File: /home/cafsindia/lead_cafsinfotech_in/public/dist/polyfills.b3c3a4255a985e45.js
var __webpack_modules__={2321:()=>{const Ot=":";Error;const tn=function(Dn,...gn){if(tn.translate){const Yn=tn.translate(Dn,gn);Dn=Yn[0],gn=Yn[1]}let Nn=Zn(Dn[0],Dn.raw[0]);for(let Yn=1;Yn<Dn.length;Yn++)Nn+=gn[Yn-1]+Zn(Dn[Yn],Dn.raw[Yn]);return Nn},fi=":";function Zn(Dn,gn){return gn.charAt(0)===fi?Dn.substring(function It(Dn,gn){for(let Nn=1,Yn=1;Nn<Dn.length;Nn++,Yn++)if("\\"===gn[Yn])Yn++;else if(Dn[Nn]===Ot)return Nn;throw new Error(`Unterminated $localize metadata block in "${gn}".`)}(Dn,gn)+1):Dn}globalThis.$localize=tn},1969:(Ot,Me,S)=>{S.r(Me),S.d(Me,{afterMain:()=>en,afterRead:()=>ve,afterWrite:()=>vn,applyStyles:()=>pn,arrow:()=>yt,auto:()=>ie,basePlacements:()=>Q,beforeMain:()=>fn,beforeRead:()=>Et,beforeWrite:()=>an,bottom:()=>e,clippingParents:()=>q,computeStyles:()=>At,createPopper:()=>ar,createPopperBase:()=>Fi,createPopperLite:()=>Or,detectOverflow:()=>Sn,end:()=>he,eventListeners:()=>ni,flip:()=>Eo,hide:()=>Va,left:()=>X,main:()=>ct,modifierPhases:()=>Pt,offset:()=>vl,placements:()=>je,popper:()=>Z,popperGenerator:()=>jn,popperOffsets:()=>_l,preventOverflow:()=>oa,read:()=>wt,reference:()=>ce,right:()=>M,start:()=>Ee,top:()=>i,variationPlacements:()=>le,viewport:()=>oe,write:()=>un});var i="top",e="bottom",M="right",X="left",ie="auto",Q=[i,e,M,X],Ee="start",he="end",q="clippingParents",oe="viewport",Z="popper",ce="reference",le=Q.reduce(function(Tt,cn){return Tt.concat([cn+"-"+Ee,cn+"-"+he])},[]),je=[].concat(Q,[ie]).reduce(function(Tt,cn){return Tt.concat([cn,cn+"-"+Ee,cn+"-"+he])},[]),Et="beforeRead",wt="read",ve="afterRead",fn="beforeMain",ct="main",en="afterMain",an="beforeWrite",un="write",vn="afterWrite",Pt=[Et,wt,ve,fn,ct,en,an,un,vn];function Ae(Tt){return Tt?(Tt.nodeName||"").toLowerCase():null}function dt(Tt){if(null==Tt)return window;if("[object Window]"!==Tt.toString()){var cn=Tt.ownerDocument;return cn&&cn.defaultView||window}return Tt}function ut(Tt){return Tt instanceof dt(Tt).Element||Tt instanceof Element}function Mt(Tt){return Tt instanceof dt(Tt).HTMLElement||Tt instanceof HTMLElement}function Wt(Tt){return!(typeof ShadowRoot>"u")&&(Tt instanceof dt(Tt).ShadowRoot||Tt instanceof ShadowRoot)}const pn={name:"applyStyles",enabled:!0,phase:"write",fn:function It(Tt){var cn=Tt.state;Object.keys(cn.elements).forEach(function(Tn){var Ri=cn.styles[Tn]||{},Un=cn.attributes[Tn]||{},Yi=cn.elements[Tn];!Mt(Yi)||!Ae(Yi)||(Object.assign(Yi.style,Ri),Object.keys(Un).forEach(function(Wi){var fr=Un[Wi];!1===fr?Yi.removeAttribute(Wi):Yi.setAttribute(Wi,!0===fr?"":fr)}))})},effect:function Vn(Tt){var cn=Tt.state,Tn={popper:{position:cn.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(cn.elements.popper.style,Tn.popper),cn.styles=Tn,cn.elements.arrow&&Object.assign(cn.elements.arrow.style,Tn.arrow),function(){Object.keys(cn.elements).forEach(function(Ri){var Un=cn.elements[Ri],Yi=cn.attributes[Ri]||{},fr=Object.keys(cn.styles.hasOwnProperty(Ri)?cn.styles[Ri]:Tn[Ri]).reduce(function(Li,Vo){return Li[Vo]="",Li},{});!Mt(Un)||!Ae(Un)||(Object.assign(Un.style,fr),Object.keys(Yi).forEach(function(Li){Un.removeAttribute(Li)}))})}},requires:["computeStyles"]};function Wn(Tt){return Tt.split("-")[0]}var ji=Math.max,An=Math.min,St=Math.round;function qt(){var Tt=navigator.userAgentData;return null!=Tt&&Tt.brands&&Array.isArray(Tt.brands)?Tt.brands.map(function(cn){return cn.brand+"/"+cn.version}).join(" "):navigator.userAgent}function Ht(){return!/^((?!chrome|android).)*safari/i.test(qt())}function on(Tt,cn,Tn){void 0===cn&&(cn=!1),void 0===Tn&&(Tn=!1);var Ri=Tt.getBoundingClientRect(),Un=1,Yi=1;cn&&Mt(Tt)&&(Un=Tt.offsetWidth>0&&St(Ri.width)/Tt.offsetWidth||1,Yi=Tt.offsetHeight>0&&St(Ri.height)/Tt.offsetHeight||1);var fr=(ut(Tt)?dt(Tt):window).visualViewport,Li=!Ht()&&Tn,Vo=(Ri.left+(Li&&fr?fr.offsetLeft:0))/Un,vr=(Ri.top+(Li&&fr?fr.offsetTop:0))/Yi,Mo=Ri.width/Un,ks=Ri.height/Yi;return{width:Mo,height:ks,top:vr,right:Vo+Mo,bottom:vr+ks,left:Vo,x:Vo,y:vr}}function Cn(Tt){var cn=on(Tt),Tn=Tt.offsetWidth,Ri=Tt.offsetHeight;return Math.abs(cn.width-Tn)<=1&&(Tn=cn.width),Math.abs(cn.height-Ri)<=1&&(Ri=cn.height),{x:Tt.offsetLeft,y:Tt.offsetTop,width:Tn,height:Ri}}function tn(Tt,cn){var Tn=cn.getRootNode&&cn.getRootNode();if(Tt.contains(cn))return!0;if(Tn&&Wt(Tn)){var Ri=cn;do{if(Ri&&Tt.isSameNode(Ri))return!0;Ri=Ri.parentNode||Ri.host}while(Ri)}return!1}function fi(Tt){return dt(Tt).getComputedStyle(Tt)}function Zn(Tt){return["table","td","th"].indexOf(Ae(Tt))>=0}function Dn(Tt){return((ut(Tt)?Tt.ownerDocument:Tt.document)||window.document).documentElement}function gn(Tt){return"html"===Ae(Tt)?Tt:Tt.assignedSlot||Tt.parentNode||(Wt(Tt)?Tt.host:null)||Dn(Tt)}function Nn(Tt){return Mt(Tt)&&"fixed"!==fi(Tt).position?Tt.offsetParent:null}function cr(Tt){for(var cn=dt(Tt),Tn=Nn(Tt);Tn&&Zn(Tn)&&"static"===fi(Tn).position;)Tn=Nn(Tn);return Tn&&("html"===Ae(Tn)||"body"===Ae(Tn)&&"static"===fi(Tn).position)?cn:Tn||function Yn(Tt){var cn=/firefox/i.test(qt());if(/Trident/i.test(qt())&&Mt(Tt)&&"fixed"===fi(Tt).position)return null;var Un=gn(Tt);for(Wt(Un)&&(Un=Un.host);Mt(Un)&&["html","body"].indexOf(Ae(Un))<0;){var Yi=fi(Un);if("none"!==Yi.transform||"none"!==Yi.perspective||"paint"===Yi.contain||-1!==["transform","perspective"].indexOf(Yi.willChange)||cn&&"filter"===Yi.willChange||cn&&Yi.filter&&"none"!==Yi.filter)return Un;Un=Un.parentNode}return null}(Tt)||cn}function Ai(Tt){return["top","bottom"].indexOf(Tt)>=0?"x":"y"}function Qi(Tt,cn,Tn){return ji(Tt,An(cn,Tn))}function eo(Tt){return Object.assign({},{top:0,right:0,bottom:0,left:0},Tt)}function as(Tt,cn){return cn.reduce(function(Tn,Ri){return Tn[Ri]=Tt,Tn},{})}const yt={name:"arrow",enabled:!0,phase:"main",fn:function mi(Tt){var cn,Tn=Tt.state,Ri=Tt.name,Un=Tt.options,Yi=Tn.elements.arrow,Wi=Tn.modifiersData.popperOffsets,fr=Wn(Tn.placement),Li=Ai(fr),vr=[X,M].indexOf(fr)>=0?"height":"width";if(Yi&&Wi){var Mo=function(cn,Tn){return eo("number"!=typeof(cn="function"==typeof cn?cn(Object.assign({},Tn.rects,{placement:Tn.placement})):cn)?cn:as(cn,Q))}(Un.padding,Tn),ks=Cn(Yi),Jo="y"===Li?i:X,$s="y"===Li?e:M,Js=Tn.rects.reference[vr]+Tn.rects.reference[Li]-Wi[Li]-Tn.rects.popper[vr],ds=Wi[Li]-Tn.rects.reference[Li],Ws=cr(Yi),es=Ws?"y"===Li?Ws.clientHeight||0:Ws.clientWidth||0:0,ea=es/2-ks[vr]/2+(Js/2-ds/2),ga=Qi(Mo[Jo],ea,es-ks[vr]-Mo[$s]);Tn.modifiersData[Ri]=((cn={})[Li]=ga,cn.centerOffset=ga-ea,cn)}},effect:function ci(Tt){var cn=Tt.state,Ri=Tt.options.element,Un=void 0===Ri?"[data-popper-arrow]":Ri;null!=Un&&("string"==typeof Un&&!(Un=cn.elements.popper.querySelector(Un))||tn(cn.elements.popper,Un)&&(cn.elements.arrow=Un))},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function hn(Tt){return Tt.split("-")[1]}var Gt={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ri(Tt){var cn,Tn=Tt.popper,Ri=Tt.popperRect,Un=Tt.placement,Yi=Tt.variation,Wi=Tt.offsets,fr=Tt.position,Li=Tt.gpuAcceleration,Vo=Tt.adaptive,vr=Tt.roundOffsets,Mo=Tt.isFixed,ks=Wi.x,Jo=void 0===ks?0:ks,$s=Wi.y,Js=void 0===$s?0:$s,ds="function"==typeof vr?vr({x:Jo,y:Js}):{x:Jo,y:Js};Jo=ds.x,Js=ds.y;var Ws=Wi.hasOwnProperty("x"),es=Wi.hasOwnProperty("y"),Ma=X,ts=i,wo=window;if(Vo){var ea=cr(Tn),ga="clientHeight",sl="clientWidth";ea===dt(Tn)&&"static"!==fi(ea=Dn(Tn)).position&&"absolute"===fr&&(ga="scrollHeight",sl="scrollWidth"),(Un===i||(Un===X||Un===M)&&Yi===he)&&(ts=e,Js-=(Mo&&ea===wo&&wo.visualViewport?wo.visualViewport.height:ea[ga])-Ri.height,Js*=Li?1:-1),Un!==X&&(Un!==i&&Un!==e||Yi!==he)||(Ma=M,Jo-=(Mo&&ea===wo&&wo.visualViewport?wo.visualViewport.width:ea[sl])-Ri.width,Jo*=Li?1:-1)}var wa,al=Object.assign({position:fr},Vo&&Gt),Kc=!0===vr?function Gn(Tt,cn){var Ri=Tt.y,Un=cn.devicePixelRatio||1;return{x:St(Tt.x*Un)/Un||0,y:St(Ri*Un)/Un||0}}({x:Jo,y:Js},dt(Tn)):{x:Jo,y:Js};return Jo=Kc.x,Js=Kc.y,Object.assign({},al,Li?((wa={})[ts]=es?"0":"",wa[Ma]=Ws?"0":"",wa.transform=(wo.devicePixelRatio||1)<=1?"translate("+Jo+"px, "+Js+"px)":"translate3d("+Jo+"px, "+Js+"px, 0)",wa):((cn={})[ts]=es?Js+"px":"",cn[Ma]=Ws?Jo+"px":"",cn.transform="",cn))}const At={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function pi(Tt){var cn=Tt.state,Tn=Tt.options,Ri=Tn.gpuAcceleration,Un=void 0===Ri||Ri,Yi=Tn.adaptive,Wi=void 0===Yi||Yi,fr=Tn.roundOffsets,Li=void 0===fr||fr,Vo={placement:Wn(cn.placement),variation:hn(cn.placement),popper:cn.elements.popper,popperRect:cn.rects.popper,gpuAcceleration:Un,isFixed:"fixed"===cn.options.strategy};null!=cn.modifiersData.popperOffsets&&(cn.styles.popper=Object.assign({},cn.styles.popper,ri(Object.assign({},Vo,{offsets:cn.modifiersData.popperOffsets,position:cn.options.strategy,adaptive:Wi,roundOffsets:Li})))),null!=cn.modifiersData.arrow&&(cn.styles.arrow=Object.assign({},cn.styles.arrow,ri(Object.assign({},Vo,{offsets:cn.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:Li})))),cn.attributes.popper=Object.assign({},cn.attributes.popper,{"data-popper-placement":cn.placement})},data:{}};var Bn={passive:!0};const ni={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function Mn(Tt){var cn=Tt.state,Tn=Tt.instance,Ri=Tt.options,Un=Ri.scroll,Yi=void 0===Un||Un,Wi=Ri.resize,fr=void 0===Wi||Wi,Li=dt(cn.elements.popper),Vo=[].concat(cn.scrollParents.reference,cn.scrollParents.popper);return Yi&&Vo.forEach(function(vr){vr.addEventListener("scroll",Tn.update,Bn)}),fr&&Li.addEventListener("resize",Tn.update,Bn),function(){Yi&&Vo.forEach(function(vr){vr.removeEventListener("scroll",Tn.update,Bn)}),fr&&Li.removeEventListener("resize",Tn.update,Bn)}},data:{}};var qn={left:"right",right:"left",bottom:"top",top:"bottom"};function Ti(Tt){return Tt.replace(/left|right|bottom|top/g,function(cn){return qn[cn]})}var Bi={start:"end",end:"start"};function Gi(Tt){return Tt.replace(/start|end/g,function(cn){return Bi[cn]})}function Ii(Tt){var cn=dt(Tt);return{scrollLeft:cn.pageXOffset,scrollTop:cn.pageYOffset}}function Ki(Tt){return on(Dn(Tt)).left+Ii(Tt).scrollLeft}function Ft(Tt){var cn=fi(Tt);return/auto|scroll|overlay|hidden/.test(cn.overflow+cn.overflowY+cn.overflowX)}function it(Tt){return["html","body","#document"].indexOf(Ae(Tt))>=0?Tt.ownerDocument.body:Mt(Tt)&&Ft(Tt)?Tt:it(gn(Tt))}function sn(Tt,cn){var Tn;void 0===cn&&(cn=[]);var Ri=it(Tt),Un=Ri===(null==(Tn=Tt.ownerDocument)?void 0:Tn.body),Yi=dt(Ri),Wi=Un?[Yi].concat(Yi.visualViewport||[],Ft(Ri)?Ri:[]):Ri,fr=cn.concat(Wi);return Un?fr:fr.concat(sn(gn(Wi)))}function Ve(Tt){return Object.assign({},Tt,{left:Tt.x,top:Tt.y,right:Tt.x+Tt.width,bottom:Tt.y+Tt.height})}function mt(Tt,cn,Tn){return cn===oe?Ve(function Jt(Tt,cn){var Tn=dt(Tt),Ri=Dn(Tt),Un=Tn.visualViewport,Yi=Ri.clientWidth,Wi=Ri.clientHeight,fr=0,Li=0;if(Un){Yi=Un.width,Wi=Un.height;var Vo=Ht();(Vo||!Vo&&"fixed"===cn)&&(fr=Un.offsetLeft,Li=Un.offsetTop)}return{width:Yi,height:Wi,x:fr+Ki(Tt),y:Li}}(Tt,Tn)):ut(cn)?function He(Tt,cn){var Tn=on(Tt,!1,"fixed"===cn);return Tn.top=Tn.top+Tt.clientTop,Tn.left=Tn.left+Tt.clientLeft,Tn.bottom=Tn.top+Tt.clientHeight,Tn.right=Tn.left+Tt.clientWidth,Tn.width=Tt.clientWidth,Tn.height=Tt.clientHeight,Tn.x=Tn.left,Tn.y=Tn.top,Tn}(cn,Tn):Ve(function hi(Tt){var cn,Tn=Dn(Tt),Ri=Ii(Tt),Un=null==(cn=Tt.ownerDocument)?void 0:cn.body,Yi=ji(Tn.scrollWidth,Tn.clientWidth,Un?Un.scrollWidth:0,Un?Un.clientWidth:0),Wi=ji(Tn.scrollHeight,Tn.clientHeight,Un?Un.scrollHeight:0,Un?Un.clientHeight:0),fr=-Ri.scrollLeft+Ki(Tt),Li=-Ri.scrollTop;return"rtl"===fi(Un||Tn).direction&&(fr+=ji(Tn.clientWidth,Un?Un.clientWidth:0)-Yi),{width:Yi,height:Wi,x:fr,y:Li}}(Dn(Tt)))}function Jn(Tt){var Li,cn=Tt.reference,Tn=Tt.element,Ri=Tt.placement,Un=Ri?Wn(Ri):null,Yi=Ri?hn(Ri):null,Wi=cn.x+cn.width/2-Tn.width/2,fr=cn.y+cn.height/2-Tn.height/2;switch(Un){case i:Li={x:Wi,y:cn.y-Tn.height};break;case e:Li={x:Wi,y:cn.y+cn.height};break;case M:Li={x:cn.x+cn.width,y:fr};break;case X:Li={x:cn.x-Tn.width,y:fr};break;default:Li={x:cn.x,y:cn.y}}var Vo=Un?Ai(Un):null;if(null!=Vo){var vr="y"===Vo?"height":"width";switch(Yi){case Ee:Li[Vo]=Li[Vo]-(cn[vr]/2-Tn[vr]/2);break;case he:Li[Vo]=Li[Vo]+(cn[vr]/2-Tn[vr]/2)}}return Li}function Sn(Tt,cn){void 0===cn&&(cn={});var Ri=cn.placement,Un=void 0===Ri?Tt.placement:Ri,Yi=cn.strategy,Wi=void 0===Yi?Tt.strategy:Yi,fr=cn.boundary,Li=void 0===fr?q:fr,Vo=cn.rootBoundary,vr=void 0===Vo?oe:Vo,Mo=cn.elementContext,ks=void 0===Mo?Z:Mo,Jo=cn.altBoundary,$s=void 0!==Jo&&Jo,Js=cn.padding,ds=void 0===Js?0:Js,Ws=eo("number"!=typeof ds?ds:as(ds,Q)),Ma=Tt.rects.popper,ts=Tt.elements[$s?ks===Z?ce:Z:ks],wo=function nn(Tt,cn,Tn,Ri){var Un="clippingParents"===cn?function bt(Tt){var cn=sn(gn(Tt)),Ri=["absolute","fixed"].indexOf(fi(Tt).position)>=0&&Mt(Tt)?cr(Tt):Tt;return ut(Ri)?cn.filter(function(Un){return ut(Un)&&tn(Un,Ri)&&"body"!==Ae(Un)}):[]}(Tt):[].concat(cn),Yi=[].concat(Un,[Tn]),fr=Yi.reduce(function(Li,Vo){var vr=mt(Tt,Vo,Ri);return Li.top=ji(vr.top,Li.top),Li.right=An(vr.right,Li.right),Li.bottom=An(vr.bottom,Li.bottom),Li.left=ji(vr.left,Li.left),Li},mt(Tt,Yi[0],Ri));return fr.width=fr.right-fr.left,fr.height=fr.bottom-fr.top,fr.x=fr.left,fr.y=fr.top,fr}(ut(ts)?ts:ts.contextElement||Dn(Tt.elements.popper),Li,vr,Wi),ea=on(Tt.elements.reference),ga=Jn({reference:ea,element:Ma,strategy:"absolute",placement:Un}),sl=Ve(Object.assign({},Ma,ga)),fl=ks===Z?sl:ea,Ia={top:wo.top-fl.top+Ws.top,bottom:fl.bottom-wo.bottom+Ws.bottom,left:wo.left-fl.left+Ws.left,right:fl.right-wo.right+Ws.right},al=Tt.modifiersData.offset;if(ks===Z&&al){var Kc=al[Un];Object.keys(Ia).forEach(function(wa){var Sl=[M,e].indexOf(wa)>=0?1:-1,qc=[i,e].indexOf(wa)>=0?"y":"x";Ia[wa]+=Kc[qc]*Sl})}return Ia}const Eo={name:"flip",enabled:!0,phase:"main",fn:function Bo(Tt){var cn=Tt.state,Tn=Tt.options,Ri=Tt.name;if(!cn.modifiersData[Ri]._skip){for(var Un=Tn.mainAxis,Yi=void 0===Un||Un,Wi=Tn.altAxis,fr=void 0===Wi||Wi,Li=Tn.fallbackPlacements,Vo=Tn.padding,vr=Tn.boundary,Mo=Tn.rootBoundary,ks=Tn.altBoundary,Jo=Tn.flipVariations,$s=void 0===Jo||Jo,Js=Tn.allowedAutoPlacements,ds=cn.options.placement,Ws=Wn(ds),Ma=Li||(Ws!==ds&&$s?function qr(Tt){if(Wn(Tt)===ie)return[];var cn=Ti(Tt);return[Gi(Tt),cn,Gi(cn)]}(ds):[Ti(ds)]),ts=[ds].concat(Ma).reduce(function(ca,Il){return ca.concat(Wn(Il)===ie?function _r(Tt,cn){void 0===cn&&(cn={});var Un=cn.boundary,Yi=cn.rootBoundary,Wi=cn.padding,fr=cn.flipVariations,Li=cn.allowedAutoPlacements,Vo=void 0===Li?je:Li,vr=hn(cn.placement),Mo=vr?fr?le:le.filter(function($s){return hn($s)===vr}):Q,ks=Mo.filter(function($s){return Vo.indexOf($s)>=0});0===ks.length&&(ks=Mo);var Jo=ks.reduce(function($s,Js){return $s[Js]=Sn(Tt,{placement:Js,boundary:Un,rootBoundary:Yi,padding:Wi})[Wn(Js)],$s},{});return Object.keys(Jo).sort(function($s,Js){return Jo[$s]-Jo[Js]})}(cn,{placement:Il,boundary:vr,rootBoundary:Mo,padding:Vo,flipVariations:$s,allowedAutoPlacements:Js}):Il)},[]),wo=cn.rects.reference,ea=cn.rects.popper,ga=new Map,sl=!0,fl=ts[0],Ia=0;Ia<ts.length;Ia++){var al=ts[Ia],Kc=Wn(al),wa=hn(al)===Ee,Sl=[i,e].indexOf(Kc)>=0,qc=Sl?"width":"height",la=Sn(cn,{placement:al,boundary:vr,rootBoundary:Mo,altBoundary:ks,padding:Vo}),pl=Sl?wa?M:X:wa?e:i;wo[qc]>ea[qc]&&(pl=Ti(pl));var Sc=Ti(pl),Ec=[];if(Yi&&Ec.push(la[Kc]<=0),fr&&Ec.push(la[pl]<=0,la[Sc]<=0),Ec.every(function(ca){return ca})){fl=al,sl=!1;break}ga.set(al,Ec)}if(sl)for(var ql=function(Il){var Xa=ts.find(function(Rl){var yl=ga.get(Rl);if(yl)return yl.slice(0,Il).every(function(sa){return sa})});if(Xa)return fl=Xa,"break"},ec=$s?3:1;ec>0&&"break"!==ql(ec);ec--);cn.placement!==fl&&(cn.modifiersData[Ri]._skip=!0,cn.placement=fl,cn.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function Ro(Tt,cn,Tn){return void 0===Tn&&(Tn={x:0,y:0}),{top:Tt.top-cn.height-Tn.y,right:Tt.right-cn.width+Tn.x,bottom:Tt.bottom-cn.height+Tn.y,left:Tt.left-cn.width-Tn.x}}function Ls(Tt){return[i,M,e,X].some(function(cn){return Tt[cn]>=0})}const Va={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function ol(Tt){var cn=Tt.state,Tn=Tt.name,Ri=cn.rects.reference,Un=cn.rects.popper,Yi=cn.modifiersData.preventOverflow,Wi=Sn(cn,{elementContext:"reference"}),fr=Sn(cn,{altBoundary:!0}),Li=Ro(Wi,Ri),Vo=Ro(fr,Un,Yi),vr=Ls(Li),Mo=Ls(Vo);cn.modifiersData[Tn]={referenceClippingOffsets:Li,popperEscapeOffsets:Vo,isReferenceHidden:vr,hasPopperEscaped:Mo},cn.attributes.popper=Object.assign({},cn.attributes.popper,{"data-popper-reference-hidden":vr,"data-popper-escaped":Mo})}},vl={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function za(Tt){var cn=Tt.state,Ri=Tt.name,Un=Tt.options.offset,Yi=void 0===Un?[0,0]:Un,Wi=je.reduce(function(vr,Mo){return vr[Mo]=function Ao(Tt,cn,Tn){var Ri=Wn(Tt),Un=[X,i].indexOf(Ri)>=0?-1:1,Yi="function"==typeof Tn?Tn(Object.assign({},cn,{placement:Tt})):Tn,Wi=Yi[0],fr=Yi[1];return Wi=Wi||0,fr=(fr||0)*Un,[X,M].indexOf(Ri)>=0?{x:fr,y:Wi}:{x:Wi,y:fr}}(Mo,cn.rects,Yi),vr},{}),fr=Wi[cn.placement],Vo=fr.y;null!=cn.modifiersData.popperOffsets&&(cn.modifiersData.popperOffsets.x+=fr.x,cn.modifiersData.popperOffsets.y+=Vo),cn.modifiersData[Ri]=Wi}},_l={name:"popperOffsets",enabled:!0,phase:"read",fn:function Na(Tt){var cn=Tt.state;cn.modifiersData[Tt.name]=Jn({reference:cn.rects.reference,element:cn.rects.popper,strategy:"absolute",placement:cn.placement})},data:{}},oa={name:"preventOverflow",enabled:!0,phase:"main",fn:function Zs(Tt){var cn=Tt.state,Tn=Tt.options,Ri=Tt.name,Un=Tn.mainAxis,Yi=void 0===Un||Un,Wi=Tn.altAxis,fr=void 0!==Wi&&Wi,ks=Tn.tether,Jo=void 0===ks||ks,$s=Tn.tetherOffset,Js=void 0===$s?0:$s,ds=Sn(cn,{boundary:Tn.boundary,rootBoundary:Tn.rootBoundary,padding:Tn.padding,altBoundary:Tn.altBoundary}),Ws=Wn(cn.placement),es=hn(cn.placement),Ma=!es,ts=Ai(Ws),wo=function gs(Tt){return"x"===Tt?"y":"x"}(ts),ea=cn.modifiersData.popperOffsets,ga=cn.rects.reference,sl=cn.rects.popper,fl="function"==typeof Js?Js(Object.assign({},cn.rects,{placement:cn.placement})):Js,Ia="number"==typeof fl?{mainAxis:fl,altAxis:fl}:Object.assign({mainAxis:0,altAxis:0},fl),al=cn.modifiersData.offset?cn.modifiersData.offset[cn.placement]:null,Kc={x:0,y:0};if(ea){if(Yi){var wa,Sl="y"===ts?i:X,qc="y"===ts?e:M,la="y"===ts?"height":"width",pl=ea[ts],Sc=pl+ds[Sl],Ec=pl-ds[qc],Qc=Jo?-sl[la]/2:0,ql=es===Ee?ga[la]:sl[la],ec=es===Ee?-sl[la]:-ga[la],Yc=cn.elements.arrow,ca=Jo&&Yc?Cn(Yc):{width:0,height:0},Il=cn.modifiersData["arrow#persistent"]?cn.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},Xa=Il[Sl],Rl=Il[qc],yl=Qi(0,ga[la],ca[la]),sa=Ma?ga[la]/2-Qc-yl-Xa-Ia.mainAxis:ql-yl-Xa-Ia.mainAxis,Lu=Ma?-ga[la]/2+Qc+yl+Rl+Ia.mainAxis:ec+yl+Rl+Ia.mainAxis,Aa=cn.elements.arrow&&cr(cn.elements.arrow),ku=Aa?"y"===ts?Aa.clientTop||0:Aa.clientLeft||0:0,Ql=null!=(wa=al?.[ts])?wa:0,ta=pl+Lu-Ql,vc=Qi(Jo?An(Sc,pl+sa-Ql-ku):Sc,pl,Jo?ji(Ec,ta):Ec);ea[ts]=vc,Kc[ts]=vc-pl}if(fr){var xu,Ll=ea[wo],Hs="y"===wo?"height":"width",kl=Ll+ds["x"===ts?i:X],Nc=Ll-ds["x"===ts?e:M],fu=-1!==[i,X].indexOf(Ws),Rc=null!=(xu=al?.[wo])?xu:0,Ke=fu?kl:Ll-ga[Hs]-sl[Hs]-Rc+Ia.altAxis,Se=fu?Ll+ga[Hs]+sl[Hs]-Rc-Ia.altAxis:Nc,re=Jo&&fu?function Xr(Tt,cn,Tn){var Ri=Qi(Tt,cn,Tn);return Ri>Tn?Tn:Ri}(Ke,Ll,Se):Qi(Jo?Ke:kl,Ll,Jo?Se:Nc);ea[wo]=re,Kc[wo]=re-Ll}cn.modifiersData[Ri]=Kc}},requiresIfExists:["offset"]};function dl(Tt,cn,Tn){void 0===Tn&&(Tn=!1);var Ri=Mt(cn),Un=Mt(cn)&&function Qr(Tt){var cn=Tt.getBoundingClientRect(),Tn=St(cn.width)/Tt.offsetWidth||1,Ri=St(cn.height)/Tt.offsetHeight||1;return 1!==Tn||1!==Ri}(cn),Yi=Dn(cn),Wi=on(Tt,Un,Tn),fr={scrollLeft:0,scrollTop:0},Li={x:0,y:0};return(Ri||!Ri&&!Tn)&&(("body"!==Ae(cn)||Ft(Yi))&&(fr=function xl(Tt){return Tt!==dt(Tt)&&Mt(Tt)?function no(Tt){return{scrollLeft:Tt.scrollLeft,scrollTop:Tt.scrollTop}}(Tt):Ii(Tt)}(cn)),Mt(cn)?((Li=on(cn,!0)).x+=cn.clientLeft,Li.y+=cn.clientTop):Yi&&(Li.x=Ki(Yi))),{x:Wi.left+fr.scrollLeft-Li.x,y:Wi.top+fr.scrollTop-Li.y,width:Wi.width,height:Wi.height}}function Ya(Tt){var cn=new Map,Tn=new Set,Ri=[];function Un(Yi){Tn.add(Yi.name),[].concat(Yi.requires||[],Yi.requiresIfExists||[]).forEach(function(fr){if(!Tn.has(fr)){var Li=cn.get(fr);Li&&Un(Li)}}),Ri.push(Yi)}return Tt.forEach(function(Yi){cn.set(Yi.name,Yi)}),Tt.forEach(function(Yi){Tn.has(Yi.name)||Un(Yi)}),Ri}function ko(Tt){var cn;return function(){return cn||(cn=new Promise(function(Tn){Promise.resolve().then(function(){cn=void 0,Tn(Tt())})})),cn}}var In={placement:"bottom",modifiers:[],strategy:"absolute"};function Rt(){for(var Tt=arguments.length,cn=new Array(Tt),Tn=0;Tn<Tt;Tn++)cn[Tn]=arguments[Tn];return!cn.some(function(Ri){return!(Ri&&"function"==typeof Ri.getBoundingClientRect)})}function jn(Tt){void 0===Tt&&(Tt={});var Tn=Tt.defaultModifiers,Ri=void 0===Tn?[]:Tn,Un=Tt.defaultOptions,Yi=void 0===Un?In:Un;return function(fr,Li,Vo){void 0===Vo&&(Vo=Yi);var vr={placement:"bottom",orderedModifiers:[],options:Object.assign({},In,Yi),modifiersData:{},elements:{reference:fr,popper:Li},attributes:{},styles:{}},Mo=[],ks=!1,Jo={state:vr,setOptions:function(Ws){var es="function"==typeof Ws?Ws(vr.options):Ws;Js(),vr.options=Object.assign({},Yi,vr.options,es),vr.scrollParents={reference:ut(fr)?sn(fr):fr.contextElement?sn(fr.contextElement):[],popper:sn(Li)};var Ma=function Lo(Tt){var cn=Ya(Tt);return Pt.reduce(function(Tn,Ri){return Tn.concat(cn.filter(function(Un){return Un.phase===Ri}))},[])}(function jt(Tt){var cn=Tt.reduce(function(Tn,Ri){var Un=Tn[Ri.name];return Tn[Ri.name]=Un?Object.assign({},Un,Ri,{options:Object.assign({},Un.options,Ri.options),data:Object.assign({},Un.data,Ri.data)}):Ri,Tn},{});return Object.keys(cn).map(function(Tn){return cn[Tn]})}([].concat(Ri,vr.options.modifiers)));return vr.orderedModifiers=Ma.filter(function(ts){return ts.enabled}),function $s(){vr.orderedModifiers.forEach(function(ds){var es=ds.options,ts=ds.effect;if("function"==typeof ts){var wo=ts({state:vr,name:ds.name,instance:Jo,options:void 0===es?{}:es});Mo.push(wo||function(){})}})}(),Jo.update()},forceUpdate:function(){if(!ks){var Ws=vr.elements,es=Ws.reference,Ma=Ws.popper;if(Rt(es,Ma)){vr.rects={reference:dl(es,cr(Ma),"fixed"===vr.options.strategy),popper:Cn(Ma)},vr.reset=!1,vr.placement=vr.options.placement,vr.orderedModifiers.forEach(function(Ia){return vr.modifiersData[Ia.name]=Object.assign({},Ia.data)});for(var ts=0;ts<vr.orderedModifiers.length;ts++)if(!0!==vr.reset){var wo=vr.orderedModifiers[ts],ea=wo.fn,ga=wo.options;"function"==typeof ea&&(vr=ea({state:vr,options:void 0===ga?{}:ga,name:wo.name,instance:Jo})||vr)}else vr.reset=!1,ts=-1}}},update:ko(function(){return new Promise(function(ds){Jo.forceUpdate(),ds(vr)})}),destroy:function(){Js(),ks=!0}};if(!Rt(fr,Li))return Jo;function Js(){Mo.forEach(function(ds){return ds()}),Mo=[]}return Jo.setOptions(Vo).then(function(ds){!ks&&Vo.onFirstUpdate&&Vo.onFirstUpdate(ds)}),Jo}}var Fi=jn(),ar=jn({defaultModifiers:[ni,_l,At,pn,vl,Eo,oa,yt,Va]}),Or=jn({defaultModifiers:[ni,_l,At,pn]})},9121:function(Ot,Me){var i;!function(){"use strict";var M=Math.cosh||function(Z){return Math.abs(Z)<1e-9?1-Z:.5*(Math.exp(Z)+Math.exp(-Z))},X=Math.sinh||function(Z){return Math.abs(Z)<1e-9?Z:.5*(Math.exp(Z)-Math.exp(-Z))},Ee=function(){throw SyntaxError("Invalid Param")};function he(Z,ce){var le=Math.abs(Z),je=Math.abs(ce);return 0===Z?Math.log(je):0===ce?Math.log(le):le<3e3&&je<3e3?.5*Math.log(Z*Z+ce*ce):(Z/=2,ce/=2,.5*Math.log(Z*Z+ce*ce)+Math.LN2)}function oe(Z,ce){if(!(this instanceof oe))return new oe(Z,ce);var le=function(Z,ce){var le={re:0,im:0};if(null==Z)le.re=le.im=0;else if(void 0!==ce)le.re=Z,le.im=ce;else switch(typeof Z){case"object":if("im"in Z&&"re"in Z)le.re=Z.re,le.im=Z.im;else if("abs"in Z&&"arg"in Z){if(!Number.isFinite(Z.abs)&&Number.isFinite(Z.arg))return oe.INFINITY;le.re=Z.abs*Math.cos(Z.arg),le.im=Z.abs*Math.sin(Z.arg)}else if("r"in Z&&"phi"in Z){if(!Number.isFinite(Z.r)&&Number.isFinite(Z.phi))return oe.INFINITY;le.re=Z.r*Math.cos(Z.phi),le.im=Z.r*Math.sin(Z.phi)}else 2===Z.length?(le.re=Z[0],le.im=Z[1]):Ee();break;case"string":le.im=le.re=0;var je=Z.match(/\d+\.?\d*e[+-]?\d+|\d+\.?\d*|\.\d+|./g),Et=1,wt=0;null===je&&Ee();for(var ve=0;ve<je.length;ve++){var fn=je[ve];" "===fn||"\t"===fn||"\n"===fn||("+"===fn?Et++:"-"===fn?wt++:"i"===fn||"I"===fn?(Et+wt===0&&Ee()," "===je[ve+1]||isNaN(je[ve+1])?le.im+=parseFloat((wt%2?"-":"")+"1"):(le.im+=parseFloat((wt%2?"-":"")+je[ve+1]),ve++),Et=wt=0):((Et+wt===0||isNaN(fn))&&Ee(),"i"===je[ve+1]||"I"===je[ve+1]?(le.im+=parseFloat((wt%2?"-":"")+fn),ve++):le.re+=parseFloat((wt%2?"-":"")+fn),Et=wt=0))}Et+wt>0&&Ee();break;case"number":le.im=0,le.re=Z;break;default:Ee()}return isNaN(le.re)||isNaN(le.im),le}(Z,ce);this.re=le.re,this.im=le.im}oe.prototype={re:0,im:0,sign:function(){var Z=this.abs();return new oe(this.re/Z,this.im/Z)},add:function(Z,ce){var le=new oe(Z,ce);return this.isInfinite()&&le.isInfinite()?oe.NAN:this.isInfinite()||le.isInfinite()?oe.INFINITY:new oe(this.re+le.re,this.im+le.im)},sub:function(Z,ce){var le=new oe(Z,ce);return this.isInfinite()&&le.isInfinite()?oe.NAN:this.isInfinite()||le.isInfinite()?oe.INFINITY:new oe(this.re-le.re,this.im-le.im)},mul:function(Z,ce){var le=new oe(Z,ce);return this.isInfinite()&&le.isZero()||this.isZero()&&le.isInfinite()?oe.NAN:this.isInfinite()||le.isInfinite()?oe.INFINITY:0===le.im&&0===this.im?new oe(this.re*le.re,0):new oe(this.re*le.re-this.im*le.im,this.re*le.im+this.im*le.re)},div:function(Z,ce){var le=new oe(Z,ce);if(this.isZero()&&le.isZero()||this.isInfinite()&&le.isInfinite())return oe.NAN;if(this.isInfinite()||le.isZero())return oe.INFINITY;if(this.isZero()||le.isInfinite())return oe.ZERO;Z=this.re,ce=this.im;var wt,ve,je=le.re,Et=le.im;return 0===Et?new oe(Z/je,ce/je):Math.abs(je)<Math.abs(Et)?new oe((Z*(ve=je/Et)+ce)/(wt=je*ve+Et),(ce*ve-Z)/wt):new oe((Z+ce*(ve=Et/je))/(wt=Et*ve+je),(ce-Z*ve)/wt)},pow:function(Z,ce){var le=new oe(Z,ce);if(Z=this.re,ce=this.im,le.isZero())return oe.ONE;if(0===le.im){if(0===ce&&Z>0)return new oe(Math.pow(Z,le.re),0);if(0===Z)switch((le.re%4+4)%4){case 0:return new oe(Math.pow(ce,le.re),0);case 1:return new oe(0,Math.pow(ce,le.re));case 2:return new oe(-Math.pow(ce,le.re),0);case 3:return new oe(0,-Math.pow(ce,le.re))}}if(0===Z&&0===ce&&le.re>0&&le.im>=0)return oe.ZERO;var je=Math.atan2(ce,Z),Et=he(Z,ce);return Z=Math.exp(le.re*Et-le.im*je),ce=le.im*Et+le.re*je,new oe(Z*Math.cos(ce),Z*Math.sin(ce))},sqrt:function(){var je,Et,Z=this.re,ce=this.im,le=this.abs();if(Z>=0){if(0===ce)return new oe(Math.sqrt(Z),0);je=.5*Math.sqrt(2*(le+Z))}else je=Math.abs(ce)/Math.sqrt(2*(le-Z));return Et=Z<=0?.5*Math.sqrt(2*(le-Z)):Math.abs(ce)/Math.sqrt(2*(le+Z)),new oe(je,ce<0?-Et:Et)},exp:function(){var Z=Math.exp(this.re);return new oe(Z*Math.cos(this.im),Z*Math.sin(this.im))},expm1:function(){var Z=this.re,ce=this.im;return new oe(Math.expm1(Z)*Math.cos(ce)+function(Z){var ce=Math.PI/4;if(-ce>Z||Z>ce)return Math.cos(Z)-1;var le=Z*Z;return le*(le*(le*(le*(le*(le*(le*(le/20922789888e3-1/87178291200)+1/479001600)-1/3628800)+1/40320)-1/720)+1/24)-.5)}(ce),Math.exp(Z)*Math.sin(ce))},log:function(){var Z=this.re,ce=this.im;return new oe(he(Z,ce),Math.atan2(ce,Z))},abs:function(){return Z=this.re,ce=this.im,le=Math.abs(Z),je=Math.abs(ce),le<3e3&&je<3e3?Math.sqrt(le*le+je*je):(le<je?(le=je,je=Z/ce):je=ce/Z,le*Math.sqrt(1+je*je));var Z,ce,le,je},arg:function(){return Math.atan2(this.im,this.re)},sin:function(){var Z=this.re,ce=this.im;return new oe(Math.sin(Z)*M(ce),Math.cos(Z)*X(ce))},cos:function(){var Z=this.re,ce=this.im;return new oe(Math.cos(Z)*M(ce),-Math.sin(Z)*X(ce))},tan:function(){var Z=2*this.re,ce=2*this.im,le=Math.cos(Z)+M(ce);return new oe(Math.sin(Z)/le,X(ce)/le)},cot:function(){var Z=2*this.re,ce=2*this.im,le=Math.cos(Z)-M(ce);return new oe(-Math.sin(Z)/le,X(ce)/le)},sec:function(){var Z=this.re,ce=this.im,le=.5*M(2*ce)+.5*Math.cos(2*Z);return new oe(Math.cos(Z)*M(ce)/le,Math.sin(Z)*X(ce)/le)},csc:function(){var Z=this.re,ce=this.im,le=.5*M(2*ce)-.5*Math.cos(2*Z);return new oe(Math.sin(Z)*M(ce)/le,-Math.cos(Z)*X(ce)/le)},asin:function(){var Z=this.re,ce=this.im,le=new oe(ce*ce-Z*Z+1,-2*Z*ce).sqrt(),je=new oe(le.re-ce,le.im+Z).log();return new oe(je.im,-je.re)},acos:function(){var Z=this.re,ce=this.im,le=new oe(ce*ce-Z*Z+1,-2*Z*ce).sqrt(),je=new oe(le.re-ce,le.im+Z).log();return new oe(Math.PI/2-je.im,je.re)},atan:function(){var Z=this.re,ce=this.im;if(0===Z){if(1===ce)return new oe(0,1/0);if(-1===ce)return new oe(0,-1/0)}var le=Z*Z+(1-ce)*(1-ce),je=new oe((1-ce*ce-Z*Z)/le,-2*Z/le).log();return new oe(-.5*je.im,.5*je.re)},acot:function(){var Z=this.re,ce=this.im;if(0===ce)return new oe(Math.atan2(1,Z),0);var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).atan():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).atan()},asec:function(){var Z=this.re,ce=this.im;if(0===Z&&0===ce)return new oe(0,1/0);var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).acos():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).acos()},acsc:function(){var Z=this.re,ce=this.im;if(0===Z&&0===ce)return new oe(Math.PI/2,1/0);var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).asin():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).asin()},sinh:function(){var Z=this.re,ce=this.im;return new oe(X(Z)*Math.cos(ce),M(Z)*Math.sin(ce))},cosh:function(){var Z=this.re,ce=this.im;return new oe(M(Z)*Math.cos(ce),X(Z)*Math.sin(ce))},tanh:function(){var Z=2*this.re,ce=2*this.im,le=M(Z)+Math.cos(ce);return new oe(X(Z)/le,Math.sin(ce)/le)},coth:function(){var Z=2*this.re,ce=2*this.im,le=M(Z)-Math.cos(ce);return new oe(X(Z)/le,-Math.sin(ce)/le)},csch:function(){var Z=this.re,ce=this.im,le=Math.cos(2*ce)-M(2*Z);return new oe(-2*X(Z)*Math.cos(ce)/le,2*M(Z)*Math.sin(ce)/le)},sech:function(){var Z=this.re,ce=this.im,le=Math.cos(2*ce)+M(2*Z);return new oe(2*M(Z)*Math.cos(ce)/le,-2*X(Z)*Math.sin(ce)/le)},asinh:function(){var Z=this.im;this.im=-this.re,this.re=Z;var ce=this.asin();return this.re=-this.im,this.im=Z,Z=ce.re,ce.re=-ce.im,ce.im=Z,ce},acosh:function(){var Z=this.acos();if(Z.im<=0){var ce=Z.re;Z.re=-Z.im,Z.im=ce}else ce=Z.im,Z.im=-Z.re,Z.re=ce;return Z},atanh:function(){var Z=this.re,ce=this.im,le=Z>1&&0===ce,je=1-Z,Et=1+Z,wt=je*je+ce*ce,ve=0!==wt?new oe((Et*je-ce*ce)/wt,(ce*je+Et*ce)/wt):new oe(-1!==Z?Z/0:0,0!==ce?ce/0:0),fn=ve.re;return ve.re=he(ve.re,ve.im)/2,ve.im=Math.atan2(ve.im,fn)/2,le&&(ve.im=-ve.im),ve},acoth:function(){var Z=this.re,ce=this.im;if(0===Z&&0===ce)return new oe(0,Math.PI/2);var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).atanh():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).atanh()},acsch:function(){var Z=this.re,ce=this.im;if(0===ce)return new oe(0!==Z?Math.log(Z+Math.sqrt(Z*Z+1)):1/0,0);var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).asinh():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).asinh()},asech:function(){var Z=this.re,ce=this.im;if(this.isZero())return oe.INFINITY;var le=Z*Z+ce*ce;return 0!==le?new oe(Z/le,-ce/le).acosh():new oe(0!==Z?Z/0:0,0!==ce?-ce/0:0).acosh()},inverse:function(){if(this.isZero())return oe.INFINITY;if(this.isInfinite())return oe.ZERO;var Z=this.re,ce=this.im,le=Z*Z+ce*ce;return new oe(Z/le,-ce/le)},conjugate:function(){return new oe(this.re,-this.im)},neg:function(){return new oe(-this.re,-this.im)},ceil:function(Z){return Z=Math.pow(10,Z||0),new oe(Math.ceil(this.re*Z)/Z,Math.ceil(this.im*Z)/Z)},floor:function(Z){return Z=Math.pow(10,Z||0),new oe(Math.floor(this.re*Z)/Z,Math.floor(this.im*Z)/Z)},round:function(Z){return Z=Math.pow(10,Z||0),new oe(Math.round(this.re*Z)/Z,Math.round(this.im*Z)/Z)},equals:function(Z,ce){var le=new oe(Z,ce);return Math.abs(le.re-this.re)<=oe.EPSILON&&Math.abs(le.im-this.im)<=oe.EPSILON},clone:function(){return new oe(this.re,this.im)},toString:function(){var Z=this.re,ce=this.im,le="";return this.isNaN()?"NaN":this.isInfinite()?"Infinity":(Math.abs(Z)<oe.EPSILON&&(Z=0),Math.abs(ce)<oe.EPSILON&&(ce=0),0===ce?le+Z:(0!==Z?(le+=Z,le+=" ",ce<0?(ce=-ce,le+="-"):le+="+",le+=" "):ce<0&&(ce=-ce,le+="-"),1!==ce&&(le+=ce),le+"i"))},toVector:function(){return[this.re,this.im]},valueOf:function(){return 0===this.im?this.re:null},isNaN:function(){return isNaN(this.re)||isNaN(this.im)},isZero:function(){return 0===this.im&&0===this.re},isFinite:function(){return isFinite(this.re)&&isFinite(this.im)},isInfinite:function(){return!(this.isNaN()||this.isFinite())}},oe.ZERO=new oe(0,0),oe.ONE=new oe(1,0),oe.I=new oe(0,1),oe.PI=new oe(Math.PI,0),oe.E=new oe(Math.E,0),oe.INFINITY=new oe(1/0,1/0),oe.NAN=new oe(NaN,NaN),oe.EPSILON=1e-15,void 0!==(i=function(){return oe}.apply(Me,[]))&&(Ot.exports=i)}()},4987:Ot=>{var Me=Object.assign||function(M){for(var X=1;X<arguments.length;X++){var ie=arguments[X];for(var Q in ie)Object.prototype.hasOwnProperty.call(ie,Q)&&(M[Q]=ie[Q])}return M},S={"{":"\\{","}":"\\}","\\":"\\textbackslash{}","#":"\\#",$:"\\$","%":"\\%","&":"\\&","^":"\\textasciicircum{}",_:"\\_","~":"\\textasciitilde{}"},i={"\u2013":"\\--","\u2014":"\\---"," ":"~","\t":"\\qquad{}","\r\n":"\\newline{}","\n":"\\newline{}"},e=function(X,ie){return Me({},X,ie)};Ot.exports=function(M){for(var X=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},ie=X.preserveFormatting,Q=void 0!==ie&&ie,Ee=X.escapeMapFn,he=void 0===Ee?e:Ee,q=String(M),oe="",Z=he(Me({},S),Q?Me({},i):{}),ce=Object.keys(Z),le=function(){var Et=!1;ce.forEach(function(wt,ve){Et||q.length>=wt.length&&q.slice(0,wt.length)===wt&&(oe+=Z[ce[ve]],q=q.slice(wt.length,q.length),Et=!0)}),Et||(oe+=q.slice(0,1),q=q.slice(1,q.length))};q;)le();return oe}},7955:Ot=>{Ot.exports=function Me(S,i){"use strict";var je,Et,e=/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,M=/(^[ ]*|[ ]*$)/g,X=/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,ie=/^0x[0-9a-f]+$/i,Q=/^0/,Ee=function(fn){return Me.insensitive&&(""+fn).toLowerCase()||""+fn},he=Ee(S).replace(M,"")||"",q=Ee(i).replace(M,"")||"",oe=he.replace(e,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),Z=q.replace(e,"\0$1\0").replace(/\0$/,"").replace(/^\0/,"").split("\0"),ce=parseInt(he.match(ie),16)||1!==oe.length&&he.match(X)&&Date.parse(he),le=parseInt(q.match(ie),16)||ce&&q.match(X)&&Date.parse(q)||null;if(le){if(ce<le)return-1;if(ce>le)return 1}for(var wt=0,ve=Math.max(oe.length,Z.length);wt<ve;wt++){if(je=!(oe[wt]||"").match(Q)&&parseFloat(oe[wt])||oe[wt]||0,Et=!(Z[wt]||"").match(Q)&&parseFloat(Z[wt])||Z[wt]||0,isNaN(je)!==isNaN(Et))return isNaN(je)?1:-1;if(typeof je!=typeof Et&&(je+="",Et+=""),je<Et)return-1;if(je>Et)return 1}return 0}},6021:Ot=>{function Me(e){return e instanceof Buffer?Buffer.from(e):new e.constructor(e.buffer.slice(),e.byteOffset,e.length)}Ot.exports=function S(e){return(e=e||{}).circles?function i(e){var M=[],X=[];return e.proto?function Ee(he){if("object"!=typeof he||null===he)return he;if(he instanceof Date)return new Date(he);if(Array.isArray(he))return ie(he,Ee);if(he instanceof Map)return new Map(ie(Array.from(he),Ee));if(he instanceof Set)return new Set(ie(Array.from(he),Ee));var q={};for(var oe in M.push(he),X.push(q),he){var Z=he[oe];if("object"!=typeof Z||null===Z)q[oe]=Z;else if(Z instanceof Date)q[oe]=new Date(Z);else if(Z instanceof Map)q[oe]=new Map(ie(Array.from(Z),Ee));else if(Z instanceof Set)q[oe]=new Set(ie(Array.from(Z),Ee));else if(ArrayBuffer.isView(Z))q[oe]=Me(Z);else{var ce=M.indexOf(Z);q[oe]=-1!==ce?X[ce]:Ee(Z)}}return M.pop(),X.pop(),q}:function Q(he){if("object"!=typeof he||null===he)return he;if(he instanceof Date)return new Date(he);if(Array.isArray(he))return ie(he,Q);if(he instanceof Map)return new Map(ie(Array.from(he),Q));if(he instanceof Set)return new Set(ie(Array.from(he),Q));var q={};for(var oe in M.push(he),X.push(q),he)if(!1!==Object.hasOwnProperty.call(he,oe)){var Z=he[oe];if("object"!=typeof Z||null===Z)q[oe]=Z;else if(Z instanceof Date)q[oe]=new Date(Z);else if(Z instanceof Map)q[oe]=new Map(ie(Array.from(Z),Q));else if(Z instanceof Set)q[oe]=new Set(ie(Array.from(Z),Q));else if(ArrayBuffer.isView(Z))q[oe]=Me(Z);else{var ce=M.indexOf(Z);q[oe]=-1!==ce?X[ce]:Q(Z)}}return M.pop(),X.pop(),q};function ie(he,q){for(var oe=Object.keys(he),Z=new Array(oe.length),ce=0;ce<oe.length;ce++){var le=oe[ce],je=he[le];if("object"!=typeof je||null===je)Z[le]=je;else if(je instanceof Date)Z[le]=new Date(je);else if(ArrayBuffer.isView(je))Z[le]=Me(je);else{var Et=M.indexOf(je);Z[le]=-1!==Et?X[Et]:q(je)}}return Z}}(e):e.proto?function ie(Q){if("object"!=typeof Q||null===Q)return Q;if(Q instanceof Date)return new Date(Q);if(Array.isArray(Q))return M(Q,ie);if(Q instanceof Map)return new Map(M(Array.from(Q),ie));if(Q instanceof Set)return new Set(M(Array.from(Q),ie));var Ee={};for(var he in Q){var q=Q[he];Ee[he]="object"!=typeof q||null===q?q:q instanceof Date?new Date(q):q instanceof Map?new Map(M(Array.from(q),ie)):q instanceof Set?new Set(M(Array.from(q),ie)):ArrayBuffer.isView(q)?Me(q):ie(q)}return Ee}:function X(Q){if("object"!=typeof Q||null===Q)return Q;if(Q instanceof Date)return new Date(Q);if(Array.isArray(Q))return M(Q,X);if(Q instanceof Map)return new Map(M(Array.from(Q),X));if(Q instanceof Set)return new Set(M(Array.from(Q),X));var Ee={};for(var he in Q)if(!1!==Object.hasOwnProperty.call(Q,he)){var q=Q[he];Ee[he]="object"!=typeof q||null===q?q:q instanceof Date?new Date(q):q instanceof Map?new Map(M(Array.from(q),X)):q instanceof Set?new Set(M(Array.from(q),X)):ArrayBuffer.isView(q)?Me(q):X(q)}return Ee};function M(Q,Ee){for(var he=Object.keys(Q),q=new Array(he.length),oe=0;oe<he.length;oe++){var Z=he[oe],ce=Q[Z];q[Z]="object"!=typeof ce||null===ce?ce:ce instanceof Date?new Date(ce):ArrayBuffer.isView(ce)?Me(ce):Ee(ce)}return q}}},4087:(Ot,Me,S)=>{S.r(Me),S.d(Me,{ArgumentOutOfRangeError:()=>Xr.k,AsyncSubject:()=>le.h,BehaviorSubject:()=>Z.t,ConnectableObservable:()=>e.G,EMPTY:()=>Bi.w,EmptyError:()=>cr.G,NEVER:()=>Ao,NotFoundError:()=>Ur.m,Notification:()=>fi.Eg,NotificationKind:()=>fi.Ij,ObjectUnsubscribedError:()=>eo.P,Observable:()=>i.c,ReplaySubject:()=>ce.m,Scheduler:()=>Cn._,SequenceError:()=>as.I,Subject:()=>oe.B,Subscriber:()=>tn.vU,Subscription:()=>ie.yU,TimeoutError:()=>uo.M,UnsubscriptionError:()=>mi.Z,VirtualAction:()=>on,VirtualTimeScheduler:()=>Ht,animationFrame:()=>qt,animationFrameScheduler:()=>St,animationFrames:()=>Ee,asap:()=>Mt,asapScheduler:()=>ut,async:()=>Wt.b,asyncScheduler:()=>Wt.E,audit:()=>In.s,auditTime:()=>Rt.Z,bindCallback:()=>ri,bindNodeCallback:()=>pi,buffer:()=>jn.r,bufferCount:()=>Fi.S,bufferTime:()=>Ui.w,bufferToggle:()=>ar.H,bufferWhen:()=>er.n,catchError:()=>Or.W,combineAll:()=>Tt.p,combineLatest:()=>At.z,combineLatestAll:()=>cn.A,combineLatestWith:()=>Tn.v,concat:()=>Bn.x,concatAll:()=>Ri.K,concatMap:()=>Un.H,concatMapTo:()=>Yi.S,concatWith:()=>Wi.$,config:()=>jt.$,connect:()=>fr.N,connectable:()=>Ti,count:()=>Li.U,debounce:()=>Vo.s,debounceTime:()=>vr.B,defaultIfEmpty:()=>Mo.U,defer:()=>ni,delay:()=>ks.c,delayWhen:()=>Jo.o,dematerialize:()=>$s.Z,distinct:()=>Js.d,distinctUntilChanged:()=>ds.F,distinctUntilKeyChanged:()=>Ws.w,elementAt:()=>es.s,empty:()=>Bi.I,endWith:()=>Ma.q,every:()=>ts.S,exhaust:()=>wo.B,exhaustAll:()=>ea.C,exhaustMap:()=>ga.p,expand:()=>sl.f,filter:()=>Zs.p,finalize:()=>fl.j,find:()=>Ia.I,findIndex:()=>al.S,first:()=>Kc.$,firstValueFrom:()=>Qi,flatMap:()=>ql.q,forkJoin:()=>hi,from:()=>Ft.H,fromEvent:()=>bt,fromEventPattern:()=>qr,generate:()=>Eo,groupBy:()=>wa.$,identity:()=>gn.D,ignoreElements:()=>Sl.w,iif:()=>Ro,interval:()=>Ls.Y,isEmpty:()=>qc.I,isObservable:()=>Yn,last:()=>la.H,lastValueFrom:()=>Ai,map:()=>pl.T,mapTo:()=>Sc.u,materialize:()=>Ec.O,max:()=>Qc.T,merge:()=>Va,mergeAll:()=>ol.U,mergeMap:()=>it.Z,mergeMapTo:()=>ec.C,mergeScan:()=>Yc.i,mergeWith:()=>ca.X,min:()=>Il.j,multicast:()=>Xa.f,never:()=>za,noop:()=>Dn.l,observable:()=>M.s,observeOn:()=>Gt.Q,of:()=>vl.of,onErrorResumeNext:()=>Na.g,onErrorResumeNextWith:()=>Rl.w,pairs:()=>_l,pairwise:()=>yl.J,partition:()=>oa,pipe:()=>Zn.F,pluck:()=>sa.E,publish:()=>Lu.m,publishBehavior:()=>Aa.K,publishLast:()=>ku.k,publishReplay:()=>Ql.H,queue:()=>Wn,queueScheduler:()=>pn,race:()=>no.O,raceWith:()=>sc.w,range:()=>xl,reduce:()=>ta.T,refCount:()=>Ll.B,repeat:()=>vc.u,repeatWhen:()=>xu.Y,retry:()=>Fc.L,retryWhen:()=>po.l,sample:()=>Hs.X,sampleTime:()=>kl.q,scan:()=>Nc.S,scheduled:()=>ko.c,sequenceEqual:()=>fu.m,share:()=>Rc.u,shareReplay:()=>Ke.t,single:()=>Se.J,skip:()=>re.i,skipLast:()=>Ge.G,skipUntil:()=>xt.U,skipWhile:()=>Qt.j,startWith:()=>kn.Z,subscribeOn:()=>yt._,switchAll:()=>bi.w,switchMap:()=>vi.n,switchMapTo:()=>Ci.K,switchScan:()=>Xi.m,take:()=>$i.s,takeLast:()=>Er.o,takeUntil:()=>ai.Q,takeWhile:()=>so.v,tap:()=>Fr.M,throttle:()=>zr.n,throttleTime:()=>ho.c,throwError:()=>Qr.$,throwIfEmpty:()=>Vr.v,timeInterval:()=>is.f,timeout:()=>uo.w,timeoutWith:()=>Ms.o,timer:()=>dl.O,timestamp:()=>Ds.v,toArray:()=>Xo.$,using:()=>Ya,window:()=>na.x,windowCount:()=>zs.k,windowTime:()=>ya.s,windowToggle:()=>Je.J,windowWhen:()=>at.p,withLatestFrom:()=>Oe.E,zip:()=>Lo.y,zipAll:()=>Ct.x,zipWith:()=>On.O});var i=S(1985),e=S(17),M=S(3494);const X={now:()=>(X.delegate||performance).now(),delegate:void 0};var ie=S(3961);const Q={schedule(_i){let Qn=requestAnimationFrame,qi=cancelAnimationFrame;const{delegate:Di}=Q;Di&&(Qn=Di.requestAnimationFrame,qi=Di.cancelAnimationFrame);const fo=Qn(Uo=>{qi=void 0,_i(Uo)});return new ie.yU(()=>qi?.(fo))},requestAnimationFrame(..._i){const{delegate:Qn}=Q;return(Qn?.requestAnimationFrame||requestAnimationFrame)(..._i)},cancelAnimationFrame(..._i){const{delegate:Qn}=Q;return(Qn?.cancelAnimationFrame||cancelAnimationFrame)(..._i)},delegate:void 0};function Ee(_i){return _i?he(_i):q}function he(_i){return new i.c(Qn=>{const qi=_i||X,Di=qi.now();let fo=0;const Uo=()=>{Qn.closed||(fo=Q.requestAnimationFrame(Gs=>{fo=0;const ba=qi.now();Qn.next({timestamp:_i?ba:Gs,elapsed:ba-Di}),Uo()}))};return Uo(),()=>{fo&&Q.cancelAnimationFrame(fo)}})}const q=he();var oe=S(8530),Z=S(4412),ce=S(2771),le=S(7876),je=S(6780);let wt,Et=1;const ve={};function fn(_i){return _i in ve&&(delete ve[_i],!0)}const ct={setImmediate(_i){const Qn=Et++;return ve[Qn]=!0,wt||(wt=Promise.resolve()),wt.then(()=>fn(Qn)&&_i()),Qn},clearImmediate(_i){fn(_i)}},{setImmediate:an,clearImmediate:un}=ct,vn={setImmediate(..._i){const{delegate:Qn}=vn;return(Qn?.setImmediate||an)(..._i)},clearImmediate(_i){const{delegate:Qn}=vn;return(Qn?.clearImmediate||un)(_i)},delegate:void 0};var Ae=S(707);const ut=new class dt extends Ae.q{flush(Qn){this._active=!0;const qi=this._scheduled;this._scheduled=void 0;const{actions:Di}=this;let fo;Qn=Qn||Di.shift();do{if(fo=Qn.execute(Qn.state,Qn.delay))break}while((Qn=Di[0])&&Qn.id===qi&&Di.shift());if(this._active=!1,fo){for(;(Qn=Di[0])&&Qn.id===qi&&Di.shift();)Qn.unsubscribe();throw fo}}}(class Pt extends je.R{constructor(Qn,qi){super(Qn,qi),this.scheduler=Qn,this.work=qi}requestAsyncId(Qn,qi,Di=0){return null!==Di&&Di>0?super.requestAsyncId(Qn,qi,Di):(Qn.actions.push(this),Qn._scheduled||(Qn._scheduled=vn.setImmediate(Qn.flush.bind(Qn,void 0))))}recycleAsyncId(Qn,qi,Di=0){var fo;if(null!=Di?Di>0:this.delay>0)return super.recycleAsyncId(Qn,qi,Di);const{actions:Uo}=Qn;null!=qi&&(null===(fo=Uo[Uo.length-1])||void 0===fo?void 0:fo.id)!==qi&&(vn.clearImmediate(qi),Qn._scheduled===qi&&(Qn._scheduled=void 0))}}),Mt=ut;var Wt=S(3236);const pn=new class Vn extends Ae.q{}(class It extends je.R{constructor(Qn,qi){super(Qn,qi),this.scheduler=Qn,this.work=qi}schedule(Qn,qi=0){return qi>0?super.schedule(Qn,qi):(this.delay=qi,this.state=Qn,this.scheduler.flush(this),this)}execute(Qn,qi){return qi>0||this.closed?super.execute(Qn,qi):this._execute(Qn,qi)}requestAsyncId(Qn,qi,Di=0){return null!=Di&&Di>0||null==Di&&this.delay>0?super.requestAsyncId(Qn,qi,Di):(Qn.flush(this),0)}}),Wn=pn,St=new class An extends Ae.q{flush(Qn){this._active=!0;const qi=this._scheduled;this._scheduled=void 0;const{actions:Di}=this;let fo;Qn=Qn||Di.shift();do{if(fo=Qn.execute(Qn.state,Qn.delay))break}while((Qn=Di[0])&&Qn.id===qi&&Di.shift());if(this._active=!1,fo){for(;(Qn=Di[0])&&Qn.id===qi&&Di.shift();)Qn.unsubscribe();throw fo}}}(class ji extends je.R{constructor(Qn,qi){super(Qn,qi),this.scheduler=Qn,this.work=qi}requestAsyncId(Qn,qi,Di=0){return null!==Di&&Di>0?super.requestAsyncId(Qn,qi,Di):(Qn.actions.push(this),Qn._scheduled||(Qn._scheduled=Q.requestAnimationFrame(()=>Qn.flush(void 0))))}recycleAsyncId(Qn,qi,Di=0){var fo;if(null!=Di?Di>0:this.delay>0)return super.recycleAsyncId(Qn,qi,Di);const{actions:Uo}=Qn;null!=qi&&(null===(fo=Uo[Uo.length-1])||void 0===fo?void 0:fo.id)!==qi&&(Q.cancelAnimationFrame(qi),Qn._scheduled=void 0)}}),qt=St;let Ht=(()=>{class _i extends Ae.q{constructor(qi=on,Di=1/0){super(qi,()=>this.frame),this.maxFrames=Di,this.frame=0,this.index=-1}flush(){const{actions:qi,maxFrames:Di}=this;let fo,Uo;for(;(Uo=qi[0])&&Uo.delay<=Di&&(qi.shift(),this.frame=Uo.delay,!(fo=Uo.execute(Uo.state,Uo.delay))););if(fo){for(;Uo=qi.shift();)Uo.unsubscribe();throw fo}}}return _i.frameTimeFactor=10,_i})();class on extends je.R{constructor(Qn,qi,Di=(Qn.index+=1)){super(Qn,qi),this.scheduler=Qn,this.work=qi,this.index=Di,this.active=!0,this.index=Qn.index=Di}schedule(Qn,qi=0){if(Number.isFinite(qi)){if(!this.id)return super.schedule(Qn,qi);this.active=!1;const Di=new on(this.scheduler,this.work);return this.add(Di),Di.schedule(Qn,qi)}return ie.yU.EMPTY}requestAsyncId(Qn,qi,Di=0){this.delay=Qn.frame+Di;const{actions:fo}=Qn;return fo.push(this),fo.sort(on.sortActions),1}recycleAsyncId(Qn,qi,Di=0){}_execute(Qn,qi){if(!0===this.active)return super._execute(Qn,qi)}static sortActions(Qn,qi){return Qn.delay===qi.delay?Qn.index===qi.index?0:Qn.index>qi.index?1:-1:Qn.delay>qi.delay?1:-1}}var Cn=S(8399),tn=S(7707),fi=S(179),Zn=S(1203),Dn=S(5343),gn=S(3669),Nn=S(8071);function Yn(_i){return!!_i&&(_i instanceof i.c||(0,Nn.T)(_i.lift)&&(0,Nn.T)(_i.subscribe))}var cr=S(9350);function Ai(_i,Qn){const qi="object"==typeof Qn;return new Promise((Di,fo)=>{let Gs,Uo=!1;_i.subscribe({next:ba=>{Gs=ba,Uo=!0},error:fo,complete:()=>{Uo?Di(Gs):qi?Di(Qn.defaultValue):fo(new cr.G)}})})}function Qi(_i,Qn){const qi="object"==typeof Qn;return new Promise((Di,fo)=>{const Uo=new tn.Ms({next:Gs=>{Di(Gs),Uo.unsubscribe()},error:fo,complete:()=>{qi?Di(Qn.defaultValue):fo(new cr.G)}});_i.subscribe(Uo)})}var Xr=S(3886),Ur=S(9896),eo=S(9117),as=S(7517),uo=S(2087),mi=S(4079),ci=S(9470),yt=S(6745),hn=S(6450),Gt=S(941);function Gn(_i,Qn,qi,Di){if(qi){if(!(0,ci.m)(qi))return function(...fo){return Gn(_i,Qn,Di).apply(this,fo).pipe((0,hn.I)(qi))};Di=qi}return Di?function(...fo){return Gn(_i,Qn).apply(this,fo).pipe((0,yt._)(Di),(0,Gt.Q)(Di))}:function(...fo){const Uo=new le.h;let Gs=!0;return new i.c(ba=>{const Za=Uo.subscribe(ba);if(Gs){Gs=!1;let Ks=!1,ac=!1;Qn.apply(this,[...fo,(...lc)=>{if(_i){const ou=lc.shift();if(null!=ou)return void Uo.error(ou)}Uo.next(1<lc.length?lc:lc[0]),ac=!0,Ks&&Uo.complete()}]),ac&&Uo.complete(),Ks=!0}return Za})}}function ri(_i,Qn,qi){return Gn(!1,_i,Qn,qi)}function pi(_i,Qn,qi){return Gn(!0,_i,Qn,qi)}var At=S(4572),Bn=S(2688),Mn=S(8750);function ni(_i){return new i.c(Qn=>{(0,Mn.Tg)(_i()).subscribe(Qn)})}const qn={connector:()=>new oe.B,resetOnDisconnect:!0};function Ti(_i,Qn=qn){let qi=null;const{connector:Di,resetOnDisconnect:fo=!0}=Qn;let Uo=Di();const Gs=new i.c(ba=>Uo.subscribe(ba));return Gs.connect=()=>((!qi||qi.closed)&&(qi=ni(()=>_i).subscribe(Uo),fo&&qi.add(()=>Uo=Di())),qi),Gs}var Bi=S(983),Gi=S(3073),Ii=S(9326),Ki=S(4360),Jt=S(8496);function hi(..._i){const Qn=(0,Ii.ms)(_i),{args:qi,keys:Di}=(0,Gi.D)(_i),fo=new i.c(Uo=>{const{length:Gs}=qi;if(!Gs)return void Uo.complete();const ba=new Array(Gs);let Za=Gs,Ks=Gs;for(let ac=0;ac<Gs;ac++){let lc=!1;(0,Mn.Tg)(qi[ac]).subscribe((0,Ki._)(Uo,ou=>{lc||(lc=!0,Ks--),ba[ac]=ou},()=>Za--,void 0,()=>{(!Za||!lc)&&(Ks||Uo.next(Di?(0,Jt.e)(Di,ba):ba),Uo.complete())}))}});return Qn?fo.pipe((0,hn.I)(Qn)):fo}var Ft=S(9724),it=S(3028),sn=S(7441);const Ve=["addListener","removeListener"],He=["addEventListener","removeEventListener"],mt=["on","off"];function bt(_i,Qn,qi,Di){if((0,Nn.T)(qi)&&(Di=qi,qi=void 0),Di)return bt(_i,Qn,qi).pipe((0,hn.I)(Di));const[fo,Uo]=function _r(_i){return(0,Nn.T)(_i.addEventListener)&&(0,Nn.T)(_i.removeEventListener)}(_i)?He.map(Gs=>ba=>_i[Gs](Qn,ba,qi)):function Jn(_i){return(0,Nn.T)(_i.addListener)&&(0,Nn.T)(_i.removeListener)}(_i)?Ve.map(nn(_i,Qn)):function Sn(_i){return(0,Nn.T)(_i.on)&&(0,Nn.T)(_i.off)}(_i)?mt.map(nn(_i,Qn)):[];if(!fo&&(0,sn.X)(_i))return(0,it.Z)(Gs=>bt(Gs,Qn,qi))((0,Mn.Tg)(_i));if(!fo)throw new TypeError("Invalid event target");return new i.c(Gs=>{const ba=(...Za)=>Gs.next(1<Za.length?Za:Za[0]);return fo(ba),()=>Uo(ba)})}function nn(_i,Qn){return qi=>Di=>_i[qi](Qn,Di)}function qr(_i,Qn,qi){return qi?qr(_i,Qn).pipe((0,hn.I)(qi)):new i.c(Di=>{const fo=(...Gs)=>Di.next(1===Gs.length?Gs[0]:Gs),Uo=_i(fo);return(0,Nn.T)(Qn)?()=>Qn(fo,Uo):void 0})}var Bo=S(7119);function Eo(_i,Qn,qi,Di,fo){let Uo,Gs;function*ba(){for(let Za=Gs;!Qn||Qn(Za);Za=qi(Za))yield Uo(Za)}return 1===arguments.length?({initialState:Gs,condition:Qn,iterate:qi,resultSelector:Uo=gn.D,scheduler:fo}=_i):(Gs=_i,!Di||(0,ci.m)(Di)?(Uo=gn.D,fo=Di):Uo=Di),ni(fo?()=>(0,Bo.S)(ba(),fo):ba)}function Ro(_i,Qn,qi){return ni(()=>_i()?Qn:qi)}var Ls=S(605),ol=S(6365);function Va(..._i){const Qn=(0,Ii.lI)(_i),qi=(0,Ii.R0)(_i,1/0),Di=_i;return Di.length?1===Di.length?(0,Mn.Tg)(Di[0]):(0,ol.U)(qi)((0,Ft.H)(Di,Qn)):Bi.w}const Ao=new i.c(Dn.l);function za(){return Ao}var vl=S(7673),Na=S(5965);function _l(_i,Qn){return(0,Ft.H)(Object.entries(_i),Qn)}var gs=S(7442),Zs=S(5964);function oa(_i,Qn,qi){return[(0,Zs.p)(Qn,qi)((0,Mn.Tg)(_i)),(0,Zs.p)((0,gs.A)(Qn,qi))((0,Mn.Tg)(_i))]}var no=S(1033);function xl(_i,Qn,qi){if(null==Qn&&(Qn=_i,_i=0),Qn<=0)return Bi.w;const Di=Qn+_i;return new i.c(qi?fo=>{let Uo=_i;return qi.schedule(function(){Uo<Di?(fo.next(Uo++),this.schedule()):fo.complete()})}:fo=>{let Uo=_i;for(;Uo<Di&&!fo.closed;)fo.next(Uo++);fo.complete()})}var Qr=S(8810),dl=S(1807);function Ya(_i,Qn){return new i.c(qi=>{const Di=_i(),fo=Qn(Di);return(fo?(0,Mn.Tg)(fo):Bi.w).subscribe(qi),()=>{Di&&Di.unsubscribe()}})}var Lo=S(4437),ko=S(5894),jt=S(1026),In=S(5135),Rt=S(3578),jn=S(8968),Fi=S(6173),Ui=S(9445),ar=S(8004),er=S(4868),Or=S(9437),Tt=S(7906),cn=S(3295),Tn=S(1990),Ri=S(9131),Un=S(274),Yi=S(7671),Wi=S(3658),fr=S(2066),Li=S(4907),Vo=S(3229),vr=S(152),Mo=S(9901),ks=S(3103),Jo=S(3183),$s=S(5236),Js=S(2953),ds=S(3294),Ws=S(1765),es=S(9301),Ma=S(4697),ts=S(947),wo=S(3726),ea=S(9643),ga=S(786),sl=S(1546),fl=S(980),Ia=S(7677),al=S(7305),Kc=S(1594),wa=S(7002),Sl=S(3557),qc=S(6785),la=S(7018),pl=S(6354),Sc=S(3703),Ec=S(7021),Qc=S(5146),ql=S(8523),ec=S(9189),Yc=S(3489),ca=S(8412),Il=S(8084),Xa=S(354),Rl=S(1219),yl=S(3946),sa=S(9085),Lu=S(1927),Aa=S(3581),ku=S(5735),Ql=S(9348),sc=S(495),ta=S(9852),vc=S(7469),xu=S(3981),Fc=S(2498),po=S(1966),Ll=S(9898),Hs=S(6052),kl=S(5385),Nc=S(1943),fu=S(7743),Rc=S(7647),Ke=S(4668),Se=S(9338),re=S(5245),Ge=S(9769),xt=S(4493),Qt=S(8492),kn=S(9172),bi=S(7799),vi=S(5558),Ci=S(7083),Xi=S(4979),$i=S(6697),Er=S(5109),ai=S(6977),so=S(7048),Fr=S(8141),zr=S(3702),ho=S(7107),Vr=S(3774),is=S(9550),Ms=S(3935),Ds=S(7232),Xo=S(6594),na=S(3438),zs=S(5355),ya=S(1371),Je=S(3182),at=S(4722),Oe=S(3993),Ct=S(1828),On=S(163)},7876:(Ot,Me,S)=>{S.d(Me,{h:()=>e});var i=S(8530);class e extends i.B{constructor(){super(...arguments),this._value=null,this._hasValue=!1,this._isComplete=!1}_checkFinalizedStatuses(X){const{hasError:ie,_hasValue:Q,_value:Ee,thrownError:he,isStopped:q,_isComplete:oe}=this;ie?X.error(he):(q||oe)&&(Q&&X.next(Ee),X.complete())}next(X){this.isStopped||(this._value=X,this._hasValue=!0)}complete(){const{_hasValue:X,_value:ie,_isComplete:Q}=this;Q||(this._isComplete=!0,X&&super.next(ie),super.complete())}}},4412:(Ot,Me,S)=>{S.d(Me,{t:()=>e});var i=S(8530);class e extends i.B{constructor(X){super(),this._value=X}get value(){return this.getValue()}_subscribe(X){const ie=super._subscribe(X);return!ie.closed&&X.next(this._value),ie}getValue(){const{hasError:X,thrownError:ie,_value:Q}=this;if(X)throw ie;return this._throwIfClosed(),Q}next(X){super.next(this._value=X)}}},179:(Ot,Me,S)=>{S.d(Me,{Eg:()=>Q,Ij:()=>ie,gV:()=>Ee});var i=S(983),e=S(7673),M=S(8810),X=S(8071),ie=function(he){return he.NEXT="N",he.ERROR="E",he.COMPLETE="C",he}(ie||{});class Q{constructor(q,oe,Z){this.kind=q,this.value=oe,this.error=Z,this.hasValue="N"===q}observe(q){return Ee(this,q)}do(q,oe,Z){const{kind:ce,value:le,error:je}=this;return"N"===ce?q?.(le):"E"===ce?oe?.(je):Z?.()}accept(q,oe,Z){var ce;return(0,X.T)(null===(ce=q)||void 0===ce?void 0:ce.next)?this.observe(q):this.do(q,oe,Z)}toObservable(){const{kind:q,value:oe,error:Z}=this,ce="N"===q?(0,e.of)(oe):"E"===q?(0,M.$)(()=>Z):"C"===q?i.w:0;if(!ce)throw new TypeError(`Unexpected notification kind ${q}`);return ce}static createNext(q){return new Q("N",q)}static createError(q){return new Q("E",void 0,q)}static createComplete(){return Q.completeNotification}}function Ee(he,q){var oe,Z,ce;const{kind:le,value:je,error:Et}=he;if("string"!=typeof le)throw new TypeError('Invalid notification, missing "kind"');"N"===le?null===(oe=q.next)||void 0===oe||oe.call(q,je):"E"===le?null===(Z=q.error)||void 0===Z||Z.call(q,Et):null===(ce=q.complete)||void 0===ce||ce.call(q)}Q.completeNotification=new Q("C")},1985:(Ot,Me,S)=>{S.d(Me,{c:()=>he});var i=S(7707),e=S(3961),M=S(3494),X=S(1203),ie=S(1026),Q=S(8071),Ee=S(9786);let he=(()=>{class ce{constructor(je){je&&(this._subscribe=je)}lift(je){const Et=new ce;return Et.source=this,Et.operator=je,Et}subscribe(je,Et,wt){const ve=function Z(ce){return ce&&ce instanceof i.vU||function oe(ce){return ce&&(0,Q.T)(ce.next)&&(0,Q.T)(ce.error)&&(0,Q.T)(ce.complete)}(ce)&&(0,e.Uv)(ce)}(je)?je:new i.Ms(je,Et,wt);return(0,Ee.Y)(()=>{const{operator:fn,source:ct}=this;ve.add(fn?fn.call(ve,ct):ct?this._subscribe(ve):this._trySubscribe(ve))}),ve}_trySubscribe(je){try{return this._subscribe(je)}catch(Et){je.error(Et)}}forEach(je,Et){return new(Et=q(Et))((wt,ve)=>{const fn=new i.Ms({next:ct=>{try{je(ct)}catch(en){ve(en),fn.unsubscribe()}},error:ve,complete:wt});this.subscribe(fn)})}_subscribe(je){var Et;return null===(Et=this.source)||void 0===Et?void 0:Et.subscribe(je)}[M.s](){return this}pipe(...je){return(0,X.m)(je)(this)}toPromise(je){return new(je=q(je))((Et,wt)=>{let ve;this.subscribe(fn=>ve=fn,fn=>wt(fn),()=>Et(ve))})}}return ce.create=le=>new ce(le),ce})();function q(ce){var le;return null!==(le=ce??ie.$.Promise)&&void 0!==le?le:Promise}},2771:(Ot,Me,S)=>{S.d(Me,{m:()=>M});var i=S(8530),e=S(6129);class M extends i.B{constructor(ie=1/0,Q=1/0,Ee=e.U){super(),this._bufferSize=ie,this._windowTime=Q,this._timestampProvider=Ee,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=Q===1/0,this._bufferSize=Math.max(1,ie),this._windowTime=Math.max(1,Q)}next(ie){const{isStopped:Q,_buffer:Ee,_infiniteTimeWindow:he,_timestampProvider:q,_windowTime:oe}=this;Q||(Ee.push(ie),!he&&Ee.push(q.now()+oe)),this._trimBuffer(),super.next(ie)}_subscribe(ie){this._throwIfClosed(),this._trimBuffer();const Q=this._innerSubscribe(ie),{_infiniteTimeWindow:Ee,_buffer:he}=this,q=he.slice();for(let oe=0;oe<q.length&&!ie.closed;oe+=Ee?1:2)ie.next(q[oe]);return this._checkFinalizedStatuses(ie),Q}_trimBuffer(){const{_bufferSize:ie,_timestampProvider:Q,_buffer:Ee,_infiniteTimeWindow:he}=this,q=(he?1:2)*ie;if(ie<1/0&&q<Ee.length&&Ee.splice(0,Ee.length-q),!he){const oe=Q.now();let Z=0;for(let ce=1;ce<Ee.length&&Ee[ce]<=oe;ce+=2)Z=ce;Z&&Ee.splice(0,Z+1)}}}},8399:(Ot,Me,S)=>{S.d(Me,{_:()=>e});var i=S(6129);class e{constructor(X,ie=e.now){this.schedulerActionCtor=X,this.now=ie}schedule(X,ie=0,Q){return new this.schedulerActionCtor(this,X).schedule(Q,ie)}}e.now=i.U.now},8530:(Ot,Me,S)=>{S.d(Me,{B:()=>Q});var i=S(1985),e=S(3961),M=S(9117),X=S(7908),ie=S(9786);let Q=(()=>{class he extends i.c{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(oe){const Z=new Ee(this,this);return Z.operator=oe,Z}_throwIfClosed(){if(this.closed)throw new M.P}next(oe){(0,ie.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const Z of this.currentObservers)Z.next(oe)}})}error(oe){(0,ie.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=oe;const{observers:Z}=this;for(;Z.length;)Z.shift().error(oe)}})}complete(){(0,ie.Y)(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:oe}=this;for(;oe.length;)oe.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var oe;return(null===(oe=this.observers)||void 0===oe?void 0:oe.length)>0}_trySubscribe(oe){return this._throwIfClosed(),super._trySubscribe(oe)}_subscribe(oe){return this._throwIfClosed(),this._checkFinalizedStatuses(oe),this._innerSubscribe(oe)}_innerSubscribe(oe){const{hasError:Z,isStopped:ce,observers:le}=this;return Z||ce?e.Kn:(this.currentObservers=null,le.push(oe),new e.yU(()=>{this.currentObservers=null,(0,X.o)(le,oe)}))}_checkFinalizedStatuses(oe){const{hasError:Z,thrownError:ce,isStopped:le}=this;Z?oe.error(ce):le&&oe.complete()}asObservable(){const oe=new i.c;return oe.source=this,oe}}return he.create=(q,oe)=>new Ee(q,oe),he})();class Ee extends Q{constructor(q,oe){super(),this.destination=q,this.source=oe}next(q){var oe,Z;null===(Z=null===(oe=this.destination)||void 0===oe?void 0:oe.next)||void 0===Z||Z.call(oe,q)}error(q){var oe,Z;null===(Z=null===(oe=this.destination)||void 0===oe?void 0:oe.error)||void 0===Z||Z.call(oe,q)}complete(){var q,oe;null===(oe=null===(q=this.destination)||void 0===q?void 0:q.complete)||void 0===oe||oe.call(q)}_subscribe(q){var oe,Z;return null!==(Z=null===(oe=this.source)||void 0===oe?void 0:oe.subscribe(q))&&void 0!==Z?Z:e.Kn}}},7707:(Ot,Me,S)=>{S.d(Me,{Ms:()=>wt,vU:()=>ce});var i=S(8071),e=S(3961),M=S(1026),X=S(5334),ie=S(5343);const Q=q("C",void 0,void 0);function q(an,un,vn){return{kind:an,value:un,error:vn}}var oe=S(9270),Z=S(9786);class ce extends e.yU{constructor(un){super(),this.isStopped=!1,un?(this.destination=un,(0,e.Uv)(un)&&un.add(this)):this.destination=en}static create(un,vn,Pt){return new wt(un,vn,Pt)}next(un){this.isStopped?ct(function he(an){return q("N",an,void 0)}(un),this):this._next(un)}error(un){this.isStopped?ct(function Ee(an){return q("E",void 0,an)}(un),this):(this.isStopped=!0,this._error(un))}complete(){this.isStopped?ct(Q,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(un){this.destination.next(un)}_error(un){try{this.destination.error(un)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const le=Function.prototype.bind;function je(an,un){return le.call(an,un)}class Et{constructor(un){this.partialObserver=un}next(un){const{partialObserver:vn}=this;if(vn.next)try{vn.next(un)}catch(Pt){ve(Pt)}}error(un){const{partialObserver:vn}=this;if(vn.error)try{vn.error(un)}catch(Pt){ve(Pt)}else ve(un)}complete(){const{partialObserver:un}=this;if(un.complete)try{un.complete()}catch(vn){ve(vn)}}}class wt extends ce{constructor(un,vn,Pt){let Ae;if(super(),(0,i.T)(un)||!un)Ae={next:un??void 0,error:vn??void 0,complete:Pt??void 0};else{let dt;this&&M.$.useDeprecatedNextContext?(dt=Object.create(un),dt.unsubscribe=()=>this.unsubscribe(),Ae={next:un.next&&je(un.next,dt),error:un.error&&je(un.error,dt),complete:un.complete&&je(un.complete,dt)}):Ae=un}this.destination=new Et(Ae)}}function ve(an){M.$.useDeprecatedSynchronousErrorHandling?(0,Z.l)(an):(0,X.m)(an)}function ct(an,un){const{onStoppedNotification:vn}=M.$;vn&&oe.f.setTimeout(()=>vn(an,un))}const en={closed:!0,next:ie.l,error:function fn(an){throw an},complete:ie.l}},3961:(Ot,Me,S)=>{S.d(Me,{Kn:()=>ie,Uv:()=>Q,yU:()=>X});var i=S(8071),e=S(4079),M=S(7908);class X{constructor(q){this.initialTeardown=q,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let q;if(!this.closed){this.closed=!0;const{_parentage:oe}=this;if(oe)if(this._parentage=null,Array.isArray(oe))for(const le of oe)le.remove(this);else oe.remove(this);const{initialTeardown:Z}=this;if((0,i.T)(Z))try{Z()}catch(le){q=le instanceof e.Z?le.errors:[le]}const{_finalizers:ce}=this;if(ce){this._finalizers=null;for(const le of ce)try{Ee(le)}catch(je){q=q??[],je instanceof e.Z?q=[...q,...je.errors]:q.push(je)}}if(q)throw new e.Z(q)}}add(q){var oe;if(q&&q!==this)if(this.closed)Ee(q);else{if(q instanceof X){if(q.closed||q._hasParent(this))return;q._addParent(this)}(this._finalizers=null!==(oe=this._finalizers)&&void 0!==oe?oe:[]).push(q)}}_hasParent(q){const{_parentage:oe}=this;return oe===q||Array.isArray(oe)&&oe.includes(q)}_addParent(q){const{_parentage:oe}=this;this._parentage=Array.isArray(oe)?(oe.push(q),oe):oe?[oe,q]:q}_removeParent(q){const{_parentage:oe}=this;oe===q?this._parentage=null:Array.isArray(oe)&&(0,M.o)(oe,q)}remove(q){const{_finalizers:oe}=this;oe&&(0,M.o)(oe,q),q instanceof X&&q._removeParent(this)}}X.EMPTY=(()=>{const he=new X;return he.closed=!0,he})();const ie=X.EMPTY;function Q(he){return he instanceof X||he&&"closed"in he&&(0,i.T)(he.remove)&&(0,i.T)(he.add)&&(0,i.T)(he.unsubscribe)}function Ee(he){(0,i.T)(he)?he():he.unsubscribe()}},1026:(Ot,Me,S)=>{S.d(Me,{$:()=>i});const i={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1}},17:(Ot,Me,S)=>{S.d(Me,{G:()=>Q});var i=S(1985),e=S(3961),M=S(9898),X=S(4360),ie=S(9974);class Q extends i.c{constructor(he,q){super(),this.source=he,this.subjectFactory=q,this._subject=null,this._refCount=0,this._connection=null,(0,ie.S)(he)&&(this.lift=he.lift)}_subscribe(he){return this.getSubject().subscribe(he)}getSubject(){const he=this._subject;return(!he||he.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;const{_connection:he}=this;this._subject=this._connection=null,he?.unsubscribe()}connect(){let he=this._connection;if(!he){he=this._connection=new e.yU;const q=this.getSubject();he.add(this.source.subscribe((0,X._)(q,void 0,()=>{this._teardown(),q.complete()},oe=>{this._teardown(),q.error(oe)},()=>this._teardown()))),he.closed&&(this._connection=null,he=e.yU.EMPTY)}return he}refCount(){return(0,M.B)()(this)}}},4572:(Ot,Me,S)=>{S.d(Me,{P:()=>Z,z:()=>oe});var i=S(1985),e=S(3073),M=S(9724),X=S(3669),ie=S(6450),Q=S(9326),Ee=S(8496),he=S(4360),q=S(5225);function oe(...le){const je=(0,Q.lI)(le),Et=(0,Q.ms)(le),{args:wt,keys:ve}=(0,e.D)(le);if(0===wt.length)return(0,M.H)([],je);const fn=new i.c(Z(wt,je,ve?ct=>(0,Ee.e)(ve,ct):X.D));return Et?fn.pipe((0,ie.I)(Et)):fn}function Z(le,je,Et=X.D){return wt=>{ce(je,()=>{const{length:ve}=le,fn=new Array(ve);let ct=ve,en=ve;for(let an=0;an<ve;an++)ce(je,()=>{const un=(0,M.H)(le[an],je);let vn=!1;un.subscribe((0,he._)(wt,Pt=>{fn[an]=Pt,vn||(vn=!0,en--),en||wt.next(Et(fn.slice()))},()=>{--ct||wt.complete()}))},wt)},wt)}}function ce(le,je,Et){le?(0,q.N)(Et,le,je):je()}},2688:(Ot,Me,S)=>{S.d(Me,{x:()=>X});var i=S(9131),e=S(9326),M=S(9724);function X(...ie){return(0,i.K)()((0,M.H)(ie,(0,e.lI)(ie)))}},983:(Ot,Me,S)=>{S.d(Me,{I:()=>M,w:()=>e});var i=S(1985);const e=new i.c(ie=>ie.complete());function M(ie){return ie?function X(ie){return new i.c(Q=>ie.schedule(()=>Q.complete()))}(ie):e}},9724:(Ot,Me,S)=>{S.d(Me,{H:()=>M});var i=S(5894),e=S(8750);function M(X,ie){return ie?(0,i.c)(X,ie):(0,e.Tg)(X)}},8750:(Ot,Me,S)=>{S.d(Me,{Tg:()=>le});var i=S(7798),e=S(7441),M=S(9858),X=S(1985),ie=S(5055),Q=S(7953),Ee=S(591),he=S(5397),q=S(5196),oe=S(8071),Z=S(5334),ce=S(3494);function le(an){if(an instanceof X.c)return an;if(null!=an){if((0,ie.l)(an))return function je(an){return new X.c(un=>{const vn=an[ce.s]();if((0,oe.T)(vn.subscribe))return vn.subscribe(un);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}(an);if((0,e.X)(an))return function Et(an){return new X.c(un=>{for(let vn=0;vn<an.length&&!un.closed;vn++)un.next(an[vn]);un.complete()})}(an);if((0,M.y)(an))return function wt(an){return new X.c(un=>{an.then(vn=>{un.closed||(un.next(vn),un.complete())},vn=>un.error(vn)).then(null,Z.m)})}(an);if((0,Q.T)(an))return fn(an);if((0,he.x)(an))return function ve(an){return new X.c(un=>{for(const vn of an)if(un.next(vn),un.closed)return;un.complete()})}(an);if((0,q.U)(an))return function ct(an){return fn((0,q.C)(an))}(an)}throw(0,Ee.L)(an)}function fn(an){return new X.c(un=>{(function en(an,un){var vn,Pt,Ae,dt;return(0,i.sH)(this,void 0,void 0,function*(){try{for(vn=(0,i.xN)(an);!(Pt=yield vn.next()).done;)if(un.next(Pt.value),un.closed)return}catch(ut){Ae={error:ut}}finally{try{Pt&&!Pt.done&&(dt=vn.return)&&(yield dt.call(vn))}finally{if(Ae)throw Ae.error}}un.complete()})})(an,un).catch(vn=>un.error(vn))})}},605:(Ot,Me,S)=>{S.d(Me,{Y:()=>M});var i=S(3236),e=S(1807);function M(X=0,ie=i.E){return X<0&&(X=0),(0,e.O)(X,X,ie)}},7673:(Ot,Me,S)=>{S.d(Me,{of:()=>M});var i=S(9326),e=S(9724);function M(...X){const ie=(0,i.lI)(X);return(0,e.H)(X,ie)}},5965:(Ot,Me,S)=>{S.d(Me,{g:()=>Q});var i=S(1985),e=S(2326),M=S(4360),X=S(5343),ie=S(8750);function Q(...Ee){const he=(0,e.K)(Ee);return new i.c(q=>{let oe=0;const Z=()=>{if(oe<he.length){let ce;try{ce=(0,ie.Tg)(he[oe++])}catch{return void Z()}const le=new M.H(q,void 0,X.l,X.l);ce.subscribe(le),le.add(Z)}else q.complete()};Z()})}},1033:(Ot,Me,S)=>{S.d(Me,{O:()=>ie,w:()=>Q});var i=S(1985),e=S(8750),M=S(2326),X=S(4360);function ie(...Ee){return 1===(Ee=(0,M.K)(Ee)).length?(0,e.Tg)(Ee[0]):new i.c(Q(Ee))}function Q(Ee){return he=>{let q=[];for(let oe=0;q&&!he.closed&&oe<Ee.length;oe++)q.push((0,e.Tg)(Ee[oe]).subscribe((0,X._)(he,Z=>{if(q){for(let ce=0;ce<q.length;ce++)ce!==oe&&q[ce].unsubscribe();q=null}he.next(Z)})))}}},8810:(Ot,Me,S)=>{S.d(Me,{$:()=>M});var i=S(1985),e=S(8071);function M(X,ie){const Q=(0,e.T)(X)?X:()=>X,Ee=he=>he.error(Q());return new i.c(ie?he=>ie.schedule(Ee,0,he):Ee)}},1807:(Ot,Me,S)=>{S.d(Me,{O:()=>ie});var i=S(1985),e=S(3236),M=S(9470),X=S(8211);function ie(Q=0,Ee,he=e.b){let q=-1;return null!=Ee&&((0,M.m)(Ee)?he=Ee:q=Ee),new i.c(oe=>{let Z=(0,X.v)(Q)?+Q-he.now():Q;Z<0&&(Z=0);let ce=0;return he.schedule(function(){oe.closed||(oe.next(ce++),0<=q?this.schedule(void 0,q):oe.complete())},Z)})}},4437:(Ot,Me,S)=>{S.d(Me,{y:()=>Ee});var i=S(1985),e=S(8750),M=S(2326),X=S(983),ie=S(4360),Q=S(9326);function Ee(...he){const q=(0,Q.ms)(he),oe=(0,M.K)(he);return oe.length?new i.c(Z=>{let ce=oe.map(()=>[]),le=oe.map(()=>!1);Z.add(()=>{ce=le=null});for(let je=0;!Z.closed&&je<oe.length;je++)(0,e.Tg)(oe[je]).subscribe((0,ie._)(Z,Et=>{if(ce[je].push(Et),ce.every(wt=>wt.length)){const wt=ce.map(ve=>ve.shift());Z.next(q?q(...wt):wt),ce.some((ve,fn)=>!ve.length&&le[fn])&&Z.complete()}},()=>{le[je]=!0,!ce[je].length&&Z.complete()}));return()=>{ce=le=null}}):X.w}},4360:(Ot,Me,S)=>{S.d(Me,{H:()=>M,_:()=>e});var i=S(7707);function e(X,ie,Q,Ee,he){return new M(X,ie,Q,Ee,he)}class M extends i.vU{constructor(ie,Q,Ee,he,q,oe){super(ie),this.onFinalize=q,this.shouldUnsubscribe=oe,this._next=Q?function(Z){try{Q(Z)}catch(ce){ie.error(ce)}}:super._next,this._error=he?function(Z){try{he(Z)}catch(ce){ie.error(ce)}finally{this.unsubscribe()}}:super._error,this._complete=Ee?function(){try{Ee()}catch(Z){ie.error(Z)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var ie;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:Q}=this;super.unsubscribe(),!Q&&(null===(ie=this.onFinalize)||void 0===ie||ie.call(this))}}}},5135:(Ot,Me,S)=>{S.d(Me,{s:()=>X});var i=S(9974),e=S(8750),M=S(4360);function X(ie){return(0,i.N)((Q,Ee)=>{let he=!1,q=null,oe=null,Z=!1;const ce=()=>{if(oe?.unsubscribe(),oe=null,he){he=!1;const je=q;q=null,Ee.next(je)}Z&&Ee.complete()},le=()=>{oe=null,Z&&Ee.complete()};Q.subscribe((0,M._)(Ee,je=>{he=!0,q=je,oe||(0,e.Tg)(ie(je)).subscribe(oe=(0,M._)(Ee,ce,le))},()=>{Z=!0,(!he||!oe||oe.closed)&&Ee.complete()}))})}},3578:(Ot,Me,S)=>{S.d(Me,{Z:()=>X});var i=S(3236),e=S(5135),M=S(1807);function X(ie,Q=i.E){return(0,e.s)(()=>(0,M.O)(ie,Q))}},8968:(Ot,Me,S)=>{S.d(Me,{r:()=>ie});var i=S(9974),e=S(5343),M=S(4360),X=S(8750);function ie(Q){return(0,i.N)((Ee,he)=>{let q=[];return Ee.subscribe((0,M._)(he,oe=>q.push(oe),()=>{he.next(q),he.complete()})),(0,X.Tg)(Q).subscribe((0,M._)(he,()=>{const oe=q;q=[],he.next(oe)},e.l)),()=>{q=null}})}},6173:(Ot,Me,S)=>{S.d(Me,{S:()=>X});var i=S(9974),e=S(4360),M=S(7908);function X(ie,Q=null){return Q=Q??ie,(0,i.N)((Ee,he)=>{let q=[],oe=0;Ee.subscribe((0,e._)(he,Z=>{let ce=null;oe++%Q==0&&q.push([]);for(const le of q)le.push(Z),ie<=le.length&&(ce=ce??[],ce.push(le));if(ce)for(const le of ce)(0,M.o)(q,le),he.next(le)},()=>{for(const Z of q)he.next(Z);he.complete()},void 0,()=>{q=null}))})}},9445:(Ot,Me,S)=>{S.d(Me,{w:()=>he});var i=S(3961),e=S(9974),M=S(4360),X=S(7908),ie=S(3236),Q=S(9326),Ee=S(5225);function he(q,...oe){var Z,ce;const le=null!==(Z=(0,Q.lI)(oe))&&void 0!==Z?Z:ie.E,je=null!==(ce=oe[0])&&void 0!==ce?ce:null,Et=oe[1]||1/0;return(0,e.N)((wt,ve)=>{let fn=[],ct=!1;const en=vn=>{const{buffer:Pt,subs:Ae}=vn;Ae.unsubscribe(),(0,X.o)(fn,vn),ve.next(Pt),ct&&an()},an=()=>{if(fn){const vn=new i.yU;ve.add(vn);const Ae={buffer:[],subs:vn};fn.push(Ae),(0,Ee.N)(vn,le,()=>en(Ae),q)}};null!==je&&je>=0?(0,Ee.N)(ve,le,an,je,!0):ct=!0,an();const un=(0,M._)(ve,vn=>{const Pt=fn.slice();for(const Ae of Pt){const{buffer:dt}=Ae;dt.push(vn),Et<=dt.length&&en(Ae)}},()=>{for(;fn?.length;)ve.next(fn.shift().buffer);un?.unsubscribe(),ve.complete(),ve.unsubscribe()},void 0,()=>fn=null);wt.subscribe(un)})}},8004:(Ot,Me,S)=>{S.d(Me,{H:()=>Ee});var i=S(3961),e=S(9974),M=S(8750),X=S(4360),ie=S(5343),Q=S(7908);function Ee(he,q){return(0,e.N)((oe,Z)=>{const ce=[];(0,M.Tg)(he).subscribe((0,X._)(Z,le=>{const je=[];ce.push(je);const Et=new i.yU;Et.add((0,M.Tg)(q(le)).subscribe((0,X._)(Z,()=>{(0,Q.o)(ce,je),Z.next(je),Et.unsubscribe()},ie.l)))},ie.l)),oe.subscribe((0,X._)(Z,le=>{for(const je of ce)je.push(le)},()=>{for(;ce.length>0;)Z.next(ce.shift());Z.complete()}))})}},4868:(Ot,Me,S)=>{S.d(Me,{n:()=>ie});var i=S(9974),e=S(5343),M=S(4360),X=S(8750);function ie(Q){return(0,i.N)((Ee,he)=>{let q=null,oe=null;const Z=()=>{oe?.unsubscribe();const ce=q;q=[],ce&&he.next(ce),(0,X.Tg)(Q()).subscribe(oe=(0,M._)(he,Z,e.l))};Z(),Ee.subscribe((0,M._)(he,ce=>q?.push(ce),()=>{q&&he.next(q),he.complete()},void 0,()=>q=oe=null))})}},9437:(Ot,Me,S)=>{S.d(Me,{W:()=>X});var i=S(8750),e=S(4360),M=S(9974);function X(ie){return(0,M.N)((Q,Ee)=>{let oe,he=null,q=!1;he=Q.subscribe((0,e._)(Ee,void 0,void 0,Z=>{oe=(0,i.Tg)(ie(Z,X(ie)(Q))),he?(he.unsubscribe(),he=null,oe.subscribe(Ee)):q=!0})),q&&(he.unsubscribe(),he=null,oe.subscribe(Ee))})}},7906:(Ot,Me,S)=>{S.d(Me,{p:()=>e});const e=S(3295).A},3802:(Ot,Me,S)=>{S.d(Me,{z:()=>Ee});var i=S(4572),e=S(9974),M=S(2326),X=S(6450),ie=S(1203),Q=S(9326);function Ee(...he){const q=(0,Q.ms)(he);return q?(0,ie.F)(Ee(...he),(0,X.I)(q)):(0,e.N)((oe,Z)=>{(0,i.P)([oe,...(0,M.K)(he)])(Z)})}},3295:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(4572),e=S(5265);function M(X){return(0,e.q)(i.z,X)}},1990:(Ot,Me,S)=>{S.d(Me,{v:()=>e});var i=S(3802);function e(...M){return(0,i.z)(...M)}},8814:(Ot,Me,S)=>{S.d(Me,{x:()=>ie});var i=S(9974),e=S(9131),M=S(9326),X=S(9724);function ie(...Q){const Ee=(0,M.lI)(Q);return(0,i.N)((he,q)=>{(0,e.K)()((0,X.H)([he,...Q],Ee)).subscribe(q)})}},9131:(Ot,Me,S)=>{S.d(Me,{K:()=>e});var i=S(6365);function e(){return(0,i.U)(1)}},274:(Ot,Me,S)=>{S.d(Me,{H:()=>M});var i=S(3028),e=S(8071);function M(X,ie){return(0,e.T)(ie)?(0,i.Z)(X,ie,1):(0,i.Z)(X,1)}},7671:(Ot,Me,S)=>{S.d(Me,{S:()=>M});var i=S(274),e=S(8071);function M(X,ie){return(0,e.T)(ie)?(0,i.H)(()=>X,ie):(0,i.H)(()=>X)}},3658:(Ot,Me,S)=>{S.d(Me,{$:()=>e});var i=S(8814);function e(...M){return(0,i.x)(...M)}},2066:(Ot,Me,S)=>{S.d(Me,{N:()=>Ee});var i=S(8530),e=S(8750),M=S(9974),X=S(1985);const Q={connector:()=>new i.B};function Ee(he,q=Q){const{connector:oe}=q;return(0,M.N)((Z,ce)=>{const le=oe();(0,e.Tg)(he(function ie(he){return new X.c(q=>he.subscribe(q))}(le))).subscribe(ce),ce.add(Z.subscribe(le))})}},4907:(Ot,Me,S)=>{S.d(Me,{U:()=>e});var i=S(9852);function e(M){return(0,i.T)((X,ie,Q)=>!M||M(ie,Q)?X+1:X,0)}},3229:(Ot,Me,S)=>{S.d(Me,{s:()=>ie});var i=S(9974),e=S(5343),M=S(4360),X=S(8750);function ie(Q){return(0,i.N)((Ee,he)=>{let q=!1,oe=null,Z=null;const ce=()=>{if(Z?.unsubscribe(),Z=null,q){q=!1;const le=oe;oe=null,he.next(le)}};Ee.subscribe((0,M._)(he,le=>{Z?.unsubscribe(),q=!0,oe=le,Z=(0,M._)(he,ce,e.l),(0,X.Tg)(Q(le)).subscribe(Z)},()=>{ce(),he.complete()},void 0,()=>{oe=Z=null}))})}},152:(Ot,Me,S)=>{S.d(Me,{B:()=>X});var i=S(3236),e=S(9974),M=S(4360);function X(ie,Q=i.E){return(0,e.N)((Ee,he)=>{let q=null,oe=null,Z=null;const ce=()=>{if(q){q.unsubscribe(),q=null;const je=oe;oe=null,he.next(je)}};function le(){const je=Z+ie,Et=Q.now();if(Et<je)return q=this.schedule(void 0,je-Et),void he.add(q);ce()}Ee.subscribe((0,M._)(he,je=>{oe=je,Z=Q.now(),q||(q=Q.schedule(le,ie),he.add(q))},()=>{ce(),he.complete()},void 0,()=>{oe=q=null}))})}},9901:(Ot,Me,S)=>{S.d(Me,{U:()=>M});var i=S(9974),e=S(4360);function M(X){return(0,i.N)((ie,Q)=>{let Ee=!1;ie.subscribe((0,e._)(Q,he=>{Ee=!0,Q.next(he)},()=>{Ee||Q.next(X),Q.complete()}))})}},3103:(Ot,Me,S)=>{S.d(Me,{c:()=>X});var i=S(3236),e=S(3183),M=S(1807);function X(ie,Q=i.E){const Ee=(0,M.O)(ie,Q);return(0,e.o)(()=>Ee)}},3183:(Ot,Me,S)=>{S.d(Me,{o:()=>Ee});var i=S(2688),e=S(6697),M=S(3557),X=S(3703),ie=S(3028),Q=S(8750);function Ee(he,q){return q?oe=>(0,i.x)(q.pipe((0,e.s)(1),(0,M.w)()),oe.pipe(Ee(he))):(0,ie.Z)((oe,Z)=>(0,Q.Tg)(he(oe,Z)).pipe((0,e.s)(1),(0,X.u)(oe)))}},5236:(Ot,Me,S)=>{S.d(Me,{Z:()=>X});var i=S(179),e=S(9974),M=S(4360);function X(){return(0,e.N)((ie,Q)=>{ie.subscribe((0,M._)(Q,Ee=>(0,i.gV)(Ee,Q)))})}},2953:(Ot,Me,S)=>{S.d(Me,{d:()=>ie});var i=S(9974),e=S(4360),M=S(5343),X=S(8750);function ie(Q,Ee){return(0,i.N)((he,q)=>{const oe=new Set;he.subscribe((0,e._)(q,Z=>{const ce=Q?Q(Z):Z;oe.has(ce)||(oe.add(ce),q.next(Z))})),Ee&&(0,X.Tg)(Ee).subscribe((0,e._)(q,()=>oe.clear(),M.l))})}},3294:(Ot,Me,S)=>{S.d(Me,{F:()=>X});var i=S(3669),e=S(9974),M=S(4360);function X(Q,Ee=i.D){return Q=Q??ie,(0,e.N)((he,q)=>{let oe,Z=!0;he.subscribe((0,M._)(q,ce=>{const le=Ee(ce);(Z||!Q(oe,le))&&(Z=!1,oe=le,q.next(ce))}))})}function ie(Q,Ee){return Q===Ee}},1765:(Ot,Me,S)=>{S.d(Me,{w:()=>e});var i=S(3294);function e(M,X){return(0,i.F)((ie,Q)=>X?X(ie[M],Q[M]):ie[M]===Q[M])}},9301:(Ot,Me,S)=>{S.d(Me,{s:()=>Q});var i=S(3886),e=S(5964),M=S(3774),X=S(9901),ie=S(6697);function Q(Ee,he){if(Ee<0)throw new i.k;const q=arguments.length>=2;return oe=>oe.pipe((0,e.p)((Z,ce)=>ce===Ee),(0,ie.s)(1),q?(0,X.U)(he):(0,M.v)(()=>new i.k))}},4697:(Ot,Me,S)=>{S.d(Me,{q:()=>M});var i=S(2688),e=S(7673);function M(...X){return ie=>(0,i.x)(ie,(0,e.of)(...X))}},947:(Ot,Me,S)=>{S.d(Me,{S:()=>M});var i=S(9974),e=S(4360);function M(X,ie){return(0,i.N)((Q,Ee)=>{let he=0;Q.subscribe((0,e._)(Ee,q=>{X.call(ie,q,he++,Q)||(Ee.next(!1),Ee.complete())},()=>{Ee.next(!0),Ee.complete()}))})}},3726:(Ot,Me,S)=>{S.d(Me,{B:()=>e});const e=S(9643).C},9643:(Ot,Me,S)=>{S.d(Me,{C:()=>M});var i=S(786),e=S(3669);function M(){return(0,i.p)(e.D)}},786:(Ot,Me,S)=>{S.d(Me,{p:()=>ie});var i=S(6354),e=S(8750),M=S(9974),X=S(4360);function ie(Q,Ee){return Ee?he=>he.pipe(ie((q,oe)=>(0,e.Tg)(Q(q,oe)).pipe((0,i.T)((Z,ce)=>Ee(q,Z,oe,ce))))):(0,M.N)((he,q)=>{let oe=0,Z=null,ce=!1;he.subscribe((0,X._)(q,le=>{Z||(Z=(0,X._)(q,void 0,()=>{Z=null,ce&&q.complete()}),(0,e.Tg)(Q(le,oe++)).subscribe(Z))},()=>{ce=!0,!Z&&q.complete()}))})}},1546:(Ot,Me,S)=>{S.d(Me,{f:()=>M});var i=S(9974),e=S(5412);function M(X,ie=1/0,Q){return ie=(ie||0)<1?1/0:ie,(0,i.N)((Ee,he)=>(0,e.h)(Ee,he,X,ie,void 0,!0,Q))}},5964:(Ot,Me,S)=>{S.d(Me,{p:()=>M});var i=S(9974),e=S(4360);function M(X,ie){return(0,i.N)((Q,Ee)=>{let he=0;Q.subscribe((0,e._)(Ee,q=>X.call(ie,q,he++)&&Ee.next(q)))})}},980:(Ot,Me,S)=>{S.d(Me,{j:()=>e});var i=S(9974);function e(M){return(0,i.N)((X,ie)=>{try{X.subscribe(ie)}finally{ie.add(M)}})}},7677:(Ot,Me,S)=>{S.d(Me,{I:()=>M,k:()=>X});var i=S(9974),e=S(4360);function M(ie,Q){return(0,i.N)(X(ie,Q,"value"))}function X(ie,Q,Ee){const he="index"===Ee;return(q,oe)=>{let Z=0;q.subscribe((0,e._)(oe,ce=>{const le=Z++;ie.call(Q,ce,le,q)&&(oe.next(he?le:ce),oe.complete())},()=>{oe.next(he?-1:void 0),oe.complete()}))}}},7305:(Ot,Me,S)=>{S.d(Me,{S:()=>M});var i=S(9974),e=S(7677);function M(X,ie){return(0,i.N)((0,e.k)(X,ie,"index"))}},1594:(Ot,Me,S)=>{S.d(Me,{$:()=>Ee});var i=S(9350),e=S(5964),M=S(6697),X=S(9901),ie=S(3774),Q=S(3669);function Ee(he,q){const oe=arguments.length>=2;return Z=>Z.pipe(he?(0,e.p)((ce,le)=>he(ce,le,Z)):Q.D,(0,M.s)(1),oe?(0,X.U)(q):(0,ie.v)(()=>new i.G))}},8523:(Ot,Me,S)=>{S.d(Me,{q:()=>e});const e=S(3028).Z},7002:(Ot,Me,S)=>{S.d(Me,{$:()=>Q});var i=S(1985),e=S(8750),M=S(8530),X=S(9974),ie=S(4360);function Q(Ee,he,q,oe){return(0,X.N)((Z,ce)=>{let le;he&&"function"!=typeof he?({duration:q,element:le,connector:oe}=he):le=he;const je=new Map,Et=an=>{je.forEach(an),an(ce)},wt=an=>Et(un=>un.error(an));let ve=0,fn=!1;const ct=new ie.H(ce,an=>{try{const un=Ee(an);let vn=je.get(un);if(!vn){je.set(un,vn=oe?oe():new M.B);const Pt=function en(an,un){const vn=new i.c(Pt=>{ve++;const Ae=un.subscribe(Pt);return()=>{Ae.unsubscribe(),0==--ve&&fn&&ct.unsubscribe()}});return vn.key=an,vn}(un,vn);if(ce.next(Pt),q){const Ae=(0,ie._)(vn,()=>{vn.complete(),Ae?.unsubscribe()},void 0,void 0,()=>je.delete(un));ct.add((0,e.Tg)(q(Pt)).subscribe(Ae))}}vn.next(le?le(an):an)}catch(un){wt(un)}},()=>Et(an=>an.complete()),wt,()=>je.clear(),()=>(fn=!0,0===ve));Z.subscribe(ct)})}},3557:(Ot,Me,S)=>{S.d(Me,{w:()=>X});var i=S(9974),e=S(4360),M=S(5343);function X(){return(0,i.N)((ie,Q)=>{ie.subscribe((0,e._)(Q,M.l))})}},6785:(Ot,Me,S)=>{S.d(Me,{I:()=>M});var i=S(9974),e=S(4360);function M(){return(0,i.N)((X,ie)=>{X.subscribe((0,e._)(ie,()=>{ie.next(!1),ie.complete()},()=>{ie.next(!0),ie.complete()}))})}},5265:(Ot,Me,S)=>{S.d(Me,{q:()=>Q});var i=S(3669),e=S(6450),M=S(1203),X=S(3028),ie=S(6594);function Q(Ee,he){return(0,M.F)((0,ie.$)(),(0,X.Z)(q=>Ee(q)),he?(0,e.I)(he):i.D)}},7018:(Ot,Me,S)=>{S.d(Me,{H:()=>Ee});var i=S(9350),e=S(5964),M=S(5109),X=S(3774),ie=S(9901),Q=S(3669);function Ee(he,q){const oe=arguments.length>=2;return Z=>Z.pipe(he?(0,e.p)((ce,le)=>he(ce,le,Z)):Q.D,(0,M.o)(1),oe?(0,ie.U)(q):(0,X.v)(()=>new i.G))}},6354:(Ot,Me,S)=>{S.d(Me,{T:()=>M});var i=S(9974),e=S(4360);function M(X,ie){return(0,i.N)((Q,Ee)=>{let he=0;Q.subscribe((0,e._)(Ee,q=>{Ee.next(X.call(ie,q,he++))}))})}},3703:(Ot,Me,S)=>{S.d(Me,{u:()=>e});var i=S(6354);function e(M){return(0,i.T)(()=>M)}},7021:(Ot,Me,S)=>{S.d(Me,{O:()=>X});var i=S(179),e=S(9974),M=S(4360);function X(){return(0,e.N)((ie,Q)=>{ie.subscribe((0,M._)(Q,Ee=>{Q.next(i.Eg.createNext(Ee))},()=>{Q.next(i.Eg.createComplete()),Q.complete()},Ee=>{Q.next(i.Eg.createError(Ee)),Q.complete()}))})}},5146:(Ot,Me,S)=>{S.d(Me,{T:()=>M});var i=S(9852),e=S(8071);function M(X){return(0,i.T)((0,e.T)(X)?(ie,Q)=>X(ie,Q)>0?ie:Q:(ie,Q)=>ie>Q?ie:Q)}},1716:(Ot,Me,S)=>{S.d(Me,{h:()=>Q});var i=S(9974),e=S(2326),M=S(6365),X=S(9326),ie=S(9724);function Q(...Ee){const he=(0,X.lI)(Ee),q=(0,X.R0)(Ee,1/0);return Ee=(0,e.K)(Ee),(0,i.N)((oe,Z)=>{(0,M.U)(q)((0,ie.H)([oe,...Ee],he)).subscribe(Z)})}},6365:(Ot,Me,S)=>{S.d(Me,{U:()=>M});var i=S(3028),e=S(3669);function M(X=1/0){return(0,i.Z)(e.D,X)}},5412:(Ot,Me,S)=>{S.d(Me,{h:()=>X});var i=S(8750),e=S(5225),M=S(4360);function X(ie,Q,Ee,he,q,oe,Z,ce){const le=[];let je=0,Et=0,wt=!1;const ve=()=>{wt&&!le.length&&!je&&Q.complete()},fn=en=>je<he?ct(en):le.push(en),ct=en=>{oe&&Q.next(en),je++;let an=!1;(0,i.Tg)(Ee(en,Et++)).subscribe((0,M._)(Q,un=>{q?.(un),oe?fn(un):Q.next(un)},()=>{an=!0},void 0,()=>{if(an)try{for(je--;le.length&&je<he;){const un=le.shift();Z?(0,e.N)(Q,Z,()=>ct(un)):ct(un)}ve()}catch(un){Q.error(un)}}))};return ie.subscribe((0,M._)(Q,fn,()=>{wt=!0,ve()})),()=>{ce?.()}}},3028:(Ot,Me,S)=>{S.d(Me,{Z:()=>Q});var i=S(6354),e=S(8750),M=S(9974),X=S(5412),ie=S(8071);function Q(Ee,he,q=1/0){return(0,ie.T)(he)?Q((oe,Z)=>(0,i.T)((ce,le)=>he(oe,ce,Z,le))((0,e.Tg)(Ee(oe,Z))),q):("number"==typeof he&&(q=he),(0,M.N)((oe,Z)=>(0,X.h)(oe,Z,Ee,q)))}},9189:(Ot,Me,S)=>{S.d(Me,{C:()=>M});var i=S(3028),e=S(8071);function M(X,ie,Q=1/0){return(0,e.T)(ie)?(0,i.Z)(()=>X,ie,Q):("number"==typeof ie&&(Q=ie),(0,i.Z)(()=>X,Q))}},3489:(Ot,Me,S)=>{S.d(Me,{i:()=>M});var i=S(9974),e=S(5412);function M(X,ie,Q=1/0){return(0,i.N)((Ee,he)=>{let q=ie;return(0,e.h)(Ee,he,(oe,Z)=>X(q,oe,Z),Q,oe=>{q=oe},!1,void 0,()=>q=null)})}},8412:(Ot,Me,S)=>{S.d(Me,{X:()=>e});var i=S(1716);function e(...M){return(0,i.h)(...M)}},8084:(Ot,Me,S)=>{S.d(Me,{j:()=>M});var i=S(9852),e=S(8071);function M(X){return(0,i.T)((0,e.T)(X)?(ie,Q)=>X(ie,Q)<0?ie:Q:(ie,Q)=>ie<Q?ie:Q)}},354:(Ot,Me,S)=>{S.d(Me,{f:()=>X});var i=S(17),e=S(8071),M=S(2066);function X(ie,Q){const Ee=(0,e.T)(ie)?ie:()=>ie;return(0,e.T)(Q)?(0,M.N)(Q,{connector:Ee}):he=>new i.G(he,Ee)}},941:(Ot,Me,S)=>{S.d(Me,{Q:()=>X});var i=S(5225),e=S(9974),M=S(4360);function X(ie,Q=0){return(0,e.N)((Ee,he)=>{Ee.subscribe((0,M._)(he,q=>(0,i.N)(he,ie,()=>he.next(q),Q),()=>(0,i.N)(he,ie,()=>he.complete(),Q),q=>(0,i.N)(he,ie,()=>he.error(q),Q)))})}},1219:(Ot,Me,S)=>{S.d(Me,{g:()=>X,w:()=>M});var i=S(2326),e=S(5965);function M(...ie){const Q=(0,i.K)(ie);return Ee=>(0,e.g)(Ee,...Q)}const X=M},3946:(Ot,Me,S)=>{S.d(Me,{J:()=>M});var i=S(9974),e=S(4360);function M(){return(0,i.N)((X,ie)=>{let Q,Ee=!1;X.subscribe((0,e._)(ie,he=>{const q=Q;Q=he,Ee&&ie.next([q,he]),Ee=!0}))})}},9085:(Ot,Me,S)=>{S.d(Me,{E:()=>e});var i=S(6354);function e(...M){const X=M.length;if(0===X)throw new Error("list of properties cannot be empty.");return(0,i.T)(ie=>{let Q=ie;for(let Ee=0;Ee<X;Ee++){const he=Q?.[M[Ee]];if(!(typeof he<"u"))return;Q=he}return Q})}},1927:(Ot,Me,S)=>{S.d(Me,{m:()=>X});var i=S(8530),e=S(354),M=S(2066);function X(ie){return ie?Q=>(0,M.N)(ie)(Q):Q=>(0,e.f)(new i.B)(Q)}},3581:(Ot,Me,S)=>{S.d(Me,{K:()=>M});var i=S(4412),e=S(17);function M(X){return ie=>{const Q=new i.t(X);return new e.G(ie,()=>Q)}}},5735:(Ot,Me,S)=>{S.d(Me,{k:()=>M});var i=S(7876),e=S(17);function M(){return X=>{const ie=new i.h;return new e.G(X,()=>ie)}}},9348:(Ot,Me,S)=>{S.d(Me,{H:()=>X});var i=S(2771),e=S(354),M=S(8071);function X(ie,Q,Ee,he){Ee&&!(0,M.T)(Ee)&&(he=Ee);const q=(0,M.T)(Ee)?Ee:void 0;return oe=>(0,e.f)(new i.m(ie,Q,he),q)(oe)}},495:(Ot,Me,S)=>{S.d(Me,{w:()=>X});var i=S(1033),e=S(9974),M=S(3669);function X(...ie){return ie.length?(0,e.N)((Q,Ee)=>{(0,i.w)([Q,...ie])(Ee)}):M.D}},9852:(Ot,Me,S)=>{S.d(Me,{T:()=>M});var i=S(6649),e=S(9974);function M(X,ie){return(0,e.N)((0,i.S)(X,ie,arguments.length>=2,!1,!0))}},9898:(Ot,Me,S)=>{S.d(Me,{B:()=>M});var i=S(9974),e=S(4360);function M(){return(0,i.N)((X,ie)=>{let Q=null;X._refCount++;const Ee=(0,e._)(ie,void 0,void 0,void 0,()=>{if(!X||X._refCount<=0||0<--X._refCount)return void(Q=null);const he=X._connection,q=Q;Q=null,he&&(!q||he===q)&&he.unsubscribe(),ie.unsubscribe()});X.subscribe(Ee),Ee.closed||(Q=X.connect())})}},7469:(Ot,Me,S)=>{S.d(Me,{u:()=>Q});var i=S(983),e=S(9974),M=S(4360),X=S(8750),ie=S(1807);function Q(Ee){let q,he=1/0;return null!=Ee&&("object"==typeof Ee?({count:he=1/0,delay:q}=Ee):he=Ee),he<=0?()=>i.w:(0,e.N)((oe,Z)=>{let le,ce=0;const je=()=>{if(le?.unsubscribe(),le=null,null!=q){const wt="number"==typeof q?(0,ie.O)(q):(0,X.Tg)(q(ce)),ve=(0,M._)(Z,()=>{ve.unsubscribe(),Et()});wt.subscribe(ve)}else Et()},Et=()=>{let wt=!1;le=oe.subscribe((0,M._)(Z,void 0,()=>{++ce<he?le?je():wt=!0:Z.complete()})),wt&&je()};Et()})}},3981:(Ot,Me,S)=>{S.d(Me,{Y:()=>ie});var i=S(8750),e=S(8530),M=S(9974),X=S(4360);function ie(Q){return(0,M.N)((Ee,he)=>{let q,Z,oe=!1,ce=!1,le=!1;const je=()=>le&&ce&&(he.complete(),!0),wt=()=>{le=!1,q=Ee.subscribe((0,X._)(he,void 0,()=>{le=!0,!je()&&(Z||(Z=new e.B,(0,i.Tg)(Q(Z)).subscribe((0,X._)(he,()=>{q?wt():oe=!0},()=>{ce=!0,je()}))),Z).next()})),oe&&(q.unsubscribe(),q=null,oe=!1,wt())};wt()})}},2498:(Ot,Me,S)=>{S.d(Me,{L:()=>Q});var i=S(9974),e=S(4360),M=S(3669),X=S(1807),ie=S(8750);function Q(Ee=1/0){let he;he=Ee&&"object"==typeof Ee?Ee:{count:Ee};const{count:q=1/0,delay:oe,resetOnSuccess:Z=!1}=he;return q<=0?M.D:(0,i.N)((ce,le)=>{let Et,je=0;const wt=()=>{let ve=!1;Et=ce.subscribe((0,e._)(le,fn=>{Z&&(je=0),le.next(fn)},void 0,fn=>{if(je++<q){const ct=()=>{Et?(Et.unsubscribe(),Et=null,wt()):ve=!0};if(null!=oe){const en="number"==typeof oe?(0,X.O)(oe):(0,ie.Tg)(oe(fn,je)),an=(0,e._)(le,()=>{an.unsubscribe(),ct()},()=>{le.complete()});en.subscribe(an)}else ct()}else le.error(fn)})),ve&&(Et.unsubscribe(),Et=null,wt())};wt()})}},1966:(Ot,Me,S)=>{S.d(Me,{l:()=>ie});var i=S(8750),e=S(8530),M=S(9974),X=S(4360);function ie(Q){return(0,M.N)((Ee,he)=>{let q,Z,oe=!1;const ce=()=>{q=Ee.subscribe((0,X._)(he,void 0,void 0,le=>{Z||(Z=new e.B,(0,i.Tg)(Q(Z)).subscribe((0,X._)(he,()=>q?ce():oe=!0))),Z&&Z.next(le)})),oe&&(q.unsubscribe(),q=null,oe=!1,ce())};ce()})}},6052:(Ot,Me,S)=>{S.d(Me,{X:()=>ie});var i=S(8750),e=S(9974),M=S(5343),X=S(4360);function ie(Q){return(0,e.N)((Ee,he)=>{let q=!1,oe=null;Ee.subscribe((0,X._)(he,Z=>{q=!0,oe=Z})),(0,i.Tg)(Q).subscribe((0,X._)(he,()=>{if(q){q=!1;const Z=oe;oe=null,he.next(Z)}},M.l))})}},5385:(Ot,Me,S)=>{S.d(Me,{q:()=>X});var i=S(3236),e=S(6052),M=S(605);function X(ie,Q=i.E){return(0,e.X)((0,M.Y)(ie,Q))}},1943:(Ot,Me,S)=>{S.d(Me,{S:()=>M});var i=S(9974),e=S(6649);function M(X,ie){return(0,i.N)((0,e.S)(X,ie,arguments.length>=2,!0))}},6649:(Ot,Me,S)=>{S.d(Me,{S:()=>e});var i=S(4360);function e(M,X,ie,Q,Ee){return(he,q)=>{let oe=ie,Z=X,ce=0;he.subscribe((0,i._)(q,le=>{const je=ce++;Z=oe?M(Z,le,je):(oe=!0,le),Q&&q.next(Z)},Ee&&(()=>{oe&&q.next(Z),q.complete()})))}}},7743:(Ot,Me,S)=>{S.d(Me,{m:()=>X});var i=S(9974),e=S(4360),M=S(8750);function X(Q,Ee=(he,q)=>he===q){return(0,i.N)((he,q)=>{const oe={buffer:[],complete:!1},Z={buffer:[],complete:!1},ce=je=>{q.next(je),q.complete()},le=(je,Et)=>{const wt=(0,e._)(q,ve=>{const{buffer:fn,complete:ct}=Et;0===fn.length?ct?ce(!1):je.buffer.push(ve):!Ee(ve,fn.shift())&&ce(!1)},()=>{je.complete=!0;const{complete:ve,buffer:fn}=Et;ve&&ce(0===fn.length),wt?.unsubscribe()});return wt};he.subscribe(le(oe,Z)),(0,M.Tg)(Q).subscribe(le(Z,oe))})}},7647:(Ot,Me,S)=>{S.d(Me,{u:()=>ie});var i=S(8750),e=S(8530),M=S(7707),X=S(9974);function ie(Ee={}){const{connector:he=()=>new e.B,resetOnError:q=!0,resetOnComplete:oe=!0,resetOnRefCountZero:Z=!0}=Ee;return ce=>{let le,je,Et,wt=0,ve=!1,fn=!1;const ct=()=>{je?.unsubscribe(),je=void 0},en=()=>{ct(),le=Et=void 0,ve=fn=!1},an=()=>{const un=le;en(),un?.unsubscribe()};return(0,X.N)((un,vn)=>{wt++,!fn&&!ve&&ct();const Pt=Et=Et??he();vn.add(()=>{wt--,0===wt&&!fn&&!ve&&(je=Q(an,Z))}),Pt.subscribe(vn),!le&&wt>0&&(le=new M.Ms({next:Ae=>Pt.next(Ae),error:Ae=>{fn=!0,ct(),je=Q(en,q,Ae),Pt.error(Ae)},complete:()=>{ve=!0,ct(),je=Q(en,oe),Pt.complete()}}),(0,i.Tg)(un).subscribe(le))})(ce)}}function Q(Ee,he,...q){if(!0===he)return void Ee();if(!1===he)return;const oe=new M.Ms({next:()=>{oe.unsubscribe(),Ee()}});return(0,i.Tg)(he(...q)).subscribe(oe)}},4668:(Ot,Me,S)=>{S.d(Me,{t:()=>M});var i=S(2771),e=S(7647);function M(X,ie,Q){let Ee,he=!1;return X&&"object"==typeof X?({bufferSize:Ee=1/0,windowTime:ie=1/0,refCount:he=!1,scheduler:Q}=X):Ee=X??1/0,(0,e.u)({connector:()=>new i.m(Ee,ie,Q),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:he})}},9338:(Ot,Me,S)=>{S.d(Me,{J:()=>Q});var i=S(9350),e=S(7517),M=S(9896),X=S(9974),ie=S(4360);function Q(Ee){return(0,X.N)((he,q)=>{let Z,oe=!1,ce=!1,le=0;he.subscribe((0,ie._)(q,je=>{ce=!0,(!Ee||Ee(je,le++,he))&&(oe&&q.error(new e.I("Too many matching values")),oe=!0,Z=je)},()=>{oe?(q.next(Z),q.complete()):q.error(ce?new M.m("No matching values"):new i.G)}))})}},5245:(Ot,Me,S)=>{S.d(Me,{i:()=>e});var i=S(5964);function e(M){return(0,i.p)((X,ie)=>M<=ie)}},9769:(Ot,Me,S)=>{S.d(Me,{G:()=>X});var i=S(3669),e=S(9974),M=S(4360);function X(ie){return ie<=0?i.D:(0,e.N)((Q,Ee)=>{let he=new Array(ie),q=0;return Q.subscribe((0,M._)(Ee,oe=>{const Z=q++;if(Z<ie)he[Z]=oe;else{const ce=Z%ie,le=he[ce];he[ce]=oe,Ee.next(le)}})),()=>{he=null}})}},4493:(Ot,Me,S)=>{S.d(Me,{U:()=>ie});var i=S(9974),e=S(4360),M=S(8750),X=S(5343);function ie(Q){return(0,i.N)((Ee,he)=>{let q=!1;const oe=(0,e._)(he,()=>{oe?.unsubscribe(),q=!0},X.l);(0,M.Tg)(Q).subscribe(oe),Ee.subscribe((0,e._)(he,Z=>q&&he.next(Z)))})}},8492:(Ot,Me,S)=>{S.d(Me,{j:()=>M});var i=S(9974),e=S(4360);function M(X){return(0,i.N)((ie,Q)=>{let Ee=!1,he=0;ie.subscribe((0,e._)(Q,q=>(Ee||(Ee=!X(q,he++)))&&Q.next(q)))})}},9172:(Ot,Me,S)=>{S.d(Me,{Z:()=>X});var i=S(2688),e=S(9326),M=S(9974);function X(...ie){const Q=(0,e.lI)(ie);return(0,M.N)((Ee,he)=>{(Q?(0,i.x)(ie,Ee,Q):(0,i.x)(ie,Ee)).subscribe(he)})}},6745:(Ot,Me,S)=>{S.d(Me,{_:()=>e});var i=S(9974);function e(M,X=0){return(0,i.N)((ie,Q)=>{Q.add(M.schedule(()=>ie.subscribe(Q),X))})}},7799:(Ot,Me,S)=>{S.d(Me,{w:()=>M});var i=S(5558),e=S(3669);function M(){return(0,i.n)(e.D)}},5558:(Ot,Me,S)=>{S.d(Me,{n:()=>X});var i=S(8750),e=S(9974),M=S(4360);function X(ie,Q){return(0,e.N)((Ee,he)=>{let q=null,oe=0,Z=!1;const ce=()=>Z&&!q&&he.complete();Ee.subscribe((0,M._)(he,le=>{q?.unsubscribe();let je=0;const Et=oe++;(0,i.Tg)(ie(le,Et)).subscribe(q=(0,M._)(he,wt=>he.next(Q?Q(le,wt,Et,je++):wt),()=>{q=null,ce()}))},()=>{Z=!0,ce()}))})}},7083:(Ot,Me,S)=>{S.d(Me,{K:()=>M});var i=S(5558),e=S(8071);function M(X,ie){return(0,e.T)(ie)?(0,i.n)(()=>X,ie):(0,i.n)(()=>X)}},4979:(Ot,Me,S)=>{S.d(Me,{m:()=>M});var i=S(5558),e=S(9974);function M(X,ie){return(0,e.N)((Q,Ee)=>{let he=ie;return(0,i.n)((q,oe)=>X(he,q,oe),(q,oe)=>(he=oe,oe))(Q).subscribe(Ee),()=>{he=null}})}},6697:(Ot,Me,S)=>{S.d(Me,{s:()=>X});var i=S(983),e=S(9974),M=S(4360);function X(ie){return ie<=0?()=>i.w:(0,e.N)((Q,Ee)=>{let he=0;Q.subscribe((0,M._)(Ee,q=>{++he<=ie&&(Ee.next(q),ie<=he&&Ee.complete())}))})}},5109:(Ot,Me,S)=>{S.d(Me,{o:()=>X});var i=S(983),e=S(9974),M=S(4360);function X(ie){return ie<=0?()=>i.w:(0,e.N)((Q,Ee)=>{let he=[];Q.subscribe((0,M._)(Ee,q=>{he.push(q),ie<he.length&&he.shift()},()=>{for(const q of he)Ee.next(q);Ee.complete()},void 0,()=>{he=null}))})}},6977:(Ot,Me,S)=>{S.d(Me,{Q:()=>ie});var i=S(9974),e=S(4360),M=S(8750),X=S(5343);function ie(Q){return(0,i.N)((Ee,he)=>{(0,M.Tg)(Q).subscribe((0,e._)(he,()=>he.complete(),X.l)),!he.closed&&Ee.subscribe(he)})}},7048:(Ot,Me,S)=>{S.d(Me,{v:()=>M});var i=S(9974),e=S(4360);function M(X,ie=!1){return(0,i.N)((Q,Ee)=>{let he=0;Q.subscribe((0,e._)(Ee,q=>{const oe=X(q,he++);(oe||ie)&&Ee.next(q),!oe&&Ee.complete()}))})}},8141:(Ot,Me,S)=>{S.d(Me,{M:()=>ie});var i=S(8071),e=S(9974),M=S(4360),X=S(3669);function ie(Q,Ee,he){const q=(0,i.T)(Q)||Ee||he?{next:Q,error:Ee,complete:he}:Q;return q?(0,e.N)((oe,Z)=>{var ce;null===(ce=q.subscribe)||void 0===ce||ce.call(q);let le=!0;oe.subscribe((0,M._)(Z,je=>{var Et;null===(Et=q.next)||void 0===Et||Et.call(q,je),Z.next(je)},()=>{var je;le=!1,null===(je=q.complete)||void 0===je||je.call(q),Z.complete()},je=>{var Et;le=!1,null===(Et=q.error)||void 0===Et||Et.call(q,je),Z.error(je)},()=>{var je,Et;le&&(null===(je=q.unsubscribe)||void 0===je||je.call(q)),null===(Et=q.finalize)||void 0===Et||Et.call(q)}))}):X.D}},3702:(Ot,Me,S)=>{S.d(Me,{n:()=>X});var i=S(9974),e=S(4360),M=S(8750);function X(ie,Q){return(0,i.N)((Ee,he)=>{const{leading:q=!0,trailing:oe=!1}=Q??{};let Z=!1,ce=null,le=null,je=!1;const Et=()=>{le?.unsubscribe(),le=null,oe&&(fn(),je&&he.complete())},wt=()=>{le=null,je&&he.complete()},ve=ct=>le=(0,M.Tg)(ie(ct)).subscribe((0,e._)(he,Et,wt)),fn=()=>{if(Z){Z=!1;const ct=ce;ce=null,he.next(ct),!je&&ve(ct)}};Ee.subscribe((0,e._)(he,ct=>{Z=!0,ce=ct,(!le||le.closed)&&(q?fn():ve(ct))},()=>{je=!0,(!(oe&&Z&&le)||le.closed)&&he.complete()}))})}},7107:(Ot,Me,S)=>{S.d(Me,{c:()=>X});var i=S(3236),e=S(3702),M=S(1807);function X(ie,Q=i.E,Ee){const he=(0,M.O)(ie,Q);return(0,e.n)(()=>he,Ee)}},3774:(Ot,Me,S)=>{S.d(Me,{v:()=>X});var i=S(9350),e=S(9974),M=S(4360);function X(Q=ie){return(0,e.N)((Ee,he)=>{let q=!1;Ee.subscribe((0,M._)(he,oe=>{q=!0,he.next(oe)},()=>q?he.complete():he.error(Q())))})}function ie(){return new i.G}},9550:(Ot,Me,S)=>{S.d(Me,{f:()=>X});var i=S(3236),e=S(9974),M=S(4360);function X(Q=i.E){return(0,e.N)((Ee,he)=>{let q=Q.now();Ee.subscribe((0,M._)(he,oe=>{const Z=Q.now(),ce=Z-q;q=Z,he.next(new ie(oe,ce))}))})}class ie{constructor(Ee,he){this.value=Ee,this.interval=he}}},2087:(Ot,Me,S)=>{S.d(Me,{M:()=>he,w:()=>q});var i=S(3236),e=S(8211),M=S(9974),X=S(8750),ie=S(1853),Q=S(4360),Ee=S(5225);const he=(0,ie.L)(Z=>function(le=null){Z(this),this.message="Timeout has occurred",this.name="TimeoutError",this.info=le});function q(Z,ce){const{first:le,each:je,with:Et=oe,scheduler:wt=ce??i.E,meta:ve=null}=(0,e.v)(Z)?{first:Z}:"number"==typeof Z?{each:Z}:Z;if(null==le&&null==je)throw new TypeError("No timeout provided.");return(0,M.N)((fn,ct)=>{let en,an,un=null,vn=0;const Pt=Ae=>{an=(0,Ee.N)(ct,wt,()=>{try{en.unsubscribe(),(0,X.Tg)(Et({meta:ve,lastValue:un,seen:vn})).subscribe(ct)}catch(dt){ct.error(dt)}},Ae)};en=fn.subscribe((0,Q._)(ct,Ae=>{an?.unsubscribe(),vn++,ct.next(un=Ae),je>0&&Pt(je)},void 0,void 0,()=>{an?.closed||an?.unsubscribe(),un=null})),!vn&&Pt(null!=le?"number"==typeof le?le:+le-wt.now():je)})}function oe(Z){throw new he(Z)}},3935:(Ot,Me,S)=>{S.d(Me,{o:()=>X});var i=S(3236),e=S(8211),M=S(2087);function X(ie,Q,Ee){let he,q,oe;if(Ee=Ee??i.b,(0,e.v)(ie)?he=ie:"number"==typeof ie&&(q=ie),!Q)throw new TypeError("No observable provided to switch to");if(oe=()=>Q,null==he&&null==q)throw new TypeError("No timeout provided.");return(0,M.w)({first:he,each:q,scheduler:Ee,with:oe})}},7232:(Ot,Me,S)=>{S.d(Me,{v:()=>M});var i=S(6129),e=S(6354);function M(X=i.U){return(0,e.T)(ie=>({value:ie,timestamp:X.now()}))}},6594:(Ot,Me,S)=>{S.d(Me,{$:()=>X});var i=S(9852),e=S(9974);const M=(ie,Q)=>(ie.push(Q),ie);function X(){return(0,e.N)((ie,Q)=>{(0,i.T)(M,[])(ie).subscribe(Q)})}},3438:(Ot,Me,S)=>{S.d(Me,{x:()=>Q});var i=S(8530),e=S(9974),M=S(4360),X=S(5343),ie=S(8750);function Q(Ee){return(0,e.N)((he,q)=>{let oe=new i.B;q.next(oe.asObservable());const Z=ce=>{oe.error(ce),q.error(ce)};return he.subscribe((0,M._)(q,ce=>oe?.next(ce),()=>{oe.complete(),q.complete()},Z)),(0,ie.Tg)(Ee).subscribe((0,M._)(q,()=>{oe.complete(),q.next(oe=new i.B)},X.l,Z)),()=>{oe?.unsubscribe(),oe=null}})}},5355:(Ot,Me,S)=>{S.d(Me,{k:()=>X});var i=S(8530),e=S(9974),M=S(4360);function X(ie,Q=0){const Ee=Q>0?Q:ie;return(0,e.N)((he,q)=>{let oe=[new i.B],Z=[],ce=0;q.next(oe[0].asObservable()),he.subscribe((0,M._)(q,le=>{for(const Et of oe)Et.next(le);const je=ce-ie+1;if(je>=0&&je%Ee==0&&oe.shift().complete(),++ce%Ee==0){const Et=new i.B;oe.push(Et),q.next(Et.asObservable())}},()=>{for(;oe.length>0;)oe.shift().complete();q.complete()},le=>{for(;oe.length>0;)oe.shift().error(le);q.error(le)},()=>{Z=null,oe=null}))})}},1371:(Ot,Me,S)=>{S.d(Me,{s:()=>q});var i=S(8530),e=S(3236),M=S(3961),X=S(9974),ie=S(4360),Q=S(7908),Ee=S(9326),he=S(5225);function q(oe,...Z){var ce,le;const je=null!==(ce=(0,Ee.lI)(Z))&&void 0!==ce?ce:e.E,Et=null!==(le=Z[0])&&void 0!==le?le:null,wt=Z[1]||1/0;return(0,X.N)((ve,fn)=>{let ct=[],en=!1;const an=Ae=>{const{window:dt,subs:ut}=Ae;dt.complete(),ut.unsubscribe(),(0,Q.o)(ct,Ae),en&&un()},un=()=>{if(ct){const Ae=new M.yU;fn.add(Ae);const dt=new i.B,ut={window:dt,subs:Ae,seen:0};ct.push(ut),fn.next(dt.asObservable()),(0,he.N)(Ae,je,()=>an(ut),oe)}};null!==Et&&Et>=0?(0,he.N)(fn,je,un,Et,!0):en=!0,un();const vn=Ae=>ct.slice().forEach(Ae),Pt=Ae=>{vn(({window:dt})=>Ae(dt)),Ae(fn),fn.unsubscribe()};return ve.subscribe((0,ie._)(fn,Ae=>{vn(dt=>{dt.window.next(Ae),wt<=++dt.seen&&an(dt)})},()=>Pt(Ae=>Ae.complete()),Ae=>Pt(dt=>dt.error(Ae)))),()=>{ct=null}})}},3182:(Ot,Me,S)=>{S.d(Me,{J:()=>he});var i=S(8530),e=S(3961),M=S(9974),X=S(8750),ie=S(4360),Q=S(5343),Ee=S(7908);function he(q,oe){return(0,M.N)((Z,ce)=>{const le=[],je=Et=>{for(;0<le.length;)le.shift().error(Et);ce.error(Et)};(0,X.Tg)(q).subscribe((0,ie._)(ce,Et=>{const wt=new i.B;le.push(wt);const ve=new e.yU;let ct;try{ct=(0,X.Tg)(oe(Et))}catch(en){return void je(en)}ce.next(wt.asObservable()),ve.add(ct.subscribe((0,ie._)(ce,()=>{(0,Ee.o)(le,wt),wt.complete(),ve.unsubscribe()},Q.l,je)))},Q.l)),Z.subscribe((0,ie._)(ce,Et=>{const wt=le.slice();for(const ve of wt)ve.next(Et)},()=>{for(;0<le.length;)le.shift().complete();ce.complete()},je,()=>{for(;0<le.length;)le.shift().unsubscribe()}))})}},4722:(Ot,Me,S)=>{S.d(Me,{p:()=>ie});var i=S(8530),e=S(9974),M=S(4360),X=S(8750);function ie(Q){return(0,e.N)((Ee,he)=>{let q,oe;const Z=le=>{q.error(le),he.error(le)},ce=()=>{let le;oe?.unsubscribe(),q?.complete(),q=new i.B,he.next(q.asObservable());try{le=(0,X.Tg)(Q())}catch(je){return void Z(je)}le.subscribe(oe=(0,M._)(he,ce,ce,Z))};ce(),Ee.subscribe((0,M._)(he,le=>q.next(le),()=>{q.complete(),he.complete()},Z,()=>{oe?.unsubscribe(),q=null}))})}},3993:(Ot,Me,S)=>{S.d(Me,{E:()=>Ee});var i=S(9974),e=S(4360),M=S(8750),X=S(3669),ie=S(5343),Q=S(9326);function Ee(...he){const q=(0,Q.ms)(he);return(0,i.N)((oe,Z)=>{const ce=he.length,le=new Array(ce);let je=he.map(()=>!1),Et=!1;for(let wt=0;wt<ce;wt++)(0,M.Tg)(he[wt]).subscribe((0,e._)(Z,ve=>{le[wt]=ve,!Et&&!je[wt]&&(je[wt]=!0,(Et=je.every(X.D))&&(je=null))},ie.l));oe.subscribe((0,e._)(Z,wt=>{if(Et){const ve=[wt,...le];Z.next(q?q(...ve):ve)}}))})}},3179:(Ot,Me,S)=>{S.d(Me,{y:()=>M});var i=S(4437),e=S(9974);function M(...X){return(0,e.N)((ie,Q)=>{(0,i.y)(ie,...X).subscribe(Q)})}},1828:(Ot,Me,S)=>{S.d(Me,{x:()=>M});var i=S(4437),e=S(5265);function M(X){return(0,e.q)(i.y,X)}},163:(Ot,Me,S)=>{S.d(Me,{O:()=>e});var i=S(3179);function e(...M){return(0,i.y)(...M)}},7119:(Ot,Me,S)=>{S.d(Me,{S:()=>ie});var i=S(1985),e=S(4761),M=S(8071),X=S(5225);function ie(Q,Ee){return new i.c(he=>{let q;return(0,X.N)(he,Ee,()=>{q=Q[e.l](),(0,X.N)(he,Ee,()=>{let oe,Z;try{({value:oe,done:Z}=q.next())}catch(ce){return void he.error(ce)}Z?he.complete():he.next(oe)},0,!0)}),()=>(0,M.T)(q?.return)&&q.return()})}},5894:(Ot,Me,S)=>{S.d(Me,{c:()=>ct});var i=S(8750),e=S(941),M=S(6745),Q=S(1985),he=S(7119),q=S(5225);function oe(en,an){if(!en)throw new Error("Iterable cannot be null");return new Q.c(un=>{(0,q.N)(un,an,()=>{const vn=en[Symbol.asyncIterator]();(0,q.N)(un,an,()=>{vn.next().then(Pt=>{Pt.done?un.complete():un.next(Pt.value)})},0,!0)})})}var Z=S(5055),ce=S(9858),le=S(7441),je=S(5397),Et=S(7953),wt=S(591),ve=S(5196);function ct(en,an){if(null!=en){if((0,Z.l)(en))return function X(en,an){return(0,i.Tg)(en).pipe((0,M._)(an),(0,e.Q)(an))}(en,an);if((0,le.X)(en))return function Ee(en,an){return new Q.c(un=>{let vn=0;return an.schedule(function(){vn===en.length?un.complete():(un.next(en[vn++]),un.closed||this.schedule())})})}(en,an);if((0,ce.y)(en))return function ie(en,an){return(0,i.Tg)(en).pipe((0,M._)(an),(0,e.Q)(an))}(en,an);if((0,Et.T)(en))return oe(en,an);if((0,je.x)(en))return(0,he.S)(en,an);if((0,ve.U)(en))return function fn(en,an){return oe((0,ve.C)(en),an)}(en,an)}throw(0,wt.L)(en)}},6780:(Ot,Me,S)=>{S.d(Me,{R:()=>ie});var i=S(3961);class e extends i.yU{constructor(Ee,he){super()}schedule(Ee,he=0){return this}}const M={setInterval(Q,Ee,...he){const{delegate:q}=M;return q?.setInterval?q.setInterval(Q,Ee,...he):setInterval(Q,Ee,...he)},clearInterval(Q){const{delegate:Ee}=M;return(Ee?.clearInterval||clearInterval)(Q)},delegate:void 0};var X=S(7908);class ie extends e{constructor(Ee,he){super(Ee,he),this.scheduler=Ee,this.work=he,this.pending=!1}schedule(Ee,he=0){var q;if(this.closed)return this;this.state=Ee;const oe=this.id,Z=this.scheduler;return null!=oe&&(this.id=this.recycleAsyncId(Z,oe,he)),this.pending=!0,this.delay=he,this.id=null!==(q=this.id)&&void 0!==q?q:this.requestAsyncId(Z,this.id,he),this}requestAsyncId(Ee,he,q=0){return M.setInterval(Ee.flush.bind(Ee,this),q)}recycleAsyncId(Ee,he,q=0){if(null!=q&&this.delay===q&&!1===this.pending)return he;null!=he&&M.clearInterval(he)}execute(Ee,he){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;const q=this._execute(Ee,he);if(q)return q;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(Ee,he){let oe,q=!1;try{this.work(Ee)}catch(Z){q=!0,oe=Z||new Error("Scheduled action threw falsy error")}if(q)return this.unsubscribe(),oe}unsubscribe(){if(!this.closed){const{id:Ee,scheduler:he}=this,{actions:q}=he;this.work=this.state=this.scheduler=null,this.pending=!1,(0,X.o)(q,this),null!=Ee&&(this.id=this.recycleAsyncId(he,Ee,null)),this.delay=null,super.unsubscribe()}}}},707:(Ot,Me,S)=>{S.d(Me,{q:()=>e});var i=S(8399);class e extends i._{constructor(X,ie=i._.now){super(X,ie),this.actions=[],this._active=!1}flush(X){const{actions:ie}=this;if(this._active)return void ie.push(X);let Q;this._active=!0;do{if(Q=X.execute(X.state,X.delay))break}while(X=ie.shift());if(this._active=!1,Q){for(;X=ie.shift();)X.unsubscribe();throw Q}}}},3236:(Ot,Me,S)=>{S.d(Me,{E:()=>M,b:()=>X});var i=S(6780);const M=new(S(707).q)(i.R),X=M},6129:(Ot,Me,S)=>{S.d(Me,{U:()=>i});const i={now:()=>(i.delegate||Date).now(),delegate:void 0}},9270:(Ot,Me,S)=>{S.d(Me,{f:()=>i});const i={setTimeout(e,M,...X){const{delegate:ie}=i;return ie?.setTimeout?ie.setTimeout(e,M,...X):setTimeout(e,M,...X)},clearTimeout(e){const{delegate:M}=i;return(M?.clearTimeout||clearTimeout)(e)},delegate:void 0}},4761:(Ot,Me,S)=>{S.d(Me,{l:()=>e});const e=function i(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}()},3494:(Ot,Me,S)=>{S.d(Me,{s:()=>i});const i="function"==typeof Symbol&&Symbol.observable||"@@observable"},3886:(Ot,Me,S)=>{S.d(Me,{k:()=>e});const e=(0,S(1853).L)(M=>function(){M(this),this.name="ArgumentOutOfRangeError",this.message="argument out of range"})},9350:(Ot,Me,S)=>{S.d(Me,{G:()=>e});const e=(0,S(1853).L)(M=>function(){M(this),this.name="EmptyError",this.message="no elements in sequence"})},9896:(Ot,Me,S)=>{S.d(Me,{m:()=>e});const e=(0,S(1853).L)(M=>function(ie){M(this),this.name="NotFoundError",this.message=ie})},9117:(Ot,Me,S)=>{S.d(Me,{P:()=>e});const e=(0,S(1853).L)(M=>function(){M(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"})},7517:(Ot,Me,S)=>{S.d(Me,{I:()=>e});const e=(0,S(1853).L)(M=>function(ie){M(this),this.name="SequenceError",this.message=ie})},4079:(Ot,Me,S)=>{S.d(Me,{Z:()=>e});const e=(0,S(1853).L)(M=>function(ie){M(this),this.message=ie?`${ie.length} errors occurred during unsubscription:\n${ie.map((Q,Ee)=>`${Ee+1}) ${Q.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=ie})},9326:(Ot,Me,S)=>{S.d(Me,{R0:()=>Q,lI:()=>ie,ms:()=>X});var i=S(8071),e=S(9470);function M(Ee){return Ee[Ee.length-1]}function X(Ee){return(0,i.T)(M(Ee))?Ee.pop():void 0}function ie(Ee){return(0,e.m)(M(Ee))?Ee.pop():void 0}function Q(Ee,he){return"number"==typeof M(Ee)?Ee.pop():he}},3073:(Ot,Me,S)=>{S.d(Me,{D:()=>ie});const{isArray:i}=Array,{getPrototypeOf:e,prototype:M,keys:X}=Object;function ie(Ee){if(1===Ee.length){const he=Ee[0];if(i(he))return{args:he,keys:null};if(function Q(Ee){return Ee&&"object"==typeof Ee&&e(Ee)===M}(he)){const q=X(he);return{args:q.map(oe=>he[oe]),keys:q}}}return{args:Ee,keys:null}}},2326:(Ot,Me,S)=>{S.d(Me,{K:()=>e});const{isArray:i}=Array;function e(M){return 1===M.length&&i(M[0])?M[0]:M}},7908:(Ot,Me,S)=>{function i(e,M){if(e){const X=e.indexOf(M);0<=X&&e.splice(X,1)}}S.d(Me,{o:()=>i})},1853:(Ot,Me,S)=>{function i(e){const X=e(ie=>{Error.call(ie),ie.stack=(new Error).stack});return X.prototype=Object.create(Error.prototype),X.prototype.constructor=X,X}S.d(Me,{L:()=>i})},8496:(Ot,Me,S)=>{function i(e,M){return e.reduce((X,ie,Q)=>(X[ie]=M[Q],X),{})}S.d(Me,{e:()=>i})},9786:(Ot,Me,S)=>{S.d(Me,{Y:()=>M,l:()=>X});var i=S(1026);let e=null;function M(ie){if(i.$.useDeprecatedSynchronousErrorHandling){const Q=!e;if(Q&&(e={errorThrown:!1,error:null}),ie(),Q){const{errorThrown:Ee,error:he}=e;if(e=null,Ee)throw he}}else ie()}function X(ie){i.$.useDeprecatedSynchronousErrorHandling&&e&&(e.errorThrown=!0,e.error=ie)}},5225:(Ot,Me,S)=>{function i(e,M,X,ie=0,Q=!1){const Ee=M.schedule(function(){X(),Q?e.add(this.schedule(null,ie)):this.unsubscribe()},ie);if(e.add(Ee),!Q)return Ee}S.d(Me,{N:()=>i})},3669:(Ot,Me,S)=>{function i(e){return e}S.d(Me,{D:()=>i})},7441:(Ot,Me,S)=>{S.d(Me,{X:()=>i});const i=e=>e&&"number"==typeof e.length&&"function"!=typeof e},7953:(Ot,Me,S)=>{S.d(Me,{T:()=>e});var i=S(8071);function e(M){return Symbol.asyncIterator&&(0,i.T)(M?.[Symbol.asyncIterator])}},8211:(Ot,Me,S)=>{function i(e){return e instanceof Date&&!isNaN(e)}S.d(Me,{v:()=>i})},8071:(Ot,Me,S)=>{function i(e){return"function"==typeof e}S.d(Me,{T:()=>i})},5055:(Ot,Me,S)=>{S.d(Me,{l:()=>M});var i=S(3494),e=S(8071);function M(X){return(0,e.T)(X[i.s])}},5397:(Ot,Me,S)=>{S.d(Me,{x:()=>M});var i=S(4761),e=S(8071);function M(X){return(0,e.T)(X?.[i.l])}},9858:(Ot,Me,S)=>{S.d(Me,{y:()=>e});var i=S(8071);function e(M){return(0,i.T)(M?.then)}},5196:(Ot,Me,S)=>{S.d(Me,{C:()=>M,U:()=>X});var i=S(7798),e=S(8071);function M(ie){return(0,i.AQ)(this,arguments,function*(){const Ee=ie.getReader();try{for(;;){const{value:he,done:q}=yield(0,i.N3)(Ee.read());if(q)return yield(0,i.N3)(void 0);yield yield(0,i.N3)(he)}}finally{Ee.releaseLock()}})}function X(ie){return(0,e.T)(ie?.getReader)}},9470:(Ot,Me,S)=>{S.d(Me,{m:()=>e});var i=S(8071);function e(M){return M&&(0,i.T)(M.schedule)}},9974:(Ot,Me,S)=>{S.d(Me,{N:()=>M,S:()=>e});var i=S(8071);function e(X){return(0,i.T)(X?.lift)}function M(X){return ie=>{if(e(ie))return ie.lift(function(Q){try{return X(Q,this)}catch(Ee){this.error(Ee)}});throw new TypeError("Unable to lift unknown Observable type")}}},6450:(Ot,Me,S)=>{S.d(Me,{I:()=>X});var i=S(6354);const{isArray:e}=Array;function X(ie){return(0,i.T)(Q=>function M(ie,Q){return e(Q)?ie(...Q):ie(Q)}(ie,Q))}},5343:(Ot,Me,S)=>{function i(){}S.d(Me,{l:()=>i})},7442:(Ot,Me,S)=>{function i(e,M){return(X,ie)=>!e.call(M,X,ie)}S.d(Me,{A:()=>i})},1203:(Ot,Me,S)=>{S.d(Me,{F:()=>e,m:()=>M});var i=S(3669);function e(...X){return M(X)}function M(X){return 0===X.length?i.D:1===X.length?X[0]:function(Q){return X.reduce((Ee,he)=>he(Ee),Q)}}},5334:(Ot,Me,S)=>{S.d(Me,{m:()=>M});var i=S(1026),e=S(9270);function M(X){e.f.setTimeout(()=>{const{onUnhandledError:ie}=i.$;if(!ie)throw X;ie(X)})}},591:(Ot,Me,S)=>{function i(e){return new TypeError(`You provided ${null!==e&&"object"==typeof e?"an invalid object":`'${e}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}S.d(Me,{L:()=>i})},7037:(Ot,Me,S)=>{S.r(Me),S.d(Me,{audit:()=>i.s,auditTime:()=>e.Z,buffer:()=>M.r,bufferCount:()=>X.S,bufferTime:()=>ie.w,bufferToggle:()=>Q.H,bufferWhen:()=>Ee.n,catchError:()=>he.W,combineAll:()=>q.p,combineLatest:()=>Z.z,combineLatestAll:()=>oe.A,combineLatestWith:()=>ce.v,concat:()=>le.x,concatAll:()=>je.K,concatMap:()=>Et.H,concatMapTo:()=>wt.S,concatWith:()=>ve.$,connect:()=>fn.N,count:()=>ct.U,debounce:()=>en.s,debounceTime:()=>an.B,defaultIfEmpty:()=>un.U,delay:()=>vn.c,delayWhen:()=>Pt.o,dematerialize:()=>Ae.Z,distinct:()=>dt.d,distinctUntilChanged:()=>ut.F,distinctUntilKeyChanged:()=>Mt.w,elementAt:()=>Wt.s,endWith:()=>It.q,every:()=>Vn.S,exhaust:()=>pn.B,exhaustAll:()=>Wn.C,exhaustMap:()=>ji.p,expand:()=>An.f,filter:()=>St.p,finalize:()=>qt.j,find:()=>Ht.I,findIndex:()=>on.S,first:()=>Cn.$,flatMap:()=>Xr.q,groupBy:()=>tn.$,ignoreElements:()=>fi.w,isEmpty:()=>Zn.I,last:()=>Dn.H,map:()=>gn.T,mapTo:()=>Nn.u,materialize:()=>Yn.O,max:()=>cr.T,merge:()=>Ai.h,mergeAll:()=>Qi.U,mergeMap:()=>Ur.Z,mergeMapTo:()=>eo.C,mergeScan:()=>as.i,mergeWith:()=>uo.X,min:()=>mi.j,multicast:()=>ci.f,observeOn:()=>yt.Q,onErrorResumeNext:()=>hn.g,pairwise:()=>Gt.J,partition:()=>ri,pluck:()=>pi.E,publish:()=>At.m,publishBehavior:()=>Bn.K,publishLast:()=>Mn.k,publishReplay:()=>ni.H,race:()=>Bi,raceWith:()=>Ti.w,reduce:()=>Gi.T,refCount:()=>Ft.B,repeat:()=>Ii.u,repeatWhen:()=>Ki.Y,retry:()=>Jt.L,retryWhen:()=>hi.l,sample:()=>it.X,sampleTime:()=>sn.q,scan:()=>Ve.S,sequenceEqual:()=>He.m,share:()=>mt.u,shareReplay:()=>bt.t,single:()=>nn.J,skip:()=>Jn.i,skipLast:()=>Sn.G,skipUntil:()=>_r.U,skipWhile:()=>qr.j,startWith:()=>Bo.Z,subscribeOn:()=>Eo._,switchAll:()=>Ro.w,switchMap:()=>Ls.n,switchMapTo:()=>ol.K,switchScan:()=>Va.m,take:()=>Ao.s,takeLast:()=>za.o,takeUntil:()=>vl.Q,takeWhile:()=>Na.v,tap:()=>_l.M,throttle:()=>gs.n,throttleTime:()=>Zs.c,throwIfEmpty:()=>oa.v,timeInterval:()=>no.f,timeout:()=>xl.w,timeoutWith:()=>Qr.o,timestamp:()=>dl.v,toArray:()=>Ya.$,window:()=>Lo.x,windowCount:()=>ko.k,windowTime:()=>jt.s,windowToggle:()=>In.J,windowWhen:()=>Rt.p,withLatestFrom:()=>jn.E,zip:()=>Fi.y,zipAll:()=>Ui.x,zipWith:()=>ar.O});var i=S(5135),e=S(3578),M=S(8968),X=S(6173),ie=S(9445),Q=S(8004),Ee=S(4868),he=S(9437),q=S(7906),oe=S(3295),Z=S(3802),ce=S(1990),le=S(8814),je=S(9131),Et=S(274),wt=S(7671),ve=S(3658),fn=S(2066),ct=S(4907),en=S(3229),an=S(152),un=S(9901),vn=S(3103),Pt=S(3183),Ae=S(5236),dt=S(2953),ut=S(3294),Mt=S(1765),Wt=S(9301),It=S(4697),Vn=S(947),pn=S(3726),Wn=S(9643),ji=S(786),An=S(1546),St=S(5964),qt=S(980),Ht=S(7677),on=S(7305),Cn=S(1594),tn=S(7002),fi=S(3557),Zn=S(6785),Dn=S(7018),gn=S(6354),Nn=S(3703),Yn=S(7021),cr=S(5146),Ai=S(1716),Qi=S(6365),Xr=S(8523),Ur=S(3028),eo=S(9189),as=S(3489),uo=S(8412),mi=S(8084),ci=S(354),yt=S(941),hn=S(1219),Gt=S(3946),Gn=S(7442);function ri(er,Or){return Tt=>[(0,St.p)(er,Or)(Tt),(0,St.p)((0,Gn.A)(er,Or))(Tt)]}var pi=S(9085),At=S(1927),Bn=S(3581),Mn=S(5735),ni=S(9348),qn=S(2326),Ti=S(495);function Bi(...er){return(0,Ti.w)(...(0,qn.K)(er))}var Gi=S(9852),Ii=S(7469),Ki=S(3981),Jt=S(2498),hi=S(1966),Ft=S(9898),it=S(6052),sn=S(5385),Ve=S(1943),He=S(7743),mt=S(7647),bt=S(4668),nn=S(9338),Jn=S(5245),Sn=S(9769),_r=S(4493),qr=S(8492),Bo=S(9172),Eo=S(6745),Ro=S(7799),Ls=S(5558),ol=S(7083),Va=S(4979),Ao=S(6697),za=S(5109),vl=S(6977),Na=S(7048),_l=S(8141),gs=S(3702),Zs=S(7107),oa=S(3774),no=S(9550),xl=S(2087),Qr=S(3935),dl=S(7232),Ya=S(6594),Lo=S(3438),ko=S(5355),jt=S(1371),In=S(3182),Rt=S(4722),jn=S(3993),Fi=S(3179),Ui=S(1828),ar=S(163)},6433:(Ot,Me,S)=>{var i=S(2495),e=S(7850),M=S(5704),X=S(8114),ie=S(9040),Q=S(4478),Ee=S(7454);Ee.alea=i,Ee.xor128=e,Ee.xorwow=M,Ee.xorshift7=X,Ee.xor4096=ie,Ee.tychei=Q,Ot.exports=Ee},2495:function(Ot,Me,S){var i;!function(e,M){function ie(q){var oe=this,Z=function he(){var q=4022871197;return function(Z){Z=String(Z);for(var ce=0;ce<Z.length;ce++){var le=.02519603282416938*(q+=Z.charCodeAt(ce));le-=q=le>>>0,q=(le*=q)>>>0,q+=4294967296*(le-=q)}return 2.3283064365386963e-10*(q>>>0)}}();oe.next=function(){var ce=2091639*oe.s0+2.3283064365386963e-10*oe.c;return oe.s0=oe.s1,oe.s1=oe.s2,oe.s2=ce-(oe.c=0|ce)},oe.c=1,oe.s0=Z(" "),oe.s1=Z(" "),oe.s2=Z(" "),oe.s0-=Z(q),oe.s0<0&&(oe.s0+=1),oe.s1-=Z(q),oe.s1<0&&(oe.s1+=1),oe.s2-=Z(q),oe.s2<0&&(oe.s2+=1),Z=null}function Q(q,oe){return oe.c=q.c,oe.s0=q.s0,oe.s1=q.s1,oe.s2=q.s2,oe}function Ee(q,oe){var Z=new ie(q),ce=oe&&oe.state,le=Z.next;return le.int32=function(){return 4294967296*Z.next()|0},le.double=function(){return le()+11102230246251565e-32*(2097152*le()|0)},le.quick=le,ce&&("object"==typeof ce&&Q(ce,Z),le.state=function(){return Q(Z,{})}),le}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.alea=Ee}(0,Ot=S.nmd(Ot))},4478:function(Ot,Me,S){var i;!function(e,M){function ie(he){var q=this,oe="";q.next=function(){var ce=q.b,le=q.c,je=q.d,Et=q.a;return ce=ce<<25^ce>>>7^le,le=le-je|0,je=je<<24^je>>>8^Et,Et=Et-ce|0,q.b=ce=ce<<20^ce>>>12^le,q.c=le=le-je|0,q.d=je<<16^le>>>16^Et,q.a=Et-ce|0},q.a=0,q.b=0,q.c=-1640531527,q.d=1367130551,he===Math.floor(he)?(q.a=he/4294967296|0,q.b=0|he):oe+=he;for(var Z=0;Z<oe.length+20;Z++)q.b^=0|oe.charCodeAt(Z),q.next()}function Q(he,q){return q.a=he.a,q.b=he.b,q.c=he.c,q.d=he.d,q}function Ee(he,q){var oe=new ie(he),Z=q&&q.state,ce=function(){return(oe.next()>>>0)/4294967296};return ce.double=function(){do{var Et=((oe.next()>>>11)+(oe.next()>>>0)/4294967296)/(1<<21)}while(0===Et);return Et},ce.int32=oe.next,ce.quick=ce,Z&&("object"==typeof Z&&Q(Z,oe),ce.state=function(){return Q(oe,{})}),ce}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.tychei=Ee}(0,Ot=S.nmd(Ot))},7850:function(Ot,Me,S){var i;!function(e,M){function ie(he){var q=this,oe="";q.x=0,q.y=0,q.z=0,q.w=0,q.next=function(){var ce=q.x^q.x<<11;return q.x=q.y,q.y=q.z,q.z=q.w,q.w^=q.w>>>19^ce^ce>>>8},he===(0|he)?q.x=he:oe+=he;for(var Z=0;Z<oe.length+64;Z++)q.x^=0|oe.charCodeAt(Z),q.next()}function Q(he,q){return q.x=he.x,q.y=he.y,q.z=he.z,q.w=he.w,q}function Ee(he,q){var oe=new ie(he),Z=q&&q.state,ce=function(){return(oe.next()>>>0)/4294967296};return ce.double=function(){do{var Et=((oe.next()>>>11)+(oe.next()>>>0)/4294967296)/(1<<21)}while(0===Et);return Et},ce.int32=oe.next,ce.quick=ce,Z&&("object"==typeof Z&&Q(Z,oe),ce.state=function(){return Q(oe,{})}),ce}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.xor128=Ee}(0,Ot=S.nmd(Ot))},9040:function(Ot,Me,S){var i;!function(e,M){function ie(he){var q=this;q.next=function(){var je,Et,Z=q.w,ce=q.X,le=q.i;return q.w=Z=Z+1640531527|0,Et=ce[le+34&127],je=ce[le=le+1&127],Et^=Et<<13,je^=je<<17,Et=ce[le]=(Et^=Et>>>15)^(je^=je>>>12),q.i=le,Et+(Z^Z>>>16)|0},function oe(Z,ce){var le,je,Et,wt,ve,fn=[],ct=128;for(ce===(0|ce)?(je=ce,ce=null):(ce+="\0",je=0,ct=Math.max(ct,ce.length)),Et=0,wt=-32;wt<ct;++wt)ce&&(je^=ce.charCodeAt((wt+32)%ce.length)),0===wt&&(ve=je),je^=je<<10,je^=je>>>15,je^=je<<4,je^=je>>>13,wt>=0&&(Et=0==(le=fn[127&wt]^=je+(ve=ve+1640531527|0))?Et+1:0);for(Et>=128&&(fn[127&(ce&&ce.length||0)]=-1),Et=127,wt=512;wt>0;--wt)je=fn[Et+34&127],le=fn[Et=Et+1&127],je^=je<<13,le^=le<<17,fn[Et]=(je^=je>>>15)^(le^=le>>>12);Z.w=ve,Z.X=fn,Z.i=Et}(q,he)}function Q(he,q){return q.i=he.i,q.w=he.w,q.X=he.X.slice(),q}function Ee(he,q){null==he&&(he=+new Date);var oe=new ie(he),Z=q&&q.state,ce=function(){return(oe.next()>>>0)/4294967296};return ce.double=function(){do{var Et=((oe.next()>>>11)+(oe.next()>>>0)/4294967296)/(1<<21)}while(0===Et);return Et},ce.int32=oe.next,ce.quick=ce,Z&&(Z.X&&Q(Z,oe),ce.state=function(){return Q(oe,{})}),ce}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.xor4096=Ee}(0,Ot=S.nmd(Ot))},8114:function(Ot,Me,S){var i;!function(e,M){function ie(he){var q=this;q.next=function(){var le,je,Z=q.x,ce=q.i;return le=Z[ce],je=(le^=le>>>7)^le<<24,je^=(le=Z[ce+1&7])^le>>>10,je^=(le=Z[ce+3&7])^le>>>3,je^=(le=Z[ce+4&7])^le<<7,le=Z[ce+7&7],Z[ce]=je^=(le^=le<<13)^le<<9,q.i=ce+1&7,je},function oe(Z,ce){var le,Et=[];if(ce===(0|ce))Et[0]=ce;else for(ce=""+ce,le=0;le<ce.length;++le)Et[7&le]=Et[7&le]<<15^ce.charCodeAt(le)+Et[le+1&7]<<13;for(;Et.length<8;)Et.push(0);for(le=0;le<8&&0===Et[le];++le);for(8==le&&(Et[7]=-1),Z.x=Et,Z.i=0,le=256;le>0;--le)Z.next()}(q,he)}function Q(he,q){return q.x=he.x.slice(),q.i=he.i,q}function Ee(he,q){null==he&&(he=+new Date);var oe=new ie(he),Z=q&&q.state,ce=function(){return(oe.next()>>>0)/4294967296};return ce.double=function(){do{var Et=((oe.next()>>>11)+(oe.next()>>>0)/4294967296)/(1<<21)}while(0===Et);return Et},ce.int32=oe.next,ce.quick=ce,Z&&(Z.x&&Q(Z,oe),ce.state=function(){return Q(oe,{})}),ce}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.xorshift7=Ee}(0,Ot=S.nmd(Ot))},5704:function(Ot,Me,S){var i;!function(e,M){function ie(he){var q=this,oe="";q.next=function(){var ce=q.x^q.x>>>2;return q.x=q.y,q.y=q.z,q.z=q.w,q.w=q.v,(q.d=q.d+362437|0)+(q.v=q.v^q.v<<4^ce^ce<<1)|0},q.x=0,q.y=0,q.z=0,q.w=0,q.v=0,he===(0|he)?q.x=he:oe+=he;for(var Z=0;Z<oe.length+64;Z++)q.x^=0|oe.charCodeAt(Z),Z==oe.length&&(q.d=q.x<<10^q.x>>>4),q.next()}function Q(he,q){return q.x=he.x,q.y=he.y,q.z=he.z,q.w=he.w,q.v=he.v,q.d=he.d,q}function Ee(he,q){var oe=new ie(he),Z=q&&q.state,ce=function(){return(oe.next()>>>0)/4294967296};return ce.double=function(){do{var Et=((oe.next()>>>11)+(oe.next()>>>0)/4294967296)/(1<<21)}while(0===Et);return Et},ce.int32=oe.next,ce.quick=ce,Z&&("object"==typeof Z&&Q(Z,oe),ce.state=function(){return Q(oe,{})}),ce}M&&M.exports?M.exports=Ee:S.amdD&&S.amdO?void 0!==(i=function(){return Ee}.call(Me,S,Me,M))&&(M.exports=i):this.xorwow=Ee}(0,Ot=S.nmd(Ot))},7454:function(Ot,Me,S){var i;!function(e,M,X){var le,ie=256,q=X.pow(ie,6),oe=X.pow(2,52),Z=2*oe,ce=ie-1;function je(an,un,vn){var Pt=[],Ae=fn(ve((un=1==un?{entropy:!0}:un||{}).entropy?[an,en(M)]:an??function ct(){try{var an;return le&&(an=le.randomBytes)?an=an(ie):(an=new Uint8Array(ie),(e.crypto||e.msCrypto).getRandomValues(an)),en(an)}catch{var un=e.navigator,vn=un&&un.plugins;return[+new Date,e,vn,e.screen,en(M)]}}(),3),Pt),dt=new Et(Pt),ut=function(){for(var Mt=dt.g(6),Wt=q,It=0;Mt<oe;)Mt=(Mt+It)*ie,Wt*=ie,It=dt.g(1);for(;Mt>=Z;)Mt/=2,Wt/=2,It>>>=1;return(Mt+It)/Wt};return ut.int32=function(){return 0|dt.g(4)},ut.quick=function(){return dt.g(4)/4294967296},ut.double=ut,fn(en(dt.S),M),(un.pass||vn||function(Mt,Wt,It,Vn){return Vn&&(Vn.S&&wt(Vn,dt),Mt.state=function(){return wt(dt,{})}),It?(X.random=Mt,Wt):Mt})(ut,Ae,"global"in un?un.global:this==X,un.state)}function Et(an){var un,vn=an.length,Pt=this,Ae=0,dt=Pt.i=Pt.j=0,ut=Pt.S=[];for(vn||(an=[vn++]);Ae<ie;)ut[Ae]=Ae++;for(Ae=0;Ae<ie;Ae++)ut[Ae]=ut[dt=ce&dt+an[Ae%vn]+(un=ut[Ae])],ut[dt]=un;(Pt.g=function(Mt){for(var Wt,It=0,Vn=Pt.i,pn=Pt.j,Wn=Pt.S;Mt--;)Wt=Wn[Vn=ce&Vn+1],It=It*ie+Wn[ce&(Wn[Vn]=Wn[pn=ce&pn+Wt])+(Wn[pn]=Wt)];return Pt.i=Vn,Pt.j=pn,It})(ie)}function wt(an,un){return un.i=an.i,un.j=an.j,un.S=an.S.slice(),un}function ve(an,un){var Ae,vn=[],Pt=typeof an;if(un&&"object"==Pt)for(Ae in an)try{vn.push(ve(an[Ae],un-1))}catch{}return vn.length?vn:"string"==Pt?an:an+"\0"}function fn(an,un){for(var Pt,vn=an+"",Ae=0;Ae<vn.length;)un[ce&Ae]=ce&(Pt^=19*un[ce&Ae])+vn.charCodeAt(Ae++);return en(un)}function en(an){return String.fromCharCode.apply(0,an)}if(fn(X.random(),M),Ot.exports){Ot.exports=je;try{le=S(1234)}catch{}}else void 0!==(i=function(){return je}.call(Me,S,Me,Ot))&&(Ot.exports=i)}(typeof self<"u"?self:this,[],Math)},1425:Ot=>{function Me(){}Me.prototype={on:function(S,i,e){var M=this.e||(this.e={});return(M[S]||(M[S]=[])).push({fn:i,ctx:e}),this},once:function(S,i,e){var M=this;function X(){M.off(S,X),i.apply(e,arguments)}return X._=i,this.on(S,X,e)},emit:function(S){for(var i=[].slice.call(arguments,1),e=((this.e||(this.e={}))[S]||[]).slice(),M=0,X=e.length;M<X;M++)e[M].fn.apply(e[M].ctx,i);return this},off:function(S,i){var e=this.e||(this.e={}),M=e[S],X=[];if(M&&i)for(var ie=0,Q=M.length;ie<Q;ie++)M[ie].fn!==i&&M[ie].fn._!==i&&X.push(M[ie]);return X.length?e[S]=X:delete e[S],this}},Ot.exports=Me,Ot.exports.TinyEmitter=Me},1234:()=>{},616:function(Ot){Ot.exports=function(){"use strict";function Me(){return!0}function S(){return!1}function i(){}const e="Argument is not a typed-function.";return function M(){function ie(At){return"object"==typeof At&&null!==At&&At.constructor===Object}const Q=[{name:"number",test:function(At){return"number"==typeof At}},{name:"string",test:function(At){return"string"==typeof At}},{name:"boolean",test:function(At){return"boolean"==typeof At}},{name:"Function",test:function(At){return"function"==typeof At}},{name:"Array",test:Array.isArray},{name:"Date",test:function(At){return At instanceof Date}},{name:"RegExp",test:function(At){return At instanceof RegExp}},{name:"Object",test:ie},{name:"null",test:function(At){return null===At}},{name:"undefined",test:function(At){return void 0===At}}],Ee={name:"any",test:Me,isAny:!0};let he,q,oe=0,Z={createCount:0};function ce(At){const Bn=he.get(At);if(Bn)return Bn;let Mn='Unknown type "'+At+'"';const ni=At.toLowerCase();let qn;for(qn of q)if(qn.toLowerCase()===ni){Mn+='. Did you mean "'+qn+'" ?';break}throw new TypeError(Mn)}function le(At){let Bn=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"any";const Mn=Bn?ce(Bn).index:q.length,ni=[];for(let Ti=0;Ti<At.length;++Ti){if(!At[Ti]||"string"!=typeof At[Ti].name||"function"!=typeof At[Ti].test)throw new TypeError("Object with properties {name: string, test: function} expected");const Bi=At[Ti].name;if(he.has(Bi))throw new TypeError('Duplicate type name "'+Bi+'"');ni.push(Bi),he.set(Bi,{name:Bi,test:At[Ti].test,isAny:At[Ti].isAny,index:Mn+Ti,conversionsTo:[]})}const qn=q.slice(Mn);q=q.slice(0,Mn).concat(ni).concat(qn);for(let Ti=Mn+ni.length;Ti<q.length;++Ti)he.get(q[Ti]).index=Ti}function je(){he=new Map,q=[],oe=0,le([Ee],!1)}function wt(At){const Bn=q.filter(Mn=>{const ni=he.get(Mn);return!ni.isAny&&ni.test(At)});return Bn.length?Bn:["any"]}function ve(At){return At&&"function"==typeof At&&"_typedFunctionData"in At}function fn(At,Bn,Mn){if(!ve(At))throw new TypeError(e);const ni=Mn&&Mn.exact,Ti=Ae(Array.isArray(Bn)?Bn.join(","):Bn),Bi=an(Ti);if(!ni||Bi in At.signatures){const Jt=At._typedFunctionData.signatureMap.get(Bi);if(Jt)return Jt}const Gi=Ti.length;let Ii,Ki;if(ni){let Jt;for(Jt in Ii=[],At.signatures)Ii.push(At._typedFunctionData.signatureMap.get(Jt))}else Ii=At._typedFunctionData.signatures;for(let Jt=0;Jt<Gi;++Jt){const hi=Ti[Jt],Ft=[];let it;for(it of Ii){const sn=Wt(it.params,Jt);if(sn&&(!hi.restParam||sn.restParam)){if(!sn.hasAny){const Ve=Pt(sn);if(hi.types.some(He=>!Ve.has(He.name)))continue}Ft.push(it)}}if(Ii=Ft,0===Ii.length)break}for(Ki of Ii)if(Ki.params.length<=Gi)return Ki;throw new TypeError("Signature not found (signature: "+(At.name||"unnamed")+"("+an(Ti,", ")+"))")}function an(At){let Bn=arguments.length>1&&void 0!==arguments[1]?arguments[1]:",";return At.map(Mn=>Mn.name).join(Bn)}function un(At){const Bn=0===At.indexOf("..."),ni=(Bn?At.length>3?At.slice(3):"any":At).split("|").map(Gi=>ce(Gi.trim()));let qn=!1,Ti=Bn?"...":"";return{types:ni.map(function(Gi){return qn=Gi.isAny||qn,Ti+=Gi.name+"|",{name:Gi.name,typeIndex:Gi.index,test:Gi.test,isAny:Gi.isAny,conversion:null,conversionIndex:-1}}),name:Ti.slice(0,-1),hasAny:qn,hasConversion:!1,restParam:Bn}}function vn(At){const Mn=function Ht(At){if(0===At.length)return[];const Bn=At.map(ce);At.length>1&&Bn.sort((qn,Ti)=>qn.index-Ti.index);let Mn=Bn[0].conversionsTo;if(1===At.length)return Mn;Mn=Mn.concat([]);const ni=new Set(At);for(let qn=1;qn<Bn.length;++qn){let Ti;for(Ti of Bn[qn].conversionsTo)ni.has(Ti.from)||(Mn.push(Ti),ni.add(Ti.from))}return Mn}(At.types.map(Bi=>Bi.name));let ni=At.hasAny,qn=At.name;const Ti=Mn.map(function(Bi){const Gi=ce(Bi.from);return ni=Gi.isAny||ni,qn+="|"+Bi.from,{name:Bi.from,typeIndex:Gi.index,test:Gi.test,isAny:Gi.isAny,conversion:Bi,conversionIndex:Bi.index}});return{types:At.types.concat(Ti),name:qn,hasAny:ni,hasConversion:Ti.length>0,restParam:At.restParam}}function Pt(At){return At.typeSet||(At.typeSet=new Set,At.types.forEach(Bn=>At.typeSet.add(Bn.name))),At.typeSet}function Ae(At){const Bn=[];if("string"!=typeof At)throw new TypeError("Signatures must be strings");const Mn=At.trim();if(""===Mn)return Bn;const ni=Mn.split(",");for(let qn=0;qn<ni.length;++qn){const Ti=un(ni[qn].trim());if(Ti.restParam&&qn!==ni.length-1)throw new SyntaxError('Unexpected rest parameter "'+ni[qn]+'": only allowed for the last parameter');if(0===Ti.types.length)return null;Bn.push(Ti)}return Bn}function dt(At){const Bn=Qi(At);return!!Bn&&Bn.restParam}function ut(At){if(!At||0===At.types.length)return Me;if(1===At.types.length)return ce(At.types[0].name).test;if(2===At.types.length){const Bn=ce(At.types[0].name).test,Mn=ce(At.types[1].name).test;return function(qn){return Bn(qn)||Mn(qn)}}{const Bn=At.types.map(function(Mn){return ce(Mn.name).test});return function(ni){for(let qn=0;qn<Bn.length;qn++)if(Bn[qn](ni))return!0;return!1}}}function Mt(At){let Bn,Mn,ni;if(dt(At)){Bn=Ai(At).map(ut);const qn=Bn.length,Ti=ut(Qi(At)),Bi=function(Gi){for(let Ii=qn;Ii<Gi.length;Ii++)if(!Ti(Gi[Ii]))return!1;return!0};return function(Ii){for(let Ki=0;Ki<Bn.length;Ki++)if(!Bn[Ki](Ii[Ki]))return!1;return Bi(Ii)&&Ii.length>=qn+1}}return 0===At.length?function(Ti){return 0===Ti.length}:1===At.length?(Mn=ut(At[0]),function(Ti){return Mn(Ti[0])&&1===Ti.length}):2===At.length?(Mn=ut(At[0]),ni=ut(At[1]),function(Ti){return Mn(Ti[0])&&ni(Ti[1])&&2===Ti.length}):(Bn=At.map(ut),function(Ti){for(let Bi=0;Bi<Bn.length;Bi++)if(!Bn[Bi](Ti[Bi]))return!1;return Ti.length===Bn.length})}function Wt(At,Bn){return Bn<At.length?At[Bn]:dt(At)?Qi(At):null}function It(At,Bn){const Mn=Wt(At,Bn);return Mn?Pt(Mn):new Set}function Vn(At){return null==At.conversion}function pn(At,Bn){const Mn=new Set;return At.forEach(ni=>{const qn=It(ni.params,Bn);let Ti;for(Ti of qn)Mn.add(Ti)}),Mn.has("any")?["any"]:Array.from(Mn)}function Wn(At,Bn,Mn){let ni,qn;const Ti=At||"unnamed";let Gi,Bi=Mn;for(Gi=0;Gi<Bn.length;Gi++){const hi=[];if(Bi.forEach(Ft=>{const sn=ut(Wt(Ft.params,Gi));(Gi<Ft.params.length||dt(Ft.params))&&sn(Bn[Gi])&&hi.push(Ft)}),0===hi.length){if(qn=pn(Bi,Gi),qn.length>0){const Ft=wt(Bn[Gi]);return ni=new TypeError("Unexpected type of argument in function "+Ti+" (expected: "+qn.join(" or ")+", actual: "+Ft.join(" | ")+", index: "+Gi+")"),ni.data={category:"wrongType",fn:Ti,index:Gi,actual:Ft,expected:qn},ni}}else Bi=hi}const Ii=Bi.map(function(hi){return dt(hi.params)?1/0:hi.params.length});if(Bn.length<Math.min.apply(null,Ii))return qn=pn(Bi,Gi),ni=new TypeError("Too few arguments in function "+Ti+" (expected: "+qn.join(" or ")+", index: "+Bn.length+")"),ni.data={category:"tooFewArgs",fn:Ti,index:Bn.length,expected:qn},ni;const Ki=Math.max.apply(null,Ii);if(Bn.length>Ki)return ni=new TypeError("Too many arguments in function "+Ti+" (expected: "+Ki+", actual: "+Bn.length+")"),ni.data={category:"tooManyArgs",fn:Ti,index:Bn.length,expectedLength:Ki},ni;const Jt=[];for(let hi=0;hi<Bn.length;++hi)Jt.push(wt(Bn[hi]).join("|"));return ni=new TypeError('Arguments of type "'+Jt.join(", ")+'" do not match any of the defined signatures of function '+Ti+"."),ni.data={category:"mismatch",actual:Jt},ni}function ji(At){let Bn=q.length+1;for(let Mn=0;Mn<At.types.length;Mn++)Vn(At.types[Mn])&&(Bn=Math.min(Bn,At.types[Mn].typeIndex));return Bn}function An(At){let Bn=oe+1;for(let Mn=0;Mn<At.types.length;Mn++)Vn(At.types[Mn])||(Bn=Math.min(Bn,At.types[Mn].conversionIndex));return Bn}function St(At,Bn){if(At.hasAny){if(!Bn.hasAny)return 1}else if(Bn.hasAny)return-1;if(At.restParam){if(!Bn.restParam)return 1}else if(Bn.restParam)return-1;if(At.hasConversion){if(!Bn.hasConversion)return 1}else if(Bn.hasConversion)return-1;const Mn=ji(At)-ji(Bn);if(Mn<0)return-1;if(Mn>0)return 1;const ni=An(At)-An(Bn);return ni<0?-1:ni>0?1:0}function qt(At,Bn){const Mn=At.params,ni=Bn.params,qn=Qi(Mn),Ti=Qi(ni),Bi=dt(Mn),Gi=dt(ni);if(Bi&&qn.hasAny){if(!Gi||!Ti.hasAny)return 1}else if(Gi&&Ti.hasAny)return-1;let Jt,Ii=0,Ki=0;for(Jt of Mn)Jt.hasAny&&++Ii,Jt.hasConversion&&++Ki;let hi=0,Ft=0;for(Jt of ni)Jt.hasAny&&++hi,Jt.hasConversion&&++Ft;if(Ii!==hi)return Ii-hi;if(Bi&&qn.hasConversion){if(!Gi||!Ti.hasConversion)return 1}else if(Gi&&Ti.hasConversion)return-1;if(Ki!==Ft)return Ki-Ft;if(Bi){if(!Gi)return 1}else if(Gi)return-1;const it=(Mn.length-ni.length)*(Bi?-1:1);if(0!==it)return it;const sn=[];let He,Ve=0;for(let mt=0;mt<Mn.length;++mt){const bt=St(Mn[mt],ni[mt]);sn.push(bt),Ve+=bt}if(0!==Ve)return Ve;for(He of sn)if(0!==He)return He;return 0}function on(At,Bn){let Mn=Bn;if(At.some(qn=>qn.hasConversion)){const qn=dt(At),Ti=At.map(Cn);Mn=function(){const Gi=[],Ii=qn?arguments.length-1:arguments.length;for(let Ki=0;Ki<Ii;Ki++)Gi[Ki]=Ti[Ki](arguments[Ki]);return qn&&(Gi[Ii]=arguments[Ii].map(Ti[Ii])),Bn.apply(this,Gi)}}let ni=Mn;if(dt(At)){const qn=At.length-1;ni=function(){return Mn.apply(this,Xr(arguments,0,qn).concat([Xr(arguments,qn)]))}}return ni}function Cn(At){let Bn,Mn,ni,qn;const Ti=[],Bi=[];switch(At.types.forEach(function(Gi){Gi.conversion&&(Ti.push(ce(Gi.conversion.from).test),Bi.push(Gi.conversion.convert))}),Bi.length){case 0:return function(Ii){return Ii};case 1:return Bn=Ti[0],ni=Bi[0],function(Ii){return Bn(Ii)?ni(Ii):Ii};case 2:return Bn=Ti[0],Mn=Ti[1],ni=Bi[0],qn=Bi[1],function(Ii){return Bn(Ii)?ni(Ii):Mn(Ii)?qn(Ii):Ii};default:return function(Ii){for(let Ki=0;Ki<Bi.length;Ki++)if(Ti[Ki](Ii))return Bi[Ki](Ii);return Ii}}}function tn(At){return function Bn(Mn,ni,qn){if(ni<Mn.length){const Ti=Mn[ni];let Bi=[];if(Ti.restParam){const Gi=Ti.types.filter(Vn);Gi.length<Ti.types.length&&Bi.push({types:Gi,name:"..."+Gi.map(Ii=>Ii.name).join("|"),hasAny:Gi.some(Ii=>Ii.isAny),hasConversion:!1,restParam:!0}),Bi.push(Ti)}else Bi=Ti.types.map(function(Gi){return{types:[Gi],name:Gi.name,hasAny:Gi.isAny,hasConversion:Gi.conversion,restParam:!1}});return function eo(At,Bn){return Array.prototype.concat.apply([],At.map(Bn))}(Bi,function(Gi){return Bn(Mn,ni+1,qn.concat([Gi]))})}return[qn]}(At,0,[])}function fi(At,Bn){const Mn=Math.max(At.length,Bn.length);for(let Gi=0;Gi<Mn;Gi++){const Ii=It(At,Gi),Ki=It(Bn,Gi);let hi,Jt=!1;for(hi of Ki)if(Ii.has(hi)){Jt=!0;break}if(!Jt)return!1}const ni=At.length,qn=Bn.length,Ti=dt(At),Bi=dt(Bn);return Ti?Bi?ni===qn:qn>=ni:Bi?ni>=qn:ni===qn}function Dn(At,Bn,Mn){const ni=[];let qn;for(qn of At){let Ti=Mn[qn];if("number"!=typeof Ti)throw new TypeError('No definition for referenced signature "'+qn+'"');if(Ti=Bn[Ti],"function"!=typeof Ti)return!1;ni.push(Ti)}return ni}function gn(At,Bn,Mn){const ni=function Zn(At){return At.map(Bn=>yt(Bn)?mi(Bn.referToSelf.callback):ci(Bn)?uo(Bn.referTo.references,Bn.referTo.callback):Bn)}(At),qn=new Array(ni.length).fill(!1);let Ti=!0;for(;Ti;){Ti=!1;let Bi=!0;for(let Gi=0;Gi<ni.length;++Gi){if(qn[Gi])continue;const Ii=ni[Gi];if(yt(Ii))ni[Gi]=Ii.referToSelf.callback(Mn),ni[Gi].referToSelf=Ii.referToSelf,qn[Gi]=!0,Bi=!1;else if(ci(Ii)){const Ki=Dn(Ii.referTo.references,ni,Bn);Ki?(ni[Gi]=Ii.referTo.callback.apply(this,Ki),ni[Gi].referTo=Ii.referTo,qn[Gi]=!0,Bi=!1):Ti=!0}}if(Bi&&Ti)throw new SyntaxError("Circular reference detected in resolving typed.referTo")}return ni}function Yn(At,Bn){if(Z.createCount++,0===Object.keys(Bn).length)throw new SyntaxError("No signatures provided");Z.warnAgainstDeprecatedThis&&function Nn(At){const Bn=/\bthis(\(|\.signatures\b)/;Object.keys(At).forEach(Mn=>{if(Bn.test(At[Mn].toString()))throw new SyntaxError("Using `this` to self-reference a function is deprecated since typed-function@3. Use typed.referTo and typed.referToSelf instead.")})}(Bn);const Mn=[],ni=[],qn={},Ti=[];let Bi;for(Bi in Bn){if(!Object.prototype.hasOwnProperty.call(Bn,Bi))continue;const jn=Ae(Bi);if(!jn)continue;Mn.forEach(function(er){if(fi(er,jn))throw new TypeError('Conflicting signatures "'+an(er)+'" and "'+an(jn)+'".')}),Mn.push(jn);const Fi=ni.length;ni.push(Bn[Bi]);const Ui=jn.map(vn);let ar;for(ar of tn(Ui)){const er=an(ar);Ti.push({params:ar,name:er,fn:Fi}),ar.every(Or=>!Or.hasConversion)&&(qn[er]=Fi)}}Ti.sort(qt);const Gi=gn(ni,qn,Rt);let Ii;for(Ii in qn)Object.prototype.hasOwnProperty.call(qn,Ii)&&(qn[Ii]=Gi[qn[Ii]]);const Ki=[],Jt=new Map;for(Ii of Ti)Jt.has(Ii.name)||(Ii.fn=Gi[Ii.fn],Ki.push(Ii),Jt.set(Ii.name,Ii));const hi=Ki[0]&&Ki[0].params.length<=2&&!dt(Ki[0].params),Ft=Ki[1]&&Ki[1].params.length<=2&&!dt(Ki[1].params),it=Ki[2]&&Ki[2].params.length<=2&&!dt(Ki[2].params),sn=Ki[3]&&Ki[3].params.length<=2&&!dt(Ki[3].params),Ve=Ki[4]&&Ki[4].params.length<=2&&!dt(Ki[4].params),He=Ki[5]&&Ki[5].params.length<=2&&!dt(Ki[5].params),mt=hi&&Ft&&it&&sn&&Ve&&He;for(let jn=0;jn<Ki.length;++jn)Ki[jn].test=Mt(Ki[jn].params);const bt=hi?ut(Ki[0].params[0]):S,nn=Ft?ut(Ki[1].params[0]):S,Jn=it?ut(Ki[2].params[0]):S,Sn=sn?ut(Ki[3].params[0]):S,_r=Ve?ut(Ki[4].params[0]):S,qr=He?ut(Ki[5].params[0]):S,Bo=hi?ut(Ki[0].params[1]):S,Eo=Ft?ut(Ki[1].params[1]):S,Ro=it?ut(Ki[2].params[1]):S,Ls=sn?ut(Ki[3].params[1]):S,ol=Ve?ut(Ki[4].params[1]):S,Va=He?ut(Ki[5].params[1]):S;for(let jn=0;jn<Ki.length;++jn)Ki[jn].implementation=on(Ki[jn].params,Ki[jn].fn);const Ao=hi?Ki[0].implementation:i,za=Ft?Ki[1].implementation:i,vl=it?Ki[2].implementation:i,Na=sn?Ki[3].implementation:i,_l=Ve?Ki[4].implementation:i,gs=He?Ki[5].implementation:i,Zs=hi?Ki[0].params.length:-1,oa=Ft?Ki[1].params.length:-1,no=it?Ki[2].params.length:-1,xl=sn?Ki[3].params.length:-1,Qr=Ve?Ki[4].params.length:-1,dl=He?Ki[5].params.length:-1,Ya=mt?6:0,Lo=Ki.length,ko=Ki.map(jn=>jn.test),jt=Ki.map(jn=>jn.implementation),In=function(){for(let Fi=Ya;Fi<Lo;Fi++)if(ko[Fi](arguments))return jt[Fi].apply(this,arguments);return Z.onMismatch(At,arguments,Ki)};function Rt(jn,Fi){return arguments.length===Zs&&bt(jn)&&Bo(Fi)?Ao.apply(this,arguments):arguments.length===oa&&nn(jn)&&Eo(Fi)?za.apply(this,arguments):arguments.length===no&&Jn(jn)&&Ro(Fi)?vl.apply(this,arguments):arguments.length===xl&&Sn(jn)&&Ls(Fi)?Na.apply(this,arguments):arguments.length===Qr&&_r(jn)&&ol(Fi)?_l.apply(this,arguments):arguments.length===dl&&qr(jn)&&Va(Fi)?gs.apply(this,arguments):In.apply(this,arguments)}try{Object.defineProperty(Rt,"name",{value:At})}catch{}return Rt.signatures=qn,Rt._typedFunctionData={signatures:Ki,signatureMap:Jt},Rt}function cr(At,Bn,Mn){throw Wn(At,Bn,Mn)}function Ai(At){return Xr(At,0,At.length-1)}function Qi(At){return At[At.length-1]}function Xr(At,Bn,Mn){return Array.prototype.slice.call(At,Bn,Mn)}function uo(At,Bn){return{referTo:{references:At,callback:Bn}}}function mi(At){if("function"!=typeof At)throw new TypeError("Callback function expected as first argument");return{referToSelf:{callback:At}}}function ci(At){return At&&"object"==typeof At.referTo&&Array.isArray(At.referTo.references)&&"function"==typeof At.referTo.callback}function yt(At){return At&&"object"==typeof At.referToSelf&&"function"==typeof At.referToSelf.callback}function hn(At,Bn){if(!At)return Bn;if(Bn&&Bn!==At){const Mn=new Error("Function names do not match (expected: "+At+", actual: "+Bn+")");throw Mn.data={actual:Bn,expected:At},Mn}return At}function Gt(At){let Bn;for(const Mn in At)Object.prototype.hasOwnProperty.call(At,Mn)&&(ve(At[Mn])||"string"==typeof At[Mn].signature)&&(Bn=hn(Bn,At[Mn].name));return Bn}function Gn(At,Bn){let Mn;for(Mn in Bn)if(Object.prototype.hasOwnProperty.call(Bn,Mn)){if(Mn in At&&Bn[Mn]!==At[Mn]){const ni=new Error('Signature "'+Mn+'" is defined twice');throw ni.data={signature:Mn,sourceFunction:Bn[Mn],destFunction:At[Mn]},ni}At[Mn]=Bn[Mn]}}je(),le(Q);const ri=Z;function pi(At){if(!At||"string"!=typeof At.from||"string"!=typeof At.to||"function"!=typeof At.convert)throw new TypeError("Object with properties {from: string, to: string, convert: function} expected");if(At.to===At.from)throw new SyntaxError('Illegal to define conversion from "'+At.from+'" to itself.')}return Z=function(At){const Bn="string"==typeof At;let ni=Bn?At:"";const qn={};for(let Ti=Bn?1:0;Ti<arguments.length;++Ti){const Bi=arguments[Ti];let Ii,Gi={};if("function"==typeof Bi?(Ii=Bi.name,"string"==typeof Bi.signature?Gi[Bi.signature]=Bi:ve(Bi)&&(Gi=Bi.signatures)):ie(Bi)&&(Gi=Bi,Bn||(Ii=Gt(Bi))),0===Object.keys(Gi).length){const Ki=new TypeError("Argument to 'typed' at index "+Ti+" is not a (typed) function, nor an object with signatures as keys and functions as values.");throw Ki.data={index:Ti,argument:Bi},Ki}Bn||(ni=hn(ni,Ii)),Gn(qn,Gi)}return Yn(ni||"",qn)},Z.create=M,Z.createCount=ri.createCount,Z.onMismatch=cr,Z.throwMismatchError=cr,Z.createError=Wn,Z.clear=je,Z.clearConversions=function Et(){let At;for(At of q)he.get(At).conversionsTo=[];oe=0},Z.addTypes=le,Z._findType=ce,Z.referTo=function as(){const At=Ai(arguments).map(Mn=>an(Ae(Mn))),Bn=Qi(arguments);if("function"!=typeof Bn)throw new TypeError("Callback function expected as last argument");return uo(At,Bn)},Z.referToSelf=mi,Z.convert=function en(At,Bn){const Mn=ce(Bn);if(Mn.test(At))return At;const ni=Mn.conversionsTo;if(0===ni.length)throw new Error("There are no conversions to "+Bn+" defined.");for(let qn=0;qn<ni.length;qn++)if(ce(ni[qn].from).test(At))return ni[qn].convert(At);throw new Error("Cannot convert "+At+" to "+Bn)},Z.findSignature=fn,Z.find=function ct(At,Bn,Mn){return fn(At,Bn,Mn).implementation},Z.isTypedFunction=ve,Z.warnAgainstDeprecatedThis=!0,Z.addType=function(At,Bn){let Mn="any";!1!==Bn&&he.has("Object")&&(Mn="Object"),Z.addTypes([At],Mn)},Z.addConversion=function(At){let Bn=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{override:!1};pi(At);const Mn=ce(At.to),ni=Mn.conversionsTo.find(qn=>qn.from===At.from);if(ni){if(!Bn||!Bn.override)throw new Error('There is already a conversion from "'+At.from+'" to "'+Mn.name+'"');Z.removeConversion({from:ni.from,to:At.to,convert:ni.convert})}Mn.conversionsTo.push({from:At.from,convert:At.convert,index:oe++})},Z.addConversions=function(At,Bn){At.forEach(Mn=>Z.addConversion(Mn,Bn))},Z.removeConversion=function(At){pi(At);const Bn=ce(At.to),Mn=function Ur(At,Bn){for(let Mn=0;Mn<At.length;Mn++)if(Bn(At[Mn]))return At[Mn]}(Bn.conversionsTo,qn=>qn.from===At.from);if(!Mn)throw new Error("Attempt to remove nonexistent conversion from "+At.from+" to "+At.to);if(Mn.convert!==At.convert)throw new Error("Conversion to remove does not match existing conversion");const ni=Bn.conversionsTo.indexOf(Mn);Bn.conversionsTo.splice(ni,1)},Z.resolve=function(At,Bn){if(!ve(At))throw new TypeError(e);const Mn=At._typedFunctionData.signatures;for(let ni=0;ni<Mn.length;++ni)if(Mn[ni].test(Bn))return Mn[ni];return null},Z}()}()},4523:(Ot,Me,S)=>{function i(M,X,ie,Q,Ee,he,q){try{var oe=M[he](q),Z=oe.value}catch(ce){return void ie(ce)}oe.done?X(Z):Promise.resolve(Z).then(Q,Ee)}function e(M){return function(){var X=this,ie=arguments;return new Promise(function(Q,Ee){var he=M.apply(X,ie);function q(Z){i(he,Q,Ee,q,oe,"next",Z)}function oe(Z){i(he,Q,Ee,q,oe,"throw",Z)}q(void 0)})}}S.d(Me,{A:()=>e})},1922:(Ot,Me,S)=>{S.r(Me),S.d(Me,{ALL_VIEW_MODES:()=>np,ActionGroupMenuComponent:()=>Ph,ActionGroupMenuModule:()=>hm,ActionHandler:()=>kp,ActionLogicHandler:()=>WL,ActionMenuComponent:()=>VI,ActionMenuModule:()=>jI,ActionNameMapper:()=>Up,ActiveFieldsChecker:()=>ph,AdminCardComponent:()=>IP,AdminCardModule:()=>QL,AdminMetadataStore:()=>jr,AdminPanelComponent:()=>v3,AdminPanelModule:()=>cN,AppMetadataStore:()=>oo,AppStateStore:()=>tl,AsyncActionHandler:()=>Ym,AsyncActionService:()=>Tl,AsyncProcessLineAction:()=>yF,AsyncProcessRecordAction:()=>pN,AsyncProcessRecordThreadItemAction:()=>Xb,AsyncProcessRecordThreadListAction:()=>dO,AsyncProcessSubpanelAction:()=>k2,AsyncProcessSubpanelLineAction:()=>HF,AsyncProcessTableAction:()=>pk,AttributeBuilder:()=>E_,AuthGuard:()=>EP,AuthService:()=>Ka,BaseActionManager:()=>js,BaseActionsAdapter:()=>Vt,BaseBooleanComponent:()=>Fy,BaseChartComponent:()=>ob,BaseChartModule:()=>$1,BaseComponentRegistry:()=>jd,BaseComposite:()=>LS,BaseDateComponent:()=>My,BaseDateTimeComponent:()=>nC,BaseEnumComponent:()=>Uh,BaseFavoritesComponent:()=>qC,BaseField:()=>Hx,BaseFieldActionsAdapter:()=>Ba,BaseFieldComponent:()=>lu,BaseFieldGridComponent:()=>a_,BaseFieldHandler:()=>Xm,BaseFieldModule:()=>xP,BaseFieldRegistry:()=>Hf,BaseGroupedMenuItemComponent:()=>Kf,BaseHomeMenuItemComponent:()=>JS,BaseLineActionsAdapter:()=>bF,BaseLineItemsComponent:()=>PS,BaseMenuFavoritesComponent:()=>HT,BaseMenuItemComponent:()=>XS,BaseMenuItemLinkComponent:()=>MO,BaseMenuItemsListComponent:()=>tE,BaseMenuRecentlyViewedComponent:()=>iE,BaseMetadataResolver:()=>lN,BaseModuleResolver:()=>GL,BaseMultiEnumComponent:()=>J1,BaseNameComponent:()=>fS,BaseNavbarComponent:()=>rc,BaseNumberComponent:()=>eg,BaseRecordActionsAdapter:()=>Em,BaseRecordContainerStore:()=>Rd,BaseRecordResolver:()=>TP,BaseRelateComponent:()=>DS,BaseRouteService:()=>Ns,BaseSaveRecordMapper:()=>jh,BaseServiceRegistry:()=>pp,BaseSubMenuFavoritesComponent:()=>WA,BaseSubMenuRecentlyViewedComponent:()=>g0,BaseTypeRegistry:()=>J0,BaseWidgetComponent:()=>v0,BaseWidgetModule:()=>VL,BooleanCheckboxFilterFieldComponent:()=>Uy,BooleanCheckboxFilterFieldModule:()=>gC,BooleanDetailFieldComponent:()=>wb,BooleanDetailFieldModule:()=>og,BooleanEditFieldComponent:()=>By,BooleanEditFieldModule:()=>vT,BottomWidgetAdapter:()=>hN,BulkActionMenuComponent:()=>PM,BulkActionMenuModule:()=>GD,BulkActionsAdapter:()=>gA,BulkActionsAdapterFactory:()=>CN,Button:()=>ep,ButtonComponent:()=>xc,ButtonGroupComponent:()=>nb,ButtonGroupModule:()=>Fu,ButtonLoadingDirective:()=>jL,ButtonLoadingUiModule:()=>rN,ButtonModule:()=>Oa,ButtonUtils:()=>iS,CalculateValueBackendAction:()=>I,CancelCreateAction:()=>fN,CancelRecordPanelAction:()=>mA,ChangelogAsyncAction:()=>Z1,ChartComponent:()=>ew,ChartDataStore:()=>fL,ChartDataStoreFactory:()=>kF,ChartMessageAreaComponent:()=>mm,ChartMessageAreaModule:()=>Xg,ChartModule:()=>yy,ChartRegistry:()=>JD,ChartSidebarWidgetComponent:()=>PF,ChartSidebarWidgetModule:()=>BF,ClassicModalComponent:()=>gb,ClassicModalModule:()=>Hi,ClassicViewResolver:()=>ZL,ClassicViewUiComponent:()=>YL,ClassicViewUiModule:()=>XL,CloseButtonComponent:()=>Km,CloseButtonModule:()=>Zg,CollectionGQL:()=>e_,ColumnChooserComponent:()=>oS,ColumnChooserModule:()=>sS,CompositeComponent:()=>Pb,CompositeModule:()=>e0,ConditionOperatorActionHandler:()=>Vh,ConditionOperatorManager:()=>fb,ConfirmationModalService:()=>$e,CreateRecordComponent:()=>ZC,CreateRecordModule:()=>HP,CreateRelatedLineAction:()=>_F,CreateViewStore:()=>tA,CurrencyDetailFieldComponent:()=>iv,CurrencyDetailFieldModule:()=>hS,CurrencyFormatter:()=>Yg,CurrencyService:()=>ev,CurrencyUnitConverter:()=>cL,CurrencyValidator:()=>bC,DataTypeFormatter:()=>_s,DataTypeSeriesMapper:()=>dL,DataTypeUnitConverter:()=>uL,DateAdapter:()=>Cb,DateDetailFieldComponent:()=>iC,DateDetailFieldModule:()=>Iy,DateEditFieldComponent:()=>oC,DateEditFieldModule:()=>gT,DateFieldHandler:()=>cS,DateFilterFieldComponent:()=>ng,DateFilterFieldModule:()=>IS,DateFormatter:()=>r_,DateParserFormatter:()=>bb,DateTimeDetailFieldComponent:()=>rv,DateTimeDetailFieldModule:()=>cw,DateTimeEditFieldComponent:()=>yb,DateTimeEditFieldModule:()=>lw,DateTimeFilterFieldComponent:()=>Db,DateTimeFilterFieldModule:()=>sC,DateTimeModel:()=>tg,DateTimeValidator:()=>NS,DateValidator:()=>Gh,DatetimeFormatter:()=>kh,DefaultFieldHandler:()=>Ey,DisplayTypeAction:()=>nT,DisplayTypeBackendAction:()=>rw,DropdownButtonComponent:()=>pm,DropdownButtonModule:()=>Bh,DropdownEnumDetailFieldComponent:()=>Wp,DropdownEnumDetailFieldModule:()=>zM,DropdownEnumEditFieldComponent:()=>_m,DropdownEnumEditFieldModule:()=>Wh,DropdownSubmenuComponent:()=>WE,DropdownSubmenuModule:()=>my,DuplicateEmailValidator:()=>fv,DynamicFieldComponent:()=>Gu,DynamicFieldModule:()=>uv,DynamicLabelComponent:()=>Df,DynamicLabelModule:()=>dh,DynamicLabelService:()=>rb,EDITABLE_VIEW_MODES:()=>dm,EmailDetailFieldsComponent:()=>SP,EmailDetailFieldsModule:()=>UL,EmailFormatter:()=>RS,EmailListFieldsComponent:()=>uw,EmailListFieldsModule:()=>sT,EmailPrimarySelectAction:()=>c_,EmailValidator:()=>uu,EntityGQL:()=>t_,EntityMutationGQL:()=>BD,EnumDetailFieldComponent:()=>dS,EnumDetailFieldModule:()=>_b,EnumEditFieldComponent:()=>jp,EnumEditFieldModule:()=>WM,ErrorInterceptor:()=>HL,ExportAsyncAction:()=>iw,ExtensionLoader:()=>aN,FavoriteToggleComponent:()=>ZR,FavoriteToggleModule:()=>DF,FavoritesService:()=>CF,FieldActionHandler:()=>a,FieldActionManager:()=>K,FieldActionsAdapter:()=>L_,FieldActionsAdapterFactory:()=>PC,FieldBuilder:()=>zf,FieldClearAction:()=>u,FieldComponent:()=>Dm,FieldCopyAction:()=>x,FieldGridComponent:()=>I_,FieldGridModule:()=>gv,FieldHandlerRegistry:()=>ow,FieldLayoutComponent:()=>c,FieldLayoutModule:()=>g,FieldLogicActionHandler:()=>fh,FieldLogicDisplayActionHandler:()=>vb,FieldLogicDisplayManager:()=>qo,FieldLogicDisplayTypeAction:()=>pb,FieldLogicManager:()=>Qs,FieldManager:()=>_p,FieldModule:()=>pa,FieldObjectRegistry:()=>Hc,FieldRegistry:()=>t0,FileDetailFieldComponent:()=>uC,FileDetailFieldModule:()=>xb,FilterAdapter:()=>DN,FilterAttributeBuilder:()=>xC,FilterFieldBuilder:()=>wC,FilterListStore:()=>Du,FilterListStoreFactory:()=>Bw,FiltersListGQL:()=>mg,FloatDetailFieldComponent:()=>p_,FloatDetailFieldModule:()=>Sb,FloatValidator:()=>x_,FooterUiComponent:()=>nl,FooterUiModule:()=>OA,FormControlUtils:()=>qg,FormatCurrencyModule:()=>Jm,FormatCurrencyPipe:()=>u_,FormatNumberModule:()=>fw,FormatNumberPipe:()=>f_,FullNameDetailFieldsComponent:()=>tC,FullNameDetailFieldsModule:()=>tv,FullPageSpinnerComponent:()=>ET,FullPageSpinnerModule:()=>FA,GlobalRecentlyViewedStore:()=>br,GlobalSearch:()=>il,GreaterThanAction:()=>Jg,GridWidgetComponent:()=>Ku,GridWidgetModule:()=>p0,GroupFieldBuilder:()=>mv,GroupFieldComponent:()=>dg,GroupFieldModule:()=>fg,GroupedButtonComponent:()=>WD,GroupedButtonModule:()=>ip,GroupedMenuItemComponent:()=>kO,GroupedMenuItemRegistry:()=>eE,HistorySidebarWidgetComponent:()=>KI,HistorySidebarWidgetModule:()=>qI,HistoryTimelineAdapter:()=>F2,HistoryTimelineAdapterFactory:()=>N2,HistoryTimelineStore:()=>mL,HistoryTimelineStoreFactory:()=>O2,HomeMenuItemComponent:()=>qA,HomeMenuItemRegistry:()=>OO,HtmlDetailFieldComponent:()=>FS,HtmlDetailFieldModule:()=>ag,HtmlSanitizeModule:()=>oN,HtmlSanitizePipe:()=>$L,IconDetailFieldComponent:()=>Wy,IconListFieldModule:()=>ym,IframePageChangeObserver:()=>Uf,IframeResizeHandlerHandler:()=>Sy,ImageComponent:()=>Bl,ImageModule:()=>Vl,ImmediateDebounce:()=>YR,InlineLoadingSpinnerComponent:()=>HD,InlineLoadingSpinnerModule:()=>gy,InstallAction:()=>fA,InstallActionManager:()=>eO,InstallActionsAdapter:()=>ck,InstallAuthGuard:()=>sN,InstallContainerComponent:()=>pA,InstallContainerModule:()=>zP,InstallContentAdapter:()=>_N,InstallErrorModalComponent:()=>Kp,InstallErrorModalModule:()=>HC,InstallHeaderComponent:()=>hA,InstallHeaderModule:()=>uk,InstallViewActionHandler:()=>dA,InstallViewComponent:()=>tO,InstallViewModule:()=>dk,InstallViewStore:()=>t1,IntDetailFieldComponent:()=>jy,IntDetailFieldModule:()=>ww,IntValidator:()=>Yy,IsEmptyAction:()=>l_,IsEqualAction:()=>X1,LabelComponent:()=>Pa,LabelModule:()=>Ea,LanguageStore:()=>Kr,LegacyEntrypointLinkBuilder:()=>cC,LessThanAction:()=>aS,LineActionActionHandler:()=>zI,LineActionActionManager:()=>S2,LineActionEvent:()=>$g,LineActionMenuComponent:()=>qb,LineActionModule:()=>Uw,LineActionsAdapter:()=>vA,LineChartComponent:()=>Vp,LineChartModule:()=>XD,LineItemBuilder:()=>SC,LineItemsComponent:()=>CT,LineItemsModule:()=>a0,LineItemsRequiredValidator:()=>kb,LinkModel:()=>os,LinkRouteAsyncActionService:()=>C_,LinkTarget:()=>Ts,ListComponent:()=>zn,ListContainerComponent:()=>w,ListContainerModule:()=>L,ListFilterComponent:()=>I2,ListFilterModule:()=>A2,ListFilterStore:()=>AF,ListFilterStoreFactory:()=>OF,ListGQL:()=>h_,ListHeaderComponent:()=>ft,ListHeaderModule:()=>Xt,ListModule:()=>xi,ListViewRecordPanelActionAdapterFactory:()=>mk,ListViewRecordPanelActionHandler:()=>yN,ListViewRecordPanelActionsAdapter:()=>SN,ListViewSidebarWidgetAdapter:()=>nO,ListViewSidebarWidgetService:()=>uE,ListViewStore:()=>Qp,ListViewTableActionsAdapter:()=>hk,ListViewUrlQueryService:()=>dF,ListviewTableActionsAdapterFactory:()=>yA,LoadMoreComponent:()=>vh,LoadMoreModule:()=>KS,LoadingBuffer:()=>VD,LoadingBufferFactory:()=>zg,LoadingSpinnerComponent:()=>af,LoadingSpinnerModule:()=>jf,LocalStorageService:()=>Zu,LoginAuthGuard:()=>h3,LoginUiComponent:()=>gk,LoginUiModule:()=>JC,LoginUiRoutes:()=>ix,LogoAbstract:()=>$w,LogoUiComponent:()=>bp,LogoUiModule:()=>Qb,LogoutComponent:()=>qP,LogoutModule:()=>vk,LogoutUiComponent:()=>KC,LogoutUiModule:()=>k_,MaxColumnsCalculator:()=>rg,MenuFavoritesComponent:()=>TI,MenuFavoritesRegistry:()=>zT,MenuItemComponent:()=>KA,MenuItemLinkComponent:()=>Gw,MenuItemLinkRegistry:()=>m0,MenuItemRegistry:()=>ZS,MenuItemsListComponent:()=>QA,MenuItemsListRegistry:()=>BO,MenuRecentlyViewedComponent:()=>TR,MenuRecentlyViewedRegistry:()=>s2,MessageModalComponent:()=>Ye,MessageModalModule:()=>fs,MessageService:()=>bo,MessageTypes:()=>Pf,MessageUiComponent:()=>bn,MessageUiModule:()=>ui,MetadataStore:()=>Fs,MinimiseButtonComponent:()=>Ul,MinimiseButtonModule:()=>gh,MobileMenuComponent:()=>sM,ModalButtonGroupComponent:()=>ye,ModalButtonGroupModule:()=>yr,ModalComponent:()=>qm,ModalModule:()=>Qm,ModalRecordFilterAdapter:()=>Ry,ModalRecordListTableAdapter:()=>yS,ModuleNameMapper:()=>Ac,ModuleNavigation:()=>Oc,ModuleTitleComponent:()=>co,ModuleTitleModule:()=>Do,MultiEnumDetailFieldComponent:()=>d_,MultiEnumDetailFieldModule:()=>lC,MultiEnumEditFieldComponent:()=>Vy,MultiEnumEditFieldModule:()=>Dw,MultiEnumField:()=>DC,MultiEnumFieldHandler:()=>iT,MultiEnumFilterFieldComponent:()=>Zm,MultiEnumFilterFieldModule:()=>Ab,NavbarAbstract:()=>gl,NavbarRegistry:()=>UT,NavbarUiComponent:()=>eF,NavbarUiModule:()=>QT,NavigationStore:()=>pr,NoopAsyncAction:()=>tT,NotEmptyAction:()=>by,NotEqualAction:()=>gm,NotificationStore:()=>hs,NotificationsComponent:()=>P_,NotificationsModule:()=>KT,NotificationsService:()=>ha,NumberFormatter:()=>Qg,OverridableMap:()=>um,PageSelection:()=>eu,PaginationComponent:()=>Qw,PaginationModule:()=>l2,PaginationType:()=>Jv,PanelComponent:()=>wl,PanelLogicActionHandler:()=>ST,PanelLogicDisplayTypeAction:()=>HS,PanelLogicManager:()=>R_,PanelModule:()=>xm,PasswordDetailFieldComponent:()=>$y,PasswordDetailFieldModule:()=>Rb,PasswordEditFieldComponent:()=>Sw,PasswordEditFieldModule:()=>b_,PhoneDetailFieldComponent:()=>vp,PhoneDetailFieldModule:()=>TS,PhoneFormatter:()=>fy,PhoneValidator:()=>iu,PieGridChartComponent:()=>ab,PieGridChartModule:()=>K1,PopupButtonComponent:()=>Yw,PopupButtonModule:()=>c2,PrimaryEmailValidator:()=>Zy,ProcessService:()=>bf,QuickFiltersService:()=>UI,RadioEnumDetailFieldComponent:()=>sg,RadioEnumDetailFieldModule:()=>av,RadioEnumEditFieldComponent:()=>Ys,RadioEnumEditFieldModule:()=>lv,RangeValidator:()=>S_,RecentlyViewedComponent:()=>cI,RecentlyViewedService:()=>JI,RecordActionDisplayTypeLogic:()=>FP,RecordActionHandler:()=>e1,RecordActionManager:()=>ek,RecordActionsAdapter:()=>mM,RecordCancelAction:()=>uN,RecordComponent:()=>lk,RecordContainerComponent:()=>q2,RecordContainerModule:()=>X2,RecordContentAdapter:()=>z2,RecordContentComponent:()=>Xw,RecordContentModule:()=>oM,RecordContentSkeletonComponent:()=>LR,RecordContentSkeletonModule:()=>lF,RecordConvertService:()=>kC,RecordCreateAction:()=>hM,RecordDetailsPopupButtonComponent:()=>FI,RecordDetailsPopupButtonModule:()=>oE,RecordEditAction:()=>nA,RecordFetchGQL:()=>jl,RecordFlexboxComponent:()=>FT,RecordFlexboxModule:()=>GT,RecordGridComponent:()=>a2,RecordGridModule:()=>QC,RecordHeaderComponent:()=>cE,RecordHeaderModule:()=>Z2,RecordListModalComponent:()=>Py,RecordListModalModule:()=>qk,RecordListModalStore:()=>ky,RecordListModalStoreFactory:()=>uT,RecordListStore:()=>mw,RecordListStoreFactory:()=>$p,RecordManager:()=>Dd,RecordMapperRegistry:()=>cy,RecordModule:()=>uA,RecordPaginationComponent:()=>mN,RecordPaginationService:()=>lE,RecordPaginationStore:()=>aA,RecordPanelActionHandler:()=>oL,RecordPanelActionManager:()=>bN,RecordPanelAdapter:()=>gM,RecordPanelComponent:()=>FF,RecordPanelModule:()=>sL,RecordPanelStore:()=>NF,RecordPanelStoreFactory:()=>aL,RecordSaveAction:()=>JL,RecordSaveContinueAction:()=>OP,RecordSaveGQL:()=>Co,RecordSaveNewAction:()=>iA,RecordStore:()=>wd,RecordStoreFactory:()=>Os,RecordStoreList:()=>Ml,RecordThreadComponent:()=>RT,RecordThreadItemActionHandler:()=>Ww,RecordThreadItemActionManager:()=>QS,RecordThreadItemActionsAdapter:()=>gg,RecordThreadItemActionsAdapterFactory:()=>yv,RecordThreadItemCancelAction:()=>Dp,RecordThreadItemComponent:()=>BA,RecordThreadItemEditAction:()=>zc,RecordThreadItemModule:()=>AI,RecordThreadItemSaveAction:()=>fO,RecordThreadItemStore:()=>Cr,RecordThreadItemStoreFactory:()=>So,RecordThreadListActionHandler:()=>AT,RecordThreadListActionManager:()=>nI,RecordThreadListActionsAdapter:()=>RA,RecordThreadListActionsAdapterFactory:()=>iI,RecordThreadModule:()=>qw,RecordThreadSidebarWidgetComponent:()=>UF,RecordThreadSidebarWidgetModule:()=>sP,RecordThreadStore:()=>Po,RecordThreadStoreFactory:()=>wi,RecordToggleWidgetsAction:()=>dN,RecordValidationHandler:()=>M_,RecordViewSidebarWidgetService:()=>rA,RecordViewStore:()=>uf,RecoverPasswordService:()=>KL,RedirectAsyncAction:()=>mc,RelateDetailFieldComponent:()=>dC,RelateDetailFieldsModule:()=>Ob,RelateEditFieldComponent:()=>v_,RelateEditFieldModule:()=>SS,RelateFilterFieldComponent:()=>Ib,RelateFilterFieldModule:()=>MS,RelateService:()=>$h,RequiredAction:()=>JE,RequiredValidator:()=>mb,RouteConverter:()=>Xs,RunBulkActionRecordPanelAction:()=>fk,SaveFilterStoreFactory:()=>IF,SavedFilterActionAdapterFactory:()=>iL,SavedFilterActionHandler:()=>E2,SavedFilterActionManager:()=>SF,SavedFilterActionsAdapter:()=>nL,SavedFilterDeleteAction:()=>xF,SavedFilterRecordStore:()=>EF,SavedFilterRecordStoreFactory:()=>T2,SavedFilterSaveAction:()=>wF,SavedFilterSaveGQL:()=>eL,SavedFilterStore:()=>MF,SavedSearchRecordMapper:()=>tL,ScreenSize:()=>$d,ScreenSizeObserverService:()=>Wd,SearchBarComponent:()=>Yb,SearchBarModule:()=>qT,SelectColumnsTableAction:()=>_A,SelectModalService:()=>ht,SelectionStatus:()=>Xu,SeriesMapper:()=>LF,SeriesStatisticsStore:()=>RF,SeriesStatisticsStoreFactory:()=>wp,SeriesTraverser:()=>lL,SettingsMenuComponent:()=>_2,SettingsMenuModule:()=>y2,SidebarComponent:()=>PR,SidebarWidgetAdapter:()=>tk,SidebarWidgetComponent:()=>XI,SidebarWidgetModule:()=>B2,SidebarWidgetRegistry:()=>XF,SingleValueStatisticsStore:()=>No,SingleValueStatisticsStoreFactory:()=>Hr,SortButtonComponent:()=>m2,SortButtonModule:()=>cF,SortDirection:()=>hp,StandardFieldRegistry:()=>Nd,StateManager:()=>ys,StatisticsBatch:()=>N_,StatisticsFetchGQL:()=>us,StatisticsSidebarWidgetComponent:()=>$F,StatisticsSidebarWidgetModule:()=>DL,StatisticsStore:()=>xo,StatisticsStoreFactory:()=>eA,StatisticsTopWidgetComponent:()=>j2,StatisticsTopWidgetModule:()=>BL,StatusBarComponent:()=>g2,StatusBarModule:()=>Zw,SubMenuFavoritesComponent:()=>zA,SubMenuFavoritesRegistry:()=>HA,SubMenuRecentlyViewedComponent:()=>mI,SubMenuRecentlyViewedRegistry:()=>kT,SubpanelActionAdapterFactory:()=>TL,SubpanelActionHandler:()=>Jw,SubpanelActionManager:()=>XC,SubpanelActionsAdapter:()=>EL,SubpanelClearFilterAction:()=>aP,SubpanelComponent:()=>YF,SubpanelContainerComponent:()=>NL,SubpanelContainerModule:()=>eN,SubpanelCreateAction:()=>wL,SubpanelFilterAdapter:()=>SL,SubpanelFilterAdapterFactory:()=>P2,SubpanelLineActionHandler:()=>WF,SubpanelLineActionManager:()=>zF,SubpanelLineActionsAdapter:()=>GF,SubpanelLineActionsAdapterFactory:()=>dM,SubpanelModule:()=>QI,SubpanelSelectAction:()=>qF,SubpanelShowFilterAction:()=>QF,SubpanelStore:()=>F_,SubpanelStoreFactory:()=>Gb,SubpanelTableAdapter:()=>KF,SubpanelTableAdapterFactory:()=>xL,SystemConfigStore:()=>zo,SystemNameService:()=>MP,TableActionHandler:()=>wN,TableActionManager:()=>xN,TableAdapter:()=>EN,TableBodyComponent:()=>C2,TableBodyModule:()=>vF,TableComponent:()=>HI,TableFooterComponent:()=>D2,TableFooterModule:()=>QR,TableHeaderComponent:()=>uM,TableHeaderModule:()=>w2,TableModule:()=>x2,TextDetailFieldComponent:()=>Oy,TextDetailFieldModule:()=>yw,TextEditFieldComponent:()=>Fb,TextEditFieldModule:()=>Nb,TextListFieldComponent:()=>Ew,TextListFieldModule:()=>Wc,ThemeImagesStore:()=>uh,TinymceDetailFieldComponent:()=>zi,TinymceDetailFieldModule:()=>yC,TinymceEditFieldComponent:()=>nu,TinymceEditFieldModule:()=>Cu,ToObservableModule:()=>aF,ToObservablePipe:()=>u2,TopWidgetAdapter:()=>oA,TopWidgetComponent:()=>DP,TopWidgetModule:()=>wP,TruncatePipe:()=>Hd,TwoFactorAuthGuard:()=>zL,TwoFactorCheckComponent:()=>Nr,TwoFactorCheckModalComponent:()=>iO,TwoFactorCheckModalModule:()=>fE,TwoFactorCheckModule:()=>n1,TwoFactorComponent:()=>Cv,TwoFactorModule:()=>Kl,UpdateBaseCurrencyAction:()=>jM,UpdateCurrencyAction:()=>wy,UpdateFlexRelateModuleAction:()=>eT,UpdateValueAction:()=>xy,UpdateValueBackendAction:()=>lS,UrlDetailFieldComponent:()=>wf,UrlDetailFieldModule:()=>mC,User:()=>tp,UserPreferenceStore:()=>$a,UserService:()=>m3,ValidationManager:()=>pv,VarcharDetailFieldComponent:()=>nv,VarcharDetailFieldModule:()=>vC,VarcharEditFieldComponent:()=>aw,VarcharEditFieldModule:()=>__,VarcharFilterFieldComponent:()=>dw,VarcharFilterFieldModule:()=>_S,VerticalBarChartComponent:()=>cb,VerticalBarChartModule:()=>G1,ViewStore:()=>LC,WidgetPanelComponent:()=>f0,WidgetPanelModule:()=>Gp,alertTypes:()=>_v,baseFieldComponents:()=>cg,baseFieldModules:()=>Hy,baseObjectFieldsTypeMap:()=>hv,baseViewFieldsMap:()=>hh,booleanRequiredValidator:()=>hb,chartModules:()=>ZD,chartTypeMap:()=>s_,componentTypeMap:()=>fM,currencyValidator:()=>Qy,dateTimeValidator:()=>CC,dateValidator:()=>pg,deepClone:()=>dr,duplicateEmailValidator:()=>dd,emailValidator:()=>cf,emptyObject:()=>_a,fieldComponents:()=>T_,fieldModules:()=>Bb,floatValidator:()=>ud,intValidator:()=>hg,isEditable:()=>PD,isEmptyString:()=>Ud,isFalse:()=>sf,isTrue:()=>cl,isVoid:()=>Al,lineItemsRequiredValidator:()=>GM,maxValidator:()=>Cm,minValidator:()=>dv,multienumRequiredValidator:()=>Dy,padObjectValues:()=>Wg,phoneValidator:()=>Lb,primaryEmailValidator:()=>Xy,ready:()=>uy,requiredValidator:()=>Cy,sidebarWidgetModules:()=>YI,topWidgetComponentTypeMap:()=>$2,topWidgetModules:()=>U2,viewFieldsMap:()=>Fw});var i=S(1647),e=S(1270),M=S(9335),X=S(788),ie=S(4085),Q=S(6860);const he=new Set;let q,oe=(()=>{class r{constructor(t,n){this._platform=t,this._nonce=n,this._matchMedia=this._platform.isBrowser&&window.matchMedia?window.matchMedia.bind(window):ce}matchMedia(t){return(this._platform.WEBKIT||this._platform.BLINK)&&function Z(r,v){if(!he.has(r))try{q||(q=document.createElement("style"),v&&q.setAttribute("nonce",v),q.setAttribute("type","text/css"),document.head.appendChild(q)),q.sheet&&(q.sheet.insertRule(`@media ${r} {body{ }}`,0),he.add(r))}catch(t){console.error(t)}}(t,this._nonce),this._matchMedia(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Q.OD),e.\u0275\u0275inject(e.CSP_NONCE,8))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function ce(r){return{matches:"all"===r||""===r,media:r,addListener:()=>{},removeListener:()=>{}}}let le=(()=>{class r{constructor(t,n){this._mediaMatcher=t,this._zone=n,this._queries=new Map,this._destroySubject=new i.Subject}ngOnDestroy(){this._destroySubject.next(),this._destroySubject.complete()}isMatched(t){return je((0,ie.FG)(t)).some(o=>this._registerQuery(o).mql.matches)}observe(t){const o=je((0,ie.FG)(t)).map(D=>this._registerQuery(D).observable);let f=(0,i.combineLatest)(o);return f=(0,i.concat)(f.pipe((0,M.take)(1)),f.pipe((0,M.skip)(1),(0,M.debounceTime)(0))),f.pipe((0,M.map)(D=>{const j={matches:!1,breakpoints:{}};return D.forEach(({matches:fe,query:Ne})=>{j.matches=j.matches||fe,j.breakpoints[Ne]=fe}),j}))}_registerQuery(t){if(this._queries.has(t))return this._queries.get(t);const n=this._mediaMatcher.matchMedia(t),f={observable:new i.Observable(D=>{const j=fe=>this._zone.run(()=>D.next(fe));return n.addListener(j),()=>{n.removeListener(j)}}).pipe((0,M.startWith)(n),(0,M.map)(({matches:D})=>({query:t,matches:D})),(0,M.takeUntil)(this._destroySubject)),mql:n};return this._queries.set(t,f),f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(oe),e.\u0275\u0275inject(e.NgZone))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function je(r){return r.map(v=>v.split(",")).reduce((v,t)=>v.concat(t)).map(v=>v.trim())}const Et_Small="(min-width: 600px) and (max-width: 959.98px)";var wt=S(1834),ve=S(2168),fn=S(5048),ct=S(677),en=S(9218),an=S(2125),un=S(9532),vn=S(2662);const Ae=new e.InjectionToken("EventArgument",{providedIn:"root",factory:function Pt(){return"$event"}}),ut=new e.InjectionToken("IoEventContext"),Mt=new e.InjectionToken("IoEventContextProvider"),Wt=new e.InjectionToken("DynamicComponentInjector");let It=(()=>{class r{constructor(){this.trackOutputChanges=!1}}return r.\u0275fac=function(t){return new(t||r)},r.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"}),r})(),Vn=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){if(this.injector=t,this.differs=n,this.cfr=o,this.options=f,this.compInjector=D,this.eventArgument=j,this.cdr=fe,this.eventContextProvider=Ne,this.lastComponentInst=null,this.lastChangedInputs=new Set,this.inputsDiffer=this.differs.find({}).create(),this.compFactory=null,this.outputsShouldDisconnect$=new i.Subject,this.inputs={},this.outputs={},this.outputsChanged=()=>!1,this.options.trackOutputChanges){const vt=this.differs.find({}).create();this.outputsChanged=ln=>!!vt.diff(ln)}}get compRef(){return this.compInjector.componentRef}get componentInst(){return this.compRef?this.compRef.instance:null}get componentInstChanged(){return this.lastComponentInst!==this.componentInst&&(this.lastComponentInst=this.componentInst,!0)}ngOnDestroy(){this.disconnectOutputs()}update(t,n){if(!this.compRef)return void this.disconnectOutputs();const o=this.updateIO(t,n),f=this.componentInstChanged,D=this.getInputsChanges(f),j=this.outputsChanged(this.outputs);D&&this.updateChangedInputs(D),(f||D)&&this.updateInputs(f||!this.lastChangedInputs.size),(f||j||o.outputsChanged)&&this.bindOutputs()}updateIO(t,n){t||(t={}),n||(n={});const o=this.inputs!==t,f=this.outputs!==n;return this.inputs=t,this.outputs=n,{inputsChanged:o,outputsChanged:f}}updateInputs(t=!1){t&&this.updateCompFactory();const n=this.compRef,o=this.inputs;if(!o||!n)return;const f=this.lastChangedInputs.size?D=>this.lastChangedInputs.has(D):()=>!0;Object.keys(o).filter(f).forEach(D=>n.setInput(D,o[D]))}bindOutputs(){this.disconnectOutputs();const t=this.componentInst;let n=this.outputs;!n||!t||(n=this.resolveOutputs(n),Object.keys(n).filter(o=>t[o]).forEach(o=>t[o].pipe((0,M.takeUntil)(this.outputsShouldDisconnect$)).subscribe(f=>(this.cdr.markForCheck(),n[o](f)))))}disconnectOutputs(){this.outputsShouldDisconnect$.next()}getInputsChanges(t){return t&&this.inputsDiffer.diff({}),this.inputsDiffer.diff(this.inputs)}updateChangedInputs(t){this.lastChangedInputs.clear();const n=o=>this.lastChangedInputs.add(o.key);t.forEachAddedItem(n),t.forEachChangedItem(n),t.forEachRemovedItem(n)}resolveCompFactory(){if(!this.compRef)return null;try{try{return this.cfr.resolveComponentFactory(this.compRef.componentType)}catch{return this.cfr.resolveComponentFactory(this.compRef.instance.constructor)}}catch{return null}}updateCompFactory(){this.compFactory=this.resolveCompFactory()}resolveOutputs(t){return this.updateOutputsEventContext(),t=this.processOutputs(t),this.compFactory?this.remapIO(t,this.compFactory.outputs):t}updateOutputsEventContext(){if(this.eventContextProvider){const t=e.Injector.create({name:"EventContext",parent:this.injector,providers:[this.eventContextProvider]});this.outputsEventContext=t.get(ut)}else this.outputsEventContext=this.injector.get(ut,null)}processOutputs(t){const n={};return Object.keys(t).forEach(o=>{const f=t[o];let D;D="function"==typeof f?f:f&&this.processOutputArgs(f),this.outputsEventContext&&D&&(D=D.bind(this.outputsEventContext)),n[o]=D}),n}processOutputArgs(t){const n=this.eventArgument,o="args"in t?t.args||[]:[n],f=o.indexOf(n),D=t.handler;return-1===f?function(){return D.apply(this,o)}:function(j){const fe=[...o];return fe[f]=j,D.apply(this,fe)}}remapIO(t,n){const o={};return Object.keys(t).forEach(f=>{const D=this.findPropByTplInMapping(f,n)||f;o[D]=t[f]}),o}findPropByTplInMapping(t,n){for(const o of n)if(o.templateName===t)return o.propName;return null}}return r.\u0275fac=function(t){return new(t||r)(e.\u0275\u0275inject(e.Injector),e.\u0275\u0275inject(e.KeyValueDiffers),e.\u0275\u0275inject(e.ComponentFactoryResolver),e.\u0275\u0275inject(It),e.\u0275\u0275inject(Wt),e.\u0275\u0275inject(Ae),e.\u0275\u0275inject(e.ChangeDetectorRef),e.\u0275\u0275inject(Mt,8))},r.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac}),r})(),An=(()=>{class r{}return r.\u0275fac=function(t){return new(t||r)},r.\u0275mod=e.\u0275\u0275defineNgModule({type:r}),r.\u0275inj=e.\u0275\u0275defineInjector({}),r})(),St=(()=>{class r{constructor(t){this.ioService=t}ngDoCheck(){this.ioService.update(this.ndcDynamicInputs,this.ndcDynamicOutputs)}}return r.\u0275fac=function(t){return new(t||r)(e.\u0275\u0275directiveInject(Vn))},r.\u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","ndcDynamicInputs",""],["","ndcDynamicOutputs",""]],inputs:{ndcDynamicInputs:"ndcDynamicInputs",ndcDynamicOutputs:"ndcDynamicOutputs"},exportAs:["ndcDynamicIo"],standalone:!0,features:[e.\u0275\u0275ProvidersFeature([Vn])]}),r})(),qt=(()=>{class r{}return r.\u0275fac=function(t){return new(t||r)},r.\u0275mod=e.\u0275\u0275defineNgModule({type:r}),r.\u0275inj=e.\u0275\u0275defineInjector({imports:[An]}),r})(),Ht=(()=>{class r{constructor(t){this.vcr=t,this.ndcDynamicCreated=new e.EventEmitter,this.componentRef=null}ngOnChanges(t){r.UpdateOnInputs.some(n=>t.hasOwnProperty(n))&&this.createDynamicComponent()}createDynamicComponent(){this.vcr.clear(),this.componentRef=null,this.ndcDynamicComponent&&(this.componentRef=this.vcr.createComponent(this.ndcDynamicComponent,{index:0,injector:this._resolveInjector(),projectableNodes:this.ndcDynamicContent,ngModuleRef:this.ndcDynamicNgModuleRef,environmentInjector:this.ndcDynamicEnvironmentInjector}),this.ndcDynamicCreated.emit(this.componentRef))}_resolveInjector(){let t=this.ndcDynamicInjector||this.vcr.injector;return this.ndcDynamicProviders&&(t=e.Injector.create({providers:this.ndcDynamicProviders,parent:t})),t}}return r.UpdateOnInputs=["ndcDynamicComponent","ndcDynamicInjector","ndcDynamicProviders","ndcDynamicContent","ndcDynamicNgModuleRef","ndcDynamicEnvironmentInjector"],r.\u0275fac=function(t){return new(t||r)(e.\u0275\u0275directiveInject(e.ViewContainerRef))},r.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ndc-dynamic"]],inputs:{ndcDynamicComponent:"ndcDynamicComponent",ndcDynamicInjector:"ndcDynamicInjector",ndcDynamicProviders:"ndcDynamicProviders",ndcDynamicContent:"ndcDynamicContent",ndcDynamicNgModuleRef:"ndcDynamicNgModuleRef",ndcDynamicEnvironmentInjector:"ndcDynamicEnvironmentInjector"},outputs:{ndcDynamicCreated:"ndcDynamicCreated"},standalone:!0,features:[e.\u0275\u0275ProvidersFeature([{provide:Wt,useExisting:r}]),e.\u0275\u0275NgOnChangesFeature,e.\u0275\u0275StandaloneFeature],decls:0,vars:0,template:function(t,n){},encapsulation:2}),r})(),on=(()=>{class r{}return r.\u0275fac=function(t){return new(t||r)},r.\u0275mod=e.\u0275\u0275defineNgModule({type:r}),r.\u0275inj=e.\u0275\u0275defineInjector({imports:[qt,Ht,qt]}),r})();new e.InjectionToken("ReflectRef",{providedIn:"root",factory:()=>window.Reflect});var Ai=S(5478),xu=S(6878),md=S(8203);function Ld(r){const v=r.cloneNode(!0),t=v.querySelectorAll("[id]"),n=r.nodeName.toLowerCase();v.removeAttribute("id");for(let o=0;o<t.length;o++)t[o].removeAttribute("id");return"canvas"===n?Lc(r,v):("input"===n||"select"===n||"textarea"===n)&&Pu(r,v),gd("canvas",r,v,Lc),gd("input, textarea, select",r,v,Pu),v}function gd(r,v,t,n){const o=v.querySelectorAll(r);if(o.length){const f=t.querySelectorAll(r);for(let D=0;D<o.length;D++)n(o[D],f[D])}}let Eu=0;function Pu(r,v){"file"!==v.type&&(v.value=r.value),"radio"===v.type&&v.name&&(v.name=`mat-clone-${v.name}-${Eu++}`)}function Lc(r,v){const t=v.getContext("2d");if(t)try{t.drawImage(r,0,0)}catch{}}function qs(r){const v=r.getBoundingClientRect();return{top:v.top,right:v.right,bottom:v.bottom,left:v.left,width:v.width,height:v.height,x:v.x,y:v.y}}function Xc(r,v,t){const{top:n,bottom:o,left:f,right:D}=r;return t>=n&&t<=o&&v>=f&&v<=D}function Bu(r,v,t){r.top+=v,r.bottom=r.top+r.height,r.left+=t,r.right=r.left+r.width}function su(r,v,t,n){const{top:o,right:f,bottom:D,left:j,width:fe,height:Ne}=r,vt=fe*v,ln=Ne*v;return n>o-ln&&n<D+ln&&t>j-vt&&t<f+vt}class Is{constructor(v){this._document=v,this.positions=new Map}clear(){this.positions.clear()}cache(v){this.clear(),this.positions.set(this._document,{scrollPosition:this.getViewportScrollPosition()}),v.forEach(t=>{this.positions.set(t,{scrollPosition:{top:t.scrollTop,left:t.scrollLeft},clientRect:qs(t)})})}handleScroll(v){const t=(0,Q.Fb)(v),n=this.positions.get(t);if(!n)return null;const o=n.scrollPosition;let f,D;if(t===this._document){const Ne=this.getViewportScrollPosition();f=Ne.top,D=Ne.left}else f=t.scrollTop,D=t.scrollLeft;const j=o.top-f,fe=o.left-D;return this.positions.forEach((Ne,vt)=>{Ne.clientRect&&t!==vt&&t.contains(vt)&&Bu(Ne.clientRect,j,fe)}),o.top=f,o.left=D,{top:j,left:fe}}getViewportScrollPosition(){return{top:window.scrollY,left:window.scrollX}}}function xa(r,v){const t=r.rootNodes;if(1===t.length&&t[0].nodeType===v.ELEMENT_NODE)return t[0];const n=v.createElement("div");return t.forEach(o=>n.appendChild(o)),n}function vd(r,v,t){for(let n in v)if(v.hasOwnProperty(n)){const o=v[n];o?r.setProperty(n,o,t?.has(n)?"important":""):r.removeProperty(n)}return r}function Vu(r,v){const t=v?"":"none";vd(r.style,{"touch-action":v?"":"none","-webkit-user-drag":v?"":"none","-webkit-tap-highlight-color":v?"":"transparent","user-select":t,"-ms-user-select":t,"-webkit-user-select":t,"-moz-user-select":t})}function id(r,v,t){vd(r.style,{position:v?"":"fixed",top:v?"":"0",opacity:v?"":"0",left:v?"":"-999em"},t)}function Sd(r,v){return v&&"none"!=v?r+" "+v:r}function pu(r,v){r.style.width=`${v.width}px`,r.style.height=`${v.height}px`,r.style.transform=hu(v.left,v.top)}function hu(r,v){return`translate3d(${Math.round(r)}px, ${Math.round(v)}px, 0)`}function As(r){const v=r.toLowerCase().indexOf("ms")>-1?1:1e3;return parseFloat(r)*v}function kc(r,v){return r.getPropertyValue(v).split(",").map(n=>n.trim())}const El=new Set(["position"]);class uc{get element(){return this._preview}constructor(v,t,n,o,f,D,j,fe,Ne){this._document=v,this._rootElement=t,this._direction=n,this._initialDomRect=o,this._previewTemplate=f,this._previewClass=D,this._pickupPositionOnPage=j,this._initialTransform=fe,this._zIndex=Ne}attach(v){this._preview=this._createPreview(),v.appendChild(this._preview),kd(this._preview)&&this._preview.showPopover()}destroy(){this._preview.remove(),this._previewEmbeddedView?.destroy(),this._preview=this._previewEmbeddedView=null}setTransform(v){this._preview.style.transform=v}getBoundingClientRect(){return this._preview.getBoundingClientRect()}addClass(v){this._preview.classList.add(v)}getTransitionDuration(){return function Ed(r){const v=getComputedStyle(r),t=kc(v,"transition-property"),n=t.find(j=>"transform"===j||"all"===j);if(!n)return 0;const o=t.indexOf(n),f=kc(v,"transition-duration"),D=kc(v,"transition-delay");return As(f[o])+As(D[o])}(this._preview)}addEventListener(v,t){this._preview.addEventListener(v,t)}removeEventListener(v,t){this._preview.removeEventListener(v,t)}_createPreview(){const v=this._previewTemplate,t=this._previewClass,n=v?v.template:null;let o;if(n&&v){const f=v.matchSize?this._initialDomRect:null,D=v.viewContainer.createEmbeddedView(n,v.context);D.detectChanges(),o=xa(D,this._document),this._previewEmbeddedView=D,v.matchSize?pu(o,f):o.style.transform=hu(this._pickupPositionOnPage.x,this._pickupPositionOnPage.y)}else o=Ld(this._rootElement),pu(o,this._initialDomRect),this._initialTransform&&(o.style.transform=this._initialTransform);return vd(o.style,{"pointer-events":"none",margin:kd(o)?"0 auto 0 0":"0",position:"fixed",top:"0",left:"0","z-index":this._zIndex+""},El),Vu(o,!1),o.classList.add("cdk-drag-preview"),o.setAttribute("popover","manual"),o.setAttribute("dir",this._direction),t&&(Array.isArray(t)?t.forEach(f=>o.classList.add(f)):o.classList.add(t)),o}}function kd(r){return"showPopover"in r}const Td=(0,Q.BQ)({passive:!0}),Pc=(0,Q.BQ)({passive:!1}),ju=(0,Q.BQ)({passive:!1,capture:!0}),Bc=new Set(["position"]);class pf{get disabled(){return this._disabled||!(!this._dropContainer||!this._dropContainer.disabled)}set disabled(v){v!==this._disabled&&(this._disabled=v,this._toggleNativeDragInteractions(),this._handles.forEach(t=>Vu(t,v)))}constructor(v,t,n,o,f,D){this._config=t,this._document=n,this._ngZone=o,this._viewportRuler=f,this._dragDropRegistry=D,this._passiveTransform={x:0,y:0},this._activeTransform={x:0,y:0},this._hasStartedDragging=(0,e.signal)(!1),this._moveEvents=new i.Subject,this._pointerMoveSubscription=i.Subscription.EMPTY,this._pointerUpSubscription=i.Subscription.EMPTY,this._scrollSubscription=i.Subscription.EMPTY,this._resizeSubscription=i.Subscription.EMPTY,this._boundaryElement=null,this._nativeInteractionsEnabled=!0,this._handles=[],this._disabledHandles=new Set,this._direction="ltr",this.dragStartDelay=0,this.scale=1,this._disabled=!1,this.beforeStarted=new i.Subject,this.started=new i.Subject,this.released=new i.Subject,this.ended=new i.Subject,this.entered=new i.Subject,this.exited=new i.Subject,this.dropped=new i.Subject,this.moved=this._moveEvents,this._pointerDown=j=>{if(this.beforeStarted.next(),this._handles.length){const fe=this._getTargetHandle(j);fe&&!this._disabledHandles.has(fe)&&!this.disabled&&this._initializeDragSequence(fe,j)}else this.disabled||this._initializeDragSequence(this._rootElement,j)},this._pointerMove=j=>{const fe=this._getPointerPositionOnPage(j);if(!this._hasStartedDragging()){if(Math.abs(fe.x-this._pickupPositionOnPage.x)+Math.abs(fe.y-this._pickupPositionOnPage.y)>=this._config.dragStartThreshold){const Oi=Date.now()>=this._dragStartTime+this._getDragStartDelay(j),Lr=this._dropContainer;if(!Oi)return void this._endDragSequence(j);(!Lr||!Lr.isDragging()&&!Lr.isReceiving())&&(j.cancelable&&j.preventDefault(),this._hasStartedDragging.set(!0),this._ngZone.run(()=>this._startDragSequence(j)))}return}j.cancelable&&j.preventDefault();const Ne=this._getConstrainedPointerPosition(fe);if(this._hasMoved=!0,this._lastKnownPointerPosition=fe,this._updatePointerDirectionDelta(Ne),this._dropContainer)this._updateActiveDropContainer(Ne,fe);else{const vt=this.constrainPosition?this._initialDomRect:this._pickupPositionOnPage,ln=this._activeTransform;ln.x=Ne.x-vt.x+this._passiveTransform.x,ln.y=Ne.y-vt.y+this._passiveTransform.y,this._applyRootElementTransform(ln.x,ln.y)}this._moveEvents.observers.length&&this._ngZone.run(()=>{this._moveEvents.next({source:this,pointerPosition:Ne,event:j,distance:this._getDragDistance(Ne),delta:this._pointerDirectionDelta})})},this._pointerUp=j=>{this._endDragSequence(j)},this._nativeDragStart=j=>{if(this._handles.length){const fe=this._getTargetHandle(j);fe&&!this._disabledHandles.has(fe)&&!this.disabled&&j.preventDefault()}else this.disabled||j.preventDefault()},this.withRootElement(v).withParent(t.parentDragRef||null),this._parentPositions=new Is(n),D.registerDragItem(this)}getPlaceholderElement(){return this._placeholder}getRootElement(){return this._rootElement}getVisibleElement(){return this.isDragging()?this.getPlaceholderElement():this.getRootElement()}withHandles(v){this._handles=v.map(n=>(0,ie.i8)(n)),this._handles.forEach(n=>Vu(n,this.disabled)),this._toggleNativeDragInteractions();const t=new Set;return this._disabledHandles.forEach(n=>{this._handles.indexOf(n)>-1&&t.add(n)}),this._disabledHandles=t,this}withPreviewTemplate(v){return this._previewTemplate=v,this}withPlaceholderTemplate(v){return this._placeholderTemplate=v,this}withRootElement(v){const t=(0,ie.i8)(v);return t!==this._rootElement&&(this._rootElement&&this._removeRootElementListeners(this._rootElement),this._ngZone.runOutsideAngular(()=>{t.addEventListener("mousedown",this._pointerDown,Pc),t.addEventListener("touchstart",this._pointerDown,Td),t.addEventListener("dragstart",this._nativeDragStart,Pc)}),this._initialTransform=void 0,this._rootElement=t),typeof SVGElement<"u"&&this._rootElement instanceof SVGElement&&(this._ownerSVGElement=this._rootElement.ownerSVGElement),this}withBoundaryElement(v){return this._boundaryElement=v?(0,ie.i8)(v):null,this._resizeSubscription.unsubscribe(),v&&(this._resizeSubscription=this._viewportRuler.change(10).subscribe(()=>this._containInsideBoundaryOnResize())),this}withParent(v){return this._parentDragRef=v,this}dispose(){this._removeRootElementListeners(this._rootElement),this.isDragging()&&this._rootElement?.remove(),this._anchor?.remove(),this._destroyPreview(),this._destroyPlaceholder(),this._dragDropRegistry.removeDragItem(this),this._removeListeners(),this.beforeStarted.complete(),this.started.complete(),this.released.complete(),this.ended.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this._moveEvents.complete(),this._handles=[],this._disabledHandles.clear(),this._dropContainer=void 0,this._resizeSubscription.unsubscribe(),this._parentPositions.clear(),this._boundaryElement=this._rootElement=this._ownerSVGElement=this._placeholderTemplate=this._previewTemplate=this._anchor=this._parentDragRef=null}isDragging(){return this._hasStartedDragging()&&this._dragDropRegistry.isDragging(this)}reset(){this._rootElement.style.transform=this._initialTransform||"",this._activeTransform={x:0,y:0},this._passiveTransform={x:0,y:0}}disableHandle(v){!this._disabledHandles.has(v)&&this._handles.indexOf(v)>-1&&(this._disabledHandles.add(v),Vu(v,!0))}enableHandle(v){this._disabledHandles.has(v)&&(this._disabledHandles.delete(v),Vu(v,this.disabled))}withDirection(v){return this._direction=v,this}_withDropContainer(v){this._dropContainer=v}getFreeDragPosition(){const v=this.isDragging()?this._activeTransform:this._passiveTransform;return{x:v.x,y:v.y}}setFreeDragPosition(v){return this._activeTransform={x:0,y:0},this._passiveTransform.x=v.x,this._passiveTransform.y=v.y,this._dropContainer||this._applyRootElementTransform(v.x,v.y),this}withPreviewContainer(v){return this._previewContainer=v,this}_sortFromLastPointerPosition(){const v=this._lastKnownPointerPosition;v&&this._dropContainer&&this._updateActiveDropContainer(this._getConstrainedPointerPosition(v),v)}_removeListeners(){this._pointerMoveSubscription.unsubscribe(),this._pointerUpSubscription.unsubscribe(),this._scrollSubscription.unsubscribe(),this._getShadowRoot()?.removeEventListener("selectstart",Dt,ju)}_destroyPreview(){this._preview?.destroy(),this._preview=null}_destroyPlaceholder(){this._placeholder?.remove(),this._placeholderRef?.destroy(),this._placeholder=this._placeholderRef=null}_endDragSequence(v){if(this._dragDropRegistry.isDragging(this)&&(this._removeListeners(),this._dragDropRegistry.stopDragging(this),this._toggleNativeDragInteractions(),this._handles&&(this._rootElement.style.webkitTapHighlightColor=this._rootElementTapHighlight),this._hasStartedDragging()))if(this.released.next({source:this,event:v}),this._dropContainer)this._dropContainer._stopScrolling(),this._animatePreviewToPlaceholder().then(()=>{this._cleanupDragArtifacts(v),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)});else{this._passiveTransform.x=this._activeTransform.x;const t=this._getPointerPositionOnPage(v);this._passiveTransform.y=this._activeTransform.y,this._ngZone.run(()=>{this.ended.next({source:this,distance:this._getDragDistance(t),dropPoint:t,event:v})}),this._cleanupCachedDimensions(),this._dragDropRegistry.stopDragging(this)}}_startDragSequence(v){_e(v)&&(this._lastTouchEventTime=Date.now()),this._toggleNativeDragInteractions();const t=this._getShadowRoot(),n=this._dropContainer;if(t&&this._ngZone.runOutsideAngular(()=>{t.addEventListener("selectstart",Dt,ju)}),n){const o=this._rootElement,f=o.parentNode,D=this._placeholder=this._createPlaceholderElement(),j=this._anchor=this._anchor||this._document.createComment("");f.insertBefore(j,o),this._initialTransform=o.style.transform||"",this._preview=new uc(this._document,this._rootElement,this._direction,this._initialDomRect,this._previewTemplate||null,this.previewClass||null,this._pickupPositionOnPage,this._initialTransform,this._config.zIndex||1e3),this._preview.attach(this._getPreviewInsertionPoint(f,t)),id(o,!1,Bc),this._document.body.appendChild(f.replaceChild(D,o)),this.started.next({source:this,event:v}),n.start(),this._initialContainer=n,this._initialIndex=n.getItemIndex(this)}else this.started.next({source:this,event:v}),this._initialContainer=this._initialIndex=void 0;this._parentPositions.cache(n?n.getScrollableParents():[])}_initializeDragSequence(v,t){this._parentDragRef&&t.stopPropagation();const n=this.isDragging(),o=_e(t),f=!o&&0!==t.button,D=this._rootElement,j=(0,Q.Fb)(t),fe=!o&&this._lastTouchEventTime&&this._lastTouchEventTime+800>Date.now(),Ne=o?function ba(r){const v=r.touches&&r.touches[0]||r.changedTouches&&r.changedTouches[0];return!(!v||-1!==v.identifier||null!=v.radiusX&&1!==v.radiusX||null!=v.radiusY&&1!==v.radiusY)}(t):function Gs(r){return 0===r.buttons||0===r.detail}(t);if(j&&j.draggable&&"mousedown"===t.type&&t.preventDefault(),n||f||fe||Ne)return;if(this._handles.length){const Hn=D.style;this._rootElementTapHighlight=Hn.webkitTapHighlightColor||"",Hn.webkitTapHighlightColor="transparent"}this._hasMoved=!1,this._hasStartedDragging.set(this._hasMoved),this._removeListeners(),this._initialDomRect=this._rootElement.getBoundingClientRect(),this._pointerMoveSubscription=this._dragDropRegistry.pointerMove.subscribe(this._pointerMove),this._pointerUpSubscription=this._dragDropRegistry.pointerUp.subscribe(this._pointerUp),this._scrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(Hn=>this._updateOnScroll(Hn)),this._boundaryElement&&(this._boundaryRect=qs(this._boundaryElement));const vt=this._previewTemplate;this._pickupPositionInElement=vt&&vt.template&&!vt.matchSize?{x:0,y:0}:this._getPointerPositionInElement(this._initialDomRect,v,t);const ln=this._pickupPositionOnPage=this._lastKnownPointerPosition=this._getPointerPositionOnPage(t);this._pointerDirectionDelta={x:0,y:0},this._pointerPositionAtLastDirectionChange={x:ln.x,y:ln.y},this._dragStartTime=Date.now(),this._dragDropRegistry.startDragging(this,t)}_cleanupDragArtifacts(v){id(this._rootElement,!0,Bc),this._anchor.parentNode.replaceChild(this._rootElement,this._anchor),this._destroyPreview(),this._destroyPlaceholder(),this._initialDomRect=this._boundaryRect=this._previewRect=this._initialTransform=void 0,this._ngZone.run(()=>{const t=this._dropContainer,n=t.getItemIndex(this),o=this._getPointerPositionOnPage(v),f=this._getDragDistance(o),D=t._isOverContainer(o.x,o.y);this.ended.next({source:this,distance:f,dropPoint:o,event:v}),this.dropped.next({item:this,currentIndex:n,previousIndex:this._initialIndex,container:t,previousContainer:this._initialContainer,isPointerOverContainer:D,distance:f,dropPoint:o,event:v}),t.drop(this,n,this._initialIndex,this._initialContainer,D,f,o,v),this._dropContainer=this._initialContainer})}_updateActiveDropContainer({x:v,y:t},{x:n,y:o}){let f=this._initialContainer._getSiblingContainerFromPosition(this,v,t);!f&&this._dropContainer!==this._initialContainer&&this._initialContainer._isOverContainer(v,t)&&(f=this._initialContainer),f&&f!==this._dropContainer&&this._ngZone.run(()=>{this.exited.next({item:this,container:this._dropContainer}),this._dropContainer.exit(this),this._dropContainer=f,this._dropContainer.enter(this,v,t,f===this._initialContainer&&f.sortingDisabled?this._initialIndex:void 0),this.entered.next({item:this,container:f,currentIndex:f.getItemIndex(this)})}),this.isDragging()&&(this._dropContainer._startScrollingIfNecessary(n,o),this._dropContainer._sortItem(this,v,t,this._pointerDirectionDelta),this.constrainPosition?this._applyPreviewTransform(v,t):this._applyPreviewTransform(v-this._pickupPositionInElement.x,t-this._pickupPositionInElement.y))}_animatePreviewToPlaceholder(){if(!this._hasMoved)return Promise.resolve();const v=this._placeholder.getBoundingClientRect();this._preview.addClass("cdk-drag-animating"),this._applyPreviewTransform(v.left,v.top);const t=this._preview.getTransitionDuration();return 0===t?Promise.resolve():this._ngZone.runOutsideAngular(()=>new Promise(n=>{const o=D=>{(!D||this._preview&&(0,Q.Fb)(D)===this._preview.element&&"transform"===D.propertyName)&&(this._preview?.removeEventListener("transitionend",o),n(),clearTimeout(f))},f=setTimeout(o,1.5*t);this._preview.addEventListener("transitionend",o)}))}_createPlaceholderElement(){const v=this._placeholderTemplate,t=v?v.template:null;let n;return t?(this._placeholderRef=v.viewContainer.createEmbeddedView(t,v.context),this._placeholderRef.detectChanges(),n=xa(this._placeholderRef,this._document)):n=Ld(this._rootElement),n.style.pointerEvents="none",n.classList.add("cdk-drag-placeholder"),n}_getPointerPositionInElement(v,t,n){const o=t===this._rootElement?null:t,f=o?o.getBoundingClientRect():v,D=_e(n)?n.targetTouches[0]:n,j=this._getViewportScrollPosition();return{x:f.left-v.left+(D.pageX-f.left-j.left),y:f.top-v.top+(D.pageY-f.top-j.top)}}_getPointerPositionOnPage(v){const t=this._getViewportScrollPosition(),n=_e(v)?v.touches[0]||v.changedTouches[0]||{pageX:0,pageY:0}:v,o=n.pageX-t.left,f=n.pageY-t.top;if(this._ownerSVGElement){const D=this._ownerSVGElement.getScreenCTM();if(D){const j=this._ownerSVGElement.createSVGPoint();return j.x=o,j.y=f,j.matrixTransform(D.inverse())}}return{x:o,y:f}}_getConstrainedPointerPosition(v){const t=this._dropContainer?this._dropContainer.lockAxis:null;let{x:n,y:o}=this.constrainPosition?this.constrainPosition(v,this,this._initialDomRect,this._pickupPositionInElement):v;if("x"===this.lockAxis||"x"===t?o=this._pickupPositionOnPage.y-(this.constrainPosition?this._pickupPositionInElement.y:0):("y"===this.lockAxis||"y"===t)&&(n=this._pickupPositionOnPage.x-(this.constrainPosition?this._pickupPositionInElement.x:0)),this._boundaryRect){const{x:f,y:D}=this.constrainPosition?{x:0,y:0}:this._pickupPositionInElement,j=this._boundaryRect,{width:fe,height:Ne}=this._getPreviewRect(),vt=j.top+D,ln=j.bottom-(Ne-D);n=hf(n,j.left+f,j.right-(fe-f)),o=hf(o,vt,ln)}return{x:n,y:o}}_updatePointerDirectionDelta(v){const{x:t,y:n}=v,o=this._pointerDirectionDelta,f=this._pointerPositionAtLastDirectionChange,D=Math.abs(t-f.x),j=Math.abs(n-f.y);return D>this._config.pointerDirectionChangeThreshold&&(o.x=t>f.x?1:-1,f.x=t),j>this._config.pointerDirectionChangeThreshold&&(o.y=n>f.y?1:-1,f.y=n),o}_toggleNativeDragInteractions(){if(!this._rootElement||!this._handles)return;const v=this._handles.length>0||!this.isDragging();v!==this._nativeInteractionsEnabled&&(this._nativeInteractionsEnabled=v,Vu(this._rootElement,v))}_removeRootElementListeners(v){v.removeEventListener("mousedown",this._pointerDown,Pc),v.removeEventListener("touchstart",this._pointerDown,Td),v.removeEventListener("dragstart",this._nativeDragStart,Pc)}_applyRootElementTransform(v,t){const n=1/this.scale,o=hu(v*n,t*n),f=this._rootElement.style;null==this._initialTransform&&(this._initialTransform=f.transform&&"none"!=f.transform?f.transform:""),f.transform=Sd(o,this._initialTransform)}_applyPreviewTransform(v,t){const n=this._previewTemplate?.template?void 0:this._initialTransform,o=hu(v,t);this._preview.setTransform(Sd(o,n))}_getDragDistance(v){const t=this._pickupPositionOnPage;return t?{x:v.x-t.x,y:v.y-t.y}:{x:0,y:0}}_cleanupCachedDimensions(){this._boundaryRect=this._previewRect=void 0,this._parentPositions.clear()}_containInsideBoundaryOnResize(){let{x:v,y:t}=this._passiveTransform;if(0===v&&0===t||this.isDragging()||!this._boundaryElement)return;const n=this._rootElement.getBoundingClientRect(),o=this._boundaryElement.getBoundingClientRect();if(0===o.width&&0===o.height||0===n.width&&0===n.height)return;const f=o.left-n.left,D=n.right-o.right,j=o.top-n.top,fe=n.bottom-o.bottom;o.width>n.width?(f>0&&(v+=f),D>0&&(v-=D)):v=0,o.height>n.height?(j>0&&(t+=j),fe>0&&(t-=fe)):t=0,(v!==this._passiveTransform.x||t!==this._passiveTransform.y)&&this.setFreeDragPosition({y:t,x:v})}_getDragStartDelay(v){const t=this.dragStartDelay;return"number"==typeof t?t:_e(v)?t.touch:t?t.mouse:0}_updateOnScroll(v){const t=this._parentPositions.handleScroll(v);if(t){const n=(0,Q.Fb)(v);this._boundaryRect&&n!==this._boundaryElement&&n.contains(this._boundaryElement)&&Bu(this._boundaryRect,t.top,t.left),this._pickupPositionOnPage.x+=t.left,this._pickupPositionOnPage.y+=t.top,this._dropContainer||(this._activeTransform.x-=t.left,this._activeTransform.y-=t.top,this._applyRootElementTransform(this._activeTransform.x,this._activeTransform.y))}}_getViewportScrollPosition(){return this._parentPositions.positions.get(this._document)?.scrollPosition||this._parentPositions.getViewportScrollPosition()}_getShadowRoot(){return void 0===this._cachedShadowRoot&&(this._cachedShadowRoot=(0,Q.KT)(this._rootElement)),this._cachedShadowRoot}_getPreviewInsertionPoint(v,t){const n=this._previewContainer||"global";if("parent"===n)return v;if("global"===n){const o=this._document;return t||o.fullscreenElement||o.webkitFullscreenElement||o.mozFullScreenElement||o.msFullscreenElement||o.body}return(0,ie.i8)(n)}_getPreviewRect(){return(!this._previewRect||!this._previewRect.width&&!this._previewRect.height)&&(this._previewRect=this._preview?this._preview.getBoundingClientRect():this._initialDomRect),this._previewRect}_getTargetHandle(v){return this._handles.find(t=>v.target&&(v.target===t||t.contains(v.target)))}}function hf(r,v,t){return Math.max(v,Math.min(t,r))}function _e(r){return"t"===r.type[0]}function Dt(r){r.preventDefault()}function Re(r,v,t){const n=gi(v,r.length-1),o=gi(t,r.length-1);if(n===o)return;const f=r[n],D=o<n?-1:1;for(let j=n;j!==o;j+=D)r[j]=r[j+D];r[o]=f}function gi(r,v){return Math.max(0,Math.min(v,r))}class rr{constructor(v){this._dragDropRegistry=v,this._itemPositions=[],this.orientation="vertical",this._previousSwap={drag:null,delta:0,overlaps:!1}}start(v){this.withItems(v)}sort(v,t,n,o){const f=this._itemPositions,D=this._getItemIndexFromPointerPosition(v,t,n,o);if(-1===D&&f.length>0)return null;const j="horizontal"===this.orientation,fe=f.findIndex(Mr=>Mr.drag===v),Ne=f[D],ln=Ne.clientRect,Hn=fe>D?1:-1,Oi=this._getItemOffsetPx(f[fe].clientRect,ln,Hn),Lr=this._getSiblingOffsetPx(fe,f,Hn),to=f.slice();return Re(f,fe,D),f.forEach((Mr,ss)=>{if(to[ss]===Mr)return;const Rs=Mr.drag===v,Us=Rs?Oi:Lr,wu=Rs?v.getPlaceholderElement():Mr.drag.getRootElement();Mr.offset+=Us;const Tf=Math.round(Mr.offset*(1/Mr.drag.scale));j?(wu.style.transform=Sd(`translate3d(${Tf}px, 0, 0)`,Mr.initialTransform),Bu(Mr.clientRect,0,Us)):(wu.style.transform=Sd(`translate3d(0, ${Tf}px, 0)`,Mr.initialTransform),Bu(Mr.clientRect,Us,0))}),this._previousSwap.overlaps=Xc(ln,t,n),this._previousSwap.drag=Ne.drag,this._previousSwap.delta=j?o.x:o.y,{previousIndex:fe,currentIndex:D}}enter(v,t,n,o){const f=null==o||o<0?this._getItemIndexFromPointerPosition(v,t,n):o,D=this._activeDraggables,j=D.indexOf(v),fe=v.getPlaceholderElement();let Ne=D[f];if(Ne===v&&(Ne=D[f+1]),!Ne&&(null==f||-1===f||f<D.length-1)&&this._shouldEnterAsFirstChild(t,n)&&(Ne=D[0]),j>-1&&D.splice(j,1),Ne&&!this._dragDropRegistry.isDragging(Ne)){const vt=Ne.getRootElement();vt.parentElement.insertBefore(fe,vt),D.splice(f,0,v)}else this._element.appendChild(fe),D.push(v);fe.style.transform="",this._cacheItemPositions()}withItems(v){this._activeDraggables=v.slice(),this._cacheItemPositions()}withSortPredicate(v){this._sortPredicate=v}reset(){this._activeDraggables?.forEach(v=>{const t=v.getRootElement();if(t){const n=this._itemPositions.find(o=>o.drag===v)?.initialTransform;t.style.transform=n||""}}),this._itemPositions=[],this._activeDraggables=[],this._previousSwap.drag=null,this._previousSwap.delta=0,this._previousSwap.overlaps=!1}getActiveItemsSnapshot(){return this._activeDraggables}getItemIndex(v){return("horizontal"===this.orientation&&"rtl"===this.direction?this._itemPositions.slice().reverse():this._itemPositions).findIndex(n=>n.drag===v)}updateOnScroll(v,t){this._itemPositions.forEach(({clientRect:n})=>{Bu(n,v,t)}),this._itemPositions.forEach(({drag:n})=>{this._dragDropRegistry.isDragging(n)&&n._sortFromLastPointerPosition()})}withElementContainer(v){this._element=v}_cacheItemPositions(){const v="horizontal"===this.orientation;this._itemPositions=this._activeDraggables.map(t=>{const n=t.getVisibleElement();return{drag:t,offset:0,initialTransform:n.style.transform||"",clientRect:qs(n)}}).sort((t,n)=>v?t.clientRect.left-n.clientRect.left:t.clientRect.top-n.clientRect.top)}_getItemOffsetPx(v,t,n){const o="horizontal"===this.orientation;let f=o?t.left-v.left:t.top-v.top;return-1===n&&(f+=o?t.width-v.width:t.height-v.height),f}_getSiblingOffsetPx(v,t,n){const o="horizontal"===this.orientation,f=t[v].clientRect,D=t[v+-1*n];let j=f[o?"width":"height"]*n;if(D){const fe=o?"left":"top",Ne=o?"right":"bottom";-1===n?j-=D.clientRect[fe]-f[Ne]:j+=f[fe]-D.clientRect[Ne]}return j}_shouldEnterAsFirstChild(v,t){if(!this._activeDraggables.length)return!1;const n=this._itemPositions,o="horizontal"===this.orientation;if(n[0].drag!==this._activeDraggables[0]){const D=n[n.length-1].clientRect;return o?v>=D.right:t>=D.bottom}{const D=n[0].clientRect;return o?v<=D.left:t<=D.top}}_getItemIndexFromPointerPosition(v,t,n,o){const f="horizontal"===this.orientation,D=this._itemPositions.findIndex(({drag:j,clientRect:fe})=>j!==v&&((!o||j!==this._previousSwap.drag||!this._previousSwap.overlaps||(f?o.x:o.y)!==this._previousSwap.delta)&&(f?t>=Math.floor(fe.left)&&t<Math.floor(fe.right):n>=Math.floor(fe.top)&&n<Math.floor(fe.bottom))));return-1!==D&&this._sortPredicate(D,v)?D:-1}}class or{constructor(v,t){this._document=v,this._dragDropRegistry=t,this._previousSwap={drag:null,deltaX:0,deltaY:0,overlaps:!1},this._relatedNodes=[]}start(v){const t=this._element.childNodes;this._relatedNodes=[];for(let n=0;n<t.length;n++){const o=t[n];this._relatedNodes.push([o,o.nextSibling])}this.withItems(v)}sort(v,t,n,o){const f=this._getItemIndexFromPointerPosition(v,t,n),D=this._previousSwap;if(-1===f||this._activeItems[f]===v)return null;const j=this._activeItems[f];if(D.drag===j&&D.overlaps&&D.deltaX===o.x&&D.deltaY===o.y)return null;const fe=this.getItemIndex(v),Ne=v.getPlaceholderElement(),vt=j.getRootElement();f>fe?vt.after(Ne):vt.before(Ne),Re(this._activeItems,fe,f);const ln=this._getRootNode().elementFromPoint(t,n);return D.deltaX=o.x,D.deltaY=o.y,D.drag=j,D.overlaps=vt===ln||vt.contains(ln),{previousIndex:fe,currentIndex:f}}enter(v,t,n,o){let f=null==o||o<0?this._getItemIndexFromPointerPosition(v,t,n):o;-1===f&&(f=this._getClosestItemIndexToPointer(v,t,n));const D=this._activeItems[f],j=this._activeItems.indexOf(v);j>-1&&this._activeItems.splice(j,1),D&&!this._dragDropRegistry.isDragging(D)?(this._activeItems.splice(f,0,v),D.getRootElement().before(v.getPlaceholderElement())):(this._activeItems.push(v),this._element.appendChild(v.getPlaceholderElement()))}withItems(v){this._activeItems=v.slice()}withSortPredicate(v){this._sortPredicate=v}reset(){const v=this._element,t=this._previousSwap;for(let n=this._relatedNodes.length-1;n>-1;n--){const[o,f]=this._relatedNodes[n];o.parentNode===v&&o.nextSibling!==f&&(null===f?v.appendChild(o):f.parentNode===v&&v.insertBefore(o,f))}this._relatedNodes=[],this._activeItems=[],t.drag=null,t.deltaX=t.deltaY=0,t.overlaps=!1}getActiveItemsSnapshot(){return this._activeItems}getItemIndex(v){return this._activeItems.indexOf(v)}updateOnScroll(){this._activeItems.forEach(v=>{this._dragDropRegistry.isDragging(v)&&v._sortFromLastPointerPosition()})}withElementContainer(v){v!==this._element&&(this._element=v,this._rootNode=void 0)}_getItemIndexFromPointerPosition(v,t,n){const o=this._getRootNode().elementFromPoint(Math.floor(t),Math.floor(n)),f=o?this._activeItems.findIndex(D=>{const j=D.getRootElement();return o===j||j.contains(o)}):-1;return-1!==f&&this._sortPredicate(f,v)?f:-1}_getRootNode(){return this._rootNode||(this._rootNode=(0,Q.KT)(this._element)||this._document),this._rootNode}_getClosestItemIndexToPointer(v,t,n){if(0===this._activeItems.length)return-1;if(1===this._activeItems.length)return 0;let o=1/0,f=-1;for(let D=0;D<this._activeItems.length;D++){const j=this._activeItems[D];if(j!==v){const{x:fe,y:Ne}=j.getRootElement().getBoundingClientRect(),vt=Math.hypot(t-fe,n-Ne);vt<o&&(o=vt,f=D)}}return f}}var vs=function(r){return r[r.NONE=0]="NONE",r[r.UP=1]="UP",r[r.DOWN=2]="DOWN",r}(vs||{}),Qo=function(r){return r[r.NONE=0]="NONE",r[r.LEFT=1]="LEFT",r[r.RIGHT=2]="RIGHT",r}(Qo||{});class ll{constructor(v,t,n,o,f){this._dragDropRegistry=t,this._ngZone=o,this._viewportRuler=f,this.disabled=!1,this.sortingDisabled=!1,this.autoScrollDisabled=!1,this.autoScrollStep=2,this.enterPredicate=()=>!0,this.sortPredicate=()=>!0,this.beforeStarted=new i.Subject,this.entered=new i.Subject,this.exited=new i.Subject,this.dropped=new i.Subject,this.sorted=new i.Subject,this.receivingStarted=new i.Subject,this.receivingStopped=new i.Subject,this._isDragging=!1,this._draggables=[],this._siblings=[],this._activeSiblings=new Set,this._viewportScrollSubscription=i.Subscription.EMPTY,this._verticalScrollDirection=vs.NONE,this._horizontalScrollDirection=Qo.NONE,this._stopScrollTimers=new i.Subject,this._cachedShadowRoot=null,this._scrollableElements=[],this._direction="ltr",this._startScrollInterval=()=>{this._stopScrolling(),(0,i.interval)(0,i.animationFrameScheduler).pipe((0,M.takeUntil)(this._stopScrollTimers)).subscribe(()=>{const j=this._scrollNode,fe=this.autoScrollStep;this._verticalScrollDirection===vs.UP?j.scrollBy(0,-fe):this._verticalScrollDirection===vs.DOWN&&j.scrollBy(0,fe),this._horizontalScrollDirection===Qo.LEFT?j.scrollBy(-fe,0):this._horizontalScrollDirection===Qo.RIGHT&&j.scrollBy(fe,0)})};const D=this.element=(0,ie.i8)(v);this._document=n,this.withOrientation("vertical").withElementContainer(D),t.registerDropContainer(this),this._parentPositions=new Is(n)}dispose(){this._stopScrolling(),this._stopScrollTimers.complete(),this._viewportScrollSubscription.unsubscribe(),this.beforeStarted.complete(),this.entered.complete(),this.exited.complete(),this.dropped.complete(),this.sorted.complete(),this.receivingStarted.complete(),this.receivingStopped.complete(),this._activeSiblings.clear(),this._scrollNode=null,this._parentPositions.clear(),this._dragDropRegistry.removeDropContainer(this)}isDragging(){return this._isDragging}start(){this._draggingStarted(),this._notifyReceivingSiblings()}enter(v,t,n,o){this._draggingStarted(),null==o&&this.sortingDisabled&&(o=this._draggables.indexOf(v)),this._sortStrategy.enter(v,t,n,o),this._cacheParentPositions(),this._notifyReceivingSiblings(),this.entered.next({item:v,container:this,currentIndex:this.getItemIndex(v)})}exit(v){this._reset(),this.exited.next({item:v,container:this})}drop(v,t,n,o,f,D,j,fe={}){this._reset(),this.dropped.next({item:v,currentIndex:t,previousIndex:n,container:this,previousContainer:o,isPointerOverContainer:f,distance:D,dropPoint:j,event:fe})}withItems(v){const t=this._draggables;return this._draggables=v,v.forEach(n=>n._withDropContainer(this)),this.isDragging()&&(t.filter(o=>o.isDragging()).every(o=>-1===v.indexOf(o))?this._reset():this._sortStrategy.withItems(this._draggables)),this}withDirection(v){return this._direction=v,this._sortStrategy instanceof rr&&(this._sortStrategy.direction=v),this}connectedTo(v){return this._siblings=v.slice(),this}withOrientation(v){if("mixed"===v)this._sortStrategy=new or(this._document,this._dragDropRegistry);else{const t=new rr(this._dragDropRegistry);t.direction=this._direction,t.orientation=v,this._sortStrategy=t}return this._sortStrategy.withElementContainer(this._container),this._sortStrategy.withSortPredicate((t,n)=>this.sortPredicate(t,n,this)),this}withScrollableParents(v){const t=this._container;return this._scrollableElements=-1===v.indexOf(t)?[t,...v]:v.slice(),this}withElementContainer(v){if(v===this._container)return this;(0,ie.i8)(this.element);const n=this._scrollableElements.indexOf(this._container),o=this._scrollableElements.indexOf(v);return n>-1&&this._scrollableElements.splice(n,1),o>-1&&this._scrollableElements.splice(o,1),this._sortStrategy&&this._sortStrategy.withElementContainer(v),this._cachedShadowRoot=null,this._scrollableElements.unshift(v),this._container=v,this}getScrollableParents(){return this._scrollableElements}getItemIndex(v){return this._isDragging?this._sortStrategy.getItemIndex(v):this._draggables.indexOf(v)}isReceiving(){return this._activeSiblings.size>0}_sortItem(v,t,n,o){if(this.sortingDisabled||!this._domRect||!su(this._domRect,.05,t,n))return;const f=this._sortStrategy.sort(v,t,n,o);f&&this.sorted.next({previousIndex:f.previousIndex,currentIndex:f.currentIndex,container:this,item:v})}_startScrollingIfNecessary(v,t){if(this.autoScrollDisabled)return;let n,o=vs.NONE,f=Qo.NONE;if(this._parentPositions.positions.forEach((D,j)=>{j===this._document||!D.clientRect||n||su(D.clientRect,.05,v,t)&&([o,f]=function Mc(r,v,t,n,o){const f=Sa(v,o),D=$o(v,n);let j=vs.NONE,fe=Qo.NONE;if(f){const Ne=r.scrollTop;f===vs.UP?Ne>0&&(j=vs.UP):r.scrollHeight-Ne>r.clientHeight&&(j=vs.DOWN)}if(D){const Ne=r.scrollLeft;"rtl"===t?D===Qo.RIGHT?Ne<0&&(fe=Qo.RIGHT):r.scrollWidth+Ne>r.clientWidth&&(fe=Qo.LEFT):D===Qo.LEFT?Ne>0&&(fe=Qo.LEFT):r.scrollWidth-Ne>r.clientWidth&&(fe=Qo.RIGHT)}return[j,fe]}(j,D.clientRect,this._direction,v,t),(o||f)&&(n=j))}),!o&&!f){const{width:D,height:j}=this._viewportRuler.getViewportSize(),fe={width:D,height:j,top:0,right:D,bottom:j,left:0};o=Sa(fe,t),f=$o(fe,v),n=window}n&&(o!==this._verticalScrollDirection||f!==this._horizontalScrollDirection||n!==this._scrollNode)&&(this._verticalScrollDirection=o,this._horizontalScrollDirection=f,this._scrollNode=n,(o||f)&&n?this._ngZone.runOutsideAngular(this._startScrollInterval):this._stopScrolling())}_stopScrolling(){this._stopScrollTimers.next()}_draggingStarted(){const v=this._container.style;this.beforeStarted.next(),this._isDragging=!0,this._initialScrollSnap=v.msScrollSnapType||v.scrollSnapType||"",v.scrollSnapType=v.msScrollSnapType="none",this._sortStrategy.start(this._draggables),this._cacheParentPositions(),this._viewportScrollSubscription.unsubscribe(),this._listenToScrollEvents()}_cacheParentPositions(){this._parentPositions.cache(this._scrollableElements),this._domRect=this._parentPositions.positions.get(this._container).clientRect}_reset(){this._isDragging=!1;const v=this._container.style;v.scrollSnapType=v.msScrollSnapType=this._initialScrollSnap,this._siblings.forEach(t=>t._stopReceiving(this)),this._sortStrategy.reset(),this._stopScrolling(),this._viewportScrollSubscription.unsubscribe(),this._parentPositions.clear()}_isOverContainer(v,t){return null!=this._domRect&&Xc(this._domRect,v,t)}_getSiblingContainerFromPosition(v,t,n){return this._siblings.find(o=>o._canReceive(v,t,n))}_canReceive(v,t,n){if(!this._domRect||!Xc(this._domRect,t,n)||!this.enterPredicate(v,this))return!1;const o=this._getShadowRoot().elementFromPoint(t,n);return!!o&&(o===this._container||this._container.contains(o))}_startReceiving(v,t){const n=this._activeSiblings;!n.has(v)&&t.every(o=>this.enterPredicate(o,this)||this._draggables.indexOf(o)>-1)&&(n.add(v),this._cacheParentPositions(),this._listenToScrollEvents(),this.receivingStarted.next({initiator:v,receiver:this,items:t}))}_stopReceiving(v){this._activeSiblings.delete(v),this._viewportScrollSubscription.unsubscribe(),this.receivingStopped.next({initiator:v,receiver:this})}_listenToScrollEvents(){this._viewportScrollSubscription=this._dragDropRegistry.scrolled(this._getShadowRoot()).subscribe(v=>{if(this.isDragging()){const t=this._parentPositions.handleScroll(v);t&&this._sortStrategy.updateOnScroll(t.top,t.left)}else this.isReceiving()&&this._cacheParentPositions()})}_getShadowRoot(){if(!this._cachedShadowRoot){const v=(0,Q.KT)(this._container);this._cachedShadowRoot=v||this._document}return this._cachedShadowRoot}_notifyReceivingSiblings(){const v=this._sortStrategy.getActiveItemsSnapshot().filter(t=>t.isDragging());this._siblings.forEach(t=>t._startReceiving(this,v))}}function Sa(r,v){const{top:t,bottom:n,height:o}=r,f=.05*o;return v>=t-f&&v<=t+f?vs.UP:v>=n-f&&v<=n+f?vs.DOWN:vs.NONE}function $o(r,v){const{left:t,right:n,width:o}=r,f=.05*o;return v>=t-f&&v<=t+f?Qo.LEFT:v>=n-f&&v<=n+f?Qo.RIGHT:Qo.NONE}const yc=(0,Q.BQ)({passive:!1,capture:!0}),Ue=new Set;let ne=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],hostAttrs:["cdk-drag-resets-container",""],standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:0,vars:0,template:function(n,o){},styles:["@layer cdk-resets{.cdk-drag-preview{background:none;border:none;padding:0;color:inherit;inset:auto}}.cdk-drag-placeholder *,.cdk-drag-preview *{pointer-events:none !important}"],encapsulation:2,changeDetection:0})}return r})(),Pe=(()=>{class r{constructor(t,n){this._ngZone=t,this._appRef=(0,e.inject)(e.ApplicationRef),this._environmentInjector=(0,e.inject)(e.EnvironmentInjector),this._dropInstances=new Set,this._dragInstances=new Set,this._activeDragInstances=(0,e.signal)([]),this._globalListeners=new Map,this._draggingPredicate=o=>o.isDragging(),this.pointerMove=new i.Subject,this.pointerUp=new i.Subject,this.scroll=new i.Subject,this._preventDefaultWhileDragging=o=>{this._activeDragInstances().length>0&&o.preventDefault()},this._persistentTouchmoveListener=o=>{this._activeDragInstances().length>0&&(this._activeDragInstances().some(this._draggingPredicate)&&o.preventDefault(),this.pointerMove.next(o))},this._document=n}registerDropContainer(t){this._dropInstances.has(t)||this._dropInstances.add(t)}registerDragItem(t){this._dragInstances.add(t),1===this._dragInstances.size&&this._ngZone.runOutsideAngular(()=>{this._document.addEventListener("touchmove",this._persistentTouchmoveListener,yc)})}removeDropContainer(t){this._dropInstances.delete(t)}removeDragItem(t){this._dragInstances.delete(t),this.stopDragging(t),0===this._dragInstances.size&&this._document.removeEventListener("touchmove",this._persistentTouchmoveListener,yc)}startDragging(t,n){if(!(this._activeDragInstances().indexOf(t)>-1)&&(this._loadResets(),this._activeDragInstances.update(o=>[...o,t]),1===this._activeDragInstances().length)){const o=n.type.startsWith("touch");this._globalListeners.set(o?"touchend":"mouseup",{handler:f=>this.pointerUp.next(f),options:!0}).set("scroll",{handler:f=>this.scroll.next(f),options:!0}).set("selectstart",{handler:this._preventDefaultWhileDragging,options:yc}),o||this._globalListeners.set("mousemove",{handler:f=>this.pointerMove.next(f),options:yc}),this._ngZone.runOutsideAngular(()=>{this._globalListeners.forEach((f,D)=>{this._document.addEventListener(D,f.handler,f.options)})})}}stopDragging(t){this._activeDragInstances.update(n=>{const o=n.indexOf(t);return o>-1?(n.splice(o,1),[...n]):n}),0===this._activeDragInstances().length&&this._clearGlobalListeners()}isDragging(t){return this._activeDragInstances().indexOf(t)>-1}scrolled(t){const n=[this.scroll];return t&&t!==this._document&&n.push(new i.Observable(o=>this._ngZone.runOutsideAngular(()=>{const D=j=>{this._activeDragInstances().length&&o.next(j)};return t.addEventListener("scroll",D,!0),()=>{t.removeEventListener("scroll",D,!0)}}))),(0,i.merge)(...n)}ngOnDestroy(){this._dragInstances.forEach(t=>this.removeDragItem(t)),this._dropInstances.forEach(t=>this.removeDropContainer(t)),this._clearGlobalListeners(),this.pointerMove.complete(),this.pointerUp.complete()}_clearGlobalListeners(){this._globalListeners.forEach((t,n)=>{this._document.removeEventListener(n,t.handler,t.options)}),this._globalListeners.clear()}_loadResets(){if(!Ue.has(this._appRef)){Ue.add(this._appRef);const t=(0,e.createComponent)(ne,{environmentInjector:this._environmentInjector});this._appRef.onDestroy(()=>{Ue.delete(this._appRef),0===Ue.size&&t.destroy()})}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(e.NgZone),e.\u0275\u0275inject(ve.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const rt={dragStartThreshold:5,pointerDirectionChangeThreshold:5};let Ut=(()=>{class r{constructor(t,n,o,f){this._document=t,this._ngZone=n,this._viewportRuler=o,this._dragDropRegistry=f}createDrag(t,n=rt){return new pf(t,n,this._document,this._ngZone,this._viewportRuler,this._dragDropRegistry)}createDropList(t){return new ll(t,this._dragDropRegistry,this._document,this._ngZone,this._viewportRuler)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ve.DOCUMENT),e.\u0275\u0275inject(e.NgZone),e.\u0275\u0275inject(Ai.Xj),e.\u0275\u0275inject(Pe))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Rn=new e.InjectionToken("CDK_DRAG_PARENT"),Y=new e.InjectionToken("CdkDragHandle"),ue=new e.InjectionToken("CDK_DRAG_CONFIG"),Ze=new e.InjectionToken("CdkDropList");let kt=(()=>{class r{static#e=this._dragInstances=[];get disabled(){return this._disabled||this.dropContainer&&this.dropContainer.disabled}set disabled(t){this._disabled=t,this._dragRef.disabled=this._disabled}constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn){this.element=t,this.dropContainer=n,this._ngZone=f,this._viewContainerRef=D,this._dir=fe,this._changeDetectorRef=vt,this._selfHandle=ln,this._parentDrag=Hn,this._destroyed=new i.Subject,this._handles=new i.BehaviorSubject([]),this.scale=1,this.started=new e.EventEmitter,this.released=new e.EventEmitter,this.ended=new e.EventEmitter,this.entered=new e.EventEmitter,this.exited=new e.EventEmitter,this.dropped=new e.EventEmitter,this.moved=new i.Observable(Oi=>{const Lr=this._dragRef.moved.pipe((0,M.map)(to=>({source:this,pointerPosition:to.pointerPosition,event:to.event,delta:to.delta,distance:to.distance}))).subscribe(Oi);return()=>{Lr.unsubscribe()}}),this._injector=(0,e.inject)(e.Injector),this._dragRef=Ne.createDrag(t,{dragStartThreshold:j&&null!=j.dragStartThreshold?j.dragStartThreshold:5,pointerDirectionChangeThreshold:j&&null!=j.pointerDirectionChangeThreshold?j.pointerDirectionChangeThreshold:5,zIndex:j?.zIndex}),this._dragRef.data=this,r._dragInstances.push(this),j&&this._assignDefaults(j),n&&(this._dragRef._withDropContainer(n._dropListRef),n.addItem(this),n._dropListRef.beforeStarted.pipe((0,M.takeUntil)(this._destroyed)).subscribe(()=>{this._dragRef.scale=this.scale})),this._syncInputs(this._dragRef),this._handleEvents(this._dragRef)}getPlaceholderElement(){return this._dragRef.getPlaceholderElement()}getRootElement(){return this._dragRef.getRootElement()}reset(){this._dragRef.reset()}getFreeDragPosition(){return this._dragRef.getFreeDragPosition()}setFreeDragPosition(t){this._dragRef.setFreeDragPosition(t)}ngAfterViewInit(){(0,e.afterNextRender)(()=>{this._updateRootElement(),this._setupHandlesListener(),this._dragRef.scale=this.scale,this.freeDragPosition&&this._dragRef.setFreeDragPosition(this.freeDragPosition)},{injector:this._injector})}ngOnChanges(t){const n=t.rootElementSelector,o=t.freeDragPosition;n&&!n.firstChange&&this._updateRootElement(),this._dragRef.scale=this.scale,o&&!o.firstChange&&this.freeDragPosition&&this._dragRef.setFreeDragPosition(this.freeDragPosition)}ngOnDestroy(){this.dropContainer&&this.dropContainer.removeItem(this);const t=r._dragInstances.indexOf(this);t>-1&&r._dragInstances.splice(t,1),this._ngZone.runOutsideAngular(()=>{this._handles.complete(),this._destroyed.next(),this._destroyed.complete(),this._dragRef.dispose()})}_addHandle(t){const n=this._handles.getValue();n.push(t),this._handles.next(n)}_removeHandle(t){const n=this._handles.getValue(),o=n.indexOf(t);o>-1&&(n.splice(o,1),this._handles.next(n))}_setPreviewTemplate(t){this._previewTemplate=t}_resetPreviewTemplate(t){t===this._previewTemplate&&(this._previewTemplate=null)}_setPlaceholderTemplate(t){this._placeholderTemplate=t}_resetPlaceholderTemplate(t){t===this._placeholderTemplate&&(this._placeholderTemplate=null)}_updateRootElement(){const t=this.element.nativeElement;let n=t;this.rootElementSelector&&(n=void 0!==t.closest?t.closest(this.rootElementSelector):t.parentElement?.closest(this.rootElementSelector)),this._dragRef.withRootElement(n||t)}_getBoundaryElement(){const t=this.boundaryElement;return t?"string"==typeof t?this.element.nativeElement.closest(t):(0,ie.i8)(t):null}_syncInputs(t){t.beforeStarted.subscribe(()=>{if(!t.isDragging()){const n=this._dir,o=this.dragStartDelay,f=this._placeholderTemplate?{template:this._placeholderTemplate.templateRef,context:this._placeholderTemplate.data,viewContainer:this._viewContainerRef}:null,D=this._previewTemplate?{template:this._previewTemplate.templateRef,context:this._previewTemplate.data,matchSize:this._previewTemplate.matchSize,viewContainer:this._viewContainerRef}:null;t.disabled=this.disabled,t.lockAxis=this.lockAxis,t.scale=this.scale,t.dragStartDelay="object"==typeof o&&o?o:(0,ie.OE)(o),t.constrainPosition=this.constrainPosition,t.previewClass=this.previewClass,t.withBoundaryElement(this._getBoundaryElement()).withPlaceholderTemplate(f).withPreviewTemplate(D).withPreviewContainer(this.previewContainer||"global"),n&&t.withDirection(n.value)}}),t.beforeStarted.pipe((0,M.take)(1)).subscribe(()=>{if(this._parentDrag)return void t.withParent(this._parentDrag._dragRef);let n=this.element.nativeElement.parentElement;for(;n;){if(n.classList.contains("cdk-drag")){t.withParent(r._dragInstances.find(o=>o.element.nativeElement===n)?._dragRef||null);break}n=n.parentElement}})}_handleEvents(t){t.started.subscribe(n=>{this.started.emit({source:this,event:n.event}),this._changeDetectorRef.markForCheck()}),t.released.subscribe(n=>{this.released.emit({source:this,event:n.event})}),t.ended.subscribe(n=>{this.ended.emit({source:this,distance:n.distance,dropPoint:n.dropPoint,event:n.event}),this._changeDetectorRef.markForCheck()}),t.entered.subscribe(n=>{this.entered.emit({container:n.container.data,item:this,currentIndex:n.currentIndex})}),t.exited.subscribe(n=>{this.exited.emit({container:n.container.data,item:this})}),t.dropped.subscribe(n=>{this.dropped.emit({previousIndex:n.previousIndex,currentIndex:n.currentIndex,previousContainer:n.previousContainer.data,container:n.container.data,isPointerOverContainer:n.isPointerOverContainer,item:this,distance:n.distance,dropPoint:n.dropPoint,event:n.event})})}_assignDefaults(t){const{lockAxis:n,dragStartDelay:o,constrainPosition:f,previewClass:D,boundaryElement:j,draggingDisabled:fe,rootElementSelector:Ne,previewContainer:vt}=t;this.disabled=fe??!1,this.dragStartDelay=o||0,n&&(this.lockAxis=n),f&&(this.constrainPosition=f),D&&(this.previewClass=D),j&&(this.boundaryElement=j),Ne&&(this.rootElementSelector=Ne),vt&&(this.previewContainer=vt)}_setupHandlesListener(){this._handles.pipe((0,M.tap)(t=>{const n=t.map(o=>o.element);this._selfHandle&&this.rootElementSelector&&n.push(this.element),this._dragRef.withHandles(n)}),(0,M.switchMap)(t=>(0,i.merge)(...t.map(n=>n._stateChanges.pipe((0,M.startWith)(n))))),(0,M.takeUntil)(this._destroyed)).subscribe(t=>{const n=this._dragRef,o=t.element.nativeElement;t.disabled?n.disableHandle(o):n.enableHandle(o)})}static#t=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Ze,12),e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(ue,8),e.\u0275\u0275directiveInject(md.dS,8),e.\u0275\u0275directiveInject(Ut),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(Y,10),e.\u0275\u0275directiveInject(Rn,12))};static#n=this.\u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","cdkDrag",""]],hostAttrs:[1,"cdk-drag"],hostVars:4,hostBindings:function(n,o){2&n&&e.\u0275\u0275classProp("cdk-drag-disabled",o.disabled)("cdk-drag-dragging",o._dragRef.isDragging())},inputs:{data:[0,"cdkDragData","data"],lockAxis:[0,"cdkDragLockAxis","lockAxis"],rootElementSelector:[0,"cdkDragRootElement","rootElementSelector"],boundaryElement:[0,"cdkDragBoundary","boundaryElement"],dragStartDelay:[0,"cdkDragStartDelay","dragStartDelay"],freeDragPosition:[0,"cdkDragFreeDragPosition","freeDragPosition"],disabled:[2,"cdkDragDisabled","disabled",e.booleanAttribute],constrainPosition:[0,"cdkDragConstrainPosition","constrainPosition"],previewClass:[0,"cdkDragPreviewClass","previewClass"],previewContainer:[0,"cdkDragPreviewContainer","previewContainer"],scale:[2,"cdkDragScale","scale",e.numberAttribute]},outputs:{started:"cdkDragStarted",released:"cdkDragReleased",ended:"cdkDragEnded",entered:"cdkDragEntered",exited:"cdkDragExited",dropped:"cdkDragDropped",moved:"cdkDragMoved"},exportAs:["cdkDrag"],standalone:!0,features:[e.\u0275\u0275ProvidersFeature([{provide:Rn,useExisting:r}]),e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275NgOnChangesFeature]})}return r})();const rn=new e.InjectionToken("CdkDropListGroup");let oi=0,Yr=(()=>{class r{static#e=this._dropLists=[];get disabled(){return this._disabled||!!this._group&&this._group.disabled}set disabled(t){this._dropListRef.disabled=this._disabled=t}constructor(t,n,o,f,D,j,fe){this.element=t,this._changeDetectorRef=o,this._scrollDispatcher=f,this._dir=D,this._group=j,this._destroyed=new i.Subject,this.connectedTo=[],this.id="cdk-drop-list-"+oi++,this.enterPredicate=()=>!0,this.sortPredicate=()=>!0,this.dropped=new e.EventEmitter,this.entered=new e.EventEmitter,this.exited=new e.EventEmitter,this.sorted=new e.EventEmitter,this._unsortedItems=new Set,this._dropListRef=n.createDropList(t),this._dropListRef.data=this,fe&&this._assignDefaults(fe),this._dropListRef.enterPredicate=(Ne,vt)=>this.enterPredicate(Ne.data,vt.data),this._dropListRef.sortPredicate=(Ne,vt,ln)=>this.sortPredicate(Ne,vt.data,ln.data),this._setupInputSyncSubscription(this._dropListRef),this._handleEvents(this._dropListRef),r._dropLists.push(this),j&&j._items.add(this)}addItem(t){this._unsortedItems.add(t),this._dropListRef.isDragging()&&this._syncItemsWithRef()}removeItem(t){this._unsortedItems.delete(t),this._dropListRef.isDragging()&&this._syncItemsWithRef()}getSortedItems(){return Array.from(this._unsortedItems).sort((t,n)=>t._dragRef.getVisibleElement().compareDocumentPosition(n._dragRef.getVisibleElement())&Node.DOCUMENT_POSITION_FOLLOWING?-1:1)}ngOnDestroy(){const t=r._dropLists.indexOf(this);t>-1&&r._dropLists.splice(t,1),this._group&&this._group._items.delete(this),this._unsortedItems.clear(),this._dropListRef.dispose(),this._destroyed.next(),this._destroyed.complete()}_setupInputSyncSubscription(t){this._dir&&this._dir.change.pipe((0,M.startWith)(this._dir.value),(0,M.takeUntil)(this._destroyed)).subscribe(n=>t.withDirection(n)),t.beforeStarted.subscribe(()=>{const n=(0,ie.FG)(this.connectedTo).map(o=>"string"==typeof o?r._dropLists.find(D=>D.id===o):o);if(this._group&&this._group._items.forEach(o=>{-1===n.indexOf(o)&&n.push(o)}),!this._scrollableParentsResolved){const o=this._scrollDispatcher.getAncestorScrollContainers(this.element).map(f=>f.getElementRef().nativeElement);this._dropListRef.withScrollableParents(o),this._scrollableParentsResolved=!0}if(this.elementContainerSelector){const o=this.element.nativeElement.querySelector(this.elementContainerSelector);t.withElementContainer(o)}t.disabled=this.disabled,t.lockAxis=this.lockAxis,t.sortingDisabled=this.sortingDisabled,t.autoScrollDisabled=this.autoScrollDisabled,t.autoScrollStep=(0,ie.OE)(this.autoScrollStep,2),t.connectedTo(n.filter(o=>o&&o!==this).map(o=>o._dropListRef)).withOrientation(this.orientation)})}_handleEvents(t){t.beforeStarted.subscribe(()=>{this._syncItemsWithRef(),this._changeDetectorRef.markForCheck()}),t.entered.subscribe(n=>{this.entered.emit({container:this,item:n.item.data,currentIndex:n.currentIndex})}),t.exited.subscribe(n=>{this.exited.emit({container:this,item:n.item.data}),this._changeDetectorRef.markForCheck()}),t.sorted.subscribe(n=>{this.sorted.emit({previousIndex:n.previousIndex,currentIndex:n.currentIndex,container:this,item:n.item.data})}),t.dropped.subscribe(n=>{this.dropped.emit({previousIndex:n.previousIndex,currentIndex:n.currentIndex,previousContainer:n.previousContainer.data,container:n.container.data,item:n.item.data,isPointerOverContainer:n.isPointerOverContainer,distance:n.distance,dropPoint:n.dropPoint,event:n.event}),this._changeDetectorRef.markForCheck()}),(0,i.merge)(t.receivingStarted,t.receivingStopped).subscribe(()=>this._changeDetectorRef.markForCheck())}_assignDefaults(t){const{lockAxis:n,draggingDisabled:o,sortingDisabled:f,listAutoScrollDisabled:D,listOrientation:j}=t;this.disabled=o??!1,this.sortingDisabled=f??!1,this.autoScrollDisabled=D??!1,this.orientation=j||"vertical",n&&(this.lockAxis=n)}_syncItemsWithRef(){this._dropListRef.withItems(this.getSortedItems().map(t=>t._dragRef))}static#t=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Ut),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(Ai.R),e.\u0275\u0275directiveInject(md.dS,8),e.\u0275\u0275directiveInject(rn,12),e.\u0275\u0275directiveInject(ue,8))};static#n=this.\u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","cdkDropList",""],["cdk-drop-list"]],hostAttrs:[1,"cdk-drop-list"],hostVars:7,hostBindings:function(n,o){2&n&&(e.\u0275\u0275attribute("id",o.id),e.\u0275\u0275classProp("cdk-drop-list-disabled",o.disabled)("cdk-drop-list-dragging",o._dropListRef.isDragging())("cdk-drop-list-receiving",o._dropListRef.isReceiving()))},inputs:{connectedTo:[0,"cdkDropListConnectedTo","connectedTo"],data:[0,"cdkDropListData","data"],orientation:[0,"cdkDropListOrientation","orientation"],id:"id",lockAxis:[0,"cdkDropListLockAxis","lockAxis"],disabled:[2,"cdkDropListDisabled","disabled",e.booleanAttribute],sortingDisabled:[2,"cdkDropListSortingDisabled","sortingDisabled",e.booleanAttribute],enterPredicate:[0,"cdkDropListEnterPredicate","enterPredicate"],sortPredicate:[0,"cdkDropListSortPredicate","sortPredicate"],autoScrollDisabled:[2,"cdkDropListAutoScrollDisabled","autoScrollDisabled",e.booleanAttribute],autoScrollStep:[0,"cdkDropListAutoScrollStep","autoScrollStep"],elementContainerSelector:[0,"cdkDropListElementContainer","elementContainerSelector"]},outputs:{dropped:"cdkDropListDropped",entered:"cdkDropListEntered",exited:"cdkDropListExited",sorted:"cdkDropListSorted"},exportAs:["cdkDropList"],standalone:!0,features:[e.\u0275\u0275ProvidersFeature([{provide:rn,useValue:void 0},{provide:Ze,useExisting:r}]),e.\u0275\u0275InputTransformsFeature]})}return r})(),ws=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[Ut],imports:[Ai.Gj]})}return r})();var Vc=S(1345),Wo=S(1820),sr=S(2810);class ro{static isArray(v,t=!0){return Array.isArray(v)&&(t||0!==v.length)}static isObject(v,t=!0){return"object"==typeof v&&!Array.isArray(v)&&null!=v&&(t||0!==Object.keys(v).length)}static equals(v,t,n){return n?this.resolveFieldData(v,n)===this.resolveFieldData(t,n):this.equalsByValue(v,t)}static equalsByValue(v,t){if(v===t)return!0;if(v&&t&&"object"==typeof v&&"object"==typeof t){var f,D,j,n=Array.isArray(v),o=Array.isArray(t);if(n&&o){if((D=v.length)!=t.length)return!1;for(f=D;0!=f--;)if(!this.equalsByValue(v[f],t[f]))return!1;return!0}if(n!=o)return!1;var fe=this.isDate(v),Ne=this.isDate(t);if(fe!=Ne)return!1;if(fe&&Ne)return v.getTime()==t.getTime();var vt=v instanceof RegExp,ln=t instanceof RegExp;if(vt!=ln)return!1;if(vt&&ln)return v.toString()==t.toString();var Hn=Object.keys(v);if((D=Hn.length)!==Object.keys(t).length)return!1;for(f=D;0!=f--;)if(!Object.prototype.hasOwnProperty.call(t,Hn[f]))return!1;for(f=D;0!=f--;)if(!this.equalsByValue(v[j=Hn[f]],t[j]))return!1;return!0}return v!=v&&t!=t}static resolveFieldData(v,t){if(v&&t){if(this.isFunction(t))return t(v);if(-1==t.indexOf("."))return v[t];{let n=t.split("."),o=v;for(let f=0,D=n.length;f<D;++f){if(null==o)return null;o=o[n[f]]}return o}}return null}static isFunction(v){return!!(v&&v.constructor&&v.call&&v.apply)}static reorderArray(v,t,n){v&&t!==n&&(n>=v.length&&(n%=v.length,t%=v.length),v.splice(n,0,v.splice(t,1)[0]))}static insertIntoOrderedArray(v,t,n,o){if(n.length>0){let f=!1;for(let D=0;D<n.length;D++)if(this.findIndexInList(n[D],o)>t){n.splice(D,0,v),f=!0;break}f||n.push(v)}else n.push(v)}static findIndexInList(v,t){let n=-1;if(t)for(let o=0;o<t.length;o++)if(t[o]==v){n=o;break}return n}static contains(v,t){if(null!=v&&t&&t.length)for(let n of t)if(this.equals(v,n))return!0;return!1}static removeAccents(v){return v&&(v=v.normalize("NFKD").replace(new RegExp("\\p{Diacritic}","gu"),"")),v}static isDate(v){return"[object Date]"===Object.prototype.toString.call(v)}static isEmpty(v){return null==v||""===v||Array.isArray(v)&&0===v.length||!this.isDate(v)&&"object"==typeof v&&0===Object.keys(v).length}static isNotEmpty(v){return!this.isEmpty(v)}static compare(v,t,n,o=1){let f=-1;const D=this.isEmpty(v),j=this.isEmpty(t);return f=D&&j?0:D?o:j?-o:"string"==typeof v&&"string"==typeof t?v.localeCompare(t,n,{numeric:!0}):v<t?-1:v>t?1:0,f}static sort(v,t,n=1,o,f=1){const D=ro.compare(v,t,o,n);let j=n;return(ro.isEmpty(v)||ro.isEmpty(t))&&(j=1===f?n:f),j*D}static merge(v,t){if(null!=v||null!=t)return null!=v&&"object"!=typeof v||null!=t&&"object"!=typeof t?null!=v&&"string"!=typeof v||null!=t&&"string"!=typeof t?t||v:[v||"",t||""].join(" "):{...v||{},...t||{}}}static isPrintableCharacter(v=""){return this.isNotEmpty(v)&&1===v.length&&v.match(/\S| /)}static getItemValue(v,...t){return this.isFunction(v)?v(...t):v}static findLastIndex(v,t){let n=-1;if(this.isNotEmpty(v))try{n=v.findLastIndex(t)}catch{n=v.lastIndexOf([...v].reverse().find(t))}return n}static findLast(v,t){let n;if(this.isNotEmpty(v))try{n=v.findLast(t)}catch{n=[...v].reverse().find(t)}return n}static deepEquals(v,t){if(v===t)return!0;if(v&&t&&"object"==typeof v&&"object"==typeof t){var f,D,j,n=Array.isArray(v),o=Array.isArray(t);if(n&&o){if((D=v.length)!=t.length)return!1;for(f=D;0!=f--;)if(!this.deepEquals(v[f],t[f]))return!1;return!0}if(n!=o)return!1;var fe=v instanceof Date,Ne=t instanceof Date;if(fe!=Ne)return!1;if(fe&&Ne)return v.getTime()==t.getTime();var vt=v instanceof RegExp,ln=t instanceof RegExp;if(vt!=ln)return!1;if(vt&&ln)return v.toString()==t.toString();var Hn=Object.keys(v);if((D=Hn.length)!==Object.keys(t).length)return!1;for(f=D;0!=f--;)if(!Object.prototype.hasOwnProperty.call(t,Hn[f]))return!1;for(f=D;0!=f--;)if(!this.deepEquals(v[j=Hn[f]],t[j]))return!1;return!0}return v!=v&&t!=t}}var Ic=0;function Sp(r="pn_id_"){return`${r}${++Ic}`}var Uu=function au(){let r=[];const o=f=>f&&parseInt(f.style.zIndex,10)||0;return{get:o,set:(f,D,j)=>{D&&(D.style.zIndex=String(((f,D)=>{let j=r.length>0?r[r.length-1]:{key:f,value:D},fe=j.value+(j.key===f?0:D)+2;return r.push({key:f,value:fe}),fe})(f,j)))},clear:f=>{f&&((f=>{r=r.filter(D=>D.value!==f)})(o(f)),f.style.zIndex="")},getCurrent:()=>r.length>0?r[r.length-1].value:0}}();const bh=["*"];let $u=(()=>class r{static STARTS_WITH="startsWith";static CONTAINS="contains";static NOT_CONTAINS="notContains";static ENDS_WITH="endsWith";static EQUALS="equals";static NOT_EQUALS="notEquals";static IN="in";static LESS_THAN="lt";static LESS_THAN_OR_EQUAL_TO="lte";static GREATER_THAN="gt";static GREATER_THAN_OR_EQUAL_TO="gte";static BETWEEN="between";static IS="is";static IS_NOT="isNot";static BEFORE="before";static AFTER="after";static DATE_IS="dateIs";static DATE_IS_NOT="dateIsNot";static DATE_BEFORE="dateBefore";static DATE_AFTER="dateAfter"})(),yg=(()=>{class r{filter(t,n,o,f,D){let j=[];if(t)for(let fe of t)for(let Ne of n){let vt=ro.resolveFieldData(fe,Ne);if(this.filters[f](vt,o,D)){j.push(fe);break}}return j}filters={startsWith:(t,n,o)=>{if(null==n||""===n.trim())return!0;if(null==t)return!1;let f=ro.removeAccents(n.toString()).toLocaleLowerCase(o);return ro.removeAccents(t.toString()).toLocaleLowerCase(o).slice(0,f.length)===f},contains:(t,n,o)=>{if(null==n||"string"==typeof n&&""===n.trim())return!0;if(null==t)return!1;let f=ro.removeAccents(n.toString()).toLocaleLowerCase(o);return-1!==ro.removeAccents(t.toString()).toLocaleLowerCase(o).indexOf(f)},notContains:(t,n,o)=>{if(null==n||"string"==typeof n&&""===n.trim())return!0;if(null==t)return!1;let f=ro.removeAccents(n.toString()).toLocaleLowerCase(o);return-1===ro.removeAccents(t.toString()).toLocaleLowerCase(o).indexOf(f)},endsWith:(t,n,o)=>{if(null==n||""===n.trim())return!0;if(null==t)return!1;let f=ro.removeAccents(n.toString()).toLocaleLowerCase(o),D=ro.removeAccents(t.toString()).toLocaleLowerCase(o);return-1!==D.indexOf(f,D.length-f.length)},equals:(t,n,o)=>null==n||"string"==typeof n&&""===n.trim()||null!=t&&(t.getTime&&n.getTime?t.getTime()===n.getTime():t==n||ro.removeAccents(t.toString()).toLocaleLowerCase(o)==ro.removeAccents(n.toString()).toLocaleLowerCase(o)),notEquals:(t,n,o)=>!(null==n||"string"==typeof n&&""===n.trim()||null!=t&&(t.getTime&&n.getTime?t.getTime()===n.getTime():t==n||ro.removeAccents(t.toString()).toLocaleLowerCase(o)==ro.removeAccents(n.toString()).toLocaleLowerCase(o))),in:(t,n)=>{if(null==n||0===n.length)return!0;for(let o=0;o<n.length;o++)if(ro.equals(t,n[o]))return!0;return!1},between:(t,n)=>null==n||null==n[0]||null==n[1]||null!=t&&(t.getTime?n[0].getTime()<=t.getTime()&&t.getTime()<=n[1].getTime():n[0]<=t&&t<=n[1]),lt:(t,n,o)=>null==n||null!=t&&(t.getTime&&n.getTime?t.getTime()<n.getTime():t<n),lte:(t,n,o)=>null==n||null!=t&&(t.getTime&&n.getTime?t.getTime()<=n.getTime():t<=n),gt:(t,n,o)=>null==n||null!=t&&(t.getTime&&n.getTime?t.getTime()>n.getTime():t>n),gte:(t,n,o)=>null==n||null!=t&&(t.getTime&&n.getTime?t.getTime()>=n.getTime():t>=n),is:(t,n,o)=>this.filters.equals(t,n,o),isNot:(t,n,o)=>this.filters.notEquals(t,n,o),before:(t,n,o)=>this.filters.lt(t,n,o),after:(t,n,o)=>this.filters.gt(t,n,o),dateIs:(t,n)=>null==n||null!=t&&t.toDateString()===n.toDateString(),dateIsNot:(t,n)=>null==n||null!=t&&t.toDateString()!==n.toDateString(),dateBefore:(t,n)=>null==n||null!=t&&t.getTime()<n.getTime(),dateAfter:(t,n)=>{if(null==n)return!0;if(null==t)return!1;const o=new Date(t);return o.setHours(0,0,0,0),o.getTime()>n.getTime()}};register(t,n){this.filters[t]=n}static \u0275fac=function(n){return new(n||r)};static \u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xv=(()=>{class r{clickSource=new i.Subject;clickObservable=this.clickSource.asObservable();add(t){t&&this.clickSource.next(t)}static \u0275fac=function(n){return new(n||r)};static \u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),mf=(()=>{class r{ripple=!1;inputStyle=(0,e.signal)("outlined");overlayOptions={};csp=(0,e.signal)({nonce:void 0});filterMatchModeOptions={text:[$u.STARTS_WITH,$u.CONTAINS,$u.NOT_CONTAINS,$u.ENDS_WITH,$u.EQUALS,$u.NOT_EQUALS],numeric:[$u.EQUALS,$u.NOT_EQUALS,$u.LESS_THAN,$u.LESS_THAN_OR_EQUAL_TO,$u.GREATER_THAN,$u.GREATER_THAN_OR_EQUAL_TO],date:[$u.DATE_IS,$u.DATE_IS_NOT,$u.DATE_BEFORE,$u.DATE_AFTER]};translation={startsWith:"Starts with",contains:"Contains",notContains:"Not contains",endsWith:"Ends with",equals:"Equals",notEquals:"Not equals",noFilter:"No Filter",lt:"Less than",lte:"Less than or equal to",gt:"Greater than",gte:"Greater than or equal to",is:"Is",isNot:"Is not",before:"Before",after:"After",dateIs:"Date is",dateIsNot:"Date is not",dateBefore:"Date is before",dateAfter:"Date is after",clear:"Clear",apply:"Apply",matchAll:"Match All",matchAny:"Match Any",addRule:"Add Rule",removeRule:"Remove Rule",accept:"Yes",reject:"No",choose:"Choose",upload:"Upload",cancel:"Cancel",pending:"Pending",fileSizeTypes:["B","KB","MB","GB","TB","PB","EB","ZB","YB"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],chooseYear:"Choose Year",chooseMonth:"Choose Month",chooseDate:"Choose Date",prevDecade:"Previous Decade",nextDecade:"Next Decade",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",prevHour:"Previous Hour",nextHour:"Next Hour",prevMinute:"Previous Minute",nextMinute:"Next Minute",prevSecond:"Previous Second",nextSecond:"Next Second",am:"am",pm:"pm",dateFormat:"mm/dd/yy",firstDayOfWeek:0,today:"Today",weekHeader:"Wk",weak:"Weak",medium:"Medium",strong:"Strong",passwordPrompt:"Enter a password",emptyMessage:"No results found",searchMessage:"{0} results are available",selectionMessage:"{0} items selected",emptySelectionMessage:"No selected item",emptySearchMessage:"No results found",emptyFilterMessage:"No results found",aria:{trueLabel:"True",falseLabel:"False",nullLabel:"Not Selected",star:"1 star",stars:"{star} stars",selectAll:"All items selected",unselectAll:"All items unselected",close:"Close",previous:"Previous",next:"Next",navigation:"Navigation",scrollTop:"Scroll Top",moveTop:"Move Top",moveUp:"Move Up",moveDown:"Move Down",moveBottom:"Move Bottom",moveToTarget:"Move to Target",moveToSource:"Move to Source",moveAllToTarget:"Move All to Target",moveAllToSource:"Move All to Source",pageLabel:"{page}",firstPageLabel:"First Page",lastPageLabel:"Last Page",nextPageLabel:"Next Page",prevPageLabel:"Previous Page",rowsPerPageLabel:"Rows per page",previousPageLabel:"Previous Page",jumpToPageDropdownLabel:"Jump to Page Dropdown",jumpToPageInputLabel:"Jump to Page Input",selectRow:"Row Selected",unselectRow:"Row Unselected",expandRow:"Row Expanded",collapseRow:"Row Collapsed",showFilterMenu:"Show Filter Menu",hideFilterMenu:"Hide Filter Menu",filterOperator:"Filter Operator",filterConstraint:"Filter Constraint",editRow:"Row Edit",saveEdit:"Save Edit",cancelEdit:"Cancel Edit",listView:"List View",gridView:"Grid View",slide:"Slide",slideNumber:"{slideNumber}",zoomImage:"Zoom Image",zoomIn:"Zoom In",zoomOut:"Zoom Out",rotateRight:"Rotate Right",rotateLeft:"Rotate Left",listLabel:"Option List",selectColor:"Select a color",removeLabel:"Remove",browseFiles:"Browse Files",maximizeLabel:"Maximize"}};zIndex={modal:1100,overlay:1e3,menu:1e3,tooltip:1100};translationSource=new i.Subject;translationObserver=this.translationSource.asObservable();getTranslation(t){return this.translation[t]}setTranslation(t){this.translation={...this.translation,...t},this.translationSource.next(this.translation)}static \u0275fac=function(n){return new(n||r)};static \u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),U_=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-header"]],standalone:!0,features:[e.\u0275\u0275StandaloneFeature],ngContentSelectors:bh,decls:1,vars:0,template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275projection(0))},encapsulation:2})}return r})(),Ch=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-footer"]],standalone:!0,features:[e.\u0275\u0275StandaloneFeature],ngContentSelectors:bh,decls:1,vars:0,template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275projection(0))},encapsulation:2})}return r})(),Zc=(()=>{class r{template;type;name;constructor(t){this.template=t}getType(){return this.name}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.TemplateRef))};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pTemplate",""]],inputs:{type:"type",name:[0,"pTemplate","name"]},standalone:!0})}return r})(),Tu=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({})}return r})(),If=(()=>class r{static STARTS_WITH="startsWith";static CONTAINS="contains";static NOT_CONTAINS="notContains";static ENDS_WITH="endsWith";static EQUALS="equals";static NOT_EQUALS="notEquals";static NO_FILTER="noFilter";static LT="lt";static LTE="lte";static GT="gt";static GTE="gte";static IS="is";static IS_NOT="isNot";static BEFORE="before";static AFTER="after";static CLEAR="clear";static APPLY="apply";static MATCH_ALL="matchAll";static MATCH_ANY="matchAny";static ADD_RULE="addRule";static REMOVE_RULE="removeRule";static ACCEPT="accept";static REJECT="reject";static CHOOSE="choose";static UPLOAD="upload";static CANCEL="cancel";static PENDING="pending";static FILE_SIZE_TYPES="fileSizeTypes";static DAY_NAMES="dayNames";static DAY_NAMES_SHORT="dayNamesShort";static DAY_NAMES_MIN="dayNamesMin";static MONTH_NAMES="monthNames";static MONTH_NAMES_SHORT="monthNamesShort";static FIRST_DAY_OF_WEEK="firstDayOfWeek";static TODAY="today";static WEEK_HEADER="weekHeader";static WEAK="weak";static MEDIUM="medium";static STRONG="strong";static PASSWORD_PROMPT="passwordPrompt";static EMPTY_MESSAGE="emptyMessage";static EMPTY_FILTER_MESSAGE="emptyFilterMessage";static SHOW_FILTER_MENU="showFilterMenu";static HIDE_FILTER_MENU="hideFilterMenu";static SELECTION_MESSAGE="selectionMessage";static ARIA="aria";static SELECT_COLOR="selectColor";static BROWSE_FILES="browseFiles"})();var Ji=S(1738);let xr=(()=>{class r{static zindex=1e3;static calculatedScrollbarWidth=null;static calculatedScrollbarHeight=null;static browser;static addClass(t,n){t&&n&&(t.classList?t.classList.add(n):t.className+=" "+n)}static addMultipleClasses(t,n){if(t&&n)if(t.classList){let o=n.trim().split(" ");for(let f=0;f<o.length;f++)t.classList.add(o[f])}else{let o=n.split(" ");for(let f=0;f<o.length;f++)t.className+=" "+o[f]}}static removeClass(t,n){t&&n&&(t.classList?t.classList.remove(n):t.className=t.className.replace(new RegExp("(^|\\b)"+n.split(" ").join("|")+"(\\b|$)","gi")," "))}static removeMultipleClasses(t,n){t&&n&&[n].flat().filter(Boolean).forEach(o=>o.split(" ").forEach(f=>this.removeClass(t,f)))}static hasClass(t,n){return!(!t||!n)&&(t.classList?t.classList.contains(n):new RegExp("(^| )"+n+"( |$)","gi").test(t.className))}static siblings(t){return Array.prototype.filter.call(t.parentNode.children,function(n){return n!==t})}static find(t,n){return Array.from(t.querySelectorAll(n))}static findSingle(t,n){return this.isElement(t)?t.querySelector(n):null}static index(t){let n=t.parentNode.childNodes,o=0;for(var f=0;f<n.length;f++){if(n[f]==t)return o;1==n[f].nodeType&&o++}return-1}static indexWithinGroup(t,n){let o=t.parentNode?t.parentNode.childNodes:[],f=0;for(var D=0;D<o.length;D++){if(o[D]==t)return f;o[D].attributes&&o[D].attributes[n]&&1==o[D].nodeType&&f++}return-1}static appendOverlay(t,n,o="self"){"self"!==o&&t&&n&&this.appendChild(t,n)}static alignOverlay(t,n,o="self",f=!0){t&&n&&(f&&(t.style.minWidth=`${r.getOuterWidth(n)}px`),"self"===o?this.relativePosition(t,n):this.absolutePosition(t,n))}static relativePosition(t,n,o=!0){const f=Rs=>{if(Rs)return"relative"===getComputedStyle(Rs).getPropertyValue("position")?Rs:f(Rs.parentElement)},D=t.offsetParent?{width:t.offsetWidth,height:t.offsetHeight}:this.getHiddenElementDimensions(t),j=n.offsetHeight??n.getBoundingClientRect().height,fe=n.getBoundingClientRect(),Ne=this.getWindowScrollTop(),vt=this.getWindowScrollLeft(),ln=this.getViewport(),Oi=f(t)?.getBoundingClientRect()||{top:-1*Ne,left:-1*vt};let Lr,to;fe.top+j+D.height>ln.height?(Lr=fe.top-Oi.top-D.height,t.style.transformOrigin="bottom",fe.top+Lr<0&&(Lr=-1*fe.top)):(Lr=j+fe.top-Oi.top,t.style.transformOrigin="top");const Mr=fe.left+D.width-ln.width;to=D.width>ln.width?-1*(fe.left-Oi.left):Mr>0?fe.left-Oi.left-Mr:fe.left-Oi.left,t.style.top=Lr+"px",t.style.left=to+"px",o&&(t.style.marginTop="bottom"===origin?"calc(var(--p-anchor-gutter) * -1)":"calc(var(--p-anchor-gutter))")}static absolutePosition(t,n,o=!0){const f=t.offsetParent?{width:t.offsetWidth,height:t.offsetHeight}:this.getHiddenElementDimensions(t),D=f.height,j=f.width,fe=n.offsetHeight??n.getBoundingClientRect().height,Ne=n.offsetWidth??n.getBoundingClientRect().width,vt=n.getBoundingClientRect(),ln=this.getWindowScrollTop(),Hn=this.getWindowScrollLeft(),Oi=this.getViewport();let Lr,to;vt.top+fe+D>Oi.height?(Lr=vt.top+ln-D,t.style.transformOrigin="bottom",Lr<0&&(Lr=ln)):(Lr=fe+vt.top+ln,t.style.transformOrigin="top"),to=vt.left+j>Oi.width?Math.max(0,vt.left+Hn+Ne-j):vt.left+Hn,t.style.top=Lr+"px",t.style.left=to+"px",o&&(t.style.marginTop="bottom"===origin?"calc(var(--p-anchor-gutter) * -1)":"calc(var(--p-anchor-gutter))")}static getParents(t,n=[]){return null===t.parentNode?n:this.getParents(t.parentNode,n.concat([t.parentNode]))}static getScrollableParents(t){let n=[];if(t){let o=this.getParents(t);const f=/(auto|scroll)/,D=j=>{let fe=window.getComputedStyle(j,null);return f.test(fe.getPropertyValue("overflow"))||f.test(fe.getPropertyValue("overflowX"))||f.test(fe.getPropertyValue("overflowY"))};for(let j of o){let fe=1===j.nodeType&&j.dataset.scrollselectors;if(fe){let Ne=fe.split(",");for(let vt of Ne){let ln=this.findSingle(j,vt);ln&&D(ln)&&n.push(ln)}}9!==j.nodeType&&D(j)&&n.push(j)}}return n}static getHiddenElementOuterHeight(t){t.style.visibility="hidden",t.style.display="block";let n=t.offsetHeight;return t.style.display="none",t.style.visibility="visible",n}static getHiddenElementOuterWidth(t){t.style.visibility="hidden",t.style.display="block";let n=t.offsetWidth;return t.style.display="none",t.style.visibility="visible",n}static getHiddenElementDimensions(t){let n={};return t.style.visibility="hidden",t.style.display="block",n.width=t.offsetWidth,n.height=t.offsetHeight,t.style.display="none",t.style.visibility="visible",n}static scrollInView(t,n){let o=getComputedStyle(t).getPropertyValue("borderTopWidth"),f=o?parseFloat(o):0,D=getComputedStyle(t).getPropertyValue("paddingTop"),j=D?parseFloat(D):0,fe=t.getBoundingClientRect(),vt=n.getBoundingClientRect().top+document.body.scrollTop-(fe.top+document.body.scrollTop)-f-j,ln=t.scrollTop,Hn=t.clientHeight,Oi=this.getOuterHeight(n);vt<0?t.scrollTop=ln+vt:vt+Oi>Hn&&(t.scrollTop=ln+vt-Hn+Oi)}static fadeIn(t,n){t.style.opacity=0;let o=+new Date,f=0,D=function(){f=+t.style.opacity.replace(",",".")+((new Date).getTime()-o)/n,t.style.opacity=f,o=+new Date,+f<1&&(window.requestAnimationFrame&&requestAnimationFrame(D)||setTimeout(D,16))};D()}static fadeOut(t,n){var o=1,j=50/n;let fe=setInterval(()=>{(o-=j)<=0&&(o=0,clearInterval(fe)),t.style.opacity=o},50)}static getWindowScrollTop(){let t=document.documentElement;return(window.pageYOffset||t.scrollTop)-(t.clientTop||0)}static getWindowScrollLeft(){let t=document.documentElement;return(window.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}static matches(t,n){var o=Element.prototype;return(o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.msMatchesSelector||function(D){return-1!==[].indexOf.call(document.querySelectorAll(D),this)}).call(t,n)}static getOuterWidth(t,n){let o=t.offsetWidth;if(n){let f=getComputedStyle(t);o+=parseFloat(f.marginLeft)+parseFloat(f.marginRight)}return o}static getHorizontalPadding(t){let n=getComputedStyle(t);return parseFloat(n.paddingLeft)+parseFloat(n.paddingRight)}static getHorizontalMargin(t){let n=getComputedStyle(t);return parseFloat(n.marginLeft)+parseFloat(n.marginRight)}static innerWidth(t){let n=t.offsetWidth,o=getComputedStyle(t);return n+=parseFloat(o.paddingLeft)+parseFloat(o.paddingRight),n}static width(t){let n=t.offsetWidth,o=getComputedStyle(t);return n-=parseFloat(o.paddingLeft)+parseFloat(o.paddingRight),n}static getInnerHeight(t){let n=t.offsetHeight,o=getComputedStyle(t);return n+=parseFloat(o.paddingTop)+parseFloat(o.paddingBottom),n}static getOuterHeight(t,n){let o=t.offsetHeight;if(n){let f=getComputedStyle(t);o+=parseFloat(f.marginTop)+parseFloat(f.marginBottom)}return o}static getHeight(t){let n=t.offsetHeight,o=getComputedStyle(t);return n-=parseFloat(o.paddingTop)+parseFloat(o.paddingBottom)+parseFloat(o.borderTopWidth)+parseFloat(o.borderBottomWidth),n}static getWidth(t){let n=t.offsetWidth,o=getComputedStyle(t);return n-=parseFloat(o.paddingLeft)+parseFloat(o.paddingRight)+parseFloat(o.borderLeftWidth)+parseFloat(o.borderRightWidth),n}static getViewport(){let t=window,n=document,o=n.documentElement,f=n.getElementsByTagName("body")[0];return{width:t.innerWidth||o.clientWidth||f.clientWidth,height:t.innerHeight||o.clientHeight||f.clientHeight}}static getOffset(t){var n=t.getBoundingClientRect();return{top:n.top+(window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0),left:n.left+(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0)}}static replaceElementWith(t,n){let o=t.parentNode;if(!o)throw"Can't replace element";return o.replaceChild(n,t)}static getUserAgent(){if(navigator&&this.isClient())return navigator.userAgent}static isIE(){var t=window.navigator.userAgent;return t.indexOf("MSIE ")>0||(t.indexOf("Trident/")>0?(t.indexOf("rv:"),!0):t.indexOf("Edge/")>0)}static isIOS(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream}static isAndroid(){return/(android)/i.test(navigator.userAgent)}static isTouchDevice(){return"ontouchstart"in window||navigator.maxTouchPoints>0}static appendChild(t,n){if(this.isElement(n))n.appendChild(t);else{if(!(n&&n.el&&n.el.nativeElement))throw"Cannot append "+n+" to "+t;n.el.nativeElement.appendChild(t)}}static removeChild(t,n){if(this.isElement(n))n.removeChild(t);else{if(!n.el||!n.el.nativeElement)throw"Cannot remove "+t+" from "+n;n.el.nativeElement.removeChild(t)}}static removeElement(t){"remove"in Element.prototype?t.remove():t.parentNode.removeChild(t)}static isElement(t){return"object"==typeof HTMLElement?t instanceof HTMLElement:t&&"object"==typeof t&&null!==t&&1===t.nodeType&&"string"==typeof t.nodeName}static calculateScrollbarWidth(t){if(t){let n=getComputedStyle(t);return t.offsetWidth-t.clientWidth-parseFloat(n.borderLeftWidth)-parseFloat(n.borderRightWidth)}{if(null!==this.calculatedScrollbarWidth)return this.calculatedScrollbarWidth;let n=document.createElement("div");n.className="p-scrollbar-measure",document.body.appendChild(n);let o=n.offsetWidth-n.clientWidth;return document.body.removeChild(n),this.calculatedScrollbarWidth=o,o}}static calculateScrollbarHeight(){if(null!==this.calculatedScrollbarHeight)return this.calculatedScrollbarHeight;let t=document.createElement("div");t.className="p-scrollbar-measure",document.body.appendChild(t);let n=t.offsetHeight-t.clientHeight;return document.body.removeChild(t),this.calculatedScrollbarWidth=n,n}static invokeElementMethod(t,n,o){t[n].apply(t,o)}static clearSelection(){if(window.getSelection)window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().rangeCount>0&&window.getSelection().getRangeAt(0).getClientRects().length>0&&window.getSelection().removeAllRanges();else if(document.selection&&document.selection.empty)try{document.selection.empty()}catch{}}static getBrowser(){if(!this.browser){let t=this.resolveUserAgent();this.browser={},t.browser&&(this.browser[t.browser]=!0,this.browser.version=t.version),this.browser.chrome?this.browser.webkit=!0:this.browser.webkit&&(this.browser.safari=!0)}return this.browser}static resolveUserAgent(){let t=navigator.userAgent.toLowerCase(),n=/(chrome)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+)/.exec(t)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(t)||/(msie) ([\w.]+)/.exec(t)||t.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(t)||[];return{browser:n[1]||"",version:n[2]||"0"}}static isInteger(t){return Number.isInteger?Number.isInteger(t):"number"==typeof t&&isFinite(t)&&Math.floor(t)===t}static isHidden(t){return!t||null===t.offsetParent}static isVisible(t){return t&&null!=t.offsetParent}static isExist(t){return null!==t&&typeof t<"u"&&t.nodeName&&t.parentNode}static focus(t,n){t&&document.activeElement!==t&&t.focus(n)}static getFocusableSelectorString(t=""){return`button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n .p-inputtext:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t},\n .p-button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${t}`}static getFocusableElements(t,n=""){let o=this.find(t,this.getFocusableSelectorString(n)),f=[];for(let D of o){const j=getComputedStyle(D);this.isVisible(D)&&"none"!=j.display&&"hidden"!=j.visibility&&f.push(D)}return f}static getFocusableElement(t,n=""){let o=this.findSingle(t,this.getFocusableSelectorString(n));if(o){const f=getComputedStyle(o);if(this.isVisible(o)&&"none"!=f.display&&"hidden"!=f.visibility)return o}return null}static getFirstFocusableElement(t,n=""){const o=this.getFocusableElements(t,n);return o.length>0?o[0]:null}static getLastFocusableElement(t,n){const o=this.getFocusableElements(t,n);return o.length>0?o[o.length-1]:null}static getNextFocusableElement(t,n=!1){const o=r.getFocusableElements(t);let f=0;if(o&&o.length>0){const D=o.indexOf(o[0].ownerDocument.activeElement);n?f=-1==D||0===D?o.length-1:D-1:-1!=D&&D!==o.length-1&&(f=D+1)}return o[f]}static generateZIndex(){return this.zindex=this.zindex||999,++this.zindex}static getSelection(){return window.getSelection?window.getSelection().toString():document.getSelection?document.getSelection().toString():document.selection?document.selection.createRange().text:null}static getTargetElement(t,n){if(!t)return null;switch(t){case"document":return document;case"window":return window;case"@next":return n?.nextElementSibling;case"@prev":return n?.previousElementSibling;case"@parent":return n?.parentElement;case"@grandparent":return n?.parentElement.parentElement;default:const o=typeof t;if("string"===o)return document.querySelector(t);if("object"===o&&t.hasOwnProperty("nativeElement"))return this.isExist(t.nativeElement)?t.nativeElement:void 0;const D=(j=t)&&j.constructor&&j.call&&j.apply?t():t;return D&&9===D.nodeType||this.isExist(D)?D:null}var j}static isClient(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}static getAttribute(t,n){if(t){const o=t.getAttribute(n);return isNaN(o)?"true"===o||"false"===o?"true"===o:o:+o}}static calculateBodyScrollbarWidth(){return window.innerWidth-document.documentElement.offsetWidth}static blockBodyScroll(t="p-overflow-hidden"){document.body.style.setProperty("--scrollbar-width",this.calculateBodyScrollbarWidth()+"px"),this.addClass(document.body,t)}static unblockBodyScroll(t="p-overflow-hidden"){document.body.style.removeProperty("--scrollbar-width"),this.removeClass(document.body,t)}static createElement(t,n={},...o){if(t){const f=document.createElement(t);return this.setAttributes(f,n),f.append(...o),f}}static setAttribute(t,n="",o){this.isElement(t)&&null!=o&&t.setAttribute(n,o)}static setAttributes(t,n={}){if(this.isElement(t)){const o=(f,D)=>{const j=t?.$attrs?.[f]?[t?.$attrs?.[f]]:[];return[D].flat().reduce((fe,Ne)=>{if(null!=Ne){const vt=typeof Ne;if("string"===vt||"number"===vt)fe.push(Ne);else if("object"===vt){const ln=Array.isArray(Ne)?o(f,Ne):Object.entries(Ne).map(([Hn,Oi])=>"style"!==f||!Oi&&0!==Oi?Oi?Hn:void 0:`${Hn.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}:${Oi}`);fe=ln.length?fe.concat(ln.filter(Hn=>!!Hn)):fe}}return fe},j)};Object.entries(n).forEach(([f,D])=>{if(null!=D){const j=f.match(/^on(.+)/);j?t.addEventListener(j[1].toLowerCase(),D):"pBind"===f?this.setAttributes(t,D):(D="class"===f?[...new Set(o("class",D))].join(" ").trim():"style"===f?o("style",D).join(";").trim():D,(t.$attrs=t.$attrs||{})&&(t.$attrs[f]=D),t.setAttribute(f,D))}})}}static isFocusableElement(t,n=""){return!!this.isElement(t)&&t.matches(`button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n},\n [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])${n}`)}}return r})();class Dh{element;listener;scrollableParents;constructor(v,t=()=>{}){this.element=v,this.listener=t}bindScrollListener(){this.scrollableParents=xr.getScrollableParents(this.element);for(let v=0;v<this.scrollableParents.length;v++)this.scrollableParents[v].addEventListener("scroll",this.listener)}unbindScrollListener(){if(this.scrollableParents)for(let v=0;v<this.scrollableParents.length;v++)this.scrollableParents[v].removeEventListener("scroll",this.listener)}destroy(){this.unbindScrollListener(),this.element=null,this.listener=null,this.scrollableParents=null}}const D0=["overlay"],$_=["content"],Cg=["*"],Sv=(r,v,t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi)=>({"p-overlay p-component":!0,"p-overlay-modal p-component-overlay p-component-overlay-enter":r,"p-overlay-center":v,"p-overlay-top":t,"p-overlay-top-start":n,"p-overlay-top-end":o,"p-overlay-bottom":f,"p-overlay-bottom-start":D,"p-overlay-bottom-end":j,"p-overlay-left":fe,"p-overlay-left-start":Ne,"p-overlay-left-end":vt,"p-overlay-right":ln,"p-overlay-right-start":Hn,"p-overlay-right-end":Oi}),Am=(r,v,t)=>({showTransitionParams:r,hideTransitionParams:v,transform:t}),ja=r=>({value:"visible",params:r}),xs=r=>({mode:r}),rd=r=>({$implicit:r});function Yd(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Qu(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",3,1),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onOverlayContentClick(o))})("@overlayContentAnimation.start",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onOverlayContentAnimationStart(o))})("@overlayContentAnimation.done",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onOverlayContentAnimationDone(o))}),e.\u0275\u0275projection(2),e.\u0275\u0275template(3,Yd,1,0,"ng-container",4),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap(t.contentStyleClass),e.\u0275\u0275property("ngStyle",t.contentStyle)("ngClass","p-overlay-content")("@overlayContentAnimation",e.\u0275\u0275pureFunction1(11,ja,e.\u0275\u0275pureFunction3(7,Am,t.showTransitionOptions,t.hideTransitionOptions,t.transformOptions[t.modal?t.overlayResponsiveDirection:"default"]))),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngTemplateOutlet",t.contentTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(15,rd,e.\u0275\u0275pureFunction1(13,xs,t.overlayMode)))}}function Xd(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",3,0),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onOverlayClick())}),e.\u0275\u0275template(2,Qu,4,17,"div",2),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.styleClass),e.\u0275\u0275property("ngStyle",t.style)("ngClass",e.\u0275\u0275pureFunctionV(5,Sv,[t.modal,t.modal&&"center"===t.overlayResponsiveDirection,t.modal&&"top"===t.overlayResponsiveDirection,t.modal&&"top-start"===t.overlayResponsiveDirection,t.modal&&"top-end"===t.overlayResponsiveDirection,t.modal&&"bottom"===t.overlayResponsiveDirection,t.modal&&"bottom-start"===t.overlayResponsiveDirection,t.modal&&"bottom-end"===t.overlayResponsiveDirection,t.modal&&"left"===t.overlayResponsiveDirection,t.modal&&"left-start"===t.overlayResponsiveDirection,t.modal&&"left-end"===t.overlayResponsiveDirection,t.modal&&"right"===t.overlayResponsiveDirection,t.modal&&"right-start"===t.overlayResponsiveDirection,t.modal&&"right-end"===t.overlayResponsiveDirection])),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.visible)}}const Ev={provide:Ji.NG_VALUE_ACCESSOR,useExisting:(0,e.forwardRef)(()=>va),multi:!0},sp=(0,sr.animation)([(0,sr.style)({transform:"{{transform}}",opacity:0}),(0,sr.animate)("{{showTransitionParams}}")]),Ep=(0,sr.animation)([(0,sr.animate)("{{hideTransitionParams}}",(0,sr.style)({transform:"{{transform}}",opacity:0}))]);let va=(()=>{class r{document;platformId;el;renderer;config;overlayService;cd;zone;get visible(){return this._visible}set visible(t){this._visible=t,this._visible&&!this.modalVisible&&(this.modalVisible=!0)}get mode(){return this._mode||this.overlayOptions?.mode}set mode(t){this._mode=t}get style(){return ro.merge(this._style,this.modal?this.overlayResponsiveOptions?.style:this.overlayOptions?.style)}set style(t){this._style=t}get styleClass(){return ro.merge(this._styleClass,this.modal?this.overlayResponsiveOptions?.styleClass:this.overlayOptions?.styleClass)}set styleClass(t){this._styleClass=t}get contentStyle(){return ro.merge(this._contentStyle,this.modal?this.overlayResponsiveOptions?.contentStyle:this.overlayOptions?.contentStyle)}set contentStyle(t){this._contentStyle=t}get contentStyleClass(){return ro.merge(this._contentStyleClass,this.modal?this.overlayResponsiveOptions?.contentStyleClass:this.overlayOptions?.contentStyleClass)}set contentStyleClass(t){this._contentStyleClass=t}get target(){const t=this._target||this.overlayOptions?.target;return void 0===t?"@prev":t}set target(t){this._target=t}get appendTo(){return this._appendTo||this.overlayOptions?.appendTo}set appendTo(t){this._appendTo=t}get autoZIndex(){const t=this._autoZIndex||this.overlayOptions?.autoZIndex;return void 0===t||t}set autoZIndex(t){this._autoZIndex=t}get baseZIndex(){const t=this._baseZIndex||this.overlayOptions?.baseZIndex;return void 0===t?0:t}set baseZIndex(t){this._baseZIndex=t}get showTransitionOptions(){const t=this._showTransitionOptions||this.overlayOptions?.showTransitionOptions;return void 0===t?".12s cubic-bezier(0, 0, 0.2, 1)":t}set showTransitionOptions(t){this._showTransitionOptions=t}get hideTransitionOptions(){const t=this._hideTransitionOptions||this.overlayOptions?.hideTransitionOptions;return void 0===t?".1s linear":t}set hideTransitionOptions(t){this._hideTransitionOptions=t}get listener(){return this._listener||this.overlayOptions?.listener}set listener(t){this._listener=t}get responsive(){return this._responsive||this.overlayOptions?.responsive}set responsive(t){this._responsive=t}get options(){return this._options}set options(t){this._options=t}visibleChange=new e.EventEmitter;onBeforeShow=new e.EventEmitter;onShow=new e.EventEmitter;onBeforeHide=new e.EventEmitter;onHide=new e.EventEmitter;onAnimationStart=new e.EventEmitter;onAnimationDone=new e.EventEmitter;templates;overlayViewChild;contentViewChild;contentTemplate;_visible=!1;_mode;_style;_styleClass;_contentStyle;_contentStyleClass;_target;_appendTo;_autoZIndex;_baseZIndex;_showTransitionOptions;_hideTransitionOptions;_listener;_responsive;_options;modalVisible=!1;isOverlayClicked=!1;isOverlayContentClicked=!1;scrollHandler;documentClickListener;documentResizeListener;documentKeyboardListener;window;transformOptions={default:"scaleY(0.8)",center:"scale(0.7)",top:"translate3d(0px, -100%, 0px)","top-start":"translate3d(0px, -100%, 0px)","top-end":"translate3d(0px, -100%, 0px)",bottom:"translate3d(0px, 100%, 0px)","bottom-start":"translate3d(0px, 100%, 0px)","bottom-end":"translate3d(0px, 100%, 0px)",left:"translate3d(-100%, 0px, 0px)","left-start":"translate3d(-100%, 0px, 0px)","left-end":"translate3d(-100%, 0px, 0px)",right:"translate3d(100%, 0px, 0px)","right-start":"translate3d(100%, 0px, 0px)","right-end":"translate3d(100%, 0px, 0px)"};get modal(){if((0,ve.isPlatformBrowser)(this.platformId))return"modal"===this.mode||this.overlayResponsiveOptions&&this.window?.matchMedia(this.overlayResponsiveOptions.media?.replace("@media","")||`(max-width: ${this.overlayResponsiveOptions.breakpoint})`).matches}get overlayMode(){return this.mode||(this.modal?"modal":"overlay")}get overlayOptions(){return{...this.config?.overlayOptions,...this.options}}get overlayResponsiveOptions(){return{...this.overlayOptions?.responsive,...this.responsive}}get overlayResponsiveDirection(){return this.overlayResponsiveOptions?.direction||"center"}get overlayEl(){return this.overlayViewChild?.nativeElement}get contentEl(){return this.contentViewChild?.nativeElement}get targetEl(){return xr.getTargetElement(this.target,this.el?.nativeElement)}constructor(t,n,o,f,D,j,fe,Ne){this.document=t,this.platformId=n,this.el=o,this.renderer=f,this.config=D,this.overlayService=j,this.cd=fe,this.zone=Ne,this.window=this.document.defaultView}ngAfterContentInit(){this.templates?.forEach(t=>{t.getType(),this.contentTemplate=t.template})}show(t,n=!1){this.onVisibleChange(!0),this.handleEvents("onShow",{overlay:t||this.overlayEl,target:this.targetEl,mode:this.overlayMode}),n&&xr.focus(this.targetEl),this.modal&&xr.addClass(this.document?.body,"p-overflow-hidden")}hide(t,n=!1){this.visible&&(this.onVisibleChange(!1),this.handleEvents("onHide",{overlay:t||this.overlayEl,target:this.targetEl,mode:this.overlayMode}),n&&xr.focus(this.targetEl),this.modal&&xr.removeClass(this.document?.body,"p-overflow-hidden"))}alignOverlay(){!this.modal&&xr.alignOverlay(this.overlayEl,this.targetEl,this.appendTo)}onVisibleChange(t){this._visible=t,this.visibleChange.emit(t)}onOverlayClick(){this.isOverlayClicked=!0}onOverlayContentClick(t){this.overlayService.add({originalEvent:t,target:this.targetEl}),this.isOverlayContentClicked=!0}onOverlayContentAnimationStart(t){switch(t.toState){case"visible":this.handleEvents("onBeforeShow",{overlay:this.overlayEl,target:this.targetEl,mode:this.overlayMode}),this.autoZIndex&&Uu.set(this.overlayMode,this.overlayEl,this.baseZIndex+this.config?.zIndex[this.overlayMode]),xr.appendOverlay(this.overlayEl,"body"===this.appendTo?this.document.body:this.appendTo,this.appendTo),this.alignOverlay();break;case"void":this.handleEvents("onBeforeHide",{overlay:this.overlayEl,target:this.targetEl,mode:this.overlayMode}),this.modal&&xr.addClass(this.overlayEl,"p-component-overlay-leave")}this.handleEvents("onAnimationStart",t)}onOverlayContentAnimationDone(t){const n=this.overlayEl||t.element.parentElement;switch(t.toState){case"visible":this.visible&&this.show(n,!0),this.bindListeners();break;case"void":if(!this.visible){this.hide(n,!0),this.modalVisible=!1,this.unbindListeners(),xr.appendOverlay(this.overlayEl,this.targetEl,this.appendTo),Uu.clear(n),this.cd.markForCheck();break}}this.handleEvents("onAnimationDone",t)}handleEvents(t,n){this[t].emit(n),this.options&&this.options[t]&&this.options[t](n),this.config?.overlayOptions&&(this.config?.overlayOptions)[t]&&(this.config?.overlayOptions)[t](n)}bindListeners(){this.unbindListeners(),this.bindScrollListener(),this.bindDocumentClickListener(),this.bindDocumentResizeListener(),this.bindDocumentKeyboardListener()}unbindListeners(){this.unbindScrollListener(),this.unbindDocumentClickListener(),this.unbindDocumentResizeListener(),this.unbindDocumentKeyboardListener()}bindScrollListener(){this.scrollHandler||(this.scrollHandler=new Dh(this.targetEl,t=>{(!this.listener||this.listener(t,{type:"scroll",mode:this.overlayMode,valid:!0}))&&this.hide(t,!0)})),this.scrollHandler.bindScrollListener()}unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()}bindDocumentClickListener(){this.documentClickListener||(this.documentClickListener=this.renderer.listen(this.document,"click",t=>{const o=!(this.targetEl&&(this.targetEl.isSameNode(t.target)||!this.isOverlayClicked&&this.targetEl.contains(t.target))||this.isOverlayContentClicked);(this.listener?this.listener(t,{type:"outside",mode:this.overlayMode,valid:3!==t.which&&o}):o)&&this.hide(t),this.isOverlayClicked=this.isOverlayContentClicked=!1}))}unbindDocumentClickListener(){this.documentClickListener&&(this.documentClickListener(),this.documentClickListener=null)}bindDocumentResizeListener(){this.documentResizeListener||(this.documentResizeListener=this.renderer.listen(this.window,"resize",t=>{(this.listener?this.listener(t,{type:"resize",mode:this.overlayMode,valid:!xr.isTouchDevice()}):!xr.isTouchDevice())&&this.hide(t,!0)}))}unbindDocumentResizeListener(){this.documentResizeListener&&(this.documentResizeListener(),this.documentResizeListener=null)}bindDocumentKeyboardListener(){this.documentKeyboardListener||this.zone.runOutsideAngular(()=>{this.documentKeyboardListener=this.renderer.listen(this.window,"keydown",t=>{!1!==this.overlayOptions.hideOnEscape&&"Escape"===t.code&&(this.listener?this.listener(t,{type:"keydown",mode:this.overlayMode,valid:!xr.isTouchDevice()}):!xr.isTouchDevice())&&this.zone.run(()=>{this.hide(t,!0)})})})}unbindDocumentKeyboardListener(){this.documentKeyboardListener&&(this.documentKeyboardListener(),this.documentKeyboardListener=null)}ngOnDestroy(){this.hide(this.overlayEl,!0),this.overlayEl&&(xr.appendOverlay(this.overlayEl,this.targetEl,this.appendTo),Uu.clear(this.overlayEl)),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.unbindListeners()}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.PLATFORM_ID),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(mf),e.\u0275\u0275directiveInject(xv),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(e.NgZone))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-overlay"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(D0,5),e.\u0275\u0275viewQuery($_,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.overlayViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.contentViewChild=f.first)}},hostAttrs:[1,"p-element"],inputs:{visible:"visible",mode:"mode",style:"style",styleClass:"styleClass",contentStyle:"contentStyle",contentStyleClass:"contentStyleClass",target:"target",appendTo:"appendTo",autoZIndex:"autoZIndex",baseZIndex:"baseZIndex",showTransitionOptions:"showTransitionOptions",hideTransitionOptions:"hideTransitionOptions",listener:"listener",responsive:"responsive",options:"options"},outputs:{visibleChange:"visibleChange",onBeforeShow:"onBeforeShow",onShow:"onShow",onBeforeHide:"onBeforeHide",onHide:"onHide",onAnimationStart:"onAnimationStart",onAnimationDone:"onAnimationDone"},features:[e.\u0275\u0275ProvidersFeature([Ev])],ngContentSelectors:Cg,decls:1,vars:1,consts:[["overlay",""],["content",""],[3,"ngStyle","class","ngClass","click",4,"ngIf"],[3,"click","ngStyle","ngClass"],[4,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275template(0,Xd,3,20,"div",2)),2&n&&e.\u0275\u0275property("ngIf",o.modalVisible)},dependencies:[ve.NgClass,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle],styles:["@layer primeng{.p-overlay{position:absolute;top:0;left:0}.p-overlay-modal{display:flex;align-items:center;justify-content:center;position:fixed;top:0;left:0;width:100%;height:100%}.p-overlay-content{transform-origin:inherit}.p-overlay-modal>.p-overlay-content{z-index:1;width:90%}.p-overlay-top{align-items:flex-start}.p-overlay-top-start{align-items:flex-start;justify-content:flex-start}.p-overlay-top-end{align-items:flex-start;justify-content:flex-end}.p-overlay-bottom{align-items:flex-end}.p-overlay-bottom-start{align-items:flex-end;justify-content:flex-start}.p-overlay-bottom-end{align-items:flex-end;justify-content:flex-end}.p-overlay-left{justify-content:flex-start}.p-overlay-left-start{justify-content:flex-start;align-items:flex-start}.p-overlay-left-end{justify-content:flex-start;align-items:flex-end}.p-overlay-right{justify-content:flex-end}.p-overlay-right-start{justify-content:flex-end;align-items:flex-start}.p-overlay-right-end{justify-content:flex-end;align-items:flex-end}}\n"],encapsulation:2,data:{animation:[(0,sr.trigger)("overlayContentAnimation",[(0,sr.transition)(":enter",[(0,sr.useAnimation)(sp)]),(0,sr.transition)(":leave",[(0,sr.useAnimation)(Ep)])])]},changeDetection:0})}return r})(),bc=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Tu,Tu]})}return r})(),Bs=(()=>{class r{document;platformId;renderer;el;zone;config;constructor(t,n,o,f,D,j){this.document=t,this.platformId=n,this.renderer=o,this.el=f,this.zone=D,this.config=j}animationListener;mouseDownListener;timeout;ngAfterViewInit(){(0,ve.isPlatformBrowser)(this.platformId)&&this.config&&this.config.ripple&&this.zone.runOutsideAngular(()=>{this.create(),this.mouseDownListener=this.renderer.listen(this.el.nativeElement,"mousedown",this.onMouseDown.bind(this))})}onMouseDown(t){let n=this.getInk();if(!n||"none"===this.document.defaultView?.getComputedStyle(n,null).display)return;if(xr.removeClass(n,"p-ink-active"),!xr.getHeight(n)&&!xr.getWidth(n)){let j=Math.max(xr.getOuterWidth(this.el.nativeElement),xr.getOuterHeight(this.el.nativeElement));n.style.height=j+"px",n.style.width=j+"px"}let o=xr.getOffset(this.el.nativeElement),f=t.pageX-o.left+this.document.body.scrollTop-xr.getWidth(n)/2,D=t.pageY-o.top+this.document.body.scrollLeft-xr.getHeight(n)/2;this.renderer.setStyle(n,"top",D+"px"),this.renderer.setStyle(n,"left",f+"px"),xr.addClass(n,"p-ink-active"),this.timeout=setTimeout(()=>{let j=this.getInk();j&&xr.removeClass(j,"p-ink-active")},401)}getInk(){const t=this.el.nativeElement.children;for(let n=0;n<t.length;n++)if("string"==typeof t[n].className&&-1!==t[n].className.indexOf("p-ink"))return t[n];return null}resetInk(){let t=this.getInk();t&&xr.removeClass(t,"p-ink-active")}onAnimationEnd(t){this.timeout&&clearTimeout(this.timeout),xr.removeClass(t.currentTarget,"p-ink-active")}create(){let t=this.renderer.createElement("span");this.renderer.addClass(t,"p-ink"),this.renderer.appendChild(this.el.nativeElement,t),this.renderer.setAttribute(t,"aria-hidden","true"),this.renderer.setAttribute(t,"role","presentation"),this.animationListener||(this.animationListener=this.renderer.listen(t,"animationend",this.onAnimationEnd.bind(this)))}remove(){let t=this.getInk();t&&(this.mouseDownListener&&this.mouseDownListener(),this.animationListener&&this.animationListener(),this.mouseDownListener=null,this.animationListener=null,xr.removeElement(t))}ngOnDestroy(){this.config&&this.config.ripple&&this.remove()}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.PLATFORM_ID),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(mf,8))};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pRipple",""]],hostAttrs:[1,"p-ripple","p-element"],standalone:!0})}return r})(),wh=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({})}return r})();const Om=["*"];let Wu=(()=>{class r{label;spin=!1;styleClass;role;ariaLabel;ariaHidden;ngOnInit(){this.getAttributes()}getAttributes(){const t=ro.isEmpty(this.label);this.role=t?void 0:"img",this.ariaLabel=t?void 0:this.label,this.ariaHidden=t}getClassNames(){return`p-icon ${this.styleClass?this.styleClass+" ":""}${this.spin?"p-icon-spin":""}`}static \u0275fac=function(n){return new(n||r)};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],hostAttrs:[1,"p-element","p-icon-wrapper"],inputs:{label:"label",spin:[2,"spin","spin",e.booleanAttribute],styleClass:"styleClass"},standalone:!0,features:[e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275StandaloneFeature],ngContentSelectors:Om,decls:1,vars:0,template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275projection(0))},encapsulation:2,changeDetection:0})}return r})(),zl=(()=>{class r extends Wu{pathId;ngOnInit(){this.pathId="url(#"+Sp()+")"}static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["SpinnerIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:6,vars:7,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M6.99701 14C5.85441 13.999 4.72939 13.7186 3.72012 13.1832C2.71084 12.6478 1.84795 11.8737 1.20673 10.9284C0.565504 9.98305 0.165424 8.89526 0.041387 7.75989C-0.0826496 6.62453 0.073125 5.47607 0.495122 4.4147C0.917119 3.35333 1.59252 2.4113 2.46241 1.67077C3.33229 0.930247 4.37024 0.413729 5.4857 0.166275C6.60117 -0.0811796 7.76026 -0.0520535 8.86188 0.251112C9.9635 0.554278 10.9742 1.12227 11.8057 1.90555C11.915 2.01493 11.9764 2.16319 11.9764 2.31778C11.9764 2.47236 11.915 2.62062 11.8057 2.73C11.7521 2.78503 11.688 2.82877 11.6171 2.85864C11.5463 2.8885 11.4702 2.90389 11.3933 2.90389C11.3165 2.90389 11.2404 2.8885 11.1695 2.85864C11.0987 2.82877 11.0346 2.78503 10.9809 2.73C9.9998 1.81273 8.73246 1.26138 7.39226 1.16876C6.05206 1.07615 4.72086 1.44794 3.62279 2.22152C2.52471 2.99511 1.72683 4.12325 1.36345 5.41602C1.00008 6.70879 1.09342 8.08723 1.62775 9.31926C2.16209 10.5513 3.10478 11.5617 4.29713 12.1803C5.48947 12.7989 6.85865 12.988 8.17414 12.7157C9.48963 12.4435 10.6711 11.7264 11.5196 10.6854C12.3681 9.64432 12.8319 8.34282 12.8328 7C12.8328 6.84529 12.8943 6.69692 13.0038 6.58752C13.1132 6.47812 13.2616 6.41667 13.4164 6.41667C13.5712 6.41667 13.7196 6.47812 13.8291 6.58752C13.9385 6.69692 14 6.84529 14 7C14 8.85651 13.2622 10.637 11.9489 11.9497C10.6356 13.2625 8.85432 14 6.99701 14Z","fill","currentColor"],[3,"id"],["width","14","height","14","fill","white"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0)(1,"g"),e.\u0275\u0275element(2,"path",1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"defs")(4,"clipPath",2),e.\u0275\u0275element(5,"rect",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role),e.\u0275\u0275advance(),e.\u0275\u0275attribute("clip-path",o.pathId),e.\u0275\u0275advance(3),e.\u0275\u0275property("id",o.pathId))},encapsulation:2})}return r})();const Tp=["element"],Mp=["content"],Zd=["*"],Fm=(r,v,t)=>({"p-scroller":!0,"p-scroller-inline":r,"p-both-scroll":v,"p-horizontal-scroll":t}),ap=(r,v)=>({$implicit:r,options:v}),Af=r=>({"p-scroller-loading":r}),_d=r=>({"p-component-overlay":r}),Mu=r=>({numCols:r}),Jd=r=>({options:r}),W_=()=>({styleClass:"p-scroller-loading-icon"}),Iu=(r,v)=>({rows:r,columns:v});function ns(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Hu(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,ns,1,0,"ng-container",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.contentTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(2,ap,t.loadedItems,t.getContentOptions()))}}function gf(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Zp(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,gf,1,0,"ng-container",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=v.index,o=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",o.itemTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(2,ap,t,o.getOptions(n)))}}function xh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",11,3),e.\u0275\u0275template(2,Zp,2,5,"ng-container",12),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(5,Af,t.d_loading))("ngStyle",t.contentStyle),e.\u0275\u0275attribute("data-pc-section","content"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.loadedItems)("ngForTrackBy",t._trackBy||t.index)}}function Tv(r,v){if(1&r&&e.\u0275\u0275element(0,"div",13),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngStyle",t.spacerStyle),e.\u0275\u0275attribute("data-pc-section","spacer")}}function Md(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Of(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Md,1,0,"ng-container",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.index,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n.loaderTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(4,Jd,n.getLoaderOptions(t,n.both&&e.\u0275\u0275pureFunction1(2,Mu,n._numItemsInViewport.cols))))}}function Qf(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Of,2,6,"ng-container",15),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.loaderArr)}}function w0(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function r1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,w0,1,0,"ng-container",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.loaderIconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(3,Jd,e.\u0275\u0275pureFunction0(2,W_)))}}function Ip(r,v){1&r&&e.\u0275\u0275element(0,"SpinnerIcon",16),2&r&&(e.\u0275\u0275property("styleClass","p-scroller-loading-icon pi-spin"),e.\u0275\u0275attribute("data-pc-section","loadingIcon"))}function Mv(r,v){if(1&r&&e.\u0275\u0275template(0,r1,2,5,"ng-container",6)(1,Ip,1,2,"ng-template",null,5,e.\u0275\u0275templateRefExtractor),2&r){const t=e.\u0275\u0275reference(2),n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngIf",n.loaderIconTemplate)("ngIfElse",t)}}function Xh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",14),e.\u0275\u0275template(1,Qf,2,1,"ng-container",6)(2,Mv,3,2,"ng-template",null,4,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275reference(3),n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(4,_d,!n.loaderTemplate)),e.\u0275\u0275attribute("data-pc-section","loader"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.loaderTemplate)("ngIfElse",t)}}function Nm(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",7,1),e.\u0275\u0275listener("scroll",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onContainerScroll(o))}),e.\u0275\u0275template(3,Hu,2,5,"ng-container",6)(4,xh,3,7,"ng-template",null,2,e.\u0275\u0275templateRefExtractor)(6,Tv,1,2,"div",8)(7,Xh,4,6,"div",9),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275reference(5),n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classMap(n._styleClass),e.\u0275\u0275property("ngStyle",n._style)("ngClass",e.\u0275\u0275pureFunction3(12,Fm,n.inline,n.both,n.horizontal)),e.\u0275\u0275attribute("id",n._id)("tabindex",n.tabindex)("data-pc-name","scroller")("data-pc-section","root"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.contentTemplate)("ngIfElse",t),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",n._showSpacer),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.loaderDisabled&&n._showLoader&&n.d_loading)}}function od(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function tD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,od,1,0,"ng-container",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.contentTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(5,ap,t.items,e.\u0275\u0275pureFunction2(2,Iu,t._items,t.loadedColumns)))}}function Iv(r,v){if(1&r&&(e.\u0275\u0275projection(0),e.\u0275\u0275template(1,tD,2,8,"ng-container",17)),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.contentTemplate)}}let mu=(()=>{class r{document;platformId;renderer;cd;zone;get id(){return this._id}set id(t){this._id=t}get style(){return this._style}set style(t){this._style=t}get styleClass(){return this._styleClass}set styleClass(t){this._styleClass=t}get tabindex(){return this._tabindex}set tabindex(t){this._tabindex=t}get items(){return this._items}set items(t){this._items=t}get itemSize(){return this._itemSize}set itemSize(t){this._itemSize=t}get scrollHeight(){return this._scrollHeight}set scrollHeight(t){this._scrollHeight=t}get scrollWidth(){return this._scrollWidth}set scrollWidth(t){this._scrollWidth=t}get orientation(){return this._orientation}set orientation(t){this._orientation=t}get step(){return this._step}set step(t){this._step=t}get delay(){return this._delay}set delay(t){this._delay=t}get resizeDelay(){return this._resizeDelay}set resizeDelay(t){this._resizeDelay=t}get appendOnly(){return this._appendOnly}set appendOnly(t){this._appendOnly=t}get inline(){return this._inline}set inline(t){this._inline=t}get lazy(){return this._lazy}set lazy(t){this._lazy=t}get disabled(){return this._disabled}set disabled(t){this._disabled=t}get loaderDisabled(){return this._loaderDisabled}set loaderDisabled(t){this._loaderDisabled=t}get columns(){return this._columns}set columns(t){this._columns=t}get showSpacer(){return this._showSpacer}set showSpacer(t){this._showSpacer=t}get showLoader(){return this._showLoader}set showLoader(t){this._showLoader=t}get numToleratedItems(){return this._numToleratedItems}set numToleratedItems(t){this._numToleratedItems=t}get loading(){return this._loading}set loading(t){this._loading=t}get autoSize(){return this._autoSize}set autoSize(t){this._autoSize=t}get trackBy(){return this._trackBy}set trackBy(t){this._trackBy=t}get options(){return this._options}set options(t){this._options=t,t&&"object"==typeof t&&Object.entries(t).forEach(([n,o])=>this[`_${n}`]!==o&&(this[`_${n}`]=o))}onLazyLoad=new e.EventEmitter;onScroll=new e.EventEmitter;onScrollIndexChange=new e.EventEmitter;elementViewChild;contentViewChild;templates;_id;_style;_styleClass;_tabindex=0;_items;_itemSize=0;_scrollHeight;_scrollWidth;_orientation="vertical";_step=0;_delay=0;_resizeDelay=10;_appendOnly=!1;_inline=!1;_lazy=!1;_disabled=!1;_loaderDisabled=!1;_columns;_showSpacer=!0;_showLoader=!1;_numToleratedItems;_loading;_autoSize=!1;_trackBy;_options;d_loading=!1;d_numToleratedItems;contentEl;contentTemplate;itemTemplate;loaderTemplate;loaderIconTemplate;first=0;last=0;page=0;isRangeChanged=!1;numItemsInViewport=0;lastScrollPos=0;lazyLoadState={};loaderArr=[];spacerStyle={};contentStyle={};scrollTimeout;resizeTimeout;initialized=!1;resizeObserver;defaultWidth;defaultHeight;defaultContentWidth;defaultContentHeight;get vertical(){return"vertical"===this._orientation}get horizontal(){return"horizontal"===this._orientation}get both(){return"both"===this._orientation}get loadedItems(){return this._items&&!this.d_loading?this.both?this._items.slice(this._appendOnly?0:this.first.rows,this.last.rows).map(t=>this._columns?t:t.slice(this._appendOnly?0:this.first.cols,this.last.cols)):this.horizontal&&this._columns?this._items:this._items.slice(this._appendOnly?0:this.first,this.last):[]}get loadedRows(){return this.d_loading?this._loaderDisabled?this.loaderArr:[]:this.loadedItems}get loadedColumns(){return this._columns&&(this.both||this.horizontal)?this.d_loading&&this._loaderDisabled?this.both?this.loaderArr[0]:this.loaderArr:this._columns.slice(this.both?this.first.cols:this.first,this.both?this.last.cols:this.last):this._columns}constructor(t,n,o,f,D){this.document=t,this.platformId=n,this.renderer=o,this.cd=f,this.zone=D}ngOnInit(){this.setInitialState()}ngOnChanges(t){let n=!1;if(t.loading){const{previousValue:o,currentValue:f}=t.loading;this.lazy&&o!==f&&f!==this.d_loading&&(this.d_loading=f,n=!0)}if(t.orientation&&(this.lastScrollPos=this.both?{top:0,left:0}:0),t.numToleratedItems){const{previousValue:o,currentValue:f}=t.numToleratedItems;o!==f&&f!==this.d_numToleratedItems&&(this.d_numToleratedItems=f)}if(t.options){const{previousValue:o,currentValue:f}=t.options;this.lazy&&o?.loading!==f?.loading&&f?.loading!==this.d_loading&&(this.d_loading=f.loading,n=!0),o?.numToleratedItems!==f?.numToleratedItems&&f?.numToleratedItems!==this.d_numToleratedItems&&(this.d_numToleratedItems=f.numToleratedItems)}this.initialized&&!n&&(t.items?.previousValue?.length!==t.items?.currentValue?.length||t.itemSize||t.scrollHeight||t.scrollWidth)&&(this.init(),this.calculateAutoSize())}ngAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"content":this.contentTemplate=t.template;break;case"item":default:this.itemTemplate=t.template;break;case"loader":this.loaderTemplate=t.template;break;case"loadericon":this.loaderIconTemplate=t.template}})}ngAfterViewInit(){Promise.resolve().then(()=>{this.viewInit()})}ngAfterViewChecked(){this.initialized||this.viewInit()}ngOnDestroy(){this.unbindResizeListener(),this.contentEl=null,this.initialized=!1}viewInit(){(0,ve.isPlatformBrowser)(this.platformId)&&!this.initialized&&xr.isVisible(this.elementViewChild?.nativeElement)&&(this.setInitialState(),this.setContentEl(this.contentEl),this.init(),this.calculateAutoSize(),this.defaultWidth=xr.getWidth(this.elementViewChild?.nativeElement),this.defaultHeight=xr.getHeight(this.elementViewChild?.nativeElement),this.defaultContentWidth=xr.getWidth(this.contentEl),this.defaultContentHeight=xr.getHeight(this.contentEl),this.resizeObserver=new ResizeObserver(()=>this.onResize()),this.resizeObserver.observe(this.elementViewChild?.nativeElement),this.initialized=!0)}init(){this._disabled||(this.setSize(),this.calculateOptions(),this.setSpacerSize(),this.cd.detectChanges())}setContentEl(t){this.contentEl=t||this.contentViewChild?.nativeElement||xr.findSingle(this.elementViewChild?.nativeElement,".p-scroller-content")}setInitialState(){this.first=this.both?{rows:0,cols:0}:0,this.last=this.both?{rows:0,cols:0}:0,this.numItemsInViewport=this.both?{rows:0,cols:0}:0,this.lastScrollPos=this.both?{top:0,left:0}:0,this.d_loading=this._loading||!1,this.d_numToleratedItems=this._numToleratedItems,this.loaderArr=[],this.spacerStyle={},this.contentStyle={}}getElementRef(){return this.elementViewChild}getPageByFirst(t){return Math.floor(((t??this.first)+4*this.d_numToleratedItems)/(this._step||1))}isPageChanged(t){return!this._step||this.page!==this.getPageByFirst(t??this.first)}scrollTo(t){this.elementViewChild?.nativeElement?.scrollTo(t)}scrollToIndex(t,n="auto"){if(this.both?t.every(f=>f>-1):t>-1){const f=this.first,{scrollTop:D=0,scrollLeft:j=0}=this.elementViewChild?.nativeElement,{numToleratedItems:fe}=this.calculateNumItems(),Ne=this.getContentPosition(),vt=this.itemSize,ln=(ss=0,Rs)=>ss<=Rs?0:ss,Hn=(ss,Rs,Us)=>ss*Rs+Us,Oi=(ss=0,Rs=0)=>this.scrollTo({left:ss,top:Rs,behavior:n});let Lr=this.both?{rows:0,cols:0}:0,to=!1,Mr=!1;this.both?(Lr={rows:ln(t[0],fe[0]),cols:ln(t[1],fe[1])},Oi(Hn(Lr.cols,vt[1],Ne.left),Hn(Lr.rows,vt[0],Ne.top)),Mr=this.lastScrollPos.top!==D||this.lastScrollPos.left!==j,to=Lr.rows!==f.rows||Lr.cols!==f.cols):(Lr=ln(t,fe),this.horizontal?Oi(Hn(Lr,vt,Ne.left),D):Oi(j,Hn(Lr,vt,Ne.top)),Mr=this.lastScrollPos!==(this.horizontal?j:D),to=Lr!==f),this.isRangeChanged=to,Mr&&(this.first=Lr)}}scrollInView(t,n,o="auto"){if(n){const{first:f,viewport:D}=this.getRenderedRange(),j=(vt=0,ln=0)=>this.scrollTo({left:vt,top:ln,behavior:o}),Ne="to-end"===n;if("to-start"===n){if(this.both)D.first.rows-f.rows>t[0]?j(D.first.cols*this._itemSize[1],(D.first.rows-1)*this._itemSize[0]):D.first.cols-f.cols>t[1]&&j((D.first.cols-1)*this._itemSize[1],D.first.rows*this._itemSize[0]);else if(D.first-f>t){const vt=(D.first-1)*this._itemSize;this.horizontal?j(vt,0):j(0,vt)}}else if(Ne)if(this.both)D.last.rows-f.rows<=t[0]+1?j(D.first.cols*this._itemSize[1],(D.first.rows+1)*this._itemSize[0]):D.last.cols-f.cols<=t[1]+1&&j((D.first.cols+1)*this._itemSize[1],D.first.rows*this._itemSize[0]);else if(D.last-f<=t+1){const vt=(D.first+1)*this._itemSize;this.horizontal?j(vt,0):j(0,vt)}}else this.scrollToIndex(t,o)}getRenderedRange(){const t=(f,D)=>D||f?Math.floor(f/(D||f)):0;let n=this.first,o=0;if(this.elementViewChild?.nativeElement){const{scrollTop:f,scrollLeft:D}=this.elementViewChild.nativeElement;this.both?(n={rows:t(f,this._itemSize[0]),cols:t(D,this._itemSize[1])},o={rows:n.rows+this.numItemsInViewport.rows,cols:n.cols+this.numItemsInViewport.cols}):(n=t(this.horizontal?D:f,this._itemSize),o=n+this.numItemsInViewport)}return{first:this.first,last:this.last,viewport:{first:n,last:o}}}calculateNumItems(){const t=this.getContentPosition(),n=(this.elementViewChild?.nativeElement?this.elementViewChild.nativeElement.offsetWidth-t.left:0)||0,o=(this.elementViewChild?.nativeElement?this.elementViewChild.nativeElement.offsetHeight-t.top:0)||0,f=(Ne,vt)=>vt||Ne?Math.ceil(Ne/(vt||Ne)):0,D=Ne=>Math.ceil(Ne/2),j=this.both?{rows:f(o,this._itemSize[0]),cols:f(n,this._itemSize[1])}:f(this.horizontal?n:o,this._itemSize);return{numItemsInViewport:j,numToleratedItems:this.d_numToleratedItems||(this.both?[D(j.rows),D(j.cols)]:D(j))}}calculateOptions(){const{numItemsInViewport:t,numToleratedItems:n}=this.calculateNumItems(),o=(j,fe,Ne,vt=!1)=>this.getLast(j+fe+(j<Ne?2:3)*Ne,vt),f=this.first,D=this.both?{rows:o(this.first.rows,t.rows,n[0]),cols:o(this.first.cols,t.cols,n[1],!0)}:o(this.first,t,n);this.last=D,this.numItemsInViewport=t,this.d_numToleratedItems=n,this.showLoader&&(this.loaderArr=this.both?Array.from({length:t.rows}).map(()=>Array.from({length:t.cols})):Array.from({length:t})),this._lazy&&Promise.resolve().then(()=>{this.lazyLoadState={first:this._step?this.both?{rows:0,cols:f.cols}:0:f,last:Math.min(this._step?this._step:this.last,this.items.length)},this.handleEvents("onLazyLoad",this.lazyLoadState)})}calculateAutoSize(){this._autoSize&&!this.d_loading&&Promise.resolve().then(()=>{if(this.contentEl){this.contentEl.style.minHeight=this.contentEl.style.minWidth="auto",this.contentEl.style.position="relative",this.elementViewChild.nativeElement.style.contain="none";const[t,n]=[xr.getWidth(this.contentEl),xr.getHeight(this.contentEl)];t!==this.defaultContentWidth&&(this.elementViewChild.nativeElement.style.width=""),n!==this.defaultContentHeight&&(this.elementViewChild.nativeElement.style.height="");const[o,f]=[xr.getWidth(this.elementViewChild.nativeElement),xr.getHeight(this.elementViewChild.nativeElement)];(this.both||this.horizontal)&&(this.elementViewChild.nativeElement.style.width=o<this.defaultWidth?o+"px":this._scrollWidth||this.defaultWidth+"px"),(this.both||this.vertical)&&(this.elementViewChild.nativeElement.style.height=f<this.defaultHeight?f+"px":this._scrollHeight||this.defaultHeight+"px"),this.contentEl.style.minHeight=this.contentEl.style.minWidth="",this.contentEl.style.position="",this.elementViewChild.nativeElement.style.contain=""}})}getLast(t=0,n=!1){return this._items?Math.min(n?(this._columns||this._items[0]).length:this._items.length,t):0}getContentPosition(){if(this.contentEl){const t=getComputedStyle(this.contentEl),n=parseFloat(t.paddingLeft)+Math.max(parseFloat(t.left)||0,0),o=parseFloat(t.paddingRight)+Math.max(parseFloat(t.right)||0,0),f=parseFloat(t.paddingTop)+Math.max(parseFloat(t.top)||0,0),D=parseFloat(t.paddingBottom)+Math.max(parseFloat(t.bottom)||0,0);return{left:n,right:o,top:f,bottom:D,x:n+o,y:f+D}}return{left:0,right:0,top:0,bottom:0,x:0,y:0}}setSize(){if(this.elementViewChild?.nativeElement){const t=this.elementViewChild.nativeElement.parentElement.parentElement,n=this._scrollWidth||`${this.elementViewChild.nativeElement.offsetWidth||t.offsetWidth}px`,o=this._scrollHeight||`${this.elementViewChild.nativeElement.offsetHeight||t.offsetHeight}px`,f=(D,j)=>this.elementViewChild.nativeElement.style[D]=j;this.both||this.horizontal?(f("height",o),f("width",n)):f("height",o)}}setSpacerSize(){if(this._items){const t=(o,f,D)=>this.spacerStyle={...this.spacerStyle,[`${o}`]:f*D+"px"},n=this._items.length;this.both?(t("height",n,this._itemSize[0]),t("width",this._columns?.length||this._items[1]?.length,this._itemSize[1])):this.horizontal?t("width",this._columns.length||this._items.length,this._itemSize):t("height",n,this._itemSize)}}setContentPosition(t){if(this.contentEl&&!this._appendOnly){const n=t?t.first:this.first,o=(D,j)=>D*j,f=(D=0,j=0)=>this.contentStyle={...this.contentStyle,transform:`translate3d(${D}px, ${j}px, 0)`};if(this.both)f(o(n.cols,this._itemSize[1]),o(n.rows,this._itemSize[0]));else{const D=o(n,this._itemSize);this.horizontal?f(D,0):f(0,D)}}}onScrollPositionChange(t){const n=t.target,o=this.getContentPosition(),f=(Mr,ss)=>Mr?Mr>ss?Mr-ss:Mr:0,D=(Mr,ss)=>ss||Mr?Math.floor(Mr/(ss||Mr)):0,j=(Mr,ss,Rs,Us,wu,Tf)=>Mr<=wu?wu:Tf?Rs-Us-wu:ss+wu-1,fe=(Mr,ss,Rs,Us,wu,Tf,vM)=>Mr<=Tf?0:Math.max(0,vM?Mr<ss?Rs:Mr-Tf:Mr>ss?Rs:Mr-2*Tf),Ne=(Mr,ss,Rs,Us,wu,Tf=!1)=>{let vM=ss+Us+2*wu;return Mr>=wu&&(vM+=wu+1),this.getLast(vM,Tf)},vt=f(n.scrollTop,o.top),ln=f(n.scrollLeft,o.left);let Hn=this.both?{rows:0,cols:0}:0,Oi=this.last,Lr=!1,to=this.lastScrollPos;if(this.both){const Mr=this.lastScrollPos.top<=vt,ss=this.lastScrollPos.left<=ln;if(!this._appendOnly||this._appendOnly&&(Mr||ss)){const Rs={rows:D(vt,this._itemSize[0]),cols:D(ln,this._itemSize[1])},Us={rows:j(Rs.rows,this.first.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0],Mr),cols:j(Rs.cols,this.first.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],ss)};Hn={rows:fe(Rs.rows,Us.rows,this.first.rows,0,0,this.d_numToleratedItems[0],Mr),cols:fe(Rs.cols,Us.cols,this.first.cols,0,0,this.d_numToleratedItems[1],ss)},Oi={rows:Ne(Rs.rows,Hn.rows,0,this.numItemsInViewport.rows,this.d_numToleratedItems[0]),cols:Ne(Rs.cols,Hn.cols,0,this.numItemsInViewport.cols,this.d_numToleratedItems[1],!0)},Lr=Hn.rows!==this.first.rows||Oi.rows!==this.last.rows||Hn.cols!==this.first.cols||Oi.cols!==this.last.cols||this.isRangeChanged,to={top:vt,left:ln}}}else{const Mr=this.horizontal?ln:vt,ss=this.lastScrollPos<=Mr;if(!this._appendOnly||this._appendOnly&&ss){const Rs=D(Mr,this._itemSize);Hn=fe(Rs,j(Rs,this.first,this.last,this.numItemsInViewport,this.d_numToleratedItems,ss),this.first,0,0,this.d_numToleratedItems,ss),Oi=Ne(Rs,Hn,0,this.numItemsInViewport,this.d_numToleratedItems),Lr=Hn!==this.first||Oi!==this.last||this.isRangeChanged,to=Mr}}return{first:Hn,last:Oi,isRangeChanged:Lr,scrollPos:to}}onScrollChange(t){const{first:n,last:o,isRangeChanged:f,scrollPos:D}=this.onScrollPositionChange(t);if(f){const j={first:n,last:o};if(this.setContentPosition(j),this.first=n,this.last=o,this.lastScrollPos=D,this.handleEvents("onScrollIndexChange",j),this._lazy&&this.isPageChanged(n)){const fe={first:this._step?Math.min(this.getPageByFirst(n)*this._step,this.items.length-this._step):n,last:Math.min(this._step?(this.getPageByFirst(n)+1)*this._step:o,this.items.length)};(this.lazyLoadState.first!==fe.first||this.lazyLoadState.last!==fe.last)&&this.handleEvents("onLazyLoad",fe),this.lazyLoadState=fe}}}onContainerScroll(t){if(this.handleEvents("onScroll",{originalEvent:t}),this._delay&&this.isPageChanged()){if(this.scrollTimeout&&clearTimeout(this.scrollTimeout),!this.d_loading&&this.showLoader){const{isRangeChanged:n}=this.onScrollPositionChange(t);(n||this._step&&this.isPageChanged())&&(this.d_loading=!0,this.cd.detectChanges())}this.scrollTimeout=setTimeout(()=>{this.onScrollChange(t),this.d_loading&&this.showLoader&&(!this._lazy||void 0===this._loading)&&(this.d_loading=!1,this.page=this.getPageByFirst(),this.cd.detectChanges())},this._delay)}else!this.d_loading&&this.onScrollChange(t)}unbindResizeListener(){this.resizeObserver&&(this.resizeObserver.unobserve(this.elementViewChild?.nativeElement),this.resizeObserver=null)}onResize(){this.resizeTimeout&&clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(()=>{if(xr.isVisible(this.elementViewChild?.nativeElement)){const[t,n]=[xr.getWidth(this.elementViewChild?.nativeElement),xr.getHeight(this.elementViewChild?.nativeElement)],[o,f]=[t!==this.defaultWidth,n!==this.defaultHeight];(this.both?o||f:this.horizontal?o:this.vertical&&f)&&this.zone.run(()=>{this.d_numToleratedItems=this._numToleratedItems,this.defaultWidth=t,this.defaultHeight=n,this.defaultContentWidth=xr.getWidth(this.contentEl),this.defaultContentHeight=xr.getHeight(this.contentEl),this.init(),this.calculateAutoSize()})}},this._resizeDelay)}handleEvents(t,n){return this.options&&this.options[t]?this.options[t](n):this[t].emit(n)}getContentOptions(){return{contentStyleClass:"p-scroller-content "+(this.d_loading?"p-scroller-loading":""),items:this.loadedItems,getItemOptions:t=>this.getOptions(t),loading:this.d_loading,getLoaderOptions:(t,n)=>this.getLoaderOptions(t,n),itemSize:this._itemSize,rows:this.loadedRows,columns:this.loadedColumns,spacerStyle:this.spacerStyle,contentStyle:this.contentStyle,vertical:this.vertical,horizontal:this.horizontal,both:this.both}}getOptions(t){const n=(this._items||[]).length,o=this.both?this.first.rows+t:this.first+t;return{index:o,count:n,first:0===o,last:o===n-1,even:o%2==0,odd:o%2!=0}}getLoaderOptions(t,n){const o=this.loaderArr.length;return{index:t,count:o,first:0===t,last:t===o-1,even:t%2==0,odd:t%2!=0,...n}}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.PLATFORM_ID),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(e.NgZone))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-scroller"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(Tp,5),e.\u0275\u0275viewQuery(Mp,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.elementViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.contentViewChild=f.first)}},hostAttrs:[1,"p-scroller-viewport","p-element"],inputs:{id:"id",style:"style",styleClass:"styleClass",tabindex:"tabindex",items:"items",itemSize:"itemSize",scrollHeight:"scrollHeight",scrollWidth:"scrollWidth",orientation:"orientation",step:"step",delay:"delay",resizeDelay:"resizeDelay",appendOnly:"appendOnly",inline:"inline",lazy:"lazy",disabled:"disabled",loaderDisabled:"loaderDisabled",columns:"columns",showSpacer:"showSpacer",showLoader:"showLoader",numToleratedItems:"numToleratedItems",loading:"loading",autoSize:"autoSize",trackBy:"trackBy",options:"options"},outputs:{onLazyLoad:"onLazyLoad",onScroll:"onScroll",onScrollIndexChange:"onScrollIndexChange"},features:[e.\u0275\u0275NgOnChangesFeature],ngContentSelectors:Zd,decls:3,vars:2,consts:[["disabledContainer",""],["element",""],["buildInContent",""],["content",""],["buildInLoader",""],["buildInLoaderIcon",""],[4,"ngIf","ngIfElse"],[3,"scroll","ngStyle","ngClass"],["class","p-scroller-spacer",3,"ngStyle",4,"ngIf"],["class","p-scroller-loader",3,"ngClass",4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"p-scroller-content",3,"ngClass","ngStyle"],[4,"ngFor","ngForOf","ngForTrackBy"],[1,"p-scroller-spacer",3,"ngStyle"],[1,"p-scroller-loader",3,"ngClass"],[4,"ngFor","ngForOf"],[3,"styleClass"],[4,"ngIf"]],template:function(n,o){if(1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275template(0,Nm,8,16,"ng-container",6)(1,Iv,2,1,"ng-template",null,0,e.\u0275\u0275templateRefExtractor)),2&n){const f=e.\u0275\u0275reference(2);e.\u0275\u0275property("ngIf",!o._disabled)("ngIfElse",f)}},dependencies:()=>[ve.NgClass,ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,zl],styles:["@layer primeng{p-scroller{flex:1;outline:0 none}.p-scroller{position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;outline:0 none}.p-scroller-content{position:absolute;top:0;left:0;min-height:100%;min-width:100%;will-change:transform}.p-scroller-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0;pointer-events:none}.p-scroller-loader{position:sticky;top:0;left:0;width:100%;height:100%}.p-scroller-loader.p-component-overlay{display:flex;align-items:center;justify-content:center}.p-scroller-loading-icon{scale:2}.p-scroller-inline .p-scroller-content{position:static}}\n"],encapsulation:2})}return r})(),Zh=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Tu,zl,Tu]})}return r})(),H_=(()=>{class r{platformId;el;zone;config;renderer;viewContainer;tooltipPosition;tooltipEvent="hover";appendTo;positionStyle;tooltipStyleClass;tooltipZIndex;escape=!0;showDelay;hideDelay;life;positionTop;positionLeft;autoHide=!0;fitContent=!0;hideOnEscape=!0;content;get disabled(){return this._disabled}set disabled(t){this._disabled=t,this.deactivate()}tooltipOptions;_tooltipOptions={tooltipLabel:null,tooltipPosition:"right",tooltipEvent:"hover",appendTo:"body",positionStyle:null,tooltipStyleClass:null,tooltipZIndex:"auto",escape:!0,disabled:null,showDelay:null,hideDelay:null,positionTop:null,positionLeft:null,life:null,autoHide:!0,hideOnEscape:!0,id:Sp()+"_tooltip"};_disabled;container;styleClass;tooltipText;showTimeout;hideTimeout;active;mouseEnterListener;mouseLeaveListener;containerMouseleaveListener;clickListener;focusListener;blurListener;scrollHandler;resizeListener;interactionInProgress=!1;constructor(t,n,o,f,D,j){this.platformId=t,this.el=n,this.zone=o,this.config=f,this.renderer=D,this.viewContainer=j}ngAfterViewInit(){(0,ve.isPlatformBrowser)(this.platformId)&&this.zone.runOutsideAngular(()=>{const t=this.getOption("tooltipEvent");if(("hover"===t||"both"===t)&&(this.mouseEnterListener=this.onMouseEnter.bind(this),this.mouseLeaveListener=this.onMouseLeave.bind(this),this.clickListener=this.onInputClick.bind(this),this.el.nativeElement.addEventListener("mouseenter",this.mouseEnterListener),this.el.nativeElement.addEventListener("click",this.clickListener),this.el.nativeElement.addEventListener("mouseleave",this.mouseLeaveListener)),"focus"===t||"both"===t){this.focusListener=this.onFocus.bind(this),this.blurListener=this.onBlur.bind(this);let n=this.el.nativeElement.querySelector(".p-component");n||(n=this.getTarget(this.el.nativeElement)),n.addEventListener("focus",this.focusListener),n.addEventListener("blur",this.blurListener)}})}ngOnChanges(t){t.tooltipPosition&&this.setOption({tooltipPosition:t.tooltipPosition.currentValue}),t.tooltipEvent&&this.setOption({tooltipEvent:t.tooltipEvent.currentValue}),t.appendTo&&this.setOption({appendTo:t.appendTo.currentValue}),t.positionStyle&&this.setOption({positionStyle:t.positionStyle.currentValue}),t.tooltipStyleClass&&this.setOption({tooltipStyleClass:t.tooltipStyleClass.currentValue}),t.tooltipZIndex&&this.setOption({tooltipZIndex:t.tooltipZIndex.currentValue}),t.escape&&this.setOption({escape:t.escape.currentValue}),t.showDelay&&this.setOption({showDelay:t.showDelay.currentValue}),t.hideDelay&&this.setOption({hideDelay:t.hideDelay.currentValue}),t.life&&this.setOption({life:t.life.currentValue}),t.positionTop&&this.setOption({positionTop:t.positionTop.currentValue}),t.positionLeft&&this.setOption({positionLeft:t.positionLeft.currentValue}),t.disabled&&this.setOption({disabled:t.disabled.currentValue}),t.content&&(this.setOption({tooltipLabel:t.content.currentValue}),this.active&&(t.content.currentValue?this.container&&this.container.offsetParent?(this.updateText(),this.align()):this.show():this.hide())),t.autoHide&&this.setOption({autoHide:t.autoHide.currentValue}),t.id&&this.setOption({id:t.id.currentValue}),t.tooltipOptions&&(this._tooltipOptions={...this._tooltipOptions,...t.tooltipOptions.currentValue},this.deactivate(),this.active&&(this.getOption("tooltipLabel")?this.container&&this.container.offsetParent?(this.updateText(),this.align()):this.show():this.hide()))}isAutoHide(){return this.getOption("autoHide")}onMouseEnter(t){!this.container&&!this.showTimeout&&this.activate()}onMouseLeave(t){(this.isAutoHide()||!(xr.hasClass(t.relatedTarget,"p-tooltip")||xr.hasClass(t.relatedTarget,"p-tooltip-text")||xr.hasClass(t.relatedTarget,"p-tooltip-arrow")))&&this.deactivate()}onFocus(t){this.activate()}onBlur(t){this.deactivate()}onInputClick(t){this.deactivate()}onPressEscape(){this.hideOnEscape&&this.deactivate()}activate(){if(!this.interactionInProgress&&(this.active=!0,this.clearHideTimeout(),this.getOption("showDelay")?this.showTimeout=setTimeout(()=>{this.show()},this.getOption("showDelay")):this.show(),this.getOption("life"))){let t=this.getOption("showDelay")?this.getOption("life")+this.getOption("showDelay"):this.getOption("life");this.hideTimeout=setTimeout(()=>{this.hide()},t)}this.interactionInProgress=!0}deactivate(){this.interactionInProgress=!1,this.active=!1,this.clearShowTimeout(),this.getOption("hideDelay")?(this.clearHideTimeout(),this.hideTimeout=setTimeout(()=>{this.hide()},this.getOption("hideDelay"))):this.hide()}create(){this.container&&(this.clearHideTimeout(),this.remove()),this.container=document.createElement("div"),this.container.setAttribute("id",this.getOption("id")),this.container.setAttribute("role","tooltip");let t=document.createElement("div");t.className="p-tooltip-arrow",this.container.appendChild(t),this.tooltipText=document.createElement("div"),this.tooltipText.className="p-tooltip-text",this.updateText(),this.getOption("positionStyle")&&(this.container.style.position=this.getOption("positionStyle")),this.container.appendChild(this.tooltipText),"body"===this.getOption("appendTo")?document.body.appendChild(this.container):"target"===this.getOption("appendTo")?xr.appendChild(this.container,this.el.nativeElement):xr.appendChild(this.container,this.getOption("appendTo")),this.container.style.display="inline-block",this.fitContent&&(this.container.style.width="fit-content"),this.isAutoHide()?this.container.style.pointerEvents="none":(this.container.style.pointerEvents="unset",this.bindContainerMouseleaveListener())}bindContainerMouseleaveListener(){this.containerMouseleaveListener||(this.containerMouseleaveListener=this.renderer.listen(this.container??this.container.nativeElement,"mouseleave",n=>{this.deactivate()}))}unbindContainerMouseleaveListener(){this.containerMouseleaveListener&&(this.bindContainerMouseleaveListener(),this.containerMouseleaveListener=null)}show(){this.getOption("tooltipLabel")&&!this.getOption("disabled")&&(this.create(),this.el.nativeElement.closest("p-dialog")?setTimeout(()=>{this.container&&this.align()},100):this.align(),xr.fadeIn(this.container,250),"auto"===this.getOption("tooltipZIndex")?Uu.set("tooltip",this.container,this.config.zIndex.tooltip):this.container.style.zIndex=this.getOption("tooltipZIndex"),this.bindDocumentResizeListener(),this.bindScrollListener())}hide(){"auto"===this.getOption("tooltipZIndex")&&Uu.clear(this.container),this.remove()}updateText(){const t=this.getOption("tooltipLabel");if(t instanceof e.TemplateRef){const n=this.viewContainer.createEmbeddedView(t);n.detectChanges(),n.rootNodes.forEach(o=>this.tooltipText.appendChild(o))}else this.getOption("escape")?(this.tooltipText.innerHTML="",this.tooltipText.appendChild(document.createTextNode(t))):this.tooltipText.innerHTML=t}align(){switch(this.getOption("tooltipPosition")){case"top":this.alignTop(),this.isOutOfBounds()&&(this.alignBottom(),this.isOutOfBounds()&&(this.alignRight(),this.isOutOfBounds()&&this.alignLeft()));break;case"bottom":this.alignBottom(),this.isOutOfBounds()&&(this.alignTop(),this.isOutOfBounds()&&(this.alignRight(),this.isOutOfBounds()&&this.alignLeft()));break;case"left":this.alignLeft(),this.isOutOfBounds()&&(this.alignRight(),this.isOutOfBounds()&&(this.alignTop(),this.isOutOfBounds()&&this.alignBottom()));break;case"right":this.alignRight(),this.isOutOfBounds()&&(this.alignLeft(),this.isOutOfBounds()&&(this.alignTop(),this.isOutOfBounds()&&this.alignBottom()))}}getHostOffset(){if("body"===this.getOption("appendTo")||"target"===this.getOption("appendTo")){let t=this.el.nativeElement.getBoundingClientRect();return{left:t.left+xr.getWindowScrollLeft(),top:t.top+xr.getWindowScrollTop()}}return{left:0,top:0}}alignRight(){this.preAlign("right");const t=this.activeElement,n=this.getHostOffset(),o=n.left+xr.getOuterWidth(t),f=n.top+(xr.getOuterHeight(t)-xr.getOuterHeight(this.container))/2;this.container.style.left=o+this.getOption("positionLeft")+"px",this.container.style.top=f+this.getOption("positionTop")+"px"}get activeElement(){return this.el.nativeElement.nodeName.includes("P-")&&xr.findSingle(this.el.nativeElement,".p-component")||this.el.nativeElement}alignLeft(){this.preAlign("left");let t=this.getHostOffset(),n=t.left-xr.getOuterWidth(this.container),o=t.top+(xr.getOuterHeight(this.el.nativeElement)-xr.getOuterHeight(this.container))/2;this.container.style.left=n+this.getOption("positionLeft")+"px",this.container.style.top=o+this.getOption("positionTop")+"px"}alignTop(){this.preAlign("top");let t=this.getHostOffset(),n=t.left+(xr.getOuterWidth(this.el.nativeElement)-xr.getOuterWidth(this.container))/2,o=t.top-xr.getOuterHeight(this.container);this.container.style.left=n+this.getOption("positionLeft")+"px",this.container.style.top=o+this.getOption("positionTop")+"px"}alignBottom(){this.preAlign("bottom");let t=this.getHostOffset(),n=t.left+(xr.getOuterWidth(this.el.nativeElement)-xr.getOuterWidth(this.container))/2,o=t.top+xr.getOuterHeight(this.el.nativeElement);this.container.style.left=n+this.getOption("positionLeft")+"px",this.container.style.top=o+this.getOption("positionTop")+"px"}setOption(t){this._tooltipOptions={...this._tooltipOptions,...t}}getOption(t){return this._tooltipOptions[t]}getTarget(t){return xr.hasClass(t,"p-inputwrapper")?xr.findSingle(t,"input"):t}preAlign(t){this.container.style.left="-999px",this.container.style.top="-999px";let n="p-tooltip p-component p-tooltip-"+t;this.container.className=this.getOption("tooltipStyleClass")?n+" "+this.getOption("tooltipStyleClass"):n}isOutOfBounds(){let t=this.container.getBoundingClientRect(),n=t.top,o=t.left,f=xr.getOuterWidth(this.container),D=xr.getOuterHeight(this.container),j=xr.getViewport();return o+f>j.width||o<0||n<0||n+D>j.height}onWindowResize(t){this.hide()}bindDocumentResizeListener(){this.zone.runOutsideAngular(()=>{this.resizeListener=this.onWindowResize.bind(this),window.addEventListener("resize",this.resizeListener)})}unbindDocumentResizeListener(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)}bindScrollListener(){this.scrollHandler||(this.scrollHandler=new Dh(this.el.nativeElement,()=>{this.container&&this.hide()})),this.scrollHandler.bindScrollListener()}unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()}unbindEvents(){const t=this.getOption("tooltipEvent");if(("hover"===t||"both"===t)&&(this.el.nativeElement.removeEventListener("mouseenter",this.mouseEnterListener),this.el.nativeElement.removeEventListener("mouseleave",this.mouseLeaveListener),this.el.nativeElement.removeEventListener("click",this.clickListener)),"focus"===t||"both"===t){let n=this.el.nativeElement.querySelector(".p-component");n||(n=this.getTarget(this.el.nativeElement))}this.unbindDocumentResizeListener()}remove(){this.container&&this.container.parentElement&&("body"===this.getOption("appendTo")?document.body.removeChild(this.container):"target"===this.getOption("appendTo")?this.el.nativeElement.removeChild(this.container):xr.removeChild(this.container,this.getOption("appendTo"))),this.unbindDocumentResizeListener(),this.unbindScrollListener(),this.unbindContainerMouseleaveListener(),this.clearTimeouts(),this.container=null,this.scrollHandler=null}clearShowTimeout(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=null)}clearHideTimeout(){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=null)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout()}ngOnDestroy(){this.unbindEvents(),this.container&&Uu.clear(this.container),this.remove(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null)}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.PLATFORM_ID),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(mf),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ViewContainerRef))};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pTooltip",""]],hostAttrs:[1,"p-element"],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keydown.escape",function(D){return o.onPressEscape(D)},!1,e.\u0275\u0275resolveDocument)},inputs:{tooltipPosition:"tooltipPosition",tooltipEvent:"tooltipEvent",appendTo:"appendTo",positionStyle:"positionStyle",tooltipStyleClass:"tooltipStyleClass",tooltipZIndex:"tooltipZIndex",escape:[2,"escape","escape",e.booleanAttribute],showDelay:[2,"showDelay","showDelay",e.numberAttribute],hideDelay:[2,"hideDelay","hideDelay",e.numberAttribute],life:[2,"life","life",e.numberAttribute],positionTop:[2,"positionTop","positionTop",e.numberAttribute],positionLeft:[2,"positionLeft","positionLeft",e.numberAttribute],autoHide:[2,"autoHide","autoHide",e.booleanAttribute],fitContent:[2,"fitContent","fitContent",e.booleanAttribute],hideOnEscape:[2,"hideOnEscape","hideOnEscape",e.booleanAttribute],content:[0,"pTooltip","content"],disabled:[0,"tooltipDisabled","disabled"],tooltipOptions:"tooltipOptions"},features:[e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275NgOnChangesFeature]})}return r})(),Ff=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),yd=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["CheckIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M4.86199 11.5948C4.78717 11.5923 4.71366 11.5745 4.64596 11.5426C4.57826 11.5107 4.51779 11.4652 4.46827 11.4091L0.753985 7.69483C0.683167 7.64891 0.623706 7.58751 0.580092 7.51525C0.536478 7.44299 0.509851 7.36177 0.502221 7.27771C0.49459 7.19366 0.506156 7.10897 0.536046 7.03004C0.565935 6.95111 0.613367 6.88 0.674759 6.82208C0.736151 6.76416 0.8099 6.72095 0.890436 6.69571C0.970973 6.67046 1.05619 6.66385 1.13966 6.67635C1.22313 6.68886 1.30266 6.72017 1.37226 6.76792C1.44186 6.81567 1.4997 6.8786 1.54141 6.95197L4.86199 10.2503L12.6397 2.49483C12.7444 2.42694 12.8689 2.39617 12.9932 2.40745C13.1174 2.41873 13.2343 2.47141 13.3251 2.55705C13.4159 2.64268 13.4753 2.75632 13.4938 2.87973C13.5123 3.00315 13.4888 3.1292 13.4271 3.23768L5.2557 11.4091C5.20618 11.4652 5.14571 11.5107 5.07801 11.5426C5.01031 11.5745 4.9368 11.5923 4.86199 11.5948Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),Rm=(()=>{class r extends Wu{pathId;ngOnInit(){this.pathId="url(#"+Sp()+")"}static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["SearchIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:6,vars:7,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["fill-rule","evenodd","clip-rule","evenodd","d","M2.67602 11.0265C3.6661 11.688 4.83011 12.0411 6.02086 12.0411C6.81149 12.0411 7.59438 11.8854 8.32483 11.5828C8.87005 11.357 9.37808 11.0526 9.83317 10.6803L12.9769 13.8241C13.0323 13.8801 13.0983 13.9245 13.171 13.9548C13.2438 13.985 13.3219 14.0003 13.4007 14C13.4795 14.0003 13.5575 13.985 13.6303 13.9548C13.7031 13.9245 13.7691 13.8801 13.8244 13.8241C13.9367 13.7116 13.9998 13.5592 13.9998 13.4003C13.9998 13.2414 13.9367 13.089 13.8244 12.9765L10.6807 9.8328C11.053 9.37773 11.3573 8.86972 11.5831 8.32452C11.8857 7.59408 12.0414 6.81119 12.0414 6.02056C12.0414 4.8298 11.6883 3.66579 11.0268 2.67572C10.3652 1.68564 9.42494 0.913972 8.32483 0.45829C7.22472 0.00260857 6.01418 -0.116618 4.84631 0.115686C3.67844 0.34799 2.60568 0.921393 1.76369 1.76338C0.921698 2.60537 0.348296 3.67813 0.115991 4.84601C-0.116313 6.01388 0.00291375 7.22441 0.458595 8.32452C0.914277 9.42464 1.68595 10.3649 2.67602 11.0265ZM3.35565 2.0158C4.14456 1.48867 5.07206 1.20731 6.02086 1.20731C7.29317 1.20731 8.51338 1.71274 9.41304 2.6124C10.3127 3.51206 10.8181 4.73226 10.8181 6.00457C10.8181 6.95337 10.5368 7.88088 10.0096 8.66978C9.48251 9.45868 8.73328 10.0736 7.85669 10.4367C6.98011 10.7997 6.01554 10.8947 5.08496 10.7096C4.15439 10.5245 3.2996 10.0676 2.62869 9.39674C1.95778 8.72583 1.50089 7.87104 1.31579 6.94046C1.13068 6.00989 1.22568 5.04532 1.58878 4.16874C1.95187 3.29215 2.56675 2.54292 3.35565 2.0158Z","fill","currentColor"],[3,"id"],["width","14","height","14","fill","white"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0)(1,"g"),e.\u0275\u0275element(2,"path",1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"defs")(4,"clipPath",2),e.\u0275\u0275element(5,"rect",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role),e.\u0275\u0275advance(),e.\u0275\u0275attribute("clip-path",o.pathId),e.\u0275\u0275advance(3),e.\u0275\u0275property("id",o.pathId))},encapsulation:2})}return r})(),Lm=(()=>{class r extends Wu{pathId;ngOnInit(){this.pathId="url(#"+Sp()+")"}static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["TimesCircleIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:6,vars:7,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["fill-rule","evenodd","clip-rule","evenodd","d","M7 14C5.61553 14 4.26215 13.5895 3.11101 12.8203C1.95987 12.0511 1.06266 10.9579 0.532846 9.67879C0.00303296 8.3997 -0.13559 6.99224 0.134506 5.63437C0.404603 4.2765 1.07129 3.02922 2.05026 2.05026C3.02922 1.07129 4.2765 0.404603 5.63437 0.134506C6.99224 -0.13559 8.3997 0.00303296 9.67879 0.532846C10.9579 1.06266 12.0511 1.95987 12.8203 3.11101C13.5895 4.26215 14 5.61553 14 7C14 8.85652 13.2625 10.637 11.9497 11.9497C10.637 13.2625 8.85652 14 7 14ZM7 1.16667C5.84628 1.16667 4.71846 1.50879 3.75918 2.14976C2.79989 2.79074 2.05222 3.70178 1.61071 4.76768C1.16919 5.83358 1.05367 7.00647 1.27876 8.13803C1.50384 9.26958 2.05941 10.309 2.87521 11.1248C3.69102 11.9406 4.73042 12.4962 5.86198 12.7212C6.99353 12.9463 8.16642 12.8308 9.23232 12.3893C10.2982 11.9478 11.2093 11.2001 11.8502 10.2408C12.4912 9.28154 12.8333 8.15373 12.8333 7C12.8333 5.45291 12.2188 3.96918 11.1248 2.87521C10.0308 1.78125 8.5471 1.16667 7 1.16667ZM4.66662 9.91668C4.58998 9.91704 4.51404 9.90209 4.44325 9.87271C4.37246 9.84333 4.30826 9.8001 4.2544 9.74557C4.14516 9.6362 4.0838 9.48793 4.0838 9.33335C4.0838 9.17876 4.14516 9.0305 4.2544 8.92113L6.17553 7L4.25443 5.07891C4.15139 4.96832 4.09529 4.82207 4.09796 4.67094C4.10063 4.51982 4.16185 4.37563 4.26872 4.26876C4.3756 4.16188 4.51979 4.10066 4.67091 4.09799C4.82204 4.09532 4.96829 4.15142 5.07887 4.25446L6.99997 6.17556L8.92106 4.25446C9.03164 4.15142 9.1779 4.09532 9.32903 4.09799C9.48015 4.10066 9.62434 4.16188 9.73121 4.26876C9.83809 4.37563 9.89931 4.51982 9.90198 4.67094C9.90464 4.82207 9.84855 4.96832 9.74551 5.07891L7.82441 7L9.74554 8.92113C9.85478 9.0305 9.91614 9.17876 9.91614 9.33335C9.91614 9.48793 9.85478 9.6362 9.74554 9.74557C9.69168 9.8001 9.62748 9.84333 9.55669 9.87271C9.4859 9.90209 9.40996 9.91704 9.33332 9.91668C9.25668 9.91704 9.18073 9.90209 9.10995 9.87271C9.03916 9.84333 8.97495 9.8001 8.9211 9.74557L6.99997 7.82444L5.07884 9.74557C5.02499 9.8001 4.96078 9.84333 4.88999 9.87271C4.81921 9.90209 4.74326 9.91704 4.66662 9.91668Z","fill","currentColor"],[3,"id"],["width","14","height","14","fill","white"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0)(1,"g"),e.\u0275\u0275element(2,"path",1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"defs")(4,"clipPath",2),e.\u0275\u0275element(5,"rect",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role),e.\u0275\u0275advance(),e.\u0275\u0275attribute("clip-path",o.pathId),e.\u0275\u0275advance(3),e.\u0275\u0275property("id",o.pathId))},encapsulation:2})}return r})(),Sh=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["TimesIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M8.01186 7.00933L12.27 2.75116C12.341 2.68501 12.398 2.60524 12.4375 2.51661C12.4769 2.42798 12.4982 2.3323 12.4999 2.23529C12.5016 2.13827 12.4838 2.0419 12.4474 1.95194C12.4111 1.86197 12.357 1.78024 12.2884 1.71163C12.2198 1.64302 12.138 1.58893 12.0481 1.55259C11.9581 1.51625 11.8617 1.4984 11.7647 1.50011C11.6677 1.50182 11.572 1.52306 11.4834 1.56255C11.3948 1.60204 11.315 1.65898 11.2488 1.72997L6.99067 5.98814L2.7325 1.72997C2.59553 1.60234 2.41437 1.53286 2.22718 1.53616C2.03999 1.53946 1.8614 1.61529 1.72901 1.74767C1.59663 1.88006 1.5208 2.05865 1.5175 2.24584C1.5142 2.43303 1.58368 2.61419 1.71131 2.75116L5.96948 7.00933L1.71131 11.2675C1.576 11.403 1.5 11.5866 1.5 11.7781C1.5 11.9696 1.576 12.1532 1.71131 12.2887C1.84679 12.424 2.03043 12.5 2.2219 12.5C2.41338 12.5 2.59702 12.424 2.7325 12.2887L6.99067 8.03052L11.2488 12.2887C11.3843 12.424 11.568 12.5 11.7594 12.5C11.9509 12.5 12.1346 12.424 12.27 12.2887C12.4053 12.1532 12.4813 11.9696 12.4813 11.7781C12.4813 11.5866 12.4053 11.403 12.27 11.2675L8.01186 7.00933Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),Dg=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ChevronDownIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M7.01744 10.398C6.91269 10.3985 6.8089 10.378 6.71215 10.3379C6.61541 10.2977 6.52766 10.2386 6.45405 10.1641L1.13907 4.84913C1.03306 4.69404 0.985221 4.5065 1.00399 4.31958C1.02276 4.13266 1.10693 3.95838 1.24166 3.82747C1.37639 3.69655 1.55301 3.61742 1.74039 3.60402C1.92777 3.59062 2.11386 3.64382 2.26584 3.75424L7.01744 8.47394L11.769 3.75424C11.9189 3.65709 12.097 3.61306 12.2748 3.62921C12.4527 3.64535 12.6199 3.72073 12.7498 3.84328C12.8797 3.96582 12.9647 4.12842 12.9912 4.30502C13.0177 4.48162 12.9841 4.662 12.8958 4.81724L7.58083 10.1322C7.50996 10.2125 7.42344 10.2775 7.32656 10.3232C7.22968 10.3689 7.12449 10.3944 7.01744 10.398Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),km=(()=>{class r{autofocus=!1;focused=!1;platformId=(0,e.inject)(e.PLATFORM_ID);document=(0,e.inject)(ve.DOCUMENT);host=(0,e.inject)(e.ElementRef);ngAfterContentChecked(){!1===this.autofocus?this.host.nativeElement.removeAttribute("autofocus"):this.host.nativeElement.setAttribute("autofocus",!0),this.focused||this.autoFocus()}ngAfterViewChecked(){this.focused||this.autoFocus()}autoFocus(){(0,ve.isPlatformBrowser)(this.platformId)&&this.autofocus&&setTimeout(()=>{const t=xr.getFocusableElements(this.host?.nativeElement);0===t.length&&this.host.nativeElement.focus(),t.length>0&&t[0].focus(),this.focused=!0})}static \u0275fac=function(n){return new(n||r)};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pAutoFocus",""]],hostAttrs:[1,"p-element"],inputs:{autofocus:[2,"autofocus","autofocus",e.booleanAttribute]},standalone:!0,features:[e.\u0275\u0275InputTransformsFeature]})}return r})(),Nf=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({})}return r})(),Jp=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["MinusIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M13.2222 7.77778H0.777778C0.571498 7.77778 0.373667 7.69584 0.227806 7.54998C0.0819442 7.40412 0 7.20629 0 7.00001C0 6.79373 0.0819442 6.5959 0.227806 6.45003C0.373667 6.30417 0.571498 6.22223 0.777778 6.22223H13.2222C13.4285 6.22223 13.6263 6.30417 13.7722 6.45003C13.9181 6.5959 14 6.79373 14 7.00001C14 7.20629 13.9181 7.40412 13.7722 7.54998C13.6263 7.69584 13.4285 7.77778 13.2222 7.77778Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},dependencies:[ve.CommonModule],encapsulation:2})}return r})();const Cc=r=>({height:r}),io=(r,v)=>({"p-multiselect-item":!0,"p-disabled":r,"p-focus":v}),Ps=r=>({"p-variant-filled":r}),fc=r=>({"p-highlight":r}),Xl=r=>({$implicit:r});function nc(r,v){1&r&&e.\u0275\u0275element(0,"CheckIcon",7),2&r&&(e.\u0275\u0275property("styleClass","p-checkbox-icon"),e.\u0275\u0275attribute("aria-hidden",!0))}function ra(r,v){}function Rf(r,v){1&r&&e.\u0275\u0275template(0,ra,0,0,"ng-template")}function Ja(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",8),e.\u0275\u0275template(1,Rf,1,0,null,9),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.checkIconTemplate)}}function Jc(r,v){}function sd(r,v){1&r&&e.\u0275\u0275template(0,Jc,0,0,"ng-template")}function Ss(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",8),e.\u0275\u0275template(1,sd,1,0,null,4),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.itemCheckboxIconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(3,Xl,t.selected))}}function ps(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,nc,1,2,"CheckIcon",5)(2,Ja,2,2,"span",6)(3,Ss,2,5,"span",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.checkIconTemplate&&!t.itemCheckboxIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.checkIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.itemCheckboxIconTemplate)}}function eh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){let t;const n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(null!==(t=n.label)&&void 0!==t?t:"empty")}}function Eh(r,v){1&r&&e.\u0275\u0275elementContainer(0)}const Gl=["container"],zu=["overlay"],Bd=["filterInput"],th=["focusInput"],V=["items"],Qe=["scroller"],E=["lastHiddenFocusableEl"],U=["firstHiddenFocusableEl"],ee=["headerCheckbox"],Xe=[[["p-header"]],[["p-footer"]]],Nt=["p-header","p-footer"],Ei=(r,v)=>({$implicit:r,removeChip:v}),gr=r=>({"p-disabled":r}),ur=r=>({"max-height":r}),vo=r=>({options:r}),Gr=(r,v)=>({"p-variant-filled":r,"p-checkbox-disabled":v}),jo=(r,v,t)=>({"p-highlight":r,"p-focus":v,"p-disabled":t}),cs=(r,v)=>({$implicit:r,partialSelected:v}),el=(r,v)=>({$implicit:r,options:v}),gu=()=>({});function Zl(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.label()||"empty")}}function Ga(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"TimesCircleIcon",31),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.removeOption(o,f.event))}),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(4,gr,n.isOptionDisabled(t)))("styleClass","p-multiselect-token-icon"),e.\u0275\u0275attribute("data-pc-section","clearicon")("aria-hidden",!0)}}function qa(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Th(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",32),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.removeOption(o,f.event))}),e.\u0275\u0275template(1,qa,1,0,"ng-container",33),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275attribute("data-pc-section","clearicon")("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.removeTokenIconTemplate)}}function Pm(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Ga,1,6,"TimesCircleIcon",29)(2,Th,2,3,"span",30),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.removeTokenIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.removeTokenIconTemplate)}}function nh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",27,4)(2,"span",28),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(4,Pm,3,2,"ng-container",20),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate(n.getLabelByValue(t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.disabled)}}function ih(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.placeholder()||t.defaultLabel||"empty")}}function Jh(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,nh,5,2,"div",26)(2,ih,2,1,"ng-container",20),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.chipSelectedItems()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.modelValue()||0===t.modelValue().length)}}function em(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Zl,2,1,"ng-container",20)(2,Jh,3,2,"ng-container",20),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","comma"===t.display),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","chip"===t.display)}}function o1(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function vE(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"TimesIcon",36),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.clear(o))}),e.\u0275\u0275elementEnd()}2&r&&(e.\u0275\u0275property("styleClass","p-multiselect-clear-icon"),e.\u0275\u0275attribute("data-pc-section","clearicon")("aria-hidden",!0))}function ef(r,v){}function x0(r,v){1&r&&e.\u0275\u0275template(0,ef,0,0,"ng-template")}function z_(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",37),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.clear(o))}),e.\u0275\u0275template(1,x0,1,0,null,33),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("data-pc-section","clearicon")("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.clearIconTemplate)}}function wg(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,vE,1,3,"TimesIcon",34)(2,z_,2,3,"span",35),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.clearIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.clearIconTemplate)}}function Dc(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Av(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Dc,1,0,"ng-container",33),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.loadingIconTemplate)}}function lx(r,v){if(1&r&&e.\u0275\u0275element(0,"span",40),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass","p-multiselect-trigger-icon pi-spin "+t.loadingIcon)}}function tm(r,v){1&r&&e.\u0275\u0275element(0,"span",41),2&r&&e.\u0275\u0275classMap("p-multiselect-trigger-icon pi pi-spinner pi-spin")}function T(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,lx,1,1,"span",38)(2,tm,1,2,"span",39),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loadingIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIcon)}}function P(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Av,2,1,"ng-container",20)(2,T,3,2,"ng-container",20),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loadingIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIconTemplate)}}function W(r,v){if(1&r&&e.\u0275\u0275element(0,"span",45),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass",t.dropdownIcon),e.\u0275\u0275attribute("data-pc-section","triggericon")("aria-hidden",!0)}}function se(r,v){1&r&&e.\u0275\u0275element(0,"ChevronDownIcon",46),2&r&&(e.\u0275\u0275property("styleClass","p-multiselect-trigger-icon"),e.\u0275\u0275attribute("data-pc-section","triggericon")("aria-hidden",!0))}function me(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,W,1,3,"span",43)(2,se,1,3,"ChevronDownIcon",44),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dropdownIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.dropdownIcon)}}function Fe(r,v){}function gt(r,v){1&r&&e.\u0275\u0275template(0,Fe,0,0,"ng-template")}function Bt(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",47),e.\u0275\u0275template(1,gt,1,0,null,33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("data-pc-section","triggericon")("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.dropdownIconTemplate)}}function wn(r,v){if(1&r&&e.\u0275\u0275template(0,me,3,2,"ng-container",20)(1,Bt,2,3,"span",42),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngIf",!t.dropdownIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dropdownIconTemplate)}}function ei(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function yi(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Vi(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,yi,1,0,"ng-container",21),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.filterTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,vo,t.filterOptions))}}function tr(r,v){1&r&&e.\u0275\u0275element(0,"CheckIcon",46),2&r&&(e.\u0275\u0275property("styleClass","p-checkbox-icon"),e.\u0275\u0275attribute("aria-hidden",!0))}function Wr(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,tr,1,2,"CheckIcon",44),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(6);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.allSelected())}}function Yo(r,v){}function Cl(r,v){1&r&&e.\u0275\u0275template(0,Yo,0,0,"ng-template")}function pc(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",63),e.\u0275\u0275template(1,Cl,1,0,null,21),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(6);e.\u0275\u0275attribute("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.checkIconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(3,Xl,t.allSelected()))}}function Yu(r,v){}function Yf(r,v){1&r&&e.\u0275\u0275template(0,Yu,0,0,"ng-template")}function bd(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",63),e.\u0275\u0275template(1,Yf,1,0,null,21),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(6);e.\u0275\u0275attribute("aria-hidden",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.headerCheckboxIconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(3,cs,t.allSelected(),t.partialSelected()))}}function vu(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Wr,2,1,"ng-container",20)(2,pc,2,5,"span",62)(3,bd,2,6,"span",62),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.checkIconTemplate&&!t.headerCheckboxIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.checkIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.headerCheckboxIconTemplate)}}function rh(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",59),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onToggleAll(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onHeaderCheckboxKeyDown(o))}),e.\u0275\u0275elementStart(1,"div",16)(2,"input",60,9),e.\u0275\u0275listener("focus",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(o.onHeaderCheckboxFocus())})("blur",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(o.onHeaderCheckboxBlur())}),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(4,"div",61),e.\u0275\u0275template(5,vu,4,3,"ng-container",20),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction2(10,Gr,"filled"===t.variant||"filled"===t.config.inputStyle(),t.disabled||t.toggleAllDisabled)),e.\u0275\u0275advance(),e.\u0275\u0275attribute("data-p-hidden-accessible",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("readonly",t.readonly)("disabled",t.disabled||t.toggleAllDisabled),e.\u0275\u0275attribute("checked",t.allSelected())("aria-label",t.toggleAllAriaLabel),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction3(13,jo,t.allSelected(),t.headerCheckboxFocus,t.disabled||t.toggleAllDisabled)),e.\u0275\u0275attribute("aria-label",t.toggleAllAriaLabel)("aria-checked",t.allSelected()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.allSelected()||t.partialSelected())}}function Xf(r,v){1&r&&e.\u0275\u0275element(0,"SearchIcon",46),2&r&&e.\u0275\u0275property("styleClass","p-multiselect-filter-icon")}function Qa(r,v){}function Ov(r,v){1&r&&e.\u0275\u0275template(0,Qa,0,0,"ng-template")}function Tr(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",67),e.\u0275\u0275template(1,Ov,1,0,null,33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.filterIconTemplate)}}function Vs(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",64)(1,"input",65,10),e.\u0275\u0275listener("input",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onFilterInputChange(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onFilterKeyDown(o))})("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onInputClick(o))})("blur",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.onFilterBlur(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,Xf,1,1,"SearchIcon",44)(4,Tr,2,1,"span",66),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("value",t._filterValue()||"")("disabled",t.disabled),e.\u0275\u0275attribute("autocomplete",t.autocomplete)("placeholder",t.filterPlaceHolder)("aria-owns",t.id+"_list")("aria-activedescendant",t.focusedOptionId)("placeholder",t.filterPlaceHolder)("aria-label",t.ariaFilterLabel),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!t.filterIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.filterIconTemplate)}}function lp(r,v){1&r&&e.\u0275\u0275element(0,"TimesIcon",46),2&r&&e.\u0275\u0275property("styleClass","p-multiselect-close-icon")}function ka(r,v){}function Lf(r,v){1&r&&e.\u0275\u0275template(0,ka,0,0,"ng-template")}function tf(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",68),e.\u0275\u0275template(1,Lf,1,0,null,33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.closeIconTemplate)}}function oh(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275template(0,rh,6,17,"div",55)(1,Vs,5,10,"div",56),e.\u0275\u0275elementStart(2,"button",57),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.close(o))}),e.\u0275\u0275template(3,lp,1,1,"TimesIcon",44)(4,tf,2,1,"span",58),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngIf",t.isSelectionAllDisabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.filter),e.\u0275\u0275advance(),e.\u0275\u0275attribute("aria-label",t.closeAriaLabel),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.closeIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.closeIconTemplate)}}function G_(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",54),e.\u0275\u0275projection(1),e.\u0275\u0275template(2,ei,1,0,"ng-container",33)(3,Vi,2,4,"ng-container",23)(4,oh,5,5,"ng-template",null,8,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275reference(5),n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",n.headerTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.filterTemplate)("ngIfElse",t)}}function S0(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function vf(r,v){if(1&r&&e.\u0275\u0275template(0,S0,1,0,"ng-container",21),2&r){const t=v.$implicit,n=v.options;e.\u0275\u0275nextContext(2);const o=e.\u0275\u0275reference(8);e.\u0275\u0275property("ngTemplateOutlet",o)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(2,el,t,n))}}function xg(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function s1(r,v){if(1&r&&e.\u0275\u0275template(0,xg,1,0,"ng-container",21),2&r){const t=v.options,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("ngTemplateOutlet",n.loaderTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,vo,t))}}function Bm(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,s1,1,4,"ng-template",70),e.\u0275\u0275elementContainerEnd())}function Ir(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"p-scroller",69,11),e.\u0275\u0275listener("onLazyLoad",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onLazyLoad.emit(o))}),e.\u0275\u0275template(2,vf,1,5,"ng-template",25)(3,Bm,2,0,"ng-container",20),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275styleMap(e.\u0275\u0275pureFunction1(9,Cc,t.scrollHeight)),e.\u0275\u0275property("items",t.visibleOptions())("itemSize",t.virtualScrollItemSize||t._itemSize)("autoSize",!0)("tabindex",-1)("lazy",t.lazy)("options",t.virtualScrollOptions),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.loaderTemplate)}}function bs(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Ko(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,bs,1,0,"ng-container",21),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(8),n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(3,el,n.visibleOptions(),e.\u0275\u0275pureFunction0(2,gu)))}}function Es(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(n.getOptionGroupLabel(t.optionGroup))}}function jc(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function wc(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",74),e.\u0275\u0275template(2,Es,2,1,"span",20)(3,jc,1,0,"ng-container",21),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext().options,D=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(5,Cc,f.itemSize+"px")),e.\u0275\u0275attribute("id",D.id+"_"+D.getOptionIndex(o,f)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!D.groupTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",D.groupTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(7,Xl,n.optionGroup))}}function Ho(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"p-multiSelectItem",75),e.\u0275\u0275listener("onClick",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext().index,D=e.\u0275\u0275nextContext().options,j=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(j.onOptionSelect(o,!1,j.getOptionIndex(f,D)))})("onMouseEnter",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext().index,D=e.\u0275\u0275nextContext().options,j=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(j.onOptionMouseEnter(o,j.getOptionIndex(f,D)))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext().options,D=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("id",D.id+"_"+D.getOptionIndex(o,f))("option",n)("selected",D.isSelected(n))("label",D.getOptionLabel(n))("disabled",D.isOptionDisabled(n))("template",D.itemTemplate)("checkIconTemplate",D.checkIconTemplate)("itemCheckboxIconTemplate",D.itemCheckboxIconTemplate)("itemSize",f.itemSize)("focused",D.focusedOptionIndex()===D.getOptionIndex(o,f))("ariaPosInset",D.getAriaPosInset(D.getOptionIndex(o,f)))("ariaSetSize",D.ariaSetSize)}}function cp(r,v){if(1&r&&e.\u0275\u0275template(0,wc,4,9,"ng-container",20)(1,Ho,2,12,"ng-container",20),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngIf",n.isOptionGroup(t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.isOptionGroup(t))}}function Mh(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.emptyFilterMessageLabel," ")}}function E0(r,v){1&r&&e.\u0275\u0275elementContainer(0,null,13)}function sh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",76),e.\u0275\u0275template(1,Mh,2,1,"ng-container",23)(2,E0,2,0,"ng-container",33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().options,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(4,Cc,t.itemSize+"px")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.emptyFilterTemplate&&!n.emptyTemplate)("ngIfElse",n.emptyFilter),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n.emptyFilterTemplate||n.emptyTemplate)}}function nD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.emptyMessageLabel," ")}}function iD(r,v){1&r&&e.\u0275\u0275elementContainer(0,null,14)}function T0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",76),e.\u0275\u0275template(1,nD,2,1,"ng-container",23)(2,iD,2,0,"ng-container",33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().options,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(4,Cc,t.itemSize+"px")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.emptyTemplate)("ngIfElse",n.empty),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n.emptyTemplate)}}function cx(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"ul",71,12),e.\u0275\u0275template(2,cp,2,2,"ng-template",72)(3,sh,3,6,"li",73)(4,T0,3,6,"li",73),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.options,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",n.contentStyleClass)("ngStyle",n.contentStyle),e.\u0275\u0275attribute("aria-label",o.listLabel),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.hasFilter()&&o.isEmpty()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.hasFilter()&&o.isEmpty())}}function Sg(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function rD(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",77),e.\u0275\u0275projection(1,1),e.\u0275\u0275template(2,Sg,1,0,"ng-container",33),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",t.footerTemplate)}}function ux(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",48)(1,"span",49,5),e.\u0275\u0275listener("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onFirstHiddenFocus(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,G_,6,3,"div",50),e.\u0275\u0275elementStart(4,"div",51),e.\u0275\u0275template(5,Ir,4,11,"p-scroller",52)(6,Ko,2,6,"ng-container",20)(7,cx,5,6,"ng-template",null,6,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(9,rD,3,1,"div",53),e.\u0275\u0275elementStart(10,"span",49,7),e.\u0275\u0275listener("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onLastHiddenFocus(o))}),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.panelStyleClass),e.\u0275\u0275property("ngClass","p-multiselect-panel p-component")("ngStyle",t.panelStyle),e.\u0275\u0275attribute("id",t.id+"_list"),e.\u0275\u0275advance(),e.\u0275\u0275attribute("tabindex",0)("data-p-hidden-accessible",!0)("data-p-hidden-focusable",!0),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.showHeader),e.\u0275\u0275advance(),e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(16,ur,t.virtualScroll?"auto":t.scrollHeight||"auto")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.virtualScroll),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.virtualScroll),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.footerFacet||t.footerTemplate),e.\u0275\u0275advance(),e.\u0275\u0275attribute("tabindex",0)("data-p-hidden-accessible",!0)("data-p-hidden-focusable",!0)}}const Ap={provide:Ji.NG_VALUE_ACCESSOR,useExisting:(0,e.forwardRef)(()=>M0),multi:!0};let _E=(()=>{class r{config;id;option;selected;label;disabled;itemSize;focused;ariaPosInset;ariaSetSize;template;checkIconTemplate;itemCheckboxIconTemplate;onClick=new e.EventEmitter;onMouseEnter=new e.EventEmitter;constructor(t){this.config=t}onOptionClick(t){this.onClick.emit({originalEvent:t,option:this.option,selected:this.selected}),t.stopPropagation()}onOptionMouseEnter(t){this.onMouseEnter.emit({originalEvent:t,option:this.option,selected:this.selected})}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(mf))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-multiSelectItem"]],hostAttrs:[1,"p-element"],inputs:{id:"id",option:"option",selected:[2,"selected","selected",e.booleanAttribute],label:"label",disabled:[2,"disabled","disabled",e.booleanAttribute],itemSize:[2,"itemSize","itemSize",e.numberAttribute],focused:[2,"focused","focused",e.booleanAttribute],ariaPosInset:"ariaPosInset",ariaSetSize:"ariaSetSize",template:"template",checkIconTemplate:"checkIconTemplate",itemCheckboxIconTemplate:"itemCheckboxIconTemplate"},outputs:{onClick:"onClick",onMouseEnter:"onMouseEnter"},features:[e.\u0275\u0275InputTransformsFeature],decls:6,vars:28,consts:[["pRipple","","role","option",1,"p-multiselect-item",3,"click","mouseenter","ngStyle","ngClass","id"],[1,"p-checkbox","p-component",3,"ngClass"],[1,"p-checkbox-box",3,"ngClass"],[4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"styleClass",4,"ngIf"],["class","p-checkbox-icon",4,"ngIf"],[3,"styleClass"],[1,"p-checkbox-icon"],[4,"ngTemplateOutlet"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"li",0),e.\u0275\u0275listener("click",function(D){return o.onOptionClick(D)})("mouseenter",function(D){return o.onOptionMouseEnter(D)}),e.\u0275\u0275elementStart(1,"div",1)(2,"div",2),e.\u0275\u0275template(3,ps,4,3,"ng-container",3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(4,eh,2,1,"span",3)(5,Eh,1,0,"ng-container",4),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(17,Cc,o.itemSize+"px"))("ngClass",e.\u0275\u0275pureFunction2(19,io,o.disabled,o.focused))("id",o.id),e.\u0275\u0275attribute("aria-label",o.label)("aria-setsize",o.ariaSetSize)("aria-posinset",o.ariaPosInset)("aria-selected",o.selected)("data-p-focused",o.focused)("data-p-highlight",o.selected)("data-p-disabled",o.disabled)("aria-checked",o.selected),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(22,Ps,"filled"===o.config.inputStyle())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(24,fc,o.selected)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.selected),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.template),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",o.template)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(26,Xl,o.option)))},dependencies:()=>[ve.NgClass,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,Bs,yd],encapsulation:2})}return r})(),M0=(()=>{class r{el;renderer;cd;zone;filterService;config;overlayService;id;ariaLabel;style;styleClass;panelStyle;panelStyleClass;inputId;disabled;readonly;group;filter=!0;filterPlaceHolder;filterLocale;overlayVisible;tabindex=0;variant="outlined";appendTo;dataKey;name;ariaLabelledBy;set displaySelectedLabel(t){this._displaySelectedLabel=t}get displaySelectedLabel(){return this._displaySelectedLabel}set maxSelectedLabels(t){this._maxSelectedLabels=t}get maxSelectedLabels(){return this._maxSelectedLabels}selectionLimit;selectedItemsLabel;showToggleAll=!0;emptyFilterMessage="";emptyMessage="";resetFilterOnHide=!1;dropdownIcon;optionLabel;optionValue;optionDisabled;optionGroupLabel="label";optionGroupChildren="items";showHeader=!0;filterBy;scrollHeight="200px";lazy=!1;virtualScroll;loading=!1;virtualScrollItemSize;loadingIcon;virtualScrollOptions;overlayOptions;ariaFilterLabel;filterMatchMode="contains";tooltip="";tooltipPosition="right";tooltipPositionStyle="absolute";tooltipStyleClass;autofocusFilter=!0;display="comma";autocomplete="off";showClear=!1;autofocus;get autoZIndex(){return this._autoZIndex}set autoZIndex(t){this._autoZIndex=t,console.warn("The autoZIndex property is deprecated since v14.2.0, use overlayOptions property instead.")}get baseZIndex(){return this._baseZIndex}set baseZIndex(t){this._baseZIndex=t,console.warn("The baseZIndex property is deprecated since v14.2.0, use overlayOptions property instead.")}get showTransitionOptions(){return this._showTransitionOptions}set showTransitionOptions(t){this._showTransitionOptions=t,console.warn("The showTransitionOptions property is deprecated since v14.2.0, use overlayOptions property instead.")}get hideTransitionOptions(){return this._hideTransitionOptions}set hideTransitionOptions(t){this._hideTransitionOptions=t,console.warn("The hideTransitionOptions property is deprecated since v14.2.0, use overlayOptions property instead.")}set defaultLabel(t){this._defaultLabel=t,console.warn("defaultLabel property is deprecated since 16.6.0, use placeholder instead")}get defaultLabel(){return this._defaultLabel}set placeholder(t){this._placeholder.set(t)}get placeholder(){return this._placeholder.asReadonly()}get options(){return this._options()}set options(t){ro.deepEquals(this._options(),t)||this._options.set(t)}get filterValue(){return this._filterValue()}set filterValue(t){this._filterValue.set(t)}get itemSize(){return this._itemSize}set itemSize(t){this._itemSize=t,console.warn("The itemSize property is deprecated, use virtualScrollItemSize property instead.")}get selectAll(){return this._selectAll}set selectAll(t){this._selectAll=t}focusOnHover=!1;filterFields;selectOnFocus=!1;autoOptionFocus=!0;onChange=new e.EventEmitter;onFilter=new e.EventEmitter;onFocus=new e.EventEmitter;onBlur=new e.EventEmitter;onClick=new e.EventEmitter;onClear=new e.EventEmitter;onPanelShow=new e.EventEmitter;onPanelHide=new e.EventEmitter;onLazyLoad=new e.EventEmitter;onRemove=new e.EventEmitter;onSelectAllChange=new e.EventEmitter;containerViewChild;overlayViewChild;filterInputChild;focusInputViewChild;itemsViewChild;scroller;lastHiddenFocusableElementOnOverlay;firstHiddenFocusableElementOnOverlay;headerCheckboxViewChild;footerFacet;headerFacet;templates;searchValue;searchTimeout;_selectAll=null;_autoZIndex;_baseZIndex;_showTransitionOptions;_hideTransitionOptions;_defaultLabel;_placeholder=(0,e.signal)(void 0);_itemSize;_selectionLimit;_disableTooltip=!1;value;_filteredOptions;onModelChange=()=>{};onModelTouched=()=>{};valuesAsString;focus;filtered;itemTemplate;groupTemplate;loaderTemplate;headerTemplate;filterTemplate;footerTemplate;emptyFilterTemplate;emptyTemplate;selectedItemsTemplate;checkIconTemplate;loadingIconTemplate;filterIconTemplate;removeTokenIconTemplate;closeIconTemplate;clearIconTemplate;dropdownIconTemplate;itemCheckboxIconTemplate;headerCheckboxIconTemplate;headerCheckboxFocus;filterOptions;preventModelTouched;preventDocumentDefault;focused=!1;itemsWrapper;_displaySelectedLabel=!0;_maxSelectedLabels=3;modelValue=(0,e.signal)(null);_filterValue=(0,e.signal)(null);_options=(0,e.signal)(null);startRangeIndex=(0,e.signal)(-1);focusedOptionIndex=(0,e.signal)(-1);selectedOptions;clickInProgress=!1;get containerClass(){return{"p-multiselect p-component p-inputwrapper":!0,"p-disabled":this.disabled,"p-multiselect-clearable":this.showClear&&!this.disabled,"p-multiselect-chip":"chip"===this.display,"p-focus":this.focused,"p-variant-filled":"filled"===this.variant||"filled"===this.config.inputStyle()}}get inputClass(){return{"p-multiselect-label p-inputtext":!0,"p-placeholder":(this.placeholder()||this.defaultLabel)&&(this.label()===this.placeholder()||this.label()===this.defaultLabel),"p-multiselect-label-empty":!this.selectedItemsTemplate&&("p-emptylabel"===this.label()||0===this.label().length)}}get panelClass(){return{"p-multiselect-panel p-component":!0,"p-input-filled":"filled"===this.config.inputStyle(),"p-ripple-disabled":!1===this.config.ripple}}get labelClass(){return{"p-multiselect-label":!0,"p-placeholder":this.label()===this.placeholder()||this.label()===this.defaultLabel,"p-multiselect-label-empty":!(this.placeholder()||this.defaultLabel||this.modelValue()&&0!==this.modelValue().length)}}get emptyMessageLabel(){return this.emptyMessage||this.config.getTranslation(If.EMPTY_MESSAGE)}get emptyFilterMessageLabel(){return this.emptyFilterMessage||this.config.getTranslation(If.EMPTY_FILTER_MESSAGE)}get filled(){return"string"==typeof this.modelValue()?!!this.modelValue():ro.isNotEmpty(this.modelValue())}get isVisibleClearIcon(){return null!=this.modelValue()&&""!==this.modelValue()&&ro.isNotEmpty(this.modelValue())&&this.showClear&&!this.disabled&&this.filled}get toggleAllAriaLabel(){return this.config.translation.aria?this.config.translation.aria[this.allSelected()?"selectAll":"unselectAll"]:void 0}get closeAriaLabel(){return this.config.translation.aria?this.config.translation.aria.close:void 0}get listLabel(){return this.config.getTranslation(If.ARIA).listLabel}getAllVisibleAndNonVisibleOptions(){return this.group?this.flatOptions(this.options):this.options||[]}visibleOptions=(0,e.computed)(()=>{const t=this.getAllVisibleAndNonVisibleOptions(),n=ro.isArray(t)&&ro.isObject(t[0]);if(this._filterValue()){let o;if(o=n?this.filterService.filter(t,this.searchFields(),this._filterValue(),this.filterMatchMode,this.filterLocale):t.filter(f=>f.toString().toLocaleLowerCase().includes(this._filterValue().toLocaleLowerCase())),this.group){const D=[];return(this.options||[]).forEach(j=>{const Ne=this.getOptionGroupChildren(j).filter(vt=>o.includes(vt));Ne.length>0&&D.push({...j,["string"==typeof this.optionGroupChildren?this.optionGroupChildren:"items"]:[...Ne]})}),this.flatOptions(D)}return o}return t});label=(0,e.computed)(()=>{let t;const n=this.modelValue();if(n&&n.length&&this.displaySelectedLabel){if(ro.isNotEmpty(this.maxSelectedLabels)&&n.length>this.maxSelectedLabels)return this.getSelectedItemsLabel();t="";for(let o=0;o<n.length;o++)0!==o&&(t+=", "),t+=this.getLabelByValue(n[o])}else t=this.placeholder()||this.defaultLabel||"";return t});chipSelectedItems=(0,e.computed)(()=>ro.isNotEmpty(this.maxSelectedLabels)&&this.modelValue()&&this.modelValue().length>this.maxSelectedLabels?this.modelValue().slice(0,this.maxSelectedLabels):this.modelValue());constructor(t,n,o,f,D,j,fe){this.el=t,this.renderer=n,this.cd=o,this.zone=f,this.filterService=D,this.config=j,this.overlayService=fe,(0,e.effect)(()=>{const Ne=this.modelValue(),vt=this.visibleOptions();vt&&ro.isNotEmpty(vt)&&(this.selectedOptions=this.optionValue&&this.optionLabel&&Ne?vt.filter(ln=>Ne.includes(ln[this.optionLabel])||Ne.includes(ln[this.optionValue])):Ne,this.cd.markForCheck())})}ngOnInit(){this.id=this.id||Sp(),this.autoUpdateModel(),this.filterBy&&(this.filterOptions={filter:t=>this.onFilterInputChange(t),reset:()=>this.resetFilter()})}maxSelectionLimitReached(){return ro.isNotEmpty(this.selectionLimit)&&this.modelValue()&&this.modelValue().length===this.selectionLimit}ngAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"item":default:this.itemTemplate=t.template;break;case"group":this.groupTemplate=t.template;break;case"selectedItems":this.selectedItemsTemplate=t.template;break;case"header":this.headerTemplate=t.template;break;case"filter":this.filterTemplate=t.template;break;case"emptyfilter":this.emptyFilterTemplate=t.template;break;case"empty":this.emptyTemplate=t.template;break;case"footer":this.footerTemplate=t.template;break;case"loader":this.loaderTemplate=t.template;break;case"checkicon":this.checkIconTemplate=t.template,console.warn("checkicon is deprecated and will removed in v18. Use itemcheckboxicon or headercheckboxicon templates instead.");break;case"headercheckboxicon":this.headerCheckboxIconTemplate=t.template;break;case"loadingicon":this.loadingIconTemplate=t.template;break;case"filtericon":this.filterIconTemplate=t.template;break;case"removetokenicon":this.removeTokenIconTemplate=t.template;break;case"closeicon":this.closeIconTemplate=t.template;break;case"clearicon":this.clearIconTemplate=t.template;break;case"dropdownicon":this.dropdownIconTemplate=t.template;break;case"itemcheckboxicon":this.itemCheckboxIconTemplate=t.template}})}ngAfterViewInit(){this.overlayVisible&&this.show()}ngAfterViewChecked(){this.filtered&&(this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.overlayViewChild?.alignOverlay()},1)}),this.filtered=!1)}flatOptions(t){return(t||[]).reduce((n,o,f)=>{n.push({optionGroup:o,group:!0,index:f});const D=this.getOptionGroupChildren(o);return D&&D.forEach(j=>n.push(j)),n},[])}autoUpdateModel(){if(this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption()){this.focusedOptionIndex.set(this.findFirstFocusedOptionIndex());const t=this.getOptionValue(this.visibleOptions()[this.focusedOptionIndex()]);this.onOptionSelect({originalEvent:null,option:[t]})}}updateModel(t,n){this.value=t,this.onModelChange(t),this.modelValue.set(t)}onInputClick(t){t.stopPropagation(),t.preventDefault(),this.focusedOptionIndex.set(-1)}onOptionSelect(t,n=!1,o=-1){const{originalEvent:f,option:D}=t;if(this.disabled||this.isOptionDisabled(D))return;let fe=null;this.isSelected(D)?(fe=this.modelValue().filter(Ne=>!ro.equals(Ne,this.getOptionValue(D),this.equalityKey())),this.onRemove.emit({newValue:this.value,removed:this.getOptionValue(D)})):fe=[...this.modelValue()||[],this.getOptionValue(D)],this.updateModel(fe,f),-1!==o&&this.focusedOptionIndex.set(o),n&&xr.focus(this.focusInputViewChild?.nativeElement),this.onChange.emit({originalEvent:{...t,selected:!t.selected},value:fe,itemValue:D})}findSelectedOptionIndex(){return this.hasSelectedOption()?this.visibleOptions().findIndex(t=>this.isValidSelectedOption(t)):-1}onOptionSelectRange(t,n=-1,o=-1){if(-1===n&&(n=this.findNearestSelectedOptionIndex(o,!0)),-1===o&&(o=this.findNearestSelectedOptionIndex(n)),-1!==n&&-1!==o){const f=Math.min(n,o),D=Math.max(n,o),j=this.visibleOptions().slice(f,D+1).filter(fe=>this.isValidOption(fe)).map(fe=>this.getOptionValue(fe));this.updateModel(j,t)}}searchFields(){return(this.filterBy||this.optionLabel||"label").split(",")}findNearestSelectedOptionIndex(t,n=!1){let o=-1;return this.hasSelectedOption()&&(n?(o=this.findPrevSelectedOptionIndex(t),o=-1===o?this.findNextSelectedOptionIndex(t):o):(o=this.findNextSelectedOptionIndex(t),o=-1===o?this.findPrevSelectedOptionIndex(t):o)),o>-1?o:t}findPrevSelectedOptionIndex(t){const n=this.hasSelectedOption()&&t>0?ro.findLastIndex(this.visibleOptions().slice(0,t),o=>this.isValidSelectedOption(o)):-1;return n>-1?n:-1}findFirstFocusedOptionIndex(){const t=this.findFirstSelectedOptionIndex();return t<0?this.findFirstOptionIndex():t}findFirstOptionIndex(){return this.visibleOptions().findIndex(t=>this.isValidOption(t))}findFirstSelectedOptionIndex(){return this.hasSelectedOption()?this.visibleOptions().findIndex(t=>this.isValidSelectedOption(t)):-1}findNextSelectedOptionIndex(t){const n=this.hasSelectedOption()&&t<this.visibleOptions().length-1?this.visibleOptions().slice(t+1).findIndex(o=>this.isValidSelectedOption(o)):-1;return n>-1?n+t+1:-1}equalityKey(){return this.optionValue?null:this.dataKey}hasSelectedOption(){return ro.isNotEmpty(this.modelValue())}isSelectionAllDisabled(){return this.showToggleAll&&ro.isEmpty(this.selectionLimit)}isValidSelectedOption(t){return this.isValidOption(t)&&this.isSelected(t)}isOptionGroup(t){return(this.group||this.optionGroupLabel)&&t.optionGroup&&t.group}isValidOption(t){return t&&!(this.isOptionDisabled(t)||this.isOptionGroup(t))}isOptionDisabled(t){return!(!this.maxSelectionLimitReached()||this.isSelected(t))||(this.optionDisabled?ro.resolveFieldData(t,this.optionDisabled):!(!t||void 0===t.disabled)&&t.disabled)}isSelected(t){const n=this.getOptionValue(t);return(this.modelValue()||[]).some(o=>ro.equals(o,n,this.equalityKey()))}isOptionMatched(t){return this.isValidOption(t)&&this.getOptionLabel(t).toString().toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale))}isEmpty(){return!this._options()||this.visibleOptions()&&0===this.visibleOptions().length}getOptionIndex(t,n){return this.virtualScrollerDisabled?t:n&&n.getItemOptions(t).index}getAriaPosInset(t){return(this.optionGroupLabel?t-this.visibleOptions().slice(0,t).filter(n=>this.isOptionGroup(n)).length:t)+1}get ariaSetSize(){return this.visibleOptions().filter(t=>!this.isOptionGroup(t)).length}getLabelByValue(t){const o=(this.group?this.flatOptions(this._options()):this._options()||[]).find(f=>!this.isOptionGroup(f)&&ro.equals(this.getOptionValue(f),t,this.equalityKey()));return o?this.getOptionLabel(o):null}getSelectedItemsLabel(){let t=/{(.*?)}/,n=this.selectedItemsLabel?this.selectedItemsLabel:this.config.getTranslation(If.SELECTION_MESSAGE);return t.test(n)?n.replace(n.match(t)[0],this.modelValue().length+""):n}getOptionLabel(t){return this.optionLabel?ro.resolveFieldData(t,this.optionLabel):t&&null!=t.label?t.label:t}getOptionValue(t){return this.optionValue?ro.resolveFieldData(t,this.optionValue):!this.optionLabel&&t&&void 0!==t.value?t.value:t}getOptionGroupLabel(t){return this.optionGroupLabel?ro.resolveFieldData(t,this.optionGroupLabel):t&&null!=t.label?t.label:t}getOptionGroupChildren(t){return this.optionGroupChildren?ro.resolveFieldData(t,this.optionGroupChildren):t.items}onKeyDown(t){if(this.disabled)return void t.preventDefault();const n=t.metaKey||t.ctrlKey;switch(t.code){case"ArrowDown":this.onArrowDownKey(t);break;case"ArrowUp":this.onArrowUpKey(t);break;case"Home":this.onHomeKey(t);break;case"End":this.onEndKey(t);break;case"PageDown":this.onPageDownKey(t);break;case"PageUp":this.onPageUpKey(t);break;case"Enter":case"Space":this.onEnterKey(t);break;case"Escape":this.onEscapeKey(t);break;case"Tab":this.onTabKey(t);break;case"ShiftLeft":case"ShiftRight":this.onShiftKey();break;default:if("KeyA"===t.code&&n){const o=this.visibleOptions().filter(f=>this.isValidOption(f)).map(f=>this.getOptionValue(f));this.updateModel(o,t),t.preventDefault();break}!n&&ro.isPrintableCharacter(t.key)&&(!this.overlayVisible&&this.show(),this.searchOptions(t,t.key),t.preventDefault())}}onFilterKeyDown(t){switch(t.code){case"ArrowDown":this.onArrowDownKey(t);break;case"ArrowUp":this.onArrowUpKey(t,!0);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(t,!0);break;case"Home":this.onHomeKey(t,!0);break;case"End":this.onEndKey(t,!0);break;case"Enter":case"NumpadEnter":this.onEnterKey(t);break;case"Escape":this.onEscapeKey(t);break;case"Tab":this.onTabKey(t,!0)}}onArrowLeftKey(t,n=!1){n&&this.focusedOptionIndex.set(-1)}onArrowDownKey(t){const n=-1!==this.focusedOptionIndex()?this.findNextOptionIndex(this.focusedOptionIndex()):this.findFirstFocusedOptionIndex();t.shiftKey&&this.onOptionSelectRange(t,this.startRangeIndex(),n),this.changeFocusedOptionIndex(t,n),!this.overlayVisible&&this.show(),t.preventDefault(),t.stopPropagation()}onArrowUpKey(t,n=!1){if(t.altKey&&!n)-1!==this.focusedOptionIndex()&&this.onOptionSelect(t,this.visibleOptions()[this.focusedOptionIndex()]),this.overlayVisible&&this.hide(),t.preventDefault();else{const o=-1!==this.focusedOptionIndex()?this.findPrevOptionIndex(this.focusedOptionIndex()):this.findLastFocusedOptionIndex();t.shiftKey&&this.onOptionSelectRange(t,o,this.startRangeIndex()),this.changeFocusedOptionIndex(t,o),!this.overlayVisible&&this.show(),t.preventDefault()}t.stopPropagation()}onHomeKey(t,n=!1){const{currentTarget:o}=t;if(n)o.setSelectionRange(0,t.shiftKey?o.value.length:0),this.focusedOptionIndex.set(-1);else{let f=t.metaKey||t.ctrlKey,D=this.findFirstOptionIndex();t.shiftKey&&f&&this.onOptionSelectRange(t,D,this.startRangeIndex()),this.changeFocusedOptionIndex(t,D),!this.overlayVisible&&this.show()}t.preventDefault()}onEndKey(t,n=!1){const{currentTarget:o}=t;if(n){const f=o.value.length;o.setSelectionRange(t.shiftKey?0:f,f),this.focusedOptionIndex.set(-1)}else{let f=t.metaKey||t.ctrlKey,D=this.findLastFocusedOptionIndex();t.shiftKey&&f&&this.onOptionSelectRange(t,this.startRangeIndex(),D),this.changeFocusedOptionIndex(t,D),!this.overlayVisible&&this.show()}t.preventDefault()}onPageDownKey(t){this.scrollInView(this.visibleOptions().length-1),t.preventDefault()}onPageUpKey(t){this.scrollInView(0),t.preventDefault()}onEnterKey(t){this.overlayVisible?-1!==this.focusedOptionIndex()&&(t.shiftKey?this.onOptionSelectRange(t,this.focusedOptionIndex()):this.onOptionSelect({originalEvent:t,option:this.visibleOptions()[this.focusedOptionIndex()]})):this.onArrowDownKey(t),t.preventDefault()}onEscapeKey(t){this.overlayVisible&&this.hide(!0),t.preventDefault()}onDeleteKey(t){this.showClear&&(this.clear(t),t.preventDefault())}onTabKey(t,n=!1){n||(this.overlayVisible&&this.hasFocusableElements()?(xr.focus(t.shiftKey?this.lastHiddenFocusableElementOnOverlay.nativeElement:this.firstHiddenFocusableElementOnOverlay.nativeElement),t.preventDefault()):(-1!==this.focusedOptionIndex()&&this.onOptionSelect({originalEvent:t,option:this.visibleOptions()[this.focusedOptionIndex()]}),this.overlayVisible&&this.hide(this.filter)))}onShiftKey(){this.startRangeIndex.set(this.focusedOptionIndex())}onContainerClick(t){if(!(this.disabled||this.loading||this.readonly||t.target.isSameNode(this.focusInputViewChild?.nativeElement))){if("INPUT"===t.target.tagName||"clearicon"===t.target.getAttribute("data-pc-section")||t.target.closest('[data-pc-section="clearicon"]'))return void t.preventDefault();if(!this.overlayViewChild||!this.overlayViewChild.el.nativeElement.contains(t.target)){if(this.clickInProgress)return;this.clickInProgress=!0,setTimeout(()=>{this.clickInProgress=!1},150),this.overlayVisible?this.hide(!0):this.show(!0)}this.focusInputViewChild?.nativeElement.focus({preventScroll:!0}),this.onClick.emit(t),this.cd.detectChanges()}}onFirstHiddenFocus(t){const n=t.relatedTarget===this.focusInputViewChild?.nativeElement?xr.getFirstFocusableElement(this.overlayViewChild?.overlayViewChild?.nativeElement,':not([data-p-hidden-focusable="true"])'):this.focusInputViewChild?.nativeElement;xr.focus(n)}onInputFocus(t){this.focused=!0;const n=-1!==this.focusedOptionIndex()?this.focusedOptionIndex():this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1;this.focusedOptionIndex.set(n),this.overlayVisible&&this.scrollInView(this.focusedOptionIndex()),this.onFocus.emit({originalEvent:t})}onInputBlur(t){this.focused=!1,this.onBlur.emit({originalEvent:t}),this.preventModelTouched||this.onModelTouched(),this.preventModelTouched=!1}onFilterInputChange(t){this._filterValue.set(t.target.value),this.focusedOptionIndex.set(-1),this.onFilter.emit({originalEvent:t,filter:this._filterValue()}),!this.virtualScrollerDisabled&&this.scroller.scrollToIndex(0),setTimeout(()=>{this.overlayViewChild.alignOverlay()})}onLastHiddenFocus(t){const n=t.relatedTarget===this.focusInputViewChild?.nativeElement?xr.getLastFocusableElement(this.overlayViewChild?.overlayViewChild?.nativeElement,':not([data-p-hidden-focusable="true"])'):this.focusInputViewChild?.nativeElement;xr.focus(n)}onOptionMouseEnter(t,n){this.focusOnHover&&this.changeFocusedOptionIndex(t,n)}onHeaderCheckboxKeyDown(t){if(this.disabled)t.preventDefault();else switch(t.code){case"Space":case"Enter":this.onToggleAll(t)}}onFilterBlur(t){this.focusedOptionIndex.set(-1)}onHeaderCheckboxFocus(){this.headerCheckboxFocus=!0}onHeaderCheckboxBlur(){this.headerCheckboxFocus=!1}onToggleAll(t){if(!this.disabled&&!this.readonly){if(null!=this.selectAll)this.onSelectAllChange.emit({originalEvent:t,checked:!this.allSelected()});else{const f=[...this.getAllVisibleAndNonVisibleOptions().filter(j=>this.isSelected(j)&&(this.optionDisabled?ro.resolveFieldData(j,this.optionDisabled):!(!j||void 0===j.disabled)&&j.disabled)),...this.allSelected()?this.visibleOptions().filter(j=>!this.isValidOption(j)&&this.isSelected(j)):this.visibleOptions().filter(j=>this.isSelected(j)||this.isValidOption(j))].map(j=>this.getOptionValue(j)),D=[...new Set(f)];this.updateModel(D,t),(!D.length||D.length===this.getAllVisibleAndNonVisibleOptions().length)&&this.onSelectAllChange.emit({originalEvent:t,checked:!!D.length})}this.partialSelected()&&(this.selectedOptions=null,this.cd.markForCheck()),this.onChange.emit({originalEvent:t,value:this.value}),xr.focus(this.headerCheckboxViewChild?.nativeElement),this.headerCheckboxFocus=!0,t.preventDefault(),t.stopPropagation()}}changeFocusedOptionIndex(t,n){this.focusedOptionIndex()!==n&&(this.focusedOptionIndex.set(n),this.scrollInView())}get virtualScrollerDisabled(){return!this.virtualScroll}scrollInView(t=-1){if(this.itemsViewChild&&this.itemsViewChild.nativeElement){const o=xr.findSingle(this.itemsViewChild.nativeElement,`li[id="${-1!==t?`${this.id}_${t}`:this.focusedOptionId}"]`);o?o.scrollIntoView&&o.scrollIntoView({block:"nearest",inline:"nearest"}):this.virtualScrollerDisabled||setTimeout(()=>{this.virtualScroll&&this.scroller?.scrollToIndex(-1!==t?t:this.focusedOptionIndex())},0)}}get focusedOptionId(){return-1!==this.focusedOptionIndex()?`${this.id}_${this.focusedOptionIndex()}`:null}writeValue(t){this.value=t,!ro.isEmpty(this.selectionLimit)&&ro.isEmpty(this.value)?this.modelValue.set([]):this.modelValue.set(this.value),this.cd.markForCheck()}registerOnChange(t){this.onModelChange=t}registerOnTouched(t){this.onModelTouched=t}setDisabledState(t){this.disabled=t,this.cd.markForCheck()}allSelected(){return null!==this.selectAll?this.selectAll:ro.isNotEmpty(this.visibleOptions())&&this.visibleOptions().every(t=>this.isOptionGroup(t)||this.isOptionDisabled(t)||this.isSelected(t))}partialSelected(){return this.selectedOptions&&this.selectedOptions.length>0&&this.selectedOptions.length<this.options.length}show(t){this.overlayVisible=!0;const n=-1!==this.focusedOptionIndex()?this.focusedOptionIndex():this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1;this.focusedOptionIndex.set(n),t&&xr.focus(this.focusInputViewChild?.nativeElement),this.cd.markForCheck()}hide(t){this.overlayVisible=!1,this.focusedOptionIndex.set(-1),this.filter&&this.resetFilterOnHide&&this.resetFilter(),"modal"===this.overlayOptions?.mode&&xr.unblockBodyScroll(),t&&xr.focus(this.focusInputViewChild?.nativeElement),this.onPanelHide.emit(),this.cd.markForCheck()}onOverlayAnimationStart(t){switch(t.toState){case"visible":if(this.itemsWrapper=xr.findSingle(this.overlayViewChild?.overlayViewChild?.nativeElement,this.virtualScroll?".p-scroller":".p-multiselect-items-wrapper"),this.virtualScroll&&this.scroller?.setContentEl(this.itemsViewChild?.nativeElement),this._options()&&this._options().length)if(this.virtualScroll){const n=ro.isNotEmpty(this.modelValue())?this.focusedOptionIndex():-1;-1!==n&&this.scroller?.scrollToIndex(n)}else{let n=xr.findSingle(this.itemsWrapper,'[data-p-highlight="true"]');n&&n.scrollIntoView({block:"nearest",inline:"nearest"})}this.filterInputChild&&this.filterInputChild.nativeElement&&(this.preventModelTouched=!0,this.autofocusFilter&&this.filterInputChild.nativeElement.focus()),this.onPanelShow.emit();case"void":this.itemsWrapper=null,this.onModelTouched()}}resetFilter(){this.filterInputChild&&this.filterInputChild.nativeElement&&(this.filterInputChild.nativeElement.value=""),this._filterValue.set(null),this._filteredOptions=null}close(t){this.hide(),t.preventDefault(),t.stopPropagation()}clear(t){this.value=null,this.updateModel(null,t),this.selectedOptions=null,this.onClear.emit(),this._disableTooltip=!0,t.stopPropagation()}labelContainerMouseLeave(){this._disableTooltip&&(this._disableTooltip=!1)}removeOption(t,n){let o=this.modelValue().filter(f=>!ro.equals(f,t,this.equalityKey()));this.updateModel(o,n),this.onChange.emit({originalEvent:n,value:o,itemValue:t}),n&&n.stopPropagation()}findNextItem(t){let n=t.nextElementSibling;return n?xr.hasClass(n.children[0],"p-disabled")||xr.isHidden(n.children[0])||xr.hasClass(n,"p-multiselect-item-group")?this.findNextItem(n):n.children[0]:null}findPrevItem(t){let n=t.previousElementSibling;return n?xr.hasClass(n.children[0],"p-disabled")||xr.isHidden(n.children[0])||xr.hasClass(n,"p-multiselect-item-group")?this.findPrevItem(n):n.children[0]:null}findNextOptionIndex(t){const n=t<this.visibleOptions().length-1?this.visibleOptions().slice(t+1).findIndex(o=>this.isValidOption(o)):-1;return n>-1?n+t+1:t}findPrevOptionIndex(t){const n=t>0?ro.findLastIndex(this.visibleOptions().slice(0,t),o=>this.isValidOption(o)):-1;return n>-1?n:t}findLastSelectedOptionIndex(){return this.hasSelectedOption()?ro.findLastIndex(this.visibleOptions(),t=>this.isValidSelectedOption(t)):-1}findLastFocusedOptionIndex(){const t=this.findLastSelectedOptionIndex();return t<0?this.findLastOptionIndex():t}findLastOptionIndex(){return ro.findLastIndex(this.visibleOptions(),t=>this.isValidOption(t))}searchOptions(t,n){this.searchValue=(this.searchValue||"")+n;let o=-1,f=!1;return-1!==this.focusedOptionIndex()?(o=this.visibleOptions().slice(this.focusedOptionIndex()).findIndex(D=>this.isOptionMatched(D)),o=-1===o?this.visibleOptions().slice(0,this.focusedOptionIndex()).findIndex(D=>this.isOptionMatched(D)):o+this.focusedOptionIndex()):o=this.visibleOptions().findIndex(D=>this.isOptionMatched(D)),-1!==o&&(f=!0),-1===o&&-1===this.focusedOptionIndex()&&(o=this.findFirstFocusedOptionIndex()),-1!==o&&this.changeFocusedOptionIndex(t,o),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500),f}activateFilter(){if(this.hasFilter()&&this._options)if(this.group){let t=[];for(let n of this.options){let o=this.filterService.filter(this.getOptionGroupChildren(n),this.searchFields(),this.filterValue,this.filterMatchMode,this.filterLocale);o&&o.length&&t.push({...n,[this.optionGroupChildren]:o})}this._filteredOptions=t}else this._filteredOptions=this.filterService.filter(this.options,this.searchFields(),this.filterValue,this.filterMatchMode,this.filterLocale);else this._filteredOptions=null}hasFocusableElements(){return xr.getFocusableElements(this.overlayViewChild.overlayViewChild.nativeElement,':not([data-p-hidden-focusable="true"])').length>0}hasFilter(){return this._filterValue()&&this._filterValue().trim().length>0}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(yg),e.\u0275\u0275directiveInject(mf),e.\u0275\u0275directiveInject(xv))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-multiSelect"]],contentQueries:function(n,o,f){if(1&n&&(e.\u0275\u0275contentQuery(f,Ch,5),e.\u0275\u0275contentQuery(f,U_,5),e.\u0275\u0275contentQuery(f,Zc,4)),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.footerFacet=D.first),e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.headerFacet=D.first),e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(Gl,5),e.\u0275\u0275viewQuery(zu,5),e.\u0275\u0275viewQuery(Bd,5),e.\u0275\u0275viewQuery(th,5),e.\u0275\u0275viewQuery(V,5),e.\u0275\u0275viewQuery(Qe,5),e.\u0275\u0275viewQuery(E,5),e.\u0275\u0275viewQuery(U,5),e.\u0275\u0275viewQuery(ee,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.containerViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.overlayViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.filterInputChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.focusInputViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.itemsViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.scroller=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.lastHiddenFocusableElementOnOverlay=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.firstHiddenFocusableElementOnOverlay=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.headerCheckboxViewChild=f.first)}},hostAttrs:[1,"p-element","p-inputwrapper"],hostVars:4,hostBindings:function(n,o){2&n&&e.\u0275\u0275classProp("p-inputwrapper-focus",o.focused||o.overlayVisible)("p-inputwrapper-filled",o.filled)},inputs:{id:"id",ariaLabel:"ariaLabel",style:"style",styleClass:"styleClass",panelStyle:"panelStyle",panelStyleClass:"panelStyleClass",inputId:"inputId",disabled:[2,"disabled","disabled",e.booleanAttribute],readonly:[2,"readonly","readonly",e.booleanAttribute],group:[2,"group","group",e.booleanAttribute],filter:[2,"filter","filter",e.booleanAttribute],filterPlaceHolder:"filterPlaceHolder",filterLocale:"filterLocale",overlayVisible:[2,"overlayVisible","overlayVisible",e.booleanAttribute],tabindex:[2,"tabindex","tabindex",e.numberAttribute],variant:"variant",appendTo:"appendTo",dataKey:"dataKey",name:"name",ariaLabelledBy:"ariaLabelledBy",displaySelectedLabel:"displaySelectedLabel",maxSelectedLabels:"maxSelectedLabels",selectionLimit:[2,"selectionLimit","selectionLimit",t=>(0,e.numberAttribute)(t,null)],selectedItemsLabel:"selectedItemsLabel",showToggleAll:[2,"showToggleAll","showToggleAll",e.booleanAttribute],emptyFilterMessage:"emptyFilterMessage",emptyMessage:"emptyMessage",resetFilterOnHide:[2,"resetFilterOnHide","resetFilterOnHide",e.booleanAttribute],dropdownIcon:"dropdownIcon",optionLabel:"optionLabel",optionValue:"optionValue",optionDisabled:"optionDisabled",optionGroupLabel:"optionGroupLabel",optionGroupChildren:"optionGroupChildren",showHeader:[2,"showHeader","showHeader",e.booleanAttribute],filterBy:"filterBy",scrollHeight:"scrollHeight",lazy:[2,"lazy","lazy",e.booleanAttribute],virtualScroll:[2,"virtualScroll","virtualScroll",e.booleanAttribute],loading:[2,"loading","loading",e.booleanAttribute],virtualScrollItemSize:[2,"virtualScrollItemSize","virtualScrollItemSize",e.numberAttribute],loadingIcon:"loadingIcon",virtualScrollOptions:"virtualScrollOptions",overlayOptions:"overlayOptions",ariaFilterLabel:"ariaFilterLabel",filterMatchMode:"filterMatchMode",tooltip:"tooltip",tooltipPosition:"tooltipPosition",tooltipPositionStyle:"tooltipPositionStyle",tooltipStyleClass:"tooltipStyleClass",autofocusFilter:[2,"autofocusFilter","autofocusFilter",e.booleanAttribute],display:"display",autocomplete:"autocomplete",showClear:[2,"showClear","showClear",e.booleanAttribute],autofocus:[2,"autofocus","autofocus",e.booleanAttribute],autoZIndex:"autoZIndex",baseZIndex:"baseZIndex",showTransitionOptions:"showTransitionOptions",hideTransitionOptions:"hideTransitionOptions",defaultLabel:"defaultLabel",placeholder:"placeholder",options:"options",filterValue:"filterValue",itemSize:"itemSize",selectAll:"selectAll",focusOnHover:[2,"focusOnHover","focusOnHover",e.booleanAttribute],filterFields:"filterFields",selectOnFocus:[2,"selectOnFocus","selectOnFocus",e.booleanAttribute],autoOptionFocus:[2,"autoOptionFocus","autoOptionFocus",e.booleanAttribute]},outputs:{onChange:"onChange",onFilter:"onFilter",onFocus:"onFocus",onBlur:"onBlur",onClick:"onClick",onClear:"onClear",onPanelShow:"onPanelShow",onPanelHide:"onPanelHide",onLazyLoad:"onLazyLoad",onRemove:"onRemove",onSelectAllChange:"onSelectAllChange"},features:[e.\u0275\u0275ProvidersFeature([Ap]),e.\u0275\u0275InputTransformsFeature],ngContentSelectors:Nt,decls:17,vars:44,consts:[["container",""],["focusInput",""],["elseBlock",""],["overlay",""],["token",""],["firstHiddenFocusableEl",""],["buildInItems",""],["lastHiddenFocusableEl",""],["builtInFilterElement",""],["headerCheckbox",""],["filterInput",""],["scroller",""],["items",""],["emptyFilter",""],["empty",""],[3,"click","ngClass","ngStyle"],[1,"p-hidden-accessible"],["role","combobox","pAutoFocus","",3,"focus","blur","keydown","pTooltip","tooltipPosition","positionStyle","tooltipStyleClass","autofocus"],[1,"p-multiselect-label-container",3,"mouseleave","pTooltip","tooltipDisabled","tooltipPosition","positionStyle","tooltipStyleClass"],[3,"ngClass"],[4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"p-multiselect-trigger"],[4,"ngIf","ngIfElse"],[3,"visibleChange","onAnimationStart","onHide","visible","options","target","appendTo","autoZIndex","baseZIndex","showTransitionOptions","hideTransitionOptions"],["pTemplate","content"],["class","p-multiselect-token",4,"ngFor","ngForOf"],[1,"p-multiselect-token"],[1,"p-multiselect-token-label"],[3,"ngClass","styleClass","click",4,"ngIf"],["class","p-multiselect-token-icon",3,"click",4,"ngIf"],[3,"click","ngClass","styleClass"],[1,"p-multiselect-token-icon",3,"click"],[4,"ngTemplateOutlet"],[3,"styleClass","click",4,"ngIf"],["class","p-multiselect-clear-icon",3,"click",4,"ngIf"],[3,"click","styleClass"],[1,"p-multiselect-clear-icon",3,"click"],["aria-hidden","true",3,"ngClass",4,"ngIf"],["aria-hidden","true",3,"class",4,"ngIf"],["aria-hidden","true",3,"ngClass"],["aria-hidden","true"],["class","p-multiselect-trigger-icon",4,"ngIf"],["class","p-multiselect-trigger-icon",3,"ngClass",4,"ngIf"],[3,"styleClass",4,"ngIf"],[1,"p-multiselect-trigger-icon",3,"ngClass"],[3,"styleClass"],[1,"p-multiselect-trigger-icon"],[3,"ngClass","ngStyle"],["role","presentation",1,"p-hidden-accessible","p-hidden-focusable",3,"focus"],["class","p-multiselect-header",4,"ngIf"],[1,"p-multiselect-items-wrapper",3,"ngStyle"],[3,"items","style","itemSize","autoSize","tabindex","lazy","options","onLazyLoad",4,"ngIf"],["class","p-multiselect-footer",4,"ngIf"],[1,"p-multiselect-header"],["class","p-checkbox p-component",3,"ngClass","click","keydown",4,"ngIf"],["class","p-multiselect-filter-container",4,"ngIf"],["type","button","pRipple","",1,"p-multiselect-close","p-link","p-button-icon-only",3,"click"],["class","p-multiselect-close-icon",4,"ngIf"],[1,"p-checkbox","p-component",3,"click","keydown","ngClass"],["type","checkbox",3,"focus","blur","readonly","disabled"],["role","checkbox",1,"p-checkbox-box",3,"ngClass"],["class","p-checkbox-icon",4,"ngIf"],[1,"p-checkbox-icon"],[1,"p-multiselect-filter-container"],["type","text","role","searchbox","role","searchbox",1,"p-multiselect-filter","p-inputtext","p-component",3,"input","keydown","click","blur","value","disabled"],["class","p-multiselect-filter-icon",4,"ngIf"],[1,"p-multiselect-filter-icon"],[1,"p-multiselect-close-icon"],[3,"onLazyLoad","items","itemSize","autoSize","tabindex","lazy","options"],["pTemplate","loader"],["role","listbox","aria-multiselectable","true",1,"p-multiselect-items","p-component",3,"ngClass","ngStyle"],["ngFor","",3,"ngForOf"],["class","p-multiselect-empty-message","role","option",3,"ngStyle",4,"ngIf"],["role","option",1,"p-multiselect-item-group",3,"ngStyle"],[3,"onClick","onMouseEnter","id","option","selected","label","disabled","template","checkIconTemplate","itemCheckboxIconTemplate","itemSize","focused","ariaPosInset","ariaSetSize"],["role","option",1,"p-multiselect-empty-message",3,"ngStyle"],[1,"p-multiselect-footer"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275projectionDef(Xe),e.\u0275\u0275elementStart(0,"div",15,0),e.\u0275\u0275listener("click",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onContainerClick(j))}),e.\u0275\u0275elementStart(2,"div",16)(3,"input",17,1),e.\u0275\u0275listener("focus",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputFocus(j))})("blur",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputBlur(j))})("keydown",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onKeyDown(j))}),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(5,"div",18),e.\u0275\u0275listener("mouseleave",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.labelContainerMouseLeave())}),e.\u0275\u0275elementStart(6,"div",19),e.\u0275\u0275template(7,em,3,2,"ng-container",20)(8,o1,1,0,"ng-container",21),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(9,wg,3,2,"ng-container",20),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(10,"div",22),e.\u0275\u0275template(11,P,3,2,"ng-container",23)(12,wn,2,2,"ng-template",null,2,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(14,"p-overlay",24,3),e.\u0275\u0275twoWayListener("visibleChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.overlayVisible,j)||(o.overlayVisible=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275listener("onAnimationStart",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onOverlayAnimationStart(j))})("onHide",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.hide())}),e.\u0275\u0275template(16,ux,12,18,"ng-template",25),e.\u0275\u0275elementEnd()()}if(2&n){let f;const D=e.\u0275\u0275reference(13);e.\u0275\u0275classMap(o.styleClass),e.\u0275\u0275property("ngClass",o.containerClass)("ngStyle",o.style),e.\u0275\u0275attribute("id",o.id),e.\u0275\u0275advance(2),e.\u0275\u0275attribute("data-p-hidden-accessible",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("pTooltip",o.tooltip)("tooltipPosition",o.tooltipPosition)("positionStyle",o.tooltipPositionStyle)("tooltipStyleClass",o.tooltipStyleClass)("autofocus",o.autofocus),e.\u0275\u0275attribute("aria-disabled",o.disabled)("id",o.inputId)("aria-label",o.ariaLabel)("aria-labelledby",o.ariaLabelledBy)("aria-haspopup","listbox")("aria-expanded",null!==(f=o.overlayVisible)&&void 0!==f&&f)("aria-controls",o.overlayVisible?o.id+"_list":null)("tabindex",o.disabled?-1:o.tabindex)("aria-activedescendant",o.focused?o.focusedOptionId:void 0)("value",o.label()||"empty"),e.\u0275\u0275advance(2),e.\u0275\u0275property("pTooltip",o.tooltip)("tooltipDisabled",o._disableTooltip)("tooltipPosition",o.tooltipPosition)("positionStyle",o.tooltipPositionStyle)("tooltipStyleClass",o.tooltipStyleClass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",o.labelClass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.selectedItemsTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",o.selectedItemsTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(41,Ei,o.selectedOptions,o.removeOption.bind(o))),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isVisibleClearIcon),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.loading)("ngIfElse",D),e.\u0275\u0275advance(3),e.\u0275\u0275twoWayProperty("visible",o.overlayVisible),e.\u0275\u0275property("options",o.overlayOptions)("target","@parent")("appendTo",o.appendTo)("autoZIndex",o.autoZIndex)("baseZIndex",o.baseZIndex)("showTransitionOptions",o.showTransitionOptions)("hideTransitionOptions",o.hideTransitionOptions)}},dependencies:()=>[ve.NgClass,ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,va,Zc,H_,Bs,mu,km,yd,Rm,Lm,Sh,Dg,_E],styles:["@layer primeng{.p-multiselect{display:inline-flex;cursor:pointer;position:relative;-webkit-user-select:none;user-select:none}.p-multiselect-trigger{display:flex;align-items:center;justify-content:center;flex-shrink:0}.p-multiselect-label-container{overflow:hidden;flex:1 1 auto;cursor:pointer;display:flex}.p-multiselect-label{display:block;white-space:nowrap;cursor:pointer;overflow:hidden;text-overflow:ellipsis}.p-multiselect-label-empty{overflow:hidden;visibility:hidden}.p-multiselect-token{cursor:default;display:inline-flex;align-items:center;flex:0 0 auto}.p-multiselect-token-icon{cursor:pointer}.p-multiselect-token-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100px}.p-multiselect-items-wrapper{overflow:auto}.p-multiselect-items{margin:0;padding:0;list-style-type:none}.p-multiselect-item{cursor:pointer;display:flex;align-items:center;font-weight:400;white-space:nowrap;position:relative;overflow:hidden}.p-multiselect-header{display:flex;align-items:center;justify-content:space-between}.p-multiselect-filter-container{position:relative;flex:1 1 auto}.p-multiselect-filter-icon{position:absolute;top:50%;margin-top:-.5rem}.p-multiselect-filter-container .p-inputtext{width:100%}.p-multiselect-close{display:flex;align-items:center;justify-content:center;flex-shrink:0;overflow:hidden;position:relative}.p-fluid .p-multiselect{display:flex}.p-multiselect-clear-icon{position:absolute;top:50%;margin-top:-.5rem;cursor:pointer}.p-multiselect-clearable{position:relative}}\n"],encapsulation:2,changeDetection:0})}return r})(),mr=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,bc,Tu,Ff,wh,Zh,Nf,yd,Rm,Lm,Sh,Dg,yd,Jp,bc,Tu,Zh]})}return r})();var Ua=S(505),Op=S(1975);let oD=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["BlankIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:0,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg","v-bind","pti()"],["width","1","height","1","fill","currentColor","fill-opacity","0"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"rect",1),e.\u0275\u0275elementEnd())},encapsulation:2})}return r})();const Pl=r=>({height:r}),dx=(r,v,t)=>({"p-dropdown-item":!0,"p-highlight":r,"p-disabled":v,"p-focus":t}),fa=r=>({$implicit:r});function Ih(r,v){1&r&&e.\u0275\u0275element(0,"CheckIcon",4),2&r&&e.\u0275\u0275property("styleClass","p-dropdown-check-icon")}function sD(r,v){1&r&&e.\u0275\u0275element(0,"BlankIcon",4),2&r&&e.\u0275\u0275property("styleClass","p-dropdown-blank-icon")}function aD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Ih,1,1,"CheckIcon",3)(2,sD,1,1,"BlankIcon",3),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.selected),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.selected)}}function a1(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){let t;const n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(null!==(t=n.label)&&void 0!==t?t:"empty")}}function yE(r,v){1&r&&e.\u0275\u0275elementContainer(0)}const xA=["container"],I0=["filter"],fx=["focusInput"],bE=["editableInput"],nf=["items"],_f=["scroller"],lD=["overlay"],Fp=["firstHiddenFocusableEl"],Eg=["lastHiddenFocusableEl"],cD=r=>({"max-height":r}),uD=r=>({options:r}),CE=r=>({"p-variant-filled":r}),px=(r,v)=>({$implicit:r,options:v}),Fv=()=>({});function dD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate("p-emptylabel"===t.label()?"\xa0":t.label())}}function Ah(r,v){if(1&r&&e.\u0275\u0275elementContainer(0,25),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngTemplateOutlet",t.selectedItemTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,fa,t.selectedOption))}}function K_(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate("p-emptylabel"===t.label()?"\xa0":t.label())}}function q_(r,v){if(1&r&&e.\u0275\u0275template(0,K_,2,1,"span",18),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngIf",t.isSelectedOptionEmpty())}}function hx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",23,3),e.\u0275\u0275listener("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onInputFocus(o))})("blur",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onInputBlur(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onKeyDown(o))}),e.\u0275\u0275template(2,dD,2,1,"ng-container",20)(3,Ah,1,4,"ng-container",24)(4,q_,1,1,"ng-template",null,4,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()}if(2&r){let t;const n=e.\u0275\u0275reference(5),o=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",o.inputClass)("pTooltip",o.tooltip)("tooltipPosition",o.tooltipPosition)("positionStyle",o.tooltipPositionStyle)("tooltipStyleClass",o.tooltipStyleClass)("autofocus",o.autofocus),e.\u0275\u0275attribute("aria-disabled",o.disabled)("id",o.inputId)("aria-label",o.ariaLabel||("p-emptylabel"===o.label()?void 0:o.label()))("aria-labelledby",o.ariaLabelledBy)("aria-haspopup","listbox")("aria-expanded",null!==(t=o.overlayVisible)&&void 0!==t&&t)("aria-controls",o.overlayVisible?o.id+"_list":null)("tabindex",o.disabled?-1:o.tabindex)("aria-activedescendant",o.focused?o.focusedOptionId:void 0)("aria-required",o.required)("required",o.required),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.selectedItemTemplate)("ngIfElse",n),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.selectedItemTemplate&&!o.isSelectedOptionEmpty())}}function Vm(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"input",26,5),e.\u0275\u0275listener("input",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onEditableInput(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onKeyDown(o))})("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onInputFocus(o))})("blur",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onInputBlur(o))}),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",t.inputClass)("disabled",t.disabled)("autofocus",t.autofocus),e.\u0275\u0275attribute("id",t.inputId)("maxlength",t.maxlength)("placeholder",void 0===t.modelValue()||null===t.modelValue()?t.placeholder():void 0)("aria-label",t.ariaLabel||("p-emptylabel"===t.label()?void 0:t.label()))("aria-activedescendant",t.focused?t.focusedOptionId:void 0)}}function l1(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"TimesIcon",29),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.clear(o))}),e.\u0275\u0275elementEnd()}2&r&&(e.\u0275\u0275property("styleClass","p-dropdown-clear-icon"),e.\u0275\u0275attribute("data-pc-section","clearicon"))}function fD(r,v){}function mx(r,v){1&r&&e.\u0275\u0275template(0,fD,0,0,"ng-template")}function Tg(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",30),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.clear(o))}),e.\u0275\u0275template(1,mx,1,0,null,31),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("data-pc-section","clearicon"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.clearIconTemplate)}}function Mg(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,l1,1,2,"TimesIcon",27)(2,Tg,2,2,"span",28),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.clearIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.clearIconTemplate)}}function DE(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Vd(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,DE,1,0,"ng-container",31),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.loadingIconTemplate)}}function Ig(r,v){if(1&r&&e.\u0275\u0275element(0,"span",34),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass","p-dropdown-trigger-icon pi-spin "+t.loadingIcon)}}function Au(r,v){1&r&&e.\u0275\u0275element(0,"span",35),2&r&&e.\u0275\u0275classMap("p-dropdown-trigger-icon pi pi-spinner pi-spin")}function A0(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Ig,1,1,"span",32)(2,Au,1,2,"span",33),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loadingIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIcon)}}function Zf(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Vd,2,1,"ng-container",18)(2,A0,3,2,"ng-container",18),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loadingIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIconTemplate)}}function pD(r,v){if(1&r&&e.\u0275\u0275element(0,"span",39),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass",t.dropdownIcon)}}function Nv(r,v){1&r&&e.\u0275\u0275element(0,"ChevronDownIcon",40),2&r&&e.\u0275\u0275property("styleClass","p-dropdown-trigger-icon")}function c1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,pD,1,1,"span",37)(2,Nv,1,1,"ChevronDownIcon",38),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dropdownIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.dropdownIcon)}}function gx(r,v){}function Rv(r,v){1&r&&e.\u0275\u0275template(0,gx,0,0,"ng-template")}function jm(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",41),e.\u0275\u0275template(1,Rv,1,0,null,31),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.dropdownIconTemplate)}}function u1(r,v){if(1&r&&e.\u0275\u0275template(0,c1,3,2,"ng-container",18)(1,jm,2,1,"span",36),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngIf",!t.dropdownIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dropdownIconTemplate)}}function hD(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Q_(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function d1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Q_,1,0,"ng-container",48),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.filterTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,uD,t.filterOptions))}}function Lv(r,v){1&r&&e.\u0275\u0275element(0,"SearchIcon",40),2&r&&e.\u0275\u0275property("styleClass","p-dropdown-filter-icon")}function Np(r,v){}function Y_(r,v){1&r&&e.\u0275\u0275template(0,Np,0,0,"ng-template")}function wE(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",52),e.\u0275\u0275template(1,Y_,1,0,null,31),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.filterIconTemplate)}}function kv(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",49)(1,"input",50,10),e.\u0275\u0275listener("input",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.onFilterInputChange(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.onFilterKeyDown(o))})("blur",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.onFilterBlur(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,Lv,1,1,"SearchIcon",38)(4,wE,2,1,"span",51),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("value",t._filterValue()||"")("ngClass",e.\u0275\u0275pureFunction1(8,CE,"filled"===t.variant||"filled"===t.config.inputStyle())),e.\u0275\u0275attribute("placeholder",t.filterPlaceholder)("aria-owns",t.id+"_list")("aria-label",t.ariaFilterLabel)("aria-activedescendant",t.focusedOptionId),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!t.filterIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.filterIconTemplate)}}function O0(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",47),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275template(1,d1,2,4,"ng-container",20)(2,kv,5,10,"ng-template",null,9,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275reference(3),n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.filterTemplate)("ngIfElse",t)}}function F0(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function f1(r,v){if(1&r&&e.\u0275\u0275template(0,F0,1,0,"ng-container",48),2&r){const t=v.$implicit,n=v.options;e.\u0275\u0275nextContext(2);const o=e.\u0275\u0275reference(9);e.\u0275\u0275property("ngTemplateOutlet",o)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(2,px,t,n))}}function _u(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Um(r,v){if(1&r&&e.\u0275\u0275template(0,_u,1,0,"ng-container",48),2&r){const t=v.options,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("ngTemplateOutlet",n.loaderTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,uD,t))}}function DM(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Um,1,4,"ng-template",54),e.\u0275\u0275elementContainerEnd())}function vx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"p-scroller",53,11),e.\u0275\u0275listener("onLazyLoad",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onLazyLoad.emit(o))}),e.\u0275\u0275template(2,f1,1,5,"ng-template",22)(3,DM,2,0,"ng-container",18),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275styleMap(e.\u0275\u0275pureFunction1(8,Pl,t.scrollHeight)),e.\u0275\u0275property("items",t.visibleOptions())("itemSize",t.virtualScrollItemSize||t._itemSize)("autoSize",!0)("lazy",t.lazy)("options",t.virtualScrollOptions),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.loaderTemplate)}}function mD(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function gD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,mD,1,0,"ng-container",48),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(9),n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(3,px,n.visibleOptions(),e.\u0275\u0275pureFunction0(2,Fv)))}}function nm(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(n.getOptionGroupLabel(t.optionGroup))}}function X_(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function $m(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",58),e.\u0275\u0275template(2,nm,2,1,"span",18)(3,X_,1,0,"ng-container",48),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext().options,D=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(5,Pl,f.itemSize+"px")),e.\u0275\u0275attribute("id",D.id+"_"+D.getOptionIndex(o,f)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!D.groupTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",D.groupTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(7,fa,n.optionGroup))}}function im(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"p-dropdownItem",59),e.\u0275\u0275listener("onClick",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext().$implicit,D=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(D.onOptionSelect(o,f))})("onMouseEnter",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext().index,D=e.\u0275\u0275nextContext().options,j=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(j.onOptionMouseEnter(o,j.getOptionIndex(f,D)))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext().options,D=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("id",D.id+"_"+D.getOptionIndex(o,f))("option",n)("checkmark",D.checkmark)("selected",D.isSelected(n))("label",D.getOptionLabel(n))("disabled",D.isOptionDisabled(n))("template",D.itemTemplate)("focused",D.focusedOptionIndex()===D.getOptionIndex(o,f))("ariaPosInset",D.getAriaPosInset(D.getOptionIndex(o,f)))("ariaSetSize",D.ariaSetSize)}}function xE(r,v){if(1&r&&e.\u0275\u0275template(0,$m,4,9,"ng-container",18)(1,im,2,10,"ng-container",18),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngIf",n.isOptionGroup(t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.isOptionGroup(t))}}function Oh(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.emptyFilterMessageLabel," ")}}function N0(r,v){1&r&&e.\u0275\u0275elementContainer(0,null,13)}function R0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",60),e.\u0275\u0275template(1,Oh,2,1,"ng-container",20)(2,N0,2,0,"ng-container",31),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().options,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(4,Pl,t.itemSize+"px")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.emptyFilterTemplate&&!n.emptyTemplate)("ngIfElse",n.emptyFilter),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n.emptyFilterTemplate||n.emptyTemplate)}}function vD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.emptyMessageLabel," ")}}function _D(r,v){1&r&&e.\u0275\u0275elementContainer(0,null,14)}function _x(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",60),e.\u0275\u0275template(1,vD,2,1,"ng-container",20)(2,_D,2,0,"ng-container",31),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().options,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(4,Pl,t.itemSize+"px")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.emptyTemplate)("ngIfElse",n.empty),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n.emptyTemplate)}}function yx(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"ul",55,12),e.\u0275\u0275template(2,xE,2,2,"ng-template",56)(3,R0,3,6,"li",57)(4,_x,3,6,"li",57),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.options,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",n.contentStyleClass)("ngStyle",n.contentStyle),e.\u0275\u0275attribute("id",o.id+"_list")("aria-label",o.listLabel),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.filterValue&&o.isEmpty()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.filterValue&&o.isEmpty())}}function p1(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Fh(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",42)(1,"span",43,6),e.\u0275\u0275listener("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onFirstHiddenFocus(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,hD,1,0,"ng-container",31)(4,O0,4,2,"div",44),e.\u0275\u0275elementStart(5,"div",45),e.\u0275\u0275template(6,vx,4,10,"p-scroller",46)(7,gD,2,6,"ng-container",18)(8,yx,5,7,"ng-template",null,7,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(10,p1,1,0,"ng-container",31),e.\u0275\u0275elementStart(11,"span",43,8),e.\u0275\u0275listener("focus",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onLastHiddenFocus(o))}),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.panelStyleClass),e.\u0275\u0275property("ngClass","p-dropdown-panel p-component")("ngStyle",t.panelStyle),e.\u0275\u0275advance(),e.\u0275\u0275attribute("tabindex",0)("data-p-hidden-accessible",!0)("data-p-hidden-focusable",!0),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",t.headerTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.filter),e.\u0275\u0275advance(),e.\u0275\u0275property("ngStyle",e.\u0275\u0275pureFunction1(16,cD,t.virtualScroll?"auto":t.scrollHeight||"auto")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.virtualScroll),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.virtualScroll),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngTemplateOutlet",t.footerTemplate),e.\u0275\u0275advance(),e.\u0275\u0275attribute("tabindex",0)("data-p-hidden-accessible",!0)("data-p-hidden-focusable",!0)}}const bx={provide:Ji.NG_VALUE_ACCESSOR,useExisting:(0,e.forwardRef)(()=>Z_),multi:!0};let Pv=(()=>{class r{id;option;selected;focused;label;disabled;visible;itemSize;ariaPosInset;ariaSetSize;template;checkmark;onClick=new e.EventEmitter;onMouseEnter=new e.EventEmitter;ngOnInit(){}onOptionClick(t){this.onClick.emit(t)}onOptionMouseEnter(t){this.onMouseEnter.emit(t)}static \u0275fac=function(n){return new(n||r)};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-dropdownItem"]],hostAttrs:[1,"p-element"],inputs:{id:"id",option:"option",selected:[2,"selected","selected",e.booleanAttribute],focused:[2,"focused","focused",e.booleanAttribute],label:"label",disabled:[2,"disabled","disabled",e.booleanAttribute],visible:[2,"visible","visible",e.booleanAttribute],itemSize:[2,"itemSize","itemSize",e.numberAttribute],ariaPosInset:"ariaPosInset",ariaSetSize:"ariaSetSize",template:"template",checkmark:[2,"checkmark","checkmark",e.booleanAttribute]},outputs:{onClick:"onClick",onMouseEnter:"onMouseEnter"},features:[e.\u0275\u0275InputTransformsFeature],decls:4,vars:22,consts:[["role","option","pRipple","",3,"click","mouseenter","id","ngStyle","ngClass"],[4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"styleClass",4,"ngIf"],[3,"styleClass"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"li",0),e.\u0275\u0275listener("click",function(D){return o.onOptionClick(D)})("mouseenter",function(D){return o.onOptionMouseEnter(D)}),e.\u0275\u0275template(1,aD,3,2,"ng-container",1)(2,a1,2,1,"span",1)(3,yE,1,0,"ng-container",2),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("id",o.id)("ngStyle",e.\u0275\u0275pureFunction1(14,Pl,o.itemSize+"px"))("ngClass",e.\u0275\u0275pureFunction3(16,dx,o.selected,o.disabled,o.focused)),e.\u0275\u0275attribute("aria-label",o.label)("aria-setsize",o.ariaSetSize)("aria-posinset",o.ariaPosInset)("aria-selected",o.selected)("data-p-focused",o.focused)("data-p-highlight",o.selected)("data-p-disabled",o.disabled),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.checkmark),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.template),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",o.template)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(20,fa,o.option)))},dependencies:()=>[ve.NgClass,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,Bs,oD,yd],encapsulation:2})}return r})(),Z_=(()=>{class r{el;renderer;cd;zone;filterService;config;id;scrollHeight="200px";filter;name;style;panelStyle;styleClass;panelStyleClass;readonly;required;editable;appendTo;tabindex=0;set placeholder(t){this._placeholder.set(t)}get placeholder(){return this._placeholder.asReadonly()}loadingIcon;filterPlaceholder;filterLocale;variant="outlined";inputId;dataKey;filterBy;filterFields;autofocus;resetFilterOnHide=!1;checkmark=!1;dropdownIcon;loading=!1;optionLabel;optionValue;optionDisabled;optionGroupLabel="label";optionGroupChildren="items";autoDisplayFirst=!0;group;showClear;emptyFilterMessage="";emptyMessage="";lazy=!1;virtualScroll;virtualScrollItemSize;virtualScrollOptions;overlayOptions;ariaFilterLabel;ariaLabel;ariaLabelledBy;filterMatchMode="contains";maxlength;tooltip="";tooltipPosition="right";tooltipPositionStyle="absolute";tooltipStyleClass;focusOnHover=!1;selectOnFocus=!1;autoOptionFocus=!0;autofocusFilter=!0;get disabled(){return this._disabled}set disabled(t){t&&(this.focused=!1,this.overlayVisible&&this.hide()),this._disabled=t,this.cd.destroyed||this.cd.detectChanges()}get itemSize(){return this._itemSize}set itemSize(t){this._itemSize=t,console.warn("The itemSize property is deprecated, use virtualScrollItemSize property instead.")}_itemSize;get autoZIndex(){return this._autoZIndex}set autoZIndex(t){this._autoZIndex=t,console.warn("The autoZIndex property is deprecated since v14.2.0, use overlayOptions property instead.")}_autoZIndex;get baseZIndex(){return this._baseZIndex}set baseZIndex(t){this._baseZIndex=t,console.warn("The baseZIndex property is deprecated since v14.2.0, use overlayOptions property instead.")}_baseZIndex;get showTransitionOptions(){return this._showTransitionOptions}set showTransitionOptions(t){this._showTransitionOptions=t,console.warn("The showTransitionOptions property is deprecated since v14.2.0, use overlayOptions property instead.")}_showTransitionOptions;get hideTransitionOptions(){return this._hideTransitionOptions}set hideTransitionOptions(t){this._hideTransitionOptions=t,console.warn("The hideTransitionOptions property is deprecated since v14.2.0, use overlayOptions property instead.")}_hideTransitionOptions;get filterValue(){return this._filterValue()}set filterValue(t){setTimeout(()=>{this._filterValue.set(t)})}get options(){return this._options()}set options(t){ro.deepEquals(t,this._options())||this._options.set(t)}onChange=new e.EventEmitter;onFilter=new e.EventEmitter;onFocus=new e.EventEmitter;onBlur=new e.EventEmitter;onClick=new e.EventEmitter;onShow=new e.EventEmitter;onHide=new e.EventEmitter;onClear=new e.EventEmitter;onLazyLoad=new e.EventEmitter;containerViewChild;filterViewChild;focusInputViewChild;editableInputViewChild;itemsViewChild;scroller;overlayViewChild;firstHiddenFocusableElementOnOverlay;lastHiddenFocusableElementOnOverlay;templates;_disabled;itemsWrapper;itemTemplate;groupTemplate;loaderTemplate;selectedItemTemplate;headerTemplate;filterTemplate;footerTemplate;emptyFilterTemplate;emptyTemplate;dropdownIconTemplate;loadingIconTemplate;clearIconTemplate;filterIconTemplate;filterOptions;_options=(0,e.signal)(null);_placeholder=(0,e.signal)(void 0);modelValue=(0,e.signal)(null);value;onModelChange=()=>{};onModelTouched=()=>{};hover;focused;overlayVisible;optionsChanged;panel;dimensionsUpdated;hoveredItem;selectedOptionUpdated;_filterValue=(0,e.signal)(null);searchValue;searchIndex;searchTimeout;previousSearchChar;currentSearchChar;preventModelTouched;focusedOptionIndex=(0,e.signal)(-1);labelId;listId;clicked=(0,e.signal)(!1);get emptyMessageLabel(){return this.emptyMessage||this.config.getTranslation(If.EMPTY_MESSAGE)}get emptyFilterMessageLabel(){return this.emptyFilterMessage||this.config.getTranslation(If.EMPTY_FILTER_MESSAGE)}get isVisibleClearIcon(){return null!=this.modelValue()&&this.hasSelectedOption()&&this.showClear&&!this.disabled}get listLabel(){return this.config.getTranslation(If.ARIA).listLabel}get containerClass(){return{"p-dropdown p-component p-inputwrapper":!0,"p-disabled":this.disabled,"p-dropdown-clearable":this.showClear&&!this.disabled,"p-focus":this.focused,"p-inputwrapper-filled":void 0!==this.modelValue()&&null!==this.modelValue()&&!this.modelValue().length,"p-inputwrapper-focus":this.focused||this.overlayVisible,"p-variant-filled":"filled"===this.variant||"filled"===this.config.inputStyle(),"p-dropdown-open":this.overlayVisible}}get inputClass(){const t=this.label();return{"p-dropdown-label p-inputtext":!0,"p-placeholder":this.placeholder()&&t===this.placeholder(),"p-dropdown-label-empty":!(this.editable||this.selectedItemTemplate||null!=t&&"p-emptylabel"!==t&&0!==t.length)}}get panelClass(){return{"p-dropdown-panel p-component":!0,"p-input-filled":"filled"===this.config.inputStyle(),"p-ripple-disabled":!1===this.config.ripple}}get focusedOptionId(){return-1!==this.focusedOptionIndex()?`${this.id}_${this.focusedOptionIndex()}`:null}visibleOptions=(0,e.computed)(()=>{const t=this.getAllVisibleAndNonVisibleOptions();if(this._filterValue()){const o=this.filterBy||this.optionLabel||this.filterFields||this.optionValue?this.filterService.filter(t,this.searchFields(),this._filterValue().trim(),this.filterMatchMode,this.filterLocale):this.options.filter(f=>f.label?-1!==f.label.toString().toLowerCase().indexOf(this._filterValue().toLowerCase().trim()):-1!==f.toString().toLowerCase().indexOf(this._filterValue().toLowerCase().trim()));if(this.group){const D=[];return(this.options||[]).forEach(j=>{const Ne=this.getOptionGroupChildren(j).filter(vt=>o.includes(vt));Ne.length>0&&D.push({...j,["string"==typeof this.optionGroupChildren?this.optionGroupChildren:"items"]:[...Ne]})}),this.flatOptions(D)}return o}return t});label=(0,e.computed)(()=>{const t=this.getAllVisibleAndNonVisibleOptions(),n=t.findIndex(o=>this.isOptionValueEqualsModelValue(o));return-1!==n?this.getOptionLabel(t[n]):this.placeholder()||"p-emptylabel"});filled=(0,e.computed)(()=>"string"==typeof this.modelValue()?!!this.modelValue():"p-emptylabel"!==this.label()&&void 0!==this.modelValue()&&null!==this.modelValue());selectedOption;editableInputValue=(0,e.computed)(()=>this.getOptionLabel(this.selectedOption)||this.modelValue()||"");constructor(t,n,o,f,D,j){this.el=t,this.renderer=n,this.cd=o,this.zone=f,this.filterService=D,this.config=j,(0,e.effect)(()=>{const fe=this.modelValue(),Ne=this.visibleOptions();if(Ne&&ro.isNotEmpty(Ne)){const vt=this.findSelectedOptionIndex();(-1!==vt||void 0===fe||"string"==typeof fe&&0===fe.length||this.isModelValueNotSet()||this.editable)&&(this.selectedOption=Ne[vt])}ro.isEmpty(Ne)&&(void 0===fe||this.isModelValueNotSet())&&ro.isNotEmpty(this.selectedOption)&&(this.selectedOption=null),void 0!==fe&&this.editable&&this.updateEditableLabel(),this.cd.markForCheck()})}isModelValueNotSet(){return null===this.modelValue()&&!this.isOptionValueEqualsModelValue(this.selectedOption)}getAllVisibleAndNonVisibleOptions(){return this.group?this.flatOptions(this.options):this.options||[]}ngOnInit(){this.id=this.id||Sp(),this.autoUpdateModel(),this.filterBy&&(this.filterOptions={filter:t=>this.onFilterInputChange(t),reset:()=>this.resetFilter()})}ngAfterViewChecked(){if(this.optionsChanged&&this.overlayVisible&&(this.optionsChanged=!1,this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.overlayViewChild&&this.overlayViewChild.alignOverlay()},1)})),this.selectedOptionUpdated&&this.itemsWrapper){let t=xr.findSingle(this.overlayViewChild?.overlayViewChild?.nativeElement,"li.p-highlight");t&&xr.scrollInView(this.itemsWrapper,t),this.selectedOptionUpdated=!1}}ngAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"item":default:this.itemTemplate=t.template;break;case"selectedItem":this.selectedItemTemplate=t.template;break;case"header":this.headerTemplate=t.template;break;case"filter":this.filterTemplate=t.template;break;case"footer":this.footerTemplate=t.template;break;case"emptyfilter":this.emptyFilterTemplate=t.template;break;case"empty":this.emptyTemplate=t.template;break;case"group":this.groupTemplate=t.template;break;case"loader":this.loaderTemplate=t.template;break;case"dropdownicon":this.dropdownIconTemplate=t.template;break;case"loadingicon":this.loadingIconTemplate=t.template;break;case"clearicon":this.clearIconTemplate=t.template;break;case"filtericon":this.filterIconTemplate=t.template}})}flatOptions(t){return(t||[]).reduce((n,o,f)=>{n.push({optionGroup:o,group:!0,index:f});const D=this.getOptionGroupChildren(o);return D&&D.forEach(j=>n.push(j)),n},[])}autoUpdateModel(){if(this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption()&&(this.focusedOptionIndex.set(this.findFirstFocusedOptionIndex()),this.onOptionSelect(null,this.visibleOptions()[this.focusedOptionIndex()],!1)),this.autoDisplayFirst&&(null===this.modelValue()||void 0===this.modelValue())&&!this.placeholder()){const t=this.findFirstOptionIndex();this.onOptionSelect(null,this.visibleOptions()[t],!1,!0)}}onOptionSelect(t,n,o=!0,f=!1){if(!this.isSelected(n)){const D=this.getOptionValue(n);this.updateModel(D,t),this.focusedOptionIndex.set(this.findSelectedOptionIndex()),!1===f&&this.onChange.emit({originalEvent:t,value:D})}o&&this.hide(!0)}onOptionMouseEnter(t,n){this.focusOnHover&&this.changeFocusedOptionIndex(t,n)}updateModel(t,n){this.value=t,this.onModelChange(t),this.modelValue.set(t),this.selectedOptionUpdated=!0}writeValue(t){this.filter&&this.resetFilter(),this.value=t,this.allowModelChange()&&this.onModelChange(t),this.modelValue.set(this.value),this.updateEditableLabel(),this.cd.markForCheck()}allowModelChange(){return this.autoDisplayFirst&&!this.placeholder()&&(void 0===this.modelValue()||null===this.modelValue())&&!this.editable&&this.options&&this.options.length}isSelectedOptionEmpty(){return ro.isEmpty(this.selectedOption)}isSelected(t){return this.isValidOption(t)&&this.isOptionValueEqualsModelValue(t)}isOptionValueEqualsModelValue(t){return ro.equals(this.modelValue(),this.getOptionValue(t),this.equalityKey())}ngAfterViewInit(){this.editable&&this.updateEditableLabel(),this.updatePlaceHolderForFloatingLabel()}updatePlaceHolderForFloatingLabel(){if(null!==this._placeholder()&&void 0!==this._placeholder())return;const t=this.el.nativeElement.parentElement,n=t?.classList.contains("p-float-label");if(t&&n&&!this.selectedOption){const o=t.querySelector("label");o&&this._placeholder.set(o.textContent)}}updateEditableLabel(){this.editableInputViewChild&&(this.editableInputViewChild.nativeElement.value=this.getOptionLabel(this.selectedOption)||this.modelValue()||"")}clearEditableLabel(){this.editableInputViewChild&&(this.editableInputViewChild.nativeElement.value="")}getOptionIndex(t,n){return this.virtualScrollerDisabled?t:n&&n.getItemOptions(t).index}getOptionLabel(t){return null!=this.optionLabel?ro.resolveFieldData(t,this.optionLabel):t&&void 0!==t.label?t.label:t}getOptionValue(t){return this.optionValue&&null!==this.optionValue?ro.resolveFieldData(t,this.optionValue):!this.optionLabel&&t&&void 0!==t.value?t.value:t}isOptionDisabled(t){return!(this.getOptionValue(this.modelValue())===this.getOptionValue(t)||this.getOptionLabel(this.modelValue()===this.getOptionLabel(t))&&!1===t.disabled)&&(this.optionDisabled?ro.resolveFieldData(t,this.optionDisabled):!(!t||void 0===t.disabled)&&t.disabled)}getOptionGroupLabel(t){return null!=this.optionGroupLabel?ro.resolveFieldData(t,this.optionGroupLabel):t&&void 0!==t.label?t.label:t}getOptionGroupChildren(t){return null!=this.optionGroupChildren?ro.resolveFieldData(t,this.optionGroupChildren):t.items}getAriaPosInset(t){return(this.optionGroupLabel?t-this.visibleOptions().slice(0,t).filter(n=>this.isOptionGroup(n)).length:t)+1}get ariaSetSize(){return this.visibleOptions().filter(t=>!this.isOptionGroup(t)).length}resetFilter(){this._filterValue.set(null),this.filterViewChild&&this.filterViewChild.nativeElement&&(this.filterViewChild.nativeElement.value="")}registerOnChange(t){this.onModelChange=t}registerOnTouched(t){this.onModelTouched=t}setDisabledState(t){this.disabled=t,this.cd.markForCheck()}onContainerClick(t){this.disabled||this.readonly||this.loading||(this.focusInputViewChild?.nativeElement.focus({preventScroll:!0}),"INPUT"!==t.target.tagName&&"clearicon"!==t.target.getAttribute("data-pc-section")&&!t.target.closest('[data-pc-section="clearicon"]')&&((!this.overlayViewChild||!this.overlayViewChild.el.nativeElement.contains(t.target))&&(this.overlayVisible?this.hide(!0):this.show(!0)),this.onClick.emit(t),this.clicked.set(!0),this.cd.detectChanges()))}isEmpty(){return!this._options()||this.visibleOptions()&&0===this.visibleOptions().length}onEditableInput(t){const n=t.target.value;this.searchValue="",!this.searchOptions(t,n)&&this.focusedOptionIndex.set(-1),this.onModelChange(n),this.updateModel(n,t),setTimeout(()=>{this.onChange.emit({originalEvent:t,value:n})},1),!this.overlayVisible&&ro.isNotEmpty(n)&&this.show()}show(t){this.overlayVisible=!0;const n=-1!==this.focusedOptionIndex()?this.focusedOptionIndex():this.autoOptionFocus?this.findFirstFocusedOptionIndex():this.editable?-1:this.findSelectedOptionIndex();this.focusedOptionIndex.set(n),t&&xr.focus(this.focusInputViewChild?.nativeElement),this.cd.markForCheck()}onOverlayAnimationStart(t){if("visible"===t.toState){if(this.itemsWrapper=xr.findSingle(this.overlayViewChild?.overlayViewChild?.nativeElement,this.virtualScroll?".p-scroller":".p-dropdown-items-wrapper"),this.virtualScroll&&this.scroller?.setContentEl(this.itemsViewChild?.nativeElement),this.options&&this.options.length)if(this.virtualScroll){const n=this.modelValue()?this.focusedOptionIndex():-1;-1!==n&&this.scroller?.scrollToIndex(n)}else{let n=xr.findSingle(this.itemsWrapper,".p-dropdown-item.p-highlight");n&&n.scrollIntoView({block:"nearest",inline:"nearest"})}this.filterViewChild&&this.filterViewChild.nativeElement&&(this.preventModelTouched=!0,this.autofocusFilter&&!this.editable&&this.filterViewChild.nativeElement.focus()),this.onShow.emit(t)}"void"===t.toState&&(this.itemsWrapper=null,this.onModelTouched(),this.onHide.emit(t))}hide(t){this.overlayVisible=!1,this.focusedOptionIndex.set(-1),this.clicked.set(!1),this.searchValue="","modal"===this.overlayOptions?.mode&&xr.unblockBodyScroll(),this.filter&&this.resetFilterOnHide&&this.resetFilter(),t&&(this.focusInputViewChild&&setTimeout(()=>{xr.focus(this.focusInputViewChild?.nativeElement)}),this.editable&&this.editableInputViewChild&&setTimeout(()=>{xr.focus(this.editableInputViewChild?.nativeElement)})),this.cd.markForCheck()}onInputFocus(t){if(this.disabled)return;this.focused=!0;const n=-1!==this.focusedOptionIndex()?this.focusedOptionIndex():this.overlayVisible&&this.autoOptionFocus?this.findFirstFocusedOptionIndex():-1;this.focusedOptionIndex.set(n),this.overlayVisible&&this.scrollInView(this.focusedOptionIndex()),this.onFocus.emit(t)}onInputBlur(t){this.focused=!1,this.onBlur.emit(t),this.preventModelTouched||this.onModelTouched(),this.preventModelTouched=!1}onMouseDown(t){t.preventDefault()}onKeyDown(t,n){if(!(this.disabled||this.readonly||this.loading)){switch(t.code){case"ArrowDown":this.onArrowDownKey(t);break;case"ArrowUp":this.onArrowUpKey(t,this.editable);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(t,this.editable);break;case"Delete":this.onDeleteKey(t);break;case"Home":this.onHomeKey(t,this.editable);break;case"End":this.onEndKey(t,this.editable);break;case"PageDown":this.onPageDownKey(t);break;case"PageUp":this.onPageUpKey(t);break;case"Space":this.onSpaceKey(t,n);break;case"Enter":case"NumpadEnter":this.onEnterKey(t);break;case"Escape":this.onEscapeKey(t);break;case"Tab":this.onTabKey(t);break;case"Backspace":this.onBackspaceKey(t,this.editable);break;case"ShiftLeft":case"ShiftRight":break;default:!t.metaKey&&ro.isPrintableCharacter(t.key)&&(!this.overlayVisible&&this.show(),!this.editable&&this.searchOptions(t,t.key))}this.clicked.set(!1)}}onFilterKeyDown(t){switch(t.code){case"ArrowDown":this.onArrowDownKey(t);break;case"ArrowUp":this.onArrowUpKey(t,!0);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(t,!0);break;case"Home":this.onHomeKey(t,!0);break;case"End":this.onEndKey(t,!0);break;case"Enter":case"NumpadEnter":this.onEnterKey(t,!0);break;case"Escape":this.onEscapeKey(t);break;case"Tab":this.onTabKey(t,!0)}}onFilterBlur(t){this.focusedOptionIndex.set(-1)}onArrowDownKey(t){if(this.overlayVisible){const n=-1!==this.focusedOptionIndex()?this.findNextOptionIndex(this.focusedOptionIndex()):this.clicked()?this.findFirstOptionIndex():this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(t,n)}else this.show(),this.editable&&this.changeFocusedOptionIndex(t,this.findSelectedOptionIndex());t.preventDefault(),t.stopPropagation()}changeFocusedOptionIndex(t,n){if(this.focusedOptionIndex()!==n&&(this.focusedOptionIndex.set(n),this.scrollInView(),this.selectOnFocus)){const o=this.visibleOptions()[n];this.onOptionSelect(t,o,!1)}}get virtualScrollerDisabled(){return!this.virtualScroll}scrollInView(t=-1){if(this.itemsViewChild&&this.itemsViewChild.nativeElement){const o=xr.findSingle(this.itemsViewChild.nativeElement,`li[id="${-1!==t?`${this.id}_${t}`:this.focusedOptionId}"]`);o?o.scrollIntoView&&o.scrollIntoView({block:"nearest",inline:"nearest"}):this.virtualScrollerDisabled||setTimeout(()=>{this.virtualScroll&&this.scroller?.scrollToIndex(-1!==t?t:this.focusedOptionIndex())},0)}}hasSelectedOption(){return void 0!==this.modelValue()}isValidSelectedOption(t){return this.isValidOption(t)&&this.isSelected(t)}equalityKey(){return this.optionValue?null:this.dataKey}findFirstFocusedOptionIndex(){const t=this.findSelectedOptionIndex();return t<0?this.findFirstOptionIndex():t}findFirstOptionIndex(){return this.visibleOptions().findIndex(t=>this.isValidOption(t))}findSelectedOptionIndex(){return this.hasSelectedOption()?this.visibleOptions().findIndex(t=>this.isValidSelectedOption(t)):-1}findNextOptionIndex(t){const n=t<this.visibleOptions().length-1?this.visibleOptions().slice(t+1).findIndex(o=>this.isValidOption(o)):-1;return n>-1?n+t+1:t}findPrevOptionIndex(t){const n=t>0?ro.findLastIndex(this.visibleOptions().slice(0,t),o=>this.isValidOption(o)):-1;return n>-1?n:t}findLastOptionIndex(){return ro.findLastIndex(this.visibleOptions(),t=>this.isValidOption(t))}findLastFocusedOptionIndex(){const t=this.findSelectedOptionIndex();return t<0?this.findLastOptionIndex():t}isValidOption(t){return null!=t&&!(this.isOptionDisabled(t)||this.isOptionGroup(t))}isOptionGroup(t){return null!=this.optionGroupLabel&&null!=t.optionGroup&&t.group}onArrowUpKey(t,n=!1){if(t.altKey&&!n){if(-1!==this.focusedOptionIndex()){const o=this.visibleOptions()[this.focusedOptionIndex()];this.onOptionSelect(t,o)}this.overlayVisible&&this.hide()}else{const o=-1!==this.focusedOptionIndex()?this.findPrevOptionIndex(this.focusedOptionIndex()):this.clicked()?this.findLastOptionIndex():this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(t,o),!this.overlayVisible&&this.show()}t.preventDefault(),t.stopPropagation()}onArrowLeftKey(t,n=!1){n&&this.focusedOptionIndex.set(-1)}onDeleteKey(t){this.showClear&&(this.clear(t),t.preventDefault())}onHomeKey(t,n=!1){if(n){const o=t.currentTarget;t.shiftKey?o.setSelectionRange(0,o.value.length):(o.setSelectionRange(0,0),this.focusedOptionIndex.set(-1))}else this.changeFocusedOptionIndex(t,this.findFirstOptionIndex()),!this.overlayVisible&&this.show();t.preventDefault()}onEndKey(t,n=!1){if(n){const o=t.currentTarget;if(t.shiftKey)o.setSelectionRange(0,o.value.length);else{const f=o.value.length;o.setSelectionRange(f,f),this.focusedOptionIndex.set(-1)}}else this.changeFocusedOptionIndex(t,this.findLastOptionIndex()),!this.overlayVisible&&this.show();t.preventDefault()}onPageDownKey(t){this.scrollInView(this.visibleOptions().length-1),t.preventDefault()}onPageUpKey(t){this.scrollInView(0),t.preventDefault()}onSpaceKey(t,n=!1){!this.editable&&!n&&this.onEnterKey(t)}onEnterKey(t,n=!1){if(this.overlayVisible){if(-1!==this.focusedOptionIndex()){const o=this.visibleOptions()[this.focusedOptionIndex()];this.onOptionSelect(t,o)}!n&&this.hide()}else this.focusedOptionIndex.set(-1),this.onArrowDownKey(t);t.preventDefault()}onEscapeKey(t){this.overlayVisible&&this.hide(!0),t.preventDefault()}onTabKey(t,n=!1){if(!n)if(this.overlayVisible&&this.hasFocusableElements())xr.focus(t.shiftKey?this.lastHiddenFocusableElementOnOverlay.nativeElement:this.firstHiddenFocusableElementOnOverlay.nativeElement),t.preventDefault();else{if(-1!==this.focusedOptionIndex()&&this.overlayVisible){const o=this.visibleOptions()[this.focusedOptionIndex()];this.onOptionSelect(t,o)}this.overlayVisible&&this.hide(this.filter)}t.stopPropagation()}onFirstHiddenFocus(t){const n=t.relatedTarget===this.focusInputViewChild?.nativeElement?xr.getFirstFocusableElement(this.overlayViewChild.el?.nativeElement,":not(.p-hidden-focusable)"):this.focusInputViewChild?.nativeElement;xr.focus(n)}onLastHiddenFocus(t){const n=t.relatedTarget===this.focusInputViewChild?.nativeElement?xr.getLastFocusableElement(this.overlayViewChild?.overlayViewChild?.nativeElement,':not([data-p-hidden-focusable="true"])'):this.focusInputViewChild?.nativeElement;xr.focus(n)}hasFocusableElements(){return xr.getFocusableElements(this.overlayViewChild.overlayViewChild.nativeElement,':not([data-p-hidden-focusable="true"]):not([class="p-dropdown-items-wrapper"])').length>0}onBackspaceKey(t,n=!1){n&&!this.overlayVisible&&this.show()}searchFields(){return this.filterBy?.split(",")||this.filterFields||[this.optionLabel]}searchOptions(t,n){this.searchValue=(this.searchValue||"")+n;let o=-1,f=!1;return-1!==this.focusedOptionIndex()?(o=this.visibleOptions().slice(this.focusedOptionIndex()).findIndex(D=>this.isOptionMatched(D)),o=-1===o?this.visibleOptions().slice(0,this.focusedOptionIndex()).findIndex(D=>this.isOptionMatched(D)):o+this.focusedOptionIndex()):o=this.visibleOptions().findIndex(D=>this.isOptionMatched(D)),-1!==o&&(f=!0),-1===o&&-1===this.focusedOptionIndex()&&(o=this.findFirstFocusedOptionIndex()),-1!==o&&this.changeFocusedOptionIndex(t,o),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500),f}isOptionMatched(t){return this.isValidOption(t)&&this.getOptionLabel(t).toString().toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale))}onFilterInputChange(t){this._filterValue.set(t.target.value),this.focusedOptionIndex.set(-1),this.onFilter.emit({originalEvent:t,filter:this._filterValue()}),!this.virtualScrollerDisabled&&this.scroller.scrollToIndex(0),setTimeout(()=>{this.overlayViewChild.alignOverlay()}),this.cd.markForCheck()}applyFocus(){this.editable?xr.findSingle(this.el.nativeElement,".p-dropdown-label.p-inputtext").focus():xr.focus(this.focusInputViewChild?.nativeElement)}focus(){this.applyFocus()}clear(t){this.updateModel(null,t),this.clearEditableLabel(),this.onModelTouched(),this.onChange.emit({originalEvent:t,value:this.value}),this.onClear.emit(t),this.resetFilter()}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(yg),e.\u0275\u0275directiveInject(mf))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-dropdown"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(xA,5),e.\u0275\u0275viewQuery(I0,5),e.\u0275\u0275viewQuery(fx,5),e.\u0275\u0275viewQuery(bE,5),e.\u0275\u0275viewQuery(nf,5),e.\u0275\u0275viewQuery(_f,5),e.\u0275\u0275viewQuery(lD,5),e.\u0275\u0275viewQuery(Fp,5),e.\u0275\u0275viewQuery(Eg,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.containerViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.filterViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.focusInputViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.editableInputViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.itemsViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.scroller=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.overlayViewChild=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.firstHiddenFocusableElementOnOverlay=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.lastHiddenFocusableElementOnOverlay=f.first)}},hostAttrs:[1,"p-element","p-inputwrapper"],hostVars:4,hostBindings:function(n,o){2&n&&e.\u0275\u0275classProp("p-inputwrapper-filled",o.filled())("p-inputwrapper-focus",o.focused||o.overlayVisible)},inputs:{id:"id",scrollHeight:"scrollHeight",filter:[2,"filter","filter",e.booleanAttribute],name:"name",style:"style",panelStyle:"panelStyle",styleClass:"styleClass",panelStyleClass:"panelStyleClass",readonly:[2,"readonly","readonly",e.booleanAttribute],required:[2,"required","required",e.booleanAttribute],editable:[2,"editable","editable",e.booleanAttribute],appendTo:"appendTo",tabindex:[2,"tabindex","tabindex",e.numberAttribute],placeholder:"placeholder",loadingIcon:"loadingIcon",filterPlaceholder:"filterPlaceholder",filterLocale:"filterLocale",variant:"variant",inputId:"inputId",dataKey:"dataKey",filterBy:"filterBy",filterFields:"filterFields",autofocus:[2,"autofocus","autofocus",e.booleanAttribute],resetFilterOnHide:[2,"resetFilterOnHide","resetFilterOnHide",e.booleanAttribute],checkmark:[2,"checkmark","checkmark",e.booleanAttribute],dropdownIcon:"dropdownIcon",loading:[2,"loading","loading",e.booleanAttribute],optionLabel:"optionLabel",optionValue:"optionValue",optionDisabled:"optionDisabled",optionGroupLabel:"optionGroupLabel",optionGroupChildren:"optionGroupChildren",autoDisplayFirst:[2,"autoDisplayFirst","autoDisplayFirst",e.booleanAttribute],group:[2,"group","group",e.booleanAttribute],showClear:[2,"showClear","showClear",e.booleanAttribute],emptyFilterMessage:"emptyFilterMessage",emptyMessage:"emptyMessage",lazy:[2,"lazy","lazy",e.booleanAttribute],virtualScroll:[2,"virtualScroll","virtualScroll",e.booleanAttribute],virtualScrollItemSize:[2,"virtualScrollItemSize","virtualScrollItemSize",e.numberAttribute],virtualScrollOptions:"virtualScrollOptions",overlayOptions:"overlayOptions",ariaFilterLabel:"ariaFilterLabel",ariaLabel:"ariaLabel",ariaLabelledBy:"ariaLabelledBy",filterMatchMode:"filterMatchMode",maxlength:[2,"maxlength","maxlength",e.numberAttribute],tooltip:"tooltip",tooltipPosition:"tooltipPosition",tooltipPositionStyle:"tooltipPositionStyle",tooltipStyleClass:"tooltipStyleClass",focusOnHover:[2,"focusOnHover","focusOnHover",e.booleanAttribute],selectOnFocus:[2,"selectOnFocus","selectOnFocus",e.booleanAttribute],autoOptionFocus:[2,"autoOptionFocus","autoOptionFocus",e.booleanAttribute],autofocusFilter:[2,"autofocusFilter","autofocusFilter",e.booleanAttribute],disabled:"disabled",itemSize:"itemSize",autoZIndex:"autoZIndex",baseZIndex:"baseZIndex",showTransitionOptions:"showTransitionOptions",hideTransitionOptions:"hideTransitionOptions",filterValue:"filterValue",options:"options"},outputs:{onChange:"onChange",onFilter:"onFilter",onFocus:"onFocus",onBlur:"onBlur",onClick:"onClick",onShow:"onShow",onHide:"onHide",onClear:"onClear",onLazyLoad:"onLazyLoad"},features:[e.\u0275\u0275ProvidersFeature([bx]),e.\u0275\u0275InputTransformsFeature],decls:12,vars:20,consts:[["container",""],["elseBlock",""],["overlay",""],["focusInput",""],["defaultPlaceholder",""],["editableInput",""],["firstHiddenFocusableEl",""],["buildInItems",""],["lastHiddenFocusableEl",""],["builtInFilterElement",""],["filter",""],["scroller",""],["items",""],["emptyFilter",""],["empty",""],[3,"click","ngClass","ngStyle"],["role","combobox","pAutoFocus","",3,"ngClass","pTooltip","tooltipPosition","positionStyle","tooltipStyleClass","autofocus","focus","blur","keydown",4,"ngIf"],["type","text","aria-haspopup","listbox","pAutoFocus","",3,"ngClass","disabled","autofocus","input","keydown","focus","blur",4,"ngIf"],[4,"ngIf"],["role","button","aria-label","dropdown trigger","aria-haspopup","listbox",1,"p-dropdown-trigger",3,"mousedown"],[4,"ngIf","ngIfElse"],[3,"visibleChange","onAnimationStart","onHide","visible","options","target","appendTo","autoZIndex","baseZIndex","showTransitionOptions","hideTransitionOptions"],["pTemplate","content"],["role","combobox","pAutoFocus","",3,"focus","blur","keydown","ngClass","pTooltip","tooltipPosition","positionStyle","tooltipStyleClass","autofocus"],[3,"ngTemplateOutlet","ngTemplateOutletContext",4,"ngIf"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],["type","text","aria-haspopup","listbox","pAutoFocus","",3,"input","keydown","focus","blur","ngClass","disabled","autofocus"],[3,"styleClass","click",4,"ngIf"],["class","p-dropdown-clear-icon",3,"click",4,"ngIf"],[3,"click","styleClass"],[1,"p-dropdown-clear-icon",3,"click"],[4,"ngTemplateOutlet"],["aria-hidden","true",3,"ngClass",4,"ngIf"],["aria-hidden","true",3,"class",4,"ngIf"],["aria-hidden","true",3,"ngClass"],["aria-hidden","true"],["class","p-dropdown-trigger-icon",4,"ngIf"],["class","p-dropdown-trigger-icon",3,"ngClass",4,"ngIf"],[3,"styleClass",4,"ngIf"],[1,"p-dropdown-trigger-icon",3,"ngClass"],[3,"styleClass"],[1,"p-dropdown-trigger-icon"],[3,"ngClass","ngStyle"],["role","presentation",1,"p-hidden-accessible","p-hidden-focusable",3,"focus"],["class","p-dropdown-header",3,"click",4,"ngIf"],["tabindex","0",1,"p-dropdown-items-wrapper",3,"ngStyle"],[3,"items","style","itemSize","autoSize","lazy","options","onLazyLoad",4,"ngIf"],[1,"p-dropdown-header",3,"click"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"p-dropdown-filter-container"],["type","text","role","searchbox","autocomplete","off",1,"p-dropdown-filter","p-inputtext","p-component",3,"input","keydown","blur","value","ngClass"],["class","p-dropdown-filter-icon",4,"ngIf"],[1,"p-dropdown-filter-icon"],[3,"onLazyLoad","items","itemSize","autoSize","lazy","options"],["pTemplate","loader"],["role","listbox",1,"p-dropdown-items",3,"ngClass","ngStyle"],["ngFor","",3,"ngForOf"],["class","p-dropdown-empty-message","role","option",3,"ngStyle",4,"ngIf"],["role","option",1,"p-dropdown-item-group",3,"ngStyle"],[3,"onClick","onMouseEnter","id","option","checkmark","selected","label","disabled","template","focused","ariaPosInset","ariaSetSize"],["role","option",1,"p-dropdown-empty-message",3,"ngStyle"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",15,0),e.\u0275\u0275listener("click",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onContainerClick(j))}),e.\u0275\u0275template(2,hx,6,20,"span",16)(3,Vm,2,8,"input",17)(4,Mg,3,2,"ng-container",18),e.\u0275\u0275elementStart(5,"div",19),e.\u0275\u0275listener("mousedown",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onMouseDown(j))}),e.\u0275\u0275template(6,Zf,3,2,"ng-container",20)(7,u1,2,2,"ng-template",null,1,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(9,"p-overlay",21,2),e.\u0275\u0275twoWayListener("visibleChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.overlayVisible,j)||(o.overlayVisible=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275listener("onAnimationStart",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onOverlayAnimationStart(j))})("onHide",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.hide())}),e.\u0275\u0275template(11,Fh,13,18,"ng-template",22),e.\u0275\u0275elementEnd()()}if(2&n){let f;const D=e.\u0275\u0275reference(8);e.\u0275\u0275classMap(o.styleClass),e.\u0275\u0275property("ngClass",o.containerClass)("ngStyle",o.style),e.\u0275\u0275attribute("id",o.id),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.editable),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.editable),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isVisibleClearIcon),e.\u0275\u0275advance(),e.\u0275\u0275attribute("aria-expanded",null!==(f=o.overlayVisible)&&void 0!==f&&f)("data-pc-section","trigger"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.loading)("ngIfElse",D),e.\u0275\u0275advance(3),e.\u0275\u0275twoWayProperty("visible",o.overlayVisible),e.\u0275\u0275property("options",o.overlayOptions)("target","@parent")("appendTo",o.appendTo)("autoZIndex",o.autoZIndex)("baseZIndex",o.baseZIndex)("showTransitionOptions",o.showTransitionOptions)("hideTransitionOptions",o.hideTransitionOptions)}},dependencies:()=>[ve.NgClass,ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,va,Zc,H_,mu,km,Sh,Dg,Rm,Pv],styles:["@layer primeng{.p-dropdown{display:inline-flex;cursor:pointer;position:relative;-webkit-user-select:none;user-select:none}.p-dropdown-clear-icon{position:absolute;top:50%;margin-top:-.5rem}.p-dropdown-trigger{display:flex;align-items:center;justify-content:center;flex-shrink:0}.p-dropdown-label{display:block;white-space:nowrap;overflow:hidden;flex:1 1 auto;width:1%;text-overflow:ellipsis;cursor:pointer}.p-dropdown-label-empty{overflow:hidden;opacity:0}input.p-dropdown-label{cursor:default}.p-dropdown .p-dropdown-panel{min-width:100%}.p-dropdown-items-wrapper{overflow:auto}.p-dropdown-item{cursor:pointer;font-weight:400;white-space:nowrap;position:relative;overflow:hidden}.p-dropdown-item-group{cursor:auto}.p-dropdown-items{margin:0;padding:0;list-style-type:none}.p-dropdown-filter{width:100%}.p-dropdown-filter-container{position:relative}.p-dropdown-filter-icon{position:absolute;top:50%;margin-top:-.5rem}.p-fluid .p-dropdown{display:flex}.p-fluid .p-dropdown .p-dropdown-label{width:1%}.p-float-label .p-dropdown .p-placeholder{opacity:0}}\n"],encapsulation:2,changeDetection:0})}return r})(),Ag=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,bc,Tu,Ff,wh,Zh,Nf,Sh,Dg,Rm,oD,yd,bc,Tu,Zh]})}return r})(),Og=(()=>{class r{el;ngModel;cd;config;variant="outlined";filled;constructor(t,n,o,f){this.el=t,this.ngModel=n,this.cd=o,this.config=f}ngAfterViewInit(){this.updateFilledState(),this.cd.detectChanges()}ngDoCheck(){this.updateFilledState()}onInput(){this.updateFilledState()}updateFilledState(){this.filled=this.el.nativeElement.value&&this.el.nativeElement.value.length||this.ngModel&&this.ngModel.model}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Ji.NgModel,8),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(mf))};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pInputText",""]],hostAttrs:[1,"p-inputtext","p-component","p-element"],hostVars:4,hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("input",function(D){return o.onInput(D)}),2&n&&e.\u0275\u0275classProp("p-filled",o.filled)("p-variant-filled","filled"===o.variant||"filled"===o.config.inputStyle())},inputs:{variant:"variant"}})}return r})(),ah=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();var L0=S(345),rm=S(4686),om=S(2661),k0=S(953);class yD{constructor(v,t){this._document=t;const n=this._textarea=this._document.createElement("textarea"),o=n.style;o.position="fixed",o.top=o.opacity="0",o.left="-999em",n.setAttribute("aria-hidden","true"),n.value=v,n.readOnly=!0,(this._document.fullscreenElement||this._document.body).appendChild(n)}copy(){const v=this._textarea;let t=!1;try{if(v){const n=this._document.activeElement;v.select(),v.setSelectionRange(0,v.value.length),t=this._document.execCommand("copy"),n&&n.focus()}}catch{}return t}destroy(){const v=this._textarea;v&&(v.remove(),this._textarea=void 0)}}let Cx=(()=>{class r{constructor(t){this._document=t}copy(t){const n=this.beginCopy(t),o=n.copy();return n.destroy(),o}beginCopy(t){return new yD(t,this._document)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ve.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();var wx=S(9311),Bv=S(4801);const Fg=["*"],Vv=(r,v,t,n,o,f)=>({"p-sidebar":!0,"p-sidebar-active":r,"p-sidebar-left":v,"p-sidebar-right":t,"p-sidebar-top":n,"p-sidebar-bottom":o,"p-sidebar-full":f}),ad=(r,v)=>({transform:r,transition:v}),bD=r=>({value:"visible",params:r});function xx(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Ng(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,xx,1,0,"ng-container",5),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.headlessTemplate)}}function Id(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function J_(r,v){1&r&&e.\u0275\u0275element(0,"TimesIcon",13),2&r&&(e.\u0275\u0275property("styleClass","p-sidebar-close-icon"),e.\u0275\u0275attribute("data-pc-section","closeicon"))}function up(r,v){}function ey(r,v){1&r&&e.\u0275\u0275template(0,up,0,0,"ng-template")}function h1(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",14),e.\u0275\u0275template(1,ey,1,0,null,5),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275attribute("data-pc-section","closeicon"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.closeIconTemplate)}}function Sx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",10),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.close(o))})("keydown.enter",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.close(o))}),e.\u0275\u0275template(1,J_,1,2,"TimesIcon",11)(2,h1,2,2,"span",12),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275attribute("aria-label",t.ariaCloseLabel)("data-pc-section","closebutton")("data-pc-group-section","iconcontainer"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.closeIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.closeIconTemplate)}}function P0(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function kf(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Ex(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",15),e.\u0275\u0275template(2,kf,1,0,"ng-container",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275attribute("data-pc-section","footer"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.footerTemplate)}}function jv(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275template(1,Id,1,0,"ng-container",5)(2,Sx,3,5,"button",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",8),e.\u0275\u0275projection(4),e.\u0275\u0275template(5,P0,1,0,"ng-container",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(6,Ex,3,2,"ng-container",9)),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("data-pc-section","header"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.headerTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.showCloseIcon),e.\u0275\u0275advance(),e.\u0275\u0275attribute("data-pc-section","content"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",t.contentTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.footerTemplate)}}function B0(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",3,0),e.\u0275\u0275listener("@panelState.start",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onAnimationStart(o))})("@panelState.done",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onAnimationEnd(o))})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onKeyDown(o))}),e.\u0275\u0275template(2,Ng,2,1,"ng-container",4)(3,jv,7,6,"ng-template",null,1,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275reference(4),n=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(n.styleClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction6(9,Vv,n.visible,"left"===n.position&&!n.fullScreen,"right"===n.position&&!n.fullScreen,"top"===n.position&&!n.fullScreen,"bottom"===n.position&&!n.fullScreen,n.fullScreen))("@panelState",e.\u0275\u0275pureFunction1(19,bD,e.\u0275\u0275pureFunction2(16,ad,n.transformOptions,n.transitionOptions)))("ngStyle",n.style),e.\u0275\u0275attribute("data-pc-name","sidebar")("data-pc-section","root"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.headlessTemplate)("ngIfElse",t)}}const Tx=(0,sr.animation)([(0,sr.style)({transform:"{{transform}}",opacity:0}),(0,sr.animate)("{{transition}}")]),SA=(0,sr.animation)([(0,sr.animate)("{{transition}}",(0,sr.style)({transform:"{{transform}}",opacity:0}))]);let ty=(()=>{class r{document;el;renderer;cd;config;appendTo;blockScroll=!1;style;styleClass;ariaCloseLabel;autoZIndex=!0;baseZIndex=0;modal=!0;dismissible=!0;showCloseIcon=!0;closeOnEscape=!0;transitionOptions="150ms cubic-bezier(0, 0, 0.2, 1)";get visible(){return this._visible}set visible(t){this._visible=t}get position(){return this._position}set position(t){switch(this._position=t,t){case"left":this.transformOptions="translate3d(-100%, 0px, 0px)";break;case"right":this.transformOptions="translate3d(100%, 0px, 0px)";break;case"bottom":this.transformOptions="translate3d(0px, 100%, 0px)";break;case"top":this.transformOptions="translate3d(0px, -100%, 0px)"}}get fullScreen(){return this._fullScreen}set fullScreen(t){this._fullScreen=t,t&&(this.transformOptions="none")}templates;onShow=new e.EventEmitter;onHide=new e.EventEmitter;visibleChange=new e.EventEmitter;initialized;_visible;_position="left";_fullScreen=!1;container;transformOptions="translate3d(-100%, 0px, 0px)";mask;maskClickListener;documentEscapeListener;animationEndListener;contentTemplate;headerTemplate;footerTemplate;closeIconTemplate;headlessTemplate;constructor(t,n,o,f,D){this.document=t,this.el=n,this.renderer=o,this.cd=f,this.config=D}ngAfterViewInit(){this.initialized=!0}ngAfterContentInit(){this.templates?.forEach(t=>{switch(t.getType()){case"content":default:this.contentTemplate=t.template;break;case"header":this.headerTemplate=t.template;break;case"footer":this.footerTemplate=t.template;break;case"closeicon":this.closeIconTemplate=t.template;break;case"headless":this.headlessTemplate=t.template}})}onKeyDown(t){"Escape"===t.code&&this.hide(!1)}show(){this.autoZIndex&&Uu.set("modal",this.container,this.baseZIndex||this.config.zIndex.modal),this.modal&&this.enableModality(),this.onShow.emit({}),this.visibleChange.emit(!0)}hide(t=!0){t&&this.onHide.emit({}),this.modal&&this.disableModality()}close(t){this.hide(),this.visibleChange.emit(!1),t.preventDefault()}enableModality(){const t=this.document.querySelectorAll(".p-sidebar-active"),o=String(1==t.length?parseInt(this.container.style.zIndex)-1:parseInt(t[0].style.zIndex)-1);this.mask||(this.mask=this.renderer.createElement("div"),this.renderer.setStyle(this.mask,"zIndex",o),xr.addMultipleClasses(this.mask,"p-component-overlay p-sidebar-mask p-component-overlay p-component-overlay-enter"),this.dismissible&&(this.maskClickListener=this.renderer.listen(this.mask,"click",f=>{this.dismissible&&this.close(f)})),this.renderer.appendChild(this.document.body,this.mask),this.blockScroll&&xr.blockBodyScroll())}disableModality(){this.mask&&(xr.addClass(this.mask,"p-component-overlay-leave"),this.animationEndListener=this.renderer.listen(this.mask,"animationend",this.destroyModal.bind(this)))}destroyModal(){this.unbindMaskClickListener(),this.mask&&this.renderer.removeChild(this.document.body,this.mask),this.blockScroll&&xr.unblockBodyScroll(),this.unbindAnimationEndListener(),this.mask=null}onAnimationStart(t){"visible"===t.toState&&(this.container=t.element,this.appendContainer(),this.show(),this.closeOnEscape&&this.bindDocumentEscapeListener())}onAnimationEnd(t){"void"===t.toState&&(this.hide(!1),Uu.clear(this.container),this.unbindGlobalListeners())}appendContainer(){this.appendTo&&("body"===this.appendTo?this.renderer.appendChild(this.document.body,this.container):xr.appendChild(this.container,this.appendTo))}bindDocumentEscapeListener(){this.documentEscapeListener=this.renderer.listen(this.el?this.el.nativeElement.ownerDocument:this.document,"keydown",n=>{27==n.which&&parseInt(this.container.style.zIndex)===Uu.get(this.container)&&this.close(n)})}unbindDocumentEscapeListener(){this.documentEscapeListener&&(this.documentEscapeListener(),this.documentEscapeListener=null)}unbindMaskClickListener(){this.maskClickListener&&(this.maskClickListener(),this.maskClickListener=null)}unbindGlobalListeners(){this.unbindMaskClickListener(),this.unbindDocumentEscapeListener()}unbindAnimationEndListener(){this.animationEndListener&&this.mask&&(this.animationEndListener(),this.animationEndListener=null)}ngOnDestroy(){this.initialized=!1,this.visible&&this.modal&&this.destroyModal(),this.appendTo&&this.container&&this.renderer.appendChild(this.el.nativeElement,this.container),this.container&&this.autoZIndex&&Uu.clear(this.container),this.container=null,this.unbindGlobalListeners(),this.unbindAnimationEndListener()}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(mf))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-sidebar"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},hostAttrs:[1,"p-element"],inputs:{appendTo:"appendTo",blockScroll:[2,"blockScroll","blockScroll",e.booleanAttribute],style:"style",styleClass:"styleClass",ariaCloseLabel:"ariaCloseLabel",autoZIndex:[2,"autoZIndex","autoZIndex",e.booleanAttribute],baseZIndex:[2,"baseZIndex","baseZIndex",e.numberAttribute],modal:[2,"modal","modal",e.booleanAttribute],dismissible:[2,"dismissible","dismissible",e.booleanAttribute],showCloseIcon:[2,"showCloseIcon","showCloseIcon",e.booleanAttribute],closeOnEscape:[2,"closeOnEscape","closeOnEscape",e.booleanAttribute],transitionOptions:"transitionOptions",visible:"visible",position:"position",fullScreen:"fullScreen"},outputs:{onShow:"onShow",onHide:"onHide",visibleChange:"visibleChange"},features:[e.\u0275\u0275InputTransformsFeature],ngContentSelectors:Fg,decls:1,vars:1,consts:[["container",""],["notHeadless",""],["role","complementary",3,"ngClass","ngStyle","class","keydown",4,"ngIf"],["role","complementary",3,"keydown","ngClass","ngStyle"],[4,"ngIf","ngIfElse"],[4,"ngTemplateOutlet"],[1,"p-sidebar-header"],["type","button","class","p-sidebar-close p-sidebar-icon p-link","pRipple","",3,"click","keydown.enter",4,"ngIf"],[1,"p-sidebar-content"],[4,"ngIf"],["type","button","pRipple","",1,"p-sidebar-close","p-sidebar-icon","p-link",3,"click","keydown.enter"],[3,"styleClass",4,"ngIf"],["class","p-sidebar-close-icon",4,"ngIf"],[3,"styleClass"],[1,"p-sidebar-close-icon"],[1,"p-sidebar-footer"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275template(0,B0,5,21,"div",2)),2&n&&e.\u0275\u0275property("ngIf",o.visible)},dependencies:()=>[ve.NgClass,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,Bs,Sh],styles:["@layer primeng{.p-sidebar{position:fixed;transition:transform .3s;display:flex;flex-direction:column}.p-sidebar-content{position:relative;overflow-y:auto;flex-grow:1}.p-sidebar-header{display:flex;align-items:center}.p-sidebar-footer{margin-top:auto}.p-sidebar-icon{display:flex;align-items:center;justify-content:center;margin-left:auto}.p-sidebar-left{top:0;left:0;width:20rem;height:100%}.p-sidebar-right{top:0;right:0;width:20rem;height:100%}.p-sidebar-top{top:0;left:0;width:100%;height:10rem}.p-sidebar-bottom{bottom:0;left:0;width:100%;height:10rem}.p-sidebar-full{width:100%;height:100%;top:0;left:0;-webkit-transition:none;transition:none}.p-sidebar-left.p-sidebar-sm,.p-sidebar-right.p-sidebar-sm{width:20rem}.p-sidebar-left.p-sidebar-md,.p-sidebar-right.p-sidebar-md{width:40rem}.p-sidebar-left.p-sidebar-lg,.p-sidebar-right.p-sidebar-lg{width:60rem}.p-sidebar-top.p-sidebar-sm,.p-sidebar-bottom.p-sidebar-sm{height:10rem}.p-sidebar-top.p-sidebar-md,.p-sidebar-bottom.p-sidebar-md{height:20rem}.p-sidebar-top.p-sidebar-lg,.p-sidebar-bottom.p-sidebar-lg{height:30rem}@media screen and (max-width: 64em){.p-sidebar-left.p-sidebar-lg,.p-sidebar-left.p-sidebar-md,.p-sidebar-right.p-sidebar-lg,.p-sidebar-right.p-sidebar-md{width:20rem}}}\n"],encapsulation:2,data:{animation:[(0,sr.trigger)("panelState",[(0,sr.transition)("void => visible",[(0,sr.useAnimation)(Tx)]),(0,sr.transition)("visible => void",[(0,sr.useAnimation)(SA)])])]},changeDetection:0})}return r})(),wM=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,wh,Tu,Sh,Tu]})}return r})();var dp=S(4256),hl=S(4523);let lh={};const Nh={},Ou={};let CD=!1;function m1(){return(m1=(0,hl.A)(function*(r,v){return(yield Nh[r].get(v))()})).apply(this,arguments)}function DD(r,v){return wD.apply(this,arguments)}function wD(){return(wD=(0,hl.A)(function*(r,v){return Ou[v]||(CD||(yield S.I("default"),CD=!0),yield r.init(S.S.default),Ou[v]=!0),r})).apply(this,arguments)}function V0(){return V0=(0,hl.A)(function*(r,v){if("string"==typeof r)return yield g1(r,v);if("script"===r.type){const t=r;return yield g1(t.remoteEntry,t.remoteName)}"module"===r.type&&(yield function ny(r){return iy.apply(this,arguments)}(r.remoteEntry))}),V0.apply(this,arguments)}function iy(){return(iy=(0,hl.A)(function*(r){return Nh[r]?Promise.resolve():yield import(r).then(v=>{DD(v,r),Nh[r]=v})})).apply(this,arguments)}function g1(r,v){return sm.apply(this,arguments)}function sm(){return(sm=(0,hl.A)(function*(r,v){return new Promise((t,n)=>{if(Nh[v])return void t();const o=document.createElement("script");o.src=r,o.onerror=n,o.onload=()=>{const f=window[v];DD(f,v),Nh[v]=f,t()},document.body.appendChild(o)})})).apply(this,arguments)}function Uv(){return Uv=(0,hl.A)(function*(r,v){let t,n,o,f;if(f="string"==typeof r?{type:"manifest",remoteName:r,exposedModule:v}:r,!f.type){const D=Object.keys(lh).length>0;f.type=D?"manifest":"script"}if("manifest"===f.type){const D=lh[f.remoteName];if(!D)throw new Error("Manifest does not contain "+f.remoteName);f={type:D.type,exposedModule:f.exposedModule,remoteEntry:D.remoteEntry,remoteName:"script"===D.type?f.remoteName:void 0},o=D.remoteEntry}else o=f.remoteEntry;return"script"===f.type?(t={type:"script",remoteEntry:f.remoteEntry,remoteName:f.remoteName},n=f.remoteName):"module"===f.type&&(t={type:"module",remoteEntry:f.remoteEntry},n=f.remoteEntry),o&&(yield function Lg(r,v){return V0.apply(this,arguments)}(t)),yield function Rg(r,v){return m1.apply(this,arguments)}(n,f.exposedModule)}),Uv.apply(this,arguments)}let oy=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleDoubleLeftIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["fill-rule","evenodd","clip-rule","evenodd","d","M5.71602 11.164C5.80782 11.2021 5.9063 11.2215 6.00569 11.221C6.20216 11.2301 6.39427 11.1612 6.54025 11.0294C6.68191 10.8875 6.76148 10.6953 6.76148 10.4948C6.76148 10.2943 6.68191 10.1021 6.54025 9.96024L3.51441 6.9344L6.54025 3.90855C6.624 3.76126 6.65587 3.59011 6.63076 3.42254C6.60564 3.25498 6.525 3.10069 6.40175 2.98442C6.2785 2.86815 6.11978 2.79662 5.95104 2.7813C5.78229 2.76598 5.61329 2.80776 5.47112 2.89994L1.97123 6.39983C1.82957 6.54167 1.75 6.73393 1.75 6.9344C1.75 7.13486 1.82957 7.32712 1.97123 7.46896L5.47112 10.9991C5.54096 11.0698 5.62422 11.1259 5.71602 11.164ZM11.0488 10.9689C11.1775 11.1156 11.3585 11.2061 11.5531 11.221C11.7477 11.2061 11.9288 11.1156 12.0574 10.9689C12.1815 10.8302 12.25 10.6506 12.25 10.4645C12.25 10.2785 12.1815 10.0989 12.0574 9.96024L9.03158 6.93439L12.0574 3.90855C12.1248 3.76739 12.1468 3.60881 12.1204 3.45463C12.0939 3.30045 12.0203 3.15826 11.9097 3.04765C11.7991 2.93703 11.6569 2.86343 11.5027 2.83698C11.3486 2.81053 11.19 2.83252 11.0488 2.89994L7.51865 6.36957C7.37699 6.51141 7.29742 6.70367 7.29742 6.90414C7.29742 7.1046 7.37699 7.29686 7.51865 7.4387L11.0488 10.9689Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),SE=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleDoubleRightIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["fill-rule","evenodd","clip-rule","evenodd","d","M7.68757 11.1451C7.7791 11.1831 7.8773 11.2024 7.9764 11.2019C8.07769 11.1985 8.17721 11.1745 8.26886 11.1312C8.36052 11.088 8.44238 11.0265 8.50943 10.9505L12.0294 7.49085C12.1707 7.34942 12.25 7.15771 12.25 6.95782C12.25 6.75794 12.1707 6.56622 12.0294 6.42479L8.50943 2.90479C8.37014 2.82159 8.20774 2.78551 8.04633 2.80192C7.88491 2.81833 7.73309 2.88635 7.6134 2.99588C7.4937 3.10541 7.41252 3.25061 7.38189 3.40994C7.35126 3.56927 7.37282 3.73423 7.44337 3.88033L10.4605 6.89748L7.44337 9.91463C7.30212 10.0561 7.22278 10.2478 7.22278 10.4477C7.22278 10.6475 7.30212 10.8393 7.44337 10.9807C7.51301 11.0512 7.59603 11.1071 7.68757 11.1451ZM1.94207 10.9505C2.07037 11.0968 2.25089 11.1871 2.44493 11.2019C2.63898 11.1871 2.81949 11.0968 2.94779 10.9505L6.46779 7.49085C6.60905 7.34942 6.68839 7.15771 6.68839 6.95782C6.68839 6.75793 6.60905 6.56622 6.46779 6.42479L2.94779 2.90479C2.80704 2.83757 2.6489 2.81563 2.49517 2.84201C2.34143 2.86839 2.19965 2.94178 2.08936 3.05207C1.97906 3.16237 1.90567 3.30415 1.8793 3.45788C1.85292 3.61162 1.87485 3.76975 1.94207 3.9105L4.95922 6.92765L1.94207 9.9448C1.81838 10.0831 1.75 10.2621 1.75 10.4477C1.75 10.6332 1.81838 10.8122 1.94207 10.9505Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),v1=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleLeftIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M8.75 11.185C8.65146 11.1854 8.55381 11.1662 8.4628 11.1284C8.37179 11.0906 8.28924 11.0351 8.22 10.965L4.72 7.46496C4.57955 7.32433 4.50066 7.13371 4.50066 6.93496C4.50066 6.73621 4.57955 6.54558 4.72 6.40496L8.22 2.93496C8.36095 2.84357 8.52851 2.80215 8.69582 2.81733C8.86312 2.83252 9.02048 2.90344 9.14268 3.01872C9.26487 3.134 9.34483 3.28696 9.36973 3.4531C9.39463 3.61924 9.36303 3.78892 9.28 3.93496L6.28 6.93496L9.28 9.93496C9.42045 10.0756 9.49934 10.2662 9.49934 10.465C9.49934 10.6637 9.42045 10.8543 9.28 10.995C9.13526 11.1257 8.9448 11.1939 8.75 11.185Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),_1=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleRightIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M5.25 11.1728C5.14929 11.1694 5.05033 11.1455 4.9592 11.1025C4.86806 11.0595 4.78666 10.9984 4.72 10.9228C4.57955 10.7822 4.50066 10.5916 4.50066 10.3928C4.50066 10.1941 4.57955 10.0035 4.72 9.86283L7.72 6.86283L4.72 3.86283C4.66067 3.71882 4.64765 3.55991 4.68275 3.40816C4.71785 3.25642 4.79932 3.11936 4.91585 3.01602C5.03238 2.91268 5.17819 2.84819 5.33305 2.83149C5.4879 2.81479 5.64411 2.84671 5.78 2.92283L9.28 6.42283C9.42045 6.56346 9.49934 6.75408 9.49934 6.95283C9.49934 7.15158 9.42045 7.34221 9.28 7.48283L5.78 10.9228C5.71333 10.9984 5.63193 11.0595 5.5408 11.1025C5.44966 11.1455 5.35071 11.1694 5.25 11.1728Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})();const Mx=["*"],Ix=r=>({class:r});function $v(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Ax(r,v){if(1&r&&e.\u0275\u0275element(0,"span",8),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass",t.iconClass()),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section","loadingicon")}}function Ox(r,v){if(1&r&&e.\u0275\u0275element(0,"SpinnerIcon",9),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("styleClass",t.spinnerIconClass())("spin",!0),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section","loadingicon")}}function U0(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Ax,1,3,"span",6)(2,Ox,1,4,"SpinnerIcon",7),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loadingIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIcon)}}function y1(r,v){}function Lh(r,v){if(1&r&&e.\u0275\u0275template(0,y1,0,0,"ng-template",10),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngIf",t.loadingIconTemplate)}}function EE(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,U0,3,2,"ng-container",2)(2,Lh,1,1,null,5),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loadingIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.loadingIconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(3,Ix,t.iconClass()))}}function b1(r,v){if(1&r&&e.\u0275\u0275element(0,"span",8),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.iconClass()),e.\u0275\u0275attribute("data-pc-section","icon")}}function TE(r,v){}function SD(r,v){if(1&r&&e.\u0275\u0275template(0,TE,0,0,"ng-template",10),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngIf",!t.icon&&t.iconTemplate)}}function C1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,b1,1,2,"span",6)(2,SD,1,1,null,5),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon&&!t.iconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.iconTemplate)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(3,Ix,t.iconClass()))}}function Fx(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",11),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275attribute("aria-hidden",t.icon&&!t.label)("data-pc-section","label"),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.label)}}function $0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",8),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.badgeClass),e.\u0275\u0275property("ngClass",t.badgeStyleClass()),e.\u0275\u0275attribute("data-pc-section","badge"),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.badge)}}const Wv={button:"p-button",component:"p-component",iconOnly:"p-button-icon-only",disabled:"p-disabled",loading:"p-button-loading",labelOnly:"p-button-loading-label-only"};let Hv=(()=>{class r{el;document;iconPos="left";loadingIcon;get label(){return this._label}set label(t){this._label=t,this.initialized&&(this.updateLabel(),this.updateIcon(),this.setStyleClass())}get icon(){return this._icon}set icon(t){this._icon=t,this.initialized&&(this.updateIcon(),this.setStyleClass())}get loading(){return this._loading}set loading(t){this._loading=t,this.initialized&&(this.updateIcon(),this.setStyleClass())}severity;raised=!1;rounded=!1;text=!1;outlined=!1;size=null;plain=!1;_label;_icon;_loading=!1;initialized;get htmlElement(){return this.el.nativeElement}_internalClasses=Object.values(Wv);constructor(t,n){this.el=t,this.document=n}ngAfterViewInit(){xr.addMultipleClasses(this.htmlElement,this.getStyleClass().join(" ")),this.createIcon(),this.createLabel(),this.initialized=!0}getStyleClass(){const t=[Wv.button,Wv.component];return this.icon&&!this.label&&ro.isEmpty(this.htmlElement.textContent)&&t.push(Wv.iconOnly),this.loading&&(t.push(Wv.disabled,Wv.loading),!this.icon&&this.label&&t.push(Wv.labelOnly),this.icon&&!this.label&&!ro.isEmpty(this.htmlElement.textContent)&&t.push(Wv.iconOnly)),this.text&&t.push("p-button-text"),this.severity&&t.push(`p-button-${this.severity}`),this.plain&&t.push("p-button-plain"),this.raised&&t.push("p-button-raised"),this.size&&t.push(`p-button-${this.size}`),this.outlined&&t.push("p-button-outlined"),this.rounded&&t.push("p-button-rounded"),"small"===this.size&&t.push("p-button-sm"),"large"===this.size&&t.push("p-button-lg"),t}setStyleClass(){const t=this.getStyleClass();this.htmlElement.classList.remove(...this._internalClasses),this.htmlElement.classList.add(...t)}createLabel(){if(!xr.findSingle(this.htmlElement,".p-button-label")&&this.label){let n=this.document.createElement("span");this.icon&&!this.label&&n.setAttribute("aria-hidden","true"),n.className="p-button-label",n.appendChild(this.document.createTextNode(this.label)),this.htmlElement.appendChild(n)}}createIcon(){if(!xr.findSingle(this.htmlElement,".p-button-icon")&&(this.icon||this.loading)){let n=this.document.createElement("span");n.className="p-button-icon",n.setAttribute("aria-hidden","true");let o=this.label?"p-button-icon-"+this.iconPos:null;o&&xr.addClass(n,o);let f=this.getIconClass();f&&xr.addMultipleClasses(n,f),this.htmlElement.insertBefore(n,this.htmlElement.firstChild)}}updateLabel(){let t=xr.findSingle(this.htmlElement,".p-button-label");this.label?t?t.textContent=this.label:this.createLabel():t&&this.htmlElement.removeChild(t)}updateIcon(){let t=xr.findSingle(this.htmlElement,".p-button-icon"),n=xr.findSingle(this.htmlElement,".p-button-label");t?t.className=this.iconPos?"p-button-icon "+(n?"p-button-icon-"+this.iconPos:"")+" "+this.getIconClass():"p-button-icon "+this.getIconClass():this.createIcon()}getIconClass(){return this.loading?"p-button-loading-icon pi-spin "+(this.loadingIcon??"pi pi-spinner"):this.icon||"p-hidden"}ngOnDestroy(){this.initialized=!1}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(ve.DOCUMENT))};static \u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","pButton",""]],hostAttrs:[1,"p-element"],inputs:{iconPos:"iconPos",loadingIcon:"loadingIcon",label:"label",icon:"icon",loading:"loading",severity:"severity",raised:[2,"raised","raised",e.booleanAttribute],rounded:[2,"rounded","rounded",e.booleanAttribute],text:[2,"text","text",e.booleanAttribute],outlined:[2,"outlined","outlined",e.booleanAttribute],size:"size",plain:[2,"plain","plain",e.booleanAttribute]},standalone:!0,features:[e.\u0275\u0275InputTransformsFeature]})}return r})(),Hm=(()=>{class r{el;type="button";iconPos="left";icon;badge;label;disabled;loading=!1;loadingIcon;raised=!1;rounded=!1;text=!1;plain=!1;severity;outlined=!1;link=!1;tabindex;size;style;styleClass;badgeClass;ariaLabel;autofocus;onClick=new e.EventEmitter;onFocus=new e.EventEmitter;onBlur=new e.EventEmitter;contentTemplate;loadingIconTemplate;iconTemplate;templates;constructor(t){this.el=t}spinnerIconClass(){return Object.entries(this.iconClass()).filter(([,t])=>!!t).reduce((t,[n])=>t+` ${n}`,"p-button-loading-icon")}iconClass(){const t={"p-button-icon":!0,"p-button-icon-left":"left"===this.iconPos&&this.label,"p-button-icon-right":"right"===this.iconPos&&this.label,"p-button-icon-top":"top"===this.iconPos&&this.label,"p-button-icon-bottom":"bottom"===this.iconPos&&this.label};return this.loading?t[`p-button-loading-icon pi-spin ${this.loadingIcon??""}`]=!0:this.icon&&(t[this.icon]=!0),t}get buttonClass(){return{"p-button p-component":!0,"p-button-icon-only":(this.icon||this.iconTemplate||this.loadingIcon||this.loadingIconTemplate)&&!this.label,"p-button-vertical":("top"===this.iconPos||"bottom"===this.iconPos)&&this.label,"p-button-loading":this.loading,"p-button-loading-label-only":this.loading&&!this.icon&&this.label&&!this.loadingIcon&&"left"===this.iconPos,"p-button-link":this.link,[`p-button-${this.severity}`]:this.severity,"p-button-raised":this.raised,"p-button-rounded":this.rounded,"p-button-text":this.text,"p-button-outlined":this.outlined,"p-button-sm":"small"===this.size,"p-button-lg":"large"===this.size,"p-button-plain":this.plain,[`${this.styleClass}`]:this.styleClass}}ngAfterContentInit(){this.templates?.forEach(t=>{switch(t.getType()){case"content":default:this.contentTemplate=t.template;break;case"icon":this.iconTemplate=t.template;break;case"loadingicon":this.loadingIconTemplate=t.template}})}badgeStyleClass(){return{"p-badge p-component":!0,"p-badge-no-gutter":this.badge&&1===String(this.badge).length}}focus(){this.el.nativeElement.firstChild.focus()}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-button"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},hostAttrs:[1,"p-element"],hostVars:2,hostBindings:function(n,o){2&n&&e.\u0275\u0275classProp("p-disabled",o.disabled)},inputs:{type:"type",iconPos:"iconPos",icon:"icon",badge:"badge",label:"label",disabled:[2,"disabled","disabled",e.booleanAttribute],loading:[2,"loading","loading",e.booleanAttribute],loadingIcon:"loadingIcon",raised:[2,"raised","raised",e.booleanAttribute],rounded:[2,"rounded","rounded",e.booleanAttribute],text:[2,"text","text",e.booleanAttribute],plain:[2,"plain","plain",e.booleanAttribute],severity:"severity",outlined:[2,"outlined","outlined",e.booleanAttribute],link:[2,"link","link",e.booleanAttribute],tabindex:[2,"tabindex","tabindex",e.numberAttribute],size:"size",style:"style",styleClass:"styleClass",badgeClass:"badgeClass",ariaLabel:"ariaLabel",autofocus:[2,"autofocus","autofocus",e.booleanAttribute]},outputs:{onClick:"onClick",onFocus:"onFocus",onBlur:"onBlur"},standalone:!0,features:[e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275StandaloneFeature],ngContentSelectors:Mx,decls:7,vars:14,consts:[["pRipple","","pAutoFocus","",3,"click","focus","blur","ngStyle","disabled","ngClass","autofocus"],[4,"ngTemplateOutlet"],[4,"ngIf"],["class","p-button-label",4,"ngIf"],[3,"ngClass","class",4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"ngClass",4,"ngIf"],[3,"styleClass","spin",4,"ngIf"],[3,"ngClass"],[3,"styleClass","spin"],[3,"ngIf"],[1,"p-button-label"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"button",0),e.\u0275\u0275listener("click",function(D){return o.onClick.emit(D)})("focus",function(D){return o.onFocus.emit(D)})("blur",function(D){return o.onBlur.emit(D)}),e.\u0275\u0275projection(1),e.\u0275\u0275template(2,$v,1,0,"ng-container",1)(3,EE,3,5,"ng-container",2)(4,C1,3,5,"ng-container",2)(5,Fx,2,3,"span",3)(6,$0,2,5,"span",4),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("ngStyle",o.style)("disabled",o.disabled||o.loading)("ngClass",o.buttonClass)("autofocus",o.autofocus),e.\u0275\u0275attribute("type",o.type)("aria-label",o.ariaLabel)("data-pc-name","button")("data-pc-section","root")("tabindex",o.tabindex),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",o.contentTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.contentTemplate&&o.label),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.contentTemplate&&o.badge))},dependencies:[ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,ve.NgClass,Bs,km,zl],encapsulation:2,changeDetection:0})}return r})(),Nx=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[Hm,Tu]})}return r})(),ME=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleDownIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M3.58659 4.5007C3.68513 4.50023 3.78277 4.51945 3.87379 4.55723C3.9648 4.59501 4.04735 4.65058 4.11659 4.7207L7.11659 7.7207L10.1166 4.7207C10.2619 4.65055 10.4259 4.62911 10.5843 4.65956C10.7427 4.69002 10.8871 4.77074 10.996 4.88976C11.1049 5.00877 11.1726 5.15973 11.1889 5.32022C11.2052 5.48072 11.1693 5.6422 11.0866 5.7807L7.58659 9.2807C7.44597 9.42115 7.25534 9.50004 7.05659 9.50004C6.85784 9.50004 6.66722 9.42115 6.52659 9.2807L3.02659 5.7807C2.88614 5.64007 2.80725 5.44945 2.80725 5.2507C2.80725 5.05195 2.88614 4.86132 3.02659 4.7207C3.09932 4.64685 3.18675 4.58911 3.28322 4.55121C3.37969 4.51331 3.48305 4.4961 3.58659 4.5007Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})(),lm=(()=>{class r extends Wu{static \u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["AngleUpIcon"]],standalone:!0,features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275StandaloneFeature],decls:2,vars:5,consts:[["width","14","height","14","viewBox","0 0 14 14","fill","none","xmlns","http://www.w3.org/2000/svg"],["d","M10.4134 9.49931C10.3148 9.49977 10.2172 9.48055 10.1262 9.44278C10.0352 9.405 9.95263 9.34942 9.88338 9.27931L6.88338 6.27931L3.88338 9.27931C3.73811 9.34946 3.57409 9.3709 3.41567 9.34044C3.25724 9.30999 3.11286 9.22926 3.00395 9.11025C2.89504 8.99124 2.82741 8.84028 2.8111 8.67978C2.79478 8.51928 2.83065 8.35781 2.91338 8.21931L6.41338 4.71931C6.55401 4.57886 6.74463 4.49997 6.94338 4.49997C7.14213 4.49997 7.33276 4.57886 7.47338 4.71931L10.9734 8.21931C11.1138 8.35994 11.1927 8.55056 11.1927 8.74931C11.1927 8.94806 11.1138 9.13868 10.9734 9.27931C10.9007 9.35315 10.8132 9.41089 10.7168 9.44879C10.6203 9.48669 10.5169 9.5039 10.4134 9.49931Z","fill","currentColor"]],template:function(n,o){1&n&&(e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(0,"svg",0),e.\u0275\u0275element(1,"path",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.getClassNames()),e.\u0275\u0275attribute("aria-label",o.ariaLabel)("aria-hidden",o.ariaHidden)("role",o.role))},encapsulation:2})}return r})();const W0=["input"],Rx=(r,v,t)=>({"p-inputnumber p-component":!0,"p-inputnumber-buttons-stacked":r,"p-inputnumber-buttons-horizontal":v,"p-inputnumber-buttons-vertical":t}),H0=()=>({"p-inputnumber-button p-inputnumber-button-up":!0}),ED=()=>({"p-inputnumber-button p-inputnumber-button-down":!0});function z0(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"TimesIcon",8),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.clear())}),e.\u0275\u0275elementEnd()}2&r&&(e.\u0275\u0275property("ngClass","p-inputnumber-clear-icon"),e.\u0275\u0275attribute("data-pc-section","clearIcon"))}function kg(r,v){}function Lx(r,v){1&r&&e.\u0275\u0275template(0,kg,0,0,"ng-template")}function kx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",9),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.clear())}),e.\u0275\u0275template(1,Lx,1,0,null,10),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275attribute("data-pc-section","clearIcon"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.clearIconTemplate)}}function TD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,z0,1,2,"TimesIcon",6)(2,kx,2,2,"span",7),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.clearIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.clearIconTemplate)}}function MD(r,v){if(1&r&&e.\u0275\u0275element(0,"span",14),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.incrementButtonIcon),e.\u0275\u0275attribute("data-pc-section","incrementbuttonicon")}}function xM(r,v){1&r&&e.\u0275\u0275element(0,"AngleUpIcon"),2&r&&e.\u0275\u0275attribute("data-pc-section","incrementbuttonicon")}function G0(r,v){}function K0(r,v){1&r&&e.\u0275\u0275template(0,G0,0,0,"ng-template")}function ID(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,xM,1,1,"AngleUpIcon",3)(2,K0,1,0,null,10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.incrementButtonIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.incrementButtonIconTemplate)}}function Cd(r,v){if(1&r&&e.\u0275\u0275element(0,"span",14),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.decrementButtonIcon),e.\u0275\u0275attribute("data-pc-section","decrementbuttonicon")}}function cm(r,v){1&r&&e.\u0275\u0275element(0,"AngleDownIcon"),2&r&&e.\u0275\u0275attribute("data-pc-section","decrementbuttonicon")}function IE(r,v){}function zv(r,v){1&r&&e.\u0275\u0275template(0,IE,0,0,"ng-template")}function SM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,cm,1,1,"AngleDownIcon",3)(2,zv,1,0,null,10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.decrementButtonIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.decrementButtonIconTemplate)}}function AD(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",11)(1,"button",12),e.\u0275\u0275listener("mousedown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onUpButtonMouseDown(o))})("mouseup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonMouseUp())})("mouseleave",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonMouseLeave())})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onUpButtonKeyDown(o))})("keyup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonKeyUp())}),e.\u0275\u0275template(2,MD,1,2,"span",13)(3,ID,3,2,"ng-container",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"button",12),e.\u0275\u0275listener("mousedown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDownButtonMouseDown(o))})("mouseup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonMouseUp())})("mouseleave",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonMouseLeave())})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDownButtonKeyDown(o))})("keyup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonKeyUp())}),e.\u0275\u0275template(5,Cd,1,2,"span",13)(6,SM,3,2,"ng-container",3),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275attribute("data-pc-section","buttonGroup"),e.\u0275\u0275advance(),e.\u0275\u0275classMap(t.incrementButtonClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction0(17,H0))("disabled",t.disabled),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section","incrementbutton"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.incrementButtonIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.incrementButtonIcon),e.\u0275\u0275advance(),e.\u0275\u0275classMap(t.decrementButtonClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction0(18,ED))("disabled",t.disabled),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section",t.decrementbutton),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.decrementButtonIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.decrementButtonIcon)}}function rf(r,v){if(1&r&&e.\u0275\u0275element(0,"span",14),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.incrementButtonIcon),e.\u0275\u0275attribute("data-pc-section","incrementbuttonicon")}}function Gv(r,v){1&r&&e.\u0275\u0275element(0,"AngleUpIcon"),2&r&&e.\u0275\u0275attribute("data-pc-section","incrementbuttonicon")}function AE(r,v){}function D1(r,v){1&r&&e.\u0275\u0275template(0,AE,0,0,"ng-template")}function Px(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Gv,1,1,"AngleUpIcon",3)(2,D1,1,0,null,10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.incrementButtonIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.incrementButtonIconTemplate)}}function OE(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",12),e.\u0275\u0275listener("mousedown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onUpButtonMouseDown(o))})("mouseup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonMouseUp())})("mouseleave",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonMouseLeave())})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onUpButtonKeyDown(o))})("keyup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onUpButtonKeyUp())}),e.\u0275\u0275template(1,rf,1,2,"span",13)(2,Px,3,2,"ng-container",3),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.incrementButtonClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction0(8,H0))("disabled",t.disabled),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section","incrementbutton"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.incrementButtonIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.incrementButtonIcon)}}function w1(r,v){if(1&r&&e.\u0275\u0275element(0,"span",14),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.decrementButtonIcon),e.\u0275\u0275attribute("data-pc-section","decrementbuttonicon")}}function Bx(r,v){1&r&&e.\u0275\u0275element(0,"AngleDownIcon"),2&r&&e.\u0275\u0275attribute("data-pc-section","decrementbuttonicon")}function EM(r,v){}function Kv(r,v){1&r&&e.\u0275\u0275template(0,EM,0,0,"ng-template")}function OD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Bx,1,1,"AngleDownIcon",3)(2,Kv,1,0,null,10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.decrementButtonIconTemplate),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t.decrementButtonIconTemplate)}}function FE(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",12),e.\u0275\u0275listener("mousedown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDownButtonMouseDown(o))})("mouseup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonMouseUp())})("mouseleave",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonMouseLeave())})("keydown",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDownButtonKeyDown(o))})("keyup",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onDownButtonKeyUp())}),e.\u0275\u0275template(1,w1,1,2,"span",13)(2,OD,3,2,"ng-container",3),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.decrementButtonClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction0(8,ED))("disabled",t.disabled),e.\u0275\u0275attribute("aria-hidden",!0)("data-pc-section","decrementbutton"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.decrementButtonIcon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.decrementButtonIcon)}}const Vx={provide:Ji.NG_VALUE_ACCESSOR,useExisting:(0,e.forwardRef)(()=>TM),multi:!0};let TM=(()=>{class r{document;el;cd;injector;config;showButtons=!1;format=!0;buttonLayout="stacked";inputId;styleClass;style;placeholder;size;maxlength;tabindex;title;ariaLabelledBy;ariaLabel;ariaRequired;name;required;autocomplete;min;max;incrementButtonClass;decrementButtonClass;incrementButtonIcon;decrementButtonIcon;readonly=!1;step=1;allowEmpty=!0;locale;localeMatcher;mode="decimal";currency;currencyDisplay;useGrouping=!0;variant="outlined";minFractionDigits;maxFractionDigits;prefix;suffix;inputStyle;inputStyleClass;showClear=!1;autofocus;get disabled(){return this._disabled}set disabled(t){t&&(this.focused=!1),this._disabled=t,this.timer&&this.clearTimer()}onInput=new e.EventEmitter;onFocus=new e.EventEmitter;onBlur=new e.EventEmitter;onKeyDown=new e.EventEmitter;onClear=new e.EventEmitter;input;templates;clearIconTemplate;incrementButtonIconTemplate;decrementButtonIconTemplate;value;onModelChange=()=>{};onModelTouched=()=>{};focused;initialized;groupChar="";prefixChar="";suffixChar="";isSpecialChar;timer;lastValue;_numeral;numberFormat;_decimal;_decimalChar;_group;_minusSign;_currency;_prefix;_suffix;_index;_disabled;ngControl=null;constructor(t,n,o,f,D){this.document=t,this.el=n,this.cd=o,this.injector=f,this.config=D}ngOnChanges(t){["locale","localeMatcher","mode","currency","currencyDisplay","useGrouping","minFractionDigits","maxFractionDigits","prefix","suffix"].some(o=>!!t[o])&&this.updateConstructParser()}ngAfterContentInit(){this.templates.forEach(t=>{switch(t.getType()){case"clearicon":this.clearIconTemplate=t.template;break;case"incrementbuttonicon":this.incrementButtonIconTemplate=t.template;break;case"decrementbuttonicon":this.decrementButtonIconTemplate=t.template}})}ngOnInit(){this.ngControl=this.injector.get(Ji.NgControl,null,{optional:!0}),this.constructParser(),this.initialized=!0}getOptions(){return{localeMatcher:this.localeMatcher,style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay,useGrouping:this.useGrouping,minimumFractionDigits:this.minFractionDigits??void 0,maximumFractionDigits:this.maxFractionDigits??void 0}}constructParser(){this.numberFormat=new Intl.NumberFormat(this.locale,this.getOptions());const t=[...new Intl.NumberFormat(this.locale,{useGrouping:!1}).format(9876543210)].reverse(),n=new Map(t.map((o,f)=>[o,f]));this._numeral=new RegExp(`[${t.join("")}]`,"g"),this._group=this.getGroupingExpression(),this._minusSign=this.getMinusSignExpression(),this._currency=this.getCurrencyExpression(),this._decimal=this.getDecimalExpression(),this._decimalChar=this.getDecimalChar(),this._suffix=this.getSuffixExpression(),this._prefix=this.getPrefixExpression(),this._index=o=>n.get(o)}updateConstructParser(){this.initialized&&this.constructParser()}escapeRegExp(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}getDecimalExpression(){const t=this.getDecimalChar();return new RegExp(`[${t}]`,"g")}getDecimalChar(){return new Intl.NumberFormat(this.locale,{...this.getOptions(),useGrouping:!1}).format(1.1).replace(this._currency,"").trim().replace(this._numeral,"")}getGroupingExpression(){const t=new Intl.NumberFormat(this.locale,{useGrouping:!0});return this.groupChar=t.format(1e6).trim().replace(this._numeral,"").charAt(0),new RegExp(`[${this.groupChar}]`,"g")}getMinusSignExpression(){const t=new Intl.NumberFormat(this.locale,{useGrouping:!1});return new RegExp(`[${t.format(-1).trim().replace(this._numeral,"")}]`,"g")}getCurrencyExpression(){if(this.currency){const t=new Intl.NumberFormat(this.locale,{style:"currency",currency:this.currency,currencyDisplay:this.currencyDisplay,minimumFractionDigits:0,maximumFractionDigits:0});return new RegExp(`[${t.format(1).replace(/\s/g,"").replace(this._numeral,"").replace(this._group,"")}]`,"g")}return new RegExp("[]","g")}getPrefixExpression(){if(this.prefix)this.prefixChar=this.prefix;else{const t=new Intl.NumberFormat(this.locale,{style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay});this.prefixChar=t.format(1).split("1")[0]}return new RegExp(`${this.escapeRegExp(this.prefixChar||"")}`,"g")}getSuffixExpression(){if(this.suffix)this.suffixChar=this.suffix;else{const t=new Intl.NumberFormat(this.locale,{style:this.mode,currency:this.currency,currencyDisplay:this.currencyDisplay,minimumFractionDigits:0,maximumFractionDigits:0});this.suffixChar=t.format(1).split("1")[1]}return new RegExp(`${this.escapeRegExp(this.suffixChar||"")}`,"g")}get isBlurUpdateOnMode(){return"blur"===this.ngControl?.control?.updateOn}formatValue(t){if(null!=t){if("-"===t)return t;if(this.format){let o=new Intl.NumberFormat(this.locale,this.getOptions()).format(t);return this.prefix&&t!=this.prefix&&(o=this.prefix+o),this.suffix&&t!=this.suffix&&(o+=this.suffix),o}return t.toString()}return""}parseValue(t){const n=new RegExp(this._suffix,""),o=new RegExp(this._prefix,""),f=new RegExp(this._currency,"");let D=t.replace(n,"").replace(o,"").trim().replace(/\s/g,"").replace(f,"").replace(this._group,"").replace(this._minusSign,"-").replace(this._decimal,".").replace(this._numeral,this._index);if(D){if("-"===D)return D;let j=+D;return isNaN(j)?null:j}return null}repeat(t,n,o){if(this.readonly)return;let f=n||500;this.clearTimer(),this.timer=setTimeout(()=>{this.repeat(t,40,o)},f),this.spin(t,o)}spin(t,n){let o=this.step*n,f=this.parseValue(this.input?.nativeElement.value)||0,D=this.validateValue(f+o);this.maxlength&&this.maxlength<this.formatValue(D).length||(this.updateInput(D,null,"spin",null),this.updateModel(t,D),this.handleOnInput(t,f,D))}clear(){this.value=null,this.onModelChange(this.value),this.onClear.emit()}onUpButtonMouseDown(t){2!==t.button?this.disabled||(this.input?.nativeElement.focus(),this.repeat(t,null,1),t.preventDefault()):this.clearTimer()}onUpButtonMouseUp(){this.disabled||this.clearTimer()}onUpButtonMouseLeave(){this.disabled||this.clearTimer()}onUpButtonKeyDown(t){(32===t.keyCode||13===t.keyCode)&&this.repeat(t,null,1)}onUpButtonKeyUp(){this.disabled||this.clearTimer()}onDownButtonMouseDown(t){2!==t.button?this.disabled||(this.input?.nativeElement.focus(),this.repeat(t,null,-1),t.preventDefault()):this.clearTimer()}onDownButtonMouseUp(){this.disabled||this.clearTimer()}onDownButtonMouseLeave(){this.disabled||this.clearTimer()}onDownButtonKeyUp(){this.disabled||this.clearTimer()}onDownButtonKeyDown(t){(32===t.keyCode||13===t.keyCode)&&this.repeat(t,null,-1)}onUserInput(t){this.readonly||(this.isSpecialChar&&(t.target.value=this.lastValue),this.isSpecialChar=!1)}onInputKeyDown(t){if(this.readonly)return;if(this.lastValue=t.target.value,t.shiftKey||t.altKey)return void(this.isSpecialChar=!0);let n=t.target.selectionStart,o=t.target.selectionEnd,f=t.target.value,D=null;switch(t.altKey&&t.preventDefault(),t.key){case"ArrowUp":this.spin(t,1),t.preventDefault();break;case"ArrowDown":this.spin(t,-1),t.preventDefault();break;case"ArrowLeft":for(let j=n;j<=f.length;j++)if(this.isNumeralChar(f.charAt(0===j?0:j-1))){this.input.nativeElement.setSelectionRange(j,j);break}break;case"ArrowRight":for(let j=o;j>=0;j--)if(this.isNumeralChar(f.charAt(j))){this.input.nativeElement.setSelectionRange(j,j);break}break;case"Tab":case"Enter":D=this.validateValue(this.parseValue(this.input.nativeElement.value)),this.input.nativeElement.value=this.formatValue(D),this.input.nativeElement.setAttribute("aria-valuenow",D),this.updateModel(t,D);break;case"Backspace":if(t.preventDefault(),n===o){if(1==n&&this.prefix||n==f.length&&this.suffix)break;const j=f.charAt(n-1),{decimalCharIndex:fe,decimalCharIndexWithoutPrefix:Ne}=this.getDecimalCharIndexes(f);if(this.isNumeralChar(j)){const vt=this.getDecimalLength(f);if(this._group.test(j))this._group.lastIndex=0,D=f.slice(0,n-2)+f.slice(n-1);else if(this._decimal.test(j))this._decimal.lastIndex=0,vt?this.input?.nativeElement.setSelectionRange(n-1,n-1):D=f.slice(0,n-1)+f.slice(n);else if(fe>0&&n>fe){const ln=this.isDecimalMode()&&(this.minFractionDigits||0)<vt?"":"0";D=f.slice(0,n-1)+ln+f.slice(n)}else 1===Ne?(D=f.slice(0,n-1)+"0"+f.slice(n),D=this.parseValue(D)>0?D:""):D=f.slice(0,n-1)+f.slice(n)}else"currency"===this.mode&&-1!=j.search(this._currency)&&(D=f.slice(1));this.updateValue(t,D,null,"delete-single")}else D=this.deleteRange(f,n,o),this.updateValue(t,D,null,"delete-range");break;case"Delete":if(t.preventDefault(),n===o){if(0==n&&this.prefix||n==f.length-1&&this.suffix)break;const j=f.charAt(n),{decimalCharIndex:fe,decimalCharIndexWithoutPrefix:Ne}=this.getDecimalCharIndexes(f);if(this.isNumeralChar(j)){const vt=this.getDecimalLength(f);if(this._group.test(j))this._group.lastIndex=0,D=f.slice(0,n)+f.slice(n+2);else if(this._decimal.test(j))this._decimal.lastIndex=0,vt?this.input?.nativeElement.setSelectionRange(n+1,n+1):D=f.slice(0,n)+f.slice(n+1);else if(fe>0&&n>fe){const ln=this.isDecimalMode()&&(this.minFractionDigits||0)<vt?"":"0";D=f.slice(0,n)+ln+f.slice(n+1)}else 1===Ne?(D=f.slice(0,n)+"0"+f.slice(n+1),D=this.parseValue(D)>0?D:""):D=f.slice(0,n)+f.slice(n+1)}this.updateValue(t,D,null,"delete-back-single")}else D=this.deleteRange(f,n,o),this.updateValue(t,D,null,"delete-range");break;case"Home":this.min&&(this.updateModel(t,this.min),t.preventDefault());break;case"End":this.max&&(this.updateModel(t,this.max),t.preventDefault())}this.onKeyDown.emit(t)}onInputKeyPress(t){if(this.readonly)return;let n=t.which||t.keyCode,o=String.fromCharCode(n),f=this.isDecimalSign(o);const D=this.isMinusSign(o);13!=n&&t.preventDefault(),!f&&"NumpadDecimal"===t.code&&(f=!0,o=this._decimalChar,n=o.charCodeAt(0));const j=this.parseValue(this.input.nativeElement.value+o),fe=null!=j?j.toString():"";this.maxlength&&this.getSelectedText()?.length==this.maxlength?this.insert(t,o,{isDecimalSign:f,isMinusSign:D}):this.maxlength&&fe.length>this.maxlength||(48<=n&&n<=57||D||f)&&this.insert(t,o,{isDecimalSign:f,isMinusSign:D})}getSelectedText(){return window?.getSelection()?.toString().replaceAll(/[^0-9']/g,"")||""}onPaste(t){if(!this.disabled&&!this.readonly){t.preventDefault();let n=(t.clipboardData||this.document.defaultView.clipboardData).getData("Text");if(n){this.maxlength&&(n=n.toString().substring(0,this.maxlength));let o=this.parseValue(n);null!=o&&this.insert(t,o.toString())}}}allowMinusSign(){return null==this.min||this.min<0}isMinusSign(t){return!(!this._minusSign.test(t)&&"-"!==t||(this._minusSign.lastIndex=0,0))}isDecimalSign(t){return!!this._decimal.test(t)&&(this._decimal.lastIndex=0,!0)}isDecimalMode(){return"decimal"===this.mode}getDecimalCharIndexes(t){let n=t.search(this._decimal);this._decimal.lastIndex=0;const f=t.replace(this._prefix,"").trim().replace(/\s/g,"").replace(this._currency,"").search(this._decimal);return this._decimal.lastIndex=0,{decimalCharIndex:n,decimalCharIndexWithoutPrefix:f}}getCharIndexes(t){const n=t.search(this._decimal);this._decimal.lastIndex=0;const o=t.search(this._minusSign);this._minusSign.lastIndex=0;const f=t.search(this._suffix);this._suffix.lastIndex=0;const D=t.search(this._currency);return this._currency.lastIndex=0,{decimalCharIndex:n,minusCharIndex:o,suffixCharIndex:f,currencyCharIndex:D}}insert(t,n,o={isDecimalSign:!1,isMinusSign:!1}){const f=n.search(this._minusSign);if(this._minusSign.lastIndex=0,!this.allowMinusSign()&&-1!==f)return;let D=this.input?.nativeElement.selectionStart,j=this.input?.nativeElement.selectionEnd,fe=this.input?.nativeElement.value.trim();const{decimalCharIndex:Ne,minusCharIndex:vt,suffixCharIndex:ln,currencyCharIndex:Hn}=this.getCharIndexes(fe);let Oi;if(o.isMinusSign)0===D&&(Oi=fe,(-1===vt||0!==j)&&(Oi=this.insertText(fe,n,0,j)),this.updateValue(t,Oi,n,"insert"));else if(o.isDecimalSign)Ne>0&&D===Ne?this.updateValue(t,fe,n,"insert"):(Ne>D&&Ne<j||-1===Ne&&this.maxFractionDigits)&&(Oi=this.insertText(fe,n,D,j),this.updateValue(t,Oi,n,"insert"));else{const Lr=this.numberFormat.resolvedOptions().maximumFractionDigits,to=D!==j?"range-insert":"insert";if(Ne>0&&D>Ne){if(D+n.length-(Ne+1)<=Lr){const Mr=Hn>=D?Hn-1:ln>=D?ln:fe.length;Oi=fe.slice(0,D)+n+fe.slice(D+n.length,Mr)+fe.slice(Mr),this.updateValue(t,Oi,n,to)}}else Oi=this.insertText(fe,n,D,j),this.updateValue(t,Oi,n,to)}}insertText(t,n,o,f){if(2===("."===n?n:n.split(".")).length){const j=t.slice(o,f).search(this._decimal);return this._decimal.lastIndex=0,j>0?t.slice(0,o)+this.formatValue(n)+t.slice(f):t||this.formatValue(n)}return f-o===t.length?this.formatValue(n):0===o?n+t.slice(f):f===t.length?t.slice(0,o)+n:t.slice(0,o)+n+t.slice(f)}deleteRange(t,n,o){let f;return f=o-n===t.length?"":0===n?t.slice(o):o===t.length?t.slice(0,n):t.slice(0,n)+t.slice(o),f}initCursor(){let t=this.input?.nativeElement.selectionStart,n=this.input?.nativeElement.selectionEnd,o=this.input?.nativeElement.value,f=o.length,D=null,j=(this.prefixChar||"").length;o=o.replace(this._prefix,""),(t===n||0!==t||n<j)&&(t-=j);let fe=o.charAt(t);if(this.isNumeralChar(fe))return t+j;let Ne=t-1;for(;Ne>=0;){if(fe=o.charAt(Ne),this.isNumeralChar(fe)){D=Ne+j;break}Ne--}if(null!==D)this.input?.nativeElement.setSelectionRange(D+1,D+1);else{for(Ne=t;Ne<f;){if(fe=o.charAt(Ne),this.isNumeralChar(fe)){D=Ne+j;break}Ne++}null!==D&&this.input?.nativeElement.setSelectionRange(D,D)}return D||0}onInputClick(){const t=this.input?.nativeElement.value;!this.readonly&&t!==xr.getSelection()&&this.initCursor()}isNumeralChar(t){return!(1!==t.length||!(this._numeral.test(t)||this._decimal.test(t)||this._group.test(t)||this._minusSign.test(t))||(this.resetRegex(),0))}resetRegex(){this._numeral.lastIndex=0,this._decimal.lastIndex=0,this._group.lastIndex=0,this._minusSign.lastIndex=0}updateValue(t,n,o,f){let D=this.input?.nativeElement.value,j=null;null!=n&&(j=this.parseValue(n),j=j||this.allowEmpty?j:0,this.updateInput(j,o,f,n),this.handleOnInput(t,D,j))}handleOnInput(t,n,o){this.isValueChanged(n,o)&&(this.input.nativeElement.value=this.formatValue(o),this.input?.nativeElement.setAttribute("aria-valuenow",o),!this.isBlurUpdateOnMode&&this.updateModel(t,o),this.onInput.emit({originalEvent:t,value:o,formattedValue:n}))}isValueChanged(t,n){return null===n&&null!==t||null!=n&&n!==("string"==typeof t?this.parseValue(t):t)}validateValue(t){return"-"===t||null==t?null:null!=this.min&&t<this.min?this.min:null!=this.max&&t>this.max?this.max:t}updateInput(t,n,o,f){n=n||"";let D=this.input?.nativeElement.value,j=this.formatValue(t),fe=D.length;if(j!==f&&(j=this.concatValues(j,f)),0===fe){this.input.nativeElement.value=j,this.input.nativeElement.setSelectionRange(0,0);const vt=this.initCursor()+n.length;this.input.nativeElement.setSelectionRange(vt,vt)}else{let Ne=this.input.nativeElement.selectionStart,vt=this.input.nativeElement.selectionEnd;if(this.maxlength&&j.length>this.maxlength&&(j=j.slice(0,this.maxlength),Ne=Math.min(Ne,this.maxlength),vt=Math.min(vt,this.maxlength)),this.maxlength&&this.maxlength<j.length)return;this.input.nativeElement.value=j;let ln=j.length;if("range-insert"===o){const Hn=this.parseValue((D||"").slice(0,Ne)),Lr=(null!==Hn?Hn.toString():"").split("").join(`(${this.groupChar})?`),to=new RegExp(Lr,"g");to.test(j);const Mr=n.split("").join(`(${this.groupChar})?`),ss=new RegExp(Mr,"g");ss.test(j.slice(to.lastIndex)),vt=to.lastIndex+ss.lastIndex,this.input.nativeElement.setSelectionRange(vt,vt)}else if(ln===fe)"insert"===o||"delete-back-single"===o?this.input.nativeElement.setSelectionRange(vt+1,vt+1):"delete-single"===o?this.input.nativeElement.setSelectionRange(vt-1,vt-1):("delete-range"===o||"spin"===o)&&this.input.nativeElement.setSelectionRange(vt,vt);else if("delete-back-single"===o){let Hn=D.charAt(vt-1),Oi=D.charAt(vt),Lr=fe-ln,to=this._group.test(Oi);to&&1===Lr?vt+=1:!to&&this.isNumeralChar(Hn)&&(vt+=-1*Lr+1),this._group.lastIndex=0,this.input.nativeElement.setSelectionRange(vt,vt)}else if("-"===D&&"insert"===o){this.input.nativeElement.setSelectionRange(0,0);const Oi=this.initCursor()+n.length+1;this.input.nativeElement.setSelectionRange(Oi,Oi)}else vt+=ln-fe,this.input.nativeElement.setSelectionRange(vt,vt)}this.input.nativeElement.setAttribute("aria-valuenow",t)}concatValues(t,n){if(t&&n){let o=n.search(this._decimal);return this._decimal.lastIndex=0,this.suffixChar?-1!==o?t:t.replace(this.suffixChar,"").split(this._decimal)[0]+n.replace(this.suffixChar,"").slice(o)+this.suffixChar:-1!==o?t.split(this._decimal)[0]+n.slice(o):t}return t}getDecimalLength(t){if(t){const n=t.split(this._decimal);if(2===n.length)return n[1].replace(this._suffix,"").trim().replace(/\s/g,"").replace(this._currency,"").length}return 0}onInputFocus(t){this.focused=!0,this.onFocus.emit(t)}onInputBlur(t){this.focused=!1;const n=this.validateValue(this.parseValue(this.input.nativeElement.value)),o=n?.toString();this.input.nativeElement.value=this.formatValue(o),this.input.nativeElement.setAttribute("aria-valuenow",o),this.updateModel(t,n),this.onBlur.emit(t)}formattedValue(){return this.formatValue(this.value||this.allowEmpty?this.value:0)}updateModel(t,n){this.value!==n&&(this.value=n,this.isBlurUpdateOnMode&&this.focused?this.isBlurUpdateOnMode&&this.onModelChange(n):this.onModelChange(n)),this.onModelTouched()}writeValue(t){this.value=t,this.cd.markForCheck()}registerOnChange(t){this.onModelChange=t}registerOnTouched(t){this.onModelTouched=t}setDisabledState(t){this.disabled=t,this.cd.markForCheck()}get filled(){return null!=this.value&&this.value.toString().length>0}clearTimer(){this.timer&&clearInterval(this.timer)}static \u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ve.DOCUMENT),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.ChangeDetectorRef),e.\u0275\u0275directiveInject(e.Injector),e.\u0275\u0275directiveInject(mf))};static \u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["p-inputNumber"]],contentQueries:function(n,o,f){if(1&n&&e.\u0275\u0275contentQuery(f,Zc,4),2&n){let D;e.\u0275\u0275queryRefresh(D=e.\u0275\u0275loadQuery())&&(o.templates=D)}},viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(W0,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.input=f.first)}},hostAttrs:[1,"p-element","p-inputwrapper"],hostVars:6,hostBindings:function(n,o){2&n&&e.\u0275\u0275classProp("p-inputwrapper-filled",o.filled)("p-inputwrapper-focus",o.focused)("p-inputnumber-clearable",o.showClear&&"vertical"!=o.buttonLayout)},inputs:{showButtons:[2,"showButtons","showButtons",e.booleanAttribute],format:[2,"format","format",e.booleanAttribute],buttonLayout:"buttonLayout",inputId:"inputId",styleClass:"styleClass",style:"style",placeholder:"placeholder",size:[2,"size","size",e.numberAttribute],maxlength:[2,"maxlength","maxlength",e.numberAttribute],tabindex:[2,"tabindex","tabindex",e.numberAttribute],title:"title",ariaLabelledBy:"ariaLabelledBy",ariaLabel:"ariaLabel",ariaRequired:[2,"ariaRequired","ariaRequired",e.booleanAttribute],name:"name",required:[2,"required","required",e.booleanAttribute],autocomplete:"autocomplete",min:[2,"min","min",e.numberAttribute],max:[2,"max","max",e.numberAttribute],incrementButtonClass:"incrementButtonClass",decrementButtonClass:"decrementButtonClass",incrementButtonIcon:"incrementButtonIcon",decrementButtonIcon:"decrementButtonIcon",readonly:[2,"readonly","readonly",e.booleanAttribute],step:[2,"step","step",e.numberAttribute],allowEmpty:[2,"allowEmpty","allowEmpty",e.booleanAttribute],locale:"locale",localeMatcher:"localeMatcher",mode:"mode",currency:"currency",currencyDisplay:"currencyDisplay",useGrouping:[2,"useGrouping","useGrouping",e.booleanAttribute],variant:"variant",minFractionDigits:[2,"minFractionDigits","minFractionDigits",t=>(0,e.numberAttribute)(t,null)],maxFractionDigits:[2,"maxFractionDigits","maxFractionDigits",t=>(0,e.numberAttribute)(t,null)],prefix:"prefix",suffix:"suffix",inputStyle:"inputStyle",inputStyleClass:"inputStyleClass",showClear:[2,"showClear","showClear",e.booleanAttribute],autofocus:[2,"autofocus","autofocus",e.booleanAttribute],disabled:"disabled"},outputs:{onInput:"onInput",onFocus:"onFocus",onBlur:"onBlur",onKeyDown:"onKeyDown",onClear:"onClear"},features:[e.\u0275\u0275ProvidersFeature([Vx]),e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275NgOnChangesFeature],decls:7,vars:43,consts:[["input",""],[3,"ngClass","ngStyle"],["pInputText","","role","spinbutton","inputmode","decimal","pAutoFocus","",3,"input","keydown","keypress","paste","click","focus","blur","ngClass","ngStyle","value","disabled","readonly","autofocus"],[4,"ngIf"],["class","p-inputnumber-button-group",4,"ngIf"],["type","button","pButton","","class","p-button-icon-only","tabindex","-1",3,"ngClass","class","disabled","mousedown","mouseup","mouseleave","keydown","keyup",4,"ngIf"],[3,"ngClass","click",4,"ngIf"],["class","p-inputnumber-clear-icon",3,"click",4,"ngIf"],[3,"click","ngClass"],[1,"p-inputnumber-clear-icon",3,"click"],[4,"ngTemplateOutlet"],[1,"p-inputnumber-button-group"],["type","button","pButton","","tabindex","-1",1,"p-button-icon-only",3,"mousedown","mouseup","mouseleave","keydown","keyup","ngClass","disabled"],[3,"ngClass",4,"ngIf"],[3,"ngClass"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",1)(1,"input",2,0),e.\u0275\u0275listener("input",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onUserInput(j))})("keydown",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputKeyDown(j))})("keypress",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputKeyPress(j))})("paste",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onPaste(j))})("click",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputClick())})("focus",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputFocus(j))})("blur",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputBlur(j))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,TD,3,2,"ng-container",3)(4,AD,7,19,"span",4)(5,OE,3,9,"button",5)(6,FE,3,9,"button",5),e.\u0275\u0275elementEnd()}2&n&&(e.\u0275\u0275classMap(o.styleClass),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction3(39,Rx,o.showButtons&&"stacked"===o.buttonLayout,o.showButtons&&"horizontal"===o.buttonLayout,o.showButtons&&"vertical"===o.buttonLayout))("ngStyle",o.style),e.\u0275\u0275attribute("data-pc-name","inputnumber")("data-pc-section","root"),e.\u0275\u0275advance(),e.\u0275\u0275classMap(o.inputStyleClass),e.\u0275\u0275classProp("p-variant-filled","filled"===o.variant||"filled"===o.config.inputStyle()),e.\u0275\u0275property("ngClass","p-inputnumber-input")("ngStyle",o.inputStyle)("value",o.formattedValue())("disabled",o.disabled)("readonly",o.readonly)("autofocus",o.autofocus),e.\u0275\u0275attribute("id",o.inputId)("variant",o.variant)("aria-valuemin",o.min)("aria-valuemax",o.max)("aria-valuenow",o.value)("placeholder",o.placeholder)("aria-label",o.ariaLabel)("aria-labelledby",o.ariaLabelledBy)("title",o.title)("size",o.size)("name",o.name)("autocomplete",o.autocomplete)("maxlength",o.maxlength)("tabindex",o.tabindex)("aria-required",o.ariaRequired)("required",o.required)("min",o.min)("max",o.max)("data-pc-section","input"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf","vertical"!=o.buttonLayout&&o.showClear&&o.value),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showButtons&&"stacked"===o.buttonLayout),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showButtons&&"stacked"!==o.buttonLayout),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showButtons&&"stacked"!==o.buttonLayout))},dependencies:()=>[ve.NgClass,ve.NgIf,ve.NgTemplateOutlet,ve.NgStyle,Og,Hv,km,Sh,lm,ME],styles:["@layer primeng{p-inputnumber,.p-inputnumber{display:inline-flex}.p-inputnumber-button{display:flex;align-items:center;justify-content:center;flex:0 0 auto}.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button .p-button-label,.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button .p-button-label{display:none}.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button-up{border-top-left-radius:0;border-bottom-left-radius:0;border-bottom-right-radius:0;padding:0}.p-inputnumber-buttons-stacked .p-inputnumber-input{border-top-right-radius:0;border-bottom-right-radius:0}.p-inputnumber-buttons-stacked .p-button.p-inputnumber-button-down{border-top-left-radius:0;border-top-right-radius:0;border-bottom-left-radius:0;padding:0}.p-inputnumber-buttons-stacked .p-inputnumber-button-group{display:flex;flex-direction:column}.p-inputnumber-buttons-stacked .p-inputnumber-button-group .p-button.p-inputnumber-button{flex:1 1 auto}.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button-up{order:3;border-top-left-radius:0;border-bottom-left-radius:0}.p-inputnumber-buttons-horizontal .p-inputnumber-input{order:2;border-radius:0}.p-inputnumber-buttons-horizontal .p-button.p-inputnumber-button-down{order:1;border-top-right-radius:0;border-bottom-right-radius:0}.p-inputnumber-buttons-vertical{flex-direction:column}.p-inputnumber-buttons-vertical .p-button.p-inputnumber-button-up{order:1;border-bottom-left-radius:0;border-bottom-right-radius:0;width:100%}.p-inputnumber-buttons-vertical .p-inputnumber-input{order:2;border-radius:0;text-align:center}.p-inputnumber-buttons-vertical .p-button.p-inputnumber-button-down{order:3;border-top-left-radius:0;border-top-right-radius:0;width:100%}.p-inputnumber-input{flex:1 1 auto}.p-fluid p-inputnumber,.p-fluid .p-inputnumber{width:100%}.p-fluid .p-inputnumber .p-inputnumber-input{width:1%}.p-fluid .p-inputnumber-buttons-vertical .p-inputnumber-input{width:100%}.p-inputnumber-clear-icon{position:absolute;top:50%;margin-top:-.5rem;cursor:pointer}.p-inputnumber-clearable{position:relative}}\n"],encapsulation:2,changeDetection:0})}return r})(),sy=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ah,Nx,Nf,Sh,lm,ME,Tu]})}return r})(),F1=(()=>{class r{static \u0275fac=function(n){return new(n||r)};static \u0275mod=e.\u0275\u0275defineNgModule({type:r});static \u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ag,sy,Ji.FormsModule,Tu,wh,oy,SE,v1,_1,Ag,sy,Ji.FormsModule,Tu]})}return r})();class kp{getStatus(v){return""}checkAccess(v,t,n){let o=n||[];if(v&&v.acl&&(o=v.acl),!o||!o.length)return!0;const f={};return t.forEach(D=>f[D]=D),o.every(D=>f[D])}}var $g=function(r){return r.onLineItemAdd="onLineItemAdd",r.onLineItemRemove="onLineItemRemove",r}($g||{});class ep{constructor(v=null,t=null,n=null,o=null,f=null,D=null,j=null){this.klass=v,this.onClick=t,this.label=n,this.icon=o,this.labelKey=f,this.titleKey=D,this.labelModule=j}static fromButton(v){return new ep(v.klass,v.onClick,v.label,v.icon,v.labelKey,v.titleKey,v.labelModule)}static appendClasses(v,t){if(v.klass)if("string"!=typeof v.klass){if(v.klass instanceof Array||v.klass instanceof Set)v.klass=[...v.klass,...t];else if(v.klass instanceof Object){const n={...v.klass};n[t.join(" ")]=!0,v.klass=n}}else v.klass=t.join(" ")+" "+v.klass;else v.klass=t}addClasses(v){if(this.klass)if("string"!=typeof this.klass){if(this.klass instanceof Array||this.klass instanceof Set)this.klass=[...this.klass,...v];else if(this.klass instanceof Object){const t={...this.klass};t[v.join(" ")]=!0,this.klass=t}}else this.klass=v.join(" ")+" "+this.klass;else this.klass=v}}class um{constructor(){this.map={default:{values:{},exclude:[]}}}init(v){Object.keys(v).forEach(t=>{v[t].values&&Object.keys(v[t].values).forEach(n=>{this.addEntry(t,n,v[t].values[n])}),v[t].exclude&&v[t].exclude.forEach(n=>this.excludeEntry(t,n))})}addEntry(v,t,n){v in this.map||(this.map[v]={values:{},exclude:[]}),this.map[v].values[t]=n}excludeEntry(v,t){v in this.map||(this.map[v]={values:{},exclude:[]}),this.map[v].exclude.push(t)}getGroupEntries(v){const t={},n={...this.map.default.values};let o={values:{},exclude:[]};return v in this.map&&(o=this.map[v],o.values=o.values||{},o.exclude=o.exclude||[]),Object.keys(o.values).forEach(f=>{n[f]=o.values[f]}),Object.keys(n).forEach(f=>{this.map.default.exclude.includes(f)||o.exclude.includes(f)||(t[f]=n[f])}),t}}class jd{constructor(){this.init()}static getKey(v){return v}register(v,t,n){this.map.addEntry(v,jd.getKey(t),n)}exclude(v,t){this.map.excludeEntry(v,t)}get(v,t){const n=this.map.getGroupEntries(v);let o=jd.getKey(t);return n[o]?n[o]:null}has(v,t){return!!this.map.getGroupEntries(v)[jd.getKey(t)]}init(){this.map=new um,this.initDefault()}initDefault(){}}class Hx{constructor(){this.loading=(0,e.signal)(!1),this.fieldDependencies={},this.attributeDependencies=[],this.defaultValueInitialized=!1,this.valueSubject=new i.BehaviorSubject({}),this.valueChanges$=this.valueSubject.asObservable(),this.display=(0,e.signal)("default"),this.required=(0,e.signal)(!1)}get value(){return this.valueState}set value(v){const t=v!==this.valueState;this.valueState=v,t&&this.emitValueChanges()}get valueList(){return this.valueListState}set valueList(v){this.valueListState=v,this.emitValueChanges()}get valueObject(){return this.valueObjectState}set valueObject(v){this.valueObjectState=v,this.emitValueChanges()}get valueObjectArray(){return this.valueObjectArrayState}set valueObjectArray(v){this.valueObjectArrayState=v,this.emitValueChanges()}emitValueChanges(){this.valueSubject.next({value:this.valueState,valueList:this.valueListState,valueObject:this.valueObjectState})}initDefaultValue(){if(this.defaultValueInitialized)return;const v=this?.default??this?.definition?.default??null;!this.value&&v?(this.value=v,this?.formControl?.setValue(v),this.defaultValueInitialized=!0):null===this.value&&(this.value="")}}let cy=(()=>{class r{constructor(){this.init()}register(t,n,o){this.map.addEntry(t,n,o)}exclude(t,n){this.map.excludeEntry(t,n)}get(t){return this.map.getGroupEntries(t)}has(t,n){return!!this.map.getGroupEntries(t)[n]}init(){this.map=new um}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class pp{constructor(){this.init()}getKey(v,t){return t}register(v,t,n){this.map.addEntry(v,this.getKey(v,t),n)}exclude(v,t){this.map.excludeEntry(v,t)}get(v,t){const n=this.map.getGroupEntries(v);let o=this.getKey(v,t);return n[o]?n[o]:n.default?n.default:null}has(v,t){return!!this.map.getGroupEntries(v)[this.getKey(v,t)]}init(){this.map=new um,this.initDefault()}initDefault(){}}class J0{constructor(){this.init()}getKey(v,t){return t}register(v,t,n){this.map.addEntry(v,this.getKey(v,t),n)}exclude(v,t){this.map.excludeEntry(v,t)}get(v,t){const n=this.map.getGroupEntries(v);let o=this.getKey(v,t);return n[o]?n[o]:n.default?n.default:null}has(v,t){return!!this.map.getGroupEntries(v)[this.getKey(v,t)]}init(){this.map=new um,this.initDefault()}initDefault(){}}var Pf=function(r){return r.primary="alert alert-primary",r.secondary="alert alert-secondary",r.success="alert alert-success",r.danger="alert alert-danger",r.warning="alert alert-warning",r.info="alert alert-info",r.light="alert alert-light",r.dark="alert alert-dark",r}(Pf||{});class tp{}const dr=r=>JSON.parse(JSON.stringify(r)),uy=r=>{let v=!0;return r.every(t=>!(!t||Array.isArray(t)&&t.length<=0||"object"==typeof t&&Object.keys(t).length<=0)||(v=!1,!1)),v},Wg=r=>(Object.keys(r).forEach(v=>{r[v]=String(r[v]).padStart(2,"0")}),r),_a=r=>r&&0===Object.keys(r).length,sf=r=>!1===r||"false"===r||"0"===r||0===r,cl=r=>!0===r||"true"===r||"1"===r||1===r,Al=r=>null===r||typeof r>"u",Ud=r=>"string"==typeof r&&!r.trim(),np=["detail","edit","list","create","massupdate","filter"],dm=["edit","create","massupdate","filter"],PD=r=>dm.includes(r);var hp=function(r){return r.NONE="NONE",r.ASC="ASC",r.DESC="DESC",r}(hp||{}),eu=function(r){return r.FIRST="FIRST",r.PREVIOUS="PREVIOUS",r.NEXT="NEXT",r.LAST="LAST",r}(eu||{}),Jv=function(r){return r.PAGINATION="pagination",r.LOAD_MORE="load-more",r}(Jv||{}),Xu=function(r){return r.ALL="ALL",r.SOME="SOME",r.PAGE="PAGE",r.NONE="NONE",r}(Xu||{});let e_=(()=>{class r{constructor(t){this.apollo=t}fetchAll(t,n){const f={query:X.gql`
query ${t}{
${t} {
edges {
node {
${n.fields.join("\n")}
}
}
}
}
`};return this.apollo.query(f)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const N1={configs:{},loading:!1};let tu=dr(N1),dy=null,zo=(()=>{class r{constructor(t){this.collectionGQL=t,this.store=new i.BehaviorSubject(tu),this.state$=this.store.asObservable(),this.resourceName="systemConfigs",this.fieldsMetadata={fields:["id","_id","value","items"]},this.configs$=this.state$.pipe((0,M.map)(n=>n.configs),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(n=>n.loading))}getConfigValue(t){return tu.configs&&tu.configs[t]?null!==tu.configs[t].value?tu.configs[t].value:tu.configs[t].items:null}getUi(t){return(this.getConfigValue("ui")??{})[t]??null}getHomePage(){let t="home";const n=this.getConfigValue("default_module");return n&&(t=n),t}clear(){dy=null,this.updateState(dr(N1))}clearAuthBased(){this.clear()}load(){return this.updateState({...tu,loading:!0}),this.getSystemConfigs().pipe((0,M.tap)(t=>{this.updateState({...tu,configs:t,loading:!1})}))}isCached(){return null!==dy}set(t){dy=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState({...tu,configs:t,loading:!1})}updateState(t){this.store.next(tu=t)}getSystemConfigs(){return null==dy&&(dy=this.fetch().pipe((0,M.shareReplay)(1))),dy}fetch(){return this.collectionGQL.fetchAll(this.resourceName,this.fieldsMetadata).pipe((0,M.map)(({data:t})=>{const n={};return t.systemConfigs&&t.systemConfigs.edges&&t.systemConfigs.edges.forEach(o=>{n[o.node._id]=o.node}),n}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(e_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();var $d=function(r){return r.XSmall="XSmall",r.Small="Small",r.Medium="Medium",r.Large="Large",r.XLarge="XLarge",r}($d||{});let Wd=(()=>{class r{constructor(t){this.breakpointObserver=t,this.screenSize=new i.BehaviorSubject($d.Medium),this.screenSize$=this.screenSize.asObservable(),this.initScreenSizeObservable()}initScreenSizeObservable(){(0,i.merge)(this.breakpointObserver.observe(["(max-width: 599.98px)"]).pipe((0,M.map)(t=>{if(t.matches)return $d.XSmall})),this.breakpointObserver.observe([Et_Small]).pipe((0,M.map)(t=>{if(t.matches)return $d.Small})),this.breakpointObserver.observe(["(min-width: 960px) and (max-width: 1279.98px)"]).pipe((0,M.map)(t=>{if(t.matches)return $d.Medium})),this.breakpointObserver.observe(["(min-width: 1280px) and (max-width: 1919.98px)"]).pipe((0,M.map)(t=>{if(t.matches)return $d.Large})),this.breakpointObserver.observe(["(min-width: 1920px)"]).pipe((0,M.map)(t=>{if(t.matches)return $d.XLarge}))).subscribe(t=>{t&&this.screenSize.next(t)})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(le))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),t_=(()=>{class r{constructor(t){this.apollo=t}fetch(t,n,o){const D={query:X.gql`
query ${t}($id: ID!) {
${t}(id: $id) {
${o.fields.join("\n")}
}
}
`,variables:{id:n}};return this.apollo.query(D)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Zu=(()=>{class r{constructor(){this.storageKey="scrm-session-storage",this.stickyStorageKey="scrm-sticky-session-storage"}clear(){this.getLocalStorage().removeItem(this.storageKey);const t=this.getLocalStorage().getItem(this.stickyStorageKey);t&&this.getLocalStorage().setItem(this.storageKey,t)}set(t,n,o=!1){this.store(this.storageKey,t,n),o&&this.store(this.stickyStorageKey,t,n)}store(t,n,o){const f=this.getLocalStorage().getItem(t);let D={};f&&(D=JSON.parse(f)),D[n]=o,this.getLocalStorage().setItem(t,JSON.stringify(D))}get(t){const n=this.getLocalStorage().getItem(this.storageKey);let o={};return n&&(o=JSON.parse(n)),o[t]}getLocalStorage(){return localStorage}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),BD=(()=>{class r{constructor(t){this.apollo=t}create(t,n,o,f){const j={mutation:X.gql`
mutation create${n}($input: create${n}Input!) {
create${n}(input: $input) {
${t} {
${f.fields.join("\n")}
}
clientMutationId
}
}
`,variables:{input:o}};return this.apollo.mutate(j)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const ch={id:null,_id:null,status:null,async:null,type:null,options:null,messages:[]};let bf=(()=>{class r{constructor(t){this.recordMutationGQL=t,this.graphqlName="process",this.coreName="Process",this.createFieldsMetadata={fields:["_id","status","async","type","messages","data"]}}submit(t,n){return this.create(t,n)}create(t,n){return this.recordMutationGQL.create(this.graphqlName,this.coreName,{type:t,options:n},this.createFieldsMetadata).pipe((0,M.map)(({data:f})=>{const D={...ch};return f.createProcess&&f.createProcess.process?f.createProcess.process:D}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(BD))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const eb={appStrings:{},appListStrings:{},modStrings:{},languageKey:"en_us",loaded:{},hasChanged:!1};let ld=dr(eb);const Hg={appStrings:{},appListStrings:{},modStrings:{}};let Cf={},fm=dr(Hg),Kr=(()=>{class r{constructor(t,n,o,f){this.recordGQL=t,this.localStorage=n,this.processService=o,this.configs=f,this.store=new i.BehaviorSubject(ld),this.state$=this.store.asObservable(),this.config={appStrings:{fetch:"fetchAppStrings",resourceName:"appStrings",metadata:{fields:["id","_id","items"]}},appListStrings:{fetch:"fetchAppListStrings",resourceName:"appListStrings",metadata:{fields:["id","_id","items"]}},modStrings:{fetch:"fetchModStrings",resourceName:"modStrings",metadata:{fields:["id","_id","items"]}}},this.appStrings$=this.state$.pipe((0,M.map)(D=>D.appStrings),(0,M.distinctUntilChanged)()),this.appListStrings$=this.state$.pipe((0,M.map)(D=>D.appListStrings),(0,M.distinctUntilChanged)()),this.modStrings$=this.state$.pipe((0,M.map)(D=>D.modStrings),(0,M.distinctUntilChanged)()),this.languageKey$=this.state$.pipe((0,M.map)(D=>D.languageKey),(0,M.distinctUntilChanged)()),this.vm$=this.appStrings$.pipe((0,i.combineLatestWith)(this.appListStrings$,this.modStrings$,this.languageKey$),(0,M.map)(([D,j,fe,Ne])=>({appStrings:D,appListStrings:j,modStrings:fe,languageKey:Ne})))}clear(){Cf={},fm=dr(Hg),this.updateState(dr(eb))}clearAuthBased(){["modStrings","appListStrings"].forEach(n=>{Cf&&Cf[n]&&delete Cf[n]}),fm.modStrings={},fm.appListStrings={}}changeLanguage(t,n=!1){const o=[];return Object.keys(Cf).forEach(f=>Cf[f]&&o.push(f)),ld.hasChanged=!0,this.load(t,o,n).pipe((0,M.tap)(()=>{this.localStorage.set("selected_language",t,!0)}))}getLanguageStrings(){return ld?{appStrings:ld.appStrings,appListStrings:ld.appListStrings,modStrings:ld.modStrings,languageKey:ld.languageKey}:null}getAppString(t){return ld.appStrings&&ld.appStrings[t]?ld.appStrings[t]:null}getAppListString(t){return ld.appListStrings&&ld.appListStrings[t]?ld.appListStrings[t]:null}getModString(t){return ld.modStrings&&ld.modStrings[t]?ld.modStrings[t]:null}getFieldLabel(t,n=null,o=null){let f=o;if(o||(f=this.getLanguageStrings()),!f||!f.modStrings||!t)return"";let D="";return n&&(D=f.modStrings[n]&&f.modStrings[n][t]),D||(D=f.appStrings&&f.appStrings[t]),D||""}getListLabel(t,n){if(!t||!n)return"";const o=this.getAppListString(t);return o&&o[n]||""}getAvailableStringsTypes(){return Object.keys(this.config)}hasLanguageChanged(){return ld.hasChanged}getCurrentLanguage(){return this.localStorage.get("selected_language")||(ld.languageKey??"en_us")}getActiveLanguage(){return ld.languageKey??""}getSelectedLanguage(){return this.localStorage.get("selected_language")??""}isLanguageEnabled(t){if(!t)return!1;const n=this.configs.getConfigValue("languages")??{},o=this.getDisabledLanguages(),f=Object.keys(n);return!!f.length&&f.includes(t)&&!o.includes(t)}getDisabledLanguages(){const t=this.configs.getConfigValue("disabled_languages")??"";return(0,wt.isString)(t)&&""!==t?t.replace(" ","").split(","):[]}getEnabledLanguages(){const t=this.configs.getConfigValue("languages")??{},n=this.getDisabledLanguages(),o={};return Object.keys(t).filter(D=>!n.includes(D)).forEach(D=>{o[D]=t[D]}),o}getFirstLanguage(){const t=this.configs.getConfigValue("languages")??{};return Object.keys(t).sort()[0]??""}load(t,n,o=!1){const f=[];return n.forEach(D=>f.push(this.getStrings(t,D,o))),(0,i.forkJoin)(f).pipe((0,M.first)(),(0,M.tap)(D=>{const j={...ld,languageKey:t};n.forEach((fe,Ne)=>{j[fe]=D[Ne],Cf[fe]=!0}),this.updateState(j)}))}areAllCached(){let t=!0;return t=t&&!_a(fm?.appStrings??{}),t=t&&!_a(fm?.appListStrings??{}),t=t&&!_a(fm?.modStrings??{}),t}set(t,n){const o={...ld,languageKey:t};n.appStrings&&!_a(n.appStrings)&&(fm.appStrings[t]=(0,i.of)(n.appStrings).pipe((0,M.shareReplay)(1)),o.appStrings=n.appStrings,Cf.appStrings=!0),n.appListStrings&&!_a(n.appListStrings)&&(fm.appListStrings[t]=(0,i.of)(n.appListStrings).pipe((0,M.shareReplay)(1)),o.appListStrings=n.appListStrings,Cf.appListStrings=!0),n.modStrings&&!_a(n.modStrings)&&(fm.modStrings[t]=(0,i.of)(n.modStrings).pipe((0,M.shareReplay)(1)),o.modStrings=n.modStrings,Cf.modStrings=!0),this.updateState(o)}setSessionLanguage(){return this.processService.submit("set-session-language",{language:ld.languageKey}).pipe((0,M.take)(1))}setUserLanguage(){return this.processService.submit("set-user-language",{language:ld.languageKey}).pipe((0,M.take)(1))}updateState(t){this.store.next(ld=t)}getStrings(t,n,o=!1){const f=fm[n];return f[t]&&!1===o||(f[t]=this[this.config[n].fetch](t).pipe((0,M.shareReplay)(1))),f[t]}fetchAppStrings(t){return this.recordGQL.fetch(this.config.appStrings.resourceName,`/api/app-strings/${t}`,this.config.appStrings.metadata).pipe((0,M.map)(({data:f})=>{let D={};return f.appStrings&&(D=f.appStrings.items),D}))}fetchAppListStrings(t){return this.recordGQL.fetch(this.config.appListStrings.resourceName,`/api/app-list-strings/${t}`,this.config.appListStrings.metadata).pipe((0,M.map)(({data:f})=>{let D={};return f.appListStrings&&(D=f.appListStrings.items),D}))}fetchModStrings(t){return this.recordGQL.fetch(this.config.modStrings.resourceName,`/api/mod-strings/${t}`,this.config.modStrings.metadata).pipe((0,M.map)(({data:f})=>{let D={};return f.modStrings&&(D=f.modStrings.items),D}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t_),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),VD=(()=>{class r{constructor(t,n="loading_display_delay"){this.config=t,this.delayConfigKey=n,this.loadingStore=new i.BehaviorSubject(!1),this.loadingBufferStore=new i.BehaviorSubject(!1),this.subs=[],this.buffered=!1,this.loading$=this.loadingStore.asObservable();const o=t.getConfigValue("ui")??{},f=parseInt(o[n]??"")??1500;this.loadingBufferStore$=this.loadingBufferStore.asObservable().pipe((0,M.debounceTime)(f)),this.subs.push(this.loadingBufferStore$.subscribe(D=>{this.buffered&&this.loadingStore.next(D)}))}updateLoading(t){if(!0===t)return this.buffered=!0,void this.loadingBufferStore.next(t);this.buffered=!1,this.loadingStore.next(t),this.loadingBufferStore.next(t)}static#e=this.\u0275fac=function(n){e.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),zg=(()=>{class r{constructor(t){this.config=t}create(t="loading_display_delay"){return new VD(this.config,t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const jD={loading:!1,initialAppLoading:!0,module:null,view:null,loaded:!1,routeUrl:null,preLoginUrl:null,currentUser:null,activeRequests:0,prevRoutes:[],isSidebarVisible:!1,activeNavbarDropdown:0};let Dl=dr(jD),tl=(()=>{class r{constructor(t,n){this.loadingBufferFactory=t,this.configs=n,this.store=new i.BehaviorSubject(Dl),this.state$=this.store.asObservable(),this.loadingQueue={},this.subs=[],this.isLoginWizardCompleted=(0,e.signal)(!0),this.loading$=this.state$.pipe((0,M.map)(o=>o.loading),(0,M.distinctUntilChanged)()),this.module$=this.state$.pipe((0,M.map)(o=>o.module),(0,M.distinctUntilChanged)()),this.view$=this.state$.pipe((0,M.map)(o=>o.view),(0,M.distinctUntilChanged)()),this.initialAppLoading$=this.state$.pipe((0,M.map)(o=>o.initialAppLoading),(0,M.distinctUntilChanged)()),this.activeRequests$=this.state$.pipe((0,M.map)(o=>o.activeRequests),(0,M.distinctUntilChanged)()),this.isSidebarVisible$=this.state$.pipe((0,M.map)(o=>o.isSidebarVisible),(0,M.distinctUntilChanged)()),this.activeNavbarDropdown$=this.state$.pipe((0,M.map)(o=>o.activeNavbarDropdown),(0,M.distinctUntilChanged)()),this.vm$=this.loading$.pipe((0,i.combineLatestWith)(this.module$,this.view$,this.initialAppLoading$),(0,M.map)(([o,f,D,j])=>({loading:o,module:f,view:D,loaded:Dl.loaded,initialAppLoading:j,isSidebarVisible:Dl.isSidebarVisible,activeNavbarDropdown:Dl.activeNavbarDropdown})))}clear(){this.loadingQueue={},this.updateState(dr(jD)),this.subs.forEach(t=>t.unsubscribe())}clearAuthBased(){}init(){this.initLoadingBuffer()}isLoggedIn(){return!!Dl.currentUser}getCurrentUser(){return Dl.currentUser}setCurrentUser(t){Al(t)?this.onLogout():this.onLogin(),this.updateState({...Dl,currentUser:t})}onLogin(){}onLogout(){this.updateState({...Dl,preLoginUrl:null})}getActiveRequests(){return Dl.activeRequests}addActiveRequest(){let t=Dl.activeRequests;Al(t)&&(t=0),t++,this.updateState({...Dl,activeRequests:t})}removeActiveRequest(){let t=Dl.activeRequests;Al(t)?t=0:t--,t<0&&(t=0),this.updateState({...Dl,activeRequests:t})}updateLoading(t,n,o=!0){if(this.initLoadingBuffer(),!0===n)return this.addToLoadingQueue(t),this.loadingBuffer.updateLoading(n),void(o||this.updateState({...Dl,loading:n}));this.removeFromLoadingQueue(t),this.hasActiveLoading()&&(this.loadingBuffer.updateLoading(n),this.updateState({...Dl,loading:n}))}updateInitialAppLoading(t){this.updateState({...Dl,initialAppLoading:t})}isLoaded(){return Dl.loaded}setLoaded(t){this.updateState({...Dl,loaded:t})}setModule(t){this.updateState({...Dl,module:t})}getModule(){return Dl?.module??""}setView(t){this.updateState({...Dl,view:t})}getView(){return Dl.view}setRouteUrl(t){this.updateState({...Dl,routeUrl:t})}getRouteUrl(){return Dl.routeUrl}setPreLoginUrl(t){this.updateState({...Dl,preLoginUrl:t})}getPreLoginUrl(){return Dl.preLoginUrl??""}initLoadingBuffer(){this.loadingBuffer||(this.loadingBuffer=this.loadingBufferFactory.create(),this.subs.push(this.loadingBuffer.loading$.subscribe(t=>{this.updateState({...Dl,loading:t})})))}hasActiveLoading(){return Object.keys(this.loadingQueue).length<1}removeFromLoadingQueue(t){this.loadingQueue[t]&&delete this.loadingQueue[t]}addToLoadingQueue(t){this.loadingQueue[t]=!0}updateState(t){this.store.next(Dl=t)}toggleSidebar(){this.updateState({...Dl,isSidebarVisible:!Dl.isSidebarVisible})}closeSidebar(){this.updateState({...Dl,isSidebarVisible:!1})}getLatestPrevRoute(){return Dl.prevRoutes[Dl.prevRoutes.length-2]}getPrevRoutes(){return Dl.prevRoutes}addToPrevRoute(t){const n=this.getPrevRoutes();n.length>0&&n[n.length-1]===t||(n.push(t),this.updateState({...Dl}))}removeLatestPrevRoute(){const t=this.getPrevRoutes(),n=t.slice(0,t.length-1);this.updateState({...Dl,prevRoutes:n})}removeAllPrevRoutes(){this.updateState({...Dl,prevRoutes:[]})}setActiveDropdown(t){this.updateState({...Dl,activeNavbarDropdown:t})}getActiveDropdown(){return Dl.activeNavbarDropdown}resetActiveDropdown(){this.updateState({...Dl,activeNavbarDropdown:0})}setLoginWizardComplete(t){this.isLoginWizardCompleted.set(t)}getLoginWizardComplete(){return this.isLoginWizardCompleted()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zg),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const R1={theme:null,images:{}};let L1=dr(R1),Pp=null,mp=null,uh=(()=>{class r{constructor(t,n,o){this.recordGQL=t,this.appStateStore=n,this.iconRegistry=o,this.store=new i.BehaviorSubject(L1),this.state$=this.store.asObservable(),this.resourceName="themeImages",this.frontendName="theme-images",this.fieldsMetadata={fields:["id","_id","items"]},this.images$=this.state$.pipe((0,M.map)(f=>f.images),(0,M.distinctUntilChanged)())}clear(){Pp=null,mp=null,this.updateState(dr(R1))}clearAuthBased(){}changeTheme(t){this.appStateStore.updateLoading("change-theme",!0),this.load(t).pipe((0,M.tap)(()=>this.appStateStore.updateLoading("change-theme",!1))).subscribe()}getTheme(){return L1.theme}load(t){return this.getThemeImages(t).pipe((0,M.tap)(n=>{this.updateState({...L1,images:n,theme:t})}))}isCached(){return null!==mp}set(t,n){Pp=t,this.registerSvgs(n),mp=(0,i.of)(n).pipe((0,M.shareReplay)(1)),this.updateState({...L1,images:n})}updateState(t){this.store.next(L1=t)}getThemeImages(t){return(Pp!==t||null===mp)&&(Pp=t,mp=this.fetch(t).pipe((0,M.shareReplay)(1))),mp}registerSvgs(t){Object.keys(t).forEach(n=>{const o=t[n],f=o.content??"",D=o.name??"";""===f||""===D||this.iconRegistry.addSvg(D,f)})}fetch(t){return this.recordGQL.fetch(this.resourceName,`/api/${this.frontendName}/${t}`,this.fieldsMetadata).pipe((0,M.map)(({data:n})=>{let o={};if(n&&n.themeImages&&(o=n.themeImages.items),!_a(o)){const f={};return this.registerSvgs(o),Object.keys(o).forEach(D=>{const{content:j,...fe}=o[D]??{};f[D]=fe}),f}return o}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t_),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(fn.SvgIconRegistryService))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function zx(r,v){if(1&r&&e.\u0275\u0275element(0,"svg-icon",3),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275classMapInterpolate2("",n.wrapperClass," image-",t.name,""),e.\u0275\u0275propertyInterpolate("name",t.name),e.\u0275\u0275property("svgClass",n.klass||"")("title",n.title||"")}}function Gm(r,v){if(1&r&&e.\u0275\u0275element(0,"img",4),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275classMapInterpolate2("",n.klass," image-",t.name,""),e.\u0275\u0275propertyInterpolate("src",t.path,e.\u0275\u0275sanitizeUrl),e.\u0275\u0275property("title",n.title||"")}}function AM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,zx,1,7,"svg-icon",1)(2,Gm,1,6,"img",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","svg"===t.type),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","svg"!==t.type)}}let Bl=(()=>{class r{set image(t){this.imageName.set(t),this.getImage()}constructor(t){this.themeImagesStore=t,this.klass="",this.title="",this.wrapperClass="sicon",this.images$=this.themeImagesStore.images$,this.imageSig=(0,e.signal)({}),this.imageName=(0,e.signal)(""),this.imageMap={images:{}},this.subs=[]}ngOnInit(){this.subs.push(this.images$.pipe((0,M.filter)(t=>null!==t),(0,M.map)(t=>({images:t})),(0,M.tap)(t=>this.imageMap={...t}),(0,M.tap)(()=>this.getImage())).subscribe())}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[]}getImage(){if(!this.imageMap||!this.imageMap.images||Object.keys(this.imageMap.images).length<1)return null;this.imageSig.update(()=>this.imageMap.images[this.imageName()]),this.imageSig()||console.warn(`Image with name '${this.imageName()}' not found`)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(uh))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-image"]],inputs:{klass:"klass",title:"title",wrapperClass:"wrapperClass",image:"image"},decls:1,vars:1,consts:[[4,"ngIf"],[3,"svgClass","title","class","name",4,"ngIf"],["alt","",3,"src","class","title",4,"ngIf"],[3,"svgClass","title","name"],["alt","",3,"src","title"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,AM,3,2,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.imageSig())},dependencies:[ve.NgIf,fn.SvgIconComponent],encapsulation:2,changeDetection:0})}return r})();function n_(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.language.getFieldLabel(t.labelKey,t.module)," ")}}function jE(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.language.getListLabel(t.listKey,t.labelKey)," ")}}function Gx(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,n_,2,1,"ng-container",0)(2,jE,2,1,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.listKey&&t.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.listKey&&t.labelKey)}}let Pa=(()=>{class r{constructor(t){this.language=t,this.labelKey="",this.module=null,this.listKey=null,this.languages$=this.language.vm$}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-label"]],inputs:{labelKey:"labelKey",module:"module",listKey:"listKey"},decls:2,vars:3,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Gx,3,2,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.languages$))},dependencies:[ve.NgIf,ve.AsyncPipe],encapsulation:2})}return r})();const tb=["*"];function UE(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",4),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("image",t.config.icon)("klass",t.config.iconKlass||"")("title",t.language.getFieldLabel(t.config.titleKey||""))}}function i_(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.config.label||"")}}function yu(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-label",5),2&r){let t;const n=e.\u0275\u0275nextContext();e.\u0275\u0275property("labelKey",n.config.labelKey)("module",null!==(t=n.config.labelModule)&&void 0!==t?t:"")}}let xc=(()=>{class r{constructor(t){this.language=t,this.clickBuffer=new i.Subject,this.clickBuffer$=this.clickBuffer.asObservable(),this.subs=[]}ngOnInit(){const t=this.config?.debounceClick??null;this.clickCallBack=this.config?.onClick??null;const n=this.getDebounceTime();t&&this.clickCallBack&&this.subs.push(this.clickBuffer$.pipe((0,M.debounceTime)(n)).subscribe(o=>{this.clickCallBack(o??null)}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}runClick(t){if(this.clickCallBack){if(this.config?.debounceClick&&this.clickCallBack)return void this.clickBuffer.next(t??null);this.clickCallBack(t??null)}}getDebounceTime(){let t=this.config?.clickDebounceTime??625;return isFinite(t)||(t=625),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-button"]],inputs:{config:"config"},ngContentSelectors:tb,decls:5,vars:6,consts:[["type","button",3,"click","ngClass","disabled","title"],[3,"image","klass","title",4,"ngIf"],[4,"ngIf"],[3,"labelKey","module",4,"ngIf"],[3,"image","klass","title"],[3,"labelKey","module"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"button",0),e.\u0275\u0275listener("click",function(D){return o.runClick(D)}),e.\u0275\u0275template(1,UE,1,3,"scrm-image",1)(2,i_,2,1,"ng-container",2)(3,yu,1,2,"scrm-label",3),e.\u0275\u0275projection(4),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("ngClass",o.config.klass)("disabled",(null==o.config?null:o.config.disabled)||"")("title",o.language.getFieldLabel(o.config.titleKey)||(null==o.config?null:o.config.title)||""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.config.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.labelKey))},dependencies:[ve.NgClass,ve.NgIf,Bl,Pa],encapsulation:2})}return r})();const k1=["*"];function hc(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",5),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("image",t.item.icon)}}function $E(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",5),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275property("image",t.icon)}}function gp(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"li",9)(1,"a",10),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.click(o))}),e.\u0275\u0275template(2,$E,1,1,"scrm-image",2),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",t&&t.klass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t&&t.label," ")}}function UD(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6)(1,"ul",7),e.\u0275\u0275template(2,gp,4,3,"li",8),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngbCollapse",t.isCollapsed),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.item.items)}}let WE=(()=>{class r{constructor(){this.itemClicked=new e.EventEmitter,this.isCollapsed=!0}ngOnInit(){}click(t){t&&t.onClick&&t.onClick(),this.itemClicked.emit(!0)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dropdown-submenu"]],inputs:{item:"item"},outputs:{itemClicked:"item-clicked"},ngContentSelectors:k1,decls:8,vars:3,consts:[[1,"dropdown-submenu-items-container"],[1,"dropdown-submenu-parent-button","dropdown-item","dropdown-toggle",3,"click"],[3,"image",4,"ngIf"],[3,"ngbCollapse",4,"ngIf"],[1,"dropdown-submenu-extra"],[3,"image"],[3,"ngbCollapse"],[1,"dropdown-submenu","pl-2","mb-1"],["class","dropdown-submenu-item dropdown-item",4,"ngFor","ngForOf"],[1,"dropdown-submenu-item","dropdown-item"],[1,"action-link","dropdown-submenu-item-link",3,"click","ngClass"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"div")(1,"div",0)(2,"a",1),e.\u0275\u0275listener("click",function(){return o.isCollapsed=!o.isCollapsed}),e.\u0275\u0275template(3,hc,1,1,"scrm-image",2),e.\u0275\u0275text(4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,UD,3,2,"div",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",4),e.\u0275\u0275projection(7),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.item&&o.item.icon),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",o.item&&o.item.label," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.item&&o.item.items.length))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,Bl,ct.NgbCollapse],encapsulation:2})}return r})(),Hd=(()=>{class r{transform(t,n){return t.length<=n?t:t.slice(0,n)+"..."}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"truncate",type:r,pure:!0,standalone:!0})}return r})();const P1=r=>({item:r});function TA(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",7),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("image",t.config.icon)("klass",t.config.iconKlass||"")}}function Gg(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"truncate"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind2(2,1,t.config.label,t.charSize.maxLength)," ")}}function Kx(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",8),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.config.labelKey)}}function HE(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Bf(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,HE,1,0,"ng-container",13),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275nextContext(3);const n=e.\u0275\u0275reference(10);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,P1,t))}}function zE(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",10)(1,"div",11),e.\u0275\u0275element(2,"scrm-label",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,Bf,2,4,"ng-container",12),e.\u0275\u0275elementEnd()),2&r){let t,n;const o=v.$implicit,f=v.last,D=v.first;e.\u0275\u0275classProp("section-split",!D)("last-section",f)("first-section",D),e.\u0275\u0275property("ngClass",null!==(t=o.klass)&&void 0!==t?t:""),e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",null!==(n=null!==(n=o.labelKey)&&void 0!==n?n:o.label)&&void 0!==n?n:""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",o.items)}}function OM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,zE,4,9,"div",9),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.sections)}}function Od(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function GE(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Od,1,0,"ng-container",13),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275nextContext(2);const n=e.\u0275\u0275reference(10);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n)("ngTemplateOutletContext",e.\u0275\u0275pureFunction1(2,P1,t))}}function $D(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,GE,2,4,"ng-container",12),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.config.items)}}function FM(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"scrm-image",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).item;e.\u0275\u0275advance(),e.\u0275\u0275property("image",t.icon)("klass",t.iconKlass||"")}}function NM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).item;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.label," ")}}function qx(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-label",18),2&r){let t;const n=e.\u0275\u0275nextContext(3).item;e.\u0275\u0275property("labelKey",n.labelKey)("module",null!==(t=n.labelModule)&&void 0!==t?t:"")}}function Bp(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,qx,1,2,"scrm-label",17),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).item;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t&&t.labelKey)}}function Fd(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",14),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext().item,f=e.\u0275\u0275nextContext(),D=e.\u0275\u0275reference(1);return e.\u0275\u0275resetView(o&&f.click(o.onClick,D))}),e.\u0275\u0275elementStart(2,"div",15),e.\u0275\u0275template(3,FM,2,2,"div",5),e.\u0275\u0275elementStart(4,"div",16),e.\u0275\u0275template(5,NM,2,1,"ng-container",5)(6,Bp,2,1,"ng-container",5),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext().item,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",t&&t.klass)("title",n.language.getFieldLabel(null==t?null:t.titleKey)||(null==t?null:t.title)||""),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t&&t.label),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t&&!t.label&&t.labelKey)}}function Qx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"scrm-dropdown-submenu",19),e.\u0275\u0275listener("item-clicked",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2),f=e.\u0275\u0275reference(1);return e.\u0275\u0275resetView(o.close(f))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext().item;e.\u0275\u0275advance(),e.\u0275\u0275property("item",t)}}function KE(r,v){if(1&r&&e.\u0275\u0275template(0,Fd,7,5,"ng-container",5)(1,Qx,2,1,"ng-container",5),2&r){const t=v.item,n=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngIf",t&&!n.isDropdown(t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t&&n.isDropdown(t))}}let pm=(()=>{class r{constructor(t,n){this.language=t,this.systemConfigStore=n,this.disabled=!1,this.autoClose=!0,this.sections=[],this.sectionsEnabled=!1,this.charSize={minLength:20,mediumLength:20,maxLength:20}}isDropdown(t){return!!t&&"items"in t}click(t,n){t(),n.close()}close(t){t.close()}ngOnInit(){if(this.config&&!this.config.placement&&(this.config.placement=["bottom-left","bottom-right","top-left","top-right"]),this.sections=[],_a(this.config?.sections??{}))return void(this.sectionsEnabled=!1);this.sectionsEnabled=!0,this.preprocessItems(this.config?.items??[]);const n=this.systemConfigStore.getUi("navbar_truncate_character_sizes");this.charSize={...n}}preprocessItems(t){const n=this.config?.sections??{},o={};!t||!t.length||(t.forEach(f=>{this.getSection(n,f?.section??"default",o).items.push(f)}),Object.keys(n).forEach(f=>{const D=o[f];D&&D.items&&D.items.length&&this.sections.push(D)}))}getSection(t,n,o){let D=o[n]??null;return null===D&&(D=dr(t[n]??{}),D.items=[],o[n]=D),D}getPlacement(){return this.config&&!this.config.placement?["bottom-left","bottom-right","top-left","top-right"]:this.config.placement}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dropdown-button"]],inputs:{config:"config",disabled:"disabled",autoClose:"autoClose"},decls:11,vars:13,consts:[["dropDown","ngbDropdown"],["buttonTemplate",""],["ngbDropdown","",1,"d-inline-block","dropdown-button",3,"autoClose","placement","ngClass"],["ngbDropdownToggle","",3,"disabled","ngClass","title"],[3,"image","klass",4,"ngIf"],[4,"ngIf"],["ngbDropdownMenu",""],[3,"image","klass"],[3,"labelKey"],[3,"ngClass","section-split","last-section","first-section",4,"ngFor","ngForOf"],[3,"ngClass"],[1,"dropdown-menu-item-header"],[4,"ngFor","ngForOf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["ngbDropdownItem","",3,"click","ngClass","title"],[1,"d-flex","align-items-center"],[1,"dropdown-item-label","flex-grow-1"],[3,"labelKey","module",4,"ngIf"],[3,"labelKey","module"],[3,"item-clicked","item"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",2,0)(2,"button",3),e.\u0275\u0275template(3,TA,1,2,"scrm-image",4)(4,Gg,3,4,"ng-container",5)(5,Kx,2,1,"ng-container",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",6),e.\u0275\u0275template(7,OM,2,1,"ng-container",5)(8,$D,2,1,"ng-container",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(9,KE,2,2,"ng-template",null,1,e.\u0275\u0275templateRefExtractor)),2&n&&(e.\u0275\u0275classProp("sectioned-dropdown-menu",o.sectionsEnabled),e.\u0275\u0275property("autoClose",o.autoClose)("placement",o.getPlacement())("ngClass",o.config.wrapperKlass),e.\u0275\u0275advance(2),e.\u0275\u0275property("disabled",o.disabled)("ngClass",o.config.klass)("title",o.language.getFieldLabel(o.config.titleKey)||""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.label),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.config.label&&o.config.labelKey),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.sectionsEnabled),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.sectionsEnabled))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,ct.NgbDropdown,ct.NgbDropdownToggle,ct.NgbDropdownMenu,ct.NgbDropdownItem,Bl,WE,Pa,Hd],encapsulation:2,changeDetection:0})}return r})();function $c(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",3),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("config",t)}}function Yx(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,$c,2,1,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.config.items)}}let WD=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-grouped-button"]],inputs:{config:"config"},decls:2,vars:2,consts:[["role","group",1,"btn-group","grouped-button",3,"ngClass"],[4,"ngIf"],[4,"ngFor","ngForOf"],[3,"config"]],template:function(n,o){if(1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,Yx,2,1,"ng-container",1),e.\u0275\u0275elementEnd()),2&n){let f;e.\u0275\u0275property("ngClass",null!==(f=null==o.config?null:o.config.wrapperKlass)&&void 0!==f?f:""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",null==o.config?null:o.config.items)}},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,xc],encapsulation:2,changeDetection:0})}return r})();function Kg(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",4),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275property("config",t)}}function B1(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-dropdown-button",4),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275property("config",t)}}function Xx(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-grouped-button",4),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275property("config",t)}}function V1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Kg,1,1,"scrm-button",3)(2,B1,1,1,"scrm-dropdown-button",3)(3,Xx,1,1,"scrm-grouped-button",3),e.\u0275\u0275elementContainerEnd()),2&r){let t,n,o;const f=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",f&&!(null!==(t=null==f?null:f.items)&&void 0!==t&&t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",f&&(null!==(n=null==f?null:f.items)&&void 0!==n?n:"")&&"dropdown"===(null!==(n=null==f?null:f.type)&&void 0!==n?n:"dropdown")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",f&&(null!==(o=null==f?null:f.items)&&void 0!==o?o:"")&&"grouped"===(null!==(o=null==f?null:f.type)&&void 0!==o?o:"dropdown"))}}function RM(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-dropdown-button",5),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",t.dropdownConfig)}}function j1(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,V1,4,3,"ng-container",1)(2,RM,1,1,"scrm-dropdown-button",2),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMap(t.klass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.buttons.expanded),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.buttons.collapsed.length)}}let nb=(()=>{class r{constructor(){this.klass="",this.buttons={expanded:[],collapsed:[]}}ngOnInit(){this.sub=this.config$.subscribe(t=>{this.internalConfig={...t},this.splitButtons()})}ngOnDestroy(){this.sub.unsubscribe()}buildDropdownConfig(){let t=["button-group-button"];this.internalConfig.buttonKlass&&this.internalConfig.buttonKlass.length>0&&(t=t.concat(this.internalConfig.buttonKlass)),this?.internalConfig?.dropdownOptions?.klass&&(t=t.concat(this.internalConfig.dropdownOptions.klass));let n=["button-group-dropdown"];const o=this.internalConfig.dropdownOptions,f=o&&o.wrapperKlass;f&&f.length>0&&(n=n.concat(f)),this.dropdownConfig={label:this.internalConfig.dropdownLabel,klass:[...t],wrapperKlass:n,items:this.buttons.collapsed},this.internalConfig.dropdownOptions&&this.internalConfig.dropdownOptions.placement&&(this.dropdownConfig.placement=this.internalConfig.dropdownOptions.placement),this.internalConfig.dropdownOptions&&this.internalConfig.dropdownOptions.icon&&(this.dropdownConfig.icon=this.internalConfig.dropdownOptions.icon)}getBreakpoint(){return this.internalConfig.breakpoint||0===this.internalConfig.breakpoint?this.internalConfig.breakpoint:4}splitButtons(){if(this.buttons.expanded=[],this.buttons.collapsed=[],!this.internalConfig.buttons||this.internalConfig.buttons.length<1)return;let t=0;const n=this.internalConfig.showAfterBreakpoint??!0;this.internalConfig.buttons.forEach(o=>{if(o){if(t<this.getBreakpoint()){let f=["button-group-button"];this.internalConfig.buttonKlass&&this.internalConfig.buttonKlass.length>0&&(f=f.concat(this.internalConfig.buttonKlass));const D={...o};ep.appendClasses(D,[...f]),this.buttons.expanded.push(D)}else!0===n&&this.buttons.collapsed.push({...o});t++}}),this.buildDropdownConfig()}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-button-group"]],inputs:{config$:"config$",klass:"klass"},decls:1,vars:1,consts:[[3,"class",4,"ngIf"],[4,"ngFor","ngForOf"],["autoClose","outside",3,"config",4,"ngIf"],[3,"config",4,"ngIf"],[3,"config"],["autoClose","outside",3,"config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,j1,3,4,"div",0),2&n&&e.\u0275\u0275property("ngIf",o.config$)},dependencies:[ve.NgForOf,ve.NgIf,xc,pm,WD],encapsulation:2})}return r})();const U1={userPreferences:{},loading:!1};let Vf=dr(U1),ib=null,$a=(()=>{class r{constructor(t,n,o,f){this.collectionGQL=t,this.config=n,this.processService=o,this.localStorage=f,this.store=new i.BehaviorSubject(Vf),this.state$=this.store.asObservable(),this.saveBufferStore=new i.BehaviorSubject(!1),this.subs=[],this.resourceName="userPreferences",this.fieldsMetadata={fields:["id","_id","value","items"]},this.userPreferences$=this.state$.pipe((0,M.map)(fe=>fe.userPreferences),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(fe=>fe.loading));const j=(n.getConfigValue("ui")??{}).user_preferences_save_delay??2500;this.saveBuffer$=this.saveBufferStore.asObservable().pipe((0,M.debounceTime)(j??2500)),this.subs.push(this.saveBuffer$.subscribe(fe=>{fe&&this.saveUiPreferences()}))}clear(){ib=null,this.updateState(dr(U1)),this.subs.forEach(t=>t.unsubscribe())}clearAuthBased(){this.clear()}getUserPreference(t){return Vf.userPreferences&&Vf.userPreferences[t]?Vf.userPreferences[t]:null}getUi(t,n){const o=t+"-"+n;return this.storageLoad(t,o)??(Vf?.userPreferences?.ui??{})[o]??null}setUi(t,n,o){const f=t+"-"+n;this.storageSave(t,f,o);const D=Vf?.userPreferences?.ui??{};D[f]=o,Vf.userPreferences.ui=D,this.saveBufferStore.next(!0)}saveUiPreferences(){this.processService.submit("save-ui-user-preferences",{preferences:Vf.userPreferences.ui}).pipe((0,M.take)(1)).subscribe()}storageSave(t,n,o){let f=this.localStorage.get(n);f||(f={}),f[t]=o,this.localStorage.set(n,f)}storageLoad(t,n){const o=this.localStorage.get(n);return o&&o[t]?o[t]:null}load(){return this.updateState({...Vf,loading:!0}),this.getUserPreferences().pipe((0,M.tap)(t=>{this.updateState({...Vf,userPreferences:t,loading:!1})}))}isCached(){return null!==ib}set(t){ib=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState({...Vf,userPreferences:t,loading:!1})}updateState(t){this.store.next(Vf=t)}getUserPreferences(){return null==ib&&(ib=this.fetch().pipe((0,M.shareReplay)(1))),ib}fetch(){return this.collectionGQL.fetchAll(this.resourceName,this.fieldsMetadata).pipe((0,M.map)(({data:t})=>{const n={};return t.userPreferences&&t.userPreferences.edges&&t.userPreferences.edges.forEach(o=>{o.node.items&&Object.keys(o.node.items).forEach(f=>{n[f]=o.node.items[f]})}),n}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(e_),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),qg=(()=>{class r{getTrimmedInputValue(t){return"string"!=typeof t?t:t.trim()}isEmptyInputValue(t){return null==t||typeof t>"u"||""===t||0===t.length}isEmptyTrimmedInputValue(t){return this.isEmptyInputValue(this.getTrimmedInputValue(t))}isEmptyBooleanInputValue(t){return this.isEmptyInputValue(t)||"false"===t||!1===t||""===t}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Qg=(()=>{class r{constructor(t,n,o){this.preferences=t,this.formUtils=n,this.locale=o}toUserFormat(t,n){if(Al(t)||""===t)return"";if(sf(n?.metadata?.format??!0))return t;const o=(0,ve.formatNumber)(Number(t),this.locale);return this.replaceSeparators(o)}toInternalFormat(t){if(!t)return t;const n=this.getDecimalsSymbol()||".",o=this.getGroupSymbol()||",";let f=new RegExp(n,"g");"."===n&&(f=new RegExp("\\.","g"));let D=new RegExp(o,"g");return"."===o&&(D=new RegExp("\\.","g")),(t=(t=(t=(t=t??"").toString().replace(D,"group_separator")).toString().replace(f,"decimal_separator")).toString().replace(/decimal_separator/g,".")).toString().replace(/group_separator/g,"")}getFloatUserFormatPattern(){const t=this.getGroupSymbol(),n=this.getDecimalsSymbol();let o="^-?(";return o+="(\\d{1,3}(\\"+t+"\\d{3})*(\\"+n+"\\d+)?)|",o+="\\d*|",o+="(\\d+(\\"+n+"\\d+)?)|",o+="(\\d+(\\.\\d+)?)",o+=")$",o}getIntUserFormatPattern(){let n="^-?(";return n+="(\\d{1,3}(\\"+this.getGroupSymbol()+"\\d{3})*)|",n+="\\d*",n+=")$",n}getGroupSymbol(){return this.preferences.getUserPreference("num_grp_sep")||","}getDecimalsSymbol(){return this.preferences.getUserPreference("dec_sep")||"."}replaceSeparators(t){if(!t)return t;t=(t=(t=t??"").toString().replace(/,/g,"group_separator")).toString().replace(/\./g,"decimal_separator");const n=this.getDecimalsSymbol()||".",o=this.getGroupSymbol()||",";return(t=t.toString().replace(/decimal_separator/g,n)).toString().replace(/group_separator/g,o)}replaceSeparatorsToInternalFormat(t){const n=this.getDecimalsSymbol()||".",o=this.toInternalFormat(t);return"."!==n&&t.includes(n)&&(t=o),t}validateIntUserFormat(t){const n=this.formUtils.getTrimmedInputValue(t);return!this.formUtils.isEmptyInputValue(n)&&!new RegExp(this.getIntUserFormatPattern()).test(n)}validateFloatUserFormat(t){const n=this.formUtils.getTrimmedInputValue(t);return!this.formUtils.isEmptyInputValue(n)&&!new RegExp(this.getFloatUserFormatPattern()).test(n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($a),e.\u0275\u0275inject(qg),e.\u0275\u0275inject(e.LOCALE_ID))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),kh=(()=>{class r{constructor(t,n,o){this.preferences=t,this.formUtils=n,this.locale=o,this.format$=this.preferences.userPreferences$.pipe((0,M.map)(()=>({date:this.getDateFormat(),time:this.getTimeFormat()})))}getDateFormat(){return this.preferences.getUserPreference("date_format")||this.getInternalDateFormat()}getTimeFormat(){const t=this.preferences.getUserPreference("time_format");if(t){let n=t;return n.includes("aaaaaa")&&(n=n.replace("aaaaaa","aaaaa'm'")),n}return this.getInternalTimeFormat()}getDateTimeFormat(){return this.getDateFormat()+" "+this.getTimeFormat()}getInternalDateFormat(){return"yyyy-MM-dd"}getInternalTimeFormat(){return"HH:mm:ss"}getInternalDateTimeFormat(){return this.getInternalDateFormat()+" "+this.getInternalTimeFormat()}getInternalFormat(){return this.getInternalDateTimeFormat()}getUserFormat(){return this.getDateTimeFormat()}toUserFormat(t,n){const o=n&&n.fromFormat||this.getInternalFormat(),f=n&&n.toFormat||this.getUserFormat();if(t){const D=this.toDateTime(t,o,{zone:"GMT"});return D.isValid?(0,ve.formatDate)(D.toJSDate(),f,this.locale,this.userTimeZone()):t}return""}toInternalFormat(t,n){const o=n&&n.fromFormat||this.getUserFormat();if(t){let f=this.toDateTime(t,o,{zone:this.preferences.getUserPreference("timezone")});return(0,ve.formatDate)(f.toJSDate(),this.getInternalFormat(),this.locale,"GMT")}return""}formatDateTime(t,n,o="",f=this.locale,D=""){const j=this.toDateTime(t,o);return j.isValid?(0,ve.formatDate)(j.toJSDate(),n,f,D):t}toDateTime(t,n="",o){if(!t)return en.DateTime.invalid("empty");if(n)return en.DateTime.fromFormat(t,n,o);let f=this.fromUserFormat(t,o);return f.isValid||(f=this.fromInternalFormat(t,o)),f}userDateTimeFormatToStruct(t){if(!t)return null;const n=this.toDateTime(t,"",{zone:this.preferences.getUserPreference("timezone")});return n.isValid?{date:{day:n.day,month:n.month,year:n.year},time:{hour:n.hour,minute:n.minute,second:n.second}}:null}internalDateTimeFormatToStruct(t){if(!t)return null;const n=this.toDateTime(t,this.getInternalDateTimeFormat(),{zone:"GMT"}),o=n.setZone(this.preferences.getUserPreference("timezone"));return n.isValid?{date:{day:o.day,month:o.month,year:o.year},time:{hour:o.hour,minute:o.minute,second:o.second}}:null}userDateFormatToStruct(t){if(!t)return null;const n=this.toDateTime(t,"",{zone:this.preferences.getUserPreference("timezone")});return n.isValid?{day:n.day,month:n.month,year:n.year}:null}dateFormatToStruct(t,n=""){if(!t)return null;const o=this.toDateTime(t,n);return o.isValid?{day:o.day,month:o.month,year:o.year}:null}userTimeFormatToStruct(t){if(!t)return null;const n=this.toDateTime(t,"",{zone:this.preferences.getUserPreference("timezone")});return n.isValid?{hour:n.hour,minute:n.minute,second:n.second}:null}fromUserFormat(t,n,o){t=(t=(t=(t=(t=this.toUserFormat(t,o)).toString()).replace("a","A")).replace("p","P")).replace("m","M");let f=this.getUserFormat();return f=f.replace("aaaaa'm'","a"),en.DateTime.fromFormat(t,f,n)}fromInternalFormat(t,n){const o=this.getInternalFormat();return en.DateTime.fromFormat(t.toString(),o,n)}validateUserFormat(t,n=""){const o=this.formUtils.getTrimmedInputValue(t);return!this.formUtils.isEmptyInputValue(o)&&!this.fromUserFormat(o,{},{fromFormat:n}).isValid}userTimeZone(){let t=this.preferences.getUserPreference("timezone")??"GMT";t||(t="GMT");const n=en.DateTime.now().setZone(t).toMillis();return en.IANAZone.create(t).formatOffset(n,"techie")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($a),e.\u0275\u0275inject(qg),e.\u0275\u0275inject(e.LOCALE_ID))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Yg=(()=>{class r{constructor(t,n,o,f){this.preferences=t,this.configs=n,this.numberFormatter=o,this.locale=f}toUserFormat(t,n=null){if(Al(t)||""===t)return"";const o=n&&n.symbol||this.getSymbol(),f=n&&n.code||this.getCode(),D=this.configs.getConfigValue("default_number_grouping_seperator");let j=null;n&&null!==n.digits&&isFinite(n.digits)&&(j=n.digits);const fe=this.getDigitsInfo(j);let Ne;return t="system"===n?.fromFormat&&t.includes(D)?t.replace(D,""):this.replaceSeparatorsToInternalFormat(t),n&&"edit"===n.mode?(Ne=(0,ve.formatNumber)(Number(t),this.locale,fe),this.replaceSeparators(Ne)):(Ne=(0,ve.formatCurrency)(Number(t),this.locale,o,f,fe),this.replaceSeparators(Ne))}toInternalFormat(t){if(!t)return"";const n=t.replace(this.getSymbol(),"");return this.numberFormatter.toInternalFormat(n)}getCurrencyFormat(){return this.preferences.getUserPreference("currency")||this.getDefaultFormat()}getDefaultFormat(){return{iso4217:"USD",name:"US Dollars",symbol:"$"}}getCode(){return this.getCurrencyFormat().iso4217}getSymbol(){return this.getCurrencyFormat().symbol}getDigits(){return this.preferences.getUserPreference("default_currency_significant_digits")||2}getDigitsInfo(t){let n="1.2-2",o=this.getDigits();return null!==t&&isFinite(t)&&(o=t),null!==o&&isFinite(o)&&(n=o<1?"1.0-0":`1.${o}-${o}`),n}replaceSeparators(t){return this.numberFormatter.replaceSeparators(t)}replaceSeparatorsToInternalFormat(t){return this.numberFormatter.replaceSeparatorsToInternalFormat(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($a),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Qg),e.\u0275\u0275inject(e.LOCALE_ID))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),r_=(()=>{class r extends kh{getInternalFormat(){return this.getInternalDateFormat()}getUserFormat(){return this.getDateFormat()}toInternalFormat(t,n){const o=n&&n.fromFormat||this.getUserFormat();if(t){let f=this.toDateTime(t,o);return(!f||!f.isValid)&&(f=this.toDateTime(t)),(0,ve.formatDate)(f.toJSDate(),this.getInternalFormat(),this.locale)}return""}toUserFormat(t,n){const o=n&&n.fromFormat||this.getInternalFormat(),f=n&&n.toFormat||this.getUserFormat();if(t){const D=this.toDateTime(t,o);return D.isValid?(0,ve.formatDate)(D.toJSDate(),f,this.locale):t}return""}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),fy=(()=>{class r{constructor(t,n){this.formUtils=t,this.systemConfigStore=n}toUserFormat(t){return t}toInternalFormat(t){return t}getDefaultFormatPattern(){return this.systemConfigStore.getUi("validations")?.regex?.phone||""}validateUserFormat(t,n){const o=this.formUtils.getTrimmedInputValue(t);return!this.formUtils.isEmptyInputValue(o)&&!new RegExp(n).test(o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(qg),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),_s=(()=>{class r{constructor(t,n,o,f,D){this.currencyFormatter=t,this.numberFormatter=n,this.dateFormatter=o,this.datetimeFormatter=f,this.phoneFormatter=D,this.map={},this.map.int=n,this.map.float=n,this.map.date=o,this.map.datetime=f,this.map.currency=t,this.map.phone=D}toUserFormat(t,n,o){if(!t)return n;const f=this.map[t];return f?f.toUserFormat(n,o):n}toInternalFormat(t,n){if(!t)return n;const o=this.map[t];return o?o.toInternalFormat(n):n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Yg),e.\u0275\u0275inject(Qg),e.\u0275\u0275inject(r_),e.\u0275\u0275inject(kh),e.\u0275\u0275inject(fy))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),rb=(()=>{class r{constructor(t,n,o,f){this.typeFormatter=t,this.language=n,this.configs=o,this.preferences=f,this.valuePipes={},this.fieldPipes={},this.valuePipes.int=D=>this.valueTypeFormat("int",D),this.valuePipes.float=D=>this.valueTypeFormat("float",D),this.valuePipes.date=D=>this.valueTypeFormat("date",D),this.valuePipes.datetime=D=>this.valueTypeFormat("datetime",D),this.valuePipes.currency=D=>this.valueTypeFormat("currency",D),this.valuePipes.enum=(D,j=[])=>this.enumFormat(D,j),this.fieldPipes.int=D=>this.fieldTypeFormat("int",D),this.fieldPipes.float=D=>this.fieldTypeFormat("float",D),this.fieldPipes.date=D=>this.fieldTypeFormat("date",D),this.fieldPipes.datetime=D=>this.fieldTypeFormat("datetime",D),this.fieldPipes.currency=D=>this.fieldTypeFormat("currency",D),this.fieldPipes.phone=D=>this.fieldTypeFormat("phone",D),this.fieldPipes.enum=D=>this.enumFieldFormat(D),this.fieldPipes.dynamicenum=D=>this.enumFieldFormat(D),this.fieldPipes.multienum=D=>this.multiEnumFormat(D)}addValuePipe(t,n){this.valuePipes[t]=n}addFieldPipe(t,n){this.fieldPipes[t]=n}parse(t,n,o){if(!t)return t;const D=t.match(/({{[\s\S]+?}})/g);if(!D||D.length<1)return t;let j=t;const fe=n&&n.module||"";return D.forEach(Ne=>{if(!j.includes(Ne))return;let vt="",ln=[],Hn="",Oi="context",Lr=[],to=""+Ne;to=to.replace("{{",""),to=to.replace("}}",""),to=to.trim();let Mr=to;if(to.includes("|")){const[Rs,Us,...wu]=to.split("|");if(vt=Us.trim(),Us.trim().includes(":")){let[Tf,...vM]=Us.trim().split(":");vt=Tf.trim(),ln=vM}to=Rs.trim(),Mr=Rs.trim()}to.includes(".")&&(Lr=to.split("."),Oi=Lr[0],to=Lr[1]);let ss=n;if("fields"===Oi&&(ss=o),"fields"===Oi){if(!ss||!(to in ss))return void(j=j.replace(Ne,Hn));const Rs=o[to];return Rs?Lr[2]&&"value"===Lr[2]&&Rs.type in this.fieldPipes?(Hn=this.fieldPipes[Rs.type](Rs),void(j=j.replace(Ne,Hn))):Lr[2]&&"label"===Lr[2]?(Hn=this.getFieldLabel(Rs.labelKey,fe),void(j=j.replace(Ne,Hn))):(Hn=(0,an.A)({fields:o},Mr,""),void(j=j.replace(Ne,Hn))):void(j=j.replace(Ne,""))}"config"!==Oi?"preferences"!==Oi?ss&&to in ss?(Hn=(0,an.A)({context:n},Mr,""),vt in this.valuePipes&&(Hn=this.valuePipes[vt](Hn)),j=j.replace(Ne,Hn)):j=j.replace(Ne,Hn):j=this.parseObjectContext(to,j,Ne,vt,ln,Rs=>this.preferences.getUserPreference(Rs)):j=this.parseObjectContext(to,j,Ne,vt,ln,Rs=>this.configs.getConfigValue(Rs))}),j}valueTypeFormat(t,n){return this.typeFormatter.toUserFormat(t,n)}enumFormat(t,n){const o=n[0]??"";return o&&t?this.language.getListLabel(o,t):""}fieldTypeFormat(t,n){return this.typeFormatter.toUserFormat(t,n.value)}enumFieldFormat(t){return Al(t.definition.options)||Al(t.value)?"":this.language.getListLabel(t.definition.options,t.value)}multiEnumFormat(t){if(Al(t.definition.options)||Al(t.valueList)||t.valueList.length<1)return"";const n=[];return t.valueList.forEach(o=>{Al(o)||n.push(this.language.getListLabel(t.definition.options,o))}),n.join(", ")}getFieldLabel(t,n=""){return Al(t)?"":this.language.getFieldLabel(t,n)}parseObjectContext(t,n,o,f,D,j){let fe=t;if(t.includes(".")){let[vt,...ln]=t.split(".");fe=vt}let Ne=j(fe);return t.includes(".")&&"object"==typeof Ne&&(Ne=(0,an.A)({value:Ne},t,"")),Ne&&"object"!=typeof Ne?(f in this.valuePipes&&(Ne=this.valuePipes[f](Ne,D)),n.replace(o,Ne)):n.replace(o,"")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function Zx(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"span",1),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t.parsedLabel)}}let Df=(()=>{class r{constructor(t,n){this.dynamicLabels=t,this.language=n,this.template="",this.labelKey="",this.context={},this.fields={},this.module=null,this.parsedLabel=""}ngOnInit(){this.vm$=this.language.vm$.pipe((0,M.tap)(()=>{this.labelKey&&(this.template=this.language.getFieldLabel(this.labelKey,this.module)),this.parseLabel()}))}ngOnChanges(t){(t.template||t.context||t.labelKey||t.fields)&&this.parseLabel()}parseLabel(){this.parsedLabel=this.dynamicLabels.parse(this.template,this.context,this.fields)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(rb),e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dynamic-label"]],inputs:{template:"template",labelKey:"labelKey",context:"context",fields:"fields",module:"module"},features:[e.\u0275\u0275NgOnChangesFeature],decls:2,vars:3,consts:[[4,"ngIf"],[1,"dynamic-label"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Zx,3,1,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe],encapsulation:2})}return r})(),HD=(()=>{class r{constructor(){this.klass=""}ngOnInit(){}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-inline-loading-spinner"]],inputs:{klass:"klass"},decls:4,vars:3,consts:[[1,"bounce1"],[1,"bounce2"],[1,"bounce3"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"div",0)(2,"div",1)(3,"div",2),e.\u0275\u0275elementEnd()),2&n&&e.\u0275\u0275classMapInterpolate1("inline-spinner ",o.klass,"")},styles:[".inline-spinner[_ngcontent-%COMP%]{text-align:center}.inline-spinner[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{border-radius:100%;display:inline-block;-webkit-animation:_ngcontent-%COMP%_sk-bouncedelay 1.4s infinite ease-in-out both;animation:_ngcontent-%COMP%_sk-bouncedelay 1.4s infinite ease-in-out both}.inline-spinner[_ngcontent-%COMP%] .bounce1[_ngcontent-%COMP%]{-webkit-animation-delay:-.32s;animation-delay:-.32s}.inline-spinner[_ngcontent-%COMP%] .bounce2[_ngcontent-%COMP%]{-webkit-animation-delay:-.16s;animation-delay:-.16s}@-webkit-keyframes _ngcontent-%COMP%_sk-bouncedelay{0%,80%,to{-webkit-transform:scale(0)}40%{-webkit-transform:scale(1)}}@keyframes _ngcontent-%COMP%_sk-bouncedelay{0%,80%,to{-webkit-transform:scale(0);transform:scale(0)}40%{-webkit-transform:scale(1);transform:scale(1)}}"]})}return r})();const Jx=()=>({});function o_(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button-group",2),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("config$",t.config$)("klass",t.buttonGroupClass)}}function LM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,o_,1,2,"scrm-button-group",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config$)}}function kM(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-label",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.confirmationLabel)}}function qE(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-dynamic-label",8),e.\u0275\u0275elementEnd()),2&r){let t,n;const o=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",o.confirmationDynamicLabel)("module",null!==(t=null==o.actionContext?null:o.actionContext.module)&&void 0!==t?t:"")("fields",null!==(n=null==o.actionContext||null==o.actionContext.record?null:o.actionContext.record.fields)&&void 0!==n?n:e.\u0275\u0275pureFunction0(3,Jx))}}function eS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",9),e.\u0275\u0275element(1,"scrm-button",10),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.inlineCancelButton)}}function tS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",9),e.\u0275\u0275element(1,"scrm-button",10),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.inlineConfirmButton)}}function zD(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",3),e.\u0275\u0275template(2,kM,2,1,"div",4)(3,qE,2,4,"div",4)(4,eS,2,1,"div",5)(5,tS,2,1,"div",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.confirmationLabel),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.confirmationDynamicLabel&&!t.confirmationLabel),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.inlineCancelButton),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.inlineConfirmButton)}}function py(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-inline-loading-spinner",11),e.\u0275\u0275elementContainerEnd())}function hy(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275template(2,LM,2,1,"ng-container",0)(3,zD,6,4,"ng-container",0)(4,py,2,0,"ng-container",0),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("",t.klass," float-right action-group-menu"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.inlineConfirmationEnabled()&&!t.loading()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.inlineConfirmationEnabled()&&!t.loading()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading())}}let Ph=(()=>{class r{constructor(t,n,o){this.languages=t,this.screenSize=n,this.systemConfigStore=o,this.klass="",this.buttonClass="btn btn-sm",this.buttonGroupClass="",this.actionLimitConfig="recordview_actions_limits",this.configState=new i.BehaviorSubject({buttons:[]}),this.config$=this.configState.asObservable(),this.inlineConfirmationEnabled=(0,e.signal)(!1),this.confirmationLabel="",this.confirmationDynamicLabel="",this.inlineCancelButton=null,this.inlineConfirmButton=null,this.loading=(0,e.signal)(!1),this.buttonGroupDropdownClass="dropdown-button-secondary",this.screen=$d.Medium,this.defaultBreakpoint=4}ngOnInit(){this.vm$=this.config?.getActions().pipe((0,i.combineLatestWith)(this.screenSize.screenSize$,this.languages.vm$),(0,M.map)(([t,n,o])=>(n&&(this.screen=n),this.configState.next(this.getButtonGroupConfig(t)),{actions:t,screenSize:n,languages:o})))}isXSmallScreen(){return this.screen===$d.XSmall}getButtonGroupConfig(t){const n=[],o=[];t.forEach(fe=>{const Ne=this.buildButton(fe);fe.params&&fe.params.collapsedMobile&&this.isXSmallScreen()?o.push(Ne):fe.params&&fe.params.expanded?n.push(Ne):o.push(Ne)});let D=t.length;!0===(this.config.collapseButtons??!0)&&(D=this.getBreakpoint(),n.length<D&&(D=n.length));const j=n.concat(o);return{buttonKlass:[this.buttonClass],dropdownLabel:this.languages.getAppString("LBL_ACTIONS")||"",breakpoint:D,dropdownOptions:{placement:["bottom-right"],wrapperKlass:[this.buttonGroupDropdownClass]},buttons:j}}getBreakpoint(){const t=this.systemConfigStore.getConfigValue(this.actionLimitConfig);return this.screen&&t&&t[this.screen]?(this.breakpoint=t[this.screen],this.breakpoint):this.breakpoint?this.breakpoint:this.defaultBreakpoint}buildButton(t){const n={label:t.label||"",labelModule:this?.actionContext?.module??"",labelKey:t.labelKey||"",klass:this.buttonClass,titleKey:t.titleKey||"",onClick:()=>{t?.params?.inlineConfirmation?(this.triggerTemporaryLoading(),this.initInlineConfirmation(t,()=>{this.config.runAction(t,this.actionContext)})):this.config.runAction(t,this.actionContext)}};n.label||(n.labelKey=t.labelKey??"");const o=t?.params?.debounceClick??null;return n.debounceClick=!0,sf(o)&&(n.debounceClick=!1),t.icon&&(n.icon=t.icon),t.status&&ep.appendClasses(n,[t.status]),t.klass&&ep.appendClasses(n,t.klass),n}triggerTemporaryLoading(){this.loading.set(!0);const t=parseInt(this.systemConfigStore.getUi("inline_confirmation_loading_delay"))??200;setTimeout(()=>{this.loading.set(!1)},t)}initInlineConfirmation(t,n){const o=t?.params?.inlineConfirmationButtons?.cancel??{},f=t?.params?.inlineConfirmationButtons?.confirm??{};this.confirmationLabel=t?.params?.confirmationLabel??"",this.confirmationDynamicLabel=t?.params?.confirmationDynamicLabel??"",this.inlineCancelButton=this.buildInlineCancelButton(o),this.inlineConfirmButton=this.buildInlineConfirmButton(f,n),this.inlineConfirmationEnabled.set(!0)}buildInlineCancelButton(t){const o={labelKey:"LBL_NO",klass:"btn btn-sm p-0 m-0 btn-link border-0 line-height-initial",debounceClick:!0,...t??{}};return o.onClick=()=>{this.triggerTemporaryLoading(),this.resetInlineConfirmation()},o}buildInlineConfirmButton(t,n){const f={labelKey:"LBL_YES",klass:"btn btn-sm p-0 m-0 btn-link border-0 line-height-initial",debounceClick:!0,...t??{}};return f.onClick=()=>{this.triggerTemporaryLoading(),n(),this.resetInlineConfirmation()},f}resetInlineConfirmation(){this.inlineConfirmationEnabled.set(!1),this.confirmationDynamicLabel="",this.confirmationLabel="",this.inlineConfirmButton=null,this.inlineCancelButton=null}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-action-group-menu"]],inputs:{klass:"klass",buttonClass:"buttonClass",buttonGroupClass:"buttonGroupClass",actionContext:"actionContext",config:"config",actionLimitConfig:"actionLimitConfig"},decls:2,vars:3,consts:[[4,"ngIf"],[3,"config$","klass",4,"ngIf"],[3,"config$","klass"],[1,"d-flex","align-items-start","justify-content-end","inline-confirmation"],["class","pl-1 inline-confirmation-label",4,"ngIf"],["class","pl-1 inline-confirmation-button",4,"ngIf"],[1,"pl-1","inline-confirmation-label"],[3,"labelKey"],[3,"labelKey","module","fields"],[1,"pl-1","inline-confirmation-button"],[3,"config"],["klass","inline-spinner-md"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,hy,5,6,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,xc,nb,Pa,Df,HD,ve.AsyncPipe],encapsulation:2})}return r})(),Vl=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fn.AngularSvgIconModule]})}return r})(),my=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl,ct.NgbModule]})}return r})(),Ea=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Bh=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ct.NgbDropdownModule,Vl,my,Ea,ct.NgbTooltipModule]})}return r})(),Oa=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl,Ea,ct.NgbTooltipModule]})}return r})(),ip=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa]})}return r})(),Fu=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,Bh,ip]})}return r})(),dh=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),gy=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),hm=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl,Oa,Fu,Ea,dh,gy]})}return r})();function nS(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",17),e.\u0275\u0275elementContainerEnd())}let PM=(()=>{class r{constructor(t){this.languageStore=t,this.subs=[],this.status=Xu.NONE,this.count=(0,e.signal)(0),this.SelectionStatus=Xu}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[],this.count=(0,e.signal)(0),this.status=Xu.NONE}ngOnInit(){this.subs=[],this.subs.push(this.selectionSource.getSelectionStatus().subscribe(t=>this.status=t)),this.subs.push(this.selectionSource.getSelectedCount().subscribe(t=>this.count.set(t))),this.subs.push(this.actionSource.getBulkActions().subscribe(t=>{const n={labelKey:"LBL_BULK_ACTION_BUTTON_LABEL",klass:["bulk-action-button","btn","btn-sm"],wrapperKlass:["bulk-action-group","float-left"],items:[]},o={labelKey:"LBL_ACTION",klass:["bulk-action-button","btn","btn-sm"],wrapperKlass:["bulk-action-group","float-left"],items:[]};Object.keys(t).forEach(f=>{const D=t[f];n.items.push({labelKey:D.labelKey??"",klass:[`${f}-bulk-action`],onClick:()=>{this.actionSource.executeBulkAction(D.key)}}),o.items.push({labelKey:D.labelKey??"",klass:[`${f}-bulk-action`],onClick:()=>{this.actionSource.executeBulkAction(D.key)}})}),this.dropdownConfig=n,this.dropdownSmallConfig=o}))}selectPage(){this.selectionSource.updateSelection(Xu.PAGE)}selectAll(){this.selectionSource.updateSelection(Xu.ALL)}deselectAll(){this.selectionSource.updateSelection(Xu.NONE)}toggleSelection(t){this.selectionSource.updateSelection(t!==Xu.ALL?Xu.ALL:Xu.NONE)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-bulk-action-menu"]],inputs:{selectionSource:"selectionSource",actionSource:"actionSource"},decls:18,vars:8,consts:[[1,"bulk-action","d-flex"],["ngbDropdown","",1,"dropdown","select-action-group"],["type","button","ngbDropdownToggle","","aria-haspopup","true","aria-expanded","false","aria-hidden","true","aria-label","Select Action Menu",1,"bulk-action-button","dropdown-toggle","btn","btn-sm"],[1,"checkbox-container"],["type","checkbox","aria-hidden","true",3,"change","checked","indeterminate"],[1,"checkmark"],[1,"bulk-action-selected-number"],[4,"ngIf"],["ngbDropdownMenu","","aria-hidden","true",1,"dropdown-menu"],[1,"dropdown-item","select-all",3,"click"],["labelKey","LBL_LISTVIEW_OPTION_ENTIRE"],[1,"dropdown-item","select-page",3,"click"],["labelKey","LBL_LISTVIEW_OPTION_CURRENT"],[1,"dropdown-item","deselect-all",3,"click"],["labelKey","LBL_LISTVIEW_NONE"],[1,"d-block","d-sm-none",3,"disabled","config"],[1,"d-none","d-sm-block",3,"disabled","config"],["labelKey","LBL_LISTVIEW_SELECTED_OBJECTS",1,"d-none","d-sm-inline"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"button",2)(3,"label",3)(4,"input",4),e.\u0275\u0275listener("change",function(){return o.toggleSelection(o.status)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(5,"span",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"span",6),e.\u0275\u0275template(7,nS,2,0,"ng-container",7),e.\u0275\u0275text(8),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(9,"div",8)(10,"a",9),e.\u0275\u0275listener("click",function(){return o.selectAll()}),e.\u0275\u0275element(11,"scrm-label",10),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(12,"a",11),e.\u0275\u0275listener("click",function(){return o.selectPage()}),e.\u0275\u0275element(13,"scrm-label",12),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(14,"a",13),e.\u0275\u0275listener("click",function(){return o.deselectAll()}),e.\u0275\u0275element(15,"scrm-label",14),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275element(16,"scrm-dropdown-button",15)(17,"scrm-dropdown-button",16),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(4),e.\u0275\u0275property("checked","ALL"===o.status)("indeterminate","SOME"===o.status||"PAGE"===o.status),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.count()>0),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",o.count()>0?o.count():""," "),e.\u0275\u0275advance(8),e.\u0275\u0275property("disabled",o.count()<1)("config",o.dropdownSmallConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("disabled",o.count()<1)("config",o.dropdownConfig))},dependencies:[ve.NgIf,ct.NgbDropdown,ct.NgbDropdownToggle,ct.NgbDropdownMenu,pm,Pa],encapsulation:2})}return r})(),GD=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ct.NgbModule,Bh,Ea]})}return r})(),iS=(()=>{class r{constructor(){}addOnClickPartial(t,n){const o={...t};if(t&&"items"in o){const f=o.items;return o.items=[],f.forEach(D=>{o.items.push(this.addOnClickPartial(D,n))}),o}return o.onClick=o.onClick&&(0,un.A)(o.onClick,n),o}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ob=(()=>{class r{constructor(t,n){this.elementRef=t,this.screenSize=n,this.height=300,this.view=(0,e.signal)([300,this.height]),this.subs=[]}onResize(){this.calculateView()}initResizeListener(){const t=(0,i.fromEvent)(window,"resize").pipe((0,M.tap)(()=>this.view.set([])),(0,M.debounceTime)(300));this.view.set([]),this.subs.push(t.pipe((0,M.debounceTime)(50)).subscribe(()=>{this.calculateView()}))}calculateView(){let t;const n=this.elementRef&&this.elementRef.nativeElement||{},o=n.parentElement&&n.parentElement.parentElement||{},f=o&&o.offsetWidth||0;f>0?t=f:(t=.7*window.innerWidth,window.innerWidth>990&&(t=.23*window.innerWidth)),this.view.set([t,this.height])}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Wd))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],inputs:{dataSource:"dataSource"},decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),$1=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();function KD(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275element(1,"scrm-label",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.labelKey)}}let mm=(()=>{class r{constructor(t){this.language=t,this.labelKey=""}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-chart-message-area"]],inputs:{labelKey:"labelKey"},decls:2,vars:1,consts:[[1,"d-flex","mb-4","mt-4","justify-content-center"],["class","lead",4,"ngIf"],[1,"lead"],[3,"labelKey"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,KD,2,1,"div",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.labelKey))},dependencies:[ve.NgIf,Pa],encapsulation:2})}return r})(),af=(()=>{class r{constructor(){this.overlay=!1}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-loading-spinner"]],inputs:{overlay:"overlay"},decls:19,vars:2,consts:[[1,"loading-spinner"],[1,"sk-cube-grid"],[1,"sk-cube","sk-cube1","sk-cube-primary"],[1,"sk-cube","sk-cube2","sk-cube-secondary"],[1,"sk-cube","sk-cube3","sk-cube-secondary"],[1,"sk-cube","sk-cube4","sk-cube-primary"],[1,"sk-cube","sk-cube5","sk-cube-secondary"],[1,"sk-cube","sk-cube6","sk-cube-secondary"],[1,"sk-cube","sk-cube7","sk-cube-primary"],[1,"sk-cube","sk-cube8","sk-cube-primary"],[1,"sk-cube","sk-cube9","sk-cube-primary"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div")(1,"div",0)(2,"div",1),e.\u0275\u0275element(3,"div",2)(4,"div",2)(5,"div",3)(6,"div",4)(7,"div",5)(8,"div",5)(9,"div",6)(10,"div",7)(11,"div",8)(12,"div",8)(13,"div",9)(14,"div",10)(15,"div",8)(16,"div",8)(17,"div",9)(18,"div",10),e.\u0275\u0275elementEnd()()()),2&n&&e.\u0275\u0275classProp("overlay",o.overlay)},styles:[".sk-cube-grid[_ngcontent-%COMP%]{width:4.25em;height:4.25em}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube[_ngcontent-%COMP%]{width:25%;height:25%;float:left;-webkit-animation:_ngcontent-%COMP%_sk-cubeGridScaleDelay 1.3s infinite ease-in-out;animation:_ngcontent-%COMP%_sk-cubeGridScaleDelay 1.3s infinite ease-in-out}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube1[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube2[_ngcontent-%COMP%]{-webkit-animation-delay:.3s;animation-delay:.3s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube3[_ngcontent-%COMP%]{-webkit-animation-delay:.4s;animation-delay:.4s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube4[_ngcontent-%COMP%]{-webkit-animation-delay:.1s;animation-delay:.1s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube5[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube6[_ngcontent-%COMP%]{-webkit-animation-delay:.3s;animation-delay:.3s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube7[_ngcontent-%COMP%]{-webkit-animation-delay:0s;animation-delay:0s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube8[_ngcontent-%COMP%]{-webkit-animation-delay:.1s;animation-delay:.1s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube9[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}@-webkit-keyframes _ngcontent-%COMP%_sk-cubeGridScaleDelay{0%,70%,to{-webkit-transform:scale3D(1,1,1);transform:scaleZ(1)}35%{-webkit-transform:scale3D(0,0,1);transform:scale3D(0,0,1)}}@keyframes _ngcontent-%COMP%_sk-cubeGridScaleDelay{0%,70%,to{-webkit-transform:scale3D(1,1,1);transform:scaleZ(1)}35%{-webkit-transform:scale3D(0,0,1);transform:scale3D(0,0,1)}}"]})}return r})();function vy(r,v){1&r&&e.\u0275\u0275element(0,"scrm-chart-message-area",3)}function qD(r,v){if(1&r&&e.\u0275\u0275element(0,"ngx-charts-pie-grid",5),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("animations",!1)("view",t.view())("scheme",t.scheme)("minWidth",t.minWidth)("label",t.language.getFieldLabel(t.label))("results",t.results)}}function W1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,qD,1,6,"ngx-charts-pie-grid",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.results&&t.results.length>0)}}function sb(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-loading-spinner"),e.\u0275\u0275elementEnd()),2&r&&e.\u0275\u0275classProp("m-5",!0)}let ab=(()=>{class r extends ob{constructor(t,n,o){super(n,o),this.language=t,this.elementRef=n,this.screenSize=o,this.height=700,this.minWidth=100}ngOnInit(){this.dataSource.options.height&&(this.height=this.dataSource.options.height),this?.dataSource?.options?.minWidth&&(this.minWidth=this.dataSource.options.minWidth),this.initResizeListener(),this.subs.push(this.dataSource.getResults().pipe((0,M.debounceTime)(500)).subscribe(t=>{this.parseResults(t),this.calculateHeightBasedOnResults(),this.calculateView()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}get scheme(){return this.dataSource.options.scheme||"picnic"}get label(){return this.dataSource.options.label||""}onResize(){this.calculateHeightBasedOnResults(),this.calculateView()}calculateHeightBasedOnResults(){if(this.results&&this.results.length){const t=Math.floor(this.view()[0]/170);this.height=200*Math.floor(this.results.length/t)}else this.height=50}parseResults(t){this.results=[],t.singleSeries&&t.singleSeries.length&&t.singleSeries.forEach(n=>{const o=parseFloat(""+n.value);this.results.push(o?{name:n.name,value:o}:n)})}calculateView(){let t;const n=this.elementRef&&this.elementRef.nativeElement||{},o=n.parentElement&&n.parentElement.parentElement||{},f=o&&o.offsetWidth||0;f>0?t=f:(t=.7*window.innerWidth,window.innerWidth>990&&(t=.23*window.innerWidth)),this.view.set(t>239?[t,this.height]:[t,800])}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Wd))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-pie-grid-chart"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:3,consts:[["labelKey","LBL_NO_DATA",4,"ngIf"],[4,"ngIf"],["class","chart-loading",3,"m-5",4,"ngIf"],["labelKey","LBL_NO_DATA"],[3,"animations","view","scheme","minWidth","label","results",4,"ngIf"],[3,"animations","view","scheme","minWidth","label","results"],[1,"chart-loading"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,vy,1,0,"scrm-chart-message-area",0)(1,W1,2,1,"ng-container",1)(2,sb,2,2,"div",2),2&n&&(e.\u0275\u0275property("ngIf",!o.results||!o.results.length||o.results.length<1),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.view().length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.view().length&&o.results&&o.results.length>0))},dependencies:[ve.NgIf,vn.PieGridComponent,mm,af],encapsulation:2})}return r})();function H1(r,v){1&r&&e.\u0275\u0275element(0,"scrm-chart-message-area",4)}function lb(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(2,"div"),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()),2&r){const t=v.model,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.name),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(n.formatTooltipValue(t.value))}}function QD(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"ngx-charts-bar-vertical",6),e.\u0275\u0275template(1,lb,4,2,"ng-template",null,0,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("animations",!1)("results",t.results)("view",t.view())("scheme",t.scheme)("gradient",t.gradient)("xAxis",t.xAxis)("yAxis",t.yAxis)("legend",t.legend)("legendPosition","below")("showXAxisLabel",t.showXAxisLabel)("showYAxisLabel",t.showYAxisLabel)("xAxisLabel",t.xAxisLabel)("yAxisLabel",t.yAxisLabel)("yAxisTickFormatting",t.yAxisTickFormatting)}}function BM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,QD,3,14,"ngx-charts-bar-vertical",5),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.results&&t.results.length>0)}}function z1(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",7),e.\u0275\u0275element(1,"scrm-loading-spinner"),e.\u0275\u0275elementEnd()),2&r&&e.\u0275\u0275classProp("m-5",!0)}let cb=(()=>{class r extends ob{constructor(t,n){super(t,n),this.elementRef=t,this.screenSize=n}ngOnInit(){this.dataSource.options.height&&(this.height=this.dataSource.options.height),this.initResizeListener(),this.subs.push(this.dataSource.getResults().pipe((0,M.debounceTime)(500)).subscribe(t=>{this.results=t.singleSeries,this.calculateView()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}get scheme(){return this.dataSource.options.scheme||"picnic"}get gradient(){return this.dataSource.options.gradient||!1}get xAxis(){return this.dataSource.options.xAxis||!1}get yAxis(){return!sf(this.dataSource.options.yAxis)}get legend(){return!sf(this.dataSource.options.legend)}get showXAxisLabel(){return this.dataSource.options.showXAxisLabel||!1}get showYAxisLabel(){return this.dataSource.options.showYAxisLabel||!1}get xAxisLabel(){return this.dataSource.options.xAxisLabel||""}get yAxisLabel(){return this.dataSource.options.yAxisLabel||""}get yAxisTickFormatting(){return this.dataSource.options.yAxisTickFormatting?this.dataSource.tickFormatting:null}formatTooltipValue(t){return this.dataSource&&this.dataSource.tooltipFormatting?this.dataSource.tooltipFormatting(t):t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Wd))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-vertical-bar-chart"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:3,consts:[["tooltipTemplate",""],["labelKey","LBL_NO_DATA",4,"ngIf"],[4,"ngIf"],["class","chart-loading",3,"m-5",4,"ngIf"],["labelKey","LBL_NO_DATA"],["class","vertical-bar-chart",3,"animations","results","view","scheme","gradient","xAxis","yAxis","legend","legendPosition","showXAxisLabel","showYAxisLabel","xAxisLabel","yAxisLabel","yAxisTickFormatting",4,"ngIf"],[1,"vertical-bar-chart",3,"animations","results","view","scheme","gradient","xAxis","yAxis","legend","legendPosition","showXAxisLabel","showYAxisLabel","xAxisLabel","yAxisLabel","yAxisTickFormatting"],[1,"chart-loading"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,H1,1,0,"scrm-chart-message-area",1)(1,BM,2,1,"ng-container",2)(2,z1,2,2,"div",3),2&n&&(e.\u0275\u0275property("ngIf",!o.results||!o.results.length||o.results.length<1),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.view().length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.view().length&&o.results&&o.results.length>0))},dependencies:[ve.NgIf,vn.BarVerticalComponent,mm,af],encapsulation:2})}return r})(),Xg=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea]})}return r})(),jf=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),G1=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,vn.NgxChartsModule,Xg,jf]})}return r})(),K1=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,vn.NgxChartsModule,Xg,jf]})}return r})();function VM(r,v){1&r&&e.\u0275\u0275element(0,"scrm-chart-message-area",3)}function YD(r,v){if(1&r&&e.\u0275\u0275element(0,"ngx-charts-line-chart",5),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("animations",!1)("results",t.results)("view",t.view())("scheme",t.scheme)("gradient",t.gradient)("xAxis",t.xAxis)("yAxis",t.yAxis)("legend",t.legend)("xScaleMin",t.xScaleMin)("xScaleMax",t.xScaleMax)("xAxisTicks",t.xAxisTicks)("showXAxisLabel",t.showXAxisLabel)("showYAxisLabel",t.showYAxisLabel)("xAxisLabel",t.xAxisLabel)("legendPosition","below")("autoScale",!0)("yAxisTickFormatting",t.yAxisTickFormatting)("xAxisTickFormatting",t.xAxisTickFormatting)("tooltipDisabled",t.tooltipDisabled)("yAxisLabel",t.yAxisLabel)}}function q1(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,YD,1,20,"ngx-charts-line-chart",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.results&&t.results.length>0)}}function QE(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-loading-spinner"),e.\u0275\u0275elementEnd()),2&r&&e.\u0275\u0275classProp("m-5",!0)}let Vp=(()=>{class r extends ob{constructor(t,n){super(t,n),this.elementRef=t,this.screenSize=n}ngOnInit(){this.dataSource.options.height&&(this.height=this.dataSource.options.height),this.initResizeListener(),this.subs.push(this.dataSource.getResults().subscribe(t=>{this.results=t.multiSeries,this.calculateView()})),this.scheme=this.getScheme(),this.gradient=this.getGradient(),this.xAxis=this.getXAxis(),this.yAxis=this.getYAxis(),this.legend=this.getLegend(),this.xScaleMin=this.getXScaleMin(),this.xScaleMax=this.getXScaleMax(),this.xAxisTicks=this.getXAxisTicks(),this.showXAxisLabel=this.getShowXAxisLabel(),this.showYAxisLabel=this.getShowYAxisLabel(),this.xAxisLabel=this.getXAxisLabel(),this.yAxisLabel=this.getYAxisLabel(),this.yAxisTickFormatting=this.getYAxisTickFormatting(),this.xAxisTickFormatting=this.getXAxisTickFormatting(),this.tooltipDisabled=this.getTooltipDisabled()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getScheme(){return this.dataSource.options.scheme||"picnic"}getGradient(){return this.dataSource.options.gradient||!1}getXAxis(){return!sf(this.dataSource.options.xAxis)}getYAxis(){return!sf(this.dataSource.options.yAxis)}getLegend(){return!sf(this.dataSource.options.legend)}getXScaleMin(){return this.dataSource.options.xScaleMin||null}getXScaleMax(){return this.dataSource.options.xScaleMax||null}getXAxisTicks(){return this.dataSource.options.xAxisTicks||null}getShowXAxisLabel(){return!sf(this.dataSource.options.showXAxisLabel)}getShowYAxisLabel(){return this.dataSource.options.showYAxisLabel||!1}getXAxisLabel(){return this.dataSource.options.xAxisLabel||""}getYAxisLabel(){return this.dataSource.options.yAxisLabel||""}getYAxisTickFormatting(){return this.dataSource.options.yAxisTickFormatting&&this.dataSource.tickFormatting||null}getXAxisTickFormatting(){return this.dataSource.options.xAxisTickFormatting&&this.dataSource.tickFormatting||null}getTooltipDisabled(){return this.dataSource.options.tooltipDisabled||!1}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(Wd))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-line-chart"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:3,consts:[["labelKey","LBL_NO_DATA",4,"ngIf"],[4,"ngIf"],["class","chart-loading",3,"m-5",4,"ngIf"],["labelKey","LBL_NO_DATA"],["class","line-chart",3,"animations","results","view","scheme","gradient","xAxis","yAxis","legend","xScaleMin","xScaleMax","xAxisTicks","showXAxisLabel","showYAxisLabel","xAxisLabel","legendPosition","autoScale","yAxisTickFormatting","xAxisTickFormatting","tooltipDisabled","yAxisLabel",4,"ngIf"],[1,"line-chart",3,"animations","results","view","scheme","gradient","xAxis","yAxis","legend","xScaleMin","xScaleMax","xAxisTicks","showXAxisLabel","showYAxisLabel","xAxisLabel","legendPosition","autoScale","yAxisTickFormatting","xAxisTickFormatting","tooltipDisabled","yAxisLabel"],[1,"chart-loading"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,VM,1,0,"scrm-chart-message-area",0)(1,q1,2,1,"ng-container",1)(2,QE,2,2,"div",2),2&n&&(e.\u0275\u0275property("ngIf",!o.results||!o.results.length||o.results.length<1),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.view().length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.view().length&&o.results&&o.results.length>0))},dependencies:[ve.NgIf,vn.LineChartComponent,mm,af],encapsulation:2})}return r})(),XD=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,vn.NgxChartsModule,Xg,jf]})}return r})();const ZD=[XD,K1,G1],s_={"line-chart":Vp,"pie-grid":ab,"vertical-bar":cb};let JD=(()=>{class r extends jd{constructor(){super()}initDefault(){Object.keys(s_).forEach(t=>{this.register("default",t,s_[t])})}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const YE=r=>({dataSource:r});function _y(r,v){1&r&&e.\u0275\u0275element(0,"scrm-chart-message-area",2)}function rS(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",3),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.chartType)("ndcDynamicInputs",e.\u0275\u0275pureFunction1(2,YE,t.dataSource))}}let ew=(()=>{class r{constructor(t){this.registry=t,this.dataSource=null}get chartType(){return this.registry.get("default",this.type)}ngOnInit(){}isConfigured(){return!!(this.type&&this.dataSource&&this.chartType)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(JD))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-chart"]],inputs:{dataSource:"dataSource",type:"type"},decls:2,vars:2,consts:[["labelKey","LBL_BAD_CONFIG",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],["labelKey","LBL_BAD_CONFIG"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,_y,1,0,"scrm-chart-message-area",0)(1,rS,1,4,"ndc-dynamic",1),2&n&&(e.\u0275\u0275property("ngIf",!o.isConfigured()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isConfigured()))},dependencies:[ve.NgIf,St,Ht,mm],encapsulation:2})}return r})(),yy=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ZD,on,Xg]})}return r})();function Q1(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"scrm-button",1)(1,"span",2),e.\u0275\u0275text(2,"\xd7"),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.getConfig())}}let Km=(()=>{class r{constructor(){this.buttonClasses=["close-button"]}getConfig(){const t=ep.fromButton(this.config);return t.addClasses(this.buttonClasses),t}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-close-button"]],inputs:{config:"config"},decls:1,vars:1,consts:[[3,"config",4,"ngIf"],[3,"config"],["aria-hidden","true"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,Q1,3,1,"scrm-button",0),2&n&&e.\u0275\u0275property("ngIf",o.config)},dependencies:[ve.NgIf,xc],encapsulation:2})}return r})(),Zg=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa]})}return r})();const tw=[[["","modal-body",""]],[["","modal-footer",""]]],ub=["[modal-body]","[modal-footer]"];function nw(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-label",3),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("labelKey",t.titleKey)}}function Y1(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-close-button",4),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.close)}}let qm=(()=>{class r{constructor(){this.klass="",this.headerKlass="",this.bodyKlass="",this.footerKlass="",this.titleKey="",this.closable=!1,this.close={klass:["btn","btn-outline-light","btn-sm"]}}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-modal"]],inputs:{klass:"klass",headerKlass:"headerKlass",bodyKlass:"bodyKlass",footerKlass:"footerKlass",titleKey:"titleKey",closable:"closable",close:"close"},ngContentSelectors:ub,decls:9,vars:13,consts:[[1,"modal-title"],[3,"labelKey",4,"ngIf"],[3,"config",4,"ngIf"],[3,"labelKey"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(tw),e.\u0275\u0275elementStart(0,"div")(1,"div")(2,"div",0),e.\u0275\u0275template(3,nw,1,1,"scrm-label",1),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(4,Y1,1,1,"scrm-close-button",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"div"),e.\u0275\u0275projection(6),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(7,"div"),e.\u0275\u0275projection(8,1),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275classMap(o.klass),e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("modal-header ",o.headerKlass," d-flex align-items-center"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.titleKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.closable),e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("modal-body ",o.bodyKlass,""),e.\u0275\u0275advance(2),e.\u0275\u0275classMapInterpolate1("modal-footer ",o.footerKlass,""))},dependencies:[ve.NgIf,Km,Pa],encapsulation:2})}return r})();const db=r=>[r];function XE(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",16),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",n.getColumnLabel(t.label)," ")}}function ZE(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",17),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",n.getColumnLabel(t.label)," ")}}let oS=(()=>{class r{constructor(t,n,o){this.appState=t,this.languageStore=n,this.modal=o,this.titleKey="LBL_COLUMN_SELECTOR_MODAL_TITLE"}drop(t){t.previousContainer===t.container?Re(t.container.data,t.previousIndex,t.currentIndex):function tt(r,v,t,n){const o=gi(t,r.length-1),f=gi(n,v.length);r.length&&v.splice(f,0,r.splice(o,1)[0])}(t.previousContainer.data,t.container.data,t.previousIndex,t.currentIndex)}getHeaderLabel(){return this.languageStore.getFieldLabel("LBL_COLUMN_SELECTOR_MODAL_TITLE")}getColumnLabel(t){return this.languageStore.getFieldLabel(t,this.appState.getModule())}ngOnInit(){this.closeButtonIcon={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.modal.close({type:"close-button"})}},this.closeButton={klass:["btn","modal-button-cancel"],labelKey:"LBL_COLUMN_SELECTOR_CLOSE_BUTTON",onClick:()=>{this.modal.close({type:"close-button"})}},this.saveButton={klass:["btn","modal-button-save"],labelKey:"LBL_COLUMN_SELECTOR_SAVE_BUTTON",onClick:()=>{this.modal.close({type:"close-button",displayed:this.displayed,hidden:this.hidden})}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(ct.NgbActiveModal))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-columnchooser"]],inputs:{displayed:"displayed",hidden:"hidden"},decls:19,vars:16,consts:[["displayedList","cdkDropList"],["hiddenList","cdkDropList"],["klass","column-chooser-modal",3,"closable","close","title","titleKey"],["modal-body",""],[1,"d-flex","bd-highlight"],[1,"p-2","flex-fill","bd-highlight","column-chooser-container"],[1,"column-chooser-title"],["labelKey","LBL_COLUMN_SELECTOR_DISPLAYED_COLS"],["cdkDropList","",1,"column-chooser-list",3,"cdkDropListDropped","cdkDropListData","cdkDropListConnectedTo"],["class","column-chooser-item column-displayed","cdkDrag","",4,"ngFor","ngForOf"],["labelKey","LBL_COLUMN_SELECTOR_HIDDEN_COLS"],["class","column-chooser-item column-hidden","cdkDrag","",4,"ngFor","ngForOf"],["modal-footer",""],[1,"modal-buttons"],["data-dismiss","modal",3,"config"],[3,"config"],["cdkDrag","",1,"column-chooser-item","column-displayed"],["cdkDrag","",1,"column-chooser-item","column-hidden"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"scrm-modal",2)(1,"div",3)(2,"div",4)(3,"div",5)(4,"h2",6),e.\u0275\u0275element(5,"scrm-label",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",8,0),e.\u0275\u0275listener("cdkDropListDropped",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.drop(j))}),e.\u0275\u0275template(8,XE,2,1,"div",9),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(9,"div",5)(10,"h2",6),e.\u0275\u0275element(11,"scrm-label",10),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(12,"div",8,1),e.\u0275\u0275listener("cdkDropListDropped",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.drop(j))}),e.\u0275\u0275template(14,ZE,2,1,"div",11),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(15,"div",12)(16,"div",13),e.\u0275\u0275element(17,"scrm-button",14)(18,"scrm-button",15),e.\u0275\u0275elementEnd()()()}if(2&n){const f=e.\u0275\u0275reference(7),D=e.\u0275\u0275reference(13);e.\u0275\u0275property("closable",!0)("close",o.closeButtonIcon)("title",o.getHeaderLabel())("titleKey",o.titleKey),e.\u0275\u0275advance(6),e.\u0275\u0275property("cdkDropListData",o.displayed)("cdkDropListConnectedTo",e.\u0275\u0275pureFunction1(12,db,D)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",o.displayed),e.\u0275\u0275advance(4),e.\u0275\u0275property("cdkDropListData",o.hidden)("cdkDropListConnectedTo",e.\u0275\u0275pureFunction1(14,db,f)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",o.hidden),e.\u0275\u0275advance(3),e.\u0275\u0275property("config",o.closeButton),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.saveButton)}},dependencies:[ve.NgForOf,Yr,kt,qm,Pa,xc],encapsulation:2})}return r})(),Qm=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fn.AngularSvgIconModule,Zg,Ea,ct.NgbModalModule]})}return r})(),sS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ws,Zg,Qm,Ea,Oa]})}return r})(),a_=(()=>{class r{constructor(t){this.breakpointObserver=t,this.special=!1,this.actions=!1,this.appendActions=!1,this.labelDisplay="top",this.labelClass={},this.inputClass={},this.rowClass={},this.colClass={},this.colAlignItems="",this.sizeMap={handset:1,tablet:2,web:3,wide:4},this.baseColClass={col:!0,"form-group":!0,"m-1":!0},this.baseRowClass={"form-row":!0,"align-items-center":!0},this.baseLabelClass={"col-form-label-sm":!0,"mb-0":!0},this.baseInputClass={"form-control":!0,"form-control-sm":!0},this.currentSize="web",this.subscriptions=[]}ngOnInit(){this.initScreenSizeObserver(this.breakpointObserver),this.buildGrid(),this.colClass={...this.colClass,...this.baseColClass},this.rowClass={...this.baseRowClass,...this.rowClass},this.labelClass={...this.labelClass,...this.baseLabelClass},this.inputClass={...this.inputClass,...this.baseInputClass}}ngOnDestroy(){this.subscriptions.forEach(t=>t.unsubscribe())}get colNumber(){const t=this.sizeMap[this.currentSize];return this.maxColumns&&t>this.maxColumns?this.maxColumns:t}addSpecialSlots(t){if(!t||0===t.length)return;const n=this.getNeededExtraSlots();if(0!==n.length)if(1===this.colNumber)n.reverse().forEach(o=>{const f={cols:[]};this.fillRow(f),t.push(f),f.cols[0][o]=!0});else if(!0===this.appendActions){const o=t[t.length-1],f=this.colNumber-1;n.forEach(D=>{o.cols[f][D]=!0})}else{let o=t[t.length-1],f=o.cols.length;n.reverse().forEach(D=>{let j=!1;"actionSlot"===D&&(j=!0),(f===this.colNumber||j)&&(o=this.addNewRow(),t.push(o),f=j?this.colNumber-1:0),o.cols[f]=[],o.cols[f][D]=!0,this.fillRow(o),f++})}}addNewRow(){const t={cols:[]};return this.fillRow(t),t}getNeededExtraSlots(){const t=[];return this.actions&&t.push("actionSlot"),this.special&&t.push("specialSlot"),t}fillRow(t){for(let o=t.cols.length;o<this.colNumber;o++)t.cols.push({field:{type:"",display:(0,e.signal)("none")}})}initScreenSizeObserver(t){this.subscriptions.push(t.observe(["(max-width: 599.98px) and (orientation: portrait)"]).subscribe(n=>{n.matches&&(this.currentSize="handset",this.buildGrid())})),this.subscriptions.push(t.observe(["(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)",Et_Small]).subscribe(n=>{n.matches&&(this.currentSize="tablet",this.buildGrid())})),this.subscriptions.push(t.observe(["(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)","(min-width: 1280px) and (orientation: landscape)"]).subscribe(n=>{n.matches&&(this.currentSize="web",this.buildGrid())})),this.subscriptions.push(t.observe(["(min-width: 1920px)"]).subscribe(n=>{n.matches&&(this.currentSize="wide",this.buildGrid())}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(le))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:r,inputs:{special:"special",actions:"actions",appendActions:"appendActions",labelDisplay:"labelDisplay",labelClass:"labelClass",inputClass:"inputClass",rowClass:"rowClass",colClass:"colClass",colAlignItems:"colAlignItems",maxColumns:"maxColumns",sizeMap:"sizeMap"}})}return r})(),js=(()=>{class r{constructor(){this.actions={edit:{},create:{},list:{},detail:{},massupdate:{},filter:{}}}run(t,n,o){!this.actions||!this.actions[n]||!this.actions[n][t.key]||this.actions[n][t.key].run(o,t)}getHandler(t,n){let o=t.key;return t&&t.asyncProcess&&(o="async-process"),this.actions&&this.actions[n]&&this.actions[n][o]?this.actions[n][o]:null}addHandler(t,n,o){this.actions[n]||(this.actions[n]={}),this.actions[n][t.key]=o}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class fh extends kp{shouldDisplay(v){return!0}getTriggeringStatus(){return["onDependencyChange"]}}class Vh{}let Jg=(()=>{class r extends Vh{constructor(){super(),this.key="greater-than"}run(t,n,o){const f=o.field?t.fields[o.field].value:o.value;return Number(n.value)>Number(f)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),aS=(()=>{class r extends Vh{constructor(){super(),this.key="less-than"}run(t,n,o){const f=o.field?t.fields[o.field].value:o.value;return Number(n.value)<Number(f)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),by=(()=>{class r extends Vh{constructor(){super(),this.key="not-empty"}run(t,n,o){return!Ud(n.value)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),l_=(()=>{class r extends Vh{constructor(){super(),this.key="is-empty"}run(t,n,o){return!!Ud(n.value)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),X1=(()=>{class r extends Vh{constructor(){super(),this.key="is-equal"}run(t,n,o){let f=null;return f=this.compareToField(o)?this.getFieldComparisonValue(t,o):this.getStaticComparisonValue(o),!!f&&f.includes(n.value.toString())}getFieldComparisonValue(t,n){return[t.fields[n.field]?.value]}getStaticComparisonValue(t){return Array.isArray(t.values)?t.values.map(n=>n?.toString()):[t.value].map(n=>n?.toString())}compareToField(t){return!!t?.field}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),gm=(()=>{class r extends Vh{constructor(){super(),this.key="not-equal"}run(t,n,o){const f=o.field?[t.fields[o.field].value]:(Array.isArray(o.values)?o.values:[o.value]).map(D=>D.toString());return!!f&&!f.includes(n.value.toString())}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),fb=(()=>{class r{constructor(t,n,o,f,D,j){this.greaterThanAction=t,this.lessThanAction=n,this.notEmptyAction=o,this.isEmptyAction=f,this.isEqualAction=D,this.notEqualAction=j}get(t){return{"greater-than":this.greaterThanAction,"less-than":this.lessThanAction,"not-empty":this.notEmptyAction,"is-empty":this.isEmptyAction,"is-equal":this.isEqualAction,"not-equal":this.notEqualAction}[t]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Jg),e.\u0275\u0275inject(aS),e.\u0275\u0275inject(by),e.\u0275\u0275inject(l_),e.\u0275\u0275inject(X1),e.\u0275\u0275inject(gm))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),pb=(()=>{class r extends fh{constructor(t){super(),this.operatorManager=t,this.key="displayType",this.modes=["edit","detail","list","create","massupdate","filter"]}run(t,n){const o=t.record;if(!o||!t.field)return;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);if(!j.length&&!Ne.length)return;const vt=n.params&&n.params.targetDisplayType;if(!vt)return;let ln=this.isActive(j,o,D,Ne,fe),Hn=t.field.defaultDisplay;ln&&(Hn=vt),t.field.display.set(Hn),(n.params&&n.params.resetOn||"none")===Hn&&(t.field.valueList&&t.field.valueList.length&&(t.field.valueList=[]),t.field.value&&(t.field.value=""))}isActive(t,n,o,f,D){let j=!1;return!j&&!(0,wt.isEmpty)(o)&&(j=this.areFieldsActive(t,n,o)),!j&&!(0,wt.isEmpty)(D)&&(j=this.areAttributesActive(f,n,D)),j}areAttributesActive(t,n,o){return t.some(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f]&&Object.keys(o[f]);if(j&&fe&&fe.length)return fe.some(Ne=>{const vt=o[f][Ne],ln=j.attributes&&j.attributes[Ne];if(vt&&vt.length&&ln)return this.isValueActive(n,ln,vt)})})}areFieldsActive(t,n,o){return t.every(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f];if(j&&fe&&fe.length)return this.isValueActive(n,j,fe)})}isValueActive(t,n,o){let f=!1;if(n.valueList&&n.valueList.length)return n.valueList.some(fe=>o.some(Ne=>{if(Ne===fe)return f=!0,!0})),f;const D=Object.keys(t.fields);let j=[];return o.some(n.value?fe=>{if((!fe.field||D.includes(fe.field))&&(fe===n.value&&!fe.operator&&(f=!0),fe.operator)){const vt=this.operatorManager.get(fe.operator);j.push(vt.run(t,n,fe)),f=j.every(ln=>ln)}}:fe=>{if(fe.operator){if(fe.field&&!D.includes(fe.field))return;const vt=this.operatorManager.get(fe.operator);j.push(vt.run(t,n,fe)),f=j.every(ln=>ln)}}),f}getTriggeringStatus(){return["onAnyLogic","onFieldInitialize"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(fb))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),c_=(()=>{class r extends fh{constructor(){super(),this.key="emailPrimarySelect",this.modes=["edit","create","massupdate"]}run(t,n){const f=t.field;if(!t.record||!f)return;const D=f.items;if(!f||!D||!D.length)return;const j=D.filter(ln=>!(ln&&ln.attributes&&ln.attributes.deleted));if(j&&1!==j.length)return;const fe=j[0],Ne=fe.fields&&fe.fields["email-fields"]||{},vt=Ne.attributes&&Ne.attributes.primary_address||null;vt&&!cl(vt.value)&&(vt.value="true",vt.formControl.setValue("true"),Ne.formControl.updateValueAndValidity({onlySelf:!0,emitEvent:!0}))}getTriggeringStatus(){return["onFieldInitialize"]}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Cy=r=>v=>r.isEmptyTrimmedInputValue(v.value)?{required:{required:!0,message:{labelKey:"LBL_VALIDATION_ERROR_REQUIRED",context:{value:v.value}}}}:null,hb=r=>v=>r.isEmptyBooleanInputValue(v.value)?{required:{required:!0,message:{labelKey:"LBL_VALIDATION_ERROR_REQUIRED",context:{value:v.value}}}}:null,Dy=(r,v,t)=>n=>{const o=r.name||"";if(!o||!v||!v.fields)return null;const f=v?.fields[o]??{};if(!f)return null;const D=f.valueList;return D&&D.length>0?null:{required:{required:!0,message:{labelKey:"LBL_VALIDATION_ERROR_REQUIRED",context:{}}}}};let mb=(()=>{class r{constructor(t){this.utils=t}applies(t,n){return!(!n||!n.fieldDefinition)&&("line-items"!==(n?.type??null)&&"line-items"!==(n?.fieldDefinition?.type??null)&&cl(n.fieldDefinition.required))}getValidator(t,n){const o=t?.type??t?.fieldDefinition?.type??"";return"boolean"===o?[hb(this.utils)]:"multienum"===o?[Dy(t,n,this.utils)]:[Cy(this.utils)]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ph=(()=>{class r{constructor(t){this.operatorManager=t}isActive(t,n,o,f,D){let j=!0;return(0,wt.isEmpty)(o)||(j=this.areFieldsActive(t,n,o)),(0,wt.isEmpty)(D)||(j=j&&this.areAttributesActive(f,n,D)),j}areAttributesActive(t,n,o){return t.every(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f]&&Object.keys(o[f]);if(j&&fe&&fe.length)return fe.some(Ne=>{const vt=o[f][Ne],ln=j.attributes&&j.attributes[Ne];if(vt&&vt.length&&ln)return this.isValueActive(n,ln,vt)})})}areFieldsActive(t,n,o){return t.every(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f];return!(j&&fe&&fe.length)||this.isValueActive(n,j,fe)})}isValueActive(t,n,o){let f=!1;if(n.valueList&&n.valueList.length)return n.valueList.some(fe=>o.some(Ne=>{if(Ne===fe)return f=!0,!0})),f;const D=Object.keys(t.fields);let j=[];return o.some(fe=>{if(fe.field&&!D.includes(fe.field))return;if(cl(fe)||sf(fe))return void(f=fe.toString()===n.value.toString());const Ne=fe?.operator??"is-equal";"string"==typeof fe&&(fe={operator:Ne,values:[fe]});const vt=this.operatorManager.get(Ne);j.push(vt.run(t,n,fe)),f=j.every(ln=>ln)}),f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(fb))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),JE=(()=>{class r extends fh{constructor(t,n){super(),this.requiredValidator=t,this.activeFieldsChecker=n,this.key="required",this.modes=["edit","create","massupdate","filter"]}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);if(!j.length&&!Ne.length)return;const vt=this.activeFieldsChecker.isActive(j,o,D,Ne,fe);let ln=!1,Hn=[...t.field.validators||[]];if(vt){ln=!0;const Oi={...f,display:f?.display()};Hn=Hn.concat(this.requiredValidator.getValidator(Oi,o))}t.field.formControl.updateValueAndValidity({onlySelf:!0,emitEvent:!0}),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0}),t.field.required.set(ln),t.field.formControl.setValidators(Hn),t.field.formControl.updateValueAndValidity({onlySelf:!0,emitEvent:!0}),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}getTriggeringStatus(){return["onAnyLogic","onFieldInitialize"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(mb),e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ev=(()=>{class r{constructor(t,n){this.config=t,this.preferences=n}getFieldCurrencyValue(t,n){const o=this.isBase(t),f=this.getCurrencyId(n);if(!o&&null!==f)return t.value;const D=parseFloat(t.value);if(!isFinite(D))return t.value;const j=this.getUserCurrency();return this.baseToCurrency(j.id,D).toString()}baseToCurrency(t,n){const o=this.getConversionRate(t);return isFinite(o)?this.round((0,Vc.multiply)(n,o)):n}currencyToBase(t,n){const o=this.getConversionRate(t);return isFinite(o)?this.round((0,Vc.divide)(n,o)):n}round(t){const n=this.getPrecision();return(0,Vc.round)(t,n)}getCurrencyId(t){return t?.fields?.currency_id?.value??null}isBase(t){return t?.metadata?.isBaseCurrency??!1}getCurrency(t){return this.config.getConfigValue("currencies")[t]??[]}getBaseCurrency(){return this.config.getConfigValue("currency")}getUserCurrency(){return this.preferences.getUserPreference("currency")}getPrecision(){const t=parseInt(this.preferences.getUserPreference("default_currency_significant_digits"));if(isFinite(t))return t;const n=parseInt(this.config.getConfigValue("default_currency_significant_digits"));return isFinite(n)?n:0}getConversionRate(t){const n=this.getCurrency(t);return parseFloat(n.conversion_rate)}getCode(t){return this.getCurrency(t).iso4217}getSymbol(t){return this.getCurrency(t).symbol}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),jM=(()=>{class r extends fh{constructor(t){super(),this.currencyService=t,this.key="update-base-currency",this.modes=["edit","create","massupdate","filter"]}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=n.params.currencyIdField??"currency_id",j=n.params.currencyField??"amount",fe=o?.fields[D]?.value??null;let Ne=parseFloat(o?.fields[j]?.value??null);if(!isFinite(Ne))return;null===fe&&this.updateValue(f,Ne,o);const vt=this.currencyService.currencyToBase(fe,Ne);isFinite(vt)&&this.updateValue(f,vt,o)}updateValue(t,n,o){t.value=n.toString(),t.formControl.setValue(n.toString()),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}getTriggeringStatus(){return["onAnyLogic"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ev))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),wy=(()=>{class r extends fh{constructor(t,n){super(),this.currencyService=t,this.currencyFormatter=n,this.key="update-currency",this.modes=["edit","create","massupdate","filter"]}run(t,n){const o=t.record,f=t.field;if(!o||!f||f?.definition?.metadata?.isBaseCurrency)return;const j=n.params.currencyIdField??"currency_id",fe=n.params.baseCurrencyField??"amount_usdollar",Ne=o?.fields[j]?.value??null;let vt=parseFloat(f?.value??null),ln=parseFloat(o?.fields[fe]?.value??null);if(!isFinite(vt)||!isFinite(ln)||null===Ne)return;const Hn=this.currencyService.baseToCurrency(Ne,ln);isFinite(Hn)&&this.updateValue(f,Hn,o)}updateValue(t,n,o){const D=this.currencyFormatter.toUserFormat(n.toString(),{mode:"edit"});t.value=D,t.formControl.setValue(D),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}getTriggeringStatus(){return["onAnyLogic"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ev),e.\u0275\u0275inject(Yg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),eT=(()=>{class r extends fh{constructor(){super(),this.key="update-flex-relate-module",this.modes=["edit","create","massupdate","filter"]}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=f.definition.type_name??"";""!==D&&(o?.fields[D]?.value??"")!==(f?.definition?.module??"")&&(f.definition.module=o?.fields[D]?.value??"",this.updateValue(f,{},"",o))}updateValue(t,n,o,f){t.value=o,t.valueObject=n,t.formControl.setValue(o),f.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}getTriggeringStatus(){return["onAttributeChange"]}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xy=(()=>{class r extends fh{constructor(t,n){super(),this.activeFieldsChecker=t,this.currencyFormatter=n,this.key="updateValue",this.modes=["edit","detail","list","create","massupdate","filter"]}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);if(!j.length&&!Ne.length)return;const vt=n.params&&n.params.targetValue;if(!vt)return;const ln=this.activeFieldsChecker.isActive(j,o,D,Ne,fe);let Hn=t.field?.value;ln&&(Hn=vt),this.isCurrencyField(f)&&(Hn=this.currencyFormatter.toUserFormat(Hn,{mode:"edit",fromFormat:"system"})),this.updateValue(f,Hn.toString(),o)}getTriggeringStatus(){return["onDependencyChange"]}updateValue(t,n,o){t.value=n.toString(),t.formControl.setValue(n),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}isCurrencyField(t){return"currency"===t.type}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ph),e.\u0275\u0275inject(Yg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),bo=(()=>{class r{constructor(t){this.config=t,this.messages=[],this.timeout=3,this.messagesStage=new i.BehaviorSubject([]),this.messages$=this.messagesStage.asObservable(),this.initTimeOut()}updateState(t){this.messagesStage.next(this.messages=t)}removeMessages(){this.updateState([])}contains(t,n=!1){let o=!1;for(let f=0;f<this.messages.length;f++)if(this.isSame(t,this.messages[f])){if(o=!0,n){const D=[...this.messages];D.splice(f,1),this.updateState(D)}break}return o}addMessage(t){let n=-1;if(!this.contains(t)){const o=[...this.messages];n=o.push(t),(t.type===Pf.success||t.type===Pf.warning)&&setTimeout(()=>{this.contains(t,!0)},1e3*this.timeout),this.updateState(o)}return n}addPrimaryMessage(t){return this.addMessage({type:Pf.primary,text:t})}addSecondaryMessage(t){return this.addMessage({type:Pf.secondary,text:t})}addSuccessMessage(t){return this.addMessage({type:Pf.success,text:t})}addSuccessMessageByKey(t,n=null){const o={type:Pf.success,labelKey:t};return n&&(o.defaultText=n),this.addMessage(o)}addDangerMessage(t){return this.addMessage({type:Pf.danger,text:t})}addDangerMessageByKey(t,n=null){const o={type:Pf.danger,labelKey:t};return n&&(o.defaultText=n),this.addMessage(o)}addWarningMessage(t){return this.addMessage({type:Pf.warning,text:t})}addWarningMessageByKey(t,n=null){const o={type:Pf.warning,labelKey:t};return n&&(o.defaultText=n),this.addMessage(o)}addInfoMessage(t){return this.addMessage({type:Pf.info,text:t})}addDarkMessage(t){return this.addMessage({type:Pf.dark,text:t})}log(...t){console.log.apply(console,t)}error(...t){console.error.apply(console,t)}initTimeOut(){const t=this.config.getConfigValue("ui");if(t&&t.alert_timeout){const n=parseInt(t.alert_timeout,10);isNaN(n)||(this.timeout=n)}}isSame(t,n){let o="text";return t.labelKey&&(o="labelKey"),t[o]===n[o]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class Ym{}let mc=(()=>{class r extends Ym{constructor(t,n){super(),this.router=t,this.message=n,this.key="redirect"}run(t){if(!t||!t.route)return void this.message.addDangerMessageByKey("LBL_MISSING_HANDLER_DATA_ROUTE");const n={queryParams:{}};t.queryParams&&(n.queryParams=t.queryParams),this.router.navigate([t.route],n).then()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),iw=(()=>{class r extends Ym{constructor(t){super(),this.message=t,this.key="export"}run(t){t&&t.url&&t.formData?this.download(t.url,t.formData):this.message.addDangerMessageByKey("LBL_MISSING_HANDLER_DATA_ROUTE")}download(t,n){const o=document.createElement("form");o.setAttribute("id","export-download"),o.setAttribute("method","post"),o.setAttribute("action",t),o.setAttribute("target","_self"),o.setAttribute("style","display: none;"),Object.keys(n).forEach(f=>{const D=document.createElement("input");D.setAttribute("name",f),D.setAttribute("value",n[f]),o.appendChild(D)}),document.body.appendChild(o),o.submit(),document.body.removeChild(o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),tT=(()=>{class r extends Ym{constructor(){super(),this.key="noop"}run(t){}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class Sy{constructor(){}init(v){this.iframe=v,this.initialSizeAdjustment(),this.addBodyResizeListener()}destroy(){this.observer&&this.observer.disconnect(),this.iframe=null,this.observer=null}initialSizeAdjustment(){setTimeout(this.onResize.bind(this),200)}addBodyResizeListener(){const v={document:this.iframe.contentWindow.document,element:this.iframe.contentWindow.document.body,height:this.iframe.contentWindow.document.body.scrollHeight,watched:[{getHeight:()=>{const t=v.document.getElementsByClassName("modal in"),n=t&&t[0],o=n&&n.firstElementChild;return o&&o.scrollHeight+200||-1}},{getHeight:()=>{const t=v.document.getElementById("bootstrap-container"),n=t&&t.scrollHeight+150||-1;return n>0?n:v.element.scrollHeight+50}}]};this.observer=(new xu.MutationObserverFactory).create(()=>{const t=[];v.watched.forEach(f=>{const D=f.getHeight();D>0&&t.push(D)}),t.sort((f,D)=>f-D);const n=t.pop(),o=this.calculateResizing(v.height,n);o.resized&&(v.height=o.height)}),this.observer.observe(this.iframe.contentWindow.document.body,{attributes:!0,childList:!0,characterData:!0,subtree:!0})}calculateResizing(v,t){const n=window.innerHeight-50;return t<n&&(t=n),v===t?{resized:!1}:v<t-20||this.iframe.scrollHeight>t?(this.resizeIFrame(t),{resized:!0,height:t}):{resized:!1}}onResize(){this.calculateResizing(this.iframe.offsetHeight,this.iframe.contentWindow.document.body.scrollHeight+120)}resizeIFrame(v){this.iframe.style.height=v+1+"px"}}class Uf{constructor(v,t=null,n=null,o=null){this.changeCallback=null,this.loadCallback=null,this.unLoadCallback=null,this.unloadListener=null,this.loadListener=null,this.iframe=v,this.changeCallback=t,this.loadCallback=n,this.unLoadCallback=o}init(){this.loadListener=this.loadHandler.bind(this),this.unloadListener=this.unloadHandler.bind(this),this.iframe.contentWindow.addEventListener("load",this.loadListener),this.iframe.contentWindow.removeEventListener("unload",this.unloadListener)}destroy(){const v=this.iframe&&this.iframe.contentWindow;v&&(v.removeEventListener("unload",this.unloadListener),v.removeEventListener("load",this.loadListener)),this.iframe=null,this.lastDispatched=null,this.changeCallback=null,this.loadCallback=null,this.unLoadCallback=null,this.loadListener=null,this.unloadListener=null}loadHandler(){this.loadCallback(),this.bindUnload()}bindUnload(){this.iframe.contentWindow.removeEventListener("unload",this.unloadListener),this.unloadListener=this.unloadHandler.bind(this),this.iframe.contentWindow.addEventListener("unload",this.unloadListener)}unloadHandler(){this.unLoadCallback(),setTimeout(this.triggerPageChange.bind(this),0)}triggerPageChange(){const v=this.iframe&&this.iframe.contentWindow&&this.iframe.contentWindow.location.href;v&&v!==this.lastDispatched&&(this.lastDispatched=v,this.changeCallback(v))}}const UM=["dataContainer"];let gb=(()=>{class r{constructor(t,n){this.languageStore=t,this.activeModal=n,this.url="",this.titleKey="",this.asyncActionCallback=null,this.iframe=null}ngOnInit(){this.closeButton={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.activeModal.close({type:"close-button"})}}}ngAfterViewInit(){this.initIframe()}ngOnDestroy(){this.cleanObservers(),this.iframe=null;const t=this.wrapper;this.wrapper.firstChild&&t.removeChild(t.firstChild),t.innerHTML="<iframe></iframe>",this.wrapper=null}cleanObservers(){this.iframeResizeHandler&&(this.iframeResizeHandler.destroy(),this.iframeResizeHandler=null),this.iframePageChangeHandler&&(this.iframePageChangeHandler.destroy(),this.iframePageChangeHandler=null)}initIframe(){this.wrapper=this.dataContainer.nativeElement,this.wrapper.firstChild&&this.wrapper.removeChild(this.wrapper.firstChild);const t=document.createElement("iframe");t.src=this.url,this.wrapper.appendChild(t),this.iframe=t,this.iframe.style.display="block",this.initObservers()}initObservers(){this.iframePageChangeHandler=this.buildIframePageChangeObserver(),this.iframeResizeHandler=this.buildIframeResizeHandlerHandler(),this.iframePageChangeHandler&&this.iframePageChangeHandler.init()}onIFrameLoad(){this.iframe.contentWindow.document.body.style.overflow="hidden",null!==this.asyncActionCallback&&this.asyncActionCallback(this.iframe),this.iframeResizeHandler.init(this.iframe)}onIFrameUnload(){this.iframe.style.display="none",this.iframeResizeHandler.destroy()}buildIframePageChangeObserver(){return new Uf(this.iframe,null,this.onIFrameLoad.bind(this),this.onIFrameUnload.bind(this))}buildIframeResizeHandlerHandler(){return new Sy}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(ct.NgbActiveModal))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-classic-modal"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(UM,7),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.dataContainer=f.first)}},inputs:{url:"url",titleKey:"titleKey",asyncActionCallback:"asyncActionCallback"},decls:5,vars:3,consts:[["dataContainer",""],["bodyKlass","m-0 small-font","footerKlass","border-0","klass","classic-view-modal",3,"closable","close","titleKey"],["modal-body",""],[1,"classic-view-container"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-modal",1)(1,"div",2)(2,"div",3,0),e.\u0275\u0275element(4,"iframe"),e.\u0275\u0275elementEnd()()()),2&n&&e.\u0275\u0275property("closable",!0)("close",o.closeButton)("titleKey",o.titleKey)},dependencies:[qm],encapsulation:2,data:{animation:[(0,sr.trigger)("modalFade",[(0,sr.transition)("void <=> *",[(0,sr.animate)("800ms")])])]}})}return r})(),Z1=(()=>{class r extends Ym{constructor(t,n,o){super(),this.router=t,this.modalService=n,this.message=o,this.key="audit"}run(t){t&&t.url?this.showClassicViewModal(t.url):this.message.addDangerMessageByKey("LBL_MISSING_HANDLER_DATA_ROUTE")}changeLogLegacyContentFormatter(t){if(!t)return;const n=t.contentDocument.getElementsByClassName("moduleTitle")[0];n&&(n.innerText="")}showClassicViewModal(t){const n=this.modalService.open(gb,{size:"xl",centered:!0,scrollable:!0});n.componentInstance.titleKey="LBL_CHANGE_LOG",n.componentInstance.url=t,n.componentInstance.asyncActionCallback=this.changeLogLegacyContentFormatter.bind(this)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Tl=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.processService=t,this.appStateStore=n,this.message=o,this.redirectAction=f,this.exportAction=D,this.noopAction=j,this.changelogAction=fe,this.actions={},this.registerHandler(f),this.registerHandler(D),this.registerHandler(j),this.registerHandler(fe)}registerHandler(t){this.actions[t.key]=t}run(t,n,o=null,f=null){const D={...n};return this.appStateStore.updateLoading(t,!0),this.processService.submit(t,D).pipe((0,M.take)(1),(0,M.tap)(j=>{this.appStateStore.updateLoading(t,!1);let fe="addSuccessMessageByKey";if("error"===j.status&&(fe="addDangerMessageByKey"),j.messages&&j.messages.forEach(ln=>{ln&&this.message[fe](ln)}),"error"===j.status)return;const Ne=o||j.data&&j.data.handler||null;if(!Ne)return;const vt=this.actions[Ne];vt?vt.run(j.data.params):this.message.addDangerMessageByKey("LBL_MISSING_HANDLER")}),(0,M.catchError)(j=>"Access Denied."===(j?.message??"")?(this.appStateStore.updateLoading(t,!1),(0,i.of)(null)):(this.appStateStore.updateLoading(t,!1),f?.errorMessageLabel?(this.message.addDangerMessage(f?.errorMessageLabel),(0,i.of)(null)):f?.errorMessageLabelKey?(this.message.addDangerMessageByKey(f?.errorMessageLabelKey,"Unexpected error when calling action, please contact your system administrator."),(0,i.of)(null)):(this.message.addDangerMessageByKey("LBL_ACTION_ERROR","Unexpected error when calling action, please contact your system administrator."),(0,i.of)(null)))))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bf),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(mc),e.\u0275\u0275inject(iw),e.\u0275\u0275inject(tT),e.\u0275\u0275inject(Z1))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),jh=(()=>{class r{getKey(){return"base"}map(t){!t.fields||!Object.keys(t.fields).length||Object.keys(t.fields).forEach(n=>{const o=t.fields[n],f=o.type||"",D=o.definition.source||"",j=o.definition.rname||"name",fe=o.definition.id_name||"";if("relate"!==f||"non-db"!==D||fe!==n){if("relate"===f&&"non-db"===D&&""!==j&&o.valueObject){const Ne=t.attributes[n]||{};return Ne[j]=o.valueObject[j],Ne.id=o.valueObject.id,t.attributes[n]=Ne,void(t.attributes[fe]=o.valueObject.id)}if(!o.valueObject)return o.items?(t.attributes[n]=[],void o.items.forEach(Ne=>{!Ne?.id&&Ne?.attributes?.deleted||t.attributes[n].push({id:Ne.id,module:Ne.module,attributes:dr(Ne.attributes)})})):void(o.valueObjectArray?t.attributes[n]=o.valueObjectArray:o.valueList?t.attributes[n]=o.valueList:!o.vardefBased||!(0,wt.isNil)(o.value)&&""!==o.value?t.attributes[n]=o.value:(0,wt.isNil)(t.attributes[n])||delete t.attributes[n]);t.attributes[n]=o.valueObject}else t.attributes[n]=o.value})}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),lS=(()=>{class r extends fh{constructor(t,n,o,f,D,j){super(),this.asyncActionService=t,this.processService=n,this.messages=o,this.recordMappers=f,this.baseMapper=D,this.activeFieldsChecker=j,this.key="updateValueBackend",this.modes=["edit","detail","list","create","massupdate","filter"],f.register("default",D.getKey(),D)}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);if(!j.length&&!Ne.length)return;const vt=n.params&&n.params.process;if(vt&&this.activeFieldsChecker.isActive(j,o,D,Ne,fe)){const Hn=vt,Oi=this.getBaseRecord(o),Lr={action:Hn,module:o.module??"",record:Oi};f.loading.set(!0),this.processService.submit(Hn,Lr).pipe((0,M.take)(1)).subscribe({next:to=>{const Mr=to?.data?.value??null;f.loading.set(!1),null!==Mr?this.updateValue(f,Mr.toString(),o):this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")},error:to=>{f.loading.set(!1),this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")}})}}getTriggeringStatus(){return["onDependencyChange"]}getBaseRecord(t){return t?(this.mapRecordFields(t),dr({id:t.id,type:t.type,module:t.module,attributes:t.attributes,acls:t.acls})):null}mapRecordFields(t){const n=this.recordMappers.get(t.module);Object.keys(n).forEach(o=>{n[o].map(t)})}updateValue(t,n,o){t.value=n.toString(),t.formControl.setValue(n),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh),e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),rw=(()=>{class r extends fh{constructor(t,n,o,f,D,j){super(),this.asyncActionService=t,this.processService=n,this.messages=o,this.recordMappers=f,this.baseMapper=D,this.activeFieldsChecker=j,this.key="displayTypeBackend",this.modes=["edit","detail","list","create","massupdate","filter"],f.register("default",D.getKey(),D)}run(t,n){const o=t.record,f=t.field;if(!o||!f)return;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);if(!j.length&&!Ne.length)return;const vt=n.params&&n.params.process;if(!vt)return;const ln=this.activeFieldsChecker.isActive(j,o,D,Ne,fe);let Hn=t.field.defaultDisplay;if(ln){const Lr=vt,to=this.getBaseRecord(o),Mr={action:Lr,module:o.module??"",record:to};f.loading.set(!0),this.processService.submit(Lr,Mr).subscribe(ss=>{const Rs=ss?.data?.value??null;f.loading.set(!1),null!==Rs?(Hn=Rs,t.field.display.set(Hn)):this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")},ss=>{f.loading.set(!1),this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")})}(n.params&&n.params.resetOn||"none")===Hn&&(t.field.valueList&&t.field.valueList.length&&(t.field.valueList=[]),t.field.value&&(t.field.value=""))}getBaseRecord(t){return t?(this.mapRecordFields(t),dr({id:t.id,type:t.type,module:t.module,attributes:t.attributes,acls:t.acls})):null}mapRecordFields(t){const n=this.recordMappers.get(t.module);Object.keys(n).forEach(o=>{n[o].map(t)})}getTriggeringStatus(){return["onAnyLogic","onFieldInitialize"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh),e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Qs=(()=>{class r extends js{constructor(t,n,o,f,D,j,fe,Ne,vt){super(),this.actions={edit:{},create:{},list:{},detail:{},massupdate:{},filter:{}},t.modes.forEach(ln=>this.actions[ln][t.key]=t),n.modes.forEach(ln=>this.actions[ln][n.key]=n),o.modes.forEach(ln=>this.actions[ln][o.key]=o),f.modes.forEach(ln=>this.actions[ln][f.key]=f),D.modes.forEach(ln=>this.actions[ln][D.key]=D),fe.modes.forEach(ln=>this.actions[ln][fe.key]=fe),j.modes.forEach(ln=>this.actions[ln][j.key]=j),Ne.modes.forEach(ln=>this.actions[ln][Ne.key]=Ne),vt.modes.forEach(ln=>this.actions[ln][vt.key]=vt)}runLogic(t,n,o,f="",D={}){if(!t.logic)return;const j=Object.keys(t.logic).map(vt=>t.logic[vt]),fe=this.parseModeActions(j,n,f,D),Ne={record:o,field:t,module:o.module};fe.forEach(vt=>{this.runAction(vt,n,Ne)})}runAction(t,n,o=null){this.runFrontEndAction(t,n,o)}runFrontEndAction(t,n,o=null){const f=this.buildActionData(t,o);this.run(t,n,f)}getModuleName(t){return t.module}buildActionData(t,n){return{field:n.field,record:n&&n.record||null}}parseModeActions(t,n,o,f){if(!t)return[];const D={list:[],detail:[],edit:[],create:[],massupdate:[],filter:[]};t&&t.length&&t.forEach(Ne=>{!Ne.modes||!Ne.modes.length||Ne.modes.forEach(vt=>{!D[vt]&&!Ne.asyncProcess||D[vt].push(Ne)})});const j=[],fe=["onDependencyChange"];return D[n].forEach(Ne=>{const vt=Object.keys(Ne?.params?.activeOnFields??{}),ln=this?.actions[n][Ne.key]?.getTriggeringStatus()??null;let Hn=Ne?.triggeringStatus??ln??fe;Hn.includes("onValueChange")&&(Hn=Hn.filter(Oi=>"onValueChange"!==Oi),Hn=["onAnyLogic",...Hn]),Hn.includes("onAnyLogic")&&"onFieldInitialize"!==o?j.push(Ne):o&&!Hn.includes(o)||Hn.includes("onDependencyChange")&&!vt?.includes(f.name)||j.push(Ne)}),j}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pb),e.\u0275\u0275inject(c_),e.\u0275\u0275inject(JE),e.\u0275\u0275inject(jM),e.\u0275\u0275inject(wy),e.\u0275\u0275inject(xy),e.\u0275\u0275inject(eT),e.\u0275\u0275inject(lS),e.\u0275\u0275inject(rw))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class vb extends kp{shouldDisplay(v){return!0}}let nT=(()=>{class r extends vb{constructor(t){super(),this.activeFieldsChecker=t,this.key="displayType",this.modes=["edit","detail","list","create","massupdate","filter"]}run(t,n){const o=t.record;if(!o||!t.field)return!0;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);return!j.length&&!Ne.length||this.activeFieldsChecker.isActive(j,o,D,Ne,fe)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),qo=(()=>{class r extends js{constructor(t){super(),t.modes.forEach(n=>this.actions[n][t.key]=t)}runAll(t,n,o){let f="show";if(!t.displayLogic)return;const D=Object.values(t.displayLogic).filter(ln=>{const Hn=ln.modes??[];return!(!Hn.length||!Hn.includes(o))});if(!D||!D.length)return void t.display.set(f);let j=t.defaultDisplay??"show",fe="none";"none"===j&&(fe="show");const Ne={record:n,field:t,module:n.module};D.some(ln=>{const Hn=this.buildActionData(ln,Ne);return this.actions[o][ln.key].run(Hn,ln)})&&(j=fe),f=j,"show"===j&&(f="show"),t.display.set(f)}buildActionData(t,n){return{field:n.field,record:n&&n.record||null}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(nT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Xm=(()=>{class r{initDefaultValue(t,n){if(t.defaultValueInitialized)return;const o=t?.default??t?.definition?.default??null;!t.value&&o?(t.value=o,t?.formControl?.setValue(o),t.defaultValueInitialized=!0):null===t.value&&(t.value="")}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),cS=(()=>{class r extends Xm{constructor(t,n){super(),this.processService=t,this.messages=n}initDefaultValue(t,n){if(t.defaultValueInitialized)return;let o=t?.default??t?.definition?.default??null,f=t?.definition?.display_default??null;if(!o&&!f)return void(t.defaultValueInitialized=!0);if("string"!=typeof o&&"string"!=typeof f)return;if(o&&"string"!=typeof o)return void super.initDefaultValue(t,n);const D="calculate-date-default",j={action:D,module:n.module??"",field:t.name,displayDefault:f};t.loading.set(!0),this.processService.submit(D,j).pipe((0,M.take)(1)).subscribe(fe=>{const Ne=fe?.data?.value??null;t.loading.set(!1),null!==Ne?(this.updateValue(t,Ne.toString(),n),t.defaultValueInitialized=!0):this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")})}updateValue(t,n,o){t.value=n.toString(),t.formControl.setValue(n),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bf),e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),iT=(()=>{class r extends Xm{initDefaultValue(t,n){if(t.defaultValueInitialized)return;let o=t?.default??t?.definition?.default??null;if(!o)return void(t.defaultValueInitialized=!0);if("string"!=typeof o)return;o=(0,wt.trimStart)(o,"^"),o=(0,wt.trimEnd)(o,"^");const f=o.split("^,^");o?(f&&f.length&&(t.valueList=f),t.defaultValueInitialized=!0):t.defaultValueInitialized=!0}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Ey=(()=>{class r extends Xm{static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ow=(()=>{class r extends pp{constructor(t,n,o){super(),this.defaultFieldHandler=t,this.dateFieldHandler=n,this.multienumFieldHandler=o,this.defaultMap={},this.defaultMap={default:t,date:n,multienum:o},this.initDefault()}initDefault(){Object.keys(this.getDefaultMap()).forEach(t=>{this.register("default",t,this.getDefaultMap()[t])})}getDefaultMap(){return this.defaultMap??{}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ey),e.\u0275\u0275inject(cS),e.\u0275\u0275inject(iT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),lu=(()=>{class r{get mode(){return this._mode}set mode(t){this._mode=t,this.modeState.next(this._mode)}constructor(t,n,o){this.typeFormatter=t,this.logic=n,this.logicDisplay=o,this.originalMode="",this.klass=null,this._mode="",this.dependentFields={},this.dependentAttributes=[],this.subs=[],this.validateOnlyOnSubmit=!1,this.isInvalid=(0,e.signal)(!1),this.modeState=new i.BehaviorSubject(""),this.mode$=this.modeState.asObservable(),this.fieldHandlerRegistry=(0,e.inject)(ow)}ngOnInit(){this.baseInit(),this.originalMode||(this.originalMode=this.mode),(this?.field?.defaultValueModes??[]).includes(this.originalMode)&&this.fieldHandlerRegistry.get(this.record.module,this.field.type).initDefaultValue(this.field,this.record)}ngOnDestroy(){this.unsubscribeAll()}baseInit(){this.initDependencyHandlers(),this.validateOnlyOnSubmit=this.record?.metadata?.validateOnlyOnSubmit,this.record?.validationTriggered&&(this.isInvalid=(0,e.computed)(()=>!!(this.record?.metadata?.validateOnlyOnSubmit&&this.record?.validationTriggered()&&this.field.formControl?.invalid)))}initDependencyHandlers(){if(!this.record)return;const t=this.record.fields&&Object.keys(this.record.fields)||[];t.length>1&&(this.calculateDependentFields(t),this.field.previousValue=this.field.value,(this.dependentFields&&Object.keys(this.dependentFields).length||this.dependentAttributes.length)&&Object.keys(this.dependentFields).forEach(n=>{const o=this.record.fields[n]||null;if(!o)return;const f=this.dependentFields[n].type??[];f.includes("logic")&&this.logic.runLogic(o,this.originalMode,this.record,"onFieldInitialize"),f.includes("displayLogic")&&this.logicDisplay.runAll(o,this.record,this.originalMode)}),this.field.valueChanges$&&(this.dependentFields&&Object.keys(this.dependentFields).length||this.dependentAttributes.length)&&this.subs.push(this.field.valueChanges$.pipe((0,M.debounceTime)(500)).subscribe(n=>{Object.keys(this.dependentFields).forEach(o=>{const f=this.dependentFields[o],D=this.record.fields[o]||null,j=this.record.fields[f.field]||null;if(D&&this.field.previousValue!=n.value){const fe=f.type??[];fe.includes("logic")&&this.logic.runLogic(D,this.originalMode,this.record,"onDependencyChange",j),fe.includes("displayLogic")&&this.logicDisplay.runAll(D,this.record,this.originalMode)}}),this.field.previousValue=n.value,this.dependentAttributes.forEach(o=>{const f=this.record.fields[o.field]||{},D=f&&f.attributes&&f.attributes[o.attribute]||null;D&&this.logic.runLogic(D,this.mode,this.record,"onAttributeChange")})})))}calculateDependentFields(t){t.forEach(n=>{"field"!==this.field.source&&"groupField"!==this.field.source?"attribute"!==this.field.source||this.addAttributeDependency(n,this.dependentFields,this.dependentAttributes):this.addFieldDependency(n,this.dependentFields,this.dependentAttributes)})}addFieldDependency(t,n,o){const f=this.record.fields[t],D=this.field.name||this.field.definition.name||"";t!==D&&f&&(f.fieldDependencies&&this.isDependencyField(f.fieldDependencies)&&(n[t]=f.fieldDependencies[D]),(f.attributes&&Object.keys(f.attributes)||[]).forEach(fe=>{const Ne=f.attributes[fe];!Ne||!Ne.fieldDependencies||!Ne.fieldDependencies.length||this.isDependencyField(Ne.fieldDependencies)&&o.push({field:t,attribute:fe,types:n[D].types??[]})}))}isDependencyField(t){return!!t[this.field.name||this.field.definition.name||""]}addAttributeDependency(t,n,o){const f=this.record.fields[t],D=this.field.name||this.field.definition.name||"";t!==D&&f&&(f.attributeDependencies&&f.attributeDependencies.length&&this.isDependencyAttribute(f.attributeDependencies)&&(n[D]=f.fieldDependencies[D]),(f.attributes&&Object.keys(f.attributes)||[]).forEach(fe=>{const Ne=f.attributes[fe];Ne&&Ne.attributeDependencies&&Ne.attributeDependencies.length&&this.isDependencyAttribute(Ne.attributeDependencies)&&o.push({field:t,attribute:fe,types:(n[D]??{}).types??[]})}))}isDependencyAttribute(t){const n=this.field.parentKey||"",o=this.field.name||this.field.definition.name||"";return t.some(f=>n===f.field&&o===f.attribute)}subscribeValueChanges(){this.field&&this.field.formControl&&this.subs.push(this.field.formControl.valueChanges.subscribe(t=>{t=Al(t)?"":t.trim(),this.typeFormatter&&this.field.type&&(t=this.toInternalFormat(this.field.type,t)),this.setFieldValue(t)}))}toInternalFormat(t,n){return this.typeFormatter.toInternalFormat(t,n)}setFieldValue(t){this.field.value=t}setFormControlValue(t){(0,wt.isEqual)(this.field.formControl.value,t)?this.field.formControl.markAsPristine():(this.field.formControl.setValue(t),this.field.formControl.markAsDirty())}unsubscribeAll(){this.subs.forEach(t=>t.unsubscribe())}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],inputs:{originalMode:"originalMode",field:"field",record:"record",parent:"parent",klass:"klass",mode:"mode"},decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),vp=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}getTelLink(t){return t?"tel:"+this.getUnFormatted(t):null}getUnFormatted(t){return t?t.replace(/\s+/g,""):""}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-phone-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[[3,"href"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"a",0),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("href",o.getTelLink(o.field.value),e.\u0275\u0275sanitizeUrl),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(o.field.value))},encapsulation:2})}return r})(),Uh=(()=>{class r extends lu{constructor(t,n,o,f){super(n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f,this.selectedValues=[],this.valueLabel="",this.options=[],this.subs=[],this.isDynamicEnum=!1}ngOnInit(){super.ngOnInit();const t=this?.field?.metadata?.options$??null;if(t)return void this.subs.push(this.field.metadata.options$.subscribe(o=>{this.buildProvidedOptions(o),this.initValue()}));const n=this?.field?.definition?.options??null;n&&this.subs.push(this.languages.vm$.subscribe(o=>{this.buildAppStringListOptions(o.appListStrings),this.initValue()})),!n&&!t&&this.initValue()}ngOnDestroy(){this.isDynamicEnum=!1,this.subs.forEach(t=>t.unsubscribe()),this.options=[],this.optionsMap={},this.selectedValues=[]}getInvalidClass(){return(this.validateOnlyOnSubmit?this.isInvalid():this.field.formControl.invalid&&this.field.formControl.touched)?"is-invalid":""}buildProvidedOptions(t){this.options=t,this.optionsMap={},t.forEach(n=>{this.optionsMap[n.value]=n.label})}buildAppStringListOptions(t){if(this.optionsMap={},this.addExtraOptions(),t&&this.field.definition.options&&t[this.field.definition.options]){const n=t[this.field.definition.options];this.options&&Object.keys(this.options)&&(this.optionsMap={...this.optionsMap,...n})}this.buildOptionsArray(t)}addExtraOptions(){(this.field.metadata&&this.field.metadata.extraOptions||[]).forEach(n=>{if(Al(n.value))return;let o=n.label||"";n.labelKey&&(o=this.languages.getFieldLabel(n.labelKey)),this.optionsMap[n.value]=o})}buildOptionsArray(t){this.options=[],Object.keys(this.optionsMap).forEach(n=>{const o=Ud(this.optionsMap[n]);o&&this.isSkipEmptyMode()||o&&!this.addEmptyStringOption()||this.options.push({value:n,label:this.optionsMap[n]})}),this.isDynamicEnum&&this.buildDynamicEnumOptions(t)}addEmptyStringOption(){return"multienum"!==this.field.type}isSkipEmptyMode(){return"massupdate"===this.mode||"filter"===this.mode}initValue(){this.selectedValues=[],(this.field.criteria||"string"==typeof this.field.value&&this.optionsMap&&"string"==typeof this.optionsMap[this.field.value])&&this.initValueLabel()}initValueLabel(){const t=this.field.value||this.field.criteria?.target||void 0;void 0!==t&&(this.valueLabel=this.optionsMap[t],this.selectedValues.push({value:t,label:this.valueLabel}))}initEnumDefault(){if(!Ud(this.record?.id))return void this.field?.formControl.setValue("");let t=this?.field?.default??this?.field?.definition?.default??null;"string"==typeof t&&(t=t.trim()),t?(this.selectedValues.push({value:t,label:this.optionsMap[t]}),this.initEnumDefaultFieldValues(t)):this.field.formControl.setValue("")}initEnumDefaultFieldValues(t){if("multienum"===this.field.type){const n=this.selectedValues.map(o=>o.value);this.field.valueList=n,this.field.formControl.setValue(n)}else this.field.value=t,this.field.formControl.setValue(t);this.field.formControl.markAsDirty()}checkAndInitAsDynamicEnum(){const t=this.field&&this.field.definition||{},o=t&&t.parentenum||"",f=this.record&&this.record.fields||null;if(t&&t.dynamic&&o&&f){this.isDynamicEnum=!0;const D=f[o];D&&this.subscribeToParentValueChanges(D)}}buildDynamicEnumOptions(t){const n=this.record.fields[this.field.definition.parentenum];if(n){const o=t[n.definition.options];if(o&&0!==Object.keys(o).length){this.mappedOptions=this.createParentChildOptionsMap(o,this.options);let f=[];"multienum"===n.definition.type?f=n.valueList:f.push(n.value),this.options=this.filterMatchingOptions(f),f&&f.length&&this.setValueToAvailableOption()}}}filterMatchingOptions(t){let n=[];return t&&t.length?(t.forEach(o=>{this.mappedOptions[o]&&(n=n.concat([...this.mappedOptions[o]]))}),n):[]}createParentChildOptionsMap(t,n){const o={};return Object.keys(t).forEach(f=>{o[f]=n.filter(D=>String(D.value).startsWith(f))}),o}subscribeToParentValueChanges(t){t.formControl&&this.subs.push(t.formControl.valueChanges.subscribe(n=>{"string"==typeof n&&(n=[n]),this.options=this.filterMatchingOptions(n),this.setValueToAvailableOption(),this.initValue()}))}setValueToAvailableOption(){if(!this?.options?.length)return this.field.value="",void this.field.formControl.setValue("");this.options.some(t=>t.value===this.field.value)||(this.field.value=this.options[0].value,this.field.formControl.setValue(this.options[0].value))}buildOptionFromValue(t){const n={value:"",label:""};if((0,wt.isNull)(t))return n;n.value=("string"!=typeof t?JSON.stringify(t):t).trim(),n.label=n.value;const o=this.optionsMap[n.value]??n.label;return(0,wt.isObject)(o)||(n.label=("string"!=typeof o?JSON.stringify(o):o).trim()),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),J1=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}subscribeValueChanges(){}initValue(){const t=this.field.valueList;Al(t)||(0,wt.isEmpty)(t)||this.updateInternalState(t)}updateInternalState(t=[]){const n=(0,wt.isArray)(t)?t:[t];this.selectedValues=n.map(o=>this.buildOptionFromValue(o)),this.selectedValues=(0,wt.uniqBy)(this.selectedValues,"value"),this.syncSelectedValuesWithForm()}syncSelectedValuesWithForm(){const t=this.selectedValues.map(n=>n.value);return(0,wt.isEqual)(this.field.valueList,t)||this.setFormControlValue(t),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();const eC=["multiSelect"];function uS(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",6)}function sw(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",7)}function Ty(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",8)}let Zm=(()=>{class r extends J1{constructor(t,n,o,f,D,j,fe){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f,this.screenSize=D,this.systemConfigStore=j,this.primengConfig=fe,this.placeholderLabel="",this.selectedItemsLabel="",this.emptyFilterLabel="",this.maxSelectedLabels=20,this.selectAll=!1}ngOnInit(){this.field.valueList=[],this.field.criteria.values&&this.field.criteria.values.length>0&&(this.field.valueList=this.field.criteria.values);const t=this.systemConfigStore.getUi("multiselect_max_number");this.screenSize.screenSize$.pipe((0,M.take)(1)).subscribe(n=>{this.maxSelectedLabels=t[n]||this.maxSelectedLabels}),this.getTranslatedLabels(),super.ngOnInit(),this.primengConfig.ripple=!0}onAdd(){const t=this.selectedValues.map(n=>n.value);this.field.valueList=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty(),this.field.criteria.operator="=",this.field.criteria.values=t,this.calculateSelectAll()}onRemove(){let t=this.selectedValues.map(n=>n.value);t||(t=[]),this.field.valueList=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty(),this.field.criteria.operator="=",this.field.criteria.values=t,this.calculateSelectAll()}onClear(){this.selectedValues=[],this.multiSelect.filterValue="",this.onRemove()}onPanelShow(){this.multiSelect.filterInputChild.nativeElement.focus(),this.multiSelect.filterValue="",this.calculateSelectAll()}onFilter(){this.calculateSelectAll()}getPlaceholderLabel(){return this.languages.getAppString("LBL_SELECT_ITEM")||""}onSelectAll(t){this.selectAll=t.checked,this.selectAll?(this.selectedValues=this.multiSelect.visibleOptions()&&this.multiSelect.visibleOptions().length?this.multiSelect.visibleOptions():this.options,this.onAdd()):(this.selectedValues=[],this.onRemove())}getTranslatedLabels(){this.placeholderLabel=this.languages.getAppString("LBL_SELECT_ITEM")||"",this.selectedItemsLabel=this.languages.getAppString("LBL_ITEMS_SELECTED")||"",this.emptyFilterLabel=this.languages.getAppString("ERR_SEARCH_NO_RESULTS")||""}addEmptyStringOption(){return!1}calculateSelectAll(){const t=this?.multiSelect?.visibleOptions()??[],n=(this?.selectedValues??[]).map(o=>o.value);this.selectAll=!(!t.length||!n.length)&&!(t.length>n.length)&&t.every(o=>n.includes(o.value))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(mf))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-multienum-filter"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(eC,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.multiSelect=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:6,vars:14,consts:[["multiSelect",""],[1,"d-flex","align-items-center"],[3,"ngModelChange","onChange","onSelectAllChange","onRemove","onPanelShow","onFilter","onClear","options","ngModel","optionLabel","placeholder","selectedItemsLabel","emptyFilterMessage","maxSelectedLabels","styleClass","showToggleAll","selectAll","autoOptionFocus","autofocusFilter","showClear","focusOnHover"],["pTemplate","dropdownicon"],["pTemplate","filtericon"],["pTemplate","checkicon"],["image","down_carret"],["image","search"],["image","checkbox_cross"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"p-multiSelect",2,0),e.\u0275\u0275twoWayListener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.selectedValues,j)||(o.selectedValues=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275listener("onChange",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onAdd())})("onSelectAllChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onSelectAll(j))})("onRemove",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onRemove())})("onPanelShow",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onPanelShow())})("onFilter",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onFilter())})("onClear",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onClear())}),e.\u0275\u0275template(3,uS,1,0,"ng-template",3)(4,sw,1,0,"ng-template",4)(5,Ty,1,0,"ng-template",5),e.\u0275\u0275elementEnd()()}2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("options",o.options),e.\u0275\u0275twoWayProperty("ngModel",o.selectedValues),e.\u0275\u0275property("optionLabel","label")("placeholder",o.placeholderLabel)("selectedItemsLabel","{0} "+o.selectedItemsLabel)("emptyFilterMessage",o.emptyFilterLabel)("maxSelectedLabels",o.maxSelectedLabels)("styleClass","w-100 "+o.getInvalidClass())("showToggleAll",!0)("selectAll",o.selectAll)("autoOptionFocus",!1)("autofocusFilter",!0)("showClear",!0)("focusOnHover",!0))},dependencies:[Ji.NgControlStatus,Ji.NgModel,Bl,M0,Zc],encapsulation:2})}return r})(),dS=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-enum-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.valueLabel,"\n")},encapsulation:2})}return r})(),_b=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})(),fS=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}getNameField(t,n){if(!t.value||!n.attributes)return;const o=t.value.split(" "),f=[];return o.forEach(D=>{n.attributes[D]&&f.push(n.attributes[D])}),f.join(" ")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),tC=(()=>{class r extends fS{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}ngOnInit(){super.ngOnInit(),this.data=this.getNameField(this.field,this.record)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-fullname-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.data,"\n")},encapsulation:2})}return r})(),tv=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),nv=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-varchar-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.field.value,"\n")},encapsulation:2})}return r})(),wf=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}get target(){return this.field.metadata&&this.field.metadata.target?this.field.metadata.target:"_blank"}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-url-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[3,"target","href"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"a",0),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275propertyInterpolate("href",o.field.value,e.\u0275\u0275sanitizeUrl),e.\u0275\u0275property("target",o.target),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(o.field.value))},encapsulation:2})}return r})(),nC=(()=>{class r extends lu{constructor(t,n,o,f){super(n,o,f),this.formatter=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f,this.vm$=this.formatter.format$}getDateTimeFormat(){return this.field?.metadata?.date_time_format?this.field.metadata.date_time_format:this.formatter.getDateTimeFormat()}toInternalFormat(t,n){return this.formatter.toInternalFormat(n,{fromFormat:this.getDateTimeFormat()})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kh),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),My=(()=>{class r extends nC{constructor(t,n,o,f){super(t,n,o,f),this.formatter=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}getDateFormat(){return this.field?.metadata?.date_time_format?this.field?.metadata?.date_time_format??"":this.formatter.getDateFormat()}toInternalFormat(t,n){return this.formatter.toInternalFormat(n,{fromFormat:this.getDateFormat()})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kh),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();function pS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"date"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind2(2,1,t.field.value,t.getDateFormat()),"\n")}}let iC=(()=>{class r extends My{constructor(t,n,o,f){super(t,n,o,f),this.formatter=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(r_),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-date-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,pS,3,4,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe,ve.DatePipe],encapsulation:2})}return r})(),Iy=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),u_=(()=>{class r{constructor(t){this.formatter=t}transform(t,n=null){return this.formatter.toUserFormat(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Yg,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"formatCurrency",type:r,pure:!0})}return r})(),Jm=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),eg=(()=>{class r extends lu{constructor(t,n,o,f,D){super(o,f,D),this.userPreferences=t,this.systemConfig=n,this.typeFormatter=o,this.logic=f,this.logicDisplay=D,this.preferences$=this.userPreferences.userPreferences$,this.configs$=this.systemConfig.configs$,this.vm$=this.configs$.pipe((0,i.combineLatestWith)(this.preferences$),(0,M.map)(([j,fe])=>({configs:j,preferences:fe})))}get format(){return!this.field.metadata||!1!==this.field.metadata.format}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();function Ay(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"formatCurrency"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind2(2,1,t.getCurrencyValue(),t.getOptions()),"\n")}}let iv=(()=>{class r extends eg{constructor(t,n,o,f,D,j){super(t,n,o,f,j),this.userPreferences=t,this.systemConfig=n,this.typeFormatter=o,this.logic=f,this.currencyService=D,this.logicDisplay=j}getOptions(){let t={};this.field&&this.field.metadata&&null!==this.field.metadata.digits&&isFinite(this.field.metadata.digits)&&(t={digits:this.field.metadata.digits});const n=this.currencyService.isBase(this.field);let o=this.currencyService.getCurrencyId(this.record);return(n||null===o)&&(o=this.currencyService.getUserCurrency().id),t.symbol=this.currencyService.getSymbol(o),t.code=this.currencyService.getCode(o),t}getCurrencyValue(){return this.currencyService.getFieldCurrencyValue(this.field,this.record)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(ev),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-currency-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Ay,3,4,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe,u_],encapsulation:2})}return r})(),hS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Jm]})}return r})(),Oy=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}get rows(){return this.field.metadata&&this.field.metadata.rows?this.field.metadata.rows:6}get cols(){return this.field.metadata&&this.field.metadata.cols?this.field.metadata.cols:20}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-text-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[["readonly","",1,"detail-pre-styling"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"pre",0),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(o.field.value))},encapsulation:2})}return r})(),aw=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}ngOnInit(){super.ngOnInit(),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-varchar-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:5,consts:[["type","text",3,"formControl","value","ngClass"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"input",0),2&n&&(e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("formControl",o.field.formControl)("value",o.field.value)("ngClass",o.klass))},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})();class tg{constructor(v){this.hourStep=1,this.minuteStep=15,this.secondStep=30,this.displaySeconds=!1,Object.assign(this,v)}static toDateTimeStruct(v,t){if(!t)return null;const n=v.userDateTimeFormatToStruct(t);if(!n)return null;const{date:o,time:f}=n;return new tg({date:o,time:f})}static internalToDateTimeStruct(v,t){if(!t)return null;const n=v.internalDateTimeFormatToStruct(t);if(!n)return null;const{date:o,time:f}=n;return new tg({date:o,time:f})}toUserFormat(v,t){const f=[[this.date.year,this.date.month,this.date.day].join("-"),[this.time.hour,this.time.minute,this.time.second].join(":")].join(" "),D=v.toInternalFormat(f,{fromFormat:"yyyy-M-d H:m:s"});return v.toUserFormat(D,{...t,fromFormat:"yyyy-M-d H:m:s"})}}function rC(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div")(1,"div")(2,"ngb-datepicker",5),e.\u0275\u0275listener("dateSelect",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDateChange(o))}),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(3,"div",6)(4,"ngb-timepicker",7),e.\u0275\u0275listener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onTimeChange(o))}),e.\u0275\u0275elementEnd()()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngModel",t.dateTimeModel.date)("startDate",t.dateTimeModel.date),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngModel",t.dateTimeModel.time)("seconds",t.dateTimeModel.displaySeconds)("hourStep",t.dateTimeModel.hourStep)("minuteStep",t.dateTimeModel.minuteStep)("secondStep",t.dateTimeModel.secondStep)}}let yb=(()=>{class r extends nC{constructor(t,n,o,f,D,j){super(t,n,D,j),this.formatter=t,this.typeFormatter=n,this.calendar=o,this.config=f,this.logic=D,this.logicDisplay=j,this.dateTimeModel=new tg,f.autoClose="outside",f.placement=this.getPlacement()}ngOnInit(){if(Al(this.field.value)||Ud(this.field.value))this.dateTimeModel.date=this.calendar.getToday(),this.dateTimeModel.time={hour:0,minute:0,second:0},this.field.formControl.setValue(null);else{if(this.dateTimeModel=tg.internalToDateTimeStruct(this.formatter,this.field.value),null===this.dateTimeModel)return void this.field.formControl.setValue(null);this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter,{toFormat:this.getDateTimeFormat()}))}this.formatter.getTimeFormat().includes("ss")&&(this.dateTimeModel.displaySeconds=!0),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}setFormValues(t){this.field.formControl.setValue(t)}onDateChange(t){this.dateTimeModel.date=t,this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter,{toFormat:this.getDateTimeFormat()})),this.field.formControl.markAsDirty()}onTimeChange(t){this.dateTimeModel.time=t,this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter,{toFormat:this.getDateTimeFormat()})),this.field.formControl.markAsDirty()}onInputChange(t){const n=tg.toDateTimeStruct(this.formatter,t.target.value);n&&(this.dateTimeModel=n)}getOpenButton(){return{klass:"btn btn-sm btn-outline-secondary m-0 border-0",icon:"calendar"}}getPlacement(){return["bottom-right","top-right","bottom-left","top-left"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kh),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(ct.NgbCalendar),e.\u0275\u0275directiveInject(ct.NgbPopoverConfig),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-datetime-edit"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(ct.NgbPopover,7),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.popover=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:6,vars:8,consts:[["calendarContent",""],[1,"input-group","mr-2"],[3,"change","ngClass","placeholder","formControl","ngbPopover"],[1,"input-group-append"],[3,"config","ngbPopover"],["name","datepicker",3,"dateSelect","ngModel","startDate"],[1,"d-flex","justify-content-center","mt-auto"],["name","timepicker",3,"ngModelChange","ngModel","seconds","hourStep","minuteStep","secondStep"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"input",2),e.\u0275\u0275listener("change",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputChange(j))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(2,"div",3),e.\u0275\u0275element(3,"scrm-button",4),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(4,rC,5,7,"ng-template",null,0,e.\u0275\u0275templateRefExtractor)}if(2&n){const f=e.\u0275\u0275reference(5);e.\u0275\u0275advance(),e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("ngClass",o.klass)("placeholder",o.getDateTimeFormat().toLowerCase())("formControl",o.field.formControl)("ngbPopover",f),e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.getOpenButton())("ngbPopover",f)}},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,ct.NgbDatepicker,ct.NgbTimepicker,xc,Ji.FormControlDirective,ct.NgbPopover],encapsulation:2})}return r})(),lw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,ct.NgbDatepickerModule,ct.NgbTimepickerModule,Vl,Oa,Ji.ReactiveFormsModule,ct.NgbModule]})}return r})(),bb=(()=>{class r extends ct.NgbDateParserFormatter{constructor(t){super(),this.formatter=t}getUserFormat(){return this.userFormat}setUserFormat(t){this.userFormat=t}parse(t){if(!t)return null;const n={fromFormat:"yyyy-M-d"};return this.userFormat&&(n.toFormat=this.userFormat),this.formatter.dateFormatToStruct(t,n.toFormat||this.formatter.getUserFormat())}format(t){if(!t)return null;const n=[t.year,t.month,t.day].join("-"),o={fromFormat:"yyyy-M-d"};return this.userFormat&&(o.toFormat=this.userFormat),this.formatter.toUserFormat(n,o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(r_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),Cb=(()=>{class r extends ct.NgbDateAdapter{constructor(t){super(),this.formatter=t}getUserFormat(){return this.userFormat}setUserFormat(t){this.userFormat=t}fromModel(t){return t?this.formatter.dateFormatToStruct(t,this.userFormat||""):null}toModel(t){if(!t)return null;const n=[t.year,t.month,t.day].join("-"),o={fromFormat:"yyyy-M-d"};return this.userFormat&&(o.toFormat=this.userFormat),this.formatter.toUserFormat(n,o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(r_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),oC=(()=>{class r extends My{constructor(t,n,o,f,D,j){super(t,f,D,j),this.formatter=t,this.dateAdapter=n,this.dateParserFormatter=o,this.typeFormatter=f,this.logic=D,this.logicDisplay=j}ngOnInit(){Al(this.field.value)||Ud(this.field.value)?this.field.formControl.setValue(null):this.field.formControl.setValue(this.formatter.toUserFormat(this.field.value,{toFormat:this.getDateFormat()})),this.dateAdapter.setUserFormat(this.getDateFormat()),this.dateParserFormatter.setUserFormat(this.getDateFormat()),this.dateModel=this.formatter.dateFormatToStruct(this.field.value,this.formatter.getInternalFormat()),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}setModel(t){this.field.value=this.formatter.toInternalFormat(t,{fromFormat:this.getDateFormat()}),this.dateModel=this.formatter.dateFormatToStruct(t,this.getDateFormat())}getOpenButton(t){return{klass:"btn btn-sm btn-outline-secondary m-0 border-0",onClick:()=>{t.toggle(),t.navigateTo(this.dateModel)},icon:"calendar"}}openDatePicker(t){t.toggle(),t.navigateTo(this.dateModel)}getPlacement(){return["bottom-left","bottom-right","top-left","top-right"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(r_),e.\u0275\u0275directiveInject(ct.NgbDateAdapter),e.\u0275\u0275directiveInject(ct.NgbDateParserFormatter),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-date-edit"]],features:[e.\u0275\u0275ProvidersFeature([{provide:ct.NgbDateAdapter,useClass:Cb},{provide:ct.NgbDateParserFormatter,useClass:bb}]),e.\u0275\u0275InheritDefinitionFeature],decls:5,vars:8,consts:[["datepicker","ngbDatepicker"],[1,"field-datetime-edit","input-group"],["ngbDatepicker","",3,"ngModelChange","click","ngClass","placement","placeholder","formControl","startDate"],[1,"input-group-append","align-items-end"],[3,"config"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"input",2,0),e.\u0275\u0275listener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.setModel(j))})("click",function(){e.\u0275\u0275restoreView(f);const j=e.\u0275\u0275reference(2);return e.\u0275\u0275resetView(o.openDatePicker(j))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"span",3),e.\u0275\u0275element(4,"scrm-button",4),e.\u0275\u0275elementEnd()()}if(2&n){const f=e.\u0275\u0275reference(2);e.\u0275\u0275advance(),e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("ngClass",o.klass)("placement",o.getPlacement())("placeholder",o.getDateFormat().toLowerCase())("formControl",o.field.formControl)("startDate",o.dateModel),e.\u0275\u0275advance(3),e.\u0275\u0275property("config",o.getOpenButton(f))}},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,ct.NgbInputDatepicker,xc,Ji.FormControlDirective],encapsulation:2})}return r})(),ng=(()=>{class r extends oC{constructor(t,n,o,f,D,j){super(t,n,o,f,D,j),this.formatter=t,this.dateAdapter=n,this.dateParserFormatter=o,this.typeFormatter=f,this.logic=D,this.logicDisplay=j}ngOnInit(){let t=null;this.field.criteria.values&&this.field.criteria.values.length>0&&(t=this.field.criteria.values[0]),!Al(t)&&!Ud(t)&&(t=t.trim()),this.field.value=t??"",super.ngOnInit()}setFieldValue(t){super.setFieldValue(t),this.field.criteria.operator="=",this.field.criteria.values=[t]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(r_),e.\u0275\u0275directiveInject(ct.NgbDateAdapter),e.\u0275\u0275directiveInject(ct.NgbDateParserFormatter),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-date-filter"]],features:[e.\u0275\u0275ProvidersFeature([{provide:ct.NgbDateAdapter,useClass:Cb},{provide:ct.NgbDateParserFormatter,useClass:bb}]),e.\u0275\u0275InheritDefinitionFeature],decls:5,vars:8,consts:[["datepicker","ngbDatepicker"],[1,"input-group"],["ngbDatepicker","",3,"ngModelChange","ngClass","placement","placeholder","formControl","startDate"],[1,"input-group-append","align-items-end"],[3,"config"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"input",2,0),e.\u0275\u0275listener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.setModel(j))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"span",3),e.\u0275\u0275element(4,"scrm-button",4),e.\u0275\u0275elementEnd()()}if(2&n){const f=e.\u0275\u0275reference(2);e.\u0275\u0275advance(),e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("ngClass",o.klass)("placement",o.getPlacement())("placeholder",o.getDateFormat().toLowerCase())("formControl",o.field.formControl)("startDate",o.dateModel),e.\u0275\u0275advance(3),e.\u0275\u0275property("config",o.getOpenButton(f))}},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,ct.NgbInputDatepicker,xc,Ji.FormControlDirective],encapsulation:2})}return r})();function rT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"date"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind3(2,1,t.toDateTime(t.field.value),t.getDateTimeFormat(),t.getUserTimeZone())," ")}}function mS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,rT,3,5,"span",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field.value)}}let rv=(()=>{class r extends nC{constructor(t,n,o,f){super(t,n,o,f),this.formatter=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}getUserTimeZone(){return this.formatter.userTimeZone()}toDateTime(t){return this.formatter.toDateTime(t,this.formatter.getInternalFormat(),{zone:"GMT"}).toJSDate()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kh),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-datetime-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,mS,2,1,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe,ve.DatePipe],encapsulation:2})}return r})(),cw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();function $M(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div")(1,"div")(2,"ngb-datepicker",5),e.\u0275\u0275listener("dateSelect",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onDateChange(o))}),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(3,"div",6)(4,"ngb-timepicker",7),e.\u0275\u0275listener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onTimeChange(o))}),e.\u0275\u0275elementEnd()()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngModel",t.dateTimeModel.date)("startDate",t.dateTimeModel.date),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngModel",t.dateTimeModel.time)("seconds",t.dateTimeModel.displaySeconds)("hourStep",t.dateTimeModel.hourStep)("minuteStep",t.dateTimeModel.minuteStep)("secondStep",t.dateTimeModel.secondStep)}}let Db=(()=>{class r extends nC{constructor(t,n,o,f,D,j){super(t,n,D,j),this.formatter=t,this.typeFormatter=n,this.calendar=o,this.config=f,this.logic=D,this.logicDisplay=j,this.dateTimeModel=new tg,f.autoClose="outside",f.placement=this.getPlacement()}ngOnInit(){super.ngOnInit();let n="";if((this.field&&this.field.criteria&&this.field.criteria.values||[]).length>0&&(n=this.field.criteria.values[0]),Ud(n))this.dateTimeModel.date=this.calendar.getToday(),this.dateTimeModel.time={hour:0,minute:0,second:0},this.field.formControl.setValue(null);else{if(this.dateTimeModel=tg.internalToDateTimeStruct(this.formatter,n),null===this.dateTimeModel)return void this.field.formControl.setValue(null);this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter))}this.formatter.getTimeFormat().includes("ss")&&(this.dateTimeModel.displaySeconds=!0),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}setFormValues(t){this.field.formControl.setValue(t),this.field.formControl.markAsDirty()}setFieldValue(t){this.field.value=t,this.field.criteria.operator="=",this.field.criteria.values=[t]}onDateChange(t){this.dateTimeModel.date=t,this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter))}onTimeChange(t){this.dateTimeModel.time=t,this.setFormValues(this.dateTimeModel.toUserFormat(this.formatter))}onInputChange(t){const n=tg.toDateTimeStruct(this.formatter,t.target.value);n&&(this.dateTimeModel=n)}getOpenButton(){return{klass:"btn btn-sm btn-outline-secondary m-0 border-0",icon:"calendar"}}getPlacement(){return["bottom-right","top-right","bottom-left","top-left"]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kh),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(ct.NgbCalendar),e.\u0275\u0275directiveInject(ct.NgbPopoverConfig),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-datetime-filter"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(ct.NgbPopover,7),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.popover=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:6,vars:7,consts:[["calendarContent",""],[1,"input-group","mr-2"],[3,"change","ngClass","placeholder","formControl"],[1,"input-group-append"],[3,"config","ngbPopover"],["name","datepicker",3,"dateSelect","ngModel","startDate"],[1,"d-flex","justify-content-center","mt-auto"],["name","timepicker",3,"ngModelChange","ngModel","seconds","hourStep","minuteStep","secondStep"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"input",2),e.\u0275\u0275listener("change",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onInputChange(j))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(2,"div",3),e.\u0275\u0275element(3,"scrm-button",4),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(4,$M,5,7,"ng-template",null,0,e.\u0275\u0275templateRefExtractor)}if(2&n){const f=e.\u0275\u0275reference(5);e.\u0275\u0275advance(),e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("ngClass",o.klass)("placeholder",o.getDateTimeFormat().toLowerCase())("formControl",o.field.formControl),e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.getOpenButton())("ngbPopover",f)}},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,ct.NgbDatepicker,ct.NgbTimepicker,xc,Ji.FormControlDirective,ct.NgbPopover],encapsulation:2})}return r})(),sC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,ct.NgbDatepickerModule,ct.NgbTimepickerModule,Vl,Oa,Ji.ReactiveFormsModule,ct.NgbModule]})}return r})();function gS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.label)}}let d_=(()=>{class r extends J1{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-multienum-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[[4,"ngFor","ngForOf"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"ul"),e.\u0275\u0275template(1,gS,2,1,"li",0),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",o.selectedValues))},dependencies:[ve.NgForOf],encapsulation:2})}return r})();const aC=["tag"];let jp=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}ngOnInit(){this.checkAndInitAsDynamicEnum(),super.ngOnInit()}onAdd(t){if(t&&t.value)return this.field.value=t.value,this.field.formControl.setValue(t.value),void this.field.formControl.markAsDirty();this.field.value="",this.field.formControl.setValue(""),this.field.formControl.markAsDirty(),this.selectedValues=[]}onRemove(){this.field.value="",this.field.formControl.setValue(""),this.field.formControl.markAsDirty(),setTimeout(()=>{this.tag.focus(!0,!0),this.tag.dropdown.show()},200)}getPlaceholderLabel(){return this.languages.getAppString("LBL_SELECT_ITEM")||""}selectFirstElement(){const t=this.tag.dropdown.items;if(0!==t.length){const n=t[0];this.selectedValues.push(n),this.onAdd(n),this.tag.dropdown.hide()}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-enum-edit"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(aC,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.tag=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:15,consts:[["tag",""],["maxItems","1",3,"ngModelChange","onAdd","onRemove","keyup.enter","ngModel","onlyFromAutocomplete","clearOnBlur","displayBy","identifyBy","placeholder","secondaryPlaceholder","inputClass"],[3,"displayBy","identifyBy","showDropdownIfEmpty","keepOpen","autocompleteItems"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"tag-input",1,0),e.\u0275\u0275twoWayListener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.selectedValues,j)||(o.selectedValues=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275listener("onAdd",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onAdd(j))})("onRemove",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onRemove())})("keyup.enter",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.selectFirstElement())}),e.\u0275\u0275element(2,"tag-input-dropdown",2),e.\u0275\u0275elementEnd()}2&n&&(e.\u0275\u0275classMap(o.getInvalidClass()),e.\u0275\u0275twoWayProperty("ngModel",o.selectedValues),e.\u0275\u0275property("onlyFromAutocomplete",!0)("clearOnBlur",!0)("displayBy","label")("identifyBy","value")("placeholder",o.getPlaceholderLabel())("secondaryPlaceholder",o.getPlaceholderLabel())("inputClass",o.getInvalidClass()),e.\u0275\u0275advance(2),e.\u0275\u0275property("displayBy","label")("identifyBy","value")("showDropdownIfEmpty",!0)("keepOpen",!1)("autocompleteItems",o.options))},dependencies:[Ua.TagInputComponent,Ua.TagInputDropdown,Ji.NgControlStatus,Ji.NgModel],encapsulation:2})}return r})(),Fy=(()=>{class r extends lu{get checked(){return cl(this.field.value)}toggle(){let t="true";this.checked&&(t="false"),this.field.value=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty()}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})(),wb=(()=>{class r extends Fy{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-boolean-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:1,consts:[[1,"checkbox-container"],["type","checkbox","disabled","","readonly","","aria-hidden","true",3,"checked"],[1,"checkmark"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"label",0),e.\u0275\u0275element(1,"input",1)(2,"span",2),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("checked",o.checked))},encapsulation:2})}return r})(),Ac=(()=>{class r{constructor(t){this.systemConfig=t}toFrontend(t){const n=this.getLegacyToFrontendMap();return n&&n[t]?n[t]:t}toLegacy(t){const n=this.getFrontendToLegacyMap();return n[t]?n[t]:t}isValid(t){let o=!1;return this.getFrontendToLegacyMap()[t]&&(o=!0),o}getLegacyToFrontendMap(){return this.systemConfig.getConfigValue("module_name_map")}getFrontendToLegacyMap(){const t=this.systemConfig.getConfigValue("module_name_map"),n={};return Object.keys(t).forEach(o=>{n[t[o]]=o}),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Up=(()=>{class r{constructor(t){this.systemConfig=t}toFrontend(t){const n=this.getLegacyToFrontendMap();return n[t]?n[t]:t}toLegacy(t){const n=this.getFrontendToLegacyMap();return n[t]?n[t]:t}isValid(t){let o=!1;return this.getFrontendToLegacyMap()[t]&&(o=!0),o}getLegacyToFrontendMap(){return this.systemConfig.getConfigValue("action_name_map")}getFrontendToLegacyMap(){const t=this.systemConfig.getConfigValue("action_name_map"),n={};return Object.keys(t).forEach(o=>{n[t[o]]=o}),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Ny="./#";let Oc=(()=>{class r{constructor(t,n,o){this.router=t,this.moduleNameMapper=n,this.actionNameMapper=o}getModuleInfo(t,n){return n&&n.modules?n.modules[t]:null}getModuleLabel(t,n){if(!n||!n.moduleList||!t)return"";const o=t&&t.labelKey||"";return n.moduleList[o]||o}getModuleRoute(t){let n=t&&t.defaultRoute||"",o=null;return n.startsWith(Ny)&&(o=n.replace(Ny,""),n=null),{route:o,url:n,params:null}}navigate(t){const n=this.getActionRoute(t);return this.router.navigate([n.route],{queryParams:n.params})}navigateUsingMenuItem(t){t.link.route?this.router.navigate([t.link.route??""],{queryParams:t.link.params??{}}).then():t.link.url&&this.router.navigateByUrl(t.link.url??"").then()}getActionRoute(t){let n=t.url,o=null,f={},D=t?.process;if(n.startsWith(Ny))if(o=n.replace(Ny,""),n=null,t.params)f=t.params;else{const j=o.split("?");o=j[0];const fe=j[1],Ne={};fe&&fe.split("&").forEach(vt=>{const ln=vt.split("=");Ne[ln[0]]=ln[1]}),f=Ne}return{route:o,url:n,params:f,process:D}}getActionLabel(t,n,o,f=""){if(!(o&&o.modStrings&&n&&t))return"";let D=f;D||(D=n.labelKey);let j=o.modStrings[t]&&o.modStrings[t][D];return j||(j=o.appStrings&&o.appStrings[D]),!j&&n.module&&(j=o.modStrings[n.module]&&o.modStrings[n.module][D]),j||(j=o.modStrings.administration&&o.modStrings.administration[D]),j||""}getRecordRouterLink(t,n,o){return o?`/${t}/edit/${n}`:`/${t}/record/${n}`}navigateBack(t,n,o){let f=this.getReturnModule(o),D=this.getReturnAction(o);const j=this.getReturnId(o);let fe="";f&&(fe+="/"+f),D&&(fe+="/"+D),j&&(fe+="/"+j),f===n&&"record"===D&&(fe="/"+n+"/record/"+(j||t.id)),!fe&&t&&t.id&&(fe="/"+n+"/record/"+t.id),!fe&&t&&t.id&&(fe="/"+n),this.router.navigate([fe]).then()}getReturnId(t){return t.return_id||""}getReturnAction(t){let n="";return t.return_action&&(n=this.actionNameMapper.toFrontend(t.return_action)),n}getReturnModule(t){let n="";return t.return_module&&(n=this.moduleNameMapper.toFrontend(t.return_module)),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Up))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function oT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a",3),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275propertyInterpolate1("href","mailto:",t.field.value,"",e.\u0275\u0275sanitizeUrl),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.field.value)}}function MA(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"a",4),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.openEmail())}),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.field.value)}}let uw=(()=>{class r extends lu{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o,this.preferences=f,this.navigation=D,this.moduleNameMapper=j,this.actionNameMapper=fe,this.appState=Ne,this.modalService=vt,this.router=ln}ngOnInit(){this.linkType=this.preferences.getUserPreference("email_link_type")||"mailto"}openEmail(){const t=this.actionNameMapper.toLegacy(this.appState.getView()),n=this.moduleNameMapper.toLegacy(this.parent.module),o=this.parent.id;let j;"ListView"!==t&&"index"!==t&&(j=o),this.router.navigate(["emails","compose"],{queryParams:{return_module:n,return_action:t,return_id:j,to_addrs_names:this.field.value,parent_type:n,parent_name:this.parent.attributes.name,parent_id:o}})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(Up),e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Wo.Router))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-email-list"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[1,"mailto-field"],[3,"href",4,"ngIf"],["class","clickable field-link",3,"click",4,"ngIf"],[3,"href"],[1,"clickable","field-link",3,"click"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,oT,2,3,"a",1)(2,MA,2,1,"a",2),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","mailto"===o.linkType),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","sugar"===o.linkType))},dependencies:[ve.NgIf],encapsulation:2})}return r})(),sT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),dw=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}ngOnInit(){super.ngOnInit();let t="";this.field.criteria&&this.field.criteria.values&&this.field.criteria.values.length>0&&(t=this.field.criteria.values[0]),t=Al(t)?"":t.trim(),this.field.value=t;const n=this.typeFormatter.toUserFormat(this.field.type,t,{mode:"edit"});this.field.formControl.setValue(n),this.field.formControl.markAsDirty(),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}setFieldValue(t){this.field.value=t,this.field.criteria.operator="=",this.field.criteria.values=[t]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-varchar-filter"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:5,consts:[["type","text",3,"formControl","value","ngClass"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"input",0),2&n&&(e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("formControl",o.field.formControl)("value",o.field.value)("ngClass",o.klass))},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})();const IA=["currencyField"];let aT=(()=>{class r extends eg{constructor(t,n,o,f,D){super(t,n,o,f,D),this.userPreferences=t,this.systemConfig=n,this.typeFormatter=o,this.logic=f,this.logicDisplay=D}ngOnInit(){super.ngOnInit(),this.subscribeValueChanges(),this.value=this.typeFormatter.toUserFormat(this.field.type,this.field.value,this.getOptions())}getOptions(){return{mode:"edit"}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-currency-edit"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(IA,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.currencyField=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:5,consts:[["currencyField",""],["type","text",3,"ngModelChange","ngModel","formControl","ngClass"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"input",1,0),e.\u0275\u0275twoWayListener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.value,j)||(o.value=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275elementEnd()}2&n&&(e.\u0275\u0275classProp("is-invalid",o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275twoWayProperty("ngModel",o.value),e.\u0275\u0275property("formControl",o.field.formControl)("ngClass",o.klass))},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})(),WM=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ua.TagInputModule,Ji.FormsModule]})}return r})(),lC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})(),cC=(()=>{class r{getDownloadEntrypointLink(t,n){return"./index.php"+this.buildQueryString({entryPoint:"download",id:t,type:n})}buildQueryString(t,n=[]){let o=new Op.HttpParams;return Object.keys(t).forEach(f=>{n.includes(f)||(o=o.set(f,t[f]))}),o.keys().length>0?"?"+o.toString():""}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),uC=(()=>{class r extends lu{constructor(t,n,o,f){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o,this.legacyEntrypointLinkBuilder=f,this.filenameLink=""}ngOnInit(){this.filenameLink=this.legacyEntrypointLinkBuilder.getDownloadEntrypointLink(this.record.id,this.record.module)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject(cC))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-file-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[1,"clickable","field-link",3,"href"]],template:function(n,o){1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",0),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("href",o.filenameLink,e.\u0275\u0275sanitizeUrl),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",o.field.value," "))},encapsulation:2})}return r})(),xb=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Wo.RouterModule]})}return r})(),f_=(()=>{class r extends ve.DecimalPipe{constructor(t,n){super(n),this.formatter=t,this.locale=n}transform(t,n,o){return t?this.formatter.toUserFormat(""+t):null}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Qg,16),e.\u0275\u0275directiveInject(e.LOCALE_ID,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"formatNumber",type:r,pure:!0})}return r})();function vS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"formatNumber"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,t.field.value),"\n")}}let p_=(()=>{class r extends eg{constructor(t,n,o,f,D){super(t,n,o,f,D),this.userPreferences=t,this.systemConfig=n,this.typeFormatter=o,this.logic=f,this.logicDisplay=D}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-float-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,vS,3,3,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe,f_],encapsulation:2})}return r})(),fw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Sb=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fw]})}return r})(),_S=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule]})}return r})(),dC=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-relate-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.field.value,"\n")},encapsulation:2})}return r})(),Ry=(()=>{class r{getConfig(t){return{klass:"light-filter",panelMode:"collapsible",isCollapsed:!0,collapseOnSearch:!0,savedFilterEdit:!1,displayHeader:!0,module:t.recordList.getModule(),filter$:t.recordList.criteria$.pipe((0,M.map)(n=>({key:"default",criteria:n}))),savedFilters$:(0,i.of)([]),searchFields$:t.searchMetadata$.pipe((0,M.map)(n=>{if(!n)return{};let o="advanced";return n.layout.advanced||(o="basic"),n.layout[o]})),listFields:[],onClose:()=>{},onSearch:()=>{},updateFilter:(n,o=!0)=>{t.recordList.updateSearchCriteria(n.criteria,o)},resetFilter:n=>{t.recordList.resetSearchCriteria(n)},addSavedFilter:n=>{},removeSavedFilter:n=>{},setOpenFilter:n=>{}}}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();class yS{constructor(v,t){this.systemConfigs=v,this.preferences=t}getTable(v,t=!1){const n={showHeader:!0,showFooter:!0,klass:"light-table",module:v.recordList.getModule(),columns:v.columns$.pipe((0,M.map)(o=>this.mapColumns(v,o))),sort$:v.recordList.sort$,maxColumns$:(0,i.of)(5),loading$:v.recordList.loading$,dataSource:v.recordList,pagination:v.recordList,toggleRecordSelection:o=>{v.recordList.toggleSelection(o)},updateSorting:(o,f)=>{v.recordList.updateSorting(o,f),v.saveCurrentSort()},maxListHeight:this.preferences.getUserPreference("record_modal_max_height")??this.systemConfigs.getConfigValue("record_modal_max_height"),paginationType:this.preferences.getUserPreference("record_modal_pagination_type")??this.systemConfigs.getConfigValue("record_modal_pagination_type"),loadMore:()=>{const o=this.preferences.getUserPreference("list_max_entries_per_modal")??this.systemConfigs.getConfigValue("list_max_entries_per_modal"),f=v.recordList.getPagination(),j=Number(f.pageSize||0)+Number(o);v.recordList.setPageSize(j),v.recordList.updatePagination(f.current)},allLoaded:()=>{const o=v.recordList.getPagination();return!!o&&(Number(o.pageLast)>=Number(o.total)||Number(o.pageSize)>=Number(o.total))}};return t&&(n.selection$=v.recordList.selection$,n.selectedCount$=v.recordList.selectedCount$,n.selectedStatus$=v.recordList.selectedStatus$),n}mapColumns(v,t){const n=[];return t.forEach(o=>{const f={...o};f.metadata={...o.metadata||{}},this.disableRelateFieldsLink(f),this.addLinkSelectHandler(v,f),n.push(f)}),n}disableRelateFieldsLink(v){"relate"===v.type&&(v.link=!1,v.metadata.link=!1)}addLinkSelectHandler(v,t){t.link&&(t.metadata.onClick=(n,o)=>{v.recordList.clearSelection(),v.recordList.toggleSelection(o.id),v.emitLinkClicked()})}}let h_=(()=>{class r{constructor(t){this.apollo=t,this.fieldsMetadata={fields:["id","_id","meta","records"]}}fetch(t,n,o,f,D,j){const Ne={query:X.gql`
query recordList($module: String!, $limit: Int, $offset: Int, $criteria: Iterable, $sort: Iterable) {
recordList(module: $module, limit: $limit, offset: $offset, criteria: $criteria, sort: $sort) {
${j.fields.join("\n")}
}
}
`,variables:{module:t,limit:n,offset:o,criteria:f,sort:D}};return this.apollo.query(Ne)}get(t,n,o,f){const D=this.mapSort(o);return this.fetch(t,(0,wt.toInteger)(f.pageSize),(0,wt.toInteger)(f.current),n,D,this.fieldsMetadata).pipe((0,M.map)(({data:j})=>{const fe={records:[],pagination:{...f}};if(!j||!j.recordList)return fe;const Ne=j.recordList;if(Ne.records&&Ne.records.forEach(vt=>{fe.records.push(this.mapRecord(vt))}),!Ne.meta)return fe;if(Ne.meta.offsets){const vt={current:"current",next:"next",prev:"previous",total:"total",end:"last"};Object.keys(vt).forEach(ln=>{ln in Ne.meta.offsets&&(fe.pagination[vt[ln]]=Ne.meta.offsets[ln])})}return fe.meta=Ne.meta,fe}))}mapSort(t){return{sortOrder:{NONE:"",ASC:"ASC",DESC:"DESC"}[t.sortOrder],orderBy:t.orderBy}}mapRecord(t){return t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Ly={key:"default",module:"saved-search",attributes:{contents:""},criteria:{name:"default",filters:{}}},lT={default:dr(Ly)},ov={filters:{}},pw={orderBy:"",sortOrder:hp.DESC},hw={pageSize:5,current:0,previous:0,next:5,last:0,total:0,pageFirst:0,pageLast:0},m_={all:!1,status:Xu.NONE,selected:{},count:0},cT={module:"",records:[],criteria:dr(ov),activeFilters:dr(lT),sort:dr(pw),pagination:dr(hw),selection:dr(m_),openFilter:dr(Ly),loading:!1,meta:{}};let mw=(()=>{class r{constructor(t,n,o,f,D,j){this.listGQL=t,this.configStore=n,this.preferencesStore=o,this.languageStore=f,this.message=D,this.localStorageService=j,this.cache$=null,this.internalState=dr(cT),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subs=[],this.pageKey=null,this.records$=this.state$.pipe((0,M.map)(fe=>fe.records),(0,M.distinctUntilChanged)()),this.criteria$=this.state$.pipe((0,M.map)(fe=>fe.criteria),(0,M.distinctUntilChanged)()),this.sort$=this.state$.pipe((0,M.map)(fe=>fe.sort),(0,M.distinctUntilChanged)()),this.pagination$=this.state$.pipe((0,M.map)(fe=>fe.pagination),(0,M.distinctUntilChanged)()),this.selection$=this.state$.pipe((0,M.map)(fe=>fe.selection),(0,M.distinctUntilChanged)()),this.selectedCount$=this.state$.pipe((0,M.map)(fe=>fe.selection.count),(0,M.distinctUntilChanged)()),this.selectedStatus$=this.state$.pipe((0,M.map)(fe=>fe.selection.status),(0,M.distinctUntilChanged)()),this.activeFilters$=this.state$.pipe((0,M.map)(fe=>fe.activeFilters),(0,M.distinctUntilChanged)()),this.openFilter$=this.state$.pipe((0,M.map)(fe=>fe.openFilter),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(fe=>fe.loading))}connect(){return this.records$}disconnect(){}get criteria(){return dr(this.internalState.criteria?this.internalState.criteria:ov)}set criteria(t){this.updateState({...this.internalState,criteria:t})}get activeFilters(){return dr(this.internalState.activeFilters)}get sort(){return dr(this.internalState.sort?this.internalState.sort:pw)}set sort(t){this.updateState({...this.internalState,sort:t})}get pagination(){return dr(this.internalState.pagination?this.internalState.pagination:hw)}set pagination(t){this.updateState({...this.internalState,pagination:t})}get selection(){return dr(this.internalState.selection?this.internalState.selection:m_)}get records(){return this.internalState.records?this.internalState.records:[]}getModule(){return this.internalState.module}getRecord(t){let n=null;return this.records.some(o=>{if(o.id===t)return n=o,!0}),n}destroy(){this.clear()}init(t,n=!0,o="list_max_entries_per_page",f=dr(Ly),D=""){return this.internalState.module=t,this.preferenceKey=D,o&&this.watchPageSize(o),this.setBaseFilter(f),this.loadCurrentFilter(t),!1===n?null:this.load()}setBaseFilter(t){this.baseFilterMap={default:dr(t)},this.baseFilter=dr(t),this.updateState({...this.internalState,activeFilters:dr(this.baseFilterMap),openFilter:dr(this.baseFilter)})}loadCurrentFilter(t){const n=this.loadPreference(t,"current-filters")??this.baseFilterMap;if(!n||_a(n))return;let o=this.loadPreference(t,"current-sort");!o&&_a(o)&&(o=null),this.setFilters(n,!1,o)}setFilters(t,n=!0,o=null){const D=t[Object.keys(t).shift()];if(this.updateState({...this.internalState,activeFilters:dr(t),openFilter:dr(D)}),D.criteria){let j=D.criteria.orderBy??"",Ne=this.mapSortOrder(D.criteria.sortOrder??"desc");null!==o&&(j=o.orderBy,Ne=o.sortOrder),this.updateSorting(j,Ne,!1),this.updateSortLocalStorage(),this.updateSearchCriteria(D.criteria,n)}this.updateFilterLocalStorage()}updateFilterLocalStorage(){this.savePreference(this.internalState.module,"current-filters",this.internalState.activeFilters)}updateSortLocalStorage(){this.savePreference(this.internalState.module,"current-sort",this.sort)}updatePaginationLocalStorage(){null!==this.pageKey&&this.localStorageService.set(this.internalState.module+"-"+this.pageKey+"-current-pagination",this.pagination)}setLoading(t){this.updateState({...this.internalState,loading:t})}load(t=!0){return this.updateState({...this.internalState,loading:!0}),this.getRecords(this.internalState.module,this.internalState.criteria,this.internalState.sort,this.internalState.pagination,t).pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_GET_RECORD_LIST_ERROR"),(0,i.of)({records:[],criteria:dr(ov),sort:dr(pw),pagination:dr(hw),openFilter:dr(this.baseFilter),activeFilters:dr(this.baseFilterMap),selection:dr(m_),meta:{}}))),(0,M.tap)(n=>{this.calculatePageCount(n.records,n.pagination),this.updateState({...this.internalState,records:n.records,pagination:n.pagination,loading:!1,meta:n.meta??{}})}))}updateSearchCriteria(t,n=!0){this.updateState({...this.internalState,criteria:t}),n&&(this.updateSelection(Xu.NONE),this.resetPagination())}resetSearchCriteria(t=!0){this.updateSearchCriteria(dr(ov),t)}updateSorting(t,n,o=!0){n===hp.NONE&&(t="",n=hp.DESC),this.updateState({...this.internalState,sort:{orderBy:t,sortOrder:n}}),o&&this.load(!1).pipe((0,M.take)(1)).subscribe()}mapSortOrder(t){let n=hp.NONE;const o=t.toLowerCase();return"asc"===o?n=hp.ASC:"desc"===o&&(n=hp.DESC),n}updatePagination(t){const n={...this.internalState.pagination,current:t};this.updateState({...this.internalState,pagination:n}),this.load(!1).pipe((0,M.take)(1),(0,M.tap)(()=>this.updatePaginationLocalStorage())).subscribe()}setPagination(t){const n={...this.internalState.pagination,current:t};return this.updateState({...this.internalState,pagination:n}),this.load(!1).pipe((0,M.take)(1),(0,M.tap)(()=>this.updatePaginationLocalStorage()))}setOpenFilter(t){this.updateState({...this.internalState,openFilter:dr(t)})}resetFilters(t=!0){this.updateState({...this.internalState,activeFilters:dr(this.baseFilterMap),openFilter:dr(this.baseFilter)}),this.clearSort(),this.updateSortLocalStorage(),this.updateFilterLocalStorage(),this.updateSearchCriteria(this.baseFilter.criteria,t)}savePreference(t,n,o){const f=this.preferenceKey??null;if(!f)return null;this.preferencesStore.setUi(t,`${f}${n}`,o)}loadPreference(t,n){const o=this.preferenceKey??null;return o?this.preferencesStore.getUi(t,`${o}${n}`):null}resetPagination(){this.updatePagination(0)}clear(){this.cache$=null,this.store.unsubscribe(),this.preferencesSub.unsubscribe()}clearAuthBased(){this.clear()}getSelectionStatus(){return this.selectedStatus$}getSelectedCount(){return this.selectedCount$}updateSelection(t){t!==Xu.NONE?t!==Xu.ALL?t!==Xu.PAGE||this.selectPage():this.selectAll():this.clearSelection()}clearSelection(){this.updateState({...this.internalState,selection:dr(m_)})}clearSort(){this.updateState({...this.internalState,sort:dr(pw)})}selectAll(){this.updateState({...this.internalState,selection:{all:!0,status:Xu.ALL,selected:{},count:this.internalState.pagination.total}})}selectPage(){const t={...this.internalState.selection.selected};this.internalState.records&&this.internalState.records.length&&this.internalState.records.forEach(n=>{n&&n.id&&(t[n.id]=n.id)}),this.updateState({...this.internalState,selection:{all:!1,status:Xu.SOME,selected:t,count:Object.keys(t).length}})}toggleSelection(t){const n=dr(this.internalState.selection);n.selected[t]?delete n.selected[t]:n.selected[t]=t,n.count=Object.keys(n.selected).length,n.status=0===n.count?Xu.NONE:Xu.SOME,this.updateState({...this.internalState,selection:n})}getPaginationCount(){return this.pagination$.pipe((0,M.map)(t=>({pageFirst:t.pageFirst,pageLast:t.pageLast,total:t.total})),(0,M.distinctUntilChanged)())}getPagination(){return this.store.value.pagination}getMeta(){return this.store.value.meta}changePage(t){let n=0;const o={};if(o[eu.FIRST]=0,o[eu.PREVIOUS]=this.internalState.pagination.previous,o[eu.NEXT]=this.internalState.pagination.next,o[eu.LAST]=this.internalState.pagination.last,t in o&&o[t]>=0){if(n=o[t],Number(n)>this.internalState.pagination.last||n<0)return;this.updatePagination(n)}}setPage(t,n){let o=0;const f={};return f[eu.FIRST]=0,f[eu.PREVIOUS]=this.internalState.pagination.previous,f[eu.NEXT]=this.internalState.pagination.next,f[eu.LAST]=this.internalState.pagination.last,t in f&&f[t]>=0?(o=f[t],Number(o)>this.internalState.pagination.last||o<0?(0,i.of)({}):(n&&(o=0),this.setPagination(o))):(0,i.of)({})}setPageSize(t){const n={...this.internalState.pagination,pageSize:t};this.updateState({...this.internalState,pagination:n})}getPageSize(){return this?.internalState?.pagination?.pageSize??10}watchPageSize(t){const n=this.preferencesStore.getUserPreference(t),o=this.configStore.getConfigValue(t);this.determinePageSize(n,o),this.preferencesSub=this.configStore.configs$.pipe((0,i.combineLatestWith)(this.preferencesStore.userPreferences$),(0,M.tap)(([f,D])=>{this.determinePageSize(D&&D[t]||null,f&&f[t]&&f[t].value||null)})).subscribe()}determinePageSize(t,n){let o=20;t?o=t:n&&(o=parseInt(n,10)),this.setPageSize(o)}updateState(t){this.store.next(this.internalState=t)}calculatePageCount(t,n){const o=t&&t.length||0;let f=0,D=0;o>0&&(f=n.current+1,D=n.current+o),n.pageFirst=f,n.pageLast=D}getRecords(t,n,o,f,D=!0){return(null==this.cache$||!1===D)&&(this.cache$=this.listGQL.get(t,n,o,f).pipe((0,M.shareReplay)(1))),this.cache$}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(h_),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),$p=(()=>{class r{constructor(t,n,o,f,D,j){this.listGQL=t,this.configStore=n,this.preferencesStore=o,this.languageStore=f,this.message=D,this.localStorageService=j}create(){return new mw(this.listGQL,this.configStore,this.preferencesStore,this.languageStore,this.message,this.localStorageService)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(h_),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const ig={module:"",detailView:{},editView:{},listView:{},search:{},recordView:{},subPanel:{},massUpdate:{},recentlyViewed:[],favorites:[],fieldActions:{}},fC={};let pC=dr(ig),vm=dr(fC);const bS={};let sv=dr(bS),Fs=(()=>{class r{constructor(t,n){this.recordGQL=t,this.appState=n,this.typeKeys={listView:"listView",search:"search",recordView:"recordView",subPanel:"subPanel",massUpdate:"massUpdate",recentlyViewed:"recentlyViewed",favorites:"favorites"},this.store=new i.BehaviorSubject(pC),this.state$=this.store.asObservable(),this.allModuleStore=new i.BehaviorSubject(vm),this.allModulesState$=this.allModuleStore.asObservable(),this.resourceName="moduleMetadata",this.fieldsMetadata={fields:["id","_id"]},this.types=["listView","search","recordView","subPanel","massUpdate","recentlyViewed","favorites"],this.baseTypes=["listView","search","recordView","subPanel","favorites"],this.listViewColumns$=this.state$.pipe((0,M.map)(o=>o.listView.fields),(0,M.distinctUntilChanged)()),this.listViewLineActions$=this.state$.pipe((0,M.map)(o=>o.listView.lineActions),(0,M.distinctUntilChanged)()),this.listViewTableActions$=this.state$.pipe((0,M.map)(o=>o.listView.tableActions),(0,M.distinctUntilChanged)()),this.listMetadata$=this.state$.pipe((0,M.map)(o=>o.listView),(0,M.distinctUntilChanged)()),this.searchMetadata$=this.state$.pipe((0,M.map)(o=>o.search),(0,M.distinctUntilChanged)()),this.recordViewMetadata$=this.state$.pipe((0,M.map)(o=>o.recordView),(0,M.distinctUntilChanged)()),this.fieldActions$=this.state$.pipe((0,M.map)(o=>o.fieldActions),(0,M.distinctUntilChanged)()),this.subPanelMetadata$=this.state$.pipe((0,M.map)(o=>o.subPanel),(0,M.distinctUntilChanged)()),this.metadata$=this.state$,this.allModuleMetadata$=this.allModulesState$}clear(){sv=dr(bS),vm=dr(fC),this.updateState("",dr(ig))}clearAuthBased(){this.clear()}getMetadataTypes(){return this.types}getModule(){return pC.module}get(){return pC}getModuleMeta(t){return{...vm[t]??{}}}setModuleMetadata(t,n){sv[t]=(0,i.of)(n).pipe((0,M.shareReplay)(1)),this.updateAllModulesState(t,n)}reloadModuleMetadata(t,n,o=!0){return n||(n=this.getMetadataTypes()),this.getMetadata(t,n,o).pipe((0,M.tap)(f=>{this.updateAllModulesState(t,f)}))}load(t,n,o=!0){return n||(n=this.getMetadataTypes()),this.getMetadata(t,n,o).pipe((0,M.tap)(f=>{this.updateState(t,f)}))}isCached(t){return null!==(sv[t]??null)}getEmpty(){return dr(ig)}set(t,n){sv[t]=(0,i.of)(n).pipe((0,M.shareReplay)(1)),this.updateState(t,n)}getMetadata(t,n=null,o=!0){return(null==sv[t]||!1===o)&&(sv[t]=this.fetchMetadata(t,n).pipe((0,M.shareReplay)(1))),sv[t]}mapMetadata(t,n){const f={...vm[t]??{}};return this.parseListViewMetadata(n,f),this.parseSearchMetadata(n,f),this.parseRecordViewMetadata(n,f),this.parseSubPanelMetadata(n,f),this.parseMassUpdateMetadata(n,f),this.parseRecentlyViewedMetadata(n,f),this.parseFavoritesMetadata(n,f),this.parseFieldViewMetada(n,f),f}updateState(t,n){this.updateAllModulesState(t,n),this.store.next(pC={...n,module:t})}updateAllModulesState(t,n){if(""!==t){const o={...vm};o[t]={...n},this.allModuleStore.next(vm=o)}}fetchMetadata(t,n){const o={fields:[...this.fieldsMetadata.fields,...n??this.baseTypes]};return this.recordGQL.fetch(this.resourceName,`/api/module-metadata/${t}`,o).pipe((0,M.map)(({data:f})=>this.mapMetadata(t,f.moduleMetadata)))}parseListViewMetadata(t,n){if(!t||!t.listView)return;const o={fields:[],bulkActions:{},lineActions:[],tableActions:[],chartTypes:{},filters:[]};t.listView.columns&&t.listView.columns.forEach(D=>{o.fields.push(D)}),this.addDefinedMeta(o,t.listView,{bulkActions:"bulkActions",lineActions:"lineActions",tableActions:"tableActions",sidebarWidgets:"sidebarWidgets",availableFilters:"filters",paginationType:"paginationType"}),n.listView=o}parseFieldViewMetada(t,n){if(!t||!t.recordView||!t.recordView.panels)return;const o={recordView:{}};t.recordView.panels.forEach(f=>{f.rows&&f.rows.forEach(D=>{D.cols&&D.cols.forEach(j=>{j.fieldActions&&j.fieldActions.actions&&Object.values(j.fieldActions.actions).forEach(fe=>{fe.fieldName=j.name;const Ne=o.recordView[j.name]??[];Ne.push(fe),o.recordView[j.name]=Ne})})})}),n.fieldActions=o}parseSearchMetadata(t,n){t&&t.search&&(n.search=t.search)}parseSubPanelMetadata(t,n){t&&t.subPanel&&(n.subPanel=t.subPanel)}parseMassUpdateMetadata(t,n){t&&t.massUpdate&&(n.massUpdate=t.massUpdate)}parseRecordViewMetadata(t,n){if(!t||!t.recordView)return;const o={actions:[],templateMeta:{},panels:[]};this.addDefinedMeta(o,t.recordView,{templateMeta:"templateMeta",actions:"actions",panels:"panels",topWidget:"topWidget",sidebarWidgets:"sidebarWidgets",bottomWidgets:"bottomWidgets",summaryTemplates:"summaryTemplates",vardefs:"vardefs",metadata:"metadata"}),n.recordView=o}parseRecentlyViewedMetadata(t,n){t&&t.recentlyViewed&&(n.recentlyViewed=t.recentlyViewed)}parseFavoritesMetadata(t,n){t&&t.favorites&&(n.favorites=t.favorites)}addDefinedMeta(t,n,o){Object.keys(o).forEach(f=>{n[f]&&(t[o[f]]=n[f])})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t_),e.\u0275\u0275inject(tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ky=(()=>{class r{constructor(t,n,o){this.listStoreFactory=t,this.meta=n,this.preferences=o,this.module="",this.parentModule="",this.recordList=t.create(),this.loading$=this.recordList.loading$,this.metadataLoadingState=new i.BehaviorSubject(!1),this.linkClickedState=new i.BehaviorSubject(!1),this.linkClicked$=this.linkClickedState.asObservable(),this.metadataLoading$=this.metadataLoadingState.asObservable(),this.selection$=this.recordList.selection$,this.selectedCount$=this.recordList.selectedCount$,this.selectedStatus$=this.recordList.selectedStatus$}clear(){this.recordList.clear(),this.recordList=null}clearAuthBased(){this.recordList.clearAuthBased()}init(t,n=""){this.module=t,this.parentModule=n,this.loadCurrentSort(),this.metadataLoadingState.next(!0);const o=this.meta.getMetadata(t).pipe((0,M.tap)(()=>{this.metadataLoadingState.next(!1),this.recordList.load().pipe((0,M.take)(1)).subscribe()}));this.listMetadata$=o.pipe((0,M.map)(f=>f.listView)),this.searchMetadata$=o.pipe((0,M.map)(f=>f.search)),this.recordList.init(t,!1,"list_max_entries_per_modal"),this.columns$=this.listMetadata$.pipe((0,M.map)(f=>f.fields))}load(t=!0){return this.recordList.load(t)}loadCurrentSort(){if(!this.parentModule)return;const t=this.loadPreference(this.parentModule,"current-sort");!t||_a(t)||(this.recordList.sort=t)}saveCurrentSort(){this.parentModule&&this.savePreference(this.parentModule,"current-sort",this.recordList.sort)}emitLinkClicked(){this.linkClickedState.next(!0)}getPreferenceKey(t){return this.module+"-record-list-modal-"+t}savePreference(t,n,o){this.preferences.setUi(t,this.getPreferenceKey(n),o)}loadPreference(t,n){return this.preferences.getUi(t,this.getPreferenceKey(n))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),uT=(()=>{class r{constructor(t,n,o){this.listStoreFactory=t,this.metadataStore=n,this.preferences=o}create(){return new ky(this.listStoreFactory,this.metadataStore,this.preferences)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),rg=(()=>{class r{constructor(t,n){this.screenSize=t,this.systemConfigStore=n,this.screen=$d.Medium,this.maxColumns=5}getMaxColumns(t){return t.pipe((0,i.combineLatestWith)(this.screenSize.screenSize$),(0,M.map)(([n,o])=>(o&&(this.screen=o),this.calculateMaxColumns(n))),(0,M.distinctUntilChanged)())}calculateMaxColumns(t=!0){let n;if(n=this.systemConfigStore.getConfigValue("listview_column_limits"),n=t?n.with_sidebar:n.without_sidebar,this.screen&&n){const o=n[this.screen];o&&(this.maxColumns=o)}return this.maxColumns}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wd),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();function CS(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",3),e.\u0275\u0275elementContainerEnd())}function dT(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-list-filter",9),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",t.filterConfig)}}function HM(r,v){1&r&&e.\u0275\u0275element(0,"scrm-loading-spinner",11),2&r&&e.\u0275\u0275property("overlay",!0)}function hC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,HM,1,1,"scrm-loading-spinner",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t)}}function g_(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",9),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.buildSelectButton())}}function Eb(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div")(2,"div",4)(3,"div",5)(4,"div",6),e.\u0275\u0275template(5,dT,1,1,"scrm-list-filter",7),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",8)(7,"div",6),e.\u0275\u0275element(8,"scrm-table",9),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275template(9,hC,2,1,"ng-container",2),e.\u0275\u0275pipe(10,"async"),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(11,g_,2,1,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275property("ngIf",t.filterConfig),e.\u0275\u0275advance(3),e.\u0275\u0275property("config",t.tableConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(10,4,t.loading$)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.multiSelect)}}let Py=(()=>{class r{constructor(t,n,o,f,D,j){this.activeModal=t,this.storeFactory=n,this.languages=o,this.maxColumnCalculator=f,this.preferences=D,this.systemConfigs=j,this.titleKey="",this.multiSelect=!1,this.multiSelectButtonLabel="LBL_SAVE",this.adapter=null,this.filterAdapter=null,this.subs=[],this.store=this.storeFactory.create()}ngOnInit(){this.closeButton={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.activeModal.close({type:"close-button"})}},this.init()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}init(){this.module&&(this.initStore(),this.initTableAdapter(),this.initFilterAdapters())}getMaxColumns(){return this.maxColumnCalculator.getMaxColumns((0,i.of)(!0))}linkSelectedRecords(){this.activeModal.close({selection:this.store.recordList.selection,records:this.store.recordList.records})}buildSelectButton(){return{klass:["btn","btn-primary","btn-sm"],onClick:()=>{this.linkSelectedRecords()},labelKey:this.multiSelectButtonLabel}}initTableAdapter(){if(null===this.adapter&&(this.adapter=new yS(this.systemConfigs,this.preferences)),this.tableConfig=this.adapter.getTable(this.store,this.multiSelect),this.store?.listMetadata?.maxHeight&&(this.tableConfig.maxListHeight=this.store.listMetadata.maxHeight),!this.tableConfig?.maxListHeight){const t=this.systemConfigs.getConfigValue("ui")??{},n=this.systemConfigs.getConfigValue("record_modal_max_height")??"";this.tableConfig.maxListHeight=t.record_modal_max_height??n}this.tableConfig.maxColumns$=this.getMaxColumns()}initFilterAdapters(){null===this.filterAdapter&&(this.filterAdapter=new Ry),this.filterConfig=this.filterAdapter.getConfig(this.store)}initStore(){this.store.init(this.module,this.parentModule??""),this.loading$=this.store.metadataLoading$,this.subs.push(this.store.linkClicked$.pipe((0,M.distinctUntilChanged)(),(0,M.skip)(1)).subscribe(t=>{t&&this.linkSelectedRecords()}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ct.NgbActiveModal),e.\u0275\u0275directiveInject(uT),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(rg),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-list-modal"]],inputs:{titleKey:"titleKey",module:"module",parentModule:"parentModule",multiSelect:"multiSelect",multiSelectButtonLabel:"multiSelectButtonLabel",adapter:"adapter",filterAdapter:"filterAdapter"},features:[e.\u0275\u0275ProvidersFeature([rg])],decls:4,vars:5,consts:[["bodyKlass","m-0 small-font","footerKlass","border-0","headerKlass","border-0","klass","record-list-modal",3,"closable","close","title"],["modal-body",""],[4,"ngIf"],["labelKey","LBL_CONFIG_NO_CONFIG"],[1,"container-fluid"],[1,"row","pb-3"],[1,"col"],[3,"config",4,"ngIf"],[1,"row"],[3,"config"],[3,"overlay",4,"ngIf"],[3,"overlay"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-modal",0)(1,"div",1),e.\u0275\u0275template(2,CS,2,0,"ng-container",2)(3,Eb,12,6,"ng-container",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275property("closable",!0)("close",o.closeButton)("title",o.titleKey),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.tableConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.tableConfig))},encapsulation:2,data:{animation:[(0,sr.trigger)("modalFade",[(0,sr.transition)("void <=> *",[(0,sr.animate)("800ms")])])]}})}return r})(),$h=(()=>{class r{constructor(t){this.recordList=t.create()}init(t){this.recordList.init(t,!1)}search(t,n){const o=this.recordList.criteria;return o.filters[n]={field:n,operator:"=",values:[t]},this.recordList.updateSearchCriteria(o,!1),this.recordList.load(!1).pipe((0,M.map)(f=>f.records),(0,M.take)(1),(0,M.shareReplay)(1))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),DS=(()=>{class r extends lu{constructor(t,n,o,f,D,j){super(n,D,j),this.languages=t,this.typeFormatter=n,this.relateService=o,this.moduleNameMapper=f,this.logic=D,this.logicDisplay=j,this.selectedValues=[],this.options=[],this.status="",this.initModule="",this.search=fe=>""===fe?(0,i.of)([]):(this.status="searching",this.relateService.search(fe,this.getRelateFieldName()).pipe((0,M.tap)(()=>this.status="found"),(0,M.catchError)(()=>(this.status="error",(0,i.of)([]))),(0,M.map)(Ne=>{if(!Ne||Ne.length<1)return this.status="not-found",[];const vt=[];return Ne.forEach(ln=>{ln&&ln.attributes&&vt.push(ln.attributes)}),this.status="",vt})))}get module(){return this.record&&this.record.module?this.record.module:null}ngOnInit(){super.ngOnInit(),this.init(),this.subs.push(this.field.valueChanges$.subscribe(()=>{this.onModuleChange()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}onModuleChange(){const t=this.initModule,n=this?.field?.definition?.module??"";t!==n&&(this.initModule=n,""===t&&t!==n&&this.init(),""===n?this.status="no-module":(this.init(),this.status="",this.selectedValues=[],this.options=[]))}getRelateFieldName(){return this.field?.definition?.metadata?.relateSearchField?this.field.definition.metadata.relateSearchField:this.field&&this.field.definition&&this.field.definition.rname||"name"}getRelateIdField(){return this.field&&this.field.definition&&this.field.definition.id_name||""}getRelatedModule(){const t=this.field&&this.field.definition&&this.field.definition.module||"";return t?this.moduleNameMapper.toFrontend(t):""}getMessage(){const t={searching:"LBL_SEARCHING","not-found":"LBL_NOT_FOUND",error:"LBL_SEARCH_ERROR",found:"LBL_FOUND","no-module":"LBL_NO_MODULE_SELECTED"};return t[this.status]?t[this.status]:""}getInvalidClass(){return(this.validateOnlyOnSubmit?this.isInvalid():this.field.formControl.invalid&&this.field.formControl.touched)||this.hasSearchError()?"is-invalid":""}hasSearchError(){return"error"===this.status||"not-found"===this.status}resetStatus(){this.status=""}getPlaceholderLabel(){return this.languages.getAppString("LBL_TYPE_TO_SEARCH")||""}init(){this.initModule=this?.field?.definition?.module??"",this.relateService&&this.relateService.init(this.getRelatedModule())}buildRelate(t,n){const o={id:t};return this.getRelateFieldName()&&(o[this.getRelateFieldName()]=n),o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject($h),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();const Tb=["tag"],gw=["dropdownFilterInput"];function wS(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",9)}function xS(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",10),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementStart(1,"input",11,1),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.filterValue,o)||(f.filterValue=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275listener("keyup",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onFilterInput(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"scrm-image",12),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275twoWayProperty("ngModel",t.filterValue)}}function fT(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",4)(2,"p-dropdown",5,0),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275twoWayBindingSet(f.selectedValue,o)||(f.selectedValue=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275listener("onChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onAdd(o.value))})("onLazyLoad",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onFilter())})("onShow",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.focusFilterInput())})("onHide",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275reference(3),f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.resetFunction(o.options))})("onClear",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onClear(o))}),e.\u0275\u0275template(4,wS,1,0,"ng-template",6)(5,xS,4,1,"ng-template",7),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div"),e.\u0275\u0275element(7,"scrm-button",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("options",t.options),e.\u0275\u0275twoWayProperty("ngModel",t.selectedValue),e.\u0275\u0275property("optionLabel",t.getRelateFieldName())("emptyMessage",t.emptyFilterLabel)("emptyFilterMessage",t.emptyFilterLabel)("placeholder",t.placeholderLabel)("autoOptionFocus",!1)("autofocusFilter",!1)("focusOnHover",!0)("filter",!0)("lazy",!0)("dataKey","id")("filterBy",t.getRelateFieldName())("showClear",!0)("styleClass","w-100 "+t.getInvalidClass()),e.\u0275\u0275advance(5),e.\u0275\u0275property("config",t.selectButton)}}let v_=(()=>{class r extends DS{constructor(t,n,o,f,D,j,fe){super(t,n,o,f,j,fe),this.languages=t,this.typeFormatter=n,this.relateService=o,this.moduleNameMapper=f,this.modalService=D,this.logic=j,this.logicDisplay=fe,this.selectedValue={},this.placeholderLabel="",this.emptyFilterLabel="",this.filterValue=""}ngOnInit(){super.ngOnInit(),this.init(),this.getTranslatedLabels(),this.selectButton={klass:["btn","btn-sm","btn-outline-secondary","m-0","border-0"],onClick:()=>{this.showSelectModal()},icon:"cursor"}}init(){super.init(),this.initValue();const t=this.getRelateIdField();t&&this.record&&this.record.fields&&this.record.fields[t]&&(this.idField=this.record.fields[t])}initValue(){return this.field.valueObject&&this.field.valueObject.id?(this.field?.metadata?.relateSearchField&&(this.field.valueObject[this.field.metadata.relateSearchField]=this.field.valueObject[this.field?.definition?.rname??"name"]),this.selectedValue=this.field.valueObject,void(this.options=[this.field.valueObject])):(this.selectedValue={},void this.field.formControl.setValue(""))}onAdd(t){if(t){const n=this.getRelateFieldName();this.setValue(t.id,t[n])}else this.setValue("",""),this.selectedValue={}}onRemove(){this.setValue("",""),this.selectedValue={},this.options=[]}onClear(t){this.selectedValue={},this.filterValue="",this.options=[],this.onRemove()}onFilter(){const t=this.getRelateFieldName();this.filterValue=this.filterValue??"";const n=this.filterValue.match(/^\s*$/g);n&&n.length&&(this.filterValue=""),this.search(this.filterValue).pipe((0,M.take)(1),(0,M.map)(f=>f.filter(D=>""!==D[t])),(0,M.map)(f=>f.map(D=>({id:D.id,[t]:D[t]})))).subscribe(f=>{if(this.options=f,!this?.selectedValue||!this?.selectedValue?.id)return;let D=!1;f.some(j=>j?.id===this.selectedValue.id&&(D=!0,!0)),!1===D&&this.selectedValue&&this.options.push(this.selectedValue)})}resetFunction(t){this.filterValue="",this.options=[],_a(this.selectedValue)||(this.options=[this.selectedValue])}onFilterInput(t){t.stopPropagation(),this.tag.onLazyLoad.emit()}setValue(t,n){const o=this.buildRelate(t,n);if(this.field.value=n,this.field.valueObject=o,this.field.formControl.setValue(n),this.field.formControl.markAsDirty(),this.idField&&(this.idField.value=t,this.idField.formControl.setValue(t),this.idField.formControl.markAsDirty()),n){const f=this.getRelateFieldName();this.selectedValue={id:t,[f]:n}}this.options=[this.selectedValue]}showSelectModal(){const t=this.modalService.open(Py,{size:"xl",scrollable:!0});t.componentInstance.module=this.getRelatedModule(),t.result.then(n=>{if(!n||!n.selection||!n.selection.selected)return;const o=this.getSelectedRecord(n);this.setItem(o)})}getSelectedRecord(t){let n="";Object.keys(t.selection.selected).some(f=>(n=f,!0));let o=null;return t.records.some(f=>{if(f&&f.id===n)return o=f,!0}),o}setItem(t){this.tag.writeValue(t.attributes),this.onAdd(t.attributes)}getTranslatedLabels(){this.placeholderLabel=this.languages.getAppString("LBL_SELECT_ITEM")||"",this.emptyFilterLabel=this.languages.getAppString("ERR_SEARCH_NO_RESULTS")||""}focusFilterInput(){this.dropdownFilterInput.nativeElement.focus()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject($h),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-relate-edit"]],viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(Tb,5),e.\u0275\u0275viewQuery(gw,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.tag=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.dropdownFilterInput=f.first)}},features:[e.\u0275\u0275ProvidersFeature([$h]),e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[["tag",""],["dropdownFilterInput",""],[1,"d-flex","align-items-center"],[4,"ngIf"],[1,"flex-grow-1","w-100","mr-1"],[3,"ngModelChange","onChange","onLazyLoad","onShow","onHide","onClear","options","ngModel","optionLabel","emptyMessage","emptyFilterMessage","placeholder","autoOptionFocus","autofocusFilter","focusOnHover","filter","lazy","dataKey","filterBy","showClear","styleClass"],["pTemplate","dropdownicon"],["pTemplate","filter"],[3,"config"],["image","down_carret"],[1,"p-dropdown-filter-container",3,"click"],["type","text","pInputText","","autocomplete","off","tabindex","0",1,"p-dropdown-filter","p-component",3,"ngModelChange","keyup","ngModel"],["image","search",1,"p-element","p-dropdown-filter-search-icon"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275template(1,fT,8,16,"ng-container",3),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.initModule))},dependencies:[ve.NgIf,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,xc,Zc,Bl,Z_,Og],encapsulation:2})}return r})(),SS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea,Ji.FormsModule,Oa,mr,Vl,Ag,ah]})}return r})();const pT=["tag"],vw=["dropdownFilterInput"];function _w(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",10)}function hT(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",11)}function Mb(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",11)}function ES(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",12),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementStart(1,"div",13),e.\u0275\u0275element(2,"input",14),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",15),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.onSelectAll())}),e.\u0275\u0275template(4,Mb,1,0,"scrm-image",16),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(5,"div",17),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementStart(6,"input",18,1),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.filterValue,o)||(f.filterValue=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275listener("keyup",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onFilterInput(o))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(8,"span",19),e.\u0275\u0275element(9,"scrm-image",20),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.selectAll),e.\u0275\u0275advance(2),e.\u0275\u0275twoWayProperty("ngModel",t.filterValue)}}function mT(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",4)(2,"p-multiSelect",5,0),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275twoWayBindingSet(f.selectedValues,o)||(f.selectedValues=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275listener("onChange",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onAdd())})("onLazyLoad",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onFilter())})("onRemove",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onRemove())})("onPanelShow",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onPanelShow())})("onPanelHide",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.resetFunction())})("onClear",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onClear())}),e.\u0275\u0275template(4,_w,1,0,"ng-template",6)(5,hT,1,0,"ng-template",7)(6,ES,10,2,"ng-template",8),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(7,"div"),e.\u0275\u0275element(8,"scrm-button",9),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("options",t.options),e.\u0275\u0275twoWayProperty("ngModel",t.selectedValues),e.\u0275\u0275property("optionLabel",t.getRelateFieldName())("placeholder",t.placeholderLabel)("selectedItemsLabel","{0} "+t.selectedItemsLabel)("emptyFilterMessage",t.emptyFilterLabel)("emptyMessage",t.emptyFilterLabel)("maxSelectedLabels",t.maxSelectedLabels)("styleClass","w-100 "+t.getInvalidClass())("showToggleAll",!0)("selectAll",t.selectAll)("autoOptionFocus",!1)("autofocusFilter",!1)("focusOnHover",!0)("showClear",!0)("filter",!0)("lazy",!0)("dataKey","id")("filterBy",t.getRelateFieldName()),e.\u0275\u0275advance(6),e.\u0275\u0275property("config",t.selectButton)}}let Ib=(()=>{class r extends DS{constructor(t,n,o,f,D,j,fe){super(t,n,o,f,j,fe),this.languages=t,this.typeFormatter=n,this.relateService=o,this.moduleNameMapper=f,this.modalService=D,this.logic=j,this.logicDisplay=fe,this.placeholderLabel="",this.selectedItemsLabel="",this.emptyFilterLabel="",this.maxSelectedLabels=20,this.selectAll=!1,this.filterValue="",this.selectButton={klass:["btn","btn-sm","btn-outline-secondary","m-0","border-0"],onClick:()=>{this.showSelectModal()},icon:"cursor"}}ngOnInit(){this.selectAll=!1;const t=this.record;this.field.valueList=[],this.field.valueObjectArray=[];let n=this.field&&this.field.criteria&&this.field.criteria.values||[];n=n.filter(D=>!D),n.length>0&&(this.field.valueList=n);let o=this.field&&this.field.criteria&&this.field.criteria.valueObjectArray||[];o=o.map(D=>{const j={...D};return j[this.getRelateFieldName()]=D[this.getRelateFieldName()]??D?.name??"",j}),o.length>0&&(this.field.valueObjectArray=dr(o),this.selectedValues=dr(o)),super.ngOnInit(),this.options=this.options??[],this.getTranslatedLabels(),this.addCurrentlySelectedToOptions(this.options??[]);const f=this.getRelateIdField();if(f&&t&&t.criteriaFields&&t.criteriaFields[f]){this.idField=t.criteriaFields[f],this.idField.valueList=[];let D=this.idField&&this.idField.criteria&&this.idField.criteria.values||[];D=D.filter(j=>!!j),D.length>0&&(this.idField.valueList=dr(D))}}onAdd(){this.updateFieldValues(),this.calculateSelectAll()}onRemove(){this.updateFieldValues(),this.calculateSelectAll()}onClear(){this.options=[],this.selectedValues=[],this.selectAll=!1,this.filterValue="",this.onRemove()}onSelectAll(){this.selectAll=!this.selectAll,this.selectAll?(this.selectedValues=this.tag.visibleOptions()&&this.tag.visibleOptions().length?this.tag.visibleOptions():this.options,this.onAdd()):(this.selectedValues=[],this.onRemove())}getTranslatedLabels(){this.placeholderLabel=this.languages.getAppString("LBL_SELECT_ITEM")||"",this.selectedItemsLabel=this.languages.getAppString("LBL_ITEMS_SELECTED")||"",this.emptyFilterLabel=this.languages.getAppString("ERR_SEARCH_NO_RESULTS")||""}onPanelShow(){this.dropdownFilterInput.nativeElement.focus(),this.calculateSelectAll()}resetFunction(){this.filterValue="",this.options=this.selectedValues}onFilterInput(t){t?.stopPropagation(),this.selectAll=!1,this.tag.onLazyLoad.emit()}onFilter(){const t=this.getRelateFieldName();this.filterValue=this.filterValue??"";const n=this.filterValue.match(/^\s*$/g);n&&n.length&&(this.filterValue=""),this.search(this.filterValue).pipe((0,M.take)(1),(0,M.map)(f=>f.filter(D=>""!==D[t])),(0,M.map)(f=>f.map(D=>({id:D.id,[t]:D[t]})))).subscribe(f=>{this.options=f,this.addCurrentlySelectedToOptions(f),this.calculateSelectAll()})}updateFieldValues(){let t=this?.selectedValues?.map(n=>n[this.getRelateFieldName()])??null;t||(t=[]),this.field.valueList=t,this.field.valueObjectArray=dr(this.selectedValues??[]),this.updateSearchCriteria(this.field),this.field.criteria.valueObjectArray=dr(this.field.valueObjectArray),this.updateIdField()}updateIdField(){this.idField&&(this.idField.valueList=this?.selectedValues?.map(t=>t.id)??[],this.updateSearchCriteria(this.idField))}setValue(t){const n=this.getRelateFieldName(),o=t?.id??"",f=t[n];if(this.idField&&this.idField.valueList.includes(o)||!this.idField&&this.field.valueList.includes(f))return;const D={};D.id=o,D[n]=f,this.field.valueObjectArray.push(D),this.field.valueList.push(f),this.idField&&(this.idField.valueList.push(o),this.updateSearchCriteria(this.idField)),this.updateSearchCriteria(this.field),this.field.criteria.valueObjectArray||(this.field.criteria.valueObjectArray=[]),this.field.criteria.valueObjectArray.push(D)}updateSearchCriteria(t){t.criteria.operator="=",t.criteria.values=t.valueList,t.formControl.setValue(t.valueList),t.formControl.markAsDirty()}showSelectModal(){const t=this.modalService.open(Py,{size:"xl",scrollable:!0});t.componentInstance.module=this.getRelatedModule(),t.result.then(n=>{if(!n||!n.selection||!n.selection.selected)return;const o=this.getSelectedRecord(n);this.field.valueObjectArray.find(D=>D.id===o.id)||(this.setItem(o),this.tag.updateModel(this.selectedValues))})}getSelectedRecord(t){let n="";Object.keys(t.selection.selected).some(f=>(n=f,!0));let o=null;return t.records.some(f=>{if(f&&f.id===n)return o=f,!0}),o}setItem(t){const n=this.getRelateFieldName(),o={id:t?.attributes?.id,[n]:t?.attributes[n]};this.isInList(this.selectedValues,o)||(this.selectedValues.push(o),this.addCurrentlySelectedToOptions(this.options),this.onAdd())}addCurrentlySelectedToOptions(t){!this?.selectedValues||!this?.selectedValues.length||this.selectedValues.forEach(n=>{!1===this.isInList(t,n)&&n&&this.options.push(n)})}isInList(t,n){let o=!1;return t.some(f=>f?.id===n?.id&&(o=!0,!0)),o}calculateSelectAll(){const t=this?.tag?.visibleOptions()??[],n=(this?.selectedValues??[]).map(o=>o.value);this.selectAll=!(!t.length||!n.length)&&!(t.length>n.length)&&t.every(o=>n.includes(o.value))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject($h),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-relate-filter"]],viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(pT,5),e.\u0275\u0275viewQuery(vw,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.tag=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.dropdownFilterInput=f.first)}},features:[e.\u0275\u0275ProvidersFeature([$h]),e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[["tag",""],["dropdownFilterInput",""],[1,"d-flex","align-items-center"],[4,"ngIf"],[1,"flex-grow-1","w-100","mr-1"],[3,"ngModelChange","onChange","onLazyLoad","onRemove","onPanelShow","onPanelHide","onClear","options","ngModel","optionLabel","placeholder","selectedItemsLabel","emptyFilterMessage","emptyMessage","maxSelectedLabels","styleClass","showToggleAll","selectAll","autoOptionFocus","autofocusFilter","focusOnHover","showClear","filter","lazy","dataKey","filterBy"],["pTemplate","dropdownicon"],["pTemplate","checkicon"],["pTemplate","filter"],[3,"config"],["image","down_carret"],["image","checkbox_cross"],[1,"p-checkbox","p-component",3,"click"],["data-p-hidden-accessible","true",1,"p-hidden-accessible"],["type","checkbox","checked","false","aria-label","All items unselected"],["role","checkbox","aria-checked","false",1,"p-checkbox-box",3,"click"],["image","checkbox_cross",4,"ngIf"],[1,"p-multiselect-filter-container",3,"click"],["type","text","pInputText","","autocomplete","off","tabindex","0",1,"p-multiselect-filter","p-inputtext","p-component",3,"ngModelChange","keyup","ngModel"],[1,"p-multiselect-filter-icon"],["image","search",1,"p-element","p-dropdown-filter-search-icon"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275template(1,mT,9,20,"ng-container",3),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.initModule))},dependencies:[ve.NgIf,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,xc,Bl,M0,Zc,Og],encapsulation:2})}return r})(),yw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})(),TS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),gT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,ct.NgbDatepickerModule,Oa,Ji.ReactiveFormsModule]})}return r})(),Ab=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule,Ua.TagInputModule,Vl,mr,Tu,Oa,ah]})}return r})(),Ob=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),MS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ua.TagInputModule,Ea,Ji.FormsModule,gy,Oa,Vl,mr,Tu,Ag,ah]})}return r})(),By=(()=>{class r extends Fy{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-boolean-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:4,vars:1,consts:[[1,"pb-4","checkbox-field"],[1,"checkbox-container"],["type","checkbox","aria-hidden","true",3,"change","checked"],[1,"checkmark"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"label",1)(2,"input",2),e.\u0275\u0275listener("change",function(){return o.toggle()}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"span",3),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275property("checked",o.checked))},encapsulation:2})}return r})(),vT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),__=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule,Ea]})}return r})(),og=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),mC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();const bw=["multiSelect"];function Cw(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",6)}function y_(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",7)}function _T(r,v){1&r&&e.\u0275\u0275element(0,"scrm-image",8)}let Vy=(()=>{class r extends J1{constructor(t,n,o,f,D,j,fe){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f,this.screenSize=D,this.systemConfigStore=j,this.primengConfig=fe,this.placeholderLabel="",this.selectedItemsLabel="",this.emptyFilterLabel="",this.maxSelectedLabels=20,this.selectAll=!1}ngOnInit(){this.checkAndInitAsDynamicEnum(),this.getTranslatedLabels(),super.ngOnInit();const t=this.systemConfigStore.getUi("multiselect_max_number");this.screenSize.screenSize$.pipe((0,M.take)(1)).subscribe(n=>{this.maxSelectedLabels=t[n]||this.maxSelectedLabels}),this.primengConfig.ripple=!0,this.clearButton={klass:["btn","btn-sm","btn-outline-secondary","m-0","border-0"],onClick:n=>{this.onRemove()},icon:"cross"}}onAdd(){const t=this.selectedValues.map(n=>n.value);this.field.valueList=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty(),this.calculateSelectAll()}onSelectAll(t){this.selectAll=t.checked,this.selectAll?(this.selectedValues=this.multiSelect.visibleOptions()&&this.multiSelect.visibleOptions().length?this.multiSelect.visibleOptions():this.options,this.onAdd()):(this.selectedValues=[],this.onRemove())}onRemove(){const t=this.selectedValues.map(n=>n.value);this.field.valueList=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty(),this.calculateSelectAll()}onClear(){this.selectedValues=[],this.multiSelect.filterValue="",this.onRemove()}onPanelShow(){this.multiSelect.filterInputChild.nativeElement.focus(),this.multiSelect.filterValue="",this.calculateSelectAll()}onFilter(){this.calculateSelectAll()}getTranslatedLabels(){this.placeholderLabel=this.languages.getAppString("LBL_SELECT_ITEM")||"",this.selectedItemsLabel=this.languages.getAppString("LBL_ITEMS_SELECTED")||"",this.emptyFilterLabel=this.languages.getAppString("ERR_SEARCH_NO_RESULTS")||""}calculateSelectAll(){const t=this?.multiSelect?.visibleOptions()??[],n=(this?.selectedValues??[]).map(o=>o.value);this.selectAll=!(!t.length||!n.length)&&!(t.length>n.length)&&t.every(o=>n.includes(o.value))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(mf))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-multienum-edit"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(bw,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.multiSelect=f.first)}},features:[e.\u0275\u0275InheritDefinitionFeature],decls:6,vars:14,consts:[["multiSelect",""],[1,"d-flex","align-items-center"],[3,"ngModelChange","onChange","onSelectAllChange","onRemove","onPanelShow","onFilter","onClear","options","ngModel","optionLabel","placeholder","selectedItemsLabel","emptyFilterMessage","maxSelectedLabels","styleClass","showToggleAll","selectAll","autoOptionFocus","autofocusFilter","showClear","focusOnHover"],["pTemplate","dropdownicon"],["pTemplate","filtericon"],["pTemplate","checkicon"],["image","down_carret"],["image","search"],["image","checkbox_cross"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",1)(1,"p-multiSelect",2,0),e.\u0275\u0275twoWayListener("ngModelChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275twoWayBindingSet(o.selectedValues,j)||(o.selectedValues=j),e.\u0275\u0275resetView(j)}),e.\u0275\u0275listener("onChange",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onAdd())})("onSelectAllChange",function(j){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onSelectAll(j))})("onRemove",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onRemove())})("onPanelShow",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onPanelShow())})("onFilter",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onFilter())})("onClear",function(){return e.\u0275\u0275restoreView(f),e.\u0275\u0275resetView(o.onClear())}),e.\u0275\u0275template(3,Cw,1,0,"ng-template",3)(4,y_,1,0,"ng-template",4)(5,_T,1,0,"ng-template",5),e.\u0275\u0275elementEnd()()}2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("options",o.options),e.\u0275\u0275twoWayProperty("ngModel",o.selectedValues),e.\u0275\u0275property("optionLabel","label")("placeholder",o.placeholderLabel)("selectedItemsLabel","{0} "+o.selectedItemsLabel)("emptyFilterMessage",o.emptyFilterLabel)("maxSelectedLabels",o.maxSelectedLabels)("styleClass","w-100 "+o.getInvalidClass())("showToggleAll",!0)("selectAll",o.selectAll)("autoOptionFocus",!1)("autofocusFilter",!0)("showClear",!0)("focusOnHover",!0))},dependencies:[Ji.NgControlStatus,Ji.NgModel,M0,Zc,Bl],encapsulation:2})}return r})();function yT(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.field.value)}}function bT(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"formatNumber"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,t.field.value),"\n")}}let jy=(()=>{class r extends eg{constructor(t,n,o,f,D){super(t,n,o,f,D),this.userPreferences=t,this.systemConfig=n,this.typeFormatter=o,this.logic=f,this.logicDisplay=D}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-int-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:4,consts:[[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,yT,2,1,"ng-container",0)(1,bT,3,3,"ng-container",0),e.\u0275\u0275pipe(2,"async")),2&n&&(e.\u0275\u0275property("ngIf",!o.format),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.format&&e.\u0275\u0275pipeBind1(2,2,o.vm$)))},dependencies:[ve.NgIf,ve.AsyncPipe,f_],encapsulation:2})}return r})(),Dw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,mr,Oa,Ag,Vl,ah]})}return r})(),ww=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fw]})}return r})(),Uy=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}ngOnInit(){this.field.value="",this.field.criteria.values&&this.field.criteria.values.length>0&&(this.field.value=this.field.criteria.values[0])}toggle(){let t="true";this.field.value&&(t=""),this.field.value=t,this.field.formControl.setValue(t),this.field.formControl.markAsDirty(),this.field.criteria.operator="=",this.field.criteria.values=[t]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-boolean-checkbox-filter"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:4,vars:1,consts:[[1,"pb-4","checkbox-field"],[1,"checkbox-container"],["type","checkbox","aria-hidden","true",3,"change","checked"],[1,"checkmark"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"label",1)(2,"input",2),e.\u0275\u0275listener("change",function(){return o.toggle()}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"span",3),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275property("checked",o.field.value))},encapsulation:2})}return r})(),gC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule,Ua.TagInputModule]})}return r})(),vC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Fb=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}ngOnInit(){super.ngOnInit(),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}get rows(){return this.field.metadata&&this.field.metadata.rows?this.field.metadata.rows:6}get cols(){return this.field.metadata&&this.field.metadata.cols?this.field.metadata.cols:20}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-text-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:6,consts:[[3,"rows","cols","ngClass","formControl"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"textarea",0),2&n&&(e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("rows",o.rows)("cols",o.cols)("ngClass",o.klass)("formControl",o.field.formControl))},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})(),IS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,ct.NgbDatepickerModule,Oa,Ji.ReactiveFormsModule]})}return r})(),Nb=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule]})}return r})();function xw(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"option",4),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap(n.getId(t)),e.\u0275\u0275property("ngValue",t.value),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.label," ")}}function AS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,xw,2,5,"option",3),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.options)}}let _m=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}ngOnInit(){this.checkAndInitAsDynamicEnum(),super.ngOnInit(),this.subscribeValueChanges()}getId(t){return this.field.name+"-"+t.value}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dropdownenum-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[1,"dropdownenum"],[1,"custom-select","custom-select-sm",3,"formControl"],[4,"ngIf"],[3,"class","ngValue",4,"ngFor","ngForOf"],[3,"ngValue"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"select",1),e.\u0275\u0275template(2,AS,2,1,"ng-container",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("formControl",o.field.formControl),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.options&&o.options.length))},dependencies:[ve.NgForOf,ve.NgIf,Ji.NgSelectOption,Ji.\u0275NgSelectMultipleOption,Ji.SelectControlValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})(),Wh=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule]})}return r})(),Wp=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dropdownenum-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.valueLabel,"\n")},encapsulation:2})}return r})(),zM=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})(),sg=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-radioenum-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.valueLabel,"\n")},encapsulation:2})}return r})(),av=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})();function OS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"input",2),e.\u0275\u0275elementStart(2,"label",3),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275classMapInterpolate1("form-check radioenum-input ",n.getId(t),""),e.\u0275\u0275classProp("form-check-inline","row"===n.displayDirection),e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate("id",n.getId(t)),e.\u0275\u0275property("checked",n.field.value===t.value)("formControl",n.field.formControl)("value",t.value)("name",n.field.name),e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate("for",n.getId(t)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.label," ")}}let Ys=(()=>{class r extends Uh{constructor(t,n,o,f){super(t,n,o,f),this.languages=t,this.typeFormatter=n,this.logic=o,this.logicDisplay=f}get displayDirection(){return this.field&&this.field.definition&&this.field.definition.displayDirection?this.field.definition.displayDirection:""}ngOnInit(){this.checkAndInitAsDynamicEnum(),super.ngOnInit(),this.subscribeValueChanges(),this.record&&this.record.formGroup?this.formGroup=this.record.formGroup:(this.formGroup=new Ji.UntypedFormGroup({}),this.formGroup.addControl(this.field.name,this.field.formControl))}getId(t){return this.field.name+"-"+t.value}buildOptionsArray(t){this.options=[],Object.keys(this.optionsMap).forEach(n=>{this.options.push({value:n,label:this.optionsMap[n]})}),this.isDynamicEnum&&this.buildDynamicEnumOptions(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-radioenum-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:1,consts:[[1,"radioenum"],[3,"form-check-inline","class",4,"ngFor","ngForOf"],["type","radio",1,"form-check-input",3,"checked","formControl","value","name","id"],[1,"form-check-label",3,"for"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,OS,4,12,"div",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",o.options))},dependencies:[ve.NgForOf,Ji.DefaultValueAccessor,Ji.RadioControlValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})(),lv=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule]})}return r})(),_C=(()=>{class r{constructor(t){this.sanitizer=t}transform(t){return this.sanitizer.bypassSecurityTrustHtml(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(L0.up,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"safeHtml",type:r,pure:!0})}return r})(),FS=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-html-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[1,"field-html","text-break",3,"innerHTML"]],template:function(n,o){1&n&&(e.\u0275\u0275element(0,"div",0),e.\u0275\u0275pipe(1,"safeHtml")),2&n&&e.\u0275\u0275property("innerHTML",null!=o.field.metadata&&o.field.metadata.trustHTML?e.\u0275\u0275pipeBind1(1,1,o.field.value):o.field.value,e.\u0275\u0275sanitizeHtml)},dependencies:[_C],encapsulation:2})}return r})(),$f=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),ag=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,$f]})}return r})(),$y=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-password-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:0,template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1,"*****"),e.\u0275\u0275elementEnd())},encapsulation:2})}return r})(),Rb=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Sw=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}ngOnInit(){super.ngOnInit(),this.subscribeValueChanges()}ngOnDestroy(){this.unsubscribeAll()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-password-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:5,consts:[["type","password",3,"formControl","ngClass","value"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"input",0),2&n&&(e.\u0275\u0275classProp("is-invalid",o.validateOnlyOnSubmit?o.isInvalid():o.field.formControl.invalid&&o.field.formControl.touched),e.\u0275\u0275property("formControl",o.field.formControl)("ngClass",o.klass)("value",o.field.value))},dependencies:[ve.NgClass,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.FormControlDirective],encapsulation:2})}return r})(),b_=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Ji.ReactiveFormsModule,Ea]})}return r})();function bu(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"div",1),e.\u0275\u0275pipe(2,"safeHtml"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("innerHTML",e.\u0275\u0275pipeBind1(2,1,t.initialValue),e.\u0275\u0275sanitizeHtml)}}function Wf(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"editor",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("initialValue",t.initialValue)("init",t.settings)("disabled",!0)}}let zi=(()=>{class r extends lu{constructor(t,n,o,f){super(t,n,f),this.typeFormatter=t,this.logic=n,this.config=o,this.logicDisplay=f,this.settings={},this.initialValue=""}ngOnInit(){super.ngOnInit(),this.initSettings(),this.initialValue=this.getValue()}initSettings(){const o=this.config.getConfigValue("ui")?.tinymce?.detail??{};let D={};D=(0,wt.merge)(D,{toolbar:!1,menubar:!1,readonly:!0,deprecation_warnings:!1},o,this.field?.metadata?.tinymce?.detail??{}),this.settings=D}getValue(){let t=this.field.value;return""===t&&(this.field.default??!1)&&(t=this.field.default),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-tinymce-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[[4,"ngIf"],[1,"field-html","text-break",3,"innerHTML"],[1,"field-html","text-break",3,"initialValue","init","disabled"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,bu,3,3,"ng-container",0)(1,Wf,2,3,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",null==o.field||null==o.field.metadata?null:o.field.metadata.trustHTML),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(null!=o.field&&null!=o.field.metadata&&o.field.metadata.trustHTML)))},dependencies:[ve.NgIf,rm.EditorComponent,_C],encapsulation:2,changeDetection:0})}return r})(),yC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[{provide:rm.TINYMCE_SCRIPT_SRC,useValue:"tinymce/tinymce.min.js"}],imports:[ve.CommonModule,Ji.FormsModule,rm.EditorModule,Ji.ReactiveFormsModule,$f]})}return r})(),nu=(()=>{class r extends lu{constructor(t,n,o,f){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o,this.config=f,this.settings={},this.modelEvents="change",this.ignoreEvents="onKeyDown,onKeyPress,onKeyUp,onSelectionChange",this.value=""}ngOnInit(){super.ngOnInit(),this.initSettings(),this.subscribeValueChanges(),this.value=this.getValue()}ngOnDestroy(){this.unsubscribeAll()}initSettings(){const o=this.config.getConfigValue("ui")?.tinymce?.edit??{};let D={};D=(0,wt.merge)(D,{height:300,menubar:!1,deprecation_warnings:!1,plugins:["advlist autolink lists link image charmap print preview anchor","searchreplace visualblocks code fullscreen","insertdatetime media table paste code help wordcount"],toolbar:"undo redo | formatselect | bold italic backcolor | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | removeformat | help",toolbar_mode:"floating"},o,this?.field?.metadata?.tinymce?.edit??{}),this.modelEvents=D?.modelEvents??"change",this.ignoreEvents=D?.ignoreEvents??"onKeyDown,onKeyPress,onKeyUp,onSelectionChange",this.settings=D}setModel(){this.field.formControl.setValue(this.value)}getValue(){let t=this.field.value;return""===t&&(this.field.default??!1)&&(t=this.field.default),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-tinymce-edit"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:4,consts:[[1,"field-html",3,"init","modelEvents","ignoreEvents","formControl"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"editor",0),2&n&&e.\u0275\u0275property("init",o.settings)("modelEvents",o.modelEvents)("ignoreEvents",o.ignoreEvents)("formControl",o.field.formControl)},dependencies:[Ji.NgControlStatus,rm.EditorComponent,Ji.FormControlDirective],encapsulation:2,changeDetection:0})}return r})(),Cu=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[{provide:rm.TINYMCE_SCRIPT_SRC,useValue:"tinymce/tinymce.min.js"}],imports:[ve.CommonModule,Ji.FormsModule,rm.EditorModule,Ji.ReactiveFormsModule]})}return r})(),Wy=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-icon-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[3,"image"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"scrm-image",0),2&n&&e.\u0275\u0275property("image",o.field.value)},dependencies:[Bl],encapsulation:2})}return r})(),ym=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})();function cu(r,v){1&r&&e.\u0275\u0275element(0,"br")}function lg(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1," ... "),e.\u0275\u0275elementContainerEnd())}function Hh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1)(1,"span"),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,cu,1,0,"br",2)(4,lg,2,0,"ng-container",2),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.last,o=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",o.klass)("title",o.field.value),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n&&o.isTruncated)}}let Ew=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o,this.isTruncated=!1}truncateValue(t){let o=t.slice(0,50),f=o.split("\n");const j=f.slice(0,3);return this.isTruncated=o.length!==t.length||f.length>3,j}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-text-list"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[3,"ngClass","title",4,"ngFor","ngForOf"],[3,"ngClass","title"],[4,"ngIf"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,Hh,5,5,"div",0),2&n&&e.\u0275\u0275property("ngForOf",o.truncateValue(o.field.value))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf],encapsulation:2})}return r})(),Wc=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule]})}return r})();const Hy=[vC,__,_S,Rb,b_,ww,ym,xb,Sb,TS,Iy,gT,IS,cw,lw,sC,mC,hS,(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Jm,Ji.FormsModule,Ji.ReactiveFormsModule,Ea,ct.NgbModule]})}return r})(),sT,yw,Nb,Wc,Ob,SS,MS,tv,_b,WM,zM,Wh,av,lv,lC,Dw,Ab,og,vT,gC,ag,yC,Cu],cg=[nv,aw,dw,$y,Sw,jy,uC,p_,vp,iC,oC,ng,rv,yb,Db,wf,Wy,iv,aT,uw,Oy,Fb,Ew,dC,v_,Ib,tC,dS,jp,Wp,_m,sg,Ys,d_,Vy,Zm,wb,By,Uy,FS,zi,nu],hh={"varchar.list":nv,"varchar.detail":nv,"varchar.edit":aw,"varchar.filter":dw,"password.list":$y,"password.detail":$y,"password.edit":Sw,"char.list":nv,"char.detail":nv,"int.list":jy,"int.detail":jy,"file.detail":uC,"file.list":uC,"float.list":p_,"float.detail":p_,"phone.list":vp,"phone.detail":vp,"date.list":iC,"date.detail":iC,"date.edit":oC,"date.filter":ng,"datetime.list":rv,"datetime.detail":rv,"datetime.edit":yb,"datetime.filter":Db,"url.list":wf,"url.detail":wf,"icon.detail":Wy,"icon.edit":Wy,"icon.list":Wy,"link.list":wf,"link.detail":wf,"currency.list":iv,"currency.detail":iv,"currency.edit":aT,"email.list":uw,"email.detail":uw,"text.detail":Oy,"text.edit":Fb,"text.list":Ew,"relate.list":dC,"relate.edit":v_,"relate.detail":dC,"relate.filter":Ib,"fullname.list":tC,"fullname.detail":tC,"enum-radio.list":sg,"enum-radio.detail":sg,"enum-radio.edit":Ys,"radioenum.list":sg,"radioenum.detail":sg,"radioenum.edit":Ys,"radioenum.filter":Zm,"enum-dropdown.list":Wp,"enum-dropdown.detail":Wp,"enum-dropdown.edit":_m,"enum-chips.list":dS,"enum-chips.detail":dS,"enum-chips.edit":jp,"enum.list":Wp,"enum.detail":Wp,"enum.edit":_m,"enum.filter":Zm,"multienum.list":d_,"multienum.detail":d_,"multienum.edit":Vy,"multienum.filter":Zm,"dynamicenum.list":Wp,"dynamicenum.detail":Wp,"dynamicenum.edit":_m,"dynamicenum.filter":Zm,"boolean.list":wb,"boolean.detail":wb,"boolean.edit":By,"bool.list":wb,"bool.detail":wb,"bool.edit":By,"bool.filter":Zm,"bool-checkbox.filter":Uy,"html-native.detail":FS,"html.detail":zi,"html.edit":nu};class Hf{constructor(){this.init()}register(v,t,n,o){this.map.addEntry(v,Hf.getKey(t,n),o)}registerField(v,t,n,o){this.fieldMap.addEntry(v,Hf.getKey(t,n),o)}exclude(v,t){this.map.excludeEntry(v,t)}getDisplayType(v,t,n,o,f){const D=this.getDisplayTypeKey(t,n);return this.hasFieldOverride(v,f,o)?this.getFieldOverride(v,t,o,f):n&&this.has(v,D,o)?this.get(v,D,o,f):this.get(v,t,o,f)}get(v,t,n,o){const f=this.map.getGroupEntries(v);let D=Hf.getKey(t,n);return f[D]||"massupdate"===n&&(D=Hf.getKey(t,"edit"),f[D])?f[D]:f[Hf.getKey("varchar",n)]}getFieldOverride(v,t,n,o){const f=this.fieldMap.getGroupEntries(v);let D=Hf.getKey(o,n);return f[D]||"massupdate"===n&&(D=Hf.getKey(o,"edit"),f[D])?f[D]:null}has(v,t,n){return!!this.map.getGroupEntries(v)[Hf.getKey(t,n)]}hasFieldOverride(v,t,n){return!!this.fieldMap.getGroupEntries(v)[Hf.getKey(t,n)]}static getKey(v,t){return v+"."+t}getDisplayTypeKey(v,t){return v&&t?v+"-"+t:""}init(){this.map=new um,this.fieldMap=new um,Object.keys(this.getDefaultMap()).forEach(v=>{const[t,n]=v.split(".",2);this.register("default",t,n,this.getDefaultMap()[v])})}getDefaultMap(){return{}}}let Nd=(()=>{class r extends Hf{constructor(){super()}getDefaultMap(){return hh}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),C_=(()=>{class r{constructor(t){this.asyncActionService=t}run(t,n,o){this.asyncActionService.run(t,{payload:{fieldName:n.name??"",fieldValue:n.value??""},record:{id:o.id??"",type:o.type??"",module:o.module??"",favorite:o.favorite??"",attributes:o.attributes??{},acls:o.acls??[]}})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const lf=(r,v,t,n,o,f)=>({mode:r,originalMode:v,field:t,klass:n,record:o,parent:f}),bm=r=>({field:r});function zy(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",1),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.onClick())}),e.\u0275\u0275element(2,"ndc-dynamic",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ndcDynamicComponent",t.componentType)("ndcDynamicInputs",e.\u0275\u0275pureFunction6(2,lf,t.mode,t.originalMode,t.field,t.klass,t.record,t.parent))}}function xf(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",3),e.\u0275\u0275element(2,"ndc-dynamic",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",t.getLink())("queryParams",null==t.record||null==t.record.metadata?null:t.record.metadata.queryParams),e.\u0275\u0275advance(),e.\u0275\u0275property("ndcDynamicComponent",t.componentType)("ndcDynamicInputs",e.\u0275\u0275pureFunction6(4,lf,t.mode,t.originalMode,t.field,t.klass,t.record,t.parent))}}function Tw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"ndc-dynamic",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ndcDynamicComponent",t.componentType)("ndcDynamicInputs",e.\u0275\u0275pureFunction6(2,lf,t.mode,t.originalMode,t.field,t.klass,t.record,t.parent))}}function Ju(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,zy,3,9,"ng-container",0)(2,xf,3,11,"ng-container",0)(3,Tw,2,9,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.hasOnClick()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.isLink()&&!t.hasOnClick()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.isLink()&&!t.hasOnClick())}}function D_(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",4),e.\u0275\u0275element(2,"div",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function Hp(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",7),e.\u0275\u0275element(1,"scrm-dynamic-label",8),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("context",n.getMessageContext(t.value,n.record))("fields",e.\u0275\u0275pureFunction1(3,bm,n.field))("labelKey",n.getMessageLabelKey(t.value))}}function Gy(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Hp,2,5,"div",6),e.\u0275\u0275pipe(2,"keyvalue"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind1(2,1,t.field.formControl.errors))}}function Ky(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Gy,3,3,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.validateOnlyOnSubmit?t.isInvalid():t.field.formControl.invalid&&t.field.formControl.touched)}}let Gu=(()=>{class r{constructor(t,n,o,f,D){this.navigation=t,this.moduleNameMapper=n,this.router=o,this.dynamicLabelService=f,this.linkRouteAsyncActionService=D,this.record=null,this.parent=null,this.klass=null,this.class="dynamic-field",this.isInvalid=(0,e.signal)(!1),this.validateOnlyOnSubmit=!1}get getRelateLink(){let t=this.field.definition.module;if("parent_type"===this.field.definition.type_name&&(t=this.record.attributes.parent_type),this.field.definition.id_name&&t){const n=this.moduleNameMapper.toFrontend(t);return this.navigation.getRecordRouterLink(n,this.record.attributes[this.field.definition.id_name])}return""}ngOnInit(){this.setHostClass(),this.validateOnlyOnSubmit=this.record?.metadata?.validateOnlyOnSubmit,this.record?.validationTriggered&&(this.isInvalid=(0,e.computed)(()=>!!(this.validateOnlyOnSubmit&&this.record?.validationTriggered()&&this.field.formControl?.invalid)))}isLink(){return!(dm.includes(this.mode)||!this.field||!this.record||"relate"!==this.type&&(!this?.field?.metadata||!this?.field?.metadata?.link))}hasOnClick(){const t=this?.field?.metadata??{};return!(!t?.linkAsyncAction&&!t?.onClick)}isEdit(){return"edit"===this.mode||"filter"===this.mode}getLink(){if("relate"===this.type)return this.getRelateLink;const t=this?.field?.metadata??null,n=t.linkRoute??null;return t&&n?this.dynamicLabelService.parse(n,{},this.record.fields):this.navigation.getRecordRouterLink(this.record.module,this.record.id)}getMessageContext(t,n){const o=t&&t.message&&t.message.context||{};return o.module=n&&n.module||"",o}getMessageLabelKey(t){return t&&t.message&&t.message.labelKey||""}onClick(){const t=this?.field?.metadata??null;if(t&&t.onClick)return void this.field.metadata.onClick(this.field,this.record);const n=t.linkAsyncAction??null;if(!t||!n)return this.router.navigateByUrl(this.getLink()).then(),!1;this.linkRouteAsyncActionService.run(n,this.field,this.record)}setHostClass(){const t=[];t.push("dynamic-field"),this.mode&&t.push("dynamic-field-mode-"+this.mode),this.type&&t.push("dynamic-field-type-"+this.type),this.field&&this.field.name&&t.push("dynamic-field-name-"+this.field.name),this.class=t.join(" ")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(rb),e.\u0275\u0275directiveInject(C_))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-dynamic-field"]],hostVars:2,hostBindings:function(n,o){2&n&&e.\u0275\u0275classMap(o.class)},inputs:{mode:"mode",originalMode:"originalMode",type:"type",field:"field",record:"record",parent:"parent",klass:"klass",componentType:"componentType"},decls:3,vars:3,consts:[[4,"ngIf"],[1,"clickable","field-link",3,"click"],[3,"ndcDynamicComponent","ndcDynamicInputs"],[1,"field-link",3,"routerLink","queryParams"],[1,"dynamic-field"],[1,"flex-grow-1","text-break","rounded","box-loading","skeleton-field-content"],["class","invalid-feedback d-block",4,"ngFor","ngForOf"],[1,"invalid-feedback","d-block"],[3,"context","fields","labelKey"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,Ju,4,3,"ng-container",0)(1,D_,3,0,"ng-container",0)(2,Ky,2,1,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",!(null!=o.field&&o.field.loading())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",null==o.field?null:o.field.loading()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isEdit()&&o.field.formControl&&o.field.formControl.errors))},dependencies:[ve.NgForOf,ve.NgIf,Wo.RouterLink,Df,St,Ht,ve.KeyValuePipe],encapsulation:2})}return r})();const Jl=["wrapper"];function ug(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",2),e.\u0275\u0275elementContainerEnd())}function qy(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",8)(1,"label"),e.\u0275\u0275element(2,"scrm-label",9),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.labelKey)("module",n.getModule())}}function zh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",10),e.\u0275\u0275element(1,"scrm-dynamic-field",11),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("componentType",n.getComponentType(t.type,t.definition))("field",t)("klass",n.klass)("mode",n.mode)("originalMode",n.originalMode)("record",n.record)("parent",n.parent)("type",t.type)}}function cv(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",5),e.\u0275\u0275template(1,qy,3,2,"span",6)(2,zh,2,8,"span",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("flex-fill","edit"===n.mode&&"flex-row"===n.direction())("h-100","flex-row"===n.direction()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.labelKey&&n.showLabel(t.definition.name)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.type)}}function Mw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,cv,3,6,"div",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.isModeEnabled(n.mode,t))}}function w_(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",null,0),e.\u0275\u0275template(3,Mw,2,1,"ng-container",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("d-flex ",t.direction()," justify-content-start align-items-start field-group h-100 w-100"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.getFields())}}let dg=(()=>{class r extends lu{onResize(){this.triggerRecalculateDirection()}constructor(t,n,o,f,D){super(t,o,f),this.typeFormatter=t,this.registry=n,this.logic=o,this.logicDisplay=f,this.config=D,this.direction=(0,e.signal)(""),this.recalculateDirectionBuffer=new i.Subject,this.recalculateDirectionBuffer$=this.recalculateDirectionBuffer.asObservable()}ngOnInit(){super.ngOnInit(),this.subs.push(this.recalculateDirectionBuffer$.pipe((0,M.debounceTime)(50)).subscribe(()=>{this.calculateDirection()})),this.subs.push(this.mode$.subscribe(()=>{this.triggerRecalculateDirection()})),this.triggerRecalculateDirection(),this.hasValidConfig=this.isConfigured()}ngAfterViewInit(){this.triggerRecalculateDirection()}getComponentType(t,n){return this.registry.getDisplayType(this.record&&this.record.module||"default",t,n&&n.displayType||"",this.mode,this.field.name)}getFields(){const t=[];return this.field.definition.layout.forEach(n=>{!this.record.fields[n]||"none"===this.record.fields[n]?.display()||t.push(this.record.fields[n])}),t}getModule(){return this.record?this.record.module:null}calculateDirection(){const t=this?.wrapper?.nativeElement?.offsetWidth??null;let n="flex-column";"inline"===(this?.field?.definition?.display??"")&&(n="flex-row"),t&&"detail"!==this.mode&&"list"!==this.mode&&t<(this?.config?.getUi("group_field_mobile_breakdown_limit")??350)?this.direction.set("flex-column"):this.direction.set(n)}isConfigured(){return this.hasDisplay()&&this.hasLayout()&&this.hasGroupFields()}showLabel(t){const n=this.field.definition||null;if(!n||!n.showLabel)return!1;const f=n.showLabel[this.mode]||null;return!(!f||typeof f>"u")&&(f.includes("*")||f.includes(t))}isModeEnabled(t,n){const o=n.definition.modes;return!o||o.length<1||o.includes(t)}triggerRecalculateDirection(){this.recalculateDirectionBuffer.next(!0)}hasGroupFields(){return!(!this.field.definition.groupFields||!Object.keys(this.field.definition.groupFields).length)}hasLayout(){return!(!this.field.definition.layout||!this.field.definition.layout.length)}hasDisplay(){return!!this.field.definition.display}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Nd),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-group-field"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(Jl,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.wrapper=f.first)}},hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("resize",function(D){return o.onResize(D)},!1,e.\u0275\u0275resolveWindow)},features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[["wrapper",""],[4,"ngIf"],["labelKey","LBL_BAD_GROUP_FIELD_CONFIG"],[4,"ngFor","ngForOf"],["class","field-group-item d-flex flex-column justify-content-end w-100",3,"flex-fill","h-100",4,"ngIf"],[1,"field-group-item","d-flex","flex-column","justify-content-end","w-100"],["class","field-group-label pt-2 pr-1 font-weight-bold",4,"ngIf"],["class","field-group-field pr-1",4,"ngIf"],[1,"field-group-label","pt-2","pr-1","font-weight-bold"],[3,"labelKey","module"],[1,"field-group-field","pr-1"],[3,"componentType","field","klass","mode","originalMode","record","parent","type"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,ug,2,0,"ng-container",1)(1,w_,4,4,"ng-container",1),2&n&&(e.\u0275\u0275property("ngIf",!o.hasValidConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.hasValidConfig))},dependencies:[ve.NgForOf,ve.NgIf,Pa,Gu],encapsulation:2})}return r})(),uv=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Wo.RouterModule,dh,on]})}return r})(),fg=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea,uv]})}return r})();const Qy=r=>v=>r.validateFloatUserFormat(v.value)?{currencyValidator:{valid:!1,format:r.getFloatUserFormatPattern(),message:{labelKey:"LBL_VALIDATION_ERROR_CURRENCY_FORMAT",context:{value:v.value,expected:r.toUserFormat("1000.50")}}}}:null;let bC=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return!(!n||!n.fieldDefinition)&&"currency"===n.type}getValidator(t){return t&&t.fieldDefinition?[Qy(this.formatter)]:[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const pg=(r,v)=>t=>r.validateUserFormat(t.value,v)?{invalidDate:{value:t.value,message:{labelKey:"LBL_VALIDATION_ERROR_DATE_FORMAT",context:{value:t.value,expected:r.toUserFormat("2020-01-23")}}}}:null;let Gh=(()=>{class r{constructor(t,n){this.formatter=t,this.utils=n}applies(t,n){return!(!n||!n.fieldDefinition)&&"date"===n.type}getValidator(t){return t&&t.fieldDefinition?[pg(this.formatter,t?.metadata?.date_time_format||"")]:[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(r_),e.\u0275\u0275inject(qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const CC=(r,v)=>t=>r.validateUserFormat(t.value,v)?{dateTimeValidator:{value:t.value,message:{labelKey:"LBL_VALIDATION_ERROR_DATETIME_FORMAT",context:{value:t.value,expected:r.toUserFormat("2020-01-23 12:30:40")}}}}:null;let NS=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return!(!n||!n.fieldDefinition)&&"datetime"===n.type}getValidator(t){return t&&t.fieldDefinition?[CC(this.formatter,t?.metadata?.date_time_format||"")]:[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(kh))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const ud=r=>v=>r.validateFloatUserFormat(v.value)?{floatValidator:{valid:!1,format:r.getFloatUserFormatPattern(),message:{labelKey:"LBL_VALIDATION_ERROR_FLOAT_FORMAT",context:{value:v.value,expected:r.toUserFormat("1000.50")}}}}:null;let x_=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return!(!n||!n.fieldDefinition)&&"float"===n.type}getValidator(t){return t&&t.fieldDefinition?[ud(this.formatter)]:[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const hg=r=>v=>r.validateIntUserFormat(v.value)?{intValidator:{valid:!1,format:r.getIntUserFormatPattern(),message:{labelKey:"LBL_VALIDATION_ERROR_INT_FORMAT",context:{value:v.value,expected:r.toUserFormat("1000")}}}}:null;let Yy=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return"int"===(n?.type??n?.fieldDefinition?.type)}getValidator(t){return t?.type??t?.fieldDefinition?.type?[hg(this.formatter)]:[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),RS=(()=>{class r{constructor(t,n){this.formUtils=t,this.configs=n}toUserFormat(t){return t}toInternalFormat(t){return t}getUserFormatPattern(){let n=this.configs.getUi("validations")?.regex?.email||"";return n||(n="^(?:[\\.\\-\\+&#!\\$\\*=\\?\\^_`\\{\\}~\\/\\w]+)@(?:(?:\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3})|\\w+(?:[\\.-]*\\w+)*(?:\\.[\\w-]{2,})+)$"),n}validateUserFormat(t,n=""){const o=this.formUtils.getTrimmedInputValue(t);return!this.formUtils.isEmptyInputValue(o)&&!new RegExp(n).test(o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(qg),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const cf=(r,v)=>t=>{const n=v||r.getUserFormatPattern();return r.validateUserFormat(t.value,n)?{emailValidator:{valid:!1,format:new RegExp(n),message:{labelKey:"LBL_VALIDATION_ERROR_EMAIL_FORMAT",context:{value:t.value,expected:"example@example.org"}}}}:null};let uu=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return!(!n||!n.fieldDefinition)&&"email"===n.type}getValidator(t){if(!t||!t.fieldDefinition)return[];const n=t?.fieldDefinition?.validation?.regex.toString()??null;return[cf(this.formatter,n)]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(RS))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Lb=(r,v)=>t=>{const n=v||r.getDefaultFormatPattern();return r.validateUserFormat(t.value,n)?{phoneValidator:{valid:!1,format:n,message:{labelKey:"LBL_VALIDATION_ERROR_PHONE_FORMAT",context:{value:t.value}}}}:null};let iu=(()=>{class r{constructor(t){this.formatter=t}applies(t,n){return!(!n||!n.fieldDefinition)&&"phone"===n.type}getValidator(t){if(!t||!t.fieldDefinition)return[];const n=t?.fieldDefinition?.validation?.regex.toString()??null;return[Lb(this.formatter,n)]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(fy))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const dv=r=>v=>{const t=Ji.Validators.min(r)(v);return null===t?null:{emailValidator:{...t,message:{labelKey:"LBL_VALIDATION_ERROR_MIN",context:{value:v.value,min:""+r}}}}},Cm=r=>v=>{const t=Ji.Validators.max(r)(v);return null===t?null:{emailValidator:{...t,message:{labelKey:"LBL_VALIDATION_ERROR_MAX",context:{value:v.value,max:""+r}}}}};let S_=(()=>{class r{applies(t,n){return!(!n||!n.fieldDefinition)&&null!==this.getRangeValidation(n.fieldDefinition)}getValidator(t){if(!t||!t.fieldDefinition)return[];const n=this.getRangeValidation(t.fieldDefinition);if(!n)return[];let o=null;(0,wt.isNumber)(n?.max)&&(o=parseInt(""+n.max,10));let f=null;(0,wt.isNumber)(n?.min)&&(f=parseInt(""+n.min,10));const D=[];return(0,wt.isNumber)(f)&&isFinite(f)&&D.push(dv(f)),(0,wt.isNumber)(o)&&isFinite(o)&&D.push(Cm(o)),D}getRangeValidation(t){if(this.isRangeValidation(t.validation))return t.validation;if(!t.validations||!t.validations.length)return null;let n=null;return t.validations.some(o=>(n=o,this.isRangeValidation(o))),n}isRangeValidation(t){return t&&"range"===t.type}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Xy=(r,v)=>t=>{const n=r.name||"";if(!n||!v||!v.fields)return null;const o=v.fields[n]||{},f=o.items;if(!o||!f||!f.length)return null;let D=0;const j=f.filter(Ne=>!(Ne&&Ne.attributes&&Ne.attributes.deleted));if(j&&j.length<1)return null;let fe=0;return j.some(Ne=>{const vt=Ne.fields&&Ne.fields["email-fields"]||{},ln=vt.attributes&&vt.attributes.primary_address||null;return!(!(vt.attributes&&vt.attributes.email_address||null)?.value||(fe++,!ln))&&(cl(ln.value)&&D++,D>1)}),1==D||0==D&&0===fe?null:0==D?{primaryEmailValidation:{valid:!1,message:{labelKey:"LBL_NO_PRIMARY_EMAIL_VALIDATION_ERROR",context:{}}}}:{primaryEmailValidation:{valid:!1,message:{labelKey:"LBL_MULTIPLE_PRIMARY_EMAIL_VALIDATION_ERROR",context:{}}}}};let Zy=(()=>{class r{constructor(){}applies(t,n){return!(!n||!n.fieldDefinition)&&("line-items"===(n.type||n.fieldDefinition.type||"")&&"email_addresses"===(n.name||n.fieldDefinition.name||""))}getValidator(t,n){return t&&t.fieldDefinition&&n?[Xy(t,n)]:[]}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const dd=(r,v)=>t=>{const n=r.name||"";if(!n||!v||!v.fields)return null;const o=v.fields[n]||{},f=o.items;if(!o||!f||!f.length)return null;const D={};let j=0;const fe=f.filter(Ne=>!(Ne&&Ne.attributes&&Ne.attributes.deleted));return fe&&fe.length<1||(fe.some(Ne=>{const vt=Ne.fields&&Ne.fields["email-fields"]||{},ln=vt.attributes&&vt.attributes.email_address||null;if(!ln.value)return!1;const Hn=(""+ln.value).toUpperCase();return D[Hn]?(j++,!0):(D[Hn]=!0,j>1)}),0==j)?null:{duplicateEmailValidation:{valid:!1,message:{labelKey:"LBL_DUPLICATE_EMAIL_VALIDATION_ERROR",context:{}}}}};let fv=(()=>{class r{constructor(){}applies(t,n){return!(!n||!n.fieldDefinition)&&("line-items"===(n.type||n.fieldDefinition.type||"")&&"email_addresses"===(n.name||n.fieldDefinition.name||""))}getValidator(t,n){return t&&t.fieldDefinition&&n?[dd(t,n)]:[]}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const GM=(r,v,t)=>n=>{const o=r.name||"";if(!o||!v||!v.fields)return null;const f=v?.fields[o]??{},D=f?.items??[];if(!f||!D)return null;const j=D.filter(fe=>!(fe&&fe.attributes&&fe.attributes.deleted));return j&&j.length>0?null:{required:{required:!0,message:{labelKey:"LBL_VALIDATION_ERROR_REQUIRED",context:{}}}}};let kb=(()=>{class r{constructor(t){this.utils=t}applies(t,n){return!(!n||!n.fieldDefinition)&&("line-items"===(n?.type??n?.fieldDefinition?.type??"")&&cl(n?.required??n?.fieldDefinition?.required??!1))}getValidator(t,n){return[GM(t,n,this.utils)]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(qg))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),pv=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi){this.requiredValidator=t,this.rangeValidator=n,this.currencyValidator=o,this.dateValidator=f,this.datetimeValidator=D,this.emailValidator=j,this.floatValidator=fe,this.intValidator=Ne,this.phoneValidator=vt,this.primaryEmailValidator=ln,this.duplicateEmailValidator=Hn,this.lineItemsRequiredValidator=Oi,this.filterFieldExclusion={default:{}},this.saveFieldExclusions={default:{}},this.saveValidators=new um,this.itemFormArraySaveValidators=new um,this.asyncSaveValidators=new um,this.filterValidators=new um,this.saveValidators.addEntry("default",this.getKey("required","all"),t),this.saveValidators.addEntry("default",this.getKey("range","all"),n),this.saveValidators.addEntry("default",this.getKey("currency","all"),o),this.saveValidators.addEntry("default",this.getKey("date","all"),f),this.saveValidators.addEntry("default",this.getKey("datetime","all"),D),this.saveValidators.addEntry("default",this.getKey("email","all"),j),this.saveValidators.addEntry("default",this.getKey("float","all"),fe),this.saveValidators.addEntry("default",this.getKey("int","all"),Ne),this.saveValidators.addEntry("default",this.getKey("phone","all"),vt),this.itemFormArraySaveValidators.addEntry("default",this.getKey("primary-email","all"),ln),this.itemFormArraySaveValidators.addEntry("default",this.getKey("duplicate-email","all"),Hn),this.itemFormArraySaveValidators.addEntry("default",this.getKey("line-items-required","all"),Oi),this.filterValidators.addEntry("default",this.getKey("date","all"),f),this.filterValidators.addEntry("default",this.getKey("datetime","all"),D),this.filterValidators.addEntry("default",this.getKey("float","all"),fe),this.filterValidators.addEntry("default",this.getKey("currency","all"),o),this.filterValidators.addEntry("default",this.getKey("int","all"),Ne),this.filterValidators.addEntry("default",this.getKey("phone","all"),vt)}registerFieldSaveValidator(t,n,o,f){this.saveValidators.addEntry(t,this.getKey(n,o),f)}registerSaveValidator(t,n,o){this.saveValidators.addEntry(t,this.getKey(n,"all"),o)}registerFieldFilterValidator(t,n,o,f){this.filterValidators.addEntry(t,this.getKey(n,o),f)}registerFilterValidator(t,n,o){this.filterValidators.addEntry(t,this.getKey(n,"all"),o)}excludeFieldSaveValidator(t,n,o){const f=this.saveFieldExclusions[t]||{},D=this.getKey(n,o);f[D]=D,this.saveFieldExclusions[t]=f}excludeSaveValidator(t,n){this.saveValidators.excludeEntry(t,this.getKey(n,"all"))}excludeFieldFilterValidator(t,n,o){const f=this.filterFieldExclusion[t]||{},D=this.getKey(n,o);f[D]=D,this.filterFieldExclusion[t]=f}excludeFilterValidator(t,n){this.filterValidators.excludeEntry(t,this.getKey(n,"all"))}registerAsyncSaveValidator(t,n,o){this.asyncSaveValidators.addEntry(t,this.getKey(n,"all"),o)}excludeAsyncSaveValidator(t,n){this.saveValidators.excludeEntry(t,this.getKey(n,"all"))}getSaveValidations(t,n,o){const f=this.saveValidators.getGroupEntries(t),D=this.getExclusions(t,this.saveFieldExclusions);return this.filterValidations(f,D,o,n)}getItemFormArraySaveValidations(t,n,o){const f=this.itemFormArraySaveValidators.getGroupEntries(t),D=this.getExclusions(t,this.saveFieldExclusions);return this.filterValidations(f,D,o,n)}getFilterValidations(t,n,o){const f=this.filterValidators.getGroupEntries(t),D=this.getExclusions(t,this.filterFieldExclusion);return this.filterValidations(f,D,o,n)}getAsyncSaveValidations(t,n,o){const f=[],D=this.asyncSaveValidators.getGroupEntries(t);return Object.keys(D).forEach(j=>{const fe=D[j];fe.applies(o,n)&&f.push(fe.getValidator(n,o))}),f}getKey(t,n){return`${t}.${n}`}parseType(t){return(t.split(".")||[])[0]||""}getExclusions(t,n){return{...n.default||{},...n[t]||{}}}filterValidations(t,n,o,f){let D=[];return Object.keys(t).forEach(j=>{const fe=this.getKey(this.parseType(j),f.name);if(n[j]||n[fe])return;const Ne=t[j];Ne.applies(o,f)&&(D=D.concat(Ne.getValidator(f,o)))}),D}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(mb),e.\u0275\u0275inject(S_),e.\u0275\u0275inject(bC),e.\u0275\u0275inject(Gh),e.\u0275\u0275inject(NS),e.\u0275\u0275inject(uu),e.\u0275\u0275inject(x_),e.\u0275\u0275inject(Yy),e.\u0275\u0275inject(iu),e.\u0275\u0275inject(Zy),e.\u0275\u0275inject(fv),e.\u0275\u0275inject(kb))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class DC extends Hx{get value(){return this.valueListState.join(",")}set value(v){this.valueState="",this.valueListState=[],(0,wt.isArray)(v)&&(0,wt.isString)(v[0])?this.valueList=v:v&&this.emitValueChanges()}}const hv={default:Hx,multienum:DC};let Hc=(()=>{class r extends J0{initDefault(){Object.keys(this.getDefaultMap()).forEach(t=>{this.register("default",t,this.getDefaultMap()[t])})}getDefaultMap(){return hv}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),zf=(()=>{class r{constructor(t,n,o){this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}buildField(t,n,o=null){const f=t?.module??"";let D=n?.fieldDefinition??{};const fe=(n?.multiModuleDefinitions??{})[f]??{};(0,wt.isEmpty)(fe)||(D=fe);const{value:Ne,valueList:vt,valueObject:ln}=this.parseValue(n,D,t),{validators:Hn,asyncValidators:Oi,itemFormArraySaveValidators:Lr}=this.getSaveValidators(t,n),to=this.setupField(t.module,n,Ne,vt,ln,t,D,Hn,Oi,o);return to.itemFormArraySaveValidators=Lr,to}getFieldLabel(t,n,o){const f=o.getLanguageStrings();return o.getFieldLabel(t,n,f)}parseValue(t,n,o){const f=t&&t.type||"",D=n&&n.source||"",j=n&&n.rname||"name",fe=t.name||"";let Ne=null,vt=null;if(fe&&(o.attributes[fe]||sf(o.attributes[fe]))){if("relate"===f&&"non-db"===D&&""!==j)return Ne=o.attributes[fe][j],{value:Ne,valueList:vt,valueObject:o.attributes[fe]};Ne=o.attributes[fe]}else Ne="";return"line-items"===f?{value:null,valueList:vt}:(Array.isArray(Ne)&&(vt=Ne,Ne=null),{value:Ne,valueList:vt})}setupField(t,n,o,f,D,j,fe,Ne,vt,ln){const Hn=(0,wt.merge)(fe?.metadata??{},n?.metadata??{}),Oi=this.typeFormatter.toUserFormat(n.type,o,{mode:"edit",metadata:Hn});n.link&&(Hn.link=n.link);const Lr=n.type||fe.type,Mr=new(this.fieldRegistry.get(t,Lr));Mr.type=Lr,Mr.name=n.name||fe.name||"",Mr.vardefBased=n?.vardefBased??fe?.vardefBased??!1,Mr.readonly=cl(n.readonly)||cl(fe.readonly)||!1,Mr.display=(0,e.signal)(n.display||fe.display||"default"),Mr.required=(0,e.signal)(cl(fe?.required)??cl(n?.fieldDefinition?.required)??!1),Mr.defaultDisplay=Mr?.display(),"default"===Mr.defaultDisplay&&(Mr.defaultDisplay="show"),Mr.value=o,Mr.metadata=Hn,Mr.definition=fe,n?.lineItems&&(Mr.definition.lineItems=n.lineItems),Mr.labelKey=n.label||fe.vname||"",Mr.dynamicLabelKey=n.dynamicLabelKey||fe.dynamicLabelKey||"";const ss=n?.defaultValue??fe?.default??fe?.defaultValue??null;ss&&(Mr.default=ss),Mr.defaultValueModes=n?.defaultValueModes??fe?.defaultValueModes??[],Mr.validators=Ne,Mr.asyncValidators=vt,"line-items"===Mr.type?(Mr.valueObjectArray=j.attributes[Mr.name],Mr.itemFormArray=new Ji.UntypedFormArray([]),Mr.formControl=new Ji.UntypedFormControl(Oi)):Mr.formControl=new Ji.UntypedFormControl(Oi),Mr.useFullColumn=n?.useFullColumn||fe?.useFullColumn||null,Mr.attributes={},Mr.source="field",Mr.logic=n.logic||fe.logic||null,Mr.displayLogic=n.displayLogic||fe.displayLogic||null;const Rs={},Us={};return this.addFieldDependencies(Mr.logic,Rs,Us,"logic"),this.addFieldDependencies(Mr.displayLogic,Rs,Us,"displayLogic"),Mr.attributeDependencies=Object.keys(Us).map(wu=>Us[wu]),Mr.fieldDependencies=Rs,f&&(Mr.valueList=f),D&&(Mr.valueObject=D),ln&&(Mr.label=this.getFieldLabel(n.label,t,ln)),!Mr.labelKey&&n.label&&(Mr.labelKey=n.label),Mr}addFieldDependencies(t,n,o,f){t&&Object.keys(t).length&&Object.keys(t).forEach(D=>{const j=t[D]||{};j.params&&(j.params&&j.params.attributeDependencies&&j.params.attributeDependencies.forEach(fe=>{o[fe.field+"."+fe.attribute]=fe}),j.params&&j.params.fieldDependencies&&j.params.fieldDependencies.forEach(fe=>{const vt=(n[fe]??{}).types??[];vt.push(f),n[fe]={field:fe,type:vt}}))})}getSaveValidators(t,n){return{validators:this.validationManager.getSaveValidations(t.module,n,t),asyncValidators:this.validationManager.getAsyncSaveValidations(t.module,n,t),itemFormArraySaveValidators:this.validationManager.getItemFormArraySaveValidations(t.module,n,t)}}getParentValue(t,n,o,f){const D=f.valueParent??"field";return f.valuePath?(0,an.A)("record"===D?t:n,f.valuePath,""):(0,an.A)("record"===D?t.attributes:n.valueObject,o,"")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),mv=(()=>{class r extends zf{constructor(t,n,o){super(t,n,o),this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}addGroupFields(t,n,o,f,D,j){const Ne=(n&&n.fieldDefinition||{}).groupFields||{};Object.keys(Ne).forEach(ln=>{const Hn=Ne[ln];if(f(t,ln))return;Hn&&"relate"===Hn.type&&"parent_type"===Hn.type_name&&(Hn.module=t.attributes.parent_type);const Lr=D(t,{name:Hn.name,label:Hn.vname,type:Hn.type,fieldDefinition:Hn},o);Lr.source="groupField",j(t,Hn.name,Lr)})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),E_=(()=>{class r extends zf{constructor(t,n,o){super(t,n,o),this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}addAttributes(t,n,o,f,D,j){const fe=Object.keys(n)||[];fe.length<1||fe.forEach(Ne=>{this.addFieldAttributes(t,n[Ne],f,D,j)})}addFieldAttributes(t,n,o,f,D){const fe=(n&&n.definition||{}).attributeFields||{};Object.keys(fe).forEach(vt=>{const ln=fe[vt];if(n.attributes[vt])return;const Oi=f(t,n,{name:ln.name,label:ln.vname,type:ln.type,fieldDefinition:ln},o);D(t,n,ln.name,Oi)})}buildAttribute(t,n,o,f=null){const D=o&&o.fieldDefinition||{},{value:j,valueList:fe,valueObject:Ne}=this.parseAttributeValue(o,D,t,n),{validators:vt,asyncValidators:ln}=this.getSaveValidators(t,o),Hn=this.setupField(t.module,o,j,fe,Ne,t,D,vt,ln,f),Oi=Hn;return Oi.valuePath=D.valuePath,Oi.valueParent=D.valueParent,Oi.source="attribute",Oi.parentKey=n.name,Oi.useFullColumn=D?.useFullColumn||Hn?.definition?.useFullColumn||null,Oi}addAttributeToRecord(t,n,o,f){!t||!o||!n||!f||(n.attributes=n.attributes||{},n.attributes[o]=f,t.formGroup&&f.formControl&&t.formGroup.addControl(o,f.formControl))}parseAttributeValue(t,n,o,f){const fe=n&&n.rname||"name",Ne=t.name||"";let vt;return"relate"===(t&&t.type||"")&&"non-db"===(n&&n.source||"")&&""!==fe?(vt=this.getParentValue(o,f,Ne,n)[fe],{value:vt,valueList:null,valueObject:this.getParentValue(o,f,Ne,n)}):(vt=Ne?this.getParentValue(o,f,Ne,n):"",vt=this.getParentValue(o,f,Ne,n),Array.isArray(vt)?{value:null,valueList:vt,valueObject:null}:(0,om.A)(vt)?{value:null,valueList:null,valueObject:vt}:{value:vt,valueList:null,valueObject:null})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),wC=(()=>{class r extends zf{constructor(t,n,o){super(t,n,o),this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}buildFilterField(t,n,o=null){const f=n&&n.fieldDefinition||{},{validators:D,asyncValidators:j}=this.getFilterValidators(t,n),fe=this.setupField(t.searchModule,n,null,null,null,t,f,D,j,o);return fe.criteria=this.initFieldFilter(t.criteria,n,fe),fe}getFilterValidators(t,n){return{validators:this.validationManager.getFilterValidations(t.searchModule,n,t),asyncValidators:[]}}initFieldFilter(t,n,o){let f;const D=n.name;let j=n.type,fe=!1;return"composite"===j&&(j=o.definition.type,fe=!0),f=t.filters[D]&&t.filters[D].fieldType?dr(t.filters[D]):{field:D,fieldType:j,operator:"",values:[]},f.rangeSearch=fe,this.mapEnumEmptyOption(f,o),this.mapRelateFields(f,o,t),f}mapEnumEmptyOption(t,n){!["multienum","enum"].includes(t.fieldType)||!this.getEmptyOption(n)||!t.values||!t.values.length||(t.values=t.values.map(f=>""!==f?f:"__SuiteCRMEmptyString__"))}mapRelateFields(t,n,o){if(!["relate"].includes(t.fieldType)||!t.values||!t.values.length)return;const f=n&&n.definition&&n.definition.id_name||"",D=n&&n.definition&&n.definition.rname||"name",j=o?.filters[f]?.values??[];t.valueObjectArray=t.valueObjectArray??[];const fe={};t.valueObjectArray.length&&t.valueObjectArray.forEach(Ne=>{fe[Ne.id]=Ne});for(let Ne=0;Ne<t.values.length;Ne++){const ln={};ln[D]=t.values[Ne],ln.id=j[Ne]??"",fe[ln.id]||(fe[ln.id]=ln,t.valueObjectArray.push(ln))}}getEmptyOption(t){let n=null;return(t?.definition?.metadata?.extraOptions??[]).forEach(f=>{"__SuiteCRMEmptyString__"===f.value&&(n=f)}),n}isCriteriaFieldInitialized(t,n){const o=t.criteriaFields[n];return!!o&&!o.vardefBased}addToSavedFilter(t,n,o){!t||!n||!o||(t.criteriaFields||(t.criteriaFields={}),t.criteriaFields[n]=o,t.criteria.filters||(t.criteria.filters={}),t.criteria.filters[n]=o.criteria,t.criteriaFormGroup&&o.formControl&&t.criteriaFormGroup.addControl(n,o.formControl))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xC=(()=>{class r extends wC{constructor(t,n,o){super(t,n,o),this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}buildFilterAttribute(t,n,o,f=null){const D=o&&o.fieldDefinition||{};D.valuePath||(D.valuePath="criteria."+(o.name||D.name));const{value:j,valueList:fe,valueObject:Ne}=this.parseFilterAttributeValue(o,D,t,n),{validators:vt,asyncValidators:ln}=this.getFilterValidators(t,o),Oi=this.setupField(t.searchModule,o,j,fe,Ne,t,D,vt,ln,f);return Oi.valuePath=D.valuePath,Oi.source="attribute",Oi.parentKey=n.definition.name,Oi}addAttributeToSavedFilter(t,n,o,f){!t||!o||!n||!f||(n.attributes=n.attributes||{},n.attributes[o]=f,t.criteriaFormGroup&&f.formControl&&t.criteriaFormGroup.addControl(o,f.formControl))}parseFilterAttributeValue(t,n,o,f){const D=t.name||"";let j;return j=D?this.getParentValue(o,f,D,n):"",Array.isArray(j)?{value:null,valueList:j,valueObject:null}:(0,om.A)(j)?{value:null,valueList:null,valueObject:j}:{value:j,valueList:null,valueObject:null}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),SC=(()=>{class r extends E_{constructor(t,n,o){super(t,n,o),this.validationManager=t,this.typeFormatter=n,this.fieldRegistry=o}addLineItems(t,n,o,f,D){const j=Object.keys(n)||[];j.length<1||j.forEach(fe=>{this.addFieldLineItems(t,n[fe],f,D)})}addFieldLineItems(t,n,o,f){const D=n&&n.definition||{},fe=n.valueObjectArray&&n.valueObjectArray||[];if("line-items"!==(n&&n.type||"")||!fe.length)return;const Ne=D.lineItems?.definition||{};n.items=[],fe.forEach(vt=>{this.addLineItem(Ne,vt,f,o,t,n)})}addLineItem(t,n,o,f,D,j){const fe={name:t.name,label:t.vname,type:t.type,fieldDefinition:dr(t)},Ne={id:n.id||"",type:n.type||"",module:n.module||"",attributes:n.attributes||{},fields:{},formGroup:new Ji.UntypedFormGroup({})};o(Ne,fe,f),j.itemFormArray.push(Ne.formGroup),j.items.push(Ne)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pv),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(Hc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),_p=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.fieldBuilder=t,this.groupFieldBuilder=n,this.attributeBuilder=o,this.filterFieldBuilder=f,this.filterAttributeBuilder=D,this.lineItemBuilder=j,this.languageStore=fe}buildShallowField(t,n){return{type:t,value:n,definition:{type:t},loading:(0,e.signal)(!1),display:(0,e.signal)("default")}}addField(t,n,o=null){const f=this.fieldBuilder.buildField(t,n,o);return this.addToRecord(t,n.name,f),this.groupFieldBuilder.addGroupFields(t,n,o,this.isFieldInitialized.bind(this),this.fieldBuilder.buildField.bind(this.fieldBuilder),this.addToRecord.bind(this)),this.attributeBuilder.addAttributes(t,t.fields,n,o,this.attributeBuilder.buildAttribute.bind(this.attributeBuilder),this.attributeBuilder.addAttributeToRecord.bind(this.attributeBuilder)),this.lineItemBuilder.addLineItems(t,t.fields,n,o,this.addField.bind(this)),f}addFilterField(t,n,o=null){if(n.vardefBased&&!(0,wt.isEmpty)(t.criteriaFields[n.name]))return t.criteriaFields[n.name];const f=this.filterFieldBuilder.buildFilterField(t,n,o);return this.filterFieldBuilder.addToSavedFilter(t,n.name,f),this.groupFieldBuilder.addGroupFields(t,n,o,this.filterFieldBuilder.isCriteriaFieldInitialized.bind(this.filterFieldBuilder),this.filterFieldBuilder.buildFilterField.bind(this.filterFieldBuilder),this.filterFieldBuilder.addToSavedFilter.bind(this.filterFieldBuilder)),this.attributeBuilder.addAttributes(t,t.criteriaFields,n,o,this.filterAttributeBuilder.buildFilterAttribute.bind(this.filterAttributeBuilder),this.filterAttributeBuilder.addAttributeToSavedFilter.bind(this.filterAttributeBuilder)),f}addLineItem(t,n,o,f=null){f||(f={id:"",module:o.definition.module||"",attributes:{},fields:{},formGroup:new Ji.UntypedFormGroup({})}),this.lineItemBuilder.addLineItem(t,f,this.addField.bind(this),this.languageStore,n,o),o.itemFormArray.updateValueAndValidity()}removeLineItem(t,n){const o=t.items[n];o&&(o.attributes.deleted=1,t.itemFormArray.clear(),t.items.forEach(f=>{!f||f&&f.attributes&&f.attributes.deleted||t.itemFormArray.push(f.formGroup)}),t.itemFormArray.updateValueAndValidity())}addToRecord(t,n,o){!t||!n||!o||(t.fields||(t.fields={}),t.fields[n]=o,t.formGroup&&o.itemFormArray&&t.formGroup.addControl(n+"-items",o.itemFormArray),t.formGroup&&o.formControl&&t.formGroup.addControl(n,o.formControl))}addVardefOnlyField(t,n,o=null){const f=this.fieldBuilder.buildField(t,n,o);return this.addVardefOnlyFieldToRecord(t,n.name,f),f}addVardefOnlyFieldToRecord(t,n,o){!t||!n||!o||(t.fields||(t.fields={}),t.fields[n]=o)}isFieldInitialized(t,n){return!!t.fields[n]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zf),e.\u0275\u0275inject(mv),e.\u0275\u0275inject(E_),e.\u0275\u0275inject(wC),e.\u0275\u0275inject(xC),e.\u0275\u0275inject(SC),e.\u0275\u0275inject(Kr))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Dd=(()=>{class r{constructor(t,n,o){this.fieldManager=t,this.language=n,this.fieldHandlerRegistry=o}buildEmptyRecord(t){return{id:"",module:t,attributes:{id:""},fields:{},formGroup:new Ji.UntypedFormGroup({})}}initFields(t,n){return t.fields||(t.fields={}),t.formGroup||(t.formGroup=new Ji.UntypedFormGroup({})),n.forEach(o=>{o&&o.name&&!t.fields[o.name]&&(o?.vardefBased?this.fieldManager.addVardefOnlyField(t,o,this.language):this.fieldManager.addField(t,o,this.language))}),t.fields}initFieldDefaults(t){t.fields&&Object.entries(t.fields).forEach(([n,o])=>{this.fieldHandlerRegistry.get(t.module,o.type).initDefaultValue(o,t)})}injectParamFields(t,n,o){Object.keys(t).forEach(f=>{const D=o[f];if(Al(D))this.handleLinkTypeRelationship(f,t,o,n);else{const j=D.type||"";let fe=D.id_name||"",vt=D.rname||"";if("relate"===j&&fe===(D.name||""))return void(n.attributes[f]=t[f]);if("parent"===j){const ln={};let Hn="name",Oi="parent_id";const Mr=(o[f+"-group"]??{}).groupFields[f];return Mr&&Mr.rname&&(Hn=Mr.rname),Hn&&(ln[Hn]=t[f]),Oi&&t[Oi]&&(ln.id=t[Oi]),void(n.attributes[f]=ln)}if("relate"===j){const ln={};return vt&&(ln[vt]=t[f]),fe&&t[fe]&&(ln.id=t[fe]),void(n.attributes[f]=ln)}n.attributes[f]=t[f]}})}handleLinkTypeRelationship(t,n,o,f){if("return_relationship"===t){const D=n.return_relationship;if(!D)return;Object.keys(o).forEach(j=>{const fe=o[j];if("link"!==(fe.type||""))return;const vt=fe.relationship||"";if(vt&&vt===D){const ln=fe.name,Hn=fe.module??n.return_module??"";if(!Hn)return;const Oi=n.parent_name;if(!Oi)return;const Lr=fe?.relationshipMetadata?.related_id,to=n[Lr]??"";if(!to)return;f.attributes[ln]=[{id:to,module:Hn,attributes:{id:to,name:Oi}}]}})}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ow))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),LS=(()=>{class r extends lu{constructor(t,n,o,f,D){super(t,f,D),this.typeFormatter=t,this.registry=n,this.recordManager=o,this.logic=f,this.logicDisplay=D}ngOnInit(){super.ngOnInit(),this.initUpdateParentSubscription()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getComponentType(t,n){return this.registry.getDisplayType(this.record&&this.record.module||"default",t,n&&n.displayType||"",this.getMode(),this.field.name)}getAttributes(){const t=[];return this.field.definition.layout.forEach(n=>{!this.field.attributes[n]||"none"===this.field.attributes[n]?.display()||t.push(this.field.attributes[n])}),t}getModule(){return this.record?this.record.module:null}getMode(){return"filter"===this.mode?"edit":this.mode}getDirection(){let t="flex-column";return"inline"===this.field.definition.display&&(t="flex-row"),t}isConfigured(){return this.hasDisplay()&&this.hasLayout()&&this.hasAttributes()}showLabel(t){const n=t.definition||null,o=n.showLabel||null;return!(!n||!o||"hide"===(t.metadata&&t.metadata.labelDisplay||""))&&(o.includes("*")||o.includes(this.mode))}hasAttributes(){return!(!this.field.definition.attributeFields||_a(this.field.definition.attributeFields))}hasLayout(){return!(!this.field.definition.layout||!this.field.definition.layout.length)}hasDisplay(){return!!this.field.definition.display}initUpdateParentSubscription(){this.field.attributes&&Object.keys(this.field.attributes).forEach(t=>{const n=this.field.attributes[t];n.valueChanges$&&this.subs.push(n.valueChanges$.subscribe(o=>{this.setValueOnParent(n,o.valueObject||o.valueList||o.value)}))})}setValueOnParent(t,n){const o=t.valueParent??"field";t.valuePath?(0,k0.A)("record"===o?this.record:this.field,t.valuePath,n):(0,k0.A)("record"===o?this.record.attributes:this.field.valueObject,t.name,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Nd),e.\u0275\u0275directiveInject(Dd),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();const Iw=()=>["edit","create"];function KM(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",1),e.\u0275\u0275elementContainerEnd())}function EC(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"span",7),e.\u0275\u0275text(2,"*"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function Aw(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"label"),e.\u0275\u0275element(1,"scrm-label",6),e.\u0275\u0275template(2,EC,3,0,"ng-container",0),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.labelKey)("module",n.getModule()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null==t?null:t.required())&&e.\u0275\u0275pureFunction0(3,Iw).includes(n.mode))}}function kS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",8),e.\u0275\u0275element(1,"scrm-dynamic-field",9),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("componentType",n.getComponentType(t.type,t.definition))("field",t)("klass",n.klass)("mode",n.getMode())("originalMode",n.originalMode)("record",n.record)("parent",n.parent)("type",t.type)}}function Jy(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3)(1,"span",4),e.\u0275\u0275template(2,Aw,3,4,"label",0),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,kS,2,8,"span",5),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("flex-fill","edit"===n.mode&&"flex-row"===n.getDirection())("align-self-start","flex-row"===n.getDirection()&&t.labelKey&&n.showLabel(t)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.labelKey&&n.showLabel(t)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.type)}}function Ow(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275template(2,Jy,4,6,"div",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("d-flex ",t.getDirection()," justify-content-start align-items-end field-group h-100 composite-field-wrapper"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.getAttributes())}}let Pb=(()=>{class r extends LS{constructor(t,n,o,f,D){super(t,n,o,f,D),this.typeFormatter=t,this.registry=n,this.recordManager=o,this.logic=f,this.logicDisplay=D}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Nd),e.\u0275\u0275directiveInject(Dd),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-composite-field"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[[4,"ngIf"],["labelKey","LBL_BAD_GROUP_FIELD_CONFIG"],["class","field-group-item d-flex flex-column justify-content-end h-100 w-100",3,"flex-fill","align-self-start",4,"ngFor","ngForOf"],[1,"field-group-item","d-flex","flex-column","justify-content-end","h-100","w-100"],[1,"field-group-label","pr-1"],["class","field-group-field pr-1 pb-1 composite-field",4,"ngIf"],[3,"labelKey","module"],[1,"required"],[1,"field-group-field","pr-1","pb-1","composite-field"],[3,"componentType","field","klass","mode","originalMode","record","parent","type"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,KM,2,0,"ng-container",0)(1,Ow,3,4,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",!o.isConfigured()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isConfigured()))},dependencies:[ve.NgForOf,ve.NgIf,Pa,Gu],encapsulation:2})}return r})(),e0=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea,uv]})}return r})();const Bb=[...Hy,fg,e0],T_=[...cg,dg,Pb],Fw={...hh,"grouped-field.list":dg,"grouped-field.detail":dg,"grouped-field.edit":dg,"grouped-field.filter":dg,"composite.list":Pb,"composite.detail":Pb,"composite.edit":Pb,"composite.filter":Pb};let t0=(()=>{class r extends Hf{constructor(){super()}getDefaultMap(){return Fw}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),M_=(()=>{class r{initValidators(t){t&&(t?.formGroup?.clearValidators(),Object.keys(t?.fields??{}).forEach(o=>{const f=t.fields[o];f?.formControl&&(this.initFieldValidators(f),this.initLineItemsValidators(f))}))}resetValidators(t){t&&(t?.formGroup?.clearValidators(),Object.keys(t?.fields??{}).forEach(o=>{const f=t.fields[o];this.resetFieldValidators(f),this.resetLineItemsValidators(f)}))}setFormControlValidators(t,n,o){t?.formControl&&(n?.length&&t.formControl.setValidators(n),o?.length&&t.formControl.setAsyncValidators(o))}resetFormControlValidators(t){t?.formControl&&(t.formControl.clearValidators(),t.formControl.clearAsyncValidators())}initFieldValidators(t){this.resetFormControlValidators(t),this.setFormControlValidators(t,t?.validators??[],t?.asyncValidators??[]);const n=t?.attributes??{};Object.keys(n).forEach(o=>{const f=n[o];this.resetFormControlValidators(f),this.setFormControlValidators(f,f?.validators??[],f?.asyncValidators??[])})}resetFieldValidators(t){this.resetFormControlValidators(t);const n=t?.attributes??{};Object.keys(n).forEach(o=>{this.resetFormControlValidators(n[o])})}initLineItemsValidators(t){if(!t?.itemFormArray)return;const n=t?.itemFormArraySaveValidators??[];n.length&&(t.itemFormArray.clearValidators(),t.itemFormArray.addValidators(n)),(t?.items??[]).forEach(f=>{const D=f?.fields??{};Object.keys(D).forEach(j=>{this.initFieldValidators(D[j])})})}resetLineItemsValidators(t){t?.itemFormArray&&(t.itemFormArray.clearValidators(),(t?.items??[]).forEach(o=>{Object.keys(o?.fields??{}).forEach(D=>{this.resetFieldValidators(t)})}))}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),PS=(()=>{class r extends lu{constructor(t,n,o,f,D,j){super(t,f,j),this.typeFormatter=t,this.registry=n,this.recordManager=o,this.logic=f,this.fieldManager=D,this.logicDisplay=j,this.recordValidationHandler=(0,e.inject)(M_)}ngOnInit(){super.ngOnInit(),this.initUpdateParentSubscription(),this.initItems()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getComponentType(t,n){return this.registry.getDisplayType(this.record&&this.record.module||"default",t,n&&n.displayType||"",this.getMode(),this.field.name)}initItems(){this.field.items=this.field.items||[];const t=this.field.items,n=t&&t.filter(f=>!(f&&f.attributes&&f.attributes.deleted)),o=!!this.field?.definition?.lineItems?.labelOnFirstLine;n.forEach((f,D)=>{this.setAttributeLabelDisplay(f,!o||D<=0)})}initEmptyItem(){this.field.items=this.field.items||[];const t=this.field.items,n=t&&t.filter(o=>!(o&&o.attributes&&o.attributes.deleted));["edit","create"].includes(this.mode)&&!n.length&&this.addEmptyItem()}getItemFields(t){const n=t.fields||{};return Object.keys(n).map(o=>n[o])}removeItem(t){this.fieldManager.removeLineItem(this.field,t);const n=this.getActiveItems();(n?.length??0)&&this.setAttributeLabelOnItem(0,n),this.updateItems(this.field.items),this.triggerLineActionEvents($g.onLineItemRemove)}addEmptyItem(){this.fieldManager.addLineItem(this.field?.definition?.lineItems?.definition||{},this.record,this.field);const n=this.getActiveItems(),o=n?.length??0;o&&(this.setAttributeLabelOnItem(0,n),this.setAttributeLabelOnItem(o-1,n)),this.recordValidationHandler.initLineItemsValidators(this.field),this.triggerLineActionEvents($g.onLineItemAdd)}updateItems(t){this.field.items=t}getModule(){return this.record?this.record.module:null}getMode(){return"filter"===this.mode?"edit":this.mode}getDirection(){let t="flex-column";return"inline"===this.field.definition.display&&(t="flex-row"),t}isConfigured(){return this.hasItemConfig()}isEditable(){return PD(this.mode)}showLabel(t){const n=t.definition||null,o=n.showLabel||null;return!(!n||!o)&&(o.includes("*")||o.includes(this.mode))}getMessageContext(t,n){const o=t&&t.message&&t.message.context||{};return o.module=n&&n.module||"",o}getMessageLabelKey(t){return t&&t.message&&t.message.labelKey||""}getActiveItems(){return(this?.field?.items??[]).filter(n=>!n?.attributes?.deleted)}setAttributeLabelOnItem(t,n){this.setAttributeLabelDisplay(n[t],!this.field?.definition?.lineItems?.labelOnFirstLine||t<=0)}hasItemConfig(){return!!this.field?.definition?.lineItems?.definition}initUpdateParentSubscription(){this.field.attributes&&Object.keys(this.field.attributes).forEach(t=>{const n=this.field.attributes[t];n.valueChanges$&&this.subs.push(n.valueChanges$.subscribe(o=>{this.setValueOnParent(n,o.valueObject||o.valueList||o.value)}))})}setValueOnParent(t,n){t.valuePath?(0,k0.A)(this.field,t.valuePath,n):(0,k0.A)(this.field.valueObject,t.name,n)}setAttributeLabelDisplay(t,n){const o=t.fields||{};Object.keys(o).forEach(f=>{const D=o[f];if("composite"!==D.type)return;const j=D.attributes||{};Object.keys(j).forEach(fe=>{const Ne=j[fe],vt=Ne.metadata||{};vt.labelDisplay=n?"default":"hide",Ne.metadata=vt})})}triggerLineActionEvents(t){const n=this.field?.logic||{};_a(n)||Object.keys(n).forEach(o=>{const D=(n[o]||null)?.params?.triggerOnEvents?.[t];cl(D)&&this.logic.runLogic(this.field,this.mode,this.record)})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(t0),e.\u0275\u0275directiveInject(Dd),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(_p),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();const Vb=r=>({field:r});function n0(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-label",1),e.\u0275\u0275elementContainerEnd())}function TC(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"scrm-dynamic-field",10),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2).$implicit,o=e.\u0275\u0275nextContext(3);e.\u0275\u0275classMapInterpolate2("",t.type," ",t.name,""),e.\u0275\u0275advance(),e.\u0275\u0275property("componentType",o.getComponentType(t.type,t.definition))("field",t)("klass",o.klass)("mode",o.mode)("originalMode",o.originalMode)("record",n)("parent",o.parent)("type",t.type)}}function BS(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",11),2&r){const t=e.\u0275\u0275nextContext(2),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("config",f.getRemoveItemButton(n,o))}}function MC(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6)(1,"div",7),e.\u0275\u0275template(2,TC,2,12,"div",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",9),e.\u0275\u0275template(4,BS,1,1,"scrm-button",4),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",n.getItemFields(t)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.isEditable())}}function IC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,MC,5,2,"div",5),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(t&&t.attributes&&t.attributes.deleted))}}function AC(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",11),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("config",t.getAddItemButton())}}function VS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",13),e.\u0275\u0275element(1,"scrm-dynamic-label",14),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("context",n.getMessageContext(t.value,n.record))("fields",e.\u0275\u0275pureFunction1(3,Vb,n.field))("labelKey",n.getMessageLabelKey(t.value))}}function OC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,VS,2,5,"div",12),e.\u0275\u0275pipe(2,"keyvalue"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind1(2,1,t.field.itemFormArray.errors))}}function jS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,OC,3,3,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field.itemFormArray.invalid)}}function qM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div")(2,"div"),e.\u0275\u0275template(3,IC,2,1,"ng-container",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"div",3),e.\u0275\u0275template(5,AC,1,1,"scrm-button",4),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(6,jS,2,1,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate2("line-items d-flex flex-column ",t.field.type," ",t.field.name,""),e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("d-flex ",t.getDirection()," justify-content-start align-items-end line-item h-100"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.field.items),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.isEditable()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",("edit"===t.mode||"filter"===t.mode)&&t.field.itemFormArray&&t.field.itemFormArray.errors)}}function mh(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",15),e.\u0275\u0275element(2,"div",16),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function FC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,qM,7,10,"ng-container",0)(2,mh,3,0,"ng-container",0),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(null!=t.field&&t.field.loading())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",null==t.field?null:t.field.loading())}}let CT=(()=>{class r extends PS{constructor(t,n,o,f,D,j){super(t,n,o,f,D,j),this.typeFormatter=t,this.registry=n,this.recordManager=o,this.logic=f,this.fieldManager=D,this.logicDisplay=j}ngOnInit(){super.ngOnInit(),this.field.metadata=this?.field?.metadata??{};const t=this?.field?.metadata?.emptyItemInitialized??!1;["create"].includes(this.originalMode)&&!t&&(this.initEmptyItem(),this.field.metadata.emptyItemInitialized=!0)}getAddItemButton(){return{klass:"btn btn-sm btn-outline-secondary m-0 border-0",icon:"plus",onClick:()=>{this.addEmptyItem()}}}getRemoveItemButton(t,n){return{klass:"btn btn-sm btn-outline-secondary m-0 border-0",icon:"minimise",onClick:()=>{this.removeItem(n)}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(t0),e.\u0275\u0275directiveInject(Dd),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(_p),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-line-items-field"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[[4,"ngIf"],["labelKey","LBL_LINE_ITEMS_FIELD_CONFIG"],[4,"ngFor","ngForOf"],[1,"line-item-buttons","d-flex","justify-content-end","mt-1"],[3,"config",4,"ngIf"],["class","d-flex flex-row line-item-entry w-100 align-items-end",4,"ngIf"],[1,"d-flex","flex-row","line-item-entry","w-100","align-items-end"],[1,"flex-grow-1","line-item-entry-composite"],[3,"class",4,"ngFor","ngForOf"],[1,"line-item-entry-buttons","mb-1"],[3,"componentType","field","klass","mode","originalMode","record","parent","type"],[3,"config"],["class","invalid-feedback d-block",4,"ngFor","ngForOf"],[1,"invalid-feedback","d-block"],[3,"context","fields","labelKey"],[1,"dynamic-field"],[1,"flex-grow-1","text-break","rounded","box-loading","skeleton-field-content"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,n0,2,0,"ng-container",0)(1,FC,3,2,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",!o.isConfigured()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isConfigured()))},dependencies:[ve.NgForOf,ve.NgIf,Pa,Gu,xc,Df,ve.KeyValuePipe],encapsulation:2})}return r})();function r0(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-dynamic-field",3),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("componentType",t.componentType)("field",t.field)("klass",t.klass)("mode",t.componentMode)("originalMode",t.mode)("record",t.record)("parent",t.record)("type",t.type)}}function DT(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-line-items-field",4),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("field",t.field)("klass",t.klass)("mode",t.componentMode)("originalMode",t.mode)("record",t.record)("parent",t.record)}}function NC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,r0,1,8,"scrm-dynamic-field",1)(2,DT,1,6,"scrm-line-items-field",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","line-items"!==t.type),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","line-items"===t.type)}}let Dm=(()=>{class r{constructor(t){this.registry=t,this.record=null,this.klass=null,this.class="field",this.map=Fw}ngOnInit(){this.setHostClass()}get componentMode(){let t=this.mode;return"create"===t&&(t="edit"),["edit","filter"].includes(t)&&this.field.readonly&&(t="detail"),t}get componentType(){return this.registry.getDisplayType(this.record&&this.record.module||"default",this.type,this.field.definition&&this.field.definition.displayType||"",this.componentMode,this.field.name)}setHostClass(){const t=[];t.push("field"),this.mode&&t.push("field-mode-"+this.mode),this.type&&t.push("field-type-"+this.type),this.field&&this.field.name&&t.push("field-name-"+this.field.name),this.class=t.join(" ")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(t0))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-field"]],hostVars:2,hostBindings:function(n,o){2&n&&e.\u0275\u0275classMap(o.class)},inputs:{mode:"mode",type:"type",field:"field",record:"record",klass:"klass"},decls:1,vars:1,consts:[[4,"ngIf"],[3,"componentType","field","klass","mode","originalMode","record","parent","type",4,"ngIf"],[3,"field","klass","mode","originalMode","record","parent",4,"ngIf"],[3,"componentType","field","klass","mode","originalMode","record","parent","type"],[3,"field","klass","mode","originalMode","record","parent"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,NC,3,2,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.field&&"none"!==(null==o.field?null:o.field.display()))},dependencies:[ve.NgIf,Gu,CT],encapsulation:2})}return r})();const US=[[["","field-grid-actions",""]],[["","field-grid-special",""]]],jb=["[field-grid-actions]","[field-grid-special]"];function o0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"label",1),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",n.labelClass),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.field.label)}}function s0(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-label",8),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("labelKey",t.field.labelKey)("ngClass",n.labelClass)}}function Ub(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,o0,2,2,"label",6)(2,s0,1,2,"scrm-label",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("pr-3","inline"===n.labelDisplay),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field.label),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.field.label&&t.field.labelKey)}}function $b(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"scrm-field",9),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("flex-grow-1","inline"===n.labelDisplay),e.\u0275\u0275advance(),e.\u0275\u0275property("field",t.field)("klass",n.inputClass)("mode",n.fieldMode)("record",n.record)("type",t.field.type)}}function Nw(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275projection(1),e.\u0275\u0275elementContainerEnd())}function RC(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275projection(1,1),e.\u0275\u0275elementContainerEnd())}function Rw(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1)(1,"div",2),e.\u0275\u0275template(2,Ub,3,4,"div",3)(3,$b,2,7,"div",4)(4,Nw,2,0,"ng-container",5)(5,RC,2,0,"ng-container",5),e.\u0275\u0275elementEnd()()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",n.colClass),e.\u0275\u0275advance(),e.\u0275\u0275classProp("align-items-center","inline"===n.labelDisplay&&!n.colAlignItems)("flex-column","top"===n.labelDisplay)("flex-row","inline"===n.labelDisplay)("justify-content-end",!t.field),e.\u0275\u0275property("ngClass",n.colAlignItems?n.colAlignItems:""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field&&"none"!==(null==t.field?null:t.field.display())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field&&"none"!==(null==t.field?null:t.field.display())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.actionSlot),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.specialSlot)}}function $S(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,Rw,6,14,"div",0),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",n.rowClass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.cols)}}let I_=(()=>{class r extends a_{constructor(t){super(t),this.breakpointObserver=t,this.fieldMode="detail"}ngOnChanges(){this.buildGrid()}buildGrid(){const t=[];if(!this.fields||0===this.fields.length)return void(this.fieldGrid=[]);let n=0,o={cols:[]};t.push(o),this.fields.forEach(f=>{n>=this.colNumber&&(n=0,o={cols:[]},t.push(o)),o.cols.push({field:f}),n++}),this.addSpecialSlots(t),this.fieldGrid=t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(le))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-field-grid"]],inputs:{fields:"fields",record:"record",fieldMode:"fieldMode"},features:[e.\u0275\u0275InheritDefinitionFeature,e.\u0275\u0275NgOnChangesFeature],ngContentSelectors:jb,decls:2,vars:1,consts:[[3,"ngClass",4,"ngFor","ngForOf"],[3,"ngClass"],[1,"d-flex",3,"ngClass"],[3,"pr-3",4,"ngIf"],[3,"flex-grow-1",4,"ngIf"],[4,"ngIf"],[3,"ngClass",4,"ngIf"],[3,"labelKey","ngClass",4,"ngIf"],[3,"labelKey","ngClass"],[3,"field","klass","mode","record","type"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(US),e.\u0275\u0275elementStart(0,"form"),e.\u0275\u0275template(1,$S,2,2,"div",0),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",o.fieldGrid))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,Dm,Pa],encapsulation:2})}return r})(),a0=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea,uv,Oa,dh]})}return r})(),pa=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[Bb,ve.CommonModule,uv,a0]})}return r})(),gv=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,pa,Ea]})}return r})();const A_=[[["","field-grid-actions",""]],[["","field-grid-special",""]]],wT=["[field-grid-actions]","[field-grid-special]"],l0=()=>["edit","create"],wm=r=>({"align-items-center":r});function Lw(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"span",11),e.\u0275\u0275text(2,"*"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function O_(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275element(2,"scrm-action-group-menu",12),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){let t,n;const o=e.\u0275\u0275nextContext(2).$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.adaptor)("buttonGroupClass",null!==(t=null==o.fieldActions?null:o.fieldActions.containerKlass)&&void 0!==t?t:"")("klass",null!==(n=null==o.fieldActions?null:o.fieldActions.klass)&&void 0!==n?n:"")}}function Wb(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",13),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(o.dataSource.getEditAction())}),e.\u0275\u0275element(1,"scrm-image",14),e.\u0275\u0275elementEnd()}}function kw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",6)(2,"div")(3,"strong"),e.\u0275\u0275template(4,Lw,3,0,"ng-container",4),e.\u0275\u0275elementStart(5,"label",7),e.\u0275\u0275text(6),e.\u0275\u0275pipe(7,"uppercase"),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(8,"div",7)(9,"div",8),e.\u0275\u0275element(10,"scrm-field",9),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(11,O_,3,3,"ng-container",4),e.\u0275\u0275elementStart(12,"div"),e.\u0275\u0275template(13,Wb,2,0,"button",10),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275classMapInterpolate1("",null==n?null:n.headerColumnClass," field-layout-field-label-wrapper col-form-label label-container"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",(null==n.field?null:n.field.required())&&e.\u0275\u0275pureFunction0(19,l0).includes(o.config.mode)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",o.labelClass),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(e.\u0275\u0275pipeBind1(7,17,n.field.label)),e.\u0275\u0275advance(2),e.\u0275\u0275classMapInterpolate1("",null==n?null:n.valueColumnClass," d-flex flex-grow-1 field-layout-field-wrapper"),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(20,wm,(null==n?null:n.fieldActions)&&"inline"===(null==n||null==n.fieldActions?null:n.fieldActions.position))),e.\u0275\u0275advance(2),e.\u0275\u0275property("type",n.field.type)("mode",o.config.mode)("klass",o.inputClass)("field",n.field)("record",o.record),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null==n?null:n.fieldActions)&&"inline"===(null!==(t=null==n||null==n.fieldActions?null:n.fieldActions.position)&&void 0!==t?t:"inline")),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!1!==n.field.definition.inline_edit&&!n.field.readonly&&!n.field.definition.readonly&&o.dataSource.inlineEdit&&"detail"===o.config.mode)}}function WS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-action-group-menu",12),e.\u0275\u0275elementContainerEnd()),2&r){let t,n;const o=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.adaptor)("buttonGroupClass",null!==(t=null==o.fieldActions?null:o.fieldActions.containerKlass)&&void 0!==t?t:"")("klass",null!==(n=null==o.fieldActions?null:o.fieldActions.klass)&&void 0!==n?n:"")}}function c0(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275projection(1),e.\u0275\u0275elementContainerEnd())}function Hb(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275projection(1,1),e.\u0275\u0275elementContainerEnd())}function xT(r,v){1&r&&e.\u0275\u0275element(0,"div",15)}function zb(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3),e.\u0275\u0275template(1,kw,14,22,"ng-container",4)(2,WS,2,3,"ng-container",4)(3,c0,2,0,"ng-container",4)(4,Hb,2,0,"ng-container",4)(5,xT,1,0,"div",5),e.\u0275\u0275elementEnd()),2&r){let t;const n=v.$implicit,o=v.index,f=e.\u0275\u0275nextContext(),D=f.$implicit,j=f.index,fe=e.\u0275\u0275nextContext();e.\u0275\u0275classProp("field-column-bordered",D.cols.length>1&&o<D.cols.length-1),e.\u0275\u0275property("ngClass",fe.colClass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.field&&"none"!==n.field.display()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null==n?null:n.fieldActions)&&"vertical"===(null!==(t=null==n||null==n.fieldActions?null:n.fieldActions.position)&&void 0!==t?t:"inline")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.actionSlot),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.specialSlot),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.field&&"none"!==(null==n.field?null:n.field.display())&&j<fe.fieldGrid.length-1)}}function Pw(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,zb,6,8,"div",2),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",n.rowClass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.cols)}}let c=(()=>{class r extends a_{constructor(t){super(t),this.breakpointObserver=t,this.baseColClass={col:!0,"form-group":!0,"m-1":!1,"m-0":!0,"pl-3":!0,"pb-2":!0,"pr-3":!0,"d-flex":!0,"flex-column":!0,"justify-content-between":!0},this.baseRowClass={"form-row":!0,"align-items-stretch":!0}}ngOnInit(){this.subscriptions.push(this.dataSource.getConfig().subscribe(t=>{this.config={...t}})),this.subscriptions.push(this.dataSource.getLayout().subscribe(t=>{this.layout={...t}})),this.subscriptions.push(this.dataSource.getFields().subscribe(t=>{this.fields={...t}})),this.subscriptions.push(this.dataSource.getRecord().subscribe(t=>{this.record={...t}})),super.ngOnInit()}buildGrid(){const t=[];this.fields&&0!==Object.keys(this.fields).length?(this.layout.rows.forEach(n=>{let o={cols:[]};n.cols.forEach((f,D)=>{const fe=this.fields[f.name]||null,Ne=f.fieldActions||null,vt=f.adaptor??null,ln=fe?.useFullColumn??fe?.definition?.useFullColumn??[];let Hn="col-sm-12 col-md-12 col-lg-3",Oi="col-sm-12 col-md-12 col-lg-9";const Lr={xs:"12",sm:"12",md:"12",lg:"3",xl:"3"},to={xs:"12",sm:"12",md:"12",lg:"9",xl:"9"},Mr=ln.reduce((ss,Rs)=>({...ss,[Rs]:!0}),{});ln.length&&(Hn=Object.keys(Lr).map(ss=>Mr[ss]?`col-${ss}-12`:`col-${ss}-${Lr[ss]}`).join(" "),Oi=Object.keys(to).map(ss=>Mr[ss]?`col-${ss}-12`:`col-${ss}-${to[ss]}`).join(" ")),fe?(o.cols.push({field:fe,fieldActions:Ne,adaptor:vt,valueColumnClass:Oi,headerColumnClass:Hn}),1===this.colNumber&&D<n.cols.length-1&&(t.push(o),o={cols:[]})):o.cols.push({})}),o.cols.length<this.colNumber&&this.fillRow(o),t.push(o)}),this.addSpecialSlots(t),this.fieldGrid=t):this.fieldGrid=[]}get colNumber(){return 1===this.sizeMap[this.currentSize]?1:this.config.maxColumns}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(le))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-field-layout"]],inputs:{dataSource:"dataSource"},features:[e.\u0275\u0275InheritDefinitionFeature],ngContentSelectors:wT,decls:2,vars:4,consts:[["class","field-layout-row",3,"ngClass",4,"ngFor","ngForOf"],[1,"field-layout-row",3,"ngClass"],["class","field-layout-col",3,"field-column-bordered","ngClass",4,"ngFor","ngForOf"],[1,"field-layout-col",3,"ngClass"],[4,"ngIf"],["class","field-separation mt-2",4,"ngIf"],[1,"field-layout-field-group-wrapper","form-group","row"],[3,"ngClass"],[1,"flex-grow-1","text-break","field-layout-field-value-wrapper"],[3,"type","mode","klass","field","record"],["type","button","class","record-action-button",3,"click",4,"ngIf"],[1,"required"],[3,"config","buttonGroupClass","klass"],["type","button",1,"record-action-button",3,"click"],["image","pencil",1,"sicon"],[1,"field-separation","mt-2"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(A_),e.\u0275\u0275elementStart(0,"form"),e.\u0275\u0275template(1,Pw,2,2,"div",0),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMapInterpolate1("field-layout ",o.config.mode,""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",o.fieldGrid))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,Dm,Bl,Ph,ve.UpperCasePipe],encapsulation:2})}return r})(),g=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,gv,Vl,hm]})}return r})();class a extends kp{shouldDisplay(v){return!0}checkRecordAccess(v,t=[]){const o=v.store.recordStore.getBaseRecord().acls??[];return!(!o||!o.length)&&this.checkAccess(v.action??null,o,t)}}let u=(()=>{class r extends a{constructor(){super(),this.key="clear",this.modes=["edit"]}run(t){t.store.recordStore.getStaging().fields[t.action.fieldName].formControl.setValue("")}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),x=(()=>{class r extends a{constructor(t){super(),this.clipboard=t,this.key="copy",this.modes=np}run(t){const o=t.store.recordStore.getStaging().fields[t.action.fieldName];this.clipboard.copy(o.value)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Cx))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),I=(()=>{class r extends a{constructor(t,n,o,f,D,j){super(),this.asyncActionService=t,this.processService=n,this.messages=o,this.recordMappers=f,this.baseMapper=D,this.activeFieldsChecker=j,this.key="calculateValueBackend",this.modes=["edit","create"],f.register("default",D.getKey(),D)}run(t){let n=t.store.recordStore.getStaging();const o=n.fields[t.action.fieldName],f=t.action;if(!n||!o)return;const D=f.params&&f.params.activeOnFields||{},j=Object.keys(D),fe=f.params&&f.params.activeOnAttributes||{},Ne=Object.keys(fe),vt=f.params&&f.params.process;if(vt&&this.activeFieldsChecker.isActive(j,n,D,Ne,fe)){const Hn=vt,Oi=this.getBaseRecord(n),Lr={action:Hn,module:n.module??"",record:Oi};o.loading.set(!0),this.processService.submit(Hn,Lr).pipe((0,M.take)(1)).subscribe(to=>{const Mr=to?.data?.value??null;o.loading.set(!1),null!==Mr?this.updateValue(o,Mr.toString(),n):this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")},to=>{o.loading.set(!1),this.messages.addDangerMessageByKey("ERR_FIELD_LOGIC_BACKEND_CALCULATION")})}}getBaseRecord(t){return t?(this.mapRecordFields(t),dr({id:t.id,type:t.type,module:t.module,attributes:t.attributes,acls:t.acls})):null}mapRecordFields(t){const n=this.recordMappers.get(t.module);Object.keys(n).forEach(o=>{n[o].map(t)})}updateValue(t,n,o){t.value=n.toString(),t.formControl.setValue(n),o.formGroup.updateValueAndValidity({onlySelf:!0,emitEvent:!0})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh),e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),K=(()=>{class r extends js{constructor(t,n,o){super(),this.calculate=t,this.clear=n,this.copy=o,t.modes.forEach(f=>this.actions[f][t.key]=t),n.modes.forEach(f=>this.actions[f][n.key]=n),o.modes.forEach(f=>this.actions[f][o.key]=o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(I),e.\u0275\u0275inject(u),e.\u0275\u0275inject(x))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ye=(()=>{class r{constructor(t,n){this.buttonUtils=t,this.config=n,this.activeModal=null,this.defaultButtonGroup={breakpoint:4,wrapperKlass:["modal-buttons"],buttonKlass:["modal-button","btn","btn-sm"],buttons:[]};const o=this.config.getConfigValue("ui");o&&o.modal_button_group_breakpoint&&(this.defaultButtonGroup.breakpoint=o.modal_buttons_collapse_breakpoint)}ngOnInit(){this.config$&&(this.buttonGroup$=this.config$.pipe((0,M.map)(t=>this.mapButtonGroup(t))))}mapButtonGroup(t){const n=(0,wx.A)({...t},dr(this.defaultButtonGroup));return this.mapButtons(n),n}mapButtons(t){const n=t.buttons||[];t.buttons=[],n.length>0&&n.forEach(o=>{const f=this.buttonUtils.addOnClickPartial(o,this.activeModal);t.buttons.push(f)})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(iS),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-modal-button-group"]],inputs:{config$:"config$",activeModal:"activeModal"},decls:1,vars:1,consts:[[3,"config$"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"scrm-button-group",0),2&n&&e.\u0275\u0275property("config$",o.buttonGroup$)},dependencies:[nb],encapsulation:2})}return r})(),Ye=(()=>{class r{constructor(t){this.activeModal=t,this.buttons=[]}ngOnInit(){this.buttonGroup$=(0,i.of)({buttons:this.buttons}),this.closeButton={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.activeModal.close({type:"close-button"})}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ct.NgbActiveModal))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-message-modal"]],inputs:{titleKey:"titleKey",textKey:"textKey",buttons:"buttons"},decls:6,vars:6,consts:[["klass","message-modal",3,"closable","close","title"],["modal-body","",1,"p-3"],[3,"labelKey"],["modal-footer",""],[3,"activeModal","config$"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-modal",0)(1,"div",1)(2,"span"),e.\u0275\u0275element(3,"scrm-label",2),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(4,"div",3),e.\u0275\u0275element(5,"scrm-modal-button-group",4),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275property("closable",!0)("close",o.closeButton)("title",o.titleKey||""),e.\u0275\u0275advance(3),e.\u0275\u0275property("labelKey",o.textKey),e.\u0275\u0275advance(2),e.\u0275\u0275property("activeModal",o.activeModal)("config$",o.buttonGroup$))},dependencies:[qm,Pa,ye],encapsulation:2,data:{animation:[(0,sr.trigger)("modalFade",[(0,sr.transition)("void <=> *",[(0,sr.animate)("800ms")])])]}})}return r})(),$e=(()=>{class r{constructor(t){this.modalService=t}showModal(t,n){const o=this.modalService.open(Ye);o.componentInstance.textKey=t??"LBL_GENERIC_CONFIRMATION",o.componentInstance.buttons=[{labelKey:"LBL_CANCEL",klass:["btn-secondary"],onClick:f=>f.dismiss()},{labelKey:"LBL_PROCEED",klass:["btn-main"],onClick:f=>{n(),f.close()}}]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ct.NgbModal))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ht=(()=>{class r{constructor(t,n,o){this.languageStore=t,this.message=n,this.modalService=o}showSelectModal(t,n=null){const o=this.modalService.open(Py,{size:"xl",scrollable:!0});o.componentInstance.module=t,o.result.then(f=>{if(!f||!f.selection||!f.selection.selected)return;const D=this.getSelectedRecord(f);if(D.id)null!==n&&n(D);else{let j=this.languageStore.getFieldLabel("ERROR_NO_RECORD");this.message.addDangerMessage(j)}})}getSelectedRecord(t){let n="";Object.keys(t.selection.selected).some(f=>(n=f,!0));let o=null;return t.records.some(f=>{if(f&&f.id===n)return o=f,!0}),o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(ct.NgbModal))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class Vt{constructor(v,t,n,o,f,D,j,fe){this.actionManager=v,this.asyncActionService=t,this.message=n,this.confirmation=o,this.language=f,this.selectModalService=D,this.metadata=j,this.appMetadataStore=fe,this.defaultActions={detail:[],list:[],edit:[],create:[],massupdate:[]}}runAction(v,t=null){const n=v&&v.params||{},D=v.params&&v.params.selectModal,j=D&&D.module;n.displayConfirmation?this.confirmation.showModal(n.confirmationLabel||"",()=>{j?this.showSelectModal(D.module,v,t):this.callAction(v,t)}):j?this.showSelectModal(D.module,v,t):this.callAction(v,t)}showSelectModal(v,t,n=null){this.selectModalService.showSelectModal(v,o=>{if(o){const{fields:f,formGroup:D,...j}=o;t.params.modalRecord=j}this.callAction(t,n)})}getActionName(v){return`${v.key}`}parseModeActions(v,t,n=null){if(!v)return[];const o={list:[],detail:[],edit:[],create:[],massupdate:[]};v&&v.length&&v.forEach(D=>{!D.modes||!D.modes.length||D.modes.forEach(j=>{!o[j]&&!D.asyncProcess||o[j].push(D)})}),o.detail=o.detail.concat(this.defaultActions.detail??[]),o.list=o.list.concat(this.defaultActions.list??[]),o.edit=o.edit.concat(this.defaultActions.edit??[]),o.create=o.create.concat(this.defaultActions.create??[]),o.massupdate=o.massupdate.concat(this.defaultActions.massupdate??[]);const f=[];return o[t].forEach(D=>{const j=this.actionManager.getHandler(D,t);if(j){const vt=this.buildActionData(D,n);if(!this.shouldDisplay(j,vt))return;D.status=j.getStatus(vt)||""}if(!j&&!D?.asyncProcess)return;const Ne=this.language.getFieldLabel(D.labelKey,n&&n.module||"");f.push({...D,label:Ne})}),f}shouldDisplay(v,t){return v&&v.shouldDisplay(t)}callAction(v,t=null){v.asyncProcess?this.runAsyncAction(v,t):this.runFrontEndAction(v,t)}runAsyncAction(v,t=null){const n=this.getActionName(v),o=this.getModuleName(t);this.message.removeMessages();const f=this.buildActionInput(v,n,o,t);this.asyncActionService.run(n,f).pipe((0,M.take)(1)).subscribe(D=>{this.afterAsyncAction(n,o,f,D,v,t)})}afterAsyncAction(v,t,n,o,f,D){this.shouldReload(o)&&this.reload(f,o,D),this.reloadMetadata(t,f,o,D)}reloadMetadata(v,t,n,o){const f=[];this.shouldReloadRecentlyViewed(n)&&f.push(this.metadata.typeKeys.recentlyViewed),this.shouldReloadFavorites(n)&&f.push(this.metadata.typeKeys.favorites),f&&f.length&&(this.metadata.reloadModuleMetadata(v,f,!1).pipe((0,M.take)(1)).subscribe(),f.includes(this.metadata.typeKeys.recentlyViewed)&&this.appMetadataStore.load(v,["globalRecentlyViewed"],!1).pipe((0,M.take)(1)).subscribe())}shouldReloadRecentlyViewed(v){return!(!v.data||!v.data.reloadRecentlyViewed)}shouldReloadFavorites(v){return!(!v.data||!v.data.reloadFavorites)}shouldReload(v){return!(!v.data||!v.data.reload)}runFrontEndAction(v,t=null){const n=this.buildActionData(v,t);this.actionManager.run(v,this.getMode(),n)}}const zt={tabs:[],groupedTabs:[],modules:{},userActionMenu:[],quickActions:[],maxTabs:0};let yn=dr(zt),li=null,pr=(()=>{class r{constructor(t){this.recordGQL=t,this.store=new i.BehaviorSubject(yn),this.state$=this.store.asObservable(),this.resourceName="navbar",this.fieldsMetadata={fields:["tabs","groupedTabs","modules","userActionMenu","maxTabs"]},this.tabs$=this.state$.pipe((0,M.map)(n=>n.tabs),(0,M.distinctUntilChanged)()),this.groupedTabs$=this.state$.pipe((0,M.map)(n=>n.groupedTabs),(0,M.distinctUntilChanged)()),this.modules$=this.state$.pipe((0,M.map)(n=>n.modules),(0,M.distinctUntilChanged)()),this.userActionMenu$=this.state$.pipe((0,M.map)(n=>n.userActionMenu),(0,M.distinctUntilChanged)()),this.maxTabs$=this.state$.pipe((0,M.map)(n=>n.maxTabs),(0,M.distinctUntilChanged)()),this.quickActions$=this.state$.pipe((0,M.map)(n=>n.quickActions),(0,M.distinctUntilChanged)()),this.vm$=this.tabs$.pipe((0,i.combineLatestWith)(this.groupedTabs$,this.modules$,this.userActionMenu$,this.maxTabs$,this.quickActions$),(0,M.map)(([n,o,f,D,j,fe])=>({tabs:n,groupedTabs:o,modules:f,userActionMenu:D,maxTabs:j,quickActions:fe})))}clear(){li=null,this.updateState(dr(zt))}clearAuthBased(){this.clear()}load(){return this.getNavigation().pipe((0,M.tap)(t=>{this.updateState({...yn,tabs:t.tabs,groupedTabs:t.groupedTabs,userActionMenu:t.userActionMenu,modules:t.modules,maxTabs:t.maxTabs,quickActions:t?.quickActions??[]})}))}isCached(){return null!==li}set(t){li=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState({...yn,tabs:t.tabs,groupedTabs:t.groupedTabs,userActionMenu:t.userActionMenu,modules:t.modules,maxTabs:t.maxTabs,quickActions:t?.quickActions??[]})}updateState(t){this.store.next(yn=t)}getNavigation(){return null===li&&(li=this.fetch("1").pipe((0,M.shareReplay)(1))),li}fetch(t){return this.recordGQL.fetch(this.resourceName,`/api/navbars/${t}`,this.fieldsMetadata).pipe((0,M.map)(({data:n})=>{let o=null;return n&&n.navbar&&(o={tabs:n.navbar.tabs,groupedTabs:n.navbar.groupedTabs,userActionMenu:n.navbar.userActionMenu,modules:n.navbar.modules,maxTabs:n.navbar.maxTabs,quickActions:n?.navbar?.quickActions??[]}),o}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const si={adminPanel:[]};let hr=dr(si),_o=null,jr=(()=>{class r{constructor(t){this.appStateStore=t,this.store=new i.BehaviorSubject(hr),this.state$=this.store.asObservable(),this.adminPanel$=this.state$.pipe((0,M.map)(n=>n.adminPanel),(0,M.distinctUntilChanged)())}clear(){_o=null,this.updateState(dr(si))}clearAuthBased(){this.clear()}getAdminPanel(){return hr.adminPanel}isCached(){return null!==_o}updateState(t){this.store.next(hr=t)}set(t){_o=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const ao={globalRecentlyViewed:[]};let lo=dr(ao),mo=null,br=(()=>{class r{constructor(){this.store=new i.BehaviorSubject(lo),this.state$=this.store.asObservable(),this.globalRecentlyViewed$=this.state$.pipe((0,M.map)(t=>t.globalRecentlyViewed),(0,M.distinctUntilChanged)())}clear(){mo=null,this.updateState(dr(ao))}clearAuthBased(){this.clear()}getGlobalRecentlyViewed(){return lo.globalRecentlyViewed}isCached(){return null!==mo}updateState(t){this.store.next(lo=t)}set(t){mo=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState({globalRecentlyViewed:t})}addToState(t){const o=this.getGlobalRecentlyViewed().filter(f=>f?.attributes?.item_id!==t?.attributes?.item_id);o.unshift(t),this.updateState({globalRecentlyViewed:o})}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const yo={systemConfig:!1,userPreferences:!1,appStrings:!1,appListStrings:!1,modStrings:!1,themeImages:!1,navigation:!1,moduleMetadata:!1,adminMetadata:!1,globalRecentlyViewed:!1};let ml=dr(yo),Ca=null,oo=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt){this.recordGQL=t,this.metadata=n,this.language=o,this.themeImages=f,this.config=D,this.preferences=j,this.navigation=fe,this.adminMetadataStore=Ne,this.globalRecentlyViewedStore=vt,this.store=new i.BehaviorSubject(ml),this.state$=this.store.asObservable(),this.resourceName="appMetadata",this.fieldsMetadata={fields:["id","_id"]},this.types=["systemConfig","userPreferences","language","themeImages","navigation","moduleMetadata","adminMetadata","globalRecentlyViewed"],this.metadata$=this.state$}clear(){Ca=null,this.updateState(dr(yo))}clearAuthBased(){this.clear()}get(){return ml}load(t="login",n=[],o=!0){const f=this.getNotLoadedTypes();return o=o&&f.length<1,(!n||n.length<1)&&(n=f).push("minimalModuleMetadata"),this.getMetadata(t,n,o).pipe((0,M.tap)(D=>{this.updateState(D)}))}loadModuleMetadata(t="login",n=!0){return this.getMetadata(t,["moduleMetadata"],n=n&&(ml?.moduleMetadata??!1)).pipe((0,M.tap)(f=>{this.updateState(f)}))}getMetadata(t="app",n=[],o=!0){return(!n||n.length<1)&&(n=[...this.types]),(null==Ca||!0!==o)&&(Ca=this.fetch(t,n).pipe((0,M.shareReplay)(1))),Ca}getNotLoadedTypes(){const t=[];return this.isNavigationLoaded()||t.push("navigation"),this.arePreferencesLoaded()||t.push("userPreferences"),this.areSystemConfigsLoaded()||t.push("systemConfig"),this.areAllLanguageStringsLoaded()||t.push("language"),this.areThemeImagesLoaded()||t.push("themeImages"),this.isAdminMetadataLoaded()||t.push("adminMetadata"),this.isGlobalRecentlyViewedLoaded()||t.push("globalRecentlyViewed"),t}areAllLanguageStringsLoaded(){return this.language.areAllCached()}arePreferencesLoaded(){return this.preferences.isCached()}areSystemConfigsLoaded(){return this.config.isCached()}areThemeImagesLoaded(){return this.themeImages.isCached()}isNavigationLoaded(){return this.navigation.isCached()}isAdminMetadataLoaded(){return!!ml.adminMetadata}isGlobalRecentlyViewedLoaded(){return!!ml.globalRecentlyViewed}updateState(t){this.store.next(ml=t)}fetch(t,n=[]){const o={fields:[...this.fieldsMetadata.fields,...n]};return this.recordGQL.fetch(this.resourceName,`/api/app-metadata/${t}`,o).pipe((0,M.catchError)(()=>(0,i.of)({})),(0,M.map)(({data:f})=>{const D=f?.appMetadata,j={...ml};return _a(D)||(this.setConfig(j,D),this.setPreferences(j,D),this.setThemeImages(j,D),this.setNavigation(j,D),this.setLanguages(j,D),this.setModuleMetadata(j,D),this.setAdminMetadata(j,D),this.setGlobalRecentlyViewed(j,D)),j}))}setModuleMetadata(t,n){let o=n?.moduleMetadata??{},f="moduleMetadata";_a(o)&&(o=n?.minimalModuleMetadata??{},f="minimalModuleMetadata"),_a(o)||(t[f]=!0,Object.keys(o).forEach(D=>{if(!_a(o[D]??{})){const fe=this.metadata.mapMetadata(D,o[D]);this.metadata.getModule()!==D?this.metadata.setModuleMetadata(D,fe):this.metadata.isCached(D)||this.metadata.set(D,fe)}}))}setLanguages(t,n){const o=n?.language??{};if(!_a(o)){const f={};f.languageKey=o.id??"",f.appStrings=o?.appStrings?.items??{},f.appListStrings=o?.appListStrings?.items??{},f.modStrings=o?.modStrings?.items??{},t.appStrings=!_a(f.appStrings),t.appListStrings=!_a(f.appListStrings),t.modStrings=!_a(f.modStrings),this.language.set(f.languageKey,f)}}setNavigation(t,n){const o=n?.navigation??{};_a(o)||(t.navigation=!0,this.navigation.set(o))}setThemeImages(t,n){const o=n?.themeImages??{},f=o?.items??{};_a(o)||_a(f)||(t.themeImages=!0,this.themeImages.set(o.id,f))}setPreferences(t,n){const o=n?.userPreferences??{};if(!_a(o)){t.userPreferences=!0;const f=this.mapPreferences(o);this.preferences.set(f)}}setConfig(t,n){const o=n?.systemConfig??{};_a(o)||(t.systemConfig=!0,this.config.set(o))}setAdminMetadata(t,n){const o=n?.adminMetadata??{};_a(o)||(t.adminMetadata=!0,this.adminMetadataStore.set(o))}setGlobalRecentlyViewed(t,n){const o=n?.globalRecentlyViewed??[];o.length?(t.globalRecentlyViewed=!0,this.globalRecentlyViewedStore.set(o)):n?.globalRecentlyViewed&&this.globalRecentlyViewedStore.set(o)}mapPreferences(t){const n={};return Object.keys(t).forEach(o=>{t[o].items&&Object.keys(t[o].items).forEach(f=>{n[f]=t[o].items[f]})}),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t_),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(uh),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(jr),e.\u0275\u0275inject(br))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Ba=(()=>{class r extends Vt{constructor(t,n,o,f,D,j,fe,Ne){super(t,n,o,f,D,j,fe,Ne),this.actionManager=t,this.asyncActionService=n,this.message=o,this.confirmation=f,this.language=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}getActionName(t){return`record-${t.key}`}buildActionInput(t,n,o,f=null){return{action:n,module:o,id:f&&f.record&&f.record.id||"",params:t&&t.params||[]}}static#e=this.\u0275fac=function(n){e.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),Co=(()=>{class r{constructor(t){this.apollo=t}save(t){const n={module:t.module,attributes:dr(t.attributes)};t.id&&(n._id=t.id);const o={mutation:X.gql`
mutation saveRecord($input: saveRecordInput!) {
saveRecord(input: $input) {
record {
attributes
favorite
id
_id
module
acls
}
}
}
`,variables:{input:n}};return this.apollo.mutate(o).pipe((0,M.map)(f=>this.mapToRecord(f)))}mapToRecord(t){return t.data&&t.data.saveRecord&&t.data.saveRecord.record?{id:t.data.saveRecord.record._id,type:t?.data?.saveRecord?.record?.type??"",module:t?.data?.saveRecord?.record?.module??"",attributes:t?.data?.saveRecord?.record?.attributes??[],acls:t?.data?.saveRecord?.record?.acls??[],favorite:t?.data.saveRecord?.record?.favorite??!1}:null}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),us=(()=>{class r{constructor(t){this.apollo=t}fetch(t,n){const o={query:X.gql`
query batchedStatistics($module: String!, $queries: Iterable!){
batchedStatistics(module: $module, queries: $queries) {
_id
id
items
}
}
`,variables:{module:t,queries:n}};return this.apollo.query(o).pipe((0,M.map)(f=>{const D={},fe=(f.data&&f.data.batchedStatistics||{}).items||{},Ne=Object.keys(fe);return Ne&&Ne.length&&Ne.forEach(vt=>{const ln=fe[vt];D[vt||ln._id]={id:ln._id,data:ln.data,metadata:ln.metadata}}),D}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Rr={module:"",query:{},statistic:{id:"",data:{}},loading:!1};let xo=(()=>{class r{constructor(t){this.fetchGQL=t,this.cache$=null,this.internalState=dr(Rr),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.statistic$=this.state$.pipe((0,M.map)(n=>n.statistic),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(n=>n.loading),(0,M.distinctUntilChanged)())}clear(){this.store.unsubscribe(),this.cache$=null}clearAuthBased(){this.clear()}getQuery(){return dr(this.internalState.query)}get context(){return this.internalState.query.context}set context(t){const n=dr(this.internalState.query);n.context=t,this.updateState({...this.internalState,query:n})}init(t,n,o=!0){return this.internalState.module=t,this.updateState({...this.internalState,module:t,query:n}),!1===o?null:this.load()}load(t=!0){return this.updateState({...this.internalState,loading:!0}),this.fetchStatistics(this.internalState.module,this.getQuery(),t).pipe((0,M.map)(n=>this.mapStatistics(n)),(0,M.tap)(n=>{this.addNewState(n)}))}setLoading(t){this.updateState({...this.internalState,loading:t})}setStatistic(t,n,o=!1){if(this.addNewState(n),!o)return;const f={};f[t]=n,this.cache$=(0,i.of)(f).pipe((0,M.shareReplay)(1))}addNewState(t){this.updateState({...this.internalState,statistic:t,loading:!1})}mapStatistics(t){const n=Object.keys(t),o=n&&n.length&&n[0];let f={id:"",data:{}};return o&&(f=t[o]),f}updateState(t){this.store.next(this.internalState=t)}fetchStatistics(t,n,o=!0){const f={};return f[n.key]=n,(null==this.cache$||!1===o)&&(this.cache$=this.fetchGQL.fetch(t,f).pipe((0,M.shareReplay)(1))),this.cache$}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();const Jr={module:"",query:{},statistic:{id:"",data:{}},loading:!1};let No=(()=>{class r extends xo{constructor(t,n){super(t),this.fetchGQL=t,this.fieldManager=n,this.cache$=null,this.internalState=dr(Jr),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.statistic$=this.state$.pipe((0,M.map)(o=>o.statistic),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(o=>o.loading),(0,M.distinctUntilChanged)())}addNewState(t){if(!t.metadata||!t.metadata.dataType)return;const n=this.fieldManager.buildShallowField(t.metadata.dataType,t.data.value);n.metadata={digits:0},this.updateState({...this.internalState,statistic:t,field:n,loading:!1})}updateState(t){super.updateState(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us),e.\u0275\u0275inject(_p))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),Hr=(()=>{class r{constructor(t,n){this.fetchGQL=t,this.fieldManager=n}create(){return new No(this.fetchGQL,this.fieldManager)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us),e.\u0275\u0275inject(_p))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ys=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.appStore=t,this.languageStore=n,this.metadataStore=o,this.navigationStore=f,this.systemConfigStore=D,this.themeImagesStore=j,this.userPreferenceStore=fe,this.appMetadataStore=Ne,this.stateStores={},this.stateStores.appStore=this.buildMapEntry(t,!1),this.stateStores.navigationStore=this.buildMapEntry(f,!0),this.stateStores.languageStore=this.buildMapEntry(n,!0),this.stateStores.metadataStore=this.buildMapEntry(o,!1),this.stateStores.systemConfigStore=this.buildMapEntry(D,!1),this.stateStores.themeImagesStore=this.buildMapEntry(j,!1),this.stateStores.userPreferenceStore=this.buildMapEntry(fe,!0),this.stateStores.appMetadataStore=this.buildMapEntry(Ne,!0)}clear(){Object.keys(this.stateStores).forEach(t=>{this.stateStores[t].store.clear()})}clearAuthBased(){Object.keys(this.stateStores).forEach(t=>{this.stateStores[t].authBased&&this.stateStores[t].store.clearAuthBased()})}clearBackendCacheable(){this.clearAuthBased(),this.systemConfigStore.clear()}buildMapEntry(t,n){return{store:t,authBased:n}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(uh),e.\u0275\u0275inject($a),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Ns=(()=>{class r{constructor(){}calculateRoute(t){const n=window.location.pathname;return n.includes("index.php")&&(t=`${n}/${t}`),t}appendNativeAuth(t){return window.location.pathname.includes("auth")&&(t=`auth/${t}`),t}removeNativeAuth(){let t=window.location.pathname;return t.includes("/auth")&&(t=t.replace("/auth","/")),t=t.replace("//","/"),t}isNativeAuth(){return window.location.pathname.includes("auth")}getNativeOutLogoutUrl(){return"auth/logout"}isLoggedOutPath(){return window.location.pathname.includes("logged-out")}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Ml=(()=>{class r{constructor(t,n){this.listStoreFactory=t,this.recordStoreFactory=n,this.subs=[],this.stores=[],this.storeSubject=new i.BehaviorSubject([]),this.state$=this.storeSubject.asObservable(),this.pageSize=10,this.recordList=t.create(),this.stores$=this.state$,this.storesMap$=this.stores$.pipe((0,M.map)(o=>this.getStoreMap(o)))}clear(){this.subs.forEach(t=>t.unsubscribe())}clearAuthBased(){}getItemMetadata(){return null}getRecordList(){return this.recordList}init(t,n=!0,o=null){let f="list_max_entries_per_record_thread";o&&isFinite(o)&&(f="",this.recordList.setPageSize(o));const D=this.recordList.init(t,n,f);this.pageSize=this.recordList.getPageSize(),this.subs.push(this.recordList.records$.subscribe(j=>{this.initStores(j)})),D&&(D.pipe((0,M.tap)(j=>{this.initStores(j.records)})).pipe((0,M.take)(1)).subscribe(),this.module=t)}load(t=!0){return this.recordList.load(t).pipe((0,M.tap)(n=>{this.initStores(n.records)}))}initStores(t){if(!t)return;const n={},o=[],f=this.getStoreMap(this.stores);t.forEach(j=>{if(!j||!j.id)return;const fe=j.id;if(f[fe]){const Ne=f[fe];return Ne.setRecord(j),n[fe]=Ne,void o.push(Ne)}n[fe]=this.recordStoreFactory.create(),this.getItemMetadata()&&n[fe].setMetadata(this.getItemMetadata()),n[fe].initRecord(j,"detail",!1),o.push(n[fe])}),Object.keys(f).forEach(j=>{n[j]||f[j].destroy()}),this.updateState(o)}updateState(t){this.storeSubject.next(this.stores=t)}getStoreMap(t){const n={};return!t||!t.length||t.forEach(o=>{n[o.getBaseRecord().id]=o}),n}getItemStores(){const t=this.stores??[];return t&&t.length?t:[]}getRecordIds(){const t=[];return!this.stores||!this.stores.length||this.stores.forEach(n=>{t.push(n.getRecordId())}),t}static#e=this.\u0275fac=function(n){e.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();const Nu={module:"",recordId:"",loading:{data:!1,metadata:!1},mode:"detail"};class Rd{constructor(v,t,n,o,f,D){this.appStateStore=v,this.meta=t,this.message=n,this.fieldManager=o,this.language=f,this.storeFactory=D,this.internalState=dr(Nu),this.metadataState=dr({}),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.metadataStore=new i.BehaviorSubject({}),this.metadataState$=this.metadataStore.asObservable(),this.subs=[],this.meta$=this.metadataState$,this.recordStore=D.create(this.getViewFields$()),this.record$=this.recordStore.state$.pipe((0,M.distinctUntilChanged)()),this.stagingRecord$=this.recordStore.staging$.pipe((0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(j=>j.loading.data||j.loading.metadata)),this.mode$=this.state$.pipe((0,M.map)(j=>j.mode)),this.vm$=this.state$}getModuleName(){return this.internalState.module}getRecordId(){return this.internalState.recordId}getViewContext(){return{module:this.getModuleName(),id:this.getRecordId()}}init(v,t,n="detail"){return this.baseInit(v,t,n),this.setMetadataLoading(!0),(0,i.forkJoin)([this.loadMetadata(),this.load()]).pipe((0,M.map)(([f,D])=>D))}initRecord(v,t="detail",n=!0){this.baseInit(v.module,v.id,t),n&&this.loadMetadata().pipe((0,M.take)(1),(0,M.tap)(()=>{this.setRecord(v)})).subscribe()}initStaging(v){const t=dr(this.recordStore.extractBaseRecord(v));this.recordStore.setStaging(t)}setRecord(v,t=!1){const n=dr(this.recordStore.extractBaseRecord(v));this.recordStore.setRecord(n,t)}setMetadata(v){this.updateMetadataState(v),this.setMetadataLoading(!1)}destroy(){this.clear()}clear(){this.updateState(dr(Nu)),this.recordStore.destroy(),this.recordStore=null}clearAuthBased(){this.clear()}getBaseRecord(){return this.recordStore.getBaseRecord()}getMode(){return this.internalState?this.internalState.mode:null}setMode(v){this.updateState({...this.internalState,mode:v})}setDataLoading(v){this.updateState({...this.internalState,loading:{...this.internalState.loading,data:v}})}setMetadataLoading(v){this.updateState({...this.internalState,loading:{...this.internalState.loading,metadata:v}})}save(){return this.setDataLoading(!0),this.recordStore.save().pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_ERROR_SAVING"),(0,i.of)({}))),(0,M.finalize)(()=>{this.setDataLoading(!1)}))}validate(){return this.recordStore.validate()}load(v=!0){return this.setDataLoading(!0),this.recordStore.retrieveRecord(this.internalState.module,this.internalState.recordId,v).pipe((0,M.tap)(t=>{this.updateState({...this.internalState,recordId:t.id,module:t.module})}),(0,M.finalize)(()=>{this.setDataLoading(!1)}))}loadMetadata(v=!0){return this.setMetadataLoading(!0),this.meta.getMetadata(this.internalState.module).pipe((0,M.map)(t=>t.recordView),(0,M.tap)(t=>{this.updateMetadataState(t)}),(0,M.finalize)(()=>{this.setMetadataLoading(!1)}))}updateState(v){this.store.next(this.internalState=v)}updateMetadataState(v){this.metadataStore.next(this.metadataState=v)}getMetadata(){return dr(this.metadataState)}baseInit(v,t,n="detail"){this.updateState({...this.internalState,module:v,recordId:t,mode:n})}}const ru={id:"",type:"",module:"",attributes:{},acls:[]};class wd{constructor(v,t,n,o,f,D,j){this.definitions$=v,this.metadata$=t,this.recordSaveGQL=n,this.recordFetchGQL=o,this.message=f,this.recordManager=D,this.recordMappers=j,this.initFieldDefaults=!1,this.fieldDefaultsInitialized=!1,this.cache$=null,this.internalState=dr(ru),this.stagingState=dr(ru),this.store=new i.BehaviorSubject(this.internalState),this.staging=new i.BehaviorSubject(this.stagingState),this.definitions=[],this.metadata=null,this.subs=[],this.fieldsMetadata={fields:["_id","id","attributes","module","type","acls","favorite"]},this.state$=this.store.asObservable().pipe((0,M.distinctUntilChanged)()),this.staging$=this.staging.asObservable(),this.subs.push(this.state$.subscribe(fe=>{this.updateStaging(fe)})),this.subs.push(v.subscribe(fe=>{this.definitions=fe,this.init(this.internalState)})),t&&this.subs.push(t.subscribe(fe=>{this.setMetadata(fe)}))}init(v,t=!1){const n={...v};this.initFieldDefaults=t,this.initRecord(n),this.updateState(n)}getStaging(){return this.stagingState?this.stagingState:null}setStaging(v){this.initRecord(v),this.staging.next(this.stagingState=v)}setRecord(v,t=!1){this.initFieldDefaults=t,this.initRecord(v),this.updateState(v)}save(){return this.mapStagingFields(),this.recordSaveGQL.save(this.stagingState).pipe((0,M.tap)(v=>{this.initRecord(v),this.updateState(v)}))}validate(){return this.stagingState.formGroup.markAllAsTouched(),this.stagingState?.validationTriggered.set(!0),this.stagingState.formGroup.statusChanges.pipe((0,M.startWith)(this.stagingState.formGroup.status),(0,M.filter)(v=>"PENDING"!==v),(0,M.take)(1),(0,M.map)(v=>"VALID"===v))}resetStaging(){this.updateStaging(this.internalState)}destroy(){this.subs.forEach(v=>v.unsubscribe())}getBaseRecord(){return this.internalState?dr({id:this.internalState.id,type:this.internalState.type,module:this.internalState.module,attributes:this.internalState.attributes,acls:this.internalState.acls}):null}getBaseStaging(){return this.stagingState?(this.mapStagingFields(),dr({id:this.stagingState.id,type:this.stagingState.type,module:this.stagingState.module,attributes:this.stagingState.attributes,acls:this.stagingState.acls})):null}extractBaseRecord(v){const{fields:t,formGroup:n,...o}=v;return{...o}}isDirty(){return!(!this.stagingState||!this.stagingState.formGroup)&&this.stagingState.formGroup.dirty}retrieveRecord(v,t,n=!0){return(null==this.cache$||!1===n)&&(this.cache$=this.fetch(v,t).pipe((0,M.tap)(o=>this.init(o)),(0,M.shareReplay)(1))),this.cache$}updateState(v){this.store.next(this.internalState=v)}updateStaging(v){const t=dr(this.extractBaseRecord(v));this.initRecord(t,this.initFieldDefaults),this.staging.next(this.stagingState=t)}mapStagingFields(){const v=this.recordMappers.get(this.stagingState.module);Object.keys(v).forEach(t=>{v[t].map(this.stagingState)})}initRecord(v,t=!1){this.metadata&&(v.metadata=this.metadata),v?.validationTriggered||(v.validationTriggered=(0,e.signal)(!1)),v.module&&this.definitions&&this.definitions.length>0&&(v.fields=this.recordManager.initFields(v,this.definitions)),t&&(this.recordManager.initFieldDefaults(v),this.fieldDefaultsInitialized=!0)}fetch(v,t){return this.recordFetchGQL.fetch(v,t,this.fieldsMetadata).pipe((0,M.map)(({data:n})=>{const o={type:"",module:"",attributes:{},acls:[]};if(!n)return o;const f=n.record.attributes.id;return f?(o.id=f,o.module=v,o.type=n.record.attributes&&n.record.attributes.object_name,o.attributes=n.record.attributes,o.acls=n.record.acls,o.favorite=n?.record?.favorite??!1,o):(this.message.addDangerMessageByKey("LBL_RECORD_DOES_NOT_EXIST"),o)}),(0,M.catchError)(n=>(0,i.throwError)(n)))}setMetadata(v){v&&(this.metadata=v)}}let jl=(()=>{class r{constructor(t){this.apollo=t}fetch(t,n,o){const D={query:X.gql`
query record($module: String!, $record: String!) {
record(module: $module, record: $record) {
${o.fields.join("\n")}
}
}
`,variables:{module:t,record:n}};return this.apollo.query(D)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Os=(()=>{class r{constructor(t,n,o,f,D,j){this.recordFetchGQL=t,this.recordSaveGQL=n,this.message=o,this.recordManager=f,this.recordMappers=D,this.baseMapper=j,D.register("default",j.getKey(),j)}create(t,n){return new wd(t,n,this.recordSaveGQL,this.recordFetchGQL,this.message,this.recordManager,this.recordMappers)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Cr=(()=>{class r extends Rd{constructor(t,n,o,f,D,j){super(t,n,o,f,D,j),this.appStateStore=t,this.meta=n,this.message=o,this.fieldManager=f,this.language=D,this.storeFactory=j}getViewFields$(){return this.meta$.pipe((0,M.map)(t=>{const n={},o=[],f=t.fields??{};return Object.keys(f).forEach(D=>{f[D]&&(n[D]=f[D])}),t.headerLayout&&t.headerLayout.rows&&t.headerLayout.rows.forEach(D=>{D.cols.forEach(j=>{j.field&&(n[j.field.name]=j.field)})}),t.bodyLayout&&t.bodyLayout.rows&&t.bodyLayout.rows.forEach(D=>{D.cols.forEach(j=>{j.field&&(n[j.field.name]=j.field)})}),Object.keys(n).forEach(D=>{o.push(n[D])}),o}))}initRecord(t,n="detail",o=!0,f=!1){super.initRecord(t,n,o),this.setRecord(t,f)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Os))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),So=(()=>{class r{constructor(t,n,o,f,D,j){this.appStateStore=t,this.meta=n,this.message=o,this.fieldManager=f,this.language=D,this.storeFactory=j}create(){return new Cr(this.appStateStore,this.meta,this.message,this.fieldManager,this.language,this.storeFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Os))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Po=(()=>{class r extends Ml{constructor(t,n){super(t,n),this.listStoreFactory=t,this.recordStoreFactory=n,this.autoRefreshEnabled=!0,this.$loading=this.recordList.loading$}init(t,n=!0,o=null){super.init(t,n,o),this.autoRefreshEnabled=!0}setFilters(t){let n=this.recordList.criteria;if(n={...n,...t},t&&t.orderBy){let o=hp.DESC;t.sortOrder&&"ASC"===String(t.sortOrder).toUpperCase()&&(o=hp.ASC),this.recordList.updateSorting(t.orderBy,o,!1)}return this.recordList.updateSearchCriteria(n,!1),this.load(!1).pipe((0,M.map)(o=>o.records))}getItemMetadata(){return this.itemMetadata}getListMetadata(){return this.listMetadata}setItemMetadata(t){return this.itemMetadata=t}setListMetadata(t){return this.listMetadata=t}allLoaded(){const t=this.recordList.getPagination();return!!t&&t.pageSize>=t.total}loadMore(t=null){t||(t=this.pageSize);let f=(this.recordList.getPagination().pageSize||0)+t;this.recordList.setPageSize(f),this.recordList.updatePagination(0)}reload(){this.recordList.updatePagination(0)}getViewContext(){return{module:this.module,ids:this.getRecordIds()}}initAutoRefresh(t,n,o,f){const D=new Date,j=new Date(D.getFullYear(),D.getMonth(),D.getDate(),D.getHours(),D.getMinutes()+1),fe=this.getAutoRefreshTime(t,n,o);return(0,i.timer)(j,fe).pipe((0,M.takeWhile)(()=>this.autoRefreshEnabled),(0,M.tap)(()=>{this.load(!1).subscribe(()=>{f&&f()})}))}disableAutoRefresh(){this.autoRefreshEnabled=!1}getAutoRefreshTime(t,n,o){let f=6e4*t;return 0===n&&0===o?f:f+this.getRandomDeviation(n,o)}getRandomDeviation(t,n){return t=Math.ceil(t),n=Math.floor(n),1e3*Math.floor(Math.random()*(n-t+1)+t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(So))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),wi=(()=>{class r{constructor(t,n){this.recordListFactory=t,this.recordStoreFactory=n}create(){return new Po(this.recordListFactory,this.recordStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(So))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ha=(()=>{class r{constructor(t,n,o,f,D,j){this.systemConfig=t,this.storeFactory=n,this.processService=o,this.messages=f,this.language=D,this.dynamicLabels=j}getOptions(){return this.systemConfig.getConfigValue("ui")?.notifications??null}initStore(){const t=this.getOptions(),n={};this.setupListActions(n,t),this.setupItemConfig(n,t);const o=this.storeFactory.create();o.setItemMetadata(n.itemConfig.metadata),o.setListMetadata({actions:n.listActions});const f={orderBy:t?.filters?.orderBy??"date_entered",sortOrder:t?.filters?.sortOrder??"asc",preset:{type:"alerts"}};return o.init(t.module,!1,t?.pageSize??null),o.setFilters(f).pipe((0,M.take)(1)).subscribe(),o}setupListActions(t,n){t.listActions=n?.listActions??[],null!==(n?.collapseListActions??null)&&(t.collapseListActions=n.collapseListActions)}setupItemConfig(t,n){t.itemConfig={collapsible:n?.item?.collapsible??!1,collapseLimit:n?.item?.collapseLimit??null,klass:n?.item?.itemClass??"",buttonClass:n?.item?.buttonClass??"",buttonGroupClass:n?.item?.buttonGroupClass??"",dynamicClass:n?.item?.dynamicClass??[],containerClass:n?.item?.containerClass??"",flexDirection:n?.item?.flexDirection??"",metadata:{}},this.setupItemMetadata(t.itemConfig.metadata,n.item.layout,n)}setupItemMetadata(t,n,o){n&&n.header&&(t.headerLayout=dr(n.header)),n&&n.body&&(t.bodyLayout=dr(n.body)),n&&n.actions&&(t.actions=dr(n.actions)),o?.item&&o?.item?.fields&&(t.fields=dr(o.item.fields)),null!==(o?.item?.collapseActions??null)&&(t.collapseActions=o?.item?.collapseActions)}markNotificationsAsRead(t){const n={action:"record-thread-list-mark-as-read",module:t.module??"alerts",ids:t.getRecordIds()};return this.processService.submit("record-thread-list-mark-as-read",n).pipe((0,M.tap)(o=>{let f="addSuccessMessageByKey";"error"===o.status&&(f="addDangerMessageByKey"),o.messages&&o.messages.forEach(D=>{this.messages[f](D)}),t.getItemStores().forEach(D=>{const fe=(D?.recordStore?.getStaging()??{})?.fields.is_read??null;null!=fe&&(fe.value="true")})}),(0,M.catchError)(o=>{throw this.messages.addDangerMessageByKey("ERR_NOTIFICATIONS_MARK_AS_READ"),o}))}onLoadMore(t){(0,i.timer)(1500).pipe((0,M.take)(1)).subscribe(()=>{t.markNotificationsAsRead()})}onRefresh(t,n){const o=t.getRecordList().getMeta().unreadCount;let f=n.getNotificationsUnreadTotal();if(o>f){let D=(o-f).toString();const j=this.language.getFieldLabel("LBL_NEW_NOTIFICATION"),fe=this.dynamicLabels.parse(j,{unread:D},{});this.messages.addSuccessMessage(fe)}n.setNotificationsUnreadTotal(o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(wi),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(rb))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const dn={notificationsEnabled:!1,notificationsTotal:0,notificationsUnreadTotal:0};let Ol=dr(dn),Fa=null,hs=(()=>{class r{constructor(t,n,o){this.appStateStore=t,this.configs=n,this.notificationService=o,this.store=new i.BehaviorSubject(Ol),this.state$=this.store.asObservable(),this.notificationPageSize=0,this.notificationsUnreadTotal$=this.state$.pipe((0,M.map)(f=>f.notificationsUnreadTotal),(0,M.distinctUntilChanged)()),this.notificationsTotal$=this.state$.pipe((0,M.map)(f=>f.notificationsTotal),(0,M.distinctUntilChanged)()),this.notificationsEnabled$=this.state$.pipe((0,M.map)(f=>f.notificationsEnabled),(0,M.distinctUntilChanged)())}clear(){Fa=null,this.updateState(dr(dn))}clearAuthBased(){this.clear(),this.notificationStore.clear(),this.notificationStore=null}init(){this.appStateStore.isLoggedIn()&&this.initNotifications()}initNotifications(){this.notificationStore||(this.notificationStore=this.notificationService.initStore())}enableNotifications(){this.initNotifications(),this.updateState({...Ol,notificationsEnabled:!0})}disableNotifications(){this.disableNotificationAutoRefresh(),this.updateState({...Ol,notificationsEnabled:!1,notificationsTotal:0,notificationsUnreadTotal:0})}areNotificationsEnabled(){return Ol.notificationsEnabled}refreshNotifications(){this.areNotificationsEnabled()&&this.notificationStore.load(!1).pipe((0,M.take)(1)).subscribe(()=>{this.notificationService.onRefresh(this.notificationStore,this)})}markNotificationsAsRead(){if(!this.areNotificationsEnabled())return;this.notificationStore.getRecordList().pagination$.pipe((0,M.take)(1),(0,M.tap)(o=>this.notificationPageSize=o.pageSize),(0,M.tap)(o=>this.setNotificationsTotal(o.total))).subscribe();let t=this.notificationStore.getRecordList().records.filter(o=>!1===o.attributes.is_read).length,n=this.getNotificationsTotal()-this.getNotificationsUnreadTotal();(0,i.timer)(500).pipe((0,M.take)(1)).subscribe(()=>{this.getNotificationsUnreadTotal()>0&&(this.notificationPageSize>n||t>0)&&this.notificationService.markNotificationsAsRead(this.notificationStore).subscribe(o=>{this.setNotificationsUnreadTotal(o?.data?.unreadCount??0),this.setRecordAsReadTrue()})})}conditionalNotificationRefresh(t=""){if(!this.areNotificationsEnabled())return;const n=this.configs.getUi("notifications_reload_actions")??null,o=this.getModule();if(t||(t=this.getView()),!n||!o)return;const f=n[o];f&&f.length&&f.some(j=>"any"===j||j===t)&&this.refreshNotifications()}disableNotificationAutoRefresh(){this.notificationStore.disableAutoRefresh()}setRecordAsReadTrue(){this.notificationStore.getRecordList().records.forEach(t=>{t.attributes.is_read||(t.attributes.is_read=!0)})}setNotificationsUnreadTotal(t){this.updateState({...Ol,notificationsUnreadTotal:t})}setNotificationsTotal(t){this.updateState({...Ol,notificationsTotal:t})}getNotificationsTotal(){return Ol.notificationsTotal}getNotificationsUnreadTotal(){return Ol.notificationsUnreadTotal}getNotificationStore(){return this.notificationStore}getModule(){return this.appStateStore.getModule()}getView(){return this.appStateStore.getView()}onLogin(){}onLogout(){this.disableNotifications(),this.clearAuthBased()}isCached(){return null!==Fa}updateState(t){this.store.next(Ol=t)}set(t){Fa=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(ha))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Ka=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){this.http=t,this.router=n,this.message=o,this.stateManager=f,this.languageStore=D,this.appStateStore=j,this.localStorage=fe,this.configs=Ne,this.baseRoute=vt,this.notificationStore=ln,this.isUserLoggedIn=new i.BehaviorSubject(!1),this.currentUserSubject=new i.BehaviorSubject({}),this.currentUser$=this.currentUserSubject.asObservable().pipe((0,M.distinctUntilChanged)())}isLoggedIn(){return this.isUserLoggedIn.value}getCurrentUser(){return this.currentUserSubject.value}setCurrentUser(t){this.appStateStore.setCurrentUser(t),this.currentUserSubject.next(t),this.isUserLoggedIn.next(!0)}doLogin(t,n,o,f,D){let j="login";j=this.baseRoute.appendNativeAuth(j),j=this.baseRoute.calculateRoute(j);const fe=new Op.HttpHeaders({"Content-Type":"application/json"});return this.http.post(j,{username:t,password:n},{headers:fe}).subscribe(Ne=>{if("false"===Ne?.two_factor_complete)return this.isUserLoggedIn.next(!1),void D(Ne);this.baseRoute.isNativeAuth()&&(window.location.href=this.baseRoute.removeNativeAuth()),this.appStateStore.updateInitialAppLoading(!0),o(Ne),this.isUserLoggedIn.next(!0),this.setCurrentUser(Ne),setTimeout(()=>{this.notificationStore.enableNotifications(),this.notificationStore.refreshNotifications()},2e3)},Ne=>{f(Ne)})}logout(t="LBL_LOGOUT_SUCCESS",n=!0){this.appStateStore.updateLoading("logout",!0,!1);const o=this.configs.getConfigValue("logout")??[];let f=o?.path??"logout",D=cl(o?.redirect??!1);const j=o?.after_logout_path??"./";this.baseRoute.isNativeAuth()&&(f=this.baseRoute.getNativeOutLogoutUrl(),D=!1),f=this.baseRoute.calculateRoute(f);const fe=new Op.HttpParams,Ne=(new Op.HttpHeaders).set("Content-Type","text/plain; charset=utf-8");this.appStateStore.getActiveRequests()<1?this.callLogout(f,fe,Ne,n,t,D,j):this.appStateStore.activeRequests$.pipe((0,M.filter)(vt=>vt<1),(0,M.take)(1)).subscribe(()=>{this.callLogout(f,fe,Ne,n,t,D,j)})}enable2fa(){let t="./2fa/enable";t=this.baseRoute.appendNativeAuth(t),t=this.baseRoute.calculateRoute(t);const n=new Op.HttpHeaders({"Content-Type":"application/json"});return this.http.get(t,{headers:n})}disable2fa(){let t="./2fa/disable";t=this.baseRoute.appendNativeAuth(t),t=this.baseRoute.calculateRoute(t);const n=new Op.HttpHeaders({"Content-Type":"application/json"});return this.http.get(t,{headers:n})}check2fa(t){let n="./2fa_check";n=this.baseRoute.appendNativeAuth(n),n=this.baseRoute.calculateRoute(n);const o=new Op.HttpHeaders({"Content-Type":"application/json; charset=utf-8"});return this.http.post(n,{_auth_code:t},{headers:o})}finalize2fa(t){let n="./2fa/enable-finalize";n=this.baseRoute.appendNativeAuth(n),n=this.baseRoute.calculateRoute(n);const o=new Op.HttpHeaders({"Content-Type":"application/json"});return JSON.stringify({_auth_code:t}),this.http.post(n,{auth_code:t},{headers:o})}setLanguage(t){this.languageStore.setSessionLanguage().pipe((0,M.catchError)(()=>(0,i.of)({}))).subscribe(()=>{if(t&&t.redirect&&t.redirect.route)return void this.router.navigate([t.redirect.route],{queryParams:t.redirect.queryParams??{}}).then();if(this.appStateStore.getPreLoginUrl())return void this.router.navigateByUrl(this.appStateStore.getPreLoginUrl()).then(()=>{this.appStateStore.setPreLoginUrl("")});const n=this.configs.getHomePage();this.router.navigate(["/"+n]).then()}),this.configs.getConfigValue("login_language")&&this.languageStore.setUserLanguage().subscribe()}callLogout(t,n,o,f,D,j,fe){this.resetState(),j?window.location.href=t:this.http.post(t,n.toString(),{headers:o,responseType:"text"}).pipe((0,M.take)(1),(0,M.catchError)(Ne=>(this.message.log("Logout failed"),(0,i.throwError)(Ne))),(0,M.finalize)(()=>{this.appStateStore.updateInitialAppLoading(!0),this.appStateStore.updateLoading("logout",!1,!1),this.appStateStore.setCurrentUser(null),this.stateManager.clearAuthBased(),this.configs.clear(),!0===f&&(window.location.href=fe)})).subscribe(()=>{this.message.log("Logout success"),Ud(D)||this.message.addSuccessMessageByKey(D)},()=>{this.message.log("Error on logout"),Ud(D)||this.message.addSuccessMessageByKey(D)})}resetState(){this.stateManager.clearAuthBased(),this.localStorage.clear(),this.isUserLoggedIn.next(!1)}fetchSessionStatus(){let t="session-status";t=this.baseRoute.appendNativeAuth(t),t=this.baseRoute.calculateRoute(t);const n=(new Op.HttpHeaders).set("Content-Type","text/plain; charset=utf-8");return this.http.get(t,{headers:n})}authorizeUserSession(t,n){if(this.isUserLoggedIn.value&&!0!==t.data.checkSession)return(0,i.of)(!0);let o=this.getSessionExpiredRoute();const f=this.sessionExpiredRedirect(),D=this.router.parseUrl(o);return this.fetchSessionStatus().pipe((0,M.take)(1),(0,M.map)(j=>{if(this.appStateStore.setLoginWizardComplete(j.appStatus.loginWizardCompleted??!1),j&&!1===j.appStatus.installed)return this.router.parseUrl("install");if(j&&!0===j.active){const Ne=!!this.appStateStore.getCurrentUser();if(this.setCurrentUser(j),Ne||this.languageStore.appStrings$.pipe((0,M.filter)(vt=>vt&&!_a(vt)),(0,M.tap)(()=>{setTimeout(()=>{this.notificationStore.enableNotifications(),this.notificationStore.refreshNotifications()},2e3)}),(0,M.take)(1)).subscribe(),j?.redirect?.route&&!n.url.includes(j.redirect.route)){const vt=this.router.parseUrl(j.redirect.route);return vt.queryParams=j?.redirect?.queryParams??{},vt}return!0}return this.appStateStore.setPreLoginUrl(n.url),this.resetState(),f?(this.handleSessionExpiredRedirect(),!1):D}),(0,M.catchError)(()=>f?(this.handleSessionExpiredRedirect(),(0,i.of)(!1)):(this.logout("LBL_SESSION_EXPIRED",!1),(0,i.of)(D))),(0,M.tap)(j=>{!0===j&&this.isUserLoggedIn.next(!0)}))}getSessionExpiredRoute(){return(this.configs.getConfigValue("session-expired")??[])?.path??"Login"}handleInvalidSession(t){this.sessionExpiredRedirect()?this.handleSessionExpiredRedirect():this.logout(t)}handleSessionExpiredRedirect(){window.location.href=this.getSessionExpiredRoute()}sessionExpiredRedirect(){const t=this.configs.getConfigValue("session-expired")??[];return cl(t?.redirect??!1)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Op.HttpClient),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(ys),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Ns),e.\u0275\u0275inject(hs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),mg=(()=>{class r extends h_{constructor(t){super(t),this.apollo=t}get(t,n,o,f){return super.get(t,n,o,f)}mapRecord(t){if(!t)return t;t.key=t.id||t.attributes&&t.attributes.id||"";const n=t.attributes&&t.attributes&&t.attributes.contents||null;if(n){const o={...t};return o.criteria=n,o}return t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Du=(()=>{class r extends mw{constructor(t,n,o,f,D,j,fe,Ne){super(t,n,o,f,D,Ne),this.listGQL=t,this.configs=n,this.preferences=o,this.language=f,this.message=D,this.auth=j,this.moduleNameMapper=fe,this.localStorageService=Ne,this.moduleName="saved-search",this.filterFields={module:"search_module",user:"assigned_user_id"}}init(t){const n=super.init(this.moduleName,!1);return this.initCriteria(t),n}load(t=!0){return super.load(t)}getFilters(){return this.records}addFilter(t){let n=!0;const f=[];this.records.forEach(D=>{if(D.id===t.id)return f.push(t),void(n=!1);f.push(D)}),n&&f.push(t),this.updateState({...this.internalState,records:f})}removeFilter(t){if(!t||!t.id)return;const o=[];this.records.forEach(f=>{f.id!==t.id&&o.push(f)}),this.updateState({...this.internalState,records:o})}initCriteria(t){const n=this.criteria;n.filters[this.filterFields.module]={field:this.filterFields.module,operator:"=",values:[this.moduleNameMapper.toLegacy(t)]},n.filters[this.filterFields.user]={field:this.filterFields.user,operator:"=",values:[this.auth.getCurrentUser().id]},this.updateSearchCriteria(n,!1)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(mg),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),Bw=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.listGQL=t,this.configs=n,this.preferences=o,this.language=f,this.message=D,this.auth=j,this.moduleNameMapper=fe,this.localStorageService=Ne}create(){return new Du(this.listGQL,this.configs,this.preferences,this.language,this.message,this.auth,this.moduleNameMapper,this.localStorageService)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(mg),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),F_=(()=>{class r{constructor(t,n,o,f,D,j){this.listStoreFactory=t,this.languageStore=n,this.statisticsStoreFactory=o,this.filterListStoreFactory=f,this.meta=D,this.preferences=j,this.show=!1,this.panelCollapseMode=(0,e.signal)("closable"),this.showFilter=(0,e.signal)(!1),this.filterApplied=!1,this.preferenceKey=null,this.subs=[],this.recordList=t.create(),this.filterList=this.filterListStoreFactory.create(),this.criteria$=this.recordList.criteria$,this.statistics={},this.metadataState=new i.BehaviorSubject({}),this.metadata$=this.metadataState.asObservable(),this.loading$=this.recordList.loading$}getTitle(){let t=this.languageStore.getFieldLabel(this.metadata.title_key,this.parentModule);if(!t){const n=this.languageStore.getAppListString("moduleList");t=n&&n[this.metadata.title_key]||""}return t}getIcon(){return this.metadata.icon}clear(){this.metadataState.unsubscribe(),this.metadataState=null,this.recordList.clear(),this.recordList=null,this.subs.forEach(t=>t.unsubscribe())}clearAuthBased(){this.recordList.clearAuthBased()}searchFilter(){this.filterApplied=!0,this.showFilter.set(!1)}init(t,n,o,f=null){this.parentModule=t,this.parentId=n,this.metadata=o,this.metadataState.next(this.metadata);const D=this.meta.getMetadata(o.module).pipe((0,M.tap)(()=>{this.recordList.load().pipe((0,M.take)(1)).subscribe()}));this.searchMetadata$=D.pipe((0,M.map)(fe=>fe.search));const j=this.initSearchCriteria(this.parentModule,this.parentId,o);this.recordList.init(o.module,!1,"list_max_entries_per_subpanel",j),this.initStatistics(o,t,n),f&&(this.parentRecord$=f,this.parentRecord$.subscribe(fe=>this.parentRecord=fe))}setFilters(t,n=!0){this.recordList.setFilters(t,n,null)}isAnyFilterApplied(){return this.hasActiveFilter()||!this.areAllCurrentCriteriaFilterEmpty()}hasActiveFilter(){const t=this.recordList.criteria;if(t)return!1;const n=Object.keys(t)??[];if(!n||!n.length)return!1;if(n.length>1)return!0;const o=t[n[0]];return o.key&&""!==o.key&&"default"!==o.key}areAllCurrentCriteriaFilterEmpty(){return Object.keys(this.getFilters()??{}).every(t=>""===this.getFilters()[t].operator)}getFilters(){return this.recordList?.criteria?.filters??{}}load(t=!0){return this.recordList.load(t)}getStatistic(t){return this.statistics[t]?this.statistics[t]:null}resetFilters(t=!0){this.recordList.resetFilters(t)}clearFilter(){this.resetFilters(),this.filterApplied=!1,this.showFilter.set(!1)}initSearchCriteria(t,n,o){const f=o?.sort_order??"desc",D=o?.sort_by??"";return{key:"default",module:"saved-search",attributes:{contents:""},criteria:{name:"default",filters:{},preset:{type:"subpanel",params:{subpanel:o?.name,parentModule:t,parentId:n}},sortOrder:f,orderBy:D}}}loadStatistics(t,n=!0){return this.statistics[t]?this.statistics[t].load(n):null}loadAllStatistics(t=!0){if(!this.statistics||!Object.keys(this.statistics).length)return null;const n=[];return Object.keys(this.statistics).forEach(o=>{this.statistics[o]&&n.push(this.loadStatistics(o,t))}),(0,i.forkJoin)(n)}shouldBatchStatistic(){const t=this.metadata||{};return!(t.subpanelWidget&&t.subpanelWidget.batch&&!1===t.subpanelWidget.batch)}setStatisticsLoading(t,n){this.statistics[t]&&this.statistics[t].setLoading(n)}setAllStatisticsLoading(t){!this.statistics||!Object.keys(this.statistics).length||Object.keys(this.statistics).forEach(n=>{this.statistics[n]&&this.setStatisticsLoading(n,t)})}setStatistics(t,n,o=!1){this.statistics[t]&&this.statistics[t].setStatistic(t,n,o)}getStatisticQuery(t){return this.statistics[t].getQuery()}getAllStatisticQuery(){if(!this.statistics||!Object.keys(this.statistics).length)return{};const t={};return Object.keys(this.statistics).forEach(n=>{this.statistics[n]&&(t[n]=this.getStatisticQuery(n))}),t}getWidgetLayout(){const t=this.metadata;if(!(t&&t.subpanelWidget&&t.subpanelWidget.options&&t.subpanelWidget.options.subpanelWidget))return{rows:[]};const n=dr(t.subpanelWidget.options.subpanelWidget);return(!n.rows||!n.rows.length)&&(n.rows={}),n}toggleFilter(){return this.showFilter.set(!this.showFilter()),this.showFilter()}initStatistics(t,n,o){this.getWidgetLayout().rows.forEach(D=>{!D.cols||!D.cols.length||D.cols.forEach(j=>{!j.statistic||"string"!=typeof j.statistic||(this.initStatistic(j.statistic,t,n,o),j.store=this.statistics[j.statistic])})})}initStatistic(t,n,o,f){this.statistics[t]=this.statisticsStoreFactory.create(),this.statistics[t].init(n.module,{key:t,context:{module:o,id:f},params:{subpanel:n.name}},!1)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Hr),e.\u0275\u0275inject(Bw),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),Gb=(()=>{class r{constructor(t,n,o,f,D,j){this.listStoreFactory=t,this.languageStore=n,this.statisticsStoreFactory=o,this.filterListStoreFactory=f,this.meta=D,this.preferences=j}create(){return new F_(this.listStoreFactory,this.languageStore,this.statisticsStoreFactory,this.filterListStoreFactory,this.meta,this.preferences)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Hr),e.\u0275\u0275inject(Bw),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),LC=(()=>{class r{constructor(t,n,o,f,D){this.appStateStore=t,this.languageStore=n,this.navigationStore=o,this.moduleNavigation=f,this.metadataStore=D,this.appState$=this.appStateStore.vm$,this.language$=this.languageStore.vm$,this.navigation$=this.navigationStore.vm$,this.module$=this.appState$.pipe((0,i.combineLatestWith)(this.navigation$),(0,M.map)(([j,fe])=>this.moduleNavigation.getModuleInfo(j.module,fe))),this.appData$=this.appState$.pipe((0,i.combineLatestWith)(this.module$,this.language$,this.navigation$),(0,M.map)(([j,fe,Ne,vt])=>(this.appData={appState:j,module:fe,language:Ne,navigation:vt},this.appData))),this.metadata$=D.metadata$.pipe((0,M.tap)(j=>{this.metadata=j}))}clear(){}clearAuthBased(){this.clear()}get appState(){return this.appData.appState?this.appData.appState:{}}get module(){return this.appData.module}get language(){return this.appData.language?this.appData.language:{appStrings:{},appListStrings:{},modStrings:{},languageKey:""}}get appStrings(){return this.language.appStrings}get appListStrings(){return this.language.appListStrings}get modStrings(){return this.language.modStrings}get navigation(){return this.appData.navigation}get searchMeta(){return this.metadata.search?this.metadata.search:{layout:{basic:{},advanced:{}}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),N_=(()=>{class r{constructor(t){this.fetchGQL=t}fetch(t,n){return this.fetchGQL.fetch(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class ST extends kp{shouldDisplay(v){return!0}}let HS=(()=>{class r extends ST{constructor(){super(),this.key="displayType",this.modes=["edit","detail","list","create","massupdate","filter"]}run(t,n){const o=t.record;if(!o||!t.field)return!0;const D=n.params&&n.params.activeOnFields||{},j=Object.keys(D),fe=n.params&&n.params.activeOnAttributes||{},Ne=Object.keys(fe);return!j.length&&!Ne.length||this.isActive(j,o,D,Ne,fe)}isActive(t,n,o,f,D){let j=!0;return(0,wt.isEmpty)(o)||(j=this.areFieldsActive(t,n,o)),(0,wt.isEmpty)(D)||(j=j&&this.areAttributesActive(f,n,D)),j}areAttributesActive(t,n,o){return t.every(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f]&&Object.keys(o[f]);if(j&&fe&&fe.length)return fe.some(Ne=>{const vt=o[f][Ne],ln=j.attributes&&j.attributes[Ne];if(vt&&vt.length&&ln)return this.isValueActive(ln,vt)})})}areFieldsActive(t,n,o){return t.every(f=>{const j=n.fields&&n.fields[f]||null,fe=o[f];return!(j&&fe&&fe.length)||this.isValueActive(j,fe)})}isValueActive(t,n){let o=!1;return t.valueList&&t.valueList.length?(t.valueList.some(f=>n.some(D=>{if(D===f)return o=!0,!0})),o):(Al(t.value)||n.some(f=>{f===t.value&&(o=!0)}),o)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),R_=(()=>{class r extends js{constructor(t){super(),t.modes.forEach(n=>this.actions[n][t.key]=t)}runLogic(t,n,o,f,D){let j=!0;const fe=Object.values(o.meta.displayLogic).filter(Oi=>{const Lr=Oi.modes??[];return!(!Lr.length||!Lr.includes(D))});if(!fe||!fe.length)return j;let Ne=o.meta.display??"show",vt="hide";"hide"===Ne&&(vt="show");const ln={panel:o,record:f,field:n,module:f.module};fe.some(Oi=>{const Lr=this.buildActionData(Oi,ln);return this.actions[D][Oi.key].run(Lr,Oi)})&&(Ne=vt),j="show"===Ne,o.displayState.next(j)}buildActionData(t,n){return{field:n.field,record:n&&n.record||null,panel:n.panel||null}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(HS))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),kC=(()=>{class r{constructor(t){this.systemConfigStore=t}duplicateOnModule(t,n,o,f){const D=this.systemConfigStore.getConfigValue("convert_ignore")??[],j=n.module??"";return n.id="",n.attributes.id="",Object.keys(o).forEach(fe=>{Al(t?.attributes[fe])||D?.default.includes(fe)||Object.keys(D).includes(j)&&D[j].includes(fe)||f.recordView?.vardefs[fe].type==o[fe].type&&(n.attributes[fe]=t.attributes[fe])}),n}getViewFieldsObservable(t){return(0,i.of)(t.recordView).pipe((0,M.map)(n=>{const o={};return n.panels.forEach(f=>{f.rows.forEach(D=>{D.cols.forEach(j=>{o[j.name??j.fieldDefinition.name??""]=j})})}),Object.keys(n.vardefs).forEach(f=>{const D=n.vardefs[f]??null;!D||(0,wt.isEmpty)(D)||o[f]||"relate"!=D.type&&(o[f]={name:f,vardefBased:!0,label:D.vname??"",type:D.type??"",display:D.display??"default",fieldDefinition:D,metadata:D.metadata??{},logic:D.logic??{}})}),Object.values(o)}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Kb={module:"",recordID:"",loading:!1,widgets:!1,showSidebarWidgets:!1,showBottomWidgets:!1,showTopWidget:!1,showSubpanels:!1,mode:"detail",params:{returnModule:"",returnId:"",returnAction:""}};let uf=(()=>{class r extends LC{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr,to,Mr,ss){super(o,f,D,j,fe),this.recordFetchGQL=t,this.recordSaveGQL=n,this.appStateStore=o,this.languageStore=f,this.navigationStore=D,this.moduleNavigation=j,this.metadataStore=fe,this.localStorage=Ne,this.message=vt,this.subpanelFactory=ln,this.recordManager=Hn,this.statisticsBatch=Oi,this.recordStoreFactory=Lr,this.preferences=to,this.panelLogicManager=Mr,this.recordConvertService=ss,this.panels=[],this.cache$=null,this.internalState=dr(Kb),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subpanelReloadSubject=new i.BehaviorSubject({}),this.subpanelReloadSub=[],this.subs=[],this.fieldSubs=[],this.panelsSubject=new i.BehaviorSubject(this.panels),this.actionAdaptorFactory=(0,e.inject)(PC),this.panels$=this.panelsSubject.asObservable(),this.recordStore=Lr.create(this.getViewFieldsObservable(),this.getRecordMetadata$()),this.record$=this.recordStore.state$.pipe((0,M.distinctUntilChanged)()),this.stagingRecord$=this.recordStore.staging$.pipe((0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(Us=>Us.loading)),this.widgets$=this.state$.pipe((0,M.map)(Us=>Us.widgets)),this.showSidebarWidgets$=this.state$.pipe((0,M.map)(Us=>Us.showSidebarWidgets)),this.showBottomWidgets$=this.state$.pipe((0,M.map)(Us=>Us.showBottomWidgets)),this.showTopWidget$=this.state$.pipe((0,M.map)(Us=>Us.showTopWidget)),this.showSubpanels$=this.state$.pipe((0,M.map)(Us=>Us.showSubpanels)),this.mode$=this.state$.pipe((0,M.map)(Us=>Us.mode)),this.subpanelReload$=this.subpanelReloadSubject.asObservable();const Rs=this.record$.pipe((0,i.combineLatestWith)(this.loading$),(0,M.map)(([Us,wu])=>(this.data={record:Us,loading:wu},this.data)));this.vm$=Rs.pipe((0,i.combineLatestWith)(this.appData$,this.metadata$),(0,M.map)(([Us,wu,Tf])=>(this.vm={data:Us,appData:wu,metadata:Tf},this.vm))),this.subpanelsState=new i.BehaviorSubject({}),this.subpanels$=this.subpanelsState.asObservable(),this.viewContext$=this.record$.pipe((0,M.map)(()=>this.getViewContext())),this.initPanels(),this.recordValidationHandler=(0,e.inject)(M_)}get widgets(){return this.internalState.widgets}set widgets(t){this.updateState({...this.internalState,widgets:t})}get showSidebarWidgets(){return this.internalState.showSidebarWidgets}set showSidebarWidgets(t){this.savePreference(this.getModuleName(),"show-sidebar-widgets",t),this.updateState({...this.internalState,showSidebarWidgets:t})}get showBottomWidgets(){return this.internalState.showBottomWidgets}set showBottomWidgets(t){this.updateState({...this.internalState,showBottomWidgets:t})}get showTopWidget(){return this.internalState.showTopWidget}set showTopWidget(t){this.updateState({...this.internalState,showTopWidget:t})}get showSubpanels(){return this.internalState.showTopWidget}set showSubpanels(t){this.updateState({...this.internalState,showSubpanels:t})}get params(){return this.internalState.params||{}}set params(t){this.updateState({...this.internalState,params:t})}getModuleName(){return this.internalState.module}getRecordId(){return this.internalState.recordID}getViewContext(){return{module:this.getModuleName(),id:this.getRecordId(),record:this.getBaseRecord()}}getSubpanels(){return this.subpanels}destroy(){this.clear()}init(t,n,o="detail",f={}){return this.internalState.module=t,this.internalState.recordID=n,this.setMode(o),this.initSubpanels(t,n),this.calculateShowWidgets(),this.load().pipe((0,M.tap)(()=>{this.showTopWidget=!0,setTimeout(()=>this.loadSubpanelStatistics(t),1500),this.parseParams(f)}))}clear(){this.cache$=null,this.clearSubpanels(),this.subpanelsState.unsubscribe(),this.updateState(dr(Kb)),this.subs=this.safeUnsubscription(this.subs),this.fieldSubs=this.safeUnsubscription(this.fieldSubs)}getBaseRecord(){return this.internalState?this.recordStore.getBaseRecord():null}getMode(){return this.internalState?this.internalState.mode:null}setMode(t){this.updateState({...this.internalState,mode:t})}save(){return this.appStateStore.updateLoading(`${this.internalState.module}-record-save`,!0),this.updateState({...this.internalState,loading:!0}),this.recordStore.save().pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_ERROR_SAVING"),(0,i.of)({}))),(0,M.finalize)(()=>{this.setMode("detail"),this.appStateStore.updateLoading(`${this.internalState.module}-record-save`,!1),this.updateState({...this.internalState,loading:!1})}))}saveOnEdit(){return this.recordStore.save().pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_ERROR_SAVING"),(0,i.of)({}))),(0,M.finalize)(()=>{this.appStateStore.updateLoading(`${this.internalState.module}-record-save`,!1),this.updateState({...this.internalState,loading:!1})}))}load(t=!0){return this.updateState({...this.internalState,loading:!0}),this.recordStore.retrieveRecord(this.internalState.module,this.internalState.recordID,t).pipe((0,M.tap)(n=>{this.updateState({...this.internalState,recordID:n.id,module:n.module,loading:!1})}))}getSummaryTemplate(){return(((this.metadata||{}).recordView||{}).summaryTemplates||{})[this.getMode()]||""}parseParams(t={}){if(!t)return;const n={...this.internalState.params};Object.keys(t).forEach(o=>{Al(n[o])||(n[o]=t[o])}),this.params=t}loadSubpanelStatistics(t){const n=this.subpanelsState.value;if(!n)return;const o={};Object.keys(n).forEach(f=>{const D=n[f],j=D.statistics;if(!j||!Object.keys(j).length)return;if(!1===D.shouldBatchStatistic())return void D.loadAllStatistics().pipe((0,M.take)(1)).subscribe();const fe=D.getAllStatisticQuery();Object.keys(fe).forEach(Ne=>{const vt=this.buildStatKey(f,Ne);o[vt]=fe[Ne]}),D.setAllStatisticsLoading(!0)}),this.statisticsBatch.fetch(t,o).pipe((0,M.take)(1)).subscribe(f=>{Object.keys(n).forEach(D=>{const j=n[D],fe=j.getAllStatisticQuery();Object.keys(fe).forEach(Ne=>{const vt=this.buildStatKey(D,Ne),ln=f[vt];ln&&j.setStatistics(Ne,ln,!0)}),j.setAllStatisticsLoading(!1)})})}buildStatKey(t,n){return(t=t.replace(/_/g,"-"))+"-"+n.replace(/_/g,"-")}updateState(t){this.store.next(this.internalState=t)}initSubpanels(t,n){this.showSubpanels=!0,this.metadataStore.subPanelMetadata$.subscribe(o=>{this.clearSubpanels(),Object.keys(o).forEach(f=>{this.subpanels[f]=this.subpanelFactory.create(),this.subpanels[f].init(t,n,o[f],this.record$)}),this.subpanelsState.next(this.subpanels),Object.keys(this.subpanels).forEach(f=>{this.subpanelReloadSub.push(this.subpanels[f].recordList.records$.pipe((0,M.tap)(()=>{const j={};j[f]=!0,this.subpanelReloadSubject.next(j)})).subscribe())})})}initPanels(){const t=(0,i.combineLatest)([this.metadataStore.recordViewMetadata$,this.stagingRecord$,this.languageStore.vm$]).subscribe(([n,o,f])=>{const D=[],j=o&&o.module||"";return this.safeUnsubscription(this.fieldSubs),n.panels.forEach(fe=>{const vt={label:fe.label?fe.label.toUpperCase():this.languageStore.getFieldLabel(fe.key.toUpperCase(),j,f),key:fe.key,rows:[]};let ln=null;const Hn=n.templateMeta.tabDefs[fe.key.toUpperCase()]??null;Hn&&(vt.meta=Hn),fe.rows.forEach(Oi=>{const Lr={cols:[]};Oi.cols.forEach(to=>{const Mr={...to};to.fieldActions&&(ln=this.actionAdaptorFactory.create("recordView",Mr.name,this),Mr.adaptor=ln),Lr.cols.push(Mr)}),vt.rows.push(Lr)}),vt.displayState=new i.BehaviorSubject(Hn?.display??!0),vt.display$=vt.displayState.asObservable(),D.push(vt),!(0,wt.isEmpty)(o?.fields)&&!(0,wt.isEmpty)(Hn?.displayLogic)&&Object.values(Hn.displayLogic).forEach(Oi=>{(0,wt.isEmpty)(Oi?.params?.fieldDependencies)||Oi.params.fieldDependencies.forEach(Lr=>{const to=o.fields[Lr]||null;(0,wt.isEmpty)(to)||this.fieldSubs.push(to.valueChanges$.subscribe(()=>{this.panelLogicManager.runLogic(Oi.key,to,vt,o,this.getMode())}))})})}),this.panelsSubject.next(this.panels=D),D});this.subs.push(t)}clearSubpanels(){this.subpanels&&Object.keys(this.subpanels).forEach(t=>{this.subpanels[t].clear()}),this.subpanelReloadSub.length&&(this.subpanelReloadSub.forEach(t=>t.unsubscribe()),this.subpanelReloadSub=[]),this.subpanels={}}calculateShowWidgets(){let t=!1;const o=this.getRecordViewMetadata().sidebarWidgets||[];o&&o.length>0&&(t=!0);const f=this.loadPreference(this.getModuleName(),"show-sidebar-widgets")??null;this.showSidebarWidgets=null!==f?f:t,this.showBottomWidgets=!0,this.widgets=t}getRecordViewMetadata(){return(this.metadataStore.get()||{}).recordView||{}}getVardefs(){return this.getRecordViewMetadata().vardefs||{}}getViewFieldsObservable(){return this.metadataStore.recordViewMetadata$.pipe((0,M.map)(t=>{const n={};return t.panels.forEach(o=>{o.rows.forEach(f=>{f.cols.forEach(D=>{n[D.name??D.fieldDefinition.name??""]=D})})}),Object.keys(t.vardefs).forEach(o=>{const f=t.vardefs[o]??null;!f||(0,wt.isEmpty)(f)||n[o]||"relate"!=f.type&&(n[o]={name:o,vardefBased:!0,label:f.vname??"",type:f.type??"",display:f.display??"",fieldDefinition:f,metadata:f.metadata??{},logic:f.logic??{}})}),Object.values(n)}))}getRecordMetadata$(){return this.metadataStore.recordViewMetadata$.pipe((0,M.map)(t=>t?.metadata??{}))}getPreferenceKey(t){return"recordview-"+t}savePreference(t,n,o){this.preferences.setUi(t,this.getPreferenceKey(n),o)}loadPreference(t,n){return this.preferences.getUi(t,this.getPreferenceKey(n))}safeUnsubscription(t){return t.forEach(n=>{n.closed||n.unsubscribe()}),[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Gb),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(N_),e.\u0275\u0275inject(Os),e.\u0275\u0275inject($a),e.\u0275\u0275inject(R_),e.\u0275\u0275inject(kC))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),L_=(()=>{class r extends Ba{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn){super(D,j,fe,Ne,f,vt,n,o),this.store=t,this.metadata=n,this.appMetadataStore=o,this.language=f,this.actionManager=D,this.asyncActionService=j,this.message=fe,this.confirmation=Ne,this.selectModalService=vt,this.viewName=ln,this.fieldName=Hn}getActions(t){return(0,i.combineLatest)([this.metadata.fieldActions$,this.store.mode$,this.store.record$,this.store.language$]).pipe((0,M.map)(([n,o])=>o&&n?this.parseModeActions(n[this.viewName][this.fieldName]??[],o,this.store.getViewContext()):[]))}buildActionData(t,n){return{store:this.store,action:t}}buildActionInput(t,n,o,f=null){const D=this.store.recordStore.getBaseStaging();return this.message.removeMessages(),{action:n,module:D.module,id:D.id,params:t&&t.params||[],record:D}}getMode(){return this.store.getMode()}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.store.load(!1).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){e.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),PC=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.metadata=t,this.appMetadataStore=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne}create(t,n,o){return new L_(o,this.metadata,this.appMetadataStore,this.language,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.selectModalService,t,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(K),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function AA(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",8)(2,"a",9),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.backToTop())}),e.\u0275\u0275elementStart(3,"span"),e.\u0275\u0275text(4," Back To Top "),e.\u0275\u0275element(5,"scrm-image",10),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementContainerEnd()}}function QM(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",11)(1,"div",12)(2,"h5",13),e.\u0275\u0275text(3,"\xa9 Powered By SugarCRM"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"button",14),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit;return e.\u0275\u0275resetView(o.dismiss("Cross click"))}),e.\u0275\u0275element(5,"scrm-image",15),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",16)(7,"p"),e.\u0275\u0275text(8," \xa9 2004-2013 SugarCRM Inc. The Program is provided AS IS, without warranty. Licensed under AGPLv3. "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(9,"p"),e.\u0275\u0275text(10," This program is free software; you can redistribute it and/or modify it under the terms of the GNU Affero General Public License version 3 as published by the Free Software Foundation, including the additional permission set forth in the source code header. "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(11,"p"),e.\u0275\u0275text(12," SugarCRM is a trademark of SugarCRM, Inc. All other company and product names may be trademarks of the respective companies with which they are associated. "),e.\u0275\u0275elementEnd()()()}}function BC(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",17)(1,"div",12)(2,"h5",13),e.\u0275\u0275text(3,"\xa9 Supercharged by SuiteCRM"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"button",14),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit;return e.\u0275\u0275resetView(o.dismiss("Cross click"))}),e.\u0275\u0275element(5,"scrm-image",15),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",16)(7,"p"),e.\u0275\u0275text(8," SuiteCRM has been written and assembled by SalesAgility. The Program is provided AS IS, without warranty. Licensed under AGPLv3. "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(9,"p"),e.\u0275\u0275text(10," This program is free software; you can redistribute it and/or modify it under the terms of the GNU Affero General Public License version 3 as published by the Free Software Foundation, including the additional permission set forth in the source code header. "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(11,"p"),e.\u0275\u0275text(12," SuiteCRM is a trademark of SalesAgility Ltd. All other company and product names may be trademarks of the respective companies with which they are associated. "),e.\u0275\u0275elementEnd()()()}}let nl=(()=>{class r{constructor(t,n){this.modalService=t,this.authService=n}openSugarCopyright(t){this.modalService.open(t,{ariaLabelledBy:"modal-basic-title",centered:!0,size:"lg"}).result.then(n=>{this.closeResult=`Closed with: ${n}`},n=>{this.closeResult=`Dismissed ${this.getDismissReason(n)}`})}openSuiteCopyright(t){this.modalService.open(t,{ariaLabelledBy:"modal-basic-title",centered:!0,size:"lg"}).result.then(n=>{this.closeResult=`Closed with: ${n}`},n=>{this.closeResult=`Dismissed ${this.getDismissReason(n)}`})}getDismissReason(t){return t===ct.ModalDismissReasons.ESC?"by pressing ESC":t===ct.ModalDismissReasons.BACKDROP_CLICK?"by clicking on a backdrop":`with: ${t}`}backToTop(){document.body.scrollTop=0,document.documentElement.scrollTop=0}ngOnInit(){this.authSub=this.authService.isUserLoggedIn.subscribe(t=>{this.isUserLoggedIn=t})}ngOnDestroy(){this.authSub.unsubscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Ka))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-footer-ui"]],decls:12,vars:1,consts:[["sugarcopyright",""],["suitecopyright",""],[1,"footer"],[1,"copyright-links"],["data-toggle","modal","data-target",".copyright-suitecrm",1,"footer-link",3,"click"],["data-toggle","modal","data-target",".copyright-sugarcrm",1,"footer-link",3,"click"],[4,"ngIf"],[1,"copyright"],[1,"back-to-top"],[1,"footer-link",3,"click"],["image","arrow_up_filled",1,"sicon","back-top-icon"],["role","dialog","aria-hidden","true",1,"copyright-sugarcrm"],[1,"modal-header"],[1,"modal-title"],["type","button","data-dismiss","modal","aria-label","Close",1,"close",3,"click"],["image","icon_modal_close",1,"sicon"],[1,"modal-body"],["role","dialog","aria-hidden","true",1,"copyright-suitecrm"]],template:function(n,o){if(1&n){const f=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",2)(1,"div",3)(2,"a",4),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(f);const j=e.\u0275\u0275reference(11);return e.\u0275\u0275resetView(o.openSuiteCopyright(j))}),e.\u0275\u0275text(3," \xa9 Supercharged by SuiteCRM "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"a",5),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(f);const j=e.\u0275\u0275reference(9);return e.\u0275\u0275resetView(o.openSugarCopyright(j))}),e.\u0275\u0275text(5," \xa9 Powered By SugarCRM "),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(6,AA,6,0,"ng-container",6),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(7,"div",7),e.\u0275\u0275template(8,QM,13,0,"ng-template",null,0,e.\u0275\u0275templateRefExtractor)(10,BC,13,0,"ng-template",null,1,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()}2&n&&(e.\u0275\u0275advance(6),e.\u0275\u0275property("ngIf",o.isUserLoggedIn))},dependencies:[ve.NgIf,Bl],encapsulation:2})}return r})(),OA=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})(),ET=(()=>{class r{constructor(){}ngOnInit(){}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["app-full-page-spinner"]],decls:20,vars:0,consts:[[1,"app-overlay"],["id","overlay-spinner"],[1,"app-loading"],[1,"sk-cube-grid"],[1,"sk-cube","sk-cube1","sk-cube-primary"],[1,"sk-cube","sk-cube2","sk-cube-secondary"],[1,"sk-cube","sk-cube3","sk-cube-secondary"],[1,"sk-cube","sk-cube4","sk-cube-primary"],[1,"sk-cube","sk-cube5","sk-cube-secondary"],[1,"sk-cube","sk-cube6","sk-cube-secondary"],[1,"sk-cube","sk-cube7","sk-cube-primary"],[1,"sk-cube","sk-cube8","sk-cube-primary"],[1,"sk-cube","sk-cube9","sk-cube-primary"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3),e.\u0275\u0275element(4,"div",4)(5,"div",4)(6,"div",5)(7,"div",6)(8,"div",7)(9,"div",7)(10,"div",8)(11,"div",9)(12,"div",10)(13,"div",10)(14,"div",11)(15,"div",12)(16,"div",10)(17,"div",10)(18,"div",11)(19,"div",12),e.\u0275\u0275elementEnd()()()())},styles:[".app-overlay[_ngcontent-%COMP%]{position:fixed;display:flex;justify-content:center;align-items:center;flex-direction:column;width:100%;height:100%;inset:0;background-color:#fff9;z-index:4000;cursor:default}.app-loading[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%}.app-loading[_ngcontent-%COMP%] .spinner[_ngcontent-%COMP%]{height:200px;width:200px;animation:scaleIn 4s linear infinite;transform-origin:center center;position:absolute;inset:0;margin:auto}.app-loading[_ngcontent-%COMP%] .spinner[_ngcontent-%COMP%] .path[_ngcontent-%COMP%]{stroke-dasharray:1,200;stroke-dashoffset:0;animation:dash 1.5s ease-in-out infinite;stroke-linecap:round;stroke:#ddd}.sk-cube-primary[_ngcontent-%COMP%]{background-color:#e67062}.sk-cube-secondary[_ngcontent-%COMP%]{background-color:#4e5063}.sk-cube-grid[_ngcontent-%COMP%]{width:100px;height:100px}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube[_ngcontent-%COMP%]{width:25%;height:25%;float:left;-webkit-animation:_ngcontent-%COMP%_sk-cubeGridScaleDelay 1.3s infinite ease-in-out;animation:_ngcontent-%COMP%_sk-cubeGridScaleDelay 1.3s infinite ease-in-out}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube1[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube2[_ngcontent-%COMP%]{-webkit-animation-delay:.3s;animation-delay:.3s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube3[_ngcontent-%COMP%]{-webkit-animation-delay:.4s;animation-delay:.4s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube4[_ngcontent-%COMP%]{-webkit-animation-delay:.1s;animation-delay:.1s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube5[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube6[_ngcontent-%COMP%]{-webkit-animation-delay:.3s;animation-delay:.3s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube7[_ngcontent-%COMP%]{-webkit-animation-delay:0s;animation-delay:0s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube8[_ngcontent-%COMP%]{-webkit-animation-delay:.1s;animation-delay:.1s}.sk-cube-grid[_ngcontent-%COMP%] .sk-cube9[_ngcontent-%COMP%]{-webkit-animation-delay:.2s;animation-delay:.2s}@-webkit-keyframes _ngcontent-%COMP%_sk-cubeGridScaleDelay{0%,70%,to{-webkit-transform:scale3D(1,1,1);transform:scaleZ(1)}35%{-webkit-transform:scale3D(0,0,1);transform:scale3D(0,0,1)}}@keyframes _ngcontent-%COMP%_sk-cubeGridScaleDelay{0%,70%,to{-webkit-transform:scale3D(1,1,1);transform:scaleZ(1)}35%{-webkit-transform:scale3D(0,0,1);transform:scale3D(0,0,1)}}"]})}return r})(),FA=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fn.AngularSvgIconModule]})}return r})();function zS(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275element(1,"scrm-label",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.messageLabelKey)}}function VC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",7),e.\u0275\u0275element(2,"scrm-image",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275property("image",t.icon)("klass",t.iconClass)}}function YM(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",11),e.\u0275\u0275element(1,"scrm-field",12),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("type",t.field.type)("field",t.field)}}function Vw(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",13)(1,"div",14)(2,"div",15),e.\u0275\u0275text(3," ... "),e.\u0275\u0275elementEnd()()())}function jw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,YM,2,2,"div",9)(2,Vw,4,0,"div",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.field),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.initializing()||t.loading&&n.loading)}}function TT(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",16),e.\u0275\u0275element(2,"scrm-label",17),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.labelKey)("module",n.getContextModule())}}function jC(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",18)(2,"label"),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4).ngIf;e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate(t.description)}}function zp(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",20),e.\u0275\u0275element(1,"scrm-dynamic-label",21),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("context",o.getMessageContext())("fields",o.getMessageFields(n.statistics))("labelKey",t.dynamicLabel)}}function vv(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",13),e.\u0275\u0275element(1,"scrm-inline-loading-spinner"),e.\u0275\u0275elementEnd())}function u0(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,zp,2,3,"div",19)(2,vv,2,0,"div",10),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading)}}function Kh(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275text(2," - "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("widget-entry-value ",n.getSizeClass(t.size),"")}}function XM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Kh,3,3,"ng-container",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.statistic&&!o.loading&&(!n.statistics[t.statistic].field||n.statistics[t.statistic].field&&o.isEmptyFieldValue(n.statistics[t.statistic].field.value)))}}function MT(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,VC,3,2,"ng-container",6)(2,jw,3,2,"ng-container",6)(3,TT,3,2,"ng-container",6)(4,jC,4,1,"ng-container",6)(5,u0,3,2,"ng-container",6)(6,XM,2,1,"ng-container",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.statistic&&n.statistics[t.statistic]),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.descriptionKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dynamicLabel),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.initializing())}}function ZM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275template(2,MT,7,6,"ng-container",6),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate2("",n.getColClass()," ",n.getClass(t),""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","hidden"!==t.display)}}function GS(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275template(2,ZM,3,5,"ng-container",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate4("d-flex ",n.getJustify(t.justify)," ",n.getAlign(t.align)," ",n.getRowClass()," ",n.getLayoutRowClass(t),""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.cols)}}function d0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",4),e.\u0275\u0275template(1,GS,3,7,"ng-container",5),e.\u0275\u0275elementEnd()),2&r){const t=v.ngIf;e.\u0275\u0275propertyInterpolate("ngbTooltip",t.tooltipTitleText),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.layout)}}let Ku=(()=>{class r{constructor(t,n){this.language=t,this.factory=n,this.loading=!0,this.initializing=(0,e.signal)(!0),this.subs=[],this.statistics={}}ngOnInit(){this.validateConfig()&&(this.gridWidgetInput=this.config,this.buildStatistics(),this.setupLoading$(),this.setupVM(),this.setupReload())}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}validateConfig(){return this.config&&this.config.layout?this.config.queryArgs.context&&this.config.queryArgs.module?this.config.widgetConfig?!(!this.config.layout||!this.config.layout.rows)||(this.messageLabelKey="LBL_CONFIG_NO_STATISTICS_KEY",!1):(this.messageLabelKey="LBL_CONFIG_NO_CONFIG",!1):(this.messageLabelKey="LBL_CONFIG_BAD_CONTEXT",!1):(this.messageLabelKey="LBL_CONFIG_NO_CONFIG",!1)}getRowClass(){return this.gridWidgetInput.rowClass}getColClass(){return this.gridWidgetInput.columnClass}getContextModule(){return this.gridWidgetInput.queryArgs.context.module}getMessageContext(){const t=this.getContextModule();return t?{module:t}:{}}getMessageFields(t){if(!t||!Object.keys(t).length)return{};const n={};return Object.keys(t).forEach(o=>{n[o]=t[o].field}),n}getSizeClass(t){return{regular:"text-regular",medium:"text-medium",large:"text-large","x-large":"text-x-large","xx-large":"text-xx-large",huge:"text-huge"}[t]||"text-regular"}getFontWeight(t){let n="font-weight-normal";return t&&cl(t)&&(n="font-weight-bolder"),n}getColor(t){return{yellow:"text-yellow",blue:"text-blue",green:"text-green",red:"text-red",purple:"text-purple",dark:"text-dark",grey:"text-grey"}[t]||""}getJustify(t){return{start:"justify-content-start",end:"justify-content-end",center:"justify-content-center",between:"justify-content-between",around:"justify-content-around"}[t]||"justify-content-center"}getAlign(t){return{start:"align-items-start",end:"align-items-end",center:"align-items-center",baseline:"align-items-baseline",stretch:"align-items-stretch"}[t]||"align-items-center"}getLayoutRowClass(t){let n="";return t&&t.class&&(n=t.class),n}getClass(t){let n="";return t&&(n=t.class),n=n+" "+this.getSizeClass(t.size)+" "+this.getFontWeight(t.bold)+" "+this.getColor(t.color),n}isEmptyFieldValue(t){return"string"==typeof t&&(t=t.trim()),null==t||typeof t>"u"||""===t||0===t.length}getLabel(t,n){let o="";return t&&t[n]&&(o=this.language.getFieldLabel(t[n])),o}getLayout(){return this.gridWidgetInput.layout.rows}buildStatistics(){this.gridWidgetInput.layout.rows.forEach(t=>{!t.cols||!t.cols.length||t.cols.forEach(n=>{if(n.statistic){if(n.store)return void(this.statistics[n.statistic]={type:n.statistic,store:n.store});this.statistics[n.statistic]={type:n.statistic,store:this.factory.create()},this.statistics[n.statistic].store.init(this.gridWidgetInput.queryArgs.module,{key:n.statistic,context:{...this.gridWidgetInput.queryArgs.context},params:{...this.gridWidgetInput.queryArgs.params}}).pipe((0,M.take)(1)).subscribe()}})})}setupLoading$(){const t=[];Object.keys(this.statistics).forEach(o=>t.push(this.statistics[o].store.loading$));let n=(0,i.of)([]);if(t.length<1)n=(0,i.of)([]);else if(1===t.length)n=t[0].pipe((0,M.map)(o=>[o]));else{let f,o=null;[o,...f]=t,n=o.pipe((0,i.combineLatestWith)(f))}this.loading$=n.pipe((0,M.map)(o=>{if(!o||o.length<1)return this.loading=!1,!1;let f=!0;return o.forEach(D=>{f=f&&D}),this.loading=f,f})),this.subs.push(this.loading$.subscribe())}setupReload(){this.gridWidgetInput.widgetConfig.reload$&&this.subs.push(this.gridWidgetInput.widgetConfig.reload$.subscribe(()=>{!1===this.loading&&(this.loading=!0,Object.keys(this.statistics).forEach(t=>{const n=this.statistics[t];n.store&&n.store.load(!1).pipe((0,M.take)(1)).subscribe()}))}))}setupVM(){let t=(0,i.of)([]).pipe((0,M.shareReplay)());const n=(0,i.of)(this.getLayout()).pipe((0,M.shareReplay)());if(this.statistics&&Object.keys(this.statistics).length>0){const o=[];if(Object.keys(this.statistics).forEach(f=>o.push(this.statistics[f].store.state$)),o.length<1)t=(0,i.of)([]);else if(1===o.length)t=o[0].pipe((0,M.map)(f=>[f]));else{let D,f=null;[f,...D]=o,t=f.pipe((0,i.combineLatestWith)(D))}}t=t.pipe((0,M.tap)(()=>{this.initializing()&&this.initializing.set(!1)})),this.vm$=t.pipe((0,i.combineLatestWith)(n),(0,M.map)(([o,f])=>{const D={},j=[],fe=[];return o.forEach(Ne=>{D[Ne.query.key]=Ne;const vt=this.getLabel(Ne.statistic.metadata,"tooltip_title_key");vt&&j.push(vt);const ln=this.getLabel(Ne.statistic.metadata,"descriptionKey");ln&&fe.push(ln)}),{layout:f,statistics:D,tooltipTitleText:j.join(" | "),description:fe.join(" | ")}}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Hr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-grid-widget"]],inputs:{config:"config"},decls:3,vars:4,consts:[["class","p-3 widget-message",4,"ngIf"],["class","grid-widget d-flex flex-column","placement","auto","container","body",3,"ngbTooltip",4,"ngIf"],[1,"p-3","widget-message"],[3,"labelKey"],["placement","auto","container","body",1,"grid-widget","d-flex","flex-column",3,"ngbTooltip"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"widget-entry-icon"],[3,"image","klass"],["class","widget-entry-value",4,"ngIf"],["class","widget-entry-loading",4,"ngIf"],[1,"widget-entry-value"],["mode","list",3,"type","field"],[1,"widget-entry-loading"],[1,"pb-2","widget-entry-value"],[1,"rounded","box-loading","skeleton-field-content"],[1,"widget-entry-label","text-truncate"],[3,"labelKey","module"],[1,"text-truncate","widget-entry-label"],["class","widget-entry-dynamic-label",4,"ngIf"],[1,"widget-entry-dynamic-label"],[3,"context","fields","labelKey"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,zS,2,1,"div",0)(1,d0,2,2,"div",1),e.\u0275\u0275pipe(2,"async")),2&n&&(e.\u0275\u0275property("ngIf",o.messageLabelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.messageLabelKey&&e.\u0275\u0275pipeBind1(2,2,o.vm$)))},dependencies:[ve.NgForOf,ve.NgIf,Dm,HD,Pa,Bl,Df,ct.NgbTooltip,ve.AsyncPipe],encapsulation:2})}return r})();function Cs(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.internalConfig)}}let Ul=(()=>{class r{constructor(){this.status="maximised",this.buttonClasses=["minimise-button"]}ngOnInit(){this.buildButton()}ngOnChanges(t){t.config&&this.buildButton()}buildButton(){const t=ep.fromButton(this.config);t.addClasses(this.buttonClasses),t.icon=this.getIcon(),t.onClick=()=>{this.config.onClick(),this.toggleStatus()},this.internalConfig=t}toggleStatus(){let t="minimised";"minimised"===this.status&&(t="maximised"),this.status=t,this.buildButton()}getIcon(){return"minimised"===this.status?"plus_thin":"minimise"}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-minimise-button"]],inputs:{config:"config",status:"status"},features:[e.\u0275\u0275NgOnChangesFeature],decls:1,vars:1,consts:[[4,"ngIf"],[3,"config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,Cs,2,1,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.internalConfig)},dependencies:[ve.NgIf,xc],encapsulation:2})}return r})();const JM=[[["","panel-body",""]],[["","panel-icon-area",""]],[["","panel-status-area",""]],[["","panel-header-button",""]]],xd=["[panel-body]","[panel-icon-area]","[panel-status-area]","[panel-header-button]"];function ua(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-close-button",11),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",t.getCloseButton())}}function yp(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-minimise-button",12),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",t.minimiseButton)("status",t.minimiseStatus)}}function UC(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",13)(1,"div",14),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t.title)}}function Wa(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15),e.\u0275\u0275element(1,"scrm-label",16),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.titleKey)}}function Sf(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2)(1,"div",3)(2,"div",4),e.\u0275\u0275template(3,ua,1,1,"scrm-close-button",5)(4,yp,1,2,"scrm-minimise-button",6),e.\u0275\u0275projection(5,1),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(6,UC,3,1,"div",7)(7,Wa,2,1,"div",8),e.\u0275\u0275elementStart(8,"div",9),e.\u0275\u0275projection(9,2),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(10,"div",10),e.\u0275\u0275projection(11,3),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.isClosable()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.isCollapsible()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.title),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.titleKey)}}let wl=(()=>{class r{constructor(){this.klass="",this.bodyPadding=2,this.mode="closable",this.close={klass:["btn","btn-outline-light","btn-sm"]},this.showHeader=!0,this.isCollapsed=!1,this.buttonClasses=["btn","btn-outline-light","btn-sm"],this.subs=[]}ngOnInit(){this.isCollapsed$&&this.subs.push(this.isCollapsed$.subscribe(t=>{this.isCollapsed=t,this.initMinimiseButton()})),this.initMinimiseButton()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getCloseButton(){if(!this.close)return null;const t=ep.fromButton(this.close);return t.addClasses(this.buttonClasses),this.close=t,t}isClosable(){return"closable"===this.mode}isCollapsible(){return"collapsible"===this.mode}initMinimiseButton(){this.minimiseButton={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.isCollapsed=!this.isCollapsed,this.initMinimiseStatus()}},this.initMinimiseStatus()}initMinimiseStatus(){this.minimiseStatus=this.isCollapsed?"minimised":"maximised"}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-panel"]],inputs:{klass:"klass",bodyPadding:"bodyPadding",title:"title",titleKey:"titleKey",mode:"mode",isCollapsed$:"isCollapsed$",close:"close",showHeader:"showHeader"},ngContentSelectors:xd,decls:4,vars:10,consts:[["class","card-header d-flex justify-content-between align-items-center",4,"ngIf"],[3,"ngbCollapse"],[1,"card-header","d-flex","justify-content-between","align-items-center"],[1,"flex-grow-1","align-items-center","d-flex"],[1,"d-flex","align-items-center"],[3,"config",4,"ngIf"],[3,"config","status",4,"ngIf"],["class","pl-1 panel-title d-inline-block align-items-center",4,"ngIf"],["class","pl-1 panel-title",4,"ngIf"],[1,"pl-1"],[1,"panel-buttons","float-right"],[3,"config"],[3,"config","status"],[1,"pl-1","panel-title","d-inline-block","align-items-center"],[1,"lh-100"],[1,"pl-1","panel-title"],[3,"labelKey"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(JM),e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,Sf,12,4,"div",0),e.\u0275\u0275elementStart(2,"div",1),e.\u0275\u0275projection(3),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275classMapInterpolate1("card panel-card ",o.klass,""),e.\u0275\u0275classProp("collapsed",o.isCollapsed),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showHeader),e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("card-body p-",o.bodyPadding,""),e.\u0275\u0275property("ngbCollapse",o.isCollapsed))},dependencies:[ve.NgIf,Km,ct.NgbCollapse,Ul,Pa],encapsulation:2})}return r})();const $l=[[["","widget-header-icon-area",""]],[["","widget-header-status-area",""]],[["","widget-header-button",""]],[["","widget-body",""]]],eI=["[widget-header-icon-area]","[widget-header-status-area]","[widget-header-button]","[widget-body]"];function NA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",7),e.\u0275\u0275projection(1,3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("@widgetContentFade",t.displayContent?"true":"false")}}let f0=(()=>{class r{constructor(t){this.languageStore=t,this.title="",this.titleKey="",this.showHeader=!0,this.displayContent=!0}ngOnInit(){}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-widget-panel"]],inputs:{title:"title",titleKey:"titleKey",showHeader:"showHeader",mode:"mode"},ngContentSelectors:eI,decls:10,vars:5,consts:[[1,"accordion","widget-panel","mr-0","shadow-sm"],["bodyPadding","0",3,"mode","title","titleKey","showHeader"],["panel-icon-area",""],["panel-status-area",""],["panel-header-button",""],["panel-body",""],["class","widget collapse show open-close-container","data-parent",".widget-panel",4,"ngIf"],["data-parent",".widget-panel",1,"widget","collapse","show","open-close-container"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef($l),e.\u0275\u0275elementStart(0,"div",0)(1,"scrm-panel",1)(2,"span",2),e.\u0275\u0275projection(3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"span",3),e.\u0275\u0275projection(5,1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"span",4),e.\u0275\u0275projection(7,2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(8,"div",5),e.\u0275\u0275template(9,NA,2,1,"div",6),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("mode",o.mode)("title",o.title)("titleKey",o.titleKey)("showHeader",o.showHeader),e.\u0275\u0275advance(8),e.\u0275\u0275property("ngIf",o.displayContent))},dependencies:[ve.NgIf,wl],encapsulation:2,data:{animation:[(0,sr.trigger)("widgetFade",[(0,sr.transition)("void => *",[(0,sr.style)({transform:"translateX(100%)",opacity:0}),(0,sr.animate)("500ms",(0,sr.style)({transform:"translateX(0)",opacity:1}))]),(0,sr.transition)("* => void",[(0,sr.style)({transform:"translateX(0)",opacity:1}),(0,sr.animate)("500ms",(0,sr.style)({transform:"translateX(100%)",opacity:0}))])]),(0,sr.trigger)("widgetContentFade",[(0,sr.transition)("void => *",[(0,sr.style)({transform:"translateY(-5%)",opacity:0}),(0,sr.animate)("500ms",(0,sr.style)({transform:"translateY(0)",opacity:1}))]),(0,sr.transition)("* => void",[(0,sr.style)({transform:"translateY(0)",opacity:1}),(0,sr.animate)("500ms",(0,sr.style)({transform:"translateY(-5%)",opacity:0}))])])]}})}return r})(),gh=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa]})}return r})(),xm=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,Zg,ct.NgbModule,gh,Ea]})}return r})(),Gp=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl,xm]})}return r})(),p0=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,gy,Gp,Ea,Vl,dh,ct.NgbTooltipModule]})}return r})();function tI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",5)(1,"div",6)(2,"strong"),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(4,"div",7),e.\u0275\u0275text(5),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate(t.getColumnLabel("LBL_CHECKSYS_TITLE")),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate1(" ",t.getColumnLabel("ERR_CHECKSYS")," ")}}function h0(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",14)(1,"strong"),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate1(" ",n.getColumnLabel(t.value.info)," ")}}function IT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",n.getColumnLabel(t.value.error)," ")}}function Gf(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li"),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t," ")}}function $C(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15)(1,"ul"),e.\u0275\u0275template(2,Gf,2,1,"li",4),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.value.data)}}function WC(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li")(1,"div",8)(2,"div")(3,"span"),e.\u0275\u0275element(4,"scrm-image",9),e.\u0275\u0275elementStart(5,"strong",10),e.\u0275\u0275text(6),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(7,h0,3,1,"span",11),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(8,IT,2,1,"div",12),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(9,$C,3,1,"div",13),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("alert ",n.getAlertType(t.value),""),e.\u0275\u0275advance(3),e.\u0275\u0275property("image",n.getAlertIcon(t.value)),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate1(" ",n.getColumnLabel(t.value.label)," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",""!==t.value.info),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",""!==t.value.error),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",0!==t.value.data.length)}}const _v={success:{alertClass:"alert-success",alertIcon:"info-circle"},error:{alertClass:"alert-danger",alertIcon:"exclamation-circle"},warning:{alertClass:"alert-warning",alertIcon:"exclamation-triangle"},info:{alertClass:"alert-info",alertIcon:"info-circle"},light:{alertClass:"alert-light",alertIcon:"exclamation-circle"}};let Kp=(()=>{class r{constructor(t,n,o){this.appState=t,this.languageStore=n,this.modal=o,this.titleKey="LBL_CHECKSYS_TITLE"}getHeaderLabel(){return this.languageStore.getFieldLabel("LBL_CHECKSYS_TITLE")}getColumnLabel(t){const n=this.languageStore.getFieldLabel(t,this.appState.getModule());return Ud(n)?t:n}ngOnInit(){this.closeButtonIcon={klass:["btn","btn-outline-light","btn-sm"],onClick:()=>{this.modal.close({type:"close-button"})}},this.closeButton={klass:["btn","modal-button-cancel"],labelKey:"LBL_COLUMN_SELECTOR_CLOSE_BUTTON",onClick:()=>{this.modal.close({type:"close-button"})}}}getAlertType(t){return"error"===t.status?_v[t.type].alertClass:_v[t.status].alertClass}getAlertIcon(t){return"error"===t.status?_v[t.type].alertIcon:_v[t.status].alertIcon}returnZero(){return 0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(ct.NgbActiveModal))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-install-error-modal"]],inputs:{errors:"errors"},decls:8,vars:11,consts:[[3,"closable","close","title","titleKey","headerKlass","bodyKlass"],["modal-body",""],["class","alert alert-danger","role","alert",4,"ngIf"],[1,"list-style-none"],[4,"ngFor","ngForOf"],["role","alert",1,"alert","alert-danger"],[1,"alert-heading"],[1,"alert-desc"],["role","alert"],[3,"image"],[2,"margin-left","2px"],["style","float:right",4,"ngIf"],[4,"ngIf"],["class","alert alert-light","role","alert",4,"ngIf"],[2,"float","right"],["role","alert",1,"alert","alert-light"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-modal",0)(1,"div",1),e.\u0275\u0275elementContainerStart(2),e.\u0275\u0275template(3,tI,6,2,"div",2),e.\u0275\u0275elementStart(4,"div")(5,"ul",3),e.\u0275\u0275template(6,WC,10,8,"li",4),e.\u0275\u0275pipe(7,"keyvalue"),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd(),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275property("closable",!0)("close",o.closeButtonIcon)("title",o.getHeaderLabel())("titleKey",o.titleKey)("headerKlass","alert-header")("bodyKlass","alert-body"),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.errors.hasValidationError&&!0===o.errors.hasValidationError),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind2(7,8,o.errors.data,o.returnZero)))},dependencies:[ve.NgForOf,ve.NgIf,qm,Bl,ve.KeyValuePipe],encapsulation:2})}return r})(),HC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r,bootstrap:[Kp]});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ws,Zg,Qm,Ea,Oa,ct.NgbModule,ct.NgbAlertModule,Vl]})}return r})();function zC(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button-group",7),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config$",t.config$)("klass","icon-bar-block")}}function GC(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",1)(2,"div",2)(3,"div",3)(4,"div"),e.\u0275\u0275template(5,zC,1,2,"scrm-button-group",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"button",5),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleExpand(null==o.record?null:o.record.id))}),e.\u0275\u0275element(7,"scrm-image",6),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275classMap(t.wrapperClass),e.\u0275\u0275property("ngClass",t.isActive?"active":""),e.\u0275\u0275advance(),e.\u0275\u0275classMap(t.klass),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config$)}}let qb=(()=>{class r{onClickOutside(t){this.el.nativeElement.contains(t)||(this.isActive=!1,this.isClickedOutside.set(!0))}constructor(t,n,o,f,D){this.languageStore=t,this.languages=n,this.screenSize=o,this.systemConfigStore=f,this.el=D,this.klass="",this.wrapperClass="",this.limitConfigKey="listview_line_actions_limits",this.configState=new i.BehaviorSubject({buttons:[]}),this.config$=this.configState.asObservable(),this.isActive=!1,this.isClickedOutside=(0,e.signal)(!1),this.buttonClass="line-action-item line-action",this.buttonGroupClass="float-right",this.subs=[],this.screen=$d.Medium,this.defaultBreakpoint=3}ngOnInit(){this.subs.push(this.config.getActions({record:this.record}).pipe((0,i.combineLatestWith)(this.screenSize.screenSize$,this.languages.vm$),(0,M.map)(([t,n,o])=>{n&&(this.screen=n),this.configState.next(this.getButtonGroupConfig(t)),this.actions=t})).subscribe()),this.subs.push(this.activeLineAction.activeAction$.subscribe(t=>{this.isActive=this.record?.id===t}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.isActive=!1,this.activeLineAction.resetActiveAction()}getButtonGroupConfig(t){const n=[],o=[];t.forEach(j=>{const fe=this.buildButton(j);j.params&&j.params.expanded?n.push(fe):o.push(fe)});let f=t.length;const D=n.concat(o);return{buttonKlass:[this.buttonClass],dropdownLabel:this.languages.getAppString("LBL_ACTIONS")||"",breakpoint:f,dropdownOptions:{placement:["bottom-right"],wrapperKlass:[this.buttonGroupClass]},buttons:D}}getBreakpoint(){const t=this.systemConfigStore.getConfigValue(this.limitConfigKey);return this.screen&&t&&t[this.screen]?(this.breakpoint=t[this.screen],this.breakpoint):this.breakpoint?this.breakpoint:this.defaultBreakpoint}buildButton(t){const n={titleKey:t.labelKey||"",klass:this.buttonClass,icon:t.icon||"",onClick:()=>{this.config.runAction(t,{module:this.record&&this.record.module||"",record:this.record})}};t.icon&&(n.icon=t.icon);const o=t?.params?.debounceClick??null;return n.debounceClick=!0,sf(o)&&(n.debounceClick=!1),t.status&&ep.appendClasses(n,[t.status]),n}toggleExpand(t){this.activeLineAction.getActiveAction()!==t||this.isClickedOutside()?(this.activeLineAction.setActiveAction(t),this.isActive=!0,this.isClickedOutside.set(!1)):this.activeLineAction.resetActiveAction()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(e.ElementRef))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-line-action-menu"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("click",function(D){return o.onClickOutside(D.target)},!1,e.\u0275\u0275resolveDocument)},inputs:{klass:"klass",wrapperClass:"wrapperClass",record:"record",config:"config",activeLineAction:"activeLineAction",limitConfigKey:"limitConfigKey"},decls:1,vars:1,consts:[[4,"ngIf"],[1,"line-action-container"],["id","line-action-div",1,"line-action","line-action-position"],[3,"ngClass"],[3,"config$","klass",4,"ngIf"],["aria-label","Mobile Menu Button",1,"more-button",3,"click"],["image","apps-line",1,"sicon"],[3,"config$","klass"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,GC,8,8,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.actions.length)},dependencies:[ve.NgClass,ve.NgIf,Bl,nb],encapsulation:2})}return r})(),Uw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ct.NgbModule,Vl,Wo.RouterModule,Fu]})}return r})(),vh=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-load-more"]],inputs:{loadMoreButton:"loadMoreButton"},decls:3,vars:1,consts:[[1,"float-right"],[1,"",3,"config"],["image","plus_thin",1,"small",2,"fill","#FFFFFF"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"scrm-button",1),e.\u0275\u0275element(2,"scrm-image",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.loadMoreButton))},dependencies:[Bl,xc],encapsulation:2})}return r})(),KS=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl,Oa]})}return r})();class $w{constructor(){this.url="",this.md5="",this.width=0,this.height=0}}let bp=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-logo-ui"]],decls:1,vars:0,consts:[["image","company_logo",1,"logo"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"scrm-image",0)},dependencies:[Bl],encapsulation:2})}return r})(),Qb=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})();function qS(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",1),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.doLogout())}),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t.appStrings[n.logout.logoutAction.label]||"")}}let KC=(()=>{class r{constructor(t,n){this.auth=t,this.languageStore=n,this.logout={logoutAction:{label:"LBL_LOGOUT"}},this.languages$=this.languageStore.vm$,this.vm$=this.languages$.pipe((0,M.map)(o=>({appStrings:o.appStrings||{},appListStrings:o.appListStrings||{}})))}doLogout(){this.auth.logout()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-logout-ui"]],decls:2,vars:3,consts:[[4,"ngIf"],[1,"dropdown-item","global-links-sublink",3,"click"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,qS,3,1,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ve.AsyncPipe],encapsulation:2})}return r})(),k_=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();function N(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(n[null==t?null:t.labelKey]||(null==t?null:t.defaultText)||(null==t?null:t.labelKey)||"")}}function $(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t.text)}}function ge(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",5),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.close(o))}),e.\u0275\u0275template(1,N,2,1,"ng-container",6)(2,$,2,1,"ng-container",6),e.\u0275\u0275elementStart(3,"a",7),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.close(o))}),e.\u0275\u0275elementStart(4,"span",8),e.\u0275\u0275text(5,"\xd7"),e.\u0275\u0275elementEnd()()()}if(2&r){const t=v.$implicit;e.\u0275\u0275classMapInterpolate1("message ",t.type," alert-dismissible fade show shadow"),e.\u0275\u0275property("@fade",void 0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.text&&!t.labelKey)}}function nt(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3),e.\u0275\u0275template(1,ge,6,6,"div",4),e.\u0275\u0275elementEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t)}}function Lt(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,nt,2,1,"div",2),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,1,t.messages$))}}let bn=(()=>{class r{constructor(t,n){this.messageService=t,this.languages=n,this.appStrings$=n.appStrings$}ngOnInit(){this.messages$=this.messageService.messages$}close(t){this.messageService.contains(t,!0)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-message-ui"]],decls:2,vars:3,consts:[["class","container-fluid alert-fixed message-wrapper",4,"ngIf"],[1,"container-fluid","alert-fixed","message-wrapper"],["class","d-flex justify-content-center flex-column align-items-center message-container",4,"ngIf"],[1,"d-flex","justify-content-center","flex-column","align-items-center","message-container"],["role","alert",3,"class","click",4,"ngFor","ngForOf"],["role","alert",3,"click"],[4,"ngIf"],["type","button","data-dismiss","alert","aria-label","Close",1,"close",3,"click"],["aria-hidden","true"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Lt,3,3,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.appStrings$))},dependencies:[ve.NgForOf,ve.NgIf,ve.AsyncPipe],encapsulation:2,data:{animation:[(0,sr.trigger)("fade",[(0,sr.transition)(":enter",(0,sr.useAnimation)(Bv.fadeIn,{params:{timing:.5,delay:0}})),(0,sr.transition)(":leave",(0,sr.useAnimation)(Bv.fadeOut,{params:{timing:.5,delay:0}}))])]}})}return r})(),ui=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Hi=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qm]})}return r})(),yr=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Fu]})}return r})(),fs=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qm,Fu,Ea,yr,ct.NgbModule]})}return r})(),co=(()=>{class r{constructor(){this.title=""}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-module-title"]],inputs:{title:"title"},decls:2,vars:3,template:function(n,o){1&n&&(e.\u0275\u0275text(0),e.\u0275\u0275pipe(1,"uppercase")),2&n&&e.\u0275\u0275textInterpolate1("\n",e.\u0275\u0275pipeBind1(1,1,o.title),"\n")},dependencies:[ve.UpperCasePipe],encapsulation:2})}return r})(),Do=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();var Ts=function(r){return r.none="",r.blank="_blank",r.parent="_parent",r.self="_self",r.top="_top",r}(Ts||{});class os{constructor(){this.target=Ts.none}}class gl{constructor(v,t,n,o,f,D){this.routeConverter=v,this.moduleNavigation=t,this.preferences=n,this.language=o,this.appState=f,this.moduleNameMapper=D,this.authenticated=!0,this.logo=new $w,this.useGroupTabs=!1,this.globalActions=[],this.currentUser={id:"",firstName:"",lastName:""},this.all={modules:[],extra:[]},this.menu=[]}resetMenu(){this.menu=[],this.globalActions=[],this.all.modules=[],this.all.extra=[],this.current=null,this.currentUser={}}buildUserActionMenu(v,t){this.currentUser.id=t.id,this.currentUser.firstName=t.firstName,this.currentUser.lastName=t.lastName,v&&v.forEach(n=>{const o=n.name;let f=n.url;if("logout"===o)return;let D=Ts.none;"training"===o?D=Ts.blank:f=this.routeConverter.toFrontEndLink(f);const j=this.language.getAppString(n.labelKey)??"";this.globalActions.push({link:{url:f,label:j,target:D}})})}build(v,t,n){this.buildUserActionMenu(v.userActionMenu,t);const o=this.preferences.getUserPreference("navigation_paradigm"),f="on"===this.preferences.getUserPreference("sort_modules_by_name");"m"!==o?"gm"!==o||this.buildGroupedNavigation(v,n,f):this.buildModuleNavigation(v,n,f)}buildGroupTabMenu(v,t,n,o,f){const D=[],j=[];v&&v.length>0&&(v.forEach(Ne=>{j.push(this.buildTabMenuItem(Ne,t[Ne]))}),f&&this.sortMenuItems(j));let fe=0;o.forEach(Ne=>{fe<n&&D.push(this.buildTabGroupedMenuItem(Ne.labelKey,Ne.modules,t,f)),fe++}),this.menu=D,this.all.modules=j}buildModuleNavigation(v,t,n){uy([v.tabs,v.modules])&&(this.buildTabMenu(v.tabs,v.modules,t,n),this.buildSelectedModule(v))}buildGroupedNavigation(v,t,n){uy([v.tabs,v.modules,v.groupedTabs])&&(this.buildGroupTabMenu(v.tabs,v.modules,t,v.groupedTabs,n),this.buildSelectedModule(v))}buildSelectedModule(v){const t=this.appState.getModule()??"";""===t||"home"===t||v.modules[t]&&(this.current=this.buildTabMenuItem(t,v.modules[t]))}buildTabMenu(v,t,n,o){const f=[],D=[];if(!v||0===v.length)return this.menu=f,void(this.all.modules=D);let j=0;v.forEach(fe=>{const Ne=this.buildTabMenuItem(fe,t[fe]);"home"===fe||this.appState.getModule()===fe||j>n?D.push(Ne):f.push(Ne),j++}),o&&(this.sortMenuItems(f),this.sortMenuItems(D)),this.menu=f,this.all.modules=D}buildTabGroupedMenuItem(v,t,n,o){return{link:{label:this.language.getAppString(v)||v,url:"",route:null,params:null},icon:"",submenu:this.buildGroupedMenu(t,n,o)}}buildGroupedMenu(v,t,n){const o=[];let f=null;return v.forEach(D=>{const j=t[D];if(!j)return;const fe=this.buildTabMenuItem(D,j);"home"!==D?o.push(fe):f=fe}),n&&this.sortMenuItems(o),f&&o.unshift(f),o}buildTabMenuItem(v,t){t.name&&(v=t.name);const n=this.moduleNavigation.getModuleRoute(t),o=this.language.getLanguageStrings()?.appListStrings??{},f={link:{label:this.moduleNavigation.getModuleLabel(t,o),url:n.url,route:n.route,params:null},icon:this.moduleNameMapper.toLegacy(v)??null,submenu:[],module:v??null,isGroupedMenu:!1};let D=!1;return t&&t.menu.forEach(j=>{const fe=j.sublinks||[],Ne=this.buildSubMenuItem(v,j,fe);f.submenu.push(Ne),fe.length>0&&(D=!0)}),f.isGroupedMenu=D,f}buildSubMenuItem(v,t,n){const o=this.moduleNavigation.getActionRoute(t);return{link:{label:this.moduleNavigation.getActionLabel(v,t,this.language.getLanguageStrings()),url:o.url,route:o.route,params:o.params,process:o.process},icon:t.icon||"",submenu:n.map(D=>this.buildSubMenuItem(v,D,[]))}}sortMenuItems(v){v.sort((t,n)=>{const o=t.link.label.toUpperCase(),f=n.link.label.toUpperCase();return o<f?-1:o>f?1:0})}}let Xs=(()=>{class r{constructor(t,n,o){this.moduleNameMapper=t,this.actionNameMapper=n,this.systemConfigStore=o}toFrontEndLink(t){return"#/"+this.toFrontEndRoute(t)}toFrontEndRoute(t){if(t&&t.includes("/#/")){const f=t.split("/#/");return f.length<2?"/":f[1]}const n=this.parse(t);if(!n)return"/";let o=this.buildRoute(n.module,n.action,n.record);return o+=this.buildQueryString(n.params,["module","action","record"]),o}toLegacy(t,n){let o="./legacy/index.php";const f={...n};return t.module&&(f.module=this.moduleNameMapper.toLegacy(t.module)),t.action&&(f.action=this.actionNameMapper.toLegacy(t.action)),t.record&&(f.record=t.record),o+=this.buildQueryString(f),o}parse(t){const n=new Wo.DefaultUrlSerializer,f=t.replace("/legacy","").split("?");if(f.length<2)return null;const D=n.parse("/?"+f[1]),j=D.queryParamMap;return{module:j.get("module")||"",action:j.get("action")||"",record:j.get("record")||"",params:D.queryParams}}parseRouteURL(t){return{module:t[0]?.path??"",action:t[1]?.path??"index",record:t[2]?.path??""}}parseRouteInfoFromUrlTree(t){return this.parseRouteURL(t.root.children[Wo.PRIMARY_OUTLET].segments)}isClassicViewRoute(t){const n=this.systemConfigStore.getConfigValue("module_routing"),o=this.parseRouteInfoFromUrlTree(t),f=o.module;return!n[f]||!n[f][o.action]}matchesActiveRoute(t,n){let f=!0;return[{name:"module",map:D=>D&&this.mapModuleToFrontend(D)},{name:"action",map:D=>D&&this.mapActionToFrontEnd(D)},{name:"record",map:D=>D}].forEach(D=>{!t.snapshot.params[D.name]&&!n[D.name]||(f=f&&t.snapshot.params[D.name]===D.map(n[D.name]))}),f}buildRoute(t,n,o){let D=`${this.mapModuleToFrontend(t)}`;return n&&(D+=`/${this.mapActionToFrontEnd(n)}`),o&&(D+=`/${o}`),D}buildQueryString(t,n=[]){let o=new Op.HttpParams;return Object.keys(t).forEach(f=>{n.includes(f)||(o=o.set(f,t[f]))}),o.keys().length>0?"?"+o.toString():""}mapModuleToFrontend(t){return this.moduleNameMapper.toFrontend(t)}mapActionToFrontEnd(t){return this.actionNameMapper.toFrontend(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Up),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),il=(()=>{class r{constructor(t){this.router=t}navigateToSearch(t,n){let o="/home/search";"UnifiedSearch"===n&&(o="/home/unified-search");let f="";return t&&(f=t),this.router.navigate([o],{queryParams:{query_string:f}})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Da=["searchInput"],fd=r=>({"search-focused":r}),zd=r=>({"dropdown-active":r});function Sm(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"ul",9)(1,"li",10)(2,"a",11),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.searchWithEnter())}),e.\u0275\u0275element(3,"scrm-image",12),e.\u0275\u0275elementStart(4,"span",13),e.\u0275\u0275text(5,'"'),e.\u0275\u0275elementStart(6,"strong"),e.\u0275\u0275text(7),e.\u0275\u0275elementEnd(),e.\u0275\u0275text(8),e.\u0275\u0275pipe(9,"lowercase"),e.\u0275\u0275elementEnd()()()()}if(2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(5,zd,n.searchWord)),e.\u0275\u0275advance(6),e.\u0275\u0275textInterpolate(n.searchWord),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1('" ',e.\u0275\u0275pipeBind1(9,3,t.appStrings.LBL_IN_EVERYWHERE),"")}}function Ef(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",14),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.searchWithEnter())}),e.\u0275\u0275element(1,"scrm-image",12),e.\u0275\u0275elementEnd()}}function df(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",15),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.clearSearchTerm())}),e.\u0275\u0275element(1,"scrm-image",16),e.\u0275\u0275elementEnd()}}function Cp(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"form",2)(2,"div",3)(3,"input",4,0),e.\u0275\u0275listener("focus",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onFocus())})("blur",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onBlur())})("keydown.enter",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView("enter"===o.searchTrigger?o.searchWithEnter():null)})("input",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275reference(4),f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView("input"===f.searchTrigger?f.searchWithInput(o.value):null)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,Sm,10,7,"ul",5),e.\u0275\u0275elementStart(6,"div",6),e.\u0275\u0275template(7,Ef,2,0,"button",7)(8,df,2,0,"button",8),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",n.klass)("formGroup",n.searchForm),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(8,fd,n.isFocused)),e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate1("placeholder","",t.appStrings[n.labelKey]||"","..."),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.searchWord.length&&n.hasSearchTyped&&"enter"===n.searchTrigger),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!n.hasSearchTyped),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.hasSearchTyped)}}let Yb=(()=>{class r{constructor(t){this.languageStore=t,this.labelKey="",this.klass="",this.isMobile=!1,this.searchTrigger="enter",this.isSearchVisible=new e.EventEmitter(!1),this.searchExpression=new e.EventEmitter,this.searchWord="",this.isFocused=!1,this.hasSearchTyped=!1,this.subs=[],this.languages$=this.languageStore.vm$,this.vm$=this.languages$.pipe((0,M.map)(n=>({appStrings:n.appStrings||{}})))}ngOnInit(){this.searchForm=new Ji.FormGroup({searchTerm:new Ji.FormControl("")}),this.subs.push(this.searchForm.get("searchTerm").valueChanges.pipe((0,M.tap)(t=>{this.hasSearchTyped=!!t}),(0,M.distinctUntilChanged)(),(0,M.filter)(t=>t?.length>1)).subscribe(t=>this.searchWord=t))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}searchWithEnter(){this.searchWord.length?(this.searchExpression.emit(this.searchWord),this.clearSearchTerm(),this.searchInput.nativeElement.blur()):this.isMobile&&this.onBlur()}searchWithInput(t){this.searchExpression.emit(t)}clearSearchTerm(){this.searchForm.reset(),this.hasSearchTyped=!1,this.searchWord="","input"===this.searchTrigger&&this.searchWithInput(this.searchWord)}onFocus(){this.isFocused=!0;const t=this.searchForm?.get("searchTerm")?.value??"";t.length>2&&(this.hasSearchTyped=!0,this.searchWord=t)}onBlur(){setTimeout(()=>{this.isFocused=!1,this.hasSearchTyped=!1},200),this.isMobile&&setTimeout(()=>{this.isSearchVisible.emit(!1)},50)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-search-bar"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(Da,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.searchInput=f.first)}},inputs:{labelKey:"labelKey",klass:"klass",isMobile:"isMobile",searchTrigger:"searchTrigger"},outputs:{isSearchVisible:"isSearchVisible",searchExpression:"searchExpression"},decls:2,vars:3,consts:[["searchInput",""],[4,"ngIf"],["name","search-bar",1,"search-bar",3,"ngClass","formGroup"],[1,"input-group","dropdown",3,"ngClass"],["formControlName","searchTerm","type","text","name","search-bar-term","aria-label","Search","data-toggle","dropdown","autocomplete","off","required","",1,"form-control","dropdown-toggle","search-bar-term",3,"focus","blur","keydown.enter","input","placeholder"],["class","dropdown-menu global-search-dropdown",4,"ngIf"],[1,"input-group-append"],["class","btn btn-default search-button d-flex align-items-center","aria-label","Search","scrm-button-loading","",3,"click",4,"ngIf"],["class","btn btn-default search-button d-flex align-items-center","aria-label","Close Search","scrm-button-loading","",3,"click",4,"ngIf"],[1,"dropdown-menu","global-search-dropdown"],[1,"dropdown-item-block",3,"ngClass"],[1,"dropdown-item",3,"click"],["image","search",1,"search-icon","sicon"],[1,"dropdown-text","ml-2"],["aria-label","Search","scrm-button-loading","",1,"btn","btn-default","search-button","d-flex","align-items-center",3,"click"],["aria-label","Close Search","scrm-button-loading","",1,"btn","btn-default","search-button","d-flex","align-items-center",3,"click"],["image","cross",1,"search-icon","sicon"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Cp,9,10,"ng-container",1),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgClass,ve.NgIf,Ji.\u0275NgNoValidate,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgControlStatusGroup,Ji.RequiredValidator,Bl,Ji.FormGroupDirective,Ji.FormControlName,ve.AsyncPipe,ve.LowerCasePipe],encapsulation:2})}return r})(),Em=(()=>{class r extends Vt{constructor(t,n,o,f,D,j,fe,Ne){super(t,n,o,f,D,j,fe,Ne),this.actionManager=t,this.asyncActionService=n,this.message=o,this.confirmation=f,this.language=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}getActionName(t){return`record-${t.key}`}buildActionInput(t,n,o,f=null){return{action:n,module:o,id:f&&f.record&&f.record.id||"",params:t&&t.params||[]}}static#e=this.\u0275fac=function(n){e.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();class AT extends kp{checkRecordAccess(v,t=[]){return!0}navigateBack(v,t,n,o,f){let D=v.getReturnModule(t),j=v.getReturnAction(t),fe=v.getReturnId(t);n!==fe&&(D===o&&"record"===j&&fe!==n||!D||!j||v.navigateBack(f,o,t))}}let dO=(()=>{class r extends AT{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){const n=t?.action?.acl??[];return!n.length||this.checkRecordAccess(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),nI=(()=>{class r extends js{constructor(t){super(),this.async=t,t.modes.forEach(n=>this.actions[n][t.key]=t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(dO))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),RA=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt){super(o,f,D,j,n,fe,Ne,vt),this.threadStore=t,this.language=n,this.actionManager=o,this.asyncActionService=f,this.message=D,this.confirmation=j,this.selectModalService=fe,this.metadata=Ne,this.appMetadataStore=vt,this.defaultActions={detail:[],edit:[],create:[],list:[]},this.collapseButtons=!1}getActions(t){return(0,i.of)(this.threadStore.getListMetadata()).pipe((0,i.combineLatestWith)((0,i.of)("list")),(0,M.map)(([n,o])=>o&&n?this.parseModeActions(n.actions,o,this.threadStore.getViewContext()):[]))}getActionName(t){return`record-thread-list-${t.key}`}buildActionData(t,n){return{threadStore:this.threadStore,action:t}}buildActionInput(t,n,o,f=null){return this.message.removeMessages(),{action:n,module:this.threadStore.module,ids:this.threadStore.getRecordIds(),params:t&&t.params||[]}}getMode(){return"list"}getModuleName(t){return this.threadStore.module}reload(t,n,o){cl(n?.data?.reloadThread??!1)&&this.threadStore.reload()}shouldReload(t){return cl(t?.data?.reloadThread??!1)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Po),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(nI),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),iI=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.language=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t,n){const o=new RA(t,this.language,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.selectModalService,this.metadata,this.appMetadataStore),f=n?.collapseListActions??null;return null!==f&&(o.collapseButtons=f),o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(nI),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();class Ww extends kp{checkRecordAccess(v,t=[]){const o=v.itemStore.recordStore.getBaseRecord().acls??[];return!(!o||!o.length)&&this.checkAccess(v.action??null,o,t)}navigateBack(v,t,n,o,f){let D=v.getReturnModule(t),j=v.getReturnAction(t),fe=v.getReturnId(t);n!==fe&&(D===o&&"record"===j&&fe!==n||!D||!j||v.navigateBack(f,o,t))}}let Xb=(()=>{class r extends Ww{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){const n=t?.action?.acl??[];return!n.length||this.checkRecordAccess(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),Dp=(()=>{class r extends Ww{constructor(t,n){super(),this.modalService=t,this.navigation=n,this.key="cancel",this.modes=["edit","detail"]}run(t){t.itemStore.recordStore.isDirty()?this.showConfirmationModal(t):this.cancel(t)}shouldDisplay(){return!0}cancel(t){t.itemStore.recordStore.resetStaging(),t.itemStore.setMode("detail")}showConfirmationModal(t){const n=this.modalService.open(Ye);n.componentInstance.textKey="WARN_UNSAVED_CHANGES",n.componentInstance.buttons=[{labelKey:"LBL_CANCEL",klass:["btn-secondary"],onClick:o=>o.dismiss()},{labelKey:"LBL_PROCEED",klass:["btn-main"],onClick:o=>{this.cancel(t),o.close()}}]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(Oc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),zc=(()=>{class r extends Ww{constructor(){super(),this.key="edit",this.modes=["detail"]}run(t){t.itemStore.setMode("edit")}shouldDisplay(t){return this.checkRecordAccess(t,["edit"])}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),fO=(()=>{class r extends Ww{constructor(t,n){super(),this.message=t,this.navigation=n,this.key="save",this.modes=["edit"]}run(t){t.itemStore.recordStore.validate().pipe((0,M.take)(1)).subscribe(n=>{n?t.itemStore.save().pipe((0,M.take)(1)).subscribe(o=>{t.itemStore.setMode("detail")}):this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Oc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),QS=(()=>{class r extends js{constructor(t,n,o,f){super(),this.async=t,this.cancel=n,this.edit=o,this.save=f,t.modes.forEach(D=>this.actions[D][t.key]=t),o.modes.forEach(D=>this.actions[D][o.key]=o),f.modes.forEach(D=>this.actions[D][f.key]=f),n.modes.forEach(D=>this.actions[D][n.key]=n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Xb),e.\u0275\u0275inject(Dp),e.\u0275\u0275inject(zc),e.\u0275\u0275inject(fO))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),gg=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){super(f,D,j,fe,o,Ne,vt,ln),this.itemStore=t,this.threadStore=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne,this.metadata=vt,this.appMetadataStore=ln,this.defaultActions={detail:[],edit:[],create:[]},this.collapseButtons=!1}getActions(t){return this.itemStore.meta$.pipe((0,i.combineLatestWith)(this.itemStore.mode$),(0,M.map)(([n,o])=>o&&n?this.parseModeActions(n.actions,o,this.itemStore.getViewContext()):[]))}getActionName(t){return`record-thread-item-${t.key}`}buildActionData(t,n){return{itemStore:this.itemStore,threadStore:this.threadStore,action:t}}buildActionInput(t,n,o,f=null){const D=this.itemStore.getBaseRecord();return this.message.removeMessages(),{action:n,module:D.module,id:D.id,params:t&&t.params||[]}}getMode(){return this.itemStore.getMode()}getModuleName(t){return this.itemStore.getModuleName()}reload(t,n,o){const f=n?.data?.reload??!1,D=n?.data?.reloadThread??!1;cl(f)&&this.itemStore.load(!1).pipe((0,M.take)(1)).subscribe(),cl(D)&&this.threadStore.reload()}shouldReload(t){const n=t?.data?.reload??!1,o=t?.data?.reloadThread??!1;return cl(n)||cl(o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Cr),e.\u0275\u0275inject(Po),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(QS),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),yv=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.language=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t,n,o=null){const f=new gg(t,n,this.language,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.selectModalService,this.metadata,this.appMetadataStore),D=o?.metadata?.collapseActions??null;return null!==D&&(f.collapseButtons=D),f}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(QS),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function Ha(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"label",3),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3).ngIf,n=e.\u0275\u0275nextContext(4).$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("ngClass",o.getLabelClass(n)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.label," ")}}function pO(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-label",9),2&r){const t=e.\u0275\u0275nextContext(3).ngIf,n=e.\u0275\u0275nextContext(4).$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("labelKey",t.labelKey)("ngClass",o.getLabelClass(n))}}function hO(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-dynamic-label",10),2&r){const t=e.\u0275\u0275nextContext(3).ngIf,n=e.\u0275\u0275nextContext(8);e.\u0275\u0275property("labelKey",t.dynamicLabelKey)("fields",n.record.fields)}}function LN(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275template(2,Ha,2,2,"label",6)(3,pO,1,2,"scrm-label",7)(4,hO,1,2,"scrm-dynamic-label",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf,n=e.\u0275\u0275nextContext(4).$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275classProp("pr-3","inline"===o.getLabelDisplay(n,o.mode)&&"none"!==o.getDisplay(n)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.label),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.label&&t.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dynamicLabelKey)}}function kN(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div"),e.\u0275\u0275element(2,"scrm-field",11),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf,n=e.\u0275\u0275nextContext(4).$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275classProp("flex-grow-1","inline"===o.getLabelDisplay(n,o.mode)),e.\u0275\u0275advance(),e.\u0275\u0275property("field",t)("klass",o.getFieldClass(n))("mode",o.mode)("record",o.record)("type",t.type)}}function PN(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,LN,5,5,"ng-container",1)(2,kN,3,7,"ng-container",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(5).$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","none"!==n.getLabelDisplay(t,n.mode)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","none"!==n.getDisplay(t))}}function Hw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,PN,3,2,"ng-container",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext(4).$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.shouldDisplay(n,t,o.mode))}}function rI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Hw,2,1,"ng-container",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.getField(n.record,t.field))}}function OT(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-action-group-menu",12),e.\u0275\u0275elementContainerEnd()),2&r){let t,n;const o=e.\u0275\u0275nextContext(7);e.\u0275\u0275advance(),e.\u0275\u0275property("buttonClass",null!==(t=o.config.buttonClass)&&void 0!==t?t:"")("buttonGroupClass",null!==(n=o.config.buttonGroupClass)&&void 0!==n?n:"")("config",o.config.actions)}}function LA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",5),e.\u0275\u0275template(2,rI,2,1,"ng-container",1)(3,OT,2,3,"ng-container",1),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275classProp("align-items-center","inline"===n.getLabelDisplay(t,n.mode))("flex-column","top"===n.getLabelDisplay(t,n.mode))("flex-row","inline"===n.getLabelDisplay(t,n.mode))("justify-content-end",!t.field),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.record),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.actionSlot&&n.config.actions)}}function mO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3),e.\u0275\u0275template(1,LA,4,10,"ng-container",1),e.\u0275\u0275elementEnd()),2&r){let t;const n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275classMapInterpolate1("record-flexbox-col ",o.getClass(n),""),e.\u0275\u0275property("ngClass",null!==(t=o.config.colClass)&&void 0!==t?t:null),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","hidden"!==n.display&&o.shouldColDisplayInMode(n,o.mode))}}function BN(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,mO,2,5,"div",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","hidden"!==t.display&&n.shouldColDisplayInMode(t,n.mode))}}function oI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",3),e.\u0275\u0275template(2,BN,2,1,"ng-container",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=v.$implicit,o=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate3("d-flex record-flexbox-row ",o.getJustify(n.justify)," ",o.getAlign(n.align)," ",o.getLayoutRowClass(n),""),e.\u0275\u0275property("ngClass",null!==(t=o.config.rowClass)&&void 0!==t?t:null),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",n.cols)}}function gO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,oI,3,7,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.layout.rows)}}function kA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,gO,2,1,"ng-container",1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMapInterpolate2("d-flex ",(t.config&&t.config.flexDirection?t.config.flexDirection:"flex-column")||""," ",t.config&&t.config.klass||"",""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.layout&&t.layout.rows)}}let FT=(()=>{class r{constructor(){this.mode="detail",this.maxColumns=4,this.sizeMap={handset:1,tablet:2,web:3,wide:4},this.subs=[]}ngOnInit(){if(!this.config)return;const t=this.config;t.record$&&this.subs.push(t.record$.subscribe(n=>{this.record=n??null})),t.mode$&&this.subs.push(t.mode$.subscribe(n=>{this.mode=n??"detail"})),t.layout$&&this.subs.push(t.layout$.subscribe(n=>{this.layout=n??null}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getRowClass(){return this.config.rowClass}getColClass(){return this.config.colClass}getSizeClass(t){return{regular:"text-regular",medium:"text-medium",large:"text-large","x-large":"text-x-large","xx-large":"text-xx-large",huge:"text-huge"}[t]||"text-regular"}getFontWeight(t){let n="font-weight-normal";return t&&cl(t)&&(n="font-weight-bolder"),n}getColor(t){return{yellow:"text-yellow",blue:"text-blue",green:"text-green",red:"text-red",purple:"text-purple",dark:"text-dark",grey:"text-grey"}[t]||""}getJustify(t){return{start:"justify-content-start",end:"justify-content-end",center:"justify-content-center",between:"justify-content-between",around:"justify-content-around"}[t]||""}getAlign(t){return{start:"align-items-start",end:"align-items-end",center:"align-items-center",baseline:"align-items-baseline",stretch:"align-items-stretch"}[t]||""}getLayoutRowClass(t){return t&&t.class||""}getClass(t){if(!t)return"";const n=[];return n.push(t.class||""),t.size&&n.push(this.getSizeClass(t.size)||""),t.bold&&n.push(this.getFontWeight(t.bold)||""),t.color&&n.push(this.getColor(t.color)||""),n.join(" ")}getLabelDisplay(t,n){return this.shouldLabelDisplayInMode(t,n)?t.labelDisplay||this.config&&this.config.labelDisplay||"inline":"none"}getField(t,n){return n&&n.name&&t&&t.fields?t.fields[n.name]??null:null}getFieldClass(t){let n=this.config.inputClass||{};return t.inputClass&&(n[t.inputClass]=!0),n}getLabelClass(t){let n=this.config.labelClass||{};return t.labelClass&&(n[t.labelClass]=!0),n}shouldDisplay(t,n,o){if(!this.shouldFieldDisplayInMode(t,o))return!1;if(!t.hideIfEmpty)return!0;let D=!1;return D=D||!!n.value,D=D||!(!n.valueList||!n.valueList.length),D=D||!(!n.valueObject||!Object.keys(n.valueObject).length),D}shouldColDisplayInMode(t,n){return this.shouldFieldDisplayInMode(t,n)||this.shouldLabelDisplayInMode(t,n)}shouldFieldDisplayInMode(t,n){const o=t?.modes??null;return!(o&&o.length&&!o.includes(n))}shouldLabelDisplayInMode(t,n){const o=t?.labelModes??null;return!(o&&o.length&&!o.includes(n))}getDisplay(t){return t.display||""}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-flexbox"]],inputs:{config:"config"},decls:1,vars:1,consts:[[3,"class",4,"ngIf"],[4,"ngIf"],[4,"ngFor","ngForOf"],[3,"ngClass"],[3,"ngClass","class",4,"ngIf"],[1,"d-flex"],[3,"ngClass",4,"ngIf"],[3,"labelKey","ngClass",4,"ngIf"],[3,"labelKey","fields",4,"ngIf"],[3,"labelKey","ngClass"],[3,"labelKey","fields"],[3,"field","klass","mode","record","type"],[3,"buttonClass","buttonGroupClass","config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,kA,2,5,"div",0),2&n&&e.\u0275\u0275property("ngIf",o.config)},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,Dm,Pa,Ph,Df],encapsulation:2})}return r})();const VN=["body"];function PA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-flexbox",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.buildConfig(t.config.metadata.headerLayout))}}function qp(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-flexbox",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.buildConfig(t.config.metadata.bodyLayout))}}function _h(r,v){1&r&&e.\u0275\u0275element(0,"div",7)}function sI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",8),e.\u0275\u0275element(1,"scrm-button",6),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.getCollapseButton())}}function vO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div")(1,"div",2),e.\u0275\u0275template(2,PA,2,1,"ng-container",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",null,0),e.\u0275\u0275template(5,qp,2,1,"ng-container",3)(6,_h,1,0,"div",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(7,sI,2,1,"div",5),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275classMapInterpolate2("d-flex flex-column record-thread-item ",t.config&&t.config.klass||""," ",t.dynamicClass,""),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.config.metadata&&t.config.metadata.headerLayout),e.\u0275\u0275advance(),e.\u0275\u0275classMapInterpolate1("record-thread-item-body flex-grow-1 ",t.getBodyClass(),""),e.\u0275\u0275classProp("collapsed",t.collapsible&&t.collapsed)("expanded",t.collapsible&&!t.collapsed),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.config.metadata&&t.config.metadata.bodyLayout),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.collapsible&&t.collapsed),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.collapsible)}}let BA=(()=>{class r{constructor(t){this.actionAdapterFactory=t,this.collapsed=!1,this.collapsible=!1,this.collapseLimit=300,this.dynamicClass="",this.subs=[],this.dynamicClassesMap={},this.dynamicClassFieldSubs=[]}ngOnInit(){this.actionAdapter=this.actionAdapterFactory.create(this.config.store,this.config.threadStore,this.config),this.initDynamicClass()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.dynamicClassFieldSubs.forEach(t=>t.unsubscribe())}ngAfterViewInit(){!this.config||!this.config.collapsible||setTimeout(()=>{(this.bodyEl.nativeElement.offsetHeight||this.bodyEl.nativeElement.height)>(this.config.collapseLimit||this.collapseLimit)&&(this.collapsible=!0,this.collapsed=!0)},2e3)}buildConfig(t){return{record$:this.config.store.stagingRecord$,mode$:this.config.store.mode$,layout$:(0,i.of)(t).pipe((0,M.shareReplay)(1)),inputClass:{...this.config.inputClass||{},"form-control form-control-sm":!0},buttonClass:this?.config?.buttonClass??"",buttonGroupClass:this?.config?.buttonGroupClass??"",labelClass:this?.config?.labelClass??{},rowClass:this?.config?.rowClass??{},colClass:this?.config?.colClass??{},actions:this?.actionAdapter,klass:this?.config?.containerClass,flexDirection:this?.config?.flexDirection||""}}getCollapseButton(){return{klass:"collapse-button btn btn-link btn-sm",labelKey:this.collapsed?"LBL_SHOW_MORE":"LBL_SHOW_LESS",onClick:()=>{this.collapsed=!this.collapsed,this.collapsed?this.config&&this.config.collapsed():this.config&&this.config.expanded()}}}initDynamicClass(){!this.config||!this.config.dynamicClass||!this.config.dynamicClass.length||this.subs.push(this.config.store.stagingRecord$.subscribe(t=>{const n={};this.dynamicClassFieldSubs.forEach(o=>o.unsubscribe()),t&&t.fields&&Object.keys(t.fields).length&&(this.config.dynamicClass.forEach(o=>{if(!o||!t.fields[o]&&!t.attributes[o])return;t.fields[o]&&this.dynamicClassFieldSubs.push(t.fields[o].valueChanges$.pipe((0,M.debounceTime)(100)).subscribe(()=>{const D=this.getDynamicClasses(o,t)??"";""!==D&&(this.dynamicClassesMap[o]=D,this.calculateDynamicClasses())}));const f=this.getDynamicClasses(o,t)??"";""!==f&&(n[o]=f)}),this.dynamicClassesMap=n,this.calculateDynamicClasses())}))}calculateDynamicClasses(){const t=[];Object.keys(this.dynamicClassesMap??{}).forEach(n=>{const o=this.dynamicClassesMap[n]??"";""!==o&&t.push(o)}),this.dynamicClass=t.join(" ")}getDynamicClasses(t,n){const o=t+"-";let f=[];return n.fields[t]?(n.fields[t].value&&f.push(n.fields[t].value),n.fields[t].valueList&&n.fields[t].valueList.length&&(f=f.concat(n.fields[t].valueList))):Array.isArray(n.attributes[t])?f=f.concat(n.attributes[t]):"object"!=typeof n.attributes[t]&&f.push(n.attributes[t]),f&&f.length?o+f.join(" "+o):""}getBodyClass(){return this.config?.metadata?.bodyLayout?.class??""}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(yv))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-thread-item"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(VN,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.bodyEl=f.first)}},inputs:{config:"config"},decls:1,vars:1,consts:[["body",""],[3,"class",4,"ngIf"],[1,"record-thread-item-header","flex-grow-1"],[4,"ngIf"],["class","fadeout",4,"ngIf"],["class","record-thread-item-collapse d-flex justify-content-center flex-grow-1",4,"ngIf"],[3,"config"],[1,"fadeout"],[1,"record-thread-item-collapse","d-flex","justify-content-center","flex-grow-1"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,vO,8,15,"div",1),2&n&&e.\u0275\u0275property("ngIf",o.config)},dependencies:[ve.NgIf,xc,FT],encapsulation:2})}return r})();const _O=["list"];function VA(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-label",7),e.\u0275\u0275elementEnd())}function Gc(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",8),e.\u0275\u0275element(1,"scrm-loading-spinner",9),e.\u0275\u0275elementEnd()),2&r&&(e.\u0275\u0275advance(),e.\u0275\u0275property("overlay",!0))}function yO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",14),e.\u0275\u0275element(1,"scrm-button",15),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.getLoadMoreButton())}}function bO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",null,1),e.\u0275\u0275element(2,"scrm-record-thread-item",15),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275reference(1),o=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.buildItem(t,n))}}function aI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",16),e.\u0275\u0275element(1,"scrm-button",15),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.getLoadMoreButton())}}function jA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-action-group-menu",17),e.\u0275\u0275elementContainerEnd()),2&r){let t,n;const o=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("buttonClass",null!==(t=o.config.listActionsButtonClass)&&void 0!==t?t:"")("buttonGroupClass",null!==(n=o.config.listActionsButtonGroupClass)&&void 0!==n?n:"")("config",o.listActionAdapter)}}function jN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",10,0),e.\u0275\u0275template(2,yO,2,1,"div",11)(3,bO,3,1,"div",12),e.\u0275\u0275elementStart(4,"div"),e.\u0275\u0275template(5,aI,2,1,"div",13)(6,jA,2,3,"ng-container",5),e.\u0275\u0275elementEnd()()),2&r){let t;const n=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngStyle",n.getMaxHeight()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf","top"===n.loadMorePosition&&!n.allLoaded()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",n.records),e.\u0275\u0275advance(),e.\u0275\u0275classMap(null!==(t=n.config.listActionsClass)&&void 0!==t?t:""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","bottom"===n.loadMorePosition&&!n.allLoaded()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.config.listActions)}}function vg(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div")(1,"h6",18),e.\u0275\u0275element(2,"scrm-label",19),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.config.noDataLabel||"LBL_NO_DATA")}}function NT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",21)(1,"div",22),e.\u0275\u0275element(2,"scrm-record-thread-item",15),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",23),e.\u0275\u0275element(4,"scrm-button",15),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.buildCreateItem()),e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.getCreateButton())}}function CO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,NT,5,2,"div",20),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loading)}}let RT=(()=>{class r{constructor(t,n,o,f,D){this.storeFactory=t,this.itemFactory=n,this.recordManager=o,this.message=f,this.actionAdapterFactory=D,this.loading=!1,this.maxHeight=400,this.direction="asc",this.loadMorePosition="top",this.shouldResetScroll=!1,this.subs=[]}ngOnInit(){if(Al(this.config.maxListHeight)||(this.maxHeight=this.config.maxListHeight),!this.config.module)return;this.config.store?this.store=this.config.store:(this.store=this.storeFactory.create(),this.store.setItemMetadata(this.config.itemConfig.metadata),this.store.setListMetadata({actions:this.config.listActions}),this.store.init(this.config.module,!1,this?.config?.pageSize??null)),this.direction=this.config.direction||this.direction,this.setLoadMorePosition(),this.initCreate(),this.initDataSubscription(),this.config.filters$?this.subs.push(this.config.filters$.subscribe(n=>{this.store.setFilters(n).pipe((0,M.take)(1)).subscribe(()=>{this.config.onRefresh&&this.config.onRefresh()})})):this.store.load(!1).subscribe(()=>{this.config.onRefresh&&this.config.onRefresh()});const t=this?.config?.autoRefreshFrequency??0;t&&this.store&&this.subs.push(this.store.initAutoRefresh(t,this.config.autoRefreshDeviationMin??-15,this.config.autoRefreshDeviationMax??15,this.config.onRefresh).subscribe()),this.initLoading(),this.listActionAdapter=this.actionAdapterFactory.create(this.store,this.config)}setLoadMorePosition(){this.loadMorePosition="asc"===this.direction?"top":"bottom",this.config.loadMorePosition&&(this.loadMorePosition=this.config.loadMorePosition)}ngAfterViewInit(){this.shouldResetScroll=!0,this.resetScroll()}ngOnDestroy(){(this?.config?.store??null)||this.store.clear(),this.store=null,this.subs.forEach(t=>t.unsubscribe())}buildItem(t,n){let o="record-thread-list-item";return this.config.itemConfig.klass&&(o+=" "+this.config.itemConfig.klass),{...this.config.itemConfig,store:t,threadStore:this.store,klass:o,containerClass:this.config.itemConfig.containerClass,flexDirection:this.config?.itemConfig?.flexDirection??"",expanded:()=>{this.scrollToItem(n)},collapsed:()=>{this.scrollToItem(n)}}}getLoadMoreButton(){return{klass:"load-more-button btn btn-link btn-sm",labelKey:"LBL_LOAD_MORE",onClick:()=>{this?.config?.onLoadMore&&this.store.getRecordList().records$.pipe((0,M.take)(1),(0,M.tap)(()=>this.config.onLoadMore())).subscribe(),this.store.loadMore()}}}buildCreateItem(){return{...this?.config?.createConfig??{},store:this.createStore,rowClass:{"pt-1":!0},klass:"record-thread-create-item"}}getCreateButton(){return{klass:"create-thread-item-button btn btn-main btn-sm",labelKey:"LBL_SUBMIT_BUTTON_LABEL",onClick:()=>{this.createStore.validate().pipe((0,M.take)(1)).subscribe(t=>{t?this.createStore.save().pipe((0,M.take)(1)).subscribe(()=>{this.store.reload(),this.initRecord(),this.shouldResetScroll=!0,this.message.addSuccessMessageByKey("LBL_ACTION_SUCCESS")}):this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}}}allLoaded(){return!(!this.store||!this.store.allLoaded())}getMaxHeight(){return 0==this.maxHeight?null:{"max-height.px":this.maxHeight,"overflow-y":"auto"}}initRecord(){const t=this.recordManager.buildEmptyRecord(this.config.module);this.addPresetFields(t);let n="edit";this?.config?.createConfig&&this?.config?.createConfig?.initialMode&&(n=this.config.createConfig.initialMode),this.createStore.initRecord(t,n,!1,!0)}scrollToEnd(){!this.listContainer||!this.listContainer.nativeElement||this.scrollTo(this.listContainer.nativeElement.scrollHeight)}scrollToTop(){this.scrollTo(0)}scrollTo(t){try{this.listContainer.nativeElement.scrollTop=t}catch{}}scrollToItem(t){t&&this.listContainer&&this.listContainer.nativeElement&&this.scrollTo(t.offsetTop-this.listContainer.nativeElement.offsetTop)}resetScroll(){!1!==this.shouldResetScroll&&("asc"===this.direction?this.scrollToEnd():this.scrollToTop(),this.shouldResetScroll=!1)}scheduleScrollReset(){setTimeout(()=>{this.resetScroll()},500)}initCreate(){this.config.create&&(this.createStore=this.itemFactory.create(),this.createStore.setMetadata(this.config.createConfig.metadata),this.initRecord(),this.initPresetFieldsMapping())}initPresetFieldsMapping(){this.config.presetFields$&&this.subs.push(this.config.presetFields$.subscribe(t=>{if(!t||!Object.keys(t).length)return;this.presetFieldValues=t;const n=this.createStore.recordStore.getBaseRecord();this.addPresetFields(n),this.createStore.recordStore.setRecord(n)}))}addPresetFields(t){this.presetFieldValues&&(t.attributes={...this.presetFieldValues,...t.attributes||{}})}initDataSubscription(){this.subs.push(this.store.stores$.subscribe(t=>{if((!this.records||!this.records.length)&&(this.shouldResetScroll=!0),"asc"===this.direction)return this.records=t.reverse(),void this.scheduleScrollReset();this.records=t,this.scheduleScrollReset()}))}initLoading(){let t;t=this.store.$loading.pipe(this.createStore&&this.createStore.loading$?(0,i.combineLatestWith)(this.createStore.loading$):(0,M.map)(n=>[n])),this.subs.push(t.subscribe(n=>{if(!n||!n.length)return void(this.loading=!1);let o=!1;n.forEach(f=>{o=o||f}),this.loading=o}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(wi),e.\u0275\u0275directiveInject(So),e.\u0275\u0275directiveInject(Dd),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(iI))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-thread"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(_O,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.listContainer=f.first)}},inputs:{config:"config"},decls:6,vars:8,consts:[["list",""],["item",""],["class","d-flex record-thread-no-data justify-content-center h3",4,"ngIf"],["class","d-flex record-thread-loading justify-content-center",4,"ngIf"],["class","record-thread-list scrollbar-thick",3,"ngStyle",4,"ngIf"],[4,"ngIf"],[1,"d-flex","record-thread-no-data","justify-content-center","h3"],["labelKey","LBL_NO_DATA"],[1,"d-flex","record-thread-loading","justify-content-center"],[3,"overlay"],[1,"record-thread-list","scrollbar-thick",3,"ngStyle"],["class","record-thread-load-more d-flex justify-content-center flex-grow-1",4,"ngIf"],[4,"ngFor","ngForOf"],["class","record-thread-load-more d-flex justify-content-center",4,"ngIf"],[1,"record-thread-load-more","d-flex","justify-content-center","flex-grow-1"],[3,"config"],[1,"record-thread-load-more","d-flex","justify-content-center"],[3,"buttonClass","buttonGroupClass","config"],[1,"pt-3","pl-3","pr-3","pb-2"],[3,"labelKey"],["class","d-flex flex-column record-thread-create-container",4,"ngIf"],[1,"d-flex","flex-column","record-thread-create-container"],[1,"flex-grow-1"],[1,"flex-grow-1","d-flex","justify-content-start","pt-1","record-thread-create-buttons"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,VA,2,0,"div",2)(2,Gc,2,1,"div",3)(3,jN,7,7,"div",4)(4,vg,3,1,"div",5)(5,CO,2,1,"ng-container",5),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMapInterpolate1("record-thread ",o.config&&o.config.klass||"",""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.loading&&!o.records&&!o.records.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.records&&o.records.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(!o.records||!o.records.length)&&!o.loading&&o.config.showNoDataMessage),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.create&&o.createStore))},dependencies:[ve.NgForOf,ve.NgIf,ve.NgStyle,xc,Pa,BA,af,Ph],encapsulation:2})}return r})();function DO(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",2),e.\u0275\u0275element(2,"scrm-label",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function lI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-thread",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.recordThreadConfig)}}let P_=(()=>{class r{constructor(t,n,o,f,D){this.language=t,this.systemConfig=n,this.message=o,this.notificationService=f,this.notificationStore=D}ngOnInit(){this.options=this.notificationService.getOptions(),this.recordThreadConfig=this.getConfig()}getConfig(){const t={filters$:(0,i.of)({orderBy:this?.options?.filters?.orderBy??"date_entered",sortOrder:this?.options?.filters?.sortOrder??"asc",preset:{type:"alerts"}}),module:this.options.module,klass:this.options.class??"",maxListHeight:this.options.maxListHeight??350,direction:this.options.direction||"asc",autoRefreshFrequency:this.options.autoRefreshFrequency||0,autoRefreshDeviationMin:this.options.autoRefreshDeviationMin??0,autoRefreshDeviationMax:this.options.autoRefreshDeviationMax??0,onRefresh:()=>{this.notificationService.onRefresh(this.store,this.notificationStore)},onLoadMore:()=>{this.notificationService.onLoadMore(this.notificationStore)},loadMorePosition:this.options?.loadMorePosition??"",create:!1,listActionsClass:this.options?.listActionsClass??"",listActionsButtonClass:this.options?.listActionsButtonClass??"",listActionsButtonGroupClass:this.options?.listActionsButtonGroupClass??"",pageSize:this.options?.pageSize??"",showNoDataMessage:this.options?.showNoDataMessage,noDataLabel:this.options?.noDataLabel};return this.notificationService.setupListActions(t,this.options),this.notificationService.setupItemConfig(t,this.options),t.store=this.notificationStore.getNotificationStore(),this.store=this.notificationStore.getNotificationStore(),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(ha),e.\u0275\u0275directiveInject(hs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-notifications"]],decls:3,vars:2,consts:[["widget-body","",1,"notifications"],[4,"ngIf"],[1,"p-3","widget-message"],["labelKey","LBL_BAD_CONFIG"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,DO,3,0,"ng-container",1)(2,lI,2,1,"ng-container",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.options),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.options))},dependencies:[ve.NgIf,Pa,RT],encapsulation:2})}return r})();function wO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",4)(1,"a",5),e.\u0275\u0275element(2,"scrm-image",6),e.\u0275\u0275elementStart(3,"div",7)(4,"span",8),e.\u0275\u0275element(5,"scrm-label",9),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"span",10),e.\u0275\u0275text(7),e.\u0275\u0275elementEnd()()()()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",null==t.attributes?null:t.attributes.route),e.\u0275\u0275advance(),e.\u0275\u0275property("image",null==t||null==t.attributes?null:t.attributes.module_name),e.\u0275\u0275advance(3),e.\u0275\u0275property("labelKey",null==t||null==t.attributes?null:t.attributes.module_name),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(null==t||null==t.attributes?null:t.attributes.item_summary)}}function xO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"ul",2),e.\u0275\u0275template(2,wO,8,4,"li",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.itemWithRoutes())}}function SO(r,v){1&r&&(e.\u0275\u0275elementStart(0,"h6",11),e.\u0275\u0275element(1,"scrm-label",12),e.\u0275\u0275elementEnd())}let cI=(()=>{class r{set menuItems(t){this._menuItems.set(t)}constructor(t,n){this.nameMapper=t,this.navigation=n,this._menuItems=(0,e.signal)([]),this.itemWithRoutes=(0,e.computed)(()=>this._menuItems().map(o=>o.attributes?.route?o:{...o,attributes:{...o.attributes,route:this.buildRoute(o)}}))}buildRoute(t){const o=this.nameMapper.toFrontend(t.attributes.module_name??"")??"";return this.navigation.getRecordRouterLink(o,t.attributes.item_id??"")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(Oc))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-recently-viewed"]],inputs:{menuItems:"menuItems"},standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:3,vars:2,consts:[["noItems",""],[4,"ngIf","ngIfElse"],[1,"p-0","mb-0"],["class","recently-viewed-header d-flex",4,"ngFor","ngForOf"],[1,"recently-viewed-header","d-flex"],[1,"new-list-item","d-flex",3,"routerLink"],[1,"action-btn-icon","mr-3",3,"image"],[1,"d-flex","flex-column"],[1,"text-title","text-uppercase"],["listKey","moduleList",3,"labelKey"],[1,"text-subtitle"],[1,"d-flex","justify-content-center","pt-3","pb-2"],["labelKey","LBL_LAST_VIEWED_NO_RESULT"]],template:function(n,o){if(1&n&&e.\u0275\u0275template(0,xO,3,1,"ng-container",1)(1,SO,2,0,"ng-template",null,0,e.\u0275\u0275templateRefExtractor),2&n){const f=e.\u0275\u0275reference(2);e.\u0275\u0275property("ngIf",o.itemWithRoutes()&&o.itemWithRoutes().length)("ngIfElse",f)}},dependencies:[ve.CommonModule,ve.NgForOf,ve.NgIf,Vl,Bl,Wo.RouterLink,Ea,Pa],encapsulation:2,changeDetection:0})}return r})();function UN(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",3),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275propertyInterpolate("image",t.icon)}}function $N(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"truncate"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(e.\u0275\u0275pipeBind2(2,1,t.link.label,t.charSize.mediumLength))}}function EO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"truncate"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(e.\u0275\u0275pipeBind2(2,1,t.link.label,t.charSize.maxLength))}}function TO(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",1),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.config.onClick(o))})("touchstart",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.config.onTouchStart(o))}),e.\u0275\u0275template(2,UN,1,1,"scrm-image",2)(3,$N,3,4,"span",0)(4,EO,3,4,"span",0),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",t.class),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.link.params),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.link.params)}}function uI(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",3),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275propertyInterpolate("image",t.icon)}}function WN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"truncate"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(e.\u0275\u0275pipeBind2(2,1,t.link.label,t.charSize.mediumLength))}}function HN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"truncate"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(e.\u0275\u0275pipeBind2(2,1,t.link.label,t.charSize.maxLength))}}function LT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a",7),e.\u0275\u0275template(1,uI,1,1,"scrm-image",2)(2,WN,3,4,"span",0)(3,HN,3,4,"span",0),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.class)("queryParams",t.link.params)("routerLink",t.link.route),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.link.params),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.link.params)}}function zN(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",3),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275propertyInterpolate("image",t.icon)}}function dI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a",8),e.\u0275\u0275template(1,zN,1,1,"scrm-image",2),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("href",t.link.url,e.\u0275\u0275sanitizeUrl)("ngClass",t.class),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.link.label," ")}}function fI(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",3),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275propertyInterpolate("image",t.icon)}}function UA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a",9),e.\u0275\u0275template(1,fI,1,1,"scrm-image",2),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("ngClass",t.class),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.link.label," ")}}function zw(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,LT,4,6,"a",4)(2,dI,3,4,"a",5)(3,UA,3,3,"a",6),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.link.route),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.link.route&&t.link.url),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.link.route&&!t.link.url)}}function GN(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-image",3),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275propertyInterpolate("image",t.icon)}}function KN(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",10),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.handleProcess(o.link.process))}),e.\u0275\u0275template(2,GN,1,1,"scrm-image",2),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",t.class),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.link.label," ")}}let MO=(()=>{class r{constructor(t,n,o){this.asyncActionService=t,this.systemConfigStore=n,this.appState=o,this.charSize={minLength:20,mediumLength:20,maxLength:20}}ngOnInit(){const t=this.systemConfigStore.getUi("navbar_truncate_character_sizes");this.charSize={...t}}handleProcess(t){if(!t)return;const n=t,o={action:n,module:this.appState.getModule()};this.asyncActionService.run(n,o).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Tl),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(tl))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-menu-item-link"]],inputs:{link:"link",icon:"icon",class:"class",config:"config"},decls:3,vars:3,consts:[[4,"ngIf"],[3,"click","touchstart","ngClass"],[3,"image",4,"ngIf"],[3,"image"],[3,"ngClass","queryParams","routerLink",4,"ngIf"],[3,"href","ngClass",4,"ngIf"],[3,"ngClass",4,"ngIf"],[3,"ngClass","queryParams","routerLink"],[3,"href","ngClass"],[3,"ngClass"],[3,"click","ngClass"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,TO,5,4,"ng-container",0)(1,zw,4,3,"ng-container",0)(2,KN,4,3,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",!o.link.process&&(null==o.config?null:o.config.onClick)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(o.link.process||null!=o.config&&o.config.onClick)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.link.process))},dependencies:[ve.NgClass,ve.NgIf,Wo.RouterLink,Bl,Hd],encapsulation:2})}return r})(),m0=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",MO)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const pI=(r,v,t,n)=>({link:r,icon:v,class:t,config:n});function hI(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction4(2,pI,t.link,t.icon,t.class,t.config))}}let Gw=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(m0))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-menu-item-link"]],inputs:{link:"link",icon:"icon",class:"class",config:"config"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,hI,1,7,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();const IO=(r,v,t)=>({label:r,url:v,route:t});function AO(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"li",7),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onItemClick(o))})("touchstart",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onItemTouchStart(o))}),e.\u0275\u0275element(1,"scrm-menu-item-link",8),e.\u0275\u0275elementEnd()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classMap("submenu-nav-link nav-link action-link"),e.\u0275\u0275property("link",e.\u0275\u0275pureFunction3(3,IO,t.attributes.item_summary,n.buildRoute(t),n.buildRoute(t)))}}function $A(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",1)(2,"a",2),e.\u0275\u0275listener("touchstart",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onTouchStart(o))})("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275element(3,"scrm-image",3)(4,"scrm-label",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"ul",5),e.\u0275\u0275template(6,AO,2,7,"li",6),e.\u0275\u0275pipe(7,"slice"),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275classProp("active",t.showDropdown()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind3(7,3,t.records,0,t.maxDisplayed))}}let g0=(()=>{class r{constructor(t,n,o,f){this.navigation=t,this.nameMapper=n,this.configs=o,this.metadata=f,this.maxDisplayed=5,this.subs=[],this.showDropdown=(0,e.signal)(!1),this.clickType="click"}ngOnInit(){const t=this.configs.getConfigValue("ui")??{};this.maxDisplayed=parseInt(t.navigation_max_module_recently_viewed)??5,this.initMetadata$()}ngOnDestroy(){this.clear()}ngOnChanges(t){null!==(t?.module??null)&&(t?.module?.previousValue??"")!==(t?.module?.currentValue??"")&&(this.clear(),this.initMetadata$())}buildRoute(t){const o=this.nameMapper.toFrontend(t.attributes.module_name??"")??"";return this.navigation.getRecordRouterLink(o,t.attributes.item_id??"")}initMetadata$(){const t=this.metadata.allModuleMetadata$.pipe((0,M.map)(n=>n[this.module]??null));this.subs.push(t.subscribe(n=>{this.records=n?.recentlyViewed??null})),this?.config?.showDropdown$&&this.subs.push(this.config.showDropdown$.subscribe(n=>{this.showDropdown.set(n)}))}clear(){this.records=null,this.subs.forEach(t=>t.unsubscribe())}toggleDropdown(){if("touch"===this.clickType)return this.showDropdown.set(!this.showDropdown()),this.clickType="click",void this?.config?.onToggleDropdown(this.showDropdown())}onTouchStart(t){this.clickType="touch"}onItemClick(t){this.toggleDropdown(),this?.config?.onItemClick(t)}onItemTouchStart(t){this.onTouchStart(t),this?.config?.onItemTouchStart(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Fs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-sub-menu-recently-viewed"]],inputs:{module:"module",config:"config"},features:[e.\u0275\u0275NgOnChangesFeature],decls:1,vars:1,consts:[[4,"ngIf"],[1,"nav-item","dropdown-submenu","submenu","submenu-extra"],[1,"sub-nav-link","nav-link","action-link","dropdown-item","dropdown-toggle","pr-4",3,"touchstart","click"],["image","clock"],["labelKey","LBL_LAST_VIEWED"],[1,"dropdown-menu","submenu"],["class","nav-item",3,"click","touchstart",4,"ngFor","ngForOf"],[1,"nav-item",3,"click","touchstart"],[3,"link"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,$A,8,7,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.records&&o.records.length)},dependencies:[ve.NgForOf,ve.NgIf,Bl,Pa,Gw,ve.SlicePipe],encapsulation:2})}return r})(),kT=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",g0)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Kw=(r,v)=>({module:r,config:v});function bv(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction2(2,Kw,t.module,t.config))}}let mI=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(kT))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-sub-menu-recently-viewed"]],inputs:{module:"module",config:"config"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,bv,1,5,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})(),qC=(()=>{class r{constructor(t,n,o,f){this.navigation=t,this.nameMapper=n,this.configs=o,this.metadata=f,this.maxDisplayed=5,this.records=(0,e.signal)([]),this.subs=[]}ngOnInit(){const t=this.configs.getConfigValue("ui")??{};this.maxDisplayed=parseInt(t.navigation_max_module_favorites)??5,this.initMetadata$()}ngOnDestroy(){this.clear()}ngOnChanges(t){null!==(t?.module??null)&&(t?.module?.previousValue??"")!==(t?.module?.currentValue??"")&&(this.clear(),this.initMetadata$())}buildRoute(t){const o=this.nameMapper.toFrontend(t.attributes.parent_type??"")??"";return this.navigation.getRecordRouterLink(o,t.attributes.parent_id??"")}initMetadata$(){const t=this.metadata.allModuleMetadata$.pipe((0,M.map)(n=>n[this.module]??null));this.subs.push(t.subscribe(n=>{this.records.set(n?.favorites??null)}))}clear(){this.records.set(null),this.subs.forEach(t=>t.unsubscribe())}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Fs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],inputs:{module:"module"},features:[e.\u0275\u0275NgOnChangesFeature],decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();const qN=(r,v,t)=>({label:r,url:v,route:t});function Ta(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"li",7),e.\u0275\u0275listener("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onItemClick(o))})("touchstart",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onItemTouchStart(o))}),e.\u0275\u0275element(1,"scrm-menu-item-link",8),e.\u0275\u0275elementEnd()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classMap("submenu-nav-link nav-link action-link"),e.\u0275\u0275property("link",e.\u0275\u0275pureFunction3(3,qN,t.attributes.parent_name,n.buildRoute(t),n.buildRoute(t)))}}function QN(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",1)(2,"a",2),e.\u0275\u0275listener("touchstart",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onTouchStart(o))})("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275element(3,"scrm-image",3)(4,"scrm-label",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"ul",5),e.\u0275\u0275template(6,Ta,2,7,"li",6),e.\u0275\u0275pipe(7,"slice"),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275classProp("active",t.showDropdown()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind3(7,3,t.records(),0,t.maxDisplayed))}}let WA=(()=>{class r extends qC{constructor(t,n,o,f){super(t,n,o,f),this.navigation=t,this.nameMapper=n,this.configs=o,this.metadata=f,this.showDropdown=(0,e.signal)(!1),this.clickType="click"}ngOnInit(){super.ngOnInit(),this?.config?.showDropdown$&&this.subs.push(this.config.showDropdown$.subscribe(t=>{this.showDropdown.set(t)}))}toggleDropdown(){if("touch"===this.clickType)return this.showDropdown.set(!this.showDropdown()),this.clickType="click",void this?.config?.onToggleDropdown(this.showDropdown())}onTouchStart(t){this.clickType="touch"}onItemClick(t){this.toggleDropdown(),this?.config?.onItemClick(t)}onItemTouchStart(t){this.onTouchStart(t),this?.config?.onItemTouchStart(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Fs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-sub-menu-favorites"]],inputs:{config:"config"},features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[4,"ngIf"],[1,"nav-item","dropdown-submenu","submenu","submenu-extra"],[1,"sub-nav-link","nav-link","action-link","dropdown-item","dropdown-toggle","pr-4",3,"touchstart","click"],["image","star"],["labelKey","LBL_FAVORITES"],[1,"dropdown-menu","submenu"],["class","nav-item",3,"click","touchstart",4,"ngFor","ngForOf"],[1,"nav-item",3,"click","touchstart"],[3,"link"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,QN,8,7,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.records()&&o.records().length)},dependencies:[ve.NgForOf,ve.NgIf,Bl,Pa,Gw,ve.SlicePipe],encapsulation:2})}return r})(),HA=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",WA)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const YN=(r,v)=>({module:r,config:v});function YS(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction2(2,YN,t.module,t.config))}}let zA=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(HA))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-sub-menu-favorites"]],inputs:{module:"module",config:"config"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,YS,1,5,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();const XN=["topLink"],ZN=(r,v,t)=>({"top-nav-link":!0,"nav-link-nongrouped":!0,"dropdown-toggle":r,"hover-enabled":v,"nav-link-activated":t});function PT(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function JN(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,PT,1,0,"ng-container",4),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)}}function gI(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function vI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,gI,1,0,"ng-container",4),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)}}function Tm(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",11),e.\u0275\u0275element(1,"scrm-menu-item-link",12),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275classMap("sub-nav-link nav-link action-link"),e.\u0275\u0275property("icon",t.icon)("link",t.link)}}function GA(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"scrm-sub-menu-recently-viewed",13),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(2,"scrm-sub-menu-favorites",13),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("module",t.item.module)("config",t.recentlyViewedConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("module",t.item.module)("config",t.favoritesConfig)}}function _I(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",9),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.hideDropdown())}),e.\u0275\u0275template(1,Tm,2,4,"div",10)(2,GA,3,4,"ng-container",3),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("show",t.showDropdown())("hover-enabled",t.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.item.submenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.item&&t.item.module)}}function eR(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",5,1)(2,"span",6,2),e.\u0275\u0275listener("touchstart",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onTouchStart())})("touchend",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.onTouchEnd())})("click",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.onClick(o))}),e.\u0275\u0275element(4,"scrm-menu-item-link",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,_I,3,6,"div",8),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(4),e.\u0275\u0275classMap(e.\u0275\u0275pureFunction3(5,ZN,t.item.submenu.length,t.hoverEnabled(),t.showDropdown())),e.\u0275\u0275property("link",t.item.link)("config",t.topLinkConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.item.submenu.length)}}let XS=(()=>{class r{constructor(t,n){this.appStateStore=t,this.moduleNavigation=n,this.index=0,this.showDropdown=(0,e.signal)(!1),this.hoverEnabled=(0,e.signal)(!0),this.clickType="click",this.subs=[]}ngOnInit(){this.showRecentlyViewed=new i.Subject,this.showFavorites=new i.Subject,this.topLinkConfig={onClick:t=>{},onTouchStart:t=>{}},this.recentlyViewedConfig={onItemClick:t=>{"touch"===this.clickType&&(this.hideDropdown(),this.clickType="click")},onItemTouchStart:t=>{this.clickType="touch"},onToggleDropdown:t=>{t&&this.showFavorites.next(!1)},showDropdown$:this.showRecentlyViewed.asObservable()},this.favoritesConfig={onItemClick:t=>{"touch"===this.clickType&&(this.hideDropdown(),this.clickType="click")},onItemTouchStart:t=>{this.clickType="touch"},onToggleDropdown:t=>{t&&this.showRecentlyViewed.next(!1)},showDropdown$:this.showFavorites.asObservable()},this.subs.push(this.appStateStore.activeNavbarDropdown$.subscribe(t=>{this.index!==t&&this.hideDropdown()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.showRecentlyViewed.unsubscribe(),this.showFavorites.unsubscribe()}hideDropdown(){this.showDropdown.set(!1),this.hoverEnabled.set(!0)}navigate(){this.moduleNavigation.navigateUsingMenuItem(this.item)}onTopItemClick(t){if("click"===this.clickType)return this.appStateStore.resetActiveDropdown(),void this.navigate();this.toggleDropdown(),this.clickType="click"}toggleDropdown(){this.showDropdown.set(!this.showDropdown()),this.showDropdown()?(this.appStateStore.setActiveDropdown(this.index),this.hoverEnabled.set(!1)):(this.appStateStore.resetActiveDropdown(),this.hoverEnabled.set(!0))}onTouchStart(){this.clickType="touch"}onTouchEnd(){this.clickType="touch"}onClick(t){t.stopImmediatePropagation(),t.stopPropagation(),this.onTopItemClick(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Oc))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-menu-item"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(XN,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.topLink=f.first)}},inputs:{item:"item",index:"index"},decls:4,vars:2,consts:[["menuItem",""],["menuItemWrapper",""],["topLink",""],[4,"ngIf"],[4,"ngTemplateOutlet"],[1,"menu-item-wrapper"],["data-target",".navbar-collapse","data-toggle","collapse",3,"touchstart","touchend","click"],[3,"link","config"],["aria-labelledby","navbarDropdownMenuLink","class","dropdown-menu submenu",3,"show","hover-enabled","click",4,"ngIf"],["aria-labelledby","navbarDropdownMenuLink",1,"dropdown-menu","submenu",3,"click"],["class","nav-item",4,"ngFor","ngForOf"],[1,"nav-item"],[3,"icon","link"],[3,"click","module","config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,JN,2,1,"ng-container",3)(1,vI,2,1,"ng-container",3)(2,eR,6,9,"ng-template",null,0,e.\u0275\u0275templateRefExtractor),2&n&&(e.\u0275\u0275property("ngIf",o.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.hoverEnabled()))},dependencies:[ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,mI,zA,Gw],encapsulation:2})}return r})(),ZS=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",XS)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const tR=(r,v)=>({item:r,index:v});function nR(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction2(2,tR,t.item,t.index))}}let KA=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ZS))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-menu-item"]],inputs:{item:"item",index:"index"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,nR,1,5,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})(),JS=(()=>{class r{constructor(){}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-home-menu-item"]],inputs:{route:"route",active:"active"},decls:4,vars:3,consts:[[1,"navbar-nav","home-nav"],[1,"nav-item"],[1,"home-nav-link",3,"routerLink"],["image","home",1,"home-icon"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"ul",0)(1,"li",1)(2,"a",2),e.\u0275\u0275element(3,"scrm-image",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275classProp("active",o.active),e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",o.route))},dependencies:[Wo.RouterLink,Bl],encapsulation:2})}return r})(),OO=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",JS)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const iR=(r,v)=>({route:r,active:v});function rR(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction2(2,iR,t.route,t.active))}}let qA=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(OO))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-home-menu-item"]],inputs:{route:"route",active:"active"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,rR,1,5,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();const FO=(r,v,t)=>({"top-nav-link":!0,"nav-link-grouped":!0,"dropdown-toggle":r,"hover-enabled":v,"nav-link-activated":t}),NO=(r,v)=>({"sub-nav-link":!0,"nav-link":!0,"action-link":!0,"dropdown-item":r,"dropdown-toggle":v});function oR(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function RO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,oR,1,0,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)}}function sR(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function Ek(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,sR,1,0,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){e.\u0275\u0275nextContext();const t=e.\u0275\u0275reference(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",t)}}function Tk(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",7),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275elementStart(1,"a",8),e.\u0275\u0275text(2),e.\u0275\u0275pipe(3,"truncate"),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classProp("hover-enabled",t.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind2(3,3,t.item.link.label,t.charSize.minLength)," ")}}function Mk(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"span",7),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275elementStart(1,"li",9),e.\u0275\u0275element(2,"scrm-menu-item-link",10),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275classMap(e.\u0275\u0275pureFunction3(3,FO,t.item.submenu.length,t.hoverEnabled(),t.showDropdown())),e.\u0275\u0275property("link",t.item.link)}}function Ik(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"li",16)(1,"scrm-menu-item-link",17),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(o.hideDropdown())}),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275classMap("submenu-nav-link nav-link action-link"),e.\u0275\u0275property("icon",t.icon)("link",t.link)}}function LO(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"scrm-sub-menu-recently-viewed",18),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(2,"scrm-sub-menu-favorites",18),e.\u0275\u0275listener("click",function(o){return e.\u0275\u0275restoreView(t),e.\u0275\u0275resetView(o.stopPropagation())}),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("module",t.module)("config",n.recentlyViewedConfig),e.\u0275\u0275advance(),e.\u0275\u0275property("module",t.module)("config",n.favoritesConfig)}}function yI(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"ul",14),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.hideDropdown())}),e.\u0275\u0275template(1,Ik,2,4,"li",15)(2,LO,3,4,"ng-container",1),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(),n=t.$implicit,o=t.index,f=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("rounded-0",n.submenu&&1===n.submenu.length)("active",f.showSubDropdown[o]()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",n.submenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n&&n.module)}}function aR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",11),e.\u0275\u0275element(1,"scrm-menu-item-link",12),e.\u0275\u0275template(2,yI,3,6,"ul",13),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.index,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275classMap(e.\u0275\u0275pureFunction2(5,NO,t.submenu.length,t.submenu.length)),e.\u0275\u0275property("link",t.link)("config",o.getConfig(t,n)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.submenu.length)}}function lR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3),e.\u0275\u0275template(1,Tk,4,6,"span",4)(2,Mk,3,7,"span",4),e.\u0275\u0275elementStart(3,"ul",5),e.\u0275\u0275template(4,aR,3,8,"li",6),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.item.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.item.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275classProp("show",t.showDropdown())("hover-enabled",t.hoverEnabled())("mobile-admin-dropdown",t.item.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.item.submenu)}}let Kf=(()=>{class r{constructor(t,n,o){this.appStateStore=t,this.moduleNavigation=n,this.systemConfigStore=o,this.index=0,this.showDropdown=(0,e.signal)(!1),this.showSubDropdown=[],this.hoverEnabled=(0,e.signal)(!0),this.subs=[],this.clickType="click",this.openSubDropdown=null,this.charSize={minLength:20,mediumLength:20,maxLength:20}}ngOnInit(){this.showRecentlyViewed=new i.Subject,this.showFavorites=new i.Subject;const t=this.systemConfigStore.getUi("navbar_truncate_character_sizes");this.charSize={...t},this.subs.push(this.appStateStore.activeNavbarDropdown$.subscribe(o=>{this.index!==o&&this.hideDropdown()})),(this?.item?.submenu??[]).forEach(()=>{this.showSubDropdown.push((0,e.signal)(!1))}),this.recentlyViewedConfig={onItemClick:o=>{"touch"===this.clickType&&(this.hideDropdown(),this.clickType="click")},onItemTouchStart:o=>{this.clickType="touch"},onToggleDropdown:o=>{o&&this.showFavorites.next(!1)},showDropdown$:this.showRecentlyViewed.asObservable()},this.favoritesConfig={onItemClick:o=>{"touch"===this.clickType&&(this.hideDropdown(),this.clickType="click")},onItemTouchStart:o=>{this.clickType="touch"},onToggleDropdown:o=>{o&&this.showRecentlyViewed.next(!1)},showDropdown$:this.showFavorites.asObservable()}}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.showRecentlyViewed.unsubscribe(),this.showFavorites.unsubscribe()}hideDropdown(){this.showDropdown.set(!1),this.hoverEnabled.set(!0),this.showSubDropdown.forEach(t=>{t.set(!1)})}toggleDropdown(){this.showDropdown.set(!this.showDropdown()),this.showDropdown()?(this.appStateStore.setActiveDropdown(this.index),this.hoverEnabled.set(!1)):(this.appStateStore.resetActiveDropdown(),this.hideDropdown())}navigate(){this.moduleNavigation.navigateUsingMenuItem(this.item)}onSubItemClick(t,n,o){"click"!==this.clickType?(this.toggleSubDropdown(o),this.clickType="click"):this.navigate()}toggleSubDropdown(t){const n=this.openSubDropdown??-1;t!==n&&n>=0&&this?.showSubDropdown[n]?.set(!1),this.showSubDropdown[t]?.set(!this.showSubDropdown[t]()),this.openSubDropdown=t,this.showSubDropdown[t]()||(this.openSubDropdown=null)}getConfig(t,n){return{onClick:o=>{this.onSubItemClick(o,t,n)},onTouchStart:o=>{this.clickType="touch"}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-grouped-menu-item"]],inputs:{item:"item",subNavCollapse:"subNavCollapse",index:"index"},decls:4,vars:2,consts:[["groupedMenuItem",""],[4,"ngIf"],[4,"ngTemplateOutlet"],[1,"menu-item-wrapper"],["data-target",".navbar-collapse","data-toggle","collapse",3,"click",4,"ngIf"],["aria-labelledby","navbarDropdownMenuLink",1,"dropdown-menu","main"],["class","nav-item dropdown-submenu submenu",4,"ngFor","ngForOf"],["data-target",".navbar-collapse","data-toggle","collapse",3,"click"],["data-toggle","dropdown",1,"top-nav-link","nav-link-grouped","dropdown-toggle","active"],[1,"nav-item","active"],[3,"link"],[1,"nav-item","dropdown-submenu","submenu"],[3,"link","config"],["class","dropdown-menu submenu",3,"rounded-0","active","click",4,"ngIf"],[1,"dropdown-menu","submenu",3,"click"],["class","nav-item",4,"ngFor","ngForOf"],[1,"nav-item"],[3,"click","icon","link"],[3,"click","module","config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,RO,2,1,"ng-container",1)(1,Ek,2,1,"ng-container",1)(2,lR,5,9,"ng-template",null,0,e.\u0275\u0275templateRefExtractor),2&n&&(e.\u0275\u0275property("ngIf",o.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.hoverEnabled()))},dependencies:[ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,mI,zA,Gw,Hd],encapsulation:2})}return r})(),eE=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",Kf)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const BT=(r,v,t)=>({item:r,subNavCollapse:v,index:t});function cR(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction3(2,BT,t.item,t.subNavCollapse,t.index))}}let kO=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(eE))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-grouped-menu-item"]],inputs:{item:"item",subNavCollapse:"subNavCollapse",index:"index"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,cR,1,6,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();const uR=r=>({"hover-enabled":!0,"nav-link-activated":r}),dR=r=>({"hover-enabled":!1,"nav-link-activated":r});function fR(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"a",6),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275element(1,"scrm-label",7),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap(e.\u0275\u0275pureFunction1(3,uR,t.showDropdown())),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.labelKey)}}function PO(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"a",6),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.toggleDropdown())}),e.\u0275\u0275element(1,"scrm-label",7),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap(e.\u0275\u0275pureFunction1(3,dR,t.showDropdown())),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.labelKey)}}function pR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",8),e.\u0275\u0275element(1,"scrm-menu-item-link",9),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275classMap("nav-link action-link"),e.\u0275\u0275property("link",t.link)}}function hR(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"ul",1)(1,"li",2),e.\u0275\u0275template(2,fR,2,5,"a",3)(3,PO,2,5,"a",3),e.\u0275\u0275elementStart(4,"div",4),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.hideDropdown())}),e.\u0275\u0275template(5,pR,2,3,"div",5),e.\u0275\u0275elementEnd()()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275classProp("show",t.showDropdown())("hover-enabled",t.hoverEnabled()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.items)}}let tE=(()=>{class r{constructor(t){this.appStateStore=t,this.showDropdown=(0,e.signal)(!0),this.hoverEnabled=(0,e.signal)(!0),this.allowHover=(0,e.signal)(!0),this.isTouchDevice=(0,e.signal)(!1),this.subs=[]}ngOnInit(){this.subs.push(this.appStateStore.activeNavbarDropdown$.subscribe(t=>{this.index!==t&&this.hideDropdown()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}hideDropdown(){this.showDropdown.set(!1),this.hoverEnabled.set(!0)}toggleDropdown(){this.showDropdown.set(!this.showDropdown()),this.showDropdown()?(this.appStateStore.setActiveDropdown(this.index),this.hoverEnabled.set(!1)):(this.appStateStore.resetActiveDropdown(),this.hoverEnabled.set(!0))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-menu-items-list"]],inputs:{items:"items",labelKey:"labelKey",index:"index"},decls:1,vars:1,consts:[["class","navbar-list navbar-nav nav-collapsed-items",4,"ngIf"],[1,"navbar-list","navbar-nav","nav-collapsed-items"],[1,"top-nav","nav-item","dropdown","non-grouped"],["class","nav-link-nongrouped dropdown-toggle",3,"class","click",4,"ngIf"],["aria-labelledby","navbarDropdownMenuLink",1,"dropdown-menu","more-menu","submenu",3,"click"],["class","nav-item",4,"ngFor","ngForOf"],[1,"nav-link-nongrouped","dropdown-toggle",3,"click"],[3,"labelKey"],[1,"nav-item"],[3,"link"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,hR,6,7,"ul",0),2&n&&e.\u0275\u0275property("ngIf",o.items&&o.items.length>0)},dependencies:[ve.NgForOf,ve.NgIf,Pa,Gw],encapsulation:2})}return r})(),BO=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",tE)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const VO=(r,v,t)=>({items:r,labelKey:v,index:t});function jO(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction3(2,VO,t.items,t.labelKey,t.index))}}let QA=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(BO))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-menu-items-list"]],inputs:{items:"items",labelKey:"labelKey",index:"index"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,jO,1,6,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();const UO=["mobileGlobalLinkTitle"],mR=["searchTerm"],bI=["alertDropdown"],$O=()=>[];function WO(r,v){1&r&&(e.\u0275\u0275elementStart(0,"nav",8)(1,"div",9)(2,"ul",10)(3,"li",11),e.\u0275\u0275text(4,"\xa0 "),e.\u0275\u0275elementEnd()()()())}function HO(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"nav",12)(2,"div",13)(3,"ul",10)(4,"li",14),e.\u0275\u0275element(5,"scrm-logo-ui"),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementContainerEnd())}function zO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",31),e.\u0275\u0275element(1,"scrm-menu-item",32),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("item",t.navbar.current)}}function gR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",33),e.\u0275\u0275element(1,"scrm-grouped-menu-item",34),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("item",t.navbar.current)("subNavCollapse",t.subNavCollapse)}}function vR(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function YA(r,v){1&r&&e.\u0275\u0275element(0,"hr")}function XA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",36),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,YA,1,0,"hr",7),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=v.first,o=v.last;e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate("href",t.link.url,e.\u0275\u0275sanitizeUrl),e.\u0275\u0275propertyInterpolate("target",t.link.target),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1("",t.link.label," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!0===o||!0===n)}}function GO(r,v){if(1&r&&e.\u0275\u0275template(0,XA,4,4,"ng-container",35),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275property("ngForOf",t.navbar.globalActions)}}function KO(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"ul",15)(2,"div",16)(3,"button",17),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.toggleSidebar())}),e.\u0275\u0275element(4,"scrm-image",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"nav",19)(6,"ul",20),e.\u0275\u0275template(7,zO,2,1,"li",21)(8,gR,2,2,"li",22),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(9,"div",23),e.\u0275\u0275template(10,vR,1,0,"ng-container",24),e.\u0275\u0275elementStart(11,"div",25)(12,"li",26)(13,"a",27,1),e.\u0275\u0275element(15,"scrm-image",28),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(16,"div",29)(17,"span",30),e.\u0275\u0275text(18),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(19,GO,1,1,"ng-template",6),e.\u0275\u0275element(20,"scrm-logout-ui"),e.\u0275\u0275elementEnd()()()()(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275reference(14);e.\u0275\u0275nextContext(2);const n=e.\u0275\u0275reference(4),o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275property("ngClass",o.isSmallScreen()&&o.isSearchBoxVisible()?"d-none":"d-block"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.navbar.current&&!o.navbar.current.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null==o.navbar.current?null:o.navbar.current.submenu)&&o.navbar.current.isGroupedMenu),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngTemplateOutlet",n),e.\u0275\u0275advance(6),e.\u0275\u0275styleProp("min-width",t.offsetWidth,"px"),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate2("",o.navbar.currentUser.firstName," ",o.navbar.currentUser.lastName,""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.navbar.globalActions)}}function _R(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",46),e.\u0275\u0275element(2,"scrm-grouped-menu-item",47),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(2),e.\u0275\u0275property("item",t.navbar.current)("subNavCollapse",t.subNavCollapse)("index",1)}}function yR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",48),e.\u0275\u0275element(1,"scrm-menu-item",49),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("item",t.navbar.current)("index",1)}}function bR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",46),e.\u0275\u0275element(1,"scrm-grouped-menu-item",47),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.index,o=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("item",t)("subNavCollapse",o.subNavCollapse)("index",n+2)}}function CR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"ul",42),e.\u0275\u0275template(2,_R,3,3,"ng-container",7)(3,yR,2,2,"li",43)(4,bR,2,3,"li",44),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(5,"scrm-menu-items-list",45),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.navbar.current&&t.navbar.current.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.navbar.current&&!t.navbar.current.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.navbar.menu),e.\u0275\u0275advance(),e.\u0275\u0275property("items",t.navbar.all.modules)("index",t.navbar.menu.length+2)}}function DR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",48),e.\u0275\u0275element(1,"scrm-menu-item",49),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("item",t.navbar.current)("index",1)}}function ZA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",46),e.\u0275\u0275element(2,"scrm-grouped-menu-item",47),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(2),e.\u0275\u0275property("item",t.navbar.current)("subNavCollapse",t.subNavCollapse)("index",1)}}function qO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",52),e.\u0275\u0275element(1,"scrm-menu-item",49),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=v.index;e.\u0275\u0275advance(),e.\u0275\u0275property("item",t)("index",n+2)}}function JA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"ul",10),e.\u0275\u0275template(2,DR,2,2,"li",43)(3,ZA,3,3,"ng-container",7)(4,qO,2,2,"li",50),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(5,"scrm-menu-items-list",51),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.navbar.current&&!t.navbar.current.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null==t.navbar.current?null:t.navbar.current.submenu)&&t.navbar.current.isGroupedMenu),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.navbar.menu),e.\u0275\u0275advance(),e.\u0275\u0275property("items",t.navbar.all.modules)("index",t.navbar.menu.length+2)}}function CI(r,v){1&r&&e.\u0275\u0275elementContainer(0)}function QO(r,v){1&r&&e.\u0275\u0275element(0,"hr")}function e2(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",36),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,QO,1,0,"hr",7),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=v.first,o=v.last;e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate("href",t.link.url,e.\u0275\u0275sanitizeUrl),e.\u0275\u0275propertyInterpolate("target",t.link.target),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1("",t.link.label," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!0===o||!0===n)}}function t2(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,e2,4,4,"ng-container",35),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.navbar.globalActions)}}function YO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"nav",37)(2,"div",38),e.\u0275\u0275element(3,"scrm-home-menu-item",39),e.\u0275\u0275template(4,CR,6,5,"ng-container",7)(5,JA,6,5,"ng-container",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(6,CI,1,0,"ng-container",24),e.\u0275\u0275elementStart(7,"div",25)(8,"ul",10)(9,"li",26)(10,"a",40),e.\u0275\u0275element(11,"scrm-image",28),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(12,"div",41)(13,"span",30),e.\u0275\u0275text(14),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(15,t2,2,1,"ng-container",7),e.\u0275\u0275element(16,"scrm-logout-ui"),e.\u0275\u0275elementEnd()()()()(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf,n=e.\u0275\u0275reference(4),o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngbCollapse",o.mainNavCollapse),e.\u0275\u0275advance(),e.\u0275\u0275property("active",t.appState.module&&"home"===t.appState.module)("route",o.getHomePage()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","gm"==t.userPreferences.navigation_paradigm),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","gm"!=t.userPreferences.navigation_paradigm),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutlet",n),e.\u0275\u0275advance(8),e.\u0275\u0275textInterpolate2("",o.navbar.currentUser.firstName," ",o.navbar.currentUser.lastName,""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.navbar.globalActions)}}function wR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,HO,6,0,"ng-container",7)(2,KO,21,9,"ng-container",7)(3,YO,17,9,"ng-container",7),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.isUserLoggedIn),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.isUserLoggedIn&&t.mobileNavbar),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.isUserLoggedIn&&!t.mobileNavbar)}}function xR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",74),e.\u0275\u0275element(2,"scrm-label",75),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",n.url)("queryParams",null!==(t=null==n?null:n.params)&&void 0!==t?t:null),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",n.labelKey)("module",o.navbar.current.module)}}function DI(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",76),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext().$implicit,f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.handleProcess(o))}),e.\u0275\u0275element(2,"scrm-label",75),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.labelKey)("module",n.navbar.current.module)}}function VT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",73),e.\u0275\u0275template(1,xR,3,4,"ng-container",7)(2,DI,3,2,"ng-container",7),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.process),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.process)}}function XO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",70),e.\u0275\u0275element(2,"scrm-label",71),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,VT,3,2,"li",72),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(2),e.\u0275\u0275property("module",t.navbar.current.module),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.currentQuickActions)}}function n2(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",74),e.\u0275\u0275element(2,"scrm-label",75),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",n.url)("queryParams",null!==(t=null==n?null:n.params)&&void 0!==t?t:null),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",n.labelKey)("module",n.module)}}function nE(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",76),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext().$implicit,f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.handleProcess(o))}),e.\u0275\u0275element(2,"scrm-label",75),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.labelKey)("module",t.module)}}function B_(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",73),e.\u0275\u0275template(1,n2,3,4,"ng-container",7)(2,nE,3,2,"ng-container",7),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.process),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.process)}}function wI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"li",70),e.\u0275\u0275element(2,"scrm-label",77),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,B_,3,2,"li",72),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(3),e.\u0275\u0275property("ngForOf",null!==(t=null==n||null==n.navigation?null:n.navigation.quickActions)&&void 0!==t?t:e.\u0275\u0275pureFunction0(1,$O))}}function ed(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate(t)}}function jT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",83),e.\u0275\u0275template(1,ed,2,1,"ng-container",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t>0)}}function ZO(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,jT,2,1,"span",82),e.\u0275\u0275elementContainerEnd()),2&r){let t;const n=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",null!==(t=n)&&void 0!==t&&t)}}function SR(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",78,3)(2,"ul",55)(3,"li",26)(4,"a",79),e.\u0275\u0275listener("mouseenter",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.markAsRead())}),e.\u0275\u0275element(5,"scrm-image",80),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(6,ZO,2,1,"ng-container",7),e.\u0275\u0275pipe(7,"async"),e.\u0275\u0275elementStart(8,"div",81),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.closeNotificationMenu())}),e.\u0275\u0275element(9,"scrm-notifications"),e.\u0275\u0275elementEnd()()()()}if(2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(6),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(7,1,t.notificationCount$))}}function ER(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",53)(1,"div",54)(2,"ul",55)(3,"li",26)(4,"a",56),e.\u0275\u0275element(5,"scrm-image",57),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"ul",58),e.\u0275\u0275template(7,XO,4,2,"ng-container",7)(8,wI,4,2,"ng-container",7),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(9,"div",59)(10,"ul",55)(11,"li",26)(12,"a",60),e.\u0275\u0275element(13,"scrm-image",61),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(14,"div",62),e.\u0275\u0275element(15,"scrm-recently-viewed",63),e.\u0275\u0275pipe(16,"async"),e.\u0275\u0275pipe(17,"slice"),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(18,"div",64)(19,"a",65),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.openSearchBox())}),e.\u0275\u0275element(20,"scrm-image",66),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(21,"div",67)(22,"scrm-search-bar",68,2),e.\u0275\u0275listener("isSearchVisible",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.closeSearchBox(o))})("searchExpression",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.search(o))}),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275template(24,SR,10,3,"div",69),e.\u0275\u0275elementEnd()}if(2&r){let t,n;const o=e.\u0275\u0275nextContext().ngIf,f=e.\u0275\u0275nextContext();e.\u0275\u0275advance(6),e.\u0275\u0275classProp("dropdown-menu-right",!f.mobileNavbar)("dropdown-menu-right-center",f.mobileNavbar),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null!==(t=null==f.navbar||null==f.navbar.current?null:f.navbar.current.module)&&void 0!==t?t:"")&&f.currentQuickActions.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",(null!==(n=null==f||null==f.navigation?null:f.navigation.quickActions)&&void 0!==n?n:e.\u0275\u0275pureFunction0(23,$O)).length),e.\u0275\u0275advance(6),e.\u0275\u0275classProp("dropdown-menu-right",!f.mobileNavbar),e.\u0275\u0275advance(),e.\u0275\u0275property("menuItems",e.\u0275\u0275pipeBind3(17,19,e.\u0275\u0275pipeBind1(16,17,f.recentlyViewed$),0,f.recentlyViewedCount)),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngClass",f.isSearchBoxVisible()?"d-none":"d-block"),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngClass",f.isSearchBoxVisible()?"d-block":"d-none")("@mobileSearchBarAnm",void 0),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey","LBL_SEARCH")("klass","search-bar-global")("searchTrigger","enter")("isMobile",f.isSmallScreen()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",f.notificationsEnabled()&&f.checkAppStrings(o.appStrings)&&f.arePreferencesInitialized(o.userPreferences))}}function JO(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",5),e.\u0275\u0275template(1,WO,5,0,"ng-template",6)(2,wR,4,3,"ng-container",7)(3,ER,25,24,"ng-template",null,0,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loaded),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loaded)}}let rc=(()=>{class r{static#e=this.instances=[];constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr,to){this.navigationStore=t,this.languageStore=n,this.userPreferenceStore=o,this.systemConfigStore=f,this.appState=D,this.authService=j,this.moduleNavigation=fe,this.screenSize=Ne,this.asyncActionService=vt,this.notificationStore=ln,this.globalRecentlyViewedStore=Hn,this.globalSearch=Oi,this.breakpointObserver=Lr,this.router=to,this.loaded=!0,this.mainNavCollapse=!0,this.subNavCollapse=!0,this.mobileSubNav=!1,this.backLink=!1,this.mainNavLink=!0,this.submenu=[],this.moduleNameMapper=new Ac(this.systemConfigStore),this.actionNameMapper=new Up(this.systemConfigStore),this.routeConverter=new Xs(this.moduleNameMapper,this.actionNameMapper,this.systemConfigStore),this.maxTabs=8,this.screen=$d.Medium,this.notificationsEnabled=(0,e.signal)(!1),this.subs=[],this.mobileNavbar=!1,this.isSmallScreen=(0,e.signal)(!1),this.isTabletScreen=(0,e.signal)(!1),this.recentlyViewedCount=10,this.isSearchBoxVisible=(0,e.signal)(!1),this.languages$=this.languageStore.vm$,this.userPreferences$=this.userPreferenceStore.userPreferences$,this.currentUser$=this.authService.currentUser$,this.appState$=this.appState.vm$,this.navigation$=this.navigationStore.vm$,this.recentlyViewed$=this.globalRecentlyViewedStore.globalRecentlyViewed$,this.vm$=this.navigation$.pipe((0,i.combineLatestWith)(this.userPreferences$,this.currentUser$,this.appState$,this.screenSize.screenSize$,this.languages$),(0,M.map)(([Mr,ss,Rs,Us,wu,Tf])=>(wu&&(this.screen=wu,this.onResize()),Mr&&Mr.modules&&(this.navigation=Mr),this.calculateMaxTabs(Mr),this.getModuleQuickActions(Us.module),this.navbar.resetMenu(),uy([Tf.appStrings,Tf.modStrings,Tf.appListStrings,ss,Rs])&&this.navbar.build(Mr,Rs,this.maxTabs),{navigation:Mr,userPreferences:ss,appState:Us,appStrings:Tf.appStrings||{},appListStrings:Tf.appListStrings||{}})))}onResize(){const t=window.innerWidth;this.mobileNavbar=t<=768,this.isSmallScreen.set(t<600),this.isTabletScreen.set(t<=992),this.isSearchBoxVisible.set(t>=600)}ngOnInit(){const t=new gl(this.routeConverter,this.moduleNavigation,this.userPreferenceStore,this.languageStore,this.appState,this.moduleNameMapper);this.setNavbar(t),this.authService.isUserLoggedIn.subscribe(n=>{this.isUserLoggedIn=n}),window.dispatchEvent(new Event("resize")),this.notificationCount$=this.notificationStore.notificationsUnreadTotal$,this.recentlyViewedCount=this.systemConfigStore.getUi("global_recently_viewed"),this.subs.push(this.notificationStore.notificationsEnabled$.subscribe(n=>{this.notificationsEnabled.set(n)})),this.subs.push(this.breakpointObserver.observe(["(max-width: 599.98px)"]).subscribe(n=>{let o;o=!!this.searchTermRef?.searchForm.get("searchTerm").value,n.matches&&!o&&this.isSearchBoxVisible.set(!1)}))}ngOnDestroy(){this.authService.isUserLoggedIn.unsubscribe(),this.subs.forEach(t=>t.unsubscribe())}checkAppStrings(t){return t&&Object.keys(t).length>0}arePreferencesInitialized(t){return t&&Object.keys(t).length}markAsRead(){this.notificationStore.markNotificationsAsRead()}ngAfterViewInit(){this.mobileGlobalLinkTitle?.nativeElement?.offsetWidth&&(this.dropdownLength=this.mobileGlobalLinkTitle.nativeElement.offsetWidth)}changeSubNav(t,n){this.mobileSubNav=!this.mobileSubNav,this.backLink=!this.backLink,this.mainNavLink=!this.mainNavLink,this.submenu=n}navBackLink(){this.mobileSubNav=!this.mobileSubNav,this.backLink=!this.backLink,this.mainNavLink=!this.mainNavLink}getHomePage(){return this.systemConfigStore.getHomePage()}setNavbar(t){this.navbar=t,this.loaded=!0}isLoaded(){return this.loaded}calculateMaxTabs(t){const n=this.systemConfigStore.getConfigValue("navigation_tab_limits");if(this.screen&&n){let o=n[this.screen];(!o||t.maxTabs&&t.maxTabs<o)&&(o=t.maxTabs),this.maxTabs=o}}getModuleQuickActions(t){const n=this?.navigation?.modules[t]??null,o=n?.menu??[];(null===n||!o.length)&&(this.currentQuickActions=[]);const f=[];o.forEach(D=>{if(!D.url||!D.quickAction)return;const j=D?.url??"";f.push({...D,url:j.replace("/#/","/")})}),this.currentQuickActions=f}handleProcess(t){if(!t.process)return;const n=t.process;this.asyncActionService.run(n,{action:n,module:t.module}).pipe((0,M.take)(1)).subscribe()}openSearchBox(){this.isSmallScreen()&&this.isSearchBoxVisible.set(!0)}closeSearchBox(t){this.isSearchBoxVisible.set(t)}search(t){const n=this.systemConfigStore.getConfigValue("search")?.controller??"";this.globalSearch.navigateToSearch(t,n).finally()}toggleSidebar(){this.appState.toggleSidebar()}closeNotificationMenu(){this.subs.push(this.router.events.pipe((0,M.filter)(t=>t instanceof Wo.NavigationEnd),(0,M.take)(1)).subscribe(()=>{this.alertDropdown.close()}))}static#t=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(pr),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(Tl),e.\u0275\u0275directiveInject(hs),e.\u0275\u0275directiveInject(br),e.\u0275\u0275directiveInject(il),e.\u0275\u0275directiveInject(le),e.\u0275\u0275directiveInject(Wo.Router))};static#n=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-navbar"]],viewQuery:function(n,o){if(1&n&&(e.\u0275\u0275viewQuery(UO,5),e.\u0275\u0275viewQuery(mR,5),e.\u0275\u0275viewQuery(bI,5)),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.mobileGlobalLinkTitle=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.searchTermRef=f.first),e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.alertDropdown=f.first)}},hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("resize",function(D){return o.onResize(D)},!1,e.\u0275\u0275resolveWindow)},decls:2,vars:3,consts:[["actionIcons",""],["mobileGlobalLinkTitle",""],["searchTerm",""],["alertDropdown","ngbDropdown"],["class","top-panel fixed-top",4,"ngIf"],[1,"top-panel","fixed-top"],[3,"ngIf"],[4,"ngIf"],[1,"navbar","navbar-expand-lg"],[1,"navbar-collapse","collapse","order-4","order-md-0","collapsenav"],[1,"navbar-nav"],[1,"top-nav","nav-item"],[1,"navbar","ml-0","pl-0"],[1,"navbar-collapse"],[1,"pl-0"],[1,"navbar","mobile-nav-block","mobilenavbar"],[1,"d-flex"],["type","button",1,"navbar-toggler",3,"click"],["image","hamburger",1,"responsive-menu-toggler"],[1,"navbar-expand",3,"ngClass"],[1,"navbar-nav","h-100"],["class","top-nav nav-item dropdown mobile-navbar-active-module h-100 non-grouped",4,"ngIf"],["class","top-nav nav-item dropdown mobile-navbar-active-module main-grouped",4,"ngIf"],[1,"d-flex","align-items-center"],[4,"ngTemplateOutlet"],["ngbDropdown","",1,"global-links","action-dropdown"],[1,"global-link-item"],["ngbDropdownToggle","",1,"nav-link","primary-global-link","dropdown-toggle"],["image","user",1,"global-action-icon","sicon-2x"],["aria-labelledby","navbarDropdownMenuLink","ngbDropdownMenu","",1,"dropdown-menu","global-links-dropdown","border","shadow-sm-2"],[1,"global-user-name"],[1,"top-nav","nav-item","dropdown","mobile-navbar-active-module","h-100","non-grouped"],[3,"item"],[1,"top-nav","nav-item","dropdown","mobile-navbar-active-module","main-grouped"],[3,"item","subNavCollapse"],[4,"ngFor","ngForOf"],["ngbDropdownItem","",1,"dropdown-item","global-links-sublink",3,"href","target"],[1,"navbar","navbar-expand-md","navbar-1"],[1,"navbar-collapse","collapse","collapsenav",3,"ngbCollapse"],[3,"active","route"],["ngbDropdownToggle","",1,"nav-link","primary-global-link"],["aria-labelledby","navbarDropdownMenuLink","ngbDropdownMenu","",1,"dropdown-menu","global-links-dropdown","border","shadow-sm-2","dropdown-menu-right"],[1,"navbar-nav","grouped"],["class","top-nav nav-item dropdown non-grouped active",4,"ngIf"],["class","top-nav nav-item dropdown main-grouped",4,"ngFor","ngForOf"],["labelKey","LBL_TABGROUP_ALL",3,"items","index"],[1,"top-nav","nav-item","dropdown","main-grouped"],[3,"item","subNavCollapse","index"],[1,"top-nav","nav-item","dropdown","non-grouped","active"],[3,"item","index"],["class","top-nav nav-item dropdown non-grouped",4,"ngFor","ngForOf"],["labelKey","LBL_MORE",3,"items","index"],[1,"top-nav","nav-item","dropdown","non-grouped"],[1,"action-group","navbar-action-group"],["ngbDropdown","",1,"action-new","action-dropdown"],[1,"navbar-nav","border-0"],["type","button","aria-label","Quick Create","ngbDropdownToggle","",1,"action-link","primary-global-link"],["image","plus",1,"action-btn-icon"],["ngbDropdownMenu","",1,"dropdown-menu","dropdown-menu-left","border","shadow-sm-2"],["ngbDropdown","",1,"action-history","action-dropdown"],["type","button","aria-label","Recently Viewed","ngbDropdownToggle","",1,"action-link","primary-global-link"],["image","recently_viewed",1,"action-btn-icon"],["ngbDropdownMenu","",1,"dropdown-menu","border","shadow-sm-2","dropdown-menu-right","scrollbar-thick","recently-viewed-nav-header"],["ngbDropdownItem","",1,"recently-viewed",3,"menuItems"],[1,"d-flex","align-items-center","px-1","action-search"],["type","button","aria-label","Search",1,"search-mobile-view","action-link","primary-global-link",3,"click","ngClass"],["image","search",1,"action-btn-icon"],[3,"ngClass"],[3,"isSearchVisible","searchExpression","labelKey","klass","searchTrigger","isMobile"],["class","action-alert action-dropdown","ngbDropdown","",4,"ngIf"],[1,"new-list-item-header","font-weight-bold"],["labelKey","LBL_MODULE_NAME",3,"module"],["class","new-list-item","ngbDropdownItem","",4,"ngFor","ngForOf"],["ngbDropdownItem","",1,"new-list-item"],[1,"d-flex","align-items-center",3,"routerLink","queryParams"],[1,"new-list-item-label",3,"labelKey","module"],[1,"d-flex","align-items-center",3,"click"],["labelKey","LBL_QUICK_ACTIONS"],["ngbDropdown","",1,"action-alert","action-dropdown"],["type","button","ngbDropdownToggle","",1,"action-link","primary-global-link",3,"mouseenter"],["image","alert",1,"action-btn-icon"],["aria-labelledby","navbarDropdownMenuLink","ngbDropdownMenu","",1,"dropdown-menu","border","shadow-sm-2","dropdown-menu-right",3,"click"],["class","badge badge-position rounded-pill bg-danger text-white",4,"ngIf"],[1,"badge","badge-position","rounded-pill","bg-danger","text-white"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,JO,5,2,"div",4),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,ve.NgTemplateOutlet,bp,KC,ct.NgbCollapse,ct.NgbDropdown,ct.NgbDropdownToggle,ct.NgbDropdownMenu,ct.NgbDropdownItem,Wo.RouterLink,Bl,Pa,P_,Yb,cI,KA,qA,kO,QA,ve.AsyncPipe,ve.SlicePipe],encapsulation:2,data:{animation:[(0,sr.trigger)("mobileSearchBarAnm",[(0,sr.transition)(":enter",(0,sr.useAnimation)(Bv.backInDown,{params:{timing:.5,delay:0}}))])]}})}return r})(),UT=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",rc)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),eF=(()=>{class r{constructor(t){this.registry=t}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(UT))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-navbar-ui"]],decls:1,vars:1,consts:[[3,"ndcDynamicComponent"]],template:function(n,o){1&n&&e.\u0275\u0275element(0,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ndcDynamicComponent",o.getType)},dependencies:[Ht],encapsulation:2})}return r})();function r2(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",4),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.onClick&&o.onClick())}),e.\u0275\u0275elementStart(1,"a",5),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",n.buildRoute(t)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.attributes.item_summary," ")}}function xI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,r2,3,2,"div",3),e.\u0275\u0275pipe(2,"slice"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind3(2,1,t.records,0,t.maxDisplayed))}}function o2(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"h4",1),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleCollapse())}),e.\u0275\u0275element(2,"scrm-label",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,xI,3,5,"ng-container",0),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",!t.collapsed)}}let iE=(()=>{class r{constructor(t,n,o,f){this.navigation=t,this.nameMapper=n,this.configs=o,this.metadata=f,this.collapsible=!1,this.maxDisplayed=5,this.collapsed=!1,this.subs=[]}ngOnInit(){const t=this.configs.getConfigValue("ui")??{};this.maxDisplayed=parseInt(t.navigation_max_module_recently_viewed)??5,this.initMetadata$(),this.collapsed=!!this.collapsible}ngOnDestroy(){this.clear()}ngOnChanges(t){null!==(t?.module??null)&&(t?.module?.previousValue??"")!==(t?.module?.currentValue??"")&&(this.clear(),this.initMetadata$())}buildRoute(t){const o=this.nameMapper.toFrontend(t.attributes.module_name??"")??"";return this.navigation.getRecordRouterLink(o,t.attributes.item_id??"")}toggleCollapse(){this.collapsible&&(this.collapsed=!this.collapsed)}initMetadata$(){const t=this.metadata.allModuleMetadata$.pipe((0,M.map)(n=>n[this.module]??null));this.subs.push(t.subscribe(n=>{this.records=n?.recentlyViewed??null}))}clear(){this.records=null,this.subs.forEach(t=>t.unsubscribe())}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Fs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-menu-recently-viewed"]],inputs:{module:"module",onClick:"onClick",collapsible:"collapsible"},features:[e.\u0275\u0275NgOnChangesFeature],decls:1,vars:1,consts:[[4,"ngIf"],[1,"recently-viewed-header","mt-0","pb-1","pl-2","pr-2",3,"click"],["labelKey","LBL_LAST_VIEWED"],["class","nav-item",3,"click",4,"ngFor","ngForOf"],[1,"nav-item",3,"click"],[1,"nav-link","action-link","pb-2","pt-2",3,"routerLink"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,o2,4,1,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.records&&o.records.length)},dependencies:[ve.NgForOf,ve.NgIf,Wo.RouterLink,Pa,ve.SlicePipe],encapsulation:2})}return r})(),s2=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",iE)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const $T=(r,v,t)=>({module:r,onClick:v,collapsible:t});function WT(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction3(2,$T,t.module,t.onClick,t.collapsible))}}let TR=(()=>{class r{constructor(t){this.registry=t,this.collapsible=!1}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(s2))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-menu-recently-viewed"]],inputs:{module:"module",onClick:"onClick",collapsible:"collapsible"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,WT,1,6,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();function SI(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",4),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.onClick&&o.onClick())}),e.\u0275\u0275elementStart(1,"a",5),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("routerLink",n.buildRoute(t)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.attributes.parent_name," ")}}function EI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,SI,3,2,"div",3),e.\u0275\u0275pipe(2,"slice"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind3(2,1,t.records(),0,t.maxDisplayed))}}function MR(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"h4",1),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleCollapse())}),e.\u0275\u0275element(2,"scrm-label",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,EI,3,5,"ng-container",0),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",!t.collapsed)}}let HT=(()=>{class r extends qC{constructor(t,n,o,f){super(t,n,o,f),this.navigation=t,this.nameMapper=n,this.configs=o,this.metadata=f,this.collapsible=!1,this.collapsed=!1}ngOnInit(){super.ngOnInit(),this.collapsed=!!this.collapsible}toggleCollapse(){this.collapsible&&(this.collapsed=!this.collapsed)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Fs))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-base-menu-favorites"]],inputs:{onClick:"onClick",collapsible:"collapsible"},features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[4,"ngIf"],[1,"favorite-header","mt-0","pb-1","pl-2","pr-2",3,"click"],["labelKey","LBL_FAVORITES"],["class","nav-item",3,"click",4,"ngFor","ngForOf"],[1,"nav-item",3,"click"],[1,"nav-link","action-link","pb-2","pt-2",3,"routerLink"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,MR,4,1,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.records()&&o.records().length)},dependencies:[ve.NgForOf,ve.NgIf,Wo.RouterLink,Pa,ve.SlicePipe],encapsulation:2})}return r})(),zT=(()=>{class r extends jd{constructor(){super()}initDefault(){this.register("default","default",HT)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const IR=(r,v,t)=>({module:r,onClick:v,collapsible:t});function rE(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.getType)("ndcDynamicInputs",e.\u0275\u0275pureFunction3(2,IR,t.module,t.onClick,t.collapsible))}}let TI=(()=>{class r{constructor(t){this.registry=t,this.collapsible=!1}get getType(){return this.registry.get("default","default")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(zT))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-menu-favorites"]],inputs:{module:"module",onClick:"onClick",collapsible:"collapsible"},decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,rE,1,6,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.getType)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})();function AR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",4),e.\u0275\u0275element(1,"scrm-action-group-menu",5),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("buttonClass",t.config.buttonClass)("config",t.config.actions)}}function MI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div")(1,"scrm-field-grid",2),e.\u0275\u0275template(2,AR,2,2,"span",3),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMapInterpolate1("record-grid ",t.config&&t.config.klass||"",""),e.\u0275\u0275advance(),e.\u0275\u0275property("actions",!!t.config.actions)("appendActions",t.config&&t.config.appendActions||!1)("colClass",t.config&&t.config.colClass)("fieldMode",t.mode)("fields",t.fields)("record",t.record)("inputClass",t.config&&t.config.inputClass)("labelClass",t.config&&t.config.labelClass)("labelDisplay",t.config&&t.config.labelDisplay||"top")("maxColumns",t.maxColumns)("record",t.record)("rowClass",t.config&&t.config.rowClass)("sizeMap",t.sizeMap)("colAlignItems",t.config.colAlignItems),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config.actions)}}function II(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,MI,3,18,"div",1),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,1,t.vm$))}}let a2=(()=>{class r{constructor(){this.mode="detail",this.maxColumns=4,this.sizeMap={handset:1,tablet:2,web:3,wide:4},this.fields=[],this.special=[]}ngOnInit(){if(!this.config)return;const t=this.config;this.vm$=t.record$.pipe((0,i.combineLatestWith)(t.mode$,t.fields$,t.maxColumns$,t.sizeMap$),(0,M.map)(([n,o,f,D,j])=>(this.mode=o,this.maxColumns=D,this.sizeMap=j,this.fields=this.getFields(n,f),this.record=n,{record:n,mode:o,fields:f,maxColumns:D})))}getFields(t,n){if(!t||!n||!t.fields)return[];const o=[];return n.forEach(f=>{t.fields[f]&&o.push(t.fields[f])}),o}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-grid"]],inputs:{config:"config"},decls:1,vars:1,consts:[[4,"ngIf"],[3,"class",4,"ngIf"],[3,"actions","appendActions","colClass","fieldMode","fields","record","inputClass","labelClass","labelDisplay","maxColumns","rowClass","sizeMap","colAlignItems"],["class","float-right","field-grid-actions","",4,"ngIf"],["field-grid-actions","",1,"float-right"],[3,"buttonClass","config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,II,3,3,"ng-container",0),2&n&&e.\u0275\u0275property("ngIf",o.config)},dependencies:[ve.NgIf,I_,Ph,ve.AsyncPipe],encapsulation:2})}return r})(),QC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,gv,hm]})}return r})(),GT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,pa,Ea,hm,dh]})}return r})(),AI=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,xm,gv,Bh,Ea,QC,g,GT]})}return r})(),qw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,xm,gv,Bh,Ea,QC,Oa,AI,jf,hm]})}return r})(),KT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,Gp,Ea,qw,AI]})}return r})(),qT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ji.FormsModule,Vl,Ea,Ji.ReactiveFormsModule]})}return r})(),QT=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qb,k_,ct.NgbModule,Wo.RouterModule,Vl,on,Ea,Ji.FormsModule,KT,qT,cI,Bh]})}return r})();const tF=(r,v)=>({"hide-pagination-count":r,"centre-pagination":v});function nF(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",7),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.first())}),e.\u0275\u0275element(1,"scrm-image",8),e.\u0275\u0275elementEnd()}}function YT(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",9),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.previous())}),e.\u0275\u0275element(1,"scrm-image",10),e.\u0275\u0275elementEnd()}}function iF(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",11),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.next())}),e.\u0275\u0275element(1,"scrm-image",12),e.\u0275\u0275elementEnd()}}function rF(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"button",13),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.last())}),e.\u0275\u0275element(1,"scrm-image",14),e.\u0275\u0275elementEnd()}}function XT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,nF,2,0,"button",2)(2,YT,2,0,"button",3),e.\u0275\u0275elementStart(3,"span",4),e.\u0275\u0275text(4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,iF,2,0,"button",5)(6,rF,2,0,"button",6),e.\u0275\u0275elementEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.allowPagination),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.allowPagination),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction2(9,tF,n.displayResponsiveTable,!n.allowPagination)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate4(" (",t.pageCount.pageFirst," - ",t.pageCount.pageLast," ",t.appStrings.LBL_LIST_OF||""," ",t.pageCount.total,") "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.allowPagination),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.allowPagination)}}let Qw=(()=>{class r{constructor(t){this.languageStore=t,this.allowPagination=!0,this.appStrings$=this.languageStore.appStrings$,this.vm$=null}ngOnInit(){const t=this.state.getPaginationCount();this.vm$=this.appStrings$.pipe((0,i.combineLatestWith)(t),(0,M.map)(([n,o])=>({appStrings:n,pageCount:o})))}first(){this.state.changePage(eu.FIRST)}previous(){this.state.changePage(eu.PREVIOUS)}next(){this.state.changePage(eu.NEXT)}last(){this.state.changePage(eu.LAST)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-pagination"]],inputs:{allowPagination:"allowPagination",state:"state"},decls:2,vars:3,consts:[["class","bulk-action float-right",4,"ngIf"],[1,"bulk-action","float-right"],["class","pagination-button pagination-first","aria-label","Navigate to first page",3,"click",4,"ngIf"],["class","pagination-button pagination-previous","aria-label","Previous page",3,"click",4,"ngIf"],[1,"pagination-count",3,"ngClass"],["class","pagination-button pagination-next","aria-label","Next page",3,"click",4,"ngIf"],["class","pagination-button pagination-last","aria-label","Navigate to last page",3,"click",4,"ngIf"],["aria-label","Navigate to first page",1,"pagination-button","pagination-first",3,"click"],["image","paginate_first",1,"sicon-2x","pagination-icons"],["aria-label","Previous page",1,"pagination-button","pagination-previous",3,"click"],["image","paginate_previous",1,"sicon-2x","pagination-icons"],["aria-label","Next page",1,"pagination-button","pagination-next",3,"click"],["image","paginate_next",1,"sicon-2x","pagination-icons"],["aria-label","Navigate to last page",1,"pagination-button","pagination-last",3,"click"],["image","paginate_last",1,"sicon-2x","pagination-icons"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,XT,7,12,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgClass,ve.NgIf,Bl,ve.AsyncPipe],encapsulation:2})}return r})(),l2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})();const OI=[[["","popup-content",""]],[["","popup-title",""]]],OR=["[popup-content]","[popup-title]"];function Ak(r,v){1&r&&e.\u0275\u0275projection(0)}function ZT(r,v){1&r&&e.\u0275\u0275projection(0,1)}let Yw=(()=>{class r{constructor(){this.klass="line-action-item line-action float-right",this.buttonConfig=(0,e.signal)({})}ngOnInit(){this.buttonConfig.update(()=>this.getButtonConfig())}getButtonConfig(){return{icon:this.icon,klass:this.klass}}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-popup-button"]],inputs:{icon:"icon",klass:"klass"},ngContentSelectors:OR,decls:5,vars:6,consts:[["popContent",""],["popTitle",""],[3,"config","autoClose","ngbPopover","popoverTitle","popoverClass","placement"]],template:function(n,o){if(1&n&&(e.\u0275\u0275projectionDef(OI),e.\u0275\u0275template(0,Ak,1,0,"ng-template",null,0,e.\u0275\u0275templateRefExtractor)(2,ZT,1,0,"ng-template",null,1,e.\u0275\u0275templateRefExtractor),e.\u0275\u0275element(4,"scrm-button",2)),2&n){const f=e.\u0275\u0275reference(1),D=e.\u0275\u0275reference(3);e.\u0275\u0275advance(4),e.\u0275\u0275property("config",o.buttonConfig())("autoClose","outside")("ngbPopover",f)("popoverTitle",D)("popoverClass","popover-wrapper")("placement","right")}},dependencies:[xc,ct.NgbPopover],encapsulation:2})}return r})(),c2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,ct.NgbPopoverModule]})}return r})();function JT(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",4)(1,"div",5),e.\u0275\u0275element(2,"scrm-label",6),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",7),e.\u0275\u0275element(4,"scrm-field",8),e.\u0275\u0275elementEnd()()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.label)("module",n.record.module),e.\u0275\u0275advance(2),e.\u0275\u0275property("mode","list")("field",n.getField(t,n.record))("type",t.type)("record",n.record)}}function yh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275template(1,JT,5,6,"div",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.columns)}}let FI=(()=>{class r{constructor(t){this.fieldManager=t}getField(t,n){return t&&n?this.fieldManager.addField(n,t):null}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_p))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-details-popup-button"]],inputs:{record:"record",columns:"columns"},decls:2,vars:2,consts:[[3,"icon"],["popup-content","","class","container container-popover scrollbar-thin",4,"ngIf"],["popup-content","",1,"container","container-popover","scrollbar-thin"],["class","row py-1",4,"ngFor","ngForOf"],[1,"row","py-1"],[1,"col","font-weight-bold","text-muted"],[3,"labelKey","module"],[1,"col"],[3,"mode","field","type","record"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-popup-button",0),e.\u0275\u0275template(1,yh,2,1,"div",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("icon","dots-vertical"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.columns))},dependencies:[ve.NgForOf,ve.NgIf,Yw,Dm,Pa],encapsulation:2,changeDetection:0})}return r})(),oE=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,c2,pa,Ea]})}return r})(),u2=(()=>{class r{transform(t){return(0,i.of)(t)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"toObservable",type:r,pure:!0})}return r})();const eM=[[["","top-right-placement",""]]],oF=["[top-right-placement]"];function tM(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6)(1,"div",7)(2,"scrm-panel",8),e.\u0275\u0275pipe(3,"toObservable"),e.\u0275\u0275elementStart(4,"div",9),e.\u0275\u0275element(5,"scrm-field-layout",10),e.\u0275\u0275elementEnd()()()()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(2),e.\u0275\u0275property("title",t.label)("isCollapsed$",e.\u0275\u0275pipeBind1(3,6,t.isCollapsed)),e.\u0275\u0275advance(2),e.\u0275\u0275classMapInterpolate1("panel-",t.key,""),e.\u0275\u0275advance(),e.\u0275\u0275property("dataSource",n.getLayoutDataSource(t))}}function FR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",4),e.\u0275\u0275template(1,tM,6,8,"div",5),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.panels)}}function nM(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"scrm-field-layout",10),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275classMapInterpolate1("tab-",t.key,""),e.\u0275\u0275advance(),e.\u0275\u0275property("dataSource",n.getLayoutDataSource(t))}}function NR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"li",17)(1,"a",18),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,nM,2,4,"ng-template",19),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2),n=t.$implicit;e.\u0275\u0275property("ngbNavItem",t.index+1),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(n.label)}}function sF(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,NR,4,2,"li",16),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!!t)}}function NI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,sF,2,1,"ng-container",1),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,1,t.display$))}}function RI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",7)(1,"scrm-panel",8),e.\u0275\u0275pipe(2,"toObservable"),e.\u0275\u0275elementStart(3,"div",9),e.\u0275\u0275element(4,"scrm-field-layout",10),e.\u0275\u0275elementEnd()()()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(5);e.\u0275\u0275advance(),e.\u0275\u0275property("title",t.label)("isCollapsed$",e.\u0275\u0275pipeBind1(2,6,t.isCollapsed)),e.\u0275\u0275advance(2),e.\u0275\u0275classMapInterpolate1("panel-",t.key,""),e.\u0275\u0275advance(),e.\u0275\u0275property("dataSource",n.getLayoutDataSource(t))}}function Ok(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",21),e.\u0275\u0275template(1,RI,5,8,"div",22),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3).index,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t==n.active-1)}}function iM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Ok,2,1,"div",20),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!!t)}}function d2(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,iM,2,1,"ng-container",1),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,1,t.display$))}}function RR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,d2,3,3,"div",14),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.subPanels)}}function rM(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,RR,2,1,"ng-container",14),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.panels)}}function Fk(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",11)(1,"div",12)(2,"ul",13,0),e.\u0275\u0275twoWayListener("activeIdChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.active,o)||(f.active=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275template(4,NI,3,3,"ng-container",14),e.\u0275\u0275elementEnd(),e.\u0275\u0275projection(5),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(6,"div",15),e.\u0275\u0275template(7,rM,2,1,"ng-container",1),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275reference(3),n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275twoWayProperty("activeId",n.active),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",n.panels),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngbNavOutlet",t),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.panelsInPrevTab&&n.panelsInPrevTab.length)}}function Nk(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,FR,2,1,"div",2)(2,Fk,8,4,"div",3),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config&&"panels"===t.config.layout),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config&&"tabs"===t.config.layout)}}let Xw=(()=>{class r{constructor(t){this.language=t,this.config={},this.panelsInPrevTab=[],this.active=1,this.subs=[]}ngOnInit(){this.subs.push(this.dataSource.getDisplayConfig().subscribe(t=>{this.config={...t}})),this.subs.push(this.dataSource.getPanels().subscribe(t=>{this.panels=[...t],"panels"===this?.config?.layout?this.updatePanelCollapseState():this.updatePanelsInTabs()})),this.subs.push(this.dataSource.getRecord().subscribe(t=>{this.record={...t},this.fields=t.fields}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}updatePanelsInTabs(){let t=[],n="";const o=this.buildPanelMap(),f=this.mapTabDefs();_a(f)||(Object.keys(f).forEach(D=>{if(cl(f[D].newTab))t=[...t,o[D]],n=D;else{const fe=f[n],Ne=o[n];this.panelsInPrevTab.includes(Ne)||this.panelsInPrevTab.push(Ne);const vt=o[D];cl(fe?.newTab)&&this.panelsInPrevTab.length>0&&this.addToPrevTab(vt)}}),this.panels=t)}addToPrevTab(t){const n=this.panelsInPrevTab.length-1;(this.panelsInPrevTab[n]?.subPanels??null)||(this.panelsInPrevTab[n].subPanels=[]),this.panelsInPrevTab[n].subPanels.push(t)}updatePanelCollapseState(){const t=this.buildPanelMap();this.panels.forEach(n=>{const o=n.key.toUpperCase();t[o]&&(n.isCollapsed=t[o].isCollapsed)})}buildPanelMap(){const t={};return this.panels.forEach(n=>{let o=!1;n.label=n?.label?.toUpperCase()??"";const f=n?.key?.toUpperCase()??"";"collapsed"===n.meta?.panelDefault&&(o=!0),n.isCollapsed=o,t[f]=n}),t}mapTabDefs(){const t={};return Object.keys(this?.config?.tabDefs??{}).forEach(n=>{t[n.toUpperCase()]=this?.config?.tabDefs[n]}),t}getLayoutDataSource(t){return{inlineEdit:!0,getConfig:()=>this.dataSource.getDisplayConfig().pipe((0,M.map)(n=>({mode:n.mode,maxColumns:n.maxColumns}))),getLayout:()=>(0,i.of)(t).pipe((0,M.shareReplay)(1)),getFields:()=>this.dataSource.getRecord().pipe((0,M.map)(n=>n.fields)),getRecord:()=>this.dataSource.getRecord(),getEditAction:()=>this.dataSource.getEditAction()}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-content"]],inputs:{dataSource:"dataSource"},ngContentSelectors:oF,decls:1,vars:1,consts:[["nav","ngbNav"],[4,"ngIf"],["class","record-content panel-layout container-fluid pl-0 pr-0",4,"ngIf"],["class","record-content tabs-layout container-fluid pl-0 pr-0",4,"ngIf"],[1,"record-content","panel-layout","container-fluid","pl-0","pr-0"],["class","row no-gutters mb-3",4,"ngFor","ngForOf"],[1,"row","no-gutters","mb-3"],[1,"col"],["mode","collapsible",3,"title","isCollapsed$"],["panel-body",""],[3,"dataSource"],[1,"record-content","tabs-layout","container-fluid","pl-0","pr-0"],[1,"d-flex","flex-column","flex-column-reverse","flex-sm-row","justify-content-between"],["ngbNav","",1,"nav-tabs",3,"activeIdChange","activeId"],[4,"ngFor","ngForOf"],[1,"p-2","pt-3","rounded-right","rounded-bottom",3,"ngbNavOutlet"],["class","tab",3,"ngbNavItem",4,"ngIf"],[1,"tab",3,"ngbNavItem"],["ngbNavLink","",1,"tab-link","d-flex","align-items-end"],["ngbNavContent",""],["class","row no-gutters mt-3",4,"ngIf"],[1,"row","no-gutters","mt-3"],["class","col",4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275projectionDef(eM),e.\u0275\u0275template(0,Nk,3,2,"ng-container",1)),2&n&&e.\u0275\u0275property("ngIf",o.dataSource)},dependencies:[ve.NgForOf,ve.NgIf,wl,ct.NgbNavContent,ct.NgbNav,ct.NgbNavItem,ct.NgbNavItemRole,ct.NgbNavLink,ct.NgbNavLinkBase,ct.NgbNavOutlet,c,ve.AsyncPipe,u2],encapsulation:2})}return r})(),aF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),oM=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,xm,ct.NgbModule,g,aF]})}return r})(),LR=(()=>{class r{constructor(){}ngOnInit(){}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-content-skeleton"]],decls:173,vars:0,consts:[[1,"record-content","tabs-layout","container-fluid","pl-0","pr-0","pt-0","record-content-skeleton"],[1,"nav-tabs","nav"],[1,"tab","nav-item"],["href","",1,"tab-link","nav-link","active","pl-5","pr-5","h-100","box-loading"],["href","",1,"tab-link","nav-link","pl-5","pr-5","h-100","box-loading"],[1,"p-2","pt-3","rounded-right","rounded-bottom","tab-content"],[1,"tab-pane","fade","active","show"],[1,""],[1,"detail","field-layout"],[1,"field-layout-row","form-row","mb-1","align-items-stretch","ng-star-inserted"],[1,"field-layout-col","field-column-bordered","col","form-group","m-0","pl-3","pb-2","pr-3","d-flex","flex-column","justify-content-between","ng-star-inserted"],[1,"field-layout-field-group-wrapper","form-group","row","ng-star-inserted"],[1,"col-form-label","col-sm-3","field-layout-field-label-wrapper","label-container"],[1,"col-form-label-sm","mb-0","pb-3","pl-5","pr-5","h-100","rounded","box-loading"],[1,"col-sm-9","d-flex","flex-grow-1","field-layout-field-wrapper"],[1,"flex-grow-1","text-break","rounded","box-loading","skeleton-field-content"],["type","button",1,"record-action-button"],["image","pencil"],[1,"field-separation","mt-2","ng-star-inserted"],[1,"field-layout-col","col","form-group","m-0","pl-3","pb-2","pr-3","d-flex","flex-column","justify-content-between","ng-star-inserted"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"ul",1)(2,"li",2),e.\u0275\u0275element(3,"a",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"li",2),e.\u0275\u0275element(5,"a",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"li",2),e.\u0275\u0275element(7,"a",4),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(8,"div",5)(9,"div",6)(10,"div",7)(11,"form",8)(12,"div",9)(13,"div",10)(14,"div",11)(15,"div",12)(16,"strong"),e.\u0275\u0275element(17,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(18,"div",14),e.\u0275\u0275element(19,"div",15),e.\u0275\u0275elementStart(20,"div")(21,"button",16),e.\u0275\u0275element(22,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(23,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(24,"div",19)(25,"div",11)(26,"div",12)(27,"strong"),e.\u0275\u0275element(28,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(29,"div",14),e.\u0275\u0275element(30,"div",15),e.\u0275\u0275elementStart(31,"div")(32,"button",16),e.\u0275\u0275element(33,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(34,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(35,"div",9)(36,"div",10)(37,"div",11)(38,"div",12)(39,"strong"),e.\u0275\u0275element(40,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(41,"div",14),e.\u0275\u0275element(42,"div",15),e.\u0275\u0275elementStart(43,"div")(44,"button",16),e.\u0275\u0275element(45,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(46,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(47,"div",19)(48,"div",11)(49,"div",12)(50,"strong"),e.\u0275\u0275element(51,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(52,"div",14),e.\u0275\u0275element(53,"div",15),e.\u0275\u0275elementStart(54,"div")(55,"button",16),e.\u0275\u0275element(56,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(57,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(58,"div",9)(59,"div",10)(60,"div",11)(61,"div",12)(62,"strong"),e.\u0275\u0275element(63,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(64,"div",14),e.\u0275\u0275element(65,"div",15),e.\u0275\u0275elementStart(66,"div")(67,"button",16),e.\u0275\u0275element(68,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(69,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(70,"div",19)(71,"div",11)(72,"div",12)(73,"strong"),e.\u0275\u0275element(74,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(75,"div",14),e.\u0275\u0275element(76,"div",15),e.\u0275\u0275elementStart(77,"div")(78,"button",16),e.\u0275\u0275element(79,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(80,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(81,"div",9)(82,"div",10)(83,"div",11)(84,"div",12)(85,"strong"),e.\u0275\u0275element(86,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(87,"div",14),e.\u0275\u0275element(88,"div",15),e.\u0275\u0275elementStart(89,"div")(90,"button",16),e.\u0275\u0275element(91,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(92,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(93,"div",19)(94,"div",11)(95,"div",12)(96,"strong"),e.\u0275\u0275element(97,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(98,"div",14),e.\u0275\u0275element(99,"div",15),e.\u0275\u0275elementStart(100,"div")(101,"button",16),e.\u0275\u0275element(102,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(103,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(104,"div",9)(105,"div",10)(106,"div",11)(107,"div",12)(108,"strong"),e.\u0275\u0275element(109,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(110,"div",14),e.\u0275\u0275element(111,"div",15),e.\u0275\u0275elementStart(112,"div")(113,"button",16),e.\u0275\u0275element(114,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(115,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(116,"div",19)(117,"div",11)(118,"div",12)(119,"strong"),e.\u0275\u0275element(120,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(121,"div",14),e.\u0275\u0275element(122,"div",15),e.\u0275\u0275elementStart(123,"div")(124,"button",16),e.\u0275\u0275element(125,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(126,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(127,"div",9)(128,"div",10)(129,"div",11)(130,"div",12)(131,"strong"),e.\u0275\u0275element(132,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(133,"div",14),e.\u0275\u0275element(134,"div",15),e.\u0275\u0275elementStart(135,"div")(136,"button",16),e.\u0275\u0275element(137,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(138,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(139,"div",19)(140,"div",11)(141,"div",12)(142,"strong"),e.\u0275\u0275element(143,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(144,"div",14),e.\u0275\u0275element(145,"div",15),e.\u0275\u0275elementStart(146,"div")(147,"button",16),e.\u0275\u0275element(148,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(149,"div",18),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(150,"div",9)(151,"div",10)(152,"div",11)(153,"div",12)(154,"strong"),e.\u0275\u0275element(155,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(156,"div",14),e.\u0275\u0275element(157,"div",15),e.\u0275\u0275elementStart(158,"div")(159,"button",16),e.\u0275\u0275element(160,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(161,"div",18),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(162,"div",19)(163,"div",11)(164,"div",12)(165,"strong"),e.\u0275\u0275element(166,"label",13),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(167,"div",14),e.\u0275\u0275element(168,"div",15),e.\u0275\u0275elementStart(169,"div")(170,"button",16),e.\u0275\u0275element(171,"scrm-image",17),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275element(172,"div",18),e.\u0275\u0275elementEnd()()()()()()())},dependencies:[Bl],encapsulation:2})}return r})(),lF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})();function f2(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"li",6),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.navigateRoute(null==o||null==o.link?null:o.link.route))}),e.\u0275\u0275element(1,"scrm-image",7),e.\u0275\u0275elementStart(2,"a",8),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("image",t.icon),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t.link.label)}}function kR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",4),e.\u0275\u0275template(2,f2,4,2,"li",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.menuItems())}}function p2(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",9),e.\u0275\u0275element(1,"scrm-label",10),e.\u0275\u0275elementEnd()),2&r&&(e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey","LBL_MODULE_NOT_FOUND"))}let sM=(()=>{class r{constructor(t,n){this.router=t,this.appStateStore=n,this.menuItems=(0,e.signal)([])}ngOnInit(){}navigateRoute(t){this.router.navigate([t]).then(),this.appStateStore.toggleSidebar()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(tl))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-mobile-menu"]],inputs:{menuItems:"menuItems"},standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:4,vars:2,consts:[[1,"mobile-menu-container"],[4,"ngIf"],[1,"border-0"],["class","d-flex justify-content-center",4,"ngIf"],[1,"mobile-menu-items","scrollbar-thin"],["class","d-flex align-items-center",3,"click",4,"ngFor","ngForOf"],[1,"d-flex","align-items-center",3,"click"],[1,"sicon","mobile-nav-icon","pl-3",3,"image"],[1,"flex-grow-1","mobile-nav-link","px-3","py-2","mobile-menu-item-label"],[1,"d-flex","justify-content-center"],[3,"labelKey"]],template:function(n,o){if(1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,kR,3,1,"ng-container",1),e.\u0275\u0275elementStart(2,"li",2),e.\u0275\u0275template(3,p2,2,1,"div",3),e.\u0275\u0275elementEnd()()),2&n){let f;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.menuItems()&&o.menuItems().length),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.menuItems()||!(null!=(f=o.menuItems())&&f.length))}},dependencies:[ve.CommonModule,ve.NgForOf,ve.NgIf,Wo.RouterModule,qT,Vl,Bl,Ea,Pa],encapsulation:2})}return r})();const LI=["searchBarComponent"];function Rk(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",4)(1,"div",5)(2,"button",6),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleSidebar())}),e.\u0275\u0275element(3,"scrm-image",7),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(4,"div",8)(5,"scrm-search-bar",9,0),e.\u0275\u0275listener("searchExpression",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.search(o))}),e.\u0275\u0275elementEnd()()()}2&r&&(e.\u0275\u0275advance(5),e.\u0275\u0275property("labelKey","LBL_FILTER_MODULES")("klass","search-bar-mobile-menu")("searchTrigger","input"))}function kI(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-mobile-menu",12),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("menuItems",t.displayedItems)}}function h2(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",10),e.\u0275\u0275template(1,kI,2,1,"ng-container",11),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.displayedItems())}}let PR=(()=>{class r{constructor(t,n,o,f,D){this.appStateStore=t,this.navigationStore=n,this.moduleNameMapper=o,this.moduleNavigation=f,this.language=D,this.isSidebarVisible=!1,this.menuItems=[],this.displayedItems=(0,e.signal)([]),this.subs=[]}ngOnInit(){this.subs.push(this.navigationStore.vm$.pipe((0,i.combineLatestWith)(this.language.vm$),(0,M.map)(([t,n])=>{this.setMenuItems(t.modules,t.tabs,n.appListStrings)})).subscribe()),this.subs.push(this.appStateStore.isSidebarVisible$.subscribe(t=>{this.isSidebarVisible=t,this.isSidebarVisible||this.clearFilter()}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}setMenuItems(t,n,o){const f=[];n.forEach(D=>{const j=t[D],fe=this.moduleNavigation.getModuleRoute(j),Ne={link:{label:this.moduleNavigation.getModuleLabel(j,o),url:fe.url,route:fe.route,params:null},icon:this.moduleNameMapper.toLegacy(j?.name)??null,submenu:[],module:j?.name??null};f.push(Ne)}),this.menuItems=[...f],this.displayedItems.set([...f])}toggleSidebar(){this.appStateStore.toggleSidebar()}closeSidebar(){this.clearFilter(),this.appStateStore.closeSidebar()}search(t){this.displayedItems.set([]),t.length&&""!==t.trim()?this.displayedItems.set(this.menuItems.filter(n=>n?.link?.label.toLowerCase().includes(t.toLowerCase()))??[]):this.resetMenuItems()}resetMenuItems(){this.displayedItems.set([...this.menuItems])}clearFilter(){this.resetMenuItems(),this?.searchBarComponent?.clearSearchTerm()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(pr),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-sidebar"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(LI,5),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.searchBarComponent=f.first)}},standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:3,vars:2,consts:[["searchBarComponent",""],[3,"visibleChange","onHide","visible","showCloseIcon"],["pTemplate","header"],["pTemplate","content"],[1,"d-flex","justify-content-start"],[1,"flex-shrink-1"],["type","button",1,"navbar-toggler",3,"click"],["image","hamburger",1,"responsive-menu-toggler"],[1,"d-flex","flex-grow-1","justify-content-center"],[3,"searchExpression","labelKey","klass","searchTrigger"],[1,"sidebar-container"],[4,"ngIf"],[3,"menuItems"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"p-sidebar",1),e.\u0275\u0275twoWayListener("visibleChange",function(D){return e.\u0275\u0275twoWayBindingSet(o.isSidebarVisible,D)||(o.isSidebarVisible=D),D}),e.\u0275\u0275listener("onHide",function(){return o.closeSidebar()}),e.\u0275\u0275template(1,Rk,7,3,"ng-template",2)(2,h2,2,1,"ng-template",3),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275twoWayProperty("visible",o.isSidebarVisible),e.\u0275\u0275property("showCloseIcon",!1))},dependencies:[ve.CommonModule,ve.NgIf,wM,ty,Zc,Vl,Bl,sM,qT,Yb],encapsulation:2})}return r})();function PI(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"a",1),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).ngIf,f=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(f.changeSorting(o))}),e.\u0275\u0275element(2,"scrm-image",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("image",n.getStatusIcon(t))}}let m2=(()=>{class r{constructor(){this.statusIcons={NONE:"sort",ASC:"sort_ascend",DESC:"sort_descend"},this.nextDirection={NONE:hp.DESC,ASC:hp.NONE,DESC:hp.ASC}}ngOnInit(){this.direction$=this.state.getSortDirection()}getStatusIcon(t){return this.statusIcons[t]}changeSorting(t){this.state.changeSortDirection(this.nextDirection[t])}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-sort-button"]],inputs:{state:"state"},decls:2,vars:3,consts:[[4,"ngIf"],[1,"btn","btn-sm","p-0","sort-button",3,"click"],[1,"sort-icon","sicon",3,"image"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,PI,3,1,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.direction$))},dependencies:[ve.NgIf,Bl,ve.AsyncPipe],encapsulation:2})}return r})(),cF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Vl]})}return r})();function BI(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",3)(2,"div",4),e.\u0275\u0275element(3,"div",5),e.\u0275\u0275elementStart(4,"div",6)(5,"div",7)(6,"div"),e.\u0275\u0275text(7,"Record Status Bar Component"),e.\u0275\u0275elementEnd()()()()(),e.\u0275\u0275elementContainerEnd())}function BR(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",8)(1,"div",9)(2,"div"),e.\u0275\u0275text(3,"Record Status Bar Component"),e.\u0275\u0275elementEnd()()())}let g2=(()=>{class r{constructor(t,n){this.recordViewStore=t,this.moduleNavigation=n,this.displayResponsiveTable=!1}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(uf),e.\u0275\u0275directiveInject(Oc))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-status-bar"]],decls:4,vars:2,consts:[[1,"record-view-header"],[4,"ngIf"],[3,"ngIf"],[1,"d-flex","flex-nowrap"],[1,"row"],[1,"w-100"],[1,"col"],[1,"order-2"],[1,"row","mr-0"],[1,"col-md-4"]],template:function(n,o){1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",0),e.\u0275\u0275template(2,BI,8,0,"ng-container",1)(3,BR,4,0,"ng-template",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.displayResponsiveTable),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.displayResponsiveTable))},dependencies:[ve.NgIf],encapsulation:2})}return r})();const aM=new RegExp("^(\\d{4})-(0[1-9]|1[0-2])$"),uF=new RegExp("^(\\d{4})$");let dF=(()=>{class r{constructor(t,n,o){this.systemConfig=t,this.metadataStore=n,this.dataTypeFormatter=o,this.allowedProperties=["operator","target","values","start","end"],this.convertableProperties=["target","values","start","end"]}buildUrlQueryBasedFilter(t,n,o){const f=this.metadataStore.get().recordView.vardefs,D=Object.entries(o).reduce((fe,[Ne,vt])=>{const[ln,Hn]=this.cleanQueryParam([Ne,vt]);return fe[ln]=Hn,fe},{}),j=this.getQueryFilterCriteria(f,t,D);return(0,wt.isEmpty)(j.filters)?null:{key:"default",searchModule:t,module:"saved-search",criteria:j}}getQueryFilterCriteria(t,n,o){const f={name:"default",filters:{}},D=Object.keys(o),j=Object.values(t).filter(({name:ln})=>D.some(Hn=>Hn.includes(ln))),fe=this.systemConfig.getConfigValue("listview_url_query_filter_mapping"),Ne=Object.entries(fe);let vt;Ne.push(["",{}]),vt="basic_search"===o.searchFormTab?"basic":"advanced";for(const ln of j){const Hn=ln.name,Oi=[Hn,`${Hn}_${vt}`];for(const[Lr,to]of Ne){if(!(0,wt.isEmpty)(f.filters[Hn]))break;for(const Mr of Oi){if(!(0,wt.isEmpty)(f.filters[Hn]))break;const ss=this.buildSearchCriteriaFieldFilter(Hn,ln.type,o,Mr,Lr,to);if(!(0,wt.isEmpty)(ss)){try{this.convertableProperties.forEach(Rs=>{if(!ss[Rs])return;let Us;Us=(0,wt.isArray)(ss[Rs])?ss[Rs].map(wu=>this.toInternalFormat(ln.type,wu)):this.toInternalFormat(ln.type,ss[Rs]),ss[Rs]=Us})}catch{continue}f.filters[Hn]=ss}}}}return f}buildSearchCriteriaFieldFilter(t,n,o,f,D,j){const fe={field:t,fieldType:n,operator:"=",values:[]};if((0,wt.isEmpty)(D)||(0,wt.isEmpty)(j)){const Hn=this.getQueryParamValue(f,f,o);if((0,wt.isEmpty)(Hn)&&!Ud(Hn))return null;const Oi=(0,wt.isArray)(Hn)?Hn:[Hn];return fe.values=Oi,fe.target=Oi[0],this.checkDateSpecialsOrReturn(fe,fe.target)}const Ne=this.getQueryParamValue(D,f,o,{forceSingleString:!0}),vt=j[Ne]??Object.values(j).reduce((Hn,Oi)=>({...Hn,...Oi}),{})??{};if((0,wt.isEmpty)(vt))return null;let ln=!0;return fe.operator=Ne,Object.entries(vt).filter(([Hn,Oi])=>"string"==typeof Oi&&this.allowedProperties.includes(Oi)).forEach(([Hn,Oi])=>{const Lr=this.getQueryParamValue(Hn,f,o);if((0,wt.isEmpty)(Lr))return;ln=!1;let to=Lr;"values"===Oi?((0,wt.isArray)(to)||(to=[to]),fe.target=to[0]):"target"===Oi&&((0,wt.isArray)(to)&&(to=to[0]),fe.values=[to]),fe[Oi]=to,(0,wt.isArray)(to)||this.checkDateSpecialsOrReturn(fe,to,{operator:Ne,key:Oi})}),ln?null:this.checkForMissingOperator(fe)}getQueryParamValue(t,n,o,{forceSingleString:f=!1}={}){let j=o[t.replace("{field}",n)??""];return j?(j=(0,wt.isArray)(j)?j.map(this.transform):this.transform(j),f&&(0,wt.isArray)(j)?j[0]??"":j):null}cleanQueryParam(t){let[n,o]=t;return 0===n.split("").reverse().join("").indexOf("][")&&"string"==typeof o&&(n=n.replace("[]",""),o=o.split(",")),[n,o]}checkDateSpecialsOrReturn(t,n,{operator:o="=",key:f="target"}={}){return n.match(aM)?this.overridesSearchCriteriaFieldFilter(t,n,{type:"month",operator:o,key:f}):n.match(uF)?this.overridesSearchCriteriaFieldFilter(t,n,{type:"year",operator:o,key:f}):t}overridesSearchCriteriaFieldFilter(t,n,{type:o="",operator:f="equal",key:D="target"}){let j,fe;switch(o){case"year":j={year:1},fe="yyyy";break;case"month":j={month:1},fe="yyyy-MM";break;default:return t}const Ne=en.DateTime.fromFormat(n,fe),vt=Ne.plus(j).minus({day:1});if("target"!==D){switch(D){case"start":t.start=Ne.toFormat("yyyy-MM-dd");break;case"end":t.end=vt.toFormat("yyyy-MM-dd")}return t}switch(t.operator=f,f){case"greater_than":case"greater_than_equals":t.start=Ne.toFormat("yyyy-MM-dd"),t.target=t.start,t.values=[t.target];break;case"less_than":case"less_than_equals":t.end=vt.toFormat("yyyy-MM-dd"),t.target=t.end,t.values=[t.target];break;case"not_equal":t.start=Ne.toFormat("yyyy-MM-dd"),t.end=vt.toFormat("yyyy-MM-dd"),t.target=n,t.values=[n];break;default:t.operator="between",t.start=Ne.toFormat("yyyy-MM-dd"),t.end=vt.toFormat("yyyy-MM-dd"),t.target="",t.values=[]}return t}toInternalFormat(t,n){return n.match(uF)||n.match(aM)?n:this.dataTypeFormatter.toInternalFormat(t,n)}transform(t){return""===t?"__SuiteCRMEmptyString__":t}checkForMissingOperator(t){return!(0,wt.isEmpty)(t.start)&&!(0,wt.isEmpty)(t.end)&&(t.operator="between"),t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(_s))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Zb={key:"default",module:"saved-search",attributes:{contents:""},criteria:{name:"default",filters:{}}},v2={default:dr(Zb)},lM={module:"",widgets:!1,actionPanel:"",showSidebarWidgets:!1,recordPanelConfig:{},activeFilters:dr(v2),openFilter:dr(Zb)};let Qp=(()=>{class r extends LC{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr,to,Mr,ss){super(t,n,o,f,D),this.appStateStore=t,this.languageStore=n,this.navigationStore=o,this.moduleNavigation=f,this.metadataStore=D,this.message=j,this.listStoreFactory=fe,this.modalService=Ne,this.filterListStoreFactory=vt,this.confirmation=ln,this.preferences=Hn,this.route=Oi,this.listViewUrlQueryService=Lr,this.localStorageService=to,this.systemConfigsStore=Mr,this.userPreferences=ss,this.pageKey="listview",this.cache$=null,this.internalState=dr(lM),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subs=[],this.recordList=this.listStoreFactory.create(),this.columns$=D.listViewColumns$,this.lineActions$=D.listViewLineActions$,this.tableActions$=D.listViewTableActions$,this.records$=this.recordList.records$,this.criteria$=this.recordList.criteria$,this.context$=this.recordList.criteria$.pipe((0,M.map)(()=>this.getViewContext())),this.sort$=this.recordList.sort$,this.pagination$=this.recordList.pagination$,this.selection$=this.recordList.selection$,this.selectedCount$=this.recordList.selectedCount$,this.selectedStatus$=this.recordList.selectedStatus$,this.loading$=this.recordList.loading$,this.moduleName$=this.state$.pipe((0,M.map)(Us=>Us.module),(0,M.distinctUntilChanged)()),this.widgets$=this.state$.pipe((0,M.map)(Us=>Us.widgets),(0,M.distinctUntilChanged)()),this.showSidebarWidgets$=this.state$.pipe((0,M.map)(Us=>Us.showSidebarWidgets)),this.displayFilters$=this.state$.pipe((0,M.map)(Us=>"filters"===Us.actionPanel),(0,M.distinctUntilChanged)()),this.actionPanel$=this.state$.pipe((0,M.map)(Us=>Us.actionPanel),(0,M.distinctUntilChanged)()),this.activeFilters$=this.state$.pipe((0,M.map)(Us=>Us.activeFilters),(0,M.distinctUntilChanged)()),this.openFilter$=this.state$.pipe((0,M.map)(Us=>Us.openFilter),(0,M.distinctUntilChanged)());const Rs=this.records$.pipe((0,i.combineLatestWith)(this.criteria$,this.pagination$,this.selection$,this.loading$),(0,M.map)(([Us,wu,Tf,vM,L3])=>(this.data={records:Us,criteria:wu,pagination:Tf,selection:vM,loading:L3},this.data)));this.vm$=Rs.pipe((0,i.combineLatestWith)(this.appData$,this.metadata$),(0,M.map)(([Us,wu,Tf])=>(this.vm={data:Us,appData:wu,metadata:Tf},this.vm))),this.columns=new i.BehaviorSubject([]),this.columns$=this.columns.asObservable(),this.initDataUpdateState(),this.initDataSetUpdatedState(),this.filterList=this.filterListStoreFactory.create(),this.recordList.pageKey=this.pageKey}get actionPanel(){return this.internalState.actionPanel}get showFilters(){return"filters"===this.internalState.actionPanel}set showFilters(t){this.updateState({...this.internalState,actionPanel:t?"filters":""})}get widgets(){return this.internalState.widgets}set widgets(t){this.updateState({...this.internalState,widgets:t})}get showSidebarWidgets(){return this.internalState.showSidebarWidgets}set showSidebarWidgets(t){this.savePreference(this.getModuleName(),"show-sidebar-widgets",t),this.updateState({...this.internalState,showSidebarWidgets:t})}get recordPanelConfig(){return this.internalState.recordPanelConfig}isRecordPanelOpen(){return"recordPanel"===this.internalState.actionPanel}openRecordPanel(t){this.updateState({...this.internalState,actionPanel:"recordPanel",recordPanelConfig:t})}closeRecordPanel(){this.updateState({...this.internalState,actionPanel:"",recordPanelConfig:{}})}getModuleName(){return this.internalState.module}getViewContext(){const t={module:this.getModuleName()};return t.criteria=this.recordList.criteria,t.sort=this.recordList.sort,t}destroy(){this.clear(),this.subs.forEach(t=>t.unsubscribe())}get activeFilters(){return dr(this.internalState.activeFilters)}clear(){this.cache$=null,this.updateState(dr(lM)),this.recordList.clear()}clearAuthBased(){this.clear(),this.recordList.clearAuthBased()}init(t){this.internalState.module=t,this.recordList.init(t,!1),this.filterList.init(t),this.filterList.load(!1).pipe((0,M.take)(1)).subscribe(),this.calculateShowWidgets(),this.recordList.sort={orderBy:this?.metadata?.listView?.orderBy??"",sortOrder:this?.metadata?.listView?.sortOrder??"NONE"};const n=this.route?.snapshot?.queryParams??{};let o="";"query"===(cl(n.query)&&(o="query"),o)?this.loadQueryFilter(t,n):(this.loadCurrentFilter(t),this.loadCurrentSort(t)),this.loadCurrentDisplayedColumns();const f=this.userPreferences.getUserPreference("listview_pagination_type")??this.systemConfigsStore.getConfigValue("listview_pagination_type"),D=this.getCurrentPaginationType(t);return this.setCurrentPaginationType(t,f),n.keepPagination&&D===f&&this.loadCurrentPagination(t),this.load()}setOpenFilter(t){this.updateState({...this.internalState,openFilter:dr(t)})}toggleQuickFilter(t,n=!0){let o=this.getActiveQuickFilters();if(Object.keys(o).some(D=>D===t.key)){let{[t.key]:D,...j}=o;o=j}else o={},o[t.key]=t;_a(o)?this.resetFilters(n):1!==Object.keys(o).length?(this.updateState({...this.internalState,activeFilters:dr(o)}),this.updateSearchCriteria(n)):this.setFilters(o)}setFilters(t,n=!0,o=null){const D=t[Object.keys(t).shift()];if(this.updateState({...this.internalState,activeFilters:dr(t),openFilter:dr(D)}),D.criteria){let j=D.criteria.orderBy??"",Ne=this.recordList.mapSortOrder(D.criteria.sortOrder??"");null!==o&&(j=o.orderBy,Ne=o.sortOrder),this.recordList.updateSorting(j,Ne,!1),this.updateSortLocalStorage()}this.updateSearchCriteria(n)}addSavedFilter(t){const n={...this.internalState},o=this.activeFilters;t.key&&o[t.key]&&(o[t.key]=t,n.activeFilters=o),n.openFilter=t,this.filterList.addFilter(t),this.updateState(n)}removeSavedFilter(t){if(!t||!t.key)return;this.filterList.removeFilter(t);const n={...this.internalState};n.openFilter&&n.openFilter.key===t.key&&this.resetFilters(!0)}resetFilters(t=!0){this.updateState({...this.internalState,activeFilters:dr(v2),openFilter:dr(Zb)}),this.recordList.clearSort(),this.updateSortLocalStorage(),this.updateSearchCriteria(t)}updateSearchCriteria(t=!0){const n={...this.internalState.activeFilters};let o=this.mergeCriteria(n);this.recordList.updateSearchCriteria(o,t),this.updateFilterLocalStorage()}updateFilterLocalStorage(){this.savePreference(this.internalState.module,"current-filters",this.internalState.activeFilters)}updateSortLocalStorage(){this.savePreference(this.internalState.module,"current-sort",this.recordList.sort)}updatePaginationLocalStorage(){const n=this.internalState.module+"-"+this.getPreferenceKey("current-pagination");this.localStorageService.set(n,this.recordList.pagination)}updateDisplayedColumnsPreference(t){this.savePreference(this.internalState.module,"displayed-columns",t)}getDisplayedColumnsPreference(){const n=this.loadPreference(this.internalState.module,"displayed-columns");return(0,wt.isArray)(n)&&n&&n.length?n:null}triggerDataUpdate(){this.dataUpdateState.next(!0)}load(t=!0){const n=this.internalState.module;return this.savePreference(n,"current-filters",this.internalState.activeFilters),this.savePreference(n,"current-sort",this.recordList.sort),this.updatePaginationLocalStorage(),this.recordList.load(t)}updateState(t){this.store.next(this.internalState=t)}getActiveQuickFilters(){let{default:t,...n}=this.activeFilters,o={};return Object.keys(n).forEach(f=>{const D=n[f]??null;f&&D?.attributes?.quick_filter&&(o[f]=D)}),o}mergeCriteria(t){let n={};return(Object.keys(t??{})??[]).forEach(f=>{const j=(t[f]??null)?.criteria??null,fe=Object.keys(j?.filters??{});if(null!==j&&(!fe||fe.length)){if(_a(n))return void(n=dr(j));fe.forEach(Ne=>{const vt=j?.filters[Ne]??null,ln=n?.filters[Ne]??null;if(!vt)return;const Hn=ln?.operator??null;if(!ln||!Hn)return void(n.filters[Ne]=dr(vt));const Oi=vt?.operator??null;Oi===Hn&&"="===Oi?ln.values=(0,wt.union)(ln.values??[],vt.values??[]):delete n.filters[Ne]})}}),n}openColumnChooserDialog(){const t=this.modalService.open(oS,{ariaLabelledBy:"modal-basic-title",centered:!0,size:"lg",windowClass:"column-chooser-modal"}),n=this.columns.getValue().filter(function(f){return!f.hasOwnProperty("default")||f.hasOwnProperty("default")&&!0===f.default}),o=this.columns.getValue().filter(function(f){return f.hasOwnProperty("default")&&!1===f.default});t.componentInstance.displayed=n,t.componentInstance.hidden=o,t.result.then(f=>{if(!f.displayed||!f.hidden)return;let D=[];const j=f.displayed,fe=f.hidden;j.forEach(function(vt){vt.default=!0}),fe.forEach(function(vt){vt.default=!1}),D.push(...j,...fe),this.columns.next(D);const Ne=j.map(vt=>vt.name);this.updateDisplayedColumnsPreference(Ne)})}calculateShowWidgets(){let t=!1;const f=((this.metadataStore.get()||{}).listView||{}).sidebarWidgets||[];f&&f.length>0&&(t=!0);const D=this.loadPreference(this.getModuleName(),"show-sidebar-widgets")??null;this.showSidebarWidgets=null!==D?D:t,this.widgets=t}getPreferenceKey(t){return this.pageKey+"-"+t}savePreference(t,n,o){this.preferences.setUi(t,this.getPreferenceKey(n),o)}loadPreference(t,n){return this.preferences.getUi(t,this.getPreferenceKey(n))}loadCurrentFilter(t){const n=this.loadPreference(t,"current-filters")??{};if(!n||_a(n))return;let o=this.loadPreference(t,"current-sort");!o&&_a(o)&&(o=null),this.setFilters(n,!1,o)}loadQueryFilter(t,n){const o=n.orderBy??"",D=this.recordList.mapSortOrder(n.sortOrder??""),j=this.listViewUrlQueryService.buildUrlQueryBasedFilter(t,this.internalState.activeFilters.default,n);(0,wt.isEmpty)(j)||(this.updateState({...this.internalState,activeFilters:dr({default:j}),openFilter:dr(j)}),this.recordList.updateSorting(o,D,!1),this.recordList.updateSearchCriteria(j.criteria,!1))}loadCurrentSort(t){const n=this.loadPreference(t,"current-sort");!n||_a(n)||(this.recordList.sort=n)}loadCurrentPagination(t){const n=t+"-"+this.getPreferenceKey("current-pagination"),o=this.localStorageService.get(n);!o||_a(o)||(this.recordList.pagination=o)}getCurrentPaginationType(t){return this.loadPreference(t,"current-pagination-type")||"pagination"}setCurrentPaginationType(t,n){this.savePreference(t,"current-pagination-type",n)}loadCurrentDisplayedColumns(){this.metadataStore.listViewColumns$.pipe((0,M.take)(1)).subscribe(t=>{const n=this.getDisplayedColumnsPreference();if(!n||!t)return void this.columns.next(t);const o={};n.forEach(fe=>{o[fe]=!0});const f={},D=[];t.forEach(fe=>{fe.default=o[fe.name]??!1,fe.default?f[fe.name]=fe:D.push(fe)});const j=n.filter(fe=>!!f[fe]).map(fe=>f[fe]);this.columns.next([...j,...D])})}initDataUpdateState(){this.dataUpdateState=new i.BehaviorSubject(!0),this.dataUpdate$=this.dataUpdateState.asObservable()}initDataSetUpdatedState(){this.dataSetUpdate$=this.criteria$.pipe((0,i.combineLatestWith)(this.dataUpdate$),(0,M.map)(()=>!0))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($p),e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(Bw),e.\u0275\u0275inject($e),e.\u0275\u0275inject($a),e.\u0275\u0275inject(Wo.ActivatedRoute),e.\u0275\u0275inject(dF),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();function VR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275element(1,"scrm-button-group",2),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config$",t.config$)}}let VI=(()=>{class r{constructor(t,n,o,f,D){this.listStore=t,this.actionHandler=n,this.screenSize=o,this.systemConfigs=f,this.asyncActionService=D,this.configState=new i.BehaviorSubject({buttons:[]}),this.config$=this.configState.asObservable(),this.vm$=this.screenSize.screenSize$.pipe((0,M.map)(j=>(j&&(this.screen=j),this.configState.next(this.getButtonGroupConfig()),{screenSize:j}))),this.screen=$d.Medium,this.defaultBreakpoint=3}ngOnInit(){this.configState.next(this.getButtonGroupConfig())}getButtonGroupConfig(){const t=this.actions,n={buttonKlass:["action-button"],dropdownLabel:this.listStore.appStrings.LBL_MORE||"",buttons:[],dropdownOptions:{placement:["bottom-right"]},breakpoint:this.getBreakpoint()};return t.forEach(o=>{const f=this.getButtonConfig(o);f&&f.klass&&n.buttons.push(f)}),n}getBreakpoint(){const t=this.systemConfigs&&this.systemConfigs.getConfigValue("listview_actions_limits");return this.screen&&t&&t[this.screen]?(this.breakpoint=t[this.screen],this.breakpoint):this.breakpoint?this.breakpoint:this.defaultBreakpoint}get actions(){return this.listStore.vm.appData.module&&this.listStore.vm.appData.module.menu?this.listStore.vm.appData.module.menu.filter(t=>!("List"===t.name||"View"===t.name)):[]}getButtonConfig(t){if(!this.listStore.vm.appData.appState.module)return{};if(!this.listStore.vm.appData.language)return{};const n=this.listStore.vm.appData.appState.module;let f="";return t.actionLabelKey&&(f=t.actionLabelKey),{klass:"action-button",label:this.actionHandler.getActionLabel(n,t,this.listStore.vm.appData.language,f),onClick:()=>{t?.process?this.handleProcess(n,t?.process):this.actionHandler.navigate(t).then()}}}handleProcess(t,n){n&&this.asyncActionService.run(n,{action:n,module:t}).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Qp),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Tl))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-action-menu"]],decls:2,vars:3,consts:[["class","list-view-actions float-right",4,"ngIf"],[1,"list-view-actions","float-right"],[3,"config$"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,VR,2,1,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,nb,ve.AsyncPipe],encapsulation:2})}return r})(),jI=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qm,Oa,fn.AngularSvgIconModule,Fu]})}return r})(),UI=(()=>{class r{constructor(t,n,o){this.systemConfigStore=t,this.screenSize=n,this.store=o,this.quickFiltersConfigState=new i.BehaviorSubject({buttons:[]}),this.enabledState=new i.BehaviorSubject(!1),this.screen=$d.Medium,this.defaultBreakpoint=5,this.breakdownSizes=[],this.subs=[],this.config$=this.quickFiltersConfigState.asObservable(),this.enabled$=this.enabledState.asObservable(),this.enabled=!1,this.breakdownSizes=this.systemConfigStore.getUi("quick_filters_breakdown_screen_sizes");const f=this.systemConfigStore.getUi("displayed_quick_filters"),D=this.systemConfigStore.getUi("quick_filters_breakdown_threshold");this.breakdown$=this.screenSize.screenSize$.pipe((0,M.map)(j=>(f[j]??2)>(D[j]??2)||cl(this.breakdownSizes[j]??!1))),this.subs.push(this.screenSize.screenSize$.subscribe(j=>{j&&(this.screen=j),this.init()}))}init(){let t=this.store.filterList.getFilters()??[];if(t=t.filter(D=>D?.attributes?.quick_filter??!1),this.enabled=this.areConfigEnabled(),!t||t.length<1)return this.enabled=!1,void this.enabledState.next(!1);this.enabledState.next(this.enabled);const n={buttonKlass:["settings-button btn btn-outline-main"],dropdownLabel:this.store.appStrings.LBL_QUICK_FILTERS||"",breakpoint:this.getBreakpoint(),showAfterBreakpoint:!1,dropdownOptions:{placement:["bottom-right"],wrapperKlass:["dropdown-button-secondary","filter-action-group"]},buttons:[]},o=this.store.activeFilters;let f=!1;t.forEach(D=>{if(!D?.attributes?.quick_filter)return;const fe=Object.keys(o).some(vt=>vt===D.key);f=f||fe;const Ne={label:D.attributes.name,title:D.attributes.name,onClick:()=>{this.store.toggleQuickFilter(D)}};fe&&(Ne.klass=["active"]),n.buttons.push(Ne)}),f&&(n.dropdownOptions.klass=["active"],n.dropdownOptions.icon="filter"),this.quickFiltersConfigState.next(n)}destroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[],this.quickFiltersConfigState.unsubscribe()}getBreakpoint(){const t=this.systemConfigStore.getUi("displayed_quick_filters");return this.screen&&t&&t[this.screen]?(this.breakpoint=t[this.screen],this.breakpoint):this.breakpoint?this.breakpoint:this.defaultBreakpoint}areConfigEnabled(){const t=this.systemConfigStore.getUi("enable_quick_filters");return!(!this.screen||!t)&&cl(t[this.screen]??!1)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Wd),e.\u0275\u0275inject(Qp))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();function fF(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button-group",10),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("config$",t.quickFilters.config$)("klass","quick-filter-button")}}function Lk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",5)(1,"div",6),e.\u0275\u0275element(2,"scrm-label",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",8),e.\u0275\u0275template(4,fF,1,2,"scrm-button-group",9),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.quickFilters.config$)}}function jR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,Lk,5,1,"div",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.showQuickFilters&&t.enableQuickFilters)}}function $I(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button-group",11),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config$",t.config$)}}let _2=(()=>{class r{constructor(t,n,o,f,D){this.listStore=t,this.modalService=n,this.screenSize=o,this.systemConfigStore=f,this.quickFilters=D,this.configState=new i.BehaviorSubject({buttons:[]}),this.config$=this.configState.asObservable(),this.showQuickFilters=!0,this.enableQuickFilters=!1,this.screen=$d.Medium,this.defaultBreakpoint=5,this.subs=[]}ngOnInit(){this.configState.next(this.getButtonGroupConfig());const t=this.listStore.widgets$.pipe((0,i.combineLatestWith)(this.listStore.displayFilters$,this.listStore.criteria$,this.screenSize.screenSize$,this.listStore.showSidebarWidgets$,this.listStore.filterList.records$));this.subs.push(t.subscribe(([n,o,f,D,j,fe])=>{D&&(this.screen=D),this.configState.next(this.getButtonGroupConfig()),this.quickFilters.init()})),this.subs.push(this.quickFilters.breakdown$.subscribe(n=>{this.showQuickFilters=!cl(n)})),this.subs.push(this.quickFilters.enabled$.subscribe(n=>{this.enableQuickFilters=cl(n??!1)}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getButtonGroupConfig(){const t=[{show:()=>this.checkFiltersDisplay(),button:this.getMyFiltersButton()},{show:()=>!0,button:this.getFilterButton()},{show:()=>this.listStore.widgets,button:this.getInsightsButton()}],n={buttonKlass:["settings-button"],dropdownLabel:this.listStore.appStrings.LBL_OPTIONS||"",breakpoint:this.getBreakpoint(),dropdownOptions:{placement:["bottom-right"],wrapperKlass:["dropdown-button-secondary"]},buttons:[]};return t.forEach(o=>{o.show?o.show()&&n.buttons.push(o.button):n.buttons.push(o.button)}),n}checkFiltersDisplay(){const t=this.listStore.filterList.getFilters()??[],n=this.quickFilters.getBreakpoint(),o=t.length,f=t.filter(D=>D.attributes.quick_filter).length;return o>0&&(f>n||o-f>0)}getFilters(){return this?.listStore?.recordList?.criteria?.filters??{}}getCurrentCriteria(){return this?.listStore?.recordList?.criteria??{}}hasActiveFilter(){const t=this.listStore.activeFilters;if(!t)return!1;const n=Object.keys(t)??[];if(!n||!n.length)return!1;if(n.length>1)return!0;const o=t[n[0]];return o.key&&""!==o.key&&"default"!==o.key}areAllCurrentCriteriaFilterEmpty(){return Object.keys(this.getFilters()??{}).every(t=>""===this.getFilters()[t].operator)}isAnyFilterApplied(){return this.hasActiveFilter()||!this.areAllCurrentCriteriaFilterEmpty()}getBreakpoint(){const t=this.systemConfigStore.getConfigValue("listview_settings_limits");return this.screen&&t&&t[this.screen]?(this.breakpoint=t[this.screen],this.breakpoint):this.breakpoint?this.breakpoint:this.defaultBreakpoint}getFilterButton(){const t={type:"grouped",items:[]},n={label:this.listStore.appStrings.LBL_FILTER||"",klass:{"filter-settings-button":!0,"btn btn-sm settings-button":!0,active:this.isAnyFilterApplied()},onClick:()=>{this.listStore.showFilters=!this.listStore.showFilters}};return this.isAnyFilterApplied()&&(n.icon="filter"),t.items.push(n),this.isAnyFilterApplied()&&t.items.push(this.getClearButton()),t}getMyFiltersButton(){const t=this.listStore.filterList.getFilters(),n={label:this.listStore.appStrings.LBL_SAVED_FILTER_SHORTCUT||"",klass:["dropdown-toggle"],wrapperKlass:["filter-action-group"],items:[],sections:{"quick-filters":{labelKey:"LBL_QUICK_FILTERS"},default:{labelKey:"LBL_SAVED_FILTER_SHORTCUT"}}},o=this.listStore.activeFilters;let f=!1,D=0;const j=this.quickFilters.getBreakpoint(),fe=this.quickFilters.areConfigEnabled();return t.forEach(Ne=>{const vt=cl(Ne?.attributes?.quick_filter??!1);if(fe&&vt&&D<j)return void D++;const ln=Object.keys(o).some(Oi=>Oi===Ne.key);f=f||ln;const Hn={label:Ne.attributes.name,title:Ne.attributes.name,section:vt?"quick-filters":"default",onClick:()=>{if(this.listStore.showFilters=!1,ln)this.listStore.resetFilters();else{this.listStore.setOpenFilter(Ne);const Oi={};Oi[Ne.key]=Ne,this.listStore.setFilters(Oi)}}};ln&&(Hn.icon="filter",Hn.iconKlass="small",Hn.klass=["active"]),n.items.push(Hn)}),f&&(n.klass=["dropdown-toggle","active"]),n}getClearButton(){return{label:"x",titleKey:"LBL_CLEAR_FILTER",klass:{"btn btn-sm settings-button clear-filter-button btn-main-light":!0},onClick:()=>{this.listStore.showFilters=!1,this.listStore.resetFilters()}}}getInsightsButton(){return{label:this.listStore.appStrings.LBL_INSIGHTS||"",klass:{active:this.listStore.showSidebarWidgets},icon:"pie",onClick:()=>{this.listStore.showSidebarWidgets=!this.listStore.showSidebarWidgets}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Qp),e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Wd),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(UI))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-settings-menu"]],decls:5,vars:4,consts:[[1,"list-view-settings","w-100","d-flex","justify-content-end"],[4,"ngIf"],[1,"text-nowrap"],["klass","d-flex align-items-center",3,"config$",4,"ngIf"],["class","d-flex align-items-baseline",4,"ngIf"],[1,"d-flex","align-items-baseline"],[1,"text-nowrap","text-muted","fs-70","pl-1","mr-2"],["labelKey","LBL_QUICK_FILTERS"],[1,"quick-filter-border","pr-xxl-1","mr-xxl-1"],[3,"config$","klass",4,"ngIf"],[3,"config$","klass"],["klass","d-flex align-items-center",3,"config$"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,jR,2,1,"ng-container",1),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementStart(3,"div",2),e.\u0275\u0275template(4,$I,1,1,"scrm-button-group",3),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,2,o.quickFilters.config$)),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.config$))},dependencies:[ve.NgIf,nb,Pa,ve.AsyncPipe],encapsulation:2})}return r})(),y2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,sS,Vl,Oa,Bh,ct.NgbModule,Fu,Ea]})}return r})(),Zw=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Do,jI,y2,fn.AngularSvgIconModule]})}return r})();function cM(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-bulk-action-menu",7),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("selectionSource",t.selection)("actionSource",t.bulkActions)}}function UR(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-pagination",8),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("allowPagination",t.isPaginationEnabled())("state",t.pagination)}}let uM=(()=>{class r{isPaginationEnabled(){return"pagination"===this.paginationType}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-table-header"]],inputs:{selection:"selection",bulkActions:"bulkActions",pagination:"pagination",tableActions:"tableActions",paginationType:"paginationType"},decls:7,vars:3,consts:[[1,"list-view-tableactions","table-header"],[1,"d-flex","justify-content-between","align-items-center"],[1,"d-flex"],[3,"selectionSource","actionSource",4,"ngIf"],["buttonClass","btn table-action-button",3,"config"],[1,"mx-0","pl-0","table-pagination-wrapper"],[3,"allowPagination","state",4,"ngIf"],[3,"selectionSource","actionSource"],[3,"allowPagination","state"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"div",2),e.\u0275\u0275template(3,cM,1,2,"scrm-bulk-action-menu",3),e.\u0275\u0275element(4,"scrm-action-group-menu",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"div",5),e.\u0275\u0275template(6,UR,1,2,"scrm-pagination",6),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.selection&&o.bulkActions),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.tableActions),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.pagination))},dependencies:[ve.NgIf,Qw,PM,Ph],encapsulation:2})}return r})();function pF(r,v){1&r&&e.\u0275\u0275element(0,"th",13)}function Mm(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"td",14)(1,"label",15)(2,"input",16),e.\u0275\u0275listener("change",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.toggleSelection(o.id))}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"span",17),e.\u0275\u0275elementEnd()()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("checked",t.id&&n.selected[t.id]||o.allSelected(n.selectionStatus))("disabled",o.allSelected(n.selectionStatus))}}function YC(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0,12),e.\u0275\u0275template(1,pF,1,0,"th",7)(2,Mm,4,2,"td",8),e.\u0275\u0275elementContainerEnd())}function $R(r,v){1&r&&e.\u0275\u0275element(0,"th",21)}function kk(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-record-details-popup-button",24),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("record",t)("columns",n.popoverColumns)}}function Pk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"td",22),e.\u0275\u0275template(1,kk,1,2,"scrm-record-details-popup-button",23),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.popoverColumns.length)}}function r3(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0,18),e.\u0275\u0275template(1,$R,1,0,"th",19)(2,Pk,2,1,"td",20),e.\u0275\u0275elementContainerEnd())}function WI(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-sort-button",31),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("state",n.getFieldSort(t))}}function Bk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"th",28),e.\u0275\u0275element(1,"scrm-label",29),e.\u0275\u0275template(2,WI,1,1,"scrm-sort-button",30),e.\u0275\u0275elementEnd()),2&r){let t;const n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap((null!==(t="primary-table-header column-"+(null==n?null:n.name))&&void 0!==t?t:"")+" "+(null!==(t="column-type-"+(null==n?null:n.type))&&void 0!==t?t:"")),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",n.label)("module",o.config.module||""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.config.sort$&&n.sortable)}}function hF(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"td",14),e.\u0275\u0275element(1,"scrm-field",32),e.\u0275\u0275elementEnd()),2&r){let t;const n=v.$implicit,o=e.\u0275\u0275nextContext().$implicit,f=e.\u0275\u0275nextContext(2);e.\u0275\u0275classMap((null!==(t="column-"+(null==o?null:o.name))&&void 0!==t?t:"")+" "+(null!==(t="column-type-"+(null==o?null:o.type))&&void 0!==t?t:"")),e.\u0275\u0275advance(),e.\u0275\u0275property("mode","list")("type",o.type)("field",f.getField(o,n))("record",n)}}function WR(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0,25),e.\u0275\u0275template(1,Bk,3,5,"th",26)(2,hF,2,6,"td",27),e.\u0275\u0275elementContainerEnd()),2&r&&e.\u0275\u0275property("cdkColumnDef",v.$implicit.name)}function HR(r,v){1&r&&e.\u0275\u0275element(0,"th",13)}function zR(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-line-action-menu",34),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",n.config.lineActions)("activeLineAction",n.activeLineAction)("record",t)("wrapperClass","listview-actions")("klass","icon-bar")}}function GR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"td",14),e.\u0275\u0275template(1,zR,1,5,"scrm-line-action-menu",33),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t&&n.config.lineActions)}}function mF(r,v){1&r&&e.\u0275\u0275element(0,"tr",35)}function gF(r,v){1&r&&e.\u0275\u0275element(0,"tr",36)}function KR(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div")(1,"p",37),e.\u0275\u0275element(2,"scrm-label",38),e.\u0275\u0275elementEnd()())}function Vk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275element(1,"scrm-loading-spinner",39),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf;e.\u0275\u0275classProp("m-5",!t.records||0===t.records.length),e.\u0275\u0275advance(),e.\u0275\u0275property("overlay",!0)}}function b2(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",1)(2,"table",2),e.\u0275\u0275template(3,YC,3,0,"ng-container",3)(4,r3,3,0,"ng-container",4)(5,WR,3,1,"ng-container",5),e.\u0275\u0275elementContainerStart(6,6),e.\u0275\u0275template(7,HR,1,0,"th",7)(8,GR,2,1,"td",8),e.\u0275\u0275elementContainerEnd(),e.\u0275\u0275template(9,mF,1,0,"tr",9)(10,gF,1,0,"tr",10),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(11,KR,3,0,"div",0)(12,Vk,2,3,"div",11),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("dataSource",n.config.dataSource)("trackBy",n.trackRecord),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.selection),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.popoverColumns&&n.popoverColumns.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.columns),e.\u0275\u0275advance(4),e.\u0275\u0275property("cdkHeaderRowDef",t.displayedColumns),e.\u0275\u0275advance(),e.\u0275\u0275property("cdkRowDefColumns",t.displayedColumns),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loading&&0===t.records.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading)}}let C2=(()=>{class r{constructor(t,n){this.fieldManager=t,this.loadingBufferFactory=n,this.activeAction=new i.BehaviorSubject(""),this.activeAction$=this.activeAction.asObservable(),this.maxColumns=4,this.subs=[],this.currentPage=1,this.pageSize=20,this.loadingBuffer=this.loadingBufferFactory.create("table_loading_display_delay")}ngOnInit(){const t=this.config.selection$||(0,i.of)(null).pipe((0,M.shareReplay)(1));let n=this.initLoading();this.activeLineAction={activeAction$:this.activeAction$,getActiveAction:()=>this.activeAction.getValue(),setActiveAction:o=>{this.activeAction.next(o)},resetActiveAction:()=>{this.activeAction.next("")}},this.subs.push(this.config.pagination.pagination$.subscribe(o=>{this.pageSize=o.pageSize,this.currentPage=Math.ceil(o.pageLast/o.pageSize)})),this.vm$=this.config.columns.pipe((0,i.combineLatestWith)(t,this.config.maxColumns$,this.config.dataSource.connect(null),n),(0,M.map)(([o,f,D,j,fe])=>{const Ne=[];this.maxColumns=D;const vt=this.buildDisplayColumns(o);this.popoverColumns=this.buildHiddenColumns(o,vt),f&&Ne.push("checkbox"),this.popoverColumns&&this.popoverColumns.length&&Ne.push("show-more"),Ne.push(...vt),Ne.push("line-actions");const ln=f&&f.selected||{},Hn=f&&f.status||Xu.NONE;return j.forEach((Oi,Lr)=>{Oi.metadata||(Oi.metadata={}),Oi.metadata.queryParams={offset:Lr+1+(this.currentPage-1)*this.pageSize}}),{columns:o,selection:f,selected:ln,selectionStatus:Hn,displayedColumns:Ne,records:j||[],loading:fe}}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}toggleSelection(t){this.config.toggleRecordSelection(t)}allSelected(t){return t===Xu.ALL}buildDisplayColumns(t){let n=0,o=!1;const f=[],D=t.filter(function(j){return!j.hasOwnProperty("default")||j.hasOwnProperty("default")&&!0===j.default});for(;n<this.maxColumns&&n<D.length;)f.push(D[n].name),o=o||D[n].link,n++;if(!o&&this.maxColumns<D.length)for(n=this.maxColumns;n<D.length;n++)if(D[n].link){f.splice(-1,1),f.push(D[n].name);break}return f}buildHiddenColumns(t,n){const o=t.filter(function(j){return!j.hasOwnProperty("default")||j.hasOwnProperty("default")&&!0===j.default});let f=[];for(let j=0;j<o.length;j++)-1===n.indexOf(o[j].name)&&f.push(o[j].name);return o.filter(j=>f.includes(j.name))}getFieldSort(t){return{getSortDirection:()=>this.config.sort$.pipe((0,M.map)(n=>{let o=hp.NONE;return n.orderBy===t.name&&(o=n.sortOrder),o})),changeSortDirection:n=>{this.config.updateSorting(t.name,n)}}}getField(t,n){return t&&n?this.fieldManager.addField(n,t):null}initLoading(){let t=(0,i.of)(!1).pipe((0,M.shareReplay)(1));return this.config.loading$&&(this.subs.push(this.config.loading$.subscribe(n=>{this.loadingBuffer.updateLoading(n)})),t=this.loadingBuffer.loading$),t}trackRecord(t,n){return n?.id??""}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_p),e.\u0275\u0275directiveInject(zg))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-table-body"]],inputs:{config:"config"},decls:2,vars:3,consts:[[4,"ngIf"],[1,"position-relative","d-flex","flex-column","table-body-wrapper"],["cdk-table","","aria-describedby","table-body",1,"list-view-table","striped-table","table",3,"dataSource","trackBy"],["cdkColumnDef","checkbox",4,"ngIf"],["cdkColumnDef","show-more",4,"ngIf"],[3,"cdkColumnDef",4,"ngFor","ngForOf"],["cdkColumnDef","line-actions"],["cdk-header-cell","","scope","col","class","primary-table-header",4,"cdkHeaderCellDef"],["cdk-cell","",4,"cdkCellDef"],["cdk-header-row","",4,"cdkHeaderRowDef"],["cdk-row","",4,"cdkRowDef","cdkRowDefColumns"],[3,"m-5",4,"ngIf"],["cdkColumnDef","checkbox"],["cdk-header-cell","","scope","col",1,"primary-table-header"],["cdk-cell",""],[1,"checkbox-container"],["type","checkbox","aria-hidden","true",3,"change","checked","disabled"],[1,"checkmark"],["cdkColumnDef","show-more"],["cdk-header-cell","","scope","col","class","primary-table-header show-more-column",4,"cdkHeaderCellDef"],["cdk-cell","","class","show-more-column",4,"cdkCellDef"],["cdk-header-cell","","scope","col",1,"primary-table-header","show-more-column"],["cdk-cell","",1,"show-more-column"],[3,"record","columns",4,"ngIf"],[3,"record","columns"],[3,"cdkColumnDef"],["cdk-header-cell","","scope","col",3,"class",4,"cdkHeaderCellDef"],["cdk-cell","",3,"class",4,"cdkCellDef"],["cdk-header-cell","","scope","col"],[3,"labelKey","module"],[3,"state",4,"ngIf"],[3,"state"],[3,"mode","type","field","record"],[3,"config","activeLineAction","record","wrapperClass","klass",4,"ngIf"],[3,"config","activeLineAction","record","wrapperClass","klass"],["cdk-header-row",""],["cdk-row",""],[1,"lead","text-center","pt-3"],["labelKey","MSG_LIST_VIEW_NO_RESULTS_BASIC"],[3,"overlay"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,b2,13,9,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgForOf,ve.NgIf,dp.CdkTable,dp.CdkRowDef,dp.CdkCellDef,dp.CdkHeaderCellDef,dp.CdkColumnDef,dp.CdkCell,dp.CdkRow,dp.CdkHeaderCell,dp.CdkHeaderRow,dp.CdkHeaderRowDef,Dm,m2,qb,af,Pa,FI,ve.AsyncPipe],encapsulation:2})}return r})();function jk(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-bulk-action-menu",8),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("selectionSource",t.selection)("actionSource",t.bulkActions)}}function qR(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",9),e.\u0275\u0275element(1,"scrm-load-more",10),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("loadMoreButton",t.getLoadMoreButton())}}function Uk(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-pagination",11),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("allowPagination",t.isPaginationEnabled())("state",t.pagination)}}let D2=(()=>{class r{isPaginationEnabled(){return"pagination"===this.paginationType}getLoadMoreButton(){return{klass:"load-more",labelKey:"LBL_LOAD_MORE",onClick:()=>{this.config.loadMore()}}}allLoaded(){return this.config?.allLoaded()}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-table-footer"]],inputs:{selection:"selection",bulkActions:"bulkActions",pagination:"pagination",tableActions:"tableActions",paginationType:"paginationType",config:"config"},decls:8,vars:4,consts:[[1,"list-view-tableactions","table-footer"],[1,"d-flex","justify-content-between","align-items-center"],[1,"d-flex"],[3,"selectionSource","actionSource",4,"ngIf"],["buttonClass","btn table-action-button",3,"config"],["class","mx-0 pl-0 load-more-style",4,"ngIf"],[1,"mx-0","pl-0","table-pagination-wrapper"],[3,"allowPagination","state",4,"ngIf"],[3,"selectionSource","actionSource"],[1,"mx-0","pl-0","load-more-style"],[3,"loadMoreButton"],[3,"allowPagination","state"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"div",2),e.\u0275\u0275template(3,jk,1,2,"scrm-bulk-action-menu",3),e.\u0275\u0275element(4,"scrm-action-group-menu",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,qR,2,1,"div",5),e.\u0275\u0275elementStart(6,"div",6),e.\u0275\u0275template(7,Uk,1,2,"scrm-pagination",7),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.selection&&o.bulkActions),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.tableActions),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.isPaginationEnabled()&&!o.allLoaded()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.pagination))},dependencies:[ve.NgIf,Qw,PM,vh,Ph],encapsulation:2})}return r})();function sE(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-table-header",3),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("bulkActions",t.config.bulkActions)("paginationType",t.getPaginationType())("pagination",t.config.pagination)("selection",t.config.selection)("tableActions",null==t.config?null:t.config.tableActions)}}function $k(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-table-footer",4),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("bulkActions",t.config.bulkActions)("paginationType",t.getPaginationType())("pagination",t.config.pagination)("selection",t.config.selection)("tableActions",null==t.config?null:t.config.tableActions)("config",t.config)}}let HI=(()=>{class r{getPaginationType(){return this.config?.loadMore&&"load-more"===this.config?.paginationType?this.config.paginationType:"pagination"}showHeader(){return this.config.showHeader}showFooter(){return this.config.showFooter}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-table"]],inputs:{config:"config"},decls:4,vars:6,consts:[[3,"bulkActions","paginationType","pagination","selection","tableActions",4,"ngIf"],[3,"config"],[3,"bulkActions","paginationType","pagination","selection","tableActions","config",4,"ngIf"],[3,"bulkActions","paginationType","pagination","selection","tableActions"],[3,"bulkActions","paginationType","pagination","selection","tableActions","config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,sE,1,5,"scrm-table-header",0),e.\u0275\u0275element(2,"scrm-table-body",1),e.\u0275\u0275template(3,$k,1,6,"scrm-table-footer",2),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275classMap(o.config&&o.config.klass||""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showHeader()),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.config),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showFooter()))},dependencies:[ve.NgIf,uM,C2,D2],encapsulation:2})}return r})(),w2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,l2,GD,fn.AngularSvgIconModule,hm]})}return r})(),vF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fn.AngularSvgIconModule,dp.CdkTableModule,pa,cF,Uw,jf,Ea,oE]})}return r})(),QR=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,l2,GD,fn.AngularSvgIconModule,KS,hm]})}return r})(),x2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,w2,vF,QR,fn.AngularSvgIconModule]})}return r})();class zI extends kp{checkRecordAccess(v,t=[]){const o=(v.record??{}).acls??[];return!(!o||!o.length)&&this.checkAccess(v.action??null,o,t)}}let _F=(()=>{class r extends zI{constructor(t,n){super(),this.moduleNameMapper=t,this.router=n,this.key="create",this.modes=["list"]}run(t,n=null){const o=n.params.create||{},f={};f.return_module=o.legacyModuleName,f.return_action=o.returnAction,f.return_id=t.record.id,f[o.mapping.moduleName]=o.legacyModuleName,f[o.mapping.name]=t.record.attributes.name,f[o.mapping.id]=t.record.id,this.router.navigate(["/"+o.module+"/"+o.action],{queryParams:f}).then()}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Wo.Router))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),yF=(()=>{class r extends zI{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){const n=t?.action?.acl??[];return!n.length||this.checkRecordAccess(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),S2=(()=>{class r extends js{constructor(t,n){super(),this.createRelated=t,this.async=n,t.modes.forEach(o=>this.actions[o][t.key]=t),n.modes.forEach(o=>this.actions[o][n.key]=n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(_F),e.\u0275\u0275inject(yF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),bF=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne){super(t,n,o,f,D,j,fe,Ne),this.actionManager=t,this.asyncActionService=n,this.message=o,this.confirmation=f,this.language=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}buildActionData(t,n){return{record:n&&n.record||null,action:t}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(S2),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),CF=(()=>{class r{constructor(t,n){this.metadata=t,this.processService=n}build(t,n){return dr({module:"Favorite",type:"Favorite",attributes:{parent_id:n,parent_type:t}})}add(t,n){this.update(t,n,"add")}remove(t,n){this.update(t,n,"remove")}update(t,n,o){const D={favorite:n,action:o};setTimeout(()=>{this.processService.submit("update-favorite",D).pipe((0,M.take)(1)).subscribe(j=>{const fe=j?.data?.favorite??null;null!==fe?this.addFavoriteToMetadata(fe,t):this.removeFavoriteFromMetadata(t,n)})},100)}addFavoriteToMetadata(t,n){const o={id:t?.id??"",module:t?.module??"",attributes:{...t?.attributes??{}}},f=t?.attributes?.parent_id??"",D=this.metadata.getModuleMeta(n),j=D?.favorites??null;if(j){let fe=j.filter(Ne=>(Ne?.attributes?.parent_id??"")!==f);fe.unshift(o),D.favorites=fe}this.metadata.setModuleMetadata(n,D)}removeFavoriteFromMetadata(t,n){const o=this.metadata.getModuleMeta(t),f=o?.favorites??null,D=n?.attributes?.parent_id??null;!f||!f.length||!D||(o.favorites=f.filter(j=>(j?.attributes?.parent_id??"")!==D),this.metadata.setModuleMetadata(t,o))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bf))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),YR=(()=>{class r{constructor(){this.buffer=new i.Subject,this.buffer$=this.buffer.asObservable(),this.enabled=!0,this.subs=[],this.debounceTime=1e3}init(t=1e3){this.debounceTime=t,this.subs.push(this.buffer$.pipe((0,M.debounceTime)(this.debounceTime)).subscribe(()=>{this.enabled=!0}))}destroy(){this.subs.forEach(t=>t.unsubscribe())}debounce(t){t&&this.enabled&&(this.enabled=!1,t(),this.buffer.next(!0))}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();function Wk(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.addButton)}}function XR(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",1),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.removeButton)}}let ZR=(()=>{class r{constructor(t){this.handler=t,this.favorite=!1}ngOnInit(){this.record&&(this.debounceService=new YR,this.debounceService.init(),this.favorite=this?.record?.favorite??!1,this.addButton={klass:["btn btn-sm btn-outline-light favorite-star favorite-off"],onClick:()=>{this.debounceService.debounce(()=>{this.add()})},icon:"star"},this.removeButton={klass:["btn btn-sm btn-outline-light favorite-star favorite-on"],onClick:()=>{this.debounceService.debounce(()=>{this.remove()})},icon:"star"})}ngOnDestroy(){this.debounceService.destroy()}add(){this.record.favorite=!0,this.favorite=!0;const t=this.handler.build(this.record.module,this.record.id);this.handler.add(this.record.module,t)}remove(){this.record.favorite=!1,this.favorite=!1;const t=this.handler.build(this.record.module,this.record.id);this.handler.remove(this.record.module,t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(CF))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-favorite-toggle"]],inputs:{record:"record"},decls:2,vars:2,consts:[[4,"ngIf"],[3,"config"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,Wk,2,1,"ng-container",0)(1,XR,2,1,"ng-container",0),2&n&&(e.\u0275\u0275property("ngIf",!o.favorite),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.favorite))},dependencies:[ve.NgIf,xc],encapsulation:2})}return r})(),DF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa]})}return r})();class E2 extends kp{}let wF=(()=>{class r extends E2{constructor(t){super(),this.message=t,this.key="save",this.modes=["edit"]}run(t){t.store.validate().pipe((0,M.take)(1)).subscribe(n=>{n?t.store.save().pipe((0,M.take)(1)).subscribe(o=>{t.listFilterStore.config.addSavedFilter(t.store.recordStore.extractBaseRecord(o)),t.listFilterStore.applyFilter(),this.message.addSuccessMessageByKey("LBL_SAVED_FILTER_SAVED")}):this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(){return!0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xF=(()=>{class r extends E2{constructor(t,n){super(),this.message=t,this.asyncActionService=n,this.key="delete",this.modes=["edit","detail"]}run(t){const n=`record-${this.key}`,o=t.store.getBaseRecord()||{};o.id?(this.message.removeMessages(),this.asyncActionService.run(n,{action:n,module:o.module,id:o.id},"noop").pipe((0,M.take)(1)).subscribe(()=>{t.listFilterStore.config.removeSavedFilter(o)})):this.message.addWarningMessageByKey("LBL_FILTER_ID_NOT_DEFINED")}shouldDisplay(t){const n=t&&t.store;return!!(n&&n.recordStore.getBaseRecord()||{}).id}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),SF=(()=>{class r extends js{constructor(t,n){super(),t.modes.forEach(o=>this.actions[o][t.key]=t),n.modes.forEach(o=>this.actions[o][n.key]=n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(wF),e.\u0275\u0275inject(xF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const JR={id:"",type:"",module:"",attributes:{}};class EF extends wd{constructor(v,t,n,o,f,D,j,fe,Ne){super(v,t,n,o,f,D,j),this.definitions$=v,this.metadata$=t,this.recordSaveGQL=n,this.recordFetchGQL=o,this.message=f,this.recordManager=D,this.recordMappers=j,this.fieldManager=fe,this.language=Ne,this.internalState=dr(JR),this.stagingState=dr(JR),this.store=new i.BehaviorSubject(this.internalState),this.staging=new i.BehaviorSubject(this.stagingState),this.searchFields={},this.listColumns=[],this.state$=this.store.asObservable().pipe((0,M.tap)(vt=>{this.updateStaging(vt)})),this.staging$=this.staging.asObservable()}getSearchFields(){return this.searchFields}setSearchFields(v){this.searchFields=v}getListColumns(){return this.listColumns}setListColumns(v){this.listColumns=v}getBaseRecord(){return this.stagingState?(this.mapStagingFields(),dr({id:this.stagingState.id,type:this.stagingState.type,module:this.stagingState.module,key:this.stagingState.key,searchModule:this.stagingState.searchModule,criteria:this.stagingState.criteria,attributes:this.stagingState.attributes})):null}extractBaseRecord(v){if(!v)return null;let t=v.criteria??{};return Array.isArray(t)&&!t.length&&(t={}),dr({id:v.id,type:v.type,module:v.module,key:v.key,searchModule:v.searchModule,criteria:t,attributes:v.attributes})}initRecord(v){this.metadata&&(v.metadata=this.metadata),v?.validationTriggered||(v.validationTriggered=(0,e.signal)(!1)),v.attributes=v.attributes||{},v.attributes.search_module=v.searchModule;const t=v?.attributes?.contents?.filters??{};v.attributes.contents=v.attributes.contents||{filters:{}},v.attributes.contents.filters=Array.isArray(t)&&!t.length?{}:t,v.criteria=this.getCriteria(v),this.initCriteriaFields(v,this.getSearchFields()),v.module&&this.definitions&&this.definitions.length>0&&(v.fields=this.recordManager.initFields(v,this.definitions)),this.initOrderByOptions(v)}initOrderByOptions(v){if(!v.fields||!v.fields.orderBy)return;v.fields.orderBy.metadata=v.fields.orderBy.metadata||{};const t=[];this.getListColumns().forEach(n=>{if(!n.default||!0!==n.default)return;const f=this.language.getFieldLabel(n.label||n.fieldDefinition.vname||"",v.searchModule);t.push({value:n.fieldDefinition.name||n.name,label:f})}),v.fields.orderBy.metadata.options$=(0,i.of)(t).pipe((0,M.shareReplay)())}getCriteria(v){return v&&v.criteria?v.criteria.filters?Array.isArray(v.criteria.filters)&&!v.criteria.filters.length?{...v.criteria,filters:{}}:dr(v.criteria):{...v.criteria,filters:{}}:{filters:{}}}initCriteriaFields(v,t){v.criteriaFields=v.criteriaFields||{},v.criteriaFormGroup||(v.criteriaFormGroup=new Ji.UntypedFormGroup({})),t&&Object.keys(t).forEach(n=>{this.buildField(v,t[n])})}buildField(v,t){const o=t.type,f={name:t.name,label:t.label,vardefBased:t?.vardefBased??!1,readonly:t?.readonly??!1,display:t?.display??"default",type:o,fieldDefinition:{}};t.fieldDefinition&&(f.fieldDefinition=t.fieldDefinition),("bool"===o||"boolean"===o)&&(f.fieldDefinition.options="dom_int_bool"),this.fieldManager.addFilterField(v,f,this.language)}}let T2=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.recordFetchGQL=t,this.recordSaveGQL=n,this.message=o,this.recordManager=f,this.recordMappers=D,this.baseMapper=j,this.fieldManager=fe,this.language=Ne,D.register("default",j.getKey(),j)}create(t,n){return new EF(t,n,this.recordSaveGQL,this.recordFetchGQL,this.message,this.recordManager,this.recordMappers,this.fieldManager,this.language)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const TF={module:"",searchModule:"",recordID:"",loading:!1,mode:"detail"};let MF=(()=>{class r{constructor(t,n,o,f,D,j){this.appStateStore=t,this.meta=n,this.message=o,this.fieldManager=f,this.language=D,this.savedFilterStoreFactory=j,this.cache$=null,this.internalState=dr(TF),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subs=[],this.metadataLoadingState=new i.BehaviorSubject(!1),this.metadataLoading$=this.metadataLoadingState.asObservable(),this.meta$=this.meta.getMetadata("saved-search",["recordView"]).pipe((0,M.tap)(()=>this.metadataLoadingState.next(!1)),(0,M.map)(fe=>{const Ne={...fe.recordView};return Ne.actions=(Ne?.actions??[]).filter(vt=>"cancel"!==vt.key),Ne})),this.recordStore=j.create(this.getViewFields$(),this.getRecordMeta$()),this.record$=this.recordStore.state$.pipe((0,M.distinctUntilChanged)(),(0,M.map)(fe=>fe)),this.stagingRecord$=this.recordStore.staging$.pipe((0,M.distinctUntilChanged)(),(0,M.map)(fe=>fe)),this.loading$=this.state$.pipe((0,M.map)(fe=>fe.loading)),this.mode$=this.state$.pipe((0,M.map)(fe=>fe.mode)),this.vm$=this.stagingRecord$.pipe((0,i.combineLatestWith)(this.mode$),(0,M.map)(([fe,Ne])=>(this.vm={record:fe,mode:Ne},this.vm))),this.recordValidationHandler=(0,e.inject)(M_)}getModuleName(){return this.internalState.module}getRecordId(){return this.internalState.recordID}getViewContext(){return{module:this.getModuleName(),id:this.getRecordId()}}destroy(){this.clear()}init(t,n="detail"){return this.internalState.module="saved-search",this.internalState.recordID=t,this.setMode(n),this.metadataLoadingState.next(!0),(0,i.forkJoin)([this.meta$,this.load()]).pipe((0,M.map)(([f,D])=>D))}initRecord(t,n,o,f,D="detail"){this.updateState({...this.internalState,recordID:n.id,module:"saved-search",searchModule:t,mode:D}),this.metadataLoadingState.next(!0),this.meta$.pipe((0,M.take)(1),(0,M.tap)(()=>{this.metadataLoadingState.next(!1),this.initStaging(t,n,o,f,null)})).subscribe()}initStaging(t,n,o,f,D){const j=dr(this.recordStore.extractBaseRecord(n));j.searchModule=t,this.recordStore.setSearchFields(o),this.recordStore.setListColumns(f),this.recordStore.setMetadata(D),this.recordStore.setStaging(j),this.recordValidationHandler.initValidators(this.recordStore.getStaging())}clear(){this.cache$=null,this.updateState(dr(TF)),this.metadataLoadingState.unsubscribe(),this.metadataLoadingState=null,this.recordStore.destroy(),this.recordStore=null}clearAuthBased(){this.clear()}getBaseRecord(){return this.recordStore.getBaseRecord()}getMode(){return this.internalState?this.internalState.mode:null}setMode(t){this.updateState({...this.internalState,mode:t})}save(){return this.appStateStore.updateLoading(`${this.internalState.module}-record-save`,!0),this.recordStore.save().pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_ERROR_SAVING"),(0,i.of)({}))),(0,M.finalize)(()=>{this.appStateStore.updateLoading(`${this.internalState.module}-record-save`,!1)}))}validate(){return(0,i.forkJoin)([this.recordStore.validate(),this.validateCriteria()]).pipe((0,M.map)(([t,n])=>t&&n))}validateCriteria(){const n=this.recordStore.getStaging().criteriaFormGroup;return n.markAllAsTouched(),n.statusChanges.pipe((0,M.startWith)(n.status),(0,M.filter)(o=>"PENDING"!==o),(0,M.take)(1),(0,M.map)(o=>"VALID"===o))}load(t=!0){return this.appStateStore.updateLoading(`${this.internalState.module}-record-fetch`,!0),this.recordStore.retrieveRecord(this.internalState.module,this.internalState.recordID,t).pipe((0,M.tap)(n=>{this.appStateStore.updateLoading(`${this.internalState.module}-record-fetch`,!1),this.updateState({...this.internalState,recordID:n.id,module:n.module})}))}getViewFieldsKeys$(){return this.meta$.pipe((0,M.map)(t=>{const n=[];return t.panels.forEach(o=>{o.rows.forEach(f=>{f.cols.forEach(D=>{n.push(D.name)})})}),n}))}getViewFields$(){return this.meta$.pipe((0,M.map)(t=>{const n=[];return t.panels.forEach(o=>{o.rows.forEach(f=>{f.cols.forEach(D=>{n.push(D)})})}),n}))}getRecordMeta$(){return this.meta$.pipe((0,M.map)(t=>t.metadata||{}))}updateState(t){this.store.next(this.internalState=t)}getMetadata(){return(this.meta.get()||{}).recordView||{}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(T2))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),eL=(()=>{class r extends Co{constructor(t){super(t),this.apollo=t}save(t){return super.save(t)}mapToRecord(t){if(!t.data||!t.data.saveRecord||!t.data.saveRecord.record)return null;const n={id:t.data.saveRecord.record._id,type:t.data.saveRecord.record.type||"",module:t.data.saveRecord.record.module||"",attributes:t.data.saveRecord.record.attributes||null};n.key=n.id||n.attributes&&n.attributes.id||"";const o=n.attributes&&n.attributes.contents||null;return o&&(n.criteria=o),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(X.Apollo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),tL=(()=>{class r{getKey(){return"criteria"}map(t){const n=t;if(n.criteria){const f=n?.attributes?.contents??{};f.filters=dr(n?.criteria?.filters??{}),t.fields.name&&(f.name=t.fields.name.value,n.criteria.name=f.name),t.fields.orderBy&&(f.orderBy=t.fields.orderBy.value,n.criteria.orderBy=f.orderBy),t.fields.sortOrder&&(f.sortOrder=t.fields.sortOrder.value,n.criteria.sortOrder=f.sortOrder),t.attributes.search_module&&(f.searchModule=t.attributes.search_module,n.criteria.searchModule=f.searchModule),n.attributes.contents=f}let o=n.key||"";"default"===o&&(o=""),n.id=o,n.attributes.id=o}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),IF=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn){this.recordFetchGQL=t,this.recordSaveGQL=n,this.appStateStore=o,this.languageStore=f,this.metadataStore=D,this.message=j,this.recordManager=fe,this.fieldManager=Ne,this.recordMappers=vt,this.baseMapper=ln,this.savedSearchMapper=Hn,this.savedFilterStoreFactory=new T2(t,n,j,fe,vt,ln,Ne,f),this.recordMappers.register("saved-search",this.savedSearchMapper.getKey(),this.savedSearchMapper)}create(){return new MF(this.appStateStore,this.metadataStore,this.message,this.fieldManager,this.languageStore,this.savedFilterStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(eL),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(cy),e.\u0275\u0275inject(jh),e.\u0275\u0275inject(tL))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),AF=(()=>{class r{constructor(t,n){this.message=t,this.savedFilterStoreFactory=n,this.panelMode="closable",this.mode="filter",this.gridButtons=null,this.fields=[],this.special=[],this.savedFilters=[],this.subs=[],this.filterStore=n.create()}init(t){this.config=t,this.initSearchFields(),this.initConfigUpdatesSubscription(),this.vm$=this.filterStore.stagingRecord$.pipe((0,M.map)(n=>[n]),(0,M.tap)(([n])=>{this.reset(),this.splitCriteriaFields(n),this.initDisplayFields(),"detail"!==this.filterStore.getMode()&&this.initGridButtons(),this.initHeaderButtons(),this.initMyFiltersButton(this.savedFilters)})),this.config.panelMode&&(this.panelMode=this.config.panelMode),this.collapse=new i.BehaviorSubject(!1),this.isCollapsed$=this.collapse.asObservable(),Al(this.config.isCollapsed)||this.collapse.next(this.config.isCollapsed),this.reset(),this.initGridButtons(),this.initHeaderButtons()}clear(){this.subs.forEach(t=>t.unsubscribe()),this.reset(),this.filterStore.clear(),this.filterStore=null,this.collapse.unsubscribe()}clearAuthBased(){this.clear()}reset(){this.fields=[],this.special=[]}applyFilter(){this.filterStore.validateCriteria().pipe((0,M.take)(1)).subscribe(t=>{if(t)return"collapsible"===this.config.panelMode&&this.config.collapseOnSearch&&this.collapse.next(!0),this.config.onSearch(),void this.config.updateFilter(this.filterStore.getBaseRecord());this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}clearFilter(){this.config.resetFilter(!1)}initConfigUpdatesSubscription(){this.subs.push(this.config.filter$.pipe((0,i.combineLatestWith)(this.config.searchFields$),(0,M.tap)(([t,n])=>{this.reset();let o="edit";(t.readonly??!1)&&(o="detail",this.mode=o),this.filterStore.initRecord(this.config.module,t,n,this.config.listFields,o)})).subscribe()),this.subs.push(this.config.savedFilters$.pipe((0,M.map)(t=>[t]),(0,M.tap)(([t])=>{this.savedFilters=t,this.initMyFiltersButton(t)})).subscribe())}splitCriteriaFields(t){!t||!t.criteriaFields||Object.entries(t.criteriaFields).forEach(([n,o])=>{if((o.name||n).includes("_only"))return void this.special.push(o);if(!o.vardefBased)return void this.fields.push(o);if(!0===o.readonly)return;const j=(t?.criteria?.filters??{})[n]??{};!(0,wt.isEmpty)(j?.operator)&&"none"===o.display()&&o.display.set("default"),this.fields.push(o)})}initSearchFields(){this.subs.push(this.config.searchFields$.subscribe(t=>{this.searchFields=t}))}initDisplayFields(){(!this.searchFields||_a(this.searchFields)||!this.fields)&&(this.displayFields=[]);const t=[];this.fields.forEach(n=>{const o=n.name;"none"===n?.display()||"groupField"===n.source||(this.searchFields[o]||(n.readonly=!0),t.push(n))}),this.displayFields=t}initGridButtons(){this.gridButtons=[{id:"clear",labelKey:"LBL_CLEAR_BUTTON_LABEL",klass:["clear-filters-button","btn","btn-outline-danger","btn-sm"],onClick:this.clearFilter.bind(this)},{id:"search",labelKey:"LBL_SEARCH_BUTTON_LABEL",klass:["filter-button","btn","btn-danger","btn-sm"],onClick:this.applyFilter.bind(this)}]}initHeaderButtons(){this.closeButton={onClick:()=>{this.config.onClose()}}}initMyFiltersButton(t){if(!t||t.length<1)return void(this.myFilterButton=null);const n={wrapperKlass:["filter-select"],labelKey:"LBL_SAVED_FILTER_SHORTCUT",klass:["btn","btn-outline-light","btn-sm"],items:[]},o=this.filterStore.getRecordId();t.forEach(f=>{const D={label:f.attributes.name,onClick:()=>{this.config.setOpenFilter(f)}};f.key===o&&(n.label=f.attributes.name,n.labelKey="",D.icon="filter",D.iconKlass="small",D.klass="active"),n.items.push(D)}),this.myFilterButton=n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(IF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),nL=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){super(f,D,j,fe,o,Ne,vt,ln),this.store=t,this.listFilterStore=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne,this.metadata=vt,this.appMetadataStore=ln,this.actions={}}getActions(t){return this.store.meta$.pipe((0,i.combineLatestWith)(this.store.mode$,this.store.stagingRecord$,this.language.vm$),(0,M.map)(([n,o])=>{if(!o||!n)return[];const f=this.parseModeActions(n.actions,o);return f.forEach(D=>{this.actions[D.key]=D}),f}))}run(t){const n=this.actions[t];n&&this.runAction(n)}buildActionData(t,n){return{store:this.store,listFilterStore:this.listFilterStore,action:t}}getMode(){return this.store.getMode()}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.store.load(!1).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(MF),e.\u0275\u0275inject(AF),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(SF),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),iL=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.language=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confimation=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t,n){return new nL(t,n,this.language,this.actionManager,this.asyncActionService,this.message,this.confimation,this.selectModalService,this.metadata,this.appMetadataStore)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(SF),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),OF=(()=>{class r{constructor(t,n){this.message=t,this.savedFilterStoreFactory=n}create(){return new AF(this.message,this.savedFilterStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(IF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function Hk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6),e.\u0275\u0275element(1,"scrm-dropdown-button",7),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.store.myFilterButton)}}function o3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",13)(1,"label",14),e.\u0275\u0275element(2,"scrm-label",15),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"scrm-field",16),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.labelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("field",t)("mode",o.store.mode)("record",n)("type",t.type)}}function rL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",11),e.\u0275\u0275template(1,o3,4,5,"div",12),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.store.special)}}function zk(r,v){1&r&&e.\u0275\u0275element(0,"scrm-button",7),2&r&&e.\u0275\u0275property("config",v.$implicit)}function GI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",17),e.\u0275\u0275template(1,zk,1,1,"scrm-button",18),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.store.gridButtons)}}function M2(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"scrm-field-grid",8),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.onFocusSearch())}),e.\u0275\u0275template(1,rL,2,1,"div",9)(2,GI,2,1,"div",10),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275property("actions",!0)("appendActions",!1)("fieldMode",n.store.mode)("fields",n.store.displayFields)("record",t)("special",n.store.special.length>0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.store.special.length>0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.store.gridButtons)}}function Gk(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",19),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.onFocusSave())}),e.\u0275\u0275element(2,"scrm-record-grid",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.gridConfig)}}function Kk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"scrm-panel",1),e.\u0275\u0275template(1,Hk,2,1,"div",2),e.\u0275\u0275elementStart(2,"div",3),e.\u0275\u0275template(3,M2,3,8,"scrm-field-grid",4)(4,Gk,3,1,"ng-container",5),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275propertyInterpolate1("klass","filter-panel m-0 ",t.config&&t.config.klass||"",""),e.\u0275\u0275property("showHeader",t.config.displayHeader)("close",t.store.closeButton)("isCollapsed$",t.store.isCollapsed$)("mode",t.store.panelMode)("titleKey","LBL_BASIC_FILTER"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.store.myFilterButton),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.store.displayFields&&t.store.displayFields.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.config&&t.config.savedFilterEdit&&"detail"!==t.store.filterStore.getMode())}}let I2=(()=>{class r{onEnterKey(){this.selectedActionButton&&(this.selectedActionButton.onClick(),event.preventDefault())}constructor(t,n){this.storeFactory=t,this.actionAdapterFactory=n,this.subs=[],this.store=t.create(),this.filterActionsAdapter=n.create(this.store.filterStore,this.store)}ngOnInit(){this.store.init(this.config),this.vm$=this.store.vm$.pipe((0,M.map)(([t])=>{const n={...t};return n.fields=t.criteriaFields,n})),this.searchActionButton=this.store.gridButtons.find(t=>"search"===t.id),this.saveActionButton={id:"save",onClick:()=>{this.filterActionsAdapter.run("save")}},this.gridConfig={record$:this.store.filterStore.stagingRecord$,mode$:this.store.filterStore.mode$,fields$:this.store.filterStore.getViewFieldsKeys$(),actions:this.filterActionsAdapter,appendActions:!0,klass:"mt-2 p-2 saved-search-container rounded",buttonClass:"btn btn-outline-danger btn-sm",labelDisplay:"inline",rowClass:{"align-items-start":!0,"align-items-center":!1},colAlignItems:"align-items-start",maxColumns$:(0,i.of)(4).pipe((0,M.shareReplay)(1)),sizeMap$:(0,i.of)({handset:1,tablet:2,web:4,wide:4}).pipe((0,M.shareReplay)(1))}}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.store.clear(),this.store=null}onFocusSearch(){this.selectedActionButton=this.searchActionButton}onFocusSave(){this.selectedActionButton=this.saveActionButton}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(OF),e.\u0275\u0275directiveInject(iL))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-list-filter"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keydown.enter",function(D){return o.onEnterKey(D)})},inputs:{config:"config"},decls:2,vars:3,consts:[[3,"showHeader","close","isCollapsed$","mode","klass","titleKey",4,"ngIf"],[3,"showHeader","close","isCollapsed$","mode","klass","titleKey"],["panel-header-button","",4,"ngIf"],["panel-body","",1,"p-2","filter-body"],[3,"actions","appendActions","fieldMode","fields","record","special","click",4,"ngIf"],[4,"ngIf"],["panel-header-button",""],[3,"config"],[3,"click","actions","appendActions","fieldMode","fields","record","special"],["class","special-field-grid","field-grid-special","",4,"ngIf"],["class","mt-4 align-self-end","field-grid-actions","",4,"ngIf"],["field-grid-special","",1,"special-field-grid"],["class","d-inline-block mr-sm-2 w-25 special-field-grid-col",4,"ngFor","ngForOf"],[1,"d-inline-block","mr-sm-2","w-25","special-field-grid-col"],[1,"form-check-label"],[3,"labelKey"],[3,"field","mode","record","type"],["field-grid-actions","",1,"mt-4","align-self-end"],[3,"config",4,"ngFor","ngForOf"],[3,"click"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Kk,5,10,"scrm-panel",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgForOf,ve.NgIf,xc,wl,I_,pm,Pa,a2,Dm,ve.AsyncPipe],encapsulation:2})}return r})(),A2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,xm,gv,Bh,Ea,QC,Oa,pa]})}return r})(),qk=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qm,x2,Ea,jf,A2,Oa]})}return r})();function Qk(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-grid",4),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.getGridConfig())}}function Yk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"scrm-panel",1)(1,"div",2),e.\u0275\u0275template(2,Qk,2,1,"ng-container",3),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275propertyInterpolate1("klass","record-panel ",t.config&&t.config.klass||"",""),e.\u0275\u0275property("close",t.closeButton)("isCollapsed$",t.isCollapsed$)("mode",t.panelMode)("titleKey",t.config.title||""),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.config)}}e.\u0275\u0275setComponentScope(Py,[ve.NgIf,qm,HI,Pa,af,I2,xc],[ve.AsyncPipe]);let FF=(()=>{class r{constructor(){this.panelMode="closable"}ngOnInit(){this.vm$=this.config.store.vm$,this.initCloseButton(),this.config.panelMode&&(this.panelMode=this.config.panelMode),this.collapse=new i.BehaviorSubject(!1),this.isCollapsed$=this.collapse.asObservable(),Al(this.config.isCollapsed)||this.collapse.next(this.config.isCollapsed)}ngOnDestroy(){}getGridConfig(){return{record$:this.config.store.stagingRecord$,mode$:this.config.store.mode$,fields$:this.config.store.getViewFieldsKeys$(),actions:this.config.actions,klass:"mt-2 rounded",buttonClass:"btn btn-outline-danger btn-sm",maxColumns$:(0,i.of)(4).pipe((0,M.shareReplay)(1)),sizeMap$:(0,i.of)({handset:1,tablet:2,web:3,wide:4}).pipe((0,M.shareReplay)(1))}}initCloseButton(){this.closeButton={onClick:()=>{this.config.onClose()}}}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-panel"]],inputs:{config:"config"},decls:2,vars:3,consts:[[3,"close","isCollapsed$","mode","titleKey","klass",4,"ngIf"],[3,"close","isCollapsed$","mode","titleKey","klass"],["panel-body","",1,"pl-2","pr-2"],[4,"ngIf"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Yk,3,7,"scrm-panel",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,wl,a2,ve.AsyncPipe],encapsulation:2})}return r})();class oL extends kp{}let sL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Oa,xm,gv,Bh,Ea,Oa,QC]})}return r})(),NF=(()=>{class r extends Rd{constructor(t,n,o,f,D,j){super(t,n,o,f,D,j),this.appStateStore=t,this.meta=n,this.message=o,this.fieldManager=f,this.language=D,this.storeFactory=j}getViewFields$(){return this.meta$.pipe((0,M.map)(t=>t.fields))}getViewFieldsKeys$(){return this.meta$.pipe((0,M.map)(t=>{if(!t.fields||!t.fields.length)return[];const n=[];return t.fields.forEach(o=>{n.push(o.name)}),n}))}initRecord(t,n="detail",o=!0){super.initRecord(t,n,o),this.setRecord(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Os))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),aL=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt){this.recordFetchGQL=t,this.recordSaveGQL=n,this.appStateStore=o,this.languageStore=f,this.metadataStore=D,this.message=j,this.recordManager=fe,this.fieldManager=Ne,this.recordStoreFactory=vt}create(){return new NF(this.appStateStore,this.metadataStore,this.message,this.fieldManager,this.languageStore,this.recordStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(_p),e.\u0275\u0275inject(Os))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Xk={module:"",query:{},statistic:{id:"",data:{}},loading:!1};let RF=(()=>{class r extends xo{constructor(t){super(t),this.fetchGQL=t,this.cache$=null,this.internalState=dr(Xk),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.statistic$=this.state$.pipe((0,M.map)(n=>n.statistic),(0,M.distinctUntilChanged)())}updateState(t){super.updateState(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),lL=(()=>{class r{traverse(t,n,o){t.singleSeries&&t.singleSeries.forEach(f=>{n.visit(f,o)}),t.multiSeries&&t.multiSeries.forEach(f=>{f.series.forEach(D=>{n.visit(D,o)})})}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),cL=(()=>{class r{constructor(t,n){this.currencyService=t,this.preferences=n}toUserFormat(t,n=null){const o=parseFloat(t);if(!isFinite(o))return t;const f=this.currencyService.getUserCurrency();return this.currencyService.baseToCurrency(f.id,o).toString()}toInternalFormat(t){const n=parseFloat(t);if(!isFinite(n))return t;const o=this.currencyService.getUserCurrency();return this.currencyService.currencyToBase(o.id,n).toString()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ev),e.\u0275\u0275inject($a))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),uL=(()=>{class r{constructor(t){this.currencyUnitConverter=t,this.map={},this.addUnitConverter("currency",t)}addUnitConverter(t,n){this.map[t]=n}toUserFormat(t,n,o){if(!t)return n;const f=this.map[t];return f?f.toUserFormat(n,o):n}toInternalFormat(t,n){if(!t)return n;const o=this.map[t];return o?o.toInternalFormat(n):n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(cL))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),dL=(()=>{class r{constructor(t){this.converter=t}visit(t,n){const o=n?.dataType??null,f=n?.direction??"user-unit";if(!o)return;const D=parseFloat(t.value.toString());if(isFinite(D)){if("user-unit"===f)return void(t.value=this.converter.toUserFormat(o,D.toString()));t.value=this.converter.toInternalFormat(o,D.toString())}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uL))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),LF=(()=>{class r{constructor(t,n){this.traverser=t,this.dataTypeMapper=n,this.registry={},this.addMapper("data-type-unit-converter",n)}addMapper(t,n){this.registry[t]=n}map(t,n,o){const f=this?.registry[n]??null;f&&this.traverser.traverse(t,f,o)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(lL),e.\u0275\u0275inject(dL))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const Zk={module:"",query:{},statistic:{id:"",data:{}},loading:!1};let fL=(()=>{class r extends RF{constructor(t,n,o){super(t),this.fetchGQL=t,this.formatter=n,this.seriesMapper=o,this.internalState=dr(Zk),this.store=new i.BehaviorSubject(this.internalState),this.defaultOptions={},this.state$=this.store.asObservable(),this.statistic$=this.state$.pipe((0,M.map)(f=>f.statistic),(0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(f=>f.loading),(0,M.distinctUntilChanged)())}setDefaultOptions(t){this.defaultOptions=t}getDataSource(){return this.internalState.dataSource}addNewState(t){if(!t.metadata||!t.metadata.dataType)return;this.injectDefaultValues(t);const n=this.buildCharDataSource(t);this.updateState({...this.internalState,statistic:t,dataSource:n,loading:!1})}injectDefaultValues(t){t.metadata.chartOptions?Object.keys(this.defaultOptions).forEach(n=>{n in t.metadata.chartOptions||(t.metadata.chartOptions[n]=this.defaultOptions[n])}):t.metadata.chartOptions=dr(this.defaultOptions)}buildCharDataSource(t){const n=t.metadata.dataType||"";let o=null;const f=t.metadata&&t.metadata.digits||null;return null!==f&&(o={digits:f}),{options:t.metadata.chartOptions||{},getResults:()=>(0,i.of)(this.buildSeriesResult(t)).pipe((0,M.shareReplay)(1)),tickFormatting:D=>this.formatter.toUserFormat(n,D,o),tooltipFormatting:D=>this.formatter.toUserFormat(n,D,o)}}buildSeriesResult(t){const n=t.metadata.dataType||"",o={},f=t.data.singleSeries||null;f&&(o.singleSeries=f);const D=t.data.multiSeries||null;return D&&(o.multiSeries=D),this.seriesMapper.map(o,"data-type-unit-converter",{dataType:n}),o}updateState(t){super.updateState(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(LF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),kF=(()=>{class r{constructor(t,n,o){this.fetchGQL=t,this.formatter=n,this.seriesMapper=o}create(){return new fL(this.fetchGQL,this.formatter,this.seriesMapper)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us),e.\u0275\u0275inject(_s),e.\u0275\u0275inject(LF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),v0=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["ng-component"]],inputs:{config:"config",context:"context",context$:"context$"},decls:0,vars:0,template:function(n,o){},encapsulation:2})}return r})();function Jk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"option",18),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("value",n.getKey(t)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",n.language.getFieldLabel(t.labelKey)," ")}}function eP(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",13)(1,"div",14)(2,"form",15)(3,"select",16),e.\u0275\u0275listener("ngModelChange",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.onChartSelect())}),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.selectedChart,o)||(f.selectedChart=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275template(4,Jk,2,2,"option",17),e.\u0275\u0275elementEnd()()()()}if(2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(3),e.\u0275\u0275twoWayProperty("ngModel",t.selectedChart),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.configuredCharts)}}function pL(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-chart",20),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("dataSource",t.dataSource)("type",t.chartType)}}function tP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,pL,1,2,"scrm-chart",19),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.dataSource&&t.chartType)}}function hL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",21),e.\u0275\u0275element(1,"scrm-loading-spinner",22),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275classProp("m-3",!t.dataSource),e.\u0275\u0275advance(),e.\u0275\u0275property("overlay",!0)}}function s3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"p",23),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.language.getFieldLabel(t.messageLabelKey)," ")}}function nP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"scrm-widget-panel",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div",5),e.\u0275\u0275template(5,eP,5,2,"div",6),e.\u0275\u0275elementStart(6,"div",7)(7,"div",8)(8,"div",9),e.\u0275\u0275template(9,tP,2,1,"ng-container",10)(10,hL,2,3,"div",11)(11,s3,2,1,"p",12),e.\u0275\u0275elementEnd()()()()()()()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("title",t.title),e.\u0275\u0275advance(5),e.\u0275\u0275property("ngIf",t.isConfigured&&t.chartOptions.toggle),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.selectedChart&&!t.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(t.loading||t.isConfigured()&&t.dataSource))}}let PF=(()=>{class r extends v0{constructor(t,n){super(),this.language=t,this.factory=n,this.charts={},this.titleLabelKey="LBL_INSIGHTS",this.title="",this.messageLabelKey="LBL_CHART_NOT_FOUND",this.selectedChart="",this.chartType="",this.loading=!0,this.subs=[]}ngOnInit(){if(this.appStrings$=this.language.appStrings$,!1===this.validateConfig())return;this.context$&&this.subs.push(this.context$.subscribe(o=>{this.context=o,Object.keys(this.charts).forEach(f=>{this.charts[f].store.context=o})}));const t=this.config.options,n=t.charts;t.defaultChart&&(this.selectedChart=t.defaultChart||""),this.setupCharts(n),this.setHeaderTitle(t),this.reloadSelectedChart(),this.setupLoading(),this.setupVM(),this.setupReload()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}get configuredCharts(){return this.chartOptions.charts||[]}get chartOptions(){return this.config.options||{}}isConfigured(){return!(!this.config.options.charts||!this.config.options.charts.length)}getLabelKey(t){return t.statistic.metadata&&t.statistic.metadata.labelKey||this.charts[t.query.key].labelKey}getKey(t){return t.chartKey||t.statisticsType||""}validateConfig(){if(!this.context||!this.context.module)return this.messageLabelKey="LBL_BAD_CONFIG_BAD_CONTEXT",!1;if(!this.config)return this.messageLabelKey="LBL_BAD_CONFIG_NO_CONFIG",!1;const t=this.config.options;return!!(t&&t.charts&&t.charts.length)||(this.messageLabelKey="LBL_BAD_CONFIG_NO_STATISTICS_KEY",!1)}setupCharts(t){this.selectedChart="",t.forEach(n=>{const o=this.getKey(n);o&&(this.selectedChart||(this.selectedChart=o||"",this.chartType=n.chartType),this.buildChartInfo(o,n),this.initChartStore(o,n))})}buildChartInfo(t,n){this.charts[t]={key:t,labelKey:n.labelKey||"",chartType:n.chartType,statisticsType:n.statisticsType,store:this.factory.create(),reload:!0}}initChartStore(t,n){this.charts[t].store.init(this.context.module,{key:n.statisticsType,context:{...this.context}},!1),this.charts[t].store.setDefaultOptions(n.chartOptions)}setHeaderTitle(t){if(this.config.labelKey&&(this.titleLabelKey=this.config.labelKey),t.headerTitle){if(!this.charts||!this.charts[this.selectedChart]||!this.charts[this.selectedChart].labelKey)return;this.titleLabelKey=this.charts[this.selectedChart].labelKey}this.title=this.language.getFieldLabel(this.titleLabelKey)}onChartSelect(){this.dataSource=null,this.chartType=this.charts[this.selectedChart].chartType,this.reloadSelectedChart(!1)}setupVM(){const t=[];Object.keys(this.charts).forEach(o=>t.push(this.charts[o].store.state$));let n=(0,i.of)([]);if(t.length<1)n=(0,i.of)([]);else if(1===t.length)n=t[0].pipe((0,M.map)(o=>[o]));else{let f,o=null;[o,...f]=t,n=o.pipe((0,i.combineLatestWith)(f))}this.vm$=n.pipe((0,i.combineLatestWith)(this.language.appStrings$),(0,M.map)(([o,f])=>({statistics:this.mapChartData(o),appStrings:f})))}mapChartData(t){const n={};return t.forEach(o=>{o.query.key&&(n[o.query.key]=o,this.charts[o.query.key].labelKey=this.getLabelKey(o))}),n}setupReload(){this.config.reload$&&this.subs.push(this.config.reload$.subscribe(()=>{!0!==this.loading&&(this.loading=!0,Object.keys(this.charts).forEach(t=>{this.charts[t].reload=!0}),this.reloadSelectedChart())}))}setupLoading(){const t=[];Object.keys(this.charts).forEach(o=>t.push(this.charts[o].store.loading$));let n=(0,i.of)([]);if(t.length<1)n=(0,i.of)([]);else if(1===t.length)n=t[0].pipe((0,M.map)(o=>[o]));else{let f,o=null;[o,...f]=t,n=o.pipe((0,i.combineLatestWith)(f))}this.loading$=n.pipe((0,M.map)(o=>{if(!o||o.length<1)return this.loading=!1,!1;let f=!1;return o.forEach(D=>{f=f||D}),this.loading=f,f})),this.subs.push(this.loading$.subscribe())}reloadSelectedChart(t=!1){!this.charts||!this.charts[this.selectedChart]||!this.charts[this.selectedChart].store||this.charts[this.selectedChart].store.load(t=t&&!this.charts[this.selectedChart].reload).pipe((0,M.take)(1),(0,M.tap)(()=>{this.dataSource=this.charts[this.selectedChart]?.store?.getDataSource()??null,this.charts[this.selectedChart].reload=!1})).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(kF))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["chart-sidebar-widget"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[[3,"title",4,"ngIf"],[3,"title"],["widget-body",""],[1,"widget-background","chart-sidebar-widget"],[1,"mb-2","ml-1","mr-1"],[1,"container-fluid"],["class","row",4,"ngIf"],[1,"row","mt-3","chart-widget"],[1,"col","pl-0","pr-0","pb-1","pt-1","d-flex","justify-content-center"],[1,"flex-grow-1"],[4,"ngIf"],["class","chart-loading",3,"m-3",4,"ngIf"],["class","lead text-center pt-3",4,"ngIf"],[1,"row"],[1,"col","pr-2","pl-2"],[1,"login-form","mb-0","mt-2","w-100"],["name","chart",1,"m-0","w-100",3,"ngModelChange","ngModel"],[3,"value",4,"ngFor","ngForOf"],[3,"value"],[3,"dataSource","type",4,"ngIf"],[3,"dataSource","type"],[1,"chart-loading"],[3,"overlay"],[1,"lead","text-center","pt-3"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,nP,12,5,"scrm-widget-panel",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgForOf,ve.NgIf,f0,Ji.\u0275NgNoValidate,Ji.NgSelectOption,Ji.\u0275NgSelectMultipleOption,Ji.SelectControlValueAccessor,Ji.NgControlStatus,Ji.NgControlStatusGroup,Ji.NgModel,Ji.NgForm,ew,af,ve.AsyncPipe],encapsulation:2})}return r})(),BF=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Gp,Ji.FormsModule,yy,jf]})}return r})(),mL=(()=>{class r{constructor(t){this.listStoreFactory=t,this.recordList=t.create()}clear(){this.recordList.clear(),this.recordList=null}clearAuthBased(){this.recordList.clearAuthBased()}init(t){this.recordList.init("history",!1,"list_max_entries_per_subpanel"),this.initViewContext(t)}load(t=!0){return this.recordList.load(t)}initSearchCriteria(t,n){this.recordList.criteria={preset:{type:"history-timeline",params:{parentModule:this.viewContext.module,parentId:this.viewContext.id,offset:t,limit:n}}}}initViewContext(t){this.viewContext=t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),O2=(()=>{class r{constructor(t){this.listStoreFactory=t}create(){return new mL(this.listStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($p))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),F2=(()=>{class r{constructor(t){this.historyTimelineStoreFactory=t,this.loading=(0,e.signal)(!1),this.initializing=(0,e.signal)(!0),this.firstLoad=(0,e.signal)(!0),this.allLoaded=(0,e.signal)(!1),this.cache=[],this.dataStream=new i.BehaviorSubject(this.cache),this.dataStream$=this.dataStream.asObservable(),this.defaultPageSize=10}init(t){this.store=this.historyTimelineStoreFactory.create(),this.store.init(t)}fetchTimelineEntries(t){if(!0!==this.loading())return!0===t&&(this.cache.length=0),this.store.initSearchCriteria(this.cache.length,this.defaultPageSize),this.loading.set(!0),this.initializing.set(!1),this.store.load(!1).pipe((0,M.take)(1)).subscribe(n=>{this.loading.set(!1),this.firstLoad.set(!1);const o=n.records;_a(o)||Object.keys(o).forEach(f=>{this.cache.push(this.buildTimelineEntry(o[f]))}),this.allLoaded.set((n?.pagination?.pageLast??0)<(n?.pagination?.pageSize??0)),this.dataStream.next([...this.cache])}),this.dataStream$}getActivityGridColor(t){return{calls:"yellow",tasks:"green",meetings:"blue",notes:"orange",audit:"purple",history:"purple"}[t]||"yellow"}buildTimelineEntry(t){const n=t.module;let o=t.attributes.module_name;"audit"===n&&(o="History");const D={module:n,icon:o,color:this.getActivityGridColor(t.module),title:{type:"varchar",value:t.attributes.name,loading:(0,e.signal)(!1),display:(0,e.signal)("default")},user:{type:"varchar",value:t.attributes.assigned_user_name.user_name,loading:(0,e.signal)(!1),display:(0,e.signal)("default")},date:{type:"datetime",value:t.attributes.date_end,loading:(0,e.signal)(!1),display:(0,e.signal)("default")},record:t};return"audit"===n&&(D.description={type:"html",value:t.attributes.description,loading:(0,e.signal)(!1),display:(0,e.signal)("default")}),D}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(O2))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),N2=(()=>{class r{constructor(t){this.historyTimelineStoreFactory=t}create(){return new F2(this.historyTimelineStoreFactory)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(O2))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),R2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-history-sidebar-skeleton-loading"]],standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:145,vars:0,consts:[[1,"history-sidebar-skeleton-loading","history-timeline-viewport"],[1,""],[1,"d-flex","entry-grey","flex-row","history-timeline-entry","m-2"],[1,"history-timeline-entry-icon"],[1,"rounded-square","icon-square","box-loading"],[1,"d-flex","justify-content-center","align-items-center","h-100","history-timeline-image"],[1,"flex-grow-1"],[1,"card"],[1,"card-body","p-1","pr-2","pl-2"],[1,"card-title","text-break","history-timeline-entry-title","pb-2"],["mode","list",1,"field","field-mode-list","field-type-varchar"],[1,"dynamic-field","dynamic-field-mode-list","dynamic-field-type-varchar"],[1,"box-loading","medium-size-text-skeleton","large-length-text-skeleton","rounded","skeleton-field-content"],[1,"card-text","history-timeline-entry-user","pb-2","text-uppercase"],[1,"text-break"],[1,"box-loading","small-size-text-skeleton","small-length-text-skeleton","rounded","skeleton-field-content"],[1,"card-text","text-break","history-timeline-entry-date","pb-1"],[1,"font-italic"],["mode","list",1,"field","field-mode-list","field-type-datetime"],[1,"dynamic-field","dynamic-field-mode-list","dynamic-field-type-datetime"],[1,"box-loading","small-size-text-skeleton","medium-length-text-skeleton","rounded","skeleton-field-content"],[1,"card-title","text-break","history-timeline-entry-title","pb-2","box-loading"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),e.\u0275\u0275element(5,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",6)(7,"div",7)(8,"div",8)(9,"p",9)(10,"a",1)(11,"div",10)(12,"div",11),e.\u0275\u0275element(13,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(14,"div",13)(15,"small",14)(16,"div",10)(17,"div",11),e.\u0275\u0275element(18,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(19,"div",16)(20,"small",17)(21,"div",18)(22,"div",19)(23,"div",20),e.\u0275\u0275element(24,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()(),e.\u0275\u0275elementStart(25,"div",1)(26,"div",2)(27,"div",3)(28,"div",4),e.\u0275\u0275element(29,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(30,"div",6)(31,"div",7)(32,"div",8)(33,"p",21)(34,"a",1)(35,"span",10)(36,"div",11),e.\u0275\u0275element(37,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(38,"div",13)(39,"small",14)(40,"div",10)(41,"div",11),e.\u0275\u0275element(42,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(43,"div",16)(44,"small",17)(45,"span",18)(46,"div",19)(47,"div",20),e.\u0275\u0275element(48,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()(),e.\u0275\u0275elementStart(49,"div",1)(50,"div",2)(51,"div",3)(52,"div",4),e.\u0275\u0275element(53,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(54,"div",6)(55,"div",7)(56,"div",8)(57,"p",9)(58,"a",1)(59,"div",10)(60,"div",11),e.\u0275\u0275element(61,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(62,"div",13)(63,"small",14)(64,"div",10)(65,"div",11),e.\u0275\u0275element(66,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(67,"div",16)(68,"small",17)(69,"div",18)(70,"div",19)(71,"div",20),e.\u0275\u0275element(72,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()(),e.\u0275\u0275elementStart(73,"div",1)(74,"div",2)(75,"div",3)(76,"div",4),e.\u0275\u0275element(77,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(78,"div",6)(79,"div",7)(80,"div",8)(81,"p",9)(82,"a",1)(83,"div",10)(84,"div",11),e.\u0275\u0275element(85,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(86,"div",13)(87,"small",14)(88,"div",10)(89,"div",11),e.\u0275\u0275element(90,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(91,"div",16)(92,"small",17)(93,"div",18)(94,"div",19)(95,"div",20),e.\u0275\u0275element(96,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()(),e.\u0275\u0275elementStart(97,"div",1)(98,"div",2)(99,"div",3)(100,"div",4),e.\u0275\u0275element(101,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(102,"div",6)(103,"div",7)(104,"div",8)(105,"p",9)(106,"a",1)(107,"div",10)(108,"div",11),e.\u0275\u0275element(109,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(110,"div",13)(111,"small",14)(112,"div",10)(113,"div",11),e.\u0275\u0275element(114,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(115,"div",16)(116,"small",17)(117,"div",18)(118,"div",19)(119,"div",20),e.\u0275\u0275element(120,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()(),e.\u0275\u0275elementStart(121,"div",1)(122,"div",2)(123,"div",3)(124,"div",4),e.\u0275\u0275element(125,"div",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(126,"div",6)(127,"div",7)(128,"div",8)(129,"p",9)(130,"a",1)(131,"div",10)(132,"div",11),e.\u0275\u0275element(133,"div",12),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(134,"div",13)(135,"small",14)(136,"div",10)(137,"div",11),e.\u0275\u0275element(138,"div",15),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(139,"div",16)(140,"small",17)(141,"div",18)(142,"div",19)(143,"div",20),e.\u0275\u0275element(144,"span",1),e.\u0275\u0275elementEnd()()()()()()()()()()())},dependencies:[Vl],encapsulation:2})}return r})();const gL=r=>[r];function vL(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",7),e.\u0275\u0275element(1,"scrm-history-sidebar-skeleton-loading"),e.\u0275\u0275elementEnd())}function VF(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",8),e.\u0275\u0275element(1,"scrm-loading-spinner",9),e.\u0275\u0275elementEnd()),2&r&&(e.\u0275\u0275advance(),e.\u0275\u0275property("overlay",!0))}function L2(r,v){1&r&&e.\u0275\u0275element(0,"scrm-chart-message-area",14)}function a3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a",32),e.\u0275\u0275element(1,"scrm-field",29),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("routerLink",n.redirectLink(t.record.module,t.record.id)),e.\u0275\u0275advance(),e.\u0275\u0275property("type",t.title.type)("field",t.title)("record",t.record)}}function _L(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"a"),e.\u0275\u0275element(1,"scrm-field",29),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("type",t.title.type)("field",t.title)("record",t.record)}}function yL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",33)(1,"small",28),e.\u0275\u0275element(2,"scrm-field",34),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275property("type",t.description.type)("field",t.description)("record",t.record)}}function iP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div")(1,"div",16)(2,"div",17)(3,"div",18),e.\u0275\u0275element(4,"scrm-image",19),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(5,"div",20)(6,"div",21)(7,"div",22)(8,"p",23),e.\u0275\u0275template(9,a3,2,4,"a",24)(10,_L,2,3,"a",25),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(11,yL,3,3,"div",26),e.\u0275\u0275elementStart(12,"div",27)(13,"small",28),e.\u0275\u0275element(14,"scrm-field",29),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(15,"div",30)(16,"small",31),e.\u0275\u0275element(17,"scrm-field",29),e.\u0275\u0275elementEnd()()()()()()),2&r){const t=e.\u0275\u0275nextContext().$implicit;e.\u0275\u0275classMapInterpolate1("d-flex flex-row m-2 history-timeline-entry entry-",t.color,""),e.\u0275\u0275advance(4),e.\u0275\u0275property("image",t.icon),e.\u0275\u0275advance(5),e.\u0275\u0275property("ngIf","audit"!==t.record.module),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","audit"===t.record.module),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.description),e.\u0275\u0275advance(3),e.\u0275\u0275property("type",t.user.type)("field",t.user)("record",t.record),e.\u0275\u0275advance(3),e.\u0275\u0275property("type",t.date.type)("field",t.date)("record",t.record)}}function rP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,iP,18,13,"div",15),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.length>0)}}function oP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",35),e.\u0275\u0275element(1,"scrm-button",36),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.getLoadMoreButton())}}function bL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",10),e.\u0275\u0275template(1,L2,1,0,"scrm-chart-message-area",11)(2,rP,2,1,"div",12)(3,oP,2,1,"div",13),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(4,gL,t.length<=0?"history-timeline-viewport-no-data":"history-timeline-viewport")),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(null!=n.adapter&&n.adapter.initializing())&&!(null!=n.adapter&&n.adapter.loading())&&t.length<=0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.adapter.initializing()&&!n.adapter.allLoaded())}}function Jb(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2)(1,"div",3),e.\u0275\u0275template(2,vL,2,0,"div",4)(3,VF,2,1,"div",5)(4,bL,4,6,"div",6),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",(null==t.adapter?null:t.adapter.initializing())||(null==t.adapter?null:t.adapter.firstLoad())&&(null==t.adapter?null:t.adapter.loading())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(null!=t.adapter&&t.adapter.firstLoad())&&(null==t.adapter?null:t.adapter.loading())),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!(null!=t.adapter&&t.adapter.firstLoad()&&null!=t.adapter&&t.adapter.loading()))}}let KI=(()=>{class r extends v0{constructor(t,n,o){super(),this.historyTimelineAdapterFactory=t,this.languageStore=n,this.navigation=o,this.initialLoad=(0,e.signal)(!1),this.subscription=new i.Subscription}ngOnInit(){this.adapter=this.historyTimelineAdapterFactory.create(),this.adapter.init(this.context)}ngAfterViewInit(){const t=[];t.push(this.config.reload$),t.push(this.config.subpanelReload$);const n=["history","activities"],f=t[0].pipe((0,i.combineLatestWith)(...t),(0,M.map)(([D,j={}])=>D||!!j&&n.some(fe=>!!j[fe]))).pipe((0,M.debounce)(()=>(0,i.timer)(400)));this.subscription.add(f.subscribe(D=>{D&&this.adapter.fetchTimelineEntries(!0)}))}ngOnDestroy(){this.subscription.unsubscribe()}getHeaderLabel(){return this.languageStore.getFieldLabel("LBL_QUICK_HISTORY")}getLoadMoreButton(){return{klass:"load-more-button btn btn-link btn-sm",labelKey:"LBL_LOAD_MORE",onClick:()=>{this.adapter.fetchTimelineEntries(!1)}}}redirectLink(t,n){if("audit"!==t)return this.navigation.getRecordRouterLink(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(N2),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Oc))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-history-timeline-widget"]],features:[e.\u0275\u0275ProvidersFeature([F2]),e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:4,consts:[[3,"title"],["widget-body","",4,"ngIf"],["widget-body",""],[1,"widget-background","history-timeline","p-2","pt-0"],["class","record-thread-loading",4,"ngIf"],["class","d-flex record-thread-loading justify-content-center",4,"ngIf"],["class","history-timeline-viewport",3,"ngClass",4,"ngIf"],[1,"record-thread-loading"],[1,"d-flex","record-thread-loading","justify-content-center"],[3,"overlay"],[1,"history-timeline-viewport",3,"ngClass"],["labelKey","LBL_NO_DATA",4,"ngIf"],[4,"ngFor","ngForOf"],["class","record-thread-load-more d-flex justify-content-center flex-grow-1",4,"ngIf"],["labelKey","LBL_NO_DATA"],[3,"class",4,"ngIf"],[1,"history-timeline-entry-icon"],[1,"rounded-square","icon-square"],[1,"d-flex","justify-content-center","align-items-center","h-100","history-timeline-image"],[3,"image"],[1,"flex-grow-1"],[1,"card"],[1,"card-body","p-1","pr-2","pl-2"],[1,"card-title","text-break","history-timeline-entry-title"],[3,"routerLink",4,"ngIf"],[4,"ngIf"],["class","card-text history-timeline-entry-description",4,"ngIf"],[1,"card-text","history-timeline-entry-user","text-uppercase"],[1,"text-break"],["mode","list",3,"type","field","record"],[1,"card-text","text-break","history-timeline-entry-date"],[1,"font-italic"],[3,"routerLink"],[1,"card-text","history-timeline-entry-description"],["mode","detail",3,"type","field","record"],[1,"record-thread-load-more","d-flex","justify-content-center","flex-grow-1"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-widget-panel",0),e.\u0275\u0275template(1,Jb,5,3,"div",1),e.\u0275\u0275pipe(2,"async"),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275property("title",o.getHeaderLabel()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(2,2,null==o.adapter?null:o.adapter.dataStream$)))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,Bl,Dm,f0,af,mm,Wo.RouterLink,xc,R2,ve.AsyncPipe],encapsulation:2})}return r})(),qI=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ai.E9,Vl,pa,Gp,jf,Ea,Xg,Wo.RouterModule,Oa,R2]})}return r})();function jF(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",3),e.\u0275\u0275element(2,"scrm-label",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd())}function CL(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-thread",5),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.recordThreadConfig)}}let UF=(()=>{class r extends v0{constructor(t,n){super(),this.language=t,this.sytemConfig=n,this.panelMode="none",this.subs=[]}ngOnInit(){this.options=(this.config.options||{}).recordThread||null,this.options&&(this.initPanelMode(),this.initFilters$(),this.initPresetFields$(),this.context$&&this.context$.subscribe()&&this.subs.push(this.context$.subscribe(n=>{this.context=n})),this.recordThreadConfig=this.getConfig())}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getHeaderLabel(){return this.getLabel(this.config.labelKey)||""}getLabel(t){return this.language.getFieldLabel(t,(this.context||{}).module||"")}getConfig(){const t={filters$:this.filters$,presetFields$:this.presetFields$,module:this.options.module,klass:this.options.class||"",maxListHeight:this.options.maxListHeight??350,direction:this.options.direction||"asc",create:!!this?.options?.create,createConfig:{},itemConfig:{collapsible:this.options.item.collapsible||!1,collapseLimit:this.options.item.collapseLimit||null,klass:this.options.item.itemClass||"",dynamicClass:this.options.item.dynamicClass||[],metadata:{}},listActions:this?.options?.listActions??null,collapseListActions:this?.options?.collapseListActions??!1,listActionsClass:this?.options?.listActionsClass??"",listActionsButtonClass:this?.options?.listActionsButtonClass??"",listActionsButtonGroupClass:this?.options?.listActionsButtonGroupClass??""};return this.setupItemMetadata(t.itemConfig.metadata,this.options.item.layout),(0,wt.isEmpty)(this.options?.create??null)||(t.createConfig={collapsible:!1,metadata:{}},this.setupItemMetadata(t.createConfig.metadata,this.options?.create?.layout??{})),t}setupItemMetadata(t,n){n&&n.header&&(t.headerLayout=dr(n.header)),n&&n.body&&(t.bodyLayout=dr(n.body)),n&&n.actions&&(t.actions=dr(n.actions)),n&&n.fields&&(t.fields=dr(n.fields)),null!==(n?.collapseActions??null)&&(t.collapseActions=n?.collapseActions)}initPanelMode(){const n=this.sytemConfig.getConfigValue("ui")?.widget?.allowCollapse??null,o=this?.config?.allowCollapse??null;let f="none";null!==n&&(cl(n)?f="collapsible":sf(n)&&(f="none")),null!==o&&(cl(o)?f="collapsible":sf(o)&&(f="none")),this.panelMode=f}initFilters$(){if(!this.options||!this.options.filters||!this.context$)return;const t=this.options.filters.parentFilters||{};let n=(0,i.of)({}).pipe((0,M.shareReplay)());Object.keys(t).length>0&&(n=this.context$.pipe((0,M.filter)(o=>{const f=o&&o.record||{};return!(!f.attributes||!Object.keys(f.attributes).length)}))),this.filters$=n.pipe((0,M.map)(o=>{const f={filters:{}};return this.initParentFilters(o,f),f.filters={...f.filters,...this.options.filters.static||{}},this.options.filters.orderBy&&(f.orderBy=this.options.filters.orderBy),this.options.filters.sortOrder&&(f.sortOrder=this.options.filters.sortOrder),f}),(0,M.distinctUntilChanged)())}initPresetFields$(){!this.options||!this.options.create||!this.options.create.presetFields||!this.context$||(this.presetFields$=this.context$.pipe((0,M.map)(t=>({...this.initParentValues(t),...this.options.create.presetFields.static||{}})),(0,M.distinctUntilChanged)()))}initParentFilters(t,n){const o=this.options.filters.parentFilters||{};!t||!t.record||!o||Object.keys(o).forEach(f=>{const j=t.record.attributes[f]||"";j&&(n.filters[o[f]]={field:o,operator:"=",values:[j]})})}initParentValues(t){const n=this.options.create.presetFields.parentValues||{};if(!t||!t.record||!n)return;const o={};return Object.keys(n).forEach(f=>{const j=t.record.attributes[f]||"";j&&(o[n[f]]=j)}),o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-thread-sidebar-widget"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:4,vars:4,consts:[[3,"mode","title"],["widget-body","",1,"record-thread-sidebar-widget"],[4,"ngIf"],[1,"p-3","widget-message"],["labelKey","LBL_BAD_CONFIG"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-widget-panel",0)(1,"div",1),e.\u0275\u0275template(2,jF,3,0,"ng-container",2)(3,CL,2,1,"ng-container",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275property("mode",o.panelMode)("title",o.getHeaderLabel()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.options),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.options))},dependencies:[ve.NgIf,f0,Pa,RT],encapsulation:2})}return r})(),sP=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,Gp,Ea,qw,AI]})}return r})(),$F=(()=>{class r extends v0{constructor(t){super(),this.language=t,this.subs=[]}ngOnInit(){this.options=(this.config.options||{}).sidebarStatistic||null,this.context$&&this.subs.push(this.context$.subscribe(n=>{this.context=n}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getHeaderLabel(){return this.getLabel(this.config.labelKey)||""}getLabel(t){return this.language.getFieldLabel(t,(this.context||{}).module||"")}getGridConfig(){return{rowClass:"statistics-sidebar-widget-row",columnClass:"statistics-sidebar-widget-col",layout:this.options,widgetConfig:{reload$:this.config.reload$},queryArgs:{module:this.context.module,context:this.context,params:{}}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-statistics-sidebar-widget"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:3,vars:2,consts:[[3,"title"],["widget-body","",1,"p-3"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-widget-panel",0)(1,"div",1),e.\u0275\u0275element(2,"scrm-grid-widget",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275property("title",o.getHeaderLabel()),e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.getGridConfig()))},dependencies:[f0,Ku],encapsulation:2})}return r})(),DL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,gy,Gp,p0,Ea]})}return r})();class WF extends kp{checkRecordAccess(v,t=[]){const o=(v.record??{}).acls??[];return!(!o||!o.length)&&this.checkAccess(v.action??null,o,t)}}let HF=(()=>{class r extends WF{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){const n=t?.action?.acl??[];return!n.length||this.checkRecordAccess(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),zF=(()=>{class r extends js{constructor(t){super(),this.async=t,t.modes.forEach(n=>this.actions[n][t.key]=t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(HF))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),GF=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt){super(n,o,f,D,j,fe,Ne,vt),this.store=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.language=j,this.selectModalService=fe,this.metadata=Ne,this.appMetadataStore=vt}getActions(t=null){return this.store.metadata$.pipe((0,M.map)(n=>n.lineActions)).pipe((0,i.combineLatestWith)((0,i.of)("list").pipe((0,M.shareReplay)())),(0,M.map)(([n,o])=>this.parseModeActions(n,o,t)))}buildActionData(t,n){return{record:n&&n.record||null,store:this.store,action:t}}getMode(){return"list"}getModuleName(t){return this.store.metadata.module}reload(t,n,o){this.store.load(!1).pipe((0,M.take)(1)).subscribe(),this.store.loadAllStatistics(!1).pipe((0,M.take)(1)).subscribe()}buildActionInput(t,n,o,f=null){const D=this.store.metadata,j=D.collection_list||null,fe=f&&f.module||o;let Ne=D.get_subpanel_data;return j&&j[fe]&&j[fe].get_subpanel_data&&(Ne=j[fe].get_subpanel_data),Ne&&t&&t.params&&t.params.linkFieldMapping&&Object.keys(t.params.linkFieldMapping).some(vt=>{if(Ne.includes(vt))return Ne=t.params.linkFieldMapping[vt],!0}),{action:n,module:o,id:f&&f.record&&f.record.id||"",payload:{baseModule:this.store.parentModule,baseRecordId:this.store.parentId,linkField:Ne,recordModule:fe,relateModule:this.store.metadata.module,relateRecordId:f&&f.record&&f.record.id||""}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(F_),e.\u0275\u0275inject(zF),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),dM=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.actionManager=t,this.asyncActionService=n,this.message=o,this.confirmation=f,this.language=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t){return new GF(t,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.language,this.selectModalService,this.metadata,this.appMetadataStore)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zF),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),KF=(()=>{class r{constructor(t,n,o,f){this.store=t,this.lineActionsAdapterFactory=n,this.preferences=o,this.systemConfigs=f}getTable(){return{showHeader:!1,showFooter:!0,module:this.store.metadata.headerModule,columns:this.getColumns(),lineActions:this.getLineActions(),sort$:this.store.recordList.sort$,maxColumns$:(0,i.of)(5),loading$:this.store.recordList.loading$,dataSource:this.store.recordList,pagination:this.store.recordList,toggleRecordSelection:t=>{this.store.recordList.toggleSelection(t)},updateSorting:(t,n)=>{this.store.recordList.updateSorting(t,n);const o=this.store.parentModule,f=this.store.recordList.getModule();this.preferences.setUi(o,f+"-subpanel-sort",{orderBy:t,sortOrder:n})},maxListHeight:this.preferences.getUserPreference("subpanel_max_height")??this.systemConfigs.getConfigValue("subpanel_max_height"),paginationType:this.preferences.getUserPreference("subpanel_pagination_type")??this.systemConfigs.getConfigValue("subpanel_pagination_type"),loadMore:()=>{const t=this.preferences.getUserPreference("list_max_entries_per_subpanel")??this.systemConfigs.getConfigValue("list_max_entries_per_subpanel"),n=this.store.recordList.getPagination(),f=Number(n.pageSize||0)+Number(t);this.store.recordList.setPageSize(f),this.store.recordList.updatePagination(n.current)},allLoaded:()=>{const t=this.store.recordList.getPagination();return!!t&&(Number(t.pageLast)>=Number(t.total)||Number(t.pageSize)>=Number(t.total))}}}getColumns(){return this.store.metadata$.pipe((0,M.map)(t=>t.columns))}getLineActions(){return this.lineActionsAdapterFactory.create(this.store)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(F_),e.\u0275\u0275inject(dM),e.\u0275\u0275inject($a),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();class Jw extends kp{}let wL=(()=>{class r extends Jw{constructor(t,n){super(),this.moduleNameMapper=t,this.router=n,this.key="create",this.modes=["list"]}run(t){const n=t.module,o=t?.action?.moduleAction??"edit",f=t?.parentId??"",D=t.parentModule??"",j=`/${n}/${o}`,fe={return_module:this.moduleNameMapper.toLegacy(D),return_action:"DetailView",return_id:f,relate_to:D,relate_id:f};this.addAdditionalFields(t,fe),this.addParams(t,fe),this.router.navigate([j],{queryParams:fe}).then()}shouldDisplay(){return!0}addAdditionalFields(t,n){const o=t.store.parentRecord&&t.store.parentRecord.attributes||{};if(!o&&!Object.keys(o).length)return;const f=t.action.additionalFields??{};(Object.keys(f)||[]).forEach(j=>{if(!j||!f[j])return;const Ne=(0,an.A)(o,f[j],null);Al(Ne)||(n[j]=Ne)})}addParams(t,n){const o=t.action.extraParams??{};(Object.keys(o)||[]).forEach(D=>{!D||!o[D]||(n[D]=o[D])})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Wo.Router))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),qF=(()=>{class r extends Jw{constructor(t,n,o){super(),this.modalService=t,this.message=n,this.asyncActionService=o,this.key="select",this.modes=["list"]}shouldDisplay(t){return!0}run(t){this.showSelectModal(t)}showSelectModal(t){const n=this.modalService.open(Py,{size:"xl",scrollable:!0}),o=t.module;n.componentInstance.module=o,n.componentInstance.parentModule=t?.parentModule??"",n.componentInstance.multiSelect=!0,n.componentInstance.multiSelectButtonLabel="LBL_LINK",n.result.then(f=>{if(!f||!f.selection||!f.selection.selected)return;const D=this.getSelectedIds(f);let j=t.subpanelMeta.get_subpanel_data;const fe=t.subpanelMeta?.collection_list??null;fe&&fe?.[o]?.get_subpanel_data&&(j=fe[o].get_subpanel_data),this.runAsyncAction({action:"record-select",module:t.store.parentModule,id:t.store.parentId||"",payload:{baseModule:t.parentModule,baseRecordId:t.parentId,linkField:j,relateModule:o,relateRecordIds:D}},t)})}getSelectedIds(t){const n=[];return Object.keys(t.selection.selected).forEach(o=>{o&&n.push(o)}),n}runAsyncAction(t,n){this.message.removeMessages(),this.asyncActionService.run("record-select",t).pipe((0,M.take)(1)).subscribe(()=>{n.store.load(!1).pipe((0,M.take)(1)).subscribe(),n.store.loadAllStatistics(!1).pipe((0,M.take)(1)).subscribe()})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),k2=(()=>{class r extends Jw{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),QF=(()=>{class r extends Jw{constructor(){super(...arguments),this.key="show-filter",this.modes=["list"]}shouldDisplay(t){return!0}getStatus(t){return this.isAnyFilterApplied(t.store)?"active":""}run(t){t.store.toggleFilter()}isAnyFilterApplied(t){return t.hasActiveFilter()||!t.areAllCurrentCriteriaFilterEmpty()}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),aP=(()=>{class r extends Jw{constructor(){super(...arguments),this.key="clear-filter",this.modes=["list"]}shouldDisplay(t){return this.isAnyFilterApplied(t.store)}run(t){t.store.clearFilter()}isAnyFilterApplied(t){return t.hasActiveFilter()||!t.areAllCurrentCriteriaFilterEmpty()}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),XC=(()=>{class r extends js{constructor(t,n,o,f,D){super(),this.create=t,this.select=n,this.async=o,this.showFilter=f,this.clearFilter=D,o.modes.forEach(j=>this.actions[j][o.key]=o),t.modes.forEach(j=>this.actions[j][t.key]=t),n.modes.forEach(j=>this.actions[j][n.key]=n),f.modes.forEach(j=>this.actions[j][f.key]=f),D.modes.forEach(j=>this.actions[j][D.key]=D)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(wL),e.\u0275\u0275inject(qF),e.\u0275\u0275inject(k2),e.\u0275\u0275inject(QF),e.\u0275\u0275inject(aP))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xL=(()=>{class r{constructor(t,n,o){this.lineActionsAdapterFactory=t,this.preferences=n,this.systemConfigs=o}create(t){return new KF(t,this.lineActionsAdapterFactory,this.preferences,this.systemConfigs)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(dM),e.\u0275\u0275inject($a),e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),SL=(()=>{class r{constructor(t){this.store=t}getConfig(){return{panelMode:"collapsible",collapseOnSearch:!0,savedFilterEdit:!1,module:this.store.recordList.getModule(),displayHeader:!1,filter$:this.store.recordList.openFilter$,savedFilters$:this.store.filterList.records$,searchFields$:this.store.searchMetadata$.pipe((0,M.map)(t=>{if(this.store.metadata.searchdefs)return this.store.metadata.searchdefs;if(!t)return{};let n="advanced";return t?.layout?.advanced||(n="basic"),t?.layout[n]})),listFields:[],onClose:()=>{},onSearch:()=>{this.store.searchFilter()},updateFilter:(t,n=!0)=>{const o={};o[t.key]=t,this.store.setFilters(o,n)},resetFilter:t=>{this.store.resetFilters(t)},addSavedFilter:t=>{},removeSavedFilter:t=>{},setOpenFilter:t=>{}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(F_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),P2=(()=>{class r{create(t){return new SL(t)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),EL=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt){super(o,f,D,j,n,fe,Ne,vt),this.store=t,this.language=n,this.actionManager=o,this.asyncActionService=f,this.message=D,this.confirmation=j,this.selectModalService=fe,this.metadata=Ne,this.appMetadataStore=vt}getActions(t){return this.store.metadata$.pipe((0,i.combineLatestWith)(this.language.vm$,this.store.criteria$),(0,M.map)(([n,o,f])=>n?this.parseModeActions(n.top_buttons,"list"):[]))}buildActionData(t,n){return{subpanelMeta:this.store?.metadata,module:t.module||this.store.metadata?.module,parentModule:this.store.parentModule,parentId:this.store.parentId,store:this.store,action:t}}getMode(){return"list"}getModuleName(t){return this.store?.metadata?.module}reload(t,n,o){this.store.load(!1).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(F_),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(XC),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),TL=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.language=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confimation=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t){return new EL(t,this.language,this.actionManager,this.asyncActionService,this.message,this.confimation,this.selectModalService,this.metadata,this.appMetadataStore)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(XC),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function lP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"span",7),e.\u0275\u0275element(1,"scrm-image",8),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("image",t.store.getIcon())}}function ML(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-list-filter",6),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.filterConfig)}}let YF=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.actionManager=t,this.languages=n,this.tableAdapterFactory=o,this.preferences=f,this.systemConfigs=D,this.filterAdapterFactory=j,this.actionAdapterFactory=fe,this.panelHeaderButtonClass="btn btn-sm btn-outline-light"}ngOnInit(){if(this.buildAdapters(),this.maxColumns$&&(this.tableConfig.maxColumns$=this.maxColumns$),this.store?.metadata?.max_height&&(this.tableConfig.maxListHeight=this.store.metadata.max_height),!this.tableConfig?.maxListHeight){const f=this.systemConfigs.getConfigValue("ui")??{};this.tableConfig.maxListHeight=f.subpanel_max_height}this.tableConfig.paginationType=this?.store?.metadata?.pagination_type??this.tableConfig.paginationType;const t=this.store.parentModule,n=this.store.recordList.getModule(),o=this.preferences.getUi(t,n+"-subpanel-sort");o&&this.store.recordList.updateSorting(o.orderBy,o.sortOrder),this.closeButton={onClick:()=>{this.onClose&&this.onClose()}}}getActionContext(){return{module:this.store?.metadata?.module??""}}buildAdapters(){this.adapter=this.tableAdapterFactory.create(this.store),this.tableConfig=this.adapter.getTable(),this.filterAdapter=this.filterAdapterFactory.create(this.store),this.filterConfig=this.filterAdapter.getConfig(),this.actionsAdapter=this.actionAdapterFactory.create(this.store)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(XC),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(xL),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(P2),e.\u0275\u0275directiveInject(TL))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-subpanel"]],inputs:{store:"store",maxColumns$:"maxColumns$",onClose:"onClose",filterConfig:"filterConfig",panelHeaderButtonClass:"panelHeaderButtonClass"},features:[e.\u0275\u0275ProvidersFeature([KF])],decls:8,vars:11,consts:[["bodyPadding","0",3,"title","mode","close","klass"],["class","subpanel-icon pl-1","panel-icon-area","",4,"ngIf"],["panel-header-button",""],[3,"config","actionContext","actionLimitConfig","buttonClass"],["panel-body",""],[3,"config",4,"ngIf"],[3,"config"],["panel-icon-area","",1,"subpanel-icon","pl-1"],[3,"image"]],template:function(n,o){if(1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"scrm-panel",0),e.\u0275\u0275template(2,lP,2,1,"span",1),e.\u0275\u0275elementStart(3,"span",2),e.\u0275\u0275element(4,"scrm-action-group-menu",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"div",4),e.\u0275\u0275template(6,ML,1,1,"scrm-list-filter",5),e.\u0275\u0275element(7,"scrm-table",6),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()),2&n){let f,D;e.\u0275\u0275advance(),e.\u0275\u0275property("title",o.store.getTitle())("mode",null!==(f=null==o.store?null:o.store.panelCollapseMode())&&void 0!==f?f:"closable")("close",o.closeButton)("klass",null!==(D="subpanel-"+(null==o.store||null==o.store.metadata?null:o.store.metadata.name))&&void 0!==D?D:""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.store.getIcon()),e.\u0275\u0275advance(2),e.\u0275\u0275property("config",o.actionsAdapter)("actionContext",o.getActionContext())("actionLimitConfig","subpanelview_actions_limits")("buttonClass",o.panelHeaderButtonClass),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.store.showFilter()),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.tableConfig)}},dependencies:[ve.NgIf,Bl,wl,HI,I2,Ph],encapsulation:2})}return r})();function IL(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-subpanel",4),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("store",t.store)("panelHeaderButtonClass",t.panelHeaderButtonClass)}}let l3=(()=>{class r extends v0{constructor(t,n){super(),this.language=t,this.subpanelFactory=n,this.panelHeaderButtonClass="btn btn-sm btn-outline-main",this.titleLabelKey="LBL_INSIGHTS",this.titleKey=(0,e.signal)(""),this.widgetCollapseMode=(0,e.signal)("none"),this.loading=!0,this.subs=[]}ngOnInit(){const t=this?.config?.options?.recordTable??null;this.store=this.subpanelFactory.create();const n=this.context.module,o=this.context.id,f=this.context$.pipe((0,M.map)(D=>this.context.record));this.store.init(n,o,t,f),this.store.recordList.setLoading(!0),this.initPanelTitleKey(t),this.initPanelCollapseMode(),this.store.load().pipe((0,M.take)(1)).subscribe()}initPanelTitleKey(t){t.title_key=this?.config?.labelKey??t.title_key,this.titleKey.set(this?.config?.labelKey??this.titleLabelKey)}initPanelCollapseMode(){let t="none";this?.config?.allowCollapse&&(t="collapsible"),this.widgetCollapseMode.set(t),this.store.panelCollapseMode.set(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Gb))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["record-table-widget"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:4,vars:4,consts:[[3,"title","mode","showHeader"],["widget-body",""],[1,"widget-background","record-table-widget","widget-table","minimal-table"],[3,"store","panelHeaderButtonClass",4,"ngIf"],[3,"store","panelHeaderButtonClass"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-widget-panel",0)(1,"div",1)(2,"div",2),e.\u0275\u0275template(3,IL,1,2,"scrm-subpanel",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275property("title",o.titleKey())("mode",o.widgetCollapseMode())("showHeader",!1),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",o.store))},dependencies:[ve.NgIf,f0,YF],encapsulation:2})}return r})(),QI=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ct.NgbModule,Vl,xm,Wo.RouterModule,Fu,x2,A2,hm]})}return r})();const YI=[qI,BF,DL,(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Gp,jf,QI]})}return r})()],fM={"history-timeline":KI,chart:PF,statistics:$F,"record-thread":UF,"record-table":l3};let XF=(()=>{class r extends jd{constructor(){super()}initDefault(){Object.keys(fM).forEach(t=>{this.register("default",t,fM[t])})}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const cP=(r,v,t)=>({config:r,context:v,context$:t});function ZF(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2)(1,"div",3),e.\u0275\u0275element(2,"scrm-label",4),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("labelKey",t.getErrorMessage())}}function ex(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",5),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.componentType)("ndcDynamicInputs",e.\u0275\u0275pureFunction3(2,cP,t.config,t.context,t.context$))}}let XI=(()=>{class r extends v0{constructor(t){super(),this.registry=t}get componentType(){return this.registry.get(this.context.module??"default",this.type)}getErrorMessage(){return this.type&&this.config?this.componentType?"LBL_BAD_CONFIG":"LBL_WIDGET_NOT_FOUND":"LBL_CONFIG_NO_CONFIG"}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(XF))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-sidebar-widget"]],inputs:{type:"type"},features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:2,consts:[["class","d-flex mb-4 mt-4 justify-content-center",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[1,"d-flex","mb-4","mt-4","justify-content-center"],[1,"lead"],[3,"labelKey"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,ZF,3,1,"div",0)(1,ex,1,6,"ndc-dynamic",1),2&n&&(e.\u0275\u0275property("ngIf",!(o.type&&o.config&&o.componentType)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.type&&o.config&&o.componentType))},dependencies:[ve.NgIf,St,Ht,Pa],encapsulation:2})}return r})(),B2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,YI,on,Ea]})}return r})();const JF=r=>({"sub-panel-banner-button-active":r});function AL(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",20),e.\u0275\u0275listener("click",function(){const o=e.\u0275\u0275restoreView(t).$implicit,f=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(f.showSubpanel(f.subpanels[o].metadata.name,f.subpanels[o]))}),e.\u0275\u0275element(1,"scrm-grid-widget",21),e.\u0275\u0275elementEnd()}if(2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(2,JF,!0===n.subpanels[t].show)),e.\u0275\u0275advance(),e.\u0275\u0275property("config",n.getGridConfig(n.subpanels[t]))}}function OL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",18),e.\u0275\u0275template(1,AL,2,4,"div",19),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.headerSubpanels())}}function V2(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-image",22),e.\u0275\u0275elementContainerEnd()),2&r&&(e.\u0275\u0275advance(),e.\u0275\u0275property("image","chevron-down"),e.\u0275\u0275attribute("aria-expanded",!1))}function uP(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-image",22),e.\u0275\u0275elementContainerEnd()),2&r&&(e.\u0275\u0275advance(),e.\u0275\u0275property("image","chevron-up"),e.\u0275\u0275attribute("aria-expanded",!0))}function dP(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",29),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext().$implicit,f=e.\u0275\u0275nextContext(4);return e.\u0275\u0275resetView(f.showSubpanel(f.subpanels[o].metadata.name,f.subpanels[o]))}),e.\u0275\u0275element(2,"scrm-grid-widget",21),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()}if(2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(2,JF,!0===n.subpanels[t].show)),e.\u0275\u0275advance(),e.\u0275\u0275property("config",n.getGridConfig(n.subpanels[t]))}}function FL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"td",28),e.\u0275\u0275template(1,dP,3,4,"ng-container",14),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t)}}function fP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"tr",26),e.\u0275\u0275template(1,FL,2,1,"td",27),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t)}}function u3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",23)(1,"table",24),e.\u0275\u0275template(2,fP,2,1,"tr",25),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.bodySubpanels())}}function d3(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-subpanel",31),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("maxColumns$",o.maxColumns$)("store",t)("filterConfig",o.filterConfig)("onClose",o.getCloseCallBack(n,t))}}function pP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,d3,1,4,"scrm-subpanel",30),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.show)}}function hP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,pP,2,1,"ng-container",14),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",n.subpanels[t])}}function mP(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",2)(1,"div",3,0)(3,"div",4)(4,"div",5)(5,"div",6)(6,"div",7)(7,"a",8),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleSubPanels())}),e.\u0275\u0275element(8,"scrm-label",9),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(9,"div",10),e.\u0275\u0275template(10,OL,2,1,"div",11),e.\u0275\u0275elementStart(11,"div",12)(12,"a",13),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(o.toggleSubPanels())}),e.\u0275\u0275template(13,V2,2,2,"ng-container",14)(14,uP,2,2,"ng-container",14),e.\u0275\u0275elementEnd()()()()(),e.\u0275\u0275elementStart(15,"div",15)(16,"div",16),e.\u0275\u0275template(17,u3,3,1,"ng-template"),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275elementStart(18,"div"),e.\u0275\u0275template(19,hP,2,1,"ng-container",17),e.\u0275\u0275elementEnd()()}if(2&r){let t;const n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("collapsed",n.isCollapsed()),e.\u0275\u0275advance(7),e.\u0275\u0275property("ngIf",n.isCollapsed()),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",n.isCollapsed()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.isCollapsed()),e.\u0275\u0275advance(4),e.\u0275\u0275classMapInterpolate1("sub-panels ",!n.isCollapsed()||null!=(t=n.openSubpanels())&&t.length?"":"pb-1",""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",n.openSubpanels())}}let NL=(()=>{class r{constructor(t,n,o,f,D,j){this.languageStore=t,this.maxColumnCalculator=n,this.localStorage=o,this.preferences=f,this.systemConfigs=D,this.screenSize=j,this.isCollapsed=(0,e.signal)(!0),this.toggleIcon=(0,e.signal)("arrow_down_filled"),this.orderedSubpanels=(0,e.signal)([]),this.headerSubpanels=(0,e.signal)([]),this.bodySubpanels=(0,e.signal)([]),this.openSubpanels=(0,e.signal)([]),this.activeHiddenButtonsCount=(0,e.signal)(0),this.subs=[],this.subpanelButtonLimits={XSmall:2,Small:3,Medium:3,Large:5,XLarge:5},this.subpanelButtonBreakpoint=(0,e.signal)(3)}ngOnInit(){const t=this?.config?.parentModule??"default";this.setCollapsed(cl(this.preferences.getUi(t,"subpanel-container-collapse")??!0));const n=this.systemConfigs.getConfigValue("recordview_subpanel_button_limits")??{};n&&Object.keys(n).length&&(this.subpanelButtonLimits=n),this.openSubpanels.set(this.preferences.getUi(t,"subpanel-container-open-subpanels")??[]),this.subs.push(this.config.subpanels$.subscribe({next:o=>{this.subpanels={...o};const f=Object.values(this.subpanels).filter(D=>void 0!==D?.metadata?.order).sort((D,j)=>(D.metadata.order??0)-(j.metadata.order??0)).map(D=>D.metadata.name);f&&this.orderedSubpanels.set(f),this.subpanels&&Object.keys(this.subpanels).length&&(!this.openSubpanels()||this.openSubpanels().length<1||this.openSubpanels().forEach(D=>{const j=this.subpanels[D];!j||j.show||(j.show=!0,j.load().pipe((0,M.take)(1)).subscribe())}))}})),this.headerSubpanels=(0,e.computed)(()=>this.orderedSubpanels().slice(0,this.subpanelButtonBreakpoint())),this.bodySubpanels=(0,e.computed)(()=>{const o=[...this.orderedSubpanels()];let f=0;const D=[];if(o.forEach(j=>{0===f&&D.push([]),D[D.length-1].push(j),f++,f>=this.subpanelButtonBreakpoint()&&(f=0)}),f<this.subpanelButtonBreakpoint()&&D.length>0){const j=D[D.length-1],fe=this.subpanelButtonBreakpoint()-j.length;for(let Ne=0;Ne<fe;Ne++)j.push("");D[D.length-1]=j}return D}),this.activeHiddenButtonsCount=(0,e.computed)(()=>{const o=new Set(this.openSubpanels()),f=new Set(this.headerSubpanels());return this.bodySubpanels().flat().reduce((D,j)=>{const fe=o.has(j),Ne=f.has(j);return D+(fe&&!Ne?1:0)},0)}),this.subs.push(this.screenSize.screenSize$.subscribe({next:o=>{o&&this.subpanelButtonLimits[o]&&this.subpanelButtonBreakpoint.set(this.subpanelButtonLimits[o])}})),this.maxColumns$=this.getMaxColumns()}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}getMaxColumns(){return this.maxColumnCalculator.getMaxColumns(this.config.sidebarActive$)}toggleSubPanels(){this.setCollapsed(!this.isCollapsed()),this.preferences.setUi(this?.config?.parentModule??"default","subpanel-container-collapse",this.isCollapsed())}showSubpanel(t,n){n.show=!n.show;let o=[...this.openSubpanels()];n.show?(o.includes(t)||o.push(t),n.load().pipe((0,M.take)(1)).subscribe()):o=o.filter(D=>D!=t),this.openSubpanels.set(o),this.preferences.setUi(this?.config?.parentModule??"default","subpanel-container-open-subpanels",this.openSubpanels())}getCloseCallBack(t,n){return()=>this.showSubpanel(t,n)}getGridConfig(t){if(!t.metadata||!t.metadata.subpanelWidget)return{layout:null};const n=t.getWidgetLayout();return n.rows.forEach(o=>{!o.cols||!o.cols.length||o.cols.forEach(f=>{if(!f.statistic)return;const D=t.getStatistic(f.statistic);D&&(f.store=D)})}),{rowClass:"statistics-sidebar-widget-row",columnClass:"statistics-sidebar-widget-col",layout:n,widgetConfig:{},queryArgs:{module:t.metadata.name,context:{module:t.parentModule,id:t.parentId},params:{subpanel:t.metadata.name}}}}setCollapsed(t){this.isCollapsed.set(t),this.setToggleIcon()}setToggleIcon(){this.toggleIcon.set(this.isCollapsed()?"arrow_up_filled":"arrow_down_filled")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(rg),e.\u0275\u0275directiveInject(Zu),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Wd))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-subpanel-container"]],inputs:{config:"config"},features:[e.\u0275\u0275ProvidersFeature([rg])],decls:1,vars:1,consts:[["accordion","ngbAccordion"],["class","card border shadow-sm",4,"ngIf"],[1,"card","border","shadow-sm"],["ngbAccordion","","activeIds","sub-panel-buttons",1,"sub-panel-banner"],["ngbAccordionItem","","id","sub-panel-buttons",1,"card",3,"collapsed"],["ngbAccordionHeader","",1,"card-header"],[1,"d-flex","justify-content-between"],[1,"d-flex","align-items-start","sub-panel-banner-header"],[1,"clickable",3,"click"],["labelKey","LBL_RELATIONSHIPS"],[1,"d-flex","align-items-center","justify-content-end"],["class","row insight-panel",4,"ngIf"],[1,"d-flex","align-items-center","sub-panel-header-toggle"],[1,"clickable","position-relative",3,"click"],[4,"ngIf"],["ngbAccordionCollapse",""],["ngbAccordionBody",""],[4,"ngFor","ngForOf"],[1,"row","insight-panel"],["class","col-auto mr-3 insight-panel-card border-insight",3,"ngClass","click",4,"ngFor","ngForOf"],[1,"col-auto","mr-3","insight-panel-card","border-insight",3,"click","ngClass"],[3,"config"],["aria-controls","collapseShowSubPanels",1,"float-right",3,"image"],["id","collapseShowSubPanels",1,"sub-panel-banner-body","d-flex","align-items-center","justify-content-center","border-bottom","border-top","pt-2","pb-3","ml-2","mr-2","mb-2"],[1,"sub-panel-banner-body-table"],["class","insight-panel sub-panel-banner-body-table-row",4,"ngFor","ngForOf"],[1,"insight-panel","sub-panel-banner-body-table-row"],["class","sub-panel-banner-body-table-col",4,"ngFor","ngForOf"],[1,"sub-panel-banner-body-table-col"],[1,"insight-panel-card","border-insight","pl-2","pr-2",3,"click","ngClass"],["class","sub-panel minimal-table",3,"maxColumns$","store","filterConfig","onClose",4,"ngIf"],[1,"sub-panel","minimal-table",3,"maxColumns$","store","filterConfig","onClose"]],template:function(n,o){if(1&n&&e.\u0275\u0275template(0,mP,20,8,"div",1),2&n){let f;e.\u0275\u0275property("ngIf",null==(f=o.bodySubpanels())?null:f.length)}},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,ct.NgbAccordionDirective,ct.NgbAccordionItem,ct.NgbAccordionHeader,ct.NgbAccordionBody,ct.NgbAccordionCollapse,Bl,YF,Ku,Pa],encapsulation:2})}return r})(),eN=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,ct.NgbModule,Vl,Wo.RouterModule,QI,gy,pa,p0,Ea]})}return r})();function tN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",4),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"uppercase"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,t.appStrings[n.messageLabelKey]||"")," ")}}function RL(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"uppercase"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,n.getLabel(t.value.labelKey)),": ")}}function gP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"uppercase"),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,n.getLabel(t.value.labelKey))," ")}}function LL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",10),e.\u0275\u0275template(1,RL,3,3,"ng-container",3)(2,gP,3,3,"ng-container",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.isValueEmpty(n.statistics[t.key])),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isValueEmpty(n.statistics[t.key]))}}function vP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,LL,3,2,"div",9),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.value.labelKey&&n.getLabel(t.value.labelKey))}}function f3(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-field",13),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).$implicit,n=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("type",n.statistics[t.key].field.type)("field",n.statistics[t.key].field)}}function _P(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",12),e.\u0275\u0275template(1,f3,2,2,"ng-container",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(2).ngIf,o=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.isValueEmpty(n.statistics[t.key])||!0!==t.value.hideValueIfEmpty)}}function yP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,_P,2,1,"div",11),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.statistics[t.key].loading&&n.statistics[t.key].field)}}function nN(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275text(1," - "),e.\u0275\u0275elementContainerEnd())}function ZI(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",14)(1,"div",15)(2,"div",16),e.\u0275\u0275text(3," . "),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(4,nN,2,0,"ng-container",3),e.\u0275\u0275elementEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext().$implicit,o=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",!(t||n.key&&o.statistics[n.key]))}}function bP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",18),e.\u0275\u0275text(1),e.\u0275\u0275pipe(2,"uppercase"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",e.\u0275\u0275pipeBind1(2,1,n.getLabel(t.value.endLabelKey))," ")}}function CP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,bP,3,3,"div",17),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.value.endLabelKey&&n.getLabel(t.value.endLabelKey))}}function kL(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",7),e.\u0275\u0275template(2,vP,2,1,"ng-container",3)(3,yP,2,1,"ng-container",3)(4,ZI,5,1,"div",8),e.\u0275\u0275pipe(5,"async"),e.\u0275\u0275template(6,CP,2,1,"ng-container",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit,n=v.index,o=v.last,f=v.count,D=e.\u0275\u0275nextContext(2).ngIf,j=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275classProp("border-right",f>1&&n%2==0&&!o)("col",1===f)("col-6",f>=2)("mt-3",f>=2&&n>2),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!j.shouldHide(D.statistics[t.key],t.value)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.key&&D.statistics[t.key]&&!j.shouldHide(D.statistics[t.key],t.value)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(5,12,t.value.store.loading$)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!j.shouldHide(D.statistics[t.key],t.value))}}function aE(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",5),e.\u0275\u0275template(2,kL,7,14,"ng-container",6),e.\u0275\u0275pipe(3,"keyvalue"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",e.\u0275\u0275pipeBind1(3,1,t.statistics))}}function PL(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",19)(2,"div",12)(3,"div",15)(4,"div",16),e.\u0275\u0275text(5," . "),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(6,"div",20),e.\u0275\u0275text(7," . "),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(8,"div",19)(9,"div",12)(10,"div",15)(11,"div",16),e.\u0275\u0275text(12," . "),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(13,"div",20),e.\u0275\u0275text(14," . "),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd())}function iN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,tN,3,3,"div",2)(2,aE,4,3,"ng-container",3)(3,PL,15,0,"ng-container",3),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.messageLabelKey),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loading()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading())}}let j2=(()=>{class r extends v0{constructor(t,n){super(),this.language=t,this.factory=n,this.statistics={},this.loading=(0,e.signal)(!0),this.subs=[],this.signal=e.signal}ngOnInit(){if(!this.context||!this.context.module)return void(this.messageLabelKey="LBL_CONFIG_BAD_CONTEXT");if(!this.config)return void(this.messageLabelKey="LBL_CONFIG_NO_CONFIG");if(!this.config.options||!this.config.options.statistics||!this.config.options.statistics.length)return void(this.messageLabelKey="LBL_CONFIG_NO_STATISTICS_KEY");this.context$&&this.subs.push(this.context$.subscribe(f=>{this.context=f}));const t=[],n=[];this.config.options.statistics.forEach(f=>{f.type&&(this.statistics[f.type]={labelKey:f.labelKey||"",endLabelKey:f.endLabelKey||"",hideValueIfEmpty:f.hideValueIfEmpty||!1,type:f.type,store:this.factory.create()},this.statistics[f.type].store.init(this.context.module,{key:f.type,context:{...this.context}}).pipe((0,M.take)(1)).subscribe(),t.push(this.statistics[f.type].store.state$),n.push(this.statistics[f.type].store.loading$))});let o=null;if(t.length<1)o=(0,i.of)([]);else if(1===t.length)o=t[0].pipe((0,M.map)(f=>[f]));else{let D,f=null;[f,...D]=t,o=f.pipe((0,i.combineLatestWith)(D))}this.loading$=n[0].pipe((0,i.combineLatestWith)(...n),(0,M.map)(f=>{if(!f||f.length<1)return this.loading.set(!1),!1;let D=!0;return f.forEach(j=>{D=D&&j}),this.loading.set(D),D})),this.subs.push(this.loading$.subscribe()),this.vm$=o.pipe((0,i.combineLatestWith)(this.language.appStrings$),(0,M.map)(([f,D])=>{const j={};return f.forEach(fe=>{j[fe.query.key]=fe,this.statistics[fe.query.key].labelKey=this.getMetadataEntry(fe,"labelKey"),this.statistics[fe.query.key].endLabelKey=this.getMetadataEntry(fe,"endLabelKey")}),{statistics:j,appStrings:D}})),this.config.reload$&&this.subs.push(this.config.reload$.subscribe(()=>{!1===this.loading()&&(this.loading.set(!0),this.config.options.statistics.forEach(f=>{f.type&&(!this.statistics[f.type]||!this.statistics[f.type].store||this.statistics[f.type].store.load(!1).pipe((0,M.take)(1)).subscribe())}))}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}shouldHide(t,n){return this.hasLoaded(t)&&this.isValueEmpty(t)&&!0===n.hideIfEmpty}hasLoaded(t){return!t.loading}isValueEmpty(t){const n=t?.statistic?.metadata?.emptyValueString??null;if(null!==n)return!0;const o=t?.field?.value??null;return!o&&n===o}getMetadataEntry(t,n){const o=t.statistic.metadata&&t.statistic.metadata[n];return null!==o&&typeof o<"u"?o:this.statistics[t.query.key][n]}getLabel(t){return this.language.getFieldLabel(t,(this.context||{}).module||"")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Hr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-statistics-top-widget"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:2,vars:3,consts:[["class","d-sm-flex justify-content-center widget-bar rounded container-fluid p-0",4,"ngIf"],[1,"d-sm-flex","justify-content-center","widget-bar","rounded","container-fluid","p-0"],["class","p-2 widget-bar-entry-message",4,"ngIf"],[4,"ngIf"],[1,"p-2","widget-bar-entry-message"],[1,"d-flex","h-100","row","justify-content-center","align-items-center","w-100","mt-3","mb-3","mr-0","ml-0"],[4,"ngFor","ngForOf"],[1,"d-flex","h-100","flex-column","justify-content-start","align-items-center","widget-bar-entry"],["class","pl-1 pr-1 widget-bar-entry-loading",4,"ngIf"],["class","pr-1 widget-bar-entry-label",4,"ngIf"],[1,"pr-1","widget-bar-entry-label"],["class","pl-1 pr-1 widget-bar-entry-value",4,"ngIf"],[1,"pl-1","pr-1","widget-bar-entry-value"],["mode","list",3,"type","field"],[1,"pl-1","pr-1","widget-bar-entry-loading"],[1,"pb-2"],[1,"large-size-text-skeleton","small-length-text-skeleton","rounded","box-loading","skeleton-field-content"],["class","pl-1 widget-bar-entry-end-label",4,"ngIf"],[1,"pl-1","widget-bar-entry-end-label"],[1,"d-flex","flex-column","justify-content-center","align-items-baseline","widget-bar-entry","p-2"],[1,"pr-1","widget-bar-entry-label","large-length-text-skeleton","rounded","box-loading","skeleton-field-content"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,iN,4,3,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgForOf,ve.NgIf,Dm,ve.AsyncPipe,ve.UpperCasePipe,ve.KeyValuePipe],encapsulation:2})}return r})(),BL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,gy]})}return r})();const U2=[BL],$2={statistics:j2},pM=(r,v)=>({config:r,context:v});function p3(r,v){if(1&r&&e.\u0275\u0275element(0,"ndc-dynamic",1),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("ndcDynamicComponent",t.componentType)("ndcDynamicInputs",e.\u0275\u0275pureFunction2(2,pM,t.config,t.context))}}let DP=(()=>{class r extends v0{constructor(){super(...arguments),this.map=$2}get componentType(){return this.map[this.type]}ngOnInit(){this.component=this.componentType,this.inputs={config:this.config,context:this.context}}static#e=this.\u0275fac=(()=>{let t;return function(o){return(t||(t=e.\u0275\u0275getInheritedFactory(r)))(o||r)}})();static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-top-widget"]],inputs:{type:"type"},features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,consts:[[3,"ndcDynamicComponent","ndcDynamicInputs",4,"ngIf"],[3,"ndcDynamicComponent","ndcDynamicInputs"]],template:function(n,o){1&n&&e.\u0275\u0275template(0,p3,1,5,"ndc-dynamic",0),2&n&&e.\u0275\u0275property("ngIf",o.type&&o.config)},dependencies:[ve.NgIf,St,Ht],encapsulation:2})}return r})(),wP=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,U2,on]})}return r})(),VL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,on]})}return r})(),jL=(()=>{class r{constructor(t,n){this.el=t,this.appStateStore=n,this.appLoading=!1}ngOnInit(){this.subscription=this.appStateStore.loading$.pipe((0,M.tap)(t=>{this.appLoading=t,this.updateComponent()})).subscribe(),this.updateComponent()}ngOnChanges(t){t.state&&this.updateComponent()}ngOnDestroy(){this.subscription.unsubscribe()}clickEvent(){this.updateComponent()}updateComponent(){const t=this.isLoading();this.setDisabledState(t)}isLoading(){let t=!1;return(!0===this.state||!0===this.appLoading)&&(t=!0),t}setDisabledState(t){this.el.nativeElement.disabled=t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(tl))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:r,selectors:[["","scrm-button-loading",""]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("click",function(){return o.clickEvent()})},inputs:{state:[0,"scrm-button-loading","state"]},features:[e.\u0275\u0275NgOnChangesFeature]})}return r})(),rN=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),xP=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),SP=(()=>{class r extends lu{constructor(t,n,o){super(t,n,o),this.typeFormatter=t,this.logic=n,this.logicDisplay=o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(_s),e.\u0275\u0275directiveInject(Qs),e.\u0275\u0275directiveInject(qo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-email-detail"]],features:[e.\u0275\u0275InheritDefinitionFeature],decls:1,vars:1,template:function(n,o){1&n&&e.\u0275\u0275text(0),2&n&&e.\u0275\u0275textInterpolate1("\n",o.field.value,"\n")},encapsulation:2})}return r})(),UL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),$L=(()=>{class r{constructor(t){this.sanitizer=t}transform(t){return this.sanitizer.sanitize(e.SecurityContext.HTML,t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(L0.up,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"htmlSanitize",type:r,pure:!0})}return r})(),oN=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})();class WL{}let EP=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.router=t,this.authService=n,this.asyncActionService=o,this.appState=f,this.routeConverter=D,this.language=j,this.notificationStore=fe}canActivate(t,n){return this.authorizeUser(t,n)}authorizeUser(t,n){return(0,i.forkJoin)([this.authService.authorizeUserSession(t,n),this.authorizeUserACL(t)]).pipe((0,M.map)(([o,f])=>o instanceof Wo.UrlTree?o:f instanceof Wo.UrlTree?f:!(!o||!f)&&(!(!this.appState.getLoginWizardComplete()&&"/users/Wizard"!==n.url)||this.router.parseUrl("/users/Wizard"))))}authorizeUserACL(t){const n=this.routeConverter.parseRouteURL(t.url),o=this.appState.getRouteUrl()??"";if(!n.module||"home"===n.module)return(0,i.of)(!0);const D=this.router.parseUrl(""),j="user-acl";return this.asyncActionService.run(j,{action:j,module:n.module,payload:{routeAction:n.action,record:n.record,routeURL:o,queryParams:t?.queryParams??[]}}).pipe((0,M.take)(1),(0,M.map)(Ne=>{if(Ne.data&&!0===Ne.data.result)return!0;if(Ud(o))return D;const vt=this.router.parseUrl(this.router.url);return!!this.routeConverter.isClassicViewRoute(vt)&&vt}),(0,M.catchError)(()=>(0,i.of)(D)))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Xs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(hs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),HL=(()=>{class r{intercept(t,n){return n.handle(t).pipe((0,M.catchError)(o=>(0,i.throwError)(o)))}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),sN=(()=>{class r{constructor(t,n,o,f,D,j){this.systemConfigStore=t,this.authService=n,this.router=o,this.routeConverter=f,this.asyncActionService=D,this.message=j}canActivate(t){return this.canActivateWebInstallation(t)}canActivateWebInstallation(t){const n=this.systemConfigStore.getHomePage(),o=this.router.parseUrl(n);return this.authService.fetchSessionStatus().pipe((0,M.take)(1),(0,M.map)(f=>f&&!0===f.appStatus.locked&&!0===f.appStatus.installed?(window.location.href="./install.php",!(!f||!1!==f.active)&&o):(f&&!0===f.active&&this.authService.logout("",!1),!0)),(0,M.catchError)(()=>(0,i.of)(!0)))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(Xs),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),h3=(()=>{class r{constructor(t,n,o,f){this.router=t,this.authService=n,this.systemConfigStore=o,this.appStateStore=f}canActivate(){const t=this.systemConfigStore.getHomePage(),n=this.router.parseUrl(t);return this.authService.isUserLoggedIn.value?n:this.authService.fetchSessionStatus().pipe((0,M.take)(1),(0,M.map)(o=>o&&!1===o.appStatus.installed?this.router.parseUrl("install"):!o||!0!==o.active||(this.authService.setCurrentUser(o),n)),(0,M.catchError)(()=>(0,i.of)(!0)))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),zL=(()=>{class r{constructor(t){this.authService=t}canActivate(t,n){return this.authService.authorizeUserSession(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ka))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),aN=(()=>{class r{constructor(t){this.systemConfigStore=t}load(t){const n=this.systemConfigStore.getConfigValue("extensions"),o={};return Object.keys(n).forEach(f=>{if(!n[f])return;const D=n[f];!D.remoteEntry||!D.remoteName||!D.enabled||sf(D.enabled)||(o[f]=this.loadExtension(D,t))}),Object.keys(o).length<1?(0,i.of)({}):(0,i.forkJoin)(o)}loadExtension(t,n){return this.loadModule(()=>function Wm(r,v){return Uv.apply(this,arguments)}({type:"module",remoteEntry:t.remoteEntry,exposedModule:"./Module"}).then(f=>f.ExtensionModule),n)}isPromise(t){return!!t&&"function"==typeof t.then}wrapIntoObservable(t){return(0,i.isObservable)(t)?t:this.isPromise(t)?(0,i.from)(Promise.resolve(t)):(0,i.of)(t)}loadModule(t,n){return this.wrapIntoObservable(t()).pipe((0,M.map)(o=>(0,e.createNgModule)(o,n)))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),lN=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){this.systemConfigStore=t,this.languageStore=n,this.navigationStore=o,this.userPreferenceStore=f,this.themeImagesStore=D,this.appState=j,this.moduleNameMapper=fe,this.messageService=Ne,this.appMetadata=vt,this.auth=ln}resolve(t){const n=this.calculateActiveModule(t);return this.appMetadata.load(n).pipe((0,M.tap)(()=>{this.auth.isLoggedIn()&&setTimeout(()=>{this.appMetadata.loadModuleMetadata(n).pipe((0,M.take)(1)).subscribe()},0)}))}sequentialLoad(t){const n={};if(this.isToLoadNavigation(t)&&(n.navigation=this.navigationStore.load()),this.isToLoadConfigs(t)){let f=this.systemConfigStore.load();if(this.isToLoadLanguageStrings(t)){const D=this.getLanguagesToLoad(t);f=f.pipe((0,M.map)(j=>{let fe=j.default_language.value;const Ne=this.languageStore.getCurrentLanguage();return Ne&&(fe=Ne),this.languageStore.load(fe,D)}),(0,M.concatAll)(),(0,M.toArray)())}n.configs=f}return this.isToLoadUserPreferences(t)&&(n.preferences=this.userPreferenceStore.load()),(0,i.forkJoin)(n).pipe((0,M.map)(f=>{let D=null;return this.systemConfigStore.getConfigValue("default_theme")&&(D=this.systemConfigStore.getConfigValue("default_theme")),this.userPreferenceStore.getUserPreference("user_theme")&&(D=this.userPreferenceStore.getUserPreference("user_theme")),this.themeImagesStore.getTheme()&&(D=this.themeImagesStore.getTheme()),null!==D?this.themeImagesStore.load(D):f}),(0,M.concatAll)(),(0,M.toArray)(),(0,M.tap)(()=>this.appState.setLoaded(!0)))}getLanguagesToLoad(t){let n=this.languageStore.getAvailableStringsTypes();return this.isToLoadNavigation(t)?n:t.data&&t.data.load?(Array.isArray(t.data.load.languageStrings)&&(n=t.data.load.languageStrings),n):[]}isToLoadLanguageStrings(t){return!!this.isToLoadNavigation(t)||!(!t.data||!t.data.load)&&(Array.isArray(t.data.load.languageStrings)||!0===t.data.load.languageStrings)}isToLoadConfigs(t){return!t.data||!t.data.load||!1!==t.data.load.configs}isToLoadNavigation(t){return!t.data||!t.data.load||!1!==t.data.load.navigation}isToLoadUserPreferences(t){return!t.data||!t.data.load||!1!==t.data.load.preferences}addMetadataLoadErrorMessage(){let t=this.languageStore.getAppString("LBL_ERROR_FETCHING_METADATA");t||(t="Error occurred while fetching metadata"),this.messageService.addDangerMessage(t)}calculateActiveModule(t){let n=t.params.module;n||(n=t.data.module);const o=t?.url[0]?.path??"";!n&&""!==o&&(n=o);const f=this.getParentModuleMap()[n]||"",D=t.queryParams[f]||"";return D&&(n=this.moduleNameMapper.toFrontend(D)),n}getParentModuleMap(){return{"merge-records":"return_module",import:"import_module"}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject($a),e.\u0275\u0275inject(uh),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(Ka))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),GL=(()=>{class r extends lN{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi){super(t,n,o,f,D,fe,j,vt,Hn,Oi),this.systemConfigStore=t,this.languageStore=n,this.navigationStore=o,this.userPreferenceStore=f,this.themeImagesStore=D,this.moduleNameMapper=j,this.appStateStore=fe,this.metadataStore=Ne,this.messageService=vt,this.routeConverter=ln,this.appMetadata=Hn,this.auth=Oi}resolve(t){let n=t.params.module;return n||(n=t.data.module),super.resolve(t).pipe((0,M.concatMap)(()=>(0,i.forkJoin)([this.metadataStore.load(n,this.metadataStore.getMetadataTypes()),this.metadataStore.getMetadata("saved-search",["recordView"])])),(0,M.map)(o=>({metadata:o[0]??{},savedSearchMeta:o[1]??{}})),(0,M.tap)(()=>{if(n){const D=this.calculateActiveModule(t);this.appStateStore.setModule(D)}const f=this.routeConverter.parseRouteURL(t.url).action??"index";this.appStateStore.setView(f)},()=>{this.addMetadataLoadErrorMessage()}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject($a),e.\u0275\u0275inject(uh),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Xs),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(Ka))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),JI=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.metadata=t,this.globalRecentlyViewedStore=n,this.processService=o,this.moduleNameMapper=f,this.appMetadataStore=D,this.systemConfigs=j,this.appStateStore=fe}onNavigationAdd(t,n){let o="detail";const f=n&&n.data||{};f.mode&&(o=f.mode);const D=n?.params?.record??null;if(D&&"create"!==o){const j=this.buildRecentlyViewed(t,D);this.addRecentlyViewed(t,j)}}buildRecentlyViewed(t,n,o="detailview"){return t=this.moduleNameMapper.toLegacy(t),dr({module:"Tracker",type:"Tracker",attributes:{module_name:t??"",item_id:n??"",action:o??""}})}addRecentlyViewed(t,n){this.saveRecentlyViewed(t,n)}saveRecentlyViewed(t,n){const f={recentlyViewed:n};setTimeout(()=>{this.processService.submit("add-recently-viewed",f).pipe((0,M.take)(1)).subscribe(D=>{const j={id:n.id??"",module:n.module??"",attributes:{...n.attributes??{}}},fe=D?.data?.tracker??null;if(null===fe)return;j.attributes.item_summary=fe.item_summary;const Ne=j?.attributes?.item_id??"",vt=this.metadata.getModuleMeta(t),ln=vt?.recentlyViewed??null;if(ln){let Hn=ln.filter(Oi=>(Oi?.attributes?.item_id??"")!==Ne);Hn.unshift(j),vt.recentlyViewed=Hn}this.globalRecentlyViewedStore.addToState(j),this.metadata.setModuleMetadata(t,vt)})},500)}conditionalGlobalRefresh(t=""){const n=this.systemConfigs.getUi("global_recently_viewed_reload_actions")??null,o=this.getModule();if(t||(t=this.getView()),!n||!o)return;const f=n[o]??n.any??[];f&&f.length&&f.some(j=>"any"===j||j===t)&&this.appMetadataStore.load(this.getModule(),["globalRecentlyViewed"],!1).pipe((0,M.take)(1)).subscribe()}getModule(){return this.appStateStore.getModule()}getView(){return this.appStateStore.getView()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(br),e.\u0275\u0275inject(bf),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),TP=(()=>{class r extends GL{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr,to,Mr){super(t,n,o,D,j,fe,vt,f,ln,Hn,Lr,to),this.systemConfigStore=t,this.languageStore=n,this.navigationStore=o,this.metadataStore=f,this.userPreferenceStore=D,this.themeImagesStore=j,this.moduleNameMapper=fe,this.actionNameMapper=Ne,this.appStateStore=vt,this.messageService=ln,this.routeConverter=Hn,this.router=Oi,this.appMetadata=Lr,this.auth=to,this.recentlyViewed=Mr}resolve(t){let n=t.params.module;return n||(n=t.data.module),super.resolve(t).pipe((0,M.concatMap)(()=>(0,i.forkJoin)([this.metadataStore.load(n,this.metadataStore.getMetadataTypes())])),(0,M.tap)(()=>{this.auth.isLoggedIn()&&setTimeout(()=>{this.recentlyViewed.onNavigationAdd(this.appStateStore.getModule(),t)},800)}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject($a),e.\u0275\u0275inject(uh),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Up),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Xs),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(JI))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),KL=(()=>{class r{constructor(t,n){this.processService=t,this.appStateStore=n,this.processType="recover-password"}run(t,n){const o={username:t,useremail:n};return this.appStateStore.updateLoading("recover-password",!0,!1),this.processService.submit(this.processType,o).pipe((0,M.tap)(()=>this.appStateStore.updateLoading("recover-password",!1,!1)),(0,M.catchError)(f=>{throw this.appStateStore.updateLoading("recover-password",!1,!1),f}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bf),e.\u0275\u0275inject(tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),MP=(()=>{class r{constructor(t,n){this.systemConfig=t,this.docElement=n}setSystemName(t){(!t||t.length<1)&&(t="SuiteCRM"),this.docElement.documentElement.childNodes.item(0).childNodes.forEach(o=>{"TITLE"===o.nodeName&&(o.textContent=t)})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(ve.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),m3=(()=>{class r{constructor(t){this.http=t}getAll(){return this.http.get("users")}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Op.HttpClient))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),wp=(()=>{class r{constructor(t){this.fetchGQL=t}create(){return new RF(this.fetchGQL)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),eA=(()=>{class r{constructor(t){this.fetchGQL=t}create(){return new xo(this.fetchGQL)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(us))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();function W2(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",9)(1,"a",10)(2,"div",11),e.\u0275\u0275element(3,"scrm-image",12)(4,"scrm-label",13),e.\u0275\u0275elementEnd()()()),2&r){const t=v.$implicit,n=v.first,o=e.\u0275\u0275nextContext(3);e.\u0275\u0275classProp("border-top",n),e.\u0275\u0275advance(),e.\u0275\u0275property("queryParams",null==t?null:t.params)("routerLink",t.link)("title",o.language.getFieldLabel(t.descriptionKey,"administration")),e.\u0275\u0275advance(2),e.\u0275\u0275property("image",t.icon),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.titleKey)}}function H2(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,W2,5,7,"div",8),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.content.linkGroup)}}function qL(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",2)(1,"div",3)(2,"h5",4),e.\u0275\u0275element(3,"scrm-label",5),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(4,"div",6),e.\u0275\u0275template(5,H2,2,1,"ng-container",7),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("title",t.language.getFieldLabel(t.content.descriptionLabelKey,"administration")),e.\u0275\u0275advance(),e.\u0275\u0275property("labelKey",t.content.titleLabelKey),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.content.linkGroup)}}let IP=(()=>{class r{constructor(t){this.language=t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-admin-card"]],inputs:{content:"content"},decls:2,vars:1,consts:[[1,"widget-panel","h-100","shadow-sm"],["class","card h-100 panel-card border-0",4,"ngIf"],[1,"card","h-100","panel-card","border-0"],[1,"card-header"],[1,"card-title","admin-card-title","m-0",3,"title"],["module","administration",3,"labelKey"],[1,"card-body","d-flex","flex-column","align-items-start"],[4,"ngIf"],["class","admin-card-link-box border-bottom w-100",3,"border-top",4,"ngFor","ngForOf"],[1,"admin-card-link-box","border-bottom","w-100"],["queryParamsHandling","merge",1,"card-link","admin-card-link",3,"queryParams","routerLink","title"],[1,"d-flex","admin-card-link-wrapper","align-items-center","w-100","p-1"],[1,"admin-card-icon","sicon-2x",3,"image"],["module","administration",1,"admin-card-label","pl-1","flex-grow-1",3,"labelKey"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275template(1,qL,6,3,"div",1),e.\u0275\u0275elementEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.content))},dependencies:[ve.NgForOf,ve.NgIf,Wo.RouterLink,Pa,Bl],encapsulation:2})}return r})(),QL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Wo.RouterModule,Ea,Vl]})}return r})();function g3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3),e.\u0275\u0275element(1,"scrm-admin-card",4),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(),e.\u0275\u0275property("content",t)}}let v3=(()=>{class r{constructor(t){this.adminMetaData=t,this.adminPanelData=[]}ngOnInit(){const t=this.adminMetaData.getAdminPanel();this.setData(t)}setData(t){t.forEach(({icon:n,titleLabelKey:o,descriptionLabelKey:f,linkGroup:D})=>{this.adminPanelData.push({icon:n,titleLabelKey:o,descriptionLabelKey:f,linkGroup:this.setLinkGroups(D)})})}setLinkGroups(t){let n=[],o=Object.keys(t);for(let f=0;f<o.length;f++){let j=Object.values(t[o[f]]);for(let fe=0;fe<j.length;fe++)n.push(j[fe])}return n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(jr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-admin-panel"]],decls:3,vars:1,consts:[[1,"admin-view","full-height-view","d-flex","align-items-center"],[1,"row","flex-grow-1"],["class","col-12 col-sm-6 col-lg-4 col-xl-3 mt-3 mb-3",4,"ngFor","ngForOf"],[1,"col-12","col-sm-6","col-lg-4","col-xl-3","mt-3","mb-3"],[3,"content"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1),e.\u0275\u0275template(2,g3,2,1,"div",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",o.adminPanelData))},dependencies:[ve.NgForOf,IP],encapsulation:2})}return r})(),cN=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,QL]})}return r})();const AP=["dataContainer"];let YL=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.route=t,this.router=n,this.sanitizer=o,this.routeConverter=f,this.auth=D,this.ngZone=j,this.systemConfigs=fe,this.iframe=null}ngOnInit(){this.url=this.route.snapshot.data.legacyUrl}ngAfterViewInit(){this.initIframe()}ngOnDestroy(){this.cleanObservers(),this.iframe=null;const t=this.wrapper;this.wrapper.firstChild&&t.removeChild(t.firstChild),t.innerHTML="<iframe></iframe>",this.wrapper=null}cleanObservers(){this.iframeResizeHandler&&(this.iframeResizeHandler.destroy(),this.iframeResizeHandler=null),this.iframePageChangeHandler&&(this.iframePageChangeHandler.destroy(),this.iframePageChangeHandler=null)}initIframe(){this.wrapper=this.dataContainer.nativeElement,this.wrapper.firstChild&&this.wrapper.removeChild(this.wrapper.firstChild);const t=document.createElement("iframe");t.src=this.url,this.wrapper.appendChild(t),this.iframe=t,this.iframe.style.display="block",this.initObservers()}initObservers(){this.iframePageChangeHandler=this.buildIframePageChangeObserver(),this.iframeResizeHandler=this.buildIframeResizeHandlerHandler(),this.iframePageChangeHandler&&this.iframePageChangeHandler.init()}onPageChange(t){if(!1===this.shouldRedirect(t))return this.iframe.style.display="block",this.cleanObservers(),void this.initObservers();const n=this.routeConverter.toFrontEndRoute(t);"/users/login"!==n?this.ngZone.run(()=>this.router.navigateByUrl(n).then()).then():this.auth.logout("LBL_SESSION_EXPIRED")}onIFrameLoad(){this.iframe.contentWindow.document.body.style.overflow="hidden",this.iframeResizeHandler.init(this.iframe),this.forceCacheRebuildAfterRepairAndRebuild()}forceCacheRebuildAfterRepairAndRebuild(){const n=new URL(this.iframe.contentWindow.location.href),o=new URLSearchParams(n.search);"Administration"===o.get("module")&&"repair"===o.get("action")&&this.auth.fetchSessionStatus().pipe((0,M.take)(1)).subscribe()}onIFrameUnload(){this.iframe.style.display="none",this.iframeResizeHandler.destroy()}buildIframePageChangeObserver(){return new Uf(this.iframe,this.onPageChange.bind(this),this.onIFrameLoad.bind(this),this.onIFrameUnload.bind(this))}buildIframeResizeHandlerHandler(){return new Sy}shouldRedirect(t){if(t&&t.includes("/#/"))return!0;const n=this.routeConverter.parse(t);return!(!n||!n.module||!0===this.routeConverter.matchesActiveRoute(this.route,n))&&(!n.action||this.toExclude(n))}toExclude(t){const n=this.systemConfigs.getConfigValue("classicview_routing_exclusions");if(!n||0===Object.keys(n).length)return!0;if(n.any&&n.any.includes(t.action))return!1;if(!n[t.module])return!0;const o=n[t.module];return!(o&&o.includes(t.action))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Wo.ActivatedRoute),e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(L0.up),e.\u0275\u0275directiveInject(Xs),e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(e.NgZone),e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-classic-view-ui"]],viewQuery:function(n,o){if(1&n&&e.\u0275\u0275viewQuery(AP,7),2&n){let f;e.\u0275\u0275queryRefresh(f=e.\u0275\u0275loadQuery())&&(o.dataContainer=f.first)}},decls:3,vars:0,consts:[["dataContainer",""],[1,"classic-view-container"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",1,0),e.\u0275\u0275element(2,"iframe"),e.\u0275\u0275elementEnd())},encapsulation:2})}return r})(),XL=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),ZL=(()=>{class r extends lN{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr){super(t,n,o,f,D,vt,j,Ne,ln,Hn),this.systemConfigStore=t,this.languageStore=n,this.navigationStore=o,this.userPreferenceStore=f,this.themeImagesStore=D,this.moduleNameMapper=j,this.routeConverter=fe,this.messageService=Ne,this.appStateStore=vt,this.appMetadata=ln,this.auth=Hn,this.recentlyViewed=Oi,this.metadataStore=Lr}resolve(t){const n=this.calculateActiveModule(t);return super.resolve(t).pipe((0,M.concatMap)(()=>(0,i.forkJoin)([this.metadataStore.load(n,this.metadataStore.getMetadataTypes())])),(0,M.map)(()=>this.routeConverter.toLegacy(t.params,t.queryParams)),(0,M.tap)(()=>{if(t.params.module){const D=this.calculateActiveModule(t);this.appStateStore.setModule(D)}const f=this.routeConverter.parseRouteURL(t.url).action??"index";this.appStateStore.setView(f),setTimeout(()=>{this.recentlyViewed.onNavigationAdd(this.appStateStore.getModule(),t)},800)},()=>{this.addMetadataLoadErrorMessage()}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject($a),e.\u0275\u0275inject(uh),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Xs),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(oo),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(JI),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),tA=(()=>{class r extends uf{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr,to,Mr,ss,Rs){super(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,to,Mr,ss,Rs),this.recordFetchGQL=t,this.recordSaveGQL=n,this.appStateStore=o,this.languageStore=f,this.navigationStore=D,this.moduleNavigation=j,this.metadataStore=fe,this.localStorage=Ne,this.message=vt,this.subpanelFactory=ln,this.recordManager=Hn,this.statisticsBatch=Oi,this.auth=Lr,this.recordStoreFactory=to,this.preferences=Mr,this.panelLogicManager=ss,this.recordConvertService=Rs}init(t,n,o="detail",f={}){this.internalState.module=t,this.internalState.recordID=n,this.setMode(o),this.parseParams(f),this.calculateShowWidgets(),this.showTopWidget=!1,this.showBottomWidgets=!1,this.showSubpanels=!1;const j=this.params.isConvert??!1,fe=this.params.originalId??!1,Ne=this.params.convertModule??"";return!this.params.isDuplicate&&!j&&!fe&&this.initRecord(f),j&&fe&&Ne?this.duplicateOnModule():this.load()}save(){return this.appStateStore.updateLoading(`${this.internalState.module}-record-save-new`,!0),this.recordStore.save().pipe((0,M.catchError)(()=>(this.message.addDangerMessageByKey("LBL_ERROR_SAVING"),(0,i.of)({}))),(0,M.finalize)(()=>{this.setMode("detail"),this.appStateStore.updateLoading(`${this.internalState.module}-record-save-new`,!1)}))}initRecord(t={}){const n=this.auth.getCurrentUser(),o={id:"",type:"",module:this.internalState.module,attributes:{assigned_user_id:n.id,assigned_user_name:{id:n.id,user_name:n.userName},relate_to:t?.return_relationship,relate_id:t?.parent_id}};this.recordManager.injectParamFields(t,o,this.getVardefs()),this.recordStore.init(o,!0)}load(){return this.params.isDuplicate&&this.params.originalId?(this.updateState({...this.internalState,loading:!0}),this.recordStore.retrieveRecord(this.internalState.module,this.params.originalId,!1).pipe((0,M.tap)(t=>{t.id="",t.attributes.id="",t.attributes.date_entered="",this.recordManager.injectParamFields(this.params,t,this.getVardefs()),this.recordStore.setRecord(t),this.updateState({...this.internalState,module:t.module,loading:!1})}))):(0,i.of)(this.recordStore.getBaseRecord()).pipe((0,M.shareReplay)())}duplicateOnModule(){this.initRecord();const t=this.getBaseRecord(),n=this.metadataStore.getModuleMeta(this.params.convertModule),o=this.recordConvertService.getViewFieldsObservable(n);return this.recordStoreFactory.create(o).retrieveRecord(this.params.convertModule,this.params.originalId,!1).pipe((0,M.map)(j=>this.recordConvertService.duplicateOnModule(j,t,this.getVardefs(),n)),(0,M.tap)(j=>{this.recordStore.setRecord(j),this.updateState({...this.internalState,module:this.internalState.module,loading:!1})}))}calculateShowWidgets(){this.showSidebarWidgets=!1,this.widgets=!1}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(pr),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Gb),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(N_),e.\u0275\u0275inject(Ka),e.\u0275\u0275inject(Os),e.\u0275\u0275inject($a),e.\u0275\u0275inject(R_),e.\u0275\u0275inject(kC))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();class e1 extends kp{checkRecordAccess(v,t=[]){const o=v.store.recordStore.getBaseRecord().acls??[];return!(!o||!o.length)&&this.checkAccess(v.action??null,o,t)}navigateBack(v,t,n,o,f){let D=v.getReturnModule(t),j=v.getReturnAction(t),fe=v.getReturnId(t);n!==fe&&(D===o&&"record"===j&&fe!==n||!D||!j||v.navigateBack(f,o,t))}navigateBackToDetail(v,t,n,o,f){const D=v.getRecordRouterLink(f,o);t.navigate([D],{queryParams:{offset:n.getOffsetFromUrl()}})}}let lE=(()=>{class r{constructor(t,n,o,f){this.localStorageService=t,this.preferences=n,this.appStateStore=o,this.route=f,this.nextRecordSubject=new i.BehaviorSubject(!1),this.nextRecord$=this.nextRecordSubject.asObservable(),this.paginationType=Jv.PAGINATION,this.subs=[]}triggerNextRecord(t){this.nextRecordSubject.next(t)}updateRecordListLocalStorage(t,n){const o=this.getModule(),f={pagination:n,recordIds:this.mapRecordIds(t)};this.updatePaginationLocalStorage(n),this.savePreference(o,"current-record-pagination",f)}updatePaginationLocalStorage(t){const o=this.getModule()+"-listview-current-pagination";this.localStorageService.set(o,t)}savePreference(t,n,o){this.preferences.setUi(t,this.getPreferenceKey(n),o)}getPreferenceKey(t){return"recordview-"+t}mapRecordIds(t){return t.map(n=>({id:n.id}))}getModule(){return this.appStateStore.getModule()}getTotalRecords(){const t=this.getModule()+"-listview-current-pagination";return this.localStorageService.get(t)?.total}checkRecordValid(t){const n=this.getRecordPaginationObj(this.getModule()),o=n?.pagination,f=n?.recordIds;if(!o)return!1;const D=this.getPageSize(),j=this.getOffsetFromUrl();if(this.paginationType===Jv.LOAD_MORE&&j>D)return!1;let fe=(j-1)%D;return this.paginationType===Jv.LOAD_MORE&&(fe=j-1),fe>=0&&fe<f.length&&f[fe]?.id===t}getPageSize(){return this.getRecordPaginationObj(this.getModule())?.pagination?.pageSize}getOffsetFromUrl(){return(0,wt.toNumber)(this.route.snapshot.queryParamMap.get("offset"))}getRecordPaginationObj(t){const o=this.localStorageService.get(t+"-recordview-current-record-pagination")[t];if(o&&!_a(o))return o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Zu),e.\u0275\u0275inject($a),e.\u0275\u0275inject(tl),e.\u0275\u0275inject(Wo.ActivatedRoute))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),uN=(()=>{class r extends e1{constructor(t,n,o,f){super(),this.modalService=t,this.navigation=n,this.router=o,this.recordPaginationService=f,this.key="cancel",this.modes=["edit","detail"]}run(t){t.store.recordStore.isDirty()?this.showConfirmationModal(t):this.cancel(t)}shouldDisplay(){return!0}cancel(t){const n=t.store.params,o=t.store.getModuleName(),f=t.store.getRecordId(),D=t.store.getBaseRecord();this.router.url.includes("edit")?this.navigateBackToDetail(this.navigation,this.router,this.recordPaginationService,f,o):this.navigateBack(this.navigation,n,f,o,D),t.store.recordStore.resetStaging(),t.store.setMode("detail")}showConfirmationModal(t){const n=this.modalService.open(Ye);n.componentInstance.textKey="WARN_UNSAVED_CHANGES",n.componentInstance.buttons=[{labelKey:"LBL_CANCEL",klass:["btn-secondary"],onClick:o=>o.dismiss()},{labelKey:"LBL_PROCEED",klass:["btn-main"],onClick:o=>{this.cancel(t),o.close()}}]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(lE))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),JL=(()=>{class r extends e1{constructor(t,n,o,f,D,j){super(),this.router=t,this.message=n,this.navigation=o,this.notificationStore=f,this.recentlyViewedService=D,this.recordPaginationService=j,this.key="save",this.modes=["edit"]}run(t){Object.keys(t.store.recordStore.getStaging().fields).some(o=>t.store.recordStore.getStaging().fields[o]?.loading()??!1)?this.message.addWarningMessageByKey("LBL_LOADING_IN_PROGRESS"):t.store.recordStore.validate().pipe((0,M.take)(1)).subscribe(o=>{o?t.store.save().pipe((0,M.take)(1)).subscribe(f=>{const D=t.store.params,j=t.store.getModuleName(),fe=f.id;this.notificationStore.conditionalNotificationRefresh("edit");const Ne=this.recentlyViewedService.buildRecentlyViewed(j,fe);this.recentlyViewedService.addRecentlyViewed(j,Ne),this.router.url.includes("edit")?this.navigateBackToDetail(this.navigation,this.router,this.recordPaginationService,fe,j):this.navigateBack(this.navigation,D,fe,j,f)}):this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(hs),e.\u0275\u0275inject(JI),e.\u0275\u0275inject(lE))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),dN=(()=>{class r extends e1{constructor(){super(),this.key="toggle-widgets",this.modes=["detail","edit"]}run(t){t.store.showSidebarWidgets=!t.store.showSidebarWidgets}shouldDisplay(t){return t.store.widgets}getStatus(t){return t.store.showSidebarWidgets?"active":""}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),nA=(()=>{class r extends e1{constructor(){super(),this.key="edit",this.modes=["detail"]}run(t){t.store.setMode("edit")}shouldDisplay(t){return this.checkRecordAccess(t,["edit"])}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),hM=(()=>{class r extends e1{constructor(t,n){super(),this.moduleNameMapper=t,this.router=n,this.key="create",this.modes=["detail"]}run(t){const n=t.store,o=n.getBaseRecord(),f="/"+n.vm.appData.module.name+"/edit",D=this.moduleNameMapper.toLegacy(n.vm.appData.module.name);this.router.navigate([f],{queryParams:{return_module:D,return_action:"DetailView",return_record:o&&o.id||""}}).then()}shouldDisplay(t){return this.checkRecordAccess(t,["edit"])}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Wo.Router))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),iA=(()=>{class r extends e1{constructor(t,n){super(),this.message=t,this.navigation=n,this.key="saveNew",this.modes=["create"]}run(t){t.store.recordStore.validate().pipe((0,M.take)(1)).subscribe(n=>{n?t.store.save().pipe((0,M.take)(1)).subscribe(o=>{const f=t.store,D=f.params,j=f.getModuleName();this.navigation.navigateBack(o,j,D)}):this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Oc))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),fN=(()=>{class r extends e1{constructor(t,n,o,f){super(),this.modalService=t,this.router=n,this.moduleNameMapper=o,this.actionNameMapper=f,this.key="cancelCreate",this.modes=["create"]}run(t){t.store.recordStore.isDirty()?this.showConfirmationModal(t):this.cancel(t)}shouldDisplay(){return!0}cancel(t){const n=t.store;let o=n.params.return_action||"",f=n.params.return_id||"",D=n.getModuleName();n.params.return_module&&(D=this.moduleNameMapper.toFrontend(n.params.return_module)),n.params.isConvert&&(D=this.moduleNameMapper.toFrontend(n.params.convertModule),f=n.params.originalId);let j="/"+D;o&&(o=this.actionNameMapper.toFrontend(o),("record"!==o||f)&&(j+="/"+o)),f&&(j+="/"+f),this.router.navigate([j]).then()}showConfirmationModal(t){const n=this.modalService.open(Ye);n.componentInstance.textKey="WARN_UNSAVED_CHANGES",n.componentInstance.buttons=[{labelKey:"LBL_CANCEL",klass:["btn-secondary"],onClick:o=>o.dismiss()},{labelKey:"LBL_OK",klass:["btn-main"],onClick:o=>{this.cancel(t),o.close()}}]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(Ac),e.\u0275\u0275inject(Up))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),pN=(()=>{class r extends e1{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){const n=t?.action?.acl??[];return!n.length||this.checkRecordAccess(t,n)}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),OP=(()=>{class r extends e1{constructor(t,n,o,f,D,j){super(),this.message=t,this.navigation=n,this.notificationStore=o,this.systemConfigStore=f,this.recentlyViewedService=D,this.recordPaginationService=j,this.key="saveContinue",this.modes=["edit"]}run(t){Object.keys(t.store.recordStore.getStaging().fields).some(o=>t.store.recordStore.getStaging().fields[o]?.loading()??!1)?this.message.addWarningMessageByKey("LBL_LOADING_IN_PROGRESS"):t.store.recordStore.validate().pipe((0,M.take)(1)).subscribe(o=>{if(o)return t.store.saveOnEdit().pipe((0,M.take)(1)).subscribe(f=>{const D=t.store.getModuleName(),j=f.id;this.notificationStore.conditionalNotificationRefresh("edit");const fe=this.recentlyViewedService.buildRecentlyViewed(D,j);this.recentlyViewedService.addRecentlyViewed(D,fe)}),void this.recordPaginationService.triggerNextRecord(!0);this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(t){if(!this.systemConfigStore.getConfigValue("enable_record_pagination"))return!1;const o=this.recordPaginationService.getTotalRecords(),f=this.recordPaginationService.getOffsetFromUrl();return!(!o||!f||f>=o||f<=0)&&this.recordPaginationService.checkRecordValid(t.store.getRecordId())}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Oc),e.\u0275\u0275inject(hs),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(JI),e.\u0275\u0275inject(lE))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),ek=(()=>{class r extends js{constructor(t,n,o,f,D,j,fe,Ne,vt){super(),this.edit=t,this.create=n,this.toggleWidgets=o,this.cancel=f,this.cancelCreate=D,this.save=j,this.saveNew=fe,this.saveContinue=Ne,this.async=vt,t.modes.forEach(ln=>this.actions[ln][t.key]=t),n.modes.forEach(ln=>this.actions[ln][n.key]=n),o.modes.forEach(ln=>this.actions[ln][o.key]=o),f.modes.forEach(ln=>this.actions[ln][f.key]=f),j.modes.forEach(ln=>this.actions[ln][j.key]=j),fe.modes.forEach(ln=>this.actions[ln][fe.key]=fe),Ne.modes.forEach(ln=>this.actions[ln][Ne.key]=Ne),D.modes.forEach(ln=>this.actions[ln][D.key]=D),vt.modes.forEach(ln=>this.actions[ln][vt.key]=vt)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(nA),e.\u0275\u0275inject(hM),e.\u0275\u0275inject(dN),e.\u0275\u0275inject(uN),e.\u0275\u0275inject(fN),e.\u0275\u0275inject(JL),e.\u0275\u0275inject(iA),e.\u0275\u0275inject(OP),e.\u0275\u0275inject(pN))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),FP=(()=>{class r extends WL{constructor(t){super(),this.activeFieldsChecker=t,this.key="displayType",this.modes=["edit","detail","list","create","massupdate","filter"]}runAll(t,n){let o=!0;const f=Object.values(t).filter(Ne=>{const vt=Ne.modes??[];return!(!vt.length||!vt.includes(n.store.getMode()))});if(!f||!f.length)return o;let D=n?.action?.display??"show",j="hide";return"hide"===D&&(j="show"),f.some(Ne=>this.run(n,Ne))&&(D=j),o="show"===D,o}run(t,n){const o=t.store.recordStore.getStaging();if(!o||!n)return!0;const f=n.params&&n.params.activeOnFields||{},D=Object.keys(f),j=n.params&&n.params.activeOnAttributes||{},fe=Object.keys(j);return!D.length&&!fe.length||this.activeFieldsChecker.isActive(D,o,f,fe,j)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(ph))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),mM=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){super(f,D,j,fe,o,Ne,n,ln),this.store=t,this.metadata=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne,this.displayTypeLogic=vt,this.appMetadataStore=ln,this.defaultActions={detail:[{key:"toggle-widgets",labelKey:"LBL_INSIGHTS",params:{expanded:!0},acl:[]}],edit:[{key:"toggle-widgets",labelKey:"LBL_INSIGHTS",params:{expanded:!0},acl:[]}]}}getActions(t){return this.metadata.recordViewMetadata$.pipe((0,i.combineLatestWith)(this.store.mode$,this.store.record$,this.store.language$,this.store.widgets$,this.store.panels$),(0,M.map)(([n,o])=>o&&n?this.parseModeActions(n.actions,o,this.store.getViewContext()):[]))}buildActionData(t,n){return{store:this.store,action:t}}buildActionInput(t,n,o,f=null){const D=this.store.getBaseRecord();return this.message.removeMessages(),{action:n,module:D.module,id:D.id,params:t&&t.params||[]}}getMode(){return this.store.getMode()}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.store.load(!1).pipe((0,M.take)(1)).subscribe()}shouldDisplay(t,n){const o=n?.action?.displayLogic??null;let f=!0;return o&&Object.keys(o).length&&(f=this.displayTypeLogic.runAll(o,n)),!!f&&t&&t.shouldDisplay(n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uf),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ek),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(FP),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),rA=(()=>{class r{constructor(t,n,o){this.systemConfigStore=t,this.screenSize=n,this.store=o,this.swapSizes=[],this.subs=[],this.swapSizes=this.systemConfigStore.getUi("widget_swap_screen_sizes"),this.widgetSwap$=this.screenSize.screenSize$.pipe((0,M.map)(f=>{const D=cl(this.swapSizes[f]??!1);return(null===this.widgetSwap&&!0===D||this.widgetSwap!==D&&!0===D)&&(this.store.showSidebarWidgets=!1),this.widgetSwap=D,D}))}destroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Wd),e.\u0275\u0275inject(uf))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),tk=(()=>{class r{constructor(t,n){this.store=t,this.metadata=n,this.config$=this.metadata.recordViewMetadata$.pipe((0,i.combineLatestWith)(this.store.showSidebarWidgets$),(0,M.map)(([o,f])=>(o.sidebarWidgets&&o.sidebarWidgets.length&&o.sidebarWidgets.forEach(D=>{D&&"data-update"===D.refreshOn&&(D.reload$=this.store.record$.pipe((0,M.map)(()=>!0))),D&&(D.subpanelReload$=this.store.subpanelReload$)}),{widgets:o.sidebarWidgets||[],show:f})))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uf),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),z2=(()=>{class r{constructor(t,n,o,f,D){this.store=t,this.metadata=n,this.language=o,this.actions=f,this.logicManager=D,this.fieldSubs=[],this.recordValidationHandler=(0,e.inject)(M_)}getEditAction(){const t={store:this.store};this.actions.run({key:"edit"},this.store.getMode(),t)}getDisplayConfig(){return this.metadata.recordViewMetadata$.pipe((0,i.combineLatestWith)(this.store.mode$),(0,M.map)(([t,n])=>({layout:this.getLayout(t),mode:n,maxColumns:t.templateMeta.maxColumns||2,tabDefs:t.templateMeta.tabDefs})))}getPanels(){return this.store.panels$}getRecord(){return this.store.stagingRecord$.pipe((0,i.combineLatestWith)(this.store.mode$),(0,M.map)(([t,n])=>("edit"===n||"create"===n?this.recordValidationHandler.initValidators(t):this.recordValidationHandler.resetValidators(t),t.formGroup&&t.formGroup.enable(),t)))}getLayout(t){let n="panels";return t.templateMeta.useTabs&&(n="tabs"),n}clean(){this.fieldSubs.forEach(t=>t.unsubscribe())}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uf),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ek),e.\u0275\u0275inject(R_))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),oA=(()=>{class r{constructor(t,n){this.store=t,this.metadata=n,this.config$=this.metadata.recordViewMetadata$.pipe((0,i.combineLatestWith)(this.store.showTopWidget$),(0,M.map)(([o,f])=>(o.topWidget&&"data-update"===o.topWidget.refreshOn&&(o.topWidget.reload$=this.store.record$.pipe((0,M.map)(()=>!0))),{widget:o.topWidget,show:f})))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uf),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),hN=(()=>{class r{constructor(t,n){this.store=t,this.metadata=n,this.config$=this.metadata.recordViewMetadata$.pipe((0,i.combineLatestWith)(this.store.showBottomWidgets$),(0,M.map)(([o,f])=>(o.bottomWidgets&&o.bottomWidgets.length&&o.bottomWidgets.forEach(D=>{D&&"data-update"===D.refreshOn&&(D.reload$=this.store.record$.pipe((0,M.map)(()=>!0))),D&&(D.subpanelReload$=this.store.subpanelReload$)}),{widgets:o.bottomWidgets||[],show:f})))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(uf),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();const sA={paginationEnabled:!1,recordIds:null,pagination:null};let aA=(()=>{class r{constructor(t,n,o,f,D){this.preferences=t,this.systemConfigStore=n,this.listStoreFactory=o,this.localStorageService=f,this.recordPaginationService=D,this.internalState=dr(sA),this.cache$=null,this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subs=[],this.recordListStore=this.listStoreFactory.create(),this.recordIds$=this.state$.pipe((0,M.map)(j=>j.recordIds),(0,M.distinctUntilChanged)()),this.pagination$=this.state$.pipe((0,M.map)(j=>j.pagination),(0,M.distinctUntilChanged)()),this.paginationEnabled$=this.state$.pipe((0,M.map)(j=>j.paginationEnabled),(0,M.distinctUntilChanged)())}clear(){this.cache$=null,this.updateState(dr(sA)),this.subs.forEach(t=>t.unsubscribe())}init(){const t=this.getModule();this.recordListStore.init(t,!1),this.enableRecordPagination(),this.loadDataLocalStorage(),this.loadCurrentPagination(t),this.loadCurrentSort(t),this.loadCurrentFilter(t)}enableRecordPagination(){let t=this.systemConfigStore.getConfigValue("enable_record_pagination");""===t&&(t=!1),this.updateState({...this.internalState,paginationEnabled:!!t})}loadDataLocalStorage(){const t=this.getRecordListPreference();this.updateState({...this.internalState,recordIds:t?.recordIds,pagination:t?.pagination})}getRecordListPreference(){const t=this.getModule(),n=this.loadPreference(t,"current-record-pagination");return this.checkPaginationExist(n),(0,wt.isArray)(n.recordIds)&&n.recordIds&&n.recordIds.length?n:null}checkPaginationExist(t){const n=this.getModule();this.loadPreference(n,"current-pagination","listview")||(this.recordListStore.pagination=t.pagination)}loadPreference(t,n,o){return this.preferences.getUi(t,o?o+"-"+n:this.getPreferenceKey(n))}getPreferenceKey(t){return"recordview-"+t}loadCurrentPagination(t){const o=this.localStorageService.get(t+"-listview-current-pagination");!o||_a(o)||(this.recordListStore.pagination=o)}loadCurrentSort(t){const n=this.loadPreference(t,"current-sort","listview");!n||_a(n)||(this.recordListStore.sort=n)}loadCurrentFilter(t){const n=this.loadPreference(t,"current-filters","listview")??{};if(!n||_a(n))return;let o=this.loadPreference(t,"current-sort","listview");!o&&_a(o)&&(o=null),this.setFilters(n,!1,o)}setFilters(t,n=!0,o=null){const D=t[Object.keys(t).shift()];if(this.recordListStore.setFilters(t,n,o),D.criteria){let j=D.criteria.orderBy??"",Ne=this.recordListStore.mapSortOrder(D.criteria.sortOrder??"");null!==o&&(j=o.orderBy,Ne=o.sortOrder),this.recordListStore.updateSorting(j,Ne,!1)}this.updateSearchCriteria(t,n)}updateSearchCriteria(t,n=!0){let o=this.mergeCriteria(t);this.recordListStore.updateSearchCriteria(o,n)}mergeCriteria(t){let n={};return(Object.keys(t??{})??[]).forEach(f=>{const j=(t[f]??null)?.criteria??null,fe=Object.keys(j?.filters??{});if(null!==j&&(!fe||fe.length)){if(_a(n))return void(n=dr(j));fe.forEach(Ne=>{const vt=j?.filters[Ne]??null,ln=n?.filters[Ne]??null;if(!vt)return;const Hn=ln?.operator??null;if(!ln||!Hn)return void(n.filters[Ne]=dr(vt));const Oi=vt?.operator??null;Oi===Hn&&"="===Oi?ln.values=(0,wt.union)(ln.values??[],vt.values??[]):delete n.filters[Ne]})}}),n}getModule(){return this.recordPaginationService.getModule()}getCurrentPage(){const t=this.internalState.pagination?.pageSize,n=this.internalState.pagination?.pageLast;return Math.ceil(n/t)}getPageSize(){return this.internalState.pagination?.pageSize}getRecordsCount(){return this.internalState.pagination?.total}updateState(t){this.store.next(this.internalState=t)}set(t){this.cache$=(0,i.of)(t).pipe((0,M.shareReplay)(1)),this.updateState(t)}isCached(){return null!==this.cache$}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject($a),e.\u0275\u0275inject(zo),e.\u0275\u0275inject($p),e.\u0275\u0275inject(Zu),e.\u0275\u0275inject(lE))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();function nk(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-button",3),e.\u0275\u0275elementStart(2,"span",4),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(4,"scrm-button",3),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("config",n.prevButton),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate3(" ",n.currentIndex," ",t.appStrings.LBL_LIST_OF||""," ",t.pageCount.total," "),e.\u0275\u0275advance(),e.\u0275\u0275property("config",n.nextButton)}}function _3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275template(1,nk,5,5,"ng-container",2),e.\u0275\u0275elementEnd()),2&r){const t=v.ngIf;e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.paginationEnabled)}}let mN=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi){this.systemConfigStore=t,this.preferences=n,this.localStorageService=o,this.languageStore=f,this.navigation=D,this.nameMapper=j,this.recordViewStore=fe,this.recordPaginationStore=Ne,this.recordPaginationService=vt,this.route=ln,this.router=Hn,this.modalService=Oi,this.currentIndex=1,this.currentPage=1,this.pageSize=20,this.totalRecordsCount=0,this.isRecordsLoading=!1,this.isSaveContinueClicked=!1,this.mode="detail",this.paginationType=Jv.PAGINATION,this.subs=[],this.prevButton=null,this.nextButton=null,this.appStrings$=this.languageStore.appStrings$,this.recordIds$=this.recordPaginationStore.recordIds$,this.mode$=this.recordViewStore.mode$,this.vm$=null,this.subs.push(this.route.queryParamMap.subscribe(Lr=>{this.currentIndex=(0,wt.toNumber)(Lr.get("offset"))}))}ngOnInit(){this.recordPaginationStore.init(),this.currentPage=this.recordPaginationStore.getCurrentPage(),this.pageSize=this.recordPaginationStore.getPageSize(),this.totalRecordsCount=this.recordPaginationStore.getRecordsCount(),this.paginationType=this.preferences.getUserPreference("listview_pagination_type")??this.systemConfigStore.getConfigValue("listview_pagination_type"),this.recordPaginationService.paginationType=this.paginationType,this.subs.push(this.mode$.subscribe(t=>{this.mode=t})),this.prevButton={klass:{"record-pagination-button":!0,"pagination-previous":!0,disabled:1===this.currentIndex},icon:"paginate_previous",iconKlass:"sicon-2x",disabled:1===this.currentIndex||this.isRecordsLoading,onClick:()=>this.prevRecord()},this.nextButton={klass:{"record-pagination-button":!0,"pagination-next":!0,disabled:this.currentIndex===this.totalRecordsCount},icon:"paginate_next",iconKlass:"sicon-2x",disabled:this.currentIndex===this.totalRecordsCount||this.isRecordsLoading,onClick:()=>this.nextRecord()},this.vm$=this.appStrings$.pipe((0,i.combineLatestWith)(this.recordPaginationStore.pagination$,this.recordPaginationStore.paginationEnabled$),(0,M.map)(([t,n,o])=>{const D=(this.nameMapper.toFrontend(this.recordPaginationStore.getModule())??"")+"-recordview-current-record-pagination",j=this.localStorageService.get(D),fe=this.recordPaginationService.checkRecordValid(this.recordViewStore.getRecordId());return(!j||!fe||this.currentIndex>this.totalRecordsCount)&&(o=!1),this.prevButton={...this.prevButton,titleKey:t.LBL_SEARCH_PREV||""},this.nextButton={...this.nextButton,titleKey:t.LBL_SEARCH_NEXT||""},{appStrings:t,pageCount:n,paginationEnabled:o}})),this.subs.push(this.recordIds$.subscribe(t=>{this.recordIds=t})),this.subs.push(this.recordPaginationService.nextRecord$.pipe((0,M.filter)(t=>!!t),(0,M.tap)(t=>{this.isSaveContinueClicked=!0,this.nextRecord()})).subscribe(t=>{this.isSaveContinueClicked=!1,this.recordPaginationService.triggerNextRecord(!1)}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.recordPaginationStore.clear()}prevRecord(){if(this.currentIndex<=0)return;let t=(this.currentIndex-2)%this.pageSize;this.currentIndex-(this.currentPage-1)*this.pageSize-1<=0?this.loadPage(eu.PREVIOUS):"edit"===this.mode&&this.recordViewStore.recordStore.isDirty()?this.showConfirmationModal(eu.PREVIOUS,t):this.navigatePrevRoute(t)}nextRecord(){if(this.currentIndex>=this.totalRecordsCount)return;let t=this.currentIndex%this.pageSize;this.currentIndex-(this.currentPage-1)*this.pageSize>this.recordIds.length-1?this.loadPage(eu.NEXT):"edit"===this.mode&&this.recordViewStore.recordStore.isDirty()&&!this.isSaveContinueClicked?this.showConfirmationModal(eu.NEXT,t):this.navigateNextRoute(t)}loadPage(t){this.isRecordsLoading=!0;let n=0,o=!1;if(this.paginationType===Jv.LOAD_MORE&&(o=!0),t===eu.PREVIOUS?n=this.pageSize-1:t===eu.NEXT&&o&&(n=this.currentIndex),o&&t!==eu.PREVIOUS){const f=this.preferences.getUserPreference("list_max_entries_per_page")??this.systemConfigStore.getConfigValue("list_max_entries_per_page"),D=this.recordPaginationStore.recordListStore.getPagination(),fe=Number(D.pageSize||0)+Number(f);this.recordPaginationStore.recordListStore.setPageSize(fe),this.recordPaginationStore.recordListStore.updatePagination(D.current)}this.recordPaginationStore.recordListStore.setPage(t,o).subscribe(f=>{this.recordPaginationService.updateRecordListLocalStorage(f.records,f.pagination),this.recordPaginationStore.loadDataLocalStorage(),this.isRecordsLoading=!1,"edit"===this.mode&&this.recordViewStore.recordStore.isDirty()&&!this.isSaveContinueClicked?this.showConfirmationModal(t,n):t===eu.NEXT?this.navigateNextRoute(n):this.navigatePrevRoute(n)})}navigateNextRoute(t){const n=this.buildRoute(this.recordIds[t]);this.router.navigate([n],{queryParams:{offset:this.currentIndex+1}})}navigatePrevRoute(t){const n=this.buildRoute(this.recordIds[t]);this.router.navigate([n],{queryParams:{offset:this.currentIndex-1}})}showConfirmationModal(t,n){const o=this.modalService.open(Ye);o.componentInstance.textKey="WARN_UNSAVED_CHANGES",o.componentInstance.buttons=[{labelKey:"LBL_CANCEL",klass:["btn-secondary"],onClick:f=>f.dismiss()},{labelKey:"LBL_PROCEED",klass:["btn-main"],onClick:f=>{t===eu.NEXT?this.navigateNextRoute(n):this.navigatePrevRoute(n),f.close()}}]}buildRoute(t){const n=this.nameMapper.toFrontend(this.recordPaginationStore.getModule())??"";return this.navigation.getRecordRouterLink(n,t.id??"","edit"===this.mode)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(Zu),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(Ac),e.\u0275\u0275directiveInject(uf),e.\u0275\u0275directiveInject(aA),e.\u0275\u0275directiveInject(lE),e.\u0275\u0275directiveInject(Wo.ActivatedRoute),e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(ct.NgbModal))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-pagination"]],standalone:!0,features:[e.\u0275\u0275StandaloneFeature],decls:2,vars:3,consts:[["class","record-pagination-container d-flex align-items-center justify-content-end",4,"ngIf"],[1,"record-pagination-container","d-flex","align-items-center","justify-content-end"],[4,"ngIf"],[3,"config"],[1,"pagination-count"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,_3,2,1,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.CommonModule,ve.NgIf,ve.AsyncPipe,Oa,xc],encapsulation:2,changeDetection:0})}return r})();const ik=r=>({"col-lg-12":r});function NP(r,v){1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275element(1,"scrm-record-content-skeleton"),e.\u0275\u0275elementContainerEnd())}function rk(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",12),e.\u0275\u0275element(1,"scrm-record-pagination"),e.\u0275\u0275elementEnd())}function RP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"scrm-record-content",10),e.\u0275\u0275template(2,rk,2,0,"div",11),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("dataSource",t.getContentAdapter()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.isOffsetExist)}}function y3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15),e.\u0275\u0275element(1,"scrm-sidebar-widget",16),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t)("context$",n.getViewContext$())("context",n.getViewContext())("type",t.type)}}function lA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",13)(1,"div",7),e.\u0275\u0275template(2,y3,2,4,"div",14),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",t.bottomWidgetConfig.widgets)}}function LP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",17)(1,"div",7),e.\u0275\u0275element(2,"scrm-subpanel-container",18),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.getSubpanelsConfig())}}function kP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",4)(2,"div",5)(3,"div",6)(4,"div",7),e.\u0275\u0275template(5,NP,2,0,"ng-container",3)(6,RP,3,2,"ng-container",3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(7,lA,3,1,"div",8)(8,LP,3,1,"div",9),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(5,ik,!n.sidebarWidgetConfig.show)),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",n.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!n.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.bottomWidgetConfig.show&&t.bottomWidgetConfig.widgets&&t.bottomWidgetConfig.widgets.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.showSubpanels)}}function G2(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",22)(1,"div",23)(2,"div",24),e.\u0275\u0275element(3,"div",25),e.\u0275\u0275elementEnd()()())}function gN(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15)(1,"div",27),e.\u0275\u0275element(2,"scrm-top-widget",28),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(4).ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.topWidgetConfig.widget)("context",n.getViewContext())("type",t.topWidgetConfig.widget.type)}}function PP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,gN,3,3,"div",26),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(3).ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.topWidgetConfig.show&&n.hasTopWidgetMetadata(t.topWidgetConfig.widget))}}function K2(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15),e.\u0275\u0275element(1,"scrm-sidebar-widget",29),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(4);e.\u0275\u0275advance(),e.\u0275\u0275property("type",t.type)("context",n.getViewContext())("context$",n.getViewContext$())("config",t)}}function BP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",20),e.\u0275\u0275template(1,G2,4,0,"div",21)(2,PP,2,1,"ng-container",3)(3,K2,2,4,"div",14),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275classProp("mt-0",t.swapWidgets),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.sidebarWidgetConfig.widgets)}}function VP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,BP,4,5,"div",19),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.displayWidgets)}}function cA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1)(1,"div",2),e.\u0275\u0275template(2,kP,9,7,"ng-container",3)(3,VP,2,1,"ng-container",3),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!t.swapWidgets||t.swapWidgets&&!t.displayWidgets),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.swapWidgets||t.swapWidgets&&t.displayWidgets)}}let q2=(()=>{class r{onEnterKey(){!this.saveAction||!this.context||this.actionsAdapter.runAction(this.saveAction,this.context)}constructor(t,n,o,f,D,j,fe,Ne,vt,ln){this.recordViewStore=t,this.language=n,this.metadata=o,this.contentAdapter=f,this.topWidgetAdapter=D,this.sidebarWidgetAdapter=j,this.bottomWidgetAdapter=fe,this.actionsAdapter=Ne,this.sidebarWidgetHandler=vt,this.activatedRoute=ln,this.subs=[],this.loading=!0,this.language$=this.language.vm$,this.isOffsetExist=!1,this.displayWidgets=!0,this.swapWidgets=!1,this.vm$=this.language$.pipe((0,i.combineLatestWith)(this.bottomWidgetAdapter.config$,this.topWidgetAdapter.config$,this.recordViewStore.showSubpanels$),(0,M.map)(([Oi,Lr,to,Mr])=>({language:Oi,bottomWidgetConfig:Lr,topWidgetConfig:to,showSubpanels:Mr}))),this.actionConfig$=this.recordViewStore.mode$.pipe((0,i.combineLatestWith)(this.actionsAdapter.getActions(),this.getViewContext$()),(0,M.filter)(([Oi,Lr,to])=>"edit"===Oi),(0,M.map)(([Oi,Lr,to])=>({mode:Oi,actions:Lr,context:to}))),this.isOffsetExist=!!this.activatedRoute.snapshot.queryParamMap.get("offset")}ngOnInit(){this.subs.push(this.recordViewStore.loading$.subscribe(t=>{this.loading=t})),this.subs.push(this.actionConfig$.subscribe(t=>{this.context=t.context,t.actions.forEach(n=>{"save"===n.key&&(this.saveAction=n)})})),this.subs.push(this.sidebarWidgetAdapter.config$.subscribe(t=>{this.sidebarWidgetConfig=t,this.displayWidgets=this.sidebarWidgetConfig.show&&this.sidebarWidgetConfig.widgets})),this.subs.push(this.sidebarWidgetHandler.widgetSwap$.subscribe(t=>{this.swapWidgets=t}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.contentAdapter.clean()}getContentAdapter(){return this.contentAdapter}getSubpanelsConfig(){return{parentModule:this.recordViewStore.getModuleName(),subpanels$:this.recordViewStore.subpanels$,sidebarActive$:this.recordViewStore.widgets$}}getViewContext(){return this.recordViewStore.getViewContext()}getViewContext$(){return this.recordViewStore.viewContext$}hasTopWidgetMetadata(t){return!(!t||!t.type)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(uf),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(Fs),e.\u0275\u0275directiveInject(z2),e.\u0275\u0275directiveInject(oA),e.\u0275\u0275directiveInject(tk),e.\u0275\u0275directiveInject(hN),e.\u0275\u0275directiveInject(mM),e.\u0275\u0275directiveInject(rA),e.\u0275\u0275directiveInject(Wo.ActivatedRoute))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-container"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keyup.control.enter",function(){return o.onEnterKey()})},features:[e.\u0275\u0275ProvidersFeature([z2,oA,tk,hN])],decls:2,vars:3,consts:[["class","record-view-container view-container container-fluid pt-0 pb-3 small-font",4,"ngIf"],[1,"record-view-container","view-container","container-fluid","pt-0","pb-3","small-font"],[1,"row"],[4,"ngIf"],[1,"col-lg-9",3,"ngClass"],[1,"container-fluid","pl-0","pr-0"],[1,"row","no-gutters","mt-1"],[1,"col"],["class","row no-gutters mt-2",4,"ngIf"],["class","row no-gutters pt-3 pb-4",4,"ngIf"],[3,"dataSource"],["top-right-placement","",4,"ngIf"],["top-right-placement",""],[1,"row","no-gutters","mt-2"],["class","mb-3",4,"ngFor","ngForOf"],[1,"mb-3"],[3,"config","context$","context","type"],[1,"row","no-gutters","pt-3","pb-4"],[3,"config"],["class","col-lg-3 record-widget-container pl-0",3,"mt-0",4,"ngIf"],[1,"col-lg-3","record-widget-container","pl-0"],["class","row no-gutters",4,"ngIf"],[1,"row","no-gutters"],[1,"col","pb-3"],[1,"d-flex","justify-content-center","widget-bar","rounded","pb-1","pt-3","box-loading"],[1,"d-flex","justify-content-center","align-items-baseline","widget-bar-entry","p-2"],["class","mb-3",4,"ngIf"],[1,""],[3,"config","context","type"],[3,"type","context","context$","config"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,cA,4,2,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,NL,Xw,DP,XI,LR,mN,ve.AsyncPipe],encapsulation:2})}return r})();function ok(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",3)(1,"div",4),e.\u0275\u0275element(2,"scrm-module-title",5)(3,"div",6),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("title",t.moduleTitle)}}function Q2(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",20),2&r){const t=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("config",t.backButtonConfig)}}function jP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",18),e.\u0275\u0275template(1,Q2,1,1,"scrm-button",19),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.backButtonConfig)}}function UP(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",21),e.\u0275\u0275element(1,"scrm-favorite-toggle",22),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("record",t.record)}}function Y2(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-dynamic-label",23),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("fields",t.record.fields)("labelKey",t.getSummaryTemplate())}}function $P(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",24),e.\u0275\u0275element(1,"scrm-action-group-menu",25),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.actionsAdapter)("actionContext",t.getActionContext(t.record))("klass",t.isScrolled?"record-view-actions-scrolled float-right":"record-view-actions float-right")}}function sk(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",7)(1,"div",8)(2,"div",9),e.\u0275\u0275template(3,jP,2,1,"div",10),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"div",11)(5,"div",12),e.\u0275\u0275template(6,UP,2,1,"div",13)(7,Y2,1,2,"scrm-dynamic-label",14),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(8,"div",15)(9,"div",16),e.\u0275\u0275template(10,$P,2,3,"div",17),e.\u0275\u0275elementEnd()()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf","detail"===t.mode||"edit"===t.mode),e.\u0275\u0275advance(),e.\u0275\u0275classProp("justify-content-center","detail"===t.mode||"edit"===t.mode)("justify-content-start",!("detail"===t.mode||"edit"===t.mode))("record-view-name-wrapper-margin-left","detail"===t.mode||"edit"===t.mode),e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",t.isScrolled?"record-view-name-scrolled":"record-view-name"),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.record&&t.record.fields&&"create"!==t.mode),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.record&&t.record.fields),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.record)}}let cE=(()=>{class r{onScroll(){const t=window.pageYOffset,n=parseFloat(getComputedStyle(document.documentElement).fontSize);if(t>n){if(t-n<5)return;this.isScrolled=!0}else{if(n-t<5)return;this.isScrolled=!1}}constructor(t,n,o,f,D){this.actionsAdapter=t,this.recordViewStore=n,this.moduleNavigation=o,this.appState=f,this.router=D,this.mode="detail",this.loading=!0,this.isScrolled=!1,this.subs=[]}ngOnInit(){this.mode=this.recordViewStore.getMode(),this.setBackButtonConfig(),this.subs.push(this.recordViewStore.mode$.subscribe(t=>{this.mode=t})),this.subs.push(this.recordViewStore.record$.subscribe(t=>{this.record=t})),this.subs.push(this.recordViewStore.loading$.subscribe(t=>{this.loading=t}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe())}get moduleTitle(){return this.moduleNavigation.getModuleLabel(this.recordViewStore.vm.appData.module,this.recordViewStore.vm.appData.language.appListStrings)}getSummaryTemplate(){return this.recordViewStore.getSummaryTemplate()}getActionContext(t){return t?{module:t.module||"",record:t}:{}}setBackButtonConfig(){const t=this.moduleNavigation.getModuleRoute(this.recordViewStore.vm.appData.module);this.backButtonConfig={icon:"paginate_previous",klass:"back-button",onClick:()=>{this.router.navigate([t.route],{queryParams:{keepPagination:!0}}).then()}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(mM),e.\u0275\u0275directiveInject(uf),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Wo.Router))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record-header"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("scroll",function(){return o.onScroll()},!1,e.\u0275\u0275resolveWindow)},decls:4,vars:3,consts:[[1,"record-view-header",3,"ngClass"],["class","row mr-0",4,"ngIf"],["class","row m-0 d-flex justify-content-between ml-1 mr-1",4,"ngIf"],[1,"row","mr-0"],[1,"col-md-4","d-flex","align-items-center"],[1,"record-view-title","title-font",3,"title"],[1,"record-view-name","pt-3","pb-3"],[1,"row","m-0","d-flex","justify-content-between","ml-1","mr-1"],[1,"col-xs-12","col-sm-12","col-md-5","col-lg-6","col-xl-7","record-name-container"],[1,"float-left","p-0"],["class","d-flex record-view-back-button justify-content-start",4,"ngIf"],[1,"record-view-name-wrapper","d-flex","justify-content-md-start","align-items-center"],[1,"p-0","d-inline-block",3,"ngClass"],["class","float-right align-items-top d-flex",4,"ngIf"],["class","record-view-name-label d-block p-0 lh-100",3,"fields","labelKey",4,"ngIf"],[1,"col-xs-12","col-sm-12","col-md-7","col-lg-6","col-xl-5","align-items-center","record-view-action-header"],[1,"row","mr-1","ml-1","justify-content-center","justify-content-md-end"],["class","",4,"ngIf"],[1,"d-flex","record-view-back-button","justify-content-start"],[3,"config",4,"ngIf"],[3,"config"],[1,"float-right","align-items-top","d-flex"],[1,"h-100","lh-100",3,"record"],[1,"record-view-name-label","d-block","p-0","lh-100",3,"fields","labelKey"],[1,""],["buttonClass","settings-button",3,"config","actionContext","klass"]],template:function(n,o){1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",0),e.\u0275\u0275template(2,ok,4,1,"div",1)(3,sk,11,11,"div",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&n&&(e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",o.isScrolled?"record-view-header-scrolled shadow-md":""),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.loading),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.loading))},dependencies:[ve.NgClass,ve.NgIf,co,Df,Ph,ZR,xc],encapsulation:2})}return r})();function WP(r,v){1&r&&e.\u0275\u0275element(0,"scrm-status-bar")}function ak(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1)(1,"div",2),e.\u0275\u0275element(2,"scrm-record-header"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",3),e.\u0275\u0275element(4,"hr",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,WP,1,0,"scrm-status-bar",5),e.\u0275\u0275element(6,"scrm-record-container"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275property("ngIf",t.showStatusBar)}}let ZC=(()=>{class r{onEnterKey(){!this.saveAction||!this.context||this.actionsAdapter.runAction(this.saveAction,this.context)}constructor(t,n,o,f){this.appState=t,this.recordStore=n,this.actionsAdapter=o,this.route=f,this.subs=[],this.vm$=null,this.showStatusBar=!1,this.actionConfig$=this.recordStore.mode$.pipe((0,i.combineLatestWith)(this.actionsAdapter.getActions(),this.getViewContext$()),(0,M.filter)(([D,j,fe])=>"create"===D),(0,M.map)(([D,j,fe])=>({mode:D,actions:j,context:fe})))}ngOnInit(){let t="detail";const n=this.route.snapshot&&this.route.snapshot.data||{};n.mode&&(t=n.mode);let o=this.route.snapshot&&this.route.snapshot.queryParams||{};o={...o};let f=this.route.snapshot.params.record;!0===n.duplicate&&(o.originalId=f,o.isDuplicate=!0,f=""),!0===n.convert&&(o.originalId=f,o.isConvert=!0,f=""),this.subs.push(this.recordStore.init(this.appState.getModule(),f,t,o).subscribe()),this.vm$=this.recordStore.vm$,this.appState.removeAllPrevRoutes(),this.subs.push(this.actionConfig$.subscribe(D=>{this.context=D.context,D.actions.forEach(j=>{"saveNew"===j.key&&(this.saveAction=j)})}))}getViewContext$(){return this.recordStore.viewContext$}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.recordStore.destroy()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(tA),e.\u0275\u0275directiveInject(mM),e.\u0275\u0275directiveInject(Wo.ActivatedRoute))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-create-record"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keyup.control.enter",function(){return o.onEnterKey()})},features:[e.\u0275\u0275ProvidersFeature([tA,mM,{provide:uf,useExisting:tA},rA])],decls:2,vars:3,consts:[["class","record-view",4,"ngIf"],[1,"record-view"],[1,"record-view-position-sticky"],[1,"record-view-hr-container"],[1,"record-view-hr"],[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,ak,7,1,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,q2,cE,g2,ve.AsyncPipe],encapsulation:2})}return r})(),X2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Gp,fn.AngularSvgIconModule,eN,oM,wP,B2,lF,mN]})}return r})(),Z2=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Do,dh,hm,DF,Oa]})}return r})();function tx(r,v){1&r&&e.\u0275\u0275element(0,"scrm-status-bar")}function J2(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",1)(1,"div",2),e.\u0275\u0275element(2,"scrm-record-header"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",3),e.\u0275\u0275element(4,"hr",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,tx,1,0,"scrm-status-bar",5),e.\u0275\u0275element(6,"scrm-record-container"),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(5),e.\u0275\u0275property("ngIf",t.showStatusBar)}}let lk=(()=>{class r{constructor(t,n,o,f){this.appState=t,this.recordStore=n,this.route=o,this.sidebarWidgetHandler=f,this.vm$=null,this.showStatusBar=!1}ngOnInit(){let t="detail";this.appState.addToPrevRoute(this.appState.getRouteUrl());const n=this.route.snapshot&&this.route.snapshot.data||{};n.mode&&(t=n.mode);const o=this.route.snapshot&&this.route.snapshot.queryParams||{};this.recordSub=this.recordStore.init(this.appState.getModule(),this.route.snapshot.params.record,t,o).subscribe(),this.vm$=this.recordStore.vm$}ngOnDestroy(){this.recordSub&&this.recordSub.unsubscribe(),this.sidebarWidgetHandler.destroy(),this.recordStore.destroy()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(uf),e.\u0275\u0275directiveInject(Wo.ActivatedRoute),e.\u0275\u0275directiveInject(rA))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-record"]],features:[e.\u0275\u0275ProvidersFeature([uf,mM,rA,aA])],decls:2,vars:3,consts:[["class","record-view",4,"ngIf"],[1,"record-view"],[1,"record-view-position-sticky"],[1,"record-view-hr-container"],[1,"record-view-hr"],[4,"ngIf"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,J2,7,1,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,q2,cE,g2,ve.AsyncPipe],encapsulation:2})}return r})(),uA=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,X2,Z2,Zw,QI]})}return r})(),HP=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,uA,X2,Z2,Zw,QI]})}return r})();class dA extends kp{}let fA=(()=>{class r extends dA{constructor(t,n,o,f,D,j){super(),this.message=t,this.asyncActionService=n,this.router=o,this.modalService=f,this.state=D,this.localStorage=j,this.key="install",this.modes=["edit"]}run(t){t.store.recordStore.validate().pipe((0,M.take)(1)).subscribe(n=>{if(n){const o=t.store.recordStore.getStaging();this.runInstall(o)}else this.message.addWarningMessageByKey("LBL_VALIDATION_ERRORS")})}shouldDisplay(){return!0}runInstall(t){const n=`suitecrm-app-${this.key}`;this.message.removeMessages(),this.asyncActionService.run(n,{action:n,module:t.module,id:t.id,payload:t.formGroup.value},null,{errorMessageLabel:"An error occurred while installing SuiteCRM. Please check the '/logs/install.log'."}).pipe((0,M.take)(1)).subscribe(f=>{3===f.data.statusCode&&this.openErrorModalDialog(f.data.errors),0===f.data.statusCode&&(this.state.clear(),this.localStorage.clear(),this.router.navigate(["/"],{}).then())})}openErrorModalDialog(t){this.modalService.open(Kp,{ariaLabelledBy:"modal-basic-title",centered:!0,size:"lg",windowClass:"custom-modal",modalDialogClass:"custom-modal"}).componentInstance.errors=t}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(Wo.Router),e.\u0275\u0275inject(ct.NgbModal),e.\u0275\u0275inject(ys),e.\u0275\u0275inject(Zu))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),eO=(()=>{class r extends js{constructor(t){super(),this.save=t,t.modes.forEach(n=>this.actions[n][t.key]=t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(fA))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();const vN={loading:!1,mode:"detail",params:{returnModule:"",returnId:"",returnAction:""}};let t1=(()=>{class r{constructor(t,n,o,f,D,j){this.recordFetchGQL=t,this.recordSaveGQL=n,this.message=o,this.recordManager=f,this.recordStoreFactory=D,this.language=j,this.cache$=null,this.internalState=dr(vN),this.store=new i.BehaviorSubject(this.internalState),this.state$=this.store.asObservable(),this.subs=[],this.recordStore=D.create(this.getViewFieldsObservable()),this.record$=this.recordStore.state$.pipe((0,M.distinctUntilChanged)()),this.stagingRecord$=this.recordStore.staging$.pipe((0,M.distinctUntilChanged)()),this.loading$=this.state$.pipe((0,M.map)(fe=>fe.loading)),this.mode$=this.state$.pipe((0,M.map)(fe=>fe.mode)),this.vm$=this.record$.pipe((0,i.combineLatestWith)(this.loading$),(0,M.map)(([fe,Ne])=>(this.vm={record:fe,loading:Ne},this.vm))),this.viewContext$=this.record$.pipe((0,M.map)(()=>this.getViewContext()))}get params(){return this.internalState.params||{}}set params(t){this.updateState({...this.internalState,params:t})}getViewContext(){return{record:this.getBaseRecord()}}getActions(){return(0,i.of)([])}init(t="edit",n={}){this.setMode(t),this.recordStore.init({id:"",module:"install",attributes:{}},!0)}clear(){this.cache$=null,this.updateState(dr(vN))}clearAuthBased(){this.clear()}getBaseRecord(){return this.internalState?this.recordStore.getBaseRecord():null}getMode(){return this.internalState?this.internalState.mode:null}setMode(t){this.updateState({...this.internalState,mode:t})}getLicenseText(){return this.language.getFieldLabel("SUITE8_LICENSE_CONTENT")}getMetadata(){return this.url=window.location.origin+window.location.pathname,this.url=(0,wt.trimEnd)(this.url,"/"),{actions:[],templateMeta:{maxColumns:2,useTabs:!0,tabDefs:{LBL_CONFIG:{newTab:!0,panelDefault:"expanded"}}},panels:[{key:"LBL_CONFIG",display$:(0,i.of)(!0).pipe((0,M.shareReplay)(1)),rows:[{cols:[{name:"site_host",label:"LBL_SITECFG_URL",type:"varchar",fieldDefinition:{name:"site_host",vname:"LBL_SITECFG_URL",type:"varchar",required:!0,default:this.url?.toString(),defaultValueModes:["create","edit"]}},{name:"demoData",label:"LBL_DBCONF_DEMO_DATA",type:"enum",fieldDefinition:{name:"demoData",vname:"LBL_DBCONF_DEMO_DATA",type:"enum",options:"__no_options__",required:!0,default:"no",defaultValueModes:["create","edit"],metadata:{extraOptions:[{value:"yes",labelKey:"LBL_YES"},{value:"no",labelKey:"LBL_NO"}]}}}]},{cols:[{name:"db_config",label:"LBL_DBCONF_TITLE",type:"grouped-field",fieldDefinition:{name:"db_config",vname:"LBL_DBCONF_TITLE",type:"grouped-field",layout:["db_username","db_password","db_host","db_name","db_port"],display:"vertical",groupFields:{db_username:{name:"db_username",type:"varchar",vname:"LBL_DBCONF_SUITE_DB_USER",labelKey:"LBL_DBCONF_SUITE_DB_USER",label:"LBL_DBCONF_SUITE_DB_USER",showLabel:["*"],required:!0},db_password:{name:"db_password",type:"password",vname:"LBL_DBCONF_DB_PASSWORD",labelKey:"LBL_DBCONF_DB_PASSWORD",showLabel:["*"],required:!0},db_host:{name:"db_host",type:"varchar",vname:"LBL_DBCONF_HOST_NAME",labelKey:"LBL_DBCONF_HOST_NAME",showLabel:["*"],required:!0},db_name:{name:"db_name",type:"varchar",vname:"LBL_DBCONF_DB_NAME",labelKey:"LBL_DBCONF_DB_NAME",showLabel:["*"],required:!0},db_port:{name:"db_port",type:"varchar",vname:"LBL_DBCONF_DB_PORT",labelKey:"LBL_DBCONF_DB_PORT",showLabel:["*"],required:!1,default:"3306",defaultValueModes:["create","edit"]}},showLabel:{edit:["*"]}}},{name:"admin_config",label:"LBL_SITECFG_TITLE",type:"grouped-field",fieldDefinition:{name:"admin_config",vname:"LBL_SITECFG_TITLE",type:"grouped-field",layout:["site_username","site_password"],display:"vertical",groupFields:{site_username:{name:"site_username",type:"varchar",vname:"LBL_SITECFG_ADMIN_Name",labelKey:"LBL_SITECFG_ADMIN_Name",showLabel:["edit"],required:!0,default:"admin",defaultValueModes:["create","edit"]},site_password:{name:"site_password",type:"password",vname:"LBL_SITECFG_ADMIN_PASS",labelKey:"LBL_SITECFG_ADMIN_PASS",showLabel:["edit"],required:!0}},showLabel:{edit:["*"]}}}]}]}]}}getMetadata$(){return(0,i.of)(this.getMetadata())}getModuleName(){return"install"}parseParams(t={}){if(!t)return;const n={...this.internalState.params};Object.keys(t).forEach(o=>{Al(n[o])||(n[o]=t[o])}),this.params=t}updateState(t){this.store.next(this.internalState=t)}getIgnoreSystemChecksField(){return this.recordStore.getStaging().fields.sys_check_option}getViewFieldsObservable(){return this.getMetadata$().pipe((0,M.map)(t=>{const n=[];return t.panels.forEach(o=>{o.rows.forEach(f=>{f.cols.forEach(D=>{n.push(D)})})}),n.push({name:"sys_check_option",type:"boolean",fieldDefinition:{name:"sys_check_option",type:"boolean",vname:"LBL_SYS_CHECK_WARNING",labelKey:"LBL_SYS_CHECK_WARNING",showLabel:["edit"],required:!1,value:"false",default:"false",defaultValueModes:["create","edit"]}}),n}))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(jl),e.\u0275\u0275inject(Co),e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Dd),e.\u0275\u0275inject(Os),e.\u0275\u0275inject(Kr))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),ck=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt){super(f,D,j,fe,o,Ne,n,vt),this.store=t,this.metadata=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne,this.appMetadataStore=vt,this.defaultActions={detail:[],edit:[{key:"install",labelKey:"LBL_PROCEED",params:{expanded:!0},acl:[]}],create:[]},this.collapseButtons=!1}getActions(t){return this.store.getActions().pipe((0,i.combineLatestWith)(this.store.mode$,this.store.stagingRecord$),(0,M.map)(([n,o])=>o?this.parseModeActions(n,o,this.store.getViewContext()):[]))}buildActionData(t,n){return{store:this.store}}buildActionInput(t,n,o,f=null){const D=this.store.getBaseRecord();return this.message.removeMessages(),{action:n,module:D.module,id:D.id,record:D}}getMode(){return this.store.getMode()}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t1),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(eO),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),_N=(()=>{class r{constructor(t,n,o,f){this.store=t,this.metadata=n,this.language=o,this.actions=f}getEditAction(){}getDisplayConfig(){return this.store.getMetadata$().pipe((0,i.combineLatestWith)(this.store.mode$),(0,M.map)(([t,n])=>({layout:this.getLayout(t),mode:n,maxColumns:t.templateMeta.maxColumns||2,tabDefs:t.templateMeta.tabDefs})))}getPanels(){return this.store.getMetadata$().pipe((0,i.combineLatestWith)(this.store.stagingRecord$,this.language.vm$),(0,M.map)(([t,n,o])=>{const f=[],D=n&&n.module||"";return t.panels.forEach(j=>{const Ne={label:this.language.getFieldLabel(j.key.toUpperCase(),D,o),key:j.key,display$:j?.display$??(0,i.of)(!0).pipe((0,M.shareReplay)(1)),rows:[]};j.rows.forEach(vt=>{const ln={cols:[]};vt.cols.forEach(Hn=>{ln.cols.push({...Hn})}),Ne.rows.push(ln)}),f.push(Ne)}),f}))}getRecord(){return this.store.stagingRecord$}getLayout(t){let n="panels";return t.templateMeta.useTabs&&(n="tabs"),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(t1),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(eO))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),pA=(()=>{class r{constructor(t,n){this.metadata=t,this.contentAdapter=n}getContentAdapter(){return this.contentAdapter}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Fs),e.\u0275\u0275directiveInject(_N))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-install-container"]],features:[e.\u0275\u0275ProvidersFeature([_N])],decls:4,vars:1,consts:[[1,"install-view-container","record-view-container","view-container","container-fluid","pt-3","pb-3","small-font"],[1,"row","no-gutters"],[1,"col"],[3,"dataSource"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"div",2),e.\u0275\u0275element(3,"scrm-record-content",3),e.\u0275\u0275elementEnd()()()),2&n&&(e.\u0275\u0275advance(3),e.\u0275\u0275property("dataSource",o.getContentAdapter()))},dependencies:[Xw],encapsulation:2})}return r})(),zP=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,fn.AngularSvgIconModule,oM]})}return r})();function GP(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),e.\u0275\u0275element(5,"scrm-label",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",6),e.\u0275\u0275element(7,"scrm-label",7),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(8,"div",8)(9,"div",9)(10,"div",10)(11,"div",11)(12,"div",12)(13,"label",13),e.\u0275\u0275element(14,"scrm-label",14),e.\u0275\u0275elementEnd(),e.\u0275\u0275text(15,": "),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(16,"div",15)(17,"div",16),e.\u0275\u0275element(18,"scrm-field",17),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementStart(19,"div"),e.\u0275\u0275element(20,"scrm-action-group-menu",18),e.\u0275\u0275elementEnd()()()()()(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(14),e.\u0275\u0275property("labelKey",n.store.getIgnoreSystemChecksField().definition.vname),e.\u0275\u0275advance(4),e.\u0275\u0275property("field",n.store.getIgnoreSystemChecksField())("mode","edit")("record",t.record)("type",n.store.getIgnoreSystemChecksField().type),e.\u0275\u0275advance(2),e.\u0275\u0275property("actionContext",n.getActionContext(t.record))("config",n.actionsAdapter)}}let hA=(()=>{class r{constructor(t,n){this.actionsAdapter=t,this.store=n,this.vm$=this.store.record$.pipe((0,M.map)(o=>({record:o})))}getActionContext(t){return t?{module:t.module||"",record:t}:{}}getTitle(){}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ck),e.\u0275\u0275directiveInject(t1))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-install-header"]],features:[e.\u0275\u0275ProvidersFeature([ck])],decls:2,vars:3,consts:[[4,"ngIf"],[1,"install-view-header"],[1,"row","mr-0"],[1,"col-md-4","install-header-title-col"],[1,"install-view-title","record-view-name","pl-4"],["labelKey","LBL_WELCOME","module","install"],[1,"install-view-subtitle","record-view-title"],["labelKey","LBL_INSTALL","module","install"],[1,"col-md-8","install-header-buttons-col"],[1,"row","mr-1","ml-1"],[1,"w-100","d-flex","justify-content-end","align-items-center"],[1,"w-100","install-header-options","d-flex","justify-content-end","align-items-center","pr-5"],[1,"label-container","pr-2"],[1,"m-0","small"],[3,"labelKey"],[1,"d-flex"],[1,"flex-grow-1","text-break"],[3,"field","mode","record","type"],["buttonClass","settings-button","klass","install-view-actions float-right",3,"actionContext","config"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,GP,21,7,"ng-container",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,Ph,Pa,Dm,ve.AsyncPipe],encapsulation:2})}return r})(),uk=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Do,hm,Ea,pa]})}return r})();function b3(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275element(1,"scrm-install-header"),e.\u0275\u0275elementStart(2,"div",2),e.\u0275\u0275element(3,"hr",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(4,"scrm-install-container"),e.\u0275\u0275elementEnd())}let tO=(()=>{class r{constructor(t,n){this.store=t,this.route=n,this.vm$=null,this.showStatusBar=!1}ngOnInit(){let t="edit";const n=this.route.snapshot&&this.route.snapshot.data||{};n.mode&&(t=n.mode),this.store.init(t),this.vm$=this.store.vm$}ngOnDestroy(){this.store.clear()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(t1),e.\u0275\u0275directiveInject(Wo.ActivatedRoute))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-install-view"]],features:[e.\u0275\u0275ProvidersFeature([t1])],decls:2,vars:3,consts:[["class","install-view",4,"ngIf"],[1,"install-view"],[1,"record-view-hr-container"],[1,"record-view-hr"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,b3,5,0,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,hA,pA,ve.AsyncPipe],encapsulation:2})}return r})(),dk=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,pa,uk,zP]})}return r})();class yN extends oL{}let mA=(()=>{class r extends yN{constructor(){super(),this.key="cancel",this.modes=["detail","edit","list","create","massupdate"]}run(t){t.listStore.closeRecordPanel()}shouldDisplay(){return!0}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),fk=(()=>{class r extends yN{constructor(t,n,o,f){super(),this.message=t,this.asyncActionService=n,this.confirmation=o,this.asyncAction=f,this.key="bulk-action",this.modes=["detail","edit","list","create","massupdate"]}run(t){const n=t.action,o=t.listStore.recordList.selection,f=n&&n.params||{};if(sf(f.allowAll)&&o.all)this.message.addDangerMessage(t.listStore.appStrings.LBL_SELECT_ALL_NOT_ALLOWED);else{if(f.min&&o.count<f.min){let D=t.listStore.appStrings.LBL_TOO_FEW_SELECTED;return D=D.replace("{min}",f.min),void this.message.addDangerMessage(D)}if(f.max&&o.count>f.max){let D=t.listStore.appStrings.LBL_TOO_MANY_SELECTED;return D=D.replace("{max}",f.max),void this.message.addDangerMessage(D)}this.runBulkAction(t)}}shouldDisplay(){return!0}runBulkAction(t){const n=`bulk-${t.action.params.bulkAction}`,o=this.buildActionInput(n,t);this.asyncAction.run(n,o).subscribe(f=>{this.handleProcessResult(f,t)})}buildActionInput(t,n){const o=[];n.listStore.metadata.listView.fields.forEach(j=>{o.push(j.name)});const f={action:t,module:n.listStore.getModuleName(),criteria:null,sort:null,ids:null,fields:o,payload:{panelRecord:n.store.recordStore.getBaseStaging()}},D=n.listStore.recordList.selection;return D.all&&D.count>n.listStore.recordList.records.length&&(f.criteria=n.listStore.recordList.criteria,f.sort=n.listStore.recordList.sort),D.all&&D.count<=n.listStore.recordList.records.length&&(f.ids=[],n.listStore.recordList.records.forEach(j=>{n.ids.push(j.id)})),D.all||(f.ids=Object.keys(D.selected)),f}handleProcessResult(t,n){t.data&&t.data.reload&&(n.listStore.recordList.clearSelection(),n.listStore.load(!1).pipe((0,M.take)(1)).subscribe()),t.data&&t.data.dataUpdated&&n.listStore.triggerDataUpdate(),n.listStore.closeRecordPanel()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Tl))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),bN=(()=>{class r extends js{constructor(t,n){super(),t.modes.forEach(o=>this.actions[o][t.key]=t),n.modes.forEach(o=>this.actions[o][n.key]=n)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(fk),e.\u0275\u0275inject(mA))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),gA=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.store=t,this.message=n,this.confirmation=o,this.selectModalService=f,this.asyncAction=D,this.metadata=j,this.appMetadataStore=fe}getBulkActions(){return this.store.metadata$.pipe((0,M.map)(t=>t.listView.bulkActions))}executeBulkAction(t){const n=this.store.recordList.selection,o=this.store.metadata.listView.bulkActions[t],f=`bulk-${t}`;if(this.message.removeMessages(),sf(o.params.allowAll)&&n.all)return void this.message.addDangerMessage(this.store.appStrings.LBL_SELECT_ALL_NOT_ALLOWED);if(o.params.min&&n.count<o.params.min){let Lr=this.store.appStrings.LBL_TOO_FEW_SELECTED;return Lr=Lr.replace("{min}",o.params.min),void this.message.addDangerMessage(Lr)}if(o.params.max&&n.count>o.params.max){let Lr=this.store.appStrings.LBL_TOO_MANY_SELECTED;return Lr=Lr.replace("{max}",o.params.max),void this.message.addDangerMessage(Lr)}const D=[];this.store.metadata.listView.fields.forEach(Lr=>{D.push(Lr.name)});const j={action:f,module:this.store.getModuleName(),criteria:null,sort:null,ids:null,fields:D};n.all&&n.count>this.store.recordList.records.length&&(j.criteria=this.store.recordList.criteria,j.sort=this.store.recordList.sort),n.all&&n.count<=this.store.recordList.records.length&&(j.ids=[],this.store.recordList.records.forEach(Lr=>{j.ids.push(Lr.id)})),n.all||(j.ids=Object.keys(n.selected));const fe=o&&o.params||{},Ne=fe.displayConfirmation||!1,vt=fe.confirmationLabel||"",ln=o.params&&o.params.selectModal,Hn=ln&&ln.module,Oi=o.params&&o.params.recordPanel;Oi?this.store.openRecordPanel(Oi):Ne?this.confirmation.showModal(vt,()=>{Hn?this.showSelectModal(ln.module,f,j):this.runBulkAction(f,j)}):Hn?this.showSelectModal(ln.module,f,j):this.runBulkAction(f,j)}showSelectModal(t,n,o){this.selectModalService.showSelectModal(t,f=>{if(f){const{fields:D,formGroup:j,...fe}=f;o.modalRecord=fe}this.runBulkAction(n,o)})}runBulkAction(t,n){this.asyncAction.run(t,n).subscribe(o=>{this.handleProcessResult(o)})}handleProcessResult(t){t?.data&&t?.data?.reload&&(this.store.recordList.clearSelection(),this.store.load(!1).pipe((0,M.take)(1)).subscribe()),t?.data&&t?.data?.dataUpdated&&this.store.triggerDataUpdate(),this.reloadMetadata(this.store.getModuleName(),t)}reloadMetadata(t,n){const o=[];this.shouldReloadRecentlyViewed(n)&&o.push(this.metadata.typeKeys.recentlyViewed),this.shouldReloadFavorites(n)&&o.push(this.metadata.typeKeys.favorites),o&&o.length&&this.metadata.reloadModuleMetadata(t,o,!1).pipe((0,M.take)(1)).subscribe(),this.shouldReloadGlobalRecentlyViewed(n)&&this.appMetadataStore.load(t,["globalRecentlyViewed"],!1).pipe((0,M.take)(1)).subscribe()}shouldReloadGlobalRecentlyViewed(t){return!(!t?.data||!t?.data?.reloadGlobalRecentlyViewed)}shouldReloadRecentlyViewed(t){return!(!t?.data||!t?.data?.reloadRecentlyViewed)}shouldReloadFavorites(t){return!(!t?.data||!t.data?.reloadFavorites)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),CN=(()=>{class r{constructor(t,n,o,f,D,j){this.message=t,this.confirmation=n,this.selectModalService=o,this.asyncAction=f,this.metadata=D,this.appMetadataStore=j}create(t){return new gA(t,this.message,this.confirmation,this.selectModalService,this.asyncAction,this.metadata,this.appMetadataStore)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),DN=(()=>{class r{constructor(t){this.store=t}getConfig(){return{savedFilterEdit:!0,displayHeader:!0,module:this.store.getModuleName(),filter$:this.store.openFilter$,savedFilters$:this.store.filterList.records$,searchFields$:this.store.metadata$.pipe((0,M.map)(t=>{if(!t||!t.search)return{};const n=t.search;let o="advanced";return n?.layout?.advanced||(o="basic"),n?.layout[o]})),listFields:this.store.metadata.listView.fields,onClose:()=>{this.store.showFilters=!1},onSearch:()=>{this.store.showFilters=!1},updateFilter:(t,n=!0)=>{const o={};o[t.key]=t,this.store.setFilters(o,n)},resetFilter:t=>{this.store.resetFilters(t)},addSavedFilter:t=>{this.store.addSavedFilter(t)},removeSavedFilter:t=>{this.store.removeSavedFilter(t)},setOpenFilter:t=>{this.store.setOpenFilter(t)}}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),vA=(()=>{class r extends bF{constructor(t,n,o,f,D,j,fe,Ne,vt){super(n,o,f,D,j,fe,Ne,vt),this.store=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.language=j,this.selectModalService=fe,this.metadata=Ne,this.appMetadataStore=vt}getActions(t=null){return this.store.lineActions$.pipe((0,i.combineLatestWith)((0,i.of)("list").pipe((0,M.shareReplay)())),(0,M.map)(([n,o])=>this.parseModeActions(n,o,t)))}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.store.recordList.clearSelection(),this.store.recordList.resetPagination()}getMode(){return"list"}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(S2),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();class wN extends kp{navigateBack(v,t,n,o,f){let D=v.getReturnModule(t),j=v.getReturnAction(t),fe=v.getReturnId(t);n!==fe&&(D===o&&"record"===j&&fe!==n||!D||!j||v.navigateBack(f,o,t))}}let pk=(()=>{class r extends wN{constructor(){super(),this.key="async-process",this.modes=np}run(t){}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),_A=(()=>{class r extends wN{constructor(){super(),this.key="select-columns",this.modes=["list"]}run(t){t.store.openColumnChooserDialog()}shouldDisplay(t){return!0}static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),xN=(()=>{class r extends js{constructor(t,n){super(),this.async=t,this.selectColumns=n,n.modes.forEach(o=>this.actions[o][n.key]=n),t.modes.forEach(o=>this.actions[o][t.key]=t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(pk),e.\u0275\u0275inject(_A))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),hk=(()=>{class r extends Vt{constructor(t,n,o,f,D,j,fe,Ne,vt){super(n,o,f,D,j,fe,Ne,vt),this.store=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.language=j,this.selectModalService=fe,this.metadata=Ne,this.appMetadataStore=vt}buildActionData(t,n){return{store:this.store,action:t}}getActionName(t){return`table-action-${t.key}`}buildActionInput(t,n,o,f=null){const D=this.store.recordList.selection,j=[];this.store.metadata.listView.fields.forEach(Ne=>{j.push(Ne.name)});const fe={action:n,module:o,criteria:null,sort:null,ids:null,fields:j,params:t&&t.params||[]};return D.all&&D.count>this.store.recordList.records.length&&(fe.criteria=this.store.recordList.criteria,fe.sort=this.store.recordList.sort),D.all&&D.count<=this.store.recordList.records.length&&(fe.ids=[],this.store.recordList.records.forEach(Ne=>{fe.ids.push(Ne.id)})),D.all||(fe.ids=Object.keys(D.selected)),fe}getActions(t=null){return this.store.tableActions$.pipe((0,i.combineLatestWith)((0,i.of)("list").pipe((0,M.shareReplay)())),(0,M.map)(([n,o])=>this.parseModeActions(n,o,t)))}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.store.recordList.clearSelection(),this.store.recordList.resetPagination()}getMode(){return"list"}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(xN),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),yA=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.actionManager=t,this.asyncActionService=n,this.message=o,this.confirmation=f,this.language=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t){return new hk(t,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.language,this.selectModalService,this.metadata,this.appMetadataStore)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(xN),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),SN=(()=>{class r extends Em{constructor(t,n,o,f,D,j,fe,Ne,vt,ln){super(f,D,j,fe,o,Ne,vt,ln),this.store=t,this.listStore=n,this.language=o,this.actionManager=f,this.asyncActionService=D,this.message=j,this.confirmation=fe,this.selectModalService=Ne,this.metadata=vt,this.appMetadataStore=ln,this.collapseButtons=!1}getActions(t){return this.store.meta$.pipe((0,i.combineLatestWith)(this.store.mode$,this.store.stagingRecord$,this.language.vm$),(0,M.map)(([n,o,f,D])=>o&&n?this.parseModeActions(n.actions,o):[]))}buildActionData(t,n){return{store:this.store,listStore:this.listStore,action:t}}getMode(){return this.store.getMode()}getModuleName(t){return this.store.getModuleName()}reload(t,n,o){this.listStore.load(!1).pipe((0,M.take)(1)).subscribe()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(NF),e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bN),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),mk=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne){this.language=t,this.actionManager=n,this.asyncActionService=o,this.message=f,this.confirmation=D,this.selectModalService=j,this.metadata=fe,this.appMetadataStore=Ne}create(t,n){const o=new SN(t,n,this.language,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.selectModalService,this.metadata,this.appMetadataStore),f=n?.recordPanelConfig?.collapseActions??null;return null!==f&&(o.collapseButtons=f),o}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(bN),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(ht),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),gM=(()=>{class r{constructor(t,n,o,f){this.store=t,this.recordPanelStoreFactory=n,this.actionAdapterFactory=o,this.recordManager=f}getConfig(){const t=this.createStore();return{module:this.getModule(),title:this.store.recordPanelConfig&&this.store.recordPanelConfig.title||"",store:t,meta:this.store.recordPanelConfig,actions:this.createActionAdapter(t),onClose:()=>{this.store.closeRecordPanel()}}}getModule(){return this.store.recordPanelConfig.module||this.store.getModuleName()}getViewMode(){return this.store.recordPanelConfig.mode||"edit"}createStore(){const t=this.recordPanelStoreFactory.create(),n=this.recordManager.buildEmptyRecord(this.getModule());return t.setMetadata(this.store.recordPanelConfig),t.initRecord(n,this.getViewMode(),!1),t}createActionAdapter(t){return this.actionAdapterFactory.create(t,this.store)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(aL),e.\u0275\u0275inject(mk),e.\u0275\u0275inject(Dd))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),nO=(()=>{class r{constructor(t,n){this.store=t,this.metadata=n,this.config$=this.metadata.listMetadata$.pipe((0,i.combineLatestWith)(this.store.showSidebarWidgets$,this.store.widgets$),(0,M.map)(([o,f,D])=>(o.sidebarWidgets&&o.sidebarWidgets.length&&o.sidebarWidgets.forEach(j=>{j&&"data-update"===j.refreshOn?j.reload$=this.store.dataSetUpdate$.pipe((0,M.map)(()=>!0)):j&&"data-reload"===j.refreshOn&&(j.reload$=this.store.records$.pipe((0,M.map)(()=>!0)))}),{widgets:o.sidebarWidgets||[],show:f,widgetsEnabled:D})))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(Fs))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),EN=(()=>{class r{constructor(t,n,o,f,D,j,fe,Ne,vt,ln,Hn,Oi,Lr){this.store=t,this.metadata=n,this.actionManager=o,this.asyncActionService=f,this.message=D,this.confirmation=j,this.language=fe,this.bulkActionsAdapterFactory=Ne,this.listviewTableActionsAdapterFactory=vt,this.selectModalService=ln,this.preferences=Hn,this.systemConfigs=Oi,this.appMetadataStore=Lr}getTable(){return{showHeader:!0,showFooter:!0,module:this.store.getModuleName(),columns:this.store.columns$,lineActions:this.getLineActionsDataSource(),selection$:this.store.selection$,sort$:this.store.sort$,maxColumns$:(0,i.of)(4),loading$:this.store.recordList.loading$,dataSource:this.store.recordList,selection:this.store.recordList,bulkActions:this.getBulkActionsDataSource(this.store),tableActions:this.getTableActions(this.store),pagination:this.store.recordList,paginationType:this.preferences.getUserPreference("listview_pagination_type")??this.systemConfigs.getConfigValue("listview_pagination_type"),maxListHeight:this.preferences.getUserPreference("listview_max_height")??this.systemConfigs.getConfigValue("listview_max_height"),toggleRecordSelection:t=>{this.store.recordList.toggleSelection(t)},updateSorting:(t,n)=>{this.store.recordList.updateSorting(t,n),this.store.updateSortLocalStorage()},loadMore:()=>{const t=this.preferences.getUserPreference("list_max_entries_per_page")??this.systemConfigs.getConfigValue("list_max_entries_per_page"),n=this.store.recordList.getPagination(),f=Number(n.pageSize||0)+Number(t);this.store.recordList.setPageSize(f),this.store.recordList.updatePagination(n.current)},allLoaded:()=>{const t=this.store.recordList.getPagination();return!!t&&(Number(t.pageLast)>=Number(t.total)||Number(t.pageSize)>=Number(t.total))}}}getLineActionsDataSource(){return new vA(this.store,this.actionManager,this.asyncActionService,this.message,this.confirmation,this.language,this.selectModalService,this.metadata,this.appMetadataStore)}getBulkActionsDataSource(t){return this.bulkActionsAdapterFactory.create(t)}getTableActions(t){return this.listviewTableActionsAdapterFactory.create(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(Qp),e.\u0275\u0275inject(Fs),e.\u0275\u0275inject(S2),e.\u0275\u0275inject(Tl),e.\u0275\u0275inject(bo),e.\u0275\u0275inject($e),e.\u0275\u0275inject(Kr),e.\u0275\u0275inject(CN),e.\u0275\u0275inject(yA),e.\u0275\u0275inject(ht),e.\u0275\u0275inject($a),e.\u0275\u0275inject(zo),e.\u0275\u0275inject(oo))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})(),uE=(()=>{class r{constructor(t,n,o){this.systemConfigStore=t,this.screenSize=n,this.store=o,this.swapSizes=[],this.subs=[],this.swapSizes=this.systemConfigStore.getUi("widget_swap_screen_sizes"),this.widgetSwap$=this.screenSize.screenSize$.pipe((0,M.map)(f=>{const D=cl(this.swapSizes[f]??!1);return(null===this.widgetSwap&&!0===D||this.widgetSwap!==D&&!0===D)&&(this.store.showSidebarWidgets=!1),this.widgetSwap=D,D}))}destroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[]}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(zo),e.\u0275\u0275inject(Wd),e.\u0275\u0275inject(Qp))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac})}return r})();const KP=r=>({"col-lg-12":r});function s(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",3),e.\u0275\u0275element(2,"scrm-table",4),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngClass",e.\u0275\u0275pureFunction1(2,KP,!t.displayWidgets)),e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.tableConfig)}}function l(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",7),e.\u0275\u0275element(1,"scrm-sidebar-widget",8),e.\u0275\u0275elementEnd()),2&r){const t=v.$implicit,n=e.\u0275\u0275nextContext(3);e.\u0275\u0275advance(),e.\u0275\u0275property("config",t)("context",n.getViewContext())("context$",n.store.context$)("type",t.type)}}function d(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",5),e.\u0275\u0275template(2,l,2,4,"div",6),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(),e.\u0275\u0275styleProp("display",t.widgetDisplayType),e.\u0275\u0275classProp("mt-0",t.swapWidgets),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",t.sidebarWidgetConfig.widgets)}}function h(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275template(1,d,3,5,"ng-container",2),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!t.swapWidgets||t.swapWidgets&&t.displayWidgets)}}let w=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.store=t,this.adapter=n,this.maxColumnCalculator=o,this.languageStore=f,this.sidebarWidgetAdapter=D,this.systemConfigs=j,this.sidebarWidgetHandler=fe,this.screen=$d.Medium,this.maxColumns=5,this.displayWidgets=!0,this.swapWidgets=!1,this.widgetDisplayType="none",this.subs=[]}ngOnInit(){if(this.tableConfig=this.adapter.getTable(),this.tableConfig.maxColumns$=this.getMaxColumns(),this.store?.metadata?.listView?.maxHeight&&(this.tableConfig.maxListHeight=this.store.metadata.listView.maxHeight),!this.tableConfig?.maxListHeight){const t=this.systemConfigs.getConfigValue("ui");this.tableConfig.maxListHeight=t.listview_max_height}this.tableConfig.paginationType=this?.store?.metadata?.listView?.paginationType??this.tableConfig.paginationType,this.subs.push(this.sidebarWidgetAdapter.config$.subscribe(t=>{this.sidebarWidgetConfig=t,this.displayWidgets=this.store.widgets&&this.store.showSidebarWidgets,this.widgetDisplayType=this.getDisplay(!(!this.sidebarWidgetConfig.show||!this.sidebarWidgetConfig.widgets))})),this.subs.push(this.sidebarWidgetHandler.widgetSwap$.subscribe(t=>{this.swapWidgets=t}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.subs=[]}getMaxColumns(){return this.maxColumnCalculator.getMaxColumns(this.store.widgets$)}getDisplayWidgets(){return this.store.widgets&&this.store.showSidebarWidgets}getDisplay(t){let n="none";return t&&(n="block"),n}getViewContext(){return this.store.getViewContext()}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Qp),e.\u0275\u0275directiveInject(EN),e.\u0275\u0275directiveInject(rg),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(nO),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(uE))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-list-container"]],features:[e.\u0275\u0275ProvidersFeature([EN,rg,nO])],decls:4,vars:2,consts:[[1,"list-view-container","container-fluid","pt-2"],[1,"row"],[4,"ngIf"],[1,"col-lg-9",3,"ngClass"],[3,"config"],[1,"col-lg-3","list-widget-container","pl-0"],["class","mb-3",4,"ngFor","ngForOf"],[1,"mb-3"],[3,"config","context","context$","type"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1),e.\u0275\u0275template(2,s,3,4,"ng-container",2)(3,h,2,1,"ng-container",2),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.swapWidgets||o.swapWidgets&&!o.displayWidgets),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.sidebarWidgetConfig.widgetsEnabled))},dependencies:[ve.NgClass,ve.NgForOf,ve.NgIf,HI,XI],encapsulation:2})}return r})(),L=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,x2,Gp,fn.AngularSvgIconModule,B2]})}return r})();function z(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button-group",14),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config$",t.quickFilters.config$)("klass","quick-filter-button")}}function ae(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",9)(1,"div",10),e.\u0275\u0275element(2,"scrm-label",11),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",12),e.\u0275\u0275template(4,z,1,2,"scrm-button-group",13),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.quickFilters.config$)}}function xe(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15)(1,"div",16)(2,"div",17),e.\u0275\u0275element(3,"scrm-list-filter",18),e.\u0275\u0275elementEnd()()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("config",t.filterAdapter.getConfig())}}function qe(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",15)(1,"div",16)(2,"div",17),e.\u0275\u0275element(3,"scrm-record-panel",18),e.\u0275\u0275elementEnd()()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("config",t.recordPanelConfig)}}let ft=(()=>{class r{constructor(t,n,o,f,D){this.filterAdapter=t,this.listStore=n,this.moduleNavigation=o,this.recordPanelAdapter=f,this.quickFilters=D,this.actionPanel="",this.showQuickFilters=!1,this.enableQuickFilters=!1,this.subs=[]}get moduleTitle(){return this.moduleNavigation.getModuleLabel(this.listStore.vm.appData.module,this.listStore.vm.appData.language.appListStrings)}ngOnInit(){this.listStore.actionPanel$.subscribe(t=>{this.actionPanel=t,this.recordPanelConfig="recordPanel"===this.actionPanel?this.recordPanelAdapter.getConfig():null}),this.subs.push(this.quickFilters.breakdown$.subscribe(t=>{this.showQuickFilters=cl(t)})),this.subs.push(this.quickFilters.enabled$.subscribe(t=>{this.enableQuickFilters=cl(t??!1)}))}ngOnDestroy(){this.subs.forEach(t=>t.unsubscribe()),this.recordPanelConfig=null}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(DN),e.\u0275\u0275directiveInject(Qp),e.\u0275\u0275directiveInject(Oc),e.\u0275\u0275directiveInject(gM),e.\u0275\u0275directiveInject(UI))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-list-header"]],features:[e.\u0275\u0275ProvidersFeature([DN,gM])],decls:12,vars:10,consts:[[1,"list-view-header"],[1,"row","mr-0","justify-content-md-between"],[1,"custom-col-4","d-none","d-md-flex","align-items-center"],[1,"list-view-title",3,"title"],[1,"custom-col-8","d-flex","align-items-center"],["class","d-flex align-items-baseline w-100 justify-content-end pr-3",4,"ngIf"],[1,"list-view-hr-container"],[1,"list-view-hr"],["class","container-fluid pt-2 small-font",4,"ngIf"],[1,"d-flex","align-items-baseline","w-100","justify-content-end","pr-3"],[1,"text-nowrap","text-muted","fs-70","pl-1","mr-1"],["labelKey","LBL_QUICK_FILTERS"],[1,"pr-xxl-1","mr-xxl-1"],[3,"config$","klass",4,"ngIf"],[3,"config$","klass"],[1,"container-fluid","pt-2","small-font"],[1,"row"],[1,"col"],[3,"config"]],template:function(n,o){1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",0)(2,"div",1)(3,"div",2),e.\u0275\u0275element(4,"scrm-module-title",3),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"div",4),e.\u0275\u0275element(6,"scrm-settings-menu"),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(7,ae,5,1,"div",5),e.\u0275\u0275elementStart(8,"div",6),e.\u0275\u0275element(9,"hr",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(10,xe,4,1,"div",8)(11,qe,4,1,"div",8),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275classProp("justify-content-center",!(o.showQuickFilters&&o.enableQuickFilters))("justify-content-end",o.showQuickFilters&&o.enableQuickFilters),e.\u0275\u0275advance(2),e.\u0275\u0275property("title",o.moduleTitle),e.\u0275\u0275advance(),e.\u0275\u0275classProp("pr-3",o.showQuickFilters&&o.enableQuickFilters),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",o.showQuickFilters&&o.enableQuickFilters),e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf","filters"===o.actionPanel),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","recordPanel"===o.actionPanel&&o.recordPanelConfig))},dependencies:[ve.NgIf,co,_2,I2,FF,nb,Pa],encapsulation:2})}return r})(),Xt=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Do,jI,y2,fn.AngularSvgIconModule,A2,sL,Fu,Ea]})}return r})();function Ln(r,v){1&r&&(e.\u0275\u0275elementStart(0,"div",1),e.\u0275\u0275element(1,"scrm-list-header")(2,"scrm-list-container"),e.\u0275\u0275elementEnd())}let zn=(()=>{class r{constructor(t,n,o,f,D){this.appState=t,this.listStore=n,this.quickFilters=o,this.sidebarWidgetHandler=f,this.recordPaginationService=D,this.vm$=null}ngOnInit(){this.appState.removeAllPrevRoutes(),this.module=this.appState.getModule(),this.listSub=this.listStore.init(this.module).subscribe(),this.vm$=this.listStore.vm$}ngOnDestroy(){this.listSub&&this.listSub.unsubscribe(),this.updateListLocalStorage(),this.quickFilters.destroy(),this.sidebarWidgetHandler.destroy(),this.listStore.destroy()}updateListLocalStorage(){this.recordPaginationService.updateRecordListLocalStorage(this.listStore.recordList.records,this.listStore.recordList.pagination)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(Qp),e.\u0275\u0275directiveInject(UI),e.\u0275\u0275directiveInject(uE),e.\u0275\u0275directiveInject(lE))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-list"]],features:[e.\u0275\u0275ProvidersFeature([Qp,UI,uE])],decls:2,vars:3,consts:[["class","list-view",4,"ngIf"],[1,"list-view"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,Ln,3,0,"div",0),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[ve.NgIf,ft,w,ve.AsyncPipe],encapsulation:2})}return r})(),xi=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Xt,L,pa]})}return r})(),Nr=(()=>{class r{onEnterKey(){this.verifyCode()}constructor(t,n,o,f,D,j,fe){this.authService=t,this.message=n,this.appState=o,this.notificationStore=f,this.router=D,this.baseRoute=j,this.languageStore=fe}ngOnInit(){this.submitCodeButtonConfig={klass:"submit-button login-button",onClick:()=>{this.verifyCode()},labelKey:"LBL_VERIFY_2FA",titleKey:""}}verifyCode(){this.authService.check2fa(this.authCode).subscribe(n=>{if(cl(n?.login_success)&&cl(n?.two_factor_complete))return this.message.addSuccessMessageByKey("LBL_FACTOR_AUTH_SUCCESS"),this.baseRoute.isNativeAuth()&&(window.location.href=this.baseRoute.removeNativeAuth()),this.appState.updateInitialAppLoading(!0),this.authService.setLanguage(n),this.authService.isUserLoggedIn.next(!0),this.authService.setCurrentUser(n),this.notificationStore.enableNotifications(),this.notificationStore.refreshNotifications(),n?.redirect&&n?.redirect?.route?void this.router.navigate([n.redirect.route],{queryParams:n.redirect.queryParams??{}}).then():void 0;if("2fa_failed"===n?.error)return void this.message.addDangerMessageByKey("LBL_FACTOR_AUTH_FAIL");const f=this.getTooManyFailedMessage("Too many failed login attempts, please try again later.");this.message.addDangerMessage(f)})}getTooManyFailedMessage(t){let n=this.languageStore.getFieldLabel("LOGIN_TOO_MANY_FAILED");return n||(n=t),n}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(tl),e.\u0275\u0275directiveInject(hs),e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(Ns),e.\u0275\u0275directiveInject(Kr))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-2fa-check"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keyup.control.enter",function(){return o.onEnterKey()})},decls:8,vars:2,consts:[[1,"d-flex","flex-column","pt-4","align-items-center"],["labelKey","LBL_ENTER_AUTH_APP_2FA_CODE"],["id","auth_code","type","text","autocomplete","off","name","auth_code",1,"mb-2","mt-2","pl-0",3,"ngModelChange","ngModel"],["id","submit-2fa-code","type","submit",3,"config"],[1,"small","mt-2","text-muted"],["labelKey","LBL_PROBLEMS_GENERATING_CODE"],[1,"small","mb-2","text-muted"],["labelKey","LBL_BACKUP_CODES_FALLBACK_INSTRUCTIONS"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275element(1,"scrm-label",1),e.\u0275\u0275elementStart(2,"input",2),e.\u0275\u0275twoWayListener("ngModelChange",function(D){return e.\u0275\u0275twoWayBindingSet(o.authCode,D)||(o.authCode=D),D}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(3,"scrm-button",3),e.\u0275\u0275elementStart(4,"div",4),e.\u0275\u0275element(5,"scrm-label",5),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",6),e.\u0275\u0275element(7,"scrm-label",7),e.\u0275\u0275elementEnd()()),2&n&&(e.\u0275\u0275advance(2),e.\u0275\u0275twoWayProperty("ngModel",o.authCode),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.submitCodeButtonConfig))},dependencies:[Pa,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,xc],encapsulation:2})}return r})();function go(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"option",20),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){let t;const n=v.$implicit,o=e.\u0275\u0275nextContext(3);e.\u0275\u0275property("selected",(null!==(t=o.language)&&void 0!==t?t:"en_us")===n)("value",n),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",o.getEnabledLanguages()[n]," ")}}function Oo(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",14)(1,"div",9)(2,"label",15),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275element(4,"div",16),e.\u0275\u0275elementStart(5,"div",9)(6,"div",17)(7,"select",18,1),e.\u0275\u0275listener("change",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275reference(8),f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(f.onLanguageSelect(o.value))}),e.\u0275\u0275template(9,go,2,3,"option",19),e.\u0275\u0275elementEnd()()()()}if(2&r){const t=e.\u0275\u0275nextContext().ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate(t.appStrings.LBL_LANGUAGE),e.\u0275\u0275advance(6),e.\u0275\u0275property("ngForOf",n.getEnabledLanguagesKeys())}}function Ar(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",29),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.appStrings.ERR_MISSING_REQUIRED_FIELDS," ")}}function ma(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",29),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.appStrings.ERR_MISSING_REQUIRED_FIELDS," ")}}function oc(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",30)(1,"a",31),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.flipCard())}),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()}if(2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate1(" ",t.appStrings.LBL_LOGIN_FORGOT_PASSWORD," ")}}function qu(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",21)(1,"div",17),e.\u0275\u0275element(2,"scrm-image",22),e.\u0275\u0275elementStart(3,"input",23,2),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.uname,o)||(f.uname=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,Ar,2,1,"div",24),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",17),e.\u0275\u0275element(7,"scrm-image",25),e.\u0275\u0275elementStart(8,"input",26,3),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.passw,o)||(f.passw=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(10,ma,2,1,"div",24),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(11,"button",27),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t),e.\u0275\u0275nextContext();const o=e.\u0275\u0275reference(2),f=e.\u0275\u0275nextContext();return o.control.markAllAsTouched(),e.\u0275\u0275resetView(o.valid&&f.doLogin())}),e.\u0275\u0275text(12),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(13,oc,3,1,"div",28),e.\u0275\u0275elementEnd()}if(2&r){const t=e.\u0275\u0275reference(4),n=e.\u0275\u0275reference(9),o=e.\u0275\u0275nextContext().ngIf,f=e.\u0275\u0275nextContext();e.\u0275\u0275property("@fade",void 0),e.\u0275\u0275advance(3),e.\u0275\u0275classProp("is-invalid",t.invalid&&t.touched),e.\u0275\u0275propertyInterpolate("placeholder",o.appStrings.LBL_USER_NAME),e.\u0275\u0275twoWayProperty("ngModel",f.uname),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.invalid&&t.touched),e.\u0275\u0275advance(3),e.\u0275\u0275classProp("is-invalid",n.invalid&&n.touched),e.\u0275\u0275propertyInterpolate("placeholder",o.appStrings.LBL_PASSWORD),e.\u0275\u0275twoWayProperty("ngModel",f.passw),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.invalid&&n.touched),e.\u0275\u0275advance(),e.\u0275\u0275property("scrm-button-loading",f.loading),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",o.appStrings.LBL_LOGIN_BUTTON_LABEL," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.showForgotPassword)}}function Gd(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",29),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.appStrings.ERR_MISSING_REQUIRED_FIELDS," ")}}function qh(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",29),e.\u0275\u0275text(1),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2).ngIf;e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",t.appStrings.ERR_MISSING_REQUIRED_FIELDS," ")}}function dE(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",32)(1,"div",17),e.\u0275\u0275element(2,"scrm-image",22),e.\u0275\u0275elementStart(3,"input",23,2),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.uname,o)||(f.uname=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(5,Gd,2,1,"div",24),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(6,"div",17),e.\u0275\u0275element(7,"scrm-image",33),e.\u0275\u0275elementStart(8,"input",34,4),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext(2);return e.\u0275\u0275twoWayBindingSet(f.email,o)||(f.email=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(10,qh,2,1,"div",24),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(11,"button",35),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t),e.\u0275\u0275nextContext();const o=e.\u0275\u0275reference(2),f=e.\u0275\u0275nextContext();return o.control.markAllAsTouched(),e.\u0275\u0275resetView(o.valid&&f.recoverPassword())}),e.\u0275\u0275text(12),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(13,"div")(14,"a",36),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.flipCard())}),e.\u0275\u0275text(15),e.\u0275\u0275elementEnd()()()}if(2&r){const t=e.\u0275\u0275reference(4),n=e.\u0275\u0275reference(9),o=e.\u0275\u0275nextContext().ngIf,f=e.\u0275\u0275nextContext();e.\u0275\u0275property("@fade",void 0),e.\u0275\u0275advance(3),e.\u0275\u0275classProp("is-invalid",t.invalid&&t.touched),e.\u0275\u0275propertyInterpolate("placeholder",o.appStrings.LBL_USER_NAME),e.\u0275\u0275twoWayProperty("ngModel",f.uname),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.invalid&&t.touched),e.\u0275\u0275advance(3),e.\u0275\u0275classProp("is-invalid",n.invalid&&n.touched),e.\u0275\u0275propertyInterpolate("placeholder",o.appStrings.LBL_EMAIL),e.\u0275\u0275twoWayProperty("ngModel",f.email),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",n.invalid&&n.touched),e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate1(" ",o.appStrings.LBL_GENERATE_PASSWORD_BUTTON_TITLE," "),e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate1(" ",o.appStrings.LBL_BACK," ")}}function nx(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",32)(1,"div",17),e.\u0275\u0275element(2,"scrm-2fa-check",37),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div")(4,"a",36),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(o.returnToLogin())}),e.\u0275\u0275text(5),e.\u0275\u0275elementEnd()()()}if(2&r){const t=e.\u0275\u0275nextContext().ngIf;e.\u0275\u0275property("@fade",void 0),e.\u0275\u0275advance(5),e.\u0275\u0275textInterpolate1(" ",t.appStrings.LBL_BACK," ")}}function bA(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",6)(1,"form",7,0)(3,"div",8)(4,"div",9),e.\u0275\u0275element(5,"scrm-logo-ui"),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(6,Oo,10,2,"div",10),e.\u0275\u0275elementStart(7,"div",11),e.\u0275\u0275template(8,qu,14,14,"div",12)(9,dE,16,13,"div",13)(10,nx,6,2,"div",13),e.\u0275\u0275elementEnd()()()),2&r){const t=v.ngIf,n=e.\u0275\u0275nextContext();e.\u0275\u0275advance(6),e.\u0275\u0275property("ngIf",t.showLanguages&&"2fa"!==n.cardState()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf","front"===n.cardState()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","back"===n.cardState()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf","2fa"===n.cardState())}}let gk=(()=>{class r{constructor(t,n,o,f,D,j,fe){this.router=t,this.auth=n,this.message=o,this.configs=f,this.languageStore=D,this.recoverPasswordService=j,this.appState=fe,this.hidden=!0,this.loading=!1,this.error="",this.uname="",this.passw="",this.email="",this.cardState=(0,e.signal)("front"),this.systemConfigs$=this.configs.configs$,this.appStrings$=this.languageStore.appStrings$,this.language=null,this.vm$=this.systemConfigs$.pipe((0,i.combineLatestWith)(this.appStrings$),(0,M.map)(([Ne,vt])=>{let ln=!1,Hn=!1;return Ne.languages&&Ne.languages.items&&Ne.login_language.value&&(ln=Object.keys(Ne.languages.items).length>1),Ne.passwordsetting&&Ne.passwordsetting.items&&(Hn=[!0,"1","true"].includes(Ne.passwordsetting.items.forgotpasswordON)),{systemConfigs:Ne,appStrings:vt,showLanguages:ln,showForgotPassword:Hn}})),this.loading=!1,this.hidden=!1,this.language=null}ngOnInit(){this.setCurrentLanguage(),this.appState.removeAllPrevRoutes()}onLanguageSelect(t){t&&t!==this.language&&this.changeLanguage(t)}changeLanguage(t){this.language=t;let n=!1;this?.appState?.updateLoading&&(this.appState.updateLoading("change-language",!0),n=!0),this.languageStore.changeLanguage(t,!0).pipe((0,M.tap)(()=>{n&&this.appState.updateLoading("change-language",!1)})).subscribe()}getEnabledLanguages(){return this.languageStore.getEnabledLanguages()}getEnabledLanguagesKeys(){return Object.keys(this.languageStore.getEnabledLanguages()??{})??[]}flipCard(){"front"===this.cardState()?this.cardState.set("back"):this.cardState.set("front")}returnToLogin(){this.cardState.set("front"),this.auth.isUserLoggedIn.next(!1),this.auth.handleInvalidSession("LBL_2FA_LOGIN_CANCEL")}doLogin(){this.loading=!0,this.auth.doLogin(this.uname,this.passw,this.onLoginSuccess.bind(this),this.onLoginError.bind(this),this.onTwoFactor.bind(this))}recoverPassword(){this.recoverPasswordService.run(this.uname,this.email).subscribe(t=>{this.message.log("Recover Password Status: "+t.status);let n="addSuccessMessageByKey";"error"===t.status&&(n="addDangerMessageByKey"),t.messages&&t.messages.forEach(o=>{this.message[n](o)})},()=>{this.message.log("Recover Password failed"),this.message.addDangerMessageByKey("ERR_AJAX_LOAD_FAILURE")})}onLoginSuccess(t){this.loading=!1,this.message.log("Login success"),this.message.removeMessages(),this.auth.setLanguage(t)}onLoginError(t){this.loading=!1,this.message.log("Login failed");let f=this.languageStore.getFieldLabel("LOGIN_INCORRECT");const D=t?.error?.error??"";"string"==typeof D&&D.includes("Too many failed login attempts, please try again in")&&(f=this.getTooManyFailedMessage("Too many failed login attempts, please try again later.")),f||(f="Login credentials incorrect, please try again."),this.message.addDangerMessage(f)}onTwoFactor(t){this.cardState.set("2fa")}getTooManyFailedMessage(t){let n=this.languageStore.getFieldLabel("LOGIN_TOO_MANY_FAILED");return n||(n=t),n}setCurrentLanguage(){let t=this.languageStore.getSelectedLanguage()??"";const n=this.languageStore.getActiveLanguage();if(t||(t=n),this.languageStore.isLanguageEnabled(t)||(t=""),this.language&&t===this.language)return;const o=this.configs.getConfigValue("default_language")??"en_us";t||(t=o),this.languageStore.isLanguageEnabled(t)||(t=this.languageStore.getFirstLanguage()),this.language=t,this.changeLanguage(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(zo),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(KL),e.\u0275\u0275directiveInject(tl))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-login-ui"]],decls:2,vars:3,consts:[["loginForm","ngForm"],["languageSelect",""],["username","ngModel"],["password","ngModel"],["mail","ngModel"],["class","login-view full-height-view d-flex align-items-center",4,"ngIf"],[1,"login-view","full-height-view","d-flex","align-items-center"],["name","login",1,"login-form"],[1,"form-row","form-group"],[1,"col"],["class","form-row",4,"ngIf"],[1,"form-row","fade-card"],["class","fade-card-front col",4,"ngIf"],["class","fade-card-back col",4,"ngIf"],[1,"form-row"],["for","languages",1,""],[1,"w-100"],[1,"inner-addon","left-addon"],["id","languages",3,"change"],[3,"selected","value",4,"ngFor","ngForOf"],[3,"selected","value"],[1,"fade-card-front","col"],["image","login_user"],["type","text","name","username","aria-label","Username","required","",3,"ngModelChange","ngModel","placeholder"],["class","invalid-feedback",4,"ngIf"],["image","login_password"],["type","password","name","password","aria-label","Password","required","",3,"ngModelChange","ngModel","placeholder"],["id","login-button",1,"login-button",3,"click","scrm-button-loading"],["class","forgotten-password",4,"ngIf"],[1,"invalid-feedback"],[1,"forgotten-password"],[1,"forgotten-password-link",3,"click"],[1,"fade-card-back","col"],["image","email"],["type","email","name","email","aria-label","Email","required","",3,"ngModelChange","ngModel","placeholder"],["scrm-button-loading","",1,"submit-button","login-button",3,"click"],[1,"back-link","forgotten-password-link",3,"click"],[1,"login-button"]],template:function(n,o){1&n&&(e.\u0275\u0275template(0,bA,11,4,"div",5),e.\u0275\u0275pipe(1,"async")),2&n&&e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(1,1,o.vm$))},dependencies:[Ji.\u0275NgNoValidate,Ji.NgSelectOption,Ji.\u0275NgSelectMultipleOption,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgControlStatusGroup,Ji.RequiredValidator,Ji.NgModel,Ji.NgForm,bp,ve.NgForOf,ve.NgIf,Bl,jL,Nr,ve.AsyncPipe],encapsulation:2,data:{animation:[(0,sr.trigger)("fade",[(0,sr.transition)(":enter",(0,sr.useAnimation)(Bv.fadeIn,{params:{timing:.5,delay:0}}))])]}})}return r})();const ix=[{path:"",component:gk}];let n1=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[Ea,F1,Qb,Oa]})}return r})(),JC=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[Ji.FormsModule,Qb,Wo.RouterModule.forChild(ix),ve.CommonModule,fn.AngularSvgIconModule,Vl,rN,n1]})}return r})(),qP=(()=>{class r{constructor(t){this.configs=t}getLoginURL(){return"./"}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(zo))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-logout"]],decls:11,vars:1,consts:[[1,"logged-out-view","full-height-view","d-flex","flex-column","align-items-center","justify-content-center"],[1,"logo-row","full-height-view-row"],[1,"mt-3","mb-1","page-title","full-height-view-row"],["labelKey","LBL_LOGGED_OUT_MESSAGE"],[1,"page-subtitle","full-height-view-row"],["labelKey","LBL_LOGIN_AGAIN"],[1,"text-lowercase",3,"href"],["labelKey","LBL_CLICK_HERE"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"div",0)(1,"div",1),e.\u0275\u0275element(2,"scrm-logo-ui"),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",2)(4,"h2"),e.\u0275\u0275element(5,"scrm-label",3),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",4)(7,"h5"),e.\u0275\u0275element(8,"scrm-label",5),e.\u0275\u0275elementStart(9,"a",6),e.\u0275\u0275element(10,"scrm-label",7),e.\u0275\u0275elementEnd()()()()),2&n&&(e.\u0275\u0275advance(9),e.\u0275\u0275property("href",o.getLoginURL(),e.\u0275\u0275sanitizeUrl))},dependencies:[Pa,bp],encapsulation:2})}return r})(),vk=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Ea,Qb]})}return r})(),C3=(()=>{class r{constructor(t){this.processService=t}generate(){return this.processService.submit("generate-backup-codes",{}).pipe((0,M.take)(1))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bf))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),_k=(()=>{class r{constructor(t){this.processService=t}checkCode(t){return this.processService.submit("check-two-factor-code",{auth_code:t}).pipe((0,M.take)(1))}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275inject(bf))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})(),iO=(()=>{class r{onEnterKey(){this.checkCode()}constructor(t,n,o,f){this.activeModal=t,this.language=n,this.message=o,this.checkTwoFactorCode=f}ngOnInit(){this.checkCodeButtonConfig={klass:"btn btn-sm btn-main",onClick:()=>{this.checkCode()},labelKey:"LBL_VERIFY_2FA",titleKey:""}}checkCode(){this.checkTwoFactorCode.checkCode(this.authCode).subscribe({next:n=>{this.closeModal(n.data.two_factor_complete)},error:()=>{this.message.addDangerMessageByKey("LBL_FACTOR_AUTH_FAIL")}})}closeModal(t){this.activeModal.close({two_factor_complete:t})}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(ct.NgbActiveModal),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(_k))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-2fa-modal"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keyup.control.enter",function(){return o.onEnterKey()})},decls:11,vars:3,consts:[["bodyKlass","m-0 small-font","footerKlass","border-0","headerKlass","border-0","klass","two-factor-popup",3,"closable"],["modal-body",""],[1,"d-flex","flex-column","pt-4","align-items-center"],["labelKey","LBL_ENTER_AUTH_APP_2FA_CODE",1,"pb-4"],["id","auth_code","type","text","name","auth_code","autocomplete","off",1,"mb-3","auth-input",3,"ngModelChange","ngModel"],["id","submit-2fa-code","type","submit",3,"config"],[1,"small","mt-2","text-muted"],["labelKey","LBL_PROBLEMS_GENERATING_CODE"],[1,"small","mb-2","text-muted"],["labelKey","LBL_BACKUP_CODES_FALLBACK_INSTRUCTIONS"]],template:function(n,o){1&n&&(e.\u0275\u0275elementStart(0,"scrm-modal",0)(1,"div",1)(2,"div")(3,"div",2),e.\u0275\u0275element(4,"scrm-label",3),e.\u0275\u0275elementStart(5,"input",4),e.\u0275\u0275twoWayListener("ngModelChange",function(D){return e.\u0275\u0275twoWayBindingSet(o.authCode,D)||(o.authCode=D),D}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(6,"scrm-button",5),e.\u0275\u0275elementStart(7,"div",6),e.\u0275\u0275element(8,"scrm-label",7),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(9,"div",8),e.\u0275\u0275element(10,"scrm-label",9),e.\u0275\u0275elementEnd()()()()()),2&n&&(e.\u0275\u0275property("closable",!1),e.\u0275\u0275advance(5),e.\u0275\u0275twoWayProperty("ngModel",o.authCode),e.\u0275\u0275advance(),e.\u0275\u0275property("config",o.checkCodeButtonConfig))},dependencies:[qm,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,Pa,xc],encapsulation:2})}return r})(),QP=(()=>{class r{constructor(t){this.sanitizer=t}transform(t){return this.sanitizer.bypassSecurityTrustHtml(t)}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(L0.up,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"trustHtml",type:r,pure:!0})}return r})();function YP(r,v){1&r&&(e.\u0275\u0275elementStart(0,"span",22),e.\u0275\u0275element(1,"scrm-label",23),e.\u0275\u0275elementEnd())}function TN(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",24),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.enableAppMethodButtonConfig)}}function D3(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",24),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.cancelAppMethodButtonConfig)}}function w3(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",24),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275property("config",t.disableAppMethodButtonConfig)}}function x3(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",38)(1,"a",39),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.setShowSecret(!0))}),e.\u0275\u0275element(2,"scrm-label",40),e.\u0275\u0275elementEnd()()}}function S3(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",38)(1,"a",39),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(t);const o=e.\u0275\u0275nextContext(3);return e.\u0275\u0275resetView(o.setShowSecret(!1))}),e.\u0275\u0275element(2,"scrm-label",41),e.\u0275\u0275elementEnd()()}}function E3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",34)(1,"div",35),e.\u0275\u0275element(2,"div",36),e.\u0275\u0275pipe(3,"trustHtml"),e.\u0275\u0275template(4,x3,3,0,"div",37)(5,S3,3,0,"div",37),e.\u0275\u0275elementEnd()()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("innerHTML",e.\u0275\u0275pipeBind1(3,3,t.qrCodeSvg),e.\u0275\u0275sanitizeHtml),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!t.showSecret()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",t.showSecret())}}function T3(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",42),e.\u0275\u0275element(1,"scrm-label",43),e.\u0275\u0275elementStart(2,"span",44),e.\u0275\u0275text(3),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(4,"scrm-button",45),e.\u0275\u0275elementEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(3),e.\u0275\u0275textInterpolate(t.secret),e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.copySecretButtonConfig)}}function To(r,v){if(1&r){const t=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",25)(1,"div",26)(2,"div",9),e.\u0275\u0275template(3,E3,6,5,"div",27),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(4,"div",9),e.\u0275\u0275template(5,T3,5,2,"div",28),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",29)(7,"div",9)(8,"div"),e.\u0275\u0275element(9,"scrm-label",30),e.\u0275\u0275elementStart(10,"div",31)(11,"input",32),e.\u0275\u0275twoWayListener("ngModelChange",function(o){e.\u0275\u0275restoreView(t);const f=e.\u0275\u0275nextContext();return e.\u0275\u0275twoWayBindingSet(f.authCode,o)||(f.authCode=o),e.\u0275\u0275resetView(o)}),e.\u0275\u0275elementEnd(),e.\u0275\u0275element(12,"scrm-button",33),e.\u0275\u0275elementEnd()()()()()}if(2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",t.qrCodeSvg),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.showSecret()),e.\u0275\u0275advance(6),e.\u0275\u0275twoWayProperty("ngModel",t.authCode),e.\u0275\u0275advance(),e.\u0275\u0275property("config",t.verifyCodeButtonConfig)}}function pd(r,v){1&r&&(e.\u0275\u0275elementStart(0,"span",22),e.\u0275\u0275element(1,"scrm-label",51),e.\u0275\u0275elementEnd())}function yk(r,v){if(1&r&&e.\u0275\u0275element(0,"scrm-button",24),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275property("config",t.regenerateBackupCodesButtonConfig)}}function Fl(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",56),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementContainerEnd()),2&r){const t=v.$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(t)}}function CA(r,v){if(1&r&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",52),e.\u0275\u0275element(2,"scrm-button",24),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(3,"div",53)(4,"div")(5,"div",54),e.\u0275\u0275template(6,Fl,3,1,"ng-container",55),e.\u0275\u0275elementEnd()()(),e.\u0275\u0275elementContainerEnd()),2&r){const t=e.\u0275\u0275nextContext(2);e.\u0275\u0275advance(2),e.\u0275\u0275property("config",t.copyBackupButtonConfig),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngForOf",t.backupCodes)}}function Pn(r,v){if(1&r&&(e.\u0275\u0275elementStart(0,"div",46)(1,"div",47)(2,"scrm-widget-panel",10)(3,"span",11),e.\u0275\u0275element(4,"scrm-image",48),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(5,"span",13),e.\u0275\u0275template(6,pd,2,0,"span",14),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(7,"span",15),e.\u0275\u0275template(8,yk,1,1,"scrm-button",16),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(9,"div",17)(10,"div",18),e.\u0275\u0275element(11,"scrm-label",49),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(12,CA,7,2,"ng-container",50),e.\u0275\u0275elementEnd()()()()),2&r){const t=e.\u0275\u0275nextContext();e.\u0275\u0275advance(2),e.\u0275\u0275property("title",t.recoveryCodesHeaderLabel),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.areRecoveryCodesGenerated()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",t.isAppMethodEnabled()),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",t.areRecoveryCodesGenerated()&&t.backupCodes)}}let Cv=(()=>{class r{onEnterKey(){this.finalize2fa()}constructor(t,n,o,f,D,j,fe,Ne){this.authService=t,this.router=n,this.message=o,this.language=f,this.userPreference=D,this.modalService=j,this.clipboard=fe,this.generateBackupCodesService=Ne,this.isAppMethodEnabled=(0,e.signal)(!1),this.areRecoveryCodesGenerated=(0,e.signal)(!1),this.isQrCodeGenerated=(0,e.signal)(!1),this.showSecret=(0,e.signal)(!1),this.title="",this.appMethodHeaderLabel="",this.recoveryCodesHeaderLabel=""}ngOnInit(){this.title=this.language.getAppString("LBL_TWO_FACTOR_AUTH"),this.appMethodHeaderLabel=this.language.getAppString("LBL_TWO_FACTOR_AUTH_APP_METHOD"),this.recoveryCodesHeaderLabel=this.language.getAppString("LBL_BACKUP_CODES");const t=this.userPreference.getUserPreference("is_two_factor_enabled")??!1;this.isAppMethodEnabled.set(t),this.areRecoveryCodesGenerated.set(t),this.showSecret.set(!1),this.initButtons()}enable2fa(){this.authService.enable2fa().subscribe({next:t=>{this.qrCodeUrl=t?.url,this.qrCodeSvg=t?.svg,this.secret=t.secret,this.areRecoveryCodesGenerated.set(!0),this.isQrCodeGenerated.set(!0)},error:()=>{this.isAppMethodEnabled.set(!1),this.areRecoveryCodesGenerated.set(!1)}})}disable2FactorAuth(){this.modalService.open(iO,{size:"lg"}).result.then(n=>{n.two_factor_complete?this.disable2fa():this.message.addDangerMessageByKey("LBL_FACTOR_AUTH_FAIL")}).catch()}cancel2fa(){this.disable2fa()}disable2fa(){this.authService.disable2fa().subscribe({next:t=>{cl(t?.two_factor_disabled)&&(this.isAppMethodEnabled.set(!1),this.areRecoveryCodesGenerated.set(!1),this.isQrCodeGenerated.set(!1),this.message.addSuccessMessageByKey("LBL_FACTOR_AUTH_DISABLE"))},error:()=>{this.isAppMethodEnabled.set(!0),this.areRecoveryCodesGenerated.set(!0)}})}getTitle(){return this.title}finalize2fa(){this.authService.finalize2fa(this.authCode).subscribe(t=>{if(cl(t?.two_factor_setup_complete??!1))return this.generateCodes(),this.message.addSuccessMessageByKey("LBL_FACTOR_AUTH_SUCCESS"),this.isAppMethodEnabled.set(!0),this.isQrCodeGenerated.set(!1),void(this.authCode="");this.message.addDangerMessageByKey("LBL_FACTOR_AUTH_FAIL")})}copyBackupCodes(){this.clipboard.copy(this.backupCodes)}copySecret(){this.clipboard.copy(this.secret)}generateCodes(){this.backupCodes=null,this.generateBackupCodesService.generate().subscribe({next:t=>{this.backupCodes=t?.data.backupCodes,this.areRecoveryCodesGenerated.set(!0)},error:()=>{this.areRecoveryCodesGenerated.set(!1)}})}generateBackupCodes(){this.modalService.open(iO,{size:"lg"}).result.then(n=>{n.two_factor_complete?(this.areRecoveryCodesGenerated.set(!1),this.generateCodes(),this.message.addSuccessMessageByKey("LBL_REGENERATED_BACKUP_CODES")):this.message.addDangerMessageByKey("LBL_FACTOR_AUTH_FAIL")}).catch()}setShowSecret(t){this.showSecret.set(t)}initButtons(){this.enableAppMethodButtonConfig={klass:"btn btn-sm btn-main",onClick:()=>{this.enable2fa()},labelKey:"LBL_ENABLE",titleKey:""},this.disableAppMethodButtonConfig={klass:"btn btn-sm btn-main",onClick:()=>{this.disable2FactorAuth()},labelKey:"LBL_DISABLE",titleKey:""},this.cancelAppMethodButtonConfig={klass:"btn btn-sm btn-main",onClick:()=>{this.cancel2fa()},labelKey:"LBL_CANCEL",titleKey:""},this.regenerateBackupCodesButtonConfig={klass:"btn btn-sm btn-main",onClick:()=>{this.generateBackupCodes()},labelKey:"LBL_REGENERATE_CODES",titleKey:""},this.verifyCodeButtonConfig={klass:"btn btn-sm btn-main mb-2",onClick:()=>{this.finalize2fa()},labelKey:"LBL_VERIFY_2FA",titleKey:""},this.copyBackupButtonConfig={klass:"btn btn-sm btn-main copy-button",onClick:()=>{this.copyBackupCodes()},labelKey:"LBL_COPY",titleKey:"",icon:"clipboard"},this.copySecretButtonConfig={klass:"btn btn-sm btn-main ml-0",onClick:()=>{this.copySecret()},labelKey:"LBL_COPY",titleKey:"",icon:"clipboard"}}static#e=this.\u0275fac=function(n){return new(n||r)(e.\u0275\u0275directiveInject(Ka),e.\u0275\u0275directiveInject(Wo.Router),e.\u0275\u0275directiveInject(bo),e.\u0275\u0275directiveInject(Kr),e.\u0275\u0275directiveInject($a),e.\u0275\u0275directiveInject(ct.NgbModal),e.\u0275\u0275directiveInject(Cx),e.\u0275\u0275directiveInject(C3))};static#t=this.\u0275cmp=e.\u0275\u0275defineComponent({type:r,selectors:[["scrm-2fa"]],hostBindings:function(n,o){1&n&&e.\u0275\u0275listener("keyup.control.enter",function(){return o.onEnterKey()})},decls:25,vars:8,consts:[["id","two-factor",1,"m-0","pt-5"],[1,"list-view-header","pb-3"],[1,"row","mr-0"],[1,"col-md-12","d-flex"],[1,"list-view-title","title-font",3,"title"],[1,"list-view-hr-container"],[1,"list-view-hr"],[1,"container"],[1,"row","mb-3"],[1,"col"],[3,"title"],["widget-header-icon-area",""],["image","mobile-phone"],["widget-header-status-area",""],["class","badge badge-pill badge-success",4,"ngIf"],["widget-header-button",""],[3,"config",4,"ngIf"],["widget-body",""],[1,"d-flex","col-md-12","pl-4","pr-4","pt-2","pb-2"],["labelKey","LBL_OTP_SETUP",1,"small"],["class","row-container",4,"ngIf"],["class","row pt-3",4,"ngIf"],[1,"badge","badge-pill","badge-success"],["labelKey","LBL_ENABLED"],[3,"config"],[1,"row-container"],[1,"qr-code-container"],["class","qr-code-col",4,"ngIf"],["class","qr-code-secret",4,"ngIf"],[1,"row"],["labelKey","LBL_QR_CODE_HELP",1,"pl-3","d-inline-block","qr-code-label"],[1,"d-flex","flex-column","pt-4","align-items-center"],["id","auth_code","type","text","name","auth_code","autocomplete","off",1,"mb-3","auth-input",3,"ngModelChange","ngModel"],["id","submit-2fa-code",3,"config"],[1,"qr-code-col"],[1,"qr-code"],[3,"innerHTML"],["class","secret-container",4,"ngIf"],[1,"secret-container"],[1,"small","show-secret-link","pl-1",3,"click"],["labelKey","LBL_USE_SECRET"],["labelKey","LBL_HIDE_SECRET"],[1,"qr-code-secret"],["labelKey","LBL_USE_SECRET_DESC",1,"pb-3"],[1,"font-weight-bold","pb-2","secret"],[1,"pb-2",3,"config"],[1,"row","pt-3"],[1,"col","mb-4"],["image","key"],["labelKey","LBL_BACKUP_CODES_INFO",1,"small"],[4,"ngIf"],["labelKey","LBL_GENERATED"],[1,"d-flex","flex-column"],[1,"d-flex","col-md-12","pl-4","pr-4","pt-2","pb-3"],[1,"backup-codes-container"],[4,"ngFor","ngForOf"],[1,"backup-codes"]],template:function(n,o){1&n&&(e.\u0275\u0275elementContainerStart(0),e.\u0275\u0275elementStart(1,"div",0)(2,"div",1)(3,"div",2)(4,"div",3),e.\u0275\u0275element(5,"scrm-module-title",4),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(6,"div",5),e.\u0275\u0275element(7,"hr",6),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementStart(8,"div",7)(9,"div",8)(10,"div",9)(11,"scrm-widget-panel",10)(12,"span",11),e.\u0275\u0275element(13,"scrm-image",12),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(14,"span",13),e.\u0275\u0275template(15,YP,2,0,"span",14),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(16,"span",15),e.\u0275\u0275template(17,TN,1,1,"scrm-button",16)(18,D3,1,1,"scrm-button",16)(19,w3,1,1,"scrm-button",16),e.\u0275\u0275elementEnd(),e.\u0275\u0275elementStart(20,"div",17)(21,"div",18),e.\u0275\u0275element(22,"scrm-label",19),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(23,To,13,4,"div",20),e.\u0275\u0275elementEnd()()()(),e.\u0275\u0275template(24,Pn,13,4,"div",21),e.\u0275\u0275elementEnd()(),e.\u0275\u0275elementContainerEnd()),2&n&&(e.\u0275\u0275advance(5),e.\u0275\u0275property("title",o.getTitle()),e.\u0275\u0275advance(6),e.\u0275\u0275property("title",o.appMethodHeaderLabel),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",o.isAppMethodEnabled()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",!o.isAppMethodEnabled()&&!o.isQrCodeGenerated()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",!o.isAppMethodEnabled()&&o.isQrCodeGenerated()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isAppMethodEnabled()&&!o.isQrCodeGenerated()),e.\u0275\u0275advance(4),e.\u0275\u0275property("ngIf",o.isQrCodeGenerated()),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",o.isAppMethodEnabled()))},dependencies:[ve.NgForOf,ve.NgIf,co,Pa,Bl,xc,Ji.DefaultValueAccessor,Ji.NgControlStatus,Ji.NgModel,f0,QP],encapsulation:2})}return r})(),Im=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule]})}return r})(),Kl=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Wo.RouterModule,Do,Ea,Vl,X2,Z2,Zw,pa,Oa,fn.SvgIconComponent,oN,Im,F1,n1,qw,Gp]})}return r})(),fE=(()=>{class r{static#e=this.\u0275fac=function(n){return new(n||r)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:r});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[ve.CommonModule,Qm,n1,Ji.FormsModule,Ea,Im,Oa]})}return r})()},9969:(Ot,Me,S)=>{S.r(Me),S.d(Me,{AUTO_STYLE:()=>X,AnimationBuilder:()=>fn,AnimationFactory:()=>ct,AnimationMetadataType:()=>M,NoopAnimationPlayer:()=>dt,animate:()=>Q,animateChild:()=>je,animation:()=>le,group:()=>Ee,keyframes:()=>Z,query:()=>wt,sequence:()=>he,stagger:()=>ve,state:()=>oe,style:()=>q,transition:()=>ce,trigger:()=>ie,useAnimation:()=>Et,\u0275AnimationGroupPlayer:()=>ut,\u0275BrowserAnimationBuilder:()=>en,\u0275PRE_STYLE:()=>Mt});var i=S(2168),e=S(1270),M=function(Wt){return Wt[Wt.State=0]="State",Wt[Wt.Transition=1]="Transition",Wt[Wt.Sequence=2]="Sequence",Wt[Wt.Group=3]="Group",Wt[Wt.Animate=4]="Animate",Wt[Wt.Keyframes=5]="Keyframes",Wt[Wt.Style=6]="Style",Wt[Wt.Trigger=7]="Trigger",Wt[Wt.Reference=8]="Reference",Wt[Wt.AnimateChild=9]="AnimateChild",Wt[Wt.AnimateRef=10]="AnimateRef",Wt[Wt.Query=11]="Query",Wt[Wt.Stagger=12]="Stagger",Wt}(M||{});const X="*";function ie(Wt,It){return{type:M.Trigger,name:Wt,definitions:It,options:{}}}function Q(Wt,It=null){return{type:M.Animate,styles:It,timings:Wt}}function Ee(Wt,It=null){return{type:M.Group,steps:Wt,options:It}}function he(Wt,It=null){return{type:M.Sequence,steps:Wt,options:It}}function q(Wt){return{type:M.Style,styles:Wt,offset:null}}function oe(Wt,It,Vn){return{type:M.State,name:Wt,styles:It,options:Vn}}function Z(Wt){return{type:M.Keyframes,steps:Wt}}function ce(Wt,It,Vn=null){return{type:M.Transition,expr:Wt,animation:It,options:Vn}}function le(Wt,It=null){return{type:M.Reference,animation:Wt,options:It}}function je(Wt=null){return{type:M.AnimateChild,options:Wt}}function Et(Wt,It=null){return{type:M.AnimateRef,animation:Wt,options:It}}function wt(Wt,It,Vn=null){return{type:M.Query,selector:Wt,animation:It,options:Vn}}function ve(Wt,It){return{type:M.Stagger,timings:Wt,animation:It}}let fn=(()=>{class Wt{static#e=this.\u0275fac=function(pn){return new(pn||Wt)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:Wt,factory:()=>(0,e.inject)(en),providedIn:"root"})}return Wt})();class ct{}let en=(()=>{class Wt extends fn{constructor(Vn,pn){if(super(),this.animationModuleType=(0,e.inject)(e.ANIMATION_MODULE_TYPE,{optional:!0}),this._nextAnimationId=0,this._renderer=Vn.createRenderer(pn.body,{id:"0",encapsulation:e.ViewEncapsulation.None,styles:[],data:{animation:[]}}),null===this.animationModuleType&&!function Ae(Wt){const It=Wt.\u0275type;return 0===It||1===It}(this._renderer))throw new e.\u0275RuntimeError(3600,!1)}build(Vn){const pn=this._nextAnimationId;this._nextAnimationId++;const Wn=Array.isArray(Vn)?he(Vn):Vn;return vn(this._renderer,null,pn,"register",[Wn]),new an(pn,this._renderer)}static#e=this.\u0275fac=function(pn){return new(pn||Wt)(e.\u0275\u0275inject(e.RendererFactory2),e.\u0275\u0275inject(i.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:Wt,factory:Wt.\u0275fac,providedIn:"root"})}return Wt})();class an extends ct{constructor(It,Vn){super(),this._id=It,this._renderer=Vn}create(It,Vn){return new un(this._id,It,Vn||{},this._renderer)}}class un{constructor(It,Vn,pn,Wn){this.id=It,this.element=Vn,this._renderer=Wn,this.parentPlayer=null,this._started=!1,this.totalTime=0,this._command("create",pn)}_listen(It,Vn){return this._renderer.listen(this.element,`@@${this.id}:${It}`,Vn)}_command(It,...Vn){vn(this._renderer,this.element,this.id,It,Vn)}onDone(It){this._listen("done",It)}onStart(It){this._listen("start",It)}onDestroy(It){this._listen("destroy",It)}init(){this._command("init")}hasStarted(){return this._started}play(){this._command("play"),this._started=!0}pause(){this._command("pause")}restart(){this._command("restart")}finish(){this._command("finish")}destroy(){this._command("destroy")}reset(){this._command("reset"),this._started=!1}setPosition(It){this._command("setPosition",It)}getPosition(){return function Pt(Wt){const It=Wt.\u0275type;return 0===It?Wt:1===It?Wt.animationRenderer:null}(this._renderer)?.engine?.players[this.id]?.getPosition()??0}}function vn(Wt,It,Vn,pn,Wn){Wt.setProperty(It,`@@${Vn}:${pn}`,Wn)}class dt{constructor(It=0,Vn=0){this._onDoneFns=[],this._onStartFns=[],this._onDestroyFns=[],this._originalOnDoneFns=[],this._originalOnStartFns=[],this._started=!1,this._destroyed=!1,this._finished=!1,this._position=0,this.parentPlayer=null,this.totalTime=It+Vn}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(It=>It()),this._onDoneFns=[])}onStart(It){this._originalOnStartFns.push(It),this._onStartFns.push(It)}onDone(It){this._originalOnDoneFns.push(It),this._onDoneFns.push(It)}onDestroy(It){this._onDestroyFns.push(It)}hasStarted(){return this._started}init(){}play(){this.hasStarted()||(this._onStart(),this.triggerMicrotask()),this._started=!0}triggerMicrotask(){queueMicrotask(()=>this._onFinish())}_onStart(){this._onStartFns.forEach(It=>It()),this._onStartFns=[]}pause(){}restart(){}finish(){this._onFinish()}destroy(){this._destroyed||(this._destroyed=!0,this.hasStarted()||this._onStart(),this.finish(),this._onDestroyFns.forEach(It=>It()),this._onDestroyFns=[])}reset(){this._started=!1,this._finished=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}setPosition(It){this._position=this.totalTime?It*this.totalTime:1}getPosition(){return this.totalTime?this._position/this.totalTime:1}triggerCallback(It){const Vn="start"==It?this._onStartFns:this._onDoneFns;Vn.forEach(pn=>pn()),Vn.length=0}}class ut{constructor(It){this._onDoneFns=[],this._onStartFns=[],this._finished=!1,this._started=!1,this._destroyed=!1,this._onDestroyFns=[],this.parentPlayer=null,this.totalTime=0,this.players=It;let Vn=0,pn=0,Wn=0;const ji=this.players.length;0==ji?queueMicrotask(()=>this._onFinish()):this.players.forEach(An=>{An.onDone(()=>{++Vn==ji&&this._onFinish()}),An.onDestroy(()=>{++pn==ji&&this._onDestroy()}),An.onStart(()=>{++Wn==ji&&this._onStart()})}),this.totalTime=this.players.reduce((An,St)=>Math.max(An,St.totalTime),0)}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(It=>It()),this._onDoneFns=[])}init(){this.players.forEach(It=>It.init())}onStart(It){this._onStartFns.push(It)}_onStart(){this.hasStarted()||(this._started=!0,this._onStartFns.forEach(It=>It()),this._onStartFns=[])}onDone(It){this._onDoneFns.push(It)}onDestroy(It){this._onDestroyFns.push(It)}hasStarted(){return this._started}play(){this.parentPlayer||this.init(),this._onStart(),this.players.forEach(It=>It.play())}pause(){this.players.forEach(It=>It.pause())}restart(){this.players.forEach(It=>It.restart())}finish(){this._onFinish(),this.players.forEach(It=>It.finish())}destroy(){this._onDestroy()}_onDestroy(){this._destroyed||(this._destroyed=!0,this._onFinish(),this.players.forEach(It=>It.destroy()),this._onDestroyFns.forEach(It=>It()),this._onDestroyFns=[])}reset(){this.players.forEach(It=>It.reset()),this._destroyed=!1,this._finished=!1,this._started=!1}setPosition(It){const Vn=It*this.totalTime;this.players.forEach(pn=>{const Wn=pn.totalTime?Math.min(1,Vn/pn.totalTime):1;pn.setPosition(Wn)})}getPosition(){const It=this.players.reduce((Vn,pn)=>null===Vn||pn.totalTime>Vn.totalTime?pn:Vn,null);return null!=It?It.getPosition():0}beforeDestroy(){this.players.forEach(It=>{It.beforeDestroy&&It.beforeDestroy()})}triggerCallback(It){const Vn="start"==It?this._onStartFns:this._onDoneFns;Vn.forEach(pn=>pn()),Vn.length=0}}const Mt="!"},8203:(Ot,Me,S)=>{S.d(Me,{dS:()=>Ee,jI:()=>q});var i=S(1270),e=S(2168);const M=new i.InjectionToken("cdk-dir-doc",{providedIn:"root",factory:function X(){return(0,i.inject)(e.DOCUMENT)}}),ie=/^(ar|ckb|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Adlm|Arab|Hebr|Nkoo|Rohg|Thaa))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)/i;let Ee=(()=>{class oe{constructor(ce){this.value="ltr",this.change=new i.EventEmitter,ce&&(this.value=function Q(oe){const Z=oe?.toLowerCase()||"";return"auto"===Z&&typeof navigator<"u"&&navigator?.language?ie.test(navigator.language)?"rtl":"ltr":"rtl"===Z?"rtl":"ltr"}((ce.body?ce.body.dir:null)||(ce.documentElement?ce.documentElement.dir:null)||"ltr"))}ngOnDestroy(){this.change.complete()}static#e=this.\u0275fac=function(le){return new(le||oe)(i.\u0275\u0275inject(M,8))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:oe,factory:oe.\u0275fac,providedIn:"root"})}return oe})(),q=(()=>{class oe{static#e=this.\u0275fac=function(le){return new(le||oe)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:oe});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return oe})()},4085:(Ot,Me,S)=>{S.d(Me,{FG:()=>ie,OE:()=>M,he:()=>e,i8:()=>Ee});var i=S(1270);function e(q){return null!=q&&"false"!=`${q}`}function M(q,oe=0){return function X(q){return!isNaN(parseFloat(q))&&!isNaN(Number(q))}(q)?Number(q):2===arguments.length?oe:0}function ie(q){return Array.isArray(q)?q:[q]}function Ee(q){return q instanceof i.ElementRef?q.nativeElement:q}},2318:(Ot,Me,S)=>{S.r(Me),S.d(Me,{CdkObserveContent:()=>he,ContentObserver:()=>Ee,MutationObserverFactory:()=>Q,ObserversModule:()=>q});var i=S(4085),e=S(1270),M=S(1647),X=S(9335);let Q=(()=>{class oe{create(ce){return typeof MutationObserver>"u"?null:new MutationObserver(ce)}static#e=this.\u0275fac=function(le){return new(le||oe)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:oe,factory:oe.\u0275fac,providedIn:"root"})}return oe})(),Ee=(()=>{class oe{constructor(ce){this._mutationObserverFactory=ce,this._observedElements=new Map,this._ngZone=(0,e.inject)(e.NgZone)}ngOnDestroy(){this._observedElements.forEach((ce,le)=>this._cleanupObserver(le))}observe(ce){const le=(0,i.i8)(ce);return new M.Observable(je=>{const wt=this._observeElement(le).pipe((0,X.map)(ve=>ve.filter(fn=>!function ie(oe){if("characterData"===oe.type&&oe.target instanceof Comment)return!0;if("childList"===oe.type){for(let Z=0;Z<oe.addedNodes.length;Z++)if(!(oe.addedNodes[Z]instanceof Comment))return!1;for(let Z=0;Z<oe.removedNodes.length;Z++)if(!(oe.removedNodes[Z]instanceof Comment))return!1;return!0}return!1}(fn))),(0,X.filter)(ve=>!!ve.length)).subscribe(ve=>{this._ngZone.run(()=>{je.next(ve)})});return()=>{wt.unsubscribe(),this._unobserveElement(le)}})}_observeElement(ce){return this._ngZone.runOutsideAngular(()=>{if(this._observedElements.has(ce))this._observedElements.get(ce).count++;else{const le=new M.Subject,je=this._mutationObserverFactory.create(Et=>le.next(Et));je&&je.observe(ce,{characterData:!0,childList:!0,subtree:!0}),this._observedElements.set(ce,{observer:je,stream:le,count:1})}return this._observedElements.get(ce).stream})}_unobserveElement(ce){this._observedElements.has(ce)&&(this._observedElements.get(ce).count--,this._observedElements.get(ce).count||this._cleanupObserver(ce))}_cleanupObserver(ce){if(this._observedElements.has(ce)){const{observer:le,stream:je}=this._observedElements.get(ce);le&&le.disconnect(),je.complete(),this._observedElements.delete(ce)}}static#e=this.\u0275fac=function(le){return new(le||oe)(e.\u0275\u0275inject(Q))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:oe,factory:oe.\u0275fac,providedIn:"root"})}return oe})(),he=(()=>{class oe{get disabled(){return this._disabled}set disabled(ce){this._disabled=ce,this._disabled?this._unsubscribe():this._subscribe()}get debounce(){return this._debounce}set debounce(ce){this._debounce=(0,i.OE)(ce),this._subscribe()}constructor(ce,le){this._contentObserver=ce,this._elementRef=le,this.event=new e.EventEmitter,this._disabled=!1,this._currentSubscription=null}ngAfterContentInit(){!this._currentSubscription&&!this.disabled&&this._subscribe()}ngOnDestroy(){this._unsubscribe()}_subscribe(){this._unsubscribe();const ce=this._contentObserver.observe(this._elementRef);this._currentSubscription=(this.debounce?ce.pipe((0,X.debounceTime)(this.debounce)):ce).subscribe(this.event)}_unsubscribe(){this._currentSubscription?.unsubscribe()}static#e=this.\u0275fac=function(le){return new(le||oe)(e.\u0275\u0275directiveInject(Ee),e.\u0275\u0275directiveInject(e.ElementRef))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:oe,selectors:[["","cdkObserveContent",""]],inputs:{disabled:[2,"cdkObserveContentDisabled","disabled",e.booleanAttribute],debounce:"debounce"},outputs:{event:"cdkObserveContent"},exportAs:["cdkObserveContent"],standalone:!0,features:[e.\u0275\u0275InputTransformsFeature]})}return oe})(),q=(()=>{class oe{static#e=this.\u0275fac=function(le){return new(le||oe)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:oe});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[Q]})}return oe})()},6860:(Ot,Me,S)=>{S.d(Me,{BQ:()=>Z,Fb:()=>an,KT:()=>ct,OD:()=>X});var i=S(1270),e=S(2168);let M;try{M=typeof Intl<"u"&&Intl.v8BreakIterator}catch{M=!1}let q,ve,X=(()=>{class vn{constructor(Ae){this._platformId=Ae,this.isBrowser=this._platformId?(0,e.isPlatformBrowser)(this._platformId):"object"==typeof document&&!!document,this.EDGE=this.isBrowser&&/(edge)/i.test(navigator.userAgent),this.TRIDENT=this.isBrowser&&/(msie|trident)/i.test(navigator.userAgent),this.BLINK=this.isBrowser&&!(!window.chrome&&!M)&&typeof CSS<"u"&&!this.EDGE&&!this.TRIDENT,this.WEBKIT=this.isBrowser&&/AppleWebKit/i.test(navigator.userAgent)&&!this.BLINK&&!this.EDGE&&!this.TRIDENT,this.IOS=this.isBrowser&&/iPad|iPhone|iPod/.test(navigator.userAgent)&&!("MSStream"in window),this.FIREFOX=this.isBrowser&&/(firefox|minefield)/i.test(navigator.userAgent),this.ANDROID=this.isBrowser&&/android/i.test(navigator.userAgent)&&!this.TRIDENT,this.SAFARI=this.isBrowser&&/safari/i.test(navigator.userAgent)&&this.WEBKIT}static#e=this.\u0275fac=function(dt){return new(dt||vn)(i.\u0275\u0275inject(i.PLATFORM_ID))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:vn,factory:vn.\u0275fac,providedIn:"root"})}return vn})();function Z(vn){return function oe(){if(null==q&&typeof window<"u")try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:()=>q=!0}))}finally{q=q||!1}return q}()?vn:!!vn.capture}function ct(vn){if(function fn(){if(null==ve){const vn=typeof document<"u"?document.head:null;ve=!(!vn||!vn.createShadowRoot&&!vn.attachShadow)}return ve}()){const Pt=vn.getRootNode?vn.getRootNode():null;if(typeof ShadowRoot<"u"&&ShadowRoot&&Pt instanceof ShadowRoot)return Pt}return null}function an(vn){return vn.composedPath?vn.composedPath()[0]:vn.target}},5478:(Ot,Me,S)=>{S.d(Me,{E9:()=>Wt,Gj:()=>Mt,R:()=>Et,Xj:()=>fn});var i=S(4085),e=S(1270),M=S(1647),X=S(9335),ie=S(6860),Q=S(2168),Ee=S(8203);let Et=(()=>{class It{constructor(pn,Wn,ji){this._ngZone=pn,this._platform=Wn,this._scrolled=new M.Subject,this._globalSubscription=null,this._scrolledCount=0,this.scrollContainers=new Map,this._document=ji}register(pn){this.scrollContainers.has(pn)||this.scrollContainers.set(pn,pn.elementScrolled().subscribe(()=>this._scrolled.next(pn)))}deregister(pn){const Wn=this.scrollContainers.get(pn);Wn&&(Wn.unsubscribe(),this.scrollContainers.delete(pn))}scrolled(pn=20){return this._platform.isBrowser?new M.Observable(Wn=>{this._globalSubscription||this._addGlobalListener();const ji=pn>0?this._scrolled.pipe((0,X.auditTime)(pn)).subscribe(Wn):this._scrolled.subscribe(Wn);return this._scrolledCount++,()=>{ji.unsubscribe(),this._scrolledCount--,this._scrolledCount||this._removeGlobalListener()}}):(0,M.of)()}ngOnDestroy(){this._removeGlobalListener(),this.scrollContainers.forEach((pn,Wn)=>this.deregister(Wn)),this._scrolled.complete()}ancestorScrolled(pn,Wn){const ji=this.getAncestorScrollContainers(pn);return this.scrolled(Wn).pipe((0,X.filter)(An=>!An||ji.indexOf(An)>-1))}getAncestorScrollContainers(pn){const Wn=[];return this.scrollContainers.forEach((ji,An)=>{this._scrollableContainsElement(An,pn)&&Wn.push(An)}),Wn}_getWindow(){return this._document.defaultView||window}_scrollableContainsElement(pn,Wn){let ji=(0,i.i8)(Wn),An=pn.getElementRef().nativeElement;do{if(ji==An)return!0}while(ji=ji.parentElement);return!1}_addGlobalListener(){this._globalSubscription=this._ngZone.runOutsideAngular(()=>{const pn=this._getWindow();return(0,M.fromEvent)(pn.document,"scroll").subscribe(()=>this._scrolled.next())})}_removeGlobalListener(){this._globalSubscription&&(this._globalSubscription.unsubscribe(),this._globalSubscription=null)}static#e=this.\u0275fac=function(Wn){return new(Wn||It)(e.\u0275\u0275inject(e.NgZone),e.\u0275\u0275inject(ie.OD),e.\u0275\u0275inject(Q.DOCUMENT,8))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:It,factory:It.\u0275fac,providedIn:"root"})}return It})(),fn=(()=>{class It{constructor(pn,Wn,ji){this._platform=pn,this._change=new M.Subject,this._changeListener=An=>{this._change.next(An)},this._document=ji,Wn.runOutsideAngular(()=>{if(pn.isBrowser){const An=this._getWindow();An.addEventListener("resize",this._changeListener),An.addEventListener("orientationchange",this._changeListener)}this.change().subscribe(()=>this._viewportSize=null)})}ngOnDestroy(){if(this._platform.isBrowser){const pn=this._getWindow();pn.removeEventListener("resize",this._changeListener),pn.removeEventListener("orientationchange",this._changeListener)}this._change.complete()}getViewportSize(){this._viewportSize||this._updateViewportSize();const pn={width:this._viewportSize.width,height:this._viewportSize.height};return this._platform.isBrowser||(this._viewportSize=null),pn}getViewportRect(){const pn=this.getViewportScrollPosition(),{width:Wn,height:ji}=this.getViewportSize();return{top:pn.top,left:pn.left,bottom:pn.top+ji,right:pn.left+Wn,height:ji,width:Wn}}getViewportScrollPosition(){if(!this._platform.isBrowser)return{top:0,left:0};const pn=this._document,Wn=this._getWindow(),ji=pn.documentElement,An=ji.getBoundingClientRect();return{top:-An.top||pn.body.scrollTop||Wn.scrollY||ji.scrollTop||0,left:-An.left||pn.body.scrollLeft||Wn.scrollX||ji.scrollLeft||0}}change(pn=20){return pn>0?this._change.pipe((0,X.auditTime)(pn)):this._change}_getWindow(){return this._document.defaultView||window}_updateViewportSize(){const pn=this._getWindow();this._viewportSize=this._platform.isBrowser?{width:pn.innerWidth,height:pn.innerHeight}:{width:0,height:0}}static#e=this.\u0275fac=function(Wn){return new(Wn||It)(e.\u0275\u0275inject(ie.OD),e.\u0275\u0275inject(e.NgZone),e.\u0275\u0275inject(Q.DOCUMENT,8))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:It,factory:It.\u0275fac,providedIn:"root"})}return It})(),Mt=(()=>{class It{static#e=this.\u0275fac=function(Wn){return new(Wn||It)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:It});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({})}return It})(),Wt=(()=>{class It{static#e=this.\u0275fac=function(Wn){return new(Wn||It)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:It});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({imports:[Ee.jI,Mt,Ee.jI,Mt]})}return It})()},6398:(Ot,Me,S)=>{S.r(Me),S.d(Me,{BaseCdkCell:()=>pn,BaseRowDef:()=>Cn,CDK_ROW_TEMPLATE:()=>on,CDK_TABLE:()=>dt,CDK_TABLE_TEMPLATE:()=>Bn,CdkCell:()=>An,CdkCellDef:()=>Mt,CdkCellOutlet:()=>Dn,CdkColumnDef:()=>Vn,CdkFooterCell:()=>ji,CdkFooterCellDef:()=>It,CdkFooterRow:()=>Nn,CdkFooterRowDef:()=>fi,CdkHeaderCell:()=>Wn,CdkHeaderCellDef:()=>Wt,CdkHeaderRow:()=>gn,CdkHeaderRowDef:()=>tn,CdkNoDataRow:()=>cr,CdkRecycleRows:()=>Gt,CdkRow:()=>Yn,CdkRowDef:()=>Zn,CdkTable:()=>ni,CdkTableModule:()=>Ii,CdkTextColumn:()=>Bi,DataRowOutlet:()=>Gn,DataSource:()=>X,FooterRowOutlet:()=>pi,HeaderRowOutlet:()=>ri,NoDataRowOutlet:()=>At,STICKY_DIRECTIONS:()=>Ai,STICKY_POSITIONING_LISTENER:()=>hn,StickyStyler:()=>Qi,TEXT_COLUMN_OPTIONS:()=>ut,_COALESCED_STYLE_SCHEDULER:()=>qt,_CoalescedStyleScheduler:()=>Ht,_Schedule:()=>St,mixinHasStickyInput:()=>Ki});var i=S(8203),e=S(1647),M=S(1270);class X{}function ie(Jt){return Jt&&"function"==typeof Jt.connect&&!(Jt instanceof e.ConnectableObservable)}var Ee=function(Jt){return Jt[Jt.REPLACED=0]="REPLACED",Jt[Jt.INSERTED=1]="INSERTED",Jt[Jt.MOVED=2]="MOVED",Jt[Jt.REMOVED=3]="REMOVED",Jt}(Ee||{});const he=new M.InjectionToken("_ViewRepeater");class q{applyChanges(hi,Ft,it,sn,Ve){hi.forEachOperation((He,mt,bt)=>{let nn,Jn;if(null==He.previousIndex){const Sn=it(He,mt,bt);nn=Ft.createEmbeddedView(Sn.templateRef,Sn.context,Sn.index),Jn=Ee.INSERTED}else null==bt?(Ft.remove(mt),Jn=Ee.REMOVED):(nn=Ft.get(mt),Ft.move(nn,bt),Jn=Ee.MOVED);Ve&&Ve({context:nn?.context,operation:Jn,record:He})})}detach(){}}class oe{constructor(){this.viewCacheSize=20,this._viewCache=[]}applyChanges(hi,Ft,it,sn,Ve){hi.forEachOperation((He,mt,bt)=>{let nn,Jn;null==He.previousIndex?(nn=this._insertView(()=>it(He,mt,bt),bt,Ft,sn(He)),Jn=nn?Ee.INSERTED:Ee.REPLACED):null==bt?(this._detachAndCacheView(mt,Ft),Jn=Ee.REMOVED):(nn=this._moveView(mt,bt,Ft,sn(He)),Jn=Ee.MOVED),Ve&&Ve({context:nn?.context,operation:Jn,record:He})})}detach(){for(const hi of this._viewCache)hi.destroy();this._viewCache=[]}_insertView(hi,Ft,it,sn){const Ve=this._insertViewFromCache(Ft,it);if(Ve)return void(Ve.context.$implicit=sn);const He=hi();return it.createEmbeddedView(He.templateRef,He.context,He.index)}_detachAndCacheView(hi,Ft){const it=Ft.detach(hi);this._maybeCacheView(it,Ft)}_moveView(hi,Ft,it,sn){const Ve=it.get(hi);return it.move(Ve,Ft),Ve.context.$implicit=sn,Ve}_maybeCacheView(hi,Ft){if(this._viewCache.length<this.viewCacheSize)this._viewCache.push(hi);else{const it=Ft.indexOf(hi);-1===it?hi.destroy():Ft.remove(it)}}_insertViewFromCache(hi,Ft){const it=this._viewCache.pop();return it&&Ft.insert(it,hi),it||null}}var je=S(6860),Et=S(5478),wt=S(2168),ve=S(9335),fn=S(4085);const ct=[[["caption"]],[["colgroup"],["col"]],"*"],en=["caption","colgroup, col","*"];function an(Jt,hi){1&Jt&&M.\u0275\u0275projection(0,2)}function un(Jt,hi){1&Jt&&(M.\u0275\u0275elementStart(0,"thead",0),M.\u0275\u0275elementContainer(1,1),M.\u0275\u0275elementEnd(),M.\u0275\u0275elementStart(2,"tbody",0),M.\u0275\u0275elementContainer(3,2)(4,3),M.\u0275\u0275elementEnd(),M.\u0275\u0275elementStart(5,"tfoot",0),M.\u0275\u0275elementContainer(6,4),M.\u0275\u0275elementEnd())}function vn(Jt,hi){1&Jt&&M.\u0275\u0275elementContainer(0,1)(1,2)(2,3)(3,4)}function Pt(Jt,hi){if(1&Jt&&(M.\u0275\u0275elementStart(0,"th",3),M.\u0275\u0275text(1),M.\u0275\u0275elementEnd()),2&Jt){const Ft=M.\u0275\u0275nextContext();M.\u0275\u0275styleProp("text-align",Ft.justify),M.\u0275\u0275advance(),M.\u0275\u0275textInterpolate1(" ",Ft.headerText," ")}}function Ae(Jt,hi){if(1&Jt&&(M.\u0275\u0275elementStart(0,"td",4),M.\u0275\u0275text(1),M.\u0275\u0275elementEnd()),2&Jt){const Ft=hi.$implicit,it=M.\u0275\u0275nextContext();M.\u0275\u0275styleProp("text-align",it.justify),M.\u0275\u0275advance(),M.\u0275\u0275textInterpolate1(" ",it.dataAccessor(Ft,it.name)," ")}}const dt=new M.InjectionToken("CDK_TABLE"),ut=new M.InjectionToken("text-column-options");let Mt=(()=>{class Jt{constructor(Ft){this.template=Ft}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkCellDef",""]],standalone:!0})}return Jt})(),Wt=(()=>{class Jt{constructor(Ft){this.template=Ft}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkHeaderCellDef",""]],standalone:!0})}return Jt})(),It=(()=>{class Jt{constructor(Ft){this.template=Ft}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkFooterCellDef",""]],standalone:!0})}return Jt})(),Vn=(()=>{class Jt{get name(){return this._name}set name(Ft){this._setNameInput(Ft)}get sticky(){return this._sticky}set sticky(Ft){Ft!==this._sticky&&(this._sticky=Ft,this._hasStickyChanged=!0)}get stickyEnd(){return this._stickyEnd}set stickyEnd(Ft){Ft!==this._stickyEnd&&(this._stickyEnd=Ft,this._hasStickyChanged=!0)}constructor(Ft){this._table=Ft,this._hasStickyChanged=!1,this._sticky=!1,this._stickyEnd=!1}hasStickyChanged(){const Ft=this._hasStickyChanged;return this.resetStickyChanged(),Ft}resetStickyChanged(){this._hasStickyChanged=!1}_updateColumnCssClassName(){this._columnCssClassName=[`cdk-column-${this.cssClassFriendlyName}`]}_setNameInput(Ft){Ft&&(this._name=Ft,this.cssClassFriendlyName=Ft.replace(/[^a-z0-9_-]/gi,"-"),this._updateColumnCssClassName())}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(dt,8))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkColumnDef",""]],contentQueries:function(it,sn,Ve){if(1&it&&(M.\u0275\u0275contentQuery(Ve,Mt,5),M.\u0275\u0275contentQuery(Ve,Wt,5),M.\u0275\u0275contentQuery(Ve,It,5)),2&it){let He;M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn.cell=He.first),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn.headerCell=He.first),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn.footerCell=He.first)}},inputs:{name:[0,"cdkColumnDef","name"],sticky:[2,"sticky","sticky",M.booleanAttribute],stickyEnd:[2,"stickyEnd","stickyEnd",M.booleanAttribute]},standalone:!0,features:[M.\u0275\u0275ProvidersFeature([{provide:"MAT_SORT_HEADER_COLUMN_DEF",useExisting:Jt}]),M.\u0275\u0275InputTransformsFeature]})}return Jt})();class pn{constructor(hi,Ft){Ft.nativeElement.classList.add(...hi._columnCssClassName)}}let Wn=(()=>{class Jt extends pn{constructor(Ft,it){super(Ft,it)}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(Vn),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["cdk-header-cell"],["th","cdk-header-cell",""]],hostAttrs:["role","columnheader",1,"cdk-header-cell"],standalone:!0,features:[M.\u0275\u0275InheritDefinitionFeature]})}return Jt})(),ji=(()=>{class Jt extends pn{constructor(Ft,it){super(Ft,it);const sn=Ft._table?._getCellRole();sn&&it.nativeElement.setAttribute("role",sn)}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(Vn),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["cdk-footer-cell"],["td","cdk-footer-cell",""]],hostAttrs:[1,"cdk-footer-cell"],standalone:!0,features:[M.\u0275\u0275InheritDefinitionFeature]})}return Jt})(),An=(()=>{class Jt extends pn{constructor(Ft,it){super(Ft,it);const sn=Ft._table?._getCellRole();sn&&it.nativeElement.setAttribute("role",sn)}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(Vn),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["cdk-cell"],["td","cdk-cell",""]],hostAttrs:[1,"cdk-cell"],standalone:!0,features:[M.\u0275\u0275InheritDefinitionFeature]})}return Jt})();class St{constructor(){this.tasks=[],this.endTasks=[]}}const qt=new M.InjectionToken("_COALESCED_STYLE_SCHEDULER");let Ht=(()=>{class Jt{constructor(Ft){this._currentSchedule=null,this._ngZone=(0,M.inject)(M.NgZone)}schedule(Ft){this._createScheduleIfNeeded(),this._currentSchedule.tasks.push(Ft)}scheduleEnd(Ft){this._createScheduleIfNeeded(),this._currentSchedule.endTasks.push(Ft)}_createScheduleIfNeeded(){this._currentSchedule||(this._currentSchedule=new St,this._ngZone.runOutsideAngular(()=>queueMicrotask(()=>{for(;this._currentSchedule.tasks.length||this._currentSchedule.endTasks.length;){const Ft=this._currentSchedule;this._currentSchedule=new St;for(const it of Ft.tasks)it();for(const it of Ft.endTasks)it()}this._currentSchedule=null})))}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275inject(M.NgZone))};static#t=this.\u0275prov=M.\u0275\u0275defineInjectable({token:Jt,factory:Jt.\u0275fac})}return Jt})();const on="<ng-container cdkCellOutlet></ng-container>";let Cn=(()=>{class Jt{constructor(Ft,it){this.template=Ft,this._differs=it}ngOnChanges(Ft){if(!this._columnsDiffer){const it=Ft.columns&&Ft.columns.currentValue||[];this._columnsDiffer=this._differs.find(it).create(),this._columnsDiffer.diff(it)}}getColumnsDiff(){return this._columnsDiffer.diff(this.columns)}extractCellTemplate(Ft){return this instanceof tn?Ft.headerCell.template:this instanceof fi?Ft.footerCell.template:Ft.cell.template}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef),M.\u0275\u0275directiveInject(M.IterableDiffers))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,features:[M.\u0275\u0275NgOnChangesFeature]})}return Jt})(),tn=(()=>{class Jt extends Cn{get sticky(){return this._sticky}set sticky(Ft){Ft!==this._sticky&&(this._sticky=Ft,this._hasStickyChanged=!0)}constructor(Ft,it,sn){super(Ft,it),this._table=sn,this._hasStickyChanged=!1,this._sticky=!1}ngOnChanges(Ft){super.ngOnChanges(Ft)}hasStickyChanged(){const Ft=this._hasStickyChanged;return this.resetStickyChanged(),Ft}resetStickyChanged(){this._hasStickyChanged=!1}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef),M.\u0275\u0275directiveInject(M.IterableDiffers),M.\u0275\u0275directiveInject(dt,8))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkHeaderRowDef",""]],inputs:{columns:[0,"cdkHeaderRowDef","columns"],sticky:[2,"cdkHeaderRowDefSticky","sticky",M.booleanAttribute]},standalone:!0,features:[M.\u0275\u0275InputTransformsFeature,M.\u0275\u0275InheritDefinitionFeature,M.\u0275\u0275NgOnChangesFeature]})}return Jt})(),fi=(()=>{class Jt extends Cn{get sticky(){return this._sticky}set sticky(Ft){Ft!==this._sticky&&(this._sticky=Ft,this._hasStickyChanged=!0)}constructor(Ft,it,sn){super(Ft,it),this._table=sn,this._hasStickyChanged=!1,this._sticky=!1}ngOnChanges(Ft){super.ngOnChanges(Ft)}hasStickyChanged(){const Ft=this._hasStickyChanged;return this.resetStickyChanged(),Ft}resetStickyChanged(){this._hasStickyChanged=!1}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef),M.\u0275\u0275directiveInject(M.IterableDiffers),M.\u0275\u0275directiveInject(dt,8))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkFooterRowDef",""]],inputs:{columns:[0,"cdkFooterRowDef","columns"],sticky:[2,"cdkFooterRowDefSticky","sticky",M.booleanAttribute]},standalone:!0,features:[M.\u0275\u0275InputTransformsFeature,M.\u0275\u0275InheritDefinitionFeature,M.\u0275\u0275NgOnChangesFeature]})}return Jt})(),Zn=(()=>{class Jt extends Cn{constructor(Ft,it,sn){super(Ft,it),this._table=sn}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef),M.\u0275\u0275directiveInject(M.IterableDiffers),M.\u0275\u0275directiveInject(dt,8))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkRowDef",""]],inputs:{columns:[0,"cdkRowDefColumns","columns"],when:[0,"cdkRowDefWhen","when"]},standalone:!0,features:[M.\u0275\u0275InheritDefinitionFeature]})}return Jt})(),Dn=(()=>{class Jt{static#e=this.mostRecentCellOutlet=null;constructor(Ft){this._viewContainer=Ft,Jt.mostRecentCellOutlet=this}ngOnDestroy(){Jt.mostRecentCellOutlet===this&&(Jt.mostRecentCellOutlet=null)}static#t=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.ViewContainerRef))};static#n=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","cdkCellOutlet",""]],standalone:!0})}return Jt})(),gn=(()=>{class Jt{static#e=this.\u0275fac=function(it){return new(it||Jt)};static#t=this.\u0275cmp=M.\u0275\u0275defineComponent({type:Jt,selectors:[["cdk-header-row"],["tr","cdk-header-row",""]],hostAttrs:["role","row",1,"cdk-header-row"],standalone:!0,features:[M.\u0275\u0275StandaloneFeature],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(it,sn){1&it&&M.\u0275\u0275elementContainer(0,0)},dependencies:[Dn],encapsulation:2})}return Jt})(),Nn=(()=>{class Jt{static#e=this.\u0275fac=function(it){return new(it||Jt)};static#t=this.\u0275cmp=M.\u0275\u0275defineComponent({type:Jt,selectors:[["cdk-footer-row"],["tr","cdk-footer-row",""]],hostAttrs:["role","row",1,"cdk-footer-row"],standalone:!0,features:[M.\u0275\u0275StandaloneFeature],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(it,sn){1&it&&M.\u0275\u0275elementContainer(0,0)},dependencies:[Dn],encapsulation:2})}return Jt})(),Yn=(()=>{class Jt{static#e=this.\u0275fac=function(it){return new(it||Jt)};static#t=this.\u0275cmp=M.\u0275\u0275defineComponent({type:Jt,selectors:[["cdk-row"],["tr","cdk-row",""]],hostAttrs:["role","row",1,"cdk-row"],standalone:!0,features:[M.\u0275\u0275StandaloneFeature],decls:1,vars:0,consts:[["cdkCellOutlet",""]],template:function(it,sn){1&it&&M.\u0275\u0275elementContainer(0,0)},dependencies:[Dn],encapsulation:2})}return Jt})(),cr=(()=>{class Jt{constructor(Ft){this.templateRef=Ft,this._contentClassName="cdk-no-data-row"}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.TemplateRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["ng-template","cdkNoDataRow",""]],standalone:!0})}return Jt})();const Ai=["top","bottom","left","right"];class Qi{constructor(hi,Ft,it,sn,Ve=!0,He=!0,mt){this._isNativeHtmlTable=hi,this._stickCellCss=Ft,this.direction=it,this._coalescedStyleScheduler=sn,this._isBrowser=Ve,this._needsPositionStickyOnElement=He,this._positionListener=mt,this._cachedCellWidths=[],this._borderCellCss={top:`${Ft}-border-elem-top`,bottom:`${Ft}-border-elem-bottom`,left:`${Ft}-border-elem-left`,right:`${Ft}-border-elem-right`}}clearStickyPositioning(hi,Ft){const it=[];for(const sn of hi)if(sn.nodeType===sn.ELEMENT_NODE){it.push(sn);for(let Ve=0;Ve<sn.children.length;Ve++)it.push(sn.children[Ve])}this._coalescedStyleScheduler.schedule(()=>{for(const sn of it)this._removeStickyStyle(sn,Ft)})}updateStickyColumns(hi,Ft,it,sn=!0){hi.length&&this._isBrowser&&(Ft.some(Ve=>Ve)||it.some(Ve=>Ve))?this._coalescedStyleScheduler.schedule(()=>{const Ve=hi[0],He=Ve.children.length,mt=this._getCellWidths(Ve,sn),bt=this._getStickyStartColumnPositions(mt,Ft),nn=this._getStickyEndColumnPositions(mt,it),Jn=Ft.lastIndexOf(!0),Sn=it.indexOf(!0),_r="rtl"===this.direction,qr=_r?"right":"left",Bo=_r?"left":"right";for(const Eo of hi)for(let Ro=0;Ro<He;Ro++){const Ls=Eo.children[Ro];Ft[Ro]&&this._addStickyStyle(Ls,qr,bt[Ro],Ro===Jn),it[Ro]&&this._addStickyStyle(Ls,Bo,nn[Ro],Ro===Sn)}this._positionListener&&(this._positionListener.stickyColumnsUpdated({sizes:-1===Jn?[]:mt.slice(0,Jn+1).map((Eo,Ro)=>Ft[Ro]?Eo:null)}),this._positionListener.stickyEndColumnsUpdated({sizes:-1===Sn?[]:mt.slice(Sn).map((Eo,Ro)=>it[Ro+Sn]?Eo:null).reverse()}))}):this._positionListener&&(this._positionListener.stickyColumnsUpdated({sizes:[]}),this._positionListener.stickyEndColumnsUpdated({sizes:[]}))}stickRows(hi,Ft,it){this._isBrowser&&this._coalescedStyleScheduler.schedule(()=>{const sn="bottom"===it?hi.slice().reverse():hi,Ve="bottom"===it?Ft.slice().reverse():Ft,He=[],mt=[],bt=[];for(let Jn=0,Sn=0;Jn<sn.length;Jn++){if(!Ve[Jn])continue;He[Jn]=Sn;const _r=sn[Jn];bt[Jn]=this._isNativeHtmlTable?Array.from(_r.children):[_r];const qr=_r.getBoundingClientRect().height;Sn+=qr,mt[Jn]=qr}const nn=Ve.lastIndexOf(!0);for(let Jn=0;Jn<sn.length;Jn++){if(!Ve[Jn])continue;const Sn=He[Jn],_r=Jn===nn;for(const qr of bt[Jn])this._addStickyStyle(qr,it,Sn,_r)}"top"===it?this._positionListener?.stickyHeaderRowsUpdated({sizes:mt,offsets:He,elements:bt}):this._positionListener?.stickyFooterRowsUpdated({sizes:mt,offsets:He,elements:bt})})}updateStickyFooterContainer(hi,Ft){this._isNativeHtmlTable&&this._coalescedStyleScheduler.schedule(()=>{const it=hi.querySelector("tfoot");it&&(Ft.some(sn=>!sn)?this._removeStickyStyle(it,["bottom"]):this._addStickyStyle(it,"bottom",0,!1))})}_removeStickyStyle(hi,Ft){for(const sn of Ft)hi.style[sn]="",hi.classList.remove(this._borderCellCss[sn]);Ai.some(sn=>-1===Ft.indexOf(sn)&&hi.style[sn])?hi.style.zIndex=this._getCalculatedZIndex(hi):(hi.style.zIndex="",this._needsPositionStickyOnElement&&(hi.style.position=""),hi.classList.remove(this._stickCellCss))}_addStickyStyle(hi,Ft,it,sn){hi.classList.add(this._stickCellCss),sn&&hi.classList.add(this._borderCellCss[Ft]),hi.style[Ft]=`${it}px`,hi.style.zIndex=this._getCalculatedZIndex(hi),this._needsPositionStickyOnElement&&(hi.style.cssText+="position: -webkit-sticky; position: sticky; ")}_getCalculatedZIndex(hi){const Ft={top:100,bottom:10,left:1,right:1};let it=0;for(const sn of Ai)hi.style[sn]&&(it+=Ft[sn]);return it?`${it}`:""}_getCellWidths(hi,Ft=!0){if(!Ft&&this._cachedCellWidths.length)return this._cachedCellWidths;const it=[],sn=hi.children;for(let Ve=0;Ve<sn.length;Ve++)it.push(sn[Ve].getBoundingClientRect().width);return this._cachedCellWidths=it,it}_getStickyStartColumnPositions(hi,Ft){const it=[];let sn=0;for(let Ve=0;Ve<hi.length;Ve++)Ft[Ve]&&(it[Ve]=sn,sn+=hi[Ve]);return it}_getStickyEndColumnPositions(hi,Ft){const it=[];let sn=0;for(let Ve=hi.length;Ve>0;Ve--)Ft[Ve]&&(it[Ve]=sn,sn+=hi[Ve]);return it}}const hn=new M.InjectionToken("CDK_SPL");let Gt=(()=>{class Jt{static#e=this.\u0275fac=function(it){return new(it||Jt)};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["cdk-table","recycleRows",""],["table","cdk-table","","recycleRows",""]],standalone:!0,features:[M.\u0275\u0275ProvidersFeature([{provide:he,useClass:oe}])]})}return Jt})(),Gn=(()=>{class Jt{constructor(Ft,it){this.viewContainer=Ft,this.elementRef=it;const sn=(0,M.inject)(dt);sn._rowOutlet=this,sn._outletAssigned()}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.ViewContainerRef),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","rowOutlet",""]],standalone:!0})}return Jt})(),ri=(()=>{class Jt{constructor(Ft,it){this.viewContainer=Ft,this.elementRef=it;const sn=(0,M.inject)(dt);sn._headerRowOutlet=this,sn._outletAssigned()}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.ViewContainerRef),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","headerRowOutlet",""]],standalone:!0})}return Jt})(),pi=(()=>{class Jt{constructor(Ft,it){this.viewContainer=Ft,this.elementRef=it;const sn=(0,M.inject)(dt);sn._footerRowOutlet=this,sn._outletAssigned()}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.ViewContainerRef),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","footerRowOutlet",""]],standalone:!0})}return Jt})(),At=(()=>{class Jt{constructor(Ft,it){this.viewContainer=Ft,this.elementRef=it;const sn=(0,M.inject)(dt);sn._noDataRowOutlet=this,sn._outletAssigned()}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.ViewContainerRef),M.\u0275\u0275directiveInject(M.ElementRef))};static#t=this.\u0275dir=M.\u0275\u0275defineDirective({type:Jt,selectors:[["","noDataRowOutlet",""]],standalone:!0})}return Jt})();const Bn='\n <ng-content select="caption"/>\n <ng-content select="colgroup, col"/>\n\n \x3c!--\n Unprojected content throws a hydration error so we need this to capture it.\n It gets removed on the client so it doesn\'t affect the layout.\n --\x3e\n @if (_isServer) {\n <ng-content/>\n }\n\n @if (_isNativeHtmlTable) {\n <thead role="rowgroup">\n <ng-container headerRowOutlet/>\n </thead>\n <tbody role="rowgroup">\n <ng-container rowOutlet/>\n <ng-container noDataRowOutlet/>\n </tbody>\n <tfoot role="rowgroup">\n <ng-container footerRowOutlet/>\n </tfoot>\n } @else {\n <ng-container headerRowOutlet/>\n <ng-container rowOutlet/>\n <ng-container noDataRowOutlet/>\n <ng-container footerRowOutlet/>\n }\n';let ni=(()=>{class Jt{_getCellRole(){if(void 0===this._cellRoleInternal){const Ft=this._elementRef.nativeElement.getAttribute("role"),it="grid"===Ft||"treegrid"===Ft?"gridcell":"cell";this._cellRoleInternal=this._isNativeHtmlTable&&"cell"===it?null:it}return this._cellRoleInternal}get trackBy(){return this._trackByFn}set trackBy(Ft){this._trackByFn=Ft}get dataSource(){return this._dataSource}set dataSource(Ft){this._dataSource!==Ft&&this._switchDataSource(Ft)}get multiTemplateDataRows(){return this._multiTemplateDataRows}set multiTemplateDataRows(Ft){this._multiTemplateDataRows=Ft,this._rowOutlet&&this._rowOutlet.viewContainer.length&&(this._forceRenderDataRows(),this.updateStickyColumnStyles())}get fixedLayout(){return this._fixedLayout}set fixedLayout(Ft){this._fixedLayout=Ft,this._forceRecalculateCellWidths=!0,this._stickyColumnStylesNeedReset=!0}constructor(Ft,it,sn,Ve,He,mt,bt,nn,Jn,Sn,_r,qr){this._differs=Ft,this._changeDetectorRef=it,this._elementRef=sn,this._dir=He,this._platform=bt,this._viewRepeater=nn,this._coalescedStyleScheduler=Jn,this._viewportRuler=Sn,this._stickyPositioningListener=_r,this._onDestroy=new e.Subject,this._columnDefsByName=new Map,this._customColumnDefs=new Set,this._customRowDefs=new Set,this._customHeaderRowDefs=new Set,this._customFooterRowDefs=new Set,this._headerRowDefChanged=!0,this._footerRowDefChanged=!0,this._stickyColumnStylesNeedReset=!0,this._forceRecalculateCellWidths=!0,this._cachedRenderRowsMap=new Map,this.stickyCssClass="cdk-table-sticky",this.needsPositionStickyOnElement=!0,this._isShowingNoDataRow=!1,this._hasAllOutlets=!1,this._hasInitialized=!1,this._cellRoleInternal=void 0,this._multiTemplateDataRows=!1,this._fixedLayout=!1,this.contentChanged=new M.EventEmitter,this.viewChange=new e.BehaviorSubject({start:0,end:Number.MAX_VALUE}),this._injector=(0,M.inject)(M.Injector),Ve||sn.nativeElement.setAttribute("role","table"),this._document=mt,this._isServer=!bt.isBrowser,this._isNativeHtmlTable="TABLE"===sn.nativeElement.nodeName}ngOnInit(){this._setupStickyStyler(),this._dataDiffer=this._differs.find([]).create((Ft,it)=>this.trackBy?this.trackBy(it.dataIndex,it.data):it),this._viewportRuler.change().pipe((0,ve.takeUntil)(this._onDestroy)).subscribe(()=>{this._forceRecalculateCellWidths=!0})}ngAfterContentInit(){this._hasInitialized=!0}ngAfterContentChecked(){this._canRender()&&this._render()}ngOnDestroy(){[this._rowOutlet?.viewContainer,this._headerRowOutlet?.viewContainer,this._footerRowOutlet?.viewContainer,this._cachedRenderRowsMap,this._customColumnDefs,this._customRowDefs,this._customHeaderRowDefs,this._customFooterRowDefs,this._columnDefsByName].forEach(Ft=>{Ft?.clear()}),this._headerRowDefs=[],this._footerRowDefs=[],this._defaultRowDef=null,this._onDestroy.next(),this._onDestroy.complete(),ie(this.dataSource)&&this.dataSource.disconnect(this)}renderRows(){this._renderRows=this._getAllRenderRows();const Ft=this._dataDiffer.diff(this._renderRows);if(!Ft)return this._updateNoDataRow(),void this.contentChanged.next();const it=this._rowOutlet.viewContainer;this._viewRepeater.applyChanges(Ft,it,(sn,Ve,He)=>this._getEmbeddedViewArgs(sn.item,He),sn=>sn.item.data,sn=>{sn.operation===Ee.INSERTED&&sn.context&&this._renderCellTemplateForItem(sn.record.item.rowDef,sn.context)}),this._updateRowIndexContext(),Ft.forEachIdentityChange(sn=>{it.get(sn.currentIndex).context.$implicit=sn.item.data}),this._updateNoDataRow(),(0,M.afterNextRender)(()=>{this.updateStickyColumnStyles()},{injector:this._injector}),this.contentChanged.next()}addColumnDef(Ft){this._customColumnDefs.add(Ft)}removeColumnDef(Ft){this._customColumnDefs.delete(Ft)}addRowDef(Ft){this._customRowDefs.add(Ft)}removeRowDef(Ft){this._customRowDefs.delete(Ft)}addHeaderRowDef(Ft){this._customHeaderRowDefs.add(Ft),this._headerRowDefChanged=!0}removeHeaderRowDef(Ft){this._customHeaderRowDefs.delete(Ft),this._headerRowDefChanged=!0}addFooterRowDef(Ft){this._customFooterRowDefs.add(Ft),this._footerRowDefChanged=!0}removeFooterRowDef(Ft){this._customFooterRowDefs.delete(Ft),this._footerRowDefChanged=!0}setNoDataRow(Ft){this._customNoDataRow=Ft}updateStickyHeaderRowStyles(){const Ft=this._getRenderedRows(this._headerRowOutlet);if(this._isNativeHtmlTable){const sn=Ti(this._headerRowOutlet,"thead");sn&&(sn.style.display=Ft.length?"":"none")}const it=this._headerRowDefs.map(sn=>sn.sticky);this._stickyStyler.clearStickyPositioning(Ft,["top"]),this._stickyStyler.stickRows(Ft,it,"top"),this._headerRowDefs.forEach(sn=>sn.resetStickyChanged())}updateStickyFooterRowStyles(){const Ft=this._getRenderedRows(this._footerRowOutlet);if(this._isNativeHtmlTable){const sn=Ti(this._footerRowOutlet,"tfoot");sn&&(sn.style.display=Ft.length?"":"none")}const it=this._footerRowDefs.map(sn=>sn.sticky);this._stickyStyler.clearStickyPositioning(Ft,["bottom"]),this._stickyStyler.stickRows(Ft,it,"bottom"),this._stickyStyler.updateStickyFooterContainer(this._elementRef.nativeElement,it),this._footerRowDefs.forEach(sn=>sn.resetStickyChanged())}updateStickyColumnStyles(){const Ft=this._getRenderedRows(this._headerRowOutlet),it=this._getRenderedRows(this._rowOutlet),sn=this._getRenderedRows(this._footerRowOutlet);(this._isNativeHtmlTable&&!this._fixedLayout||this._stickyColumnStylesNeedReset)&&(this._stickyStyler.clearStickyPositioning([...Ft,...it,...sn],["left","right"]),this._stickyColumnStylesNeedReset=!1),Ft.forEach((Ve,He)=>{this._addStickyColumnStyles([Ve],this._headerRowDefs[He])}),this._rowDefs.forEach(Ve=>{const He=[];for(let mt=0;mt<it.length;mt++)this._renderRows[mt].rowDef===Ve&&He.push(it[mt]);this._addStickyColumnStyles(He,Ve)}),sn.forEach((Ve,He)=>{this._addStickyColumnStyles([Ve],this._footerRowDefs[He])}),Array.from(this._columnDefsByName.values()).forEach(Ve=>Ve.resetStickyChanged())}_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();const it=this._renderUpdatedColumns()||this._headerRowDefChanged||this._footerRowDefChanged;this._stickyColumnStylesNeedReset=this._stickyColumnStylesNeedReset||it,this._forceRecalculateCellWidths=it,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(){const Ft=[],it=this._cachedRenderRowsMap;this._cachedRenderRowsMap=new Map;for(let sn=0;sn<this._data.length;sn++){let Ve=this._data[sn];const He=this._getRenderRowsForData(Ve,sn,it.get(Ve));this._cachedRenderRowsMap.has(Ve)||this._cachedRenderRowsMap.set(Ve,new WeakMap);for(let mt=0;mt<He.length;mt++){let bt=He[mt];const nn=this._cachedRenderRowsMap.get(bt.data);nn.has(bt.rowDef)?nn.get(bt.rowDef).push(bt):nn.set(bt.rowDef,[bt]),Ft.push(bt)}}return Ft}_getRenderRowsForData(Ft,it,sn){return this._getRowDefs(Ft,it).map(He=>{const mt=sn&&sn.has(He)?sn.get(He):[];if(mt.length){const bt=mt.shift();return bt.dataIndex=it,bt}return{data:Ft,rowDef:He,dataIndex:it}})}_cacheColumnDefs(){this._columnDefsByName.clear(),qn(this._getOwnDefs(this._contentColumnDefs),this._customColumnDefs).forEach(it=>{this._columnDefsByName.has(it.name),this._columnDefsByName.set(it.name,it)})}_cacheRowDefs(){this._headerRowDefs=qn(this._getOwnDefs(this._contentHeaderRowDefs),this._customHeaderRowDefs),this._footerRowDefs=qn(this._getOwnDefs(this._contentFooterRowDefs),this._customFooterRowDefs),this._rowDefs=qn(this._getOwnDefs(this._contentRowDefs),this._customRowDefs);const Ft=this._rowDefs.filter(it=>!it.when);this._defaultRowDef=Ft[0]}_renderUpdatedColumns(){const Ft=(He,mt)=>He||!!mt.getColumnsDiff(),it=this._rowDefs.reduce(Ft,!1);it&&this._forceRenderDataRows();const sn=this._headerRowDefs.reduce(Ft,!1);sn&&this._forceRenderHeaderRows();const Ve=this._footerRowDefs.reduce(Ft,!1);return Ve&&this._forceRenderFooterRows(),it||sn||Ve}_switchDataSource(Ft){this._data=[],ie(this.dataSource)&&this.dataSource.disconnect(this),this._renderChangeSubscription&&(this._renderChangeSubscription.unsubscribe(),this._renderChangeSubscription=null),Ft||(this._dataDiffer&&this._dataDiffer.diff([]),this._rowOutlet&&this._rowOutlet.viewContainer.clear()),this._dataSource=Ft}_observeRenderChanges(){if(!this.dataSource)return;let Ft;ie(this.dataSource)?Ft=this.dataSource.connect(this):(0,e.isObservable)(this.dataSource)?Ft=this.dataSource:Array.isArray(this.dataSource)&&(Ft=(0,e.of)(this.dataSource)),this._renderChangeSubscription=Ft.pipe((0,ve.takeUntil)(this._onDestroy)).subscribe(it=>{this._data=it||[],this.renderRows()})}_forceRenderHeaderRows(){this._headerRowOutlet.viewContainer.length>0&&this._headerRowOutlet.viewContainer.clear(),this._headerRowDefs.forEach((Ft,it)=>this._renderRow(this._headerRowOutlet,Ft,it)),this.updateStickyHeaderRowStyles()}_forceRenderFooterRows(){this._footerRowOutlet.viewContainer.length>0&&this._footerRowOutlet.viewContainer.clear(),this._footerRowDefs.forEach((Ft,it)=>this._renderRow(this._footerRowOutlet,Ft,it)),this.updateStickyFooterRowStyles()}_addStickyColumnStyles(Ft,it){const sn=Array.from(it.columns||[]).map(mt=>this._columnDefsByName.get(mt)),Ve=sn.map(mt=>mt.sticky),He=sn.map(mt=>mt.stickyEnd);this._stickyStyler.updateStickyColumns(Ft,Ve,He,!this._fixedLayout||this._forceRecalculateCellWidths)}_getRenderedRows(Ft){const it=[];for(let sn=0;sn<Ft.viewContainer.length;sn++){const Ve=Ft.viewContainer.get(sn);it.push(Ve.rootNodes[0])}return it}_getRowDefs(Ft,it){if(1==this._rowDefs.length)return[this._rowDefs[0]];let sn=[];if(this.multiTemplateDataRows)sn=this._rowDefs.filter(Ve=>!Ve.when||Ve.when(it,Ft));else{let Ve=this._rowDefs.find(He=>He.when&&He.when(it,Ft))||this._defaultRowDef;Ve&&sn.push(Ve)}return sn}_getEmbeddedViewArgs(Ft,it){return{templateRef:Ft.rowDef.template,context:{$implicit:Ft.data},index:it}}_renderRow(Ft,it,sn,Ve={}){const He=Ft.viewContainer.createEmbeddedView(it.template,Ve,sn);return this._renderCellTemplateForItem(it,Ve),He}_renderCellTemplateForItem(Ft,it){for(let sn of this._getCellTemplates(Ft))Dn.mostRecentCellOutlet&&Dn.mostRecentCellOutlet._viewContainer.createEmbeddedView(sn,it);this._changeDetectorRef.markForCheck()}_updateRowIndexContext(){const Ft=this._rowOutlet.viewContainer;for(let it=0,sn=Ft.length;it<sn;it++){const He=Ft.get(it).context;He.count=sn,He.first=0===it,He.last=it===sn-1,He.even=it%2==0,He.odd=!He.even,this.multiTemplateDataRows?(He.dataIndex=this._renderRows[it].dataIndex,He.renderIndex=it):He.index=this._renderRows[it].dataIndex}}_getCellTemplates(Ft){return Ft&&Ft.columns?Array.from(Ft.columns,it=>{const sn=this._columnDefsByName.get(it);return Ft.extractCellTemplate(sn)}):[]}_forceRenderDataRows(){this._dataDiffer.diff([]),this._rowOutlet.viewContainer.clear(),this.renderRows()}_checkStickyStates(){const Ft=(it,sn)=>it||sn.hasStickyChanged();this._headerRowDefs.reduce(Ft,!1)&&this.updateStickyHeaderRowStyles(),this._footerRowDefs.reduce(Ft,!1)&&this.updateStickyFooterRowStyles(),Array.from(this._columnDefsByName.values()).reduce(Ft,!1)&&(this._stickyColumnStylesNeedReset=!0,this.updateStickyColumnStyles())}_setupStickyStyler(){this._stickyStyler=new Qi(this._isNativeHtmlTable,this.stickyCssClass,this._dir?this._dir.value:"ltr",this._coalescedStyleScheduler,this._platform.isBrowser,this.needsPositionStickyOnElement,this._stickyPositioningListener),(this._dir?this._dir.change:(0,e.of)()).pipe((0,ve.takeUntil)(this._onDestroy)).subscribe(it=>{this._stickyStyler.direction=it,this.updateStickyColumnStyles()})}_getOwnDefs(Ft){return Ft.filter(it=>!it._table||it._table===this)}_updateNoDataRow(){const Ft=this._customNoDataRow||this._noDataRow;if(!Ft)return;const it=0===this._rowOutlet.viewContainer.length;if(it===this._isShowingNoDataRow)return;const sn=this._noDataRowOutlet.viewContainer;if(it){const Ve=sn.createEmbeddedView(Ft.templateRef),He=Ve.rootNodes[0];1===Ve.rootNodes.length&&He?.nodeType===this._document.ELEMENT_NODE&&(He.setAttribute("role","row"),He.classList.add(Ft._contentClassName))}else sn.clear();this._isShowingNoDataRow=it,this._changeDetectorRef.markForCheck()}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(M.IterableDiffers),M.\u0275\u0275directiveInject(M.ChangeDetectorRef),M.\u0275\u0275directiveInject(M.ElementRef),M.\u0275\u0275injectAttribute("role"),M.\u0275\u0275directiveInject(i.dS,8),M.\u0275\u0275directiveInject(wt.DOCUMENT),M.\u0275\u0275directiveInject(je.OD),M.\u0275\u0275directiveInject(he),M.\u0275\u0275directiveInject(qt),M.\u0275\u0275directiveInject(Et.Xj),M.\u0275\u0275directiveInject(hn,12),M.\u0275\u0275directiveInject(M.NgZone,8))};static#t=this.\u0275cmp=M.\u0275\u0275defineComponent({type:Jt,selectors:[["cdk-table"],["table","cdk-table",""]],contentQueries:function(it,sn,Ve){if(1&it&&(M.\u0275\u0275contentQuery(Ve,cr,5),M.\u0275\u0275contentQuery(Ve,Vn,5),M.\u0275\u0275contentQuery(Ve,Zn,5),M.\u0275\u0275contentQuery(Ve,tn,5),M.\u0275\u0275contentQuery(Ve,fi,5)),2&it){let He;M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn._noDataRow=He.first),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn._contentColumnDefs=He),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn._contentRowDefs=He),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn._contentHeaderRowDefs=He),M.\u0275\u0275queryRefresh(He=M.\u0275\u0275loadQuery())&&(sn._contentFooterRowDefs=He)}},hostAttrs:[1,"cdk-table"],hostVars:2,hostBindings:function(it,sn){2&it&&M.\u0275\u0275classProp("cdk-table-fixed-layout",sn.fixedLayout)},inputs:{trackBy:"trackBy",dataSource:"dataSource",multiTemplateDataRows:[2,"multiTemplateDataRows","multiTemplateDataRows",M.booleanAttribute],fixedLayout:[2,"fixedLayout","fixedLayout",M.booleanAttribute]},outputs:{contentChanged:"contentChanged"},exportAs:["cdkTable"],standalone:!0,features:[M.\u0275\u0275ProvidersFeature([{provide:dt,useExisting:Jt},{provide:he,useClass:q},{provide:qt,useClass:Ht},{provide:hn,useValue:null}]),M.\u0275\u0275InputTransformsFeature,M.\u0275\u0275StandaloneFeature],ngContentSelectors:en,decls:5,vars:2,consts:[["role","rowgroup"],["headerRowOutlet",""],["rowOutlet",""],["noDataRowOutlet",""],["footerRowOutlet",""]],template:function(it,sn){1&it&&(M.\u0275\u0275projectionDef(ct),M.\u0275\u0275projection(0),M.\u0275\u0275projection(1,1),M.\u0275\u0275template(2,an,1,0)(3,un,7,0)(4,vn,4,0)),2&it&&(M.\u0275\u0275advance(2),M.\u0275\u0275conditional(sn._isServer?2:-1),M.\u0275\u0275advance(),M.\u0275\u0275conditional(sn._isNativeHtmlTable?3:4))},dependencies:[ri,Gn,At,pi],styles:[".cdk-table-fixed-layout{table-layout:fixed}"],encapsulation:2})}return Jt})();function qn(Jt,hi){return Jt.concat(Array.from(hi))}function Ti(Jt,hi){const Ft=hi.toUpperCase();let it=Jt.viewContainer.element.nativeElement;for(;it;){const sn=1===it.nodeType?it.nodeName:null;if(sn===Ft)return it;if("TABLE"===sn)break;it=it.parentNode}return null}let Bi=(()=>{class Jt{get name(){return this._name}set name(Ft){this._name=Ft,this._syncColumnDefName()}constructor(Ft,it){this._table=Ft,this._options=it,this.justify="start",this._options=it||{}}ngOnInit(){this._syncColumnDefName(),void 0===this.headerText&&(this.headerText=this._createDefaultHeaderText()),this.dataAccessor||(this.dataAccessor=this._options.defaultDataAccessor||((Ft,it)=>Ft[it])),this._table&&(this.columnDef.cell=this.cell,this.columnDef.headerCell=this.headerCell,this._table.addColumnDef(this.columnDef))}ngOnDestroy(){this._table&&this._table.removeColumnDef(this.columnDef)}_createDefaultHeaderText(){const Ft=this.name;return this._options&&this._options.defaultHeaderTextTransform?this._options.defaultHeaderTextTransform(Ft):Ft[0].toUpperCase()+Ft.slice(1)}_syncColumnDefName(){this.columnDef&&(this.columnDef.name=this.name)}static#e=this.\u0275fac=function(it){return new(it||Jt)(M.\u0275\u0275directiveInject(ni,8),M.\u0275\u0275directiveInject(ut,8))};static#t=this.\u0275cmp=M.\u0275\u0275defineComponent({type:Jt,selectors:[["cdk-text-column"]],viewQuery:function(it,sn){if(1&it&&(M.\u0275\u0275viewQuery(Vn,7),M.\u0275\u0275viewQuery(Mt,7),M.\u0275\u0275viewQuery(Wt,7)),2&it){let Ve;M.\u0275\u0275queryRefresh(Ve=M.\u0275\u0275loadQuery())&&(sn.columnDef=Ve.first),M.\u0275\u0275queryRefresh(Ve=M.\u0275\u0275loadQuery())&&(sn.cell=Ve.first),M.\u0275\u0275queryRefresh(Ve=M.\u0275\u0275loadQuery())&&(sn.headerCell=Ve.first)}},inputs:{name:"name",headerText:"headerText",dataAccessor:"dataAccessor",justify:"justify"},standalone:!0,features:[M.\u0275\u0275StandaloneFeature],decls:3,vars:0,consts:[["cdkColumnDef",""],["cdk-header-cell","",3,"text-align",4,"cdkHeaderCellDef"],["cdk-cell","",3,"text-align",4,"cdkCellDef"],["cdk-header-cell",""],["cdk-cell",""]],template:function(it,sn){1&it&&(M.\u0275\u0275elementContainerStart(0,0),M.\u0275\u0275template(1,Pt,2,3,"th",1)(2,Ae,2,3,"td",2),M.\u0275\u0275elementContainerEnd())},dependencies:[Vn,Wt,Wn,Mt,An],encapsulation:2})}return Jt})(),Ii=(()=>{class Jt{static#e=this.\u0275fac=function(it){return new(it||Jt)};static#t=this.\u0275mod=M.\u0275\u0275defineNgModule({type:Jt});static#n=this.\u0275inj=M.\u0275\u0275defineInjector({imports:[Et.E9]})}return Jt})();function Ki(Jt){return class extends Jt{get sticky(){return this._sticky}set sticky(hi){const Ft=this._sticky;this._sticky=(0,fn.he)(hi),this._hasStickyChanged=Ft!==this._sticky}hasStickyChanged(){const hi=this._hasStickyChanged;return this._hasStickyChanged=!1,hi}resetStickyChanged(){this._hasStickyChanged=!1}constructor(...hi){super(...hi),this._sticky=!1,this._hasStickyChanged=!1}}}},177:(Ot,Me,S)=>{S.r(Me),S.d(Me,{APP_BASE_HREF:()=>wt,AsyncPipe:()=>ea,BrowserPlatformLocation:()=>Z,CommonModule:()=>sa,CurrencyPipe:()=>ca,DATE_PIPE_DEFAULT_OPTIONS:()=>wa,DATE_PIPE_DEFAULT_TIMEZONE:()=>Kc,DOCUMENT:()=>he,DatePipe:()=>Sl,DecimalPipe:()=>ec,FormStyle:()=>ut,FormatWidth:()=>Wt,HashLocationStrategy:()=>fn,I18nPluralPipe:()=>la,I18nSelectPipe:()=>pl,IMAGE_CONFIG:()=>e.\u0275IMAGE_CONFIG,IMAGE_LOADER:()=>re,JsonPipe:()=>Sc,KeyValuePipe:()=>Qc,LOCATION_INITIALIZED:()=>oe,Location:()=>ct,LocationStrategy:()=>Et,LowerCasePipe:()=>ga,NgClass:()=>Ui,NgComponentOutlet:()=>ar,NgFor:()=>Tt,NgForOf:()=>Tt,NgForOfContext:()=>Or,NgIf:()=>Ri,NgIfContext:()=>Un,NgLocaleLocalization:()=>jt,NgLocalization:()=>Lo,NgOptimizedImage:()=>Su,NgPlural:()=>ks,NgPluralCase:()=>Jo,NgStyle:()=>$s,NgSwitch:()=>fr,NgSwitchCase:()=>Li,NgSwitchDefault:()=>Vo,NgTemplateOutlet:()=>Js,NumberFormatStyle:()=>Ae,NumberSymbol:()=>It,PRECONNECT_CHECK_BLOCKLIST:()=>fo,PathLocationStrategy:()=>ve,PercentPipe:()=>Yc,PlatformLocation:()=>q,Plural:()=>dt,SlicePipe:()=>Rl,TitleCasePipe:()=>fl,TranslationWidth:()=>Mt,UpperCasePipe:()=>Ia,VERSION:()=>sc,ViewportScroller:()=>ta,WeekDay:()=>Vn,XhrFactory:()=>po,formatCurrency:()=>gs,formatDate:()=>At,formatNumber:()=>oa,formatPercent:()=>Zs,getCurrencySymbol:()=>uo,getLocaleCurrencyCode:()=>Nn,getLocaleCurrencyName:()=>gn,getLocaleCurrencySymbol:()=>Dn,getLocaleDateFormat:()=>on,getLocaleDateTimeFormat:()=>tn,getLocaleDayNames:()=>ji,getLocaleDayPeriods:()=>Wn,getLocaleDirection:()=>Ur,getLocaleEraNames:()=>St,getLocaleExtraDayPeriodRules:()=>Qi,getLocaleExtraDayPeriods:()=>Xr,getLocaleFirstDayOfWeek:()=>qt,getLocaleId:()=>pn,getLocaleMonthNames:()=>An,getLocaleNumberFormat:()=>Zn,getLocaleNumberSymbol:()=>fi,getLocalePluralCase:()=>cr,getLocaleTimeFormat:()=>Cn,getLocaleWeekEndRange:()=>Ht,getNumberOfCurrencyDigits:()=>ci,isPlatformBrowser:()=>ku,isPlatformServer:()=>Ql,provideCloudflareLoader:()=>kn,provideCloudinaryLoader:()=>$i,provideImageKitLoader:()=>zr,provideImgixLoader:()=>Ds,provideNetlifyLoader:()=>Je,registerLocaleData:()=>In,\u0275DomAdapter:()=>Q,\u0275NullViewportScroller:()=>Fc,\u0275PLATFORM_BROWSER_ID:()=>Lu,\u0275PLATFORM_SERVER_ID:()=>Aa,\u0275PlatformNavigation:()=>Ee,\u0275getDOM:()=>X,\u0275normalizeQueryParams:()=>je,\u0275parseCookieValue:()=>Rt,\u0275setRootDomAdapter:()=>ie}),S(4523);var e=S(1270);let M=null;function X(){return M}function ie(_e){M??=_e}class Q{}let Ee=(()=>{class _e{static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:()=>window.navigation,providedIn:"platform"})}return _e})();const he=new e.InjectionToken("");let q=(()=>{class _e{historyGo(Re){throw new Error("")}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:()=>(0,e.inject)(Z),providedIn:"platform"})}return _e})();const oe=new e.InjectionToken("");let Z=(()=>{class _e extends q{constructor(){super(),this._doc=(0,e.inject)(he),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return X().getBaseHref(this._doc)}onPopState(Re){const tt=X().getGlobalEventTarget(this._doc,"window");return tt.addEventListener("popstate",Re,!1),()=>tt.removeEventListener("popstate",Re)}onHashChange(Re){const tt=X().getGlobalEventTarget(this._doc,"window");return tt.addEventListener("hashchange",Re,!1),()=>tt.removeEventListener("hashchange",Re)}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(Re){this._location.pathname=Re}pushState(Re,tt,mn){this._history.pushState(Re,tt,mn)}replaceState(Re,tt,mn){this._history.replaceState(Re,tt,mn)}forward(){this._history.forward()}back(){this._history.back()}historyGo(Re=0){this._history.go(Re)}getState(){return this._history.state}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:()=>new _e,providedIn:"platform"})}return _e})();function ce(_e,Dt){if(0==_e.length)return Dt;if(0==Dt.length)return _e;let Re=0;return _e.endsWith("/")&&Re++,Dt.startsWith("/")&&Re++,2==Re?_e+Dt.substring(1):1==Re?_e+Dt:_e+"/"+Dt}function le(_e){const Dt=_e.match(/#|\?|$/),Re=Dt&&Dt.index||_e.length;return _e.slice(0,Re-("/"===_e[Re-1]?1:0))+_e.slice(Re)}function je(_e){return _e&&"?"!==_e[0]?"?"+_e:_e}let Et=(()=>{class _e{historyGo(Re){throw new Error("")}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:()=>(0,e.inject)(ve),providedIn:"root"})}return _e})();const wt=new e.InjectionToken("");let ve=(()=>{class _e extends Et{constructor(Re,tt){super(),this._platformLocation=Re,this._removeListenerFns=[],this._baseHref=tt??this._platformLocation.getBaseHrefFromDOM()??(0,e.inject)(he).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(Re){this._removeListenerFns.push(this._platformLocation.onPopState(Re),this._platformLocation.onHashChange(Re))}getBaseHref(){return this._baseHref}prepareExternalUrl(Re){return ce(this._baseHref,Re)}path(Re=!1){const tt=this._platformLocation.pathname+je(this._platformLocation.search),mn=this._platformLocation.hash;return mn&&Re?`${tt}${mn}`:tt}pushState(Re,tt,mn,gi){const rr=this.prepareExternalUrl(mn+je(gi));this._platformLocation.pushState(Re,tt,rr)}replaceState(Re,tt,mn,gi){const rr=this.prepareExternalUrl(mn+je(gi));this._platformLocation.replaceState(Re,tt,rr)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(Re=0){this._platformLocation.historyGo?.(Re)}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275inject(q),e.\u0275\u0275inject(wt,8))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:_e.\u0275fac,providedIn:"root"})}return _e})(),fn=(()=>{class _e extends Et{constructor(Re,tt){super(),this._platformLocation=Re,this._baseHref="",this._removeListenerFns=[],null!=tt&&(this._baseHref=tt)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(Re){this._removeListenerFns.push(this._platformLocation.onPopState(Re),this._platformLocation.onHashChange(Re))}getBaseHref(){return this._baseHref}path(Re=!1){const tt=this._platformLocation.hash??"#";return tt.length>0?tt.substring(1):tt}prepareExternalUrl(Re){const tt=ce(this._baseHref,Re);return tt.length>0?"#"+tt:tt}pushState(Re,tt,mn,gi){let rr=this.prepareExternalUrl(mn+je(gi));0==rr.length&&(rr=this._platformLocation.pathname),this._platformLocation.pushState(Re,tt,rr)}replaceState(Re,tt,mn,gi){let rr=this.prepareExternalUrl(mn+je(gi));0==rr.length&&(rr=this._platformLocation.pathname),this._platformLocation.replaceState(Re,tt,rr)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(Re=0){this._platformLocation.historyGo?.(Re)}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275inject(q),e.\u0275\u0275inject(wt,8))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:_e.\u0275fac})}return _e})(),ct=(()=>{class _e{constructor(Re){this._subject=new e.EventEmitter,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=Re;const tt=this._locationStrategy.getBaseHref();this._basePath=function vn(_e){if(new RegExp("^(https?:)?//").test(_e)){const[,Re]=_e.split(/\/\/[^\/]+/);return Re}return _e}(le(un(tt))),this._locationStrategy.onPopState(mn=>{this._subject.emit({url:this.path(!0),pop:!0,state:mn.state,type:mn.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(Re=!1){return this.normalize(this._locationStrategy.path(Re))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(Re,tt=""){return this.path()==this.normalize(Re+je(tt))}normalize(Re){return _e.stripTrailingSlash(function an(_e,Dt){if(!_e||!Dt.startsWith(_e))return Dt;const Re=Dt.substring(_e.length);return""===Re||["/",";","?","#"].includes(Re[0])?Re:Dt}(this._basePath,un(Re)))}prepareExternalUrl(Re){return Re&&"/"!==Re[0]&&(Re="/"+Re),this._locationStrategy.prepareExternalUrl(Re)}go(Re,tt="",mn=null){this._locationStrategy.pushState(mn,"",Re,tt),this._notifyUrlChangeListeners(this.prepareExternalUrl(Re+je(tt)),mn)}replaceState(Re,tt="",mn=null){this._locationStrategy.replaceState(mn,"",Re,tt),this._notifyUrlChangeListeners(this.prepareExternalUrl(Re+je(tt)),mn)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(Re=0){this._locationStrategy.historyGo?.(Re)}onUrlChange(Re){return this._urlChangeListeners.push(Re),this._urlChangeSubscription??=this.subscribe(tt=>{this._notifyUrlChangeListeners(tt.url,tt.state)}),()=>{const tt=this._urlChangeListeners.indexOf(Re);this._urlChangeListeners.splice(tt,1),0===this._urlChangeListeners.length&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(Re="",tt){this._urlChangeListeners.forEach(mn=>mn(Re,tt))}subscribe(Re,tt,mn){return this._subject.subscribe({next:Re,error:tt,complete:mn})}static#e=this.normalizeQueryParams=je;static#t=this.joinWithSlash=ce;static#n=this.stripTrailingSlash=le;static#i=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275inject(Et))};static#r=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:()=>function en(){return new ct((0,e.\u0275\u0275inject)(Et))}(),providedIn:"root"})}return _e})();function un(_e){return _e.replace(/\/index.html$/,"")}const Pt={ADP:[void 0,void 0,0],AFN:[void 0,"\u060b",0],ALL:[void 0,void 0,0],AMD:[void 0,"\u058f",2],AOA:[void 0,"Kz"],ARS:[void 0,"$"],AUD:["A$","$"],AZN:[void 0,"\u20bc"],BAM:[void 0,"KM"],BBD:[void 0,"$"],BDT:[void 0,"\u09f3"],BHD:[void 0,void 0,3],BIF:[void 0,void 0,0],BMD:[void 0,"$"],BND:[void 0,"$"],BOB:[void 0,"Bs"],BRL:["R$"],BSD:[void 0,"$"],BWP:[void 0,"P"],BYN:[void 0,void 0,2],BYR:[void 0,void 0,0],BZD:[void 0,"$"],CAD:["CA$","$",2],CHF:[void 0,void 0,2],CLF:[void 0,void 0,4],CLP:[void 0,"$",0],CNY:["CN\xa5","\xa5"],COP:[void 0,"$",2],CRC:[void 0,"\u20a1",2],CUC:[void 0,"$"],CUP:[void 0,"$"],CZK:[void 0,"K\u010d",2],DJF:[void 0,void 0,0],DKK:[void 0,"kr",2],DOP:[void 0,"$"],EGP:[void 0,"E\xa3"],ESP:[void 0,"\u20a7",0],EUR:["\u20ac"],FJD:[void 0,"$"],FKP:[void 0,"\xa3"],GBP:["\xa3"],GEL:[void 0,"\u20be"],GHS:[void 0,"GH\u20b5"],GIP:[void 0,"\xa3"],GNF:[void 0,"FG",0],GTQ:[void 0,"Q"],GYD:[void 0,"$",2],HKD:["HK$","$"],HNL:[void 0,"L"],HRK:[void 0,"kn"],HUF:[void 0,"Ft",2],IDR:[void 0,"Rp",2],ILS:["\u20aa"],INR:["\u20b9"],IQD:[void 0,void 0,0],IRR:[void 0,void 0,0],ISK:[void 0,"kr",0],ITL:[void 0,void 0,0],JMD:[void 0,"$"],JOD:[void 0,void 0,3],JPY:["\xa5",void 0,0],KHR:[void 0,"\u17db"],KMF:[void 0,"CF",0],KPW:[void 0,"\u20a9",0],KRW:["\u20a9",void 0,0],KWD:[void 0,void 0,3],KYD:[void 0,"$"],KZT:[void 0,"\u20b8"],LAK:[void 0,"\u20ad",0],LBP:[void 0,"L\xa3",0],LKR:[void 0,"Rs"],LRD:[void 0,"$"],LTL:[void 0,"Lt"],LUF:[void 0,void 0,0],LVL:[void 0,"Ls"],LYD:[void 0,void 0,3],MGA:[void 0,"Ar",0],MGF:[void 0,void 0,0],MMK:[void 0,"K",0],MNT:[void 0,"\u20ae",2],MRO:[void 0,void 0,0],MUR:[void 0,"Rs",2],MXN:["MX$","$"],MYR:[void 0,"RM"],NAD:[void 0,"$"],NGN:[void 0,"\u20a6"],NIO:[void 0,"C$"],NOK:[void 0,"kr",2],NPR:[void 0,"Rs"],NZD:["NZ$","$"],OMR:[void 0,void 0,3],PHP:["\u20b1"],PKR:[void 0,"Rs",2],PLN:[void 0,"z\u0142"],PYG:[void 0,"\u20b2",0],RON:[void 0,"lei"],RSD:[void 0,void 0,0],RUB:[void 0,"\u20bd"],RWF:[void 0,"RF",0],SBD:[void 0,"$"],SEK:[void 0,"kr",2],SGD:[void 0,"$"],SHP:[void 0,"\xa3"],SLE:[void 0,void 0,2],SLL:[void 0,void 0,0],SOS:[void 0,void 0,0],SRD:[void 0,"$"],SSP:[void 0,"\xa3"],STD:[void 0,void 0,0],STN:[void 0,"Db"],SYP:[void 0,"\xa3",0],THB:[void 0,"\u0e3f"],TMM:[void 0,void 0,0],TND:[void 0,void 0,3],TOP:[void 0,"T$"],TRL:[void 0,void 0,0],TRY:[void 0,"\u20ba"],TTD:[void 0,"$"],TWD:["NT$","$",2],TZS:[void 0,void 0,2],UAH:[void 0,"\u20b4"],UGX:[void 0,void 0,0],USD:["$"],UYI:[void 0,void 0,0],UYU:[void 0,"$"],UYW:[void 0,void 0,4],UZS:[void 0,void 0,2],VEF:[void 0,"Bs",2],VND:["\u20ab",void 0,0],VUV:[void 0,void 0,0],XAF:["FCFA",void 0,0],XCD:["EC$","$"],XOF:["F\u202fCFA",void 0,0],XPF:["CFPF",void 0,0],XXX:["\xa4"],YER:[void 0,void 0,0],ZAR:[void 0,"R"],ZMK:[void 0,void 0,0],ZMW:[void 0,"ZK"],ZWD:[void 0,void 0,0]};var Ae=function(_e){return _e[_e.Decimal=0]="Decimal",_e[_e.Percent=1]="Percent",_e[_e.Currency=2]="Currency",_e[_e.Scientific=3]="Scientific",_e}(Ae||{}),dt=function(_e){return _e[_e.Zero=0]="Zero",_e[_e.One=1]="One",_e[_e.Two=2]="Two",_e[_e.Few=3]="Few",_e[_e.Many=4]="Many",_e[_e.Other=5]="Other",_e}(dt||{}),ut=function(_e){return _e[_e.Format=0]="Format",_e[_e.Standalone=1]="Standalone",_e}(ut||{}),Mt=function(_e){return _e[_e.Narrow=0]="Narrow",_e[_e.Abbreviated=1]="Abbreviated",_e[_e.Wide=2]="Wide",_e[_e.Short=3]="Short",_e}(Mt||{}),Wt=function(_e){return _e[_e.Short=0]="Short",_e[_e.Medium=1]="Medium",_e[_e.Long=2]="Long",_e[_e.Full=3]="Full",_e}(Wt||{});const 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};var Vn=function(_e){return _e[_e.Sunday=0]="Sunday",_e[_e.Monday=1]="Monday",_e[_e.Tuesday=2]="Tuesday",_e[_e.Wednesday=3]="Wednesday",_e[_e.Thursday=4]="Thursday",_e[_e.Friday=5]="Friday",_e[_e.Saturday=6]="Saturday",_e}(Vn||{});function pn(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.LocaleId]}function Wn(_e,Dt,Re){const tt=(0,e.\u0275findLocaleData)(_e),gi=eo([tt[e.\u0275LocaleDataIndex.DayPeriodsFormat],tt[e.\u0275LocaleDataIndex.DayPeriodsStandalone]],Dt);return eo(gi,Re)}function ji(_e,Dt,Re){const tt=(0,e.\u0275findLocaleData)(_e),gi=eo([tt[e.\u0275LocaleDataIndex.DaysFormat],tt[e.\u0275LocaleDataIndex.DaysStandalone]],Dt);return eo(gi,Re)}function An(_e,Dt,Re){const tt=(0,e.\u0275findLocaleData)(_e),gi=eo([tt[e.\u0275LocaleDataIndex.MonthsFormat],tt[e.\u0275LocaleDataIndex.MonthsStandalone]],Dt);return eo(gi,Re)}function St(_e,Dt){return eo((0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.Eras],Dt)}function qt(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.FirstDayOfWeek]}function Ht(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.WeekendRange]}function on(_e,Dt){return eo((0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.DateFormat],Dt)}function Cn(_e,Dt){return eo((0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.TimeFormat],Dt)}function tn(_e,Dt){return eo((0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.DateTimeFormat],Dt)}function fi(_e,Dt){const Re=(0,e.\u0275findLocaleData)(_e),tt=Re[e.\u0275LocaleDataIndex.NumberSymbols][Dt];if(typeof tt>"u"){if(Dt===It.CurrencyDecimal)return Re[e.\u0275LocaleDataIndex.NumberSymbols][It.Decimal];if(Dt===It.CurrencyGroup)return Re[e.\u0275LocaleDataIndex.NumberSymbols][It.Group]}return tt}function Zn(_e,Dt){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.NumberFormats][Dt]}function Dn(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.CurrencySymbol]||null}function gn(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.CurrencyName]||null}function Nn(_e){return(0,e.\u0275getLocaleCurrencyCode)(_e)}const cr=e.\u0275getLocalePluralCase;function Ai(_e){if(!_e[e.\u0275LocaleDataIndex.ExtraData])throw new Error(`Missing extra locale data for the locale "${_e[e.\u0275LocaleDataIndex.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function Qi(_e){const Dt=(0,e.\u0275findLocaleData)(_e);return Ai(Dt),(Dt[e.\u0275LocaleDataIndex.ExtraData][2]||[]).map(tt=>"string"==typeof tt?as(tt):[as(tt[0]),as(tt[1])])}function Xr(_e,Dt,Re){const tt=(0,e.\u0275findLocaleData)(_e);Ai(tt);const gi=eo([tt[e.\u0275LocaleDataIndex.ExtraData][0],tt[e.\u0275LocaleDataIndex.ExtraData][1]],Dt)||[];return eo(gi,Re)||[]}function Ur(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.Directionality]}function eo(_e,Dt){for(let Re=Dt;Re>-1;Re--)if(typeof _e[Re]<"u")return _e[Re];throw new Error("Locale data API: locale data undefined")}function as(_e){const[Dt,Re]=_e.split(":");return{hours:+Dt,minutes:+Re}}function uo(_e,Dt,Re="en"){const tt=function Yn(_e){return(0,e.\u0275findLocaleData)(_e)[e.\u0275LocaleDataIndex.Currencies]}(Re)[_e]||Pt[_e]||[],mn=tt[1];return"narrow"===Dt&&"string"==typeof mn?mn:tt[0]||_e}const mi=2;function ci(_e){let Dt;const Re=Pt[_e];return Re&&(Dt=Re[2]),"number"==typeof Dt?Dt:mi}const yt=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,hn={},Gt=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;var Gn=function(_e){return _e[_e.Short=0]="Short",_e[_e.ShortGMT=1]="ShortGMT",_e[_e.Long=2]="Long",_e[_e.Extended=3]="Extended",_e}(Gn||{}),ri=function(_e){return _e[_e.FullYear=0]="FullYear",_e[_e.Month=1]="Month",_e[_e.Date=2]="Date",_e[_e.Hours=3]="Hours",_e[_e.Minutes=4]="Minutes",_e[_e.Seconds=5]="Seconds",_e[_e.FractionalSeconds=6]="FractionalSeconds",_e[_e.Day=7]="Day",_e}(ri||{}),pi=function(_e){return _e[_e.DayPeriods=0]="DayPeriods",_e[_e.Days=1]="Days",_e[_e.Months=2]="Months",_e[_e.Eras=3]="Eras",_e}(pi||{});function At(_e,Dt,Re,tt){let mn=function _r(_e){if(Bo(_e))return _e;if("number"==typeof _e&&!isNaN(_e))return new Date(_e);if("string"==typeof _e){if(_e=_e.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(_e)){const[mn,gi=1,rr=1]=_e.split("-").map(or=>+or);return Bn(mn,gi-1,rr)}const Re=parseFloat(_e);if(!isNaN(_e-Re))return new Date(Re);let tt;if(tt=_e.match(yt))return function qr(_e){const Dt=new Date(0);let Re=0,tt=0;const mn=_e[8]?Dt.setUTCFullYear:Dt.setFullYear,gi=_e[8]?Dt.setUTCHours:Dt.setHours;_e[9]&&(Re=Number(_e[9]+_e[10]),tt=Number(_e[9]+_e[11])),mn.call(Dt,Number(_e[1]),Number(_e[2])-1,Number(_e[3]));const rr=Number(_e[4]||0)-Re,or=Number(_e[5]||0)-tt,ia=Number(_e[6]||0),La=Math.floor(1e3*parseFloat("0."+(_e[7]||0)));return gi.call(Dt,rr,or,ia,La),Dt}(tt)}const Dt=new Date(_e);if(!Bo(Dt))throw new Error(`Unable to convert "${_e}" into a date`);return Dt}(_e);Dt=Mn(Re,Dt)||Dt;let or,rr=[];for(;Dt;){if(or=Gt.exec(Dt),!or){rr.push(Dt);break}{rr=rr.concat(or.slice(1));const vs=rr.pop();if(!vs)break;Dt=vs}}let ia=mn.getTimezoneOffset();tt&&(ia=nn(tt,ia),mn=function Sn(_e,Dt,Re){const tt=Re?-1:1,mn=_e.getTimezoneOffset();return function Jn(_e,Dt){return(_e=new Date(_e.getTime())).setMinutes(_e.getMinutes()+Dt),_e}(_e,tt*(nn(Dt,mn)-mn))}(mn,tt,!0));let La="";return rr.forEach(vs=>{const Qo=function bt(_e){if(mt[_e])return mt[_e];let Dt;switch(_e){case"G":case"GG":case"GGG":Dt=Ii(pi.Eras,Mt.Abbreviated);break;case"GGGG":Dt=Ii(pi.Eras,Mt.Wide);break;case"GGGGG":Dt=Ii(pi.Eras,Mt.Narrow);break;case"y":Dt=Bi(ri.FullYear,1,0,!1,!0);break;case"yy":Dt=Bi(ri.FullYear,2,0,!0,!0);break;case"yyy":Dt=Bi(ri.FullYear,3,0,!1,!0);break;case"yyyy":Dt=Bi(ri.FullYear,4,0,!1,!0);break;case"Y":Dt=He(1);break;case"YY":Dt=He(2,!0);break;case"YYY":Dt=He(3);break;case"YYYY":Dt=He(4);break;case"M":case"L":Dt=Bi(ri.Month,1,1);break;case"MM":case"LL":Dt=Bi(ri.Month,2,1);break;case"MMM":Dt=Ii(pi.Months,Mt.Abbreviated);break;case"MMMM":Dt=Ii(pi.Months,Mt.Wide);break;case"MMMMM":Dt=Ii(pi.Months,Mt.Narrow);break;case"LLL":Dt=Ii(pi.Months,Mt.Abbreviated,ut.Standalone);break;case"LLLL":Dt=Ii(pi.Months,Mt.Wide,ut.Standalone);break;case"LLLLL":Dt=Ii(pi.Months,Mt.Narrow,ut.Standalone);break;case"w":Dt=Ve(1);break;case"ww":Dt=Ve(2);break;case"W":Dt=Ve(1,!0);break;case"d":Dt=Bi(ri.Date,1);break;case"dd":Dt=Bi(ri.Date,2);break;case"c":case"cc":Dt=Bi(ri.Day,1);break;case"ccc":Dt=Ii(pi.Days,Mt.Abbreviated,ut.Standalone);break;case"cccc":Dt=Ii(pi.Days,Mt.Wide,ut.Standalone);break;case"ccccc":Dt=Ii(pi.Days,Mt.Narrow,ut.Standalone);break;case"cccccc":Dt=Ii(pi.Days,Mt.Short,ut.Standalone);break;case"E":case"EE":case"EEE":Dt=Ii(pi.Days,Mt.Abbreviated);break;case"EEEE":Dt=Ii(pi.Days,Mt.Wide);break;case"EEEEE":Dt=Ii(pi.Days,Mt.Narrow);break;case"EEEEEE":Dt=Ii(pi.Days,Mt.Short);break;case"a":case"aa":case"aaa":Dt=Ii(pi.DayPeriods,Mt.Abbreviated);break;case"aaaa":Dt=Ii(pi.DayPeriods,Mt.Wide);break;case"aaaaa":Dt=Ii(pi.DayPeriods,Mt.Narrow);break;case"b":case"bb":case"bbb":Dt=Ii(pi.DayPeriods,Mt.Abbreviated,ut.Standalone,!0);break;case"bbbb":Dt=Ii(pi.DayPeriods,Mt.Wide,ut.Standalone,!0);break;case"bbbbb":Dt=Ii(pi.DayPeriods,Mt.Narrow,ut.Standalone,!0);break;case"B":case"BB":case"BBB":Dt=Ii(pi.DayPeriods,Mt.Abbreviated,ut.Format,!0);break;case"BBBB":Dt=Ii(pi.DayPeriods,Mt.Wide,ut.Format,!0);break;case"BBBBB":Dt=Ii(pi.DayPeriods,Mt.Narrow,ut.Format,!0);break;case"h":Dt=Bi(ri.Hours,1,-12);break;case"hh":Dt=Bi(ri.Hours,2,-12);break;case"H":Dt=Bi(ri.Hours,1);break;case"HH":Dt=Bi(ri.Hours,2);break;case"m":Dt=Bi(ri.Minutes,1);break;case"mm":Dt=Bi(ri.Minutes,2);break;case"s":Dt=Bi(ri.Seconds,1);break;case"ss":Dt=Bi(ri.Seconds,2);break;case"S":Dt=Bi(ri.FractionalSeconds,1);break;case"SS":Dt=Bi(ri.FractionalSeconds,2);break;case"SSS":Dt=Bi(ri.FractionalSeconds,3);break;case"Z":case"ZZ":case"ZZZ":Dt=Jt(Gn.Short);break;case"ZZZZZ":Dt=Jt(Gn.Extended);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":Dt=Jt(Gn.ShortGMT);break;case"OOOO":case"ZZZZ":case"zzzz":Dt=Jt(Gn.Long);break;default:return null}return mt[_e]=Dt,Dt}(vs);La+=Qo?Qo(mn,Re,ia):"''"===vs?"'":vs.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),La}function Bn(_e,Dt,Re){const tt=new Date(0);return tt.setFullYear(_e,Dt,Re),tt.setHours(0,0,0),tt}function Mn(_e,Dt){const Re=pn(_e);if(hn[Re]??={},hn[Re][Dt])return hn[Re][Dt];let tt="";switch(Dt){case"shortDate":tt=on(_e,Wt.Short);break;case"mediumDate":tt=on(_e,Wt.Medium);break;case"longDate":tt=on(_e,Wt.Long);break;case"fullDate":tt=on(_e,Wt.Full);break;case"shortTime":tt=Cn(_e,Wt.Short);break;case"mediumTime":tt=Cn(_e,Wt.Medium);break;case"longTime":tt=Cn(_e,Wt.Long);break;case"fullTime":tt=Cn(_e,Wt.Full);break;case"short":const mn=Mn(_e,"shortTime"),gi=Mn(_e,"shortDate");tt=ni(tn(_e,Wt.Short),[mn,gi]);break;case"medium":const rr=Mn(_e,"mediumTime"),or=Mn(_e,"mediumDate");tt=ni(tn(_e,Wt.Medium),[rr,or]);break;case"long":const ia=Mn(_e,"longTime"),La=Mn(_e,"longDate");tt=ni(tn(_e,Wt.Long),[ia,La]);break;case"full":const vs=Mn(_e,"fullTime"),Qo=Mn(_e,"fullDate");tt=ni(tn(_e,Wt.Full),[vs,Qo])}return tt&&(hn[Re][Dt]=tt),tt}function ni(_e,Dt){return Dt&&(_e=_e.replace(/\{([^}]+)}/g,function(Re,tt){return null!=Dt&&tt in Dt?Dt[tt]:Re})),_e}function qn(_e,Dt,Re="-",tt,mn){let gi="";(_e<0||mn&&_e<=0)&&(mn?_e=1-_e:(_e=-_e,gi=Re));let rr=String(_e);for(;rr.length<Dt;)rr="0"+rr;return tt&&(rr=rr.slice(rr.length-Dt)),gi+rr}function Bi(_e,Dt,Re=0,tt=!1,mn=!1){return function(gi,rr){let or=function Gi(_e,Dt){switch(_e){case ri.FullYear:return Dt.getFullYear();case ri.Month:return Dt.getMonth();case ri.Date:return Dt.getDate();case ri.Hours:return Dt.getHours();case ri.Minutes:return Dt.getMinutes();case ri.Seconds:return Dt.getSeconds();case ri.FractionalSeconds:return Dt.getMilliseconds();case ri.Day:return Dt.getDay();default:throw new Error(`Unknown DateType value "${_e}".`)}}(_e,gi);if((Re>0||or>-Re)&&(or+=Re),_e===ri.Hours)0===or&&-12===Re&&(or=12);else if(_e===ri.FractionalSeconds)return function Ti(_e,Dt){return qn(_e,3).substring(0,Dt)}(or,Dt);const ia=fi(rr,It.MinusSign);return qn(or,Dt,ia,tt,mn)}}function Ii(_e,Dt,Re=ut.Format,tt=!1){return function(mn,gi){return function Ki(_e,Dt,Re,tt,mn,gi){switch(Re){case pi.Months:return An(Dt,mn,tt)[_e.getMonth()];case pi.Days:return ji(Dt,mn,tt)[_e.getDay()];case pi.DayPeriods:const rr=_e.getHours(),or=_e.getMinutes();if(gi){const La=Qi(Dt),vs=Xr(Dt,mn,tt),Qo=La.findIndex(ll=>{if(Array.isArray(ll)){const[Sa,$o]=ll,Mc=rr>=Sa.hours&&or>=Sa.minutes,yc=rr<$o.hours||rr===$o.hours&&or<$o.minutes;if(Sa.hours<$o.hours){if(Mc&&yc)return!0}else if(Mc||yc)return!0}else if(ll.hours===rr&&ll.minutes===or)return!0;return!1});if(-1!==Qo)return vs[Qo]}return Wn(Dt,mn,tt)[rr<12?0:1];case pi.Eras:return St(Dt,tt)[_e.getFullYear()<=0?0:1];default:throw new Error(`unexpected translation type ${Re}`)}}(mn,gi,_e,Dt,Re,tt)}}function Jt(_e){return function(Dt,Re,tt){const mn=-1*tt,gi=fi(Re,It.MinusSign),rr=mn>0?Math.floor(mn/60):Math.ceil(mn/60);switch(_e){case Gn.Short:return(mn>=0?"+":"")+qn(rr,2,gi)+qn(Math.abs(mn%60),2,gi);case Gn.ShortGMT:return"GMT"+(mn>=0?"+":"")+qn(rr,1,gi);case Gn.Long:return"GMT"+(mn>=0?"+":"")+qn(rr,2,gi)+":"+qn(Math.abs(mn%60),2,gi);case Gn.Extended:return 0===tt?"Z":(mn>=0?"+":"")+qn(rr,2,gi)+":"+qn(Math.abs(mn%60),2,gi);default:throw new Error(`Unknown zone width "${_e}"`)}}}const hi=0,Ft=4;function sn(_e){const Dt=_e.getDay(),Re=0===Dt?-3:Ft-Dt;return Bn(_e.getFullYear(),_e.getMonth(),_e.getDate()+Re)}function Ve(_e,Dt=!1){return function(Re,tt){let mn;if(Dt){const gi=new Date(Re.getFullYear(),Re.getMonth(),1).getDay()-1,rr=Re.getDate();mn=1+Math.floor((rr+gi)/7)}else{const gi=sn(Re),rr=function it(_e){const Dt=Bn(_e,hi,1).getDay();return Bn(_e,0,1+(Dt<=Ft?Ft:Ft+7)-Dt)}(gi.getFullYear()),or=gi.getTime()-rr.getTime();mn=1+Math.round(or/6048e5)}return qn(mn,_e,fi(tt,It.MinusSign))}}function He(_e,Dt=!1){return function(Re,tt){return qn(sn(Re).getFullYear(),_e,fi(tt,It.MinusSign),Dt)}}const mt={};function nn(_e,Dt){_e=_e.replace(/:/g,"");const Re=Date.parse("Jan 01, 1970 00:00:00 "+_e)/6e4;return isNaN(Re)?Dt:Re}function Bo(_e){return _e instanceof Date&&!isNaN(_e.valueOf())}const Eo=/^(\d+)?\.((\d+)(-(\d+))?)?$/,Ro=22,Ls=".",ol="0",Va=";",Ao=",",za="#",vl="\xa4",Na="%";function _l(_e,Dt,Re,tt,mn,gi,rr=!1){let or="",ia=!1;if(isFinite(_e)){let La=function Qr(_e){let tt,mn,gi,rr,or,Dt=Math.abs(_e)+"",Re=0;for((mn=Dt.indexOf(Ls))>-1&&(Dt=Dt.replace(Ls,"")),(gi=Dt.search(/e/i))>0?(mn<0&&(mn=gi),mn+=+Dt.slice(gi+1),Dt=Dt.substring(0,gi)):mn<0&&(mn=Dt.length),gi=0;Dt.charAt(gi)===ol;gi++);if(gi===(or=Dt.length))tt=[0],mn=1;else{for(or--;Dt.charAt(or)===ol;)or--;for(mn-=gi,tt=[],rr=0;gi<=or;gi++,rr++)tt[rr]=Number(Dt.charAt(gi))}return mn>Ro&&(tt=tt.splice(0,Ro-1),Re=mn-1,mn=1),{digits:tt,exponent:Re,integerLen:mn}}(_e);rr&&(La=function xl(_e){if(0===_e.digits[0])return _e;const Dt=_e.digits.length-_e.integerLen;return _e.exponent?_e.exponent+=2:(0===Dt?_e.digits.push(0,0):1===Dt&&_e.digits.push(0),_e.integerLen+=2),_e}(La));let vs=Dt.minInt,Qo=Dt.minFrac,ll=Dt.maxFrac;if(gi){const ne=gi.match(Eo);if(null===ne)throw new Error(`${gi} is not a valid digit info`);const Pe=ne[1],rt=ne[3],Ut=ne[5];null!=Pe&&(vs=Ya(Pe)),null!=rt&&(Qo=Ya(rt)),null!=Ut?ll=Ya(Ut):null!=rt&&Qo>ll&&(ll=Qo)}!function dl(_e,Dt,Re){if(Dt>Re)throw new Error(`The minimum number of digits after fraction (${Dt}) is higher than the maximum (${Re}).`);let tt=_e.digits,mn=tt.length-_e.integerLen;const gi=Math.min(Math.max(Dt,mn),Re);let rr=gi+_e.integerLen,or=tt[rr];if(rr>0){tt.splice(Math.max(_e.integerLen,rr));for(let Qo=rr;Qo<tt.length;Qo++)tt[Qo]=0}else{mn=Math.max(0,mn),_e.integerLen=1,tt.length=Math.max(1,rr=gi+1),tt[0]=0;for(let Qo=1;Qo<rr;Qo++)tt[Qo]=0}if(or>=5)if(rr-1<0){for(let Qo=0;Qo>rr;Qo--)tt.unshift(0),_e.integerLen++;tt.unshift(1),_e.integerLen++}else tt[rr-1]++;for(;mn<Math.max(0,gi);mn++)tt.push(0);let ia=0!==gi;const La=Dt+_e.integerLen,vs=tt.reduceRight(function(Qo,ll,Sa,$o){return $o[Sa]=(ll+=Qo)<10?ll:ll-10,ia&&(0===$o[Sa]&&Sa>=La?$o.pop():ia=!1),ll>=10?1:0},0);vs&&(tt.unshift(vs),_e.integerLen++)}(La,Qo,ll);let Sa=La.digits,$o=La.integerLen;const Mc=La.exponent;let yc=[];for(ia=Sa.every(ne=>!ne);$o<vs;$o++)Sa.unshift(0);for(;$o<0;$o++)Sa.unshift(0);$o>0?yc=Sa.splice($o,Sa.length):(yc=Sa,Sa=[0]);const Ue=[];for(Sa.length>=Dt.lgSize&&Ue.unshift(Sa.splice(-Dt.lgSize,Sa.length).join(""));Sa.length>Dt.gSize;)Ue.unshift(Sa.splice(-Dt.gSize,Sa.length).join(""));Sa.length&&Ue.unshift(Sa.join("")),or=Ue.join(fi(Re,tt)),yc.length&&(or+=fi(Re,mn)+yc.join("")),Mc&&(or+=fi(Re,It.Exponential)+"+"+Mc)}else or=fi(Re,It.Infinity);return or=_e<0&&!ia?Dt.negPre+or+Dt.negSuf:Dt.posPre+or+Dt.posSuf,or}function gs(_e,Dt,Re,tt,mn){const rr=no(Zn(Dt,Ae.Currency),fi(Dt,It.MinusSign));return rr.minFrac=ci(tt),rr.maxFrac=rr.minFrac,_l(_e,rr,Dt,It.CurrencyGroup,It.CurrencyDecimal,mn).replace(vl,Re).replace(vl,"").trim()}function Zs(_e,Dt,Re){return _l(_e,no(Zn(Dt,Ae.Percent),fi(Dt,It.MinusSign)),Dt,It.Group,It.Decimal,Re,!0).replace(new RegExp(Na,"g"),fi(Dt,It.PercentSign))}function oa(_e,Dt,Re){return _l(_e,no(Zn(Dt,Ae.Decimal),fi(Dt,It.MinusSign)),Dt,It.Group,It.Decimal,Re)}function no(_e,Dt="-"){const Re={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},tt=_e.split(Va),mn=tt[0],gi=tt[1],rr=-1!==mn.indexOf(Ls)?mn.split(Ls):[mn.substring(0,mn.lastIndexOf(ol)+1),mn.substring(mn.lastIndexOf(ol)+1)],or=rr[0],ia=rr[1]||"";Re.posPre=or.substring(0,or.indexOf(za));for(let vs=0;vs<ia.length;vs++){const Qo=ia.charAt(vs);Qo===ol?Re.minFrac=Re.maxFrac=vs+1:Qo===za?Re.maxFrac=vs+1:Re.posSuf+=Qo}const La=or.split(Ao);if(Re.gSize=La[1]?La[1].length:0,Re.lgSize=La[2]||La[1]?(La[2]||La[1]).length:0,gi){const vs=mn.length-Re.posPre.length-Re.posSuf.length,Qo=gi.indexOf(za);Re.negPre=gi.substring(0,Qo).replace(/'/g,""),Re.negSuf=gi.slice(Qo+vs).replace(/'/g,"")}else Re.negPre=Dt+Re.posPre,Re.negSuf=Re.posSuf;return Re}function Ya(_e){const Dt=parseInt(_e);if(isNaN(Dt))throw new Error("Invalid integer literal when parsing "+_e);return Dt}let Lo=(()=>{class _e{static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:function(tt){let mn=null;return tt?mn=new tt:(gi=e.\u0275\u0275inject(e.LOCALE_ID),mn=new jt(gi)),mn;var gi},providedIn:"root"})}return _e})();function ko(_e,Dt,Re,tt){let mn=`=${_e}`;if(Dt.indexOf(mn)>-1||(mn=Re.getPluralCategory(_e,tt),Dt.indexOf(mn)>-1))return mn;if(Dt.indexOf("other")>-1)return"other";throw new Error(`No plural message found for value "${_e}"`)}let jt=(()=>{class _e extends Lo{constructor(Re){super(),this.locale=Re}getPluralCategory(Re,tt){switch(cr(tt||this.locale)(Re)){case dt.Zero:return"zero";case dt.One:return"one";case dt.Two:return"two";case dt.Few:return"few";case dt.Many:return"many";default:return"other"}}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275inject(e.LOCALE_ID))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:_e.\u0275fac})}return _e})();function In(_e,Dt,Re){return(0,e.\u0275registerLocaleData)(_e,Dt,Re)}function Rt(_e,Dt){Dt=encodeURIComponent(Dt);for(const Re of _e.split(";")){const tt=Re.indexOf("="),[mn,gi]=-1==tt?[Re,""]:[Re.slice(0,tt),Re.slice(tt+1)];if(mn.trim()===Dt)return decodeURIComponent(gi)}return null}const jn=/\s+/,Fi=[];let Ui=(()=>{class _e{constructor(Re,tt){this._ngEl=Re,this._renderer=tt,this.initialClasses=Fi,this.stateMap=new Map}set klass(Re){this.initialClasses=null!=Re?Re.trim().split(jn):Fi}set ngClass(Re){this.rawClass="string"==typeof Re?Re.trim().split(jn):Re}ngDoCheck(){for(const tt of this.initialClasses)this._updateState(tt,!0);const Re=this.rawClass;if(Array.isArray(Re)||Re instanceof Set)for(const tt of Re)this._updateState(tt,!0);else if(null!=Re)for(const tt of Object.keys(Re))this._updateState(tt,!!Re[tt]);this._applyStateDiff()}_updateState(Re,tt){const mn=this.stateMap.get(Re);void 0!==mn?(mn.enabled!==tt&&(mn.changed=!0,mn.enabled=tt),mn.touched=!0):this.stateMap.set(Re,{enabled:tt,changed:!0,touched:!0})}_applyStateDiff(){for(const Re of this.stateMap){const tt=Re[0],mn=Re[1];mn.changed?(this._toggleClass(tt,mn.enabled),mn.changed=!1):mn.touched||(mn.enabled&&this._toggleClass(tt,!1),this.stateMap.delete(tt)),mn.touched=!1}}_toggleClass(Re,tt){(Re=Re.trim()).length>0&&Re.split(jn).forEach(mn=>{tt?this._renderer.addClass(this._ngEl.nativeElement,mn):this._renderer.removeClass(this._ngEl.nativeElement,mn)})}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"},standalone:!0})}return _e})(),ar=(()=>{class _e{constructor(Re){this._viewContainerRef=Re,this.ngComponentOutlet=null,this._inputsUsed=new Map}_needToReCreateNgModuleInstance(Re){return void 0!==Re.ngComponentOutletNgModule||void 0!==Re.ngComponentOutletNgModuleFactory}_needToReCreateComponentInstance(Re){return void 0!==Re.ngComponentOutlet||void 0!==Re.ngComponentOutletContent||void 0!==Re.ngComponentOutletInjector||this._needToReCreateNgModuleInstance(Re)}ngOnChanges(Re){if(this._needToReCreateComponentInstance(Re)&&(this._viewContainerRef.clear(),this._inputsUsed.clear(),this._componentRef=void 0,this.ngComponentOutlet)){const tt=this.ngComponentOutletInjector||this._viewContainerRef.parentInjector;this._needToReCreateNgModuleInstance(Re)&&(this._moduleRef?.destroy(),this._moduleRef=this.ngComponentOutletNgModule?(0,e.createNgModule)(this.ngComponentOutletNgModule,er(tt)):this.ngComponentOutletNgModuleFactory?this.ngComponentOutletNgModuleFactory.create(er(tt)):void 0),this._componentRef=this._viewContainerRef.createComponent(this.ngComponentOutlet,{injector:tt,ngModuleRef:this._moduleRef,projectableNodes:this.ngComponentOutletContent})}}ngDoCheck(){if(this._componentRef){if(this.ngComponentOutletInputs)for(const Re of Object.keys(this.ngComponentOutletInputs))this._inputsUsed.set(Re,!0);this._applyInputStateDiff(this._componentRef)}}ngOnDestroy(){this._moduleRef?.destroy()}_applyInputStateDiff(Re){for(const[tt,mn]of this._inputsUsed)mn?(Re.setInput(tt,this.ngComponentOutletInputs[tt]),this._inputsUsed.set(tt,!1)):(Re.setInput(tt,void 0),this._inputsUsed.delete(tt))}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngComponentOutlet",""]],inputs:{ngComponentOutlet:"ngComponentOutlet",ngComponentOutletInputs:"ngComponentOutletInputs",ngComponentOutletInjector:"ngComponentOutletInjector",ngComponentOutletContent:"ngComponentOutletContent",ngComponentOutletNgModule:"ngComponentOutletNgModule",ngComponentOutletNgModuleFactory:"ngComponentOutletNgModuleFactory"},standalone:!0,features:[e.\u0275\u0275NgOnChangesFeature]})}return _e})();function er(_e){return _e.get(e.NgModuleRef).injector}class Or{constructor(Dt,Re,tt,mn){this.$implicit=Dt,this.ngForOf=Re,this.index=tt,this.count=mn}get first(){return 0===this.index}get last(){return this.index===this.count-1}get even(){return this.index%2==0}get odd(){return!this.even}}let Tt=(()=>{class _e{set ngForOf(Re){this._ngForOf=Re,this._ngForOfDirty=!0}set ngForTrackBy(Re){this._trackByFn=Re}get ngForTrackBy(){return this._trackByFn}constructor(Re,tt,mn){this._viewContainer=Re,this._template=tt,this._differs=mn,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForTemplate(Re){Re&&(this._template=Re)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;const Re=this._ngForOf;!this._differ&&Re&&(this._differ=this._differs.find(Re).create(this.ngForTrackBy))}if(this._differ){const Re=this._differ.diff(this._ngForOf);Re&&this._applyChanges(Re)}}_applyChanges(Re){const tt=this._viewContainer;Re.forEachOperation((mn,gi,rr)=>{if(null==mn.previousIndex)tt.createEmbeddedView(this._template,new Or(mn.item,this._ngForOf,-1,-1),null===rr?void 0:rr);else if(null==rr)tt.remove(null===gi?void 0:gi);else if(null!==gi){const or=tt.get(gi);tt.move(or,rr),cn(or,mn)}});for(let mn=0,gi=tt.length;mn<gi;mn++){const or=tt.get(mn).context;or.index=mn,or.count=gi,or.ngForOf=this._ngForOf}Re.forEachIdentityChange(mn=>{cn(tt.get(mn.currentIndex),mn)})}static ngTemplateContextGuard(Re,tt){return!0}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(e.TemplateRef),e.\u0275\u0275directiveInject(e.IterableDiffers))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"},standalone:!0})}return _e})();function cn(_e,Dt){_e.context.$implicit=Dt.item}let Ri=(()=>{class _e{constructor(Re,tt){this._viewContainer=Re,this._context=new Un,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=tt}set ngIf(Re){this._context.$implicit=this._context.ngIf=Re,this._updateView()}set ngIfThen(Re){Yi("ngIfThen",Re),this._thenTemplateRef=Re,this._thenViewRef=null,this._updateView()}set ngIfElse(Re){Yi("ngIfElse",Re),this._elseTemplateRef=Re,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngTemplateContextGuard(Re,tt){return!0}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(e.TemplateRef))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"},standalone:!0})}return _e})();class Un{constructor(){this.$implicit=null,this.ngIf=null}}function Yi(_e,Dt){if(Dt&&!Dt.createEmbeddedView)throw new Error(`${_e} must be a TemplateRef, but received '${(0,e.\u0275stringify)(Dt)}'.`)}class Wi{constructor(Dt,Re){this._viewContainerRef=Dt,this._templateRef=Re,this._created=!1}create(){this._created=!0,this._viewContainerRef.createEmbeddedView(this._templateRef)}destroy(){this._created=!1,this._viewContainerRef.clear()}enforceState(Dt){Dt&&!this._created?this.create():!Dt&&this._created&&this.destroy()}}let fr=(()=>{class _e{constructor(){this._defaultViews=[],this._defaultUsed=!1,this._caseCount=0,this._lastCaseCheckIndex=0,this._lastCasesMatched=!1}set ngSwitch(Re){this._ngSwitch=Re,0===this._caseCount&&this._updateDefaultCases(!0)}_addCase(){return this._caseCount++}_addDefault(Re){this._defaultViews.push(Re)}_matchCase(Re){const tt=Re===this._ngSwitch;return this._lastCasesMatched||=tt,this._lastCaseCheckIndex++,this._lastCaseCheckIndex===this._caseCount&&(this._updateDefaultCases(!this._lastCasesMatched),this._lastCaseCheckIndex=0,this._lastCasesMatched=!1),tt}_updateDefaultCases(Re){if(this._defaultViews.length>0&&Re!==this._defaultUsed){this._defaultUsed=Re;for(const tt of this._defaultViews)tt.enforceState(Re)}}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngSwitch",""]],inputs:{ngSwitch:"ngSwitch"},standalone:!0})}return _e})(),Li=(()=>{class _e{constructor(Re,tt,mn){this.ngSwitch=mn,mn._addCase(),this._view=new Wi(Re,tt)}ngDoCheck(){this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase))}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(e.TemplateRef),e.\u0275\u0275directiveInject(fr,9))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngSwitchCase",""]],inputs:{ngSwitchCase:"ngSwitchCase"},standalone:!0})}return _e})(),Vo=(()=>{class _e{constructor(Re,tt,mn){mn._addDefault(new Wi(Re,tt))}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(e.TemplateRef),e.\u0275\u0275directiveInject(fr,9))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngSwitchDefault",""]],standalone:!0})}return _e})(),ks=(()=>{class _e{constructor(Re){this._localization=Re,this._caseViews={}}set ngPlural(Re){this._updateView(Re)}addCase(Re,tt){this._caseViews[Re]=tt}_updateView(Re){this._clearViews();const mn=ko(Re,Object.keys(this._caseViews),this._localization);this._activateView(this._caseViews[mn])}_clearViews(){this._activeView&&this._activeView.destroy()}_activateView(Re){Re&&(this._activeView=Re,this._activeView.create())}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(Lo))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngPlural",""]],inputs:{ngPlural:"ngPlural"},standalone:!0})}return _e})(),Jo=(()=>{class _e{constructor(Re,tt,mn,gi){this.value=Re;const rr=!isNaN(Number(Re));gi.addCase(rr?`=${Re}`:Re,new Wi(mn,tt))}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275injectAttribute("ngPluralCase"),e.\u0275\u0275directiveInject(e.TemplateRef),e.\u0275\u0275directiveInject(e.ViewContainerRef),e.\u0275\u0275directiveInject(ks,1))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngPluralCase",""]],standalone:!0})}return _e})(),$s=(()=>{class _e{constructor(Re,tt,mn){this._ngEl=Re,this._differs=tt,this._renderer=mn,this._ngStyle=null,this._differ=null}set ngStyle(Re){this._ngStyle=Re,!this._differ&&Re&&(this._differ=this._differs.find(Re).create())}ngDoCheck(){if(this._differ){const Re=this._differ.diff(this._ngStyle);Re&&this._applyChanges(Re)}}_setStyle(Re,tt){const[mn,gi]=Re.split("."),rr=-1===mn.indexOf("-")?void 0:e.RendererStyleFlags2.DashCase;null!=tt?this._renderer.setStyle(this._ngEl.nativeElement,mn,gi?`${tt}${gi}`:tt,rr):this._renderer.removeStyle(this._ngEl.nativeElement,mn,rr)}_applyChanges(Re){Re.forEachRemovedItem(tt=>this._setStyle(tt.key,null)),Re.forEachAddedItem(tt=>this._setStyle(tt.key,tt.currentValue)),Re.forEachChangedItem(tt=>this._setStyle(tt.key,tt.currentValue))}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.KeyValueDiffers),e.\u0275\u0275directiveInject(e.Renderer2))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"},standalone:!0})}return _e})(),Js=(()=>{class _e{constructor(Re){this._viewContainerRef=Re,this._viewRef=null,this.ngTemplateOutletContext=null,this.ngTemplateOutlet=null,this.ngTemplateOutletInjector=null}ngOnChanges(Re){if(this._shouldRecreateView(Re)){const tt=this._viewContainerRef;if(this._viewRef&&tt.remove(tt.indexOf(this._viewRef)),!this.ngTemplateOutlet)return void(this._viewRef=null);const mn=this._createContextForwardProxy();this._viewRef=tt.createEmbeddedView(this.ngTemplateOutlet,mn,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(Re){return!!Re.ngTemplateOutlet||!!Re.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(Re,tt,mn)=>!!this.ngTemplateOutletContext&&Reflect.set(this.ngTemplateOutletContext,tt,mn),get:(Re,tt,mn)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,tt,mn)}})}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ViewContainerRef))};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},standalone:!0,features:[e.\u0275\u0275NgOnChangesFeature]})}return _e})();function Ws(_e,Dt){return new e.\u0275RuntimeError(2100,!1)}class es{createSubscription(Dt,Re){return(0,e.untracked)(()=>Dt.subscribe({next:Re,error:tt=>{throw tt}}))}dispose(Dt){(0,e.untracked)(()=>Dt.unsubscribe())}}class Ma{createSubscription(Dt,Re){return Dt.then(Re,tt=>{throw tt})}dispose(Dt){}}const ts=new Ma,wo=new es;let ea=(()=>{class _e{constructor(Re){this._latestValue=null,this.markForCheckOnValueUpdate=!0,this._subscription=null,this._obj=null,this._strategy=null,this._ref=Re}ngOnDestroy(){this._subscription&&this._dispose(),this._ref=null}transform(Re){if(!this._obj){if(Re)try{this.markForCheckOnValueUpdate=!1,this._subscribe(Re)}finally{this.markForCheckOnValueUpdate=!0}return this._latestValue}return Re!==this._obj?(this._dispose(),this.transform(Re)):this._latestValue}_subscribe(Re){this._obj=Re,this._strategy=this._selectStrategy(Re),this._subscription=this._strategy.createSubscription(Re,tt=>this._updateLatestValue(Re,tt))}_selectStrategy(Re){if((0,e.\u0275isPromise)(Re))return ts;if((0,e.\u0275isSubscribable)(Re))return wo;throw Ws()}_dispose(){this._strategy.dispose(this._subscription),this._latestValue=null,this._subscription=null,this._obj=null}_updateLatestValue(Re,tt){Re===this._obj&&(this._latestValue=tt,this.markForCheckOnValueUpdate&&this._ref?.markForCheck())}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.ChangeDetectorRef,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"async",type:_e,pure:!1,standalone:!0})}return _e})(),ga=(()=>{class _e{transform(Re){if(null==Re)return null;if("string"!=typeof Re)throw Ws();return Re.toLowerCase()}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"lowercase",type:_e,pure:!0,standalone:!0})}return _e})();const sl=/(?:[0-9A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])\S*/g;let fl=(()=>{class _e{transform(Re){if(null==Re)return null;if("string"!=typeof Re)throw Ws();return Re.replace(sl,tt=>tt[0].toUpperCase()+tt.slice(1).toLowerCase())}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"titlecase",type:_e,pure:!0,standalone:!0})}return _e})(),Ia=(()=>{class _e{transform(Re){if(null==Re)return null;if("string"!=typeof Re)throw Ws();return Re.toUpperCase()}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"uppercase",type:_e,pure:!0,standalone:!0})}return _e})();const Kc=new e.InjectionToken(""),wa=new e.InjectionToken("");let Sl=(()=>{class _e{constructor(Re,tt,mn){this.locale=Re,this.defaultTimezone=tt,this.defaultOptions=mn}transform(Re,tt,mn,gi){if(null==Re||""===Re||Re!=Re)return null;try{return At(Re,tt??this.defaultOptions?.dateFormat??"mediumDate",gi||this.locale,mn??this.defaultOptions?.timezone??this.defaultTimezone??void 0)}catch(rr){throw Ws()}}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.LOCALE_ID,16),e.\u0275\u0275directiveInject(Kc,24),e.\u0275\u0275directiveInject(wa,24))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"date",type:_e,pure:!0,standalone:!0})}return _e})();const qc=/#/g;let la=(()=>{class _e{constructor(Re){this._localization=Re}transform(Re,tt,mn){if(null==Re)return"";if("object"!=typeof tt||null===tt)throw Ws();return tt[ko(Re,Object.keys(tt),this._localization,mn)].replace(qc,Re.toString())}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(Lo,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"i18nPlural",type:_e,pure:!0,standalone:!0})}return _e})(),pl=(()=>{class _e{transform(Re,tt){if(null==Re)return"";if("object"!=typeof tt||"string"!=typeof Re)throw Ws();return tt.hasOwnProperty(Re)?tt[Re]:tt.hasOwnProperty("other")?tt.other:""}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"i18nSelect",type:_e,pure:!0,standalone:!0})}return _e})(),Sc=(()=>{class _e{transform(Re){return JSON.stringify(Re,null,2)}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"json",type:_e,pure:!1,standalone:!0})}return _e})(),Qc=(()=>{class _e{constructor(Re){this.differs=Re,this.keyValues=[],this.compareFn=ql}transform(Re,tt=ql){if(!Re||!(Re instanceof Map)&&"object"!=typeof Re)return null;this.differ??=this.differs.find(Re).create();const mn=this.differ.diff(Re),gi=tt!==this.compareFn;return mn&&(this.keyValues=[],mn.forEachItem(rr=>{this.keyValues.push(function Ec(_e,Dt){return{key:_e,value:Dt}}(rr.key,rr.currentValue))})),(mn||gi)&&(this.keyValues.sort(tt),this.compareFn=tt),this.keyValues}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.KeyValueDiffers,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"keyvalue",type:_e,pure:!1,standalone:!0})}return _e})();function ql(_e,Dt){const Re=_e.key,tt=Dt.key;if(Re===tt)return 0;if(void 0===Re)return 1;if(void 0===tt)return-1;if(null===Re)return 1;if(null===tt)return-1;if("string"==typeof Re&&"string"==typeof tt)return Re<tt?-1:1;if("number"==typeof Re&&"number"==typeof tt)return Re-tt;if("boolean"==typeof Re&&"boolean"==typeof tt)return Re<tt?-1:1;const mn=String(Re),gi=String(tt);return mn==gi?0:mn<gi?-1:1}let ec=(()=>{class _e{constructor(Re){this._locale=Re}transform(Re,tt,mn){if(!Il(Re))return null;mn||=this._locale;try{return oa(Xa(Re),mn,tt)}catch(gi){throw Ws()}}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.LOCALE_ID,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"number",type:_e,pure:!0,standalone:!0})}return _e})(),Yc=(()=>{class _e{constructor(Re){this._locale=Re}transform(Re,tt,mn){if(!Il(Re))return null;mn||=this._locale;try{return Zs(Xa(Re),mn,tt)}catch(gi){throw Ws()}}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.LOCALE_ID,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"percent",type:_e,pure:!0,standalone:!0})}return _e})(),ca=(()=>{class _e{constructor(Re,tt="USD"){this._locale=Re,this._defaultCurrencyCode=tt}transform(Re,tt=this._defaultCurrencyCode,mn="symbol",gi,rr){if(!Il(Re))return null;rr||=this._locale,"boolean"==typeof mn&&(mn=mn?"symbol":"code");let or=tt||this._defaultCurrencyCode;"code"!==mn&&(or="symbol"===mn||"symbol-narrow"===mn?uo(or,"symbol"===mn?"wide":"narrow",rr):mn);try{return gs(Xa(Re),rr,or,tt,gi)}catch(ia){throw Ws()}}static#e=this.\u0275fac=function(tt){return new(tt||_e)(e.\u0275\u0275directiveInject(e.LOCALE_ID,16),e.\u0275\u0275directiveInject(e.DEFAULT_CURRENCY_CODE,16))};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"currency",type:_e,pure:!0,standalone:!0})}return _e})();function Il(_e){return!(null==_e||""===_e||_e!=_e)}function Xa(_e){if("string"==typeof _e&&!isNaN(Number(_e)-parseFloat(_e)))return Number(_e);if("number"!=typeof _e)throw new Error(`${_e} is not a number`);return _e}let Rl=(()=>{class _e{transform(Re,tt,mn){if(null==Re)return null;if(!this.supports(Re))throw Ws();return Re.slice(tt,mn)}supports(Re){return"string"==typeof Re||Array.isArray(Re)}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275pipe=e.\u0275\u0275definePipe({name:"slice",type:_e,pure:!1,standalone:!0})}return _e})(),sa=(()=>{class _e{static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:_e});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({})}return _e})();const Lu="browser",Aa="server";function ku(_e){return _e===Lu}function Ql(_e){return _e===Aa}const sc=new e.Version("18.2.8");let ta=(()=>{class _e{static#e=this.\u0275prov=(0,e.\u0275\u0275defineInjectable)({token:_e,providedIn:"root",factory:()=>ku((0,e.inject)(e.PLATFORM_ID))?new vc((0,e.inject)(he),window):new Fc})}return _e})();class vc{constructor(Dt,Re){this.document=Dt,this.window=Re,this.offset=()=>[0,0]}setOffset(Dt){this.offset=Array.isArray(Dt)?()=>Dt:Dt}getScrollPosition(){return[this.window.scrollX,this.window.scrollY]}scrollToPosition(Dt){this.window.scrollTo(Dt[0],Dt[1])}scrollToAnchor(Dt){const Re=function xu(_e,Dt){const Re=_e.getElementById(Dt)||_e.getElementsByName(Dt)[0];if(Re)return Re;if("function"==typeof _e.createTreeWalker&&_e.body&&"function"==typeof _e.body.attachShadow){const tt=_e.createTreeWalker(_e.body,NodeFilter.SHOW_ELEMENT);let mn=tt.currentNode;for(;mn;){const gi=mn.shadowRoot;if(gi){const rr=gi.getElementById(Dt)||gi.querySelector(`[name="${Dt}"]`);if(rr)return rr}mn=tt.nextNode()}}return null}(this.document,Dt);Re&&(this.scrollToElement(Re),Re.focus())}setHistoryScrollRestoration(Dt){this.window.history.scrollRestoration=Dt}scrollToElement(Dt){const Re=Dt.getBoundingClientRect(),tt=Re.left+this.window.pageXOffset,mn=Re.top+this.window.pageYOffset,gi=this.offset();this.window.scrollTo(tt-gi[0],mn-gi[1])}}class Fc{setOffset(Dt){}getScrollPosition(){return[0,0]}scrollToPosition(Dt){}scrollToAnchor(Dt){}setHistoryScrollRestoration(Dt){}}class po{}const Ll="20";function kl(_e){return/^https?:\/\//.test(_e)}function fu(_e){if("string"!=typeof _e||""===_e.trim())return!1;try{return new URL(_e),!0}catch{return!1}}function Ke(_e){return _e.startsWith("/")?_e.slice(1):_e}const Se=_e=>_e.src,re=new e.InjectionToken("",{providedIn:"root",factory:()=>Se});function Ge(_e,Dt){return function(tt){return fu(tt)||function xt(){throw new e.\u0275RuntimeError(2959,!1)}(),tt=function Rc(_e){return _e.endsWith("/")?_e.slice(0,-1):_e}(tt),[{provide:re,useValue:rr=>(kl(rr.src)&&function Qt(){throw new e.\u0275RuntimeError(2959,!1)}(),_e(tt,{...rr,src:Ke(rr.src)}))}]}}const kn=Ge(bi);function bi(_e,Dt){let Re="format=auto";return Dt.width&&(Re+=`,width=${Dt.width}`),Dt.isPlaceholder&&(Re+=`,quality=${Ll}`),`${_e}/cdn-cgi/image/${Re}/${Dt.src}`}const $i=Ge(Er);function Er(_e,Dt){let tt="f_auto,"+(Dt.isPlaceholder?"q_auto:low":"q_auto");return Dt.width&&(tt+=`,w_${Dt.width}`),`${_e}/image/upload/${tt}/${Dt.src}`}const zr=Ge(ho);function ho(_e,Dt){const{src:Re,width:tt}=Dt,mn=[];tt&&mn.push(`w-${tt}`),Dt.isPlaceholder&&mn.push(`q-${Ll}`);const gi=mn.length?[_e,`tr:${mn.join(",")}`,Re]:[_e,Re];return new URL(gi.join("/")).href}const Ds=Ge(Xo);function Xo(_e,Dt){const Re=new URL(`${_e}/${Dt.src}`);return Re.searchParams.set("auto","format"),Dt.width&&Re.searchParams.set("w",Dt.width.toString()),Dt.isPlaceholder&&Re.searchParams.set("q",Ll),Re.href}function Je(_e){if(_e&&!fu(_e))throw new e.\u0275RuntimeError(2959,!1);return _e&&(_e=new URL(_e).origin),[{provide:re,useValue:tt=>function Oe(_e,Dt){const Re=new URL(Dt??"https://a/");Re.pathname="/.netlify/images",!kl(_e.src)&&!_e.src.startsWith("/")&&(_e.src="/"+_e.src),Re.searchParams.set("url",_e.src),_e.width&&Re.searchParams.set("w",_e.width.toString());_e.isPlaceholder&&!(_e.loaderParams?.quality??_e.loaderParams?.q)&&Re.searchParams.set("q",Ll);for(const[mn,gi]of Object.entries(_e.loaderParams??{}))at.has(mn)&&Re.searchParams.set(at.get(mn),gi.toString());return"a"===Re.hostname?Re.href.replace(Re.origin,""):Re.href}(tt,_e)}]}const at=new Map([["height","h"],["fit","fit"],["quality","q"],["q","q"],["position","position"]]),fo=new e.InjectionToken(""),Za=new e.InjectionToken("NG_OPTIMIZED_PRELOADED_IMAGES",{providedIn:"root",factory:()=>new Set});let Ks=(()=>{class _e{constructor(){this.preloadedImages=(0,e.inject)(Za),this.document=(0,e.inject)(he)}createPreloadLinkTag(Re,tt,mn,gi){if(this.preloadedImages.has(tt))return;this.preloadedImages.add(tt);const rr=Re.createElement("link");Re.setAttribute(rr,"as","image"),Re.setAttribute(rr,"href",tt),Re.setAttribute(rr,"rel","preload"),Re.setAttribute(rr,"fetchpriority","high"),gi&&Re.setAttribute(rr,"imageSizes",gi),mn&&Re.setAttribute(rr,"imageSrcset",mn),Re.appendChild(this.document.head,rr)}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:_e,factory:_e.\u0275fac,providedIn:"root"})}return _e})();const lc=/^((\s*\d+w\s*(,|$)){1,})$/,nd=[1,2];let Su=(()=>{class _e{constructor(){this.imageLoader=(0,e.inject)(re),this.config=function md(_e){let Dt={};return _e.breakpoints&&(Dt.breakpoints=_e.breakpoints.sort((Re,tt)=>Re-tt)),Object.assign({},e.\u0275IMAGE_CONFIG_DEFAULTS,_e,Dt)}((0,e.inject)(e.\u0275IMAGE_CONFIG)),this.renderer=(0,e.inject)(e.Renderer2),this.imgElement=(0,e.inject)(e.ElementRef).nativeElement,this.injector=(0,e.inject)(e.Injector),this.isServer=Ql((0,e.inject)(e.PLATFORM_ID)),this.preloadLinkCreator=(0,e.inject)(Ks),this.lcpObserver=null,this._renderedSrc=null,this.priority=!1,this.disableOptimizedSrcset=!1,this.fill=!1}ngOnInit(){(0,e.\u0275performanceMarkFeature)("NgOptimizedImage"),this.placeholder&&this.removePlaceholderOnLoad(this.imgElement),this.setHostAttributes()}setHostAttributes(){this.fill?this.sizes||="100vw":(this.setHostAttribute("width",this.width.toString()),this.setHostAttribute("height",this.height.toString())),this.setHostAttribute("loading",this.getLoadingBehavior()),this.setHostAttribute("fetchpriority",this.getFetchPriority()),this.setHostAttribute("ng-img","true");const Re=this.updateSrcAndSrcset();this.sizes&&this.setHostAttribute("sizes",this.sizes),this.isServer&&this.priority&&this.preloadLinkCreator.createPreloadLinkTag(this.renderer,this.getRewrittenSrc(),Re,this.sizes)}ngOnChanges(Re){if(Re.ngSrc&&!Re.ngSrc.isFirstChange()){const tt=this._renderedSrc;this.updateSrcAndSrcset(!0);const mn=this._renderedSrc;null!==this.lcpObserver&&tt&&mn&&tt!==mn&&this.injector.get(e.NgZone).runOutsideAngular(()=>{this.lcpObserver?.updateImage(tt,mn)})}}callImageLoader(Re){let tt=Re;return this.loaderParams&&(tt.loaderParams=this.loaderParams),this.imageLoader(tt)}getLoadingBehavior(){return this.priority||void 0===this.loading?this.priority?"eager":"lazy":this.loading}getFetchPriority(){return this.priority?"high":"auto"}getRewrittenSrc(){return this._renderedSrc||(this._renderedSrc=this.callImageLoader({src:this.ngSrc})),this._renderedSrc}getRewrittenSrcset(){const Re=lc.test(this.ngSrcset);return this.ngSrcset.split(",").filter(mn=>""!==mn).map(mn=>{mn=mn.trim();const gi=Re?parseFloat(mn):parseFloat(mn)*this.width;return`${this.callImageLoader({src:this.ngSrc,width:gi})} ${mn}`}).join(", ")}getAutomaticSrcset(){return this.sizes?this.getResponsiveSrcset():this.getFixedSrcset()}getResponsiveSrcset(){const{breakpoints:Re}=this.config;let tt=Re;return"100vw"===this.sizes?.trim()&&(tt=Re.filter(gi=>gi>=640)),tt.map(gi=>`${this.callImageLoader({src:this.ngSrc,width:gi})} ${gi}w`).join(", ")}updateSrcAndSrcset(Re=!1){Re&&(this._renderedSrc=null);const tt=this.getRewrittenSrc();let mn;return this.setHostAttribute("src",tt),this.ngSrcset?mn=this.getRewrittenSrcset():this.shouldGenerateAutomaticSrcset()&&(mn=this.getAutomaticSrcset()),mn&&this.setHostAttribute("srcset",mn),mn}getFixedSrcset(){return nd.map(tt=>`${this.callImageLoader({src:this.ngSrc,width:this.width*tt})} ${tt}x`).join(", ")}shouldGenerateAutomaticSrcset(){let Re=!1;return this.sizes||(Re=this.width>1920||this.height>1080),!this.disableOptimizedSrcset&&!this.srcset&&this.imageLoader!==Se&&!Re}generatePlaceholder(Re){const{placeholderResolution:tt}=this.config;return!0===Re?`url(${this.callImageLoader({src:this.ngSrc,width:tt,isPlaceholder:!0})})`:"string"==typeof Re?`url(${Re})`:null}shouldBlurPlaceholder(Re){return!Re||!Re.hasOwnProperty("blur")||!!Re.blur}removePlaceholderOnLoad(Re){const tt=()=>{const rr=this.injector.get(e.ChangeDetectorRef);mn(),gi(),this.placeholder=!1,rr.markForCheck()},mn=this.renderer.listen(Re,"load",tt),gi=this.renderer.listen(Re,"error",tt);!function Yl(_e,Dt){_e.complete&&_e.naturalWidth&&Dt()}(Re,tt)}ngOnDestroy(){}setHostAttribute(Re,tt){this.renderer.setAttribute(this.imgElement,Re,tt)}static#e=this.\u0275fac=function(tt){return new(tt||_e)};static#t=this.\u0275dir=e.\u0275\u0275defineDirective({type:_e,selectors:[["img","ngSrc",""]],hostVars:18,hostBindings:function(tt,mn){2&tt&&e.\u0275\u0275styleProp("position",mn.fill?"absolute":null)("width",mn.fill?"100%":null)("height",mn.fill?"100%":null)("inset",mn.fill?"0":null)("background-size",mn.placeholder?"cover":null)("background-position",mn.placeholder?"50% 50%":null)("background-repeat",mn.placeholder?"no-repeat":null)("background-image",mn.placeholder?mn.generatePlaceholder(mn.placeholder):null)("filter",mn.placeholder&&mn.shouldBlurPlaceholder(mn.placeholderConfig)?"blur(15px)":null)},inputs:{ngSrc:[2,"ngSrc","ngSrc",pf],ngSrcset:"ngSrcset",sizes:"sizes",width:[2,"width","width",e.numberAttribute],height:[2,"height","height",e.numberAttribute],loading:"loading",priority:[2,"priority","priority",e.booleanAttribute],loaderParams:"loaderParams",disableOptimizedSrcset:[2,"disableOptimizedSrcset","disableOptimizedSrcset",e.booleanAttribute],fill:[2,"fill","fill",e.booleanAttribute],placeholder:[2,"placeholder","placeholder",hf],placeholderConfig:"placeholderConfig",src:"src",srcset:"srcset"},standalone:!0,features:[e.\u0275\u0275InputTransformsFeature,e.\u0275\u0275NgOnChangesFeature]})}return _e})();function pf(_e){return"string"==typeof _e?_e:(0,e.\u0275unwrapSafeValue)(_e)}function hf(_e){return"string"==typeof _e&&"true"!==_e&&"false"!==_e&&""!==_e?_e:(0,e.booleanAttribute)(_e)}},1626:(Ot,Me,S)=>{S.r(Me),S.d(Me,{FetchBackend:()=>Ht,HTTP_INTERCEPTORS:()=>gn,HTTP_TRANSFER_CACHE_ORIGIN_MAP:()=>Ro,HttpBackend:()=>Ee,HttpClient:()=>ji,HttpClientJsonpModule:()=>Eo,HttpClientModule:()=>Bo,HttpClientXsrfModule:()=>qr,HttpContext:()=>fn,HttpContextToken:()=>ve,HttpErrorResponse:()=>Wt,HttpEventType:()=>Ae,HttpFeatureKind:()=>Ft,HttpHandler:()=>Q,HttpHeaderResponse:()=>ut,HttpHeaders:()=>he,HttpParams:()=>wt,HttpRequest:()=>Pt,HttpResponse:()=>Mt,HttpResponseBase:()=>dt,HttpStatusCode:()=>pn,HttpUrlEncodingCodec:()=>oe,HttpXhrBackend:()=>Mn,HttpXsrfTokenExtractor:()=>Ii,JsonpClientBackend:()=>Gn,JsonpInterceptor:()=>pi,provideHttpClient:()=>sn,withFetch:()=>_r,withInterceptors:()=>Ve,withInterceptorsFromDi:()=>mt,withJsonpSupport:()=>Jn,withNoXsrfProtection:()=>nn,withRequestsMadeViaParent:()=>Sn,withXsrfConfiguration:()=>bt,\u0275HTTP_ROOT_INTERCEPTOR_FNS:()=>Yn,\u0275HttpInterceptingHandler:()=>Ur,\u0275HttpInterceptorHandler:()=>Ur,\u0275REQUESTS_CONTRIBUTE_TO_STABILITY:()=>cr,\u0275withHttpTransferCache:()=>dl});var i=S(4523),e=S(1270),M=S(1647),X=S(9335),ie=S(2168);class Q{}class Ee{}class he{constructor(In){this.normalizedNames=new Map,this.lazyUpdate=null,In?"string"==typeof In?this.lazyInit=()=>{this.headers=new Map,In.split("\n").forEach(Rt=>{const jn=Rt.indexOf(":");if(jn>0){const Fi=Rt.slice(0,jn),Ui=Fi.toLowerCase(),ar=Rt.slice(jn+1).trim();this.maybeSetNormalizedName(Fi,Ui),this.headers.has(Ui)?this.headers.get(Ui).push(ar):this.headers.set(Ui,[ar])}})}:typeof Headers<"u"&&In instanceof Headers?(this.headers=new Map,In.forEach((Rt,jn)=>{this.setHeaderEntries(jn,Rt)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(In).forEach(([Rt,jn])=>{this.setHeaderEntries(Rt,jn)})}:this.headers=new Map}has(In){return this.init(),this.headers.has(In.toLowerCase())}get(In){this.init();const Rt=this.headers.get(In.toLowerCase());return Rt&&Rt.length>0?Rt[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(In){return this.init(),this.headers.get(In.toLowerCase())||null}append(In,Rt){return this.clone({name:In,value:Rt,op:"a"})}set(In,Rt){return this.clone({name:In,value:Rt,op:"s"})}delete(In,Rt){return this.clone({name:In,value:Rt,op:"d"})}maybeSetNormalizedName(In,Rt){this.normalizedNames.has(Rt)||this.normalizedNames.set(Rt,In)}init(){this.lazyInit&&(this.lazyInit instanceof he?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(In=>this.applyUpdate(In)),this.lazyUpdate=null))}copyFrom(In){In.init(),Array.from(In.headers.keys()).forEach(Rt=>{this.headers.set(Rt,In.headers.get(Rt)),this.normalizedNames.set(Rt,In.normalizedNames.get(Rt))})}clone(In){const Rt=new he;return Rt.lazyInit=this.lazyInit&&this.lazyInit instanceof he?this.lazyInit:this,Rt.lazyUpdate=(this.lazyUpdate||[]).concat([In]),Rt}applyUpdate(In){const Rt=In.name.toLowerCase();switch(In.op){case"a":case"s":let jn=In.value;if("string"==typeof jn&&(jn=[jn]),0===jn.length)return;this.maybeSetNormalizedName(In.name,Rt);const Fi=("a"===In.op?this.headers.get(Rt):void 0)||[];Fi.push(...jn),this.headers.set(Rt,Fi);break;case"d":const Ui=In.value;if(Ui){let ar=this.headers.get(Rt);if(!ar)return;ar=ar.filter(er=>-1===Ui.indexOf(er)),0===ar.length?(this.headers.delete(Rt),this.normalizedNames.delete(Rt)):this.headers.set(Rt,ar)}else this.headers.delete(Rt),this.normalizedNames.delete(Rt)}}setHeaderEntries(In,Rt){const jn=(Array.isArray(Rt)?Rt:[Rt]).map(Ui=>Ui.toString()),Fi=In.toLowerCase();this.headers.set(Fi,jn),this.maybeSetNormalizedName(In,Fi)}forEach(In){this.init(),Array.from(this.normalizedNames.keys()).forEach(Rt=>In(this.normalizedNames.get(Rt),this.headers.get(Rt)))}}class oe{encodeKey(In){return je(In)}encodeValue(In){return je(In)}decodeKey(In){return decodeURIComponent(In)}decodeValue(In){return decodeURIComponent(In)}}const ce=/%(\d[a-f0-9])/gi,le={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function je(jt){return encodeURIComponent(jt).replace(ce,(In,Rt)=>le[Rt]??In)}function Et(jt){return`${jt}`}class wt{constructor(In={}){if(this.updates=null,this.cloneFrom=null,this.encoder=In.encoder||new oe,In.fromString){if(In.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=function Z(jt,In){const Rt=new Map;return jt.length>0&&jt.replace(/^\?/,"").split("&").forEach(Fi=>{const Ui=Fi.indexOf("="),[ar,er]=-1==Ui?[In.decodeKey(Fi),""]:[In.decodeKey(Fi.slice(0,Ui)),In.decodeValue(Fi.slice(Ui+1))],Or=Rt.get(ar)||[];Or.push(er),Rt.set(ar,Or)}),Rt}(In.fromString,this.encoder)}else In.fromObject?(this.map=new Map,Object.keys(In.fromObject).forEach(Rt=>{const jn=In.fromObject[Rt],Fi=Array.isArray(jn)?jn.map(Et):[Et(jn)];this.map.set(Rt,Fi)})):this.map=null}has(In){return this.init(),this.map.has(In)}get(In){this.init();const Rt=this.map.get(In);return Rt?Rt[0]:null}getAll(In){return this.init(),this.map.get(In)||null}keys(){return this.init(),Array.from(this.map.keys())}append(In,Rt){return this.clone({param:In,value:Rt,op:"a"})}appendAll(In){const Rt=[];return Object.keys(In).forEach(jn=>{const Fi=In[jn];Array.isArray(Fi)?Fi.forEach(Ui=>{Rt.push({param:jn,value:Ui,op:"a"})}):Rt.push({param:jn,value:Fi,op:"a"})}),this.clone(Rt)}set(In,Rt){return this.clone({param:In,value:Rt,op:"s"})}delete(In,Rt){return this.clone({param:In,value:Rt,op:"d"})}toString(){return this.init(),this.keys().map(In=>{const Rt=this.encoder.encodeKey(In);return this.map.get(In).map(jn=>Rt+"="+this.encoder.encodeValue(jn)).join("&")}).filter(In=>""!==In).join("&")}clone(In){const Rt=new wt({encoder:this.encoder});return Rt.cloneFrom=this.cloneFrom||this,Rt.updates=(this.updates||[]).concat(In),Rt}init(){null===this.map&&(this.map=new Map),null!==this.cloneFrom&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(In=>this.map.set(In,this.cloneFrom.map.get(In))),this.updates.forEach(In=>{switch(In.op){case"a":case"s":const Rt=("a"===In.op?this.map.get(In.param):void 0)||[];Rt.push(Et(In.value)),this.map.set(In.param,Rt);break;case"d":if(void 0===In.value){this.map.delete(In.param);break}{let jn=this.map.get(In.param)||[];const Fi=jn.indexOf(Et(In.value));-1!==Fi&&jn.splice(Fi,1),jn.length>0?this.map.set(In.param,jn):this.map.delete(In.param)}}}),this.cloneFrom=this.updates=null)}}class ve{constructor(In){this.defaultValue=In}}class fn{constructor(){this.map=new Map}set(In,Rt){return this.map.set(In,Rt),this}get(In){return this.map.has(In)||this.map.set(In,In.defaultValue()),this.map.get(In)}delete(In){return this.map.delete(In),this}has(In){return this.map.has(In)}keys(){return this.map.keys()}}function en(jt){return typeof ArrayBuffer<"u"&&jt instanceof ArrayBuffer}function an(jt){return typeof Blob<"u"&&jt instanceof Blob}function un(jt){return typeof FormData<"u"&&jt instanceof FormData}class Pt{constructor(In,Rt,jn,Fi){let Ui;if(this.url=Rt,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=In.toUpperCase(),function ct(jt){switch(jt){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}(this.method)||Fi?(this.body=void 0!==jn?jn:null,Ui=Fi):Ui=jn,Ui&&(this.reportProgress=!!Ui.reportProgress,this.withCredentials=!!Ui.withCredentials,Ui.responseType&&(this.responseType=Ui.responseType),Ui.headers&&(this.headers=Ui.headers),Ui.context&&(this.context=Ui.context),Ui.params&&(this.params=Ui.params),this.transferCache=Ui.transferCache),this.headers??=new he,this.context??=new fn,this.params){const ar=this.params.toString();if(0===ar.length)this.urlWithParams=Rt;else{const er=Rt.indexOf("?");this.urlWithParams=Rt+(-1===er?"?":er<Rt.length-1?"&":"")+ar}}else this.params=new wt,this.urlWithParams=Rt}serializeBody(){return null===this.body?null:"string"==typeof this.body||en(this.body)||an(this.body)||un(this.body)||function vn(jt){return typeof URLSearchParams<"u"&&jt instanceof URLSearchParams}(this.body)?this.body:this.body instanceof wt?this.body.toString():"object"==typeof this.body||"boolean"==typeof this.body||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return null===this.body||un(this.body)?null:an(this.body)?this.body.type||null:en(this.body)?null:"string"==typeof this.body?"text/plain":this.body instanceof wt?"application/x-www-form-urlencoded;charset=UTF-8":"object"==typeof this.body||"number"==typeof this.body||"boolean"==typeof this.body?"application/json":null}clone(In={}){const Rt=In.method||this.method,jn=In.url||this.url,Fi=In.responseType||this.responseType,Ui=In.transferCache??this.transferCache,ar=void 0!==In.body?In.body:this.body,er=In.withCredentials??this.withCredentials,Or=In.reportProgress??this.reportProgress;let Tt=In.headers||this.headers,cn=In.params||this.params;const Tn=In.context??this.context;return void 0!==In.setHeaders&&(Tt=Object.keys(In.setHeaders).reduce((Ri,Un)=>Ri.set(Un,In.setHeaders[Un]),Tt)),In.setParams&&(cn=Object.keys(In.setParams).reduce((Ri,Un)=>Ri.set(Un,In.setParams[Un]),cn)),new Pt(Rt,jn,ar,{params:cn,headers:Tt,context:Tn,reportProgress:Or,responseType:Fi,withCredentials:er,transferCache:Ui})}}var Ae=function(jt){return jt[jt.Sent=0]="Sent",jt[jt.UploadProgress=1]="UploadProgress",jt[jt.ResponseHeader=2]="ResponseHeader",jt[jt.DownloadProgress=3]="DownloadProgress",jt[jt.Response=4]="Response",jt[jt.User=5]="User",jt}(Ae||{});class dt{constructor(In,Rt=200,jn="OK"){this.headers=In.headers||new he,this.status=void 0!==In.status?In.status:Rt,this.statusText=In.statusText||jn,this.url=In.url||null,this.ok=this.status>=200&&this.status<300}}class ut extends dt{constructor(In={}){super(In),this.type=Ae.ResponseHeader}clone(In={}){return new ut({headers:In.headers||this.headers,status:void 0!==In.status?In.status:this.status,statusText:In.statusText||this.statusText,url:In.url||this.url||void 0})}}class Mt extends dt{constructor(In={}){super(In),this.type=Ae.Response,this.body=void 0!==In.body?In.body:null}clone(In={}){return new Mt({body:void 0!==In.body?In.body:this.body,headers:In.headers||this.headers,status:void 0!==In.status?In.status:this.status,statusText:In.statusText||this.statusText,url:In.url||this.url||void 0})}}class Wt extends dt{constructor(In){super(In,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.message=this.status>=200&&this.status<300?`Http failure during parsing for ${In.url||"(unknown url)"}`:`Http failure response for ${In.url||"(unknown url)"}: ${In.status} ${In.statusText}`,this.error=In.error||null}}var pn=function(jt){return jt[jt.Continue=100]="Continue",jt[jt.SwitchingProtocols=101]="SwitchingProtocols",jt[jt.Processing=102]="Processing",jt[jt.EarlyHints=103]="EarlyHints",jt[jt.Ok=200]="Ok",jt[jt.Created=201]="Created",jt[jt.Accepted=202]="Accepted",jt[jt.NonAuthoritativeInformation=203]="NonAuthoritativeInformation",jt[jt.NoContent=204]="NoContent",jt[jt.ResetContent=205]="ResetContent",jt[jt.PartialContent=206]="PartialContent",jt[jt.MultiStatus=207]="MultiStatus",jt[jt.AlreadyReported=208]="AlreadyReported",jt[jt.ImUsed=226]="ImUsed",jt[jt.MultipleChoices=300]="MultipleChoices",jt[jt.MovedPermanently=301]="MovedPermanently",jt[jt.Found=302]="Found",jt[jt.SeeOther=303]="SeeOther",jt[jt.NotModified=304]="NotModified",jt[jt.UseProxy=305]="UseProxy",jt[jt.Unused=306]="Unused",jt[jt.TemporaryRedirect=307]="TemporaryRedirect",jt[jt.PermanentRedirect=308]="PermanentRedirect",jt[jt.BadRequest=400]="BadRequest",jt[jt.Unauthorized=401]="Unauthorized",jt[jt.PaymentRequired=402]="PaymentRequired",jt[jt.Forbidden=403]="Forbidden",jt[jt.NotFound=404]="NotFound",jt[jt.MethodNotAllowed=405]="MethodNotAllowed",jt[jt.NotAcceptable=406]="NotAcceptable",jt[jt.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",jt[jt.RequestTimeout=408]="RequestTimeout",jt[jt.Conflict=409]="Conflict",jt[jt.Gone=410]="Gone",jt[jt.LengthRequired=411]="LengthRequired",jt[jt.PreconditionFailed=412]="PreconditionFailed",jt[jt.PayloadTooLarge=413]="PayloadTooLarge",jt[jt.UriTooLong=414]="UriTooLong",jt[jt.UnsupportedMediaType=415]="UnsupportedMediaType",jt[jt.RangeNotSatisfiable=416]="RangeNotSatisfiable",jt[jt.ExpectationFailed=417]="ExpectationFailed",jt[jt.ImATeapot=418]="ImATeapot",jt[jt.MisdirectedRequest=421]="MisdirectedRequest",jt[jt.UnprocessableEntity=422]="UnprocessableEntity",jt[jt.Locked=423]="Locked",jt[jt.FailedDependency=424]="FailedDependency",jt[jt.TooEarly=425]="TooEarly",jt[jt.UpgradeRequired=426]="UpgradeRequired",jt[jt.PreconditionRequired=428]="PreconditionRequired",jt[jt.TooManyRequests=429]="TooManyRequests",jt[jt.RequestHeaderFieldsTooLarge=431]="RequestHeaderFieldsTooLarge",jt[jt.UnavailableForLegalReasons=451]="UnavailableForLegalReasons",jt[jt.InternalServerError=500]="InternalServerError",jt[jt.NotImplemented=501]="NotImplemented",jt[jt.BadGateway=502]="BadGateway",jt[jt.ServiceUnavailable=503]="ServiceUnavailable",jt[jt.GatewayTimeout=504]="GatewayTimeout",jt[jt.HttpVersionNotSupported=505]="HttpVersionNotSupported",jt[jt.VariantAlsoNegotiates=506]="VariantAlsoNegotiates",jt[jt.InsufficientStorage=507]="InsufficientStorage",jt[jt.LoopDetected=508]="LoopDetected",jt[jt.NotExtended=510]="NotExtended",jt[jt.NetworkAuthenticationRequired=511]="NetworkAuthenticationRequired",jt}(pn||{});function Wn(jt,In){return{body:In,headers:jt.headers,context:jt.context,observe:jt.observe,params:jt.params,reportProgress:jt.reportProgress,responseType:jt.responseType,withCredentials:jt.withCredentials,transferCache:jt.transferCache}}let ji=(()=>{class jt{constructor(Rt){this.handler=Rt}request(Rt,jn,Fi={}){let Ui;if(Rt instanceof Pt)Ui=Rt;else{let Or,Tt;Or=Fi.headers instanceof he?Fi.headers:new he(Fi.headers),Fi.params&&(Tt=Fi.params instanceof wt?Fi.params:new wt({fromObject:Fi.params})),Ui=new Pt(Rt,jn,void 0!==Fi.body?Fi.body:null,{headers:Or,context:Fi.context,params:Tt,reportProgress:Fi.reportProgress,responseType:Fi.responseType||"json",withCredentials:Fi.withCredentials,transferCache:Fi.transferCache})}const ar=(0,M.of)(Ui).pipe((0,X.concatMap)(Or=>this.handler.handle(Or)));if(Rt instanceof Pt||"events"===Fi.observe)return ar;const er=ar.pipe((0,X.filter)(Or=>Or instanceof Mt));switch(Fi.observe||"body"){case"body":switch(Ui.responseType){case"arraybuffer":return er.pipe((0,X.map)(Or=>{if(null!==Or.body&&!(Or.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return Or.body}));case"blob":return er.pipe((0,X.map)(Or=>{if(null!==Or.body&&!(Or.body instanceof Blob))throw new Error("Response is not a Blob.");return Or.body}));case"text":return er.pipe((0,X.map)(Or=>{if(null!==Or.body&&"string"!=typeof Or.body)throw new Error("Response is not a string.");return Or.body}));default:return er.pipe((0,X.map)(Or=>Or.body))}case"response":return er;default:throw new Error(`Unreachable: unhandled observe type ${Fi.observe}}`)}}delete(Rt,jn={}){return this.request("DELETE",Rt,jn)}get(Rt,jn={}){return this.request("GET",Rt,jn)}head(Rt,jn={}){return this.request("HEAD",Rt,jn)}jsonp(Rt,jn){return this.request("JSONP",Rt,{params:(new wt).append(jn,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(Rt,jn={}){return this.request("OPTIONS",Rt,jn)}patch(Rt,jn,Fi={}){return this.request("PATCH",Rt,Wn(Fi,jn))}post(Rt,jn,Fi={}){return this.request("POST",Rt,Wn(Fi,jn))}put(Rt,jn,Fi={}){return this.request("PUT",Rt,Wn(Fi,jn))}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(Q))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();const An=/^\)\]\}',?\n/;function qt(jt){if(jt.url)return jt.url;const In="X-Request-URL".toLocaleLowerCase();return jt.headers.get(In)}let Ht=(()=>{class jt{constructor(){this.fetchImpl=(0,e.inject)(on,{optional:!0})?.fetch??((...Rt)=>globalThis.fetch(...Rt)),this.ngZone=(0,e.inject)(e.NgZone)}handle(Rt){return new M.Observable(jn=>{const Fi=new AbortController;return this.doRequest(Rt,Fi.signal,jn).then(Cn,Ui=>jn.error(new Wt({error:Ui}))),()=>Fi.abort()})}doRequest(Rt,jn,Fi){var Ui=this;return(0,i.A)(function*(){const ar=Ui.createRequestInit(Rt);let er;try{const Yi=Ui.ngZone.runOutsideAngular(()=>Ui.fetchImpl(Rt.urlWithParams,{signal:jn,...ar}));(function tn(jt){jt.then(Cn,Cn)})(Yi),Fi.next({type:Ae.Sent}),er=yield Yi}catch(Yi){return void Fi.error(new Wt({error:Yi,status:Yi.status??0,statusText:Yi.statusText,url:Rt.urlWithParams,headers:Yi.headers}))}const Or=new he(er.headers),Tt=er.statusText,cn=qt(er)??Rt.urlWithParams;let Tn=er.status,Ri=null;if(Rt.reportProgress&&Fi.next(new ut({headers:Or,status:Tn,statusText:Tt,url:cn})),er.body){const Yi=er.headers.get("content-length"),Wi=[],fr=er.body.getReader();let Vo,vr,Li=0;const Mo=typeof Zone<"u"&&Zone.current;yield Ui.ngZone.runOutsideAngular((0,i.A)(function*(){for(;;){const{done:Jo,value:$s}=yield fr.read();if(Jo)break;if(Wi.push($s),Li+=$s.length,Rt.reportProgress){vr="text"===Rt.responseType?(vr??"")+(Vo??=new TextDecoder).decode($s,{stream:!0}):void 0;const Js=()=>Fi.next({type:Ae.DownloadProgress,total:Yi?+Yi:void 0,loaded:Li,partialText:vr});Mo?Mo.run(Js):Js()}}}));const ks=Ui.concatChunks(Wi,Li);try{const Jo=er.headers.get("Content-Type")??"";Ri=Ui.parseBody(Rt,ks,Jo)}catch(Jo){return void Fi.error(new Wt({error:Jo,headers:new he(er.headers),status:er.status,statusText:er.statusText,url:qt(er)??Rt.urlWithParams}))}}0===Tn&&(Tn=Ri?200:0),Tn>=200&&Tn<300?(Fi.next(new Mt({body:Ri,headers:Or,status:Tn,statusText:Tt,url:cn})),Fi.complete()):Fi.error(new Wt({error:Ri,headers:Or,status:Tn,statusText:Tt,url:cn}))})()}parseBody(Rt,jn,Fi){switch(Rt.responseType){case"json":const Ui=(new TextDecoder).decode(jn).replace(An,"");return""===Ui?null:JSON.parse(Ui);case"text":return(new TextDecoder).decode(jn);case"blob":return new Blob([jn],{type:Fi});case"arraybuffer":return jn.buffer}}createRequestInit(Rt){const jn={},Fi=Rt.withCredentials?"include":void 0;if(Rt.headers.forEach((Ui,ar)=>jn[Ui]=ar.join(",")),Rt.headers.has("Accept")||(jn.Accept="application/json, text/plain, */*"),!Rt.headers.has("Content-Type")){const Ui=Rt.detectContentTypeHeader();null!==Ui&&(jn["Content-Type"]=Ui)}return{body:Rt.serializeBody(),method:Rt.method,headers:jn,credentials:Fi}}concatChunks(Rt,jn){const Fi=new Uint8Array(jn);let Ui=0;for(const ar of Rt)Fi.set(ar,Ui),Ui+=ar.length;return Fi}static#e=this.\u0275fac=function(jn){return new(jn||jt)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();class on{}function Cn(){}function fi(jt,In){return In(jt)}function Zn(jt,In){return(Rt,jn)=>In.intercept(Rt,{handle:Fi=>jt(Fi,jn)})}const gn=new e.InjectionToken(""),Nn=new e.InjectionToken(""),Yn=new e.InjectionToken(""),cr=new e.InjectionToken("",{providedIn:"root",factory:()=>!0});function Ai(){let jt=null;return(In,Rt)=>{null===jt&&(jt=((0,e.inject)(gn,{optional:!0})??[]).reduceRight(Zn,fi));const jn=(0,e.inject)(e.\u0275PendingTasks);if((0,e.inject)(cr)){const Ui=jn.add();return jt(In,Rt).pipe((0,X.finalize)(()=>jn.remove(Ui)))}return jt(In,Rt)}}let as,Ur=(()=>{class jt extends Q{constructor(Rt,jn){super(),this.backend=Rt,this.injector=jn,this.chain=null,this.pendingTasks=(0,e.inject)(e.\u0275PendingTasks),this.contributeToStability=(0,e.inject)(cr)}handle(Rt){if(null===this.chain){const jn=Array.from(new Set([...this.injector.get(Nn),...this.injector.get(Yn,[])]));this.chain=jn.reduceRight((Fi,Ui)=>function Dn(jt,In,Rt){return(jn,Fi)=>(0,e.runInInjectionContext)(Rt,()=>In(jn,Ui=>jt(Ui,Fi)))}(Fi,Ui,this.injector),fi)}if(this.contributeToStability){const jn=this.pendingTasks.add();return this.chain(Rt,Fi=>this.backend.handle(Fi)).pipe((0,X.finalize)(()=>this.pendingTasks.remove(jn)))}return this.chain(Rt,jn=>this.backend.handle(jn))}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(Ee),e.\u0275\u0275inject(e.EnvironmentInjector))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})(),eo=0;class hn{}function Gt(){return"object"==typeof window?window:{}}let Gn=(()=>{class jt{constructor(Rt,jn){this.callbackMap=Rt,this.document=jn,this.resolvedPromise=Promise.resolve()}nextCallback(){return"ng_jsonp_callback_"+eo++}handle(Rt){if("JSONP"!==Rt.method)throw new Error("JSONP requests must use JSONP request method.");if("json"!==Rt.responseType)throw new Error("JSONP requests must use Json response type.");if(Rt.headers.keys().length>0)throw new Error("JSONP requests do not support headers.");return new M.Observable(jn=>{const Fi=this.nextCallback(),Ui=Rt.urlWithParams.replace(/=JSONP_CALLBACK(&|$)/,`=${Fi}$1`),ar=this.document.createElement("script");ar.src=Ui;let er=null,Or=!1;this.callbackMap[Fi]=Ri=>{delete this.callbackMap[Fi],er=Ri,Or=!0};const Tt=()=>{ar.removeEventListener("load",cn),ar.removeEventListener("error",Tn),ar.remove(),delete this.callbackMap[Fi]},cn=Ri=>{this.resolvedPromise.then(()=>{Tt(),Or?(jn.next(new Mt({body:er,status:200,statusText:"OK",url:Ui})),jn.complete()):jn.error(new Wt({url:Ui,status:0,statusText:"JSONP Error",error:new Error("JSONP injected script did not invoke callback.")}))})},Tn=Ri=>{Tt(),jn.error(new Wt({error:Ri,status:0,statusText:"JSONP Error",url:Ui}))};return ar.addEventListener("load",cn),ar.addEventListener("error",Tn),this.document.body.appendChild(ar),jn.next({type:Ae.Sent}),()=>{Or||this.removeListeners(ar),Tt()}})}removeListeners(Rt){as??=this.document.implementation.createHTMLDocument(),as.adoptNode(Rt)}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(hn),e.\u0275\u0275inject(ie.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();function ri(jt,In){return"JSONP"===jt.method?(0,e.inject)(Gn).handle(jt):In(jt)}let pi=(()=>{class jt{constructor(Rt){this.injector=Rt}intercept(Rt,jn){return(0,e.runInInjectionContext)(this.injector,()=>ri(Rt,Fi=>jn.handle(Fi)))}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(e.EnvironmentInjector))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();const At=/^\)\]\}',?\n/;let Mn=(()=>{class jt{constructor(Rt){this.xhrFactory=Rt}handle(Rt){if("JSONP"===Rt.method)throw new e.\u0275RuntimeError(-2800,!1);const jn=this.xhrFactory;return(jn.\u0275loadImpl?(0,M.from)(jn.\u0275loadImpl()):(0,M.of)(null)).pipe((0,X.switchMap)(()=>new M.Observable(Ui=>{const ar=jn.build();if(ar.open(Rt.method,Rt.urlWithParams),Rt.withCredentials&&(ar.withCredentials=!0),Rt.headers.forEach((Wi,fr)=>ar.setRequestHeader(Wi,fr.join(","))),Rt.headers.has("Accept")||ar.setRequestHeader("Accept","application/json, text/plain, */*"),!Rt.headers.has("Content-Type")){const Wi=Rt.detectContentTypeHeader();null!==Wi&&ar.setRequestHeader("Content-Type",Wi)}if(Rt.responseType){const Wi=Rt.responseType.toLowerCase();ar.responseType="json"!==Wi?Wi:"text"}const er=Rt.serializeBody();let Or=null;const Tt=()=>{if(null!==Or)return Or;const Wi=ar.statusText||"OK",fr=new he(ar.getAllResponseHeaders()),Li=function Bn(jt){return"responseURL"in jt&&jt.responseURL?jt.responseURL:/^X-Request-URL:/m.test(jt.getAllResponseHeaders())?jt.getResponseHeader("X-Request-URL"):null}(ar)||Rt.url;return Or=new ut({headers:fr,status:ar.status,statusText:Wi,url:Li}),Or},cn=()=>{let{headers:Wi,status:fr,statusText:Li,url:Vo}=Tt(),vr=null;204!==fr&&(vr=typeof ar.response>"u"?ar.responseText:ar.response),0===fr&&(fr=vr?200:0);let Mo=fr>=200&&fr<300;if("json"===Rt.responseType&&"string"==typeof vr){const ks=vr;vr=vr.replace(At,"");try{vr=""!==vr?JSON.parse(vr):null}catch(Jo){vr=ks,Mo&&(Mo=!1,vr={error:Jo,text:vr})}}Mo?(Ui.next(new Mt({body:vr,headers:Wi,status:fr,statusText:Li,url:Vo||void 0})),Ui.complete()):Ui.error(new Wt({error:vr,headers:Wi,status:fr,statusText:Li,url:Vo||void 0}))},Tn=Wi=>{const{url:fr}=Tt(),Li=new Wt({error:Wi,status:ar.status||0,statusText:ar.statusText||"Unknown Error",url:fr||void 0});Ui.error(Li)};let Ri=!1;const Un=Wi=>{Ri||(Ui.next(Tt()),Ri=!0);let fr={type:Ae.DownloadProgress,loaded:Wi.loaded};Wi.lengthComputable&&(fr.total=Wi.total),"text"===Rt.responseType&&ar.responseText&&(fr.partialText=ar.responseText),Ui.next(fr)},Yi=Wi=>{let fr={type:Ae.UploadProgress,loaded:Wi.loaded};Wi.lengthComputable&&(fr.total=Wi.total),Ui.next(fr)};return ar.addEventListener("load",cn),ar.addEventListener("error",Tn),ar.addEventListener("timeout",Tn),ar.addEventListener("abort",Tn),Rt.reportProgress&&(ar.addEventListener("progress",Un),null!==er&&ar.upload&&ar.upload.addEventListener("progress",Yi)),ar.send(er),Ui.next({type:Ae.Sent}),()=>{ar.removeEventListener("error",Tn),ar.removeEventListener("abort",Tn),ar.removeEventListener("load",cn),ar.removeEventListener("timeout",Tn),Rt.reportProgress&&(ar.removeEventListener("progress",Un),null!==er&&ar.upload&&ar.upload.removeEventListener("progress",Yi)),ar.readyState!==ar.DONE&&ar.abort()}})))}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(ie.XhrFactory))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();const ni=new e.InjectionToken(""),qn="XSRF-TOKEN",Ti=new e.InjectionToken("",{providedIn:"root",factory:()=>qn}),Bi="X-XSRF-TOKEN",Gi=new e.InjectionToken("",{providedIn:"root",factory:()=>Bi});class Ii{}let Ki=(()=>{class jt{constructor(Rt,jn,Fi){this.doc=Rt,this.platform=jn,this.cookieName=Fi,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if("server"===this.platform)return null;const Rt=this.doc.cookie||"";return Rt!==this.lastCookieString&&(this.parseCount++,this.lastToken=(0,ie.\u0275parseCookieValue)(Rt,this.cookieName),this.lastCookieString=Rt),this.lastToken}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(ie.DOCUMENT),e.\u0275\u0275inject(e.PLATFORM_ID),e.\u0275\u0275inject(Ti))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();function Jt(jt,In){const Rt=jt.url.toLowerCase();if(!(0,e.inject)(ni)||"GET"===jt.method||"HEAD"===jt.method||Rt.startsWith("http://")||Rt.startsWith("https://"))return In(jt);const jn=(0,e.inject)(Ii).getToken(),Fi=(0,e.inject)(Gi);return null!=jn&&!jt.headers.has(Fi)&&(jt=jt.clone({headers:jt.headers.set(Fi,jn)})),In(jt)}let hi=(()=>{class jt{constructor(Rt){this.injector=Rt}intercept(Rt,jn){return(0,e.runInInjectionContext)(this.injector,()=>Jt(Rt,Fi=>jn.handle(Fi)))}static#e=this.\u0275fac=function(jn){return new(jn||jt)(e.\u0275\u0275inject(e.EnvironmentInjector))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:jt,factory:jt.\u0275fac})}return jt})();var Ft=function(jt){return jt[jt.Interceptors=0]="Interceptors",jt[jt.LegacyInterceptors=1]="LegacyInterceptors",jt[jt.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",jt[jt.NoXsrfProtection=3]="NoXsrfProtection",jt[jt.JsonpSupport=4]="JsonpSupport",jt[jt.RequestsMadeViaParent=5]="RequestsMadeViaParent",jt[jt.Fetch=6]="Fetch",jt}(Ft||{});function it(jt,In){return{\u0275kind:jt,\u0275providers:In}}function sn(...jt){const In=[ji,Mn,Ur,{provide:Q,useExisting:Ur},{provide:Ee,useFactory:()=>(0,e.inject)(Ht,{optional:!0})??(0,e.inject)(Mn)},{provide:Nn,useValue:Jt,multi:!0},{provide:ni,useValue:!0},{provide:Ii,useClass:Ki}];for(const Rt of jt)In.push(...Rt.\u0275providers);return(0,e.makeEnvironmentProviders)(In)}function Ve(jt){return it(Ft.Interceptors,jt.map(In=>({provide:Nn,useValue:In,multi:!0})))}const He=new e.InjectionToken("");function mt(){return it(Ft.LegacyInterceptors,[{provide:He,useFactory:Ai},{provide:Nn,useExisting:He,multi:!0}])}function bt({cookieName:jt,headerName:In}){const Rt=[];return void 0!==jt&&Rt.push({provide:Ti,useValue:jt}),void 0!==In&&Rt.push({provide:Gi,useValue:In}),it(Ft.CustomXsrfConfiguration,Rt)}function nn(){return it(Ft.NoXsrfProtection,[{provide:ni,useValue:!1}])}function Jn(){return it(Ft.JsonpSupport,[Gn,{provide:hn,useFactory:Gt},{provide:Nn,useValue:ri,multi:!0}])}function Sn(){return it(Ft.RequestsMadeViaParent,[{provide:Ee,useFactory:()=>(0,e.inject)(Q,{skipSelf:!0,optional:!0})}])}function _r(){return it(Ft.Fetch,[Ht,{provide:Ee,useExisting:Ht}])}let qr=(()=>{class jt{static disable(){return{ngModule:jt,providers:[nn().\u0275providers]}}static withOptions(Rt={}){return{ngModule:jt,providers:bt(Rt).\u0275providers}}static#e=this.\u0275fac=function(jn){return new(jn||jt)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:jt});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[hi,{provide:gn,useExisting:hi,multi:!0},{provide:Ii,useClass:Ki},bt({cookieName:qn,headerName:Bi}).\u0275providers,{provide:ni,useValue:!0}]})}return jt})(),Bo=(()=>{class jt{static#e=this.\u0275fac=function(jn){return new(jn||jt)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:jt});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[sn(mt())]})}return jt})(),Eo=(()=>{class jt{static#e=this.\u0275fac=function(jn){return new(jn||jt)};static#t=this.\u0275mod=e.\u0275\u0275defineNgModule({type:jt});static#n=this.\u0275inj=e.\u0275\u0275defineInjector({providers:[Jn().\u0275providers]})}return jt})();const Ro=new e.InjectionToken(""),Ls="b",ol="h",Va="s",Ao="st",za="u",vl="rt",Na=new e.InjectionToken(""),_l=["GET","HEAD"];function gs(jt,In){const{isCacheActive:Rt,...jn}=(0,e.inject)(Na),{transferCache:Fi,method:Ui}=jt;if(!Rt||!1===Fi||"POST"===Ui&&!jn.includePostRequests&&!Fi||"POST"!==Ui&&!_l.includes(Ui)||!jn.includeRequestsWithAuthHeaders&&function Zs(jt){return jt.headers.has("authorization")||jt.headers.has("proxy-authorization")}(jt)||!1===jn.filter?.(jt))return In(jt);const ar=(0,e.inject)(e.TransferState),er=(0,e.inject)(Ro,{optional:!0}),Or=(0,ie.isPlatformServer)((0,e.inject)(e.PLATFORM_ID));if(er&&!Or)throw new e.\u0275RuntimeError(2803,!1);const Tt=Or&&er?function Lo(jt,In){const Rt=new URL(jt,"resolve://").origin,jn=In[Rt];return jn?jt.replace(Rt,jn):jt}(jt.url,er):jt.url,cn=function xl(jt,In){const{params:Rt,method:jn,responseType:Fi}=jt,Ui=no(Rt);let ar=jt.serializeBody();ar instanceof URLSearchParams?ar=no(ar):"string"!=typeof ar&&(ar="");const Or=function Qr(jt){let In=0;for(const Rt of jt)In=Math.imul(31,In)+Rt.charCodeAt(0)|0;return In+=2147483648,In.toString()}([jn,Fi,In,ar,Ui].join("|"));return(0,e.makeStateKey)(Or)}(jt,Tt),Tn=ar.get(cn,null);let Ri=jn.includeHeaders;if("object"==typeof Fi&&Fi.includeHeaders&&(Ri=Fi.includeHeaders),Tn){const{[Ls]:Un,[vl]:Yi,[ol]:Wi,[Va]:fr,[Ao]:Li,[za]:Vo}=Tn;let vr=Un;switch(Yi){case"arraybuffer":vr=(new TextEncoder).encode(Un).buffer;break;case"blob":vr=new Blob([Un])}let Mo=new he(Wi);return(0,M.of)(new Mt({body:vr,headers:Mo,status:fr,statusText:Li,url:Vo}))}return In(jt).pipe((0,X.tap)(Un=>{Un instanceof Mt&&Or&&ar.set(cn,{[Ls]:Un.body,[ol]:oa(Un.headers,Ri),[Va]:Un.status,[Ao]:Un.statusText,[za]:Tt,[vl]:jt.responseType})}))}function oa(jt,In){if(!In)return{};const Rt={};for(const jn of In){const Fi=jt.getAll(jn);null!==Fi&&(Rt[jn]=Fi)}return Rt}function no(jt){return[...jt.keys()].sort().map(In=>`${In}=${jt.getAll(In)}`).join("&")}function dl(jt){return[{provide:Na,useFactory:()=>((0,e.\u0275performanceMarkFeature)("NgHttpTransferCache"),{isCacheActive:!0,...jt})},{provide:Yn,useValue:gs,multi:!0,deps:[e.TransferState,Na]},{provide:e.APP_BOOTSTRAP_LISTENER,multi:!0,useFactory:()=>{const In=(0,e.inject)(e.ApplicationRef),Rt=(0,e.inject)(Na);return()=>{(0,e.\u0275whenStable)(In).then(()=>{Rt.isCacheActive=!1})}}}]}},3953:(Ot,Me,S)=>{function i(s,l){return Object.is(s,l)}S.r(Me),S.d(Me,{ANIMATION_MODULE_TYPE:()=>ay,APP_BOOTSTRAP_LISTENER:()=>L2,APP_ID:()=>X0,APP_INITIALIZER:()=>vL,AfterRenderPhase:()=>Ns,ApplicationInitStatus:()=>VF,ApplicationModule:()=>MP,ApplicationRef:()=>Jb,Attribute:()=>ey,COMPILER_OPTIONS:()=>$F,CSP_NONCE:()=>BE,CUSTOM_ELEMENTS_SCHEMA:()=>_s,ChangeDetectionStrategy:()=>Wo,ChangeDetectorRef:()=>tN,Compiler:()=>sP,CompilerFactory:()=>DL,Component:()=>MF,ComponentFactory:()=>Ys,ComponentFactoryResolver:()=>ag,ComponentRef:()=>OS,ContentChild:()=>t0,ContentChildren:()=>Fw,DEFAULT_CURRENCY_CODE:()=>EL,DebugElement:()=>ZI,DebugEventListener:()=>_P,DebugNode:()=>nN,DefaultIterableDiffer:()=>rN,DestroyRef:()=>ny,Directive:()=>TF,ENVIRONMENT_INITIALIZER:()=>Hl,ElementRef:()=>Hm,EmbeddedViewRef:()=>vP,EnvironmentInjector:()=>Hu,ErrorHandler:()=>Lh,EventEmitter:()=>Rp,ExperimentalPendingTasks:()=>Wm,HOST_TAG_NAME:()=>Rg,Host:()=>ne,HostAttributeToken:()=>CD,HostBinding:()=>AF,HostListener:()=>nL,INJECTOR:()=>dc,Inject:()=>$o,InjectFlags:()=>As,Injectable:()=>hl,InjectionToken:()=>aa,Injector:()=>Ou,Input:()=>tL,IterableDiffers:()=>sN,KeyValueDiffers:()=>aN,LOCALE_ID:()=>P2,MissingTranslationStrategy:()=>ML,ModuleWithComponentFactories:()=>UF,NO_ERRORS_SCHEMA:()=>rb,NgModule:()=>iL,NgModuleFactory:()=>Wb,NgModuleRef:()=>O_,NgProbeToken:()=>iP,NgZone:()=>Uc,Optional:()=>Mc,Output:()=>IF,OutputEmitterRef:()=>b1,PACKAGE_ROOT_URL:()=>IM,PLATFORM_ID:()=>Yv,PLATFORM_INITIALIZER:()=>Qv,Pipe:()=>eL,PlatformRef:()=>ZF,Query:()=>T_,QueryList:()=>lm,Renderer2:()=>Rb,RendererFactory2:()=>$y,RendererStyleFlags2:()=>$1,Sanitizer:()=>b_,SecurityContext:()=>pm,Self:()=>yc,SimpleChange:()=>ei,SkipSelf:()=>Ue,TRANSLATIONS:()=>TL,TRANSLATIONS_FORMAT:()=>lP,TemplateRef:()=>Fy,Testability:()=>mL,TestabilityRegistry:()=>O2,TransferState:()=>zm,Type:()=>H_,VERSION:()=>Hk,Version:()=>OF,ViewChild:()=>PS,ViewChildren:()=>M_,ViewContainerRef:()=>Ju,ViewEncapsulation:()=>sr,ViewRef:()=>LL,afterNextRender:()=>wd,afterRender:()=>ru,asNativeElements:()=>yP,assertInInjectionContext:()=>Nm,assertNotInReactiveContext:()=>ys,assertPlatform:()=>OL,booleanAttribute:()=>dk,computed:()=>xN,contentChild:()=>EC,contentChildren:()=>Aw,createComponent:()=>EN,createEnvironmentInjector:()=>Pw,createNgModule:()=>kw,createNgModuleRef:()=>WS,createPlatform:()=>B2,createPlatformFactory:()=>JF,defineInjectable:()=>ac,destroyPlatform:()=>uP,effect:()=>nO,enableProdMode:()=>hP,forwardRef:()=>ho,getDebugNode:()=>pM,getModuleFactory:()=>mP,getNgModuleById:()=>NL,getPlatform:()=>V2,importProvidersFrom:()=>Bs,inject:()=>or,input:()=>$0,isDevMode:()=>pP,isSignal:()=>fv,isStandalone:()=>Yd,makeEnvironmentProviders:()=>bc,makeStateKey:()=>VE,mergeApplicationConfig:()=>KP,model:()=>e0,numberAttribute:()=>yN,output:()=>SD,platformCore:()=>KL,provideExperimentalCheckNoChangesForDebug:()=>fP,provideExperimentalZonelessChangeDetection:()=>xL,provideZoneChangeDetection:()=>KF,reflectComponentType:()=>uE,resolveForwardRef:()=>Vr,runInInjectionContext:()=>Mv,setTestabilityGetter:()=>F2,signal:()=>pv,untracked:()=>hk,viewChild:()=>Dd,viewChildren:()=>LS,\u0275ALLOW_MULTIPLE_PLATFORMS:()=>XI,\u0275AfterRenderManager:()=>Ml,\u0275CONTAINER_HEADER_OFFSET:()=>Gr,\u0275ChangeDetectionScheduler:()=>Wh,\u0275ChangeDetectionSchedulerImpl:()=>XC,\u0275ComponentFactory:()=>Ys,\u0275Console:()=>rL,\u0275DEFAULT_LOCALE_ID:()=>PT,\u0275DEFER_BLOCK_CONFIG:()=>jw,\u0275DEFER_BLOCK_DEPENDENCY_INTERCEPTOR:()=>Vw,\u0275DeferBlockBehavior:()=>xo,\u0275DeferBlockState:()=>yo,\u0275EffectScheduler:()=>SN,\u0275IMAGE_CONFIG:()=>Z0,\u0275IMAGE_CONFIG_DEFAULTS:()=>RD,\u0275INJECTOR_SCOPE:()=>Mu,\u0275INPUT_SIGNAL_BRAND_WRITE_TYPE:()=>fu,\u0275INTERNAL_APPLICATION_ERROR_HANDLER:()=>EE,\u0275IS_HYDRATION_DOM_REUSE_ENABLED:()=>tu,\u0275JSACTION_EVENT_CONTRACT:()=>cA,\u0275LContext:()=>ID,\u0275LifecycleHooksFeature:()=>Tw,\u0275LocaleDataIndex:()=>YS,\u0275NG_COMP_DEF:()=>Eu,\u0275NG_DIR_DEF:()=>Pu,\u0275NG_ELEMENT_ID:()=>Bu,\u0275NG_INJ_DEF:()=>_c,\u0275NG_MOD_DEF:()=>qs,\u0275NG_PIPE_DEF:()=>Lc,\u0275NG_PROV_DEF:()=>bl,\u0275NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR:()=>nm,\u0275NO_CHANGE:()=>js,\u0275NgModuleFactory:()=>Hb,\u0275NoopNgZone:()=>$v,\u0275PROVIDED_NG_ZONE:()=>GF,\u0275PendingTasks:()=>sm,\u0275ReflectionCapabilities:()=>km,\u0275Render3ComponentFactory:()=>hh,\u0275Render3ComponentRef:()=>Hf,\u0275Render3NgModuleRef:()=>c0,\u0275RuntimeError:()=>po,\u0275SIGNAL:()=>ie,\u0275SSR_CONTENT_INTEGRITY_MARKER:()=>um,\u0275TESTABILITY:()=>PF,\u0275TESTABILITY_GETTER:()=>BF,\u0275USE_RUNTIME_DEPS_TRACKER_FOR_JIT:()=>ym,\u0275ViewRef:()=>jp,\u0275XSS_SECURITY_URL:()=>Fc,\u0275ZONELESS_ENABLED:()=>Wp,\u0275_sanitizeHtml:()=>Fd,\u0275_sanitizeUrl:()=>i_,\u0275allowSanitizationBypassAndThrow:()=>mp,\u0275annotateForHydration:()=>X2,\u0275bypassSanitizationTrustHtml:()=>zx,\u0275bypassSanitizationTrustResourceUrl:()=>n_,\u0275bypassSanitizationTrustScript:()=>AM,\u0275bypassSanitizationTrustStyle:()=>Gm,\u0275bypassSanitizationTrustUrl:()=>Bl,\u0275clearResolutionOfComponentResourcesQueue:()=>AC,\u0275compileComponent:()=>vF,\u0275compileDirective:()=>zI,\u0275compileNgModule:()=>zR,\u0275compileNgModuleDefs:()=>GR,\u0275compileNgModuleFactory:()=>WF,\u0275compilePipe:()=>EF,\u0275convertToBitFlags:()=>ia,\u0275createInjector:()=>lh,\u0275defaultIterableDiffers:()=>JI,\u0275defaultKeyValueDiffers:()=>TP,\u0275depsTracker:()=>Hh,\u0275detectChangesInViewIfRequired:()=>CL,\u0275devModeEqual:()=>K,\u0275findLocaleData:()=>Ta,\u0275flushModuleScopingQueueAsMuchAsPossible:()=>WR,\u0275formatRuntimeError:()=>Ll,\u0275generateStandaloneInDeclarationsError:()=>mF,\u0275getAsyncClassMetadataFn:()=>Rk,\u0275getDebugNode:()=>pM,\u0275getDeferBlocks:()=>gN,\u0275getDirectives:()=>RE,\u0275getHostElement:()=>E1,\u0275getInjectableDef:()=>ou,\u0275getLContext:()=>Cd,\u0275getLocaleCurrencyCode:()=>QN,\u0275getLocalePluralCase:()=>WA,\u0275getOutputDestroyRef:()=>TE,\u0275getSanitizationBypassType:()=>uh,\u0275getUnknownElementStrictMode:()=>HD,\u0275getUnknownPropertyStrictMode:()=>LM,\u0275global:()=>vi,\u0275injectChangeDetectorRef:()=>RL,\u0275internalCreateApplication:()=>G2,\u0275internalProvideZoneChangeDetection:()=>dM,\u0275isBoundToModule:()=>yL,\u0275isComponentDefPendingResolution:()=>MC,\u0275isEnvironmentProviders:()=>gd,\u0275isInjectable:()=>qd,\u0275isNgModule:()=>Wf,\u0275isPromise:()=>R2,\u0275isSubscribable:()=>gL,\u0275noSideEffects:()=>Ke,\u0275patchComponentDefWithScope:()=>D2,\u0275performanceMarkFeature:()=>dd,\u0275readHydrationInfo:()=>_a,\u0275registerLocaleData:()=>qN,\u0275renderDeferBlockState:()=>Sf,\u0275resetCompiledComponents:()=>jk,\u0275resetJitOptions:()=>Pk,\u0275resolveComponentResources:()=>Vb,\u0275restoreComponentResolutionQueue:()=>VS,\u0275setAllowDuplicateNgModuleIdsForTest:()=>Dm,\u0275setAlternateWeakRefImpl:()=>kP,\u0275setClassDebugInfo:()=>pF,\u0275setClassMetadata:()=>h2,\u0275setClassMetadataAsync:()=>kI,\u0275setCurrentInjector:()=>tt,\u0275setDocument:()=>EA,\u0275setInjectorProfilerContext:()=>hd,\u0275setLocaleId:()=>_I,\u0275setUnknownElementStrictMode:()=>Df,\u0275setUnknownPropertyStrictMode:()=>o_,\u0275store:()=>rE,\u0275stringify:()=>ai,\u0275transitiveScopesFor:()=>sE,\u0275triggerResourceLoading:()=>Gp,\u0275truncateMiddle:()=>Fr,\u0275unregisterLocaleData:()=>YN,\u0275unwrapSafeValue:()=>Pp,\u0275unwrapWritableSignal:()=>kb,\u0275whenStable:()=>jF,\u0275withDomHydration:()=>hA,\u0275withEventReplay:()=>Q2,\u0275withI18nSupport:()=>uk,\u0275\u0275CopyDefinitionFeature:()=>a0,\u0275\u0275FactoryTarget:()=>od,\u0275\u0275HostDirectivesFeature:()=>pa,\u0275\u0275InheritDefinitionFeature:()=>o0,\u0275\u0275InputTransformsFeature:()=>Lw,\u0275\u0275NgOnChangesFeature:()=>Vi,\u0275\u0275ProvidersFeature:()=>oM,\u0275\u0275StandaloneFeature:()=>lF,\u0275\u0275advance:()=>fh,\u0275\u0275attribute:()=>IT,\u0275\u0275attributeInterpolate1:()=>Uw,\u0275\u0275attributeInterpolate2:()=>vh,\u0275\u0275attributeInterpolate3:()=>KS,\u0275\u0275attributeInterpolate4:()=>$w,\u0275\u0275attributeInterpolate5:()=>bp,\u0275\u0275attributeInterpolate6:()=>Qb,\u0275\u0275attributeInterpolate7:()=>qS,\u0275\u0275attributeInterpolate8:()=>KC,\u0275\u0275attributeInterpolateV:()=>k_,\u0275\u0275classMap:()=>QS,\u0275\u0275classMapInterpolate1:()=>qp,\u0275\u0275classMapInterpolate2:()=>_h,\u0275\u0275classMapInterpolate3:()=>sI,\u0275\u0275classMapInterpolate4:()=>vO,\u0275\u0275classMapInterpolate5:()=>BA,\u0275\u0275classMapInterpolate6:()=>_O,\u0275\u0275classMapInterpolate7:()=>VA,\u0275\u0275classMapInterpolate8:()=>Gc,\u0275\u0275classMapInterpolateV:()=>yO,\u0275\u0275classProp:()=>Dp,\u0275\u0275componentInstance:()=>bO,\u0275\u0275conditional:()=>lI,\u0275\u0275contentQuery:()=>TR,\u0275\u0275contentQuerySignal:()=>HT,\u0275\u0275declareLet:()=>sF,\u0275\u0275defer:()=>vv,\u0275\u0275deferEnableTimerScheduling:()=>zp,\u0275\u0275deferOnHover:()=>Cs,\u0275\u0275deferOnIdle:()=>XM,\u0275\u0275deferOnImmediate:()=>ZM,\u0275\u0275deferOnInteraction:()=>JM,\u0275\u0275deferOnTimer:()=>d0,\u0275\u0275deferOnViewport:()=>ua,\u0275\u0275deferPrefetchOnHover:()=>Ul,\u0275\u0275deferPrefetchOnIdle:()=>MT,\u0275\u0275deferPrefetchOnImmediate:()=>GS,\u0275\u0275deferPrefetchOnInteraction:()=>xd,\u0275\u0275deferPrefetchOnTimer:()=>Ku,\u0275\u0275deferPrefetchOnViewport:()=>yp,\u0275\u0275deferPrefetchWhen:()=>Kh,\u0275\u0275deferWhen:()=>u0,\u0275\u0275defineComponent:()=>xr,\u0275\u0275defineDirective:()=>Sv,\u0275\u0275defineInjectable:()=>Ks,\u0275\u0275defineInjector:()=>lc,\u0275\u0275defineNgModule:()=>$_,\u0275\u0275definePipe:()=>Am,\u0275\u0275directiveInject:()=>Jg,\u0275\u0275disableBindings:()=>_E,\u0275\u0275element:()=>UA,\u0275\u0275elementContainer:()=>hI,\u0275\u0275elementContainerEnd:()=>pI,\u0275\u0275elementContainerStart:()=>m0,\u0275\u0275elementEnd:()=>fI,\u0275\u0275elementStart:()=>dI,\u0275\u0275enableBindings:()=>ux,\u0275\u0275getComponentDepsFactory:()=>uM,\u0275\u0275getCurrentView:()=>$A,\u0275\u0275getInheritedFactory:()=>xx,\u0275\u0275hostProperty:()=>g0,\u0275\u0275i18n:()=>QO,\u0275\u0275i18nApply:()=>YO,\u0275\u0275i18nAttributes:()=>e2,\u0275\u0275i18nEnd:()=>CI,\u0275\u0275i18nExp:()=>t2,\u0275\u0275i18nPostprocess:()=>wR,\u0275\u0275i18nStart:()=>JA,\u0275\u0275inject:()=>gi,\u0275\u0275injectAttribute:()=>up,\u0275\u0275invalidFactory:()=>aS,\u0275\u0275invalidFactoryDep:()=>rr,\u0275\u0275listener:()=>VT,\u0275\u0275loadQuery:()=>MR,\u0275\u0275namespaceHTML:()=>pD,\u0275\u0275namespaceMathML:()=>Zf,\u0275\u0275namespaceSVG:()=>A0,\u0275\u0275nextContext:()=>jT,\u0275\u0275ngDeclareClassMetadata:()=>fk,\u0275\u0275ngDeclareClassMetadataAsync:()=>bN,\u0275\u0275ngDeclareComponent:()=>gA,\u0275\u0275ngDeclareDirective:()=>mA,\u0275\u0275ngDeclareFactory:()=>CN,\u0275\u0275ngDeclareInjectable:()=>vA,\u0275\u0275ngDeclareInjector:()=>wN,\u0275\u0275ngDeclareNgModule:()=>pk,\u0275\u0275ngDeclarePipe:()=>_A,\u0275\u0275pipe:()=>jI,\u0275\u0275pipeBind1:()=>jR,\u0275\u0275pipeBind2:()=>$I,\u0275\u0275pipeBind3:()=>_2,\u0275\u0275pipeBind4:()=>y2,\u0275\u0275pipeBindV:()=>Zw,\u0275\u0275projection:()=>ER,\u0275\u0275projectionDef:()=>SR,\u0275\u0275property:()=>iI,\u0275\u0275propertyInterpolate:()=>rc,\u0275\u0275propertyInterpolate1:()=>UT,\u0275\u0275propertyInterpolate2:()=>eF,\u0275\u0275propertyInterpolate3:()=>r2,\u0275\u0275propertyInterpolate4:()=>xI,\u0275\u0275propertyInterpolate5:()=>o2,\u0275\u0275propertyInterpolate6:()=>iE,\u0275\u0275propertyInterpolate7:()=>s2,\u0275\u0275propertyInterpolate8:()=>$T,\u0275\u0275propertyInterpolateV:()=>WT,\u0275\u0275pureFunction0:()=>PR,\u0275\u0275pureFunction1:()=>PI,\u0275\u0275pureFunction2:()=>m2,\u0275\u0275pureFunction3:()=>cF,\u0275\u0275pureFunction4:()=>BI,\u0275\u0275pureFunction5:()=>BR,\u0275\u0275pureFunction6:()=>g2,\u0275\u0275pureFunction7:()=>aM,\u0275\u0275pureFunction8:()=>uF,\u0275\u0275pureFunctionV:()=>dF,\u0275\u0275queryAdvance:()=>IR,\u0275\u0275queryRefresh:()=>EI,\u0275\u0275readContextLet:()=>RI,\u0275\u0275reference:()=>TI,\u0275\u0275registerNgModuleType:()=>r0,\u0275\u0275repeater:()=>TO,\u0275\u0275repeaterCreate:()=>cI,\u0275\u0275repeaterTrackByIdentity:()=>xO,\u0275\u0275repeaterTrackByIndex:()=>wO,\u0275\u0275resetView:()=>oD,\u0275\u0275resolveBody:()=>Bh,\u0275\u0275resolveDocument:()=>Ea,\u0275\u0275resolveWindow:()=>my,\u0275\u0275restoreView:()=>Op,\u0275\u0275sanitizeHtml:()=>$c,\u0275\u0275sanitizeResourceUrl:()=>Kg,\u0275\u0275sanitizeScript:()=>B1,\u0275\u0275sanitizeStyle:()=>Yx,\u0275\u0275sanitizeUrl:()=>WD,\u0275\u0275sanitizeUrlOrResourceUrl:()=>j1,\u0275\u0275setComponentScope:()=>f2,\u0275\u0275setNgModuleScope:()=>kR,\u0275\u0275storeLet:()=>NI,\u0275\u0275styleMap:()=>zc,\u0275\u0275styleMapInterpolate1:()=>AR,\u0275\u0275styleMapInterpolate2:()=>MI,\u0275\u0275styleMapInterpolate3:()=>II,\u0275\u0275styleMapInterpolate4:()=>a2,\u0275\u0275styleMapInterpolate5:()=>QC,\u0275\u0275styleMapInterpolate6:()=>GT,\u0275\u0275styleMapInterpolate7:()=>AI,\u0275\u0275styleMapInterpolate8:()=>qw,\u0275\u0275styleMapInterpolateV:()=>KT,\u0275\u0275styleProp:()=>Xb,\u0275\u0275stylePropInterpolate1:()=>qT,\u0275\u0275stylePropInterpolate2:()=>QT,\u0275\u0275stylePropInterpolate3:()=>tF,\u0275\u0275stylePropInterpolate4:()=>nF,\u0275\u0275stylePropInterpolate5:()=>YT,\u0275\u0275stylePropInterpolate6:()=>iF,\u0275\u0275stylePropInterpolate7:()=>rF,\u0275\u0275stylePropInterpolate8:()=>XT,\u0275\u0275stylePropInterpolateV:()=>Qw,\u0275\u0275syntheticHostListener:()=>XO,\u0275\u0275syntheticHostProperty:()=>kT,\u0275\u0275template:()=>si,\u0275\u0275templateRefExtractor:()=>UR,\u0275\u0275text:()=>l2,\u0275\u0275textInterpolate:()=>ZT,\u0275\u0275textInterpolate1:()=>Yw,\u0275\u0275textInterpolate2:()=>c2,\u0275\u0275textInterpolate3:()=>JT,\u0275\u0275textInterpolate4:()=>yh,\u0275\u0275textInterpolate5:()=>FI,\u0275\u0275textInterpolate6:()=>oE,\u0275\u0275textInterpolate7:()=>u2,\u0275\u0275textInterpolate8:()=>eM,\u0275\u0275textInterpolateV:()=>oF,\u0275\u0275trustConstantHtml:()=>Xx,\u0275\u0275trustConstantResourceUrl:()=>V1,\u0275\u0275twoWayBindingSet:()=>FR,\u0275\u0275twoWayListener:()=>nM,\u0275\u0275twoWayProperty:()=>tM,\u0275\u0275validateIframeAttribute:()=>US,\u0275\u0275viewQuery:()=>SI,\u0275\u0275viewQuerySignal:()=>zT});let e=null,M=!1,X=1;const ie=Symbol("SIGNAL");function Q(s){const l=e;return e=s,l}function Ee(){return e}const oe={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function Z(s){if(M)throw new Error("");if(null===e)return;e.consumerOnSignalRead(s);const l=e.nextProducerIndex++;Pt(e),l<e.producerNode.length&&e.producerNode[l]!==s&&vn(e)&&un(e.producerNode[l],e.producerIndexOfThis[l]),e.producerNode[l]!==s&&(e.producerNode[l]=s,e.producerIndexOfThis[l]=vn(e)?an(s,e,l):0),e.producerLastReadVersion[l]=s.version}function le(s){if((!vn(s)||s.dirty)&&(s.dirty||s.lastCleanEpoch!==X)){if(!s.producerMustRecompute(s)&&!ct(s))return s.dirty=!1,void(s.lastCleanEpoch=X);s.producerRecomputeValue(s),s.dirty=!1,s.lastCleanEpoch=X}}function je(s){if(void 0===s.liveConsumerNode)return;const l=M;M=!0;try{for(const d of s.liveConsumerNode)d.dirty||wt(d)}finally{M=l}}function Et(){return!1!==e?.consumerAllowSignalWrites}function wt(s){s.dirty=!0,je(s),s.consumerMarkedDirty?.(s)}function ve(s){return s&&(s.nextProducerIndex=0),Q(s)}function fn(s,l){if(Q(l),s&&void 0!==s.producerNode&&void 0!==s.producerIndexOfThis&&void 0!==s.producerLastReadVersion){if(vn(s))for(let d=s.nextProducerIndex;d<s.producerNode.length;d++)un(s.producerNode[d],s.producerIndexOfThis[d]);for(;s.producerNode.length>s.nextProducerIndex;)s.producerNode.pop(),s.producerLastReadVersion.pop(),s.producerIndexOfThis.pop()}}function ct(s){Pt(s);for(let l=0;l<s.producerNode.length;l++){const d=s.producerNode[l],h=s.producerLastReadVersion[l];if(h!==d.version||(le(d),h!==d.version))return!0}return!1}function en(s){if(Pt(s),vn(s))for(let l=0;l<s.producerNode.length;l++)un(s.producerNode[l],s.producerIndexOfThis[l]);s.producerNode.length=s.producerLastReadVersion.length=s.producerIndexOfThis.length=0,s.liveConsumerNode&&(s.liveConsumerNode.length=s.liveConsumerIndexOfThis.length=0)}function an(s,l,d){if(Ae(s),0===s.liveConsumerNode.length&&dt(s))for(let h=0;h<s.producerNode.length;h++)s.producerIndexOfThis[h]=an(s.producerNode[h],s,h);return s.liveConsumerIndexOfThis.push(d),s.liveConsumerNode.push(l)-1}function un(s,l){if(Ae(s),1===s.liveConsumerNode.length&&dt(s))for(let h=0;h<s.producerNode.length;h++)un(s.producerNode[h],s.producerIndexOfThis[h]);const d=s.liveConsumerNode.length-1;if(s.liveConsumerNode[l]=s.liveConsumerNode[d],s.liveConsumerIndexOfThis[l]=s.liveConsumerIndexOfThis[d],s.liveConsumerNode.length--,s.liveConsumerIndexOfThis.length--,l<s.liveConsumerNode.length){const h=s.liveConsumerIndexOfThis[l],w=s.liveConsumerNode[l];Pt(w),w.producerIndexOfThis[h]=l}}function vn(s){return s.consumerIsAlwaysLive||(s?.liveConsumerNode?.length??0)>0}function Pt(s){s.producerNode??=[],s.producerIndexOfThis??=[],s.producerLastReadVersion??=[]}function Ae(s){s.liveConsumerNode??=[],s.liveConsumerIndexOfThis??=[]}function dt(s){return void 0!==s.producerNode}function ut(s){const l=Object.create(Vn);l.computation=s;const d=()=>{if(le(l),Z(l),l.value===It)throw l.error;return l.value};return d[ie]=l,d}const Mt=Symbol("UNSET"),Wt=Symbol("COMPUTING"),It=Symbol("ERRORED"),Vn={...oe,value:Mt,dirty:!0,error:null,equal:i,producerMustRecompute:s=>s.value===Mt||s.value===Wt,producerRecomputeValue(s){if(s.value===Wt)throw new Error("Detected cycle in computations.");const l=s.value;s.value=Wt;const d=ve(s);let h;try{h=s.computation()}catch(w){h=It,s.error=w}finally{fn(s,d)}l!==Mt&&l!==It&&h!==It&&s.equal(l,h)?s.value=l:(s.value=h,s.version++)}};let Wn=function pn(){throw new Error};function ji(){Wn()}let St=null;function Cn(s,l){Et()||ji(),s.equal(s.value,l)||(s.value=l,function Dn(s){s.version++,function ce(){X++}(),je(s),St?.()}(s))}const Zn={...oe,equal:i,value:void 0};const Nn=()=>{},Yn={...oe,consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!1,consumerMarkedDirty:s=>{null!==s.schedule&&s.schedule(s.ref)},hasRun:!1,cleanupFn:Nn};var Ai=S(1647),Qi=S(9335);const Xr={JSACTION:"jsaction"},Ur_JSACTION="__jsaction",Ur_OWNER="__owner",eo={};function mi(s,l){s[Ur_JSACTION]=l}const Gn=["mouseenter","mouseleave","pointerenter","pointerleave"],pi=["focus","blur","error","load","toggle"],At=s=>pi.indexOf(s)>=0,Bn=["click","dblclick","focusin","focusout","keydown","keyup","keypress","mouseover","mouseout","submit","touchstart","touchend","touchmove","touchcancel","auxclick","change","compositionstart","compositionupdate","compositionend","beforeinput","input","select","copy","cut","paste","mousedown","mouseup","wheel","contextmenu","dragover","dragenter","dragleave","drop","dragstart","dragend","pointerdown","pointermove","pointerup","pointercancel","pointerover","pointerout","gotpointercapture","lostpointercapture","ended","loadedmetadata","pagehide","pageshow","visibilitychange","beforematch"].concat(pi),Mn=s=>Bn.indexOf(s)>=0;function Ki(s,l){s.removeEventListener?s.removeEventListener(l.eventType,l.handler,l.capture):s.detachEvent&&s.detachEvent(`on${l.eventType}`,l.handler)}let it=typeof navigator<"u"&&/Macintosh/.test(navigator.userAgent);typeof navigator<"u"&&!/Opera/.test(navigator.userAgent)&&navigator,typeof navigator<"u"&&(/MSIE/.test(navigator.userAgent)||navigator),typeof navigator<"u"&&!/Opera|WebKit/.test(navigator.userAgent)&&navigator;const Lo=typeof navigator<"u"&&/iPhone|iPad|iPod/.test(navigator.userAgent);class ko{constructor(l){this.element=l,this.handlerInfos=[]}addEventListener(l,d){Lo&&(this.element.style.cursor="pointer"),this.handlerInfos.push(function Ii(s,l,d){let h=!1;return At(l)&&(h=!0),s.addEventListener(l,d,h),{eventType:l,handler:d,capture:h}}(this.element,l,d(this.element)))}cleanUp(){for(let l=0;l<this.handlerInfos.length;l++)Ki(this.element,this.handlerInfos[l]);this.handlerInfos=[]}}function In(s){return s.eventType}function Rt(s,l){s.eventType=l}function jn(s){return s.event}function Fi(s,l){s.event=l}function Ui(s){return s.targetElement}function ar(s,l){s.targetElement=l}function er(s){return s.eic}function Tn(s){return s.eia}function Ri(s,l,d){s.eia=[l,d]}function Un(s){s.eia=void 0}function Wi(s){return s[1]}function Li(s,l){s.eirp=l}function Mo(s){return s.eir}function ks(s,l){s.eir=l}function Jo(s){return{eventType:s.eventType,event:s.event,targetElement:s.targetElement,eic:s.eic,eia:s.eia,timeStamp:s.timeStamp,eirp:s.eirp,eiack:s.eiack,eir:s.eir}}class ds{constructor(l){this.eventInfo=l}getEventType(){return In(this.eventInfo)}setEventType(l){Rt(this.eventInfo,l)}getEvent(){return jn(this.eventInfo)}setEvent(l){Fi(this.eventInfo,l)}getTargetElement(){return Ui(this.eventInfo)}setTargetElement(l){ar(this.eventInfo,l)}getContainer(){return er(this.eventInfo)}setContainer(l){!function Or(s,l){s.eic=l}(this.eventInfo,l)}getTimestamp(){return function Tt(s){return s.timeStamp}(this.eventInfo)}setTimestamp(l){!function cn(s,l){s.timeStamp=l}(this.eventInfo,l)}getAction(){const l=Tn(this.eventInfo);if(l)return{name:l[0],element:l[1]}}setAction(l){l?Ri(this.eventInfo,l.name,l.element):Un(this.eventInfo)}getIsReplay(){return function fr(s){return s.eirp}(this.eventInfo)}setIsReplay(l){Li(this.eventInfo,l)}getResolved(){return Mo(this.eventInfo)}setResolved(l){ks(this.eventInfo,l)}clone(){return new ds(Jo(this.eventInfo))}}const Ws={},es=/\s*;\s*/;class ts{constructor({syntheticMouseEventSupport:l=!1,clickModSupport:d=!0}={}){this.a11yClickSupport=!1,this.clickModSupport=!0,this.updateEventInfoForA11yClick=void 0,this.preventDefaultForA11yClick=void 0,this.populateClickOnlyAction=void 0,this.syntheticMouseEventSupport=l,this.clickModSupport=d}resolveEventType(l){this.clickModSupport&&"click"===In(l)&&function Ve(s){return it&&s.metaKey||!it&&s.ctrlKey||function sn(s){return 2===s.which||null==s.which&&4===s.button}(s)||s.shiftKey}(jn(l))?Rt(l,"clickmod"):this.a11yClickSupport&&this.updateEventInfoForA11yClick(l)}resolveAction(l){Mo(l)||(this.populateAction(l,Ui(l)),ks(l,!0))}resolveParentAction(l){const d=Tn(l),h=d&&Wi(d);Un(l);const w=h&&this.getParentNode(h);w&&this.populateAction(l,w)}populateAction(l,d){let h=d;for(;h&&h!==er(l)&&(h.nodeType===Node.ELEMENT_NODE&&this.populateActionOnElement(h,l),!Tn(l));)h=this.getParentNode(h);const w=Tn(l);if(w&&(this.a11yClickSupport&&this.preventDefaultForA11yClick(l),this.syntheticMouseEventSupport&&("mouseenter"===In(l)||"mouseleave"===In(l)||"pointerenter"===In(l)||"pointerleave"===In(l))))if(function Ls(s,l,d){const h=s.relatedTarget;return("mouseover"===s.type&&"mouseenter"===l||"mouseout"===s.type&&"mouseleave"===l||"pointerover"===s.type&&"pointerenter"===l||"pointerout"===s.type&&"pointerleave"===l)&&(!h||h!==d&&!d.contains(h))}(jn(l),In(l),Wi(w))){const L=function ol(s,l){const d={};for(const h in s){if("srcElement"===h||"target"===h)continue;const L=s[h];"function"!=typeof L&&(d[h]=L)}return d.type="mouseover"===s.type?"mouseenter":"mouseout"===s.type?"mouseleave":"pointerover"===s.type?"pointerenter":"pointerleave",d.target=d.srcElement=l,d.bubbles=!1,d}(jn(l),Wi(w));Fi(l,L),ar(l,Wi(w))}else Un(l)}getParentNode(l){const d=l[Ur_OWNER];if(d)return d;const h=l.parentNode;return"#document-fragment"===h?.nodeName?h?.host??null:h}populateActionOnElement(l,d){const h=this.parseActions(l),w=h[In(d)];void 0!==w&&Ri(d,w,l),this.a11yClickSupport&&this.populateClickOnlyAction(l,d,h)}parseActions(l){let d=function as(s){return s[Ur_JSACTION]}(l);if(!d){const h=l.getAttribute(Xr.JSACTION);if(h){if(d=function ci(s){return eo[s]}(h),!d){d={};const w=h.split(es);for(let L=0;L<w.length;L++){const z=w[L];if(!z)continue;const ae=z.indexOf(":"),xe=-1!==ae,qe=xe?z.substr(0,ae).trim():"click",ft=xe?z.substr(ae+1).trim():z;d[qe]=ft}!function yt(s,l){eo[s]=l}(h,d)}mi(l,d)}else d=Ws,mi(l,d)}return d}addA11yClickSupport(l,d,h){this.a11yClickSupport=!0,this.updateEventInfoForA11yClick=l,this.preventDefaultForA11yClick=d,this.populateClickOnlyAction=h}}var wo=function(s){return s[s.I_AM_THE_JSACTION_FRAMEWORK=0]="I_AM_THE_JSACTION_FRAMEWORK",s}(wo||{});class ea{constructor(l,{actionResolver:d,eventReplayer:h}={}){this.dispatchDelegate=l,this.eventReplayScheduled=!1,this.replayEventInfoWrappers=[],this.actionResolver=d,this.eventReplayer=h}dispatch(l){const d=new ds(l);this.actionResolver?.resolveEventType(l),this.actionResolver?.resolveAction(l);const h=d.getAction();h&&function sl(s,l){return"A"===s.tagName&&("click"===l.getEventType()||"clickmod"===l.getEventType())}(h.element,d)&&function hi(s){s.preventDefault?s.preventDefault():s.returnValue=!1}(d.getEvent()),this.eventReplayer&&d.getIsReplay()?this.scheduleEventInfoWrapperReplay(d):this.dispatchDelegate(d)}scheduleEventInfoWrapperReplay(l){this.replayEventInfoWrappers.push(l),!this.eventReplayScheduled&&(this.eventReplayScheduled=!0,Promise.resolve().then(()=>{this.eventReplayScheduled=!1,this.eventReplayer(this.replayEventInfoWrappers)}))}}const Ia=Symbol.for("propagationStopped");class la{constructor(l,d=!0){this.dispatchDelegate=l,this.clickModSupport=d,this.actionResolver=new ts({clickModSupport:d}),this.dispatcher=new ea(h=>{this.dispatchToDelegate(h)},{actionResolver:this.actionResolver})}dispatch(l){this.dispatcher.dispatch(l)}dispatchToDelegate(l){for(l.getIsReplay()&&function Ec(s){const l=s.getEvent(),d=s.getTargetElement(),h=l.preventDefault.bind(l);ql(l,"target",d),ql(l,"eventPhase",101),ql(l,"preventDefault",()=>{throw h(),new Error("`preventDefault` called during event replay.")}),ql(l,"composedPath",()=>{throw new Error("`composedPath` called during event replay.")})}(l),function pl(s){const l=s.getEvent(),d=s.getEvent().stopPropagation.bind(l),h=()=>{l[Ia]=!0,d()};ql(l,"stopPropagation",h),ql(l,"stopImmediatePropagation",h)}(l);l.getAction();){if(Qc(l),At(l.getEventType())&&l.getAction().element!==l.getTargetElement()||(this.dispatchDelegate(l.getEvent(),l.getAction().name),l.getEvent()[Ia]))return;this.actionResolver.resolveParentAction(l.eventInfo)}}}function Qc(s){const l=s.getEvent(),d=s.getAction()?.element;d&&ql(l,"currentTarget",d,{configurable:!0})}function ql(s,l,d,{configurable:h=!1}={}){Object.defineProperty(s,l,{value:d,configurable:h})}function sa(s,l,d,h){for(let w=0;w<l.length;w++)s.removeEventListener(l[w],d,h)}let Aa=(()=>{class s{static#e=this.MOUSE_SPECIAL_SUPPORT=!1;constructor(d){this.eventHandlers={},this.browserEventTypeToExtraEventTypes={},this.dispatcher=null,this.queuedEventInfos=[],this.containerManager=d}handleEvent(d,h,w){const L=function $s(s,l,d,h,w,L,z,ae){return{eventType:s,event:l,targetElement:d,eic:h,timeStamp:w,eia:L,eirp:z,eiack:ae}}(d,h,h.target,w,Date.now());this.handleEventInfo(L)}handleEventInfo(d){if(!this.dispatcher)return Li(d,!0),void this.queuedEventInfos?.push(d);this.dispatcher(d)}addEvent(d,h){if(d in this.eventHandlers||!this.containerManager||!s.MOUSE_SPECIAL_SUPPORT&&Gn.indexOf(d)>=0)return;const w=(z,ae,xe)=>{this.handleEvent(z,ae,xe)};this.eventHandlers[d]=w;const L=function Gi(s){return"mouseenter"===s?"mouseover":"mouseleave"===s?"mouseout":"pointerenter"===s?"pointerover":"pointerleave"===s?"pointerout":s}(h||d);if(L!==d){const z=this.browserEventTypeToExtraEventTypes[L]||[];z.push(d),this.browserEventTypeToExtraEventTypes[L]=z}this.containerManager.addEventListener(L,z=>ae=>{w(d,ae,z)})}replayEarlyEvents(d=window._ejsa){d&&(this.replayEarlyEventInfos(d.q),function yl(s){s&&(sa(s.c,s.et,s.h),sa(s.c,s.etc,s.h,!0))}(d),delete window._ejsa)}replayEarlyEventInfos(d){for(let h=0;h<d.length;h++){const w=d[h],L=this.getEventTypesForBrowserEventType(w.eventType);for(let z=0;z<L.length;z++){const ae=Jo(w);Rt(ae,L[z]),this.handleEventInfo(ae)}}}getEventTypesForBrowserEventType(d){const h=[];return this.eventHandlers[d]&&h.push(d),this.browserEventTypeToExtraEventTypes[d]&&h.push(...this.browserEventTypeToExtraEventTypes[d]),h}handler(d){return this.eventHandlers[d]}cleanUp(){this.containerManager.cleanUp(),this.containerManager=null,this.eventHandlers={},this.browserEventTypeToExtraEventTypes={},this.dispatcher=null,this.queuedEventInfos=[]}registerDispatcher(d,h){this.ecrd(d,h)}ecrd(d,h){if(this.dispatcher=d,this.queuedEventInfos?.length){for(let w=0;w<this.queuedEventInfos.length;w++)this.handleEventInfo(this.queuedEventInfos[w]);this.queuedEventInfos=null}}}return s})();const Fc="https://g.co/ng/security#xss";class po extends Error{constructor(l,d){super(Ll(l,d)),this.code=l}}function Ll(s,l){return`NG0${Math.abs(s)}${l?": "+l:""}`}const Hs=Symbol("InputSignalNode#UNSET"),kl={...Zn,transformFn:void 0,applyValueToInputSignal(s,l){Cn(s,l)}},fu=Symbol();function Rc(s,l){const d=Object.create(kl);function h(){if(Z(d),d.value===Hs)throw new po(-950,!1);return d.value}return d.value=s,d.transformFn=l?.transform,h[ie]=d,h}function Ke(s){return{toString:s}.toString()}const Se="__annotations__",re="__parameters__",Ge="__prop__metadata__";function xt(s,l,d,h,w){return Ke(()=>{const L=Qt(l);function z(...ae){if(this instanceof z)return L.call(this,...ae),this;const xe=new z(...ae);return function(ft){return w&&w(ft,...ae),(ft.hasOwnProperty(Se)?ft[Se]:Object.defineProperty(ft,Se,{value:[]})[Se]).push(xe),h&&h(ft),ft}}return d&&(z.prototype=Object.create(d.prototype)),z.prototype.ngMetadataName=s,z.annotationCls=z,z})}function Qt(s){return function(...d){if(s){const h=s(...d);for(const w in h)this[w]=h[w]}}}function kn(s,l,d){return Ke(()=>{const h=Qt(l);function w(...L){if(this instanceof w)return h.apply(this,L),this;const z=new w(...L);return ae.annotation=z,ae;function ae(xe,qe,ft){const Xt=xe.hasOwnProperty(re)?xe[re]:Object.defineProperty(xe,re,{value:[]})[re];for(;Xt.length<=ft;)Xt.push(null);return(Xt[ft]=Xt[ft]||[]).push(z),xe}}return d&&(w.prototype=Object.create(d.prototype)),w.prototype.ngMetadataName=s,w.annotationCls=w,w})}function bi(s,l,d,h){return Ke(()=>{const w=Qt(l);function L(...z){if(this instanceof L)return w.apply(this,z),this;const ae=new L(...z);return function xe(qe,ft){if(void 0===qe)throw new Error("Standard Angular field decorators are not supported in JIT mode.");const Xt=qe.constructor,Ln=Xt.hasOwnProperty(Ge)?Xt[Ge]:Object.defineProperty(Xt,Ge,{value:{}})[Ge];Ln[ft]=Ln.hasOwnProperty(ft)&&Ln[ft]||[],Ln[ft].unshift(ae),h&&h(qe,ft,...z)}}return d&&(L.prototype=Object.create(d.prototype)),L.prototype.ngMetadataName=s,L.annotationCls=L,L})}const vi=globalThis;function $i(s){for(let l in s)if(s[l]===$i)return l;throw Error("Could not find renamed property on target object.")}function Er(s,l){for(const d in l)l.hasOwnProperty(d)&&!s.hasOwnProperty(d)&&(s[d]=l[d])}function ai(s){if("string"==typeof s)return s;if(Array.isArray(s))return"["+s.map(ai).join(", ")+"]";if(null==s)return""+s;if(s.overriddenName)return`${s.overriddenName}`;if(s.name)return`${s.name}`;const l=s.toString();if(null==l)return""+l;const d=l.indexOf("\n");return-1===d?l:l.substring(0,d)}function so(s,l){return null==s||""===s?null===l?"":l:null==l||""===l?s:s+" "+l}function Fr(s,l=100){if(!s||l<1||s.length<=l)return s;if(1==l)return s.substring(0,1)+"...";const d=Math.round(l/2);return s.substring(0,d)+"..."+s.substring(s.length-d)}const zr=$i({__forward_ref__:$i});function ho(s){return s.__forward_ref__=ho,s.toString=function(){return ai(this())},s}function Vr(s){return is(s)?s():s}function is(s){return"function"==typeof s&&s.hasOwnProperty(zr)&&s.__forward_ref__===ho}function Di(s,l,d,h){throw new Error(`ASSERTION ERROR: ${s}`+(null==h?"":` [Expected=> ${d} ${h} ${l} <=Actual]`))}function Ks(s){return{token:s.token,providedIn:s.providedIn||null,factory:s.factory,value:void 0}}const ac=Ks;function lc(s){return{providers:s.providers||[],imports:s.imports||[]}}function ou(s){return da(s,bl)||da(s,cc)}function qd(s){return null!==ou(s)}function da(s,l){return s.hasOwnProperty(l)?s[l]:null}function xp(s){return s&&(s.hasOwnProperty(_c)||s.hasOwnProperty(qf))?s[_c]:null}const bl=$i({\u0275prov:$i}),_c=$i({\u0275inj:$i}),cc=$i({ngInjectableDef:$i}),qf=$i({ngInjectorDef:$i});class aa{constructor(l,d){this._desc=l,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof d?this.__NG_ELEMENT_ID__=d:void 0!==d&&(this.\u0275prov=Ks({token:this,providedIn:d.providedIn||"root",factory:d.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}let Tc;function hd(s){Di("setInjectorProfilerContext should never be called in production mode");const l=Tc;return Tc=s,l}function gd(s){return s&&!!s.\u0275providers}const Eu=$i({\u0275cmp:$i}),Pu=$i({\u0275dir:$i}),Lc=$i({\u0275pipe:$i}),qs=$i({\u0275mod:$i}),Xc=$i({\u0275fac:$i}),Bu=$i({__NG_ELEMENT_ID__:$i}),su=$i({__NG_ENV_ID__:$i});function Is(s){return"string"==typeof s?s:null==s?"":String(s)}function xa(s){return"function"==typeof s?s.name||s.toString():"object"==typeof s&&null!=s&&"function"==typeof s.type?s.type.name||s.type.toString():Is(s)}function hu(s,l){throw new po(-201,!1)}var As=function(s){return s[s.Default=0]="Default",s[s.Host=1]="Host",s[s.Self=2]="Self",s[s.SkipSelf=4]="SkipSelf",s[s.Optional=8]="Optional",s}(As||{});let Ed;function kc(){return Ed}function El(s){const l=Ed;return Ed=s,l}function uc(s,l,d){const h=ou(s);return h&&"root"==h.providedIn?void 0===h.value?h.value=h.factory():h.value:d&As.Optional?null:void 0!==l?l:void hu()}const Pc={},ju="__NG_DI_FLAG__",Yl="ngTempTokenPath",pf=/\n/gm,_e="__source";let Dt;function tt(s){const l=Dt;return Dt=s,l}function mn(s,l=As.Default){if(void 0===Dt)throw new po(-203,!1);return null===Dt?uc(s,void 0,l):Dt.get(s,l&As.Optional?null:void 0,l)}function gi(s,l=As.Default){return(kc()||mn)(Vr(s),l)}function rr(s){throw new po(202,!1)}function or(s,l=As.Default){return gi(s,ia(l))}function ia(s){return typeof s>"u"||"number"==typeof s?s:(s.optional&&8)|(s.host&&1)|(s.self&&2)|(s.skipSelf&&4)}function La(s){const l=[];for(let d=0;d<s.length;d++){const h=Vr(s[d]);if(Array.isArray(h)){if(0===h.length)throw new po(900,!1);let w,L=As.Default;for(let z=0;z<h.length;z++){const ae=h[z],xe=Qo(ae);"number"==typeof xe?-1===xe?w=ae.token:L|=xe:w=ae}l.push(gi(w,L))}else l.push(gi(h))}return l}function vs(s,l){return s[ju]=l,s.prototype[ju]=l,s}function Qo(s){return s[ju]}const $o=vs(kn("Inject",s=>({token:s})),-1),Mc=vs(kn("Optional"),8),yc=vs(kn("Self"),2),Ue=vs(kn("SkipSelf"),4),ne=vs(kn("Host"),1);function Pe(s,l){return s.hasOwnProperty(Xc)?s[Xc]:null}function Ut(s){return s.flat(Number.POSITIVE_INFINITY)}function Rn(s,l){s.forEach(d=>Array.isArray(d)?Rn(d,l):l(d))}function Kn(s,l,d){l>=s.length?s.push(d):s.splice(l,0,d)}function Y(s,l){return l>=s.length-1?s.pop():s.splice(l,1)[0]}function Ce(s,l){const d=[];for(let h=0;h<s;h++)d.push(l);return d}function ue(s,l,d){const h=s.length-d;for(;l<h;)s[l]=s[l+d],l++;for(;d--;)s.pop()}function Ze(s,l,d,h){let w=s.length;if(w==l)s.push(d,h);else if(1===w)s.push(h,s[0]),s[0]=d;else{for(w--,s.push(s[w-1],s[w]);w>l;)s[w]=s[w-2],w--;s[l]=d,s[l+1]=h}}function rn(s,l,d){let h=oi(s,l);return h>=0?s[1|h]=d:(h=~h,Ze(s,h,l,d)),h}function Si(s,l){const d=oi(s,l);if(d>=0)return s[1|d]}function oi(s,l){return function rs(s,l,d){let h=0,w=s.length>>d;for(;w!==h;){const L=h+(w-h>>1),z=s[L<<d];if(l===z)return L<<d;z>l?w=L:h=L+1}return~(w<<d)}(s,l,1)}const ls={},Zo=[],Hl=new aa(""),dc=new aa("",-1),ws=new aa("");class Vc{get(l,d=Pc){if(d===Pc){const h=new Error(`NullInjectorError: No provider for ${ai(l)}!`);throw h.name="NullInjectorError",h}return d}}var Wo=function(s){return s[s.OnPush=0]="OnPush",s[s.Default=1]="Default",s}(Wo||{}),sr=function(s){return s[s.Emulated=0]="Emulated",s[s.None=2]="None",s[s.ShadowDom=3]="ShadowDom",s}(sr||{}),ro=function(s){return s[s.None=0]="None",s[s.SignalBased=1]="SignalBased",s[s.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",s}(ro||{});function Ic(s,l,d){let h=s.length;for(;;){const w=s.indexOf(l,d);if(-1===w)return w;if(0===w||s.charCodeAt(w-1)<=32){const L=l.length;if(w+L===h||s.charCodeAt(w+L)<=32)return w}d=w+1}}function Sp(s,l,d){let h=0;for(;h<d.length;){const w=d[h];if("number"==typeof w){if(0!==w)break;h++;const L=d[h++],z=d[h++],ae=d[h++];s.setAttribute(l,z,ae,L)}else{const L=w,z=d[++h];Uu(L)?s.setProperty(l,L,z):s.setAttribute(l,L,z),h++}}return h}function au(s){return 3===s||4===s||6===s}function Uu(s){return 64===s.charCodeAt(0)}function bh(s,l){if(null!==l&&0!==l.length)if(null===s||0===s.length)s=l.slice();else{let d=-1;for(let h=0;h<l.length;h++){const w=l[h];"number"==typeof w?d=w:0===d||wv(s,d,w,null,-1===d||2===d?l[++h]:null)}}return s}function wv(s,l,d,h,w){let L=0,z=s.length;if(-1===l)z=-1;else for(;L<s.length;){const ae=s[L++];if("number"==typeof ae){if(ae===l){z=-1;break}if(ae>l){z=L-1;break}}}for(;L<s.length;){const ae=s[L];if("number"==typeof ae)break;if(ae===d){if(null===h)return void(null!==w&&(s[L+1]=w));if(h===s[L+1])return void(s[L+2]=w)}L++,null!==h&&L++,null!==w&&L++}-1!==z&&(s.splice(z,0,l),L=z+1),s.splice(L++,0,d),null!==h&&s.splice(L++,0,h),null!==w&&s.splice(L++,0,w)}const op="ng-template";function Pd(s,l,d,h){let w=0;if(h){for(;w<l.length&&"string"==typeof l[w];w+=2)if("class"===l[w]&&-1!==Ic(l[w+1].toLowerCase(),d,0))return!0}else if($u(s))return!1;if(w=l.indexOf(1,w),w>-1){let L;for(;++w<l.length&&"string"==typeof(L=l[w]);)if(L.toLowerCase()===d)return!0}return!1}function $u(s){return 4===s.type&&s.value!==op}function Yh(s,l,d){return l===(4!==s.type||d?s.value:op)}function yg(s,l,d){let h=4;const w=s.attrs,L=null!==w?function U_(s){for(let l=0;l<s.length;l++)if(au(s[l]))return l;return s.length}(w):0;let z=!1;for(let ae=0;ae<l.length;ae++){const xe=l[ae];if("number"!=typeof xe){if(!z)if(4&h){if(h=2|1&h,""!==xe&&!Yh(s,xe,d)||""===xe&&1===l.length){if(Qd(h))return!1;z=!0}}else if(8&h){if(null===w||!Pd(s,w,xe,d)){if(Qd(h))return!1;z=!0}}else{const qe=l[++ae],ft=xv(xe,w,$u(s),d);if(-1===ft){if(Qd(h))return!1;z=!0;continue}if(""!==qe){let Xt;if(Xt=ft>L?"":w[ft+1].toLowerCase(),2&h&&qe!==Xt){if(Qd(h))return!1;z=!0}}}}else{if(!z&&!Qd(h)&&!Qd(xe))return!1;if(z&&Qd(xe))continue;z=!1,h=xe|1&h}}return Qd(h)||z}function Qd(s){return!(1&s)}function xv(s,l,d,h){if(null===l)return-1;let w=0;if(h||!d){let L=!1;for(;w<l.length;){const z=l[w];if(z===s)return w;if(3===z||6===z)L=!0;else{if(1===z||2===z){let ae=l[++w];for(;"string"==typeof ae;)ae=l[++w];continue}if(4===z)break;if(0===z){w+=4;continue}}w+=L?1:2}return-1}return function Ch(s,l){let d=s.indexOf(4);if(d>-1)for(d++;d<s.length;){const h=s[d];if("number"==typeof h)return-1;if(h===l)return d;d++}return-1}(l,s)}function bg(s,l,d=!1){for(let h=0;h<l.length;h++)if(yg(s,l[h],d))return!0;return!1}function Zc(s,l){e:for(let d=0;d<l.length;d++){const h=l[d];if(s.length===h.length){for(let w=0;w<s.length;w++)if(s[w]!==h[w])continue e;return!0}}return!1}function Tu(s,l){return s?":not("+l.trim()+")":l}function If(s){let l=s[0],d=1,h=2,w="",L=!1;for(;d<s.length;){let z=s[d];if("string"==typeof z)if(2&h){const ae=s[++d];w+="["+z+(ae.length>0?'="'+ae+'"':"")+"]"}else 8&h?w+="."+z:4&h&&(w+=" "+z);else""!==w&&!Qd(z)&&(l+=Tu(L,w),w=""),h=z,L=L||!Qd(h);d++}return""!==w&&(l+=Tu(L,w)),l}function xr(s){return Ke(()=>{const l=Xd(s),d={...l,decls:s.decls,vars:s.vars,template:s.template,consts:s.consts||null,ngContentSelectors:s.ngContentSelectors,onPush:s.changeDetection===Wo.OnPush,directiveDefs:null,pipeDefs:null,dependencies:l.standalone&&s.dependencies||null,getStandaloneInjector:null,signals:s.signals??!1,data:s.data||{},encapsulation:s.encapsulation||sr.Emulated,styles:s.styles||Zo,_:null,schemas:s.schemas||null,tView:null,id:""};Ev(d);const h=s.dependencies;return d.directiveDefs=sp(h,!1),d.pipeDefs=sp(h,!0),d.id=function va(s){let l=0;const d=[s.selectors,s.ngContentSelectors,s.hostVars,s.hostAttrs,s.consts,s.vars,s.decls,s.encapsulation,s.standalone,s.signals,s.exportAs,JSON.stringify(s.inputs),JSON.stringify(s.outputs),Object.getOwnPropertyNames(s.type.prototype),!!s.contentQueries,!!s.viewQuery].join("|");for(const w of d)l=Math.imul(31,l)+w.charCodeAt(0)|0;return l+=2147483648,"c"+l}(d),d})}function Dh(s){return ja(s)||xs(s)}function D0(s){return null!==s}function $_(s){return Ke(()=>({type:s.type,bootstrap:s.bootstrap||Zo,declarations:s.declarations||Zo,imports:s.imports||Zo,exports:s.exports||Zo,transitiveCompileScopes:null,schemas:s.schemas||null,id:s.id||null}))}function Cg(s,l){if(null==s)return ls;const d={};for(const h in s)if(s.hasOwnProperty(h)){const w=s[h];let L,z,ae=ro.None;Array.isArray(w)?(ae=w[0],L=w[1],z=w[2]??L):(L=w,z=w),l?(d[L]=ae!==ro.None?[h,ae]:h,l[L]=z):d[L]=h}return d}function Sv(s){return Ke(()=>{const l=Xd(s);return Ev(l),l})}function Am(s){return{type:s.type,name:s.name,factory:null,pure:!1!==s.pure,standalone:!0===s.standalone,onDestroy:s.type.prototype.ngOnDestroy||null}}function ja(s){return s[Eu]||null}function xs(s){return s[Pu]||null}function rd(s){return s[Lc]||null}function Yd(s){const l=ja(s)||xs(s)||rd(s);return null!==l&&l.standalone}function Qu(s,l){const d=s[qs]||null;if(!d&&!0===l)throw new Error(`Type ${ai(s)} does not have '\u0275mod' property.`);return d}function Xd(s){const l={};return{type:s.type,providersResolver:null,factory:null,hostBindings:s.hostBindings||null,hostVars:s.hostVars||0,hostAttrs:s.hostAttrs||null,contentQueries:s.contentQueries||null,declaredInputs:l,inputTransforms:null,inputConfig:s.inputs||ls,exportAs:s.exportAs||null,standalone:!0===s.standalone,signals:!0===s.signals,selectors:s.selectors||Zo,viewQuery:s.viewQuery||null,features:s.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:Cg(s.inputs,l),outputs:Cg(s.outputs),debugInfo:null}}function Ev(s){s.features?.forEach(l=>l(s))}function sp(s,l){if(!s)return null;const d=l?rd:Dh;return()=>("function"==typeof s?s():s).map(h=>d(h)).filter(D0)}const Ep=new Map;function bc(s){return{\u0275providers:s}}function Bs(...s){return{\u0275providers:wh(0,s),\u0275fromNgModule:!0}}function wh(s,...l){const d=[],h=new Set;let w;const L=z=>{d.push(z)};return Rn(l,z=>{const ae=z;Wu(ae,L,[],h)&&(w||=[],w.push(ae))}),void 0!==w&&Om(w,L),d}function Om(s,l){for(let d=0;d<s.length;d++){const{ngModule:h,providers:w}=s[d];Tp(w,L=>{l(L,h)})}}function Wu(s,l,d,h){if(!(s=Vr(s)))return!1;let w=null,L=xp(s);const z=!L&&ja(s);if(L||z){if(z&&!z.standalone)return!1;w=s}else{const xe=s.ngModule;if(L=xp(xe),!L)return!1;w=xe}const ae=h.has(w);if(z){if(ae)return!1;if(h.add(w),z.dependencies){const xe="function"==typeof z.dependencies?z.dependencies():z.dependencies;for(const qe of xe)Wu(qe,l,d,h)}}else{if(!L)return!1;{if(null!=L.imports&&!ae){let qe;h.add(w);try{Rn(L.imports,ft=>{Wu(ft,l,d,h)&&(qe||=[],qe.push(ft))})}finally{}void 0!==qe&&Om(qe,l)}if(!ae){const qe=Pe(w)||(()=>new w);l({provide:w,useFactory:qe,deps:Zo},w),l({provide:ws,useValue:w,multi:!0},w),l({provide:Hl,useValue:()=>gi(w),multi:!0},w)}const xe=L.providers;if(null!=xe&&!ae){const qe=s;Tp(xe,ft=>{l(ft,qe)})}}}return w!==s&&void 0!==s.providers}function Tp(s,l){for(let d of s)gd(d)&&(d=d.\u0275providers),Array.isArray(d)?Tp(d,l):l(d)}const Mp=$i({provide:String,useValue:$i});function Zd(s){return null!==s&&"object"==typeof s&&Mp in s}function Af(s){return"function"==typeof s}const Mu=new aa(""),Jd={},W_={};let Iu;function ns(){return void 0===Iu&&(Iu=new Vc),Iu}class Hu{}class gf extends Hu{get destroyed(){return this._destroyed}constructor(l,d,h,w){super(),this.parent=d,this.source=h,this.scopes=w,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,Ip(l,z=>this.processProvider(z)),this.records.set(dc,Of(void 0,this)),w.has("environment")&&this.records.set(Hu,Of(void 0,this));const L=this.records.get(Mu);null!=L&&"string"==typeof L.value&&this.scopes.add(L.value),this.injectorDefTypes=new Set(this.get(ws,Zo,As.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;const l=Q(null);try{for(const h of this._ngOnDestroyHooks)h.ngOnDestroy();const d=this._onDestroyHooks;this._onDestroyHooks=[];for(const h of d)h()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),Q(l)}}onDestroy(l){return this.assertNotDestroyed(),this._onDestroyHooks.push(l),()=>this.removeOnDestroy(l)}runInContext(l){this.assertNotDestroyed();const d=tt(this),h=El(void 0);try{return l()}finally{tt(d),El(h)}}get(l,d=Pc,h=As.Default){if(this.assertNotDestroyed(),l.hasOwnProperty(su))return l[su](this);h=ia(h);const L=tt(this),z=El(void 0);try{if(!(h&As.SkipSelf)){let xe=this.records.get(l);if(void 0===xe){const qe=function r1(s){return"function"==typeof s||"object"==typeof s&&s instanceof aa}(l)&&ou(l);xe=qe&&this.injectableDefInScope(qe)?Of(Zp(l),Jd):null,this.records.set(l,xe)}if(null!=xe)return this.hydrate(l,xe)}return(h&As.Self?ns():this.parent).get(l,d=h&As.Optional&&d===Pc?null:d)}catch(ae){if("NullInjectorError"===ae.name){if((ae[Yl]=ae[Yl]||[]).unshift(ai(l)),L)throw ae;return function ll(s,l,d,h){const w=s[Yl];throw l[_e]&&w.unshift(l[_e]),s.message=function Sa(s,l,d,h=null){s=s&&"\n"===s.charAt(0)&&"\u0275"==s.charAt(1)?s.slice(2):s;let w=ai(l);if(Array.isArray(l))w=l.map(ai).join(" -> ");else if("object"==typeof l){let L=[];for(let z in l)if(l.hasOwnProperty(z)){let ae=l[z];L.push(z+":"+("string"==typeof ae?JSON.stringify(ae):ai(ae)))}w=`{${L.join(", ")}}`}return`${d}${h?"("+h+")":""}[${w}]: ${s.replace(pf,"\n ")}`}("\n"+s.message,w,d,h),s.ngTokenPath=w,s[Yl]=null,s}(ae,l,"R3InjectorError",this.source)}throw ae}finally{El(z),tt(L)}}resolveInjectorInitializers(){const l=Q(null),d=tt(this),h=El(void 0);try{const L=this.get(Hl,Zo,As.Self);for(const z of L)z()}finally{tt(d),El(h),Q(l)}}toString(){const l=[],d=this.records;for(const h of d.keys())l.push(ai(h));return`R3Injector[${l.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new po(205,!1)}processProvider(l){let d=Af(l=Vr(l))?l:Vr(l&&l.provide);const h=function Tv(s){return Zd(s)?Of(void 0,s.useValue):Of(Md(s),Jd)}(l);if(!Af(l)&&!0===l.multi){let w=this.records.get(d);w||(w=Of(void 0,Jd,!0),w.factory=()=>La(w.multi),this.records.set(d,w)),d=l,w.multi.push(l)}this.records.set(d,h)}hydrate(l,d){const h=Q(null);try{return d.value===Jd&&(d.value=W_,d.value=d.factory()),"object"==typeof d.value&&d.value&&function w0(s){return null!==s&&"object"==typeof s&&"function"==typeof s.ngOnDestroy}(d.value)&&this._ngOnDestroyHooks.add(d.value),d.value}finally{Q(h)}}injectableDefInScope(l){if(!l.providedIn)return!1;const d=Vr(l.providedIn);return"string"==typeof d?"any"===d||this.scopes.has(d):this.injectorDefTypes.has(d)}removeOnDestroy(l){const d=this._onDestroyHooks.indexOf(l);-1!==d&&this._onDestroyHooks.splice(d,1)}}function Zp(s){const l=ou(s),d=null!==l?l.factory:Pe(s);if(null!==d)return d;if(s instanceof aa)throw new po(204,!1);if(s instanceof Function)return function xh(s){if(s.length>0)throw new po(204,!1);const d=function nd(s){return s&&(s[bl]||s[cc])||null}(s);return null!==d?()=>d.factory(s):()=>new s}(s);throw new po(204,!1)}function Md(s,l,d){let h;if(Af(s)){const w=Vr(s);return Pe(w)||Zp(w)}if(Zd(s))h=()=>Vr(s.useValue);else if(function ap(s){return!(!s||!s.useFactory)}(s))h=()=>s.useFactory(...La(s.deps||[]));else if(function Fm(s){return!(!s||!s.useExisting)}(s))h=()=>gi(Vr(s.useExisting));else{const w=Vr(s&&(s.useClass||s.provide));if(!function Qf(s){return!!s.deps}(s))return Pe(w)||Zp(w);h=()=>new w(...La(s.deps))}return h}function Of(s,l,d=!1){return{factory:s,value:l,multi:d?[]:void 0}}function Ip(s,l){for(const d of s)Array.isArray(d)?Ip(d,l):d&&gd(d)?Ip(d.\u0275providers,l):l(d)}function Mv(s,l){s instanceof gf&&s.assertNotDestroyed();const h=tt(s),w=El(void 0);try{return l()}finally{tt(h),El(w)}}function Xh(){return void 0!==kc()||null!=function Re(){return Dt}()}function Nm(s){if(!Xh())throw new po(-203,!1)}var od=function(s){return s[s.Directive=0]="Directive",s[s.Component=1]="Component",s[s.Injectable=2]="Injectable",s[s.Pipe=3]="Pipe",s[s.NgModule=4]="NgModule",s}(od||{});function mu(s){const l=vi.ng;if(l&&l.\u0275compilerFacade)return l.\u0275compilerFacade;throw new Error("JIT compiler unavailable")}const Zh={\u0275\u0275defineInjectable:Ks,\u0275\u0275defineInjector:lc,\u0275\u0275inject:gi,\u0275\u0275invalidFactoryDep:rr,resolveForwardRef:Vr},H_=Function;function Ff(s){return"function"==typeof s}const yd=/^function\s+\S+\(\)\s*{[\s\S]+\.apply\(this,\s*(arguments|(?:[^()]+\(\[\],)?[^()]+\(arguments\).*)\)/,Rm=/^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{/,Lm=/^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{[\s\S]*constructor\s*\(/,Sh=/^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{[\s\S]*constructor\s*\(\)\s*{[^}]*super\(\.\.\.arguments\)/;class km{constructor(l){this._reflect=l||vi.Reflect}factory(l){return(...d)=>new l(...d)}_zipTypesAndAnnotations(l,d){let h;h=Ce(typeof l>"u"?d.length:l.length);for(let w=0;w<h.length;w++)h[w]=typeof l>"u"?[]:l[w]&&l[w]!=Object?[l[w]]:[],d&&null!=d[w]&&(h[w]=h[w].concat(d[w]));return h}_ownParameters(l,d){if(function Dg(s){return yd.test(s)||Sh.test(s)||Rm.test(s)&&!Lm.test(s)}(l.toString()))return null;if(l.parameters&&l.parameters!==d.parameters)return l.parameters;const w=l.ctorParameters;if(w&&w!==d.ctorParameters){const ae="function"==typeof w?w():w,xe=ae.map(ft=>ft&&ft.type),qe=ae.map(ft=>ft&&Nf(ft.decorators));return this._zipTypesAndAnnotations(xe,qe)}const L=l.hasOwnProperty(re)&&l[re],z=this._reflect&&this._reflect.getOwnMetadata&&this._reflect.getOwnMetadata("design:paramtypes",l);return z||L?this._zipTypesAndAnnotations(z,L):Ce(l.length)}parameters(l){if(!Ff(l))return[];const d=Jp(l);let h=this._ownParameters(l,d);return!h&&d!==Object&&(h=this.parameters(d)),h||[]}_ownAnnotations(l,d){if(l.annotations&&l.annotations!==d.annotations){let h=l.annotations;return"function"==typeof h&&h.annotations&&(h=h.annotations),h}return l.decorators&&l.decorators!==d.decorators?Nf(l.decorators):l.hasOwnProperty(Se)?l[Se]:null}annotations(l){if(!Ff(l))return[];const d=Jp(l),h=this._ownAnnotations(l,d)||[];return(d!==Object?this.annotations(d):[]).concat(h)}_ownPropMetadata(l,d){if(l.propMetadata&&l.propMetadata!==d.propMetadata){let h=l.propMetadata;return"function"==typeof h&&h.propMetadata&&(h=h.propMetadata),h}if(l.propDecorators&&l.propDecorators!==d.propDecorators){const h=l.propDecorators,w={};return Object.keys(h).forEach(L=>{w[L]=Nf(h[L])}),w}return l.hasOwnProperty(Ge)?l[Ge]:null}propMetadata(l){if(!Ff(l))return{};const d=Jp(l),h={};if(d!==Object){const L=this.propMetadata(d);Object.keys(L).forEach(z=>{h[z]=L[z]})}const w=this._ownPropMetadata(l,d);return w&&Object.keys(w).forEach(L=>{const z=[];h.hasOwnProperty(L)&&z.push(...h[L]),z.push(...w[L]),h[L]=z}),h}ownPropMetadata(l){return Ff(l)&&this._ownPropMetadata(l,Jp(l))||{}}hasLifecycleHook(l,d){return l instanceof H_&&d in l.prototype}}function Nf(s){return s?s.map(l=>new(0,l.type.annotationCls)(...l.args?l.args:[])):[]}function Jp(s){const l=s.prototype?Object.getPrototypeOf(s.prototype):null;return(l?l.constructor:null)||Object}const Cc=0,io=1,Ps=2,fc=3,Xl=4,nc=5,ra=6,Rf=7,Ja=8,Jc=9,sd=10,Ss=11,ps=12,eh=13,Eh=14,Gl=15,zu=16,Bd=17,th=18,V=19,Qe=20,E=21,U=22,ee=23,Xe=25,Nt=1,Ei=6,gr=7,vo=9,Gr=10;var jo=function(s){return s[s.None=0]="None",s[s.HasTransplantedViews=2]="HasTransplantedViews",s}(jo||{});function cs(s){return Array.isArray(s)&&"object"==typeof s[Nt]}function el(s){return Array.isArray(s)&&!0===s[Nt]}function gu(s){return!!(4&s.flags)}function Zl(s){return s.componentOffset>-1}function Ga(s){return!(1&~s.flags)}function qa(s){return!!s.template}function Th(s){return!!(512&s[Ps])}function Pm(s){return!(16&~s.type)}function ih(s){return!(256&~s[Ps])}class ei{constructor(l,d,h){this.previousValue=l,this.currentValue=d,this.firstChange=h}isFirstChange(){return this.firstChange}}function yi(s,l,d,h){null!==l?l.applyValueToInputSignal(l,h):s[d]=h}function Vi(){return tr}function tr(s){return s.type.prototype.ngOnChanges&&(s.setInput=Yo),Wr}function Wr(){const s=pc(this),l=s?.current;if(l){const d=s.previous;if(d===ls)s.previous=l;else for(let h in l)d[h]=l[h];s.current=null,this.ngOnChanges(l)}}function Yo(s,l,d,h,w){const L=this.declaredInputs[h],z=pc(s)||function Yu(s,l){return s[Cl]=l}(s,{previous:ls,current:null}),ae=z.current||(z.current={}),xe=z.previous,qe=xe[L];ae[L]=new ei(qe&&qe.currentValue,d,xe===ls),yi(s,l,w,d)}Vi.ngInherit=!0;const Cl="__ngSimpleChanges__";function pc(s){return s[Cl]||null}const vu=function(s,l,d){},rh="svg",Xf="math";function Qa(s){for(;Array.isArray(s);)s=s[Cc];return s}function Ov(s){for(;Array.isArray(s);){if("object"==typeof s[Nt])return s;s=s[Cc]}return null}function Tr(s,l){return Qa(l[s])}function Vs(s,l){return Qa(l[s.index])}function ka(s,l){return s.data[l]}function Lf(s,l){return s[l]}function tf(s,l){const d=l[s];return cs(d)?d:d[Cc]}function G_(s){return!(128&~s[Ps])}function vf(s,l){return null==l?null:s[l]}function xg(s){s[Bd]=0}function s1(s){1024&s[Ps]||(s[Ps]|=1024,G_(s)&&Ko(s))}function Bm(s,l){for(;s>0;)l=l[Eh],s--;return l}function Ir(s){return!!(9216&s[Ps]||s[ee]?.dirty)}function bs(s){s[sd].changeDetectionScheduler?.notify(8),64&s[Ps]&&(s[Ps]|=1024),Ir(s)&&Ko(s)}function Ko(s){s[sd].changeDetectionScheduler?.notify(0);let l=wc(s);for(;null!==l&&!(8192&l[Ps])&&(l[Ps]|=8192,G_(l));)l=wc(l)}function Es(s,l){if(!(256&~s[Ps]))throw new po(911,!1);null===s[E]&&(s[E]=[]),s[E].push(l)}function jc(s,l){if(null===s[E])return;const d=s[E].indexOf(l);-1!==d&&s[E].splice(d,1)}function wc(s){const l=s[fc];return el(l)?l[fc]:l}const Ho={lFrame:fD(null),bindingsEnabled:!0,skipHydrationRootTNode:null};let E0=!1;function cx(){return Ho.bindingsEnabled}function Sg(){return null!==Ho.skipHydrationRootTNode}function ux(){Ho.bindingsEnabled=!0}function _E(){Ho.bindingsEnabled=!1}function mr(){return Ho.lFrame.lView}function Ua(){return Ho.lFrame.tView}function Op(s){return Ho.lFrame.contextLView=s,s[Ja]}function oD(s){return Ho.lFrame.contextLView=null,s}function Pl(){let s=dx();for(;null!==s&&64===s.type;)s=s.parent;return s}function dx(){return Ho.lFrame.currentTNode}function fa(){const s=Ho.lFrame,l=s.currentTNode;return s.isParent?l:l.parent}function Ih(s,l){const d=Ho.lFrame;d.currentTNode=s,d.isParent=l}function sD(){return Ho.lFrame.isParent}function aD(){Ho.lFrame.isParent=!1}function a1(){return Ho.lFrame.contextLView}function fx(){return E0}function bE(s){E0=s}function nf(){const s=Ho.lFrame;let l=s.bindingRootIndex;return-1===l&&(l=s.bindingRootIndex=s.tView.bindingStartIndex),l}function _f(){return Ho.lFrame.bindingIndex}function lD(s){return Ho.lFrame.bindingIndex=s}function Fp(){return Ho.lFrame.bindingIndex++}function Eg(s){const l=Ho.lFrame,d=l.bindingIndex;return l.bindingIndex=l.bindingIndex+s,d}function uD(s){Ho.lFrame.inI18n=s}function CE(s,l){const d=Ho.lFrame;d.bindingIndex=d.bindingRootIndex=s,Fv(l)}function Fv(s){Ho.lFrame.currentDirectiveIndex=s}function dD(s){const l=Ho.lFrame.currentDirectiveIndex;return-1===l?null:s[l]}function Ah(){return Ho.lFrame.currentQueryIndex}function K_(s){Ho.lFrame.currentQueryIndex=s}function q_(s){const l=s[io];return 2===l.type?l.declTNode:1===l.type?s[nc]:null}function hx(s,l,d){if(d&As.SkipSelf){let w=l,L=s;for(;!(w=w.parent,null!==w||d&As.Host||(w=q_(L),null===w||(L=L[Eh],10&w.type))););if(null===w)return!1;l=w,s=L}const h=Ho.lFrame=l1();return h.currentTNode=l,h.lView=s,!0}function Vm(s){const l=l1(),d=s[io];Ho.lFrame=l,l.currentTNode=d.firstChild,l.lView=s,l.tView=d,l.contextLView=s,l.bindingIndex=d.bindingStartIndex,l.inI18n=!1}function l1(){const s=Ho.lFrame,l=null===s?null:s.child;return null===l?fD(s):l}function fD(s){const l={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:s,child:null,inI18n:!1};return null!==s&&(s.child=l),l}function mx(){const s=Ho.lFrame;return Ho.lFrame=s.parent,s.currentTNode=null,s.lView=null,s}const Tg=mx;function Mg(){const s=mx();s.isParent=!0,s.tView=null,s.selectedIndex=-1,s.contextLView=null,s.elementDepthCount=0,s.currentDirectiveIndex=-1,s.currentNamespace=null,s.bindingRootIndex=-1,s.bindingIndex=-1,s.currentQueryIndex=0}function Vd(){return Ho.lFrame.selectedIndex}function Ig(s){Ho.lFrame.selectedIndex=s}function Au(){const s=Ho.lFrame;return ka(s.tView,s.selectedIndex)}function A0(){Ho.lFrame.currentNamespace=rh}function Zf(){Ho.lFrame.currentNamespace=Xf}function pD(){!function Nv(){Ho.lFrame.currentNamespace=null}()}function c1(){return Ho.lFrame.currentNamespace}let gx=!0;function Rv(){return gx}function jm(s){gx=s}function hD(s,l){for(let d=l.directiveStart,h=l.directiveEnd;d<h;d++){const L=s.data[d].type.prototype,{ngAfterContentInit:z,ngAfterContentChecked:ae,ngAfterViewInit:xe,ngAfterViewChecked:qe,ngOnDestroy:ft}=L;z&&(s.contentHooks??=[]).push(-d,z),ae&&((s.contentHooks??=[]).push(d,ae),(s.contentCheckHooks??=[]).push(d,ae)),xe&&(s.viewHooks??=[]).push(-d,xe),qe&&((s.viewHooks??=[]).push(d,qe),(s.viewCheckHooks??=[]).push(d,qe)),null!=ft&&(s.destroyHooks??=[]).push(d,ft)}}function Q_(s,l,d){Np(s,l,3,d)}function d1(s,l,d,h){(3&s[Ps])===d&&Np(s,l,d,h)}function Lv(s,l){let d=s[Ps];(3&d)===l&&(d&=16383,d+=1,s[Ps]=d)}function Np(s,l,d,h){const L=h??-1,z=l.length-1;let ae=0;for(let xe=void 0!==h?65535&s[Bd]:0;xe<z;xe++)if("number"==typeof l[xe+1]){if(ae=l[xe],null!=h&&ae>=h)break}else l[xe]<0&&(s[Bd]+=65536),(ae<L||-1==L)&&(wE(s,d,l,xe),s[Bd]=(4294901760&s[Bd])+xe+2),xe++}function Y_(s,l){vu(4,s,l);const d=Q(null);try{l.call(s)}finally{Q(d),vu(5,s,l)}}function wE(s,l,d,h){const w=d[h]<0,L=d[h+1],ae=s[w?-d[h]:d[h]];w?s[Ps]>>14<s[Bd]>>16&&(3&s[Ps])===l&&(s[Ps]+=16384,Y_(ae,L)):Y_(ae,L)}const kv=-1;class O0{constructor(l,d,h){this.factory=l,this.resolving=!1,this.canSeeViewProviders=d,this.injectImpl=h}}function _u(s){return null!=s&&"object"==typeof s&&(null===s.insertBeforeIndex||"number"==typeof s.insertBeforeIndex||Array.isArray(s.insertBeforeIndex))}function Um(s){return!!(128&s.type)}const nm={};class X_{constructor(l,d){this.injector=l,this.parentInjector=d}get(l,d,h){h=ia(h);const w=this.injector.get(l,nm,h);return w!==nm||d===nm?w:this.parentInjector.get(l,d,h)}}function $m(s){return s!==kv}function im(s){return 32767&s}function Oh(s,l){let d=function xE(s){return s>>16}(s),h=l;for(;d>0;)h=h[Eh],d--;return h}let R0=!0;function vD(s){const l=R0;return R0=s,l}const _x=255,yx=5;let p1=0;const Fh={};function Pv(s,l){const d=Ag(s,l);if(-1!==d)return d;const h=l[io];h.firstCreatePass&&(s.injectorIndex=l.length,Z_(h.data,s),Z_(l,null),Z_(h.blueprint,null));const w=Og(s,l),L=s.injectorIndex;if($m(w)){const z=im(w),ae=Oh(w,l),xe=ae[io].data;for(let qe=0;qe<8;qe++)l[L+qe]=ae[z+qe]|xe[z+qe]}return l[L+8]=w,L}function Z_(s,l){s.push(0,0,0,0,0,0,0,0,l)}function Ag(s,l){return-1===s.injectorIndex||s.parent&&s.parent.injectorIndex===s.injectorIndex||null===l[s.injectorIndex+8]?-1:s.injectorIndex}function Og(s,l){if(s.parent&&-1!==s.parent.injectorIndex)return s.parent.injectorIndex;let d=0,h=null,w=l;for(;null!==w;){if(h=J_(w),null===h)return kv;if(d++,w=w[Eh],-1!==h.injectorIndex)return h.injectorIndex|d<<16}return kv}function ah(s,l,d){!function bx(s,l,d){let h;"string"==typeof d?h=d.charCodeAt(0)||0:d.hasOwnProperty(Bu)&&(h=d[Bu]),null==h&&(h=d[Bu]=p1++);const w=h&_x;l.data[s+(w>>yx)]|=1<<w}(s,l,d)}function rm(s,l,d){if(d&As.Optional||void 0!==s)return s;hu()}function om(s,l,d,h){if(d&As.Optional&&void 0===h&&(h=null),!(d&(As.Self|As.Host))){const w=s[Jc],L=El(void 0);try{return w?w.get(l,h,d&As.Optional):uc(l,h,d&As.Optional)}finally{El(L)}}return rm(h,0,d)}function k0(s,l,d,h=As.Default,w){if(null!==s){if(2048&l[Ps]&&!(h&As.Self)){const z=function Id(s,l,d,h,w){let L=s,z=l;for(;null!==L&&null!==z&&2048&z[Ps]&&!(512&z[Ps]);){const ae=yD(L,z,d,h|As.Self,Fh);if(ae!==Fh)return ae;let xe=L.parent;if(!xe){const qe=z[Qe];if(qe){const ft=qe.get(d,Fh,h);if(ft!==Fh)return ft}xe=J_(z),z=z[Eh]}L=xe}return w}(s,l,d,h,Fh);if(z!==Fh)return z}const L=yD(s,l,d,h,Fh);if(L!==Fh)return L}return om(l,d,h,w)}function yD(s,l,d,h,w){const L=function Dx(s){if("string"==typeof s)return s.charCodeAt(0)||0;const l=s.hasOwnProperty(Bu)?s[Bu]:void 0;return"number"==typeof l?l>=0?l&_x:bD:l}(d);if("function"==typeof L){if(!hx(l,s,h))return h&As.Host?rm(w,0,h):om(l,d,h,w);try{let z;if(z=L(h),null!=z||h&As.Optional)return z;hu()}finally{Tg()}}else if("number"==typeof L){let z=null,ae=Ag(s,l),xe=kv,qe=h&As.Host?l[Gl][nc]:null;for((-1===ae||h&As.SkipSelf)&&(xe=-1===ae?Og(s,l):l[ae+8],xe!==kv&&Bv(h,!1)?(z=l[io],ae=im(xe),l=Oh(xe,l)):ae=-1);-1!==ae;){const ft=l[io];if(wx(L,ae,ft.data)){const Xt=Cx(ae,l,d,z,h,qe);if(Xt!==Fh)return Xt}xe=l[ae+8],xe!==kv&&Bv(h,l[io].data[ae+8]===qe)&&wx(L,ae,l)?(z=ft,ae=im(xe),l=Oh(xe,l)):ae=-1}}return w}function Cx(s,l,d,h,w,L){const z=l[io],ae=z.data[s+8],ft=Jf(ae,z,d,null==h?Zl(ae)&&R0:h!=z&&!!(3&ae.type),w&As.Host&&L===ae);return null!==ft?ic(l,z,ft,ae):Fh}function Jf(s,l,d,h,w){const L=s.providerIndexes,z=l.data,ae=1048575&L,xe=s.directiveStart,ft=L>>20,Ln=w?ae+ft:s.directiveEnd;for(let zn=h?ae:ae+ft;zn<Ln;zn++){const xi=z[zn];if(zn<xe&&d===xi||zn>=xe&&xi.type===d)return zn}if(w){const zn=z[xe];if(zn&&qa(zn)&&zn.type===d)return xe}return null}function ic(s,l,d,h){let w=s[d];const L=l.data;if(function F0(s){return s instanceof O0}(w)){const z=w;z.resolving&&function id(s,l){throw l&&l.join(" > "),new po(-200,s)}(xa(L[d]));const ae=vD(z.canSeeViewProviders);z.resolving=!0;const qe=z.injectImpl?El(z.injectImpl):null;hx(s,h,As.Default);try{w=s[d]=z.factory(void 0,L,s,h),l.firstCreatePass&&d>=h.directiveStart&&function u1(s,l,d){const{ngOnChanges:h,ngOnInit:w,ngDoCheck:L}=l.type.prototype;if(h){const z=tr(l);(d.preOrderHooks??=[]).push(s,z),(d.preOrderCheckHooks??=[]).push(s,z)}w&&(d.preOrderHooks??=[]).push(0-s,w),L&&((d.preOrderHooks??=[]).push(s,L),(d.preOrderCheckHooks??=[]).push(s,L))}(d,L[d],l)}finally{null!==qe&&El(qe),vD(ae),z.resolving=!1,Tg()}}return w}function wx(s,l,d){return!!(d[l+(s>>yx)]&1<<s)}function Bv(s,l){return!(s&As.Self||s&As.Host&&l)}class ad{constructor(l,d){this._tNode=l,this._lView=d}get(l,d,h){return k0(this._tNode,this._lView,l,ia(h),d)}}function bD(){return new ad(Pl(),mr())}function xx(s){return Ke(()=>{const l=s.prototype.constructor,d=l[Xc]||Ng(l),h=Object.prototype;let w=Object.getPrototypeOf(s.prototype).constructor;for(;w&&w!==h;){const L=w[Xc]||Ng(w);if(L&&L!==d)return L;w=Object.getPrototypeOf(w)}return L=>new L})}function Ng(s){return is(s)?()=>{const l=Ng(Vr(s));return l&&l()}:Pe(s)}function J_(s){const l=s[io],d=l.type;return 2===d?l.declTNode:1===d?s[nc]:null}function up(s){return function L0(s,l){if("class"===l)return s.classes;if("style"===l)return s.styles;const d=s.attrs;if(d){const h=d.length;let w=0;for(;w<h;){const L=d[w];if(au(L))break;if(0===L)w+=2;else if("number"==typeof L)for(w++;w<h&&"string"==typeof d[w];)w++;else{if(L===l)return d[w+1];w+=2}}}return null}(Pl(),s)}const ey=kn("Attribute",s=>({attributeName:s,__NG_ELEMENT_ID__:()=>up(s)}));let h1=null;function Sx(){return h1=h1||new km}function P0(s){return kf(Sx().parameters(s))}function kf(s){return s.map(l=>function Ex(s){const l={token:null,attribute:null,host:!1,optional:!1,self:!1,skipSelf:!1};if(Array.isArray(s)&&s.length>0)for(let d=0;d<s.length;d++){const h=s[d];if(void 0===h)continue;const w=Object.getPrototypeOf(h);if(h instanceof Mc||"Optional"===w.ngMetadataName)l.optional=!0;else if(h instanceof Ue||"SkipSelf"===w.ngMetadataName)l.skipSelf=!0;else if(h instanceof yc||"Self"===w.ngMetadataName)l.self=!0;else if(h instanceof ne||"Host"===w.ngMetadataName)l.host=!0;else if(h instanceof $o)l.token=h.token;else if(h instanceof ey){if(void 0===h.attributeName)throw new po(204,!1);l.attribute=h.attributeName}else l.token=h}else l.token=void 0===s||Array.isArray(s)&&0===s.length?null:s;return l}(l))}const B0=$i({provide:String,useValue:$i});function Tx(s){return void 0!==s.useClass}function ty(s){return void 0!==s.useFactory}const hl=xt("Injectable",void 0,void 0,void 0,(s,l)=>function jv(s,l){let d=null,h=null;s.hasOwnProperty(bl)||Object.defineProperty(s,bl,{get:()=>(null===d&&(d=mu().compileInjectable(Zh,`ng:///${s.name}/\u0275prov.js`,function dp(s,l){const d=l||{providedIn:null},h={name:s.name,type:s,typeArgumentCount:0,providedIn:d.providedIn};return(Tx(d)||ty(d))&&void 0!==d.deps&&(h.deps=kf(d.deps)),Tx(d)?h.useClass=d.useClass:function SA(s){return B0 in s}(d)?h.useValue=d.useValue:ty(d)?h.useFactory=d.useFactory:function wM(s){return void 0!==s.useExisting}(d)&&(h.useExisting=d.useExisting),h}(s,l))),d)}),s.hasOwnProperty(Xc)||Object.defineProperty(s,Xc,{get:()=>{if(null===h){const w=mu();h=w.compileFactory(Zh,`ng:///${s.name}/\u0275fac.js`,{name:s.name,type:s,typeArgumentCount:0,deps:P0(s),target:w.FactoryTarget.Injectable})}return h},configurable:!0})}(s,l));function lh(s,l=null,d=null,h){const w=Nh(s,l,d,h);return w.resolveInjectorInitializers(),w}function Nh(s,l=null,d=null,h,w=new Set){const L=[d||Zo,Bs(s)];return h=h||("object"==typeof s?void 0:ai(s)),new gf(L,l||ns(),h||null,w)}class Ou{static#e=this.THROW_IF_NOT_FOUND=Pc;static#t=this.NULL=new Vc;static create(l,d){if(Array.isArray(l))return lh({name:""},d,l,"");{const h=l.name??"";return lh({name:h},l.parent,l.providers,h)}}static#n=this.\u0275prov=Ks({token:Ou,providedIn:"any",factory:()=>gi(dc)});static#i=this.__NG_ELEMENT_ID__=-1}class CD{constructor(l){this.attributeName=l,this.__NG_ELEMENT_ID__=()=>up(this.attributeName)}toString(){return`HostAttributeToken ${this.attributeName}`}}const Rg=new aa("");Rg.__NG_ELEMENT_ID__=s=>{const l=Pl();if(null===l)throw new po(204,!1);if(2&l.type)return l.value;if(s&As.Optional)return null;throw new po(204,!1)};function Lg(s){return s.ngOriginalError}const V0=!0;let ny=(()=>{class s{static#e=this.__NG_ELEMENT_ID__=g1;static#t=this.__NG_ENV_ID__=d=>d}return s})();class iy extends ny{constructor(l){super(),this._lView=l}onDestroy(l){return Es(this._lView,l),()=>jc(this._lView,l)}}function g1(){return new iy(mr())}let sm=(()=>{class s{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new Ai.BehaviorSubject(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const d=this.taskId++;return this.pendingTasks.add(d),d}remove(d){this.pendingTasks.delete(d),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new s})}return s})(),Wm=(()=>{class s{constructor(){this.internalPendingTasks=or(sm)}add(){const d=this.internalPendingTasks.add();return()=>this.internalPendingTasks.remove(d)}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new s})}return s})();const Rp=class Uv extends Ai.Subject{constructor(l=!1){super(),this.destroyRef=void 0,this.pendingTasks=void 0,this.__isAsync=l,Xh()&&(this.destroyRef=or(ny,{optional:!0})??void 0,this.pendingTasks=or(sm,{optional:!0})??void 0)}emit(l){const d=Q(null);try{super.next(l)}finally{Q(d)}}subscribe(l,d,h){let w=l,L=d||(()=>null),z=h;if(l&&"object"==typeof l){const xe=l;w=xe.next?.bind(xe),L=xe.error?.bind(xe),z=xe.complete?.bind(xe)}this.__isAsync&&(L=this.wrapInTimeout(L),w&&(w=this.wrapInTimeout(w)),z&&(z=this.wrapInTimeout(z)));const ae=super.subscribe({next:w,error:L,complete:z});return l instanceof Ai.Subscription&&l.add(ae),ae}wrapInTimeout(l){return d=>{const h=this.pendingTasks?.add();setTimeout(()=>{l(d),void 0!==h&&this.pendingTasks?.remove(h)})}}};function Ad(...s){}function ry(s){let l,d;function h(){s=Ad;try{void 0!==d&&"function"==typeof cancelAnimationFrame&&cancelAnimationFrame(d),void 0!==l&&clearTimeout(l)}catch{}}return l=setTimeout(()=>{s(),h()}),"function"==typeof requestAnimationFrame&&(d=requestAnimationFrame(()=>{s(),h()})),()=>h()}function xD(s){return queueMicrotask(()=>s()),()=>{s=Ad}}const Rh="isAngularZone",Lp=Rh+"_ID";let yf=0;class Uc{constructor(l){this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Rp(!1),this.onMicrotaskEmpty=new Rp(!1),this.onStable=new Rp(!1),this.onError=new Rp(!1);const{enableLongStackTrace:d=!1,shouldCoalesceEventChangeDetection:h=!1,shouldCoalesceRunChangeDetection:w=!1,scheduleInRootZone:L=V0}=l;if(typeof Zone>"u")throw new po(908,!1);Zone.assertZonePatched();const z=this;z._nesting=0,z._outer=z._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(z._inner=z._inner.fork(new Zone.TaskTrackingZoneSpec)),d&&Zone.longStackTraceZoneSpec&&(z._inner=z._inner.fork(Zone.longStackTraceZoneSpec)),z.shouldCoalesceEventChangeDetection=!w&&h,z.shouldCoalesceRunChangeDetection=w,z.callbackScheduled=!1,z.scheduleInRootZone=L,function v1(s){const l=()=>{!function SE(s){function l(){ry(()=>{s.callbackScheduled=!1,_1(s),s.isCheckStableRunning=!0,oy(s),s.isCheckStableRunning=!1})}s.isCheckStableRunning||s.callbackScheduled||(s.callbackScheduled=!0,s.scheduleInRootZone?Zone.root.run(()=>{l()}):s._outer.run(()=>{l()}),_1(s))}(s)},d=yf++;s._inner=s._inner.fork({name:"angular",properties:{[Rh]:!0,[Lp]:d,[Lp+d]:!0},onInvokeTask:(h,w,L,z,ae,xe)=>{if(function Ax(s){return U0(s,"__ignore_ng_zone__")}(xe))return h.invokeTask(L,z,ae,xe);try{return Mx(s),h.invokeTask(L,z,ae,xe)}finally{(s.shouldCoalesceEventChangeDetection&&"eventTask"===z.type||s.shouldCoalesceRunChangeDetection)&&l(),Ix(s)}},onInvoke:(h,w,L,z,ae,xe,qe)=>{try{return Mx(s),h.invoke(L,z,ae,xe,qe)}finally{s.shouldCoalesceRunChangeDetection&&!s.callbackScheduled&&!function Ox(s){return U0(s,"__scheduler_tick__")}(xe)&&l(),Ix(s)}},onHasTask:(h,w,L,z)=>{h.hasTask(L,z),w===L&&("microTask"==z.change?(s._hasPendingMicrotasks=z.microTask,_1(s),oy(s)):"macroTask"==z.change&&(s.hasPendingMacrotasks=z.macroTask))},onHandleError:(h,w,L,z)=>(h.handleError(L,z),s.runOutsideAngular(()=>s.onError.emit(z)),!1)})}(z)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get(Rh)}static assertInAngularZone(){if(!Uc.isInAngularZone())throw new po(909,!1)}static assertNotInAngularZone(){if(Uc.isInAngularZone())throw new po(909,!1)}run(l,d,h){return this._inner.run(l,d,h)}runTask(l,d,h,w){const L=this._inner,z=L.scheduleEventTask("NgZoneEvent: "+w,l,am,Ad,Ad);try{return L.runTask(z,d,h)}finally{L.cancelTask(z)}}runGuarded(l,d,h){return this._inner.runGuarded(l,d,h)}runOutsideAngular(l){return this._outer.run(l)}}const am={};function oy(s){if(0==s._nesting&&!s.hasPendingMicrotasks&&!s.isStable)try{s._nesting++,s.onMicrotaskEmpty.emit(null)}finally{if(s._nesting--,!s.hasPendingMicrotasks)try{s.runOutsideAngular(()=>s.onStable.emit(null))}finally{s.isStable=!0}}}function _1(s){s.hasPendingMicrotasks=!!(s._hasPendingMicrotasks||(s.shouldCoalesceEventChangeDetection||s.shouldCoalesceRunChangeDetection)&&!0===s.callbackScheduled)}function Mx(s){s._nesting++,s.isStable&&(s.isStable=!1,s.onUnstable.emit(null))}function Ix(s){s._nesting--,oy(s)}class $v{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new Rp,this.onMicrotaskEmpty=new Rp,this.onStable=new Rp,this.onError=new Rp}run(l,d,h){return l.apply(d,h)}runGuarded(l,d,h){return l.apply(d,h)}runOutsideAngular(l){return l()}runTask(l,d,h,w){return l.apply(d,h)}}function U0(s,l){return!(!Array.isArray(s)||1!==s.length)&&!0===s[0]?.data?.[l]}class Lh{constructor(){this._console=console}handleError(l){const d=this._findOriginalError(l);this._console.error("ERROR",l),d&&this._console.error("ORIGINAL ERROR",d)}_findOriginalError(l){let d=l&&Lg(l);for(;d&&Lg(d);)d=Lg(d);return d||null}}const EE=new aa("",{providedIn:"root",factory:()=>{const s=or(Uc),l=or(Lh);return d=>s.runOutsideAngular(()=>l.handleError(d))}});class b1{constructor(){this.destroyed=!1,this.listeners=null,this.errorHandler=or(Lh,{optional:!0}),this.destroyRef=or(ny),this.destroyRef.onDestroy(()=>{this.destroyed=!0,this.listeners=null})}subscribe(l){if(this.destroyed)throw new po(953,!1);return(this.listeners??=[]).push(l),{unsubscribe:()=>{const d=this.listeners?.indexOf(l);void 0!==d&&-1!==d&&this.listeners?.splice(d,1)}}}emit(l){if(this.destroyed)throw new po(953,!1);if(null===this.listeners)return;const d=Q(null);try{for(const h of this.listeners)try{h(l)}catch(w){this.errorHandler?.handleError(w)}}finally{Q(d)}}}function TE(s){return s.destroyRef}function SD(s){return new b1}function C1(s,l){return Rc(s,l)}const $0=(C1.required=function Fx(s){return Rc(Hs,s)},C1);function Wv(){return Hv(Pl(),mr())}function Hv(s,l){return new Hm(Vs(s,l))}let Hm=(()=>{class s{constructor(d){this.nativeElement=d}static#e=this.__NG_ELEMENT_ID__=Wv}return s})();function Nx(s){return s instanceof Hm?s.nativeElement:s}function ME(){return this._results[Symbol.iterator]()}class lm{static#e=Symbol.iterator;get changes(){return this._changes??=new Rp}constructor(l=!1){this._emitDistinctChangesOnly=l,this.dirty=!0,this._onDirty=void 0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const d=lm.prototype;d[Symbol.iterator]||(d[Symbol.iterator]=ME)}get(l){return this._results[l]}map(l){return this._results.map(l)}filter(l){return this._results.filter(l)}find(l){return this._results.find(l)}reduce(l,d){return this._results.reduce(l,d)}forEach(l){this._results.forEach(l)}some(l){return this._results.some(l)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(l,d){this.dirty=!1;const h=Ut(l);(this._changesDetected=!function rt(s,l,d){if(s.length!==l.length)return!1;for(let h=0;h<s.length;h++){let w=s[h],L=l[h];if(d&&(w=d(w),L=d(L)),L!==w)return!1}return!0}(this._results,h,d))&&(this._results=h,this.length=h.length,this.last=h[this.length-1],this.first=h[0])}notifyOnChanges(){void 0!==this._changes&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.emit(this)}onDirty(l){this._onDirty=l}setDirty(){this.dirty=!0,this._onDirty?.()}destroy(){void 0!==this._changes&&(this._changes.complete(),this._changes.unsubscribe())}}const W0="ngSkipHydration",Rx="ngskiphydration";function H0(s){const l=s.mergedAttrs;if(null===l)return!1;for(let d=0;d<l.length;d+=2){const h=l[d];if("number"==typeof h)return!1;if("string"==typeof h&&h.toLowerCase()===Rx)return!0}return!1}function ED(s){return s.hasAttribute(W0)}function z0(s){return!(128&~s.flags)}function kg(s){if(z0(s))return!0;let l=s.parent;for(;l;){if(z0(s)||H0(l))return!0;l=l.parent}return!1}function Lx(s){return z0(s)||H0(s)||kg(s)}const kx=new Map;let TD=0;function G0(s){return kx.get(s)||null}function K0(s){kx.delete(s[V])}class ID{get lView(){return G0(this.lViewId)}constructor(l,d,h){this.lViewId=l,this.nodeIndex=d,this.native=h}}function Cd(s){let l=Gv(s);if(l){if(cs(l)){const d=l;let h,w,L;if(D1(s)){if(h=function Bx(s,l){const d=s[io].components;if(d)for(let h=0;h<d.length;h++){const w=d[h];if(tf(w,s)[Ja]===l)return w}else if(tf(Xe,s)[Ja]===l)return Xe;return-1}(d,s),-1==h)throw new Error("The provided component was not found in the application");w=s}else if(function Px(s){return s&&s.constructor&&s.constructor.\u0275dir}(s)){if(h=function EM(s,l){let d=s[io].firstChild;for(;d;){const w=d.directiveEnd;for(let L=d.directiveStart;L<w;L++)if(s[L]===l)return d.index;d=w1(d)}return-1}(d,s),-1==h)throw new Error("The provided directive was not found in the application");L=Kv(h,d)}else if(h=OE(d,s),-1==h)return null;const z=Qa(d[h]),ae=Gv(z),xe=ae&&!Array.isArray(ae)?ae:cm(d,h,z);if(w&&void 0===xe.component&&(xe.component=w,rf(xe.component,xe)),L&&void 0===xe.directives){xe.directives=L;for(let qe=0;qe<L.length;qe++)rf(L[qe],xe)}rf(xe.native,xe),l=xe}}else{const d=s;let h=d;for(;h=h.parentNode;){const w=Gv(h);if(w){const L=Array.isArray(w)?w:w.lView;if(!L)return null;const z=OE(L,d);if(z>=0){const ae=Qa(L[z]),xe=cm(L,z,ae);rf(ae,xe),l=xe;break}}}}return l||null}function cm(s,l,d){return new ID(s[V],l,d)}const zv="__ngContext__";function rf(s,l){cs(l)?(s[zv]=l[V],function xM(s){kx.set(s[V],s)}(l)):s[zv]=l}function Gv(s){const l=s[zv];return"number"==typeof l?G0(l):l||null}function D1(s){return s&&s.constructor&&s.constructor.\u0275cmp}function OE(s,l){const d=s[io];for(let h=Xe;h<d.bindingStartIndex;h++)if(Qa(s[h])===l)return h;return-1}function w1(s){if(s.child)return s.child;if(s.next)return s.next;for(;s.parent&&!s.parent.next;)s=s.parent;return s.parent&&s.parent.next}function Kv(s,l){const d=l[io].data[s];if(0===d.directiveStart)return Zo;const h=[];for(let w=d.directiveStart;w<d.directiveEnd;w++){const L=l[w];D1(L)||h.push(L)}return h}function sy(s){return q0(s[ps])}function x1(s){return q0(s[Xl])}function q0(s){for(;null!==s&&!el(s);)s=s[Xl];return s}function qv(s){const l=Cd(s);if(null===l)return null;if(void 0===l.component){const d=l.lView;if(null===d)return null;l.component=function OD(s,l){const d=l[io].data[s],{directiveStart:h,componentOffset:w}=d;return w>-1?l[h+w]:null}(l.nodeIndex,d)}return l.component}function RE(s){if(s instanceof Text)return[];const l=Cd(s),d=l?l.lView:null;if(null===d)return[];const h=d[io],w=l.nodeIndex;return h?.data[w]?(void 0===l.directives&&(l.directives=Kv(w,d)),null===l.directives?[]:[...l.directives]):[]}function E1(s){return Cd(s).native}function kE(s,l){return s.name==l.name?0:s.name<l.name?-1:1}function M1(s){return void 0!==s.type&&void 0!==s.declaredInputs&&void 0!==s.findHostDirectiveDefs}let I1;function EA(s){I1=s}function fp(){if(void 0!==I1)return I1;if(typeof document<"u")return document;throw new po(210,!1)}const X0=new aa("",{providedIn:"root",factory:()=>Ux}),Ux="ng",Qv=new aa(""),Yv=new aa("",{providedIn:"platform",factory:()=>"unknown"}),IM=new aa(""),ay=new aa(""),BE=new aa("",{providedIn:"root",factory:()=>fp().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null}),RD={breakpoints:[16,32,48,64,96,128,256,384,640,750,828,1080,1200,1920,2048,3840],placeholderResolution:30,disableImageSizeWarning:!1,disableImageLazyLoadWarning:!1},Z0=new aa("",{providedIn:"root",factory:()=>RD});function VE(s){return s}function $x(){const s=new zm;return"browser"===or(Yv)&&(s.store=function Xv(s,l){const d=s.getElementById(l+"-state");if(d?.textContent)try{return JSON.parse(d.textContent)}catch(h){console.warn("Exception while restoring TransferState for app "+l,h)}return{}}(fp(),or(X0))),s}let zm=(()=>{class s{constructor(){this.store={},this.onSerializeCallbacks={}}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:$x});get(d,h){return void 0!==this.store[d]?this.store[d]:h}set(d,h){this.store[d]=h}remove(d){delete this.store[d]}hasKey(d){return this.store.hasOwnProperty(d)}get isEmpty(){return 0===Object.keys(this.store).length}onSerialize(d,h){this.onSerializeCallbacks[d]=h}toJson(){for(const d in this.onSerializeCallbacks)if(this.onSerializeCallbacks.hasOwnProperty(d))try{this.store[d]=this.onSerializeCallbacks[d]()}catch(h){console.warn("Exception in onSerialize callback: ",h)}return JSON.stringify(this.store).replace(/</g,"\\u003C")}}return s})();const LD="h",Zv="b";var Bg=function(s){return s.FirstChild="f",s.NextSibling="n",s}(Bg||{});const kD="e",Vg="t",ly="c",A1="x",jg="r",O1="i",Wx="n",Ug="d",F1="l",$g="__nghData__",ep="ngh",um="nghm";let jd=()=>null;function Hx(s,l,d=!1){let h=s.getAttribute(ep);if(null==h)return null;const[w,L]=h.split("|");if(h=d?L:w,!h)return null;const ae=d?w:L?`|${L}`:"";let xe={};if(""!==h){const ft=l.get(zm,null,{optional:!0});null!==ft&&(xe=ft.get($g,[])[Number(h)])}const qe={data:xe,firstChild:s.firstChild??null};return d&&(qe.firstChild=s,np(qe,0,s.nextSibling)),ae?s.setAttribute(ep,ae):s.removeAttribute(ep),qe}function pp(s,l,d=!1){return jd(s,l,d)}function J0(s){let l=s._lView;return 2===l[io].type?null:(Th(l)&&(l=l[Xe]),l)}const uy="__ngDebugHydrationInfo__";function _a(s){return s[uy]??null}function np(s,l,d){s.segmentHeads??={},s.segmentHeads[l]=d}function dm(s,l){return s.segmentHeads?.[l]??null}function PD(s,l){const d=s.data;let h=d[kD]?.[l]??null;return null===h&&d[ly]?.[l]&&(h=Jv(s,l)),h}function eu(s,l){return s.data[ly]?.[l]??null}function Jv(s,l){const d=eu(s,l)??[];let h=0;for(let w of d)h+=w[jg]*(w[A1]??1);return h}function Xu(s){if(typeof s.disconnectedNodes>"u"){const l=s.data[Ug];s.disconnectedNodes=l?new Set(l):null}return s.disconnectedNodes}function e_(s,l){if(typeof s.disconnectedNodes>"u"){const d=s.data[Ug];s.disconnectedNodes=d?new Set(d):null}return!!Xu(s)?.has(l)}function N1(s,l){const d=l,h=s.corruptedTextNodes;""===d.textContent?h.set(d,"ngetn"):d.nextSibling?.nodeType===Node.TEXT_NODE&&h.set(d,"ngtns")}const tu=new aa(""),zo=new aa("",{providedIn:"root",factory:()=>!1}),$d=new aa(""),Wd=new aa(""),t_=!1;let Zu,Hg;function BD(){if(void 0===Zu&&(Zu=null,vi.trustedTypes))try{Zu=vi.trustedTypes.createPolicy("angular",{createHTML:s=>s,createScript:s=>s,createScriptURL:s=>s})}catch{}return Zu}function ch(s){return BD()?.createHTML(s)||s}function Cf(){if(void 0===Hg&&(Hg=null,vi.trustedTypes))try{Hg=vi.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:s=>s,createScript:s=>s,createScriptURL:s=>s})}catch{}return Hg}function fm(s){return Cf()?.createHTML(s)||s}function Kr(s){return Cf()?.createScript(s)||s}function VD(s){return Cf()?.createScriptURL(s)||s}class zg{constructor(l){this.changingThisBreaksApplicationSecurity=l}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${Fc})`}}class jD extends zg{getTypeName(){return"HTML"}}class Dl extends zg{getTypeName(){return"Style"}}class tl extends zg{getTypeName(){return"Script"}}class R1 extends zg{getTypeName(){return"URL"}}class L1 extends zg{getTypeName(){return"ResourceURL"}}function Pp(s){return s instanceof zg?s.changingThisBreaksApplicationSecurity:s}function mp(s,l){const d=uh(s);if(null!=d&&d!==l){if("ResourceURL"===d&&"URL"===l)return!0;throw new Error(`Required a safe ${l}, got a ${d} (see ${Fc})`)}return d===l}function uh(s){return s instanceof zg&&s.getTypeName()||null}function zx(s){return new jD(s)}function Gm(s){return new Dl(s)}function AM(s){return new tl(s)}function Bl(s){return new R1(s)}function n_(s){return new L1(s)}function jE(s){const l=new Pa(s);return function tb(){try{return!!(new window.DOMParser).parseFromString(ch(""),"text/html")}catch{return!1}}()?new Gx(l):l}class Gx{constructor(l){this.inertDocumentHelper=l}getInertBodyElement(l){l="<body><remove></remove>"+l;try{const d=(new window.DOMParser).parseFromString(ch(l),"text/html").body;return null===d?this.inertDocumentHelper.getInertBodyElement(l):(d.firstChild?.remove(),d)}catch{return null}}}class Pa{constructor(l){this.defaultDoc=l,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(l){const d=this.inertDocument.createElement("template");return d.innerHTML=ch(l),d}}const UE=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function i_(s){return(s=String(s)).match(UE)?s:"unsafe:"+s}function yu(s){const l={};for(const d of s.split(","))l[d]=!0;return l}function xc(...s){const l={};for(const d of s)for(const h in d)d.hasOwnProperty(h)&&(l[h]=!0);return l}const k1=yu("area,br,col,hr,img,wbr"),hc=yu("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),$E=yu("rp,rt"),Hd=xc(k1,xc(hc,yu("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),xc($E,yu("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),xc($E,hc)),P1=yu("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),Kx=xc(P1,yu("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),yu("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext")),HE=yu("script,style,template");class Bf{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(l){let d=l.firstChild,h=!0,w=[];for(;d;)if(d.nodeType===Node.ELEMENT_NODE?h=this.startElement(d):d.nodeType===Node.TEXT_NODE?this.chars(d.nodeValue):this.sanitizedSomething=!0,h&&d.firstChild)w.push(d),d=Od(d);else for(;d;){d.nodeType===Node.ELEMENT_NODE&&this.endElement(d);let L=OM(d);if(L){d=L;break}d=w.pop()}return this.buf.join("")}startElement(l){const d=GE(l).toLowerCase();if(!Hd.hasOwnProperty(d))return this.sanitizedSomething=!0,!HE.hasOwnProperty(d);this.buf.push("<"),this.buf.push(d);const h=l.attributes;for(let w=0;w<h.length;w++){const L=h.item(w),z=L.name,ae=z.toLowerCase();if(!Kx.hasOwnProperty(ae)){this.sanitizedSomething=!0;continue}let xe=L.value;P1[ae]&&(xe=i_(xe)),this.buf.push(" ",z,'="',qx(xe),'"')}return this.buf.push(">"),!0}endElement(l){const d=GE(l).toLowerCase();Hd.hasOwnProperty(d)&&!k1.hasOwnProperty(d)&&(this.buf.push("</"),this.buf.push(d),this.buf.push(">"))}chars(l){this.buf.push(qx(l))}}function OM(s){const l=s.nextSibling;if(l&&s!==l.previousSibling)throw $D(l);return l}function Od(s){const l=s.firstChild;if(l&&function zE(s,l){return(s.compareDocumentPosition(l)&Node.DOCUMENT_POSITION_CONTAINED_BY)!==Node.DOCUMENT_POSITION_CONTAINED_BY}(s,l))throw $D(l);return l}function GE(s){const l=s.nodeName;return"string"==typeof l?l:"FORM"}function $D(s){return new Error(`Failed to sanitize html because the element is clobbered: ${s.outerHTML}`)}const FM=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,NM=/([^\#-~ |!])/g;function qx(s){return s.replace(/&/g,"&").replace(FM,function(l){return"&#"+(1024*(l.charCodeAt(0)-55296)+(l.charCodeAt(1)-56320)+65536)+";"}).replace(NM,function(l){return"&#"+l.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}let Bp;function Fd(s,l){let d=null;try{Bp=Bp||jE(s);let h=l?String(l):"";d=Bp.getInertBodyElement(h);let w=5,L=h;do{if(0===w)throw new Error("Failed to sanitize html because the input is unstable");w--,h=L,L=d.innerHTML,d=Bp.getInertBodyElement(h)}while(h!==L);return ch((new Bf).sanitizeChildren(Qx(d)||d))}finally{if(d){const h=Qx(d)||d;for(;h.firstChild;)h.firstChild.remove()}}}function Qx(s){return"content"in s&&function KE(s){return s.nodeType===Node.ELEMENT_NODE&&"TEMPLATE"===s.nodeName}(s)?s.content:null}var pm=function(s){return s[s.NONE=0]="NONE",s[s.HTML=1]="HTML",s[s.STYLE=2]="STYLE",s[s.SCRIPT=3]="SCRIPT",s[s.URL=4]="URL",s[s.RESOURCE_URL=5]="RESOURCE_URL",s}(pm||{});function $c(s){const l=Vf();return l?fm(l.sanitize(pm.HTML,s)||""):mp(s,"HTML")?fm(Pp(s)):Fd(fp(),Is(s))}function Yx(s){const l=Vf();return l?l.sanitize(pm.STYLE,s)||"":mp(s,"Style")?Pp(s):Is(s)}function WD(s){const l=Vf();return l?l.sanitize(pm.URL,s)||"":mp(s,"URL")?Pp(s):i_(Is(s))}function Kg(s){const l=Vf();if(l)return VD(l.sanitize(pm.RESOURCE_URL,s)||"");if(mp(s,"ResourceURL"))return VD(Pp(s));throw new po(904,!1)}function B1(s){const l=Vf();if(l)return Kr(l.sanitize(pm.SCRIPT,s)||"");if(mp(s,"Script"))return Kr(Pp(s));throw new po(905,!1)}function Xx(s){return ch(s[0])}function V1(s){return function eb(s){return BD()?.createScriptURL(s)||s}(s[0])}function j1(s,l,d){return function RM(s,l){return"src"===l&&("embed"===s||"frame"===s||"iframe"===s||"media"===s||"script"===s)||"href"===l&&("base"===s||"link"===s)?Kg:WD}(l,d)(s)}function Vf(){const s=mr();return s&&s[sd].sanitizer}const ib=/^>|^->|<!--|-->|--!>|<!-$/g,$a=/(<|>)/g,qg="\u200b$1\u200b";const _s={name:"custom-elements"},rb={name:"no-errors-schema"};let Zx=!1;function Df(s){Zx=s}function HD(){return Zx}let Jx=!1;function o_(s){Jx=s}function LM(){return Jx}function my(s){return s.ownerDocument.defaultView}function Ea(s){return s.ownerDocument}function Bh(s){return s.ownerDocument.body}function ip(s){return s instanceof Function?s():s}function Fu(s){return"browser"===(s??or(Ou)).get(Yv)}var $1=function(s){return s[s.Important=1]="Important",s[s.DashCase=2]="DashCase",s}($1||{});let KD;function mm(s,l){return KD(s,l)}function vy(s,l,d,h,w){if(null!=h){let L,z=!1;el(h)?L=h:cs(h)&&(z=!0,h=h[Cc]);const ae=Qa(h);0===s&&null!==d?null==w?XD(l,d,ae):Vp(l,d,ae,w||null,!0):1===s&&null!==d?Vp(l,d,ae,w||null,!0):2===s?ub(l,ae,z):3===s&&l.destroyNode(ae),null!=L&&function ZE(s,l,d,h,w){const L=d[gr];L!==Qa(d)&&vy(l,s,h,L,w);for(let ae=Gr;ae<d.length;ae++){const xe=d[ae];qm(xe[io],xe,s,l,h,L)}}(l,s,L,d,w)}}function qD(s,l){return s.createText(l)}function W1(s,l,d){s.setValue(l,d)}function sb(s,l){return s.createComment(function Qg(s){return s.replace(ib,l=>l.replace($a,qg))}(l))}function ab(s,l,d){return s.createElement(l,d)}function QD(s,l){l[sd].changeDetectionScheduler?.notify(9),qm(s,l,l[Ss],2,null,null)}function cb(s,l){const d=s[vo],h=l[fc];(cs(h)||l[Gl]!==h[fc][Gl])&&(s[Ps]|=jo.HasTransplantedViews),null===d?s[vo]=[l]:d.push(l)}function Xg(s,l){const d=s[vo],h=d.indexOf(l);d.splice(h,1)}function jf(s,l){if(s.length<=Gr)return;const d=Gr+l,h=s[d];if(h){const w=h[zu];null!==w&&w!==s&&Xg(w,h),l>0&&(s[d-1][Xl]=h[Xl]);const L=Y(s,Gr+l);!function H1(s,l){QD(s,l),l[Cc]=null,l[nc]=null}(h[io],h);const z=L[th];null!==z&&z.detachView(L[io]),h[fc]=null,h[Xl]=null,h[Ps]&=-129}return h}function G1(s,l){if(!(256&l[Ps])){const d=l[Ss];d.destroyNode&&qm(s,l,d,3,null,null),function BM(s){let l=s[ps];if(!l)return K1(s[io],s);for(;l;){let d=null;if(cs(l))d=l[ps];else{const h=l[Gr];h&&(d=h)}if(!d){for(;l&&!l[Xl]&&l!==s;)cs(l)&&K1(l[io],l),l=l[fc];null===l&&(l=s),cs(l)&&K1(l[io],l),d=l&&l[Xl]}l=d}}(l)}}function K1(s,l){if(256&l[Ps])return;const d=Q(null);try{l[Ps]&=-129,l[Ps]|=256,l[ee]&&en(l[ee]),function YD(s,l){let d;if(null!=s&&null!=(d=s.destroyHooks))for(let h=0;h<d.length;h+=2){const w=l[d[h]];if(!(w instanceof O0)){const L=d[h+1];if(Array.isArray(L))for(let z=0;z<L.length;z+=2){const ae=w[L[z]],xe=L[z+1];vu(4,ae,xe);try{xe.call(ae)}finally{vu(5,ae,xe)}}else{vu(4,w,L);try{L.call(w)}finally{vu(5,w,L)}}}}}(s,l),function VM(s,l){const d=s.cleanup,h=l[Rf];if(null!==d)for(let L=0;L<d.length-1;L+=2)if("string"==typeof d[L]){const z=d[L+3];z>=0?h[z]():h[-z].unsubscribe(),L+=2}else d[L].call(h[d[L+1]]);null!==h&&(l[Rf]=null);const w=l[E];if(null!==w){l[E]=null;for(let L=0;L<w.length;L++)(0,w[L])()}}(s,l),1===l[io].type&&l[Ss].destroy();const h=l[zu];if(null!==h&&el(l[fc])){h!==l[fc]&&Xg(h,l);const w=l[th];null!==w&&w.detachView(s)}K0(l)}finally{Q(d)}}function q1(s,l,d){return QE(s,l.parent,d)}function QE(s,l,d){let h=l;for(;null!==h&&168&h.type;)h=(l=h).parent;if(null===h)return d[Cc];{const{componentOffset:w}=h;if(w>-1){const{encapsulation:L}=s.data[h.directiveStart+w];if(L===sr.None||L===sr.Emulated)return null}return Vs(h,d)}}function Vp(s,l,d,h,w){s.insertBefore(l,d,h,w)}function XD(s,l,d){s.appendChild(l,d)}function ZD(s,l,d,h,w){null!==h?Vp(s,l,d,h,w):XD(s,l,d)}function s_(s,l){return s.parentNode(l)}function YE(s,l,d){return rS(s,l,d)}function _y(s,l,d){return 40&s.type?Vs(s,d):null}let ew,rS=_y;function yy(s,l){rS=s,ew=l}function Q1(s,l,d,h){const w=q1(s,h,l),L=l[Ss],ae=YE(h.parent||l[nc],h,l);if(null!=w)if(Array.isArray(d))for(let xe=0;xe<d.length;xe++)ZD(L,w,d[xe],ae,!1);else ZD(L,w,d,ae,!1);void 0!==ew&&ew(L,h,l,d,w)}function Km(s,l){if(null!==l){const d=l.type;if(3&d)return Vs(l,s);if(4&d)return tw(-1,s[l.index]);if(8&d){const h=l.child;if(null!==h)return Km(s,h);{const w=s[l.index];return el(w)?tw(-1,w):Qa(w)}}if(128&d)return Km(s,l.next);if(32&d)return mm(l,s)()||Qa(s[l.index]);{const h=Zg(s,l);return null!==h?Array.isArray(h)?h[0]:Km(wc(s[Gl]),h):Km(s,l.next)}}return null}function Zg(s,l){return null!==l?s[Gl][nc].projection[l.projection]:null}function tw(s,l){const d=Gr+s+1;if(d<l.length){const h=l[d],w=h[io].firstChild;if(null!==w)return Km(h,w)}return l[gr]}function ub(s,l,d){s.removeChild(null,l,d)}function nw(s){s.textContent=""}function Y1(s,l,d,h,w,L,z){for(;null!=d;){if(128===d.type){d=d.next;continue}const ae=h[d.index],xe=d.type;if(z&&0===l&&(ae&&rf(Qa(ae),h),d.flags|=2),32&~d.flags)if(8&xe)Y1(s,l,d.child,h,w,L,!1),vy(l,s,w,ae,L);else if(32&xe){const qe=mm(d,h);let ft;for(;ft=qe();)vy(l,s,w,ft,L);vy(l,s,w,ae,L)}else 16&xe?XE(s,l,h,d,w,L):vy(l,s,w,ae,L);d=z?d.projectionNext:d.next}}function qm(s,l,d,h,w,L){Y1(d,h,s.firstChild,l,w,L,!1)}function XE(s,l,d,h,w,L){const z=d[Gl],xe=z[nc].projection[h.projection];if(Array.isArray(xe))for(let qe=0;qe<xe.length;qe++)vy(l,s,w,xe[qe],L);else{let qe=xe;const ft=z[fc];z0(h)&&(qe.flags|=128),Y1(s,l,qe,ft,w,L,!0)}}function sS(s,l,d){""===d?s.removeAttribute(l,"class"):s.setAttribute(l,"class",d)}function a_(s,l,d){const{mergedAttrs:h,classes:w,styles:L}=d;null!==h&&Sp(s,l,h),null!==w&&sS(s,l,w),null!==L&&function Qm(s,l,d){s.setAttribute(l,"style",d)}(s,l,L)}const js={};function fh(s=1){Vh(Ua(),mr(),Vd()+s,!1)}function Vh(s,l,d,h){if(!h)if(3&~l[Ps]){const L=s.preOrderHooks;null!==L&&d1(l,L,0,d)}else{const L=s.preOrderCheckHooks;null!==L&&Q_(l,L,d)}Ig(d)}function Jg(s,l=As.Default){const d=mr();return null===d?gi(s,l):k0(Pl(),d,Vr(s),l)}function aS(){throw new Error("invalid")}function by(s,l,d,h,w,L){const z=Q(null);try{let ae=null;w&ro.SignalBased&&(ae=l[h][ie]),null!==ae&&void 0!==ae.transformFn&&(L=ae.transformFn(L)),w&ro.HasDecoratorInputTransform&&(L=s.inputTransforms[h].call(l,L)),null!==s.setInput?s.setInput(l,ae,L,d,h):yi(l,ae,h,L)}finally{Q(z)}}function X1(s,l,d,h,w,L,z,ae,xe,qe,ft){const Xt=l.blueprint.slice();return Xt[Cc]=w,Xt[Ps]=204|h,(null!==qe||s&&2048&s[Ps])&&(Xt[Ps]|=2048),xg(Xt),Xt[fc]=Xt[Eh]=s,Xt[Ja]=d,Xt[sd]=z||s&&s[sd],Xt[Ss]=ae||s&&s[Ss],Xt[Jc]=xe||s&&s[Jc]||null,Xt[nc]=L,Xt[V]=function MD(){return TD++}(),Xt[ra]=ft,Xt[Qe]=qe,Xt[Gl]=2==l.type?s[Gl]:Xt,Xt}function gm(s,l,d,h,w){let L=s.data[l];if(null===L)L=fb(s,l,d,h,w),function cD(){return Ho.lFrame.inI18n}()&&(L.flags|=32);else if(64&L.type){L.type=d,L.value=h,L.attrs=w;const z=fa();L.injectorIndex=null===z?-1:z.injectorIndex}return Ih(L,!0),L}function fb(s,l,d,h,w){const L=dx(),z=sD(),xe=s.data[l]=function Ym(s,l,d,h,w,L){let z=l?l.injectorIndex:-1,ae=0;return Sg()&&(ae|=128),{type:d,index:h,insertBeforeIndex:null,injectorIndex:z,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:ae,providerIndexes:0,value:w,attrs:L,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:l,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,z?L:L&&L.parent,d,l,h,w);return null===s.firstChild&&(s.firstChild=xe),null!==L&&(z?null==L.child&&null!==xe.parent&&(L.child=xe):null===L.next&&(L.next=xe,xe.prev=L)),xe}function pb(s,l,d,h){if(0===d)return-1;const w=l.length;for(let L=0;L<d;L++)l.push(h),s.blueprint.push(h),s.data.push(null);return w}function c_(s,l,d,h,w){const L=Vd(),z=2&h;try{Ig(-1),z&&l.length>Xe&&Vh(s,l,Xe,!1),vu(z?2:0,w),d(h,w)}finally{Ig(L),vu(z?3:1,w)}}function Cy(s,l,d){if(gu(l)){const h=Q(null);try{const L=l.directiveEnd;for(let z=l.directiveStart;z<L;z++){const ae=s.data[z];ae.contentQueries&&ae.contentQueries(1,d[z],z)}}finally{Q(h)}}}function hb(s,l,d){cx()&&(function Qs(s,l,d,h){const w=d.directiveStart,L=d.directiveEnd;Zl(d)&&function lu(s,l,d){const h=Vs(l,s),w=mb(d);let z=16;d.signals?z=4096:d.onPush&&(z=64);const ae=Ty(s,X1(s,w,null,z,h,l,null,s[sd].rendererFactory.createRenderer(h,d),null,null,null));s[l.index]=ae}(l,d,s.data[w+d.componentOffset]),s.firstCreatePass||Pv(d,l),rf(h,l);const z=d.initialInputs;for(let ae=w;ae<L;ae++){const xe=s.data[ae],qe=ic(l,s,ae,d);rf(qe,l),null!==z&&J1(0,ae-w,qe,xe,0,z),qa(xe)&&(tf(d.index,l)[Ja]=ic(l,s,ae,d))}}(s,l,d,Vs(d,l)),!(64&~d.flags)&&vb(s,l,d))}function Dy(s,l,d=Vs){const h=l.localNames;if(null!==h){let w=l.index+1;for(let L=0;L<h.length;L+=2){const z=h[L+1],ae=-1===z?d(l,s):s[z];s[w++]=ae}}}function mb(s){const l=s.tView;return null===l||l.incompleteFirstPass?s.tView=ph(1,null,s.template,s.decls,s.vars,s.directiveDefs,s.pipeDefs,s.viewQuery,s.schemas,s.consts,s.id):l}function ph(s,l,d,h,w,L,z,ae,xe,qe,ft){const Xt=Xe+h,Ln=Xt+w,zn=function JE(s,l){const d=[];for(let h=0;h<l;h++)d.push(h<s?null:js);return d}(Xt,Ln),xi="function"==typeof qe?qe():qe;return zn[io]={type:s,blueprint:zn,template:d,queries:null,viewQuery:ae,declTNode:l,data:zn.slice().fill(null,Xt),bindingStartIndex:Xt,expandoStartIndex:Ln,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:"function"==typeof L?L():L,pipeRegistry:"function"==typeof z?z():z,firstChild:null,schemas:xe,consts:xi,incompleteFirstPass:!1,ssrId:ft}}let wy=()=>null;function eT(s){ED(s)?nw(s):function tp(s){const l=fp(),d=l.createNodeIterator(s,NodeFilter.SHOW_COMMENT,{acceptNode(L){const z=function Pf(s){return s.textContent?.replace(/\s/gm,"")}(L);return"ngetn"===z||"ngtns"===z?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}});let h;const w=[];for(;h=d.nextNode();)w.push(h);for(const L of w)"ngetn"===L.textContent?L.replaceWith(l.createTextNode("")):L.remove()}(s)}function mc(s,l,d,h,w){for(let L in l){if(!l.hasOwnProperty(L))continue;const z=l[L];if(void 0===z)continue;h??={};let ae,xe=ro.None;Array.isArray(z)?(ae=z[0],xe=z[1]):ae=z;let qe=L;if(null!==w){if(!w.hasOwnProperty(L))continue;qe=w[L]}0===s?iw(h,d,qe,ae,xe):iw(h,d,qe,ae)}return h}function iw(s,l,d,h,w){let L;s.hasOwnProperty(d)?(L=s[d]).push(l,h):L=s[d]=[l,h],void 0!==w&&L.push(w)}function Uf(s,l,d,h,w,L,z,ae){const xe=Vs(l,d);let ft,qe=l.inputs;!ae&&null!=qe&&(ft=qe[h])?(nv(s,d,ft,h,w),Zl(l)&&function UM(s,l){const d=tf(l,s);16&d[Ps]||(d[Ps]|=64)}(d,l.index)):3&l.type&&(h=function Sy(s){return"class"===s?"className":"for"===s?"htmlFor":"formaction"===s?"formAction":"innerHtml"===s?"innerHTML":"readonly"===s?"readOnly":"tabindex"===s?"tabIndex":s}(h),w=null!=z?z(w,l.value||"",h):w,L.setProperty(xe,h,w))}function Tl(s,l,d,h){if(cx()){const w=null===h?null:{"":-1},L=function qo(s,l){const d=s.directiveRegistry;let h=null,w=null;if(d)for(let L=0;L<d.length;L++){const z=d[L];if(bg(l,z.selectors,!1))if(h||(h=[]),qa(z))if(null!==z.findHostDirectiveDefs){const ae=[];w=w||new Map,z.findHostDirectiveDefs(z,ae,w),h.unshift(...ae,z),Xm(s,l,ae.length)}else h.unshift(z),Xm(s,l,0);else w=w||new Map,z.findHostDirectiveDefs?.(z,h,w),h.push(z)}return null===h?null:[h,w]}(s,d);let z,ae;null===L?z=ae=null:[z,ae]=L,null!==z&&jh(s,l,d,z,w,ae),w&&function cS(s,l,d){if(l){const h=s.localNames=[];for(let w=0;w<l.length;w+=2){const L=d[l[w+1]];if(null==L)throw new po(-301,!1);h.push(l[w],L)}}}(d,h,w)}d.mergedAttrs=bh(d.mergedAttrs,d.attrs)}function jh(s,l,d,h,w,L){for(let qe=0;qe<h.length;qe++)ah(Pv(d,l),s,h[qe].type);!function Ey(s,l,d){s.flags|=1,s.directiveStart=l,s.directiveEnd=l+d,s.providerIndexes=l}(d,s.data.length,h.length);for(let qe=0;qe<h.length;qe++){const ft=h[qe];ft.providersResolver&&ft.providersResolver(ft)}let z=!1,ae=!1,xe=pb(s,l,h.length,null);for(let qe=0;qe<h.length;qe++){const ft=h[qe];d.mergedAttrs=bh(d.mergedAttrs,ft.hostAttrs),ow(s,d,l,xe,ft),iT(xe,ft,w),null!==ft.contentQueries&&(d.flags|=4),(null!==ft.hostBindings||null!==ft.hostAttrs||0!==ft.hostVars)&&(d.flags|=64);const Xt=ft.type.prototype;!z&&(Xt.ngOnChanges||Xt.ngOnInit||Xt.ngDoCheck)&&((s.preOrderHooks??=[]).push(d.index),z=!0),!ae&&(Xt.ngOnChanges||Xt.ngDoCheck)&&((s.preOrderCheckHooks??=[]).push(d.index),ae=!0),xe++}!function tT(s,l,d){const w=l.directiveEnd,L=s.data,z=l.attrs,ae=[];let xe=null,qe=null;for(let ft=l.directiveStart;ft<w;ft++){const Xt=L[ft],Ln=d?d.get(Xt):null,xi=Ln?Ln.outputs:null;xe=mc(0,Xt.inputs,ft,xe,Ln?Ln.inputs:null),qe=mc(1,Xt.outputs,ft,qe,xi);const Nr=null===xe||null===z||$u(l)?null:eC(xe,ft,z);ae.push(Nr)}null!==xe&&(xe.hasOwnProperty("class")&&(l.flags|=8),xe.hasOwnProperty("style")&&(l.flags|=16)),l.initialInputs=ae,l.inputs=xe,l.outputs=qe}(s,d,L)}function vb(s,l,d){const h=d.directiveStart,w=d.directiveEnd,L=d.index,z=function px(){return Ho.lFrame.currentDirectiveIndex}();try{Ig(L);for(let ae=h;ae<w;ae++){const xe=s.data[ae],qe=l[ae];Fv(ae),(null!==xe.hostBindings||0!==xe.hostVars||null!==xe.hostAttrs)&&nT(xe,qe)}}finally{Ig(-1),Fv(z)}}function nT(s,l){null!==s.hostBindings&&s.hostBindings(1,l)}function Xm(s,l,d){l.componentOffset=d,(s.components??=[]).push(l.index)}function iT(s,l,d){if(d){if(l.exportAs)for(let h=0;h<l.exportAs.length;h++)d[l.exportAs[h]]=s;qa(l)&&(d[""]=s)}}function ow(s,l,d,h,w){s.data[h]=w;const L=w.factory||(w.factory=Pe(w.type)),z=new O0(L,qa(w),Jg);s.blueprint[h]=z,d[h]=z,function lS(s,l,d,h,w){const L=w.hostBindings;if(L){let z=s.hostBindingOpCodes;null===z&&(z=s.hostBindingOpCodes=[]);const ae=~l.index;(function rw(s){let l=s.length;for(;l>0;){const d=s[--l];if("number"==typeof d&&d<0)return d}return 0})(z)!=ae&&z.push(ae),z.push(d,h,L)}}(s,l,h,pb(s,d,w.hostVars,js),w)}function vp(s,l,d,h,w,L){const z=Vs(s,l);Uh(l[Ss],z,L,s.value,d,h,w)}function Uh(s,l,d,h,w,L,z){if(null==L)s.removeAttribute(l,w,d);else{const ae=null==z?Is(L):z(L,h||"",w);s.setAttribute(l,w,ae,d)}}function J1(s,l,d,h,w,L){const z=L[l];if(null!==z)for(let ae=0;ae<z.length;)by(h,d,z[ae++],z[ae++],z[ae++],z[ae++])}function eC(s,l,d){let h=null,w=0;for(;w<d.length;){const L=d[w];if(0!==L)if(5!==L){if("number"==typeof L)break;if(s.hasOwnProperty(L)){null===h&&(h=[]);const z=s[L];for(let ae=0;ae<z.length;ae+=3)if(z[ae]===l){h.push(L,z[ae+1],z[ae+2],d[w+1]);break}}w+=2}else w+=2;else w+=4}return h}function uS(s,l,d,h){return[s,!0,0,l,null,h,null,d,null,null]}function sw(s,l){const d=s.contentQueries;if(null!==d){const h=Q(null);try{for(let w=0;w<d.length;w+=2){const z=d[w+1];if(-1!==z){const ae=s.data[z];K_(d[w]),ae.contentQueries(2,l[z],z)}}}finally{Q(h)}}}function Ty(s,l){return s[ps]?s[eh][Xl]=l:s[ps]=l,s[eh]=l,l}function Zm(s,l,d){K_(0);const h=Q(null);try{l(s,d)}finally{Q(h)}}function _b(s){return s[Rf]??=[]}function fS(s){return s.cleanup??=[]}function tC(s,l,d){return(null===s||qa(s))&&(d=Ov(d[l.index])),d[Ss]}function tv(s,l){const d=s[Jc],h=d?d.get(Lh,null):null;h&&h.handleError(l)}function nv(s,l,d,h,w){for(let L=0;L<d.length;){const z=d[L++],ae=d[L++],xe=d[L++];by(s.data[z],l[z],h,ae,xe,w)}}function wf(s,l,d){const h=Tr(l,s);W1(s[Ss],h,d)}function nC(s,l){const d=tf(l,s),h=d[io];!function My(s,l){for(let d=l.length;d<s.blueprint.length;d++)l.push(s.blueprint[d])}(h,d);const w=d[Cc];null!==w&&null===d[ra]&&(d[ra]=pp(w,d[Jc])),pS(h,d,d[Ja])}function pS(s,l,d){Vm(l);try{const h=s.viewQuery;null!==h&&Zm(1,h,d);const w=s.template;null!==w&&c_(s,l,w,1,d),s.firstCreatePass&&(s.firstCreatePass=!1),l[th]?.finishViewCreation(s),s.staticContentQueries&&sw(s,l),s.staticViewQueries&&Zm(2,s.viewQuery,d);const L=s.components;null!==L&&function iC(s,l){for(let d=0;d<l.length;d++)nC(s,l[d])}(l,L)}catch(h){throw s.firstCreatePass&&(s.incompleteFirstPass=!0,s.firstCreatePass=!1),h}finally{l[Ps]&=-5,Mg()}}function Iy(s,l,d,h){const w=Q(null);try{const L=l.tView,xe=X1(s,L,d,4096&s[Ps]?4096:16,null,l,null,null,h?.injector??null,h?.embeddedViewInjector??null,h?.dehydratedView??null);xe[zu]=s[l.index];const ft=s[th];return null!==ft&&(xe[th]=ft.createEmbeddedView(L)),pS(L,xe,d),xe}finally{Q(w)}}function u_(s,l){const d=Gr+l;if(d<s.length)return s[d]}function Jm(s,l){return!l||null===l.firstChild||z0(s)}function eg(s,l,d,h=!0){const w=l[io];if(function z1(s,l,d,h){const w=Gr+h,L=d.length;h>0&&(d[w-1][Xl]=l),h<L-Gr?(l[Xl]=d[w],Kn(d,Gr+h,l)):(d.push(l),l[Xl]=null),l[fc]=d;const z=l[zu];null!==z&&d!==z&&cb(z,l);const ae=l[th];null!==ae&&ae.insertView(s),bs(l),l[Ps]|=128}(w,l,s,d),h){const z=tw(d,s),ae=l[Ss],xe=s_(ae,s[gr]);null!==xe&&function lb(s,l,d,h,w,L){h[Cc]=w,h[nc]=l,qm(s,h,d,1,w,L)}(w,s[nc],ae,l,xe,z)}const L=l[ra];null!==L&&null!==L.firstChild&&(L.firstChild=null)}function Ay(s,l){const d=jf(s,l);return void 0!==d&&G1(d[io],d),d}function iv(s,l,d,h,w=!1){for(;null!==d;){if(128===d.type){d=w?d.projectionNext:d.next;continue}const L=l[d.index];null!==L&&h.push(Qa(L)),el(L)&&hS(L,h);const z=d.type;if(8&z)iv(s,l,d.child,h);else if(32&z){const ae=mm(d,l);let xe;for(;xe=ae();)h.push(xe)}else if(16&z){const ae=Zg(l,d);if(Array.isArray(ae))h.push(...ae);else{const xe=wc(l[Gl]);iv(xe[io],xe,ae,h,!0)}}d=w?d.projectionNext:d.next}return h}function hS(s,l){for(let d=Gr;d<s.length;d++){const h=s[d],w=h[io].firstChild;null!==w&&iv(h[io],h,w,l)}s[gr]!==s[Cc]&&l.push(s[gr])}let Oy=[];const yb={...oe,consumerIsAlwaysLive:!0,consumerMarkedDirty:s=>{Ko(s.lView)},consumerOnSignalRead(){this.lView[ee]=this}},bb={...oe,consumerIsAlwaysLive:!0,consumerMarkedDirty:s=>{let l=wc(s.lView);for(;l&&!Cb(l[io]);)l=wc(l);l&&s1(l)},consumerOnSignalRead(){this.lView[ee]=this}};function Cb(s){return 2!==s.type}const oC=100;function ng(s,l=!0,d=0){const h=s[sd],w=h.rendererFactory;w.begin?.();try{!function rT(s,l){const d=fx();try{bE(!0),gS(s,l);let h=0;for(;Ir(s);){if(h===oC)throw new po(103,!1);h++,gS(s,1)}}finally{bE(d)}}(s,d)}catch(z){throw l&&tv(s,z),z}finally{w.end?.(),h.inlineEffectRunner?.flush()}}function rv(s,l,d,h){const w=l[Ps];if(!(256&~w))return;l[sd].inlineEffectRunner?.flush(),Vm(l);let ae=!0,xe=null,qe=null;Cb(s)?(qe=function aw(s){return s[ee]??function tg(s){const l=Oy.pop()??Object.create(yb);return l.lView=s,l}(s)}(l),xe=ve(qe)):null===Ee()?(ae=!1,qe=function lw(s){const l=s[ee]??Object.create(bb);return l.lView=s,l}(l),xe=ve(qe)):l[ee]&&(en(l[ee]),l[ee]=null);try{xg(l),lD(s.bindingStartIndex),null!==d&&c_(s,l,d,2,h);const ft=!(3&~w);if(ft){const zn=s.preOrderCheckHooks;null!==zn&&Q_(l,zn,null)}else{const zn=s.preOrderHooks;null!==zn&&d1(l,zn,0,null),Lv(l,0)}if(function $M(s){for(let l=sy(s);null!==l;l=x1(l)){if(!(l[Ps]&jo.HasTransplantedViews))continue;const d=l[vo];for(let h=0;h<d.length;h++)s1(d[h])}}(l),cw(l,0),null!==s.contentQueries&&sw(s,l),ft){const zn=s.contentCheckHooks;null!==zn&&Q_(l,zn)}else{const zn=s.contentHooks;null!==zn&&d1(l,zn,1),Lv(l,1)}!function l_(s,l){const d=s.hostBindingOpCodes;if(null!==d)try{for(let h=0;h<d.length;h++){const w=d[h];if(w<0)Ig(~w);else{const L=w,z=d[++h],ae=d[++h];CE(z,L),ae(2,l[L])}}}finally{Ig(-1)}}(s,l);const Xt=s.components;null!==Xt&&d_(l,Xt,0);const Ln=s.viewQuery;if(null!==Ln&&Zm(2,Ln,h),ft){const zn=s.viewCheckHooks;null!==zn&&Q_(l,zn)}else{const zn=s.viewHooks;null!==zn&&d1(l,zn,2),Lv(l,2)}if(!0===s.firstUpdatePass&&(s.firstUpdatePass=!1),l[U]){for(const zn of l[U])zn();l[U]=null}l[Ps]&=-73}catch(ft){throw Ko(l),ft}finally{null!==qe&&(fn(qe,xe),ae&&function rC(s){s.lView[ee]!==s&&(s.lView=null,Oy.push(s))}(qe)),Mg()}}function cw(s,l){for(let d=sy(s);null!==d;d=x1(d))for(let h=Gr;h<d.length;h++)sC(d[h],l)}function Db(s,l,d){sC(tf(l,s),d)}function sC(s,l){G_(s)&&gS(s,l)}function gS(s,l){const h=s[io],w=s[Ps],L=s[ee];let z=!!(0===l&&16&w);if(z||=!!(64&w&&0===l),z||=!!(1024&w),z||=!(!L?.dirty||!ct(L)),z||=!1,L&&(L.dirty=!1),s[Ps]&=-9217,z)rv(h,s,h.template,s[Ja]);else if(8192&w){cw(s,1);const ae=h.components;null!==ae&&d_(s,ae,1)}}function d_(s,l,d){for(let h=0;h<l.length;h++)Db(s,l[h],d)}function aC(s,l){const d=fx()?64:1088;for(s[sd].changeDetectionScheduler?.notify(l);s;){s[Ps]|=d;const h=wc(s);if(Th(s)&&!h)return s;s=h}return null}class jp{get rootNodes(){const l=this._lView,d=l[io];return iv(d,l,d.firstChild,[])}constructor(l,d,h=!0){this._lView=l,this._cdRefInjectingView=d,this.notifyErrorHandler=h,this._appRef=null,this._attachedToViewContainer=!1}get context(){return this._lView[Ja]}set context(l){this._lView[Ja]=l}get destroyed(){return!(256&~this._lView[Ps])}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){const l=this._lView[fc];if(el(l)){const d=l[8],h=d?d.indexOf(this):-1;h>-1&&(jf(l,h),Y(d,h))}this._attachedToViewContainer=!1}G1(this._lView[io],this._lView)}onDestroy(l){Es(this._lView,l)}markForCheck(){aC(this._cdRefInjectingView||this._lView,4)}detach(){this._lView[Ps]&=-129}reattach(){bs(this._lView),this._lView[Ps]|=128}detectChanges(){this._lView[Ps]|=1024,ng(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new po(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;const l=Th(this._lView),d=this._lView[zu];null!==d&&!l&&Xg(d,this._lView),QD(this._lView[io],this._lView)}attachToAppRef(l){if(this._attachedToViewContainer)throw new po(902,!1);this._appRef=l;const d=Th(this._lView),h=this._lView[zu];null!==h&&!d&&cb(h,this._lView),bs(this._lView)}}let Fy=(()=>{class s{static#e=this.__NG_ELEMENT_ID__=Up}return s})();const wb=Fy,Ac=class extends wb{constructor(l,d,h){super(),this._declarationLView=l,this._declarationTContainer=d,this.elementRef=h}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(l,d){return this.createEmbeddedViewImpl(l,d)}createEmbeddedViewImpl(l,d,h){const w=Iy(this._declarationLView,this._declarationTContainer,l,{embeddedViewInjector:d,dehydratedView:h});return new jp(w)}};function Up(){return Ny(Pl(),mr())}function Ny(s,l){return 4&s.type?new Ac(l,s,Hv(s,l)):null}const Oc="<-- AT THIS LOCATION";function aT(s){const h=`During serialization, Angular detected DOM nodes that were created outside of Angular context and provided as projectable nodes (likely via \`ViewContainerRef.createComponent\` or \`createComponent\` APIs). Hydration is not supported for such cases, consider refactoring the code to avoid this pattern or using \`ngSkipHydration\` on the host element of the component.\n\n${function p_(s){const l=" ";let d="";const h=s;return h.previousSibling&&(d+=" \u2026\n",d+=l+f_(h.previousSibling)+"\n"),d+=l+f_(h)+` ${Oc}\n`,s.nextSibling&&(d+=" \u2026\n"),s.parentNode&&(d=f_(h.parentNode,"\n"+d)),d}(s)}\n\nNote: attributes are only displayed to better represent the DOM but have no effect on hydration mismatches.\n\n`;return new po(-503,h)}const cC=new Set(["ngh","ng-version","ng-server-context"]);function xb(s,l="\u2026"){switch(s.type){case 1:return"#text"+(s.value?`(${s.value})`:"");case 2:const h=function lC(s){const l=[];if(s.attrs)for(let d=0;d<s.attrs.length;){const h=s.attrs[d++];if("number"==typeof h)break;const w=s.attrs[d++];l.push(`${h}="${Ry(w)}"`)}return l.join(" ")}(s),w=s.value.toLowerCase();return`<${w}${h?" "+h:""}>${l}</${w}>`;case 8:return"\x3c!-- ng-container --\x3e";case 4:return"\x3c!-- container --\x3e";default:return`#node(${function oT(s){switch(s){case 4:return"view container";case 2:return"element";case 8:return"ng-container";case 32:return"icu";case 64:return"i18n";case 16:return"projection";case 1:return"text";case 128:return"@let";default:return"<unknown>"}}(s.type)})`}}function f_(s,l="\u2026"){const d=s;switch(d.nodeType){case Node.ELEMENT_NODE:const h=d.tagName.toLowerCase(),w=function uC(s){const l=[];for(let d=0;d<s.attributes.length;d++){const h=s.attributes[d];cC.has(h.name)||l.push(`${h.name}="${Ry(h.value)}"`)}return l.join(" ")}(d);return`<${h}${w?" "+w:""}>${l}</${h}>`;case Node.TEXT_NODE:const L=d.textContent?Ry(d.textContent):"";return"#text"+(L?`(${L})`:"");case Node.COMMENT_NODE:return`\x3c!-- ${Ry(d.textContent??"")} --\x3e`;default:return`#node(${d.nodeType})`}}function Ry(s,l=50){return s?(s=function dC(s){return s.replace(/\s+/gm,"")}(s)).length>l?`${s.substring(0,l-1)}\u2026`:s:""}function yS(s,l,d){const h=l.insertBeforeIndex,w=Array.isArray(h)?h[0]:h;return null===w?_y(s,0,d):Qa(d[w])}function h_(s,l,d,h,w){const L=l.insertBeforeIndex;if(Array.isArray(L)){let z=h,ae=null;if(3&l.type||(ae=z,z=w),null!==z&&-1===l.componentOffset)for(let xe=1;xe<L.length;xe++)Vp(s,z,d[L[xe]],ae,!1)}}function Ly(s,l){if(s.push(l),s.length>1)for(let d=s.length-2;d>=0;d--){const h=s[d];lT(h)||ov(h,l)&&null===pw(h)&&hw(h,l.index)}}function lT(s){return!(64&s.type)}function ov(s,l){return lT(l)||s.index>l.index}function pw(s){const l=s.insertBeforeIndex;return Array.isArray(l)?l[0]:l}function hw(s,l){const d=s.insertBeforeIndex;Array.isArray(d)?d[0]=l:(yy(yS,h_),s.insertBeforeIndex=l)}function m_(s,l){const d=s.data[l];return null===d||"string"==typeof d?null:d.hasOwnProperty("currentCaseLViewIndex")?d:d.value}function $p(s,l,d){const h=fb(s,d,64,null,null);return Ly(l,h),h}function ig(s,l){const d=l[s.currentCaseLViewIndex];return null===d?d:d<0?~d:d}function fC(s){return s>>>17}function pC(s){return(131070&s)>>>1}function sv(s){return-1===s}function Fs(s,l,d){s.index=0;const h=ig(l,d);s.removes=null!==h?l.remove[h]:Zo}function ky(s){if(s.index<s.removes.length){const l=s.removes[s.index++];return l>0?s.lView[l]:(s.stack.push(s.index,s.removes),Fs(s,s.lView[io].data[~l],s.lView),ky(s))}return 0===s.stack.length?null:(s.removes=s.stack.pop(),s.index=s.stack.pop(),ky(s))}function uT(){const s={stack:[],index:-1};return function l(d,h){for(s.lView=h;s.stack.length;)s.stack.pop();return Fs(s,d.value,h),ky.bind(null,s)}}const CS=new RegExp(`^(\\d+)*(${Zv}|${LD})*(.*)`);function g_(s){return s.index-Xe}function Eb(s,l){return!(144&s.type)&&!!l[s.index]&&Py(Qa(l[s.index]))}function Py(s){return!!s&&!s.isConnected}function $h(s,l){const d=s.i18nNodes;if(d)return d.get(l)}function DS(s,l,d){const w=s.data[Wx]?.[d];return w?fT(w,l):null}function Tb(s,l,d,h){const w=g_(h);let L=$h(s,w);if(void 0===L){const z=s.data[Wx];if(z?.[w])L=fT(z[w],d);else if(l.firstChild===h)L=s.firstChild;else{const ae=null===h.prev,xe=h.prev??h.parent;if(function hC(s){return!s.prev&&8===s.parent?.type}(h))L=dm(s,g_(h.parent));else{let qe=Vs(xe,d);if(ae)L=qe.firstChild;else{const ft=g_(xe),Xt=dm(s,ft);L=2===xe.type&&Xt?gw(Jv(s,ft)+1,Xt):qe.nextSibling}}}}return L}function gw(s,l){let d=l;for(let h=0;h<s;h++)d=d.nextSibling;return d}function fT(s,l){const[d,...h]=function HM(s){const l=s.match(CS),[d,h,w,L]=l,z=h?parseInt(h,10):w,ae=[];for(const[xe,qe,ft]of L.matchAll(/(f|n)(\d*)/g)){const Xt=parseInt(ft,10)||1;ae.push(qe,Xt)}return[z,...ae]}(s);let w;return w=d===LD?l[Gl][Cc]:d===Zv?Bh(l[Gl][Cc]):Qa(l[Number(d)+Xe]),function xS(s,l){let d=s;for(let h=0;h<l.length;h+=2){const w=l[h],L=l[h+1];for(let z=0;z<L;z++)switch(w){case Bg.FirstChild:d=d.firstChild;break;case Bg.NextSibling:d=d.nextSibling}}return d}(w,h)}function v_(s,l){if(s===l)return[];if(null==s.parentElement||null==l.parentElement)return null;if(s.parentElement===l.parentElement)return function SS(s,l){const d=[];let h=null;for(h=s;null!=h&&h!==l;h=h.nextSibling)d.push(Bg.NextSibling);return null==h?null:d}(s,l);{const d=l.parentElement,h=v_(s,d),w=v_(d.firstChild,l);return h&&w?[...h,Bg.FirstChild,...w]:null}}function pT(s,l,d){const h=v_(s,l);return null===h?null:function dT(s,l){const d=[s];for(const h of l){const w=d.length-1;w>0&&d[w-1]===h?d[w]=(d[w]||1)+1:d.push(h,"")}return d.join("")}(d,h)}function vw(s,l,d){let w,L,z,h=s.parent;for(;null!==h&&(Eb(h,l)||d?.has(h.index));)h=h.parent;null!==h&&3&h.type?(w=h.index,L=Qa(l[w]),z=Is(w-Xe)):(w=z=LD,L=l[Gl][Cc]);let ae=Qa(l[s.index]);if(44&s.type){const qe=Km(l,s);qe&&(ae=qe)}let xe=pT(L,ae,z);if(null===xe&&L!==ae&&(xe=pT(L.ownerDocument.body,ae,Zv),null===xe))throw function dw(s,l){const h=`${function vS(s,l,d){const h=" ";let w="";l.prev?(w+=" \u2026\n",w+=h+xb(l.prev)+"\n"):l.type&&12&l.type&&(w+=" \u2026\n"),d?(w+=h+xb(l)+"\n",w+=h+`\x3c!-- container --\x3e ${Oc}\n`):w+=h+xb(l)+` ${Oc}\n`,w+=" \u2026\n";const L=l.type?q1(s[io],l,s):null;return L&&(w=f_(L,"\n"+w)),w}(s,l,!1)}\n\n`,w=function Sb(s){return`To fix this problem:\n * check ${s?`the "${s}"`:"corresponding"} component for hydration-related issues\n * check to see if your template has valid HTML structure\n * or skip hydration by adding the \`ngSkipHydration\` attribute to its host node in a template\n\n`}();throw new po(-502,"During serialization, Angular was unable to find an element in the DOM:\n\n"+h+w)}(l,s);return xe}let _w=!1,hT=()=>{};function Mb(s){_w=s}function ES(){return _w}function Ab(s,l,d){if(!d.isI18nHydrationEnabled)return null;const h=s[io],w=h.data[l];if(!w||!w.ast)return null;const L=h.data[w.parentTNodeIndex];if(L&&Lx(L))return null;const z={caseQueue:[],disconnectedNodes:new Set,disjointNodes:new Set};return Ob(s,z,d,w.ast),0===z.caseQueue.length&&0===z.disconnectedNodes.size&&0===z.disjointNodes.size?null:z}function Ob(s,l,d,h){let w=null;for(const L of h){const z=By(s,l,d,L);z&&(MS(w,z)&&l.disjointNodes.add(L.index-Xe),w=z)}return w}function MS(s,l){return s&&s.nextSibling!==l}function By(s,l,d,h){const w=Qa(s[h.index]);if(!w||Py(w))return l.disconnectedNodes.add(h.index-Xe),null;const L=w;switch(h.kind){case 0:N1(d,L);break;case 1:case 2:Ob(s,l,d,h.children);break;case 3:{const z=s[h.currentCaseLViewIndex];if(null!=z){const ae=z<0?~z:z;l.caseQueue.push(ae),Ob(s,l,d,h.cases[ae])}break}}return function vT(s,l){const h=s[io].data[l.index];return _u(h)?Km(s,h):3===l.kind?function rg(s,l){const d={stack:[],index:-1,lView:l};return Fs(d,s,l),ky.bind(null,d)}(h,s)()??Qa(s[l.index]):Qa(s[l.index])??null}(s,h)}function __(s,l){s.currentNode=l}function og(s,l,d){const h=d.index-Xe,{disconnectedNodes:w}=s,L=l.currentNode;return l.isConnected?(s.i18nNodes.set(h,L),w.delete(h)):w.add(h),L}function mC(s,l){let d=s.currentNode;for(let h=0;h<l&&d;h++)d=d?.nextSibling??null;return d}function bw(s,l){return{currentNode:l,isConnected:s.isConnected}}function Cw(s,l,d,h){const w=s[ra];if(!w||!ES()||d&&(Lx(d)||e_(w,d.index-Xe)))return;const L=s[io],z=L.data[l],xe=function ae(){if(sv(h)){const zn=Tb(w,L,s,d);return 8&d.type?zn:zn.firstChild}return w?.firstChild}(),qe=Xu(w)??new Set,ft=w.i18nNodes??=new Map,Xt=w.data[F1]?.[l-Xe]??[],Ln=w.dehydratedIcuData??=new Map;y_({hydrationInfo:w,lView:s,i18nNodes:ft,disconnectedNodes:qe,caseQueue:Xt,dehydratedIcuData:Ln},{currentNode:xe,isConnected:!0},z.ast),w.disconnectedNodes=0===qe.size?null:qe}function y_(s,l,d){if(Array.isArray(d)){let h=l;for(const w of d){const L=DS(s.hydrationInfo,s.lView,w.index-Xe);L&&(h=bw(l,L)),y_(s,h,w)}}else{if(s.disconnectedNodes.has(d.index-Xe))return;switch(d.kind){case 0:{const h=og(s,l,d);__(l,h?.nextSibling??null);break}case 1:{y_(s,bw(l,l.currentNode?.firstChild??null),d.children);const h=og(s,l,d);__(l,h?.nextSibling??null);break}case 2:{const h=d.index-Xe,{hydrationInfo:w}=s,L=PD(w,h);switch(d.type){case 0:{const z=og(s,l,d);!function hp(s,l){return void 0!==s.data[kD]?.[l]}(w,h)?(y_(s,bw(l,l.currentNode?.firstChild??null),d.children),__(l,z?.nextSibling??null),null!==L&&__(l,mC(l,L+1))):(y_(s,l,d.children),__(l,mC(l,1)));break}case 1:og(s,l,d),__(l,mC(l,L+1))}break}case 3:{const h=l.isConnected?s.caseQueue.shift():null,w={currentNode:null,isConnected:!1};for(let z=0;z<d.cases.length;z++)y_(s,z===h?l:w,d.cases[z]);null!==h&&s.dehydratedIcuData.set(d.index,{case:h,node:d});const L=og(s,l,d);__(l,L?.nextSibling??null);break}}}}let _T=()=>{};function bT(s,l,d){const h=s[ra]?.dehydratedIcuData;h&&h.get(l)?.case===d&&h.delete(l)}function Dw(s,l,d){for(const h of d.node.cases[d.case]){const w=l.get(h.index-Xe);w&&ub(s,w,!1)}}function ww(s){const l=s[Ei]??[],h=s[fc][Ss];for(const w of l)Uy(w,h);s[Ei]=Zo}function Uy(s,l){let d=0,h=s.firstChild;if(h){const w=s.data[jg];for(;d<w;){const L=h.nextSibling;ub(l,h,!1),h=L,d++}}}function gC(s){ww(s);const l=s[Cc];cs(l)&&vC(l);for(let d=Gr;d<s.length;d++)vC(s[d])}function vC(s){!function jy(s){const l=s[ra];if(l){const{i18nNodes:d,dehydratedIcuData:h}=l;if(d&&h){const w=s[Ss];for(const L of h.values())Dw(w,d,L)}l.i18nNodes=void 0,l.dehydratedIcuData=void 0}}(s);const l=s[io];for(let d=Xe;d<l.bindingStartIndex;d++)el(s[d])?gC(s[d]):cs(s[d])&&vC(s[d])}let Nb=()=>null;function xw(s,l){const d=s[Ei];return l&&null!==d&&0!==d.length?d[0].data[O1]===l?d.shift():(ww(s),null):null}function _m(s,l){return Nb(s,l)}class Wh{}const Wp=new aa("",{providedIn:"root",factory:()=>!1}),sg=new aa(""),av=new aa("");class OS{}class Ys{}class $f{resolveComponentFactory(l){throw function lv(s){const l=Error(`No component factory found for ${ai(s)}.`);return l.ngComponent=s,l}(l)}}class ag{static#e=this.NULL=new $f}class $y{}let Rb=(()=>{class s{constructor(){this.destroyNode=null}static#e=this.__NG_ELEMENT_ID__=()=>function Sw(){const s=mr(),d=tf(Pl().index,s);return(cs(d)?d:s)[Ss]}()}return s})(),b_=(()=>{class s{static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>null})}return s})();function bu(s){return void 0!==s.ngModule}function Wf(s){return!!Qu(s)}function zi(s){return!!rd(s)}function yC(s){return!!xs(s)}function nu(s){return!!ja(s)}function Wy(s,l){if(is(s)&&!(s=Vr(s)))throw new Error(`Expected forwardRef function, imported from "${xa(l)}", to return a standalone entity or NgModule but got "${xa(s)||s}".`);if(null==Qu(s)){const d=ja(s)||xs(s)||rd(s);if(null==d)throw bu(s)?new Error(`A module with providers was imported from "${xa(l)}". Modules with providers are not supported in standalone components imports.`):new Error(`The "${xa(s)}" type, imported from "${xa(l)}", must be a standalone component / directive / pipe or an NgModule. Did you forget to add the required @Component / @Directive / @Pipe or @NgModule annotation?`);if(!d.standalone)throw new Error(`The "${xa(s)}" ${function Cu(s){return ja(s)?"component":xs(s)?"directive":rd(s)?"pipe":"type"}(s)}, imported from "${xa(l)}", is not standalone. Did you forget to add the standalone: true flag?`)}}const ym=!0;class cu{constructor(){this.ownerNgModule=new Map,this.ngModulesWithSomeUnresolvedDecls=new Set,this.ngModulesScopeCache=new Map,this.standaloneComponentsScopeCache=new Map}resolveNgModulesDecls(){if(0!==this.ngModulesWithSomeUnresolvedDecls.size){for(const l of this.ngModulesWithSomeUnresolvedDecls){const d=Qu(l);if(d?.declarations)for(const h of ip(d.declarations))nu(h)&&this.ownerNgModule.set(h,l)}this.ngModulesWithSomeUnresolvedDecls.clear()}}getComponentDependencies(l,d){this.resolveNgModulesDecls();const h=ja(l);if(null===h)throw new Error(`Attempting to get component dependencies for a type that is not a component: ${l}`);if(h.standalone){const w=this.getStandaloneComponentScope(l,d);return w.compilation.isPoisoned?{dependencies:[]}:{dependencies:[...w.compilation.directives,...w.compilation.pipes,...w.compilation.ngModules]}}{if(!this.ownerNgModule.has(l))return{dependencies:[]};const w=this.getNgModuleScope(this.ownerNgModule.get(l));return w.compilation.isPoisoned?{dependencies:[]}:{dependencies:[...w.compilation.directives,...w.compilation.pipes]}}}registerNgModule(l,d){if(!Wf(l))throw new Error(`Attempting to register a Type which is not NgModule as NgModule: ${l}`);this.ngModulesWithSomeUnresolvedDecls.add(l)}clearScopeCacheFor(l){this.ngModulesScopeCache.delete(l),this.standaloneComponentsScopeCache.delete(l)}getNgModuleScope(l){if(this.ngModulesScopeCache.has(l))return this.ngModulesScopeCache.get(l);const d=this.computeNgModuleScope(l);return this.ngModulesScopeCache.set(l,d),d}computeNgModuleScope(l){const d=Qu(l,!0),h={exported:{directives:new Set,pipes:new Set},compilation:{directives:new Set,pipes:new Set}};for(const w of ip(d.imports))if(Wf(w)){const L=this.getNgModuleScope(w);lg(L.exported.directives,h.compilation.directives),lg(L.exported.pipes,h.compilation.pipes)}else{if(!Yd(w)){h.compilation.isPoisoned=!0;break}if(yC(w)||nu(w))h.compilation.directives.add(w);else{if(!zi(w))throw new po(1e3,"The standalone imported type is neither a component nor a directive nor a pipe");h.compilation.pipes.add(w)}}if(!h.compilation.isPoisoned)for(const w of ip(d.declarations)){if(Wf(w)||Yd(w)){h.compilation.isPoisoned=!0;break}zi(w)?h.compilation.pipes.add(w):h.compilation.directives.add(w)}for(const w of ip(d.exports))if(Wf(w)){const L=this.getNgModuleScope(w);lg(L.exported.directives,h.exported.directives),lg(L.exported.pipes,h.exported.pipes),lg(L.exported.directives,h.compilation.directives),lg(L.exported.pipes,h.compilation.pipes)}else zi(w)?h.exported.pipes.add(w):h.exported.directives.add(w);return h}getStandaloneComponentScope(l,d){if(this.standaloneComponentsScopeCache.has(l))return this.standaloneComponentsScopeCache.get(l);const h=this.computeStandaloneComponentScope(l,d);return this.standaloneComponentsScopeCache.set(l,h),h}computeStandaloneComponentScope(l,d){const h={compilation:{directives:new Set([l]),pipes:new Set,ngModules:new Set}};for(const w of Ut(d??[])){const L=Vr(w);try{Wy(L,l)}catch{return h.compilation.isPoisoned=!0,h}if(Wf(L)){h.compilation.ngModules.add(L);const z=this.getNgModuleScope(L);if(z.exported.isPoisoned)return h.compilation.isPoisoned=!0,h;lg(z.exported.directives,h.compilation.directives),lg(z.exported.pipes,h.compilation.pipes)}else if(zi(L))h.compilation.pipes.add(L);else{if(!yC(L)&&!nu(L))return h.compilation.isPoisoned=!0,h;h.compilation.directives.add(L)}}return h}isOrphanComponent(l){const d=ja(l);return!(!d||d.standalone||(this.resolveNgModulesDecls(),this.ownerNgModule.has(l)))}}function lg(s,l){for(const d of s)l.add(d)}const Hh=new cu;function Wc(s,l,d){let h=d?s.styles:null,w=d?s.classes:null,L=0;if(null!==l)for(let z=0;z<l.length;z++){const ae=l[z];"number"==typeof ae?L=ae:1==L?w=so(w,ae):2==L&&(h=so(h,ae+": "+l[++z]+";"))}d?s.styles=h:s.stylesWithoutHost=h,d?s.classes=w:s.classesWithoutHost=w}class cd extends ag{constructor(l){super(),this.ngModule=l}resolveComponentFactory(l){const d=ja(l);return new hh(d,this.ngModule)}}function Hy(s,l){const d=[];for(const h in s){if(!s.hasOwnProperty(h))continue;const w=s[h];if(void 0===w)continue;const L=Array.isArray(w),z=L?w[0]:w;d.push(l?{propName:z,templateName:h,isSignal:!!((L?w[1]:ro.None)&ro.SignalBased)}:{propName:z,templateName:h})}return d}class hh extends Ys{get inputs(){const l=this.componentDef,d=l.inputTransforms,h=Hy(l.inputs,!0);if(null!==d)for(const w of h)d.hasOwnProperty(w.propName)&&(w.transform=d[w.propName]);return h}get outputs(){return Hy(this.componentDef.outputs,!1)}constructor(l,d){super(),this.componentDef=l,this.ngModule=d,this.componentType=l.type,this.selector=function C0(s){return s.map(If).join(",")}(l.selectors),this.ngContentSelectors=l.ngContentSelectors?l.ngContentSelectors:[],this.isBoundToModule=!!d}create(l,d,h,w){const L=Q(null);try{let z=(w=w||this.ngModule)instanceof Hu?w:w?.injector;z&&null!==this.componentDef.getStandaloneInjector&&(z=this.componentDef.getStandaloneInjector(z)||z);const ae=z?new X_(l,z):l,xe=ae.get($y,null);if(null===xe)throw new po(407,!1);const Xt={rendererFactory:xe,sanitizer:ae.get(b_,null),inlineEffectRunner:null,changeDetectionScheduler:ae.get(Wh,null)},Ln=xe.createRenderer(null,this.componentDef),zn=this.componentDef.selectors[0][0]||"div",xi=h?function ev(s,l,d,h){const L=h.get(zo,!1)||d===sr.ShadowDom,z=s.selectRootElement(l,L);return function jM(s){wy(s)}(z),z}(Ln,h,this.componentDef.encapsulation,ae):ab(Ln,zn,function cg(s){const l=s.toLowerCase();return"svg"===l?rh:"math"===l?Xf:null}(zn));let Nr=512;this.componentDef.signals?Nr|=4096:this.componentDef.onPush||(Nr|=16);let go=null;null!==xi&&(go=pp(xi,ae,!0));const Oo=ph(0,null,null,1,0,null,null,null,null,null,null),Ar=X1(null,Oo,null,Nr,null,null,Xt,Ln,ae,null,go);Vm(Ar);let ma,oc,qu=null;try{const Gd=this.componentDef;let qh,dE=null;Gd.findHostDirectiveDefs?(qh=[],dE=new Map,Gd.findHostDirectiveDefs(Gd,qh,dE),qh.push(Gd)):qh=[Gd];const nx=function Nd(s,l){const d=s[io],h=Xe;return s[h]=l,gm(d,h,2,"#host",null)}(Ar,xi);qu=function C_(s,l,d,h,w,L,z){const ae=w[io];!function lf(s,l,d,h){for(const w of s)l.mergedAttrs=bh(l.mergedAttrs,w.hostAttrs);null!==l.mergedAttrs&&(Wc(l,l.mergedAttrs,!0),null!==d&&a_(h,d,l))}(h,s,l,z);let xe=null;null!==l&&(xe=pp(l,w[Jc]));const qe=L.rendererFactory.createRenderer(l,d);let ft=16;d.signals?ft=4096:d.onPush&&(ft=64);const Xt=X1(w,mb(d),null,ft,w[s.index],s,L,qe,null,null,xe);return ae.firstCreatePass&&Xm(ae,s,h.length-1),Ty(w,Xt),w[s.index]=Xt}(nx,xi,Gd,qh,Ar,Xt,Ln),oc=ka(Oo,Xe),xi&&function zy(s,l,d,h){if(h)Sp(s,d,["ng-version","18.2.8"]);else{const{attrs:w,classes:L}=function Ji(s){const l=[],d=[];let h=1,w=2;for(;h<s.length;){let L=s[h];if("string"==typeof L)2===w?""!==L&&l.push(L,s[++h]):8===w&&d.push(L);else{if(!Qd(w))break;w=L}h++}return{attrs:l,classes:d}}(l.selectors[0]);w&&Sp(s,d,w),L&&L.length>0&&sS(s,d,L.join(" "))}}(Ln,Gd,xi,h),void 0!==d&&function xf(s,l,d){const h=s.projection=[];for(let w=0;w<l.length;w++){const L=d[w];h.push(null!=L?Array.from(L):null)}}(oc,this.ngContentSelectors,d),ma=function bm(s,l,d,h,w,L){const z=Pl(),ae=w[io],xe=Vs(z,w);jh(ae,w,z,d,null,h);for(let ft=0;ft<d.length;ft++)rf(ic(w,ae,z.directiveStart+ft,z),w);vb(ae,w,z),xe&&rf(xe,w);const qe=ic(w,ae,z.directiveStart+z.componentOffset,z);if(s[Ja]=w[Ja]=qe,null!==L)for(const ft of L)ft(qe,l);return Cy(ae,z,w),qe}(qu,Gd,qh,dE,Ar,[Tw]),pS(Oo,Ar,null)}catch(Gd){throw null!==qu&&K0(qu),K0(Ar),Gd}finally{Mg()}return new Hf(this.componentType,ma,Hv(oc,Ar),Ar,oc)}finally{Q(L)}}}class Hf extends OS{constructor(l,d,h,w,L){super(),this.location=h,this._rootLView=w,this._tNode=L,this.previousInputValues=null,this.instance=d,this.hostView=this.changeDetectorRef=new jp(w,void 0,!1),this.componentType=l}setInput(l,d){const h=this._tNode.inputs;let w;if(null!==h&&(w=h[l])){if(this.previousInputValues??=new Map,this.previousInputValues.has(l)&&Object.is(this.previousInputValues.get(l),d))return;const L=this._rootLView;nv(L[io],L,w,l,d),this.previousInputValues.set(l,d),aC(tf(this._tNode.index,L),1)}}get injector(){return new ad(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(l){this.hostView.onDestroy(l)}}function Tw(){const s=Pl();hD(mr()[io],s)}let Ju=(()=>{class s{static#e=this.__NG_ELEMENT_ID__=D_}return s})();function D_(){return Jl(Pl(),mr())}const Hp=Ju,Gy=class extends Hp{constructor(l,d,h){super(),this._lContainer=l,this._hostTNode=d,this._hostLView=h}get element(){return Hv(this._hostTNode,this._hostLView)}get injector(){return new ad(this._hostTNode,this._hostLView)}get parentInjector(){const l=Og(this._hostTNode,this._hostLView);if($m(l)){const d=Oh(l,this._hostLView),h=im(l);return new ad(d[io].data[h+8],d)}return new ad(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(l){const d=Ky(this._lContainer);return null!==d&&d[l]||null}get length(){return this._lContainer.length-Gr}createEmbeddedView(l,d,h){let w,L;"number"==typeof h?w=h:null!=h&&(w=h.index,L=h.injector);const z=_m(this._lContainer,l.ssrId),ae=l.createEmbeddedViewImpl(d||{},L,z);return this.insertImpl(ae,w,Jm(this._hostTNode,z)),ae}createComponent(l,d,h,w,L){const z=l&&!Ff(l);let ae;if(z)ae=d;else{const xi=d||{};ae=xi.index,h=xi.injector,w=xi.projectableNodes,L=xi.environmentInjector||xi.ngModuleRef}const xe=z?l:new hh(ja(l)),qe=h||this.parentInjector;if(!L&&null==xe.ngModule){const Nr=(z?qe:this.parentInjector).get(Hu,null);Nr&&(L=Nr)}const ft=ja(xe.componentType??{}),Xt=_m(this._lContainer,ft?.id??null),zn=xe.create(qe,w,Xt?.firstChild??null,L);return this.insertImpl(zn.hostView,ae,Jm(this._hostTNode,Xt)),zn}insert(l,d){return this.insertImpl(l,d,!0)}insertImpl(l,d,h){const w=l._lView;if(function S0(s){return el(s[fc])}(w)){const ae=this.indexOf(l);if(-1!==ae)this.detach(ae);else{const xe=w[fc],qe=new Gy(xe,xe[nc],xe[fc]);qe.detach(qe.indexOf(l))}}const L=this._adjustIndex(d),z=this._lContainer;return eg(z,w,L,h),l.attachToViewContainerRef(),Kn(Gu(z),L,l),l}move(l,d){return this.insert(l,d)}indexOf(l){const d=Ky(this._lContainer);return null!==d?d.indexOf(l):-1}remove(l){const d=this._adjustIndex(l,-1),h=jf(this._lContainer,d);h&&(Y(Gu(this._lContainer),d),G1(h[io],h))}detach(l){const d=this._adjustIndex(l,-1),h=jf(this._lContainer,d);return h&&null!=Y(Gu(this._lContainer),d)?new jp(h):null}_adjustIndex(l,d=0){return l??this.length+d}};function Ky(s){return s[8]}function Gu(s){return s[8]||(s[8]=[])}function Jl(s,l){let d;const h=l[s.index];return el(h)?d=h:(d=uS(h,l,null,s),l[s.index]=d,Ty(l,d)),qy(d,l,s,h),new Gy(d,s,l)}let qy=Mw,zh=()=>!1;function cv(s,l,d){return zh(s,l,d)}function Mw(s,l,d,h){if(s[gr])return;let w;w=8&d.type?Qa(h):function ug(s,l){const d=s[Ss],h=d.createComment(""),w=Vs(l,s);return Vp(d,s_(d,w),h,function JD(s,l){return s.nextSibling(l)}(d,w),!1),h}(l,d),s[gr]=w}function w_(s,l,d){if(s[gr]&&s[Ei])return!0;const h=d[ra],w=l.index-Xe;if(!h||kg(l)||e_(h,w))return!1;const z=dm(h,w),ae=h.data[ly]?.[w],[xe,qe]=function IS(s,l){const d=[];for(const h of l)for(let w=0;w<(h[A1]??1);w++){const L={data:h,firstChild:null};h[jg]>0&&(L.firstChild=s,s=gw(h[jg],s)),d.push(L)}return[s,d]}(z,ae);return s[gr]=xe,s[Ei]=qe,!0}function dg(s,l,d,h){zh(s,d,l)||Mw(s,l,d,h)}class fg{constructor(l){this.queryList=l,this.matches=null}clone(){return new fg(this.queryList)}setDirty(){this.queryList.setDirty()}}class Qy{constructor(l=[]){this.queries=l}createEmbeddedView(l){const d=l.queries;if(null!==d){const h=null!==l.contentQueries?l.contentQueries[0]:d.length,w=[];for(let L=0;L<h;L++){const z=d.getByIndex(L);w.push(this.queries[z.indexInDeclarationView].clone())}return new Qy(w)}return null}insertView(l){this.dirtyQueriesWithMatches(l)}detachView(l){this.dirtyQueriesWithMatches(l)}finishViewCreation(l){this.dirtyQueriesWithMatches(l)}dirtyQueriesWithMatches(l){for(let d=0;d<this.queries.length;d++)null!==S_(l,d).matches&&this.queries[d].setDirty()}}class bC{constructor(l,d,h=null){this.flags=d,this.read=h,this.predicate="string"==typeof l?function iu(s){return s.split(",").map(l=>l.trim())}(l):l}}class pg{constructor(l=[]){this.queries=l}elementStart(l,d){for(let h=0;h<this.queries.length;h++)this.queries[h].elementStart(l,d)}elementEnd(l){for(let d=0;d<this.queries.length;d++)this.queries[d].elementEnd(l)}embeddedTView(l){let d=null;for(let h=0;h<this.length;h++){const w=null!==d?d.length:0,L=this.getByIndex(h).embeddedTView(l,w);L&&(L.indexInDeclarationView=h,null!==d?d.push(L):d=[L])}return null!==d?new pg(d):null}template(l,d){for(let h=0;h<this.queries.length;h++)this.queries[h].template(l,d)}getByIndex(l){return this.queries[l]}get length(){return this.queries.length}track(l){this.queries.push(l)}}class Gh{constructor(l,d=-1){this.metadata=l,this.matches=null,this.indexInDeclarationView=-1,this.crossesNgTemplate=!1,this._appliesToNextNode=!0,this._declarationNodeIndex=d}elementStart(l,d){this.isApplyingToNode(d)&&this.matchTNode(l,d)}elementEnd(l){this._declarationNodeIndex===l.index&&(this._appliesToNextNode=!1)}template(l,d){this.elementStart(l,d)}embeddedTView(l,d){return this.isApplyingToNode(l)?(this.crossesNgTemplate=!0,this.addMatch(-l.index,d),new Gh(this.metadata)):null}isApplyingToNode(l){if(this._appliesToNextNode&&1&~this.metadata.flags){const d=this._declarationNodeIndex;let h=l.parent;for(;null!==h&&8&h.type&&h.index!==d;)h=h.parent;return d===(null!==h?h.index:-1)}return this._appliesToNextNode}matchTNode(l,d){const h=this.metadata.predicate;if(Array.isArray(h))for(let w=0;w<h.length;w++){const L=h[w];this.matchTNodeWithReadOption(l,d,CC(d,L)),this.matchTNodeWithReadOption(l,d,Jf(d,l,L,!1,!1))}else h===Fy?4&d.type&&this.matchTNodeWithReadOption(l,d,-1):this.matchTNodeWithReadOption(l,d,Jf(d,l,h,!1,!1))}matchTNodeWithReadOption(l,d,h){if(null!==h){const w=this.metadata.read;if(null!==w)if(w===Hm||w===Ju||w===Fy&&4&d.type)this.addMatch(d.index,-2);else{const L=Jf(d,l,w,!1,!1);null!==L&&this.addMatch(d.index,L)}else this.addMatch(d.index,h)}}addMatch(l,d){null===this.matches?this.matches=[l,d]:this.matches.push(l,d)}}function CC(s,l){const d=s.localNames;if(null!==d)for(let h=0;h<d.length;h+=2)if(d[h]===l)return d[h+1];return null}function ud(s,l,d,h){return-1===d?function NS(s,l){return 11&s.type?Hv(s,l):4&s.type?Ny(s,l):null}(l,s):-2===d?function x_(s,l,d){return d===Hm?Hv(l,s):d===Fy?Ny(l,s):d===Ju?Jl(l,s):void 0}(s,l,h):ic(s,s[io],d,l)}function hg(s,l,d,h){const w=l[th].queries[h];if(null===w.matches){const L=s.data,z=d.matches,ae=[];for(let xe=0;null!==z&&xe<z.length;xe+=2){const qe=z[xe];ae.push(qe<0?null:ud(l,L[qe],z[xe+1],d.metadata.read))}w.matches=ae}return w.matches}function Yy(s,l,d,h){const w=s.queries.getByIndex(d),L=w.matches;if(null!==L){const z=hg(s,l,w,d);for(let ae=0;ae<L.length;ae+=2){const xe=L[ae];if(xe>0)h.push(z[ae/2]);else{const qe=L[ae+1],ft=l[-xe];for(let Xt=Gr;Xt<ft.length;Xt++){const Ln=ft[Xt];Ln[zu]===Ln[fc]&&Yy(Ln[io],Ln,qe,h)}if(null!==ft[vo]){const Xt=ft[vo];for(let Ln=0;Ln<Xt.length;Ln++){const zn=Xt[Ln];Yy(zn[io],zn,qe,h)}}}}}return h}function RS(s,l){return s[th].queries[l].queryList}function cf(s,l,d){const h=new lm(!(4&~d));return function bo(s,l,d,h){const w=_b(l);w.push(d),s.firstCreatePass&&fS(s).push(h,w.length-1)}(s,l,h,h.destroy),(l[th]??=new Qy).queries.push(new fg(h))-1}function uu(s,l,d){const h=Ua();return h.firstCreatePass&&(dv(h,new bC(s,l,d),-1),!(2&~l)&&(h.staticViewQueries=!0)),cf(h,mr(),l)}function Lb(s,l,d,h){const w=Ua();if(w.firstCreatePass){const L=Pl();dv(w,new bC(l,d,h),L.index),function Cm(s,l){const d=s.contentQueries||(s.contentQueries=[]);l!==(d.length?d[d.length-1]:-1)&&d.push(s.queries.length-1,l)}(w,s),!(2&~d)&&(w.staticContentQueries=!0)}return cf(w,mr(),d)}function dv(s,l,d){null===s.queries&&(s.queries=new pg),s.queries.track(new Gh(l,d))}function S_(s,l){return s.queries.getByIndex(l)}function Xy(s,l){const d=s[io],h=S_(d,l);return h.crossesNgTemplate?Yy(d,s,l,[]):hg(d,s,h,l)}const Zy=new Set;function dd(s){Zy.has(s)||(Zy.add(s),performance?.mark?.("mark_feature_usage",{detail:{feature:s}}))}function fv(s){return"function"==typeof s&&void 0!==s[ie]}function kb(s){return null}function pv(s,l){dd("NgSignals");const d=function qt(s){const l=Object.create(Zn);l.value=s;const d=()=>(Z(l),l.value);return d[ie]=l,d}(s),h=d[ie];return l?.equal&&(h.equal=l.equal),d.set=w=>Cn(h,w),d.update=w=>function tn(s,l){Et()||ji(),Cn(s,l(s.value))}(h,w),d.asReadonly=DC.bind(d),d}function DC(){const s=this[ie];if(void 0===s.readonlyFn){const l=()=>this();l[ie]=s,s.readonlyFn=l}return s.readonlyFn}function hv(s){return fv(s)&&"function"==typeof s.set}function Hc(s,l){let d;const h=ut(()=>{d._dirtyCounter();const w=function xC(s,l){const d=s._lView,h=s._queryIndex;if(void 0===d||void 0===h||4&d[Ps])return l?void 0:Zo;const w=RS(d,h),L=Xy(d,h);return w.reset(L,Nx),l?w.first:w._changesDetected||void 0===s._flatValue?s._flatValue=w.toArray():s._flatValue}(d,s);if(l&&void 0===w)throw new po(-951,!1);return w});return d=h[ie],d._dirtyCounter=pv(0),d._flatValue=void 0,h}function zf(){return Hc(!0,!1)}function mv(){return Hc(!0,!0)}function E_(){return Hc(!1,!1)}function wC(s,l){const d=s[ie];d._lView=mr(),d._queryIndex=l,d._queryList=RS(d._lView,l),d._queryList.onDirty(()=>d._dirtyCounter.update(h=>h+1))}function SC(s,l){return zf()}const Dd=(SC.required=function _p(s,l){return mv()},SC);function LS(s,l){return E_()}function Iw(s,l){return zf()}const EC=(Iw.required=function KM(s,l){return mv()},Iw);function Aw(s,l){return E_()}function kS(s){const l=Object.create(kl),d=new b1;function h(){return Z(l),Jy(l.value),l.value}return l.value=s,h[ie]=l,h.asReadonly=DC.bind(h),h.set=w=>{l.equal(l.value,w)||(Cn(l,w),d.emit(w))},h.update=w=>{Jy(l.value),h.set(w(l.value))},h.subscribe=d.subscribe.bind(d),h.destroyRef=d.destroyRef,h}function Jy(s){if(s===Hs)throw new po(952,!1)}function Ow(s){return kS(s)}const e0=(Ow.required=function Pb(){return kS(Hs)},Ow);class T_{}const Fw=bi("ContentChildren",(s,l={})=>({selector:s,first:!1,isViewQuery:!1,descendants:!1,emitDistinctChangesOnly:!0,...l}),T_),t0=bi("ContentChild",(s,l={})=>({selector:s,first:!0,isViewQuery:!1,descendants:!0,...l}),T_),M_=bi("ViewChildren",(s,l={})=>({selector:s,first:!1,isViewQuery:!0,descendants:!0,emitDistinctChangesOnly:!0,...l}),T_),PS=bi("ViewChild",(s,l)=>({selector:s,first:!0,isViewQuery:!0,descendants:!0,...l}),T_);function Vb(s){const l=[],d=new Map;function h(w){let L=d.get(w);if(!L){const z=s(w);d.set(w,L=z.then(jS))}return L}return n0.forEach((w,L)=>{const z=[];w.templateUrl&&z.push(h(w.templateUrl).then(qe=>{w.template=qe}));const ae="string"==typeof w.styles?[w.styles]:w.styles||[];if(w.styles=ae,w.styleUrl&&w.styleUrls?.length)throw new Error("@Component cannot define both `styleUrl` and `styleUrls`. Use `styleUrl` if the component has one stylesheet, or `styleUrls` if it has multiple");if(w.styleUrls?.length){const qe=w.styles.length,ft=w.styleUrls;w.styleUrls.forEach((Xt,Ln)=>{ae.push(""),z.push(h(Xt).then(zn=>{ae[qe+Ln]=zn,ft.splice(ft.indexOf(Xt),1),0==ft.length&&(w.styleUrls=void 0)}))})}else w.styleUrl&&z.push(h(w.styleUrl).then(qe=>{ae.push(qe),w.styleUrl=void 0}));const xe=Promise.all(z).then(()=>function qM(s){TC.delete(s)}(L));l.push(xe)}),AC(),Promise.all(l).then(()=>{})}let n0=new Map;const TC=new Set;function MC(s){return TC.has(s)}function IC(s){return!!(s.templateUrl&&!s.hasOwnProperty("template")||s.styleUrls&&s.styleUrls.length||s.styleUrl)}function AC(){const s=n0;return n0=new Map,s}function VS(s){TC.clear(),s.forEach((l,d)=>TC.add(d)),n0=s}function jS(s){return"string"==typeof s?s:s.text()}const mh=new Map;let FC=!0;function r0(s,l){(function CT(s,l,d){if(l&&l!==d&&FC)throw new Error(`Duplicate module registered for ${s} - ${ai(l)} vs ${ai(l.name)}`)})(l,mh.get(l)||null,s),mh.set(l,s)}function NC(s){return mh.get(s)}function Dm(s){FC=!s}function US(s,l,d){const h=mr(),w=Au(),L=Vs(w,h);if(2===w.type&&"iframe"===l.toLowerCase()){const z=L;throw z.src="",z.srcdoc=ch(""),ub(h[Ss],z),new po(-910,!1)}return s}function jb(s){return Object.getPrototypeOf(s.prototype).constructor}function o0(s){let l=jb(s.type),d=!0;const h=[s];for(;l;){let w;if(qa(s))w=l.\u0275cmp||l.\u0275dir;else{if(l.\u0275cmp)throw new po(903,!1);w=l.\u0275dir}if(w){if(d){h.push(w);const z=s;z.inputs=$b(s.inputs),z.inputTransforms=$b(s.inputTransforms),z.declaredInputs=$b(s.declaredInputs),z.outputs=$b(s.outputs);const ae=w.hostBindings;ae&&Rw(s,ae);const xe=w.viewQuery,qe=w.contentQueries;if(xe&&Nw(s,xe),qe&&RC(s,qe),s0(s,w),Er(s.outputs,w.outputs),qa(w)&&w.data.animation){const ft=s.data;ft.animation=(ft.animation||[]).concat(w.data.animation)}}const L=w.features;if(L)for(let z=0;z<L.length;z++){const ae=L[z];ae&&ae.ngInherit&&ae(s),ae===o0&&(d=!1)}}l=Object.getPrototypeOf(l)}!function Ub(s){let l=0,d=null;for(let h=s.length-1;h>=0;h--){const w=s[h];w.hostVars=l+=w.hostVars,w.hostAttrs=bh(w.hostAttrs,d=bh(d,w.hostAttrs))}}(h)}function s0(s,l){for(const d in l.inputs){if(!l.inputs.hasOwnProperty(d)||s.inputs.hasOwnProperty(d))continue;const h=l.inputs[d];if(void 0!==h&&(s.inputs[d]=h,s.declaredInputs[d]=l.declaredInputs[d],null!==l.inputTransforms)){const w=Array.isArray(h)?h[0]:h;if(!l.inputTransforms.hasOwnProperty(w))continue;s.inputTransforms??={},s.inputTransforms[w]=l.inputTransforms[w]}}}function $b(s){return s===ls?{}:s===Zo?[]:s}function Nw(s,l){const d=s.viewQuery;s.viewQuery=d?(h,w)=>{l(h,w),d(h,w)}:l}function RC(s,l){const d=s.contentQueries;s.contentQueries=d?(h,w,L)=>{l(h,w,L),d(h,w,L)}:l}function Rw(s,l){const d=s.hostBindings;s.hostBindings=d?(h,w)=>{l(h,w),d(h,w)}:l}const $S=["providersResolver"],I_=["template","decls","consts","vars","onPush","ngContentSelectors","styles","encapsulation","schemas"];function a0(s){let d,l=jb(s.type);d=qa(s)?l.\u0275cmp:l.\u0275dir;const h=s;for(const w of $S)h[w]=d[w];if(qa(d))for(const w of I_)h[w]=d[w]}function pa(s){const l=d=>{const h=(Array.isArray(s)?s:s()).map(w=>"function"==typeof w?{directive:Vr(w),inputs:ls,outputs:ls}:{directive:Vr(w.directive),inputs:A_(w.inputs),outputs:A_(w.outputs)});null===d.hostDirectives?(d.findHostDirectiveDefs=gv,d.hostDirectives=h):d.hostDirectives.unshift(...h)};return l.ngInherit=!0,l}function gv(s,l,d){if(null!==s.hostDirectives)for(const h of s.hostDirectives){const w=xs(h.directive);wT(w.declaredInputs,h.inputs),gv(w,l,d),d.set(w,h),l.push(w)}}function A_(s){if(void 0===s||0===s.length)return ls;const l={};for(let d=0;d<s.length;d+=2)l[s[d]]=s[d+1];return l}function wT(s,l){for(const d in l)l.hasOwnProperty(d)&&(s[l[d]]=s[d])}function Lw(s){const l=s.inputConfig,d={};for(const h in l)if(l.hasOwnProperty(h)){const w=l[h];Array.isArray(w)&&w[3]&&(d[h]=w[3])}s.inputTransforms=d}class O_{}class Wb{}function kw(s,l){return new c0(s,l??null,[])}const WS=kw;class c0 extends O_{constructor(l,d,h,w=!0){super(),this.ngModuleType=l,this._parent=d,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new cd(this);const L=Qu(l);this._bootstrapComponents=ip(L.bootstrap),this._r3Injector=Nh(l,d,[{provide:O_,useValue:this},{provide:ag,useValue:this.componentFactoryResolver},...h],ai(l),new Set(["environment"])),w&&this.resolveInjectorInitializers()}resolveInjectorInitializers(){this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(this.ngModuleType)}get injector(){return this._r3Injector}destroy(){const l=this._r3Injector;!l.destroyed&&l.destroy(),this.destroyCbs.forEach(d=>d()),this.destroyCbs=null}onDestroy(l){this.destroyCbs.push(l)}}class Hb extends Wb{constructor(l){super(),this.moduleType=l}create(l){return new c0(this.moduleType,l,[])}}class zb extends O_{constructor(l){super(),this.componentFactoryResolver=new cd(this),this.instance=null;const d=new gf([...l.providers,{provide:O_,useValue:this},{provide:ag,useValue:this.componentFactoryResolver}],l.parent||ns(),l.debugName,new Set(["environment"]));this.injector=d,l.runEnvironmentInitializers&&d.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(l){this.injector.onDestroy(l)}}function Pw(s,l,d=null){return new zb({providers:s,parent:l,debugName:d,runEnvironmentInitializers:!0}).injector}let c=(()=>{class s{constructor(){this.cachedInjectors=new Map}getOrCreateInjector(d,h,w,L){if(!this.cachedInjectors.has(d)){const z=w.length>0?Pw(w,h,L):null;this.cachedInjectors.set(d,z)}return this.cachedInjectors.get(d)}ngOnDestroy(){try{for(const d of this.cachedInjectors.values())null!==d&&d.destroy()}finally{this.cachedInjectors.clear()}}static#e=this.\u0275prov=Ks({token:s,providedIn:"environment",factory:()=>new s})}return s})();function a(s){return!!I(s)&&(Array.isArray(s)||!(s instanceof Map)&&Symbol.iterator in s)}function I(s){return null!==s&&("function"==typeof s||"object"==typeof s)}function K(s,l){const d=a(s),h=a(l);return d&&h?function u(s,l,d){const h=s[Symbol.iterator](),w=l[Symbol.iterator]();for(;;){const L=h.next(),z=w.next();if(L.done&&z.done)return!0;if(L.done||z.done||!d(L.value,z.value))return!1}}(s,l,K):!(d||!s||"object"!=typeof s&&"function"!=typeof s||h||!l||"object"!=typeof l&&"function"!=typeof l)||Object.is(s,l)}function ye(s,l,d){return s[l]=d}function Ye(s,l){return s[l]}function $e(s,l,d){return!Object.is(s[l],d)&&(s[l]=d,!0)}function ht(s,l,d,h){const w=$e(s,l,d);return $e(s,l+1,h)||w}function Vt(s,l,d,h,w){const L=ht(s,l,d,h);return $e(s,l+2,w)||L}function zt(s,l,d,h,w,L){const z=ht(s,l,d,h);return ht(s,l+2,w,L)||z}function yn(s){return!(32&~s.flags)}function pr(s,l,d,h,w,L,z,ae,xe,qe){const ft=d+Xe,Xt=l.firstCreatePass?function li(s,l,d,h,w,L,z,ae,xe){const qe=l.consts,ft=gm(l,s,4,z||null,ae||null);Tl(l,d,ft,vf(qe,xe)),hD(l,ft);const Xt=ft.tView=ph(2,ft,h,w,L,l.directiveRegistry,l.pipeRegistry,null,l.schemas,qe,null);return null!==l.queries&&(l.queries.template(l,ft),Xt.queries=l.queries.embeddedTView(ft)),ft}(ft,l,s,h,w,L,z,ae,xe):l.data[ft];Ih(Xt,!1);const Ln=hr(l,s,Xt,d);Rv()&&Q1(l,s,Ln,Xt),rf(Ln,s);const zn=uS(Ln,s,Ln,Xt);return s[ft]=zn,Ty(s,zn),cv(zn,Xt,s),Ga(Xt)&&hb(l,s,Xt),null!=xe&&Dy(s,Xt,qe),Xt}function si(s,l,d,h,w,L,z,ae){const xe=mr(),qe=Ua();return pr(xe,qe,s,l,d,h,w,vf(qe.consts,L),z,ae),si}let hr=_o;function _o(s,l,d,h){return jm(!0),l[Ss].createComment("")}function jr(s,l,d,h){const w=l[ra],L=!w||Sg()||yn(d)||e_(w,h);if(jm(L),L)return _o(0,l);const z=w.data[Vg]?.[h]??null;null!==z&&null!==d.tView&&null===d.tView.ssrId&&(d.tView.ssrId=z);const ae=Tb(w,s,l,d);return np(w,h,ae),gw(Jv(w,h),ae)}var lo=function(s){return s[s.NOT_STARTED=0]="NOT_STARTED",s[s.IN_PROGRESS=1]="IN_PROGRESS",s[s.COMPLETE=2]="COMPLETE",s[s.FAILED=3]="FAILED",s}(lo||{});const mo=0,br=1;var yo=function(s){return s[s.Placeholder=0]="Placeholder",s[s.Loading=1]="Loading",s[s.Complete=2]="Complete",s[s.Error=3]="Error",s}(yo||{}),ml=function(s){return s[s.Initial=-1]="Initial",s}(ml||{});const Ca=0,oo=1,Ba=2,Co=3,us=4,Rr=5;var xo=function(s){return s[s.Manual=0]="Manual",s[s.Playthrough=1]="Playthrough",s}(xo||{});function Jr(s,l,d){const h=1===s?Rr:us;null===l[h]&&(l[h]=[]),l[h].push(d)}function No(s,l){const d=1===s?Rr:us,h=l[d];if(null!==h){for(const w of h)w();l[d]=null}}function Hr(s){No(1,s),No(0,s)}function ys(s,l){if(null!==Ee())throw new po(-602,!1)}var Ns=function(s){return s[s.EarlyRead=0]="EarlyRead",s[s.Write=1]="Write",s[s.MixedReadWrite=2]="MixedReadWrite",s[s.Read=3]="Read",s}(Ns||{});let Ml=(()=>{class s{constructor(){this.impl=null}execute(){this.impl?.execute()}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new s})}return s})();class Nu{constructor(){this.ngZone=or(Uc),this.scheduler=or(Wh),this.errorHandler=or(Lh,{optional:!0}),this.sequences=new Set,this.deferredRegistrations=new Set,this.executing=!1}static#e=this.PHASES=[Ns.EarlyRead,Ns.Write,Ns.MixedReadWrite,Ns.Read];execute(){this.executing=!0;for(const l of Nu.PHASES)for(const d of this.sequences)if(!d.erroredOrDestroyed&&d.hooks[l])try{d.pipelinedValue=this.ngZone.runOutsideAngular(()=>d.hooks[l](d.pipelinedValue))}catch(h){d.erroredOrDestroyed=!0,this.errorHandler?.handleError(h)}this.executing=!1;for(const l of this.sequences)l.afterRun(),l.once&&(this.sequences.delete(l),l.destroy());for(const l of this.deferredRegistrations)this.sequences.add(l);this.deferredRegistrations.size>0&&this.scheduler.notify(7),this.deferredRegistrations.clear()}register(l){this.executing?this.deferredRegistrations.add(l):(this.sequences.add(l),this.scheduler.notify(6))}unregister(l){this.executing&&this.sequences.has(l)?(l.erroredOrDestroyed=!0,l.pipelinedValue=void 0,l.once=!0):(this.sequences.delete(l),this.deferredRegistrations.delete(l))}static#t=this.\u0275prov=Ks({token:Nu,providedIn:"root",factory:()=>new Nu})}class Rd{constructor(l,d,h,w){this.impl=l,this.hooks=d,this.once=h,this.erroredOrDestroyed=!1,this.pipelinedValue=void 0,this.unregisterOnDestroy=w?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.()}}function ru(s,l){!l?.injector&&Nm();const d=l?.injector??or(Ou);return Fu(d)?(dd("NgAfterRender"),Os(s,d,l,!1)):Cr}function wd(s,l){!l?.injector&&Nm();const d=l?.injector??or(Ou);return Fu(d)?(dd("NgAfterNextRender"),Os(s,d,l,!0)):Cr}function Os(s,l,d,h){const w=l.get(Ml);w.impl??=l.get(Nu);const L=d?.phase??Ns.MixedReadWrite,z=!0!==d?.manualCleanup?l.get(ny):null,ae=new Rd(w.impl,function jl(s,l){if(s instanceof Function){const d=[void 0,void 0,void 0,void 0];return d[l]=s,d}return[s.earlyRead,s.write,s.mixedReadWrite,s.read]}(s,L),h,z);return w.impl.register(ae),ae}const Cr={destroy(){}};function So(s){return s+1}function Po(s,l){return s[So(l.index)]}function ha(s,l){const d=So(l.index);return s.data[d]}function Fa(s,l){return l===yo.Placeholder?s.placeholderBlockConfig?.[mo]??null:l===yo.Loading?s.loadingBlockConfig?.[mo]??null:null}function hs(s){return s.loadingBlockConfig?.[br]??null}function Ka(s,l){if(!s||0===s.length)return l;const d=new Set(s);for(const h of l)d.add(h);return s.length===d.size?s:Array.from(d)}function Bw(s){return null!==s&&"object"==typeof s&&"number"==typeof s.primaryTmplIndex}const F_={passive:!0,capture:!0},Gb=new WeakMap,LC=new WeakMap,N_=new WeakMap,ST=["click","keydown"],HS=["mouseenter","focusin"];let R_=null,kC=0;class Kb{constructor(){this.callbacks=new Set,this.listener=()=>{for(const l of this.callbacks)l()}}}function uf(s,l){let d=LC.get(s);if(!d){d=new Kb,LC.set(s,d);for(const h of ST)s.addEventListener(h,d.listener,F_)}return d.callbacks.add(l),()=>{const{callbacks:h,listener:w}=d;if(h.delete(l),0===h.size){LC.delete(s);for(const L of ST)s.removeEventListener(L,w,F_)}}}function L_(s,l){let d=Gb.get(s);if(!d){d=new Kb,Gb.set(s,d);for(const h of HS)s.addEventListener(h,d.listener,F_)}return d.callbacks.add(l),()=>{const{callbacks:h,listener:w}=d;if(h.delete(l),0===h.size){for(const L of HS)s.removeEventListener(L,w,F_);Gb.delete(s)}}}function PC(s,l,d){const h=d.get(Uc);let w=N_.get(s);return R_=R_||h.runOutsideAngular(()=>new IntersectionObserver(L=>{for(const z of L)z.isIntersecting&&N_.has(z.target)&&h.run(N_.get(z.target).listener)})),w||(w=new Kb,h.runOutsideAngular(()=>R_.observe(s)),N_.set(s,w),kC++),w.callbacks.add(l),()=>{N_.has(s)&&(w.callbacks.delete(l),0===w.callbacks.size&&(R_?.unobserve(s),N_.delete(s),kC--),0===kC&&(R_?.disconnect(),R_=null))}}function BC(s,l,d,h,w,L,z){const ae=s[Jc],xe=ae.get(Uc);wd({read:function qe(){if(ih(s))return;const ft=Po(s,l),Xt=ft[oo];if(Xt!==ml.Initial&&Xt!==yo.Placeholder)return;const Ln=function AA(s,l,d){return null==d?s:d>=0?Bm(d,s):s[l.index][Gr]??null}(s,l,h);if(!Ln)return void wd({read:qe},{injector:ae});if(ih(Ln))return;const zn=function QM(s,l){return Tr(Xe+l,s)}(Ln,d),xi=w(zn,()=>{xe.run(()=>{s!==Ln&&jc(Ln,xi),L()})},ae);s!==Ln&&Es(Ln,xi),Jr(z,ft,xi)}},{injector:ae})}function nl(s,l){const h=l[Jc].get(FA);return h.add(s),()=>h.remove(s)}let FA=(()=>{class s{constructor(){this.executingCallbacks=!1,this.idleId=null,this.current=new Set,this.deferred=new Set,this.ngZone=or(Uc),this.requestIdleCallbackFn=(typeof requestIdleCallback<"u"?requestIdleCallback:setTimeout).bind(globalThis),this.cancelIdleCallbackFn=(typeof requestIdleCallback<"u"?cancelIdleCallback:clearTimeout).bind(globalThis)}add(d){(this.executingCallbacks?this.deferred:this.current).add(d),null===this.idleId&&this.scheduleIdleCallback()}remove(d){const{current:h,deferred:w}=this;h.delete(d),w.delete(d),0===h.size&&0===w.size&&this.cancelIdleCallback()}scheduleIdleCallback(){const d=()=>{this.cancelIdleCallback(),this.executingCallbacks=!0;for(const h of this.current)h();if(this.current.clear(),this.executingCallbacks=!1,this.deferred.size>0){for(const h of this.deferred)this.current.add(h);this.deferred.clear(),this.scheduleIdleCallback()}};this.idleId=this.requestIdleCallbackFn(()=>this.ngZone.run(d))}cancelIdleCallback(){null!==this.idleId&&(this.cancelIdleCallbackFn(this.idleId),this.idleId=null)}ngOnDestroy(){this.cancelIdleCallback(),this.current.clear(),this.deferred.clear()}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new s})}return s})();function zS(s){return(l,d)=>VC(s,l,d)}function VC(s,l,d){const w=d[Jc].get(YM);return w.add(s,l),()=>w.remove(l)}let YM=(()=>{class s{constructor(){this.executingCallbacks=!1,this.timeoutId=null,this.invokeTimerAt=null,this.current=[],this.deferred=[]}add(d,h){this.addToQueue(this.executingCallbacks?this.deferred:this.current,Date.now()+d,h),this.scheduleTimer()}remove(d){const{current:h,deferred:w}=this;-1===this.removeFromQueue(h,d)&&this.removeFromQueue(w,d),0===h.length&&0===w.length&&this.clearTimeout()}addToQueue(d,h,w){let L=d.length;for(let z=0;z<d.length;z+=2)if(d[z]>h){L=z;break}Ze(d,L,h,w)}removeFromQueue(d,h){let w=-1;for(let L=0;L<d.length;L+=2)if(d[L+1]===h){w=L;break}return w>-1&&ue(d,w,2),w}scheduleTimer(){const d=()=>{this.clearTimeout(),this.executingCallbacks=!0;const w=[...this.current],L=Date.now();for(let ae=0;ae<w.length;ae+=2){const qe=w[ae+1];if(!(w[ae]<=L))break;qe()}let z=-1;for(let ae=0;ae<this.current.length&&this.current[ae]<=L;ae+=2)z=ae+1;if(z>=0&&ue(this.current,0,z+1),this.executingCallbacks=!1,this.deferred.length>0){for(let ae=0;ae<this.deferred.length;ae+=2)this.addToQueue(this.current,this.deferred[ae],this.deferred[ae+1]);this.deferred.length=0}this.scheduleTimer()};if(this.current.length>0){const w=Date.now(),L=this.current[0];if(null===this.timeoutId||this.invokeTimerAt&&this.invokeTimerAt-L>16){this.clearTimeout();const z=Math.max(L-w,16);this.invokeTimerAt=L,this.timeoutId=setTimeout(d,z)}}}clearTimeout(){null!==this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null)}ngOnDestroy(){this.clearTimeout(),this.current.length=0,this.deferred.length=0}static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new s})}return s})();const Vw=new aa("DEFER_BLOCK_DEPENDENCY_INTERCEPTOR"),jw=new aa("");function TT(s){return s.get(jw,null,{optional:!0})?.behavior!==xo.Manual&&Fu(s)}let jC=null;function zp(s,l,d,h){const w=s.consts;null!=d&&(l.placeholderBlockConfig=vf(w,d)),null!=h&&(l.loadingBlockConfig=vf(w,h)),null===jC&&(jC=NA)}function vv(s,l,d,h,w,L,z,ae,xe){const qe=mr(),ft=Ua(),Xt=s+Xe,Ln=pr(qe,ft,s,null,0,0);if(ft.firstCreatePass){dd("NgDefer");const go={primaryTmplIndex:l,loadingTmplIndex:h??null,placeholderTmplIndex:w??null,errorTmplIndex:L??null,placeholderBlockConfig:null,loadingBlockConfig:null,dependencyResolverFn:d??null,loadingState:lo.NOT_STARTED,loadingPromise:null,providers:null};xe?.(ft,go,ae,z),function dn(s,l,d){const h=So(l);s.data[h]=d}(ft,Xt,go)}cv(qe[Xt],Ln,qe);const xi=[null,ml.Initial,null,null,null,null];!function wi(s,l,d){s[So(l)]=d}(qe,Xt,xi);const Nr=()=>Hr(xi);Jr(0,xi,()=>jc(qe,Nr)),Es(qe,Nr)}function u0(s){const l=mr();if($e(l,Fp(),s)){const h=Q(null);try{const w=!!s,L=Au(),ae=Po(l,L)[oo];!1===w&&ae===ml.Initial?p0(l,L):!0===w&&(ae===ml.Initial||ae===yo.Placeholder)&&h0(l,L)}finally{Q(h)}}}function Kh(s){const l=mr();if($e(l,Fp(),s)){const h=Q(null);try{const w=!!s,L=l[io],z=Au(),ae=ha(L,z);!0===w&&ae.loadingState===lo.NOT_STARTED&&xm(ae,l,z)}finally{Q(h)}}}function XM(){UC(nl)}function MT(){Wa(nl)}function ZM(){const s=mr(),l=Pl(),h=s[Jc],w=ha(s[io],l);(!TT(h)||null===w.loadingTmplIndex)&&p0(s,l),h0(s,l)}function GS(){const s=mr(),l=Pl(),h=ha(s[io],l);h.loadingState===lo.NOT_STARTED&&Gp(h,s,l)}function d0(s){UC(zS(s))}function Ku(s){Wa(zS(s))}function Cs(s,l){const d=mr(),h=Pl();p0(d,h),BC(d,h,s,l,L_,()=>h0(d,h),0)}function Ul(s,l){const d=mr(),h=Pl(),L=ha(d[io],h);L.loadingState===lo.NOT_STARTED&&BC(d,h,s,l,L_,()=>xm(L,d,h),1)}function JM(s,l){const d=mr(),h=Pl();p0(d,h),BC(d,h,s,l,uf,()=>h0(d,h),0)}function xd(s,l){const d=mr(),h=Pl(),L=ha(d[io],h);L.loadingState===lo.NOT_STARTED&&BC(d,h,s,l,uf,()=>xm(L,d,h),1)}function ua(s,l){const d=mr(),h=Pl();p0(d,h),BC(d,h,s,l,PC,()=>h0(d,h),0)}function yp(s,l){const d=mr(),h=Pl(),L=ha(d[io],h);L.loadingState===lo.NOT_STARTED&&BC(d,h,s,l,PC,()=>xm(L,d,h),1)}function UC(s){const l=mr(),d=Pl();if(p0(l,d),Fu(l[Jc])){const h=s(()=>h0(l,d),l);Jr(0,Po(l,d),h)}}function Wa(s){const l=mr();if(Fu(l[Jc])){const d=Pl(),w=ha(l[io],d);w.loadingState===lo.NOT_STARTED&&Jr(1,Po(l,d),s(()=>xm(w,l,d),l))}}function Sf(s,l,d,h=!1){const w=d[fc],L=w[io];if(ih(w))return;const z=Po(w,l);if(gh(z[oo],s)&&gh(z[Ca]??-1,s)){const xe=w[Jc],qe=ha(L,l),Xt=h||!Fu(xe)||null===hs(qe)&&null===Fa(qe,yo.Loading)&&!Fa(qe,yo.Placeholder)?eI:jC;try{Xt(s,z,d,l,w)}catch(Ln){tv(w,Ln)}}}function wl(s,l,d){return s.get(c).getOrCreateInjector(l,s,d,"")}function eI(s,l,d,h,w){const L=function Ol(s,l,d){const w=ha(l[io],d);switch(s){case yo.Complete:return w.primaryTmplIndex;case yo.Loading:return w.loadingTmplIndex;case yo.Error:return w.errorTmplIndex;case yo.Placeholder:return w.placeholderTmplIndex;default:return null}}(s,w,h);if(null!==L){l[oo]=s;const z=w[io],xe=ka(z,L+Xe),qe=0;let ft;if(Ay(d,qe),s===yo.Complete){const zn=ha(z,h),xi=zn.providers;xi&&xi.length>0&&(ft=function $l(s,l,d){if(s instanceof X_){const w=s.injector,z=wl(s.parentInjector,l,d);return new X_(w,z)}const h=s.get(Hu);if(h!==s){const w=wl(h,l,d);return new X_(s,w)}return wl(s,l,d)}(w[Jc],zn,xi))}const Xt=_m(d,xe.tView.ssrId),Ln=Iy(w,xe,null,{dehydratedView:Xt,injector:ft});eg(d,Ln,qe,Jm(xe,Xt)),aC(Ln,2)}}function NA(s,l,d,h,w){const L=Date.now(),ae=ha(w[io],h);if(null===l[Ba]||l[Ba]<=L){l[Ba]=null;const xe=hs(ae),qe=null!==l[Co];if(s!==yo.Loading||null===xe||qe){s>yo.Loading&&qe&&(l[Co](),l[Co]=null,l[Ca]=null),eI(s,l,d,h,w);const ft=Fa(ae,s);null!==ft&&(l[Ba]=L+ft,f0(ft,l,h,d,w))}else{l[Ca]=s;const ft=f0(xe,l,h,d,w);l[Co]=ft}}else l[Ca]=s}function f0(s,l,d,h,w){return VC(s,()=>{const z=l[Ca];l[Ba]=null,l[Ca]=null,null!==z&&Sf(z,d,h)},w)}function gh(s,l){return s<l}function xm(s,l,d){l[Jc]&&TT(l[Jc])&&Gp(s,l,d)}function Gp(s,l,d){const h=l[Jc],w=l[io];if(s.loadingState!==lo.NOT_STARTED)return s.loadingPromise??Promise.resolve();const L=Po(l,d),z=function mg(s,l){return ka(s,l.primaryTmplIndex+Xe)}(w,s);s.loadingState=lo.IN_PROGRESS,No(1,L);let ae=s.dependencyResolverFn;const xe=h.get(sm),qe=xe.add();return ae?(s.loadingPromise=Promise.allSettled(ae()).then(ft=>{let Xt=!1;const Ln=[],zn=[];for(const xi of ft){if("fulfilled"!==xi.status){Xt=!0;break}{const Nr=xi.value,go=ja(Nr)||xs(Nr);if(go)Ln.push(go);else{const Oo=rd(Nr);Oo&&zn.push(Oo)}}}if(s.loadingPromise=null,xe.remove(qe),Xt){if(s.loadingState=lo.FAILED,null===s.errorTmplIndex){const Nr=new po(750,!1);tv(l,Nr)}}else{s.loadingState=lo.COMPLETE;const xi=z.tView;if(Ln.length>0){xi.directiveRegistry=Ka(xi.directiveRegistry,Ln);const go=wh(!1,...Ln.map(Oo=>Oo.type));s.providers=go}zn.length>0&&(xi.pipeRegistry=Ka(xi.pipeRegistry,zn))}}),s.loadingPromise):(s.loadingPromise=Promise.resolve().then(()=>{s.loadingPromise=null,s.loadingState=lo.COMPLETE,xe.remove(qe)}),s.loadingPromise)}function p0(s,l){Sf(yo.Placeholder,l,s[l.index])}function tI(s,l,d){s.loadingPromise.then(()=>{s.loadingState===lo.COMPLETE?Sf(yo.Complete,l,d):s.loadingState===lo.FAILED&&Sf(yo.Error,l,d)})}function h0(s,l){const d=s[io],h=s[l.index];if(!TT(s[Jc]))return;const L=Po(s,l),z=ha(d,l);switch(Hr(L),z.loadingState){case lo.NOT_STARTED:Sf(yo.Loading,l,h),Gp(z,s,l),z.loadingState===lo.IN_PROGRESS&&tI(z,l,h);break;case lo.IN_PROGRESS:Sf(yo.Loading,l,h),tI(z,l,h);break;case lo.COMPLETE:Sf(yo.Complete,l,h);break;case lo.FAILED:Sf(yo.Error,l,h)}}function IT(s,l,d,h){const w=mr();return $e(w,Fp(),l)&&(Ua(),vp(Au(),w,s,l,d,h)),IT}function Gf(s,l){let d=!1,h=_f();for(let L=1;L<l.length;L+=2)d=$e(s,h++,l[L])||d;if(lD(h),!d)return js;let w=l[0];for(let L=1;L<l.length;L+=2)w+=Is(l[L])+l[L+1];return w}function $C(s,l,d,h){return $e(s,Fp(),d)?l+Is(d)+h:js}function WC(s,l,d,h,w,L){const ae=ht(s,_f(),d,w);return Eg(2),ae?l+Is(d)+h+Is(w)+L:js}function _v(s,l,d,h,w,L,z,ae){const qe=Vt(s,_f(),d,w,z);return Eg(3),qe?l+Is(d)+h+Is(w)+L+Is(z)+ae:js}function Kp(s,l,d,h,w,L,z,ae,xe,qe){const Xt=zt(s,_f(),d,w,z,xe);return Eg(4),Xt?l+Is(d)+h+Is(w)+L+Is(z)+ae+Is(xe)+qe:js}function HC(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt){const Ln=_f();let zn=zt(s,Ln,d,w,z,xe);return zn=$e(s,Ln+4,ft)||zn,Eg(5),zn?l+Is(d)+h+Is(w)+L+Is(z)+ae+Is(xe)+qe+Is(ft)+Xt:js}function zC(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn){const xi=_f();let Nr=zt(s,xi,d,w,z,xe);return Nr=ht(s,xi+4,ft,Ln)||Nr,Eg(6),Nr?l+Is(d)+h+Is(w)+L+Is(z)+ae+Is(xe)+qe+Is(ft)+Xt+Is(Ln)+zn:js}function GC(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr){const go=_f();let Oo=zt(s,go,d,w,z,xe);return Oo=Vt(s,go+4,ft,Ln,xi)||Oo,Eg(7),Oo?l+Is(d)+h+Is(w)+L+Is(z)+ae+Is(xe)+qe+Is(ft)+Xt+Is(Ln)+zn+Is(xi)+Nr:js}function qb(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo){const Ar=_f();let ma=zt(s,Ar,d,w,z,xe);return ma=zt(s,Ar+4,ft,Ln,xi,go)||ma,Eg(8),ma?l+Is(d)+h+Is(w)+L+Is(z)+ae+Is(xe)+qe+Is(ft)+Xt+Is(Ln)+zn+Is(xi)+Nr+Is(go)+Oo:js}function Uw(s,l,d,h,w,L){const z=mr(),ae=$C(z,l,d,h);return ae!==js&&vp(Au(),z,s,ae,w,L),Uw}function vh(s,l,d,h,w,L,z,ae){const xe=mr(),qe=WC(xe,l,d,h,w,L);return qe!==js&&vp(Au(),xe,s,qe,z,ae),vh}function KS(s,l,d,h,w,L,z,ae,xe,qe){const ft=mr(),Xt=_v(ft,l,d,h,w,L,z,ae);return Xt!==js&&vp(Au(),ft,s,Xt,xe,qe),KS}function $w(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt){const Ln=mr(),zn=Kp(Ln,l,d,h,w,L,z,ae,xe,qe);return zn!==js&&vp(Au(),Ln,s,zn,ft,Xt),$w}function bp(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn){const xi=mr(),Nr=HC(xi,l,d,h,w,L,z,ae,xe,qe,ft,Xt);return Nr!==js&&vp(Au(),xi,s,Nr,Ln,zn),bp}function Qb(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr){const go=mr(),Oo=zC(go,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn);return Oo!==js&&vp(Au(),go,s,Oo,xi,Nr),Qb}function qS(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo){const Ar=mr(),ma=GC(Ar,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr);return ma!==js&&vp(Au(),Ar,s,ma,go,Oo),qS}function KC(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo,Ar,ma){const oc=mr(),qu=qb(oc,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo);return qu!==js&&vp(Au(),oc,s,qu,Ar,ma),KC}function k_(s,l,d,h){const w=mr(),L=Gf(w,l);return L!==js&&vp(Au(),w,s,L,d,h),k_}function N(s,l){return s<<17|l<<2}function $(s){return s>>17&32767}function Lt(s){return 2|s}function bn(s){return(131068&s)>>2}function ui(s,l){return-131069&s|l<<2}function yr(s){return 1|s}function os(s,l,d,h){const w=s[d+1],L=null===l;let z=h?$(w):bn(w),ae=!1;for(;0!==z&&(!1===ae||L);){const qe=s[z+1];gl(s[z],l)&&(ae=!0,s[z+1]=h?yr(qe):Lt(qe)),z=h?$(qe):bn(qe)}ae&&(s[d+1]=h?Lt(w):yr(w))}function gl(s,l){return null===s||null==l||(Array.isArray(s)?s[1]:s)===l||!(!Array.isArray(s)||"string"!=typeof l)&&oi(s,l)>=0}const Xs={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function il(s){return s.substring(Xs.key,Xs.keyEnd)}function Da(s){return s.substring(Xs.value,Xs.valueEnd)}function zd(s,l){const d=Xs.textEnd;return d===l?-1:(l=Xs.keyEnd=function Yb(s,l,d){for(;l<d&&s.charCodeAt(l)>32;)l++;return l}(s,Xs.key=l,d),Cp(s,l,d))}function Ef(s,l){const d=Xs.textEnd;let h=Xs.key=Cp(s,l,d);return d===h?-1:(h=Xs.keyEnd=function Em(s,l,d){let h;for(;l<d&&(45===(h=s.charCodeAt(l))||95===h||(-33&h)>=65&&(-33&h)<=90||h>=48&&h<=57);)l++;return l}(s,h,d),h=AT(s,h,d),h=Xs.value=Cp(s,h,d),h=Xs.valueEnd=function dO(s,l,d){let h=-1,w=-1,L=-1,z=l,ae=z;for(;z<d;){const xe=s.charCodeAt(z++);if(59===xe)return ae;34===xe||39===xe?ae=z=nI(s,xe,z,d):l===z-4&&85===L&&82===w&&76===h&&40===xe?ae=z=nI(s,41,z,d):xe>32&&(ae=z),L=w,w=h,h=-33&xe}return ae}(s,h,d),AT(s,h,d))}function df(s){Xs.key=0,Xs.keyEnd=0,Xs.value=0,Xs.valueEnd=0,Xs.textEnd=s.length}function Cp(s,l,d){for(;l<d&&s.charCodeAt(l)<=32;)l++;return l}function AT(s,l,d,h){return(l=Cp(s,l,d))<d&&l++,l}function nI(s,l,d,h){let w=-1,L=d;for(;L<h;){const z=s.charCodeAt(L++);if(z==l&&92!==w)return L;w=92==z&&92===w?0:z}throw new Error}function iI(s,l,d){const h=mr();return $e(h,Fp(),l)&&Uf(Ua(),Au(),h,s,l,h[Ss],d,!1),iI}function Ww(s,l,d,h,w){const z=w?"class":"style";nv(s,d,l.inputs[z],z,h)}function Xb(s,l,d){return yv(s,l,d,!1),Xb}function Dp(s,l){return yv(s,l,null,!0),Dp}function zc(s){Ha(mO,fO,s,!1)}function fO(s,l){for(let d=function Sm(s){return df(s),Ef(s,Cp(s,0,Xs.textEnd))}(l);d>=0;d=Ef(l,d))mO(s,il(l),Da(l))}function QS(s){Ha(BN,gg,s,!0)}function gg(s,l){for(let d=function fd(s){return df(s),zd(s,Cp(s,0,Xs.textEnd))}(l);d>=0;d=zd(l,d))rn(s,il(l),!0)}function yv(s,l,d,h){const w=mr(),L=Ua(),z=Eg(2);L.firstUpdatePass&&hO(L,s,z,h),l!==js&&$e(w,z,l)&&gO(L,L.data[Vd()],w,w[Ss],s,w[z+1]=function VN(s,l){return null==s||""===s||("string"==typeof l?s+=l:"object"==typeof s&&(s=ai(Pp(s)))),s}(l,d),h,z)}function Ha(s,l,d,h){const w=Ua(),L=Eg(2);w.firstUpdatePass&&hO(w,null,L,h);const z=mr();if(d!==js&&$e(z,L,d)){const ae=w.data[Vd()];if(PA(ae,h)&&!pO(w,L)){let xe=h?ae.classesWithoutHost:ae.stylesWithoutHost;null!==xe&&(d=so(xe,d||"")),Ww(w,ae,z,d,h)}else!function oI(s,l,d,h,w,L,z,ae){w===js&&(w=Zo);let xe=0,qe=0,ft=0<w.length?w[0]:null,Xt=0<L.length?L[0]:null;for(;null!==ft||null!==Xt;){const Ln=xe<w.length?w[xe+1]:void 0,zn=qe<L.length?L[qe+1]:void 0;let Nr,xi=null;ft===Xt?(xe+=2,qe+=2,Ln!==zn&&(xi=Xt,Nr=zn)):null===Xt||null!==ft&&ft<Xt?(xe+=2,xi=ft):(qe+=2,xi=Xt,Nr=zn),null!==xi&&gO(s,l,d,h,xi,Nr,z,ae),ft=xe<w.length?w[xe]:null,Xt=qe<L.length?L[qe]:null}}(w,ae,z,z[Ss],z[L+1],z[L+1]=function LA(s,l,d){if(null==d||""===d)return Zo;const h=[],w=Pp(d);if(Array.isArray(w))for(let L=0;L<w.length;L++)s(h,w[L],!0);else if("object"==typeof w)for(const L in w)w.hasOwnProperty(L)&&s(h,L,w[L]);else"string"==typeof w&&l(h,w);return h}(s,l,d),h,L)}}function pO(s,l){return l>=s.expandoStartIndex}function hO(s,l,d,h){const w=s.data;if(null===w[d+1]){const L=w[Vd()],z=pO(s,d);PA(L,h)&&null===l&&!z&&(l=!1),l=function LN(s,l,d,h){const w=dD(s);let L=h?l.residualClasses:l.residualStyles;if(null===w)0===(h?l.classBindings:l.styleBindings)&&(d=OT(d=rI(null,s,l,d,h),l.attrs,h),L=null);else{const z=l.directiveStylingLast;if(-1===z||s[z]!==w)if(d=rI(w,s,l,d,h),null===L){let xe=function kN(s,l,d){const h=d?l.classBindings:l.styleBindings;if(0!==bn(h))return s[$(h)]}(s,l,h);void 0!==xe&&Array.isArray(xe)&&(xe=rI(null,s,l,xe[1],h),xe=OT(xe,l.attrs,h),function PN(s,l,d,h){s[$(d?l.classBindings:l.styleBindings)]=h}(s,l,h,xe))}else L=function Hw(s,l,d){let h;const w=l.directiveEnd;for(let L=1+l.directiveStylingLast;L<w;L++)h=OT(h,s[L].hostAttrs,d);return OT(h,l.attrs,d)}(s,l,h)}return void 0!==L&&(h?l.residualClasses=L:l.residualStyles=L),d}(w,L,l,h),function Do(s,l,d,h,w,L){let z=L?l.classBindings:l.styleBindings,ae=$(z),xe=bn(z);s[h]=d;let ft,qe=!1;if(Array.isArray(d)?(ft=d[1],(null===ft||oi(d,ft)>0)&&(qe=!0)):ft=d,w)if(0!==xe){const Ln=$(s[ae+1]);s[h+1]=N(Ln,ae),0!==Ln&&(s[Ln+1]=ui(s[Ln+1],h)),s[ae+1]=function nt(s,l){return 131071&s|l<<17}(s[ae+1],h)}else s[h+1]=N(ae,0),0!==ae&&(s[ae+1]=ui(s[ae+1],h)),ae=h;else s[h+1]=N(xe,0),0===ae?ae=h:s[xe+1]=ui(s[xe+1],h),xe=h;qe&&(s[h+1]=Lt(s[h+1])),os(s,ft,h,!0),os(s,ft,h,!1),function Ts(s,l,d,h,w){const L=w?s.residualClasses:s.residualStyles;null!=L&&"string"==typeof l&&oi(L,l)>=0&&(d[h+1]=yr(d[h+1]))}(l,ft,s,h,L),z=N(ae,xe),L?l.classBindings=z:l.styleBindings=z}(w,L,l,d,z,h)}}function rI(s,l,d,h,w){let L=null;const z=d.directiveEnd;let ae=d.directiveStylingLast;for(-1===ae?ae=d.directiveStart:ae++;ae<z&&(L=l[ae],h=OT(h,L.hostAttrs,w),L!==s);)ae++;return null!==s&&(d.directiveStylingLast=ae),h}function OT(s,l,d){const h=d?1:2;let w=-1;if(null!==l)for(let L=0;L<l.length;L++){const z=l[L];"number"==typeof z?w=z:w===h&&(Array.isArray(s)||(s=void 0===s?[]:["",s]),rn(s,z,!!d||l[++L]))}return void 0===s?null:s}function mO(s,l,d){rn(s,l,Pp(d))}function BN(s,l,d){const h=String(l);""!==h&&!h.includes(" ")&&rn(s,h,d)}function gO(s,l,d,h,w,L,z,ae){if(!(3&l.type))return;const xe=s.data,qe=xe[ae+1],ft=function Hi(s){return!(1&~s)}(qe)?kA(xe,l,d,w,bn(qe),z):void 0;FT(ft)||(FT(L)||function ge(s){return!(2&~s)}(qe)&&(L=kA(xe,null,d,w,ae,z)),function oS(s,l,d,h,w){if(l)w?s.addClass(d,h):s.removeClass(d,h);else{let L=-1===h.indexOf("-")?void 0:$1.DashCase;null==w?s.removeStyle(d,h,L):("string"==typeof w&&w.endsWith("!important")&&(w=w.slice(0,-10),L|=$1.Important),s.setStyle(d,h,w,L))}}(h,z,Tr(Vd(),d),w,L))}function kA(s,l,d,h,w,L){const z=null===l;let ae;for(;w>0;){const xe=s[w],qe=Array.isArray(xe),ft=qe?xe[1]:xe,Xt=null===ft;let Ln=d[w+1];Ln===js&&(Ln=Xt?Zo:void 0);let zn=Xt?Si(Ln,h):ft===h?Ln:void 0;if(qe&&!FT(zn)&&(zn=Si(xe,h)),FT(zn)&&(ae=zn,z))return ae;const xi=s[w+1];w=z?$(xi):bn(xi)}if(null!==l){let xe=L?l.residualClasses:l.residualStyles;null!=xe&&(ae=Si(xe,h))}return ae}function FT(s){return void 0!==s}function PA(s,l){return!!(s.flags&(l?8:16))}function qp(s,l,d){Ha(rn,gg,$C(mr(),s,l,d),!0)}function _h(s,l,d,h,w){Ha(rn,gg,WC(mr(),s,l,d,h,w),!0)}function sI(s,l,d,h,w,L,z){Ha(rn,gg,_v(mr(),s,l,d,h,w,L,z),!0)}function vO(s,l,d,h,w,L,z,ae,xe){Ha(rn,gg,Kp(mr(),s,l,d,h,w,L,z,ae,xe),!0)}function BA(s,l,d,h,w,L,z,ae,xe,qe,ft){Ha(rn,gg,HC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft),!0)}function _O(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){Ha(rn,gg,zC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln),!0)}function VA(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi){Ha(rn,gg,GC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi),!0)}function Gc(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go){Ha(rn,gg,qb(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go),!0)}function yO(s){Ha(rn,gg,Gf(mr(),s),!0)}function bO(){return mr()[Gl][Ja]}class aI{destroy(l){}updateValue(l,d){}swap(l,d){const h=Math.min(l,d),w=Math.max(l,d),L=this.detach(w);if(w-h>1){const z=this.detach(h);this.attach(h,L),this.attach(w,z)}else this.attach(h,L)}move(l,d){this.attach(d,this.detach(l))}}function jA(s,l,d,h,w){return s===d&&Object.is(l,h)?1:Object.is(w(s,l),w(d,h))?-1:0}function NT(s,l,d,h){return!(void 0===l||!l.has(h)||(s.attach(d,l.get(h)),l.delete(h),0))}function CO(s,l,d,h,w){if(NT(s,l,h,d(h,w)))s.updateValue(h,w);else{const L=s.create(h,w);s.attach(h,L)}}function RT(s,l,d,h){const w=new Set;for(let L=l;L<=d;L++)w.add(h(L,s.at(L)));return w}class DO{constructor(){this.kvMap=new Map,this._vMap=void 0}has(l){return this.kvMap.has(l)}delete(l){if(!this.has(l))return!1;const d=this.kvMap.get(l);return void 0!==this._vMap&&this._vMap.has(d)?(this.kvMap.set(l,this._vMap.get(d)),this._vMap.delete(d)):this.kvMap.delete(l),!0}get(l){return this.kvMap.get(l)}set(l,d){if(this.kvMap.has(l)){let h=this.kvMap.get(l);void 0===this._vMap&&(this._vMap=new Map);const w=this._vMap;for(;w.has(h);)h=w.get(h);w.set(h,d)}else this.kvMap.set(l,d)}forEach(l){for(let[d,h]of this.kvMap)if(l(h,d),void 0!==this._vMap){const w=this._vMap;for(;w.has(h);)h=w.get(h),l(h,d)}}}function lI(s,l){dd("NgControlFlow");const d=mr(),h=Fp(),w=d[h]!==js?d[h]:-1,L=-1!==w?uI(d,Xe+w):void 0;if($e(d,h,s)){const ae=Q(null);try{if(void 0!==L&&Ay(L,0),-1!==s){const xe=Xe+s,qe=uI(d,xe),ft=LT(d[io],xe),Xt=_m(qe,ft.tView.ssrId);eg(qe,Iy(d,ft,l,{dehydratedView:Xt}),0,Jm(ft,Xt))}}finally{Q(ae)}}else if(void 0!==L){const ae=u_(L,0);void 0!==ae&&(ae[Ja]=l)}}class P_{constructor(l,d,h){this.lContainer=l,this.$implicit=d,this.$index=h}get $count(){return this.lContainer.length-Gr}}function wO(s){return s}function xO(s,l){return l}class SO{constructor(l,d,h){this.hasEmptyBlock=l,this.trackByFn=d,this.liveCollection=h}}function cI(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){dd("NgControlFlow");const zn=mr(),xi=Ua(),Nr=void 0!==xe,go=mr(),Oo=ae?z.bind(go[Gl][Ja]):z,Ar=new SO(Nr,Oo);go[Xe+s]=Ar,pr(zn,xi,s+1,l,d,h,w,vf(xi.consts,L)),Nr&&pr(zn,xi,s+2,xe,qe,ft,Xt,vf(xi.consts,Ln))}class EO extends aI{constructor(l,d,h){super(),this.lContainer=l,this.hostLView=d,this.templateTNode=h,this.operationsCounter=void 0,this.needsIndexUpdate=!1}get length(){return this.lContainer.length-Gr}at(l){return this.getLView(l)[Ja].$implicit}attach(l,d){const h=d[ra];this.needsIndexUpdate||=l!==this.length,eg(this.lContainer,d,l,Jm(this.templateTNode,h))}detach(l){return this.needsIndexUpdate||=l!==this.length-1,function WN(s,l){return jf(s,l)}(this.lContainer,l)}create(l,d){const h=_m(this.lContainer,this.templateTNode.tView.ssrId),w=Iy(this.hostLView,this.templateTNode,new P_(this.lContainer,d,l),{dehydratedView:h});return this.operationsCounter?.recordCreate(),w}destroy(l){G1(l[io],l),this.operationsCounter?.recordDestroy()}updateValue(l,d){this.getLView(l)[Ja].$implicit=d}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}updateIndexes(){if(this.needsIndexUpdate)for(let l=0;l<this.length;l++)this.getLView(l)[Ja].$index=l}getLView(l){return function HN(s,l){return u_(s,l)}(this.lContainer,l)}}function TO(s){const l=Q(null),d=Vd();try{const h=mr(),w=h[io],L=h[d],z=d+1,ae=uI(h,z);if(void 0===L.liveCollection){const qe=LT(w,z);L.liveCollection=new EO(ae,h,qe)}else L.liveCollection.reset();const xe=L.liveCollection;if(function vg(s,l,d){let h,w,L=0,z=s.length-1;if(Array.isArray(l)){let xe=l.length-1;for(;L<=z&&L<=xe;){const qe=s.at(L),ft=l[L],Xt=jA(L,qe,L,ft,d);if(0!==Xt){Xt<0&&s.updateValue(L,ft),L++;continue}const Ln=s.at(z),zn=l[xe],xi=jA(z,Ln,xe,zn,d);if(0!==xi){xi<0&&s.updateValue(z,zn),z--,xe--;continue}const Nr=d(L,qe),go=d(z,Ln),Oo=d(L,ft);if(Object.is(Oo,go)){const Ar=d(xe,zn);Object.is(Ar,Nr)?(s.swap(L,z),s.updateValue(z,zn),xe--,z--):s.move(z,L),s.updateValue(L,ft),L++}else if(h??=new DO,w??=RT(s,L,z,d),NT(s,h,L,Oo))s.updateValue(L,ft),L++,z++;else if(w.has(Oo))h.set(Nr,s.detach(L)),z--;else{const Ar=s.create(L,l[L]);s.attach(L,Ar),L++,z++}}for(;L<=xe;)CO(s,h,d,L,l[L]),L++}else if(null!=l){const xe=l[Symbol.iterator]();let qe=xe.next();for(;!qe.done&&L<=z;){const ft=s.at(L),Xt=qe.value,Ln=jA(L,ft,L,Xt,d);if(0!==Ln)Ln<0&&s.updateValue(L,Xt),L++,qe=xe.next();else{h??=new DO,w??=RT(s,L,z,d);const zn=d(L,Xt);if(NT(s,h,L,zn))s.updateValue(L,Xt),L++,z++,qe=xe.next();else if(w.has(zn)){const xi=d(L,ft);h.set(xi,s.detach(L)),z--}else s.attach(L,s.create(L,Xt)),L++,z++,qe=xe.next()}}for(;!qe.done;)CO(s,h,d,s.length,qe.value),qe=xe.next()}for(;L<=z;)s.destroy(s.detach(z--));h?.forEach(xe=>{s.destroy(xe)})}(xe,s,L.trackByFn),xe.updateIndexes(),L.hasEmptyBlock){const qe=Fp(),ft=0===xe.length;if($e(h,qe,ft)){const Xt=d+2,Ln=uI(h,Xt);if(ft){const zn=LT(w,Xt),xi=_m(Ln,zn.tView.ssrId);eg(Ln,Iy(h,zn,void 0,{dehydratedView:xi}),0,Jm(zn,xi))}else Ay(Ln,0)}}}finally{Q(l)}}function uI(s,l){return s[l]}function LT(s,l){return ka(s,l)}function dI(s,l,d,h){const w=mr(),L=Ua(),z=Xe+s,ae=w[Ss],xe=L.firstCreatePass?function zN(s,l,d,h,w,L){const z=l.consts,xe=gm(l,s,2,h,vf(z,w));return Tl(l,d,xe,vf(z,L)),null!==xe.attrs&&Wc(xe,xe.attrs,!1),null!==xe.mergedAttrs&&Wc(xe,xe.mergedAttrs,!0),null!==l.queries&&l.queries.elementStart(l,xe),xe}(z,L,w,l,d,h):L.data[z],qe=zw(L,w,xe,ae,l,s);w[z]=qe;const ft=Ga(xe);return Ih(xe,!0),a_(ae,qe,xe),!yn(xe)&&Rv()&&Q1(L,w,qe,xe),0===function nD(){return Ho.lFrame.elementDepthCount}()&&rf(qe,w),function iD(){Ho.lFrame.elementDepthCount++}(),ft&&(hb(L,w,xe),Cy(L,xe,w)),null!==h&&Dy(w,xe),dI}function fI(){let s=Pl();sD()?aD():(s=s.parent,Ih(s,!1));const l=s;(function rD(s){return Ho.skipHydrationRootTNode===s})(l)&&function M0(){Ho.skipHydrationRootTNode=null}(),function T0(){Ho.lFrame.elementDepthCount--}();const d=Ua();return d.firstCreatePass&&(hD(d,s),gu(s)&&d.queries.elementEnd(s)),null!=l.classesWithoutHost&&function DM(s){return!!(8&s.flags)}(l)&&Ww(d,l,mr(),l.classesWithoutHost,!0),null!=l.stylesWithoutHost&&function vx(s){return!!(16&s.flags)}(l)&&Ww(d,l,mr(),l.stylesWithoutHost,!1),fI}function UA(s,l,d,h){return dI(s,l,d,h),fI(),UA}let zw=(s,l,d,h,w,L)=>(jm(!0),ab(h,w,c1()));function GN(s,l,d,h,w,L){const z=l[ra],ae=!z||Sg()||yn(d)||e_(z,L);if(jm(ae),ae)return ab(h,w,c1());const xe=Tb(z,s,l,d);return eu(z,L)&&np(z,L,xe.nextSibling),z&&(H0(d)||ED(xe))&&Zl(d)&&(function Ap(s){Ho.skipHydrationRootTNode=s}(d),nw(xe)),xe}function m0(s,l,d){const h=mr(),w=Ua(),L=s+Xe,z=w.firstCreatePass?function MO(s,l,d,h,w){const L=l.consts,z=vf(L,h),ae=gm(l,s,8,"ng-container",z);return null!==z&&Wc(ae,z,!0),Tl(l,d,ae,vf(L,w)),null!==l.queries&&l.queries.elementStart(l,ae),ae}(L,w,h,l,d):w.data[L];Ih(z,!0);const ae=Gw(w,h,z,s);return h[L]=ae,Rv()&&Q1(w,h,ae,z),rf(ae,h),Ga(z)&&(hb(w,h,z),Cy(w,z,h)),null!=d&&Dy(h,z),m0}function pI(){let s=Pl();const l=Ua();return sD()?aD():(s=s.parent,Ih(s,!1)),l.firstCreatePass&&(hD(l,s),gu(s)&&l.queries.elementEnd(s)),pI}function hI(s,l,d){return m0(s,l,d),pI(),hI}let Gw=(s,l,d,h)=>(jm(!0),sb(l[Ss],""));function IO(s,l,d,h){let w;const L=l[ra],z=!L||Sg()||e_(L,h)||yn(d);if(jm(z),z)return sb(l[Ss],"");const ae=Tb(L,s,l,d),xe=PD(L,h);return np(L,h,ae),w=gw(xe,ae),w}function $A(){return mr()}function g0(s,l,d){const h=mr();return $e(h,Fp(),l)&&Uf(Ua(),Au(),h,s,l,h[Ss],d,!0),g0}function kT(s,l,d){const h=mr();if($e(h,Fp(),l)){const L=Ua(),z=Au();Uf(L,z,h,s,l,tC(dD(L.data),z,h),d,!0)}return kT}const Kw=void 0;var mI=["en",[["a","p"],["AM","PM"],Kw],[["AM","PM"],Kw,Kw],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],Kw,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],Kw,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",Kw,"{1} 'at' {0}",Kw],[".",",",";","%","+","-","E","\xd7","\u2030","\u221e","NaN",":"],["#,##0.###","#,##0%","\xa4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",function bv(s){const d=Math.floor(Math.abs(s)),h=s.toString().replace(/^[^.]*\.?/,"").length;return 1===d&&0===h?1:5}];let qC={};function qN(s,l,d){"string"!=typeof l&&(d=l,l=s[YS.LocaleId]),l=l.toLowerCase().replace(/_/g,"-"),qC[l]=s,d&&(qC[l][YS.ExtraData]=d)}function Ta(s){const l=function zA(s){return s.toLowerCase().replace(/_/g,"-")}(s);let d=HA(l);if(d)return d;const h=l.split("-")[0];if(d=HA(h),d)return d;if("en"===h)return mI;throw new po(701,!1)}function QN(s){return Ta(s)[YS.CurrencyCode]||null}function WA(s){return Ta(s)[YS.PluralCase]}function HA(s){return s in qC||(qC[s]=vi.ng&&vi.ng.common&&vi.ng.common.locales&&vi.ng.common.locales[s]),qC[s]}function YN(){qC={}}var YS=function(s){return s[s.LocaleId=0]="LocaleId",s[s.DayPeriodsFormat=1]="DayPeriodsFormat",s[s.DayPeriodsStandalone=2]="DayPeriodsStandalone",s[s.DaysFormat=3]="DaysFormat",s[s.DaysStandalone=4]="DaysStandalone",s[s.MonthsFormat=5]="MonthsFormat",s[s.MonthsStandalone=6]="MonthsStandalone",s[s.Eras=7]="Eras",s[s.FirstDayOfWeek=8]="FirstDayOfWeek",s[s.WeekendRange=9]="WeekendRange",s[s.DateFormat=10]="DateFormat",s[s.TimeFormat=11]="TimeFormat",s[s.DateTimeFormat=12]="DateTimeFormat",s[s.NumberSymbols=13]="NumberSymbols",s[s.NumberFormats=14]="NumberFormats",s[s.CurrencyCode=15]="CurrencyCode",s[s.CurrencySymbol=16]="CurrencySymbol",s[s.CurrencyName=17]="CurrencyName",s[s.Currencies=18]="Currencies",s[s.Directionality=19]="Directionality",s[s.PluralCase=20]="PluralCase",s[s.ExtraData=21]="ExtraData",s}(YS||{});const XN=["zero","one","two","few","many"],PT="en-US",gI={marker:"element"},vI={marker:"ICU"};var Tm=function(s){return s[s.SHIFT=2]="SHIFT",s[s.APPEND_EAGERLY=1]="APPEND_EAGERLY",s[s.COMMENT=2]="COMMENT",s}(Tm||{});let GA=PT;function _I(s){"string"==typeof s&&(GA=s.toLowerCase().replace(/_/g,"-"))}let XS=0,ZS=0;function KA(s,l,d){const h=s[Ss];switch(d){case Node.COMMENT_NODE:return sb(h,l);case Node.TEXT_NODE:return qD(h,l);case Node.ELEMENT_NODE:return ab(h,l,null)}}let JS=(s,l,d,h)=>(jm(!0),KA(s,d,h));function OO(s,l,d,h){const w=s[ra],L=l-Xe,z=!ES()||!w||Sg()||e_(w,L);return jm(z),z?KA(s,d,h):$h(w,L)}function qA(s,l,d,h){const w=d[Ss];let z,L=null;for(let ae=0;ae<l.length;ae++){const xe=l[ae];if("string"==typeof xe){const qe=l[++ae];null===d[qe]&&(d[qe]=JS(d,qe,xe,Node.TEXT_NODE))}else if("number"==typeof xe)switch(1&xe){case 0:const qe=fC(xe);let ft,Xt;if(null===L&&(L=qe,z=s_(w,h)),qe===L?(ft=h,Xt=z):(ft=null,Xt=Qa(d[qe])),null!==Xt){const Nr=pC(xe);Vp(w,Xt,d[Nr],ft,!1);const Oo=m_(s,Nr);if(null!==Oo&&"object"==typeof Oo){const Ar=ig(Oo,d);null!==Ar&&qA(s,Oo.create[Ar],d,d[Oo.anchorIdx])}}break;case 1:const zn=l[++ae],xi=l[++ae];Uh(w,Tr(xe>>>1,d),null,null,zn,xi,null)}else switch(xe){case vI:const qe=l[++ae],ft=l[++ae];null===d[ft]&&rf(d[ft]=JS(d,ft,qe,Node.COMMENT_NODE),d);break;case gI:const Xt=l[++ae],Ln=l[++ae];null===d[Ln]&&rf(d[Ln]=JS(d,Ln,Xt,Node.ELEMENT_NODE),d)}}}function FO(s,l,d,h,w){for(let L=0;L<d.length;L++){const z=d[L],ae=d[++L];if(z&w){let xe="";for(let qe=L+1;qe<=L+ae;qe++){const ft=d[qe];if("string"==typeof ft)xe+=ft;else if("number"==typeof ft)if(ft<0)xe+=Is(l[h-ft]);else{const Xt=ft>>>2;switch(3&ft){case 1:const Ln=d[++qe],zn=d[++qe],xi=s.data[Xt];"string"==typeof xi?Uh(l[Ss],l[Xt],null,xi,Ln,xe,zn):Uf(s,xi,l,Ln,xe,l[Ss],zn,!1);break;case 0:const Nr=l[Xt];null!==Nr&&W1(l[Ss],Nr,xe);break;case 2:oR(s,m_(s,Xt),l,xe);break;case 3:NO(s,m_(s,Xt),h,l)}}}}else{const xe=d[L+1];if(xe>0&&!(3&~xe)){const ft=m_(s,xe>>>2);l[ft.currentCaseLViewIndex]<0&&NO(s,ft,h,l)}}L+=ae}}function NO(s,l,d,h){let w=h[l.currentCaseLViewIndex];if(null!==w){let L=XS;w<0&&(w=h[l.currentCaseLViewIndex]=~w,L=-1),FO(s,h,l.update[w],d,L)}}function oR(s,l,d,h){const w=function sR(s,l){let d=s.cases.indexOf(l);if(-1===d)switch(s.type){case 1:{const h=function ZN(s,l){const d=WA(l)(parseInt(s,10)),h=XN[d];return void 0!==h?h:"other"}(l,function eR(){return GA}());d=s.cases.indexOf(h),-1===d&&"other"!==h&&(d=s.cases.indexOf("other"));break}case 0:d=s.cases.indexOf("other")}return-1===d?null:d}(l,h);if(ig(l,d)!==w&&(RO(s,l,d),d[l.currentCaseLViewIndex]=null===w?null:~w,null!==w)){const z=d[l.anchorIdx];z&&qA(s,l.create[w],d,z),function Vy(s,l,d){_T(s,l,d)}(d,l.anchorIdx,w)}}function RO(s,l,d){let h=ig(l,d);if(null!==h){const w=l.remove[h];for(let L=0;L<w.length;L++){const z=w[L];if(z>0){const ae=Tr(z,d);null!==ae&&ub(d[Ss],ae)}else RO(s,m_(s,~z),d)}}}const yI=/\ufffd(\d+):?\d*\ufffd/gi,aR=/({\s*\ufffd\d+:?\d*\ufffd\s*,\s*\S{6}\s*,[\s\S]*})/gi,lR=/\ufffd(\d+)\ufffd/,Kf=/^\s*(\ufffd\d+:?\d*\ufffd)\s*,\s*(select|plural)\s*,/,eE="\ufffd",BT=/\ufffd\/?\*(\d+:\d+)\ufffd/gi,cR=/\ufffd(\/?[#*]\d+):?\d*\ufffd/gi,kO=/\uE500/g;function PO(s,l,d,h,w,L,z){const ae=pb(s,h,1,null);let xe=ae<<Tm.SHIFT,qe=fa();l===qe&&(qe=null),null===qe&&(xe|=Tm.APPEND_EAGERLY),z&&(xe|=Tm.COMMENT,function af(s){void 0===KD&&(KD=s())}(uT)),w.push(xe,null===L?"":L);const ft=fb(s,ae,z?32:1,null===L?"":L,null);Ly(d,ft);const Xt=ft.index;return Ih(ft,!1),null!==qe&&l!==qe&&function mw(s,l){let d=s.insertBeforeIndex;null===d?(yy(yS,h_),d=s.insertBeforeIndex=[null,l]):(function zs(s,l,d){s!=l&&Di(d,s,l,"==")}(Array.isArray(d),!0,"Expecting array here"),d.push(l))}(qe,Xt),ft}function pR(s,l,d,h,w,L,z,ae){const xe=ae.match(yI),ft=PO(l,d,h,z,w,xe?null:ae,!1).index;xe&&tE(L,ae,ft,null,0,null),s.push({kind:0,index:ft})}function tE(s,l,d,h,w,L){const z=s.length,ae=z+1;s.push(null,null);const xe=z+2,qe=l.split(yI);let ft=0;for(let Xt=0;Xt<qe.length;Xt++){const Ln=qe[Xt];if(1&Xt){const zn=w+parseInt(Ln,10);s.push(-1-zn),ft|=VO(zn)}else""!==Ln&&s.push(Ln)}return s.push(d<<2|(h?1:0)),h&&s.push(h,L),s[z]=ft,s[ae]=s.length-xe,ft}function BO(s){let l=0;for(let d=0;d<s.length;d++){const h=s[d];"number"==typeof h&&h<0&&l++}return l}function VO(s){return 1<<Math.min(s,31)}function jO(s){let l,L,d="",h=0,w=!1;for(;null!==(l=BT.exec(s));)w?l[0]===`${eE}/*${L}${eE}`&&(h=l.index,w=!1):(d+=s.substring(h,l.index+l[0].length),L=l[1],w=!0);return d+=s.slice(h),d}function UO(s,l,d,h,w,L,z){let ae=0;const xe={type:L.type,currentCaseLViewIndex:pb(l,d,1,null),anchorIdx:z,cases:[],create:[],remove:[],update:[]};(function gR(s,l,d){s.push(VO(l.mainBinding),2,-1-l.mainBinding,d<<2|2)})(h,L,z),function cT(s,l,d){const h=s.data[l];null===h?s.data[l]=d:h.value=d}(l,z,xe);const qe=L.values,ft=[];for(let Xt=0;Xt<qe.length;Xt++){const Ln=qe[Xt],zn=[];for(let Nr=0;Nr<Ln.length;Nr++){const go=Ln[Nr];if("string"!=typeof go){const Oo=zn.push(go)-1;Ln[Nr]=`\x3c!--\ufffd${Oo}\ufffd--\x3e`}}const xi=[];ft.push(xi),ae=$O(xi,l,xe,d,h,w,L.cases[Xt],Ln.join(""),zn)|ae}ae&&function vR(s,l,d){s.push(l,1,d<<2|3)}(h,ae,z),s.push({kind:3,index:z,cases:ft,currentCaseLViewIndex:xe.currentCaseLViewIndex})}function mR(s){const l=[],d=[];let h=1,w=0;const L=bI(s=s.replace(Kf,function(z,ae,xe){return h="select"===xe?0:1,w=parseInt(ae.slice(1),10),""}));for(let z=0;z<L.length;){let ae=L[z++].trim();1===h&&(ae=ae.replace(/\s*(?:=)?(\w+)\s*/,"$1")),ae.length&&l.push(ae);const xe=bI(L[z++]);l.length>d.length&&d.push(xe)}return{type:h,mainBinding:w,cases:l,values:d}}function bI(s){if(!s)return[];let l=0;const d=[],h=[],w=/[{}]/g;let L;for(w.lastIndex=0;L=w.exec(s);){const ae=L.index;if("}"==L[0]){if(d.pop(),0==d.length){const xe=s.substring(l,ae);Kf.test(xe)?h.push(mR(xe)):h.push(xe),l=ae+1}}else{if(0==d.length){const xe=s.substring(l,ae);h.push(xe),l=ae+1}d.push("{")}}const z=s.substring(l);return h.push(z),h}function $O(s,l,d,h,w,L,z,ae,xe){const qe=[],ft=[],Xt=[];d.cases.push(z),d.create.push(qe),d.remove.push(ft),d.update.push(Xt);const zn=jE(fp()).getInertBodyElement(ae),xi=Qx(zn)||zn;return xi?WO(s,l,d,h,w,qe,ft,Xt,xi,L,xe,0):0}function WO(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt){let Ln=0,zn=xe.firstChild;for(;zn;){const xi=pb(l,h,1,null);switch(zn.nodeType){case Node.ELEMENT_NODE:const Nr=zn,go=Nr.tagName.toLowerCase();if(Hd.hasOwnProperty(go)){YA(L,gI,go,qe,xi),l.data[xi]=go;const oc=Nr.attributes;for(let Gd=0;Gd<oc.length;Gd++){const qh=oc.item(Gd),dE=qh.name.toLowerCase();qh.value.match(yI)?Kx.hasOwnProperty(dE)&&tE(ae,qh.value,xi,qh.name,0,P1[dE]?i_:null):XA(L,xi,qh)}const qu={kind:1,index:xi,children:[]};s.push(qu),Ln=WO(qu.children,l,d,h,w,L,z,ae,zn,xi,ft,Xt+1)|Ln,HO(z,xi,Xt)}break;case Node.TEXT_NODE:const Oo=zn.textContent||"",Ar=Oo.match(yI);YA(L,null,Ar?"":Oo,qe,xi),HO(z,xi,Xt),Ar&&(Ln=tE(ae,Oo,xi,null,0,null)|Ln),s.push({kind:0,index:xi});break;case Node.COMMENT_NODE:const ma=lR.exec(zn.textContent||"");if(ma){const qu=ft[parseInt(ma[1],10)];YA(L,vI,"",qe,xi),UO(s,l,h,w,qe,qu,xi),zO(z,xi,Xt)}}zn=zn.nextSibling}return Ln}function HO(s,l,d){0===d&&s.push(l)}function zO(s,l,d){0===d&&(s.push(~l),s.push(l))}function YA(s,l,d,h,w){null!==l&&s.push(l),s.push(d,w,function bS(s,l,d){return s|l<<17|d<<1}(0,h,w))}function XA(s,l,d){s.push(l<<1|1,d.name,d.value)}const GO=0,KO=/\[(\ufffd.+?\ufffd?)\]/,_R=/\[(\ufffd.+?\ufffd?)\]|(\ufffd\/?\*\d+:\d+\ufffd)/g,yR=/({\s*)(VAR_(PLURAL|SELECT)(_\d+)?)(\s*,)/g,bR=/{([A-Z0-9_]+)}/g,CR=/\ufffdI18N_EXP_(ICU(_\d+)?)\ufffd/g,DR=/\/\*/,ZA=/\d+\:(\d+)/;function JA(s,l,d=-1){const h=Ua(),w=mr(),L=Xe+s,z=vf(h.consts,l),ae=fa();h.firstCreatePass&&function fR(s,l,d,h,w,L){const z=fa(),ae=[],xe=[],qe=[[]],ft=[[]];w=function QA(s,l){if(sv(l))return jO(s);{const d=s.indexOf(`:${l}${eE}`)+2+l.toString().length,h=s.search(new RegExp(`${eE}\\/\\*\\d+:${l}${eE}`));return jO(s.substring(d,h))}}(w,L);const Xt=function uR(s){return s.replace(kO," ")}(w).split(cR);for(let Ln=0;Ln<Xt.length;Ln++){let zn=Xt[Ln];if(1&Ln){const xi=47===zn.charCodeAt(0),Nr=zn.charCodeAt(xi?1:0),go=Xe+Number.parseInt(zn.substring(xi?2:1));if(xi)qe.shift(),ft.shift(),Ih(fa(),!1);else{const Oo=$p(s,qe[0],go);qe.unshift([]),Ih(Oo,!0);const Ar={kind:2,index:go,children:[],type:35===Nr?0:1};ft[0].push(Ar),ft.unshift(Ar.children)}}else{const xi=bI(zn);for(let Nr=0;Nr<xi.length;Nr++){let go=xi[Nr];if(1&Nr){const Oo=go;if("object"!=typeof Oo)throw new Error(`Unable to parse ICU expression in "${w}" message.`);const ma=PO(s,z,qe[0],d,ae,"",!0).index;UO(ft[0],s,d,xe,l,Oo,ma)}else""!==go&&pR(ft[0],s,z,qe[0],ae,xe,d,go)}}}s.data[h]={create:ae,update:xe,ast:ft[0],parentTNodeIndex:l}}(h,null===ae?0:ae.index,w,L,z,d),2===h.type?w[Gl][Ps]|=32:w[Ps]|=32;const xe=h.data[L],ft=QE(h,ae===w[nc]?null:ae,w),Xt=ae&&8&ae.type?w[ae.index]:null;(function mT(s,l,d,h){hT(s,l,d,h)})(w,L,ae,d),function rR(s,l,d,h){const w=s[Ss];for(let L=0;L<l.length;L++){const z=l[L++],qe=(z&Tm.APPEND_EAGERLY)===Tm.APPEND_EAGERLY,ft=z>>>Tm.SHIFT;let Xt=s[ft],Ln=!1;null===Xt&&(Xt=s[ft]=JS(s,ft,l[L],(z&Tm.COMMENT)===Tm.COMMENT?Node.COMMENT_NODE:Node.TEXT_NODE),Ln=Rv()),qe&&null!==d&&Ln&&Vp(w,d,Xt,h,!1)}}(w,xe.create,ft,Xt),uD(!0)}function CI(){uD(!1)}function QO(s,l,d){JA(s,l,d),CI()}function e2(s,l){const d=Ua(),h=vf(d.consts,l);!function hR(s,l,d){const w=Pl().index,L=[];if(s.firstCreatePass&&null===s.data[l]){for(let z=0;z<d.length;z+=2){const ae=d[z],xe=d[z+1];if(""!==xe){if(aR.test(xe))throw new Error(`ICU expressions are not supported in attributes. Message: "${xe}".`);tE(L,xe,w,ae,BO(L),null)}}s.data[l]=L}}(d,s+Xe,h)}function t2(s){return function tR(s){s&&(XS|=1<<Math.min(ZS,31)),ZS++}($e(mr(),Fp(),s)),t2}function YO(s){!function nR(s,l,d){if(ZS>0){const h=s.data[d];FO(s,l,Array.isArray(h)?h:h.update,_f()-ZS-1,XS)}XS=0,ZS=0}(Ua(),mr(),s+Xe)}function wR(s,l={}){return function qO(s,l={}){let d=s;if(KO.test(s)){const h={},w=[GO];d=d.replace(_R,(L,z,ae)=>{const xe=z||ae,qe=h[xe]||[];if(qe.length||(xe.split("|").forEach(Nr=>{const go=Nr.match(ZA),Oo=go?parseInt(go[1],10):GO,Ar=DR.test(Nr);qe.push([Oo,Ar,Nr])}),h[xe]=qe),!qe.length)throw new Error(`i18n postprocess: unmatched placeholder - ${xe}`);const ft=w[w.length-1];let Xt=0;for(let Nr=0;Nr<qe.length;Nr++)if(qe[Nr][0]===ft){Xt=Nr;break}const[Ln,zn,xi]=qe[Xt];return zn?w.pop():ft!==Ln&&w.push(Ln),qe.splice(Xt,1),xi})}return Object.keys(l).length&&(d=d.replace(yR,(h,w,L,z,ae,xe)=>l.hasOwnProperty(L)?`${w}${l[L]}${xe}`:h),d=d.replace(bR,(h,w)=>l.hasOwnProperty(w)?l[w]:h),d=d.replace(CR,(h,w)=>{if(l.hasOwnProperty(w)){const L=l[w];if(!L.length)throw new Error(`i18n postprocess: unmatched ICU - ${h} with key: ${w}`);return L.shift()}return h})),d}(s,l)}let xR=(s,l,d)=>{};function DI(s){xR=s}function VT(s,l,d,h){const w=mr(),L=Ua(),z=Pl();return nE(L,w,w[Ss],z,s,l,h),VT}function XO(s,l){const d=Pl(),h=mr(),w=Ua();return nE(w,h,tC(dD(w.data),d,h),d,s,l),XO}function nE(s,l,d,h,w,L,z){const ae=Ga(h),qe=s.firstCreatePass&&fS(s),ft=l[Ja],Xt=_b(l);let Ln=!0;if(3&h.type||z){const Nr=Vs(h,l),go=z?z(Nr):Nr,Oo=Xt.length,Ar=z?oc=>z(Qa(oc[h.index])):h.index;let ma=null;if(!z&&ae&&(ma=function n2(s,l,d,h){const w=s.cleanup;if(null!=w)for(let L=0;L<w.length-1;L+=2){const z=w[L];if(z===d&&w[L+1]===h){const ae=l[Rf],xe=w[L+2];return ae.length>xe?ae[xe]:null}"string"==typeof z&&(L+=2)}return null}(s,l,w,h.index)),null!==ma)(ma.__ngLastListenerFn__||ma).__ngNextListenerFn__=L,ma.__ngLastListenerFn__=L,Ln=!1;else{L=wI(h,l,ft,L),xR(Nr,w,L);const oc=d.listen(go,w,L);Xt.push(L,oc),qe&&qe.push(w,Ar,Oo,Oo+1)}}else L=wI(h,l,ft,L);const zn=h.outputs;let xi;if(Ln&&null!==zn&&(xi=zn[w])){const Nr=xi.length;if(Nr)for(let go=0;go<Nr;go+=2){const qu=l[xi[go]][xi[go+1]].subscribe(L),Gd=Xt.length;Xt.push(L,qu),qe&&qe.push(w,h.index,Gd,-(Gd+1))}}}function B_(s,l,d,h){const w=Q(null);try{return vu(6,l,d),!1!==d(h)}catch(L){return tv(s,L),!1}finally{vu(7,l,d),Q(w)}}function wI(s,l,d,h){return function w(L){if(L===Function)return h;aC(s.componentOffset>-1?tf(s.index,l):l,5);let ae=B_(l,d,h,L),xe=w.__ngNextListenerFn__;for(;xe;)ae=B_(l,d,xe,L)&&ae,xe=xe.__ngNextListenerFn__;return ae}}function jT(s=1){return function DE(s){return(Ho.lFrame.contextLView=Bm(s,Ho.lFrame.contextLView))[Ja]}(s)}function ZO(s,l){let d=null;const h=function mf(s){const l=s.attrs;if(null!=l){const d=l.indexOf(5);if(!(1&d))return l[d+1]}return null}(s);for(let w=0;w<l.length;w++){const L=l[w];if("*"!==L){if(null===h?bg(s,L,!0):Zc(h,L))return w}else d=w}return d}function SR(s){const l=mr()[Gl][nc];if(!l.projection){const h=l.projection=Ce(s?s.length:1,null),w=h.slice();let L=l.child;for(;null!==L;){if(128!==L.type){const z=s?ZO(L,s):0;null!==z&&(w[z]?w[z].projectionNext=L:h[z]=L,w[z]=L)}L=L.next}}}function ER(s,l=0,d,h,w,L){const z=mr(),ae=Ua(),xe=h?s+1:null;null!==xe&&pr(z,ae,xe,h,w,L,null,d);const qe=gm(ae,Xe+s,16,null,d||null);null===qe.projection&&(qe.projection=l),aD();const Xt=!z[ra]||Sg();null===z[Gl][nc].projection[qe.projection]&&null!==xe?function JO(s,l,d){const h=Xe+d,w=l.data[h],L=s[h],z=_m(L,w.tView.ssrId);eg(L,Iy(s,w,void 0,{dehydratedView:z}),0,Jm(w,z))}(z,ae,xe):Xt&&32&~qe.flags&&function db(s,l,d){XE(l[Ss],0,l,d,q1(s,d,l),YE(d.parent||l[nc],d,l))}(ae,z,qe)}function rc(s,l,d){return UT(s,"",l,"",d),rc}function UT(s,l,d,h,w){const L=mr(),z=$C(L,l,d,h);return z!==js&&Uf(Ua(),Au(),L,s,z,L[Ss],w,!1),UT}function eF(s,l,d,h,w,L,z){const ae=mr(),xe=WC(ae,l,d,h,w,L);return xe!==js&&Uf(Ua(),Au(),ae,s,xe,ae[Ss],z,!1),eF}function r2(s,l,d,h,w,L,z,ae,xe){const qe=mr(),ft=_v(qe,l,d,h,w,L,z,ae);return ft!==js&&Uf(Ua(),Au(),qe,s,ft,qe[Ss],xe,!1),r2}function xI(s,l,d,h,w,L,z,ae,xe,qe,ft){const Xt=mr(),Ln=Kp(Xt,l,d,h,w,L,z,ae,xe,qe);return Ln!==js&&Uf(Ua(),Au(),Xt,s,Ln,Xt[Ss],ft,!1),xI}function o2(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){const zn=mr(),xi=HC(zn,l,d,h,w,L,z,ae,xe,qe,ft,Xt);return xi!==js&&Uf(Ua(),Au(),zn,s,xi,zn[Ss],Ln,!1),o2}function iE(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi){const Nr=mr(),go=zC(Nr,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn);return go!==js&&Uf(Ua(),Au(),Nr,s,go,Nr[Ss],xi,!1),iE}function s2(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go){const Oo=mr(),Ar=GC(Oo,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr);return Ar!==js&&Uf(Ua(),Au(),Oo,s,Ar,Oo[Ss],go,!1),s2}function $T(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo,Ar){const ma=mr(),oc=qb(ma,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo);return oc!==js&&Uf(Ua(),Au(),ma,s,oc,ma[Ss],Ar,!1),$T}function WT(s,l,d){const h=mr(),w=Gf(h,l);return w!==js&&Uf(Ua(),Au(),h,s,w,h[Ss],d,!1),WT}function TR(s,l,d,h){Lb(s,l,d,h)}function SI(s,l,d){uu(s,l,d)}function EI(s){const l=mr(),d=Ua(),h=Ah();K_(h+1);const w=S_(d,h);if(s.dirty&&function oh(s){return!(4&~s[Ps])}(l)===!(2&~w.metadata.flags)){if(null===w.matches)s.reset([]);else{const L=Xy(l,h);s.reset(L,Nx),s.notifyOnChanges()}return!0}return!1}function MR(){return RS(mr(),Ah())}function HT(s,l,d,h,w){wC(l,Lb(s,d,h,w))}function zT(s,l,d,h){wC(s,uu(l,d,h))}function IR(s=1){K_(Ah()+s)}function rE(s,l,d,h){d>=s.data.length&&(s.data[d]=null,s.blueprint[d]=null),l[d]=h}function TI(s){return Lf(a1(),Xe+s)}function AR(s,l,d){zc($C(mr(),s,l,d))}function MI(s,l,d,h,w){zc(WC(mr(),s,l,d,h,w))}function II(s,l,d,h,w,L,z){zc(_v(mr(),s,l,d,h,w,L,z))}function a2(s,l,d,h,w,L,z,ae,xe){zc(Kp(mr(),s,l,d,h,w,L,z,ae,xe))}function QC(s,l,d,h,w,L,z,ae,xe,qe,ft){zc(HC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft))}function GT(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){zc(zC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln))}function AI(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi){zc(GC(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi))}function qw(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go){zc(qb(mr(),s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go))}function KT(s){zc(Gf(mr(),s))}function qT(s,l,d,h,w){return yv(s,$C(mr(),l,d,h),w,!1),qT}function QT(s,l,d,h,w,L,z){return yv(s,WC(mr(),l,d,h,w,L),z,!1),QT}function tF(s,l,d,h,w,L,z,ae,xe){return yv(s,_v(mr(),l,d,h,w,L,z,ae),xe,!1),tF}function nF(s,l,d,h,w,L,z,ae,xe,qe,ft){return yv(s,Kp(mr(),l,d,h,w,L,z,ae,xe,qe),ft,!1),nF}function YT(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){return yv(s,HC(mr(),l,d,h,w,L,z,ae,xe,qe,ft,Xt),Ln,!1),YT}function iF(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi){return yv(s,zC(mr(),l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn),xi,!1),iF}function rF(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go){return yv(s,GC(mr(),l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr),go,!1),rF}function XT(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo,Ar){return yv(s,qb(mr(),l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go,Oo),Ar,!1),XT}function Qw(s,l,d){return yv(s,Gf(mr(),l),d,!1),Qw}function l2(s,l=""){const d=mr(),h=Ua(),w=s+Xe,L=h.firstCreatePass?gm(h,w,1,l,null):h.data[w],z=OI(h,d,L,l,s);d[w]=z,Rv()&&Q1(h,d,z,L),Ih(L,!1)}let OI=(s,l,d,h,w)=>(jm(!0),qD(l[Ss],h));function OR(s,l,d,h,w){const L=l[ra],z=!L||Sg()||yn(d)||e_(L,w);return jm(z),z?qD(l[Ss],h):Tb(L,s,l,d)}function ZT(s){return Yw("",s,""),ZT}function Yw(s,l,d){const h=mr(),w=$C(h,s,l,d);return w!==js&&wf(h,Vd(),w),Yw}function c2(s,l,d,h,w){const L=mr(),z=WC(L,s,l,d,h,w);return z!==js&&wf(L,Vd(),z),c2}function JT(s,l,d,h,w,L,z){const ae=mr(),xe=_v(ae,s,l,d,h,w,L,z);return xe!==js&&wf(ae,Vd(),xe),JT}function yh(s,l,d,h,w,L,z,ae,xe){const qe=mr(),ft=Kp(qe,s,l,d,h,w,L,z,ae,xe);return ft!==js&&wf(qe,Vd(),ft),yh}function FI(s,l,d,h,w,L,z,ae,xe,qe,ft){const Xt=mr(),Ln=HC(Xt,s,l,d,h,w,L,z,ae,xe,qe,ft);return Ln!==js&&wf(Xt,Vd(),Ln),FI}function oE(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln){const zn=mr(),xi=zC(zn,s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln);return xi!==js&&wf(zn,Vd(),xi),oE}function u2(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi){const Nr=mr(),go=GC(Nr,s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi);return go!==js&&wf(Nr,Vd(),go),u2}function eM(s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go){const Oo=mr(),Ar=qb(Oo,s,l,d,h,w,L,z,ae,xe,qe,ft,Xt,Ln,zn,xi,Nr,go);return Ar!==js&&wf(Oo,Vd(),Ar),eM}function oF(s){const l=mr(),d=Gf(l,s);return d!==js&&wf(l,Vd(),d),oF}function tM(s,l,d){hv(l)&&(l=l());const h=mr();return $e(h,Fp(),l)&&Uf(Ua(),Au(),h,s,l,h[Ss],d,!1),tM}function FR(s,l){const d=hv(s);return d&&s.set(l),d}function nM(s,l){const d=mr(),h=Ua(),w=Pl();return nE(h,d,d[Ss],w,s,l),nM}const NR={};function sF(s){const l=Ua(),d=mr(),h=s+Xe;return Ih(gm(l,h,128,null,null),!1),rE(l,d,h,NR),sF}function NI(s){return dd("NgLet"),rE(Ua(),mr(),Vd(),s),s}function RI(s){const d=Lf(a1(),Xe+s);if(d===NR)throw new po(314,!1);return d}function iM(s,l,d,h,w){if(s=Vr(s),Array.isArray(s))for(let L=0;L<s.length;L++)iM(s[L],l,d,h,w);else{const L=Ua(),z=mr(),ae=Pl();let xe=Af(s)?s:Vr(s.provide);const qe=Md(s),ft=1048575&ae.providerIndexes,Xt=ae.directiveStart,Ln=ae.providerIndexes>>20;if(Af(s)||!s.multi){const zn=new O0(qe,w,Jg),xi=rM(xe,l,w?ft:ft+Ln,Xt);-1===xi?(ah(Pv(ae,z),L,xe),d2(L,s,l.length),l.push(xe),ae.directiveStart++,ae.directiveEnd++,w&&(ae.providerIndexes+=1048576),d.push(zn),z.push(zn)):(d[xi]=zn,z[xi]=zn)}else{const zn=rM(xe,l,ft+Ln,Xt),xi=rM(xe,l,ft,ft+Ln),go=xi>=0&&d[xi];if(w&&!go||!w&&!(zn>=0&&d[zn])){ah(Pv(ae,z),L,xe);const Oo=function aF(s,l,d,h,w){const L=new O0(s,d,Jg);return L.multi=[],L.index=l,L.componentProviders=0,RR(L,w,h&&!d),L}(w?Nk:Fk,d.length,w,h,qe);!w&&go&&(d[xi].providerFactory=Oo),d2(L,s,l.length,0),l.push(xe),ae.directiveStart++,ae.directiveEnd++,w&&(ae.providerIndexes+=1048576),d.push(Oo),z.push(Oo)}else d2(L,s,zn>-1?zn:xi,RR(d[w?xi:zn],qe,!w&&h));!w&&h&&go&&d[xi].componentProviders++}}}function d2(s,l,d,h){const w=Af(l),L=function _d(s){return!!s.useClass}(l);if(w||L){const xe=(L?Vr(l.useClass):l).prototype.ngOnDestroy;if(xe){const qe=s.destroyHooks||(s.destroyHooks=[]);if(!w&&l.multi){const ft=qe.indexOf(d);-1===ft?qe.push(d,[h,xe]):qe[ft+1].push(h,xe)}else qe.push(d,xe)}}}function RR(s,l,d){return d&&s.componentProviders++,s.multi.push(l)-1}function rM(s,l,d,h){for(let w=d;w<h;w++)if(l[w]===s)return w;return-1}function Fk(s,l,d,h){return Xw(this.multi,[])}function Nk(s,l,d,h){const w=this.multi;let L;if(this.providerFactory){const z=this.providerFactory.componentProviders,ae=ic(d,d[io],this.providerFactory.index,h);L=ae.slice(0,z),Xw(w,L);for(let xe=z;xe<ae.length;xe++)L.push(ae[xe])}else L=[],Xw(w,L);return L}function Xw(s,l){for(let d=0;d<s.length;d++)l.push((0,s[d])());return l}function oM(s,l=[]){return d=>{d.providersResolver=(h,w)=>function Ok(s,l,d){const h=Ua();if(h.firstCreatePass){const w=qa(s);iM(d,h.data,h.blueprint,w,!0),iM(l,h.data,h.blueprint,w,!1)}}(h,w?w(s):s,l)}}let LR=(()=>{class s{constructor(d){this._injector=d,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(d){if(!d.standalone)return null;if(!this.cachedInjectors.has(d)){const h=wh(0,d.type),w=h.length>0?Pw([h],this._injector,`Standalone[${d.type.name}]`):null;this.cachedInjectors.set(d,w)}return this.cachedInjectors.get(d)}ngOnDestroy(){try{for(const d of this.cachedInjectors.values())null!==d&&d.destroy()}finally{this.cachedInjectors.clear()}}static#e=this.\u0275prov=Ks({token:s,providedIn:"environment",factory:()=>new s(gi(Hu))})}return s})();function lF(s){dd("NgStandalone"),s.getStandaloneInjector=l=>l.get(LR).getOrCreateStandaloneInjector(s)}function f2(s,l,d){const h=s.\u0275cmp;h.directiveDefs=sp(l,!1),h.pipeDefs=sp(d,!0)}function kR(s,l){return Ke(()=>{const d=Qu(s,!0);d.declarations=p2(l.declarations||Zo),d.imports=p2(l.imports||Zo),d.exports=p2(l.exports||Zo),l.bootstrap&&(d.bootstrap=p2(l.bootstrap)),Hh.registerNgModule(s,l)})}function p2(s){if("function"==typeof s)return s;const l=Ut(s);return l.some(is)?()=>l.map(Vr).map(sM):l.map(sM)}function sM(s){return bu(s)?s.ngModule:s}const LI="__ngAsyncComponentMetadataFn__";function Rk(s){return s[LI]??null}function kI(s,l,d){const h=s;return h[LI]=()=>Promise.all(l()).then(w=>(d(...w),h[LI]=null,w)),h[LI]}function h2(s,l,d,h){return Ke(()=>{const w=s;null!==l&&(w.hasOwnProperty("decorators")&&void 0!==w.decorators?w.decorators.push(...l):w.decorators=l),null!==d&&(w.ctorParameters=d),null!==h&&(w.propDecorators=w.hasOwnProperty("propDecorators")&&void 0!==w.propDecorators?{...w.propDecorators,...h}:h)})}function PR(s,l,d){const h=nf()+s,w=mr();return w[h]===js?ye(w,h,d?l.call(d):l()):Ye(w,h)}function PI(s,l,d,h){return v2(mr(),nf(),s,l,d,h)}function m2(s,l,d,h,w){return lM(mr(),nf(),s,l,d,h,w)}function cF(s,l,d,h,w,L){return Qp(mr(),nf(),s,l,d,h,w,L)}function BI(s,l,d,h,w,L,z){return VR(mr(),nf(),s,l,d,h,w,L,z)}function BR(s,l,d,h,w,L,z,ae){const xe=nf()+s,qe=mr(),ft=zt(qe,xe,d,h,w,L);return $e(qe,xe+4,z)||ft?ye(qe,xe+5,ae?l.call(ae,d,h,w,L,z):l(d,h,w,L,z)):Ye(qe,xe+5)}function g2(s,l,d,h,w,L,z,ae,xe){const qe=nf()+s,ft=mr(),Xt=zt(ft,qe,d,h,w,L);return ht(ft,qe+4,z,ae)||Xt?ye(ft,qe+6,xe?l.call(xe,d,h,w,L,z,ae):l(d,h,w,L,z,ae)):Ye(ft,qe+6)}function aM(s,l,d,h,w,L,z,ae,xe,qe){const ft=nf()+s,Xt=mr();let Ln=zt(Xt,ft,d,h,w,L);return Vt(Xt,ft+4,z,ae,xe)||Ln?ye(Xt,ft+7,qe?l.call(qe,d,h,w,L,z,ae,xe):l(d,h,w,L,z,ae,xe)):Ye(Xt,ft+7)}function uF(s,l,d,h,w,L,z,ae,xe,qe,ft){const Xt=nf()+s,Ln=mr(),zn=zt(Ln,Xt,d,h,w,L);return zt(Ln,Xt+4,z,ae,xe,qe)||zn?ye(Ln,Xt+8,ft?l.call(ft,d,h,w,L,z,ae,xe,qe):l(d,h,w,L,z,ae,xe,qe)):Ye(Ln,Xt+8)}function dF(s,l,d,h){return VI(mr(),nf(),s,l,d,h)}function Zb(s,l){const d=s[l];return d===js?void 0:d}function v2(s,l,d,h,w,L){const z=l+d;return $e(s,z,w)?ye(s,z+1,L?h.call(L,w):h(w)):Zb(s,z+1)}function lM(s,l,d,h,w,L,z){const ae=l+d;return ht(s,ae,w,L)?ye(s,ae+2,z?h.call(z,w,L):h(w,L)):Zb(s,ae+2)}function Qp(s,l,d,h,w,L,z,ae){const xe=l+d;return Vt(s,xe,w,L,z)?ye(s,xe+3,ae?h.call(ae,w,L,z):h(w,L,z)):Zb(s,xe+3)}function VR(s,l,d,h,w,L,z,ae,xe){const qe=l+d;return zt(s,qe,w,L,z,ae)?ye(s,qe+4,xe?h.call(xe,w,L,z,ae):h(w,L,z,ae)):Zb(s,qe+4)}function VI(s,l,d,h,w,L){let z=l+d,ae=!1;for(let xe=0;xe<w.length;xe++)$e(s,z++,w[xe])&&(ae=!0);return ae?ye(s,z,h.apply(L,w)):Zb(s,z)}function jI(s,l){const d=Ua();let h;const w=s+Xe;d.firstCreatePass?(h=function UI(s,l){if(l)for(let d=l.length-1;d>=0;d--){const h=l[d];if(s===h.name)return h}}(l,d.pipeRegistry),d.data[w]=h,h.onDestroy&&(d.destroyHooks??=[]).push(w,h.onDestroy)):h=d.data[w];const L=h.factory||(h.factory=Pe(h.type)),ae=El(Jg);try{const xe=vD(!1),qe=L();return vD(xe),rE(d,mr(),w,qe),qe}finally{El(ae)}}function jR(s,l,d){const h=s+Xe,w=mr(),L=Lf(w,h);return cM(w,h)?v2(w,nf(),l,L.transform,d,L):L.transform(d)}function $I(s,l,d,h){const w=s+Xe,L=mr(),z=Lf(L,w);return cM(L,w)?lM(L,nf(),l,z.transform,d,h,z):z.transform(d,h)}function _2(s,l,d,h,w){const L=s+Xe,z=mr(),ae=Lf(z,L);return cM(z,L)?Qp(z,nf(),l,ae.transform,d,h,w,ae):ae.transform(d,h,w)}function y2(s,l,d,h,w,L){const z=s+Xe,ae=mr(),xe=Lf(ae,z);return cM(ae,z)?VR(ae,nf(),l,xe.transform,d,h,w,L,xe):xe.transform(d,h,w,L)}function Zw(s,l,d){const h=s+Xe,w=mr(),L=Lf(w,h);return cM(w,h)?VI(w,nf(),l,L.transform,d,L):L.transform.apply(L,d)}function cM(s,l){return s[io].data[l].pure}function UR(s,l){return Ny(s,l)}function uM(s,l){return()=>{try{return Hh.getComponentDependencies(s,l).dependencies}catch(d){throw console.error(`Computing dependencies in local compilation mode for the component "${s.name}" failed with the exception:`,d),d}}}function pF(s,l){const d=ja(s);null!==d&&(d.debugInfo=l)}const Mm={\u0275\u0275attribute:IT,\u0275\u0275attributeInterpolate1:Uw,\u0275\u0275attributeInterpolate2:vh,\u0275\u0275attributeInterpolate3:KS,\u0275\u0275attributeInterpolate4:$w,\u0275\u0275attributeInterpolate5:bp,\u0275\u0275attributeInterpolate6:Qb,\u0275\u0275attributeInterpolate7:qS,\u0275\u0275attributeInterpolate8:KC,\u0275\u0275attributeInterpolateV:k_,\u0275\u0275defineComponent:xr,\u0275\u0275defineDirective:Sv,\u0275\u0275defineInjectable:Ks,\u0275\u0275defineInjector:lc,\u0275\u0275defineNgModule:$_,\u0275\u0275definePipe:Am,\u0275\u0275directiveInject:Jg,\u0275\u0275getInheritedFactory:xx,\u0275\u0275inject:gi,\u0275\u0275injectAttribute:up,\u0275\u0275invalidFactory:aS,\u0275\u0275invalidFactoryDep:rr,\u0275\u0275templateRefExtractor:UR,\u0275\u0275resetView:oD,\u0275\u0275HostDirectivesFeature:pa,\u0275\u0275NgOnChangesFeature:Vi,\u0275\u0275ProvidersFeature:oM,\u0275\u0275CopyDefinitionFeature:a0,\u0275\u0275InheritDefinitionFeature:o0,\u0275\u0275InputTransformsFeature:Lw,\u0275\u0275StandaloneFeature:lF,\u0275\u0275nextContext:jT,\u0275\u0275namespaceHTML:pD,\u0275\u0275namespaceMathML:Zf,\u0275\u0275namespaceSVG:A0,\u0275\u0275enableBindings:ux,\u0275\u0275disableBindings:_E,\u0275\u0275elementStart:dI,\u0275\u0275elementEnd:fI,\u0275\u0275element:UA,\u0275\u0275elementContainerStart:m0,\u0275\u0275elementContainerEnd:pI,\u0275\u0275elementContainer:hI,\u0275\u0275pureFunction0:PR,\u0275\u0275pureFunction1:PI,\u0275\u0275pureFunction2:m2,\u0275\u0275pureFunction3:cF,\u0275\u0275pureFunction4:BI,\u0275\u0275pureFunction5:BR,\u0275\u0275pureFunction6:g2,\u0275\u0275pureFunction7:aM,\u0275\u0275pureFunction8:uF,\u0275\u0275pureFunctionV:dF,\u0275\u0275getCurrentView:$A,\u0275\u0275restoreView:Op,\u0275\u0275listener:VT,\u0275\u0275projection:ER,\u0275\u0275syntheticHostProperty:kT,\u0275\u0275syntheticHostListener:XO,\u0275\u0275pipeBind1:jR,\u0275\u0275pipeBind2:$I,\u0275\u0275pipeBind3:_2,\u0275\u0275pipeBind4:y2,\u0275\u0275pipeBindV:Zw,\u0275\u0275projectionDef:SR,\u0275\u0275hostProperty:g0,\u0275\u0275property:iI,\u0275\u0275propertyInterpolate:rc,\u0275\u0275propertyInterpolate1:UT,\u0275\u0275propertyInterpolate2:eF,\u0275\u0275propertyInterpolate3:r2,\u0275\u0275propertyInterpolate4:xI,\u0275\u0275propertyInterpolate5:o2,\u0275\u0275propertyInterpolate6:iE,\u0275\u0275propertyInterpolate7:s2,\u0275\u0275propertyInterpolate8:$T,\u0275\u0275propertyInterpolateV:WT,\u0275\u0275pipe:jI,\u0275\u0275queryRefresh:EI,\u0275\u0275queryAdvance:IR,\u0275\u0275viewQuery:SI,\u0275\u0275viewQuerySignal:zT,\u0275\u0275loadQuery:MR,\u0275\u0275contentQuery:TR,\u0275\u0275contentQuerySignal:HT,\u0275\u0275reference:TI,\u0275\u0275classMap:QS,\u0275\u0275classMapInterpolate1:qp,\u0275\u0275classMapInterpolate2:_h,\u0275\u0275classMapInterpolate3:sI,\u0275\u0275classMapInterpolate4:vO,\u0275\u0275classMapInterpolate5:BA,\u0275\u0275classMapInterpolate6:_O,\u0275\u0275classMapInterpolate7:VA,\u0275\u0275classMapInterpolate8:Gc,\u0275\u0275classMapInterpolateV:yO,\u0275\u0275styleMap:zc,\u0275\u0275styleMapInterpolate1:AR,\u0275\u0275styleMapInterpolate2:MI,\u0275\u0275styleMapInterpolate3:II,\u0275\u0275styleMapInterpolate4:a2,\u0275\u0275styleMapInterpolate5:QC,\u0275\u0275styleMapInterpolate6:GT,\u0275\u0275styleMapInterpolate7:AI,\u0275\u0275styleMapInterpolate8:qw,\u0275\u0275styleMapInterpolateV:KT,\u0275\u0275styleProp:Xb,\u0275\u0275stylePropInterpolate1:qT,\u0275\u0275stylePropInterpolate2:QT,\u0275\u0275stylePropInterpolate3:tF,\u0275\u0275stylePropInterpolate4:nF,\u0275\u0275stylePropInterpolate5:YT,\u0275\u0275stylePropInterpolate6:iF,\u0275\u0275stylePropInterpolate7:rF,\u0275\u0275stylePropInterpolate8:XT,\u0275\u0275stylePropInterpolateV:Qw,\u0275\u0275classProp:Dp,\u0275\u0275advance:fh,\u0275\u0275template:si,\u0275\u0275conditional:lI,\u0275\u0275defer:vv,\u0275\u0275deferWhen:u0,\u0275\u0275deferOnIdle:XM,\u0275\u0275deferOnImmediate:ZM,\u0275\u0275deferOnTimer:d0,\u0275\u0275deferOnHover:Cs,\u0275\u0275deferOnInteraction:JM,\u0275\u0275deferOnViewport:ua,\u0275\u0275deferPrefetchWhen:Kh,\u0275\u0275deferPrefetchOnIdle:MT,\u0275\u0275deferPrefetchOnImmediate:GS,\u0275\u0275deferPrefetchOnTimer:Ku,\u0275\u0275deferPrefetchOnHover:Ul,\u0275\u0275deferPrefetchOnInteraction:xd,\u0275\u0275deferPrefetchOnViewport:yp,\u0275\u0275deferEnableTimerScheduling:zp,\u0275\u0275repeater:TO,\u0275\u0275repeaterCreate:cI,\u0275\u0275repeaterTrackByIndex:wO,\u0275\u0275repeaterTrackByIdentity:xO,\u0275\u0275componentInstance:bO,\u0275\u0275text:l2,\u0275\u0275textInterpolate:ZT,\u0275\u0275textInterpolate1:Yw,\u0275\u0275textInterpolate2:c2,\u0275\u0275textInterpolate3:JT,\u0275\u0275textInterpolate4:yh,\u0275\u0275textInterpolate5:FI,\u0275\u0275textInterpolate6:oE,\u0275\u0275textInterpolate7:u2,\u0275\u0275textInterpolate8:eM,\u0275\u0275textInterpolateV:oF,\u0275\u0275i18n:QO,\u0275\u0275i18nAttributes:e2,\u0275\u0275i18nExp:t2,\u0275\u0275i18nStart:JA,\u0275\u0275i18nEnd:CI,\u0275\u0275i18nApply:YO,\u0275\u0275i18nPostprocess:wR,\u0275\u0275resolveWindow:my,\u0275\u0275resolveDocument:Ea,\u0275\u0275resolveBody:Bh,\u0275\u0275setComponentScope:f2,\u0275\u0275setNgModuleScope:kR,\u0275\u0275registerNgModuleType:r0,\u0275\u0275getComponentDepsFactory:uM,\u0275setClassDebugInfo:pF,\u0275\u0275declareLet:sF,\u0275\u0275storeLet:NI,\u0275\u0275readContextLet:RI,\u0275\u0275sanitizeHtml:$c,\u0275\u0275sanitizeStyle:Yx,\u0275\u0275sanitizeResourceUrl:Kg,\u0275\u0275sanitizeScript:B1,\u0275\u0275sanitizeUrl:WD,\u0275\u0275sanitizeUrlOrResourceUrl:j1,\u0275\u0275trustConstantHtml:Xx,\u0275\u0275trustConstantResourceUrl:V1,\u0275\u0275validateIframeAttribute:US,forwardRef:ho,resolveForwardRef:Vr,\u0275\u0275twoWayProperty:tM,\u0275\u0275twoWayBindingSet:FR,\u0275\u0275twoWayListener:nM};let YC=null;function Pk(){YC=null}const WI=[];let hF=!1;function WR(){if(!hF){hF=!0;try{for(let s=WI.length-1;s>=0;s--){const{moduleType:l,ngModule:d}=WI[s];d.declarations&&d.declarations.every(HR)&&(WI.splice(s,1),Uk(l,d))}}finally{hF=!1}}}function HR(s){return Array.isArray(s)?s.every(HR):!!Vr(s)}function zR(s,l={}){GR(s,l),void 0!==l.id&&r0(s,l.id),function Bk(s,l){WI.push({moduleType:s,ngModule:l})}(s,l)}function GR(s,l,d=!1){const h=Ut(l.declarations||Zo);let w=null;Object.defineProperty(s,qs,{configurable:!0,get:()=>(null===w&&(w=mu().compileNgModule(Mm,`ng:///${s.name}/\u0275mod.js`,{type:s,bootstrap:Ut(l.bootstrap||Zo).map(Vr),declarations:h.map(Vr),imports:Ut(l.imports||Zo).map(Vr).map(HI),exports:Ut(l.exports||Zo).map(Vr).map(HI),schemas:l.schemas?Ut(l.schemas):null,id:l.id||null}),w.schemas||(w.schemas=[])),w)});let L=null;Object.defineProperty(s,Xc,{get:()=>{if(null===L){const ae=mu();L=ae.compileFactory(Mm,`ng:///${s.name}/\u0275fac.js`,{name:s.name,type:s,deps:P0(s),target:ae.FactoryTarget.NgModule,typeArgumentCount:0})}return L},configurable:!1});let z=null;Object.defineProperty(s,_c,{get:()=>{if(null===z){const ae={name:s.name,type:s,providers:l.providers||Zo,imports:[(l.imports||Zo).map(Vr),(l.exports||Zo).map(Vr)]};z=mu().compileInjector(Mm,`ng:///${s.name}/\u0275inj.js`,ae)}return z},configurable:!1})}function mF(s,l){return`Unexpected "${xa(s)}" found in the "declarations" array of the ${l}, "${xa(s)}" is marked as standalone and can't be declared in any NgModule - did you intend to import it instead (by adding it to the "imports" array)?`}let b2=new WeakMap,C2=new WeakMap;function jk(){b2=new WeakMap,C2=new WeakMap,WI.length=0,Ep.clear()}function Uk(s,l){const d=Ut(l.declarations||Zo),h=sE(s);d.forEach(w=>{(w=Vr(w)).hasOwnProperty(Eu)?D2(ja(w),h):!w.hasOwnProperty(Pu)&&!w.hasOwnProperty(Lc)&&(w.ngSelectorScope=s)})}function D2(s,l){s.directiveDefs=()=>Array.from(l.compilation.directives).map(d=>d.hasOwnProperty(Eu)?ja(d):xs(d)).filter(d=>!!d),s.pipeDefs=()=>Array.from(l.compilation.pipes).map(d=>rd(d)),s.schemas=l.schemas,s.tView=null}function sE(s){if(Wf(s)){if(ym){const l=Hh.getNgModuleScope(s);return{schemas:Qu(s,!0).schemas||null,...l}}return function $k(s){const l=Qu(s,!0);if(null!==l.transitiveCompileScopes)return l.transitiveCompileScopes;const d={schemas:l.schemas||null,compilation:{directives:new Set,pipes:new Set},exported:{directives:new Set,pipes:new Set}};return ip(l.imports).forEach(h=>{const w=sE(h);w.exported.directives.forEach(L=>d.compilation.directives.add(L)),w.exported.pipes.forEach(L=>d.compilation.pipes.add(L))}),ip(l.declarations).forEach(h=>{rd(h)?d.compilation.pipes.add(h):d.compilation.directives.add(h)}),ip(l.exports).forEach(h=>{const w=h;if(Wf(w)){const L=sE(w);L.exported.directives.forEach(z=>{d.compilation.directives.add(z),d.exported.directives.add(z)}),L.exported.pipes.forEach(z=>{d.compilation.pipes.add(z),d.exported.pipes.add(z)})}else rd(w)?d.exported.pipes.add(w):d.exported.directives.add(w)}),l.transitiveCompileScopes=d,d}(s)}if(Yd(s)){if(null!==(ja(s)||xs(s)))return{schemas:null,compilation:{directives:new Set,pipes:new Set},exported:{directives:new Set([s]),pipes:new Set}};if(null!==rd(s))return{schemas:null,compilation:{directives:new Set,pipes:new Set},exported:{directives:new Set,pipes:new Set([s])}}}throw new Error(`${s.name} does not have a module def (\u0275mod property)`)}function HI(s){return bu(s)?s.ngModule:s}let w2=0;function vF(s,l){let d=null;(function BS(s,l){IC(l)&&(n0.set(s,l),TC.add(s))})(s,l),yF(s,l),Object.defineProperty(s,Eu,{get:()=>{if(null===d){const h=mu();if(IC(l)){const qe=[`Component '${s.name}' is not resolved:`];throw l.templateUrl&&qe.push(` - templateUrl: ${l.templateUrl}`),l.styleUrls&&l.styleUrls.length&&qe.push(` - styleUrls: ${JSON.stringify(l.styleUrls)}`),l.styleUrl&&qe.push(` - styleUrl: ${l.styleUrl}`),qe.push("Did you run and wait for 'resolveComponentResources()'?"),new Error(qe.join("\n"))}const w=function kk(){return YC}();let L=l.preserveWhitespaces;void 0===L&&(L=null!==w&&void 0!==w.preserveWhitespaces&&w.preserveWhitespaces);let z=l.encapsulation;void 0===z&&(z=null!==w&&void 0!==w.defaultEncapsulation?w.defaultEncapsulation:sr.Emulated);const ae=l.templateUrl||`ng:///${s.name}/template.html`,xe={...bF(s,l),typeSourceSpan:h.createParseSourceSpan("Component",s.name,ae),template:l.template||"",preserveWhitespaces:L,styles:"string"==typeof l.styles?[l.styles]:l.styles||Zo,animations:l.animations,declarations:[],changeDetection:l.changeDetection,encapsulation:z,interpolation:l.interpolation,viewProviders:l.viewProviders||null};w2++;try{if(xe.usesInheritance&&CF(s),d=h.compileComponent(Mm,ae,xe),l.standalone){const qe=Ut(l.imports||Zo),{directiveDefs:ft,pipeDefs:Xt}=function QR(s,l){let d=null,h=null;return{directiveDefs:()=>{if(ym)return nu(s)?[...Hh.getStandaloneComponentScope(s,l).compilation.directives].map(ae=>ja(ae)||xs(ae)).filter(ae=>null!==ae):[];if(null===d){d=[ja(s)];const z=new Set([s]);for(const ae of l){const xe=Vr(ae);if(!z.has(xe))if(z.add(xe),Qu(xe)){const qe=sE(xe);for(const ft of qe.exported.directives){const Xt=ja(ft)||xs(ft);Xt&&!z.has(ft)&&(z.add(ft),d.push(Xt))}}else{const qe=ja(xe)||xs(xe);qe&&d.push(qe)}}}return d},pipeDefs:()=>{if(ym)return nu(s)?[...Hh.getStandaloneComponentScope(s,l).compilation.pipes].map(ae=>rd(ae)).filter(ae=>null!==ae):[];if(null===h){h=[];const z=new Set;for(const ae of l){const xe=Vr(ae);if(!z.has(xe))if(z.add(xe),Qu(xe)){const qe=sE(xe);for(const ft of qe.exported.pipes){const Xt=rd(ft);Xt&&!z.has(ft)&&(z.add(ft),h.push(Xt))}}else{const qe=rd(xe);qe&&h.push(qe)}}}return h}}}(s,qe);d.directiveDefs=ft,d.pipeDefs=Xt,d.dependencies=()=>qe.map(Vr)}}finally{w2--}if(0===w2&&WR(),function x2(s){return void 0!==s.ngSelectorScope}(s)){const qe=sE(s.ngSelectorScope);D2(d,qe)}if(l.schemas){if(!l.standalone)throw new Error(`The 'schemas' was specified for the ${xa(s)} but is only valid on a component that is standalone.`);d.schemas=l.schemas}else l.standalone&&(d.schemas=[])}return d},configurable:!1})}function zI(s,l){let d=null;yF(s,l||{}),Object.defineProperty(s,Pu,{get:()=>{if(null===d){const h=_F(s,l||{});d=mu().compileDirective(Mm,h.sourceMapUrl,h.metadata)}return d},configurable:!1})}function _F(s,l){const d=s&&s.name,h=`ng:///${d}/\u0275dir.js`,w=mu(),L=bF(s,l);return L.typeSourceSpan=w.createParseSourceSpan("Directive",d,h),L.usesInheritance&&CF(s),{metadata:L,sourceMapUrl:h}}function yF(s,l){let d=null;Object.defineProperty(s,Xc,{get:()=>{if(null===d){const h=_F(s,l),w=mu();d=w.compileFactory(Mm,`ng:///${s.name}/\u0275fac.js`,{name:h.metadata.name,type:h.metadata.type,typeArgumentCount:0,deps:P0(s),target:w.FactoryTarget.Directive})}return d},configurable:!1})}function S2(s){return Object.getPrototypeOf(s.prototype)===Object.prototype}function bF(s,l){const d=Sx(),h=d.ownPropMetadata(s);return{name:s.name,type:s,selector:void 0!==l.selector?l.selector:null,host:l.host||ls,propMetadata:h,inputs:l.inputs||Zo,outputs:l.outputs||Zo,queries:XR(s,h,DF),lifecycle:{usesOnChanges:d.hasLifecycleHook(s,"ngOnChanges")},typeSourceSpan:null,usesInheritance:!S2(s),exportAs:ZR(l.exportAs),providers:l.providers||null,viewQueries:XR(s,h,E2),isStandalone:!!l.standalone,isSignal:!!l.signals,hostDirectives:l.hostDirectives?.map(w=>"function"==typeof w?{directive:w}:w)||null}}function CF(s){const l=Object.prototype;let d=Object.getPrototypeOf(s.prototype).constructor;for(;d&&d!==l;)!xs(d)&&!ja(d)&&JR(d)&&zI(d,null),d=Object.getPrototypeOf(d)}function YR(s){return"string"==typeof s?xF(s):Vr(s)}function Wk(s,l){return{propertyName:s,predicate:YR(l.selector),descendants:l.descendants,first:l.first,read:l.read?l.read:null,static:!!l.static,emitDistinctChangesOnly:!!l.emitDistinctChangesOnly,isSignal:!!l.isSignal}}function XR(s,l,d){const h=[];for(const w in l)if(l.hasOwnProperty(w)){const L=l[w];L.forEach(z=>{if(d(z)){if(!z.selector)throw new Error(`Can't construct a query for the property "${w}" of "${xa(s)}" since the query selector wasn't defined.`);if(L.some(wF))throw new Error("Cannot combine @Input decorators with query decorators");h.push(Wk(w,z))}})}return h}function ZR(s){return void 0===s?null:xF(s)}function DF(s){const l=s.ngMetadataName;return"ContentChild"===l||"ContentChildren"===l}function E2(s){const l=s.ngMetadataName;return"ViewChild"===l||"ViewChildren"===l}function wF(s){return"Input"===s.ngMetadataName}function xF(s){return s.split(",").map(l=>l.trim())}const SF=["ngOnChanges","ngOnInit","ngOnDestroy","ngDoCheck","ngAfterViewInit","ngAfterViewChecked","ngAfterContentInit","ngAfterContentChecked"];function JR(s){const l=Sx();if(SF.some(h=>l.hasLifecycleHook(s,h)))return!0;const d=l.propMetadata(s);for(const h in d){const w=d[h];for(let L=0;L<w.length;L++){const z=w[L],ae=z.ngMetadataName;if(wF(z)||DF(z)||E2(z)||"Output"===ae||"HostBinding"===ae||"HostListener"===ae)return!0}}return!1}function EF(s,l){let d=null,h=null;Object.defineProperty(s,Xc,{get:()=>{if(null===h){const w=T2(s,l),L=mu();h=L.compileFactory(Mm,`ng:///${w.name}/\u0275fac.js`,{name:w.name,type:w.type,typeArgumentCount:0,deps:P0(s),target:L.FactoryTarget.Pipe})}return h},configurable:!1}),Object.defineProperty(s,Lc,{get:()=>{if(null===d){const w=T2(s,l);d=mu().compilePipe(Mm,`ng:///${w.name}/\u0275pipe.js`,w)}return d},configurable:!1})}function T2(s,l){return{type:s,name:s.name,pipeName:l.name,pure:void 0===l.pure||l.pure,isStandalone:!!l.standalone}}const TF=xt("Directive",(s={})=>s,void 0,void 0,(s,l)=>zI(s,l)),MF=xt("Component",(s={})=>({changeDetection:Wo.Default,...s}),TF,void 0,(s,l)=>vF(s,l)),eL=xt("Pipe",s=>({pure:!0,...s}),void 0,void 0,(s,l)=>EF(s,l)),tL=bi("Input",s=>s?"string"==typeof s?{alias:s}:s:{}),IF=bi("Output",s=>({alias:s})),AF=bi("HostBinding",s=>({hostPropertyName:s})),nL=bi("HostListener",(s,l)=>({eventName:s,args:l})),iL=xt("NgModule",s=>s,void 0,void 0,(s,l)=>zR(s,l));class OF{constructor(l){this.full=l;const d=l.split(".");this.major=d[0],this.minor=d[1],this.patch=d.slice(2).join(".")}}const Hk=new OF("18.2.8");let rL=(()=>{class s{log(d){console.log(d)}warn(d){console.warn(d)}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"platform"})}return s})();const PF=new aa(""),BF=new aa("");let N2,mL=(()=>{class s{constructor(d,h,w){this._ngZone=d,this.registry=h,this._isZoneStable=!0,this._callbacks=[],this.taskTrackingZone=null,N2||(F2(w),w.addToWindow(h)),this._watchAngularEvents(),d.run(()=>{this.taskTrackingZone=typeof Zone>"u"?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{Uc.assertNotInAngularZone(),queueMicrotask(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}isStable(){return this._isZoneStable&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())queueMicrotask(()=>{for(;0!==this._callbacks.length;){let d=this._callbacks.pop();clearTimeout(d.timeoutId),d.doneCb()}});else{let d=this.getPendingTasks();this._callbacks=this._callbacks.filter(h=>!h.updateCb||!h.updateCb(d)||(clearTimeout(h.timeoutId),!1))}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(d=>({source:d.source,creationLocation:d.creationLocation,data:d.data})):[]}addCallback(d,h,w){let L=-1;h&&h>0&&(L=setTimeout(()=>{this._callbacks=this._callbacks.filter(z=>z.timeoutId!==L),d()},h)),this._callbacks.push({doneCb:d,timeoutId:L,updateCb:w})}whenStable(d,h,w){if(w&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(d,h,w),this._runCallbacksIfReady()}registerApplication(d){this.registry.registerApplication(d,this)}unregisterApplication(d){this.registry.unregisterApplication(d)}findProviders(d,h,w){return[]}static#e=this.\u0275fac=function(h){return new(h||s)(gi(Uc),gi(O2),gi(BF))};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac})}return s})(),O2=(()=>{class s{constructor(){this._applications=new Map}registerApplication(d,h){this._applications.set(d,h)}unregisterApplication(d){this._applications.delete(d)}unregisterAllApplications(){this._applications.clear()}getTestability(d){return this._applications.get(d)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(d,h=!0){return N2?.findTestabilityInTree(this,d,h)??null}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"platform"})}return s})();function F2(s){N2=s}function R2(s){return!!s&&"function"==typeof s.then}function gL(s){return!!s&&"function"==typeof s.subscribe}const vL=new aa("");let VF=(()=>{class s{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((d,h)=>{this.resolve=d,this.reject=h}),this.appInits=or(vL,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const d=[];for(const w of this.appInits){const L=w();if(R2(L))d.push(L);else if(gL(L)){const z=new Promise((ae,xe)=>{L.subscribe({complete:ae,error:xe})});d.push(z)}}const h=()=>{this.done=!0,this.resolve()};Promise.all(d).then(()=>{h()}).catch(w=>{this.reject(w)}),0===d.length&&h(),this.initialized=!0}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();const L2=new aa("");function _L(){!function An(s){Wn=s}(()=>{throw new po(600,!1)})}function yL(s){return s.isBoundToModule}class iP{constructor(l,d){this.name=l,this.token=d}}function bL(s,l){return Array.isArray(l)?l.reduce(bL,s):{...s,...l}}let qI,Jb=(()=>{class s{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=or(EE),this.afterRenderManager=or(Ml),this.zonelessEnabled=or(Wp),this.dirtyFlags=0,this.deferredDirtyFlags=0,this.externalTestViews=new Set,this.beforeRender=new Ai.Subject,this.afterTick=new Ai.Subject,this.componentTypes=[],this.components=[],this.isStable=or(sm).hasPendingTasks.pipe((0,Qi.map)(d=>!d)),this._injector=or(Hu)}get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}whenStable(){let d;return new Promise(h=>{d=this.isStable.subscribe({next:w=>{w&&h()}})}).finally(()=>{d.unsubscribe()})}get injector(){return this._injector}bootstrap(d,h){const w=d instanceof Ys;if(!this._injector.get(VF).done)throw!w&&Yd(d),new po(405,!1);let z;z=w?d:this._injector.get(ag).resolveComponentFactory(d),this.componentTypes.push(z.componentType);const ae=yL(z)?void 0:this._injector.get(O_),qe=z.create(Ou.NULL,[],h||z.selector,ae),ft=qe.location.nativeElement,Xt=qe.injector.get(PF,null);return Xt?.registerApplication(ft),qe.onDestroy(()=>{this.detachView(qe.hostView),KI(this.components,qe),Xt?.unregisterApplication(ft)}),this._loadComponent(qe),qe}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){if(this._runningTick)throw new po(101,!1);const d=Q(null);try{this._runningTick=!0,this.synchronize()}catch(h){this.internalErrorHandler(h)}finally{this._runningTick=!1,Q(d),this.afterTick.next()}}synchronize(){let d=null;this._injector.destroyed||(d=this._injector.get($y,null,{optional:!0})),this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0;let h=0;for(;0!==this.dirtyFlags&&h++<10;)this.synchronizeOnce(d)}synchronizeOnce(d){if(this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0,7&this.dirtyFlags){const h=!!(1&this.dirtyFlags);this.dirtyFlags&=-8,this.dirtyFlags|=8,this.beforeRender.next(h);for(let{_lView:w,notifyErrorHandler:L}of this._views)CL(w,L,h,this.zonelessEnabled);if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),7&this.dirtyFlags)return}else d?.begin?.(),d?.end?.();8&this.dirtyFlags&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){this.allViews.some(({_lView:d})=>Ir(d))?this.dirtyFlags|=2:this.dirtyFlags&=-8}attachView(d){const h=d;this._views.push(h),h.attachToAppRef(this)}detachView(d){const h=d;KI(this._views,h),h.detachFromAppRef()}_loadComponent(d){this.attachView(d.hostView),this.tick(),this.components.push(d);const h=this._injector.get(L2,[]);[...this._bootstrapListeners,...h].forEach(w=>w(d))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(d=>d()),this._views.slice().forEach(d=>d.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(d){return this._destroyListeners.push(d),()=>KI(this._destroyListeners,d)}destroy(){if(this._destroyed)throw new po(406,!1);const d=this._injector;d.destroy&&!d.destroyed&&d.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();function KI(s,l){const d=s.indexOf(l);d>-1&&s.splice(d,1)}function jF(s){qI??=new WeakMap;const l=qI.get(s);if(l)return l;const d=s.isStable.pipe((0,Qi.first)(h=>h)).toPromise().then(()=>{});return qI.set(s,d),s.onDestroy(()=>qI?.delete(s)),d}function CL(s,l,d,h){(d||Ir(s))&&ng(s,l,d&&!h?0:1)}class UF{constructor(l,d){this.ngModuleFactory=l,this.componentFactories=d}}let sP=(()=>{class s{compileModuleSync(d){return new Hb(d)}compileModuleAsync(d){return Promise.resolve(this.compileModuleSync(d))}compileModuleAndAllComponentsSync(d){const h=this.compileModuleSync(d),L=ip(Qu(d).declarations).reduce((z,ae)=>{const xe=ja(ae);return xe&&z.push(new hh(xe)),z},[]);return new UF(h,L)}compileModuleAndAllComponentsAsync(d){return Promise.resolve(this.compileModuleAndAllComponentsSync(d))}clearCache(){}clearCacheFor(d){}getModuleId(d){}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();const $F=new aa("");class DL{}function WF(s,l,d){const h=new Hb(d);return Promise.resolve(h)}let zF=(()=>{class s{constructor(){this.zone=or(Uc),this.changeDetectionScheduler=or(Wh),this.applicationRef=or(Jb)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();const GF=new aa("",{factory:()=>!1});function dM({ngZoneFactory:s,ignoreChangesOutsideZone:l,scheduleInRootZone:d}){return s??=()=>new Uc({...Jw(),scheduleInRootZone:d}),[{provide:Uc,useFactory:s},{provide:Hl,multi:!0,useFactory:()=>{const h=or(zF,{optional:!0});return()=>h.initialize()}},{provide:Hl,multi:!0,useFactory:()=>{const h=or(wL);return()=>{h.initialize()}}},!0===l?{provide:sg,useValue:!0}:[],{provide:av,useValue:d??V0}]}function KF(s){const l=s?.ignoreChangesOutsideZone,d=s?.scheduleInRootZone,h=dM({ngZoneFactory:()=>{const w=Jw(s);return w.scheduleInRootZone=d,w.shouldCoalesceEventChangeDetection&&dd("NgZone_CoalesceEvent"),new Uc(w)},ignoreChangesOutsideZone:l,scheduleInRootZone:d});return bc([{provide:GF,useValue:!0},{provide:Wp,useValue:!1},h])}function Jw(s){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:s?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:s?.runCoalescing??!1}}let wL=(()=>{class s{constructor(){this.subscription=new Ai.Subscription,this.initialized=!1,this.zone=or(Uc),this.pendingTasks=or(sm)}initialize(){if(this.initialized)return;this.initialized=!0;let d=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(d=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Uc.assertNotInAngularZone(),queueMicrotask(()=>{null!==d&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(d),d=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Uc.assertInAngularZone(),d??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})(),XC=(()=>{class s{constructor(){this.appRef=or(Jb),this.taskService=or(sm),this.ngZone=or(Uc),this.zonelessEnabled=or(Wp),this.disableScheduling=or(sg,{optional:!0})??!1,this.zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run,this.schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}],this.subscriptions=new Ai.Subscription,this.angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(Lp):null,this.scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(or(av,{optional:!0})??!1),this.cancelScheduledCallback=null,this.useMicrotaskScheduler=!1,this.runningTick=!1,this.pendingRenderTaskId=null,this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof $v||!this.zoneIsDefined)}notify(d){if(!this.zonelessEnabled&&5===d)return;switch(d){case 0:this.appRef.dirtyFlags|=2;break;case 3:case 2:case 4:case 5:case 1:this.appRef.dirtyFlags|=4;break;case 7:this.appRef.deferredDirtyFlags|=8;break;default:this.appRef.dirtyFlags|=8}if(!this.shouldScheduleTick())return;const h=this.useMicrotaskScheduler?xD:ry;this.pendingRenderTaskId=this.taskService.add(),this.cancelScheduledCallback=this.scheduleInRootZone?Zone.root.run(()=>h(()=>this.tick())):this.ngZone.runOutsideAngular(()=>h(()=>this.tick()))}shouldScheduleTick(){return!(this.disableScheduling||null!==this.pendingRenderTaskId||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(Lp+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;!this.zonelessEnabled&&7&this.appRef.dirtyFlags&&(this.appRef.dirtyFlags|=1);const d=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(h){throw this.taskService.remove(d),h}finally{this.cleanup()}this.useMicrotaskScheduler=!0,xD(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(d)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,null!==this.pendingRenderTaskId){const d=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(d)}}static#e=this.\u0275fac=function(h){return new(h||s)};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();function xL(){return dd("NgZoneless"),bc([{provide:Wh,useExisting:XC},{provide:Uc,useClass:$v},{provide:Wp,useValue:!0},{provide:av,useValue:!1},[]])}const P2=new aa("",{providedIn:"root",factory:()=>or(P2,As.Optional|As.SkipSelf)||function SL(){return typeof $localize<"u"&&$localize.locale||PT}()}),EL=new aa("",{providedIn:"root",factory:()=>"USD"}),TL=new aa(""),lP=new aa("");var ML=function(s){return s[s.Error=0]="Error",s[s.Warning=1]="Warning",s[s.Ignore=2]="Ignore",s}(ML||{});const YI=new aa("");function fM(s){return!s.moduleRef}function XF(s){const l=fM(s)?s.r3Injector:s.moduleRef.injector,d=l.get(Uc);return d.run(()=>{fM(s)?s.r3Injector.resolveInjectorInitializers():s.moduleRef.resolveInjectorInitializers();const h=l.get(Lh,null);let w;if(d.runOutsideAngular(()=>{w=d.onError.subscribe({next:L=>{h.handleError(L)}})}),fM(s)){const L=()=>l.destroy(),z=s.platformInjector.get(YI);z.add(L),l.onDestroy(()=>{w.unsubscribe(),z.delete(L)})}else{const L=()=>s.moduleRef.destroy(),z=s.platformInjector.get(YI);z.add(L),s.moduleRef.onDestroy(()=>{KI(s.allPlatformModules,s.moduleRef),w.unsubscribe(),z.delete(L)})}return function oP(s,l,d){try{const h=d();return R2(h)?h.catch(w=>{throw l.runOutsideAngular(()=>s.handleError(w)),w}):h}catch(h){throw l.runOutsideAngular(()=>s.handleError(h)),h}}(h,d,()=>{const L=l.get(VF);return L.runInitializers(),L.donePromise.then(()=>{if(_I(l.get(P2,PT)||PT),fM(s)){const ae=l.get(Jb);return void 0!==s.rootComponent&&ae.bootstrap(s.rootComponent),ae}return function cP(s,l){const d=s.injector.get(Jb);if(s._bootstrapComponents.length>0)s._bootstrapComponents.forEach(h=>d.bootstrap(h));else{if(!s.instance.ngDoBootstrap)throw new po(-403,!1);s.instance.ngDoBootstrap(d)}l.push(s)}(s.moduleRef,s.allPlatformModules),s.moduleRef})})})}let ZF=(()=>{class s{constructor(d){this._injector=d,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(d,h){const w=h?.scheduleInRootZone,z=h?.ignoreChangesOutsideZone,ae=[dM({ngZoneFactory:()=>function y1(s="zone.js",l){return"noop"===s?new $v:"zone.js"===s?new Uc(l):s}(h?.ngZone,{...Jw({eventCoalescing:h?.ngZoneEventCoalescing,runCoalescing:h?.ngZoneRunCoalescing}),scheduleInRootZone:w}),ignoreChangesOutsideZone:z}),{provide:Wh,useExisting:XC}],xe=function xT(s,l,d){return new c0(s,l,d,!1)}(d.moduleType,this.injector,ae);return XF({moduleRef:xe,allPlatformModules:this._modules,platformInjector:this.injector})}bootstrapModule(d,h=[]){const w=bL({},h);return WF(0,0,d).then(L=>this.bootstrapModuleFactory(L,w))}onDestroy(d){this._destroyListeners.push(d)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new po(404,!1);this._modules.slice().forEach(h=>h.destroy()),this._destroyListeners.forEach(h=>h());const d=this._injector.get(YI,null);d&&(d.forEach(h=>h()),d.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}static#e=this.\u0275fac=function(h){return new(h||s)(gi(Ou))};static#t=this.\u0275prov=Ks({token:s,factory:s.\u0275fac,providedIn:"platform"})}return s})(),ex=null;const XI=new aa("");function B2(s){if(ex&&!ex.get(XI,!1))throw new po(400,!1);_L(),ex=s;const l=s.get(ZF);return FL(s),l}function JF(s,l,d=[]){const h=`Platform: ${l}`,w=new aa(h);return(L=[])=>{let z=V2();if(!z||z.injector.get(XI,!1)){const ae=[...d,...L,{provide:w,useValue:!0}];s?s(ae):B2(AL(ae,h))}return OL()}}function AL(s=[],l){return Ou.create({name:l,providers:[{provide:Mu,useValue:"platform"},{provide:YI,useValue:new Set([()=>ex=null])},...s]})}function OL(s){const l=V2();if(!l)throw new po(401,!1);return l}function V2(){return ex?.get(ZF)??null}function uP(){V2()?.destroy()}function FL(s){s.get(Qv,null)?.forEach(d=>d())}function fP(s){return bc([])}function pP(){return!1}function hP(){}function mP(s){const l=NC(s);if(!l)throw eN(s);return new Hb(l)}function NL(s){const l=NC(s);if(!l)throw eN(s);return l}function eN(s){return new Error(`No module with ID ${s} loaded`)}let tN=(()=>{class s{static#e=this.__NG_ELEMENT_ID__=RL}return s})();function RL(s){return function gP(s,l,d){if(Zl(s)&&!d){const h=tf(s.index,l);return new jp(h,h)}return 175&s.type?new jp(l[Gl],l):null}(Pl(),mr(),!(16&~s))}class LL extends tN{}class vP extends LL{}class _P{constructor(l,d){this.name=l,this.callback=d}}function yP(s){return s.map(l=>l.nativeElement)}class nN{constructor(l){this.nativeNode=l}get parent(){const l=this.nativeNode.parentNode;return l?new ZI(l):null}get injector(){return function S1(s){const l=Cd(s),d=l?l.lView:null;return null===d?Ou.NULL:new ad(d[io].data[l.nodeIndex],d)}(this.nativeNode)}get componentInstance(){const l=this.nativeNode;return l&&(qv(l)||function jx(s){const l=Cd(s);let h,d=l?l.lView:null;if(null===d)return null;for(;2===d[io].type&&(h=wc(d));)d=h;return 512&d[Ps]?null:d[Ja]}(l))}get context(){return qv(this.nativeNode)||function Pg(s){!function PE(s){if(typeof Element<"u"&&!(s instanceof Element))throw new Error("Expecting instance of DOM Element")}(s);const l=Cd(s),d=l?l.lView:null;return null===d?null:d[Ja]}(this.nativeNode)}get listeners(){return function Y0(s){const l=Cd(s),d=null===l?null:l.lView;if(null===d)return[];const w=d[Rf],L=d[io].cleanup,z=[];if(L&&w)for(let ae=0;ae<L.length;){const xe=L[ae++],qe=L[ae++];if("string"==typeof xe){const ft=xe,Xt=Qa(d[qe]),Ln=w[L[ae++]],zn=L[ae++];s==Xt&&z.push({element:s,name:ft,callback:Ln,useCapture:"boolean"==typeof zn&&zn,type:"boolean"==typeof zn||zn>=0?"dom":"output"})}}return z.sort(kE),z}(this.nativeNode).filter(l=>"dom"===l.type)}get references(){return function LE(s){const l=Cd(s);if(null===l)return{};if(void 0===l.localRefs){const d=l.lView;if(null===d)return{};l.localRefs=function FE(s,l){const d=s[io].data[l];if(d&&d.localNames){const h={};let w=d.index+1;for(let L=0;L<d.localNames.length;L+=2)h[d.localNames[L]]=s[w],w++;return h}return null}(d,l.nodeIndex)}return l.localRefs||{}}(this.nativeNode)}get providerTokens(){return function NE(s){const l=Cd(s),d=l?l.lView:null;if(null===d)return[];const h=d[io],w=h.data[l.nodeIndex],L=[],ae=w.directiveEnd;for(let xe=1048575&w.providerIndexes;xe<ae;xe++){let qe=h.data[xe];M1(qe)&&(qe=qe.type),L.push(qe)}return L}(this.nativeNode)}}class ZI extends nN{constructor(l){super(l)}get nativeElement(){return this.nativeNode.nodeType==Node.ELEMENT_NODE?this.nativeNode:null}get name(){const l=Cd(this.nativeNode),d=l?l.lView:null;return null!==d?d[io].data[l.nodeIndex].value:this.nativeNode.nodeName}get properties(){const l=Cd(this.nativeNode),d=l?l.lView:null;if(null===d)return{};const h=d[io].data,w=h[l.nodeIndex],L={};return function bP(s,l){if(s){let d=Object.getPrototypeOf(s);const h=Node.prototype;for(;null!==d&&d!==h;){const w=Object.getOwnPropertyDescriptors(d);for(let L in w)if(!L.startsWith("__")&&!L.startsWith("on")){const z=s[L];CP(z)&&(l[L]=z)}d=Object.getPrototypeOf(d)}}}(this.nativeElement,L),function BL(s,l,d,h){let w=l.propertyBindings;if(null!==w)for(let L=0;L<w.length;L++){const z=w[L],xe=h[z].split("\ufffd"),qe=xe[0];if(xe.length>1){let ft=xe[1];for(let Xt=1;Xt<xe.length-1;Xt++)ft+=Is(d[z+Xt-1])+xe[Xt+1];s[qe]=ft}else s[qe]=d[z]}}(L,w,d,h),L}get attributes(){const l={},d=this.nativeElement;if(!d)return l;const h=Cd(d),w=h?h.lView:null;if(null===w)return{};const L=w[io].data[h.nodeIndex].attrs,z=[];if(L){let ae=0;for(;ae<L.length;){const xe=L[ae];if("string"!=typeof xe)break;l[xe]=L[ae+1],z.push(xe.toLowerCase()),ae+=2}}for(const ae of d.attributes)z.includes(ae.name)||(l[ae.name]=ae.value);return l}get styles(){return this.nativeElement?.style??{}}get classes(){const l={},h=this.nativeElement.className;return("string"!=typeof h?h.baseVal.split(" "):h.split(" ")).forEach(L=>l[L]=!0),l}get childNodes(){const l=this.nativeNode.childNodes,d=[];for(let h=0;h<l.length;h++)d.push(pM(l[h]));return d}get children(){const l=this.nativeElement;if(!l)return[];const d=l.children,h=[];for(let w=0;w<d.length;w++)h.push(pM(d[w]));return h}query(l){return this.queryAll(l)[0]||null}queryAll(l){const d=[];return kL(this,l,d,!0),d}queryAllNodes(l){const d=[];return kL(this,l,d,!1),d}triggerEventHandler(l,d){const h=this.nativeNode,w=[];this.listeners.forEach(L=>{if(L.name===l){const z=L.callback;z.call(h,d),w.push(z)}}),"function"==typeof h.eventListeners&&h.eventListeners(l).forEach(L=>{if(-1!==L.toString().indexOf("__ngUnwrap__")){const z=L("__ngUnwrap__");return-1===w.indexOf(z)&&z.call(h,d)}})}}function CP(s){return"string"==typeof s||"boolean"==typeof s||"number"==typeof s||null===s}function kL(s,l,d,h){const w=Cd(s.nativeNode),L=w?w.lView:null;null!==L?aE(L[io].data[w.nodeIndex],L,l,d,h,s.nativeNode):j2(s.nativeNode,l,d,h)}function aE(s,l,d,h,w,L){const z=function lp(s,l){const d=null===s?-1:s.index;return-1!==d?Qa(l[d]):null}(s,l);if(11&s.type){if(iN(z,d,h,w,L),Zl(s)){const xe=tf(s.index,l);xe&&xe[io].firstChild&&aE(xe[io].firstChild,xe,d,h,w,L)}else s.child&&aE(s.child,l,d,h,w,L),z&&j2(z,d,h,w);const ae=l[s.index];el(ae)&&PL(ae,d,h,w,L)}else if(4&s.type){const ae=l[s.index];iN(ae[gr],d,h,w,L),PL(ae,d,h,w,L)}else if(16&s.type){const ae=l[Gl],qe=ae[nc].projection[s.projection];if(Array.isArray(qe))for(let ft of qe)iN(ft,d,h,w,L);else if(qe){const ft=ae[fc];aE(ft[io].data[qe.index],ft,d,h,w,L)}}else s.child&&aE(s.child,l,d,h,w,L);if(L!==z){const ae=2&s.flags?s.projectionNext:s.next;ae&&aE(ae,l,d,h,w,L)}}function PL(s,l,d,h,w){for(let L=Gr;L<s.length;L++){const z=s[L],ae=z[io].firstChild;ae&&aE(ae,z,l,d,h,w)}}function iN(s,l,d,h,w){if(w!==s){const L=pM(s);if(!L)return;(h&&L instanceof ZI&&l(L)&&-1===d.indexOf(L)||!h&&l(L)&&-1===d.indexOf(L))&&d.push(L)}}function j2(s,l,d,h){const w=s.childNodes,L=w.length;for(let z=0;z<L;z++){const ae=w[z],xe=pM(ae);xe&&((h&&xe instanceof ZI&&l(xe)&&-1===d.indexOf(xe)||!h&&l(xe)&&-1===d.indexOf(xe))&&d.push(xe),j2(ae,l,d,h))}}const $2="__ng_debug__";function pM(s){return s instanceof Node?(s.hasOwnProperty($2)||(s[$2]=s.nodeType==Node.ELEMENT_NODE?new ZI(s):new nN(s)),s[$2]):null}class VL{constructor(){}supports(l){return a(l)}create(l){return new rN(l)}}const jL=(s,l)=>l;class rN{constructor(l){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=l||jL}forEachItem(l){let d;for(d=this._itHead;null!==d;d=d._next)l(d)}forEachOperation(l){let d=this._itHead,h=this._removalsHead,w=0,L=null;for(;d||h;){const z=!h||d&&d.currentIndex<$L(h,w,L)?d:h,ae=$L(z,w,L),xe=z.currentIndex;if(z===h)w--,h=h._nextRemoved;else if(d=d._next,null==z.previousIndex)w++;else{L||(L=[]);const qe=ae-w,ft=xe-w;if(qe!=ft){for(let Ln=0;Ln<qe;Ln++){const zn=Ln<L.length?L[Ln]:L[Ln]=0,xi=zn+Ln;ft<=xi&&xi<qe&&(L[Ln]=zn+1)}L[z.previousIndex]=ft-qe}}ae!==xe&&l(z,ae,xe)}}forEachPreviousItem(l){let d;for(d=this._previousItHead;null!==d;d=d._nextPrevious)l(d)}forEachAddedItem(l){let d;for(d=this._additionsHead;null!==d;d=d._nextAdded)l(d)}forEachMovedItem(l){let d;for(d=this._movesHead;null!==d;d=d._nextMoved)l(d)}forEachRemovedItem(l){let d;for(d=this._removalsHead;null!==d;d=d._nextRemoved)l(d)}forEachIdentityChange(l){let d;for(d=this._identityChangesHead;null!==d;d=d._nextIdentityChange)l(d)}diff(l){if(null==l&&(l=[]),!a(l))throw new po(900,!1);return this.check(l)?this:null}onDestroy(){}check(l){this._reset();let w,L,z,d=this._itHead,h=!1;if(Array.isArray(l)){this.length=l.length;for(let ae=0;ae<this.length;ae++)L=l[ae],z=this._trackByFn(ae,L),null!==d&&Object.is(d.trackById,z)?(h&&(d=this._verifyReinsertion(d,L,z,ae)),Object.is(d.item,L)||this._addIdentityChange(d,L)):(d=this._mismatch(d,L,z,ae),h=!0),d=d._next}else w=0,function x(s,l){if(Array.isArray(s))for(let d=0;d<s.length;d++)l(s[d]);else{const d=s[Symbol.iterator]();let h;for(;!(h=d.next()).done;)l(h.value)}}(l,ae=>{z=this._trackByFn(w,ae),null!==d&&Object.is(d.trackById,z)?(h&&(d=this._verifyReinsertion(d,ae,z,w)),Object.is(d.item,ae)||this._addIdentityChange(d,ae)):(d=this._mismatch(d,ae,z,w),h=!0),d=d._next,w++}),this.length=w;return this._truncate(d),this.collection=l,this.isDirty}get isDirty(){return null!==this._additionsHead||null!==this._movesHead||null!==this._removalsHead||null!==this._identityChangesHead}_reset(){if(this.isDirty){let l;for(l=this._previousItHead=this._itHead;null!==l;l=l._next)l._nextPrevious=l._next;for(l=this._additionsHead;null!==l;l=l._nextAdded)l.previousIndex=l.currentIndex;for(this._additionsHead=this._additionsTail=null,l=this._movesHead;null!==l;l=l._nextMoved)l.previousIndex=l.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(l,d,h,w){let L;return null===l?L=this._itTail:(L=l._prev,this._remove(l)),null!==(l=null===this._unlinkedRecords?null:this._unlinkedRecords.get(h,null))?(Object.is(l.item,d)||this._addIdentityChange(l,d),this._reinsertAfter(l,L,w)):null!==(l=null===this._linkedRecords?null:this._linkedRecords.get(h,w))?(Object.is(l.item,d)||this._addIdentityChange(l,d),this._moveAfter(l,L,w)):l=this._addAfter(new xP(d,h),L,w),l}_verifyReinsertion(l,d,h,w){let L=null===this._unlinkedRecords?null:this._unlinkedRecords.get(h,null);return null!==L?l=this._reinsertAfter(L,l._prev,w):l.currentIndex!=w&&(l.currentIndex=w,this._addToMoves(l,w)),l}_truncate(l){for(;null!==l;){const d=l._next;this._addToRemovals(this._unlink(l)),l=d}null!==this._unlinkedRecords&&this._unlinkedRecords.clear(),null!==this._additionsTail&&(this._additionsTail._nextAdded=null),null!==this._movesTail&&(this._movesTail._nextMoved=null),null!==this._itTail&&(this._itTail._next=null),null!==this._removalsTail&&(this._removalsTail._nextRemoved=null),null!==this._identityChangesTail&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(l,d,h){null!==this._unlinkedRecords&&this._unlinkedRecords.remove(l);const w=l._prevRemoved,L=l._nextRemoved;return null===w?this._removalsHead=L:w._nextRemoved=L,null===L?this._removalsTail=w:L._prevRemoved=w,this._insertAfter(l,d,h),this._addToMoves(l,h),l}_moveAfter(l,d,h){return this._unlink(l),this._insertAfter(l,d,h),this._addToMoves(l,h),l}_addAfter(l,d,h){return this._insertAfter(l,d,h),this._additionsTail=null===this._additionsTail?this._additionsHead=l:this._additionsTail._nextAdded=l,l}_insertAfter(l,d,h){const w=null===d?this._itHead:d._next;return l._next=w,l._prev=d,null===w?this._itTail=l:w._prev=l,null===d?this._itHead=l:d._next=l,null===this._linkedRecords&&(this._linkedRecords=new UL),this._linkedRecords.put(l),l.currentIndex=h,l}_remove(l){return this._addToRemovals(this._unlink(l))}_unlink(l){null!==this._linkedRecords&&this._linkedRecords.remove(l);const d=l._prev,h=l._next;return null===d?this._itHead=h:d._next=h,null===h?this._itTail=d:h._prev=d,l}_addToMoves(l,d){return l.previousIndex===d||(this._movesTail=null===this._movesTail?this._movesHead=l:this._movesTail._nextMoved=l),l}_addToRemovals(l){return null===this._unlinkedRecords&&(this._unlinkedRecords=new UL),this._unlinkedRecords.put(l),l.currentIndex=null,l._nextRemoved=null,null===this._removalsTail?(this._removalsTail=this._removalsHead=l,l._prevRemoved=null):(l._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=l),l}_addIdentityChange(l,d){return l.item=d,this._identityChangesTail=null===this._identityChangesTail?this._identityChangesHead=l:this._identityChangesTail._nextIdentityChange=l,l}}class xP{constructor(l,d){this.item=l,this.trackById=d,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}}class SP{constructor(){this._head=null,this._tail=null}add(l){null===this._head?(this._head=this._tail=l,l._nextDup=null,l._prevDup=null):(this._tail._nextDup=l,l._prevDup=this._tail,l._nextDup=null,this._tail=l)}get(l,d){let h;for(h=this._head;null!==h;h=h._nextDup)if((null===d||d<=h.currentIndex)&&Object.is(h.trackById,l))return h;return null}remove(l){const d=l._prevDup,h=l._nextDup;return null===d?this._head=h:d._nextDup=h,null===h?this._tail=d:h._prevDup=d,null===this._head}}class UL{constructor(){this.map=new Map}put(l){const d=l.trackById;let h=this.map.get(d);h||(h=new SP,this.map.set(d,h)),h.add(l)}get(l,d){const w=this.map.get(l);return w?w.get(l,d):null}remove(l){const d=l.trackById;return this.map.get(d).remove(l)&&this.map.delete(d),l}get isEmpty(){return 0===this.map.size}clear(){this.map.clear()}}function $L(s,l,d){const h=s.previousIndex;if(null===h)return h;let w=0;return d&&h<d.length&&(w=d[h]),h+l+w}class oN{constructor(){}supports(l){return l instanceof Map||I(l)}create(){return new WL}}class WL{constructor(){this._records=new Map,this._mapHead=null,this._appendAfter=null,this._previousMapHead=null,this._changesHead=null,this._changesTail=null,this._additionsHead=null,this._additionsTail=null,this._removalsHead=null,this._removalsTail=null}get isDirty(){return null!==this._additionsHead||null!==this._changesHead||null!==this._removalsHead}forEachItem(l){let d;for(d=this._mapHead;null!==d;d=d._next)l(d)}forEachPreviousItem(l){let d;for(d=this._previousMapHead;null!==d;d=d._nextPrevious)l(d)}forEachChangedItem(l){let d;for(d=this._changesHead;null!==d;d=d._nextChanged)l(d)}forEachAddedItem(l){let d;for(d=this._additionsHead;null!==d;d=d._nextAdded)l(d)}forEachRemovedItem(l){let d;for(d=this._removalsHead;null!==d;d=d._nextRemoved)l(d)}diff(l){if(l){if(!(l instanceof Map||I(l)))throw new po(900,!1)}else l=new Map;return this.check(l)?this:null}onDestroy(){}check(l){this._reset();let d=this._mapHead;if(this._appendAfter=null,this._forEach(l,(h,w)=>{if(d&&d.key===w)this._maybeAddToChanges(d,h),this._appendAfter=d,d=d._next;else{const L=this._getOrCreateRecordForKey(w,h);d=this._insertBeforeOrAppend(d,L)}}),d){d._prev&&(d._prev._next=null),this._removalsHead=d;for(let h=d;null!==h;h=h._nextRemoved)h===this._mapHead&&(this._mapHead=null),this._records.delete(h.key),h._nextRemoved=h._next,h.previousValue=h.currentValue,h.currentValue=null,h._prev=null,h._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(l,d){if(l){const h=l._prev;return d._next=l,d._prev=h,l._prev=d,h&&(h._next=d),l===this._mapHead&&(this._mapHead=d),this._appendAfter=l,l}return this._appendAfter?(this._appendAfter._next=d,d._prev=this._appendAfter):this._mapHead=d,this._appendAfter=d,null}_getOrCreateRecordForKey(l,d){if(this._records.has(l)){const w=this._records.get(l);this._maybeAddToChanges(w,d);const L=w._prev,z=w._next;return L&&(L._next=z),z&&(z._prev=L),w._next=null,w._prev=null,w}const h=new EP(l);return this._records.set(l,h),h.currentValue=d,this._addToAdditions(h),h}_reset(){if(this.isDirty){let l;for(this._previousMapHead=this._mapHead,l=this._previousMapHead;null!==l;l=l._next)l._nextPrevious=l._next;for(l=this._changesHead;null!==l;l=l._nextChanged)l.previousValue=l.currentValue;for(l=this._additionsHead;null!=l;l=l._nextAdded)l.previousValue=l.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(l,d){Object.is(d,l.currentValue)||(l.previousValue=l.currentValue,l.currentValue=d,this._addToChanges(l))}_addToAdditions(l){null===this._additionsHead?this._additionsHead=this._additionsTail=l:(this._additionsTail._nextAdded=l,this._additionsTail=l)}_addToChanges(l){null===this._changesHead?this._changesHead=this._changesTail=l:(this._changesTail._nextChanged=l,this._changesTail=l)}_forEach(l,d){l instanceof Map?l.forEach(d):Object.keys(l).forEach(h=>d(l[h],h))}}class EP{constructor(l){this.key=l,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}}function HL(){return new sN([new VL])}let sN=(()=>{class s{static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:HL});constructor(d){this.factories=d}static create(d,h){if(null!=h){const w=h.factories.slice();d=d.concat(w)}return new s(d)}static extend(d){return{provide:s,useFactory:h=>s.create(d,h||HL()),deps:[[s,new Ue,new Mc]]}}find(d){const h=this.factories.find(w=>w.supports(d));if(null!=h)return h;throw new po(901,!1)}}return s})();function zL(){return new aN([new oN])}let aN=(()=>{class s{static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:zL});constructor(d){this.factories=d}static create(d,h){if(h){const w=h.factories.slice();d=d.concat(w)}return new s(d)}static extend(d){return{provide:s,useFactory:h=>s.create(d,h||zL()),deps:[[s,new Ue,new Mc]]}}find(d){const h=this.factories.find(w=>w.supports(d));if(h)return h;throw new po(901,!1)}}return s})();const lN=[new oN],JI=new sN([new VL]),TP=new aN(lN),KL=JF(null,"core",[]);let MP=(()=>{class s{constructor(d){}static#e=this.\u0275fac=function(h){return new(h||s)(gi(Jb))};static#t=this.\u0275mod=$_({type:s});static#n=this.\u0275inj=lc({})}return s})();function kP(s){}function G2(s){try{const{rootComponent:l,appProviders:d,platformProviders:h}=s,w=function dP(s=[]){if(ex)return ex;const l=AL(s);return ex=l,_L(),FL(l),l}(h),L=[dM({}),{provide:Wh,useExisting:XC},...d||[]];return XF({r3Injector:new zb({providers:L,parent:w,debugName:"",runEnvironmentInitializers:!1}).injector,platformInjector:w,rootComponent:l})}catch(l){return Promise.reject(l)}}function gN(s,l){const d=s[io];for(let h=Xe;h<d.bindingStartIndex;h++)if(el(s[h])){const w=s[h];if(h!==d.bindingStartIndex-1){const z=d.data[h],ae=ha(d,z);if(Bw(ae)){l.push({lContainer:w,lView:s,tNode:z,tDetails:ae});continue}}for(let z=Gr;z<w.length;z++)gN(w[z],l)}else cs(s[h])&&gN(s[h],l)}function PP(s){const l=s.currentTarget?.__jsaction_fns?.get(s.type);if(l)for(const d of l)d(s)}function K2(s,l){if(!l.length)return;const d=l.reduce((w,L)=>w+L+":;",""),h=s.getAttribute(Xr.JSACTION);s.setAttribute(Xr.JSACTION,`${h??""}${d}`)}const BP=(s,l,d)=>{const h=s,w=h.__jsaction_fns??new Map,L=w.get(l)??[];L.push(d),w.set(l,L),h.__jsaction_fns=w},VP=s=>{s.removeAttribute(Xr.JSACTION),s.__jsaction_fns=void 0},cA=new aa("",{providedIn:"root",factory:()=>({})}),q2=new Set;function ok(s){return s.get(Wd,t_)}function Q2(){return[{provide:Wd,useFactory:()=>{let s=!0;if(Fu()){const l=or(X0);s=!!window._ejsas?.[l]}return s&&dd("NgEventReplay"),s}},{provide:Hl,useValue:()=>{const s=or(Ou);Fu(s)&&ok(s)&&DI((l,d,h)=>{BP(l,d,h),q2.add(l)})},multi:!0},{provide:L2,useFactory:()=>{if(Fu()){const s=or(Ou),l=or(Jb);return()=>{ok(s)&&jF(l).then(()=>{const d=s.get(cA);jP(d,s),q2.forEach(VP),DI(()=>{})})}}return()=>{}},multi:!0}]}const jP=(s,l)=>{const d=l.get(X0),h=window._ejsas[d],w=s.instance=new Aa(new ko(h.c));for(const ae of h.et)w.addEvent(ae);for(const ae of h.etc)w.addEvent(ae);const L=function Ql(s,l=window){return function Xa(s){return s?.q??[]}(l._ejsas?.[s])}(d);w.replayEarlyEventInfos(L),function vc(s,l=window){l._ejsas&&(l._ejsas[s]=void 0)}(d),function ec(s,l){s.ecrd(d=>{l.dispatch(d)},wo.I_AM_THE_JSACTION_FRAMEWORK)}(w,new la(PP))};class Y2{constructor(){this.views=[],this.indexByContent=new Map}add(l){const d=JSON.stringify(l);if(!this.indexByContent.has(d)){const h=this.views.length;return this.views.push(l),this.indexByContent.set(d,h),h}return this.indexByContent.get(d)}getAll(){return this.views}}let $P=0;function sk(s){return s.ssrId||(s.ssrId="t"+$P++),s.ssrId}function cE(s,l,d){const h=[];return iv(s,l,d,h),h.length}function WP(s){const l=[];return hS(s,l),l.length}function ak(s,l){const d=s[Cc];return d&&!d.hasAttribute(W0)?dA(d,s,l):null}function ZC(s,l){const d=Ov(s[Cc]),h=ak(d,l);if(null===h)return;const w=Qa(d[Cc]),z=dA(w,s[fc],l);d[Ss].setAttribute(w,ep,`${h}|${z}`)}function X2(s,l){const d=s.injector,h=function yw(s){return(s=s??or(Ou)).get($d,!1)}(d),w=new Y2,L=new Map,z=s._views,ae=d.get(Wd,t_),xe={regular:new Set,capture:new Set};for(const Xt of z){const Ln=J0(Xt);if(null!==Ln){const zn={serializedViewCollection:w,corruptedTextNodes:L,isI18nHydrationEnabled:h,i18nChildren:new Map,eventTypesToReplay:xe,shouldReplayEvents:ae};el(Ln)?ZC(Ln,zn):ak(Ln,zn),fA(L,l)}}const qe=w.getAll();return d.get(zm).set($g,qe),xe}function Z2(s,l){const d=[];let h="";for(let w=Gr;w<s.length;w++){let z,ae,xe,L=s[w];if(Th(L)&&(L=L[Xe],el(L))){ae=WP(L)+1,ZC(L,l);const ft=Ov(L[Cc]);xe={[O1]:ft[io].ssrId,[jg]:ae}}if(!xe){const ft=L[io];1===ft.type?(z=ft.ssrId,ae=1):(z=sk(ft),ae=cE(ft,L,ft.firstChild)),xe={[O1]:z,[jg]:ae,...lk(s[w],l)}}const qe=JSON.stringify(xe);if(d.length>0&&qe===h){const ft=d[d.length-1];ft[A1]??=1,ft[A1]++}else h=qe,d.push(xe)}return d}function tx(s,l,d,h){const w=l.index-Xe;s[Wx]??={},s[Wx][w]??=vw(l,d,h)}function J2(s,l){const d="number"==typeof l?l:l.index-Xe;s[Ug]??=[],s[Ug].includes(d)||s[Ug].push(d)}function lk(s,l){const d={},h=s[io],w=function TS(s,l){let d=l.i18nChildren.get(s);return void 0===d&&(d=function gT(s){const l=new Set;function d(h){switch(l.add(h.index),h.kind){case 1:case 2:for(const w of h.children)d(w);break;case 3:for(const w of h.cases)for(const L of w)d(L)}}for(let h=Xe;h<s.bindingStartIndex;h++){const w=s.data[h];if(w&&w.ast)for(const L of w.ast)d(L)}return 0===l.size?null:l}(s),l.i18nChildren.set(s,d)),d}(h,l),L=l.shouldReplayEvents?function UP(s,l,d){const h=new Map,L=s.cleanup;if(!L||!l[Rf])return h;for(let z=0;z<L.length;){const ae=L[z++],xe=L[z++];if("string"!=typeof ae)continue;const qe=ae;if(!Mn(qe))continue;At(qe)?d.capture.add(qe):d.regular.add(qe);const ft=Qa(l[xe]);z++;const Xt=L[z++];("boolean"==typeof Xt||Xt>=0)&&(h.has(ft)?h.get(ft).push(qe):h.set(ft,[qe]))}return h}(h,s,l.eventTypesToReplay):null;for(let z=Xe;z<h.bindingStartIndex;z++){const ae=h.data[z],xe=z-Xe,qe=Ab(s,z,l);if(qe){d[F1]??={},d[F1][xe]=qe.caseQueue;for(const ft of qe.disconnectedNodes)J2(d,ft);for(const ft of qe.disjointNodes)tx(d,h.data[ft+Xe],s,w)}else if(_u(ae)&&!yn(ae)){if(Eb(ae,s)&&eO(ae)){J2(d,ae);continue}if(L&&2&ae.type){const ft=Qa(s[z]);L.has(ft)&&K2(ft,L.get(ft))}if(Array.isArray(ae.projection))for(const ft of ae.projection)if(ft){if(Array.isArray(ft))throw aT(Qa(s[z]));!Pm(ft)&&!kg(ft)&&(Eb(ft,s)?J2(d,ft):tx(d,ft,s,w))}if(uA(d,ae,s,w),el(s[z])){const ft=ae.tView;null!==ft&&(d[Vg]??={},d[Vg][xe]=sk(ft));const Xt=s[z][Cc];if(Array.isArray(Xt)){const Ln=Qa(Xt);Ln.hasAttribute(W0)||dA(Ln,Xt,l)}d[ly]??={},d[ly][xe]=Z2(s[z],l)}else if(Array.isArray(s[z])&&!Um(ae)){const ft=Qa(s[z][Cc]);ft.hasAttribute(W0)||dA(ft,s[z],l)}else if(8&ae.type)d[kD]??={},d[kD][xe]=cE(h,s,ae.child);else if(144&ae.type){let ft=ae.next;for(;null!==ft&&144&ft.type;)ft=ft.next;ft&&!kg(ft)&&tx(d,ft,s,w)}else 1&ae.type&&N1(l,Qa(s[z]))}}return d}function uA(s,l,d,h){Pm(l)||(l.projectionNext&&l.projectionNext!==l.next&&!kg(l.projectionNext)&&tx(s,l.projectionNext,d,h),null===l.prev&&null!==l.parent&&Eb(l.parent,d)&&!Eb(l,d)&&tx(s,l,d,h))}function dA(s,l,d){const h=l[Ss];if(function nh(s){return!(32&~s[Ps])}(l)&&!ES()||function HP(s){const l=s[Ja];return!!l?.constructor&&ja(l.constructor)?.encapsulation===sr.ShadowDom}(l))return h.setAttribute(s,W0,""),null;{const w=lk(l,d),L=d.serializedViewCollection.add(w);return h.setAttribute(s,ep,L.toString()),L}}function fA(s,l){for(const[d,h]of s)d.after(l.createComment(h))}function eO(s){let l=s;for(;null!=l;){if(Zl(l))return!0;l=l.parent}return!1}let vN=!1,t1=!1;function hA(){return bc([{provide:tu,useFactory:()=>{let s=!0;return Fu()&&(s=!!or(zm,{optional:!0})?.get($g,null)),s&&dd("NgHydration"),s}},{provide:Hl,useValue:()=>{Mb(!1),Fu()&&or(tu)&&(function tO(){const s=fp();let l;for(const d of s.body.childNodes)if(d.nodeType===Node.COMMENT_NODE&&d.textContent?.trim()===um){l=d;break}if(!l)throw new po(-507,!1)}(),function _N(){vN||(vN=!0,function cy(){jd=Hx}(),function KN(){zw=GN}(),function Ak(){OI=OR}(),function AO(){Gw=IO}(),function ao(){hr=jr}(),function uv(){qy=dg,zh=w_}(),function AS(){Nb=xw}(),function xy(){wy=eT}())}())},multi:!0},{provide:zo,useFactory:()=>Fu()&&or(tu)},{provide:L2,useFactory:()=>{if(Fu()&&or(tu)){const s=or(Jb);return or(Ou),()=>{(function GP(s){return jF(s)})(s).then(()=>{!function Fb(s){const l=s._views;for(const d of l){const h=J0(d);null!==h&&null!==h[Cc]&&(cs(h)?vC(h):gC(h))}}(s)})}}return()=>{}},multi:!0}])}function uk(){return[{provide:$d,useValue:!0},{provide:Hl,useValue:()=>{(function pA(){t1||(t1=!0,function iR(){JS=OO}(),function Ib(){hT=Cw}(),function yT(){_T=bT}())})(),Mb(!0),dd("NgI18nHydration")},multi:!0}]}function dk(s){return"boolean"==typeof s?s:null!=s&&"false"!==s}function yN(s,l=NaN){return isNaN(parseFloat(s))||isNaN(Number(s))?l:Number(s)}function mA(s){return mu().compileDirectiveDeclaration(Mm,`ng:///${s.type.name}/\u0275fac.js`,s)}function fk(s){h2(s.type,s.decorators,s.ctorParameters??null,s.propDecorators??null)}function bN(s){kI(s.type,s.resolveDeferredDeps,(...l)=>{const d=s.resolveMetadata(...l);h2(s.type,d.decorators,d.ctorParameters,d.propDecorators)})}function gA(s){return mu().compileComponentDeclaration(Mm,`ng:///${s.type.name}/\u0275cmp.js`,s)}function CN(s){return mu(function DN(s){switch(s){case od.Directive:return"directive";case od.Component:return"component";case od.Injectable:return"injectable";case od.Pipe:return"pipe";case od.NgModule:return"NgModule"}}(s.target)).compileFactoryDeclaration(Mm,`ng:///${s.type.name}/\u0275fac.js`,s)}function vA(s){return mu().compileInjectableDeclaration(Mm,`ng:///${s.type.name}/\u0275prov.js`,s)}function wN(s){return mu().compileInjectorDeclaration(Mm,`ng:///${s.type.name}/\u0275inj.js`,s)}function pk(s){return mu().compileNgModuleDeclaration(Mm,`ng:///${s.type.name}/\u0275mod.js`,s)}function _A(s){return mu().compilePipeDeclaration(Mm,`ng:///${s.type.name}/\u0275pipe.js`,s)}function xN(s,l){dd("NgSignals");const d=ut(s);return l?.equal&&(d[ie].equal=l.equal),d}function hk(s){const l=Q(null);try{return s()}finally{Q(l)}}const yA=new aa("",{providedIn:"root",factory:()=>or(SN)});let SN=(()=>{class s{static#e=this.\u0275prov=Ks({token:s,providedIn:"root",factory:()=>new mk})}return s})();class mk{constructor(){this.queuedEffectCount=0,this.queues=new Map,this.pendingTasks=or(sm),this.taskId=null}scheduleEffect(l){if(this.enqueue(l),null===this.taskId){const d=this.taskId=this.pendingTasks.add();queueMicrotask(()=>{this.flush(),this.pendingTasks.remove(d),this.taskId=null})}}enqueue(l){const d=l.creationZone;this.queues.has(d)||this.queues.set(d,new Set);const h=this.queues.get(d);h.has(l)||(this.queuedEffectCount++,h.add(l))}flush(){for(;this.queuedEffectCount>0;)for(const[l,d]of this.queues)null===l?this.flushQueue(d):l.run(()=>this.flushQueue(d))}flushQueue(l){for(const d of l)l.delete(d),this.queuedEffectCount--,d.run()}}class gM{constructor(l,d,h,w,L,z){this.scheduler=l,this.effectFn=d,this.creationZone=h,this.injector=L,this.watcher=function gn(s,l,d){const h=Object.create(Yn);d&&(h.consumerAllowSignalWrites=!0),h.fn=s,h.schedule=l;const w=xe=>{h.cleanupFn=xe};return h.ref={notify:()=>wt(h),run:()=>{if(null===h.fn)return;if(function he(){return M}())throw new Error("Schedulers cannot synchronously execute watches while scheduling.");if(h.dirty=!1,h.hasRun&&!ct(h))return;h.hasRun=!0;const xe=ve(h);try{h.cleanupFn(),h.cleanupFn=Nn,h.fn(w)}finally{fn(h,xe)}},cleanup:()=>h.cleanupFn(),destroy:()=>function z(xe){(function L(xe){return null===xe.fn&&null===xe.schedule})(xe)||(en(xe),xe.cleanupFn(),xe.fn=null,xe.schedule=null,xe.cleanupFn=Nn)}(h),[ie]:h},h.ref}(ae=>this.runEffect(ae),()=>this.schedule(),z),this.unregisterOnDestroy=w?.onDestroy(()=>this.destroy())}runEffect(l){try{this.effectFn(l)}catch(d){this.injector.get(Lh,null,{optional:!0})?.handleError(d)}}run(){this.watcher.run()}schedule(){this.scheduler.scheduleEffect(this)}destroy(){this.watcher.destroy(),this.unregisterOnDestroy?.()}}function nO(s,l){dd("NgSignals"),!l?.injector&&Nm();const d=l?.injector??or(Ou),h=!0!==l?.manualCleanup?d.get(ny):null,w=new gM(d.get(yA),s,typeof Zone>"u"?null:Zone.current,h,d,l?.allowSignalWrites??!1),L=d.get(tN,null,{optional:!0});return L&&8&L._lView[Ps]?(L._lView[U]??=[]).push(w.watcher.notify):w.watcher.notify(),w}function EN(s,l){const d=ja(s),h=l.elementInjector||ns();return new hh(d).create(h,l.projectableNodes,l.hostElement,l.environmentInjector)}function uE(s){const l=ja(s);if(!l)return null;const d=new hh(l);return{get selector(){return d.selector},get type(){return d.componentType},get inputs(){return d.inputs},get outputs(){return d.outputs},get ngContentSelectors(){return d.ngContentSelectors},get isStandalone(){return l.standalone},get isSignal(){return l.signals}}}function KP(...s){return s.reduce((l,d)=>Object.assign(l,d,{providers:[...l.providers,...d.providers]}),{providers:[]})}},9417:(Ot,Me,S)=>{S.r(Me),S.d(Me,{AbstractControl:()=>Ro,AbstractControlDirective:()=>Nn,AbstractFormGroupDirective:()=>Jo,COMPOSITION_BUFFER_MODE:()=>ce,CheckboxControlValueAccessor:()=>q,CheckboxRequiredValidator:()=>Ge,ControlContainer:()=>Yn,ControlEvent:()=>Ft,DefaultValueAccessor:()=>le,EmailValidator:()=>Qt,FormArray:()=>zr,FormArrayName:()=>ca,FormBuilder:()=>Ms,FormControl:()=>vr,FormControlDirective:()=>Sc,FormControlName:()=>Rl,FormGroup:()=>Ls,FormGroupDirective:()=>Qc,FormGroupName:()=>ec,FormRecord:()=>za,FormResetEvent:()=>bt,FormSubmittedEvent:()=>mt,FormsModule:()=>zs,MaxLengthValidator:()=>Ci,MaxValidator:()=>Nc,MinLengthValidator:()=>bi,MinValidator:()=>Rc,NG_ASYNC_VALIDATORS:()=>ve,NG_VALIDATORS:()=>wt,NG_VALUE_ACCESSOR:()=>Ee,NgControl:()=>cr,NgControlStatus:()=>Ur,NgControlStatusGroup:()=>eo,NgForm:()=>fr,NgModel:()=>ea,NgModelGroup:()=>Ma,NgSelectOption:()=>ku,NonNullableFormBuilder:()=>Ds,NumberValueAccessor:()=>fl,PatternValidator:()=>$i,PristineChangeEvent:()=>sn,RadioControlValueAccessor:()=>wa,RangeValueAccessor:()=>qc,ReactiveFormsModule:()=>ya,RequiredValidator:()=>re,SelectControlValueAccessor:()=>Aa,SelectMultipleControlValueAccessor:()=>xu,StatusChangeEvent:()=>He,TouchedChangeEvent:()=>Ve,UntypedFormArray:()=>ho,UntypedFormBuilder:()=>Xo,UntypedFormControl:()=>Mo,UntypedFormGroup:()=>Va,VERSION:()=>na,Validators:()=>ct,ValueChangeEvent:()=>it,isFormArray:()=>Vr,isFormControl:()=>ks,isFormGroup:()=>Ao,isFormRecord:()=>vl,\u0275InternalFormsSharedModule:()=>Fr,\u0275NgNoValidate:()=>ga,\u0275NgSelectMultipleOption:()=>Fc});var i=S(1270),e=S(2168),M=S(1647),X=S(9335);let ie=(()=>{class Je{constructor(Oe,Ct){this._renderer=Oe,this._elementRef=Ct,this.onChange=On=>{},this.onTouched=()=>{}}setProperty(Oe,Ct){this._renderer.setProperty(this._elementRef.nativeElement,Oe,Ct)}registerOnTouched(Oe){this.onTouched=Oe}registerOnChange(Oe){this.onChange=Oe}setDisabledState(Oe){this.setProperty("disabled",Oe)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.ElementRef))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je})}return Je})(),Q=(()=>{class Je extends ie{static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,features:[i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Ee=new i.InjectionToken(""),he={provide:Ee,useExisting:(0,i.forwardRef)(()=>q),multi:!0};let q=(()=>{class Je extends Q{writeValue(Oe){this.setProperty("checked",Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("change",function(Qn){return On.onChange(Qn.target.checked)})("blur",function(){return On.onTouched()})},features:[i.\u0275\u0275ProvidersFeature([he]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const oe={provide:Ee,useExisting:(0,i.forwardRef)(()=>le),multi:!0},ce=new i.InjectionToken("");let le=(()=>{class Je extends ie{constructor(Oe,Ct,On){super(Oe,Ct),this._compositionMode=On,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function Z(){const Je=(0,e.\u0275getDOM)()?(0,e.\u0275getDOM)().getUserAgent():"";return/android (\d+)/.test(Je.toLowerCase())}())}writeValue(Oe){this.setProperty("value",Oe??"")}_handleInput(Oe){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(Oe)}_compositionStart(){this._composing=!0}_compositionEnd(Oe){this._composing=!1,this._compositionMode&&this.onChange(Oe)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(ce,8))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("input",function(Qn){return On._handleInput(Qn.target.value)})("blur",function(){return On.onTouched()})("compositionstart",function(){return On._compositionStart()})("compositionend",function(Qn){return On._compositionEnd(Qn.target.value)})},features:[i.\u0275\u0275ProvidersFeature([oe]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();function je(Je){return null==Je||("string"==typeof Je||Array.isArray(Je))&&0===Je.length}function Et(Je){return null!=Je&&"number"==typeof Je.length}const wt=new i.InjectionToken(""),ve=new i.InjectionToken(""),fn=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class ct{static min(at){return en(at)}static max(at){return an(at)}static required(at){return un(at)}static requiredTrue(at){return vn(at)}static email(at){return Pt(at)}static minLength(at){return Ae(at)}static maxLength(at){return dt(at)}static pattern(at){return ut(at)}static nullValidator(at){return null}static compose(at){return An(at)}static composeAsync(at){return qt(at)}}function en(Je){return at=>{if(je(at.value)||je(Je))return null;const Oe=parseFloat(at.value);return!isNaN(Oe)&&Oe<Je?{min:{min:Je,actual:at.value}}:null}}function an(Je){return at=>{if(je(at.value)||je(Je))return null;const Oe=parseFloat(at.value);return!isNaN(Oe)&&Oe>Je?{max:{max:Je,actual:at.value}}:null}}function un(Je){return je(Je.value)?{required:!0}:null}function vn(Je){return!0===Je.value?null:{required:!0}}function Pt(Je){return je(Je.value)||fn.test(Je.value)?null:{email:!0}}function Ae(Je){return at=>je(at.value)||!Et(at.value)?null:at.value.length<Je?{minlength:{requiredLength:Je,actualLength:at.value.length}}:null}function dt(Je){return at=>Et(at.value)&&at.value.length>Je?{maxlength:{requiredLength:Je,actualLength:at.value.length}}:null}function ut(Je){if(!Je)return Mt;let at,Oe;return"string"==typeof Je?(Oe="","^"!==Je.charAt(0)&&(Oe+="^"),Oe+=Je,"$"!==Je.charAt(Je.length-1)&&(Oe+="$"),at=new RegExp(Oe)):(Oe=Je.toString(),at=Je),Ct=>{if(je(Ct.value))return null;const On=Ct.value;return at.test(On)?null:{pattern:{requiredPattern:Oe,actualValue:On}}}}function Mt(Je){return null}function Wt(Je){return null!=Je}function It(Je){return(0,i.\u0275isPromise)(Je)?(0,M.from)(Je):Je}function Vn(Je){let at={};return Je.forEach(Oe=>{at=null!=Oe?{...at,...Oe}:at}),0===Object.keys(at).length?null:at}function pn(Je,at){return at.map(Oe=>Oe(Je))}function ji(Je){return Je.map(at=>function Wn(Je){return!Je.validate}(at)?at:Oe=>at.validate(Oe))}function An(Je){if(!Je)return null;const at=Je.filter(Wt);return 0==at.length?null:function(Oe){return Vn(pn(Oe,at))}}function St(Je){return null!=Je?An(ji(Je)):null}function qt(Je){if(!Je)return null;const at=Je.filter(Wt);return 0==at.length?null:function(Oe){const Ct=pn(Oe,at).map(It);return(0,M.forkJoin)(Ct).pipe((0,X.map)(Vn))}}function Ht(Je){return null!=Je?qt(ji(Je)):null}function on(Je,at){return null===Je?[at]:Array.isArray(Je)?[...Je,at]:[Je,at]}function Cn(Je){return Je._rawValidators}function tn(Je){return Je._rawAsyncValidators}function fi(Je){return Je?Array.isArray(Je)?Je:[Je]:[]}function Zn(Je,at){return Array.isArray(Je)?Je.includes(at):Je===at}function Dn(Je,at){const Oe=fi(at);return fi(Je).forEach(On=>{Zn(Oe,On)||Oe.push(On)}),Oe}function gn(Je,at){return fi(at).filter(Oe=>!Zn(Je,Oe))}class Nn{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(at){this._rawValidators=at||[],this._composedValidatorFn=St(this._rawValidators)}_setAsyncValidators(at){this._rawAsyncValidators=at||[],this._composedAsyncValidatorFn=Ht(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(at){this._onDestroyCallbacks.push(at)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(at=>at()),this._onDestroyCallbacks=[]}reset(at=void 0){this.control&&this.control.reset(at)}hasError(at,Oe){return!!this.control&&this.control.hasError(at,Oe)}getError(at,Oe){return this.control?this.control.getError(at,Oe):null}}class Yn extends Nn{get formDirective(){return null}get path(){return null}}class cr extends Nn{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class Ai{constructor(at){this._cd=at}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}}let Ur=(()=>{class Je extends Ai{constructor(Oe){super(Oe)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(cr,2))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275classProp("ng-untouched",On.isUntouched)("ng-touched",On.isTouched)("ng-pristine",On.isPristine)("ng-dirty",On.isDirty)("ng-valid",On.isValid)("ng-invalid",On.isInvalid)("ng-pending",On.isPending)},features:[i.\u0275\u0275InheritDefinitionFeature]})}return Je})(),eo=(()=>{class Je extends Ai{constructor(Oe){super(Oe)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,10))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275classProp("ng-untouched",On.isUntouched)("ng-touched",On.isTouched)("ng-pristine",On.isPristine)("ng-dirty",On.isDirty)("ng-valid",On.isValid)("ng-invalid",On.isInvalid)("ng-pending",On.isPending)("ng-submitted",On.isSubmitted)},features:[i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Ii="VALID",Ki="INVALID",Jt="PENDING",hi="DISABLED";class Ft{}class it extends Ft{constructor(at,Oe){super(),this.value=at,this.source=Oe}}class sn extends Ft{constructor(at,Oe){super(),this.pristine=at,this.source=Oe}}class Ve extends Ft{constructor(at,Oe){super(),this.touched=at,this.source=Oe}}class He extends Ft{constructor(at,Oe){super(),this.status=at,this.source=Oe}}class mt extends Ft{constructor(at){super(),this.source=at}}class bt extends Ft{constructor(at){super(),this.source=at}}function nn(Je){return(qr(Je)?Je.validators:Je)||null}function Sn(Je,at){return(qr(at)?at.asyncValidators:Je)||null}function qr(Je){return null!=Je&&!Array.isArray(Je)&&"object"==typeof Je}function Bo(Je,at,Oe){const Ct=Je.controls;if(!(at?Object.keys(Ct):Ct).length)throw new i.\u0275RuntimeError(1e3,"");if(!Ct[Oe])throw new i.\u0275RuntimeError(1001,"")}function Eo(Je,at,Oe){Je._forEachChild((Ct,On)=>{if(void 0===Oe[On])throw new i.\u0275RuntimeError(1002,"")})}class Ro{constructor(at,Oe){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=null,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this._status=(0,i.computed)(()=>this.statusReactive()),this.statusReactive=(0,i.signal)(void 0),this._pristine=(0,i.computed)(()=>this.pristineReactive()),this.pristineReactive=(0,i.signal)(!0),this._touched=(0,i.computed)(()=>this.touchedReactive()),this.touchedReactive=(0,i.signal)(!1),this._events=new M.Subject,this.events=this._events.asObservable(),this._onDisabledChange=[],this._assignValidators(at),this._assignAsyncValidators(Oe)}get validator(){return this._composedValidatorFn}set validator(at){this._rawValidators=this._composedValidatorFn=at}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(at){this._rawAsyncValidators=this._composedAsyncValidatorFn=at}get parent(){return this._parent}get status(){return(0,i.untracked)(this.statusReactive)}set status(at){(0,i.untracked)(()=>this.statusReactive.set(at))}get valid(){return this.status===Ii}get invalid(){return this.status===Ki}get pending(){return this.status==Jt}get disabled(){return this.status===hi}get enabled(){return this.status!==hi}get pristine(){return(0,i.untracked)(this.pristineReactive)}set pristine(at){(0,i.untracked)(()=>this.pristineReactive.set(at))}get dirty(){return!this.pristine}get touched(){return(0,i.untracked)(this.touchedReactive)}set touched(at){(0,i.untracked)(()=>this.touchedReactive.set(at))}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(at){this._assignValidators(at)}setAsyncValidators(at){this._assignAsyncValidators(at)}addValidators(at){this.setValidators(Dn(at,this._rawValidators))}addAsyncValidators(at){this.setAsyncValidators(Dn(at,this._rawAsyncValidators))}removeValidators(at){this.setValidators(gn(at,this._rawValidators))}removeAsyncValidators(at){this.setAsyncValidators(gn(at,this._rawAsyncValidators))}hasValidator(at){return Zn(this._rawValidators,at)}hasAsyncValidator(at){return Zn(this._rawAsyncValidators,at)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(at={}){const Oe=!1===this.touched;this.touched=!0;const Ct=at.sourceControl??this;this._parent&&!at.onlySelf&&this._parent.markAsTouched({...at,sourceControl:Ct}),Oe&&!1!==at.emitEvent&&this._events.next(new Ve(!0,Ct))}markAllAsTouched(at={}){this.markAsTouched({onlySelf:!0,emitEvent:at.emitEvent,sourceControl:this}),this._forEachChild(Oe=>Oe.markAllAsTouched(at))}markAsUntouched(at={}){const Oe=!0===this.touched;this.touched=!1,this._pendingTouched=!1;const Ct=at.sourceControl??this;this._forEachChild(On=>{On.markAsUntouched({onlySelf:!0,emitEvent:at.emitEvent,sourceControl:Ct})}),this._parent&&!at.onlySelf&&this._parent._updateTouched(at,Ct),Oe&&!1!==at.emitEvent&&this._events.next(new Ve(!1,Ct))}markAsDirty(at={}){const Oe=!0===this.pristine;this.pristine=!1;const Ct=at.sourceControl??this;this._parent&&!at.onlySelf&&this._parent.markAsDirty({...at,sourceControl:Ct}),Oe&&!1!==at.emitEvent&&this._events.next(new sn(!1,Ct))}markAsPristine(at={}){const Oe=!1===this.pristine;this.pristine=!0,this._pendingDirty=!1;const Ct=at.sourceControl??this;this._forEachChild(On=>{On.markAsPristine({onlySelf:!0,emitEvent:at.emitEvent})}),this._parent&&!at.onlySelf&&this._parent._updatePristine(at,Ct),Oe&&!1!==at.emitEvent&&this._events.next(new sn(!0,Ct))}markAsPending(at={}){this.status=Jt;const Oe=at.sourceControl??this;!1!==at.emitEvent&&(this._events.next(new He(this.status,Oe)),this.statusChanges.emit(this.status)),this._parent&&!at.onlySelf&&this._parent.markAsPending({...at,sourceControl:Oe})}disable(at={}){const Oe=this._parentMarkedDirty(at.onlySelf);this.status=hi,this.errors=null,this._forEachChild(On=>{On.disable({...at,onlySelf:!0})}),this._updateValue();const Ct=at.sourceControl??this;!1!==at.emitEvent&&(this._events.next(new it(this.value,Ct)),this._events.next(new He(this.status,Ct)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...at,skipPristineCheck:Oe},this),this._onDisabledChange.forEach(On=>On(!0))}enable(at={}){const Oe=this._parentMarkedDirty(at.onlySelf);this.status=Ii,this._forEachChild(Ct=>{Ct.enable({...at,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:at.emitEvent}),this._updateAncestors({...at,skipPristineCheck:Oe},this),this._onDisabledChange.forEach(Ct=>Ct(!1))}_updateAncestors(at,Oe){this._parent&&!at.onlySelf&&(this._parent.updateValueAndValidity(at),at.skipPristineCheck||this._parent._updatePristine({},Oe),this._parent._updateTouched({},Oe))}setParent(at){this._parent=at}getRawValue(){return this.value}updateValueAndValidity(at={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){const Ct=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Ii||this.status===Jt)&&this._runAsyncValidator(Ct,at.emitEvent)}const Oe=at.sourceControl??this;!1!==at.emitEvent&&(this._events.next(new it(this.value,Oe)),this._events.next(new He(this.status,Oe)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!at.onlySelf&&this._parent.updateValueAndValidity({...at,sourceControl:Oe})}_updateTreeValidity(at={emitEvent:!0}){this._forEachChild(Oe=>Oe._updateTreeValidity(at)),this.updateValueAndValidity({onlySelf:!0,emitEvent:at.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?hi:Ii}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(at,Oe){if(this.asyncValidator){this.status=Jt,this._hasOwnPendingAsyncValidator={emitEvent:!1!==Oe};const Ct=It(this.asyncValidator(this));this._asyncValidationSubscription=Ct.subscribe(On=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(On,{emitEvent:Oe,shouldHaveEmitted:at})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();const at=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,at}return!1}setErrors(at,Oe={}){this.errors=at,this._updateControlsErrors(!1!==Oe.emitEvent,this,Oe.shouldHaveEmitted)}get(at){let Oe=at;return null==Oe||(Array.isArray(Oe)||(Oe=Oe.split(".")),0===Oe.length)?null:Oe.reduce((Ct,On)=>Ct&&Ct._find(On),this)}getError(at,Oe){const Ct=Oe?this.get(Oe):this;return Ct&&Ct.errors?Ct.errors[at]:null}hasError(at,Oe){return!!this.getError(at,Oe)}get root(){let at=this;for(;at._parent;)at=at._parent;return at}_updateControlsErrors(at,Oe,Ct){this.status=this._calculateStatus(),at&&this.statusChanges.emit(this.status),(at||Ct)&&this._events.next(new He(this.status,Oe)),this._parent&&this._parent._updateControlsErrors(at,Oe,Ct)}_initObservables(){this.valueChanges=new i.EventEmitter,this.statusChanges=new i.EventEmitter}_calculateStatus(){return this._allControlsDisabled()?hi:this.errors?Ki:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Jt)?Jt:this._anyControlsHaveStatus(Ki)?Ki:Ii}_anyControlsHaveStatus(at){return this._anyControls(Oe=>Oe.status===at)}_anyControlsDirty(){return this._anyControls(at=>at.dirty)}_anyControlsTouched(){return this._anyControls(at=>at.touched)}_updatePristine(at,Oe){const Ct=!this._anyControlsDirty(),On=this.pristine!==Ct;this.pristine=Ct,this._parent&&!at.onlySelf&&this._parent._updatePristine(at,Oe),On&&this._events.next(new sn(this.pristine,Oe))}_updateTouched(at={},Oe){this.touched=this._anyControlsTouched(),this._events.next(new Ve(this.touched,Oe)),this._parent&&!at.onlySelf&&this._parent._updateTouched(at,Oe)}_registerOnCollectionChange(at){this._onCollectionChange=at}_setUpdateStrategy(at){qr(at)&&null!=at.updateOn&&(this._updateOn=at.updateOn)}_parentMarkedDirty(at){return!at&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(at){return null}_assignValidators(at){this._rawValidators=Array.isArray(at)?at.slice():at,this._composedValidatorFn=function Jn(Je){return Array.isArray(Je)?St(Je):Je||null}(this._rawValidators)}_assignAsyncValidators(at){this._rawAsyncValidators=Array.isArray(at)?at.slice():at,this._composedAsyncValidatorFn=function _r(Je){return Array.isArray(Je)?Ht(Je):Je||null}(this._rawAsyncValidators)}}class Ls extends Ro{constructor(at,Oe,Ct){super(nn(Oe),Sn(Ct,Oe)),this.controls=at,this._initObservables(),this._setUpdateStrategy(Oe),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(at,Oe){return this.controls[at]?this.controls[at]:(this.controls[at]=Oe,Oe.setParent(this),Oe._registerOnCollectionChange(this._onCollectionChange),Oe)}addControl(at,Oe,Ct={}){this.registerControl(at,Oe),this.updateValueAndValidity({emitEvent:Ct.emitEvent}),this._onCollectionChange()}removeControl(at,Oe={}){this.controls[at]&&this.controls[at]._registerOnCollectionChange(()=>{}),delete this.controls[at],this.updateValueAndValidity({emitEvent:Oe.emitEvent}),this._onCollectionChange()}setControl(at,Oe,Ct={}){this.controls[at]&&this.controls[at]._registerOnCollectionChange(()=>{}),delete this.controls[at],Oe&&this.registerControl(at,Oe),this.updateValueAndValidity({emitEvent:Ct.emitEvent}),this._onCollectionChange()}contains(at){return this.controls.hasOwnProperty(at)&&this.controls[at].enabled}setValue(at,Oe={}){Eo(this,0,at),Object.keys(at).forEach(Ct=>{Bo(this,!0,Ct),this.controls[Ct].setValue(at[Ct],{onlySelf:!0,emitEvent:Oe.emitEvent})}),this.updateValueAndValidity(Oe)}patchValue(at,Oe={}){null!=at&&(Object.keys(at).forEach(Ct=>{const On=this.controls[Ct];On&&On.patchValue(at[Ct],{onlySelf:!0,emitEvent:Oe.emitEvent})}),this.updateValueAndValidity(Oe))}reset(at={},Oe={}){this._forEachChild((Ct,On)=>{Ct.reset(at?at[On]:null,{onlySelf:!0,emitEvent:Oe.emitEvent})}),this._updatePristine(Oe,this),this._updateTouched(Oe,this),this.updateValueAndValidity(Oe)}getRawValue(){return this._reduceChildren({},(at,Oe,Ct)=>(at[Ct]=Oe.getRawValue(),at))}_syncPendingControls(){let at=this._reduceChildren(!1,(Oe,Ct)=>!!Ct._syncPendingControls()||Oe);return at&&this.updateValueAndValidity({onlySelf:!0}),at}_forEachChild(at){Object.keys(this.controls).forEach(Oe=>{const Ct=this.controls[Oe];Ct&&at(Ct,Oe)})}_setUpControls(){this._forEachChild(at=>{at.setParent(this),at._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(at){for(const[Oe,Ct]of Object.entries(this.controls))if(this.contains(Oe)&&at(Ct))return!0;return!1}_reduceValue(){return this._reduceChildren({},(Oe,Ct,On)=>((Ct.enabled||this.disabled)&&(Oe[On]=Ct.value),Oe))}_reduceChildren(at,Oe){let Ct=at;return this._forEachChild((On,_i)=>{Ct=Oe(Ct,On,_i)}),Ct}_allControlsDisabled(){for(const at of Object.keys(this.controls))if(this.controls[at].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(at){return this.controls.hasOwnProperty(at)?this.controls[at]:null}}const Va=Ls,Ao=Je=>Je instanceof Ls;class za extends Ls{}const vl=Je=>Je instanceof za,Na=new i.InjectionToken("CallSetDisabledState",{providedIn:"root",factory:()=>_l}),_l="always";function gs(Je,at){return[...at.path,Je]}function Zs(Je,at,Oe=_l){Qr(Je,at),at.valueAccessor.writeValue(Je.value),(Je.disabled||"always"===Oe)&&at.valueAccessor.setDisabledState?.(Je.disabled),function Ya(Je,at){at.valueAccessor.registerOnChange(Oe=>{Je._pendingValue=Oe,Je._pendingChange=!0,Je._pendingDirty=!0,"change"===Je.updateOn&&ko(Je,at)})}(Je,at),function jt(Je,at){const Oe=(Ct,On)=>{at.valueAccessor.writeValue(Ct),On&&at.viewToModelUpdate(Ct)};Je.registerOnChange(Oe),at._registerOnDestroy(()=>{Je._unregisterOnChange(Oe)})}(Je,at),function Lo(Je,at){at.valueAccessor.registerOnTouched(()=>{Je._pendingTouched=!0,"blur"===Je.updateOn&&Je._pendingChange&&ko(Je,at),"submit"!==Je.updateOn&&Je.markAsTouched()})}(Je,at),function xl(Je,at){if(at.valueAccessor.setDisabledState){const Oe=Ct=>{at.valueAccessor.setDisabledState(Ct)};Je.registerOnDisabledChange(Oe),at._registerOnDestroy(()=>{Je._unregisterOnDisabledChange(Oe)})}}(Je,at)}function oa(Je,at,Oe=!0){const Ct=()=>{};at.valueAccessor&&(at.valueAccessor.registerOnChange(Ct),at.valueAccessor.registerOnTouched(Ct)),dl(Je,at),Je&&(at._invokeOnDestroyCallbacks(),Je._registerOnCollectionChange(()=>{}))}function no(Je,at){Je.forEach(Oe=>{Oe.registerOnValidatorChange&&Oe.registerOnValidatorChange(at)})}function Qr(Je,at){const Oe=Cn(Je);null!==at.validator?Je.setValidators(on(Oe,at.validator)):"function"==typeof Oe&&Je.setValidators([Oe]);const Ct=tn(Je);null!==at.asyncValidator?Je.setAsyncValidators(on(Ct,at.asyncValidator)):"function"==typeof Ct&&Je.setAsyncValidators([Ct]);const On=()=>Je.updateValueAndValidity();no(at._rawValidators,On),no(at._rawAsyncValidators,On)}function dl(Je,at){let Oe=!1;if(null!==Je){if(null!==at.validator){const On=Cn(Je);if(Array.isArray(On)&&On.length>0){const _i=On.filter(Qn=>Qn!==at.validator);_i.length!==On.length&&(Oe=!0,Je.setValidators(_i))}}if(null!==at.asyncValidator){const On=tn(Je);if(Array.isArray(On)&&On.length>0){const _i=On.filter(Qn=>Qn!==at.asyncValidator);_i.length!==On.length&&(Oe=!0,Je.setAsyncValidators(_i))}}}const Ct=()=>{};return no(at._rawValidators,Ct),no(at._rawAsyncValidators,Ct),Oe}function ko(Je,at){Je._pendingDirty&&Je.markAsDirty(),Je.setValue(Je._pendingValue,{emitModelToViewChange:!1}),at.viewToModelUpdate(Je._pendingValue),Je._pendingChange=!1}function In(Je,at){Qr(Je,at)}function Or(Je,at){if(!Je.hasOwnProperty("model"))return!1;const Oe=Je.model;return!!Oe.isFirstChange()||!Object.is(at,Oe.currentValue)}function cn(Je,at){Je._syncPendingControls(),at.forEach(Oe=>{const Ct=Oe.control;"submit"===Ct.updateOn&&Ct._pendingChange&&(Oe.viewToModelUpdate(Ct._pendingValue),Ct._pendingChange=!1)})}function Tn(Je,at){if(!at)return null;let Oe,Ct,On;return Array.isArray(at),at.forEach(_i=>{_i.constructor===le?Oe=_i:function Tt(Je){return Object.getPrototypeOf(Je.constructor)===Q}(_i)?Ct=_i:On=_i}),On||Ct||Oe||null}const Yi={provide:Yn,useExisting:(0,i.forwardRef)(()=>fr)},Wi=Promise.resolve();let fr=(()=>{class Je extends Yn{get submitted(){return(0,i.untracked)(this.submittedReactive)}constructor(Oe,Ct,On){super(),this.callSetDisabledState=On,this._submitted=(0,i.computed)(()=>this.submittedReactive()),this.submittedReactive=(0,i.signal)(!1),this._directives=new Set,this.ngSubmit=new i.EventEmitter,this.form=new Ls({},St(Oe),Ht(Ct))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(Oe){Wi.then(()=>{const Ct=this._findContainer(Oe.path);Oe.control=Ct.registerControl(Oe.name,Oe.control),Zs(Oe.control,Oe,this.callSetDisabledState),Oe.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(Oe)})}getControl(Oe){return this.form.get(Oe.path)}removeControl(Oe){Wi.then(()=>{const Ct=this._findContainer(Oe.path);Ct&&Ct.removeControl(Oe.name),this._directives.delete(Oe)})}addFormGroup(Oe){Wi.then(()=>{const Ct=this._findContainer(Oe.path),On=new Ls({});In(On,Oe),Ct.registerControl(Oe.name,On),On.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(Oe){Wi.then(()=>{const Ct=this._findContainer(Oe.path);Ct&&Ct.removeControl(Oe.name)})}getFormGroup(Oe){return this.form.get(Oe.path)}updateModel(Oe,Ct){Wi.then(()=>{this.form.get(Oe.path).setValue(Ct)})}setValue(Oe){this.control.setValue(Oe)}onSubmit(Oe){return this.submittedReactive.set(!0),cn(this.form,this._directives),this.ngSubmit.emit(Oe),"dialog"===Oe?.target?.method}onReset(){this.resetForm()}resetForm(Oe=void 0){this.form.reset(Oe),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(Oe){return Oe.pop(),Oe.length?this.form.get(Oe):this.form}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10),i.\u0275\u0275directiveInject(Na,8))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("submit",function(Qn){return On.onSubmit(Qn)})("reset",function(){return On.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[i.\u0275\u0275ProvidersFeature([Yi]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();function Li(Je,at){const Oe=Je.indexOf(at);Oe>-1&&Je.splice(Oe,1)}function Vo(Je){return"object"==typeof Je&&null!==Je&&2===Object.keys(Je).length&&"value"in Je&&"disabled"in Je}const vr=class extends Ro{constructor(at=null,Oe,Ct){super(nn(Oe),Sn(Ct,Oe)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(at),this._setUpdateStrategy(Oe),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),qr(Oe)&&(Oe.nonNullable||Oe.initialValueIsDefault)&&(this.defaultValue=Vo(at)?at.value:at)}setValue(at,Oe={}){this.value=this._pendingValue=at,this._onChange.length&&!1!==Oe.emitModelToViewChange&&this._onChange.forEach(Ct=>Ct(this.value,!1!==Oe.emitViewToModelChange)),this.updateValueAndValidity(Oe)}patchValue(at,Oe={}){this.setValue(at,Oe)}reset(at=this.defaultValue,Oe={}){this._applyFormState(at),this.markAsPristine(Oe),this.markAsUntouched(Oe),this.setValue(this.value,Oe),this._pendingChange=!1}_updateValue(){}_anyControls(at){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(at){this._onChange.push(at)}_unregisterOnChange(at){Li(this._onChange,at)}registerOnDisabledChange(at){this._onDisabledChange.push(at)}_unregisterOnDisabledChange(at){Li(this._onDisabledChange,at)}_forEachChild(at){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(at){Vo(at)?(this.value=this._pendingValue=at.value,at.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=at}},Mo=vr,ks=Je=>Je instanceof vr;let Jo=(()=>{class Je extends Yn{ngOnInit(){this._checkParentType(),this.formDirective.addFormGroup(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormGroup(this)}get control(){return this.formDirective.getFormGroup(this)}get path(){return gs(null==this.name?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,features:[i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const es={provide:Yn,useExisting:(0,i.forwardRef)(()=>Ma)};let Ma=(()=>{class Je extends Jo{constructor(Oe,Ct,On){super(),this.name="",this._parent=Oe,this._setValidators(Ct),this._setAsyncValidators(On)}_checkParentType(){}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,5),i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","ngModelGroup",""]],inputs:{name:[0,"ngModelGroup","name"]},exportAs:["ngModelGroup"],features:[i.\u0275\u0275ProvidersFeature([es]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const ts={provide:cr,useExisting:(0,i.forwardRef)(()=>ea)},wo=Promise.resolve();let ea=(()=>{class Je extends cr{constructor(Oe,Ct,On,_i,Qn,qi){super(),this._changeDetectorRef=Qn,this.callSetDisabledState=qi,this.control=new vr,this._registered=!1,this.name="",this.update=new i.EventEmitter,this._parent=Oe,this._setValidators(Ct),this._setAsyncValidators(On),this.valueAccessor=Tn(0,_i)}ngOnChanges(Oe){if(this._checkForErrors(),!this._registered||"name"in Oe){if(this._registered&&(this._checkName(),this.formDirective)){const Ct=Oe.name.previousValue;this.formDirective.removeControl({name:Ct,path:this._getPath(Ct)})}this._setUpControl()}"isDisabled"in Oe&&this._updateDisabled(Oe),Or(Oe,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(Oe){this.viewModel=Oe,this.update.emit(Oe)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){Zs(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(Oe){wo.then(()=>{this.control.setValue(Oe,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(Oe){const Ct=Oe.isDisabled.currentValue,On=0!==Ct&&(0,i.booleanAttribute)(Ct);wo.then(()=>{On&&!this.control.disabled?this.control.disable():!On&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(Oe){return this._parent?gs(Oe,this._parent):[Oe]}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,9),i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10),i.\u0275\u0275directiveInject(Ee,10),i.\u0275\u0275directiveInject(i.ChangeDetectorRef,8),i.\u0275\u0275directiveInject(Na,8))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,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"],features:[i.\u0275\u0275ProvidersFeature([ts]),i.\u0275\u0275InheritDefinitionFeature,i.\u0275\u0275NgOnChangesFeature]})}return Je})(),ga=(()=>{class Je{static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]})}return Je})();const sl={provide:Ee,useExisting:(0,i.forwardRef)(()=>fl),multi:!0};let fl=(()=>{class Je extends Q{writeValue(Oe){this.setProperty("value",Oe??"")}registerOnChange(Oe){this.onChange=Ct=>{Oe(""==Ct?null:parseFloat(Ct))}}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("input",function(Qn){return On.onChange(Qn.target.value)})("blur",function(){return On.onTouched()})},features:[i.\u0275\u0275ProvidersFeature([sl]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Ia={provide:Ee,useExisting:(0,i.forwardRef)(()=>wa),multi:!0};let Kc=(()=>{class Je{constructor(){this._accessors=[]}add(Oe,Ct){this._accessors.push([Oe,Ct])}remove(Oe){for(let Ct=this._accessors.length-1;Ct>=0;--Ct)if(this._accessors[Ct][1]===Oe)return void this._accessors.splice(Ct,1)}select(Oe){this._accessors.forEach(Ct=>{this._isSameGroup(Ct,Oe)&&Ct[1]!==Oe&&Ct[1].fireUncheck(Oe.value)})}_isSameGroup(Oe,Ct){return!!Oe[0].control&&Oe[0]._parent===Ct._control._parent&&Oe[1].name===Ct.name}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Je,factory:Je.\u0275fac,providedIn:"root"})}return Je})(),wa=(()=>{class Je extends Q{constructor(Oe,Ct,On,_i){super(Oe,Ct),this._registry=On,this._injector=_i,this.setDisabledStateFired=!1,this.onChange=()=>{},this.callSetDisabledState=(0,i.inject)(Na,{optional:!0})??_l}ngOnInit(){this._control=this._injector.get(cr),this._checkName(),this._registry.add(this._control,this)}ngOnDestroy(){this._registry.remove(this)}writeValue(Oe){this._state=Oe===this.value,this.setProperty("checked",this._state)}registerOnChange(Oe){this._fn=Oe,this.onChange=()=>{Oe(this.value),this._registry.select(this)}}setDisabledState(Oe){(this.setDisabledStateFired||Oe||"whenDisabledForLegacyCode"===this.callSetDisabledState)&&this.setProperty("disabled",Oe),this.setDisabledStateFired=!0}fireUncheck(Oe){this.writeValue(Oe)}_checkName(){!this.name&&this.formControlName&&(this.name=this.formControlName)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(Kc),i.\u0275\u0275directiveInject(i.Injector))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","radio","formControlName",""],["input","type","radio","formControl",""],["input","type","radio","ngModel",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("change",function(){return On.onChange()})("blur",function(){return On.onTouched()})},inputs:{name:"name",formControlName:"formControlName",value:"value"},features:[i.\u0275\u0275ProvidersFeature([Ia]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Sl={provide:Ee,useExisting:(0,i.forwardRef)(()=>qc),multi:!0};let qc=(()=>{class Je extends Q{writeValue(Oe){this.setProperty("value",parseFloat(Oe))}registerOnChange(Oe){this.onChange=Ct=>{Oe(""==Ct?null:parseFloat(Ct))}}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","range","formControlName",""],["input","type","range","formControl",""],["input","type","range","ngModel",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("change",function(Qn){return On.onChange(Qn.target.value)})("input",function(Qn){return On.onChange(Qn.target.value)})("blur",function(){return On.onTouched()})},features:[i.\u0275\u0275ProvidersFeature([Sl]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const la=new i.InjectionToken(""),pl={provide:cr,useExisting:(0,i.forwardRef)(()=>Sc)};let Sc=(()=>{class Je extends cr{set isDisabled(Oe){}static#e=this._ngModelWarningSentOnce=!1;constructor(Oe,Ct,On,_i,Qn){super(),this._ngModelWarningConfig=_i,this.callSetDisabledState=Qn,this.update=new i.EventEmitter,this._ngModelWarningSent=!1,this._setValidators(Oe),this._setAsyncValidators(Ct),this.valueAccessor=Tn(0,On)}ngOnChanges(Oe){if(this._isControlChanged(Oe)){const Ct=Oe.form.previousValue;Ct&&oa(Ct,this,!1),Zs(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}Or(Oe,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&oa(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(Oe){this.viewModel=Oe,this.update.emit(Oe)}_isControlChanged(Oe){return Oe.hasOwnProperty("form")}static#t=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10),i.\u0275\u0275directiveInject(Ee,10),i.\u0275\u0275directiveInject(la,8),i.\u0275\u0275directiveInject(Na,8))};static#n=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],features:[i.\u0275\u0275ProvidersFeature([pl]),i.\u0275\u0275InheritDefinitionFeature,i.\u0275\u0275NgOnChangesFeature]})}return Je})();const Ec={provide:Yn,useExisting:(0,i.forwardRef)(()=>Qc)};let Qc=(()=>{class Je extends Yn{get submitted(){return(0,i.untracked)(this._submittedReactive)}set submitted(Oe){this._submittedReactive.set(Oe)}constructor(Oe,Ct,On){super(),this.callSetDisabledState=On,this._submitted=(0,i.computed)(()=>this._submittedReactive()),this._submittedReactive=(0,i.signal)(!1),this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new i.EventEmitter,this._setValidators(Oe),this._setAsyncValidators(Ct)}ngOnChanges(Oe){this._checkFormPresent(),Oe.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(dl(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(Oe){const Ct=this.form.get(Oe.path);return Zs(Ct,Oe,this.callSetDisabledState),Ct.updateValueAndValidity({emitEvent:!1}),this.directives.push(Oe),Ct}getControl(Oe){return this.form.get(Oe.path)}removeControl(Oe){oa(Oe.control||null,Oe,!1),function Ri(Je,at){const Oe=Je.indexOf(at);Oe>-1&&Je.splice(Oe,1)}(this.directives,Oe)}addFormGroup(Oe){this._setUpFormContainer(Oe)}removeFormGroup(Oe){this._cleanUpFormContainer(Oe)}getFormGroup(Oe){return this.form.get(Oe.path)}addFormArray(Oe){this._setUpFormContainer(Oe)}removeFormArray(Oe){this._cleanUpFormContainer(Oe)}getFormArray(Oe){return this.form.get(Oe.path)}updateModel(Oe,Ct){this.form.get(Oe.path).setValue(Ct)}onSubmit(Oe){return this._submittedReactive.set(!0),cn(this.form,this.directives),this.ngSubmit.emit(Oe),this.form._events.next(new mt(this.control)),"dialog"===Oe?.target?.method}onReset(){this.resetForm()}resetForm(Oe=void 0){this.form.reset(Oe),this._submittedReactive.set(!1),this.form._events.next(new bt(this.form))}_updateDomValue(){this.directives.forEach(Oe=>{const Ct=Oe.control,On=this.form.get(Oe.path);Ct!==On&&(oa(Ct||null,Oe),ks(On)&&(Zs(On,Oe,this.callSetDisabledState),Oe.control=On))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(Oe){const Ct=this.form.get(Oe.path);In(Ct,Oe),Ct.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(Oe){if(this.form){const Ct=this.form.get(Oe.path);Ct&&function Rt(Je,at){return dl(Je,at)}(Ct,Oe)&&Ct.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){Qr(this.form,this),this._oldForm&&dl(this._oldForm,this)}_checkFormPresent(){}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10),i.\u0275\u0275directiveInject(Na,8))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formGroup",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("submit",function(Qn){return On.onSubmit(Qn)})("reset",function(){return On.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[i.\u0275\u0275ProvidersFeature([Ec]),i.\u0275\u0275InheritDefinitionFeature,i.\u0275\u0275NgOnChangesFeature]})}return Je})();const ql={provide:Yn,useExisting:(0,i.forwardRef)(()=>ec)};let ec=(()=>{class Je extends Jo{constructor(Oe,Ct,On){super(),this.name=null,this._parent=Oe,this._setValidators(Ct),this._setAsyncValidators(On)}_checkParentType(){Il(this._parent)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,13),i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formGroupName",""]],inputs:{name:[0,"formGroupName","name"]},features:[i.\u0275\u0275ProvidersFeature([ql]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Yc={provide:Yn,useExisting:(0,i.forwardRef)(()=>ca)};let ca=(()=>{class Je extends Yn{constructor(Oe,Ct,On){super(),this.name=null,this._parent=Oe,this._setValidators(Ct),this._setAsyncValidators(On)}ngOnInit(){this._checkParentType(),this.formDirective.addFormArray(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormArray(this)}get control(){return this.formDirective.getFormArray(this)}get formDirective(){return this._parent?this._parent.formDirective:null}get path(){return gs(null==this.name?this.name:this.name.toString(),this._parent)}_checkParentType(){Il(this._parent)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,13),i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formArrayName",""]],inputs:{name:[0,"formArrayName","name"]},features:[i.\u0275\u0275ProvidersFeature([Yc]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();function Il(Je){return!(Je instanceof ec||Je instanceof Qc||Je instanceof ca)}const Xa={provide:cr,useExisting:(0,i.forwardRef)(()=>Rl)};let Rl=(()=>{class Je extends cr{set isDisabled(Oe){}static#e=this._ngModelWarningSentOnce=!1;constructor(Oe,Ct,On,_i,Qn){super(),this._ngModelWarningConfig=Qn,this._added=!1,this.name=null,this.update=new i.EventEmitter,this._ngModelWarningSent=!1,this._parent=Oe,this._setValidators(Ct),this._setAsyncValidators(On),this.valueAccessor=Tn(0,_i)}ngOnChanges(Oe){this._added||this._setUpControl(),Or(Oe,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(Oe){this.viewModel=Oe,this.update.emit(Oe)}get path(){return gs(null==this.name?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this._added=!0}static#t=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(Yn,13),i.\u0275\u0275directiveInject(wt,10),i.\u0275\u0275directiveInject(ve,10),i.\u0275\u0275directiveInject(Ee,10),i.\u0275\u0275directiveInject(la,8))};static#n=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},features:[i.\u0275\u0275ProvidersFeature([Xa]),i.\u0275\u0275InheritDefinitionFeature,i.\u0275\u0275NgOnChangesFeature]})}return Je})();const yl={provide:Ee,useExisting:(0,i.forwardRef)(()=>Aa),multi:!0};function sa(Je,at){return null==Je?`${at}`:(at&&"object"==typeof at&&(at="Object"),`${Je}: ${at}`.slice(0,50))}let Aa=(()=>{class Je extends Q{constructor(){super(...arguments),this._optionMap=new Map,this._idCounter=0,this._compareWith=Object.is}set compareWith(Oe){this._compareWith=Oe}writeValue(Oe){this.value=Oe;const On=sa(this._getOptionId(Oe),Oe);this.setProperty("value",On)}registerOnChange(Oe){this.onChange=Ct=>{this.value=this._getOptionValue(Ct),Oe(this.value)}}_registerOption(){return(this._idCounter++).toString()}_getOptionId(Oe){for(const Ct of this._optionMap.keys())if(this._compareWith(this._optionMap.get(Ct),Oe))return Ct;return null}_getOptionValue(Oe){const Ct=function Lu(Je){return Je.split(":")[0]}(Oe);return this._optionMap.has(Ct)?this._optionMap.get(Ct):Oe}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["select","formControlName","",3,"multiple",""],["select","formControl","",3,"multiple",""],["select","ngModel","",3,"multiple",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("change",function(Qn){return On.onChange(Qn.target.value)})("blur",function(){return On.onTouched()})},inputs:{compareWith:"compareWith"},features:[i.\u0275\u0275ProvidersFeature([yl]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})(),ku=(()=>{class Je{constructor(Oe,Ct,On){this._element=Oe,this._renderer=Ct,this._select=On,this._select&&(this.id=this._select._registerOption())}set ngValue(Oe){null!=this._select&&(this._select._optionMap.set(this.id,Oe),this._setElementValue(sa(this.id,Oe)),this._select.writeValue(this._select.value))}set value(Oe){this._setElementValue(Oe),this._select&&this._select.writeValue(this._select.value)}_setElementValue(Oe){this._renderer.setProperty(this._element.nativeElement,"value",Oe)}ngOnDestroy(){this._select&&(this._select._optionMap.delete(this.id),this._select.writeValue(this._select.value))}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(Aa,9))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"}})}return Je})();const Ql={provide:Ee,useExisting:(0,i.forwardRef)(()=>xu),multi:!0};function sc(Je,at){return null==Je?`${at}`:("string"==typeof at&&(at=`'${at}'`),at&&"object"==typeof at&&(at="Object"),`${Je}: ${at}`.slice(0,50))}let xu=(()=>{class Je extends Q{constructor(){super(...arguments),this._optionMap=new Map,this._idCounter=0,this._compareWith=Object.is}set compareWith(Oe){this._compareWith=Oe}writeValue(Oe){let Ct;if(this.value=Oe,Array.isArray(Oe)){const On=Oe.map(_i=>this._getOptionId(_i));Ct=(_i,Qn)=>{_i._setSelected(On.indexOf(Qn.toString())>-1)}}else Ct=(On,_i)=>{On._setSelected(!1)};this._optionMap.forEach(Ct)}registerOnChange(Oe){this.onChange=Ct=>{const On=[],_i=Ct.selectedOptions;if(void 0!==_i){const Qn=_i;for(let qi=0;qi<Qn.length;qi++){const fo=this._getOptionValue(Qn[qi].value);On.push(fo)}}else{const Qn=Ct.options;for(let qi=0;qi<Qn.length;qi++){const Di=Qn[qi];if(Di.selected){const fo=this._getOptionValue(Di.value);On.push(fo)}}}this.value=On,Oe(On)}}_registerOption(Oe){const Ct=(this._idCounter++).toString();return this._optionMap.set(Ct,Oe),Ct}_getOptionId(Oe){for(const Ct of this._optionMap.keys())if(this._compareWith(this._optionMap.get(Ct)._value,Oe))return Ct;return null}_getOptionValue(Oe){const Ct=function ta(Je){return Je.split(":")[0]}(Oe);return this._optionMap.has(Ct)?this._optionMap.get(Ct)._value:Oe}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["select","multiple","","formControlName",""],["select","multiple","","formControl",""],["select","multiple","","ngModel",""]],hostBindings:function(Ct,On){1&Ct&&i.\u0275\u0275listener("change",function(Qn){return On.onChange(Qn.target)})("blur",function(){return On.onTouched()})},inputs:{compareWith:"compareWith"},features:[i.\u0275\u0275ProvidersFeature([Ql]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})(),Fc=(()=>{class Je{constructor(Oe,Ct,On){this._element=Oe,this._renderer=Ct,this._select=On,this._select&&(this.id=this._select._registerOption(this))}set ngValue(Oe){null!=this._select&&(this._value=Oe,this._setElementValue(sc(this.id,Oe)),this._select.writeValue(this._select.value))}set value(Oe){this._select?(this._value=Oe,this._setElementValue(sc(this.id,Oe)),this._select.writeValue(this._select.value)):this._setElementValue(Oe)}_setElementValue(Oe){this._renderer.setProperty(this._element.nativeElement,"value",Oe)}_setSelected(Oe){this._renderer.setProperty(this._element.nativeElement,"selected",Oe)}ngOnDestroy(){this._select&&(this._select._optionMap.delete(this.id),this._select.writeValue(this._select.value))}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(xu,9))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"}})}return Je})();function po(Je){return"number"==typeof Je?Je:parseInt(Je,10)}function Ll(Je){return"number"==typeof Je?Je:parseFloat(Je)}let Hs=(()=>{class Je{constructor(){this._validator=Mt}ngOnChanges(Oe){if(this.inputName in Oe){const Ct=this.normalizeInput(Oe[this.inputName].currentValue);this._enabled=this.enabled(Ct),this._validator=this._enabled?this.createValidator(Ct):Mt,this._onChange&&this._onChange()}}validate(Oe){return this._validator(Oe)}registerOnValidatorChange(Oe){this._onChange=Oe}enabled(Oe){return null!=Oe}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,features:[i.\u0275\u0275NgOnChangesFeature]})}return Je})();const kl={provide:wt,useExisting:(0,i.forwardRef)(()=>Nc),multi:!0};let Nc=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="max",this.normalizeInput=Oe=>Ll(Oe),this.createValidator=Oe=>an(Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","number","max","","formControlName",""],["input","type","number","max","","formControl",""],["input","type","number","max","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("max",On._enabled?On.max:null)},inputs:{max:"max"},features:[i.\u0275\u0275ProvidersFeature([kl]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const fu={provide:wt,useExisting:(0,i.forwardRef)(()=>Rc),multi:!0};let Rc=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="min",this.normalizeInput=Oe=>Ll(Oe),this.createValidator=Oe=>en(Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","number","min","","formControlName",""],["input","type","number","min","","formControl",""],["input","type","number","min","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("min",On._enabled?On.min:null)},inputs:{min:"min"},features:[i.\u0275\u0275ProvidersFeature([fu]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Ke={provide:wt,useExisting:(0,i.forwardRef)(()=>re),multi:!0},Se={provide:wt,useExisting:(0,i.forwardRef)(()=>Ge),multi:!0};let re=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="required",this.normalizeInput=i.booleanAttribute,this.createValidator=Oe=>un}enabled(Oe){return Oe}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("required",On._enabled?"":null)},inputs:{required:"required"},features:[i.\u0275\u0275ProvidersFeature([Ke]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})(),Ge=(()=>{class Je extends re{constructor(){super(...arguments),this.createValidator=Oe=>vn}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["input","type","checkbox","required","","formControlName",""],["input","type","checkbox","required","","formControl",""],["input","type","checkbox","required","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("required",On._enabled?"":null)},features:[i.\u0275\u0275ProvidersFeature([Se]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const xt={provide:wt,useExisting:(0,i.forwardRef)(()=>Qt),multi:!0};let Qt=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="email",this.normalizeInput=i.booleanAttribute,this.createValidator=Oe=>Pt}enabled(Oe){return Oe}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","email","","formControlName",""],["","email","","formControl",""],["","email","","ngModel",""]],inputs:{email:"email"},features:[i.\u0275\u0275ProvidersFeature([xt]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const kn={provide:wt,useExisting:(0,i.forwardRef)(()=>bi),multi:!0};let bi=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="minlength",this.normalizeInput=Oe=>po(Oe),this.createValidator=Oe=>Ae(Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","minlength","","formControlName",""],["","minlength","","formControl",""],["","minlength","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("minlength",On._enabled?On.minlength:null)},inputs:{minlength:"minlength"},features:[i.\u0275\u0275ProvidersFeature([kn]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const vi={provide:wt,useExisting:(0,i.forwardRef)(()=>Ci),multi:!0};let Ci=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="maxlength",this.normalizeInput=Oe=>po(Oe),this.createValidator=Oe=>dt(Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","maxlength","","formControlName",""],["","maxlength","","formControl",""],["","maxlength","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("maxlength",On._enabled?On.maxlength:null)},inputs:{maxlength:"maxlength"},features:[i.\u0275\u0275ProvidersFeature([vi]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})();const Xi={provide:wt,useExisting:(0,i.forwardRef)(()=>$i),multi:!0};let $i=(()=>{class Je extends Hs{constructor(){super(...arguments),this.inputName="pattern",this.normalizeInput=Oe=>Oe,this.createValidator=Oe=>ut(Oe)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Je,selectors:[["","pattern","","formControlName",""],["","pattern","","formControl",""],["","pattern","","ngModel",""]],hostVars:1,hostBindings:function(Ct,On){2&Ct&&i.\u0275\u0275attribute("pattern",On._enabled?On.pattern:null)},inputs:{pattern:"pattern"},features:[i.\u0275\u0275ProvidersFeature([Xi]),i.\u0275\u0275InheritDefinitionFeature]})}return Je})(),Fr=(()=>{class Je{static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:Je});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return Je})();class zr extends Ro{constructor(at,Oe,Ct){super(nn(Oe),Sn(Ct,Oe)),this.controls=at,this._initObservables(),this._setUpdateStrategy(Oe),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}at(at){return this.controls[this._adjustIndex(at)]}push(at,Oe={}){this.controls.push(at),this._registerControl(at),this.updateValueAndValidity({emitEvent:Oe.emitEvent}),this._onCollectionChange()}insert(at,Oe,Ct={}){this.controls.splice(at,0,Oe),this._registerControl(Oe),this.updateValueAndValidity({emitEvent:Ct.emitEvent})}removeAt(at,Oe={}){let Ct=this._adjustIndex(at);Ct<0&&(Ct=0),this.controls[Ct]&&this.controls[Ct]._registerOnCollectionChange(()=>{}),this.controls.splice(Ct,1),this.updateValueAndValidity({emitEvent:Oe.emitEvent})}setControl(at,Oe,Ct={}){let On=this._adjustIndex(at);On<0&&(On=0),this.controls[On]&&this.controls[On]._registerOnCollectionChange(()=>{}),this.controls.splice(On,1),Oe&&(this.controls.splice(On,0,Oe),this._registerControl(Oe)),this.updateValueAndValidity({emitEvent:Ct.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(at,Oe={}){Eo(this,0,at),at.forEach((Ct,On)=>{Bo(this,!1,On),this.at(On).setValue(Ct,{onlySelf:!0,emitEvent:Oe.emitEvent})}),this.updateValueAndValidity(Oe)}patchValue(at,Oe={}){null!=at&&(at.forEach((Ct,On)=>{this.at(On)&&this.at(On).patchValue(Ct,{onlySelf:!0,emitEvent:Oe.emitEvent})}),this.updateValueAndValidity(Oe))}reset(at=[],Oe={}){this._forEachChild((Ct,On)=>{Ct.reset(at[On],{onlySelf:!0,emitEvent:Oe.emitEvent})}),this._updatePristine(Oe,this),this._updateTouched(Oe,this),this.updateValueAndValidity(Oe)}getRawValue(){return this.controls.map(at=>at.getRawValue())}clear(at={}){this.controls.length<1||(this._forEachChild(Oe=>Oe._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:at.emitEvent}))}_adjustIndex(at){return at<0?at+this.length:at}_syncPendingControls(){let at=this.controls.reduce((Oe,Ct)=>!!Ct._syncPendingControls()||Oe,!1);return at&&this.updateValueAndValidity({onlySelf:!0}),at}_forEachChild(at){this.controls.forEach((Oe,Ct)=>{at(Oe,Ct)})}_updateValue(){this.value=this.controls.filter(at=>at.enabled||this.disabled).map(at=>at.value)}_anyControls(at){return this.controls.some(Oe=>Oe.enabled&&at(Oe))}_setUpControls(){this._forEachChild(at=>this._registerControl(at))}_allControlsDisabled(){for(const at of this.controls)if(at.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(at){at.setParent(this),at._registerOnCollectionChange(this._onCollectionChange)}_find(at){return this.at(at)??null}}const ho=zr,Vr=Je=>Je instanceof zr;function is(Je){return!!Je&&(void 0!==Je.asyncValidators||void 0!==Je.validators||void 0!==Je.updateOn)}let Ms=(()=>{class Je{constructor(){this.useNonNullable=!1}get nonNullable(){const Oe=new Je;return Oe.useNonNullable=!0,Oe}group(Oe,Ct=null){const On=this._reduceControls(Oe);let _i={};return is(Ct)?_i=Ct:null!==Ct&&(_i.validators=Ct.validator,_i.asyncValidators=Ct.asyncValidator),new Ls(On,_i)}record(Oe,Ct=null){const On=this._reduceControls(Oe);return new za(On,Ct)}control(Oe,Ct,On){let _i={};return this.useNonNullable?(is(Ct)?_i=Ct:(_i.validators=Ct,_i.asyncValidators=On),new vr(Oe,{..._i,nonNullable:!0})):new vr(Oe,Ct,On)}array(Oe,Ct,On){const _i=Oe.map(Qn=>this._createControl(Qn));return new zr(_i,Ct,On)}_reduceControls(Oe){const Ct={};return Object.keys(Oe).forEach(On=>{Ct[On]=this._createControl(Oe[On])}),Ct}_createControl(Oe){return Oe instanceof vr||Oe instanceof Ro?Oe:Array.isArray(Oe)?this.control(Oe[0],Oe.length>1?Oe[1]:null,Oe.length>2?Oe[2]:null):this.control(Oe)}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Je,factory:Je.\u0275fac,providedIn:"root"})}return Je})(),Ds=(()=>{class Je{static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Je,factory:()=>(0,i.inject)(Ms).nonNullable,providedIn:"root"})}return Je})(),Xo=(()=>{class Je extends Ms{group(Oe,Ct=null){return super.group(Oe,Ct)}control(Oe,Ct,On){return super.control(Oe,Ct,On)}array(Oe,Ct,On){return super.array(Oe,Ct,On)}static#e=this.\u0275fac=(()=>{let Oe;return function(On){return(Oe||(Oe=i.\u0275\u0275getInheritedFactory(Je)))(On||Je)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Je,factory:Je.\u0275fac,providedIn:"root"})}return Je})();const na=new i.Version("18.2.8");let zs=(()=>{class Je{static withConfig(Oe){return{ngModule:Je,providers:[{provide:Na,useValue:Oe.callSetDisabledState??_l}]}}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:Je});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({imports:[Fr]})}return Je})(),ya=(()=>{class Je{static withConfig(Oe){return{ngModule:Je,providers:[{provide:la,useValue:Oe.warnOnNgModelWithFormControl??"always"},{provide:Na,useValue:Oe.callSetDisabledState??_l}]}}static#e=this.\u0275fac=function(Ct){return new(Ct||Je)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:Je});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({imports:[Fr]})}return Je})()},345:(Ot,Me,S)=>{S.d(Me,{hE:()=>as,up:()=>Ti});var i=S(2168),e=S(1270);S(1975);let as=(()=>{class He{constructor(bt){this._doc=bt}getTitle(){return this._doc.title}setTitle(bt){this._doc.title=bt||""}static#e=this.\u0275fac=function(nn){return new(nn||He)(e.\u0275\u0275inject(i.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:He,factory:He.\u0275fac,providedIn:"root"})}return He})(),Ti=(()=>{class He{static#e=this.\u0275fac=function(nn){return new(nn||He)};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:He,factory:function(nn){let Jn=null;return Jn=nn?new(nn||He):e.\u0275\u0275inject(Bi),Jn},providedIn:"root"})}return He})(),Bi=(()=>{class He extends Ti{constructor(bt){super(),this._doc=bt}sanitize(bt,nn){if(null==nn)return null;switch(bt){case e.SecurityContext.NONE:return nn;case e.SecurityContext.HTML:return(0,e.\u0275allowSanitizationBypassAndThrow)(nn,"HTML")?(0,e.\u0275unwrapSafeValue)(nn):(0,e.\u0275_sanitizeHtml)(this._doc,String(nn)).toString();case e.SecurityContext.STYLE:return(0,e.\u0275allowSanitizationBypassAndThrow)(nn,"Style")?(0,e.\u0275unwrapSafeValue)(nn):nn;case e.SecurityContext.SCRIPT:if((0,e.\u0275allowSanitizationBypassAndThrow)(nn,"Script"))return(0,e.\u0275unwrapSafeValue)(nn);throw new e.\u0275RuntimeError(5200,!1);case e.SecurityContext.URL:return(0,e.\u0275allowSanitizationBypassAndThrow)(nn,"URL")?(0,e.\u0275unwrapSafeValue)(nn):(0,e.\u0275_sanitizeUrl)(String(nn));case e.SecurityContext.RESOURCE_URL:if((0,e.\u0275allowSanitizationBypassAndThrow)(nn,"ResourceURL"))return(0,e.\u0275unwrapSafeValue)(nn);throw new e.\u0275RuntimeError(5201,!1);default:throw new e.\u0275RuntimeError(5202,!1)}}bypassSecurityTrustHtml(bt){return(0,e.\u0275bypassSanitizationTrustHtml)(bt)}bypassSecurityTrustStyle(bt){return(0,e.\u0275bypassSanitizationTrustStyle)(bt)}bypassSecurityTrustScript(bt){return(0,e.\u0275bypassSanitizationTrustScript)(bt)}bypassSecurityTrustUrl(bt){return(0,e.\u0275bypassSanitizationTrustUrl)(bt)}bypassSecurityTrustResourceUrl(bt){return(0,e.\u0275bypassSanitizationTrustResourceUrl)(bt)}static#e=this.\u0275fac=function(nn){return new(nn||He)(e.\u0275\u0275inject(i.DOCUMENT))};static#t=this.\u0275prov=e.\u0275\u0275defineInjectable({token:He,factory:He.\u0275fac,providedIn:"root"})}return He})()},7901:(Ot,Me,S)=>{S.r(Me),S.d(Me,{ActivatedRoute:()=>Li,ActivatedRouteSnapshot:()=>vr,ActivationEnd:()=>gs,ActivationStart:()=>_l,BaseRouteReuseStrategy:()=>tc,ChildActivationEnd:()=>Na,ChildActivationStart:()=>vl,ChildrenOutletContexts:()=>Or,DefaultTitleStrategy:()=>Za,DefaultUrlSerializer:()=>Wn,EventType:()=>He,GuardsCheckEnd:()=>Ls,GuardsCheckStart:()=>Ro,NavigationCancel:()=>_r,NavigationCancellationCode:()=>Jn,NavigationEnd:()=>nn,NavigationError:()=>Bo,NavigationSkipped:()=>qr,NavigationSkippedCode:()=>Sn,NavigationStart:()=>bt,NoPreloading:()=>id,OutletContext:()=>er,PRIMARY_OUTLET:()=>Q,PreloadAllModules:()=>Vu,PreloadingStrategy:()=>vd,ROUTER_CONFIGURATION:()=>Ks,ROUTER_INITIALIZER:()=>yc,ROUTES:()=>ou,RedirectCommand:()=>fl,ResolveEnd:()=>Va,ResolveStart:()=>ol,RouteConfigLoadEnd:()=>za,RouteConfigLoadStart:()=>Ao,RouteReuseStrategy:()=>Yt,Router:()=>qs,RouterEvent:()=>mt,RouterLink:()=>su,RouterLinkActive:()=>Is,RouterLinkWithHref:()=>su,RouterModule:()=>vs,RouterOutlet:()=>Ws,RouterPreloader:()=>Sd,RouterState:()=>Yi,RouterStateSnapshot:()=>Mo,RoutesRecognized:()=>Eo,Scroll:()=>Zs,TitleStrategy:()=>ba,UrlHandlingStrategy:()=>bl,UrlSegment:()=>Mt,UrlSegmentGroup:()=>ut,UrlSerializer:()=>pn,UrlTree:()=>dt,VERSION:()=>Kn,convertToParamMap:()=>q,createUrlTreeFromSnapshot:()=>hn,defaultUrlMatcher:()=>oe,mapToCanActivate:()=>Pe,mapToCanActivateChild:()=>rt,mapToCanDeactivate:()=>Ut,mapToCanMatch:()=>ne,mapToResolve:()=>Rn,provideRouter:()=>As,provideRoutes:()=>kd,withComponentInputBinding:()=>gi,withDebugTracing:()=>hf,withDisabledInitialNavigation:()=>pf,withEnabledBlockingInitialNavigation:()=>Bc,withHashLocation:()=>tt,withInMemoryScrolling:()=>Td,withNavigationErrorHandler:()=>mn,withPreloading:()=>Dt,withRouterConfig:()=>Re,withViewTransitions:()=>rr,\u0275EmptyOutletComponent:()=>ac,\u0275ROUTER_PROVIDERS:()=>La,\u0275afterNextNavigation:()=>gd,\u0275loadChildren:()=>da});var i=S(1270),e=S(1647),M=S(2168),X=S(9335),ie=S(345);const Q="primary",Ee=Symbol("RouteTitle");class he{constructor(Ce){this.params=Ce||{}}has(Ce){return Object.prototype.hasOwnProperty.call(this.params,Ce)}get(Ce){if(this.has(Ce)){const ue=this.params[Ce];return Array.isArray(ue)?ue[0]:ue}return null}getAll(Ce){if(this.has(Ce)){const ue=this.params[Ce];return Array.isArray(ue)?ue:[ue]}return[]}get keys(){return Object.keys(this.params)}}function q(Y){return new he(Y)}function oe(Y,Ce,ue){const Ie=ue.path.split("/");if(Ie.length>Y.length||"full"===ue.pathMatch&&(Ce.hasChildren()||Ie.length<Y.length))return null;const Ze={};for(let kt=0;kt<Ie.length;kt++){const rn=Ie[kt],Si=Y[kt];if(":"===rn[0])Ze[rn.substring(1)]=Si;else if(rn!==Si.path)return null}return{consumed:Y.slice(0,Ie.length),posParams:Ze}}function ce(Y,Ce){const ue=Y?le(Y):void 0,Ie=Ce?le(Ce):void 0;if(!ue||!Ie||ue.length!=Ie.length)return!1;let Ze;for(let kt=0;kt<ue.length;kt++)if(Ze=ue[kt],!je(Y[Ze],Ce[Ze]))return!1;return!0}function le(Y){return[...Object.keys(Y),...Object.getOwnPropertySymbols(Y)]}function je(Y,Ce){if(Array.isArray(Y)&&Array.isArray(Ce)){if(Y.length!==Ce.length)return!1;const ue=[...Y].sort(),Ie=[...Ce].sort();return ue.every((Ze,kt)=>Ie[kt]===Ze)}return Y===Ce}function Et(Y){return Y.length>0?Y[Y.length-1]:null}function wt(Y){return(0,e.isObservable)(Y)?Y:(0,i.\u0275isPromise)(Y)?(0,e.from)(Promise.resolve(Y)):(0,e.of)(Y)}const ve={exact:function an(Y,Ce,ue){if(!It(Y.segments,Ce.segments)||!Ae(Y.segments,Ce.segments,ue)||Y.numberOfChildren!==Ce.numberOfChildren)return!1;for(const Ie in Ce.children)if(!Y.children[Ie]||!an(Y.children[Ie],Ce.children[Ie],ue))return!1;return!0},subset:vn},fn={exact:function en(Y,Ce){return ce(Y,Ce)},subset:function un(Y,Ce){return Object.keys(Ce).length<=Object.keys(Y).length&&Object.keys(Ce).every(ue=>je(Y[ue],Ce[ue]))},ignored:()=>!0};function ct(Y,Ce,ue){return ve[ue.paths](Y.root,Ce.root,ue.matrixParams)&&fn[ue.queryParams](Y.queryParams,Ce.queryParams)&&!("exact"===ue.fragment&&Y.fragment!==Ce.fragment)}function vn(Y,Ce,ue){return Pt(Y,Ce,Ce.segments,ue)}function Pt(Y,Ce,ue,Ie){if(Y.segments.length>ue.length){const Ze=Y.segments.slice(0,ue.length);return!(!It(Ze,ue)||Ce.hasChildren()||!Ae(Ze,ue,Ie))}if(Y.segments.length===ue.length){if(!It(Y.segments,ue)||!Ae(Y.segments,ue,Ie))return!1;for(const Ze in Ce.children)if(!Y.children[Ze]||!vn(Y.children[Ze],Ce.children[Ze],Ie))return!1;return!0}{const Ze=ue.slice(0,Y.segments.length),kt=ue.slice(Y.segments.length);return!!(It(Y.segments,Ze)&&Ae(Y.segments,Ze,Ie)&&Y.children[Q])&&Pt(Y.children[Q],Ce,kt,Ie)}}function Ae(Y,Ce,ue){return Ce.every((Ie,Ze)=>fn[ue](Y[Ze].parameters,Ie.parameters))}class dt{constructor(Ce=new ut([],{}),ue={},Ie=null){this.root=Ce,this.queryParams=ue,this.fragment=Ie}get queryParamMap(){return this._queryParamMap??=q(this.queryParams),this._queryParamMap}toString(){return ji.serialize(this)}}class ut{constructor(Ce,ue){this.segments=Ce,this.children=ue,this.parent=null,Object.values(ue).forEach(Ie=>Ie.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return An(this)}}class Mt{constructor(Ce,ue){this.path=Ce,this.parameters=ue}get parameterMap(){return this._parameterMap??=q(this.parameters),this._parameterMap}toString(){return Zn(this)}}function It(Y,Ce){return Y.length===Ce.length&&Y.every((ue,Ie)=>ue.path===Ce[Ie].path)}let pn=(()=>{class Y{static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:()=>new Wn,providedIn:"root"})}return Y})();class Wn{parse(Ce){const ue=new as(Ce);return new dt(ue.parseRootSegment(),ue.parseQueryParams(),ue.parseFragment())}serialize(Ce){const ue=`/${St(Ce.root,!0)}`,Ie=function gn(Y){const Ce=Object.entries(Y).map(([ue,Ie])=>Array.isArray(Ie)?Ie.map(Ze=>`${Ht(ue)}=${Ht(Ze)}`).join("&"):`${Ht(ue)}=${Ht(Ie)}`).filter(ue=>ue);return Ce.length?`?${Ce.join("&")}`:""}(Ce.queryParams);return`${ue}${Ie}${"string"==typeof Ce.fragment?`#${function on(Y){return encodeURI(Y)}(Ce.fragment)}`:""}`}}const ji=new Wn;function An(Y){return Y.segments.map(Ce=>Zn(Ce)).join("/")}function St(Y,Ce){if(!Y.hasChildren())return An(Y);if(Ce){const ue=Y.children[Q]?St(Y.children[Q],!1):"",Ie=[];return Object.entries(Y.children).forEach(([Ze,kt])=>{Ze!==Q&&Ie.push(`${Ze}:${St(kt,!1)}`)}),Ie.length>0?`${ue}(${Ie.join("//")})`:ue}{const ue=function Vn(Y,Ce){let ue=[];return Object.entries(Y.children).forEach(([Ie,Ze])=>{Ie===Q&&(ue=ue.concat(Ce(Ze,Ie)))}),Object.entries(Y.children).forEach(([Ie,Ze])=>{Ie!==Q&&(ue=ue.concat(Ce(Ze,Ie)))}),ue}(Y,(Ie,Ze)=>Ze===Q?[St(Y.children[Q],!1)]:[`${Ze}:${St(Ie,!1)}`]);return 1===Object.keys(Y.children).length&&null!=Y.children[Q]?`${An(Y)}/${ue[0]}`:`${An(Y)}/(${ue.join("//")})`}}function qt(Y){return encodeURIComponent(Y).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function Ht(Y){return qt(Y).replace(/%3B/gi,";")}function Cn(Y){return qt(Y).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function tn(Y){return decodeURIComponent(Y)}function fi(Y){return tn(Y.replace(/\+/g,"%20"))}function Zn(Y){return`${Cn(Y.path)}${function Dn(Y){return Object.entries(Y).map(([Ce,ue])=>`;${Cn(Ce)}=${Cn(ue)}`).join("")}(Y.parameters)}`}const Nn=/^[^\/()?;#]+/;function Yn(Y){const Ce=Y.match(Nn);return Ce?Ce[0]:""}const cr=/^[^\/()?;=#]+/,Qi=/^[^=?&#]+/,Ur=/^[^&#]+/;class as{constructor(Ce){this.url=Ce,this.remaining=Ce}parseRootSegment(){return this.consumeOptional("/"),""===this.remaining||this.peekStartsWith("?")||this.peekStartsWith("#")?new ut([],{}):new ut([],this.parseChildren())}parseQueryParams(){const Ce={};if(this.consumeOptional("?"))do{this.parseQueryParam(Ce)}while(this.consumeOptional("&"));return Ce}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(""===this.remaining)return{};this.consumeOptional("/");const Ce=[];for(this.peekStartsWith("(")||Ce.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),Ce.push(this.parseSegment());let ue={};this.peekStartsWith("/(")&&(this.capture("/"),ue=this.parseParens(!0));let Ie={};return this.peekStartsWith("(")&&(Ie=this.parseParens(!1)),(Ce.length>0||Object.keys(ue).length>0)&&(Ie[Q]=new ut(Ce,ue)),Ie}parseSegment(){const Ce=Yn(this.remaining);if(""===Ce&&this.peekStartsWith(";"))throw new i.\u0275RuntimeError(4009,!1);return this.capture(Ce),new Mt(tn(Ce),this.parseMatrixParams())}parseMatrixParams(){const Ce={};for(;this.consumeOptional(";");)this.parseParam(Ce);return Ce}parseParam(Ce){const ue=function Ai(Y){const Ce=Y.match(cr);return Ce?Ce[0]:""}(this.remaining);if(!ue)return;this.capture(ue);let Ie="";if(this.consumeOptional("=")){const Ze=Yn(this.remaining);Ze&&(Ie=Ze,this.capture(Ie))}Ce[tn(ue)]=tn(Ie)}parseQueryParam(Ce){const ue=function Xr(Y){const Ce=Y.match(Qi);return Ce?Ce[0]:""}(this.remaining);if(!ue)return;this.capture(ue);let Ie="";if(this.consumeOptional("=")){const rn=function eo(Y){const Ce=Y.match(Ur);return Ce?Ce[0]:""}(this.remaining);rn&&(Ie=rn,this.capture(Ie))}const Ze=fi(ue),kt=fi(Ie);if(Ce.hasOwnProperty(Ze)){let rn=Ce[Ze];Array.isArray(rn)||(rn=[rn],Ce[Ze]=rn),rn.push(kt)}else Ce[Ze]=kt}parseParens(Ce){const ue={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){const Ie=Yn(this.remaining),Ze=this.remaining[Ie.length];if("/"!==Ze&&")"!==Ze&&";"!==Ze)throw new i.\u0275RuntimeError(4010,!1);let kt;Ie.indexOf(":")>-1?(kt=Ie.slice(0,Ie.indexOf(":")),this.capture(kt),this.capture(":")):Ce&&(kt=Q);const rn=this.parseChildren();ue[kt]=1===Object.keys(rn).length?rn[Q]:new ut([],rn),this.consumeOptional("//")}return ue}peekStartsWith(Ce){return this.remaining.startsWith(Ce)}consumeOptional(Ce){return!!this.peekStartsWith(Ce)&&(this.remaining=this.remaining.substring(Ce.length),!0)}capture(Ce){if(!this.consumeOptional(Ce))throw new i.\u0275RuntimeError(4011,!1)}}function uo(Y){return Y.segments.length>0?new ut([],{[Q]:Y}):Y}function mi(Y){const Ce={};for(const[Ie,Ze]of Object.entries(Y.children)){const kt=mi(Ze);if(Ie===Q&&0===kt.segments.length&&kt.hasChildren())for(const[rn,Si]of Object.entries(kt.children))Ce[rn]=Si;else(kt.segments.length>0||kt.hasChildren())&&(Ce[Ie]=kt)}return function ci(Y){if(1===Y.numberOfChildren&&Y.children[Q]){const Ce=Y.children[Q];return new ut(Y.segments.concat(Ce.segments),Ce.children)}return Y}(new ut(Y.segments,Ce))}function yt(Y){return Y instanceof dt}function hn(Y,Ce,ue=null,Ie=null){return Gn(Gt(Y),Ce,ue,Ie)}function Gt(Y){let Ce;const Ze=uo(function ue(kt){const rn={};for(const oi of kt.children){const Yr=ue(oi);rn[oi.outlet]=Yr}const Si=new ut(kt.url,rn);return kt===Y&&(Ce=Si),Si}(Y.root));return Ce??Ze}function Gn(Y,Ce,ue,Ie){let Ze=Y;for(;Ze.parent;)Ze=Ze.parent;if(0===Ce.length)return At(Ze,Ze,Ze,ue,Ie);const kt=function ni(Y){if("string"==typeof Y[0]&&1===Y.length&&"/"===Y[0])return new Mn(!0,0,Y);let Ce=0,ue=!1;const Ie=Y.reduce((Ze,kt,rn)=>{if("object"==typeof kt&&null!=kt){if(kt.outlets){const Si={};return Object.entries(kt.outlets).forEach(([oi,Yr])=>{Si[oi]="string"==typeof Yr?Yr.split("/"):Yr}),[...Ze,{outlets:Si}]}if(kt.segmentPath)return[...Ze,kt.segmentPath]}return"string"!=typeof kt?[...Ze,kt]:0===rn?(kt.split("/").forEach((Si,oi)=>{0==oi&&"."===Si||(0==oi&&""===Si?ue=!0:".."===Si?Ce++:""!=Si&&Ze.push(Si))}),Ze):[...Ze,kt]},[]);return new Mn(ue,Ce,Ie)}(Ce);if(kt.toRoot())return At(Ze,Ze,new ut([],{}),ue,Ie);const rn=function Ti(Y,Ce,ue){if(Y.isAbsolute)return new qn(Ce,!0,0);if(!ue)return new qn(Ce,!1,NaN);if(null===ue.parent)return new qn(ue,!0,0);const Ie=ri(Y.commands[0])?0:1;return function Bi(Y,Ce,ue){let Ie=Y,Ze=Ce,kt=ue;for(;kt>Ze;){if(kt-=Ze,Ie=Ie.parent,!Ie)throw new i.\u0275RuntimeError(4005,!1);Ze=Ie.segments.length}return new qn(Ie,!1,Ze-kt)}(ue,ue.segments.length-1+Ie,Y.numberOfDoubleDots)}(kt,Ze,Y),Si=rn.processChildren?Ki(rn.segmentGroup,rn.index,kt.commands):Ii(rn.segmentGroup,rn.index,kt.commands);return At(Ze,rn.segmentGroup,Si,ue,Ie)}function ri(Y){return"object"==typeof Y&&null!=Y&&!Y.outlets&&!Y.segmentPath}function pi(Y){return"object"==typeof Y&&null!=Y&&Y.outlets}function At(Y,Ce,ue,Ie,Ze){let rn,kt={};Ie&&Object.entries(Ie).forEach(([oi,Yr])=>{kt[oi]=Array.isArray(Yr)?Yr.map(rs=>`${rs}`):`${Yr}`}),rn=Y===Ce?ue:Bn(Y,Ce,ue);const Si=uo(mi(rn));return new dt(Si,kt,Ze)}function Bn(Y,Ce,ue){const Ie={};return Object.entries(Y.children).forEach(([Ze,kt])=>{Ie[Ze]=kt===Ce?ue:Bn(kt,Ce,ue)}),new ut(Y.segments,Ie)}class Mn{constructor(Ce,ue,Ie){if(this.isAbsolute=Ce,this.numberOfDoubleDots=ue,this.commands=Ie,Ce&&Ie.length>0&&ri(Ie[0]))throw new i.\u0275RuntimeError(4003,!1);const Ze=Ie.find(pi);if(Ze&&Ze!==Et(Ie))throw new i.\u0275RuntimeError(4004,!1)}toRoot(){return this.isAbsolute&&1===this.commands.length&&"/"==this.commands[0]}}class qn{constructor(Ce,ue,Ie){this.segmentGroup=Ce,this.processChildren=ue,this.index=Ie}}function Ii(Y,Ce,ue){if(Y??=new ut([],{}),0===Y.segments.length&&Y.hasChildren())return Ki(Y,Ce,ue);const Ie=function Jt(Y,Ce,ue){let Ie=0,Ze=Ce;const kt={match:!1,pathIndex:0,commandIndex:0};for(;Ze<Y.segments.length;){if(Ie>=ue.length)return kt;const rn=Y.segments[Ze],Si=ue[Ie];if(pi(Si))break;const oi=`${Si}`,Yr=Ie<ue.length-1?ue[Ie+1]:null;if(Ze>0&&void 0===oi)break;if(oi&&Yr&&"object"==typeof Yr&&void 0===Yr.outlets){if(!sn(oi,Yr,rn))return kt;Ie+=2}else{if(!sn(oi,{},rn))return kt;Ie++}Ze++}return{match:!0,pathIndex:Ze,commandIndex:Ie}}(Y,Ce,ue),Ze=ue.slice(Ie.commandIndex);if(Ie.match&&Ie.pathIndex<Y.segments.length){const kt=new ut(Y.segments.slice(0,Ie.pathIndex),{});return kt.children[Q]=new ut(Y.segments.slice(Ie.pathIndex),Y.children),Ki(kt,0,Ze)}return Ie.match&&0===Ze.length?new ut(Y.segments,{}):Ie.match&&!Y.hasChildren()?hi(Y,Ce,ue):Ie.match?Ki(Y,0,Ze):hi(Y,Ce,ue)}function Ki(Y,Ce,ue){if(0===ue.length)return new ut(Y.segments,{});{const Ie=function Gi(Y){return pi(Y[0])?Y[0].outlets:{[Q]:Y}}(ue),Ze={};if(Object.keys(Ie).some(kt=>kt!==Q)&&Y.children[Q]&&1===Y.numberOfChildren&&0===Y.children[Q].segments.length){const kt=Ki(Y.children[Q],Ce,ue);return new ut(Y.segments,kt.children)}return Object.entries(Ie).forEach(([kt,rn])=>{"string"==typeof rn&&(rn=[rn]),null!==rn&&(Ze[kt]=Ii(Y.children[kt],Ce,rn))}),Object.entries(Y.children).forEach(([kt,rn])=>{void 0===Ie[kt]&&(Ze[kt]=rn)}),new ut(Y.segments,Ze)}}function hi(Y,Ce,ue){const Ie=Y.segments.slice(0,Ce);let Ze=0;for(;Ze<ue.length;){const kt=ue[Ze];if(pi(kt)){const oi=Ft(kt.outlets);return new ut(Ie,oi)}if(0===Ze&&ri(ue[0])){Ie.push(new Mt(Y.segments[Ce].path,it(ue[0]))),Ze++;continue}const rn=pi(kt)?kt.outlets[Q]:`${kt}`,Si=Ze<ue.length-1?ue[Ze+1]:null;rn&&Si&&ri(Si)?(Ie.push(new Mt(rn,it(Si))),Ze+=2):(Ie.push(new Mt(rn,{})),Ze++)}return new ut(Ie,{})}function Ft(Y){const Ce={};return Object.entries(Y).forEach(([ue,Ie])=>{"string"==typeof Ie&&(Ie=[Ie]),null!==Ie&&(Ce[ue]=hi(new ut([],{}),0,Ie))}),Ce}function it(Y){const Ce={};return Object.entries(Y).forEach(([ue,Ie])=>Ce[ue]=`${Ie}`),Ce}function sn(Y,Ce,ue){return Y==ue.path&&ce(Ce,ue.parameters)}const Ve="imperative";var He=function(Y){return Y[Y.NavigationStart=0]="NavigationStart",Y[Y.NavigationEnd=1]="NavigationEnd",Y[Y.NavigationCancel=2]="NavigationCancel",Y[Y.NavigationError=3]="NavigationError",Y[Y.RoutesRecognized=4]="RoutesRecognized",Y[Y.ResolveStart=5]="ResolveStart",Y[Y.ResolveEnd=6]="ResolveEnd",Y[Y.GuardsCheckStart=7]="GuardsCheckStart",Y[Y.GuardsCheckEnd=8]="GuardsCheckEnd",Y[Y.RouteConfigLoadStart=9]="RouteConfigLoadStart",Y[Y.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",Y[Y.ChildActivationStart=11]="ChildActivationStart",Y[Y.ChildActivationEnd=12]="ChildActivationEnd",Y[Y.ActivationStart=13]="ActivationStart",Y[Y.ActivationEnd=14]="ActivationEnd",Y[Y.Scroll=15]="Scroll",Y[Y.NavigationSkipped=16]="NavigationSkipped",Y}(He||{});class mt{constructor(Ce,ue){this.id=Ce,this.url=ue}}class bt extends mt{constructor(Ce,ue,Ie="imperative",Ze=null){super(Ce,ue),this.type=He.NavigationStart,this.navigationTrigger=Ie,this.restoredState=Ze}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}}class nn extends mt{constructor(Ce,ue,Ie){super(Ce,ue),this.urlAfterRedirects=Ie,this.type=He.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}}var Jn=function(Y){return Y[Y.Redirect=0]="Redirect",Y[Y.SupersededByNewNavigation=1]="SupersededByNewNavigation",Y[Y.NoDataFromResolver=2]="NoDataFromResolver",Y[Y.GuardRejected=3]="GuardRejected",Y}(Jn||{}),Sn=function(Y){return Y[Y.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",Y[Y.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",Y}(Sn||{});class _r extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.reason=Ie,this.code=Ze,this.type=He.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}}class qr extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.reason=Ie,this.code=Ze,this.type=He.NavigationSkipped}}class Bo extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.error=Ie,this.target=Ze,this.type=He.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}}class Eo extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.urlAfterRedirects=Ie,this.state=Ze,this.type=He.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Ro extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.urlAfterRedirects=Ie,this.state=Ze,this.type=He.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Ls extends mt{constructor(Ce,ue,Ie,Ze,kt){super(Ce,ue),this.urlAfterRedirects=Ie,this.state=Ze,this.shouldActivate=kt,this.type=He.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}}class ol extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.urlAfterRedirects=Ie,this.state=Ze,this.type=He.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Va extends mt{constructor(Ce,ue,Ie,Ze){super(Ce,ue),this.urlAfterRedirects=Ie,this.state=Ze,this.type=He.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}}class Ao{constructor(Ce){this.route=Ce,this.type=He.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}}class za{constructor(Ce){this.route=Ce,this.type=He.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}}class vl{constructor(Ce){this.snapshot=Ce,this.type=He.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Na{constructor(Ce){this.snapshot=Ce,this.type=He.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class _l{constructor(Ce){this.snapshot=Ce,this.type=He.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class gs{constructor(Ce){this.snapshot=Ce,this.type=He.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}}class Zs{constructor(Ce,ue,Ie){this.routerEvent=Ce,this.position=ue,this.anchor=Ie,this.type=He.Scroll}toString(){return`Scroll(anchor: '${this.anchor}', position: '${this.position?`${this.position[0]}, ${this.position[1]}`:null}')`}}class oa{}class no{constructor(Ce,ue){this.url=Ce,this.navigationBehaviorOptions=ue}}function Fi(Y){return Y.outlet||Q}function ar(Y){if(!Y)return null;if(Y.routeConfig?._injector)return Y.routeConfig._injector;for(let Ce=Y.parent;Ce;Ce=Ce.parent){const ue=Ce.routeConfig;if(ue?._loadedInjector)return ue._loadedInjector;if(ue?._injector)return ue._injector}return null}class er{get injector(){return ar(this.route?.snapshot)??this.rootInjector}set injector(Ce){}constructor(Ce){this.rootInjector=Ce,this.outlet=null,this.route=null,this.children=new Or(this.rootInjector),this.attachRef=null}}let Or=(()=>{class Y{constructor(ue){this.rootInjector=ue,this.contexts=new Map}onChildOutletCreated(ue,Ie){const Ze=this.getOrCreateContext(ue);Ze.outlet=Ie,this.contexts.set(ue,Ze)}onChildOutletDestroyed(ue){const Ie=this.getContext(ue);Ie&&(Ie.outlet=null,Ie.attachRef=null)}onOutletDeactivated(){const ue=this.contexts;return this.contexts=new Map,ue}onOutletReAttached(ue){this.contexts=ue}getOrCreateContext(ue){let Ie=this.getContext(ue);return Ie||(Ie=new er(this.rootInjector),this.contexts.set(ue,Ie)),Ie}getContext(ue){return this.contexts.get(ue)||null}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275inject(i.EnvironmentInjector))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();class Tt{constructor(Ce){this._root=Ce}get root(){return this._root.value}parent(Ce){const ue=this.pathFromRoot(Ce);return ue.length>1?ue[ue.length-2]:null}children(Ce){const ue=cn(Ce,this._root);return ue?ue.children.map(Ie=>Ie.value):[]}firstChild(Ce){const ue=cn(Ce,this._root);return ue&&ue.children.length>0?ue.children[0].value:null}siblings(Ce){const ue=Tn(Ce,this._root);return ue.length<2?[]:ue[ue.length-2].children.map(Ze=>Ze.value).filter(Ze=>Ze!==Ce)}pathFromRoot(Ce){return Tn(Ce,this._root).map(ue=>ue.value)}}function cn(Y,Ce){if(Y===Ce.value)return Ce;for(const ue of Ce.children){const Ie=cn(Y,ue);if(Ie)return Ie}return null}function Tn(Y,Ce){if(Y===Ce.value)return[Ce];for(const ue of Ce.children){const Ie=Tn(Y,ue);if(Ie.length)return Ie.unshift(Ce),Ie}return[]}class Ri{constructor(Ce,ue){this.value=Ce,this.children=ue}toString(){return`TreeNode(${this.value})`}}function Un(Y){const Ce={};return Y&&Y.children.forEach(ue=>Ce[ue.value.outlet]=ue),Ce}class Yi extends Tt{constructor(Ce,ue){super(Ce),this.snapshot=ue,ks(this,Ce)}toString(){return this.snapshot.toString()}}function Wi(Y){const Ce=function fr(Y){const kt=new vr([],{},{},"",{},Q,Y,null,{});return new Mo("",new Ri(kt,[]))}(Y),ue=new e.BehaviorSubject([new Mt("",{})]),Ie=new e.BehaviorSubject({}),Ze=new e.BehaviorSubject({}),kt=new e.BehaviorSubject({}),rn=new e.BehaviorSubject(""),Si=new Li(ue,Ie,kt,rn,Ze,Q,Y,Ce.root);return Si.snapshot=Ce.root,new Yi(new Ri(Si,[]),Ce)}class Li{constructor(Ce,ue,Ie,Ze,kt,rn,Si,oi){this.urlSubject=Ce,this.paramsSubject=ue,this.queryParamsSubject=Ie,this.fragmentSubject=Ze,this.dataSubject=kt,this.outlet=rn,this.component=Si,this._futureSnapshot=oi,this.title=this.dataSubject?.pipe((0,X.map)(Yr=>Yr[Ee]))??(0,e.of)(void 0),this.url=Ce,this.params=ue,this.queryParams=Ie,this.fragment=Ze,this.data=kt}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe((0,X.map)(Ce=>q(Ce))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe((0,X.map)(Ce=>q(Ce))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}}function Vo(Y,Ce,ue="emptyOnly"){let Ie;const{routeConfig:Ze}=Y;return Ie=null===Ce||"always"!==ue&&""!==Ze?.path&&(Ce.component||Ce.routeConfig?.loadComponent)?{params:{...Y.params},data:{...Y.data},resolve:{...Y.data,...Y._resolvedData??{}}}:{params:{...Ce.params,...Y.params},data:{...Ce.data,...Y.data},resolve:{...Y.data,...Ce.data,...Ze?.data,...Y._resolvedData}},Ze&&ds(Ze)&&(Ie.resolve[Ee]=Ze.title),Ie}class vr{get title(){return this.data?.[Ee]}constructor(Ce,ue,Ie,Ze,kt,rn,Si,oi,Yr){this.url=Ce,this.params=ue,this.queryParams=Ie,this.fragment=Ze,this.data=kt,this.outlet=rn,this.component=Si,this.routeConfig=oi,this._resolve=Yr}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=q(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=q(this.queryParams),this._queryParamMap}toString(){return`Route(url:'${this.url.map(Ie=>Ie.toString()).join("/")}', path:'${this.routeConfig?this.routeConfig.path:""}')`}}class Mo extends Tt{constructor(Ce,ue){super(ue),this.url=Ce,ks(this,ue)}toString(){return Jo(this._root)}}function ks(Y,Ce){Ce.value._routerState=Y,Ce.children.forEach(ue=>ks(Y,ue))}function Jo(Y){const Ce=Y.children.length>0?` { ${Y.children.map(Jo).join(", ")} } `:"";return`${Y.value}${Ce}`}function $s(Y){if(Y.snapshot){const Ce=Y.snapshot,ue=Y._futureSnapshot;Y.snapshot=ue,ce(Ce.queryParams,ue.queryParams)||Y.queryParamsSubject.next(ue.queryParams),Ce.fragment!==ue.fragment&&Y.fragmentSubject.next(ue.fragment),ce(Ce.params,ue.params)||Y.paramsSubject.next(ue.params),function Z(Y,Ce){if(Y.length!==Ce.length)return!1;for(let ue=0;ue<Y.length;++ue)if(!ce(Y[ue],Ce[ue]))return!1;return!0}(Ce.url,ue.url)||Y.urlSubject.next(ue.url),ce(Ce.data,ue.data)||Y.dataSubject.next(ue.data)}else Y.snapshot=Y._futureSnapshot,Y.dataSubject.next(Y._futureSnapshot.data)}function Js(Y,Ce){const ue=ce(Y.params,Ce.params)&&function Wt(Y,Ce){return It(Y,Ce)&&Y.every((ue,Ie)=>ce(ue.parameters,Ce[Ie].parameters))}(Y.url,Ce.url);return ue&&!(!Y.parent!=!Ce.parent)&&(!Y.parent||Js(Y.parent,Ce.parent))}function ds(Y){return"string"==typeof Y.title||null===Y.title}let Ws=(()=>{class Y{constructor(){this.activated=null,this._activatedRoute=null,this.name=Q,this.activateEvents=new i.EventEmitter,this.deactivateEvents=new i.EventEmitter,this.attachEvents=new i.EventEmitter,this.detachEvents=new i.EventEmitter,this.parentContexts=(0,i.inject)(Or),this.location=(0,i.inject)(i.ViewContainerRef),this.changeDetector=(0,i.inject)(i.ChangeDetectorRef),this.inputBinder=(0,i.inject)(Ma,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(ue){if(ue.name){const{firstChange:Ie,previousValue:Ze}=ue.name;if(Ie)return;this.isTrackedInParentContexts(Ze)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(Ze)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(ue){return this.parentContexts.getContext(ue)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;const ue=this.parentContexts.getContext(this.name);ue?.route&&(ue.attachRef?this.attach(ue.attachRef,ue.route):this.activateWith(ue.route,ue.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new i.\u0275RuntimeError(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new i.\u0275RuntimeError(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new i.\u0275RuntimeError(4012,!1);this.location.detach();const ue=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(ue.instance),ue}attach(ue,Ie){this.activated=ue,this._activatedRoute=Ie,this.location.insert(ue.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(ue.instance)}deactivate(){if(this.activated){const ue=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(ue)}}activateWith(ue,Ie){if(this.isActivated)throw new i.\u0275RuntimeError(4013,!1);this._activatedRoute=ue;const Ze=this.location,rn=ue.snapshot.component,Si=this.parentContexts.getOrCreateContext(this.name).children,oi=new es(ue,Si,Ze.injector);this.activated=Ze.createComponent(rn,{index:Ze.length,injector:oi,environmentInjector:Ie}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Y,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return Y})();class es{__ngOutletInjector(Ce){return new es(this.route,this.childContexts,Ce)}constructor(Ce,ue,Ie){this.route=Ce,this.childContexts=ue,this.parent=Ie}get(Ce,ue){return Ce===Li?this.route:Ce===Or?this.childContexts:this.parent.get(Ce,ue)}}const Ma=new i.InjectionToken("");let ts=(()=>{class Y{constructor(){this.outletDataSubscriptions=new Map}bindActivatedRouteToOutletComponent(ue){this.unsubscribeFromRouteData(ue),this.subscribeToRouteData(ue)}unsubscribeFromRouteData(ue){this.outletDataSubscriptions.get(ue)?.unsubscribe(),this.outletDataSubscriptions.delete(ue)}subscribeToRouteData(ue){const{activatedRoute:Ie}=ue,Ze=(0,e.combineLatest)([Ie.queryParams,Ie.params,Ie.data]).pipe((0,X.switchMap)(([kt,rn,Si],oi)=>(Si={...kt,...rn,...Si},0===oi?(0,e.of)(Si):Promise.resolve(Si)))).subscribe(kt=>{if(!ue.isActivated||!ue.activatedComponentRef||ue.activatedRoute!==Ie||null===Ie.component)return void this.unsubscribeFromRouteData(ue);const rn=(0,i.reflectComponentType)(Ie.component);if(rn)for(const{templateName:Si}of rn.inputs)ue.activatedComponentRef.setInput(Si,kt[Si]);else this.unsubscribeFromRouteData(ue)});this.outletDataSubscriptions.set(ue,Ze)}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac})}return Y})();function ea(Y,Ce,ue){if(ue&&Y.shouldReuseRoute(Ce.value,ue.value.snapshot)){const Ie=ue.value;Ie._futureSnapshot=Ce.value;const Ze=function ga(Y,Ce,ue){return Ce.children.map(Ie=>{for(const Ze of ue.children)if(Y.shouldReuseRoute(Ie.value,Ze.value.snapshot))return ea(Y,Ie,Ze);return ea(Y,Ie)})}(Y,Ce,ue);return new Ri(Ie,Ze)}{if(Y.shouldAttach(Ce.value)){const kt=Y.retrieve(Ce.value);if(null!==kt){const rn=kt.route;return rn.value._futureSnapshot=Ce.value,rn.children=Ce.children.map(Si=>ea(Y,Si)),rn}}const Ie=function sl(Y){return new Li(new e.BehaviorSubject(Y.url),new e.BehaviorSubject(Y.params),new e.BehaviorSubject(Y.queryParams),new e.BehaviorSubject(Y.fragment),new e.BehaviorSubject(Y.data),Y.outlet,Y.component,Y)}(Ce.value),Ze=Ce.children.map(kt=>ea(Y,kt));return new Ri(Ie,Ze)}}class fl{constructor(Ce,ue){this.redirectTo=Ce,this.navigationBehaviorOptions=ue}}const Ia="ngNavigationCancelingError";function al(Y,Ce){const{redirectTo:ue,navigationBehaviorOptions:Ie}=yt(Ce)?{redirectTo:Ce,navigationBehaviorOptions:void 0}:Ce,Ze=Kc(!1,Jn.Redirect);return Ze.url=ue,Ze.navigationBehaviorOptions=Ie,Ze}function Kc(Y,Ce){const ue=new Error(`NavigationCancelingError: ${Y||""}`);return ue[Ia]=!0,ue.cancellationCode=Ce,ue}function Sl(Y){return!!Y&&Y[Ia]}class pl{constructor(Ce,ue,Ie,Ze,kt){this.routeReuseStrategy=Ce,this.futureState=ue,this.currState=Ie,this.forwardEvent=Ze,this.inputBindingEnabled=kt}activate(Ce){const ue=this.futureState._root,Ie=this.currState?this.currState._root:null;this.deactivateChildRoutes(ue,Ie,Ce),$s(this.futureState.root),this.activateChildRoutes(ue,Ie,Ce)}deactivateChildRoutes(Ce,ue,Ie){const Ze=Un(ue);Ce.children.forEach(kt=>{const rn=kt.value.outlet;this.deactivateRoutes(kt,Ze[rn],Ie),delete Ze[rn]}),Object.values(Ze).forEach(kt=>{this.deactivateRouteAndItsChildren(kt,Ie)})}deactivateRoutes(Ce,ue,Ie){const Ze=Ce.value,kt=ue?ue.value:null;if(Ze===kt)if(Ze.component){const rn=Ie.getContext(Ze.outlet);rn&&this.deactivateChildRoutes(Ce,ue,rn.children)}else this.deactivateChildRoutes(Ce,ue,Ie);else kt&&this.deactivateRouteAndItsChildren(ue,Ie)}deactivateRouteAndItsChildren(Ce,ue){Ce.value.component&&this.routeReuseStrategy.shouldDetach(Ce.value.snapshot)?this.detachAndStoreRouteSubtree(Ce,ue):this.deactivateRouteAndOutlet(Ce,ue)}detachAndStoreRouteSubtree(Ce,ue){const Ie=ue.getContext(Ce.value.outlet),Ze=Ie&&Ce.value.component?Ie.children:ue,kt=Un(Ce);for(const rn of Object.values(kt))this.deactivateRouteAndItsChildren(rn,Ze);if(Ie&&Ie.outlet){const rn=Ie.outlet.detach(),Si=Ie.children.onOutletDeactivated();this.routeReuseStrategy.store(Ce.value.snapshot,{componentRef:rn,route:Ce,contexts:Si})}}deactivateRouteAndOutlet(Ce,ue){const Ie=ue.getContext(Ce.value.outlet),Ze=Ie&&Ce.value.component?Ie.children:ue,kt=Un(Ce);for(const rn of Object.values(kt))this.deactivateRouteAndItsChildren(rn,Ze);Ie&&(Ie.outlet&&(Ie.outlet.deactivate(),Ie.children.onOutletDeactivated()),Ie.attachRef=null,Ie.route=null)}activateChildRoutes(Ce,ue,Ie){const Ze=Un(ue);Ce.children.forEach(kt=>{this.activateRoutes(kt,Ze[kt.value.outlet],Ie),this.forwardEvent(new gs(kt.value.snapshot))}),Ce.children.length&&this.forwardEvent(new Na(Ce.value.snapshot))}activateRoutes(Ce,ue,Ie){const Ze=Ce.value,kt=ue?ue.value:null;if($s(Ze),Ze===kt)if(Ze.component){const rn=Ie.getOrCreateContext(Ze.outlet);this.activateChildRoutes(Ce,ue,rn.children)}else this.activateChildRoutes(Ce,ue,Ie);else if(Ze.component){const rn=Ie.getOrCreateContext(Ze.outlet);if(this.routeReuseStrategy.shouldAttach(Ze.snapshot)){const Si=this.routeReuseStrategy.retrieve(Ze.snapshot);this.routeReuseStrategy.store(Ze.snapshot,null),rn.children.onOutletReAttached(Si.contexts),rn.attachRef=Si.componentRef,rn.route=Si.route.value,rn.outlet&&rn.outlet.attach(Si.componentRef,Si.route.value),$s(Si.route.value),this.activateChildRoutes(Ce,null,rn.children)}else rn.attachRef=null,rn.route=Ze,rn.outlet&&rn.outlet.activateWith(Ze,rn.injector),this.activateChildRoutes(Ce,null,rn.children)}else this.activateChildRoutes(Ce,null,Ie)}}class Sc{constructor(Ce){this.path=Ce,this.route=this.path[this.path.length-1]}}class Ec{constructor(Ce,ue){this.component=Ce,this.route=ue}}function Qc(Y,Ce,ue){const Ie=Y._root;return Yc(Ie,Ce?Ce._root:null,ue,[Ie.value])}function ec(Y,Ce){const ue=Symbol(),Ie=Ce.get(Y,ue);return Ie===ue?"function"!=typeof Y||(0,i.\u0275isInjectable)(Y)?Ce.get(Y):Y:Ie}function Yc(Y,Ce,ue,Ie,Ze={canDeactivateChecks:[],canActivateChecks:[]}){const kt=Un(Ce);return Y.children.forEach(rn=>{(function ca(Y,Ce,ue,Ie,Ze={canDeactivateChecks:[],canActivateChecks:[]}){const kt=Y.value,rn=Ce?Ce.value:null,Si=ue?ue.getContext(Y.value.outlet):null;if(rn&&kt.routeConfig===rn.routeConfig){const oi=function Il(Y,Ce,ue){if("function"==typeof ue)return ue(Y,Ce);switch(ue){case"pathParamsChange":return!It(Y.url,Ce.url);case"pathParamsOrQueryParamsChange":return!It(Y.url,Ce.url)||!ce(Y.queryParams,Ce.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Js(Y,Ce)||!ce(Y.queryParams,Ce.queryParams);default:return!Js(Y,Ce)}}(rn,kt,kt.routeConfig.runGuardsAndResolvers);oi?Ze.canActivateChecks.push(new Sc(Ie)):(kt.data=rn.data,kt._resolvedData=rn._resolvedData),Yc(Y,Ce,kt.component?Si?Si.children:null:ue,Ie,Ze),oi&&Si&&Si.outlet&&Si.outlet.isActivated&&Ze.canDeactivateChecks.push(new Ec(Si.outlet.component,rn))}else rn&&Xa(Ce,Si,Ze),Ze.canActivateChecks.push(new Sc(Ie)),Yc(Y,null,kt.component?Si?Si.children:null:ue,Ie,Ze)})(rn,kt[rn.value.outlet],ue,Ie.concat([rn.value]),Ze),delete kt[rn.value.outlet]}),Object.entries(kt).forEach(([rn,Si])=>Xa(Si,ue.getContext(rn),Ze)),Ze}function Xa(Y,Ce,ue){const Ie=Un(Y),Ze=Y.value;Object.entries(Ie).forEach(([kt,rn])=>{Xa(rn,Ze.component?Ce?Ce.children.getContext(kt):null:Ce,ue)}),ue.canDeactivateChecks.push(new Ec(Ze.component&&Ce&&Ce.outlet&&Ce.outlet.isActivated?Ce.outlet.component:null,Ze))}function Rl(Y){return"function"==typeof Y}function sc(Y){return Y instanceof e.EmptyError||"EmptyError"===Y?.name}const ta=Symbol("INITIAL_VALUE");function vc(){return(0,X.switchMap)(Y=>(0,e.combineLatest)(Y.map(Ce=>Ce.pipe((0,X.take)(1),(0,X.startWith)(ta)))).pipe((0,X.map)(Ce=>{for(const ue of Ce)if(!0!==ue){if(ue===ta)return ta;if(!1===ue||xu(ue))return ue}return!0}),(0,X.filter)(Ce=>Ce!==ta),(0,X.take)(1)))}function xu(Y){return yt(Y)||Y instanceof fl}function Se(Y){return(0,e.pipe)((0,X.tap)(Ce=>{if("boolean"!=typeof Ce)throw al(0,Ce)}),(0,X.map)(Ce=>!0===Ce))}class Ge{constructor(Ce){this.segmentGroup=Ce||null}}class xt extends Error{constructor(Ce){super(),this.urlTree=Ce}}function Qt(Y){return(0,e.throwError)(new Ge(Y))}class Ci{constructor(Ce,ue){this.urlSerializer=Ce,this.urlTree=ue}lineralizeSegments(Ce,ue){let Ie=[],Ze=ue.root;for(;;){if(Ie=Ie.concat(Ze.segments),0===Ze.numberOfChildren)return(0,e.of)(Ie);if(Ze.numberOfChildren>1||!Ze.children[Q])return(0,e.throwError)(new i.\u0275RuntimeError(4e3,!1));Ze=Ze.children[Q]}}applyRedirectCommands(Ce,ue,Ie,Ze,kt){if("string"!=typeof ue){const Si=ue,{queryParams:oi,fragment:Yr,routeConfig:rs,url:ls,outlet:Zo,params:Hl,data:dc,title:ws}=Ze,Vc=(0,i.runInInjectionContext)(kt,()=>Si({params:Hl,data:dc,queryParams:oi,fragment:Yr,routeConfig:rs,url:ls,outlet:Zo,title:ws}));if(Vc instanceof dt)throw new xt(Vc);ue=Vc}const rn=this.applyRedirectCreateUrlTree(ue,this.urlSerializer.parse(ue),Ce,Ie);if("/"===ue[0])throw new xt(rn);return rn}applyRedirectCreateUrlTree(Ce,ue,Ie,Ze){const kt=this.createSegmentGroup(Ce,ue.root,Ie,Ze);return new dt(kt,this.createQueryParams(ue.queryParams,this.urlTree.queryParams),ue.fragment)}createQueryParams(Ce,ue){const Ie={};return Object.entries(Ce).forEach(([Ze,kt])=>{if("string"==typeof kt&&":"===kt[0]){const Si=kt.substring(1);Ie[Ze]=ue[Si]}else Ie[Ze]=kt}),Ie}createSegmentGroup(Ce,ue,Ie,Ze){const kt=this.createSegments(Ce,ue.segments,Ie,Ze);let rn={};return Object.entries(ue.children).forEach(([Si,oi])=>{rn[Si]=this.createSegmentGroup(Ce,oi,Ie,Ze)}),new ut(kt,rn)}createSegments(Ce,ue,Ie,Ze){return ue.map(kt=>":"===kt.path[0]?this.findPosParam(Ce,kt,Ze):this.findOrReturn(kt,Ie))}findPosParam(Ce,ue,Ie){const Ze=Ie[ue.path.substring(1)];if(!Ze)throw new i.\u0275RuntimeError(4001,!1);return Ze}findOrReturn(Ce,ue){let Ie=0;for(const Ze of ue){if(Ze.path===Ce.path)return ue.splice(Ie),Ze;Ie++}return Ce}}const Xi={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function $i(Y,Ce,ue,Ie,Ze){const kt=Er(Y,Ce,ue);return kt.matched?(Ie=function Qr(Y,Ce){return Y.providers&&!Y._injector&&(Y._injector=(0,i.createEnvironmentInjector)(Y.providers,Ce,`Route: ${Y.path}`)),Y._injector??Ce}(Ce,Ie),function re(Y,Ce,ue,Ie){const Ze=Ce.canMatch;if(!Ze||0===Ze.length)return(0,e.of)(!0);const kt=Ze.map(rn=>{const Si=ec(rn,Y);return wt(function Ql(Y){return Y&&Rl(Y.canMatch)}(Si)?Si.canMatch(Ce,ue):(0,i.runInInjectionContext)(Y,()=>Si(Ce,ue)))});return(0,e.of)(kt).pipe(vc(),Se())}(Ie,Ce,ue).pipe((0,X.map)(rn=>!0===rn?kt:{...Xi}))):(0,e.of)(kt)}function Er(Y,Ce,ue){if("**"===Ce.path)return function ai(Y){return{matched:!0,parameters:Y.length>0?Et(Y).parameters:{},consumedSegments:Y,remainingSegments:[],positionalParamSegments:{}}}(ue);if(""===Ce.path)return"full"===Ce.pathMatch&&(Y.hasChildren()||ue.length>0)?{...Xi}:{matched:!0,consumedSegments:[],remainingSegments:ue,parameters:{},positionalParamSegments:{}};const Ze=(Ce.matcher||oe)(ue,Y,Ce);if(!Ze)return{...Xi};const kt={};Object.entries(Ze.posParams??{}).forEach(([Si,oi])=>{kt[Si]=oi.path});const rn=Ze.consumed.length>0?{...kt,...Ze.consumed[Ze.consumed.length-1].parameters}:kt;return{matched:!0,consumedSegments:Ze.consumed,remainingSegments:ue.slice(Ze.consumed.length),parameters:rn,positionalParamSegments:Ze.posParams??{}}}function so(Y,Ce,ue,Ie){return ue.length>0&&function ho(Y,Ce,ue){return ue.some(Ie=>is(Y,Ce,Ie)&&Fi(Ie)!==Q)}(Y,ue,Ie)?{segmentGroup:new ut(Ce,zr(Ie,new ut(ue,Y.children))),slicedSegments:[]}:0===ue.length&&function Vr(Y,Ce,ue){return ue.some(Ie=>is(Y,Ce,Ie))}(Y,ue,Ie)?{segmentGroup:new ut(Y.segments,Fr(Y,ue,Ie,Y.children)),slicedSegments:ue}:{segmentGroup:new ut(Y.segments,Y.children),slicedSegments:ue}}function Fr(Y,Ce,ue,Ie){const Ze={};for(const kt of ue)if(is(Y,Ce,kt)&&!Ie[Fi(kt)]){const rn=new ut([],{});Ze[Fi(kt)]=rn}return{...Ie,...Ze}}function zr(Y,Ce){const ue={};ue[Q]=Ce;for(const Ie of Y)if(""===Ie.path&&Fi(Ie)!==Q){const Ze=new ut([],{});ue[Fi(Ie)]=Ze}return ue}function is(Y,Ce,ue){return(!(Y.hasChildren()||Ce.length>0)||"full"!==ue.pathMatch)&&""===ue.path}class Ds{}class zs{constructor(Ce,ue,Ie,Ze,kt,rn,Si){this.injector=Ce,this.configLoader=ue,this.rootComponentType=Ie,this.config=Ze,this.urlTree=kt,this.paramsInheritanceStrategy=rn,this.urlSerializer=Si,this.applyRedirects=new Ci(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(Ce){return new i.\u0275RuntimeError(4002,`'${Ce.segmentGroup}'`)}recognize(){const Ce=so(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(Ce).pipe((0,X.map)(({children:ue,rootSnapshot:Ie})=>{const Ze=new Ri(Ie,ue),kt=new Mo("",Ze),rn=hn(Ie,[],this.urlTree.queryParams,this.urlTree.fragment);return rn.queryParams=this.urlTree.queryParams,kt.url=this.urlSerializer.serialize(rn),{state:kt,tree:rn}}))}match(Ce){const ue=new vr([],Object.freeze({}),Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Object.freeze({}),Q,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,Ce,Q,ue).pipe((0,X.map)(Ie=>({children:Ie,rootSnapshot:ue})),(0,X.catchError)(Ie=>{if(Ie instanceof xt)return this.urlTree=Ie.urlTree,this.match(Ie.urlTree.root);throw Ie instanceof Ge?this.noMatchError(Ie):Ie}))}processSegmentGroup(Ce,ue,Ie,Ze,kt){return 0===Ie.segments.length&&Ie.hasChildren()?this.processChildren(Ce,ue,Ie,kt):this.processSegment(Ce,ue,Ie,Ie.segments,Ze,!0,kt).pipe((0,X.map)(rn=>rn instanceof Ri?[rn]:[]))}processChildren(Ce,ue,Ie,Ze){const kt=[];for(const rn of Object.keys(Ie.children))"primary"===rn?kt.unshift(rn):kt.push(rn);return(0,e.from)(kt).pipe((0,X.concatMap)(rn=>{const Si=Ie.children[rn],oi=function Ui(Y,Ce){const ue=Y.filter(Ie=>Fi(Ie)===Ce);return ue.push(...Y.filter(Ie=>Fi(Ie)!==Ce)),ue}(ue,rn);return this.processSegmentGroup(Ce,oi,Si,rn,Ze)}),(0,X.scan)((rn,Si)=>(rn.push(...Si),rn)),(0,X.defaultIfEmpty)(null),(0,X.last)(),(0,X.mergeMap)(rn=>{if(null===rn)return Qt(Ie);const Si=at(rn);return function ya(Y){Y.sort((Ce,ue)=>Ce.value.outlet===Q?-1:ue.value.outlet===Q?1:Ce.value.outlet.localeCompare(ue.value.outlet))}(Si),(0,e.of)(Si)}))}processSegment(Ce,ue,Ie,Ze,kt,rn,Si){return(0,e.from)(ue).pipe((0,X.concatMap)(oi=>this.processSegmentAgainstRoute(oi._injector??Ce,ue,oi,Ie,Ze,kt,rn,Si).pipe((0,X.catchError)(Yr=>{if(Yr instanceof Ge)return(0,e.of)(null);throw Yr}))),(0,X.first)(oi=>!!oi),(0,X.catchError)(oi=>{if(sc(oi))return function Ms(Y,Ce,ue){return 0===Ce.length&&!Y.children[ue]}(Ie,Ze,kt)?(0,e.of)(new Ds):Qt(Ie);throw oi}))}processSegmentAgainstRoute(Ce,ue,Ie,Ze,kt,rn,Si,oi){return Fi(Ie)===rn||rn!==Q&&is(Ze,kt,Ie)?void 0===Ie.redirectTo?this.matchSegmentAgainstRoute(Ce,Ze,Ie,kt,rn,oi):this.allowRedirects&&Si?this.expandSegmentAgainstRouteUsingRedirect(Ce,Ze,ue,Ie,kt,rn,oi):Qt(Ze):Qt(Ze)}expandSegmentAgainstRouteUsingRedirect(Ce,ue,Ie,Ze,kt,rn,Si){const{matched:oi,parameters:Yr,consumedSegments:rs,positionalParamSegments:ls,remainingSegments:Zo}=Er(ue,Ze,kt);if(!oi)return Qt(ue);"string"==typeof Ze.redirectTo&&"/"===Ze.redirectTo[0]&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>31&&(this.allowRedirects=!1));const Hl=new vr(kt,Yr,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Ct(Ze),Fi(Ze),Ze.component??Ze._loadedComponent??null,Ze,On(Ze)),dc=Vo(Hl,Si,this.paramsInheritanceStrategy);Hl.params=Object.freeze(dc.params),Hl.data=Object.freeze(dc.data);const ws=this.applyRedirects.applyRedirectCommands(rs,Ze.redirectTo,ls,Hl,Ce);return this.applyRedirects.lineralizeSegments(Ze,ws).pipe((0,X.mergeMap)(Vc=>this.processSegment(Ce,Ie,ue,Vc.concat(Zo),rn,!1,Si)))}matchSegmentAgainstRoute(Ce,ue,Ie,Ze,kt,rn){const Si=$i(ue,Ie,Ze,Ce);return"**"===Ie.path&&(ue.children={}),Si.pipe((0,X.switchMap)(oi=>oi.matched?this.getChildConfig(Ce=Ie._injector??Ce,Ie,Ze).pipe((0,X.switchMap)(({routes:Yr})=>{const rs=Ie._loadedInjector??Ce,{parameters:ls,consumedSegments:Zo,remainingSegments:Hl}=oi,dc=new vr(Zo,ls,Object.freeze({...this.urlTree.queryParams}),this.urlTree.fragment,Ct(Ie),Fi(Ie),Ie.component??Ie._loadedComponent??null,Ie,On(Ie)),ws=Vo(dc,rn,this.paramsInheritanceStrategy);dc.params=Object.freeze(ws.params),dc.data=Object.freeze(ws.data);const{segmentGroup:Vc,slicedSegments:Wo}=so(ue,Zo,Hl,Yr);if(0===Wo.length&&Vc.hasChildren())return this.processChildren(rs,Yr,Vc,dc).pipe((0,X.map)(ro=>new Ri(dc,ro)));if(0===Yr.length&&0===Wo.length)return(0,e.of)(new Ri(dc,[]));const sr=Fi(Ie)===kt;return this.processSegment(rs,Yr,Vc,Wo,sr?Q:kt,!0,dc).pipe((0,X.map)(ro=>new Ri(dc,ro instanceof Ri?[ro]:[])))})):Qt(ue)))}getChildConfig(Ce,ue,Ie){return ue.children?(0,e.of)({routes:ue.children,injector:Ce}):ue.loadChildren?void 0!==ue._loadedRoutes?(0,e.of)({routes:ue._loadedRoutes,injector:ue._loadedInjector}):function Ke(Y,Ce,ue,Ie){const Ze=Ce.canLoad;if(void 0===Ze||0===Ze.length)return(0,e.of)(!0);const kt=Ze.map(rn=>{const Si=ec(rn,Y);return wt(function sa(Y){return Y&&Rl(Y.canLoad)}(Si)?Si.canLoad(Ce,ue):(0,i.runInInjectionContext)(Y,()=>Si(Ce,ue)))});return(0,e.of)(kt).pipe(vc(),Se())}(Ce,ue,Ie).pipe((0,X.mergeMap)(Ze=>Ze?this.configLoader.loadChildren(Ce,ue).pipe((0,X.tap)(kt=>{ue._loadedRoutes=kt.routes,ue._loadedInjector=kt.injector})):function vi(){return(0,e.throwError)(Kc(!1,Jn.GuardRejected))}())):(0,e.of)({routes:[],injector:Ce})}}function Je(Y){const Ce=Y.value.routeConfig;return Ce&&""===Ce.path}function at(Y){const Ce=[],ue=new Set;for(const Ie of Y){if(!Je(Ie)){Ce.push(Ie);continue}const Ze=Ce.find(kt=>Ie.value.routeConfig===kt.value.routeConfig);void 0!==Ze?(Ze.children.push(...Ie.children),ue.add(Ze)):Ce.push(Ie)}for(const Ie of ue){const Ze=at(Ie.children);Ce.push(new Ri(Ie.value,Ze))}return Ce.filter(Ie=>!ue.has(Ie))}function Ct(Y){return Y.data||{}}function On(Y){return Y.resolve||{}}function qi(Y){const Ce=Y.children.map(ue=>qi(ue)).flat();return[Y,...Ce]}function Gs(Y){return(0,X.switchMap)(Ce=>{const ue=Y(Ce);return ue?(0,e.from)(ue).pipe((0,X.map)(()=>Ce)):(0,e.of)(Ce)})}let ba=(()=>{class Y{buildTitle(ue){let Ie,Ze=ue.root;for(;void 0!==Ze;)Ie=this.getResolvedTitleForRoute(Ze)??Ie,Ze=Ze.children.find(kt=>kt.outlet===Q);return Ie}getResolvedTitleForRoute(ue){return ue.data[Ee]}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:()=>(0,i.inject)(Za),providedIn:"root"})}return Y})(),Za=(()=>{class Y extends ba{constructor(ue){super(),this.title=ue}updateTitle(ue){const Ie=this.buildTitle(ue);void 0!==Ie&&this.title.setTitle(Ie)}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275inject(ie.hE))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();const Ks=new i.InjectionToken("",{providedIn:"root",factory:()=>({})});let ac=(()=>{class Y{static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:Y,selectors:[["ng-component"]],standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:1,vars:0,template:function(Ie,Ze){1&Ie&&i.\u0275\u0275element(0,"router-outlet")},dependencies:[Ws],encapsulation:2})}return Y})();function lc(Y){const Ce=Y.children&&Y.children.map(lc),ue=Ce?{...Y,children:Ce}:{...Y};return!ue.component&&!ue.loadComponent&&(Ce||ue.loadChildren)&&ue.outlet&&ue.outlet!==Q&&(ue.component=ac),ue}const ou=new i.InjectionToken("");let qd=(()=>{class Y{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=(0,i.inject)(i.Compiler)}loadComponent(ue){if(this.componentLoaders.get(ue))return this.componentLoaders.get(ue);if(ue._loadedComponent)return(0,e.of)(ue._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(ue);const Ie=wt(ue.loadComponent()).pipe((0,X.map)(xp),(0,X.tap)(kt=>{this.onLoadEndListener&&this.onLoadEndListener(ue),ue._loadedComponent=kt}),(0,X.finalize)(()=>{this.componentLoaders.delete(ue)})),Ze=new e.ConnectableObservable(Ie,()=>new e.Subject).pipe((0,X.refCount)());return this.componentLoaders.set(ue,Ze),Ze}loadChildren(ue,Ie){if(this.childrenLoaders.get(Ie))return this.childrenLoaders.get(Ie);if(Ie._loadedRoutes)return(0,e.of)({routes:Ie._loadedRoutes,injector:Ie._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(Ie);const kt=da(Ie,this.compiler,ue,this.onLoadEndListener).pipe((0,X.finalize)(()=>{this.childrenLoaders.delete(Ie)})),rn=new e.ConnectableObservable(kt,()=>new e.Subject).pipe((0,X.refCount)());return this.childrenLoaders.set(Ie,rn),rn}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();function da(Y,Ce,ue,Ie){return wt(Y.loadChildren()).pipe((0,X.map)(xp),(0,X.mergeMap)(Ze=>Ze instanceof i.NgModuleFactory||Array.isArray(Ze)?(0,e.of)(Ze):(0,e.from)(Ce.compileModuleAsync(Ze))),(0,X.map)(Ze=>{Ie&&Ie(Y);let kt,rn;return Array.isArray(Ze)?rn=Ze:(kt=Ze.create(ue).injector,rn=kt.get(ou,[],{optional:!0,self:!0}).flat()),{routes:rn.map(lc),injector:kt}}))}function xp(Y){return function nd(Y){return Y&&"object"==typeof Y&&"default"in Y}(Y)?Y.default:Y}let bl=(()=>{class Y{static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:()=>(0,i.inject)(_c),providedIn:"root"})}return Y})(),_c=(()=>{class Y{shouldProcessUrl(ue){return!0}extract(ue){return ue}merge(ue,Ie){return ue}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();const cc=new i.InjectionToken(""),qf=new i.InjectionToken("");function aa(Y,Ce,ue){const Ie=Y.get(qf),Ze=Y.get(M.DOCUMENT);return Y.get(i.NgZone).runOutsideAngular(()=>{if(!Ze.startViewTransition||Ie.skipNextTransition)return Ie.skipNextTransition=!1,new Promise(Yr=>setTimeout(Yr));let kt;const rn=new Promise(Yr=>{kt=Yr}),Si=Ze.startViewTransition(()=>(kt(),function Tc(Y){return new Promise(Ce=>{(0,i.afterNextRender)({read:()=>setTimeout(Ce)},{injector:Y})})}(Y))),{onViewTransitionCreated:oi}=Ie;return oi&&(0,i.runInInjectionContext)(Y,()=>oi({transition:Si,from:Ce,to:ue})),rn})}const Ra=new i.InjectionToken("");let hd=(()=>{class Y{get hasRequestedNavigation(){return 0!==this.navigationId}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new e.Subject,this.transitionAbortSubject=new e.Subject,this.configLoader=(0,i.inject)(qd),this.environmentInjector=(0,i.inject)(i.EnvironmentInjector),this.urlSerializer=(0,i.inject)(pn),this.rootContexts=(0,i.inject)(Or),this.location=(0,i.inject)(M.Location),this.inputBindingEnabled=null!==(0,i.inject)(Ma,{optional:!0}),this.titleStrategy=(0,i.inject)(ba),this.options=(0,i.inject)(Ks,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=(0,i.inject)(bl),this.createViewTransition=(0,i.inject)(cc,{optional:!0}),this.navigationErrorHandler=(0,i.inject)(Ra,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>(0,e.of)(void 0),this.rootComponentType=null,this.configLoader.onLoadEndListener=Ze=>this.events.next(new za(Ze)),this.configLoader.onLoadStartListener=Ze=>this.events.next(new Ao(Ze))}complete(){this.transitions?.complete()}handleNavigationRequest(ue){const Ie=++this.navigationId;this.transitions?.next({...this.transitions.value,...ue,id:Ie})}setupNavigations(ue,Ie,Ze){return this.transitions=new e.BehaviorSubject({id:0,currentUrlTree:Ie,currentRawUrl:Ie,extractedUrl:this.urlHandlingStrategy.extract(Ie),urlAfterRedirects:this.urlHandlingStrategy.extract(Ie),rawUrl:Ie,extras:{},resolve:()=>{},reject:()=>{},promise:Promise.resolve(!0),source:Ve,restoredState:null,currentSnapshot:Ze.snapshot,targetSnapshot:null,currentRouterState:Ze,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe((0,X.filter)(kt=>0!==kt.id),(0,X.map)(kt=>({...kt,extractedUrl:this.urlHandlingStrategy.extract(kt.rawUrl)})),(0,X.switchMap)(kt=>{let rn=!1,Si=!1;return(0,e.of)(kt).pipe((0,X.switchMap)(oi=>{if(this.navigationId>kt.id)return this.cancelNavigationTransition(kt,"",Jn.SupersededByNewNavigation),e.EMPTY;this.currentTransition=kt,this.currentNavigation={id:oi.id,initialUrl:oi.rawUrl,extractedUrl:oi.extractedUrl,targetBrowserUrl:"string"==typeof oi.extras.browserUrl?this.urlSerializer.parse(oi.extras.browserUrl):oi.extras.browserUrl,trigger:oi.source,extras:oi.extras,previousNavigation:this.lastSuccessfulNavigation?{...this.lastSuccessfulNavigation,previousNavigation:null}:null};const Yr=!ue.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl();if(!Yr&&"reload"!==(oi.extras.onSameUrlNavigation??ue.onSameUrlNavigation)){const ls="";return this.events.next(new qr(oi.id,this.urlSerializer.serialize(oi.rawUrl),ls,Sn.IgnoredSameUrlNavigation)),oi.resolve(!1),e.EMPTY}if(this.urlHandlingStrategy.shouldProcessUrl(oi.rawUrl))return(0,e.of)(oi).pipe((0,X.switchMap)(ls=>{const Zo=this.transitions?.getValue();return this.events.next(new bt(ls.id,this.urlSerializer.serialize(ls.extractedUrl),ls.source,ls.restoredState)),Zo!==this.transitions?.getValue()?e.EMPTY:Promise.resolve(ls)}),function _i(Y,Ce,ue,Ie,Ze,kt){return(0,X.mergeMap)(rn=>function Xo(Y,Ce,ue,Ie,Ze,kt,rn="emptyOnly"){return new zs(Y,Ce,ue,Ie,Ze,rn,kt).recognize()}(Y,Ce,ue,Ie,rn.extractedUrl,Ze,kt).pipe((0,X.map)(({state:Si,tree:oi})=>({...rn,targetSnapshot:Si,urlAfterRedirects:oi}))))}(this.environmentInjector,this.configLoader,this.rootComponentType,ue.config,this.urlSerializer,this.paramsInheritanceStrategy),(0,X.tap)(ls=>{kt.targetSnapshot=ls.targetSnapshot,kt.urlAfterRedirects=ls.urlAfterRedirects,this.currentNavigation={...this.currentNavigation,finalUrl:ls.urlAfterRedirects};const Zo=new Eo(ls.id,this.urlSerializer.serialize(ls.extractedUrl),this.urlSerializer.serialize(ls.urlAfterRedirects),ls.targetSnapshot);this.events.next(Zo)}));if(Yr&&this.urlHandlingStrategy.shouldProcessUrl(oi.currentRawUrl)){const{id:ls,extractedUrl:Zo,source:Hl,restoredState:dc,extras:ws}=oi,Vc=new bt(ls,this.urlSerializer.serialize(Zo),Hl,dc);this.events.next(Vc);const Wo=Wi(this.rootComponentType).snapshot;return this.currentTransition=kt={...oi,targetSnapshot:Wo,urlAfterRedirects:Zo,extras:{...ws,skipLocationChange:!1,replaceUrl:!1}},this.currentNavigation.finalUrl=Zo,(0,e.of)(kt)}{const ls="";return this.events.next(new qr(oi.id,this.urlSerializer.serialize(oi.extractedUrl),ls,Sn.IgnoredByUrlHandlingStrategy)),oi.resolve(!1),e.EMPTY}}),(0,X.tap)(oi=>{const Yr=new Ro(oi.id,this.urlSerializer.serialize(oi.extractedUrl),this.urlSerializer.serialize(oi.urlAfterRedirects),oi.targetSnapshot);this.events.next(Yr)}),(0,X.map)(oi=>(this.currentTransition=kt={...oi,guards:Qc(oi.targetSnapshot,oi.currentSnapshot,this.rootContexts)},kt)),function Fc(Y,Ce){return(0,X.mergeMap)(ue=>{const{targetSnapshot:Ie,currentSnapshot:Ze,guards:{canActivateChecks:kt,canDeactivateChecks:rn}}=ue;return 0===rn.length&&0===kt.length?(0,e.of)({...ue,guardsResult:!0}):function po(Y,Ce,ue,Ie){return(0,e.from)(Y).pipe((0,X.mergeMap)(Ze=>function Rc(Y,Ce,ue,Ie,Ze){const kt=Ce&&Ce.routeConfig?Ce.routeConfig.canDeactivate:null;if(!kt||0===kt.length)return(0,e.of)(!0);const rn=kt.map(Si=>{const oi=ar(Ce)??Ze,Yr=ec(Si,oi);return wt(function ku(Y){return Y&&Rl(Y.canDeactivate)}(Yr)?Yr.canDeactivate(Y,Ce,ue,Ie):(0,i.runInInjectionContext)(oi,()=>Yr(Y,Ce,ue,Ie))).pipe((0,X.first)())});return(0,e.of)(rn).pipe(vc())}(Ze.component,Ze.route,ue,Ce,Ie)),(0,X.first)(Ze=>!0!==Ze,!0))}(rn,Ie,Ze,Y).pipe((0,X.mergeMap)(Si=>Si&&function yl(Y){return"boolean"==typeof Y}(Si)?function Ll(Y,Ce,ue,Ie){return(0,e.from)(Ce).pipe((0,X.concatMap)(Ze=>(0,e.concat)(function kl(Y,Ce){return null!==Y&&Ce&&Ce(new vl(Y)),(0,e.of)(!0)}(Ze.route.parent,Ie),function Hs(Y,Ce){return null!==Y&&Ce&&Ce(new _l(Y)),(0,e.of)(!0)}(Ze.route,Ie),function fu(Y,Ce,ue){const Ie=Ce[Ce.length-1],kt=Ce.slice(0,Ce.length-1).reverse().map(rn=>function ql(Y){const Ce=Y.routeConfig?Y.routeConfig.canActivateChild:null;return Ce&&0!==Ce.length?{node:Y,guards:Ce}:null}(rn)).filter(rn=>null!==rn).map(rn=>(0,e.defer)(()=>{const Si=rn.guards.map(oi=>{const Yr=ar(rn.node)??ue,rs=ec(oi,Yr);return wt(function Aa(Y){return Y&&Rl(Y.canActivateChild)}(rs)?rs.canActivateChild(Ie,Y):(0,i.runInInjectionContext)(Yr,()=>rs(Ie,Y))).pipe((0,X.first)())});return(0,e.of)(Si).pipe(vc())}));return(0,e.of)(kt).pipe(vc())}(Y,Ze.path,ue),function Nc(Y,Ce,ue){const Ie=Ce.routeConfig?Ce.routeConfig.canActivate:null;if(!Ie||0===Ie.length)return(0,e.of)(!0);const Ze=Ie.map(kt=>(0,e.defer)(()=>{const rn=ar(Ce)??ue,Si=ec(kt,rn);return wt(function Lu(Y){return Y&&Rl(Y.canActivate)}(Si)?Si.canActivate(Ce,Y):(0,i.runInInjectionContext)(rn,()=>Si(Ce,Y))).pipe((0,X.first)())}));return(0,e.of)(Ze).pipe(vc())}(Y,Ze.route,ue))),(0,X.first)(Ze=>!0!==Ze,!0))}(Ie,kt,Y,Ce):(0,e.of)(Si)),(0,X.map)(Si=>({...ue,guardsResult:Si})))})}(this.environmentInjector,oi=>this.events.next(oi)),(0,X.tap)(oi=>{if(kt.guardsResult=oi.guardsResult,oi.guardsResult&&"boolean"!=typeof oi.guardsResult)throw al(0,oi.guardsResult);const Yr=new Ls(oi.id,this.urlSerializer.serialize(oi.extractedUrl),this.urlSerializer.serialize(oi.urlAfterRedirects),oi.targetSnapshot,!!oi.guardsResult);this.events.next(Yr)}),(0,X.filter)(oi=>!!oi.guardsResult||(this.cancelNavigationTransition(oi,"",Jn.GuardRejected),!1)),Gs(oi=>{if(oi.guards.canActivateChecks.length)return(0,e.of)(oi).pipe((0,X.tap)(Yr=>{const rs=new ol(Yr.id,this.urlSerializer.serialize(Yr.extractedUrl),this.urlSerializer.serialize(Yr.urlAfterRedirects),Yr.targetSnapshot);this.events.next(rs)}),(0,X.switchMap)(Yr=>{let rs=!1;return(0,e.of)(Yr).pipe(function Qn(Y,Ce){return(0,X.mergeMap)(ue=>{const{targetSnapshot:Ie,guards:{canActivateChecks:Ze}}=ue;if(!Ze.length)return(0,e.of)(ue);const kt=new Set(Ze.map(oi=>oi.route)),rn=new Set;for(const oi of kt)if(!rn.has(oi))for(const Yr of qi(oi))rn.add(Yr);let Si=0;return(0,e.from)(rn).pipe((0,X.concatMap)(oi=>kt.has(oi)?function Di(Y,Ce,ue,Ie){const Ze=Y.routeConfig,kt=Y._resolve;return void 0!==Ze?.title&&!ds(Ze)&&(kt[Ee]=Ze.title),function fo(Y,Ce,ue,Ie){const Ze=le(Y);if(0===Ze.length)return(0,e.of)({});const kt={};return(0,e.from)(Ze).pipe((0,X.mergeMap)(rn=>function Uo(Y,Ce,ue,Ie){const Ze=ar(Ce)??Ie,kt=ec(Y,Ze);return wt(kt.resolve?kt.resolve(Ce,ue):(0,i.runInInjectionContext)(Ze,()=>kt(Ce,ue)))}(Y[rn],Ce,ue,Ie).pipe((0,X.first)(),(0,X.tap)(Si=>{if(Si instanceof fl)throw al(new Wn,Si);kt[rn]=Si}))),(0,X.takeLast)(1),(0,X.mapTo)(kt),(0,X.catchError)(rn=>sc(rn)?e.EMPTY:(0,e.throwError)(rn)))}(kt,Y,Ce,Ie).pipe((0,X.map)(rn=>(Y._resolvedData=rn,Y.data=Vo(Y,Y.parent,ue).resolve,null)))}(oi,Ie,Y,Ce):(oi.data=Vo(oi,oi.parent,Y).resolve,(0,e.of)(void 0))),(0,X.tap)(()=>Si++),(0,X.takeLast)(1),(0,X.mergeMap)(oi=>Si===rn.size?(0,e.of)(ue):e.EMPTY))})}(this.paramsInheritanceStrategy,this.environmentInjector),(0,X.tap)({next:()=>rs=!0,complete:()=>{rs||this.cancelNavigationTransition(Yr,"",Jn.NoDataFromResolver)}}))}),(0,X.tap)(Yr=>{const rs=new Va(Yr.id,this.urlSerializer.serialize(Yr.extractedUrl),this.urlSerializer.serialize(Yr.urlAfterRedirects),Yr.targetSnapshot);this.events.next(rs)}))}),Gs(oi=>{const Yr=rs=>{const ls=[];rs.routeConfig?.loadComponent&&!rs.routeConfig._loadedComponent&&ls.push(this.configLoader.loadComponent(rs.routeConfig).pipe((0,X.tap)(Zo=>{rs.component=Zo}),(0,X.map)(()=>{})));for(const Zo of rs.children)ls.push(...Yr(Zo));return ls};return(0,e.combineLatest)(Yr(oi.targetSnapshot.root)).pipe((0,X.defaultIfEmpty)(null),(0,X.take)(1))}),Gs(()=>this.afterPreactivation()),(0,X.switchMap)(()=>{const{currentSnapshot:oi,targetSnapshot:Yr}=kt,rs=this.createViewTransition?.(this.environmentInjector,oi.root,Yr.root);return rs?(0,e.from)(rs).pipe((0,X.map)(()=>kt)):(0,e.of)(kt)}),(0,X.map)(oi=>{const Yr=function wo(Y,Ce,ue){const Ie=ea(Y,Ce._root,ue?ue._root:void 0);return new Yi(Ie,Ce)}(ue.routeReuseStrategy,oi.targetSnapshot,oi.currentRouterState);return this.currentTransition=kt={...oi,targetRouterState:Yr},this.currentNavigation.targetRouterState=Yr,kt}),(0,X.tap)(()=>{this.events.next(new oa)}),((Y,Ce,ue,Ie)=>(0,X.map)(Ze=>(new pl(Ce,Ze.targetRouterState,Ze.currentRouterState,ue,Ie).activate(Y),Ze)))(this.rootContexts,ue.routeReuseStrategy,oi=>this.events.next(oi),this.inputBindingEnabled),(0,X.take)(1),(0,X.tap)({next:oi=>{rn=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new nn(oi.id,this.urlSerializer.serialize(oi.extractedUrl),this.urlSerializer.serialize(oi.urlAfterRedirects))),this.titleStrategy?.updateTitle(oi.targetRouterState.snapshot),oi.resolve(!0)},complete:()=>{rn=!0}}),(0,X.takeUntil)(this.transitionAbortSubject.pipe((0,X.tap)(oi=>{throw oi}))),(0,X.finalize)(()=>{!rn&&!Si&&this.cancelNavigationTransition(kt,"",Jn.SupersededByNewNavigation),this.currentTransition?.id===kt.id&&(this.currentNavigation=null,this.currentTransition=null)}),(0,X.catchError)(oi=>{if(Si=!0,Sl(oi))this.events.next(new _r(kt.id,this.urlSerializer.serialize(kt.extractedUrl),oi.message,oi.cancellationCode)),function wa(Y){return Sl(Y)&&yt(Y.url)}(oi)?this.events.next(new no(oi.url,oi.navigationBehaviorOptions)):kt.resolve(!1);else{const Yr=new Bo(kt.id,this.urlSerializer.serialize(kt.extractedUrl),oi,kt.targetSnapshot??void 0);try{const rs=(0,i.runInInjectionContext)(this.environmentInjector,()=>this.navigationErrorHandler?.(Yr));if(rs instanceof fl){const{message:ls,cancellationCode:Zo}=al(0,rs);this.events.next(new _r(kt.id,this.urlSerializer.serialize(kt.extractedUrl),ls,Zo)),this.events.next(new no(rs.redirectTo,rs.navigationBehaviorOptions))}else{this.events.next(Yr);const ls=ue.errorHandler(oi);kt.resolve(!!ls)}}catch(rs){this.options.resolveNavigationPromiseOnError?kt.resolve(!1):kt.reject(rs)}}return e.EMPTY}))}))}cancelNavigationTransition(ue,Ie,Ze){const kt=new _r(ue.id,this.urlSerializer.serialize(ue.extractedUrl),Ie,Ze);this.events.next(kt),ue.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){const ue=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),Ie=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return ue.toString()!==Ie?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();function ff(Y){return Y!==Ve}let Yt=(()=>{class Y{static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:()=>(0,i.inject)(Qh),providedIn:"root"})}return Y})();class tc{shouldDetach(Ce){return!1}store(Ce,ue){}shouldAttach(Ce){return!1}retrieve(Ce){return null}shouldReuseRoute(Ce,ue){return Ce.routeConfig===ue.routeConfig}}let Qh=(()=>{class Y extends tc{static#e=this.\u0275fac=(()=>{let ue;return function(Ze){return(ue||(ue=i.\u0275\u0275getInheritedFactory(Y)))(Ze||Y)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})(),Su=(()=>{class Y{static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:()=>(0,i.inject)(md),providedIn:"root"})}return Y})(),md=(()=>{class Y extends Su{constructor(){super(...arguments),this.location=(0,i.inject)(M.Location),this.urlSerializer=(0,i.inject)(pn),this.options=(0,i.inject)(Ks,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=(0,i.inject)(bl),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new dt,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=Wi(null),this.stateMemento=this.createStateMemento()}getCurrentUrlTree(){return this.currentUrlTree}getRawUrlTree(){return this.rawUrlTree}restoredState(){return this.location.getState()}get browserPageId(){return"computed"!==this.canceledNavigationResolution?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}getRouterState(){return this.routerState}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}registerNonRouterCurrentEntryChangeListener(ue){return this.location.subscribe(Ie=>{"popstate"===Ie.type&&ue(Ie.url,Ie.state)})}handleRouterEvent(ue,Ie){if(ue instanceof bt)this.stateMemento=this.createStateMemento();else if(ue instanceof qr)this.rawUrlTree=Ie.initialUrl;else if(ue instanceof Eo){if("eager"===this.urlUpdateStrategy&&!Ie.extras.skipLocationChange){const Ze=this.urlHandlingStrategy.merge(Ie.finalUrl,Ie.initialUrl);this.setBrowserUrl(Ie.targetBrowserUrl??Ze,Ie)}}else ue instanceof oa?(this.currentUrlTree=Ie.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(Ie.finalUrl,Ie.initialUrl),this.routerState=Ie.targetRouterState,"deferred"===this.urlUpdateStrategy&&!Ie.extras.skipLocationChange&&this.setBrowserUrl(Ie.targetBrowserUrl??this.rawUrlTree,Ie)):ue instanceof _r&&(ue.code===Jn.GuardRejected||ue.code===Jn.NoDataFromResolver)?this.restoreHistory(Ie):ue instanceof Bo?this.restoreHistory(Ie,!0):ue instanceof nn&&(this.lastSuccessfulId=ue.id,this.currentPageId=this.browserPageId)}setBrowserUrl(ue,Ie){const Ze=ue instanceof dt?this.urlSerializer.serialize(ue):ue;if(this.location.isCurrentPathEqualTo(Ze)||Ie.extras.replaceUrl){const rn={...Ie.extras.state,...this.generateNgRouterState(Ie.id,this.browserPageId)};this.location.replaceState(Ze,"",rn)}else{const kt={...Ie.extras.state,...this.generateNgRouterState(Ie.id,this.browserPageId+1)};this.location.go(Ze,"",kt)}}restoreHistory(ue,Ie=!1){if("computed"===this.canceledNavigationResolution){const kt=this.currentPageId-this.browserPageId;0!==kt?this.location.historyGo(kt):this.currentUrlTree===ue.finalUrl&&0===kt&&(this.resetState(ue),this.resetUrlToCurrentUrlTree())}else"replace"===this.canceledNavigationResolution&&(Ie&&this.resetState(ue),this.resetUrlToCurrentUrlTree())}resetState(ue){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,ue.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(ue,Ie){return"computed"===this.canceledNavigationResolution?{navigationId:ue,\u0275routerPageId:Ie}:{navigationId:ue}}static#e=this.\u0275fac=(()=>{let ue;return function(Ze){return(ue||(ue=i.\u0275\u0275getInheritedFactory(Y)))(Ze||Y)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();var Ld=function(Y){return Y[Y.COMPLETE=0]="COMPLETE",Y[Y.FAILED=1]="FAILED",Y[Y.REDIRECTING=2]="REDIRECTING",Y}(Ld||{});function gd(Y,Ce){Y.events.pipe((0,X.filter)(ue=>ue instanceof nn||ue instanceof _r||ue instanceof Bo||ue instanceof qr),(0,X.map)(ue=>ue instanceof nn||ue instanceof qr?Ld.COMPLETE:ue instanceof _r&&(ue.code===Jn.Redirect||ue.code===Jn.SupersededByNewNavigation)?Ld.REDIRECTING:Ld.FAILED),(0,X.filter)(ue=>ue!==Ld.REDIRECTING),(0,X.take)(1)).subscribe(()=>{Ce()})}function Eu(Y){throw Y}const Pu={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Lc={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};let qs=(()=>{class Y{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}constructor(){this.disposed=!1,this.console=(0,i.inject)(i.\u0275Console),this.stateManager=(0,i.inject)(Su),this.options=(0,i.inject)(Ks,{optional:!0})||{},this.pendingTasks=(0,i.inject)(i.\u0275PendingTasks),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=(0,i.inject)(hd),this.urlSerializer=(0,i.inject)(pn),this.location=(0,i.inject)(M.Location),this.urlHandlingStrategy=(0,i.inject)(bl),this._events=new e.Subject,this.errorHandler=this.options.errorHandler||Eu,this.navigated=!1,this.routeReuseStrategy=(0,i.inject)(Yt),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=(0,i.inject)(ou,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!(0,i.inject)(Ma,{optional:!0}),this.eventsSubscription=new e.Subscription,this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:ue=>{this.console.warn(ue)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){const ue=this.navigationTransitions.events.subscribe(Ie=>{try{const Ze=this.navigationTransitions.currentTransition,kt=this.navigationTransitions.currentNavigation;if(null!==Ze&&null!==kt)if(this.stateManager.handleRouterEvent(Ie,kt),Ie instanceof _r&&Ie.code!==Jn.Redirect&&Ie.code!==Jn.SupersededByNewNavigation)this.navigated=!0;else if(Ie instanceof nn)this.navigated=!0;else if(Ie instanceof no){const rn=Ie.navigationBehaviorOptions,Si=this.urlHandlingStrategy.merge(Ie.url,Ze.currentRawUrl),oi={browserUrl:Ze.extras.browserUrl,info:Ze.extras.info,skipLocationChange:Ze.extras.skipLocationChange,replaceUrl:Ze.extras.replaceUrl||"eager"===this.urlUpdateStrategy||ff(Ze.source),...rn};this.scheduleNavigation(Si,Ve,null,oi,{resolve:Ze.resolve,reject:Ze.reject,promise:Ze.promise})}(function Bu(Y){return!(Y instanceof oa||Y instanceof no)})(Ie)&&this._events.next(Ie)}catch(Ze){this.navigationTransitions.transitionAbortSubject.next(Ze)}});this.eventsSubscription.add(ue)}resetRootComponentType(ue){this.routerState.root.component=ue,this.navigationTransitions.rootComponentType=ue}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Ve,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((ue,Ie)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(ue,"popstate",Ie)},0)})}navigateToSyncWithBrowser(ue,Ie,Ze){const kt={replaceUrl:!0},rn=Ze?.navigationId?Ze:null;if(Ze){const oi={...Ze};delete oi.navigationId,delete oi.\u0275routerPageId,0!==Object.keys(oi).length&&(kt.state=oi)}const Si=this.parseUrl(ue);this.scheduleNavigation(Si,Ie,rn,kt)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(ue){this.config=ue.map(lc),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(ue,Ie={}){const{relativeTo:Ze,queryParams:kt,fragment:rn,queryParamsHandling:Si,preserveFragment:oi}=Ie,Yr=oi?this.currentUrlTree.fragment:rn;let ls,rs=null;switch(Si??this.options.defaultQueryParamsHandling){case"merge":rs={...this.currentUrlTree.queryParams,...kt};break;case"preserve":rs=this.currentUrlTree.queryParams;break;default:rs=kt||null}null!==rs&&(rs=this.removeEmptyProps(rs));try{ls=Gt(Ze?Ze.snapshot:this.routerState.snapshot.root)}catch{("string"!=typeof ue[0]||"/"!==ue[0][0])&&(ue=[]),ls=this.currentUrlTree.root}return Gn(ls,ue,rs,Yr??null)}navigateByUrl(ue,Ie={skipLocationChange:!1}){const Ze=yt(ue)?ue:this.parseUrl(ue),kt=this.urlHandlingStrategy.merge(Ze,this.rawUrlTree);return this.scheduleNavigation(kt,Ve,null,Ie)}navigate(ue,Ie={skipLocationChange:!1}){return function Xc(Y){for(let Ce=0;Ce<Y.length;Ce++)if(null==Y[Ce])throw new i.\u0275RuntimeError(4008,!1)}(ue),this.navigateByUrl(this.createUrlTree(ue,Ie),Ie)}serializeUrl(ue){return this.urlSerializer.serialize(ue)}parseUrl(ue){try{return this.urlSerializer.parse(ue)}catch{return this.urlSerializer.parse("/")}}isActive(ue,Ie){let Ze;if(Ze=!0===Ie?{...Pu}:!1===Ie?{...Lc}:Ie,yt(ue))return ct(this.currentUrlTree,ue,Ze);const kt=this.parseUrl(ue);return ct(this.currentUrlTree,kt,Ze)}removeEmptyProps(ue){return Object.entries(ue).reduce((Ie,[Ze,kt])=>(null!=kt&&(Ie[Ze]=kt),Ie),{})}scheduleNavigation(ue,Ie,Ze,kt,rn){if(this.disposed)return Promise.resolve(!1);let Si,oi,Yr;rn?(Si=rn.resolve,oi=rn.reject,Yr=rn.promise):Yr=new Promise((ls,Zo)=>{Si=ls,oi=Zo});const rs=this.pendingTasks.add();return gd(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(rs))}),this.navigationTransitions.handleNavigationRequest({source:Ie,restoredState:Ze,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:ue,extras:kt,resolve:Si,reject:oi,promise:Yr,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),Yr.catch(ls=>Promise.reject(ls))}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})(),su=(()=>{class Y{constructor(ue,Ie,Ze,kt,rn,Si){this.router=ue,this.route=Ie,this.tabIndexAttribute=Ze,this.renderer=kt,this.el=rn,this.locationStrategy=Si,this.href=null,this.onChanges=new e.Subject,this.preserveFragment=!1,this.skipLocationChange=!1,this.replaceUrl=!1,this.routerLinkInput=null;const oi=rn.nativeElement.tagName?.toLowerCase();this.isAnchorElement="a"===oi||"area"===oi,this.isAnchorElement?this.subscription=ue.events.subscribe(Yr=>{Yr instanceof nn&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}setTabIndexIfNotOnNativeEl(ue){null!=this.tabIndexAttribute||this.isAnchorElement||this.applyAttributeValue("tabindex",ue)}ngOnChanges(ue){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}set routerLink(ue){null==ue?(this.routerLinkInput=null,this.setTabIndexIfNotOnNativeEl(null)):(this.routerLinkInput=yt(ue)||Array.isArray(ue)?ue:[ue],this.setTabIndexIfNotOnNativeEl("0"))}onClick(ue,Ie,Ze,kt,rn){const Si=this.urlTree;return!!(null===Si||this.isAnchorElement&&(0!==ue||Ie||Ze||kt||rn||"string"==typeof this.target&&"_self"!=this.target))||(this.router.navigateByUrl(Si,{skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info}),!this.isAnchorElement)}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){const ue=this.urlTree;this.href=null!==ue&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(ue)):null;const Ie=null===this.href?null:(0,i.\u0275\u0275sanitizeUrlOrResourceUrl)(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",Ie)}applyAttributeValue(ue,Ie){const Ze=this.renderer,kt=this.el.nativeElement;null!==Ie?Ze.setAttribute(kt,ue,Ie):Ze.removeAttribute(kt,ue)}get urlTree(){return null===this.routerLinkInput?null:yt(this.routerLinkInput)?this.routerLinkInput:this.router.createUrlTree(this.routerLinkInput,{relativeTo:void 0!==this.relativeTo?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:this.preserveFragment})}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275directiveInject(qs),i.\u0275\u0275directiveInject(Li),i.\u0275\u0275injectAttribute("tabindex"),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(M.LocationStrategy))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Y,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(Ie,Ze){1&Ie&&i.\u0275\u0275listener("click",function(rn){return Ze.onClick(rn.button,rn.ctrlKey,rn.shiftKey,rn.altKey,rn.metaKey)}),2&Ie&&i.\u0275\u0275attribute("target",Ze.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",i.booleanAttribute],skipLocationChange:[2,"skipLocationChange","skipLocationChange",i.booleanAttribute],replaceUrl:[2,"replaceUrl","replaceUrl",i.booleanAttribute],routerLink:"routerLink"},standalone:!0,features:[i.\u0275\u0275InputTransformsFeature,i.\u0275\u0275NgOnChangesFeature]})}return Y})(),Is=(()=>{class Y{get isActive(){return this._isActive}constructor(ue,Ie,Ze,kt,rn){this.router=ue,this.element=Ie,this.renderer=Ze,this.cdr=kt,this.link=rn,this.classes=[],this._isActive=!1,this.routerLinkActiveOptions={exact:!1},this.isActiveChange=new i.EventEmitter,this.routerEventsSubscription=ue.events.subscribe(Si=>{Si instanceof nn&&this.update()})}ngAfterContentInit(){(0,e.of)(this.links.changes,(0,e.of)(null)).pipe((0,X.mergeAll)()).subscribe(ue=>{this.update(),this.subscribeToEachLinkOnChanges()})}subscribeToEachLinkOnChanges(){this.linkInputChangesSubscription?.unsubscribe();const ue=[...this.links.toArray(),this.link].filter(Ie=>!!Ie).map(Ie=>Ie.onChanges);this.linkInputChangesSubscription=(0,e.from)(ue).pipe((0,X.mergeAll)()).subscribe(Ie=>{this._isActive!==this.isLinkActive(this.router)(Ie)&&this.update()})}set routerLinkActive(ue){const Ie=Array.isArray(ue)?ue:ue.split(" ");this.classes=Ie.filter(Ze=>!!Ze)}ngOnChanges(ue){this.update()}ngOnDestroy(){this.routerEventsSubscription.unsubscribe(),this.linkInputChangesSubscription?.unsubscribe()}update(){!this.links||!this.router.navigated||queueMicrotask(()=>{const ue=this.hasActiveLinks();this.classes.forEach(Ie=>{ue?this.renderer.addClass(this.element.nativeElement,Ie):this.renderer.removeClass(this.element.nativeElement,Ie)}),ue&&void 0!==this.ariaCurrentWhenActive?this.renderer.setAttribute(this.element.nativeElement,"aria-current",this.ariaCurrentWhenActive.toString()):this.renderer.removeAttribute(this.element.nativeElement,"aria-current"),this._isActive!==ue&&(this._isActive=ue,this.cdr.markForCheck(),this.isActiveChange.emit(ue))})}isLinkActive(ue){const Ie=function xa(Y){return!!Y.paths}(this.routerLinkActiveOptions)?this.routerLinkActiveOptions:this.routerLinkActiveOptions.exact||!1;return Ze=>{const kt=Ze.urlTree;return!!kt&&ue.isActive(kt,Ie)}}hasActiveLinks(){const ue=this.isLinkActive(this.router);return this.link&&ue(this.link)||this.links.some(ue)}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275directiveInject(qs),i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(su,8))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:Y,selectors:[["","routerLinkActive",""]],contentQueries:function(Ie,Ze,kt){if(1&Ie&&i.\u0275\u0275contentQuery(kt,su,5),2&Ie){let rn;i.\u0275\u0275queryRefresh(rn=i.\u0275\u0275loadQuery())&&(Ze.links=rn)}},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",ariaCurrentWhenActive:"ariaCurrentWhenActive",routerLinkActive:"routerLinkActive"},outputs:{isActiveChange:"isActiveChange"},exportAs:["routerLinkActive"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return Y})();class vd{}let Vu=(()=>{class Y{preload(ue,Ie){return Ie().pipe((0,X.catchError)(()=>(0,e.of)(null)))}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})(),id=(()=>{class Y{preload(ue,Ie){return(0,e.of)(null)}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})(),Sd=(()=>{class Y{constructor(ue,Ie,Ze,kt,rn){this.router=ue,this.injector=Ze,this.preloadingStrategy=kt,this.loader=rn}setUpPreloading(){this.subscription=this.router.events.pipe((0,X.filter)(ue=>ue instanceof nn),(0,X.concatMap)(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(ue,Ie){const Ze=[];for(const kt of Ie){kt.providers&&!kt._injector&&(kt._injector=(0,i.createEnvironmentInjector)(kt.providers,ue,`Route: ${kt.path}`));const rn=kt._injector??ue,Si=kt._loadedInjector??rn;(kt.loadChildren&&!kt._loadedRoutes&&void 0===kt.canLoad||kt.loadComponent&&!kt._loadedComponent)&&Ze.push(this.preloadConfig(rn,kt)),(kt.children||kt._loadedRoutes)&&Ze.push(this.processRoutes(Si,kt.children??kt._loadedRoutes))}return(0,e.from)(Ze).pipe((0,X.mergeAll)())}preloadConfig(ue,Ie){return this.preloadingStrategy.preload(Ie,()=>{let Ze;Ze=Ie.loadChildren&&void 0===Ie.canLoad?this.loader.loadChildren(ue,Ie):(0,e.of)(null);const kt=Ze.pipe((0,X.mergeMap)(rn=>null===rn?(0,e.of)(void 0):(Ie._loadedRoutes=rn.routes,Ie._loadedInjector=rn.injector,this.processRoutes(rn.injector??ue,rn.routes))));if(Ie.loadComponent&&!Ie._loadedComponent){const rn=this.loader.loadComponent(Ie);return(0,e.from)([kt,rn]).pipe((0,X.mergeAll)())}return kt})}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275inject(qs),i.\u0275\u0275inject(i.Compiler),i.\u0275\u0275inject(i.EnvironmentInjector),i.\u0275\u0275inject(vd),i.\u0275\u0275inject(qd))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac,providedIn:"root"})}return Y})();const pu=new i.InjectionToken("");let hu=(()=>{class Y{constructor(ue,Ie,Ze,kt,rn={}){this.urlSerializer=ue,this.transitions=Ie,this.viewportScroller=Ze,this.zone=kt,this.options=rn,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},rn.scrollPositionRestoration||="disabled",rn.anchorScrolling||="disabled"}init(){"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(ue=>{ue instanceof bt?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=ue.navigationTrigger,this.restoredId=ue.restoredState?ue.restoredState.navigationId:0):ue instanceof nn?(this.lastId=ue.id,this.scheduleScrollEvent(ue,this.urlSerializer.parse(ue.urlAfterRedirects).fragment)):ue instanceof qr&&ue.code===Sn.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(ue,this.urlSerializer.parse(ue.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(ue=>{ue instanceof Zs&&(ue.position?"top"===this.options.scrollPositionRestoration?this.viewportScroller.scrollToPosition([0,0]):"enabled"===this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition(ue.position):ue.anchor&&"enabled"===this.options.anchorScrolling?this.viewportScroller.scrollToAnchor(ue.anchor):"disabled"!==this.options.scrollPositionRestoration&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(ue,Ie){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new Zs(ue,"popstate"===this.lastSource?this.store[this.restoredId]:null,Ie))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static#e=this.\u0275fac=function(Ie){i.\u0275\u0275invalidFactory()};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:Y,factory:Y.\u0275fac})}return Y})();function As(Y,...Ce){return(0,i.makeEnvironmentProviders)([{provide:ou,multi:!0,useValue:Y},[],{provide:Li,useFactory:Ed,deps:[qs]},{provide:i.APP_BOOTSTRAP_LISTENER,multi:!0,useFactory:Pc},Ce.map(ue=>ue.\u0275providers)])}function Ed(Y){return Y.routerState.root}function kc(Y,Ce){return{\u0275kind:Y,\u0275providers:Ce}}function kd(Y){return[{provide:ou,multi:!0,useValue:Y},[]]}function Td(Y={}){return kc(4,[{provide:pu,useFactory:()=>{const ue=(0,i.inject)(M.ViewportScroller),Ie=(0,i.inject)(i.NgZone),Ze=(0,i.inject)(hd),kt=(0,i.inject)(pn);return new hu(kt,Ze,ue,Ie,Y)}}])}function Pc(){const Y=(0,i.inject)(i.Injector);return Ce=>{const ue=Y.get(i.ApplicationRef);if(Ce!==ue.components[0])return;const Ie=Y.get(qs),Ze=Y.get(ju);1===Y.get(Yl)&&Ie.initialNavigation(),Y.get(_e,null,i.InjectFlags.Optional)?.setUpPreloading(),Y.get(pu,null,i.InjectFlags.Optional)?.init(),Ie.resetRootComponentType(ue.componentTypes[0]),Ze.closed||(Ze.next(),Ze.complete(),Ze.unsubscribe())}}const ju=new i.InjectionToken("",{factory:()=>new e.Subject}),Yl=new i.InjectionToken("",{providedIn:"root",factory:()=>1});function Bc(){return kc(2,[{provide:Yl,useValue:0},{provide:i.APP_INITIALIZER,multi:!0,deps:[i.Injector],useFactory:Ce=>{const ue=Ce.get(M.LOCATION_INITIALIZED,Promise.resolve());return()=>ue.then(()=>new Promise(Ie=>{const Ze=Ce.get(qs),kt=Ce.get(ju);gd(Ze,()=>{Ie(!0)}),Ce.get(hd).afterPreactivation=()=>(Ie(!0),kt.closed?(0,e.of)(void 0):kt),Ze.initialNavigation()}))}}])}function pf(){return kc(3,[{provide:i.APP_INITIALIZER,multi:!0,useFactory:()=>{const Ce=(0,i.inject)(qs);return()=>{Ce.setUpLocationChangeListener()}}},{provide:Yl,useValue:2}])}function hf(){let Y=[];return Y=[],kc(1,Y)}const _e=new i.InjectionToken("");function Dt(Y){return kc(0,[{provide:_e,useExisting:Sd},{provide:vd,useExisting:Y}])}function Re(Y){return kc(5,[{provide:Ks,useValue:Y}])}function tt(){return kc(6,[{provide:M.LocationStrategy,useClass:M.HashLocationStrategy}])}function mn(Y){return kc(7,[{provide:Ra,useValue:Y}])}function gi(){return kc(8,[ts,{provide:Ma,useExisting:ts}])}function rr(Y){return kc(9,[{provide:cc,useValue:aa},{provide:qf,useValue:{skipNextTransition:!!Y?.skipInitialTransition,...Y}}])}const ia=new i.InjectionToken("ROUTER_FORROOT_GUARD"),La=[M.Location,{provide:pn,useClass:Wn},qs,Or,{provide:Li,useFactory:Ed,deps:[qs]},qd,[]];let vs=(()=>{class Y{constructor(ue){}static forRoot(ue,Ie){return{ngModule:Y,providers:[La,[],{provide:ou,multi:!0,useValue:ue},{provide:ia,useFactory:$o,deps:[[qs,new i.Optional,new i.SkipSelf]]},{provide:Ks,useValue:Ie||{}},Ie?.useHash?{provide:M.LocationStrategy,useClass:M.HashLocationStrategy}:{provide:M.LocationStrategy,useClass:M.PathLocationStrategy},{provide:pu,useFactory:()=>{const Y=(0,i.inject)(M.ViewportScroller),Ce=(0,i.inject)(i.NgZone),ue=(0,i.inject)(Ks),Ie=(0,i.inject)(hd),Ze=(0,i.inject)(pn);return ue.scrollOffset&&Y.setOffset(ue.scrollOffset),new hu(Ze,Ie,Y,Ce,ue)}},Ie?.preloadingStrategy?Dt(Ie.preloadingStrategy).\u0275providers:[],Ie?.initialNavigation?Mc(Ie):[],Ie?.bindToComponentInputs?gi().\u0275providers:[],Ie?.enableViewTransitions?rr().\u0275providers:[],[{provide:yc,useFactory:Pc},{provide:i.APP_BOOTSTRAP_LISTENER,multi:!0,useExisting:yc}]]}}static forChild(ue){return{ngModule:Y,providers:[{provide:ou,multi:!0,useValue:ue}]}}static#e=this.\u0275fac=function(Ie){return new(Ie||Y)(i.\u0275\u0275inject(ia,8))};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:Y});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return Y})();function $o(Y){return"guarded"}function Mc(Y){return["disabled"===Y.initialNavigation?pf().\u0275providers:[],"enabledBlocking"===Y.initialNavigation?Bc().\u0275providers:[]]}const yc=new i.InjectionToken("");function ne(Y){return Y.map(Ce=>(...ue)=>(0,i.inject)(Ce).canMatch(...ue))}function Pe(Y){return Y.map(Ce=>(...ue)=>(0,i.inject)(Ce).canActivate(...ue))}function rt(Y){return Y.map(Ce=>(...ue)=>(0,i.inject)(Ce).canActivateChild(...ue))}function Ut(Y){return Y.map(Ce=>(...ue)=>(0,i.inject)(Ce).canDeactivate(...ue))}function Rn(Y){return(...Ce)=>(0,i.inject)(Y).resolve(...Ce)}const Kn=new i.Version("18.2.8")},4141:(Ot,Me,S)=>{S.d(Me,{bl:()=>e});var e=new(S(7773).DX)},9471:(Ot,Me,S)=>{S.d(Me,{a:()=>Ee});var i=S(3844),e=S(9860),M=S(4229),X=S(6108),ie=S(4183),Q=S(1367);function Ee(Z,ce,le,je){var Et=ce.data,wt=(0,i.Tt)(ce,["data"]),ve=le.data,fn=(0,i.Tt)(le,["data"]);return(0,e.A)(wt,fn)&&he((0,M.Vn)(Z).selectionSet,Et,ve,{fragmentMap:(0,X.JG)((0,M.zK)(Z)),variables:je})}function he(Z,ce,le,je){if(ce===le)return!0;var Et=new Set;return Z.selections.every(function(wt){if(Et.has(wt)||(Et.add(wt),!(0,ie.MS)(wt,je.variables))||q(wt))return!0;if((0,Q.dt)(wt)){var ve=(0,Q.ue)(wt),fn=ce&&ce[ve],ct=le&&le[ve],en=wt.selectionSet;if(!en)return(0,e.A)(fn,ct);var an=Array.isArray(fn),un=Array.isArray(ct);if(an!==un)return!1;if(an&&un){var vn=fn.length;if(ct.length!==vn)return!1;for(var Pt=0;Pt<vn;++Pt)if(!he(en,fn[Pt],ct[Pt],je))return!1;return!0}return he(en,fn,ct,je)}var Ae=(0,X.HQ)(wt,je.fragmentMap);return Ae?!!q(Ae)||he(Ae.selectionSet,ce,le,je):void 0})}function q(Z){return!!Z.directives&&Z.directives.some(oe)}function oe(Z){return"nonreactive"===Z.name.value}},8008:(Ot,Me,S)=>{S.d(Me,{C:()=>Z});var i=S(2455),e=S(7994),M=S(3844),ie=S(4229);function he(ce,le){return le?le(ce):e.c.of()}function q(ce){return"function"==typeof ce?new Z(ce):ce}function oe(ce){return ce.request.length<=1}var Z=function(){function ce(le){le&&(this.request=le)}return ce.empty=function(){return new ce(function(){return e.c.of()})},ce.from=function(le){return 0===le.length?ce.empty():le.map(q).reduce(function(je,Et){return je.concat(Et)})},ce.split=function(le,je,Et){var fn,wt=q(je),ve=q(Et||new ce(he));return fn=oe(wt)&&oe(ve)?new ce(function(ct){return le(ct)?wt.request(ct)||e.c.of():ve.request(ct)||e.c.of()}):new ce(function(ct,en){return le(ct)?wt.request(ct,en)||e.c.of():ve.request(ct,en)||e.c.of()}),Object.assign(fn,{left:wt,right:ve})},ce.execute=function(le,je){return le.request(function X(ce,le){var je=(0,M.Cl)({},ce);return Object.defineProperty(le,"setContext",{enumerable:!1,value:function(ve){je=(0,M.Cl)((0,M.Cl)({},je),"function"==typeof ve?ve(je):ve)}}),Object.defineProperty(le,"getContext",{enumerable:!1,value:function(){return(0,M.Cl)({},je)}}),le}(je.context,function Q(ce){var le={variables:ce.variables||{},extensions:ce.extensions||{},operationName:ce.operationName,query:ce.query};return le.operationName||(le.operationName="string"!=typeof le.query?(0,ie.n4)(le.query)||void 0:""),le}(function Ee(ce){for(var le=["query","operationName","variables","extensions","context"],je=0,Et=Object.keys(ce);je<Et.length;je++){var wt=Et[je];if(le.indexOf(wt)<0)throw(0,i.vA)(44,wt)}return ce}(je))))||e.c.of()},ce.concat=function(le,je){var Et=q(le);if(oe(Et))return!1!==globalThis.__DEV__&&i.V1.warn(36,Et),Et;var ve,wt=q(je);return ve=oe(wt)?new ce(function(fn){return Et.request(fn,function(ct){return wt.request(ct)||e.c.of()})||e.c.of()}):new ce(function(fn,ct){return Et.request(fn,function(en){return wt.request(en,ct)||e.c.of()})||e.c.of()}),Object.assign(ve,{left:Et,right:wt})},ce.prototype.split=function(le,je,Et){return this.concat(ce.split(le,je,Et||new ce(he)))},ce.prototype.concat=function(le){return ce.concat(this,le)},ce.prototype.request=function(le,je){throw(0,i.vA)(37)},ce.prototype.onError=function(le,je){if(je&&je.error)return je.error(le),!1;throw le},ce.prototype.setOnError=function(le){return this.onError=le,this},ce}()},2170:(Ot,Me,S)=>{S.d(Me,{A:()=>ie,V:()=>Q});var i=S(9055),e=S(6476),M=new WeakSet;function X(Ee){Ee.size<=(Ee.max||-1)||M.has(Ee)||(M.add(Ee),setTimeout(function(){Ee.clean(),M.delete(Ee)},100))}var ie=function(Ee,he){var q=new i.l(Ee,he);return q.set=function(oe,Z){var ce=i.l.prototype.set.call(this,oe,Z);return X(this),ce},q},Q=function(Ee,he){var q=new e.C(Ee,he);return q.set=function(oe,Z){var ce=e.C.prototype.set.call(this,oe,Z);return X(this),ce},q}},8782:(Ot,Me,S)=>{S.d(Me,{D_:()=>X,ep:()=>ie});var i=S(3844),e=S(2151),M={};function X(fn,ct){M[fn]=ct}var ie=!1!==globalThis.__DEV__?function q(){var fn,ct,en,an,un;if(!1===globalThis.__DEV__)throw new Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(ct){var en=ct[0];return[en,e.v[en]||ct[1]]})),sizes:(0,i.Cl)({print:null===(fn=M.print)||void 0===fn?void 0:fn.call(M),parser:null===(ct=M.parser)||void 0===ct?void 0:ct.call(M),canonicalStringify:null===(en=M.canonicalStringify)||void 0===en?void 0:en.call(M),links:ve(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:Et(this.queryManager.documentTransform)}},null===(un=(an=this.cache).getMemoryInternals)||void 0===un?void 0:un.call(an))}}:void 0;function le(fn){return function ce(fn){return!!fn&&"dirtyKey"in fn}(fn)?fn.size:void 0}function je(fn){return null!=fn}function Et(fn){return wt(fn).map(function(ct){return{cache:ct}})}function wt(fn){return fn?(0,i.fX)((0,i.fX)([le(fn?.performWork)],wt(fn?.left),!0),wt(fn?.right),!0).filter(je):[]}function ve(fn){var ct;return fn?(0,i.fX)((0,i.fX)([null===(ct=fn?.getMemoryInternals)||void 0===ct?void 0:ct.call(fn)],ve(fn?.left),!0),ve(fn?.right),!0).filter(je):[]}globalThis,globalThis},2151:(Ot,Me,S)=>{S.d(Me,{v:()=>X});var i=S(3844),e=S(2455),M=Symbol.for("apollo.cacheSize"),X=(0,i.Cl)({},e.Sf[M])},7715:(Ot,Me,S)=>{S.d(Me,{E:()=>e,c:()=>i});var i=Array.isArray;function e(M){return Array.isArray(M)&&M.length>0}},6500:(Ot,Me,S)=>{S.d(Me,{En:()=>X,et:()=>M,ol:()=>ie,uJ:()=>Q});var i=S(2455),e="ReactNative"==(0,i.no)(function(){return navigator.product}),M="function"==typeof WeakMap&&!(e&&!global.HermesInternal),X="function"==typeof WeakSet,ie="function"==typeof Symbol&&"function"==typeof Symbol.for,Q=ie&&Symbol.asyncIterator;(0,i.no)(function(){return window.document.createElement}),(0,i.no)(function(){return navigator.userAgent.indexOf("jsdom")>=0})},2130:(Ot,Me,S)=>{S.d(Me,{M:()=>X});var ie,i=S(2170),e=S(2151),M=S(8782),X=Object.assign(function(q){return JSON.stringify(q,Q)},{reset:function(){ie=new i.V(e.v.canonicalStringify||1e3)}});function Q(he,q){if(q&&"object"==typeof q){var oe=Object.getPrototypeOf(q);if(oe===Object.prototype||null===oe){var Z=Object.keys(q);if(Z.every(Ee))return q;var ce=JSON.stringify(Z),le=ie.get(ce);if(!le){Z.sort();var je=JSON.stringify(Z);le=ie.get(je)||Z,ie.set(ce,le),ie.set(je,le)}var Et=Object.create(oe);return le.forEach(function(wt){Et[wt]=q[wt]}),Et}}return q}function Ee(he,q,oe){return 0===q||oe[q-1]<=he}!1!==globalThis.__DEV__&&(0,M.D_)("canonicalStringify",function(){return ie.size}),X.reset()},4246:(Ot,Me,S)=>{S.d(Me,{m:()=>e});var i=Object.prototype.toString;function e(X){return M(X)}function M(X,ie){switch(i.call(X)){case"[object Array]":if((ie=ie||new Map).has(X))return ie.get(X);var Q=X.slice(0);return ie.set(X,Q),Q.forEach(function(he,q){Q[q]=M(he,ie)}),Q;case"[object Object]":if((ie=ie||new Map).has(X))return ie.get(X);var Ee=Object.create(Object.getPrototypeOf(X));return ie.set(X,Ee),Object.keys(X).forEach(function(he){Ee[he]=M(X[he],ie)}),Ee;default:return X}}},120:(Ot,Me,S)=>{function i(){for(var e=[],M=0;M<arguments.length;M++)e[M]=arguments[M];var X=Object.create(null);return e.forEach(function(ie){ie&&Object.keys(ie).forEach(function(Q){var Ee=ie[Q];void 0!==Ee&&(X[Q]=Ee)})}),X}S.d(Me,{o:()=>i})},9977:(Ot,Me,S)=>{S.d(Me,{v:()=>e});var i=new Map;function e(M){var X=i.get(M)||1;return i.set(M,X+1),"".concat(M,":").concat(X,":").concat(Math.random().toString(36).slice(2))}},1115:(Ot,Me,S)=>{S.d(Me,{D9:()=>X,IM:()=>ie,ZI:()=>Ee});var i=S(3844),e=S(1181),M=Object.prototype.hasOwnProperty;function X(){for(var he=[],q=0;q<arguments.length;q++)he[q]=arguments[q];return ie(he)}function ie(he){var q=he[0]||{},oe=he.length;if(oe>1)for(var Z=new Ee,ce=1;ce<oe;++ce)q=Z.merge(q,he[ce]);return q}var Q=function(he,q,oe){return this.merge(he[oe],q[oe])},Ee=function(){function he(q){void 0===q&&(q=Q),this.reconciler=q,this.isObject=e.U,this.pastCopies=new Set}return he.prototype.merge=function(q,oe){for(var Z=this,ce=[],le=2;le<arguments.length;le++)ce[le-2]=arguments[le];return(0,e.U)(oe)&&(0,e.U)(q)?(Object.keys(oe).forEach(function(je){if(M.call(q,je)){var Et=q[je];if(oe[je]!==Et){var wt=Z.reconciler.apply(Z,(0,i.fX)([q,oe,je],ce,!1));wt!==Et&&((q=Z.shallowCopyForMerge(q))[je]=wt)}}else(q=Z.shallowCopyForMerge(q))[je]=oe[je]}),q):oe},he.prototype.shallowCopyForMerge=function(q){return(0,e.U)(q)&&(this.pastCopies.has(q)||(q=Array.isArray(q)?q.slice(0):(0,i.Cl)({__proto__:Object.getPrototypeOf(q)},q),this.pastCopies.add(q))),q},he}()},1181:(Ot,Me,S)=>{function i(M){return null!==M&&"object"==typeof M}S.d(Me,{U:()=>i})},1687:(Ot,Me,S)=>{S.d(Me,{p:()=>e});var i=S(9977);function e(M,X){void 0===X&&(X=0);var ie=(0,i.v)("stringifyForDisplay");return JSON.stringify(M,function(Q,Ee){return void 0===Ee?ie:Ee},X).split(JSON.stringify(ie)).join("<undefined>")}},2455:(Ot,Me,S)=>{S.d(Me,{Sf:()=>cr,V1:()=>Xr,no:()=>Yn,vA:()=>Ur});var i=function(yt,hn){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Gt,Gn){Gt.__proto__=Gn}||function(Gt,Gn){for(var ri in Gn)Object.prototype.hasOwnProperty.call(Gn,ri)&&(Gt[ri]=Gn[ri])})(yt,hn)};"function"==typeof SuppressedError&&SuppressedError;var St="Invariant Violation",qt=Object.setPrototypeOf,Ht=void 0===qt?function(yt,hn){return yt.__proto__=hn,yt}:qt,on=function(yt){function hn(Gt){void 0===Gt&&(Gt=St);var Gn=yt.call(this,"number"==typeof Gt?St+": "+Gt+" (see https://github.com/apollographql/invariant-packages)":Gt)||this;return Gn.framesToPop=1,Gn.name=St,Ht(Gn,hn.prototype),Gn}return function e(yt,hn){if("function"!=typeof hn&&null!==hn)throw new TypeError("Class extends value "+String(hn)+" is not a constructor or null");function Gt(){this.constructor=yt}i(yt,hn),yt.prototype=null===hn?Object.create(hn):(Gt.prototype=hn.prototype,new Gt)}(hn,yt),hn}(Error);function Cn(yt,hn){if(!yt)throw new on(hn)}var yt,tn=["debug","log","warn","error","silent"],fi=tn.indexOf("log");function Zn(yt){return function(){if(tn.indexOf(yt)>=fi)return(console[yt]||console.log).apply(console,arguments)}}(yt=Cn||(Cn={})).debug=Zn("debug"),yt.log=Zn("log"),yt.warn=Zn("warn"),yt.error=Zn("error");var Nn=S(560);function Yn(yt){try{return yt()}catch{}}const cr=Yn(function(){return globalThis})||Yn(function(){return window})||Yn(function(){return self})||Yn(function(){return global})||Yn(function(){return Yn.constructor("return this")()});var Ai=S(1687);function Qi(yt){return function(hn){for(var Gt=[],Gn=1;Gn<arguments.length;Gn++)Gt[Gn-1]=arguments[Gn];if("number"==typeof hn){var ri=hn;(hn=uo(ri))||(hn=mi(ri,Gt),Gt=[])}yt.apply(void 0,[hn].concat(Gt))}}var Xr=Object.assign(function(hn,Gt){for(var Gn=[],ri=2;ri<arguments.length;ri++)Gn[ri-2]=arguments[ri];hn||Cn(hn,uo(Gt,Gn)||mi(Gt,Gn))},{debug:Qi(Cn.debug),log:Qi(Cn.log),warn:Qi(Cn.warn),error:Qi(Cn.error)});function Ur(yt){for(var hn=[],Gt=1;Gt<arguments.length;Gt++)hn[Gt-1]=arguments[Gt];return new on(uo(yt,hn)||mi(yt,hn))}var eo=Symbol.for("ApolloErrorMessageHandler_"+Nn.r);function as(yt){if("string"==typeof yt)return yt;try{return(0,Ai.p)(yt,2).slice(0,1e3)}catch{return"<non-serializable>"}}function uo(yt,hn){if(void 0===hn&&(hn=[]),yt)return cr[eo]&&cr[eo](yt,hn.map(as))}function mi(yt,hn){if(void 0===hn&&(hn=[]),yt)return"An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({version:Nn.r,message:yt,args:hn.map(as)})))}globalThis},8926:(Ot,Me,S)=>{S.d(Me,{c:()=>q});var i=S(4420),e=S(6500),M=S(4229),X=S(2455),ie=S(9055),Q=S(7773),Ee=S(2151);function he(oe){return oe}var q=function(){function oe(Z,ce){void 0===ce&&(ce=Object.create(null)),this.resultCache=e.En?new WeakSet:new Set,this.transform=Z,ce.getCacheKey&&(this.getCacheKey=ce.getCacheKey),this.cached=!1!==ce.cache,this.resetCache()}return oe.prototype.getCacheKey=function(Z){return[Z]},oe.identity=function(){return new oe(he,{cache:!1})},oe.split=function(Z,ce,le){return void 0===le&&(le=oe.identity()),Object.assign(new oe(function(je){return(Z(je)?ce:le).transformDocument(je)},{cache:!1}),{left:ce,right:le})},oe.prototype.resetCache=function(){var Z=this;if(this.cached){var ce=new i.b(e.et);this.performWork=(0,Q.LV)(oe.prototype.performWork.bind(this),{makeCacheKey:function(le){var je=Z.getCacheKey(le);if(je)return(0,X.V1)(Array.isArray(je),69),ce.lookupArray(je)},max:Ee.v["documentTransform.cache"],cache:ie.l})}},oe.prototype.performWork=function(Z){return(0,M.sw)(Z),this.transform(Z)},oe.prototype.transformDocument=function(Z){if(this.resultCache.has(Z))return Z;var ce=this.performWork(Z);return this.resultCache.add(ce),ce},oe.prototype.concat=function(Z){var ce=this;return Object.assign(new oe(function(le){return Z.transformDocument(ce.transformDocument(le))},{cache:!1}),{left:this,right:Z})},oe}()},4183:(Ot,Me,S)=>{S.d(Me,{MS:()=>M,d8:()=>Ee,f2:()=>he});var i=S(2455),e=S(4335);function M(Z,ce){var le=Z.directives;return!le||!le.length||function oe(Z){var ce=[];return Z&&Z.length&&Z.forEach(function(le){if(function q(Z){var ce=Z.name.value;return"skip"===ce||"include"===ce}(le)){var je=le.arguments,Et=le.name.value;(0,i.V1)(je&&1===je.length,71,Et);var wt=je[0];(0,i.V1)(wt.name&&"if"===wt.name.value,72,Et);var ve=wt.value;(0,i.V1)(ve&&("Variable"===ve.kind||"BooleanValue"===ve.kind),73,Et),ce.push({directive:le,ifArgument:wt})}}),ce}(le).every(function(je){var Et=je.directive,wt=je.ifArgument,ve=!1;return"Variable"===wt.value.kind?(0,i.V1)(void 0!==(ve=ce&&ce[wt.value.name.value]),70,Et.name.value):ve=wt.value.value,"skip"===Et.name.value?!ve:ve})}function Ee(Z,ce,le){var je=new Set(Z),Et=je.size;return(0,e.visit)(ce,{Directive:function(wt){if(je.delete(wt.name.value)&&(!le||!je.size))return e.BREAK}}),le?!je.size:je.size<Et}function he(Z){return Z&&Ee(["client","export"],Z,!0)}},6108:(Ot,Me,S)=>{S.d(Me,{HQ:()=>X,JG:()=>M});var i=S(2455);function M(ie){void 0===ie&&(ie=[]);var Q={};return ie.forEach(function(Ee){Q[Ee.name.value]=Ee}),Q}function X(ie,Q){switch(ie.kind){case"InlineFragment":return ie;case"FragmentSpread":var Ee=ie.name.value;if("function"==typeof Q)return Q(Ee);var he=Q&&Q[Ee];return(0,i.V1)(he,76,Ee),he||null;default:return null}}},4229:(Ot,Me,S)=>{S.d(Me,{AT:()=>Ee,E4:()=>he,Vn:()=>q,Vu:()=>X,n4:()=>ie,sw:()=>M,wY:()=>oe,zK:()=>Q});var i=S(2455),e=S(1367);function M(Z){(0,i.V1)(Z&&"Document"===Z.kind,77);var ce=Z.definitions.filter(function(le){return"FragmentDefinition"!==le.kind}).map(function(le){if("OperationDefinition"!==le.kind)throw(0,i.vA)(78,le.kind);return le});return(0,i.V1)(ce.length<=1,79,ce.length),Z}function X(Z){return M(Z),Z.definitions.filter(function(ce){return"OperationDefinition"===ce.kind})[0]}function ie(Z){return Z.definitions.filter(function(ce){return"OperationDefinition"===ce.kind&&!!ce.name}).map(function(ce){return ce.name.value})[0]||null}function Q(Z){return Z.definitions.filter(function(ce){return"FragmentDefinition"===ce.kind})}function Ee(Z){var ce=X(Z);return(0,i.V1)(ce&&"query"===ce.operation,80),ce}function he(Z){(0,i.V1)("Document"===Z.kind,81),(0,i.V1)(Z.definitions.length<=1,82);var ce=Z.definitions[0];return(0,i.V1)("FragmentDefinition"===ce.kind,83),ce}function q(Z){M(Z);for(var ce,le=0,je=Z.definitions;le<je.length;le++){var Et=je[le];if("OperationDefinition"===Et.kind){var wt=Et.operation;if("query"===wt||"mutation"===wt||"subscription"===wt)return Et}"FragmentDefinition"===Et.kind&&!ce&&(ce=Et)}if(ce)return ce;throw(0,i.vA)(84)}function oe(Z){var ce=Object.create(null),le=Z&&Z.variableDefinitions;return le&&le.length&&le.forEach(function(je){je.defaultValue&&(0,e.J)(ce,je.variable.name,je.defaultValue)}),ce}},1658:(Ot,Me,S)=>{S.d(Me,{y:()=>Q});var ie,i=S(4335),e=S(2170),M=S(2151),X=S(8782),Q=Object.assign(function(Ee){var he=ie.get(Ee);return he||(he=(0,i.print)(Ee),ie.set(Ee,he)),he},{reset:function(){ie=new e.A(M.v.print||2e3)}});Q.reset(),!1!==globalThis.__DEV__&&(0,X.D_)("print",function(){return ie?ie.size:0})},1367:(Ot,Me,S)=>{S.d(Me,{J:()=>wt,Kc:()=>Q,MB:()=>an,dt:()=>Pt,kd:()=>Ae,ue:()=>un});var i=S(2455),e=S(1181),M=S(2130);function Q(dt){return(0,e.U)(dt)&&"Document"===dt.kind&&Array.isArray(dt.definitions)}function wt(dt,ut,Mt,Wt){if(function q(dt){return"IntValue"===dt.kind}(Mt)||function oe(dt){return"FloatValue"===dt.kind}(Mt))dt[ut.value]=Number(Mt.value);else if(function he(dt){return"BooleanValue"===dt.kind}(Mt)||function Ee(dt){return"StringValue"===dt.kind}(Mt))dt[ut.value]=Mt.value;else if(function ce(dt){return"ObjectValue"===dt.kind}(Mt)){var It={};Mt.fields.map(function(pn){return wt(It,pn.name,pn.value,Wt)}),dt[ut.value]=It}else if(function Z(dt){return"Variable"===dt.kind}(Mt))dt[ut.value]=(Wt||{})[Mt.name.value];else if(function le(dt){return"ListValue"===dt.kind}(Mt))dt[ut.value]=Mt.values.map(function(pn){var Wn={};return wt(Wn,ut,pn,Wt),Wn[ut.value]});else if(function je(dt){return"EnumValue"===dt.kind}(Mt))dt[ut.value]=Mt.value;else{if(!function Et(dt){return"NullValue"===dt.kind}(Mt))throw(0,i.vA)(85,ut.value,Mt.kind);dt[ut.value]=null}}var fn=["connection","include","skip","client","rest","export","nonreactive"],ct=M.M;function an(dt,ut){if(dt.arguments&&dt.arguments.length){var Mt={};return dt.arguments.forEach(function(Wt){return wt(Mt,Wt.name,Wt.value,ut)}),Mt}return null}function un(dt){return dt.alias?dt.alias.value:dt.name.value}function Pt(dt){return"Field"===dt.kind}function Ae(dt){return"InlineFragment"===dt.kind}Object.assign(function(dt,ut,Mt){if(ut&&Mt&&Mt.connection&&Mt.connection.key){if(Mt.connection.filter&&Mt.connection.filter.length>0){var Wt=Mt.connection.filter?Mt.connection.filter:[];Wt.sort();var It={};return Wt.forEach(function(Wn){It[Wn]=ut[Wn]}),"".concat(Mt.connection.key,"(").concat(ct(It),")")}return Mt.connection.key}var Vn=dt;if(ut){var pn=ct(ut);Vn+="(".concat(pn,")")}return Mt&&Object.keys(Mt).forEach(function(Wn){-1===fn.indexOf(Wn)&&(Mt[Wn]&&Object.keys(Mt[Wn]).length?Vn+="@".concat(Wn,"(").concat(ct(Mt[Wn]),")"):Vn+="@".concat(Wn))}),Vn},{setStringify:function(dt){var ut=ct;return ct=dt,ut}})},1601:(Ot,Me,S)=>{S.d(Me,{er:()=>vn,iz:()=>le,zc:()=>un});var i=S(3844),e=S(2455),M=S(4335),X=S(4229),ie=S(1367),Q=S(6108),Ee=S(7715),he={kind:M.Kind.FIELD,name:{kind:M.Kind.NAME,value:"__typename"}};function q(Pt,Ae){return!Pt||Pt.selectionSet.selections.every(function(dt){return dt.kind===M.Kind.FRAGMENT_SPREAD&&q(Ae[dt.name.value],Ae)})}function oe(Pt){return q((0,X.Vu)(Pt)||(0,X.E4)(Pt),(0,Q.JG)((0,X.zK)(Pt)))?null:Pt}function ce(Pt){var Ae=new Map;return function(ut){void 0===ut&&(ut=Pt);var Mt=Ae.get(ut);return Mt||Ae.set(ut,Mt={variables:new Set,fragmentSpreads:new Set}),Mt}}function le(Pt,Ae){(0,X.sw)(Ae);for(var dt=ce(""),ut=ce(""),Mt=function(tn){for(var fi=0,Zn=void 0;fi<tn.length&&(Zn=tn[fi]);++fi)if(!(0,Ee.c)(Zn)){if(Zn.kind===M.Kind.OPERATION_DEFINITION)return dt(Zn.name&&Zn.name.value);if(Zn.kind===M.Kind.FRAGMENT_DEFINITION)return ut(Zn.name.value)}return!1!==globalThis.__DEV__&&e.V1.error(86),null},Wt=0,It=Ae.definitions.length-1;It>=0;--It)Ae.definitions[It].kind===M.Kind.OPERATION_DEFINITION&&++Wt;var Vn=function Z(Pt){var Ae=new Map,dt=new Map;return Pt.forEach(function(ut){ut&&(ut.name?Ae.set(ut.name,ut):ut.test&&dt.set(ut.test,ut))}),function(ut){var Mt=Ae.get(ut.name.value);return!Mt&&dt.size&&dt.forEach(function(Wt,It){It(ut)&&(Mt=Wt)}),Mt}}(Pt),pn=function(tn){return(0,Ee.E)(tn)&&tn.map(Vn).some(function(fi){return fi&&fi.remove})},Wn=new Map,ji=!1,An={enter:function(tn){if(pn(tn.directives))return ji=!0,null}},St=(0,M.visit)(Ae,{Field:An,InlineFragment:An,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(tn,fi,Zn,Dn,gn){var Nn=Mt(gn);Nn&&Nn.variables.add(tn.name.value)}},FragmentSpread:{enter:function(tn,fi,Zn,Dn,gn){if(pn(tn.directives))return ji=!0,null;var Nn=Mt(gn);Nn&&Nn.fragmentSpreads.add(tn.name.value)}},FragmentDefinition:{enter:function(tn,fi,Zn,Dn){Wn.set(JSON.stringify(Dn),tn)},leave:function(tn,fi,Zn,Dn){return tn===Wn.get(JSON.stringify(Dn))?tn:Wt>0&&tn.selectionSet.selections.every(function(Nn){return Nn.kind===M.Kind.FIELD&&"__typename"===Nn.name.value})?(ut(tn.name.value).removed=!0,ji=!0,null):void 0}},Directive:{leave:function(tn){if(Vn(tn))return ji=!0,null}}});if(!ji)return Ae;var qt=function(tn){return tn.transitiveVars||(tn.transitiveVars=new Set(tn.variables),tn.removed||tn.fragmentSpreads.forEach(function(fi){qt(ut(fi)).transitiveVars.forEach(function(Zn){tn.transitiveVars.add(Zn)})})),tn},Ht=new Set;St.definitions.forEach(function(tn){tn.kind===M.Kind.OPERATION_DEFINITION?qt(dt(tn.name&&tn.name.value)).fragmentSpreads.forEach(function(fi){Ht.add(fi)}):tn.kind===M.Kind.FRAGMENT_DEFINITION&&0===Wt&&!ut(tn.name.value).removed&&Ht.add(tn.name.value)}),Ht.forEach(function(tn){qt(ut(tn)).fragmentSpreads.forEach(function(fi){Ht.add(fi)})});var Cn={enter:function(tn){if(function(tn){return!(Ht.has(tn)&&!ut(tn).removed)}(tn.name.value))return null}};return oe((0,M.visit)(St,{FragmentSpread:Cn,FragmentDefinition:Cn,OperationDefinition:{leave:function(tn){if(tn.variableDefinitions){var fi=qt(dt(tn.name&&tn.name.value)).transitiveVars;if(fi.size<tn.variableDefinitions.length)return(0,i.Cl)((0,i.Cl)({},tn),{variableDefinitions:tn.variableDefinitions.filter(function(Zn){return fi.has(Zn.variable.name.value)})})}}}}))}function un(Pt){return"query"===(0,X.Vn)(Pt).operation?Pt:(0,M.visit)(Pt,{OperationDefinition:{enter:function(Mt){return(0,i.Cl)((0,i.Cl)({},Mt),{operation:"query"})}}})}function vn(Pt){return(0,X.sw)(Pt),le([{test:function(dt){return"client"===dt.name.value},remove:!0}],Pt)}Object.assign(function(Pt){return(0,M.visit)(Pt,{SelectionSet:{enter:function(Ae,dt,ut){if(!ut||ut.kind!==M.Kind.OPERATION_DEFINITION){var Mt=Ae.selections;if(Mt&&!Mt.some(function(Vn){return(0,ie.dt)(Vn)&&("__typename"===Vn.name.value||0===Vn.name.value.lastIndexOf("__",0))})){var It=ut;if(!((0,ie.dt)(It)&&It.directives&&It.directives.some(function(Vn){return"export"===Vn.name.value})))return(0,i.Cl)((0,i.Cl)({},Ae),{selections:(0,i.fX)((0,i.fX)([],Mt,!0),[he],!1)})}}}}})},{added:function(Pt){return Pt===he}})},560:(Ot,Me,S)=>{S.d(Me,{r:()=>i});var i="3.11.8"},6605:(Ot,Me,S)=>{S.r(Me),S.d(Me,{ModalDismissReasons:()=>op,NgbAccordionBody:()=>es,NgbAccordionButton:()=>wo,NgbAccordionCollapse:()=>Ma,NgbAccordionConfig:()=>jt,NgbAccordionDirective:()=>sl,NgbAccordionHeader:()=>ea,NgbAccordionItem:()=>ga,NgbAccordionModule:()=>Ia,NgbAccordionToggle:()=>ts,NgbActiveModal:()=>au,NgbActiveOffcanvas:()=>Jc,NgbAlert:()=>wa,NgbAlertConfig:()=>al,NgbAlertModule:()=>Sl,NgbCalendar:()=>Ql,NgbCalendarBuddhist:()=>vs,NgbCalendarEthiopian:()=>Y,NgbCalendarGregorian:()=>sc,NgbCalendarHebrew:()=>tt,NgbCalendarIslamicCivil:()=>aa,NgbCalendarIslamicUmalqura:()=>Su,NgbCalendarPersian:()=>Vu,NgbCarousel:()=>Il,NgbCarouselConfig:()=>qc,NgbCarouselModule:()=>Rl,NgbCollapse:()=>ds,NgbCollapseConfig:()=>Js,NgbCollapseModule:()=>yl,NgbConfig:()=>ko,NgbDate:()=>sa,NgbDateAdapter:()=>vi,NgbDateNativeAdapter:()=>Ze,NgbDateNativeUTCAdapter:()=>kt,NgbDateParserFormatter:()=>Za,NgbDateStructAdapter:()=>Ci,NgbDatepicker:()=>zr,NgbDatepickerConfig:()=>kn,NgbDatepickerContent:()=>so,NgbDatepickerI18n:()=>re,NgbDatepickerI18nAmharic:()=>Ie,NgbDatepickerI18nDefault:()=>Ge,NgbDatepickerI18nHebrew:()=>or,NgbDatepickerKeyboardService:()=>Xi,NgbDatepickerModule:()=>Si,NgbDatepickerMonth:()=>Fr,NgbDropdown:()=>dc,NgbDropdownAnchor:()=>Zo,NgbDropdownButtonItem:()=>rs,NgbDropdownConfig:()=>oi,NgbDropdownItem:()=>Yr,NgbDropdownMenu:()=>ls,NgbDropdownModule:()=>Vc,NgbDropdownToggle:()=>Hl,NgbHighlight:()=>Jp,NgbInputDatepicker:()=>ou,NgbInputDatepickerConfig:()=>ac,NgbModal:()=>Yh,NgbModalConfig:()=>Wo,NgbModalModule:()=>yg,NgbModalRef:()=>wv,NgbModule:()=>th,NgbNav:()=>Zc,NgbNavConfig:()=>Qd,NgbNavContent:()=>mf,NgbNavItem:()=>Ch,NgbNavItemRole:()=>U_,NgbNavLink:()=>C0,NgbNavLinkBase:()=>Tu,NgbNavLinkButton:()=>If,NgbNavModule:()=>Cg,NgbNavOutlet:()=>D0,NgbNavPane:()=>Dh,NgbOffcanvas:()=>Gl,NgbOffcanvasConfig:()=>Ja,NgbOffcanvasModule:()=>zu,NgbOffcanvasRef:()=>sd,NgbPagination:()=>Ev,NgbPaginationConfig:()=>Sv,NgbPaginationEllipsis:()=>Am,NgbPaginationFirst:()=>ja,NgbPaginationLast:()=>xs,NgbPaginationModule:()=>Ep,NgbPaginationNext:()=>rd,NgbPaginationNumber:()=>Yd,NgbPaginationPages:()=>Xd,NgbPaginationPrevious:()=>Qu,NgbPopover:()=>zl,NgbPopoverConfig:()=>wh,NgbPopoverModule:()=>Tp,NgbProgressbar:()=>Zd,NgbProgressbarConfig:()=>Mp,NgbProgressbarModule:()=>ap,NgbProgressbarStacked:()=>Fm,NgbRating:()=>_d,NgbRatingConfig:()=>Af,NgbRatingModule:()=>Mu,NgbScrollSpy:()=>Tv,NgbScrollSpyConfig:()=>ns,NgbScrollSpyFragment:()=>Md,NgbScrollSpyItem:()=>Zp,NgbScrollSpyMenu:()=>xh,NgbScrollSpyModule:()=>Of,NgbScrollSpyService:()=>gf,NgbSlide:()=>ca,NgbSlideEventDirection:()=>la,NgbSlideEventSource:()=>Xa,NgbTimeAdapter:()=>Ip,NgbTimepicker:()=>tD,NgbTimepickerConfig:()=>w0,NgbTimepickerI18n:()=>Xh,NgbTimepickerModule:()=>Iv,NgbToast:()=>yd,NgbToastConfig:()=>mu,NgbToastHeader:()=>Ff,NgbToastModule:()=>Rm,NgbTooltip:()=>km,NgbTooltipConfig:()=>Lm,NgbTooltipModule:()=>Nf,NgbTypeahead:()=>ra,NgbTypeaheadConfig:()=>fc,NgbTypeaheadModule:()=>Rf,OffcanvasDismissReasons:()=>Ss});var i=S(1270),e=S(1647),M=S(9335);function X(V){V||((0,i.assertInInjectionContext)(X),V=(0,i.inject)(i.DestroyRef));const Qe=new e.Observable(E=>V.onDestroy(E.next.bind(E)));return E=>E.pipe((0,M.takeUntil)(Qe))}var Z=S(2168),ce=S(1738),le=S(6304);const je=["*"];function Et(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",1),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.close())}),i.\u0275\u0275elementEnd()}}function wt(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",7),i.\u0275\u0275listener("click",function(){const ee=i.\u0275\u0275restoreView(E).$implicit,Xe=i.\u0275\u0275nextContext();return Xe.focus(),i.\u0275\u0275resetView(Xe.select(ee.id,Xe.NgbSlideEventSource.INDICATOR))}),i.\u0275\u0275elementEnd()}if(2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("active",E.id===U.activeId),i.\u0275\u0275attribute("aria-labelledby","slide-"+E.id)("aria-controls","slide-"+E.id)("aria-selected",E.id===U.activeId)}}function ve(V,Qe){}function fn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",6)(1,"span",8),i.\u0275\u0275i18n(2,0),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,ve,0,0,"ng-template",9),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit,U=Qe.$index,ee=Qe.$count;i.\u0275\u0275property("id","slide-"+E.id),i.\u0275\u0275advance(2),i.\u0275\u0275i18nExp(U+1)(ee),i.\u0275\u0275i18nApply(2),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",E.templateRef)}}function ct(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",10),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.arrowLeft())}),i.\u0275\u0275element(1,"span",11),i.\u0275\u0275elementStart(2,"span",12),i.\u0275\u0275i18n(3,1),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"button",13),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.arrowRight())}),i.\u0275\u0275element(5,"span",14),i.\u0275\u0275elementStart(6,"span",12),i.\u0275\u0275i18n(7,2),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("aria-labelledby",E.id+"-previous"),i.\u0275\u0275advance(2),i.\u0275\u0275property("id",E.id+"-previous"),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("aria-labelledby",E.id+"-next"),i.\u0275\u0275advance(2),i.\u0275\u0275property("id",E.id+"-next")}}const en=["ngbDatepickerDayView",""],an=["month"],un=["year"];function vn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"option",3),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275property("value",E),i.\u0275\u0275attribute("aria-label",U.i18n.getMonthFullName(E,U.date.year)),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(U.i18n.getMonthShortName(E,U.date.year))}}function Pt(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"option",3),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275property("value",E),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(U.i18n.getYearNumerals(E))}}function Ae(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"ngb-datepicker-navigation-select",6),i.\u0275\u0275listener("select",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.select.emit(ee))}),i.\u0275\u0275elementEnd()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275property("date",E.date)("disabled",E.disabled)("months",E.selectBoxes.months)("years",E.selectBoxes.years)}}function dt(V,Qe){1&V&&i.\u0275\u0275element(0,"div",7)}function ut(V,Qe){1&V&&i.\u0275\u0275element(0,"div",7)}function Mt(V,Qe){if(1&V&&(i.\u0275\u0275template(0,dt,1,0,"div",7),i.\u0275\u0275elementStart(1,"div",8),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,ut,1,0,"div",7)),2&V){const E=Qe.$implicit,U=Qe.$index,ee=i.\u0275\u0275nextContext(2);i.\u0275\u0275conditional(U>0?0:-1),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",ee.i18n.getMonthLabel(E.firstDate)," "),i.\u0275\u0275advance(),i.\u0275\u0275conditional(U!==ee.months.length-1?3:-1)}}function Wt(V,Qe){if(1&V&&i.\u0275\u0275repeaterCreate(0,Mt,4,3,null,null,i.\u0275\u0275repeaterTrackByIdentity),2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275repeater(E.months)}}function It(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",1),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E.i18n.getWeekLabel())}}function Vn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",2),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit;i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E)}}function pn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",0),i.\u0275\u0275template(1,It,2,1,"div",1),i.\u0275\u0275repeaterCreate(2,Vn,2,1,"div",2,i.\u0275\u0275repeaterTrackByIndex),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275conditional(E.datepicker.showWeekNumbers?1:-1),i.\u0275\u0275advance(),i.\u0275\u0275repeater(E.viewModel.weekdays)}}function Wn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",4),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext(2).$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(U.i18n.getWeekNumerals(E.number))}}function ji(V,Qe){}function An(V,Qe){if(1&V&&i.\u0275\u0275template(0,ji,0,0,"ng-template",7),2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext(3);i.\u0275\u0275property("ngTemplateOutlet",U.datepicker.dayTemplate)("ngTemplateOutletContext",E.context)}}function St(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"div",6),i.\u0275\u0275listener("click",function(ee){const Xe=i.\u0275\u0275restoreView(E).$implicit;return i.\u0275\u0275nextContext(3).doSelect(Xe),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(1,An,1,2,null,7),i.\u0275\u0275elementEnd()}if(2&V){const E=Qe.$implicit;i.\u0275\u0275classProp("disabled",E.context.disabled)("hidden",E.hidden)("ngb-dp-today",E.context.today),i.\u0275\u0275property("tabindex",E.tabindex),i.\u0275\u0275attribute("aria-label",E.ariaLabel),i.\u0275\u0275advance(),i.\u0275\u0275conditional(E.hidden?-1:1)}}function qt(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",3),i.\u0275\u0275template(1,Wn,2,1,"div",4),i.\u0275\u0275repeaterCreate(2,St,2,9,"div",5,i.\u0275\u0275repeaterTrackByIdentity),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275conditional(U.datepicker.showWeekNumbers?1:-1),i.\u0275\u0275advance(),i.\u0275\u0275repeater(E.days)}}function Ht(V,Qe){1&V&&i.\u0275\u0275template(0,qt,4,1,"div",3),2&V&&i.\u0275\u0275conditional(Qe.$implicit.collapsed?-1:0)}const on=["defaultDayTemplate"],Cn=["content"],tn=V=>({$implicit:V});function fi(V,Qe){if(1&V&&i.\u0275\u0275element(0,"div",8),2&V){const U=Qe.currentMonth,ee=Qe.selected,Xe=Qe.disabled,Nt=Qe.focused;i.\u0275\u0275property("date",Qe.date)("currentMonth",U)("selected",ee)("disabled",Xe)("focused",Nt)}}function Zn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",10),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",U.i18n.getMonthLabel(E.firstDate)," ")}}function Dn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",9),i.\u0275\u0275template(1,Zn,2,1,"div",10),i.\u0275\u0275element(2,"ngb-datepicker-month",11),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275conditional("none"===U.navigation||U.displayMonths>1&&"select"===U.navigation?1:-1),i.\u0275\u0275advance(),i.\u0275\u0275property("month",E.firstDate)}}function gn(V,Qe){if(1&V&&i.\u0275\u0275repeaterCreate(0,Dn,3,2,"div",9,i.\u0275\u0275repeaterTrackByIdentity),2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275repeater(E.model.months)}}function Nn(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"ngb-datepicker-navigation",12),i.\u0275\u0275listener("navigate",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.onNavigateEvent(ee))})("select",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.onNavigateDateSelect(ee))}),i.\u0275\u0275elementEnd()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275property("date",E.model.firstDate)("months",E.model.months)("disabled",E.model.disabled)("showSelect","select"===E.model.navigation)("prevDisabled",E.model.prevDisabled)("nextDisabled",E.model.nextDisabled)("selectBoxes",E.model.selectBoxes)}}function Yn(V,Qe){}function cr(V,Qe){}const Ai=["dialog"],Qi=["ngbNavOutlet",""];function Xr(V,Qe){}function Ur(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"div",0),i.\u0275\u0275template(1,Xr,0,0,"ng-template",1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275property("item",E)("nav",U.nav)("role",U.paneRole),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==E.contentTpl?null:E.contentTpl.templateRef)||null)("ngTemplateOutletContext",i.\u0275\u0275pureFunction1(5,tn,E.active||U.isPanelTransitioning(E)))}}function eo(V,Qe){if(1&V&&i.\u0275\u0275template(0,Ur,2,7,"div",0),2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275conditional(E.isPanelInDom()||U.isPanelTransitioning(E)?0:-1)}}const as=(V,Qe,E)=>({$implicit:V,pages:Qe,disabled:E}),uo=V=>({disabled:!0,currentPage:V}),mi=(V,Qe,E)=>({disabled:V,$implicit:Qe,currentPage:E}),ci=(V,Qe)=>({disabled:V,currentPage:Qe}),yt=V=>({disabled:V});function hn(V,Qe){1&V&&(i.\u0275\u0275elementStart(0,"span",13),i.\u0275\u0275i18n(1,7),i.\u0275\u0275elementEnd())}function Gt(V,Qe){1&V&&(i.\u0275\u0275elementStart(0,"span",13),i.\u0275\u0275i18n(1,8),i.\u0275\u0275elementEnd())}function Gn(V,Qe){1&V&&(i.\u0275\u0275elementStart(0,"span",13),i.\u0275\u0275i18n(1,9),i.\u0275\u0275elementEnd())}function ri(V,Qe){1&V&&(i.\u0275\u0275elementStart(0,"span",13),i.\u0275\u0275i18n(1,10),i.\u0275\u0275elementEnd())}function pi(V,Qe){1&V&&i.\u0275\u0275text(0,"...")}function At(V,Qe){1&V&&i.\u0275\u0275text(0),2&V&&i.\u0275\u0275textInterpolate(Qe.$implicit)}function Bn(V,Qe){}function Mn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"a",16),i.\u0275\u0275template(1,Bn,0,0,"ng-template",12),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext(2).$implicit,U=i.\u0275\u0275nextContext(),ee=i.\u0275\u0275reference(9);i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==U.tplEllipsis?null:U.tplEllipsis.templateRef)||ee)("ngTemplateOutletContext",i.\u0275\u0275pureFunction1(2,uo,E))}}function ni(V,Qe){}function qn(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"a",18),i.\u0275\u0275listener("click",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext().$implicit;return i.\u0275\u0275nextContext(2).selectPage(Xe),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(1,ni,0,0,"ng-template",12),i.\u0275\u0275elementEnd()}if(2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext(),ee=U.$implicit,Xe=U.disabled,Nt=i.\u0275\u0275nextContext(),Ei=i.\u0275\u0275reference(11);i.\u0275\u0275attribute("tabindex",Xe?"-1":null)("aria-disabled",Xe?"true":null),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==Nt.tplNumber?null:Nt.tplNumber.templateRef)||Ei)("ngTemplateOutletContext",i.\u0275\u0275pureFunction3(4,mi,Xe,E,ee))}}function Ti(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"li",15),i.\u0275\u0275template(1,Mn,2,4,"a",16)(2,qn,2,8,"a",17),i.\u0275\u0275elementEnd()),2&V){const E=Qe.$implicit,U=i.\u0275\u0275nextContext(),ee=U.$implicit,Xe=U.disabled,Nt=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("active",E===ee)("disabled",Nt.isEllipsis(E)||Xe),i.\u0275\u0275attribute("aria-current",E===ee?"page":null),i.\u0275\u0275advance(),i.\u0275\u0275conditional(Nt.isEllipsis(E)?1:2)}}function Bi(V,Qe){1&V&&i.\u0275\u0275repeaterCreate(0,Ti,3,6,"li",14,i.\u0275\u0275repeaterTrackByIndex),2&V&&i.\u0275\u0275repeater(Qe.pages)}function Gi(V,Qe){}function Ii(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"li",15)(1,"a",19),i.\u0275\u0275listener("click",function(ee){return i.\u0275\u0275restoreView(E),i.\u0275\u0275nextContext().selectPage(1),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(2,Gi,0,0,"ng-template",12),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(),U=i.\u0275\u0275reference(1);i.\u0275\u0275classProp("disabled",E.previousDisabled()),i.\u0275\u0275advance(),i.\u0275\u0275attribute("tabindex",E.previousDisabled()?"-1":null)("aria-disabled",E.previousDisabled()?"true":null),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==E.tplFirst?null:E.tplFirst.templateRef)||U)("ngTemplateOutletContext",i.\u0275\u0275pureFunction2(6,ci,E.previousDisabled(),E.page))}}function Ki(V,Qe){}function Jt(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"li",15)(1,"a",20),i.\u0275\u0275listener("click",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return Xe.selectPage(Xe.page-1),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(2,Ki,0,0,"ng-template",12),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(),U=i.\u0275\u0275reference(3);i.\u0275\u0275classProp("disabled",E.previousDisabled()),i.\u0275\u0275advance(),i.\u0275\u0275attribute("tabindex",E.previousDisabled()?"-1":null)("aria-disabled",E.previousDisabled()?"true":null),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==E.tplPrevious?null:E.tplPrevious.templateRef)||U)("ngTemplateOutletContext",i.\u0275\u0275pureFunction1(6,yt,E.previousDisabled()))}}function hi(V,Qe){}function Ft(V,Qe){}function it(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"li",15)(1,"a",21),i.\u0275\u0275listener("click",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return Xe.selectPage(Xe.page+1),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(2,Ft,0,0,"ng-template",12),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(),U=i.\u0275\u0275reference(5);i.\u0275\u0275classProp("disabled",E.nextDisabled()),i.\u0275\u0275advance(),i.\u0275\u0275attribute("tabindex",E.nextDisabled()?"-1":null)("aria-disabled",E.nextDisabled()?"true":null),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==E.tplNext?null:E.tplNext.templateRef)||U)("ngTemplateOutletContext",i.\u0275\u0275pureFunction2(6,ci,E.nextDisabled(),E.page))}}function sn(V,Qe){}function Ve(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"li",15)(1,"a",22),i.\u0275\u0275listener("click",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return Xe.selectPage(Xe.pageCount),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275template(2,sn,0,0,"ng-template",12),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(),U=i.\u0275\u0275reference(7);i.\u0275\u0275classProp("disabled",E.nextDisabled()),i.\u0275\u0275advance(),i.\u0275\u0275attribute("tabindex",E.nextDisabled()?"-1":null)("aria-disabled",E.nextDisabled()?"true":null),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==E.tplLast?null:E.tplLast.templateRef)||U)("ngTemplateOutletContext",i.\u0275\u0275pureFunction2(6,ci,E.nextDisabled(),E.page))}}function He(V,Qe){if(1&V&&i.\u0275\u0275text(0),2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275textInterpolate(E.title)}}function mt(V,Qe){}function bt(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"h3",2),i.\u0275\u0275template(1,He,1,1,"ng-template",null,0,i.\u0275\u0275templateRefExtractor)(3,mt,0,0,"ng-template",4),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275reference(2),U=i.\u0275\u0275nextContext();i.\u0275\u0275advance(3),i.\u0275\u0275property("ngTemplateOutlet",U.isTitleTemplate()?U.title:E)("ngTemplateOutletContext",U.context)}}function nn(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"span"),i.\u0275\u0275i18n(1,0),i.\u0275\u0275pipe(2,"percent"),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275advance(2),i.\u0275\u0275i18nExp(i.\u0275\u0275pipeBind1(2,1,E.getValue()/E.max)),i.\u0275\u0275i18nApply(1)}}function Jn(V,Qe){1&V&&i.\u0275\u0275text(0),2&V&&i.\u0275\u0275textInterpolate(100===Qe.fill?"\u2605":"\u2606")}function Sn(V,Qe){}function _r(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"span",1),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(2,"span",2),i.\u0275\u0275listener("mouseenter",function(){const ee=i.\u0275\u0275restoreView(E).$index,Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.enter(ee+1))})("click",function(){const ee=i.\u0275\u0275restoreView(E).$index,Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.handleClick(ee+1))}),i.\u0275\u0275template(3,Sn,0,0,"ng-template",3),i.\u0275\u0275elementEnd()}if(2&V){const E=Qe.$index,U=i.\u0275\u0275nextContext(),ee=i.\u0275\u0275reference(1);i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1("(",E<U.nextRate?"*":" ",")"),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("cursor",U.isInteractive()?"pointer":"default"),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",U.starTemplate||U.starTemplateFromContent||ee)("ngTemplateOutletContext",U.contexts[E])}}function qr(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.changeHour(ee.hourStep))}),i.\u0275\u0275element(1,"span",16),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,0),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function Bo(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.changeHour(-ee.hourStep))}),i.\u0275\u0275element(1,"span",18),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,1),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function Eo(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.changeMinute(ee.minuteStep))}),i.\u0275\u0275element(1,"span",16),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,2),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function Ro(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.changeMinute(-ee.minuteStep))}),i.\u0275\u0275element(1,"span",18),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,3),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function Ls(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(ee.changeSecond(ee.secondStep))}),i.\u0275\u0275element(1,"span",16),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,4),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function ol(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",15),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(ee.changeSecond(-ee.secondStep))}),i.\u0275\u0275element(1,"span",18),i.\u0275\u0275elementStart(2,"span",17),i.\u0275\u0275i18n(3,5),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled)}}function Va(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"div",12),i.\u0275\u0275text(1,":"),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(2,"div",19),i.\u0275\u0275template(3,Ls,4,7,"button",10),i.\u0275\u0275elementStart(4,"input",20),i.\u0275\u0275listener("change",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.updateSecond(ee.target.value))})("blur",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.handleBlur())})("input",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.formatInput(ee.target))})("keydown.ArrowUp",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return Xe.changeSecond(Xe.secondStep),i.\u0275\u0275resetView(ee.preventDefault())})("keydown.ArrowDown",function(ee){i.\u0275\u0275restoreView(E);const Xe=i.\u0275\u0275nextContext();return Xe.changeSecond(-Xe.secondStep),i.\u0275\u0275resetView(ee.preventDefault())}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(5,ol,4,7,"button",10),i.\u0275\u0275elementEnd()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275advance(3),i.\u0275\u0275conditional(E.spinners?3:-1),i.\u0275\u0275advance(),i.\u0275\u0275classProp("form-control-sm",E.isSmallSize)("form-control-lg",E.isLargeSize),i.\u0275\u0275property("value",E.formatMinSec(null==E.model?null:E.model.second))("readOnly",E.readonlyInputs)("disabled",E.disabled),i.\u0275\u0275advance(),i.\u0275\u0275conditional(E.spinners?5:-1)}}function Ao(V,Qe){if(1&V&&(i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275i18n(1,6),i.\u0275\u0275elementContainerEnd()),2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275i18nExp(E.i18n.getAfternoonPeriod()),i.\u0275\u0275i18nApply(1)}}function za(V,Qe){if(1&V&&(i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275text(1),i.\u0275\u0275elementContainerEnd()),2&V){const E=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E.i18n.getMorningPeriod())}}function vl(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275element(0,"div",12),i.\u0275\u0275elementStart(1,"div",21)(2,"button",22),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.toggleMeridian())}),i.\u0275\u0275template(3,Ao,2,1,"ng-container")(4,za,2,1,"ng-container"),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275advance(2),i.\u0275\u0275classProp("btn-sm",E.isSmallSize)("btn-lg",E.isLargeSize)("disabled",E.disabled),i.\u0275\u0275property("disabled",E.disabled),i.\u0275\u0275advance(),i.\u0275\u0275conditional(E.model&&E.model.hour>=12?3:4)}}function Na(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"strong",3),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E.header)}}function _l(V,Qe){}function gs(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"div",1),i.\u0275\u0275template(1,_l,0,0,"ng-template",4),i.\u0275\u0275elementStart(2,"button",5),i.\u0275\u0275listener("click",function(){i.\u0275\u0275restoreView(E);const ee=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(ee.hide())}),i.\u0275\u0275elementEnd()()}if(2&V){const E=i.\u0275\u0275nextContext(),U=i.\u0275\u0275reference(1);i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",E.contentHeaderTpl||U)}}function Zs(V,Qe){if(1&V&&(i.\u0275\u0275elementStart(0,"span"),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&V){const E=i.\u0275\u0275nextContext().$implicit,U=i.\u0275\u0275nextContext();i.\u0275\u0275classMap(U.highlightClass),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E)}}function oa(V,Qe){if(1&V&&(i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275text(1),i.\u0275\u0275elementContainerEnd()),2&V){const E=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(E)}}function no(V,Qe){1&V&&i.\u0275\u0275template(0,Zs,2,4,"span",0)(1,oa,2,1,"ng-container"),2&V&&i.\u0275\u0275conditional(Qe.$index%2!=0?0:1)}const xl=(V,Qe,E)=>({result:V,term:Qe,formatter:E});function Qr(V,Qe){if(1&V&&i.\u0275\u0275element(0,"ngb-highlight",2),2&V){const U=Qe.term;i.\u0275\u0275property("result",(0,Qe.formatter)(Qe.result))("term",U)}}function dl(V,Qe){}function Ya(V,Qe){if(1&V){const E=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"button",3),i.\u0275\u0275listener("mouseenter",function(){const ee=i.\u0275\u0275restoreView(E).$index,Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.markActive(ee))})("click",function(){const ee=i.\u0275\u0275restoreView(E).$implicit,Xe=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(Xe.select(ee))}),i.\u0275\u0275template(1,dl,0,0,"ng-template",4),i.\u0275\u0275elementEnd()}if(2&V){const E=Qe.$implicit,U=Qe.$index,ee=i.\u0275\u0275nextContext(),Xe=i.\u0275\u0275reference(1);i.\u0275\u0275classProp("active",U===ee.activeIdx),i.\u0275\u0275property("id",ee.id+"-"+U),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",ee.resultTemplate||Xe)("ngTemplateOutletContext",i.\u0275\u0275pureFunction3(5,xl,E,ee.term,ee.formatter))}}const Lo={animation:!0,transitionTimerDelayMs:5};let ko=(()=>{class V{constructor(){this.animation=Lo.animation}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),jt=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.closeOthers=!1,this.destroyOnHide=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();function Rt(V){return parseInt(`${V}`,10)}function jn(V){return null!=V?`${V}`:""}function Fi(V,Qe,E=0){return Math.max(Math.min(V,Qe),E)}function Ui(V){return"string"==typeof V}function ar(V){return!isNaN(Rt(V))}function er(V){return"number"==typeof V&&isFinite(V)&&Math.floor(V)===V}function Or(V){return null!=V}function Tt(V){return V&&V.then}function cn(V){return ar(V)?`0${V}`.slice(-2):""}function Un(V){return(V||document.body).getBoundingClientRect()}function Wi(V){return V.normalize("NFD").replace(/[\u0300-\u036f]/g,"")}function fr(V=document){const Qe=V?.activeElement;return Qe?Qe.shadowRoot?fr(Qe.shadowRoot):Qe:null}const Li=()=>{},{transitionTimerDelayMs:Vo}=Lo,vr=new Map,Mo=(V,Qe,E,U)=>{let ee=U.context||{};const Xe=vr.get(Qe);if(Xe)switch(U.runningTransition){case"continue":return e.EMPTY;case"stop":V.run(()=>Xe.transition$.complete()),ee=Object.assign(Xe.context,ee),vr.delete(Qe)}const Nt=E(Qe,U.animation,ee)||Li;if(!U.animation||"none"===window.getComputedStyle(Qe).transitionProperty)return V.run(()=>Nt()),(0,e.of)(void 0).pipe(function Yi(V){return Qe=>new e.Observable(E=>Qe.subscribe({next:Nt=>V.run(()=>E.next(Nt)),error:Nt=>V.run(()=>E.error(Nt)),complete:()=>V.run(()=>E.complete())}))}(V));const Ei=new e.Subject,gr=new e.Subject,ur=Ei.pipe((0,M.endWith)(!0));vr.set(Qe,{transition$:Ei,complete:()=>{gr.next(),gr.complete()},context:ee});const vo=function In(V){const{transitionDelay:Qe,transitionDuration:E}=window.getComputedStyle(V);return 1e3*(parseFloat(Qe)+parseFloat(E))}(Qe);return V.runOutsideAngular(()=>{const Gr=(0,e.fromEvent)(Qe,"transitionend").pipe((0,M.takeUntil)(ur),(0,M.filter)(({target:cs})=>cs===Qe)),jo=(0,e.timer)(vo+Vo).pipe((0,M.takeUntil)(ur));(0,e.race)(jo,Gr,gr).pipe((0,M.takeUntil)(ur)).subscribe(()=>{vr.delete(Qe),V.run(()=>{Nt(),Ei.next(),Ei.complete()})})}),Ei.asObservable()},$s=(V,Qe,E)=>{let{direction:U,maxSize:ee,dimension:Xe}=E;const{classList:Nt}=V;function Ei(){Nt.add("collapse"),"show"===U?Nt.add("show"):Nt.remove("show")}if(Qe)return ee||(ee=function Jo(V,Qe){if(typeof navigator>"u")return"0px";const{classList:E}=V,U=E.contains("show");U||E.add("show"),V.style[Qe]="";const ee=V.getBoundingClientRect()[Qe]+"px";return U||E.remove("show"),ee}(V,Xe),E.maxSize=ee,V.style[Xe]="show"!==U?ee:"0px",Nt.remove("collapse","collapsing","show"),Un(V),Nt.add("collapsing")),V.style[Xe]="show"===U?ee:"0px",()=>{Ei(),Nt.remove("collapsing"),V.style[Xe]=""};Ei()};let Js=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.horizontal=!1}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),ds=(()=>{class V{constructor(){this._config=(0,i.inject)(Js),this._element=(0,i.inject)(i.ElementRef),this._zone=(0,i.inject)(i.NgZone),this.animation=this._config.animation,this._afterInit=!1,this._isCollapsed=!1,this.ngbCollapseChange=new i.EventEmitter,this.horizontal=this._config.horizontal,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter}set collapsed(E){this._isCollapsed!==E&&(this._isCollapsed=E,this._afterInit&&this._runTransitionWithEvents(E,this.animation))}ngOnInit(){this._runTransition(this._isCollapsed,!1),this._afterInit=!0}toggle(E=this._isCollapsed){this.collapsed=!E,this.ngbCollapseChange.next(this._isCollapsed)}_runTransition(E,U){return Mo(this._zone,this._element.nativeElement,$s,{animation:U,runningTransition:"stop",context:{direction:E?"hide":"show",dimension:this.horizontal?"width":"height"}})}_runTransitionWithEvents(E,U){this._runTransition(E,U).subscribe(()=>{E?this.hidden.emit():this.shown.emit()})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbCollapse",""]],hostVars:2,hostBindings:function(U,ee){2&U&&i.\u0275\u0275classProp("collapse-horizontal",ee.horizontal)},inputs:{animation:"animation",collapsed:[0,"ngbCollapse","collapsed"],horizontal:"horizontal"},outputs:{ngbCollapseChange:"ngbCollapseChange",shown:"shown",hidden:"hidden"},exportAs:["ngbCollapse"],standalone:!0})}return V})(),Ws=0,es=(()=>{class V{constructor(){this._vcr=(0,i.inject)(i.ViewContainerRef),this._element=(0,i.inject)(i.ElementRef).nativeElement,this._item=(0,i.inject)(ga),this._viewRef=null}ngAfterContentChecked(){this._bodyTpl&&(this._item._shouldBeInDOM?this._createViewIfNotExists():this._destroyViewIfExists())}ngOnDestroy(){this._destroyViewIfExists()}_destroyViewIfExists(){this._viewRef?.destroy(),this._viewRef=null}_createViewIfNotExists(){if(!this._viewRef){this._viewRef=this._vcr.createEmbeddedView(this._bodyTpl),this._viewRef.detectChanges();for(const E of this._viewRef.rootNodes)this._element.appendChild(E)}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordionBody",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,i.TemplateRef,7),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._bodyTpl=Nt.first)}},hostAttrs:[1,"accordion-body"],standalone:!0})}return V})(),Ma=(()=>{class V{constructor(){this.item=(0,i.inject)(ga),this.ngbCollapse=(0,i.inject)(ds)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordionCollapse",""]],hostAttrs:["role","region",1,"accordion-collapse"],hostVars:2,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("id",ee.item.collapseId),i.\u0275\u0275attribute("aria-labelledby",ee.item.toggleId))},exportAs:["ngbAccordionCollapse"],standalone:!0,features:[i.\u0275\u0275HostDirectivesFeature([ds])]})}return V})(),ts=(()=>{class V{constructor(){this.item=(0,i.inject)(ga),this.accordion=(0,i.inject)(sl)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordionToggle",""]],hostVars:5,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("click",function(){return!ee.item.disabled&&ee.accordion.toggle(ee.item.id)}),2&U&&(i.\u0275\u0275hostProperty("id",ee.item.toggleId),i.\u0275\u0275attribute("aria-controls",ee.item.collapseId)("aria-expanded",!ee.item.collapsed),i.\u0275\u0275classProp("collapsed",ee.item.collapsed))},standalone:!0})}return V})(),wo=(()=>{class V{constructor(){this.item=(0,i.inject)(ga)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["button","ngbAccordionButton",""]],hostAttrs:["type","button",1,"accordion-button"],hostVars:1,hostBindings:function(U,ee){2&U&&i.\u0275\u0275hostProperty("disabled",ee.item.disabled)},standalone:!0,features:[i.\u0275\u0275HostDirectivesFeature([ts])]})}return V})(),ea=(()=>{class V{constructor(){this.item=(0,i.inject)(ga)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordionHeader",""]],hostAttrs:["role","heading",1,"accordion-header"],hostVars:2,hostBindings:function(U,ee){2&U&&i.\u0275\u0275classProp("collapsed",ee.item.collapsed)},standalone:!0})}return V})(),ga=(()=>{class V{constructor(){this._accordion=(0,i.inject)(sl),this._cd=(0,i.inject)(i.ChangeDetectorRef),this._destroyRef=(0,i.inject)(i.DestroyRef),this._collapsed=!0,this._id="ngb-accordion-item-"+Ws++,this._collapseAnimationRunning=!1,this.disabled=!1,this.show=new i.EventEmitter,this.shown=new i.EventEmitter,this.hide=new i.EventEmitter,this.hidden=new i.EventEmitter}set id(E){Ui(E)&&""!==E&&(this._id=E)}set destroyOnHide(E){this._destroyOnHide=E}get destroyOnHide(){return void 0===this._destroyOnHide?this._accordion.destroyOnHide:this._destroyOnHide}set collapsed(E){E?this.collapse():this.expand()}get collapsed(){return this._collapsed}get id(){return`${this._id}`}get toggleId(){return`${this.id}-toggle`}get collapseId(){return`${this.id}-collapse`}get _shouldBeInDOM(){return!this.collapsed||this._collapseAnimationRunning||!this.destroyOnHide}ngAfterContentInit(){const{ngbCollapse:E}=this._collapse;E.animation=!1,E.collapsed=this.collapsed,E.animation=this._accordion.animation,E.hidden.pipe(X(this._destroyRef)).subscribe(()=>{this._collapseAnimationRunning=!1,this.hidden.emit(),this._accordion.hidden.emit(this.id)}),E.shown.pipe(X(this._destroyRef)).subscribe(()=>{this.shown.emit(),this._accordion.shown.emit(this.id)})}toggle(){this.collapsed=!this.collapsed}expand(){if(this.collapsed){if(!this._accordion._ensureCanExpand(this))return;this._collapsed=!1,this._cd.markForCheck(),this._cd.detectChanges(),this.show.emit(),this._accordion.show.emit(this.id),this._collapse.ngbCollapse.animation=this._accordion.animation,this._collapse.ngbCollapse.collapsed=!1}}collapse(){this.collapsed||(this._collapsed=!0,this._collapseAnimationRunning=!0,this._cd.markForCheck(),this.hide.emit(),this._accordion.hide.emit(this.id),this._collapse.ngbCollapse.animation=this._accordion.animation,this._collapse.ngbCollapse.collapsed=!0)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordionItem",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,Ma,7),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._collapse=Nt.first)}},hostAttrs:[1,"accordion-item"],hostVars:1,hostBindings:function(U,ee){2&U&&i.\u0275\u0275hostProperty("id",ee.id)},inputs:{id:[0,"ngbAccordionItem","id"],destroyOnHide:"destroyOnHide",disabled:"disabled",collapsed:"collapsed"},outputs:{show:"show",shown:"shown",hide:"hide",hidden:"hidden"},exportAs:["ngbAccordionItem"],standalone:!0})}return V})(),sl=(()=>{class V{constructor(){this._config=(0,i.inject)(jt),this._anItemWasAlreadyExpandedDuringInitialisation=!1,this.animation=this._config.animation,this.closeOthers=this._config.closeOthers,this.destroyOnHide=this._config.destroyOnHide,this.show=new i.EventEmitter,this.shown=new i.EventEmitter,this.hide=new i.EventEmitter,this.hidden=new i.EventEmitter}toggle(E){this._getItem(E)?.toggle()}expand(E){this._getItem(E)?.expand()}expandAll(){this._items&&(this.closeOthers?this._items.find(E=>!E.collapsed)||this._items.first.expand():this._items.forEach(E=>E.expand()))}collapse(E){this._getItem(E)?.collapse()}collapseAll(){this._items?.forEach(E=>E.collapse())}isExpanded(E){const U=this._getItem(E);return!!U&&!U.collapsed}_ensureCanExpand(E){return!(this.closeOthers&&(this._items?(this._items.find(U=>!U.collapsed&&E!==U)?.collapse(),0):this._anItemWasAlreadyExpandedDuringInitialisation||(this._anItemWasAlreadyExpandedDuringInitialisation=!0,0)))}_getItem(E){return this._items?.find(U=>U.id===E)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbAccordion",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,ga,4),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._items=Nt)}},hostAttrs:[1,"accordion"],inputs:{animation:"animation",closeOthers:"closeOthers",destroyOnHide:"destroyOnHide"},outputs:{show:"show",shown:"shown",hide:"hide",hidden:"hidden"},exportAs:["ngbAccordion"],standalone:!0})}return V})(),Ia=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),al=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.dismissible=!0,this.type="warning"}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();const Kc=({classList:V})=>{V.remove("show")};let wa=(()=>{class V{constructor(){this._config=(0,i.inject)(al),this._elementRef=(0,i.inject)(i.ElementRef),this._zone=(0,i.inject)(i.NgZone),this.animation=this._config.animation,this.dismissible=this._config.dismissible,this.type=this._config.type,this.closed=new i.EventEmitter}close(){const E=Mo(this._zone,this._elementRef.nativeElement,Kc,{animation:this.animation,runningTransition:"continue"});return E.subscribe(()=>this.closed.emit()),E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-alert"]],hostAttrs:["role","alert"],hostVars:6,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275classMap("alert show"+(ee.type?" alert-"+ee.type:"")),i.\u0275\u0275classProp("fade",ee.animation)("alert-dismissible",ee.dismissible))},inputs:{animation:"animation",dismissible:"dismissible",type:"type"},outputs:{closed:"closed"},exportAs:["ngbAlert"],standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:2,vars:1,consts:()=>{let E;return E=$localize`:@@ngb.alert.close:Close`,[["type","button","aria-label",E,1,"btn-close"],["type","button","aria-label",E,1,"btn-close",3,"click"]]},template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275projection(0),i.\u0275\u0275template(1,Et,1,0,"button",0)),2&U&&(i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.dismissible?1:-1))},styles:["ngb-alert{display:block}\n"],encapsulation:2,changeDetection:0})}return V})(),Sl=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),qc=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.interval=5e3,this.wrap=!0,this.keyboard=!0,this.pauseOnHover=!0,this.pauseOnFocus=!0,this.showNavigationArrows=!0,this.showNavigationIndicators=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();var la=function(V){return V.START="start",V.END="end",V}(la||{});const pl=({classList:V})=>V.contains("carousel-item-start")||V.contains("carousel-item-end"),Sc=V=>{V.remove("carousel-item-start","carousel-item-end")},Ec=V=>{Sc(V),V.remove("carousel-item-prev","carousel-item-next")},Qc=(V,Qe,{direction:E})=>{const{classList:U}=V;return Qe?(pl(V)?Sc(U):(U.add("carousel-item-"+(E===la.START?"next":"prev")),Un(V),U.add("carousel-item-"+E)),()=>{Ec(U),U.add("active")}):(Ec(U),void U.add("active"))},ql=(V,Qe,{direction:E})=>{const{classList:U}=V;return Qe?(pl(V)?Sc(U):U.add("carousel-item-"+E),()=>{Ec(U),U.remove("active")}):(Ec(U),void U.remove("active"))};let ec=0,Yc=0,ca=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef),this.id="ngb-slide-"+ec++,this.slid=new i.EventEmitter}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbSlide",""]],inputs:{id:"id"},outputs:{slid:"slid"},standalone:!0})}return V})(),Il=(()=>{class V{constructor(){this.NgbSlideEventSource=Xa,this._config=(0,i.inject)(qc),this._platformId=(0,i.inject)(i.PLATFORM_ID),this._ngZone=(0,i.inject)(i.NgZone),this._cd=(0,i.inject)(i.ChangeDetectorRef),this._container=(0,i.inject)(i.ElementRef),this._destroyRef=(0,i.inject)(i.DestroyRef),this._injector=(0,i.inject)(i.Injector),this._interval$=new e.BehaviorSubject(this._config.interval),this._mouseHover$=new e.BehaviorSubject(!1),this._focused$=new e.BehaviorSubject(!1),this._pauseOnHover$=new e.BehaviorSubject(this._config.pauseOnHover),this._pauseOnFocus$=new e.BehaviorSubject(this._config.pauseOnFocus),this._pause$=new e.BehaviorSubject(!1),this._wrap$=new e.BehaviorSubject(this._config.wrap),this.id="ngb-carousel-"+Yc++,this.animation=this._config.animation,this.keyboard=this._config.keyboard,this.showNavigationArrows=this._config.showNavigationArrows,this.showNavigationIndicators=this._config.showNavigationIndicators,this.slide=new i.EventEmitter,this.slid=new i.EventEmitter,this._transitionIds=null}set interval(E){this._interval$.next(E)}get interval(){return this._interval$.value}set wrap(E){this._wrap$.next(E)}get wrap(){return this._wrap$.value}set pauseOnHover(E){this._pauseOnHover$.next(E)}get pauseOnHover(){return this._pauseOnHover$.value}set pauseOnFocus(E){this._pauseOnFocus$.next(E)}get pauseOnFocus(){return this._pauseOnFocus$.value}set mouseHover(E){this._mouseHover$.next(E)}get mouseHover(){return this._mouseHover$.value}set focused(E){this._focused$.next(E)}get focused(){return this._focused$.value}arrowLeft(){this.focus(),this.prev(Xa.ARROW_LEFT)}arrowRight(){this.focus(),this.next(Xa.ARROW_RIGHT)}ngAfterContentInit(){(0,Z.isPlatformBrowser)(this._platformId)&&this._ngZone.runOutsideAngular(()=>{const E=(0,e.combineLatest)([this.slide.pipe((0,M.map)(U=>U.current),(0,M.startWith)(this.activeId)),this._wrap$,this.slides.changes.pipe((0,M.startWith)(null))]).pipe((0,M.map)(([U,ee])=>{const Xe=this.slides.toArray(),Nt=this._getSlideIdxById(U);return ee?Xe.length>1:Nt<Xe.length-1}),(0,M.distinctUntilChanged)());(0,e.combineLatest)([this._pause$,this._pauseOnHover$,this._mouseHover$,this._pauseOnFocus$,this._focused$,this._interval$,E]).pipe((0,M.map)(([U,ee,Xe,Nt,Ei,gr,ur])=>U||ee&&Xe||Nt&&Ei||!ur?0:gr),(0,M.distinctUntilChanged)(),(0,M.switchMap)(U=>U>0?(0,e.timer)(U,U):e.NEVER),X(this._destroyRef)).subscribe(()=>this._ngZone.run(()=>this.next(Xa.TIMER)))}),this.slides.changes.pipe(X(this._destroyRef)).subscribe(()=>{this._transitionIds?.forEach(E=>(V=>{vr.get(V)?.complete()})(this._getSlideElement(E))),this._transitionIds=null,this._cd.markForCheck(),(0,i.afterNextRender)(()=>{for(const{id:E}of this.slides){const U=this._getSlideElement(E);E===this.activeId?U.classList.add("active"):U.classList.remove("active")}},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector})})}ngAfterContentChecked(){let E=this._getSlideById(this.activeId);this.activeId=E?E.id:this.slides.length?this.slides.first.id:""}ngAfterViewInit(){if(this.activeId){const E=this._getSlideElement(this.activeId);E&&E.classList.add("active")}}select(E,U){this._cycleToSelected(E,this._getSlideEventDirection(this.activeId,E),U)}prev(E){this._cycleToSelected(this._getPrevSlide(this.activeId),la.END,E)}next(E){this._cycleToSelected(this._getNextSlide(this.activeId),la.START,E)}pause(){this._pause$.next(!0)}cycle(){this._pause$.next(!1)}focus(){this._container.nativeElement.focus()}_cycleToSelected(E,U,ee){const Xe=this._transitionIds;if(Xe&&(Xe[0]!==E||Xe[1]!==this.activeId))return;let Nt=this._getSlideById(E);if(Nt&&Nt.id!==this.activeId){this._transitionIds=[this.activeId,E],this.slide.emit({prev:this.activeId,current:Nt.id,direction:U,paused:this._pause$.value,source:ee});const Ei={animation:this.animation,runningTransition:"stop",context:{direction:U}},gr=[],ur=this._getSlideById(this.activeId);if(ur){const cs=Mo(this._ngZone,this._getSlideElement(ur.id),ql,Ei);cs.subscribe(()=>{ur.slid.emit({isShown:!1,direction:U,source:ee})}),gr.push(cs)}const vo=this.activeId;this.activeId=Nt.id;const Gr=this._getSlideById(this.activeId),jo=Mo(this._ngZone,this._getSlideElement(Nt.id),Qc,Ei);jo.subscribe(()=>{Gr?.slid.emit({isShown:!0,direction:U,source:ee})}),gr.push(jo),(0,e.zip)(...gr).pipe((0,M.take)(1)).subscribe(()=>{this._transitionIds=null,this.slid.emit({prev:vo,current:Nt.id,direction:U,paused:this._pause$.value,source:ee})})}this._cd.markForCheck()}_getSlideEventDirection(E,U){return this._getSlideIdxById(E)>this._getSlideIdxById(U)?la.END:la.START}_getSlideById(E){return this.slides.find(U=>U.id===E)||null}_getSlideIdxById(E){const U=this._getSlideById(E);return null!=U?this.slides.toArray().indexOf(U):-1}_getNextSlide(E){const U=this.slides.toArray(),ee=this._getSlideIdxById(E);return ee===U.length-1?this.wrap?U[0].id:U[U.length-1].id:U[ee+1].id}_getPrevSlide(E){const U=this.slides.toArray(),ee=this._getSlideIdxById(E);return 0===ee?this.wrap?U[U.length-1].id:U[0].id:U[ee-1].id}_getSlideElement(E){return this._container.nativeElement.querySelector(`#slide-${E}`)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-carousel"]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,ca,4),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.slides=Nt)}},hostAttrs:["tabIndex","0",1,"carousel","slide"],hostVars:3,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("keydown.arrowLeft",function(){return ee.keyboard&&ee.arrowLeft()})("keydown.arrowRight",function(){return ee.keyboard&&ee.arrowRight()})("mouseenter",function(){return ee.mouseHover=!0})("mouseleave",function(){return ee.mouseHover=!1})("focusin",function(){return ee.focused=!0})("focusout",function(){return ee.focused=!1}),2&U&&(i.\u0275\u0275attribute("aria-activedescendant","slide-"+ee.activeId),i.\u0275\u0275styleProp("display","block"))},inputs:{animation:"animation",activeId:"activeId",interval:"interval",wrap:"wrap",keyboard:"keyboard",pauseOnHover:"pauseOnHover",pauseOnFocus:"pauseOnFocus",showNavigationArrows:"showNavigationArrows",showNavigationIndicators:"showNavigationIndicators"},outputs:{slide:"slide",slid:"slid"},exportAs:["ngbCarousel"],standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:7,vars:3,consts:()=>{let E,U,ee;return E=$localize`:Currently selected slide number read by screen reader@@ngb.carousel.slide-number: Slide ${"\ufffd0\ufffd"}:INTERPOLATION: of ${"\ufffd1\ufffd"}:INTERPOLATION_1: `,U=$localize`:@@ngb.carousel.previous:Previous`,ee=$localize`:@@ngb.carousel.next:Next`,[E,U,ee,["role","tablist",1,"carousel-indicators"],["type","button","data-bs-target","","role","tab",3,"active"],[1,"carousel-inner"],["role","tabpanel",1,"carousel-item",3,"id"],["type","button","data-bs-target","","role","tab",3,"click"],[1,"visually-hidden"],[3,"ngTemplateOutlet"],["type","button",1,"carousel-control-prev",3,"click"],["aria-hidden","true",1,"carousel-control-prev-icon"],[1,"visually-hidden",3,"id"],["type","button",1,"carousel-control-next",3,"click"],["aria-hidden","true",1,"carousel-control-next-icon"]]},template:function(U,ee){1&U&&(i.\u0275\u0275elementStart(0,"div",3),i.\u0275\u0275repeaterCreate(1,wt,1,5,"button",4,i.\u0275\u0275repeaterTrackByIdentity),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"div",5),i.\u0275\u0275repeaterCreate(4,fn,4,4,"div",6,i.\u0275\u0275repeaterTrackByIdentity),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(6,ct,8,4)),2&U&&(i.\u0275\u0275classProp("visually-hidden",!ee.showNavigationIndicators),i.\u0275\u0275advance(),i.\u0275\u0275repeater(ee.slides),i.\u0275\u0275advance(3),i.\u0275\u0275repeater(ee.slides),i.\u0275\u0275advance(2),i.\u0275\u0275conditional(ee.showNavigationArrows?6:-1))},dependencies:[Z.NgTemplateOutlet],encapsulation:2,changeDetection:0})}return V})();var Xa=function(V){return V.TIMER="timer",V.ARROW_LEFT="arrowLeft",V.ARROW_RIGHT="arrowRight",V.INDICATOR="indicator",V}(Xa||{});let Rl=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),yl=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})();class sa{static from(Qe){return Qe instanceof sa?Qe:Qe?new sa(Qe.year,Qe.month,Qe.day):null}constructor(Qe,E,U){this.year=er(Qe)?Qe:null,this.month=er(E)?E:null,this.day=er(U)?U:null}equals(Qe){return null!=Qe&&this.year===Qe.year&&this.month===Qe.month&&this.day===Qe.day}before(Qe){return!!Qe&&(this.year===Qe.year?this.month===Qe.month?this.day!==Qe.day&&this.day<Qe.day:this.month<Qe.month:this.year<Qe.year)}after(Qe){return!!Qe&&(this.year===Qe.year?this.month===Qe.month?this.day!==Qe.day&&this.day>Qe.day:this.month>Qe.month:this.year>Qe.year)}}function Lu(V){return new sa(V.getFullYear(),V.getMonth()+1,V.getDate())}function Aa(V){const Qe=new Date(V.year,V.month-1,V.day,12);return isNaN(Qe.getTime())||Qe.setFullYear(V.year),Qe}let Ql=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>function ku(){return new sc}(),providedIn:"root"})}return V})(),sc=(()=>{class V extends Ql{getDaysPerWeek(){return 7}getMonths(){return[1,2,3,4,5,6,7,8,9,10,11,12]}getWeeksPerMonth(){return 6}getNext(E,U="d",ee=1){let Xe=Aa(E),Nt=!0,Ei=Xe.getMonth();switch(U){case"y":Xe.setFullYear(Xe.getFullYear()+ee);break;case"m":Ei+=ee,Xe.setMonth(Ei),Ei%=12,Ei<0&&(Ei+=12);break;case"d":Xe.setDate(Xe.getDate()+ee),Nt=!1;break;default:return E}return Nt&&Xe.getMonth()!==Ei&&Xe.setDate(0),Lu(Xe)}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){let ee=Aa(E).getDay();return 0===ee?7:ee}getWeekNumber(E,U){7===U&&(U=0);const Nt=Aa(E[(11-U)%7]);Nt.setDate(Nt.getDate()+4-(Nt.getDay()||7));const Ei=Nt.getTime();return Nt.setMonth(0),Nt.setDate(1),Math.floor(Math.round((Ei-Nt.getTime())/864e5)/7)+1}getToday(){return Lu(new Date)}isValid(E){if(!(E&&er(E.year)&&er(E.month)&&er(E.day)&&0!==E.year))return!1;const U=Aa(E);return!isNaN(U.getTime())&&U.getFullYear()===E.year&&U.getMonth()+1===E.month&&U.getDate()===E.day}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();function ta(V,Qe){return!function xu(V,Qe){return!V&&!Qe||!!V&&!!Qe&&V.equals(Qe)}(V,Qe)}function vc(V,Qe){return!(!V&&!Qe||V&&Qe&&V.year===Qe.year&&V.month===Qe.month)}function po(V,Qe,E){return V&&Qe&&V.before(Qe)?Qe:V&&E&&V.after(E)?E:V||null}function Ll(V,Qe){const{minDate:E,maxDate:U,disabled:ee,markDisabled:Xe}=Qe;return!(null==V||ee||Xe&&Xe(V,{year:V.year,month:V.month})||E&&V.before(E)||U&&V.after(U))}let re=(()=>{class V{getMonthLabel(E){return`${this.getMonthFullName(E.month,E.year)} ${this.getYearNumerals(E.year)}`}getDayNumerals(E){return`${E.day}`}getWeekNumerals(E){return`${E}`}getYearNumerals(E){return`${E}`}getWeekLabel(){return""}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>new Ge,providedIn:"root"})}return V})(),Ge=(()=>{class V extends re{constructor(){super(...arguments),this._locale=(0,i.inject)(i.LOCALE_ID),this._monthsShort=[...Array(12).keys()].map(E=>Intl.DateTimeFormat(this._locale,{month:"short",timeZone:"UTC"}).format(Date.UTC(2e3,E))),this._monthsFull=[...Array(12).keys()].map(E=>Intl.DateTimeFormat(this._locale,{month:"long",timeZone:"UTC"}).format(Date.UTC(2e3,E)))}getWeekdayLabel(E,U="narrow"){return[1,2,3,4,5,6,7].map(Xe=>Intl.DateTimeFormat(this._locale,{weekday:U,timeZone:"UTC"}).format(Date.UTC(2e3,4,Xe)))[E-1]||""}getMonthShortName(E){return this._monthsShort[E-1]||""}getMonthFullName(E){return this._monthsFull[E-1]||""}getDayAriaLabel(E){const U=new Date(E.year,E.month-1,E.day);return(0,Z.formatDate)(U,"fullDate",this._locale)}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),xt=(()=>{class V{constructor(){this._VALIDATORS={dayTemplateData:E=>{if(this._state.dayTemplateData!==E)return{dayTemplateData:E}},displayMonths:E=>{if(er(E=Rt(E))&&E>0&&this._state.displayMonths!==E)return{displayMonths:E}},disabled:E=>{if(this._state.disabled!==E)return{disabled:E}},firstDayOfWeek:E=>{if(er(E=Rt(E))&&E>=0&&this._state.firstDayOfWeek!==E)return{firstDayOfWeek:E}},focusVisible:E=>{if(this._state.focusVisible!==E&&!this._state.disabled)return{focusVisible:E}},markDisabled:E=>{if(this._state.markDisabled!==E)return{markDisabled:E}},maxDate:E=>{const U=this.toValidDate(E,null);if(ta(this._state.maxDate,U))return{maxDate:U}},minDate:E=>{const U=this.toValidDate(E,null);if(ta(this._state.minDate,U))return{minDate:U}},navigation:E=>{if(this._state.navigation!==E)return{navigation:E}},outsideDays:E=>{if(this._state.outsideDays!==E)return{outsideDays:E}},weekdays:E=>{const U=!0===E||!1===E?"narrow":E,ee=!0!==E&&!1!==E||E;if(this._state.weekdayWidth!==U||this._state.weekdaysVisible!==ee)return{weekdayWidth:U,weekdaysVisible:ee}}},this._calendar=(0,i.inject)(Ql),this._i18n=(0,i.inject)(re),this._model$=new e.Subject,this._dateSelect$=new e.Subject,this._state={dayTemplateData:null,markDisabled:null,maxDate:null,minDate:null,disabled:!1,displayMonths:1,firstDate:null,firstDayOfWeek:1,lastDate:null,focusDate:null,focusVisible:!1,months:[],navigation:"select",outsideDays:"visible",prevDisabled:!1,nextDisabled:!1,selectedDate:null,selectBoxes:{years:[],months:[]},weekdayWidth:"narrow",weekdaysVisible:!0}}get model$(){return this._model$.pipe((0,M.filter)(E=>E.months.length>0))}get dateSelect$(){return this._dateSelect$.pipe((0,M.filter)(E=>null!==E))}set(E){let U=Object.keys(E).map(ee=>this._VALIDATORS[ee](E[ee])).reduce((ee,Xe)=>({...ee,...Xe}),{});Object.keys(U).length>0&&this._nextState(U)}focus(E){const U=this.toValidDate(E,null);null!=U&&!this._state.disabled&&ta(this._state.focusDate,U)&&this._nextState({focusDate:E})}focusSelect(){Ll(this._state.focusDate,this._state)&&this.select(this._state.focusDate,{emitEvent:!0})}open(E){const U=this.toValidDate(E,this._calendar.getToday());null!=U&&!this._state.disabled&&(!this._state.firstDate||vc(this._state.firstDate,U))&&this._nextState({firstDate:U})}select(E,U={}){const ee=this.toValidDate(E,null);null!=ee&&!this._state.disabled&&(ta(this._state.selectedDate,ee)&&this._nextState({selectedDate:ee}),U.emitEvent&&Ll(ee,this._state)&&this._dateSelect$.next(ee))}toValidDate(E,U){const ee=sa.from(E);return void 0===U&&(U=this._calendar.getToday()),this._calendar.isValid(ee)?ee:U}getMonth(E){for(let U of this._state.months)if(E.month===U.number&&E.year===U.year)return U;throw new Error(`month ${E.month} of year ${E.year} not found`)}_nextState(E){const U=this._updateState(E);this._patchContexts(U),this._state=U,this._model$.next(this._state)}_patchContexts(E){const{months:U,displayMonths:ee,selectedDate:Xe,focusDate:Nt,focusVisible:Ei,disabled:gr,outsideDays:ur}=E;E.months.forEach(vo=>{vo.weeks.forEach(Gr=>{Gr.days.forEach(jo=>{Nt&&(jo.context.focused=Nt.equals(jo.date)&&Ei),jo.tabindex=!gr&&Nt&&jo.date.equals(Nt)&&Nt.month===vo.number?0:-1,!0===gr&&(jo.context.disabled=!0),void 0!==Xe&&(jo.context.selected=null!==Xe&&Xe.equals(jo.date)),vo.number!==jo.date.month&&(jo.hidden="hidden"===ur||"collapsed"===ur||ee>1&&jo.date.after(U[0].firstDate)&&jo.date.before(U[ee-1].lastDate))})})})}_updateState(E){const U=Object.assign({},this._state,E);let ee=U.firstDate;if(("minDate"in E||"maxDate"in E)&&(function Fc(V,Qe){if(Qe&&V&&Qe.before(V))throw new Error(`'maxDate' ${Qe} should be greater than 'minDate' ${V}`)}(U.minDate,U.maxDate),U.focusDate=po(U.focusDate,U.minDate,U.maxDate),U.firstDate=po(U.firstDate,U.minDate,U.maxDate),ee=U.focusDate),"disabled"in E&&(U.focusVisible=!1),"selectedDate"in E&&0===this._state.months.length&&(ee=U.selectedDate),"focusVisible"in E||"focusDate"in E&&(U.focusDate=po(U.focusDate,U.minDate,U.maxDate),ee=U.focusDate,0!==U.months.length&&U.focusDate&&!U.focusDate.before(U.firstDate)&&!U.focusDate.after(U.lastDate)))return U;if("firstDate"in E&&(U.firstDate=po(U.firstDate,U.minDate,U.maxDate),ee=U.firstDate),ee){const Nt=function Rc(V,Qe,E,U,ee){const{displayMonths:Xe,months:Nt}=E,Ei=Nt.splice(0,Nt.length);return Array.from({length:Xe},(ur,vo)=>{const Gr=Object.assign(V.getNext(Qe,"m",vo),{day:1});if(Nt[vo]=null,!ee){const jo=Ei.findIndex(cs=>cs.firstDate.equals(Gr));-1!==jo&&(Nt[vo]=Ei.splice(jo,1)[0])}return Gr}).forEach((ur,vo)=>{null===Nt[vo]&&(Nt[vo]=function Ke(V,Qe,E,U,ee={}){const{dayTemplateData:Xe,minDate:Nt,maxDate:Ei,firstDayOfWeek:gr,markDisabled:ur,outsideDays:vo,weekdayWidth:Gr,weekdaysVisible:jo}=E,cs=V.getToday();ee.firstDate=null,ee.lastDate=null,ee.number=Qe.month,ee.year=Qe.year,ee.weeks=ee.weeks||[],ee.weekdays=ee.weekdays||[],Qe=function Se(V,Qe,E){const U=V.getDaysPerWeek(),ee=new sa(Qe.year,Qe.month,1),Xe=V.getWeekday(ee)%U;return V.getPrev(ee,"d",(U+Xe-E)%U)}(V,Qe,gr),jo||(ee.weekdays.length=0);for(let el=0;el<V.getWeeksPerMonth();el++){let gu=ee.weeks[el];gu||(gu=ee.weeks[el]={number:0,days:[],collapsed:!0});const Zl=gu.days;for(let Ga=0;Ga<V.getDaysPerWeek();Ga++){0===el&&jo&&(ee.weekdays[Ga]=U.getWeekdayLabel(V.getWeekday(Qe),Gr));const qa=new sa(Qe.year,Qe.month,Qe.day),Th=V.getNext(qa),Pm=U.getDayAriaLabel(qa);let nh=!!(Nt&&qa.before(Nt)||Ei&&qa.after(Ei));!nh&&ur&&(nh=ur(qa,{month:ee.number,year:ee.year}));let ih=qa.equals(cs),Jh=Xe?Xe(qa,{month:ee.number,year:ee.year}):void 0;null===ee.firstDate&&qa.month===ee.number&&(ee.firstDate=qa),qa.month===ee.number&&Th.month!==ee.number&&(ee.lastDate=qa);let em=Zl[Ga];em||(em=Zl[Ga]={}),em.date=qa,em.context=Object.assign(em.context||{},{$implicit:qa,date:qa,data:Jh,currentMonth:ee.number,currentYear:ee.year,disabled:nh,focused:!1,selected:!1,today:ih}),em.tabindex=-1,em.ariaLabel=Pm,em.hidden=!1,Qe=Th}gu.number=V.getWeekNumber(Zl.map(Ga=>Ga.date),gr),gu.collapsed="collapsed"===vo&&Zl[0].date.month!==ee.number&&Zl[Zl.length-1].date.month!==ee.number}return ee}(V,ur,E,U,Ei.shift()||{}))}),Nt}(this._calendar,ee,U,this._i18n,"dayTemplateData"in E||"firstDayOfWeek"in E||"markDisabled"in E||"minDate"in E||"maxDate"in E||"disabled"in E||"outsideDays"in E||"weekdaysVisible"in E);U.months=Nt,U.firstDate=Nt[0].firstDate,U.lastDate=Nt[Nt.length-1].lastDate,"selectedDate"in E&&!Ll(U.selectedDate,U)&&(U.selectedDate=null),"firstDate"in E&&(!U.focusDate||U.focusDate.before(U.firstDate)||U.focusDate.after(U.lastDate))&&(U.focusDate=ee);const Ei=!this._state.firstDate||this._state.firstDate.year!==U.firstDate.year,gr=!this._state.firstDate||this._state.firstDate.month!==U.firstDate.month;"select"===U.navigation?(("minDate"in E||"maxDate"in E||0===U.selectBoxes.years.length||Ei)&&(U.selectBoxes.years=function kl(V,Qe,E){if(!V)return[];const U=Qe?Math.max(Qe.year,V.year-500):V.year-10,Xe=(E?Math.min(E.year,V.year+500):V.year+10)-U+1,Nt=Array(Xe);for(let Ei=0;Ei<Xe;Ei++)Nt[Ei]=U+Ei;return Nt}(U.firstDate,U.minDate,U.maxDate)),("minDate"in E||"maxDate"in E||0===U.selectBoxes.months.length||Ei)&&(U.selectBoxes.months=function Hs(V,Qe,E,U){if(!Qe)return[];let ee=V.getMonths(Qe.year);if(E&&Qe.year===E.year){const Xe=ee.findIndex(Nt=>Nt===E.month);ee=ee.slice(Xe)}if(U&&Qe.year===U.year){const Xe=ee.findIndex(Nt=>Nt===U.month);ee=ee.slice(0,Xe+1)}return ee}(this._calendar,U.firstDate,U.minDate,U.maxDate))):U.selectBoxes={years:[],months:[]},("arrows"===U.navigation||"select"===U.navigation)&&(gr||Ei||"minDate"in E||"maxDate"in E||"disabled"in E)&&(U.prevDisabled=U.disabled||function fu(V,Qe,E){const U=Object.assign(V.getPrev(Qe,"m"),{day:1});return null!=E&&(U.year===E.year&&U.month<E.month||U.year<E.year&&1===E.month)}(this._calendar,U.firstDate,U.minDate),U.nextDisabled=U.disabled||function Nc(V,Qe,E){const U=Object.assign(V.getNext(Qe,"m"),{day:1});return null!=E&&U.after(E)}(this._calendar,U.lastDate,U.maxDate))}return U}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();var Qt=function(V){return V[V.PREV=0]="PREV",V[V.NEXT=1]="NEXT",V}(Qt||{});let kn=(()=>{class V{constructor(){this.displayMonths=1,this.firstDayOfWeek=1,this.navigation="select",this.outsideDays="visible",this.showWeekNumbers=!1,this.weekdays="narrow"}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),vi=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>function bi(){return new Ci}(),providedIn:"root"})}return V})(),Ci=(()=>{class V extends vi{fromModel(E){return E&&er(E.year)&&er(E.month)&&er(E.day)?{year:E.year,month:E.month,day:E.day}:null}toModel(E){return E&&er(E.year)&&er(E.month)&&er(E.day)?{year:E.year,month:E.month,day:E.day}:null}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),Xi=(()=>{class V{processKey(E,U){const{state:ee,calendar:Xe}=U;switch(E.key){case"PageUp":U.focusDate(Xe.getPrev(ee.focusedDate,E.shiftKey?"y":"m",1));break;case"PageDown":U.focusDate(Xe.getNext(ee.focusedDate,E.shiftKey?"y":"m",1));break;case"End":U.focusDate(E.shiftKey?ee.maxDate:ee.lastDate);break;case"Home":U.focusDate(E.shiftKey?ee.minDate:ee.firstDate);break;case"ArrowLeft":U.focusDate(Xe.getPrev(ee.focusedDate,"d",1));break;case"ArrowUp":U.focusDate(Xe.getPrev(ee.focusedDate,"d",Xe.getDaysPerWeek()));break;case"ArrowRight":U.focusDate(Xe.getNext(ee.focusedDate,"d",1));break;case"ArrowDown":U.focusDate(Xe.getNext(ee.focusedDate,"d",Xe.getDaysPerWeek()));break;case"Enter":case" ":U.focusSelect();break;default:return}E.preventDefault(),E.stopPropagation()}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),$i=(()=>{class V{constructor(){this.i18n=(0,i.inject)(re)}isMuted(){return!this.selected&&(this.date.month!==this.currentMonth||this.disabled)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["","ngbDatepickerDayView",""]],hostAttrs:[1,"btn-light"],hostVars:10,hostBindings:function(U,ee){2&U&&i.\u0275\u0275classProp("bg-primary",ee.selected)("text-white",ee.selected)("text-muted",ee.isMuted())("outside",ee.isMuted())("active",ee.focused)},inputs:{currentMonth:"currentMonth",date:"date",disabled:"disabled",focused:"focused",selected:"selected"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],attrs:en,decls:1,vars:1,template:function(U,ee){1&U&&i.\u0275\u0275text(0),2&U&&i.\u0275\u0275textInterpolate(ee.i18n.getDayNumerals(ee.date))},styles:["[ngbDatepickerDayView]{text-align:center;width:2rem;height:2rem;line-height:2rem;border-radius:.25rem;background:transparent}[ngbDatepickerDayView]:hover:not(.bg-primary),[ngbDatepickerDayView].active:not(.bg-primary){background-color:var(--bs-tertiary-bg);outline:1px solid var(--bs-border-color)}[ngbDatepickerDayView].outside{opacity:.5}\n"],encapsulation:2,changeDetection:0})}return V})(),Er=(()=>{class V{constructor(){this._month=-1,this._year=-1,this.i18n=(0,i.inject)(re),this.select=new i.EventEmitter}changeMonth(E){this.select.emit(new sa(this.date.year,Rt(E),1))}changeYear(E){this.select.emit(new sa(Rt(E),this.date.month,1))}ngAfterViewChecked(){this.date&&(this.date.month!==this._month&&(this._month=this.date.month,this.monthSelect.nativeElement.value=`${this._month}`),this.date.year!==this._year&&(this._year=this.date.year,this.yearSelect.nativeElement.value=`${this._year}`))}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-datepicker-navigation-select"]],viewQuery:function(U,ee){if(1&U&&(i.\u0275\u0275viewQuery(an,7,i.ElementRef),i.\u0275\u0275viewQuery(un,7,i.ElementRef)),2&U){let Xe;i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee.monthSelect=Xe.first),i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee.yearSelect=Xe.first)}},inputs:{date:"date",disabled:"disabled",months:"months",years:"years"},outputs:{select:"select"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:8,vars:2,consts:()=>{let E,U,ee,Xe;return E=$localize`:@@ngb.datepicker.select-month:Select month`,U=$localize`:@@ngb.datepicker.select-month:Select month`,ee=$localize`:@@ngb.datepicker.select-year:Select year`,Xe=$localize`:@@ngb.datepicker.select-year:Select year`,[["month",""],["year",""],["aria-label",E,"title",U,1,"form-select",3,"change","disabled"],[3,"value"],["aria-label",ee,"title",Xe,1,"form-select",3,"change","disabled"]]},template:function(U,ee){if(1&U){const Xe=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"select",2,0),i.\u0275\u0275listener("change",function(Ei){return i.\u0275\u0275restoreView(Xe),i.\u0275\u0275resetView(ee.changeMonth(Ei.target.value))}),i.\u0275\u0275repeaterCreate(2,vn,2,3,"option",3,i.\u0275\u0275repeaterTrackByIdentity),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(4,"select",4,1),i.\u0275\u0275listener("change",function(Ei){return i.\u0275\u0275restoreView(Xe),i.\u0275\u0275resetView(ee.changeYear(Ei.target.value))}),i.\u0275\u0275repeaterCreate(6,Pt,2,2,"option",3,i.\u0275\u0275repeaterTrackByIdentity),i.\u0275\u0275elementEnd()}2&U&&(i.\u0275\u0275property("disabled",ee.disabled),i.\u0275\u0275advance(2),i.\u0275\u0275repeater(ee.months),i.\u0275\u0275advance(2),i.\u0275\u0275property("disabled",ee.disabled),i.\u0275\u0275advance(2),i.\u0275\u0275repeater(ee.years))},styles:["ngb-datepicker-navigation-select>.form-select{flex:1 1 auto;padding:0 .5rem;font-size:.875rem;height:1.85rem}ngb-datepicker-navigation-select>.form-select:focus{z-index:1}ngb-datepicker-navigation-select>.form-select::-ms-value{background-color:transparent!important}\n"],encapsulation:2,changeDetection:0})}return V})(),ai=(()=>{class V{constructor(){this.navigation=Qt,this.i18n=(0,i.inject)(re),this.months=[],this.navigate=new i.EventEmitter,this.select=new i.EventEmitter}onClickPrev(E){E.currentTarget.focus(),this.navigate.emit(this.navigation.PREV)}onClickNext(E){E.currentTarget.focus(),this.navigate.emit(this.navigation.NEXT)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-datepicker-navigation"]],inputs:{date:"date",disabled:"disabled",months:"months",showSelect:"showSelect",prevDisabled:"prevDisabled",nextDisabled:"nextDisabled",selectBoxes:"selectBoxes"},outputs:{navigate:"navigate",select:"select"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:8,vars:4,consts:()=>{let E,U,ee,Xe;return E=$localize`:@@ngb.datepicker.previous-month:Previous month`,U=$localize`:@@ngb.datepicker.previous-month:Previous month`,ee=$localize`:@@ngb.datepicker.next-month:Next month`,Xe=$localize`:@@ngb.datepicker.next-month:Next month`,[[1,"ngb-dp-arrow","ngb-dp-arrow-prev"],["type","button","aria-label",E,"title",U,1,"btn","btn-link","ngb-dp-arrow-btn",3,"click","disabled"],[1,"ngb-dp-navigation-chevron"],[1,"ngb-dp-navigation-select",3,"date","disabled","months","years"],[1,"ngb-dp-arrow","ngb-dp-arrow-next"],["type","button","aria-label",ee,"title",Xe,1,"btn","btn-link","ngb-dp-arrow-btn",3,"click","disabled"],[1,"ngb-dp-navigation-select",3,"select","date","disabled","months","years"],[1,"ngb-dp-arrow"],[1,"ngb-dp-month-name"]]},template:function(U,ee){1&U&&(i.\u0275\u0275elementStart(0,"div",0)(1,"button",1),i.\u0275\u0275listener("click",function(Nt){return ee.onClickPrev(Nt)}),i.\u0275\u0275element(2,"span",2),i.\u0275\u0275elementEnd()(),i.\u0275\u0275template(3,Ae,1,4,"ngb-datepicker-navigation-select",3)(4,Wt,2,0),i.\u0275\u0275elementStart(5,"div",4)(6,"button",5),i.\u0275\u0275listener("click",function(Nt){return ee.onClickNext(Nt)}),i.\u0275\u0275element(7,"span",2),i.\u0275\u0275elementEnd()()),2&U&&(i.\u0275\u0275advance(),i.\u0275\u0275property("disabled",ee.prevDisabled),i.\u0275\u0275advance(2),i.\u0275\u0275conditional(ee.showSelect?3:-1),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.showSelect?-1:4),i.\u0275\u0275advance(2),i.\u0275\u0275property("disabled",ee.nextDisabled))},dependencies:[Er],styles:["ngb-datepicker-navigation{display:flex;align-items:center}.ngb-dp-navigation-chevron{border-style:solid;border-width:.2em .2em 0 0;display:inline-block;width:.75em;height:.75em;margin-left:.25em;margin-right:.15em;transform:rotate(-135deg)}.ngb-dp-arrow{display:flex;flex:1 1 auto;padding-right:0;padding-left:0;margin:0;width:2rem;height:2rem}.ngb-dp-arrow-next{justify-content:flex-end}.ngb-dp-arrow-next .ngb-dp-navigation-chevron{transform:rotate(45deg);margin-left:.15em;margin-right:.25em}.ngb-dp-arrow-btn{padding:0 .25rem;margin:0 .5rem;border:none;background-color:transparent;z-index:1}.ngb-dp-arrow-btn:focus{outline-width:1px;outline-style:auto}@media all and (-ms-high-contrast: none),(-ms-high-contrast: active){.ngb-dp-arrow-btn:focus{outline-style:solid}}.ngb-dp-month-name{font-size:larger;height:2rem;line-height:2rem;text-align:center}.ngb-dp-navigation-select{display:flex;flex:1 1 9rem}\n"],encapsulation:2,changeDetection:0})}return V})(),so=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbDatepickerContent",""]],standalone:!0})}return V})(),Fr=(()=>{class V{constructor(){this._keyboardService=(0,i.inject)(Xi),this._service=(0,i.inject)(xt),this.i18n=(0,i.inject)(re),this.datepicker=(0,i.inject)(zr)}set month(E){this.viewModel=this._service.getMonth(E)}onKeyDown(E){this._keyboardService.processKey(E,this.datepicker)}doSelect(E){!E.context.disabled&&!E.hidden&&this.datepicker.onDateSelect(E.date)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-datepicker-month"]],hostAttrs:["role","grid"],hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("keydown",function(Nt){return ee.onKeyDown(Nt)})},inputs:{month:"month"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:3,vars:1,consts:[["role","row",1,"ngb-dp-week","ngb-dp-weekdays"],[1,"ngb-dp-weekday","ngb-dp-showweek","small"],["role","columnheader",1,"ngb-dp-weekday","small"],["role","row",1,"ngb-dp-week"],[1,"ngb-dp-week-number","small","text-muted"],["role","gridcell",1,"ngb-dp-day",3,"disabled","tabindex","hidden","ngb-dp-today"],["role","gridcell",1,"ngb-dp-day",3,"click","tabindex"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(U,ee){1&U&&(i.\u0275\u0275template(0,pn,4,1,"div",0),i.\u0275\u0275repeaterCreate(1,Ht,1,1,null,null,i.\u0275\u0275repeaterTrackByIdentity)),2&U&&(i.\u0275\u0275conditional(ee.viewModel.weekdays.length>0?0:-1),i.\u0275\u0275advance(),i.\u0275\u0275repeater(ee.viewModel.weeks))},dependencies:[Z.NgTemplateOutlet],styles:['ngb-datepicker-month{display:block}.ngb-dp-weekday,.ngb-dp-week-number{line-height:2rem;text-align:center;font-style:italic}.ngb-dp-weekday{color:var(--bs-info)}.ngb-dp-week{border-radius:.25rem;display:flex}.ngb-dp-weekdays{border-bottom:1px solid var(--bs-border-color);border-radius:0;background-color:var(--bs-tertiary-bg)}.ngb-dp-day,.ngb-dp-weekday,.ngb-dp-week-number{width:2rem;height:2rem}.ngb-dp-day{cursor:pointer}.ngb-dp-day.disabled,.ngb-dp-day.hidden{cursor:default;pointer-events:none}.ngb-dp-day[tabindex="0"]{z-index:1}\n'],encapsulation:2})}return V})(),zr=(()=>{class V{constructor(){this.injector=(0,i.inject)(i.Injector),this._service=(0,i.inject)(xt),this._calendar=(0,i.inject)(Ql),this._i18n=(0,i.inject)(re),this._config=(0,i.inject)(kn),this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._ngbDateAdapter=(0,i.inject)(vi),this._ngZone=(0,i.inject)(i.NgZone),this._destroyRef=(0,i.inject)(i.DestroyRef),this._injector=(0,i.inject)(i.Injector),this._controlValue=null,this._publicState={},this._initialized=!1,this.dayTemplate=this._config.dayTemplate,this.dayTemplateData=this._config.dayTemplateData,this.displayMonths=this._config.displayMonths,this.firstDayOfWeek=this._config.firstDayOfWeek,this.footerTemplate=this._config.footerTemplate,this.markDisabled=this._config.markDisabled,this.maxDate=this._config.maxDate,this.minDate=this._config.minDate,this.navigation=this._config.navigation,this.outsideDays=this._config.outsideDays,this.showWeekNumbers=this._config.showWeekNumbers,this.startDate=this._config.startDate,this.weekdays=this._config.weekdays,this.navigate=new i.EventEmitter,this.dateSelect=new i.EventEmitter,this.onChange=U=>{},this.onTouched=()=>{};const E=(0,i.inject)(i.ChangeDetectorRef);this._service.dateSelect$.pipe(X()).subscribe(U=>{this.dateSelect.emit(U)}),this._service.model$.pipe(X()).subscribe(U=>{const ee=U.firstDate,Xe=this.model?this.model.firstDate:null;this._publicState={maxDate:U.maxDate,minDate:U.minDate,firstDate:U.firstDate,lastDate:U.lastDate,focusedDate:U.focusDate,months:U.months.map(vo=>vo.firstDate)};let Nt=!1;if(!ee.equals(Xe)&&(this.navigate.emit({current:Xe?{year:Xe.year,month:Xe.month}:null,next:{year:ee.year,month:ee.month},preventDefault:()=>Nt=!0}),Nt&&null!==Xe))return void this._service.open(Xe);const Ei=U.selectedDate,gr=U.focusDate,ur=this.model?this.model.focusDate:null;this.model=U,ta(Ei,this._controlValue)&&(this._controlValue=Ei,this.onTouched(),this.onChange(this._ngbDateAdapter.toModel(Ei))),ta(gr,ur)&&ur&&U.focusVisible&&this.focus(),E.markForCheck()})}get state(){return this._publicState}get calendar(){return this._calendar}get i18n(){return this._i18n}focusDate(E){this._service.focus(sa.from(E))}focusSelect(){this._service.focusSelect()}focus(){(0,i.afterNextRender)(()=>{this._nativeElement.querySelector('div.ngb-dp-day[tabindex="0"]')?.focus()},{phase:i.AfterRenderPhase.Read,injector:this._injector})}navigateTo(E){this._service.open(sa.from(E?E.day?E:{...E,day:1}:null))}ngAfterViewInit(){this._ngZone.runOutsideAngular(()=>{const E=(0,e.fromEvent)(this._contentEl.nativeElement,"focusin"),U=(0,e.fromEvent)(this._contentEl.nativeElement,"focusout");(0,e.merge)(E,U).pipe((0,M.filter)(ee=>{const Xe=ee.target,Nt=ee.relatedTarget;return!(Xe?.classList.contains("ngb-dp-day")&&Nt?.classList.contains("ngb-dp-day")&&this._nativeElement.contains(Xe)&&this._nativeElement.contains(Nt))}),X(this._destroyRef)).subscribe(({type:ee})=>this._ngZone.run(()=>this._service.set({focusVisible:"focusin"===ee})))})}ngOnInit(){if(void 0===this.model){const E={};["dayTemplateData","displayMonths","markDisabled","firstDayOfWeek","navigation","minDate","maxDate","outsideDays","weekdays"].forEach(U=>E[U]=this[U]),this._service.set(E),this.navigateTo(this.startDate)}this.dayTemplate||(this.dayTemplate=this._defaultDayTemplate),this._initialized=!0}ngOnChanges(E){const U={};if(["dayTemplateData","displayMonths","markDisabled","firstDayOfWeek","navigation","minDate","maxDate","outsideDays","weekdays"].filter(ee=>ee in E).forEach(ee=>U[ee]=this[ee]),this._service.set(U),"startDate"in E&&this._initialized){const{currentValue:ee,previousValue:Xe}=E.startDate;vc(Xe,ee)&&this.navigateTo(this.startDate)}}onDateSelect(E){this._service.focus(E),this._service.select(E,{emitEvent:!0})}onNavigateDateSelect(E){this._service.open(E)}onNavigateEvent(E){switch(E){case Qt.PREV:this._service.open(this._calendar.getPrev(this.model.firstDate,"m",1));break;case Qt.NEXT:this._service.open(this._calendar.getNext(this.model.firstDate,"m",1))}}registerOnChange(E){this.onChange=E}registerOnTouched(E){this.onTouched=E}setDisabledState(E){this._service.set({disabled:E})}writeValue(E){this._controlValue=sa.from(this._ngbDateAdapter.fromModel(E)),this._service.select(this._controlValue)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-datepicker"]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,so,7),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.contentTemplateFromContent=Nt.first)}},viewQuery:function(U,ee){if(1&U&&(i.\u0275\u0275viewQuery(on,7),i.\u0275\u0275viewQuery(Cn,7)),2&U){let Xe;i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee._defaultDayTemplate=Xe.first),i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee._contentEl=Xe.first)}},hostVars:2,hostBindings:function(U,ee){2&U&&i.\u0275\u0275classProp("disabled",ee.model.disabled)},inputs:{contentTemplate:"contentTemplate",dayTemplate:"dayTemplate",dayTemplateData:"dayTemplateData",displayMonths:"displayMonths",firstDayOfWeek:"firstDayOfWeek",footerTemplate:"footerTemplate",markDisabled:"markDisabled",maxDate:"maxDate",minDate:"minDate",navigation:"navigation",outsideDays:"outsideDays",showWeekNumbers:"showWeekNumbers",startDate:"startDate",weekdays:"weekdays"},outputs:{navigate:"navigate",dateSelect:"dateSelect"},exportAs:["ngbDatepicker"],standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:ce.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>V),multi:!0},xt]),i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],decls:10,vars:9,consts:[["defaultDayTemplate",""],["defaultContentTemplate",""],["content",""],[1,"ngb-dp-header"],[3,"date","months","disabled","showSelect","prevDisabled","nextDisabled","selectBoxes"],[1,"ngb-dp-content"],[3,"ngTemplateOutlet","ngTemplateOutletContext","ngTemplateOutletInjector"],[3,"ngTemplateOutlet"],["ngbDatepickerDayView","",3,"date","currentMonth","selected","disabled","focused"],[1,"ngb-dp-month"],[1,"ngb-dp-month-name"],[3,"month"],[3,"navigate","select","date","months","disabled","showSelect","prevDisabled","nextDisabled","selectBoxes"]],template:function(U,ee){if(1&U&&(i.\u0275\u0275template(0,fi,1,5,"ng-template",null,0,i.\u0275\u0275templateRefExtractor)(2,gn,2,0,"ng-template",null,1,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275elementStart(4,"div",3),i.\u0275\u0275template(5,Nn,1,7,"ngb-datepicker-navigation",4),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(6,"div",5,2),i.\u0275\u0275template(8,Yn,0,0,"ng-template",6),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(9,cr,0,0,"ng-template",7)),2&U){const Xe=i.\u0275\u0275reference(3);i.\u0275\u0275advance(5),i.\u0275\u0275conditional("none"!==ee.navigation?5:-1),i.\u0275\u0275advance(),i.\u0275\u0275classProp("ngb-dp-months",!ee.contentTemplate),i.\u0275\u0275advance(2),i.\u0275\u0275property("ngTemplateOutlet",ee.contentTemplate||(null==ee.contentTemplateFromContent?null:ee.contentTemplateFromContent.templateRef)||Xe)("ngTemplateOutletContext",i.\u0275\u0275pureFunction1(7,tn,ee))("ngTemplateOutletInjector",ee.injector),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",ee.footerTemplate)}},dependencies:[Z.NgTemplateOutlet,$i,Fr,ai],styles:["ngb-datepicker{border:1px solid var(--bs-border-color);border-radius:.25rem;display:inline-block}ngb-datepicker-month{pointer-events:auto}ngb-datepicker.dropdown-menu{padding:0}ngb-datepicker.disabled .ngb-dp-weekday,ngb-datepicker.disabled .ngb-dp-week-number,ngb-datepicker.disabled .ngb-dp-month-name{color:var(--bs-text-muted)}.ngb-dp-body{z-index:1055}.ngb-dp-header{border-bottom:0;border-radius:.25rem .25rem 0 0;padding-top:.25rem;background-color:var(--bs-tertiary-bg)}.ngb-dp-months{display:flex}.ngb-dp-month{pointer-events:none}.ngb-dp-month-name{font-size:larger;height:2rem;line-height:2rem;text-align:center;background-color:var(--bs-tertiary-bg)}.ngb-dp-month+.ngb-dp-month .ngb-dp-month-name,.ngb-dp-month+.ngb-dp-month .ngb-dp-week{padding-left:1rem}.ngb-dp-month:last-child .ngb-dp-week{padding-right:.25rem}.ngb-dp-month:first-child .ngb-dp-week{padding-left:.25rem}.ngb-dp-month .ngb-dp-week:last-child{padding-bottom:.25rem}\n"],encapsulation:2,changeDetection:0})}return V})();const ho=(V,Qe)=>!!Qe&&Qe.some(E=>E.contains(V)),Vr=(V,Qe)=>!Qe||null!=function Ri(V,Qe){return!Qe||typeof V.closest>"u"?null:V.closest(Qe)}(V,Qe),is=typeof navigator<"u"&&!!navigator.userAgent&&(/iPad|iPhone|iPod/.test(navigator.userAgent)||/Macintosh/.test(navigator.userAgent)&&navigator.maxTouchPoints&&navigator.maxTouchPoints>2||/Android/.test(navigator.userAgent));function Ds(V,Qe,E,U,ee,Xe,Nt,Ei){E&&V.runOutsideAngular((V=>is?()=>setTimeout(()=>V(),100):V)(()=>{const ur=(0,e.fromEvent)(Qe,"keydown").pipe((0,M.takeUntil)(ee),(0,M.filter)(jo=>"Escape"===jo.key),(0,M.tap)(jo=>jo.preventDefault())),vo=(0,e.fromEvent)(Qe,"mousedown").pipe((0,M.map)(jo=>{const cs=jo.target;return 2!==jo.button&&!ho(cs,Nt)&&("inside"===E?ho(cs,Xe)&&Vr(cs,Ei):"outside"===E?!ho(cs,Xe):Vr(cs,Ei)||!ho(cs,Xe))}),(0,M.takeUntil)(ee)),Gr=(0,e.fromEvent)(Qe,"mouseup").pipe((0,M.withLatestFrom)(vo),(0,M.filter)(([jo,cs])=>cs),(0,M.delay)(0),(0,M.takeUntil)(ee));(0,e.race)([ur.pipe((0,M.map)(jo=>0)),Gr.pipe((0,M.map)(jo=>1))]).subscribe(jo=>V.run(()=>U(jo)))}))}const Xo=["a[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","[contenteditable]",'[tabindex]:not([tabindex="-1"])'].join(", ");function na(V){const Qe=Array.from(V.querySelectorAll(Xo)).filter(E=>-1!==E.tabIndex);return[Qe[0],Qe[Qe.length-1]]}const zs=(V,Qe,E,U=!1)=>{V.runOutsideAngular(()=>{const ee=(0,e.fromEvent)(Qe,"focusin").pipe((0,M.takeUntil)(E),(0,M.map)(Xe=>Xe.target));(0,e.fromEvent)(Qe,"keydown").pipe((0,M.takeUntil)(E),(0,M.filter)(Xe=>"Tab"===Xe.key),(0,M.withLatestFrom)(ee)).subscribe(([Xe,Nt])=>{const[Ei,gr]=na(Qe);(Nt===Ei||Nt===Qe)&&Xe.shiftKey&&(gr.focus(),Xe.preventDefault()),Nt===gr&&!Xe.shiftKey&&(Ei.focus(),Xe.preventDefault())}),U&&(0,e.fromEvent)(Qe,"click").pipe((0,M.takeUntil)(E),(0,M.withLatestFrom)(ee),(0,M.map)(Xe=>Xe[1])).subscribe(Xe=>Xe.focus())})};let ya=(()=>{class V{constructor(){this._element=(0,i.inject)(Z.DOCUMENT).documentElement}isRTL(){return"rtl"===(this._element.getAttribute("dir")||"").toLowerCase()}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();const Je=/\s+/,at=/ +/gi,Oe={top:["top"],bottom:["bottom"],start:["left","right"],left:["left"],end:["right","left"],right:["right"],"top-start":["top-start","top-end"],"top-left":["top-start"],"top-end":["top-end","top-start"],"top-right":["top-end"],"bottom-start":["bottom-start","bottom-end"],"bottom-left":["bottom-start"],"bottom-end":["bottom-end","bottom-start"],"bottom-right":["bottom-end"],"start-top":["left-start","right-start"],"left-top":["left-start"],"start-bottom":["left-end","right-end"],"left-bottom":["left-end"],"end-top":["right-start","left-start"],"right-top":["right-start"],"end-bottom":["right-end","left-end"],"right-bottom":["right-end"]},On=/^left/,_i=/^right/,Qn=/^start/,qi=/^end/;function fo({placement:V,baseClass:Qe},E){let U=Array.isArray(V)?V:V.split(Je),Xe=U.findIndex(ur=>"auto"===ur);Xe>=0&&["top","bottom","start","end","top-start","top-end","bottom-start","bottom-end","start-top","start-bottom","end-top","end-bottom"].forEach(function(ur){null==U.find(vo=>-1!==vo.search("^"+ur))&&U.splice(Xe++,1,ur)});const Nt=U.map(ur=>function Ct(V,Qe){const[E,U]=Oe[V];return Qe&&U||E}(ur,E.isRTL()));return{placement:Nt.shift(),modifiers:[{name:"bootstrapClasses",enabled:!!Qe,phase:"write",fn({state:ur}){const vo=new RegExp(Qe+"(-[a-z]+)*","gi"),Gr=ur.elements.popper,jo=ur.placement;let cs=Gr.className;cs=cs.replace(vo,""),cs+=` ${function Di(V,Qe){let[E,U]=Qe.split("-");const ee=E.replace(On,"start").replace(_i,"end");let Xe=[ee];if(U){let Nt=U;("left"===E||"right"===E)&&(Nt=Nt.replace(Qn,"top").replace(qi,"bottom")),Xe.push(`${ee}-${Nt}`)}return V&&(Xe=Xe.map(Nt=>`${V}-${Nt}`)),Xe.join(" ")}(Qe,jo)}`,cs=cs.trim().replace(at," "),Gr.className=cs}},le.flip,le.preventOverflow,le.arrow,{enabled:!0,name:"flip",options:{fallbackPlacements:Nt}},{enabled:!0,name:"preventOverflow",phase:"main",fn:function(){}}]}}function Uo(V){return V}function Gs(){const V=(0,i.inject)(ya);let Qe=null;return{createPopper(E){if(!Qe){let ee=(E.updatePopperOptions||Uo)(fo(E,V));Qe=(0,le.createPopperLite)(E.hostElement,E.targetElement,ee)}},update(){Qe&&Qe.update()},setOptions(E){if(Qe){let ee=(E.updatePopperOptions||Uo)(fo(E,V));Qe.setOptions(ee)}},destroy(){Qe&&(Qe.destroy(),Qe=null)}}}let Za=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>function ba(){return new Ks}(),providedIn:"root"})}return V})(),Ks=(()=>{class V extends Za{parse(E){if(null!=E){const U=E.trim().split("-");if(1===U.length&&ar(U[0]))return{year:Rt(U[0]),month:null,day:null};if(2===U.length&&ar(U[0])&&ar(U[1]))return{year:Rt(U[0]),month:Rt(U[1]),day:null};if(3===U.length&&ar(U[0])&&ar(U[1])&&ar(U[2]))return{year:Rt(U[0]),month:Rt(U[1]),day:Rt(U[2])}}return null}format(E){return E?`${E.year}-${ar(E.month)?cn(E.month):""}-${ar(E.day)?cn(E.day):""}`:""}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),ac=(()=>{class V extends kn{constructor(){super(...arguments),this.autoClose=!0,this.placement=["bottom-start","bottom-end","top-start","top-end"],this.popperOptions=E=>E,this.restoreFocus=!0}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();function lc(V){return Qe=>(Qe.modifiers.push(le.offset,{name:"offset",options:{offset:()=>V}}),Qe)}let ou=(()=>{class V{constructor(){this._parserFormatter=(0,i.inject)(Za),this._elRef=(0,i.inject)(i.ElementRef),this._vcRef=(0,i.inject)(i.ViewContainerRef),this._ngZone=(0,i.inject)(i.NgZone),this._calendar=(0,i.inject)(Ql),this._dateAdapter=(0,i.inject)(vi),this._document=(0,i.inject)(Z.DOCUMENT),this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._injector=(0,i.inject)(i.Injector),this._config=(0,i.inject)(ac),this._cRef=null,this._disabled=!1,this._elWithFocus=null,this._model=null,this._positioning=Gs(),this._destroyCloseHandlers$=new e.Subject,this.autoClose=this._config.autoClose,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.container=this._config.container,this.positionTarget=this._config.positionTarget,this.dateSelect=new i.EventEmitter,this.navigate=new i.EventEmitter,this.closed=new i.EventEmitter,this._onChange=E=>{},this._onTouched=()=>{},this._validatorChange=()=>{}}get disabled(){return this._disabled}set disabled(E){this._disabled=""===E||E&&"false"!==E,this.isOpen()&&this._cRef.instance.setDisabledState(this._disabled)}registerOnChange(E){this._onChange=E}registerOnTouched(E){this._onTouched=E}registerOnValidatorChange(E){this._validatorChange=E}setDisabledState(E){this.disabled=E}validate(E){const{value:U}=E;if(null!=U){const ee=this._fromDateStruct(this._dateAdapter.fromModel(U));if(!ee)return{ngbDate:{invalid:U}};if(this.minDate&&ee.before(sa.from(this.minDate)))return{ngbDate:{minDate:{minDate:this.minDate,actual:U}}};if(this.maxDate&&ee.after(sa.from(this.maxDate)))return{ngbDate:{maxDate:{maxDate:this.maxDate,actual:U}}}}return null}writeValue(E){this._model=this._fromDateStruct(this._dateAdapter.fromModel(E)),this._writeModelValue(this._model)}manualDateChange(E,U=!1){const ee=E!==this._inputValue;ee&&(this._inputValue=E,this._model=this._fromDateStruct(this._parserFormatter.parse(E))),(ee||!U)&&this._onChange(this._model?this._dateAdapter.toModel(this._model):""===E?null:E),U&&this._model&&this._writeModelValue(this._model)}isOpen(){return!!this._cRef}open(){if(!this.isOpen()){let E;if(this._cRef=this._vcRef.createComponent(zr,{injector:this._injector}),this._applyPopupStyling(this._cRef.location.nativeElement),this._applyDatepickerInputs(this._cRef),this._subscribeForDatepickerOutputs(this._cRef.instance),this._cRef.instance.ngOnInit(),this._cRef.instance.writeValue(this._dateAdapter.toModel(this._model)),this._cRef.instance.registerOnChange(U=>{this.writeValue(U),this._onChange(U),this._onTouched()}),this._cRef.changeDetectorRef.detectChanges(),this._cRef.instance.setDisabledState(this.disabled),"body"===this.container&&this._document.querySelector(this.container)?.appendChild(this._cRef.location.nativeElement),this._elWithFocus=this._document.activeElement,zs(this._ngZone,this._cRef.location.nativeElement,this.closed,!0),setTimeout(()=>this._cRef?.instance.focus()),E=Ui(this.positionTarget)?this._document.querySelector(this.positionTarget):this.positionTarget instanceof HTMLElement?this.positionTarget:this._elRef.nativeElement,this.positionTarget&&!E)throw new Error("ngbDatepicker could not find element declared in [positionTarget] to position against.");this._ngZone.runOutsideAngular(()=>{this._cRef&&E&&(this._positioning.createPopper({hostElement:E,targetElement:this._cRef.location.nativeElement,placement:this.placement,updatePopperOptions:U=>this.popperOptions(lc([0,2])(U))}),this._afterRenderRef=(0,i.afterRender)(()=>{this._positioning.update()},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector}))}),this._setCloseHandlers()}}close(){if(this.isOpen()){this._cRef?.destroy(),this._cRef=null,this._positioning.destroy(),this._afterRenderRef?.destroy(),this._destroyCloseHandlers$.next(),this.closed.emit(),this._changeDetector.markForCheck();let E=this._elWithFocus;Ui(this.restoreFocus)?E=this._document.querySelector(this.restoreFocus):void 0!==this.restoreFocus&&(E=this.restoreFocus),E&&E.focus?E.focus():this._document.body.focus()}}toggle(){this.isOpen()?this.close():this.open()}navigateTo(E){this.isOpen()&&this._cRef.instance.navigateTo(E)}onBlur(){this._onTouched()}onFocus(){this._elWithFocus=this._elRef.nativeElement}ngOnChanges(E){if((E.minDate||E.maxDate)&&(this._validatorChange(),this.isOpen()&&(E.minDate&&this._cRef.setInput("minDate",this.minDate),E.maxDate&&this._cRef.setInput("maxDate",this.maxDate))),E.datepickerClass){const{currentValue:U,previousValue:ee}=E.datepickerClass;this._applyPopupClass(U,ee)}E.autoClose&&this.isOpen()&&this._setCloseHandlers()}ngOnDestroy(){this.close()}_applyDatepickerInputs(E){["contentTemplate","dayTemplate","dayTemplateData","displayMonths","firstDayOfWeek","footerTemplate","markDisabled","minDate","maxDate","navigation","outsideDays","showNavigation","showWeekNumbers","weekdays"].forEach(U=>{void 0!==this[U]&&E.setInput(U,this[U])}),E.setInput("startDate",this.startDate||this._model)}_applyPopupClass(E,U){const ee=this._cRef?.location.nativeElement;ee&&(E&&ee.classList.add(E),U&&ee.classList.remove(U))}_applyPopupStyling(E){E.classList.add("dropdown-menu","show"),"body"===this.container&&E.classList.add("ngb-dp-body"),this._applyPopupClass(this.datepickerClass)}_subscribeForDatepickerOutputs(E){E.navigate.subscribe(U=>this.navigate.emit(U)),E.dateSelect.subscribe(U=>{this.dateSelect.emit(U),(!0===this.autoClose||"inside"===this.autoClose)&&this.close()})}_writeModelValue(E){const U=this._parserFormatter.format(E);this._inputValue=U,this._elRef.nativeElement.value=U,this.isOpen()&&(this._cRef.instance.writeValue(this._dateAdapter.toModel(E)),this._onTouched())}_fromDateStruct(E){const U=E?new sa(E.year,E.month,E.day):null;return this._calendar.isValid(U)?U:null}_setCloseHandlers(){this._destroyCloseHandlers$.next(),Ds(this._ngZone,this._document,this.autoClose,()=>this.close(),this._destroyCloseHandlers$,[],[this._elRef.nativeElement,this._cRef.location.nativeElement])}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["input","ngbDatepicker",""]],hostVars:1,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("input",function(Nt){return ee.manualDateChange(Nt.target.value)})("change",function(Nt){return ee.manualDateChange(Nt.target.value,!0)})("focus",function(){return ee.onFocus()})("blur",function(){return ee.onBlur()}),2&U&&i.\u0275\u0275hostProperty("disabled",ee.disabled)},inputs:{autoClose:"autoClose",contentTemplate:"contentTemplate",datepickerClass:"datepickerClass",dayTemplate:"dayTemplate",dayTemplateData:"dayTemplateData",displayMonths:"displayMonths",firstDayOfWeek:"firstDayOfWeek",footerTemplate:"footerTemplate",markDisabled:"markDisabled",minDate:"minDate",maxDate:"maxDate",navigation:"navigation",outsideDays:"outsideDays",placement:"placement",popperOptions:"popperOptions",restoreFocus:"restoreFocus",showWeekNumbers:"showWeekNumbers",startDate:"startDate",container:"container",positionTarget:"positionTarget",weekdays:"weekdays",disabled:"disabled"},outputs:{dateSelect:"dateSelect",navigate:"navigate",closed:"closed"},exportAs:["ngbDatepicker"],standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:ce.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>V),multi:!0},{provide:ce.NG_VALIDATORS,useExisting:(0,i.forwardRef)(()=>V),multi:!0},{provide:kn,useExisting:ac}]),i.\u0275\u0275NgOnChangesFeature]})}return V})(),qd=(()=>{class V extends Ql{getDaysPerWeek(){return 7}getMonths(){return[1,2,3,4,5,6,7,8,9,10,11,12]}getWeeksPerMonth(){return 6}getNext(E,U="d",ee=1){switch(E=new sa(E.year,E.month,E.day),U){case"y":return(E=this._setYear(E,E.year+ee)).month=1,E.day=1,E;case"m":return(E=this._setMonth(E,E.month+ee)).day=1,E;case"d":return this._setDay(E,E.day+ee);default:return E}}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){const U=this.toGregorian(E).getDay();return 0===U?7:U}getWeekNumber(E,U){7===U&&(U=0);const Xe=E[(11-U)%7],Nt=this.toGregorian(Xe);Nt.setDate(Nt.getDate()+4-(Nt.getDay()||7));const Ei=Nt.getTime(),gr=this.toGregorian(new sa(Xe.year,1,1));return Math.floor(Math.round((Ei-gr.getTime())/864e5)/7)+1}getToday(){return this.fromGregorian(new Date)}isValid(E){return null!=E&&ar(E.year)&&ar(E.month)&&ar(E.day)&&!isNaN(this.toGregorian(E).getTime())}_setDay(E,U){U=+U;let ee=this.getDaysPerMonth(E.month,E.year);if(U<=0)for(;U<=0;)E=this._setMonth(E,E.month-1),ee=this.getDaysPerMonth(E.month,E.year),U+=ee;else if(U>ee)for(;U>ee;)U-=ee,E=this._setMonth(E,E.month+1),ee=this.getDaysPerMonth(E.month,E.year);return E.day=U,E}_setMonth(E,U){return U=+U,E.year=E.year+Math.floor((U-1)/12),E.month=Math.floor(((U-1)%12+12)%12)+1,E}_setYear(E,U){return E.year=+U,E}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();function nd(V){const Qe=V.getFullYear();return Qe%4==0&&Qe%100!=0||Qe%400==0}function _c(V,Qe){return V-Qe*Math.floor(V/Qe)}const cc=1721425.5,qf=1948439.5;let aa=(()=>{class V extends qd{fromGregorian(E){const U=E.getFullYear(),ee=E.getMonth(),Xe=E.getDate();let Nt=cc-1+365*(U-1)+Math.floor((U-1)/4)+-Math.floor((U-1)/100)+Math.floor((U-1)/400)+Math.floor((367*(ee+1)-362)/12+(ee+1<=2?0:nd(E)?-1:-2)+Xe);Nt=Math.floor(Nt)+.5;const Ei=Nt-qf,gr=Math.floor((30*Ei+10646)/10631);let ur=Math.ceil((Ei-29-function bl(V){return 354*(V-1)+Math.floor((3+11*V)/30)}(gr))/29.5);ur=Math.min(ur,11);const vo=Math.ceil(Ei-function xp(V,Qe){return Math.ceil(29.5*Qe)+354*(V-1)+Math.floor((3+11*V)/30)}(gr,ur))+1;return new sa(gr,ur+1,vo)}toGregorian(E){const U=E.year,Nt=E.day+Math.ceil(29.5*(E.month-1))+354*(U-1)+Math.floor((3+11*U)/30)+qf-1,Ei=Math.floor(Nt-.5)+.5,gr=Ei-cc,ur=Math.floor(gr/146097),vo=_c(gr,146097),Gr=Math.floor(vo/36524),jo=_c(vo,36524),cs=Math.floor(jo/1461),el=_c(jo,1461),gu=Math.floor(el/365);let Zl=400*ur+100*Gr+4*cs+gu;4===Gr||4===gu||Zl++;const qa=Ei-(cc+365*(Zl-1)+Math.floor((Zl-1)/4)-Math.floor((Zl-1)/100)+Math.floor((Zl-1)/400)),Pm=Ei<cc-1+365*(Zl-1)+Math.floor((Zl-1)/4)-Math.floor((Zl-1)/100)+Math.floor((Zl-1)/400)+Math.floor(739/12+(nd(new Date(Zl,3,1))?-1:-2)+1)?0:nd(new Date(Zl,3,1))?1:2,nh=Math.floor((12*(qa+Pm)+373)/367),ih=cc-1+365*(Zl-1)+Math.floor((Zl-1)/4)-Math.floor((Zl-1)/100)+Math.floor((Zl-1)/400)+Math.floor((367*nh-362)/12+(nh<=2?0:nd(new Date(Zl,nh-1,1))?-1:-2)+1);return new Date(Zl,nh-1,Ei-ih+1)}getDaysPerMonth(E,U){U+=Math.floor(E/13);let ee=29+(E=(E-1)%12+1)%2;return 12===E&&function da(V){return(14+11*V)%30<11}(U)&&ee++,ee}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const Tc=new Date(1882,10,12),Ra=new Date(2174,10,25),hd=1300,tc=["101010101010","110101010100","111011001001","011011010100","011011101010","001101101100","101010101101","010101010101","011010101001","011110010010","101110101001","010111010100","101011011010","010101011100","110100101101","011010010101","011101001010","101101010100","101101101010","010110101101","010010101110","101001001111","010100010111","011010001011","011010100101","101011010101","001011010110","100101011011","010010011101","101001001101","110100100110","110110010101","010110101100","100110110110","001010111010","101001011011","010100101011","101010010101","011011001010","101011101001","001011110100","100101110110","001010110110","100101010110","101011001010","101110100100","101111010010","010111011001","001011011100","100101101101","010101001101","101010100101","101101010010","101110100101","010110110100","100110110110","010101010111","001010010111","010101001011","011010100011","011101010010","101101100101","010101101010","101010101011","010100101011","110010010101","110101001010","110110100101","010111001010","101011010110","100101010111","010010101011","100101001011","101010100101","101101010010","101101101010","010101110101","001001110110","100010110111","010001011011","010101010101","010110101001","010110110100","100111011010","010011011101","001001101110","100100110110","101010101010","110101010100","110110110010","010111010101","001011011010","100101011011","010010101011","101001010101","101101001001","101101100100","101101110001","010110110100","101010110101","101001010101","110100100101","111010010010","111011001001","011011010100","101011101001","100101101011","010010101011","101010010011","110101001001","110110100100","110110110010","101010111001","010010111010","101001011011","010100101011","101010010101","101100101010","101101010101","010101011100","010010111101","001000111101","100100011101","101010010101","101101001010","101101011010","010101101101","001010110110","100100111011","010010011011","011001010101","011010101001","011101010100","101101101010","010101101100","101010101101","010101010101","101100101001","101110010010","101110101001","010111010100","101011011010","010101011010","101010101011","010110010101","011101001001","011101100100","101110101010","010110110101","001010110110","101001010110","111001001101","101100100101","101101010010","101101101010","010110101101","001010101110","100100101111","010010010111","011001001011","011010100101","011010101100","101011010110","010101011101","010010011101","101001001101","110100010110","110110010101","010110101010","010110110101","001011011010","100101011011","010010101101","010110010101","011011001010","011011100100","101011101010","010011110101","001010110110","100101010110","101010101010","101101010100","101111010010","010111011001","001011101010","100101101101","010010101101","101010010101","101101001010","101110100101","010110110010","100110110101","010011010110","101010010111","010101000111","011010010011","011101001001","101101010101","010101101010","101001101011","010100101011","101010001011","110101000110","110110100011","010111001010","101011010110","010011011011","001001101011","100101001011","101010100101","101101010010","101101101001","010101110101","000101110110","100010110111","001001011011","010100101011","010101100101","010110110100","100111011010","010011101101","000101101101","100010110110","101010100110","110101010010","110110101001","010111010100","101011011010","100101011011","010010101011","011001010011","011100101001","011101100010","101110101001","010110110010","101010110101","010101010101","101100100101","110110010010","111011001001","011011010010","101011101001","010101101011","010010101011","101001010101","110100101001","110101010100","110110101010","100110110101","010010111010","101000111011","010010011011","101001001101","101010101010","101011010101","001011011010","100101011101","010001011110","101000101110","110010011010","110101010101","011010110010","011010111001","010010111010","101001011101","010100101101","101010010101","101101010010","101110101000","101110110100","010110111001","001011011010","100101011010","101101001010","110110100100","111011010001","011011101000","101101101010","010101101101","010100110101","011010010101","110101001010","110110101000","110111010100","011011011010","010101011011","001010011101","011000101011","101100010101","101101001010","101110010101","010110101010","101010101110","100100101110","110010001111","010100100111","011010010101","011010101010","101011010110","010101011101","001010011101"];let Su=(()=>{class V extends aa{fromGregorian(E){let U=1,ee=0,Xe=1300,Nt=function Qh(V,Qe){const E=Date.UTC(V.getFullYear(),V.getMonth(),V.getDate()),U=Date.UTC(Qe.getFullYear(),Qe.getMonth(),Qe.getDate()),ee=Math.abs(E-U);return Math.round(ee/864e5)}(E,Tc);if(E.getTime()-Tc.getTime()>=0&&E.getTime()-Ra.getTime()<=0){let Ei=1300;for(let gr=0;gr<tc.length;gr++,Ei++)for(let ur=0;ur<12;ur++){let vo=+tc[gr][ur]+29;if(Nt<=vo)return U=Nt+1,U>vo&&(U=1,ur++),ur>11&&(ur=0,Ei++),ee=ur,Xe=Ei,new sa(Xe,ee+1,U);Nt-=vo}return null}return super.fromGregorian(E)}toGregorian(E){const U=E.year,ee=E.month-1,Xe=E.day;let Nt=new Date(Tc),Ei=Xe-1;if(U>=hd&&U<=1600){for(let gr=0;gr<U-hd;gr++)for(let ur=0;ur<12;ur++)Ei+=+tc[gr][ur]+29;for(let gr=0;gr<ee;gr++)Ei+=+tc[U-hd][gr]+29;Nt.setDate(Tc.getDate()+Ei)}else Nt=super.toGregorian(E);return Nt}getDaysPerMonth(E,U){return U>=hd&&U<=1600?+tc[U-hd][E-1]+29:super.getDaysPerMonth(E,U)}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();function md(V){let Qe=function xa(V,Qe,E){let U=Xc(V);return su(U.gy,3,U.march)+31*(Qe-1)-qs(Qe,7)*(Qe-7)+E-1}(V.year,V.month,V.day),E=Bu(Qe);return E.setHours(6,30,3,200),E}function Eu(V,Qe){return Qe=+Qe,V.year=V.year+Math.floor((Qe-1)/12),V.month=Math.floor(((Qe-1)%12+12)%12)+1,V}function Lc(V,Qe){return V-Qe*Math.floor(V/Qe)}function qs(V,Qe){return Math.trunc(V/Qe)}function Xc(V){let Qe=[-61,9,38,199,426,686,756,818,1111,1181,1210,1635,2060,2097,2192,2262,2324,2394,2456,3178];const E=Qe.length,U=V+621;let Nt,ee=-14,Xe=Qe[0];if(V<Xe||V>=Qe[E-1])throw new Error("Invalid Jalali year "+V);for(let Gr=1;Gr<E;Gr+=1){const jo=Qe[Gr];if(Nt=jo-Xe,V<jo)break;ee=ee+8*qs(Nt,33)+qs(Lc(Nt,33),4),Xe=jo}let Ei=V-Xe;ee=ee+8*qs(Ei,33)+qs(Lc(Ei,33)+3,4),4===Lc(Nt,33)&&Nt-Ei==4&&(ee+=1);const ur=20+ee-(qs(U,4)-qs(3*(qs(U,100)+1),4)-150);Nt-Ei<6&&(Ei=Ei-Nt+33*qs(Nt+4,33));let vo=Lc(Lc(Ei+1,33)-1,4);return-1===vo&&(vo=4),{leap:vo,gy:U,march:ur}}function Bu(V){let Qe=4*V+139361631;Qe=Qe+4*qs(3*qs(4*V+183187720,146097),4)-3908;const E=5*qs(Lc(Qe,1461),4)+308,U=qs(Lc(E,153),5)+1,ee=Lc(qs(E,153),12)+1,Xe=qs(Qe,1461)-100100+qs(8-ee,6);return new Date(Xe,ee-1,U)}function su(V,Qe,E){let U=qs(1461*(V+qs(Qe-8,6)+100100),4)+qs(153*Lc(Qe+9,12)+2,5)+E-34840408;return U=U-qs(3*qs(V+100100+qs(Qe-8,6),100),4)+752,U}function vd(V,Qe){return V<=6?31:V<=11||0===Xc(Qe).leap?30:29}let Vu=(()=>{class V extends Ql{getDaysPerWeek(){return 7}getMonths(){return[1,2,3,4,5,6,7,8,9,10,11,12]}getWeeksPerMonth(){return 6}getNext(E,U="d",ee=1){switch(E=new sa(E.year,E.month,E.day),U){case"y":return E=function gd(V,Qe){return V.year=+Qe,V}(E,E.year+ee),E.month=1,E.day=1,E;case"m":return(E=Eu(E,E.month+ee)).day=1,E;case"d":return function Pu(V,Qe){let E=vd(V.month,V.year);if(Qe<=0)for(;Qe<=0;)E=vd((V=Eu(V,V.month-1)).month,V.year),Qe+=E;else if(Qe>E)for(;Qe>E;)Qe-=E,E=vd((V=Eu(V,V.month+1)).month,V.year);return V.day=Qe,V}(E,E.day+ee);default:return E}}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){const U=md(E).getDay();return 0===U?7:U}getWeekNumber(E,U){7===U&&(U=0);const Xe=E[(11-U)%7],Nt=md(Xe);Nt.setDate(Nt.getDate()+4-(Nt.getDay()||7));const Ei=Nt.getTime(),gr=md(new sa(Xe.year,1,1));return Math.floor(Math.round((Ei-gr.getTime())/864e5)/7)+1}getToday(){return function Ld(V){return function Is(V){let Xe,Nt,Ei,Qe=Bu(V).getFullYear(),E=Qe-621,U=Xc(E);if(Ei=V-su(Qe,3,U.march),Ei>=0){if(Ei<=185)return Nt=1+qs(Ei,31),Xe=Lc(Ei,31)+1,new sa(E,Nt,Xe);Ei-=186}else E-=1,Ei+=179,1===U.leap&&(Ei+=1);return Nt=7+qs(Ei,30),Xe=Lc(Ei,30)+1,new sa(E,Nt,Xe)}(su(V.getFullYear(),V.getMonth()+1,V.getDate()))}(new Date)}isValid(E){return null!=E&&er(E.year)&&er(E.month)&&er(E.day)&&!isNaN(md(E).getTime())}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const id=1080,Sd=24*id,pu=12*id+793,hu=29*Sd+pu,As=11*id+204;function El(V){return V%4==0&&V%100!=0||V%400==0}function uc(V){let Qe=Math.floor((235*V-234)/19),E=Qe*pu+As,U=29*Qe+Math.floor(E/Sd),ee=E%Sd,Xe=U%7;return(2===Xe||4===Xe||6===Xe)&&(U++,Xe=U%7),1===Xe&&ee>15*id+204&&!ju(V)?U+=2:0===Xe&&ee>21*id+589&&ju(V-1)&&U++,U}function kd(V,Qe){let E=[31,28,31,30,31,30,31,31,30,31,30,31];return El(Qe)&&E[1]++,E[V-1]}function Td(V){return ju(V)?13:12}function Pc(V){return uc(V+1)-uc(V)}function ju(V){if(null!=V){let Qe=(12*V+17)%19;return Qe>=(Qe<0?-7:12)}return!1}function Yl(V,Qe){let E=uc(Qe+1)-uc(Qe),U=(E<=380?E:E-30)-353,Xe=ju(Qe)?[30,29,29,29,30,30,29,30,29,30,29,30,29]:[30,29,29,29,30,29,30,29,30,29,30,29];return U>0&&Xe[2]++,U>1&&Xe[1]++,Xe[V-1]}function Bc(V){let Qe=0;for(let E=1;E<V.month;E++)Qe+=Yl(E,V.year);return Qe+V.day}function _e(V){const Qe=new Date(V),E=Qe.getFullYear(),U=Qe.getMonth(),ee=Qe.getDate();let Xe=1721424.5+365*(E-1)+Math.floor((E-1)/4)-Math.floor((E-1)/100)+Math.floor((E-1)/400)+Math.floor((367*(U+1)-362)/12+(U+1<=2?0:El(E)?-1:-2)+ee);Xe=Math.floor(Xe+.5);let Nt=Xe-347997,Ei=Math.floor(Nt*Sd/hu),gr=Math.floor((19*Ei+234)/235)+1,ur=uc(gr),vo=Nt-ur;for(;vo<1;)gr--,ur=uc(gr),vo=Nt-ur;let Gr=1,jo=vo;for(;jo>Yl(Gr,gr);)jo-=Yl(Gr,gr),Gr++;return new sa(gr,Gr,jo)}function Dt(V){const Qe=V.year,E=V.month,U=V.day;let ee=uc(Qe);for(let vo=1;vo<E;vo++)ee+=Yl(vo,Qe);ee+=U;let Xe=ee-2092591,Nt=Xe>=0;Nt||(Xe=-Xe);let Ei=1970,gr=1,ur=1;for(;Xe>0;)Nt?Xe>=(El(Ei)?366:365)?(Xe-=El(Ei)?366:365,Ei++):Xe>=kd(gr,Ei)?(Xe-=kd(gr,Ei),gr++):(ur+=Xe,Xe=0):Xe>=(El(Ei-1)?366:365)?(Xe-=El(Ei-1)?366:365,Ei--):(gr>1?gr--:(gr=12,Ei--),Xe>=kd(gr,Ei)?Xe-=kd(gr,Ei):(ur=kd(gr,Ei)-Xe+1,Xe=0));return new Date(Ei,gr-1,ur)}function Re(V){if(!V)return"";const Qe=["","\u05d0","\u05d1","\u05d2","\u05d3","\u05d4","\u05d5","\u05d6","\u05d7","\u05d8"],E=["\u05d9","\u05d9\u05d0","\u05d9\u05d1","\u05d9\u05d2","\u05d9\u05d3","\u05d8\u05d5","\u05d8\u05d6","\u05d9\u05d6","\u05d9\u05d7","\u05d9\u05d8"],U=["","","\u05db","\u05dc","\u05de","\u05e0","\u05e1","\u05e2","\u05e4","\u05e6"],ee=["","\u05e7","\u05e8","\u05e9","\u05ea","\u05ea\u05e7","\u05ea\u05e8","\u05ea\u05e9","\u05ea\u05ea","\u05ea\u05ea\u05e7"],Xe=["","\u05d0","\u05d1","\u05d1\u05d0","\u05d1\u05d1","\u05d4","\u05d4\u05d0","\u05d4\u05d1","\u05d4\u05d1\u05d0","\u05d4\u05d1\u05d1"];let gr=0,ur=[],vo=0;for(;V>0;){let Gr=V%10;if(0===vo)gr=Gr;else if(1===vo)1!==Gr?ur.unshift(U[Gr],Qe[gr]):ur.unshift(E[gr]);else{if(2!==vo){5!==Gr&&ur.unshift(Xe[Gr],"\u05f3"," ");break}ur.unshift(ee[Gr])}V=Math.floor(V/10),0===vo&&0===V&&ur.unshift(Qe[Gr]),vo++}return ur=ur.join("").split(""),1===ur.length?ur.push("\u05f3"):ur.length>1&&ur.splice(ur.length-1,0,"\u05f4"),ur.join("")}let tt=(()=>{class V extends Ql{getDaysPerWeek(){return 7}getMonths(E){return E&&ju(E)?[1,2,3,4,5,6,7,8,9,10,11,12,13]:[1,2,3,4,5,6,7,8,9,10,11,12]}getWeeksPerMonth(){return 6}isValid(E){if(null!=E){let U=ar(E.year)&&ar(E.month)&&ar(E.day);return U=U&&E.month>0&&E.month<=(ju(E.year)?13:12),U=U&&E.day>0&&E.day<=Yl(E.month,E.year),U&&!isNaN(Dt(E).getTime())}return!1}getNext(E,U="d",ee=1){switch(E=new sa(E.year,E.month,E.day),U){case"y":return E.year+=ee,E.month=1,E.day=1,E;case"m":return E=function pf(V,Qe){let E=Qe>=0;for(E||(Qe=-Qe);Qe>0;)E?Qe>Td(V.year)-V.month?(Qe-=Td(V.year)-V.month+1,V.year++,V.month=1):(V.month+=Qe,Qe=0):Qe>=V.month?(V.year--,Qe-=V.month,V.month=Td(V.year)):(V.month-=Qe,Qe=0);return V}(E,ee),E.day=1,E;case"d":return function hf(V,Qe){let E=Qe>=0;for(E||(Qe=-Qe);Qe>0;)E?Qe>Pc(V.year)-Bc(V)?(Qe-=Pc(V.year)-Bc(V)+1,V.year++,V.month=1,V.day=1):Qe>Yl(V.month,V.year)-V.day?(Qe-=Yl(V.month,V.year)-V.day+1,V.month++,V.day=1):(V.day+=Qe,Qe=0):Qe>=V.day?(Qe-=V.day,V.month--,0===V.month&&(V.year--,V.month=Td(V.year)),V.day=Yl(V.month,V.year)):(V.day-=Qe,Qe=0);return V}(E,ee);default:return E}}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){const U=Dt(E).getDay();return 0===U?7:U}getWeekNumber(E,U){return Math.ceil(Bc(E[E.length-1])/7)}getToday(){return _e(new Date)}toGregorian(E){return Lu(Dt(E))}fromGregorian(E){return _e(Aa(E))}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const mn=["\u05e9\u05e0\u05d9","\u05e9\u05dc\u05d9\u05e9\u05d9","\u05e8\u05d1\u05d9\u05e2\u05d9","\u05d7\u05de\u05d9\u05e9\u05d9","\u05e9\u05d9\u05e9\u05d9","\u05e9\u05d1\u05ea","\u05e8\u05d0\u05e9\u05d5\u05df"],gi=["\u05ea\u05e9\u05e8\u05d9","\u05d7\u05e9\u05d5\u05df","\u05db\u05e1\u05dc\u05d5","\u05d8\u05d1\u05ea","\u05e9\u05d1\u05d8","\u05d0\u05d3\u05e8","\u05e0\u05d9\u05e1\u05df","\u05d0\u05d9\u05d9\u05e8","\u05e1\u05d9\u05d5\u05df","\u05ea\u05de\u05d5\u05d6","\u05d0\u05d1","\u05d0\u05dc\u05d5\u05dc"],rr=["\u05ea\u05e9\u05e8\u05d9","\u05d7\u05e9\u05d5\u05df","\u05db\u05e1\u05dc\u05d5","\u05d8\u05d1\u05ea","\u05e9\u05d1\u05d8","\u05d0\u05d3\u05e8 \u05d0\u05f3","\u05d0\u05d3\u05e8 \u05d1\u05f3","\u05e0\u05d9\u05e1\u05df","\u05d0\u05d9\u05d9\u05e8","\u05e1\u05d9\u05d5\u05df","\u05ea\u05de\u05d5\u05d6","\u05d0\u05d1","\u05d0\u05dc\u05d5\u05dc"];let or=(()=>{class V extends re{getMonthShortName(E,U){return this.getMonthFullName(E,U)}getMonthFullName(E,U){return ju(U)?rr[E-1]||"":gi[E-1]||""}getWeekdayLabel(E,U){return mn[E-1]||""}getDayAriaLabel(E){return`${Re(E.day)} ${this.getMonthFullName(E.month,E.year)} ${Re(E.year)}`}getDayNumerals(E){return Re(E.day)}getWeekNumerals(E){return Re(E)}getYearNumerals(E){return Re(E)}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();function ia(V){return new Date(V.year-543,V.month-1,V.day)}function La(V){return new sa(V.getFullYear()+543,V.getMonth()+1,V.getDate())}let vs=(()=>{class V extends sc{getToday(){return La(new Date)}getNext(E,U="d",ee=1){let Xe=ia(E),Nt=!0,Ei=Xe.getMonth();switch(U){case"y":Xe.setFullYear(Xe.getFullYear()+ee);break;case"m":Ei+=ee,Xe.setMonth(Ei),Ei%=12,Ei<0&&(Ei+=12);break;case"d":Xe.setDate(Xe.getDate()+ee),Nt=!1;break;default:return E}return Nt&&Xe.getMonth()!==Ei&&Xe.setDate(0),La(Xe)}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){let ee=ia(E).getDay();return 0===ee?7:ee}getWeekNumber(E,U){7===U&&(U=0);const Nt=ia(E[(11-U)%7]);Nt.setDate(Nt.getDate()+4-(Nt.getDay()||7));const Ei=Nt.getTime();return Nt.setMonth(0),Nt.setDate(1),Math.floor(Math.round((Ei-Nt.getTime())/864e5)/7)+1}isValid(E){if(!(E&&er(E.year)&&er(E.month)&&er(E.day)&&0!==E.year))return!1;const U=ia(E);return!isNaN(U.getTime())&&U.getFullYear()===E.year-543&&U.getMonth()+1===E.month&&U.getDate()===E.day}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const Qo=1724220.5,ll=[30,30,30,30,30,30,30,30,30,30,30,30,5];function Mc(V,Qe){return Qe=+Qe,V.year=V.year+Math.floor((Qe-1)/13),V.month=Math.floor(((Qe-1)%13+13)%13)+1,V}function Ue(V,Qe){let E=function Sa(V){return null!=V&&(V%4==3||V%4==-1)}(Qe);return ll[V-1]+(13===V&&E?1:0)}function ne(V){let E=function Rn(V){let Qe=Math.floor(V+.5),E=Math.floor((Qe-1867216.25)/36524.25);E=Qe+1+E-Math.floor(E/4);let U=E+1524,ee=Math.floor((U-122.1)/365.25),Xe=Math.floor(365.25*ee),Nt=Math.floor((U-Xe)/30.6001),Ei=U-Xe-Math.floor(30.6001*Nt),gr=Nt-(Nt>13.5?13:1),ur=ee-(gr>2.5?4716:4715);return ur<=0&&ur--,new Date(ur,gr,Ei)}(rt(V.year,V.month,V.day));return E.setHours(6,30,3,200),E}function rt(V,Qe,E){return V<0&&V++,E+30*(Qe-1)+365*(V-1)+Math.floor(V/4)+Qo-1}let Y=(()=>{class V extends Ql{getDaysPerWeek(){return 7}getMonths(E){return[1,2,3,4,5,6,7,8,9,10,11,12,13]}getNext(E,U="d",ee=1){switch(E=new sa(E.year,E.month,E.day),U){case"y":return E=function $o(V,Qe){return V.year=+Qe,V}(E,E.year+ee),E.month=1,E.day=1,E;case"m":return(E=Mc(E,E.month+ee)).day=1,E;case"d":return function yc(V,Qe){let E=Ue(V.month,V.year);if(Qe<=0)for(;Qe<=0;)E=Ue((V=Mc(V,V.month-1)).month,V.year),Qe+=E;else if(Qe>E)for(;Qe>E;)Qe-=E,E=Ue((V=Mc(V,V.month+1)).month,V.year);return V.day=Qe,V}(E,E.day+ee);default:return E}}getPrev(E,U="d",ee=1){return this.getNext(E,U,-ee)}getWeekday(E){const U=Math.floor(rt(E.year,E.month,E.day)+3)%7;return 0===U?7:U}getWeekNumber(E,U){7===U&&(U=0);const Xe=E[(11-U)%7],Nt=ne(Xe);Nt.setDate(Nt.getDate()+4-(Nt.getDay()||7));const Ei=Nt.getTime(),gr=ne(new sa(Xe.year,1,1));return Math.floor(Math.round((Ei-gr.getTime())/864e5)/7)+1}getWeeksPerMonth(){return 6}getToday(){return function Pe(V){return function Ut(V){let Qe=Math.floor(V)+.5-Qo,E=Math.floor((Qe-Math.floor((Qe+366)/1461))/365)+1;E<=0&&E--,Qe=Math.floor(V)+.5-rt(E,1,1);let U=Math.floor(Qe/30)+1;return new sa(E,U,Qe-30*(U-1)+1)}(function Kn(V,Qe,E){V<0&&V++,Qe<3&&(Qe+=12,V--);let U=Math.floor(V/100),ee=2-U+Math.floor(U/4);return Math.floor(365.25*(V+4716))+Math.floor(30.6001*(Qe+1))+E+ee-1524.5}(V.getFullYear(),V.getMonth()+1,V.getDate()))}(new Date)}isValid(E){return E&&er(E.year)&&er(E.month)&&er(E.day)&&!isNaN(ne(E).getTime())}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const Ce=["\u12a5\u1211\u12f5","\u1230\u129e","\u121b\u12ad\u1230\u129e","\u1228\u1261\u12d5","\u1213\u1219\u1235","\u12d3\u122d\u1265","\u1245\u12f3\u121c"],ue=["\u1218\u1235\u12a8\u1228\u121d","\u1325\u1245\u121d\u1275","\u1285\u12f3\u122d","\u1273\u1205\u1223\u1225","\u1325\u122d","\u12e8\u12ab\u1272\u1275","\u1218\u130b\u1262\u1275","\u121a\u12eb\u12dd\u12eb","\u130d\u1295\u1266\u1275","\u1230\u1294","\u1210\u121d\u120c","\u1290\u1210\u1234","\u1333\u1309\u121c"];let Ie=(()=>{class V extends re{getMonthShortName(E,U){return this.getMonthFullName(E,U)}getMonthFullName(E,U){return ue[E-1]}getWeekdayLabel(E,U){return Ce[E-1]}getDayAriaLabel(E){return`${E.day} ${this.getMonthFullName(E.month,E.year)} ${E.year}`}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),Ze=(()=>{class V extends vi{fromModel(E){return E instanceof Date&&!isNaN(E.getTime())?this._fromNativeDate(E):null}toModel(E){return E&&er(E.year)&&er(E.month)&&er(E.day)?this._toNativeDate(E):null}_fromNativeDate(E){return{year:E.getFullYear(),month:E.getMonth()+1,day:E.getDate()}}_toNativeDate(E){const U=new Date(E.year,E.month-1,E.day,12);return U.setFullYear(E.year),U}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),kt=(()=>{class V extends Ze{_fromNativeDate(E){return{year:E.getUTCFullYear(),month:E.getUTCMonth()+1,day:E.getUTCDate()}}_toNativeDate(E){const U=new Date(Date.UTC(E.year,E.month-1,E.day));return U.setUTCFullYear(E.year),U}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),Si=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),oi=(()=>{class V{constructor(){this.autoClose=!0,this.placement=["bottom-start","bottom-end","top-start","top-end"],this.popperOptions=E=>E,this.container=null}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Yr=(()=>{class V{constructor(){this._disabled=!1,this.nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this.tabindex=0}set disabled(E){this._disabled=""===E||!0===E}get disabled(){return this._disabled}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbDropdownItem",""]],hostAttrs:[1,"dropdown-item"],hostVars:3,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("tabIndex",ee.disabled?-1:ee.tabindex),i.\u0275\u0275classProp("disabled",ee.disabled))},inputs:{tabindex:"tabindex",disabled:"disabled"},standalone:!0})}return V})(),rs=(()=>{class V{constructor(){this.item=(0,i.inject)(Yr)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["button","ngbDropdownItem",""]],hostVars:1,hostBindings:function(U,ee){2&U&&i.\u0275\u0275hostProperty("disabled",ee.item.disabled)},standalone:!0})}return V})(),ls=(()=>{class V{constructor(){this.dropdown=(0,i.inject)(dc),this.nativeElement=(0,i.inject)(i.ElementRef).nativeElement}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbDropdownMenu",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,Yr,4),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.menuItems=Nt)}},hostAttrs:[1,"dropdown-menu"],hostVars:2,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("keydown.ArrowUp",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.ArrowDown",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Home",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.End",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Enter",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Space",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Tab",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Shift.Tab",function(Nt){return ee.dropdown.onKeyDown(Nt)}),2&U&&i.\u0275\u0275classProp("show",ee.dropdown.isOpen())},standalone:!0})}return V})(),Zo=(()=>{class V{constructor(){this.dropdown=(0,i.inject)(dc),this.nativeElement=(0,i.inject)(i.ElementRef).nativeElement}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbDropdownAnchor",""]],hostAttrs:[1,"dropdown-toggle"],hostVars:3,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275attribute("aria-expanded",ee.dropdown.isOpen()),i.\u0275\u0275classProp("show",ee.dropdown.isOpen()))},standalone:!0})}return V})(),Hl=(()=>{class V extends Zo{static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbDropdownToggle",""]],hostAttrs:[1,"dropdown-toggle"],hostVars:3,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("click",function(){return ee.dropdown.toggle()})("keydown.ArrowUp",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.ArrowDown",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Home",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.End",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Tab",function(Nt){return ee.dropdown.onKeyDown(Nt)})("keydown.Shift.Tab",function(Nt){return ee.dropdown.onKeyDown(Nt)}),2&U&&(i.\u0275\u0275attribute("aria-expanded",ee.dropdown.isOpen()),i.\u0275\u0275classProp("show",ee.dropdown.isOpen()))},standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:Zo,useExisting:(0,i.forwardRef)(()=>V)}]),i.\u0275\u0275InheritDefinitionFeature]})}return V})(),dc=(()=>{class V{constructor(){this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._config=(0,i.inject)(oi),this._document=(0,i.inject)(Z.DOCUMENT),this._injector=(0,i.inject)(i.Injector),this._ngZone=(0,i.inject)(i.NgZone),this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._destroyCloseHandlers$=new e.Subject,this._bodyContainer=null,this._positioning=Gs(),this.autoClose=this._config.autoClose,this._open=!1,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.container=this._config.container,this.openChange=new i.EventEmitter}ngOnInit(){this.display||(this.display=this._nativeElement.closest(".navbar")?"static":"dynamic")}ngAfterContentInit(){(0,i.afterNextRender)(()=>{this._applyPlacementClasses(),this._open&&this._setCloseHandlers()},{phase:i.AfterRenderPhase.Write,injector:this._injector})}ngOnChanges(E){if(E.container&&this._open&&this._applyContainer(this.container),E.placement&&!E.placement.firstChange&&(this._positioning.setOptions({hostElement:this._anchor.nativeElement,targetElement:this._bodyContainer||this._menu.nativeElement,placement:this.placement}),this._applyPlacementClasses()),E.dropdownClass){const{currentValue:U,previousValue:ee}=E.dropdownClass;this._applyCustomDropdownClass(U,ee)}E.autoClose&&this._open&&(this.autoClose=E.autoClose.currentValue,this._setCloseHandlers())}isOpen(){return this._open}open(){this._open||(this._open=!0,this._applyContainer(this.container),this.openChange.emit(!0),this._setCloseHandlers(),this._anchor&&(this._anchor.nativeElement.focus(),"dynamic"===this.display&&this._ngZone.runOutsideAngular(()=>{this._positioning.createPopper({hostElement:this._anchor.nativeElement,targetElement:this._bodyContainer||this._menu.nativeElement,placement:this.placement,updatePopperOptions:E=>this.popperOptions(lc([0,2])(E))}),this._applyPlacementClasses(),this._afterRenderRef=(0,i.afterRender)(()=>{this._positionMenu()},{phase:i.AfterRenderPhase.Write,injector:this._injector})})))}_setCloseHandlers(){this._destroyCloseHandlers$.next(),Ds(this._ngZone,this._document,this.autoClose,E=>{this.close(),0===E&&this._anchor.nativeElement.focus()},this._destroyCloseHandlers$,this._menu?[this._menu.nativeElement]:[],this._anchor?[this._anchor.nativeElement]:[],".dropdown-item,.dropdown-divider")}close(){this._open&&(this._open=!1,this._resetContainer(),this._positioning.destroy(),this._afterRenderRef?.destroy(),this._destroyCloseHandlers$.next(),this.openChange.emit(!1),this._changeDetector.markForCheck())}toggle(){this.isOpen()?this.close():this.open()}ngOnDestroy(){this.close()}onKeyDown(E){const{key:U}=E,ee=this._getMenuElements();let Xe=-1,Nt=null;const Ei=this._isEventFromToggle(E);if(!Ei&&ee.length&&ee.forEach((gr,ur)=>{gr.contains(E.target)&&(Nt=gr),gr===fr(this._document)&&(Xe=ur)})," "!==U&&"Enter"!==U){if("Tab"!==U){if(Ei||Nt){if(this.open(),ee.length){switch(U){case"ArrowDown":Xe=Math.min(Xe+1,ee.length-1);break;case"ArrowUp":if(this._isDropup()&&-1===Xe){Xe=ee.length-1;break}Xe=Math.max(Xe-1,0);break;case"Home":Xe=0;break;case"End":Xe=ee.length-1}ee[Xe].focus()}E.preventDefault()}}else if(E.target&&this.isOpen()&&this.autoClose){if(this._anchor.nativeElement===E.target)return void("body"!==this.container||E.shiftKey?E.shiftKey&&this.close():(this._menu.nativeElement.setAttribute("tabindex","0"),this._menu.nativeElement.focus(),this._menu.nativeElement.removeAttribute("tabindex")));if("body"===this.container){const gr=this._menu.nativeElement.querySelectorAll(Xo);E.shiftKey&&E.target===gr[0]?(this._anchor.nativeElement.focus(),E.preventDefault()):!E.shiftKey&&E.target===gr[gr.length-1]&&(this._anchor.nativeElement.focus(),this.close())}else(0,e.fromEvent)(E.target,"focusout").pipe((0,M.take)(1)).subscribe(({relatedTarget:gr})=>{this._nativeElement.contains(gr)||this.close()})}}else Nt&&(!0===this.autoClose||"inside"===this.autoClose)&&(0,e.fromEvent)(Nt,"click").pipe((0,M.take)(1)).subscribe(()=>this.close())}_isDropup(){return this._nativeElement.classList.contains("dropup")}_isEventFromToggle(E){return this._anchor.nativeElement.contains(E.target)}_getMenuElements(){return this._menu?this._menu.menuItems.filter(({disabled:E})=>!E).map(({nativeElement:E})=>E):[]}_positionMenu(){const E=this._menu;this.isOpen()&&E&&("dynamic"===this.display?(this._positioning.update(),this._applyPlacementClasses()):this._applyPlacementClasses(this._getFirstPlacement(this.placement)))}_getFirstPlacement(E){return Array.isArray(E)?E[0]:E.split(" ")[0]}_resetContainer(){this._menu&&this._nativeElement.appendChild(this._menu.nativeElement),this._bodyContainer&&(this._document.body.removeChild(this._bodyContainer),this._bodyContainer=null)}_applyContainer(E=null){if(this._resetContainer(),"body"===E){const U=this._menu.nativeElement,ee=this._bodyContainer=this._bodyContainer||this._document.createElement("div");ee.style.position="absolute",U.style.position="static",ee.style.zIndex="1055",ee.appendChild(U),this._document.body.appendChild(ee)}this._applyCustomDropdownClass(this.dropdownClass)}_applyCustomDropdownClass(E,U){const ee="body"===this.container?this._bodyContainer:this._nativeElement;ee&&(U&&ee.classList.remove(U),E&&ee.classList.add(E))}_applyPlacementClasses(E){if(this._menu){E||(E=this._getFirstPlacement(this.placement)),this._nativeElement.classList.remove("dropup","dropdown"),"static"===this.display?this._menu.nativeElement.setAttribute("data-bs-popper","static"):this._menu.nativeElement.removeAttribute("data-bs-popper");const U=-1!==E.search("^top")?"dropup":"dropdown";this._nativeElement.classList.add(U),this._bodyContainer&&(this._bodyContainer.classList.remove("dropup","dropdown"),this._bodyContainer.classList.add(U))}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbDropdown",""]],contentQueries:function(U,ee,Xe){if(1&U&&(i.\u0275\u0275contentQuery(Xe,ls,5),i.\u0275\u0275contentQuery(Xe,Zo,5)),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._menu=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._anchor=Nt.first)}},hostVars:2,hostBindings:function(U,ee){2&U&&i.\u0275\u0275classProp("show",ee.isOpen())},inputs:{autoClose:"autoClose",dropdownClass:"dropdownClass",_open:[0,"open","_open"],placement:"placement",popperOptions:"popperOptions",container:"container",display:"display"},outputs:{openChange:"openChange"},exportAs:["ngbDropdown"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return V})(),Vc=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Wo=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.backdrop=!0,this.fullscreen=!1,this.keyboard=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();class sr{constructor(Qe,E,U){this.nodes=Qe,this.viewRef=E,this.componentRef=U}}class ro{constructor(Qe){this._componentType=Qe,this._windowRef=null,this._contentRef=null,this._document=(0,i.inject)(Z.DOCUMENT),this._applicationRef=(0,i.inject)(i.ApplicationRef),this._injector=(0,i.inject)(i.Injector),this._viewContainerRef=(0,i.inject)(i.ViewContainerRef),this._ngZone=(0,i.inject)(i.NgZone)}open(Qe,E,U=!1){this._windowRef||(this._contentRef=this._getContentRef(Qe,E),this._windowRef=this._viewContainerRef.createComponent(this._componentType,{injector:this._injector,projectableNodes:this._contentRef.nodes}));const{nativeElement:ee}=this._windowRef.location,Xe=new e.Subject;(0,i.afterNextRender)(()=>{Xe.next(),Xe.complete()},{injector:this._injector,phase:i.AfterRenderPhase.MixedReadWrite});const Nt=Xe.pipe((0,M.mergeMap)(()=>Mo(this._ngZone,ee,({classList:Ei})=>Ei.add("show"),{animation:U,runningTransition:"continue"})));return{windowRef:this._windowRef,transition$:Nt}}close(Qe=!1){return this._windowRef?Mo(this._ngZone,this._windowRef.location.nativeElement,({classList:E})=>E.remove("show"),{animation:Qe,runningTransition:"stop"}).pipe((0,M.tap)(()=>{this._windowRef?.destroy(),this._contentRef?.viewRef?.destroy(),this._windowRef=null,this._contentRef=null})):(0,e.of)(void 0)}_getContentRef(Qe,E){if(Qe){if(Qe instanceof i.TemplateRef){const U=Qe.createEmbeddedView(E);return this._applicationRef.attachView(U),new sr([U.rootNodes],U)}return new sr([[this._document.createTextNode(`${Qe}`)]])}return new sr([])}}let Ic=(()=>{class V{constructor(){this._document=(0,i.inject)(Z.DOCUMENT)}hide(){const E=Math.abs(window.innerWidth-this._document.documentElement.clientWidth),U=this._document.body,ee=U.style,{overflow:Xe,paddingRight:Nt}=ee;if(E>0){const Ei=parseFloat(window.getComputedStyle(U).paddingRight);ee.paddingRight=`${Ei+E}px`}return ee.overflow="hidden",()=>{E>0&&(ee.paddingRight=Nt),ee.overflow=Xe}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Sp=(()=>{class V{constructor(){this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._zone=(0,i.inject)(i.NgZone),this._injector=(0,i.inject)(i.Injector)}ngOnInit(){(0,i.afterNextRender)(()=>Mo(this._zone,this._nativeElement,(E,U)=>{U&&Un(E),E.classList.add("show")},{animation:this.animation,runningTransition:"continue"}),{injector:this._injector,phase:i.AfterRenderPhase.MixedReadWrite})}hide(){return Mo(this._zone,this._nativeElement,({classList:E})=>E.remove("show"),{animation:this.animation,runningTransition:"stop"})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-modal-backdrop"]],hostAttrs:[2,"z-index","1055"],hostVars:6,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275classMap("modal-backdrop"+(ee.backdropClass?" "+ee.backdropClass:"")),i.\u0275\u0275classProp("show",!ee.animation)("fade",ee.animation))},inputs:{animation:"animation",backdropClass:"backdropClass"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:0,vars:0,template:function(U,ee){},encapsulation:2})}return V})();class au{update(Qe){}close(Qe){}dismiss(Qe){}}const Uu=["animation","ariaLabelledBy","ariaDescribedBy","backdrop","centered","fullscreen","keyboard","scrollable","size","windowClass","modalDialogClass"],bh=["animation","backdropClass"];class wv{_applyWindowOptions(Qe,E){Uu.forEach(U=>{Or(E[U])&&(Qe[U]=E[U])})}_applyBackdropOptions(Qe,E){bh.forEach(U=>{Or(E[U])&&(Qe[U]=E[U])})}update(Qe){this._applyWindowOptions(this._windowCmptRef.instance,Qe),this._backdropCmptRef&&this._backdropCmptRef.instance&&this._applyBackdropOptions(this._backdropCmptRef.instance,Qe)}get componentInstance(){if(this._contentRef&&this._contentRef.componentRef)return this._contentRef.componentRef.instance}get closed(){return this._closed.asObservable().pipe((0,M.takeUntil)(this._hidden))}get dismissed(){return this._dismissed.asObservable().pipe((0,M.takeUntil)(this._hidden))}get hidden(){return this._hidden.asObservable()}get shown(){return this._windowCmptRef.instance.shown.asObservable()}constructor(Qe,E,U,ee){this._windowCmptRef=Qe,this._contentRef=E,this._backdropCmptRef=U,this._beforeDismiss=ee,this._closed=new e.Subject,this._dismissed=new e.Subject,this._hidden=new e.Subject,Qe.instance.dismissEvent.subscribe(Xe=>{this.dismiss(Xe)}),this.result=new Promise((Xe,Nt)=>{this._resolve=Xe,this._reject=Nt}),this.result.then(null,()=>{})}close(Qe){this._windowCmptRef&&(this._closed.next(Qe),this._resolve(Qe),this._removeModalElements())}_dismiss(Qe){this._dismissed.next(Qe),this._reject(Qe),this._removeModalElements()}dismiss(Qe){if(this._windowCmptRef)if(this._beforeDismiss){const E=this._beforeDismiss();Tt(E)?E.then(U=>{!1!==U&&this._dismiss(Qe)},()=>{}):!1!==E&&this._dismiss(Qe)}else this._dismiss(Qe)}_removeModalElements(){const Qe=this._windowCmptRef.instance.hide(),E=this._backdropCmptRef?this._backdropCmptRef.instance.hide():(0,e.of)(void 0);Qe.subscribe(()=>{const{nativeElement:U}=this._windowCmptRef.location;U.parentNode.removeChild(U),this._windowCmptRef.destroy(),this._contentRef?.viewRef?.destroy(),this._windowCmptRef=null,this._contentRef=null}),E.subscribe(()=>{if(this._backdropCmptRef){const{nativeElement:U}=this._backdropCmptRef.location;U.parentNode.removeChild(U),this._backdropCmptRef.destroy(),this._backdropCmptRef=null}}),(0,e.zip)(Qe,E).subscribe(()=>{this._hidden.next(),this._hidden.complete()})}}var op=function(V){return V[V.BACKDROP_CLICK=0]="BACKDROP_CLICK",V[V.ESC=1]="ESC",V}(op||{});let Pd=(()=>{class V{constructor(){this._document=(0,i.inject)(Z.DOCUMENT),this._elRef=(0,i.inject)(i.ElementRef),this._zone=(0,i.inject)(i.NgZone),this._injector=(0,i.inject)(i.Injector),this._closed$=new e.Subject,this._elWithFocus=null,this.backdrop=!0,this.keyboard=!0,this.dismissEvent=new i.EventEmitter,this.shown=new e.Subject,this.hidden=new e.Subject}get fullscreenClass(){return!0===this.fullscreen?" modal-fullscreen":Ui(this.fullscreen)?` modal-fullscreen-${this.fullscreen}-down`:""}dismiss(E){this.dismissEvent.emit(E)}ngOnInit(){this._elWithFocus=this._document.activeElement,(0,i.afterNextRender)(()=>this._show(),{injector:this._injector,phase:i.AfterRenderPhase.MixedReadWrite})}ngOnDestroy(){this._disableEventHandling()}hide(){const{nativeElement:E}=this._elRef,U={animation:this.animation,runningTransition:"stop"},ee=Mo(this._zone,E,()=>E.classList.remove("show"),U),Xe=Mo(this._zone,this._dialogEl.nativeElement,()=>{},U),Nt=(0,e.zip)(ee,Xe);return Nt.subscribe(()=>{this.hidden.next(),this.hidden.complete()}),this._disableEventHandling(),this._restoreFocus(),Nt}_show(){const E={animation:this.animation,runningTransition:"continue"},U=Mo(this._zone,this._elRef.nativeElement,(Xe,Nt)=>{Nt&&Un(Xe),Xe.classList.add("show")},E),ee=Mo(this._zone,this._dialogEl.nativeElement,()=>{},E);(0,e.zip)(U,ee).subscribe(()=>{this.shown.next(),this.shown.complete()}),this._enableEventHandling(),this._setFocus()}_enableEventHandling(){const{nativeElement:E}=this._elRef;this._zone.runOutsideAngular(()=>{(0,e.fromEvent)(E,"keydown").pipe((0,M.takeUntil)(this._closed$),(0,M.filter)(ee=>"Escape"===ee.key)).subscribe(ee=>{this.keyboard?requestAnimationFrame(()=>{ee.defaultPrevented||this._zone.run(()=>this.dismiss(op.ESC))}):"static"===this.backdrop&&this._bumpBackdrop()});let U=!1;(0,e.fromEvent)(this._dialogEl.nativeElement,"mousedown").pipe((0,M.takeUntil)(this._closed$),(0,M.tap)(()=>U=!1),(0,M.switchMap)(()=>(0,e.fromEvent)(E,"mouseup").pipe((0,M.takeUntil)(this._closed$),(0,M.take)(1))),(0,M.filter)(({target:ee})=>E===ee)).subscribe(()=>{U=!0}),(0,e.fromEvent)(E,"click").pipe((0,M.takeUntil)(this._closed$)).subscribe(({target:ee})=>{E===ee&&("static"===this.backdrop?this._bumpBackdrop():!0===this.backdrop&&!U&&this._zone.run(()=>this.dismiss(op.BACKDROP_CLICK))),U=!1})})}_disableEventHandling(){this._closed$.next()}_setFocus(){const{nativeElement:E}=this._elRef;if(!E.contains(document.activeElement)){const U=E.querySelector("[ngbAutofocus]"),ee=na(E)[0];(U||ee||E).focus()}}_restoreFocus(){const E=this._document.body,U=this._elWithFocus;let ee;ee=U&&U.focus&&E.contains(U)?U:E,this._zone.runOutsideAngular(()=>{setTimeout(()=>ee.focus()),this._elWithFocus=null})}_bumpBackdrop(){"static"===this.backdrop&&Mo(this._zone,this._elRef.nativeElement,({classList:E})=>(E.add("modal-static"),()=>E.remove("modal-static")),{animation:this.animation,runningTransition:"continue"})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-modal-window"]],viewQuery:function(U,ee){if(1&U&&i.\u0275\u0275viewQuery(Ai,7),2&U){let Xe;i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee._dialogEl=Xe.first)}},hostAttrs:["role","dialog","tabindex","-1"],hostVars:7,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275attribute("aria-modal",!0)("aria-labelledby",ee.ariaLabelledBy)("aria-describedby",ee.ariaDescribedBy),i.\u0275\u0275classMap("modal d-block"+(ee.windowClass?" "+ee.windowClass:"")),i.\u0275\u0275classProp("fade",ee.animation))},inputs:{animation:"animation",ariaLabelledBy:"ariaLabelledBy",ariaDescribedBy:"ariaDescribedBy",backdrop:"backdrop",centered:"centered",fullscreen:"fullscreen",keyboard:"keyboard",scrollable:"scrollable",size:"size",windowClass:"windowClass",modalDialogClass:"modalDialogClass"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:4,vars:2,consts:[["dialog",""],["role","document"],[1,"modal-content"]],template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275elementStart(0,"div",1,0)(2,"div",2),i.\u0275\u0275projection(3),i.\u0275\u0275elementEnd()()),2&U&&i.\u0275\u0275classMap("modal-dialog"+(ee.size?" modal-"+ee.size:"")+(ee.centered?" modal-dialog-centered":"")+ee.fullscreenClass+(ee.scrollable?" modal-dialog-scrollable":"")+(ee.modalDialogClass?" "+ee.modalDialogClass:""))},styles:["ngb-modal-window .component-host-scrollable{display:flex;flex-direction:column;overflow:hidden}\n"],encapsulation:2})}return V})(),$u=(()=>{class V{constructor(){this._applicationRef=(0,i.inject)(i.ApplicationRef),this._injector=(0,i.inject)(i.Injector),this._environmentInjector=(0,i.inject)(i.EnvironmentInjector),this._document=(0,i.inject)(Z.DOCUMENT),this._scrollBar=(0,i.inject)(Ic),this._activeWindowCmptHasChanged=new e.Subject,this._ariaHiddenValues=new Map,this._scrollBarRestoreFn=null,this._modalRefs=[],this._windowCmpts=[],this._activeInstances=new i.EventEmitter;const E=(0,i.inject)(i.NgZone);this._activeWindowCmptHasChanged.subscribe(()=>{if(this._windowCmpts.length){const U=this._windowCmpts[this._windowCmpts.length-1];zs(E,U.location.nativeElement,this._activeWindowCmptHasChanged),this._revertAriaHidden(),this._setAriaHidden(U.location.nativeElement)}})}_restoreScrollBar(){const E=this._scrollBarRestoreFn;E&&(this._scrollBarRestoreFn=null,E())}_hideScrollBar(){this._scrollBarRestoreFn||(this._scrollBarRestoreFn=this._scrollBar.hide())}open(E,U,ee){const Xe=ee.container instanceof HTMLElement?ee.container:Or(ee.container)?this._document.querySelector(ee.container):this._document.body;if(!Xe)throw new Error(`The specified modal container "${ee.container||"body"}" was not found in the DOM.`);this._hideScrollBar();const Nt=new au,Ei=(E=ee.injector||E).get(i.EnvironmentInjector,null)||this._environmentInjector,gr=this._getContentRef(E,Ei,U,Nt,ee);let ur=!1!==ee.backdrop?this._attachBackdrop(Xe):void 0,vo=this._attachWindowComponent(Xe,gr.nodes),Gr=new wv(vo,gr,ur,ee.beforeDismiss);return this._registerModalRef(Gr),this._registerWindowCmpt(vo),Gr.hidden.pipe((0,M.take)(1)).subscribe(()=>Promise.resolve(!0).then(()=>{this._modalRefs.length||(this._document.body.classList.remove("modal-open"),this._restoreScrollBar(),this._revertAriaHidden())})),Nt.close=jo=>{Gr.close(jo)},Nt.dismiss=jo=>{Gr.dismiss(jo)},Nt.update=jo=>{Gr.update(jo)},Gr.update(ee),1===this._modalRefs.length&&this._document.body.classList.add("modal-open"),ur&&ur.instance&&ur.changeDetectorRef.detectChanges(),vo.changeDetectorRef.detectChanges(),Gr}get activeInstances(){return this._activeInstances}dismissAll(E){this._modalRefs.forEach(U=>U.dismiss(E))}hasOpenModals(){return this._modalRefs.length>0}_attachBackdrop(E){let U=(0,i.createComponent)(Sp,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector});return this._applicationRef.attachView(U.hostView),E.appendChild(U.location.nativeElement),U}_attachWindowComponent(E,U){let ee=(0,i.createComponent)(Pd,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector,projectableNodes:U});return this._applicationRef.attachView(ee.hostView),E.appendChild(ee.location.nativeElement),ee}_getContentRef(E,U,ee,Xe,Nt){return ee?ee instanceof i.TemplateRef?this._createFromTemplateRef(ee,Xe):Ui(ee)?this._createFromString(ee):this._createFromComponent(E,U,ee,Xe,Nt):new sr([])}_createFromTemplateRef(E,U){const Xe=E.createEmbeddedView({$implicit:U,close(Nt){U.close(Nt)},dismiss(Nt){U.dismiss(Nt)}});return this._applicationRef.attachView(Xe),new sr([Xe.rootNodes],Xe)}_createFromString(E){const U=this._document.createTextNode(`${E}`);return new sr([[U]])}_createFromComponent(E,U,ee,Xe,Nt){const Ei=i.Injector.create({providers:[{provide:au,useValue:Xe}],parent:E}),gr=(0,i.createComponent)(ee,{environmentInjector:U,elementInjector:Ei}),ur=gr.location.nativeElement;return Nt.scrollable&&ur.classList.add("component-host-scrollable"),this._applicationRef.attachView(gr.hostView),new sr([[ur]],gr.hostView,gr)}_setAriaHidden(E){const U=E.parentElement;U&&E!==this._document.body&&(Array.from(U.children).forEach(ee=>{ee!==E&&"SCRIPT"!==ee.nodeName&&(this._ariaHiddenValues.set(ee,ee.getAttribute("aria-hidden")),ee.setAttribute("aria-hidden","true"))}),this._setAriaHidden(U))}_revertAriaHidden(){this._ariaHiddenValues.forEach((E,U)=>{E?U.setAttribute("aria-hidden",E):U.removeAttribute("aria-hidden")}),this._ariaHiddenValues.clear()}_registerModalRef(E){const U=()=>{const ee=this._modalRefs.indexOf(E);ee>-1&&(this._modalRefs.splice(ee,1),this._activeInstances.emit(this._modalRefs))};this._modalRefs.push(E),this._activeInstances.emit(this._modalRefs),E.result.then(U,U)}_registerWindowCmpt(E){this._windowCmpts.push(E),this._activeWindowCmptHasChanged.next(),E.onDestroy(()=>{const U=this._windowCmpts.indexOf(E);U>-1&&(this._windowCmpts.splice(U,1),this._activeWindowCmptHasChanged.next())})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Yh=(()=>{class V{constructor(){this._injector=(0,i.inject)(i.Injector),this._modalStack=(0,i.inject)($u),this._config=(0,i.inject)(Wo)}open(E,U={}){const ee={...this._config,animation:this._config.animation,...U};return this._modalStack.open(this._injector,E,ee)}get activeInstances(){return this._modalStack.activeInstances}dismissAll(E){this._modalStack.dismissAll(E)}hasOpenModals(){return this._modalStack.hasOpenModals()}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),yg=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({providers:[Yh]})}return V})(),Qd=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.destroyOnHide=!0,this.orientation="horizontal",this.roles="tablist",this.keyboard=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();const xv=V=>Or(V)&&""!==V;let bg=0,mf=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbNavContent",""]],standalone:!0})}return V})(),U_=(()=>{class V{constructor(E){this.role=E,this.nav=(0,i.inject)(Zc)}static#e=this.\u0275fac=function(U){return new(U||V)(i.\u0275\u0275injectAttribute("role"))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbNavItem","",5,"ng-container"]],hostVars:1,hostBindings:function(U,ee){2&U&&i.\u0275\u0275attribute("role",ee.role?ee.role:ee.nav.roles?"presentation":void 0)},standalone:!0})}return V})(),Ch=(()=>{class V{constructor(){this._nav=(0,i.inject)(Zc),this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this.disabled=!1,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter}ngOnInit(){Or(this.domId)||(this.domId="ngb-nav-"+bg++)}get active(){return this._nav.activeId===this.id}get id(){return xv(this._id)?this._id:this.domId}get panelDomId(){return`${this.domId}-panel`}isPanelInDom(){return(Or(this.destroyOnHide)?!this.destroyOnHide:!this._nav.destroyOnHide)||this.active}isNgContainer(){return this._nativeElement.nodeType===Node.COMMENT_NODE}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbNavItem",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,mf,4),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.contentTpl=Nt.first)}},hostAttrs:[1,"nav-item"],inputs:{destroyOnHide:"destroyOnHide",disabled:"disabled",domId:"domId",_id:[0,"ngbNavItem","_id"]},outputs:{shown:"shown",hidden:"hidden"},exportAs:["ngbNavItem"],standalone:!0})}return V})(),Zc=(()=>{class V{constructor(E){this.role=E,this._config=(0,i.inject)(Qd),this._cd=(0,i.inject)(i.ChangeDetectorRef),this._document=(0,i.inject)(Z.DOCUMENT),this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this.destroyRef=(0,i.inject)(i.DestroyRef),this._navigatingWithKeyboard=!1,this.activeIdChange=new i.EventEmitter,this.animation=this._config.animation,this.destroyOnHide=this._config.destroyOnHide,this.orientation=this._config.orientation,this.roles=this._config.roles,this.keyboard=this._config.keyboard,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter,this.navItemChange$=new e.Subject,this.navChange=new i.EventEmitter}click(E){E.disabled||this._updateActiveId(E.id)}onFocusout({relatedTarget:E}){this._nativeElement.contains(E)||(this._navigatingWithKeyboard=!1)}onKeyDown(E){if("tablist"!==this.roles||!this.keyboard)return;const U=this.links.filter(Nt=>!Nt.navItem.disabled),{length:ee}=U;let Xe=-1;if(U.forEach((Nt,Ei)=>{Nt.nativeElement===this._document.activeElement&&(Xe=Ei)}),ee){switch(E.key){case"ArrowUp":case"ArrowLeft":Xe=(Xe-1+ee)%ee;break;case"ArrowRight":case"ArrowDown":Xe=(Xe+1)%ee;break;case"Home":Xe=0;break;case"End":Xe=ee-1}"changeWithArrows"===this.keyboard&&this.select(U[Xe].navItem.id),U[Xe].nativeElement.focus(),this._navigatingWithKeyboard=!0,E.preventDefault()}}select(E){this._updateActiveId(E,!1)}ngAfterContentInit(){if(!Or(this.activeId)){const E=this.items.first?this.items.first.id:null;xv(E)&&(this._updateActiveId(E,!1),this._cd.detectChanges())}this.items.changes.pipe(X(this.destroyRef)).subscribe(()=>this._notifyItemChanged(this.activeId))}ngOnChanges({activeId:E}){E&&!E.firstChange&&this._notifyItemChanged(E.currentValue)}_updateActiveId(E,U=!0){if(this.activeId!==E){let ee=!1;U&&this.navChange.emit({activeId:this.activeId,nextId:E,preventDefault:()=>{ee=!0}}),ee||(this.activeId=E,this.activeIdChange.emit(E),this._notifyItemChanged(E))}}_notifyItemChanged(E){this.navItemChange$.next(this._getItemById(E))}_getItemById(E){return this.items&&this.items.find(U=>U.id===E)||null}static#e=this.\u0275fac=function(U){return new(U||V)(i.\u0275\u0275injectAttribute("role"))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbNav",""]],contentQueries:function(U,ee,Xe){if(1&U&&(i.\u0275\u0275contentQuery(Xe,Ch,4),i.\u0275\u0275contentQuery(Xe,Tu,5)),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.items=Nt),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.links=Nt)}},hostAttrs:[1,"nav"],hostVars:4,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("keydown.arrowLeft",function(Nt){return ee.onKeyDown(Nt)})("keydown.arrowRight",function(Nt){return ee.onKeyDown(Nt)})("keydown.arrowDown",function(Nt){return ee.onKeyDown(Nt)})("keydown.arrowUp",function(Nt){return ee.onKeyDown(Nt)})("keydown.Home",function(Nt){return ee.onKeyDown(Nt)})("keydown.End",function(Nt){return ee.onKeyDown(Nt)})("focusout",function(Nt){return ee.onFocusout(Nt)}),2&U&&(i.\u0275\u0275attribute("aria-orientation","vertical"===ee.orientation&&"tablist"===ee.roles?"vertical":void 0)("role",ee.role?ee.role:ee.roles?"tablist":void 0),i.\u0275\u0275classProp("flex-column","vertical"===ee.orientation))},inputs:{activeId:"activeId",animation:"animation",destroyOnHide:"destroyOnHide",orientation:"orientation",roles:"roles",keyboard:"keyboard"},outputs:{activeIdChange:"activeIdChange",shown:"shown",hidden:"hidden",navChange:"navChange"},exportAs:["ngbNav"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return V})(),Tu=(()=>{class V{constructor(E){this.role=E,this.navItem=(0,i.inject)(Ch),this.nav=(0,i.inject)(Zc),this.nativeElement=(0,i.inject)(i.ElementRef).nativeElement}get tabindex(){return!1===this.nav.keyboard?this.navItem.disabled?-1:void 0:this.nav._navigatingWithKeyboard||this.navItem.disabled||!this.navItem.active?-1:void 0}static#e=this.\u0275fac=function(U){return new(U||V)(i.\u0275\u0275injectAttribute("role"))};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbNavLink",""]],hostAttrs:[1,"nav-link"],hostVars:12,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("id",ee.navItem.domId),i.\u0275\u0275attribute("role",ee.role?ee.role:ee.nav.roles?"tab":void 0)("tabindex",ee.tabindex)("aria-controls",ee.navItem.isPanelInDom()?ee.navItem.panelDomId:null)("aria-selected",ee.navItem.active)("aria-disabled",ee.navItem.disabled),i.\u0275\u0275classProp("nav-item",ee.navItem.isNgContainer())("active",ee.navItem.active)("disabled",ee.navItem.disabled))},standalone:!0})}return V})(),If=(()=>{class V extends Tu{static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["button","ngbNavLink",""]],hostAttrs:["type","button"],hostVars:1,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("click",function(){return ee.nav.click(ee.navItem)}),2&U&&i.\u0275\u0275hostProperty("disabled",ee.navItem.disabled)},standalone:!0,features:[i.\u0275\u0275InheritDefinitionFeature]})}return V})(),C0=(()=>{class V extends Tu{static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["a","ngbNavLink",""]],hostAttrs:["href",""],hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("click",function(Nt){return ee.nav.click(ee.navItem),Nt.preventDefault()})},standalone:!0,features:[i.\u0275\u0275InheritDefinitionFeature]})}return V})();const Ji=({classList:V})=>(V.remove("show"),()=>V.remove("active")),xr=(V,Qe)=>{Qe&&Un(V),V.classList.add("show")};let Dh=(()=>{class V{constructor(){this.nativeElement=(0,i.inject)(i.ElementRef).nativeElement}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbNavPane",""]],hostAttrs:[1,"tab-pane"],hostVars:5,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("id",ee.item.panelDomId),i.\u0275\u0275attribute("role",ee.role?ee.role:ee.nav.roles?"tabpanel":void 0)("aria-labelledby",ee.item.domId),i.\u0275\u0275classProp("fade",ee.nav.animation))},inputs:{item:"item",nav:"nav",role:"role"},standalone:!0})}return V})(),D0=(()=>{class V{constructor(){this._cd=(0,i.inject)(i.ChangeDetectorRef),this._ngZone=(0,i.inject)(i.NgZone),this._activePane=null}isPanelTransitioning(E){return this._activePane?.item===E}ngAfterViewInit(){this._updateActivePane(),this.nav.navItemChange$.pipe(X(this.nav.destroyRef),(0,M.startWith)(this._activePane?.item||null),(0,M.distinctUntilChanged)(),(0,M.skip)(1)).subscribe(E=>{const U={animation:this.nav.animation,runningTransition:"stop"};this._cd.detectChanges(),this._activePane?Mo(this._ngZone,this._activePane.nativeElement,Ji,U).subscribe(()=>{const ee=this._activePane?.item;this._activePane=this._getPaneForItem(E),this._cd.markForCheck(),this._activePane&&(this._activePane.nativeElement.classList.add("active"),Mo(this._ngZone,this._activePane.nativeElement,xr,U).subscribe(()=>{E&&(E.shown.emit(),this.nav.shown.emit(E.id))})),ee&&(ee.hidden.emit(),this.nav.hidden.emit(ee.id))}):this._updateActivePane()})}_updateActivePane(){this._activePane=this._getActivePane(),this._activePane?.nativeElement.classList.add("show","active")}_getPaneForItem(E){return this._panes&&this._panes.find(U=>U.item===E)||null}_getActivePane(){return this._panes&&this._panes.find(E=>E.item.active)||null}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["","ngbNavOutlet",""]],viewQuery:function(U,ee){if(1&U&&i.\u0275\u0275viewQuery(Dh,5),2&U){let Xe;i.\u0275\u0275queryRefresh(Xe=i.\u0275\u0275loadQuery())&&(ee._panes=Xe)}},hostAttrs:[1,"tab-content"],inputs:{paneRole:"paneRole",nav:[0,"ngbNavOutlet","nav"]},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],attrs:Qi,decls:2,vars:0,consts:[["ngbNavPane","",3,"item","nav","role"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(U,ee){1&U&&i.\u0275\u0275repeaterCreate(0,eo,1,1,null,null,i.\u0275\u0275repeaterTrackByIdentity),2&U&&i.\u0275\u0275repeater(ee.nav.items)},dependencies:[Dh,Z.NgTemplateOutlet],encapsulation:2,changeDetection:0})}return V})(),Cg=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Sv=(()=>{class V{constructor(){this.disabled=!1,this.boundaryLinks=!1,this.directionLinks=!0,this.ellipses=!0,this.maxSize=0,this.pageSize=10,this.rotate=!1}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Am=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationEllipsis",""]],standalone:!0})}return V})(),ja=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationFirst",""]],standalone:!0})}return V})(),xs=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationLast",""]],standalone:!0})}return V})(),rd=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationNext",""]],standalone:!0})}return V})(),Yd=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationNumber",""]],standalone:!0})}return V})(),Qu=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationPrevious",""]],standalone:!0})}return V})(),Xd=(()=>{class V{constructor(){this.templateRef=(0,i.inject)(i.TemplateRef)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["ng-template","ngbPaginationPages",""]],standalone:!0})}return V})(),Ev=(()=>{class V{constructor(){this._config=(0,i.inject)(Sv),this.pageCount=0,this.pages=[],this.disabled=this._config.disabled,this.boundaryLinks=this._config.boundaryLinks,this.directionLinks=this._config.directionLinks,this.ellipses=this._config.ellipses,this.rotate=this._config.rotate,this.maxSize=this._config.maxSize,this.page=1,this.pageSize=this._config.pageSize,this.pageChange=new i.EventEmitter(!0),this.size=this._config.size}hasPrevious(){return this.page>1}hasNext(){return this.page<this.pageCount}nextDisabled(){return!this.hasNext()||this.disabled}previousDisabled(){return!this.hasPrevious()||this.disabled}selectPage(E){this._updatePages(E)}ngOnChanges(E){this._updatePages(this.page)}isEllipsis(E){return-1===E}_applyEllipses(E,U){this.ellipses&&(E>0&&(E>2?this.pages.unshift(-1):2===E&&this.pages.unshift(2),this.pages.unshift(1)),U<this.pageCount&&(U<this.pageCount-2?this.pages.push(-1):U===this.pageCount-2&&this.pages.push(this.pageCount-1),this.pages.push(this.pageCount)))}_applyRotation(){let E=0,U=this.pageCount,ee=Math.floor(this.maxSize/2);return this.page<=ee?U=this.maxSize:this.pageCount-this.page<ee?E=this.pageCount-this.maxSize:(E=this.page-ee-1,U=this.page+(this.maxSize%2==0?ee-1:ee)),[E,U]}_applyPagination(){let U=(Math.ceil(this.page/this.maxSize)-1)*this.maxSize;return[U,U+this.maxSize]}_setPageInRange(E){const U=this.page;this.page=Fi(E,this.pageCount,1),this.page!==U&&ar(this.collectionSize)&&this.pageChange.emit(this.page)}_updatePages(E){this.pageCount=Math.ceil(this.collectionSize/this.pageSize),ar(this.pageCount)||(this.pageCount=0),this.pages.length=0;for(let U=1;U<=this.pageCount;U++)this.pages.push(U);if(this._setPageInRange(E),this.maxSize>0&&this.pageCount>this.maxSize){let U=0,ee=this.pageCount;[U,ee]=this.rotate?this._applyRotation():this._applyPagination(),this.pages=this.pages.slice(U,ee),this._applyEllipses(U,ee)}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-pagination"]],contentQueries:function(U,ee,Xe){if(1&U&&(i.\u0275\u0275contentQuery(Xe,Am,5),i.\u0275\u0275contentQuery(Xe,ja,5),i.\u0275\u0275contentQuery(Xe,xs,5),i.\u0275\u0275contentQuery(Xe,rd,5),i.\u0275\u0275contentQuery(Xe,Yd,5),i.\u0275\u0275contentQuery(Xe,Qu,5),i.\u0275\u0275contentQuery(Xe,Xd,5)),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplEllipsis=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplFirst=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplLast=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplNext=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplNumber=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplPrevious=Nt.first),i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.tplPages=Nt.first)}},hostAttrs:["role","navigation"],inputs:{disabled:"disabled",boundaryLinks:"boundaryLinks",directionLinks:"directionLinks",ellipses:"ellipses",rotate:"rotate",collectionSize:"collectionSize",maxSize:"maxSize",page:"page",pageSize:"pageSize",size:"size"},outputs:{pageChange:"pageChange"},standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],decls:20,vars:12,consts:()=>{let E,U,ee,Xe,Nt,Ei,gr,ur;return E=$localize`:@@ngb.pagination.first:««`,U=$localize`:@@ngb.pagination.previous:«`,ee=$localize`:@@ngb.pagination.next:»`,Xe=$localize`:@@ngb.pagination.last:»»`,Nt=$localize`:@@ngb.pagination.first-aria:First`,Ei=$localize`:@@ngb.pagination.previous-aria:Previous`,gr=$localize`:@@ngb.pagination.next-aria:Next`,ur=$localize`:@@ngb.pagination.last-aria:Last`,[["first",""],["previous",""],["next",""],["last",""],["ellipsis",""],["defaultNumber",""],["defaultPages",""],E,U,ee,Xe,[1,"page-item",3,"disabled"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],["aria-hidden","true"],[1,"page-item",3,"active","disabled"],[1,"page-item"],["tabindex","-1","aria-disabled","true",1,"page-link"],["href","",1,"page-link"],["href","",1,"page-link",3,"click"],["aria-label",Nt,"href","",1,"page-link",3,"click"],["aria-label",Ei,"href","",1,"page-link",3,"click"],["aria-label",gr,"href","",1,"page-link",3,"click"],["aria-label",ur,"href","",1,"page-link",3,"click"]]},template:function(U,ee){if(1&U&&(i.\u0275\u0275template(0,hn,2,0,"ng-template",null,0,i.\u0275\u0275templateRefExtractor)(2,Gt,2,0,"ng-template",null,1,i.\u0275\u0275templateRefExtractor)(4,Gn,2,0,"ng-template",null,2,i.\u0275\u0275templateRefExtractor)(6,ri,2,0,"ng-template",null,3,i.\u0275\u0275templateRefExtractor)(8,pi,1,0,"ng-template",null,4,i.\u0275\u0275templateRefExtractor)(10,At,1,1,"ng-template",null,5,i.\u0275\u0275templateRefExtractor)(12,Bi,2,0,"ng-template",null,6,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275elementStart(14,"ul"),i.\u0275\u0275template(15,Ii,3,9,"li",11)(16,Jt,3,8,"li",11)(17,hi,0,0,"ng-template",12)(18,it,3,9,"li",11)(19,Ve,3,9,"li",11),i.\u0275\u0275elementEnd()),2&U){const Xe=i.\u0275\u0275reference(13);i.\u0275\u0275advance(14),i.\u0275\u0275classMap("pagination"+(ee.size?" pagination-"+ee.size:"")),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.boundaryLinks?15:-1),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.directionLinks?16:-1),i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",(null==ee.tplPages?null:ee.tplPages.templateRef)||Xe)("ngTemplateOutletContext",i.\u0275\u0275pureFunction3(8,as,ee.page,ee.pages,ee.disabled)),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.directionLinks?18:-1),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.boundaryLinks?19:-1)}},dependencies:[Z.NgTemplateOutlet],encapsulation:2,changeDetection:0})}return V})(),Ep=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})();const va={hover:["mouseenter","mouseleave"],focus:["focusin","focusout"]};function Bs(V,Qe,E,U,ee,Xe=0,Nt=0){const Ei=function bc(V){const Qe=(V||"").trim();if(0===Qe.length)return[];const E=Qe.split(/\s+/).map(ee=>ee.split(":")).map(ee=>va[ee[0]]||ee),U=E.filter(ee=>ee.includes("manual"));if(U.length>1)throw"Triggers parse error: only one manual trigger is allowed";if(1===U.length&&E.length>1)throw"Triggers parse error: manual trigger can't be mixed with other triggers";return U.length?[]:E}(Qe);if(0===Ei.length)return()=>{};const gr=new Set,ur=[];let vo;function Gr(cs,el){V.addEventListener(cs,el),ur.push(()=>V.removeEventListener(cs,el))}function jo(cs,el){clearTimeout(vo),el>0?vo=setTimeout(cs,el):cs()}for(const[cs,el]of Ei)el?(Gr(cs,()=>{gr.add(cs),jo(()=>gr.size>0&&U(),Xe)}),Gr(el,()=>{gr.delete(cs),jo(()=>0===gr.size&&ee(),Nt)})):Gr(cs,()=>E()?jo(ee,Nt):jo(U,Xe));return()=>ur.forEach(cs=>cs())}let wh=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.autoClose=!0,this.placement="auto",this.popperOptions=E=>E,this.triggers="click",this.disablePopover=!1,this.openDelay=0,this.closeDelay=0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Om=0,Wu=(()=>{class V{isTitleTemplate(){return this.title instanceof i.TemplateRef}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-popover-window"]],hostAttrs:["role","tooltip",2,"position","absolute"],hostVars:5,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("id",ee.id),i.\u0275\u0275classMap("popover"+(ee.popoverClass?" "+ee.popoverClass:"")),i.\u0275\u0275classProp("fade",ee.animation))},inputs:{animation:"animation",title:"title",id:"id",popoverClass:"popoverClass",context:"context"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:4,vars:1,consts:[["simpleTitle",""],["data-popper-arrow","",1,"popover-arrow"],[1,"popover-header"],[1,"popover-body"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275element(0,"div",1),i.\u0275\u0275template(1,bt,4,2,"h3",2),i.\u0275\u0275elementStart(2,"div",3),i.\u0275\u0275projection(3),i.\u0275\u0275elementEnd()),2&U&&(i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.title?1:-1))},dependencies:[Z.NgTemplateOutlet],encapsulation:2,changeDetection:0})}return V})(),zl=(()=>{class V{constructor(){this._config=(0,i.inject)(wh),this.animation=this._config.animation,this.autoClose=this._config.autoClose,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.triggers=this._config.triggers,this.container=this._config.container,this.disablePopover=this._config.disablePopover,this.popoverClass=this._config.popoverClass,this.openDelay=this._config.openDelay,this.closeDelay=this._config.closeDelay,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter,this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._ngZone=(0,i.inject)(i.NgZone),this._document=(0,i.inject)(Z.DOCUMENT),this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._injector=(0,i.inject)(i.Injector),this._ngbPopoverWindowId="ngb-popover-"+Om++,this._popupService=new ro(Wu),this._windowRef=null,this._positioning=Gs()}open(E){if(!this._windowRef&&!this._isDisabled()){const{windowRef:U,transition$:ee}=this._popupService.open(this.ngbPopover,E??this.popoverContext,this.animation);this._windowRef=U,this._windowRef.setInput("animation",this.animation),this._windowRef.setInput("title",this.popoverTitle),this._windowRef.setInput("context",E??this.popoverContext),this._windowRef.setInput("popoverClass",this.popoverClass),this._windowRef.setInput("id",this._ngbPopoverWindowId),this._getPositionTargetElement().setAttribute("aria-describedby",this._ngbPopoverWindowId),"body"===this.container&&this._document.body.appendChild(this._windowRef.location.nativeElement),this._windowRef.changeDetectorRef.detectChanges(),this._windowRef.changeDetectorRef.markForCheck(),this._ngZone.runOutsideAngular(()=>{this._positioning.createPopper({hostElement:this._getPositionTargetElement(),targetElement:this._windowRef.location.nativeElement,placement:this.placement,baseClass:"bs-popover",updatePopperOptions:Xe=>this.popperOptions(lc([0,8])(Xe))}),Promise.resolve().then(()=>{this._positioning.update()}),this._afterRenderRef=(0,i.afterRender)(()=>{this._positioning.update()},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector})}),Ds(this._ngZone,this._document,this.autoClose,()=>this.close(),this.hidden,[this._windowRef.location.nativeElement]),ee.subscribe(()=>this.shown.emit())}}close(E=this.animation){this._windowRef&&(this._getPositionTargetElement().removeAttribute("aria-describedby"),this._popupService.close(E).subscribe(()=>{this._windowRef=null,this._positioning.destroy(),this._afterRenderRef?.destroy(),this.hidden.emit(),this._changeDetector.markForCheck()}))}toggle(){this._windowRef?this.close():this.open()}isOpen(){return null!=this._windowRef}ngOnInit(){this._unregisterListenersFn=Bs(this._nativeElement,this.triggers,this.isOpen.bind(this),this.open.bind(this),this.close.bind(this),+this.openDelay,+this.closeDelay)}ngOnChanges({ngbPopover:E,popoverTitle:U,disablePopover:ee,popoverClass:Xe}){Xe&&this.isOpen()&&this._windowRef.setInput("popoverClass",Xe.currentValue),(E||U||ee)&&this._isDisabled()&&this.close()}ngOnDestroy(){this.close(!1),this._unregisterListenersFn?.()}_isDisabled(){return!!this.disablePopover||!this.ngbPopover&&!this.popoverTitle}_getPositionTargetElement(){return(Ui(this.positionTarget)?this._document.querySelector(this.positionTarget):this.positionTarget)||this._nativeElement}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbPopover",""]],inputs:{animation:"animation",autoClose:"autoClose",ngbPopover:"ngbPopover",popoverTitle:"popoverTitle",placement:"placement",popperOptions:"popperOptions",triggers:"triggers",positionTarget:"positionTarget",container:"container",disablePopover:"disablePopover",popoverClass:"popoverClass",popoverContext:"popoverContext",openDelay:"openDelay",closeDelay:"closeDelay"},outputs:{shown:"shown",hidden:"hidden"},exportAs:["ngbPopover"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return V})(),Tp=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Mp=(()=>{class V{constructor(){this.max=100,this.animated=!1,this.ariaLabel="progress bar",this.striped=!1,this.showValue=!1}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Zd=(()=>{class V{set max(E){this._max=!ar(E)||E<=0?100:E}get max(){return this._max}constructor(){this._config=(0,i.inject)(Mp),this.stacked=(0,i.inject)(Fm,{optional:!0}),this.animated=this._config.animated,this.ariaLabel=this._config.ariaLabel,this.striped=this._config.striped,this.showValue=this._config.showValue,this.textType=this._config.textType,this.type=this._config.type,this.value=0,this.height=this._config.height,this.max=this._config.max}getValue(){return Fi(this.value,this.max)}getPercentValue(){return 100*this.getValue()/this.max}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-progressbar"]],hostAttrs:["role","progressbar","aria-valuemin","0",1,"progress"],hostVars:7,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275attribute("aria-valuenow",ee.getValue())("aria-valuemax",ee.max)("aria-label",ee.ariaLabel),i.\u0275\u0275styleProp("width",ee.stacked?ee.getPercentValue():null,"%")("height",ee.height))},inputs:{max:"max",animated:"animated",ariaLabel:"ariaLabel",striped:"striped",showValue:"showValue",textType:"textType",type:"type",value:"value",height:"height"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:3,vars:11,consts:()=>{let E;return E=$localize`:@@ngb.progressbar.value:${"\ufffd0\ufffd"}:INTERPOLATION:`,[E]},template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275elementStart(0,"div"),i.\u0275\u0275template(1,nn,3,3,"span"),i.\u0275\u0275projection(2),i.\u0275\u0275elementEnd()),2&U&&(i.\u0275\u0275classMapInterpolate2("progress-bar",ee.type?ee.textType?" bg-"+ee.type:" text-bg-"+ee.type:"","",ee.textType?" text-"+ee.textType:"",""),i.\u0275\u0275styleProp("width",ee.stacked?null:ee.getPercentValue(),"%"),i.\u0275\u0275classProp("progress-bar-animated",ee.animated)("progress-bar-striped",ee.striped),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.showValue?1:-1))},dependencies:[Z.PercentPipe],encapsulation:2,changeDetection:0})}return V})(),Fm=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-progressbar-stacked"]],hostAttrs:[1,"progress-stacked"],standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:1,vars:0,template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275projection(0))},encapsulation:2,changeDetection:0})}return V})(),ap=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Af=(()=>{class V{constructor(){this.max=10,this.readonly=!1,this.resettable=!1,this.tabindex=0}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),_d=(()=>{class V{constructor(){this.contexts=[],this._config=(0,i.inject)(Af),this._changeDetectorRef=(0,i.inject)(i.ChangeDetectorRef),this.disabled=!1,this.max=this._config.max,this.readonly=this._config.readonly,this.resettable=this._config.resettable,this.tabindex=this._config.tabindex,this.hover=new i.EventEmitter,this.leave=new i.EventEmitter,this.rateChange=new i.EventEmitter(!0),this.onChange=E=>{},this.onTouched=()=>{}}ariaValueText(E,U){return`${E} out of ${U}`}isInteractive(){return!this.readonly&&!this.disabled}enter(E){this.isInteractive()&&this._updateState(E),this.hover.emit(E)}handleBlur(){this.onTouched()}handleClick(E){this.isInteractive()&&this.update(this.resettable&&this.rate===E?0:E)}handleKeyDown(E){switch(E.key){case"ArrowDown":case"ArrowLeft":this.update(this.rate-1);break;case"ArrowUp":case"ArrowRight":this.update(this.rate+1);break;case"Home":this.update(0);break;case"End":this.update(this.max);break;default:return}E.preventDefault()}ngOnChanges(E){E.rate&&this.update(this.rate),E.max&&this._updateMax()}ngOnInit(){this._setupContexts(),this._updateState(this.rate)}registerOnChange(E){this.onChange=E}registerOnTouched(E){this.onTouched=E}reset(){this.leave.emit(this.nextRate),this._updateState(this.rate)}setDisabledState(E){this.disabled=E}update(E,U=!0){const ee=Fi(E,this.max,0);this.isInteractive()&&this.rate!==ee&&(this.rate=ee,this.rateChange.emit(this.rate)),U&&(this.onChange(this.rate),this.onTouched()),this._updateState(this.rate)}writeValue(E){this.update(E,!1),this._changeDetectorRef.markForCheck()}_updateState(E){this.nextRate=E,this.contexts.forEach((U,ee)=>U.fill=Math.round(100*Fi(E-ee,1,0)))}_updateMax(){this.max>0&&(this._setupContexts(),this.update(this.rate))}_setupContexts(){this.contexts=Array.from({length:this.max},(E,U)=>({fill:0,index:U}))}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-rating"]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,i.TemplateRef,5),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.starTemplateFromContent=Nt.first)}},hostAttrs:["role","slider","aria-valuemin","0",1,"d-inline-flex"],hostVars:6,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("blur",function(){return ee.handleBlur()})("keydown",function(Nt){return ee.handleKeyDown(Nt)})("mouseleave",function(){return ee.reset()}),2&U&&(i.\u0275\u0275hostProperty("tabindex",ee.disabled?-1:ee.tabindex),i.\u0275\u0275attribute("aria-valuemax",ee.max)("aria-valuenow",ee.nextRate)("aria-valuetext",ee.ariaValueText(ee.nextRate,ee.max))("aria-readonly",!(!ee.readonly||ee.disabled)||null)("aria-disabled",!!ee.disabled||null))},inputs:{disabled:"disabled",max:"max",rate:"rate",readonly:"readonly",resettable:"resettable",starTemplate:"starTemplate",tabindex:"tabindex",ariaValueText:"ariaValueText"},outputs:{hover:"hover",leave:"leave",rateChange:"rateChange"},standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:ce.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>V),multi:!0}]),i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],decls:4,vars:0,consts:[["t",""],[1,"visually-hidden"],[3,"mouseenter","click"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(U,ee){1&U&&(i.\u0275\u0275template(0,Jn,1,1,"ng-template",null,0,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275repeaterCreate(2,_r,4,5,null,null,i.\u0275\u0275repeaterTrackByIdentity)),2&U&&(i.\u0275\u0275advance(2),i.\u0275\u0275repeater(ee.contexts))},dependencies:[Z.NgTemplateOutlet],encapsulation:2,changeDetection:0})}return V})(),Mu=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})();function Jd(V,Qe){return V&&null!=Qe?Ui(Qe)?V.querySelector(`#${CSS.escape(Qe)}`):Qe:null}const Iu=(V,Qe,E)=>{const{rootElement:U,fragments:ee,scrollSpy:Xe,options:Nt,entries:Ei}=V,gr=function W_(V,Qe){const E=[...Qe].map(({id:U})=>`#${CSS.escape(U)}`).join(",");return Array.from(V.querySelectorAll(E))}(U,ee);if(!E.initialized){E.initialized=!0,E.gapFragment=null,E.visibleFragments=new Set;const ur=Jd(U,Nt?.initialFragment);if(ur)return void Xe.scrollTo(ur)}for(const ur of Ei){const{isIntersecting:vo,target:Gr}=ur;if(vo)E.gapFragment&&(E.visibleFragments.delete(E.gapFragment),E.gapFragment=null),E.visibleFragments.add(Gr);else if(E.visibleFragments.delete(Gr),0===E.visibleFragments.size&&""!==Xe.active)if(ur.boundingClientRect.top<ur.rootBounds.top)E.gapFragment=Gr,E.visibleFragments.add(E.gapFragment);else{if(Gr===gr[0])return E.gapFragment=null,E.visibleFragments.clear(),void Qe("");{const jo=gr.indexOf(Gr);E.gapFragment=gr[jo-1]||null,E.gapFragment&&E.visibleFragments.add(E.gapFragment)}}}for(const ur of gr)if(E.visibleFragments.has(ur)){Qe(ur.id);break}};let ns=(()=>{class V{constructor(){this.scrollBehavior="smooth",this.processChanges=Iu}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),gf=(()=>{class V{constructor(){this._observer=null,this._containerElement=null,this._fragments=new Set,this._preRegisteredFragments=new Set,this._active$=new e.Subject,this._distinctActive$=this._active$.pipe((0,M.distinctUntilChanged)()),this._active="",this._config=(0,i.inject)(ns),this._document=(0,i.inject)(Z.DOCUMENT),this._platformId=(0,i.inject)(i.PLATFORM_ID),this._scrollBehavior=this._config.scrollBehavior,this._diChangeDetectorRef=(0,i.inject)(i.ChangeDetectorRef,{optional:!0}),this._changeDetectorRef=this._diChangeDetectorRef,this._zone=(0,i.inject)(i.NgZone),this._distinctActive$.pipe(X()).subscribe(E=>{this._active=E,this._changeDetectorRef?.markForCheck()})}get active(){return this._active}get active$(){return this._distinctActive$}start(E){if((0,Z.isPlatformBrowser)(this._platformId)){this._cleanup();const{root:U,rootMargin:ee,scrollBehavior:Xe,threshold:Nt,fragments:Ei,changeDetectorRef:gr,processChanges:ur}={...E};this._containerElement=U??this._document.documentElement,this._changeDetectorRef=gr??this._diChangeDetectorRef,this._scrollBehavior=Xe??this._config.scrollBehavior;const vo=ur??this._config.processChanges,Gr={};this._observer=new IntersectionObserver(jo=>vo({entries:jo,rootElement:this._containerElement,fragments:this._fragments,scrollSpy:this,options:{...E}},cs=>this._active$.next(cs),Gr),{root:U??this._document,...ee&&{rootMargin:ee},...Nt&&{threshold:Nt}});for(const jo of[...this._preRegisteredFragments,...Ei??[]])this.observe(jo);this._preRegisteredFragments.clear()}}stop(){this._cleanup(),this._active$.next("")}scrollTo(E,U){const{behavior:ee}={behavior:this._scrollBehavior,...U};if(this._containerElement){const Xe=Jd(this._containerElement,E);if(Xe){this._containerElement.scrollTo({top:Xe.offsetTop-this._containerElement.offsetTop,behavior:ee});let Ei=this._containerElement.scrollTop,gr=0;const ur=this._containerElement;this._zone.runOutsideAngular(()=>{const vo=()=>{const Gr=Ei===ur.scrollTop;Gr?gr++:gr=0,!Gr||Gr&&gr<3?(Ei=ur.scrollTop,requestAnimationFrame(vo)):this._zone.run(()=>this._active$.next(Xe.id))};requestAnimationFrame(vo)})}}}observe(E){if(!this._observer)return void this._preRegisteredFragments.add(E);const U=Jd(this._containerElement,E);U&&!this._fragments.has(U)&&(this._fragments.add(U),this._observer.observe(U))}unobserve(E){if(!this._observer)return void this._preRegisteredFragments.delete(E);const U=Jd(this._containerElement,E);if(U){this._fragments.delete(U),this._observer.disconnect();for(const ee of this._fragments)this._observer.observe(ee)}}ngOnDestroy(){this._cleanup()}_cleanup(){this._fragments.clear(),this._observer?.disconnect(),this._changeDetectorRef=this._diChangeDetectorRef,this._scrollBehavior=this._config.scrollBehavior,this._observer=null,this._containerElement=null}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Zp=(()=>{class V{constructor(){this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._scrollSpyMenu=(0,i.inject)(xh,{optional:!0}),this._scrollSpyAPI=this._scrollSpyMenu??(0,i.inject)(gf),this._destroyRef=(0,i.inject)(i.DestroyRef),this._isActive=!1}set data(E){Array.isArray(E)?(this._scrollSpyAPI=E[0],this.fragment=E[1],this.parent??=E[2]):E instanceof Tv?this._scrollSpyAPI=E:Ui(E)&&(this.fragment=E)}ngOnInit(){this._scrollSpyMenu||this._scrollSpyAPI.active$.pipe(X(this._destroyRef)).subscribe(E=>{E===this.fragment?this._activate():this._deactivate(),this._changeDetector.markForCheck()})}_activate(){this._isActive=!0,this._scrollSpyMenu&&this._scrollSpyMenu.getItem(this.parent??"")?._activate()}_deactivate(){this._isActive=!1,this._scrollSpyMenu&&this._scrollSpyMenu.getItem(this.parent??"")?._deactivate()}isActive(){return this._isActive}scrollTo(E){this._scrollSpyAPI.scrollTo(this.fragment,E)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbScrollSpyItem",""]],hostVars:2,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("click",function(){return ee.scrollTo()}),2&U&&i.\u0275\u0275classProp("active",ee.isActive())},inputs:{data:[0,"ngbScrollSpyItem","data"],fragment:"fragment",parent:"parent"},exportAs:["ngbScrollSpyItem"],standalone:!0})}return V})(),xh=(()=>{class V{constructor(){this._scrollSpyRef=(0,i.inject)(gf),this._destroyRef=(0,i.inject)(i.DestroyRef),this._map=new Map,this._lastActiveItem=null}set scrollSpy(E){this._scrollSpyRef=E}get active(){return this._scrollSpyRef.active}get active$(){return this._scrollSpyRef.active$}scrollTo(E,U){this._scrollSpyRef.scrollTo(E,U)}getItem(E){return this._map.get(E)}ngAfterViewInit(){this._items.changes.pipe(X(this._destroyRef)).subscribe(()=>this._rebuildMap()),this._rebuildMap(),this._scrollSpyRef.active$.pipe(X(this._destroyRef)).subscribe(E=>{this._lastActiveItem?._deactivate();const U=this._map.get(E);U&&(U._activate(),this._lastActiveItem=U)})}_rebuildMap(){this._map.clear();for(let E of this._items)this._map.set(E.fragment,E)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbScrollSpyMenu",""]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,Zp,5),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee._items=Nt)}},inputs:{scrollSpy:[0,"ngbScrollSpyMenu","scrollSpy"]},standalone:!0})}return V})(),Tv=(()=>{class V{constructor(){this._initialFragment=null,this._service=(0,i.inject)(gf),this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this.activeChange=this._service.active$}set active(E){this._initialFragment=E,this.scrollTo(E)}get active(){return this._service.active}get active$(){return this._service.active$}ngAfterViewInit(){this._service.start({processChanges:this.processChanges,root:this._nativeElement,rootMargin:this.rootMargin,threshold:this.threshold,...this._initialFragment&&{initialFragment:this._initialFragment}})}_registerFragment(E){this._service.observe(E.id)}_unregisterFragment(E){this._service.unobserve(E.id)}scrollTo(E,U){this._service.scrollTo(E,{...this.scrollBehavior&&{behavior:this.scrollBehavior},...U})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbScrollSpy",""]],hostAttrs:["tabindex","0",2,"overflow-y","auto"],inputs:{processChanges:"processChanges",rootMargin:"rootMargin",scrollBehavior:"scrollBehavior",threshold:"threshold",active:"active"},outputs:{activeChange:"activeChange"},exportAs:["ngbScrollSpy"],standalone:!0,features:[i.\u0275\u0275ProvidersFeature([gf])]})}return V})(),Md=(()=>{class V{constructor(){this._destroyRef=(0,i.inject)(i.DestroyRef),this._scrollSpy=(0,i.inject)(Tv)}ngAfterViewInit(){this._scrollSpy._registerFragment(this),this._destroyRef.onDestroy(()=>this._scrollSpy._unregisterFragment(this))}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbScrollSpyFragment",""]],hostVars:1,hostBindings:function(U,ee){2&U&&i.\u0275\u0275hostProperty("id",ee.id)},inputs:{id:[0,"ngbScrollSpyFragment","id"]},standalone:!0})}return V})(),Of=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})();class Qf{constructor(Qe,E,U){this.hour=Rt(Qe),this.minute=Rt(E),this.second=Rt(U)}changeHour(Qe=1){this.updateHour((isNaN(this.hour)?0:this.hour)+Qe)}updateHour(Qe){this.hour=ar(Qe)?(Qe<0?24+Qe:Qe)%24:NaN}changeMinute(Qe=1){this.updateMinute((isNaN(this.minute)?0:this.minute)+Qe)}updateMinute(Qe){ar(Qe)?(this.minute=Qe%60<0?60+Qe%60:Qe%60,this.changeHour(Math.floor(Qe/60))):this.minute=NaN}changeSecond(Qe=1){this.updateSecond((isNaN(this.second)?0:this.second)+Qe)}updateSecond(Qe){ar(Qe)?(this.second=Qe<0?60+Qe%60:Qe%60,this.changeMinute(Math.floor(Qe/60))):this.second=NaN}isValid(Qe=!0){return ar(this.hour)&&ar(this.minute)&&(!Qe||ar(this.second))}toString(){return`${this.hour||0}:${this.minute||0}:${this.second||0}`}}let w0=(()=>{class V{constructor(){this.meridian=!1,this.spinners=!0,this.seconds=!1,this.hourStep=1,this.minuteStep=1,this.secondStep=1,this.disabled=!1,this.readonlyInputs=!1,this.size="medium"}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Ip=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>function r1(){return new Mv}(),providedIn:"root"})}return V})(),Mv=(()=>{class V extends Ip{fromModel(E){return E&&er(E.hour)&&er(E.minute)?{hour:E.hour,minute:E.minute,second:er(E.second)?E.second:null}:null}toModel(E){return E&&er(E.hour)&&er(E.minute)?{hour:E.hour,minute:E.minute,second:er(E.second)?E.second:null}:null}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})(),Xh=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:()=>new Nm,providedIn:"root"})}return V})(),Nm=(()=>{class V extends Xh{constructor(){super(...arguments),this._locale=(0,i.inject)(i.LOCALE_ID),this._periods=[(0,Z.formatDate)(new Date(36e5),"a",this._locale,"UTC"),(0,Z.formatDate)(new Date(468e5),"a",this._locale,"UTC")]}getMorningPeriod(){return this._periods[0]}getAfternoonPeriod(){return this._periods[1]}static#e=this.\u0275fac=(()=>{let E;return function(ee){return(E||(E=i.\u0275\u0275getInheritedFactory(V)))(ee||V)}})();static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac})}return V})();const od=/[^0-9]/g;let tD=(()=>{class V{set hourStep(E){this._hourStep=er(E)?E:this._config.hourStep}get hourStep(){return this._hourStep}set minuteStep(E){this._minuteStep=er(E)?E:this._config.minuteStep}get minuteStep(){return this._minuteStep}set secondStep(E){this._secondStep=er(E)?E:this._config.secondStep}get secondStep(){return this._secondStep}constructor(E,U,ee,Xe){this._config=E,this._ngbTimeAdapter=U,this._cd=ee,this.i18n=Xe,this.onChange=Nt=>{},this.onTouched=()=>{},this.meridian=E.meridian,this.spinners=E.spinners,this.seconds=E.seconds,this.hourStep=E.hourStep,this.minuteStep=E.minuteStep,this.secondStep=E.secondStep,this.disabled=E.disabled,this.readonlyInputs=E.readonlyInputs,this.size=E.size}writeValue(E){const U=this._ngbTimeAdapter.fromModel(E);this.model=U?new Qf(U.hour,U.minute,U.second):new Qf,!this.seconds&&(!U||!ar(U.second))&&(this.model.second=0),this._cd.markForCheck()}registerOnChange(E){this.onChange=E}registerOnTouched(E){this.onTouched=E}setDisabledState(E){this.disabled=E}changeHour(E){this.model?.changeHour(E),this.propagateModelChange()}changeMinute(E){this.model?.changeMinute(E),this.propagateModelChange()}changeSecond(E){this.model?.changeSecond(E),this.propagateModelChange()}updateHour(E){const U=!!this.model&&this.model.hour>=12,ee=Rt(E);this.model?.updateHour(this.meridian&&(U&&ee<12||!U&&12===ee)?ee+12:ee),this.propagateModelChange()}updateMinute(E){this.model?.updateMinute(Rt(E)),this.propagateModelChange()}updateSecond(E){this.model?.updateSecond(Rt(E)),this.propagateModelChange()}toggleMeridian(){this.meridian&&this.changeHour(12)}formatInput(E){E.value=E.value.replace(od,"")}formatHour(E){return ar(E)?cn(this.meridian?E%12==0?12:E%12:E%24):cn(NaN)}formatMinSec(E){return cn(ar(E)?E:NaN)}handleBlur(){this.onTouched()}get isSmallSize(){return"small"===this.size}get isLargeSize(){return"large"===this.size}ngOnChanges(E){E.seconds&&!this.seconds&&this.model&&!ar(this.model.second)&&(this.model.second=0,this.propagateModelChange(!1))}propagateModelChange(E=!0){E&&this.onTouched(),this.model?.isValid(this.seconds)?this.onChange(this._ngbTimeAdapter.toModel({hour:this.model.hour,minute:this.model.minute,second:this.model.second})):this.onChange(this._ngbTimeAdapter.toModel(null))}static#e=this.\u0275fac=function(U){return new(U||V)(i.\u0275\u0275directiveInject(w0),i.\u0275\u0275directiveInject(Ip),i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(Xh))};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-timepicker"]],inputs:{meridian:"meridian",spinners:"spinners",seconds:"seconds",hourStep:"hourStep",minuteStep:"minuteStep",secondStep:"secondStep",readonlyInputs:"readonlyInputs",size:"size"},exportAs:["ngbTimepicker"],standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:ce.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>V),multi:!0}]),i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],decls:14,vars:23,consts:()=>{let E,U,ee,Xe,Nt,Ei,gr,ur,vo,Gr,jo,cs,el;return E=$localize`:@@ngb.timepicker.HH:HH`,U=$localize`:@@ngb.timepicker.hours:Hours`,ee=$localize`:@@ngb.timepicker.MM:MM`,Xe=$localize`:@@ngb.timepicker.minutes:Minutes`,Nt=$localize`:@@ngb.timepicker.increment-hours:Increment hours`,Ei=$localize`:@@ngb.timepicker.decrement-hours:Decrement hours`,gr=$localize`:@@ngb.timepicker.increment-minutes:Increment minutes`,ur=$localize`:@@ngb.timepicker.decrement-minutes:Decrement minutes`,vo=$localize`:@@ngb.timepicker.SS:SS`,Gr=$localize`:@@ngb.timepicker.seconds:Seconds`,jo=$localize`:@@ngb.timepicker.increment-seconds:Increment seconds`,cs=$localize`:@@ngb.timepicker.decrement-seconds:Decrement seconds`,el=$localize`:@@ngb.timepicker.PM:${"\ufffd0\ufffd"}:INTERPOLATION:`,[Nt,Ei,gr,ur,jo,cs,el,[3,"disabled"],[1,"ngb-tp"],[1,"ngb-tp-input-container","ngb-tp-hour"],["tabindex","-1","type","button",1,"btn","btn-link",3,"btn-sm","btn-lg","disabled"],["type","text","maxlength","2","inputmode","numeric","placeholder",E,"aria-label",U,1,"ngb-tp-input","form-control",3,"change","blur","input","keydown.ArrowUp","keydown.ArrowDown","value","readOnly","disabled"],[1,"ngb-tp-spacer"],[1,"ngb-tp-input-container","ngb-tp-minute"],["type","text","maxlength","2","inputmode","numeric","placeholder",ee,"aria-label",Xe,1,"ngb-tp-input","form-control",3,"change","blur","input","keydown.ArrowUp","keydown.ArrowDown","value","readOnly","disabled"],["tabindex","-1","type","button",1,"btn","btn-link",3,"click","disabled"],[1,"chevron","ngb-tp-chevron"],[1,"visually-hidden"],[1,"chevron","ngb-tp-chevron","bottom"],[1,"ngb-tp-input-container","ngb-tp-second"],["type","text","maxlength","2","inputmode","numeric","placeholder",vo,"aria-label",Gr,1,"ngb-tp-input","form-control",3,"change","blur","input","keydown.ArrowUp","keydown.ArrowDown","value","readOnly","disabled"],[1,"ngb-tp-meridian"],["type","button",1,"btn","btn-outline-primary",3,"click","disabled"]]},template:function(U,ee){1&U&&(i.\u0275\u0275elementStart(0,"fieldset",7)(1,"div",8)(2,"div",9),i.\u0275\u0275template(3,qr,4,7,"button",10),i.\u0275\u0275elementStart(4,"input",11),i.\u0275\u0275listener("change",function(Nt){return ee.updateHour(Nt.target.value)})("blur",function(){return ee.handleBlur()})("input",function(Nt){return ee.formatInput(Nt.target)})("keydown.ArrowUp",function(Nt){return ee.changeHour(ee.hourStep),Nt.preventDefault()})("keydown.ArrowDown",function(Nt){return ee.changeHour(-ee.hourStep),Nt.preventDefault()}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(5,Bo,4,7,"button",10),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(6,"div",12),i.\u0275\u0275text(7,":"),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(8,"div",13),i.\u0275\u0275template(9,Eo,4,7,"button",10),i.\u0275\u0275elementStart(10,"input",14),i.\u0275\u0275listener("change",function(Nt){return ee.updateMinute(Nt.target.value)})("blur",function(){return ee.handleBlur()})("input",function(Nt){return ee.formatInput(Nt.target)})("keydown.ArrowUp",function(Nt){return ee.changeMinute(ee.minuteStep),Nt.preventDefault()})("keydown.ArrowDown",function(Nt){return ee.changeMinute(-ee.minuteStep),Nt.preventDefault()}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(11,Ro,4,7,"button",10),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(12,Va,6,9)(13,vl,5,8),i.\u0275\u0275elementEnd()()),2&U&&(i.\u0275\u0275classProp("disabled",ee.disabled),i.\u0275\u0275property("disabled",ee.disabled),i.\u0275\u0275advance(3),i.\u0275\u0275conditional(ee.spinners?3:-1),i.\u0275\u0275advance(),i.\u0275\u0275classProp("form-control-sm",ee.isSmallSize)("form-control-lg",ee.isLargeSize),i.\u0275\u0275property("value",ee.formatHour(null==ee.model?null:ee.model.hour))("readOnly",ee.readonlyInputs)("disabled",ee.disabled),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.spinners?5:-1),i.\u0275\u0275advance(4),i.\u0275\u0275conditional(ee.spinners?9:-1),i.\u0275\u0275advance(),i.\u0275\u0275classProp("form-control-sm",ee.isSmallSize)("form-control-lg",ee.isLargeSize),i.\u0275\u0275property("value",ee.formatMinSec(null==ee.model?null:ee.model.minute))("readOnly",ee.readonlyInputs)("disabled",ee.disabled),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.spinners?11:-1),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.seconds?12:-1),i.\u0275\u0275advance(),i.\u0275\u0275conditional(ee.meridian?13:-1))},styles:['ngb-timepicker{font-size:1rem}.ngb-tp{display:flex;align-items:center}.ngb-tp-input-container{width:4em}.ngb-tp-chevron:before{border-style:solid;border-width:.29em .29em 0 0;content:"";display:inline-block;height:.69em;left:.05em;position:relative;top:.15em;transform:rotate(-45deg);vertical-align:middle;width:.69em}.ngb-tp-chevron.bottom:before{top:-.3em;transform:rotate(135deg)}.ngb-tp-input{text-align:center}.ngb-tp-hour,.ngb-tp-minute,.ngb-tp-second,.ngb-tp-meridian{display:flex;flex-direction:column;align-items:center;justify-content:space-around}.ngb-tp-spacer{width:1em;text-align:center}\n'],encapsulation:2})}return V})(),Iv=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),mu=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.autohide=!0,this.delay=5e3,this.ariaLive="polite"}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();const Zh=(V,Qe)=>{const{classList:E}=V;if(Qe)return E.add("fade"),Un(V),E.add("show","showing"),()=>{E.remove("showing")};E.add("show")},H_=({classList:V})=>(V.add("showing"),()=>{V.remove("show","showing")});let Ff=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbToastHeader",""]],standalone:!0})}return V})(),yd=(()=>{class V{constructor(E){this.ariaLive=E,this._config=(0,i.inject)(mu),this._zone=(0,i.inject)(i.NgZone),this._injector=(0,i.inject)(i.Injector),this._element=(0,i.inject)(i.ElementRef),this.animation=this._config.animation,this.delay=this._config.delay,this.autohide=this._config.autohide,this.contentHeaderTpl=null,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter,this.ariaLive??=this._config.ariaLive}ngAfterContentInit(){(0,i.afterNextRender)(()=>{this._init(),this.show()},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector})}ngOnChanges(E){"autohide"in E&&(this._clearTimeout(),this._init())}hide(){this._clearTimeout();const E=Mo(this._zone,this._element.nativeElement,H_,{animation:this.animation,runningTransition:"stop"});return E.subscribe(()=>{this.hidden.emit()}),E}show(){const E=Mo(this._zone,this._element.nativeElement,Zh,{animation:this.animation,runningTransition:"continue"});return E.subscribe(()=>{this.shown.emit()}),E}_init(){this.autohide&&!this._timeoutID&&(this._timeoutID=setTimeout(()=>this.hide(),this.delay))}_clearTimeout(){this._timeoutID&&(clearTimeout(this._timeoutID),this._timeoutID=null)}static#e=this.\u0275fac=function(U){return new(U||V)(i.\u0275\u0275injectAttribute("aria-live"))};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-toast"]],contentQueries:function(U,ee,Xe){if(1&U&&i.\u0275\u0275contentQuery(Xe,Ff,7,i.TemplateRef),2&U){let Nt;i.\u0275\u0275queryRefresh(Nt=i.\u0275\u0275loadQuery())&&(ee.contentHeaderTpl=Nt.first)}},hostAttrs:["role","alert","aria-atomic","true",1,"toast"],hostVars:3,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275attribute("aria-live",ee.ariaLive),i.\u0275\u0275classProp("fade",ee.animation))},inputs:{animation:"animation",delay:"delay",autohide:"autohide",header:"header"},outputs:{shown:"shown",hidden:"hidden"},exportAs:["ngbToast"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:5,vars:1,consts:()=>{let E;return E=$localize`:@@ngb.toast.close-aria:Close`,[["headerTpl",""],[1,"toast-header"],[1,"toast-body"],[1,"me-auto"],[3,"ngTemplateOutlet"],["type","button","aria-label",E,1,"btn-close",3,"click"]]},template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275template(0,Na,2,1,"ng-template",null,0,i.\u0275\u0275templateRefExtractor)(2,gs,3,1,"div",1),i.\u0275\u0275elementStart(3,"div",2),i.\u0275\u0275projection(4),i.\u0275\u0275elementEnd()),2&U&&(i.\u0275\u0275advance(2),i.\u0275\u0275conditional(ee.contentHeaderTpl||ee.header?2:-1))},dependencies:[Z.NgTemplateOutlet],styles:["ngb-toast{display:block}ngb-toast .toast-header .close{margin-left:auto;margin-bottom:.25rem}\n"],encapsulation:2})}return V})(),Rm=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Lm=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.autoClose=!0,this.placement="auto",this.popperOptions=E=>E,this.triggers="hover focus",this.disableTooltip=!1,this.openDelay=0,this.closeDelay=0}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Sh=0,Dg=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-tooltip-window"]],hostAttrs:["role","tooltip"],hostVars:5,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275hostProperty("id",ee.id),i.\u0275\u0275classMap("tooltip"+(ee.tooltipClass?" "+ee.tooltipClass:"")),i.\u0275\u0275classProp("fade",ee.animation))},inputs:{animation:"animation",id:"id",tooltipClass:"tooltipClass"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:3,vars:0,consts:[["data-popper-arrow","",1,"tooltip-arrow"],[1,"tooltip-inner"]],template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275element(0,"div",0),i.\u0275\u0275elementStart(1,"div",1),i.\u0275\u0275projection(2),i.\u0275\u0275elementEnd())},styles:["ngb-tooltip-window{pointer-events:none;position:absolute}ngb-tooltip-window .tooltip-inner{pointer-events:auto}ngb-tooltip-window.bs-tooltip-top,ngb-tooltip-window.bs-tooltip-bottom{padding-left:0;padding-right:0}ngb-tooltip-window.bs-tooltip-start,ngb-tooltip-window.bs-tooltip-end{padding-top:0;padding-bottom:0}\n"],encapsulation:2,changeDetection:0})}return V})(),km=(()=>{class V{constructor(){this._config=(0,i.inject)(Lm),this.animation=this._config.animation,this.autoClose=this._config.autoClose,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.triggers=this._config.triggers,this.container=this._config.container,this.disableTooltip=this._config.disableTooltip,this.tooltipClass=this._config.tooltipClass,this.openDelay=this._config.openDelay,this.closeDelay=this._config.closeDelay,this.shown=new i.EventEmitter,this.hidden=new i.EventEmitter,this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._ngZone=(0,i.inject)(i.NgZone),this._document=(0,i.inject)(Z.DOCUMENT),this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._injector=(0,i.inject)(i.Injector),this._ngbTooltipWindowId="ngb-tooltip-"+Sh++,this._popupService=new ro(Dg),this._windowRef=null,this._positioning=Gs()}set ngbTooltip(E){this._ngbTooltip=E,!E&&this._windowRef&&this.close()}get ngbTooltip(){return this._ngbTooltip}open(E){if(!this._windowRef&&this._ngbTooltip&&!this.disableTooltip){const{windowRef:U,transition$:ee}=this._popupService.open(this._ngbTooltip,E??this.tooltipContext,this.animation);this._windowRef=U,this._windowRef.setInput("animation",this.animation),this._windowRef.setInput("tooltipClass",this.tooltipClass),this._windowRef.setInput("id",this._ngbTooltipWindowId),this._getPositionTargetElement().setAttribute("aria-describedby",this._ngbTooltipWindowId),"body"===this.container&&this._document.body.appendChild(this._windowRef.location.nativeElement),this._windowRef.changeDetectorRef.detectChanges(),this._windowRef.changeDetectorRef.markForCheck(),this._ngZone.runOutsideAngular(()=>{this._positioning.createPopper({hostElement:this._getPositionTargetElement(),targetElement:this._windowRef.location.nativeElement,placement:this.placement,baseClass:"bs-tooltip",updatePopperOptions:Xe=>this.popperOptions(lc([0,6])(Xe))}),Promise.resolve().then(()=>{this._positioning.update()}),this._afterRenderRef=(0,i.afterRender)(()=>{this._positioning.update()},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector})}),Ds(this._ngZone,this._document,this.autoClose,()=>this.close(),this.hidden,[this._windowRef.location.nativeElement],[this._nativeElement]),ee.subscribe(()=>this.shown.emit())}}close(E=this.animation){null!=this._windowRef&&(this._getPositionTargetElement().removeAttribute("aria-describedby"),this._popupService.close(E).subscribe(()=>{this._windowRef=null,this._positioning.destroy(),this._afterRenderRef?.destroy(),this.hidden.emit(),this._changeDetector.markForCheck()}))}toggle(){this._windowRef?this.close():this.open()}isOpen(){return null!=this._windowRef}ngOnInit(){this._unregisterListenersFn=Bs(this._nativeElement,this.triggers,this.isOpen.bind(this),this.open.bind(this),this.close.bind(this),+this.openDelay,+this.closeDelay)}ngOnChanges({tooltipClass:E}){E&&this.isOpen()&&this._windowRef.setInput("tooltipClass",E.currentValue)}ngOnDestroy(){this.close(!1),this._unregisterListenersFn?.()}_getPositionTargetElement(){return(Ui(this.positionTarget)?this._document.querySelector(this.positionTarget):this.positionTarget)||this._nativeElement}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["","ngbTooltip",""]],inputs:{animation:"animation",autoClose:"autoClose",placement:"placement",popperOptions:"popperOptions",triggers:"triggers",positionTarget:"positionTarget",container:"container",disableTooltip:"disableTooltip",tooltipClass:"tooltipClass",tooltipContext:"tooltipContext",openDelay:"openDelay",closeDelay:"closeDelay",ngbTooltip:"ngbTooltip"},outputs:{shown:"shown",hidden:"hidden"},exportAs:["ngbTooltip"],standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature]})}return V})(),Nf=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Jp=(()=>{class V{constructor(){this.highlightClass="ngb-highlight",this.accentSensitive=!0}ngOnChanges(E){!this.accentSensitive&&!String.prototype.normalize&&(console.warn("The `accentSensitive` input in `ngb-highlight` cannot be set to `false` in a browser that does not implement the `String.normalize` function. You will have to include a polyfill in your application to use this feature in the current browser."),this.accentSensitive=!0);const U=jn(this.result),ee=Array.isArray(this.term)?this.term:[this.term],Xe=ur=>this.accentSensitive?ur:Wi(ur),Nt=ee.map(ur=>function Tn(V){return V.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}(Xe(jn(ur)))).filter(ur=>ur),Ei=this.accentSensitive?U:Wi(U),gr=Nt.length?Ei.split(new RegExp(`(${Nt.join("|")})`,"gmi")):[U];if(this.accentSensitive)this.parts=gr;else{let ur=0;this.parts=gr.map(vo=>U.substring(ur,ur+=vo.length))}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-highlight"]],inputs:{highlightClass:"highlightClass",result:"result",term:"term",accentSensitive:"accentSensitive"},standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],decls:2,vars:0,consts:[[3,"class"]],template:function(U,ee){1&U&&i.\u0275\u0275repeaterCreate(0,no,2,1,null,null,i.\u0275\u0275repeaterTrackByIndex),2&U&&i.\u0275\u0275repeater(ee.parts)},styles:[".ngb-highlight{font-weight:700}\n"],encapsulation:2,changeDetection:0})}return V})();const Cc=new i.InjectionToken("live announcer delay",{providedIn:"root",factory:()=>100});function io(V,Qe=!1){let E=V.body.querySelector("#ngb-live");return null==E&&Qe&&(E=V.createElement("div"),E.setAttribute("id","ngb-live"),E.setAttribute("aria-live","polite"),E.setAttribute("aria-atomic","true"),E.classList.add("visually-hidden"),V.body.appendChild(E)),E}let Ps=(()=>{class V{constructor(){this._document=(0,i.inject)(Z.DOCUMENT),this._delay=(0,i.inject)(Cc)}ngOnDestroy(){const E=io(this._document);E&&E.parentElement.removeChild(E)}say(E){const U=io(this._document,!0),ee=this._delay;if(null!=U){U.textContent="";const Xe=()=>U.textContent=E;null===ee?Xe():setTimeout(Xe,ee)}}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),fc=(()=>{class V{constructor(){this.editable=!0,this.focusFirst=!0,this.selectOnExact=!1,this.showHint=!1,this.placement=["bottom-start","bottom-end","top-start","top-end"],this.popperOptions=E=>E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Xl=(()=>{class V{constructor(){this.activeIdx=0,this.focusFirst=!0,this.formatter=jn,this.selectEvent=new i.EventEmitter,this.activeChangeEvent=new i.EventEmitter}hasActive(){return this.activeIdx>-1&&this.activeIdx<this.results.length}getActive(){return this.results[this.activeIdx]}markActive(E){this.activeIdx=E,this._activeChanged()}next(){this.activeIdx===this.results.length-1?this.activeIdx=this.focusFirst?(this.activeIdx+1)%this.results.length:-1:this.activeIdx++,this._activeChanged()}prev(){this.activeIdx<0?this.activeIdx=this.results.length-1:0===this.activeIdx?this.activeIdx=this.focusFirst?this.results.length-1:-1:this.activeIdx--,this._activeChanged()}resetActive(){this.activeIdx=this.focusFirst?0:-1,this._activeChanged()}select(E){this.selectEvent.emit(E)}ngOnInit(){this.resetActive()}_activeChanged(){this.activeChangeEvent.emit(this.activeIdx>=0?this.id+"-"+this.activeIdx:void 0)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-typeahead-window"]],hostAttrs:["role","listbox"],hostVars:3,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("mousedown",function(Nt){return Nt.preventDefault()}),2&U&&(i.\u0275\u0275hostProperty("id",ee.id),i.\u0275\u0275classMap("dropdown-menu show"+(ee.popupClass?" "+ee.popupClass:"")))},inputs:{id:"id",focusFirst:"focusFirst",results:"results",term:"term",formatter:"formatter",resultTemplate:"resultTemplate",popupClass:"popupClass"},outputs:{selectEvent:"select",activeChangeEvent:"activeChange"},exportAs:["ngbTypeaheadWindow"],standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:4,vars:0,consts:[["rt",""],["type","button","role","option",1,"dropdown-item",3,"id","active"],[3,"result","term"],["type","button","role","option",1,"dropdown-item",3,"mouseenter","click","id"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(U,ee){1&U&&(i.\u0275\u0275template(0,Qr,1,2,"ng-template",null,0,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275repeaterCreate(2,Ya,2,9,"button",1,i.\u0275\u0275repeaterTrackByIndex)),2&U&&(i.\u0275\u0275advance(2),i.\u0275\u0275repeater(ee.results))},dependencies:[Jp,Z.NgTemplateOutlet],encapsulation:2})}return V})(),nc=0,ra=(()=>{class V{constructor(){this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._config=(0,i.inject)(fc),this._live=(0,i.inject)(Ps),this._document=(0,i.inject)(Z.DOCUMENT),this._ngZone=(0,i.inject)(i.NgZone),this._changeDetector=(0,i.inject)(i.ChangeDetectorRef),this._injector=(0,i.inject)(i.Injector),this._popupService=new ro(Xl),this._positioning=Gs(),this._subscription=null,this._closed$=new e.Subject,this._inputValueBackup=null,this._inputValueForSelectOnExact=null,this._valueChanges$=(0,e.fromEvent)(this._nativeElement,"input").pipe((0,M.map)(E=>E.target.value)),this._resubscribeTypeahead$=new e.BehaviorSubject(null),this._windowRef=null,this.autocomplete="off",this.container=this._config.container,this.editable=this._config.editable,this.focusFirst=this._config.focusFirst,this.selectOnExact=this._config.selectOnExact,this.showHint=this._config.showHint,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.selectItem=new i.EventEmitter,this.activeDescendant=null,this.popupId="ngb-typeahead-"+nc++,this._onTouched=()=>{},this._onChange=E=>{}}ngOnInit(){this._subscribeToUserInput()}ngOnChanges({ngbTypeahead:E}){E&&!E.firstChange&&(this._unsubscribeFromUserInput(),this._subscribeToUserInput())}ngOnDestroy(){this._closePopup(),this._unsubscribeFromUserInput()}registerOnChange(E){this._onChange=E}registerOnTouched(E){this._onTouched=E}writeValue(E){this._writeInputValue(this._formatItemForInput(E)),this.showHint&&(this._inputValueBackup=E)}setDisabledState(E){this._nativeElement.disabled=E}dismissPopup(){this.isPopupOpen()&&(this._resubscribeTypeahead$.next(null),this._closePopup(),this.showHint&&null!==this._inputValueBackup&&this._writeInputValue(this._inputValueBackup),this._changeDetector.markForCheck())}isPopupOpen(){return null!=this._windowRef}handleBlur(){this._resubscribeTypeahead$.next(null),this._onTouched()}handleKeyDown(E){if(this.isPopupOpen())switch(E.key){case"ArrowDown":E.preventDefault(),this._windowRef.instance.next(),this._showHint();break;case"ArrowUp":E.preventDefault(),this._windowRef.instance.prev(),this._showHint();break;case"Enter":case"Tab":{const U=this._windowRef.instance.getActive();Or(U)&&(E.preventDefault(),E.stopPropagation(),this._selectResult(U)),this._closePopup();break}}}_openPopup(){if(!this.isPopupOpen()){this._inputValueBackup=this._nativeElement.value;const{windowRef:E}=this._popupService.open();this._windowRef=E,this._windowRef.setInput("id",this.popupId),this._windowRef.setInput("popupClass",this.popupClass),this._windowRef.instance.selectEvent.subscribe(U=>this._selectResultClosePopup(U)),this._windowRef.instance.activeChangeEvent.subscribe(U=>this.activeDescendant=U),"body"===this.container&&(this._windowRef.location.nativeElement.style.zIndex="1055",this._document.body.appendChild(this._windowRef.location.nativeElement)),this._changeDetector.markForCheck(),this._ngZone.runOutsideAngular(()=>{this._windowRef&&(this._positioning.createPopper({hostElement:this._nativeElement,targetElement:this._windowRef.location.nativeElement,placement:this.placement,updatePopperOptions:U=>this.popperOptions(lc([0,2])(U))}),this._afterRenderRef=(0,i.afterRender)(()=>{this._positioning.update()},{phase:i.AfterRenderPhase.MixedReadWrite,injector:this._injector}))}),Ds(this._ngZone,this._document,"outside",()=>this.dismissPopup(),this._closed$,[this._nativeElement,this._windowRef.location.nativeElement])}}_closePopup(){this._popupService.close().subscribe(()=>{this._positioning.destroy(),this._afterRenderRef?.destroy(),this._closed$.next(),this._windowRef=null,this.activeDescendant=null})}_selectResult(E){let U=!1;this.selectItem.emit({item:E,preventDefault:()=>{U=!0}}),this._resubscribeTypeahead$.next(null),U||(this.writeValue(E),this._onChange(E))}_selectResultClosePopup(E){this._selectResult(E),this._closePopup()}_showHint(){if(this.showHint&&this._windowRef?.instance.hasActive()&&null!=this._inputValueBackup){const E=this._inputValueBackup.toLowerCase(),U=this._formatItemForInput(this._windowRef.instance.getActive());E===U.substring(0,this._inputValueBackup.length).toLowerCase()?(this._writeInputValue(this._inputValueBackup+U.substring(this._inputValueBackup.length)),this._nativeElement.setSelectionRange.apply(this._nativeElement,[this._inputValueBackup.length,U.length])):this._writeInputValue(U)}}_formatItemForInput(E){return null!=E&&this.inputFormatter?this.inputFormatter(E):jn(E)}_writeInputValue(E){this._nativeElement.value=jn(E)}_subscribeToUserInput(){const E=this._valueChanges$.pipe((0,M.tap)(U=>{this._inputValueBackup=this.showHint?U:null,this._inputValueForSelectOnExact=this.selectOnExact?U:null,this._onChange(this.editable?U:void 0)}),this.ngbTypeahead?this.ngbTypeahead:()=>(0,e.of)([]));this._subscription=this._resubscribeTypeahead$.pipe((0,M.switchMap)(()=>E)).subscribe(U=>{U&&0!==U.length?this.selectOnExact&&1===U.length&&this._formatItemForInput(U[0])===this._inputValueForSelectOnExact?(this._selectResult(U[0]),this._closePopup()):(this._openPopup(),this._windowRef.setInput("focusFirst",this.focusFirst),this._windowRef.setInput("results",U),this._windowRef.setInput("term",this._nativeElement.value),this.resultFormatter&&this._windowRef.setInput("formatter",this.resultFormatter),this.resultTemplate&&this._windowRef.setInput("resultTemplate",this.resultTemplate),this._windowRef.instance.resetActive(),this._windowRef.changeDetectorRef.detectChanges(),this._showHint()):this._closePopup();const ee=U?U.length:0;this._live.say(0===ee?"No results available":`${ee} result${1===ee?"":"s"} available`)})}_unsubscribeFromUserInput(){this._subscription&&this._subscription.unsubscribe(),this._subscription=null}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275dir=i.\u0275\u0275defineDirective({type:V,selectors:[["input","ngbTypeahead",""]],hostAttrs:["autocapitalize","off","autocorrect","off","role","combobox"],hostVars:7,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("blur",function(){return ee.handleBlur()})("keydown",function(Nt){return ee.handleKeyDown(Nt)}),2&U&&(i.\u0275\u0275hostProperty("autocomplete",ee.autocomplete),i.\u0275\u0275attribute("aria-autocomplete",ee.showHint?"both":"list")("aria-activedescendant",ee.activeDescendant)("aria-owns",ee.isPopupOpen()?ee.popupId:null)("aria-expanded",ee.isPopupOpen()),i.\u0275\u0275classProp("open",ee.isPopupOpen()))},inputs:{autocomplete:"autocomplete",container:"container",editable:"editable",focusFirst:"focusFirst",inputFormatter:"inputFormatter",ngbTypeahead:"ngbTypeahead",resultFormatter:"resultFormatter",resultTemplate:"resultTemplate",selectOnExact:"selectOnExact",showHint:"showHint",placement:"placement",popperOptions:"popperOptions",popupClass:"popupClass"},outputs:{selectItem:"selectItem"},exportAs:["ngbTypeahead"],standalone:!0,features:[i.\u0275\u0275ProvidersFeature([{provide:ce.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>V),multi:!0}]),i.\u0275\u0275NgOnChangesFeature]})}return V})(),Rf=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})(),Ja=(()=>{class V{constructor(){this._ngbConfig=(0,i.inject)(ko),this.backdrop=!0,this.keyboard=!0,this.position="start",this.scroll=!1}get animation(){return this._animation??this._ngbConfig.animation}set animation(E){this._animation=E}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})();class Jc{close(Qe){}dismiss(Qe){}}class sd{get componentInstance(){if(this._contentRef&&this._contentRef.componentRef)return this._contentRef.componentRef.instance}get closed(){return this._closed.asObservable().pipe((0,M.takeUntil)(this._hidden))}get dismissed(){return this._dismissed.asObservable().pipe((0,M.takeUntil)(this._hidden))}get hidden(){return this._hidden.asObservable()}get shown(){return this._panelCmptRef.instance.shown.asObservable()}constructor(Qe,E,U,ee){this._panelCmptRef=Qe,this._contentRef=E,this._backdropCmptRef=U,this._beforeDismiss=ee,this._closed=new e.Subject,this._dismissed=new e.Subject,this._hidden=new e.Subject,Qe.instance.dismissEvent.subscribe(Xe=>{this.dismiss(Xe)}),U&&U.instance.dismissEvent.subscribe(Xe=>{this.dismiss(Xe)}),this.result=new Promise((Xe,Nt)=>{this._resolve=Xe,this._reject=Nt}),this.result.then(null,()=>{})}close(Qe){this._panelCmptRef&&(this._closed.next(Qe),this._resolve(Qe),this._removeOffcanvasElements())}_dismiss(Qe){this._dismissed.next(Qe),this._reject(Qe),this._removeOffcanvasElements()}dismiss(Qe){if(this._panelCmptRef)if(this._beforeDismiss){const E=this._beforeDismiss();Tt(E)?E.then(U=>{!1!==U&&this._dismiss(Qe)},()=>{}):!1!==E&&this._dismiss(Qe)}else this._dismiss(Qe)}_removeOffcanvasElements(){const Qe=this._panelCmptRef.instance.hide(),E=this._backdropCmptRef?this._backdropCmptRef.instance.hide():(0,e.of)(void 0);Qe.subscribe(()=>{const{nativeElement:U}=this._panelCmptRef.location;U.parentNode.removeChild(U),this._panelCmptRef.destroy(),this._contentRef?.viewRef?.destroy(),this._panelCmptRef=null,this._contentRef=null}),E.subscribe(()=>{if(this._backdropCmptRef){const{nativeElement:U}=this._backdropCmptRef.location;U.parentNode.removeChild(U),this._backdropCmptRef.destroy(),this._backdropCmptRef=null}}),(0,e.zip)(Qe,E).subscribe(()=>{this._hidden.next(),this._hidden.complete()})}}var Ss=function(V){return V[V.BACKDROP_CLICK=0]="BACKDROP_CLICK",V[V.ESC=1]="ESC",V}(Ss||{});let ps=(()=>{class V{constructor(){this._nativeElement=(0,i.inject)(i.ElementRef).nativeElement,this._zone=(0,i.inject)(i.NgZone),this._injector=(0,i.inject)(i.Injector),this.dismissEvent=new i.EventEmitter}ngOnInit(){(0,i.afterNextRender)(()=>Mo(this._zone,this._nativeElement,(E,U)=>{U&&Un(E),E.classList.add("show")},{animation:this.animation,runningTransition:"continue"}),{injector:this._injector,phase:i.AfterRenderPhase.MixedReadWrite})}hide(){return Mo(this._zone,this._nativeElement,({classList:E})=>E.remove("show"),{animation:this.animation,runningTransition:"stop"})}dismiss(){this.static||this.dismissEvent.emit(Ss.BACKDROP_CLICK)}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-offcanvas-backdrop"]],hostVars:6,hostBindings:function(U,ee){1&U&&i.\u0275\u0275listener("mousedown",function(){return ee.dismiss()}),2&U&&(i.\u0275\u0275classMap("offcanvas-backdrop"+(ee.backdropClass?" "+ee.backdropClass:"")),i.\u0275\u0275classProp("show",!ee.animation)("fade",ee.animation))},inputs:{animation:"animation",backdropClass:"backdropClass",static:"static"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],decls:0,vars:0,template:function(U,ee){},encapsulation:2})}return V})(),eh=(()=>{class V{constructor(){this._document=(0,i.inject)(Z.DOCUMENT),this._elRef=(0,i.inject)(i.ElementRef),this._zone=(0,i.inject)(i.NgZone),this._injector=(0,i.inject)(i.Injector),this._closed$=new e.Subject,this._elWithFocus=null,this.keyboard=!0,this.position="start",this.dismissEvent=new i.EventEmitter,this.shown=new e.Subject,this.hidden=new e.Subject}dismiss(E){this.dismissEvent.emit(E)}ngOnInit(){this._elWithFocus=this._document.activeElement,(0,i.afterNextRender)(()=>this._show(),{injector:this._injector,phase:i.AfterRenderPhase.MixedReadWrite})}ngOnDestroy(){this._disableEventHandling()}hide(){const U=Mo(this._zone,this._elRef.nativeElement,ee=>(ee.classList.remove("showing"),ee.classList.add("hiding"),()=>ee.classList.remove("show","hiding")),{animation:this.animation,runningTransition:"stop"});return U.subscribe(()=>{this.hidden.next(),this.hidden.complete()}),this._disableEventHandling(),this._restoreFocus(),U}_show(){Mo(this._zone,this._elRef.nativeElement,(ee,Xe)=>(Xe&&Un(ee),ee.classList.add("show","showing"),()=>ee.classList.remove("showing")),{animation:this.animation,runningTransition:"continue"}).subscribe(()=>{this.shown.next(),this.shown.complete()}),this._enableEventHandling(),this._setFocus()}_enableEventHandling(){const{nativeElement:E}=this._elRef;this._zone.runOutsideAngular(()=>{(0,e.fromEvent)(E,"keydown").pipe((0,M.takeUntil)(this._closed$),(0,M.filter)(U=>"Escape"===U.key)).subscribe(U=>{this.keyboard&&requestAnimationFrame(()=>{U.defaultPrevented||this._zone.run(()=>this.dismiss(Ss.ESC))})})})}_disableEventHandling(){this._closed$.next()}_setFocus(){const{nativeElement:E}=this._elRef;if(!E.contains(document.activeElement)){const U=E.querySelector("[ngbAutofocus]"),ee=na(E)[0];(U||ee||E).focus()}}_restoreFocus(){const E=this._document.body,U=this._elWithFocus;let ee;ee=U&&U.focus&&E.contains(U)?U:E,this._zone.runOutsideAngular(()=>{setTimeout(()=>ee.focus()),this._elWithFocus=null})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:V,selectors:[["ngb-offcanvas-panel"]],hostAttrs:["role","dialog","tabindex","-1"],hostVars:5,hostBindings:function(U,ee){2&U&&(i.\u0275\u0275attribute("aria-modal",!0)("aria-labelledby",ee.ariaLabelledBy)("aria-describedby",ee.ariaDescribedBy),i.\u0275\u0275classMap("offcanvas offcanvas-"+ee.position+(ee.panelClass?" "+ee.panelClass:"")))},inputs:{animation:"animation",ariaLabelledBy:"ariaLabelledBy",ariaDescribedBy:"ariaDescribedBy",keyboard:"keyboard",panelClass:"panelClass",position:"position"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[i.\u0275\u0275StandaloneFeature],ngContentSelectors:je,decls:1,vars:0,template:function(U,ee){1&U&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275projection(0))},encapsulation:2})}return V})(),Eh=(()=>{class V{constructor(){this._applicationRef=(0,i.inject)(i.ApplicationRef),this._injector=(0,i.inject)(i.Injector),this._document=(0,i.inject)(Z.DOCUMENT),this._scrollBar=(0,i.inject)(Ic),this._activePanelCmptHasChanged=new e.Subject,this._scrollBarRestoreFn=null,this._backdropAttributes=["animation","backdropClass"],this._panelAttributes=["animation","ariaDescribedBy","ariaLabelledBy","keyboard","panelClass","position"],this._activeInstance=new i.EventEmitter;const E=(0,i.inject)(i.NgZone);this._activePanelCmptHasChanged.subscribe(()=>{this._panelCmpt&&zs(E,this._panelCmpt.location.nativeElement,this._activePanelCmptHasChanged)})}_restoreScrollBar(){const E=this._scrollBarRestoreFn;E&&(this._scrollBarRestoreFn=null,E())}_hideScrollBar(){this._scrollBarRestoreFn||(this._scrollBarRestoreFn=this._scrollBar.hide())}open(E,U,ee){const Xe=ee.container instanceof HTMLElement?ee.container:Or(ee.container)?this._document.querySelector(ee.container):this._document.body;if(!Xe)throw new Error(`The specified offcanvas container "${ee.container||"body"}" was not found in the DOM.`);ee.scroll||this._hideScrollBar();const Nt=new Jc,Ei=this._getContentRef(ee.injector||E,U,Nt);let gr=!1!==ee.backdrop?this._attachBackdrop(Xe):void 0,ur=this._attachWindowComponent(Xe,Ei.nodes),vo=new sd(ur,Ei,gr,ee.beforeDismiss);return this._registerOffcanvasRef(vo),this._registerPanelCmpt(ur),vo.hidden.pipe((0,M.finalize)(()=>this._restoreScrollBar())).subscribe(),Nt.close=Gr=>{vo.close(Gr)},Nt.dismiss=Gr=>{vo.dismiss(Gr)},this._applyPanelOptions(ur.instance,ee),gr&&gr.instance&&(this._applyBackdropOptions(gr.instance,ee),gr.changeDetectorRef.detectChanges()),ur.changeDetectorRef.detectChanges(),vo}get activeInstance(){return this._activeInstance}dismiss(E){this._offcanvasRef?.dismiss(E)}hasOpenOffcanvas(){return!!this._offcanvasRef}_attachBackdrop(E){let U=(0,i.createComponent)(ps,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector});return this._applicationRef.attachView(U.hostView),E.appendChild(U.location.nativeElement),U}_attachWindowComponent(E,U){let ee=(0,i.createComponent)(eh,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector,projectableNodes:U});return this._applicationRef.attachView(ee.hostView),E.appendChild(ee.location.nativeElement),ee}_applyPanelOptions(E,U){this._panelAttributes.forEach(ee=>{Or(U[ee])&&(E[ee]=U[ee])})}_applyBackdropOptions(E,U){this._backdropAttributes.forEach(ee=>{Or(U[ee])&&(E[ee]=U[ee])}),E.static="static"===U.backdrop}_getContentRef(E,U,ee){return U?U instanceof i.TemplateRef?this._createFromTemplateRef(U,ee):Ui(U)?this._createFromString(U):this._createFromComponent(E,U,ee):new sr([])}_createFromTemplateRef(E,U){const Xe=E.createEmbeddedView({$implicit:U,close(Nt){U.close(Nt)},dismiss(Nt){U.dismiss(Nt)}});return this._applicationRef.attachView(Xe),new sr([Xe.rootNodes],Xe)}_createFromString(E){const U=this._document.createTextNode(`${E}`);return new sr([[U]])}_createFromComponent(E,U,ee){const Xe=i.Injector.create({providers:[{provide:Jc,useValue:ee}],parent:E}),Nt=(0,i.createComponent)(U,{environmentInjector:this._applicationRef.injector,elementInjector:Xe}),Ei=Nt.location.nativeElement;return this._applicationRef.attachView(Nt.hostView),new sr([[Ei]],Nt.hostView,Nt)}_registerOffcanvasRef(E){const U=()=>{this._offcanvasRef=void 0,this._activeInstance.emit(this._offcanvasRef)};this._offcanvasRef=E,this._activeInstance.emit(this._offcanvasRef),E.result.then(U,U)}_registerPanelCmpt(E){this._panelCmpt=E,this._activePanelCmptHasChanged.next(),E.onDestroy(()=>{this._panelCmpt=void 0,this._activePanelCmptHasChanged.next()})}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),Gl=(()=>{class V{constructor(){this._injector=(0,i.inject)(i.Injector),this._offcanvasStack=(0,i.inject)(Eh),this._config=(0,i.inject)(Ja)}open(E,U={}){const ee={...this._config,animation:this._config.animation,...U};return this._offcanvasStack.open(this._injector,E,ee)}get activeInstance(){return this._offcanvasStack.activeInstance}dismiss(E){this._offcanvasStack.dismiss(E)}hasOpenOffcanvas(){return this._offcanvasStack.hasOpenOffcanvas()}static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:V,factory:V.\u0275fac,providedIn:"root"})}return V})(),zu=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({})}return V})();const Bd=[Ia,Sl,Rl,yl,Si,Vc,yg,Cg,zu,Ep,Tp,ap,Mu,Of,Iv,Rm,Nf,Rf];let th=(()=>{class V{static#e=this.\u0275fac=function(U){return new(U||V)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:V});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({imports:[Bd,Ia,Sl,Rl,yl,Si,Vc,yg,Cg,zu,Ep,Tp,ap,Mu,Of,Iv,Rm,Nf,Rf]})}return V})()},5568:(Ot,Me,S)=>{S.r(Me),S.d(Me,{AdvancedLegendComponent:()=>Yy,AdvancedPieChartComponent:()=>CT,AreaChartComponent:()=>GM,AreaChartModule:()=>DC,AreaChartNormalizedComponent:()=>kb,AreaChartStackedComponent:()=>pv,AreaComponent:()=>fg,AreaSeriesComponent:()=>fv,AxesModule:()=>Tw,AxisLabelComponent:()=>Hy,BarChartModule:()=>Aw,BarChartType:()=>Hc,BarComponent:()=>hv,BarHorizontal2DComponent:()=>xC,BarHorizontalComponent:()=>wC,BarHorizontalNormalizedComponent:()=>SC,BarHorizontalStackedComponent:()=>_p,BarLabelComponent:()=>mv,BarOrientation:()=>Jl,BarVertical2DComponent:()=>Iw,BarVerticalComponent:()=>LS,BarVerticalNormalizedComponent:()=>KM,BarVerticalStackedComponent:()=>EC,BaseChartComponent:()=>Wc,BoxChartComponent:()=>Pb,BoxChartModule:()=>e0,BoxComponent:()=>Jy,BoxSeriesComponent:()=>Ow,BubbleChartComponent:()=>t0,BubbleChartModule:()=>M_,BubbleSeriesComponent:()=>Fw,CardComponent:()=>Nw,CardSeriesComponent:()=>I_,ChartCommonModule:()=>cf,ChartComponent:()=>cu,CircleComponent:()=>qy,CircleSeriesComponent:()=>cv,ColorHelper:()=>iu,CountUpDirective:()=>Gh,D0Types:()=>zf,GaugeArcComponent:()=>O_,GaugeAxisComponent:()=>Wb,GaugeComponent:()=>kw,GaugeModule:()=>WS,GridPanelComponent:()=>Mw,GridPanelSeriesComponent:()=>dg,HeatCellSeriesComponent:()=>Vb,HeatMapCellComponent:()=>PS,HeatMapComponent:()=>n0,HeatMapModule:()=>TC,LegendComponent:()=>ym,LegendEntryComponent:()=>Wy,LegendPosition:()=>bu,LegendType:()=>Wf,LineChartComponent:()=>IC,LineChartModule:()=>AC,LineComponent:()=>BS,LineSeriesComponent:()=>MC,LinearGaugeComponent:()=>Lw,NgxChartsModule:()=>zb,NumberCardComponent:()=>a0,NumberCardModule:()=>pa,Orientation:()=>cd,PieArcComponent:()=>mh,PieChartComponent:()=>r0,PieChartModule:()=>o0,PieGridComponent:()=>jb,PieGridSeriesComponent:()=>US,PieLabelComponent:()=>VS,PieSeriesComponent:()=>FC,PlacementTypes:()=>Ys,PolarChartComponent:()=>qM,PolarChartModule:()=>s0,PolarSeriesComponent:()=>OC,SankeyComponent:()=>Hb,SankeyModule:()=>xT,ScaleLegendComponent:()=>yC,ScaleType:()=>zi,SeriesHorizontal:()=>E_,SeriesType:()=>zh,SeriesVerticalComponent:()=>Dd,ShowTypes:()=>D_,StyleTypes:()=>Ju,SvgLinearGradientComponent:()=>ug,SvgRadialGradientComponent:()=>uv,TextAnchor:()=>Nd,Timeline:()=>hg,TooltipArea:()=>x_,TooltipContentComponent:()=>ag,TooltipDirective:()=>Hp,TooltipModule:()=>Gy,TooltipService:()=>b_,TreeMapCellComponent:()=>gv,TreeMapCellSeriesComponent:()=>A_,TreeMapComponent:()=>wT,TreeMapModule:()=>l0,VisibilityObserver:()=>lg,XAxisComponent:()=>lf,XAxisTicksComponent:()=>C_,YAxisComponent:()=>xf,YAxisTicksComponent:()=>zy,calculateViewDimensions:()=>uu,colorSets:()=>Lb,count:()=>bC,decimalChecker:()=>pg,escapeLabel:()=>Cu,formatLabel:()=>nu,getDomain:()=>Bb,getScale:()=>T_,getScaleType:()=>Cm,getTickLines:()=>Hf,getUniqueXDomainValues:()=>dv,getXDomainArray:()=>S_,gridLayout:()=>NC,gridSize:()=>DT,hexToRgb:()=>RC,id:()=>Gu,invertColor:()=>Rw,reduceTicks:()=>hh,shadeRGBColor:()=>$S,sortByDomain:()=>Zy,sortByTime:()=>dd,sortLinear:()=>Xy,throttle:()=>av,throttleable:()=>OS,tickFormat:()=>Pw,trimLabel:()=>cg});var i=S(1270),e=S(2168);"function"==typeof SuppressedError&&SuppressedError;class Dn{attach(g){return this._attachedHost=g,g.attach(this)}detach(){let g=this._attachedHost;null!=g&&(this._attachedHost=null,g.detach())}get isAttached(){return null!=this._attachedHost}setAttachedHost(g){this._attachedHost=g}}class gn extends Dn{constructor(g,a,u,x,I){super(),this.component=g,this.viewContainerRef=a,this.injector=u,this.componentFactoryResolver=x,this.projectableNodes=I}}class Nn extends Dn{constructor(g,a,u,x){super(),this.templateRef=g,this.viewContainerRef=a,this.context=u,this.injector=x}get origin(){return this.templateRef.elementRef}attach(g,a=this.context){return this.context=a,super.attach(g)}detach(){return this.context=void 0,super.detach()}}class Yn extends Dn{constructor(g){super(),this.element=g instanceof i.ElementRef?g.nativeElement:g}}class cr{constructor(){this._isDisposed=!1,this.attachDomPortal=null}hasAttached(){return!!this._attachedPortal}attach(g){return g instanceof gn?(this._attachedPortal=g,this.attachComponentPortal(g)):g instanceof Nn?(this._attachedPortal=g,this.attachTemplatePortal(g)):this.attachDomPortal&&g instanceof Yn?(this._attachedPortal=g,this.attachDomPortal(g)):void 0}detach(){this._attachedPortal&&(this._attachedPortal.setAttachedHost(null),this._attachedPortal=null),this._invokeDisposeFn()}dispose(){this.hasAttached()&&this.detach(),this._invokeDisposeFn(),this._isDisposed=!0}setDisposeFn(g){this._disposeFn=g}_invokeDisposeFn(){this._disposeFn&&(this._disposeFn(),this._disposeFn=null)}}class Qi extends cr{constructor(g,a,u,x,I){super(),this.outletElement=g,this._componentFactoryResolver=a,this._appRef=u,this._defaultInjector=x,this.attachDomPortal=K=>{const ye=K.element,Ye=this._document.createComment("dom-portal");ye.parentNode.insertBefore(Ye,ye),this.outletElement.appendChild(ye),this._attachedPortal=K,super.setDisposeFn(()=>{Ye.parentNode&&Ye.parentNode.replaceChild(ye,Ye)})},this._document=I}attachComponentPortal(g){const u=(g.componentFactoryResolver||this._componentFactoryResolver).resolveComponentFactory(g.component);let x;return g.viewContainerRef?(x=g.viewContainerRef.createComponent(u,g.viewContainerRef.length,g.injector||g.viewContainerRef.injector,g.projectableNodes||void 0),this.setDisposeFn(()=>x.destroy())):(x=u.create(g.injector||this._defaultInjector||i.Injector.NULL),this._appRef.attachView(x.hostView),this.setDisposeFn(()=>{this._appRef.viewCount>0&&this._appRef.detachView(x.hostView),x.destroy()})),this.outletElement.appendChild(this._getComponentRootNode(x)),this._attachedPortal=g,x}attachTemplatePortal(g){let a=g.viewContainerRef,u=a.createEmbeddedView(g.templateRef,g.context,{injector:g.injector});return u.rootNodes.forEach(x=>this.outletElement.appendChild(x)),u.detectChanges(),this.setDisposeFn(()=>{let x=a.indexOf(u);-1!==x&&a.remove(x)}),this._attachedPortal=g,u}dispose(){super.dispose(),this.outletElement.remove()}_getComponentRootNode(g){return g.hostView.rootNodes[0]}}var yt=S(1647),hn=S(9335),Gt=S(2810);function Gn(){}function ri(c){return null==c?Gn:function(){return this.querySelector(c)}}function Bn(){return[]}function Mn(c){return null==c?Bn:function(){return this.querySelectorAll(c)}}function Ti(c){return function(){return this.matches(c)}}function Bi(c){return function(g){return g.matches(c)}}var Gi=Array.prototype.find;function Ki(){return this.firstElementChild}var hi=Array.prototype.filter;function Ft(){return Array.from(this.children)}function He(c){return new Array(c.length)}function bt(c,g){this.ownerDocument=c.ownerDocument,this.namespaceURI=c.namespaceURI,this._next=null,this._parent=c,this.__data__=g}function Jn(c,g,a,u,x,I){for(var ye,K=0,Ye=g.length,$e=I.length;K<$e;++K)(ye=g[K])?(ye.__data__=I[K],u[K]=ye):a[K]=new bt(c,I[K]);for(;K<Ye;++K)(ye=g[K])&&(x[K]=ye)}function Sn(c,g,a,u,x,I,K){var ye,Ye,yn,$e=new Map,ht=g.length,Vt=I.length,zt=new Array(ht);for(ye=0;ye<ht;++ye)(Ye=g[ye])&&(zt[ye]=yn=K.call(Ye,Ye.__data__,ye,g)+"",$e.has(yn)?x[ye]=Ye:$e.set(yn,Ye));for(ye=0;ye<Vt;++ye)yn=K.call(c,I[ye],ye,I)+"",(Ye=$e.get(yn))?(u[ye]=Ye,Ye.__data__=I[ye],$e.delete(yn)):a[ye]=new bt(c,I[ye]);for(ye=0;ye<ht;++ye)(Ye=g[ye])&&$e.get(zt[ye])===Ye&&(x[ye]=Ye)}function _r(c){return c.__data__}function Bo(c){return"object"==typeof c&&"length"in c?c:Array.from(c)}function Ao(c,g){return c<g?-1:c>g?1:c>=g?0:NaN}bt.prototype={constructor:bt,appendChild:function(c){return this._parent.insertBefore(c,this._next)},insertBefore:function(c,g){return this._parent.insertBefore(c,g)},querySelector:function(c){return this._parent.querySelector(c)},querySelectorAll:function(c){return this._parent.querySelectorAll(c)}};var oa="http://www.w3.org/1999/xhtml";const no={svg:"http://www.w3.org/2000/svg",xhtml:oa,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function xl(c){var g=c+="",a=g.indexOf(":");return a>=0&&"xmlns"!==(g=c.slice(0,a))&&(c=c.slice(a+1)),no.hasOwnProperty(g)?{space:no[g],local:c}:c}function Qr(c){return function(){this.removeAttribute(c)}}function dl(c){return function(){this.removeAttributeNS(c.space,c.local)}}function Ya(c,g){return function(){this.setAttribute(c,g)}}function Lo(c,g){return function(){this.setAttributeNS(c.space,c.local,g)}}function ko(c,g){return function(){var a=g.apply(this,arguments);null==a?this.removeAttribute(c):this.setAttribute(c,a)}}function jt(c,g){return function(){var a=g.apply(this,arguments);null==a?this.removeAttributeNS(c.space,c.local):this.setAttributeNS(c.space,c.local,a)}}function Rt(c){return c.ownerDocument&&c.ownerDocument.defaultView||c.document&&c||c.defaultView}function jn(c){return function(){this.style.removeProperty(c)}}function Fi(c,g,a){return function(){this.style.setProperty(c,g,a)}}function Ui(c,g,a){return function(){var u=g.apply(this,arguments);null==u?this.style.removeProperty(c):this.style.setProperty(c,u,a)}}function er(c,g){return c.style.getPropertyValue(g)||Rt(c).getComputedStyle(c,null).getPropertyValue(g)}function Or(c){return function(){delete this[c]}}function Tt(c,g){return function(){this[c]=g}}function cn(c,g){return function(){var a=g.apply(this,arguments);null==a?delete this[c]:this[c]=a}}function Ri(c){return c.trim().split(/^|\s+/)}function Un(c){return c.classList||new Yi(c)}function Yi(c){this._node=c,this._names=Ri(c.getAttribute("class")||"")}function Wi(c,g){for(var a=Un(c),u=-1,x=g.length;++u<x;)a.add(g[u])}function fr(c,g){for(var a=Un(c),u=-1,x=g.length;++u<x;)a.remove(g[u])}function Li(c){return function(){Wi(this,c)}}function Vo(c){return function(){fr(this,c)}}function vr(c,g){return function(){(g.apply(this,arguments)?Wi:fr)(this,c)}}function ks(){this.textContent=""}function Jo(c){return function(){this.textContent=c}}function $s(c){return function(){var g=c.apply(this,arguments);this.textContent=g??""}}function ds(){this.innerHTML=""}function Ws(c){return function(){this.innerHTML=c}}function es(c){return function(){var g=c.apply(this,arguments);this.innerHTML=g??""}}function ts(){this.nextSibling&&this.parentNode.appendChild(this)}function ea(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function sl(c){return function(){var g=this.ownerDocument,a=this.namespaceURI;return a===oa&&g.documentElement.namespaceURI===oa?g.createElement(c):g.createElementNS(a,c)}}function fl(c){return function(){return this.ownerDocument.createElementNS(c.space,c.local)}}function Ia(c){var g=xl(c);return(g.local?fl:sl)(g)}function Kc(){return null}function Sl(){var c=this.parentNode;c&&c.removeChild(this)}function la(){var c=this.cloneNode(!1),g=this.parentNode;return g?g.insertBefore(c,this.nextSibling):c}function pl(){var c=this.cloneNode(!0),g=this.parentNode;return g?g.insertBefore(c,this.nextSibling):c}function ec(c){return function(){var g=this.__on;if(g){for(var I,a=0,u=-1,x=g.length;a<x;++a)I=g[a],c.type&&I.type!==c.type||I.name!==c.name?g[++u]=I:this.removeEventListener(I.type,I.listener,I.options);++u?g.length=u:delete this.__on}}}function Yc(c,g,a){return function(){var x,u=this.__on,I=function Qc(c){return function(g){c.call(this,g,this.__data__)}}(g);if(u)for(var K=0,ye=u.length;K<ye;++K)if((x=u[K]).type===c.type&&x.name===c.name)return this.removeEventListener(x.type,x.listener,x.options),this.addEventListener(x.type,x.listener=I,x.options=a),void(x.value=g);this.addEventListener(c.type,I,a),x={type:c.type,name:c.name,value:g,listener:I,options:a},u?u.push(x):this.__on=[x]}}function Il(c,g,a){var u=Rt(c),x=u.CustomEvent;"function"==typeof x?x=new x(g,a):(x=u.document.createEvent("Event"),a?(x.initEvent(g,a.bubbles,a.cancelable),x.detail=a.detail):x.initEvent(g,!1,!1)),c.dispatchEvent(x)}function Xa(c,g){return function(){return Il(this,c,g)}}function Rl(c,g){return function(){return Il(this,c,g.apply(this,arguments))}}Yi.prototype={add:function(c){this._names.indexOf(c)<0&&(this._names.push(c),this._node.setAttribute("class",this._names.join(" ")))},remove:function(c){var g=this._names.indexOf(c);g>=0&&(this._names.splice(g,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(c){return this._names.indexOf(c)>=0}};var Lu=[null];function Aa(c,g){this._groups=c,this._parents=g}function ku(){return new Aa([[document.documentElement]],Lu)}Aa.prototype=ku.prototype={constructor:Aa,select:function pi(c){"function"!=typeof c&&(c=ri(c));for(var g=this._groups,a=g.length,u=new Array(a),x=0;x<a;++x)for(var Ye,$e,I=g[x],K=I.length,ye=u[x]=new Array(K),ht=0;ht<K;++ht)(Ye=I[ht])&&($e=c.call(Ye,Ye.__data__,ht,I))&&("__data__"in Ye&&($e.__data__=Ye.__data__),ye[ht]=$e);return new Aa(u,this._parents)},selectAll:function qn(c){c="function"==typeof c?function ni(c){return function(){return function At(c){return null==c?[]:Array.isArray(c)?c:Array.from(c)}(c.apply(this,arguments))}}(c):Mn(c);for(var g=this._groups,a=g.length,u=[],x=[],I=0;I<a;++I)for(var Ye,K=g[I],ye=K.length,$e=0;$e<ye;++$e)(Ye=K[$e])&&(u.push(c.call(Ye,Ye.__data__,$e,K)),x.push(Ye));return new Aa(u,x)},selectChild:function Jt(c){return this.select(null==c?Ki:function Ii(c){return function(){return Gi.call(this.children,c)}}("function"==typeof c?c:Bi(c)))},selectChildren:function sn(c){return this.selectAll(null==c?Ft:function it(c){return function(){return hi.call(this.children,c)}}("function"==typeof c?c:Bi(c)))},filter:function Ve(c){"function"!=typeof c&&(c=Ti(c));for(var g=this._groups,a=g.length,u=new Array(a),x=0;x<a;++x)for(var Ye,I=g[x],K=I.length,ye=u[x]=[],$e=0;$e<K;++$e)(Ye=I[$e])&&c.call(Ye,Ye.__data__,$e,I)&&ye.push(Ye);return new Aa(u,this._parents)},data:function qr(c,g){if(!arguments.length)return Array.from(this,_r);var a=g?Sn:Jn,u=this._parents,x=this._groups;"function"!=typeof c&&(c=function nn(c){return function(){return c}}(c));for(var I=x.length,K=new Array(I),ye=new Array(I),Ye=new Array(I),$e=0;$e<I;++$e){var ht=u[$e],Vt=x[$e],zt=Vt.length,yn=Bo(c.call(ht,ht&&ht.__data__,$e,u)),li=yn.length,pr=ye[$e]=new Array(li),si=K[$e]=new Array(li);a(ht,Vt,pr,si,Ye[$e]=new Array(zt),yn,g);for(var ao,lo,_o=0,jr=0;_o<li;++_o)if(ao=pr[_o]){for(_o>=jr&&(jr=_o+1);!(lo=si[jr])&&++jr<li;);ao._next=lo||null}}return(K=new Aa(K,u))._enter=ye,K._exit=Ye,K},enter:function mt(){return new Aa(this._enter||this._groups.map(He),this._parents)},exit:function Eo(){return new Aa(this._exit||this._groups.map(He),this._parents)},join:function Ro(c,g,a){var u=this.enter(),x=this,I=this.exit();return"function"==typeof c?(u=c(u))&&(u=u.selection()):u=u.append(c+""),null!=g&&(x=g(x))&&(x=x.selection()),null==a?I.remove():a(I),u&&x?u.merge(x).order():x},merge:function Ls(c){for(var g=c.selection?c.selection():c,a=this._groups,u=g._groups,x=a.length,K=Math.min(x,u.length),ye=new Array(x),Ye=0;Ye<K;++Ye)for(var yn,$e=a[Ye],ht=u[Ye],Vt=$e.length,zt=ye[Ye]=new Array(Vt),li=0;li<Vt;++li)(yn=$e[li]||ht[li])&&(zt[li]=yn);for(;Ye<x;++Ye)ye[Ye]=a[Ye];return new Aa(ye,this._parents)},selection:function Ql(){return this},order:function ol(){for(var c=this._groups,g=-1,a=c.length;++g<a;)for(var K,u=c[g],x=u.length-1,I=u[x];--x>=0;)(K=u[x])&&(I&&4^K.compareDocumentPosition(I)&&I.parentNode.insertBefore(K,I),I=K);return this},sort:function Va(c){function g(Vt,zt){return Vt&&zt?c(Vt.__data__,zt.__data__):!Vt-!zt}c||(c=Ao);for(var a=this._groups,u=a.length,x=new Array(u),I=0;I<u;++I){for(var $e,K=a[I],ye=K.length,Ye=x[I]=new Array(ye),ht=0;ht<ye;++ht)($e=K[ht])&&(Ye[ht]=$e);Ye.sort(g)}return new Aa(x,this._parents).order()},call:function za(){var c=arguments[0];return arguments[0]=this,c.apply(null,arguments),this},nodes:function vl(){return Array.from(this)},node:function Na(){for(var c=this._groups,g=0,a=c.length;g<a;++g)for(var u=c[g],x=0,I=u.length;x<I;++x){var K=u[x];if(K)return K}return null},size:function _l(){let c=0;for(const g of this)++c;return c},empty:function gs(){return!this.node()},each:function Zs(c){for(var g=this._groups,a=0,u=g.length;a<u;++a)for(var ye,x=g[a],I=0,K=x.length;I<K;++I)(ye=x[I])&&c.call(ye,ye.__data__,I,x);return this},attr:function In(c,g){var a=xl(c);if(arguments.length<2){var u=this.node();return a.local?u.getAttributeNS(a.space,a.local):u.getAttribute(a)}return this.each((null==g?a.local?dl:Qr:"function"==typeof g?a.local?jt:ko:a.local?Lo:Ya)(a,g))},style:function ar(c,g,a){return arguments.length>1?this.each((null==g?jn:"function"==typeof g?Ui:Fi)(c,g,a??"")):er(this.node(),c)},property:function Tn(c,g){return arguments.length>1?this.each((null==g?Or:"function"==typeof g?cn:Tt)(c,g)):this.node()[c]},classed:function Mo(c,g){var a=Ri(c+"");if(arguments.length<2){for(var u=Un(this.node()),x=-1,I=a.length;++x<I;)if(!u.contains(a[x]))return!1;return!0}return this.each(("function"==typeof g?vr:g?Li:Vo)(a,g))},text:function Js(c){return arguments.length?this.each(null==c?ks:("function"==typeof c?$s:Jo)(c)):this.node().textContent},html:function Ma(c){return arguments.length?this.each(null==c?ds:("function"==typeof c?es:Ws)(c)):this.node().innerHTML},raise:function wo(){return this.each(ts)},lower:function ga(){return this.each(ea)},append:function al(c){var g="function"==typeof c?c:Ia(c);return this.select(function(){return this.appendChild(g.apply(this,arguments))})},insert:function wa(c,g){var a="function"==typeof c?c:Ia(c),u=null==g?Kc:"function"==typeof g?g:ri(g);return this.select(function(){return this.insertBefore(a.apply(this,arguments),u.apply(this,arguments)||null)})},remove:function qc(){return this.each(Sl)},clone:function Sc(c){return this.select(c?pl:la)},datum:function Ec(c){return arguments.length?this.property("__data__",c):this.node().__data__},on:function ca(c,g,a){var x,K,u=function ql(c){return c.trim().split(/^|\s+/).map(function(g){var a="",u=g.indexOf(".");return u>=0&&(a=g.slice(u+1),g=g.slice(0,u)),{type:g,name:a}})}(c+""),I=u.length;if(!(arguments.length<2)){for(ye=g?Yc:ec,x=0;x<I;++x)this.each(ye(u[x],g,a));return this}var ye=this.node().__on;if(ye)for(var ht,Ye=0,$e=ye.length;Ye<$e;++Ye)for(x=0,ht=ye[Ye];x<I;++x)if((K=u[x]).type===ht.type&&K.name===ht.name)return ht.value},dispatch:function yl(c,g){return this.each(("function"==typeof g?Rl:Xa)(c,g))},[Symbol.iterator]:function*sa(){for(var c=this._groups,g=0,a=c.length;g<a;++g)for(var K,u=c[g],x=0,I=u.length;x<I;++x)(K=u[x])&&(yield K)}};const sc=ku;function ta(c){return"string"==typeof c?new Aa([[document.querySelector(c)]],[document.documentElement]):new Aa([[c]],Lu)}var vc={value:()=>{}};function xu(){for(var u,c=0,g=arguments.length,a={};c<g;++c){if(!(u=arguments[c]+"")||u in a||/[\s.]/.test(u))throw new Error("illegal type: "+u);a[u]=[]}return new Fc(a)}function Fc(c){this._=c}function Ll(c,g){for(var x,a=0,u=c.length;a<u;++a)if((x=c[a]).name===g)return x.value}function Hs(c,g,a){for(var u=0,x=c.length;u<x;++u)if(c[u].name===g){c[u]=vc,c=c.slice(0,u).concat(c.slice(u+1));break}return null!=a&&c.push({name:g,value:a}),c}Fc.prototype=xu.prototype={constructor:Fc,on:function(c,g){var x,a=this._,u=function po(c,g){return c.trim().split(/^|\s+/).map(function(a){var u="",x=a.indexOf(".");if(x>=0&&(u=a.slice(x+1),a=a.slice(0,x)),a&&!g.hasOwnProperty(a))throw new Error("unknown type: "+a);return{type:a,name:u}})}(c+"",a),I=-1,K=u.length;if(!(arguments.length<2)){if(null!=g&&"function"!=typeof g)throw new Error("invalid callback: "+g);for(;++I<K;)if(x=(c=u[I]).type)a[x]=Hs(a[x],c.name,g);else if(null==g)for(x in a)a[x]=Hs(a[x],c.name,null);return this}for(;++I<K;)if((x=(c=u[I]).type)&&(x=Ll(a[x],c.name)))return x},copy:function(){var c={},g=this._;for(var a in g)c[a]=g[a].slice();return new Fc(c)},call:function(c,g){if((x=arguments.length-2)>0)for(var x,I,a=new Array(x),u=0;u<x;++u)a[u]=arguments[u+2];if(!this._.hasOwnProperty(c))throw new Error("unknown type: "+c);for(u=0,x=(I=this._[c]).length;u<x;++u)I[u].value.apply(g,a)},apply:function(c,g,a){if(!this._.hasOwnProperty(c))throw new Error("unknown type: "+c);for(var u=this._[c],x=0,I=u.length;x<I;++x)u[x].value.apply(g,a)}};const kl=xu,fu={capture:!0,passive:!1};function Ke(c){c.preventDefault(),c.stopImmediatePropagation()}function Ge(c,g,a){c.prototype=g.prototype=a,a.constructor=c}function xt(c,g){var a=Object.create(c.prototype);for(var u in g)a[u]=g[u];return a}function Qt(){}var bi=1/.7,vi="\\s*([+-]?\\d+)\\s*",Ci="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Xi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",$i=/^#([0-9a-f]{3,8})$/,Er=new RegExp(`^rgb\\(${vi},${vi},${vi}\\)$`),ai=new RegExp(`^rgb\\(${Xi},${Xi},${Xi}\\)$`),so=new RegExp(`^rgba\\(${vi},${vi},${vi},${Ci}\\)$`),Fr=new RegExp(`^rgba\\(${Xi},${Xi},${Xi},${Ci}\\)$`),zr=new RegExp(`^hsl\\(${Ci},${Xi},${Xi}\\)$`),ho=new RegExp(`^hsla\\(${Ci},${Xi},${Xi},${Ci}\\)$`),Vr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function is(){return this.rgb().formatHex()}function Xo(){return this.rgb().formatRgb()}function na(c){var g,a;return c=(c+"").trim().toLowerCase(),(g=$i.exec(c))?(a=g[1].length,g=parseInt(g[1],16),6===a?zs(g):3===a?new Oe(g>>8&15|g>>4&240,g>>4&15|240&g,(15&g)<<4|15&g,1):8===a?ya(g>>24&255,g>>16&255,g>>8&255,(255&g)/255):4===a?ya(g>>12&15|g>>8&240,g>>8&15|g>>4&240,g>>4&15|240&g,((15&g)<<4|15&g)/255):null):(g=Er.exec(c))?new Oe(g[1],g[2],g[3],1):(g=ai.exec(c))?new Oe(255*g[1]/100,255*g[2]/100,255*g[3]/100,1):(g=so.exec(c))?ya(g[1],g[2],g[3],g[4]):(g=Fr.exec(c))?ya(255*g[1]/100,255*g[2]/100,255*g[3]/100,g[4]):(g=zr.exec(c))?fo(g[1],g[2]/100,g[3]/100,1):(g=ho.exec(c))?fo(g[1],g[2]/100,g[3]/100,g[4]):Vr.hasOwnProperty(c)?zs(Vr[c]):"transparent"===c?new Oe(NaN,NaN,NaN,0):null}function zs(c){return new Oe(c>>16&255,c>>8&255,255&c,1)}function ya(c,g,a,u){return u<=0&&(c=g=a=NaN),new Oe(c,g,a,u)}function at(c,g,a,u){return 1===arguments.length?function Je(c){return c instanceof Qt||(c=na(c)),c?new Oe((c=c.rgb()).r,c.g,c.b,c.opacity):new Oe}(c):new Oe(c,g,a,u??1)}function Oe(c,g,a,u){this.r=+c,this.g=+g,this.b=+a,this.opacity=+u}function Ct(){return`#${Di(this.r)}${Di(this.g)}${Di(this.b)}`}function _i(){const c=Qn(this.opacity);return`${1===c?"rgb(":"rgba("}${qi(this.r)}, ${qi(this.g)}, ${qi(this.b)}${1===c?")":`, ${c})`}`}function Qn(c){return isNaN(c)?1:Math.max(0,Math.min(1,c))}function qi(c){return Math.max(0,Math.min(255,Math.round(c)||0))}function Di(c){return((c=qi(c))<16?"0":"")+c.toString(16)}function fo(c,g,a,u){return u<=0?c=g=a=NaN:a<=0||a>=1?c=g=NaN:g<=0&&(c=NaN),new ba(c,g,a,u)}function Uo(c){if(c instanceof ba)return new ba(c.h,c.s,c.l,c.opacity);if(c instanceof Qt||(c=na(c)),!c)return new ba;if(c instanceof ba)return c;var g=(c=c.rgb()).r/255,a=c.g/255,u=c.b/255,x=Math.min(g,a,u),I=Math.max(g,a,u),K=NaN,ye=I-x,Ye=(I+x)/2;return ye?(K=g===I?(a-u)/ye+6*(a<u):a===I?(u-g)/ye+2:(g-a)/ye+4,ye/=Ye<.5?I+x:2-I-x,K*=60):ye=Ye>0&&Ye<1?0:K,new ba(K,ye,Ye,c.opacity)}function ba(c,g,a,u){this.h=+c,this.s=+g,this.l=+a,this.opacity=+u}function Za(c){return(c=(c||0)%360)<0?c+360:c}function Ks(c){return Math.max(0,Math.min(1,c||0))}function ac(c,g,a){return 255*(c<60?g+(a-g)*c/60:c<180?a:c<240?g+(a-g)*(240-c)/60:g)}function lc(c,g,a,u,x){var I=c*c,K=I*c;return((1-3*c+3*I-K)*g+(4-6*I+3*K)*a+(1+3*c+3*I-3*K)*u+K*x)/6}Ge(Qt,na,{copy(c){return Object.assign(new this.constructor,this,c)},displayable(){return this.rgb().displayable()},hex:is,formatHex:is,formatHex8:function Ms(){return this.rgb().formatHex8()},formatHsl:function Ds(){return Uo(this).formatHsl()},formatRgb:Xo,toString:Xo}),Ge(Oe,at,xt(Qt,{brighter(c){return c=null==c?bi:Math.pow(bi,c),new Oe(this.r*c,this.g*c,this.b*c,this.opacity)},darker(c){return c=null==c?.7:Math.pow(.7,c),new Oe(this.r*c,this.g*c,this.b*c,this.opacity)},rgb(){return this},clamp(){return new Oe(qi(this.r),qi(this.g),qi(this.b),Qn(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Ct,formatHex:Ct,formatHex8:function On(){return`#${Di(this.r)}${Di(this.g)}${Di(this.b)}${Di(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:_i,toString:_i})),Ge(ba,function Gs(c,g,a,u){return 1===arguments.length?Uo(c):new ba(c,g,a,u??1)},xt(Qt,{brighter(c){return c=null==c?bi:Math.pow(bi,c),new ba(this.h,this.s,this.l*c,this.opacity)},darker(c){return c=null==c?.7:Math.pow(.7,c),new ba(this.h,this.s,this.l*c,this.opacity)},rgb(){var c=this.h%360+360*(this.h<0),g=isNaN(c)||isNaN(this.s)?0:this.s,a=this.l,u=a+(a<.5?a:1-a)*g,x=2*a-u;return new Oe(ac(c>=240?c-240:c+120,x,u),ac(c,x,u),ac(c<120?c+240:c-120,x,u),this.opacity)},clamp(){return new ba(Za(this.h),Ks(this.s),Ks(this.l),Qn(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const c=Qn(this.opacity);return`${1===c?"hsl(":"hsla("}${Za(this.h)}, ${100*Ks(this.s)}%, ${100*Ks(this.l)}%${1===c?")":`, ${c})`}`}}));const da=c=>()=>c;function cc(c,g){var a=g-c;return a?function nd(c,g){return function(a){return c+a*g}}(c,a):da(isNaN(c)?g:c)}const qf=function c(g){var a=function _c(c){return 1==(c=+c)?cc:function(g,a){return a-g?function xp(c,g,a){return c=Math.pow(c,a),g=Math.pow(g,a)-c,a=1/a,function(u){return Math.pow(c+u*g,a)}}(g,a,c):da(isNaN(g)?a:g)}}(g);function u(x,I){var K=a((x=at(x)).r,(I=at(I)).r),ye=a(x.g,I.g),Ye=a(x.b,I.b),$e=cc(x.opacity,I.opacity);return function(ht){return x.r=K(ht),x.g=ye(ht),x.b=Ye(ht),x.opacity=$e(ht),x+""}}return u.gamma=c,u}(1);function aa(c){return function(g){var K,ye,a=g.length,u=new Array(a),x=new Array(a),I=new Array(a);for(K=0;K<a;++K)ye=at(g[K]),u[K]=ye.r||0,x[K]=ye.g||0,I[K]=ye.b||0;return u=c(u),x=c(x),I=c(I),ye.opacity=1,function(Ye){return ye.r=u(Ye),ye.g=x(Ye),ye.b=I(Ye),ye+""}}}function ff(c,g){var K,a=g?g.length:0,u=c?Math.min(a,c.length):0,x=new Array(u),I=new Array(a);for(K=0;K<u;++K)x[K]=qs(c[K],g[K]);for(;K<a;++K)I[K]=g[K];return function(ye){for(K=0;K<u;++K)I[K]=x[K](ye);return I}}function Yt(c,g){var a=new Date;return c=+c,g=+g,function(u){return a.setTime(c*(1-u)+g*u),a}}function tc(c,g){return c=+c,g=+g,function(a){return c*(1-a)+g*a}}function Qh(c,g){var x,a={},u={};for(x in(null===c||"object"!=typeof c)&&(c={}),(null===g||"object"!=typeof g)&&(g={}),g)x in c?a[x]=qs(c[x],g[x]):u[x]=g[x];return function(I){for(x in a)u[x]=a[x](I);return u}}aa(function ou(c){var g=c.length-1;return function(a){var u=a<=0?a=0:a>=1?(a=1,g-1):Math.floor(a*g),x=c[u],I=c[u+1];return lc((a-u/g)*g,u>0?c[u-1]:2*x-I,x,I,u<g-1?c[u+2]:2*I-x)}}),aa(function qd(c){var g=c.length;return function(a){var u=Math.floor(((a%=1)<0?++a:a)*g);return lc((a-u/g)*g,c[(u+g-1)%g],c[u%g],c[(u+1)%g],c[(u+2)%g])}});var Su=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,md=new RegExp(Su.source,"g");function Eu(c,g){var u,x,I,a=Su.lastIndex=md.lastIndex=0,K=-1,ye=[],Ye=[];for(c+="",g+="";(u=Su.exec(c))&&(x=md.exec(g));)(I=x.index)>a&&(I=g.slice(a,I),ye[K]?ye[K]+=I:ye[++K]=I),(u=u[0])===(x=x[0])?ye[K]?ye[K]+=x:ye[++K]=x:(ye[++K]=null,Ye.push({i:K,x:tc(u,x)})),a=md.lastIndex;return a<g.length&&(I=g.slice(a),ye[K]?ye[K]+=I:ye[++K]=I),ye.length<2?Ye[0]?function gd(c){return function(g){return c(g)+""}}(Ye[0].x):function Ld(c){return function(){return c}}(g):(g=Ye.length,function($e){for(var Vt,ht=0;ht<g;++ht)ye[(Vt=Ye[ht]).i]=Vt.x($e);return ye.join("")})}function Pu(c,g){g||(g=[]);var x,a=c?Math.min(g.length,c.length):0,u=g.slice();return function(I){for(x=0;x<a;++x)u[x]=c[x]*(1-I)+g[x]*I;return u}}function qs(c,g){var u,a=typeof g;return null==g||"boolean"===a?da(g):("number"===a?tc:"string"===a?(u=na(g))?(g=u,qf):Eu:g instanceof na?qf:g instanceof Date?Yt:function Lc(c){return ArrayBuffer.isView(c)&&!(c instanceof DataView)}(g)?Pu:Array.isArray(g)?ff:"function"!=typeof g.valueOf&&"function"!=typeof g.toString||isNaN(g)?Qh:tc)(c,g)}function Bu(c,g){if(c=function Xc(c){let g;for(;g=c.sourceEvent;)c=g;return c}(c),void 0===g&&(g=c.currentTarget),g){var a=g.ownerSVGElement||g;if(a.createSVGPoint){var u=a.createSVGPoint();return u.x=c.clientX,u.y=c.clientY,[(u=u.matrixTransform(g.getScreenCTM().inverse())).x,u.y]}if(g.getBoundingClientRect){var x=g.getBoundingClientRect();return[c.clientX-x.left-g.clientLeft,c.clientY-x.top-g.clientTop]}}return[c.pageX,c.pageY]}var Vu,id,su=0,Is=0,xa=0,vd=1e3,Sd=0,pu=0,hu=0,As="object"==typeof performance&&performance.now?performance:Date,Ed="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(c){setTimeout(c,17)};function kc(){return pu||(Ed(El),pu=As.now()+hu)}function El(){pu=0}function uc(){this._call=this._time=this._next=null}function kd(c,g,a){var u=new uc;return u.restart(c,g,a),u}function Pc(){pu=(Sd=As.now())+hu,su=Is=0;try{!function Td(){kc(),++su;for(var g,c=Vu;c;)(g=pu-c._time)>=0&&c._call.call(void 0,g),c=c._next;--su}()}finally{su=0,function Yl(){for(var c,a,g=Vu,u=1/0;g;)g._call?(u>g._time&&(u=g._time),c=g,g=g._next):(a=g._next,g._next=null,g=c?c._next=a:Vu=a);id=c,Bc(u)}(),pu=0}}function ju(){var c=As.now(),g=c-Sd;g>vd&&(hu-=g,Sd=c)}function Bc(c){su||(Is&&(Is=clearTimeout(Is)),c-pu>24?(c<1/0&&(Is=setTimeout(Pc,c-As.now()-hu)),xa&&(xa=clearInterval(xa))):(xa||(Sd=As.now(),xa=setInterval(ju,vd)),su=1,Ed(Pc)))}function pf(c,g,a){var u=new uc;return u.restart(x=>{u.stop(),c(x+g)},g=null==g?0:+g,a),u}uc.prototype=kd.prototype={constructor:uc,restart:function(c,g,a){if("function"!=typeof c)throw new TypeError("callback is not a function");a=(null==a?kc():+a)+(null==g?0:+g),!this._next&&id!==this&&(id?id._next=this:Vu=this,id=this),this._call=c,this._time=a,Bc()},stop:function(){this._call&&(this._call=null,this._time=1/0,Bc())}};var hf=kl("start","end","cancel","interrupt"),_e=[],Dt=0,tt=2,mn=3,rr=5,or=6;function ia(c,g,a,u,x,I){var K=c.__transition;if(K){if(a in K)return}else c.__transition={};!function ll(c,g,a){var x,u=c.__transition;function K($e){var ht,Vt,zt,yn;if(1!==a.state)return Ye();for(ht in u)if((yn=u[ht]).name===a.name){if(yn.state===mn)return pf(K);4===yn.state?(yn.state=or,yn.timer.stop(),yn.on.call("interrupt",c,c.__data__,yn.index,yn.group),delete u[ht]):+ht<g&&(yn.state=or,yn.timer.stop(),yn.on.call("cancel",c,c.__data__,yn.index,yn.group),delete u[ht])}if(pf(function(){a.state===mn&&(a.state=4,a.timer.restart(ye,a.delay,a.time),ye($e))}),a.state=tt,a.on.call("start",c,c.__data__,a.index,a.group),a.state===tt){for(a.state=mn,x=new Array(zt=a.tween.length),ht=0,Vt=-1;ht<zt;++ht)(yn=a.tween[ht].value.call(c,c.__data__,a.index,a.group))&&(x[++Vt]=yn);x.length=Vt+1}}function ye($e){for(var ht=$e<a.duration?a.ease.call(null,$e/a.duration):(a.timer.restart(Ye),a.state=rr,1),Vt=-1,zt=x.length;++Vt<zt;)x[Vt].call(c,ht);a.state===rr&&(a.on.call("end",c,c.__data__,a.index,a.group),Ye())}function Ye(){for(var $e in a.state=or,a.timer.stop(),delete u[g],u)return;delete c.__transition}u[g]=a,a.timer=kd(function I($e){a.state=1,a.timer.restart(K,a.delay,a.time),a.delay<=$e&&K($e-a.delay)},0,a.time)}(c,a,{name:g,index:u,group:x,on:hf,tween:_e,time:I.time,delay:I.delay,duration:I.duration,ease:I.ease,timer:null,state:Dt})}function La(c,g){var a=Qo(c,g);if(a.state>Dt)throw new Error("too late; already scheduled");return a}function vs(c,g){var a=Qo(c,g);if(a.state>mn)throw new Error("too late; already running");return a}function Qo(c,g){var a=c.__transition;if(!a||!(a=a[g]))throw new Error("transition not found");return a}function Sa(c,g){var u,x,K,a=c.__transition,I=!0;if(a){for(K in g=null==g?null:g+"",a)(u=a[K]).name===g?(x=u.state>tt&&u.state<rr,u.state=or,u.timer.stop(),u.on.call(x?"interrupt":"cancel",c,c.__data__,u.index,u.group),delete a[K]):I=!1;I&&delete c.__transition}}var ne,Mc=180/Math.PI,yc={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Ue(c,g,a,u,x,I){var K,ye,Ye;return(K=Math.sqrt(c*c+g*g))&&(c/=K,g/=K),(Ye=c*a+g*u)&&(a-=c*Ye,u-=g*Ye),(ye=Math.sqrt(a*a+u*u))&&(a/=ye,u/=ye,Ye/=ye),c*u<g*a&&(c=-c,g=-g,Ye=-Ye,K=-K),{translateX:x,translateY:I,rotate:Math.atan2(g,c)*Mc,skewX:Math.atan(Ye)*Mc,scaleX:K,scaleY:ye}}function Ut(c,g,a,u){function x($e){return $e.length?$e.pop()+" ":""}return function($e,ht){var Vt=[],zt=[];return $e=c($e),ht=c(ht),function I($e,ht,Vt,zt,yn,li){if($e!==Vt||ht!==zt){var pr=yn.push("translate(",null,g,null,a);li.push({i:pr-4,x:tc($e,Vt)},{i:pr-2,x:tc(ht,zt)})}else(Vt||zt)&&yn.push("translate("+Vt+g+zt+a)}($e.translateX,$e.translateY,ht.translateX,ht.translateY,Vt,zt),function K($e,ht,Vt,zt){$e!==ht?($e-ht>180?ht+=360:ht-$e>180&&($e+=360),zt.push({i:Vt.push(x(Vt)+"rotate(",null,u)-2,x:tc($e,ht)})):ht&&Vt.push(x(Vt)+"rotate("+ht+u)}($e.rotate,ht.rotate,Vt,zt),function ye($e,ht,Vt,zt){$e!==ht?zt.push({i:Vt.push(x(Vt)+"skewX(",null,u)-2,x:tc($e,ht)}):ht&&Vt.push(x(Vt)+"skewX("+ht+u)}($e.skewX,ht.skewX,Vt,zt),function Ye($e,ht,Vt,zt,yn,li){if($e!==Vt||ht!==zt){var pr=yn.push(x(yn)+"scale(",null,",",null,")");li.push({i:pr-4,x:tc($e,Vt)},{i:pr-2,x:tc(ht,zt)})}else(1!==Vt||1!==zt)&&yn.push(x(yn)+"scale("+Vt+","+zt+")")}($e.scaleX,$e.scaleY,ht.scaleX,ht.scaleY,Vt,zt),$e=ht=null,function(yn){for(var si,li=-1,pr=zt.length;++li<pr;)Vt[(si=zt[li]).i]=si.x(yn);return Vt.join("")}}}var Rn=Ut(function Pe(c){const g=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(c+"");return g.isIdentity?yc:Ue(g.a,g.b,g.c,g.d,g.e,g.f)},"px, ","px)","deg)"),Kn=Ut(function rt(c){return null!=c&&(ne||(ne=document.createElementNS("http://www.w3.org/2000/svg","g")),ne.setAttribute("transform",c),c=ne.transform.baseVal.consolidate())?Ue((c=c.matrix).a,c.b,c.c,c.d,c.e,c.f):yc},", ",")",")");function Y(c,g){var a,u;return function(){var x=vs(this,c),I=x.tween;if(I!==a)for(var K=0,ye=(u=a=I).length;K<ye;++K)if(u[K].name===g){(u=u.slice()).splice(K,1);break}x.tween=u}}function Ce(c,g,a){var u,x;if("function"!=typeof a)throw new Error;return function(){var I=vs(this,c),K=I.tween;if(K!==u){x=(u=K).slice();for(var ye={name:g,value:a},Ye=0,$e=x.length;Ye<$e;++Ye)if(x[Ye].name===g){x[Ye]=ye;break}Ye===$e&&x.push(ye)}I.tween=x}}function Ie(c,g,a){var u=c._id;return c.each(function(){var x=vs(this,u);(x.value||(x.value={}))[g]=a.apply(this,arguments)}),function(x){return Qo(x,u).value[g]}}function Ze(c,g){var a;return("number"==typeof g?tc:g instanceof na?qf:(a=na(g))?(g=a,qf):Eu)(c,g)}function kt(c){return function(){this.removeAttribute(c)}}function rn(c){return function(){this.removeAttributeNS(c.space,c.local)}}function Si(c,g,a){var u,I,x=a+"";return function(){var K=this.getAttribute(c);return K===x?null:K===u?I:I=g(u=K,a)}}function oi(c,g,a){var u,I,x=a+"";return function(){var K=this.getAttributeNS(c.space,c.local);return K===x?null:K===u?I:I=g(u=K,a)}}function Yr(c,g,a){var u,x,I;return function(){var K,Ye,ye=a(this);return null==ye?void this.removeAttribute(c):(K=this.getAttribute(c))===(Ye=ye+"")?null:K===u&&Ye===x?I:(x=Ye,I=g(u=K,ye))}}function rs(c,g,a){var u,x,I;return function(){var K,Ye,ye=a(this);return null==ye?void this.removeAttributeNS(c.space,c.local):(K=this.getAttributeNS(c.space,c.local))===(Ye=ye+"")?null:K===u&&Ye===x?I:(x=Ye,I=g(u=K,ye))}}function dc(c,g){var a,u;function x(){var I=g.apply(this,arguments);return I!==u&&(a=(u=I)&&function Hl(c,g){return function(a){this.setAttributeNS(c.space,c.local,g.call(this,a))}}(c,I)),a}return x._value=g,x}function ws(c,g){var a,u;function x(){var I=g.apply(this,arguments);return I!==u&&(a=(u=I)&&function Zo(c,g){return function(a){this.setAttribute(c,g.call(this,a))}}(c,I)),a}return x._value=g,x}function Wo(c,g){return function(){La(this,c).delay=+g.apply(this,arguments)}}function sr(c,g){return g=+g,function(){La(this,c).delay=g}}function Ic(c,g){return function(){vs(this,c).duration=+g.apply(this,arguments)}}function Sp(c,g){return g=+g,function(){vs(this,c).duration=g}}var Ch=sc.prototype.constructor;function If(c){return function(){this.style.removeProperty(c)}}var Ev=0;function sp(c,g,a,u){this._groups=c,this._parents=g,this._name=a,this._id=u}function va(){return++Ev}var bc=sc.prototype;sp.prototype=function Ep(c){return sc().transition(c)}.prototype={constructor:sp,select:function mf(c){var g=this._name,a=this._id;"function"!=typeof c&&(c=ri(c));for(var u=this._groups,x=u.length,I=new Array(x),K=0;K<x;++K)for(var ht,Vt,ye=u[K],Ye=ye.length,$e=I[K]=new Array(Ye),zt=0;zt<Ye;++zt)(ht=ye[zt])&&(Vt=c.call(ht,ht.__data__,zt,ye))&&("__data__"in ht&&(Vt.__data__=ht.__data__),$e[zt]=Vt,ia($e[zt],g,a,zt,$e,Qo(ht,a)));return new sp(I,this._parents,g,a)},selectAll:function U_(c){var g=this._name,a=this._id;"function"!=typeof c&&(c=Mn(c));for(var u=this._groups,x=u.length,I=[],K=[],ye=0;ye<x;++ye)for(var ht,Ye=u[ye],$e=Ye.length,Vt=0;Vt<$e;++Vt)if(ht=Ye[Vt]){for(var yn,zt=c.call(ht,ht.__data__,Vt,Ye),li=Qo(ht,a),pr=0,si=zt.length;pr<si;++pr)(yn=zt[pr])&&ia(yn,g,a,pr,zt,li);I.push(zt),K.push(ht)}return new sp(I,K,g,a)},selectChild:bc.selectChild,selectChildren:bc.selectChildren,filter:function Pd(c){"function"!=typeof c&&(c=Ti(c));for(var g=this._groups,a=g.length,u=new Array(a),x=0;x<a;++x)for(var Ye,I=g[x],K=I.length,ye=u[x]=[],$e=0;$e<K;++$e)(Ye=I[$e])&&c.call(Ye,Ye.__data__,$e,I)&&ye.push(Ye);return new sp(u,this._parents,this._name,this._id)},merge:function $u(c){if(c._id!==this._id)throw new Error;for(var g=this._groups,a=c._groups,u=g.length,I=Math.min(u,a.length),K=new Array(u),ye=0;ye<I;++ye)for(var zt,Ye=g[ye],$e=a[ye],ht=Ye.length,Vt=K[ye]=new Array(ht),yn=0;yn<ht;++yn)(zt=Ye[yn]||$e[yn])&&(Vt[yn]=zt);for(;ye<u;++ye)K[ye]=g[ye];return new sp(K,this._parents,this._name,this._id)},selection:function Zc(){return new Ch(this._groups,this._parents)},transition:function Qu(){for(var c=this._name,g=this._id,a=va(),u=this._groups,x=u.length,I=0;I<x;++I)for(var Ye,K=u[I],ye=K.length,$e=0;$e<ye;++$e)if(Ye=K[$e]){var ht=Qo(Ye,g);ia(Ye,c,a,$e,K,{time:ht.time+ht.delay+ht.duration,delay:0,duration:ht.duration,ease:ht.ease})}return new sp(u,this._parents,c,a)},call:bc.call,nodes:bc.nodes,node:bc.node,size:bc.size,empty:bc.empty,each:bc.each,on:function Qd(c,g){var a=this._id;return arguments.length<2?Qo(this.node(),a).on.on(c):this.each(function yg(c,g,a){var u,x,I=function Yh(c){return(c+"").trim().split(/^|\s+/).every(function(g){var a=g.indexOf(".");return a>=0&&(g=g.slice(0,a)),!g||"start"===g})}(g)?La:vs;return function(){var K=I(this,c),ye=K.on;ye!==u&&(x=(u=ye).copy()).on(g,a),K.on=x}}(a,c,g))},attr:function ls(c,g){var a=xl(c),u="transform"===a?Kn:Ze;return this.attrTween(c,"function"==typeof g?(a.local?rs:Yr)(a,u,Ie(this,"attr."+c,g)):null==g?(a.local?rn:kt)(a):(a.local?oi:Si)(a,u,g))},attrTween:function Vc(c,g){var a="attr."+c;if(arguments.length<2)return(a=this.tween(a))&&a._value;if(null==g)return this.tween(a,null);if("function"!=typeof g)throw new Error;var u=xl(c);return this.tween(a,(u.local?dc:ws)(u,g))},style:function Dh(c,g,a){var u="transform"==(c+="")?Rn:Ze;return null==g?this.styleTween(c,function Tu(c,g){var a,u,x;return function(){var I=er(this,c),K=(this.style.removeProperty(c),er(this,c));return I===K?null:I===a&&K===u?x:x=g(a=I,u=K)}}(c,u)).on("end.style."+c,If(c)):"function"==typeof g?this.styleTween(c,function Ji(c,g,a){var u,x,I;return function(){var K=er(this,c),ye=a(this),Ye=ye+"";return null==ye&&(this.style.removeProperty(c),Ye=ye=er(this,c)),K===Ye?null:K===u&&Ye===x?I:(x=Ye,I=g(u=K,ye))}}(c,u,Ie(this,"style."+c,g))).each(function xr(c,g){var a,u,x,ye,I="style."+g,K="end."+I;return function(){var Ye=vs(this,c),$e=Ye.on,ht=null==Ye.value[I]?ye||(ye=If(g)):void 0;($e!==a||x!==ht)&&(u=(a=$e).copy()).on(K,x=ht),Ye.on=u}}(this._id,c)):this.styleTween(c,function C0(c,g,a){var u,I,x=a+"";return function(){var K=er(this,c);return K===x?null:K===u?I:I=g(u=K,a)}}(c,u,g),a).on("end.style."+c,null)},styleTween:function Cg(c,g,a){var u="style."+(c+="");if(arguments.length<2)return(u=this.tween(u))&&u._value;if(null==g)return this.tween(u,null);if("function"!=typeof g)throw new Error;return this.tween(u,function $_(c,g,a){var u,x;function I(){var K=g.apply(this,arguments);return K!==x&&(u=(x=K)&&function D0(c,g,a){return function(u){this.style.setProperty(c,g.call(this,u),a)}}(c,K,a)),u}return I._value=g,I}(c,g,a??""))},text:function ja(c){return this.tween("text","function"==typeof c?function Am(c){return function(){var g=c(this);this.textContent=g??""}}(Ie(this,"text",c)):function Sv(c){return function(){this.textContent=c}}(null==c?"":c+""))},textTween:function Yd(c){var g="text";if(arguments.length<1)return(g=this.tween(g))&&g._value;if(null==c)return this.tween(g,null);if("function"!=typeof c)throw new Error;return this.tween(g,function rd(c){var g,a;function u(){var x=c.apply(this,arguments);return x!==a&&(g=(a=x)&&function xs(c){return function(g){this.textContent=c.call(this,g)}}(x)),g}return u._value=c,u}(c))},remove:function bg(){return this.on("end.remove",function xv(c){return function(){var g=this.parentNode;for(var a in this.__transition)if(+a!==c)return;g&&g.removeChild(this)}}(this._id))},tween:function ue(c,g){var a=this._id;if(c+="",arguments.length<2){for(var K,u=Qo(this.node(),a).tween,x=0,I=u.length;x<I;++x)if((K=u[x]).name===c)return K.value;return null}return this.each((null==g?Y:Ce)(a,c,g))},delay:function ro(c){var g=this._id;return arguments.length?this.each(("function"==typeof c?Wo:sr)(g,c)):Qo(this.node(),g).delay},duration:function au(c){var g=this._id;return arguments.length?this.each(("function"==typeof c?Ic:Sp)(g,c)):Qo(this.node(),g).duration},ease:function bh(c){var g=this._id;return arguments.length?this.each(function Uu(c,g){if("function"!=typeof g)throw new Error;return function(){vs(this,c).ease=g}}(g,c)):Qo(this.node(),g).ease},easeVarying:function op(c){if("function"!=typeof c)throw new Error;return this.each(function wv(c,g){return function(){var a=g.apply(this,arguments);if("function"!=typeof a)throw new Error;vs(this,c).ease=a}}(this._id,c))},end:function Xd(){var c,g,a=this,u=a._id,x=a.size();return new Promise(function(I,K){var ye={value:K},Ye={value:function(){0==--x&&I()}};a.each(function(){var $e=vs(this,u),ht=$e.on;ht!==c&&((g=(c=ht).copy())._.cancel.push(ye),g._.interrupt.push(ye),g._.end.push(Ye)),$e.on=g}),0===x&&I()})},[Symbol.iterator]:bc[Symbol.iterator]};var Wu={time:null,delay:0,duration:250,ease:function Om(c){return((c*=2)<=1?c*c*c:(c-=2)*c*c+2)/2}};function zl(c,g){for(var a;!(a=c.__transition)||!(a=a[g]);)if(!(c=c.parentNode))throw new Error(`transition ${g} not found`);return a}sc.prototype.interrupt=function $o(c){return this.each(function(){Sa(this,c)})},sc.prototype.transition=function Tp(c){var g,a;c instanceof sp?(g=c._id,c=c._name):(g=va(),(a=Wu).time=kc(),c=null==c?null:c+"");for(var u=this._groups,x=u.length,I=0;I<x;++I)for(var Ye,K=u[I],ye=K.length,$e=0;$e<ye;++$e)(Ye=K[$e])&&ia(Ye,c,g,$e,K,a||zl(Ye,g));return new sp(u,this._parents,c,g)};const Mp=c=>()=>c;function Zd(c,{sourceEvent:g,target:a,selection:u,mode:x,dispatch:I}){Object.defineProperties(this,{type:{value:c,enumerable:!0,configurable:!0},sourceEvent:{value:g,enumerable:!0,configurable:!0},target:{value:a,enumerable:!0,configurable:!0},selection:{value:u,enumerable:!0,configurable:!0},mode:{value:x,enumerable:!0,configurable:!0},_:{value:I}})}function ap(c){c.preventDefault(),c.stopImmediatePropagation()}var Af={name:"drag"},_d={name:"space"},Mu={name:"handle"},Jd={name:"center"};const{abs:W_,max:Iu,min:ns}=Math;function Hu(c){return[+c[0],+c[1]]}function gf(c){return[Hu(c[0]),Hu(c[1])]}var Zp={name:"x",handles:["w","e"].map(Ip),input:function(c,g){return null==c?null:[[+c[0],g[0][1]],[+c[1],g[1][1]]]},output:function(c){return c&&[c[0][0],c[1][0]]}},xh={name:"y",handles:["n","s"].map(Ip),input:function(c,g){return null==c?null:[[g[0][0],+c[0]],[g[1][0],+c[1]]]},output:function(c){return c&&[c[0][1],c[1][1]]}},Md=(["n","w","e","s","nw","ne","sw","se"].map(Ip),{overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"}),Of={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},Qf={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},w0={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},r1={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Ip(c){return{type:c}}function Mv(c){return!c.ctrlKey&&!c.button}function Xh(){var c=this.ownerSVGElement||this;return c.hasAttribute("viewBox")?[[(c=c.viewBox.baseVal).x,c.y],[c.x+c.width,c.y+c.height]]:[[0,0],[c.width.baseVal.value,c.height.baseVal.value]]}function Nm(){return navigator.maxTouchPoints||"ontouchstart"in this}function od(c){for(;!c.__brush;)if(!(c=c.parentNode))return;return c.__brush}function yd(c,g){return null==c||null==g?NaN:c<g?-1:c>g?1:c>=g?0:NaN}function Rm(c,g){return null==c||null==g?NaN:g<c?-1:g>c?1:g>=c?0:NaN}function Lm(c){let g,a,u;function x(ye,Ye,$e=0,ht=ye.length){if($e<ht){if(0!==g(Ye,Ye))return ht;do{const Vt=$e+ht>>>1;a(ye[Vt],Ye)<0?$e=Vt+1:ht=Vt}while($e<ht)}return $e}return 2!==c.length?(g=yd,a=(ye,Ye)=>yd(c(ye),Ye),u=(ye,Ye)=>c(ye)-Ye):(g=c===yd||c===Rm?c:Sh,a=c,u=c),{left:x,center:function K(ye,Ye,$e=0,ht=ye.length){const Vt=x(ye,Ye,$e,ht-1);return Vt>$e&&u(ye[Vt-1],Ye)>-u(ye[Vt],Ye)?Vt-1:Vt},right:function I(ye,Ye,$e=0,ht=ye.length){if($e<ht){if(0!==g(Ye,Ye))return ht;do{const Vt=$e+ht>>>1;a(ye[Vt],Ye)<=0?$e=Vt+1:ht=Vt}while($e<ht)}return $e}}}function Sh(){return 0}const Dg=Math.sqrt(50),km=Math.sqrt(10),Nf=Math.sqrt(2);function Jp(c,g,a){const u=(g-c)/Math.max(0,a),x=Math.floor(Math.log10(u)),I=u/Math.pow(10,x),K=I>=Dg?10:I>=km?5:I>=Nf?2:1;let ye,Ye,$e;return x<0?($e=Math.pow(10,-x)/K,ye=Math.round(c*$e),Ye=Math.round(g*$e),ye/$e<c&&++ye,Ye/$e>g&&--Ye,$e=-$e):($e=Math.pow(10,x)*K,ye=Math.round(c/$e),Ye=Math.round(g/$e),ye*$e<c&&++ye,Ye*$e>g&&--Ye),Ye<ye&&.5<=a&&a<2?Jp(c,g,2*a):[ye,Ye,$e]}function io(c,g,a){return Jp(c=+c,g=+g,a=+a)[2]}function Ps(c,g,a){a=+a;const u=(g=+g)<(c=+c),x=u?io(g,c,a):io(c,g,a);return(u?-1:1)*(x<0?1/-x:x)}const fc=1e3,Xl=6e4,nc=60*Xl,ra=24*nc,Rf=7*ra,Ja=30*ra,Jc=365*ra,sd=new Date,Ss=new Date;function ps(c,g,a,u){function x(I){return c(I=0===arguments.length?new Date:new Date(+I)),I}return x.floor=I=>(c(I=new Date(+I)),I),x.ceil=I=>(c(I=new Date(I-1)),g(I,1),c(I),I),x.round=I=>{const K=x(I),ye=x.ceil(I);return I-K<ye-I?K:ye},x.offset=(I,K)=>(g(I=new Date(+I),null==K?1:Math.floor(K)),I),x.range=(I,K,ye)=>{const Ye=[];if(I=x.ceil(I),ye=null==ye?1:Math.floor(ye),!(I<K&&ye>0))return Ye;let $e;do{Ye.push($e=new Date(+I)),g(I,ye),c(I)}while($e<I&&I<K);return Ye},x.filter=I=>ps(K=>{if(K>=K)for(;c(K),!I(K);)K.setTime(K-1)},(K,ye)=>{if(K>=K)if(ye<0)for(;++ye<=0;)for(;g(K,-1),!I(K););else for(;--ye>=0;)for(;g(K,1),!I(K););}),a&&(x.count=(I,K)=>(sd.setTime(+I),Ss.setTime(+K),c(sd),c(Ss),Math.floor(a(sd,Ss))),x.every=I=>(I=Math.floor(I),isFinite(I)&&I>0?I>1?x.filter(u?K=>u(K)%I==0:K=>x.count(0,K)%I==0):x:null)),x}const eh=ps(()=>{},(c,g)=>{c.setTime(+c+g)},(c,g)=>g-c);eh.every=c=>(c=Math.floor(c),isFinite(c)&&c>0?c>1?ps(g=>{g.setTime(Math.floor(g/c)*c)},(g,a)=>{g.setTime(+g+a*c)},(g,a)=>(a-g)/c):eh:null);const Gl=ps(c=>{c.setTime(c-c.getMilliseconds())},(c,g)=>{c.setTime(+c+g*fc)},(c,g)=>(g-c)/fc,c=>c.getUTCSeconds()),Bd=ps(c=>{c.setTime(c-c.getMilliseconds()-c.getSeconds()*fc)},(c,g)=>{c.setTime(+c+g*Xl)},(c,g)=>(g-c)/Xl,c=>c.getMinutes()),V=ps(c=>{c.setUTCSeconds(0,0)},(c,g)=>{c.setTime(+c+g*Xl)},(c,g)=>(g-c)/Xl,c=>c.getUTCMinutes()),E=ps(c=>{c.setTime(c-c.getMilliseconds()-c.getSeconds()*fc-c.getMinutes()*Xl)},(c,g)=>{c.setTime(+c+g*nc)},(c,g)=>(g-c)/nc,c=>c.getHours()),ee=ps(c=>{c.setUTCMinutes(0,0,0)},(c,g)=>{c.setTime(+c+g*nc)},(c,g)=>(g-c)/nc,c=>c.getUTCHours()),Nt=ps(c=>c.setHours(0,0,0,0),(c,g)=>c.setDate(c.getDate()+g),(c,g)=>(g-c-(g.getTimezoneOffset()-c.getTimezoneOffset())*Xl)/ra,c=>c.getDate()-1),gr=ps(c=>{c.setUTCHours(0,0,0,0)},(c,g)=>{c.setUTCDate(c.getUTCDate()+g)},(c,g)=>(g-c)/ra,c=>c.getUTCDate()-1),vo=ps(c=>{c.setUTCHours(0,0,0,0)},(c,g)=>{c.setUTCDate(c.getUTCDate()+g)},(c,g)=>(g-c)/ra,c=>Math.floor(c/ra));function jo(c){return ps(g=>{g.setDate(g.getDate()-(g.getDay()+7-c)%7),g.setHours(0,0,0,0)},(g,a)=>{g.setDate(g.getDate()+7*a)},(g,a)=>(a-g-(a.getTimezoneOffset()-g.getTimezoneOffset())*Xl)/Rf)}const cs=jo(0),el=jo(1),Ga=(jo(2),jo(3),jo(4));function ef(c){return ps(g=>{g.setUTCDate(g.getUTCDate()-(g.getUTCDay()+7-c)%7),g.setUTCHours(0,0,0,0)},(g,a)=>{g.setUTCDate(g.getUTCDate()+7*a)},(g,a)=>(a-g)/Rf)}jo(5),jo(6);const x0=ef(0),z_=ef(1),Av=(ef(2),ef(3),ef(4)),Bt=(ef(5),ef(6),ps(c=>{c.setDate(1),c.setHours(0,0,0,0)},(c,g)=>{c.setMonth(c.getMonth()+g)},(c,g)=>g.getMonth()-c.getMonth()+12*(g.getFullYear()-c.getFullYear()),c=>c.getMonth())),ei=ps(c=>{c.setUTCDate(1),c.setUTCHours(0,0,0,0)},(c,g)=>{c.setUTCMonth(c.getUTCMonth()+g)},(c,g)=>g.getUTCMonth()-c.getUTCMonth()+12*(g.getUTCFullYear()-c.getUTCFullYear()),c=>c.getUTCMonth()),Vi=ps(c=>{c.setMonth(0,1),c.setHours(0,0,0,0)},(c,g)=>{c.setFullYear(c.getFullYear()+g)},(c,g)=>g.getFullYear()-c.getFullYear(),c=>c.getFullYear());Vi.every=c=>isFinite(c=Math.floor(c))&&c>0?ps(g=>{g.setFullYear(Math.floor(g.getFullYear()/c)*c),g.setMonth(0,1),g.setHours(0,0,0,0)},(g,a)=>{g.setFullYear(g.getFullYear()+a*c)}):null;const Wr=ps(c=>{c.setUTCMonth(0,1),c.setUTCHours(0,0,0,0)},(c,g)=>{c.setUTCFullYear(c.getUTCFullYear()+g)},(c,g)=>g.getUTCFullYear()-c.getUTCFullYear(),c=>c.getUTCFullYear());function Cl(c,g,a,u,x,I){const K=[[Gl,1,fc],[Gl,5,5e3],[Gl,15,15e3],[Gl,30,3e4],[I,1,Xl],[I,5,5*Xl],[I,15,15*Xl],[I,30,30*Xl],[x,1,nc],[x,3,3*nc],[x,6,6*nc],[x,12,12*nc],[u,1,ra],[u,2,2*ra],[a,1,Rf],[g,1,Ja],[g,3,3*Ja],[c,1,Jc]];function Ye($e,ht,Vt){const zt=Math.abs(ht-$e)/Vt,yn=Lm(([,,si])=>si).right(K,zt);if(yn===K.length)return c.every(Ps($e/Jc,ht/Jc,Vt));if(0===yn)return eh.every(Math.max(Ps($e,ht,Vt),1));const[li,pr]=K[zt/K[yn-1][2]<K[yn][2]/zt?yn-1:yn];return li.every(pr)}return[function ye($e,ht,Vt){const zt=ht<$e;zt&&([$e,ht]=[ht,$e]);const yn=Vt&&"function"==typeof Vt.range?Vt:Ye($e,ht,Vt),li=yn?yn.range($e,+ht+1):[];return zt?li.reverse():li},Ye]}Wr.every=c=>isFinite(c=Math.floor(c))&&c>0?ps(g=>{g.setUTCFullYear(Math.floor(g.getUTCFullYear()/c)*c),g.setUTCMonth(0,1),g.setUTCHours(0,0,0,0)},(g,a)=>{g.setUTCFullYear(g.getUTCFullYear()+a*c)}):null;const[pc,Yu]=Cl(Wr,ei,x0,vo,ee,V),[Yf,bd]=Cl(Vi,Bt,cs,Nt,E,Bd);function vu(c){if(0<=c.y&&c.y<100){var g=new Date(-1,c.m,c.d,c.H,c.M,c.S,c.L);return g.setFullYear(c.y),g}return new Date(c.y,c.m,c.d,c.H,c.M,c.S,c.L)}function rh(c){if(0<=c.y&&c.y<100){var g=new Date(Date.UTC(-1,c.m,c.d,c.H,c.M,c.S,c.L));return g.setUTCFullYear(c.y),g}return new Date(Date.UTC(c.y,c.m,c.d,c.H,c.M,c.S,c.L))}function Xf(c,g,a){return{y:c,m:g,d:a,H:0,M:0,S:0,L:0}}var Mg,DE,Ov={"-":"",_:" ",0:"0"},Tr=/^\s*\d+/,Vs=/^%/,lp=/[\\^$*+?|[\]().{}]/g;function ka(c,g,a){var u=c<0?"-":"",x=(u?-c:c)+"",I=x.length;return u+(I<a?new Array(a-I+1).join(g)+x:x)}function Lf(c){return c.replace(lp,"\\$&")}function tf(c){return new RegExp("^(?:"+c.map(Lf).join("|")+")","i")}function oh(c){return new Map(c.map((g,a)=>[g.toLowerCase(),a]))}function G_(c,g,a){var u=Tr.exec(g.slice(a,a+1));return u?(c.w=+u[0],a+u[0].length):-1}function S0(c,g,a){var u=Tr.exec(g.slice(a,a+1));return u?(c.u=+u[0],a+u[0].length):-1}function vf(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.U=+u[0],a+u[0].length):-1}function xg(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.V=+u[0],a+u[0].length):-1}function s1(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.W=+u[0],a+u[0].length):-1}function Bm(c,g,a){var u=Tr.exec(g.slice(a,a+4));return u?(c.y=+u[0],a+u[0].length):-1}function Ir(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.y=+u[0]+(+u[0]>68?1900:2e3),a+u[0].length):-1}function bs(c,g,a){var u=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(g.slice(a,a+6));return u?(c.Z=u[1]?0:-(u[2]+(u[3]||"00")),a+u[0].length):-1}function Ko(c,g,a){var u=Tr.exec(g.slice(a,a+1));return u?(c.q=3*u[0]-3,a+u[0].length):-1}function Es(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.m=u[0]-1,a+u[0].length):-1}function jc(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.d=+u[0],a+u[0].length):-1}function wc(c,g,a){var u=Tr.exec(g.slice(a,a+3));return u?(c.m=0,c.d=+u[0],a+u[0].length):-1}function Ho(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.H=+u[0],a+u[0].length):-1}function cp(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.M=+u[0],a+u[0].length):-1}function Mh(c,g,a){var u=Tr.exec(g.slice(a,a+2));return u?(c.S=+u[0],a+u[0].length):-1}function E0(c,g,a){var u=Tr.exec(g.slice(a,a+3));return u?(c.L=+u[0],a+u[0].length):-1}function sh(c,g,a){var u=Tr.exec(g.slice(a,a+6));return u?(c.L=Math.floor(u[0]/1e3),a+u[0].length):-1}function nD(c,g,a){var u=Vs.exec(g.slice(a,a+1));return u?a+u[0].length:-1}function iD(c,g,a){var u=Tr.exec(g.slice(a));return u?(c.Q=+u[0],a+u[0].length):-1}function T0(c,g,a){var u=Tr.exec(g.slice(a));return u?(c.s=+u[0],a+u[0].length):-1}function cx(c,g){return ka(c.getDate(),g,2)}function Sg(c,g){return ka(c.getHours(),g,2)}function rD(c,g){return ka(c.getHours()%12||12,g,2)}function ux(c,g){return ka(1+Nt.count(Vi(c),c),g,3)}function Ap(c,g){return ka(c.getMilliseconds(),g,3)}function _E(c,g){return Ap(c,g)+"000"}function M0(c,g){return ka(c.getMonth()+1,g,2)}function mr(c,g){return ka(c.getMinutes(),g,2)}function Ua(c,g){return ka(c.getSeconds(),g,2)}function Op(c){var g=c.getDay();return 0===g?7:g}function oD(c,g){return ka(cs.count(Vi(c)-1,c),g,2)}function Pl(c){var g=c.getDay();return g>=4||0===g?Ga(c):Ga.ceil(c)}function dx(c,g){return c=Pl(c),ka(Ga.count(Vi(c),c)+(4===Vi(c).getDay()),g,2)}function fa(c){return c.getDay()}function Ih(c,g){return ka(el.count(Vi(c)-1,c),g,2)}function sD(c,g){return ka(c.getFullYear()%100,g,2)}function aD(c,g){return ka((c=Pl(c)).getFullYear()%100,g,2)}function a1(c,g){return ka(c.getFullYear()%1e4,g,4)}function yE(c,g){var a=c.getDay();return ka((c=a>=4||0===a?Ga(c):Ga.ceil(c)).getFullYear()%1e4,g,4)}function xA(c){var g=c.getTimezoneOffset();return(g>0?"-":(g*=-1,"+"))+ka(g/60|0,"0",2)+ka(g%60,"0",2)}function I0(c,g){return ka(c.getUTCDate(),g,2)}function fx(c,g){return ka(c.getUTCHours(),g,2)}function bE(c,g){return ka(c.getUTCHours()%12||12,g,2)}function nf(c,g){return ka(1+gr.count(Wr(c),c),g,3)}function _f(c,g){return ka(c.getUTCMilliseconds(),g,3)}function lD(c,g){return _f(c,g)+"000"}function Fp(c,g){return ka(c.getUTCMonth()+1,g,2)}function Eg(c,g){return ka(c.getUTCMinutes(),g,2)}function cD(c,g){return ka(c.getUTCSeconds(),g,2)}function uD(c){var g=c.getUTCDay();return 0===g?7:g}function CE(c,g){return ka(x0.count(Wr(c)-1,c),g,2)}function px(c){var g=c.getUTCDay();return g>=4||0===g?Av(c):Av.ceil(c)}function Fv(c,g){return c=px(c),ka(Av.count(Wr(c),c)+(4===Wr(c).getUTCDay()),g,2)}function dD(c){return c.getUTCDay()}function Ah(c,g){return ka(z_.count(Wr(c)-1,c),g,2)}function K_(c,g){return ka(c.getUTCFullYear()%100,g,2)}function q_(c,g){return ka((c=px(c)).getUTCFullYear()%100,g,2)}function hx(c,g){return ka(c.getUTCFullYear()%1e4,g,4)}function Vm(c,g){var a=c.getUTCDay();return ka((c=a>=4||0===a?Av(c):Av.ceil(c)).getUTCFullYear()%1e4,g,4)}function l1(){return"+0000"}function fD(){return"%"}function mx(c){return+c}function Tg(c){return Math.floor(+c/1e3)}function Zf(c){return null===c?NaN:+c}!function A0(c){Mg=function Qa(c){var g=c.dateTime,a=c.date,u=c.time,x=c.periods,I=c.days,K=c.shortDays,ye=c.months,Ye=c.shortMonths,$e=tf(x),ht=oh(x),Vt=tf(I),zt=oh(I),yn=tf(K),li=oh(K),pr=tf(ye),si=oh(ye),hr=tf(Ye),_o=oh(Ye),jr={a:function Jr(Cr){return K[Cr.getDay()]},A:function No(Cr){return I[Cr.getDay()]},b:function Hr(Cr){return Ye[Cr.getMonth()]},B:function ys(Cr){return ye[Cr.getMonth()]},c:null,d:cx,e:cx,f:_E,g:aD,G:yE,H:Sg,I:rD,j:ux,L:Ap,m:M0,M:mr,p:function Ns(Cr){return x[+(Cr.getHours()>=12)]},q:function Ml(Cr){return 1+~~(Cr.getMonth()/3)},Q:mx,s:Tg,S:Ua,u:Op,U:oD,V:dx,w:fa,W:Ih,x:null,X:null,y:sD,Y:a1,Z:xA,"%":fD},ao={a:function Nu(Cr){return K[Cr.getUTCDay()]},A:function Rd(Cr){return I[Cr.getUTCDay()]},b:function ru(Cr){return Ye[Cr.getUTCMonth()]},B:function wd(Cr){return ye[Cr.getUTCMonth()]},c:null,d:I0,e:I0,f:lD,g:q_,G:Vm,H:fx,I:bE,j:nf,L:_f,m:Fp,M:Eg,p:function jl(Cr){return x[+(Cr.getUTCHours()>=12)]},q:function Os(Cr){return 1+~~(Cr.getUTCMonth()/3)},Q:mx,s:Tg,S:cD,u:uD,U:CE,V:Fv,w:dD,W:Ah,x:null,X:null,y:K_,Y:hx,Z:l1,"%":fD},lo={a:function Ca(Cr,So,Po){var wi=yn.exec(So.slice(Po));return wi?(Cr.w=li.get(wi[0].toLowerCase()),Po+wi[0].length):-1},A:function oo(Cr,So,Po){var wi=Vt.exec(So.slice(Po));return wi?(Cr.w=zt.get(wi[0].toLowerCase()),Po+wi[0].length):-1},b:function Ba(Cr,So,Po){var wi=hr.exec(So.slice(Po));return wi?(Cr.m=_o.get(wi[0].toLowerCase()),Po+wi[0].length):-1},B:function Co(Cr,So,Po){var wi=pr.exec(So.slice(Po));return wi?(Cr.m=si.get(wi[0].toLowerCase()),Po+wi[0].length):-1},c:function us(Cr,So,Po){return yo(Cr,g,So,Po)},d:jc,e:jc,f:sh,g:Ir,G:Bm,H:Ho,I:Ho,j:wc,L:E0,m:Es,M:cp,p:function ml(Cr,So,Po){var wi=$e.exec(So.slice(Po));return wi?(Cr.p=ht.get(wi[0].toLowerCase()),Po+wi[0].length):-1},q:Ko,Q:iD,s:T0,S:Mh,u:S0,U:vf,V:xg,w:G_,W:s1,x:function Rr(Cr,So,Po){return yo(Cr,a,So,Po)},X:function xo(Cr,So,Po){return yo(Cr,u,So,Po)},y:Ir,Y:Bm,Z:bs,"%":nD};function mo(Cr,So){return function(Po){var Fa,hs,Ka,wi=[],ha=-1,dn=0,Ol=Cr.length;for(Po instanceof Date||(Po=new Date(+Po));++ha<Ol;)37===Cr.charCodeAt(ha)&&(wi.push(Cr.slice(dn,ha)),null!=(hs=Ov[Fa=Cr.charAt(++ha)])?Fa=Cr.charAt(++ha):hs="e"===Fa?" ":"0",(Ka=So[Fa])&&(Fa=Ka(Po,hs)),wi.push(Fa),dn=ha+1);return wi.push(Cr.slice(dn,ha)),wi.join("")}}function br(Cr,So){return function(Po){var dn,Ol,wi=Xf(1900,void 0,1);if(yo(wi,Cr,Po+="",0)!=Po.length)return null;if("Q"in wi)return new Date(wi.Q);if("s"in wi)return new Date(1e3*wi.s+("L"in wi?wi.L:0));if(So&&!("Z"in wi)&&(wi.Z=0),"p"in wi&&(wi.H=wi.H%12+12*wi.p),void 0===wi.m&&(wi.m="q"in wi?wi.q:0),"V"in wi){if(wi.V<1||wi.V>53)return null;"w"in wi||(wi.w=1),"Z"in wi?(Ol=(dn=rh(Xf(wi.y,0,1))).getUTCDay(),dn=Ol>4||0===Ol?z_.ceil(dn):z_(dn),dn=gr.offset(dn,7*(wi.V-1)),wi.y=dn.getUTCFullYear(),wi.m=dn.getUTCMonth(),wi.d=dn.getUTCDate()+(wi.w+6)%7):(Ol=(dn=vu(Xf(wi.y,0,1))).getDay(),dn=Ol>4||0===Ol?el.ceil(dn):el(dn),dn=Nt.offset(dn,7*(wi.V-1)),wi.y=dn.getFullYear(),wi.m=dn.getMonth(),wi.d=dn.getDate()+(wi.w+6)%7)}else("W"in wi||"U"in wi)&&("w"in wi||(wi.w="u"in wi?wi.u%7:"W"in wi?1:0),Ol="Z"in wi?rh(Xf(wi.y,0,1)).getUTCDay():vu(Xf(wi.y,0,1)).getDay(),wi.m=0,wi.d="W"in wi?(wi.w+6)%7+7*wi.W-(Ol+5)%7:wi.w+7*wi.U-(Ol+6)%7);return"Z"in wi?(wi.H+=wi.Z/100|0,wi.M+=wi.Z%100,rh(wi)):vu(wi)}}function yo(Cr,So,Po,wi){for(var Fa,hs,ha=0,dn=So.length,Ol=Po.length;ha<dn;){if(wi>=Ol)return-1;if(37===(Fa=So.charCodeAt(ha++))){if(Fa=So.charAt(ha++),!(hs=lo[Fa in Ov?So.charAt(ha++):Fa])||(wi=hs(Cr,Po,wi))<0)return-1}else if(Fa!=Po.charCodeAt(wi++))return-1}return wi}return jr.x=mo(a,jr),jr.X=mo(u,jr),jr.c=mo(g,jr),ao.x=mo(a,ao),ao.X=mo(u,ao),ao.c=mo(g,ao),{format:function(Cr){var So=mo(Cr+="",jr);return So.toString=function(){return Cr},So},parse:function(Cr){var So=br(Cr+="",!1);return So.toString=function(){return Cr},So},utcFormat:function(Cr){var So=mo(Cr+="",ao);return So.toString=function(){return Cr},So},utcParse:function(Cr){var So=br(Cr+="",!0);return So.toString=function(){return Cr},So}}}(c),DE=Mg.format}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});const c1=Lm(yd).right,jm=(Lm(Zf),c1);function u1(c,g){return c=+c,g=+g,function(a){return Math.round(c*(1-a)+g*a)}}function Q_(c){return+c}var d1=[0,1];function Lv(c){return c}function Np(c,g){return(g-=c=+c)?function(a){return(a-c)/g}:function hD(c){return function(){return c}}(isNaN(g)?NaN:.5)}function wE(c,g,a){var u=c[0],x=c[1],I=g[0],K=g[1];return x<u?(u=Np(x,u),I=a(K,I)):(u=Np(u,x),I=a(I,K)),function(ye){return I(u(ye))}}function kv(c,g,a){var u=Math.min(c.length,g.length)-1,x=new Array(u),I=new Array(u),K=-1;for(c[u]<c[0]&&(c=c.slice().reverse(),g=g.slice().reverse());++K<u;)x[K]=Np(c[K],c[K+1]),I[K]=a(g[K],g[K+1]);return function(ye){var Ye=jm(c,ye,1,u)-1;return I[Ye](x[Ye](ye))}}function O0(c,g){return g.domain(c.domain()).range(c.range()).interpolate(c.interpolate()).clamp(c.clamp()).unknown(c.unknown())}function f1(){return function F0(){var u,x,I,ye,Ye,$e,c=d1,g=d1,a=qs,K=Lv;function ht(){var zt=Math.min(c.length,g.length);return K!==Lv&&(K=function Y_(c,g){var a;return c>g&&(a=c,c=g,g=a),function(u){return Math.max(c,Math.min(g,u))}}(c[0],c[zt-1])),ye=zt>2?kv:wE,Ye=$e=null,Vt}function Vt(zt){return null==zt||isNaN(zt=+zt)?I:(Ye||(Ye=ye(c.map(u),g,a)))(u(K(zt)))}return Vt.invert=function(zt){return K(x(($e||($e=ye(g,c.map(u),tc)))(zt)))},Vt.domain=function(zt){return arguments.length?(c=Array.from(zt,Q_),ht()):c.slice()},Vt.range=function(zt){return arguments.length?(g=Array.from(zt),ht()):g.slice()},Vt.rangeRound=function(zt){return g=Array.from(zt),a=u1,ht()},Vt.clamp=function(zt){return arguments.length?(K=!!zt||Lv,ht()):K!==Lv},Vt.interpolate=function(zt){return arguments.length?(a=zt,ht()):a},Vt.unknown=function(zt){return arguments.length?(I=zt,Vt):I},function(zt,yn){return u=zt,x=yn,ht()}}()(Lv,Lv)}function _u(c,g){switch(arguments.length){case 0:break;case 1:this.range(c);break;default:this.range(g).domain(c)}return this}function vx(c){return new Date(c)}function mD(c){return c instanceof Date?+c:+new Date(+c)}function gD(c,g,a,u,x,I,K,ye,Ye,$e){var ht=f1(),Vt=ht.invert,zt=ht.domain,yn=$e(".%L"),li=$e(":%S"),pr=$e("%I:%M"),si=$e("%I %p"),hr=$e("%a %d"),_o=$e("%b %d"),jr=$e("%B"),ao=$e("%Y");function lo(mo){return(Ye(mo)<mo?yn:ye(mo)<mo?li:K(mo)<mo?pr:I(mo)<mo?si:u(mo)<mo?x(mo)<mo?hr:_o:a(mo)<mo?jr:ao)(mo)}return ht.invert=function(mo){return new Date(Vt(mo))},ht.domain=function(mo){return arguments.length?zt(Array.from(mo,mD)):zt().map(vx)},ht.ticks=function(mo){var br=zt();return c(br[0],br[br.length-1],mo??10)},ht.tickFormat=function(mo,br){return null==br?lo:$e(br)},ht.nice=function(mo){var br=zt();return(!mo||"function"!=typeof mo.range)&&(mo=g(br[0],br[br.length-1],mo??10)),mo?zt(function DM(c,g){var K,a=0,u=(c=c.slice()).length-1,x=c[a],I=c[u];return I<x&&(K=a,a=u,u=K,K=x,x=I,I=K),c[a]=g.floor(x),c[u]=g.ceil(I),c}(br,mo)):ht},ht.copy=function(){return O0(ht,gD(c,g,a,u,x,I,K,ye,Ye,$e))},ht}function nm(){return _u.apply(gD(Yf,bd,Vi,Bt,cs,Nt,E,Bd,Gl,DE).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var yx,X_=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function $m(c){if(!(g=X_.exec(c)))throw new Error("invalid format: "+c);var g;return new im({fill:g[1],align:g[2],sign:g[3],symbol:g[4],zero:g[5],width:g[6],comma:g[7],precision:g[8]&&g[8].slice(1),trim:g[9],type:g[10]})}function im(c){this.fill=void 0===c.fill?" ":c.fill+"",this.align=void 0===c.align?">":c.align+"",this.sign=void 0===c.sign?"-":c.sign+"",this.symbol=void 0===c.symbol?"":c.symbol+"",this.zero=!!c.zero,this.width=void 0===c.width?void 0:+c.width,this.comma=!!c.comma,this.precision=void 0===c.precision?void 0:+c.precision,this.trim=!!c.trim,this.type=void 0===c.type?"":c.type+""}function Oh(c,g){if((a=(c=g?c.toExponential(g-1):c.toExponential()).indexOf("e"))<0)return null;var a,u=c.slice(0,a);return[u.length>1?u[0]+u.slice(2):u,+c.slice(a+1)]}function N0(c){return(c=Oh(Math.abs(c)))?c[1]:NaN}function Fh(c,g){var a=Oh(c,g);if(!a)return c+"";var u=a[0],x=a[1];return x<0?"0."+new Array(-x).join("0")+u:u.length>x+1?u.slice(0,x+1)+"."+u.slice(x+1):u+new Array(x-u.length+2).join("0")}$m.prototype=im.prototype,im.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const bx={"%":(c,g)=>(100*c).toFixed(g),b:c=>Math.round(c).toString(2),c:c=>c+"",d:function xE(c){return Math.abs(c=Math.round(c))>=1e21?c.toLocaleString("en").replace(/,/g,""):c.toString(10)},e:(c,g)=>c.toExponential(g),f:(c,g)=>c.toFixed(g),g:(c,g)=>c.toPrecision(g),o:c=>Math.round(c).toString(8),p:(c,g)=>Fh(100*c,g),r:Fh,s:function p1(c,g){var a=Oh(c,g);if(!a)return c+"";var u=a[0],x=a[1],I=x-(yx=3*Math.max(-8,Math.min(8,Math.floor(x/3))))+1,K=u.length;return I===K?u:I>K?u+new Array(I-K+1).join("0"):I>0?u.slice(0,I)+"."+u.slice(I):"0."+new Array(1-I).join("0")+Oh(c,Math.max(0,g+I-1))[0]},X:c=>Math.round(c).toString(16).toUpperCase(),x:c=>Math.round(c).toString(16)};function Pv(c){return c}var ah,L0,rm,Z_=Array.prototype.map,Ag=["y","z","a","f","p","n","\xb5","m","","k","M","G","T","P","E","Z","Y"];function Jf(c){var g=c.domain;return c.ticks=function(a){var u=g();return function Cc(c,g,a){if(!((a=+a)>0))return[];if((c=+c)==(g=+g))return[c];const u=g<c,[x,I,K]=u?Jp(g,c,a):Jp(c,g,a);if(!(I>=x))return[];const ye=I-x+1,Ye=new Array(ye);if(u)if(K<0)for(let $e=0;$e<ye;++$e)Ye[$e]=(I-$e)/-K;else for(let $e=0;$e<ye;++$e)Ye[$e]=(I-$e)*K;else if(K<0)for(let $e=0;$e<ye;++$e)Ye[$e]=(x+$e)/-K;else for(let $e=0;$e<ye;++$e)Ye[$e]=(x+$e)*K;return Ye}(u[0],u[u.length-1],a??10)},c.tickFormat=function(a,u){var x=g();return function Cx(c,g,a,u){var I,x=Ps(c,g,a);switch((u=$m(u??",f")).type){case"s":var K=Math.max(Math.abs(c),Math.abs(g));return null==u.precision&&!isNaN(I=function R0(c,g){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(N0(g)/3)))-N0(Math.abs(c)))}(x,K))&&(u.precision=I),rm(u,K);case"":case"e":case"g":case"p":case"r":null==u.precision&&!isNaN(I=function k0(c,g){return c=Math.abs(c),g=Math.abs(g)-c,Math.max(0,N0(g)-N0(c))+1}(x,Math.max(Math.abs(c),Math.abs(g))))&&(u.precision=I-("e"===u.type));break;case"f":case"%":null==u.precision&&!isNaN(I=function yD(c){return Math.max(0,-N0(Math.abs(c)))}(x))&&(u.precision=I-2*("%"===u.type))}return L0(u)}(x[0],x[x.length-1],a??10,u)},c.nice=function(a){null==a&&(a=10);var Ye,$e,u=g(),x=0,I=u.length-1,K=u[x],ye=u[I],ht=10;for(ye<K&&($e=K,K=ye,ye=$e,$e=x,x=I,I=$e);ht-- >0;){if(($e=io(K,ye,a))===Ye)return u[x]=K,u[I]=ye,g(u);if($e>0)K=Math.floor(K/$e)*$e,ye=Math.ceil(ye/$e)*$e;else{if(!($e<0))break;K=Math.ceil(K*$e)/$e,ye=Math.floor(ye*$e)/$e}Ye=$e}return c},c}function ic(){var c=f1();return c.copy=function(){return O0(c,ic())},_u.apply(c,arguments),Jf(c)}function Dx(c,g,a){c=+c,g=+g,a=(x=arguments.length)<2?(g=c,c=0,1):x<3?1:+a;for(var u=-1,x=0|Math.max(0,Math.ceil((g-c)/a)),I=new Array(x);++u<x;)I[u]=c+u*a;return I}!function om(c){ah=function Og(c){var g=void 0===c.grouping||void 0===c.thousands?Pv:function vD(c,g){return function(a,u){for(var x=a.length,I=[],K=0,ye=c[0],Ye=0;x>0&&ye>0&&(Ye+ye+1>u&&(ye=Math.max(1,u-Ye)),I.push(a.substring(x-=ye,x+ye)),!((Ye+=ye+1)>u));)ye=c[K=(K+1)%c.length];return I.reverse().join(g)}}(Z_.call(c.grouping,Number),c.thousands+""),a=void 0===c.currency?"":c.currency[0]+"",u=void 0===c.currency?"":c.currency[1]+"",x=void 0===c.decimal?".":c.decimal+"",I=void 0===c.numerals?Pv:function _D(c){return function(g){return g.replace(/[0-9]/g,function(a){return c[+a]})}}(Z_.call(c.numerals,String)),K=void 0===c.percent?"%":c.percent+"",ye=void 0===c.minus?"\u2212":c.minus+"",Ye=void 0===c.nan?"NaN":c.nan+"";function $e(Vt){var zt=(Vt=$m(Vt)).fill,yn=Vt.align,li=Vt.sign,pr=Vt.symbol,si=Vt.zero,hr=Vt.width,_o=Vt.comma,jr=Vt.precision,ao=Vt.trim,lo=Vt.type;"n"===lo?(_o=!0,lo="g"):bx[lo]||(void 0===jr&&(jr=12),ao=!0,lo="g"),(si||"0"===zt&&"="===yn)&&(si=!0,zt="0",yn="=");var mo="$"===pr?a:"#"===pr&&/[boxX]/.test(lo)?"0"+lo.toLowerCase():"",br="$"===pr?u:/[%p]/.test(lo)?K:"",yo=bx[lo],ml=/[defgprs%]/.test(lo);function Ca(oo){var us,Rr,xo,Ba=mo,Co=br;if("c"===lo)Co=yo(oo)+Co,oo="";else{var Jr=(oo=+oo)<0||1/oo<0;if(oo=isNaN(oo)?Ye:yo(Math.abs(oo),jr),ao&&(oo=function _x(c){e:for(var x,g=c.length,a=1,u=-1;a<g;++a)switch(c[a]){case".":u=x=a;break;case"0":0===u&&(u=a),x=a;break;default:if(!+c[a])break e;u>0&&(u=0)}return u>0?c.slice(0,u)+c.slice(x+1):c}(oo)),Jr&&0==+oo&&"+"!==li&&(Jr=!1),Ba=(Jr?"("===li?li:ye:"-"===li||"("===li?"":li)+Ba,Co=("s"===lo?Ag[8+yx/3]:"")+Co+(Jr&&"("===li?")":""),ml)for(us=-1,Rr=oo.length;++us<Rr;)if(48>(xo=oo.charCodeAt(us))||xo>57){Co=(46===xo?x+oo.slice(us+1):oo.slice(us))+Co,oo=oo.slice(0,us);break}}_o&&!si&&(oo=g(oo,1/0));var No=Ba.length+oo.length+Co.length,Hr=No<hr?new Array(hr-No+1).join(zt):"";switch(_o&&si&&(oo=g(Hr+oo,Hr.length?hr-Co.length:1/0),Hr=""),yn){case"<":oo=Ba+oo+Co+Hr;break;case"=":oo=Ba+Hr+oo+Co;break;case"^":oo=Hr.slice(0,No=Hr.length>>1)+Ba+oo+Co+Hr.slice(No);break;default:oo=Hr+Ba+oo+Co}return I(oo)}return jr=void 0===jr?6:/[gprs]/.test(lo)?Math.max(1,Math.min(21,jr)):Math.max(0,Math.min(20,jr)),Ca.toString=function(){return Vt+""},Ca}return{format:$e,formatPrefix:function ht(Vt,zt){var yn=$e(((Vt=$m(Vt)).type="f",Vt)),li=3*Math.max(-8,Math.min(8,Math.floor(N0(zt)/3))),pr=Math.pow(10,-li),si=Ag[8+li/3];return function(hr){return yn(pr*hr)+si}}}}(c),L0=ah.format,rm=ah.formatPrefix}({thousands:",",grouping:[3],currency:["$",""]});class wx extends Map{constructor(g,a=bD){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:a}}),null!=g)for(const[u,x]of g)this.set(u,x)}get(g){return super.get(Fg(this,g))}has(g){return super.has(Fg(this,g))}set(g,a){return super.set(function Vv({_intern:c,_key:g},a){const u=g(a);return c.has(u)?c.get(u):(c.set(u,a),a)}(this,g),a)}delete(g){return super.delete(function ad({_intern:c,_key:g},a){const u=g(a);return c.has(u)&&(a=c.get(u),c.delete(u)),a}(this,g))}}function Fg({_intern:c,_key:g},a){const u=g(a);return c.has(u)?c.get(u):a}function bD(c){return null!==c&&"object"==typeof c?c.valueOf():c}Set;const xx=Symbol("implicit");function Ng(){var c=new wx,g=[],a=[],u=xx;function x(I){let K=c.get(I);if(void 0===K){if(u!==xx)return u;c.set(I,K=g.push(I)-1)}return a[K%a.length]}return x.domain=function(I){if(!arguments.length)return g.slice();g=[],c=new wx;for(const K of I)c.has(K)||c.set(K,g.push(K)-1);return x},x.range=function(I){return arguments.length?(a=Array.from(I),x):a.slice()},x.unknown=function(I){return arguments.length?(u=I,x):u},x.copy=function(){return Ng(g,a).unknown(u)},_u.apply(x,arguments),x}function Id(){var I,K,c=Ng().unknown(void 0),g=c.domain,a=c.range,u=0,x=1,ye=!1,Ye=0,$e=0,ht=.5;function Vt(){var zt=g().length,yn=x<u,li=yn?x:u,pr=yn?u:x;I=(pr-li)/Math.max(1,zt-Ye+2*$e),ye&&(I=Math.floor(I)),li+=(pr-li-I*(zt-Ye))*ht,K=I*(1-Ye),ye&&(li=Math.round(li),K=Math.round(K));var si=Dx(zt).map(function(hr){return li+I*hr});return a(yn?si.reverse():si)}return delete c.unknown,c.domain=function(zt){return arguments.length?(g(zt),Vt()):g()},c.range=function(zt){return arguments.length?([u,x]=zt,u=+u,x=+x,Vt()):[u,x]},c.rangeRound=function(zt){return[u,x]=zt,u=+u,x=+x,ye=!0,Vt()},c.bandwidth=function(){return K},c.step=function(){return I},c.round=function(zt){return arguments.length?(ye=!!zt,Vt()):ye},c.padding=function(zt){return arguments.length?(Ye=Math.min(1,$e=+zt),Vt()):Ye},c.paddingInner=function(zt){return arguments.length?(Ye=Math.min(1,zt),Vt()):Ye},c.paddingOuter=function(zt){return arguments.length?($e=+zt,Vt()):$e},c.align=function(zt){return arguments.length?(ht=Math.max(0,Math.min(1,zt)),Vt()):ht},c.copy=function(){return Id(g(),[u,x]).round(ye).paddingInner(Ye).paddingOuter($e).align(ht)},_u.apply(Vt(),arguments)}function J_(c){var g=c.copy;return c.padding=c.paddingOuter,delete c.paddingInner,delete c.paddingOuter,c.copy=function(){return J_(g())},c}function up(){return J_(Id.apply(null,arguments).paddingInner(1))}function ey(c,g){let a;if(void 0===g)for(const u of c)null!=u&&(a<u||void 0===a&&u>=u)&&(a=u);else{let u=-1;for(let x of c)null!=(x=g(x,++u,c))&&(a<x||void 0===a&&x>=x)&&(a=x)}return a}function h1(c,g){let a;if(void 0===g)for(const u of c)null!=u&&(a>u||void 0===a&&u>=u)&&(a=u);else{let u=-1;for(let x of c)null!=(x=g(x,++u,c))&&(a>x||void 0===a&&x>=x)&&(a=x)}return a}function kf(c,g){return(null==c||!(c>=c))-(null==g||!(g>=g))||(c<g?-1:c>g?1:0)}function Ex(c,g,a=0,u=1/0,x){if(g=Math.floor(g),a=Math.floor(Math.max(0,a)),u=Math.floor(Math.min(c.length-1,u)),!(a<=g&&g<=u))return c;for(x=void 0===x?kf:function P0(c=yd){if(c===yd)return kf;if("function"!=typeof c)throw new TypeError("compare is not a function");return(g,a)=>{const u=c(g,a);return u||0===u?u:(0===c(a,a))-(0===c(g,g))}}(x);u>a;){if(u-a>600){const Ye=u-a+1,$e=g-a+1,ht=Math.log(Ye),Vt=.5*Math.exp(2*ht/3),zt=.5*Math.sqrt(ht*Vt*(Ye-Vt)/Ye)*($e-Ye/2<0?-1:1);Ex(c,g,Math.max(a,Math.floor(g-$e*Vt/Ye+zt)),Math.min(u,Math.floor(g+(Ye-$e)*Vt/Ye+zt)),x)}const I=c[g];let K=a,ye=u;for(jv(c,a,g),x(c[u],I)>0&&jv(c,a,u);K<ye;){for(jv(c,K,ye),++K,--ye;x(c[K],I)<0;)++K;for(;x(c[ye],I)>0;)--ye}0===x(c[a],I)?jv(c,a,ye):(++ye,jv(c,ye,u)),ye<=g&&(a=ye+1),g<=ye&&(u=ye-1)}return c}function jv(c,g,a){const u=c[g];c[g]=c[a],c[a]=u}function B0(c,g,a){if(c=Float64Array.from(function*pD(c,g){if(void 0===g)for(let a of c)null!=a&&(a=+a)>=a&&(yield a);else{let a=-1;for(let u of c)null!=(u=g(u,++a,c))&&(u=+u)>=u&&(yield u)}}(c,a)),(u=c.length)&&!isNaN(g=+g)){if(g<=0||u<2)return h1(c);if(g>=1)return ey(c);var u,x=(u-1)*g,I=Math.floor(x),K=ey(Ex(c,I).subarray(0,I+1));return K+(h1(c.subarray(I+1))-K)*(x-I)}}function Tx(c,g,a=Zf){if((u=c.length)&&!isNaN(g=+g)){if(g<=0||u<2)return+a(c[0],0,c);if(g>=1)return+a(c[u-1],u-1,c);var u,x=(u-1)*g,I=Math.floor(x),K=+a(c[I],I,c);return K+(+a(c[I+1],I+1,c)-K)*(x-I)}}function ty(){var u,c=[],g=[],a=[];function x(){var K=0,ye=Math.max(1,g.length);for(a=new Array(ye-1);++K<ye;)a[K-1]=Tx(c,K/ye);return I}function I(K){return null==K||isNaN(K=+K)?u:g[jm(a,K)]}return I.invertExtent=function(K){var ye=g.indexOf(K);return ye<0?[NaN,NaN]:[ye>0?a[ye-1]:c[0],ye<a.length?a[ye]:c[c.length-1]]},I.domain=function(K){if(!arguments.length)return c.slice();c=[];for(let ye of K)null!=ye&&!isNaN(ye=+ye)&&c.push(ye);return c.sort(yd),x()},I.range=function(K){return arguments.length?(g=Array.from(K),x()):g.slice()},I.unknown=function(K){return arguments.length?(u=K,I):u},I.quantiles=function(){return a.slice()},I.copy=function(){return ty().domain(c).range(g).unknown(u)},_u.apply(I,arguments)}function dp(c){return"object"==typeof c&&"length"in c?c:Array.from(c)}function hl(c){return function(){return c}}function lh(c){this._context=c}function Nh(c){return new lh(c)}lh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(c,g){switch(c=+c,g=+g,this._point){case 0:this._point=1,this._line?this._context.lineTo(c,g):this._context.moveTo(c,g);break;case 1:this._point=2;default:this._context.lineTo(c,g)}}};const Ou=Math.PI,CD=2*Ou,Rg=1e-6,m1=CD-Rg;function DD(c){this._+=c[0];for(let g=1,a=c.length;g<a;++g)this._+=arguments[g]+c[g]}class Lg{constructor(g){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==g?DD:function wD(c){let g=Math.floor(c);if(!(g>=0))throw new Error(`invalid digits: ${c}`);if(g>15)return DD;const a=10**g;return function(u){this._+=u[0];for(let x=1,I=u.length;x<I;++x)this._+=Math.round(arguments[x]*a)/a+u[x]}}(g)}moveTo(g,a){this._append`M${this._x0=this._x1=+g},${this._y0=this._y1=+a}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(g,a){this._append`L${this._x1=+g},${this._y1=+a}`}quadraticCurveTo(g,a,u,x){this._append`Q${+g},${+a},${this._x1=+u},${this._y1=+x}`}bezierCurveTo(g,a,u,x,I,K){this._append`C${+g},${+a},${+u},${+x},${this._x1=+I},${this._y1=+K}`}arcTo(g,a,u,x,I){if(g=+g,a=+a,u=+u,x=+x,(I=+I)<0)throw new Error(`negative radius: ${I}`);let K=this._x1,ye=this._y1,Ye=u-g,$e=x-a,ht=K-g,Vt=ye-a,zt=ht*ht+Vt*Vt;if(null===this._x1)this._append`M${this._x1=g},${this._y1=a}`;else if(zt>Rg)if(Math.abs(Vt*Ye-$e*ht)>Rg&&I){let yn=u-K,li=x-ye,pr=Ye*Ye+$e*$e,si=yn*yn+li*li,hr=Math.sqrt(pr),_o=Math.sqrt(zt),jr=I*Math.tan((Ou-Math.acos((pr+zt-si)/(2*hr*_o)))/2),ao=jr/_o,lo=jr/hr;Math.abs(ao-1)>Rg&&this._append`L${g+ao*ht},${a+ao*Vt}`,this._append`A${I},${I},0,0,${+(Vt*yn>ht*li)},${this._x1=g+lo*Ye},${this._y1=a+lo*$e}`}else this._append`L${this._x1=g},${this._y1=a}`}arc(g,a,u,x,I,K){if(g=+g,a=+a,K=!!K,(u=+u)<0)throw new Error(`negative radius: ${u}`);let ye=u*Math.cos(x),Ye=u*Math.sin(x),$e=g+ye,ht=a+Ye,Vt=1^K,zt=K?x-I:I-x;null===this._x1?this._append`M${$e},${ht}`:(Math.abs(this._x1-$e)>Rg||Math.abs(this._y1-ht)>Rg)&&this._append`L${$e},${ht}`,u&&(zt<0&&(zt=zt%CD+CD),zt>m1?this._append`A${u},${u},0,1,${Vt},${g-ye},${a-Ye}A${u},${u},0,1,${Vt},${this._x1=$e},${this._y1=ht}`:zt>Rg&&this._append`A${u},${u},0,${+(zt>=Ou)},${Vt},${this._x1=g+u*Math.cos(I)},${this._y1=a+u*Math.sin(I)}`)}rect(g,a,u,x){this._append`M${this._x0=this._x1=+g},${this._y0=this._y1=+a}h${u=+u}v${+x}h${-u}Z`}toString(){return this._}}function iy(c){let g=3;return c.digits=function(a){if(!arguments.length)return g;if(null==a)g=null;else{const u=Math.floor(a);if(!(u>=0))throw new RangeError(`invalid digits: ${a}`);g=u}return c},()=>new Lg(g)}function g1(c){return c[0]}function sm(c){return c[1]}function Wm(c,g){var a=hl(!0),u=null,x=Nh,I=null,K=iy(ye);function ye(Ye){var $e,Vt,yn,ht=(Ye=dp(Ye)).length,zt=!1;for(null==u&&(I=x(yn=K())),$e=0;$e<=ht;++$e)!($e<ht&&a(Vt=Ye[$e],$e,Ye))===zt&&((zt=!zt)?I.lineStart():I.lineEnd()),zt&&I.point(+c(Vt,$e,Ye),+g(Vt,$e,Ye));if(yn)return I=null,yn+""||null}return c="function"==typeof c?c:void 0===c?g1:hl(c),g="function"==typeof g?g:void 0===g?sm:hl(g),ye.x=function(Ye){return arguments.length?(c="function"==typeof Ye?Ye:hl(+Ye),ye):c},ye.y=function(Ye){return arguments.length?(g="function"==typeof Ye?Ye:hl(+Ye),ye):g},ye.defined=function(Ye){return arguments.length?(a="function"==typeof Ye?Ye:hl(!!Ye),ye):a},ye.curve=function(Ye){return arguments.length?(x=Ye,null!=u&&(I=x(u)),ye):x},ye.context=function(Ye){return arguments.length?(null==Ye?u=I=null:I=x(u=Ye),ye):u},ye}function Uv(c,g,a){var u=null,x=hl(!0),I=null,K=Nh,ye=null,Ye=iy($e);function $e(Vt){var zt,yn,li,si,_o,pr=(Vt=dp(Vt)).length,hr=!1,jr=new Array(pr),ao=new Array(pr);for(null==I&&(ye=K(_o=Ye())),zt=0;zt<=pr;++zt){if(!(zt<pr&&x(si=Vt[zt],zt,Vt))===hr)if(hr=!hr)yn=zt,ye.areaStart(),ye.lineStart();else{for(ye.lineEnd(),ye.lineStart(),li=zt-1;li>=yn;--li)ye.point(jr[li],ao[li]);ye.lineEnd(),ye.areaEnd()}hr&&(jr[zt]=+c(si,zt,Vt),ao[zt]=+g(si,zt,Vt),ye.point(u?+u(si,zt,Vt):jr[zt],a?+a(si,zt,Vt):ao[zt]))}if(_o)return ye=null,_o+""||null}function ht(){return Wm().defined(x).curve(K).context(I)}return c="function"==typeof c?c:void 0===c?g1:hl(+c),g="function"==typeof g?g:hl(void 0===g?0:+g),a="function"==typeof a?a:void 0===a?sm:hl(+a),$e.x=function(Vt){return arguments.length?(c="function"==typeof Vt?Vt:hl(+Vt),u=null,$e):c},$e.x0=function(Vt){return arguments.length?(c="function"==typeof Vt?Vt:hl(+Vt),$e):c},$e.x1=function(Vt){return arguments.length?(u=null==Vt?null:"function"==typeof Vt?Vt:hl(+Vt),$e):u},$e.y=function(Vt){return arguments.length?(g="function"==typeof Vt?Vt:hl(+Vt),a=null,$e):g},$e.y0=function(Vt){return arguments.length?(g="function"==typeof Vt?Vt:hl(+Vt),$e):g},$e.y1=function(Vt){return arguments.length?(a=null==Vt?null:"function"==typeof Vt?Vt:hl(+Vt),$e):a},$e.lineX0=$e.lineY0=function(){return ht().x(c).y(g)},$e.lineY1=function(){return ht().x(c).y(a)},$e.lineX1=function(){return ht().x(u).y(g)},$e.defined=function(Vt){return arguments.length?(x="function"==typeof Vt?Vt:hl(!!Vt),$e):x},$e.curve=function(Vt){return arguments.length?(K=Vt,null!=I&&(ye=K(I)),$e):K},$e.context=function(Vt){return arguments.length?(null==Vt?I=ye=null:ye=K(I=Vt),$e):I},$e}const Rp=Math.abs,Ad=Math.atan2,ry=Math.cos,xD=Math.max,j0=Math.min,Rh=Math.sin,Lp=Math.sqrt,yf=1e-12,Uc=Math.PI,am=Uc/2,oy=2*Uc;function v1(c){return c>=1?am:c<=-1?-am:Math.asin(c)}function _1(c){return c.innerRadius}function Mx(c){return c.outerRadius}function Ix(c){return c.startAngle}function $v(c){return c.endAngle}function Ax(c){return c&&c.padAngle}function U0(c,g,a,u,x,I,K){var ye=c-a,Ye=g-u,$e=(K?I:-I)/Lp(ye*ye+Ye*Ye),ht=$e*Ye,Vt=-$e*ye,zt=c+ht,yn=g+Vt,li=a+ht,pr=u+Vt,si=(zt+li)/2,hr=(yn+pr)/2,_o=li-zt,jr=pr-yn,ao=_o*_o+jr*jr,lo=x-I,mo=zt*pr-li*yn,br=(jr<0?-1:1)*Lp(xD(0,lo*lo*ao-mo*mo)),yo=(mo*jr-_o*br)/ao,ml=(-mo*_o-jr*br)/ao,Ca=(mo*jr+_o*br)/ao,oo=(-mo*_o+jr*br)/ao,Ba=yo-si,Co=ml-hr,us=Ca-si,Rr=oo-hr;return Ba*Ba+Co*Co>us*us+Rr*Rr&&(yo=Ca,ml=oo),{cx:yo,cy:ml,x01:-ht,y01:-Vt,x11:yo*(x/lo-1),y11:ml*(x/lo-1)}}function y1(){var c=_1,g=Mx,a=hl(0),u=null,x=Ix,I=$v,K=Ax,ye=null,Ye=iy($e);function $e(){var ht,Vt,zt=+c.apply(this,arguments),yn=+g.apply(this,arguments),li=x.apply(this,arguments)-am,pr=I.apply(this,arguments)-am,si=Rp(pr-li),hr=pr>li;if(ye||(ye=ht=Ye()),yn<zt&&(Vt=yn,yn=zt,zt=Vt),yn>yf)if(si>oy-yf)ye.moveTo(yn*ry(li),yn*Rh(li)),ye.arc(0,0,yn,li,pr,!hr),zt>yf&&(ye.moveTo(zt*ry(pr),zt*Rh(pr)),ye.arc(0,0,zt,pr,li,hr));else{var Co,us,_o=li,jr=pr,ao=li,lo=pr,mo=si,br=si,yo=K.apply(this,arguments)/2,ml=yo>yf&&(u?+u.apply(this,arguments):Lp(zt*zt+yn*yn)),Ca=j0(Rp(yn-zt)/2,+a.apply(this,arguments)),oo=Ca,Ba=Ca;if(ml>yf){var Rr=v1(ml/zt*Rh(yo)),xo=v1(ml/yn*Rh(yo));(mo-=2*Rr)>yf?(ao+=Rr*=hr?1:-1,lo-=Rr):(mo=0,ao=lo=(li+pr)/2),(br-=2*xo)>yf?(_o+=xo*=hr?1:-1,jr-=xo):(br=0,_o=jr=(li+pr)/2)}var Jr=yn*ry(_o),No=yn*Rh(_o),Hr=zt*ry(lo),ys=zt*Rh(lo);if(Ca>yf){var ru,Ns=yn*ry(jr),Ml=yn*Rh(jr),Nu=zt*ry(ao),Rd=zt*Rh(ao);if(si<Uc)if(ru=function Ox(c,g,a,u,x,I,K,ye){var Ye=a-c,$e=u-g,ht=K-x,Vt=ye-I,zt=Vt*Ye-ht*$e;if(!(zt*zt<yf))return[c+(zt=(ht*(g-I)-Vt*(c-x))/zt)*Ye,g+zt*$e]}(Jr,No,Nu,Rd,Ns,Ml,Hr,ys)){var wd=Jr-ru[0],jl=No-ru[1],Os=Ns-ru[0],Cr=Ml-ru[1],So=1/Rh(function SE(c){return c>1?0:c<-1?Uc:Math.acos(c)}((wd*Os+jl*Cr)/(Lp(wd*wd+jl*jl)*Lp(Os*Os+Cr*Cr)))/2),Po=Lp(ru[0]*ru[0]+ru[1]*ru[1]);oo=j0(Ca,(zt-Po)/(So-1)),Ba=j0(Ca,(yn-Po)/(So+1))}else oo=Ba=0}br>yf?Ba>yf?(Co=U0(Nu,Rd,Jr,No,yn,Ba,hr),us=U0(Ns,Ml,Hr,ys,yn,Ba,hr),ye.moveTo(Co.cx+Co.x01,Co.cy+Co.y01),Ba<Ca?ye.arc(Co.cx,Co.cy,Ba,Ad(Co.y01,Co.x01),Ad(us.y01,us.x01),!hr):(ye.arc(Co.cx,Co.cy,Ba,Ad(Co.y01,Co.x01),Ad(Co.y11,Co.x11),!hr),ye.arc(0,0,yn,Ad(Co.cy+Co.y11,Co.cx+Co.x11),Ad(us.cy+us.y11,us.cx+us.x11),!hr),ye.arc(us.cx,us.cy,Ba,Ad(us.y11,us.x11),Ad(us.y01,us.x01),!hr))):(ye.moveTo(Jr,No),ye.arc(0,0,yn,_o,jr,!hr)):ye.moveTo(Jr,No),zt>yf&&mo>yf?oo>yf?(Co=U0(Hr,ys,Ns,Ml,zt,-oo,hr),us=U0(Jr,No,Nu,Rd,zt,-oo,hr),ye.lineTo(Co.cx+Co.x01,Co.cy+Co.y01),oo<Ca?ye.arc(Co.cx,Co.cy,oo,Ad(Co.y01,Co.x01),Ad(us.y01,us.x01),!hr):(ye.arc(Co.cx,Co.cy,oo,Ad(Co.y01,Co.x01),Ad(Co.y11,Co.x11),!hr),ye.arc(0,0,zt,Ad(Co.cy+Co.y11,Co.cx+Co.x11),Ad(us.cy+us.y11,us.cx+us.x11),hr),ye.arc(us.cx,us.cy,oo,Ad(us.y11,us.x11),Ad(us.y01,us.x01),!hr))):ye.arc(0,0,zt,lo,ao,hr):ye.lineTo(Hr,ys)}else ye.moveTo(0,0);if(ye.closePath(),ht)return ye=null,ht+""||null}return $e.centroid=function(){var ht=(+c.apply(this,arguments)+ +g.apply(this,arguments))/2,Vt=(+x.apply(this,arguments)+ +I.apply(this,arguments))/2-Uc/2;return[ry(Vt)*ht,Rh(Vt)*ht]},$e.innerRadius=function(ht){return arguments.length?(c="function"==typeof ht?ht:hl(+ht),$e):c},$e.outerRadius=function(ht){return arguments.length?(g="function"==typeof ht?ht:hl(+ht),$e):g},$e.cornerRadius=function(ht){return arguments.length?(a="function"==typeof ht?ht:hl(+ht),$e):a},$e.padRadius=function(ht){return arguments.length?(u=null==ht?null:"function"==typeof ht?ht:hl(+ht),$e):u},$e.startAngle=function(ht){return arguments.length?(x="function"==typeof ht?ht:hl(+ht),$e):x},$e.endAngle=function(ht){return arguments.length?(I="function"==typeof ht?ht:hl(+ht),$e):I},$e.padAngle=function(ht){return arguments.length?(K="function"==typeof ht?ht:hl(+ht),$e):K},$e.context=function(ht){return arguments.length?(ye=ht??null,$e):ye},$e}var Lh=b1(Nh);function EE(c){this._curve=c}function b1(c){function g(a){return new EE(c(a))}return g._curve=c,g}function C1(){}function Fx(c,g,a){c._context.bezierCurveTo(c._x1+c._k*(c._x2-c._x0),c._y1+c._k*(c._y2-c._y0),c._x2+c._k*(c._x1-g),c._y2+c._k*(c._y1-a),c._x2,c._y2)}function $0(c,g){this._context=c,this._k=(1-g)/6}function Hv(c,g){this._context=c,this._k=(1-g)/6}EE.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(c,g){this._curve.point(g*Math.sin(c),g*-Math.cos(c))}},$0.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Fx(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(c,g){switch(c=+c,g=+g,this._point){case 0:this._point=1,this._line?this._context.lineTo(c,g):this._context.moveTo(c,g);break;case 1:this._point=2,this._x1=c,this._y1=g;break;case 2:this._point=3;default:Fx(this,c,g)}this._x0=this._x1,this._x1=this._x2,this._x2=c,this._y0=this._y1,this._y1=this._y2,this._y2=g}},function c(g){function a(u){return new $0(u,g)}return a.tension=function(u){return c(+u)},a}(0),Hv.prototype={areaStart:C1,areaEnd:C1,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(c,g){switch(c=+c,g=+g,this._point){case 0:this._point=1,this._x3=c,this._y3=g;break;case 1:this._point=2,this._context.moveTo(this._x4=c,this._y4=g);break;case 2:this._point=3,this._x5=c,this._y5=g;break;default:Fx(this,c,g)}this._x0=this._x1,this._x1=this._x2,this._x2=c,this._y0=this._y1,this._y1=this._y2,this._y2=g}};const Hm=function c(g){function a(u){return new Hv(u,g)}return a.tension=function(u){return c(+u)},a}(0);function Nx(c,g){return g<c?-1:g>c?1:g>=c?0:NaN}function ME(c){return c}function lm(){var c=ME,g=Nx,a=null,u=hl(0),x=hl(oy),I=hl(0);function K(ye){var Ye,ht,Vt,hr,ao,$e=(ye=dp(ye)).length,zt=0,yn=new Array($e),li=new Array($e),pr=+u.apply(this,arguments),si=Math.min(oy,Math.max(-oy,x.apply(this,arguments)-pr)),_o=Math.min(Math.abs(si)/$e,I.apply(this,arguments)),jr=_o*(si<0?-1:1);for(Ye=0;Ye<$e;++Ye)(ao=li[yn[Ye]=Ye]=+c(ye[Ye],Ye,ye))>0&&(zt+=ao);for(null!=g?yn.sort(function(lo,mo){return g(li[lo],li[mo])}):null!=a&&yn.sort(function(lo,mo){return a(ye[lo],ye[mo])}),Ye=0,Vt=zt?(si-$e*jr)/zt:0;Ye<$e;++Ye,pr=hr)li[ht=yn[Ye]]={data:ye[ht],index:Ye,value:ao=li[ht],startAngle:pr,endAngle:hr=pr+(ao>0?ao*Vt:0)+jr,padAngle:_o};return li}return K.value=function(ye){return arguments.length?(c="function"==typeof ye?ye:hl(+ye),K):c},K.sortValues=function(ye){return arguments.length?(g=ye,a=null,K):g},K.sort=function(ye){return arguments.length?(a=ye,g=null,K):a},K.startAngle=function(ye){return arguments.length?(u="function"==typeof ye?ye:hl(+ye),K):u},K.endAngle=function(ye){return arguments.length?(x="function"==typeof ye?ye:hl(+ye),K):x},K.padAngle=function(ye){return arguments.length?(I="function"==typeof ye?ye:hl(+ye),K):I},K}var W0=Math.PI;function z0(c){return(1-Math.cos(W0*c))/2}var kg=S(6021);function Lx(c){c.x0=Math.round(c.x0),c.y0=Math.round(c.y0),c.x1=Math.round(c.x1),c.y1=Math.round(c.y1)}function kx(c,g,a,u,x){for(var K,I=c.children,ye=-1,Ye=I.length,$e=c.value&&(u-g)/c.value;++ye<Ye;)(K=I[ye]).y0=a,K.y1=x,K.x0=g,K.x1=g+=K.value*$e}function TD(c,g,a,u,x){for(var K,I=c.children,ye=-1,Ye=I.length,$e=c.value&&(x-a)/c.value;++ye<Ye;)(K=I[ye]).x0=g,K.x1=u,K.y0=a,K.y1=a+=K.value*$e}const G0=function c(g){function a(u,x,I,K,ye){!function xM(c,g,a,u,x,I){for(var Ye,$e,yn,li,si,hr,_o,jr,ao,lo,mo,K=[],ye=g.children,ht=0,Vt=0,zt=ye.length,pr=g.value;ht<zt;){yn=x-a,li=I-u;do{si=ye[Vt++].value}while(!si&&Vt<zt);for(hr=_o=si,mo=si*si*(lo=Math.max(li/yn,yn/li)/(pr*c)),ao=Math.max(_o/mo,mo/hr);Vt<zt;++Vt){if(si+=$e=ye[Vt].value,$e<hr&&(hr=$e),$e>_o&&(_o=$e),mo=si*si*lo,(jr=Math.max(_o/mo,mo/hr))>ao){si-=$e;break}ao=jr}K.push(Ye={value:si,dice:yn<li,children:ye.slice(ht,Vt)}),Ye.dice?kx(Ye,a,u,x,pr?u+=li*si/pr:I):TD(Ye,a,u,pr?a+=yn*si/pr:x,I),pr-=si,ht=Vt}}(g,u,x,I,K,ye)}return a.ratio=function(u){return c((u=+u)>1?u:1)},a}((1+Math.sqrt(5))/2);function K0(c){return null==c?null:ID(c)}function ID(c){if("function"!=typeof c)throw new Error;return c}function Cd(){return 0}function cm(c){return function(){return c}}function zv(c){var g=0,a=c.children,u=a&&a.length;if(u)for(;--u>=0;)g+=a[u].value;else g=1;c.value=g}function Vx(c,g){c instanceof Map?(c=[void 0,c],void 0===g&&(g=x1)):void 0===g&&(g=sy);for(var u,I,K,ye,Ye,a=new Pg(c),x=[a];u=x.pop();)if((K=g(u.data))&&(Ye=(K=Array.from(K)).length))for(u.children=K,ye=Ye-1;ye>=0;--ye)x.push(I=K[ye]=new Pg(K[ye])),I.parent=u,I.depth=u.depth+1;return a.eachBefore(qv)}function sy(c){return c.children}function x1(c){return Array.isArray(c)?c[1]:null}function q0(c){void 0!==c.data.value&&(c.value=c.data.value),c.data=c.data.data}function qv(c){var g=0;do{c.height=g}while((c=c.parent)&&c.height<++g)}function Pg(c){this.data=c,this.depth=this.height=0,this.parent=null}Pg.prototype=Vx.prototype={constructor:Pg,count:function SM(){return this.eachAfter(zv)},each:function AD(c,g){let a=-1;for(const u of this)c.call(g,u,++a,this);return this},eachAfter:function Gv(c,g){for(var I,K,ye,a=this,u=[a],x=[],Ye=-1;a=u.pop();)if(x.push(a),I=a.children)for(K=0,ye=I.length;K<ye;++K)u.push(I[K]);for(;a=x.pop();)c.call(g,a,++Ye,this);return this},eachBefore:function rf(c,g){for(var x,I,a=this,u=[a],K=-1;a=u.pop();)if(c.call(g,a,++K,this),x=a.children)for(I=x.length-1;I>=0;--I)u.push(x[I]);return this},find:function AE(c,g){let a=-1;for(const u of this)if(c.call(g,u,++a,this))return u},sum:function D1(c){return this.eachAfter(function(g){for(var a=+c(g.data)||0,u=g.children,x=u&&u.length;--x>=0;)a+=u[x].value;g.value=a})},sort:function Px(c){return this.eachBefore(function(g){g.children&&g.children.sort(c)})},path:function OE(c){for(var g=this,a=function w1(c,g){if(c===g)return c;var a=c.ancestors(),u=g.ancestors(),x=null;for(c=a.pop(),g=u.pop();c===g;)x=c,c=a.pop(),g=u.pop();return x}(g,c),u=[g];g!==a;)u.push(g=g.parent);for(var x=u.length;c!==a;)u.splice(x,0,c),c=c.parent;return u},ancestors:function Bx(){for(var c=this,g=[c];c=c.parent;)g.push(c);return g},descendants:function EM(){return Array.from(this)},leaves:function Kv(){var c=[];return this.eachBefore(function(g){g.children||c.push(g)}),c},links:function OD(){var c=this,g=[];return c.each(function(a){a!==c&&g.push({source:a.parent,target:a})}),g},copy:function TM(){return Vx(this).eachBefore(q0)},[Symbol.iterator]:function*FE(){var g,u,x,I,c=this,a=[c];do{for(g=a.reverse(),a=[];c=g.pop();)if(yield c,u=c.children)for(x=0,I=u.length;x<I;++x)a.push(u[x])}while(a.length)}};var jx={depth:-1},Q0={},S1={};function NE(c){return c.id}function RE(c){return c.parentId}function E1(c){let g=c.length;if(g<2)return"";for(;--g>1&&!T1(c,g););return c.slice(0,g)}function T1(c,g){if("/"===c[g]){let a=0;for(;g>0&&"\\"===c[--g];)++a;if(!(1&a))return!0}return!1}function Y0(c,g){let a=0;if(void 0===g)for(let u of c)(u=+u)&&(a+=u);else{let u=-1;for(let x of c)(x=+g(x,++u,c))&&(a+=x)}return a}function kE(c,g){let a;if(void 0===g)for(const u of c)null!=u&&(a<u||void 0===a&&u>=u)&&(a=u);else{let u=-1;for(let x of c)null!=(x=g(x,++u,c))&&(a<x||void 0===a&&x>=x)&&(a=x)}return a}function PE(c){return c.depth}function I1(c,g){return c.sourceLinks.length?c.depth:g-1}function fp(c){return function(){return c}}function X0(c,g){return Qv(c.source,g.source)||c.index-g.index}function Ux(c,g){return Qv(c.target,g.target)||c.index-g.index}function Qv(c,g){return c.y0-g.y0}function Yv(c){return c.value}function IM(c){return c.index}function ay(c){return c.nodes}function BE(c){return c.links}function RD(c,g){const a=c.get(g);if(!a)throw new Error("missing: "+g);return a}function Z0({nodes:c}){for(const g of c){let a=g.y0,u=a;for(const x of g.sourceLinks)x.y0=a+x.width/2,a+=x.width;for(const x of g.targetLinks)x.y1=u+x.width/2,u+=x.width}}var $x=Math.PI,zm=2*$x,Xv=1e-6,LD=zm-Xv;function Zv(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function Bg(){return new Zv}Zv.prototype=Bg.prototype={constructor:Zv,moveTo:function(c,g){this._+="M"+(this._x0=this._x1=+c)+","+(this._y0=this._y1=+g)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(c,g){this._+="L"+(this._x1=+c)+","+(this._y1=+g)},quadraticCurveTo:function(c,g,a,u){this._+="Q"+ +c+","+ +g+","+(this._x1=+a)+","+(this._y1=+u)},bezierCurveTo:function(c,g,a,u,x,I){this._+="C"+ +c+","+ +g+","+ +a+","+ +u+","+(this._x1=+x)+","+(this._y1=+I)},arcTo:function(c,g,a,u,x){var I=this._x1,K=this._y1,ye=(a=+a)-(c=+c),Ye=(u=+u)-(g=+g),$e=I-c,ht=K-g,Vt=$e*$e+ht*ht;if((x=+x)<0)throw new Error("negative radius: "+x);if(null===this._x1)this._+="M"+(this._x1=c)+","+(this._y1=g);else if(Vt>Xv)if(Math.abs(ht*ye-Ye*$e)>Xv&&x){var zt=a-I,yn=u-K,li=ye*ye+Ye*Ye,pr=zt*zt+yn*yn,si=Math.sqrt(li),hr=Math.sqrt(Vt),_o=x*Math.tan(($x-Math.acos((li+Vt-pr)/(2*si*hr)))/2),jr=_o/hr,ao=_o/si;Math.abs(jr-1)>Xv&&(this._+="L"+(c+jr*$e)+","+(g+jr*ht)),this._+="A"+x+","+x+",0,0,"+ +(ht*zt>$e*yn)+","+(this._x1=c+ao*ye)+","+(this._y1=g+ao*Ye)}else this._+="L"+(this._x1=c)+","+(this._y1=g)},arc:function(c,g,a,u,x,I){c=+c,g=+g,I=!!I;var K=(a=+a)*Math.cos(u),ye=a*Math.sin(u),Ye=c+K,$e=g+ye,ht=1^I,Vt=I?u-x:x-u;if(a<0)throw new Error("negative radius: "+a);null===this._x1?this._+="M"+Ye+","+$e:(Math.abs(this._x1-Ye)>Xv||Math.abs(this._y1-$e)>Xv)&&(this._+="L"+Ye+","+$e),a&&(Vt<0&&(Vt=Vt%zm+zm),Vt>LD?this._+="A"+a+","+a+",0,1,"+ht+","+(c-K)+","+(g-ye)+"A"+a+","+a+",0,1,"+ht+","+(this._x1=Ye)+","+(this._y1=$e):Vt>Xv&&(this._+="A"+a+","+a+",0,"+ +(Vt>=$x)+","+ht+","+(this._x1=c+a*Math.cos(x))+","+(this._y1=g+a*Math.sin(x))))},rect:function(c,g,a,u){this._+="M"+(this._x0=this._x1=+c)+","+(this._y0=this._y1=+g)+"h"+ +a+"v"+ +u+"h"+-a+"Z"},toString:function(){return this._}};const kD=Bg;var Vg=Array.prototype.slice;function ly(c){return function(){return c}}function A1(c){return c[0]}function jg(c){return c[1]}function O1(c){return c.source}function Wx(c){return c.target}function F1(c,g,a,u,x){c.moveTo(g,a),c.bezierCurveTo(g=(g+u)/2,a,g,x,u,x)}function Hx(c){return[c.source.x1,c.y0]}function cy(c){return[c.target.x0,c.y1]}function pp(){return function ep(){return function Ug(c){var g=O1,a=Wx,u=A1,x=jg,I=null;function K(){var ye,Ye=Vg.call(arguments),$e=g.apply(this,Ye),ht=a.apply(this,Ye);if(I||(I=ye=kD()),c(I,+u.apply(this,(Ye[0]=$e,Ye)),+x.apply(this,Ye),+u.apply(this,(Ye[0]=ht,Ye)),+x.apply(this,Ye)),ye)return I=null,ye+""||null}return K.source=function(ye){return arguments.length?(g=ye,K):g},K.target=function(ye){return arguments.length?(a=ye,K):a},K.x=function(ye){return arguments.length?(u="function"==typeof ye?ye:ly(+ye),K):u},K.y=function(ye){return arguments.length?(x="function"==typeof ye?ye:ly(+ye),K):x},K.context=function(ye){return arguments.length?(I=ye??null,K):I},K}(F1)}().source(Hx).target(cy)}var J0=new Date,Pf=new Date;function tp(c,g,a,u){function x(I){return c(I=0===arguments.length?new Date:new Date(+I)),I}return x.floor=function(I){return c(I=new Date(+I)),I},x.ceil=function(I){return c(I=new Date(I-1)),g(I,1),c(I),I},x.round=function(I){var K=x(I),ye=x.ceil(I);return I-K<ye-I?K:ye},x.offset=function(I,K){return g(I=new Date(+I),null==K?1:Math.floor(K)),I},x.range=function(I,K,ye){var $e,Ye=[];if(I=x.ceil(I),ye=null==ye?1:Math.floor(ye),!(I<K&&ye>0))return Ye;do{Ye.push($e=new Date(+I)),g(I,ye),c(I)}while($e<I&&I<K);return Ye},x.filter=function(I){return tp(function(K){if(K>=K)for(;c(K),!I(K);)K.setTime(K-1)},function(K,ye){if(K>=K)if(ye<0)for(;++ye<=0;)for(;g(K,-1),!I(K););else for(;--ye>=0;)for(;g(K,1),!I(K););})},a&&(x.count=function(I,K){return J0.setTime(+I),Pf.setTime(+K),c(J0),c(Pf),Math.floor(a(J0,Pf))},x.every=function(I){return I=Math.floor(I),isFinite(I)&&I>0?I>1?x.filter(u?function(K){return u(K)%I==0}:function(K){return x.count(0,K)%I==0}):x:null}),x}const _a=864e5,sf=7*_a;function Ud(c){return tp(function(g){g.setUTCDate(g.getUTCDate()-(g.getUTCDay()+7-c)%7),g.setUTCHours(0,0,0,0)},function(g,a){g.setUTCDate(g.getUTCDate()+7*a)},function(g,a){return(a-g)/sf})}var np=Ud(0),dm=Ud(1),eu=(Ud(2),Ud(3),Ud(4));const Zu=(Ud(5),Ud(6),tp(function(c){c.setUTCHours(0,0,0,0)},function(c,g){c.setUTCDate(c.getUTCDate()+g)},function(c,g){return(g-c)/_a},function(c){return c.getUTCDate()-1}));function ch(c){return tp(function(g){g.setDate(g.getDate()-(g.getDay()+7-c)%7),g.setHours(0,0,0,0)},function(g,a){g.setDate(g.getDate()+7*a)},function(g,a){return(a-g-6e4*(a.getTimezoneOffset()-g.getTimezoneOffset()))/sf})}var bf=ch(0),eb=ch(1),Cf=(ch(2),ch(3),ch(4));const mp=(ch(5),ch(6),tp(c=>c.setHours(0,0,0,0),(c,g)=>c.setDate(c.getDate()+g),(c,g)=>(g-c-6e4*(g.getTimezoneOffset()-c.getTimezoneOffset()))/_a,c=>c.getDate()-1));var zx=tp(function(c){c.setMonth(0,1),c.setHours(0,0,0,0)},function(c,g){c.setFullYear(c.getFullYear()+g)},function(c,g){return g.getFullYear()-c.getFullYear()},function(c){return c.getFullYear()});zx.every=function(c){return isFinite(c=Math.floor(c))&&c>0?tp(function(g){g.setFullYear(Math.floor(g.getFullYear()/c)*c),g.setMonth(0,1),g.setHours(0,0,0,0)},function(g,a){g.setFullYear(g.getFullYear()+a*c)}):null};const Gm=zx;var Bl=tp(function(c){c.setUTCMonth(0,1),c.setUTCHours(0,0,0,0)},function(c,g){c.setUTCFullYear(c.getUTCFullYear()+g)},function(c,g){return g.getUTCFullYear()-c.getUTCFullYear()},function(c){return c.getUTCFullYear()});Bl.every=function(c){return isFinite(c=Math.floor(c))&&c>0?tp(function(g){g.setUTCFullYear(Math.floor(g.getUTCFullYear()/c)*c),g.setUTCMonth(0,1),g.setUTCHours(0,0,0,0)},function(g,a){g.setUTCFullYear(g.getUTCFullYear()+a*c)}):null};const n_=Bl;function Gx(c){if(0<=c.y&&c.y<100){var g=new Date(-1,c.m,c.d,c.H,c.M,c.S,c.L);return g.setFullYear(c.y),g}return new Date(c.y,c.m,c.d,c.H,c.M,c.S,c.L)}function Pa(c){if(0<=c.y&&c.y<100){var g=new Date(Date.UTC(-1,c.m,c.d,c.H,c.M,c.S,c.L));return g.setUTCFullYear(c.y),g}return new Date(Date.UTC(c.y,c.m,c.d,c.H,c.M,c.S,c.L))}function tb(c,g,a){return{y:c,m:g,d:a,H:0,M:0,S:0,L:0}}var Fu,dh,i_={"-":"",_:" ",0:"0"},yu=/^\s*\d+/,xc=/^%/,k1=/[\\^$*+?|[\]().{}]/g;function hc(c,g,a){var u=c<0?"-":"",x=(u?-c:c)+"",I=x.length;return u+(I<a?new Array(a-I+1).join(g)+x:x)}function $E(c){return c.replace(k1,"\\$&")}function gp(c){return new RegExp("^(?:"+c.map($E).join("|")+")","i")}function UD(c){return new Map(c.map((g,a)=>[g.toLowerCase(),a]))}function WE(c,g,a){var u=yu.exec(g.slice(a,a+1));return u?(c.w=+u[0],a+u[0].length):-1}function Hd(c,g,a){var u=yu.exec(g.slice(a,a+1));return u?(c.u=+u[0],a+u[0].length):-1}function P1(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.U=+u[0],a+u[0].length):-1}function TA(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.V=+u[0],a+u[0].length):-1}function Gg(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.W=+u[0],a+u[0].length):-1}function Kx(c,g,a){var u=yu.exec(g.slice(a,a+4));return u?(c.y=+u[0],a+u[0].length):-1}function HE(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.y=+u[0]+(+u[0]>68?1900:2e3),a+u[0].length):-1}function Bf(c,g,a){var u=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(g.slice(a,a+6));return u?(c.Z=u[1]?0:-(u[2]+(u[3]||"00")),a+u[0].length):-1}function zE(c,g,a){var u=yu.exec(g.slice(a,a+1));return u?(c.q=3*u[0]-3,a+u[0].length):-1}function OM(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.m=u[0]-1,a+u[0].length):-1}function Od(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.d=+u[0],a+u[0].length):-1}function GE(c,g,a){var u=yu.exec(g.slice(a,a+3));return u?(c.m=0,c.d=+u[0],a+u[0].length):-1}function $D(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.H=+u[0],a+u[0].length):-1}function FM(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.M=+u[0],a+u[0].length):-1}function NM(c,g,a){var u=yu.exec(g.slice(a,a+2));return u?(c.S=+u[0],a+u[0].length):-1}function qx(c,g,a){var u=yu.exec(g.slice(a,a+3));return u?(c.L=+u[0],a+u[0].length):-1}function Bp(c,g,a){var u=yu.exec(g.slice(a,a+6));return u?(c.L=Math.floor(u[0]/1e3),a+u[0].length):-1}function Fd(c,g,a){var u=xc.exec(g.slice(a,a+1));return u?a+u[0].length:-1}function Qx(c,g,a){var u=yu.exec(g.slice(a));return u?(c.Q=+u[0],a+u[0].length):-1}function KE(c,g,a){var u=yu.exec(g.slice(a));return u?(c.s=+u[0],a+u[0].length):-1}function pm(c,g){return hc(c.getDate(),g,2)}function $c(c,g){return hc(c.getHours(),g,2)}function Yx(c,g){return hc(c.getHours()%12||12,g,2)}function WD(c,g){return hc(1+mp.count(Gm(c),c),g,3)}function Kg(c,g){return hc(c.getMilliseconds(),g,3)}function B1(c,g){return Kg(c,g)+"000"}function Xx(c,g){return hc(c.getMonth()+1,g,2)}function V1(c,g){return hc(c.getMinutes(),g,2)}function RM(c,g){return hc(c.getSeconds(),g,2)}function j1(c){var g=c.getDay();return 0===g?7:g}function nb(c,g){return hc(bf.count(Gm(c)-1,c),g,2)}function U1(c){var g=c.getDay();return g>=4||0===g?Cf(c):Cf.ceil(c)}function Vf(c,g){return c=U1(c),hc(Cf.count(Gm(c),c)+(4===Gm(c).getDay()),g,2)}function ib(c){return c.getDay()}function $a(c,g){return hc(eb.count(Gm(c)-1,c),g,2)}function qg(c,g){return hc(c.getFullYear()%100,g,2)}function Qg(c,g){return hc((c=U1(c)).getFullYear()%100,g,2)}function kh(c,g){return hc(c.getFullYear()%1e4,g,4)}function Yg(c,g){var a=c.getDay();return hc((c=a>=4||0===a?Cf(c):Cf.ceil(c)).getFullYear()%1e4,g,4)}function r_(c){var g=c.getTimezoneOffset();return(g>0?"-":(g*=-1,"+"))+hc(g/60|0,"0",2)+hc(g%60,"0",2)}function fy(c,g){return hc(c.getUTCDate(),g,2)}function _s(c,g){return hc(c.getUTCHours(),g,2)}function rb(c,g){return hc(c.getUTCHours()%12||12,g,2)}function Zx(c,g){return hc(1+Zu.count(n_(c),c),g,3)}function Df(c,g){return hc(c.getUTCMilliseconds(),g,3)}function HD(c,g){return Df(c,g)+"000"}function Jx(c,g){return hc(c.getUTCMonth()+1,g,2)}function o_(c,g){return hc(c.getUTCMinutes(),g,2)}function LM(c,g){return hc(c.getUTCSeconds(),g,2)}function kM(c){var g=c.getUTCDay();return 0===g?7:g}function qE(c,g){return hc(np.count(n_(c)-1,c),g,2)}function eS(c){var g=c.getUTCDay();return g>=4||0===g?eu(c):eu.ceil(c)}function tS(c,g){return c=eS(c),hc(eu.count(n_(c),c)+(4===n_(c).getUTCDay()),g,2)}function zD(c){return c.getUTCDay()}function py(c,g){return hc(dm.count(n_(c)-1,c),g,2)}function hy(c,g){return hc(c.getUTCFullYear()%100,g,2)}function Ph(c,g){return hc((c=eS(c)).getUTCFullYear()%100,g,2)}function Vl(c,g){return hc(c.getUTCFullYear()%1e4,g,4)}function my(c,g){var a=c.getUTCDay();return hc((c=a>=4||0===a?eu(c):eu.ceil(c)).getUTCFullYear()%1e4,g,4)}function Ea(){return"+0000"}function Bh(){return"%"}function Oa(c){return+c}function ip(c){return Math.floor(+c/1e3)}!function PM(c){Fu=function UE(c){var g=c.dateTime,a=c.date,u=c.time,x=c.periods,I=c.days,K=c.shortDays,ye=c.months,Ye=c.shortMonths,$e=gp(x),ht=UD(x),Vt=gp(I),zt=UD(I),yn=gp(K),li=UD(K),pr=gp(ye),si=UD(ye),hr=gp(Ye),_o=UD(Ye),jr={a:function Jr(Cr){return K[Cr.getDay()]},A:function No(Cr){return I[Cr.getDay()]},b:function Hr(Cr){return Ye[Cr.getMonth()]},B:function ys(Cr){return ye[Cr.getMonth()]},c:null,d:pm,e:pm,f:B1,g:Qg,G:Yg,H:$c,I:Yx,j:WD,L:Kg,m:Xx,M:V1,p:function Ns(Cr){return x[+(Cr.getHours()>=12)]},q:function Ml(Cr){return 1+~~(Cr.getMonth()/3)},Q:Oa,s:ip,S:RM,u:j1,U:nb,V:Vf,w:ib,W:$a,x:null,X:null,y:qg,Y:kh,Z:r_,"%":Bh},ao={a:function Nu(Cr){return K[Cr.getUTCDay()]},A:function Rd(Cr){return I[Cr.getUTCDay()]},b:function ru(Cr){return Ye[Cr.getUTCMonth()]},B:function wd(Cr){return ye[Cr.getUTCMonth()]},c:null,d:fy,e:fy,f:HD,g:Ph,G:my,H:_s,I:rb,j:Zx,L:Df,m:Jx,M:o_,p:function jl(Cr){return x[+(Cr.getUTCHours()>=12)]},q:function Os(Cr){return 1+~~(Cr.getUTCMonth()/3)},Q:Oa,s:ip,S:LM,u:kM,U:qE,V:tS,w:zD,W:py,x:null,X:null,y:hy,Y:Vl,Z:Ea,"%":Bh},lo={a:function Ca(Cr,So,Po){var wi=yn.exec(So.slice(Po));return wi?(Cr.w=li.get(wi[0].toLowerCase()),Po+wi[0].length):-1},A:function oo(Cr,So,Po){var wi=Vt.exec(So.slice(Po));return wi?(Cr.w=zt.get(wi[0].toLowerCase()),Po+wi[0].length):-1},b:function Ba(Cr,So,Po){var wi=hr.exec(So.slice(Po));return wi?(Cr.m=_o.get(wi[0].toLowerCase()),Po+wi[0].length):-1},B:function Co(Cr,So,Po){var wi=pr.exec(So.slice(Po));return wi?(Cr.m=si.get(wi[0].toLowerCase()),Po+wi[0].length):-1},c:function us(Cr,So,Po){return yo(Cr,g,So,Po)},d:Od,e:Od,f:Bp,g:HE,G:Kx,H:$D,I:$D,j:GE,L:qx,m:OM,M:FM,p:function ml(Cr,So,Po){var wi=$e.exec(So.slice(Po));return wi?(Cr.p=ht.get(wi[0].toLowerCase()),Po+wi[0].length):-1},q:zE,Q:Qx,s:KE,S:NM,u:Hd,U:P1,V:TA,w:WE,W:Gg,x:function Rr(Cr,So,Po){return yo(Cr,a,So,Po)},X:function xo(Cr,So,Po){return yo(Cr,u,So,Po)},y:HE,Y:Kx,Z:Bf,"%":Fd};function mo(Cr,So){return function(Po){var Fa,hs,Ka,wi=[],ha=-1,dn=0,Ol=Cr.length;for(Po instanceof Date||(Po=new Date(+Po));++ha<Ol;)37===Cr.charCodeAt(ha)&&(wi.push(Cr.slice(dn,ha)),null!=(hs=i_[Fa=Cr.charAt(++ha)])?Fa=Cr.charAt(++ha):hs="e"===Fa?" ":"0",(Ka=So[Fa])&&(Fa=Ka(Po,hs)),wi.push(Fa),dn=ha+1);return wi.push(Cr.slice(dn,ha)),wi.join("")}}function br(Cr,So){return function(Po){var dn,Ol,wi=tb(1900,void 0,1);if(yo(wi,Cr,Po+="",0)!=Po.length)return null;if("Q"in wi)return new Date(wi.Q);if("s"in wi)return new Date(1e3*wi.s+("L"in wi?wi.L:0));if(So&&!("Z"in wi)&&(wi.Z=0),"p"in wi&&(wi.H=wi.H%12+12*wi.p),void 0===wi.m&&(wi.m="q"in wi?wi.q:0),"V"in wi){if(wi.V<1||wi.V>53)return null;"w"in wi||(wi.w=1),"Z"in wi?(Ol=(dn=Pa(tb(wi.y,0,1))).getUTCDay(),dn=Ol>4||0===Ol?dm.ceil(dn):dm(dn),dn=Zu.offset(dn,7*(wi.V-1)),wi.y=dn.getUTCFullYear(),wi.m=dn.getUTCMonth(),wi.d=dn.getUTCDate()+(wi.w+6)%7):(Ol=(dn=Gx(tb(wi.y,0,1))).getDay(),dn=Ol>4||0===Ol?eb.ceil(dn):eb(dn),dn=mp.offset(dn,7*(wi.V-1)),wi.y=dn.getFullYear(),wi.m=dn.getMonth(),wi.d=dn.getDate()+(wi.w+6)%7)}else("W"in wi||"U"in wi)&&("w"in wi||(wi.w="u"in wi?wi.u%7:"W"in wi?1:0),Ol="Z"in wi?Pa(tb(wi.y,0,1)).getUTCDay():Gx(tb(wi.y,0,1)).getDay(),wi.m=0,wi.d="W"in wi?(wi.w+6)%7+7*wi.W-(Ol+5)%7:wi.w+7*wi.U-(Ol+6)%7);return"Z"in wi?(wi.H+=wi.Z/100|0,wi.M+=wi.Z%100,Pa(wi)):Gx(wi)}}function yo(Cr,So,Po,wi){for(var Fa,hs,ha=0,dn=So.length,Ol=Po.length;ha<dn;){if(wi>=Ol)return-1;if(37===(Fa=So.charCodeAt(ha++))){if(Fa=So.charAt(ha++),!(hs=lo[Fa in i_?So.charAt(ha++):Fa])||(wi=hs(Cr,Po,wi))<0)return-1}else if(Fa!=Po.charCodeAt(wi++))return-1}return wi}return jr.x=mo(a,jr),jr.X=mo(u,jr),jr.c=mo(g,jr),ao.x=mo(a,ao),ao.X=mo(u,ao),ao.c=mo(g,ao),{format:function(Cr){var So=mo(Cr+="",jr);return So.toString=function(){return Cr},So},parse:function(Cr){var So=br(Cr+="",!1);return So.toString=function(){return Cr},So},utcFormat:function(Cr){var So=mo(Cr+="",ao);return So.toString=function(){return Cr},So},utcParse:function(Cr){var So=br(Cr+="",!0);return So.toString=function(){return Cr},So}}}(c),dh=Fu.format}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});const GD=["caretElm"],iS=c=>({model:c});function ob(c,g){}function $1(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"span"),i.\u0275\u0275template(1,ob,0,0,"ng-template",5),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngTemplateOutlet",a.template)("ngTemplateOutletContext",i.\u0275\u0275pureFunction1(2,iS,a.context))}}function KD(c,g){if(1&c&&i.\u0275\u0275element(0,"span",6),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("innerHTML",a.title,i.\u0275\u0275sanitizeHtml)}}function mm(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"header",4)(1,"span",5),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd()()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(a.title)}}function af(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"li",6)(1,"ngx-charts-legend-entry",7),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.labelClick.emit(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("label",a.label)("formattedLabel",a.formattedLabel)("color",a.color)("isActive",u.isActive(a))}}const vy=["*"];function qD(c,g){if(1&c&&i.\u0275\u0275element(0,"ngx-charts-scale-legend",4),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("horizontal",a.legendOptions&&a.legendOptions.position===a.LegendPosition.Below)("valueRange",a.legendOptions.domain)("colors",a.legendOptions.colors)("height",a.view[1])("width",a.legendWidth)}}function W1(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"ngx-charts-legend",5),i.\u0275\u0275listener("labelClick",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.legendLabelClick.emit(x))})("labelActivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.legendLabelActivate.emit(x))})("labelDeactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.legendLabelDeactivate.emit(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("horizontal",a.legendOptions&&a.legendOptions.position===a.LegendPosition.Below)("data",a.legendOptions.domain)("title",a.legendOptions.title)("colors",a.legendOptions.colors)("height",a.view[1])("width",a.legendWidth)("activeEntries",a.activeEntries)}}const sb=["ngx-charts-axis-label",""],ab=["ticksel"],H1=["ngx-charts-x-axis-ticks",""];function lb(c,g){1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainer(0))}function QD(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"tspan",10),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit;i.\u0275\u0275attribute("y",12*g.index),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a," ")}}function BM(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275template(1,QD,2,2,"tspan",9),i.\u0275\u0275elementContainerEnd()),2&c){const a=g.ngIf;i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a)}}function z1(c,g){if(1&c&&i.\u0275\u0275template(0,BM,2,1,"ng-container",6),2&c){const a=i.\u0275\u0275nextContext(2).$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("ngIf",u.tickChunks(a))}}function cb(c,g){if(1&c&&i.\u0275\u0275text(0),2&c){const a=i.\u0275\u0275nextContext().ngIf,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275textInterpolate1(" ",u.tickTrim(a)," ")}}function Xg(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275elementStart(1,"title"),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"text",7),i.\u0275\u0275template(4,lb,1,0,"ng-container",8),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(5,z1,1,1,"ng-template",null,1,i.\u0275\u0275templateRefExtractor)(7,cb,1,1,"ng-template",null,2,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275elementContainerEnd()),2&c){const a=g.ngIf,u=i.\u0275\u0275reference(6),x=i.\u0275\u0275reference(8),I=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(a),i.\u0275\u0275advance(),i.\u0275\u0275attribute("text-anchor",I.textAnchor)("transform",I.textTransform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",I.isWrapTicksSupported)("ngIfThen",u)("ngIfElse",x)}}function jf(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275template(1,Xg,9,6,"ng-container",6),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.tickTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.tickFormat(a))}}function G1(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"line",11),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",a.gridLineTransform()),i.\u0275\u0275advance(),i.\u0275\u0275attribute("y1",-a.gridLineHeight)}}function K1(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,G1,2,2,"g",6),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.tickTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showGridLines)}}const VM=["ngx-charts-x-axis",""];function YD(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.emitTicksHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("trimTicks",a.trimTicks)("rotateTicks",a.rotateTicks)("maxTickLength",a.maxTickLength)("tickFormatting",a.tickFormatting)("tickArguments",a.tickArguments)("tickStroke",a.tickStroke)("scale",a.xScale)("orient",a.xOrient)("showGridLines",a.showGridLines)("gridLineHeight",a.dims.height)("width",a.dims.width)("tickValues",a.ticks)("wrapTicks",a.wrapTicks)}}function q1(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",3)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("label",a.labelText)("offset",a.labelOffset)("orient",a.orientation.Bottom)("height",a.dims.height)("width",a.dims.width)}}const QE=["ngx-charts-y-axis-ticks",""];function Vp(c,g){1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainer(0))}function XD(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"tspan",12),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=g.index,x=i.\u0275\u0275nextContext(6);i.\u0275\u0275attribute("y",u*(8+x.tickSpacing)),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a," ")}}function ZD(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275template(1,XD,2,2,"tspan",11),i.\u0275\u0275elementContainerEnd()),2&c){const a=i.\u0275\u0275nextContext().ngIf;i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a)}}function s_(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275template(1,ZD,2,1,"ng-container",10),i.\u0275\u0275elementContainerEnd()),2&c){const a=g.ngIf;i.\u0275\u0275nextContext(2);const u=i.\u0275\u0275reference(8);i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",a.length>1)("ngIfElse",u)}}function JD(c,g){if(1&c&&i.\u0275\u0275template(0,s_,2,2,"ng-container",7),2&c){const a=i.\u0275\u0275nextContext(2).$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("ngIf",u.tickChunks(a))}}function YE(c,g){if(1&c&&i.\u0275\u0275text(0),2&c){const a=i.\u0275\u0275nextContext().ngIf,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275textInterpolate1(" ",u.tickTrim(a)," ")}}function _y(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementContainerStart(0),i.\u0275\u0275elementStart(1,"title"),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"text",8),i.\u0275\u0275template(4,Vp,1,0,"ng-container",9),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(5,JD,1,1,"ng-template",null,1,i.\u0275\u0275templateRefExtractor)(7,YE,1,1,"ng-template",null,2,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275elementContainerEnd()),2&c){const a=g.ngIf,u=i.\u0275\u0275reference(6),x=i.\u0275\u0275reference(8),I=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(a),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("font-size","12px"),i.\u0275\u0275attribute("dy",I.dy)("x",I.x1)("y",I.y1)("text-anchor",I.textAnchor),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",I.wrapTicks)("ngIfThen",u)("ngIfElse",x)}}function rS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275template(1,_y,9,10,"ng-container",7),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.transform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.tickFormat(a))}}function ew(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"path",13)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("d",a.referenceAreaPath)("transform",a.gridLineTransform())}}function yy(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"line",15)),2&c){const a=i.\u0275\u0275nextContext(3);i.\u0275\u0275attribute("x2",a.gridLineWidth)}}function Q1(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"line",15)),2&c){const a=i.\u0275\u0275nextContext(3);i.\u0275\u0275attribute("x2",-a.gridLineWidth)}}function Km(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,yy,1,1,"line",14)(2,Q1,1,1,"line",14),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",a.gridLineTransform()),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",a.orient===a.Orientation.Left),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",a.orient===a.Orientation.Right)}}function Zg(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Km,3,3,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.transform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showGridLines)}}function tw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"title"),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"text",17),i.\u0275\u0275text(4),i.\u0275\u0275elementEnd()()),2&c){const a=i.\u0275\u0275nextContext(2).$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(u.tickTrim(u.tickFormat(a.value))),i.\u0275\u0275advance(),i.\u0275\u0275attribute("dy",u.dy)("y",-6)("x",u.gridLineWidth)("text-anchor",u.textAnchor),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.name," ")}}function ub(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"line",16),i.\u0275\u0275template(2,tw,5,6,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.transform(a.value)),i.\u0275\u0275advance(),i.\u0275\u0275attribute("x2",u.gridLineWidth)("transform",u.gridLineTransform()),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showRefLabels)}}function nw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,ub,3,4,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",a.showRefLines)}}const Y1=["ngx-charts-y-axis",""];function qm(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.emitTicksWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("trimTicks",a.trimTicks)("maxTickLength",a.maxTickLength)("tickFormatting",a.tickFormatting)("tickArguments",a.tickArguments)("tickValues",a.ticks)("tickStroke",a.tickStroke)("scale",a.yScale)("orient",a.yOrient)("showGridLines",a.showGridLines)("gridLineWidth",a.dims.width)("referenceLines",a.referenceLines)("showRefLines",a.showRefLines)("showRefLabels",a.showRefLabels)("height",a.dims.height)("wrapTicks",a.wrapTicks)}}function db(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",3)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("label",a.labelText)("offset",a.labelOffset)("orient",a.yOrient)("height",a.dims.height)("width",a.dims.width)}}const XE=["ngx-charts-svg-linear-gradient",""];function ZE(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"stop")),2&c){const a=g.$implicit;i.\u0275\u0275styleProp("stop-color",a.color)("stop-opacity",a.opacity),i.\u0275\u0275attribute("offset",a.offset+"%")}}const oS=["ngx-charts-circle",""],Qm=["ngx-charts-circle-series",""],sS=c=>({name:c});function a_(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"rect",4)),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("x",a.circle.cx-a.circle.radius)("y",a.circle.cy)("width",2*a.circle.radius)("height",a.circle.height)("fill",a.gradientFill)}}function js(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"rect",4)),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("x",a.circle.cx-a.circle.radius)("y",a.circle.cy)("width",2*a.circle.radius)("height",a.circle.height)("fill",a.gradientFill)}}function fh(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"defs"),i.\u0275\u0275element(2,"g",1),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,a_,1,6,"rect",2)(4,js,1,5,"rect",2),i.\u0275\u0275elementStart(5,"g",3),i.\u0275\u0275listener("select",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.onClick(x.circle.data))})("activate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.activateCircle())})("deactivate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.deactivateCircle())}),i.\u0275\u0275elementEnd()()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(2),i.\u0275\u0275property("orientation",a.barOrientation.Vertical)("name",a.gradientId)("stops",a.circle.gradientStops),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!a.isSSR&&a.barVisible&&"standard"===a.type),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",a.isSSR&&a.barVisible&&"standard"===a.type),i.\u0275\u0275advance(),i.\u0275\u0275classProp("active",a.isActive(i.\u0275\u0275pureFunction1(20,sS,a.circle.seriesName))),i.\u0275\u0275property("cx",a.circle.cx)("cy",a.circle.cy)("r",a.circle.radius)("fill",a.circle.color)("pointerEvents",0===a.circle.value?"none":"all")("data",a.circle.value)("classNames",a.circle.classNames)("tooltipDisabled",a.tooltipDisabled)("tooltipPlacement",a.placementTypes.Top)("tooltipType",a.styleTypes.tooltip)("tooltipTitle",a.tooltipTemplate?void 0:a.getTooltipText(a.circle))("tooltipTemplate",a.tooltipTemplate)("tooltipContext",a.circle.data)}}const Vh=["ngx-charts-grid-panel",""],Jg=["ngx-charts-grid-panel-series",""];function aS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",1)),2&c){const a=g.$implicit;i.\u0275\u0275classProp("grid-panel",!0)("odd","odd"===a.class)("even","even"===a.class),i.\u0275\u0275property("height",a.height)("width",a.width)("x",a.x)("y",a.y)}}const by=["ngx-charts-svg-radial-gradient",""];function l_(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"stop")),2&c){const a=g.$implicit;i.\u0275\u0275styleProp("stop-color",a.color)("stop-opacity",a.opacity),i.\u0275\u0275attribute("offset",a.offset+"%")}}const X1=["ngx-charts-area",""];function gm(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275element(1,"g",2),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("orientation",a.barOrientation.Vertical)("name",a.gradientId)("stops",a.gradientStops)}}const fb=["ngx-charts-count-up",""],pb=["tooltipAnchor"],c_=["ngx-charts-tooltip-area",""];function Cy(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"div",6),i.\u0275\u0275element(1,"span",7),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275styleProp("background-color",a.color),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",u.getToolTipText(a)," ")}}function hb(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"div",4),i.\u0275\u0275template(1,Cy,3,3,"div",5),i.\u0275\u0275elementEnd()),2&c){const a=g.model;i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a)}}const Dy=["ngx-charts-timeline",""];function mb(c,g){if(1&c&&i.\u0275\u0275element(0,"div",7),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("countTo",a.roundedTotal)("valueFormatting",a.valueFormatting)}}function ph(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"div",8),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.valueFormatting?a.valueFormatting(a.roundedTotal):a.defaultValueFormatting(a.roundedTotal)," ")}}function JE(c,g){if(1&c&&i.\u0275\u0275element(0,"div",16),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("countTo",a._value)("valueFormatting",u.valueFormatting)}}function ev(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"div",17),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",u.valueFormatting?u.valueFormatting(a.value):u.defaultValueFormatting(a.value)," ")}}function jM(c,g){if(1&c&&i.\u0275\u0275element(0,"div",18),2&c){const a=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275property("countTo",a.percentage)("countSuffix","%")}}function wy(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"div",19),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1("",a.percentage.toLocaleString(),"%")}}function eT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"div",9),i.\u0275\u0275listener("mouseenter",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x.data))})("mouseleave",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit(x.data))})("click",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.select.emit(x.data))}),i.\u0275\u0275element(1,"div",10),i.\u0275\u0275template(2,JE,1,2,"div",11)(3,ev,2,1,"div",12),i.\u0275\u0275elementStart(4,"div",13),i.\u0275\u0275text(5),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(6,jM,1,2,"div",14)(7,wy,2,1,"div",15),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275styleProp("border-left-color",a.color),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(a.displayLabel),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.animations)}}const xy=["ngx-charts-area-series",""],bo=["tooltipTemplate"],Ym=["seriesTooltipTemplate"],mc=(c,g)=>[c,g];function iw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function tT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",8),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function Sy(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",9),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("baseValue",u.baseValue)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("scaleType",u.scaleType)("gradient",u.gradient)("curve",u.curve)("animations",u.animations)}}function Uf(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",13),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("activeEntries",u.activeEntries)("data",a)("scaleType",u.scaleType)("visibleValue",u.hoveredVertical)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function UM(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",10),i.\u0275\u0275listener("mouseleave",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.hideCircles())}),i.\u0275\u0275elementStart(1,"g",11),i.\u0275\u0275listener("hover",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateHoveredVertical(x))}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,Uf,2,9,"g",12),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("dims",a.dims)("xSet",a.xSet)("xScale",a.xScale)("yScale",a.yScale)("results",a.results)("colors",a.colors)("tooltipDisabled",a.tooltipDisabled)("tooltipTemplate",a.seriesTooltipTemplate),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)}}function gb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",15),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.timelineXScale)("yScale",u.timelineYScale)("baseValue",u.baseValue)("colors",u.colors)("data",a)("scaleType",u.scaleType)("gradient",u.gradient)("curve",u.curve)("animations",u.animations)}}function Z1(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",14),i.\u0275\u0275listener("onDomainChange",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateDomain(x))}),i.\u0275\u0275template(1,gb,2,9,"g",4),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("results",a.results)("view",i.\u0275\u0275pureFunction2(10,mc,a.timelineWidth,a.height))("height",a.timelineHeight)("scheme",a.scheme)("customColors",a.customColors)("legend",a.legend)("scaleType",a.scaleType),i.\u0275\u0275attribute("transform",a.timelineTransform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Tl(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function jh(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",8),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function lS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",9),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("activeEntries",u.activeEntries)("gradient",u.gradient)("normalized",!0)("curve",u.curve)("animations",u.animations)}}function rw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",13),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.seriesType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("activeEntries",u.activeEntries)("data",a)("scaleType",u.scaleType)("visibleValue",u.hoveredVertical)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function Qs(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",10),i.\u0275\u0275listener("mouseleave",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.hideCircles())}),i.\u0275\u0275elementStart(1,"g",11),i.\u0275\u0275listener("hover",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateHoveredVertical(x))}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,rw,2,10,"g",12),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("dims",a.dims)("xSet",a.xSet)("xScale",a.xScale)("yScale",a.yScale)("results",a.results)("colors",a.colors)("showPercentage",!0)("tooltipDisabled",a.tooltipDisabled)("tooltipTemplate",a.seriesTooltipTemplate),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)}}function vb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",15),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.timelineXScale)("yScale",u.timelineYScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("gradient",u.gradient)("normalized",!0)("curve",u.curve)("animations",u.animations)}}function nT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",14),i.\u0275\u0275listener("onDomainChange",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateDomain(x))}),i.\u0275\u0275template(1,vb,2,9,"g",4),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("results",a.results)("view",i.\u0275\u0275pureFunction2(10,mc,a.timelineWidth,a.height))("height",a.timelineHeight)("scheme",a.scheme)("customColors",a.customColors)("legend",a.legend)("scaleType",a.scaleType),i.\u0275\u0275attribute("transform",a.timelineTransform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const qo=".ngx-charts-outer{animation:chartFadeIn linear .6s}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .node,.ngx-charts .link,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .node.active,.ngx-charts .node:hover,.ngx-charts .link.active,.ngx-charts .link:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .node:focus,.ngx-charts .link:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .node.hidden,.ngx-charts .link.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n";function Xm(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function cS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",8),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function iT(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",9),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("gradient",u.gradient)("activeEntries",u.activeEntries)("stacked",!0)("curve",u.curve)("animations",u.animations)}}function Ey(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",12),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.seriesType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("activeEntries",u.activeEntries)("data",a)("scaleType",u.scaleType)("visibleValue",u.hoveredVertical)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function ow(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",10),i.\u0275\u0275listener("mouseleave",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.hideCircles())}),i.\u0275\u0275elementStart(1,"g",11),i.\u0275\u0275listener("hover",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateHoveredVertical(x))}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,Ey,2,10,"g",4),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("dims",a.dims)("xSet",a.xSet)("xScale",a.xScale)("yScale",a.yScale)("results",a.results)("colors",a.colors)("tooltipDisabled",a.tooltipDisabled)("tooltipTemplate",a.seriesTooltipTemplate),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function lu(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",14),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.timelineXScale)("yScale",u.timelineYScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("gradient",u.gradient)("stacked",!0)("curve",u.curve)("animations",u.animations)}}function vp(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",13),i.\u0275\u0275listener("onDomainChange",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateDomain(x))}),i.\u0275\u0275template(1,lu,2,9,"g",4),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("results",a.results)("view",i.\u0275\u0275pureFunction2(10,mc,a.timelineWidth,a.height))("height",a.timelineHeight)("scheme",a.scheme)("customColors",a.customColors)("legend",a.legend)("scaleType",a.scaleType),i.\u0275\u0275attribute("transform",a.timelineTransform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const Uh=["ngx-charts-bar",""];function J1(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275element(1,"g",2),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("orientation",a.orientation)("name",a.gradientId)("stops",a.gradientStops)}}const eC=["ngx-charts-bar-label",""],uS=["ngx-charts-series-horizontal",""];function sw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.click(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("@animationState","active")("width",a.width)("height",a.height)("x",a.x)("y",a.y)("fill",a.color)("stops",a.gradientStops)("data",a.data)("orientation",u.barOrientation.Horizontal)("roundEdges",a.roundEdges)("gradient",u.gradient)("isActive",u.isActive(a.data))("ariaLabel",a.ariaLabel)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.tooltipPlacement)("tooltipType",u.tooltipType)("tooltipTitle",u.tooltipTemplate?void 0:a.tooltipText)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)("noBarWhenZero",u.noBarWhenZero)}}function Ty(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",4),i.\u0275\u0275listener("dimensionsChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.dataLabelWidthChanged.emit({size:x,index:I}))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("barX",a.x)("barY",a.y)("barWidth",a.width)("barHeight",a.height)("value",a.total)("valueFormatting",u.dataLabelFormatting)("orientation",u.barOrientation.Horizontal)}}function Zm(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Ty,1,7,"g",3),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.barsForDataLabels)("ngForTrackBy",a.trackDataLabelBy)}}function dS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function _b(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("yAxisOffset",a.dataLabelMaxWidth.negative)("wrapTicks",a.wrapTicks)}}function fS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.valueScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function tC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.groupScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("yAxisOffset",a.dataLabelMaxWidth.negative)("wrapTicks",a.wrapTicks)}}function tv(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelWidthChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxWidthChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.valueScale)("activeEntries",u.activeEntries)("yScale",u.innerScale)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("roundEdges",u.roundEdges)("animations",u.animations)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("noBarWhenZero",u.noBarWhenZero)}}function nv(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,tv,2,17,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function wf(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelWidthChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxWidthChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.valueScale)("activeEntries",u.activeEntries)("yScale",u.innerScale)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("roundEdges",u.roundEdges)("animations",u.animations)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("noBarWhenZero",u.noBarWhenZero)}}function nC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,wf,2,16,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function My(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function pS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function iC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Normalized)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function Iy(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,iC,2,15,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function u_(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Normalized)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function Jm(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,u_,2,14,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function eg(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function Ay(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("yAxisOffset",a.dataLabelMaxWidth.negative)("wrapTicks",a.wrapTicks)}}function iv(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelWidthChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxWidthChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("series",a.series)("activeEntries",u.activeEntries)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("noBarWhenZero",u.noBarWhenZero)}}function hS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,iv,2,17,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Oy(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelWidthChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxWidthChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("series",a.series)("activeEntries",u.activeEntries)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("noBarWhenZero",u.noBarWhenZero)}}function aw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Oy,2,16,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const tg=["ngx-charts-series-vertical",""];function rC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.activate.emit(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.deactivate.emit(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active")("@.disabled",!u.animations)("width",a.width)("height",a.height)("x",a.x)("y",a.y)("fill",a.color)("stops",a.gradientStops)("data",a.data)("orientation",u.barOrientation.Vertical)("roundEdges",a.roundEdges)("gradient",u.gradient)("ariaLabel",a.ariaLabel)("isActive",u.isActive(a.data))("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.tooltipPlacement)("tooltipType",u.tooltipType)("tooltipTitle",u.tooltipTemplate?void 0:a.tooltipText)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)("noBarWhenZero",u.noBarWhenZero)("animations",u.animations)}}function yb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,rC,1,22,"g",1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.bars)("ngForTrackBy",a.trackBy)}}function lw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.activate.emit(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.deactivate.emit(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("width",a.width)("height",a.height)("x",a.x)("y",a.y)("fill",a.color)("stops",a.gradientStops)("data",a.data)("orientation",u.barOrientation.Vertical)("roundEdges",a.roundEdges)("gradient",u.gradient)("ariaLabel",a.ariaLabel)("isActive",u.isActive(a.data))("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.tooltipPlacement)("tooltipType",u.tooltipType)("tooltipTitle",u.tooltipTemplate?void 0:a.tooltipText)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)("noBarWhenZero",u.noBarWhenZero)("animations",u.animations)}}function bb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,lw,1,20,"g",1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.bars)("ngForTrackBy",a.trackBy)}}function Cb(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",4),i.\u0275\u0275listener("dimensionsChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.dataLabelHeightChanged.emit({size:x,index:I}))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("barX",a.x)("barY",a.y)("barWidth",a.width)("barHeight",a.height)("value",a.total)("valueFormatting",u.dataLabelFormatting)("orientation",u.barOrientation.Vertical)}}function oC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Cb,1,7,"g",3),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.barsForDataLabels)("ngForTrackBy",a.trackDataLabelBy)}}function ng(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("xAxisOffset",a.dataLabelMaxHeight.negative)("wrapTicks",a.wrapTicks)}}function rT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function mS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.groupScale)("dims",a.dims)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("xAxisOffset",a.dataLabelMaxHeight.negative)("wrapTicks",a.wrapTicks)}}function rv(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.valueScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function cw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelHeightChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxHeightChanged(x,I))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active")("activeEntries",u.activeEntries)("xScale",u.innerScale)("yScale",u.valueScale)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("seriesName",a.name)("roundEdges",u.roundEdges)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero),i.\u0275\u0275attribute("transform",u.groupTransform(a))}}function $M(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,cw,1,17,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Db(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelHeightChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxHeightChanged(x,I))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("activeEntries",u.activeEntries)("xScale",u.innerScale)("yScale",u.valueScale)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("seriesName",a.name)("roundEdges",u.roundEdges)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero),i.\u0275\u0275attribute("transform",u.groupTransform(a))}}function sC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Db,1,16,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function gS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function d_(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function aC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Normalized)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function jp(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,aC,2,15,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Fy(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Normalized)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function wb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Fy,2,14,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Ac(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("xAxisOffset",a.dataLabelMaxHeight.negative)("wrapTicks",a.wrapTicks)}}function Up(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function Ny(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelHeightChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxHeightChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function Oc(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Ny,2,17,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function oT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",8),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onActivate(x,I))})("deactivate",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDeactivate(x,I))})("dataLabelHeightChanged",function(x){const I=i.\u0275\u0275restoreView(a).index,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onDataLabelMaxHeightChanged(x,I))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275attribute("transform",u.groupTransform(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("type",u.barChartType.Stacked)("xScale",u.xScale)("yScale",u.yScale)("activeEntries",u.activeEntries)("colors",u.colors)("series",a.series)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("seriesName",a.name)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero)}}function MA(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,oT,2,16,"g",7),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const uw=["ngx-charts-box",""];function sT(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",5)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("orientation",a.BarOrientation.Vertical)("name",a.gradientId)("stops",a.gradientStops)}}function dw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"line",6)),2&c){const a=g.$implicit,u=g.index,x=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("hidden",x.hideBar),i.\u0275\u0275attribute("x1",a.v1.x)("y1",a.v1.y)("x2",a.v2.x)("y2",a.v2.y)("stroke",x.strokeColor)("stroke-width",2===u?x.medianLineWidth:x.whiskerStrokeWidth)("mask",u?void 0:x.maskLine)}}const IA=["ngx-charts-box-series",""];function aT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",5),i.\u0275\u0275listener("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onDeactivate(x))})("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("roundEdges",u.roundEdges)("strokeColor",u.strokeColor)("strokeWidth",u.strokeWidth)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("series",a)("dims",u.dims)("animations",u.animations)("gradient",u.gradient)}}const WM=["ngx-charts-bubble-series",""];function lC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x.data))})("activate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activateCircle(x))})("deactivate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivateCircle(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("opacity",a.opacity),i.\u0275\u0275classProp("active",a.isActive),i.\u0275\u0275property("@animationState","active")("cx",0)("cy",0)("r",a.radius)("fill",a.color)("pointerEvents","all")("data",a.value)("classNames",a.classNames)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.getTooltipText(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)}}function cC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x.data))})("activate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activateCircle(x))})("deactivate",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext().$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivateCircle(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("opacity",a.opacity),i.\u0275\u0275classProp("active",a.isActive),i.\u0275\u0275property("cx",0)("cy",0)("r",a.radius)("fill",a.color)("pointerEvents","all")("data",a.value)("classNames",a.classNames)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.getTooltipText(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)}}function uC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g"),i.\u0275\u0275template(2,lC,1,18,"g",1)(3,cC,1,17,"g",1),i.\u0275\u0275elementEnd()()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",a.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR)}}function xb(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("showGridLines",a.showGridLines)("dims",a.dims)("xScale",a.xScale)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function f_(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("showGridLines",a.showGridLines)("yScale",a.yScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function vS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("rScale",u.rScale)("xScaleType",u.xScaleType)("yScaleType",u.yScaleType)("xAxisLabel",u.xAxisLabel)("yAxisLabel",u.yAxisLabel)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function p_(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,vS,2,13,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("clip-path",a.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.data)("ngForTrackBy",a.trackBy)}}function fw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",9),i.\u0275\u0275listener("select",function(x){const I=i.\u0275\u0275restoreView(a).$implicit,K=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(K.onClick(x,I))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("rScale",u.rScale)("xScaleType",u.xScaleType)("yScaleType",u.yScaleType)("xAxisLabel",u.xAxisLabel)("yAxisLabel",u.yAxisLabel)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function Sb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,fw,2,12,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("clip-path",a.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.data)("ngForTrackBy",a.trackBy)}}const _S=["ngx-charts-heat-map-cell",""];function dC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275element(1,"g",3),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("orientation",a.barOrientation.Vertical)("name",a.gradientId)("stops",a.gradientStops)}}const Ry=["ngx-charts-heat-map-cell-series",""],yS=(c,g,a)=>({series:c,name:g,value:a});function h_(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",1),i.\u0275\u0275listener("select",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x.cell))})("activate",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x.cell))})("deactivate",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit(x.cell))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("x",a.x)("y",a.y)("width",a.width)("height",a.height)("fill",a.fill)("data",a.data)("gradient",u.gradient)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.tooltipText(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",i.\u0275\u0275pureFunction3(14,yS,a.series,a.label,a.data))}}function Ly(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",6),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function lT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("wrapTicks",a.wrapTicks)}}function ov(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"rect")),2&c){const a=g.$implicit;i.\u0275\u0275attribute("x",a.x)("y",a.y)("rx",a.rx)("width",a.width)("height",a.height)("fill",a.fill)}}const pw=["ngx-charts-line",""];function hw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"path",1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275attribute("d",a.initialPath)("fill",a.fill)("stroke",a.stroke)}}function m_(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"path",1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275attribute("d",a.initialPath)("fill",a.fill)("stroke",a.stroke)}}const cT=["ngx-charts-line-series",""];function mw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",4)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("orientation",a.barOrientation.Vertical)("name",a.gradientId)("stops",a.gradientStops)}}function $p(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",5)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275classProp("active",a.isActive(a.data))("inactive",a.isInactive(a.data)),i.\u0275\u0275property("data",a.data)("path",a.outerPath)("fill",a.hasGradient?a.gradientUrl:a.colors.getColor(a.data.name))("opacity",a.rangeFillOpacity)("animations",a.animations)}}function ig(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",7),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateXAxisHeight(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("xScale",a.xScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showXAxisLabel)("labelText",a.xAxisLabel)("trimTicks",a.trimXAxisTicks)("rotateTicks",a.rotateXAxisTicks)("maxTickLength",a.maxXAxisTickLength)("tickFormatting",a.xAxisTickFormatting)("ticks",a.xAxisTicks)("wrapTicks",a.wrapTicks)}}function fC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",8),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yScale)("dims",a.dims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("ticks",a.yAxisTicks)("referenceLines",a.referenceLines)("showRefLines",a.showRefLines)("showRefLabels",a.showRefLabels)("wrapTicks",a.wrapTicks)}}function pC(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",10),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("scaleType",u.scaleType)("curve",u.curve)("rangeFillOpacity",u.rangeFillOpacity)("hasRange",u.hasRange)("animations",u.animations)}}function vm(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,pC,2,11,"g",9),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function bS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",10),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("scaleType",u.scaleType)("curve",u.curve)("rangeFillOpacity",u.rangeFillOpacity)("hasRange",u.hasRange)("animations",u.animations)}}function sv(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,bS,2,10,"g",9),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function Fs(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",14),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("visibleValue",u.hoveredVertical)("activeEntries",u.activeEntries)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function ky(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",11),i.\u0275\u0275listener("mouseleave",function(){i.\u0275\u0275restoreView(a);const x=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(x.hideCircles())}),i.\u0275\u0275elementStart(1,"g",12),i.\u0275\u0275listener("hover",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateHoveredVertical(x))}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,Fs,2,9,"g",13),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("dims",a.dims)("xSet",a.xSet)("xScale",a.xScale)("yScale",a.yScale)("results",a.results)("colors",a.colors)("tooltipDisabled",a.tooltipDisabled)("tooltipTemplate",a.seriesTooltipTemplate),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)}}function uT(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275element(1,"g",16),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.timelineXScale)("yScale",u.timelineYScale)("colors",u.colors)("data",a)("scaleType",u.scaleType)("curve",u.curve)("hasRange",u.hasRange)("animations",u.animations)}}function rg(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",15),i.\u0275\u0275listener("onDomainChange",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateDomain(x))}),i.\u0275\u0275template(1,uT,2,8,"g",9),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("results",a.results)("view",i.\u0275\u0275pureFunction2(10,mc,a.timelineWidth,a.height))("height",a.timelineHeight)("scheme",a.scheme)("customColors",a.customColors)("scaleType",a.scaleType)("legend",a.legend),i.\u0275\u0275attribute("transform",a.timelineTransform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const CS=["ngx-charts-pie-label",""],dT=["ngx-charts-polar-series",""];function HM(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",4)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("color",a.seriesColor)("name",a.gradientId)("startOpacity",.25)("endOpacity",1)("stops",a.gradientStops)}}function hC(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5),i.\u0275\u0275listener("select",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.select.emit(x.data))})("activate",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit({name:x.data.series}))})("deactivate",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit({name:x.data.series}))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("opacity",u.inactive?.2:1),i.\u0275\u0275property("cx",a.cx)("cy",a.cy)("r",u.circleRadius)("fill",a.color)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.tooltipText(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)}}function g_(c,g){1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"circle",7)),2&c&&i.\u0275\u0275attribute("r",g.$implicit)}function Eb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,g_,1,1,"circle",6),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.radiusTicks)}}function Py(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",9)),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("data",a)("radius",u.outerRadius)("label",a.label)("max",u.outerRadius)("value",u.showGridLines?1:u.outerRadius)("explodeSlices",!0)("animations",u.animations)("labelTrim",u.labelTrim)("labelTrimSize",u.labelTrimSize)}}function $h(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Py,1,9,"g",8),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.thetaTicks)}}function DS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",10),i.\u0275\u0275listener("dimensionsChanged",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.updateYAxisWidth(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("yScale",a.yAxisScale)("dims",a.yAxisDims)("showGridLines",a.showGridLines)("showLabel",a.showYAxisLabel)("labelText",a.yAxisLabel)("trimTicks",a.trimYAxisTicks)("maxTickLength",a.maxYAxisTickLength)("tickFormatting",a.yAxisTickFormatting)("wrapTicks",a.wrapTicks),i.\u0275\u0275attribute("transform",a.transformYAxis)}}function Tb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",11)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("label",a.xAxisLabel)("offset",a.labelOffset)("orient",a.orientation.Bottom)("height",a.dims.height)("width",a.dims.width)}}function gw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",13),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("@animationState","active"),i.\u0275\u0275advance(),i.\u0275\u0275property("gradient",u.gradient)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("scaleType",u.scaleType)("curve",u.curve)("rangeFillOpacity",u.rangeFillOpacity)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function wS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,gw,2,13,"g",12),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transformPlot),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}function xS(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",13),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext(2);return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275property("gradient",u.gradient)("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",a)("activeEntries",u.activeEntries)("scaleType",u.scaleType)("curve",u.curve)("rangeFillOpacity",u.rangeFillOpacity)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)}}function fT(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,xS,2,12,"g",12),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transformPlot),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",a.results)("ngForTrackBy",a.trackBy)}}const v_=["ngx-charts-pie-arc",""];function SS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275element(1,"g",3),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("color",a.fill)("name",a.radialGradientId)("startOpacity",a.startOpacity)}}const pT=["ngx-charts-pie-series",""];function vw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",3)),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("data",a)("radius",u.outerRadius)("color",u.color(a))("label",u.labelText(a))("labelTrim",u.trimLabels)("labelTrimSize",u.maxLabelLength)("max",u.max)("value",a.value)("explodeSlices",u.explodeSlices)("animations",u.animations)}}function _w(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,vw,1,10,"g",1),i.\u0275\u0275elementStart(2,"g",2),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit(x))})("dblclick",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.dblclick.emit(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.labelVisible(a)),i.\u0275\u0275advance(),i.\u0275\u0275property("startAngle",a.startAngle)("endAngle",a.endAngle)("innerRadius",u.innerRadius)("outerRadius",u.outerRadius)("fill",u.color(a))("value",a.data.value)("gradient",u.gradient)("data",a.data)("max",u.max)("explodeSlices",u.explodeSlices)("isActive",u.isActive(a.data))("animate",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.getTooltipTitle(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)}}const Mb=["ngx-charts-pie-grid-series",""];function ES(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.deactivate.emit(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("startAngle",a.startAngle)("endAngle",a.endAngle)("innerRadius",u.innerRadius)("outerRadius",u.outerRadius)("fill",u.color(a))("value",a.data.value)("data",a.data)("gradient",!1)("pointerEvents",a.pointerEvents)("animate",a.animate),i.\u0275\u0275attribute("class",a.class)}}const mT=c=>({data:c});function Ib(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"text",10)),2&c){const a=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275property("countTo",a.percent)("countSuffix","%")}}function yw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text",11),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.percent.toLocaleString()," ")}}function TS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"text",12)),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("countTo",a.total)("countPrefix",u.label+": "),i.\u0275\u0275attribute("y",a.outerRadius)}}function gT(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text",13),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("y",a.outerRadius),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate2(" ",u.label,": ",a.total.toLocaleString()," ")}}function Ab(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",3)(1,"g",4),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,Ib,1,2,"text",5)(3,yw,2,1,"text",6),i.\u0275\u0275elementStart(4,"text",7),i.\u0275\u0275text(5),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(6,TS,1,3,"text",8)(7,gT,2,3,"text",9),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("colors",a.colors)("data",a.data)("innerRadius",a.innerRadius)("outerRadius",a.outerRadius)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.tooltipText(i.\u0275\u0275pureFunction1(17,mT,a)))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data[0].data),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",a.label," "),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.animations)}}const Ob=["textEl"],MS=["ngx-charts-card",""];function By(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"path",7)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("fill",a.bandColor)("transform",a.transformBand)("d",a.bandPath)}}const vT=["ngx-charts-card-series",""];function __(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"rect",2)),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("fill",u.emptyColor),i.\u0275\u0275attribute("x",a.x)("y",a.y)("width",a.width)("height",a.height)}}function og(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",3),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("x",a.x)("y",a.y)("width",a.width)("height",a.height)("color",a.color)("bandColor",a.bandColor)("textColor",a.textColor)("data",a.data)("label",a.label)("medianSize",u.medianSize)("valueFormatting",u.valueFormatting)("labelFormatting",u.labelFormatting)("animations",u.animations)}}const mC=["ngx-charts-tree-map-cell",""];function bw(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275element(1,"g",3),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275advance(),i.\u0275\u0275property("orientation",a.orientation.Vertical)("name",a.gradientId)("stops",a.gradientStops)}}function Cw(c,g){if(1&c&&i.\u0275\u0275element(0,"span",8),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275property("countTo",a.value)("valueFormatting",a.valueFormatting)}}function y_(c,g){if(1&c&&(i.\u0275\u0275elementStart(0,"span",9),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext(2);i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.formattedValue," ")}}function _T(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"foreignObject",4),i.\u0275\u0275namespaceHTML(),i.\u0275\u0275elementStart(1,"p"),i.\u0275\u0275element(2,"span",5)(3,"br"),i.\u0275\u0275template(4,Cw,1,2,"span",6)(5,y_,2,1,"span",7),i.\u0275\u0275elementEnd()()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("pointer-events","none"),i.\u0275\u0275attribute("x",a.x)("y",a.y)("width",a.width)("height",a.height),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("color",a.getTextColor())("height",a.height+"px")("width",a.width+"px"),i.\u0275\u0275advance(),i.\u0275\u0275property("innerHTML",a.formattedLabel,i.\u0275\u0275sanitizeHtml),i.\u0275\u0275advance(2),i.\u0275\u0275property("ngIf",a.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!a.animations)}}const Vy=["ngx-charts-tree-map-cell-series",""];function yT(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",1),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))}),i.\u0275\u0275elementEnd()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("data",a.data)("x",a.x)("y",a.y)("width",a.width)("height",a.height)("fill",a.fill)("label",a.label)("value",a.value)("valueFormatting",u.valueFormatting)("labelFormatting",u.labelFormatting)("gradient",u.gradient)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.getTooltipText(a))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data)}}const bT=["valueTextEl"],jy=["unitsTextEl"],Dw=()=>({});function ww(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"line",10)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transformLine)("stroke",a.colors.getColor(a.units))}}function Uy(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"line",11)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transformLine)("stroke",a.colors.getColor(a.units))}}const gC=["ngx-charts-gauge-arc",""],vC=["ngx-charts-gauge-axis",""];function Fb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2),i.\u0275\u0275element(1,"path"),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit;i.\u0275\u0275advance(),i.\u0275\u0275attribute("d",a.line)}}function IS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",2)(1,"text",3),i.\u0275\u0275text(2),i.\u0275\u0275elementEnd()()),2&c){const a=g.$implicit;i.\u0275\u0275advance(),i.\u0275\u0275styleProp("text-anchor",a.textAnchor),i.\u0275\u0275attribute("transform",a.textTransform),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.text," ")}}function Nb(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",4),i.\u0275\u0275element(1,"path"),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit;i.\u0275\u0275advance(),i.\u0275\u0275attribute("d",a.line)}}function xw(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"g",6),i.\u0275\u0275listener("select",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onClick(x))})("activate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onActivate(x))})("deactivate",function(x){i.\u0275\u0275restoreView(a);const I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.onDeactivate(x))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",u.rotation),i.\u0275\u0275advance(),i.\u0275\u0275property("backgroundArc",a.backgroundArc)("valueArc",a.valueArc)("cornerRadius",u.cornerRadius)("colors",u.colors)("isActive",u.isActive(a.valueArc.data))("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("valueFormatting",u.valueFormatting)("animations",u.animations)}}function AS(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",7)),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275property("bigSegments",a.bigSegments)("smallSegments",a.smallSegments)("min",a.min)("max",a.max)("radius",a.outerRadius)("angleSpan",a.angleSpan)("valueScale",a.valueScale)("startAngle",a.startAngle)("tickFormatting",a.axisTickFormatting)}}function _m(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text",8,0)(2,"tspan",9),i.\u0275\u0275text(3),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(4,"tspan",10),i.\u0275\u0275text(5),i.\u0275\u0275elementEnd()()),2&c){const a=i.\u0275\u0275nextContext();i.\u0275\u0275styleProp("text-anchor","middle"),i.\u0275\u0275attribute("transform",a.textTransform),i.\u0275\u0275advance(3),i.\u0275\u0275textInterpolate(a.displayValue),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(a.units)}}function Wh(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",5)(1,"defs")(2,"linearGradient",6),i.\u0275\u0275element(3,"stop",7)(4,"stop",8),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(5,"path",9),i.\u0275\u0275listener("click",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.select.emit(x.data))})("mouseenter",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x.data))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275property("tooltipDisabled",u.tooltipDisabled)("tooltipType",u.styleTypes.tooltip)("tooltipPlacement","top")("tooltipTitle",u.tooltipTemplate?void 0:a.tooltip)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",a.id)("x1",a.source.x1)("x2",a.target.x0),i.\u0275\u0275advance(),i.\u0275\u0275attribute("stop-color",a.startColor),i.\u0275\u0275advance(),i.\u0275\u0275attribute("stop-color",a.endColor),i.\u0275\u0275advance(),i.\u0275\u0275attribute("d",a.path)("stroke",a.gradientFill)("stroke-width",a.strokeWidth)}}function Wp(c,g){if(1&c){const a=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",10)(1,"rect",11),i.\u0275\u0275listener("click",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.select.emit(x.data))})("mouseenter",function(){const x=i.\u0275\u0275restoreView(a).$implicit,I=i.\u0275\u0275nextContext();return i.\u0275\u0275resetView(I.activate.emit(x.data))}),i.\u0275\u0275elementEnd()()}if(2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("tooltipDisabled",u.tooltipDisabled)("tooltipType",u.styleTypes.tooltip)("tooltipPlacement","top")("tooltipTitle",u.tooltipTemplate?void 0:a.tooltip)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",a.data),i.\u0275\u0275attribute("x",0)("y",0)("width",a.width)("height",a.height)("fill",a.fill)}}function zM(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text",13),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&c){const a=i.\u0275\u0275nextContext().$implicit;i.\u0275\u0275attribute("x",a.width+5)("y",a.height/2)("text-anchor",a.labelAnchor)("dx","end"===a.labelAnchor?-25:0),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",a.label," ")}}function sg(c,g){if(1&c&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,zM,2,5,"text",12),i.\u0275\u0275elementEnd()),2&c){const a=g.$implicit,u=i.\u0275\u0275nextContext();i.\u0275\u0275attribute("transform",a.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showLabels&&a.height>15)}}function av(c,g,a){a=a||{};let u,x,I,K=null,ye=0;function Ye(){ye=!1===a.leading?0:+new Date,K=null,I=c.apply(u,x)}return function(){const $e=+new Date;!ye&&!1===a.leading&&(ye=$e);const ht=g-($e-ye);return u=this,x=arguments,ht<=0?(clearTimeout(K),K=null,ye=$e,I=c.apply(u,x)):!K&&!1!==a.trailing&&(K=setTimeout(Ye,ht)),I}}function OS(c,g){return function(u,x,I){return{configurable:!0,enumerable:I.enumerable,get:function(){return Object.defineProperty(this,x,{configurable:!0,enumerable:I.enumerable,value:av(I.value,c,g)}),this[x]}}}}var Ys=function(c){return c.Top="top",c.Bottom="bottom",c.Left="left",c.Right="right",c.Center="center",c}(Ys||{});function _C(c,g,a){return a===Ys.Top?c.top-7:a===Ys.Bottom?c.top+c.height-g.height+7:a===Ys.Center?c.top+c.height/2-g.height/2:void 0}function FS(c,g,a){return a===Ys.Left?c.left-7:a===Ys.Right?c.left+c.width-g.width+7:a===Ys.Center?c.left+c.width/2-g.width/2:void 0}class $f{static calculateVerticalAlignment(g,a,u){let x=_C(g,a,u);return x+a.height>window.innerHeight&&(x=window.innerHeight-a.height),x}static calculateVerticalCaret(g,a,u,x){let I;x===Ys.Top&&(I=g.height/2-u.height/2+7),x===Ys.Bottom&&(I=a.height-g.height/2-u.height/2-7),x===Ys.Center&&(I=a.height/2-u.height/2);const K=_C(g,a,x);return K+a.height>window.innerHeight&&(I+=K+a.height-window.innerHeight),I}static calculateHorizontalAlignment(g,a,u){let x=FS(g,a,u);return x+a.width>window.innerWidth&&(x=window.innerWidth-a.width),x}static calculateHorizontalCaret(g,a,u,x){let I;x===Ys.Left&&(I=g.width/2-u.width/2+7),x===Ys.Right&&(I=a.width-g.width/2-u.width/2-7),x===Ys.Center&&(I=a.width/2-u.width/2);const K=FS(g,a,x);return K+a.width>window.innerWidth&&(I+=K+a.width-window.innerWidth),I}static shouldFlip(g,a,u,x){let I=!1;return u===Ys.Right&&g.left+g.width+a.width+x>window.innerWidth&&(I=!0),u===Ys.Left&&g.left-a.width-x<0&&(I=!0),u===Ys.Top&&g.top-a.height-x<0&&(I=!0),u===Ys.Bottom&&g.top+g.height+a.height+x>window.innerHeight&&(I=!0),I}static positionCaret(g,a,u,x,I){let K=0,ye=0;return g===Ys.Right?(ye=-7,K=$f.calculateVerticalCaret(u,a,x,I)):g===Ys.Left?(ye=a.width,K=$f.calculateVerticalCaret(u,a,x,I)):g===Ys.Top?(K=a.height,ye=$f.calculateHorizontalCaret(u,a,x,I)):g===Ys.Bottom&&(K=-7,ye=$f.calculateHorizontalCaret(u,a,x,I)),{top:K,left:ye}}static positionContent(g,a,u,x,I){let K=0,ye=0;return g===Ys.Right?(ye=u.left+u.width+x,K=$f.calculateVerticalAlignment(u,a,I)):g===Ys.Left?(ye=u.left-a.width-x,K=$f.calculateVerticalAlignment(u,a,I)):g===Ys.Top?(K=u.top-a.height-x,ye=$f.calculateHorizontalAlignment(u,a,I)):g===Ys.Bottom&&(K=u.top+u.height+x,ye=$f.calculateHorizontalAlignment(u,a,I)),{top:K,left:ye}}static determinePlacement(g,a,u,x){if($f.shouldFlip(u,a,g,x)){if(g===Ys.Right)return Ys.Left;if(g===Ys.Left)return Ys.Right;if(g===Ys.Top)return Ys.Bottom;if(g===Ys.Bottom)return Ys.Top}return g}}let ag=(()=>{class c{constructor(a,u,x){this.element=a,this.renderer=u,this.platformId=x}get cssClasses(){let a="ngx-charts-tooltip-content";return a+=` position-${this.placement}`,a+=` type-${this.type}`,a+=` ${this.cssClass}`,a}ngAfterViewInit(){setTimeout(this.position.bind(this))}position(){if(!(0,e.isPlatformBrowser)(this.platformId))return;const a=this.element.nativeElement,u=this.host.nativeElement.getBoundingClientRect();if(!u.height&&!u.width)return;const x=a.getBoundingClientRect();this.checkFlip(u,x),this.positionContent(a,u,x),this.showCaret&&this.positionCaret(u,x),setTimeout(()=>this.renderer.addClass(a,"animate"),1)}positionContent(a,u,x){const{top:I,left:K}=$f.positionContent(this.placement,x,u,this.spacing,this.alignment);this.renderer.setStyle(a,"top",`${I}px`),this.renderer.setStyle(a,"left",`${K}px`)}positionCaret(a,u){const x=this.caretElm.nativeElement,I=x.getBoundingClientRect(),{top:K,left:ye}=$f.positionCaret(this.placement,u,a,I,this.alignment);this.renderer.setStyle(x,"top",`${K}px`),this.renderer.setStyle(x,"left",`${ye}px`)}checkFlip(a,u){this.placement=$f.determinePlacement(this.placement,u,a,this.spacing)}onWindowResize(){this.position()}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-tooltip-content"]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(GD,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.caretElm=x.first)}},hostVars:2,hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("resize",function(){return u.onWindowResize()},!1,i.\u0275\u0275resolveWindow),2&a&&i.\u0275\u0275classMap(u.cssClasses)},inputs:{host:"host",showCaret:"showCaret",type:"type",placement:"placement",alignment:"alignment",spacing:"spacing",cssClass:"cssClass",title:"title",template:"template",context:"context"},decls:6,vars:6,consts:[["caretElm",""],[3,"hidden"],[1,"tooltip-content"],[4,"ngIf"],[3,"innerHTML",4,"ngIf"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"innerHTML"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"div"),i.\u0275\u0275element(1,"span",1,0),i.\u0275\u0275elementStart(3,"div",2),i.\u0275\u0275template(4,$1,2,4,"span",3)(5,KD,1,1,"span",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275classMapInterpolate1("tooltip-caret position-",u.placement,""),i.\u0275\u0275property("hidden",!u.showCaret),i.\u0275\u0275advance(3),i.\u0275\u0275property("ngIf",!u.title),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.title))},dependencies:[e.NgIf,e.NgTemplateOutlet],styles:[".ngx-charts-tooltip-content{position:fixed;border-radius:3px;z-index:5000;display:block;font-weight:400;opacity:0;pointer-events:none!important}.ngx-charts-tooltip-content.type-popover{background:#fff;color:#060709;border:1px solid #72809b;box-shadow:0 1px 3px #0003,0 1px 1px #00000024,0 2px 1px -1px #0000001f;font-size:13px;padding:4px}.ngx-charts-tooltip-content.type-popover .tooltip-caret{position:absolute;z-index:5001;width:0;height:0}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-left{border-top:7px solid transparent;border-bottom:7px solid transparent;border-left:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-right{border-top:7px solid transparent;border-bottom:7px solid transparent;border-right:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-bottom{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid #fff}.ngx-charts-tooltip-content.type-tooltip{color:#fff;background:rgba(0,0,0,.75);font-size:12px;padding:0 10px;text-align:center;pointer-events:auto}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-left{border-top:7px solid transparent;border-bottom:7px solid transparent;border-left:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-right{border-top:7px solid transparent;border-bottom:7px solid transparent;border-right:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-bottom{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content .tooltip-label{display:block;line-height:1em;padding:8px 5px 5px;font-size:1em}.ngx-charts-tooltip-content .tooltip-val{display:block;font-size:1.3em;line-height:1em;padding:0 5px 8px}.ngx-charts-tooltip-content .tooltip-caret{position:absolute;z-index:5001;width:0;height:0}.ngx-charts-tooltip-content.position-right{transform:translate(10px)}.ngx-charts-tooltip-content.position-left{transform:translate(-10px)}.ngx-charts-tooltip-content.position-top{transform:translateY(-10px)}.ngx-charts-tooltip-content.position-bottom{transform:translateY(10px)}.ngx-charts-tooltip-content.animate{opacity:1;transition:opacity .3s,transform .3s;transform:translate(0);pointer-events:auto}.area-tooltip-container{padding:5px 0;pointer-events:none}.tooltip-item{text-align:left;line-height:1.2em;padding:5px 0}.tooltip-item .tooltip-item-color{display:inline-block;height:12px;width:12px;margin-right:5px;color:#5b646b;border-radius:3px}\n"],encapsulation:2}),function Ee(c,g,a,u){var K,x=arguments.length,I=x<3?g:null===u?u=Object.getOwnPropertyDescriptor(g,a):u;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)I=Reflect.decorate(c,g,a,u);else for(var ye=c.length-1;ye>=0;ye--)(K=c[ye])&&(I=(x<3?K(I):x>3?K(g,a,I):K(g,a))||I);return x>3&&I&&Object.defineProperty(g,a,I),I}([OS(100)],c.prototype,"onWindowResize",null),c})();class $y{constructor(g){this.injectionService=g,this.defaults={},this.components=new Map}getByType(g=this.type){return this.components.get(g)}create(g){return this.createByType(this.type,g)}createByType(g,a){a=this.assignDefaults(a);const u=this.injectComponent(g,a);return this.register(g,u),u}destroy(g){const a=this.components.get(g.componentType);if(a&&a.length){const u=a.indexOf(g);u>-1&&(a[u].destroy(),a.splice(u,1))}}destroyAll(){this.destroyByType(this.type)}destroyByType(g){const a=this.components.get(g);if(a&&a.length){let u=a.length-1;for(;u>=0;)this.destroy(a[u--])}}injectComponent(g,a){return this.injectionService.appendComponent(g,a)}assignDefaults(g){const a={...this.defaults.inputs},u={...this.defaults.outputs};return!g.inputs&&!g.outputs&&(g={inputs:g}),a&&(g.inputs={...a,...g.inputs}),u&&(g.outputs={...u,...g.outputs}),g}register(g,a){this.components.has(g)||this.components.set(g,[]),this.components.get(g).push(a)}}let Sw=(()=>{class c{constructor(a,u,x){this.applicationRef=a,this.componentFactoryResolver=u,this.injector=x}static setGlobalRootViewContainer(a){c.globalRootViewContainer=a}getRootViewContainer(){if(this._container)return this._container;if(c.globalRootViewContainer)return c.globalRootViewContainer;if(this.applicationRef.components.length)return this.applicationRef.components[0];throw new Error("View Container not found! ngUpgrade needs to manually set this via setRootViewContainer or setGlobalRootViewContainer.")}setRootViewContainer(a){this._container=a}getComponentRootNode(a){return function Rb(c){return c.element}(a)?a.element.nativeElement:a.hostView&&a.hostView.rootNodes.length>0?a.hostView.rootNodes[0]:a.location.nativeElement}getRootViewContainerNode(a){return this.getComponentRootNode(a)}projectComponentBindings(a,u){if(u){if(void 0!==u.inputs){const x=Object.getOwnPropertyNames(u.inputs);for(const I of x)a.instance[I]=u.inputs[I]}if(void 0!==u.outputs){const x=Object.getOwnPropertyNames(u.outputs);for(const I of x)a.instance[I]=u.outputs[I]}}return a}appendComponent(a,u={},x){x||(x=this.getRootViewContainer());const I=this.getComponentRootNode(x),K=new Qi(I,this.componentFactoryResolver,this.applicationRef,this.injector),ye=new gn(a),Ye=K.attach(ye);return this.projectComponentBindings(Ye,u),Ye}}return c.globalRootViewContainer=null,c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275inject(i.ApplicationRef),i.\u0275\u0275inject(i.ComponentFactoryResolver),i.\u0275\u0275inject(i.Injector))},c.\u0275prov=i.\u0275\u0275defineInjectable({token:c,factory:c.\u0275fac}),c})(),b_=(()=>{class c extends $y{constructor(a){super(a),this.type=ag}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275inject(Sw))},c.\u0275prov=i.\u0275\u0275defineInjectable({token:c,factory:c.\u0275fac}),c})();var bu=function(c){return c.Right="right",c.Below="below",c}(bu||{}),Wf=function(c){return c.ScaleLegend="scaleLegend",c.Legend="legend",c}(Wf||{}),zi=function(c){return c.Time="time",c.Linear="linear",c.Ordinal="ordinal",c.Quantile="quantile",c}(zi||{});let yC=(()=>{class c{constructor(){this.horizontal=!1}ngOnChanges(a){const u=this.gradientString(this.colors.range(),this.colors.domain());this.gradient=`linear-gradient(to ${this.horizontal?"right":"bottom"}, ${u})`}gradientString(a,u){u.push(1);const x=[];return a.reverse().forEach((I,K)=>{x.push(`${I} ${Math.round(100*u[K])}%`)}),x.join(", ")}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-scale-legend"]],inputs:{valueRange:"valueRange",colors:"colors",height:"height",width:"width",horizontal:"horizontal"},features:[i.\u0275\u0275NgOnChangesFeature],decls:8,vars:10,consts:[[1,"scale-legend"],[1,"scale-legend-label"],[1,"scale-legend-wrap"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"div",0)(1,"div",1)(2,"span"),i.\u0275\u0275text(3),i.\u0275\u0275elementEnd()(),i.\u0275\u0275element(4,"div",2),i.\u0275\u0275elementStart(5,"div",1)(6,"span"),i.\u0275\u0275text(7),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275styleProp("height",u.horizontal?void 0:u.height,"px")("width",u.width,"px"),i.\u0275\u0275classProp("horizontal-legend",u.horizontal),i.\u0275\u0275advance(3),i.\u0275\u0275textInterpolate(u.valueRange[1].toLocaleString()),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("background",u.gradient),i.\u0275\u0275advance(3),i.\u0275\u0275textInterpolate(u.valueRange[0].toLocaleString()))},styles:[".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .scale-legend{text-align:center;display:flex;flex-direction:column}.chart-legend .scale-legend-wrap{display:inline-block;flex:1;width:30px;border-radius:5px;margin:0 auto}.chart-legend .scale-legend-label{font-size:12px}.chart-legend .horizontal-legend.scale-legend{flex-direction:row}.chart-legend .horizontal-legend .scale-legend-wrap{width:auto;height:30px;margin:0 16px}\n"],encapsulation:2,changeDetection:0}),c})();function nu(c){return c instanceof Date?c.toLocaleDateString():c.toLocaleString()}function Cu(c){return c.toLocaleString().replace(/[&'`"<>]/g,g=>({"&":"&","'":"'","`":"`",'"':""","<":"<",">":">"}[g]))}let Wy=(()=>{class c{constructor(){this.isActive=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.toggle=new i.EventEmitter}get trimmedLabel(){return this.formattedLabel||"(empty)"}onMouseEnter(){this.activate.emit({name:this.label})}onMouseLeave(){this.deactivate.emit({name:this.label})}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-legend-entry"]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(){return u.onMouseLeave()})},inputs:{color:"color",label:"label",formattedLabel:"formattedLabel",isActive:"isActive"},outputs:{select:"select",activate:"activate",deactivate:"deactivate",toggle:"toggle"},decls:4,vars:6,consts:[["tabindex","-1",3,"click","title"],[1,"legend-label-color",3,"click"],[1,"legend-label-text"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"span",0),i.\u0275\u0275listener("click",function(){return u.select.emit(u.formattedLabel)}),i.\u0275\u0275elementStart(1,"span",1),i.\u0275\u0275listener("click",function(){return u.toggle.emit(u.formattedLabel)}),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(2,"span",2),i.\u0275\u0275text(3),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275classProp("active",u.isActive),i.\u0275\u0275property("title",u.formattedLabel),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("background-color",u.color),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",u.trimmedLabel," "))},encapsulation:2,changeDetection:0}),c})(),ym=(()=>{class c{constructor(a){this.cd=a,this.horizontal=!1,this.labelClick=new i.EventEmitter,this.labelActivate=new i.EventEmitter,this.labelDeactivate=new i.EventEmitter,this.legendEntries=[]}ngOnChanges(a){this.update()}update(){this.cd.markForCheck(),this.legendEntries=this.getLegendEntries()}getLegendEntries(){const a=[];for(const u of this.data){const x=nu(u);-1===a.findIndex(K=>K.label===x)&&a.push({label:u,formattedLabel:x,color:this.colors.getColor(u)})}return a}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.label===x.name)}activate(a){this.labelActivate.emit(a)}deactivate(a){this.labelDeactivate.emit(a)}trackBy(a,u){return u.label}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ChangeDetectorRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-legend"]],inputs:{data:"data",title:"title",colors:"colors",height:"height",width:"width",activeEntries:"activeEntries",horizontal:"horizontal"},outputs:{labelClick:"labelClick",labelActivate:"labelActivate",labelDeactivate:"labelDeactivate"},features:[i.\u0275\u0275NgOnChangesFeature],decls:5,vars:9,consts:[["class","legend-title",4,"ngIf"],[1,"legend-wrap"],[1,"legend-labels"],["class","legend-label",4,"ngFor","ngForOf","ngForTrackBy"],[1,"legend-title"],[1,"legend-title-text"],[1,"legend-label"],[3,"select","activate","deactivate","label","formattedLabel","color","isActive"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"div"),i.\u0275\u0275template(1,mm,3,1,"header",0),i.\u0275\u0275elementStart(2,"div",1)(3,"ul",2),i.\u0275\u0275template(4,af,2,4,"li",3),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275styleProp("width",u.width,"px"),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",(null==u.title?null:u.title.length)>0),i.\u0275\u0275advance(2),i.\u0275\u0275styleProp("max-height",u.height-45,"px"),i.\u0275\u0275classProp("horizontal-legend",u.horizontal),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.legendEntries)("ngForTrackBy",u.trackBy))},dependencies:[Wy,e.NgIf,e.NgForOf],styles:[".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .legend-title{white-space:nowrap;overflow:hidden;margin-left:10px;margin-bottom:5px;font-size:14px;font-weight:700}.chart-legend ul,.chart-legend li{padding:0;margin:0;list-style:none}.chart-legend .horizontal-legend li{display:inline-block}.chart-legend .legend-wrap{width:calc(100% - 10px)}.chart-legend .legend-labels{line-height:85%;list-style:none;text-align:left;float:left;width:100%;border-radius:3px;overflow-y:auto;overflow-x:hidden;white-space:nowrap;background:rgba(0,0,0,.05)}.chart-legend .legend-label{cursor:pointer;font-size:90%;margin:8px;color:#afb7c8}.chart-legend .legend-label:hover{color:#000;transition:.2s}.chart-legend .legend-label .active .legend-label-text{color:#000}.chart-legend .legend-label-color{display:inline-block;height:15px;width:15px;margin-right:5px;color:#5b646b;border-radius:3px}.chart-legend .legend-label-text{display:inline-block;vertical-align:top;line-height:15px;font-size:12px;width:calc(100% - 20px);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.chart-legend .legend-title-text{vertical-align:bottom;display:inline-block;line-height:16px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"],encapsulation:2,changeDetection:0}),c})(),cu=(()=>{class c{constructor(){this.showLegend=!1,this.animations=!0,this.legendLabelClick=new i.EventEmitter,this.legendLabelActivate=new i.EventEmitter,this.legendLabelDeactivate=new i.EventEmitter,this.LegendPosition=bu,this.LegendType=Wf}ngOnChanges(a){this.update()}update(){let a=0;this.showLegend&&(this.legendType=this.getLegendType(),(!this.legendOptions||this.legendOptions.position===bu.Right)&&(a=this.legendType===Wf.ScaleLegend?1:2)),this.chartWidth=Math.floor(this.view[0]*(12-a)/12),this.legendWidth=this.legendOptions&&this.legendOptions.position!==bu.Right?this.chartWidth:Math.floor(this.view[0]*a/12)}getLegendType(){return this.legendOptions.scaleType===zi.Linear?Wf.ScaleLegend:Wf.Legend}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-chart"]],inputs:{view:"view",showLegend:"showLegend",legendOptions:"legendOptions",legendType:"legendType",activeEntries:"activeEntries",animations:"animations"},outputs:{legendLabelClick:"legendLabelClick",legendLabelActivate:"legendLabelActivate",legendLabelDeactivate:"legendLabelDeactivate"},features:[i.\u0275\u0275ProvidersFeature([b_]),i.\u0275\u0275NgOnChangesFeature],ngContentSelectors:vy,decls:5,vars:8,consts:[[1,"ngx-charts-outer"],[1,"ngx-charts"],["class","chart-legend",3,"horizontal","valueRange","colors","height","width",4,"ngIf"],["class","chart-legend",3,"horizontal","data","title","colors","height","width","activeEntries","labelClick","labelActivate","labelDeactivate",4,"ngIf"],[1,"chart-legend",3,"horizontal","valueRange","colors","height","width"],[1,"chart-legend",3,"labelClick","labelActivate","labelDeactivate","horizontal","data","title","colors","height","width","activeEntries"]],template:function(a,u){1&a&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275elementStart(0,"div",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"svg",1),i.\u0275\u0275projection(2),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,qD,1,5,"ngx-charts-scale-legend",2)(4,W1,1,7,"ngx-charts-legend",3),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275styleProp("width",u.view[0],"px")("height",u.view[1],"px"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.chartWidth)("height",u.view[1]),i.\u0275\u0275advance(2),i.\u0275\u0275property("ngIf",u.showLegend&&u.legendType===u.LegendType.ScaleLegend),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showLegend&&u.legendType===u.LegendType.Legend))},dependencies:[yC,ym,e.NgIf],encapsulation:2,changeDetection:0}),c})(),lg=(()=>{class c{constructor(a,u){this.element=a,this.zone=u,this.visible=new i.EventEmitter,this.isVisible=!1,this.runCheck()}destroy(){clearTimeout(this.timeout)}onVisibilityChange(){this.zone.run(()=>{this.isVisible=!0,this.visible.emit(!0)})}runCheck(){const a=()=>{if(!this.element)return;const{offsetHeight:u,offsetWidth:x}=this.element.nativeElement;u&&x?(clearTimeout(this.timeout),this.onVisibilityChange()):(clearTimeout(this.timeout),this.zone.runOutsideAngular(()=>{this.timeout=setTimeout(()=>a(),100)}))};this.zone.runOutsideAngular(()=>{this.timeout=setTimeout(()=>a())})}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.NgZone))},c.\u0275dir=i.\u0275\u0275defineDirective({type:c,selectors:[["visibility-observer"]],outputs:{visible:"visible"}}),c})();function Hh(c){return"[object Date]"===toString.call(c)}function Ew(c){return"number"==typeof c}let Wc=(()=>{class c{constructor(a,u,x,I){this.chartElement=a,this.zone=u,this.cd=x,this.platformId=I,this.scheme="cool",this.schemeType=zi.Ordinal,this.animations=!0,this.select=new i.EventEmitter}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.animations=!1)}ngAfterViewInit(){this.bindWindowResizeEvent(),this.visibilityObserver=new lg(this.chartElement,this.zone),this.visibilityObserver.visible.subscribe(this.update.bind(this))}ngOnDestroy(){this.unbindEvents(),this.visibilityObserver&&(this.visibilityObserver.visible.unsubscribe(),this.visibilityObserver.destroy())}ngOnChanges(a){this.update()}update(){if(this.results=this.results?this.cloneData(this.results):[],this.view)this.width=this.view[0],this.height=this.view[1];else{const a=this.getContainerDims();a&&(this.width=a.width,this.height=a.height)}this.width||(this.width=600),this.height||(this.height=400),this.width=Math.floor(this.width),this.height=Math.floor(this.height),this.cd&&this.cd.markForCheck()}getContainerDims(){let a,u;const x=this.chartElement.nativeElement;if((0,e.isPlatformBrowser)(this.platformId)&&null!==x.parentNode){const I=x.parentNode.getBoundingClientRect();a=I.width,u=I.height}return a&&u?{width:a,height:u}:null}formatDates(){for(let a=0;a<this.results.length;a++){const u=this.results[a];if(u.label=u.name,Hh(u.label)&&(u.label=u.label.toLocaleDateString()),u.series)for(let x=0;x<u.series.length;x++){const I=u.series[x];I.label=I.name,Hh(I.label)&&(I.label=I.label.toLocaleDateString())}}}unbindEvents(){this.resizeSubscription&&this.resizeSubscription.unsubscribe()}bindWindowResizeEvent(){if(!(0,e.isPlatformBrowser)(this.platformId))return;const u=(0,yt.fromEvent)(window,"resize").pipe((0,hn.debounceTime)(200)).subscribe(x=>{this.update(),this.cd&&this.cd.markForCheck()});this.resizeSubscription=u}cloneData(a){const u=[];for(const x of a){const I={};if(void 0!==x.name&&(I.name=x.name),void 0!==x.value&&(I.value=x.value),void 0!==x.series){I.series=[];for(const K of x.series){const ye=Object.assign({},K);I.series.push(ye)}}void 0!==x.extra&&(I.extra=JSON.parse(JSON.stringify(x.extra))),void 0!==x.source&&(I.source=x.source),void 0!==x.target&&(I.target=x.target),u.push(I)}return u}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.NgZone),i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["base-chart"]],inputs:{results:"results",view:"view",scheme:"scheme",schemeType:"schemeType",customColors:"customColors",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],decls:1,vars:0,template:function(a,u){1&a&&i.\u0275\u0275element(0,"div")},encapsulation:2}),c})();var cd=function(c){return c.Top="top",c.Bottom="bottom",c.Left="left",c.Right="right",c}(cd||{});let Hy=(()=>{class c{constructor(a){this.textHeight=25,this.margin=5,this.element=a.nativeElement}ngOnChanges(a){this.update()}update(){switch(this.strokeWidth="0.01",this.textAnchor="middle",this.transform="",this.orient){case cd.Top:case cd.Bottom:this.y=this.offset,this.x=this.width/2;break;case cd.Left:this.y=-(this.offset+this.textHeight+this.margin),this.x=-this.height/2,this.transform="rotate(270)";break;case cd.Right:this.y=this.offset+this.margin,this.x=-this.height/2,this.transform="rotate(270)"}}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-axis-label",""]],inputs:{orient:"orient",label:"label",offset:"offset",width:"width",height:"height"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:sb,decls:2,vars:6,template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text"),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("stroke-width",u.strokeWidth)("x",u.x)("y",u.y)("text-anchor",u.textAnchor)("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",u.label," "))},encapsulation:2,changeDetection:0}),c})();function cg(c,g=16){return"string"!=typeof c?"number"==typeof c?c+"":"":(c=c.trim()).length<=g?c:`${c.slice(0,g)}...`}function hh(c,g){if(c.length>g){const a=[],u=Math.floor(c.length/g);for(let x=0;x<c.length;x++)x%u==0&&a.push(c[x]);c=a}return c}function Hf(c,g,a){const u=(c||"").toString();let x=[];if(/\s/.test(u))x=u.split(/\s+/).reduce((I,K)=>{const ye=(I.pop()||"")+" ";return ye.length+K.length>g?[...I,ye.trim(),K.trim()]:[...I,ye+K]},[]);else{let I=0;for(;I<u.length;)x.push(u.substring(I,I+g)),I+=g}return x.length>a&&(x=x.splice(0,a),x[x.length-1]+="..."),x}var Nd=function(c){return c.Start="start",c.Middle="middle",c.End="end",c}(Nd||{});let C_=(()=>{class c{constructor(a){this.platformId=a,this.tickArguments=[5],this.tickStroke="#ccc",this.trimTicks=!0,this.maxTickLength=16,this.showGridLines=!1,this.rotateTicks=!0,this.wrapTicks=!1,this.dimensionsChanged=new i.EventEmitter,this.verticalSpacing=20,this.rotateLabels=!1,this.innerTickSize=6,this.outerTickSize=6,this.tickPadding=3,this.textAnchor=Nd.Middle,this.maxTicksLength=0,this.maxAllowedLength=16,this.height=0,this.approxHeight=10,this.maxPossibleLengthForTickIfWrapped=16}get isWrapTicksSupported(){return this.wrapTicks&&this.scale.step}ngOnChanges(a){this.update()}ngAfterViewInit(){setTimeout(()=>this.updateDims())}updateDims(){if(!(0,e.isPlatformBrowser)(this.platformId))return void this.dimensionsChanged.emit({height:this.approxHeight});const a=parseInt(this.ticksElement.nativeElement.getBoundingClientRect().height,10);a!==this.height&&(this.height=a,this.dimensionsChanged.emit({height:this.height}),setTimeout(()=>this.updateDims()))}update(){const a=this.scale;this.ticks=this.getTicks(),this.tickFormat=this.tickFormatting?this.tickFormatting:a.tickFormat?a.tickFormat.apply(a,this.tickArguments):function(x){return"Date"===x.constructor.name?x.toLocaleDateString():x.toLocaleString()};const u=this.rotateTicks?this.getRotationAngle(this.ticks):null;this.adjustedScale=this.scale.bandwidth?function(x){return this.scale(x)+.5*this.scale.bandwidth()}:this.scale,this.textTransform="",u&&0!==u?(this.textTransform=`rotate(${u})`,this.textAnchor=Nd.End,this.verticalSpacing=10):this.textAnchor=Nd.Middle,setTimeout(()=>this.updateDims())}getRotationAngle(a){let u=0;this.maxTicksLength=0;for(let Vt=0;Vt<a.length;Vt++){const zt=this.tickFormat(a[Vt]).toString();let yn=zt.length;this.trimTicks&&(yn=this.tickTrim(zt).length),yn>this.maxTicksLength&&(this.maxTicksLength=yn)}const K=7*Math.min(this.maxTicksLength,this.maxAllowedLength);let ye=K;const Ye=Math.floor(this.width/a.length);for(;ye>Ye&&u>-90;)u-=30,ye=Math.cos(u*(Math.PI/180))*K;let $e=14;if(this.isWrapTicksSupported){const Vt=this.ticks.reduce((yn,li)=>li.length>yn.length?li:yn,"");$e=14*(this.tickChunks(Vt).length||1),this.maxPossibleLengthForTickIfWrapped=this.getMaxPossibleLengthForTick(Vt)}const ht=0!==u?Math.max(Math.abs(Math.sin(u*Math.PI/180))*this.maxTickLength*7,10):$e;return this.approxHeight=Math.min(ht,200),u}getTicks(){let a;const u=this.getMaxTicks(20),x=this.getMaxTicks(100);return this.tickValues?a=this.tickValues:this.scale.ticks?a=this.scale.ticks.apply(this.scale,[x]):(a=this.scale.domain(),a=hh(a,u)),a}getMaxTicks(a){return Math.floor(this.width/a)}tickTransform(a){return"translate("+this.adjustedScale(a)+","+this.verticalSpacing+")"}gridLineTransform(){return`translate(0,${-this.verticalSpacing-5})`}tickTrim(a){return this.trimTicks?cg(a,this.maxTickLength):a}getMaxPossibleLengthForTick(a){if(this.scale.bandwidth){const x=Math.floor(this.scale.bandwidth()/7),I=a.slice(0,x);return Math.max(I.length,this.maxTickLength)}return this.maxTickLength}tickChunks(a){if(a.toString().length>this.maxTickLength&&this.scale.bandwidth){let x=this.rotateTicks?Math.floor(this.scale.step()/14):5;if(x<=1)return[this.tickTrim(a)];let I=Math.max(this.maxPossibleLengthForTickIfWrapped,this.maxTickLength);return(0,e.isPlatformBrowser)(this.platformId)||(I=Math.floor(Math.min(this.approxHeight/5,Math.max(this.maxPossibleLengthForTickIfWrapped,this.maxTickLength)))),x=Math.min(x,5),Hf(a,I,x<1?1:x)}return[this.tickTrim(a)]}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-x-axis-ticks",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(ab,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.ticksElement=x.first)}},inputs:{scale:"scale",orient:"orient",tickArguments:"tickArguments",tickValues:"tickValues",tickStroke:"tickStroke",trimTicks:"trimTicks",maxTickLength:"maxTickLength",tickFormatting:"tickFormatting",showGridLines:"showGridLines",gridLineHeight:"gridLineHeight",width:"width",rotateTicks:"rotateTicks",wrapTicks:"wrapTicks"},outputs:{dimensionsChanged:"dimensionsChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:H1,decls:4,vars:2,consts:[["ticksel",""],["tmplMultilineTick",""],["tmplSinglelineTick",""],["class","tick",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],[1,"tick"],[4,"ngIf"],["stroke-width","0.01","font-size","12px"],[4,"ngIf","ngIfThen","ngIfElse"],["x","0",4,"ngFor","ngForOf"],["x","0"],["y2","0",1,"gridline-path","gridline-path-vertical"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",null,0),i.\u0275\u0275template(2,jf,2,2,"g",3),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,K1,2,2,"g",4)),2&a&&(i.\u0275\u0275advance(2),i.\u0275\u0275property("ngForOf",u.ticks),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.ticks))},dependencies:[e.NgForOf,e.NgIf],encapsulation:2,changeDetection:0}),c})(),lf=(()=>{class c{constructor(){this.rotateTicks=!0,this.showGridLines=!1,this.xOrient=cd.Bottom,this.xAxisOffset=0,this.wrapTicks=!1,this.dimensionsChanged=new i.EventEmitter,this.xAxisClassName="x axis",this.labelOffset=0,this.fill="none",this.stroke="stroke",this.tickStroke="#ccc",this.strokeWidth="none",this.padding=5,this.orientation=cd}ngOnChanges(a){this.update()}update(){this.transform=`translate(0,${this.xAxisOffset+this.padding+this.dims.height})`,typeof this.xAxisTickCount<"u"&&(this.tickArguments=[this.xAxisTickCount])}emitTicksHeight({height:a}){const u=a+25+5;u!==this.labelOffset&&(this.labelOffset=u,setTimeout(()=>{this.dimensionsChanged.emit({height:a})},0))}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-x-axis",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(C_,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.ticksComponent=x.first)}},inputs:{xScale:"xScale",dims:"dims",trimTicks:"trimTicks",rotateTicks:"rotateTicks",maxTickLength:"maxTickLength",tickFormatting:"tickFormatting",showGridLines:"showGridLines",showLabel:"showLabel",labelText:"labelText",ticks:"ticks",xAxisTickCount:"xAxisTickCount",xOrient:"xOrient",xAxisOffset:"xAxisOffset",wrapTicks:"wrapTicks"},outputs:{dimensionsChanged:"dimensionsChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:VM,decls:3,vars:4,consts:[["ngx-charts-x-axis-ticks","",3,"trimTicks","rotateTicks","maxTickLength","tickFormatting","tickArguments","tickStroke","scale","orient","showGridLines","gridLineHeight","width","tickValues","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width",4,"ngIf"],["ngx-charts-x-axis-ticks","",3,"dimensionsChanged","trimTicks","rotateTicks","maxTickLength","tickFormatting","tickArguments","tickStroke","scale","orient","showGridLines","gridLineHeight","width","tickValues","wrapTicks"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,YD,1,13,"g",0)(2,q1,1,5,"g",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("class",u.xAxisClassName)("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xScale),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showLabel))},dependencies:[C_,Hy,e.NgIf],encapsulation:2,changeDetection:0}),c})();function bm(c,g,a,u,x,[I,K,ye,Ye]){let $e="";return $e=`M${[c+x,g]}`,$e+="h"+((a=0===(a=Math.floor(a))?1:a)-2*x),$e+=K?`a${[x,x]} 0 0 1 ${[x,x]}`:`h${x}v${x}`,$e+="v"+((u=0===(u=Math.floor(u))?1:u)-2*x),$e+=Ye?`a${[x,x]} 0 0 1 ${[-x,x]}`:`v${x}h${-x}`,$e+="h"+(2*x-a),$e+=ye?`a${[x,x]} 0 0 1 ${[-x,-x]}`:`h${-x}v${-x}`,$e+="v"+(2*x-u),$e+=I?`a${[x,x]} 0 0 1 ${[x,-x]}`:`v${-x}h${x}`,$e+="z",$e}let zy=(()=>{class c{constructor(a){this.platformId=a,this.tickArguments=[5],this.tickStroke="#ccc",this.trimTicks=!0,this.maxTickLength=16,this.showGridLines=!1,this.showRefLabels=!1,this.showRefLines=!1,this.wrapTicks=!1,this.dimensionsChanged=new i.EventEmitter,this.innerTickSize=6,this.tickPadding=3,this.verticalSpacing=20,this.textAnchor=Nd.Middle,this.width=0,this.outerTickSize=6,this.rotateLabels=!1,this.referenceLineLength=0,this.Orientation=cd}ngOnChanges(a){this.update()}ngAfterViewInit(){setTimeout(()=>this.updateDims())}updateDims(){if(!(0,e.isPlatformBrowser)(this.platformId))return this.width=this.getApproximateAxisWidth(),void this.dimensionsChanged.emit({width:this.width});const a=parseInt(this.ticksElement.nativeElement.getBoundingClientRect().width,10);a!==this.width&&(this.width=a,this.dimensionsChanged.emit({width:a}),setTimeout(()=>this.updateDims()))}update(){const a=this.scale,u=this.orient===cd.Top||this.orient===cd.Right?-1:1;switch(this.tickSpacing=Math.max(this.innerTickSize,0)+this.tickPadding,this.ticks=this.getTicks(),this.tickFormat=this.tickFormatting?this.tickFormatting:a.tickFormat?a.tickFormat.apply(a,this.tickArguments):function(x){return"Date"===x.constructor.name?x.toLocaleDateString():x.toLocaleString()},this.adjustedScale=a.bandwidth?x=>{const I=a(x)+.5*a.bandwidth();if(this.wrapTicks&&x.toString().length>this.maxTickLength){const K=this.tickChunks(x).length;if(1===K)return I;const $e=.5*a.bandwidth()-8*K*.5;return a(x)+$e}return I}:a,this.showRefLines&&this.referenceLines&&this.setReferencelines(),this.orient){case cd.Top:case cd.Bottom:this.transform=function(x){return"translate("+this.adjustedScale(x)+",0)"},this.textAnchor=Nd.Middle,this.y2=this.innerTickSize*u,this.y1=this.tickSpacing*u,this.dy=u<0?"0em":".71em";break;case cd.Left:this.transform=function(x){return"translate(0,"+this.adjustedScale(x)+")"},this.textAnchor=Nd.End,this.x2=this.innerTickSize*-u,this.x1=this.tickSpacing*-u,this.dy=".32em";break;case cd.Right:this.transform=function(x){return"translate(0,"+this.adjustedScale(x)+")"},this.textAnchor=Nd.Start,this.x2=this.innerTickSize*-u,this.x1=this.tickSpacing*-u,this.dy=".32em"}setTimeout(()=>this.updateDims())}setReferencelines(){this.refMin=this.adjustedScale(Math.min.apply(null,this.referenceLines.map(a=>a.value))),this.refMax=this.adjustedScale(Math.max.apply(null,this.referenceLines.map(a=>a.value))),this.referenceLineLength=this.referenceLines.length,this.referenceAreaPath=bm(0,this.refMax,this.gridLineWidth,this.refMin-this.refMax,0,[!1,!1,!1,!1])}getTicks(){let a;const u=this.getMaxTicks(20),x=this.getMaxTicks(50);return this.tickValues?a=this.tickValues:this.scale.ticks?a=this.scale.ticks.apply(this.scale,[x]):(a=this.scale.domain(),a=hh(a,u)),a}getMaxTicks(a){return Math.floor(this.height/a)}tickTransform(a){return`translate(${this.adjustedScale(a)},${this.verticalSpacing})`}gridLineTransform(){return"translate(5,0)"}tickTrim(a){return this.trimTicks?cg(a,this.maxTickLength):a}getApproximateAxisWidth(){return 7*Math.max(...this.ticks.map(x=>this.tickTrim(this.tickFormat(x)).length))}tickChunks(a){if(a.toString().length>this.maxTickLength&&this.scale.bandwidth){const u=this.maxTickLength,x=Math.floor(this.scale.bandwidth()/15);return x<=1?[this.tickTrim(a)]:Hf(a,u,Math.min(x,5))}return[this.tickFormat(a)]}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-y-axis-ticks",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(ab,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.ticksElement=x.first)}},inputs:{scale:"scale",orient:"orient",tickArguments:"tickArguments",tickValues:"tickValues",tickStroke:"tickStroke",trimTicks:"trimTicks",maxTickLength:"maxTickLength",tickFormatting:"tickFormatting",showGridLines:"showGridLines",gridLineWidth:"gridLineWidth",height:"height",referenceLines:"referenceLines",showRefLabels:"showRefLabels",showRefLines:"showRefLines",wrapTicks:"wrapTicks"},outputs:{dimensionsChanged:"dimensionsChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:QE,decls:6,vars:4,consts:[["ticksel",""],["tmplMultilineTick",""],["tmplSinglelineTick",""],["class","tick",4,"ngFor","ngForOf"],["class","reference-area",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"tick"],[4,"ngIf"],["stroke-width","0.01"],[4,"ngIf","ngIfThen","ngIfElse"],[4,"ngIf","ngIfElse"],["x","0",4,"ngFor","ngForOf"],["x","0"],[1,"reference-area"],["class","gridline-path gridline-path-horizontal","x1","0",4,"ngIf"],["x1","0",1,"gridline-path","gridline-path-horizontal"],["x1","0",1,"refline-path","gridline-path-horizontal"],[1,"refline-label"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",null,0),i.\u0275\u0275template(2,rS,2,2,"g",3),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,ew,1,2,"path",4)(4,Zg,2,2,"g",5)(5,nw,2,1,"g",5)),2&a&&(i.\u0275\u0275advance(2),i.\u0275\u0275property("ngForOf",u.ticks),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.referenceLineLength>1&&u.refMax&&u.refMin&&u.showRefLines),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.ticks),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.referenceLines))},dependencies:[e.NgForOf,e.NgIf],encapsulation:2,changeDetection:0}),c})(),xf=(()=>{class c{constructor(){this.showGridLines=!1,this.yOrient=cd.Left,this.yAxisOffset=0,this.wrapTicks=!1,this.dimensionsChanged=new i.EventEmitter,this.yAxisClassName="y axis",this.labelOffset=15,this.fill="none",this.stroke="#CCC",this.tickStroke="#CCC",this.strokeWidth=1,this.padding=5}ngOnChanges(a){this.update()}update(){this.offset=-(this.yAxisOffset+this.padding),this.yOrient===cd.Right?(this.labelOffset=65,this.transform=`translate(${this.offset+this.dims.width} , 0)`):this.transform=`translate(${this.offset} , 0)`,void 0!==this.yAxisTickCount&&(this.tickArguments=[this.yAxisTickCount])}emitTicksWidth({width:a}){a!==this.labelOffset&&this.yOrient===cd.Right?(this.labelOffset=a+this.labelOffset,setTimeout(()=>{this.dimensionsChanged.emit({width:a})},0)):a!==this.labelOffset&&(this.labelOffset=a,setTimeout(()=>{this.dimensionsChanged.emit({width:a})},0))}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-y-axis",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(zy,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.ticksComponent=x.first)}},inputs:{yScale:"yScale",dims:"dims",trimTicks:"trimTicks",maxTickLength:"maxTickLength",tickFormatting:"tickFormatting",ticks:"ticks",showGridLines:"showGridLines",showLabel:"showLabel",labelText:"labelText",yAxisTickCount:"yAxisTickCount",yOrient:"yOrient",referenceLines:"referenceLines",showRefLines:"showRefLines",showRefLabels:"showRefLabels",yAxisOffset:"yAxisOffset",wrapTicks:"wrapTicks"},outputs:{dimensionsChanged:"dimensionsChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Y1,decls:3,vars:4,consts:[["ngx-charts-y-axis-ticks","",3,"trimTicks","maxTickLength","tickFormatting","tickArguments","tickValues","tickStroke","scale","orient","showGridLines","gridLineWidth","referenceLines","showRefLines","showRefLabels","height","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width",4,"ngIf"],["ngx-charts-y-axis-ticks","",3,"dimensionsChanged","trimTicks","maxTickLength","tickFormatting","tickArguments","tickValues","tickStroke","scale","orient","showGridLines","gridLineWidth","referenceLines","showRefLines","showRefLabels","height","wrapTicks"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,qm,1,15,"g",0)(2,db,1,5,"g",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("class",u.yAxisClassName)("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yScale),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showLabel))},dependencies:[zy,Hy,e.NgIf],encapsulation:2,changeDetection:0}),c})(),Tw=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[e.CommonModule]]}),c})();var Ju=function(c){return c.popover="popover",c.tooltip="tooltip",c}(Ju||{}),D_=function(c){return c[c.all="all"]="all",c[c.focus="focus"]="focus",c[c.mouseover="mouseover"]="mouseover",c}(D_||{});let Hp=(()=>{class c{constructor(a,u,x){this.tooltipService=a,this.viewContainerRef=u,this.renderer=x,this.tooltipCssClass="",this.tooltipAppendToBody=!0,this.tooltipSpacing=10,this.tooltipDisabled=!1,this.tooltipShowCaret=!0,this.tooltipPlacement=Ys.Top,this.tooltipAlignment=Ys.Center,this.tooltipType=Ju.popover,this.tooltipCloseOnClickOutside=!0,this.tooltipCloseOnMouseLeave=!0,this.tooltipHideTimeout=300,this.tooltipShowTimeout=100,this.tooltipShowEvent=D_.all,this.tooltipImmediateExit=!1,this.show=new i.EventEmitter,this.hide=new i.EventEmitter}get listensForFocus(){return this.tooltipShowEvent===D_.all||this.tooltipShowEvent===D_.focus}get listensForHover(){return this.tooltipShowEvent===D_.all||this.tooltipShowEvent===D_.mouseover}ngOnDestroy(){this.hideTooltip(!0)}onFocus(){this.listensForFocus&&this.showTooltip()}onBlur(){this.listensForFocus&&this.hideTooltip(!0)}onMouseEnter(){this.listensForHover&&this.showTooltip()}onMouseLeave(a){if(this.listensForHover&&this.tooltipCloseOnMouseLeave){if(clearTimeout(this.timeout),this.component&&this.component.instance.element.nativeElement.contains(a))return;this.hideTooltip(this.tooltipImmediateExit)}}onMouseClick(){this.listensForHover&&this.hideTooltip(!0)}showTooltip(a){if(this.component||this.tooltipDisabled)return;const u=a?0:this.tooltipShowTimeout+(navigator.userAgent.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/)?400:0);clearTimeout(this.timeout),this.timeout=setTimeout(()=>{this.tooltipService.destroyAll();const x=this.createBoundOptions();this.component=this.tooltipService.create(x),setTimeout(()=>{this.component&&this.addHideListeners(this.component.instance.element.nativeElement)},10),this.show.emit(!0)},u)}addHideListeners(a){this.mouseEnterContentEvent=this.renderer.listen(a,"mouseenter",()=>{clearTimeout(this.timeout)}),this.tooltipCloseOnMouseLeave&&(this.mouseLeaveContentEvent=this.renderer.listen(a,"mouseleave",()=>{this.hideTooltip(this.tooltipImmediateExit)})),this.tooltipCloseOnClickOutside&&(this.documentClickEvent=this.renderer.listen("window","click",u=>{a.contains(u.target)||this.hideTooltip()}))}hideTooltip(a=!1){if(!this.component)return;const u=()=>{this.mouseLeaveContentEvent&&this.mouseLeaveContentEvent(),this.mouseEnterContentEvent&&this.mouseEnterContentEvent(),this.documentClickEvent&&this.documentClickEvent(),this.hide.emit(!0),this.tooltipService.destroy(this.component),this.component=void 0};clearTimeout(this.timeout),a?u():this.timeout=setTimeout(u,this.tooltipHideTimeout)}createBoundOptions(){return{title:this.tooltipTitle,template:this.tooltipTemplate,host:this.viewContainerRef.element,placement:this.tooltipPlacement,alignment:this.tooltipAlignment,type:this.tooltipType,showCaret:this.tooltipShowCaret,cssClass:this.tooltipCssClass,spacing:this.tooltipSpacing,context:this.tooltipContext}}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(b_),i.\u0275\u0275directiveInject(i.ViewContainerRef),i.\u0275\u0275directiveInject(i.Renderer2))},c.\u0275dir=i.\u0275\u0275defineDirective({type:c,selectors:[["","ngx-tooltip",""]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("focusin",function(){return u.onFocus()})("blur",function(){return u.onBlur()})("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(I){return u.onMouseLeave(I.target)})("click",function(){return u.onMouseClick()})},inputs:{tooltipCssClass:"tooltipCssClass",tooltipTitle:"tooltipTitle",tooltipAppendToBody:"tooltipAppendToBody",tooltipSpacing:"tooltipSpacing",tooltipDisabled:"tooltipDisabled",tooltipShowCaret:"tooltipShowCaret",tooltipPlacement:"tooltipPlacement",tooltipAlignment:"tooltipAlignment",tooltipType:"tooltipType",tooltipCloseOnClickOutside:"tooltipCloseOnClickOutside",tooltipCloseOnMouseLeave:"tooltipCloseOnMouseLeave",tooltipHideTimeout:"tooltipHideTimeout",tooltipShowTimeout:"tooltipShowTimeout",tooltipTemplate:"tooltipTemplate",tooltipShowEvent:"tooltipShowEvent",tooltipContext:"tooltipContext",tooltipImmediateExit:"tooltipImmediateExit"},outputs:{show:"show",hide:"hide"}}),c})(),Gy=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({providers:[Sw,b_],imports:[[e.CommonModule]]}),c})();const Ky={};function Gu(){let c=("0000"+(Math.random()*Math.pow(36,4)|0).toString(36)).slice(-4);return c=`a${c}`,Ky[c]?Gu():(Ky[c]=!0,c)}var Jl=function(c){return c.Vertical="vertical",c.Horizontal="horizontal",c}(Jl||{});let ug=(()=>{class c{constructor(){this.orientation=Jl.Vertical}ngOnChanges(a){this.x1="0%",this.x2="0%",this.y1="0%",this.y2="0%",this.orientation===Jl.Horizontal?this.x2="100%":this.orientation===Jl.Vertical&&(this.y1="100%")}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-svg-linear-gradient",""]],inputs:{orientation:"orientation",name:"name",stops:"stops"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:XE,decls:2,vars:6,consts:[[3,"id"],[3,"stop-color","stop-opacity",4,"ngFor","ngForOf"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"linearGradient",0),i.\u0275\u0275template(1,ZE,1,5,"stop",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("id",u.name),i.\u0275\u0275attribute("x1",u.x1)("y1",u.y1)("x2",u.x2)("y2",u.y2),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.stops))},dependencies:[e.NgForOf],encapsulation:2,changeDetection:0}),c})(),qy=(()=>{class c{constructor(){this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter}onClick(){this.select.emit(this.data)}onMouseEnter(){this.activate.emit(this.data)}onMouseLeave(){this.deactivate.emit(this.data)}ngOnChanges(a){this.classNames=Array.isArray(this.classNames)?this.classNames.join(" "):"",this.classNames+="circle"}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-circle",""]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("click",function(){return u.onClick()})("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(){return u.onMouseLeave()})},inputs:{cx:"cx",cy:"cy",r:"r",fill:"fill",stroke:"stroke",data:"data",classNames:"classNames",circleOpacity:"circleOpacity",pointerEvents:"pointerEvents"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:oS,decls:1,vars:8,template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"circle")),2&a&&i.\u0275\u0275attribute("cx",u.cx)("cy",u.cy)("r",u.r)("fill",u.fill)("stroke",u.stroke)("opacity",u.circleOpacity)("class",u.classNames)("pointer-events",u.pointerEvents)},encapsulation:2,changeDetection:0}),c})();var zh=function(c){return c.Standard="standard",c.Stacked="stacked",c}(zh||{});let cv=(()=>{class c{constructor(a){this.platformId=a,this.type=zh.Standard,this.tooltipDisabled=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.barVisible=!1,this.barOrientation=Jl,this.placementTypes=Ys,this.styleTypes=Ju,this.isSSR=!1}ngOnInit(){this.gradientId="grad"+Gu().toString(),this.gradientFill=`url(#${this.gradientId})`,(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}ngOnChanges(){this.update()}update(){this.circle=this.getActiveCircle()}getActiveCircle(){const a=this.data.series.findIndex(u=>{const x=u.name;return x&&this.visibleValue&&x.toString()===this.visibleValue.toString()&&void 0!==u.value});if(-1!==a)return this.mapDataPointToCircle(this.data.series[a],a)}mapDataPointToCircle(a,u){const x=this.data.name,I=a.value,K=a.name,ye=nu(K);let Ye;Ye=this.xScale(this.scaleType===zi.Time?K:this.scaleType===zi.Linear?Number(K):K);const $e=this.yScale(this.type===zh.Standard?I:a.d1),Vt=this.yScale.range()[0]-$e;let yn;return yn=this.colors.getColor(this.colors.scaleType===zi.Linear?this.type===zh.Standard?I:a.d1:x),{classNames:[`circle-data-${u}`],value:I,label:K,data:Object.assign({},a,{series:x,value:I,name:K}),cx:Ye,cy:$e,radius:5,height:Vt,tooltipLabel:ye,color:yn,opacity:1,seriesName:x,gradientStops:this.getGradientStops(yn),min:a.min,max:a.max}}getTooltipText({tooltipLabel:a,value:u,seriesName:x,min:I,max:K}){return`\n <span class="tooltip-label">${Cu(x)} \u2022 ${Cu(a)}</span>\n <span class="tooltip-val">${u.toLocaleString()}${this.getTooltipMinMaxText(I,K)}</span>\n `}getTooltipMinMaxText(a,u){if(void 0!==a||void 0!==u){let x=" (";return void 0!==a?(void 0===u&&(x+="\u2265"),x+=a.toLocaleString(),void 0!==u&&(x+=" - ")):void 0!==u&&(x+="\u2264"),void 0!==u&&(x+=u.toLocaleString()),x+=")",x}return""}getGradientStops(a){return[{offset:0,color:a,opacity:.2},{offset:100,color:a,opacity:1}]}onClick(a){this.select.emit(a)}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name)}activateCircle(){this.barVisible=!0,this.activate.emit({name:this.data.name})}deactivateCircle(){this.barVisible=!1,this.circle.opacity=0,this.deactivate.emit({name:this.data.name})}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-circle-series",""]],inputs:{data:"data",type:"type",xScale:"xScale",yScale:"yScale",colors:"colors",scaleType:"scaleType",visibleValue:"visibleValue",activeEntries:"activeEntries",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Qm,decls:1,vars:1,consts:[[4,"ngIf"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"],["class","tooltip-bar",4,"ngIf"],["ngx-charts-circle","","ngx-tooltip","",1,"circle",3,"select","activate","deactivate","cx","cy","r","fill","pointerEvents","data","classNames","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"],[1,"tooltip-bar"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,fh,6,22,"g",0),2&a&&i.\u0275\u0275property("ngIf",u.circle)},dependencies:[ug,qy,e.NgIf,Hp],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":enter",[(0,Gt.style)({opacity:0}),(0,Gt.animate)(250,(0,Gt.style)({opacity:1}))])])]},changeDetection:0}),c})(),Mw=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-grid-panel",""]],inputs:{width:"width",height:"height",x:"x",y:"y"},attrs:Vh,decls:1,vars:4,consts:[["stroke","none",1,"gridpanel"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"rect",0)),2&a&&i.\u0275\u0275attribute("height",u.height)("width",u.width)("x",u.x)("y",u.y)},encapsulation:2,changeDetection:0}),c})();var w_=function(c){return c.Odd="odd",c.Even="even",c}(w_||{});let dg=(()=>{class c{ngOnChanges(a){this.update()}update(){this.gridPanels=this.getGridPanels()}getGridPanels(){return this.data.map(a=>{let u,x,I,K,ye,Ye=w_.Odd;if(this.orient===Jl.Vertical){const $e=this.xScale(a.name);Number.parseInt(($e/this.xScale.step()).toString(),10)%2==1&&(Ye=w_.Even),u=this.xScale.bandwidth()*this.xScale.paddingInner(),x=this.xScale.bandwidth()+u,I=this.dims.height,K=this.xScale(a.name)-u/2,ye=0}else if(this.orient===Jl.Horizontal){const $e=this.yScale(a.name);Number.parseInt(($e/this.yScale.step()).toString(),10)%2==1&&(Ye=w_.Even),u=this.yScale.bandwidth()*this.yScale.paddingInner(),x=this.dims.width,I=this.yScale.bandwidth()+u,K=0,ye=this.yScale(a.name)-u/2}return{name:a.name,class:Ye,height:I,width:x,x:K,y:ye}})}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-grid-panel-series",""]],inputs:{data:"data",dims:"dims",xScale:"xScale",yScale:"yScale",orient:"orient"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Jg,decls:1,vars:1,consts:[["ngx-charts-grid-panel","",3,"height","width","x","y","grid-panel","odd","even",4,"ngFor","ngForOf"],["ngx-charts-grid-panel","",3,"height","width","x","y"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,aS,1,10,"g",0),2&a&&i.\u0275\u0275property("ngForOf",u.gridPanels)},dependencies:[Mw,e.NgForOf],encapsulation:2,changeDetection:0}),c})(),uv=(()=>{class c{constructor(){this.endOpacity=1,this.cx=0,this.cy=0}get stops(){return this.stopsInput||this.stopsDefault}set stops(a){this.stopsInput=a}ngOnChanges(a){this.r="30%",("color"in a||"startOpacity"in a||"endOpacity"in a)&&(this.stopsDefault=[{offset:0,color:this.color,opacity:this.startOpacity},{offset:100,color:this.color,opacity:this.endOpacity}])}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-svg-radial-gradient",""]],inputs:{color:"color",name:"name",startOpacity:"startOpacity",endOpacity:"endOpacity",cx:"cx",cy:"cy",stops:"stops"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:by,decls:2,vars:5,consts:[["gradientUnits","userSpaceOnUse",3,"id"],[3,"stop-color","stop-opacity",4,"ngFor","ngForOf"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"radialGradient",0),i.\u0275\u0275template(1,l_,1,5,"stop",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("id",u.name),i.\u0275\u0275attribute("cx",u.cx)("cy",u.cy)("r",u.r),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.stops))},dependencies:[e.NgForOf],encapsulation:2,changeDetection:0}),c})(),fg=(()=>{class c{constructor(a){this.opacity=1,this.startOpacity=.5,this.endOpacity=1,this.gradient=!1,this.animations=!0,this.select=new i.EventEmitter,this.animationsLoaded=!1,this.hasGradient=!1,this.barOrientation=Jl,this.element=a.nativeElement}ngOnChanges(){this.update(),this.animationsLoaded||(this.loadAnimation(),this.animationsLoaded=!0)}update(){this.gradientId="grad"+Gu().toString(),this.gradientFill=`url(#${this.gradientId})`,this.gradient||this.stops?(this.gradientStops=this.getGradient(),this.hasGradient=!0):this.hasGradient=!1,this.updatePathEl()}loadAnimation(){this.areaPath=this.startingPath,setTimeout(this.updatePathEl.bind(this),100)}updatePathEl(){const a=ta(this.element).select(".area");this.animations?a.transition().duration(750).attr("d",this.path):a.attr("d",this.path)}getGradient(){return this.stops?this.stops:[{offset:0,color:this.fill,opacity:this.startOpacity},{offset:100,color:this.fill,opacity:this.endOpacity}]}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-area",""]],inputs:{data:"data",path:"path",startingPath:"startingPath",fill:"fill",opacity:"opacity",startOpacity:"startOpacity",endOpacity:"endOpacity",gradient:"gradient",stops:"stops",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:X1,decls:2,vars:5,consts:[[4,"ngIf"],[1,"area"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"]],template:function(a,u){1&a&&(i.\u0275\u0275template(0,gm,2,3,"defs",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(1,"path",1)),2&a&&(i.\u0275\u0275property("ngIf",u.gradient),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("opacity",u.opacity),i.\u0275\u0275attribute("d",u.areaPath)("fill",u.gradient?u.gradientFill:u.fill))},dependencies:[ug,e.NgIf],encapsulation:2,changeDetection:0}),c})();function Qy(c,g,a,u){return a*(1-Math.pow(2,-10*c/u))*1024/1023+g}function bC(c,g,a,u,x){const I=Number(c),K=Number(g),ye=I>K,Ye=Math.max(0,a),$e=Math.pow(10,Ye),ht=1e3*Number(u);let Vt;function zt(yn){let li;const pr=yn-Vt;li=ye?I-Qy(pr,0,I-K,ht):Qy(pr,I,K-I,ht),li=ye?li<K?K:li:li>K?K:li,li=Math.round(li*$e)/$e;const si=pr<ht;if(x({value:li,progress:pr,timestamp:yn,finished:!si}),si)return requestAnimationFrame(hr=>zt(hr))}return requestAnimationFrame(yn=>(Vt=yn,zt(yn)))}function pg(c){const g=Number(c);return g%1!=0&&Math.abs(g)<=10?2:0}let CC,Gh=(()=>{class c{constructor(a,u){this.cd=a,this.countDuration=1,this.countPrefix="",this.countSuffix="",this.countChange=new i.EventEmitter,this.countFinish=new i.EventEmitter,this.value="",this._countDecimals=0,this._countTo=0,this._countFrom=0,this.nativeElement=u.nativeElement}set countDecimals(a){this._countDecimals=a}get countDecimals(){return this._countDecimals?this._countDecimals:pg(this.countTo)}set countTo(a){this._countTo=parseFloat(a),this.start()}get countTo(){return this._countTo}set countFrom(a){this._countFrom=parseFloat(a),this.start()}get countFrom(){return this._countFrom}ngOnDestroy(){cancelAnimationFrame(this.animationReq)}start(){cancelAnimationFrame(this.animationReq);const a=this.valueFormatting||(x=>`${this.countPrefix}${x.toLocaleString()}${this.countSuffix}`);this.animationReq=bC(this.countFrom,this.countTo,this.countDecimals,this.countDuration,({value:x,progress:I,finished:K})=>{this.value=a(x),this.cd.markForCheck(),K||this.countChange.emit({value:this.value,progress:I}),K&&this.countFinish.emit({value:this.value,progress:I})})}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["","ngx-charts-count-up",""]],inputs:{countDuration:"countDuration",countPrefix:"countPrefix",countSuffix:"countSuffix",valueFormatting:"valueFormatting",countDecimals:"countDecimals",countTo:"countTo",countFrom:"countFrom"},outputs:{countChange:"countChange",countFinish:"countFinish"},attrs:fb,decls:1,vars:1,template:function(a,u){1&a&&i.\u0275\u0275text(0),2&a&&i.\u0275\u0275textInterpolate1(" ",u.value," ")},encapsulation:2}),c})();typeof window<"u"?CC=window:typeof global<"u"&&(CC=global);const NS=CC.MouseEvent;function ud(c,g=!1,a=!0){if("function"==typeof NS)return new NS(c,{bubbles:g,cancelable:a});{const u=document.createEvent("MouseEvent");return u.initEvent(c,g,a),u}}let x_=(()=>{class c{constructor(a){this.platformId=a,this.anchorOpacity=0,this.anchorPos=-1,this.anchorValues=[],this.placementTypes=Ys,this.styleTypes=Ju,this.showPercentage=!1,this.tooltipDisabled=!1,this.hover=new i.EventEmitter}getValues(a){const u=[];for(const x of this.results){const I=x.series.find(ye=>ye.name.toString()===a.toString());let K=x.name;if(K instanceof Date&&(K=K.toLocaleDateString()),I){const ye=I.name;let $e,Ye=I.value;if(this.showPercentage&&(Ye=(I.d1-I.d0).toFixed(2)+"%"),this.colors.scaleType===zi.Linear){let Vt=Ye;I.d1&&(Vt=I.d1),$e=this.colors.getColor(Vt)}else $e=this.colors.getColor(x.name);const ht=Object.assign({},I,{value:Ye,name:ye,series:K,min:I.min,max:I.max,color:$e});u.push(ht)}}return u}mouseMove(a){if(!(0,e.isPlatformBrowser)(this.platformId))return;const u=a.pageX-a.target.getBoundingClientRect().left,x=this.findClosestPointIndex(u),I=this.xSet[x];if(this.anchorPos=this.xScale(I),this.anchorPos=Math.max(0,this.anchorPos),this.anchorPos=Math.min(this.dims.width,this.anchorPos),this.anchorValues=this.getValues(I),this.anchorPos!==this.lastAnchorPos){const K=ud("mouseleave");this.tooltipAnchor.nativeElement.dispatchEvent(K),this.anchorOpacity=.7,this.hover.emit({value:I}),this.showTooltip(),this.lastAnchorPos=this.anchorPos}}findClosestPointIndex(a){let u=0,x=this.xSet.length-1,I=Number.MAX_VALUE,K=0;for(;u<=x;){const ye=(u+x)/2|0,Ye=this.xScale(this.xSet[ye]),$e=Math.abs(Ye-a);if($e<I&&(I=$e,K=ye),Ye<a)u=ye+1;else{if(!(Ye>a)){I=0,K=ye;break}x=ye-1}}return K}showTooltip(){const a=ud("mouseenter");this.tooltipAnchor.nativeElement.dispatchEvent(a)}hideTooltip(){const a=ud("mouseleave");this.tooltipAnchor.nativeElement.dispatchEvent(a),this.anchorOpacity=0,this.lastAnchorPos=-1}getToolTipText(a){let u="";return u+=void 0!==a.series?a.series:"???",u+=": ",void 0!==a.value&&(u+=a.value.toLocaleString()),(void 0!==a.min||void 0!==a.max)&&(u+=" (",void 0!==a.min?(void 0===a.max&&(u+="\u2265"),u+=a.min.toLocaleString(),void 0!==a.max&&(u+=" - ")):void 0!==a.max&&(u+="\u2264"),void 0!==a.max&&(u+=a.max.toLocaleString()),u+=")"),u}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-tooltip-area",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(pb,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.tooltipAnchor=x.first)}},inputs:{dims:"dims",xSet:"xSet",xScale:"xScale",yScale:"yScale",results:"results",colors:"colors",showPercentage:"showPercentage",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate"},outputs:{hover:"hover"},attrs:c_,decls:6,vars:18,consts:[["defaultTooltipTemplate",""],["tooltipAnchor",""],["y","0",1,"tooltip-area",2,"opacity","0","cursor","'auto'",3,"mousemove","mouseleave"],["y","0","ngx-tooltip","",1,"tooltip-anchor",3,"tooltipDisabled","tooltipPlacement","tooltipType","tooltipSpacing","tooltipTemplate","tooltipContext","tooltipImmediateExit"],[1,"area-tooltip-container"],["class","tooltip-item",4,"ngFor","ngForOf"],[1,"tooltip-item"],[1,"tooltip-item-color"]],template:function(a,u){if(1&a){const x=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"rect",2),i.\u0275\u0275listener("mousemove",function(K){return i.\u0275\u0275restoreView(x),i.\u0275\u0275resetView(u.mouseMove(K))})("mouseleave",function(){return i.\u0275\u0275restoreView(x),i.\u0275\u0275resetView(u.hideTooltip())}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(2,hb,2,1,"ng-template",null,0,i.\u0275\u0275templateRefExtractor),i.\u0275\u0275element(4,"rect",3,1),i.\u0275\u0275elementEnd()}if(2&a){const x=i.\u0275\u0275reference(3);i.\u0275\u0275advance(),i.\u0275\u0275attribute("x",0)("width",u.dims.width)("height",u.dims.height),i.\u0275\u0275advance(3),i.\u0275\u0275styleProp("opacity",u.anchorOpacity)("pointer-events","none"),i.\u0275\u0275property("@animationState",0!==u.anchorOpacity?"active":"inactive")("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Right)("tooltipType",u.styleTypes.tooltip)("tooltipSpacing",15)("tooltipTemplate",u.tooltipTemplate?u.tooltipTemplate:x)("tooltipContext",u.anchorValues)("tooltipImmediateExit",!0),i.\u0275\u0275attribute("x",u.anchorPos)("width",1)("height",u.dims.height)}},dependencies:[e.NgForOf,Hp],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)("inactive => active",[(0,Gt.style)({opacity:0}),(0,Gt.animate)(250,(0,Gt.style)({opacity:.7}))]),(0,Gt.transition)("active => inactive",[(0,Gt.style)({opacity:.7}),(0,Gt.animate)(250,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),hg=(()=>{class c{constructor(a,u){this.cd=u,this.height=50,this.select=new i.EventEmitter,this.onDomainChange=new i.EventEmitter,this.initialized=!1,this.element=a.nativeElement}ngOnChanges(a){this.update(),this.initialized||(this.addBrush(),this.initialized=!0)}update(){this.dims=this.getDims(),this.height=this.dims.height;const a=this.view[1]-this.height;this.xDomain=this.getXDomain(),this.xScale=this.getXScale(),this.brush&&this.updateBrush(),this.transform=`translate(0 , ${a})`,this.filterId="filter"+Gu().toString(),this.filter=`url(#${this.filterId})`,this.cd.markForCheck()}getXDomain(){let a=[];for(const x of this.results)for(const I of x.series)a.includes(I.name)||a.push(I.name);let u=[];return this.scaleType===zi.Time?u=[Math.min(...a),Math.max(...a)]:this.scaleType===zi.Linear?(a=a.map(K=>Number(K)),u=[Math.min(...a),Math.max(...a)]):u=a,u}getXScale(){let a;return this.scaleType===zi.Time?a=nm().range([0,this.dims.width]).domain(this.xDomain):this.scaleType===zi.Linear?a=ic().range([0,this.dims.width]).domain(this.xDomain):this.scaleType===zi.Ordinal&&(a=up().range([0,this.dims.width]).padding(.1).domain(this.xDomain)),a}addBrush(){if(this.brush)return;const a=this.height,u=this.view[0];this.brush=function mu(){return function Ff(c){var ye,g=Xh,a=Mv,u=Nm,x=!0,I=kl("start","brush","end"),K=6;function Ye(si){var hr=si.property("__brush",pr).selectAll(".overlay").data([Ip("overlay")]);hr.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",Md.overlay).merge(hr).each(function(){var jr=od(this).extent;ta(this).attr("x",jr[0][0]).attr("y",jr[0][1]).attr("width",jr[1][0]-jr[0][0]).attr("height",jr[1][1]-jr[0][1])}),si.selectAll(".selection").data([Ip("selection")]).enter().append("rect").attr("class","selection").attr("cursor",Md.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var _o=si.selectAll(".handle").data(c.handles,function(jr){return jr.type});_o.exit().remove(),_o.enter().append("rect").attr("class",function(jr){return"handle handle--"+jr.type}).attr("cursor",function(jr){return Md[jr.type]}),si.each($e).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",zt).filter(u).on("touchstart.brush",zt).on("touchmove.brush",yn).on("touchend.brush touchcancel.brush",li).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function $e(){var si=ta(this),hr=od(this).selection;hr?(si.selectAll(".selection").style("display",null).attr("x",hr[0][0]).attr("y",hr[0][1]).attr("width",hr[1][0]-hr[0][0]).attr("height",hr[1][1]-hr[0][1]),si.selectAll(".handle").style("display",null).attr("x",function(_o){return"e"===_o.type[_o.type.length-1]?hr[1][0]-K/2:hr[0][0]-K/2}).attr("y",function(_o){return"s"===_o.type[0]?hr[1][1]-K/2:hr[0][1]-K/2}).attr("width",function(_o){return"n"===_o.type||"s"===_o.type?hr[1][0]-hr[0][0]+K:K}).attr("height",function(_o){return"e"===_o.type||"w"===_o.type?hr[1][1]-hr[0][1]+K:K})):si.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function ht(si,hr,_o){var jr=si.__brush.emitter;return!jr||_o&&jr.clean?new Vt(si,hr,_o):jr}function Vt(si,hr,_o){this.that=si,this.args=hr,this.state=si.__brush,this.active=0,this.clean=_o}function zt(si){if((!ye||si.touches)&&a.apply(this,arguments)){var Ca,oo,Co,us,xo,Jr,Hr,ys,Nu,ru,wd,hr=this,_o=si.target.__data__.type,jr="selection"===(x&&si.metaKey?_o="overlay":_o)?Af:x&&si.altKey?Jd:Mu,ao=c===xh?null:w0[_o],lo=c===Zp?null:r1[_o],mo=od(hr),br=mo.extent,yo=mo.selection,ml=br[0][0],Ba=br[0][1],Rr=br[1][0],No=br[1][1],Ns=0,Ml=0,Rd=ao&&lo&&x&&si.shiftKey,jl=Array.from(si.touches||[si],hs=>{const Ka=hs.identifier;return(hs=Bu(hs,hr)).point0=hs.slice(),hs.identifier=Ka,hs});Sa(hr);var Os=ht(hr,arguments,!0).beforestart();if("overlay"===_o){yo&&(Nu=!0);const hs=[jl[0],jl[1]||jl[0]];mo.selection=yo=[[Ca=c===xh?ml:ns(hs[0][0],hs[1][0]),Co=c===Zp?Ba:ns(hs[0][1],hs[1][1])],[xo=c===xh?Rr:Iu(hs[0][0],hs[1][0]),Hr=c===Zp?No:Iu(hs[0][1],hs[1][1])]],jl.length>1&&ha(si)}else Ca=yo[0][0],Co=yo[0][1],xo=yo[1][0],Hr=yo[1][1];oo=Ca,us=Co,Jr=xo,ys=Hr;var Cr=ta(hr).attr("pointer-events","none"),So=Cr.selectAll(".overlay").attr("cursor",Md[_o]);if(si.touches)Os.moved=wi,Os.ended=dn;else{var Po=ta(si.view).on("mousemove.brush",wi,!0).on("mouseup.brush",dn,!0);x&&Po.on("keydown.brush",function Ol(hs){switch(hs.keyCode){case 16:Rd=ao&&lo;break;case 18:jr===Mu&&(ao&&(xo=Jr-Ns*ao,Ca=oo+Ns*ao),lo&&(Hr=ys-Ml*lo,Co=us+Ml*lo),jr=Jd,ha(hs));break;case 32:(jr===Mu||jr===Jd)&&(ao<0?xo=Jr-Ns:ao>0&&(Ca=oo-Ns),lo<0?Hr=ys-Ml:lo>0&&(Co=us-Ml),jr=_d,So.attr("cursor",Md.selection),ha(hs));break;default:return}ap(hs)},!0).on("keyup.brush",function Fa(hs){switch(hs.keyCode){case 16:Rd&&(ru=wd=Rd=!1,ha(hs));break;case 18:jr===Jd&&(ao<0?xo=Jr:ao>0&&(Ca=oo),lo<0?Hr=ys:lo>0&&(Co=us),jr=Mu,ha(hs));break;case 32:jr===_d&&(hs.altKey?(ao&&(xo=Jr-Ns*ao,Ca=oo+Ns*ao),lo&&(Hr=ys-Ml*lo,Co=us+Ml*lo),jr=Jd):(ao<0?xo=Jr:ao>0&&(Ca=oo),lo<0?Hr=ys:lo>0&&(Co=us),jr=Mu),So.attr("cursor",Md[_o]),ha(hs));break;default:return}ap(hs)},!0),function Se(c){var g=c.document.documentElement,a=ta(c).on("dragstart.drag",Ke,fu);"onselectstart"in g?a.on("selectstart.drag",Ke,fu):(g.__noselect=g.style.MozUserSelect,g.style.MozUserSelect="none")}(si.view)}$e.call(hr),Os.start(si,jr.name)}function wi(hs){for(const Ka of hs.changedTouches||[hs])for(const mg of jl)mg.identifier===Ka.identifier&&(mg.cur=Bu(Ka,hr));if(Rd&&!ru&&!wd&&1===jl.length){const Ka=jl[0];W_(Ka.cur[0]-Ka[0])>W_(Ka.cur[1]-Ka[1])?wd=!0:ru=!0}for(const Ka of jl)Ka.cur&&(Ka[0]=Ka.cur[0],Ka[1]=Ka.cur[1]);Nu=!0,ap(hs),ha(hs)}function ha(hs){const Ka=jl[0],mg=Ka.point0;var Du;switch(Ns=Ka[0]-mg[0],Ml=Ka[1]-mg[1],jr){case _d:case Af:ao&&(Ns=Iu(ml-Ca,ns(Rr-xo,Ns)),oo=Ca+Ns,Jr=xo+Ns),lo&&(Ml=Iu(Ba-Co,ns(No-Hr,Ml)),us=Co+Ml,ys=Hr+Ml);break;case Mu:jl[1]?(ao&&(oo=Iu(ml,ns(Rr,jl[0][0])),Jr=Iu(ml,ns(Rr,jl[1][0])),ao=1),lo&&(us=Iu(Ba,ns(No,jl[0][1])),ys=Iu(Ba,ns(No,jl[1][1])),lo=1)):(ao<0?(Ns=Iu(ml-Ca,ns(Rr-Ca,Ns)),oo=Ca+Ns,Jr=xo):ao>0&&(Ns=Iu(ml-xo,ns(Rr-xo,Ns)),oo=Ca,Jr=xo+Ns),lo<0?(Ml=Iu(Ba-Co,ns(No-Co,Ml)),us=Co+Ml,ys=Hr):lo>0&&(Ml=Iu(Ba-Hr,ns(No-Hr,Ml)),us=Co,ys=Hr+Ml));break;case Jd:ao&&(oo=Iu(ml,ns(Rr,Ca-Ns*ao)),Jr=Iu(ml,ns(Rr,xo+Ns*ao))),lo&&(us=Iu(Ba,ns(No,Co-Ml*lo)),ys=Iu(Ba,ns(No,Hr+Ml*lo)))}Jr<oo&&(ao*=-1,Du=Ca,Ca=xo,xo=Du,Du=oo,oo=Jr,Jr=Du,_o in Of&&So.attr("cursor",Md[_o=Of[_o]])),ys<us&&(lo*=-1,Du=Co,Co=Hr,Hr=Du,Du=us,us=ys,ys=Du,_o in Qf&&So.attr("cursor",Md[_o=Qf[_o]])),mo.selection&&(yo=mo.selection),ru&&(oo=yo[0][0],Jr=yo[1][0]),wd&&(us=yo[0][1],ys=yo[1][1]),(yo[0][0]!==oo||yo[0][1]!==us||yo[1][0]!==Jr||yo[1][1]!==ys)&&(mo.selection=[[oo,us],[Jr,ys]],$e.call(hr),Os.brush(hs,jr.name))}function dn(hs){if(function Fm(c){c.stopImmediatePropagation()}(hs),hs.touches){if(hs.touches.length)return;ye&&clearTimeout(ye),ye=setTimeout(function(){ye=null},500)}else(function re(c,g){var a=c.document.documentElement,u=ta(c).on("dragstart.drag",null);g&&(u.on("click.drag",Ke,fu),setTimeout(function(){u.on("click.drag",null)},0)),"onselectstart"in a?u.on("selectstart.drag",null):(a.style.MozUserSelect=a.__noselect,delete a.__noselect)})(hs.view,Nu),Po.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);Cr.attr("pointer-events","all"),So.attr("cursor",Md.overlay),mo.selection&&(yo=mo.selection),function tD(c){return c[0][0]===c[1][0]||c[0][1]===c[1][1]}(yo)&&(mo.selection=null,$e.call(hr)),Os.end(hs,jr.name)}}function yn(si){ht(this,arguments).moved(si)}function li(si){ht(this,arguments).ended(si)}function pr(){var si=this.__brush||{selection:null};return si.extent=gf(g.apply(this,arguments)),si.dim=c,si}return Ye.move=function(si,hr,_o){si.tween?si.on("start.brush",function(jr){ht(this,arguments).beforestart().start(jr)}).on("interrupt.brush end.brush",function(jr){ht(this,arguments).end(jr)}).tween("brush",function(){var jr=this,ao=jr.__brush,lo=ht(jr,arguments),mo=ao.selection,br=c.input("function"==typeof hr?hr.apply(this,arguments):hr,ao.extent),yo=qs(mo,br);function ml(Ca){ao.selection=1===Ca&&null===br?null:yo(Ca),$e.call(jr),lo.brush()}return null!==mo&&null!==br?ml:ml(1)}):si.each(function(){var jr=this,ao=arguments,lo=jr.__brush,mo=c.input("function"==typeof hr?hr.apply(jr,ao):hr,lo.extent),br=ht(jr,ao).beforestart();Sa(jr),lo.selection=null===mo?null:mo,$e.call(jr),br.start(_o).brush(_o).end(_o)})},Ye.clear=function(si,hr){Ye.move(si,null,hr)},Vt.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(si,hr){return this.starting?(this.starting=!1,this.emit("start",si,hr)):this.emit("brush",si),this},brush:function(si,hr){return this.emit("brush",si,hr),this},end:function(si,hr){return 0==--this.active&&(delete this.state.emitter,this.emit("end",si,hr)),this},emit:function(si,hr,_o){var jr=ta(this.that).datum();I.call(si,this.that,new Zd(si,{sourceEvent:hr,target:Ye,selection:c.output(this.state.selection),mode:_o,dispatch:I}),jr)}},Ye.extent=function(si){return arguments.length?(g="function"==typeof si?si:Mp(gf(si)),Ye):g},Ye.filter=function(si){return arguments.length?(a="function"==typeof si?si:Mp(!!si),Ye):a},Ye.touchable=function(si){return arguments.length?(u="function"==typeof si?si:Mp(!!si),Ye):u},Ye.handleSize=function(si){return arguments.length?(K=+si,Ye):K},Ye.keyModifiers=function(si){return arguments.length?(x=!!si,Ye):x},Ye.on=function(){var si=I.on.apply(I,arguments);return si===I?Ye:si},Ye}(Zp)}().extent([[0,0],[u,a]]).on("brush end",({selection:x})=>{const K=(x||this.xScale.range()).map(this.xScale.invert);this.onDomainChange.emit(K),this.cd.markForCheck()}),ta(this.element).select(".brush").call(this.brush)}updateBrush(){this.brush&&(this.brush.extent([[0,0],[this.view[0],this.height]]),ta(this.element).select(".brush").call(this.brush),ta(this.element).select(".selection").attr("fill",void 0).attr("stroke",void 0).attr("fill-opacity",void 0),this.cd.markForCheck())}getDims(){return{width:this.view[0],height:this.height}}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.ChangeDetectorRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-timeline",""]],inputs:{view:"view",results:"results",scheme:"scheme",customColors:"customColors",legend:"legend",autoScale:"autoScale",scaleType:"scaleType",height:"height"},outputs:{select:"select",onDomainChange:"onDomainChange"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Dy,ngContentSelectors:vy,decls:7,vars:4,consts:[[1,"timeline"],["in","SourceGraphic","type","matrix","values","0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0"],[1,"embedded-chart"],["x","0","y","0",1,"brush-background"],[1,"brush"]],template:function(a,u){1&a&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0)(1,"filter"),i.\u0275\u0275element(2,"feColorMatrix",1),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"g",2),i.\u0275\u0275projection(4),i.\u0275\u0275elementEnd(),i.\u0275\u0275element(5,"rect",3)(6,"g",4),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275attribute("id",u.filterId),i.\u0275\u0275advance(4),i.\u0275\u0275attribute("width",u.view[0])("height",u.height))},styles:[".timeline .brush-background{fill:#0000000d}.timeline .brush .selection{fill:#0000001a;stroke-width:1px;stroke:#888}.timeline .brush .handle{fill-opacity:0}.timeline .embedded-chart{opacity:.6}\n"],encapsulation:2,changeDetection:0}),c})(),Yy=(()=>{class c{constructor(){this.label="Total",this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.legendItems=[],this.labelFormatting=a=>a,this.percentageFormatting=a=>a,this.defaultValueFormatting=a=>a.toLocaleString()}ngOnChanges(a){this.update()}getTotal(){return this.data.map(a=>Number(a.value)).reduce((a,u)=>a+u,0)}update(){this.total=this.getTotal(),this.roundedTotal=this.total,this.legendItems=this.getLegendItems()}getLegendItems(){return this.data.map(a=>{const u=nu(a.name),x=a.value,I=this.colors.getColor(u),K=this.total>0?x/this.total*100:0,ye="function"==typeof this.labelFormatting?this.labelFormatting(u):u;return{_value:x,data:a,value:x,color:I,label:ye,displayLabel:cg(ye,20),origialLabel:a.name,percentage:this.percentageFormatting?this.percentageFormatting(K):K.toLocaleString()}})}trackBy(a,u){return u.label}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-advanced-legend"]],inputs:{width:"width",data:"data",colors:"colors",label:"label",animations:"animations",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",percentageFormatting:"percentageFormatting"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],decls:8,vars:7,consts:[[1,"advanced-pie-legend"],["class","total-value","ngx-charts-count-up","",3,"countTo","valueFormatting",4,"ngIf"],["class","total-value",4,"ngIf"],[1,"total-label"],[1,"legend-items-container"],[1,"legend-items"],["tabindex","-1","class","legend-item",3,"mouseenter","mouseleave","click",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-count-up","",1,"total-value",3,"countTo","valueFormatting"],[1,"total-value"],["tabindex","-1",1,"legend-item",3,"mouseenter","mouseleave","click"],[1,"item-color"],["class","item-value","ngx-charts-count-up","",3,"countTo","valueFormatting",4,"ngIf"],["class","item-value",4,"ngIf"],[1,"item-label"],["class","item-percent","ngx-charts-count-up","",3,"countTo","countSuffix",4,"ngIf"],["class","item-percent",4,"ngIf"],["ngx-charts-count-up","",1,"item-value",3,"countTo","valueFormatting"],[1,"item-value"],["ngx-charts-count-up","",1,"item-percent",3,"countTo","countSuffix"],[1,"item-percent"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"div",0),i.\u0275\u0275template(1,mb,1,2,"div",1)(2,ph,2,1,"div",2),i.\u0275\u0275elementStart(3,"div",3),i.\u0275\u0275text(4),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(5,"div",4)(6,"div",5),i.\u0275\u0275template(7,eT,8,7,"div",6),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275styleProp("width",u.width,"px"),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",u.label," "),i.\u0275\u0275advance(3),i.\u0275\u0275property("ngForOf",u.legendItems)("ngForTrackBy",u.trackBy))},dependencies:[Gh,e.NgIf,e.NgForOf],styles:[".advanced-pie-legend{float:left;position:relative;top:50%;transform:translateY(-50%)}.advanced-pie-legend .total-value{font-size:36px}.advanced-pie-legend .total-label{font-size:24px;margin-bottom:19px}.advanced-pie-legend .legend-items-container{width:100%}.advanced-pie-legend .legend-items-container .legend-items{white-space:nowrap;overflow:auto}.advanced-pie-legend .legend-items-container .legend-items .legend-item{margin-right:20px;display:inline-block;cursor:pointer}.advanced-pie-legend .legend-items-container .legend-items .legend-item:focus{outline:none}.advanced-pie-legend .legend-items-container .legend-items .legend-item:hover{color:#000;transition:.2s}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-value{font-size:24px;margin-top:-6px;margin-left:11px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-label{font-size:14px;opacity:.7;margin-left:11px;margin-top:-6px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-percent{font-size:24px;opacity:.7;margin-left:11px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-color{border-left:4px solid;width:4px;height:42px;float:left;margin-right:7px}\n"],encapsulation:2,changeDetection:0}),c})(),cf=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[e.CommonModule,Tw,Gy],e.CommonModule,Tw,Gy]}),c})();function uu({width:c,height:g,margins:a,showXAxis:u=!1,showYAxis:x=!1,xAxisHeight:I=0,yAxisWidth:K=0,showXLabel:ye=!1,showYLabel:Ye=!1,showLegend:$e=!1,legendType:ht=zi.Ordinal,legendPosition:Vt=bu.Right,columns:zt=12}){let yn=a[3],li=c,pr=g-a[0]-a[2];return $e&&Vt===bu.Right&&(zt-=ht===zi.Ordinal?2:1),li=li*zt/12,li=li-a[1]-a[3],u&&(pr-=5,pr-=I,ye&&(pr-=30)),x&&(li-=5,li-=K,yn+=K,yn+=10,Ye&&(li-=30,yn+=30)),li=Math.max(0,li),pr=Math.max(0,pr),{width:Math.floor(li),height:Math.floor(pr),xOffset:Math.floor(yn)}}const Lb=[{name:"vivid",selectable:!0,group:zi.Ordinal,domain:["#647c8a","#3f51b5","#2196f3","#00b862","#afdf0a","#a7b61a","#f3e562","#ff9800","#ff5722","#ff4514"]},{name:"natural",selectable:!0,group:zi.Ordinal,domain:["#bf9d76","#e99450","#d89f59","#f2dfa7","#a5d7c6","#7794b1","#afafaf","#707160","#ba9383","#d9d5c3"]},{name:"cool",selectable:!0,group:zi.Ordinal,domain:["#a8385d","#7aa3e5","#a27ea8","#aae3f5","#adcded","#a95963","#8796c0","#7ed3ed","#50abcc","#ad6886"]},{name:"fire",selectable:!0,group:zi.Ordinal,domain:["#ff3d00","#bf360c","#ff8f00","#ff6f00","#ff5722","#e65100","#ffca28","#ffab00"]},{name:"solar",selectable:!0,group:zi.Linear,domain:["#fff8e1","#ffecb3","#ffe082","#ffd54f","#ffca28","#ffc107","#ffb300","#ffa000","#ff8f00","#ff6f00"]},{name:"air",selectable:!0,group:zi.Linear,domain:["#e1f5fe","#b3e5fc","#81d4fa","#4fc3f7","#29b6f6","#03a9f4","#039be5","#0288d1","#0277bd","#01579b"]},{name:"aqua",selectable:!0,group:zi.Linear,domain:["#e0f7fa","#b2ebf2","#80deea","#4dd0e1","#26c6da","#00bcd4","#00acc1","#0097a7","#00838f","#006064"]},{name:"flame",selectable:!1,group:zi.Ordinal,domain:["#A10A28","#D3342D","#EF6D49","#FAAD67","#FDDE90","#DBED91","#A9D770","#6CBA67","#2C9653","#146738"]},{name:"ocean",selectable:!1,group:zi.Ordinal,domain:["#1D68FB","#33C0FC","#4AFFFE","#AFFFFF","#FFFC63","#FDBD2D","#FC8A25","#FA4F1E","#FA141B","#BA38D1"]},{name:"forest",selectable:!1,group:zi.Ordinal,domain:["#55C22D","#C1F33D","#3CC099","#AFFFFF","#8CFC9D","#76CFFA","#BA60FB","#EE6490","#C42A1C","#FC9F32"]},{name:"horizon",selectable:!1,group:zi.Ordinal,domain:["#2597FB","#65EBFD","#99FDD0","#FCEE4B","#FEFCFA","#FDD6E3","#FCB1A8","#EF6F7B","#CB96E8","#EFDEE0"]},{name:"neons",selectable:!1,group:zi.Ordinal,domain:["#FF3333","#FF33FF","#CC33FF","#0000FF","#33CCFF","#33FFFF","#33FF66","#CCFF33","#FFCC00","#FF6600"]},{name:"picnic",selectable:!1,group:zi.Ordinal,domain:["#FAC51D","#66BD6D","#FAA026","#29BB9C","#E96B56","#55ACD2","#B7332F","#2C83C9","#9166B8","#92E7E8"]},{name:"night",selectable:!1,group:zi.Ordinal,domain:["#2B1B5A","#501356","#183356","#28203F","#391B3C","#1E2B3C","#120634","#2D0432","#051932","#453080","#75267D","#2C507D","#4B3880","#752F7D","#35547D"]},{name:"nightLights",selectable:!1,group:zi.Ordinal,domain:["#4e31a5","#9c25a7","#3065ab","#57468b","#904497","#46648b","#32118d","#a00fb3","#1052a2","#6e51bd","#b63cc3","#6c97cb","#8671c1","#b455be","#7496c3"]}];class iu{constructor(g,a,u,x){"string"==typeof g&&(g=Lb.find(I=>I.name===g)),this.colorDomain=g.domain,this.scaleType=a,this.domain=u,this.customColors=x,this.scale=this.generateColorScheme(g,a,this.domain)}generateColorScheme(g,a,u){let x;switch("string"==typeof g&&(g=Lb.find(I=>I.name===g)),a){case zi.Quantile:x=ty().range(g.domain).domain(u);break;case zi.Ordinal:x=Ng().range(g.domain).domain(u);break;case zi.Linear:{const I=[...g.domain];1===I.length&&(I.push(I[0]),this.colorDomain=I);const K=Dx(0,1,1/I.length);x=ic().range(I).domain(K)}}return x}getColor(g){if(null==g)throw new Error("Value can not be null");if(this.scaleType===zi.Linear){const a=ic().domain(this.domain).range([0,1]);return this.scale(a(g))}{if("function"==typeof this.customColors)return this.customColors(g);const a=g.toString();let u;return this.customColors&&this.customColors.length>0&&(u=this.customColors.find(x=>x.name.toLowerCase()===a.toLowerCase())),u?u.value:this.scale(g)}}getLinearGradientStops(g,a){void 0===a&&(a=this.domain[0]);const u=ic().domain(this.domain).range([0,1]),x=Id().domain(this.colorDomain).range([0,1]),I=this.getColor(g),K=u(a),ye=this.getColor(a),Ye=u(g);let $e=1,ht=K;const Vt=[];for(Vt.push({color:ye,offset:K,originalOffset:K,opacity:1});ht<Ye&&$e<this.colorDomain.length;){const zt=this.colorDomain[$e],yn=x(zt);if(yn<=K)$e++;else{if(yn.toFixed(4)>=(Ye-x.bandwidth()).toFixed(4))break;Vt.push({color:zt,offset:yn,opacity:1}),ht=yn,$e++}}if(Vt[Vt.length-1].offset<100&&Vt.push({color:I,offset:Ye,opacity:1}),Ye===K)Vt[0].offset=0,Vt[1].offset=100;else if(100!==Vt[Vt.length-1].offset)for(const zt of Vt)zt.offset=(zt.offset-K)/(Ye-K)*100;return Vt}}function dv(c){const g=new Set;for(const a of c)for(const u of a.series)g.add(u.name);return Array.from(g)}function Cm(c,g=!0){return g&&c.every(x=>x instanceof Date)?zi.Time:c.every(u=>"number"==typeof u)?zi.Linear:zi.Ordinal}function S_(c,g,a){const u=Cm(c);let K,ye,x=[],I=[];if(u===zi.Linear&&(c=c.map(Ye=>Number(Ye))),u===zi.Time||u===zi.Linear){const Ye=c.map($e=>Number($e));K=g||Math.min(...Ye),ye=a||Math.max(...Ye)}return u===zi.Time?(I=[new Date(K),new Date(ye)],x=[...c].sort((Ye,$e)=>{const ht=Ye.getTime(),Vt=$e.getTime();return ht>Vt?1:Vt>ht?-1:0})):u===zi.Linear?(I=[K,ye],x=[...c].sort((Ye,$e)=>Ye-$e)):(I=c,x=c),{domain:I,xSet:x,scaleType:u}}function Xy(c,g,a="asc"){return c.sort((u,x)=>"asc"===a?u[g]-x[g]:x[g]-u[g])}function Zy(c,g,a="asc",u){return c.sort((x,I)=>{const ye=I[g],Ye=u.indexOf(x[g]),$e=u.indexOf(ye);return"asc"===a?Ye-$e:$e-Ye})}function dd(c,g,a="asc"){return c.sort((u,x)=>{const I=u[g].getTime(),K=x[g].getTime();return"asc"===a?I>K?1:K>I?-1:0:I>K?-1:K>I?1:0})}let fv=(()=>{class c{constructor(){this.baseValue="auto",this.stacked=!1,this.normalized=!1,this.animations=!0,this.select=new i.EventEmitter}ngOnChanges(a){this.update()}update(){let a,u;this.updateGradient();const x=K=>this.xScale(K.name);this.stacked||this.normalized?(a=Uv().x(x).y0((K,ye)=>this.yScale(K.d0)).y1((K,ye)=>this.yScale(K.d1)),u=Uv().x(x).y0(K=>this.yScale.range()[0]).y1(K=>this.yScale.range()[0])):(a=Uv().x(x).y0(()=>"auto"===this.baseValue?this.yScale.range()[0]:this.yScale(this.baseValue)).y1(K=>this.yScale(K.value)),u=Uv().x(x).y0(K=>"auto"===this.baseValue?this.yScale.range()[0]:this.yScale(this.baseValue)).y1(K=>"auto"===this.baseValue?this.yScale.range()[0]:this.yScale(this.baseValue))),a.curve(this.curve),u.curve(this.curve),this.opacity=.8;let I=this.data.series;I=this.scaleType===zi.Linear?Xy(I,"name"):this.scaleType===zi.Time?dd(I,"name"):Zy(I,"name","asc",this.xScale.domain()),this.path=a(I),this.startingPath=u(I)}updateGradient(){if(this.colors.scaleType===zi.Linear)if(this.hasGradient=!0,this.stacked||this.normalized){const a=this.data.series.map(K=>K.d0),u=this.data.series.map(K=>K.d1),x=Math.max(...u),I=Math.min(...a);this.gradientStops=this.colors.getLinearGradientStops(x,I)}else{const a=this.data.series.map(x=>x.value),u=Math.max(...a);this.gradientStops=this.colors.getLinearGradientStops(u)}else this.hasGradient=!1,this.gradientStops=void 0}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name)}isInactive(a){return!(!this.activeEntries||0===this.activeEntries.length)&&void 0===this.activeEntries.find(x=>a.name===x.name)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-area-series",""]],inputs:{data:"data",xScale:"xScale",yScale:"yScale",baseValue:"baseValue",colors:"colors",scaleType:"scaleType",stacked:"stacked",normalized:"normalized",gradient:"gradient",curve:"curve",activeEntries:"activeEntries",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:xy,decls:1,vars:12,consts:[["ngx-charts-area","",1,"area-series",3,"data","path","fill","stops","startingPath","opacity","gradient","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",0)),2&a&&(i.\u0275\u0275classProp("active",u.isActive(u.data))("inactive",u.isInactive(u.data)),i.\u0275\u0275property("data",u.data)("path",u.path)("fill",u.colors.getColor(u.data.name))("stops",u.gradientStops)("startingPath",u.startingPath)("opacity",u.opacity)("gradient",u.gradient||u.hasGradient)("animations",u.animations))},dependencies:[fg],encapsulation:2,changeDetection:0}),c})(),GM=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.xAxis=!1,this.yAxis=!1,this.baseValue="auto",this.autoScale=!1,this.timeline=!1,this.showGridLines=!0,this.curve=Nh,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.roundDomains=!1,this.tooltipDisabled=!1,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.timelineHeight=50,this.timelinePadding=10,this.trackBy=(a,u)=>u.name}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.timeline&&(this.dims.height-=this.timelineHeight+this.margin[2]+this.timelinePadding),this.xDomain=this.getXDomain(),this.filteredDomain&&(this.xDomain=this.filteredDomain),this.yDomain=this.getYDomain(),this.seriesDomain=this.getSeriesDomain(),this.xScale=this.getXScale(this.xDomain,this.dims.width),this.yScale=this.getYScale(this.yDomain,this.dims.height),this.updateTimeline(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset}, ${this.margin[0]})`,this.clipPathId="clip"+Gu().toString(),this.clipPath=`url(#${this.clipPathId})`}updateTimeline(){this.timeline&&(this.timelineWidth=this.dims.width,this.timelineXDomain=this.getXDomain(),this.timelineXScale=this.getXScale(this.timelineXDomain,this.timelineWidth),this.timelineYScale=this.getYScale(this.yDomain,this.timelineHeight),this.timelineTransform=`translate(${this.dims.xOffset}, ${-this.margin[2]})`)}getXDomain(){let a=dv(this.results);this.scaleType=Cm(a);let x,I,u=[];return this.scaleType===zi.Linear&&(a=a.map(K=>Number(K))),(this.scaleType===zi.Time||this.scaleType===zi.Linear)&&(x=this.xScaleMin?this.xScaleMin:Math.min(...a),I=this.xScaleMax?this.xScaleMax:Math.max(...a)),this.scaleType===zi.Time?(u=[new Date(x),new Date(I)],this.xSet=[...a].sort((K,ye)=>{const Ye=K.getTime(),$e=ye.getTime();return Ye>$e?1:$e>Ye?-1:0})):this.scaleType===zi.Linear?(u=[x,I],this.xSet=[...a].sort((K,ye)=>K-ye)):(u=a,this.xSet=a),u}getYDomain(){const a=[];for(const K of this.results)for(const ye of K.series)a.includes(ye.value)||a.push(ye.value);const u=[...a];return this.autoScale||u.push(0),"auto"!==this.baseValue&&u.push(this.baseValue),[this.yScaleMin?this.yScaleMin:Math.min(...u),this.yScaleMax?this.yScaleMax:Math.max(...u)]}getSeriesDomain(){return this.results.map(a=>a.name)}getXScale(a,u){let x;return this.scaleType===zi.Time?x=nm():this.scaleType===zi.Linear?x=ic():this.scaleType===zi.Ordinal&&(x=up().padding(.1)),x.range([0,u]).domain(a),this.roundDomains?x.nice():x}getYScale(a,u){const x=ic().range([u,0]).domain(a);return this.roundDomains?x.nice():x}getScaleType(a){let u=!0,x=!0;for(const I of a)Hh(I)&&(u=!1),Ew(I)&&(x=!1);return u?zi.Time:x?zi.Linear:zi.Ordinal}updateDomain(a){this.filteredDomain=a,this.xDomain=this.filteredDomain,this.xScale=this.getXScale(this.xDomain,this.dims.width)}updateHoveredVertical(a){this.hoveredVertical=a.value,this.deactivateAll()}hideCircles(){this.hoveredVertical=null,this.deactivateAll()}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.seriesDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.yDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1||(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-area-chart"]],contentQueries:function(a,u,x){if(1&a&&(i.\u0275\u0275contentQuery(x,bo,5),i.\u0275\u0275contentQuery(x,Ym,5)),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first),i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.seriesTooltipTemplate=I.first)}},hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseleave",function(){return u.hideCircles()})},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",baseValue:"baseValue",autoScale:"autoScale",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",timeline:"timeline",gradient:"gradient",showGridLines:"showGridLines",curve:"curve",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",roundDomains:"roundDomains",tooltipDisabled:"tooltipDisabled",xScaleMin:"xScaleMin",xScaleMax:"xScaleMax",yScaleMin:"yScaleMin",yScaleMax:"yScaleMax",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:11,vars:20,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"area-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],[3,"mouseleave",4,"ngIf"],["ngx-charts-timeline","",3,"results","view","height","scheme","customColors","legend","scaleType","onDomainChange",4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-area-series","",3,"xScale","yScale","baseValue","colors","data","activeEntries","scaleType","gradient","curve","animations"],[3,"mouseleave"],["ngx-charts-tooltip-area","",3,"hover","dims","xSet","xScale","yScale","results","colors","tooltipDisabled","tooltipTemplate"],[4,"ngFor","ngForOf"],["ngx-charts-circle-series","",3,"select","activate","deactivate","xScale","yScale","colors","activeEntries","data","scaleType","visibleValue","tooltipDisabled","tooltipTemplate"],["ngx-charts-timeline","",3,"onDomainChange","results","view","height","scheme","customColors","legend","scaleType"],["ngx-charts-area-series","",3,"xScale","yScale","baseValue","colors","data","scaleType","gradient","curve","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"defs")(2,"clipPath"),i.\u0275\u0275element(3,"rect"),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g",1),i.\u0275\u0275template(5,iw,1,11,"g",2)(6,tT,1,10,"g",3),i.\u0275\u0275elementStart(7,"g"),i.\u0275\u0275template(8,Sy,2,10,"g",4)(9,UM,3,9,"g",5),i.\u0275\u0275elementEnd()(),i.\u0275\u0275template(10,Z1,2,13,"g",6),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",u.clipPathId),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width+10)("height",u.dims.height+10)("transform","translate(-5, -5)"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275attribute("clip-path",u.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.results)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.tooltipDisabled),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.timeline&&"ordinal"!=u.scaleType))},dependencies:[cu,lf,xf,fv,x_,cv,hg,e.NgIf,e.NgForOf],styles:[".ngx-charts-outer{animation:chartFadeIn linear .6s}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .node,.ngx-charts .link,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .node.active,.ngx-charts .node:hover,.ngx-charts .link.active,.ngx-charts .link:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .node:focus,.ngx-charts .link:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .node.hidden,.ngx-charts .link.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"],encapsulation:2,changeDetection:0}),c})(),kb=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.showXAxisLabel=!1,this.showYAxisLabel=!1,this.showGridLines=!0,this.curve=Nh,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.roundDomains=!1,this.tooltipDisabled=!1,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.yDomain=[0,100],this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.seriesType=zh,this.timelineHeight=50,this.timelinePadding=10,this.trackBy=(a,u)=>u.name}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.timeline&&(this.dims.height-=this.timelineHeight+this.margin[2]+this.timelinePadding),this.xDomain=this.getXDomain(),this.filteredDomain&&(this.xDomain=this.filteredDomain),this.seriesDomain=this.getSeriesDomain(),this.xScale=this.getXScale(this.xDomain,this.dims.width),this.yScale=this.getYScale(this.yDomain,this.dims.height);for(let a=0;a<this.xSet.length;a++){const u=this.xSet[a];let x=0,I=0;for(const K of this.results){const ye=K.series.find(Ye=>{let $e=Ye.name,ht=u;return this.scaleType===zi.Time&&($e=$e.valueOf(),ht=ht.valueOf()),$e===ht});ye&&(I+=ye.value)}for(const K of this.results){let ye=K.series.find(Ye=>{let $e=Ye.name,ht=u;return this.scaleType===zi.Time&&($e=$e.valueOf(),ht=ht.valueOf()),$e===ht});ye?(ye.d0=x,ye.d1=x+ye.value,x+=ye.value):(ye={name:u,value:0,d0:x,d1:x},K.series.push(ye)),I>0?(ye.d0=100*ye.d0/I,ye.d1=100*ye.d1/I):(ye.d0=0,ye.d1=0)}}this.updateTimeline(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`,this.clipPathId="clip"+Gu().toString(),this.clipPath=`url(#${this.clipPathId})`}updateTimeline(){this.timeline&&(this.timelineWidth=this.dims.width,this.timelineXDomain=this.getXDomain(),this.timelineXScale=this.getXScale(this.timelineXDomain,this.timelineWidth),this.timelineYScale=this.getYScale(this.yDomain,this.timelineHeight),this.timelineTransform=`translate(${this.dims.xOffset}, ${-this.margin[2]})`)}getXDomain(){let a=dv(this.results);this.scaleType=Cm(a);let u=[];if(this.scaleType===zi.Time){const x=Math.min(...a),I=Math.max(...a);u=[new Date(x),new Date(I)],this.xSet=[...a].sort((K,ye)=>{const Ye=K.getTime(),$e=ye.getTime();return Ye>$e?1:$e>Ye?-1:0})}else this.scaleType===zi.Linear?(a=a.map(K=>Number(K)),u=[Math.min(...a),Math.max(...a)],this.xSet=[...a].sort((K,ye)=>K-ye)):(u=a,this.xSet=a);return u}getSeriesDomain(){return this.results.map(a=>a.name)}getXScale(a,u){let x;return this.scaleType===zi.Time?x=nm():this.scaleType===zi.Linear?x=ic():this.scaleType===zi.Ordinal&&(x=up().padding(.1)),x.range([0,u]).domain(a),this.roundDomains?x.nice():x}getYScale(a,u){const x=ic().range([u,0]).domain(a);return this.roundDomains?x.nice():x}updateDomain(a){this.filteredDomain=a,this.xDomain=this.filteredDomain,this.xScale=this.getXScale(this.xDomain,this.dims.width)}updateHoveredVertical(a){this.hoveredVertical=a.value,this.deactivateAll()}hideCircles(){this.hoveredVertical=null,this.deactivateAll()}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.seriesDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.yDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1||(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-area-chart-normalized"]],contentQueries:function(a,u,x){if(1&a&&(i.\u0275\u0275contentQuery(x,bo,5),i.\u0275\u0275contentQuery(x,Ym,5)),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first),i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.seriesTooltipTemplate=I.first)}},hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseleave",function(){return u.hideCircles()})},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",timeline:"timeline",gradient:"gradient",showGridLines:"showGridLines",curve:"curve",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",roundDomains:"roundDomains",tooltipDisabled:"tooltipDisabled",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:11,vars:20,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"area-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],[3,"mouseleave",4,"ngIf"],["ngx-charts-timeline","",3,"results","view","height","scheme","customColors","legend","scaleType","onDomainChange",4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-area-series","",3,"xScale","yScale","colors","data","scaleType","activeEntries","gradient","normalized","curve","animations"],[3,"mouseleave"],["ngx-charts-tooltip-area","",3,"hover","dims","xSet","xScale","yScale","results","colors","showPercentage","tooltipDisabled","tooltipTemplate"],[4,"ngFor","ngForOf"],["ngx-charts-circle-series","",3,"select","activate","deactivate","type","xScale","yScale","colors","activeEntries","data","scaleType","visibleValue","tooltipDisabled","tooltipTemplate"],["ngx-charts-timeline","",3,"onDomainChange","results","view","height","scheme","customColors","legend","scaleType"],["ngx-charts-area-series","",3,"xScale","yScale","colors","data","scaleType","gradient","normalized","curve","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"defs")(2,"clipPath"),i.\u0275\u0275element(3,"rect"),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g",1),i.\u0275\u0275template(5,Tl,1,11,"g",2)(6,jh,1,10,"g",3),i.\u0275\u0275elementStart(7,"g"),i.\u0275\u0275template(8,lS,2,10,"g",4)(9,Qs,3,10,"g",5),i.\u0275\u0275elementEnd()(),i.\u0275\u0275template(10,nT,2,13,"g",6),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",u.clipPathId),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width+10)("height",u.dims.height+10)("transform","translate(-5, -5)"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275attribute("clip-path",u.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.results)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.tooltipDisabled),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.timeline&&"ordinal"!=u.scaleType))},dependencies:[cu,lf,xf,fv,x_,cv,hg,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),pv=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.xAxis=!1,this.yAxis=!1,this.timeline=!1,this.showGridLines=!0,this.curve=Nh,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.roundDomains=!1,this.tooltipDisabled=!1,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.timelineHeight=50,this.timelinePadding=10,this.seriesType=zh}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.timeline&&(this.dims.height-=this.timelineHeight+this.margin[2]+this.timelinePadding),this.xDomain=this.getXDomain(),this.filteredDomain&&(this.xDomain=this.filteredDomain),this.yDomain=this.getYDomain(),this.seriesDomain=this.getSeriesDomain(),this.xScale=this.getXScale(this.xDomain,this.dims.width),this.yScale=this.getYScale(this.yDomain,this.dims.height);for(let a=0;a<this.xSet.length;a++){const u=this.xSet[a];let x=0;for(const I of this.results){let K=I.series.find(ye=>{let Ye=ye.name,$e=u;return this.scaleType===zi.Time&&(Ye=Ye.valueOf(),$e=$e.valueOf()),Ye===$e});K?(K.d0=x,K.d1=x+K.value,x+=K.value):(K={name:u,value:0,d0:x,d1:x},I.series.push(K))}}this.updateTimeline(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`,this.clipPathId="clip"+Gu().toString(),this.clipPath=`url(#${this.clipPathId})`}updateTimeline(){this.timeline&&(this.timelineWidth=this.dims.width,this.timelineXDomain=this.getXDomain(),this.timelineXScale=this.getXScale(this.timelineXDomain,this.timelineWidth),this.timelineYScale=this.getYScale(this.yDomain,this.timelineHeight),this.timelineTransform=`translate(${this.dims.xOffset}, ${-this.margin[2]})`)}getXDomain(){let a=dv(this.results);this.scaleType=Cm(a);let x,I,u=[];return this.scaleType===zi.Linear&&(a=a.map(K=>Number(K))),(this.scaleType===zi.Time||this.scaleType===zi.Linear)&&(x=this.xScaleMin?this.xScaleMin:Math.min(...a),I=this.xScaleMax?this.xScaleMax:Math.max(...a)),this.scaleType===zi.Time?(u=[new Date(x),new Date(I)],this.xSet=[...a].sort((K,ye)=>{const Ye=K.getTime(),$e=ye.getTime();return Ye>$e?1:$e>Ye?-1:0})):this.scaleType===zi.Linear?(u=[x,I],this.xSet=[...a].sort((K,ye)=>K-ye)):(u=a,this.xSet=a),u}getYDomain(){const a=[];for(let I=0;I<this.xSet.length;I++){const K=this.xSet[I];let ye=0;for(const Ye of this.results){const $e=Ye.series.find(ht=>{let Vt=ht.name,zt=K;return this.scaleType===zi.Time&&(Vt=Vt.valueOf(),zt=zt.valueOf()),Vt===zt});$e&&(ye+=$e.value)}a.push(ye)}return[this.yScaleMin?this.yScaleMin:Math.min(0,...a),this.yScaleMax?this.yScaleMax:Math.max(...a)]}getSeriesDomain(){return this.results.map(a=>a.name)}getXScale(a,u){let x;return this.scaleType===zi.Time?x=nm():this.scaleType===zi.Linear?x=ic():this.scaleType===zi.Ordinal&&(x=up().padding(.1)),x.range([0,u]).domain(a),this.roundDomains?x.nice():x}getYScale(a,u){const x=ic().range([u,0]).domain(a);return this.roundDomains?x.nice():x}updateDomain(a){this.filteredDomain=a,this.xDomain=this.filteredDomain,this.xScale=this.getXScale(this.xDomain,this.dims.width)}updateHoveredVertical(a){this.hoveredVertical=a.value,this.deactivateAll()}hideCircles(){this.hoveredVertical=null,this.deactivateAll()}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}trackBy(a,u){return`${u.name}`}setColors(){let a;a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.seriesDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.yDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1||(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-area-chart-stacked"]],contentQueries:function(a,u,x){if(1&a&&(i.\u0275\u0275contentQuery(x,bo,5),i.\u0275\u0275contentQuery(x,Ym,5)),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first),i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.seriesTooltipTemplate=I.first)}},hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseleave",function(){return u.hideCircles()})},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",timeline:"timeline",gradient:"gradient",showGridLines:"showGridLines",curve:"curve",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",roundDomains:"roundDomains",tooltipDisabled:"tooltipDisabled",xScaleMin:"xScaleMin",xScaleMax:"xScaleMax",yScaleMin:"yScaleMin",yScaleMax:"yScaleMax",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:11,vars:20,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"area-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngFor","ngForOf","ngForTrackBy"],[3,"mouseleave",4,"ngIf"],["ngx-charts-timeline","",3,"results","view","height","scheme","customColors","legend","scaleType","onDomainChange",4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-area-series","",3,"xScale","yScale","colors","data","scaleType","gradient","activeEntries","stacked","curve","animations"],[3,"mouseleave"],["ngx-charts-tooltip-area","",3,"hover","dims","xSet","xScale","yScale","results","colors","tooltipDisabled","tooltipTemplate"],["ngx-charts-circle-series","",3,"select","activate","deactivate","type","xScale","yScale","colors","activeEntries","data","scaleType","visibleValue","tooltipDisabled","tooltipTemplate"],["ngx-charts-timeline","",3,"onDomainChange","results","view","height","scheme","customColors","legend","scaleType"],["ngx-charts-area-series","",3,"xScale","yScale","colors","data","scaleType","gradient","stacked","curve","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"defs")(2,"clipPath"),i.\u0275\u0275element(3,"rect"),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g",1),i.\u0275\u0275template(5,Xm,1,11,"g",2)(6,cS,1,10,"g",3),i.\u0275\u0275elementStart(7,"g"),i.\u0275\u0275template(8,iT,2,10,"g",4)(9,ow,3,10,"g",5),i.\u0275\u0275elementEnd()(),i.\u0275\u0275template(10,vp,2,13,"g",6),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",u.clipPathId),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width+10)("height",u.dims.height+10)("transform","translate(-5, -5)"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275attribute("clip-path",u.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.results)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.tooltipDisabled),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.timeline&&"ordinal"!=u.scaleType))},dependencies:[cu,lf,xf,fv,x_,cv,hg,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),DC=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),hv=(()=>{class c{constructor(a){this.roundEdges=!0,this.gradient=!1,this.offset=0,this.isActive=!1,this.animations=!0,this.noBarWhenZero=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.hasGradient=!1,this.hideBar=!1,this.element=a.nativeElement}ngOnChanges(a){a.roundEdges&&this.loadAnimation(),this.update()}update(){this.gradientId="grad"+Gu().toString(),this.gradientFill=`url(#${this.gradientId})`,this.gradient||this.stops?(this.gradientStops=this.getGradient(),this.hasGradient=!0):this.hasGradient=!1,this.updatePathEl(),this.checkToHideBar()}loadAnimation(){this.path=this.getStartingPath(),setTimeout(this.update.bind(this),100)}updatePathEl(){const a=ta(this.element).select(".bar"),u=this.getPath();this.animations?a.transition().duration(500).attr("d",u):a.attr("d",u)}getGradient(){return this.stops?this.stops:[{offset:0,color:this.fill,opacity:this.getStartOpacity()},{offset:100,color:this.fill,opacity:1}]}getStartingPath(){if(!this.animations)return this.getPath();let u,a=this.getRadius();return this.roundEdges?this.orientation===Jl.Vertical?(a=Math.min(this.height,a),u=bm(this.x,this.y+this.height,this.width,1,0,this.edges)):this.orientation===Jl.Horizontal&&(a=Math.min(this.width,a),u=bm(this.x,this.y,1,this.height,0,this.edges)):this.orientation===Jl.Vertical?u=bm(this.x,this.y+this.height,this.width,1,0,this.edges):this.orientation===Jl.Horizontal&&(u=bm(this.x,this.y,1,this.height,0,this.edges)),u}getPath(){let u,a=this.getRadius();return this.roundEdges?this.orientation===Jl.Vertical?(a=Math.min(this.height,a),u=bm(this.x,this.y,this.width,this.height,a,this.edges)):this.orientation===Jl.Horizontal&&(a=Math.min(this.width,a),u=bm(this.x,this.y,this.width,this.height,a,this.edges)):u=bm(this.x,this.y,this.width,this.height,a,this.edges),u}getRadius(){let a=0;return this.roundEdges&&this.height>5&&this.width>5&&(a=Math.floor(Math.min(5,this.height/2,this.width/2))),a}getStartOpacity(){return this.roundEdges?.2:.5}get edges(){let a=[!1,!1,!1,!1];return this.roundEdges&&(this.orientation===Jl.Vertical?a=this.data.value>0?[!0,!0,!1,!1]:[!1,!1,!0,!0]:this.orientation===Jl.Horizontal&&(a=this.data.value>0?[!1,!0,!1,!0]:[!0,!1,!0,!1])),a}onMouseEnter(){this.activate.emit(this.data)}onMouseLeave(){this.deactivate.emit(this.data)}checkToHideBar(){this.hideBar=this.noBarWhenZero&&(this.orientation===Jl.Vertical&&0===this.height||this.orientation===Jl.Horizontal&&0===this.width)}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-bar",""]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(){return u.onMouseLeave()})},inputs:{fill:"fill",data:"data",width:"width",height:"height",x:"x",y:"y",orientation:"orientation",roundEdges:"roundEdges",gradient:"gradient",offset:"offset",isActive:"isActive",stops:"stops",animations:"animations",ariaLabel:"ariaLabel",noBarWhenZero:"noBarWhenZero"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Uh,decls:2,vars:8,consts:[[4,"ngIf"],["stroke","none","role","img","tabIndex","-1",1,"bar",3,"click"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"]],template:function(a,u){1&a&&(i.\u0275\u0275template(0,J1,2,3,"defs",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"path",1),i.\u0275\u0275listener("click",function(){return u.select.emit(u.data)}),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("ngIf",u.hasGradient),i.\u0275\u0275advance(),i.\u0275\u0275classProp("active",u.isActive)("hidden",u.hideBar),i.\u0275\u0275attribute("d",u.path)("aria-label",u.ariaLabel)("fill",u.hasGradient?u.gradientFill:u.fill))},dependencies:[ug,e.NgIf],encapsulation:2,changeDetection:0}),c})();var Hc=function(c){return c.Standard="standard",c.Normalized="normalized",c.Stacked="stacked",c}(Hc||{}),zf=function(c){return c.positive="positive",c.negative="negative",c}(zf||{});let mv=(()=>{class c{constructor(a){this.dimensionsChanged=new i.EventEmitter,this.horizontalPadding=2,this.verticalPadding=5,this.element=a.nativeElement}ngOnChanges(a){this.update()}getSize(){return{height:this.element.getBoundingClientRect().height,width:this.element.getBoundingClientRect().width,negative:this.value<0}}ngAfterViewInit(){this.dimensionsChanged.emit(this.getSize())}update(){this.formatedValue=this.valueFormatting?this.valueFormatting(this.value):nu(this.value),"horizontal"===this.orientation?(this.x=this.barX+this.barWidth,this.value<0?(this.x=this.x-this.horizontalPadding,this.textAnchor="end"):(this.x=this.x+this.horizontalPadding,this.textAnchor="start"),this.y=this.barY+this.barHeight/2):(this.x=this.barX+this.barWidth/2,this.y=this.barY+this.barHeight,this.value<0?(this.y=this.y+this.verticalPadding,this.textAnchor="end"):(this.y=this.y-this.verticalPadding,this.textAnchor="start"),this.transform=`rotate(-45, ${this.x} , ${this.y})`)}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-bar-label",""]],inputs:{value:"value",valueFormatting:"valueFormatting",barX:"barX",barY:"barY",barWidth:"barWidth",barHeight:"barHeight",orientation:"orientation"},outputs:{dimensionsChanged:"dimensionsChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:eC,decls:2,vars:5,consts:[["alignment-baseline","middle",1,"textDataLabel"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"text",0),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("text-anchor",u.textAnchor)("transform",u.transform)("x",u.x)("y",u.y),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",u.formatedValue," "))},styles:[".textDataLabel[_ngcontent-%COMP%]{font-size:11px}"],changeDetection:0}),c})(),E_=(()=>{class c{constructor(){this.type=Hc.Standard,this.tooltipDisabled=!1,this.animations=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.dataLabelWidthChanged=new i.EventEmitter,this.barsForDataLabels=[],this.barOrientation=Jl}ngOnChanges(a){this.update()}update(){this.updateTooltipSettings();const a={[zf.positive]:0,[zf.negative]:0};let u,x;u=zf.positive,this.type===Hc.Normalized&&(x=this.series.map(K=>K.value).reduce((K,ye)=>K+ye,0));const I=Math.max(this.xScale.domain()[0],0);this.bars=this.series.map(K=>{let ye=K.value;const Ye=this.getLabel(K),$e=nu(Ye);u=ye>0?zf.positive:zf.negative;const Vt={value:ye,label:Ye,roundEdges:this.roundEdges,data:K,formattedLabel:$e};if(Vt.height=this.yScale.bandwidth(),this.type===Hc.Standard)Vt.width=Math.abs(this.xScale(ye)-this.xScale(I)),Vt.x=this.xScale(ye<0?ye:I),Vt.y=this.yScale(Ye);else if(this.type===Hc.Stacked){const yn=a[u],li=yn+ye;a[u]+=ye,Vt.width=this.xScale(li)-this.xScale(yn),Vt.x=this.xScale(yn),Vt.y=0,Vt.offset0=yn,Vt.offset1=li}else if(this.type===Hc.Normalized){let yn=a[u],li=yn+ye;a[u]+=ye,x>0?(yn=100*yn/x,li=100*li/x):(yn=0,li=0),Vt.width=this.xScale(li)-this.xScale(yn),Vt.x=this.xScale(yn),Vt.y=0,Vt.offset0=yn,Vt.offset1=li,ye=(li-yn).toFixed(2)+"%"}this.colors.scaleType===zi.Ordinal?Vt.color=this.colors.getColor(Ye):this.type===Hc.Standard?(Vt.color=this.colors.getColor(ye),Vt.gradientStops=this.colors.getLinearGradientStops(ye)):(Vt.color=this.colors.getColor(Vt.offset1),Vt.gradientStops=this.colors.getLinearGradientStops(Vt.offset1,Vt.offset0));let zt=$e;return Vt.ariaLabel=$e+" "+ye.toLocaleString(),null!=this.seriesName&&(zt=`${this.seriesName} \u2022 ${$e}`,Vt.data.series=this.seriesName,Vt.ariaLabel=this.seriesName+" "+Vt.ariaLabel),Vt.tooltipText=this.tooltipDisabled?void 0:`\n <span class="tooltip-label">${Cu(zt)}</span>\n <span class="tooltip-val">${this.dataLabelFormatting?this.dataLabelFormatting(ye):ye.toLocaleString()}</span>\n `,Vt}),this.updateDataLabels()}updateDataLabels(){if(this.type===Hc.Stacked){this.barsForDataLabels=[];const a={};a.series=this.seriesName;const u=this.series.map(I=>I.value).reduce((I,K)=>K>0?I+K:I,0),x=this.series.map(I=>I.value).reduce((I,K)=>K<0?I+K:I,0);a.total=u+x,a.x=0,a.y=0,a.width=this.xScale(a.total>0?u:x),a.height=this.yScale.bandwidth(),this.barsForDataLabels.push(a)}else this.barsForDataLabels=this.series.map(a=>{const u={};return u.series=this.seriesName??a.label,u.total=a.value,u.x=this.xScale(0),u.y=this.yScale(a.label),u.width=this.xScale(u.total)-this.xScale(0),u.height=this.yScale.bandwidth(),u})}updateTooltipSettings(){this.tooltipPlacement=this.tooltipDisabled?void 0:Ys.Top,this.tooltipType=this.tooltipDisabled?void 0:Ju.tooltip}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name&&a.value===x.value)}getLabel(a){return a.label?a.label:a.name}trackBy(a,u){return u.label}trackDataLabelBy(a,u){return a+"#"+u.series+"#"+u.total}click(a){this.select.emit(a)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-series-horizontal",""]],inputs:{dims:"dims",type:"type",series:"series",xScale:"xScale",yScale:"yScale",colors:"colors",tooltipDisabled:"tooltipDisabled",gradient:"gradient",activeEntries:"activeEntries",seriesName:"seriesName",tooltipTemplate:"tooltipTemplate",roundEdges:"roundEdges",animations:"animations",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero"},outputs:{select:"select",activate:"activate",deactivate:"deactivate",dataLabelWidthChanged:"dataLabelWidthChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:uS,decls:2,vars:3,consts:[["ngx-charts-bar","","ngx-tooltip","",3,"width","height","x","y","fill","stops","data","orientation","roundEdges","gradient","isActive","ariaLabel","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","noBarWhenZero","select","activate","deactivate",4,"ngFor","ngForOf","ngForTrackBy"],[4,"ngIf"],["ngx-charts-bar","","ngx-tooltip","",3,"select","activate","deactivate","width","height","x","y","fill","stops","data","orientation","roundEdges","gradient","isActive","ariaLabel","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","noBarWhenZero"],["ngx-charts-bar-label","",3,"barX","barY","barWidth","barHeight","value","valueFormatting","orientation","dimensionsChanged",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-bar-label","",3,"dimensionsChanged","barX","barY","barWidth","barHeight","value","valueFormatting","orientation"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,sw,1,21,"g",0)(1,Zm,2,2,"g",1),2&a&&(i.\u0275\u0275property("ngForOf",u.bars)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showDataLabel))},dependencies:[hv,mv,e.NgForOf,Hp,e.NgIf],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),wC=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.roundEdges=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxWidth={negative:0,positive:0}}update(){super.update(),this.showDataLabel||(this.dataLabelMaxWidth={negative:0,positive:0}),this.margin=[10,20+this.dataLabelMaxWidth.positive,10,20+this.dataLabelMaxWidth.negative],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getXScale(){this.xDomain=this.getXDomain();const a=ic().range([0,this.dims.width]).domain(this.xDomain);return this.roundDomains?a.nice():a}getYScale(){this.yDomain=this.getYDomain();const a=this.yDomain.length/(this.dims.height/this.barPadding+1);return Id().rangeRound([0,this.dims.height]).paddingInner(a).domain(this.yDomain)}getXDomain(){const a=this.results.map(I=>I.value);return[this.xScaleMin?Math.min(this.xScaleMin,...a):Math.min(0,...a),this.xScaleMax?Math.max(this.xScaleMax,...a):Math.max(0,...a)]}getYDomain(){return this.results.map(a=>a.label)}onClick(a){this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.yDomain:this.xDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return"ordinal"===a.scaleType?(a.domain=this.yDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.xDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onDataLabelMaxWidthChanged(a){a.size.negative?this.dataLabelMaxWidth.negative=Math.max(this.dataLabelMaxWidth.negative,a.size.width):this.dataLabelMaxWidth.positive=Math.max(this.dataLabelMaxWidth.positive,a.size.width),a.index===this.results.length-1&&setTimeout(()=>this.update())}onActivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name),!(this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series)>-1)&&(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name);const x=this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series);this.activeEntries.splice(x,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-horizontal"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",roundEdges:"roundEdges",xScaleMax:"xScaleMax",xScaleMin:"xScaleMin",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:5,vars:25,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-series-horizontal","",3,"select","activate","deactivate","dataLabelWidthChanged","xScale","yScale","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","activeEntries","roundEdges","animations","showDataLabel","dataLabelFormatting","noBarWhenZero"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,!0)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,dS,1,11,"g",2)(3,_b,1,10,"g",3),i.\u0275\u0275elementStart(4,"g",4),i.\u0275\u0275listener("select",function(I){return u.onClick(I)})("activate",function(I){return u.onActivate(I)})("deactivate",function(I){return u.onDeactivate(I)})("dataLabelWidthChanged",function(I){return u.onDataLabelMaxWidthChanged(I)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(22,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("series",u.results)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("activeEntries",u.activeEntries)("roundEdges",u.roundEdges)("animations",u.animations)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("noBarWhenZero",u.noBarWhenZero))},dependencies:[cu,lf,xf,E_,e.NgIf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),xC=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.groupPadding=16,this.barPadding=8,this.roundDomains=!1,this.roundEdges=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxWidth={negative:0,positive:0},this.isSSR=!1,this.barOrientation=Jl,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.showDataLabel||(this.dataLabelMaxWidth={negative:0,positive:0}),this.margin=[10,20+this.dataLabelMaxWidth.positive,10,20+this.dataLabelMaxWidth.negative],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.valueDomain=this.getValueDomain(),this.groupScale=this.getGroupScale(),this.innerScale=this.getInnerScale(),this.valueScale=this.getValueScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getGroupScale(){const a=this.groupDomain.length/(this.dims.height/this.groupPadding+1);return Id().rangeRound([0,this.dims.height]).paddingInner(a).paddingOuter(a/2).domain(this.groupDomain)}getInnerScale(){const a=this.groupScale.bandwidth(),u=this.innerDomain.length/(a/this.barPadding+1);return Id().rangeRound([0,a]).paddingInner(u).domain(this.innerDomain)}getValueScale(){const a=ic().range([0,this.dims.width]).domain(this.valueDomain);return this.roundDomains?a.nice():a}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getValueDomain(){const a=[];for(const I of this.results)for(const K of I.series)a.includes(K.value)||a.push(K.value);return[Math.min(0,...a),this.xScaleMax?Math.max(this.xScaleMax,...a):Math.max(0,...a)]}groupTransform(a){return`translate(0, ${this.groupScale(a.label)})`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onDataLabelMaxWidthChanged(a,u){a.size.negative?this.dataLabelMaxWidth.negative=Math.max(this.dataLabelMaxWidth.negative,a.size.width):this.dataLabelMaxWidth.positive=Math.max(this.dataLabelMaxWidth.positive,a.size.width),u===this.results.length-1&&setTimeout(()=>this.update())}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-horizontal-2d"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",groupPadding:"groupPadding",barPadding:"barPadding",roundDomains:"roundDomains",roundEdges:"roundEdges",xScaleMax:"xScaleMax",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:7,vars:18,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-grid-panel-series","",3,"xScale","yScale","data","dims","orient"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-horizontal","",3,"select","activate","deactivate","dataLabelWidthChanged","xScale","activeEntries","yScale","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","seriesName","roundEdges","animations","showDataLabel","dataLabelFormatting","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275element(2,"g",2),i.\u0275\u0275template(3,fS,1,11,"g",3)(4,tC,1,10,"g",4)(5,nv,2,2,"g",5)(6,nC,2,2,"g",5),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(15,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.valueScale)("yScale",u.groupScale)("data",u.results)("dims",u.dims)("orient",u.barOrientation.Horizontal),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,dg,lf,xf,E_,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),SC=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.valueDomain=[0,100],this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.barChartType=Hc,this.isSSR=!1,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getYScale(){const a=this.groupDomain.length/(this.dims.height/this.barPadding+1);return Id().rangeRound([0,this.dims.height]).paddingInner(a).domain(this.groupDomain)}getXScale(){const a=ic().range([0,this.dims.width]).domain(this.valueDomain);return this.roundDomains?a.nice():a}groupTransform(a){return`translate(0, ${this.yScale(a.name)})`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-horizontal-normalized"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:13,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-horizontal","",3,"select","activate","deactivate","type","xScale","yScale","activeEntries","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","seriesName","animations","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,My,1,11,"g",2)(3,pS,1,9,"g",3)(4,Iy,2,2,"g",4)(5,Jm,2,2,"g",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(10,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,lf,xf,E_,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),_p=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxWidth={negative:0,positive:0},this.barChartType=Hc,this.isSSR=!1,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.showDataLabel||(this.dataLabelMaxWidth={negative:0,positive:0}),this.margin=[10,20+this.dataLabelMaxWidth.positive,10,20+this.dataLabelMaxWidth.negative],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.valueDomain=this.getValueDomain(),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getValueDomain(){const a=[];let u=0,x=0;for(const ye of this.results){let Ye=0,$e=0;for(const ht of ye.series)ht.value<0?Ye+=ht.value:$e+=ht.value,u=ht.value<u?ht.value:u,x=ht.value>x?ht.value:x;a.push(Ye),a.push($e)}return a.push(u),a.push(x),[Math.min(0,...a),this.xScaleMax?Math.max(this.xScaleMax,...a):Math.max(...a)]}getYScale(){const a=this.groupDomain.length/(this.dims.height/this.barPadding+1);return Id().rangeRound([0,this.dims.height]).paddingInner(a).domain(this.groupDomain)}getXScale(){const a=ic().range([0,this.dims.width]).domain(this.valueDomain);return this.roundDomains?a.nice():a}groupTransform(a){return`translate(0, ${this.yScale(a.name)})`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onDataLabelMaxWidthChanged(a,u){a.size.negative?this.dataLabelMaxWidth.negative=Math.max(this.dataLabelMaxWidth.negative,a.size.width):this.dataLabelMaxWidth.positive=Math.max(this.dataLabelMaxWidth.positive,a.size.width),u===this.results.length-1&&setTimeout(()=>this.update())}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-horizontal-stacked"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",xScaleMax:"xScaleMax",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:13,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","yAxisOffset","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-horizontal","",3,"select","activate","deactivate","dataLabelWidthChanged","type","xScale","yScale","colors","series","activeEntries","dims","gradient","tooltipDisabled","tooltipTemplate","seriesName","animations","showDataLabel","dataLabelFormatting","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,eg,1,11,"g",2)(3,Ay,1,10,"g",3)(4,hS,2,2,"g",4)(5,aw,2,2,"g",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(10,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,lf,xf,E_,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),Dd=(()=>{class c{constructor(a){this.platformId=a,this.type=Hc.Standard,this.tooltipDisabled=!1,this.animations=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.dataLabelHeightChanged=new i.EventEmitter,this.barsForDataLabels=[],this.barOrientation=Jl,this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}ngOnChanges(a){this.update()}update(){let a;this.updateTooltipSettings(),this.series.length&&(a=this.xScale.bandwidth()),a=Math.round(a);const u=Math.max(this.yScale.domain()[0],0),x={[zf.positive]:0,[zf.negative]:0};let K,I=zf.positive;this.type===Hc.Normalized&&(K=this.series.map(ye=>ye.value).reduce((ye,Ye)=>ye+Ye,0)),this.bars=this.series.map((ye,Ye)=>{let $e=ye.value;const ht=this.getLabel(ye),Vt=nu(ht);I=$e>0?zf.positive:zf.negative;const yn={value:$e,label:ht,roundEdges:this.roundEdges,data:ye,width:a,formattedLabel:Vt,height:0,x:0,y:0};if(this.type===Hc.Standard)yn.height=Math.abs(this.yScale($e)-this.yScale(u)),yn.x=this.xScale(ht),yn.y=this.yScale($e<0?0:$e);else if(this.type===Hc.Stacked){const pr=x[I],si=pr+$e;x[I]+=$e,yn.height=this.yScale(pr)-this.yScale(si),yn.x=0,yn.y=this.yScale(si),yn.offset0=pr,yn.offset1=si}else if(this.type===Hc.Normalized){let pr=x[I],si=pr+$e;x[I]+=$e,K>0?(pr=100*pr/K,si=100*si/K):(pr=0,si=0),yn.height=this.yScale(pr)-this.yScale(si),yn.x=0,yn.y=this.yScale(si),yn.offset0=pr,yn.offset1=si,$e=(si-pr).toFixed(2)+"%"}this.colors.scaleType===zi.Ordinal?yn.color=this.colors.getColor(ht):this.type===Hc.Standard?(yn.color=this.colors.getColor($e),yn.gradientStops=this.colors.getLinearGradientStops($e)):(yn.color=this.colors.getColor(yn.offset1),yn.gradientStops=this.colors.getLinearGradientStops(yn.offset1,yn.offset0));let li=Vt;return yn.ariaLabel=Vt+" "+$e.toLocaleString(),null!=this.seriesName&&(li=`${this.seriesName} \u2022 ${Vt}`,yn.data.series=this.seriesName,yn.ariaLabel=this.seriesName+" "+yn.ariaLabel),yn.tooltipText=this.tooltipDisabled?void 0:`\n <span class="tooltip-label">${Cu(li)}</span>\n <span class="tooltip-val">${this.dataLabelFormatting?this.dataLabelFormatting($e):$e.toLocaleString()}</span>\n `,yn}),this.updateDataLabels()}updateDataLabels(){if(this.type===Hc.Stacked){this.barsForDataLabels=[];const a={};a.series=this.seriesName;const u=this.series.map(I=>I.value).reduce((I,K)=>K>0?I+K:I,0),x=this.series.map(I=>I.value).reduce((I,K)=>K<0?I+K:I,0);a.total=u+x,a.x=0,a.y=0,a.height=this.yScale(a.total>0?u:x),a.width=this.xScale.bandwidth(),this.barsForDataLabels.push(a)}else this.barsForDataLabels=this.series.map(a=>{const u={};return u.series=this.seriesName??a.label,u.total=a.value,u.x=this.xScale(a.label),u.y=this.yScale(0),u.height=this.yScale(u.total)-this.yScale(0),u.width=this.xScale.bandwidth(),u})}updateTooltipSettings(){this.tooltipPlacement=this.tooltipDisabled?void 0:Ys.Top,this.tooltipType=this.tooltipDisabled?void 0:Ju.tooltip}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name&&a.value===x.value)}onClick(a){this.select.emit(a)}getLabel(a){return a.label?a.label:a.name}trackBy(a,u){return u.label}trackDataLabelBy(a,u){return a+"#"+u.series+"#"+u.total}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-series-vertical",""]],inputs:{dims:"dims",type:"type",series:"series",xScale:"xScale",yScale:"yScale",colors:"colors",gradient:"gradient",activeEntries:"activeEntries",seriesName:"seriesName",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate",roundEdges:"roundEdges",animations:"animations",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero"},outputs:{select:"select",activate:"activate",deactivate:"deactivate",dataLabelHeightChanged:"dataLabelHeightChanged"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:tg,decls:3,vars:3,consts:[[4,"ngIf"],["ngx-charts-bar","","ngx-tooltip","",3,"width","height","x","y","fill","stops","data","orientation","roundEdges","gradient","ariaLabel","isActive","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","noBarWhenZero","animations","select","activate","deactivate",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-bar","","ngx-tooltip","",3,"select","activate","deactivate","width","height","x","y","fill","stops","data","orientation","roundEdges","gradient","ariaLabel","isActive","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","noBarWhenZero","animations"],["ngx-charts-bar-label","",3,"barX","barY","barWidth","barHeight","value","valueFormatting","orientation","dimensionsChanged",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-bar-label","",3,"dimensionsChanged","barX","barY","barWidth","barHeight","value","valueFormatting","orientation"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,yb,2,2,"g",0)(1,bb,2,2,"g",0)(2,oC,2,2,"g",0),2&a&&(i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showDataLabel))},dependencies:[hv,mv,e.NgIf,e.NgForOf,Hp],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),LS=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.roundEdges=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxHeight={negative:0,positive:0}}update(){super.update(),this.showDataLabel||(this.dataLabelMaxHeight={negative:0,positive:0}),this.margin=[10+this.dataLabelMaxHeight.positive,20,10+this.dataLabelMaxHeight.negative,20],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.showDataLabel&&(this.dims.height-=this.dataLabelMaxHeight.negative),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]+this.dataLabelMaxHeight.negative})`}getXScale(){this.xDomain=this.getXDomain();const a=this.xDomain.length/(this.dims.width/this.barPadding+1);return Id().range([0,this.dims.width]).paddingInner(a).domain(this.xDomain)}getYScale(){this.yDomain=this.getYDomain();const a=ic().range([this.dims.height,0]).domain(this.yDomain);return this.roundDomains?a.nice():a}getXDomain(){return this.results.map(a=>a.label)}getYDomain(){const a=this.results.map(I=>I.value);let u=this.yScaleMin?Math.min(this.yScaleMin,...a):Math.min(0,...a);this.yAxisTicks&&!this.yAxisTicks.some(isNaN)&&(u=Math.min(u,...this.yAxisTicks));let x=this.yScaleMax?Math.max(this.yScaleMax,...a):Math.max(0,...a);return this.yAxisTicks&&!this.yAxisTicks.some(isNaN)&&(x=Math.max(x,...this.yAxisTicks)),[u,x]}onClick(a){this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.xDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.xDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.yDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onDataLabelMaxHeightChanged(a){a.size.negative?this.dataLabelMaxHeight.negative=Math.max(this.dataLabelMaxHeight.negative,a.size.height):this.dataLabelMaxHeight.positive=Math.max(this.dataLabelMaxHeight.positive,a.size.height),a.index===this.results.length-1&&setTimeout(()=>this.update())}onActivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name),!(this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series)>-1)&&(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name);const x=this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series);this.activeEntries.splice(x,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-vertical"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",roundEdges:"roundEdges",yScaleMax:"yScaleMax",yScaleMin:"yScaleMin",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:5,vars:25,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-series-vertical","",3,"activate","deactivate","select","dataLabelHeightChanged","xScale","yScale","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","showDataLabel","dataLabelFormatting","activeEntries","roundEdges","animations","noBarWhenZero"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,!0)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,ng,1,12,"g",2)(3,rT,1,10,"g",3),i.\u0275\u0275elementStart(4,"g",4),i.\u0275\u0275listener("activate",function(I){return u.onActivate(I)})("deactivate",function(I){return u.onDeactivate(I)})("select",function(I){return u.onClick(I)})("dataLabelHeightChanged",function(I){return u.onDataLabelMaxHeightChanged(I)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(22,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("series",u.results)("dims",u.dims)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("showDataLabel",u.showDataLabel)("dataLabelFormatting",u.dataLabelFormatting)("activeEntries",u.activeEntries)("roundEdges",u.roundEdges)("animations",u.animations)("noBarWhenZero",u.noBarWhenZero))},dependencies:[cu,lf,xf,Dd,e.NgIf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),Iw=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.scaleType=zi.Ordinal,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.groupPadding=16,this.barPadding=8,this.roundDomains=!1,this.roundEdges=!0,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxHeight={negative:0,positive:0},this.isSSR=!1,this.barOrientation=Jl,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.showDataLabel||(this.dataLabelMaxHeight={negative:0,positive:0}),this.margin=[10+this.dataLabelMaxHeight.positive,20,10+this.dataLabelMaxHeight.negative,20],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.showDataLabel&&(this.dims.height-=this.dataLabelMaxHeight.negative),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.valueDomain=this.getValueDomain(),this.groupScale=this.getGroupScale(),this.innerScale=this.getInnerScale(),this.valueScale=this.getValueScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]+this.dataLabelMaxHeight.negative})`}onDataLabelMaxHeightChanged(a,u){a.size.negative?this.dataLabelMaxHeight.negative=Math.max(this.dataLabelMaxHeight.negative,a.size.height):this.dataLabelMaxHeight.positive=Math.max(this.dataLabelMaxHeight.positive,a.size.height),u===this.results.length-1&&setTimeout(()=>this.update())}getGroupScale(){const a=this.groupDomain.length/(this.dims.height/this.groupPadding+1);return Id().rangeRound([0,this.dims.width]).paddingInner(a).paddingOuter(a/2).domain(this.groupDomain)}getInnerScale(){const a=this.groupScale.bandwidth(),u=this.innerDomain.length/(a/this.barPadding+1);return Id().rangeRound([0,a]).paddingInner(u).domain(this.innerDomain)}getValueScale(){const a=ic().range([this.dims.height,0]).domain(this.valueDomain);return this.roundDomains?a.nice():a}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getValueDomain(){const a=[];for(const I of this.results)for(const K of I.series)a.includes(K.value)||a.push(K.value);return[Math.min(0,...a),this.yScaleMax?Math.max(this.yScaleMax,...a):Math.max(0,...a)]}groupTransform(a){return`translate(${this.groupScale(a.label)}, 0)`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-vertical-2d"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",scaleType:"scaleType",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",groupPadding:"groupPadding",barPadding:"barPadding",roundDomains:"roundDomains",roundEdges:"roundEdges",yScaleMax:"yScaleMax",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:7,vars:18,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-grid-panel-series","",3,"xScale","yScale","data","dims","orient"],["ngx-charts-x-axis","",3,"xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-series-vertical","",3,"activeEntries","xScale","yScale","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","showDataLabel","dataLabelFormatting","seriesName","roundEdges","animations","noBarWhenZero","select","activate","deactivate","dataLabelHeightChanged",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-vertical","",3,"select","activate","deactivate","dataLabelHeightChanged","activeEntries","xScale","yScale","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","showDataLabel","dataLabelFormatting","seriesName","roundEdges","animations","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275element(2,"g",2),i.\u0275\u0275template(3,mS,1,11,"g",3)(4,rv,1,10,"g",4)(5,$M,2,2,"g",5),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(6,sC,2,2,"g",5),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(15,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.groupScale)("yScale",u.valueScale)("data",u.results)("dims",u.dims)("orient",u.barOrientation.Vertical),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,dg,lf,xf,Dd,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),KM=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.valueDomain=[0,100],this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.isSSR=!1,this.barChartType=Hc,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getXScale(){const a=this.groupDomain.length/(this.dims.width/this.barPadding+1);return Id().rangeRound([0,this.dims.width]).paddingInner(a).domain(this.groupDomain)}getYScale(){const a=ic().range([this.dims.height,0]).domain(this.valueDomain);return this.roundDomains?a.nice():a}groupTransform(a){return`translate(${this.xScale(a.name)}, 0)`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-vertical-normalized"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:13,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-vertical","",3,"select","activate","deactivate","type","xScale","yScale","activeEntries","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","seriesName","animations","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,gS,1,10,"g",2)(3,d_,1,10,"g",3)(4,jp,2,2,"g",4)(5,wb,2,2,"g",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(10,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,lf,xf,Dd,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),EC=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.tooltipDisabled=!1,this.showGridLines=!0,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.barPadding=8,this.roundDomains=!1,this.showDataLabel=!1,this.noBarWhenZero=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.dataLabelMaxHeight={negative:0,positive:0},this.isSSR=!1,this.barChartType=Hc,this.trackBy=(a,u)=>u.name}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.showDataLabel||(this.dataLabelMaxHeight={negative:0,positive:0}),this.margin=[10+this.dataLabelMaxHeight.positive,20,10+this.dataLabelMaxHeight.negative,20],this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.showDataLabel&&(this.dims.height-=this.dataLabelMaxHeight.negative),this.formatDates(),this.groupDomain=this.getGroupDomain(),this.innerDomain=this.getInnerDomain(),this.valueDomain=this.getValueDomain(),this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]+this.dataLabelMaxHeight.negative})`}getGroupDomain(){const a=[];for(const u of this.results)a.includes(u.label)||a.push(u.label);return a}getInnerDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.label)||a.push(x.label);return a}getValueDomain(){const a=[];let u=0,x=0;for(const ye of this.results){let Ye=0,$e=0;for(const ht of ye.series)ht.value<0?Ye+=ht.value:$e+=ht.value,u=ht.value<u?ht.value:u,x=ht.value>x?ht.value:x;a.push(Ye),a.push($e)}return a.push(u),a.push(x),[Math.min(0,...a),this.yScaleMax?Math.max(this.yScaleMax,...a):Math.max(...a)]}getXScale(){const a=this.groupDomain.length/(this.dims.width/this.barPadding+1);return Id().rangeRound([0,this.dims.width]).paddingInner(a).domain(this.groupDomain)}getYScale(){const a=ic().range([this.dims.height,0]).domain(this.valueDomain);return this.roundDomains?a.nice():a}onDataLabelMaxHeightChanged(a,u){a.size.negative?this.dataLabelMaxHeight.negative=Math.max(this.dataLabelMaxHeight.negative,a.size.height):this.dataLabelMaxHeight.positive=Math.max(this.dataLabelMaxHeight.positive,a.size.height),u===this.results.length-1&&setTimeout(()=>this.update())}groupTransform(a){return`translate(${this.xScale(a.name)||0}, 0)`}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){let a;a=this.schemeType===zi.Ordinal?this.innerDomain:this.valueDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.innerDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.valueDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bar-vertical-stacked"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",gradient:"gradient",showGridLines:"showGridLines",activeEntries:"activeEntries",schemeType:"schemeType",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",barPadding:"barPadding",roundDomains:"roundDomains",yScaleMax:"yScaleMax",showDataLabel:"showDataLabel",dataLabelFormatting:"dataLabelFormatting",noBarWhenZero:"noBarWhenZero",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:13,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"bar-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","xAxisOffset","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-series-vertical","",3,"select","activate","deactivate","dataLabelHeightChanged","type","xScale","yScale","activeEntries","colors","series","dims","gradient","tooltipDisabled","tooltipTemplate","showDataLabel","dataLabelFormatting","seriesName","animations","noBarWhenZero"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,void 0,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,void 0,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,Ac,1,11,"g",2)(3,Up,1,10,"g",3)(4,Oc,2,2,"g",4),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(5,MA,2,2,"g",4),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(10,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,lf,xf,Dd,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1,transform:"*"}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0,transform:"scale(0)"}))])])]},changeDetection:0}),c})(),Aw=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})();const kS=kg();let Jy=(()=>{class c{constructor(a,u){this.cd=u,this.roundEdges=!0,this.gradient=!1,this.offset=0,this.isActive=!1,this.animations=!0,this.noBarWhenZero=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.BarOrientation=Jl,this.initialized=!1,this.hasGradient=!1,this.hideBar=!1,this.nativeElm=a.nativeElement}ngOnChanges(a){this.initialized?this.update():(this.loadAnimation(),this.initialized=!0)}update(){this.boxStrokeWidth=Math.max(this.strokeWidth,1),this.whiskerStrokeWidth=Math.max(this.strokeWidth/2,1),this.medianLineWidth=1.5*this.strokeWidth,this.gradientId="grad"+Gu().toString(),this.gradientFill=`url(#${this.gradientId})`,this.gradient?(this.gradientStops=this.getGradient(),this.hasGradient=!0):this.hasGradient=!1,this.updateLineEl(),this.updatePathEl(),this.checkToHideBar(),this.maskLineId="mask"+Gu().toString(),this.maskLine=`url(#${this.maskLineId})`,this.cd&&this.cd.markForCheck()}loadAnimation(){this.boxPath=this.oldPath=this.getStartingPath(),this.oldLineCoordinates=this.getStartingLineCoordinates(),setTimeout(this.update.bind(this),100)}updatePathEl(){const a=ta(this.nativeElm).selectAll(".bar"),u=this.getPath();this.animations?a.attr("d",this.oldPath).transition().ease(z0).duration(500).attrTween("d",this.pathTween(u,4)):a.attr("d",u),this.oldPath=u}updateLineEl(){const a=ta(this.nativeElm).selectAll(".bar-line"),u=this.lineCoordinates,x=this.oldLineCoordinates;this.animations?a.attr("x1",(I,K)=>x[K].v1.x).attr("y1",(I,K)=>x[K].v1.y).attr("x2",(I,K)=>x[K].v2.x).attr("y2",(I,K)=>x[K].v2.y).transition().ease(z0).duration(500).attr("x1",(I,K)=>u[K].v1.x).attr("y1",(I,K)=>u[K].v1.y).attr("x2",(I,K)=>u[K].v2.x).attr("y2",(I,K)=>u[K].v2.y):a.attr("x1",(I,K)=>u[K].v1.x).attr("y1",(I,K)=>u[K].v1.y).attr("x2",(I,K)=>u[K].v2.x).attr("y2",(I,K)=>u[K].v2.y),this.oldLineCoordinates=[...u]}lineTween(a,u,x,I){return I[x][a].baseVal.value}pathTween(a,u){return function(){const x=this,I=this.cloneNode();I.setAttribute("d",a);const K=x?.getTotalLength(),ye=I?.getTotalLength(),Ye=[0];let $e=0;const ht=u/Math.max(K,ye);for(;$e<1;)Ye.push($e),$e+=ht;Ye.push(1);const Vt=Ye.map(zt=>{const yn=x.getPointAtLength(zt*K),li=I.getPointAtLength(zt*ye);return qs([yn.x,yn.y],[li.x,li.y])});return zt=>zt<1?"M"+Vt.map(yn=>yn(zt)).join("L"):a}}getStartingPath(){if(!this.animations)return this.getPath();const a=this.roundEdges?1:0,{x:u,y:x}=this.lineCoordinates[2].v1;return bm(u-this.width,x-1,this.width,2,a,this.edges)}getPath(){const a=this.getRadius();let u="";return u=bm(this.x,this.y,this.width,this.height,Math.min(this.height,a),this.edges),u}getStartingLineCoordinates(){if(!this.animations)return[...this.lineCoordinates];const a=kS(this.lineCoordinates);return a[1].v1.y=a[1].v2.y=a[3].v1.y=a[3].v2.y=a[0].v1.y=a[0].v2.y=a[2].v1.y,a}getRadius(){let a=0;return this.roundEdges&&this.height>5&&this.width>5&&(a=Math.floor(Math.min(5,this.height/2,this.width/2))),a}getGradient(){return[{offset:0,color:this.fill,opacity:this.getStartOpacity()},{offset:100,color:this.fill,opacity:1}]}getStartOpacity(){return this.roundEdges?.2:.5}get edges(){let a=[!1,!1,!1,!1];return this.roundEdges&&(a=[!0,!0,!0,!0]),a}onMouseEnter(){this.activate.emit(this.data)}onMouseLeave(){this.deactivate.emit(this.data)}checkToHideBar(){this.hideBar=this.noBarWhenZero&&0===this.height}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.ChangeDetectorRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-box",""]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(){return u.onMouseLeave()})},inputs:{strokeColor:"strokeColor",strokeWidth:"strokeWidth",fill:"fill",data:"data",width:"width",height:"height",x:"x",y:"y",lineCoordinates:"lineCoordinates",roundEdges:"roundEdges",gradient:"gradient",gradientStops:"gradientStops",offset:"offset",isActive:"isActive",animations:"animations",ariaLabel:"ariaLabel",noBarWhenZero:"noBarWhenZero"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:uw,decls:9,vars:13,consts:[["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops",4,"ngIf"],["height","100%","width","100%","fill","white","fill-opacity","1"],["fill","black","fill-opacity","1",1,"bar"],["role","img","tabIndex","-1",1,"bar",3,"click"],["class","bar-line","fill","none",3,"hidden",4,"ngFor","ngForOf"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"],["fill","none",1,"bar-line"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"defs"),i.\u0275\u0275template(1,sT,1,3,"g",0),i.\u0275\u0275elementStart(2,"mask")(3,"g"),i.\u0275\u0275element(4,"rect",1)(5,"path",2),i.\u0275\u0275elementEnd()()(),i.\u0275\u0275elementStart(6,"g")(7,"path",3),i.\u0275\u0275listener("click",function(){return u.select.emit(u.data)}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(8,dw,1,9,"line",4),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.hasGradient),i.\u0275\u0275advance(),i.\u0275\u0275attribute("id",u.maskLineId),i.\u0275\u0275advance(3),i.\u0275\u0275attribute("d",u.boxPath),i.\u0275\u0275advance(2),i.\u0275\u0275classProp("active",u.isActive)("hidden",u.hideBar),i.\u0275\u0275attribute("d",u.boxPath)("stroke",u.strokeColor)("stroke-width",u.boxStrokeWidth)("aria-label",u.ariaLabel)("fill",u.hasGradient?u.gradientFill:u.fill),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.lineCoordinates))},dependencies:[ug,e.NgIf,e.NgForOf],encapsulation:2,changeDetection:0}),c})(),Ow=(()=>{class c{constructor(){this.animations=!0,this.tooltipDisabled=!1,this.gradient=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter}ngOnChanges(a){this.update()}onClick(a){this.select.emit(a)}update(){this.updateTooltipSettings();const a=this.series&&this.series.series.length?Math.round(this.xScale.bandwidth()):null,u=this.series.name;this.counts=this.series.series;const x=this.counts.map(Vt=>Number(Vt.value));this.whiskers=[h1(x),ey(x)];const I=this.counts.map(Vt=>Vt.value).sort((Vt,zt)=>Number(Vt)-Number(zt));this.quartiles=this.getBoxQuantiles(I),this.lineCoordinates=this.getLinesCoordinates(u.toString(),this.whiskers,this.quartiles,a);const K=this.quartiles[1],ye=nu(u),Ye={value:K,data:this.counts,label:u,formattedLabel:ye,width:a,height:0,x:0,y:0,roundEdges:this.roundEdges,quartiles:this.quartiles,lineCoordinates:this.lineCoordinates};Ye.height=Math.abs(this.yScale(this.quartiles[0])-this.yScale(this.quartiles[2])),Ye.x=this.xScale(u.toString()),Ye.y=this.yScale(this.quartiles[2]),Ye.ariaLabel=ye+" - Median: "+K.toLocaleString(),this.colors.scaleType===zi.Ordinal?Ye.color=this.colors.getColor(u):(Ye.color=this.colors.getColor(this.quartiles[1]),Ye.gradientStops=this.colors.getLinearGradientStops(this.quartiles[0],this.quartiles[2]));const ht=`\n <span class="tooltip-label">${Cu(ye)}</span>\n <span class="tooltip-val">\n \u2022 Q1: ${this.quartiles[0]} \u2022 Q2: ${this.quartiles[1]} \u2022 Q3: ${this.quartiles[2]}<br>\n \u2022 Min: ${this.whiskers[0]} \u2022 Max: ${this.whiskers[1]}\n </span>`;Ye.tooltipText=this.tooltipDisabled?void 0:ht,this.tooltipTitle=this.tooltipDisabled?void 0:Ye.tooltipText,this.box=Ye}getBoxQuantiles(a){return[B0(a,.25),B0(a,.5),B0(a,.75)]}getLinesCoordinates(a,u,x,I){const ye=this.xScale(a)+I/2,Ye=Math.max(I+4*this.strokeWidth,1),$e=Math.max(I/3,1),ht=this.yScale(u[0]),Vt=this.yScale(u[1]),zt=this.yScale(x[1]);return[{v1:{x:ye,y:ht},v2:{x:ye,y:Vt}},{v1:{x:ye+$e/2,y:ht},v2:{x:ye-$e/2,y:ht}},{v1:{x:ye+Ye/2,y:zt},v2:{x:ye-Ye/2,y:zt}},{v1:{x:ye+$e/2,y:Vt},v2:{x:ye-$e/2,y:Vt}}]}updateTooltipSettings(){this.tooltipDisabled?(this.tooltipPlacement=void 0,this.tooltipType=void 0):(this.tooltipPlacement||(this.tooltipPlacement=Ys.Top),this.tooltipType||(this.tooltipType=Ju.tooltip))}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-box-series",""]],inputs:{dims:"dims",series:"series",xScale:"xScale",yScale:"yScale",colors:"colors",animations:"animations",strokeColor:"strokeColor",strokeWidth:"strokeWidth",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate",tooltipPlacement:"tooltipPlacement",tooltipType:"tooltipType",roundEdges:"roundEdges",gradient:"gradient"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:IA,decls:1,vars:22,consts:[["ngx-charts-box","","ngx-tooltip","",3,"select","activate","deactivate","width","height","x","y","roundEdges","fill","gradientStops","strokeColor","strokeWidth","data","lineCoordinates","gradient","ariaLabel","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0),i.\u0275\u0275listener("select",function(I){return u.onClick(I)})("activate",function(I){return u.activate.emit(I)})("deactivate",function(I){return u.deactivate.emit(I)}),i.\u0275\u0275elementEnd()),2&a&&i.\u0275\u0275property("@animationState","active")("@.disabled",!u.animations)("width",u.box.width)("height",u.box.height)("x",u.box.x)("y",u.box.y)("roundEdges",u.box.roundEdges)("fill",u.box.color)("gradientStops",u.box.gradientStops)("strokeColor",u.strokeColor)("strokeWidth",u.strokeWidth)("data",u.box.data)("lineCoordinates",u.box.lineCoordinates)("gradient",u.gradient)("ariaLabel",u.box.ariaLabel)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.tooltipPlacement)("tooltipType",u.tooltipType)("tooltipTitle",u.tooltipTitle)("tooltipTemplate",u.tooltipTemplate)("tooltipContext",u.box.data)("animations",u.animations)},dependencies:[Jy,Hp],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),Pb=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendPosition=bu.Right,this.legendTitle="Legend",this.showGridLines=!0,this.xAxis=!0,this.yAxis=!0,this.showXAxisLabel=!0,this.showYAxisLabel=!0,this.roundDomains=!1,this.roundEdges=!0,this.strokeColor="#FFFFFF",this.strokeWidth=2,this.tooltipDisabled=!1,this.wrapTicks=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0}trackBy(a,u){return u.name}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendPosition:this.legendPosition}),this.xDomain=this.getXDomain(),this.yDomain=this.getYDomain(),this.seriesDomain=this.getSeriesDomain(),this.setScales(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}setColors(){let a=[];a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}setScales(){this.xScale=this.getXScale(this.xDomain,this.dims.width),this.yScale=this.getYScale(this.yDomain,this.dims.height)}getXScale(a,u){return Id().domain(a.map(I=>I.toString())).rangeRound([0,u]).padding(.5)}getYScale(a,u){const x=ic().domain(a).range([u,0]);return this.roundDomains?x.nice():x}getUniqueBoxChartXDomainValues(a){const u=new Set;for(const x of a)u.add(x.name);return Array.from(u)}getXDomain(){let a=[];const u=this.getUniqueBoxChartXDomainValues(this.results);let x,I;if("string"==typeof u[0])a=u.map(K=>K.toString());else if("number"==typeof u[0]){const K=u.map(ye=>Number(ye));x=Math.min(...K),I=Math.max(...K),a=[x,I]}else{const K=u.map(ye=>Number(new Date(ye)));x=Math.min(...K),I=Math.max(...K),a=[new Date(x),new Date(I)]}return a}getYDomain(){const a=[];for(const ye of this.results)for(const Ye of ye.series)a.indexOf(Ye.value)<0&&a.push(Ye.value);const x=[...a].map(ye=>Number(ye));return[Math.min(...x),Math.max(...x)]}getSeriesDomain(){return this.results.map(a=>`${a.name}`)}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onClick(a){this.select.emit(a)}onActivate(a){this.activate.emit(a)}onDeactivate(a){this.deactivate.emit(a)}getLegendOptions(){const a={scaleType:this.schemeType,colors:this.colors,domain:[],position:this.legendPosition,title:this.legendTitle};return this.schemeType===zi.Ordinal?(a.domain=this.xDomain,a.colors=this.colors):(a.domain=this.yDomain,a.colors=this.colors.scale),a}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-box-chart"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendPosition:"legendPosition",legendTitle:"legendTitle",legendOptionsConfig:"legendOptionsConfig",showGridLines:"showGridLines",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",roundDomains:"roundDomains",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",roundEdges:"roundEdges",strokeColor:"strokeColor",strokeWidth:"strokeWidth",tooltipDisabled:"tooltipDisabled",gradient:"gradient",wrapTicks:"wrapTicks"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:23,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","animations"],[1,"box-chart","chart"],["ngx-charts-x-axis","",3,"dimensionsChanged","showGridLines","dims","xScale","showLabel","labelText","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","showGridLines","dims","yScale","showLabel","labelText","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-box-series","",3,"activate","deactivate","select","xScale","yScale","colors","roundEdges","strokeColor","strokeWidth","tooltipDisabled","tooltipTemplate","series","dims","animations","gradient"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1)(2,"g",2),i.\u0275\u0275listener("dimensionsChanged",function(I){return u.updateXAxisHeight(I)}),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(3,"g",3),i.\u0275\u0275listener("dimensionsChanged",function(I){return u.updateYAxisWidth(I)}),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g"),i.\u0275\u0275template(5,aT,2,12,"g",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(20,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("showGridLines",u.showGridLines)("dims",u.dims)("xScale",u.xScale)("showLabel",u.showXAxisLabel)("labelText",u.xAxisLabel)("wrapTicks",u.wrapTicks),i.\u0275\u0275advance(),i.\u0275\u0275property("showGridLines",u.showGridLines)("dims",u.dims)("yScale",u.yScale)("showLabel",u.showYAxisLabel)("labelText",u.yAxisLabel)("wrapTicks",u.wrapTicks),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.results)("ngForTrackBy",u.trackBy))},dependencies:[cu,lf,xf,Ow,e.NgForOf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),e0=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})();function Bb(c,g,a,u,x){let I=[];return g===zi.Linear&&(c=c.map(K=>Number(K)),a||c.push(0)),I=g===zi.Time||g===zi.Linear?[u||0===u?u:Math.min(...c),x||Math.max(...c)]:c,I}function T_(c,g,a,u){switch(a){case zi.Time:return nm().range(g).domain(c);case zi.Linear:{const x=ic().range(g).domain(c);return u?x.nice():x}case zi.Ordinal:return up().range([g[0],g[1]]).domain(c.map(x=>x.toString()));default:return}}let Fw=(()=>{class c{constructor(a){this.platformId=a,this.tooltipDisabled=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.placementTypes=Ys,this.styleTypes=Ju,this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}ngOnChanges(a){this.update()}update(){this.circles=this.getCircles()}getCircles(){const a=this.data.name;return this.data.series.map((u,x)=>{if(typeof u.y<"u"&&typeof u.x<"u"){const I=u.y,K=u.x,ye=u.r,Ye=this.rScale(ye||1),$e=nu(u.name),ht=this.xScale(this.xScaleType===zi.Linear?Number(K):K),Vt=this.yScale(this.yScaleType===zi.Linear?Number(I):I),zt=this.colors.getColor(this.colors.scaleType===zi.Linear?ye:a),yn=!this.activeEntries.length||this.isActive({name:a}),li=yn?1:.3;return{data:Object.assign({},u,{series:a,name:u.name,value:u.y,x:u.x,radius:u.r}),x:K,y:I,r:ye,classNames:[`circle-data-${x}`],value:I,label:K,cx:ht,cy:Vt,radius:Ye,tooltipLabel:$e,color:zt,opacity:li,seriesName:a,isActive:yn,transform:`translate(${ht},${Vt})`}}}).filter(u=>void 0!==u)}getTooltipText(a){const x=a.tooltipLabel&&a.tooltipLabel.length,I=a.seriesName&&a.seriesName.length,K=typeof a.r<"u"?nu(a.r):"",ye=this.xAxisLabel&&""!==this.xAxisLabel?`${this.xAxisLabel}:`:"",Ye=this.yAxisLabel&&""!==this.yAxisLabel?`${this.yAxisLabel}:`:"",$e=nu(a.x),ht=nu(a.y);return`\n ${I||x?`<span class="tooltip-label">${Cu(I&&x?`${a.seriesName} \u2022 ${a.tooltipLabel}`:a.seriesName+a.tooltipLabel)}</span>`:""}\n <span class="tooltip-label">\n <label>${Cu(ye)}</label> ${Cu($e)}<br />\n <label>${Cu(Ye)}</label> ${Cu(ht)}\n </span>\n <span class="tooltip-val">\n ${Cu(K)}\n </span>\n `}onClick(a){this.select.emit(a)}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name)}isVisible(a){return this.activeEntries.length>0?this.isActive({name:a.seriesName}):0!==a.opacity}activateCircle(a){a.barVisible=!0,this.activate.emit({name:this.data.name})}deactivateCircle(a){a.barVisible=!1,this.deactivate.emit({name:this.data.name})}trackBy(a,u){return`${u.data.series} ${u.data.name}`}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-bubble-series",""]],inputs:{data:"data",xScale:"xScale",yScale:"yScale",rScale:"rScale",xScaleType:"xScaleType",yScaleType:"yScaleType",colors:"colors",visibleValue:"visibleValue",activeEntries:"activeEntries",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:WM,decls:1,vars:2,consts:[[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-circle","","class","circle","ngx-tooltip","",3,"cx","cy","r","fill","opacity","active","pointerEvents","data","classNames","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","select","activate","deactivate",4,"ngIf"],["ngx-charts-circle","","ngx-tooltip","",1,"circle",3,"select","activate","deactivate","cx","cy","r","fill","pointerEvents","data","classNames","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,uC,4,3,"g",0),2&a&&i.\u0275\u0275property("ngForOf",u.circles)("ngForTrackBy",u.trackBy)},dependencies:[qy,e.NgForOf,e.NgIf,Hp],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":enter",[(0,Gt.style)({opacity:0,transform:"scale(0)"}),(0,Gt.animate)(250,(0,Gt.style)({opacity:1,transform:"scale(1)"}))])])]},changeDetection:0}),c})(),t0=(()=>{class c extends Wc{constructor(){super(...arguments),this.showGridLines=!0,this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.xAxis=!0,this.yAxis=!0,this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.roundDomains=!1,this.maxRadius=10,this.minRadius=3,this.schemeType=zi.Ordinal,this.tooltipDisabled=!1,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.scaleType=zi.Linear,this.margin=[10,20,10,20],this.bubblePadding=[0,0,0,0],this.xAxisHeight=0,this.yAxisWidth=0,this.activeEntries=[],this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.seriesDomain=this.results.map(u=>u.name),this.rDomain=this.getRDomain(),this.xDomain=this.getXDomain(),this.yDomain=this.getYDomain(),this.transform=`translate(${this.dims.xOffset},${this.margin[0]})`,this.colors=new iu(this.scheme,this.schemeType,this.schemeType===zi.Ordinal?this.seriesDomain:this.rDomain,this.customColors),this.data=this.results,this.minRadius=Math.max(this.minRadius,1),this.maxRadius=Math.max(this.maxRadius,1),this.rScale=this.getRScale(this.rDomain,[this.minRadius,this.maxRadius]),this.bubblePadding=[0,0,0,0],this.setScales(),this.bubblePadding=this.getBubblePadding(),this.setScales(),this.legendOptions=this.getLegendOptions(),this.clipPathId="clip"+Gu().toString(),this.clipPath=`url(#${this.clipPathId})`}hideCircles(){this.deactivateAll()}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}getBubblePadding(){let a=0,u=0,x=this.dims.height,I=this.dims.width;for(const K of this.data)for(const ye of K.series){const Ye=this.rScale(ye.r),$e=this.xScale(this.xScaleType===zi.Linear?Number(ye.x):ye.x),ht=this.yScale(this.yScaleType===zi.Linear?Number(ye.y):ye.y);u=Math.max(Ye-$e,u),a=Math.max(Ye-ht,a),x=Math.max(ht+Ye,x),I=Math.max($e+Ye,I)}return I=Math.max(I-this.dims.width,0),x=Math.max(x-this.dims.height,0),[a,I,x,u]}setScales(){let a=this.dims.width;void 0===this.xScaleMin&&void 0===this.xScaleMax&&(a-=this.bubblePadding[1]);let u=this.dims.height;void 0===this.yScaleMin&&void 0===this.yScaleMax&&(u-=this.bubblePadding[2]),this.xScale=this.getXScale(this.xDomain,a),this.yScale=this.getYScale(this.yDomain,u)}getYScale(a,u){return T_(a,[u,this.bubblePadding[0]],this.yScaleType,this.roundDomains)}getXScale(a,u){return T_(a,[this.bubblePadding[3],u],this.xScaleType,this.roundDomains)}getRScale(a,u){const x=ic().range(u).domain(a);return this.roundDomains?x.nice():x}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],position:this.legendPosition,title:void 0};return a.scaleType===zi.Ordinal?(a.domain=this.seriesDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.rDomain,a.colors=this.colors.scale),a}getXDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.x)||a.push(x.x);return this.xScaleType=Cm(a),Bb(a,this.xScaleType,this.autoScale,this.xScaleMin,this.xScaleMax)}getYDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.y)||a.push(x.y);return this.yScaleType=Cm(a),Bb(a,this.yScaleType,this.autoScale,this.yScaleMin,this.yScaleMax)}getRDomain(){let a=1/0,u=-1/0;for(const x of this.results)for(const I of x.series){const K=Number(I.r)||1;a=Math.min(a,K),u=Math.max(u,K)}return[a,u]}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name)>-1||(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}trackBy(a,u){return`${u.name}`}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-bubble-chart"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseleave",function(){return u.hideCircles()})},inputs:{showGridLines:"showGridLines",legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",roundDomains:"roundDomains",maxRadius:"maxRadius",minRadius:"minRadius",autoScale:"autoScale",schemeType:"schemeType",tooltipDisabled:"tooltipDisabled",xScaleMin:"xScaleMin",xScaleMax:"xScaleMax",yScaleMin:"yScaleMin",yScaleMax:"yScaleMax",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:10,vars:19,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","activeEntries","legendOptions","animations"],[1,"bubble-chart","chart"],["ngx-charts-x-axis","",3,"showGridLines","dims","xScale","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"showGridLines","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["x","0","y","0",1,"bubble-chart-area",2,"fill","rgb(255, 0, 0)","opacity","0","cursor","'auto'",3,"mouseenter"],[4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","showGridLines","dims","xScale","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","showGridLines","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-bubble-series","",3,"select","activate","deactivate","xScale","yScale","rScale","xScaleType","yScaleType","xAxisLabel","yAxisLabel","colors","data","activeEntries","tooltipDisabled","tooltipTemplate"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"defs")(2,"clipPath"),i.\u0275\u0275element(3,"rect"),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g",1),i.\u0275\u0275template(5,xb,1,11,"g",2)(6,f_,1,10,"g",3),i.\u0275\u0275elementStart(7,"rect",4),i.\u0275\u0275listener("mouseenter",function(){return u.deactivateAll()}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(8,p_,2,3,"g",5)(9,Sb,2,3,"g",5),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(16,mc,u.width,u.height))("showLegend",u.legend)("activeEntries",u.activeEntries)("legendOptions",u.legendOptions)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",u.clipPathId),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width+10)("height",u.dims.height+10)("transform","translate(-5, -5)"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width)("height",u.dims.height),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,lf,xf,Fw,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),M_=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),PS=(()=>{class c{constructor(a){this.gradient=!1,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.barOrientation=Jl,this.element=a.nativeElement}ngOnChanges(a){this.transform=`translate(${this.x} , ${this.y})`,this.startOpacity=.3,this.gradientId="grad"+Gu().toString(),this.gradientUrl=`url(#${this.gradientId})`,this.gradientStops=this.getGradientStops(),this.animations&&this.loadAnimation()}getGradientStops(){return[{offset:0,color:this.fill,opacity:this.startOpacity},{offset:100,color:this.fill,opacity:1}]}loadAnimation(){ta(this.element).select(".cell").attr("opacity",0),this.animateToCurrentForm()}animateToCurrentForm(){ta(this.element).select(".cell").transition().duration(750).attr("opacity",1)}onClick(){this.select.emit(this.data)}onMouseEnter(){this.activate.emit(this.data)}onMouseLeave(){this.deactivate.emit(this.data)}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-heat-map-cell",""]],hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseenter",function(){return u.onMouseEnter()})("mouseleave",function(){return u.onMouseLeave()})},inputs:{fill:"fill",x:"x",y:"y",width:"width",height:"height",data:"data",gradient:"gradient",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:_S,decls:3,vars:5,consts:[[1,"cell"],[4,"ngIf"],["rx","3",1,"cell",3,"click"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0),i.\u0275\u0275template(1,dC,2,3,"defs",1),i.\u0275\u0275elementStart(2,"rect",2),i.\u0275\u0275listener("click",function(){return u.onClick()}),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.gradient),i.\u0275\u0275advance(),i.\u0275\u0275attribute("fill",u.gradient?u.gradientUrl:u.fill)("width",u.width)("height",u.height))},dependencies:[ug,e.NgIf],encapsulation:2,changeDetection:0}),c})(),Vb=(()=>{class c{constructor(){this.tooltipDisabled=!1,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.placementTypes=Ys,this.styleTypes=Ju}ngOnInit(){this.tooltipText||(this.tooltipText=this.getTooltipText)}ngOnChanges(a){this.update()}update(){this.cells=this.getCells()}getCells(){const a=[];return this.data.map(u=>{u.series.map(x=>{const I=x.value;x.series=u.name,a.push({row:u,cell:x,x:this.xScale(u.name),y:this.yScale(x.name),width:this.xScale.bandwidth(),height:this.yScale.bandwidth(),fill:this.colors.getColor(I),data:I,label:nu(x.name),series:u.name})})}),a}getTooltipText({label:a,data:u,series:x}){return`\n <span class="tooltip-label">${Cu(x)} \u2022 ${Cu(a)}</span>\n <span class="tooltip-val">${u.toLocaleString()}</span>\n `}trackBy(a,u){return u.label}onClick(a){this.select.emit(a)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-heat-map-cell-series",""]],inputs:{data:"data",colors:"colors",xScale:"xScale",yScale:"yScale",gradient:"gradient",tooltipDisabled:"tooltipDisabled",tooltipText:"tooltipText",tooltipTemplate:"tooltipTemplate",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Ry,decls:1,vars:2,consts:[["ngx-charts-heat-map-cell","","ngx-tooltip","",3,"x","y","width","height","fill","data","gradient","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","select","activate","deactivate",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-heat-map-cell","","ngx-tooltip","",3,"select","activate","deactivate","x","y","width","height","fill","data","gradient","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,h_,1,18,"g",0),2&a&&i.\u0275\u0275property("ngForOf",u.cells)("ngForTrackBy",u.trackBy)},dependencies:[PS,e.NgForOf,Hp],encapsulation:2,changeDetection:0}),c})(),n0=(()=>{class c extends Wc{constructor(){super(...arguments),this.legendTitle="Legend",this.legendPosition=bu.Right,this.innerPadding=8,this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.tooltipDisabled=!1,this.activeEntries=[],this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.scaleType=zi.Linear}update(){if(super.update(),this.formatDates(),this.xDomain=this.getXDomain(),this.yDomain=this.getYDomain(),this.valueDomain=this.getValueDomain(),this.scaleType=Cm(this.valueDomain,!1),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.scaleType,legendPosition:this.legendPosition}),this.scaleType===zi.Linear){let a=this.min,u=this.max;this.min||(a=Math.min(0,...this.valueDomain)),this.max||(u=Math.max(...this.valueDomain)),this.valueDomain=[a,u]}this.xScale=this.getXScale(),this.yScale=this.getYScale(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`,this.rects=this.getRects()}getXDomain(){const a=[];for(const u of this.results)a.includes(u.name)||a.push(u.name);return a}getYDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.name)||a.push(x.name);return a}getValueDomain(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.value)||a.push(x.value);return a}getDimension(a,u=0,x,I){return"string"==typeof a&&(a=a.replace("[","").replace("]","").replace("px","").replace("'","")).includes(",")&&(a=a.split(",")),Array.isArray(a)&&"number"==typeof u?this.getDimension(a[u],null,x,I):"string"==typeof a&&a.includes("%")?+a.replace("%","")/100:x/(I/+a+1)}getXScale(){const a=this.getDimension(this.innerPadding,0,this.xDomain.length,this.dims.width);return Id().rangeRound([0,this.dims.width]).domain(this.xDomain).paddingInner(a)}getYScale(){const a=this.getDimension(this.innerPadding,1,this.yDomain.length,this.dims.height);return Id().rangeRound([this.dims.height,0]).domain(this.yDomain).paddingInner(a)}getRects(){const a=[];return this.xDomain.map(u=>{this.yDomain.map(x=>{a.push({x:this.xScale(u),y:this.yScale(x),rx:3,width:this.xScale.bandwidth(),height:this.yScale.bandwidth(),fill:"rgba(200,200,200,0.03)"})})}),a}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,this.scaleType,this.valueDomain)}getLegendOptions(){return{scaleType:this.scaleType,domain:this.valueDomain,colors:this.scaleType===zi.Ordinal?this.colors:this.colors.scale,title:this.scaleType===zi.Ordinal?this.legendTitle:void 0,position:this.legendPosition}}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name);const K=this.results.map(ye=>ye.series).flat().filter(ye=>x?ye.label===I.name:ye.name===I.name&&ye.series===I.series);this.activeEntries=[...K],this.activate.emit({value:I,entries:this.activeEntries})}onDeactivate(a,u,x=!1){const I=Object.assign({},a);u&&(I.series=u.name),this.activeEntries=this.activeEntries.filter(K=>x?K.label!==I.name:!(K.name===I.name&&K.series===I.series)),this.deactivate.emit({value:I,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-heat-map"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",gradient:"gradient",innerPadding:"innerPadding",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",tooltipDisabled:"tooltipDisabled",tooltipText:"tooltipText",min:"min",max:"max",activeEntries:"activeEntries",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:6,vars:20,consts:[[3,"legendLabelClick","view","showLegend","animations","legendOptions"],[1,"heat-map","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngFor","ngForOf"],["ngx-charts-heat-map-cell-series","",3,"select","activate","deactivate","xScale","yScale","colors","data","gradient","animations","tooltipDisabled","tooltipTemplate","tooltipText"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","wrapTicks"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,Ly,1,10,"g",2)(3,lT,1,9,"g",3)(4,ov,1,6,"rect",4),i.\u0275\u0275elementStart(5,"g",5),i.\u0275\u0275listener("select",function(I){return u.onClick(I)})("activate",function(I){return u.onActivate(I,void 0)})("deactivate",function(I){return u.onDeactivate(I,void 0)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",u.legend)("animations",u.animations)("legendOptions",u.legendOptions),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.rects),i.\u0275\u0275advance(),i.\u0275\u0275property("xScale",u.xScale)("yScale",u.yScale)("colors",u.colors)("data",u.results)("gradient",u.gradient)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("tooltipText",u.tooltipText))},dependencies:[cu,lf,xf,Vb,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),TC=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),BS=(()=>{class c{constructor(a,u){this.element=a,this.platformId=u,this.fill="none",this.animations=!0,this.initialized=!1,this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}ngOnChanges(a){this.initialized?this.updatePathEl():(this.initialized=!0,this.initialPath=this.path)}updatePathEl(){const a=ta(this.element.nativeElement).select(".line");this.animations?a.transition().duration(750).attr("d",this.path):a.attr("d",this.path)}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-line",""]],inputs:{path:"path",stroke:"stroke",data:"data",fill:"fill",animations:"animations"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:pw,decls:2,vars:2,consts:[[4,"ngIf"],["stroke-width","1.5px",1,"line"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,hw,2,4,"g",0)(1,m_,2,3,"g",0),2&a&&(i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[e.NgIf],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":enter",[(0,Gt.style)({strokeDasharray:2e3,strokeDashoffset:2e3}),(0,Gt.animate)(1e3,(0,Gt.style)({strokeDashoffset:0}))])])]},changeDetection:0}),c})(),MC=(()=>{class c{constructor(){this.animations=!0,this.barOrientation=Jl}ngOnChanges(a){this.update()}update(){this.updateGradients();const a=this.sortData(this.data.series),u=this.getLineGenerator();this.path=u(a)||"";const x=this.getAreaGenerator();if(this.areaPath=x(a)||"",this.hasRange){const I=this.getRangeGenerator();this.outerPath=I(a)||""}if(this.hasGradient){this.stroke=this.gradientUrl;const I=this.data.series.map(Ye=>Ye.value),K=Math.max(...I);K===Math.min(...I)&&(this.stroke=this.colors.getColor(K))}else this.stroke=this.colors.getColor(this.data.name)}getLineGenerator(){return Wm().x(a=>{const u=a.name;let x;return x=this.xScale(this.scaleType===zi.Time?u:this.scaleType===zi.Linear?Number(u):u),x}).y(a=>this.yScale(a.value)).curve(this.curve)}getRangeGenerator(){return Uv().x(a=>{const u=a.name;let x;return x=this.xScale(this.scaleType===zi.Time?u:this.scaleType===zi.Linear?Number(u):u),x}).y0(a=>this.yScale("number"==typeof a.min?a.min:a.value)).y1(a=>this.yScale("number"==typeof a.max?a.max:a.value)).curve(this.curve)}getAreaGenerator(){return Uv().x(u=>this.xScale(u.name)).y0(()=>this.yScale.range()[0]).y1(u=>this.yScale(u.value)).curve(this.curve)}sortData(a){return this.scaleType===zi.Linear?Xy(a,"name"):this.scaleType===zi.Time?dd(a,"name"):Zy(a,"name","asc",this.xScale.domain())}updateGradients(){if(this.colors.scaleType===zi.Linear){this.hasGradient=!0,this.gradientId="grad"+Gu().toString(),this.gradientUrl=`url(#${this.gradientId})`;const a=this.data.series.map(I=>I.value),u=Math.max(...a),x=Math.min(...a);this.gradientStops=this.colors.getLinearGradientStops(u,x),this.areaGradientStops=this.colors.getLinearGradientStops(u)}else this.hasGradient=!1,this.gradientStops=void 0,this.areaGradientStops=void 0}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name)}isInactive(a){return!(!this.activeEntries||0===this.activeEntries.length)&&void 0===this.activeEntries.find(x=>a.name===x.name)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-line-series",""]],inputs:{data:"data",xScale:"xScale",yScale:"yScale",colors:"colors",scaleType:"scaleType",curve:"curve",activeEntries:"activeEntries",rangeFillOpacity:"rangeFillOpacity",hasRange:"hasRange",animations:"animations"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:cT,decls:6,vars:22,consts:[["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops",4,"ngIf"],["ngx-charts-area","",1,"line-highlight",3,"data","path","fill","opacity","startOpacity","gradient","stops","animations"],["ngx-charts-line","",1,"line-series",3,"data","path","stroke","animations"],["ngx-charts-area","","class","line-series-range",3,"data","path","fill","active","inactive","opacity","animations",4,"ngIf"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"],["ngx-charts-area","",1,"line-series-range",3,"data","path","fill","opacity","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g")(1,"defs"),i.\u0275\u0275template(2,mw,1,3,"g",0),i.\u0275\u0275elementEnd(),i.\u0275\u0275element(3,"g",1)(4,"g",2),i.\u0275\u0275template(5,$p,1,9,"g",3),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275advance(2),i.\u0275\u0275property("ngIf",u.hasGradient),i.\u0275\u0275advance(),i.\u0275\u0275classProp("active",u.isActive(u.data))("inactive",u.isInactive(u.data)),i.\u0275\u0275property("data",u.data)("path",u.areaPath)("fill",u.hasGradient?u.gradientUrl:u.colors.getColor(u.data.name))("opacity",.25)("startOpacity",0)("gradient",!0)("stops",u.areaGradientStops)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275classProp("active",u.isActive(u.data))("inactive",u.isInactive(u.data)),i.\u0275\u0275property("data",u.data)("path",u.path)("stroke",u.stroke)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.hasRange))},dependencies:[ug,fg,BS,e.NgIf],encapsulation:2,changeDetection:0}),c})(),IC=(()=>{class c extends Wc{constructor(){super(...arguments),this.legendTitle="Legend",this.legendPosition=bu.Right,this.showGridLines=!0,this.curve=Nh,this.activeEntries=[],this.trimXAxisTicks=!0,this.trimYAxisTicks=!0,this.rotateXAxisTicks=!0,this.maxXAxisTickLength=16,this.maxYAxisTickLength=16,this.roundDomains=!1,this.tooltipDisabled=!1,this.showRefLines=!1,this.showRefLabels=!0,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.timelineHeight=50,this.timelinePadding=10,this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition}),this.timeline&&(this.dims.height-=this.timelineHeight+this.margin[2]+this.timelinePadding),this.xDomain=this.getXDomain(),this.filteredDomain&&(this.xDomain=this.filteredDomain),this.yDomain=this.getYDomain(),this.seriesDomain=this.getSeriesDomain(),this.xScale=this.getXScale(this.xDomain,this.dims.width),this.yScale=this.getYScale(this.yDomain,this.dims.height),this.updateTimeline(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`,this.clipPathId="clip"+Gu().toString(),this.clipPath=`url(#${this.clipPathId})`}updateTimeline(){this.timeline&&(this.timelineWidth=this.dims.width,this.timelineXDomain=this.getXDomain(),this.timelineXScale=this.getXScale(this.timelineXDomain,this.timelineWidth),this.timelineYScale=this.getYScale(this.yDomain,this.timelineHeight),this.timelineTransform=`translate(${this.dims.xOffset}, ${-this.margin[2]})`)}getXDomain(){let a=dv(this.results);this.scaleType=Cm(a);let x,I,u=[];return this.scaleType===zi.Linear&&(a=a.map(K=>Number(K))),(this.scaleType===zi.Time||this.scaleType===zi.Linear)&&(x=this.xScaleMin?this.xScaleMin:Math.min(...a),I=this.xScaleMax?this.xScaleMax:Math.max(...a)),this.scaleType===zi.Time?(u=[new Date(x),new Date(I)],this.xSet=[...a].sort((K,ye)=>{const Ye=K.getTime(),$e=ye.getTime();return Ye>$e?1:$e>Ye?-1:0})):this.scaleType===zi.Linear?(u=[x,I],this.xSet=[...a].sort((K,ye)=>K-ye)):(u=a,this.xSet=a),u}getYDomain(){const a=[];for(const K of this.results)for(const ye of K.series)a.indexOf(ye.value)<0&&a.push(ye.value),void 0!==ye.min&&(this.hasRange=!0,a.indexOf(ye.min)<0&&a.push(ye.min)),void 0!==ye.max&&(this.hasRange=!0,a.indexOf(ye.max)<0&&a.push(ye.max));const u=[...a];return this.autoScale||u.push(0),[this.yScaleMin?this.yScaleMin:Math.min(...u),this.yScaleMax?this.yScaleMax:Math.max(...u)]}getSeriesDomain(){return this.results.map(a=>a.name)}getXScale(a,u){let x;return this.scaleType===zi.Time?x=nm().range([0,u]).domain(a):this.scaleType===zi.Linear?(x=ic().range([0,u]).domain(a),this.roundDomains&&(x=x.nice())):this.scaleType===zi.Ordinal&&(x=up().range([0,u]).padding(.1).domain(a)),x}getYScale(a,u){const x=ic().range([u,0]).domain(a);return this.roundDomains?x.nice():x}updateDomain(a){this.filteredDomain=a,this.xDomain=this.filteredDomain,this.xScale=this.getXScale(this.xDomain,this.dims.width)}updateHoveredVertical(a){this.hoveredVertical=a.value,this.deactivateAll()}hideCircles(){this.hoveredVertical=null,this.deactivateAll()}onClick(a){this.select.emit(a)}trackBy(a,u){return`${u.name}`}setColors(){let a;a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain,this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){const a={scaleType:this.schemeType,colors:void 0,domain:[],title:void 0,position:this.legendPosition};return a.scaleType===zi.Ordinal?(a.domain=this.seriesDomain,a.colors=this.colors,a.title=this.legendTitle):(a.domain=this.yDomain,a.colors=this.colors.scale),a}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.deactivateAll(),!(this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1)&&(this.activeEntries=[a],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-line-chart"]],contentQueries:function(a,u,x){if(1&a&&(i.\u0275\u0275contentQuery(x,bo,5),i.\u0275\u0275contentQuery(x,Ym,5)),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first),i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.seriesTooltipTemplate=I.first)}},hostBindings:function(a,u){1&a&&i.\u0275\u0275listener("mouseleave",function(){return u.hideCircles()})},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",autoScale:"autoScale",timeline:"timeline",gradient:"gradient",showGridLines:"showGridLines",curve:"curve",activeEntries:"activeEntries",schemeType:"schemeType",rangeFillOpacity:"rangeFillOpacity",trimXAxisTicks:"trimXAxisTicks",trimYAxisTicks:"trimYAxisTicks",rotateXAxisTicks:"rotateXAxisTicks",maxXAxisTickLength:"maxXAxisTickLength",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",xAxisTicks:"xAxisTicks",yAxisTicks:"yAxisTicks",roundDomains:"roundDomains",tooltipDisabled:"tooltipDisabled",showRefLines:"showRefLines",referenceLines:"referenceLines",showRefLabels:"showRefLabels",xScaleMin:"xScaleMin",xScaleMax:"xScaleMax",yScaleMin:"yScaleMin",yScaleMax:"yScaleMax",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:12,vars:20,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"line-chart","chart"],["ngx-charts-x-axis","",3,"xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","referenceLines","showRefLines","showRefLabels","wrapTicks","dimensionsChanged",4,"ngIf"],[4,"ngIf"],[3,"mouseleave",4,"ngIf"],["ngx-charts-timeline","",3,"results","view","height","scheme","customColors","scaleType","legend","onDomainChange",4,"ngIf"],["ngx-charts-x-axis","",3,"dimensionsChanged","xScale","dims","showGridLines","showLabel","labelText","trimTicks","rotateTicks","maxTickLength","tickFormatting","ticks","wrapTicks"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","ticks","referenceLines","showRefLines","showRefLabels","wrapTicks"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-line-series","",3,"xScale","yScale","colors","data","activeEntries","scaleType","curve","rangeFillOpacity","hasRange","animations"],[3,"mouseleave"],["ngx-charts-tooltip-area","",3,"hover","dims","xSet","xScale","yScale","results","colors","tooltipDisabled","tooltipTemplate"],[4,"ngFor","ngForOf"],["ngx-charts-circle-series","",3,"select","activate","deactivate","xScale","yScale","colors","data","scaleType","visibleValue","activeEntries","tooltipDisabled","tooltipTemplate"],["ngx-charts-timeline","",3,"onDomainChange","results","view","height","scheme","customColors","scaleType","legend"],["ngx-charts-line-series","",3,"xScale","yScale","colors","data","scaleType","curve","hasRange","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"defs")(2,"clipPath"),i.\u0275\u0275element(3,"rect"),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(4,"g",1),i.\u0275\u0275template(5,ig,1,11,"g",2)(6,fC,1,13,"g",3),i.\u0275\u0275elementStart(7,"g"),i.\u0275\u0275template(8,vm,2,2,"g",4)(9,sv,2,2,"g",4)(10,ky,3,9,"g",5),i.\u0275\u0275elementEnd()(),i.\u0275\u0275template(11,rg,2,13,"g",6),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275attribute("id",u.clipPathId),i.\u0275\u0275advance(),i.\u0275\u0275attribute("width",u.dims.width+10)("height",u.dims.height+10)("transform","translate(-5, -5)"),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275attribute("clip-path",u.clipPath),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.tooltipDisabled),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.timeline&&"ordinal"!=u.scaleType))},dependencies:[cu,lf,xf,MC,x_,cv,hg,e.NgIf,e.NgForOf],styles:[qo],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),AC=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),VS=(()=>{class c{constructor(a){this.platformId=a,this.animations=!0,this.labelTrim=!0,this.labelTrimSize=10,this.trimLabel=cg}ngOnChanges(a){this.setTransforms(),this.update()}setTransforms(){if((0,e.isPlatformServer)(this.platformId))this.styleTransform=`translate3d(${this.textX}px,${this.textY}px, 0)`,this.attrTransform=`translate(${this.textX},${this.textY})`,this.textTransition=this.animations?"transform 0.75s":null;else{const a=/(edge|msie|trident)/i.test(navigator.userAgent);this.styleTransform=a?null:`translate3d(${this.textX}px,${this.textY}px, 0)`,this.attrTransform=a?`translate(${this.textX},${this.textY})`:null,this.textTransition=a||!this.animations?null:"transform 0.75s"}}update(){let a=this.radius;this.explodeSlices&&(a=this.radius*this.value/this.max);const x=y1().innerRadius(a).outerRadius(a).centroid(this.data);let I=this.data.pos[1]/x[1];(0===this.data.pos[1]||0===x[1])&&(I=1),this.line=`M${x}L${[I*x[0],I*x[1]]}L${this.data.pos}`}get textX(){return this.data.pos[0]}get textY(){return this.data.pos[1]}textAnchor(){return this.midAngle(this.data)<Math.PI?Nd.Start:Nd.End}midAngle(a){return a.startAngle+(a.endAngle-a.startAngle)/2}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-pie-label",""]],inputs:{data:"data",radius:"radius",label:"label",color:"color",max:"max",value:"value",explodeSlices:"explodeSlices",animations:"animations",labelTrim:"labelTrim",labelTrimSize:"labelTrimSize"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:CS,decls:6,vars:17,consts:[["dy",".35em",1,"pie-label"],["fill","none",1,"pie-label-line","line"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"title"),i.\u0275\u0275text(1),i.\u0275\u0275elementEnd(),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(2,"g")(3,"text",0),i.\u0275\u0275text(4),i.\u0275\u0275elementEnd()(),i.\u0275\u0275element(5,"path",1)),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate(u.label),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("transform",u.styleTransform)("transition",u.textTransition),i.\u0275\u0275attribute("transform",u.attrTransform),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("text-anchor",u.textAnchor())("shape-rendering","crispEdges"),i.\u0275\u0275classProp("animation",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275textInterpolate1(" ",u.labelTrim?u.trimLabel(u.label,u.labelTrimSize):u.label," "),i.\u0275\u0275advance(),i.\u0275\u0275classProp("animation",u.animations),i.\u0275\u0275attribute("d",u.line)("stroke",u.color))},encapsulation:2,changeDetection:0}),c})(),OC=(()=>{class c{constructor(){this.tooltipDisabled=!1,this.gradient=!1,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.circleRadius=3,this.barOrientation=Jl,this.placementTypes=Ys,this.styleTypes=Ju}ngOnChanges(a){this.update()}update(){this.updateGradients();const a=this.getLineGenerator(),u=this.sortData(this.data.series),x=this.data.name,I=this.colors.scaleType===zi.Linear,K=this.yScale.domain()[0];this.seriesColor=this.colors.getColor(I?K:x),this.path=a(u)||"",this.circles=u.map(ye=>{const Ye=this.getAngle(ye),$e=this.getRadius(ye),ht=ye.value,Vt=this.colors.getColor(I?Math.abs(ht):x);return{data:Object.assign({},ye,{series:x,value:ht,name:ye.name}),cx:$e*Math.sin(Ye),cy:-$e*Math.cos(Ye),value:ht,color:Vt,label:ye.name}}),this.active=this.isActive(this.data),this.inactive=this.isInactive(this.data),this.tooltipText=this.tooltipText||(ye=>this.defaultTooltipText(ye))}getAngle(a){const u=a.name;return this.xScale(this.scaleType===zi.Time?u:this.scaleType===zi.Linear?Number(u):u)}getRadius(a){return this.yScale(a.value)}getLineGenerator(){return function SD(){return function TE(c){var g=c.curve;return c.angle=c.x,delete c.x,c.radius=c.y,delete c.y,c.curve=function(a){return arguments.length?g(b1(a)):g()._curve},c}(Wm().curve(Lh))}().angle(a=>this.getAngle(a)).radius(a=>this.getRadius(a)).curve(this.curve)}sortData(a){return this.scaleType===zi.Linear?Xy(a,"name"):this.scaleType===zi.Time?dd(a,"name"):Zy(a,"name","asc",this.xScale.domain())}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name)}isInactive(a){return!(!this.activeEntries||0===this.activeEntries.length)&&void 0===this.activeEntries.find(x=>a.name===x.name)}defaultTooltipText({label:a,value:u}){return`\n <span class="tooltip-label">${Cu(this.data.name)} \u2022 ${Cu(a)}</span>\n <span class="tooltip-val">${u.toLocaleString()}</span>\n `}updateGradients(){if(this.hasGradient=this.gradient||this.colors.scaleType===zi.Linear,this.hasGradient)if(this.gradientId="grad"+Gu().toString(),this.gradientUrl=`url(#${this.gradientId})`,this.colors.scaleType===zi.Linear){const a=this.data.series.map(I=>I.value),u=Math.max(...a),x=Math.min(...a);this.gradientStops=this.colors.getLinearGradientStops(u,x)}else this.gradientStops=void 0}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-polar-series",""]],inputs:{name:"name",data:"data",xScale:"xScale",yScale:"yScale",colors:"colors",scaleType:"scaleType",curve:"curve",activeEntries:"activeEntries",rangeFillOpacity:"rangeFillOpacity",tooltipDisabled:"tooltipDisabled",tooltipText:"tooltipText",gradient:"gradient",tooltipTemplate:"tooltipTemplate",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:dT,decls:5,vars:11,consts:[[1,"polar-charts-series"],["ngx-charts-svg-radial-gradient","",3,"color","name","startOpacity","endOpacity","stops",4,"ngIf"],["ngx-charts-line","",1,"polar-series-path",3,"path","stroke","fill","animations"],["ngx-charts-circle","","class","circle","ngx-tooltip","",3,"cx","cy","r","fill","opacity","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","select","activate","deactivate",4,"ngFor","ngForOf"],["ngx-charts-svg-radial-gradient","",3,"color","name","startOpacity","endOpacity","stops"],["ngx-charts-circle","","ngx-tooltip","",1,"circle",3,"select","activate","deactivate","cx","cy","r","fill","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0)(1,"defs"),i.\u0275\u0275template(2,HM,1,5,"g",1),i.\u0275\u0275elementEnd(),i.\u0275\u0275element(3,"g",2),i.\u0275\u0275template(4,hC,1,12,"g",3),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275advance(2),i.\u0275\u0275property("ngIf",u.hasGradient),i.\u0275\u0275advance(),i.\u0275\u0275classProp("active",u.active)("inactive",u.inactive),i.\u0275\u0275property("path",u.path)("stroke",u.hasGradient?u.gradientUrl:u.seriesColor)("fill",u.hasGradient?u.gradientUrl:u.seriesColor)("animations",u.animations),i.\u0275\u0275attribute("fill-opacity",u.rangeFillOpacity),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.circles))},dependencies:[uv,BS,qy,e.NgIf,e.NgForOf,Hp],encapsulation:2,changeDetection:0}),c})();const jS=2*Math.PI;let qM=(()=>{class c extends Wc{constructor(){super(...arguments),this.legendTitle="Legend",this.legendPosition=bu.Right,this.showGridLines=!0,this.curve=Hm,this.activeEntries=[],this.rangeFillOpacity=.15,this.trimYAxisTicks=!0,this.maxYAxisTickLength=16,this.roundDomains=!1,this.tooltipDisabled=!1,this.showSeriesOnHover=!0,this.gradient=!1,this.yAxisMinScale=0,this.labelTrim=!0,this.labelTrimSize=10,this.wrapTicks=!1,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,20,10,20],this.xAxisHeight=0,this.yAxisWidth=0,this.orientation=cd,this.isSSR=!1}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&(this.isSSR=!0)}update(){super.update(),this.setDims(),this.setScales(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.setTicks()}setDims(){this.dims=uu({width:this.width,height:this.height,margins:this.margin,showXAxis:this.xAxis,showYAxis:this.yAxis,xAxisHeight:this.xAxisHeight,yAxisWidth:this.yAxisWidth,showXLabel:this.showXAxisLabel,showYLabel:this.showYAxisLabel,showLegend:this.legend,legendType:this.schemeType,legendPosition:this.legendPosition});const a=Math.floor(this.dims.width/2),u=Math.floor(this.dims.height/2),x=this.outerRadius=Math.min(u/1.5,a/1.5),I=Math.max(0,u-x);this.yAxisDims={...this.dims,width:a},this.transform=`translate(${this.dims.xOffset}, ${this.margin[0]})`,this.transformYAxis=`translate(0, ${I})`,this.labelOffset=this.dims.height+40,this.transformPlot=`translate(${a}, ${u})`}setScales(){const a=this.getXValues();this.scaleType=Cm(a),this.xDomain=this.filteredDomain||this.getXDomain(a),this.yDomain=this.getYDomain(),this.seriesDomain=this.getSeriesDomain(),this.xScale=this.getXScale(this.xDomain,jS),this.yScale=this.getYScale(this.yDomain,this.outerRadius),this.yAxisScale=this.getYScale(this.yDomain.reverse(),this.outerRadius)}setTicks(){let a;a=this.xAxisTickFormatting?this.xAxisTickFormatting:this.xScale.tickFormat?this.xScale.tickFormat.apply(this.xScale,[5]):K=>Hh(K)?K.toLocaleDateString():K.toLocaleString();const u=this.outerRadius;this.thetaTicks=this.xDomain.map(K=>{const ye=this.xScale(K),Ye=1.1*u*(ye>Math.PI?-1:1),$e=a(K),ht=[u*Math.sin(ye),-u*Math.cos(ye)];return{innerRadius:0,outerRadius:u,startAngle:ye,endAngle:ye,value:u,label:$e,startPos:ht,pos:[Ye,1.1*ht[1]]}});for(let K=0;K<this.thetaTicks.length-1;K++){const ye=this.thetaTicks[K];for(let Ye=K+1;Ye<this.thetaTicks.length;Ye++){const $e=this.thetaTicks[Ye];if($e.pos[0]*ye.pos[0]>0){const ht=10-Math.abs($e.pos[1]-ye.pos[1]);ht>0&&($e.pos[1]+=Math.sign($e.pos[0])*ht)}}}this.radiusTicks=this.yAxisScale.ticks(Math.floor(this.dims.height/50)).map(K=>this.yScale(K))}getXValues(){const a=[];for(const u of this.results)for(const x of u.series)a.includes(x.name)||a.push(x.name);return a}getXDomain(a=this.getXValues()){return this.scaleType===zi.Time?[Math.min(...a),Math.max(...a)]:this.scaleType===zi.Linear?(a=a.map(I=>Number(I)),[Math.min(...a),Math.max(...a)]):a}getYValues(){const a=[];for(const u of this.results)for(const x of u.series)a.indexOf(x.value)<0&&a.push(x.value),void 0!==x.min&&a.indexOf(x.min)<0&&a.push(x.min),void 0!==x.max&&a.indexOf(x.max)<0&&a.push(x.max);return a}getYDomain(a=this.getYValues()){let u=Math.min(...a);const x=Math.max(this.yAxisMinScale,...a);return u=Math.max(0,u),this.autoScale||(u=Math.min(0,u)),[u,x]}getSeriesDomain(){return this.results.map(a=>a.name)}getXScale(a,u){switch(this.scaleType){case zi.Time:return nm().range([0,u]).domain(a);case zi.Linear:{const x=ic().range([0,u]).domain(a);return this.roundDomains?x.nice():x}default:return up().range([0,u-jS/a.length]).padding(0).domain(a)}}getYScale(a,u){const x=ic().range([0,u]).domain(a);return this.roundDomains?x.nice():x}onClick(a,u){u&&(a.series=u.name),this.select.emit(a)}setColors(){const a=this.schemeType===zi.Ordinal?this.seriesDomain:this.yDomain.reverse();this.colors=new iu(this.scheme,this.schemeType,a,this.customColors)}getLegendOptions(){return this.schemeType===zi.Ordinal?{scaleType:this.schemeType,colors:this.colors,domain:this.seriesDomain,title:this.legendTitle,position:this.legendPosition}:{scaleType:this.schemeType,colors:this.colors.scale,domain:this.yDomain,title:void 0,position:this.legendPosition}}updateYAxisWidth({width:a}){this.yAxisWidth=a,this.update()}updateXAxisHeight({height:a}){this.xAxisHeight=a,this.update()}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1||(this.activeEntries=this.showSeriesOnHover?[a,...this.activeEntries]:this.activeEntries,this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}deactivateAll(){this.activeEntries=[...this.activeEntries];for(const a of this.activeEntries)this.deactivate.emit({value:a,entries:[]});this.activeEntries=[]}trackBy(a,u){return`${u.name}`}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-polar-chart"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",xAxis:"xAxis",yAxis:"yAxis",showXAxisLabel:"showXAxisLabel",showYAxisLabel:"showYAxisLabel",xAxisLabel:"xAxisLabel",yAxisLabel:"yAxisLabel",autoScale:"autoScale",showGridLines:"showGridLines",curve:"curve",activeEntries:"activeEntries",schemeType:"schemeType",rangeFillOpacity:"rangeFillOpacity",trimYAxisTicks:"trimYAxisTicks",maxYAxisTickLength:"maxYAxisTickLength",xAxisTickFormatting:"xAxisTickFormatting",yAxisTickFormatting:"yAxisTickFormatting",roundDomains:"roundDomains",tooltipDisabled:"tooltipDisabled",showSeriesOnHover:"showSeriesOnHover",gradient:"gradient",yAxisMinScale:"yAxisMinScale",labelTrim:"labelTrim",labelTrimSize:"labelTrimSize",wrapTicks:"wrapTicks"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:10,vars:17,consts:[[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"polar-chart","chart"],["cx","0","cy","0",1,"polar-chart-background"],[4,"ngIf"],["ngx-charts-y-axis","",3,"yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","wrapTicks","dimensionsChanged",4,"ngIf"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width",4,"ngIf"],["class","gridline-path radial-gridline-path","cx","0","cy","0",4,"ngFor","ngForOf"],["cx","0","cy","0",1,"gridline-path","radial-gridline-path"],["ngx-charts-pie-label","",3,"data","radius","label","max","value","explodeSlices","animations","labelTrim","labelTrimSize",4,"ngFor","ngForOf"],["ngx-charts-pie-label","",3,"data","radius","label","max","value","explodeSlices","animations","labelTrim","labelTrimSize"],["ngx-charts-y-axis","",3,"dimensionsChanged","yScale","dims","showGridLines","showLabel","labelText","trimTicks","maxTickLength","tickFormatting","wrapTicks"],["ngx-charts-axis-label","",3,"label","offset","orient","height","width"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-polar-series","",3,"select","activate","deactivate","gradient","xScale","yScale","colors","data","activeEntries","scaleType","curve","rangeFillOpacity","animations","tooltipDisabled","tooltipTemplate"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1)(2,"g"),i.\u0275\u0275element(3,"circle",2),i.\u0275\u0275template(4,Eb,2,1,"g",3)(5,$h,2,1,"g",3),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(6,DS,1,10,"g",4)(7,Tb,1,5,"g",5)(8,wS,2,3,"g",3)(9,fT,2,3,"g",3),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(14,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transformPlot),i.\u0275\u0275advance(),i.\u0275\u0275attribute("r",u.outerRadius),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showGridLines),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.yAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.xAxis&&u.showXAxisLabel),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",!u.isSSR),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.isSSR))},dependencies:[cu,VS,xf,Hy,OC,e.NgIf,e.NgForOf],styles:[qo,".pie-label{font-size:11px}.pie-label.animation{animation:.75s ease-in fadeIn}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{animation:3s linear drawOut;transition:d .75s}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}\n",".polar-chart .polar-chart-background{fill:none}.polar-chart .radial-gridline-path{stroke-dasharray:10 10;fill:none}.polar-chart .pie-label-line{stroke:#2f3646}.polar-charts-series .polar-series-area,.polar-series-path{pointer-events:none}\n"],encapsulation:2,data:{animation:[(0,Gt.trigger)("animationState",[(0,Gt.transition)(":leave",[(0,Gt.style)({opacity:1}),(0,Gt.animate)(500,(0,Gt.style)({opacity:0}))])])]},changeDetection:0}),c})(),mh=(()=>{class c{constructor(a){this.startAngle=0,this.endAngle=2*Math.PI,this.cornerRadius=0,this.explodeSlices=!1,this.gradient=!1,this.animate=!0,this.pointerEvents=!0,this.isActive=!1,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.dblclick=new i.EventEmitter,this.barOrientation=Jl,this.initialized=!1,this.element=a.nativeElement}ngOnChanges(a){this.update()}getGradient(){return this.gradient?this.gradientFill:this.fill}getPointerEvents(){return this.pointerEvents?"auto":"none"}update(){const a=this.calculateArc();this.startOpacity=.5,this.radialGradientId="linearGrad"+Gu().toString(),this.gradientFill=`url(#${this.radialGradientId})`,this.animate?this.initialized?this.updateAnimation():(this.loadAnimation(),this.initialized=!0):this.path=a.startAngle(this.startAngle).endAngle(this.endAngle)()}calculateArc(){let a=this.outerRadius;return this.explodeSlices&&0===this.innerRadius&&(a=this.outerRadius*this.value/this.max),y1().innerRadius(this.innerRadius).outerRadius(a).cornerRadius(this.cornerRadius)}loadAnimation(){const a=ta(this.element).selectAll(".arc").data([{startAngle:this.startAngle,endAngle:this.endAngle}]),u=this.calculateArc();a.transition().attrTween("d",function(x){this._current=this._current||x;const I=Object.assign({},x);I.endAngle=I.startAngle;const K=qs(I,I);return this._current=K(0),function(ye){return u(K(ye))}}).transition().duration(750).attrTween("d",function(x){this._current=this._current||x;const I=qs(this._current,x);return this._current=I(0),function(K){return u(I(K))}})}updateAnimation(){const a=ta(this.element).selectAll(".arc").data([{startAngle:this.startAngle,endAngle:this.endAngle}]),u=this.calculateArc();a.transition().duration(750).attrTween("d",function(x){this._current=this._current||x;const I=qs(this._current,x);return this._current=I(0),function(K){return u(I(K))}})}onClick(){clearTimeout(this._timeout),this._timeout=setTimeout(()=>this.select.emit(this.data),200)}onDblClick(a){a.preventDefault(),a.stopPropagation(),clearTimeout(this._timeout),this.dblclick.emit({data:this.data,nativeEvent:a})}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-pie-arc",""]],inputs:{fill:"fill",startAngle:"startAngle",endAngle:"endAngle",innerRadius:"innerRadius",outerRadius:"outerRadius",cornerRadius:"cornerRadius",value:"value",max:"max",data:"data",explodeSlices:"explodeSlices",gradient:"gradient",animate:"animate",pointerEvents:"pointerEvents",isActive:"isActive"},outputs:{select:"select",activate:"activate",deactivate:"deactivate",dblclick:"dblclick"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:v_,decls:3,vars:7,consts:[[1,"arc-group"],[4,"ngIf"],[1,"arc",3,"click","dblclick","mouseenter","mouseleave"],["ngx-charts-svg-radial-gradient","",3,"color","name","startOpacity"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0),i.\u0275\u0275template(1,SS,2,3,"defs",1),i.\u0275\u0275elementStart(2,"path",2),i.\u0275\u0275listener("click",function(){return u.onClick()})("dblclick",function(I){return u.onDblClick(I)})("mouseenter",function(){return u.activate.emit(u.data)})("mouseleave",function(){return u.deactivate.emit(u.data)}),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.gradient),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("pointer-events",u.getPointerEvents()),i.\u0275\u0275classProp("active",u.isActive),i.\u0275\u0275attribute("d",u.path)("fill",u.getGradient()))},dependencies:[uv,e.NgIf],encapsulation:2,changeDetection:0}),c})(),FC=(()=>{class c{constructor(){this.series=[],this.innerRadius=60,this.outerRadius=80,this.trimLabels=!0,this.maxLabelLength=10,this.tooltipDisabled=!1,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.dblclick=new i.EventEmitter,this.placementTypes=Ys,this.styleTypes=Ju}ngOnChanges(a){this.update()}update(){const u=lm().value(x=>x.value).sort(null)(this.series);this.max=ey(u,x=>x.value),this.data=this.calculateLabelPositions(u),this.tooltipText=this.tooltipText||this.defaultTooltipText}midAngle(a){return a.startAngle+(a.endAngle-a.startAngle)/2}outerArc(){return y1().innerRadius(1.5*this.outerRadius).outerRadius(1.5*this.outerRadius)}calculateLabelPositions(a){const I=a;I.forEach(K=>{K.pos=this.outerArc().centroid(K),K.pos[0]=1.5*this.outerRadius*(this.midAngle(K)<Math.PI?1:-1)});for(let K=0;K<I.length-1;K++){const ye=I[K];if(this.labelVisible(ye))for(let Ye=K+1;Ye<I.length;Ye++){const $e=I[Ye];if(this.labelVisible($e)&&$e.pos[0]*ye.pos[0]>0){const ht=10-Math.abs($e.pos[1]-ye.pos[1]);ht>0&&($e.pos[1]+=Math.sign($e.pos[0])*ht)}}}return I}labelVisible(a){return this.showLabels&&a.endAngle-a.startAngle>Math.PI/30}getTooltipTitle(a){return this.tooltipTemplate?void 0:this.tooltipText(a)}labelText(a){return this.labelFormatting?this.labelFormatting(a.data.name):this.label(a)}label(a){return nu(a.data.name)}defaultTooltipText(a){const u=this.label(a),x=nu(a.data.value);return`\n <span class="tooltip-label">${Cu(u)}</span>\n <span class="tooltip-val">${x}</span>\n `}color(a){return this.colors.getColor(this.label(a))}trackBy(a,u){return u.data.name}onClick(a){this.select.emit(a)}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name&&a.series===x.series)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-pie-series",""]],inputs:{colors:"colors",series:"series",dims:"dims",innerRadius:"innerRadius",outerRadius:"outerRadius",explodeSlices:"explodeSlices",showLabels:"showLabels",gradient:"gradient",activeEntries:"activeEntries",labelFormatting:"labelFormatting",trimLabels:"trimLabels",maxLabelLength:"maxLabelLength",tooltipText:"tooltipText",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate",dblclick:"dblclick"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:pT,decls:1,vars:2,consts:[[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-pie-label","",3,"data","radius","color","label","labelTrim","labelTrimSize","max","value","explodeSlices","animations",4,"ngIf"],["ngx-charts-pie-arc","","ngx-tooltip","",3,"select","activate","deactivate","dblclick","startAngle","endAngle","innerRadius","outerRadius","fill","value","gradient","data","max","explodeSlices","isActive","animate","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"],["ngx-charts-pie-label","",3,"data","radius","color","label","labelTrim","labelTrimSize","max","value","explodeSlices","animations"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,_w,3,19,"g",0),2&a&&i.\u0275\u0275property("ngForOf",u.data)("ngForTrackBy",u.trackBy)},dependencies:[VS,mh,e.NgForOf,e.NgIf,Hp],encapsulation:2,changeDetection:0}),c})(),CT=(()=>{class c extends Wc{constructor(){super(...arguments),this.activeEntries=[],this.tooltipDisabled=!1,this.label="Total",this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[20,20,20,20]}update(){super.update(),this.dims=uu({width:4*this.width/12,height:this.height,margins:this.margin}),this.formatDates(),this.domain=this.getDomain(),this.setColors();const a=this.dims.width/2,u=this.margin[0]+this.dims.height/2;this.legendWidth=this.width-this.dims.width-this.margin[1],this.outerRadius=Math.min(this.dims.width,this.dims.height)/2.5,this.innerRadius=.75*this.outerRadius,this.transform=`translate(${a} , ${u})`}getDomain(){return this.results.map(a=>a.label)}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}onActivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name),!(this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series)>-1)&&(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name);const x=this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series);this.activeEntries.splice(x,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-advanced-pie-chart"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{gradient:"gradient",activeEntries:"activeEntries",tooltipDisabled:"tooltipDisabled",tooltipText:"tooltipText",label:"label",valueFormatting:"valueFormatting",nameFormatting:"nameFormatting",percentageFormatting:"percentageFormatting"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:7,vars:37,consts:[[1,"advanced-pie","chart"],[3,"view","showLegend","animations"],[1,"pie","chart"],["ngx-charts-pie-series","",3,"select","activate","deactivate","colors","series","innerRadius","activeEntries","outerRadius","gradient","tooltipDisabled","tooltipTemplate","tooltipText","animations"],[1,"advanced-pie-legend-wrapper"],[3,"select","activate","deactivate","data","colors","width","label","animations","valueFormatting","labelFormatting","percentageFormatting"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"div")(1,"div",0)(2,"ngx-charts-chart",1),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(3,"g",2)(4,"g",3),i.\u0275\u0275listener("select",function(I){return u.onClick(I)})("activate",function(I){return u.onActivate(I)})("deactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275elementEnd()()()(),i.\u0275\u0275namespaceHTML(),i.\u0275\u0275elementStart(5,"div",4)(6,"ngx-charts-advanced-legend",5),i.\u0275\u0275listener("select",function(I){return u.onClick(I)})("activate",function(I){return u.onActivate(I,!0)})("deactivate",function(I){return u.onDeactivate(I,!0)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275styleProp("width",u.width,"px")("height",u.height,"px"),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("width",u.dims.width,"px")("height",u.dims.height,"px"),i.\u0275\u0275advance(),i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(34,mc,u.width,u.height))("showLegend",!1)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("colors",u.colors)("series",u.results)("innerRadius",u.innerRadius)("activeEntries",u.activeEntries)("outerRadius",u.outerRadius)("gradient",u.gradient)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("tooltipText",u.tooltipText)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("width",u.width-u.dims.width,"px")("height",u.height,"px"),i.\u0275\u0275advance(),i.\u0275\u0275property("data",u.results)("colors",u.colors)("width",u.width-u.dims.width-u.margin[1])("label",u.label)("animations",u.animations)("valueFormatting",u.valueFormatting)("labelFormatting",u.nameFormatting)("percentageFormatting",u.percentageFormatting))},dependencies:[cu,FC,Yy],styles:[qo,".advanced-pie{display:inline-block;float:left}.advanced-pie-legend-wrapper{display:inline-block}\n"],encapsulation:2,changeDetection:0}),c})(),r0=(()=>{class c extends Wc{constructor(){super(...arguments),this.labels=!1,this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.explodeSlices=!1,this.doughnut=!1,this.arcWidth=.25,this.activeEntries=[],this.tooltipDisabled=!1,this.trimLabels=!0,this.maxLabelLength=10,this.dblclick=new i.EventEmitter,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter}update(){super.update(),this.labels&&this.hasNoOptionalMarginsSet()?this.margins=[30,80,30,80]:!this.labels&&this.hasNoOptionalMarginsSet()&&(this.margins=[20,20,20,20]),this.dims=uu({width:this.width,height:this.height,margins:this.margins,showLegend:this.legend,legendPosition:this.legendPosition}),this.formatDates(),this.translation=`translate(${this.margins[3]+this.dims.width/2}, ${this.margins[0]+this.dims.height/2})`,this.outerRadius=Math.min(this.dims.width,this.dims.height),this.outerRadius/=this.labels?3:2,this.innerRadius=0,this.doughnut&&(this.innerRadius=this.outerRadius*(1-this.arcWidth)),this.domain=this.getDomain(),this.data=this.results.sort((x,I)=>this.domain.indexOf(x.name)-this.domain.indexOf(I.name)),this.setColors(),this.legendOptions=this.getLegendOptions()}getDomain(){return this.results.map(a=>a.label)}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}getLegendOptions(){return{scaleType:zi.Ordinal,domain:this.domain,colors:this.colors,title:this.legendTitle,position:this.legendPosition}}onActivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name),!(this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series)>-1)&&(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name);const x=this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series);this.activeEntries.splice(x,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}hasNoOptionalMarginsSet(){return!this.margins||this.margins.length<=0}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-pie-chart"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{labels:"labels",legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",explodeSlices:"explodeSlices",doughnut:"doughnut",arcWidth:"arcWidth",gradient:"gradient",activeEntries:"activeEntries",tooltipDisabled:"tooltipDisabled",labelFormatting:"labelFormatting",trimLabels:"trimLabels",maxLabelLength:"maxLabelLength",tooltipText:"tooltipText",margins:"margins"},outputs:{dblclick:"dblclick",select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:3,vars:24,consts:[[3,"legendLabelActivate","legendLabelDeactivate","legendLabelClick","view","showLegend","legendOptions","activeEntries","animations"],[1,"pie-chart","chart"],["ngx-charts-pie-series","",3,"dblclick","select","activate","deactivate","colors","series","showLabels","labelFormatting","trimLabels","maxLabelLength","activeEntries","innerRadius","outerRadius","explodeSlices","gradient","animations","tooltipDisabled","tooltipTemplate","tooltipText"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275listener("legendLabelActivate",function(I){return u.onActivate(I,!0)})("legendLabelDeactivate",function(I){return u.onDeactivate(I,!0)})("legendLabelClick",function(I){return u.onClick(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1)(2,"g",2),i.\u0275\u0275listener("dblclick",function(I){return u.dblclick.emit(I)})("select",function(I){return u.onClick(I)})("activate",function(I){return u.onActivate(I)})("deactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(21,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.translation),i.\u0275\u0275advance(),i.\u0275\u0275property("colors",u.colors)("series",u.data)("showLabels",u.labels)("labelFormatting",u.labelFormatting)("trimLabels",u.trimLabels)("maxLabelLength",u.maxLabelLength)("activeEntries",u.activeEntries)("innerRadius",u.innerRadius)("outerRadius",u.outerRadius)("explodeSlices",u.explodeSlices)("gradient",u.gradient)("animations",u.animations)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("tooltipText",u.tooltipText))},dependencies:[cu,FC],styles:[qo,".pie-label{font-size:11px}.pie-label.animation{animation:.75s ease-in fadeIn}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{animation:3s linear drawOut;transition:d .75s}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}\n"],encapsulation:2,changeDetection:0}),c})();function DT(c,g,a){let u=1,x=g;const I=c.width;if(I>a)for(;I/x<a;)u+=1,x=Math.ceil(g/u);return[x,u]}function NC(c,g,a,u){const x=Id(),I=Id(),K=c.width,ye=c.height,[Ye,$e]=DT(c,g.length,a),ht=[],Vt=[];for(let si=0;si<$e;si++)Vt.push(si);for(let si=0;si<Ye;si++)ht.push(si);x.domain(ht),I.domain(Vt),x.rangeRound([0,K],.1),I.rangeRound([0,ye],.1);const zt=[],yn=u||function Dm(c){return c.map(g=>g?g.value:0).reduce((g,a)=>g+a,0)}(g),li=x.bandwidth(),pr=I.bandwidth();for(let si=0;si<g.length;si++)zt[si]={},zt[si].data={name:g[si]?g[si].name:"",value:g[si]?g[si].value:void 0,extra:g[si]?g[si].extra:void 0,label:g[si]?g[si].label:""},zt[si].x=x(si%Ye),zt[si].y=I(Math.floor(si/Ye)),zt[si].width=li,zt[si].height=pr,zt[si].data.percent=yn>0?zt[si].data.value/yn:0,zt[si].data.total=yn;return zt}let US=(()=>{class c{constructor(a){this.innerRadius=70,this.outerRadius=80,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.element=a.nativeElement}ngOnChanges(a){this.update()}update(){this.layout=lm().value(a=>a.data.value).sort(null),this.arcs=this.getArcs()}getArcs(){return this.layout(this.data).map((a,u)=>{const x=a.data.data.name,I=a.data.data.other;0===u&&(a.startAngle=0);const K=this.colors(x);return{data:a.data.data,class:"arc arc"+u,fill:K,startAngle:I?0:a.startAngle,endAngle:a.endAngle,animate:this.animations&&!I,pointerEvents:!I}})}onClick(a){this.select.emit(this.data[0].data)}trackBy(a,u){return u.data.name}label(a){return a.data.name}color(a){return this.colors(this.label(a))}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-pie-grid-series",""]],inputs:{colors:"colors",data:"data",innerRadius:"innerRadius",outerRadius:"outerRadius",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Mb,decls:2,vars:2,consts:[[1,"pie-grid-arcs"],["ngx-charts-pie-arc","",3,"startAngle","endAngle","innerRadius","outerRadius","fill","value","data","gradient","pointerEvents","animate","select","activate","deactivate",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-pie-arc","",3,"select","activate","deactivate","startAngle","endAngle","innerRadius","outerRadius","fill","value","data","gradient","pointerEvents","animate"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",0),i.\u0275\u0275template(1,ES,1,11,"g",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.arcs)("ngForTrackBy",u.trackBy))},dependencies:[mh,e.NgForOf],encapsulation:2,changeDetection:0}),c})(),jb=(()=>{class c extends Wc{constructor(){super(...arguments),this.tooltipDisabled=!1,this.label="Total",this.minWidth=150,this.activeEntries=[],this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[20,20,20,20],this.placementTypes=Ys,this.styleTypes=Ju}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin}),this.formatDates(),this.domain=this.getDomain(),this.data=NC(this.dims,this.results,this.minWidth,this.designatedTotal),this.transform=`translate(${this.margin[3]} , ${this.margin[0]})`,this.series=this.getSeries(),this.setColors(),this.tooltipText=this.tooltipText||this.defaultTooltipText}defaultTooltipText({data:a}){return`\n <span class="tooltip-label">${cg(nu(a.name))}</span>\n <span class="tooltip-val">${a.value.toLocaleString()}</span>\n `}getDomain(){return this.results.map(a=>a.label)}getSeries(){const a=this.designatedTotal?this.designatedTotal:this.getTotal();return this.data.map(u=>{const K=u.data.name,ye=nu(K),Ye=u.data.value,$e=h1([u.width-10,u.height-20])/2-5;let Vt=0;return{transform:`translate(${u.x+(u.width-10)/2}, ${u.y+(u.height-20)/2})`,colors:()=>(Vt+=1,1===Vt?"rgba(100,100,100,0.3)":this.colorScale.getColor(ye)),innerRadius:.9*$e,outerRadius:$e,name:K,label:cg(ye),total:Ye,value:Ye,percent:L0(".1%")(u.data.percent),data:[u,{data:{other:!0,value:a-Ye,name:u.data.name}}]}})}getTotal(){return this.results.map(a=>a.value).reduce((a,u)=>a+u,0)}onClick(a){this.select.emit(a)}setColors(){this.colorScale=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}onActivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name),!(this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series)>-1)&&(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a,u=!1){a=this.results.find(I=>u?I.label===a.name:I.name===a.name);const x=this.activeEntries.findIndex(I=>I.name===a.name&&I.value===a.value&&I.series===a.series);this.activeEntries.splice(x,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-pie-grid"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{designatedTotal:"designatedTotal",tooltipDisabled:"tooltipDisabled",tooltipText:"tooltipText",label:"label",minWidth:"minWidth",activeEntries:"activeEntries"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:3,vars:8,consts:[[3,"view","showLegend","animations"],[1,"pie-grid","chart"],["class","pie-grid-item",4,"ngFor","ngForOf"],[1,"pie-grid-item"],["ngx-charts-pie-grid-series","","ngx-tooltip","",3,"select","activate","deactivate","colors","data","innerRadius","outerRadius","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"],["class","label percent-label","dy","-0.5em","x","0","y","5","ngx-charts-count-up","","text-anchor","middle",3,"countTo","countSuffix",4,"ngIf"],["class","label percent-label","dy","-0.5em","x","0","y","5","text-anchor","middle",4,"ngIf"],["dy","0.5em","x","0","y","5","text-anchor","middle",1,"label"],["class","label","dy","1.23em","x","0","text-anchor","middle","ngx-charts-count-up","",3,"countTo","countPrefix",4,"ngIf"],["class","label","dy","1.23em","x","0","text-anchor","middle",4,"ngIf"],["dy","-0.5em","x","0","y","5","ngx-charts-count-up","","text-anchor","middle",1,"label","percent-label",3,"countTo","countSuffix"],["dy","-0.5em","x","0","y","5","text-anchor","middle",1,"label","percent-label"],["dy","1.23em","x","0","text-anchor","middle","ngx-charts-count-up","",1,"label",3,"countTo","countPrefix"],["dy","1.23em","x","0","text-anchor","middle",1,"label"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,Ab,8,19,"g",2),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(5,mc,u.width,u.height))("showLegend",!1)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.series))},dependencies:[cu,US,Gh,e.NgForOf,Hp,e.NgIf],styles:[qo,".pie-grid .arc1{opacity:.4}.pie-grid .percent-label{font-size:16px;font-weight:400}\n"],encapsulation:2,changeDetection:0}),c})(),o0=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),s0=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf,o0,AC]]}),c})();function Ub(c,g,a=8){return g.split("").reduce((u,x)=>u+(c[x]||a),0)}const $b={0:10,1:10,2:10,3:10,4:10,5:10,6:10,7:10,8:10,9:10,A:11,B:11,C:11,D:12,E:10,F:9,G:12,H:12,I:7,J:7,K:11,L:9,M:13,N:12,O:13,P:10,Q:13,R:11,S:11,T:10,U:12,V:11,W:16,X:11,Y:10,Z:11,a:10,b:10,c:8,d:10,e:10,f:6,g:10,h:10,i:4,j:6,k:9,l:4,m:16,n:10,o:10,p:10,q:10,r:7,s:8,t:6,u:10,v:9,w:13,x:9,y:9,z:8,"!":6,"@":16,"#":13,$:10,"%":17,"^":13,"&":12,"*":10,"(":7,")":7,_:10,"-":7,"+":13,"=":13,",":6,".":6,"/":7,"'":4,":":7,"|":7,"?":9,";":7,"<":13,">":13};let Nw=(()=>{class c{constructor(a,u,x,I){this.cd=u,this.zone=x,this.platformId=I,this.animations=!0,this.select=new i.EventEmitter,this.value="",this.textFontSize=12,this.textTransform="",this.initialized=!1,this.bandHeight=10,this.textPadding=[10,20,5,20],this.labelFontSize=15,this.element=a.nativeElement}ngOnChanges(a){this.update()}ngOnInit(){(0,e.isPlatformServer)(this.platformId)&&this.scaleTextSSR()}ngOnDestroy(){(0,e.isPlatformBrowser)(this.platformId)&&cancelAnimationFrame(this.animationReq)}update(){this.zone.run(()=>{const a=this.data&&typeof this.data.value<"u",u=this.valueFormatting||(ye=>ye.value.toLocaleString()),x=this.labelFormatting||(ye=>Cu(cg(ye.label,55)));this.transform=`translate(${this.x} , ${this.y})`,this.textWidth=Math.max(0,this.width)-this.textPadding[1]-this.textPadding[3],this.cardWidth=Math.max(0,this.width),this.cardHeight=Math.max(0,this.height),this.label=this.label?this.label:this.data.name;const I={label:this.label,data:this.data,value:this.data.value};this.formattedLabel=x(I),this.transformBand=`translate(0 , ${this.cardHeight-this.bandHeight})`;const K=a?u(I):"";this.value=this.paddedValue(K),this.setPadding(),this.bandPath=bm(0,0,this.cardWidth,this.bandHeight,3,[!1,!1,!0,!0]),setTimeout(()=>{(0,e.isPlatformBrowser)(this.platformId)&&this.scaleText(),this.value=K,a&&!this.initialized&&setTimeout(()=>this.startCount(),20)},8)})}paddedValue(a){return this.medianSize&&this.medianSize>a.length&&(a+="\u2007".repeat(this.medianSize-a.length)),a}startCount(){if(!this.initialized&&this.animations){cancelAnimationFrame(this.animationReq);const a=this.data.value,u=pg(a),x=this.valueFormatting||(K=>K.value.toLocaleString());this.animationReq=bC(0,a,u,1,({value:K,finished:ye})=>{this.zone.run(()=>{this.value=x({label:this.label,data:this.data,value:K=ye?a:K}),ye||(this.value=this.paddedValue(this.value)),this.cd.markForCheck()})}),this.initialized=!0}}scaleText(){this.zone.run(()=>{const{width:a,height:u}=this.textEl.nativeElement.getBoundingClientRect();if(0===a||0===u)return;const x=this.textPadding[1]=this.textPadding[3]=this.cardWidth/8,ye=Math.min((this.cardWidth-2*x)/a,this.cardHeight/3/u);this.textFontSize=Math.floor(this.textFontSize*ye),this.labelFontSize=Math.min(this.textFontSize,15),this.setPadding(),this.cd.markForCheck()})}scaleTextSSR(){const a=Ub($b,this.value,10),x=this.textPadding[1]=this.textPadding[3]=this.cardWidth/8,ye=Math.min((this.cardWidth-2*x)/a,this.cardHeight/3/18);this.textFontSize=Math.floor(this.textFontSize*ye),this.labelFontSize=Math.min(this.textFontSize,15),this.setPadding()}setPadding(){this.textPadding[1]=this.textPadding[3]=this.cardWidth/8;const a=this.cardHeight/2;this.textPadding[0]=a-this.textFontSize-this.labelFontSize/2,this.textPadding[2]=a-this.labelFontSize}onClick(){this.select.emit(this.data)}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(i.NgZone),i.\u0275\u0275directiveInject(i.PLATFORM_ID))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-card",""]],viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(Ob,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.textEl=x.first)}},inputs:{color:"color",bandColor:"bandColor",textColor:"textColor",x:"x",y:"y",width:"width",height:"height",label:"label",data:"data",medianSize:"medianSize",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:MS,decls:10,vars:25,consts:[["textEl",""],[1,"cell",3,"click"],["rx","3","ry","3",1,"card"],["class","card-band","stroke","none",4,"ngIf"],["x","5","alignment-baseline","hanging",1,"trimmed-label"],[3,"innerHTML"],["text-anchor","start","alignment-baseline","hanging",1,"value-text"],["stroke","none",1,"card-band"]],template:function(a,u){if(1&a){const x=i.\u0275\u0275getCurrentView();i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g",1),i.\u0275\u0275listener("click",function(){return i.\u0275\u0275restoreView(x),i.\u0275\u0275resetView(u.onClick())}),i.\u0275\u0275element(1,"rect",2),i.\u0275\u0275template(2,By,1,3,"path",3),i.\u0275\u0275elementStart(3,"title"),i.\u0275\u0275text(4),i.\u0275\u0275elementEnd(),i.\u0275\u0275elementStart(5,"foreignObject",4),i.\u0275\u0275namespaceHTML(),i.\u0275\u0275element(6,"p",5),i.\u0275\u0275elementEnd(),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(7,"text",6,0),i.\u0275\u0275text(9),i.\u0275\u0275elementEnd()()}2&a&&(i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("fill",u.color),i.\u0275\u0275attribute("width",u.cardWidth)("height",u.cardHeight),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.bandColor&&u.bandColor!==u.color),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate(u.label),i.\u0275\u0275advance(),i.\u0275\u0275attribute("x",u.textPadding[3])("y",u.cardHeight-u.textPadding[2])("width",u.textWidth)("height",u.labelFontSize+u.textPadding[2]),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("color",u.textColor)("font-size",u.labelFontSize,"px")("line-height",u.labelFontSize,"px"),i.\u0275\u0275property("innerHTML",u.formattedLabel,i.\u0275\u0275sanitizeHtml),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("fill",u.textColor)("font-size",u.textFontSize,"pt"),i.\u0275\u0275attribute("x",u.textPadding[3])("y",u.textPadding[0]),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",u.value," "))},dependencies:[e.NgIf],encapsulation:2,changeDetection:0}),c})();function RC(c){return at(c)}function Rw(c){const g=at(c),{r:a,g:u,b:x,opacity:I}=g;return 0===I?g.toString():$S(g,(299*a+587*u+114*x)/1e3>=128?-.8:.8)}function $S({r:c,g,b:a},u){const x=u<0?0:255,I=u<0?-1*u:u;return`rgb(${c=Math.round((x-c)*I)+c}, ${g=Math.round((x-g)*I)+g}, ${a=Math.round((x-a)*I)+a})`}let I_=(()=>{class c{constructor(){this.innerPadding=15,this.emptyColor="rgba(0, 0, 0, 0)",this.animations=!0,this.select=new i.EventEmitter}ngOnChanges(a){this.update()}update(){if(this.data.length>2){const u=this.valueFormatting||(K=>K.value.toLocaleString()),x=this.data.map(K=>K&&K.data&&typeof K.data.value<"u"&&null!==K.data.value?u({data:K.data,label:K?K.data.name:"",value:K&&K.data?K.data.value:""}).length:0).sort((K,ye)=>ye-K),I=Math.ceil(this.data.length/2);this.medianSize=x[I]}const a=this.getCards();this.cards=a.filter(u=>null!==u.data.value),this.emptySlots=a.filter(u=>null===u.data.value)}getCards(){const a="number"==typeof this.innerPadding?this.innerPadding:this.innerPadding[0]+this.innerPadding[2],u="number"==typeof this.innerPadding?this.innerPadding:this.innerPadding[1]+this.innerPadding[3];return this.data.map((x,I)=>{let K=x.data.name;K=K&&"Date"===K.constructor.name?K.toLocaleDateString():K&&K.toLocaleString();const ye=x.data.value,Ye=K?this.colors.getColor(K):this.emptyColor,$e=this.cardColor||Ye||"#000";return{x:x.x,y:x.y,width:x.width-u,height:x.height-a,color:$e,bandColor:this.bandColor||Ye,textColor:this.textColor||Rw($e),label:K,data:x.data,tooltipText:`${K}: ${ye}`}})}trackBy(a,u){return u.label}onClick(a){this.select.emit(a)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-card-series",""]],inputs:{data:"data",dims:"dims",colors:"colors",innerPadding:"innerPadding",cardColor:"cardColor",bandColor:"bandColor",emptyColor:"emptyColor",textColor:"textColor",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:vT,decls:2,vars:4,consts:[["class","card-empty","rx","3","ry","3",3,"fill",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-card","",3,"x","y","width","height","color","bandColor","textColor","data","label","medianSize","valueFormatting","labelFormatting","animations","select",4,"ngFor","ngForOf","ngForTrackBy"],["rx","3","ry","3",1,"card-empty"],["ngx-charts-card","",3,"select","x","y","width","height","color","bandColor","textColor","data","label","medianSize","valueFormatting","labelFormatting","animations"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,__,1,6,"rect",0)(1,og,1,13,"g",1),2&a&&(i.\u0275\u0275property("ngForOf",u.emptySlots)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.cards)("ngForTrackBy",u.trackBy))},dependencies:[Nw,e.NgForOf],encapsulation:2,changeDetection:0}),c})(),a0=(()=>{class c extends Wc{constructor(){super(...arguments),this.emptyColor="rgba(0, 0, 0, 0)",this.innerPadding=15,this.margin=[10,10,10,10]}get clickable(){return!!this.select.observers.length}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin}),this.formatDates(),this.domain=this.getDomain(),this.setColors(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`;const a=DT(this.dims,this.results.length,150),u=a[0]*a[1],x=this.results.slice();for(;x.length<u;)x.push({value:null});this.data=NC(this.dims,x,150,this.designatedTotal)}getDomain(){return this.results.map(a=>a.label)}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-number-card"]],inputs:{cardColor:"cardColor",bandColor:"bandColor",emptyColor:"emptyColor",innerPadding:"innerPadding",textColor:"textColor",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",designatedTotal:"designatedTotal"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:3,vars:20,consts:[[3,"view","showLegend","animations"],[1,"number-card","chart"],["ngx-charts-card-series","",3,"select","colors","cardColor","bandColor","textColor","emptyColor","data","dims","innerPadding","valueFormatting","labelFormatting","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1)(2,"g",2),i.\u0275\u0275listener("select",function(I){return u.onClick(I)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(17,mc,u.width,u.height))("showLegend",!1)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275classProp("clickable",u.clickable),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("colors",u.colors)("cardColor",u.cardColor)("bandColor",u.bandColor)("textColor",u.textColor)("emptyColor",u.emptyColor)("data",u.data)("dims",u.dims)("innerPadding",u.innerPadding)("valueFormatting",u.valueFormatting)("labelFormatting",u.labelFormatting)("animations",u.animations))},dependencies:[cu,I_],styles:[qo,"ngx-charts-number-card .cell .trimmed-label{font-size:12px;pointer-events:none;overflow:hidden;text-align:left;line-height:1em}ngx-charts-number-card .cell .trimmed-label p{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;width:100%;padding:0;margin:0}ngx-charts-number-card .cell .value-text{pointer-events:none}ngx-charts-number-card .number-card.clickable .cell .card,ngx-charts-number-card .number-card.clickable .cell .card-band{cursor:pointer}\n"],encapsulation:2,changeDetection:0}),c})(),pa=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),gv=(()=>{class c{constructor(a){this.gradient=!1,this.animations=!0,this.select=new i.EventEmitter,this.initialized=!1,this.orientation=Jl,this.element=a.nativeElement}ngOnChanges(){this.update(),this.valueFormatting=this.valueFormatting||(x=>x.toLocaleString());const a=this.labelFormatting||(x=>Cu(cg(x.label,55))),u={data:this.data,label:this.label,value:this.value};this.formattedValue=this.valueFormatting(u.value),this.formattedLabel=a(u),this.gradientId="grad"+Gu().toString(),this.gradientUrl=`url(#${this.gradientId})`,this.gradientStops=this.getGradientStops()}update(){this.initialized?this.animateToCurrentForm():(this.animations&&this.loadAnimation(),this.initialized=!0)}loadAnimation(){ta(this.element).select(".cell").attr("opacity",0).attr("x",this.x).attr("y",this.y),this.animateToCurrentForm()}getTextColor(){return Rw(this.fill)}animateToCurrentForm(){const a=ta(this.element).select(".cell");this.animations?a.transition().duration(750).attr("opacity",1).attr("x",this.x).attr("y",this.y).attr("width",this.width).attr("height",this.height):a.attr("opacity",1).attr("x",this.x).attr("y",this.y).attr("width",this.width).attr("height",this.height)}onClick(){this.select.emit(this.data)}getGradientStops(){return[{offset:0,color:this.fill,opacity:.3},{offset:100,color:this.fill,opacity:1}]}}return c.\u0275fac=function(a){return new(a||c)(i.\u0275\u0275directiveInject(i.ElementRef))},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-tree-map-cell",""]],inputs:{data:"data",fill:"fill",x:"x",y:"y",width:"width",height:"height",label:"label",value:"value",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",gradient:"gradient",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:mC,decls:4,vars:7,consts:[[4,"ngIf"],[1,"cell",3,"click"],["class","treemap-label",3,"pointer-events",4,"ngIf"],["ngx-charts-svg-linear-gradient","",3,"orientation","name","stops"],[1,"treemap-label"],[1,"treemap-label",3,"innerHTML"],["class","treemap-val","ngx-charts-count-up","",3,"countTo","valueFormatting",4,"ngIf"],["class","treemap-val",4,"ngIf"],["ngx-charts-count-up","",1,"treemap-val",3,"countTo","valueFormatting"],[1,"treemap-val"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,bw,2,3,"defs",0),i.\u0275\u0275elementStart(2,"rect",1),i.\u0275\u0275listener("click",function(){return u.onClick()}),i.\u0275\u0275elementEnd(),i.\u0275\u0275template(3,_T,6,15,"foreignObject",2),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.gradient),i.\u0275\u0275advance(),i.\u0275\u0275attribute("fill",u.gradient?u.gradientUrl:u.fill)("width",u.width)("height",u.height)("x",u.x)("y",u.y),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.width>=70&&u.height>=35))},dependencies:[ug,Gh,e.NgIf],encapsulation:2,changeDetection:0}),c})(),A_=(()=>{class c{constructor(){this.gradient=!1,this.tooltipDisabled=!1,this.animations=!0,this.select=new i.EventEmitter,this.styleTypes=Ju,this.placementTypes=Ys}ngOnChanges(a){this.cells=this.getCells()}getCells(){return this.data.children.filter(a=>1===a.depth).map((a,u)=>{const x=a.id;return{data:a.data,x:a.x0,y:a.y0,width:a.x1-a.x0,height:a.y1-a.y0,fill:this.colors.getColor(x),label:x,value:a.value}})}getTooltipText({label:a,value:u}){return`\n <span class="tooltip-label">${Cu(a)}</span>\n <span class="tooltip-val">${u.toLocaleString()}</span>\n `}onClick(a){this.select.emit(a)}trackBy(a,u){return u.label}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-tree-map-cell-series",""]],inputs:{data:"data",dims:"dims",colors:"colors",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",gradient:"gradient",tooltipDisabled:"tooltipDisabled",tooltipTemplate:"tooltipTemplate",animations:"animations"},outputs:{select:"select"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:Vy,decls:1,vars:2,consts:[["ngx-charts-tree-map-cell","","ngx-tooltip","",3,"data","x","y","width","height","fill","label","value","valueFormatting","labelFormatting","gradient","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext","select",4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-tree-map-cell","","ngx-tooltip","",3,"select","data","x","y","width","height","fill","label","value","valueFormatting","labelFormatting","gradient","animations","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"]],template:function(a,u){1&a&&i.\u0275\u0275template(0,yT,1,18,"g",0),2&a&&i.\u0275\u0275property("ngForOf",u.cells)("ngForTrackBy",u.trackBy)},dependencies:[gv,e.NgForOf,Hp],encapsulation:2,changeDetection:0}),c})(),wT=(()=>{class c extends Wc{constructor(){super(...arguments),this.tooltipDisabled=!1,this.gradient=!1,this.select=new i.EventEmitter,this.margin=[10,10,10,10]}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin}),this.domain=this.getDomain(),this.treemap=function IE(){var c=G0,g=!1,a=1,u=1,x=[0],I=Cd,K=Cd,ye=Cd,Ye=Cd,$e=Cd;function ht(zt){return zt.x0=zt.y0=0,zt.x1=a,zt.y1=u,zt.eachBefore(Vt),x=[0],g&&zt.eachBefore(Lx),zt}function Vt(zt){var yn=x[zt.depth],li=zt.x0+yn,pr=zt.y0+yn,si=zt.x1-yn,hr=zt.y1-yn;si<li&&(li=si=(li+si)/2),hr<pr&&(pr=hr=(pr+hr)/2),zt.x0=li,zt.y0=pr,zt.x1=si,zt.y1=hr,zt.children&&(yn=x[zt.depth+1]=I(zt)/2,li+=$e(zt)-yn,pr+=K(zt)-yn,(si-=ye(zt)-yn)<li&&(li=si=(li+si)/2),(hr-=Ye(zt)-yn)<pr&&(pr=hr=(pr+hr)/2),c(zt,li,pr,si,hr))}return ht.round=function(zt){return arguments.length?(g=!!zt,ht):g},ht.size=function(zt){return arguments.length?(a=+zt[0],u=+zt[1],ht):[a,u]},ht.tile=function(zt){return arguments.length?(c=ID(zt),ht):c},ht.padding=function(zt){return arguments.length?ht.paddingInner(zt).paddingOuter(zt):ht.paddingInner()},ht.paddingInner=function(zt){return arguments.length?(I="function"==typeof zt?zt:cm(+zt),ht):I},ht.paddingOuter=function(zt){return arguments.length?ht.paddingTop(zt).paddingRight(zt).paddingBottom(zt).paddingLeft(zt):ht.paddingTop()},ht.paddingTop=function(zt){return arguments.length?(K="function"==typeof zt?zt:cm(+zt),ht):K},ht.paddingRight=function(zt){return arguments.length?(ye="function"==typeof zt?zt:cm(+zt),ht):ye},ht.paddingBottom=function(zt){return arguments.length?(Ye="function"==typeof zt?zt:cm(+zt),ht):Ye},ht.paddingLeft=function(zt){return arguments.length?($e="function"==typeof zt?zt:cm(+zt),ht):$e},ht}().size([this.dims.width,this.dims.height]);const u=function FD(){var a,c=NE,g=RE;function u(x){var Ye,$e,ht,Vt,zt,yn,li,pr,I=Array.from(x),K=c,ye=g,si=new Map;if(null!=a){const hr=I.map((ao,lo)=>function LE(c){let g=(c=`${c}`).length;return T1(c,g-1)&&!T1(c,g-2)&&(c=c.slice(0,-1)),"/"===c[0]?c:`/${c}`}(a(ao,lo,x))),_o=hr.map(E1),jr=new Set(hr).add("");for(const ao of _o)jr.has(ao)||(jr.add(ao),hr.push(ao),_o.push(E1(ao)),I.push(S1));K=(ao,lo)=>hr[lo],ye=(ao,lo)=>_o[lo]}for(ht=0,Ye=I.length;ht<Ye;++ht)yn=I[ht]=new Pg($e=I[ht]),null!=(li=K($e,ht,x))&&(li+="")&&(pr=yn.id=li,si.set(pr,si.has(pr)?Q0:yn)),null!=(li=ye($e,ht,x))&&(li+="")&&(yn.parent=li);for(ht=0;ht<Ye;++ht)if(li=(yn=I[ht]).parent){if(!(zt=si.get(li)))throw new Error("missing: "+li);if(zt===Q0)throw new Error("ambiguous: "+li);zt.children?zt.children.push(yn):zt.children=[yn],yn.parent=zt}else{if(Vt)throw new Error("multiple roots");Vt=yn}if(!Vt)throw new Error("no root");if(null!=a){for(;Vt.data===S1&&1===Vt.children.length;)Vt=Vt.children[0],--Ye;for(let hr=I.length-1;hr>=0&&(yn=I[hr]).data===S1;--hr)yn.data=null}if(Vt.parent=jx,Vt.eachBefore(function(hr){hr.depth=hr.parent.depth+1,--Ye}).eachBefore(qv),Vt.parent=null,Ye>0)throw new Error("cycle");return Vt}return u.id=function(x){return arguments.length?(c=K0(x),u):c},u.parentId=function(x){return arguments.length?(g=K0(x),u):g},u.path=function(x){return arguments.length?(a=K0(x),u):a},u}().id(x=>{let I=x.name;return I="Date"===I.constructor.name?I.toLocaleDateString():I.toLocaleString(),I}).parentId(x=>x.isRoot?null:"root")([{name:"root",value:0,isRoot:!0},...this.results]).sum(x=>x.value);this.data=this.treemap(u),this.setColors(),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getDomain(){return this.results.map(a=>a.name)}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-tree-map"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{results:"results",tooltipDisabled:"tooltipDisabled",valueFormatting:"valueFormatting",labelFormatting:"labelFormatting",gradient:"gradient"},outputs:{select:"select"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:3,vars:16,consts:[[3,"view","showLegend","animations"],[1,"tree-map","chart"],["ngx-charts-tree-map-cell-series","",3,"select","colors","data","dims","tooltipDisabled","tooltipTemplate","valueFormatting","labelFormatting","gradient","animations"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1)(2,"g",2),i.\u0275\u0275listener("select",function(I){return u.onClick(I)}),i.\u0275\u0275elementEnd()()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(13,mc,u.width,u.height))("showLegend",!1)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("colors",u.colors)("data",u.data)("dims",u.dims)("tooltipDisabled",u.tooltipDisabled)("tooltipTemplate",u.tooltipTemplate)("valueFormatting",u.valueFormatting)("labelFormatting",u.labelFormatting)("gradient",u.gradient)("animations",u.animations))},dependencies:[cu,A_],styles:[".tree-map .treemap-val{font-size:1.3em;padding-top:5px;display:inline-block}.tree-map .treemap-label p{display:table-cell;text-align:center;line-height:1.2em;vertical-align:middle}\n"],encapsulation:2,changeDetection:0}),c})(),l0=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})();var wm=function(c){return c.Value="value",c.Units="units",c}(wm||{});let Lw=(()=>{class c extends Wc{constructor(){super(...arguments),this.min=0,this.max=100,this.value=0,this.margin=[10,20,10,20],this.valueResizeScale=1,this.unitsResizeScale=1,this.valueTextTransform="",this.valueTranslate="",this.unitsTextTransform="",this.unitsTranslate="",this.barOrientation=Jl}ngAfterViewInit(){super.ngAfterViewInit(),setTimeout(()=>{this.scaleText(wm.Value),this.scaleText(wm.Units)})}update(){super.update(),this.hasPreviousValue=void 0!==this.previousValue,this.max=Math.max(this.max,this.value),this.min=Math.min(this.min,this.value),this.hasPreviousValue&&(this.max=Math.max(this.max,this.previousValue),this.min=Math.min(this.min,this.previousValue)),this.dims=uu({width:this.width,height:this.height,margins:this.margin}),this.valueDomain=this.getValueDomain(),this.valueScale=this.getValueScale(),this.displayValue=this.getDisplayValue(),this.setColors();const u=this.margin[0]+this.dims.height/2;this.transform=`translate(${this.margin[3]+this.dims.width/2}, ${u})`,this.transformLine=`translate(${this.margin[3]+this.valueScale(this.previousValue)}, ${u})`,this.valueTranslate="translate(0, -15)",this.unitsTranslate="translate(0, 15)",(0,e.isPlatformServer)(this.platformId)?(this.scaleTextSSR("value"),this.scaleTextSSR("units")):(setTimeout(()=>this.scaleText(wm.Value),50),setTimeout(()=>this.scaleText(wm.Units),50))}getValueDomain(){return[this.min,this.max]}getValueScale(){return ic().range([0,this.dims.width]).domain(this.valueDomain)}getDisplayValue(){return this.valueFormatting?this.valueFormatting(this.value):this.value.toLocaleString()}scaleText(a,u=!0){let x,I;a===wm.Value?(x=this.valueTextEl,I=this.valueResizeScale):(x=this.unitsTextEl,I=this.unitsResizeScale);const{width:K,height:ye}=x.nativeElement.getBoundingClientRect();if(0===K||0===ye)return;const Ye=I,$e=this.dims.width,ht=Math.max(this.dims.height/2-15,0),Vt=Math.floor($e/(K/I)*100)/100,zt=Math.floor(ht/(ye/I)*100)/100;I=Math.min(zt,Vt),I!==Ye&&(a===wm.Value?(this.valueResizeScale=I,this.valueTextTransform=`scale(${I}, ${I})`):(this.unitsResizeScale=I,this.unitsTextTransform=`scale(${I}, ${I})`),this.cd.markForCheck(),u&&(0,e.isPlatformBrowser)(this.platformId)&&setTimeout(()=>{this.scaleText(a,!1)},50))}scaleTextSSR(a){let u=1;const I=Ub($b,"value"===a?this.displayValue:this.units,10),ye=this.dims.width,Ye=Math.max(this.dims.height/2-15,0),$e=Math.floor(ye/(I/u)*100)/100,ht=Math.floor(Ye/(25/u)*100)/100;u=Math.min(ht,$e),"value"===a?(this.valueResizeScale=u,this.valueTextTransform=`scale(${u}, ${u})`):(this.unitsResizeScale=u,this.unitsTextTransform=`scale(${u}, ${u})`),this.cd.markForCheck()}onClick(){this.select.emit({name:"Value",value:this.value})}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,[this.value],this.customColors)}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-linear-gauge"]],viewQuery:function(a,u){if(1&a&&(i.\u0275\u0275viewQuery(bT,5),i.\u0275\u0275viewQuery(jy,5)),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.valueTextEl=x.first),i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.unitsTextEl=x.first)}},inputs:{min:"min",max:"max",value:"value",units:"units",previousValue:"previousValue",valueFormatting:"valueFormatting"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:15,vars:38,consts:[["valueTextEl",""],["unitsTextEl",""],[3,"click","view","showLegend","animations"],[1,"linear-gauge","chart"],["ngx-charts-bar","",1,"background-bar",3,"width","height","x","y","data","orientation","roundEdges","animations"],["ngx-charts-bar","",3,"width","height","x","y","fill","data","orientation","roundEdges","animations"],["x1","0","y1","5","x2","0","y2","15",4,"ngIf"],["x1","0","y1","-5","x2","0","y2","-15",4,"ngIf"],["alignment-baseline","after-edge",1,"value"],["alignment-baseline","before-edge",1,"units"],["x1","0","y1","5","x2","0","y2","15"],["x1","0","y1","-5","x2","0","y2","-15"]],template:function(a,u){if(1&a){const x=i.\u0275\u0275getCurrentView();i.\u0275\u0275elementStart(0,"ngx-charts-chart",2),i.\u0275\u0275listener("click",function(){return i.\u0275\u0275restoreView(x),i.\u0275\u0275resetView(u.onClick())}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",3),i.\u0275\u0275element(2,"g",4)(3,"g",5),i.\u0275\u0275template(4,ww,1,2,"line",6)(5,Uy,1,2,"line",7),i.\u0275\u0275elementStart(6,"g")(7,"g")(8,"text",8,0),i.\u0275\u0275text(10),i.\u0275\u0275elementEnd()(),i.\u0275\u0275elementStart(11,"g")(12,"text",9,1),i.\u0275\u0275text(14),i.\u0275\u0275elementEnd()()()()()}2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(33,mc,u.width,u.height))("showLegend",!1)("animations",u.animations),i.\u0275\u0275advance(2),i.\u0275\u0275property("width",u.dims.width)("height",3)("x",u.margin[3])("y",u.dims.height/2+u.margin[0]-2)("data",i.\u0275\u0275pureFunction0(36,Dw))("orientation",u.barOrientation.Horizontal)("roundEdges",!0)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("width",u.valueScale(u.value))("height",3)("x",u.margin[3])("y",u.dims.height/2+u.margin[0]-2)("fill",u.colors.getColor(u.units))("data",i.\u0275\u0275pureFunction0(37,Dw))("orientation",u.barOrientation.Horizontal)("roundEdges",!0)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.hasPreviousValue),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.hasPreviousValue),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.valueTranslate),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("text-anchor","middle"),i.\u0275\u0275attribute("transform",u.valueTextTransform),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",u.displayValue," "),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.unitsTranslate),i.\u0275\u0275advance(),i.\u0275\u0275styleProp("text-anchor","middle"),i.\u0275\u0275attribute("transform",u.unitsTextTransform),i.\u0275\u0275advance(2),i.\u0275\u0275textInterpolate1(" ",u.units," "))},dependencies:[cu,hv,e.NgIf],styles:[qo,".linear-gauge{cursor:pointer}.linear-gauge .background-bar path{fill:#0000000d}.linear-gauge .units{fill:#666}\n"],encapsulation:2,changeDetection:0}),c})(),O_=(()=>{class c{constructor(){this.isActive=!1,this.tooltipDisabled=!1,this.animations=!0,this.select=new i.EventEmitter,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.placementTypes=Ys,this.styleTypes=Ju}tooltipText(a){const u=nu(a.data.name);let x;return x=this.valueFormatting?this.valueFormatting(a.data.value):nu(a.data.value),`\n <span class="tooltip-label">${Cu(u)}</span>\n <span class="tooltip-val">${x}</span>\n `}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-gauge-arc",""]],inputs:{backgroundArc:"backgroundArc",valueArc:"valueArc",cornerRadius:"cornerRadius",colors:"colors",isActive:"isActive",tooltipDisabled:"tooltipDisabled",valueFormatting:"valueFormatting",tooltipTemplate:"tooltipTemplate",animations:"animations"},outputs:{select:"select",activate:"activate",deactivate:"deactivate"},attrs:gC,decls:2,vars:23,consts:[["ngx-charts-pie-arc","",1,"background-arc",3,"startAngle","endAngle","innerRadius","outerRadius","cornerRadius","data","animate","pointerEvents"],["ngx-charts-pie-arc","","ngx-tooltip","",3,"select","activate","deactivate","startAngle","endAngle","innerRadius","outerRadius","cornerRadius","fill","data","animate","isActive","tooltipDisabled","tooltipPlacement","tooltipType","tooltipTitle","tooltipTemplate","tooltipContext"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275element(0,"g",0),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275listener("select",function(I){return u.select.emit(I)})("activate",function(I){return u.activate.emit(I)})("deactivate",function(I){return u.deactivate.emit(I)}),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275property("startAngle",0)("endAngle",u.backgroundArc.endAngle)("innerRadius",u.backgroundArc.innerRadius)("outerRadius",u.backgroundArc.outerRadius)("cornerRadius",u.cornerRadius)("data",u.backgroundArc.data)("animate",!1)("pointerEvents",!1),i.\u0275\u0275advance(),i.\u0275\u0275property("startAngle",0)("endAngle",u.valueArc.endAngle)("innerRadius",u.valueArc.innerRadius)("outerRadius",u.valueArc.outerRadius)("cornerRadius",u.cornerRadius)("fill",u.colors.getColor(u.valueArc.data.name))("data",u.valueArc.data)("animate",u.animations)("isActive",u.isActive)("tooltipDisabled",u.tooltipDisabled)("tooltipPlacement",u.placementTypes.Top)("tooltipType",u.styleTypes.tooltip)("tooltipTitle",u.tooltipTemplate?void 0:u.tooltipText(u.valueArc))("tooltipTemplate",u.tooltipTemplate)("tooltipContext",u.valueArc.data))},dependencies:[mh,Hp],encapsulation:2,changeDetection:0}),c})(),Wb=(()=>{class c{constructor(){this.rotate=""}ngOnChanges(a){this.update()}update(){this.rotationAngle=-90+this.startAngle,this.rotate=`rotate(${this.rotationAngle})`,this.ticks=this.getTicks()}getTicks(){const a=this.angleSpan/this.bigSegments,u=a/this.smallSegments,I={big:[],small:[]},K=this.radius+10,ye=K+20+10;for(let Ye=0;Ye<=this.bigSegments;Ye++){const $e=Ye*a,ht=$e*Math.PI/180,Vt=this.getTextAnchor($e);let zt=!1;if(0===Ye&&360===this.angleSpan&&(zt=!0),!zt){let yn=Number.parseFloat(this.valueScale.invert($e).toString()).toLocaleString();this.tickFormatting&&(yn=this.tickFormatting(yn)),I.big.push({line:this.getTickPath(K,20,ht),textAnchor:Vt,text:yn,textTransform:`\n translate(${ye*Math.cos(ht)}, ${ye*Math.sin(ht)}) rotate(${-this.rotationAngle})\n `})}if(Ye!==this.bigSegments)for(let yn=1;yn<=this.smallSegments;yn++){const pr=($e+yn*u)*Math.PI/180;I.small.push({line:this.getTickPath(K,10,pr)})}}return I}getTextAnchor(a){let u=Nd.Middle;return(a=(this.startAngle+a)%360)>45&&a<=135?u=Nd.Start:a>225&&a<=315&&(u=Nd.End),u}getTickPath(a,u,x){const I=a*Math.sin(x),K=(a+u)*Math.sin(x),$e=[{x:a*Math.cos(x),y:I},{x:(a+u)*Math.cos(x),y:K}];return Wm().x(Vt=>Vt.x).y(Vt=>Vt.y)($e)}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["g","ngx-charts-gauge-axis",""]],inputs:{bigSegments:"bigSegments",smallSegments:"smallSegments",min:"min",max:"max",angleSpan:"angleSpan",startAngle:"startAngle",radius:"radius",valueScale:"valueScale",tickFormatting:"tickFormatting"},features:[i.\u0275\u0275NgOnChangesFeature],attrs:vC,decls:4,vars:4,consts:[["class","gauge-tick gauge-tick-large",4,"ngFor","ngForOf"],["class","gauge-tick gauge-tick-small",4,"ngFor","ngForOf"],[1,"gauge-tick","gauge-tick-large"],["alignment-baseline","central"],[1,"gauge-tick","gauge-tick-small"]],template:function(a,u){1&a&&(i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(0,"g"),i.\u0275\u0275template(1,Fb,2,1,"g",0)(2,IS,3,4,"g",0)(3,Nb,2,1,"g",1),i.\u0275\u0275elementEnd()),2&a&&(i.\u0275\u0275attribute("transform",u.rotate),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.ticks.big),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.ticks.big),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.ticks.small))},dependencies:[e.NgForOf],encapsulation:2,changeDetection:0}),c})(),kw=(()=>{class c extends Wc{constructor(){super(...arguments),this.legend=!1,this.legendTitle="Legend",this.legendPosition=bu.Right,this.min=0,this.max=100,this.bigSegments=10,this.smallSegments=5,this.showAxis=!0,this.startAngle=-120,this.angleSpan=240,this.activeEntries=[],this.tooltipDisabled=!1,this.showText=!0,this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.resizeScale=1,this.rotation="",this.textTransform="scale(1, 1)",this.cornerRadius=10}ngAfterViewInit(){super.ngAfterViewInit(),setTimeout(()=>this.scaleText())}update(){super.update(),this.showAxis?this.margin||(this.margin=[60,100,60,100]):this.margin||(this.margin=[10,20,10,20]),this.startAngle<0&&(this.startAngle=this.startAngle%360+360),this.angleSpan=Math.min(this.angleSpan,360),this.dims=uu({width:this.width,height:this.height,margins:this.margin,showLegend:this.legend,legendPosition:this.legendPosition}),this.domain=this.getDomain(),this.valueDomain=this.getValueDomain(),this.valueScale=this.getValueScale(),this.displayValue=this.getDisplayValue(),this.outerRadius=Math.min(this.dims.width,this.dims.height)/2,this.arcs=this.getArcs(),this.setColors(),this.legendOptions=this.getLegendOptions(),this.transform=`translate(${this.margin[3]+this.dims.width/2}, ${this.margin[0]+this.dims.height/2})`,this.rotation=`rotate(${this.startAngle})`,setTimeout(()=>this.scaleText(),50)}getArcs(){const a=[],x=Math.min(.7*this.outerRadius/this.results.length,10),I=.7*x;this.textRadius=this.outerRadius-this.results.length*x,this.cornerRadius=Math.floor(I/2);let K=0;for(const ye of this.results){const Ye=this.outerRadius-K*x,$e=Ye-I,ht={endAngle:this.angleSpan*Math.PI/180,innerRadius:$e,outerRadius:Ye,data:{value:this.max,name:ye.name}},Vt={endAngle:Math.min(this.valueScale(ye.value),this.angleSpan)*Math.PI/180,innerRadius:$e,outerRadius:Ye,data:{value:ye.value,name:ye.name}};a.push({backgroundArc:ht,valueArc:Vt}),K++}return a}getDomain(){return this.results.map(a=>a.name)}getValueDomain(){const a=this.results.map(I=>I.value),u=Math.min(...a),x=Math.max(...a);return this.min=void 0!==this.min?Math.min(this.min,u):u,this.max=void 0!==this.max?Math.max(this.max,x):x,[this.min,this.max]}getValueScale(){return ic().range([0,this.angleSpan]).nice().domain(this.valueDomain)}getDisplayValue(){const a=this.results.map(u=>u.value).reduce((u,x)=>u+x,0);return this.textValue&&0!==this.textValue.length?this.textValue.toLocaleString():this.valueFormatting?this.valueFormatting(a):a.toLocaleString()}scaleText(a=!0){if(!this.showText)return;const{width:u}=this.textEl.nativeElement.getBoundingClientRect(),x=this.resizeScale;this.resizeScale=0===u?1:Math.floor(this.textRadius/(u/this.resizeScale)*100)/100,this.resizeScale!==x&&(this.textTransform=`scale(${this.resizeScale}, ${this.resizeScale})`,this.cd.markForCheck(),a&&setTimeout(()=>this.scaleText(!1),50))}onClick(a){this.select.emit(a)}getLegendOptions(){return{scaleType:zi.Ordinal,colors:this.colors,domain:this.domain,title:this.legendTitle,position:this.legendPosition}}setColors(){this.colors=new iu(this.scheme,zi.Ordinal,this.domain,this.customColors)}onActivate(a){this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value)>-1||(this.activeEntries=[a,...this.activeEntries],this.activate.emit({value:a,entries:this.activeEntries}))}onDeactivate(a){const u=this.activeEntries.findIndex(x=>x.name===a.name&&x.value===a.value);this.activeEntries.splice(u,1),this.activeEntries=[...this.activeEntries],this.deactivate.emit({value:a,entries:this.activeEntries})}isActive(a){return!!this.activeEntries&&void 0!==this.activeEntries.find(x=>a.name===x.name&&a.series===x.series)}trackBy(a,u){return u.valueArc.data.name}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-gauge"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},viewQuery:function(a,u){if(1&a&&i.\u0275\u0275viewQuery(Ob,5),2&a){let x;i.\u0275\u0275queryRefresh(x=i.\u0275\u0275loadQuery())&&(u.textEl=x.first)}},inputs:{legend:"legend",legendTitle:"legendTitle",legendPosition:"legendPosition",min:"min",max:"max",textValue:"textValue",units:"units",bigSegments:"bigSegments",smallSegments:"smallSegments",results:"results",showAxis:"showAxis",startAngle:"startAngle",angleSpan:"angleSpan",activeEntries:"activeEntries",axisTickFormatting:"axisTickFormatting",tooltipDisabled:"tooltipDisabled",valueFormatting:"valueFormatting",showText:"showText",margin:"margin"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:5,vars:13,consts:[["textEl",""],[3,"legendLabelClick","legendLabelActivate","legendLabelDeactivate","view","showLegend","legendOptions","activeEntries","animations"],[1,"gauge","chart"],[4,"ngFor","ngForOf","ngForTrackBy"],["ngx-charts-gauge-axis","",3,"bigSegments","smallSegments","min","max","radius","angleSpan","valueScale","startAngle","tickFormatting",4,"ngIf"],["alignment-baseline","central",3,"textAnchor",4,"ngIf"],["ngx-charts-gauge-arc","",3,"select","activate","deactivate","backgroundArc","valueArc","cornerRadius","colors","isActive","tooltipDisabled","tooltipTemplate","valueFormatting","animations"],["ngx-charts-gauge-axis","",3,"bigSegments","smallSegments","min","max","radius","angleSpan","valueScale","startAngle","tickFormatting"],["alignment-baseline","central"],["x","0","dy","0"],["x","0","dy","1.2em"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",1),i.\u0275\u0275listener("legendLabelClick",function(I){return u.onClick(I)})("legendLabelActivate",function(I){return u.onActivate(I)})("legendLabelDeactivate",function(I){return u.onDeactivate(I)}),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",2),i.\u0275\u0275template(2,xw,2,10,"g",3)(3,AS,1,9,"g",4)(4,_m,6,5,"text",5),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(10,mc,u.width,u.height))("showLegend",u.legend)("legendOptions",u.legendOptions)("activeEntries",u.activeEntries)("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.arcs)("ngForTrackBy",u.trackBy),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showAxis),i.\u0275\u0275advance(),i.\u0275\u0275property("ngIf",u.showText))},dependencies:[cu,O_,Wb,e.NgForOf,e.NgIf],styles:[qo,".gauge .background-arc path{fill:#0000000d}.gauge .gauge-tick path{stroke:#666}.gauge .gauge-tick text{font-size:12px;fill:#666;font-weight:700}.gauge .gauge-tick-large path{stroke-width:2px}.gauge .gauge-tick-small path{stroke-width:1px}\n"],encapsulation:2,changeDetection:0}),c})(),WS=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf,o0,Aw]]}),c})(),Hb=(()=>{class c extends Wc{constructor(){super(...arguments),this.showLabels=!0,this.tooltipDisabled=!1,this.activeEntries=[],this.activate=new i.EventEmitter,this.deactivate=new i.EventEmitter,this.margin=[10,10,10,10],this.scaleType=zi.Ordinal,this.styleTypes=Ju}update(){super.update(),this.dims=uu({width:this.width,height:this.height,margins:this.margin,legendType:this.scaleType});const a=this.results,u=Array.from(new Set(a.flatMap(K=>[K.source,K.target])),K=>({name:K,value:a.filter(ye=>ye.source===K).reduce((ye,Ye)=>ye+Ye.value,0)})),I=function VE(){let K,$e,ht,c=0,g=0,a=1,u=1,x=24,I=8,ye=IM,Ye=I1,Vt=ay,zt=BE,yn=6;function li(){const Rr={nodes:Vt.apply(null,arguments),links:zt.apply(null,arguments)};return function pr({nodes:Rr,links:xo}){for(const[No,Hr]of Rr.entries())Hr.index=No,Hr.sourceLinks=[],Hr.targetLinks=[];const Jr=new Map(Rr.map((No,Hr)=>[ye(No,Hr,Rr),No]));for(const[No,Hr]of xo.entries()){Hr.index=No;let{source:ys,target:Ns}=Hr;"object"!=typeof ys&&(ys=Hr.source=RD(Jr,ys)),"object"!=typeof Ns&&(Ns=Hr.target=RD(Jr,Ns)),ys.sourceLinks.push(Hr),Ns.targetLinks.push(Hr)}if(null!=ht)for(const{sourceLinks:No,targetLinks:Hr}of Rr)No.sort(ht),Hr.sort(ht)}(Rr),function si({nodes:Rr}){for(const xo of Rr)xo.value=void 0===xo.fixedValue?Math.max(Y0(xo.sourceLinks,Yv),Y0(xo.targetLinks,Yv)):xo.fixedValue}(Rr),function hr({nodes:Rr}){const xo=Rr.length;let Jr=new Set(Rr),No=new Set,Hr=0;for(;Jr.size;){for(const ys of Jr){ys.depth=Hr;for(const{target:Ns}of ys.sourceLinks)No.add(Ns)}if(++Hr>xo)throw new Error("circular link");Jr=No,No=new Set}}(Rr),function _o({nodes:Rr}){const xo=Rr.length;let Jr=new Set(Rr),No=new Set,Hr=0;for(;Jr.size;){for(const ys of Jr){ys.height=Hr;for(const{source:Ns}of ys.targetLinks)No.add(Ns)}if(++Hr>xo)throw new Error("circular link");Jr=No,No=new Set}}(Rr),function lo(Rr){const xo=function jr({nodes:Rr}){const xo=kE(Rr,Hr=>Hr.depth)+1,Jr=(a-c-x)/(xo-1),No=new Array(xo);for(const Hr of Rr){const ys=Math.max(0,Math.min(xo-1,Math.floor(Ye.call(null,Hr,xo))));Hr.layer=ys,Hr.x0=c+ys*Jr,Hr.x1=Hr.x0+x,No[ys]?No[ys].push(Hr):No[ys]=[Hr]}if($e)for(const Hr of No)Hr.sort($e);return No}(Rr);K=Math.min(I,(u-g)/(kE(xo,Jr=>Jr.length)-1)),function ao(Rr){const xo=function M1(c,g){let a;if(void 0===g)for(const u of c)null!=u&&(a>u||void 0===a&&u>=u)&&(a=u);else{let u=-1;for(let x of c)null!=(x=g(x,++u,c))&&(a>x||void 0===a&&x>=x)&&(a=x)}return a}(Rr,Jr=>(u-g-(Jr.length-1)*K)/Y0(Jr,Yv));for(const Jr of Rr){let No=g;for(const Hr of Jr){Hr.y0=No,Hr.y1=No+Hr.value*xo,No=Hr.y1+K;for(const ys of Hr.sourceLinks)ys.width=ys.value*xo}No=(u-No+K)/(Jr.length+1);for(let Hr=0;Hr<Jr.length;++Hr){const ys=Jr[Hr];ys.y0+=No*(Hr+1),ys.y1+=No*(Hr+1)}Ba(Jr)}}(xo);for(let Jr=0;Jr<yn;++Jr){const No=Math.pow(.99,Jr),Hr=Math.max(1-No,(Jr+1)/yn);br(xo,No,Hr),mo(xo,No,Hr)}}(Rr),Z0(Rr),Rr}function mo(Rr,xo,Jr){for(let No=1,Hr=Rr.length;No<Hr;++No){const ys=Rr[No];for(const Ns of ys){let Ml=0,Nu=0;for(const{source:ru,value:wd}of Ns.targetLinks){let jl=wd*(Ns.layer-ru.layer);Ml+=Co(ru,Ns)*jl,Nu+=jl}if(!(Nu>0))continue;let Rd=(Ml/Nu-Ns.y0)*xo;Ns.y0+=Rd,Ns.y1+=Rd,oo(Ns)}void 0===$e&&ys.sort(Qv),yo(ys,Jr)}}function br(Rr,xo,Jr){for(let Hr=Rr.length-2;Hr>=0;--Hr){const ys=Rr[Hr];for(const Ns of ys){let Ml=0,Nu=0;for(const{target:ru,value:wd}of Ns.sourceLinks){let jl=wd*(ru.layer-Ns.layer);Ml+=us(Ns,ru)*jl,Nu+=jl}if(!(Nu>0))continue;let Rd=(Ml/Nu-Ns.y0)*xo;Ns.y0+=Rd,Ns.y1+=Rd,oo(Ns)}void 0===$e&&ys.sort(Qv),yo(ys,Jr)}}function yo(Rr,xo){const Jr=Rr.length>>1,No=Rr[Jr];Ca(Rr,No.y0-K,Jr-1,xo),ml(Rr,No.y1+K,Jr+1,xo),Ca(Rr,u,Rr.length-1,xo),ml(Rr,g,0,xo)}function ml(Rr,xo,Jr,No){for(;Jr<Rr.length;++Jr){const Hr=Rr[Jr],ys=(xo-Hr.y0)*No;ys>1e-6&&(Hr.y0+=ys,Hr.y1+=ys),xo=Hr.y1+K}}function Ca(Rr,xo,Jr,No){for(;Jr>=0;--Jr){const Hr=Rr[Jr],ys=(Hr.y1-xo)*No;ys>1e-6&&(Hr.y0-=ys,Hr.y1-=ys),xo=Hr.y0-K}}function oo({sourceLinks:Rr,targetLinks:xo}){if(void 0===ht){for(const{source:{sourceLinks:Jr}}of xo)Jr.sort(Ux);for(const{target:{targetLinks:Jr}}of Rr)Jr.sort(X0)}}function Ba(Rr){if(void 0===ht)for(const{sourceLinks:xo,targetLinks:Jr}of Rr)xo.sort(Ux),Jr.sort(X0)}function Co(Rr,xo){let Jr=Rr.y0-(Rr.sourceLinks.length-1)*K/2;for(const{target:No,width:Hr}of Rr.sourceLinks){if(No===xo)break;Jr+=Hr+K}for(const{source:No,width:Hr}of xo.targetLinks){if(No===Rr)break;Jr-=Hr}return Jr}function us(Rr,xo){let Jr=xo.y0-(xo.targetLinks.length-1)*K/2;for(const{source:No,width:Hr}of xo.targetLinks){if(No===Rr)break;Jr+=Hr+K}for(const{target:No,width:Hr}of Rr.sourceLinks){if(No===xo)break;Jr-=Hr}return Jr}return li.update=function(Rr){return Z0(Rr),Rr},li.nodeId=function(Rr){return arguments.length?(ye="function"==typeof Rr?Rr:fp(Rr),li):ye},li.nodeAlign=function(Rr){return arguments.length?(Ye="function"==typeof Rr?Rr:fp(Rr),li):Ye},li.nodeSort=function(Rr){return arguments.length?($e=Rr,li):$e},li.nodeWidth=function(Rr){return arguments.length?(x=+Rr,li):x},li.nodePadding=function(Rr){return arguments.length?(I=K=+Rr,li):I},li.nodes=function(Rr){return arguments.length?(Vt="function"==typeof Rr?Rr:fp(Rr),li):Vt},li.links=function(Rr){return arguments.length?(zt="function"==typeof Rr?Rr:fp(Rr),li):zt},li.linkSort=function(Rr){return arguments.length?(ht=Rr,li):ht},li.size=function(Rr){return arguments.length?(c=g=0,a=+Rr[0],u=+Rr[1],li):[a-c,u-g]},li.extent=function(Rr){return arguments.length?(c=+Rr[0][0],a=+Rr[1][0],g=+Rr[0][1],u=+Rr[1][1],li):[[c,g],[a,u]]},li.iterations=function(Rr){return arguments.length?(yn=+Rr,li):yn},li}().nodeId(K=>K.name).nodeAlign(PE).nodeWidth(15).nodePadding(10).extent([[1,5],[this.dims.width-1,this.dims.height-5]])({nodes:u.map(K=>Object.assign({},K)),links:a.map(K=>Object.assign({},K))});this.valueDomain=this.getValueDomain(I.nodes),this.setColors(),this.nodeRects=I.nodes.map(K=>{const ye={x:K.x0,y:K.y0,height:K.y1-K.y0,width:K.x1-K.x0,fill:this.colors.getColor(K.name),tooltip:this.getNodeTooltipText(K),rx:5,data:{name:K.name,value:K.value},transform:"",label:this.labelFormatting?this.labelFormatting(K.name):K.name,labelAnchor:Nd.Start};return ye.labelAnchor=this.getTextAnchor(K),ye.transform=`translate(${ye.x},${ye.y})`,ye}),this.linkPaths=I.links.map(K=>{const ye="mask"+Gu().toString();return{path:pp()(K),strokeWidth:Math.max(1,K.width),tooltip:this.getLinkTooltipText(K.source,K.target,K.value),id:ye,gradientFill:`url(#${ye})`,source:K.source,target:K.target,startColor:this.colors.getColor(K.source.name),endColor:this.colors.getColor(K.target.name),data:{source:K.source.name,target:K.target.name,value:K.value}}}),this.transform=`translate(${this.dims.xOffset} , ${this.margin[0]})`}getNodeTooltipText(a){return`\n <span class="tooltip-label">${Cu(a.name)}</span>\n <span class="tooltip-val">${a.value.toLocaleString()}</span>\n `}getLinkTooltipText(a,u,x){return`\n <span class="tooltip-label">${Cu(a.name)} \u2022 ${Cu(u.name)}</span>\n <span class="tooltip-val">${x.toLocaleString()} (${(x/a.value).toLocaleString(void 0,{style:"percent",maximumFractionDigits:2})})</span>\n `}getTextAnchor(a){return 0===a.layer?Nd.Start:Nd.End}onClick(a){this.select.emit(a)}setColors(){this.colors=new iu(this.scheme,this.scaleType,this.valueDomain)}getValueDomain(a){return a.map(u=>u.name)}}return c.\u0275fac=(()=>{let g;return function(u){return(g||(g=i.\u0275\u0275getInheritedFactory(c)))(u||c)}})(),c.\u0275cmp=i.\u0275\u0275defineComponent({type:c,selectors:[["ngx-charts-sankey"]],contentQueries:function(a,u,x){if(1&a&&i.\u0275\u0275contentQuery(x,bo,5),2&a){let I;i.\u0275\u0275queryRefresh(I=i.\u0275\u0275loadQuery())&&(u.tooltipTemplate=I.first)}},inputs:{showLabels:"showLabels",gradient:"gradient",tooltipDisabled:"tooltipDisabled",activeEntries:"activeEntries",labelFormatting:"labelFormatting"},outputs:{activate:"activate",deactivate:"deactivate"},features:[i.\u0275\u0275InheritDefinitionFeature],decls:5,vars:9,consts:[[3,"view","animations"],[1,"sankey","chart"],["class","link","ngx-tooltip","",3,"tooltipDisabled","tooltipType","tooltipPlacement","tooltipTitle","tooltipTemplate","tooltipContext",4,"ngFor","ngForOf"],["class","node",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],["ngx-tooltip","",1,"link",3,"tooltipDisabled","tooltipType","tooltipPlacement","tooltipTitle","tooltipTemplate","tooltipContext"],["gradientUnits","userSpaceOnUse"],["offset","0%"],["offset","100%"],["stroke-opacity","0.5","fill","none",3,"click","mouseenter"],[1,"node"],["ngx-tooltip","",3,"click","mouseenter","tooltipDisabled","tooltipType","tooltipPlacement","tooltipTitle","tooltipTemplate","tooltipContext"],["class","label","dy","0.35em",4,"ngIf"],["dy","0.35em",1,"label"]],template:function(a,u){1&a&&(i.\u0275\u0275elementStart(0,"ngx-charts-chart",0),i.\u0275\u0275namespaceSVG(),i.\u0275\u0275elementStart(1,"g",1),i.\u0275\u0275template(2,Wh,6,14,"g",2)(3,Wp,2,12,"g",3)(4,sg,2,2,"g",4),i.\u0275\u0275elementEnd()()),2&a&&(i.\u0275\u0275property("view",i.\u0275\u0275pureFunction2(6,mc,u.width,u.height))("animations",u.animations),i.\u0275\u0275advance(),i.\u0275\u0275attribute("transform",u.transform),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.linkPaths),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.nodeRects),i.\u0275\u0275advance(),i.\u0275\u0275property("ngForOf",u.nodeRects))},dependencies:[cu,e.NgForOf,Hp,e.NgIf],styles:[qo],encapsulation:2,changeDetection:0}),c})(),xT=(()=>{class c{}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[[cf]]}),c})(),zb=(()=>{class c{constructor(){!function c0(){typeof SVGElement<"u"&&typeof SVGElement.prototype.contains>"u"&&(SVGElement.prototype.contains=HTMLDivElement.prototype.contains)}()}}return c.\u0275fac=function(a){return new(a||c)},c.\u0275mod=i.\u0275\u0275defineNgModule({type:c}),c.\u0275inj=i.\u0275\u0275defineInjector({imports:[cf,DC,Aw,e0,M_,TC,xT,AC,s0,pa,o0,l0,WS]}),c})();function Pw(c,g){return function(a){return"No Value"===a||"Other"===a?a:"date"===c&&"groupBy"===g?dh("MM/DD/YYYY")(a):a.toString()}}},992:(Ot,Me,S)=>{S.r(Me),S.d(Me,{EditorComponent:()=>Ae,EditorModule:()=>dt,TINYMCE_SCRIPT_SRC:()=>vn});var i=S(1270),e=S(2168),M=S(1738),X=S(1647);const ie=()=>{const ut=typeof window<"u"?window:void 0;return ut&&ut.tinymce?ut.tinymce:null};let Q=(()=>{class ut{onBeforePaste=new i.EventEmitter;onBlur=new i.EventEmitter;onClick=new i.EventEmitter;onCompositionEnd=new i.EventEmitter;onCompositionStart=new i.EventEmitter;onCompositionUpdate=new i.EventEmitter;onContextMenu=new i.EventEmitter;onCopy=new i.EventEmitter;onCut=new i.EventEmitter;onDblclick=new i.EventEmitter;onDrag=new i.EventEmitter;onDragDrop=new i.EventEmitter;onDragEnd=new i.EventEmitter;onDragGesture=new i.EventEmitter;onDragOver=new i.EventEmitter;onDrop=new i.EventEmitter;onFocus=new i.EventEmitter;onFocusIn=new i.EventEmitter;onFocusOut=new i.EventEmitter;onKeyDown=new i.EventEmitter;onKeyPress=new i.EventEmitter;onKeyUp=new i.EventEmitter;onMouseDown=new i.EventEmitter;onMouseEnter=new i.EventEmitter;onMouseLeave=new i.EventEmitter;onMouseMove=new i.EventEmitter;onMouseOut=new i.EventEmitter;onMouseOver=new i.EventEmitter;onMouseUp=new i.EventEmitter;onPaste=new i.EventEmitter;onSelectionChange=new i.EventEmitter;onActivate=new i.EventEmitter;onAddUndo=new i.EventEmitter;onBeforeAddUndo=new i.EventEmitter;onBeforeExecCommand=new i.EventEmitter;onBeforeGetContent=new i.EventEmitter;onBeforeRenderUI=new i.EventEmitter;onBeforeSetContent=new i.EventEmitter;onChange=new i.EventEmitter;onClearUndos=new i.EventEmitter;onDeactivate=new i.EventEmitter;onDirty=new i.EventEmitter;onExecCommand=new i.EventEmitter;onGetContent=new i.EventEmitter;onHide=new i.EventEmitter;onInit=new i.EventEmitter;onInput=new i.EventEmitter;onInitNgModel=new i.EventEmitter;onLoadContent=new i.EventEmitter;onNodeChange=new i.EventEmitter;onPostProcess=new i.EventEmitter;onPostRender=new i.EventEmitter;onPreInit=new i.EventEmitter;onPreProcess=new i.EventEmitter;onProgressState=new i.EventEmitter;onRedo=new i.EventEmitter;onRemove=new i.EventEmitter;onReset=new i.EventEmitter;onResizeEditor=new i.EventEmitter;onSaveContent=new i.EventEmitter;onSetAttrib=new i.EventEmitter;onObjectResizeStart=new i.EventEmitter;onObjectResized=new i.EventEmitter;onObjectSelected=new i.EventEmitter;onSetContent=new i.EventEmitter;onShow=new i.EventEmitter;onSubmit=new i.EventEmitter;onUndo=new i.EventEmitter;onVisualAid=new i.EventEmitter;static \u0275fac=function(It){return new(It||ut)};static \u0275dir=i.\u0275\u0275defineDirective({type:ut,outputs:{onBeforePaste:"onBeforePaste",onBlur:"onBlur",onClick:"onClick",onCompositionEnd:"onCompositionEnd",onCompositionStart:"onCompositionStart",onCompositionUpdate:"onCompositionUpdate",onContextMenu:"onContextMenu",onCopy:"onCopy",onCut:"onCut",onDblclick:"onDblclick",onDrag:"onDrag",onDragDrop:"onDragDrop",onDragEnd:"onDragEnd",onDragGesture:"onDragGesture",onDragOver:"onDragOver",onDrop:"onDrop",onFocus:"onFocus",onFocusIn:"onFocusIn",onFocusOut:"onFocusOut",onKeyDown:"onKeyDown",onKeyPress:"onKeyPress",onKeyUp:"onKeyUp",onMouseDown:"onMouseDown",onMouseEnter:"onMouseEnter",onMouseLeave:"onMouseLeave",onMouseMove:"onMouseMove",onMouseOut:"onMouseOut",onMouseOver:"onMouseOver",onMouseUp:"onMouseUp",onPaste:"onPaste",onSelectionChange:"onSelectionChange",onActivate:"onActivate",onAddUndo:"onAddUndo",onBeforeAddUndo:"onBeforeAddUndo",onBeforeExecCommand:"onBeforeExecCommand",onBeforeGetContent:"onBeforeGetContent",onBeforeRenderUI:"onBeforeRenderUI",onBeforeSetContent:"onBeforeSetContent",onChange:"onChange",onClearUndos:"onClearUndos",onDeactivate:"onDeactivate",onDirty:"onDirty",onExecCommand:"onExecCommand",onGetContent:"onGetContent",onHide:"onHide",onInit:"onInit",onInput:"onInput",onInitNgModel:"onInitNgModel",onLoadContent:"onLoadContent",onNodeChange:"onNodeChange",onPostProcess:"onPostProcess",onPostRender:"onPostRender",onPreInit:"onPreInit",onPreProcess:"onPreProcess",onProgressState:"onProgressState",onRedo:"onRedo",onRemove:"onRemove",onReset:"onReset",onResizeEditor:"onResizeEditor",onSaveContent:"onSaveContent",onSetAttrib:"onSetAttrib",onObjectResizeStart:"onObjectResizeStart",onObjectResized:"onObjectResized",onObjectSelected:"onObjectSelected",onSetContent:"onSetContent",onShow:"onShow",onSubmit:"onSubmit",onUndo:"onUndo",onVisualAid:"onVisualAid"}})}return ut})();const Ee=["onActivate","onAddUndo","onBeforeAddUndo","onBeforeExecCommand","onBeforeGetContent","onBeforeRenderUI","onBeforeSetContent","onBeforePaste","onBlur","onChange","onClearUndos","onClick","onCompositionEnd","onCompositionStart","onCompositionUpdate","onContextMenu","onCopy","onCut","onDblclick","onDeactivate","onDirty","onDrag","onDragDrop","onDragEnd","onDragGesture","onDragOver","onDrop","onExecCommand","onFocus","onFocusIn","onFocusOut","onGetContent","onHide","onInit","onInput","onKeyDown","onKeyPress","onKeyUp","onLoadContent","onMouseDown","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onNodeChange","onObjectResizeStart","onObjectResized","onObjectSelected","onPaste","onPostProcess","onPostRender","onPreProcess","onProgressState","onRedo","onRemove","onReset","onResizeEditor","onSaveContent","onSelectionChange","onSetAttrib","onSetContent","onShow","onSubmit","onUndo","onVisualAid"],he=(ut,Mt,Wt)=>(0,X.fromEvent)(ut,Mt).pipe((0,X.takeUntil)(Wt)),Z=(ut,Mt)=>"string"==typeof ut?ut.split(",").map(Wt=>Wt.trim()):Array.isArray(ut)?ut:Mt;let ce=0;const je=ut=>typeof ut<"u"&&"textarea"===ut.tagName.toLowerCase(),Et=ut=>typeof ut>"u"||""===ut?[]:Array.isArray(ut)?ut:ut.split(" "),wt=(ut,Mt)=>Et(ut).concat(Et(Mt)),ve=()=>{},fn=ut=>null==ut,un=(()=>{const ut=new X.BehaviorSubject(null),Mt=ut.pipe((0,X.filter)(Boolean),(0,X.switchMap)(([Wt,It])=>{const Vn=Wt.createElement("script");return Vn.referrerPolicy="origin",Vn.type="application/javascript",Vn.src=It,Wt.head.appendChild(Vn),(0,X.fromEvent)(Vn,"load").pipe(ut=>ut.pipe((0,X.first)(),(0,X.map)(()=>{})))}),(0,X.shareReplay)({bufferSize:1,refCount:!0}));return{load:(...Wt)=>(ut.getValue()||ut.next(Wt),Mt),reinitialize:()=>{ut.next(null)}}})(),vn=new i.InjectionToken("TINYMCE_SCRIPT_SRC"),Pt={provide:M.NG_VALUE_ACCESSOR,useExisting:(0,i.forwardRef)(()=>Ae),multi:!0};let Ae=(()=>{class ut extends Q{cdRef;platformId;tinymceScriptSrc;cloudChannel="7";apiKey="no-api-key";licenseKey;init;id="";initialValue;outputFormat;inline;tagName;plugins;toolbar;modelEvents="change input undo redo";allowedEvents;ignoreEvents;set disabled(Wt){this._disabled=Wt,this._editor&&this._editor.initialized&&("function"==typeof this._editor.mode?.set?this._editor.mode.set(Wt?"readonly":"design"):this._editor.setMode(Wt?"readonly":"design"))}get disabled(){return this._disabled}get editor(){return this._editor}ngZone;_elementRef;_element;_disabled;_editor;onTouchedCallback=ve;onChangeCallback;destroy$=new X.Subject;constructor(Wt,It,Vn,pn,Wn){super(),this.cdRef=Vn,this.platformId=pn,this.tinymceScriptSrc=Wn,this._elementRef=Wt,this.ngZone=It}writeValue(Wt){this._editor&&this._editor.initialized?this._editor.setContent(fn(Wt)?"":Wt):this.initialValue=null===Wt?void 0:Wt}registerOnChange(Wt){this.onChangeCallback=Wt}registerOnTouched(Wt){this.onTouchedCallback=Wt}setDisabledState(Wt){this.disabled=Wt}ngAfterViewInit(){(0,e.isPlatformBrowser)(this.platformId)&&(this.id=this.id||(()=>{const Wt=(new Date).getTime(),It=Math.floor(1e9*Math.random());return ce++,"tiny-angular_"+It+ce+String(Wt)})(),this.inline=void 0!==this.inline?!1!==this.inline:!!this.init?.inline,this.createElement(),null!==ie()?this.initialise():this._element&&this._element.ownerDocument&&un.load(this._element.ownerDocument,this.getScriptSrc()).pipe((0,X.takeUntil)(this.destroy$)).subscribe(this.initialise))}ngOnDestroy(){this.destroy$.next(),null!==ie()&&ie().remove(this._editor)}createElement(){if(this._element=document.createElement(this.inline?"string"==typeof this.tagName?this.tagName:"div":"textarea"),this._element){const It=document.getElementById(this.id);It&&It!==this._elementRef.nativeElement&&console.warn(`TinyMCE-Angular: an element with id [${this.id}] already exists. Editors with duplicate Id will not be able to mount`),this._element.id=this.id,je(this._element)&&(this._element.style.visibility="hidden"),this._elementRef.nativeElement.appendChild(this._element)}}initialise=()=>{const Wt={...this.init,selector:void 0,target:this._element,inline:this.inline,readonly:this.disabled,license_key:this.licenseKey,plugins:wt(this.init&&this.init.plugins,this.plugins),toolbar:this.toolbar||this.init&&this.init.toolbar,setup:It=>{this._editor=It,he(It,"init",this.destroy$).subscribe(()=>{this.initEditor(It)}),((ut,Mt,Wt)=>{(ut=>{const Mt=Z(ut.ignoreEvents,[]);return Z(ut.allowedEvents,Ee).filter(It=>Ee.includes(It)&&!Mt.includes(It))})(ut).forEach(Vn=>{const pn=ut[Vn];he(Mt,Vn.substring(2),Wt).subscribe(Wn=>{(ut=>ut.observed||ut.observers?.length>0)(pn)&&ut.ngZone.run(()=>pn.emit({event:Wn,editor:Mt}))})})})(this,It,this.destroy$),this.init&&"function"==typeof this.init.setup&&this.init.setup(It)}};je(this._element)&&(this._element.style.visibility=""),this.ngZone.runOutsideAngular(()=>{ie().init(Wt)})};getScriptSrc(){return fn(this.tinymceScriptSrc)?`https://cdn.tiny.cloud/1/${this.apiKey}/tinymce/${this.cloudChannel}/tinymce.min.js`:this.tinymceScriptSrc}initEditor(Wt){he(Wt,"blur",this.destroy$).subscribe(()=>{this.cdRef.markForCheck(),this.ngZone.run(()=>this.onTouchedCallback())}),he(Wt,this.modelEvents,this.destroy$).subscribe(()=>{this.cdRef.markForCheck(),this.ngZone.run(()=>this.emitOnChange(Wt))}),"string"==typeof this.initialValue&&this.ngZone.run(()=>{Wt.setContent(this.initialValue),Wt.getContent()!==this.initialValue&&this.emitOnChange(Wt),void 0!==this.onInitNgModel&&this.onInitNgModel.emit(Wt)})}emitOnChange(Wt){this.onChangeCallback&&this.onChangeCallback(Wt.getContent({format:this.outputFormat}))}static \u0275fac=function(It){return new(It||ut)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.NgZone),i.\u0275\u0275directiveInject(i.ChangeDetectorRef),i.\u0275\u0275directiveInject(i.PLATFORM_ID),i.\u0275\u0275directiveInject(vn,8))};static \u0275cmp=i.\u0275\u0275defineComponent({type:ut,selectors:[["editor"]],inputs:{cloudChannel:"cloudChannel",apiKey:"apiKey",licenseKey:"licenseKey",init:"init",id:"id",initialValue:"initialValue",outputFormat:"outputFormat",inline:"inline",tagName:"tagName",plugins:"plugins",toolbar:"toolbar",modelEvents:"modelEvents",allowedEvents:"allowedEvents",ignoreEvents:"ignoreEvents",disabled:"disabled"},standalone:!0,features:[i.\u0275\u0275ProvidersFeature([Pt]),i.\u0275\u0275InheritDefinitionFeature,i.\u0275\u0275StandaloneFeature],decls:0,vars:0,template:function(It,Vn){},dependencies:[e.CommonModule,M.FormsModule],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}return ut})(),dt=(()=>{class ut{static \u0275fac=function(It){return new(It||ut)};static \u0275mod=i.\u0275\u0275defineNgModule({type:ut});static \u0275inj=i.\u0275\u0275defineInjector({imports:[Ae]})}return ut})()},6476:(Ot,Me,S)=>{function i(){}S.d(Me,{C:()=>e});class e{constructor(X=1/0,ie=i){this.max=X,this.dispose=ie,this.map=new Map,this.newest=null,this.oldest=null}has(X){return this.map.has(X)}get(X){const ie=this.getNode(X);return ie&&ie.value}get size(){return this.map.size}getNode(X){const ie=this.map.get(X);if(ie&&ie!==this.newest){const{older:Q,newer:Ee}=ie;Ee&&(Ee.older=Q),Q&&(Q.newer=Ee),ie.older=this.newest,ie.older.newer=ie,ie.newer=null,this.newest=ie,ie===this.oldest&&(this.oldest=Ee)}return ie}set(X,ie){let Q=this.getNode(X);return Q?Q.value=ie:(Q={key:X,value:ie,newer:null,older:this.newest},this.newest&&(this.newest.newer=Q),this.newest=Q,this.oldest=this.oldest||Q,this.map.set(X,Q),Q.value)}clean(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)}delete(X){const ie=this.map.get(X);return!!ie&&(ie===this.newest&&(this.newest=ie.older),ie===this.oldest&&(this.oldest=ie.newer),ie.newer&&(ie.newer.older=ie.older),ie.older&&(ie.older.newer=ie.newer),this.map.delete(X),this.dispose(ie.value,X),!0)}}},9055:(Ot,Me,S)=>{function i(){}S.d(Me,{l:()=>Ee});const e=i,M=typeof WeakRef<"u"?WeakRef:function(he){return{deref:()=>he}},X=typeof WeakMap<"u"?WeakMap:Map,ie=typeof FinalizationRegistry<"u"?FinalizationRegistry:function(){return{register:i,unregister:i}};class Ee{constructor(q=1/0,oe=e){this.max=q,this.dispose=oe,this.map=new X,this.newest=null,this.oldest=null,this.unfinalizedNodes=new Set,this.finalizationScheduled=!1,this.size=0,this.finalize=()=>{const Z=this.unfinalizedNodes.values();for(let ce=0;ce<10024;ce++){const le=Z.next().value;if(!le)break;this.unfinalizedNodes.delete(le);const je=le.key;delete le.key,le.keyRef=new M(je),this.registry.register(je,le,le)}this.unfinalizedNodes.size>0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new ie(this.deleteNode.bind(this))}has(q){return this.map.has(q)}get(q){const oe=this.getNode(q);return oe&&oe.value}getNode(q){const oe=this.map.get(q);if(oe&&oe!==this.newest){const{older:Z,newer:ce}=oe;ce&&(ce.older=Z),Z&&(Z.newer=ce),oe.older=this.newest,oe.older.newer=oe,oe.newer=null,this.newest=oe,oe===this.oldest&&(this.oldest=ce)}return oe}set(q,oe){let Z=this.getNode(q);return Z?Z.value=oe:(Z={key:q,value:oe,newer:null,older:this.newest},this.newest&&(this.newest.newer=Z),this.newest=Z,this.oldest=this.oldest||Z,this.scheduleFinalization(Z),this.map.set(q,Z),this.size++,Z.value)}clean(){for(;this.oldest&&this.size>this.max;)this.deleteNode(this.oldest)}deleteNode(q){q===this.newest&&(this.newest=q.older),q===this.oldest&&(this.oldest=q.newer),q.newer&&(q.newer.older=q.older),q.older&&(q.older.newer=q.newer),this.size--;const oe=q.key||q.keyRef&&q.keyRef.deref();this.dispose(q.value,oe),q.keyRef?this.registry.unregister(q):this.unfinalizedNodes.delete(q),oe&&this.map.delete(oe)}delete(q){const oe=this.map.get(q);return!!oe&&(this.deleteNode(oe),!0)}scheduleFinalization(q){this.unfinalizedNodes.add(q),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}}},9860:(Ot,Me,S)=>{S.d(Me,{A:()=>Q,L:()=>ie});const{toString:i,hasOwnProperty:e}=Object.prototype,M=Function.prototype.toString,X=new Map;function ie(le,je){try{return Ee(le,je)}finally{X.clear()}}const Q=ie;function Ee(le,je){if(le===je)return!0;const Et=i.call(le);if(Et!==i.call(je))return!1;switch(Et){case"[object Array]":if(le.length!==je.length)return!1;case"[object Object]":{if(ce(le,je))return!0;const ve=he(le),fn=he(je),ct=ve.length;if(ct!==fn.length)return!1;for(let en=0;en<ct;++en)if(!e.call(je,ve[en]))return!1;for(let en=0;en<ct;++en){const an=ve[en];if(!Ee(le[an],je[an]))return!1}return!0}case"[object Error]":return le.name===je.name&&le.message===je.message;case"[object Number]":if(le!=le)return je!=je;case"[object Boolean]":case"[object Date]":return+le==+je;case"[object RegExp]":case"[object String]":return le==`${je}`;case"[object Map]":case"[object Set]":{if(le.size!==je.size)return!1;if(ce(le,je))return!0;const ve=le.entries(),fn="[object Map]"===Et;for(;;){const ct=ve.next();if(ct.done)break;const[en,an]=ct.value;if(!je.has(en)||fn&&!Ee(an,je.get(en)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":le=new Uint8Array(le),je=new Uint8Array(je);case"[object DataView]":{let ve=le.byteLength;if(ve===je.byteLength)for(;ve--&&le[ve]===je[ve];);return-1===ve}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{const ve=M.call(le);return ve===M.call(je)&&!function Z(le,je){const Et=le.length-je.length;return Et>=0&&le.indexOf(je,Et)===Et}(ve,oe)}}return!1}function he(le){return Object.keys(le).filter(q,le)}function q(le){return void 0!==this[le]}const oe="{ [native code] }";function ce(le,je){let Et=X.get(le);if(Et){if(Et.has(je))return!0}else X.set(le,Et=new Set);return Et.add(je),!1}},4420:(Ot,Me,S)=>{S.d(Me,{b:()=>ie});const i=()=>Object.create(null),{forEach:e,slice:M}=Array.prototype,{hasOwnProperty:X}=Object.prototype;class ie{constructor(he=!0,q=i){this.weakness=he,this.makeData=q}lookup(){return this.lookupArray(arguments)}lookupArray(he){let q=this;return e.call(he,oe=>q=q.getChildTrie(oe)),X.call(q,"data")?q.data:q.data=this.makeData(M.call(he))}peek(){return this.peekArray(arguments)}peekArray(he){let q=this;for(let oe=0,Z=he.length;q&&oe<Z;++oe){const ce=q.mapFor(he[oe],!1);q=ce&&ce.get(he[oe])}return q&&q.data}remove(){return this.removeArray(arguments)}removeArray(he){let q;if(he.length){const oe=he[0],Z=this.mapFor(oe,!1),ce=Z&&Z.get(oe);ce&&(q=ce.removeArray(M.call(he,1)),!ce.data&&!ce.weak&&(!ce.strong||!ce.strong.size)&&Z.delete(oe))}else q=this.data,delete this.data;return q}getChildTrie(he){const q=this.mapFor(he,!0);let oe=q.get(he);return oe||q.set(he,oe=new ie(this.weakness,this.makeData)),oe}mapFor(he,q){return this.weakness&&function Q(Ee){switch(typeof Ee){case"object":if(null===Ee)break;case"function":return!0}return!1}(he)?this.weak||(q?this.weak=new WeakMap:void 0):this.strong||(q?this.strong=new Map:void 0)}}},8606:(Ot,Me,S)=>{S.r(Me),S.d(Me,{AngularSvgIconModule:()=>wt,SERVER_URL:()=>q,SVG_ICON_REGISTRY_PROVIDER:()=>ce,SVG_ICON_REGISTRY_PROVIDER_FACTORY:()=>Z,SvgHttpLoader:()=>he,SvgIconComponent:()=>je,SvgIconRegistryService:()=>oe,SvgLoader:()=>Ee,provideAngularSvgIcon:()=>Et});var i=S(1270),e=S(1647),M=S(9335),X=S(2168),ie=S(1975);const Q=["*"];class Ee{}let he=(()=>{class ve extends Ee{constructor(ct){super(),this.http=ct}getSvg(ct){return this.http.get(ct,{responseType:"text"})}static#e=this.\u0275fac=function(en){return new(en||ve)(i.\u0275\u0275inject(ie.HttpClient))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:ve,factory:ve.\u0275fac})}return ve})();const q=new i.InjectionToken("SERVER_URL");let oe=(()=>{class ve{constructor(ct,en,an,un){this.loader=ct,this.platformId=en,this.serverUrl=an,this._document=un,this.iconsByUrl=new Map,this.iconsLoadingByUrl=new Map,this.document=this._document}addSvg(ct,en){if(!this.iconsByUrl.has(ct)){const an=this.document.createElement("DIV");an.innerHTML=en;const un=an.querySelector("svg");this.iconsByUrl.set(ct,un)}}loadSvg(ct,en=ct){if(this.serverUrl&&null===ct.match(/^(http(s)?):/)&&(en=ct=this.serverUrl+ct),this.iconsByUrl.has(en))return(0,e.of)(this.iconsByUrl.get(en));if(this.iconsLoadingByUrl.has(en))return this.iconsLoadingByUrl.get(en);const an=this.loader.getSvg(ct).pipe((0,M.map)(un=>{const vn=this.document.createElement("DIV");return vn.innerHTML=un,vn.querySelector("svg")}),(0,M.tap)(un=>this.iconsByUrl.set(en,un)),(0,M.catchError)(un=>(console.error(un),(0,e.throwError)(un))),(0,M.finalize)(()=>this.iconsLoadingByUrl.delete(en)),(0,M.share)());return this.iconsLoadingByUrl.set(en,an),an}getSvgByName(ct){return this.iconsByUrl.has(ct)?(0,e.of)(this.iconsByUrl.get(ct)):this.iconsLoadingByUrl.has(ct)?this.iconsLoadingByUrl.get(ct):(0,e.throwError)(`No svg with name '${ct}' has been loaded`)}unloadSvg(ct){this.iconsByUrl.has(ct)&&this.iconsByUrl.delete(ct)}static#e=this.\u0275fac=function(en){return new(en||ve)(i.\u0275\u0275inject(Ee),i.\u0275\u0275inject(i.PLATFORM_ID),i.\u0275\u0275inject(q,8),i.\u0275\u0275inject(X.DOCUMENT,8))};static#t=this.\u0275prov=i.\u0275\u0275defineInjectable({token:ve,factory:ve.\u0275fac})}return ve})();function Z(ve,fn,ct,en,an){return ve||new oe(fn,ct,en,an)}const ce={provide:oe,deps:[[new i.Optional,new i.SkipSelf,oe],Ee,[i.PLATFORM_ID],[new i.Optional,q],[new i.Optional,X.DOCUMENT]],useFactory:Z};class le{constructor(){this.loaded=!1}}let je=(()=>{class ve{set svgStyle(ct){this._svgStyle=ct,!this.helper.differ&&ct&&(this.helper.differ=this.differs.find(ct).create())}constructor(ct,en,an,un,vn){this.element=ct,this.differs=en,this.renderer=an,this.iconReg=un,this.cdr=vn,this.stretch=!1,this.applyClass=!1,this.applyCss=!1,this.helper=new le,this._svgStyle=null}ngOnInit(){this.init()}ngOnDestroy(){this.destroy()}ngOnChanges(ct){const en=this.element.nativeElement.firstChild;(ct.src||ct.name)&&(this.helper.loaded&&this.destroy(),this.init()),ct.stretch&&this.stylize(),ct.applyClass&&(this.applyClass?this.setClass(en,null,this.klass):this.setClass(en,this.klass,null)),ct.svgClass&&this.setClass(en,ct.svgClass.previousValue,ct.svgClass.currentValue),ct.klass&&(this.setClass(this.element.nativeElement,ct.klass.previousValue,ct.klass.currentValue),this.setClass(en,ct.klass.previousValue,this.applyClass?ct.klass.currentValue:null)),ct.viewBox&&(this.helper.loaded&&this.destroy(),this.init()),ct.applyCss&&(console.warn("applyCss deprecated since 9.1.0, will be removed in 10.0.0"),console.warn("use applyClass instead")),ct.svgAriaLabel&&this.doAria(ct.svgAriaLabel.currentValue)}ngDoCheck(){if(this.helper.svg&&this.helper.differ){const ct=this.helper.differ.diff(this._svgStyle);ct&&this.applyChanges(ct)}}init(){if(this.name){const ct=this.iconReg.getSvgByName(this.name);ct&&(this.helper.icnSub=ct.subscribe(en=>this.initSvg(en)))}else if(this.src){const ct=this.iconReg.loadSvg(this.src);ct&&(this.helper.icnSub=ct.subscribe(en=>this.initSvg(en)))}else this.element.nativeElement.innerHTML="",this.cdr.markForCheck()}initSvg(ct){!this.helper.loaded&&ct&&(this.setSvg(ct),this.resetDiffer())}destroy(){this.helper.icnSub&&this.helper.icnSub.unsubscribe(),this.helper=new le}resetDiffer(){this._svgStyle&&!this.helper.differ&&(this.helper.differ=this.differs.find(this._svgStyle).create())}setSvg(ct){if(!this.helper.loaded&&ct){this.helper.svg=ct;const en=ct.cloneNode(!0),an=this.element.nativeElement;if(an.innerHTML="",this.renderer.appendChild(an,en),this.helper.loaded=!0,this.copyNgContentAttribute(an,en),this.klass&&this.applyClass&&this.setClass(an.firstChild,null,this.klass),this.svgClass&&this.setClass(an.firstChild,null,this.svgClass),this.viewBox)if("auto"===this.viewBox){const un=en.getAttribute("width"),vn=en.getAttribute("height");vn&&un&&(this.renderer.setAttribute(en,"viewBox",`0 0 ${un} ${vn}`),this.renderer.removeAttribute(en,"width"),this.renderer.removeAttribute(en,"height"))}else""!==this.viewBox&&(this.renderer.setAttribute(en,"viewBox",this.viewBox),this.renderer.removeAttribute(en,"width"),this.renderer.removeAttribute(en,"height"));this.stylize(),void 0===this.svgAriaLabel&&an.firstChild.hasAttribute("aria-label")||this.doAria(this.svgAriaLabel||""),this.cdr.markForCheck()}}copyNgContentAttribute(ct,en){const an=ct.attributes,un=an.length;for(let vn=0;vn<un;vn+=1){const Pt=an.item(vn);if(Pt&&Pt.name.startsWith("_ngcontent")){this.setNgContentAttribute(en,Pt.name);break}}}setNgContentAttribute(ct,en){this.renderer.setAttribute(ct,en,"");const an=ct.childNodes.length;for(let un=0;un<an;un+=1){const vn=ct.childNodes[un];vn instanceof Element&&this.setNgContentAttribute(vn,en)}}stylize(){if(this.helper.svg){const ct=this.element.nativeElement.firstChild;!0===this.stretch?this.renderer.setAttribute(ct,"preserveAspectRatio","none"):!1===this.stretch&&this.renderer.removeAttribute(ct,"preserveAspectRatio")}}applyChanges(ct){ct.forEachRemovedItem(en=>this.setStyle(en.key,null)),ct.forEachAddedItem(en=>this.setStyle(en.key,en.currentValue)),ct.forEachChangedItem(en=>this.setStyle(en.key,en.currentValue))}setStyle(ct,en){const[an,un]=ct.split("."),vn=this.element.nativeElement.firstChild;null!==(en=null!==en&&un?`${en}${un}`:en)?this.renderer.setStyle(vn,an,en):this.renderer.removeStyle(vn,an)}setClass(ct,en,an){if(ct){if(en){const un=(Array.isArray(en)?en:en.split(" ")).filter(vn=>vn);for(const vn of un)this.renderer.removeClass(ct,vn)}if(an){const un=(Array.isArray(an)?an:an.split(" ")).filter(vn=>vn);for(const vn of un)this.renderer.addClass(ct,vn)}}}doAria(ct){const en=this.element.nativeElement.firstChild;en&&(""===ct?(this.renderer.setAttribute(en,"aria-hidden","true"),this.renderer.removeAttribute(en,"aria-label")):(this.renderer.removeAttribute(en,"aria-hidden"),this.renderer.setAttribute(en,"aria-label",ct)))}static#e=this.\u0275fac=function(en){return new(en||ve)(i.\u0275\u0275directiveInject(i.ElementRef),i.\u0275\u0275directiveInject(i.KeyValueDiffers),i.\u0275\u0275directiveInject(i.Renderer2),i.\u0275\u0275directiveInject(oe),i.\u0275\u0275directiveInject(i.ChangeDetectorRef))};static#t=this.\u0275cmp=i.\u0275\u0275defineComponent({type:ve,selectors:[["svg-icon"]],inputs:{src:"src",name:"name",stretch:"stretch",applyClass:"applyClass",applyCss:"applyCss",svgClass:"svgClass",klass:[0,"class","klass"],viewBox:"viewBox",svgAriaLabel:"svgAriaLabel",svgStyle:"svgStyle"},standalone:!0,features:[i.\u0275\u0275NgOnChangesFeature,i.\u0275\u0275StandaloneFeature],ngContentSelectors:Q,decls:1,vars:0,template:function(en,an){1&en&&(i.\u0275\u0275projectionDef(),i.\u0275\u0275projection(0))},dependencies:[X.CommonModule],encapsulation:2})}return ve})();function Et(ve={}){return(0,i.makeEnvironmentProviders)([ce,ve.loader||{provide:Ee,useClass:he}])}let wt=(()=>{class ve{static forRoot(ct={}){return{ngModule:ve,providers:[ce,ct.loader||{provide:Ee,useClass:he}]}}static#e=this.\u0275fac=function(en){return new(en||ve)};static#t=this.\u0275mod=i.\u0275\u0275defineNgModule({type:ve});static#n=this.\u0275inj=i.\u0275\u0275defineInjector({imports:[je]})}return ve})()},4676:(Ot,Me,S)=>{S.r(Me),S.d(Me,{APOLLO_FLAGS:()=>Aa,APOLLO_NAMED_OPTIONS:()=>Ql,APOLLO_OPTIONS:()=>ku,Apollo:()=>ta,ApolloBase:()=>sc,ApolloModule:()=>xu,Mutation:()=>Hs,Query:()=>Ll,QueryRef:()=>Lu,Subscription:()=>kl,gql:()=>fu,graphql:()=>Rc,provideApollo:()=>Fc,provideNamedApollo:()=>po});var i=S(1270),e=S(1647),M=function(Ke){return Ke[Ke.loading=1]="loading",Ke[Ke.setVariables=2]="setVariables",Ke[Ke.fetchMore=3]="fetchMore",Ke[Ke.refetch=4]="refetch",Ke[Ke.poll=6]="poll",Ke[Ke.ready=7]="ready",Ke[Ke.error=8]="error",Ke}(M||{});function X(Ke){return!!Ke&&Ke<7}var Q=S(3844),Ee=S(2455),he=S(8008),q=he.C.execute,oe=S(560),Z=S(4183),ce=S(7994),le=function(Ke,Se){var re;try{re=JSON.stringify(Ke)}catch(xt){var Ge=(0,Ee.vA)(40,Se,xt.message);throw Ge.parseError=xt,Ge}return re},Et=S(6500);function ct(Ke){var Se={next:function(){return Ke.read()}};return Et.uJ&&(Se[Symbol.asyncIterator]=function(){return this}),Se}function dt(Ke){var Se=Ke;if(function en(Ke){return!!Ke.body}(Ke)&&(Se=Ke.body),function un(Ke){return!(!Et.uJ||!Ke[Symbol.asyncIterator])}(Se))return function wt(Ke){var Se,re=Ke[Symbol.asyncIterator]();return(Se={next:function(){return re.next()}})[Symbol.asyncIterator]=function(){return this},Se}(Se);if(function an(Ke){return!!Ke.getReader}(Se))return ct(Se.getReader());if(function vn(Ke){return!!Ke.stream}(Se))return ct(Se.stream().getReader());if(function Pt(Ke){return!!Ke.arrayBuffer}(Se))return function fn(Ke){var Se=!1,re={next:function(){return Se?Promise.resolve({value:void 0,done:!0}):(Se=!0,new Promise(function(Ge,xt){Ke.then(function(Qt){Ge({value:Qt,done:!1})}).catch(xt)}))}};return Et.uJ&&(re[Symbol.asyncIterator]=function(){return this}),re}(Se.arrayBuffer());if(function Ae(Ke){return!!Ke.pipe}(Se))return function ve(Ke){var Se=null,re=null,Ge=!1,xt=[],Qt=[];function kn($i){if(!re){if(Qt.length){var Er=Qt.shift();if(Array.isArray(Er)&&Er[0])return Er[0]({value:$i,done:!1})}xt.push($i)}}function bi($i){re=$i,Qt.slice().forEach(function(ai){ai[1]($i)}),!Se||Se()}function vi(){Ge=!0,Qt.slice().forEach(function(Er){Er[0]({value:void 0,done:!0})}),!Se||Se()}Se=function(){Se=null,Ke.removeListener("data",kn),Ke.removeListener("error",bi),Ke.removeListener("end",vi),Ke.removeListener("finish",vi),Ke.removeListener("close",vi)},Ke.on("data",kn),Ke.on("error",bi),Ke.on("end",vi),Ke.on("finish",vi),Ke.on("close",vi);var Xi={next:function(){return function Ci(){return new Promise(function($i,Er){return re?Er(re):xt.length?$i({value:xt.shift(),done:!1}):Ge?$i({value:void 0,done:!0}):void Qt.push([$i,Er])})}()}};return Et.uJ&&(Xi[Symbol.asyncIterator]=function(){return this}),Xi}(Se);throw new Error("Unknown body type for responseIterator. Please pass a streamable response.")}var ut=function(Ke,Se,re){var Ge=new Error(re);throw Ge.name="ServerError",Ge.response=Ke,Ge.statusCode=Ke.status,Ge.result=Se,Ge},Mt=S(1181),Wt=Symbol();function Vn(Ke){return Ke.hasOwnProperty("graphQLErrors")}var Wn=function(Ke){function Se(re){var Ge=re.graphQLErrors,xt=re.protocolErrors,Qt=re.clientErrors,kn=re.networkError,bi=re.errorMessage,vi=re.extraInfo,Ci=Ke.call(this,bi)||this;return Ci.name="ApolloError",Ci.graphQLErrors=Ge||[],Ci.protocolErrors=xt||[],Ci.clientErrors=Qt||[],Ci.networkError=kn||null,Ci.message=bi||function(Ke){var Se=(0,Q.fX)((0,Q.fX)((0,Q.fX)([],Ke.graphQLErrors,!0),Ke.clientErrors,!0),Ke.protocolErrors,!0);return Ke.networkError&&Se.push(Ke.networkError),Se.map(function(re){return(0,Mt.U)(re)&&re.message||"Error message not found."}).join("\n")}(Ci),Ci.extraInfo=vi,Ci.cause=(0,Q.fX)((0,Q.fX)((0,Q.fX)([kn],Ge||[],!0),xt||[],!0),Qt||[],!0).find(function(Xi){return!!Xi})||null,Ci.__proto__=Se.prototype,Ci}return(0,Q.C6)(Se,Ke),Se}(Error),ji=S(7715),An=S(1115);function St(Ke){return"incremental"in Ke}function on(Ke){return(0,Mt.U)(Ke)&&"payload"in Ke}function Cn(Ke,Se){var re=Ke,Ge=new An.ZI;return St(Se)&&(0,ji.E)(Se.incremental)&&Se.incremental.forEach(function(xt){for(var Qt=xt.data,kn=xt.path,bi=kn.length-1;bi>=0;--bi){var vi=kn[bi],Xi=isNaN(+vi)?{}:[];Xi[vi]=Qt,Qt=Xi}re=Ge.merge(re,Qt)}),re}var tn=Object.prototype.hasOwnProperty;function Zn(Ke){var Se={};return Ke.split("\n").forEach(function(re){var Ge=re.indexOf(":");if(Ge>-1){var xt=re.slice(0,Ge).trim().toLowerCase(),Qt=re.slice(Ge+1).trim();Se[xt]=Qt}}),Se}function Dn(Ke,Se){Ke.status>=300&&ut(Ke,function(){try{return JSON.parse(Se)}catch{return Se}}(),"Response not successful: Received status code ".concat(Ke.status));try{return JSON.parse(Se)}catch(xt){var Ge=xt;throw Ge.name="ServerParseError",Ge.response=Ke,Ge.statusCode=Ke.status,Ge.bodyText=Se,Ge}}var cr=S(1658),Ur={http:{includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},eo=function(Ke,Se){return Se(Ke)};function yt(Ke){return new ce.c(function(Se){Se.error(Ke)})}var hn=S(4335),Gn=S(1601),ri=S(4229),pi=(0,Ee.no)(function(){return fetch}),At=function(Ke){void 0===Ke&&(Ke={});var Se=Ke.uri,re=void 0===Se?"/graphql":Se,Ge=Ke.fetch,xt=Ke.print,Qt=void 0===xt?eo:xt,kn=Ke.includeExtensions,bi=Ke.preserveHeaderCase,vi=Ke.useGETForQueries,Ci=Ke.includeUnusedVariables,Xi=void 0!==Ci&&Ci,$i=(0,Q.Tt)(Ke,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);!1!==globalThis.__DEV__&&function(Ke){if(!Ke&&typeof fetch>"u")throw(0,Ee.vA)(38)}(Ge||pi);var Er={http:{includeExtensions:kn,preserveHeaderCase:bi},options:$i.fetchOptions,credentials:$i.credentials,headers:$i.headers};return new he.C(function(ai){var so=function(Ke,Se){return Ke.getContext().uri||("function"==typeof Se?Se(Ke):Se||"/graphql")}(ai,re),Fr=ai.getContext(),zr={};if(Fr.clientAwareness){var ho=Fr.clientAwareness,Vr=ho.name,is=ho.version;Vr&&(zr["apollographql-client-name"]=Vr),is&&(zr["apollographql-client-version"]=is)}var Ms=(0,Q.Cl)((0,Q.Cl)({},zr),Fr.headers),Ds={http:Fr.http,options:Fr.fetchOptions,credentials:Fr.credentials,headers:Ms};if((0,Z.d8)(["client"],ai.query)){var Xo=(0,Gn.er)(ai.query);if(!Xo)return yt(new Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));ai.query=Xo}var Je,na=function uo(Ke,Se){for(var re=[],Ge=2;Ge<arguments.length;Ge++)re[Ge-2]=arguments[Ge];var xt={},Qt={};re.forEach(function($i){xt=(0,Q.Cl)((0,Q.Cl)((0,Q.Cl)({},xt),$i.options),{headers:(0,Q.Cl)((0,Q.Cl)({},xt.headers),$i.headers)}),$i.credentials&&(xt.credentials=$i.credentials),Qt=(0,Q.Cl)((0,Q.Cl)({},Qt),$i.http)}),xt.headers&&(xt.headers=function mi(Ke,Se){if(!Se){var re={};return Object.keys(Object(Ke)).forEach(function(Qt){re[Qt.toLowerCase()]=Ke[Qt]}),re}var Ge={};Object.keys(Object(Ke)).forEach(function(Qt){Ge[Qt.toLowerCase()]={originalName:Qt,value:Ke[Qt]}});var xt={};return Object.keys(Ge).forEach(function(Qt){xt[Ge[Qt].originalName]=Ge[Qt].value}),xt}(xt.headers,Qt.preserveHeaderCase));var Ci=Ke.query,Xi={operationName:Ke.operationName,variables:Ke.variables};return Qt.includeExtensions&&(Xi.extensions=Ke.extensions),Qt.includeQuery&&(Xi.query=Se(Ci,cr.y)),{options:xt,body:Xi}}(ai,Qt,Ur,Er,Ds),zs=na.options,ya=na.body;ya.variables&&!Xi&&(ya.variables=function Gt(Ke,Se){var re=(0,Q.Cl)({},Ke),Ge=new Set(Object.keys(Ke));return(0,hn.visit)(Se,{Variable:function(xt,Qt,kn){kn&&"VariableDefinition"!==kn.kind&&Ge.delete(xt.name.value)}}),Ge.forEach(function(xt){delete re[xt]}),re}(ya.variables,ai.query)),!zs.signal&&typeof AbortController<"u"&&(Je=new AbortController,zs.signal=Je.signal);var fo,Ct="OperationDefinition"===(fo=(0,ri.Vn)(ai.query)).kind&&"subscription"===fo.operation,On=(0,Z.d8)(["defer"],ai.query);if(vi&&!ai.query.definitions.some(function(fo){return"OperationDefinition"===fo.kind&&"mutation"===fo.operation})&&(zs.method="GET"),On||Ct){zs.headers=zs.headers||{};var _i="multipart/mixed;";Ct&&On&&!1!==globalThis.__DEV__&&Ee.V1.warn(39),Ct?_i+="boundary=graphql;subscriptionSpec=1.0,application/json":On&&(_i+="deferSpec=20220824,application/json"),zs.headers.accept=_i}if("GET"===zs.method){var Qn=function ci(Ke,Se){var re=[],Ge=function($i,Er){re.push("".concat($i,"=").concat(encodeURIComponent(Er)))};if("query"in Se&&Ge("query",Se.query),Se.operationName&&Ge("operationName",Se.operationName),Se.variables){var xt=void 0;try{xt=le(Se.variables,"Variables map")}catch($i){return{parseError:$i}}Ge("variables",xt)}if(Se.extensions){var Qt=void 0;try{Qt=le(Se.extensions,"Extensions map")}catch($i){return{parseError:$i}}Ge("extensions",Qt)}var kn="",bi=Ke,vi=Ke.indexOf("#");-1!==vi&&(kn=Ke.substr(vi),bi=Ke.substr(0,vi));var Ci=-1===bi.indexOf("?")?"?":"&";return{newURI:bi+Ci+re.join("&")+kn}}(so,ya),qi=Qn.newURI,Di=Qn.parseError;if(Di)return yt(Di);so=qi}else try{zs.body=le(ya,"Payload")}catch(fo){return yt(fo)}return new ce.c(function(fo){var Uo=Ge||(0,Ee.no)(function(){return fetch})||pi,Gs=fo.next.bind(fo);return Uo(so,zs).then(function(ba){var Za;ai.setContext({response:ba});var Ks=null===(Za=ba.headers)||void 0===Za?void 0:Za.get("content-type");return null!==Ks&&/^multipart\/mixed/i.test(Ks)?function fi(Ke,Se){return(0,Q.sH)(this,void 0,void 0,function(){var re,Ge,xt,Qt,kn,bi,vi,Ci,Xi,$i,Er,ai,so,Fr,zr,ho,Vr,is,Ms,Ds,Xo,na,zs,ya;return(0,Q.YH)(this,function(Je){switch(Je.label){case 0:if(void 0===TextDecoder)throw new Error("TextDecoder must be defined in the environment: please import a polyfill.");re=new TextDecoder("utf-8"),Ge=null===(ya=Ke.headers)||void 0===ya?void 0:ya.get("content-type"),xt="boundary=",Qt=Ge?.includes(xt)?Ge?.substring(Ge?.indexOf(xt)+9).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",kn="\r\n--".concat(Qt),bi="",vi=dt(Ke),Ci=!0,Je.label=1;case 1:return Ci?[4,vi.next()]:[3,3];case 2:for(Xi=Je.sent(),Er=Xi.done,ai="string"==typeof($i=Xi.value)?$i:re.decode($i),so=bi.length-kn.length+1,Ci=!Er,Fr=(bi+=ai).indexOf(kn,so);Fr>-1;){if(zr=void 0,na=[bi.slice(0,Fr),bi.slice(Fr+kn.length)],bi=na[1],ho=(zr=na[0]).indexOf("\r\n\r\n"),Vr=Zn(zr.slice(0,ho)),(is=Vr["content-type"])&&-1===is.toLowerCase().indexOf("application/json"))throw new Error("Unsupported patch content type: application/json is required.");if(Ms=zr.slice(ho))if(Ds=Dn(Ke,Ms),Object.keys(Ds).length>1||"data"in Ds||"incremental"in Ds||"errors"in Ds||"payload"in Ds)if(on(Ds)){if(Xo={},"payload"in Ds){if(1===Object.keys(Ds).length&&null===Ds.payload)return[2];Xo=(0,Q.Cl)({},Ds.payload)}"errors"in Ds&&(Xo=(0,Q.Cl)((0,Q.Cl)({},Xo),{extensions:(0,Q.Cl)((0,Q.Cl)({},"extensions"in Xo?Xo.extensions:null),(zs={},zs[Wt]=Ds.errors,zs))})),Se(Xo)}else Se(Ds);else if(1===Object.keys(Ds).length&&"hasNext"in Ds&&!Ds.hasNext)return[2];Fr=bi.indexOf(kn)}return[3,1];case 3:return[2]}})})}(ba,Gs):function Nn(Ke){return function(Se){return Se.text().then(function(re){return Dn(Se,re)}).then(function(re){return!Array.isArray(re)&&!tn.call(re,"data")&&!tn.call(re,"errors")&&ut(Se,re,"Server response was missing for query '".concat(Array.isArray(Ke)?Ke.map(function(Ge){return Ge.operationName}):Ke.operationName,"'.")),re})}}(ai)(ba).then(Gs)}).then(function(){Je=void 0,fo.complete()}).catch(function(ba){Je=void 0,function gn(Ke,Se){Ke.result&&Ke.result.errors&&Ke.result.data&&Se.next(Ke.result),Se.error(Ke)}(ba,fo)}),function(){Je&&Je.abort()}})})},Bn=function(Ke){function Se(re){void 0===re&&(re={});var Ge=Ke.call(this,At(re).request)||this;return Ge.options=re,Ge}return(0,Q.C6)(Se,Ke),Se}(he.C),Mn=S(9860),ni=S(2130),qn=S(8926);function Ti(Ke,Se,re){return new ce.c(function(Ge){var xt={then:function(vi){return new Promise(function(Ci){return Ci(vi())})}};function Qt(vi,Ci){return function(Xi){if(vi){var $i=function(){return Ge.closed?0:vi(Xi)};xt=xt.then($i,$i).then(function(Er){return Ge.next(Er)},function(Er){return Ge.error(Er)})}else Ge[Ci](Xi)}}var kn={next:Qt(Se,"next"),error:Qt(re,"error"),complete:function(){xt.then(function(){return Ge.complete()})}},bi=Ke.subscribe(kn);return function(){return bi.unsubscribe()}})}function Bi(Ke){var Se=Gi(Ke);return(0,ji.E)(Se)}function Gi(Ke){var Se=(0,ji.E)(Ke.errors)?Ke.errors.slice(0):[];return St(Ke)&&(0,ji.E)(Ke.incremental)&&Ke.incremental.forEach(function(re){re.errors&&Se.push.apply(Se,re.errors)}),Se}var Ii=S(1367),Ki=S(9977);function Jt(Ke,Se,re){var Ge=[];Ke.forEach(function(xt){return xt[Se]&&Ge.push(xt)}),Ge.forEach(function(xt){return xt[Se](re)})}function hi(Ke){function Se(re){Object.defineProperty(Ke,re,{value:ce.c})}return Et.ol&&Symbol.species&&Se(Symbol.species),Se("@@species"),Ke}function Ft(Ke){return Ke&&"function"==typeof Ke.then}var it=function(Ke){function Se(re){var Ge=Ke.call(this,function(xt){return Ge.addObserver(xt),function(){return Ge.removeObserver(xt)}})||this;return Ge.observers=new Set,Ge.promise=new Promise(function(xt,Qt){Ge.resolve=xt,Ge.reject=Qt}),Ge.handlers={next:function(xt){null!==Ge.sub&&(Ge.latest=["next",xt],Ge.notify("next",xt),Jt(Ge.observers,"next",xt))},error:function(xt){var Qt=Ge.sub;null!==Qt&&(Qt&&setTimeout(function(){return Qt.unsubscribe()}),Ge.sub=null,Ge.latest=["error",xt],Ge.reject(xt),Ge.notify("error",xt),Jt(Ge.observers,"error",xt))},complete:function(){var Qt=Ge.sub,kn=Ge.sources;if(null!==Qt){var vi=(void 0===kn?[]:kn).shift();vi?Ft(vi)?vi.then(function(Ci){return Ge.sub=Ci.subscribe(Ge.handlers)},Ge.handlers.error):Ge.sub=vi.subscribe(Ge.handlers):(Qt&&setTimeout(function(){return Qt.unsubscribe()}),Ge.sub=null,Ge.latest&&"next"===Ge.latest[0]?Ge.resolve(Ge.latest[1]):Ge.resolve(),Ge.notify("complete"),Jt(Ge.observers,"complete"))}}},Ge.nextResultListeners=new Set,Ge.cancel=function(xt){Ge.reject(xt),Ge.sources=[],Ge.handlers.error(xt)},Ge.promise.catch(function(xt){}),"function"==typeof re&&(re=[new ce.c(re)]),Ft(re)?re.then(function(xt){return Ge.start(xt)},Ge.handlers.error):Ge.start(re),Ge}return(0,Q.C6)(Se,Ke),Se.prototype.start=function(re){void 0===this.sub&&(this.sources=Array.from(re),this.handlers.complete())},Se.prototype.deliverLastMessage=function(re){if(this.latest){var Ge=this.latest[0],xt=re[Ge];xt&&xt.call(re,this.latest[1]),null===this.sub&&"next"===Ge&&re.complete&&re.complete()}},Se.prototype.addObserver=function(re){this.observers.has(re)||(this.deliverLastMessage(re),this.observers.add(re))},Se.prototype.removeObserver=function(re){this.observers.delete(re)&&this.observers.size<1&&this.handlers.complete()},Se.prototype.notify=function(re,Ge){var xt=this.nextResultListeners;xt.size&&(this.nextResultListeners=new Set,xt.forEach(function(Qt){return Qt(re,Ge)}))},Se.prototype.beforeNext=function(re){var Ge=!1;this.nextResultListeners.add(function(xt,Qt){Ge||(Ge=!0,re(xt,Qt))})},Se}(ce.c);hi(it);var sn=S(120),Ve=S(4246),He=S(9471),mt=Object.assign,bt=Object.hasOwnProperty,nn=function(Ke){function Se(re){var Ge=re.queryManager,xt=re.queryInfo,Qt=re.options,kn=Ke.call(this,function(zr){try{var ho=zr._subscription._observer;ho&&!ho.error&&(ho.error=Sn)}catch{}var Vr=!kn.observers.size;kn.observers.add(zr);var is=kn.last;return is&&is.error?zr.error&&zr.error(is.error):is&&is.result&&zr.next&&zr.next(is.result),Vr&&kn.reobserve().catch(function(){}),function(){kn.observers.delete(zr)&&!kn.observers.size&&kn.tearDownQuery()}})||this;kn.observers=new Set,kn.subscriptions=new Set,kn.queryInfo=xt,kn.queryManager=Ge,kn.waitForOwnResult=qr(Qt.fetchPolicy),kn.isTornDown=!1,kn.subscribeToMore=kn.subscribeToMore.bind(kn);var bi=Ge.defaultOptions.watchQuery,Ci=(void 0===bi?{}:bi).fetchPolicy,Xi=void 0===Ci?"cache-first":Ci,$i=Qt.fetchPolicy,Er=void 0===$i?Xi:$i,ai=Qt.initialFetchPolicy,so=void 0===ai?"standby"===Er?Xi:Er:ai;kn.options=(0,Q.Cl)((0,Q.Cl)({},Qt),{initialFetchPolicy:so,fetchPolicy:Er}),kn.queryId=xt.queryId||Ge.generateQueryId();var Fr=(0,ri.Vu)(kn.query);return kn.queryName=Fr&&Fr.name&&Fr.name.value,kn}return(0,Q.C6)(Se,Ke),Object.defineProperty(Se.prototype,"query",{get:function(){return this.lastQuery||this.options.query},enumerable:!1,configurable:!0}),Object.defineProperty(Se.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),Se.prototype.result=function(){var re=this;return new Promise(function(Ge,xt){var Qt={next:function(bi){Ge(bi),re.observers.delete(Qt),re.observers.size||re.queryManager.removeQuery(re.queryId),setTimeout(function(){kn.unsubscribe()},0)},error:xt},kn=re.subscribe(Qt)})},Se.prototype.resetDiff=function(){this.queryInfo.resetDiff()},Se.prototype.getCurrentResult=function(re){void 0===re&&(re=!0);var Ge=this.getLastResult(!0),xt=this.queryInfo.networkStatus||Ge&&Ge.networkStatus||M.ready,Qt=(0,Q.Cl)((0,Q.Cl)({},Ge),{loading:X(xt),networkStatus:xt}),kn=this.options.fetchPolicy,bi=void 0===kn?"cache-first":kn;if(!qr(bi)&&!this.queryManager.getDocumentInfo(this.query).hasForcedResolvers)if(this.waitForOwnResult)this.queryInfo.updateWatch();else{var vi=this.queryInfo.getDiff();(vi.complete||this.options.returnPartialData)&&(Qt.data=vi.result),(0,Mn.L)(Qt.data,{})&&(Qt.data=void 0),vi.complete?(delete Qt.partial,vi.complete&&Qt.networkStatus===M.loading&&("cache-first"===bi||"cache-only"===bi)&&(Qt.networkStatus=M.ready,Qt.loading=!1)):Qt.partial=!0,!1!==globalThis.__DEV__&&!vi.complete&&!this.options.partialRefetch&&!Qt.loading&&!Qt.data&&!Qt.error&&_r(vi.missing)}return re&&this.updateLastResult(Qt),Qt},Se.prototype.isDifferentFromLastResult=function(re,Ge){return!this.last||(this.queryManager.getDocumentInfo(this.query).hasNonreactiveDirective?!(0,He.a)(this.query,this.last.result,re,this.variables):!(0,Mn.L)(this.last.result,re))||Ge&&!(0,Mn.L)(this.last.variables,Ge)},Se.prototype.getLast=function(re,Ge){var xt=this.last;if(xt&&xt[re]&&(!Ge||(0,Mn.L)(xt.variables,this.variables)))return xt[re]},Se.prototype.getLastResult=function(re){return this.getLast("result",re)},Se.prototype.getLastError=function(re){return this.getLast("error",re)},Se.prototype.resetLastResults=function(){delete this.last,this.isTornDown=!1},Se.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId)},Se.prototype.refetch=function(re){var Ge,xt={pollInterval:0},Qt=this.options.fetchPolicy;if(xt.fetchPolicy="cache-and-network"===Qt?Qt:"no-cache"===Qt?"no-cache":"network-only",!1!==globalThis.__DEV__&&re&&bt.call(re,"variables")){var kn=(0,ri.AT)(this.query),bi=kn.variableDefinitions;(!bi||!bi.some(function(vi){return"variables"===vi.variable.name.value}))&&!1!==globalThis.__DEV__&&Ee.V1.warn(20,re,(null===(Ge=kn.name)||void 0===Ge?void 0:Ge.value)||kn)}return re&&!(0,Mn.L)(this.options.variables,re)&&(xt.variables=this.options.variables=(0,Q.Cl)((0,Q.Cl)({},this.options.variables),re)),this.queryInfo.resetLastWrite(),this.reobserve(xt,M.refetch)},Se.prototype.fetchMore=function(re){var Ge=this,xt=(0,Q.Cl)((0,Q.Cl)({},re.query?re:(0,Q.Cl)((0,Q.Cl)((0,Q.Cl)((0,Q.Cl)({},this.options),{query:this.options.query}),re),{variables:(0,Q.Cl)((0,Q.Cl)({},this.options.variables),re.variables)})),{fetchPolicy:"no-cache"});xt.query=this.transformDocument(xt.query);var Qt=this.queryManager.generateQueryId();this.lastQuery=re.query?this.transformDocument(this.options.query):xt.query;var kn=this.queryInfo,bi=kn.networkStatus;kn.networkStatus=M.fetchMore,xt.notifyOnNetworkStatusChange&&this.observe();var vi=new Set,Ci=re?.updateQuery,Xi="no-cache"!==this.options.fetchPolicy;return Xi||(0,Ee.V1)(Ci,21),this.queryManager.fetchQuery(Qt,xt,M.fetchMore).then(function($i){if(Ge.queryManager.removeQuery(Qt),kn.networkStatus===M.fetchMore&&(kn.networkStatus=bi),Xi)Ge.queryManager.cache.batch({update:function(so){var Fr=re.updateQuery;Fr?so.updateQuery({query:Ge.query,variables:Ge.variables,returnPartialData:!0,optimistic:!1},function(zr){return Fr(zr,{fetchMoreResult:$i.data,variables:xt.variables})}):so.writeQuery({query:xt.query,variables:xt.variables,data:$i.data})},onWatchUpdated:function(so){vi.add(so.query)}});else{var Er=Ge.getLast("result"),ai=Ci(Er.data,{fetchMoreResult:$i.data,variables:xt.variables});Ge.reportResult((0,Q.Cl)((0,Q.Cl)({},Er),{data:ai}),Ge.variables)}return $i}).finally(function(){Xi&&!vi.has(Ge.query)&&Jn(Ge)})},Se.prototype.subscribeToMore=function(re){var Ge=this,xt=this.queryManager.startGraphQLSubscription({query:re.document,variables:re.variables,context:re.context}).subscribe({next:function(Qt){var kn=re.updateQuery;kn&&Ge.updateQuery(function(bi,vi){return kn(bi,{subscriptionData:Qt,variables:vi.variables})})},error:function(Qt){re.onError?re.onError(Qt):!1!==globalThis.__DEV__&&Ee.V1.error(22,Qt)}});return this.subscriptions.add(xt),function(){Ge.subscriptions.delete(xt)&&xt.unsubscribe()}},Se.prototype.setOptions=function(re){return this.reobserve(re)},Se.prototype.silentSetOptions=function(re){var Ge=(0,sn.o)(this.options,re||{});mt(this.options,Ge)},Se.prototype.setVariables=function(re){return(0,Mn.L)(this.variables,re)?this.observers.size?this.result():Promise.resolve():(this.options.variables=re,this.observers.size?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:re},M.setVariables):Promise.resolve())},Se.prototype.updateQuery=function(re){var Ge=this.queryManager,Qt=re(Ge.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}).result,{variables:this.variables});Qt&&(Ge.cache.writeQuery({query:this.options.query,data:Qt,variables:this.variables}),Ge.broadcastQueries())},Se.prototype.startPolling=function(re){this.options.pollInterval=re,this.updatePolling()},Se.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},Se.prototype.applyNextFetchPolicy=function(re,Ge){if(Ge.nextFetchPolicy){var xt=Ge.fetchPolicy,Qt=void 0===xt?"cache-first":xt,kn=Ge.initialFetchPolicy,bi=void 0===kn?Qt:kn;"standby"===Qt||(Ge.fetchPolicy="function"==typeof Ge.nextFetchPolicy?Ge.nextFetchPolicy(Qt,{reason:re,options:Ge,observable:this,initialFetchPolicy:bi}):"variables-changed"===re?bi:Ge.nextFetchPolicy)}return Ge.fetchPolicy},Se.prototype.fetch=function(re,Ge,xt){return this.queryManager.setObservableQuery(this),this.queryManager.fetchConcastWithInfo(this.queryId,re,Ge,xt)},Se.prototype.updatePolling=function(){var re=this;if(!this.queryManager.ssrMode){var xt=this.pollingInfo,Qt=this.options.pollInterval;if(!Qt||!this.hasObservers())return void(xt&&(clearTimeout(xt.timeout),delete this.pollingInfo));if(!xt||xt.interval!==Qt){(0,Ee.V1)(Qt,23),(xt||(this.pollingInfo={})).interval=Qt;var bi=function(){var Ci,Xi;re.pollingInfo&&(X(re.queryInfo.networkStatus)||null!==(Xi=(Ci=re.options).skipPollAttempt)&&void 0!==Xi&&Xi.call(Ci)?vi():re.reobserve({fetchPolicy:"no-cache"===re.options.initialFetchPolicy?"no-cache":"network-only"},M.poll).then(vi,vi))},vi=function(){var Ci=re.pollingInfo;Ci&&(clearTimeout(Ci.timeout),Ci.timeout=setTimeout(bi,Ci.interval))};vi()}}},Se.prototype.updateLastResult=function(re,Ge){void 0===Ge&&(Ge=this.variables);var xt=this.getLastError();return xt&&this.last&&!(0,Mn.L)(Ge,this.last.variables)&&(xt=void 0),this.last=(0,Q.Cl)({result:this.queryManager.assumeImmutableResults?re:(0,Ve.m)(re),variables:Ge},xt?{error:xt}:null)},Se.prototype.reobserveAsConcast=function(re,Ge){var xt=this;this.isTornDown=!1;var Qt=Ge===M.refetch||Ge===M.fetchMore||Ge===M.poll,kn=this.options.variables,bi=this.options.fetchPolicy,vi=(0,sn.o)(this.options,re||{}),Ci=Qt?vi:mt(this.options,vi),Xi=this.transformDocument(Ci.query);this.lastQuery=Xi,Qt||(this.updatePolling(),re&&re.variables&&!(0,Mn.L)(re.variables,kn)&&"standby"!==Ci.fetchPolicy&&(Ci.fetchPolicy===bi||"function"==typeof Ci.nextFetchPolicy)&&(this.applyNextFetchPolicy("variables-changed",Ci),void 0===Ge&&(Ge=M.setVariables))),this.waitForOwnResult&&(this.waitForOwnResult=qr(Ci.fetchPolicy));var $i=function(){xt.concast===so&&(xt.waitForOwnResult=!1)},Er=Ci.variables&&(0,Q.Cl)({},Ci.variables),ai=this.fetch(Ci,Ge,Xi),so=ai.concast,zr={next:function(ho){(0,Mn.L)(xt.variables,Er)&&($i(),xt.reportResult(ho,Er))},error:function(ho){(0,Mn.L)(xt.variables,Er)&&(Vn(ho)||(ho=new Wn({networkError:ho})),$i(),xt.reportError(ho,Er))}};return!Qt&&(ai.fromLink||!this.concast)&&(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=so,this.observer=zr),so.addObserver(zr),so},Se.prototype.reobserve=function(re,Ge){return this.reobserveAsConcast(re,Ge).promise},Se.prototype.resubscribeAfterError=function(){for(var re=[],Ge=0;Ge<arguments.length;Ge++)re[Ge]=arguments[Ge];var xt=this.last;this.resetLastResults();var Qt=this.subscribe.apply(this,re);return this.last=xt,Qt},Se.prototype.observe=function(){this.reportResult(this.getCurrentResult(!1),this.variables)},Se.prototype.reportResult=function(re,Ge){var xt=this.getLastError(),Qt=this.isDifferentFromLastResult(re,Ge);(xt||!re.partial||this.options.returnPartialData)&&this.updateLastResult(re,Ge),(xt||Qt)&&Jt(this.observers,"next",re)},Se.prototype.reportError=function(re,Ge){var xt=(0,Q.Cl)((0,Q.Cl)({},this.getLastResult()),{error:re,errors:re.graphQLErrors,networkStatus:M.error,loading:!1});this.updateLastResult(xt,Ge),Jt(this.observers,"error",this.last.error=re)},Se.prototype.hasObservers=function(){return this.observers.size>0},Se.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(re){return re.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},Se.prototype.transformDocument=function(re){return this.queryManager.transform(re)},Se}(ce.c);function Jn(Ke){var Se=Ke.options,re=Se.fetchPolicy,Ge=Se.nextFetchPolicy;return"cache-and-network"===re||"network-only"===re?Ke.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(xt,Qt){return this.nextFetchPolicy=Ge,"function"==typeof this.nextFetchPolicy?this.nextFetchPolicy(xt,Qt):re}}):Ke.reobserve()}function Sn(Ke){!1!==globalThis.__DEV__&&Ee.V1.error(24,Ke.message,Ke.stack)}function _r(Ke){!1!==globalThis.__DEV__&&Ke&&!1!==globalThis.__DEV__&&Ee.V1.debug(25,Ke)}function qr(Ke){return"network-only"===Ke||"no-cache"===Ke||"standby"===Ke}hi(nn);var Bo=new(Et.et?WeakMap:Map);function Eo(Ke,Se){var re=Ke[Se];"function"==typeof re&&(Ke[Se]=function(){return Bo.set(Ke,(Bo.get(Ke)+1)%1e15),re.apply(this,arguments)})}function Ro(Ke){Ke.notifyTimeout&&(clearTimeout(Ke.notifyTimeout),Ke.notifyTimeout=void 0)}var Ls=function(){function Ke(Se,re){void 0===re&&(re=Se.generateQueryId()),this.queryId=re,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.stopped=!1,this.dirty=!1,this.observableQuery=null;var Ge=this.cache=Se.cache;Bo.has(Ge)||(Bo.set(Ge,0),Eo(Ge,"evict"),Eo(Ge,"modify"),Eo(Ge,"reset"))}return Ke.prototype.init=function(Se){var re=Se.networkStatus||M.loading;return this.variables&&this.networkStatus!==M.loading&&!(0,Mn.L)(this.variables,Se.variables)&&(re=M.setVariables),(0,Mn.L)(Se.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:Se.document,variables:Se.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:re}),Se.observableQuery&&this.setObservableQuery(Se.observableQuery),Se.lastRequestId&&(this.lastRequestId=Se.lastRequestId),this},Ke.prototype.reset=function(){Ro(this),this.dirty=!1},Ke.prototype.resetDiff=function(){this.lastDiff=void 0},Ke.prototype.getDiff=function(){var Se=this.getDiffOptions();if(this.lastDiff&&(0,Mn.L)(Se,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var re=this.observableQuery;if(re&&"no-cache"===re.options.fetchPolicy)return{complete:!1};var Ge=this.cache.diff(Se);return this.updateLastDiff(Ge,Se),Ge},Ke.prototype.updateLastDiff=function(Se,re){this.lastDiff=Se?{diff:Se,options:re||this.getDiffOptions()}:void 0},Ke.prototype.getDiffOptions=function(Se){var re;return void 0===Se&&(Se=this.variables),{query:this.document,variables:Se,returnPartialData:!0,optimistic:!0,canonizeResults:null===(re=this.observableQuery)||void 0===re?void 0:re.options.canonizeResults}},Ke.prototype.setDiff=function(Se){var Ge,re=this,xt=this.lastDiff&&this.lastDiff.diff;Se&&!Se.complete&&null!==(Ge=this.observableQuery)&&void 0!==Ge&&Ge.getLastError()||(this.updateLastDiff(Se),!this.dirty&&!(0,Mn.L)(xt&&xt.result,Se&&Se.result)&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return re.notify()},0))))},Ke.prototype.setObservableQuery=function(Se){var re=this;Se!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=Se,Se?(Se.queryInfo=this,this.listeners.add(this.oqListener=function(){re.getDiff().fromOptimisticTransaction?Se.observe():Jn(Se)})):delete this.oqListener)},Ke.prototype.notify=function(){var Se=this;Ro(this),this.shouldNotify()&&this.listeners.forEach(function(re){return re(Se)}),this.dirty=!1},Ke.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return!1;if(X(this.networkStatus)&&this.observableQuery){var Se=this.observableQuery.options.fetchPolicy;if("cache-only"!==Se&&"cache-and-network"!==Se)return!1}return!0},Ke.prototype.stop=function(){if(!this.stopped){this.stopped=!0,this.reset(),this.cancel(),this.cancel=Ke.prototype.cancel;var Se=this.observableQuery;Se&&Se.stopPolling()}},Ke.prototype.cancel=function(){},Ke.prototype.updateWatch=function(Se){var re=this;void 0===Se&&(Se=this.variables);var Ge=this.observableQuery;if(!Ge||"no-cache"!==Ge.options.fetchPolicy){var xt=(0,Q.Cl)((0,Q.Cl)({},this.getDiffOptions(Se)),{watcher:this,callback:function(Qt){return re.setDiff(Qt)}});(!this.lastWatch||!(0,Mn.L)(xt,this.lastWatch))&&(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=xt))}},Ke.prototype.resetLastWrite=function(){this.lastWrite=void 0},Ke.prototype.shouldWrite=function(Se,re){var Ge=this.lastWrite;return!(Ge&&Ge.dmCount===Bo.get(this.cache)&&(0,Mn.L)(re,Ge.variables)&&(0,Mn.L)(Se.data,Ge.result.data))},Ke.prototype.markResult=function(Se,re,Ge,xt){var Qt=this,kn=new An.ZI,bi=(0,ji.E)(Se.errors)?Se.errors.slice(0):[];if(this.reset(),"incremental"in Se&&(0,ji.E)(Se.incremental)){var vi=Cn(this.getDiff().result,Se);Se.data=vi}else if("hasNext"in Se&&Se.hasNext){var Ci=this.getDiff();Se.data=kn.merge(Ci.result,Se.data)}this.graphQLErrors=bi,"no-cache"===Ge.fetchPolicy?this.updateLastDiff({result:Se.data,complete:!0},this.getDiffOptions(Ge.variables)):0!==xt&&(ol(Se,Ge.errorPolicy)?this.cache.performTransaction(function(Xi){if(Qt.shouldWrite(Se,Ge.variables))Xi.writeQuery({query:re,data:Se.data,variables:Ge.variables,overwrite:1===xt}),Qt.lastWrite={result:Se,variables:Ge.variables,dmCount:Bo.get(Qt.cache)};else if(Qt.lastDiff&&Qt.lastDiff.diff.complete)return void(Se.data=Qt.lastDiff.diff.result);var $i=Qt.getDiffOptions(Ge.variables),Er=Xi.diff($i);!Qt.stopped&&(0,Mn.L)(Qt.variables,Ge.variables)&&Qt.updateWatch(Ge.variables),Qt.updateLastDiff(Er,$i),Er.complete&&(Se.data=Er.result)}):this.lastWrite=void 0)},Ke.prototype.markReady=function(){return this.networkError=null,this.networkStatus=M.ready},Ke.prototype.markError=function(Se){return this.networkStatus=M.error,this.lastWrite=void 0,this.reset(),Se.graphQLErrors&&(this.graphQLErrors=Se.graphQLErrors),Se.networkError&&(this.networkError=Se.networkError),Se},Ke}();function ol(Ke,Se){void 0===Se&&(Se="none");var re="ignore"===Se||"all"===Se,Ge=!Bi(Ke);return!Ge&&re&&Ke.data&&(Ge=!0),Ge}var Va=S(4420),Ao=S(2170),za=S(2151),vl=Object.prototype.hasOwnProperty,Na=Object.create(null),_l=function(){function Ke(Se){var re=this;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new Ao.A(za.v["queryManager.getDocumentInfo"]||2e3),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new Va.b(!1);var Ge=new qn.c(function(Qt){return re.cache.transformDocument(Qt)},{cache:!1});this.cache=Se.cache,this.link=Se.link,this.defaultOptions=Se.defaultOptions,this.queryDeduplication=Se.queryDeduplication,this.clientAwareness=Se.clientAwareness,this.localState=Se.localState,this.ssrMode=Se.ssrMode,this.assumeImmutableResults=Se.assumeImmutableResults;var xt=Se.documentTransform;this.documentTransform=xt?Ge.concat(xt).concat(Ge):Ge,this.defaultContext=Se.defaultContext||Object.create(null),(this.onBroadcast=Se.onBroadcast)&&(this.mutationStore=Object.create(null))}return Ke.prototype.stop=function(){var Se=this;this.queries.forEach(function(re,Ge){Se.stopQueryNoBroadcast(Ge)}),this.cancelPendingFetches((0,Ee.vA)(26))},Ke.prototype.cancelPendingFetches=function(Se){this.fetchCancelFns.forEach(function(re){return re(Se)}),this.fetchCancelFns.clear()},Ke.prototype.mutate=function(Se){return(0,Q.sH)(this,arguments,void 0,function(re){var Ge,xt,Qt,kn,bi,vi,Ci,Xi=re.mutation,$i=re.variables,Er=re.optimisticResponse,ai=re.updateQueries,so=re.refetchQueries,Fr=void 0===so?[]:so,zr=re.awaitRefetchQueries,ho=void 0!==zr&&zr,Vr=re.update,is=re.onQueryUpdated,Ms=re.fetchPolicy,Ds=void 0===Ms?(null===(vi=this.defaultOptions.mutate)||void 0===vi?void 0:vi.fetchPolicy)||"network-only":Ms,Xo=re.errorPolicy,na=void 0===Xo?(null===(Ci=this.defaultOptions.mutate)||void 0===Ci?void 0:Ci.errorPolicy)||"none":Xo,zs=re.keepRootFields,ya=re.context;return(0,Q.YH)(this,function(Je){switch(Je.label){case 0:return(0,Ee.V1)(Xi,27),(0,Ee.V1)("network-only"===Ds||"no-cache"===Ds,28),Ge=this.generateMutationId(),Xi=this.cache.transformForLink(this.transform(Xi)),xt=this.getDocumentInfo(Xi).hasClientExports,$i=this.getVariables(Xi,$i),xt?[4,this.localState.addExportedVariables(Xi,$i,ya)]:[3,2];case 1:$i=Je.sent(),Je.label=2;case 2:return Qt=this.mutationStore&&(this.mutationStore[Ge]={mutation:Xi,variables:$i,loading:!0,error:null}),kn=Er&&this.markMutationOptimistic(Er,{mutationId:Ge,document:Xi,variables:$i,fetchPolicy:Ds,errorPolicy:na,context:ya,updateQueries:ai,update:Vr,keepRootFields:zs}),this.broadcastQueries(),bi=this,[2,new Promise(function(at,Oe){return Ti(bi.getObservableFromLink(Xi,(0,Q.Cl)((0,Q.Cl)({},ya),{optimisticResponse:kn?Er:void 0}),$i,{},!1),function(Ct){if(Bi(Ct)&&"none"===na)throw new Wn({graphQLErrors:Gi(Ct)});Qt&&(Qt.loading=!1,Qt.error=null);var On=(0,Q.Cl)({},Ct);return"function"==typeof Fr&&(Fr=Fr(On)),"ignore"===na&&Bi(On)&&delete On.errors,bi.markMutationResult({mutationId:Ge,result:On,document:Xi,variables:$i,fetchPolicy:Ds,errorPolicy:na,context:ya,update:Vr,updateQueries:ai,awaitRefetchQueries:ho,refetchQueries:Fr,removeOptimistic:kn?Ge:void 0,onQueryUpdated:is,keepRootFields:zs})}).subscribe({next:function(Ct){bi.broadcastQueries(),(!("hasNext"in Ct)||!1===Ct.hasNext)&&at(Ct)},error:function(Ct){Qt&&(Qt.loading=!1,Qt.error=Ct),kn&&bi.cache.removeOptimistic(Ge),bi.broadcastQueries(),Oe(Ct instanceof Wn?Ct:new Wn({networkError:Ct}))}})})]}})})},Ke.prototype.markMutationResult=function(Se,re){var Ge=this;void 0===re&&(re=this.cache);var xt=Se.result,Qt=[],kn="no-cache"===Se.fetchPolicy;if(!kn&&ol(xt,Se.errorPolicy)){if(St(xt)||Qt.push({result:xt.data,dataId:"ROOT_MUTATION",query:Se.document,variables:Se.variables}),St(xt)&&(0,ji.E)(xt.incremental)){var bi=re.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(Se.document).asQuery,variables:Se.variables,optimistic:!1,returnPartialData:!0}),vi=void 0;bi.result&&(vi=Cn(bi.result,xt)),typeof vi<"u"&&(xt.data=vi,Qt.push({result:vi,dataId:"ROOT_MUTATION",query:Se.document,variables:Se.variables}))}var Ci=Se.updateQueries;Ci&&this.queries.forEach(function($i,Er){var ai=$i.observableQuery,so=ai&&ai.queryName;if(so&&vl.call(Ci,so)){var Fr=Ci[so],zr=Ge.queries.get(Er),ho=zr.document,Vr=zr.variables,is=re.diff({query:ho,variables:Vr,returnPartialData:!0,optimistic:!1}),Ms=is.result;if(is.complete&&Ms){var Xo=Fr(Ms,{mutationResult:xt,queryName:ho&&(0,ri.n4)(ho)||void 0,queryVariables:Vr});Xo&&Qt.push({result:Xo,dataId:"ROOT_QUERY",query:ho,variables:Vr})}}})}if(Qt.length>0||(Se.refetchQueries||"").length>0||Se.update||Se.onQueryUpdated||Se.removeOptimistic){var Xi=[];if(this.refetchQueries({updateCache:function($i){kn||Qt.forEach(function(Fr){return $i.write(Fr)});var Er=Se.update,ai=!function Ht(Ke){return St(Ke)||function qt(Ke){return"hasNext"in Ke&&"data"in Ke}(Ke)}(xt)||St(xt)&&!xt.hasNext;if(Er){if(!kn){var so=$i.diff({id:"ROOT_MUTATION",query:Ge.getDocumentInfo(Se.document).asQuery,variables:Se.variables,optimistic:!1,returnPartialData:!0});so.complete&&("incremental"in(xt=(0,Q.Cl)((0,Q.Cl)({},xt),{data:so.result}))&&delete xt.incremental,"hasNext"in xt&&delete xt.hasNext)}ai&&Er($i,xt,{context:Se.context,variables:Se.variables})}!kn&&!Se.keepRootFields&&ai&&$i.modify({id:"ROOT_MUTATION",fields:function(Fr,zr){return"__typename"===zr.fieldName?Fr:zr.DELETE}})},include:Se.refetchQueries,optimistic:!1,removeOptimistic:Se.removeOptimistic,onQueryUpdated:Se.onQueryUpdated||null}).forEach(function($i){return Xi.push($i)}),Se.awaitRefetchQueries||Se.onQueryUpdated)return Promise.all(Xi).then(function(){return xt})}return Promise.resolve(xt)},Ke.prototype.markMutationOptimistic=function(Se,re){var Ge=this,xt="function"==typeof Se?Se(re.variables,{IGNORE:Na}):Se;return xt!==Na&&(this.cache.recordOptimisticTransaction(function(Qt){try{Ge.markMutationResult((0,Q.Cl)((0,Q.Cl)({},re),{result:{data:xt}}),Qt)}catch(kn){!1!==globalThis.__DEV__&&Ee.V1.error(kn)}},re.mutationId),!0)},Ke.prototype.fetchQuery=function(Se,re,Ge){return this.fetchConcastWithInfo(Se,re,Ge).concast.promise},Ke.prototype.getQueryStore=function(){var Se=Object.create(null);return this.queries.forEach(function(re,Ge){Se[Ge]={variables:re.variables,networkStatus:re.networkStatus,networkError:re.networkError,graphQLErrors:re.graphQLErrors}}),Se},Ke.prototype.resetErrors=function(Se){var re=this.queries.get(Se);re&&(re.networkError=void 0,re.graphQLErrors=[])},Ke.prototype.transform=function(Se){return this.documentTransform.transformDocument(Se)},Ke.prototype.getDocumentInfo=function(Se){var re=this.transformCache;if(!re.has(Se)){var Ge={hasClientExports:(0,Z.f2)(Se),hasForcedResolvers:this.localState.shouldForceResolvers(Se),hasNonreactiveDirective:(0,Z.d8)(["nonreactive"],Se),clientQuery:this.localState.clientQuery(Se),serverQuery:(0,Gn.iz)([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"}],Se),defaultVars:(0,ri.wY)((0,ri.Vu)(Se)),asQuery:(0,Q.Cl)((0,Q.Cl)({},Se),{definitions:Se.definitions.map(function(xt){return"OperationDefinition"===xt.kind&&"query"!==xt.operation?(0,Q.Cl)((0,Q.Cl)({},xt),{operation:"query"}):xt})})};re.set(Se,Ge)}return re.get(Se)},Ke.prototype.getVariables=function(Se,re){return(0,Q.Cl)((0,Q.Cl)({},this.getDocumentInfo(Se).defaultVars),re)},Ke.prototype.watchQuery=function(Se){var re=this.transform(Se.query);typeof(Se=(0,Q.Cl)((0,Q.Cl)({},Se),{variables:this.getVariables(re,Se.variables)})).notifyOnNetworkStatusChange>"u"&&(Se.notifyOnNetworkStatusChange=!1);var Ge=new Ls(this),xt=new nn({queryManager:this,queryInfo:Ge,options:Se});return xt.lastQuery=re,this.queries.set(xt.queryId,Ge),Ge.init({document:re,observableQuery:xt,variables:xt.variables}),xt},Ke.prototype.query=function(Se,re){var Ge=this;return void 0===re&&(re=this.generateQueryId()),(0,Ee.V1)(Se.query,29),(0,Ee.V1)("Document"===Se.query.kind,30),(0,Ee.V1)(!Se.returnPartialData,31),(0,Ee.V1)(!Se.pollInterval,32),this.fetchQuery(re,(0,Q.Cl)((0,Q.Cl)({},Se),{query:this.transform(Se.query)})).finally(function(){return Ge.stopQuery(re)})},Ke.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},Ke.prototype.generateRequestId=function(){return this.requestIdCounter++},Ke.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},Ke.prototype.stopQueryInStore=function(Se){this.stopQueryInStoreNoBroadcast(Se),this.broadcastQueries()},Ke.prototype.stopQueryInStoreNoBroadcast=function(Se){var re=this.queries.get(Se);re&&re.stop()},Ke.prototype.clearStore=function(Se){return void 0===Se&&(Se={discardWatches:!0}),this.cancelPendingFetches((0,Ee.vA)(33)),this.queries.forEach(function(re){re.observableQuery?re.networkStatus=M.loading:re.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(Se)},Ke.prototype.getObservableQueries=function(Se){var re=this;void 0===Se&&(Se="active");var Ge=new Map,xt=new Map,Qt=new Set;return Array.isArray(Se)&&Se.forEach(function(kn){"string"==typeof kn?xt.set(kn,!1):(0,Ii.Kc)(kn)?xt.set(re.transform(kn),!1):(0,Mt.U)(kn)&&kn.query&&Qt.add(kn)}),this.queries.forEach(function(kn,bi){var vi=kn.observableQuery,Ci=kn.document;if(vi){if("all"===Se)return void Ge.set(bi,vi);var Xi=vi.queryName;if("standby"===vi.options.fetchPolicy||"active"===Se&&!vi.hasObservers())return;("active"===Se||Xi&&xt.has(Xi)||Ci&&xt.has(Ci))&&(Ge.set(bi,vi),Xi&&xt.set(Xi,!0),Ci&&xt.set(Ci,!0))}}),Qt.size&&Qt.forEach(function(kn){var bi=(0,Ki.v)("legacyOneTimeQuery"),vi=re.getQuery(bi).init({document:kn.query,variables:kn.variables}),Ci=new nn({queryManager:re,queryInfo:vi,options:(0,Q.Cl)((0,Q.Cl)({},kn),{fetchPolicy:"network-only"})});(0,Ee.V1)(Ci.queryId===bi),vi.setObservableQuery(Ci),Ge.set(bi,Ci)}),!1!==globalThis.__DEV__&&xt.size&&xt.forEach(function(kn,bi){kn||!1!==globalThis.__DEV__&&Ee.V1.warn("string"==typeof bi?34:35,bi)}),Ge},Ke.prototype.reFetchObservableQueries=function(Se){var re=this;void 0===Se&&(Se=!1);var Ge=[];return this.getObservableQueries(Se?"all":"active").forEach(function(xt,Qt){var kn=xt.options.fetchPolicy;xt.resetLastResults(),(Se||"standby"!==kn&&"cache-only"!==kn)&&Ge.push(xt.refetch()),re.getQuery(Qt).setDiff(null)}),this.broadcastQueries(),Promise.all(Ge)},Ke.prototype.setObservableQuery=function(Se){this.getQuery(Se.queryId).setObservableQuery(Se)},Ke.prototype.startGraphQLSubscription=function(Se){var re=this,Ge=Se.query,xt=Se.fetchPolicy,Qt=Se.errorPolicy,kn=void 0===Qt?"none":Qt,bi=Se.variables,vi=Se.context,Ci=void 0===vi?{}:vi,Xi=Se.extensions,$i=void 0===Xi?{}:Xi;Ge=this.transform(Ge),bi=this.getVariables(Ge,bi);var Er=function(so){return re.getObservableFromLink(Ge,Ci,so,$i).map(function(Fr){"no-cache"!==xt&&(ol(Fr,kn)&&re.cache.write({query:Ge,result:Fr.data,dataId:"ROOT_SUBSCRIPTION",variables:so}),re.broadcastQueries());var zr=Bi(Fr),ho=function It(Ke){return!!Ke.extensions&&Array.isArray(Ke.extensions[Wt])}(Fr);if(zr||ho){var Vr={};if(zr&&(Vr.graphQLErrors=Fr.errors),ho&&(Vr.protocolErrors=Fr.extensions[Wt]),"none"===kn||ho)throw new Wn(Vr)}return"ignore"===kn&&delete Fr.errors,Fr})};if(this.getDocumentInfo(Ge).hasClientExports){var ai=this.localState.addExportedVariables(Ge,bi,Ci).then(Er);return new ce.c(function(so){var Fr=null;return ai.then(function(zr){return Fr=zr.subscribe(so)},so.error),function(){return Fr&&Fr.unsubscribe()}})}return Er(bi)},Ke.prototype.stopQuery=function(Se){this.stopQueryNoBroadcast(Se),this.broadcastQueries()},Ke.prototype.stopQueryNoBroadcast=function(Se){this.stopQueryInStoreNoBroadcast(Se),this.removeQuery(Se)},Ke.prototype.removeQuery=function(Se){this.fetchCancelFns.delete(Se),this.queries.has(Se)&&(this.getQuery(Se).stop(),this.queries.delete(Se))},Ke.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(Se){return Se.notify()})},Ke.prototype.getLocalState=function(){return this.localState},Ke.prototype.getObservableFromLink=function(Se,re,Ge,xt,Qt){var bi,kn=this;void 0===Qt&&(Qt=null!==(bi=re?.queryDeduplication)&&void 0!==bi?bi:this.queryDeduplication);var vi,Ci=this.getDocumentInfo(Se),Xi=Ci.serverQuery,$i=Ci.clientQuery;if(Xi){var ai=this.inFlightLinkObservables,so=this.link,Fr={query:Xi,variables:Ge,operationName:(0,ri.n4)(Xi)||void 0,context:this.prepareContext((0,Q.Cl)((0,Q.Cl)({},re),{forceFetch:!Qt})),extensions:xt};if(re=Fr.context,Qt){var zr=(0,cr.y)(Xi),ho=(0,ni.M)(Ge),Vr=ai.lookup(zr,ho);if(!(vi=Vr.observable)){var is=new it([q(so,Fr)]);vi=Vr.observable=is,is.beforeNext(function(){ai.remove(zr,ho)})}}else vi=new it([q(so,Fr)])}else vi=new it([ce.c.of({data:{}})]),re=this.prepareContext(re);return $i&&(vi=Ti(vi,function(Ms){return kn.localState.runResolvers({document:$i,remoteResult:Ms,context:re,variables:Ge})})),vi},Ke.prototype.getResultsFromLink=function(Se,re,Ge){var xt=Se.lastRequestId=this.generateRequestId(),Qt=this.cache.transformForLink(Ge.query);return Ti(this.getObservableFromLink(Qt,Ge.context,Ge.variables),function(kn){var bi=Gi(kn),vi=bi.length>0,Ci=Ge.errorPolicy;if(xt>=Se.lastRequestId){if(vi&&"none"===Ci)throw Se.markError(new Wn({graphQLErrors:bi}));Se.markResult(kn,Qt,Ge,re),Se.markReady()}var Xi={data:kn.data,loading:!1,networkStatus:M.ready};return vi&&"none"===Ci&&(Xi.data=void 0),vi&&"ignore"!==Ci&&(Xi.errors=bi,Xi.networkStatus=M.error),Xi},function(kn){var bi=Vn(kn)?kn:new Wn({networkError:kn});throw xt>=Se.lastRequestId&&Se.markError(bi),bi})},Ke.prototype.fetchConcastWithInfo=function(Se,re,Ge,xt){var Qt=this;void 0===Ge&&(Ge=M.loading),void 0===xt&&(xt=re.query);var Xo,na,kn=this.getVariables(xt,re.variables),bi=this.getQuery(Se),vi=this.defaultOptions.watchQuery,Ci=re.fetchPolicy,$i=re.errorPolicy,ai=re.returnPartialData,Fr=re.notifyOnNetworkStatusChange,ho=re.context,is=Object.assign({},re,{query:xt,variables:kn,fetchPolicy:void 0===Ci?vi&&vi.fetchPolicy||"cache-first":Ci,errorPolicy:void 0===$i?vi&&vi.errorPolicy||"none":$i,returnPartialData:void 0!==ai&&ai,notifyOnNetworkStatusChange:void 0!==Fr&&Fr,context:void 0===ho?{}:ho}),Ms=function(ya){is.variables=ya;var Je=Qt.fetchQueryByPolicy(bi,is,Ge);return"standby"!==is.fetchPolicy&&Je.sources.length>0&&bi.observableQuery&&bi.observableQuery.applyNextFetchPolicy("after-fetch",re),Je},Ds=function(){return Qt.fetchCancelFns.delete(Se)};if(this.fetchCancelFns.set(Se,function(ya){Ds(),setTimeout(function(){return Xo.cancel(ya)})}),this.getDocumentInfo(is.query).hasClientExports)Xo=new it(this.localState.addExportedVariables(is.query,is.variables,is.context).then(Ms).then(function(ya){return ya.sources})),na=!0;else{var zs=Ms(is.variables);na=zs.fromLink,Xo=new it(zs.sources)}return Xo.promise.then(Ds,Ds),{concast:Xo,fromLink:na}},Ke.prototype.refetchQueries=function(Se){var re=this,Ge=Se.updateCache,xt=Se.include,Qt=Se.optimistic,kn=void 0!==Qt&&Qt,bi=Se.removeOptimistic,vi=void 0===bi?kn?(0,Ki.v)("refetchQueries"):void 0:bi,Ci=Se.onQueryUpdated,Xi=new Map;xt&&this.getObservableQueries(xt).forEach(function(Er,ai){Xi.set(ai,{oq:Er,lastDiff:re.getQuery(ai).getDiff()})});var $i=new Map;return Ge&&this.cache.batch({update:Ge,optimistic:kn&&vi||!1,removeOptimistic:vi,onWatchUpdated:function(Er,ai,so){var Fr=Er.watcher instanceof Ls&&Er.watcher.observableQuery;if(Fr){if(Ci){Xi.delete(Fr.queryId);var zr=Ci(Fr,ai,so);return!0===zr&&(zr=Fr.refetch()),!1!==zr&&$i.set(Fr,zr),zr}null!==Ci&&Xi.set(Fr.queryId,{oq:Fr,lastDiff:so,diff:ai})}}}),Xi.size&&Xi.forEach(function(Er,ai){var ho,so=Er.oq,Fr=Er.lastDiff,zr=Er.diff;if(Ci){if(!zr){var Vr=so.queryInfo;Vr.reset(),zr=Vr.getDiff()}ho=Ci(so,zr,Fr)}(!Ci||!0===ho)&&(ho=so.refetch()),!1!==ho&&$i.set(so,ho),ai.indexOf("legacyOneTimeQuery")>=0&&re.stopQueryNoBroadcast(ai)}),vi&&this.cache.removeOptimistic(vi),$i},Ke.prototype.fetchQueryByPolicy=function(Se,re,Ge){var xt=this,Qt=re.query,kn=re.variables,bi=re.fetchPolicy,vi=re.refetchWritePolicy,Ci=re.errorPolicy,Xi=re.returnPartialData,$i=re.context,Er=re.notifyOnNetworkStatusChange,ai=Se.networkStatus;Se.init({document:Qt,variables:kn,networkStatus:Ge});var so=function(){return Se.getDiff()},Fr=function(Ms,Ds){void 0===Ds&&(Ds=Se.networkStatus||M.loading);var Xo=Ms.result;!1!==globalThis.__DEV__&&!Xi&&!(0,Mn.L)(Xo,{})&&_r(Ms.missing);var na=function(zs){return ce.c.of((0,Q.Cl)({data:zs,loading:X(Ds),networkStatus:Ds},Ms.complete?null:{partial:!0}))};return Xo&&xt.getDocumentInfo(Qt).hasForcedResolvers?xt.localState.runResolvers({document:Qt,remoteResult:{data:Xo},context:$i,variables:kn,onlyRunForcedResolvers:!0}).then(function(zs){return na(zs.data||void 0)}):"none"===Ci&&Ds===M.refetch&&Array.isArray(Ms.missing)?na(void 0):na(Xo)},zr="no-cache"===bi?0:Ge===M.refetch&&"merge"!==vi?1:2,ho=function(){return xt.getResultsFromLink(Se,zr,{query:Qt,variables:kn,context:$i,fetchPolicy:bi,errorPolicy:Ci})},Vr=Er&&"number"==typeof ai&&ai!==Ge&&X(Ge);switch(bi){default:case"cache-first":return(is=so()).complete?{fromLink:!1,sources:[Fr(is,Se.markReady())]}:Xi||Vr?{fromLink:!0,sources:[Fr(is),ho()]}:{fromLink:!0,sources:[ho()]};case"cache-and-network":var is;return(is=so()).complete||Xi||Vr?{fromLink:!0,sources:[Fr(is),ho()]}:{fromLink:!0,sources:[ho()]};case"cache-only":return{fromLink:!1,sources:[Fr(so(),Se.markReady())]};case"network-only":return Vr?{fromLink:!0,sources:[Fr(so()),ho()]}:{fromLink:!0,sources:[ho()]};case"no-cache":return Vr?{fromLink:!0,sources:[Fr(Se.getDiff()),ho()]}:{fromLink:!0,sources:[ho()]};case"standby":return{fromLink:!1,sources:[]}}},Ke.prototype.getQuery=function(Se){return Se&&!this.queries.has(Se)&&this.queries.set(Se,new Ls(this,Se)),this.queries.get(Se)},Ke.prototype.prepareContext=function(Se){void 0===Se&&(Se={});var re=this.localState.prepareContext(Se);return(0,Q.Cl)((0,Q.Cl)((0,Q.Cl)({},this.defaultContext),re),{clientAwareness:this.clientAwareness})},Ke}(),gs=S(6108),Zs=S(4141),oa=function(){function Ke(Se){var re=Se.cache,Ge=Se.client,xt=Se.resolvers,Qt=Se.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=re,Ge&&(this.client=Ge),xt&&this.addResolvers(xt),Qt&&this.setFragmentMatcher(Qt)}return Ke.prototype.addResolvers=function(Se){var re=this;this.resolvers=this.resolvers||{},Array.isArray(Se)?Se.forEach(function(Ge){re.resolvers=(0,An.D9)(re.resolvers,Ge)}):this.resolvers=(0,An.D9)(this.resolvers,Se)},Ke.prototype.setResolvers=function(Se){this.resolvers={},this.addResolvers(Se)},Ke.prototype.getResolvers=function(){return this.resolvers||{}},Ke.prototype.runResolvers=function(Se){return(0,Q.sH)(this,arguments,void 0,function(re){var Ge=re.document,xt=re.remoteResult,Qt=re.context,kn=re.variables,bi=re.onlyRunForcedResolvers,vi=void 0!==bi&&bi;return(0,Q.YH)(this,function(Ci){return Ge?[2,this.resolveDocument(Ge,xt.data,Qt,kn,this.fragmentMatcher,vi).then(function(Xi){return(0,Q.Cl)((0,Q.Cl)({},xt),{data:Xi.result})})]:[2,xt]})})},Ke.prototype.setFragmentMatcher=function(Se){this.fragmentMatcher=Se},Ke.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},Ke.prototype.clientQuery=function(Se){return(0,Z.d8)(["client"],Se)&&this.resolvers?Se:null},Ke.prototype.serverQuery=function(Se){return(0,Gn.er)(Se)},Ke.prototype.prepareContext=function(Se){var re=this.cache;return(0,Q.Cl)((0,Q.Cl)({},Se),{cache:re,getCacheKey:function(Ge){return re.identify(Ge)}})},Ke.prototype.addExportedVariables=function(Se){return(0,Q.sH)(this,arguments,void 0,function(re,Ge,xt){return void 0===Ge&&(Ge={}),void 0===xt&&(xt={}),(0,Q.YH)(this,function(Qt){return re?[2,this.resolveDocument(re,this.buildRootValueFromCache(re,Ge)||{},this.prepareContext(xt),Ge).then(function(kn){return(0,Q.Cl)((0,Q.Cl)({},Ge),kn.exportedVariables)})]:[2,(0,Q.Cl)({},Ge)]})})},Ke.prototype.shouldForceResolvers=function(Se){var re=!1;return(0,hn.visit)(Se,{Directive:{enter:function(Ge){if("client"===Ge.name.value&&Ge.arguments&&(re=Ge.arguments.some(function(xt){return"always"===xt.name.value&&"BooleanValue"===xt.value.kind&&!0===xt.value.value})))return hn.BREAK}}}),re},Ke.prototype.buildRootValueFromCache=function(Se,re){return this.cache.diff({query:(0,Gn.zc)(Se),variables:re,returnPartialData:!0,optimistic:!1}).result},Ke.prototype.resolveDocument=function(Se,re){return(0,Q.sH)(this,arguments,void 0,function(Ge,xt,Qt,kn,bi,vi){var Ci,Xi,$i,Er,ai,so,Fr,zr,ho,Vr;return void 0===Qt&&(Qt={}),void 0===kn&&(kn={}),void 0===bi&&(bi=function(){return!0}),void 0===vi&&(vi=!1),(0,Q.YH)(this,function(Ms){return Ci=(0,ri.Vn)(Ge),Xi=(0,ri.zK)(Ge),$i=(0,gs.JG)(Xi),Er=this.collectSelectionsToResolve(Ci,$i),so=(ai=Ci.operation)?ai.charAt(0).toUpperCase()+ai.slice(1):"Query",zr=(Fr=this).cache,ho=Fr.client,Vr={fragmentMap:$i,context:(0,Q.Cl)((0,Q.Cl)({},Qt),{cache:zr,client:ho}),variables:kn,fragmentMatcher:bi,defaultOperationType:so,exportedVariables:{},selectionsToResolve:Er,onlyRunForcedResolvers:vi},[2,this.resolveSelectionSet(Ci.selectionSet,!1,xt,Vr).then(function(Ds){return{result:Ds,exportedVariables:Vr.exportedVariables}})]})})},Ke.prototype.resolveSelectionSet=function(Se,re,Ge,xt){return(0,Q.sH)(this,void 0,void 0,function(){var Qt,kn,bi,vi,Xi=this;return(0,Q.YH)(this,function($i){return Qt=xt.fragmentMap,kn=xt.context,bi=xt.variables,vi=[Ge],[2,Promise.all(Se.selections.map(function(Er){return(0,Q.sH)(Xi,void 0,void 0,function(){var ai;return(0,Q.YH)(this,function(Fr){return(re||xt.selectionsToResolve.has(Er))&&(0,Z.MS)(Er,bi)?(0,Ii.dt)(Er)?[2,this.resolveField(Er,re,Ge,xt).then(function(zr){var ho;typeof zr<"u"&&vi.push(((ho={})[(0,Ii.ue)(Er)]=zr,ho))})]:((0,Ii.kd)(Er)?ai=Er:(0,Ee.V1)(ai=Qt[Er.name.value],18,Er.name.value),ai&&ai.typeCondition&&xt.fragmentMatcher(Ge,ai.typeCondition.name.value,kn)?[2,this.resolveSelectionSet(ai.selectionSet,re,Ge,xt).then(function(zr){vi.push(zr)})]:[2]):[2]})})})).then(function(){return(0,An.IM)(vi)})]})})},Ke.prototype.resolveField=function(Se,re,Ge,xt){return(0,Q.sH)(this,void 0,void 0,function(){var Qt,kn,bi,vi,Ci,Xi,$i,Er,ai,so=this;return(0,Q.YH)(this,function(Fr){return Ge?(Qt=xt.variables,kn=Se.name.value,bi=(0,Ii.ue)(Se),vi=kn!==bi,Ci=Ge[bi]||Ge[kn],Xi=Promise.resolve(Ci),(!xt.onlyRunForcedResolvers||this.shouldForceResolvers(Se))&&($i=Ge.__typename||xt.defaultOperationType,(Er=this.resolvers&&this.resolvers[$i])&&(ai=Er[vi?kn:bi])&&(Xi=Promise.resolve(Zs.bl.withValue(this.cache,ai,[Ge,(0,Ii.MB)(Se,Qt),xt.context,{field:Se,fragmentMap:xt.fragmentMap}])))),[2,Xi.then(function(zr){var ho,Vr;if(void 0===zr&&(zr=Ci),Se.directives&&Se.directives.forEach(function(Ms){"export"===Ms.name.value&&Ms.arguments&&Ms.arguments.forEach(function(Ds){"as"===Ds.name.value&&"StringValue"===Ds.value.kind&&(xt.exportedVariables[Ds.value.value]=zr)})}),!Se.selectionSet||null==zr)return zr;var is=null!==(Vr=null===(ho=Se.directives)||void 0===ho?void 0:ho.some(function(Ms){return"client"===Ms.name.value}))&&void 0!==Vr&&Vr;return Array.isArray(zr)?so.resolveSubSelectedArray(Se,re||is,zr,xt):Se.selectionSet?so.resolveSelectionSet(Se.selectionSet,re||is,zr,xt):void 0})]):[2,null]})})},Ke.prototype.resolveSubSelectedArray=function(Se,re,Ge,xt){var Qt=this;return Promise.all(Ge.map(function(kn){return null===kn?null:Array.isArray(kn)?Qt.resolveSubSelectedArray(Se,re,kn,xt):Se.selectionSet?Qt.resolveSelectionSet(Se.selectionSet,re,kn,xt):void 0}))},Ke.prototype.collectSelectionsToResolve=function(Se,re){var Ge=function(kn){return!Array.isArray(kn)},xt=this.selectionsToResolveCache;return function Qt(kn){if(!xt.has(kn)){var bi=new Set;xt.set(kn,bi),(0,hn.visit)(kn,{Directive:function(vi,Ci,Xi,$i,Er){"client"===vi.name.value&&Er.forEach(function(ai){Ge(ai)&&(0,hn.isSelectionNode)(ai)&&bi.add(ai)})},FragmentSpread:function(vi,Ci,Xi,$i,Er){var ai=re[vi.name.value];(0,Ee.V1)(ai,19,vi.name.value);var so=Qt(ai);so.size>0&&(Er.forEach(function(Fr){Ge(Fr)&&(0,hn.isSelectionNode)(Fr)&&bi.add(Fr)}),bi.add(vi),so.forEach(function(Fr){bi.add(Fr)}))}})}return xt.get(kn)}(Se)},Ke}();function no(Ke,Se){return(0,sn.o)(Ke,Se,Se.variables&&{variables:(0,sn.o)((0,Q.Cl)((0,Q.Cl)({},Ke&&Ke.variables),Se.variables))})}var xl=S(8782),Qr=!1,dl=function(){function Ke(Se){var re=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!Se.cache)throw(0,Ee.vA)(15);var Ge=Se.uri,kn=Se.cache,bi=Se.documentTransform,vi=Se.ssrMode,Ci=void 0!==vi&&vi,Xi=Se.ssrForceFetchDelay,$i=void 0===Xi?0:Xi,Er=Se.connectToDevTools,ai=Se.queryDeduplication,so=void 0===ai||ai,Fr=Se.defaultOptions,zr=Se.defaultContext,ho=Se.assumeImmutableResults,Vr=void 0===ho?kn.assumeImmutableResults:ho,is=Se.resolvers,Ms=Se.typeDefs,Ds=Se.fragmentMatcher,Xo=Se.name,na=Se.version,zs=Se.devtools,ya=Se.link;ya||(ya=Ge?new Bn({uri:Ge,credentials:Se.credentials,headers:Se.headers}):he.C.empty()),this.link=ya,this.cache=kn,this.disableNetworkFetches=Ci||$i>0,this.queryDeduplication=so,this.defaultOptions=Fr||Object.create(null),this.typeDefs=Ms,this.devtoolsConfig=(0,Q.Cl)((0,Q.Cl)({},zs),{enabled:zs?.enabled||Er}),void 0===this.devtoolsConfig.enabled&&(this.devtoolsConfig.enabled=!1!==globalThis.__DEV__),$i&&setTimeout(function(){return re.disableNetworkFetches=!1},$i),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.watchFragment=this.watchFragment.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version=oe.r,this.localState=new oa({cache:kn,client:this,resolvers:is,fragmentMatcher:Ds}),this.queryManager=new _l({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,defaultContext:zr,documentTransform:bi,queryDeduplication:so,ssrMode:Ci,clientAwareness:{name:Xo,version:na},localState:this.localState,assumeImmutableResults:Vr,onBroadcast:this.devtoolsConfig.enabled?function(){re.devToolsHookCb&&re.devToolsHookCb({action:{},state:{queries:re.queryManager.getQueryStore(),mutations:re.queryManager.mutationStore||{}},dataWithOptimisticResults:re.cache.extract(!0)})}:void 0}),this.devtoolsConfig.enabled&&this.connectToDevTools()}return Ke.prototype.connectToDevTools=function(){if(!(typeof window>"u")){var Se=window,re=Symbol.for("apollo.devtools");(Se[re]=Se[re]||[]).push(this),Se.__APOLLO_CLIENT__=this,!Qr&&!1!==globalThis.__DEV__&&(Qr=!0,window.document&&window.top===window.self&&/^(https?|file):$/.test(window.location.protocol)&&setTimeout(function(){if(!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var Ge=window.navigator,xt=Ge&&Ge.userAgent,Qt=void 0;"string"==typeof xt&&(xt.indexOf("Chrome/")>-1?Qt="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":xt.indexOf("Firefox/")>-1&&(Qt="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),Qt&&!1!==globalThis.__DEV__&&Ee.V1.log("Download the Apollo DevTools for a better development experience: %s",Qt)}},1e4))}},Object.defineProperty(Ke.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform},enumerable:!1,configurable:!0}),Ke.prototype.stop=function(){this.queryManager.stop()},Ke.prototype.watchQuery=function(Se){return this.defaultOptions.watchQuery&&(Se=no(this.defaultOptions.watchQuery,Se)),this.disableNetworkFetches&&("network-only"===Se.fetchPolicy||"cache-and-network"===Se.fetchPolicy)&&(Se=(0,Q.Cl)((0,Q.Cl)({},Se),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(Se)},Ke.prototype.query=function(Se){return this.defaultOptions.query&&(Se=no(this.defaultOptions.query,Se)),(0,Ee.V1)("cache-and-network"!==Se.fetchPolicy,16),this.disableNetworkFetches&&"network-only"===Se.fetchPolicy&&(Se=(0,Q.Cl)((0,Q.Cl)({},Se),{fetchPolicy:"cache-first"})),this.queryManager.query(Se)},Ke.prototype.mutate=function(Se){return this.defaultOptions.mutate&&(Se=no(this.defaultOptions.mutate,Se)),this.queryManager.mutate(Se)},Ke.prototype.subscribe=function(Se){return this.queryManager.startGraphQLSubscription(Se)},Ke.prototype.readQuery=function(Se,re){return void 0===re&&(re=!1),this.cache.readQuery(Se,re)},Ke.prototype.watchFragment=function(Se){return this.cache.watchFragment(Se)},Ke.prototype.readFragment=function(Se,re){return void 0===re&&(re=!1),this.cache.readFragment(Se,re)},Ke.prototype.writeQuery=function(Se){var re=this.cache.writeQuery(Se);return!1!==Se.broadcast&&this.queryManager.broadcastQueries(),re},Ke.prototype.writeFragment=function(Se){var re=this.cache.writeFragment(Se);return!1!==Se.broadcast&&this.queryManager.broadcastQueries(),re},Ke.prototype.__actionHookForDevTools=function(Se){this.devToolsHookCb=Se},Ke.prototype.__requestRaw=function(Se){return q(this.link,Se)},Ke.prototype.resetStore=function(){var Se=this;return Promise.resolve().then(function(){return Se.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(Se.resetStoreCallbacks.map(function(re){return re()}))}).then(function(){return Se.reFetchObservableQueries()})},Ke.prototype.clearStore=function(){var Se=this;return Promise.resolve().then(function(){return Se.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(Se.clearStoreCallbacks.map(function(re){return re()}))})},Ke.prototype.onResetStore=function(Se){var re=this;return this.resetStoreCallbacks.push(Se),function(){re.resetStoreCallbacks=re.resetStoreCallbacks.filter(function(Ge){return Ge!==Se})}},Ke.prototype.onClearStore=function(Se){var re=this;return this.clearStoreCallbacks.push(Se),function(){re.clearStoreCallbacks=re.clearStoreCallbacks.filter(function(Ge){return Ge!==Se})}},Ke.prototype.reFetchObservableQueries=function(Se){return this.queryManager.reFetchObservableQueries(Se)},Ke.prototype.refetchQueries=function(Se){var re=this.queryManager.refetchQueries(Se),Ge=[],xt=[];re.forEach(function(kn,bi){Ge.push(bi),xt.push(kn)});var Qt=Promise.all(xt);return Qt.queries=Ge,Qt.results=xt,Qt.catch(function(kn){!1!==globalThis.__DEV__&&Ee.V1.debug(17,kn)}),Qt},Ke.prototype.getObservableQueries=function(Se){return void 0===Se&&(Se="active"),this.queryManager.getObservableQueries(Se)},Ke.prototype.extract=function(Se){return this.cache.extract(Se)},Ke.prototype.restore=function(Se){return this.cache.restore(Se)},Ke.prototype.addResolvers=function(Se){this.localState.addResolvers(Se)},Ke.prototype.setResolvers=function(Se){this.localState.setResolvers(Se)},Ke.prototype.getResolvers=function(){return this.localState.getResolvers()},Ke.prototype.setLocalStateFragmentMatcher=function(Se){this.localState.setFragmentMatcher(Se)},Ke.prototype.setLink=function(Se){this.link=this.queryManager.link=Se},Object.defineProperty(Ke.prototype,"defaultContext",{get:function(){return this.queryManager.defaultContext},enumerable:!1,configurable:!0}),Ke}();!1!==globalThis.__DEV__&&(dl.prototype.getMemoryInternals=xl.ep);var ko=function(){return ko=Object.assign||function(Se){for(var re,Ge=1,xt=arguments.length;Ge<xt;Ge++)for(var Qt in re=arguments[Ge])Object.prototype.hasOwnProperty.call(re,Qt)&&(Se[Qt]=re[Qt]);return Se},ko.apply(this,arguments)};"function"==typeof SuppressedError&&SuppressedError;var ga=new Map,sl=new Map,fl=!0,Ia=!1;function al(Ke){return Ke.replace(/[\s,]+/g," ").trim()}function qc(Ke){var Se=al(Ke);if(!ga.has(Se)){var re=(0,hn.parse)(Ke,{experimentalFragmentVariables:Ia,allowLegacyFragmentVariables:Ia});if(!re||"Document"!==re.kind)throw new Error("Not a valid GraphQL document.");ga.set(Se,function Sl(Ke){var Se=new Set(Ke.definitions);Se.forEach(function(Ge){Ge.loc&&delete Ge.loc,Object.keys(Ge).forEach(function(xt){var Qt=Ge[xt];Qt&&"object"==typeof Qt&&Se.add(Qt)})});var re=Ke.loc;return re&&(delete re.startToken,delete re.endToken),Ke}(function wa(Ke){var Se=new Set,re=[];return Ke.definitions.forEach(function(Ge){if("FragmentDefinition"===Ge.kind){var xt=Ge.name.value,Qt=function Kc(Ke){return al(Ke.source.body.substring(Ke.start,Ke.end))}(Ge.loc),kn=sl.get(xt);kn&&!kn.has(Qt)?fl&&console.warn("Warning: fragment with name "+xt+" already exists.\ngraphql-tag enforces all fragment names across your application to be unique; read more about\nthis in the docs: http://dev.apollodata.com/core/fragments.html#unique-names"):kn||sl.set(xt,kn=new Set),kn.add(Qt),Se.has(Qt)||(Se.add(Qt),re.push(Ge))}else re.push(Ge)}),ko(ko({},Ke),{definitions:re})}(re)))}return ga.get(Se)}function la(Ke){for(var Se=[],re=1;re<arguments.length;re++)Se[re-1]=arguments[re];"string"==typeof Ke&&(Ke=[Ke]);var Ge=Ke[0];return Se.forEach(function(xt,Qt){Ge+=xt&&"Document"===xt.kind?xt.loc.source.body:xt,Ge+=Ke[Qt+1]}),qc(Ge)}var Ke,ql_gql=la;(Ke=la||(la={})).gql=ql_gql,Ke.resetCaches=function pl(){ga.clear(),sl.clear()},Ke.disableFragmentWarnings=function Sc(){fl=!1},Ke.enableExperimentalFragmentVariables=function Ec(){Ia=!0},Ke.disableExperimentalFragmentVariables=function Qc(){Ia=!1},la.default=la;var Yc=S(9335);function ca(Ke){return new e.Observable(Se=>(Ke().then(re=>{Se.closed||(Se.next(re),Se.complete())},re=>{Se.closed||Se.error(re)}),()=>Se.unsubscribe()))}class Xa{zone;constructor(Se){this.zone=Se}now=Date.now?Date.now:()=>+new Date;schedule(Se,re=0,Ge){return this.zone.run(()=>e.queueScheduler.schedule(Se,re,Ge))}}function Rl(Ke){return Ke[e.observable]=()=>Ke,Ke}function yl(Ke,Se){return Ke.pipe((0,Yc.observeOn)(new Xa(Se)))}class Lu{obsQuery;valueChanges;queryId;constructor(Se,re,Ge){this.obsQuery=Se;const xt=yl((0,e.from)(Rl(this.obsQuery)),re);this.valueChanges=Ge.useInitialLoading?xt.pipe(function sa(Ke){return function(re){return new e.Observable(function(xt){const Qt=Ke.getCurrentResult(),{loading:kn,errors:bi,error:vi,partial:Ci,data:Xi}=Qt,{partialRefetch:$i,fetchPolicy:Er}=Ke.options,ai=bi||vi;return $i&&Ci&&(!Xi||0===Object.keys(Xi).length)&&"cache-only"!==Er&&!kn&&!ai&&xt.next({...Qt,loading:!0,networkStatus:M.loading}),re.subscribe(xt)})}}(this.obsQuery)):xt,this.queryId=this.obsQuery.queryId}get options(){return this.obsQuery.options}get variables(){return this.obsQuery.variables}result(){return this.obsQuery.result()}getCurrentResult(){return this.obsQuery.getCurrentResult()}getLastResult(){return this.obsQuery.getLastResult()}getLastError(){return this.obsQuery.getLastError()}resetLastResults(){return this.obsQuery.resetLastResults()}refetch(Se){return this.obsQuery.refetch(Se)}fetchMore(Se){return this.obsQuery.fetchMore(Se)}subscribeToMore(Se){return this.obsQuery.subscribeToMore(Se)}updateQuery(Se){return this.obsQuery.updateQuery(Se)}stopPolling(){return this.obsQuery.stopPolling()}startPolling(Se){return this.obsQuery.startPolling(Se)}setOptions(Se){return this.obsQuery.setOptions(Se)}setVariables(Se){return this.obsQuery.setVariables(Se)}}const Aa=new i.InjectionToken("APOLLO_FLAGS"),ku=new i.InjectionToken("APOLLO_OPTIONS"),Ql=new i.InjectionToken("APOLLO_NAMED_OPTIONS");class sc{ngZone;flags;_client;useInitialLoading;useMutationLoading;constructor(Se,re,Ge){this.ngZone=Se,this.flags=re,this._client=Ge,this.useInitialLoading=re?.useInitialLoading??!1,this.useMutationLoading=re?.useMutationLoading??!1}watchQuery(Se){return new Lu(this.ensureClient().watchQuery({...Se}),this.ngZone,{useInitialLoading:this.useInitialLoading,...Se})}query(Se){return ca(()=>this.ensureClient().query({...Se}))}mutate(Se){return function Il(Ke,Se){return Se?Ke.pipe((0,Yc.startWith)({loading:!0}),(0,Yc.map)(re=>({...re,loading:!!re.loading}))):Ke.pipe((0,Yc.map)(re=>({...re,loading:!1})))}(ca(()=>this.ensureClient().mutate({...Se})),Se.useMutationLoading??this.useMutationLoading)}watchFragment(Se,re){const Ge=(0,e.from)(Rl(this.ensureClient().watchFragment({...Se})));return re&&!0!==re.useZone?Ge:yl(Ge,this.ngZone)}subscribe(Se,re){const Ge=(0,e.from)(Rl(this.ensureClient().subscribe({...Se})));return re&&!0!==re.useZone?Ge:yl(Ge,this.ngZone)}get client(){return this.ensureClient()}set client(Se){if(this._client)throw new Error("Client has been already defined");this._client=Se}ensureClient(){return this.checkInstance(),this._client}checkInstance(){if(this._client)return!0;throw new Error("Client has not been defined yet")}}let ta=(()=>{class Ke extends sc{map=new Map;constructor(re,Ge,xt,Qt){if(super(re,Qt),Ge&&this.createDefault(Ge),xt&&"object"==typeof xt)for(let kn in xt)xt.hasOwnProperty(kn)&&this.create(xt[kn],kn)}create(re,Ge){vc(Ge)?this.createNamed(Ge,re):this.createDefault(re)}default(){return this}use(re){return vc(re)?this.map.get(re):this.default()}createDefault(re){if(this._client)throw new Error("Apollo has been already created.");this.client=this.ngZone.runOutsideAngular(()=>new dl(re))}createNamed(re,Ge){if(this.map.has(re))throw new Error(`Client ${re} has been already created`);this.map.set(re,new sc(this.ngZone,this.flags,this.ngZone.runOutsideAngular(()=>new dl(Ge))))}removeClient(re){vc(re)?this.map.delete(re):this._client=void 0}static \u0275fac=function(Ge){return new(Ge||Ke)(i.\u0275\u0275inject(i.NgZone),i.\u0275\u0275inject(ku,8),i.\u0275\u0275inject(Ql,8),i.\u0275\u0275inject(Aa,8))};static \u0275prov=i.\u0275\u0275defineInjectable({token:Ke,factory:Ke.\u0275fac})}return Ke})();function vc(Ke){return!!Ke&&"default"!==Ke}let xu=(()=>{class Ke{static \u0275fac=function(Ge){return new(Ge||Ke)};static \u0275mod=i.\u0275\u0275defineNgModule({type:Ke});static \u0275inj=i.\u0275\u0275defineInjector({providers:[ta]})}return Ke})();function Fc(Ke,Se={}){return[ta,{provide:ku,useFactory:Ke},{provide:Aa,useValue:Se}]}function po(Ke,Se={}){return[ta,{provide:Ql,useFactory:Ke},{provide:Aa,useValue:Se}]}let Ll=(()=>{class Ke{apollo;client="default";constructor(re){this.apollo=re}watch(re,Ge){return this.apollo.use(this.client).watchQuery({...Ge,variables:re,query:this.document})}fetch(re,Ge){return this.apollo.use(this.client).query({...Ge,variables:re,query:this.document})}static \u0275fac=function(Ge){return new(Ge||Ke)(i.\u0275\u0275inject(ta))};static \u0275prov=i.\u0275\u0275defineInjectable({token:Ke,factory:Ke.\u0275fac})}return Ke})(),Hs=(()=>{class Ke{apollo;client="default";constructor(re){this.apollo=re}mutate(re,Ge){return this.apollo.use(this.client).mutate({...Ge,variables:re,mutation:this.document})}static \u0275fac=function(Ge){return new(Ge||Ke)(i.\u0275\u0275inject(ta))};static \u0275prov=i.\u0275\u0275defineInjectable({token:Ke,factory:Ke.\u0275fac})}return Ke})(),kl=(()=>{class Ke{apollo;client="default";constructor(re){this.apollo=re}subscribe(re,Ge,xt){return this.apollo.use(this.client).subscribe({...Ge,variables:re,query:this.document},xt)}static \u0275fac=function(Ge){return new(Ge||Ke)(i.\u0275\u0275inject(ta))};static \u0275prov=i.\u0275\u0275defineInjectable({token:Ke,factory:Ke.\u0275fac})}return Ke})();function Nc(Ke,...Se){return la(Ke,...Se)}const fu=Nc,Rc=Nc},8286:(Ot,Me,S)=>{S.r(Me),S.d(Me,{BREAK:()=>Ao,BreakingChangeType:()=>Ga,DEFAULT_DEPRECATION_REASON:()=>kn,DangerousChangeType:()=>qa,DirectiveLocation:()=>Pt,ExecutableDefinitionsRule:()=>qs,FieldsOnCorrectTypeRule:()=>Xc,FragmentsOnCompositeTypesRule:()=>Is,GRAPHQL_MAX_INT:()=>xu,GRAPHQL_MIN_INT:()=>Fc,GraphQLBoolean:()=>kl,GraphQLDeprecatedDirective:()=>bi,GraphQLDirective:()=>Ge,GraphQLEnumType:()=>yl,GraphQLError:()=>le,GraphQLFloat:()=>Ll,GraphQLID:()=>Nc,GraphQLIncludeDirective:()=>xt,GraphQLInputObjectType:()=>Aa,GraphQLInt:()=>po,GraphQLInterfaceType:()=>Il,GraphQLList:()=>ts,GraphQLNonNull:()=>wo,GraphQLObjectType:()=>pl,GraphQLOneOfDirective:()=>Ci,GraphQLScalarType:()=>la,GraphQLSchema:()=>_i,GraphQLSkipDirective:()=>Qt,GraphQLSpecifiedByDirective:()=>vi,GraphQLString:()=>Hs,GraphQLUnionType:()=>Xa,Kind:()=>Ae,KnownArgumentNamesRule:()=>xa,KnownDirectivesRule:()=>Vu,KnownFragmentNamesRule:()=>pu,KnownTypeNamesRule:()=>hu,Lexer:()=>St,Location:()=>fn,LoneAnonymousOperationRule:()=>kc,LoneSchemaDefinitionRule:()=>El,MaxIntrospectionDepthRule:()=>kd,NoDeprecatedCustomRule:()=>mu,NoFragmentCyclesRule:()=>Td,NoSchemaIntrospectionCustomRule:()=>Zh,NoUndefinedVariablesRule:()=>Pc,NoUnusedFragmentsRule:()=>ju,NoUnusedVariablesRule:()=>Yl,OperationTypeNode:()=>vn,OverlappingFieldsCanBeMergedRule:()=>_e,PossibleFragmentSpreadsRule:()=>yc,PossibleTypeExtensionsRule:()=>ne,ProvidedRequiredArgumentsRule:()=>Rn,ScalarLeafsRule:()=>Ce,SchemaMetaFieldDef:()=>zs,SingleFieldSubscriptionsRule:()=>Sp,Source:()=>ni,Token:()=>ct,TokenKind:()=>An,TypeInfo:()=>Ra,TypeKind:()=>Xo,TypeMetaFieldDef:()=>ya,TypeNameMetaFieldDef:()=>Je,UniqueArgumentDefinitionNamesRule:()=>Uu,UniqueArgumentNamesRule:()=>bh,UniqueDirectiveNamesRule:()=>wv,UniqueDirectivesPerLocationRule:()=>op,UniqueEnumValueNamesRule:()=>Pd,UniqueFieldDefinitionNamesRule:()=>$u,UniqueFragmentNamesRule:()=>yg,UniqueInputFieldNamesRule:()=>Qd,UniqueOperationNamesRule:()=>xv,UniqueOperationTypesRule:()=>bg,UniqueTypeNamesRule:()=>mf,UniqueVariableNamesRule:()=>U_,ValidationContext:()=>Sv,ValuesOfCorrectTypeRule:()=>Ch,VariablesAreInputTypesRule:()=>If,VariablesInAllowedPositionRule:()=>C0,__Directive:()=>zr,__DirectiveLocation:()=>ho,__EnumValue:()=>Ds,__Field:()=>is,__InputValue:()=>Ms,__Schema:()=>Fr,__Type:()=>Vr,__TypeKind:()=>na,assertAbstractType:()=>Ma,assertCompositeType:()=>Ws,assertDirective:()=>re,assertEnumType:()=>Ri,assertEnumValueName:()=>jt,assertInputObjectType:()=>Yi,assertInputType:()=>Mo,assertInterfaceType:()=>Or,assertLeafType:()=>Js,assertListType:()=>fr,assertName:()=>ko,assertNamedType:()=>Kc,assertNonNullType:()=>Vo,assertNullableType:()=>fl,assertObjectType:()=>ar,assertOutputType:()=>Jo,assertScalarType:()=>Fi,assertSchema:()=>On,assertType:()=>Rt,assertUnionType:()=>cn,assertValidName:()=>gu,assertValidSchema:()=>Di,assertWrappingType:()=>ga,astFromValue:()=>ai,buildASTSchema:()=>io,buildClientSchema:()=>Lm,buildSchema:()=>Ps,coerceInputValue:()=>kt,concatAST:()=>vo,createSourceEventStream:()=>Nm,defaultFieldResolver:()=>Zp,defaultTypeResolver:()=>gf,doTypesOverlap:()=>vc,execute:()=>Bs,executeSync:()=>wh,extendSchema:()=>Sh,findBreakingChanges:()=>Th,findDangerousChanges:()=>Pm,formatError:()=>wt,getArgumentValues:()=>Zo,getDirectiveValues:()=>Hl,getEnterLeaveForKind:()=>Na,getIntrospectionQuery:()=>H_,getLocation:()=>he,getNamedType:()=>wa,getNullableType:()=>Ia,getOperationAST:()=>Ff,getOperationRootType:()=>yd,getVariableValues:()=>rs,getVisitFn:()=>_l,graphql:()=>Tv,graphqlSync:()=>Md,introspectionFromSchema:()=>Rm,introspectionTypes:()=>at,isAbstractType:()=>es,isCompositeType:()=>ds,isConstValueNode:()=>md,isDefinitionNode:()=>Yt,isDirective:()=>Se,isEnumType:()=>Tn,isEqualType:()=>sc,isExecutableDefinitionNode:()=>tc,isInputObjectType:()=>Un,isInputType:()=>vr,isInterfaceType:()=>er,isIntrospectionType:()=>Oe,isLeafType:()=>$s,isListType:()=>Wi,isNamedType:()=>al,isNonNullType:()=>Li,isNullableType:()=>sl,isObjectType:()=>Ui,isOutputType:()=>ks,isRequiredArgument:()=>ca,isRequiredInputField:()=>Ql,isScalarType:()=>jn,isSchema:()=>Ct,isSelectionNode:()=>Qh,isSpecifiedDirective:()=>$i,isSpecifiedScalarType:()=>Rc,isType:()=>In,isTypeDefinitionNode:()=>Eu,isTypeExtensionNode:()=>Lc,isTypeNode:()=>Ld,isTypeSubTypeOf:()=>ta,isTypeSystemDefinitionNode:()=>gd,isTypeSystemExtensionNode:()=>Pu,isUnionType:()=>Tt,isValidNameError:()=>Zl,isValueNode:()=>Su,isWrappingType:()=>ea,lexicographicSortSchema:()=>fc,locatedError:()=>Ep,parse:()=>Ti,parseConstValue:()=>Gi,parseType:()=>Ii,parseValue:()=>Bi,print:()=>gs,printError:()=>Et,printIntrospectionSchema:()=>Ja,printLocation:()=>q,printSchema:()=>Rf,printSourceLocation:()=>oe,printType:()=>eh,recommendedRules:()=>xr,resolveObjMapThunk:()=>qc,resolveReadonlyArrayThunk:()=>Sl,responsePathAsArray:()=>Ze,separateOperations:()=>Gr,specifiedDirectives:()=>Xi,specifiedRules:()=>Dh,specifiedScalarTypes:()=>fu,stripIgnoredCharacters:()=>el,subscribe:()=>Ip,syntaxError:()=>ve,typeFromAST:()=>Tc,validate:()=>Am,validateSchema:()=>qi,valueFromAST:()=>oi,valueFromASTUntyped:()=>Lo,version:()=>i,versionInfo:()=>e,visit:()=>za,visitInParallel:()=>vl,visitWithTypeInfo:()=>ff});const i="16.9.0",e=Object.freeze({major:16,minor:9,patch:0,preReleaseTag:null});function M(T,P){if(!T)throw new Error(P)}function X(T){return"function"==typeof T?.then}function ie(T){return"object"==typeof T&&null!==T}function Q(T,P){if(!T)throw new Error(P??"Unexpected invariant triggered.")}const Ee=/\r\n|[\n\r]/g;function he(T,P){let W=0,se=1;for(const me of T.body.matchAll(Ee)){if("number"==typeof me.index||Q(!1),me.index>=P)break;W=me.index+me[0].length,se+=1}return{line:se,column:P+1-W}}function q(T){return oe(T.source,he(T.source,T.start))}function oe(T,P){const W=T.locationOffset.column-1,se="".padStart(W)+T.body,me=P.line-1,gt=P.line+(T.locationOffset.line-1),wn=P.column+(1===P.line?W:0),ei=`${T.name}:${gt}:${wn}\n`,yi=se.split(/\r\n|[\n\r]/g),Vi=yi[me];if(Vi.length>120){const tr=Math.floor(wn/80),Wr=wn%80,Yo=[];for(let Cl=0;Cl<Vi.length;Cl+=80)Yo.push(Vi.slice(Cl,Cl+80));return ei+Z([[`${gt} |`,Yo[0]],...Yo.slice(1,tr+1).map(Cl=>["|",Cl]),["|","^".padStart(Wr)],["|",Yo[tr+1]]])}return ei+Z([[gt-1+" |",yi[me-1]],[`${gt} |`,Vi],["|","^".padStart(wn)],[`${gt+1} |`,yi[me+1]]])}function Z(T){const P=T.filter(([se,me])=>void 0!==me),W=Math.max(...P.map(([se])=>se.length));return P.map(([se,me])=>se.padStart(W)+(me?" "+me:"")).join("\n")}class le extends Error{constructor(P,...W){var se,me,Fe;const{nodes:gt,source:Bt,positions:wn,path:ei,originalError:yi,extensions:Vi}=function ce(T){const P=T[0];return null==P||"kind"in P||"length"in P?{nodes:P,source:T[1],positions:T[2],path:T[3],originalError:T[4],extensions:T[5]}:P}(W);super(P),this.name="GraphQLError",this.path=ei??void 0,this.originalError=yi??void 0,this.nodes=je(Array.isArray(gt)?gt:gt?[gt]:void 0);const tr=je(null===(se=this.nodes)||void 0===se?void 0:se.map(Yo=>Yo.loc).filter(Yo=>null!=Yo));this.source=Bt??(null==tr||null===(me=tr[0])||void 0===me?void 0:me.source),this.positions=wn??tr?.map(Yo=>Yo.start),this.locations=wn&&Bt?wn.map(Yo=>he(Bt,Yo)):tr?.map(Yo=>he(Yo.source,Yo.start));const Wr=ie(yi?.extensions)?yi?.extensions:void 0;this.extensions=null!==(Fe=Vi??Wr)&&void 0!==Fe?Fe:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),null!=yi&&yi.stack?Object.defineProperty(this,"stack",{value:yi.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,le):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let P=this.message;if(this.nodes)for(const W of this.nodes)W.loc&&(P+="\n\n"+q(W.loc));else if(this.source&&this.locations)for(const W of this.locations)P+="\n\n"+oe(this.source,W);return P}toJSON(){const P={message:this.message};return null!=this.locations&&(P.locations=this.locations),null!=this.path&&(P.path=this.path),null!=this.extensions&&Object.keys(this.extensions).length>0&&(P.extensions=this.extensions),P}}function je(T){return void 0===T||0===T.length?void 0:T}function Et(T){return T.toString()}function wt(T){return T.toJSON()}function ve(T,P,W){return new le(`Syntax Error: ${W}`,{source:T,positions:[P]})}class fn{constructor(P,W,se){this.start=P.start,this.end=W.end,this.startToken=P,this.endToken=W,this.source=se}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}}class ct{constructor(P,W,se,me,Fe,gt){this.kind=P,this.start=W,this.end=se,this.line=me,this.column=Fe,this.value=gt,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}const en={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},an=new Set(Object.keys(en));function un(T){const P=T?.kind;return"string"==typeof P&&an.has(P)}var vn=function(T){return T.QUERY="query",T.MUTATION="mutation",T.SUBSCRIPTION="subscription",T}(vn||{}),Pt=function(T){return T.QUERY="QUERY",T.MUTATION="MUTATION",T.SUBSCRIPTION="SUBSCRIPTION",T.FIELD="FIELD",T.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",T.FRAGMENT_SPREAD="FRAGMENT_SPREAD",T.INLINE_FRAGMENT="INLINE_FRAGMENT",T.VARIABLE_DEFINITION="VARIABLE_DEFINITION",T.SCHEMA="SCHEMA",T.SCALAR="SCALAR",T.OBJECT="OBJECT",T.FIELD_DEFINITION="FIELD_DEFINITION",T.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",T.INTERFACE="INTERFACE",T.UNION="UNION",T.ENUM="ENUM",T.ENUM_VALUE="ENUM_VALUE",T.INPUT_OBJECT="INPUT_OBJECT",T.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION",T}(Pt||{}),Ae=function(T){return T.NAME="Name",T.DOCUMENT="Document",T.OPERATION_DEFINITION="OperationDefinition",T.VARIABLE_DEFINITION="VariableDefinition",T.SELECTION_SET="SelectionSet",T.FIELD="Field",T.ARGUMENT="Argument",T.FRAGMENT_SPREAD="FragmentSpread",T.INLINE_FRAGMENT="InlineFragment",T.FRAGMENT_DEFINITION="FragmentDefinition",T.VARIABLE="Variable",T.INT="IntValue",T.FLOAT="FloatValue",T.STRING="StringValue",T.BOOLEAN="BooleanValue",T.NULL="NullValue",T.ENUM="EnumValue",T.LIST="ListValue",T.OBJECT="ObjectValue",T.OBJECT_FIELD="ObjectField",T.DIRECTIVE="Directive",T.NAMED_TYPE="NamedType",T.LIST_TYPE="ListType",T.NON_NULL_TYPE="NonNullType",T.SCHEMA_DEFINITION="SchemaDefinition",T.OPERATION_TYPE_DEFINITION="OperationTypeDefinition",T.SCALAR_TYPE_DEFINITION="ScalarTypeDefinition",T.OBJECT_TYPE_DEFINITION="ObjectTypeDefinition",T.FIELD_DEFINITION="FieldDefinition",T.INPUT_VALUE_DEFINITION="InputValueDefinition",T.INTERFACE_TYPE_DEFINITION="InterfaceTypeDefinition",T.UNION_TYPE_DEFINITION="UnionTypeDefinition",T.ENUM_TYPE_DEFINITION="EnumTypeDefinition",T.ENUM_VALUE_DEFINITION="EnumValueDefinition",T.INPUT_OBJECT_TYPE_DEFINITION="InputObjectTypeDefinition",T.DIRECTIVE_DEFINITION="DirectiveDefinition",T.SCHEMA_EXTENSION="SchemaExtension",T.SCALAR_TYPE_EXTENSION="ScalarTypeExtension",T.OBJECT_TYPE_EXTENSION="ObjectTypeExtension",T.INTERFACE_TYPE_EXTENSION="InterfaceTypeExtension",T.UNION_TYPE_EXTENSION="UnionTypeExtension",T.ENUM_TYPE_EXTENSION="EnumTypeExtension",T.INPUT_OBJECT_TYPE_EXTENSION="InputObjectTypeExtension",T}(Ae||{});function dt(T){return 9===T||32===T}function ut(T){return T>=48&&T<=57}function Mt(T){return T>=97&&T<=122||T>=65&&T<=90}function Wt(T){return Mt(T)||95===T}function It(T){return Mt(T)||ut(T)||95===T}function Vn(T){var P;let W=Number.MAX_SAFE_INTEGER,se=null,me=-1;for(let gt=0;gt<T.length;++gt){var Fe;const Bt=T[gt],wn=pn(Bt);wn!==Bt.length&&(se=null!==(Fe=se)&&void 0!==Fe?Fe:gt,me=gt,0!==gt&&wn<W&&(W=wn))}return T.map((gt,Bt)=>0===Bt?gt:gt.slice(W)).slice(null!==(P=se)&&void 0!==P?P:0,me+1)}function pn(T){let P=0;for(;P<T.length&&dt(T.charCodeAt(P));)++P;return P}function Wn(T){if(""===T)return!0;let P=!0,W=!1,se=!0,me=!1;for(let Fe=0;Fe<T.length;++Fe)switch(T.codePointAt(Fe)){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 11:case 12:case 14:case 15:case 13:return!1;case 10:if(P&&!me)return!1;me=!0,P=!0,W=!1;break;case 9:case 32:W||(W=P);break;default:se&&(se=W),P=!1}return!(P||se&&me)}function ji(T,P){const W=T.replace(/"""/g,'\\"""'),se=W.split(/\r\n|[\n\r]/g),me=1===se.length,Fe=se.length>1&&se.slice(1).every(Wr=>0===Wr.length||dt(Wr.charCodeAt(0))),gt=W.endsWith('\\"""'),Bt=T.endsWith('"')&&!gt,wn=T.endsWith("\\"),ei=Bt||wn,yi=!(null!=P&&P.minimize)&&(!me||T.length>70||ei||Fe||gt);let Vi="";const tr=me&&dt(T.charCodeAt(0));return(yi&&!tr||Fe)&&(Vi+="\n"),Vi+=W,(yi||ei)&&(Vi+="\n"),'"""'+Vi+'"""'}var An=function(T){return T.SOF="<SOF>",T.EOF="<EOF>",T.BANG="!",T.DOLLAR="$",T.AMP="&",T.PAREN_L="(",T.PAREN_R=")",T.SPREAD="...",T.COLON=":",T.EQUALS="=",T.AT="@",T.BRACKET_L="[",T.BRACKET_R="]",T.BRACE_L="{",T.PIPE="|",T.BRACE_R="}",T.NAME="Name",T.INT="Int",T.FLOAT="Float",T.STRING="String",T.BLOCK_STRING="BlockString",T.COMMENT="Comment",T}(An||{});class St{constructor(P){const W=new ct(An.SOF,0,0,0,0);this.source=P,this.lastToken=W,this.token=W,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let P=this.token;if(P.kind!==An.EOF)do{if(P.next)P=P.next;else{const W=Dn(this,P.end);P.next=W,W.prev=P,P=W}}while(P.kind===An.COMMENT);return P}}function qt(T){return T===An.BANG||T===An.DOLLAR||T===An.AMP||T===An.PAREN_L||T===An.PAREN_R||T===An.SPREAD||T===An.COLON||T===An.EQUALS||T===An.AT||T===An.BRACKET_L||T===An.BRACKET_R||T===An.BRACE_L||T===An.PIPE||T===An.BRACE_R}function Ht(T){return T>=0&&T<=55295||T>=57344&&T<=1114111}function on(T,P){return Cn(T.charCodeAt(P))&&tn(T.charCodeAt(P+1))}function Cn(T){return T>=55296&&T<=56319}function tn(T){return T>=56320&&T<=57343}function fi(T,P){const W=T.source.body.codePointAt(P);if(void 0===W)return An.EOF;if(W>=32&&W<=126){const se=String.fromCodePoint(W);return'"'===se?"'\"'":`"${se}"`}return"U+"+W.toString(16).toUpperCase().padStart(4,"0")}function Zn(T,P,W,se,me){return new ct(P,W,se,T.line,1+W-T.lineStart,me)}function Dn(T,P){const W=T.source.body,se=W.length;let me=P;for(;me<se;){const Fe=W.charCodeAt(me);switch(Fe){case 65279:case 9:case 32:case 44:++me;continue;case 10:++me,++T.line,T.lineStart=me;continue;case 13:10===W.charCodeAt(me+1)?me+=2:++me,++T.line,T.lineStart=me;continue;case 35:return gn(T,me);case 33:return Zn(T,An.BANG,me,me+1);case 36:return Zn(T,An.DOLLAR,me,me+1);case 38:return Zn(T,An.AMP,me,me+1);case 40:return Zn(T,An.PAREN_L,me,me+1);case 41:return Zn(T,An.PAREN_R,me,me+1);case 46:if(46===W.charCodeAt(me+1)&&46===W.charCodeAt(me+2))return Zn(T,An.SPREAD,me,me+3);break;case 58:return Zn(T,An.COLON,me,me+1);case 61:return Zn(T,An.EQUALS,me,me+1);case 64:return Zn(T,An.AT,me,me+1);case 91:return Zn(T,An.BRACKET_L,me,me+1);case 93:return Zn(T,An.BRACKET_R,me,me+1);case 123:return Zn(T,An.BRACE_L,me,me+1);case 124:return Zn(T,An.PIPE,me,me+1);case 125:return Zn(T,An.BRACE_R,me,me+1);case 34:return 34===W.charCodeAt(me+1)&&34===W.charCodeAt(me+2)?as(T,me):cr(T,me)}if(ut(Fe)||45===Fe)return Nn(T,me,Fe);if(Wt(Fe))return uo(T,me);throw ve(T.source,me,39===Fe?"Unexpected single quote character ('), did you mean to use a double quote (\")?":Ht(Fe)||on(W,me)?`Unexpected character: ${fi(T,me)}.`:`Invalid character: ${fi(T,me)}.`)}return Zn(T,An.EOF,se,se)}function gn(T,P){const W=T.source.body,se=W.length;let me=P+1;for(;me<se;){const Fe=W.charCodeAt(me);if(10===Fe||13===Fe)break;if(Ht(Fe))++me;else{if(!on(W,me))break;me+=2}}return Zn(T,An.COMMENT,P,me,W.slice(P+1,me))}function Nn(T,P,W){const se=T.source.body;let me=P,Fe=W,gt=!1;if(45===Fe&&(Fe=se.charCodeAt(++me)),48===Fe){if(Fe=se.charCodeAt(++me),ut(Fe))throw ve(T.source,me,`Invalid number, unexpected digit after 0: ${fi(T,me)}.`)}else me=Yn(T,me,Fe),Fe=se.charCodeAt(me);if(46===Fe&&(gt=!0,Fe=se.charCodeAt(++me),me=Yn(T,me,Fe),Fe=se.charCodeAt(me)),(69===Fe||101===Fe)&&(gt=!0,Fe=se.charCodeAt(++me),(43===Fe||45===Fe)&&(Fe=se.charCodeAt(++me)),me=Yn(T,me,Fe),Fe=se.charCodeAt(me)),46===Fe||Wt(Fe))throw ve(T.source,me,`Invalid number, expected digit but got: ${fi(T,me)}.`);return Zn(T,gt?An.FLOAT:An.INT,P,me,se.slice(P,me))}function Yn(T,P,W){if(!ut(W))throw ve(T.source,P,`Invalid number, expected digit but got: ${fi(T,P)}.`);const se=T.source.body;let me=P+1;for(;ut(se.charCodeAt(me));)++me;return me}function cr(T,P){const W=T.source.body,se=W.length;let me=P+1,Fe=me,gt="";for(;me<se;){const Bt=W.charCodeAt(me);if(34===Bt)return gt+=W.slice(Fe,me),Zn(T,An.STRING,P,me+1,gt);if(92!==Bt){if(10===Bt||13===Bt)break;if(Ht(Bt))++me;else{if(!on(W,me))throw ve(T.source,me,`Invalid character within String: ${fi(T,me)}.`);me+=2}}else{gt+=W.slice(Fe,me);const wn=117===W.charCodeAt(me+1)?123===W.charCodeAt(me+2)?Ai(T,me):Qi(T,me):eo(T,me);gt+=wn.value,me+=wn.size,Fe=me}}throw ve(T.source,me,"Unterminated string.")}function Ai(T,P){const W=T.source.body;let se=0,me=3;for(;me<12;){const Fe=W.charCodeAt(P+me++);if(125===Fe){if(me<5||!Ht(se))break;return{value:String.fromCodePoint(se),size:me}}if(se=se<<4|Ur(Fe),se<0)break}throw ve(T.source,P,`Invalid Unicode escape sequence: "${W.slice(P,P+me)}".`)}function Qi(T,P){const W=T.source.body,se=Xr(W,P+2);if(Ht(se))return{value:String.fromCodePoint(se),size:6};if(Cn(se)&&92===W.charCodeAt(P+6)&&117===W.charCodeAt(P+7)){const me=Xr(W,P+8);if(tn(me))return{value:String.fromCodePoint(se,me),size:12}}throw ve(T.source,P,`Invalid Unicode escape sequence: "${W.slice(P,P+6)}".`)}function Xr(T,P){return Ur(T.charCodeAt(P))<<12|Ur(T.charCodeAt(P+1))<<8|Ur(T.charCodeAt(P+2))<<4|Ur(T.charCodeAt(P+3))}function Ur(T){return T>=48&&T<=57?T-48:T>=65&&T<=70?T-55:T>=97&&T<=102?T-87:-1}function eo(T,P){const W=T.source.body;switch(W.charCodeAt(P+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:"\n",size:2};case 114:return{value:"\r",size:2};case 116:return{value:"\t",size:2}}throw ve(T.source,P,`Invalid character escape sequence: "${W.slice(P,P+2)}".`)}function as(T,P){const W=T.source.body,se=W.length;let me=T.lineStart,Fe=P+3,gt=Fe,Bt="";const wn=[];for(;Fe<se;){const ei=W.charCodeAt(Fe);if(34===ei&&34===W.charCodeAt(Fe+1)&&34===W.charCodeAt(Fe+2)){Bt+=W.slice(gt,Fe),wn.push(Bt);const yi=Zn(T,An.BLOCK_STRING,P,Fe+3,Vn(wn).join("\n"));return T.line+=wn.length-1,T.lineStart=me,yi}if(92!==ei||34!==W.charCodeAt(Fe+1)||34!==W.charCodeAt(Fe+2)||34!==W.charCodeAt(Fe+3))if(10!==ei&&13!==ei)if(Ht(ei))++Fe;else{if(!on(W,Fe))throw ve(T.source,Fe,`Invalid character within String: ${fi(T,Fe)}.`);Fe+=2}else Bt+=W.slice(gt,Fe),wn.push(Bt),13===ei&&10===W.charCodeAt(Fe+1)?Fe+=2:++Fe,Bt="",gt=Fe,me=Fe;else Bt+=W.slice(gt,Fe),gt=Fe+1,Fe+=4}throw ve(T.source,Fe,"Unterminated string.")}function uo(T,P){const W=T.source.body,se=W.length;let me=P+1;for(;me<se&&It(W.charCodeAt(me));)++me;return Zn(T,An.NAME,P,me,W.slice(P,me))}const mi=10,ci=2;function yt(T){return hn(T,[])}function hn(T,P){switch(typeof T){case"string":return JSON.stringify(T);case"function":return T.name?`[function ${T.name}]`:"[function]";case"object":return function Gt(T,P){if(null===T)return"null";if(P.includes(T))return"[Circular]";const W=[...P,T];if(function Gn(T){return"function"==typeof T.toJSON}(T)){const se=T.toJSON();if(se!==T)return"string"==typeof se?se:hn(se,W)}else if(Array.isArray(T))return function pi(T,P){if(0===T.length)return"[]";if(P.length>ci)return"[Array]";const W=Math.min(mi,T.length),se=T.length-W,me=[];for(let Fe=0;Fe<W;++Fe)me.push(hn(T[Fe],P));return 1===se?me.push("... 1 more item"):se>1&&me.push(`... ${se} more items`),"["+me.join(", ")+"]"}(T,W);return function ri(T,P){const W=Object.entries(T);return 0===W.length?"{}":P.length>ci?"["+function At(T){const P=Object.prototype.toString.call(T).replace(/^\[object /,"").replace(/]$/,"");if("Object"===P&&"function"==typeof T.constructor){const W=T.constructor.name;if("string"==typeof W&&""!==W)return W}return P}(T)+"]":"{ "+W.map(([me,Fe])=>me+": "+hn(Fe,P)).join(", ")+" }"}(T,W)}(T,P);default:return String(T)}}const Mn=globalThis.process?function(P,W){return P instanceof W}:function(P,W){if(P instanceof W)return!0;if("object"==typeof P&&null!==P){var se;const me=W.prototype[Symbol.toStringTag];if(me===(Symbol.toStringTag in P?P[Symbol.toStringTag]:null===(se=P.constructor)||void 0===se?void 0:se.name)){const gt=yt(P);throw new Error(`Cannot use ${me} "${gt}" from another module or realm.\n\nEnsure that there is only one instance of "graphql" in the node_modules\ndirectory. If different versions of "graphql" are the dependencies of other\nrelied on modules, use "resolutions" to ensure only one version is installed.\n\nhttps://yarnpkg.com/en/docs/selective-version-resolutions\n\nDuplicate "graphql" modules cannot be used at the same time since different\nversions may have different capabilities and behavior. The data from one\nversion used in the function from another could produce confusing and\nspurious results.`)}}return!1};class ni{constructor(P,W="GraphQL request",se={line:1,column:1}){"string"==typeof P||M(!1,`Body must be a string. Received: ${yt(P)}.`),this.body=P,this.name=W,this.locationOffset=se,this.locationOffset.line>0||M(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||M(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function qn(T){return Mn(T,ni)}function Ti(T,P){return new Ki(T,P).parseDocument()}function Bi(T,P){const W=new Ki(T,P);W.expectToken(An.SOF);const se=W.parseValueLiteral(!1);return W.expectToken(An.EOF),se}function Gi(T,P){const W=new Ki(T,P);W.expectToken(An.SOF);const se=W.parseConstValueLiteral();return W.expectToken(An.EOF),se}function Ii(T,P){const W=new Ki(T,P);W.expectToken(An.SOF);const se=W.parseTypeReference();return W.expectToken(An.EOF),se}class Ki{constructor(P,W={}){const se=qn(P)?P:new ni(P);this._lexer=new St(se),this._options=W,this._tokenCounter=0}parseName(){const P=this.expectToken(An.NAME);return this.node(P,{kind:Ae.NAME,value:P.value})}parseDocument(){return this.node(this._lexer.token,{kind:Ae.DOCUMENT,definitions:this.many(An.SOF,this.parseDefinition,An.EOF)})}parseDefinition(){if(this.peek(An.BRACE_L))return this.parseOperationDefinition();const P=this.peekDescription(),W=P?this._lexer.lookahead():this._lexer.token;if(W.kind===An.NAME){switch(W.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(P)throw ve(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(W.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(W)}parseOperationDefinition(){const P=this._lexer.token;if(this.peek(An.BRACE_L))return this.node(P,{kind:Ae.OPERATION_DEFINITION,operation:vn.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});const W=this.parseOperationType();let se;return this.peek(An.NAME)&&(se=this.parseName()),this.node(P,{kind:Ae.OPERATION_DEFINITION,operation:W,name:se,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){const P=this.expectToken(An.NAME);switch(P.value){case"query":return vn.QUERY;case"mutation":return vn.MUTATION;case"subscription":return vn.SUBSCRIPTION}throw this.unexpected(P)}parseVariableDefinitions(){return this.optionalMany(An.PAREN_L,this.parseVariableDefinition,An.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:Ae.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(An.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(An.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){const P=this._lexer.token;return this.expectToken(An.DOLLAR),this.node(P,{kind:Ae.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:Ae.SELECTION_SET,selections:this.many(An.BRACE_L,this.parseSelection,An.BRACE_R)})}parseSelection(){return this.peek(An.SPREAD)?this.parseFragment():this.parseField()}parseField(){const P=this._lexer.token,W=this.parseName();let se,me;return this.expectOptionalToken(An.COLON)?(se=W,me=this.parseName()):me=W,this.node(P,{kind:Ae.FIELD,alias:se,name:me,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(An.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(P){return this.optionalMany(An.PAREN_L,P?this.parseConstArgument:this.parseArgument,An.PAREN_R)}parseArgument(P=!1){const W=this._lexer.token,se=this.parseName();return this.expectToken(An.COLON),this.node(W,{kind:Ae.ARGUMENT,name:se,value:this.parseValueLiteral(P)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){const P=this._lexer.token;this.expectToken(An.SPREAD);const W=this.expectOptionalKeyword("on");return!W&&this.peek(An.NAME)?this.node(P,{kind:Ae.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(P,{kind:Ae.INLINE_FRAGMENT,typeCondition:W?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){const P=this._lexer.token;return this.expectKeyword("fragment"),this.node(P,!0===this._options.allowLegacyFragmentVariables?{kind:Ae.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}:{kind:Ae.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if("on"===this._lexer.token.value)throw this.unexpected();return this.parseName()}parseValueLiteral(P){const W=this._lexer.token;switch(W.kind){case An.BRACKET_L:return this.parseList(P);case An.BRACE_L:return this.parseObject(P);case An.INT:return this.advanceLexer(),this.node(W,{kind:Ae.INT,value:W.value});case An.FLOAT:return this.advanceLexer(),this.node(W,{kind:Ae.FLOAT,value:W.value});case An.STRING:case An.BLOCK_STRING:return this.parseStringLiteral();case An.NAME:switch(this.advanceLexer(),W.value){case"true":return this.node(W,{kind:Ae.BOOLEAN,value:!0});case"false":return this.node(W,{kind:Ae.BOOLEAN,value:!1});case"null":return this.node(W,{kind:Ae.NULL});default:return this.node(W,{kind:Ae.ENUM,value:W.value})}case An.DOLLAR:if(P){if(this.expectToken(An.DOLLAR),this._lexer.token.kind===An.NAME)throw ve(this._lexer.source,W.start,`Unexpected variable "$${this._lexer.token.value}" in constant value.`);throw this.unexpected(W)}return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){const P=this._lexer.token;return this.advanceLexer(),this.node(P,{kind:Ae.STRING,value:P.value,block:P.kind===An.BLOCK_STRING})}parseList(P){return this.node(this._lexer.token,{kind:Ae.LIST,values:this.any(An.BRACKET_L,()=>this.parseValueLiteral(P),An.BRACKET_R)})}parseObject(P){return this.node(this._lexer.token,{kind:Ae.OBJECT,fields:this.any(An.BRACE_L,()=>this.parseObjectField(P),An.BRACE_R)})}parseObjectField(P){const W=this._lexer.token,se=this.parseName();return this.expectToken(An.COLON),this.node(W,{kind:Ae.OBJECT_FIELD,name:se,value:this.parseValueLiteral(P)})}parseDirectives(P){const W=[];for(;this.peek(An.AT);)W.push(this.parseDirective(P));return W}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(P){const W=this._lexer.token;return this.expectToken(An.AT),this.node(W,{kind:Ae.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(P)})}parseTypeReference(){const P=this._lexer.token;let W;if(this.expectOptionalToken(An.BRACKET_L)){const se=this.parseTypeReference();this.expectToken(An.BRACKET_R),W=this.node(P,{kind:Ae.LIST_TYPE,type:se})}else W=this.parseNamedType();return this.expectOptionalToken(An.BANG)?this.node(P,{kind:Ae.NON_NULL_TYPE,type:W}):W}parseNamedType(){return this.node(this._lexer.token,{kind:Ae.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(An.STRING)||this.peek(An.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("schema");const se=this.parseConstDirectives(),me=this.many(An.BRACE_L,this.parseOperationTypeDefinition,An.BRACE_R);return this.node(P,{kind:Ae.SCHEMA_DEFINITION,description:W,directives:se,operationTypes:me})}parseOperationTypeDefinition(){const P=this._lexer.token,W=this.parseOperationType();this.expectToken(An.COLON);const se=this.parseNamedType();return this.node(P,{kind:Ae.OPERATION_TYPE_DEFINITION,operation:W,type:se})}parseScalarTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("scalar");const se=this.parseName(),me=this.parseConstDirectives();return this.node(P,{kind:Ae.SCALAR_TYPE_DEFINITION,description:W,name:se,directives:me})}parseObjectTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("type");const se=this.parseName(),me=this.parseImplementsInterfaces(),Fe=this.parseConstDirectives(),gt=this.parseFieldsDefinition();return this.node(P,{kind:Ae.OBJECT_TYPE_DEFINITION,description:W,name:se,interfaces:me,directives:Fe,fields:gt})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(An.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(An.BRACE_L,this.parseFieldDefinition,An.BRACE_R)}parseFieldDefinition(){const P=this._lexer.token,W=this.parseDescription(),se=this.parseName(),me=this.parseArgumentDefs();this.expectToken(An.COLON);const Fe=this.parseTypeReference(),gt=this.parseConstDirectives();return this.node(P,{kind:Ae.FIELD_DEFINITION,description:W,name:se,arguments:me,type:Fe,directives:gt})}parseArgumentDefs(){return this.optionalMany(An.PAREN_L,this.parseInputValueDef,An.PAREN_R)}parseInputValueDef(){const P=this._lexer.token,W=this.parseDescription(),se=this.parseName();this.expectToken(An.COLON);const me=this.parseTypeReference();let Fe;this.expectOptionalToken(An.EQUALS)&&(Fe=this.parseConstValueLiteral());const gt=this.parseConstDirectives();return this.node(P,{kind:Ae.INPUT_VALUE_DEFINITION,description:W,name:se,type:me,defaultValue:Fe,directives:gt})}parseInterfaceTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("interface");const se=this.parseName(),me=this.parseImplementsInterfaces(),Fe=this.parseConstDirectives(),gt=this.parseFieldsDefinition();return this.node(P,{kind:Ae.INTERFACE_TYPE_DEFINITION,description:W,name:se,interfaces:me,directives:Fe,fields:gt})}parseUnionTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("union");const se=this.parseName(),me=this.parseConstDirectives(),Fe=this.parseUnionMemberTypes();return this.node(P,{kind:Ae.UNION_TYPE_DEFINITION,description:W,name:se,directives:me,types:Fe})}parseUnionMemberTypes(){return this.expectOptionalToken(An.EQUALS)?this.delimitedMany(An.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("enum");const se=this.parseName(),me=this.parseConstDirectives(),Fe=this.parseEnumValuesDefinition();return this.node(P,{kind:Ae.ENUM_TYPE_DEFINITION,description:W,name:se,directives:me,values:Fe})}parseEnumValuesDefinition(){return this.optionalMany(An.BRACE_L,this.parseEnumValueDefinition,An.BRACE_R)}parseEnumValueDefinition(){const P=this._lexer.token,W=this.parseDescription(),se=this.parseEnumValueName(),me=this.parseConstDirectives();return this.node(P,{kind:Ae.ENUM_VALUE_DEFINITION,description:W,name:se,directives:me})}parseEnumValueName(){if("true"===this._lexer.token.value||"false"===this._lexer.token.value||"null"===this._lexer.token.value)throw ve(this._lexer.source,this._lexer.token.start,`${Jt(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("input");const se=this.parseName(),me=this.parseConstDirectives(),Fe=this.parseInputFieldsDefinition();return this.node(P,{kind:Ae.INPUT_OBJECT_TYPE_DEFINITION,description:W,name:se,directives:me,fields:Fe})}parseInputFieldsDefinition(){return this.optionalMany(An.BRACE_L,this.parseInputValueDef,An.BRACE_R)}parseTypeSystemExtension(){const P=this._lexer.lookahead();if(P.kind===An.NAME)switch(P.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(P)}parseSchemaExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");const W=this.parseConstDirectives(),se=this.optionalMany(An.BRACE_L,this.parseOperationTypeDefinition,An.BRACE_R);if(0===W.length&&0===se.length)throw this.unexpected();return this.node(P,{kind:Ae.SCHEMA_EXTENSION,directives:W,operationTypes:se})}parseScalarTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");const W=this.parseName(),se=this.parseConstDirectives();if(0===se.length)throw this.unexpected();return this.node(P,{kind:Ae.SCALAR_TYPE_EXTENSION,name:W,directives:se})}parseObjectTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");const W=this.parseName(),se=this.parseImplementsInterfaces(),me=this.parseConstDirectives(),Fe=this.parseFieldsDefinition();if(0===se.length&&0===me.length&&0===Fe.length)throw this.unexpected();return this.node(P,{kind:Ae.OBJECT_TYPE_EXTENSION,name:W,interfaces:se,directives:me,fields:Fe})}parseInterfaceTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");const W=this.parseName(),se=this.parseImplementsInterfaces(),me=this.parseConstDirectives(),Fe=this.parseFieldsDefinition();if(0===se.length&&0===me.length&&0===Fe.length)throw this.unexpected();return this.node(P,{kind:Ae.INTERFACE_TYPE_EXTENSION,name:W,interfaces:se,directives:me,fields:Fe})}parseUnionTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");const W=this.parseName(),se=this.parseConstDirectives(),me=this.parseUnionMemberTypes();if(0===se.length&&0===me.length)throw this.unexpected();return this.node(P,{kind:Ae.UNION_TYPE_EXTENSION,name:W,directives:se,types:me})}parseEnumTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");const W=this.parseName(),se=this.parseConstDirectives(),me=this.parseEnumValuesDefinition();if(0===se.length&&0===me.length)throw this.unexpected();return this.node(P,{kind:Ae.ENUM_TYPE_EXTENSION,name:W,directives:se,values:me})}parseInputObjectTypeExtension(){const P=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");const W=this.parseName(),se=this.parseConstDirectives(),me=this.parseInputFieldsDefinition();if(0===se.length&&0===me.length)throw this.unexpected();return this.node(P,{kind:Ae.INPUT_OBJECT_TYPE_EXTENSION,name:W,directives:se,fields:me})}parseDirectiveDefinition(){const P=this._lexer.token,W=this.parseDescription();this.expectKeyword("directive"),this.expectToken(An.AT);const se=this.parseName(),me=this.parseArgumentDefs(),Fe=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");const gt=this.parseDirectiveLocations();return this.node(P,{kind:Ae.DIRECTIVE_DEFINITION,description:W,name:se,arguments:me,repeatable:Fe,locations:gt})}parseDirectiveLocations(){return this.delimitedMany(An.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){const P=this._lexer.token,W=this.parseName();if(Object.prototype.hasOwnProperty.call(Pt,W.value))return W;throw this.unexpected(P)}node(P,W){return!0!==this._options.noLocation&&(W.loc=new fn(P,this._lexer.lastToken,this._lexer.source)),W}peek(P){return this._lexer.token.kind===P}expectToken(P){const W=this._lexer.token;if(W.kind===P)return this.advanceLexer(),W;throw ve(this._lexer.source,W.start,`Expected ${hi(P)}, found ${Jt(W)}.`)}expectOptionalToken(P){return this._lexer.token.kind===P&&(this.advanceLexer(),!0)}expectKeyword(P){const W=this._lexer.token;if(W.kind!==An.NAME||W.value!==P)throw ve(this._lexer.source,W.start,`Expected "${P}", found ${Jt(W)}.`);this.advanceLexer()}expectOptionalKeyword(P){const W=this._lexer.token;return W.kind===An.NAME&&W.value===P&&(this.advanceLexer(),!0)}unexpected(P){const W=P??this._lexer.token;return ve(this._lexer.source,W.start,`Unexpected ${Jt(W)}.`)}any(P,W,se){this.expectToken(P);const me=[];for(;!this.expectOptionalToken(se);)me.push(W.call(this));return me}optionalMany(P,W,se){if(this.expectOptionalToken(P)){const me=[];do{me.push(W.call(this))}while(!this.expectOptionalToken(se));return me}return[]}many(P,W,se){this.expectToken(P);const me=[];do{me.push(W.call(this))}while(!this.expectOptionalToken(se));return me}delimitedMany(P,W){this.expectOptionalToken(P);const se=[];do{se.push(W.call(this))}while(this.expectOptionalToken(P));return se}advanceLexer(){const{maxTokens:P}=this._options,W=this._lexer.advance();if(void 0!==P&&W.kind!==An.EOF&&(++this._tokenCounter,this._tokenCounter>P))throw ve(this._lexer.source,W.start,`Document contains more that ${P} tokens. Parsing aborted.`)}}function Jt(T){const P=T.value;return hi(T.kind)+(null!=P?` "${P}"`:"")}function hi(T){return qt(T)?`"${T}"`:T}const Ft=5;function it(T,P){const[W,se]=P?[T,P]:[void 0,T];let me=" Did you mean ";W&&(me+=W+" ");const Fe=se.map(wn=>`"${wn}"`);switch(Fe.length){case 0:return"";case 1:return me+Fe[0]+"?";case 2:return me+Fe[0]+" or "+Fe[1]+"?"}const gt=Fe.slice(0,Ft),Bt=gt.pop();return me+gt.join(", ")+", or "+Bt+"?"}function sn(T){return T}function Ve(T,P){const W=Object.create(null);for(const se of T)W[P(se)]=se;return W}function He(T,P,W){const se=Object.create(null);for(const me of T)se[P(me)]=W(me);return se}function mt(T,P){const W=Object.create(null);for(const se of Object.keys(T))W[se]=P(T[se],se);return W}function bt(T,P){let W=0,se=0;for(;W<T.length&&se<P.length;){let me=T.charCodeAt(W),Fe=P.charCodeAt(se);if(Sn(me)&&Sn(Fe)){let gt=0;do{++W,gt=10*gt+me-nn,me=T.charCodeAt(W)}while(Sn(me)&>>0);let Bt=0;do{++se,Bt=10*Bt+Fe-nn,Fe=P.charCodeAt(se)}while(Sn(Fe)&&Bt>0);if(gt<Bt)return-1;if(gt>Bt)return 1}else{if(me<Fe)return-1;if(me>Fe)return 1;++W,++se}}return T.length-P.length}const nn=48,Jn=57;function Sn(T){return!isNaN(T)&&nn<=T&&T<=Jn}function _r(T,P){const W=Object.create(null),se=new qr(T),me=Math.floor(.4*T.length)+1;for(const Fe of P){const gt=se.measure(Fe,me);void 0!==gt&&(W[Fe]=gt)}return Object.keys(W).sort((Fe,gt)=>{const Bt=W[Fe]-W[gt];return 0!==Bt?Bt:bt(Fe,gt)})}class qr{constructor(P){this._input=P,this._inputLowerCase=P.toLowerCase(),this._inputArray=Bo(this._inputLowerCase),this._rows=[new Array(P.length+1).fill(0),new Array(P.length+1).fill(0),new Array(P.length+1).fill(0)]}measure(P,W){if(this._input===P)return 0;const se=P.toLowerCase();if(this._inputLowerCase===se)return 1;let me=Bo(se),Fe=this._inputArray;if(me.length<Fe.length){const yi=me;me=Fe,Fe=yi}const gt=me.length,Bt=Fe.length;if(gt-Bt>W)return;const wn=this._rows;for(let yi=0;yi<=Bt;yi++)wn[0][yi]=yi;for(let yi=1;yi<=gt;yi++){const Vi=wn[(yi-1)%3],tr=wn[yi%3];let Wr=tr[0]=yi;for(let Yo=1;Yo<=Bt;Yo++){let pc=Math.min(Vi[Yo]+1,tr[Yo-1]+1,Vi[Yo-1]+(me[yi-1]===Fe[Yo-1]?0:1));yi>1&&Yo>1&&me[yi-1]===Fe[Yo-2]&&me[yi-2]===Fe[Yo-1]&&(pc=Math.min(pc,wn[(yi-2)%3][Yo-2]+1)),pc<Wr&&(Wr=pc),tr[Yo]=pc}if(Wr>W)return}const ei=wn[gt%3][Bt];return ei<=W?ei:void 0}}function Bo(T){const P=T.length,W=new Array(P);for(let se=0;se<P;++se)W[se]=T.charCodeAt(se);return W}function Eo(T){if(null==T)return Object.create(null);if(null===Object.getPrototypeOf(T))return T;const P=Object.create(null);for(const[W,se]of Object.entries(T))P[W]=se;return P}const Ls=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function ol(T){return Va[T.charCodeAt(0)]}const Va=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],Ao=Object.freeze({});function za(T,P,W=en){const se=new Map;for(const Yu of Object.values(Ae))se.set(Yu,Na(P,Yu));let me,yi,Vi,Fe=Array.isArray(T),gt=[T],Bt=-1,wn=[],ei=T;const tr=[],Wr=[];do{Bt++;const Yu=Bt===gt.length,Yf=Yu&&0!==wn.length;if(Yu){if(yi=0===Wr.length?void 0:tr[tr.length-1],ei=Vi,Vi=Wr.pop(),Yf)if(Fe){ei=ei.slice();let vu=0;for(const[rh,Xf]of wn){const Qa=rh-vu;null===Xf?(ei.splice(Qa,1),vu++):ei[Qa]=Xf}}else{ei=Object.defineProperties({},Object.getOwnPropertyDescriptors(ei));for(const[vu,rh]of wn)ei[vu]=rh}Bt=me.index,gt=me.keys,wn=me.edits,Fe=me.inArray,me=me.prev}else if(Vi){if(yi=Fe?Bt:gt[Bt],ei=Vi[yi],null==ei)continue;tr.push(yi)}let bd;if(!Array.isArray(ei)){var Yo,Cl;un(ei)||M(!1,`Invalid AST Node: ${yt(ei)}.`);const vu=Yu?null===(Yo=se.get(ei.kind))||void 0===Yo?void 0:Yo.leave:null===(Cl=se.get(ei.kind))||void 0===Cl?void 0:Cl.enter;if(bd=vu?.call(P,ei,yi,Vi,tr,Wr),bd===Ao)break;if(!1===bd){if(!Yu){tr.pop();continue}}else if(void 0!==bd&&(wn.push([yi,bd]),!Yu)){if(!un(bd)){tr.pop();continue}ei=bd}}var pc;void 0===bd&&Yf&&wn.push([yi,ei]),Yu?tr.pop():(me={inArray:Fe,index:Bt,keys:gt,edits:wn,prev:me},Fe=Array.isArray(ei),gt=Fe?ei:null!==(pc=W[ei.kind])&&void 0!==pc?pc:[],Bt=-1,wn=[],Vi&&Wr.push(Vi),Vi=ei)}while(void 0!==me);return 0!==wn.length?wn[wn.length-1][1]:T}function vl(T){const P=new Array(T.length).fill(null),W=Object.create(null);for(const se of Object.values(Ae)){let me=!1;const Fe=new Array(T.length).fill(void 0),gt=new Array(T.length).fill(void 0);for(let wn=0;wn<T.length;++wn){const{enter:ei,leave:yi}=Na(T[wn],se);me||(me=null!=ei||null!=yi),Fe[wn]=ei,gt[wn]=yi}me&&(W[se]={enter(...wn){const ei=wn[0];for(let Vi=0;Vi<T.length;Vi++)if(null===P[Vi]){var yi;const tr=null===(yi=Fe[Vi])||void 0===yi?void 0:yi.apply(T[Vi],wn);if(!1===tr)P[Vi]=ei;else if(tr===Ao)P[Vi]=Ao;else if(void 0!==tr)return tr}},leave(...wn){const ei=wn[0];for(let Vi=0;Vi<T.length;Vi++)if(null===P[Vi]){var yi;const tr=null===(yi=gt[Vi])||void 0===yi?void 0:yi.apply(T[Vi],wn);if(tr===Ao)P[Vi]=Ao;else if(void 0!==tr&&!1!==tr)return tr}else P[Vi]===ei&&(P[Vi]=null)}})}return W}function Na(T,P){const W=T[P];return"object"==typeof W?W:"function"==typeof W?{enter:W,leave:void 0}:{enter:T.enter,leave:T.leave}}function _l(T,P,W){const{enter:se,leave:me}=Na(T,P);return W?me:se}function gs(T){return za(T,oa)}const oa={Name:{leave:T=>T.value},Variable:{leave:T=>"$"+T.name},Document:{leave:T=>no(T.definitions,"\n\n")},OperationDefinition:{leave(T){const P=Qr("(",no(T.variableDefinitions,", "),")"),W=no([T.operation,no([T.name,P]),no(T.directives," ")]," ");return("query"===W?"":W+" ")+T.selectionSet}},VariableDefinition:{leave:({variable:T,type:P,defaultValue:W,directives:se})=>T+": "+P+Qr(" = ",W)+Qr(" ",no(se," "))},SelectionSet:{leave:({selections:T})=>xl(T)},Field:{leave({alias:T,name:P,arguments:W,directives:se,selectionSet:me}){const Fe=Qr("",T,": ")+P;let gt=Fe+Qr("(",no(W,", "),")");return gt.length>80&&(gt=Fe+Qr("(\n",dl(no(W,"\n")),"\n)")),no([gt,no(se," "),me]," ")}},Argument:{leave:({name:T,value:P})=>T+": "+P},FragmentSpread:{leave:({name:T,directives:P})=>"..."+T+Qr(" ",no(P," "))},InlineFragment:{leave:({typeCondition:T,directives:P,selectionSet:W})=>no(["...",Qr("on ",T),no(P," "),W]," ")},FragmentDefinition:{leave:({name:T,typeCondition:P,variableDefinitions:W,directives:se,selectionSet:me})=>`fragment ${T}${Qr("(",no(W,", "),")")} on ${P} ${Qr("",no(se," ")," ")}`+me},IntValue:{leave:({value:T})=>T},FloatValue:{leave:({value:T})=>T},StringValue:{leave:({value:T,block:P})=>P?ji(T):function Ro(T){return`"${T.replace(Ls,ol)}"`}(T)},BooleanValue:{leave:({value:T})=>T?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:T})=>T},ListValue:{leave:({values:T})=>"["+no(T,", ")+"]"},ObjectValue:{leave:({fields:T})=>"{"+no(T,", ")+"}"},ObjectField:{leave:({name:T,value:P})=>T+": "+P},Directive:{leave:({name:T,arguments:P})=>"@"+T+Qr("(",no(P,", "),")")},NamedType:{leave:({name:T})=>T},ListType:{leave:({type:T})=>"["+T+"]"},NonNullType:{leave:({type:T})=>T+"!"},SchemaDefinition:{leave:({description:T,directives:P,operationTypes:W})=>Qr("",T,"\n")+no(["schema",no(P," "),xl(W)]," ")},OperationTypeDefinition:{leave:({operation:T,type:P})=>T+": "+P},ScalarTypeDefinition:{leave:({description:T,name:P,directives:W})=>Qr("",T,"\n")+no(["scalar",P,no(W," ")]," ")},ObjectTypeDefinition:{leave:({description:T,name:P,interfaces:W,directives:se,fields:me})=>Qr("",T,"\n")+no(["type",P,Qr("implements ",no(W," & ")),no(se," "),xl(me)]," ")},FieldDefinition:{leave:({description:T,name:P,arguments:W,type:se,directives:me})=>Qr("",T,"\n")+P+(Ya(W)?Qr("(\n",dl(no(W,"\n")),"\n)"):Qr("(",no(W,", "),")"))+": "+se+Qr(" ",no(me," "))},InputValueDefinition:{leave:({description:T,name:P,type:W,defaultValue:se,directives:me})=>Qr("",T,"\n")+no([P+": "+W,Qr("= ",se),no(me," ")]," ")},InterfaceTypeDefinition:{leave:({description:T,name:P,interfaces:W,directives:se,fields:me})=>Qr("",T,"\n")+no(["interface",P,Qr("implements ",no(W," & ")),no(se," "),xl(me)]," ")},UnionTypeDefinition:{leave:({description:T,name:P,directives:W,types:se})=>Qr("",T,"\n")+no(["union",P,no(W," "),Qr("= ",no(se," | "))]," ")},EnumTypeDefinition:{leave:({description:T,name:P,directives:W,values:se})=>Qr("",T,"\n")+no(["enum",P,no(W," "),xl(se)]," ")},EnumValueDefinition:{leave:({description:T,name:P,directives:W})=>Qr("",T,"\n")+no([P,no(W," ")]," ")},InputObjectTypeDefinition:{leave:({description:T,name:P,directives:W,fields:se})=>Qr("",T,"\n")+no(["input",P,no(W," "),xl(se)]," ")},DirectiveDefinition:{leave:({description:T,name:P,arguments:W,repeatable:se,locations:me})=>Qr("",T,"\n")+"directive @"+P+(Ya(W)?Qr("(\n",dl(no(W,"\n")),"\n)"):Qr("(",no(W,", "),")"))+(se?" repeatable":"")+" on "+no(me," | ")},SchemaExtension:{leave:({directives:T,operationTypes:P})=>no(["extend schema",no(T," "),xl(P)]," ")},ScalarTypeExtension:{leave:({name:T,directives:P})=>no(["extend scalar",T,no(P," ")]," ")},ObjectTypeExtension:{leave:({name:T,interfaces:P,directives:W,fields:se})=>no(["extend type",T,Qr("implements ",no(P," & ")),no(W," "),xl(se)]," ")},InterfaceTypeExtension:{leave:({name:T,interfaces:P,directives:W,fields:se})=>no(["extend interface",T,Qr("implements ",no(P," & ")),no(W," "),xl(se)]," ")},UnionTypeExtension:{leave:({name:T,directives:P,types:W})=>no(["extend union",T,no(P," "),Qr("= ",no(W," | "))]," ")},EnumTypeExtension:{leave:({name:T,directives:P,values:W})=>no(["extend enum",T,no(P," "),xl(W)]," ")},InputObjectTypeExtension:{leave:({name:T,directives:P,fields:W})=>no(["extend input",T,no(P," "),xl(W)]," ")}};function no(T,P=""){var W;return null!==(W=T?.filter(se=>se).join(P))&&void 0!==W?W:""}function xl(T){return Qr("{\n",dl(no(T,"\n")),"\n}")}function Qr(T,P,W=""){return null!=P&&""!==P?T+P+W:""}function dl(T){return Qr(" ",T.replace(/\n/g,"\n "))}function Ya(T){var P;return null!==(P=T?.some(W=>W.includes("\n")))&&void 0!==P&&P}function Lo(T,P){switch(T.kind){case Ae.NULL:return null;case Ae.INT:return parseInt(T.value,10);case Ae.FLOAT:return parseFloat(T.value);case Ae.STRING:case Ae.ENUM:case Ae.BOOLEAN:return T.value;case Ae.LIST:return T.values.map(W=>Lo(W,P));case Ae.OBJECT:return He(T.fields,W=>W.name.value,W=>Lo(W.value,P));case Ae.VARIABLE:return P?.[T.name.value]}}function ko(T){if(null!=T||M(!1,"Must provide name."),"string"==typeof T||M(!1,"Expected name to be a string."),0===T.length)throw new le("Expected name to be a non-empty string.");for(let P=1;P<T.length;++P)if(!It(T.charCodeAt(P)))throw new le(`Names must only contain [_a-zA-Z0-9] but "${T}" does not.`);if(!Wt(T.charCodeAt(0)))throw new le(`Names must start with [_a-zA-Z] but "${T}" does not.`);return T}function jt(T){if("true"===T||"false"===T||"null"===T)throw new le(`Enum values cannot be named: ${T}`);return ko(T)}function In(T){return jn(T)||Ui(T)||er(T)||Tt(T)||Tn(T)||Un(T)||Wi(T)||Li(T)}function Rt(T){if(!In(T))throw new Error(`Expected ${yt(T)} to be a GraphQL type.`);return T}function jn(T){return Mn(T,la)}function Fi(T){if(!jn(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Scalar type.`);return T}function Ui(T){return Mn(T,pl)}function ar(T){if(!Ui(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Object type.`);return T}function er(T){return Mn(T,Il)}function Or(T){if(!er(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Interface type.`);return T}function Tt(T){return Mn(T,Xa)}function cn(T){if(!Tt(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Union type.`);return T}function Tn(T){return Mn(T,yl)}function Ri(T){if(!Tn(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Enum type.`);return T}function Un(T){return Mn(T,Aa)}function Yi(T){if(!Un(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Input Object type.`);return T}function Wi(T){return Mn(T,ts)}function fr(T){if(!Wi(T))throw new Error(`Expected ${yt(T)} to be a GraphQL List type.`);return T}function Li(T){return Mn(T,wo)}function Vo(T){if(!Li(T))throw new Error(`Expected ${yt(T)} to be a GraphQL Non-Null type.`);return T}function vr(T){return jn(T)||Tn(T)||Un(T)||ea(T)&&vr(T.ofType)}function Mo(T){if(!vr(T))throw new Error(`Expected ${yt(T)} to be a GraphQL input type.`);return T}function ks(T){return jn(T)||Ui(T)||er(T)||Tt(T)||Tn(T)||ea(T)&&ks(T.ofType)}function Jo(T){if(!ks(T))throw new Error(`Expected ${yt(T)} to be a GraphQL output type.`);return T}function $s(T){return jn(T)||Tn(T)}function Js(T){if(!$s(T))throw new Error(`Expected ${yt(T)} to be a GraphQL leaf type.`);return T}function ds(T){return Ui(T)||er(T)||Tt(T)}function Ws(T){if(!ds(T))throw new Error(`Expected ${yt(T)} to be a GraphQL composite type.`);return T}function es(T){return er(T)||Tt(T)}function Ma(T){if(!es(T))throw new Error(`Expected ${yt(T)} to be a GraphQL abstract type.`);return T}class ts{constructor(P){In(P)||M(!1,`Expected ${yt(P)} to be a GraphQL type.`),this.ofType=P}get[Symbol.toStringTag](){return"GraphQLList"}toString(){return"["+String(this.ofType)+"]"}toJSON(){return this.toString()}}class wo{constructor(P){sl(P)||M(!1,`Expected ${yt(P)} to be a GraphQL nullable type.`),this.ofType=P}get[Symbol.toStringTag](){return"GraphQLNonNull"}toString(){return String(this.ofType)+"!"}toJSON(){return this.toString()}}function ea(T){return Wi(T)||Li(T)}function ga(T){if(!ea(T))throw new Error(`Expected ${yt(T)} to be a GraphQL wrapping type.`);return T}function sl(T){return In(T)&&!Li(T)}function fl(T){if(!sl(T))throw new Error(`Expected ${yt(T)} to be a GraphQL nullable type.`);return T}function Ia(T){if(T)return Li(T)?T.ofType:T}function al(T){return jn(T)||Ui(T)||er(T)||Tt(T)||Tn(T)||Un(T)}function Kc(T){if(!al(T))throw new Error(`Expected ${yt(T)} to be a GraphQL named type.`);return T}function wa(T){if(T){let P=T;for(;ea(P);)P=P.ofType;return P}}function Sl(T){return"function"==typeof T?T():T}function qc(T){return"function"==typeof T?T():T}class la{constructor(P){var W,se,me,Fe;const gt=null!==(W=P.parseValue)&&void 0!==W?W:sn;this.name=ko(P.name),this.description=P.description,this.specifiedByURL=P.specifiedByURL,this.serialize=null!==(se=P.serialize)&&void 0!==se?se:sn,this.parseValue=gt,this.parseLiteral=null!==(me=P.parseLiteral)&&void 0!==me?me:(Bt,wn)=>gt(Lo(Bt,wn)),this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(Fe=P.extensionASTNodes)&&void 0!==Fe?Fe:[],null==P.specifiedByURL||"string"==typeof P.specifiedByURL||M(!1,`${this.name} must provide "specifiedByURL" as a string, but got: ${yt(P.specifiedByURL)}.`),null==P.serialize||"function"==typeof P.serialize||M(!1,`${this.name} must provide "serialize" function. If this custom Scalar is also used as an input type, ensure "parseValue" and "parseLiteral" functions are also provided.`),P.parseLiteral&&("function"==typeof P.parseValue&&"function"==typeof P.parseLiteral||M(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`))}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class pl{constructor(P){var W;this.name=ko(P.name),this.description=P.description,this.isTypeOf=P.isTypeOf,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this._fields=()=>Ec(P),this._interfaces=()=>Sc(P),null==P.isTypeOf||"function"==typeof P.isTypeOf||M(!1,`${this.name} must provide "isTypeOf" as a function, but got: ${yt(P.isTypeOf)}.`)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ec(this.getFields()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Sc(T){var P;const W=Sl(null!==(P=T.interfaces)&&void 0!==P?P:[]);return Array.isArray(W)||M(!1,`${T.name} interfaces must be an Array or a function which returns an Array.`),W}function Ec(T){const P=qc(T.fields);return ql(P)||M(!1,`${T.name} fields must be an object with field names as keys or a function which returns such an object.`),mt(P,(W,se)=>{var me;ql(W)||M(!1,`${T.name}.${se} field config must be an object.`),null==W.resolve||"function"==typeof W.resolve||M(!1,`${T.name}.${se} field resolver must be a function if provided, but got: ${yt(W.resolve)}.`);const Fe=null!==(me=W.args)&&void 0!==me?me:{};return ql(Fe)||M(!1,`${T.name}.${se} args must be an object with argument names as keys.`),{name:ko(se),description:W.description,type:W.type,args:Qc(Fe),resolve:W.resolve,subscribe:W.subscribe,deprecationReason:W.deprecationReason,extensions:Eo(W.extensions),astNode:W.astNode}})}function Qc(T){return Object.entries(T).map(([P,W])=>({name:ko(P),description:W.description,type:W.type,defaultValue:W.defaultValue,deprecationReason:W.deprecationReason,extensions:Eo(W.extensions),astNode:W.astNode}))}function ql(T){return ie(T)&&!Array.isArray(T)}function ec(T){return mt(T,P=>({description:P.description,type:P.type,args:Yc(P.args),resolve:P.resolve,subscribe:P.subscribe,deprecationReason:P.deprecationReason,extensions:P.extensions,astNode:P.astNode}))}function Yc(T){return He(T,P=>P.name,P=>({description:P.description,type:P.type,defaultValue:P.defaultValue,deprecationReason:P.deprecationReason,extensions:P.extensions,astNode:P.astNode}))}function ca(T){return Li(T.type)&&void 0===T.defaultValue}class Il{constructor(P){var W;this.name=ko(P.name),this.description=P.description,this.resolveType=P.resolveType,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this._fields=Ec.bind(void 0,P),this._interfaces=Sc.bind(void 0,P),null==P.resolveType||"function"==typeof P.resolveType||M(!1,`${this.name} must provide "resolveType" as a function, but got: ${yt(P.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}getInterfaces(){return"function"==typeof this._interfaces&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:ec(this.getFields()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class Xa{constructor(P){var W;this.name=ko(P.name),this.description=P.description,this.resolveType=P.resolveType,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this._types=Rl.bind(void 0,P),null==P.resolveType||"function"==typeof P.resolveType||M(!1,`${this.name} must provide "resolveType" as a function, but got: ${yt(P.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){return"function"==typeof this._types&&(this._types=this._types()),this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function Rl(T){const P=Sl(T.types);return Array.isArray(P)||M(!1,`Must provide Array of types or a function which returns such an array for Union ${T.name}.`),P}class yl{constructor(P){var W;this.name=ko(P.name),this.description=P.description,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this._values="function"==typeof P.values?P.values:Lu(this.name,P.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){return"function"==typeof this._values&&(this._values=Lu(this.name,this._values())),this._values}getValue(P){return null===this._nameLookup&&(this._nameLookup=Ve(this.getValues(),W=>W.name)),this._nameLookup[P]}serialize(P){null===this._valueLookup&&(this._valueLookup=new Map(this.getValues().map(se=>[se.value,se])));const W=this._valueLookup.get(P);if(void 0===W)throw new le(`Enum "${this.name}" cannot represent value: ${yt(P)}`);return W.name}parseValue(P){if("string"!=typeof P){const se=yt(P);throw new le(`Enum "${this.name}" cannot represent non-string value: ${se}.`+sa(this,se))}const W=this.getValue(P);if(null==W)throw new le(`Value "${P}" does not exist in "${this.name}" enum.`+sa(this,P));return W.value}parseLiteral(P,W){if(P.kind!==Ae.ENUM){const me=gs(P);throw new le(`Enum "${this.name}" cannot represent non-enum value: ${me}.`+sa(this,me),{nodes:P})}const se=this.getValue(P.value);if(null==se){const me=gs(P);throw new le(`Value "${me}" does not exist in "${this.name}" enum.`+sa(this,me),{nodes:P})}return se.value}toConfig(){const P=He(this.getValues(),W=>W.name,W=>({description:W.description,value:W.value,deprecationReason:W.deprecationReason,extensions:W.extensions,astNode:W.astNode}));return{name:this.name,description:this.description,values:P,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function sa(T,P){return it("the enum value",_r(P,T.getValues().map(me=>me.name)))}function Lu(T,P){return ql(P)||M(!1,`${T} values must be an object with value names as keys.`),Object.entries(P).map(([W,se])=>(ql(se)||M(!1,`${T}.${W} must refer to an object with a "value" key representing an internal value but got: ${yt(se)}.`),{name:jt(W),description:se.description,value:void 0!==se.value?se.value:W,deprecationReason:se.deprecationReason,extensions:Eo(se.extensions),astNode:se.astNode}))}class Aa{constructor(P){var W,se;this.name=ko(P.name),this.description=P.description,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this.isOneOf=null!==(se=P.isOneOf)&&void 0!==se&&se,this._fields=ku.bind(void 0,P)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){return"function"==typeof this._fields&&(this._fields=this._fields()),this._fields}toConfig(){const P=mt(this.getFields(),W=>({description:W.description,type:W.type,defaultValue:W.defaultValue,deprecationReason:W.deprecationReason,extensions:W.extensions,astNode:W.astNode}));return{name:this.name,description:this.description,fields:P,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function ku(T){const P=qc(T.fields);return ql(P)||M(!1,`${T.name} fields must be an object with field names as keys or a function which returns such an object.`),mt(P,(W,se)=>(!("resolve"in W)||M(!1,`${T.name}.${se} field has a resolve property, but Input Types cannot define resolvers.`),{name:ko(se),description:W.description,type:W.type,defaultValue:W.defaultValue,deprecationReason:W.deprecationReason,extensions:Eo(W.extensions),astNode:W.astNode}))}function Ql(T){return Li(T.type)&&void 0===T.defaultValue}function sc(T,P){return T===P||!!(Li(T)&&Li(P)||Wi(T)&&Wi(P))&&sc(T.ofType,P.ofType)}function ta(T,P,W){return P===W||(Li(W)?!!Li(P)&&ta(T,P.ofType,W.ofType):Li(P)?ta(T,P.ofType,W):Wi(W)?!!Wi(P)&&ta(T,P.ofType,W.ofType):!Wi(P)&&es(W)&&(er(P)||Ui(P))&&T.isSubType(W,P))}function vc(T,P,W){return P===W||(es(P)?es(W)?T.getPossibleTypes(P).some(se=>T.isSubType(W,se)):T.isSubType(P,W):!!es(W)&&T.isSubType(W,P))}const xu=2147483647,Fc=-2147483648,po=new la({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",serialize(T){const P=Ke(T);if("boolean"==typeof P)return P?1:0;let W=P;if("string"==typeof P&&""!==P&&(W=Number(P)),"number"!=typeof W||!Number.isInteger(W))throw new le(`Int cannot represent non-integer value: ${yt(P)}`);if(W>xu||W<Fc)throw new le("Int cannot represent non 32-bit signed integer value: "+yt(P));return W},parseValue(T){if("number"!=typeof T||!Number.isInteger(T))throw new le(`Int cannot represent non-integer value: ${yt(T)}`);if(T>xu||T<Fc)throw new le(`Int cannot represent non 32-bit signed integer value: ${T}`);return T},parseLiteral(T){if(T.kind!==Ae.INT)throw new le(`Int cannot represent non-integer value: ${gs(T)}`,{nodes:T});const P=parseInt(T.value,10);if(P>xu||P<Fc)throw new le(`Int cannot represent non 32-bit signed integer value: ${T.value}`,{nodes:T});return P}}),Ll=new la({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",serialize(T){const P=Ke(T);if("boolean"==typeof P)return P?1:0;let W=P;if("string"==typeof P&&""!==P&&(W=Number(P)),"number"!=typeof W||!Number.isFinite(W))throw new le(`Float cannot represent non numeric value: ${yt(P)}`);return W},parseValue(T){if("number"!=typeof T||!Number.isFinite(T))throw new le(`Float cannot represent non numeric value: ${yt(T)}`);return T},parseLiteral(T){if(T.kind!==Ae.FLOAT&&T.kind!==Ae.INT)throw new le(`Float cannot represent non numeric value: ${gs(T)}`,T);return parseFloat(T.value)}}),Hs=new la({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",serialize(T){const P=Ke(T);if("string"==typeof P)return P;if("boolean"==typeof P)return P?"true":"false";if("number"==typeof P&&Number.isFinite(P))return P.toString();throw new le(`String cannot represent value: ${yt(T)}`)},parseValue(T){if("string"!=typeof T)throw new le(`String cannot represent a non string value: ${yt(T)}`);return T},parseLiteral(T){if(T.kind!==Ae.STRING)throw new le(`String cannot represent a non string value: ${gs(T)}`,{nodes:T});return T.value}}),kl=new la({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",serialize(T){const P=Ke(T);if("boolean"==typeof P)return P;if(Number.isFinite(P))return 0!==P;throw new le(`Boolean cannot represent a non boolean value: ${yt(P)}`)},parseValue(T){if("boolean"!=typeof T)throw new le(`Boolean cannot represent a non boolean value: ${yt(T)}`);return T},parseLiteral(T){if(T.kind!==Ae.BOOLEAN)throw new le(`Boolean cannot represent a non boolean value: ${gs(T)}`,{nodes:T});return T.value}}),Nc=new la({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',serialize(T){const P=Ke(T);if("string"==typeof P)return P;if(Number.isInteger(P))return String(P);throw new le(`ID cannot represent value: ${yt(T)}`)},parseValue(T){if("string"==typeof T)return T;if("number"==typeof T&&Number.isInteger(T))return T.toString();throw new le(`ID cannot represent value: ${yt(T)}`)},parseLiteral(T){if(T.kind!==Ae.STRING&&T.kind!==Ae.INT)throw new le("ID cannot represent a non-string and non-integer value: "+gs(T),{nodes:T});return T.value}}),fu=Object.freeze([Hs,po,Ll,kl,Nc]);function Rc(T){return fu.some(({name:P})=>T.name===P)}function Ke(T){if(ie(T)){if("function"==typeof T.valueOf){const P=T.valueOf();if(!ie(P))return P}if("function"==typeof T.toJSON)return T.toJSON()}return T}function Se(T){return Mn(T,Ge)}function re(T){if(!Se(T))throw new Error(`Expected ${yt(T)} to be a GraphQL directive.`);return T}class Ge{constructor(P){var W,se;this.name=ko(P.name),this.description=P.description,this.locations=P.locations,this.isRepeatable=null!==(W=P.isRepeatable)&&void 0!==W&&W,this.extensions=Eo(P.extensions),this.astNode=P.astNode,Array.isArray(P.locations)||M(!1,`@${P.name} locations must be an Array.`);const me=null!==(se=P.args)&&void 0!==se?se:{};ie(me)&&!Array.isArray(me)||M(!1,`@${P.name} args must be an object with argument names as keys.`),this.args=Qc(me)}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:Yc(this.args),isRepeatable:this.isRepeatable,extensions:this.extensions,astNode:this.astNode}}toString(){return"@"+this.name}toJSON(){return this.toString()}}const xt=new Ge({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[Pt.FIELD,Pt.FRAGMENT_SPREAD,Pt.INLINE_FRAGMENT],args:{if:{type:new wo(kl),description:"Included when true."}}}),Qt=new Ge({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[Pt.FIELD,Pt.FRAGMENT_SPREAD,Pt.INLINE_FRAGMENT],args:{if:{type:new wo(kl),description:"Skipped when true."}}}),kn="No longer supported",bi=new Ge({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[Pt.FIELD_DEFINITION,Pt.ARGUMENT_DEFINITION,Pt.INPUT_FIELD_DEFINITION,Pt.ENUM_VALUE],args:{reason:{type:Hs,description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",defaultValue:kn}}}),vi=new Ge({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[Pt.SCALAR],args:{url:{type:new wo(Hs),description:"The URL that specifies the behavior of this scalar."}}}),Ci=new Ge({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[Pt.INPUT_OBJECT],args:{}}),Xi=Object.freeze([xt,Qt,bi,vi,Ci]);function $i(T){return Xi.some(({name:P})=>P===T.name)}function Er(T){return"object"==typeof T&&"function"==typeof T?.[Symbol.iterator]}function ai(T,P){if(Li(P)){const W=ai(T,P.ofType);return W?.kind===Ae.NULL?null:W}if(null===T)return{kind:Ae.NULL};if(void 0===T)return null;if(Wi(P)){const W=P.ofType;if(Er(T)){const se=[];for(const me of T){const Fe=ai(me,W);null!=Fe&&se.push(Fe)}return{kind:Ae.LIST,values:se}}return ai(T,W)}if(Un(P)){if(!ie(T))return null;const W=[];for(const se of Object.values(P.getFields())){const me=ai(T[se.name],se.type);me&&W.push({kind:Ae.OBJECT_FIELD,name:{kind:Ae.NAME,value:se.name},value:me})}return{kind:Ae.OBJECT,fields:W}}if($s(P)){const W=P.serialize(T);if(null==W)return null;if("boolean"==typeof W)return{kind:Ae.BOOLEAN,value:W};if("number"==typeof W&&Number.isFinite(W)){const se=String(W);return so.test(se)?{kind:Ae.INT,value:se}:{kind:Ae.FLOAT,value:se}}if("string"==typeof W)return Tn(P)?{kind:Ae.ENUM,value:W}:P===Nc&&so.test(W)?{kind:Ae.INT,value:W}:{kind:Ae.STRING,value:W};throw new TypeError(`Cannot convert value to AST: ${yt(W)}.`)}Q(!1,"Unexpected input type: "+yt(P))}const so=/^-?(?:0|[1-9][0-9]*)$/,Fr=new pl({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:Hs,resolve:T=>T.description},types:{description:"A list of all types supported by this server.",type:new wo(new ts(new wo(Vr))),resolve:T=>Object.values(T.getTypeMap())},queryType:{description:"The type that query operations will be rooted at.",type:new wo(Vr),resolve:T=>T.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:Vr,resolve:T=>T.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:Vr,resolve:T=>T.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new wo(new ts(new wo(zr))),resolve:T=>T.getDirectives()}})}),zr=new pl({name:"__Directive",description:"A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document.\n\nIn some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.",fields:()=>({name:{type:new wo(Hs),resolve:T=>T.name},description:{type:Hs,resolve:T=>T.description},isRepeatable:{type:new wo(kl),resolve:T=>T.isRepeatable},locations:{type:new wo(new ts(new wo(ho))),resolve:T=>T.locations},args:{type:new wo(new ts(new wo(Ms))),args:{includeDeprecated:{type:kl,defaultValue:!1}},resolve:(T,{includeDeprecated:P})=>P?T.args:T.args.filter(W=>null==W.deprecationReason)}})}),ho=new yl({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:Pt.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:Pt.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:Pt.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:Pt.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:Pt.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:Pt.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:Pt.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:Pt.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:Pt.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:Pt.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:Pt.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:Pt.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:Pt.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:Pt.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:Pt.UNION,description:"Location adjacent to a union definition."},ENUM:{value:Pt.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:Pt.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:Pt.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:Pt.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}}),Vr=new pl({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name, description and optional `specifiedByURL`, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:()=>({kind:{type:new wo(na),resolve:T=>jn(T)?Xo.SCALAR:Ui(T)?Xo.OBJECT:er(T)?Xo.INTERFACE:Tt(T)?Xo.UNION:Tn(T)?Xo.ENUM:Un(T)?Xo.INPUT_OBJECT:Wi(T)?Xo.LIST:Li(T)?Xo.NON_NULL:void Q(!1,`Unexpected type: "${yt(T)}".`)},name:{type:Hs,resolve:T=>"name"in T?T.name:void 0},description:{type:Hs,resolve:T=>"description"in T?T.description:void 0},specifiedByURL:{type:Hs,resolve:T=>"specifiedByURL"in T?T.specifiedByURL:void 0},fields:{type:new ts(new wo(is)),args:{includeDeprecated:{type:kl,defaultValue:!1}},resolve(T,{includeDeprecated:P}){if(Ui(T)||er(T)){const W=Object.values(T.getFields());return P?W:W.filter(se=>null==se.deprecationReason)}}},interfaces:{type:new ts(new wo(Vr)),resolve(T){if(Ui(T)||er(T))return T.getInterfaces()}},possibleTypes:{type:new ts(new wo(Vr)),resolve(T,P,W,{schema:se}){if(es(T))return se.getPossibleTypes(T)}},enumValues:{type:new ts(new wo(Ds)),args:{includeDeprecated:{type:kl,defaultValue:!1}},resolve(T,{includeDeprecated:P}){if(Tn(T)){const W=T.getValues();return P?W:W.filter(se=>null==se.deprecationReason)}}},inputFields:{type:new ts(new wo(Ms)),args:{includeDeprecated:{type:kl,defaultValue:!1}},resolve(T,{includeDeprecated:P}){if(Un(T)){const W=Object.values(T.getFields());return P?W:W.filter(se=>null==se.deprecationReason)}}},ofType:{type:Vr,resolve:T=>"ofType"in T?T.ofType:void 0},isOneOf:{type:kl,resolve:T=>{if(Un(T))return T.isOneOf}}})}),is=new pl({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:()=>({name:{type:new wo(Hs),resolve:T=>T.name},description:{type:Hs,resolve:T=>T.description},args:{type:new wo(new ts(new wo(Ms))),args:{includeDeprecated:{type:kl,defaultValue:!1}},resolve:(T,{includeDeprecated:P})=>P?T.args:T.args.filter(W=>null==W.deprecationReason)},type:{type:new wo(Vr),resolve:T=>T.type},isDeprecated:{type:new wo(kl),resolve:T=>null!=T.deprecationReason},deprecationReason:{type:Hs,resolve:T=>T.deprecationReason}})}),Ms=new pl({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:()=>({name:{type:new wo(Hs),resolve:T=>T.name},description:{type:Hs,resolve:T=>T.description},type:{type:new wo(Vr),resolve:T=>T.type},defaultValue:{type:Hs,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(T){const{type:P,defaultValue:W}=T,se=ai(W,P);return se?gs(se):null}},isDeprecated:{type:new wo(kl),resolve:T=>null!=T.deprecationReason},deprecationReason:{type:Hs,resolve:T=>T.deprecationReason}})}),Ds=new pl({name:"__EnumValue",description:"One possible value for a given Enum. Enum values are unique values, not a placeholder for a string or numeric value. However an Enum value is returned in a JSON response as a string.",fields:()=>({name:{type:new wo(Hs),resolve:T=>T.name},description:{type:Hs,resolve:T=>T.description},isDeprecated:{type:new wo(kl),resolve:T=>null!=T.deprecationReason},deprecationReason:{type:Hs,resolve:T=>T.deprecationReason}})});var Xo=function(T){return T.SCALAR="SCALAR",T.OBJECT="OBJECT",T.INTERFACE="INTERFACE",T.UNION="UNION",T.ENUM="ENUM",T.INPUT_OBJECT="INPUT_OBJECT",T.LIST="LIST",T.NON_NULL="NON_NULL",T}(Xo||{});const na=new yl({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:Xo.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:Xo.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:Xo.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:Xo.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:Xo.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:Xo.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:Xo.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:Xo.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),zs={name:"__schema",type:new wo(Fr),description:"Access the current type schema of this server.",args:[],resolve:(T,P,W,{schema:se})=>se,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},ya={name:"__type",type:Vr,description:"Request the type information of a single type.",args:[{name:"name",description:void 0,type:new wo(Hs),defaultValue:void 0,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0}],resolve:(T,{name:P},W,{schema:se})=>se.getType(P),deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},Je={name:"__typename",type:new wo(Hs),description:"The name of the current Object type at runtime.",args:[],resolve:(T,P,W,{parentType:se})=>se.name,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},at=Object.freeze([Fr,zr,ho,Vr,is,Ms,Ds,na]);function Oe(T){return at.some(({name:P})=>T.name===P)}function Ct(T){return Mn(T,_i)}function On(T){if(!Ct(T))throw new Error(`Expected ${yt(T)} to be a GraphQL schema.`);return T}class _i{constructor(P){var W,se;this.__validationErrors=!0===P.assumeValid?[]:void 0,ie(P)||M(!1,"Must provide configuration object."),!P.types||Array.isArray(P.types)||M(!1,`"types" must be Array if provided but got: ${yt(P.types)}.`),!P.directives||Array.isArray(P.directives)||M(!1,`"directives" must be Array if provided but got: ${yt(P.directives)}.`),this.description=P.description,this.extensions=Eo(P.extensions),this.astNode=P.astNode,this.extensionASTNodes=null!==(W=P.extensionASTNodes)&&void 0!==W?W:[],this._queryType=P.query,this._mutationType=P.mutation,this._subscriptionType=P.subscription,this._directives=null!==(se=P.directives)&&void 0!==se?se:Xi;const me=new Set(P.types);if(null!=P.types)for(const Fe of P.types)me.delete(Fe),Qn(Fe,me);null!=this._queryType&&Qn(this._queryType,me),null!=this._mutationType&&Qn(this._mutationType,me),null!=this._subscriptionType&&Qn(this._subscriptionType,me);for(const Fe of this._directives)if(Se(Fe))for(const gt of Fe.args)Qn(gt.type,me);Qn(Fr,me),this._typeMap=Object.create(null),this._subTypeMap=Object.create(null),this._implementationsMap=Object.create(null);for(const Fe of me){if(null==Fe)continue;const gt=Fe.name;if(gt||M(!1,"One of the provided types for building the Schema is missing a name."),void 0!==this._typeMap[gt])throw new Error(`Schema must contain uniquely named types but contains multiple types named "${gt}".`);if(this._typeMap[gt]=Fe,er(Fe)){for(const Bt of Fe.getInterfaces())if(er(Bt)){let wn=this._implementationsMap[Bt.name];void 0===wn&&(wn=this._implementationsMap[Bt.name]={objects:[],interfaces:[]}),wn.interfaces.push(Fe)}}else if(Ui(Fe))for(const Bt of Fe.getInterfaces())if(er(Bt)){let wn=this._implementationsMap[Bt.name];void 0===wn&&(wn=this._implementationsMap[Bt.name]={objects:[],interfaces:[]}),wn.objects.push(Fe)}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(P){switch(P){case vn.QUERY:return this.getQueryType();case vn.MUTATION:return this.getMutationType();case vn.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(P){return this.getTypeMap()[P]}getPossibleTypes(P){return Tt(P)?P.getTypes():this.getImplementations(P).objects}getImplementations(P){return this._implementationsMap[P.name]??{objects:[],interfaces:[]}}isSubType(P,W){let se=this._subTypeMap[P.name];if(void 0===se){if(se=Object.create(null),Tt(P))for(const me of P.getTypes())se[me.name]=!0;else{const me=this.getImplementations(P);for(const Fe of me.objects)se[Fe.name]=!0;for(const Fe of me.interfaces)se[Fe.name]=!0}this._subTypeMap[P.name]=se}return void 0!==se[W.name]}getDirectives(){return this._directives}getDirective(P){return this.getDirectives().find(W=>W.name===P)}toConfig(){return{description:this.description,query:this.getQueryType(),mutation:this.getMutationType(),subscription:this.getSubscriptionType(),types:Object.values(this.getTypeMap()),directives:this.getDirectives(),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,assumeValid:void 0!==this.__validationErrors}}}function Qn(T,P){const W=wa(T);if(!P.has(W))if(P.add(W),Tt(W))for(const se of W.getTypes())Qn(se,P);else if(Ui(W)||er(W)){for(const se of W.getInterfaces())Qn(se,P);for(const se of Object.values(W.getFields())){Qn(se.type,P);for(const me of se.args)Qn(me.type,P)}}else if(Un(W))for(const se of Object.values(W.getFields()))Qn(se.type,P);return P}function qi(T){if(On(T),T.__validationErrors)return T.__validationErrors;const P=new fo(T);(function Uo(T){const P=T.schema,W=P.getQueryType();if(W){if(!Ui(W)){var se;T.reportError(`Query root type must be Object type, it cannot be ${yt(W)}.`,null!==(se=Gs(P,vn.QUERY))&&void 0!==se?se:W.astNode)}}else T.reportError("Query root type must be provided.",P.astNode);const me=P.getMutationType();var Fe;me&&!Ui(me)&&T.reportError(`Mutation root type must be Object type if provided, it cannot be ${yt(me)}.`,null!==(Fe=Gs(P,vn.MUTATION))&&void 0!==Fe?Fe:me.astNode);const gt=P.getSubscriptionType();var Bt;gt&&!Ui(gt)&&T.reportError(`Subscription root type must be Object type if provided, it cannot be ${yt(gt)}.`,null!==(Bt=Gs(P,vn.SUBSCRIPTION))&&void 0!==Bt?Bt:gt.astNode)})(P),function ba(T){for(const W of T.schema.getDirectives())if(Se(W)){Za(T,W);for(const se of W.args)if(Za(T,se),vr(se.type)||T.reportError(`The type of @${W.name}(${se.name}:) must be Input Type but got: ${yt(se.type)}.`,se.astNode),ca(se)&&null!=se.deprecationReason){var P;T.reportError(`Required argument @${W.name}(${se.name}:) cannot be deprecated.`,[aa(se.astNode),null===(P=se.astNode)||void 0===P?void 0:P.type])}}else T.reportError(`Expected directive but got: ${yt(W)}.`,W?.astNode)}(P),function Ks(T){const P=function _c(T){const P=Object.create(null),W=[],se=Object.create(null);return function me(Fe){if(P[Fe.name])return;P[Fe.name]=!0,se[Fe.name]=W.length;const gt=Object.values(Fe.getFields());for(const Bt of gt)if(Li(Bt.type)&&Un(Bt.type.ofType)){const wn=Bt.type.ofType,ei=se[wn.name];if(W.push(Bt),void 0===ei)me(wn);else{const yi=W.slice(ei),Vi=yi.map(tr=>tr.name).join(".");T.reportError(`Cannot reference Input Object "${wn.name}" within itself through a series of non-null fields: "${Vi}".`,yi.map(tr=>tr.astNode))}W.pop()}se[Fe.name]=void 0}}(T),W=T.schema.getTypeMap();for(const se of Object.values(W))al(se)?(Oe(se)||Za(T,se),Ui(se)||er(se)?(ac(T,se),lc(T,se)):Tt(se)?da(T,se):Tn(se)?nd(T,se):Un(se)&&(xp(T,se),P(se))):T.reportError(`Expected GraphQL named type but got: ${yt(se)}.`,se.astNode)}(P);const W=P.getErrors();return T.__validationErrors=W,W}function Di(T){const P=qi(T);if(0!==P.length)throw new Error(P.map(W=>W.message).join("\n\n"))}class fo{constructor(P){this._errors=[],this.schema=P}reportError(P,W){const se=Array.isArray(W)?W.filter(Boolean):W;this._errors.push(new le(P,{nodes:se}))}getErrors(){return this._errors}}function Gs(T,P){var W;return null===(W=[T.astNode,...T.extensionASTNodes].flatMap(se=>{var me;return null!==(me=se?.operationTypes)&&void 0!==me?me:[]}).find(se=>se.operation===P))||void 0===W?void 0:W.type}function Za(T,P){P.name.startsWith("__")&&T.reportError(`Name "${P.name}" must not begin with "__", which is reserved by GraphQL introspection.`,P.astNode)}function ac(T,P){const W=Object.values(P.getFields());0===W.length&&T.reportError(`Type ${P.name} must define one or more fields.`,[P.astNode,...P.extensionASTNodes]);for(const gt of W){var se;Za(T,gt),ks(gt.type)||T.reportError(`The type of ${P.name}.${gt.name} must be Output Type but got: ${yt(gt.type)}.`,null===(se=gt.astNode)||void 0===se?void 0:se.type);for(const Bt of gt.args){const wn=Bt.name;var me,Fe;Za(T,Bt),vr(Bt.type)||T.reportError(`The type of ${P.name}.${gt.name}(${wn}:) must be Input Type but got: ${yt(Bt.type)}.`,null===(me=Bt.astNode)||void 0===me?void 0:me.type),ca(Bt)&&null!=Bt.deprecationReason&&T.reportError(`Required argument ${P.name}.${gt.name}(${wn}:) cannot be deprecated.`,[aa(Bt.astNode),null===(Fe=Bt.astNode)||void 0===Fe?void 0:Fe.type])}}}function lc(T,P){const W=Object.create(null);for(const se of P.getInterfaces())er(se)?P!==se?W[se.name]?T.reportError(`Type ${P.name} can only implement ${se.name} once.`,cc(P,se)):(W[se.name]=!0,qd(T,P,se),ou(T,P,se)):T.reportError(`Type ${P.name} cannot implement itself because it would create a circular reference.`,cc(P,se)):T.reportError(`Type ${yt(P)} must only implement Interface types, it cannot implement ${yt(se)}.`,cc(P,se))}function ou(T,P,W){const se=P.getFields();for(const wn of Object.values(W.getFields())){const ei=wn.name,yi=se[ei];if(yi){var me,Fe;ta(T.schema,yi.type,wn.type)||T.reportError(`Interface field ${W.name}.${ei} expects type ${yt(wn.type)} but ${P.name}.${ei} is type ${yt(yi.type)}.`,[null===(me=wn.astNode)||void 0===me?void 0:me.type,null===(Fe=yi.astNode)||void 0===Fe?void 0:Fe.type]);for(const Vi of wn.args){const tr=Vi.name,Wr=yi.args.find(Yo=>Yo.name===tr);var gt,Bt;Wr?sc(Vi.type,Wr.type)||T.reportError(`Interface field argument ${W.name}.${ei}(${tr}:) expects type ${yt(Vi.type)} but ${P.name}.${ei}(${tr}:) is type ${yt(Wr.type)}.`,[null===(gt=Vi.astNode)||void 0===gt?void 0:gt.type,null===(Bt=Wr.astNode)||void 0===Bt?void 0:Bt.type]):T.reportError(`Interface field argument ${W.name}.${ei}(${tr}:) expected but ${P.name}.${ei} does not provide it.`,[Vi.astNode,yi.astNode])}for(const Vi of yi.args){const tr=Vi.name;!wn.args.find(Yo=>Yo.name===tr)&&ca(Vi)&&T.reportError(`Object field ${P.name}.${ei} includes required argument ${tr} that is missing from the Interface field ${W.name}.${ei}.`,[Vi.astNode,wn.astNode])}}else T.reportError(`Interface field ${W.name}.${ei} expected but ${P.name} does not provide it.`,[wn.astNode,P.astNode,...P.extensionASTNodes])}}function qd(T,P,W){const se=P.getInterfaces();for(const me of W.getInterfaces())se.includes(me)||T.reportError(me===P?`Type ${P.name} cannot implement ${W.name} because it would create a circular reference.`:`Type ${P.name} must implement ${me.name} because it is implemented by ${W.name}.`,[...cc(W,me),...cc(P,W)])}function da(T,P){const W=P.getTypes();0===W.length&&T.reportError(`Union type ${P.name} must define one or more member types.`,[P.astNode,...P.extensionASTNodes]);const se=Object.create(null);for(const me of W)se[me.name]?T.reportError(`Union type ${P.name} can only include type ${me.name} once.`,qf(P,me.name)):(se[me.name]=!0,Ui(me)||T.reportError(`Union type ${P.name} can only include Object types, it cannot include ${yt(me)}.`,qf(P,String(me))))}function nd(T,P){const W=P.getValues();0===W.length&&T.reportError(`Enum type ${P.name} must define one or more values.`,[P.astNode,...P.extensionASTNodes]);for(const se of W)Za(T,se)}function xp(T,P){const W=Object.values(P.getFields());0===W.length&&T.reportError(`Input Object type ${P.name} must define one or more fields.`,[P.astNode,...P.extensionASTNodes]);for(const Fe of W){var se,me;Za(T,Fe),vr(Fe.type)||T.reportError(`The type of ${P.name}.${Fe.name} must be Input Type but got: ${yt(Fe.type)}.`,null===(se=Fe.astNode)||void 0===se?void 0:se.type),Ql(Fe)&&null!=Fe.deprecationReason&&T.reportError(`Required input field ${P.name}.${Fe.name} cannot be deprecated.`,[aa(Fe.astNode),null===(me=Fe.astNode)||void 0===me?void 0:me.type]),P.isOneOf&&bl(P,Fe,T)}}function bl(T,P,W){var se;Li(P.type)&&W.reportError(`OneOf input field ${T.name}.${P.name} must be nullable.`,null===(se=P.astNode)||void 0===se?void 0:se.type),void 0!==P.defaultValue&&W.reportError(`OneOf input field ${T.name}.${P.name} cannot have a default value.`,P.astNode)}function cc(T,P){const{astNode:W,extensionASTNodes:se}=T;return(null!=W?[W,...se]:se).flatMap(Fe=>{var gt;return null!==(gt=Fe.interfaces)&&void 0!==gt?gt:[]}).filter(Fe=>Fe.name.value===P.name)}function qf(T,P){const{astNode:W,extensionASTNodes:se}=T;return(null!=W?[W,...se]:se).flatMap(Fe=>{var gt;return null!==(gt=Fe.types)&&void 0!==gt?gt:[]}).filter(Fe=>Fe.name.value===P)}function aa(T){var P;return null==T||null===(P=T.directives)||void 0===P?void 0:P.find(W=>W.name.value===bi.name)}function Tc(T,P){switch(P.kind){case Ae.LIST_TYPE:{const W=Tc(T,P.type);return W&&new ts(W)}case Ae.NON_NULL_TYPE:{const W=Tc(T,P.type);return W&&new wo(W)}case Ae.NAMED_TYPE:return T.getType(P.name.value)}}class Ra{constructor(P,W,se){this._schema=P,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=se??hd,W&&(vr(W)&&this._inputTypeStack.push(W),ds(W)&&this._parentTypeStack.push(W),ks(W)&&this._typeStack.push(W))}get[Symbol.toStringTag](){return"TypeInfo"}getType(){if(this._typeStack.length>0)return this._typeStack[this._typeStack.length-1]}getParentType(){if(this._parentTypeStack.length>0)return this._parentTypeStack[this._parentTypeStack.length-1]}getInputType(){if(this._inputTypeStack.length>0)return this._inputTypeStack[this._inputTypeStack.length-1]}getParentInputType(){if(this._inputTypeStack.length>1)return this._inputTypeStack[this._inputTypeStack.length-2]}getFieldDef(){if(this._fieldDefStack.length>0)return this._fieldDefStack[this._fieldDefStack.length-1]}getDefaultValue(){if(this._defaultValueStack.length>0)return this._defaultValueStack[this._defaultValueStack.length-1]}getDirective(){return this._directive}getArgument(){return this._argument}getEnumValue(){return this._enumValue}enter(P){const W=this._schema;switch(P.kind){case Ae.SELECTION_SET:{const me=wa(this.getType());this._parentTypeStack.push(ds(me)?me:void 0);break}case Ae.FIELD:{const me=this.getParentType();let Fe,gt;me&&(Fe=this._getFieldDef(W,me,P),Fe&&(gt=Fe.type)),this._fieldDefStack.push(Fe),this._typeStack.push(ks(gt)?gt:void 0);break}case Ae.DIRECTIVE:this._directive=W.getDirective(P.name.value);break;case Ae.OPERATION_DEFINITION:{const me=W.getRootType(P.operation);this._typeStack.push(Ui(me)?me:void 0);break}case Ae.INLINE_FRAGMENT:case Ae.FRAGMENT_DEFINITION:{const me=P.typeCondition,Fe=me?Tc(W,me):wa(this.getType());this._typeStack.push(ks(Fe)?Fe:void 0);break}case Ae.VARIABLE_DEFINITION:{const me=Tc(W,P.type);this._inputTypeStack.push(vr(me)?me:void 0);break}case Ae.ARGUMENT:{var se;let me,Fe;const gt=null!==(se=this.getDirective())&&void 0!==se?se:this.getFieldDef();gt&&(me=gt.args.find(Bt=>Bt.name===P.name.value),me&&(Fe=me.type)),this._argument=me,this._defaultValueStack.push(me?me.defaultValue:void 0),this._inputTypeStack.push(vr(Fe)?Fe:void 0);break}case Ae.LIST:{const me=Ia(this.getInputType()),Fe=Wi(me)?me.ofType:me;this._defaultValueStack.push(void 0),this._inputTypeStack.push(vr(Fe)?Fe:void 0);break}case Ae.OBJECT_FIELD:{const me=wa(this.getInputType());let Fe,gt;Un(me)&&(gt=me.getFields()[P.name.value],gt&&(Fe=gt.type)),this._defaultValueStack.push(gt?gt.defaultValue:void 0),this._inputTypeStack.push(vr(Fe)?Fe:void 0);break}case Ae.ENUM:{const me=wa(this.getInputType());let Fe;Tn(me)&&(Fe=me.getValue(P.value)),this._enumValue=Fe;break}}}leave(P){switch(P.kind){case Ae.SELECTION_SET:this._parentTypeStack.pop();break;case Ae.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case Ae.DIRECTIVE:this._directive=null;break;case Ae.OPERATION_DEFINITION:case Ae.INLINE_FRAGMENT:case Ae.FRAGMENT_DEFINITION:this._typeStack.pop();break;case Ae.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case Ae.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Ae.LIST:case Ae.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Ae.ENUM:this._enumValue=null}}}function hd(T,P,W){const se=W.name.value;return se===zs.name&&T.getQueryType()===P?zs:se===ya.name&&T.getQueryType()===P?ya:se===Je.name&&ds(P)?Je:Ui(P)||er(P)?P.getFields()[se]:void 0}function ff(T,P){return{enter(...W){const se=W[0];T.enter(se);const me=Na(P,se.kind).enter;if(me){const Fe=me.apply(P,W);return void 0!==Fe&&(T.leave(se),un(Fe)&&T.enter(Fe)),Fe}},leave(...W){const se=W[0],me=Na(P,se.kind).leave;let Fe;return me&&(Fe=me.apply(P,W)),T.leave(se),Fe}}}function Yt(T){return tc(T)||gd(T)||Pu(T)}function tc(T){return T.kind===Ae.OPERATION_DEFINITION||T.kind===Ae.FRAGMENT_DEFINITION}function Qh(T){return T.kind===Ae.FIELD||T.kind===Ae.FRAGMENT_SPREAD||T.kind===Ae.INLINE_FRAGMENT}function Su(T){return T.kind===Ae.VARIABLE||T.kind===Ae.INT||T.kind===Ae.FLOAT||T.kind===Ae.STRING||T.kind===Ae.BOOLEAN||T.kind===Ae.NULL||T.kind===Ae.ENUM||T.kind===Ae.LIST||T.kind===Ae.OBJECT}function md(T){return Su(T)&&(T.kind===Ae.LIST?T.values.some(md):T.kind===Ae.OBJECT?T.fields.some(P=>md(P.value)):T.kind!==Ae.VARIABLE)}function Ld(T){return T.kind===Ae.NAMED_TYPE||T.kind===Ae.LIST_TYPE||T.kind===Ae.NON_NULL_TYPE}function gd(T){return T.kind===Ae.SCHEMA_DEFINITION||Eu(T)||T.kind===Ae.DIRECTIVE_DEFINITION}function Eu(T){return T.kind===Ae.SCALAR_TYPE_DEFINITION||T.kind===Ae.OBJECT_TYPE_DEFINITION||T.kind===Ae.INTERFACE_TYPE_DEFINITION||T.kind===Ae.UNION_TYPE_DEFINITION||T.kind===Ae.ENUM_TYPE_DEFINITION||T.kind===Ae.INPUT_OBJECT_TYPE_DEFINITION}function Pu(T){return T.kind===Ae.SCHEMA_EXTENSION||Lc(T)}function Lc(T){return T.kind===Ae.SCALAR_TYPE_EXTENSION||T.kind===Ae.OBJECT_TYPE_EXTENSION||T.kind===Ae.INTERFACE_TYPE_EXTENSION||T.kind===Ae.UNION_TYPE_EXTENSION||T.kind===Ae.ENUM_TYPE_EXTENSION||T.kind===Ae.INPUT_OBJECT_TYPE_EXTENSION}function qs(T){return{Document(P){for(const W of P.definitions)tc(W)||T.reportError(new le(`The ${W.kind===Ae.SCHEMA_DEFINITION||W.kind===Ae.SCHEMA_EXTENSION?"schema":'"'+W.name.value+'"'} definition is not executable.`,{nodes:W}));return!1}}}function Xc(T){return{Field(P){const W=T.getParentType();if(W&&!T.getFieldDef()){const me=T.getSchema(),Fe=P.name.value;let gt=it("to use an inline fragment on",function Bu(T,P,W){if(!es(P))return[];const se=new Set,me=Object.create(null);for(const gt of T.getPossibleTypes(P))if(gt.getFields()[W]){se.add(gt),me[gt.name]=1;for(const Bt of gt.getInterfaces()){var Fe;Bt.getFields()[W]&&(se.add(Bt),me[Bt.name]=(null!==(Fe=me[Bt.name])&&void 0!==Fe?Fe:0)+1)}}return[...se].sort((gt,Bt)=>{const wn=me[Bt.name]-me[gt.name];return 0!==wn?wn:er(gt)&&T.isSubType(gt,Bt)?-1:er(Bt)&&T.isSubType(Bt,gt)?1:bt(gt.name,Bt.name)}).map(gt=>gt.name)}(me,W,Fe));""===gt&&(gt=it(function su(T,P){return Ui(T)||er(T)?_r(P,Object.keys(T.getFields())):[]}(W,Fe))),T.reportError(new le(`Cannot query field "${Fe}" on type "${W.name}".`+gt,{nodes:P}))}}}}function Is(T){return{InlineFragment(P){const W=P.typeCondition;if(W){const se=Tc(T.getSchema(),W);if(se&&!ds(se)){const me=gs(W);T.reportError(new le(`Fragment cannot condition on non composite type "${me}".`,{nodes:W}))}}},FragmentDefinition(P){const W=Tc(T.getSchema(),P.typeCondition);if(W&&!ds(W)){const se=gs(P.typeCondition);T.reportError(new le(`Fragment "${P.name.value}" cannot condition on non composite type "${se}".`,{nodes:P.typeCondition}))}}}}function xa(T){return{...vd(T),Argument(P){const W=T.getArgument(),se=T.getFieldDef(),me=T.getParentType();if(!W&&se&&me){const Fe=P.name.value,Bt=_r(Fe,se.args.map(wn=>wn.name));T.reportError(new le(`Unknown argument "${Fe}" on field "${me.name}.${se.name}".`+it(Bt),{nodes:P}))}}}}function vd(T){const P=Object.create(null),W=T.getSchema(),se=W?W.getDirectives():Xi;for(const gt of se)P[gt.name]=gt.args.map(Bt=>Bt.name);const me=T.getDocument().definitions;for(const gt of me)if(gt.kind===Ae.DIRECTIVE_DEFINITION){var Fe;const Bt=null!==(Fe=gt.arguments)&&void 0!==Fe?Fe:[];P[gt.name.value]=Bt.map(wn=>wn.name.value)}return{Directive(gt){const Bt=gt.name.value,wn=P[Bt];if(gt.arguments&&wn)for(const ei of gt.arguments){const yi=ei.name.value;if(!wn.includes(yi)){const Vi=_r(yi,wn);T.reportError(new le(`Unknown argument "${yi}" on directive "@${Bt}".`+it(Vi),{nodes:ei}))}}return!1}}}function Vu(T){const P=Object.create(null),W=T.getSchema(),se=W?W.getDirectives():Xi;for(const Fe of se)P[Fe.name]=Fe.locations;const me=T.getDocument().definitions;for(const Fe of me)Fe.kind===Ae.DIRECTIVE_DEFINITION&&(P[Fe.name.value]=Fe.locations.map(gt=>gt.value));return{Directive(Fe,gt,Bt,wn,ei){const yi=Fe.name.value,Vi=P[yi];if(!Vi)return void T.reportError(new le(`Unknown directive "@${yi}".`,{nodes:Fe}));const tr=function id(T){const P=T[T.length-1];switch("kind"in P||Q(!1),P.kind){case Ae.OPERATION_DEFINITION:return function Sd(T){switch(T){case vn.QUERY:return Pt.QUERY;case vn.MUTATION:return Pt.MUTATION;case vn.SUBSCRIPTION:return Pt.SUBSCRIPTION}}(P.operation);case Ae.FIELD:return Pt.FIELD;case Ae.FRAGMENT_SPREAD:return Pt.FRAGMENT_SPREAD;case Ae.INLINE_FRAGMENT:return Pt.INLINE_FRAGMENT;case Ae.FRAGMENT_DEFINITION:return Pt.FRAGMENT_DEFINITION;case Ae.VARIABLE_DEFINITION:return Pt.VARIABLE_DEFINITION;case Ae.SCHEMA_DEFINITION:case Ae.SCHEMA_EXTENSION:return Pt.SCHEMA;case Ae.SCALAR_TYPE_DEFINITION:case Ae.SCALAR_TYPE_EXTENSION:return Pt.SCALAR;case Ae.OBJECT_TYPE_DEFINITION:case Ae.OBJECT_TYPE_EXTENSION:return Pt.OBJECT;case Ae.FIELD_DEFINITION:return Pt.FIELD_DEFINITION;case Ae.INTERFACE_TYPE_DEFINITION:case Ae.INTERFACE_TYPE_EXTENSION:return Pt.INTERFACE;case Ae.UNION_TYPE_DEFINITION:case Ae.UNION_TYPE_EXTENSION:return Pt.UNION;case Ae.ENUM_TYPE_DEFINITION:case Ae.ENUM_TYPE_EXTENSION:return Pt.ENUM;case Ae.ENUM_VALUE_DEFINITION:return Pt.ENUM_VALUE;case Ae.INPUT_OBJECT_TYPE_DEFINITION:case Ae.INPUT_OBJECT_TYPE_EXTENSION:return Pt.INPUT_OBJECT;case Ae.INPUT_VALUE_DEFINITION:{const W=T[T.length-3];return"kind"in W||Q(!1),W.kind===Ae.INPUT_OBJECT_TYPE_DEFINITION?Pt.INPUT_FIELD_DEFINITION:Pt.ARGUMENT_DEFINITION}default:Q(!1,"Unexpected kind: "+yt(P.kind))}}(ei);tr&&!Vi.includes(tr)&&T.reportError(new le(`Directive "@${yi}" may not be used on ${tr}.`,{nodes:Fe}))}}}function pu(T){return{FragmentSpread(P){const W=P.name.value;T.getFragment(W)||T.reportError(new le(`Unknown fragment "${W}".`,{nodes:P.name}))}}}function hu(T){const P=T.getSchema(),W=P?P.getTypeMap():Object.create(null),se=Object.create(null);for(const Fe of T.getDocument().definitions)Eu(Fe)&&(se[Fe.name.value]=!0);const me=[...Object.keys(W),...Object.keys(se)];return{NamedType(Fe,gt,Bt,wn,ei){const yi=Fe.name.value;if(!W[yi]&&!se[yi]){var Vi;const tr=null!==(Vi=ei[2])&&void 0!==Vi?Vi:Bt,Wr=null!=tr&&function Ed(T){return"kind"in T&&(gd(T)||Pu(T))}(tr);if(Wr&&As.includes(yi))return;const Yo=_r(yi,Wr?As.concat(me):me);T.reportError(new le(`Unknown type "${yi}".`+it(Yo),{nodes:Fe}))}}}}const As=[...fu,...at].map(T=>T.name);function kc(T){let P=0;return{Document(W){P=W.definitions.filter(se=>se.kind===Ae.OPERATION_DEFINITION).length},OperationDefinition(W){!W.name&&P>1&&T.reportError(new le("This anonymous operation must be the only defined operation.",{nodes:W}))}}}function El(T){var P,W,se;const me=T.getSchema(),Fe=null!==(P=null!==(W=null!==(se=me?.astNode)&&void 0!==se?se:me?.getQueryType())&&void 0!==W?W:me?.getMutationType())&&void 0!==P?P:me?.getSubscriptionType();let gt=0;return{SchemaDefinition(Bt){Fe?T.reportError(new le("Cannot define a new schema within a schema extension.",{nodes:Bt})):(gt>0&&T.reportError(new le("Must provide only one schema definition.",{nodes:Bt})),++gt)}}}const uc=3;function kd(T){function P(W,se=Object.create(null),me=0){if(W.kind===Ae.FRAGMENT_SPREAD){const Fe=W.name.value;if(!0===se[Fe])return!1;const gt=T.getFragment(Fe);if(!gt)return!1;try{return se[Fe]=!0,P(gt,se,me)}finally{se[Fe]=void 0}}if(W.kind===Ae.FIELD&&("fields"===W.name.value||"interfaces"===W.name.value||"possibleTypes"===W.name.value||"inputFields"===W.name.value)&&++me>=uc)return!0;if("selectionSet"in W&&W.selectionSet)for(const Fe of W.selectionSet.selections)if(P(Fe,se,me))return!0;return!1}return{Field(W){if(("__schema"===W.name.value||"__type"===W.name.value)&&P(W))return T.reportError(new le("Maximum introspection depth exceeded",{nodes:[W]})),!1}}}function Td(T){const P=Object.create(null),W=[],se=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition:Fe=>(me(Fe),!1)};function me(Fe){if(P[Fe.name.value])return;const gt=Fe.name.value;P[gt]=!0;const Bt=T.getFragmentSpreads(Fe.selectionSet);if(0!==Bt.length){se[gt]=W.length;for(const wn of Bt){const ei=wn.name.value,yi=se[ei];if(W.push(wn),void 0===yi){const Vi=T.getFragment(ei);Vi&&me(Vi)}else{const Vi=W.slice(yi),tr=Vi.slice(0,-1).map(Wr=>'"'+Wr.name.value+'"').join(", ");T.reportError(new le(`Cannot spread fragment "${ei}" within itself`+(""!==tr?` via ${tr}.`:"."),{nodes:Vi}))}W.pop()}se[gt]=void 0}}}function Pc(T){let P=Object.create(null);return{OperationDefinition:{enter(){P=Object.create(null)},leave(W){const se=T.getRecursiveVariableUsages(W);for(const{node:me}of se){const Fe=me.name.value;!0!==P[Fe]&&T.reportError(new le(W.name?`Variable "$${Fe}" is not defined by operation "${W.name.value}".`:`Variable "$${Fe}" is not defined.`,{nodes:[me,W]}))}}},VariableDefinition(W){P[W.variable.name.value]=!0}}}function ju(T){const P=[],W=[];return{OperationDefinition:se=>(P.push(se),!1),FragmentDefinition:se=>(W.push(se),!1),Document:{leave(){const se=Object.create(null);for(const me of P)for(const Fe of T.getRecursivelyReferencedFragments(me))se[Fe.name.value]=!0;for(const me of W){const Fe=me.name.value;!0!==se[Fe]&&T.reportError(new le(`Fragment "${Fe}" is never used.`,{nodes:me}))}}}}}function Yl(T){let P=[];return{OperationDefinition:{enter(){P=[]},leave(W){const se=Object.create(null),me=T.getRecursiveVariableUsages(W);for(const{node:Fe}of me)se[Fe.name.value]=!0;for(const Fe of P){const gt=Fe.variable.name.value;!0!==se[gt]&&T.reportError(new le(W.name?`Variable "$${gt}" is never used in operation "${W.name.value}".`:`Variable "$${gt}" is never used.`,{nodes:Fe}))}}},VariableDefinition(W){P.push(W)}}}function Bc(T){switch(T.kind){case Ae.OBJECT:return{...T,fields:pf(T.fields)};case Ae.LIST:return{...T,values:T.values.map(Bc)};case Ae.INT:case Ae.FLOAT:case Ae.STRING:case Ae.BOOLEAN:case Ae.NULL:case Ae.ENUM:case Ae.VARIABLE:return T}}function pf(T){return T.map(P=>({...P,value:Bc(P.value)})).sort((P,W)=>bt(P.name.value,W.name.value))}function hf(T){return Array.isArray(T)?T.map(([P,W])=>`subfields "${P}" conflict because `+hf(W)).join(" and "):T}function _e(T){const P=new Mc,W=new Map;return{SelectionSet(se){const me=function Dt(T,P,W,se,me){const Fe=[],[gt,Bt]=Qo(T,P,se,me);if(function gi(T,P,W,se,me){for(const[Fe,gt]of Object.entries(me))if(gt.length>1)for(let Bt=0;Bt<gt.length;Bt++)for(let wn=Bt+1;wn<gt.length;wn++){const ei=or(T,W,se,!1,Fe,gt[Bt],gt[wn]);ei&&P.push(ei)}}(T,Fe,P,W,gt),0!==Bt.length)for(let wn=0;wn<Bt.length;wn++){Re(T,Fe,P,W,!1,gt,Bt[wn]);for(let ei=wn+1;ei<Bt.length;ei++)tt(T,Fe,P,W,!1,Bt[wn],Bt[ei])}return Fe}(T,W,P,T.getParentType(),se);for(const[[Fe,gt],Bt,wn]of me){const ei=hf(gt);T.reportError(new le(`Fields "${Fe}" conflict because ${ei}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:Bt.concat(wn)}))}}}}function Re(T,P,W,se,me,Fe,gt){const Bt=T.getFragment(gt);if(!Bt)return;const[wn,ei]=ll(T,W,Bt);if(Fe!==wn){rr(T,P,W,se,me,Fe,wn);for(const yi of ei)se.has(yi,gt,me)||(se.add(yi,gt,me),Re(T,P,W,se,me,Fe,yi))}}function tt(T,P,W,se,me,Fe,gt){if(Fe===gt||se.has(Fe,gt,me))return;se.add(Fe,gt,me);const Bt=T.getFragment(Fe),wn=T.getFragment(gt);if(!Bt||!wn)return;const[ei,yi]=ll(T,W,Bt),[Vi,tr]=ll(T,W,wn);rr(T,P,W,se,me,ei,Vi);for(const Wr of tr)tt(T,P,W,se,me,Fe,Wr);for(const Wr of yi)tt(T,P,W,se,me,Wr,gt)}function rr(T,P,W,se,me,Fe,gt){for(const[Bt,wn]of Object.entries(Fe)){const ei=gt[Bt];if(ei)for(const yi of wn)for(const Vi of ei){const tr=or(T,W,se,me,Bt,yi,Vi);tr&&P.push(tr)}}}function or(T,P,W,se,me,Fe,gt){const[Bt,wn,ei]=Fe,[yi,Vi,tr]=gt,Wr=se||Bt!==yi&&Ui(Bt)&&Ui(yi);if(!Wr){const Yf=wn.name.value,bd=Vi.name.value;if(Yf!==bd)return[[me,`"${Yf}" and "${bd}" are different fields`],[wn],[Vi]];if(!function ia(T,P){const W=T.arguments,se=P.arguments;if(void 0===W||0===W.length)return void 0===se||0===se.length;if(void 0===se||0===se.length||W.length!==se.length)return!1;const me=new Map(se.map(({name:Fe,value:gt})=>[Fe.value,gt]));return W.every(Fe=>{const gt=Fe.value,Bt=me.get(Fe.name.value);return void 0!==Bt&&La(gt)===La(Bt)})}(wn,Vi))return[[me,"they have differing arguments"],[wn],[Vi]]}const Yo=ei?.type,Cl=tr?.type;if(Yo&&Cl&&vs(Yo,Cl))return[[me,`they return conflicting types "${yt(Yo)}" and "${yt(Cl)}"`],[wn],[Vi]];const pc=wn.selectionSet,Yu=Vi.selectionSet;if(pc&&Yu){const Yf=function mn(T,P,W,se,me,Fe,gt,Bt){const wn=[],[ei,yi]=Qo(T,P,me,Fe),[Vi,tr]=Qo(T,P,gt,Bt);rr(T,wn,P,W,se,ei,Vi);for(const Wr of tr)Re(T,wn,P,W,se,ei,Wr);for(const Wr of yi)Re(T,wn,P,W,se,Vi,Wr);for(const Wr of yi)for(const Yo of tr)tt(T,wn,P,W,se,Wr,Yo);return wn}(T,P,W,Wr,wa(Yo),pc,wa(Cl),Yu);return function $o(T,P,W,se){if(T.length>0)return[[P,T.map(([me])=>me)],[W,...T.map(([,me])=>me).flat()],[se,...T.map(([,,me])=>me).flat()]]}(Yf,me,wn,Vi)}}function La(T){return gs(Bc(T))}function vs(T,P){return Wi(T)?!Wi(P)||vs(T.ofType,P.ofType):!!Wi(P)||(Li(T)?!Li(P)||vs(T.ofType,P.ofType):!!Li(P)||!(!$s(T)&&!$s(P))&&T!==P)}function Qo(T,P,W,se){const me=P.get(se);if(me)return me;const Fe=Object.create(null),gt=Object.create(null);Sa(T,W,se,Fe,gt);const Bt=[Fe,Object.keys(gt)];return P.set(se,Bt),Bt}function ll(T,P,W){const se=P.get(W.selectionSet);if(se)return se;const me=Tc(T.getSchema(),W.typeCondition);return Qo(T,P,me,W.selectionSet)}function Sa(T,P,W,se,me){for(const Fe of W.selections)switch(Fe.kind){case Ae.FIELD:{const gt=Fe.name.value;let Bt;(Ui(P)||er(P))&&(Bt=P.getFields()[gt]);const wn=Fe.alias?Fe.alias.value:gt;se[wn]||(se[wn]=[]),se[wn].push([P,Fe,Bt]);break}case Ae.FRAGMENT_SPREAD:me[Fe.name.value]=!0;break;case Ae.INLINE_FRAGMENT:{const gt=Fe.typeCondition,Bt=gt?Tc(T.getSchema(),gt):P;Sa(T,Bt,Fe.selectionSet,se,me);break}}}class Mc{constructor(){this._data=new Map}has(P,W,se){var me;const[Fe,gt]=P<W?[P,W]:[W,P],Bt=null===(me=this._data.get(Fe))||void 0===me?void 0:me.get(gt);return void 0!==Bt&&(!!se||se===Bt)}add(P,W,se){const[me,Fe]=P<W?[P,W]:[W,P],gt=this._data.get(me);void 0===gt?this._data.set(me,new Map([[Fe,se]])):gt.set(Fe,se)}}function yc(T){return{InlineFragment(P){const W=T.getType(),se=T.getParentType();if(ds(W)&&ds(se)&&!vc(T.getSchema(),W,se)){const me=yt(se),Fe=yt(W);T.reportError(new le(`Fragment cannot be spread here as objects of type "${me}" can never be of type "${Fe}".`,{nodes:P}))}},FragmentSpread(P){const W=P.name.value,se=function Ue(T,P){const W=T.getFragment(P);if(W){const se=Tc(T.getSchema(),W.typeCondition);if(ds(se))return se}}(T,W),me=T.getParentType();if(se&&me&&!vc(T.getSchema(),se,me)){const Fe=yt(me),gt=yt(se);T.reportError(new le(`Fragment "${W}" cannot be spread here as objects of type "${Fe}" can never be of type "${gt}".`,{nodes:P}))}}}}function ne(T){const P=T.getSchema(),W=Object.create(null);for(const me of T.getDocument().definitions)Eu(me)&&(W[me.name.value]=me);return{ScalarTypeExtension:se,ObjectTypeExtension:se,InterfaceTypeExtension:se,UnionTypeExtension:se,EnumTypeExtension:se,InputObjectTypeExtension:se};function se(me){const Fe=me.name.value,gt=W[Fe],Bt=P?.getType(Fe);let wn;if(gt?wn=Pe[gt.kind]:Bt&&(wn=function rt(T){return jn(T)?Ae.SCALAR_TYPE_EXTENSION:Ui(T)?Ae.OBJECT_TYPE_EXTENSION:er(T)?Ae.INTERFACE_TYPE_EXTENSION:Tt(T)?Ae.UNION_TYPE_EXTENSION:Tn(T)?Ae.ENUM_TYPE_EXTENSION:Un(T)?Ae.INPUT_OBJECT_TYPE_EXTENSION:void Q(!1,"Unexpected type: "+yt(T))}(Bt)),wn){if(wn!==me.kind){const ei=function Ut(T){switch(T){case Ae.SCALAR_TYPE_EXTENSION:return"scalar";case Ae.OBJECT_TYPE_EXTENSION:return"object";case Ae.INTERFACE_TYPE_EXTENSION:return"interface";case Ae.UNION_TYPE_EXTENSION:return"union";case Ae.ENUM_TYPE_EXTENSION:return"enum";case Ae.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:Q(!1,"Unexpected kind: "+yt(T))}}(me.kind);T.reportError(new le(`Cannot extend non-${ei} type "${Fe}".`,{nodes:gt?[gt,me]:me}))}}else{const yi=_r(Fe,Object.keys({...W,...P?.getTypeMap()}));T.reportError(new le(`Cannot extend type "${Fe}" because it is not defined.`+it(yi),{nodes:me.name}))}}}const Pe={[Ae.SCALAR_TYPE_DEFINITION]:Ae.SCALAR_TYPE_EXTENSION,[Ae.OBJECT_TYPE_DEFINITION]:Ae.OBJECT_TYPE_EXTENSION,[Ae.INTERFACE_TYPE_DEFINITION]:Ae.INTERFACE_TYPE_EXTENSION,[Ae.UNION_TYPE_DEFINITION]:Ae.UNION_TYPE_EXTENSION,[Ae.ENUM_TYPE_DEFINITION]:Ae.ENUM_TYPE_EXTENSION,[Ae.INPUT_OBJECT_TYPE_DEFINITION]:Ae.INPUT_OBJECT_TYPE_EXTENSION};function Rn(T){return{...Kn(T),Field:{leave(P){var W;const se=T.getFieldDef();if(!se)return!1;const me=new Set(null===(W=P.arguments)||void 0===W?void 0:W.map(Fe=>Fe.name.value));for(const Fe of se.args)if(!me.has(Fe.name)&&ca(Fe)){const gt=yt(Fe.type);T.reportError(new le(`Field "${se.name}" argument "${Fe.name}" of type "${gt}" is required, but it was not provided.`,{nodes:P}))}}}}}function Kn(T){var P;const W=Object.create(null),se=T.getSchema(),me=null!==(P=se?.getDirectives())&&void 0!==P?P:Xi;for(const Bt of me)W[Bt.name]=Ve(Bt.args.filter(ca),wn=>wn.name);const Fe=T.getDocument().definitions;for(const Bt of Fe)if(Bt.kind===Ae.DIRECTIVE_DEFINITION){var gt;const wn=null!==(gt=Bt.arguments)&&void 0!==gt?gt:[];W[Bt.name.value]=Ve(wn.filter(Y),ei=>ei.name.value)}return{Directive:{leave(Bt){const wn=Bt.name.value,ei=W[wn];if(ei){var yi;const Vi=null!==(yi=Bt.arguments)&&void 0!==yi?yi:[],tr=new Set(Vi.map(Wr=>Wr.name.value));for(const[Wr,Yo]of Object.entries(ei))if(!tr.has(Wr)){const Cl=In(Yo.type)?yt(Yo.type):gs(Yo.type);T.reportError(new le(`Directive "@${wn}" argument "${Wr}" of type "${Cl}" is required, but it was not provided.`,{nodes:Bt}))}}}}}}function Y(T){return T.type.kind===Ae.NON_NULL_TYPE&&null==T.defaultValue}function Ce(T){return{Field(P){const W=T.getType(),se=P.selectionSet;if(W)if($s(wa(W))){if(se){const me=P.name.value,Fe=yt(W);T.reportError(new le(`Field "${me}" must not have a selection since type "${Fe}" has no subfields.`,{nodes:se}))}}else if(!se){const me=P.name.value,Fe=yt(W);T.reportError(new le(`Field "${me}" of type "${Fe}" must have a selection of subfields. Did you mean "${me} { ... }"?`,{nodes:P}))}}}}function ue(T){return T.map(P=>"number"==typeof P?"["+P.toString()+"]":"."+P).join("")}function Ie(T,P,W){return{prev:T,key:P,typename:W}}function Ze(T){const P=[];let W=T;for(;W;)P.push(W.key),W=W.prev;return P.reverse()}function kt(T,P,W=rn){return Si(T,P,W,void 0)}function rn(T,P,W){let se="Invalid value "+yt(P);throw T.length>0&&(se+=` at "value${ue(T)}"`),W.message=se+": "+W.message,W}function Si(T,P,W,se){if(Li(P))return null!=T?Si(T,P.ofType,W,se):void W(Ze(se),T,new le(`Expected non-nullable type "${yt(P)}" not to be null.`));if(null==T)return null;if(Wi(P)){const me=P.ofType;return Er(T)?Array.from(T,(Fe,gt)=>{const Bt=Ie(se,gt,void 0);return Si(Fe,me,W,Bt)}):[Si(T,me,W,se)]}if(Un(P)){if(!ie(T))return void W(Ze(se),T,new le(`Expected type "${P.name}" to be an object.`));const me={},Fe=P.getFields();for(const gt of Object.values(Fe)){const Bt=T[gt.name];if(void 0!==Bt)me[gt.name]=Si(Bt,gt.type,W,Ie(se,gt.name,P.name));else if(void 0!==gt.defaultValue)me[gt.name]=gt.defaultValue;else if(Li(gt.type)){const wn=yt(gt.type);W(Ze(se),T,new le(`Field "${gt.name}" of required type "${wn}" was not provided.`))}}for(const gt of Object.keys(T))if(!Fe[gt]){const Bt=_r(gt,Object.keys(P.getFields()));W(Ze(se),T,new le(`Field "${gt}" is not defined by type "${P.name}".`+it(Bt)))}if(P.isOneOf){const gt=Object.keys(me);1!==gt.length&&W(Ze(se),T,new le(`Exactly one key must be specified for OneOf type "${P.name}".`));const Bt=gt[0],wn=me[Bt];null===wn&&W(Ze(se).concat(Bt),wn,new le(`Field "${Bt}" must be non-null.`))}return me}if($s(P)){let me;try{me=P.parseValue(T)}catch(Fe){return void W(Ze(se),T,Fe instanceof le?Fe:new le(`Expected type "${P.name}". `+Fe.message,{originalError:Fe}))}return void 0===me&&W(Ze(se),T,new le(`Expected type "${P.name}".`)),me}Q(!1,"Unexpected input type: "+yt(P))}function oi(T,P,W){if(T){if(T.kind===Ae.VARIABLE){const se=T.name.value;if(null==W||void 0===W[se])return;const me=W[se];return null===me&&Li(P)?void 0:me}if(Li(P))return T.kind===Ae.NULL?void 0:oi(T,P.ofType,W);if(T.kind===Ae.NULL)return null;if(Wi(P)){const se=P.ofType;if(T.kind===Ae.LIST){const Fe=[];for(const gt of T.values)if(Yr(gt,W)){if(Li(se))return;Fe.push(null)}else{const Bt=oi(gt,se,W);if(void 0===Bt)return;Fe.push(Bt)}return Fe}const me=oi(T,se,W);return void 0===me?void 0:[me]}if(Un(P)){if(T.kind!==Ae.OBJECT)return;const se=Object.create(null),me=Ve(T.fields,Fe=>Fe.name.value);for(const Fe of Object.values(P.getFields())){const gt=me[Fe.name];if(!gt||Yr(gt.value,W)){if(void 0!==Fe.defaultValue)se[Fe.name]=Fe.defaultValue;else if(Li(Fe.type))return;continue}const Bt=oi(gt.value,Fe.type,W);if(void 0===Bt)return;se[Fe.name]=Bt}if(P.isOneOf){const Fe=Object.keys(se);if(1!==Fe.length||null===se[Fe[0]])return}return se}if($s(P)){let se;try{se=P.parseLiteral(T,W)}catch{return}return void 0===se?void 0:se}Q(!1,"Unexpected input type: "+yt(P))}}function Yr(T,P){return T.kind===Ae.VARIABLE&&(null==P||void 0===P[T.name.value])}function rs(T,P,W,se){const me=[],Fe=se?.maxErrors;try{const gt=function ls(T,P,W,se){const me={};for(const Fe of P){const gt=Fe.variable.name.value,Bt=Tc(T,Fe.type);if(!vr(Bt)){const ei=gs(Fe.type);se(new le(`Variable "$${gt}" expected value of type "${ei}" which cannot be used as an input type.`,{nodes:Fe.type}));continue}if(!dc(W,gt)){if(Fe.defaultValue)me[gt]=oi(Fe.defaultValue,Bt);else if(Li(Bt)){const ei=yt(Bt);se(new le(`Variable "$${gt}" of required type "${ei}" was not provided.`,{nodes:Fe}))}continue}const wn=W[gt];if(null===wn&&Li(Bt)){const ei=yt(Bt);se(new le(`Variable "$${gt}" of non-null type "${ei}" must not be null.`,{nodes:Fe}))}else me[gt]=kt(wn,Bt,(ei,yi,Vi)=>{let tr=`Variable "$${gt}" got invalid value `+yt(yi);ei.length>0&&(tr+=` at "${gt}${ue(ei)}"`),se(new le(tr+"; "+Vi.message,{nodes:Fe,originalError:Vi}))})}return me}(T,P,W,Bt=>{if(null!=Fe&&me.length>=Fe)throw new le("Too many errors processing variables, error limit reached. Execution aborted.");me.push(Bt)});if(0===me.length)return{coerced:gt}}catch(gt){me.push(gt)}return{errors:me}}function Zo(T,P,W){var se;const me={},gt=Ve(null!==(se=P.arguments)&&void 0!==se?se:[],Bt=>Bt.name.value);for(const Bt of T.args){const wn=Bt.name,ei=Bt.type,yi=gt[wn];if(!yi){if(void 0!==Bt.defaultValue)me[wn]=Bt.defaultValue;else if(Li(ei))throw new le(`Argument "${wn}" of required type "${yt(ei)}" was not provided.`,{nodes:P});continue}const Vi=yi.value;let tr=Vi.kind===Ae.NULL;if(Vi.kind===Ae.VARIABLE){const Yo=Vi.name.value;if(null==W||!dc(W,Yo)){if(void 0!==Bt.defaultValue)me[wn]=Bt.defaultValue;else if(Li(ei))throw new le(`Argument "${wn}" of required type "${yt(ei)}" was provided the variable "$${Yo}" which was not provided a runtime value.`,{nodes:Vi});continue}tr=null==W[Yo]}if(tr&&Li(ei))throw new le(`Argument "${wn}" of non-null type "${yt(ei)}" must not be null.`,{nodes:Vi});const Wr=oi(Vi,ei,W);if(void 0===Wr)throw new le(`Argument "${wn}" has invalid value ${gs(Vi)}.`,{nodes:Vi});me[wn]=Wr}return me}function Hl(T,P,W){var se;const me=null===(se=P.directives)||void 0===se?void 0:se.find(Fe=>Fe.name.value===T.name);if(me)return Zo(T,me,W)}function dc(T,P){return Object.prototype.hasOwnProperty.call(T,P)}function ws(T,P,W,se,me){const Fe=new Map;return Wo(T,P,W,se,me,Fe,new Set),Fe}function Wo(T,P,W,se,me,Fe,gt){for(const Bt of me.selections)switch(Bt.kind){case Ae.FIELD:{if(!sr(W,Bt))continue;const wn=Ic(Bt),ei=Fe.get(wn);void 0!==ei?ei.push(Bt):Fe.set(wn,[Bt]);break}case Ae.INLINE_FRAGMENT:if(!sr(W,Bt)||!ro(T,Bt,se))continue;Wo(T,P,W,se,Bt.selectionSet,Fe,gt);break;case Ae.FRAGMENT_SPREAD:{const wn=Bt.name.value;if(gt.has(wn)||!sr(W,Bt))continue;gt.add(wn);const ei=P[wn];if(!ei||!ro(T,ei,se))continue;Wo(T,P,W,se,ei.selectionSet,Fe,gt);break}}}function sr(T,P){const W=Hl(Qt,P,T);if(!0===W?.if)return!1;const se=Hl(xt,P,T);return!1!==se?.if}function ro(T,P,W){const se=P.typeCondition;if(!se)return!0;const me=Tc(T,se);return me===W||!!es(me)&&T.isSubType(me,W)}function Ic(T){return T.alias?T.alias.value:T.name.value}function Sp(T){return{OperationDefinition(P){if("subscription"===P.operation){const W=T.getSchema(),se=W.getSubscriptionType();if(se){const me=P.name?P.name.value:null,Fe=Object.create(null),gt=T.getDocument(),Bt=Object.create(null);for(const ei of gt.definitions)ei.kind===Ae.FRAGMENT_DEFINITION&&(Bt[ei.name.value]=ei);const wn=ws(W,Bt,Fe,se,P.selectionSet);if(wn.size>1){const Vi=[...wn.values()].slice(1).flat();T.reportError(new le(null!=me?`Subscription "${me}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:Vi}))}for(const ei of wn.values())ei[0].name.value.startsWith("__")&&T.reportError(new le(null!=me?`Subscription "${me}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:ei}))}}}}}function au(T,P){const W=new Map;for(const se of T){const me=P(se),Fe=W.get(me);void 0===Fe?W.set(me,[se]):Fe.push(se)}return W}function Uu(T){return{DirectiveDefinition(se){var me;const Fe=null!==(me=se.arguments)&&void 0!==me?me:[];return W(`@${se.name.value}`,Fe)},InterfaceTypeDefinition:P,InterfaceTypeExtension:P,ObjectTypeDefinition:P,ObjectTypeExtension:P};function P(se){var me;const Fe=se.name.value,gt=null!==(me=se.fields)&&void 0!==me?me:[];for(const wn of gt){var Bt;W(`${Fe}.${wn.name.value}`,null!==(Bt=wn.arguments)&&void 0!==Bt?Bt:[])}return!1}function W(se,me){const Fe=au(me,gt=>gt.name.value);for(const[gt,Bt]of Fe)Bt.length>1&&T.reportError(new le(`Argument "${se}(${gt}:)" can only be defined once.`,{nodes:Bt.map(wn=>wn.name)}));return!1}}function bh(T){return{Field:P,Directive:P};function P(W){var se;const Fe=au(null!==(se=W.arguments)&&void 0!==se?se:[],gt=>gt.name.value);for(const[gt,Bt]of Fe)Bt.length>1&&T.reportError(new le(`There can be only one argument named "${gt}".`,{nodes:Bt.map(wn=>wn.name)}))}}function wv(T){const P=Object.create(null),W=T.getSchema();return{DirectiveDefinition(se){const me=se.name.value;if(null==W||!W.getDirective(me))return P[me]?T.reportError(new le(`There can be only one directive named "@${me}".`,{nodes:[P[me],se.name]})):P[me]=se.name,!1;T.reportError(new le(`Directive "@${me}" already exists in the schema. It cannot be redefined.`,{nodes:se.name}))}}}function op(T){const P=Object.create(null),W=T.getSchema(),se=W?W.getDirectives():Xi;for(const Bt of se)P[Bt.name]=!Bt.isRepeatable;const me=T.getDocument().definitions;for(const Bt of me)Bt.kind===Ae.DIRECTIVE_DEFINITION&&(P[Bt.name.value]=!Bt.repeatable);const Fe=Object.create(null),gt=Object.create(null);return{enter(Bt){if(!("directives"in Bt)||!Bt.directives)return;let wn;if(Bt.kind===Ae.SCHEMA_DEFINITION||Bt.kind===Ae.SCHEMA_EXTENSION)wn=Fe;else if(Eu(Bt)||Lc(Bt)){const ei=Bt.name.value;wn=gt[ei],void 0===wn&&(gt[ei]=wn=Object.create(null))}else wn=Object.create(null);for(const ei of Bt.directives){const yi=ei.name.value;P[yi]&&(wn[yi]?T.reportError(new le(`The directive "@${yi}" can only be used once at this location.`,{nodes:[wn[yi],ei]})):wn[yi]=ei)}}}}function Pd(T){const P=T.getSchema(),W=P?P.getTypeMap():Object.create(null),se=Object.create(null);return{EnumTypeDefinition:me,EnumTypeExtension:me};function me(Fe){var gt;const Bt=Fe.name.value;se[Bt]||(se[Bt]=Object.create(null));const wn=null!==(gt=Fe.values)&&void 0!==gt?gt:[],ei=se[Bt];for(const yi of wn){const Vi=yi.name.value,tr=W[Bt];Tn(tr)&&tr.getValue(Vi)?T.reportError(new le(`Enum value "${Bt}.${Vi}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:yi.name})):ei[Vi]?T.reportError(new le(`Enum value "${Bt}.${Vi}" can only be defined once.`,{nodes:[ei[Vi],yi.name]})):ei[Vi]=yi.name}return!1}}function $u(T){const P=T.getSchema(),W=P?P.getTypeMap():Object.create(null),se=Object.create(null);return{InputObjectTypeDefinition:me,InputObjectTypeExtension:me,InterfaceTypeDefinition:me,InterfaceTypeExtension:me,ObjectTypeDefinition:me,ObjectTypeExtension:me};function me(Fe){var gt;const Bt=Fe.name.value;se[Bt]||(se[Bt]=Object.create(null));const wn=null!==(gt=Fe.fields)&&void 0!==gt?gt:[],ei=se[Bt];for(const yi of wn){const Vi=yi.name.value;Yh(W[Bt],Vi)?T.reportError(new le(`Field "${Bt}.${Vi}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:yi.name})):ei[Vi]?T.reportError(new le(`Field "${Bt}.${Vi}" can only be defined once.`,{nodes:[ei[Vi],yi.name]})):ei[Vi]=yi.name}return!1}}function Yh(T,P){return!!(Ui(T)||er(T)||Un(T))&&null!=T.getFields()[P]}function yg(T){const P=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(W){const se=W.name.value;return P[se]?T.reportError(new le(`There can be only one fragment named "${se}".`,{nodes:[P[se],W.name]})):P[se]=W.name,!1}}}function Qd(T){const P=[];let W=Object.create(null);return{ObjectValue:{enter(){P.push(W),W=Object.create(null)},leave(){const se=P.pop();se||Q(!1),W=se}},ObjectField(se){const me=se.name.value;W[me]?T.reportError(new le(`There can be only one input field named "${me}".`,{nodes:[W[me],se.name]})):W[me]=se.name}}}function xv(T){const P=Object.create(null);return{OperationDefinition(W){const se=W.name;return se&&(P[se.value]?T.reportError(new le(`There can be only one operation named "${se.value}".`,{nodes:[P[se.value],se]})):P[se.value]=se),!1},FragmentDefinition:()=>!1}}function bg(T){const P=T.getSchema(),W=Object.create(null),se=P?{query:P.getQueryType(),mutation:P.getMutationType(),subscription:P.getSubscriptionType()}:{};return{SchemaDefinition:me,SchemaExtension:me};function me(Fe){var gt;const Bt=null!==(gt=Fe.operationTypes)&&void 0!==gt?gt:[];for(const wn of Bt){const ei=wn.operation,yi=W[ei];se[ei]?T.reportError(new le(`Type for ${ei} already defined in the schema. It cannot be redefined.`,{nodes:wn})):yi?T.reportError(new le(`There can be only one ${ei} type in schema.`,{nodes:[yi,wn]})):W[ei]=wn}return!1}}function mf(T){const P=Object.create(null),W=T.getSchema();return{ScalarTypeDefinition:se,ObjectTypeDefinition:se,InterfaceTypeDefinition:se,UnionTypeDefinition:se,EnumTypeDefinition:se,InputObjectTypeDefinition:se};function se(me){const Fe=me.name.value;if(null==W||!W.getType(Fe))return P[Fe]?T.reportError(new le(`There can be only one type named "${Fe}".`,{nodes:[P[Fe],me.name]})):P[Fe]=me.name,!1;T.reportError(new le(`Type "${Fe}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:me.name}))}}function U_(T){return{OperationDefinition(P){var W;const me=au(null!==(W=P.variableDefinitions)&&void 0!==W?W:[],Fe=>Fe.variable.name.value);for(const[Fe,gt]of me)gt.length>1&&T.reportError(new le(`There can be only one variable named "$${Fe}".`,{nodes:gt.map(Bt=>Bt.variable.name)}))}}}function Ch(T){let P={};return{OperationDefinition:{enter(){P={}}},VariableDefinition(W){P[W.variable.name.value]=W},ListValue(W){if(!Wi(Ia(T.getParentInputType())))return Zc(T,W),!1},ObjectValue(W){const se=wa(T.getInputType());if(!Un(se))return Zc(T,W),!1;const me=Ve(W.fields,Fe=>Fe.name.value);for(const Fe of Object.values(se.getFields()))if(!me[Fe.name]&&Ql(Fe)){const Bt=yt(Fe.type);T.reportError(new le(`Field "${se.name}.${Fe.name}" of required type "${Bt}" was not provided.`,{nodes:W}))}se.isOneOf&&function Tu(T,P,W,se,me){var Fe;const gt=Object.keys(se);if(1!==gt.length)return void T.reportError(new le(`OneOf Input Object "${W.name}" must specify exactly one key.`,{nodes:[P]}));const wn=null===(Fe=se[gt[0]])||void 0===Fe?void 0:Fe.value,ei=!wn||wn.kind===Ae.NULL,yi=wn?.kind===Ae.VARIABLE;if(ei)T.reportError(new le(`Field "${W.name}.${gt[0]}" must be non-null.`,{nodes:[P]}));else if(yi){const Vi=wn.name.value;me[Vi].type.kind!==Ae.NON_NULL_TYPE&&T.reportError(new le(`Variable "${Vi}" must be non-nullable to be used for OneOf Input Object "${W.name}".`,{nodes:[P]}))}}(T,W,se,me,P)},ObjectField(W){const se=wa(T.getParentInputType());if(!T.getInputType()&&Un(se)){const Fe=_r(W.name.value,Object.keys(se.getFields()));T.reportError(new le(`Field "${W.name.value}" is not defined by type "${se.name}".`+it(Fe),{nodes:W}))}},NullValue(W){const se=T.getInputType();Li(se)&&T.reportError(new le(`Expected value of type "${yt(se)}", found ${gs(W)}.`,{nodes:W}))},EnumValue:W=>Zc(T,W),IntValue:W=>Zc(T,W),FloatValue:W=>Zc(T,W),StringValue:W=>Zc(T,W),BooleanValue:W=>Zc(T,W)}}function Zc(T,P){const W=T.getInputType();if(!W)return;const se=wa(W);if($s(se))try{if(void 0===se.parseLiteral(P,void 0)){const Fe=yt(W);T.reportError(new le(`Expected value of type "${Fe}", found ${gs(P)}.`,{nodes:P}))}}catch(me){const Fe=yt(W);T.reportError(me instanceof le?me:new le(`Expected value of type "${Fe}", found ${gs(P)}; `+me.message,{nodes:P,originalError:me}))}else{const me=yt(W);T.reportError(new le(`Expected value of type "${me}", found ${gs(P)}.`,{nodes:P}))}}function If(T){return{VariableDefinition(P){const W=Tc(T.getSchema(),P.type);if(void 0!==W&&!vr(W)){const se=P.variable.name.value,me=gs(P.type);T.reportError(new le(`Variable "$${se}" cannot be non-input type "${me}".`,{nodes:P.type}))}}}}function C0(T){let P=Object.create(null);return{OperationDefinition:{enter(){P=Object.create(null)},leave(W){const se=T.getRecursiveVariableUsages(W);for(const{node:me,type:Fe,defaultValue:gt}of se){const Bt=me.name.value,wn=P[Bt];if(wn&&Fe){const ei=T.getSchema(),yi=Tc(ei,wn.type);if(yi&&!Ji(ei,yi,wn.defaultValue,Fe,gt)){const Vi=yt(yi),tr=yt(Fe);T.reportError(new le(`Variable "$${Bt}" of type "${Vi}" used in position expecting type "${tr}".`,{nodes:[wn,me]}))}}}}},VariableDefinition(W){P[W.variable.name.value]=W}}}function Ji(T,P,W,se,me){return Li(se)&&!Li(P)?(null!=W&&W.kind!==Ae.NULL||void 0!==me)&&ta(T,P,se.ofType):ta(T,P,se)}const xr=Object.freeze([kd]),Dh=Object.freeze([qs,xv,kc,Sp,hu,Is,If,Ce,Xc,yg,pu,ju,yc,Td,U_,Pc,Yl,Vu,op,xa,bh,Ch,Rn,C0,_e,Qd,...xr]),D0=Object.freeze([El,bg,mf,Pd,$u,Uu,wv,hu,Vu,op,ne,vd,bh,Qd,Kn]);class $_{constructor(P,W){this._ast=P,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=W}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(P){this._onError(P)}getDocument(){return this._ast}getFragment(P){let W;if(this._fragments)W=this._fragments;else{W=Object.create(null);for(const se of this.getDocument().definitions)se.kind===Ae.FRAGMENT_DEFINITION&&(W[se.name.value]=se);this._fragments=W}return W[P]}getFragmentSpreads(P){let W=this._fragmentSpreads.get(P);if(!W){W=[];const se=[P];let me;for(;me=se.pop();)for(const Fe of me.selections)Fe.kind===Ae.FRAGMENT_SPREAD?W.push(Fe):Fe.selectionSet&&se.push(Fe.selectionSet);this._fragmentSpreads.set(P,W)}return W}getRecursivelyReferencedFragments(P){let W=this._recursivelyReferencedFragments.get(P);if(!W){W=[];const se=Object.create(null),me=[P.selectionSet];let Fe;for(;Fe=me.pop();)for(const gt of this.getFragmentSpreads(Fe)){const Bt=gt.name.value;if(!0!==se[Bt]){se[Bt]=!0;const wn=this.getFragment(Bt);wn&&(W.push(wn),me.push(wn.selectionSet))}}this._recursivelyReferencedFragments.set(P,W)}return W}}class Cg extends $_{constructor(P,W,se){super(P,se),this._schema=W}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}class Sv extends $_{constructor(P,W,se,me){super(W,me),this._schema=P,this._typeInfo=se,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(P){let W=this._variableUsages.get(P);if(!W){const se=[],me=new Ra(this._schema);za(P,ff(me,{VariableDefinition:()=>!1,Variable(Fe){se.push({node:Fe,type:me.getInputType(),defaultValue:me.getDefaultValue()})}})),W=se,this._variableUsages.set(P,W)}return W}getRecursiveVariableUsages(P){let W=this._recursiveVariableUsages.get(P);if(!W){W=this.getVariableUsages(P);for(const se of this.getRecursivelyReferencedFragments(P))W=W.concat(this.getVariableUsages(se));this._recursiveVariableUsages.set(P,W)}return W}getType(){return this._typeInfo.getType()}getParentType(){return this._typeInfo.getParentType()}getInputType(){return this._typeInfo.getInputType()}getParentInputType(){return this._typeInfo.getParentInputType()}getFieldDef(){return this._typeInfo.getFieldDef()}getDirective(){return this._typeInfo.getDirective()}getArgument(){return this._typeInfo.getArgument()}getEnumValue(){return this._typeInfo.getEnumValue()}}function Am(T,P,W=Dh,se,me=new Ra(T)){var Fe;const gt=null!==(Fe=se?.maxErrors)&&void 0!==Fe?Fe:100;P||M(!1,"Must provide document."),Di(T);const Bt=Object.freeze({}),wn=[],ei=new Sv(T,P,me,Vi=>{if(wn.length>=gt)throw wn.push(new le("Too many validation errors, error limit reached. Validation aborted.")),Bt;wn.push(Vi)}),yi=vl(W.map(Vi=>Vi(ei)));try{za(P,ff(me,yi))}catch(Vi){if(Vi!==Bt)throw Vi}return wn}function ja(T,P,W=D0){const se=[],me=new Cg(T,P,gt=>{se.push(gt)});return za(T,vl(W.map(gt=>gt(me)))),se}function Qu(T){return Promise.all(Object.values(T)).then(P=>{const W=Object.create(null);for(const[se,me]of Object.keys(T).entries())W[me]=P[se];return W})}class sp extends Error{constructor(P){super("Unexpected error value: "+yt(P)),this.name="NonErrorThrown",this.thrownValue=P}}function Ep(T,P,W){var se;const me=function Ev(T){return T instanceof Error?T:new sp(T)}(T);return function va(T){return Array.isArray(T.path)}(me)?me:new le(me.message,{nodes:null!==(se=me.nodes)&&void 0!==se?se:P,source:me.source,positions:me.positions,path:W,originalError:me})}const bc=function Yd(T){let P;return function(se,me,Fe){void 0===P&&(P=new WeakMap);let gt=P.get(se);void 0===gt&&(gt=new WeakMap,P.set(se,gt));let Bt=gt.get(me);void 0===Bt&&(Bt=new WeakMap,gt.set(me,Bt));let wn=Bt.get(Fe);return void 0===wn&&(wn=T(se,me,Fe),Bt.set(Fe,wn)),wn}}((T,P,W)=>function Vc(T,P,W,se,me){const Fe=new Map,gt=new Set;for(const Bt of me)Bt.selectionSet&&Wo(T,P,W,se,Bt.selectionSet,Fe,gt);return Fe}(T.schema,T.fragments,T.variableValues,P,W));function Bs(T){arguments.length<2||M(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const{schema:P,document:W,variableValues:se,rootValue:me}=T;Wu(P,W,se);const Fe=zl(T);if(!("schema"in Fe))return{errors:Fe};try{const{operation:gt}=Fe,Bt=function Tp(T,P,W){const se=T.schema.getRootType(P.operation);if(null==se)throw new le(`Schema is not configured to execute ${P.operation} operation.`,{nodes:P});const me=ws(T.schema,T.fragments,T.variableValues,se,P.selectionSet),Fe=void 0;switch(P.operation){case vn.QUERY:return Zd(T,se,W,Fe,me);case vn.MUTATION:return function Mp(T,P,W,se,me){return function Xd(T,P,W){let se=W;for(const me of T)se=X(se)?se.then(Fe=>P(Fe,me)):P(se,me);return se}(me.entries(),(Fe,[gt,Bt])=>{const wn=Ie(se,gt,P.name),ei=Fm(T,P,W,Bt,wn);return void 0===ei?Fe:X(ei)?ei.then(yi=>(Fe[gt]=yi,Fe)):(Fe[gt]=ei,Fe)},Object.create(null))}(T,se,W,Fe,me);case vn.SUBSCRIPTION:return Zd(T,se,W,Fe,me)}}(Fe,gt,me);return X(Bt)?Bt.then(wn=>Om(wn,Fe.errors),wn=>(Fe.errors.push(wn),Om(null,Fe.errors))):Om(Bt,Fe.errors)}catch(gt){return Fe.errors.push(gt),Om(null,Fe.errors)}}function wh(T){const P=Bs(T);if(X(P))throw new Error("GraphQL execution failed to complete synchronously.");return P}function Om(T,P){return 0===P.length?{data:T}:{errors:P,data:T}}function Wu(T,P,W){P||M(!1,"Must provide document."),Di(T),null==W||ie(W)||M(!1,"Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.")}function zl(T){var P,W;const{schema:se,document:me,rootValue:Fe,contextValue:gt,variableValues:Bt,operationName:wn,fieldResolver:ei,typeResolver:yi,subscribeFieldResolver:Vi}=T;let tr;const Wr=Object.create(null);for(const pc of me.definitions)switch(pc.kind){case Ae.OPERATION_DEFINITION:if(null==wn){if(void 0!==tr)return[new le("Must provide operation name if query contains multiple operations.")];tr=pc}else(null===(P=pc.name)||void 0===P?void 0:P.value)===wn&&(tr=pc);break;case Ae.FRAGMENT_DEFINITION:Wr[pc.name.value]=pc}if(!tr)return null!=wn?[new le(`Unknown operation named "${wn}".`)]:[new le("Must provide an operation.")];const Cl=rs(se,null!==(W=tr.variableDefinitions)&&void 0!==W?W:[],Bt??{},{maxErrors:50});return Cl.errors?Cl.errors:{schema:se,fragments:Wr,rootValue:Fe,contextValue:gt,operation:tr,variableValues:Cl.coerced,fieldResolver:ei??Zp,typeResolver:yi??gf,subscribeFieldResolver:Vi??Zp,errors:[]}}function Zd(T,P,W,se,me){const Fe=Object.create(null);let gt=!1;try{for(const[Bt,wn]of me.entries()){const yi=Fm(T,P,W,wn,Ie(se,Bt,P.name));void 0!==yi&&(Fe[Bt]=yi,X(yi)&&(gt=!0))}}catch(Bt){if(gt)return Qu(Fe).finally(()=>{throw Bt});throw Bt}return gt?Qu(Fe):Fe}function Fm(T,P,W,se,me){var Fe;const gt=xh(T.schema,P,se[0]);if(!gt)return;const Bt=gt.type,wn=null!==(Fe=gt.resolve)&&void 0!==Fe?Fe:T.fieldResolver,ei=ap(T,gt,se,P,me);try{const tr=wn(W,Zo(gt,se[0],T.variableValues),T.contextValue,ei);let Wr;return Wr=X(tr)?tr.then(Yo=>_d(T,Bt,se,ei,me,Yo)):_d(T,Bt,se,ei,me,tr),X(Wr)?Wr.then(void 0,Yo=>Af(Ep(Yo,se,Ze(me)),Bt,T)):Wr}catch(yi){return Af(Ep(yi,se,Ze(me)),Bt,T)}}function ap(T,P,W,se,me){return{fieldName:P.name,fieldNodes:W,returnType:P.type,parentType:se,path:me,schema:T.schema,fragments:T.fragments,rootValue:T.rootValue,operation:T.operation,variableValues:T.variableValues}}function Af(T,P,W){if(Li(P))throw T;return W.errors.push(T),null}function _d(T,P,W,se,me,Fe){if(Fe instanceof Error)throw Fe;if(Li(P)){const gt=_d(T,P.ofType,W,se,me,Fe);if(null===gt)throw new Error(`Cannot return null for non-nullable field ${se.parentType.name}.${se.fieldName}.`);return gt}return null==Fe?null:Wi(P)?function Mu(T,P,W,se,me,Fe){if(!Er(Fe))throw new le(`Expected Iterable, but did not find one for field "${se.parentType.name}.${se.fieldName}".`);const gt=P.ofType;let Bt=!1;const wn=Array.from(Fe,(ei,yi)=>{const Vi=Ie(me,yi,void 0);try{let tr;return tr=X(ei)?ei.then(Wr=>_d(T,gt,W,se,Vi,Wr)):_d(T,gt,W,se,Vi,ei),X(tr)?(Bt=!0,tr.then(void 0,Wr=>Af(Ep(Wr,W,Ze(Vi)),gt,T))):tr}catch(tr){return Af(Ep(tr,W,Ze(Vi)),gt,T)}});return Bt?Promise.all(wn):wn}(T,P,W,se,me,Fe):$s(P)?function Jd(T,P){const W=T.serialize(P);if(null==W)throw new Error(`Expected \`${yt(T)}.serialize(${yt(P)})\` to return non-nullable value, returned: ${yt(W)}`);return W}(P,Fe):es(P)?function W_(T,P,W,se,me,Fe){var gt;const ei=(null!==(gt=P.resolveType)&&void 0!==gt?gt:T.typeResolver)(Fe,T.contextValue,se,P);return X(ei)?ei.then(yi=>ns(T,Iu(yi,T,P,W,se,Fe),W,se,me,Fe)):ns(T,Iu(ei,T,P,W,se,Fe),W,se,me,Fe)}(T,P,W,se,me,Fe):Ui(P)?ns(T,P,W,se,me,Fe):void Q(!1,"Cannot complete value of unexpected output type: "+yt(P))}function Iu(T,P,W,se,me,Fe){if(null==T)throw new le(`Abstract type "${W.name}" must resolve to an Object type at runtime for field "${me.parentType.name}.${me.fieldName}". Either the "${W.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,se);if(Ui(T))throw new le("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if("string"!=typeof T)throw new le(`Abstract type "${W.name}" must resolve to an Object type at runtime for field "${me.parentType.name}.${me.fieldName}" with value ${yt(Fe)}, received "${yt(T)}".`);const gt=P.schema.getType(T);if(null==gt)throw new le(`Abstract type "${W.name}" was resolved to a type "${T}" that does not exist inside the schema.`,{nodes:se});if(!Ui(gt))throw new le(`Abstract type "${W.name}" was resolved to a non-object type "${T}".`,{nodes:se});if(!P.schema.isSubType(W,gt))throw new le(`Runtime Object type "${gt.name}" is not a possible type for "${W.name}".`,{nodes:se});return gt}function ns(T,P,W,se,me,Fe){const gt=bc(T,P,W);if(P.isTypeOf){const Bt=P.isTypeOf(Fe,T.contextValue,se);if(X(Bt))return Bt.then(wn=>{if(!wn)throw Hu(P,Fe,W);return Zd(T,P,Fe,me,gt)});if(!Bt)throw Hu(P,Fe,W)}return Zd(T,P,Fe,me,gt)}function Hu(T,P,W){return new le(`Expected value of type "${T.name}" but got: ${yt(P)}.`,{nodes:W})}const gf=function(T,P,W,se){if(ie(T)&&"string"==typeof T.__typename)return T.__typename;const me=W.schema.getPossibleTypes(se),Fe=[];for(let gt=0;gt<me.length;gt++){const Bt=me[gt];if(Bt.isTypeOf){const wn=Bt.isTypeOf(T,P,W);if(X(wn))Fe[gt]=wn;else if(wn)return Bt.name}}return Fe.length?Promise.all(Fe).then(gt=>{for(let Bt=0;Bt<gt.length;Bt++)if(gt[Bt])return me[Bt].name}):void 0},Zp=function(T,P,W,se){if(ie(T)||"function"==typeof T){const me=T[se.fieldName];return"function"==typeof me?T[se.fieldName](P,W,se):me}};function xh(T,P,W){const se=W.name.value;return se===zs.name&&T.getQueryType()===P?zs:se===ya.name&&T.getQueryType()===P?ya:se===Je.name?Je:P.getFields()[se]}function Tv(T){return new Promise(P=>P(Of(T)))}function Md(T){const P=Of(T);if(X(P))throw new Error("GraphQL execution failed to complete synchronously.");return P}function Of(T){arguments.length<2||M(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const{schema:P,source:W,rootValue:se,contextValue:me,variableValues:Fe,operationName:gt,fieldResolver:Bt,typeResolver:wn}=T,ei=qi(P);if(ei.length>0)return{errors:ei};let yi;try{yi=Ti(W)}catch(tr){return{errors:[tr]}}const Vi=Am(P,yi);return Vi.length>0?{errors:Vi}:Bs({schema:P,document:yi,rootValue:se,contextValue:me,variableValues:Fe,operationName:gt,fieldResolver:Bt,typeResolver:wn})}var Qf=S(4523);function w0(T){return"function"==typeof T?.[Symbol.asyncIterator]}function Ip(T){return Mv.apply(this,arguments)}function Mv(){return Mv=(0,Qf.A)(function*(T){arguments.length<2||M(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const P=yield Nm(T);return w0(P)?function r1(T,P){const W=T[Symbol.asyncIterator]();function se(Fe){return me.apply(this,arguments)}function me(){return(me=(0,Qf.A)(function*(Fe){if(Fe.done)return Fe;try{return{value:yield P(Fe.value),done:!1}}catch(gt){if("function"==typeof W.return)try{yield W.return()}catch{}throw gt}})).apply(this,arguments)}return{next:()=>(0,Qf.A)(function*(){return se(yield W.next())})(),return:()=>(0,Qf.A)(function*(){return"function"==typeof W.return?se(yield W.return()):{value:void 0,done:!0}})(),throw:Fe=>(0,Qf.A)(function*(){if("function"==typeof W.throw)return se(yield W.throw(Fe));throw Fe})(),[Symbol.asyncIterator](){return this}}}(P,se=>Bs({...T,rootValue:se})):P}),Mv.apply(this,arguments)}function Nm(){return od.apply(this,arguments)}function od(){return od=(0,Qf.A)(function*(...T){const P=function Xh(T){const P=T[0];return P&&"document"in P?P:{schema:P,document:T[1],rootValue:T[2],contextValue:T[3],variableValues:T[4],operationName:T[5],subscribeFieldResolver:T[6]}}(T),{schema:W,document:se,variableValues:me}=P;Wu(W,se,me);const Fe=zl(P);if(!("schema"in Fe))return{errors:Fe};try{const gt=yield function tD(T){return Iv.apply(this,arguments)}(Fe);if(!w0(gt))throw new Error(`Subscription field must return Async Iterable. Received: ${yt(gt)}.`);return gt}catch(gt){if(gt instanceof le)return{errors:[gt]};throw gt}}),od.apply(this,arguments)}function Iv(){return(Iv=(0,Qf.A)(function*(T){const{schema:P,fragments:W,operation:se,variableValues:me,rootValue:Fe}=T,gt=P.getSubscriptionType();if(null==gt)throw new le("Schema is not configured to execute subscription operation.",{nodes:se});const Bt=ws(P,W,me,gt,se.selectionSet),[wn,ei]=[...Bt.entries()][0],yi=xh(P,gt,ei[0]);if(!yi)throw new le(`The subscription field "${ei[0].name.value}" is not defined.`,{nodes:ei});const Vi=Ie(void 0,wn,gt.name),tr=ap(T,yi,ei,gt,Vi);try{var Wr;const Yo=Zo(yi,ei[0],me),Cl=T.contextValue,Yu=yield(null!==(Wr=yi.subscribe)&&void 0!==Wr?Wr:T.subscribeFieldResolver)(Fe,Yo,Cl,tr);if(Yu instanceof Error)throw Yu;return Yu}catch(Yo){throw Ep(Yo,ei,Ze(Vi))}})).apply(this,arguments)}function mu(T){return{Field(P){const W=T.getFieldDef(),se=W?.deprecationReason;if(W&&null!=se){const me=T.getParentType();null!=me||Q(!1),T.reportError(new le(`The field ${me.name}.${W.name} is deprecated. ${se}`,{nodes:P}))}},Argument(P){const W=T.getArgument(),se=W?.deprecationReason;if(W&&null!=se){const me=T.getDirective();if(null!=me)T.reportError(new le(`Directive "@${me.name}" argument "${W.name}" is deprecated. ${se}`,{nodes:P}));else{const Fe=T.getParentType(),gt=T.getFieldDef();null!=Fe&&null!=gt||Q(!1),T.reportError(new le(`Field "${Fe.name}.${gt.name}" argument "${W.name}" is deprecated. ${se}`,{nodes:P}))}}},ObjectField(P){const W=wa(T.getParentInputType());if(Un(W)){const se=W.getFields()[P.name.value],me=se?.deprecationReason;null!=me&&T.reportError(new le(`The input field ${W.name}.${se.name} is deprecated. ${me}`,{nodes:P}))}},EnumValue(P){const W=T.getEnumValue(),se=W?.deprecationReason;if(W&&null!=se){const me=wa(T.getInputType());null!=me||Q(!1),T.reportError(new le(`The enum value "${me.name}.${W.name}" is deprecated. ${se}`,{nodes:P}))}}}}function Zh(T){return{Field(P){const W=wa(T.getType());W&&Oe(W)&&T.reportError(new le(`GraphQL introspection has been disabled, but the requested query contained the field "${P.name.value}".`,{nodes:P}))}}}function H_(T){const P={descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1,...T},W=P.descriptions?"description":"",se=P.specifiedByUrl?"specifiedByURL":"";function gt(wn){return P.inputValueDeprecation?wn:""}const Bt=P.oneOf?"isOneOf":"";return`\n query IntrospectionQuery {\n __schema {\n ${P.schemaDescription?W:""}\n queryType { name }\n mutationType { name }\n subscriptionType { name }\n types {\n ...FullType\n }\n directives {\n name\n ${W}\n ${P.directiveIsRepeatable?"isRepeatable":""}\n locations\n args${gt("(includeDeprecated: true)")} {\n ...InputValue\n }\n }\n }\n }\n\n fragment FullType on __Type {\n kind\n name\n ${W}\n ${se}\n ${Bt}\n fields(includeDeprecated: true) {\n name\n ${W}\n args${gt("(includeDeprecated: true)")} {\n ...InputValue\n }\n type {\n ...TypeRef\n }\n isDeprecated\n deprecationReason\n }\n inputFields${gt("(includeDeprecated: true)")} {\n ...InputValue\n }\n interfaces {\n ...TypeRef\n }\n enumValues(includeDeprecated: true) {\n name\n ${W}\n isDeprecated\n deprecationReason\n }\n possibleTypes {\n ...TypeRef\n }\n }\n\n fragment InputValue on __InputValue {\n name\n ${W}\n type { ...TypeRef }\n defaultValue\n ${gt("isDeprecated")}\n ${gt("deprecationReason")}\n }\n\n fragment TypeRef on __Type {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n `}function Ff(T,P){let W=null;for(const me of T.definitions)if(me.kind===Ae.OPERATION_DEFINITION){var se;if(null==P){if(W)return null;W=me}else if((null===(se=me.name)||void 0===se?void 0:se.value)===P)return me}return W}function yd(T,P){if("query"===P.operation){const W=T.getQueryType();if(!W)throw new le("Schema does not define the required query root type.",{nodes:P});return W}if("mutation"===P.operation){const W=T.getMutationType();if(!W)throw new le("Schema is not configured for mutations.",{nodes:P});return W}if("subscription"===P.operation){const W=T.getSubscriptionType();if(!W)throw new le("Schema is not configured for subscriptions.",{nodes:P});return W}throw new le("Can only have query, mutation and subscription operations.",{nodes:P})}function Rm(T,P){const me=wh({schema:T,document:Ti(H_({specifiedByUrl:!0,directiveIsRepeatable:!0,schemaDescription:!0,inputValueDeprecation:!0,oneOf:!0,...P}))});return!me.errors&&me.data||Q(!1),me.data}function Lm(T,P){ie(T)&&ie(T.__schema)||M(!1,`Invalid or incomplete introspection result. Ensure that you are passing "data" property of introspection response and no "errors" was returned alongside: ${yt(T)}.`);const W=T.__schema,se=He(W.types,Tr=>Tr.name,Tr=>function tr(Tr){if(null!=Tr&&null!=Tr.name&&null!=Tr.kind)switch(Tr.kind){case Xo.SCALAR:return function Wr(Tr){return new la({name:Tr.name,description:Tr.description,specifiedByURL:Tr.specifiedByURL})}(Tr);case Xo.OBJECT:return function Cl(Tr){return new pl({name:Tr.name,description:Tr.description,interfaces:()=>Yo(Tr),fields:()=>vu(Tr)})}(Tr);case Xo.INTERFACE:return function pc(Tr){return new Il({name:Tr.name,description:Tr.description,interfaces:()=>Yo(Tr),fields:()=>vu(Tr)})}(Tr);case Xo.UNION:return function Yu(Tr){if(!Tr.possibleTypes){const Vs=yt(Tr);throw new Error(`Introspection result missing possibleTypes: ${Vs}.`)}return new Xa({name:Tr.name,description:Tr.description,types:()=>Tr.possibleTypes.map(yi)})}(Tr);case Xo.ENUM:return function Yf(Tr){if(!Tr.enumValues){const Vs=yt(Tr);throw new Error(`Introspection result missing enumValues: ${Vs}.`)}return new yl({name:Tr.name,description:Tr.description,values:He(Tr.enumValues,Vs=>Vs.name,Vs=>({description:Vs.description,deprecationReason:Vs.deprecationReason}))})}(Tr);case Xo.INPUT_OBJECT:return function bd(Tr){if(!Tr.inputFields){const Vs=yt(Tr);throw new Error(`Introspection result missing inputFields: ${Vs}.`)}return new Aa({name:Tr.name,description:Tr.description,fields:()=>Xf(Tr.inputFields),isOneOf:Tr.isOneOf})}(Tr)}const Vs=yt(Tr);throw new Error(`Invalid or incomplete introspection result. Ensure that a full introspection query is used in order to build a client schema: ${Vs}.`)}(Tr));for(const Tr of[...fu,...at])se[Tr.name]&&(se[Tr.name]=Tr);const me=W.queryType?yi(W.queryType):null,Fe=W.mutationType?yi(W.mutationType):null,gt=W.subscriptionType?yi(W.subscriptionType):null,Bt=W.directives?W.directives.map(function Ov(Tr){if(!Tr.args){const Vs=yt(Tr);throw new Error(`Introspection result missing directive args: ${Vs}.`)}if(!Tr.locations){const Vs=yt(Tr);throw new Error(`Introspection result missing directive locations: ${Vs}.`)}return new Ge({name:Tr.name,description:Tr.description,isRepeatable:Tr.isRepeatable,locations:Tr.locations.slice(),args:Xf(Tr.args)})}):[];return new _i({description:W.description,query:me,mutation:Fe,subscription:gt,types:Object.values(se),directives:Bt,assumeValid:P?.assumeValid});function wn(Tr){if(Tr.kind===Xo.LIST){const Vs=Tr.ofType;if(!Vs)throw new Error("Decorated type deeper than introspection query.");return new ts(wn(Vs))}if(Tr.kind===Xo.NON_NULL){const Vs=Tr.ofType;if(!Vs)throw new Error("Decorated type deeper than introspection query.");const lp=wn(Vs);return new wo(fl(lp))}return ei(Tr)}function ei(Tr){const Vs=Tr.name;if(!Vs)throw new Error(`Unknown type reference: ${yt(Tr)}.`);const lp=se[Vs];if(!lp)throw new Error(`Invalid or incomplete schema, unknown type: ${Vs}. Ensure that a full introspection query is used in order to build a client schema.`);return lp}function yi(Tr){return ar(ei(Tr))}function Vi(Tr){return Or(ei(Tr))}function Yo(Tr){if(null===Tr.interfaces&&Tr.kind===Xo.INTERFACE)return[];if(!Tr.interfaces){const Vs=yt(Tr);throw new Error(`Introspection result missing interfaces: ${Vs}.`)}return Tr.interfaces.map(Vi)}function vu(Tr){if(!Tr.fields)throw new Error(`Introspection result missing fields: ${yt(Tr)}.`);return He(Tr.fields,Vs=>Vs.name,rh)}function rh(Tr){const Vs=wn(Tr.type);if(!ks(Vs)){const lp=yt(Vs);throw new Error(`Introspection must provide output type for fields, but received: ${lp}.`)}if(!Tr.args){const lp=yt(Tr);throw new Error(`Introspection result missing field args: ${lp}.`)}return{description:Tr.description,deprecationReason:Tr.deprecationReason,type:Vs,args:Xf(Tr.args)}}function Xf(Tr){return He(Tr,Vs=>Vs.name,Qa)}function Qa(Tr){const Vs=wn(Tr.type);if(!vr(Vs)){const ka=yt(Vs);throw new Error(`Introspection must provide input type for arguments, but received: ${ka}.`)}const lp=null!=Tr.defaultValue?oi(Bi(Tr.defaultValue),Vs):void 0;return{description:Tr.description,type:Vs,defaultValue:lp,deprecationReason:Tr.deprecationReason}}}function Sh(T,P,W){On(T),null!=P&&P.kind===Ae.DOCUMENT||M(!1,"Must provide valid Document AST."),!0!==W?.assumeValid&&!0!==W?.assumeValidSDL&&function rd(T,P){const W=ja(T,P);if(0!==W.length)throw new Error(W.map(se=>se.message).join("\n\n"))}(P,T);const se=T.toConfig(),me=Dg(se,P,W);return se===me?T:new _i(me)}function Dg(T,P,W){var se,me,Fe,gt;const Bt=[],wn=Object.create(null),ei=[];let yi;const Vi=[];for(const Ir of P.definitions)if(Ir.kind===Ae.SCHEMA_DEFINITION)yi=Ir;else if(Ir.kind===Ae.SCHEMA_EXTENSION)Vi.push(Ir);else if(Eu(Ir))Bt.push(Ir);else if(Lc(Ir)){const bs=Ir.name.value,Ko=wn[bs];wn[bs]=Ko?Ko.concat([Ir]):[Ir]}else Ir.kind===Ae.DIRECTIVE_DEFINITION&&ei.push(Ir);if(0===Object.keys(wn).length&&0===Bt.length&&0===ei.length&&0===Vi.length&&null==yi)return T;const tr=Object.create(null);for(const Ir of T.types)tr[Ir.name]=Yf(Ir);for(const Ir of Bt){var Wr;const bs=Ir.name.value;tr[bs]=null!==(Wr=km[bs])&&void 0!==Wr?Wr:Bm(Ir)}const Yo={query:T.query&&pc(T.query),mutation:T.mutation&&pc(T.mutation),subscription:T.subscription&&pc(T.subscription),...yi&&lp([yi]),...lp(Vi)};return{description:null===(se=yi)||void 0===se||null===(me=se.description)||void 0===me?void 0:me.value,...Yo,types:Object.values(tr),directives:[...T.directives.map(function Yu(Ir){const bs=Ir.toConfig();return new Ge({...bs,args:mt(bs.args,Vs)})}),...ei.map(function tf(Ir){var bs;return new Ge({name:Ir.name.value,description:null===(bs=Ir.description)||void 0===bs?void 0:bs.value,locations:Ir.locations.map(({value:Ko})=>Ko),isRepeatable:Ir.repeatable,args:G_(Ir.arguments),astNode:Ir})})],extensions:Object.create(null),astNode:null!==(Fe=yi)&&void 0!==Fe?Fe:T.astNode,extensionASTNodes:T.extensionASTNodes.concat(Vi),assumeValid:null!==(gt=W?.assumeValid)&&void 0!==gt&>};function Cl(Ir){return Wi(Ir)?new ts(Cl(Ir.ofType)):Li(Ir)?new wo(Cl(Ir.ofType)):pc(Ir)}function pc(Ir){return tr[Ir.name]}function Yf(Ir){return Oe(Ir)||Rc(Ir)?Ir:jn(Ir)?function rh(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ko.name])&&void 0!==bs?bs:[];let jc=Ko.specifiedByURL;for(const Ho of Es){var wc;jc=null!==(wc=Jp(Ho))&&void 0!==wc?wc:jc}return new la({...Ko,specifiedByURL:jc,extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):Ui(Ir)?function Xf(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ko.name])&&void 0!==bs?bs:[];return new pl({...Ko,interfaces:()=>[...Ir.getInterfaces().map(pc),...xg(Es)],fields:()=>({...mt(Ko.fields,Tr),...oh(Es)}),extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):er(Ir)?function Qa(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ko.name])&&void 0!==bs?bs:[];return new Il({...Ko,interfaces:()=>[...Ir.getInterfaces().map(pc),...xg(Es)],fields:()=>({...mt(Ko.fields,Tr),...oh(Es)}),extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):Tt(Ir)?function Ov(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ko.name])&&void 0!==bs?bs:[];return new Xa({...Ko,types:()=>[...Ir.getTypes().map(pc),...s1(Es)],extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):Tn(Ir)?function vu(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ir.name])&&void 0!==bs?bs:[];return new yl({...Ko,values:{...Ko.values,...vf(Es)},extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):Un(Ir)?function bd(Ir){var bs;const Ko=Ir.toConfig(),Es=null!==(bs=wn[Ko.name])&&void 0!==bs?bs:[];return new Aa({...Ko,fields:()=>({...mt(Ko.fields,jc=>({...jc,type:Cl(jc.type)})),...S0(Es)}),extensionASTNodes:Ko.extensionASTNodes.concat(Es)})}(Ir):void Q(!1,"Unexpected type: "+yt(Ir))}function Tr(Ir){return{...Ir,type:Cl(Ir.type),args:Ir.args&&mt(Ir.args,Vs)}}function Vs(Ir){return{...Ir,type:Cl(Ir.type)}}function lp(Ir){const bs={};for(const Es of Ir){var Ko;const jc=null!==(Ko=Es.operationTypes)&&void 0!==Ko?Ko:[];for(const wc of jc)bs[wc.operation]=ka(wc.type)}return bs}function ka(Ir){var bs;const Ko=Ir.name.value,Es=null!==(bs=km[Ko])&&void 0!==bs?bs:tr[Ko];if(void 0===Es)throw new Error(`Unknown type: "${Ko}".`);return Es}function Lf(Ir){return Ir.kind===Ae.LIST_TYPE?new ts(Lf(Ir.type)):Ir.kind===Ae.NON_NULL_TYPE?new wo(Lf(Ir.type)):ka(Ir)}function oh(Ir){const bs=Object.create(null);for(const jc of Ir){var Ko;const wc=null!==(Ko=jc.fields)&&void 0!==Ko?Ko:[];for(const Ho of wc){var Es;bs[Ho.name.value]={type:Lf(Ho.type),description:null===(Es=Ho.description)||void 0===Es?void 0:Es.value,args:G_(Ho.arguments),deprecationReason:Nf(Ho),astNode:Ho}}}return bs}function G_(Ir){const bs=Ir??[],Ko=Object.create(null);for(const jc of bs){var Es;const wc=Lf(jc.type);Ko[jc.name.value]={type:wc,description:null===(Es=jc.description)||void 0===Es?void 0:Es.value,defaultValue:oi(jc.defaultValue,wc),deprecationReason:Nf(jc),astNode:jc}}return Ko}function S0(Ir){const bs=Object.create(null);for(const jc of Ir){var Ko;const wc=null!==(Ko=jc.fields)&&void 0!==Ko?Ko:[];for(const Ho of wc){var Es;const cp=Lf(Ho.type);bs[Ho.name.value]={type:cp,description:null===(Es=Ho.description)||void 0===Es?void 0:Es.value,defaultValue:oi(Ho.defaultValue,cp),deprecationReason:Nf(Ho),astNode:Ho}}}return bs}function vf(Ir){const bs=Object.create(null);for(const jc of Ir){var Ko;const wc=null!==(Ko=jc.values)&&void 0!==Ko?Ko:[];for(const Ho of wc){var Es;bs[Ho.name.value]={description:null===(Es=Ho.description)||void 0===Es?void 0:Es.value,deprecationReason:Nf(Ho),astNode:Ho}}}return bs}function xg(Ir){return Ir.flatMap(bs=>{var Ko,Es;return null!==(Ko=null===(Es=bs.interfaces)||void 0===Es?void 0:Es.map(ka))&&void 0!==Ko?Ko:[]})}function s1(Ir){return Ir.flatMap(bs=>{var Ko,Es;return null!==(Ko=null===(Es=bs.types)||void 0===Es?void 0:Es.map(ka))&&void 0!==Ko?Ko:[]})}function Bm(Ir){var bs;const Ko=Ir.name.value,Es=null!==(bs=wn[Ko])&&void 0!==bs?bs:[];switch(Ir.kind){case Ae.OBJECT_TYPE_DEFINITION:{var jc;const sh=[Ir,...Es];return new pl({name:Ko,description:null===(jc=Ir.description)||void 0===jc?void 0:jc.value,interfaces:()=>xg(sh),fields:()=>oh(sh),astNode:Ir,extensionASTNodes:Es})}case Ae.INTERFACE_TYPE_DEFINITION:{var wc;const sh=[Ir,...Es];return new Il({name:Ko,description:null===(wc=Ir.description)||void 0===wc?void 0:wc.value,interfaces:()=>xg(sh),fields:()=>oh(sh),astNode:Ir,extensionASTNodes:Es})}case Ae.ENUM_TYPE_DEFINITION:{var Ho;const sh=[Ir,...Es];return new yl({name:Ko,description:null===(Ho=Ir.description)||void 0===Ho?void 0:Ho.value,values:vf(sh),astNode:Ir,extensionASTNodes:Es})}case Ae.UNION_TYPE_DEFINITION:{var cp;const sh=[Ir,...Es];return new Xa({name:Ko,description:null===(cp=Ir.description)||void 0===cp?void 0:cp.value,types:()=>s1(sh),astNode:Ir,extensionASTNodes:Es})}case Ae.SCALAR_TYPE_DEFINITION:var Mh;return new la({name:Ko,description:null===(Mh=Ir.description)||void 0===Mh?void 0:Mh.value,specifiedByURL:Jp(Ir),astNode:Ir,extensionASTNodes:Es});case Ae.INPUT_OBJECT_TYPE_DEFINITION:{var E0;const sh=[Ir,...Es];return new Aa({name:Ko,description:null===(E0=Ir.description)||void 0===E0?void 0:E0.value,fields:()=>S0(sh),astNode:Ir,extensionASTNodes:Es,isOneOf:Cc(Ir)})}}}}const km=Ve([...fu,...at],T=>T.name);function Nf(T){const P=Hl(bi,T);return P?.reason}function Jp(T){const P=Hl(vi,T);return P?.url}function Cc(T){return!!Hl(Ci,T)}function io(T,P){null!=T&&T.kind===Ae.DOCUMENT||M(!1,"Must provide valid Document AST."),!0!==P?.assumeValid&&!0!==P?.assumeValidSDL&&function xs(T){const P=ja(T);if(0!==P.length)throw new Error(P.map(W=>W.message).join("\n\n"))}(T);const se=Dg({description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},T,P);if(null==se.astNode)for(const Fe of se.types)switch(Fe.name){case"Query":se.query=Fe;break;case"Mutation":se.mutation=Fe;break;case"Subscription":se.subscription=Fe}const me=[...se.directives,...Xi.filter(Fe=>se.directives.every(gt=>gt.name!==Fe.name))];return new _i({...se,directives:me})}function Ps(T,P){return io(Ti(T,{noLocation:P?.noLocation,allowLegacyFragmentVariables:P?.allowLegacyFragmentVariables}),{assumeValidSDL:P?.assumeValidSDL,assumeValid:P?.assumeValid})}function fc(T){const P=T.toConfig(),W=He(nc(P.types),tr=>tr.name,function Vi(tr){if(jn(tr)||Oe(tr))return tr;if(Ui(tr)){const Wr=tr.toConfig();return new pl({...Wr,interfaces:()=>yi(Wr.interfaces),fields:()=>wn(Wr.fields)})}if(er(tr)){const Wr=tr.toConfig();return new Il({...Wr,interfaces:()=>yi(Wr.interfaces),fields:()=>wn(Wr.fields)})}if(Tt(tr)){const Wr=tr.toConfig();return new Xa({...Wr,types:()=>yi(Wr.types)})}if(Tn(tr)){const Wr=tr.toConfig();return new yl({...Wr,values:Xl(Wr.values,Yo=>Yo)})}if(Un(tr)){const Wr=tr.toConfig();return new Aa({...Wr,fields:()=>function ei(tr){return Xl(tr,Wr=>({...Wr,type:se(Wr.type)}))}(Wr.fields)})}Q(!1,"Unexpected type: "+yt(tr))});return new _i({...P,types:Object.values(W),directives:nc(P.directives).map(function gt(tr){const Wr=tr.toConfig();return new Ge({...Wr,locations:ra(Wr.locations,Yo=>Yo),args:Bt(Wr.args)})}),query:Fe(P.query),mutation:Fe(P.mutation),subscription:Fe(P.subscription)});function se(tr){return Wi(tr)?new ts(se(tr.ofType)):Li(tr)?new wo(se(tr.ofType)):me(tr)}function me(tr){return W[tr.name]}function Fe(tr){return tr&&me(tr)}function Bt(tr){return Xl(tr,Wr=>({...Wr,type:se(Wr.type)}))}function wn(tr){return Xl(tr,Wr=>({...Wr,type:se(Wr.type),args:Wr.args&&Bt(Wr.args)}))}function yi(tr){return nc(tr).map(me)}}function Xl(T,P){const W=Object.create(null);for(const se of Object.keys(T).sort(bt))W[se]=P(T[se]);return W}function nc(T){return ra(T,P=>P.name)}function ra(T,P){return T.slice().sort((W,se)=>bt(P(W),P(se)))}function Rf(T){return sd(T,P=>!$i(P),Jc)}function Ja(T){return sd(T,$i,Oe)}function Jc(T){return!Rc(T)&&!Oe(T)}function sd(T,P,W){const se=T.getDirectives().filter(P),me=Object.values(T.getTypeMap()).filter(W);return[Ss(T),...se.map(Fe=>function Nt(T){return ur(T)+"directive @"+T.name+ee(T.args)+(T.isRepeatable?" repeatable":"")+" on "+T.locations.join(" | ")}(Fe)),...me.map(Fe=>eh(Fe))].filter(Boolean).join("\n\n")}function Ss(T){if(null==T.description&&function ps(T){const P=T.getQueryType();if(P&&"Query"!==P.name)return!1;const W=T.getMutationType();if(W&&"Mutation"!==W.name)return!1;const se=T.getSubscriptionType();return!(se&&"Subscription"!==se.name)}(T))return;const P=[],W=T.getQueryType();W&&P.push(` query: ${W.name}`);const se=T.getMutationType();se&&P.push(` mutation: ${se.name}`);const me=T.getSubscriptionType();return me&&P.push(` subscription: ${me.name}`),ur(T)+`schema {\n${P.join("\n")}\n}`}function eh(T){return jn(T)?function Eh(T){return ur(T)+`scalar ${T.name}`+function gr(T){return null==T.specifiedByURL?"":` @specifiedBy(url: ${gs({kind:Ae.STRING,value:T.specifiedByURL})})`}(T)}(T):Ui(T)?function zu(T){return ur(T)+`type ${T.name}`+Gl(T)+E(T)}(T):er(T)?function Bd(T){return ur(T)+`interface ${T.name}`+Gl(T)+E(T)}(T):Tt(T)?function th(T){const P=T.getTypes(),W=P.length?" = "+P.join(" | "):"";return ur(T)+"union "+T.name+W}(T):Tn(T)?function V(T){const P=T.getValues().map((W,se)=>ur(W," ",!se)+" "+W.name+Ei(W.deprecationReason));return ur(T)+`enum ${T.name}`+U(P)}(T):Un(T)?function Qe(T){const P=Object.values(T.getFields()).map((W,se)=>ur(W," ",!se)+" "+Xe(W));return ur(T)+`input ${T.name}`+(T.isOneOf?" @oneOf":"")+U(P)}(T):void Q(!1,"Unexpected type: "+yt(T))}function Gl(T){const P=T.getInterfaces();return P.length?" implements "+P.map(W=>W.name).join(" & "):""}function E(T){return U(Object.values(T.getFields()).map((W,se)=>ur(W," ",!se)+" "+W.name+ee(W.args," ")+": "+String(W.type)+Ei(W.deprecationReason)))}function U(T){return 0!==T.length?" {\n"+T.join("\n")+"\n}":""}function ee(T,P=""){return 0===T.length?"":T.every(W=>!W.description)?"("+T.map(Xe).join(", ")+")":"(\n"+T.map((W,se)=>ur(W," "+P,!se)+" "+P+Xe(W)).join("\n")+"\n"+P+")"}function Xe(T){const P=ai(T.defaultValue,T.type);let W=T.name+": "+String(T.type);return P&&(W+=` = ${gs(P)}`),W+Ei(T.deprecationReason)}function Ei(T){return null==T?"":T!==kn?` @deprecated(reason: ${gs({kind:Ae.STRING,value:T})})`:" @deprecated"}function ur(T,P="",W=!0){const{description:se}=T;return null==se?"":(P&&!W?"\n"+P:P)+gs({kind:Ae.STRING,value:se,block:Wn(se)}).replace(/\n/g,"\n"+P)+"\n"}function vo(T){const P=[];for(const W of T)P.push(...W.definitions);return{kind:Ae.DOCUMENT,definitions:P}}function Gr(T){const P=[],W=Object.create(null);for(const me of T.definitions)switch(me.kind){case Ae.OPERATION_DEFINITION:P.push(me);break;case Ae.FRAGMENT_DEFINITION:W[me.name.value]=cs(me.selectionSet)}const se=Object.create(null);for(const me of P){const Fe=new Set;for(const Bt of cs(me.selectionSet))jo(Fe,W,Bt);se[me.name?me.name.value:""]={kind:Ae.DOCUMENT,definitions:T.definitions.filter(Bt=>Bt===me||Bt.kind===Ae.FRAGMENT_DEFINITION&&Fe.has(Bt.name.value))}}return se}function jo(T,P,W){if(!T.has(W)){T.add(W);const se=P[W];if(void 0!==se)for(const me of se)jo(T,P,me)}}function cs(T){const P=[];return za(T,{FragmentSpread(W){P.push(W.name.value)}}),P}function el(T){const P=qn(T)?T:new ni(T),W=P.body,se=new St(P);let me="",Fe=!1;for(;se.advance().kind!==An.EOF;){const gt=se.token,Bt=gt.kind,wn=!qt(gt.kind);Fe&&(wn||gt.kind===An.SPREAD)&&(me+=" ");const ei=W.slice(gt.start,gt.end);me+=Bt===An.BLOCK_STRING?ji(gt.value,{minimize:!0}):ei,Fe=wn}return me}function gu(T){const P=Zl(T);if(P)throw P;return T}function Zl(T){if("string"==typeof T||M(!1,"Expected name to be a string."),T.startsWith("__"))return new le(`Name "${T}" must not begin with "__", which is reserved by GraphQL introspection.`);try{ko(T)}catch(P){return P}}var Ga=function(T){return T.TYPE_REMOVED="TYPE_REMOVED",T.TYPE_CHANGED_KIND="TYPE_CHANGED_KIND",T.TYPE_REMOVED_FROM_UNION="TYPE_REMOVED_FROM_UNION",T.VALUE_REMOVED_FROM_ENUM="VALUE_REMOVED_FROM_ENUM",T.REQUIRED_INPUT_FIELD_ADDED="REQUIRED_INPUT_FIELD_ADDED",T.IMPLEMENTED_INTERFACE_REMOVED="IMPLEMENTED_INTERFACE_REMOVED",T.FIELD_REMOVED="FIELD_REMOVED",T.FIELD_CHANGED_KIND="FIELD_CHANGED_KIND",T.REQUIRED_ARG_ADDED="REQUIRED_ARG_ADDED",T.ARG_REMOVED="ARG_REMOVED",T.ARG_CHANGED_KIND="ARG_CHANGED_KIND",T.DIRECTIVE_REMOVED="DIRECTIVE_REMOVED",T.DIRECTIVE_ARG_REMOVED="DIRECTIVE_ARG_REMOVED",T.REQUIRED_DIRECTIVE_ARG_ADDED="REQUIRED_DIRECTIVE_ARG_ADDED",T.DIRECTIVE_REPEATABLE_REMOVED="DIRECTIVE_REPEATABLE_REMOVED",T.DIRECTIVE_LOCATION_REMOVED="DIRECTIVE_LOCATION_REMOVED",T}(Ga||{}),qa=function(T){return T.VALUE_ADDED_TO_ENUM="VALUE_ADDED_TO_ENUM",T.TYPE_ADDED_TO_UNION="TYPE_ADDED_TO_UNION",T.OPTIONAL_INPUT_FIELD_ADDED="OPTIONAL_INPUT_FIELD_ADDED",T.OPTIONAL_ARG_ADDED="OPTIONAL_ARG_ADDED",T.IMPLEMENTED_INTERFACE_ADDED="IMPLEMENTED_INTERFACE_ADDED",T.ARG_DEFAULT_VALUE_CHANGE="ARG_DEFAULT_VALUE_CHANGE",T}(qa||{});function Th(T,P){return nh(T,P).filter(W=>W.type in Ga)}function Pm(T,P){return nh(T,P).filter(W=>W.type in qa)}function nh(T,P){return[...Jh(T,P),...ih(T,P)]}function ih(T,P){const W=[],se=tm(T.getDirectives(),P.getDirectives());for(const me of se.removed)W.push({type:Ga.DIRECTIVE_REMOVED,description:`${me.name} was removed.`});for(const[me,Fe]of se.persisted){const gt=tm(me.args,Fe.args);for(const Bt of gt.added)ca(Bt)&&W.push({type:Ga.REQUIRED_DIRECTIVE_ARG_ADDED,description:`A required arg ${Bt.name} on directive ${me.name} was added.`});for(const Bt of gt.removed)W.push({type:Ga.DIRECTIVE_ARG_REMOVED,description:`${Bt.name} was removed from ${me.name}.`});me.isRepeatable&&!Fe.isRepeatable&&W.push({type:Ga.DIRECTIVE_REPEATABLE_REMOVED,description:`Repeatable flag was removed from ${me.name}.`});for(const Bt of me.locations)Fe.locations.includes(Bt)||W.push({type:Ga.DIRECTIVE_LOCATION_REMOVED,description:`${Bt} was removed from ${me.name}.`})}return W}function Jh(T,P){const W=[],se=tm(Object.values(T.getTypeMap()),Object.values(P.getTypeMap()));for(const me of se.removed)W.push({type:Ga.TYPE_REMOVED,description:Rc(me)?`Standard scalar ${me.name} was removed because it is not referenced anymore.`:`${me.name} was removed.`});for(const[me,Fe]of se.persisted)Tn(me)&&Tn(Fe)?W.push(...vE(me,Fe)):Tt(me)&&Tt(Fe)?W.push(...o1(me,Fe)):Un(me)&&Un(Fe)?W.push(...em(me,Fe)):Ui(me)&&Ui(Fe)||er(me)&&er(Fe)?W.push(...x0(me,Fe),...ef(me,Fe)):me.constructor!==Fe.constructor&&W.push({type:Ga.TYPE_CHANGED_KIND,description:`${me.name} changed from ${Av(me)} to ${Av(Fe)}.`});return W}function em(T,P){const W=[],se=tm(Object.values(T.getFields()),Object.values(P.getFields()));for(const me of se.added)Ql(me)?W.push({type:Ga.REQUIRED_INPUT_FIELD_ADDED,description:`A required field ${me.name} on input type ${T.name} was added.`}):W.push({type:qa.OPTIONAL_INPUT_FIELD_ADDED,description:`An optional field ${me.name} on input type ${T.name} was added.`});for(const me of se.removed)W.push({type:Ga.FIELD_REMOVED,description:`${T.name}.${me.name} was removed.`});for(const[me,Fe]of se.persisted)Dc(me.type,Fe.type)||W.push({type:Ga.FIELD_CHANGED_KIND,description:`${T.name}.${me.name} changed type from ${String(me.type)} to ${String(Fe.type)}.`});return W}function o1(T,P){const W=[],se=tm(T.getTypes(),P.getTypes());for(const me of se.added)W.push({type:qa.TYPE_ADDED_TO_UNION,description:`${me.name} was added to union type ${T.name}.`});for(const me of se.removed)W.push({type:Ga.TYPE_REMOVED_FROM_UNION,description:`${me.name} was removed from union type ${T.name}.`});return W}function vE(T,P){const W=[],se=tm(T.getValues(),P.getValues());for(const me of se.added)W.push({type:qa.VALUE_ADDED_TO_ENUM,description:`${me.name} was added to enum type ${T.name}.`});for(const me of se.removed)W.push({type:Ga.VALUE_REMOVED_FROM_ENUM,description:`${me.name} was removed from enum type ${T.name}.`});return W}function ef(T,P){const W=[],se=tm(T.getInterfaces(),P.getInterfaces());for(const me of se.added)W.push({type:qa.IMPLEMENTED_INTERFACE_ADDED,description:`${me.name} added to interfaces implemented by ${T.name}.`});for(const me of se.removed)W.push({type:Ga.IMPLEMENTED_INTERFACE_REMOVED,description:`${T.name} no longer implements interface ${me.name}.`});return W}function x0(T,P){const W=[],se=tm(Object.values(T.getFields()),Object.values(P.getFields()));for(const me of se.removed)W.push({type:Ga.FIELD_REMOVED,description:`${T.name}.${me.name} was removed.`});for(const[me,Fe]of se.persisted)W.push(...z_(T,me,Fe)),wg(me.type,Fe.type)||W.push({type:Ga.FIELD_CHANGED_KIND,description:`${T.name}.${me.name} changed type from ${String(me.type)} to ${String(Fe.type)}.`});return W}function z_(T,P,W){const se=[],me=tm(P.args,W.args);for(const Fe of me.removed)se.push({type:Ga.ARG_REMOVED,description:`${T.name}.${P.name} arg ${Fe.name} was removed.`});for(const[Fe,gt]of me.persisted)if(Dc(Fe.type,gt.type)){if(void 0!==Fe.defaultValue)if(void 0===gt.defaultValue)se.push({type:qa.ARG_DEFAULT_VALUE_CHANGE,description:`${T.name}.${P.name} arg ${Fe.name} defaultValue was removed.`});else{const wn=lx(Fe.defaultValue,Fe.type),ei=lx(gt.defaultValue,gt.type);wn!==ei&&se.push({type:qa.ARG_DEFAULT_VALUE_CHANGE,description:`${T.name}.${P.name} arg ${Fe.name} has changed defaultValue from ${wn} to ${ei}.`})}}else se.push({type:Ga.ARG_CHANGED_KIND,description:`${T.name}.${P.name} arg ${Fe.name} has changed type from ${String(Fe.type)} to ${String(gt.type)}.`});for(const Fe of me.added)ca(Fe)?se.push({type:Ga.REQUIRED_ARG_ADDED,description:`A required arg ${Fe.name} on ${T.name}.${P.name} was added.`}):se.push({type:qa.OPTIONAL_ARG_ADDED,description:`An optional arg ${Fe.name} on ${T.name}.${P.name} was added.`});return se}function wg(T,P){return Wi(T)?Wi(P)&&wg(T.ofType,P.ofType)||Li(P)&&wg(T,P.ofType):Li(T)?Li(P)&&wg(T.ofType,P.ofType):al(P)&&T.name===P.name||Li(P)&&wg(T,P.ofType)}function Dc(T,P){return Wi(T)?Wi(P)&&Dc(T.ofType,P.ofType):Li(T)?Li(P)&&Dc(T.ofType,P.ofType)||!Li(P)&&Dc(T.ofType,P):al(P)&&T.name===P.name}function Av(T){return jn(T)?"a Scalar type":Ui(T)?"an Object type":er(T)?"an Interface type":Tt(T)?"a Union type":Tn(T)?"an Enum type":Un(T)?"an Input type":void Q(!1,"Unexpected type: "+yt(T))}function lx(T,P){const W=ai(T,P);return null!=W||Q(!1),gs(Bc(W))}function tm(T,P){const W=[],se=[],me=[],Fe=Ve(T,({name:Bt})=>Bt),gt=Ve(P,({name:Bt})=>Bt);for(const Bt of T){const wn=gt[Bt.name];void 0===wn?se.push(Bt):me.push([Bt,wn])}for(const Bt of P)void 0===Fe[Bt.name]&&W.push(Bt);return{added:W,persisted:me,removed:se}}},7071:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(282),e=S(6180);function X(Q){this.__wrapped__=Q,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}(X.prototype=(0,i.A)(e.A.prototype)).constructor=X;const ie=X},7015:(Ot,Me,S)=>{S.d(Me,{A:()=>ve});var M=S(1319);const ie=function X(fn,ct){for(var en=fn.length;en--;)if((0,M.A)(fn[en][0],ct))return en;return-1};var Ee=Array.prototype.splice;function wt(fn){var ct=-1,en=null==fn?0:fn.length;for(this.clear();++ct<en;){var an=fn[ct];this.set(an[0],an[1])}}wt.prototype.clear=function i(){this.__data__=[],this.size=0},wt.prototype.delete=function he(fn){var ct=this.__data__,en=ie(ct,fn);return!(en<0||(en==ct.length-1?ct.pop():Ee.call(ct,en,1),--this.size,0))},wt.prototype.get=function oe(fn){var ct=this.__data__,en=ie(ct,fn);return en<0?void 0:ct[en][1]},wt.prototype.has=function ce(fn){return ie(this.__data__,fn)>-1},wt.prototype.set=function je(fn,ct){var en=this.__data__,an=ie(en,fn);return an<0?(++this.size,en.push([fn,ct])):en[an][1]=ct,this};const ve=wt},8754:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(282),e=S(6180);function M(ie,Q){this.__wrapped__=ie,this.__actions__=[],this.__chain__=!!Q,this.__index__=0,this.__values__=void 0}(M.prototype=(0,i.A)(e.A.prototype)).constructor=M;const X=M},6568:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(8425),e=S(1860);const X=(0,i.A)(e.A,"Map")},2291:(Ot,Me,S)=>{S.d(Me,{A:()=>on});const M=(0,S(8425).A)(Object,"create");var oe=Object.prototype.hasOwnProperty;var je=Object.prototype.hasOwnProperty;function en(Cn){var tn=-1,fi=null==Cn?0:Cn.length;for(this.clear();++tn<fi;){var Zn=Cn[tn];this.set(Zn[0],Zn[1])}}en.prototype.clear=function X(){this.__data__=M?M(null):{},this.size=0},en.prototype.delete=function Q(Cn){var tn=this.has(Cn)&&delete this.__data__[Cn];return this.size-=tn?1:0,tn},en.prototype.get=function Z(Cn){var tn=this.__data__;if(M){var fi=tn[Cn];return"__lodash_hash_undefined__"===fi?void 0:fi}return oe.call(tn,Cn)?tn[Cn]:void 0},en.prototype.has=function Et(Cn){var tn=this.__data__;return M?void 0!==tn[Cn]:je.call(tn,Cn)},en.prototype.set=function fn(Cn,tn){var fi=this.__data__;return this.size+=this.has(Cn)?0:1,fi[Cn]=M&&void 0===tn?"__lodash_hash_undefined__":tn,this};const an=en;var un=S(7015),vn=S(6568);const Wt=function Mt(Cn,tn){var fi=Cn.__data__;return function dt(Cn){var tn=typeof Cn;return"string"==tn||"number"==tn||"symbol"==tn||"boolean"==tn?"__proto__"!==Cn:null===Cn}(tn)?fi["string"==typeof tn?"string":"hash"]:fi.map};function Ht(Cn){var tn=-1,fi=null==Cn?0:Cn.length;for(this.clear();++tn<fi;){var Zn=Cn[tn];this.set(Zn[0],Zn[1])}}Ht.prototype.clear=function Pt(){this.size=0,this.__data__={hash:new an,map:new(vn.A||un.A),string:new an}},Ht.prototype.delete=function It(Cn){var tn=Wt(this,Cn).delete(Cn);return this.size-=tn?1:0,tn},Ht.prototype.get=function pn(Cn){return Wt(this,Cn).get(Cn)},Ht.prototype.has=function ji(Cn){return Wt(this,Cn).has(Cn)},Ht.prototype.set=function St(Cn,tn){var fi=Wt(this,Cn),Zn=fi.size;return fi.set(Cn,tn),this.size+=fi.size==Zn?0:1,this};const on=Ht},6944:(Ot,Me,S)=>{S.d(Me,{A:()=>M});const M=S(1860).A.Symbol},5756:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(8425),e=S(1860);const X=(0,i.A)(e.A,"WeakMap")},4982:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X,ie){switch(ie.length){case 0:return M.call(X);case 1:return M.call(X,ie[0]);case 2:return M.call(X,ie[0],ie[1]);case 3:return M.call(X,ie[0],ie[1],ie[2])}return M.apply(X,ie)}},9162:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X){for(var ie=-1,Q=null==M?0:M.length;++ie<Q&&!1!==X(M[ie],ie,M););return M}},3854:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(3776);const M=function e(X,ie){return!(null==X||!X.length)&&(0,i.A)(X,ie,0)>-1}},6792:(Ot,Me,S)=>{S.d(Me,{A:()=>oe});var i=S(9659),e=S(6513),M=S(3744),X=S(259),ie=S(6225),Q=S(8885),he=Object.prototype.hasOwnProperty;const oe=function q(Z,ce){var le=(0,M.A)(Z),je=!le&&(0,e.A)(Z),Et=!le&&!je&&(0,X.A)(Z),wt=!le&&!je&&!Et&&(0,Q.A)(Z),ve=le||je||Et||wt,fn=ve?(0,i.A)(Z.length,String):[],ct=fn.length;for(var en in Z)(ce||he.call(Z,en))&&(!ve||!("length"==en||Et&&("offset"==en||"parent"==en)||wt&&("buffer"==en||"byteLength"==en||"byteOffset"==en)||(0,ie.A)(en,ct)))&&fn.push(en);return fn}},6689:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X){for(var ie=-1,Q=null==M?0:M.length,Ee=Array(Q);++ie<Q;)Ee[ie]=X(M[ie],ie,M);return Ee}},1984:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(1827),e=S(1319),X=Object.prototype.hasOwnProperty;const Q=function ie(Ee,he,q){var oe=Ee[he];(!X.call(Ee,he)||!(0,e.A)(oe,q)||void 0===q&&!(he in Ee))&&(0,i.A)(Ee,he,q)}},1827:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(4746);const M=function e(X,ie,Q){"__proto__"==ie&&i.A?(0,i.A)(X,ie,{configurable:!0,enumerable:!0,value:Q,writable:!0}):X[ie]=Q}},282:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(554),e=Object.create;const X=function(){function ie(){}return function(Q){if(!(0,i.A)(Q))return{};if(e)return e(Q);ie.prototype=Q;var Ee=new ie;return ie.prototype=void 0,Ee}}()},8556:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X,ie,Q){for(var Ee=M.length,he=ie+(Q?1:-1);Q?he--:++he<Ee;)if(X(M[he],he,M))return he;return-1}},4501:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(4512),e=S(4662);const X=function M(ie,Q){for(var Ee=0,he=(Q=(0,i.A)(Q,ie)).length;null!=ie&&Ee<he;)ie=ie[(0,e.A)(Q[Ee++])];return Ee&&Ee==he?ie:void 0}},5281:(Ot,Me,S)=>{S.d(Me,{A:()=>wt});var i=S(6944),e=Object.prototype,M=e.hasOwnProperty,X=e.toString,ie=i.A?i.A.toStringTag:void 0;var q=Object.prototype.toString;var je=i.A?i.A.toStringTag:void 0;const wt=function Et(ve){return null==ve?void 0===ve?"[object Undefined]":"[object Null]":je&&je in Object(ve)?function Q(ve){var fn=M.call(ve,ie),ct=ve[ie];try{ve[ie]=void 0;var en=!0}catch{}var an=X.call(ve);return en&&(fn?ve[ie]=ct:delete ve[ie]),an}(ve):function oe(ve){return q.call(ve)}(ve)}},3776:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(8556),e=S(6440);const Q=function ie(Ee,he,q){return he==he?function M(Ee,he,q){for(var oe=q-1,Z=Ee.length;++oe<Z;)if(Ee[oe]===he)return oe;return-1}(Ee,he,q):(0,i.A)(Ee,e.A,q)}},6440:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return M!=M}},5066:(Ot,Me,S)=>{S.d(Me,{A:()=>wt});var ve,i=S(129),e=S(9748),M=(ve=/[^.]+$/.exec(e.A&&e.A.keys&&e.A.keys.IE_PROTO||""))?"Symbol(src)_1."+ve:"";var Q=S(554),Ee=S(8736),q=/^\[object .+?Constructor\]$/,je=RegExp("^"+Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const wt=function Et(ve){return!(!(0,Q.A)(ve)||function X(ve){return!!M&&M in ve}(ve))&&((0,i.A)(ve)?je:q).test((0,Ee.A)(ve))}},6180:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(){}},363:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(7003),e=S(9008),M=S(5014);const ie=function X(Q,Ee){return(0,M.A)((0,e.A)(Q,Ee,i.A),Q+"")}},5473:(Ot,Me,S)=>{S.d(Me,{A:()=>Ee});var i=S(1984),e=S(4512),M=S(6225),X=S(554),ie=S(4662);const Ee=function Q(he,q,oe,Z){if(!(0,X.A)(he))return he;for(var ce=-1,le=(q=(0,e.A)(q,he)).length,je=le-1,Et=he;null!=Et&&++ce<le;){var wt=(0,ie.A)(q[ce]),ve=oe;if("__proto__"===wt||"constructor"===wt||"prototype"===wt)return he;if(ce!=je){var fn=Et[wt];void 0===(ve=Z?Z(fn,wt,Et):void 0)&&(ve=(0,X.A)(fn)?fn:(0,M.A)(q[ce+1])?[]:{})}(0,i.A)(Et,wt,ve),Et=Et[wt]}return he}},2721:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(7003),e=S(2047);const X=e.A?function(ie,Q){return e.A.set(ie,Q),ie}:i.A},9659:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X){for(var ie=-1,Q=Array(M);++ie<M;)Q[ie]=X(ie);return Q}},1473:(Ot,Me,S)=>{S.d(Me,{A:()=>q});var i=S(6944),e=S(6689),M=S(3744),X=S(4077),Q=i.A?i.A.prototype:void 0,Ee=Q?Q.toString:void 0;const q=function he(oe){if("string"==typeof oe)return oe;if((0,M.A)(oe))return(0,e.A)(oe,he)+"";if((0,X.A)(oe))return Ee?Ee.call(oe):"";var Z=oe+"";return"0"==Z&&1/oe==-1/0?"-0":Z}},673:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(9939),e=/^\s+/;const X=function M(ie){return ie&&ie.slice(0,(0,i.A)(ie)+1).replace(e,"")}},778:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return function(X){return M(X)}}},4512:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(3744),e=S(3097),M=S(9293),X=S(1705);const Q=function ie(Ee,he){return(0,i.A)(Ee)?Ee:(0,e.A)(Ee,he)?[Ee]:(0,M.A)((0,X.A)(Ee))}},2427:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=Math.max;const M=function e(X,ie,Q,Ee){for(var he=-1,q=X.length,oe=Q.length,Z=-1,ce=ie.length,le=i(q-oe,0),je=Array(ce+le),Et=!Ee;++Z<ce;)je[Z]=ie[Z];for(;++he<oe;)(Et||he<q)&&(je[Q[he]]=X[he]);for(;le--;)je[Z++]=X[he++];return je}},6673:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=Math.max;const M=function e(X,ie,Q,Ee){for(var he=-1,q=X.length,oe=-1,Z=Q.length,ce=-1,le=ie.length,je=i(q-Z,0),Et=Array(je+le),wt=!Ee;++he<je;)Et[he]=X[he];for(var ve=he;++ce<le;)Et[ve+ce]=ie[ce];for(;++oe<Z;)(wt||he<q)&&(Et[ve+Q[oe]]=X[he++]);return Et}},4528:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X){var ie=-1,Q=M.length;for(X||(X=Array(Q));++ie<Q;)X[ie]=M[ie];return X}},9748:(Ot,Me,S)=>{S.d(Me,{A:()=>M});const M=S(1860).A["__core-js_shared__"]},5762:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(282),e=S(554);const X=function M(ie){return function(){var Q=arguments;switch(Q.length){case 0:return new ie;case 1:return new ie(Q[0]);case 2:return new ie(Q[0],Q[1]);case 3:return new ie(Q[0],Q[1],Q[2]);case 4:return new ie(Q[0],Q[1],Q[2],Q[3]);case 5:return new ie(Q[0],Q[1],Q[2],Q[3],Q[4]);case 6:return new ie(Q[0],Q[1],Q[2],Q[3],Q[4],Q[5]);case 7:return new ie(Q[0],Q[1],Q[2],Q[3],Q[4],Q[5],Q[6])}var Ee=(0,i.A)(ie.prototype),he=ie.apply(Ee,Q);return(0,e.A)(he)?he:Ee}}},1383:(Ot,Me,S)=>{S.d(Me,{A:()=>un});var i=S(2427),e=S(6673);var ie=S(5762),Q=S(6958),Ee=S(4388),he=S(4528),q=S(6225),oe=Math.min;var le=S(3595),je=S(1860);const un=function an(vn,Pt,Ae,dt,ut,Mt,Wt,It,Vn,pn){var Wn=128&Pt,ji=1&Pt,An=2&Pt,St=24&Pt,qt=512&Pt,Ht=An?void 0:(0,ie.A)(vn);return function on(){for(var Cn=arguments.length,tn=Array(Cn),fi=Cn;fi--;)tn[fi]=arguments[fi];if(St)var Zn=(0,Ee.A)(on),Dn=function M(vn,Pt){for(var Ae=vn.length,dt=0;Ae--;)vn[Ae]===Pt&&++dt;return dt}(tn,Zn);if(dt&&(tn=(0,i.A)(tn,dt,ut,St)),Mt&&(tn=(0,e.A)(tn,Mt,Wt,St)),Cn-=Dn,St&&Cn<pn){var gn=(0,le.A)(tn,Zn);return(0,Q.A)(vn,Pt,an,on.placeholder,Ae,tn,gn,It,Vn,pn-Cn)}var Nn=ji?Ae:this,Yn=An?Nn[vn]:vn;return Cn=tn.length,It?tn=function Z(vn,Pt){for(var Ae=vn.length,dt=oe(Pt.length,Ae),ut=(0,he.A)(vn);dt--;){var Mt=Pt[dt];vn[dt]=(0,q.A)(Mt,Ae)?ut[Mt]:void 0}return vn}(tn,It):qt&&Cn>1&&tn.reverse(),Wn&&Vn<Cn&&(tn.length=Vn),this&&this!==je.A&&this instanceof on&&(Yn=Ht||(0,ie.A)(Yn)),Yn.apply(Nn,tn)}}},6958:(Ot,Me,S)=>{S.d(Me,{A:()=>Z});var i=S(6558),e=S(5474),M=S(8015);const Z=function oe(ce,le,je,Et,wt,ve,fn,ct,en,an){var un=8≤le|=un?32:64,4&(le&=~(un?64:32))||(le&=-4);var ut=[ce,le,wt,un?ve:void 0,un?fn:void 0,un?void 0:ve,un?void 0:fn,ct,en,an],Mt=je.apply(void 0,ut);return(0,i.A)(ce)&&(0,e.A)(Mt,ut),Mt.placeholder=Et,(0,M.A)(Mt,ce,le)}},6151:(Ot,Me,S)=>{S.d(Me,{A:()=>fi});var i=S(2721),e=S(5762),M=S(1860);var Ee=S(4982),he=S(1383),q=S(6958),oe=S(4388),Z=S(3595);var ve=S(8462),fn=S(2427),ct=S(6673),en="__lodash_placeholder__",ut=Math.min;var It=S(5474),Vn=S(8015),pn=S(2184),Cn=Math.max;const fi=function tn(Zn,Dn,gn,Nn,Yn,cr,Ai,Qi){var Xr=2&Dn;if(!Xr&&"function"!=typeof Zn)throw new TypeError("Expected a function");var Ur=Nn?Nn.length:0;if(Ur||(Dn&=-97,Nn=Yn=void 0),Ai=void 0===Ai?Ai:Cn((0,pn.A)(Ai),0),Qi=void 0===Qi?Qi:(0,pn.A)(Qi),Ur-=Yn?Yn.length:0,64&Dn){var eo=Nn,as=Yn;Nn=Yn=void 0}var uo=Xr?void 0:(0,ve.A)(Zn),mi=[Zn,Dn,gn,Nn,Yn,eo,as,cr,Ai,Qi];if(uo&&function Mt(Zn,Dn){var gn=Zn[1],Nn=Dn[1],Yn=gn|Nn;if(!(Yn<131||128==Nn&&8==gn||128==Nn&&256==gn&&Zn[7].length<=Dn[8]||384==Nn&&Dn[7].length<=Dn[8]&&8==gn))return Zn;1&Nn&&(Zn[2]=Dn[2],Yn|=1&gn?0:4);var Qi=Dn[3];if(Qi){var Xr=Zn[3];Zn[3]=Xr?(0,fn.A)(Xr,Qi,Dn[4]):Qi,Zn[4]=Xr?(0,Z.A)(Zn[3],en):Dn[4]}(Qi=Dn[5])&&(Zn[5]=(Xr=Zn[5])?(0,ct.A)(Xr,Qi,Dn[6]):Qi,Zn[6]=Xr?(0,Z.A)(Zn[5],en):Dn[6]),(Qi=Dn[7])&&(Zn[7]=Qi),128&Nn&&(Zn[8]=null==Zn[8]?Dn[8]:ut(Zn[8],Dn[8])),null==Zn[9]&&(Zn[9]=Dn[9]),Zn[0]=Dn[0],Zn[1]=Yn}(mi,uo),Zn=mi[0],Dn=mi[1],gn=mi[2],Nn=mi[3],Yn=mi[4],!(Qi=mi[9]=void 0===mi[9]?Xr?0:Zn.length:Cn(mi[9]-Ur,0))&&24&Dn&&(Dn&=-25),Dn&&1!=Dn)ci=8==Dn||16==Dn?function ce(Zn,Dn,gn){var Nn=(0,e.A)(Zn);return function Yn(){for(var cr=arguments.length,Ai=Array(cr),Qi=cr,Xr=(0,oe.A)(Yn);Qi--;)Ai[Qi]=arguments[Qi];var Ur=cr<3&&Ai[0]!==Xr&&Ai[cr-1]!==Xr?[]:(0,Z.A)(Ai,Xr);return(cr-=Ur.length)<gn?(0,q.A)(Zn,Dn,he.A,Yn.placeholder,void 0,Ai,Ur,void 0,void 0,gn-cr):(0,Ee.A)(this&&this!==M.A&&this instanceof Yn?Nn:Zn,this,Ai)}}(Zn,Dn,Qi):32!=Dn&&33!=Dn||Yn.length?he.A.apply(void 0,mi):function Et(Zn,Dn,gn,Nn){var Yn=1&Dn,cr=(0,e.A)(Zn);return function Ai(){for(var Qi=-1,Xr=arguments.length,Ur=-1,eo=Nn.length,as=Array(eo+Xr),uo=this&&this!==M.A&&this instanceof Ai?cr:Zn;++Ur<eo;)as[Ur]=Nn[Ur];for(;Xr--;)as[Ur++]=arguments[++Qi];return(0,Ee.A)(uo,Yn?gn:this,as)}}(Zn,Dn,gn,Nn);else var ci=function ie(Zn,Dn,gn){var Nn=1&Dn,Yn=(0,e.A)(Zn);return function cr(){return(this&&this!==M.A&&this instanceof cr?Yn:Zn).apply(Nn?gn:this,arguments)}}(Zn,Dn,gn);return(0,Vn.A)((uo?i.A:It.A)(ci,mi),Zn,Dn)}},4746:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(8425);const M=function(){try{var X=(0,i.A)(Object,"defineProperty");return X({},"",{}),X}catch{}}()},7133:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e="object"==typeof global&&global&&global.Object===Object&&global},8462:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(2047),e=S(3565);const X=i.A?function(ie){return i.A.get(ie)}:e.A},3395:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(7086),M=Object.prototype.hasOwnProperty;const ie=function X(Q){for(var Ee=Q.name+"",he=i.A[Ee],q=M.call(i.A,Ee)?he.length:0;q--;){var oe=he[q],Z=oe.func;if(null==Z||Z==Q)return oe.name}return Ee}},4388:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return M.placeholder}},8425:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(5066);const ie=function X(Q,Ee){var he=function e(Q,Ee){return Q?.[Ee]}(Q,Ee);return(0,i.A)(he)?he:void 0}},6225:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var e=/^(?:0|[1-9]\d*)$/;const X=function M(ie,Q){var Ee=typeof ie;return!!(Q=Q??9007199254740991)&&("number"==Ee||"symbol"!=Ee&&e.test(ie))&&ie>-1&&ie%1==0&&ie<Q}},7357:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(1319),e=S(1287),M=S(6225),X=S(554);const Q=function ie(Ee,he,q){if(!(0,X.A)(q))return!1;var oe=typeof he;return!!("number"==oe?(0,e.A)(q)&&(0,M.A)(he,q.length):"string"==oe&&he in q)&&(0,i.A)(q[he],Ee)}},3097:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(3744),e=S(4077),M=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,X=/^\w*$/;const Q=function ie(Ee,he){if((0,i.A)(Ee))return!1;var q=typeof Ee;return!("number"!=q&&"symbol"!=q&&"boolean"!=q&&null!=Ee&&!(0,e.A)(Ee))||X.test(Ee)||!M.test(Ee)||null!=he&&Ee in Object(he)}},6558:(Ot,Me,S)=>{S.d(Me,{A:()=>Q});var i=S(7071),e=S(8462),M=S(3395),X=S(7907);const Q=function ie(Ee){var he=(0,M.A)(Ee),q=X.A[he];if("function"!=typeof q||!(he in i.A.prototype))return!1;if(Ee===q)return!0;var oe=(0,e.A)(q);return!!oe&&Ee===oe[0]}},5776:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=Object.prototype;const M=function e(X){var ie=X&&X.constructor;return X===("function"==typeof ie&&ie.prototype||i)}},2047:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(5756);const M=i.A&&new i.A},3340:(Ot,Me,S)=>{S.d(Me,{A:()=>Ee});var i=S(7133),e="object"==typeof exports&&exports&&!exports.nodeType&&exports,M=e&&"object"==typeof module&&module&&!module.nodeType&&module,ie=M&&M.exports===e&&i.A.process;const Ee=function(){try{return M&&M.require&&M.require("util").types||ie&&ie.binding&&ie.binding("util")}catch{}}()},9008:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(4982),e=Math.max;const X=function M(ie,Q,Ee){return Q=e(void 0===Q?ie.length-1:Q,0),function(){for(var he=arguments,q=-1,oe=e(he.length-Q,0),Z=Array(oe);++q<oe;)Z[q]=he[Q+q];q=-1;for(var ce=Array(Q+1);++q<Q;)ce[q]=he[q];return ce[Q]=Ee(Z),(0,i.A)(ie,this,ce)}}},7086:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e={}},3595:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i="__lodash_placeholder__";const M=function e(X,ie){for(var Q=-1,Ee=X.length,he=0,q=[];++Q<Ee;){var oe=X[Q];(oe===ie||oe===i)&&(X[Q]=i,q[he++]=Q)}return q}},1860:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(7133),e="object"==typeof self&&self&&self.Object===Object&&self;const X=i.A||e||Function("return this")()},5474:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(2721);const X=(0,S(9950).A)(i.A)},5014:(Ot,Me,S)=>{S.d(Me,{A:()=>he});var i=S(1913),e=S(4746),M=S(7003);const ie=e.A?function(q,oe){return(0,e.A)(q,"toString",{configurable:!0,enumerable:!1,value:(0,i.A)(oe),writable:!0})}:M.A,he=(0,S(9950).A)(ie)},8015:(Ot,Me,S)=>{S.d(Me,{A:()=>Pt});var i=/\{\n\/\* \[wrapped with (.+)\] \*/,e=/,? & /;var ie=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;var he=S(5014),q=S(9162),oe=S(3854),en=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];const Pt=function vn(Ae,dt,ut){var Mt=dt+"";return(0,he.A)(Ae,function Q(Ae,dt){var ut=dt.length;if(!ut)return Ae;var Mt=ut-1;return dt[Mt]=(ut>1?"& ":"")+dt[Mt],dt=dt.join(ut>2?", ":" "),Ae.replace(ie,"{\n/* [wrapped with "+dt+"] */\n")}(Mt,function an(Ae,dt){return(0,q.A)(en,function(ut){var Mt="_."+ut[0];dt&ut[1]&&!(0,oe.A)(Ae,Mt)&&Ae.push(Mt)}),Ae.sort()}(function M(Ae){var dt=Ae.match(i);return dt?dt[1].split(e):[]}(Mt),ut)))}},9950:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var M=Date.now;const ie=function X(Q){var Ee=0,he=0;return function(){var q=M(),oe=16-(q-he);if(he=q,oe>0){if(++Ee>=800)return arguments[0]}else Ee=0;return Q.apply(void 0,arguments)}}},9293:(Ot,Me,S)=>{S.d(Me,{A:()=>he});var i=S(4569),ie=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Q=/\\(\\)?/g;const he=function M(q){var oe=(0,i.A)(q,function(ce){return 500===Z.size&&Z.clear(),ce}),Z=oe.cache;return oe}(function(q){var oe=[];return 46===q.charCodeAt(0)&&oe.push(""),q.replace(ie,function(Z,ce,le,je){oe.push(le?je.replace(Q,"$1"):ce||Z)}),oe})},4662:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(4077),e=1/0;const X=function M(ie){if("string"==typeof ie||(0,i.A)(ie))return ie;var Q=ie+"";return"0"==Q&&1/ie==-e?"-0":Q}},8736:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var e=Function.prototype.toString;const X=function M(ie){if(null!=ie){try{return e.call(ie)}catch{}try{return ie+""}catch{}}return""}},9939:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=/\s/;const M=function e(X){for(var ie=X.length;ie--&&i.test(X.charAt(ie)););return ie}},6740:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(7071),e=S(8754),M=S(4528);const ie=function X(Q){if(Q instanceof i.A)return Q.clone();var Ee=new e.A(Q.__wrapped__,Q.__chain__);return Ee.__actions__=(0,M.A)(Q.__actions__),Ee.__index__=Q.__index__,Ee.__values__=Q.__values__,Ee}},1913:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return function(){return M}}},9311:(Ot,Me,S)=>{S.d(Me,{A:()=>he});var i=S(363),e=S(1319),M=S(7357),X=S(133),ie=Object.prototype,Q=ie.hasOwnProperty;const he=(0,i.A)(function(q,oe){q=Object(q);var Z=-1,ce=oe.length,le=ce>2?oe[2]:void 0;for(le&&(0,M.A)(oe[0],oe[1],le)&&(ce=1);++Z<ce;)for(var je=oe[Z],Et=(0,X.A)(je),wt=-1,ve=Et.length;++wt<ve;){var fn=Et[wt],ct=q[fn];(void 0===ct||(0,e.A)(ct,ie[fn])&&!Q.call(q,fn))&&(q[fn]=je[fn])}return q})},1319:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M,X){return M===X||M!=M&&X!=X}},2125:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(4501);const M=function e(X,ie,Q){var Ee=null==X?void 0:(0,i.A)(X,ie);return void 0===Ee?Q:Ee}},7003:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return M}},6513:(Ot,Me,S)=>{S.d(Me,{A:()=>oe});var i=S(5281),e=S(2661);const ie=function X(Z){return(0,e.A)(Z)&&"[object Arguments]"==(0,i.A)(Z)};var Q=Object.prototype,Ee=Q.hasOwnProperty,he=Q.propertyIsEnumerable;const oe=ie(function(){return arguments}())?ie:function(Z){return(0,e.A)(Z)&&Ee.call(Z,"callee")&&!he.call(Z,"callee")}},3744:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=Array.isArray},1287:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(129),e=S(5481);const X=function M(ie){return null!=ie&&(0,e.A)(ie.length)&&!(0,i.A)(ie)}},259:(Ot,Me,S)=>{S.d(Me,{A:()=>q});var i=S(1860),e=S(5554),M="object"==typeof exports&&exports&&!exports.nodeType&&exports,X=M&&"object"==typeof module&&module&&!module.nodeType&&module,Q=X&&X.exports===M?i.A.Buffer:void 0;const q=(Q?Q.isBuffer:void 0)||e.A},129:(Ot,Me,S)=>{S.d(Me,{A:()=>he});var i=S(5281),e=S(554);const he=function Ee(q){if(!(0,e.A)(q))return!1;var oe=(0,i.A)(q);return"[object Function]"==oe||"[object GeneratorFunction]"==oe||"[object AsyncFunction]"==oe||"[object Proxy]"==oe}},5481:(Ot,Me,S)=>{S.d(Me,{A:()=>M});const M=function e(X){return"number"==typeof X&&X>-1&&X%1==0&&X<=9007199254740991}},554:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){var X=typeof M;return null!=M&&("object"==X||"function"==X)}},2661:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(M){return null!=M&&"object"==typeof M}},4077:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(5281),e=S(2661);const ie=function X(Q){return"symbol"==typeof Q||(0,e.A)(Q)&&"[object Symbol]"==(0,i.A)(Q)}},8885:(Ot,Me,S)=>{S.d(Me,{A:()=>An});var i=S(5281),e=S(5481),M=S(2661),Mt={};Mt["[object Float32Array]"]=Mt["[object Float64Array]"]=Mt["[object Int8Array]"]=Mt["[object Int16Array]"]=Mt["[object Int32Array]"]=Mt["[object Uint8Array]"]=Mt["[object Uint8ClampedArray]"]=Mt["[object Uint16Array]"]=Mt["[object Uint32Array]"]=!0,Mt["[object Arguments]"]=Mt["[object Array]"]=Mt["[object ArrayBuffer]"]=Mt["[object Boolean]"]=Mt["[object DataView]"]=Mt["[object Date]"]=Mt["[object Error]"]=Mt["[object Function]"]=Mt["[object Map]"]=Mt["[object Number]"]=Mt["[object Object]"]=Mt["[object RegExp]"]=Mt["[object Set]"]=Mt["[object String]"]=Mt["[object WeakMap]"]=!1;var Vn=S(778),pn=S(3340),Wn=pn.A&&pn.A.isTypedArray;const An=Wn?(0,Vn.A)(Wn):function Wt(St){return(0,M.A)(St)&&(0,e.A)(St.length)&&!!Mt[(0,i.A)(St)]}},133:(Ot,Me,S)=>{S.d(Me,{A:()=>ce});var i=S(6792),e=S(554),M=S(5776);var Ee=Object.prototype.hasOwnProperty;const q=function he(le){if(!(0,e.A)(le))return function X(le){var je=[];if(null!=le)for(var Et in Object(le))je.push(Et);return je}(le);var je=(0,M.A)(le),Et=[];for(var wt in le)"constructor"==wt&&(je||!Ee.call(le,wt))||Et.push(wt);return Et};var oe=S(1287);const ce=function Z(le){return(0,oe.A)(le)?(0,i.A)(le,!0):q(le)}},3324:(Ot,Me,S)=>{S.r(Me),S.d(Me,{add:()=>q,after:()=>le,ary:()=>ve,assign:()=>fi,assignIn:()=>gn,assignInWith:()=>Yn,assignWith:()=>Ai,at:()=>Bi,attempt:()=>Eo,before:()=>ol,bind:()=>_l,bindAll:()=>no,bindKey:()=>Lo,camelCase:()=>nd,capitalize:()=>Qc,castArray:()=>bl,ceil:()=>ff,chain:()=>Qh,chunk:()=>gd,clamp:()=>qs,clone:()=>Ss,cloneDeep:()=>Gl,cloneDeepWith:()=>V,cloneWith:()=>U,commit:()=>Nt,compact:()=>gr,concat:()=>vo,cond:()=>aD,conforms:()=>nf,conformsTo:()=>lD,constant:()=>Fp.A,countBy:()=>Ig,create:()=>A0,curry:()=>Nv,curryRight:()=>Rv,debounce:()=>Np,deburr:()=>vc,default:()=>k_,defaultTo:()=>wE,defaults:()=>kv.A,defaultsDeep:()=>_D,defer:()=>bx,delay:()=>Z_,difference:()=>yD,differenceBy:()=>Dx,differenceWith:()=>Bv,divide:()=>Vv,drop:()=>bD,dropRight:()=>Ng,dropRightWhile:()=>ey,dropWhile:()=>Sx,each:()=>jv,eachRight:()=>Ou,endsWith:()=>Rg,entries:()=>Wm,entriesIn:()=>Rp,eq:()=>ef.A,escape:()=>yf,escapeRegExp:()=>SE,every:()=>Ax,extend:()=>gn,extendWith:()=>Yn,fill:()=>TE,filter:()=>$0,find:()=>Rx,findIndex:()=>lm,findKey:()=>kg,findLast:()=>G0,findLastIndex:()=>MD,findLastKey:()=>ID,first:()=>cm,flatMap:()=>Gv,flatMapDeep:()=>Px,flatMapDepth:()=>w1,flatten:()=>At,flattenDeep:()=>Kv,flattenDepth:()=>FE,flip:()=>sy,floor:()=>q0,flow:()=>Y0,flowRight:()=>M1,forEach:()=>jv,forEachRight:()=>Ou,forIn:()=>PE,forInRight:()=>I1,forOwn:()=>fp,forOwnRight:()=>Ux,fromPairs:()=>Yv,functions:()=>RD,functionsIn:()=>VE,get:()=>Qi.A,groupBy:()=>LD,gt:()=>A1,gte:()=>O1,has:()=>ep,hasIn:()=>iD,head:()=>cm,identity:()=>Ap.A,inRange:()=>Pf,includes:()=>dm,indexOf:()=>eu,initial:()=>Xu,intersection:()=>Wd,intersectionBy:()=>Zu,intersectionWith:()=>ch,invert:()=>VD,invertBy:()=>R1,invoke:()=>Gm,invokeMap:()=>Bl,isArguments:()=>mi.A,isArray:()=>ci.A,isArrayBuffer:()=>UE,isArrayLike:()=>dt.A,isArrayLikeObject:()=>_u,isBoolean:()=>xc,isBuffer:()=>Zd.A,isDate:()=>WE,isElement:()=>P1,isEmpty:()=>zE,isEqual:()=>Od,isEqualWith:()=>$D,isError:()=>qr,isFinite:()=>qx,isFunction:()=>Um.A,isInteger:()=>Fd,isLength:()=>Mh.A,isMap:()=>Iu,isMatch:()=>KE,isMatchWith:()=>$c,isNaN:()=>Xx,isNative:()=>$a,isNil:()=>Qg,isNull:()=>Yg,isNumber:()=>Kg,isObject:()=>ns.A,isObjectLike:()=>Ki.A,isPlainObject:()=>nn,isRegExp:()=>Df,isSafeInteger:()=>o_,isSet:()=>Md,isString:()=>Wg,isSymbol:()=>i.A,isTypedArray:()=>bd.A,isUndefined:()=>kM,isWeakMap:()=>tS,isWeakSet:()=>hy,iteratee:()=>my,join:()=>ip,kebabCase:()=>dh,keyBy:()=>hm,keys:()=>Ht,keysIn:()=>Zn.A,last:()=>Jf,lastIndexOf:()=>KD,lodash:()=>Yt.A,lowerCase:()=>af,lowerFirst:()=>qD,lt:()=>H1,lte:()=>QD,map:()=>AD,mapKeys:()=>z1,mapValues:()=>Xg,matches:()=>K1,matchesProperty:()=>q1,max:()=>ZD,maxBy:()=>JD,mean:()=>Km,meanBy:()=>tw,memoize:()=>ub.A,merge:()=>Y1,mergeWith:()=>R0,method:()=>db,methodOf:()=>ZE,min:()=>Qm,minBy:()=>a_,mixin:()=>fh,multiply:()=>Jg,negate:()=>l_,next:()=>mb,noop:()=>ph.A,now:()=>u1,nth:()=>wy,nthArg:()=>xy,omit:()=>gb,omitBy:()=>vb,once:()=>qo,orderBy:()=>eC,over:()=>Zm,overArgs:()=>tv,overEvery:()=>wf,overSome:()=>My,pad:()=>oT,padEnd:()=>uw,padStart:()=>dw,parseInt:()=>lC,partial:()=>cC.A,partialRight:()=>f_,partition:()=>p_,pick:()=>dC,pickBy:()=>rw,plant:()=>Ly,property:()=>Pl,propertyOf:()=>ov,pull:()=>vm,pullAll:()=>fC,pullAllBy:()=>sv,pullAllWith:()=>ky,pullAt:()=>hC,random:()=>xS,range:()=>Mb,rangeRight:()=>mT,rearg:()=>TS,reduce:()=>MS,reduceRight:()=>og,reject:()=>bw,remove:()=>y_,repeat:()=>Vy,replace:()=>bT,rest:()=>ww,result:()=>gC,reverse:()=>Nb,round:()=>AS,sample:()=>av,sampleSize:()=>$y,set:()=>Rb.A,setWith:()=>b_,shuffle:()=>Cu,size:()=>lg,slice:()=>Ew,snakeCase:()=>cd,some:()=>Hf,sortBy:()=>C_,sortedIndex:()=>Jl,sortedIndexBy:()=>qy,sortedIndexOf:()=>cv,sortedLastIndex:()=>w_,sortedLastIndexBy:()=>uv,sortedLastIndexOf:()=>Qy,sortedUniq:()=>CC,sortedUniqBy:()=>ud,split:()=>Yy,spread:()=>Lb,startCase:()=>dv,startsWith:()=>S_,stubArray:()=>or,stubFalse:()=>j1.A,stubObject:()=>Zy,stubString:()=>fv,stubTrue:()=>kb,subtract:()=>DC,sum:()=>Hc,sumBy:()=>mv,tail:()=>wC,take:()=>SC,takeRight:()=>Dd,takeRightWhile:()=>Iw,takeWhile:()=>EC,tap:()=>kS,template:()=>NC,templateSettings:()=>MC,throttle:()=>jb,thru:()=>s0,times:()=>$S,toArray:()=>hb,toFinite:()=>pp.A,toInteger:()=>oe.A,toIterator:()=>a0,toJSON:()=>l0,toLength:()=>y1,toLower:()=>Lw,toNumber:()=>cc.A,toPairs:()=>Wm,toPairsIn:()=>Rp,toPath:()=>kw,toPlainObject:()=>gD,toSafeInteger:()=>Hb,toString:()=>ko.A,toUpper:()=>zb,transform:()=>c,trim:()=>ye,trimEnd:()=>ht,trimStart:()=>yn,truncate:()=>_o,unary:()=>ao,unescape:()=>oo,union:()=>Hr,unionBy:()=>Ns,unionWith:()=>Nu,uniq:()=>ru,uniqBy:()=>jl,uniqWith:()=>Cr,uniqueId:()=>wi,unset:()=>dn,unzip:()=>hs,unzipWith:()=>mg,update:()=>Gb,updateWith:()=>N_,upperCase:()=>HS,upperFirst:()=>Sc,value:()=>l0,valueOf:()=>l0,values:()=>Al,valuesIn:()=>kC,without:()=>uf,words:()=>Ks,wrap:()=>PC,wrapperAt:()=>QM,wrapperChain:()=>nl,wrapperCommit:()=>Nt,wrapperLodash:()=>Yt.A,wrapperNext:()=>mb,wrapperPlant:()=>Ly,wrapperReverse:()=>ET,wrapperToIterator:()=>a0,wrapperValue:()=>l0,xor:()=>YM,xorBy:()=>jw,xorWith:()=>jC,zip:()=>vv,zipObject:()=>MT,zipObjectDeep:()=>GS,zipWith:()=>Ku});var i=S(4077);const X=function M(N){return"number"==typeof N?N:(0,i.A)(N)?NaN:+N};var ie=S(1473);const Ee=function Q(N,$){return function(ge,nt){var Lt;if(void 0===ge&&void 0===nt)return $;if(void 0!==ge&&(Lt=ge),void 0!==nt){if(void 0===Lt)return nt;"string"==typeof ge||"string"==typeof nt?(ge=(0,ie.A)(ge),nt=(0,ie.A)(nt)):(ge=X(ge),nt=X(nt)),Lt=N(ge,nt)}return Lt}};var he=Ee(function(N,$){return N+$},0);const q=he;var oe=S(2184);const le=function ce(N,$){if("function"!=typeof $)throw new TypeError("Expected a function");return N=(0,oe.A)(N),function(){if(--N<1)return $.apply(this,arguments)}};var je=S(6151);const ve=function wt(N,$,ge){return $=ge?void 0:$,(0,je.A)(N,128,void 0,void 0,void 0,void 0,$=N&&null==$?N.length:$)};var fn=S(1984),ct=S(1827);const an=function en(N,$,ge,nt){var Lt=!ge;ge||(ge={});for(var bn=-1,ui=$.length;++bn<ui;){var Hi=$[bn],yr=nt?nt(ge[Hi],N[Hi],Hi,ge,N):void 0;void 0===yr&&(yr=N[Hi]),Lt?(0,ct.A)(ge,Hi,yr):(0,fn.A)(ge,Hi,yr)}return ge};var un=S(363),vn=S(7357);const Ae=function Pt(N){return(0,un.A)(function($,ge){var nt=-1,Lt=ge.length,bn=Lt>1?ge[Lt-1]:void 0,ui=Lt>2?ge[2]:void 0;for(bn=N.length>3&&"function"==typeof bn?(Lt--,bn):void 0,ui&&(0,vn.A)(ge[0],ge[1],ui)&&(bn=Lt<3?void 0:bn,Lt=1),$=Object($);++nt<Lt;){var Hi=ge[nt];Hi&&N($,Hi,nt,bn)}return $})};var dt=S(1287),ut=S(5776),Mt=S(6792);const It=function Wt(N,$){return function(ge){return N($(ge))}},pn=It(Object.keys,Object);var ji=Object.prototype.hasOwnProperty;const St=function An(N){if(!(0,ut.A)(N))return pn(N);var $=[];for(var ge in Object(N))ji.call(N,ge)&&"constructor"!=ge&&$.push(ge);return $},Ht=function qt(N){return(0,dt.A)(N)?(0,Mt.A)(N):St(N)};var Cn=Object.prototype.hasOwnProperty,tn=Ae(function(N,$){if((0,ut.A)($)||(0,dt.A)($))an($,Ht($),N);else for(var ge in $)Cn.call($,ge)&&(0,fn.A)(N,ge,$[ge])});const fi=tn;var Zn=S(133),Dn=Ae(function(N,$){an($,(0,Zn.A)($),N)});const gn=Dn;var Nn=Ae(function(N,$,ge,nt){an($,(0,Zn.A)($),N,nt)});const Yn=Nn;var cr=Ae(function(N,$,ge,nt){an($,Ht($),N,nt)});const Ai=cr;var Qi=S(2125);const Ur=function Xr(N,$){for(var ge=-1,nt=$.length,Lt=Array(nt),bn=null==N;++ge<nt;)Lt[ge]=bn?void 0:(0,Qi.A)(N,$[ge]);return Lt},as=function eo(N,$){for(var ge=-1,nt=$.length,Lt=N.length;++ge<nt;)N[Lt+ge]=$[ge];return N};var uo=S(6944),mi=S(6513),ci=S(3744),yt=uo.A?uo.A.isConcatSpreadable:void 0;const Gt=function hn(N){return(0,ci.A)(N)||(0,mi.A)(N)||!!(yt&&N&&N[yt])},ri=function Gn(N,$,ge,nt,Lt){var bn=-1,ui=N.length;for(ge||(ge=Gt),Lt||(Lt=[]);++bn<ui;){var Hi=N[bn];$>0&&ge(Hi)?$>1?Gn(Hi,$-1,ge,nt,Lt):as(Lt,Hi):nt||(Lt[Lt.length]=Hi)}return Lt},At=function pi(N){return null!=N&&N.length?ri(N,1):[]};var Bn=S(9008),Mn=S(5014);const qn=function ni(N){return(0,Mn.A)((0,Bn.A)(N,void 0,At),N+"")},Bi=qn(Ur);var Gi=S(4982),Ii=S(5281),Ki=S(2661);const hi=It(Object.getPrototypeOf,Object);var Ve=Function.prototype.toString,He=Object.prototype.hasOwnProperty,mt=Ve.call(Object);const nn=function bt(N){if(!(0,Ki.A)(N)||"[object Object]"!=(0,Ii.A)(N))return!1;var $=hi(N);if(null===$)return!0;var ge=He.call($,"constructor")&&$.constructor;return"function"==typeof ge&&ge instanceof ge&&Ve.call(ge)==mt},qr=function _r(N){if(!(0,Ki.A)(N))return!1;var $=(0,Ii.A)(N);return"[object Error]"==$||"[object DOMException]"==$||"string"==typeof N.message&&"string"==typeof N.name&&!nn(N)};var Bo=(0,un.A)(function(N,$){try{return(0,Gi.A)(N,void 0,$)}catch(ge){return qr(ge)?ge:new Error(ge)}});const Eo=Bo,ol=function Ls(N,$){var ge;if("function"!=typeof $)throw new TypeError("Expected a function");return N=(0,oe.A)(N),function(){return--N>0&&(ge=$.apply(this,arguments)),N<=1&&($=void 0),ge}};var Va=S(4388),Ao=S(3595),Na=(0,un.A)(function(N,$,ge){var nt=1;if(ge.length){var Lt=(0,Ao.A)(ge,(0,Va.A)(Na));nt|=32}return(0,je.A)(N,nt,$,ge,Lt)});Na.placeholder={};const _l=Na;var gs=S(9162),Zs=S(4662),oa=qn(function(N,$){return(0,gs.A)($,function(ge){ge=(0,Zs.A)(ge),(0,ct.A)(N,ge,_l(N[ge],N))}),N});const no=oa;var Ya=(0,un.A)(function(N,$,ge){var nt=3;if(ge.length){var Lt=(0,Ao.A)(ge,(0,Va.A)(Ya));nt|=32}return(0,je.A)($,nt,N,ge,Lt)});Ya.placeholder={};const Lo=Ya;var ko=S(1705);const In=function jt(N,$,ge){var nt=-1,Lt=N.length;$<0&&($=-$>Lt?0:Lt+$),(ge=ge>Lt?Lt:ge)<0&&(ge+=Lt),Lt=$>ge?0:ge-$>>>0,$>>>=0;for(var bn=Array(Lt);++nt<Lt;)bn[nt]=N[nt+$];return bn},jn=function Rt(N,$,ge){var nt=N.length;return ge=void 0===ge?nt:ge,!$&&ge>=nt?N:In(N,$,ge)};var Tn=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");const Un=function Ri(N){return Tn.test(N)};var fr="\\ud800-\\udfff",Jo="["+fr+"]",$s="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",Js="\\ud83c[\\udffb-\\udfff]",Ws="[^"+fr+"]",es="(?:\\ud83c[\\udde6-\\uddff]){2}",Ma="[\\ud800-\\udbff][\\udc00-\\udfff]",wo="(?:"+$s+"|"+Js+")?",ea="[\\ufe0e\\ufe0f]?",sl=ea+wo+"(?:\\u200d(?:"+[Ws,es,Ma].join("|")+")"+ea+wo+")*",fl="(?:"+[Ws+$s+"?",$s,es,Ma,Jo].join("|")+")",Ia=RegExp(Js+"(?="+Js+")|"+fl+sl,"g");const Sl=function wa(N){return Un(N)?function al(N){return N.match(Ia)||[]}(N):function Yi(N){return N.split("")}(N)},la=function qc(N){return function($){$=(0,ko.A)($);var ge=Un($)?Sl($):void 0,nt=ge?ge[0]:$.charAt(0),Lt=ge?jn(ge,1).join(""):$.slice(1);return nt[N]()+Lt}},Sc=la("toUpperCase"),Qc=function Ec(N){return Sc((0,ko.A)(N).toLowerCase())},ec=function ql(N,$,ge,nt){var Lt=-1,bn=null==N?0:N.length;for(nt&&bn&&(ge=N[++Lt]);++Lt<bn;)ge=$(ge,N[Lt],Lt,N);return ge},ca=function Yc(N){return function($){return N?.[$]}},Rl=ca({\u00c0:"A",\u00c1:"A",\u00c2:"A",\u00c3:"A",\u00c4:"A",\u00c5:"A",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u00e3:"a",\u00e4:"a",\u00e5:"a",\u00c7:"C",\u00e7:"c",\u00d0:"D",\u00f0:"d",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u00cb:"E",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u00eb:"e",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u00cf:"I",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u00ef:"i",\u00d1:"N",\u00f1:"n",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u00d5:"O",\u00d6:"O",\u00d8:"O",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u00f5:"o",\u00f6:"o",\u00f8:"o",\u00d9:"U",\u00da:"U",\u00db:"U",\u00dc:"U",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u00fc:"u",\u00dd:"Y",\u00fd:"y",\u00ff:"y",\u00c6:"Ae",\u00e6:"ae",\u00de:"Th",\u00fe:"th",\u00df:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u010e:"D",\u0110:"D",\u010f:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011a:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011b:"e",\u011c:"G",\u011e:"G",\u0120:"G",\u0122:"G",\u011d:"g",\u011f:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012a:"I",\u012c:"I",\u012e:"I",\u0130:"I",\u0129:"i",\u012b:"i",\u012d:"i",\u012f:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013b:"L",\u013d:"L",\u013f:"L",\u0141:"L",\u013a:"l",\u013c:"l",\u013e:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014a:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014b:"n",\u014c:"O",\u014e:"O",\u0150:"O",\u014d:"o",\u014f:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015a:"S",\u015c:"S",\u015e:"S",\u0160:"S",\u015b:"s",\u015d:"s",\u015f:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016a:"U",\u016c:"U",\u016e:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016b:"u",\u016d:"u",\u016f:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017b:"Z",\u017d:"Z",\u017a:"z",\u017c:"z",\u017e:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017f:"s"});var yl=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,sc=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");const vc=function ta(N){return(N=(0,ko.A)(N))&&N.replace(yl,Rl).replace(sc,"")};var xu=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var Ll=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var Nc="\\ud800-\\udfff",re="\\u2700-\\u27bf",Ge="a-z\\xdf-\\xf6\\xf8-\\xff",vi="A-Z\\xc0-\\xd6\\xd8-\\xde",Xi="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Er="["+Xi+"]",so="\\d+",Fr="["+re+"]",zr="["+Ge+"]",ho="[^"+Nc+Xi+so+re+Ge+vi+"]",Ds="(?:\\ud83c[\\udde6-\\uddff]){2}",Xo="[\\ud800-\\udbff][\\udc00-\\udfff]",na="["+vi+"]",ya="(?:"+zr+"|"+ho+")",Je="(?:"+na+"|"+ho+")",at="(?:['\u2019](?:d|ll|m|re|s|t|ve))?",Oe="(?:['\u2019](?:D|LL|M|RE|S|T|VE))?",Ct="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",On="[\\ufe0e\\ufe0f]?",Di=On+Ct+"(?:\\u200d(?:"+["[^"+Nc+"]",Ds,Xo].join("|")+")"+On+Ct+")*",fo="(?:"+[Fr,Ds,Xo].join("|")+")"+Di,Uo=RegExp([na+"?"+zr+"+"+at+"(?="+[Er,na,"$"].join("|")+")",Je+"+"+Oe+"(?="+[Er,na+ya,"$"].join("|")+")",na+"?"+ya+"+"+at,na+"+"+Oe,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",so,fo].join("|"),"g");const Ks=function Za(N,$,ge){return N=(0,ko.A)(N),void 0===($=ge?void 0:$)?function Hs(N){return Ll.test(N)}(N)?function Gs(N){return N.match(Uo)||[]}(N):function Fc(N){return N.match(xu)||[]}(N):N.match($)||[]};var lc=RegExp("['\u2019]","g");const qd=function ou(N){return function($){return ec(Ks(vc($).replace(lc,"")),N,"")}};var da=qd(function(N,$,ge){return $=$.toLowerCase(),N+(ge?Qc($):$)});const nd=da,bl=function xp(){if(!arguments.length)return[];var N=arguments[0];return(0,ci.A)(N)?N:[N]};var _c=S(1860),cc=S(2949),qf=_c.A.isFinite,aa=Math.min;const Ra=function Tc(N){var $=Math[N];return function(ge,nt){if(ge=(0,cc.A)(ge),(nt=null==nt?0:aa((0,oe.A)(nt),292))&&qf(ge)){var Lt=((0,ko.A)(ge)+"e").split("e"),bn=$(Lt[0]+"e"+(+Lt[1]+nt));return+((Lt=((0,ko.A)(bn)+"e").split("e"))[0]+"e"+(+Lt[1]-nt))}return $(ge)}},ff=Ra("ceil");var Yt=S(7907);const Qh=function tc(N){var $=(0,Yt.A)(N);return $.__chain__=!0,$};var Su=Math.ceil,md=Math.max;const gd=function Ld(N,$,ge){$=(ge?(0,vn.A)(N,$,ge):void 0===$)?1:md((0,oe.A)($),0);var nt=null==N?0:N.length;if(!nt||$<1)return[];for(var Lt=0,bn=0,ui=Array(Su(nt/$));Lt<nt;)ui[bn++]=In(N,Lt,Lt+=$);return ui},Pu=function Eu(N,$,ge){return N==N&&(void 0!==ge&&(N=N<=ge?N:ge),void 0!==$&&(N=N>=$?N:$)),N},qs=function Lc(N,$,ge){return void 0===ge&&(ge=$,$=void 0),void 0!==ge&&(ge=(ge=(0,cc.A)(ge))==ge?ge:0),void 0!==$&&($=($=(0,cc.A)($))==$?$:0),Pu((0,cc.A)(N),$,ge)};var Xc=S(7015);var pu=S(6568),hu=S(2291);function El(N){var $=this.__data__=new Xc.A(N);this.size=$.size}El.prototype.clear=function Bu(){this.__data__=new Xc.A,this.size=0},El.prototype.delete=function Is(N){var $=this.__data__,ge=$.delete(N);return this.size=$.size,ge},El.prototype.get=function vd(N){return this.__data__.get(N)},El.prototype.has=function id(N){return this.__data__.has(N)},El.prototype.set=function Ed(N,$){var ge=this.__data__;if(ge instanceof Xc.A){var nt=ge.__data__;if(!pu.A||nt.length<199)return nt.push([N,$]),this.size=++ge.size,this;ge=this.__data__=new hu.A(nt)}return ge.set(N,$),this.size=ge.size,this};const uc=El,Td=function kd(N,$){return N&&an($,Ht($),N)};var Yl="object"==typeof exports&&exports&&!exports.nodeType&&exports,Bc=Yl&&"object"==typeof module&&module&&!module.nodeType&&module,hf=Bc&&Bc.exports===Yl?_c.A.Buffer:void 0,_e=hf?hf.allocUnsafe:void 0;const Re=function Dt(N,$){if($)return N.slice();var ge=N.length,nt=_e?_e(ge):new N.constructor(ge);return N.copy(nt),nt};var tt=S(4528);const gi=function mn(N,$){for(var ge=-1,nt=null==N?0:N.length,Lt=0,bn=[];++ge<nt;){var ui=N[ge];$(ui,ge,N)&&(bn[Lt++]=ui)}return bn},or=function rr(){return[]};var La=Object.prototype.propertyIsEnumerable,vs=Object.getOwnPropertySymbols,Qo=vs?function(N){return null==N?[]:(N=Object(N),gi(vs(N),function($){return La.call(N,$)}))}:or;const ll=Qo;var yc=Object.getOwnPropertySymbols?function(N){for(var $=[];N;)as($,ll(N)),N=hi(N);return $}:or;const Ue=yc,Ut=function rt(N,$,ge){var nt=$(N);return(0,ci.A)(N)?nt:as(nt,ge(N))},Kn=function Rn(N){return Ut(N,Ht,ll)},Ce=function Y(N){return Ut(N,Zn.A,Ue)};var ue=S(8425);const Ze=(0,ue.A)(_c.A,"DataView"),rn=(0,ue.A)(_c.A,"Promise"),oi=(0,ue.A)(_c.A,"Set");var Yr=S(5756),rs=S(8736),ls="[object Map]",Hl="[object Promise]",dc="[object Set]",ws="[object WeakMap]",Vc="[object DataView]",Wo=(0,rs.A)(Ze),sr=(0,rs.A)(pu.A),ro=(0,rs.A)(rn),Ic=(0,rs.A)(oi),Sp=(0,rs.A)(Yr.A),au=Ii.A;(Ze&&au(new Ze(new ArrayBuffer(1)))!=Vc||pu.A&&au(new pu.A)!=ls||rn&&au(rn.resolve())!=Hl||oi&&au(new oi)!=dc||Yr.A&&au(new Yr.A)!=ws)&&(au=function(N){var $=(0,Ii.A)(N),ge="[object Object]"==$?N.constructor:void 0,nt=ge?(0,rs.A)(ge):"";if(nt)switch(nt){case Wo:return Vc;case sr:return ls;case ro:return Hl;case Ic:return dc;case Sp:return ws}return $});const Uu=au;var wv=Object.prototype.hasOwnProperty;const Yh=_c.A.Uint8Array,Qd=function yg(N){var $=new N.constructor(N.byteLength);return new Yh($).set(new Yh(N)),$};var mf=/\w*$/;var Zc=uo.A?uo.A.prototype:void 0,Tu=Zc?Zc.valueOf:void 0;const xr=function Ji(N,$){var ge=$?Qd(N.buffer):N.buffer;return new N.constructor(ge,N.byteOffset,N.length)},Wu=function Om(N,$,ge){var nt=N.constructor;switch($){case"[object ArrayBuffer]":return Qd(N);case"[object Boolean]":case"[object Date]":return new nt(+N);case"[object DataView]":return function xv(N,$){var ge=$?Qd(N.buffer):N.buffer;return new N.constructor(ge,N.byteOffset,N.byteLength)}(N,ge);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return xr(N,ge);case"[object Map]":case"[object Set]":return new nt;case"[object Number]":case"[object String]":return new nt(N);case"[object RegExp]":return function U_(N){var $=new N.constructor(N.source,mf.exec(N));return $.lastIndex=N.lastIndex,$}(N);case"[object Symbol]":return function If(N){return Tu?Object(Tu.call(N)):{}}(N)}};var zl=S(282);const Mp=function Tp(N){return"function"!=typeof N.constructor||(0,ut.A)(N)?{}:(0,zl.A)(hi(N))};var Zd=S(259);var _d=S(778),Mu=S(3340),Jd=Mu.A&&Mu.A.isMap;const Iu=Jd?(0,_d.A)(Jd):function ap(N){return(0,Ki.A)(N)&&"[object Map]"==Uu(N)};var ns=S(554);var xh=Mu.A&&Mu.A.isSet;const Md=xh?(0,_d.A)(xh):function gf(N){return(0,Ki.A)(N)&&"[object Set]"==Uu(N)};var r1="[object Arguments]",od="[object Function]",Zh="[object Object]",ra={};ra[r1]=ra["[object Array]"]=ra["[object ArrayBuffer]"]=ra["[object DataView]"]=ra["[object Boolean]"]=ra["[object Date]"]=ra["[object Float32Array]"]=ra["[object Float64Array]"]=ra["[object Int8Array]"]=ra["[object Int16Array]"]=ra["[object Int32Array]"]=ra["[object Map]"]=ra["[object Number]"]=ra[Zh]=ra["[object RegExp]"]=ra["[object Set]"]=ra["[object String]"]=ra["[object Symbol]"]=ra["[object Uint8Array]"]=ra["[object Uint8ClampedArray]"]=ra["[object Uint16Array]"]=ra["[object Uint32Array]"]=!0,ra["[object Error]"]=ra[od]=ra["[object WeakMap]"]=!1;const Ja=function Rf(N,$,ge,nt,Lt,bn){var ui,Hi=1&$,yr=2&$,fs=4&$;if(ge&&(ui=Lt?ge(N,nt,Lt,bn):ge(N)),void 0!==ui)return ui;if(!(0,ns.A)(N))return N;var co=(0,ci.A)(N);if(co){if(ui=function op(N){var $=N.length,ge=new N.constructor($);return $&&"string"==typeof N[0]&&wv.call(N,"index")&&(ge.index=N.index,ge.input=N.input),ge}(N),!Hi)return(0,tt.A)(N,ui)}else{var Do=Uu(N),Ts=Do==od||"[object GeneratorFunction]"==Do;if((0,Zd.A)(N))return Re(N,Hi);if(Do==Zh||Do==r1||Ts&&!Lt){if(ui=yr||Ts?{}:Mp(N),!Hi)return yr?function ne(N,$){return an(N,Ue(N),$)}(N,function Pc(N,$){return N&&an($,(0,Zn.A)($),N)}(ui,N)):function Sa(N,$){return an(N,ll(N),$)}(N,Td(ui,N))}else{if(!ra[Do])return Lt?N:{};ui=Wu(N,Do,Hi)}}bn||(bn=new uc);var os=bn.get(N);if(os)return os;bn.set(N,ui),Md(N)?N.forEach(function(il){ui.add(Rf(il,$,ge,il,N,bn))}):Iu(N)&&N.forEach(function(il,Da){ui.set(Da,Rf(il,$,ge,Da,N,bn))});var Xs=co?void 0:(fs?yr?Ce:Kn:yr?Zn.A:Ht)(N);return(0,gs.A)(Xs||N,function(il,Da){Xs&&(il=N[Da=il]),(0,fn.A)(ui,Da,Rf(il,$,ge,Da,N,bn))}),ui},Ss=function sd(N){return Ja(N,4)},Gl=function Eh(N){return Ja(N,5)},V=function th(N,$){return Ja(N,5,$="function"==typeof $?$:void 0)},U=function E(N,$){return Ja(N,4,$="function"==typeof $?$:void 0)};var ee=S(8754);const Nt=function Xe(){return new ee.A(this.value(),this.__chain__)},gr=function Ei(N){for(var $=-1,ge=null==N?0:N.length,nt=0,Lt=[];++$<ge;){var bn=N[$];bn&&(Lt[nt++]=bn)}return Lt},vo=function ur(){var N=arguments.length;if(!N)return[];for(var $=Array(N-1),ge=arguments[0],nt=N;nt--;)$[nt-1]=arguments[nt];return as((0,ci.A)(ge)?(0,tt.A)(ge):[ge],ri($,1))};var Gr=S(6689);function Ga(N){var $=-1,ge=null==N?0:N.length;for(this.__data__=new hu.A;++$<ge;)this.add(N[$])}Ga.prototype.add=Ga.prototype.push=function cs(N){return this.__data__.set(N,"__lodash_hash_undefined__"),this},Ga.prototype.has=function gu(N){return this.__data__.has(N)};const qa=Ga,Pm=function Th(N,$){for(var ge=-1,nt=null==N?0:N.length;++ge<nt;)if($(N[ge],ge,N))return!0;return!1},ih=function nh(N,$){return N.has($)},vE=function o1(N,$,ge,nt,Lt,bn){var ui=1&ge,Hi=N.length,yr=$.length;if(Hi!=yr&&!(ui&&yr>Hi))return!1;var fs=bn.get(N),co=bn.get($);if(fs&&co)return fs==$&&co==N;var Do=-1,Ts=!0,os=2&ge?new qa:void 0;for(bn.set(N,$),bn.set($,N);++Do<Hi;){var gl=N[Do],Xs=$[Do];if(nt)var il=ui?nt(Xs,gl,Do,$,N,bn):nt(gl,Xs,Do,N,$,bn);if(void 0!==il){if(il)continue;Ts=!1;break}if(os){if(!Pm($,function(Da,fd){if(!ih(os,fd)&&(gl===Da||Lt(gl,Da,ge,nt,bn)))return os.push(fd)})){Ts=!1;break}}else if(gl!==Xs&&!Lt(gl,Xs,ge,nt,bn)){Ts=!1;break}}return bn.delete(N),bn.delete($),Ts};var ef=S(1319);const z_=function x0(N){var $=-1,ge=Array(N.size);return N.forEach(function(nt,Lt){ge[++$]=[Lt,nt]}),ge},Dc=function wg(N){var $=-1,ge=Array(N.size);return N.forEach(function(nt){ge[++$]=nt}),ge};var yi=uo.A?uo.A.prototype:void 0,Vi=yi?yi.valueOf:void 0;var pc=Object.prototype.hasOwnProperty;var bd=S(8885),rh="[object Arguments]",Xf="[object Array]",Qa="[object Object]",Tr=Object.prototype.hasOwnProperty;const lp=function Vs(N,$,ge,nt,Lt,bn){var ui=(0,ci.A)(N),Hi=(0,ci.A)($),yr=ui?Xf:Uu(N),fs=Hi?Xf:Uu($),co=(yr=yr==rh?Qa:yr)==Qa,Do=(fs=fs==rh?Qa:fs)==Qa,Ts=yr==fs;if(Ts&&(0,Zd.A)(N)){if(!(0,Zd.A)($))return!1;ui=!0,co=!1}if(Ts&&!co)return bn||(bn=new uc),ui||(0,bd.A)(N)?vE(N,$,ge,nt,Lt,bn):function tr(N,$,ge,nt,Lt,bn,ui){switch(ge){case"[object DataView]":if(N.byteLength!=$.byteLength||N.byteOffset!=$.byteOffset)return!1;N=N.buffer,$=$.buffer;case"[object ArrayBuffer]":return!(N.byteLength!=$.byteLength||!bn(new Yh(N),new Yh($)));case"[object Boolean]":case"[object Date]":case"[object Number]":return(0,ef.A)(+N,+$);case"[object Error]":return N.name==$.name&&N.message==$.message;case"[object RegExp]":case"[object String]":return N==$+"";case"[object Map]":var Hi=z_;case"[object Set]":if(Hi||(Hi=Dc),N.size!=$.size&&!(1&nt))return!1;var fs=ui.get(N);if(fs)return fs==$;nt|=2,ui.set(N,$);var co=vE(Hi(N),Hi($),nt,Lt,bn,ui);return ui.delete(N),co;case"[object Symbol]":if(Vi)return Vi.call(N)==Vi.call($)}return!1}(N,$,yr,ge,nt,Lt,bn);if(!(1&ge)){var os=co&&Tr.call(N,"__wrapped__"),gl=Do&&Tr.call($,"__wrapped__");if(os||gl){var Xs=os?N.value():N,il=gl?$.value():$;return bn||(bn=new uc),Lt(Xs,il,ge,nt,bn)}}return!!Ts&&(bn||(bn=new uc),function Yu(N,$,ge,nt,Lt,bn){var ui=1&ge,Hi=Kn(N),yr=Hi.length;if(yr!=Kn($).length&&!ui)return!1;for(var Do=yr;Do--;){var Ts=Hi[Do];if(!(ui?Ts in $:pc.call($,Ts)))return!1}var os=bn.get(N),gl=bn.get($);if(os&&gl)return os==$&&gl==N;var Xs=!0;bn.set(N,$),bn.set($,N);for(var il=ui;++Do<yr;){var Da=N[Ts=Hi[Do]],fd=$[Ts];if(nt)var zd=ui?nt(fd,Da,Ts,$,N,bn):nt(Da,fd,Ts,N,$,bn);if(!(void 0===zd?Da===fd||Lt(Da,fd,ge,nt,bn):zd)){Xs=!1;break}il||(il="constructor"==Ts)}if(Xs&&!il){var Sm=N.constructor,Ef=$.constructor;Sm!=Ef&&"constructor"in N&&"constructor"in $&&!("function"==typeof Sm&&Sm instanceof Sm&&"function"==typeof Ef&&Ef instanceof Ef)&&(Xs=!1)}return bn.delete(N),bn.delete($),Xs}(N,$,ge,nt,Lt,bn))},Lf=function ka(N,$,ge,nt,Lt){return N===$||(null==N||null==$||!(0,Ki.A)(N)&&!(0,Ki.A)($)?N!=N&&$!=$:lp(N,$,ge,nt,ka,Lt))},S0=function G_(N,$,ge,nt){var Lt=ge.length,bn=Lt,ui=!nt;if(null==N)return!bn;for(N=Object(N);Lt--;){var Hi=ge[Lt];if(ui&&Hi[2]?Hi[1]!==N[Hi[0]]:!(Hi[0]in N))return!1}for(;++Lt<bn;){var yr=(Hi=ge[Lt])[0],fs=N[yr],co=Hi[1];if(ui&&Hi[2]){if(void 0===fs&&!(yr in N))return!1}else{var Do=new uc;if(nt)var Ts=nt(fs,co,yr,N,$,Do);if(!(void 0===Ts?Lf(co,fs,3,nt,Do):Ts))return!1}}return!0},xg=function vf(N){return N==N&&!(0,ns.A)(N)},Bm=function s1(N){for(var $=Ht(N),ge=$.length;ge--;){var nt=$[ge],Lt=N[nt];$[ge]=[nt,Lt,xg(Lt)]}return $},bs=function Ir(N,$){return function(ge){return null!=ge&&ge[N]===$&&(void 0!==$||N in Object(ge))}},Es=function Ko(N){var $=Bm(N);return 1==$.length&&$[0][2]?bs($[0][0],$[0][1]):function(ge){return ge===N||S0(ge,N,$)}},wc=function jc(N,$){return null!=N&&$ in Object(N)};var Ho=S(4512),cp=S(6225),Mh=S(5481);const sh=function E0(N,$,ge){for(var nt=-1,Lt=($=(0,Ho.A)($,N)).length,bn=!1;++nt<Lt;){var ui=(0,Zs.A)($[nt]);if(!(bn=null!=N&&ge(N,ui)))break;N=N[ui]}return bn||++nt!=Lt?bn:!!(Lt=null==N?0:N.length)&&(0,Mh.A)(Lt)&&(0,cp.A)(ui,Lt)&&((0,ci.A)(N)||(0,mi.A)(N))},iD=function nD(N,$){return null!=N&&sh(N,$,wc)};var T0=S(3097);const ux=function rD(N,$){return(0,T0.A)(N)&&xg($)?bs((0,Zs.A)(N),$):function(ge){var nt=(0,Qi.A)(ge,N);return void 0===nt&&nt===$?iD(ge,N):Lf($,nt,3)}};var Ap=S(7003);const M0=function _E(N){return function($){return $?.[N]}};var mr=S(4501);const Pl=function oD(N){return(0,T0.A)(N)?M0((0,Zs.A)(N)):function Ua(N){return function($){return(0,mr.A)($,N)}}(N)},fa=function dx(N){return"function"==typeof N?N:null==N?Ap.A:"object"==typeof N?(0,ci.A)(N)?ux(N[0],N[1]):Es(N):Pl(N)},aD=function sD(N){var $=null==N?0:N.length,ge=fa;return N=$?(0,Gr.A)(N,function(nt){if("function"!=typeof nt[1])throw new TypeError("Expected a function");return[ge(nt[0]),nt[1]]}):[],(0,un.A)(function(nt){for(var Lt=-1;++Lt<$;){var bn=N[Lt];if((0,Gi.A)(bn[0],this,nt))return(0,Gi.A)(bn[1],this,nt)}})},yE=function a1(N,$,ge){var nt=ge.length;if(null==N)return!nt;for(N=Object(N);nt--;){var Lt=ge[nt],ui=N[Lt];if(void 0===ui&&!(Lt in N)||!(0,$[Lt])(ui))return!1}return!0},nf=function bE(N){return function xA(N){var $=Ht(N);return function(ge){return yE(ge,N,$)}}(Ja(N,1))},lD=function _f(N,$){return null==$||yE(N,$,Ht($))};var Fp=S(1913);const cD=function Eg(N,$,ge,nt){for(var Lt=-1,bn=null==N?0:N.length;++Lt<bn;){var ui=N[Lt];$(nt,ui,ge(ui),N)}return nt},CE=function uD(N){return function($,ge,nt){for(var Lt=-1,bn=Object($),ui=nt($),Hi=ui.length;Hi--;){var yr=ui[N?Hi:++Lt];if(!1===ge(bn[yr],yr,bn))break}return $}},Fv=CE(),Ah=function dD(N,$){return N&&Fv(N,$,Ht)},q_=function K_(N,$){return function(ge,nt){if(null==ge)return ge;if(!(0,dt.A)(ge))return N(ge,nt);for(var Lt=ge.length,bn=$?Lt:-1,ui=Object(ge);($?bn--:++bn<Lt)&&!1!==nt(ui[bn],bn,ui););return ge}},Vm=q_(Ah),fD=function l1(N,$,ge,nt){return Vm(N,function(Lt,bn,ui){$(nt,Lt,ge(Lt),ui)}),nt},Tg=function mx(N,$){return function(ge,nt){var Lt=(0,ci.A)(ge)?cD:fD,bn=$?$():{};return Lt(ge,N,fa(nt),bn)}};var DE=Object.prototype.hasOwnProperty,Vd=Tg(function(N,$,ge){DE.call(N,ge)?++N[ge]:(0,ct.A)(N,ge,1)});const Ig=Vd,A0=function Au(N,$){var ge=(0,zl.A)(N);return null==$?ge:Td(ge,$)};function pD(N,$,ge){var nt=(0,je.A)(N,8,void 0,void 0,void 0,void 0,void 0,$=ge?void 0:$);return nt.placeholder=pD.placeholder,nt}pD.placeholder={};const Nv=pD;function gx(N,$,ge){var nt=(0,je.A)(N,16,void 0,void 0,void 0,void 0,void 0,$=ge?void 0:$);return nt.placeholder=gx.placeholder,nt}gx.placeholder={};const Rv=gx,u1=function(){return _c.A.Date.now()};var Q_=Math.max,d1=Math.min;const Np=function Lv(N,$,ge){var nt,Lt,bn,ui,Hi,yr,fs=0,co=!1,Do=!1,Ts=!0;if("function"!=typeof N)throw new TypeError("Expected a function");function os(df){var Cp=nt,Yb=Lt;return nt=Lt=void 0,fs=df,ui=N.apply(Yb,Cp)}function il(df){var Cp=df-yr;return void 0===yr||Cp>=$||Cp<0||Do&&df-fs>=bn}function Da(){var df=u1();if(il(df))return fd(df);Hi=setTimeout(Da,function Xs(df){var Em=$-(df-yr);return Do?d1(Em,bn-(df-fs)):Em}(df))}function fd(df){return Hi=void 0,Ts&&nt?os(df):(nt=Lt=void 0,ui)}function Ef(){var df=u1(),Cp=il(df);if(nt=arguments,Lt=this,yr=df,Cp){if(void 0===Hi)return function gl(df){return fs=df,Hi=setTimeout(Da,$),co?os(df):ui}(yr);if(Do)return clearTimeout(Hi),Hi=setTimeout(Da,$),os(yr)}return void 0===Hi&&(Hi=setTimeout(Da,$)),ui}return $=(0,cc.A)($)||0,(0,ns.A)(ge)&&(co=!!ge.leading,bn=(Do="maxWait"in ge)?Q_((0,cc.A)(ge.maxWait)||0,$):bn,Ts="trailing"in ge?!!ge.trailing:Ts),Ef.cancel=function zd(){void 0!==Hi&&clearTimeout(Hi),fs=0,nt=yr=Lt=Hi=void 0},Ef.flush=function Sm(){return void 0===Hi?ui:fd(u1())},Ef},wE=function Y_(N,$){return null==N||N!=N?$:N};var kv=S(9311);const F0=function O0(N,$,ge){(void 0!==ge&&!(0,ef.A)(N[$],ge)||void 0===ge&&!($ in N))&&(0,ct.A)(N,$,ge)},_u=function f1(N){return(0,Ki.A)(N)&&(0,dt.A)(N)};var Um=S(129);const vx=function DM(N,$){if(("constructor"!==$||"function"!=typeof N[$])&&"__proto__"!=$)return N[$]},gD=function mD(N){return an(N,(0,Zn.A)(N))},im=function $m(N,$,ge,nt,Lt){N!==$&&Fv($,function(bn,ui){if(Lt||(Lt=new uc),(0,ns.A)(bn))!function nm(N,$,ge,nt,Lt,bn,ui){var Hi=vx(N,ge),yr=vx($,ge),fs=ui.get(yr);if(fs)F0(N,ge,fs);else{var co=bn?bn(Hi,yr,ge+"",N,$,ui):void 0,Do=void 0===co;if(Do){var Ts=(0,ci.A)(yr),os=!Ts&&(0,Zd.A)(yr),gl=!Ts&&!os&&(0,bd.A)(yr);co=yr,Ts||os||gl?(0,ci.A)(Hi)?co=Hi:_u(Hi)?co=(0,tt.A)(Hi):os?(Do=!1,co=Re(yr,!0)):gl?(Do=!1,co=xr(yr,!0)):co=[]:nn(yr)||(0,mi.A)(yr)?(co=Hi,(0,mi.A)(Hi)?co=gD(Hi):(!(0,ns.A)(Hi)||(0,Um.A)(Hi))&&(co=Mp(yr))):Do=!1}Do&&(ui.set(yr,co),Lt(co,yr,nt,bn,ui),ui.delete(yr)),F0(N,ge,co)}}(N,$,ui,ge,$m,nt,Lt);else{var Hi=nt?nt(vx(N,ui),bn,ui+"",N,$,Lt):void 0;void 0===Hi&&(Hi=bn),F0(N,ui,Hi)}},Zn.A)},Oh=function xE(N,$,ge,nt,Lt,bn){return(0,ns.A)(N)&&(0,ns.A)($)&&(bn.set($,N),im(N,$,void 0,xE,bn),bn.delete($)),N};var N0=Ae(function(N,$,ge,nt){im(N,$,ge,nt)});const R0=N0;var vD=(0,un.A)(function(N){return N.push(void 0,Oh),(0,Gi.A)(R0,void 0,N)});const _D=vD,p1=function yx(N,$,ge){if("function"!=typeof N)throw new TypeError("Expected a function");return setTimeout(function(){N.apply(void 0,ge)},$)};var Fh=(0,un.A)(function(N,$){return p1(N,1,$)});const bx=Fh;var Pv=(0,un.A)(function(N,$,ge){return p1(N,(0,cc.A)($)||0,ge)});const Z_=Pv;var Ag=S(3854);const ah=function Og(N,$,ge){for(var nt=-1,Lt=null==N?0:N.length;++nt<Lt;)if(ge($,N[nt]))return!0;return!1},om=function rm(N,$,ge,nt){var Lt=-1,bn=Ag.A,ui=!0,Hi=N.length,yr=[],fs=$.length;if(!Hi)return yr;ge&&($=(0,Gr.A)($,(0,_d.A)(ge))),nt?(bn=ah,ui=!1):$.length>=200&&(bn=ih,ui=!1,$=new qa($));e:for(;++Lt<Hi;){var co=N[Lt],Do=null==ge?co:ge(co);if(co=nt||0!==co?co:0,ui&&Do==Do){for(var Ts=fs;Ts--;)if($[Ts]===Do)continue e;yr.push(co)}else bn($,Do,nt)||yr.push(co)}return yr};var k0=(0,un.A)(function(N,$){return _u(N)?om(N,ri($,1,_u,!0)):[]});const yD=k0,Jf=function Cx(N){var $=null==N?0:N.length;return $?N[$-1]:void 0};var ic=(0,un.A)(function(N,$){var ge=Jf($);return _u(ge)&&(ge=void 0),_u(N)?om(N,ri($,1,_u,!0),fa(ge)):[]});const Dx=ic;var wx=(0,un.A)(function(N,$){var ge=Jf($);return _u(ge)&&(ge=void 0),_u(N)?om(N,ri($,1,_u,!0),void 0,ge):[]});const Bv=wx;var Fg=Ee(function(N,$){return N/$},1);const Vv=Fg,bD=function ad(N,$,ge){var nt=null==N?0:N.length;return nt?($=ge||void 0===$?1:(0,oe.A)($),In(N,$<0?0:$,nt)):[]},Ng=function xx(N,$,ge){var nt=null==N?0:N.length;return nt?($=ge||void 0===$?1:(0,oe.A)($),In(N,0,($=nt-$)<0?0:$)):[]},J_=function Id(N,$,ge,nt){for(var Lt=N.length,bn=nt?Lt:-1;(nt?bn--:++bn<Lt)&&$(N[bn],bn,N););return ge?In(N,nt?0:bn,nt?bn+1:Lt):In(N,nt?bn+1:0,nt?Lt:bn)},ey=function up(N,$){return N&&N.length?J_(N,fa($),!0,!0):[]},Sx=function h1(N,$){return N&&N.length?J_(N,fa($),!0):[]},kf=function P0(N){return"function"==typeof N?N:Ap.A},jv=function Ex(N,$){return((0,ci.A)(N)?gs.A:Vm)(N,kf($))},Tx=function B0(N,$){for(var ge=null==N?0:N.length;ge--&&!1!==$(N[ge],ge,N););return N},ty=CE(!0),dp=function wM(N,$){return N&&ty(N,$,Ht)},lh=q_(dp,!0),Ou=function Nh(N,$){return((0,ci.A)(N)?Tx:lh)(N,kf($))},Rg=function CD(N,$,ge){N=(0,ko.A)(N),$=(0,ie.A)($);var nt=N.length,Lt=ge=void 0===ge?nt:Pu((0,oe.A)(ge),0,nt);return(ge-=$.length)>=0&&N.slice(ge,Lt)==$},g1=function iy(N){return function($){var ge=Uu($);return"[object Map]"==ge?z_($):"[object Set]"==ge?function wD(N){var $=-1,ge=Array(N.size);return N.forEach(function(nt){ge[++$]=[nt,nt]}),ge}($):function m1(N,$){return(0,Gr.A)($,function(ge){return[ge,N[ge]]})}($,N($))}},Wm=g1(Ht),Rp=g1(Zn.A),xD=ca({"&":"&","<":"<",">":">",'"':""","'":"'"});var j0=/[&<>"']/g,Rh=RegExp(j0.source);const yf=function Lp(N){return(N=(0,ko.A)(N))&&Rh.test(N)?N.replace(j0,xD):N};var Uc=/[\\^$.*+?()[\]{}|]/g,am=RegExp(Uc.source);const SE=function oy(N){return(N=(0,ko.A)(N))&&am.test(N)?N.replace(Uc,"\\$&"):N},_1=function v1(N,$){for(var ge=-1,nt=null==N?0:N.length;++ge<nt;)if(!$(N[ge],ge,N))return!1;return!0},Ix=function Mx(N,$){var ge=!0;return Vm(N,function(nt,Lt,bn){return ge=!!$(nt,Lt,bn)}),ge},Ax=function $v(N,$,ge){var nt=(0,ci.A)(N)?_1:Ix;return ge&&(0,vn.A)(N,$,ge)&&($=void 0),nt(N,fa($))},y1=function U0(N){return N?Pu((0,oe.A)(N),0,4294967295):0},TE=function b1(N,$,ge,nt){var Lt=null==N?0:N.length;return Lt?(ge&&"number"!=typeof ge&&(0,vn.A)(N,$,ge)&&(ge=0,nt=Lt),function Lh(N,$,ge,nt){var Lt=N.length;for((ge=(0,oe.A)(ge))<0&&(ge=-ge>Lt?0:Lt+ge),(nt=void 0===nt||nt>Lt?Lt:(0,oe.A)(nt))<0&&(nt+=Lt),nt=ge>nt?0:y1(nt);ge<nt;)N[ge++]=$;return N}(N,$,ge,nt)):[]},C1=function SD(N,$){var ge=[];return Vm(N,function(nt,Lt,bn){$(nt,Lt,bn)&&ge.push(nt)}),ge},$0=function Fx(N,$){return((0,ci.A)(N)?gi:C1)(N,fa($))},Hv=function Wv(N){return function($,ge,nt){var Lt=Object($);if(!(0,dt.A)($)){var bn=fa(ge);$=Ht($),ge=function(Hi){return bn(Lt[Hi],Hi,Lt)}}var ui=N($,ge,nt);return ui>-1?Lt[bn?$[ui]:ui]:void 0}};var Hm=S(8556),Nx=Math.max;const lm=function ME(N,$,ge){var nt=null==N?0:N.length;if(!nt)return-1;var Lt=null==ge?0:(0,oe.A)(ge);return Lt<0&&(Lt=Nx(nt+Lt,0)),(0,Hm.A)(N,fa($),Lt)},Rx=Hv(lm),ED=function H0(N,$,ge){var nt;return ge(N,function(Lt,bn,ui){if($(Lt,bn,ui))return nt=bn,!1}),nt},kg=function z0(N,$){return ED(N,fa($),Ah)};var Lx=Math.max,kx=Math.min;const MD=function TD(N,$,ge){var nt=null==N?0:N.length;if(!nt)return-1;var Lt=nt-1;return void 0!==ge&&(Lt=(0,oe.A)(ge),Lt=ge<0?Lx(nt+Lt,0):kx(Lt,nt-1)),(0,Hm.A)(N,fa($),Lt,!0)},G0=Hv(MD),ID=function K0(N,$){return ED(N,fa($),dp)},cm=function Cd(N){return N&&N.length?N[0]:void 0},zv=function IE(N,$){var ge=-1,nt=(0,dt.A)(N)?Array(N.length):[];return Vm(N,function(Lt,bn,ui){nt[++ge]=$(Lt,bn,ui)}),nt},AD=function SM(N,$){return((0,ci.A)(N)?Gr.A:zv)(N,fa($))},Gv=function rf(N,$){return ri(AD(N,$),1)},Px=function D1(N,$){return ri(AD(N,$),1/0)},w1=function OE(N,$,ge){return ge=void 0===ge?1:(0,oe.A)(ge),ri(AD(N,$),ge)},Kv=function EM(N){return null!=N&&N.length?ri(N,1/0):[]},FE=function OD(N,$){return null!=N&&N.length?($=void 0===$?1:(0,oe.A)($),ri(N,$)):[]},sy=function TM(N){return(0,je.A)(N,512)},q0=Ra("floor");var qv=S(8462),Pg=S(3395),jx=S(6558);const E1=function LE(N){return qn(function($){var ge=$.length,nt=ge,Lt=ee.A.prototype.thru;for(N&&$.reverse();nt--;){var bn=$[nt];if("function"!=typeof bn)throw new TypeError("Expected a function");if(Lt&&!ui&&"wrapper"==(0,Pg.A)(bn))var ui=new ee.A([],!0)}for(nt=ui?nt:ge;++nt<ge;){var Hi=(0,Pg.A)(bn=$[nt]),yr="wrapper"==Hi?(0,qv.A)(bn):void 0;ui=yr&&(0,jx.A)(yr[0])&&424==yr[1]&&!yr[4].length&&1==yr[9]?ui[(0,Pg.A)(yr[0])].apply(ui,yr[3]):1==bn.length&&(0,jx.A)(bn)?ui[Hi]():ui.thru(bn)}return function(){var fs=arguments,co=fs[0];if(ui&&1==fs.length&&(0,ci.A)(co))return ui.plant(co).value();for(var Do=0,Ts=ge?$[Do].apply(this,fs):co;++Do<ge;)Ts=$[Do].call(this,Ts);return Ts}})},Y0=E1(),M1=E1(!0),PE=function MM(N,$){return null==N?N:Fv(N,kf($),Zn.A)},I1=function ND(N,$){return null==N?N:ty(N,kf($),Zn.A)},fp=function EA(N,$){return N&&Ah(N,kf($))},Ux=function X0(N,$){return N&&dp(N,kf($))},Yv=function Qv(N){for(var $=-1,ge=null==N?0:N.length,nt={};++$<ge;){var Lt=N[$];nt[Lt[0]]=Lt[1]}return nt},ay=function IM(N,$){return gi($,function(ge){return(0,Um.A)(N[ge])})},RD=function BE(N){return null==N?[]:ay(N,Ht(N))},VE=function Z0(N){return null==N?[]:ay(N,(0,Zn.A)(N))};var zm=Object.prototype.hasOwnProperty,Xv=Tg(function(N,$,ge){zm.call(N,ge)?N[ge].push($):(0,ct.A)(N,ge,[$])});const LD=Xv,Bg=function Zv(N,$){return N>$},Vg=function kD(N){return function($,ge){return"string"==typeof $&&"string"==typeof ge||($=(0,cc.A)($),ge=(0,cc.A)(ge)),N($,ge)}},A1=Vg(Bg);var jg=Vg(function(N,$){return N>=$});const O1=jg;var Ug=Object.prototype.hasOwnProperty;const kp=function F1(N,$){return null!=N&&Ug.call(N,$)},ep=function $g(N,$){return null!=N&&sh(N,$,kp)};var um=Math.max,jd=Math.min;var pp=S(8747);const Pf=function J0(N,$,ge){return $=(0,pp.A)($),void 0===ge?(ge=$,$=0):ge=(0,pp.A)(ge),function Hx(N,$,ge){return N>=jd($,ge)&&N<um($,ge)}(N=(0,cc.A)(N),$,ge)};var tp=S(3776);const Wg=function uy(N){return"string"==typeof N||!(0,ci.A)(N)&&(0,Ki.A)(N)&&"[object String]"==(0,Ii.A)(N)},sf=function _a(N,$){return(0,Gr.A)($,function(ge){return N[ge]})},Al=function cl(N){return null==N?[]:sf(N,Ht(N))};var Ud=Math.max;const dm=function np(N,$,ge,nt){N=(0,dt.A)(N)?N:Al(N),ge=ge&&!nt?(0,oe.A)(ge):0;var Lt=N.length;return ge<0&&(ge=Ud(Lt+ge,0)),Wg(N)?ge<=Lt&&N.indexOf($,ge)>-1:!!Lt&&(0,tp.A)(N,$,ge)>-1};var PD=Math.max;const eu=function hp(N,$,ge){var nt=null==N?0:N.length;if(!nt)return-1;var Lt=null==ge?0:(0,oe.A)(ge);return Lt<0&&(Lt=PD(nt+Lt,0)),(0,tp.A)(N,$,Lt)},Xu=function Jv(N){return null!=N&&N.length?In(N,0,-1):[]};var e_=Math.min;const tu=function N1(N,$,ge){for(var nt=ge?ah:Ag.A,Lt=N[0].length,bn=N.length,ui=bn,Hi=Array(bn),yr=1/0,fs=[];ui--;){var co=N[ui];ui&&$&&(co=(0,Gr.A)(co,(0,_d.A)($))),yr=e_(co.length,yr),Hi[ui]=!ge&&($||Lt>=120&&co.length>=120)?new qa(ui&&co):void 0}co=N[0];var Do=-1,Ts=Hi[0];e:for(;++Do<Lt&&fs.length<yr;){var os=co[Do],gl=$?$(os):os;if(os=ge||0!==os?os:0,!(Ts?ih(Ts,gl):nt(fs,gl,ge))){for(ui=bn;--ui;){var Xs=Hi[ui];if(!(Xs?ih(Xs,gl):nt(N[ui],gl,ge)))continue e}Ts&&Ts.push(gl),fs.push(os)}}return fs},zo=function dy(N){return _u(N)?N:[]};var $d=(0,un.A)(function(N){var $=(0,Gr.A)(N,zo);return $.length&&$[0]===N[0]?tu($):[]});const Wd=$d;var t_=(0,un.A)(function(N){var $=Jf(N),ge=(0,Gr.A)(N,zo);return $===Jf(ge)?$=void 0:ge.pop(),ge.length&&ge[0]===N[0]?tu(ge,fa($)):[]});const Zu=t_;var BD=(0,un.A)(function(N){var $=Jf(N),ge=(0,Gr.A)(N,zo);return($="function"==typeof $?$:void 0)&&ge.pop(),ge.length&&ge[0]===N[0]?tu(ge,void 0,$):[]});const ch=BD,Hg=function ld(N,$){return function(ge,nt){return function bf(N,$,ge,nt){return Ah(N,function(Lt,bn,ui){$(nt,ge(Lt),bn,ui)}),nt}(ge,N,$(nt),{})}};var fm=Object.prototype.toString,Kr=Hg(function(N,$,ge){null!=$&&"function"!=typeof $.toString&&($=fm.call($)),N[$]=ge},(0,Fp.A)(Ap.A));const VD=Kr;var zg=Object.prototype,jD=zg.hasOwnProperty,Dl=zg.toString,tl=Hg(function(N,$,ge){null!=$&&"function"!=typeof $.toString&&($=Dl.call($)),jD.call(N,$)?N[$].push(ge):N[$]=[ge]},fa);const R1=tl,Pp=function L1(N,$){return $.length<2?N:(0,mr.A)(N,In($,0,-1))},uh=function mp(N,$,ge){$=(0,Ho.A)($,N);var nt=null==(N=Pp(N,$))?N:N[(0,Zs.A)(Jf($))];return null==nt?void 0:(0,Gi.A)(nt,N,ge)},Gm=(0,un.A)(uh);var AM=(0,un.A)(function(N,$,ge){var nt=-1,Lt="function"==typeof $,bn=(0,dt.A)(N)?Array(N.length):[];return Vm(N,function(ui){bn[++nt]=Lt?(0,Gi.A)($,ui,ge):uh(ui,$,ge)}),bn});const Bl=AM;var Pa=Mu.A&&Mu.A.isArrayBuffer;const UE=Pa?(0,_d.A)(Pa):function jE(N){return(0,Ki.A)(N)&&"[object ArrayBuffer]"==(0,Ii.A)(N)},xc=function yu(N){return!0===N||!1===N||(0,Ki.A)(N)&&"[object Boolean]"==(0,Ii.A)(N)};var gp=Mu.A&&Mu.A.isDate;const WE=gp?(0,_d.A)(gp):function hc(N){return(0,Ki.A)(N)&&"[object Date]"==(0,Ii.A)(N)},P1=function Hd(N){return(0,Ki.A)(N)&&1===N.nodeType&&!nn(N)};var HE=Object.prototype.hasOwnProperty;const zE=function Bf(N){if(null==N)return!0;if((0,dt.A)(N)&&((0,ci.A)(N)||"string"==typeof N||"function"==typeof N.splice||(0,Zd.A)(N)||(0,bd.A)(N)||(0,mi.A)(N)))return!N.length;var $=Uu(N);if("[object Map]"==$||"[object Set]"==$)return!N.size;if((0,ut.A)(N))return!St(N).length;for(var ge in N)if(HE.call(N,ge))return!1;return!0},Od=function OM(N,$){return Lf(N,$)},$D=function GE(N,$,ge){var nt=(ge="function"==typeof ge?ge:void 0)?ge(N,$):void 0;return void 0===nt?Lf(N,$,void 0,ge):!!nt};var FM=_c.A.isFinite;const qx=function NM(N){return"number"==typeof N&&FM(N)},Fd=function Bp(N){return"number"==typeof N&&N==(0,oe.A)(N)},KE=function Qx(N,$){return N===$||S0(N,$,Bm($))},$c=function pm(N,$,ge){return ge="function"==typeof ge?ge:void 0,S0(N,$,Bm($),ge)},Kg=function WD(N){return"number"==typeof N||(0,Ki.A)(N)&&"[object Number]"==(0,Ii.A)(N)},Xx=function B1(N){return Kg(N)&&N!=+N};var V1=S(5066),RM=S(9748),j1=S(5554);const U1=RM.A?Um.A:j1.A,$a=function ib(N){if(U1(N))throw new Error("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return(0,V1.A)(N)},Qg=function qg(N){return null==N},Yg=function kh(N){return null===N};var rb=Mu.A&&Mu.A.isRegExp;const Df=rb?(0,_d.A)(rb):function fy(N){return(0,Ki.A)(N)&&"[object RegExp]"==(0,Ii.A)(N)};var HD=9007199254740991;const o_=function Jx(N){return Fd(N)&&N>=-HD&&N<=HD},kM=function LM(N){return void 0===N},tS=function eS(N){return(0,Ki.A)(N)&&"[object WeakMap]"==Uu(N)},hy=function py(N){return(0,Ki.A)(N)&&"[object WeakSet]"==(0,Ii.A)(N)},my=function Vl(N){return fa("function"==typeof N?N:Ja(N,1))};var Bh=Array.prototype.join;const ip=function Oa(N,$){return null==N?"":Bh.call(N,$)};var Fu=qd(function(N,$,ge){return N+(ge?"-":"")+$.toLowerCase()});const dh=Fu;var gy=Tg(function(N,$,ge){(0,ct.A)(N,ge,$)});const hm=gy;var nS=S(6440);var iS=Math.max,ob=Math.min;const KD=function $1(N,$,ge){var nt=null==N?0:N.length;if(!nt)return-1;var Lt=nt;return void 0!==ge&&(Lt=(Lt=(0,oe.A)(ge))<0?iS(nt+Lt,0):ob(Lt,nt-1)),$==$?function PM(N,$,ge){for(var nt=ge+1;nt--;)if(N[nt]===$)return nt;return nt}(N,$,Lt):(0,Hm.A)(N,nS.A,Lt,!0)};var mm=qd(function(N,$,ge){return N+(ge?" ":"")+$.toLowerCase()});const af=mm,qD=la("toLowerCase"),sb=function W1(N,$){return N<$},H1=Vg(sb);var lb=Vg(function(N,$){return N<=$});const QD=lb,z1=function BM(N,$){var ge={};return $=fa($),Ah(N,function(nt,Lt,bn){(0,ct.A)(ge,$(nt,Lt,bn),nt)}),ge},Xg=function cb(N,$){var ge={};return $=fa($),Ah(N,function(nt,Lt,bn){(0,ct.A)(ge,Lt,$(nt,Lt,bn))}),ge},K1=function G1(N){return Es(Ja(N,1))},q1=function YD(N,$){return ux(N,Ja($,1))},Vp=function QE(N,$,ge){for(var nt=-1,Lt=N.length;++nt<Lt;){var bn=N[nt],ui=$(bn);if(null!=ui&&(void 0===Hi?ui==ui&&!(0,i.A)(ui):ge(ui,Hi)))var Hi=ui,yr=bn}return yr},ZD=function XD(N){return N&&N.length?Vp(N,Ap.A,Bg):void 0},JD=function s_(N,$){return N&&N.length?Vp(N,fa($),Bg):void 0},_y=function YE(N,$){for(var ge,nt=-1,Lt=N.length;++nt<Lt;){var bn=$(N[nt]);void 0!==bn&&(ge=void 0===ge?bn:ge+bn)}return ge},yy=function ew(N,$){var ge=null==N?0:N.length;return ge?_y(N,$)/ge:NaN},Km=function Q1(N){return yy(N,Ap.A)},tw=function Zg(N,$){return yy(N,fa($))};var ub=S(4569),nw=Ae(function(N,$,ge){im(N,$,ge)});const Y1=nw;var qm=(0,un.A)(function(N,$){return function(ge){return uh(ge,N,$)}});const db=qm;var XE=(0,un.A)(function(N,$){return function(ge){return uh(N,ge,$)}});const ZE=XE,Qm=function oS(N){return N&&N.length?Vp(N,Ap.A,sb):void 0},a_=function sS(N,$){return N&&N.length?Vp(N,fa($),sb):void 0},fh=function js(N,$,ge){var nt=Ht($),Lt=ay($,nt),bn=!((0,ns.A)(ge)&&"chain"in ge&&!ge.chain),ui=(0,Um.A)(N);return(0,gs.A)(Lt,function(Hi){var yr=$[Hi];N[Hi]=yr,ui&&(N.prototype[Hi]=function(){var fs=this.__chain__;if(bn||fs){var co=N(this.__wrapped__);return(co.__actions__=(0,tt.A)(this.__actions__)).push({func:yr,args:arguments,thisArg:N}),co.__chain__=fs,co}return yr.apply(N,as([this.value()],arguments))})}),N};var Vh=Ee(function(N,$){return N*$},1);const Jg=Vh,l_=function by(N){if("function"!=typeof N)throw new TypeError("Expected a function");return function(){var $=arguments;switch($.length){case 0:return!N.call(this);case 1:return!N.call(this,$[0]);case 2:return!N.call(this,$[0],$[1]);case 3:return!N.call(this,$[0],$[1],$[2])}return!N.apply(this,$)}};var c_=uo.A?uo.A.iterator:void 0;const hb=function Cy(N){if(!N)return[];if((0,dt.A)(N))return Wg(N)?Sl(N):(0,tt.A)(N);if(c_&&N[c_])return function X1(N){for(var $,ge=[];!($=N.next()).done;)ge.push($.value);return ge}(N[c_]());var $=Uu(N);return("[object Map]"==$?z_:"[object Set]"==$?Dc:Al)(N)},mb=function Dy(){void 0===this.__values__&&(this.__values__=hb(this.value()));var N=this.__index__>=this.__values__.length;return{done:N,value:N?void 0:this.__values__[this.__index__++]}};var ph=S(3565);const ev=function JE(N,$){var ge=N.length;if(ge)return(0,cp.A)($+=$<0?ge:0,ge)?N[$]:void 0},wy=function jM(N,$){return N&&N.length?ev(N,(0,oe.A)($)):void 0},xy=function eT(N){return N=(0,oe.A)(N),(0,un.A)(function($){return ev($,N)})},Ym=function bo(N,$){return $=(0,Ho.A)($,N),null==(N=Pp(N,$))||delete N[(0,Zs.A)(Jf($))]},iw=function mc(N){return nn(N)?void 0:N};var UM=qn(function(N,$){var ge={};if(null==N)return ge;var nt=!1;$=(0,Gr.A)($,function(bn){return bn=(0,Ho.A)(bn,N),nt||(nt=bn.length>1),bn}),an(N,Ce(N),ge),nt&&(ge=Ja(ge,7,iw));for(var Lt=$.length;Lt--;)Ym(ge,$[Lt]);return ge});const gb=UM;var Z1=S(5473);const jh=function Tl(N,$,ge){for(var nt=-1,Lt=$.length,bn={};++nt<Lt;){var ui=$[nt],Hi=(0,mr.A)(N,ui);ge(Hi,ui)&&(0,Z1.A)(bn,(0,Ho.A)(ui,N),Hi)}return bn},rw=function lS(N,$){if(null==N)return{};var ge=(0,Gr.A)(Ce(N),function(nt){return[nt]});return $=fa($),jh(N,ge,function(nt,Lt){return $(nt,Lt[0])})},vb=function Qs(N,$){return rw(N,l_(fa($)))},qo=function nT(N){return ol(2,N)},Ey=function iT(N,$){if(N!==$){var ge=void 0!==N,nt=null===N,Lt=N==N,bn=(0,i.A)(N),ui=void 0!==$,Hi=null===$,yr=$==$,fs=(0,i.A)($);if(!Hi&&!fs&&!bn&&N>$||bn&&ui&&yr&&!Hi&&!fs||nt&&ui&&yr||!ge&&yr||!Lt)return 1;if(!nt&&!bn&&!fs&&N<$||fs&&ge&&Lt&&!nt&&!bn||Hi&&ge&&Lt||!ui&&Lt||!yr)return-1}return 0},Uh=function vp(N,$,ge){$=$.length?(0,Gr.A)($,function(bn){return(0,ci.A)(bn)?function(ui){return(0,mr.A)(ui,1===bn.length?bn[0]:bn)}:bn}):[Ap.A];var nt=-1;return $=(0,Gr.A)($,(0,_d.A)(fa)),function Xm(N,$){var ge=N.length;for(N.sort($);ge--;)N[ge]=N[ge].value;return N}(zv(N,function(bn,ui,Hi){return{criteria:(0,Gr.A)($,function(fs){return fs(bn)}),index:++nt,value:bn}}),function(bn,ui){return function ow(N,$,ge){for(var nt=-1,Lt=N.criteria,bn=$.criteria,ui=Lt.length,Hi=ge.length;++nt<ui;){var yr=Ey(Lt[nt],bn[nt]);if(yr)return nt>=Hi?yr:yr*("desc"==ge[nt]?-1:1)}return N.index-$.index}(bn,ui,ge)})},eC=function J1(N,$,ge,nt){return null==N?[]:((0,ci.A)($)||($=null==$?[]:[$]),(0,ci.A)(ge=nt?void 0:ge)||(ge=null==ge?[]:[ge]),Uh(N,$,ge))},sw=function uS(N){return qn(function($){return $=(0,Gr.A)($,(0,_d.A)(fa)),(0,un.A)(function(ge){var nt=this;return N($,function(Lt){return(0,Gi.A)(Lt,nt,ge)})})})},Zm=sw(Gr.A);var fS=Math.min,tC=(0,un.A)(function(N,$){var ge=($=1==$.length&&(0,ci.A)($[0])?(0,Gr.A)($[0],(0,_d.A)(fa)):(0,Gr.A)(ri($,1),(0,_d.A)(fa))).length;return(0,un.A)(function(nt){for(var Lt=-1,bn=fS(nt.length,ge);++Lt<bn;)nt[Lt]=$[Lt].call(this,nt[Lt]);return(0,Gi.A)(N,this,nt)})});const tv=tC,wf=sw(_1),My=sw(Pm);var iC=Math.floor;const u_=function Iy(N,$){var ge="";if(!N||$<1||$>9007199254740991)return ge;do{$%2&&(ge+=N),($=iC($/2))&&(N+=N)}while($);return ge},eg=M0("length");var Ay="\\ud800-\\udfff",rC="["+Ay+"]",yb="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",lw="\\ud83c[\\udffb-\\udfff]",Cb="[^"+Ay+"]",oC="(?:\\ud83c[\\udde6-\\uddff]){2}",ng="[\\ud800-\\udbff][\\udc00-\\udfff]",mS="(?:"+yb+"|"+lw+")?",rv="[\\ufe0e\\ufe0f]?",$M=rv+mS+"(?:\\u200d(?:"+[Cb,oC,ng].join("|")+")"+rv+mS+")*",Db="(?:"+[Cb+yb+"?",yb,oC,ng,rC].join("|")+")",sC=RegExp(lw+"(?="+lw+")|"+Db+$M,"g");const jp=function aC(N){return Un(N)?function gS(N){for(var $=sC.lastIndex=0;sC.test(N);)++$;return $}(N):eg(N)};var Fy=Math.ceil;const Ac=function wb(N,$){var ge=($=void 0===$?" ":(0,ie.A)($)).length;if(ge<2)return ge?u_($,N):$;var nt=u_($,Fy(N/jp($)));return Un($)?jn(Sl(nt),0,N).join(""):nt.slice(0,N)};var Up=Math.ceil,Ny=Math.floor;const oT=function Oc(N,$,ge){N=(0,ko.A)(N);var nt=($=(0,oe.A)($))?jp(N):0;if(!$||nt>=$)return N;var Lt=($-nt)/2;return Ac(Ny(Lt),ge)+N+Ac(Up(Lt),ge)},uw=function MA(N,$,ge){N=(0,ko.A)(N);var nt=($=(0,oe.A)($))?jp(N):0;return $&&nt<$?N+Ac($-nt,ge):N},dw=function sT(N,$,ge){N=(0,ko.A)(N);var nt=($=(0,oe.A)($))?jp(N):0;return $&&nt<$?Ac($-nt,ge)+N:N};var IA=/^\s+/,aT=_c.A.parseInt;const lC=function WM(N,$,ge){return ge||null==$?$=0:$&&($=+$),aT((0,ko.A)(N).replace(IA,""),$||0)};var cC=S(9532),xb=(0,un.A)(function(N,$){var ge=(0,Ao.A)($,(0,Va.A)(xb));return(0,je.A)(N,64,void 0,$,ge)});xb.placeholder={};const f_=xb;var vS=Tg(function(N,$,ge){N[ge?0:1].push($)},function(){return[[],[]]});const p_=vS;var _S=qn(function(N,$){return null==N?{}:function fw(N,$){return jh(N,$,function(ge,nt){return iD(N,nt)})}(N,$)});const dC=_S;var Ry=S(6180),yS=S(6740);const Ly=function h_(N){for(var $,ge=this;ge instanceof Ry.A;){var nt=(0,yS.A)(ge);nt.__index__=0,nt.__values__=void 0,$?Lt.__wrapped__=nt:$=nt;var Lt=nt;ge=ge.__wrapped__}return Lt.__wrapped__=N,$},ov=function lT(N){return function($){return null==N?void 0:(0,mr.A)(N,$)}},hw=function pw(N,$,ge,nt){for(var Lt=ge-1,bn=N.length;++Lt<bn;)if(nt(N[Lt],$))return Lt;return-1};var cT=Array.prototype.splice;const $p=function mw(N,$,ge,nt){var Lt=nt?hw:tp.A,bn=-1,ui=$.length,Hi=N;for(N===$&&($=(0,tt.A)($)),ge&&(Hi=(0,Gr.A)(N,(0,_d.A)(ge)));++bn<ui;)for(var yr=0,fs=$[bn],co=ge?ge(fs):fs;(yr=Lt(Hi,co,yr,nt))>-1;)Hi!==N&&cT.call(Hi,yr,1),cT.call(N,yr,1);return N},fC=function ig(N,$){return N&&N.length&&$&&$.length?$p(N,$):N},vm=(0,un.A)(fC),sv=function bS(N,$,ge){return N&&N.length&&$&&$.length?$p(N,$,fa(ge)):N},ky=function Fs(N,$,ge){return N&&N.length&&$&&$.length?$p(N,$,void 0,ge):N};var rg=Array.prototype.splice;const dT=function CS(N,$){for(var ge=N?$.length:0,nt=ge-1;ge--;){var Lt=$[ge];if(ge==nt||Lt!==bn){var bn=Lt;(0,cp.A)(Lt)?rg.call(N,Lt,1):Ym(N,Lt)}}return N};var HM=qn(function(N,$){var ge=null==N?0:N.length,nt=Ur(N,$);return dT(N,(0,Gr.A)($,function(Lt){return(0,cp.A)(Lt,ge)?+Lt:Lt}).sort(Ey)),nt});const hC=HM;var g_=Math.floor,Eb=Math.random;const $h=function Py(N,$){return N+g_(Eb()*($-N+1))};var DS=parseFloat,Tb=Math.min,gw=Math.random;const xS=function wS(N,$,ge){if(ge&&"boolean"!=typeof ge&&(0,vn.A)(N,$,ge)&&($=ge=void 0),void 0===ge&&("boolean"==typeof $?(ge=$,$=void 0):"boolean"==typeof N&&(ge=N,N=void 0)),void 0===N&&void 0===$?(N=0,$=1):(N=(0,pp.A)(N),void 0===$?($=N,N=0):$=(0,pp.A)($)),N>$){var nt=N;N=$,$=nt}if(ge||N%1||$%1){var Lt=gw();return Tb(N+Lt*($-N+DS("1e-"+((Lt+"").length-1))),$)}return $h(N,$)};var fT=Math.ceil,v_=Math.max;const _w=function vw(N){return function($,ge,nt){return nt&&"number"!=typeof nt&&(0,vn.A)($,ge,nt)&&(ge=nt=void 0),$=(0,pp.A)($),void 0===ge?(ge=$,$=0):ge=(0,pp.A)(ge),function SS(N,$,ge,nt){for(var Lt=-1,bn=v_(fT(($-N)/(ge||1)),0),ui=Array(bn);bn--;)ui[nt?bn:++Lt]=N,N+=ge;return ui}($,ge,nt=void 0===nt?$<ge?1:-1:(0,pp.A)(nt),N)}},Mb=_w(),mT=_w(!0);var yw=qn(function(N,$){return(0,je.A)(N,256,void 0,void 0,void 0,$)});const TS=yw,Ab=function gT(N,$,ge,nt,Lt){return Lt(N,function(bn,ui,Hi){ge=nt?(nt=!1,bn):$(ge,bn,ui,Hi)}),ge},MS=function Ob(N,$,ge){var nt=(0,ci.A)(N)?ec:Ab,Lt=arguments.length<3;return nt(N,fa($),ge,Lt,Vm)},vT=function By(N,$,ge,nt){var Lt=null==N?0:N.length;for(nt&&Lt&&(ge=N[--Lt]);Lt--;)ge=$(ge,N[Lt],Lt,N);return ge},og=function __(N,$,ge){var nt=(0,ci.A)(N)?vT:Ab,Lt=arguments.length<3;return nt(N,fa($),ge,Lt,lh)},bw=function mC(N,$){return((0,ci.A)(N)?gi:C1)(N,l_(fa($)))},y_=function Cw(N,$){var ge=[];if(!N||!N.length)return ge;var nt=-1,Lt=[],bn=N.length;for($=fa($);++nt<bn;){var ui=N[nt];$(ui,nt,N)&&(ge.push(ui),Lt.push(nt))}return dT(N,Lt),ge},Vy=function _T(N,$,ge){return $=(ge?(0,vn.A)(N,$,ge):void 0===$)?1:(0,oe.A)($),u_((0,ko.A)(N),$)},bT=function yT(){var N=arguments,$=(0,ko.A)(N[0]);return N.length<3?$:$.replace(N[1],N[2])},ww=function Dw(N,$){if("function"!=typeof N)throw new TypeError("Expected a function");return $=void 0===$?$:(0,oe.A)($),(0,un.A)(N,$)},gC=function Uy(N,$,ge){var nt=-1,Lt=($=(0,Ho.A)($,N)).length;for(Lt||(Lt=1,N=void 0);++nt<Lt;){var bn=N?.[(0,Zs.A)($[nt])];void 0===bn&&(nt=Lt,bn=ge),N=(0,Um.A)(bn)?bn.call(N):bn}return N};var Fb=Array.prototype.reverse;const Nb=function IS(N){return null==N?N:Fb.call(N)},AS=Ra("round"),Wh=function _m(N){var $=N.length;return $?N[$h(0,$-1)]:void 0},zM=function Wp(N){return Wh(Al(N))},av=function sg(N){return((0,ci.A)(N)?Wh:zM)(N)},Ys=function OS(N,$){var ge=-1,nt=N.length,Lt=nt-1;for($=void 0===$?nt:$;++ge<$;){var bn=$h(ge,Lt),ui=N[bn];N[bn]=N[ge],N[ge]=ui}return N.length=$,N},_C=function lv(N,$){return Ys((0,tt.A)(N),Pu($,0,N.length))},$f=function FS(N,$){var ge=Al(N);return Ys(ge,Pu($,0,ge.length))},$y=function ag(N,$,ge){return $=(ge?(0,vn.A)(N,$,ge):void 0===$)?1:(0,oe.A)($),((0,ci.A)(N)?_C:$f)(N,$)};var Rb=S(953);const b_=function Sw(N,$,ge,nt){return nt="function"==typeof nt?nt:void 0,null==N?N:(0,Z1.A)(N,$,ge,nt)},Wf=function bu(N){return Ys((0,tt.A)(N))},yC=function zi(N){return Ys(Al(N))},Cu=function nu(N){return((0,ci.A)(N)?Wf:yC)(N)},lg=function cu(N){if(null==N)return 0;if((0,dt.A)(N))return Wg(N)?jp(N):N.length;var $=Uu(N);return"[object Map]"==$||"[object Set]"==$?N.size:St(N).length},Ew=function Hh(N,$,ge){var nt=null==N?0:N.length;return nt?(ge&&"number"!=typeof ge&&(0,vn.A)(N,$,ge)?($=0,ge=nt):($=null==$?0:(0,oe.A)($),ge=void 0===ge?nt:(0,oe.A)(ge)),In(N,$,ge)):[]};var Wc=qd(function(N,$,ge){return N+(ge?"_":"")+$.toLowerCase()});const cd=Wc,cg=function Hy(N,$){var ge;return Vm(N,function(nt,Lt,bn){return!(ge=$(nt,Lt,bn))}),!!ge},Hf=function hh(N,$,ge){var nt=(0,ci.A)(N)?Pm:cg;return ge&&(0,vn.A)(N,$,ge)&&($=void 0),nt(N,fa($))};var Nd=(0,un.A)(function(N,$){if(null==N)return[];var ge=$.length;return ge>1&&(0,vn.A)(N,$[0],$[1])?$=[]:ge>2&&(0,vn.A)($[0],$[1],$[2])&&($=[$[0]]),Uh(N,ri($,1),[])});const C_=Nd;var zy=Math.floor,xf=Math.min;const Ju=function Tw(N,$,ge,nt){var Lt=0,bn=null==N?0:N.length;if(0===bn)return 0;for(var ui=($=ge($))!=$,Hi=null===$,yr=(0,i.A)($),fs=void 0===$;Lt<bn;){var co=zy((Lt+bn)/2),Do=ge(N[co]),Ts=void 0!==Do,os=null===Do,gl=Do==Do,Xs=(0,i.A)(Do);if(ui)var il=nt||gl;else il=fs?gl&&(nt||Ts):Hi?gl&&Ts&&(nt||!os):yr?gl&&Ts&&!os&&(nt||!Xs):!os&&!Xs&&(nt?Do<=$:Do<$);il?Lt=co+1:bn=co}return xf(bn,4294967294)},Ky=function Gy(N,$,ge){var nt=0,Lt=null==N?nt:N.length;if("number"==typeof $&&$==$&&Lt<=2147483647){for(;nt<Lt;){var bn=nt+Lt>>>1,ui=N[bn];null!==ui&&!(0,i.A)(ui)&&(ge?ui<=$:ui<$)?nt=bn+1:Lt=bn}return Lt}return Ju(N,$,Ap.A,ge)},Jl=function Gu(N,$){return Ky(N,$)},qy=function ug(N,$,ge){return Ju(N,$,fa(ge))},cv=function zh(N,$){var ge=null==N?0:N.length;if(ge){var nt=Ky(N,$);if(nt<ge&&(0,ef.A)(N[nt],$))return nt}return-1},w_=function Mw(N,$){return Ky(N,$,!0)},uv=function dg(N,$,ge){return Ju(N,$,fa(ge),!0)},Qy=function fg(N,$){if(null!=N&&N.length){var nt=Ky(N,$,!0)-1;if((0,ef.A)(N[nt],$))return nt}return-1},pg=function bC(N,$){for(var ge=-1,nt=N.length,Lt=0,bn=[];++ge<nt;){var ui=N[ge],Hi=$?$(ui):ui;if(!ge||!(0,ef.A)(Hi,yr)){var yr=Hi;bn[Lt++]=0===ui?0:ui}}return bn},CC=function Gh(N){return N&&N.length?pg(N):[]},ud=function NS(N,$){return N&&N.length?pg(N,fa($)):[]},Yy=function hg(N,$,ge){return ge&&"number"!=typeof ge&&(0,vn.A)(N,$,ge)&&($=ge=void 0),(ge=void 0===ge?4294967295:ge>>>0)?(N=(0,ko.A)(N))&&("string"==typeof $||null!=$&&!Df($))&&!($=(0,ie.A)($))&&Un(N)?jn(Sl(N),0,ge):N.split($,ge):[]};var cf=Math.max;const Lb=function uu(N,$){if("function"!=typeof N)throw new TypeError("Expected a function");return $=null==$?0:cf((0,oe.A)($),0),(0,un.A)(function(ge){var nt=ge[$],Lt=jn(ge,0,$);return nt&&as(Lt,nt),(0,Gi.A)(N,this,Lt)})};var iu=qd(function(N,$,ge){return N+(ge?" ":"")+Sc($)});const dv=iu,S_=function Cm(N,$,ge){return N=(0,ko.A)(N),ge=null==ge?0:Pu((0,oe.A)(ge),0,N.length),$=(0,ie.A)($),N.slice(ge,ge+$.length)==$},Zy=function Xy(){return{}},fv=function dd(){return""},kb=function GM(){return!0};var pv=Ee(function(N,$){return N-$},0);const DC=pv,Hc=function hv(N){return N&&N.length?_y(N,Ap.A):0},mv=function zf(N,$){return N&&N.length?_y(N,fa($)):0},wC=function E_(N){var $=null==N?0:N.length;return $?In(N,1,$):[]},SC=function xC(N,$,ge){return N&&N.length?($=ge||void 0===$?1:(0,oe.A)($),In(N,0,$<0?0:$)):[]},Dd=function _p(N,$,ge){var nt=null==N?0:N.length;return nt?($=ge||void 0===$?1:(0,oe.A)($),In(N,($=nt-$)<0?0:$,nt)):[]},Iw=function LS(N,$){return N&&N.length?J_(N,fa($),!1,!0):[]},EC=function KM(N,$){return N&&N.length?J_(N,fa($)):[]},kS=function Aw(N,$){return $(N),N};var Jy=Object.prototype,Ow=Jy.hasOwnProperty;const e0=function Pb(N,$,ge,nt){return void 0===N||(0,ef.A)(N,Jy[ge])&&!Ow.call(nt,ge)?$:N};var Bb={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};const Fw=function T_(N){return"\\"+Bb[N]},M_=/<%=([\s\S]+?)%>/g,MC={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:M_,variable:"",imports:{_:{escape:yf}}};var AC=/\b__p \+= '';/g,VS=/\b(__p \+=) '' \+/g,OC=/(__e\(.*?\)|\b__t\)) \+\n'';/g,jS=/[()=,{}\[\]\/\s]/,qM=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,mh=/($^)/,FC=/['\n\r\u2028\u2029\\]/g,r0=Object.prototype.hasOwnProperty;const NC=function DT(N,$,ge){var nt=MC.imports._.templateSettings||MC;ge&&(0,vn.A)(N,$,ge)&&($=void 0),N=(0,ko.A)(N),$=Yn({},$,nt,e0);var Hi,yr,Lt=Yn({},$.imports,nt.imports,e0),bn=Ht(Lt),ui=sf(Lt,bn),fs=0,co=$.interpolate||mh,Do="__p += '",Ts=RegExp(($.escape||mh).source+"|"+co.source+"|"+(co===M_?qM:mh).source+"|"+($.evaluate||mh).source+"|$","g"),os=r0.call($,"sourceURL")?"//# sourceURL="+($.sourceURL+"").replace(/\s/g," ")+"\n":"";N.replace(Ts,function(il,Da,fd,zd,Sm,Ef){return fd||(fd=zd),Do+=N.slice(fs,Ef).replace(FC,Fw),Da&&(Hi=!0,Do+="' +\n__e("+Da+") +\n'"),Sm&&(yr=!0,Do+="';\n"+Sm+";\n__p += '"),fd&&(Do+="' +\n((__t = ("+fd+")) == null ? '' : __t) +\n'"),fs=Ef+il.length,il}),Do+="';\n";var gl=r0.call($,"variable")&&$.variable;if(gl){if(jS.test(gl))throw new Error("Invalid `variable` option passed into `_.template`")}else Do="with (obj) {\n"+Do+"\n}\n";Do=(yr?Do.replace(AC,""):Do).replace(VS,"$1").replace(OC,"$1;"),Do="function("+(gl||"obj")+") {\n"+(gl?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(Hi?", __e = _.escape":"")+(yr?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+Do+"return __p\n}";var Xs=Eo(function(){return Function(bn,os+"return "+Do).apply(void 0,ui)});if(Xs.source=Do,qr(Xs))throw Xs;return Xs},jb=function US(N,$,ge){var nt=!0,Lt=!0;if("function"!=typeof N)throw new TypeError("Expected a function");return(0,ns.A)(ge)&&(nt="leading"in ge?!!ge.leading:nt,Lt="trailing"in ge?!!ge.trailing:Lt),Np(N,$,{leading:nt,maxWait:$,trailing:Lt})},s0=function o0(N,$){return $(N)};var Ub=S(9659),Nw=4294967295,RC=Math.min;const $S=function Rw(N,$){if((N=(0,oe.A)(N))<1||N>9007199254740991)return[];var ge=Nw,nt=RC(N,Nw);$=kf($),N-=Nw;for(var Lt=(0,Ub.A)(nt,$);++ge<N;)$(ge);return Lt},a0=function I_(){return this};var pa=S(7071);const A_=function gv(N,$){var ge=N;return ge instanceof pa.A&&(ge=ge.value()),ec($,function(nt,Lt){return Lt.func.apply(Lt.thisArg,as([nt],Lt.args))},ge)},l0=function wT(){return A_(this.__wrapped__,this.__actions__)},Lw=function wm(N){return(0,ko.A)(N).toLowerCase()};var O_=S(9293);const kw=function Wb(N){return(0,ci.A)(N)?(0,Gr.A)(N,Zs.A):(0,i.A)(N)?[N]:(0,tt.A)((0,O_.A)((0,ko.A)(N)))};var WS=9007199254740991;const Hb=function c0(N){return N?Pu((0,oe.A)(N),-WS,WS):0===N?N:0},zb=function xT(N){return(0,ko.A)(N).toUpperCase()},c=function Pw(N,$,ge){var nt=(0,ci.A)(N),Lt=nt||(0,Zd.A)(N)||(0,bd.A)(N);if($=fa($),null==ge){var bn=N&&N.constructor;ge=Lt?nt?new bn:[]:(0,ns.A)(N)&&(0,Um.A)(bn)?(0,zl.A)(hi(N)):{}}return(Lt?gs.A:Ah)(N,function(ui,Hi,yr){return $(ge,ui,Hi,yr)}),ge};var g=S(673);const u=function a(N,$){for(var ge=N.length;ge--&&(0,tp.A)($,N[ge],0)>-1;);return ge},I=function x(N,$){for(var ge=-1,nt=N.length;++ge<nt&&(0,tp.A)($,N[ge],0)>-1;);return ge},ye=function K(N,$,ge){if((N=(0,ko.A)(N))&&(ge||void 0===$))return(0,g.A)(N);if(!N||!($=(0,ie.A)($)))return N;var nt=Sl(N),Lt=Sl($),bn=I(nt,Lt),ui=u(nt,Lt)+1;return jn(nt,bn,ui).join("")};var Ye=S(9939);const ht=function $e(N,$,ge){if((N=(0,ko.A)(N))&&(ge||void 0===$))return N.slice(0,(0,Ye.A)(N)+1);if(!N||!($=(0,ie.A)($)))return N;var nt=Sl(N),Lt=u(nt,Sl($))+1;return jn(nt,0,Lt).join("")};var Vt=/^\s+/;const yn=function zt(N,$,ge){if((N=(0,ko.A)(N))&&(ge||void 0===$))return N.replace(Vt,"");if(!N||!($=(0,ie.A)($)))return N;var nt=Sl(N),Lt=I(nt,Sl($));return jn(nt,Lt).join("")};var si=/\w*$/;const _o=function hr(N,$){var ge=30,nt="...";if((0,ns.A)($)){var Lt="separator"in $?$.separator:Lt;ge="length"in $?(0,oe.A)($.length):ge,nt="omission"in $?(0,ie.A)($.omission):nt}var bn=(N=(0,ko.A)(N)).length;if(Un(N)){var ui=Sl(N);bn=ui.length}if(ge>=bn)return N;var Hi=ge-jp(nt);if(Hi<1)return nt;var yr=ui?jn(ui,0,Hi).join(""):N.slice(0,Hi);if(void 0===Lt)return yr+nt;if(ui&&(Hi+=yr.length-Hi),Df(Lt)){if(N.slice(Hi).search(Lt)){var fs,co=yr;for(Lt.global||(Lt=RegExp(Lt.source,(0,ko.A)(si.exec(Lt))+"g")),Lt.lastIndex=0;fs=Lt.exec(co);)var Do=fs.index;yr=yr.slice(0,void 0===Do?Hi:Do)}}else if(N.indexOf((0,ie.A)(Lt),Hi)!=Hi){var Ts=yr.lastIndexOf(Lt);Ts>-1&&(yr=yr.slice(0,Ts))}return yr+nt},ao=function jr(N){return ve(N,1)},br=ca({"&":"&","<":"<",">":">",""":'"',"'":"'"});var yo=/&(?:amp|lt|gt|quot|#39);/g,ml=RegExp(yo.source);const oo=function Ca(N){return(N=(0,ko.A)(N))&&ml.test(N)?N.replace(yo,br):N};var Co=oi&&1/Dc(new oi([,-0]))[1]==1/0?function(N){return new oi(N)}:ph.A;const us=Co,Jr=function xo(N,$,ge){var nt=-1,Lt=Ag.A,bn=N.length,ui=!0,Hi=[],yr=Hi;if(ge)ui=!1,Lt=ah;else if(bn>=200){var fs=$?null:us(N);if(fs)return Dc(fs);ui=!1,Lt=ih,yr=new qa}else yr=$?[]:Hi;e:for(;++nt<bn;){var co=N[nt],Do=$?$(co):co;if(co=ge||0!==co?co:0,ui&&Do==Do){for(var Ts=yr.length;Ts--;)if(yr[Ts]===Do)continue e;$&&yr.push(Do),Hi.push(co)}else Lt(yr,Do,ge)||(yr!==Hi&&yr.push(Do),Hi.push(co))}return Hi};var No=(0,un.A)(function(N){return Jr(ri(N,1,_u,!0))});const Hr=No;var ys=(0,un.A)(function(N){var $=Jf(N);return _u($)&&($=void 0),Jr(ri(N,1,_u,!0),fa($))});const Ns=ys;var Ml=(0,un.A)(function(N){var $=Jf(N);return $="function"==typeof $?$:void 0,Jr(ri(N,1,_u,!0),void 0,$)});const Nu=Ml,ru=function Rd(N){return N&&N.length?Jr(N):[]},jl=function wd(N,$){return N&&N.length?Jr(N,fa($)):[]},Cr=function Os(N,$){return $="function"==typeof $?$:void 0,N&&N.length?Jr(N,void 0,$):[]};var So=0;const wi=function Po(N){var $=++So;return(0,ko.A)(N)+$},dn=function ha(N,$){return null==N||Ym(N,$)};var Ol=Math.max;const hs=function Fa(N){if(!N||!N.length)return[];var $=0;return N=gi(N,function(ge){if(_u(ge))return $=Ol(ge.length,$),!0}),(0,Ub.A)($,function(ge){return(0,Gr.A)(N,M0(ge))})},mg=function Ka(N,$){if(!N||!N.length)return[];var ge=hs(N);return null==$?ge:(0,Gr.A)(ge,function(nt){return(0,Gi.A)($,void 0,nt)})},Bw=function Du(N,$,ge,nt){return(0,Z1.A)(N,$,ge((0,mr.A)(N,$)),nt)},Gb=function F_(N,$,ge){return null==N?N:Bw(N,$,kf(ge))},N_=function LC(N,$,ge,nt){return nt="function"==typeof nt?nt:void 0,null==N?N:Bw(N,$,kf(ge),nt)};var ST=qd(function(N,$,ge){return N+(ge?" ":"")+$.toUpperCase()});const HS=ST,kC=function R_(N){return null==N?[]:sf(N,(0,Zn.A)(N))};var Kb=(0,un.A)(function(N,$){return _u(N)?om(N,$):[]});const uf=Kb,PC=function L_(N,$){return(0,cC.A)(kf($),N)};var AA=qn(function(N){var $=N.length,ge=$?N[0]:0,nt=this.__wrapped__,Lt=function(bn){return Ur(bn,N)};return!($>1||this.__actions__.length)&&nt instanceof pa.A&&(0,cp.A)(ge)?((nt=nt.slice(ge,+ge+($?1:0))).__actions__.push({func:s0,args:[Lt],thisArg:void 0}),new ee.A(nt,this.__chain__).thru(function(bn){return $&&!bn.length&&bn.push(void 0),bn})):this.thru(Lt)});const QM=AA,nl=function BC(){return Qh(this)},ET=function OA(){var N=this.__wrapped__;if(N instanceof pa.A){var $=N;return this.__actions__.length&&($=new pa.A(this)),($=$.reverse()).__actions__.push({func:s0,args:[Nb],thisArg:void 0}),new ee.A($,this.__chain__)}return this.thru(Nb)},zS=function FA(N,$,ge){var nt=N.length;if(nt<2)return nt?Jr(N[0]):[];for(var Lt=-1,bn=Array(nt);++Lt<nt;)for(var ui=N[Lt],Hi=-1;++Hi<nt;)Hi!=Lt&&(bn[Lt]=om(bn[Lt]||ui,N[Hi],$,ge));return Jr(ri(bn,1),$,ge)};var VC=(0,un.A)(function(N){return zS(gi(N,_u))});const YM=VC;var Vw=(0,un.A)(function(N){var $=Jf(N);return _u($)&&($=void 0),zS(gi(N,_u),fa($))});const jw=Vw;var TT=(0,un.A)(function(N){var $=Jf(N);return $="function"==typeof $?$:void 0,zS(gi(N,_u),void 0,$)});const jC=TT,vv=(0,un.A)(hs),Kh=function u0(N,$,ge){for(var nt=-1,Lt=N.length,bn=$.length,ui={};++nt<Lt;)ge(ui,N[nt],nt<bn?$[nt]:void 0);return ui},MT=function XM(N,$){return Kh(N||[],$||[],fn.A)},GS=function ZM(N,$){return Kh(N||[],$||[],Z1.A)};var d0=(0,un.A)(function(N){var $=N.length,ge=$>1?N[$-1]:void 0;return ge="function"==typeof ge?(N.pop(),ge):void 0,mg(N,ge)});const Ku=d0,Cs={chunk:gd,compact:gr,concat:vo,difference:yD,differenceBy:Dx,differenceWith:Bv,drop:bD,dropRight:Ng,dropRightWhile:ey,dropWhile:Sx,fill:TE,findIndex:lm,findLastIndex:MD,first:cm,flatten:At,flattenDeep:Kv,flattenDepth:FE,fromPairs:Yv,head:cm,indexOf:eu,initial:Xu,intersection:Wd,intersectionBy:Zu,intersectionWith:ch,join:ip,last:Jf,lastIndexOf:KD,nth:wy,pull:vm,pullAll:fC,pullAllBy:sv,pullAllWith:ky,pullAt:hC,remove:y_,reverse:Nb,slice:Ew,sortedIndex:Jl,sortedIndexBy:qy,sortedIndexOf:cv,sortedLastIndex:w_,sortedLastIndexBy:uv,sortedLastIndexOf:Qy,sortedUniq:CC,sortedUniqBy:ud,tail:wC,take:SC,takeRight:Dd,takeRightWhile:Iw,takeWhile:EC,union:Hr,unionBy:Ns,unionWith:Nu,uniq:ru,uniqBy:jl,uniqWith:Cr,unzip:hs,unzipWith:mg,without:uf,xor:YM,xorBy:jw,xorWith:jC,zip:vv,zipObject:MT,zipObjectDeep:GS,zipWith:Ku},Ul={countBy:Ig,each:jv,eachRight:Ou,every:Ax,filter:$0,find:Rx,findLast:G0,flatMap:Gv,flatMapDeep:Px,flatMapDepth:w1,forEach:jv,forEachRight:Ou,groupBy:LD,includes:dm,invokeMap:Bl,keyBy:hm,map:AD,orderBy:eC,partition:p_,reduce:MS,reduceRight:og,reject:bw,sample:av,sampleSize:$y,shuffle:Cu,size:lg,some:Hf,sortBy:C_},JM={now:u1},xd={after:le,ary:ve,before:ol,bind:_l,bindKey:Lo,curry:Nv,curryRight:Rv,debounce:Np,defer:bx,delay:Z_,flip:sy,memoize:ub.A,negate:l_,once:qo,overArgs:tv,partial:cC.A,partialRight:f_,rearg:TS,rest:ww,spread:Lb,throttle:jb,unary:ao,wrap:PC},ua={castArray:bl,clone:Ss,cloneDeep:Gl,cloneDeepWith:V,cloneWith:U,conformsTo:lD,eq:ef.A,gt:A1,gte:O1,isArguments:mi.A,isArray:ci.A,isArrayBuffer:UE,isArrayLike:dt.A,isArrayLikeObject:_u,isBoolean:xc,isBuffer:Zd.A,isDate:WE,isElement:P1,isEmpty:zE,isEqual:Od,isEqualWith:$D,isError:qr,isFinite:qx,isFunction:Um.A,isInteger:Fd,isLength:Mh.A,isMap:Iu,isMatch:KE,isMatchWith:$c,isNaN:Xx,isNative:$a,isNil:Qg,isNull:Yg,isNumber:Kg,isObject:ns.A,isObjectLike:Ki.A,isPlainObject:nn,isRegExp:Df,isSafeInteger:o_,isSet:Md,isString:Wg,isSymbol:i.A,isTypedArray:bd.A,isUndefined:kM,isWeakMap:tS,isWeakSet:hy,lt:H1,lte:QD,toArray:hb,toFinite:pp.A,toInteger:oe.A,toLength:y1,toNumber:cc.A,toPlainObject:gD,toSafeInteger:Hb,toString:ko.A},yp={add:q,ceil:ff,divide:Vv,floor:q0,max:ZD,maxBy:JD,mean:Km,meanBy:tw,min:Qm,minBy:a_,multiply:Jg,round:AS,subtract:DC,sum:Hc,sumBy:mv},UC={clamp:qs,inRange:Pf,random:xS},Wa={assign:fi,assignIn:gn,assignInWith:Yn,assignWith:Ai,at:Bi,create:A0,defaults:kv.A,defaultsDeep:_D,entries:Wm,entriesIn:Rp,extend:gn,extendWith:Yn,findKey:kg,findLastKey:ID,forIn:PE,forInRight:I1,forOwn:fp,forOwnRight:Ux,functions:RD,functionsIn:VE,get:Qi.A,has:ep,hasIn:iD,invert:VD,invertBy:R1,invoke:Gm,keys:Ht,keysIn:Zn.A,mapKeys:z1,mapValues:Xg,merge:Y1,mergeWith:R0,omit:gb,omitBy:vb,pick:dC,pickBy:rw,result:gC,set:Rb.A,setWith:b_,toPairs:Wm,toPairsIn:Rp,transform:c,unset:dn,update:Gb,updateWith:N_,values:Al,valuesIn:kC},Sf={at:QM,chain:Qh,commit:Nt,lodash:Yt.A,next:mb,plant:Ly,reverse:ET,tap:kS,thru:s0,toIterator:a0,toJSON:l0,value:l0,valueOf:l0,wrapperChain:nl},wl={camelCase:nd,capitalize:Qc,deburr:vc,endsWith:Rg,escape:yf,escapeRegExp:SE,kebabCase:dh,lowerCase:af,lowerFirst:qD,pad:oT,padEnd:uw,padStart:dw,parseInt:lC,repeat:Vy,replace:bT,snakeCase:cd,split:Yy,startCase:dv,startsWith:S_,template:NC,templateSettings:MC,toLower:Lw,toUpper:zb,trim:ye,trimEnd:ht,trimStart:yn,truncate:_o,unescape:oo,upperCase:HS,upperFirst:Sc,words:Ks},$l={attempt:Eo,bindAll:no,cond:aD,conforms:nf,constant:Fp.A,defaultTo:wE,flow:Y0,flowRight:M1,identity:Ap.A,iteratee:my,matches:K1,matchesProperty:q1,method:db,methodOf:ZE,mixin:fh,noop:ph.A,nthArg:xy,over:Zm,overEvery:wf,overSome:My,property:Pl,propertyOf:ov,range:Mb,rangeRight:mT,stubArray:or,stubFalse:j1.A,stubObject:Zy,stubString:fv,stubTrue:kb,times:$S,toPath:kw,uniqueId:wi};var eI=S(1383);var Gp=Math.max,p0=Math.min;var $C=Math.min;var N,Kp=S(7086),Uw=4294967295,vh=Array.prototype,$w=Object.prototype.hasOwnProperty,bp=uo.A?uo.A.iterator:void 0,Qb=Math.max,qS=Math.min,KC=function(N){return function($,ge,nt){if(null==nt){var Lt=(0,ns.A)(ge),bn=Lt&&Ht(ge),ui=bn&&bn.length&&ay(ge,bn);(ui?ui.length:Lt)||(nt=ge,ge=$,$=this)}return N($,ge,nt)}}(fh);Yt.A.after=xd.after,Yt.A.ary=xd.ary,Yt.A.assign=Wa.assign,Yt.A.assignIn=Wa.assignIn,Yt.A.assignInWith=Wa.assignInWith,Yt.A.assignWith=Wa.assignWith,Yt.A.at=Wa.at,Yt.A.before=xd.before,Yt.A.bind=xd.bind,Yt.A.bindAll=$l.bindAll,Yt.A.bindKey=xd.bindKey,Yt.A.castArray=ua.castArray,Yt.A.chain=Sf.chain,Yt.A.chunk=Cs.chunk,Yt.A.compact=Cs.compact,Yt.A.concat=Cs.concat,Yt.A.cond=$l.cond,Yt.A.conforms=$l.conforms,Yt.A.constant=$l.constant,Yt.A.countBy=Ul.countBy,Yt.A.create=Wa.create,Yt.A.curry=xd.curry,Yt.A.curryRight=xd.curryRight,Yt.A.debounce=xd.debounce,Yt.A.defaults=Wa.defaults,Yt.A.defaultsDeep=Wa.defaultsDeep,Yt.A.defer=xd.defer,Yt.A.delay=xd.delay,Yt.A.difference=Cs.difference,Yt.A.differenceBy=Cs.differenceBy,Yt.A.differenceWith=Cs.differenceWith,Yt.A.drop=Cs.drop,Yt.A.dropRight=Cs.dropRight,Yt.A.dropRightWhile=Cs.dropRightWhile,Yt.A.dropWhile=Cs.dropWhile,Yt.A.fill=Cs.fill,Yt.A.filter=Ul.filter,Yt.A.flatMap=Ul.flatMap,Yt.A.flatMapDeep=Ul.flatMapDeep,Yt.A.flatMapDepth=Ul.flatMapDepth,Yt.A.flatten=Cs.flatten,Yt.A.flattenDeep=Cs.flattenDeep,Yt.A.flattenDepth=Cs.flattenDepth,Yt.A.flip=xd.flip,Yt.A.flow=$l.flow,Yt.A.flowRight=$l.flowRight,Yt.A.fromPairs=Cs.fromPairs,Yt.A.functions=Wa.functions,Yt.A.functionsIn=Wa.functionsIn,Yt.A.groupBy=Ul.groupBy,Yt.A.initial=Cs.initial,Yt.A.intersection=Cs.intersection,Yt.A.intersectionBy=Cs.intersectionBy,Yt.A.intersectionWith=Cs.intersectionWith,Yt.A.invert=Wa.invert,Yt.A.invertBy=Wa.invertBy,Yt.A.invokeMap=Ul.invokeMap,Yt.A.iteratee=$l.iteratee,Yt.A.keyBy=Ul.keyBy,Yt.A.keys=Ht,Yt.A.keysIn=Wa.keysIn,Yt.A.map=Ul.map,Yt.A.mapKeys=Wa.mapKeys,Yt.A.mapValues=Wa.mapValues,Yt.A.matches=$l.matches,Yt.A.matchesProperty=$l.matchesProperty,Yt.A.memoize=xd.memoize,Yt.A.merge=Wa.merge,Yt.A.mergeWith=Wa.mergeWith,Yt.A.method=$l.method,Yt.A.methodOf=$l.methodOf,Yt.A.mixin=KC,Yt.A.negate=l_,Yt.A.nthArg=$l.nthArg,Yt.A.omit=Wa.omit,Yt.A.omitBy=Wa.omitBy,Yt.A.once=xd.once,Yt.A.orderBy=Ul.orderBy,Yt.A.over=$l.over,Yt.A.overArgs=xd.overArgs,Yt.A.overEvery=$l.overEvery,Yt.A.overSome=$l.overSome,Yt.A.partial=xd.partial,Yt.A.partialRight=xd.partialRight,Yt.A.partition=Ul.partition,Yt.A.pick=Wa.pick,Yt.A.pickBy=Wa.pickBy,Yt.A.property=$l.property,Yt.A.propertyOf=$l.propertyOf,Yt.A.pull=Cs.pull,Yt.A.pullAll=Cs.pullAll,Yt.A.pullAllBy=Cs.pullAllBy,Yt.A.pullAllWith=Cs.pullAllWith,Yt.A.pullAt=Cs.pullAt,Yt.A.range=$l.range,Yt.A.rangeRight=$l.rangeRight,Yt.A.rearg=xd.rearg,Yt.A.reject=Ul.reject,Yt.A.remove=Cs.remove,Yt.A.rest=xd.rest,Yt.A.reverse=Cs.reverse,Yt.A.sampleSize=Ul.sampleSize,Yt.A.set=Wa.set,Yt.A.setWith=Wa.setWith,Yt.A.shuffle=Ul.shuffle,Yt.A.slice=Cs.slice,Yt.A.sortBy=Ul.sortBy,Yt.A.sortedUniq=Cs.sortedUniq,Yt.A.sortedUniqBy=Cs.sortedUniqBy,Yt.A.split=wl.split,Yt.A.spread=xd.spread,Yt.A.tail=Cs.tail,Yt.A.take=Cs.take,Yt.A.takeRight=Cs.takeRight,Yt.A.takeRightWhile=Cs.takeRightWhile,Yt.A.takeWhile=Cs.takeWhile,Yt.A.tap=Sf.tap,Yt.A.throttle=xd.throttle,Yt.A.thru=s0,Yt.A.toArray=ua.toArray,Yt.A.toPairs=Wa.toPairs,Yt.A.toPairsIn=Wa.toPairsIn,Yt.A.toPath=$l.toPath,Yt.A.toPlainObject=ua.toPlainObject,Yt.A.transform=Wa.transform,Yt.A.unary=xd.unary,Yt.A.union=Cs.union,Yt.A.unionBy=Cs.unionBy,Yt.A.unionWith=Cs.unionWith,Yt.A.uniq=Cs.uniq,Yt.A.uniqBy=Cs.uniqBy,Yt.A.uniqWith=Cs.uniqWith,Yt.A.unset=Wa.unset,Yt.A.unzip=Cs.unzip,Yt.A.unzipWith=Cs.unzipWith,Yt.A.update=Wa.update,Yt.A.updateWith=Wa.updateWith,Yt.A.values=Wa.values,Yt.A.valuesIn=Wa.valuesIn,Yt.A.without=Cs.without,Yt.A.words=wl.words,Yt.A.wrap=xd.wrap,Yt.A.xor=Cs.xor,Yt.A.xorBy=Cs.xorBy,Yt.A.xorWith=Cs.xorWith,Yt.A.zip=Cs.zip,Yt.A.zipObject=Cs.zipObject,Yt.A.zipObjectDeep=Cs.zipObjectDeep,Yt.A.zipWith=Cs.zipWith,Yt.A.entries=Wa.toPairs,Yt.A.entriesIn=Wa.toPairsIn,Yt.A.extend=Wa.assignIn,Yt.A.extendWith=Wa.assignInWith,KC(Yt.A,Yt.A),Yt.A.add=yp.add,Yt.A.attempt=$l.attempt,Yt.A.camelCase=wl.camelCase,Yt.A.capitalize=wl.capitalize,Yt.A.ceil=yp.ceil,Yt.A.clamp=UC.clamp,Yt.A.clone=ua.clone,Yt.A.cloneDeep=ua.cloneDeep,Yt.A.cloneDeepWith=ua.cloneDeepWith,Yt.A.cloneWith=ua.cloneWith,Yt.A.conformsTo=ua.conformsTo,Yt.A.deburr=wl.deburr,Yt.A.defaultTo=$l.defaultTo,Yt.A.divide=yp.divide,Yt.A.endsWith=wl.endsWith,Yt.A.eq=ua.eq,Yt.A.escape=wl.escape,Yt.A.escapeRegExp=wl.escapeRegExp,Yt.A.every=Ul.every,Yt.A.find=Ul.find,Yt.A.findIndex=Cs.findIndex,Yt.A.findKey=Wa.findKey,Yt.A.findLast=Ul.findLast,Yt.A.findLastIndex=Cs.findLastIndex,Yt.A.findLastKey=Wa.findLastKey,Yt.A.floor=yp.floor,Yt.A.forEach=Ul.forEach,Yt.A.forEachRight=Ul.forEachRight,Yt.A.forIn=Wa.forIn,Yt.A.forInRight=Wa.forInRight,Yt.A.forOwn=Wa.forOwn,Yt.A.forOwnRight=Wa.forOwnRight,Yt.A.get=Wa.get,Yt.A.gt=ua.gt,Yt.A.gte=ua.gte,Yt.A.has=Wa.has,Yt.A.hasIn=Wa.hasIn,Yt.A.head=Cs.head,Yt.A.identity=Ap.A,Yt.A.includes=Ul.includes,Yt.A.indexOf=Cs.indexOf,Yt.A.inRange=UC.inRange,Yt.A.invoke=Wa.invoke,Yt.A.isArguments=ua.isArguments,Yt.A.isArray=ci.A,Yt.A.isArrayBuffer=ua.isArrayBuffer,Yt.A.isArrayLike=ua.isArrayLike,Yt.A.isArrayLikeObject=ua.isArrayLikeObject,Yt.A.isBoolean=ua.isBoolean,Yt.A.isBuffer=ua.isBuffer,Yt.A.isDate=ua.isDate,Yt.A.isElement=ua.isElement,Yt.A.isEmpty=ua.isEmpty,Yt.A.isEqual=ua.isEqual,Yt.A.isEqualWith=ua.isEqualWith,Yt.A.isError=ua.isError,Yt.A.isFinite=ua.isFinite,Yt.A.isFunction=ua.isFunction,Yt.A.isInteger=ua.isInteger,Yt.A.isLength=ua.isLength,Yt.A.isMap=ua.isMap,Yt.A.isMatch=ua.isMatch,Yt.A.isMatchWith=ua.isMatchWith,Yt.A.isNaN=ua.isNaN,Yt.A.isNative=ua.isNative,Yt.A.isNil=ua.isNil,Yt.A.isNull=ua.isNull,Yt.A.isNumber=ua.isNumber,Yt.A.isObject=ns.A,Yt.A.isObjectLike=ua.isObjectLike,Yt.A.isPlainObject=ua.isPlainObject,Yt.A.isRegExp=ua.isRegExp,Yt.A.isSafeInteger=ua.isSafeInteger,Yt.A.isSet=ua.isSet,Yt.A.isString=ua.isString,Yt.A.isSymbol=ua.isSymbol,Yt.A.isTypedArray=ua.isTypedArray,Yt.A.isUndefined=ua.isUndefined,Yt.A.isWeakMap=ua.isWeakMap,Yt.A.isWeakSet=ua.isWeakSet,Yt.A.join=Cs.join,Yt.A.kebabCase=wl.kebabCase,Yt.A.last=Jf,Yt.A.lastIndexOf=Cs.lastIndexOf,Yt.A.lowerCase=wl.lowerCase,Yt.A.lowerFirst=wl.lowerFirst,Yt.A.lt=ua.lt,Yt.A.lte=ua.lte,Yt.A.max=yp.max,Yt.A.maxBy=yp.maxBy,Yt.A.mean=yp.mean,Yt.A.meanBy=yp.meanBy,Yt.A.min=yp.min,Yt.A.minBy=yp.minBy,Yt.A.stubArray=$l.stubArray,Yt.A.stubFalse=$l.stubFalse,Yt.A.stubObject=$l.stubObject,Yt.A.stubString=$l.stubString,Yt.A.stubTrue=$l.stubTrue,Yt.A.multiply=yp.multiply,Yt.A.nth=Cs.nth,Yt.A.noop=$l.noop,Yt.A.now=JM.now,Yt.A.pad=wl.pad,Yt.A.padEnd=wl.padEnd,Yt.A.padStart=wl.padStart,Yt.A.parseInt=wl.parseInt,Yt.A.random=UC.random,Yt.A.reduce=Ul.reduce,Yt.A.reduceRight=Ul.reduceRight,Yt.A.repeat=wl.repeat,Yt.A.replace=wl.replace,Yt.A.result=Wa.result,Yt.A.round=yp.round,Yt.A.sample=Ul.sample,Yt.A.size=Ul.size,Yt.A.snakeCase=wl.snakeCase,Yt.A.some=Ul.some,Yt.A.sortedIndex=Cs.sortedIndex,Yt.A.sortedIndexBy=Cs.sortedIndexBy,Yt.A.sortedIndexOf=Cs.sortedIndexOf,Yt.A.sortedLastIndex=Cs.sortedLastIndex,Yt.A.sortedLastIndexBy=Cs.sortedLastIndexBy,Yt.A.sortedLastIndexOf=Cs.sortedLastIndexOf,Yt.A.startCase=wl.startCase,Yt.A.startsWith=wl.startsWith,Yt.A.subtract=yp.subtract,Yt.A.sum=yp.sum,Yt.A.sumBy=yp.sumBy,Yt.A.template=wl.template,Yt.A.times=$l.times,Yt.A.toFinite=ua.toFinite,Yt.A.toInteger=oe.A,Yt.A.toLength=ua.toLength,Yt.A.toLower=wl.toLower,Yt.A.toNumber=ua.toNumber,Yt.A.toSafeInteger=ua.toSafeInteger,Yt.A.toString=ua.toString,Yt.A.toUpper=wl.toUpper,Yt.A.trim=wl.trim,Yt.A.trimEnd=wl.trimEnd,Yt.A.trimStart=wl.trimStart,Yt.A.truncate=wl.truncate,Yt.A.unescape=wl.unescape,Yt.A.uniqueId=$l.uniqueId,Yt.A.upperCase=wl.upperCase,Yt.A.upperFirst=wl.upperFirst,Yt.A.each=Ul.forEach,Yt.A.eachRight=Ul.forEachRight,Yt.A.first=Cs.head,KC(Yt.A,(N={},Ah(Yt.A,function($,ge){$w.call(Yt.A.prototype,ge)||(N[ge]=$)}),N),{chain:!1}),Yt.A.VERSION="4.17.21",(Yt.A.templateSettings=wl.templateSettings).imports._=Yt.A,(0,gs.A)(["bind","bindKey","curry","curryRight","partial","partialRight"],function(N){Yt.A[N].placeholder=Yt.A}),(0,gs.A)(["drop","take"],function(N,$){pa.A.prototype[N]=function(ge){ge=void 0===ge?1:Qb((0,oe.A)(ge),0);var nt=this.__filtered__&&!$?new pa.A(this):this.clone();return nt.__filtered__?nt.__takeCount__=qS(ge,nt.__takeCount__):nt.__views__.push({size:qS(ge,Uw),type:N+(nt.__dir__<0?"Right":"")}),nt},pa.A.prototype[N+"Right"]=function(ge){return this.reverse()[N](ge).reverse()}}),(0,gs.A)(["filter","map","takeWhile"],function(N,$){var ge=$+1,nt=1==ge||3==ge;pa.A.prototype[N]=function(Lt){var bn=this.clone();return bn.__iteratees__.push({iteratee:fa(Lt),type:ge}),bn.__filtered__=bn.__filtered__||nt,bn}}),(0,gs.A)(["head","last"],function(N,$){var ge="take"+($?"Right":"");pa.A.prototype[N]=function(){return this[ge](1).value()[0]}}),(0,gs.A)(["initial","tail"],function(N,$){var ge="drop"+($?"":"Right");pa.A.prototype[N]=function(){return this.__filtered__?new pa.A(this):this[ge](1)}}),pa.A.prototype.compact=function(){return this.filter(Ap.A)},pa.A.prototype.find=function(N){return this.filter(N).head()},pa.A.prototype.findLast=function(N){return this.reverse().find(N)},pa.A.prototype.invokeMap=(0,un.A)(function(N,$){return"function"==typeof N?new pa.A(this):this.map(function(ge){return uh(ge,N,$)})}),pa.A.prototype.reject=function(N){return this.filter(l_(fa(N)))},pa.A.prototype.slice=function(N,$){N=(0,oe.A)(N);var ge=this;return ge.__filtered__&&(N>0||$<0)?new pa.A(ge):(N<0?ge=ge.takeRight(-N):N&&(ge=ge.drop(N)),void 0!==$&&(ge=($=(0,oe.A)($))<0?ge.dropRight(-$):ge.take($-N)),ge)},pa.A.prototype.takeRightWhile=function(N){return this.reverse().takeWhile(N).reverse()},pa.A.prototype.toArray=function(){return this.take(Uw)},Ah(pa.A.prototype,function(N,$){var ge=/^(?:filter|find|map|reject)|While$/.test($),nt=/^(?:head|last)$/.test($),Lt=Yt.A[nt?"take"+("last"==$?"Right":""):$],bn=nt||/^find/.test($);Lt&&(Yt.A.prototype[$]=function(){var ui=this.__wrapped__,Hi=nt?[1]:arguments,yr=ui instanceof pa.A,fs=Hi[0],co=yr||(0,ci.A)(ui),Do=function(Da){var fd=Lt.apply(Yt.A,as([Da],Hi));return nt&&Ts?fd[0]:fd};co&&ge&&"function"==typeof fs&&1!=fs.length&&(yr=co=!1);var Ts=this.__chain__,gl=bn&&!Ts,Xs=yr&&!this.__actions__.length;if(!bn&&co){ui=Xs?ui:new pa.A(this);var il=N.apply(ui,Hi);return il.__actions__.push({func:s0,args:[Do],thisArg:void 0}),new ee.A(il,Ts)}return gl&&Xs?N.apply(this,Hi):(il=this.thru(Do),gl?nt?il.value()[0]:il.value():il)})}),(0,gs.A)(["pop","push","shift","sort","splice","unshift"],function(N){var $=vh[N],ge=/^(?:push|sort|unshift)$/.test(N)?"tap":"thru",nt=/^(?:pop|shift)$/.test(N);Yt.A.prototype[N]=function(){var Lt=arguments;if(nt&&!this.__chain__){var bn=this.value();return $.apply((0,ci.A)(bn)?bn:[],Lt)}return this[ge](function(ui){return $.apply((0,ci.A)(ui)?ui:[],Lt)})}}),Ah(pa.A.prototype,function(N,$){var ge=Yt.A[$];if(ge){var nt=ge.name+"";$w.call(Kp.A,nt)||(Kp.A[nt]=[]),Kp.A[nt].push({name:$,func:ge})}}),Kp.A[(0,eI.A)(void 0,2).name]=[{name:"wrapper",func:void 0}],pa.A.prototype.clone=function NA(){var N=new pa.A(this.__wrapped__);return N.__actions__=(0,tt.A)(this.__actions__),N.__dir__=this.__dir__,N.__filtered__=this.__filtered__,N.__iteratees__=(0,tt.A)(this.__iteratees__),N.__takeCount__=this.__takeCount__,N.__views__=(0,tt.A)(this.__views__),N},pa.A.prototype.reverse=function gh(){if(this.__filtered__){var N=new pa.A(this);N.__dir__=-1,N.__filtered__=!0}else(N=this.clone()).__dir__*=-1;return N},pa.A.prototype.value=function WC(){var N=this.__wrapped__.value(),$=this.__dir__,ge=(0,ci.A)(N),nt=$<0,Lt=ge?N.length:0,bn=function tI(N,$,ge){for(var nt=-1,Lt=ge.length;++nt<Lt;){var bn=ge[nt],ui=bn.size;switch(bn.type){case"drop":N+=ui;break;case"dropRight":$-=ui;break;case"take":$=p0($,N+ui);break;case"takeRight":N=Gp(N,$-ui)}}return{start:N,end:$}}(0,Lt,this.__views__),ui=bn.start,Hi=bn.end,yr=Hi-ui,fs=nt?Hi:ui-1,co=this.__iteratees__,Do=co.length,Ts=0,os=$C(yr,this.__takeCount__);if(!ge||!nt&&Lt==yr&&os==yr)return A_(N,this.__actions__);var gl=[];e:for(;yr--&&Ts<os;){for(var Xs=-1,il=N[fs+=$];++Xs<Do;){var Da=co[Xs],zd=Da.type,Sm=(0,Da.iteratee)(il);if(2==zd)il=Sm;else if(!Sm){if(1==zd)continue e;break e}}gl[Ts++]=il}return gl},Yt.A.prototype.at=Sf.at,Yt.A.prototype.chain=Sf.wrapperChain,Yt.A.prototype.commit=Sf.commit,Yt.A.prototype.next=Sf.next,Yt.A.prototype.plant=Sf.plant,Yt.A.prototype.reverse=Sf.reverse,Yt.A.prototype.toJSON=Yt.A.prototype.valueOf=Yt.A.prototype.value=Sf.value,Yt.A.prototype.first=Yt.A.prototype.head,bp&&(Yt.A.prototype[bp]=Sf.toIterator);const k_=Yt.A},4569:(Ot,Me,S)=>{S.d(Me,{A:()=>X});var i=S(2291);function M(ie,Q){if("function"!=typeof ie||null!=Q&&"function"!=typeof Q)throw new TypeError("Expected a function");var Ee=function(){var he=arguments,q=Q?Q.apply(this,he):he[0],oe=Ee.cache;if(oe.has(q))return oe.get(q);var Z=ie.apply(this,he);return Ee.cache=oe.set(q,Z)||oe,Z};return Ee.cache=new(M.Cache||i.A),Ee}M.Cache=i.A;const X=M},3565:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(){}},9532:(Ot,Me,S)=>{S.d(Me,{A:()=>Ee});var i=S(363),e=S(6151),M=S(4388),X=S(3595),Q=(0,i.A)(function(he,q){var oe=(0,X.A)(q,(0,M.A)(Q));return(0,e.A)(he,32,void 0,q,oe)});Q.placeholder={};const Ee=Q},953:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(5473);const M=function e(X,ie,Q){return null==X?X:(0,i.A)(X,ie,Q)}},5554:(Ot,Me,S)=>{S.d(Me,{A:()=>e});const e=function i(){return!1}},8747:(Ot,Me,S)=>{S.d(Me,{A:()=>ie});var i=S(2949),e=1/0;const ie=function X(Q){return Q?(Q=(0,i.A)(Q))===e||Q===-e?17976931348623157e292*(Q<0?-1:1):Q==Q?Q:0:0===Q?Q:0}},2184:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(8747);const M=function e(X){var ie=(0,i.A)(X),Q=ie%1;return ie==ie?Q?ie-Q:ie:0}},2949:(Ot,Me,S)=>{S.d(Me,{A:()=>oe});var i=S(673),e=S(554),M=S(4077),ie=/^[-+]0x[0-9a-f]+$/i,Q=/^0b[01]+$/i,Ee=/^0o[0-7]+$/i,he=parseInt;const oe=function q(Z){if("number"==typeof Z)return Z;if((0,M.A)(Z))return NaN;if((0,e.A)(Z)){var ce="function"==typeof Z.valueOf?Z.valueOf():Z;Z=(0,e.A)(ce)?ce+"":ce}if("string"!=typeof Z)return 0===Z?Z:+Z;Z=(0,i.A)(Z);var le=Q.test(Z);return le||Ee.test(Z)?he(Z.slice(2),le?2:8):ie.test(Z)?NaN:+Z}},1705:(Ot,Me,S)=>{S.d(Me,{A:()=>M});var i=S(1473);const M=function e(X){return null==X?"":(0,i.A)(X)}},7907:(Ot,Me,S)=>{S.d(Me,{A:()=>oe});var i=S(7071),e=S(8754),M=S(6180),X=S(3744),ie=S(2661),Q=S(6740),he=Object.prototype.hasOwnProperty;function q(Z){if((0,ie.A)(Z)&&!(0,X.A)(Z)&&!(Z instanceof i.A)){if(Z instanceof e.A)return Z;if(he.call(Z,"__wrapped__"))return(0,Q.A)(Z)}return new e.A(Z)}(q.prototype=M.A.prototype).constructor=q;const oe=q},4549:(Ot,Me,S)=>{S.r(Me),S.d(Me,{DateTime:()=>$o,Duration:()=>da,FixedOffsetZone:()=>qn,IANAZone:()=>Zn,Info:()=>_c,Interval:()=>bl,InvalidZone:()=>Ti,Settings:()=>_r,SystemZone:()=>St,VERSION:()=>yc,Zone:()=>ji});class i extends Error{}class e extends i{constructor(ne){super(`Invalid DateTime: ${ne.toMessage()}`)}}class M extends i{constructor(ne){super(`Invalid Interval: ${ne.toMessage()}`)}}class X extends i{constructor(ne){super(`Invalid Duration: ${ne.toMessage()}`)}}class ie extends i{}class Q extends i{constructor(ne){super(`Invalid unit ${ne}`)}}class Ee extends i{}class he extends i{constructor(){super("Zone is an abstract class")}}const q="numeric",oe="short",Z="long",ce={year:q,month:q,day:q},le={year:q,month:oe,day:q},je={year:q,month:oe,day:q,weekday:oe},Et={year:q,month:Z,day:q},wt={year:q,month:Z,day:q,weekday:Z},ve={hour:q,minute:q},fn={hour:q,minute:q,second:q},ct={hour:q,minute:q,second:q,timeZoneName:oe},en={hour:q,minute:q,second:q,timeZoneName:Z},an={hour:q,minute:q,hourCycle:"h23"},un={hour:q,minute:q,second:q,hourCycle:"h23"},vn={hour:q,minute:q,second:q,hourCycle:"h23",timeZoneName:oe},Pt={hour:q,minute:q,second:q,hourCycle:"h23",timeZoneName:Z},Ae={year:q,month:q,day:q,hour:q,minute:q},dt={year:q,month:q,day:q,hour:q,minute:q,second:q},ut={year:q,month:oe,day:q,hour:q,minute:q},Mt={year:q,month:oe,day:q,hour:q,minute:q,second:q},Wt={year:q,month:oe,day:q,weekday:oe,hour:q,minute:q},It={year:q,month:Z,day:q,hour:q,minute:q,timeZoneName:oe},Vn={year:q,month:Z,day:q,hour:q,minute:q,second:q,timeZoneName:oe},pn={year:q,month:Z,day:q,weekday:Z,hour:q,minute:q,timeZoneName:Z},Wn={year:q,month:Z,day:q,weekday:Z,hour:q,minute:q,second:q,timeZoneName:Z};class ji{get type(){throw new he}get name(){throw new he}get ianaName(){return this.name}get isUniversal(){throw new he}offsetName(ne,Pe){throw new he}formatOffset(ne,Pe){throw new he}offset(ne){throw new he}equals(ne){throw new he}get isValid(){throw new he}}let An=null;class St extends ji{static get instance(){return null===An&&(An=new St),An}get type(){return"system"}get name(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(ne,{format:Pe,locale:rt}){return ks(ne,Pe,rt)}formatOffset(ne,Pe){return ds(this.offset(ne),Pe)}offset(ne){return-new Date(ne).getTimezoneOffset()}equals(ne){return"system"===ne.type}get isValid(){return!0}}let qt={};const on={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};let fi={};class Zn extends ji{static create(ne){return fi[ne]||(fi[ne]=new Zn(ne)),fi[ne]}static resetCache(){fi={},qt={}}static isValidSpecifier(ne){return this.isValidZone(ne)}static isValidZone(ne){if(!ne)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:ne}).format(),!0}catch{return!1}}constructor(ne){super(),this.zoneName=ne,this.valid=Zn.isValidZone(ne)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(ne,{format:Pe,locale:rt}){return ks(ne,Pe,rt,this.name)}formatOffset(ne,Pe){return ds(this.offset(ne),Pe)}offset(ne){const Pe=new Date(ne);if(isNaN(Pe))return NaN;const rt=function Ht(Ue){return qt[Ue]||(qt[Ue]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:Ue,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),qt[Ue]}(this.name);let[Ut,Rn,Kn,Y,Ce,ue,Ie]=rt.formatToParts?function tn(Ue,ne){const Pe=Ue.formatToParts(ne),rt=[];for(let Ut=0;Ut<Pe.length;Ut++){const{type:Rn,value:Kn}=Pe[Ut],Y=on[Rn];"era"===Rn?rt[Y]=Kn:Qr(Y)||(rt[Y]=parseInt(Kn,10))}return rt}(rt,Pe):function Cn(Ue,ne){const Pe=Ue.format(ne).replace(/\u200E/g,""),rt=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(Pe),[,Ut,Rn,Kn,Y,Ce,ue,Ie]=rt;return[Kn,Ut,Rn,Y,Ce,ue,Ie]}(rt,Pe);"BC"===Y&&(Ut=1-Math.abs(Ut));let rn=+Pe;const Si=rn%1e3;return rn-=Si>=0?Si:1e3+Si,(Li({year:Ut,month:Rn,day:Kn,hour:24===Ce?0:Ce,minute:ue,second:Ie,millisecond:0})-rn)/6e4}equals(ne){return"iana"===ne.type&&ne.name===this.name}get isValid(){return this.valid}}let Dn={},Nn={};function Yn(Ue,ne={}){const Pe=JSON.stringify([Ue,ne]);let rt=Nn[Pe];return rt||(rt=new Intl.DateTimeFormat(Ue,ne),Nn[Pe]=rt),rt}let cr={},Qi={},Ur=null,as={};function Gt(Ue,ne,Pe,rt){const Ut=Ue.listingMode();return"error"===Ut?null:"en"===Ut?Pe(ne):rt(ne)}class ri{constructor(ne,Pe,rt){this.padTo=rt.padTo||0,this.floor=rt.floor||!1;const{padTo:Ut,floor:Rn,...Kn}=rt;if(!Pe||Object.keys(Kn).length>0){const Y={useGrouping:!1,...rt};rt.padTo>0&&(Y.minimumIntegerDigits=rt.padTo),this.inf=function Ai(Ue,ne={}){const Pe=JSON.stringify([Ue,ne]);let rt=cr[Pe];return rt||(rt=new Intl.NumberFormat(Ue,ne),cr[Pe]=rt),rt}(ne,Y)}}format(ne){if(this.inf){const Pe=this.floor?Math.floor(ne):ne;return this.inf.format(Pe)}return Tt(this.floor?Math.floor(ne):Un(ne,3),this.padTo)}}class pi{constructor(ne,Pe,rt){let Ut;if(this.opts=rt,this.originalZone=void 0,this.opts.timeZone)this.dt=ne;else if("fixed"===ne.zone.type){const Kn=ne.offset/60*-1,Y=Kn>=0?`Etc/GMT+${Kn}`:`Etc/GMT${Kn}`;0!==ne.offset&&Zn.create(Y).valid?(Ut=Y,this.dt=ne):(Ut="UTC",this.dt=0===ne.offset?ne:ne.setZone("UTC").plus({minutes:ne.offset}),this.originalZone=ne.zone)}else"system"===ne.zone.type?this.dt=ne:"iana"===ne.zone.type?(this.dt=ne,Ut=ne.zone.name):(Ut="UTC",this.dt=ne.setZone("UTC").plus({minutes:ne.offset}),this.originalZone=ne.zone);const Rn={...this.opts};Rn.timeZone=Rn.timeZone||Ut,this.dtf=Yn(Pe,Rn)}format(){return this.originalZone?this.formatToParts().map(({value:ne})=>ne).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){const ne=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?ne.map(Pe=>{if("timeZoneName"===Pe.type){const rt=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...Pe,value:rt}}return Pe}):ne}resolvedOptions(){return this.dtf.resolvedOptions()}}class At{constructor(ne,Pe,rt){this.opts={style:"long",...rt},!Pe&&jt()&&(this.rtf=function Xr(Ue,ne={}){const{base:Pe,...rt}=ne,Ut=JSON.stringify([Ue,rt]);let Rn=Qi[Ut];return Rn||(Rn=new Intl.RelativeTimeFormat(Ue,ne),Qi[Ut]=Rn),Rn}(ne,rt))}format(ne,Pe){return this.rtf?this.rtf.format(ne,Pe):function Qc(Ue,ne,Pe="always",rt=!1){const Ut={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},Rn=-1===["hours","minutes","seconds"].indexOf(Ue);if("auto"===Pe&&Rn){const Ze="days"===Ue;switch(ne){case 1:return Ze?"tomorrow":`next ${Ut[Ue][0]}`;case-1:return Ze?"yesterday":`last ${Ut[Ue][0]}`;case 0:return Ze?"today":`this ${Ut[Ue][0]}`}}const Kn=Object.is(ne,-0)||ne<0,Y=Math.abs(ne),Ce=1===Y,ue=Ut[Ue],Ie=rt?Ce?ue[1]:ue[2]||ue[1]:Ce?Ut[Ue][0]:Ue;return Kn?`${Y} ${Ie} ago`:`in ${Y} ${Ie}`}(Pe,ne,this.opts.numeric,"long"!==this.opts.style)}formatToParts(ne,Pe){return this.rtf?this.rtf.formatToParts(ne,Pe):[]}}const Bn={firstDay:1,minimalDays:4,weekend:[6,7]};class Mn{static fromOpts(ne){return Mn.create(ne.locale,ne.numberingSystem,ne.outputCalendar,ne.weekSettings,ne.defaultToEN)}static create(ne,Pe,rt,Ut,Rn=!1){const Kn=ne||_r.defaultLocale,Y=Kn||(Rn?"en-US":function eo(){return Ur||(Ur=(new Intl.DateTimeFormat).resolvedOptions().locale,Ur)}()),Ce=Pe||_r.defaultNumberingSystem,ue=rt||_r.defaultOutputCalendar,Ie=ar(Ut)||_r.defaultWeekSettings;return new Mn(Y,Ce,ue,Ie,Kn)}static resetCache(){Ur=null,Nn={},cr={},Qi={}}static fromObject({locale:ne,numberingSystem:Pe,outputCalendar:rt,weekSettings:Ut}={}){return Mn.create(ne,Pe,rt,Ut)}constructor(ne,Pe,rt,Ut,Rn){const[Kn,Y,Ce]=function mi(Ue){const ne=Ue.indexOf("-x-");-1!==ne&&(Ue=Ue.substring(0,ne));const Pe=Ue.indexOf("-u-");if(-1===Pe)return[Ue];{let rt,Ut;try{rt=Yn(Ue).resolvedOptions(),Ut=Ue}catch{const Ce=Ue.substring(0,Pe);rt=Yn(Ce).resolvedOptions(),Ut=Ce}const{numberingSystem:Rn,calendar:Kn}=rt;return[Ut,Rn,Kn]}}(ne);this.locale=Kn,this.numberingSystem=Pe||Y||null,this.outputCalendar=rt||Ce||null,this.weekSettings=Ut,this.intl=function ci(Ue,ne,Pe){return(Pe||ne)&&(Ue.includes("-u-")||(Ue+="-u"),Pe&&(Ue+=`-ca-${Pe}`),ne&&(Ue+=`-nu-${ne}`)),Ue}(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=Rn,this.fastNumbersCached=null}get fastNumbers(){return null==this.fastNumbersCached&&(this.fastNumbersCached=function Gn(Ue){return(!Ue.numberingSystem||"latn"===Ue.numberingSystem)&&("latn"===Ue.numberingSystem||!Ue.locale||Ue.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(Ue.intl).resolvedOptions().numberingSystem)}(this)),this.fastNumbersCached}listingMode(){return this.isEnglish()&&!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar)?"en":"intl"}clone(ne){return ne&&0!==Object.getOwnPropertyNames(ne).length?Mn.create(ne.locale||this.specifiedLocale,ne.numberingSystem||this.numberingSystem,ne.outputCalendar||this.outputCalendar,ar(ne.weekSettings)||this.weekSettings,ne.defaultToEN||!1):this}redefaultToEN(ne={}){return this.clone({...ne,defaultToEN:!0})}redefaultToSystem(ne={}){return this.clone({...ne,defaultToEN:!1})}months(ne,Pe=!1){return Gt(this,ne,ea,()=>{const rt=Pe?{month:ne,day:"numeric"}:{month:ne},Ut=Pe?"format":"standalone";return this.monthsCache[Ut][ne]||(this.monthsCache[Ut][ne]=function yt(Ue){const ne=[];for(let Pe=1;Pe<=12;Pe++){const rt=$o.utc(2009,Pe,1);ne.push(Ue(rt))}return ne}(Rn=>this.extract(Rn,rt,"month"))),this.monthsCache[Ut][ne]})}weekdays(ne,Pe=!1){return Gt(this,ne,Ia,()=>{const rt=Pe?{weekday:ne,year:"numeric",month:"long",day:"numeric"}:{weekday:ne},Ut=Pe?"format":"standalone";return this.weekdaysCache[Ut][ne]||(this.weekdaysCache[Ut][ne]=function hn(Ue){const ne=[];for(let Pe=1;Pe<=7;Pe++){const rt=$o.utc(2016,11,13+Pe);ne.push(Ue(rt))}return ne}(Rn=>this.extract(Rn,rt,"weekday"))),this.weekdaysCache[Ut][ne]})}meridiems(){return Gt(this,void 0,()=>al,()=>{if(!this.meridiemCache){const ne={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[$o.utc(2016,11,13,9),$o.utc(2016,11,13,19)].map(Pe=>this.extract(Pe,ne,"dayperiod"))}return this.meridiemCache})}eras(ne){return Gt(this,ne,qc,()=>{const Pe={era:ne};return this.eraCache[ne]||(this.eraCache[ne]=[$o.utc(-40,1,1),$o.utc(2017,1,1)].map(rt=>this.extract(rt,Pe,"era"))),this.eraCache[ne]})}extract(ne,Pe,rt){const Kn=this.dtFormatter(ne,Pe).formatToParts().find(Y=>Y.type.toLowerCase()===rt);return Kn?Kn.value:null}numberFormatter(ne={}){return new ri(this.intl,ne.forceSimple||this.fastNumbers,ne)}dtFormatter(ne,Pe={}){return new pi(ne,this.intl,Pe)}relFormatter(ne={}){return new At(this.intl,this.isEnglish(),ne)}listFormatter(ne={}){return function gn(Ue,ne={}){const Pe=JSON.stringify([Ue,ne]);let rt=Dn[Pe];return rt||(rt=new Intl.ListFormat(Ue,ne),Dn[Pe]=rt),rt}(this.intl,ne)}isEnglish(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:In()?function uo(Ue){let ne=as[Ue];if(!ne){const Pe=new Intl.Locale(Ue);ne="getWeekInfo"in Pe?Pe.getWeekInfo():Pe.weekInfo,as[Ue]=ne}return ne}(this.locale):Bn}getStartOfWeek(){return this.getWeekSettings().firstDay}getMinDaysInFirstWeek(){return this.getWeekSettings().minimalDays}getWeekendDays(){return this.getWeekSettings().weekend}equals(ne){return this.locale===ne.locale&&this.numberingSystem===ne.numberingSystem&&this.outputCalendar===ne.outputCalendar}toString(){return`Locale(${this.locale}, ${this.numberingSystem}, ${this.outputCalendar})`}}let ni=null;class qn extends ji{static get utcInstance(){return null===ni&&(ni=new qn(0)),ni}static instance(ne){return 0===ne?qn.utcInstance:new qn(ne)}static parseSpecifier(ne){if(ne){const Pe=ne.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(Pe)return new qn(Jo(Pe[1],Pe[2]))}return null}constructor(ne){super(),this.fixed=ne}get type(){return"fixed"}get name(){return 0===this.fixed?"UTC":`UTC${ds(this.fixed,"narrow")}`}get ianaName(){return 0===this.fixed?"Etc/UTC":`Etc/GMT${ds(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(ne,Pe){return ds(this.fixed,Pe)}get isUniversal(){return!0}offset(){return this.fixed}equals(ne){return"fixed"===ne.type&&ne.fixed===this.fixed}get isValid(){return!0}}class Ti extends ji{constructor(ne){super(),this.zoneName=ne}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function Bi(Ue,ne){if(Qr(Ue)||null===Ue)return ne;if(Ue instanceof ji)return Ue;if(function Lo(Ue){return"string"==typeof Ue}(Ue)){const rt=Ue.toLowerCase();return"default"===rt?ne:"local"===rt||"system"===rt?St.instance:"utc"===rt||"gmt"===rt?qn.utcInstance:qn.parseSpecifier(rt)||Zn.create(Ue)}return dl(Ue)?qn.instance(Ue):"object"==typeof Ue&&"offset"in Ue&&"function"==typeof Ue.offset?Ue:new Ti(Ue)}const Gi={arab:"[\u0660-\u0669]",arabext:"[\u06f0-\u06f9]",bali:"[\u1b50-\u1b59]",beng:"[\u09e6-\u09ef]",deva:"[\u0966-\u096f]",fullwide:"[\uff10-\uff19]",gujr:"[\u0ae6-\u0aef]",hanidec:"[\u3007|\u4e00|\u4e8c|\u4e09|\u56db|\u4e94|\u516d|\u4e03|\u516b|\u4e5d]",khmr:"[\u17e0-\u17e9]",knda:"[\u0ce6-\u0cef]",laoo:"[\u0ed0-\u0ed9]",limb:"[\u1946-\u194f]",mlym:"[\u0d66-\u0d6f]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0b66-\u0b6f]",tamldec:"[\u0be6-\u0bef]",telu:"[\u0c66-\u0c6f]",thai:"[\u0e50-\u0e59]",tibt:"[\u0f20-\u0f29]",latn:"\\d"},Ii={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},Ki=Gi.hanidec.replace(/[\[|\]]/g,"").split("");let hi={};function it({numberingSystem:Ue},ne=""){const Pe=Ue||"latn";return hi[Pe]||(hi[Pe]={}),hi[Pe][ne]||(hi[Pe][ne]=new RegExp(`${Gi[Pe]}${ne}`)),hi[Pe][ne]}let Jn,sn=()=>Date.now(),Ve="system",He=null,mt=null,bt=null,nn=60,Sn=null;class _r{static get now(){return sn}static set now(ne){sn=ne}static set defaultZone(ne){Ve=ne}static get defaultZone(){return Bi(Ve,St.instance)}static get defaultLocale(){return He}static set defaultLocale(ne){He=ne}static get defaultNumberingSystem(){return mt}static set defaultNumberingSystem(ne){mt=ne}static get defaultOutputCalendar(){return bt}static set defaultOutputCalendar(ne){bt=ne}static get defaultWeekSettings(){return Sn}static set defaultWeekSettings(ne){Sn=ar(ne)}static get twoDigitCutoffYear(){return nn}static set twoDigitCutoffYear(ne){nn=ne%100}static get throwOnInvalid(){return Jn}static set throwOnInvalid(ne){Jn=ne}static resetCaches(){Mn.resetCache(),Zn.resetCache(),$o.resetCache(),function Ft(){hi={}}()}}class qr{constructor(ne,Pe){this.reason=ne,this.explanation=Pe}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const Bo=[0,31,59,90,120,151,181,212,243,273,304,334],Eo=[0,31,60,91,121,152,182,213,244,274,305,335];function Ro(Ue,ne){return new qr("unit out of range",`you specified ${ne} (of type ${typeof ne}) as a ${Ue}, which is invalid`)}function Ls(Ue,ne,Pe){const rt=new Date(Date.UTC(Ue,ne-1,Pe));Ue<100&&Ue>=0&&rt.setUTCFullYear(rt.getUTCFullYear()-1900);const Ut=rt.getUTCDay();return 0===Ut?7:Ut}function ol(Ue,ne,Pe){return Pe+(Yi(Ue)?Eo:Bo)[ne-1]}function Va(Ue,ne){const Pe=Yi(Ue)?Eo:Bo,rt=Pe.findIndex(Rn=>Rn<ne);return{month:rt+1,day:ne-Pe[rt]}}function Ao(Ue,ne){return(Ue-ne+7)%7+1}function za(Ue,ne=4,Pe=1){const{year:rt,month:Ut,day:Rn}=Ue,Kn=ol(rt,Ut,Rn),Y=Ao(Ls(rt,Ut,Rn),Pe);let ue,Ce=Math.floor((Kn-Y+14-ne)/7);return Ce<1?(ue=rt-1,Ce=vr(ue,ne,Pe)):Ce>vr(rt,ne,Pe)?(ue=rt+1,Ce=1):ue=rt,{weekYear:ue,weekNumber:Ce,weekday:Y,...Ws(Ue)}}function vl(Ue,ne=4,Pe=1){const{weekYear:rt,weekNumber:Ut,weekday:Rn}=Ue,Kn=Ao(Ls(rt,1,ne),Pe),Y=Wi(rt);let ue,Ce=7*Ut+Rn-Kn-7+ne;Ce<1?(ue=rt-1,Ce+=Wi(ue)):Ce>Y?(ue=rt+1,Ce-=Wi(rt)):ue=rt;const{month:Ie,day:Ze}=Va(ue,Ce);return{year:ue,month:Ie,day:Ze,...Ws(Ue)}}function Na(Ue){const{year:ne,month:Pe,day:rt}=Ue;return{year:ne,ordinal:ol(ne,Pe,rt),...Ws(Ue)}}function _l(Ue){const{year:ne,ordinal:Pe}=Ue,{month:rt,day:Ut}=Va(ne,Pe);return{year:ne,month:rt,day:Ut,...Ws(Ue)}}function gs(Ue,ne){if(Qr(Ue.localWeekday)&&Qr(Ue.localWeekNumber)&&Qr(Ue.localWeekYear))return{minDaysInFirstWeek:4,startOfWeek:1};if(!Qr(Ue.weekday)||!Qr(Ue.weekNumber)||!Qr(Ue.weekYear))throw new ie("Cannot mix locale-based week fields with ISO-based week fields");return Qr(Ue.localWeekday)||(Ue.weekday=Ue.localWeekday),Qr(Ue.localWeekNumber)||(Ue.weekNumber=Ue.localWeekNumber),Qr(Ue.localWeekYear)||(Ue.weekYear=Ue.localWeekYear),delete Ue.localWeekday,delete Ue.localWeekNumber,delete Ue.localWeekYear,{minDaysInFirstWeek:ne.getMinDaysInFirstWeek(),startOfWeek:ne.getStartOfWeek()}}function no(Ue){const ne=Ya(Ue.year),Pe=er(Ue.month,1,12),rt=er(Ue.day,1,fr(Ue.year,Ue.month));return ne?Pe?!rt&&Ro("day",Ue.day):Ro("month",Ue.month):Ro("year",Ue.year)}function xl(Ue){const{hour:ne,minute:Pe,second:rt,millisecond:Ut}=Ue,Rn=er(ne,0,23)||24===ne&&0===Pe&&0===rt&&0===Ut,Kn=er(Pe,0,59),Y=er(rt,0,59),Ce=er(Ut,0,999);return Rn?Kn?Y?!Ce&&Ro("millisecond",Ut):Ro("second",rt):Ro("minute",Pe):Ro("hour",ne)}function Qr(Ue){return typeof Ue>"u"}function dl(Ue){return"number"==typeof Ue}function Ya(Ue){return"number"==typeof Ue&&Ue%1==0}function jt(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function In(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function jn(Ue,ne,Pe){if(0!==Ue.length)return Ue.reduce((rt,Ut)=>{const Rn=[ne(Ut),Ut];return rt&&Pe(rt[0],Rn[0])===rt[0]?rt:Rn},null)[1]}function Ui(Ue,ne){return Object.prototype.hasOwnProperty.call(Ue,ne)}function ar(Ue){if(null==Ue)return null;if("object"!=typeof Ue)throw new Ee("Week settings must be an object");if(!er(Ue.firstDay,1,7)||!er(Ue.minimalDays,1,7)||!Array.isArray(Ue.weekend)||Ue.weekend.some(ne=>!er(ne,1,7)))throw new Ee("Invalid week settings");return{firstDay:Ue.firstDay,minimalDays:Ue.minimalDays,weekend:Array.from(Ue.weekend)}}function er(Ue,ne,Pe){return Ya(Ue)&&Ue>=ne&&Ue<=Pe}function Tt(Ue,ne=2){let rt;return rt=Ue<0?"-"+(""+-Ue).padStart(ne,"0"):(""+Ue).padStart(ne,"0"),rt}function cn(Ue){if(!Qr(Ue)&&null!==Ue&&""!==Ue)return parseInt(Ue,10)}function Tn(Ue){if(!Qr(Ue)&&null!==Ue&&""!==Ue)return parseFloat(Ue)}function Ri(Ue){if(!Qr(Ue)&&null!==Ue&&""!==Ue){const ne=1e3*parseFloat("0."+Ue);return Math.floor(ne)}}function Un(Ue,ne,Pe=!1){const rt=10**ne;return(Pe?Math.trunc:Math.round)(Ue*rt)/rt}function Yi(Ue){return Ue%4==0&&(Ue%100!=0||Ue%400==0)}function Wi(Ue){return Yi(Ue)?366:365}function fr(Ue,ne){const Pe=function Or(Ue,ne){return Ue-ne*Math.floor(Ue/ne)}(ne-1,12)+1;return 2===Pe?Yi(Ue+(ne-Pe)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][Pe-1]}function Li(Ue){let ne=Date.UTC(Ue.year,Ue.month-1,Ue.day,Ue.hour,Ue.minute,Ue.second,Ue.millisecond);return Ue.year<100&&Ue.year>=0&&(ne=new Date(ne),ne.setUTCFullYear(Ue.year,Ue.month-1,Ue.day)),+ne}function Vo(Ue,ne,Pe){return-Ao(Ls(Ue,1,ne),Pe)+ne-1}function vr(Ue,ne=4,Pe=1){const rt=Vo(Ue,ne,Pe),Ut=Vo(Ue+1,ne,Pe);return(Wi(Ue)-rt+Ut)/7}function Mo(Ue){return Ue>99?Ue:Ue>_r.twoDigitCutoffYear?1900+Ue:2e3+Ue}function ks(Ue,ne,Pe,rt=null){const Ut=new Date(Ue),Rn={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};rt&&(Rn.timeZone=rt);const Kn={timeZoneName:ne,...Rn},Y=new Intl.DateTimeFormat(Pe,Kn).formatToParts(Ut).find(Ce=>"timezonename"===Ce.type.toLowerCase());return Y?Y.value:null}function Jo(Ue,ne){let Pe=parseInt(Ue,10);Number.isNaN(Pe)&&(Pe=0);const rt=parseInt(ne,10)||0;return 60*Pe+(Pe<0||Object.is(Pe,-0)?-rt:rt)}function $s(Ue){const ne=Number(Ue);if("boolean"==typeof Ue||""===Ue||Number.isNaN(ne))throw new Ee(`Invalid unit value ${Ue}`);return ne}function Js(Ue,ne){const Pe={};for(const rt in Ue)if(Ui(Ue,rt)){const Ut=Ue[rt];if(null==Ut)continue;Pe[ne(rt)]=$s(Ut)}return Pe}function ds(Ue,ne){const Pe=Math.trunc(Math.abs(Ue/60)),rt=Math.trunc(Math.abs(Ue%60)),Ut=Ue>=0?"+":"-";switch(ne){case"short":return`${Ut}${Tt(Pe,2)}:${Tt(rt,2)}`;case"narrow":return`${Ut}${Pe}${rt>0?`:${rt}`:""}`;case"techie":return`${Ut}${Tt(Pe,2)}${Tt(rt,2)}`;default:throw new RangeError(`Value format ${ne} is out of range for property format`)}}function Ws(Ue){return function Fi(Ue,ne){return ne.reduce((Pe,rt)=>(Pe[rt]=Ue[rt],Pe),{})}(Ue,["hour","minute","second","millisecond"])}const Ma=["January","February","March","April","May","June","July","August","September","October","November","December"],ts=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wo=["J","F","M","A","M","J","J","A","S","O","N","D"];function ea(Ue){switch(Ue){case"narrow":return[...wo];case"short":return[...ts];case"long":return[...Ma];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const ga=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],sl=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],fl=["M","T","W","T","F","S","S"];function Ia(Ue){switch(Ue){case"narrow":return[...fl];case"short":return[...sl];case"long":return[...ga];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const al=["AM","PM"],Kc=["Before Christ","Anno Domini"],wa=["BC","AD"],Sl=["B","A"];function qc(Ue){switch(Ue){case"narrow":return[...Sl];case"short":return[...wa];case"long":return[...Kc];default:return null}}function ec(Ue,ne){let Pe="";for(const rt of Ue)Pe+=rt.literal?rt.val:ne(rt.val);return Pe}const Yc={D:ce,DD:le,DDD:Et,DDDD:wt,t:ve,tt:fn,ttt:ct,tttt:en,T:an,TT:un,TTT:vn,TTTT:Pt,f:Ae,ff:ut,fff:It,ffff:pn,F:dt,FF:Mt,FFF:Vn,FFFF:Wn};class ca{static create(ne,Pe={}){return new ca(ne,Pe)}static parseFormat(ne){let Pe=null,rt="",Ut=!1;const Rn=[];for(let Kn=0;Kn<ne.length;Kn++){const Y=ne.charAt(Kn);"'"===Y?(rt.length>0&&Rn.push({literal:Ut||/^\s+$/.test(rt),val:rt}),Pe=null,rt="",Ut=!Ut):Ut||Y===Pe?rt+=Y:(rt.length>0&&Rn.push({literal:/^\s+$/.test(rt),val:rt}),rt=Y,Pe=Y)}return rt.length>0&&Rn.push({literal:Ut||/^\s+$/.test(rt),val:rt}),Rn}static macroTokenToFormatOpts(ne){return Yc[ne]}constructor(ne,Pe){this.opts=Pe,this.loc=ne,this.systemLoc=null}formatWithSystemDefault(ne,Pe){return null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(ne,{...this.opts,...Pe}).format()}dtFormatter(ne,Pe={}){return this.loc.dtFormatter(ne,{...this.opts,...Pe})}formatDateTime(ne,Pe){return this.dtFormatter(ne,Pe).format()}formatDateTimeParts(ne,Pe){return this.dtFormatter(ne,Pe).formatToParts()}formatInterval(ne,Pe){return this.dtFormatter(ne.start,Pe).dtf.formatRange(ne.start.toJSDate(),ne.end.toJSDate())}resolvedOptions(ne,Pe){return this.dtFormatter(ne,Pe).resolvedOptions()}num(ne,Pe=0){if(this.opts.forceSimple)return Tt(ne,Pe);const rt={...this.opts};return Pe>0&&(rt.padTo=Pe),this.loc.numberFormatter(rt).format(ne)}formatDateTimeFromString(ne,Pe){const rt="en"===this.loc.listingMode(),Ut=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,Rn=(rn,Si)=>this.loc.extract(ne,rn,Si),Kn=rn=>ne.isOffsetFixed&&0===ne.offset&&rn.allowZ?"Z":ne.isValid?ne.zone.formatOffset(ne.ts,rn.format):"",Ce=(rn,Si)=>rt?function Sc(Ue,ne){return ea(ne)[Ue.month-1]}(ne,rn):Rn(Si?{month:rn}:{month:rn,day:"numeric"},"month"),ue=(rn,Si)=>rt?function pl(Ue,ne){return Ia(ne)[Ue.weekday-1]}(ne,rn):Rn(Si?{weekday:rn}:{weekday:rn,month:"long",day:"numeric"},"weekday"),Ie=rn=>{const Si=ca.macroTokenToFormatOpts(rn);return Si?this.formatWithSystemDefault(ne,Si):rn},Ze=rn=>rt?function Ec(Ue,ne){return qc(ne)[Ue.year<0?0:1]}(ne,rn):Rn({era:rn},"era");return ec(ca.parseFormat(Pe),rn=>{switch(rn){case"S":return this.num(ne.millisecond);case"u":case"SSS":return this.num(ne.millisecond,3);case"s":return this.num(ne.second);case"ss":return this.num(ne.second,2);case"uu":return this.num(Math.floor(ne.millisecond/10),2);case"uuu":return this.num(Math.floor(ne.millisecond/100));case"m":return this.num(ne.minute);case"mm":return this.num(ne.minute,2);case"h":return this.num(ne.hour%12==0?12:ne.hour%12);case"hh":return this.num(ne.hour%12==0?12:ne.hour%12,2);case"H":return this.num(ne.hour);case"HH":return this.num(ne.hour,2);case"Z":return Kn({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return Kn({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return Kn({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return ne.zone.offsetName(ne.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return ne.zone.offsetName(ne.ts,{format:"long",locale:this.loc.locale});case"z":return ne.zoneName;case"a":return rt?function la(Ue){return al[Ue.hour<12?0:1]}(ne):Rn({hour:"numeric",hourCycle:"h12"},"dayperiod");case"d":return Ut?Rn({day:"numeric"},"day"):this.num(ne.day);case"dd":return Ut?Rn({day:"2-digit"},"day"):this.num(ne.day,2);case"c":case"E":return this.num(ne.weekday);case"ccc":return ue("short",!0);case"cccc":return ue("long",!0);case"ccccc":return ue("narrow",!0);case"EEE":return ue("short",!1);case"EEEE":return ue("long",!1);case"EEEEE":return ue("narrow",!1);case"L":return Ut?Rn({month:"numeric",day:"numeric"},"month"):this.num(ne.month);case"LL":return Ut?Rn({month:"2-digit",day:"numeric"},"month"):this.num(ne.month,2);case"LLL":return Ce("short",!0);case"LLLL":return Ce("long",!0);case"LLLLL":return Ce("narrow",!0);case"M":return Ut?Rn({month:"numeric"},"month"):this.num(ne.month);case"MM":return Ut?Rn({month:"2-digit"},"month"):this.num(ne.month,2);case"MMM":return Ce("short",!1);case"MMMM":return Ce("long",!1);case"MMMMM":return Ce("narrow",!1);case"y":return Ut?Rn({year:"numeric"},"year"):this.num(ne.year);case"yy":return Ut?Rn({year:"2-digit"},"year"):this.num(ne.year.toString().slice(-2),2);case"yyyy":return Ut?Rn({year:"numeric"},"year"):this.num(ne.year,4);case"yyyyyy":return Ut?Rn({year:"numeric"},"year"):this.num(ne.year,6);case"G":return Ze("short");case"GG":return Ze("long");case"GGGGG":return Ze("narrow");case"kk":return this.num(ne.weekYear.toString().slice(-2),2);case"kkkk":return this.num(ne.weekYear,4);case"W":return this.num(ne.weekNumber);case"WW":return this.num(ne.weekNumber,2);case"n":return this.num(ne.localWeekNumber);case"nn":return this.num(ne.localWeekNumber,2);case"ii":return this.num(ne.localWeekYear.toString().slice(-2),2);case"iiii":return this.num(ne.localWeekYear,4);case"o":return this.num(ne.ordinal);case"ooo":return this.num(ne.ordinal,3);case"q":return this.num(ne.quarter);case"qq":return this.num(ne.quarter,2);case"X":return this.num(Math.floor(ne.ts/1e3));case"x":return this.num(ne.ts);default:return Ie(rn)}})}formatDurationFromString(ne,Pe){const rt=Ce=>{switch(Ce[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},Rn=ca.parseFormat(Pe),Kn=Rn.reduce((Ce,{literal:ue,val:Ie})=>ue?Ce:Ce.concat(Ie),[]);return ec(Rn,(Ce=>ue=>{const Ie=rt(ue);return Ie?this.num(Ce.get(Ie),ue.length):ue})(ne.shiftTo(...Kn.map(rt).filter(Ce=>Ce))))}}const Il=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Xa(...Ue){const ne=Ue.reduce((Pe,rt)=>Pe+rt.source,"");return RegExp(`^${ne}$`)}function Rl(...Ue){return ne=>Ue.reduce(([Pe,rt,Ut],Rn)=>{const[Kn,Y,Ce]=Rn(ne,Ut);return[{...Pe,...Kn},Y||rt,Ce]},[{},null,1]).slice(0,2)}function yl(Ue,...ne){if(null==Ue)return[null,null];for(const[Pe,rt]of ne){const Ut=Pe.exec(Ue);if(Ut)return rt(Ut)}return[null,null]}function sa(...Ue){return(ne,Pe)=>{const rt={};let Ut;for(Ut=0;Ut<Ue.length;Ut++)rt[Ue[Ut]]=cn(ne[Pe+Ut]);return[rt,null,Pe+Ut]}}const Lu=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,ku=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Ql=RegExp(`${ku.source}(?:${Lu.source}?(?:\\[(${Il.source})\\])?)?`),sc=RegExp(`(?:T${Ql.source})?`),Fc=sa("weekYear","weekNumber","weekDay"),po=sa("year","ordinal"),Hs=RegExp(`${ku.source} ?(?:${Lu.source}|(${Il.source}))?`),kl=RegExp(`(?: ${Hs.source})?`);function Nc(Ue,ne,Pe){const rt=Ue[ne];return Qr(rt)?Pe:cn(rt)}function Rc(Ue,ne){return[{hours:Nc(Ue,ne,0),minutes:Nc(Ue,ne+1,0),seconds:Nc(Ue,ne+2,0),milliseconds:Ri(Ue[ne+3])},null,ne+4]}function Ke(Ue,ne){const Pe=!Ue[ne]&&!Ue[ne+1],rt=Jo(Ue[ne+1],Ue[ne+2]);return[{},Pe?null:qn.instance(rt),ne+3]}function Se(Ue,ne){return[{},Ue[ne]?Zn.create(Ue[ne]):null,ne+1]}const re=RegExp(`^T?${ku.source}$`),Ge=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function xt(Ue){const[ne,Pe,rt,Ut,Rn,Kn,Y,Ce,ue]=Ue,Ie="-"===ne[0],Ze=Ce&&"-"===Ce[0],kt=(rn,Si=!1)=>void 0!==rn&&(Si||rn&&Ie)?-rn:rn;return[{years:kt(Tn(Pe)),months:kt(Tn(rt)),weeks:kt(Tn(Ut)),days:kt(Tn(Rn)),hours:kt(Tn(Kn)),minutes:kt(Tn(Y)),seconds:kt(Tn(Ce),"-0"===Ce),milliseconds:kt(Ri(ue),Ze)}]}const Qt={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function kn(Ue,ne,Pe,rt,Ut,Rn,Kn){const Y={year:2===ne.length?Mo(cn(ne)):cn(ne),month:ts.indexOf(Pe)+1,day:cn(rt),hour:cn(Ut),minute:cn(Rn)};return Kn&&(Y.second=cn(Kn)),Ue&&(Y.weekday=Ue.length>3?ga.indexOf(Ue)+1:sl.indexOf(Ue)+1),Y}const bi=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function vi(Ue){const[,ne,Pe,rt,Ut,Rn,Kn,Y,Ce,ue,Ie,Ze]=Ue,kt=kn(ne,Ut,rt,Pe,Rn,Kn,Y);let rn;return rn=Ce?Qt[Ce]:ue?0:Jo(Ie,Ze),[kt,new qn(rn)]}const Xi=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,$i=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Er=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function ai(Ue){const[,ne,Pe,rt,Ut,Rn,Kn,Y]=Ue;return[kn(ne,Ut,rt,Pe,Rn,Kn,Y),qn.utcInstance]}function so(Ue){const[,ne,Pe,rt,Ut,Rn,Kn,Y]=Ue;return[kn(ne,Y,Pe,rt,Ut,Rn,Kn),qn.utcInstance]}const Fr=Xa(/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,sc),zr=Xa(/(\d{4})-?W(\d\d)(?:-?(\d))?/,sc),ho=Xa(/(\d{4})-?(\d{3})/,sc),Vr=Xa(Ql),is=Rl(function fu(Ue,ne){return[{year:Nc(Ue,ne),month:Nc(Ue,ne+1,1),day:Nc(Ue,ne+2,1)},null,ne+3]},Rc,Ke,Se),Ms=Rl(Fc,Rc,Ke,Se),Ds=Rl(po,Rc,Ke,Se),Xo=Rl(Rc,Ke,Se),at=Rl(Rc),Ct=Xa(/(\d{4})-(\d\d)-(\d\d)/,kl),On=Xa(Hs),_i=Rl(Rc,Ke,Se),qi="Invalid Duration",Di={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},fo={years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6},...Di},Uo=365.2425,Gs=30.436875,ba={years:{quarters:4,months:12,weeks:Uo/7,days:Uo,hours:24*Uo,minutes:525949.2,seconds:525949.2*60,milliseconds:525949.2*60*1e3},quarters:{months:3,weeks:Uo/28,days:Uo/4,hours:24*Uo/4,minutes:131487.3,seconds:525949.2*60/4,milliseconds:7889237999.999999},months:{weeks:Gs/7,days:Gs,hours:24*Gs,minutes:43829.1,seconds:2629746,milliseconds:2629746e3},...Di},Za=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],Ks=Za.slice(0).reverse();function ac(Ue,ne,Pe=!1){const rt={values:Pe?ne.values:{...Ue.values,...ne.values||{}},loc:Ue.loc.clone(ne.loc),conversionAccuracy:ne.conversionAccuracy||Ue.conversionAccuracy,matrix:ne.matrix||Ue.matrix};return new da(rt)}function lc(Ue,ne){let Pe=ne.milliseconds??0;for(const rt of Ks.slice(1))ne[rt]&&(Pe+=ne[rt]*Ue[rt].milliseconds);return Pe}function ou(Ue,ne){const Pe=lc(Ue,ne)<0?-1:1;Za.reduceRight((rt,Ut)=>{if(Qr(ne[Ut]))return rt;if(rt){const Kn=Ue[Ut][rt],Y=Math.floor(ne[rt]*Pe/Kn);ne[Ut]+=Y*Pe,ne[rt]-=Y*Kn*Pe}return Ut},null),Za.reduce((rt,Ut)=>{if(Qr(ne[Ut]))return rt;if(rt){const Rn=ne[rt]%1;ne[rt]-=Rn,ne[Ut]+=Rn*Ue[rt][Ut]}return Ut},null)}class da{constructor(ne){const Pe="longterm"===ne.conversionAccuracy||!1;let rt=Pe?ba:fo;ne.matrix&&(rt=ne.matrix),this.values=ne.values,this.loc=ne.loc||Mn.create(),this.conversionAccuracy=Pe?"longterm":"casual",this.invalid=ne.invalid||null,this.matrix=rt,this.isLuxonDuration=!0}static fromMillis(ne,Pe){return da.fromObject({milliseconds:ne},Pe)}static fromObject(ne,Pe={}){if(null==ne||"object"!=typeof ne)throw new Ee("Duration.fromObject: argument expected to be an object, got "+(null===ne?"null":typeof ne));return new da({values:Js(ne,da.normalizeUnit),loc:Mn.fromObject(Pe),conversionAccuracy:Pe.conversionAccuracy,matrix:Pe.matrix})}static fromDurationLike(ne){if(dl(ne))return da.fromMillis(ne);if(da.isDuration(ne))return ne;if("object"==typeof ne)return da.fromObject(ne);throw new Ee(`Unknown duration argument ${ne} of type ${typeof ne}`)}static fromISO(ne,Pe){const[rt]=function Je(Ue){return yl(Ue,[Ge,xt])}(ne);return rt?da.fromObject(rt,Pe):da.invalid("unparsable",`the input "${ne}" can't be parsed as ISO 8601`)}static fromISOTime(ne,Pe){const[rt]=function Oe(Ue){return yl(Ue,[re,at])}(ne);return rt?da.fromObject(rt,Pe):da.invalid("unparsable",`the input "${ne}" can't be parsed as ISO 8601`)}static invalid(ne,Pe=null){if(!ne)throw new Ee("need to specify a reason the Duration is invalid");const rt=ne instanceof qr?ne:new qr(ne,Pe);if(_r.throwOnInvalid)throw new X(rt);return new da({invalid:rt})}static normalizeUnit(ne){const Pe={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[ne&&ne.toLowerCase()];if(!Pe)throw new Q(ne);return Pe}static isDuration(ne){return ne&&ne.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(ne,Pe={}){const rt={...Pe,floor:!1!==Pe.round&&!1!==Pe.floor};return this.isValid?ca.create(this.loc,rt).formatDurationFromString(this,ne):qi}toHuman(ne={}){if(!this.isValid)return qi;const Pe=Za.map(rt=>{const Ut=this.values[rt];return Qr(Ut)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...ne,unit:rt.slice(0,-1)}).format(Ut)}).filter(rt=>rt);return this.loc.listFormatter({type:"conjunction",style:ne.listStyle||"narrow",...ne}).format(Pe)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let ne="P";return 0!==this.years&&(ne+=this.years+"Y"),(0!==this.months||0!==this.quarters)&&(ne+=this.months+3*this.quarters+"M"),0!==this.weeks&&(ne+=this.weeks+"W"),0!==this.days&&(ne+=this.days+"D"),(0!==this.hours||0!==this.minutes||0!==this.seconds||0!==this.milliseconds)&&(ne+="T"),0!==this.hours&&(ne+=this.hours+"H"),0!==this.minutes&&(ne+=this.minutes+"M"),(0!==this.seconds||0!==this.milliseconds)&&(ne+=Un(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===ne&&(ne+="T0S"),ne}toISOTime(ne={}){if(!this.isValid)return null;const Pe=this.toMillis();return Pe<0||Pe>=864e5?null:(ne={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...ne,includeOffset:!1},$o.fromMillis(Pe,{zone:"UTC"}).toISOTime(ne))}toJSON(){return this.toISO()}toString(){return this.toISO()}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Duration { values: ${JSON.stringify(this.values)} }`:`Duration { Invalid, reason: ${this.invalidReason} }`}toMillis(){return this.isValid?lc(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(ne){if(!this.isValid)return this;const Pe=da.fromDurationLike(ne),rt={};for(const Ut of Za)(Ui(Pe.values,Ut)||Ui(this.values,Ut))&&(rt[Ut]=Pe.get(Ut)+this.get(Ut));return ac(this,{values:rt},!0)}minus(ne){if(!this.isValid)return this;const Pe=da.fromDurationLike(ne);return this.plus(Pe.negate())}mapUnits(ne){if(!this.isValid)return this;const Pe={};for(const rt of Object.keys(this.values))Pe[rt]=$s(ne(this.values[rt],rt));return ac(this,{values:Pe},!0)}get(ne){return this[da.normalizeUnit(ne)]}set(ne){return this.isValid?ac(this,{values:{...this.values,...Js(ne,da.normalizeUnit)}}):this}reconfigure({locale:ne,numberingSystem:Pe,conversionAccuracy:rt,matrix:Ut}={}){return ac(this,{loc:this.loc.clone({locale:ne,numberingSystem:Pe}),matrix:Ut,conversionAccuracy:rt})}as(ne){return this.isValid?this.shiftTo(ne).get(ne):NaN}normalize(){if(!this.isValid)return this;const ne=this.toObject();return ou(this.matrix,ne),ac(this,{values:ne},!0)}rescale(){return this.isValid?ac(this,{values:function qd(Ue){const ne={};for(const[Pe,rt]of Object.entries(Ue))0!==rt&&(ne[Pe]=rt);return ne}(this.normalize().shiftToAll().toObject())},!0):this}shiftTo(...ne){if(!this.isValid)return this;if(0===ne.length)return this;ne=ne.map(Kn=>da.normalizeUnit(Kn));const Pe={},rt={},Ut=this.toObject();let Rn;for(const Kn of Za)if(ne.indexOf(Kn)>=0){Rn=Kn;let Y=0;for(const ue in rt)Y+=this.matrix[ue][Kn]*rt[ue],rt[ue]=0;dl(Ut[Kn])&&(Y+=Ut[Kn]);const Ce=Math.trunc(Y);Pe[Kn]=Ce,rt[Kn]=(1e3*Y-1e3*Ce)/1e3}else dl(Ut[Kn])&&(rt[Kn]=Ut[Kn]);for(const Kn in rt)0!==rt[Kn]&&(Pe[Rn]+=Kn===Rn?rt[Kn]:rt[Kn]/this.matrix[Rn][Kn]);return ou(this.matrix,Pe),ac(this,{values:Pe},!0)}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const ne={};for(const Pe of Object.keys(this.values))ne[Pe]=0===this.values[Pe]?0:-this.values[Pe];return ac(this,{values:ne},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(ne){if(!this.isValid||!ne.isValid||!this.loc.equals(ne.loc))return!1;function Pe(rt,Ut){return void 0===rt||0===rt?void 0===Ut||0===Ut:rt===Ut}for(const rt of Za)if(!Pe(this.values[rt],ne.values[rt]))return!1;return!0}}const nd="Invalid Interval";class bl{constructor(ne){this.s=ne.start,this.e=ne.end,this.invalid=ne.invalid||null,this.isLuxonInterval=!0}static invalid(ne,Pe=null){if(!ne)throw new Ee("need to specify a reason the Interval is invalid");const rt=ne instanceof qr?ne:new qr(ne,Pe);if(_r.throwOnInvalid)throw new M(rt);return new bl({invalid:rt})}static fromDateTimes(ne,Pe){const rt=Mc(ne),Ut=Mc(Pe),Rn=function xp(Ue,ne){return Ue&&Ue.isValid?ne&&ne.isValid?ne<Ue?bl.invalid("end before start",`The end of an interval must be after its start, but you had start=${Ue.toISO()} and end=${ne.toISO()}`):null:bl.invalid("missing or invalid end"):bl.invalid("missing or invalid start")}(rt,Ut);return Rn??new bl({start:rt,end:Ut})}static after(ne,Pe){const rt=da.fromDurationLike(Pe),Ut=Mc(ne);return bl.fromDateTimes(Ut,Ut.plus(rt))}static before(ne,Pe){const rt=da.fromDurationLike(Pe),Ut=Mc(ne);return bl.fromDateTimes(Ut.minus(rt),Ut)}static fromISO(ne,Pe){const[rt,Ut]=(ne||"").split("/",2);if(rt&&Ut){let Rn,Kn,Y,Ce;try{Rn=$o.fromISO(rt,Pe),Kn=Rn.isValid}catch{Kn=!1}try{Y=$o.fromISO(Ut,Pe),Ce=Y.isValid}catch{Ce=!1}if(Kn&&Ce)return bl.fromDateTimes(Rn,Y);if(Kn){const ue=da.fromISO(Ut,Pe);if(ue.isValid)return bl.after(Rn,ue)}else if(Ce){const ue=da.fromISO(rt,Pe);if(ue.isValid)return bl.before(Y,ue)}}return bl.invalid("unparsable",`the input "${ne}" can't be parsed as ISO 8601`)}static isInterval(ne){return ne&&ne.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return null===this.invalidReason}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(ne="milliseconds"){return this.isValid?this.toDuration(ne).get(ne):NaN}count(ne="milliseconds",Pe){if(!this.isValid)return NaN;const rt=this.start.startOf(ne,Pe);let Ut;return Ut=Pe?.useLocaleWeeks?this.end.reconfigure({locale:rt.locale}):this.end,Ut=Ut.startOf(ne,Pe),Math.floor(Ut.diff(rt,ne).get(ne))+(Ut.valueOf()!==this.end.valueOf())}hasSame(ne){return!!this.isValid&&(this.isEmpty()||this.e.minus(1).hasSame(this.s,ne))}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(ne){return!!this.isValid&&this.s>ne}isBefore(ne){return!!this.isValid&&this.e<=ne}contains(ne){return!!this.isValid&&this.s<=ne&&this.e>ne}set({start:ne,end:Pe}={}){return this.isValid?bl.fromDateTimes(ne||this.s,Pe||this.e):this}splitAt(...ne){if(!this.isValid)return[];const Pe=ne.map(Mc).filter(Kn=>this.contains(Kn)).sort((Kn,Y)=>Kn.toMillis()-Y.toMillis()),rt=[];let{s:Ut}=this,Rn=0;for(;Ut<this.e;){const Kn=Pe[Rn]||this.e,Y=+Kn>+this.e?this.e:Kn;rt.push(bl.fromDateTimes(Ut,Y)),Ut=Y,Rn+=1}return rt}splitBy(ne){const Pe=da.fromDurationLike(ne);if(!this.isValid||!Pe.isValid||0===Pe.as("milliseconds"))return[];let Rn,{s:rt}=this,Ut=1;const Kn=[];for(;rt<this.e;){const Y=this.start.plus(Pe.mapUnits(Ce=>Ce*Ut));Rn=+Y>+this.e?this.e:Y,Kn.push(bl.fromDateTimes(rt,Rn)),rt=Rn,Ut+=1}return Kn}divideEqually(ne){return this.isValid?this.splitBy(this.length()/ne).slice(0,ne):[]}overlaps(ne){return this.e>ne.s&&this.s<ne.e}abutsStart(ne){return!!this.isValid&&+this.e==+ne.s}abutsEnd(ne){return!!this.isValid&&+ne.e==+this.s}engulfs(ne){return!!this.isValid&&this.s<=ne.s&&this.e>=ne.e}equals(ne){return!(!this.isValid||!ne.isValid)&&this.s.equals(ne.s)&&this.e.equals(ne.e)}intersection(ne){if(!this.isValid)return this;const Pe=this.s>ne.s?this.s:ne.s,rt=this.e<ne.e?this.e:ne.e;return Pe>=rt?null:bl.fromDateTimes(Pe,rt)}union(ne){return this.isValid?bl.fromDateTimes(this.s<ne.s?this.s:ne.s,this.e>ne.e?this.e:ne.e):this}static merge(ne){const[Pe,rt]=ne.sort((Ut,Rn)=>Ut.s-Rn.s).reduce(([Ut,Rn],Kn)=>Rn?Rn.overlaps(Kn)||Rn.abutsStart(Kn)?[Ut,Rn.union(Kn)]:[Ut.concat([Rn]),Kn]:[Ut,Kn],[[],null]);return rt&&Pe.push(rt),Pe}static xor(ne){let Pe=null,rt=0;const Ut=[],Rn=ne.map(Ce=>[{time:Ce.s,type:"s"},{time:Ce.e,type:"e"}]),Y=Array.prototype.concat(...Rn).sort((Ce,ue)=>Ce.time-ue.time);for(const Ce of Y)rt+="s"===Ce.type?1:-1,1===rt?Pe=Ce.time:(Pe&&+Pe!=+Ce.time&&Ut.push(bl.fromDateTimes(Pe,Ce.time)),Pe=null);return bl.merge(Ut)}difference(...ne){return bl.xor([this].concat(ne)).map(Pe=>this.intersection(Pe)).filter(Pe=>Pe&&!Pe.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:nd}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Interval { start: ${this.s.toISO()}, end: ${this.e.toISO()} }`:`Interval { Invalid, reason: ${this.invalidReason} }`}toLocaleString(ne=ce,Pe={}){return this.isValid?ca.create(this.s.loc.clone(Pe),ne).formatInterval(this):nd}toISO(ne){return this.isValid?`${this.s.toISO(ne)}/${this.e.toISO(ne)}`:nd}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:nd}toISOTime(ne){return this.isValid?`${this.s.toISOTime(ne)}/${this.e.toISOTime(ne)}`:nd}toFormat(ne,{separator:Pe=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(ne)}${Pe}${this.e.toFormat(ne)}`:nd}toDuration(ne,Pe){return this.isValid?this.e.diff(this.s,ne,Pe):da.invalid(this.invalidReason)}mapEndpoints(ne){return bl.fromDateTimes(ne(this.s),ne(this.e))}}class _c{static hasDST(ne=_r.defaultZone){const Pe=$o.now().setZone(ne).set({month:12});return!ne.isUniversal&&Pe.offset!==Pe.set({month:6}).offset}static isValidIANAZone(ne){return Zn.isValidZone(ne)}static normalizeZone(ne){return Bi(ne,_r.defaultZone)}static getStartOfWeek({locale:ne=null,locObj:Pe=null}={}){return(Pe||Mn.create(ne)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:ne=null,locObj:Pe=null}={}){return(Pe||Mn.create(ne)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:ne=null,locObj:Pe=null}={}){return(Pe||Mn.create(ne)).getWeekendDays().slice()}static months(ne="long",{locale:Pe=null,numberingSystem:rt=null,locObj:Ut=null,outputCalendar:Rn="gregory"}={}){return(Ut||Mn.create(Pe,rt,Rn)).months(ne)}static monthsFormat(ne="long",{locale:Pe=null,numberingSystem:rt=null,locObj:Ut=null,outputCalendar:Rn="gregory"}={}){return(Ut||Mn.create(Pe,rt,Rn)).months(ne,!0)}static weekdays(ne="long",{locale:Pe=null,numberingSystem:rt=null,locObj:Ut=null}={}){return(Ut||Mn.create(Pe,rt,null)).weekdays(ne)}static weekdaysFormat(ne="long",{locale:Pe=null,numberingSystem:rt=null,locObj:Ut=null}={}){return(Ut||Mn.create(Pe,rt,null)).weekdays(ne,!0)}static meridiems({locale:ne=null}={}){return Mn.create(ne).meridiems()}static eras(ne="short",{locale:Pe=null}={}){return Mn.create(Pe,null,"gregory").eras(ne)}static features(){return{relative:jt(),localeWeek:In()}}}function cc(Ue,ne){const Pe=Ut=>Ut.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),rt=Pe(ne)-Pe(Ue);return Math.floor(da.fromMillis(rt).as("days"))}function Ra(Ue,ne=Pe=>Pe){return{regex:Ue,deser:([Pe])=>ne(function Jt(Ue){let ne=parseInt(Ue,10);if(isNaN(ne)){ne="";for(let Pe=0;Pe<Ue.length;Pe++){const rt=Ue.charCodeAt(Pe);if(-1!==Ue[Pe].search(Gi.hanidec))ne+=Ki.indexOf(Ue[Pe]);else for(const Ut in Ii){const[Rn,Kn]=Ii[Ut];rt>=Rn&&rt<=Kn&&(ne+=rt-Rn)}}return parseInt(ne,10)}return ne}(Pe))}}const ff="[ \xa0]",Yt=new RegExp(ff,"g");function tc(Ue){return Ue.replace(/\./g,"\\.?").replace(Yt,ff)}function Qh(Ue){return Ue.replace(/\./g,"").replace(Yt," ").toLowerCase()}function Su(Ue,ne){return null===Ue?null:{regex:RegExp(Ue.map(tc).join("|")),deser:([Pe])=>Ue.findIndex(rt=>Qh(Pe)===Qh(rt))+ne}}function md(Ue,ne){return{regex:Ue,deser:([,Pe,rt])=>Jo(Pe,rt),groups:ne}}function Ld(Ue){return{regex:Ue,deser:([ne])=>ne}}function gd(Ue){return Ue.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}const Pu={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour12:{numeric:"h","2-digit":"hh"},hour24:{numeric:"H","2-digit":"HH"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};let su=null;function vd(Ue,ne){return Array.prototype.concat(...Ue.map(Pe=>function xa(Ue,ne){if(Ue.literal)return Ue;const rt=pu(ca.macroTokenToFormatOpts(Ue.val),ne);return null==rt||rt.includes(void 0)?Ue:rt}(Pe,ne)))}class Vu{constructor(ne,Pe){if(this.locale=ne,this.format=Pe,this.tokens=vd(ca.parseFormat(Pe),ne),this.units=this.tokens.map(rt=>function Eu(Ue,ne){const Pe=it(ne),rt=it(ne,"{2}"),Ut=it(ne,"{3}"),Rn=it(ne,"{4}"),Kn=it(ne,"{6}"),Y=it(ne,"{1,2}"),Ce=it(ne,"{1,3}"),ue=it(ne,"{1,6}"),Ie=it(ne,"{1,9}"),Ze=it(ne,"{2,4}"),kt=it(ne,"{4,6}"),rn=Yr=>({regex:RegExp(gd(Yr.val)),deser:([rs])=>rs,literal:!0}),oi=(Yr=>{if(Ue.literal)return rn(Yr);switch(Yr.val){case"G":return Su(ne.eras("short"),0);case"GG":return Su(ne.eras("long"),0);case"y":return Ra(ue);case"yy":case"kk":return Ra(Ze,Mo);case"yyyy":case"kkkk":return Ra(Rn);case"yyyyy":return Ra(kt);case"yyyyyy":return Ra(Kn);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return Ra(Y);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return Ra(rt);case"MMM":return Su(ne.months("short",!0),1);case"MMMM":return Su(ne.months("long",!0),1);case"LLL":return Su(ne.months("short",!1),1);case"LLLL":return Su(ne.months("long",!1),1);case"o":case"S":return Ra(Ce);case"ooo":case"SSS":return Ra(Ut);case"u":return Ld(Ie);case"uu":return Ld(Y);case"uuu":case"E":case"c":return Ra(Pe);case"a":return Su(ne.meridiems(),0);case"EEE":return Su(ne.weekdays("short",!1),1);case"EEEE":return Su(ne.weekdays("long",!1),1);case"ccc":return Su(ne.weekdays("short",!0),1);case"cccc":return Su(ne.weekdays("long",!0),1);case"Z":case"ZZ":return md(new RegExp(`([+-]${Y.source})(?::(${rt.source}))?`),2);case"ZZZ":return md(new RegExp(`([+-]${Y.source})(${rt.source})?`),2);case"z":return Ld(/[a-z_+-/]{1,256}?/i);case" ":return Ld(/[^\S\n\r]/);default:return rn(Yr)}})(Ue)||{invalidReason:"missing Intl.DateTimeFormat.formatToParts support"};return oi.token=Ue,oi}(rt,ne)),this.disqualifyingUnit=this.units.find(rt=>rt.invalidReason),!this.disqualifyingUnit){const[rt,Ut]=function qs(Ue){return[`^${Ue.map(Pe=>Pe.regex).reduce((Pe,rt)=>`${Pe}(${rt.source})`,"")}$`,Ue]}(this.units);this.regex=RegExp(rt,"i"),this.handlers=Ut}}explainFromTokens(ne){if(this.isValid){const[Pe,rt]=function Xc(Ue,ne,Pe){const rt=Ue.match(ne);if(rt){const Ut={};let Rn=1;for(const Kn in Pe)if(Ui(Pe,Kn)){const Y=Pe[Kn],Ce=Y.groups?Y.groups+1:1;!Y.literal&&Y.token&&(Ut[Y.token.val[0]]=Y.deser(rt.slice(Rn,Rn+Ce))),Rn+=Ce}return[rt,Ut]}return[rt,{}]}(ne,this.regex,this.handlers),[Ut,Rn,Kn]=rt?function Bu(Ue){let rt,Pe=null;return Qr(Ue.z)||(Pe=Zn.create(Ue.z)),Qr(Ue.Z)||(Pe||(Pe=new qn(Ue.Z)),rt=Ue.Z),Qr(Ue.q)||(Ue.M=3*(Ue.q-1)+1),Qr(Ue.h)||(Ue.h<12&&1===Ue.a?Ue.h+=12:12===Ue.h&&0===Ue.a&&(Ue.h=0)),0===Ue.G&&Ue.y&&(Ue.y=-Ue.y),Qr(Ue.u)||(Ue.S=Ri(Ue.u)),[Object.keys(Ue).reduce((Rn,Kn)=>{const Y=(Rn=>{switch(Rn){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}})(Kn);return Y&&(Rn[Y]=Ue[Kn]),Rn},{}),Pe,rt]}(rt):[null,null,void 0];if(Ui(rt,"a")&&Ui(rt,"H"))throw new ie("Can't include meridiem when specifying 24-hour format");return{input:ne,tokens:this.tokens,regex:this.regex,rawMatches:Pe,matches:rt,result:Ut,zone:Rn,specificOffset:Kn}}return{input:ne,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}}function id(Ue,ne,Pe){return new Vu(Ue,Pe).explainFromTokens(ne)}function pu(Ue,ne){if(!Ue)return null;const rt=ca.create(ne,Ue).dtFormatter(function Is(){return su||(su=$o.fromMillis(1555555555555)),su}()),Ut=rt.formatToParts(),Rn=rt.resolvedOptions();return Ut.map(Kn=>function Lc(Ue,ne,Pe){const{type:rt,value:Ut}=Ue;if("literal"===rt){const Ce=/^\s+$/.test(Ut);return{literal:!Ce,val:Ce?" ":Ut}}let Kn=rt;"hour"===rt&&(Kn=null!=ne.hour12?ne.hour12?"hour12":"hour24":null!=ne.hourCycle?"h11"===ne.hourCycle||"h12"===ne.hourCycle?"hour12":"hour24":Pe.hour12?"hour12":"hour24");let Y=Pu[Kn];if("object"==typeof Y&&(Y=Y[ne[rt]]),Y)return{literal:!1,val:Y}}(Kn,Ue,Rn))}const hu="Invalid DateTime",As=864e13;function Ed(Ue){return new qr("unsupported zone",`the zone "${Ue.name}" is not supported`)}function kc(Ue){return null===Ue.weekData&&(Ue.weekData=za(Ue.c)),Ue.weekData}function El(Ue){return null===Ue.localWeekData&&(Ue.localWeekData=za(Ue.c,Ue.loc.getMinDaysInFirstWeek(),Ue.loc.getStartOfWeek())),Ue.localWeekData}function uc(Ue,ne){const Pe={ts:Ue.ts,zone:Ue.zone,c:Ue.c,o:Ue.o,loc:Ue.loc,invalid:Ue.invalid};return new $o({...Pe,...ne,old:Pe})}function kd(Ue,ne,Pe){let rt=Ue-60*ne*1e3;const Ut=Pe.offset(rt);if(ne===Ut)return[rt,ne];rt-=60*(Ut-ne)*1e3;const Rn=Pe.offset(rt);return Ut===Rn?[rt,Ut]:[Ue-60*Math.min(Ut,Rn)*1e3,Math.max(Ut,Rn)]}function Td(Ue,ne){const Pe=new Date(Ue+=60*ne*1e3);return{year:Pe.getUTCFullYear(),month:Pe.getUTCMonth()+1,day:Pe.getUTCDate(),hour:Pe.getUTCHours(),minute:Pe.getUTCMinutes(),second:Pe.getUTCSeconds(),millisecond:Pe.getUTCMilliseconds()}}function Pc(Ue,ne,Pe){return kd(Li(Ue),ne,Pe)}function ju(Ue,ne){const Pe=Ue.o,rt=Ue.c.year+Math.trunc(ne.years),Ut=Ue.c.month+Math.trunc(ne.months)+3*Math.trunc(ne.quarters),Rn={...Ue.c,year:rt,month:Ut,day:Math.min(Ue.c.day,fr(rt,Ut))+Math.trunc(ne.days)+7*Math.trunc(ne.weeks)},Kn=da.fromObject({years:ne.years-Math.trunc(ne.years),quarters:ne.quarters-Math.trunc(ne.quarters),months:ne.months-Math.trunc(ne.months),weeks:ne.weeks-Math.trunc(ne.weeks),days:ne.days-Math.trunc(ne.days),hours:ne.hours,minutes:ne.minutes,seconds:ne.seconds,milliseconds:ne.milliseconds}).as("milliseconds"),Y=Li(Rn);let[Ce,ue]=kd(Y,Pe,Ue.zone);return 0!==Kn&&(Ce+=Kn,ue=Ue.zone.offset(Ce)),{ts:Ce,o:ue}}function Yl(Ue,ne,Pe,rt,Ut,Rn){const{setZone:Kn,zone:Y}=Pe;if(Ue&&0!==Object.keys(Ue).length||ne){const Ce=ne||Y,ue=$o.fromObject(Ue,{...Pe,zone:Ce,specificOffset:Rn});return Kn?ue:ue.setZone(Y)}return $o.invalid(new qr("unparsable",`the input "${Ut}" can't be parsed as ${rt}`))}function Bc(Ue,ne,Pe=!0){return Ue.isValid?ca.create(Mn.create("en-US"),{allowZ:Pe,forceSimple:!0}).formatDateTimeFromString(Ue,ne):null}function pf(Ue,ne){const Pe=Ue.c.year>9999||Ue.c.year<0;let rt="";return Pe&&Ue.c.year>=0&&(rt+="+"),rt+=Tt(Ue.c.year,Pe?6:4),ne?(rt+="-",rt+=Tt(Ue.c.month),rt+="-",rt+=Tt(Ue.c.day)):(rt+=Tt(Ue.c.month),rt+=Tt(Ue.c.day)),rt}function hf(Ue,ne,Pe,rt,Ut,Rn){let Kn=Tt(Ue.c.hour);return ne?(Kn+=":",Kn+=Tt(Ue.c.minute),(0!==Ue.c.millisecond||0!==Ue.c.second||!Pe)&&(Kn+=":")):Kn+=Tt(Ue.c.minute),(0!==Ue.c.millisecond||0!==Ue.c.second||!Pe)&&(Kn+=Tt(Ue.c.second),(0!==Ue.c.millisecond||!rt)&&(Kn+=".",Kn+=Tt(Ue.c.millisecond,3))),Ut&&(Ue.isOffsetFixed&&0===Ue.offset&&!Rn?Kn+="Z":Ue.o<0?(Kn+="-",Kn+=Tt(Math.trunc(-Ue.o/60)),Kn+=":",Kn+=Tt(Math.trunc(-Ue.o%60))):(Kn+="+",Kn+=Tt(Math.trunc(Ue.o/60)),Kn+=":",Kn+=Tt(Math.trunc(Ue.o%60)))),Rn&&(Kn+="["+Ue.zone.ianaName+"]"),Kn}const _e={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},Dt={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},Re={ordinal:1,hour:0,minute:0,second:0,millisecond:0},tt=["year","month","day","hour","minute","second","millisecond"],mn=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],gi=["year","ordinal","hour","minute","second","millisecond"];function or(Ue){switch(Ue.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return function rr(Ue){const ne={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[Ue.toLowerCase()];if(!ne)throw new Q(Ue);return ne}(Ue)}}function La(Ue,ne){const Pe=Bi(ne.zone,_r.defaultZone);if(!Pe.isValid)return $o.invalid(Ed(Pe));const rt=Mn.fromObject(ne);let Ut,Rn;if(Qr(Ue.year))Ut=_r.now();else{for(const Ce of tt)Qr(Ue[Ce])&&(Ue[Ce]=_e[Ce]);const Kn=no(Ue)||xl(Ue);if(Kn)return $o.invalid(Kn);const Y=function ia(Ue){return Sa[Ue]||(void 0===ll&&(ll=_r.now()),Sa[Ue]=Ue.offset(ll)),Sa[Ue]}(Pe);[Ut,Rn]=Pc(Ue,Y,Pe)}return new $o({ts:Ut,zone:Pe,loc:rt,o:Rn})}function vs(Ue,ne,Pe){const rt=!!Qr(Pe.round)||Pe.round,Ut=(Kn,Y)=>(Kn=Un(Kn,rt||Pe.calendary?0:2,!0),ne.loc.clone(Pe).relFormatter(Pe).format(Kn,Y)),Rn=Kn=>Pe.calendary?ne.hasSame(Ue,Kn)?0:ne.startOf(Kn).diff(Ue.startOf(Kn),Kn).get(Kn):ne.diff(Ue,Kn).get(Kn);if(Pe.unit)return Ut(Rn(Pe.unit),Pe.unit);for(const Kn of Pe.units){const Y=Rn(Kn);if(Math.abs(Y)>=1)return Ut(Y,Kn)}return Ut(Ue>ne?-0:0,Pe.units[Pe.units.length-1])}function Qo(Ue){let Pe,ne={};return Ue.length>0&&"object"==typeof Ue[Ue.length-1]?(ne=Ue[Ue.length-1],Pe=Array.from(Ue).slice(0,Ue.length-1)):Pe=Array.from(Ue),[ne,Pe]}let ll,Sa={};class $o{constructor(ne){const Pe=ne.zone||_r.defaultZone;let rt=ne.invalid||(Number.isNaN(ne.ts)?new qr("invalid input"):null)||(Pe.isValid?null:Ed(Pe));this.ts=Qr(ne.ts)?_r.now():ne.ts;let Ut=null,Rn=null;if(!rt)if(ne.old&&ne.old.ts===this.ts&&ne.old.zone.equals(Pe))[Ut,Rn]=[ne.old.c,ne.old.o];else{const Y=dl(ne.o)&&!ne.old?ne.o:Pe.offset(this.ts);Ut=Td(this.ts,Y),rt=Number.isNaN(Ut.year)?new qr("invalid input"):null,Ut=rt?null:Ut,Rn=rt?null:Y}this._zone=Pe,this.loc=ne.loc||Mn.create(),this.invalid=rt,this.weekData=null,this.localWeekData=null,this.c=Ut,this.o=Rn,this.isLuxonDateTime=!0}static now(){return new $o({})}static local(){const[ne,Pe]=Qo(arguments),[rt,Ut,Rn,Kn,Y,Ce,ue]=Pe;return La({year:rt,month:Ut,day:Rn,hour:Kn,minute:Y,second:Ce,millisecond:ue},ne)}static utc(){const[ne,Pe]=Qo(arguments),[rt,Ut,Rn,Kn,Y,Ce,ue]=Pe;return ne.zone=qn.utcInstance,La({year:rt,month:Ut,day:Rn,hour:Kn,minute:Y,second:Ce,millisecond:ue},ne)}static fromJSDate(ne,Pe={}){const rt=function ko(Ue){return"[object Date]"===Object.prototype.toString.call(Ue)}(ne)?ne.valueOf():NaN;if(Number.isNaN(rt))return $o.invalid("invalid input");const Ut=Bi(Pe.zone,_r.defaultZone);return Ut.isValid?new $o({ts:rt,zone:Ut,loc:Mn.fromObject(Pe)}):$o.invalid(Ed(Ut))}static fromMillis(ne,Pe={}){if(dl(ne))return ne<-As||ne>As?$o.invalid("Timestamp out of range"):new $o({ts:ne,zone:Bi(Pe.zone,_r.defaultZone),loc:Mn.fromObject(Pe)});throw new Ee(`fromMillis requires a numerical input, but received a ${typeof ne} with value ${ne}`)}static fromSeconds(ne,Pe={}){if(dl(ne))return new $o({ts:1e3*ne,zone:Bi(Pe.zone,_r.defaultZone),loc:Mn.fromObject(Pe)});throw new Ee("fromSeconds requires a numerical input")}static fromObject(ne,Pe={}){ne=ne||{};const rt=Bi(Pe.zone,_r.defaultZone);if(!rt.isValid)return $o.invalid(Ed(rt));const Ut=Mn.fromObject(Pe),Rn=Js(ne,or),{minDaysInFirstWeek:Kn,startOfWeek:Y}=gs(Rn,Ut),Ce=_r.now(),ue=Qr(Pe.specificOffset)?rt.offset(Ce):Pe.specificOffset,Ie=!Qr(Rn.ordinal),Ze=!Qr(Rn.year),kt=!Qr(Rn.month)||!Qr(Rn.day),rn=Ze||kt,Si=Rn.weekYear||Rn.weekNumber;if((rn||Ie)&&Si)throw new ie("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(kt&&Ie)throw new ie("Can't mix ordinal dates with month/day");const oi=Si||Rn.weekday&&!rn;let Yr,rs,ls=Td(Ce,ue);oi?(Yr=mn,rs=Dt,ls=za(ls,Kn,Y)):Ie?(Yr=gi,rs=Re,ls=Na(ls)):(Yr=tt,rs=_e);let Zo=!1;for(const ro of Yr)Qr(Rn[ro])?Rn[ro]=Zo?rs[ro]:ls[ro]:Zo=!0;const Hl=oi?function Zs(Ue,ne=4,Pe=1){const rt=Ya(Ue.weekYear),Ut=er(Ue.weekNumber,1,vr(Ue.weekYear,ne,Pe)),Rn=er(Ue.weekday,1,7);return rt?Ut?!Rn&&Ro("weekday",Ue.weekday):Ro("week",Ue.weekNumber):Ro("weekYear",Ue.weekYear)}(Rn,Kn,Y):Ie?function oa(Ue){const ne=Ya(Ue.year),Pe=er(Ue.ordinal,1,Wi(Ue.year));return ne?!Pe&&Ro("ordinal",Ue.ordinal):Ro("year",Ue.year)}(Rn):no(Rn),dc=Hl||xl(Rn);if(dc)return $o.invalid(dc);const ws=oi?vl(Rn,Kn,Y):Ie?_l(Rn):Rn,[Vc,Wo]=Pc(ws,ue,rt),sr=new $o({ts:Vc,zone:rt,o:Wo,loc:Ut});return Rn.weekday&&rn&&ne.weekday!==sr.weekday?$o.invalid("mismatched weekday",`you can't specify both a weekday of ${Rn.weekday} and a date of ${sr.toISO()}`):sr.isValid?sr:$o.invalid(sr.invalid)}static fromISO(ne,Pe={}){const[rt,Ut]=function na(Ue){return yl(Ue,[Fr,is],[zr,Ms],[ho,Ds],[Vr,Xo])}(ne);return Yl(rt,Ut,Pe,"ISO 8601",ne)}static fromRFC2822(ne,Pe={}){const[rt,Ut]=function zs(Ue){return yl(function Ci(Ue){return Ue.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(Ue),[bi,vi])}(ne);return Yl(rt,Ut,Pe,"RFC 2822",ne)}static fromHTTP(ne,Pe={}){const[rt,Ut]=function ya(Ue){return yl(Ue,[Xi,ai],[$i,ai],[Er,so])}(ne);return Yl(rt,Ut,Pe,"HTTP",Pe)}static fromFormat(ne,Pe,rt={}){if(Qr(ne)||Qr(Pe))throw new Ee("fromFormat requires an input string and a format");const{locale:Ut=null,numberingSystem:Rn=null}=rt,Kn=Mn.fromOpts({locale:Ut,numberingSystem:Rn,defaultToEN:!0}),[Y,Ce,ue,Ie]=function Sd(Ue,ne,Pe){const{result:rt,zone:Ut,specificOffset:Rn,invalidReason:Kn}=id(Ue,ne,Pe);return[rt,Ut,Rn,Kn]}(Kn,ne,Pe);return Ie?$o.invalid(Ie):Yl(Y,Ce,rt,`format ${Pe}`,ne,ue)}static fromString(ne,Pe,rt={}){return $o.fromFormat(ne,Pe,rt)}static fromSQL(ne,Pe={}){const[rt,Ut]=function Qn(Ue){return yl(Ue,[Ct,is],[On,_i])}(ne);return Yl(rt,Ut,Pe,"SQL",ne)}static invalid(ne,Pe=null){if(!ne)throw new Ee("need to specify a reason the DateTime is invalid");const rt=ne instanceof qr?ne:new qr(ne,Pe);if(_r.throwOnInvalid)throw new e(rt);return new $o({invalid:rt})}static isDateTime(ne){return ne&&ne.isLuxonDateTime||!1}static parseFormatForOpts(ne,Pe={}){const rt=pu(ne,Mn.fromObject(Pe));return rt?rt.map(Ut=>Ut?Ut.val:null).join(""):null}static expandFormat(ne,Pe={}){return vd(ca.parseFormat(ne),Mn.fromObject(Pe)).map(Ut=>Ut.val).join("")}static resetCache(){ll=void 0,Sa={}}get(ne){return this[ne]}get isValid(){return null===this.invalid}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?kc(this).weekYear:NaN}get weekNumber(){return this.isValid?kc(this).weekNumber:NaN}get weekday(){return this.isValid?kc(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?El(this).weekday:NaN}get localWeekNumber(){return this.isValid?El(this).weekNumber:NaN}get localWeekYear(){return this.isValid?El(this).weekYear:NaN}get ordinal(){return this.isValid?Na(this.c).ordinal:NaN}get monthShort(){return this.isValid?_c.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?_c.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?_c.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?_c.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}getPossibleOffsets(){if(!this.isValid||this.isOffsetFixed)return[this];const Pe=6e4,rt=Li(this.c),Ut=this.zone.offset(rt-864e5),Rn=this.zone.offset(rt+864e5),Kn=this.zone.offset(rt-Ut*Pe),Y=this.zone.offset(rt-Rn*Pe);if(Kn===Y)return[this];const Ce=rt-Kn*Pe,ue=rt-Y*Pe,Ie=Td(Ce,Kn),Ze=Td(ue,Y);return Ie.hour===Ze.hour&&Ie.minute===Ze.minute&&Ie.second===Ze.second&&Ie.millisecond===Ze.millisecond?[uc(this,{ts:Ce}),uc(this,{ts:ue})]:[this]}get isInLeapYear(){return Yi(this.year)}get daysInMonth(){return fr(this.year,this.month)}get daysInYear(){return this.isValid?Wi(this.year):NaN}get weeksInWeekYear(){return this.isValid?vr(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?vr(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(ne={}){const{locale:Pe,numberingSystem:rt,calendar:Ut}=ca.create(this.loc.clone(ne),ne).resolvedOptions(this);return{locale:Pe,numberingSystem:rt,outputCalendar:Ut}}toUTC(ne=0,Pe={}){return this.setZone(qn.instance(ne),Pe)}toLocal(){return this.setZone(_r.defaultZone)}setZone(ne,{keepLocalTime:Pe=!1,keepCalendarTime:rt=!1}={}){if((ne=Bi(ne,_r.defaultZone)).equals(this.zone))return this;if(ne.isValid){let Ut=this.ts;if(Pe||rt){const Rn=ne.offset(this.ts),Kn=this.toObject();[Ut]=Pc(Kn,Rn,ne)}return uc(this,{ts:Ut,zone:ne})}return $o.invalid(Ed(ne))}reconfigure({locale:ne,numberingSystem:Pe,outputCalendar:rt}={}){return uc(this,{loc:this.loc.clone({locale:ne,numberingSystem:Pe,outputCalendar:rt})})}setLocale(ne){return this.reconfigure({locale:ne})}set(ne){if(!this.isValid)return this;const Pe=Js(ne,or),{minDaysInFirstWeek:rt,startOfWeek:Ut}=gs(Pe,this.loc),Rn=!Qr(Pe.weekYear)||!Qr(Pe.weekNumber)||!Qr(Pe.weekday),Kn=!Qr(Pe.ordinal),Y=!Qr(Pe.year),Ce=!Qr(Pe.month)||!Qr(Pe.day);if((Y||Ce||Kn)&&(Pe.weekYear||Pe.weekNumber))throw new ie("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(Ce&&Kn)throw new ie("Can't mix ordinal dates with month/day");let Ze;Rn?Ze=vl({...za(this.c,rt,Ut),...Pe},rt,Ut):Qr(Pe.ordinal)?(Ze={...this.toObject(),...Pe},Qr(Pe.day)&&(Ze.day=Math.min(fr(Ze.year,Ze.month),Ze.day))):Ze=_l({...Na(this.c),...Pe});const[kt,rn]=Pc(Ze,this.o,this.zone);return uc(this,{ts:kt,o:rn})}plus(ne){return this.isValid?uc(this,ju(this,da.fromDurationLike(ne))):this}minus(ne){return this.isValid?uc(this,ju(this,da.fromDurationLike(ne).negate())):this}startOf(ne,{useLocaleWeeks:Pe=!1}={}){if(!this.isValid)return this;const rt={},Ut=da.normalizeUnit(ne);switch(Ut){case"years":rt.month=1;case"quarters":case"months":rt.day=1;case"weeks":case"days":rt.hour=0;case"hours":rt.minute=0;case"minutes":rt.second=0;case"seconds":rt.millisecond=0}if("weeks"===Ut)if(Pe){const Rn=this.loc.getStartOfWeek(),{weekday:Kn}=this;Kn<Rn&&(rt.weekNumber=this.weekNumber-1),rt.weekday=Rn}else rt.weekday=1;if("quarters"===Ut){const Rn=Math.ceil(this.month/3);rt.month=3*(Rn-1)+1}return this.set(rt)}endOf(ne,Pe){return this.isValid?this.plus({[ne]:1}).startOf(ne,Pe).minus(1):this}toFormat(ne,Pe={}){return this.isValid?ca.create(this.loc.redefaultToEN(Pe)).formatDateTimeFromString(this,ne):hu}toLocaleString(ne=ce,Pe={}){return this.isValid?ca.create(this.loc.clone(Pe),ne).formatDateTime(this):hu}toLocaleParts(ne={}){return this.isValid?ca.create(this.loc.clone(ne),ne).formatDateTimeParts(this):[]}toISO({format:ne="extended",suppressSeconds:Pe=!1,suppressMilliseconds:rt=!1,includeOffset:Ut=!0,extendedZone:Rn=!1}={}){if(!this.isValid)return null;const Kn="extended"===ne;let Y=pf(this,Kn);return Y+="T",Y+=hf(this,Kn,Pe,rt,Ut,Rn),Y}toISODate({format:ne="extended"}={}){return this.isValid?pf(this,"extended"===ne):null}toISOWeekDate(){return Bc(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:ne=!1,suppressSeconds:Pe=!1,includeOffset:rt=!0,includePrefix:Ut=!1,extendedZone:Rn=!1,format:Kn="extended"}={}){return this.isValid?(Ut?"T":"")+hf(this,"extended"===Kn,Pe,ne,rt,Rn):null}toRFC2822(){return Bc(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return Bc(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?pf(this,!0):null}toSQLTime({includeOffset:ne=!0,includeZone:Pe=!1,includeOffsetSpace:rt=!0}={}){let Ut="HH:mm:ss.SSS";return(Pe||ne)&&(rt&&(Ut+=" "),Pe?Ut+="z":ne&&(Ut+="ZZ")),Bc(this,Ut,!0)}toSQL(ne={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(ne)}`:null}toString(){return this.isValid?this.toISO():hu}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`DateTime { ts: ${this.toISO()}, zone: ${this.zone.name}, locale: ${this.locale} }`:`DateTime { Invalid, reason: ${this.invalidReason} }`}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(ne={}){if(!this.isValid)return{};const Pe={...this.c};return ne.includeConfig&&(Pe.outputCalendar=this.outputCalendar,Pe.numberingSystem=this.loc.numberingSystem,Pe.locale=this.loc.locale),Pe}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(ne,Pe="milliseconds",rt={}){if(!this.isValid||!ne.isValid)return da.invalid("created by diffing an invalid DateTime");const Ut={locale:this.locale,numberingSystem:this.numberingSystem,...rt},Rn=function Rt(Ue){return Array.isArray(Ue)?Ue:[Ue]}(Pe).map(da.normalizeUnit),Kn=ne.valueOf()>this.valueOf(),ue=function aa(Ue,ne,Pe,rt){let[Ut,Rn,Kn,Y]=function qf(Ue,ne,Pe){const rt=[["years",(Ce,ue)=>ue.year-Ce.year],["quarters",(Ce,ue)=>ue.quarter-Ce.quarter+4*(ue.year-Ce.year)],["months",(Ce,ue)=>ue.month-Ce.month+12*(ue.year-Ce.year)],["weeks",(Ce,ue)=>{const Ie=cc(Ce,ue);return(Ie-Ie%7)/7}],["days",cc]],Ut={},Rn=Ue;let Kn,Y;for(const[Ce,ue]of rt)Pe.indexOf(Ce)>=0&&(Kn=Ce,Ut[Ce]=ue(Ue,ne),Y=Rn.plus(Ut),Y>ne?(Ut[Ce]--,(Ue=Rn.plus(Ut))>ne&&(Y=Ue,Ut[Ce]--,Ue=Rn.plus(Ut))):Ue=Y);return[Ue,Ut,Y,Kn]}(Ue,ne,Pe);const Ce=ne-Ut,ue=Pe.filter(Ze=>["hours","minutes","seconds","milliseconds"].indexOf(Ze)>=0);0===ue.length&&(Kn<ne&&(Kn=Ut.plus({[Y]:1})),Kn!==Ut&&(Rn[Y]=(Rn[Y]||0)+Ce/(Kn-Ut)));const Ie=da.fromObject(Rn,rt);return ue.length>0?da.fromMillis(Ce,rt).shiftTo(...ue).plus(Ie):Ie}(Kn?this:ne,Kn?ne:this,Rn,Ut);return Kn?ue.negate():ue}diffNow(ne="milliseconds",Pe={}){return this.diff($o.now(),ne,Pe)}until(ne){return this.isValid?bl.fromDateTimes(this,ne):this}hasSame(ne,Pe,rt){if(!this.isValid)return!1;const Ut=ne.valueOf(),Rn=this.setZone(ne.zone,{keepLocalTime:!0});return Rn.startOf(Pe,rt)<=Ut&&Ut<=Rn.endOf(Pe,rt)}equals(ne){return this.isValid&&ne.isValid&&this.valueOf()===ne.valueOf()&&this.zone.equals(ne.zone)&&this.loc.equals(ne.loc)}toRelative(ne={}){if(!this.isValid)return null;const Pe=ne.base||$o.fromObject({},{zone:this.zone}),rt=ne.padding?this<Pe?-ne.padding:ne.padding:0;let Ut=["years","months","days","hours","minutes","seconds"],Rn=ne.unit;return Array.isArray(ne.unit)&&(Ut=ne.unit,Rn=void 0),vs(Pe,this.plus(rt),{...ne,numeric:"always",units:Ut,unit:Rn})}toRelativeCalendar(ne={}){return this.isValid?vs(ne.base||$o.fromObject({},{zone:this.zone}),this,{...ne,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...ne){if(!ne.every($o.isDateTime))throw new Ee("min requires all arguments be DateTimes");return jn(ne,Pe=>Pe.valueOf(),Math.min)}static max(...ne){if(!ne.every($o.isDateTime))throw new Ee("max requires all arguments be DateTimes");return jn(ne,Pe=>Pe.valueOf(),Math.max)}static fromFormatExplain(ne,Pe,rt={}){const{locale:Ut=null,numberingSystem:Rn=null}=rt;return id(Mn.fromOpts({locale:Ut,numberingSystem:Rn,defaultToEN:!0}),ne,Pe)}static fromStringExplain(ne,Pe,rt={}){return $o.fromFormatExplain(ne,Pe,rt)}static buildFormatParser(ne,Pe={}){const{locale:rt=null,numberingSystem:Ut=null}=Pe,Rn=Mn.fromOpts({locale:rt,numberingSystem:Ut,defaultToEN:!0});return new Vu(Rn,ne)}static fromFormatParser(ne,Pe,rt={}){if(Qr(ne)||Qr(Pe))throw new Ee("fromFormatParser requires an input string and a format parser");const{locale:Ut=null,numberingSystem:Rn=null}=rt,Kn=Mn.fromOpts({locale:Ut,numberingSystem:Rn,defaultToEN:!0});if(!Kn.equals(Pe.locale))throw new Ee(`fromFormatParser called with a locale of ${Kn}, but the format parser was created for ${Pe.locale}`);const{result:Y,zone:Ce,specificOffset:ue,invalidReason:Ie}=Pe.explainFromTokens(ne);return Ie?$o.invalid(Ie):Yl(Y,Ce,rt,`format ${Pe.format}`,ne,ue)}static get DATE_SHORT(){return ce}static get DATE_MED(){return le}static get DATE_MED_WITH_WEEKDAY(){return je}static get DATE_FULL(){return Et}static get DATE_HUGE(){return wt}static get TIME_SIMPLE(){return ve}static get TIME_WITH_SECONDS(){return fn}static get TIME_WITH_SHORT_OFFSET(){return ct}static get TIME_WITH_LONG_OFFSET(){return en}static get TIME_24_SIMPLE(){return an}static get TIME_24_WITH_SECONDS(){return un}static get TIME_24_WITH_SHORT_OFFSET(){return vn}static get TIME_24_WITH_LONG_OFFSET(){return Pt}static get DATETIME_SHORT(){return Ae}static get DATETIME_SHORT_WITH_SECONDS(){return dt}static get DATETIME_MED(){return ut}static get DATETIME_MED_WITH_SECONDS(){return Mt}static get DATETIME_MED_WITH_WEEKDAY(){return Wt}static get DATETIME_FULL(){return It}static get DATETIME_FULL_WITH_SECONDS(){return Vn}static get DATETIME_HUGE(){return pn}static get DATETIME_HUGE_WITH_SECONDS(){return Wn}}function Mc(Ue){if($o.isDateTime(Ue))return Ue;if(Ue&&Ue.valueOf&&dl(Ue.valueOf()))return $o.fromJSDate(Ue);if(Ue&&"object"==typeof Ue)return $o.fromObject(Ue);throw new Ee(`Unknown datetime argument: ${Ue}, of type ${typeof Ue}`)}const yc="3.5.0"},2739:(Ot,Me,S)=>{S.r(Me),S.d(Me,{AccessorNode:()=>bA,AccessorNodeDependencies:()=>j,ArgumentsError:()=>af,ArrayNode:()=>go,ArrayNodeDependencies:()=>wu,AssignmentNode:()=>gk,AssignmentNodeDependencies:()=>iB,BigNumber:()=>br,BigNumberDependencies:()=>To,BlockNode:()=>Oo,BlockNodeDependencies:()=>uB,Chain:()=>Gd,ChainDependencies:()=>fB,Complex:()=>yo,ComplexDependencies:()=>pd,ConditionalNode:()=>Ar,ConditionalNodeDependencies:()=>gB,ConstantNode:()=>ma,ConstantNodeDependencies:()=>sO,DenseMatrix:()=>Os,DenseMatrixDependencies:()=>Fl,DimensionError:()=>va,EDependencies:()=>R5,FibonacciHeap:()=>UN,FibonacciHeapDependencies:()=>RB,Fraction:()=>Ba,FractionDependencies:()=>CA,FunctionAssignmentNode:()=>qh,FunctionAssignmentNodeDependencies:()=>vB,FunctionNode:()=>n1,FunctionNodeDependencies:()=>lO,Help:()=>QP,HelpDependencies:()=>LB,ImmutableDenseMatrix:()=>PA,ImmutableDenseMatrixDependencies:()=>pB,Index:()=>qp,IndexDependencies:()=>V_,IndexError:()=>bc,IndexNode:()=>nx,IndexNodeDependencies:()=>xk,InfinityDependencies:()=>wj,LN10:()=>Rr,LN10Dependencies:()=>Oj,LN2:()=>So,LN2Dependencies:()=>Fj,LOG10E:()=>xo,LOG10EDependencies:()=>Nj,LOG2E:()=>XM,LOG2EDependencies:()=>Rj,Matrix:()=>Jr,MatrixDependencies:()=>yk,NaNDependencies:()=>a4,Node:()=>Xt,NodeDependencies:()=>Im,ObjectNode:()=>Ln,ObjectNodeDependencies:()=>Sk,OperatorNode:()=>zn,OperatorNodeDependencies:()=>wA,PIDependencies:()=>L5,ParenthesisNode:()=>xi,ParenthesisNodeDependencies:()=>NN,Parser:()=>YP,ParserDependencies:()=>KB,Range:()=>Ns,RangeDependencies:()=>P4,RangeNode:()=>oc,RangeNodeDependencies:()=>_B,RelationalNode:()=>Nr,RelationalNodeDependencies:()=>yB,ResultSet:()=>Ml,ResultSetDependencies:()=>cB,SQRT1_2:()=>Nu,SQRT1_2Dependencies:()=>Y4,SQRT2:()=>ha,SQRT2Dependencies:()=>X4,Spa:()=>AO,SpaDependencies:()=>jB,SparseMatrix:()=>$l,SparseMatrixDependencies:()=>fE,SymbolNode:()=>ix,SymbolNodeDependencies:()=>aO,Unit:()=>Ta,UnitDependencies:()=>ul,_Infinity:()=>us,_NaN:()=>No,_false:()=>Ca,_null:()=>Hr,_true:()=>wd,abs:()=>Fa,absDependencies:()=>Cv,acos:()=>hs,acosDependencies:()=>fe,acosh:()=>p0,acoshDependencies:()=>Ne,acot:()=>Ka,acotDependencies:()=>vt,acoth:()=>Qb,acothDependencies:()=>ln,acsc:()=>mg,acscDependencies:()=>Hn,acsch:()=>tI,acschDependencies:()=>Oi,add:()=>Ha,addDependencies:()=>o,addScalar:()=>Du,addScalarDependencies:()=>r,all:()=>H5,and:()=>MO,andDependencies:()=>to,andTransformDependencies:()=>Mr,apply:()=>h0,applyDependencies:()=>ss,applyTransformDependencies:()=>Rs,arg:()=>Bw,argDependencies:()=>Us,asec:()=>IT,asecDependencies:()=>Tf,asech:()=>F_,asechDependencies:()=>vM,asin:()=>Do,asinDependencies:()=>L3,asinh:()=>Gb,asinhDependencies:()=>eV,atan:()=>LC,atan2:()=>pO,atan2Dependencies:()=>tV,atanDependencies:()=>rB,atanh:()=>N_,atanhDependencies:()=>nV,atomicMass:()=>HA,atomicMassDependencies:()=>iV,avogadro:()=>yI,avogadroDependencies:()=>rV,bellNumbers:()=>mR,bellNumbersDependencies:()=>oV,bigint:()=>ST,bigintDependencies:()=>sV,bignumber:()=>Gf,bignumberDependencies:()=>eD,bin:()=>qS,binDependencies:()=>aV,bitAnd:()=>hO,bitAndDependencies:()=>lV,bitAndTransformDependencies:()=>cV,bitNot:()=>HS,bitNotDependencies:()=>uV,bitOr:()=>LN,bitOrDependencies:()=>dV,bitOrTransformDependencies:()=>fV,bitXor:()=>kN,bitXorDependencies:()=>pV,bohrMagneton:()=>YN,bohrMagnetonDependencies:()=>hV,bohrRadius:()=>aR,bohrRadiusDependencies:()=>mV,boltzmann:()=>YS,boltzmannDependencies:()=>gV,boolean:()=>R_,booleanDependencies:()=>vV,catalan:()=>PN,catalanDependencies:()=>_V,cbrt:()=>Ts,cbrtDependencies:()=>dB,ceil:()=>lI,ceilDependencies:()=>k3,chain:()=>dE,chainDependencies:()=>yV,classicalElectronRadius:()=>GO,classicalElectronRadiusDependencies:()=>bV,clone:()=>kC,cloneDependencies:()=>CV,column:()=>$A,columnDependencies:()=>hB,columnTransformDependencies:()=>DV,combinations:()=>Kb,combinationsDependencies:()=>I3,combinationsWithRep:()=>$C,combinationsWithRepDependencies:()=>wV,compare:()=>Hw,compareDependencies:()=>FN,compareNatural:()=>P_,compareNaturalDependencies:()=>yM,compareText:()=>rI,compareTextDependencies:()=>mB,compile:()=>C3,compileDependencies:()=>xV,complex:()=>uf,complexDependencies:()=>O3,composition:()=>wO,compositionDependencies:()=>SV,concat:()=>os,concatDependencies:()=>n,concatTransformDependencies:()=>EV,conductanceQuantum:()=>zA,conductanceQuantumDependencies:()=>TV,config:()=>Sn,conj:()=>L_,conjDependencies:()=>IN,corr:()=>_R,corrDependencies:()=>MV,cos:()=>PC,cosDependencies:()=>j3,cosh:()=>WC,coshDependencies:()=>IV,cot:()=>AA,cotDependencies:()=>AV,coth:()=>KC,cothDependencies:()=>OV,coulomb:()=>XN,coulombDependencies:()=>FV,count:()=>gl,countDependencies:()=>NV,create:()=>JB,createAbs:()=>ef,createAccessorNode:()=>eM,createAcos:()=>wg,createAcosh:()=>D1,createAcot:()=>Tr,createAcoth:()=>Ug,createAcsc:()=>ka,createAcsch:()=>w1,createAdd:()=>db,createAddScalar:()=>oh,createAnd:()=>Wf,createAndTransform:()=>Y2,createApply:()=>Kv,createApplyTransform:()=>cA,createArg:()=>vf,createArrayNode:()=>rE,createAsec:()=>sy,createAsech:()=>Bm,createAsin:()=>R1,createAsinh:()=>Ko,createAssignmentNode:()=>nM,createAtan:()=>wc,createAtan2:()=>a_,createAtanh:()=>Mh,createAtomicMass:()=>ne,createAvogadro:()=>Pe,createBellNumbers:()=>r0,createBigNumberClass:()=>$i,createBigint:()=>nD,createBignumber:()=>qv,createBin:()=>$g,createBitAnd:()=>Vh,createBitAndTransform:()=>fA,createBitNot:()=>a1,createBitOr:()=>by,createBitOrTransform:()=>tO,createBitXor:()=>gm,createBlockNode:()=>MI,createBohrMagneton:()=>Bc,createBohrRadius:()=>mn,createBoltzmann:()=>rt,createBoolean:()=>I0,createCatalan:()=>c_,createCbrt:()=>mp,createCeil:()=>hC,createChain:()=>ZT,createChainClass:()=>XT,createClassicalElectronRadius:()=>gi,createClone:()=>nf,createColumn:()=>zy,createColumnTransform:()=>gM,createCombinations:()=>cD,createCombinationsWithRep:()=>Q0,createCompare:()=>Dy,createCompareNatural:()=>$h,createCompareText:()=>ev,createCompile:()=>kI,createComplex:()=>Fv,createComplexClass:()=>nd,createComposition:()=>wS,createConcat:()=>Gm,createConcatTransform:()=>cE,createConditionalNode:()=>QC,createConductanceQuantum:()=>pf,createConj:()=>K_,createConstantNode:()=>qw,createCorr:()=>Wb,createCos:()=>l1,createCosh:()=>FD,createCot:()=>Tg,createCoth:()=>jd,createCoulomb:()=>ju,createCount:()=>n_,createCreateUnit:()=>mv,createCross:()=>v_,createCsc:()=>Vd,createCsch:()=>T1,createCtranspose:()=>Pa,createCube:()=>A0,createCumSum:()=>xy,createCumSumTransform:()=>mA,createDeepEqual:()=>mc,createDenseMatrixClass:()=>Nf,createDerivative:()=>YC,createDet:()=>vw,createDeuteronMass:()=>Qo,createDiag:()=>i_,createDiff:()=>Sy,createDiffTransform:()=>t1,createDistance:()=>gb,createDivide:()=>xC,createDivideScalar:()=>k1,createDot:()=>jh,createDotDivide:()=>Kg,createDotMultiply:()=>Mb,createDotPow:()=>iu,createE:()=>qs,createEfimovFactor:()=>Ue,createEigs:()=>jb,createElectricConstant:()=>Td,createElectronMass:()=>rr,createElementaryCharge:()=>Yl,createEqual:()=>V1,createEqualScalar:()=>Rv,createEqualText:()=>Qs,createErf:()=>Q_,createEvaluate:()=>BI,createExp:()=>F0,createExpm:()=>S_,createExpm1:()=>Um,createFactorial:()=>Dd,createFalse:()=>md,createFaraday:()=>Ut,createFermiCoupling:()=>or,createFft:()=>dd,createFibonacciHeapClass:()=>Ib,createFilter:()=>mD,createFilterTransform:()=>lA,createFineStructure:()=>ia,createFirstRadiation:()=>Rn,createFix:()=>Ab,createFlatten:()=>$m,createFloor:()=>Xm,createForEach:()=>Oh,createForEachTransform:()=>G2,createFormat:()=>_D,createFraction:()=>pp,createFractionClass:()=>bg,createFreqz:()=>c0,createFunctionAssignmentNode:()=>OI,createFunctionNode:()=>iM,createGamma:()=>kb,createGasConstant:()=>Y,createGcd:()=>eC,createGetMatrixDataType:()=>p1,createGravitationConstant:()=>kc,createGravity:()=>Yr,createHartreeEnergy:()=>La,createHasNumericValue:()=>U1,createHelp:()=>aA,createHelpClass:()=>aM,createHex:()=>Pv,createHypot:()=>Ty,createI:()=>id,createIdentity:()=>$a,createIfft:()=>hv,createIm:()=>Og,createImmutableDenseMatrixClass:()=>_b,createIndex:()=>By,createIndexClass:()=>tv,createIndexNode:()=>JT,createIndexTransform:()=>gA,createInfinity:()=>gd,createIntersect:()=>og,createInv:()=>Ju,createInverseConductanceQuantum:()=>hf,createInvmod:()=>Cw,createIsInteger:()=>rm,createIsNaN:()=>M1,createIsNegative:()=>Bv,createIsNumeric:()=>tp,createIsPositive:()=>ad,createIsPrime:()=>ND,createIsZero:()=>Ng,createKldivergence:()=>Ub,createKlitzing:()=>Re,createKron:()=>kh,createLN10:()=>su,createLN2:()=>Bu,createLOG10E:()=>xa,createLOG2E:()=>Is,createLarger:()=>My,createLargerEq:()=>fy,createLcm:()=>Vy,createLeafCount:()=>$I,createLeftShift:()=>py,createLgamma:()=>B0,createLog:()=>u_,createLog10:()=>ty,createLog1p:()=>jy,createLog2:()=>hl,createLoschmidt:()=>Kn,createLsolve:()=>my,createLsolveAll:()=>Ay,createLup:()=>Gy,createLusolve:()=>EC,createLyap:()=>mo,createMad:()=>zb,createMagneticConstant:()=>kd,createMagneticFluxQuantum:()=>_e,createMap:()=>Ou,createMapTransform:()=>K2,createMatrix:()=>Wg,createMatrixClass:()=>Ch,createMatrixFromColumns:()=>Oa,createMatrixFromFunction:()=>cl,createMatrixFromRows:()=>Oy,createMax:()=>Uy,createMaxTransform:()=>tx,createMean:()=>RC,createMeanTransform:()=>uE,createMedian:()=>wm,createMin:()=>rC,createMinTransform:()=>pA,createMod:()=>Ey,createMode:()=>np,createMolarMass:()=>Si,createMolarMassC12:()=>oi,createMolarPlanckConstant:()=>Ce,createMolarVolume:()=>ue,createMultinomial:()=>Jy,createMultiply:()=>bb,createMultiplyScalar:()=>m1,createNaN:()=>Eu,createNeutronMass:()=>ll,createNode:()=>DI,createNorm:()=>ye,createNot:()=>Wm,createNthRoot:()=>nS,createNthRoots:()=>ng,createNuclearMagneton:()=>Dt,createNull:()=>Ld,createNumber:()=>xD,createNumeric:()=>N1,createObjectNode:()=>n2,createOct:()=>Lp,createOnes:()=>ob,createOperatorNode:()=>$T,createOr:()=>rv,createOrTransform:()=>Q2,createParenthesisNode:()=>SI,createParse:()=>rM,createParser:()=>Zw,createParserClass:()=>Zb,createPartitionSelect:()=>Db,createPermutations:()=>e0,createPhi:()=>Xc,createPi:()=>Pu,createPickRandom:()=>v1,createPinv:()=>Jl,createPlanckCharge:()=>Hl,createPlanckConstant:()=>El,createPlanckLength:()=>rs,createPlanckMass:()=>ls,createPlanckTemperature:()=>dc,createPlanckTime:()=>Zo,createPolynomialRoot:()=>t0,createPow:()=>zh,createPrint:()=>$v,createPrintTransform:()=>uA,createProd:()=>$d,createProtonMass:()=>vs,createQr:()=>mm,createQuantileSeq:()=>I_,createQuantileSeqTransform:()=>l,createQuantumOfCirculation:()=>Sa,createRandom:()=>Lh,createRandomInt:()=>fp,createRange:()=>nu,createRangeClass:()=>If,createRangeNode:()=>QT,createRangeTransform:()=>_A,createRationalize:()=>uM,createRe:()=>SD,createReducedPlanckConstant:()=>uc,createRelationalNode:()=>HT,createReplacer:()=>io,createReshape:()=>Zu,createResize:()=>W1,createResolve:()=>Xw,createResultSet:()=>xr,createReviver:()=>YT,createRightArithShift:()=>H1,createRightLogShift:()=>d_,createRotate:()=>si,createRotationMatrix:()=>ht,createRound:()=>z1,createRow:()=>ym,createRowTransform:()=>yA,createRydberg:()=>$o,createSQRT1_2:()=>vd,createSQRT2:()=>Vu,createSackurTetrode:()=>Ie,createSchur:()=>yn,createSec:()=>$0,createSech:()=>Qv,createSecondRadiation:()=>Ze,createSetCartesian:()=>Fb,createSetDifference:()=>Hh,createSetDistinct:()=>xw,createSetIntersect:()=>w_,createSetIsSubset:()=>Wh,createSetMultiplicity:()=>cd,createSetPowerset:()=>sg,createSetSize:()=>Vb,createSetSymDifference:()=>hh,createSetUnion:()=>fg,createSign:()=>Hm,createSimplify:()=>VI,createSimplifyConstant:()=>sM,createSimplifyCore:()=>PI,createSin:()=>lm,createSinh:()=>ay,createSize:()=>bf,createSlu:()=>h_,createSmaller:()=>jf,createSmallerEq:()=>Ys,createSolveODE:()=>IC,createSort:()=>$f,createSpaClass:()=>C_,createSparse:()=>Z0,createSparseMatrixClass:()=>H0,createSpeedOfLight:()=>Ed,createSplitUnit:()=>kg,createSqrt:()=>zm,createSqrtm:()=>pg,createSquare:()=>TD,createSqueeze:()=>Zv,createStd:()=>g,createStdTransform:()=>ae,createStefanBoltzmann:()=>kt,createStirlingS2:()=>OC,createString:()=>G0,createSubset:()=>ov,createSubsetTransform:()=>hA,createSubtract:()=>Vp,createSubtractScalar:()=>Cd,createSum:()=>ig,createSumTransform:()=>vA,createSylvester:()=>jr,createSymbolNode:()=>NI,createSymbolicEqual:()=>fF,createTan:()=>zv,createTanh:()=>Vg,createTau:()=>Lc,createThomsonCrossSection:()=>Mc,createTo:()=>s_,createTrace:()=>vm,createTranspose:()=>Hg,createTrue:()=>Su,createTypeOf:()=>rf,createTyped:()=>Xl,createUnaryMinus:()=>jg,createUnaryPlus:()=>_y,createUnequal:()=>Rb,createUnit:()=>lR,createUnitClass:()=>cf,createUnitDependencies:()=>RV,createUnitFunction:()=>mh,createUppercaseE:()=>pu,createUppercasePi:()=>Sd,createUsolve:()=>yy,createUsolveAll:()=>Fs,createVacuumImpedance:()=>Pc,createVariance:()=>A_,createVarianceTransform:()=>w,createVersion:()=>hu,createWeakMixingAngle:()=>yc,createWienDisplacement:()=>rn,createXgcd:()=>Kr,createXor:()=>Zg,createZeros:()=>jD,createZeta:()=>x,createZpk2tf:()=>rg,cross:()=>xO,crossDependencies:()=>LV,csc:()=>QM,cscDependencies:()=>kV,csch:()=>_v,cschDependencies:()=>PV,ctranspose:()=>Xs,ctransposeDependencies:()=>U3,cube:()=>BC,cubeDependencies:()=>BV,cumsum:()=>OT,cumsumDependencies:()=>VV,cumsumTransformDependencies:()=>jV,deepEqual:()=>LA,deepEqualDependencies:()=>W3,derivative:()=>E3,derivativeDependencies:()=>UV,det:()=>SO,detDependencies:()=>aB,deuteronMass:()=>ZN,deuteronMassDependencies:()=>$V,diag:()=>il,diagDependencies:()=>wB,diff:()=>mO,diffDependencies:()=>WV,diffTransformDependencies:()=>HV,distance:()=>BN,distanceDependencies:()=>zV,divide:()=>Kf,divideDependencies:()=>_g,divideScalar:()=>Da,divideScalarDependencies:()=>rp,docs:()=>oA,dot:()=>oI,dotDependencies:()=>M3,dotDivide:()=>fd,dotDivideDependencies:()=>e3,dotMultiply:()=>cI,dotMultiplyDependencies:()=>GV,dotPow:()=>PT,dotPowDependencies:()=>KV,e:()=>ml,eDependencies:()=>xB,efimovFactor:()=>Cr,efimovFactorDependencies:()=>qV,eigs:()=>bI,eigsDependencies:()=>MB,electricConstant:()=>JN,electricConstantDependencies:()=>QV,electronMass:()=>eE,electronMassDependencies:()=>YV,elementaryCharge:()=>gI,elementaryChargeDependencies:()=>XV,equal:()=>zd,equalDependencies:()=>ox,equalScalar:()=>nl,equalScalarDependencies:()=>Kl,equalText:()=>gO,equalTextDependencies:()=>ZV,erf:()=>OA,erfDependencies:()=>JV,evaluate:()=>iO,evaluateDependencies:()=>X3,exp:()=>ET,expDependencies:()=>IB,expm:()=>vI,expm1:()=>FA,expm1Dependencies:()=>tj,expmDependencies:()=>ej,factorial:()=>BT,factorialDependencies:()=>ZP,factory:()=>re,falseDependencies:()=>nj,faraday:()=>Tm,faradayDependencies:()=>ij,fermiCoupling:()=>$O,fermiCouplingDependencies:()=>rj,fft:()=>GA,fftDependencies:()=>NB,filter:()=>zS,filterDependencies:()=>oj,filterTransformDependencies:()=>sj,fineStructure:()=>oo,fineStructureDependencies:()=>aj,firstRadiation:()=>cR,firstRadiationDependencies:()=>lj,fix:()=>$N,fixDependencies:()=>sB,flatten:()=>VC,flattenDependencies:()=>t3,floor:()=>kA,floorDependencies:()=>oB,forEach:()=>YM,forEachDependencies:()=>cj,forEachTransformDependencies:()=>uj,format:()=>Vw,formatDependencies:()=>XP,fraction:()=>k_,fractionDependencies:()=>bk,freqz:()=>yR,freqzDependencies:()=>dj,gamma:()=>_I,gammaDependencies:()=>P3,gasConstant:()=>WO,gasConstantDependencies:()=>fj,gcd:()=>FT,gcdDependencies:()=>pj,getMatrixDataType:()=>jw,getMatrixDataTypeDependencies:()=>B3,gravitationConstant:()=>eR,gravitationConstantDependencies:()=>hj,gravity:()=>kO,gravityDependencies:()=>mj,hartreeEnergy:()=>XS,hartreeEnergyDependencies:()=>gj,hasNumericValue:()=>Sm,hasNumericValueDependencies:()=>vj,help:()=>T3,helpDependencies:()=>_j,hex:()=>TT,hexDependencies:()=>yj,hypot:()=>VN,hypotDependencies:()=>bj,i:()=>Co,iDependencies:()=>AB,identity:()=>Ef,identityDependencies:()=>rO,ifft:()=>ZS,ifftDependencies:()=>Cj,im:()=>jC,imDependencies:()=>G3,index:()=>EO,indexDependencies:()=>kB,indexTransformDependencies:()=>Dj,intersect:()=>TO,intersectDependencies:()=>xj,inv:()=>g0,invDependencies:()=>AN,inverseConductanceQuantum:()=>uR,inverseConductanceQuantumDependencies:()=>Sj,invmod:()=>uI,invmodDependencies:()=>Ej,isAccessorNode:()=>gn,isArray:()=>dt,isArrayNode:()=>Nn,isAssignmentNode:()=>Yn,isBigInt:()=>an,isBigNumber:()=>en,isBlockNode:()=>cr,isBoolean:()=>Wn,isChain:()=>ri,isCollection:()=>Mt,isComplex:()=>un,isConditionalNode:()=>Ai,isConstantNode:()=>Qi,isDate:()=>qt,isDenseMatrix:()=>Wt,isFraction:()=>vn,isFunction:()=>St,isFunctionAssignmentNode:()=>Ur,isFunctionNode:()=>eo,isHelp:()=>An,isIndex:()=>pn,isIndexNode:()=>as,isInteger:()=>zp,isIntegerDependencies:()=>v,isMap:()=>Cn,isMatrix:()=>ut,isNaN:()=>Kp,isNaNDependencies:()=>n3,isNegative:()=>vv,isNegativeDependencies:()=>oO,isNode:()=>uo,isNull:()=>Zn,isNumber:()=>ct,isNumeric:()=>N,isNumericDependencies:()=>MN,isObject:()=>on,isObjectNode:()=>mi,isObjectWrappingMap:()=>fi,isOperatorNode:()=>ci,isParenthesisNode:()=>yt,isPartitionedMap:()=>tn,isPositive:()=>u0,isPositiveDependencies:()=>ON,isPrime:()=>HC,isPrimeDependencies:()=>Tj,isRange:()=>Vn,isRangeNode:()=>hn,isRegExp:()=>Ht,isRelationalNode:()=>Gt,isResultSet:()=>ji,isSparseMatrix:()=>It,isString:()=>Ae,isSymbolNode:()=>Gn,isUndefined:()=>Dn,isUnit:()=>Pt,isZero:()=>Kh,isZeroDependencies:()=>pE,kldivergence:()=>HO,kldivergenceDependencies:()=>Mj,klitzing:()=>tR,klitzingDependencies:()=>Ij,kron:()=>df,kronDependencies:()=>Aj,larger:()=>_h,largerDependencies:()=>_0,largerEq:()=>Cp,largerEqDependencies:()=>A3,lcm:()=>WN,lcmDependencies:()=>Lj,leafCount:()=>w3,leafCountDependencies:()=>kj,leftShift:()=>Yb,leftShiftDependencies:()=>Pj,lgamma:()=>MT,lgammaDependencies:()=>Bj,log:()=>sI,log10:()=>ZM,log10Dependencies:()=>Vj,log1p:()=>HN,log1pDependencies:()=>jj,log2:()=>GS,log2Dependencies:()=>OB,logDependencies:()=>Z3,loschmidt:()=>nR,loschmidtDependencies:()=>Uj,lsolve:()=>Em,lsolveAll:()=>vO,lsolveAllDependencies:()=>$j,lsolveDependencies:()=>VB,lup:()=>kT,lupDependencies:()=>UB,lusolve:()=>dR,lusolveDependencies:()=>WB,lyap:()=>t2,lyapDependencies:()=>Wj,mad:()=>bR,madDependencies:()=>Hj,magneticConstant:()=>KA,magneticConstantDependencies:()=>zj,magneticFluxQuantum:()=>fR,magneticFluxQuantumDependencies:()=>Gj,map:()=>d0,mapDependencies:()=>RN,mapTransformDependencies:()=>Kj,matrix:()=>$,matrixDependencies:()=>t,matrixFromColumns:()=>AT,matrixFromColumnsDependencies:()=>K3,matrixFromFunction:()=>ge,matrixFromFunctionDependencies:()=>qj,matrixFromRows:()=>BA,matrixFromRowsDependencies:()=>Qj,max:()=>LT,maxDependencies:()=>eB,maxTransformDependencies:()=>Yj,mean:()=>zO,meanDependencies:()=>bB,meanTransformDependencies:()=>Xj,median:()=>KO,medianDependencies:()=>GB,min:()=>_O,minDependencies:()=>Zj,minTransformDependencies:()=>Jj,mod:()=>VA,modDependencies:()=>PB,mode:()=>nt,modeDependencies:()=>e4,molarMass:()=>JS,molarMassC12:()=>PO,molarMassC12Dependencies:()=>n4,molarMassDependencies:()=>t4,molarPlanckConstant:()=>OO,molarPlanckConstantDependencies:()=>r4,molarVolume:()=>gR,molarVolumeDependencies:()=>o4,multinomial:()=>pR,multinomialDependencies:()=>s4,multiply:()=>Gc,multiplyDependencies:()=>td,multiplyScalar:()=>Ku,multiplyScalarDependencies:()=>Yp,neutronMass:()=>iR,neutronMassDependencies:()=>l4,norm:()=>ZA,normDependencies:()=>J3,not:()=>Cs,notDependencies:()=>Lr,nthRoot:()=>dO,nthRootDependencies:()=>c4,nthRoots:()=>yO,nthRootsDependencies:()=>u4,nuclearMagneton:()=>rR,nuclearMagnetonDependencies:()=>d4,nullDependencies:()=>f4,number:()=>Ul,numberDependencies:()=>DA,numeric:()=>Lt,numericDependencies:()=>rx,oct:()=>JM,octDependencies:()=>p4,ones:()=>nI,onesDependencies:()=>h4,or:()=>bO,orDependencies:()=>m4,orTransformDependencies:()=>g4,parse:()=>JC,parseDependencies:()=>bM,parser:()=>x3,parserDependencies:()=>v4,partitionSelect:()=>aI,partitionSelectDependencies:()=>R3,permutations:()=>hR,permutationsDependencies:()=>_4,phi:()=>ys,phiDependencies:()=>y4,pi:()=>Po,piDependencies:()=>tB,pickRandom:()=>xd,pickRandomDependencies:()=>b4,pinv:()=>Kw,pinvDependencies:()=>C4,planckCharge:()=>qA,planckChargeDependencies:()=>D4,planckConstant:()=>vR,planckConstantDependencies:()=>w4,planckLength:()=>FO,planckLengthDependencies:()=>x4,planckMass:()=>tE,planckMassDependencies:()=>S4,planckTemperature:()=>NO,planckTemperatureDependencies:()=>E4,planckTime:()=>JA,planckTimeDependencies:()=>T4,polynomialRoot:()=>BO,polynomialRootDependencies:()=>M4,pow:()=>bv,powDependencies:()=>ax,print:()=>ua,printDependencies:()=>I4,printTransformDependencies:()=>A4,prod:()=>bn,prodDependencies:()=>CB,protonMass:()=>oR,protonMassDependencies:()=>O4,qr:()=>RA,qrDependencies:()=>q3,quantileSeq:()=>YA,quantileSeqDependencies:()=>F4,quantileSeqTransformDependencies:()=>N4,quantumOfCirculation:()=>RO,quantumOfCirculationDependencies:()=>R4,random:()=>yp,randomDependencies:()=>L4,randomInt:()=>zC,randomIntDependencies:()=>k4,range:()=>m0,rangeDependencies:()=>wk,rangeTransformDependencies:()=>B4,rationalize:()=>S3,rationalizeDependencies:()=>V4,re:()=>UC,reDependencies:()=>Q3,reducedPlanckConstant:()=>sR,reducedPlanckConstantDependencies:()=>j4,replacer:()=>wi,replacerDependencies:()=>U4,reshape:()=>ui,reshapeDependencies:()=>EB,resize:()=>iI,resizeDependencies:()=>$4,resolve:()=>qP,resolveDependencies:()=>DB,reviver:()=>qu,reviverDependencies:()=>W4,rightArithShift:()=>Ww,rightArithShiftDependencies:()=>H4,rightLogShift:()=>jA,rightLogShiftDependencies:()=>z4,rotate:()=>QO,rotateDependencies:()=>G4,rotationMatrix:()=>qO,rotationMatrixDependencies:()=>QB,round:()=>Xb,roundDependencies:()=>Ck,row:()=>pI,rowDependencies:()=>K4,rowTransformDependencies:()=>q4,rydberg:()=>Ek,rydbergDependencies:()=>Q4,sackurTetrode:()=>Rd,sackurTetrodeDependencies:()=>Z4,schur:()=>CI,schurDependencies:()=>HB,sec:()=>Wa,secDependencies:()=>J4,sech:()=>GC,sechDependencies:()=>e5,secondRadiation:()=>Tk,secondRadiationDependencies:()=>t5,setCartesian:()=>zN,setCartesianDependencies:()=>n5,setDifference:()=>hI,setDifferenceDependencies:()=>YB,setDistinct:()=>dI,setDistinctDependencies:()=>r5,setIntersect:()=>mI,setIntersectDependencies:()=>XB,setIsSubset:()=>fI,setIsSubsetDependencies:()=>o5,setMultiplicity:()=>Gw,setMultiplicityDependencies:()=>s5,setPowerset:()=>UA,setPowersetDependencies:()=>a5,setSize:()=>VO,setSizeDependencies:()=>l5,setSymDifference:()=>IO,setSymDifferenceDependencies:()=>ZB,setUnion:()=>qC,setUnionDependencies:()=>c5,sign:()=>Sf,signDependencies:()=>SB,simplify:()=>TN,simplifyConstant:()=>vk,simplifyConstantDependencies:()=>H3,simplifyCore:()=>_k,simplifyCoreDependencies:()=>z3,simplifyDependencies:()=>F3,sin:()=>wl,sinDependencies:()=>N3,sinh:()=>qb,sinhDependencies:()=>u5,size:()=>Hi,sizeDependencies:()=>Dv,slu:()=>jN,sluDependencies:()=>$B,smaller:()=>Dp,smallerDependencies:()=>y0,smallerEq:()=>zw,smallerEqDependencies:()=>Dk,solveODE:()=>jO,solveODEDependencies:()=>d5,sort:()=>GN,sortDependencies:()=>f5,sparse:()=>Uw,sparseDependencies:()=>p5,speedOfLight:()=>Mk,speedOfLightDependencies:()=>h5,splitUnit:()=>eI,splitUnitDependencies:()=>m5,sqrt:()=>vh,sqrtDependencies:()=>hE,sqrtm:()=>qN,sqrtmDependencies:()=>g5,square:()=>NA,squareDependencies:()=>v5,squeeze:()=>KS,squeezeDependencies:()=>_5,std:()=>CR,stdDependencies:()=>y5,stdTransformDependencies:()=>b5,stefanBoltzmann:()=>Ik,stefanBoltzmannDependencies:()=>C5,stirlingS2:()=>QA,stirlingS2Dependencies:()=>lB,string:()=>f0,stringDependencies:()=>D5,subset:()=>vg,subsetDependencies:()=>D,subsetTransformDependencies:()=>w5,subtract:()=>zc,subtractDependencies:()=>Xp,subtractScalar:()=>gh,subtractScalarDependencies:()=>sx,sum:()=>NT,sumDependencies:()=>V3,sumTransformDependencies:()=>x5,sylvester:()=>e2,sylvesterDependencies:()=>zB,symbolicEqual:()=>D3,symbolicEqualDependencies:()=>S5,tan:()=>xm,tanDependencies:()=>E5,tanh:()=>$w,tanhDependencies:()=>T5,tau:()=>ru,tauDependencies:()=>FB,thomsonCrossSection:()=>LO,thomsonCrossSectionDependencies:()=>M5,to:()=>fO,toDependencies:()=>I5,trace:()=>CO,traceDependencies:()=>A5,transpose:()=>yr,transposeDependencies:()=>JP,trueDependencies:()=>O5,typeOf:()=>Gp,typeOfDependencies:()=>qB,typed:()=>dn,typedDependencies:()=>Pn,unaryMinus:()=>bp,unaryMinusDependencies:()=>_M,unaryPlus:()=>QS,unaryPlusDependencies:()=>$3,unequal:()=>KN,unequalDependencies:()=>F5,unit:()=>UO,unitDependencies:()=>N5,usolve:()=>gg,usolveAll:()=>RT,usolveAllDependencies:()=>TB,usolveDependencies:()=>Y3,vacuumImpedance:()=>QN,vacuumImpedanceDependencies:()=>k5,variance:()=>XA,varianceDependencies:()=>nB,varianceTransformDependencies:()=>P5,version:()=>jl,versionDependencies:()=>B5,weakMixingAngle:()=>Ol,weakMixingAngleDependencies:()=>V5,wienDisplacement:()=>WA,wienDisplacementDependencies:()=>j5,xgcd:()=>fs,xgcdDependencies:()=>BB,xor:()=>yv,xorDependencies:()=>U5,zeros:()=>co,zerosDependencies:()=>f,zeta:()=>DR,zetaDependencies:()=>$5,zpk2tf:()=>DO,zpk2tfDependencies:()=>W5});var i={};function e(){return e=Object.assign?Object.assign.bind():function(p){for(var m=1;m<arguments.length;m++){var b=arguments[m];for(var _ in b)({}).hasOwnProperty.call(b,_)&&(p[_]=b[_])}return p},e.apply(null,arguments)}S.r(i),S.d(i,{createAbs:()=>ef,createAccessorNode:()=>eM,createAcos:()=>wg,createAcosh:()=>D1,createAcot:()=>Tr,createAcoth:()=>Ug,createAcsc:()=>ka,createAcsch:()=>w1,createAdd:()=>db,createAddScalar:()=>oh,createAnd:()=>Wf,createAndTransform:()=>Y2,createApply:()=>Kv,createApplyTransform:()=>cA,createArg:()=>vf,createArrayNode:()=>rE,createAsec:()=>sy,createAsech:()=>Bm,createAsin:()=>R1,createAsinh:()=>Ko,createAssignmentNode:()=>nM,createAtan:()=>wc,createAtan2:()=>a_,createAtanh:()=>Mh,createAtomicMass:()=>ne,createAvogadro:()=>Pe,createBellNumbers:()=>r0,createBigNumberClass:()=>$i,createBigint:()=>nD,createBignumber:()=>qv,createBin:()=>$g,createBitAnd:()=>Vh,createBitAndTransform:()=>fA,createBitNot:()=>a1,createBitOr:()=>by,createBitOrTransform:()=>tO,createBitXor:()=>gm,createBlockNode:()=>MI,createBohrMagneton:()=>Bc,createBohrRadius:()=>mn,createBoltzmann:()=>rt,createBoolean:()=>I0,createCatalan:()=>c_,createCbrt:()=>mp,createCeil:()=>hC,createChain:()=>ZT,createChainClass:()=>XT,createClassicalElectronRadius:()=>gi,createClone:()=>nf,createColumn:()=>zy,createColumnTransform:()=>gM,createCombinations:()=>cD,createCombinationsWithRep:()=>Q0,createCompare:()=>Dy,createCompareNatural:()=>$h,createCompareText:()=>ev,createCompile:()=>kI,createComplex:()=>Fv,createComplexClass:()=>nd,createComposition:()=>wS,createConcat:()=>Gm,createConcatTransform:()=>cE,createConditionalNode:()=>QC,createConductanceQuantum:()=>pf,createConj:()=>K_,createConstantNode:()=>qw,createCorr:()=>Wb,createCos:()=>l1,createCosh:()=>FD,createCot:()=>Tg,createCoth:()=>jd,createCoulomb:()=>ju,createCount:()=>n_,createCreateUnit:()=>mv,createCross:()=>v_,createCsc:()=>Vd,createCsch:()=>T1,createCtranspose:()=>Pa,createCube:()=>A0,createCumSum:()=>xy,createCumSumTransform:()=>mA,createDeepEqual:()=>mc,createDenseMatrixClass:()=>Nf,createDerivative:()=>YC,createDet:()=>vw,createDeuteronMass:()=>Qo,createDiag:()=>i_,createDiff:()=>Sy,createDiffTransform:()=>t1,createDistance:()=>gb,createDivide:()=>xC,createDivideScalar:()=>k1,createDot:()=>jh,createDotDivide:()=>Kg,createDotMultiply:()=>Mb,createDotPow:()=>iu,createE:()=>qs,createEfimovFactor:()=>Ue,createEigs:()=>jb,createElectricConstant:()=>Td,createElectronMass:()=>rr,createElementaryCharge:()=>Yl,createEqual:()=>V1,createEqualScalar:()=>Rv,createEqualText:()=>Qs,createErf:()=>Q_,createEvaluate:()=>BI,createExp:()=>F0,createExpm:()=>S_,createExpm1:()=>Um,createFactorial:()=>Dd,createFalse:()=>md,createFaraday:()=>Ut,createFermiCoupling:()=>or,createFft:()=>dd,createFibonacciHeapClass:()=>Ib,createFilter:()=>mD,createFilterTransform:()=>lA,createFineStructure:()=>ia,createFirstRadiation:()=>Rn,createFix:()=>Ab,createFlatten:()=>$m,createFloor:()=>Xm,createForEach:()=>Oh,createForEachTransform:()=>G2,createFormat:()=>_D,createFraction:()=>pp,createFractionClass:()=>bg,createFreqz:()=>c0,createFunctionAssignmentNode:()=>OI,createFunctionNode:()=>iM,createGamma:()=>kb,createGasConstant:()=>Y,createGcd:()=>eC,createGetMatrixDataType:()=>p1,createGravitationConstant:()=>kc,createGravity:()=>Yr,createHartreeEnergy:()=>La,createHasNumericValue:()=>U1,createHelp:()=>aA,createHelpClass:()=>aM,createHex:()=>Pv,createHypot:()=>Ty,createI:()=>id,createIdentity:()=>$a,createIfft:()=>hv,createIm:()=>Og,createImmutableDenseMatrixClass:()=>_b,createIndex:()=>By,createIndexClass:()=>tv,createIndexNode:()=>JT,createIndexTransform:()=>gA,createInfinity:()=>gd,createIntersect:()=>og,createInv:()=>Ju,createInverseConductanceQuantum:()=>hf,createInvmod:()=>Cw,createIsInteger:()=>rm,createIsNaN:()=>M1,createIsNegative:()=>Bv,createIsNumeric:()=>tp,createIsPositive:()=>ad,createIsPrime:()=>ND,createIsZero:()=>Ng,createKldivergence:()=>Ub,createKlitzing:()=>Re,createKron:()=>kh,createLN10:()=>su,createLN2:()=>Bu,createLOG10E:()=>xa,createLOG2E:()=>Is,createLarger:()=>My,createLargerEq:()=>fy,createLcm:()=>Vy,createLeafCount:()=>$I,createLeftShift:()=>py,createLgamma:()=>B0,createLog:()=>u_,createLog10:()=>ty,createLog1p:()=>jy,createLog2:()=>hl,createLoschmidt:()=>Kn,createLsolve:()=>my,createLsolveAll:()=>Ay,createLup:()=>Gy,createLusolve:()=>EC,createLyap:()=>mo,createMad:()=>zb,createMagneticConstant:()=>kd,createMagneticFluxQuantum:()=>_e,createMap:()=>Ou,createMapTransform:()=>K2,createMatrix:()=>Wg,createMatrixClass:()=>Ch,createMatrixFromColumns:()=>Oa,createMatrixFromFunction:()=>cl,createMatrixFromRows:()=>Oy,createMax:()=>Uy,createMaxTransform:()=>tx,createMean:()=>RC,createMeanTransform:()=>uE,createMedian:()=>wm,createMin:()=>rC,createMinTransform:()=>pA,createMod:()=>Ey,createMode:()=>np,createMolarMass:()=>Si,createMolarMassC12:()=>oi,createMolarPlanckConstant:()=>Ce,createMolarVolume:()=>ue,createMultinomial:()=>Jy,createMultiply:()=>bb,createMultiplyScalar:()=>m1,createNaN:()=>Eu,createNeutronMass:()=>ll,createNode:()=>DI,createNorm:()=>ye,createNot:()=>Wm,createNthRoot:()=>nS,createNthRoots:()=>ng,createNuclearMagneton:()=>Dt,createNull:()=>Ld,createNumber:()=>xD,createNumeric:()=>N1,createObjectNode:()=>n2,createOct:()=>Lp,createOnes:()=>ob,createOperatorNode:()=>$T,createOr:()=>rv,createOrTransform:()=>Q2,createParenthesisNode:()=>SI,createParse:()=>rM,createParser:()=>Zw,createParserClass:()=>Zb,createPartitionSelect:()=>Db,createPermutations:()=>e0,createPhi:()=>Xc,createPi:()=>Pu,createPickRandom:()=>v1,createPinv:()=>Jl,createPlanckCharge:()=>Hl,createPlanckConstant:()=>El,createPlanckLength:()=>rs,createPlanckMass:()=>ls,createPlanckTemperature:()=>dc,createPlanckTime:()=>Zo,createPolynomialRoot:()=>t0,createPow:()=>zh,createPrint:()=>$v,createPrintTransform:()=>uA,createProd:()=>$d,createProtonMass:()=>vs,createQr:()=>mm,createQuantileSeq:()=>I_,createQuantileSeqTransform:()=>l,createQuantumOfCirculation:()=>Sa,createRandom:()=>Lh,createRandomInt:()=>fp,createRange:()=>nu,createRangeClass:()=>If,createRangeNode:()=>QT,createRangeTransform:()=>_A,createRationalize:()=>uM,createRe:()=>SD,createReducedPlanckConstant:()=>uc,createRelationalNode:()=>HT,createReplacer:()=>io,createReshape:()=>Zu,createResize:()=>W1,createResolve:()=>Xw,createResultSet:()=>xr,createReviver:()=>YT,createRightArithShift:()=>H1,createRightLogShift:()=>d_,createRotate:()=>si,createRotationMatrix:()=>ht,createRound:()=>z1,createRow:()=>ym,createRowTransform:()=>yA,createRydberg:()=>$o,createSQRT1_2:()=>vd,createSQRT2:()=>Vu,createSackurTetrode:()=>Ie,createSchur:()=>yn,createSec:()=>$0,createSech:()=>Qv,createSecondRadiation:()=>Ze,createSetCartesian:()=>Fb,createSetDifference:()=>Hh,createSetDistinct:()=>xw,createSetIntersect:()=>w_,createSetIsSubset:()=>Wh,createSetMultiplicity:()=>cd,createSetPowerset:()=>sg,createSetSize:()=>Vb,createSetSymDifference:()=>hh,createSetUnion:()=>fg,createSign:()=>Hm,createSimplify:()=>VI,createSimplifyConstant:()=>sM,createSimplifyCore:()=>PI,createSin:()=>lm,createSinh:()=>ay,createSize:()=>bf,createSlu:()=>h_,createSmaller:()=>jf,createSmallerEq:()=>Ys,createSolveODE:()=>IC,createSort:()=>$f,createSpaClass:()=>C_,createSparse:()=>Z0,createSparseMatrixClass:()=>H0,createSpeedOfLight:()=>Ed,createSplitUnit:()=>kg,createSqrt:()=>zm,createSqrtm:()=>pg,createSquare:()=>TD,createSqueeze:()=>Zv,createStd:()=>g,createStdTransform:()=>ae,createStefanBoltzmann:()=>kt,createStirlingS2:()=>OC,createString:()=>G0,createSubset:()=>ov,createSubsetTransform:()=>hA,createSubtract:()=>Vp,createSubtractScalar:()=>Cd,createSum:()=>ig,createSumTransform:()=>vA,createSylvester:()=>jr,createSymbolNode:()=>NI,createSymbolicEqual:()=>fF,createTan:()=>zv,createTanh:()=>Vg,createTau:()=>Lc,createThomsonCrossSection:()=>Mc,createTo:()=>s_,createTrace:()=>vm,createTranspose:()=>Hg,createTrue:()=>Su,createTypeOf:()=>rf,createTyped:()=>Xl,createUnaryMinus:()=>jg,createUnaryPlus:()=>_y,createUnequal:()=>Rb,createUnitClass:()=>cf,createUnitFunction:()=>mh,createUppercaseE:()=>pu,createUppercasePi:()=>Sd,createUsolve:()=>yy,createUsolveAll:()=>Fs,createVacuumImpedance:()=>Pc,createVariance:()=>A_,createVarianceTransform:()=>w,createVersion:()=>hu,createWeakMixingAngle:()=>yc,createWienDisplacement:()=>rn,createXgcd:()=>Kr,createXor:()=>Zg,createZeros:()=>jD,createZeta:()=>x,createZpk2tf:()=>rg});var M={relTol:1e-12,absTol:1e-15,matrix:"Matrix",number:"number",numberFallback:"number",precision:64,predictable:!1,randomSeed:null};function X(p,m){if(Q(p,m))return p[m];throw"function"==typeof p[m]&&he(p,m)?new Error('Cannot access method "'+m+'" as a property'):new Error('No access to property "'+m+'"')}function ie(p,m,b){if(Q(p,m))return p[m]=b,b;throw new Error('No access to property "'+m+'"')}function Q(p,m){return!(!function q(p){return"object"==typeof p&&p&&p.constructor===Object}(p)&&!Array.isArray(p)||!Jt(oe,m)&&(m in Object.prototype||m in Function.prototype))}function he(p,m){return!(null==p||"function"!=typeof p[m]||Jt(p,m)&&Object.getPrototypeOf&&m in Object.getPrototypeOf(p)||!Jt(Z,m)&&(m in Object.prototype||m in Function.prototype))}var oe={length:!0,name:!0},Z={toString:!0,valueOf:!0,toLocaleString:!0};class ce{constructor(m){this.wrappedObject=m,this[Symbol.iterator]=this.entries}keys(){return Object.keys(this.wrappedObject).filter(m=>this.has(m)).values()}get(m){return X(this.wrappedObject,m)}set(m,b){return ie(this.wrappedObject,m,b),this}has(m){return Q(this.wrappedObject,m)&&m in this.wrappedObject}entries(){return je(this.keys(),m=>[m,this.get(m)])}forEach(m){for(var b of this.keys())m(this.get(b),b,this)}delete(m){Q(this.wrappedObject,m)&&delete this.wrappedObject[m]}clear(){for(var m of this.keys())this.delete(m)}get size(){return Object.keys(this.wrappedObject).length}}class le{constructor(m,b,_){this.a=m,this.b=b,this.bKeys=_,this[Symbol.iterator]=this.entries}get(m){return this.bKeys.has(m)?this.b.get(m):this.a.get(m)}set(m,b){return this.bKeys.has(m)?this.b.set(m,b):this.a.set(m,b),this}has(m){return this.b.has(m)||this.a.has(m)}keys(){return new Set([...this.a.keys(),...this.b.keys()])[Symbol.iterator]()}entries(){return je(this.keys(),m=>[m,this.get(m)])}forEach(m){for(var b of this.keys())m(this.get(b),b,this)}delete(m){return this.bKeys.has(m)?this.b.delete(m):this.a.delete(m)}clear(){this.a.clear(),this.b.clear()}get size(){return[...this.keys()].length}}function je(p,m){return{next:()=>{var b=p.next();return b.done?b:{value:m(b.value),done:!1}}}}function Et(){return new Map}function wt(p){if(!p)return Et();if(Cn(p))return p;if(on(p))return new ce(p);throw new Error("createMap can create maps from objects or Maps")}function ct(p){return"number"==typeof p}function en(p){return!(!p||"object"!=typeof p||"function"!=typeof p.constructor)&&(!0===p.isBigNumber&&"object"==typeof p.constructor.prototype&&!0===p.constructor.prototype.isBigNumber||"function"==typeof p.constructor.isDecimal&&!0===p.constructor.isDecimal(p))}function an(p){return"bigint"==typeof p}function un(p){return p&&"object"==typeof p&&!0===Object.getPrototypeOf(p).isComplex||!1}function vn(p){return p&&"object"==typeof p&&!0===Object.getPrototypeOf(p).isFraction||!1}function Pt(p){return p&&!0===p.constructor.prototype.isUnit||!1}function Ae(p){return"string"==typeof p}var dt=Array.isArray;function ut(p){return p&&!0===p.constructor.prototype.isMatrix||!1}function Mt(p){return Array.isArray(p)||ut(p)}function Wt(p){return p&&p.isDenseMatrix&&!0===p.constructor.prototype.isMatrix||!1}function It(p){return p&&p.isSparseMatrix&&!0===p.constructor.prototype.isMatrix||!1}function Vn(p){return p&&!0===p.constructor.prototype.isRange||!1}function pn(p){return p&&!0===p.constructor.prototype.isIndex||!1}function Wn(p){return"boolean"==typeof p}function ji(p){return p&&!0===p.constructor.prototype.isResultSet||!1}function An(p){return p&&!0===p.constructor.prototype.isHelp||!1}function St(p){return"function"==typeof p}function qt(p){return p instanceof Date}function Ht(p){return p instanceof RegExp}function on(p){return!(!p||"object"!=typeof p||p.constructor!==Object||un(p)||vn(p))}function Cn(p){return!!p&&(p instanceof Map||p instanceof ce||"function"==typeof p.set&&"function"==typeof p.get&&"function"==typeof p.keys&&"function"==typeof p.has)}function tn(p){return Cn(p)&&Cn(p.a)&&Cn(p.b)}function fi(p){return Cn(p)&&on(p.wrappedObject)}function Zn(p){return null===p}function Dn(p){return void 0===p}function gn(p){return p&&!0===p.isAccessorNode&&!0===p.constructor.prototype.isNode||!1}function Nn(p){return p&&!0===p.isArrayNode&&!0===p.constructor.prototype.isNode||!1}function Yn(p){return p&&!0===p.isAssignmentNode&&!0===p.constructor.prototype.isNode||!1}function cr(p){return p&&!0===p.isBlockNode&&!0===p.constructor.prototype.isNode||!1}function Ai(p){return p&&!0===p.isConditionalNode&&!0===p.constructor.prototype.isNode||!1}function Qi(p){return p&&!0===p.isConstantNode&&!0===p.constructor.prototype.isNode||!1}function Xr(p){return Qi(p)||ci(p)&&1===p.args.length&&Qi(p.args[0])&&"-+~".includes(p.op)}function Ur(p){return p&&!0===p.isFunctionAssignmentNode&&!0===p.constructor.prototype.isNode||!1}function eo(p){return p&&!0===p.isFunctionNode&&!0===p.constructor.prototype.isNode||!1}function as(p){return p&&!0===p.isIndexNode&&!0===p.constructor.prototype.isNode||!1}function uo(p){return p&&!0===p.isNode&&!0===p.constructor.prototype.isNode||!1}function mi(p){return p&&!0===p.isObjectNode&&!0===p.constructor.prototype.isNode||!1}function ci(p){return p&&!0===p.isOperatorNode&&!0===p.constructor.prototype.isNode||!1}function yt(p){return p&&!0===p.isParenthesisNode&&!0===p.constructor.prototype.isNode||!1}function hn(p){return p&&!0===p.isRangeNode&&!0===p.constructor.prototype.isNode||!1}function Gt(p){return p&&!0===p.isRelationalNode&&!0===p.constructor.prototype.isNode||!1}function Gn(p){return p&&!0===p.isSymbolNode&&!0===p.constructor.prototype.isNode||!1}function ri(p){return p&&!0===p.constructor.prototype.isChain||!1}function pi(p){var m=typeof p;return"object"===m?null===p?"null":en(p)?"BigNumber":p.constructor&&p.constructor.name?p.constructor.name:"Object":m}function At(p){var m=typeof p;if("number"===m||"bigint"===m||"string"===m||"boolean"===m||null==p)return p;if("function"==typeof p.clone)return p.clone();if(Array.isArray(p))return p.map(function(b){return At(b)});if(p instanceof Date)return new Date(p.valueOf());if(en(p))return p;if(on(p))return function Bn(p,m){var b={};for(var _ in p)Jt(p,_)&&(b[_]=m(p[_]));return b}(p,At);throw new TypeError("Cannot clone: unknown type of value (value: ".concat(p,")"))}function Mn(p,m){for(var b in m)Jt(m,b)&&(p[b]=m[b]);return p}function ni(p,m){if(Array.isArray(m))throw new TypeError("Arrays are not supported by deepExtend");for(var b in m)if(Jt(m,b)&&!(b in Object.prototype)&&!(b in Function.prototype))if(m[b]&&m[b].constructor===Object)void 0===p[b]&&(p[b]={}),p[b]&&p[b].constructor===Object?ni(p[b],m[b]):p[b]=m[b];else{if(Array.isArray(m[b]))throw new TypeError("Arrays are not supported by deepExtend");p[b]=m[b]}return p}function qn(p,m){var b,_,y;if(Array.isArray(p)){if(!Array.isArray(m)||p.length!==m.length)return!1;for(_=0,y=p.length;_<y;_++)if(!qn(p[_],m[_]))return!1;return!0}if("function"==typeof p)return p===m;if(p instanceof Object){if(Array.isArray(m)||!(m instanceof Object))return!1;for(b in p)if(!(b in m)||!qn(p[b],m[b]))return!1;for(b in m)if(!(b in p))return!1;return!0}return p===m}function Ti(p){var m={};return Bi(p,m),m}function Bi(p,m){for(var b in p)if(Jt(p,b)){var _=p[b];"object"==typeof _&&null!==_?Bi(_,m):m[b]=_}}function Ii(p,m,b){var y,_=!0;Object.defineProperty(p,m,{get:function(){return _&&(y=b(),_=!1),y},set:function(A){y=A,_=!1},configurable:!0,enumerable:!0})}function Jt(p,m){return p&&Object.hasOwnProperty.call(p,m)}var mt=["Matrix","Array"],bt=["number","BigNumber","Fraction"];function nn(p,m){function b(_){if(_){if(void 0!==_.epsilon){console.warn('Warning: The configuration option "epsilon" is deprecated. Use "relTol" and "absTol" instead.');var y=At(_);return y.relTol=_.epsilon,y.absTol=.001*_.epsilon,delete y.epsilon,b(y)}var C=At(p);Jn(_,"matrix",mt),Jn(_,"number",bt),ni(p,_);var A=At(p),k=At(_);return m("config",A,C,k),A}return At(p)}return b.MATRIX_OPTIONS=mt,b.NUMBER_OPTIONS=bt,Object.keys(M).forEach(_=>{Object.defineProperty(b,_,{get:()=>p[_],enumerable:!0,configurable:!0})}),b}function Jn(p,m,b){void 0!==p[m]&&!b.includes(p[m])&&console.warn('Warning: Unknown value "'+p[m]+'" for configuration option "'+m+'". Available options: '+b.map(_=>JSON.stringify(_)).join(", ")+".")}var Sn=function(m){if(m)throw new Error("The global config is readonly. \nPlease create a mathjs instance if you want to change the default configuration. \nExample:\n\n import { create, all } from 'mathjs';\n const mathjs = create(all);\n mathjs.config({ number: 'BigNumber' });\n");return Object.freeze(M)};e(Sn,M,{MATRIX_OPTIONS:mt,NUMBER_OPTIONS:bt});var ol,Va,_r=9e15,qr=1e9,Bo="0123456789abcdef",Eo="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",Ro="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",Ls={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-_r,maxE:_r,crypto:!1},Ao=!0,za="[DecimalError] ",vl=za+"Invalid argument: ",Na=za+"Precision limit exceeded",_l=za+"crypto unavailable",gs="[object Decimal]",Zs=Math.floor,oa=Math.pow,no=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,xl=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,Qr=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,dl=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Ya=1e7,Lo=7,jt=Eo.length-1,In=Ro.length-1,Rt={toStringTag:gs};function jn(p){var m,b,_,y=p.length-1,C="",A=p[0];if(y>0){for(C+=A,m=1;m<y;m++)(b=Lo-(_=p[m]+"").length)&&(C+=Wi(b)),C+=_;(b=Lo-(_=(A=p[m])+"").length)&&(C+=Wi(b))}else if(0===A)return"0";for(;A%10==0;)A/=10;return C+A}function Fi(p,m,b){if(p!==~~p||p<m||p>b)throw Error(vl+p)}function Ui(p,m,b,_){var y,C,A,k;for(C=p[0];C>=10;C/=10)--m;return--m<0?(m+=Lo,y=0):(y=Math.ceil((m+1)/Lo),m%=Lo),C=oa(10,Lo-m),k=p[y]%C|0,null==_?m<3?(0==m?k=k/100|0:1==m&&(k=k/10|0),A=b<4&&99999==k||b>3&&49999==k||5e4==k||0==k):A=(b<4&&k+1==C||b>3&&k+1==C/2)&&(p[y+1]/C/100|0)==oa(10,m-2)-1||(k==C/2||0==k)&&!(p[y+1]/C/100|0):m<4?(0==m?k=k/1e3|0:1==m?k=k/100|0:2==m&&(k=k/10|0),A=(_||b<4)&&9999==k||!_&&b>3&&4999==k):A=((_||b<4)&&k+1==C||!_&&b>3&&k+1==C/2)&&(p[y+1]/C/1e3|0)==oa(10,m-3)-1,A}function ar(p,m,b){for(var _,C,y=[0],A=0,k=p.length;A<k;){for(C=y.length;C--;)y[C]*=m;for(y[0]+=Bo.indexOf(p.charAt(A++)),_=0;_<y.length;_++)y[_]>b-1&&(void 0===y[_+1]&&(y[_+1]=0),y[_+1]+=y[_]/b|0,y[_]%=b)}return y.reverse()}Rt.absoluteValue=Rt.abs=function(){var p=new this.constructor(this);return p.s<0&&(p.s=1),Tt(p)},Rt.ceil=function(){return Tt(new this.constructor(this),this.e+1,2)},Rt.clampedTo=Rt.clamp=function(p,m){var _=this,y=_.constructor;if(p=new y(p),m=new y(m),!p.s||!m.s)return new y(NaN);if(p.gt(m))throw Error(vl+m);return _.cmp(p)<0?p:_.cmp(m)>0?m:new y(_)},Rt.comparedTo=Rt.cmp=function(p){var m,b,_,y,C=this,A=C.d,k=(p=new C.constructor(p)).d,R=C.s,O=p.s;if(!A||!k)return R&&O?R!==O?R:A===k?0:!A^R<0?1:-1:NaN;if(!A[0]||!k[0])return A[0]?R:k[0]?-O:0;if(R!==O)return R;if(C.e!==p.e)return C.e>p.e^R<0?1:-1;for(m=0,b=(_=A.length)<(y=k.length)?_:y;m<b;++m)if(A[m]!==k[m])return A[m]>k[m]^R<0?1:-1;return _===y?0:_>y^R<0?1:-1},Rt.cosine=Rt.cos=function(){var p,m,b=this,_=b.constructor;return b.d?b.d[0]?(m=_.rounding,_.precision=(p=_.precision)+Math.max(b.e,b.sd())+Lo,_.rounding=1,b=function er(p,m){var b,_,y;if(m.isZero())return m;(_=m.d.length)<32?y=(1/Ws(4,b=Math.ceil(_/3))).toString():(b=16,y="2.3283064365386962890625e-10"),p.precision+=b,m=ds(p,1,m.times(y),new p(1));for(var C=b;C--;){var A=m.times(m);m=A.times(A).minus(A).times(8).plus(1)}return p.precision-=b,m}(_,es(_,b)),_.precision=p,_.rounding=m,Tt(2==Va||3==Va?b.neg():b,p,m,!0)):new _(1):new _(NaN)},Rt.cubeRoot=Rt.cbrt=function(){var p,m,b,_,y,C,A,k,R,O,F=this,B=F.constructor;if(!F.isFinite()||F.isZero())return new B(F);for(Ao=!1,(C=F.s*oa(F.s*F,.3333333333333333))&&Math.abs(C)!=1/0?_=new B(C.toString()):(b=jn(F.d),(C=((p=F.e)-b.length+1)%3)&&(b+=1==C||-2==C?"0":"00"),C=oa(b,.3333333333333333),p=Zs((p+1)/3)-(p%3==(p<0?-1:2)),(_=new B(b=C==1/0?"5e"+p:(b=C.toExponential()).slice(0,b.indexOf("e")+1)+p)).s=F.s),A=(p=B.precision)+3;;)if(O=(R=(k=_).times(k).times(k)).plus(F),_=Or(O.plus(F).times(k),O.plus(R),A+2,1),jn(k.d).slice(0,A)===(b=jn(_.d)).slice(0,A)){if("9999"!=(b=b.slice(A-3,A+1))&&(y||"4999"!=b)){(!+b||!+b.slice(1)&&"5"==b.charAt(0))&&(Tt(_,p+1,1),m=!_.times(_).times(_).eq(F));break}if(!y&&(Tt(k,p+1,0),k.times(k).times(k).eq(F))){_=k;break}A+=4,y=1}return Ao=!0,Tt(_,p,B.rounding,m)},Rt.decimalPlaces=Rt.dp=function(){var p,m=this.d,b=NaN;if(m){if(b=((p=m.length-1)-Zs(this.e/Lo))*Lo,p=m[p])for(;p%10==0;p/=10)b--;b<0&&(b=0)}return b},Rt.dividedBy=Rt.div=function(p){return Or(this,new this.constructor(p))},Rt.dividedToIntegerBy=Rt.divToInt=function(p){var b=this.constructor;return Tt(Or(this,new b(p),0,1,1),b.precision,b.rounding)},Rt.equals=Rt.eq=function(p){return 0===this.cmp(p)},Rt.floor=function(){return Tt(new this.constructor(this),this.e+1,3)},Rt.greaterThan=Rt.gt=function(p){return this.cmp(p)>0},Rt.greaterThanOrEqualTo=Rt.gte=function(p){var m=this.cmp(p);return 1==m||0===m},Rt.hyperbolicCosine=Rt.cosh=function(){var p,m,b,_,y,C=this,A=C.constructor,k=new A(1);if(!C.isFinite())return new A(C.s?1/0:NaN);if(C.isZero())return k;_=A.rounding,A.precision=(b=A.precision)+Math.max(C.e,C.sd())+4,A.rounding=1,(y=C.d.length)<32?m=(1/Ws(4,p=Math.ceil(y/3))).toString():(p=16,m="2.3283064365386962890625e-10"),C=ds(A,1,C.times(m),new A(1),!0);for(var R,O=p,F=new A(8);O--;)R=C.times(C),C=k.minus(R.times(F.minus(R.times(F))));return Tt(C,A.precision=b,A.rounding=_,!0)},Rt.hyperbolicSine=Rt.sinh=function(){var p,m,b,_,y=this,C=y.constructor;if(!y.isFinite()||y.isZero())return new C(y);if(b=C.rounding,C.precision=(m=C.precision)+Math.max(y.e,y.sd())+4,C.rounding=1,(_=y.d.length)<3)y=ds(C,2,y,y,!0);else{p=1.4*Math.sqrt(_),y=ds(C,2,y=y.times(1/Ws(5,p=p>16?16:0|p)),y,!0);for(var A,k=new C(5),R=new C(16),O=new C(20);p--;)A=y.times(y),y=y.times(k.plus(A.times(R.times(A).plus(O))))}return C.precision=m,C.rounding=b,Tt(y,m,b,!0)},Rt.hyperbolicTangent=Rt.tanh=function(){var p,m,b=this,_=b.constructor;return b.isFinite()?b.isZero()?new _(b):(m=_.rounding,_.precision=(p=_.precision)+7,_.rounding=1,Or(b.sinh(),b.cosh(),_.precision=p,_.rounding=m)):new _(b.s)},Rt.inverseCosine=Rt.acos=function(){var p,m=this,b=m.constructor,_=m.abs().cmp(1),y=b.precision,C=b.rounding;return-1!==_?0===_?m.isNeg()?Un(b,y,C):new b(0):new b(NaN):m.isZero()?Un(b,y+4,C).times(.5):(b.precision=y+6,b.rounding=1,m=m.asin(),p=Un(b,y+4,C).times(.5),b.precision=y,b.rounding=C,p.minus(m))},Rt.inverseHyperbolicCosine=Rt.acosh=function(){var p,m,b=this,_=b.constructor;return b.lte(1)?new _(b.eq(1)?0:NaN):b.isFinite()?(m=_.rounding,_.precision=(p=_.precision)+Math.max(Math.abs(b.e),b.sd())+4,_.rounding=1,Ao=!1,b=b.times(b).minus(1).sqrt().plus(b),Ao=!0,_.precision=p,_.rounding=m,b.ln()):new _(b)},Rt.inverseHyperbolicSine=Rt.asinh=function(){var p,m,b=this,_=b.constructor;return!b.isFinite()||b.isZero()?new _(b):(m=_.rounding,_.precision=(p=_.precision)+2*Math.max(Math.abs(b.e),b.sd())+6,_.rounding=1,Ao=!1,b=b.times(b).plus(1).sqrt().plus(b),Ao=!0,_.precision=p,_.rounding=m,b.ln())},Rt.inverseHyperbolicTangent=Rt.atanh=function(){var p,m,b,_,y=this,C=y.constructor;return y.isFinite()?y.e>=0?new C(y.abs().eq(1)?y.s/0:y.isZero()?y:NaN):(p=C.precision,m=C.rounding,_=y.sd(),Math.max(_,p)<2*-y.e-1?Tt(new C(y),p,m,!0):(C.precision=b=_-y.e,y=Or(y.plus(1),new C(1).minus(y),b+p,1),C.precision=p+4,C.rounding=1,y=y.ln(),C.precision=p,C.rounding=m,y.times(.5))):new C(NaN)},Rt.inverseSine=Rt.asin=function(){var p,m,b,_,y=this,C=y.constructor;return y.isZero()?new C(y):(m=y.abs().cmp(1),b=C.precision,_=C.rounding,-1!==m?0===m?((p=Un(C,b+4,_).times(.5)).s=y.s,p):new C(NaN):(C.precision=b+6,C.rounding=1,y=y.div(new C(1).minus(y.times(y)).sqrt().plus(1)).atan(),C.precision=b,C.rounding=_,y.times(2)))},Rt.inverseTangent=Rt.atan=function(){var p,m,b,_,y,C,A,k,R,O=this,F=O.constructor,B=F.precision,H=F.rounding;if(O.isFinite()){if(O.isZero())return new F(O);if(O.abs().eq(1)&&B+4<=In)return(A=Un(F,B+4,H).times(.25)).s=O.s,A}else{if(!O.s)return new F(NaN);if(B+4<=In)return(A=Un(F,B+4,H).times(.5)).s=O.s,A}for(F.precision=k=B+10,F.rounding=1,p=b=Math.min(28,k/Lo+2|0);p;--p)O=O.div(O.times(O).plus(1).sqrt().plus(1));for(Ao=!1,m=Math.ceil(k/Lo),_=1,R=O.times(O),A=new F(O),y=O;-1!==p;)if(y=y.times(R),C=A.minus(y.div(_+=2)),y=y.times(R),void 0!==(A=C.plus(y.div(_+=2))).d[m])for(p=m;A.d[p]===C.d[p]&&p--;);return b&&(A=A.times(2<<b-1)),Ao=!0,Tt(A,F.precision=B,F.rounding=H,!0)},Rt.isFinite=function(){return!!this.d},Rt.isInteger=Rt.isInt=function(){return!!this.d&&Zs(this.e/Lo)>this.d.length-2},Rt.isNaN=function(){return!this.s},Rt.isNegative=Rt.isNeg=function(){return this.s<0},Rt.isPositive=Rt.isPos=function(){return this.s>0},Rt.isZero=function(){return!!this.d&&0===this.d[0]},Rt.lessThan=Rt.lt=function(p){return this.cmp(p)<0},Rt.lessThanOrEqualTo=Rt.lte=function(p){return this.cmp(p)<1},Rt.logarithm=Rt.log=function(p){var m,b,_,y,C,A,k,R,O=this,F=O.constructor,B=F.precision,H=F.rounding;if(null==p)p=new F(10),m=!0;else{if(b=(p=new F(p)).d,p.s<0||!b||!b[0]||p.eq(1))return new F(NaN);m=p.eq(10)}if(b=O.d,O.s<0||!b||!b[0]||O.eq(1))return new F(b&&!b[0]?-1/0:1!=O.s?NaN:b?0:1/0);if(m)if(b.length>1)C=!0;else{for(y=b[0];y%10==0;)y/=10;C=1!==y}if(Ao=!1,A=Mo(O,k=B+5),_=m?Ri(F,k+10):Mo(p,k),Ui((R=Or(A,_,k,1)).d,y=B,H))do{if(A=Mo(O,k+=10),_=m?Ri(F,k+10):Mo(p,k),R=Or(A,_,k,1),!C){+jn(R.d).slice(y+1,y+15)+1==1e14&&(R=Tt(R,B+1,0));break}}while(Ui(R.d,y+=10,H));return Ao=!0,Tt(R,B,H)},Rt.minus=Rt.sub=function(p){var m,b,_,y,C,A,k,R,O,F,B,H,G=this,J=G.constructor;if(p=new J(p),!G.d||!p.d)return G.s&&p.s?G.d?p.s=-p.s:p=new J(p.d||G.s!==p.s?G:NaN):p=new J(NaN),p;if(G.s!=p.s)return p.s=-p.s,G.plus(p);if(H=p.d,k=J.precision,R=J.rounding,!(O=G.d)[0]||!H[0]){if(H[0])p.s=-p.s;else{if(!O[0])return new J(3===R?-0:0);p=new J(G)}return Ao?Tt(p,k,R):p}if(b=Zs(p.e/Lo),F=Zs(G.e/Lo),O=O.slice(),C=F-b){for((B=C<0)?(m=O,C=-C,A=H.length):(m=H,b=F,A=O.length),C>(_=Math.max(Math.ceil(k/Lo),A)+2)&&(C=_,m.length=1),m.reverse(),_=C;_--;)m.push(0);m.reverse()}else{for((B=(_=O.length)<(A=H.length))&&(A=_),_=0;_<A;_++)if(O[_]!=H[_]){B=O[_]<H[_];break}C=0}for(B&&(m=O,O=H,H=m,p.s=-p.s),_=H.length-(A=O.length);_>0;--_)O[A++]=0;for(_=H.length;_>C;){if(O[--_]<H[_]){for(y=_;y&&0===O[--y];)O[y]=Ya-1;--O[y],O[_]+=Ya}O[_]-=H[_]}for(;0===O[--A];)O.pop();for(;0===O[0];O.shift())--b;return O[0]?(p.d=O,p.e=Tn(O,b),Ao?Tt(p,k,R):p):new J(3===R?-0:0)},Rt.modulo=Rt.mod=function(p){var m,b=this,_=b.constructor;return p=new _(p),!b.d||!p.s||p.d&&!p.d[0]?new _(NaN):!p.d||b.d&&!b.d[0]?Tt(new _(b),_.precision,_.rounding):(Ao=!1,9==_.modulo?(m=Or(b,p.abs(),0,3,1)).s*=p.s:m=Or(b,p,0,_.modulo,1),m=m.times(p),Ao=!0,b.minus(m))},Rt.naturalExponential=Rt.exp=function(){return vr(this)},Rt.naturalLogarithm=Rt.ln=function(){return Mo(this)},Rt.negated=Rt.neg=function(){var p=new this.constructor(this);return p.s=-p.s,Tt(p)},Rt.plus=Rt.add=function(p){var m,b,_,y,C,A,k,R,O,F,B=this,H=B.constructor;if(p=new H(p),!B.d||!p.d)return B.s&&p.s?B.d||(p=new H(p.d||B.s===p.s?B:NaN)):p=new H(NaN),p;if(B.s!=p.s)return p.s=-p.s,B.minus(p);if(F=p.d,k=H.precision,R=H.rounding,!(O=B.d)[0]||!F[0])return F[0]||(p=new H(B)),Ao?Tt(p,k,R):p;if(C=Zs(B.e/Lo),_=Zs(p.e/Lo),O=O.slice(),y=C-_){for(y<0?(b=O,y=-y,A=F.length):(b=F,_=C,A=O.length),y>(A=(C=Math.ceil(k/Lo))>A?C+1:A+1)&&(y=A,b.length=1),b.reverse();y--;)b.push(0);b.reverse()}for((A=O.length)-(y=F.length)<0&&(y=A,b=F,F=O,O=b),m=0;y;)m=(O[--y]=O[y]+F[y]+m)/Ya|0,O[y]%=Ya;for(m&&(O.unshift(m),++_),A=O.length;0==O[--A];)O.pop();return p.d=O,p.e=Tn(O,_),Ao?Tt(p,k,R):p},Rt.precision=Rt.sd=function(p){var m,b=this;if(void 0!==p&&p!==!!p&&1!==p&&0!==p)throw Error(vl+p);return b.d?(m=Yi(b.d),p&&b.e+1>m&&(m=b.e+1)):m=NaN,m},Rt.round=function(){var p=this,m=p.constructor;return Tt(new m(p),p.e+1,m.rounding)},Rt.sine=Rt.sin=function(){var p,m,b=this,_=b.constructor;return b.isFinite()?b.isZero()?new _(b):(m=_.rounding,_.precision=(p=_.precision)+Math.max(b.e,b.sd())+Lo,_.rounding=1,b=function Js(p,m){var b,_=m.d.length;if(_<3)return m.isZero()?m:ds(p,2,m,m);b=1.4*Math.sqrt(_),m=ds(p,2,m=m.times(1/Ws(5,b=b>16?16:0|b)),m);for(var y,C=new p(5),A=new p(16),k=new p(20);b--;)y=m.times(m),m=m.times(C.plus(y.times(A.times(y).minus(k))));return m}(_,es(_,b)),_.precision=p,_.rounding=m,Tt(Va>2?b.neg():b,p,m,!0)):new _(NaN)},Rt.squareRoot=Rt.sqrt=function(){var p,m,b,_,y,C,A=this,k=A.d,R=A.e,O=A.s,F=A.constructor;if(1!==O||!k||!k[0])return new F(!O||O<0&&(!k||k[0])?NaN:k?A:1/0);for(Ao=!1,0==(O=Math.sqrt(+A))||O==1/0?(((m=jn(k)).length+R)%2==0&&(m+="0"),O=Math.sqrt(m),R=Zs((R+1)/2)-(R<0||R%2),_=new F(m=O==1/0?"5e"+R:(m=O.toExponential()).slice(0,m.indexOf("e")+1)+R)):_=new F(O.toString()),b=(R=F.precision)+3;;)if(_=(C=_).plus(Or(A,C,b+2,1)).times(.5),jn(C.d).slice(0,b)===(m=jn(_.d)).slice(0,b)){if("9999"!=(m=m.slice(b-3,b+1))&&(y||"4999"!=m)){(!+m||!+m.slice(1)&&"5"==m.charAt(0))&&(Tt(_,R+1,1),p=!_.times(_).eq(A));break}if(!y&&(Tt(C,R+1,0),C.times(C).eq(A))){_=C;break}b+=4,y=1}return Ao=!0,Tt(_,R,F.rounding,p)},Rt.tangent=Rt.tan=function(){var p,m,b=this,_=b.constructor;return b.isFinite()?b.isZero()?new _(b):(m=_.rounding,_.precision=(p=_.precision)+10,_.rounding=1,(b=b.sin()).s=1,b=Or(b,new _(1).minus(b.times(b)).sqrt(),p+10,0),_.precision=p,_.rounding=m,Tt(2==Va||4==Va?b.neg():b,p,m,!0)):new _(NaN)},Rt.times=Rt.mul=function(p){var m,b,_,y,C,A,k,R,O,F=this,B=F.constructor,H=F.d,G=(p=new B(p)).d;if(p.s*=F.s,!(H&&H[0]&&G&&G[0]))return new B(!p.s||H&&!H[0]&&!G||G&&!G[0]&&!H?NaN:H&&G?0*p.s:p.s/0);for(b=Zs(F.e/Lo)+Zs(p.e/Lo),(R=H.length)<(O=G.length)&&(C=H,H=G,G=C,A=R,R=O,O=A),C=[],_=A=R+O;_--;)C.push(0);for(_=O;--_>=0;){for(m=0,y=R+_;y>_;)k=C[y]+G[_]*H[y-_-1]+m,C[y--]=k%Ya|0,m=k/Ya|0;C[y]=(C[y]+m)%Ya|0}for(;!C[--A];)C.pop();return m?++b:C.shift(),p.d=C,p.e=Tn(C,b),Ao?Tt(p,B.precision,B.rounding):p},Rt.toBinary=function(p,m){return Ma(this,2,p,m)},Rt.toDecimalPlaces=Rt.toDP=function(p,m){var b=this,_=b.constructor;return b=new _(b),void 0===p?b:(Fi(p,0,qr),void 0===m?m=_.rounding:Fi(m,0,8),Tt(b,p+b.e+1,m))},Rt.toExponential=function(p,m){var b,_=this,y=_.constructor;return void 0===p?b=cn(_,!0):(Fi(p,0,qr),void 0===m?m=y.rounding:Fi(m,0,8),b=cn(_=Tt(new y(_),p+1,m),!0,p+1)),_.isNeg()&&!_.isZero()?"-"+b:b},Rt.toFixed=function(p,m){var b,_,y=this,C=y.constructor;return void 0===p?b=cn(y):(Fi(p,0,qr),void 0===m?m=C.rounding:Fi(m,0,8),b=cn(_=Tt(new C(y),p+y.e+1,m),!1,p+_.e+1)),y.isNeg()&&!y.isZero()?"-"+b:b},Rt.toFraction=function(p){var m,b,_,y,C,A,k,R,O,F,B,H,G=this,J=G.d,te=G.constructor;if(!J)return new te(G);if(O=b=new te(1),_=R=new te(0),C=(m=new te(_)).e=Yi(J)-G.e-1,m.d[0]=oa(10,(A=C%Lo)<0?Lo+A:A),null==p)p=C>0?m:O;else{if(!(k=new te(p)).isInt()||k.lt(O))throw Error(vl+k);p=k.gt(m)?C>0?m:O:k}for(Ao=!1,k=new te(jn(J)),F=te.precision,te.precision=C=J.length*Lo*2;B=Or(k,m,0,1,1),1!=(y=b.plus(B.times(_))).cmp(p);)b=_,_=y,O=R.plus(B.times(y=O)),R=y,m=k.minus(B.times(y=m)),k=y;return y=Or(p.minus(b),_,0,1,1),R=R.plus(y.times(O)),b=b.plus(y.times(_)),R.s=O.s=G.s,H=Or(O,_,C,1).minus(G).abs().cmp(Or(R,b,C,1).minus(G).abs())<1?[O,_]:[R,b],te.precision=F,Ao=!0,H},Rt.toHexadecimal=Rt.toHex=function(p,m){return Ma(this,16,p,m)},Rt.toNearest=function(p,m){var b=this,_=b.constructor;if(b=new _(b),null==p){if(!b.d)return b;p=new _(1),m=_.rounding}else{if(p=new _(p),void 0===m?m=_.rounding:Fi(m,0,8),!b.d)return p.s?b:p;if(!p.d)return p.s&&(p.s=b.s),p}return p.d[0]?(Ao=!1,b=Or(b,p,0,m,1).times(p),Ao=!0,Tt(b)):(p.s=b.s,b=p),b},Rt.toNumber=function(){return+this},Rt.toOctal=function(p,m){return Ma(this,8,p,m)},Rt.toPower=Rt.pow=function(p){var m,b,_,y,C,A,k=this,R=k.constructor,O=+(p=new R(p));if(!(k.d&&p.d&&k.d[0]&&p.d[0]))return new R(oa(+k,O));if((k=new R(k)).eq(1))return k;if(_=R.precision,C=R.rounding,p.eq(1))return Tt(k,_,C);if((m=Zs(p.e/Lo))>=p.d.length-1&&(b=O<0?-O:O)<=9007199254740991)return y=fr(R,k,b,_),p.s<0?new R(1).div(y):Tt(y,_,C);if((A=k.s)<0){if(m<p.d.length-1)return new R(NaN);if(1&p.d[m]||(A=1),0==k.e&&1==k.d[0]&&1==k.d.length)return k.s=A,k}return(m=0!=(b=oa(+k,O))&&isFinite(b)?new R(b+"").e:Zs(O*(Math.log("0."+jn(k.d))/Math.LN10+k.e+1)))>R.maxE+1||m<R.minE-1?new R(m>0?A/0:0):(Ao=!1,R.rounding=k.s=1,b=Math.min(12,(m+"").length),(y=vr(p.times(Mo(k,_+b)),_)).d&&Ui((y=Tt(y,_+5,1)).d,_,C)&&+jn((y=Tt(vr(p.times(Mo(k,(m=_+10)+b)),m),m+5,1)).d).slice(_+1,_+15)+1==1e14&&(y=Tt(y,_+1,0)),y.s=A,Ao=!0,R.rounding=C,Tt(y,_,C))},Rt.toPrecision=function(p,m){var b,_=this,y=_.constructor;return void 0===p?b=cn(_,_.e<=y.toExpNeg||_.e>=y.toExpPos):(Fi(p,1,qr),void 0===m?m=y.rounding:Fi(m,0,8),b=cn(_=Tt(new y(_),p,m),p<=_.e||_.e<=y.toExpNeg,p)),_.isNeg()&&!_.isZero()?"-"+b:b},Rt.toSignificantDigits=Rt.toSD=function(p,m){var _=this.constructor;return void 0===p?(p=_.precision,m=_.rounding):(Fi(p,1,qr),void 0===m?m=_.rounding:Fi(m,0,8)),Tt(new _(this),p,m)},Rt.toString=function(){var p=this,m=p.constructor,b=cn(p,p.e<=m.toExpNeg||p.e>=m.toExpPos);return p.isNeg()&&!p.isZero()?"-"+b:b},Rt.truncated=Rt.trunc=function(){return Tt(new this.constructor(this),this.e+1,1)},Rt.valueOf=Rt.toJSON=function(){var p=this,m=p.constructor,b=cn(p,p.e<=m.toExpNeg||p.e>=m.toExpPos);return p.isNeg()?"-"+b:b};var Or=function(){function p(_,y,C){var A,k=0,R=_.length;for(_=_.slice();R--;)_[R]=(A=_[R]*y+k)%C|0,k=A/C|0;return k&&_.unshift(k),_}function m(_,y,C,A){var k,R;if(C!=A)R=C>A?1:-1;else for(k=R=0;k<C;k++)if(_[k]!=y[k]){R=_[k]>y[k]?1:-1;break}return R}function b(_,y,C,A){for(var k=0;C--;)_[C]-=k,_[C]=(k=_[C]<y[C]?1:0)*A+_[C]-y[C];for(;!_[0]&&_.length>1;)_.shift()}return function(_,y,C,A,k,R){var O,F,B,H,G,J,te,be,we,Le,de,Te,De,pe,Be,We,ke,ze,et,pt,$t=_.constructor,Zt=_.s==y.s?1:-1,Kt=_.d,lt=y.d;if(!(Kt&&Kt[0]&<&<[0]))return new $t(_.s&&y.s&&(Kt?!lt||Kt[0]!=lt[0]:lt)?Kt&&0==Kt[0]||!lt?0*Zt:Zt/0:NaN);for(R?(G=1,F=_.e-y.e):(R=Ya,F=Zs(_.e/(G=Lo))-Zs(y.e/G)),et=lt.length,ke=Kt.length,Le=(we=new $t(Zt)).d=[],B=0;lt[B]==(Kt[B]||0);B++);if(lt[B]>(Kt[B]||0)&&F--,null==C?(pe=C=$t.precision,A=$t.rounding):pe=k?C+(_.e-y.e)+1:C,pe<0)Le.push(1),J=!0;else{if(pe=pe/G+2|0,B=0,1==et){for(H=0,lt=lt[0],pe++;(B<ke||H)&&pe--;B++)Le[B]=(Be=H*R+(Kt[B]||0))/lt|0,H=Be%lt|0;J=H||B<ke}else{for((H=R/(lt[0]+1)|0)>1&&(lt=p(lt,H,R),Kt=p(Kt,H,R),et=lt.length,ke=Kt.length),We=et,Te=(de=Kt.slice(0,et)).length;Te<et;)de[Te++]=0;(pt=lt.slice()).unshift(0),ze=lt[0],lt[1]>=R/2&&++ze;do{H=0,(O=m(lt,de,et,Te))<0?(De=de[0],et!=Te&&(De=De*R+(de[1]||0)),(H=De/ze|0)>1?(H>=R&&(H=R-1),1==(O=m(te=p(lt,H,R),de,be=te.length,Te=de.length))&&(H--,b(te,et<be?pt:lt,be,R))):(0==H&&(O=H=1),te=lt.slice()),(be=te.length)<Te&&te.unshift(0),b(de,te,Te,R),-1==O&&(O=m(lt,de,et,Te=de.length))<1&&(H++,b(de,et<Te?pt:lt,Te,R)),Te=de.length):0===O&&(H++,de=[0]),Le[B++]=H,O&&de[0]?de[Te++]=Kt[We]||0:(de=[Kt[We]],Te=1)}while((We++<ke||void 0!==de[0])&&pe--);J=void 0!==de[0]}Le[0]||Le.shift()}if(1==G)we.e=F,ol=J;else{for(B=1,H=Le[0];H>=10;H/=10)B++;we.e=B+F*G-1,Tt(we,k?C+we.e+1:C,A,J)}return we}}();function Tt(p,m,b,_){var y,C,A,k,R,O,F,B,H,G=p.constructor;e:if(null!=m){if(!(B=p.d))return p;for(y=1,k=B[0];k>=10;k/=10)y++;if((C=m-y)<0)C+=Lo,R=(F=B[H=0])/oa(10,y-(A=m)-1)%10|0;else if((H=Math.ceil((C+1)/Lo))>=(k=B.length)){if(!_)break e;for(;k++<=H;)B.push(0);F=R=0,y=1,A=(C%=Lo)-Lo+1}else{for(F=k=B[H],y=1;k>=10;k/=10)y++;R=(A=(C%=Lo)-Lo+y)<0?0:F/oa(10,y-A-1)%10|0}if(_=_||m<0||void 0!==B[H+1]||(A<0?F:F%oa(10,y-A-1)),O=b<4?(R||_)&&(0==b||b==(p.s<0?3:2)):R>5||5==R&&(4==b||_||6==b&&(C>0?A>0?F/oa(10,y-A):0:B[H-1])%10&1||b==(p.s<0?8:7)),m<1||!B[0])return B.length=0,O?(B[0]=oa(10,(Lo-(m-=p.e+1)%Lo)%Lo),p.e=-m||0):B[0]=p.e=0,p;if(0==C?(B.length=H,k=1,H--):(B.length=H+1,k=oa(10,Lo-C),B[H]=A>0?(F/oa(10,y-A)%oa(10,A)|0)*k:0),O)for(;;){if(0==H){for(C=1,A=B[0];A>=10;A/=10)C++;for(A=B[0]+=k,k=1;A>=10;A/=10)k++;C!=k&&(p.e++,B[0]==Ya&&(B[0]=1));break}if(B[H]+=k,B[H]!=Ya)break;B[H--]=0,k=1}for(C=B.length;0===B[--C];)B.pop()}return Ao&&(p.e>G.maxE?(p.d=null,p.e=NaN):p.e<G.minE&&(p.e=0,p.d=[0])),p}function cn(p,m,b){if(!p.isFinite())return ks(p);var _,y=p.e,C=jn(p.d),A=C.length;return m?(b&&(_=b-A)>0?C=C.charAt(0)+"."+C.slice(1)+Wi(_):A>1&&(C=C.charAt(0)+"."+C.slice(1)),C=C+(p.e<0?"e":"e+")+p.e):y<0?(C="0."+Wi(-y-1)+C,b&&(_=b-A)>0&&(C+=Wi(_))):y>=A?(C+=Wi(y+1-A),b&&(_=b-y-1)>0&&(C=C+"."+Wi(_))):((_=y+1)<A&&(C=C.slice(0,_)+"."+C.slice(_)),b&&(_=b-A)>0&&(y+1===A&&(C+="."),C+=Wi(_))),C}function Tn(p,m){var b=p[0];for(m*=Lo;b>=10;b/=10)m++;return m}function Ri(p,m,b){if(m>jt)throw Ao=!0,b&&(p.precision=b),Error(Na);return Tt(new p(Eo),m,1,!0)}function Un(p,m,b){if(m>In)throw Error(Na);return Tt(new p(Ro),m,b,!0)}function Yi(p){var m=p.length-1,b=m*Lo+1;if(m=p[m]){for(;m%10==0;m/=10)b--;for(m=p[0];m>=10;m/=10)b++}return b}function Wi(p){for(var m="";p--;)m+="0";return m}function fr(p,m,b,_){var y,C=new p(1),A=Math.ceil(_/Lo+4);for(Ao=!1;;){if(b%2&&ts((C=C.times(m)).d,A)&&(y=!0),0===(b=Zs(b/2))){b=C.d.length-1,y&&0===C.d[b]&&++C.d[b];break}ts((m=m.times(m)).d,A)}return Ao=!0,C}function Li(p){return 1&p.d[p.d.length-1]}function Vo(p,m,b){for(var _,y=new p(m[0]),C=0;++C<m.length;){if(!(_=new p(m[C])).s){y=_;break}y[b](_)&&(y=_)}return y}function vr(p,m){var b,_,y,C,A,k,R,O=0,F=0,B=0,H=p.constructor,G=H.rounding,J=H.precision;if(!p.d||!p.d[0]||p.e>17)return new H(p.d?p.d[0]?p.s<0?0:1/0:1:p.s?p.s<0?0:p:NaN);for(null==m?(Ao=!1,R=J):R=m,k=new H(.03125);p.e>-2;)p=p.times(k),B+=5;for(R+=_=Math.log(oa(2,B))/Math.LN10*2+5|0,b=C=A=new H(1),H.precision=R;;){if(C=Tt(C.times(p),R,1),b=b.times(++F),jn((k=A.plus(Or(C,b,R,1))).d).slice(0,R)===jn(A.d).slice(0,R)){for(y=B;y--;)A=Tt(A.times(A),R,1);if(null!=m)return H.precision=J,A;if(!(O<3&&Ui(A.d,R-_,G,O)))return Tt(A,H.precision=J,G,Ao=!0);H.precision=R+=10,b=C=k=new H(1),F=0,O++}A=k}}function Mo(p,m){var b,_,y,C,A,k,R,O,F,B,H,G=1,te=p,be=te.d,we=te.constructor,Le=we.rounding,de=we.precision;if(te.s<0||!be||!be[0]||!te.e&&1==be[0]&&1==be.length)return new we(be&&!be[0]?-1/0:1!=te.s?NaN:be?0:te);if(null==m?(Ao=!1,F=de):F=m,we.precision=F+=10,_=(b=jn(be)).charAt(0),!(Math.abs(C=te.e)<15e14))return O=Ri(we,F+2,de).times(C+""),te=Mo(new we(_+"."+b.slice(1)),F-10).plus(O),we.precision=de,null==m?Tt(te,de,Le,Ao=!0):te;for(;_<7&&1!=_||1==_&&b.charAt(1)>3;)_=(b=jn((te=te.times(p)).d)).charAt(0),G++;for(C=te.e,_>1?(te=new we("0."+b),C++):te=new we(_+"."+b.slice(1)),B=te,R=A=te=Or(te.minus(1),te.plus(1),F,1),H=Tt(te.times(te),F,1),y=3;;){if(A=Tt(A.times(H),F,1),jn((O=R.plus(Or(A,new we(y),F,1))).d).slice(0,F)===jn(R.d).slice(0,F)){if(R=R.times(2),0!==C&&(R=R.plus(Ri(we,F+2,de).times(C+""))),R=Or(R,new we(G),F,1),null!=m)return we.precision=de,R;if(!Ui(R.d,F-10,Le,k))return Tt(R,we.precision=de,Le,Ao=!0);we.precision=F+=10,O=A=te=Or(B.minus(1),B.plus(1),F,1),H=Tt(te.times(te),F,1),y=k=1}R=O,y+=2}}function ks(p){return String(p.s*p.s/0)}function Jo(p,m){var b,_,y;for((b=m.indexOf("."))>-1&&(m=m.replace(".","")),(_=m.search(/e/i))>0?(b<0&&(b=_),b+=+m.slice(_+1),m=m.substring(0,_)):b<0&&(b=m.length),_=0;48===m.charCodeAt(_);_++);for(y=m.length;48===m.charCodeAt(y-1);--y);if(m=m.slice(_,y)){if(y-=_,p.e=b=b-_-1,p.d=[],_=(b+1)%Lo,b<0&&(_+=Lo),_<y){for(_&&p.d.push(+m.slice(0,_)),y-=Lo;_<y;)p.d.push(+m.slice(_,_+=Lo));m=m.slice(_),_=Lo-m.length}else _-=y;for(;_--;)m+="0";p.d.push(+m),Ao&&(p.e>p.constructor.maxE?(p.d=null,p.e=NaN):p.e<p.constructor.minE&&(p.e=0,p.d=[0]))}else p.e=0,p.d=[0];return p}function ds(p,m,b,_,y){var C,A,k,R,F=p.precision,B=Math.ceil(F/Lo);for(Ao=!1,R=b.times(b),k=new p(_);;){if(A=Or(k.times(R),new p(m++*m++),F,1),k=y?_.plus(A):_.minus(A),_=Or(A.times(R),new p(m++*m++),F,1),void 0!==(A=k.plus(_)).d[B]){for(C=B;A.d[C]===k.d[C]&&C--;);if(-1==C)break}C=k,k=_,_=A,A=C}return Ao=!0,A.d.length=B+1,A}function Ws(p,m){for(var b=p;--m;)b*=p;return b}function es(p,m){var b,_=m.s<0,y=Un(p,p.precision,1),C=y.times(.5);if((m=m.abs()).lte(C))return Va=_?4:1,m;if((b=m.divToInt(y)).isZero())Va=_?3:2;else{if((m=m.minus(b.times(y))).lte(C))return Va=Li(b)?_?2:3:_?4:1,m;Va=Li(b)?_?1:4:_?3:2}return m.minus(y).abs()}function Ma(p,m,b,_){var y,C,A,k,R,O,F,B,H,G=p.constructor,J=void 0!==b;if(J?(Fi(b,1,qr),void 0===_?_=G.rounding:Fi(_,0,8)):(b=G.precision,_=G.rounding),p.isFinite()){for(J?(y=2,16==m?b=4*b-3:8==m&&(b=3*b-2)):y=m,(A=(F=cn(p)).indexOf("."))>=0&&(F=F.replace(".",""),(H=new G(1)).e=F.length-A,H.d=ar(cn(H),10,y),H.e=H.d.length),C=R=(B=ar(F,10,y)).length;0==B[--R];)B.pop();if(B[0]){if(A<0?C--:((p=new G(p)).d=B,p.e=C,B=(p=Or(p,H,b,_,0,y)).d,C=p.e,O=ol),A=B[b],k=y/2,O=O||void 0!==B[b+1],O=_<4?(void 0!==A||O)&&(0===_||_===(p.s<0?3:2)):A>k||A===k&&(4===_||O||6===_&&1&B[b-1]||_===(p.s<0?8:7)),B.length=b,O)for(;++B[--b]>y-1;)B[b]=0,b||(++C,B.unshift(1));for(R=B.length;!B[R-1];--R);for(A=0,F="";A<R;A++)F+=Bo.charAt(B[A]);if(J){if(R>1)if(16==m||8==m){for(A=16==m?4:3,--R;R%A;R++)F+="0";for(R=(B=ar(F,y,m)).length;!B[R-1];--R);for(A=1,F="1.";A<R;A++)F+=Bo.charAt(B[A])}else F=F.charAt(0)+"."+F.slice(1);F=F+(C<0?"p":"p+")+C}else if(C<0){for(;++C;)F="0"+F;F="0."+F}else if(++C>R)for(C-=R;C--;)F+="0";else C<R&&(F=F.slice(0,C)+"."+F.slice(C))}else F=J?"0p+0":"0";F=(16==m?"0x":2==m?"0b":8==m?"0o":"")+F}else F=ks(p);return p.s<0?"-"+F:F}function ts(p,m){if(p.length>m)return p.length=m,!0}function wo(p){return new this(p).abs()}function ea(p){return new this(p).acos()}function ga(p){return new this(p).acosh()}function sl(p,m){return new this(p).plus(m)}function fl(p){return new this(p).asin()}function Ia(p){return new this(p).asinh()}function al(p){return new this(p).atan()}function Kc(p){return new this(p).atanh()}function wa(p,m){p=new this(p),m=new this(m);var b,_=this.precision,y=this.rounding,C=_+4;return p.s&&m.s?p.d||m.d?!m.d||p.isZero()?(b=m.s<0?Un(this,_,y):new this(0)).s=p.s:!p.d||m.isZero()?(b=Un(this,C,1).times(.5)).s=p.s:m.s<0?(this.precision=C,this.rounding=1,b=this.atan(Or(p,m,C,1)),m=Un(this,C,1),this.precision=_,this.rounding=y,b=p.s<0?b.minus(m):b.plus(m)):b=this.atan(Or(p,m,C,1)):(b=Un(this,C,1).times(m.s>0?.25:.75)).s=p.s:b=new this(NaN),b}function Sl(p){return new this(p).cbrt()}function qc(p){return Tt(p=new this(p),p.e+1,2)}function la(p,m,b){return new this(p).clamp(m,b)}function pl(p){if(!p||"object"!=typeof p)throw Error(za+"Object expected");var m,b,_,y=!0===p.defaults,C=["precision",1,qr,"rounding",0,8,"toExpNeg",-_r,0,"toExpPos",0,_r,"maxE",0,_r,"minE",-_r,0,"modulo",0,9];for(m=0;m<C.length;m+=3)if(b=C[m],y&&(this[b]=Ls[b]),void 0!==(_=p[b])){if(!(Zs(_)===_&&_>=C[m+1]&&_<=C[m+2]))throw Error(vl+b+": "+_);this[b]=_}if(b="crypto",y&&(this[b]=Ls[b]),void 0!==(_=p[b])){if(!0!==_&&!1!==_&&0!==_&&1!==_)throw Error(vl+b+": "+_);if(_){if(!(typeof crypto<"u"&&crypto&&(crypto.getRandomValues||crypto.randomBytes)))throw Error(_l);this[b]=!0}else this[b]=!1}return this}function Sc(p){return new this(p).cos()}function Ec(p){return new this(p).cosh()}function ql(p,m){return new this(p).div(m)}function ec(p){return new this(p).exp()}function Yc(p){return Tt(p=new this(p),p.e+1,3)}function ca(){var p,m,b=new this(0);for(Ao=!1,p=0;p<arguments.length;)if((m=new this(arguments[p++])).d)b.d&&(b=b.plus(m.times(m)));else{if(m.s)return Ao=!0,new this(1/0);b=m}return Ao=!0,b.sqrt()}function Il(p){return p instanceof Ke||p&&p.toStringTag===gs||!1}function Xa(p){return new this(p).ln()}function Rl(p,m){return new this(p).log(m)}function yl(p){return new this(p).log(2)}function sa(p){return new this(p).log(10)}function Lu(){return Vo(this,arguments,"lt")}function Aa(){return Vo(this,arguments,"gt")}function ku(p,m){return new this(p).mod(m)}function Ql(p,m){return new this(p).mul(m)}function sc(p,m){return new this(p).pow(m)}function ta(p){var m,b,_,y,C=0,A=new this(1),k=[];if(void 0===p?p=this.precision:Fi(p,1,qr),_=Math.ceil(p/Lo),this.crypto)if(crypto.getRandomValues)for(m=crypto.getRandomValues(new Uint32Array(_));C<_;)(y=m[C])>=429e7?m[C]=crypto.getRandomValues(new Uint32Array(1))[0]:k[C++]=y%1e7;else{if(!crypto.randomBytes)throw Error(_l);for(m=crypto.randomBytes(_*=4);C<_;)(y=m[C]+(m[C+1]<<8)+(m[C+2]<<16)+((127&m[C+3])<<24))>=214e7?crypto.randomBytes(4).copy(m,C):(k.push(y%1e7),C+=4);C=_/4}else for(;C<_;)k[C++]=1e7*Math.random()|0;for(_=k[--C],p%=Lo,_&&p&&(y=oa(10,Lo-p),k[C]=(_/y|0)*y);0===k[C];C--)k.pop();if(C<0)b=0,k=[0];else{for(b=-1;0===k[0];b-=Lo)k.shift();for(_=1,y=k[0];y>=10;y/=10)_++;_<Lo&&(b-=Lo-_)}return A.e=b,A.d=k,A}function vc(p){return Tt(p=new this(p),p.e+1,this.rounding)}function xu(p){return(p=new this(p)).d?p.d[0]?p.s:0*p.s:p.s||NaN}function Fc(p){return new this(p).sin()}function po(p){return new this(p).sinh()}function Ll(p){return new this(p).sqrt()}function Hs(p,m){return new this(p).sub(m)}function kl(){var p=0,m=arguments,b=new this(m[p]);for(Ao=!1;b.s&&++p<m.length;)b=b.plus(m[p]);return Ao=!0,Tt(b,this.precision,this.rounding)}function Nc(p){return new this(p).tan()}function fu(p){return new this(p).tanh()}function Rc(p){return Tt(p=new this(p),p.e+1,1)}Rt[Symbol.for("nodejs.util.inspect.custom")]=Rt.toString,Rt[Symbol.toStringTag]="Decimal";var Ke=Rt.constructor=function Qc(p){var m,b,_;function y(C){var A,k,R,O=this;if(!(O instanceof y))return new y(C);if(O.constructor=y,Il(C))return O.s=C.s,void(Ao?!C.d||C.e>y.maxE?(O.e=NaN,O.d=null):C.e<y.minE?(O.e=0,O.d=[0]):(O.e=C.e,O.d=C.d.slice()):(O.e=C.e,O.d=C.d?C.d.slice():C.d));if("number"==(R=typeof C)){if(0===C)return O.s=1/C<0?-1:1,O.e=0,void(O.d=[0]);if(C<0?(C=-C,O.s=-1):O.s=1,C===~~C&&C<1e7){for(A=0,k=C;k>=10;k/=10)A++;return void(Ao?A>y.maxE?(O.e=NaN,O.d=null):A<y.minE?(O.e=0,O.d=[0]):(O.e=A,O.d=[C]):(O.e=A,O.d=[C]))}return 0*C!=0?(C||(O.s=NaN),O.e=NaN,void(O.d=null)):Jo(O,C.toString())}if("string"!==R)throw Error(vl+C);return 45===(k=C.charCodeAt(0))?(C=C.slice(1),O.s=-1):(43===k&&(C=C.slice(1)),O.s=1),dl.test(C)?Jo(O,C):function $s(p,m){var b,_,y,C,A,k,R,O,F;if(m.indexOf("_")>-1){if(m=m.replace(/(\d)_(?=\d)/g,"$1"),dl.test(m))return Jo(p,m)}else if("Infinity"===m||"NaN"===m)return+m||(p.s=NaN),p.e=NaN,p.d=null,p;if(xl.test(m))b=16,m=m.toLowerCase();else if(no.test(m))b=2;else{if(!Qr.test(m))throw Error(vl+m);b=8}for((C=m.search(/p/i))>0?(R=+m.slice(C+1),m=m.substring(2,C)):m=m.slice(2),C=m.indexOf("."),_=p.constructor,(A=C>=0)&&(C=(k=(m=m.replace(".","")).length)-C,y=fr(_,new _(b),C,2*C)),C=F=(O=ar(m,b,Ya)).length-1;0===O[C];--C)O.pop();return C<0?new _(0*p.s):(p.e=Tn(O,F),p.d=O,Ao=!1,A&&(p=Or(p,y,4*k)),R&&(p=p.times(Math.abs(R)<54?oa(2,R):Ke.pow(2,R))),Ao=!0,p)}(O,C)}if(y.prototype=Rt,y.ROUND_UP=0,y.ROUND_DOWN=1,y.ROUND_CEIL=2,y.ROUND_FLOOR=3,y.ROUND_HALF_UP=4,y.ROUND_HALF_DOWN=5,y.ROUND_HALF_EVEN=6,y.ROUND_HALF_CEIL=7,y.ROUND_HALF_FLOOR=8,y.EUCLID=9,y.config=y.set=pl,y.clone=Qc,y.isDecimal=Il,y.abs=wo,y.acos=ea,y.acosh=ga,y.add=sl,y.asin=fl,y.asinh=Ia,y.atan=al,y.atanh=Kc,y.atan2=wa,y.cbrt=Sl,y.ceil=qc,y.clamp=la,y.cos=Sc,y.cosh=Ec,y.div=ql,y.exp=ec,y.floor=Yc,y.hypot=ca,y.ln=Xa,y.log=Rl,y.log10=sa,y.log2=yl,y.max=Lu,y.min=Aa,y.mod=ku,y.mul=Ql,y.pow=sc,y.random=ta,y.round=vc,y.sign=xu,y.sin=Fc,y.sinh=po,y.sqrt=Ll,y.sub=Hs,y.sum=kl,y.tan=Nc,y.tanh=fu,y.trunc=Rc,void 0===p&&(p={}),p&&!0!==p.defaults)for(_=["precision","rounding","toExpNeg","toExpPos","maxE","minE","modulo","crypto"],m=0;m<_.length;)p.hasOwnProperty(b=_[m++])||(p[b]=this[b]);return y.config(p),y}(Ls);Eo=new Ke(Eo),Ro=new Ke(Ro);const Se=Ke;function re(p,m,b,_){function y(C){var A=function Ve(p,m){for(var b={},_=0;_<m.length;_++){var y=m[_],C=p[y];void 0!==C&&(b[y]=C)}return b}(C,m.map(vi));return function kn(p,m,b){var _=m.filter(C=>!function bi(p){return p&&"?"===p[0]}(C)).every(C=>void 0!==b[C]);if(!_){var y=m.filter(C=>void 0===b[C]);throw new Error('Cannot create function "'.concat(p,'", ')+"some dependencies are missing: ".concat(y.map(C=>'"'.concat(C,'"')).join(", "),"."))}}(p,m,C),b(A)}return y.isFactory=!0,y.fn=p,y.dependencies=m.slice().sort(),_&&(y.meta=_),y}function Qt(p){return"function"==typeof p&&"string"==typeof p.fn&&Array.isArray(p.dependencies)}function vi(p){return p&&"?"===p[0]?p.slice(1):p}var $i=re("BigNumber",["?on","config"],p=>{var{on:m,config:b}=p,_=Se.clone({precision:b.precision,modulo:Se.EUCLID});return _.prototype=Object.create(_.prototype),_.prototype.type="BigNumber",_.prototype.isBigNumber=!0,_.prototype.toJSON=function(){return{mathjs:"BigNumber",value:this.toString()}},_.fromJSON=function(y){return new _(y.value)},m&&m("config",function(y,C){y.precision!==C.precision&&_.config({precision:y.precision})}),_},{isClass:!0}),Er=S(9121);function ai(p){return"boolean"==typeof p||!!isFinite(p)&&p===Math.round(p)}function Fr(p,m){return"bigint"!==m.number||function so(p){return/^-?\d+$/.test(p)}(p)?m.number:m.numberFallback}var zr=Math.sign||function(p){return p>0?1:p<0?-1:0},ho=Math.log2||function(m){return Math.log(m)/Math.LN2},Vr=Math.log10||function(m){return Math.log(m)/Math.LN10},is=Math.log1p||function(p){return Math.log(p+1)},Ms=Math.cbrt||function(m){if(0===m)return m;var _,b=m<0;return b&&(m=-m),_=isFinite(m)?(m/((_=Math.exp(Math.log(m)/3))*_)+2*_)/3:m,b?-_:_},Ds=Math.expm1||function(m){return m>=2e-4||m<=-2e-4?Math.exp(m)-1:m+m*m/2+m*m*m/6};function Xo(p,m,b){var y={2:"0b",8:"0o",16:"0x"}[m],C="";if(b){if(b<1)throw new Error("size must be in greater than 0");if(!ai(b))throw new Error("size must be an integer");if(p>2**(b-1)-1||p<-(2**(b-1)))throw new Error("Value must be in range [-2^".concat(b-1,", 2^").concat(b-1,"-1]"));if(!ai(p))throw new Error("Value must be an integer");p<0&&(p+=2**b),C="i".concat(b)}var A="";return p<0&&(p=-p,A="-"),"".concat(A).concat(y).concat(p.toString(m)).concat(C)}function na(p,m){if("function"==typeof m)return m(p);if(p===1/0)return"Infinity";if(p===-1/0)return"-Infinity";if(isNaN(p))return"NaN";var{notation:b,precision:_,wordSize:y}=zs(m);switch(b){case"fixed":return at(p,_);case"exponential":return Oe(p,_);case"engineering":return function Je(p,m){if(isNaN(p)||!isFinite(p))return String(p);var _=On(ya(p),m),y=_.exponent,C=_.coefficients,A=y%3==0?y:y<0?y-3-y%3:y-y%3;if(ct(m))for(;m>C.length||y-A+1>C.length;)C.push(0);else for(var k=Math.abs(y-A)-(C.length-1),R=0;R<k;R++)C.push(0);for(var O=Math.abs(y-A),F=1;O>0;)F++,O--;var B=C.slice(F).join(""),H=ct(m)&&B.length||B.match(/[1-9]/)?"."+B:"",G=C.slice(0,F).join("")+H+"e"+(y>=0?"+":"")+A.toString();return _.sign+G}(p,_);case"bin":return Xo(p,2,y);case"oct":return Xo(p,8,y);case"hex":return Xo(p,16,y);case"auto":return function Ct(p,m,b){if(isNaN(p)||!isFinite(p))return String(p);var _=ou(b?.lowerExp,-3),y=ou(b?.upperExp,5),C=ya(p),A=m?On(C,m):C;if(A.exponent<_||A.exponent>=y)return Oe(p,m);var k=A.coefficients,R=A.exponent;k.length<m&&(k=k.concat(_i(m-k.length))),k=k.concat(_i(R-k.length+1+(k.length<m?m-k.length:0)));var O=R>0?R:0;return O<(k=_i(-R).concat(k)).length-1&&k.splice(O+1,0,"."),A.sign+k.join("")}(p,_,m).replace(/((\.\d*?)(0+))($|e)/,function(){var C=arguments[2],A=arguments[4];return"."!==C?C+A:A});default:throw new Error('Unknown notation "'+b+'". Choose "auto", "exponential", "fixed", "bin", "oct", or "hex.')}}function zs(p){var b,_,m="auto";if(void 0!==p)if(ct(p))b=p;else if(en(p))b=p.toNumber();else{if(!on(p))throw new Error("Unsupported type of options, number, BigNumber, or object expected");void 0!==p.precision&&(b=lc(p.precision,()=>{throw new Error('Option "precision" must be a number or BigNumber')})),void 0!==p.wordSize&&(_=lc(p.wordSize,()=>{throw new Error('Option "wordSize" must be a number or BigNumber')})),p.notation&&(m=p.notation)}return{notation:m,precision:b,wordSize:_}}function ya(p){var m=String(p).toLowerCase().match(/^(-?)(\d+\.?\d*)(e([+-]?\d+))?$/);if(!m)throw new SyntaxError("Invalid number "+p);var b=m[1],_=m[2],y=parseFloat(m[4]||"0"),C=_.indexOf(".");y+=-1!==C?C-1:_.length-1;var A=_.replace(".","").replace(/^0*/,function(k){return y-=k.length,""}).replace(/0*$/,"").split("").map(function(k){return parseInt(k)});return 0===A.length&&(A.push(0),y++),{sign:b,coefficients:A,exponent:y}}function at(p,m){if(isNaN(p)||!isFinite(p))return String(p);var b=ya(p),_="number"==typeof m?On(b,b.exponent+1+m):b,y=_.coefficients,C=_.exponent+1,A=C+(m||0);return y.length<A&&(y=y.concat(_i(A-y.length))),C<0&&(y=_i(1-C).concat(y),C=1),C<y.length&&y.splice(C,0,0===C?"0.":"."),_.sign+y.join("")}function Oe(p,m){if(isNaN(p)||!isFinite(p))return String(p);var b=ya(p),_=m?On(b,m):b,y=_.coefficients,C=_.exponent;y.length<m&&(y=y.concat(_i(m-y.length)));var A=y.shift();return _.sign+A+(y.length>0?"."+y.join(""):"")+"e"+(C>=0?"+":"")+C}function On(p,m){for(var b={sign:p.sign,coefficients:p.coefficients,exponent:p.exponent},_=b.coefficients;m<=0;)_.unshift(0),b.exponent++,m++;if(_.length>m&&_.splice(m,_.length-m)[0]>=5){var C=m-1;for(_[C]++;10===_[C];)_.pop(),0===C&&(_.unshift(0),b.exponent++,C++),_[--C]++}return b}function _i(p){for(var m=[],b=0;b<p;b++)m.push(0);return m}function Di(p,m){var b=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e-8,_=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;if(b<=0)throw new Error("Relative tolerance must be greater than 0");if(_<0)throw new Error("Absolute tolerance must be at least 0");return!isNaN(p)&&!isNaN(m)&&(isFinite(p)&&isFinite(m)?p===m||Math.abs(p-m)<=Math.max(b*Math.max(Math.abs(p),Math.abs(m)),_):p===m)}var fo=Math.acosh||function(p){return Math.log(Math.sqrt(p*p-1)+p)},Uo=Math.asinh||function(p){return Math.log(Math.sqrt(p*p+1)+p)},Gs=Math.atanh||function(p){return Math.log((1+p)/(1-p))/2},ba=Math.cosh||function(p){return(Math.exp(p)+Math.exp(-p))/2},Za=Math.sinh||function(p){return(Math.exp(p)-Math.exp(-p))/2},Ks=Math.tanh||function(p){var m=Math.exp(2*p);return(m-1)/(m+1)};function lc(p,m){return ct(p)?p:en(p)?p.toNumber():void m()}function ou(p,m){return ct(p)?p:en(p)?p.toNumber():m}var nd=re("Complex",[],()=>(Object.defineProperty(Er,"name",{value:"Complex"}),Er.prototype.constructor=Er,Er.prototype.type="Complex",Er.prototype.isComplex=!0,Er.prototype.toJSON=function(){return{mathjs:"Complex",re:this.re,im:this.im}},Er.prototype.toPolar=function(){return{r:this.abs(),phi:this.arg()}},Er.prototype.format=function(p){var b=this.im,_=this.re,y=na(this.re,p),C=na(this.im,p),A=ct(p)?p:p?p.precision:null;if(null!==A){var k=Math.pow(10,-A);Math.abs(_/b)<k&&(_=0),Math.abs(b/_)<k&&(b=0)}return 0===b?y:0===_?1===b?"i":-1===b?"-i":C+"i":b<0?-1===b?y+" - i":y+" - "+C.substring(1)+"i":1===b?y+" + i":y+" + "+C+"i"},Er.fromPolar=function(p){switch(arguments.length){case 1:var m=arguments[0];if("object"==typeof m)return Er(m);throw new TypeError("Input has to be an object with r and phi keys.");case 2:var b=arguments[0],_=arguments[1];if(ct(b)){if(Pt(_)&&_.hasBase("ANGLE")&&(_=_.toNumber("rad")),ct(_))return new Er({r:b,phi:_});throw new TypeError("Phi is not a number nor an angle unit.")}throw new TypeError("Radius r is not a number.");default:throw new SyntaxError("Wrong number of arguments in function fromPolar")}},Er.prototype.valueOf=Er.prototype.toString,Er.fromJSON=function(p){return new Er(p)},Er.compare=function(p,m){return p.re>m.re?1:p.re<m.re?-1:p.im>m.im?1:p.im<m.im?-1:0},Er),{isClass:!0});function bl(p){var m=0,b=1,_=Object.create(null),y=Object.create(null),C=0,A=function(R){var O=y[R];if(O&&(delete _[O],delete y[R],--m,b===O)){if(!m)return C=0,void(b=1);for(;!Object.prototype.hasOwnProperty.call(_,++b););}};return p=Math.abs(p),{hit:function(R){var O=y[R],F=++C;if(_[F]=R,y[R]=F,!O)return++m<=p?void 0:(A(R=_[b]),R);if(delete _[O],b===O)for(;!Object.prototype.hasOwnProperty.call(_,++b););},delete:A,clear:function(){m=C=0,b=1,_=Object.create(null),y=Object.create(null)}}}function _c(p){var{hasher:m,limit:b}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return b=b??Number.POSITIVE_INFINITY,m=m??JSON.stringify,function _(){"object"!=typeof _.cache&&(_.cache={values:new Map,lru:bl(b||Number.POSITIVE_INFINITY)});for(var y=[],C=0;C<arguments.length;C++)y[C]=arguments[C];var A=m(y);if(_.cache.values.has(A))return _.cache.lru.hit(A),_.cache.values.get(A);var k=p.apply(p,y);return _.cache.values.set(A,k),_.cache.values.delete(_.cache.lru.hit(A)),k}}var qf=_c(function(p){return new p(1).exp()},{hasher:hd}),aa=_c(function(p){return new p(1).plus(new p(5).sqrt()).div(2)},{hasher:hd}),Tc=_c(function(p){return p.acos(-1)},{hasher:hd}),Ra=_c(function(p){return Tc(p).times(2)},{hasher:hd});function hd(p){return p[0].precision}var ff=Math.PI,Yt=2*Math.PI,tc=Math.E,Su=re("true",[],()=>!0),md=re("false",[],()=>!1),Ld=re("null",[],()=>null),gd=As("Infinity",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(1/0):1/0}),Eu=As("NaN",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(NaN):NaN}),Pu=As("pi",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?Tc(b):ff}),Lc=As("tau",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?Ra(b):Yt}),qs=As("e",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?qf(b):tc}),Xc=As("phi",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?aa(b):1.618033988749895}),Bu=As("LN2",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(2).ln():Math.LN2}),su=As("LN10",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(10).ln():Math.LN10}),Is=As("LOG2E",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(1).div(new b(2).ln()):Math.LOG2E}),xa=As("LOG10E",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(1).div(new b(10).ln()):Math.LOG10E}),vd=As("SQRT1_2",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b("0.5").sqrt():Math.SQRT1_2}),Vu=As("SQRT2",["config","?BigNumber"],p=>{var{config:m,BigNumber:b}=p;return"BigNumber"===m.number?new b(2).sqrt():Math.SQRT2}),id=As("i",["Complex"],p=>{var{Complex:m}=p;return m.I}),Sd=re("PI",["pi"],p=>{var{pi:m}=p;return m}),pu=re("E",["e"],p=>{var{e:m}=p;return m}),hu=re("version",[],()=>"13.2.0");function As(p,m,b){return re(p,m,b,{recreateOnConfigChange:!0})}var Ed=ws("speedOfLight","299792458","m s^-1"),kc=ws("gravitationConstant","6.67430e-11","m^3 kg^-1 s^-2"),El=ws("planckConstant","6.62607015e-34","J s"),uc=ws("reducedPlanckConstant","1.0545718176461565e-34","J s"),kd=ws("magneticConstant","1.25663706212e-6","N A^-2"),Td=ws("electricConstant","8.8541878128e-12","F m^-1"),Pc=ws("vacuumImpedance","376.730313667","ohm"),ju=ws("coulomb","8.987551792261171e9","N m^2 C^-2"),Yl=ws("elementaryCharge","1.602176634e-19","C"),Bc=ws("bohrMagneton","9.2740100783e-24","J T^-1"),pf=ws("conductanceQuantum","7.748091729863649e-5","S"),hf=ws("inverseConductanceQuantum","12906.403729652257","ohm"),_e=ws("magneticFluxQuantum","2.0678338484619295e-15","Wb"),Dt=ws("nuclearMagneton","5.0507837461e-27","J T^-1"),Re=ws("klitzing","25812.807459304513","ohm"),mn=ws("bohrRadius","5.29177210903e-11","m"),gi=ws("classicalElectronRadius","2.8179403262e-15","m"),rr=ws("electronMass","9.1093837015e-31","kg"),or=ws("fermiCoupling","1.1663787e-5","GeV^-2"),ia=Vc("fineStructure",.0072973525693),La=ws("hartreeEnergy","4.3597447222071e-18","J"),vs=ws("protonMass","1.67262192369e-27","kg"),Qo=ws("deuteronMass","3.3435830926e-27","kg"),ll=ws("neutronMass","1.6749271613e-27","kg"),Sa=ws("quantumOfCirculation","3.6369475516e-4","m^2 s^-1"),$o=ws("rydberg","10973731.568160","m^-1"),Mc=ws("thomsonCrossSection","6.6524587321e-29","m^2"),yc=Vc("weakMixingAngle",.2229),Ue=Vc("efimovFactor",22.7),ne=ws("atomicMass","1.66053906660e-27","kg"),Pe=ws("avogadro","6.02214076e23","mol^-1"),rt=ws("boltzmann","1.380649e-23","J K^-1"),Ut=ws("faraday","96485.33212331001","C mol^-1"),Rn=ws("firstRadiation","3.7417718521927573e-16","W m^2"),Kn=ws("loschmidt","2.686780111798444e25","m^-3"),Y=ws("gasConstant","8.31446261815324","J K^-1 mol^-1"),Ce=ws("molarPlanckConstant","3.990312712893431e-10","J s mol^-1"),ue=ws("molarVolume","0.022413969545014137","m^3 mol^-1"),Ie=Vc("sackurTetrode",-1.16487052358),Ze=ws("secondRadiation","0.014387768775039337","m K"),kt=ws("stefanBoltzmann","5.67037441918443e-8","W m^-2 K^-4"),rn=ws("wienDisplacement","2.897771955e-3","m K"),Si=ws("molarMass","0.99999999965e-3","kg mol^-1"),oi=ws("molarMassC12","11.9999999958e-3","kg mol^-1"),Yr=ws("gravity","9.80665","m s^-2"),rs=ws("planckLength","1.616255e-35","m"),ls=ws("planckMass","2.176435e-8","kg"),Zo=ws("planckTime","5.391245e-44","s"),Hl=ws("planckCharge","1.87554603778e-18","C"),dc=ws("planckTemperature","1.416785e+32","K");function ws(p,m,b){return re(p,["config","Unit","BigNumber"],y=>{var{config:C,Unit:A,BigNumber:k}=y,O=new A("BigNumber"===C.number?new k(m):parseFloat(m),b);return O.fixPrefix=!0,O})}function Vc(p,m){return re(p,["config","BigNumber"],_=>{var{config:y,BigNumber:C}=_;return"BigNumber"===y.number?new C(m):m})}var sr={s:1,n:0,d:1};function ro(p,m){if(isNaN(p=parseInt(p,10)))throw Yh();return p*m}function Ic(p,m){if(0===m)throw $u();var b=Object.create(Pd.prototype);b.s=p<0?-1:1;var _=op(p=p<0?-p:p,m);return b.n=p/_,b.d=m/_,b}function Sp(p){for(var m={},b=p,_=2,y=4;y<=b;){for(;b%_==0;)b/=_,m[_]=(m[_]||0)+1;y+=1+2*_++}return b!==p?b>1&&(m[b]=(m[b]||0)+1):m[p]=(m[p]||0)+1,m}var au=function(p,m){var te,b=0,_=1,y=1,C=0,A=0,k=0,R=1,O=1,F=0,B=1,H=1,G=1,J=1e7;if(null!=p)if(void 0!==m){if(y=(b=p)*(_=m),b%1!=0||_%1!=0)throw yg()}else switch(typeof p){case"object":if("d"in p&&"n"in p)b=p.n,_=p.d,"s"in p&&(b*=p.s);else{if(!(0 in p))throw Yh();b=p[0],1 in p&&(_=p[1])}y=b*_;break;case"number":if(p<0&&(y=p,p=-p),p%1==0)b=p;else if(p>0){for(p>=1&&(p/=O=Math.pow(10,Math.floor(1+Math.log(p)/Math.LN10)));B<=J&&G<=J;){if(p===(te=(F+H)/(B+G))){B+G<=J?(b=F+H,_=B+G):G>B?(b=H,_=G):(b=F,_=B);break}p>te?(F+=H,B+=G):(H+=F,G+=B),B>J?(b=H,_=G):(b=F,_=B)}b*=O}else(isNaN(p)||isNaN(m))&&(_=b=NaN);break;case"string":if(null===(B=p.match(/\d+|./g)))throw Yh();if("-"===B[F]?(y=-1,F++):"+"===B[F]&&F++,B.length===F+1?A=ro(B[F++],y):"."===B[F+1]||"."===B[F]?("."!==B[F]&&(C=ro(B[F++],y)),(1+ ++F===B.length||"("===B[F+1]&&")"===B[F+3]||"'"===B[F+1]&&"'"===B[F+3])&&(A=ro(B[F],y),R=Math.pow(10,B[F].length),F++),("("===B[F]&&")"===B[F+2]||"'"===B[F]&&"'"===B[F+2])&&(k=ro(B[F+1],y),O=Math.pow(10,B[F+1].length)-1,F+=3)):"/"===B[F+1]||":"===B[F+1]?(A=ro(B[F],y),R=ro(B[F+2],1),F+=3):"/"===B[F+3]&&" "===B[F+1]&&(C=ro(B[F],y),A=ro(B[F+2],y),R=ro(B[F+4],1),F+=5),B.length<=F){y=b=k+(_=R*O)*C+O*A;break}default:throw Yh()}if(0===_)throw $u();sr.s=y<0?-1:1,sr.n=Math.abs(b),sr.d=Math.abs(_)};function op(p,m){if(!p)return m;if(!m)return p;for(;;){if(!(p%=m))return m;if(!(m%=p))return p}}function Pd(p,m){if(au(p,m),!(this instanceof Pd))return Ic(sr.s*sr.n,sr.d);p=op(sr.d,sr.n),this.s=sr.s,this.n=sr.n/p,this.d=sr.d/p}var $u=function(){return new Error("Division by Zero")},Yh=function(){return new Error("Invalid argument")},yg=function(){return new Error("Parameters must be integer")};Pd.prototype={s:1,n:0,d:1,abs:function(){return Ic(this.n,this.d)},neg:function(){return Ic(-this.s*this.n,this.d)},add:function(p,m){return au(p,m),Ic(this.s*this.n*sr.d+sr.s*this.d*sr.n,this.d*sr.d)},sub:function(p,m){return au(p,m),Ic(this.s*this.n*sr.d-sr.s*this.d*sr.n,this.d*sr.d)},mul:function(p,m){return au(p,m),Ic(this.s*sr.s*this.n*sr.n,this.d*sr.d)},div:function(p,m){return au(p,m),Ic(this.s*sr.s*this.n*sr.d,this.d*sr.n)},clone:function(){return Ic(this.s*this.n,this.d)},mod:function(p,m){if(isNaN(this.n)||isNaN(this.d))return new Pd(NaN);if(void 0===p)return Ic(this.s*this.n%this.d,1);if(au(p,m),0===sr.n&&0===this.d)throw $u();return Ic(this.s*(sr.d*this.n)%(sr.n*this.d),sr.d*this.d)},gcd:function(p,m){return au(p,m),Ic(op(sr.n,this.n)*op(sr.d,this.d),sr.d*this.d)},lcm:function(p,m){return au(p,m),0===sr.n&&0===this.n?Ic(0,1):Ic(sr.n*this.n,op(sr.n,this.n)*op(sr.d,this.d))},ceil:function(p){return p=Math.pow(10,p||0),isNaN(this.n)||isNaN(this.d)?new Pd(NaN):Ic(Math.ceil(p*this.s*this.n/this.d),p)},floor:function(p){return p=Math.pow(10,p||0),isNaN(this.n)||isNaN(this.d)?new Pd(NaN):Ic(Math.floor(p*this.s*this.n/this.d),p)},round:function(p){return p=Math.pow(10,p||0),isNaN(this.n)||isNaN(this.d)?new Pd(NaN):Ic(Math.round(p*this.s*this.n/this.d),p)},roundTo:function(p,m){return au(p,m),Ic(this.s*Math.round(this.n*sr.d/(this.d*sr.n))*sr.n,sr.d)},inverse:function(){return Ic(this.s*this.d,this.n)},pow:function(p,m){if(au(p,m),1===sr.d)return sr.s<0?Ic(Math.pow(this.s*this.d,sr.n),Math.pow(this.n,sr.n)):Ic(Math.pow(this.s*this.n,sr.n),Math.pow(this.d,sr.n));if(this.s<0)return null;var b=Sp(this.n),_=Sp(this.d),y=1,C=1;for(var A in b)if("1"!==A){if("0"===A){y=0;break}if(b[A]*=sr.n,b[A]%sr.d!=0)return null;b[A]/=sr.d,y*=Math.pow(A,b[A])}for(var A in _)if("1"!==A){if(_[A]*=sr.n,_[A]%sr.d!=0)return null;_[A]/=sr.d,C*=Math.pow(A,_[A])}return sr.s<0?Ic(C,y):Ic(y,C)},equals:function(p,m){return au(p,m),this.s*this.n*sr.d==sr.s*sr.n*this.d},compare:function(p,m){au(p,m);var b=this.s*this.n*sr.d-sr.s*sr.n*this.d;return(0<b)-(b<0)},simplify:function(p){if(isNaN(this.n)||isNaN(this.d))return this;p=p||.001;for(var m=this.abs(),b=m.toContinued(),_=1;_<b.length;_++){for(var y=Ic(b[_-1],1),C=_-2;C>=0;C--)y=y.inverse().add(b[C]);if(Math.abs(y.sub(m).valueOf())<p)return y.mul(this.s)}return this},divisible:function(p,m){return au(p,m),!(!(sr.n*this.d)||this.n*sr.d%(sr.n*this.d))},valueOf:function(){return this.s*this.n/this.d},toFraction:function(p){var m,b="",_=this.n,y=this.d;return this.s<0&&(b+="-"),1===y?b+=_:(p&&(m=Math.floor(_/y))>0&&(b+=m,b+=" ",_%=y),b+=_,b+="/",b+=y),b},toLatex:function(p){var m,b="",_=this.n,y=this.d;return this.s<0&&(b+="-"),1===y?b+=_:(p&&(m=Math.floor(_/y))>0&&(b+=m,_%=y),b+="\\frac{",b+=_,b+="}{",b+=y,b+="}"),b},toContinued:function(){var p,m=this.n,b=this.d,_=[];if(isNaN(m)||isNaN(b))return _;do{_.push(Math.floor(m/b)),p=m%b,m=b,b=p}while(1!==m);return _},toString:function(p){var m=this.n,b=this.d;if(isNaN(m)||isNaN(b))return"NaN";p=p||15;var _=function bh(p,m){for(;m%2==0;m/=2);for(;m%5==0;m/=5);if(1===m)return 0;for(var b=10%m,_=1;1!==b;_++)if(b=10*b%m,_>2e3)return 0;return _}(0,b),y=function wv(p,m,b){for(var _=1,y=function Uu(p,m,b){for(var _=1;m>0;p=p*p%b,m>>=1)1&m&&(_=_*p%b);return _}(10,b,m),C=0;C<300;C++){if(_===y)return C;_=10*_%m,y=10*y%m}return 0}(0,b,_),C=this.s<0?"-":"";if(C+=m/b|0,m%=b,(m*=10)&&(C+="."),_){for(var A=y;A--;)C+=m/b|0,m%=b,m*=10;for(C+="(",A=_;A--;)C+=m/b|0,m%=b,m*=10;C+=")"}else for(A=p;m&&A--;)C+=m/b|0,m%=b,m*=10;return C}};var bg=re("Fraction",[],()=>(Object.defineProperty(Pd,"name",{value:"Fraction"}),Pd.prototype.constructor=Pd,Pd.prototype.type="Fraction",Pd.prototype.isFraction=!0,Pd.prototype.toJSON=function(){return{mathjs:"Fraction",n:this.s*this.n,d:this.d}},Pd.fromJSON=function(p){return new Pd(p)},Pd),{isClass:!0}),Ch=re("Matrix",[],()=>{function p(){if(!(this instanceof p))throw new SyntaxError("Constructor must be called with the new operator")}return p.prototype.type="Matrix",p.prototype.isMatrix=!0,p.prototype.storage=function(){throw new Error("Cannot invoke storage on a Matrix interface")},p.prototype.datatype=function(){throw new Error("Cannot invoke datatype on a Matrix interface")},p.prototype.create=function(m,b){throw new Error("Cannot invoke create on a Matrix interface")},p.prototype.subset=function(m,b,_){throw new Error("Cannot invoke subset on a Matrix interface")},p.prototype.get=function(m){throw new Error("Cannot invoke get on a Matrix interface")},p.prototype.set=function(m,b,_){throw new Error("Cannot invoke set on a Matrix interface")},p.prototype.resize=function(m,b){throw new Error("Cannot invoke resize on a Matrix interface")},p.prototype.reshape=function(m,b){throw new Error("Cannot invoke reshape on a Matrix interface")},p.prototype.clone=function(){throw new Error("Cannot invoke clone on a Matrix interface")},p.prototype.size=function(){throw new Error("Cannot invoke size on a Matrix interface")},p.prototype.map=function(m,b){throw new Error("Cannot invoke map on a Matrix interface")},p.prototype.forEach=function(m){throw new Error("Cannot invoke forEach on a Matrix interface")},p.prototype[Symbol.iterator]=function(){throw new Error("Cannot iterate a Matrix interface")},p.prototype.toArray=function(){throw new Error("Cannot invoke toArray on a Matrix interface")},p.prototype.valueOf=function(){throw new Error("Cannot invoke valueOf on a Matrix interface")},p.prototype.format=function(m){throw new Error("Cannot invoke format on a Matrix interface")},p.prototype.toString=function(){throw new Error("Cannot invoke toString on a Matrix interface")},p},{isClass:!0}),If=re("Range",[],()=>{function p(m,b,_){if(!(this instanceof p))throw new SyntaxError("Constructor must be called with the new operator");var y=null!=m,C=null!=b,A=null!=_;if(y)if(en(m))m=m.toNumber();else if("number"!=typeof m)throw new TypeError("Parameter start must be a number");if(C)if(en(b))b=b.toNumber();else if("number"!=typeof b)throw new TypeError("Parameter end must be a number");if(A)if(en(_))_=_.toNumber();else if("number"!=typeof _)throw new TypeError("Parameter step must be a number");this.start=y?parseFloat(m):0,this.end=C?parseFloat(b):0,this.step=A?parseFloat(_):1}return p.prototype.type="Range",p.prototype.isRange=!0,p.parse=function(m){if("string"!=typeof m)return null;var _=m.split(":").map(function(C){return parseFloat(C)});if(_.some(function(C){return isNaN(C)}))return null;switch(_.length){case 2:return new p(_[0],_[1]);case 3:return new p(_[0],_[2],_[1]);default:return null}},p.prototype.clone=function(){return new p(this.start,this.end,this.step)},p.prototype.size=function(){var m=0,_=this.step,C=this.end-this.start;return zr(_)===zr(C)?m=Math.ceil(C/_):0===C&&(m=0),isNaN(m)&&(m=0),[m]},p.prototype.min=function(){var m=this.size()[0];if(m>0)return this.step>0?this.start:this.start+(m-1)*this.step},p.prototype.max=function(){var m=this.size()[0];if(m>0)return this.step>0?this.start+(m-1)*this.step:this.start},p.prototype.forEach=function(m){var b=this.start,_=this.step,y=this.end,C=0;if(_>0)for(;b<y;)m(b,[C],this),b+=_,C++;else if(_<0)for(;b>y;)m(b,[C],this),b+=_,C++},p.prototype.map=function(m){var b=[];return this.forEach(function(_,y,C){b[y[0]]=m(_,y,C)}),b},p.prototype.toArray=function(){var m=[];return this.forEach(function(b,_){m[_[0]]=b}),m},p.prototype.valueOf=function(){return this.toArray()},p.prototype.format=function(m){var b=na(this.start,m);return 1!==this.step&&(b+=":"+na(this.step,m)),b+":"+na(this.end,m)},p.prototype.toString=function(){return this.format()},p.prototype.toJSON=function(){return{mathjs:"Range",start:this.start,end:this.end,step:this.step}},p.fromJSON=function(m){return new p(m.start,m.end,m.step)},p},{isClass:!0}),xr=re("ResultSet",[],()=>{function p(m){if(!(this instanceof p))throw new SyntaxError("Constructor must be called with the new operator");this.entries=m||[]}return p.prototype.type="ResultSet",p.prototype.isResultSet=!0,p.prototype.valueOf=function(){return this.entries},p.prototype.toString=function(){return"["+this.entries.join(", ")+"]"},p.prototype.toJSON=function(){return{mathjs:"ResultSet",entries:this.entries}},p.fromJSON=function(m){return new p(m.entries)},p},{isClass:!0});function Dh(p,m,b){var y=new(0,p.constructor)(2),C="";if(b){if(b<1)throw new Error("size must be in greater than 0");if(!ai(b))throw new Error("size must be an integer");if(p.greaterThan(y.pow(b-1).sub(1))||p.lessThan(y.pow(b-1).mul(-1)))throw new Error("Value must be in range [-2^".concat(b-1,", 2^").concat(b-1,"-1]"));if(!p.isInteger())throw new Error("Value must be an integer");p.lessThan(0)&&(p=p.add(y.pow(b))),C="i".concat(b)}switch(m){case 2:return"".concat(p.toBinary()).concat(C);case 8:return"".concat(p.toOctal()).concat(C);case 16:return"".concat(p.toHexadecimal()).concat(C);default:throw new Error("Base ".concat(m," not supported "))}}function Cg(p,m){return void 0!==m?p.toExponential(m-1):p.toExponential()}function Am(p,m){return ct(p)?p:en(p)?p.toNumber():m}function ja(p,m){return p.substring(p.length-m.length,p.length)===m}function xs(p,m){var b=function rd(p,m){return"number"==typeof p?na(p,m):en(p)?function D0(p,m){if("function"==typeof m)return m(p);if(!p.isFinite())return p.isNaN()?"NaN":p.gt(0)?"Infinity":"-Infinity";var{notation:b,precision:_,wordSize:y}=zs(m);switch(b){case"fixed":return function Sv(p,m){return p.toFixed(m)}(p,_);case"exponential":return Cg(p,_);case"engineering":return function $_(p,m){var b=p.e,_=b%3==0?b:b<0?b-3-b%3:b-b%3,C=p.mul(Math.pow(10,-_)).toPrecision(m);return C.includes("e")&&(C=new(0,p.constructor)(C).toFixed()),C+"e"+(b>=0?"+":"")+_.toString()}(p,_);case"bin":return Dh(p,2,y);case"oct":return Dh(p,8,y);case"hex":return Dh(p,16,y);case"auto":var C=Am(m?.lowerExp,-3),A=Am(m?.upperExp,5);if(p.isZero())return"0";var R=p.toSignificantDigits(_),O=R.e;return(O>=C&&O<A?R.toFixed():Cg(p,_)).replace(/((\.\d*?)(0+))($|e)/,function(){var F=arguments[2],B=arguments[4];return"."!==F?F+B:B});default:throw new Error('Unknown notation "'+b+'". Choose "auto", "exponential", "fixed", "bin", "oct", or "hex.')}}(p,m):function sp(p){return p&&"object"==typeof p&&"number"==typeof p.s&&"number"==typeof p.n&&"number"==typeof p.d||!1}(p)?m&&"decimal"===m.fraction?p.toString():p.s*p.n+"/"+p.d:Array.isArray(p)?Ev(p,m):Ae(p)?Yd(p):"function"==typeof p?p.syntax?String(p.syntax):"function":p&&"object"==typeof p?"function"==typeof p.format?p.format(m):p&&p.toString(m)!=={}.toString()?p.toString(m):"{"+Object.keys(p).map(_=>Yd(_)+": "+xs(p[_],m)).join(", ")+"}":String(p)}(p,m);return m&&"object"==typeof m&&"truncate"in m&&b.length>m.truncate?b.substring(0,m.truncate-3)+"...":b}function Yd(p){for(var m=String(p),b="",_=0;_<m.length;){var y=m.charAt(_);b+=y in Qu?Qu[y]:y,_++}return'"'+b+'"'}var Qu={'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t"};function Xd(p){var m=String(p);return m.replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function Ev(p,m){if(Array.isArray(p)){for(var b="[",_=p.length,y=0;y<_;y++)0!==y&&(b+=", "),b+=Ev(p[y],m);return b+"]"}return xs(p,m)}function Ep(p,m){if(!Ae(p))throw new TypeError("Unexpected type of argument in function compareText (expected: string or Array or Matrix, actual: "+pi(p)+", index: 0)");if(!Ae(m))throw new TypeError("Unexpected type of argument in function compareText (expected: string or Array or Matrix, actual: "+pi(m)+", index: 1)");return p===m?0:p>m?1:-1}function va(p,m,b){if(!(this instanceof va))throw new SyntaxError("Constructor must be called with the new operator");this.actual=p,this.expected=m,this.relation=b,this.message="Dimension mismatch ("+(Array.isArray(p)?"["+p.join(", ")+"]":p)+" "+(this.relation||"!=")+" "+(Array.isArray(m)?"["+m.join(", ")+"]":m)+")",this.stack=(new Error).stack}function bc(p,m,b){if(!(this instanceof bc))throw new SyntaxError("Constructor must be called with the new operator");this.index=p,arguments.length<3?(this.min=0,this.max=m):(this.min=m,this.max=b),this.message=void 0!==this.min&&this.index<this.min?"Index out of range ("+this.index+" < "+this.min+")":void 0!==this.max&&this.index>=this.max?"Index out of range ("+this.index+" > "+(this.max-1)+")":"Index out of range ("+this.index+")",this.stack=(new Error).stack}function Bs(p){for(var m=[];Array.isArray(p);)m.push(p.length),p=p[0];return m}function wh(p,m,b){var _,y=p.length;if(y!==m[b])throw new va(y,m[b]);if(b<m.length-1){var C=b+1;for(_=0;_<y;_++){if(!Array.isArray(p[_]))throw new va(m.length-1,m.length,"<");wh(p[_],m,C)}}else for(_=0;_<y;_++)if(Array.isArray(p[_]))throw new va(m.length+1,m.length,">")}function Om(p,m){if(0===m.length){if(Array.isArray(p))throw new va(p.length,0)}else wh(p,m,0)}function Wu(p,m){var b=p.isMatrix?p._size:Bs(p);m._sourceSize.forEach((y,C)=>{if(null!==y&&y!==b[C])throw new va(y,b[C])})}function zl(p,m){if(void 0!==p){if(!ct(p)||!ai(p))throw new TypeError("Index must be an integer (value: "+p+")");if(p<0||"number"==typeof m&&p>=m)throw new bc(p,m)}}function Tp(p){for(var m=0;m<p._dimensions.length;++m){var b=p._dimensions[m];if(b._data&&dt(b._data)){if(0===b._size[0])return!0}else if(b.isRange){if(b.start===b.end)return!0}else if(Ae(b)&&0===b.length)return!0}return!1}function Mp(p,m,b){if(!Array.isArray(m))throw new TypeError("Array expected");if(0===m.length)throw new Error("Resizing to scalar is not supported");return m.forEach(function(y){if(!ct(y)||!ai(y)||y<0)throw new TypeError("Invalid size, must contain positive integers (size: "+xs(m)+")")}),(ct(p)||en(p))&&(p=[p]),Zd(p,m,0,void 0!==b?b:0),p}function Zd(p,m,b,_){var y,C,k=m[b],R=Math.min(p.length,k);if(p.length=k,b<m.length-1){var O=b+1;for(y=0;y<R;y++)C=p[y],Array.isArray(C)||(p[y]=C=[C]),Zd(C,m,O,_);for(y=R;y<k;y++)p[y]=C=[],Zd(C,m,O,_)}else{for(y=0;y<R;y++)for(;Array.isArray(p[y]);)p[y]=p[y][0];for(y=R;y<k;y++)p[y]=_}}function Fm(p,m){var b=ns(p),_=b.length;if(!Array.isArray(p)||!Array.isArray(m))throw new TypeError("Array expected");if(0===m.length)throw new va(0,_,"!=");var y=Af(m=ap(m,_));if(_!==y)throw new va(y,_,"!=");try{return function _d(p,m){for(var _,b=p,y=m.length-1;y>0;y--){var C=m[y];_=[];for(var A=b.length/C,k=0;k<A;k++)_.push(b.slice(k*C,(k+1)*C));b=_}return b}(b,m)}catch(C){throw C instanceof va?new va(y,_,"!="):C}}function ap(p,m){var b=Af(p),_=p.slice(),C=p.indexOf(-1);if(p.indexOf(-1,C+1)>=0)throw new Error("More than one wildcard in sizes");if(C>=0){if(m%b!=0)throw new Error("Could not replace wildcard, since "+m+" is no multiple of "+-b);_[C]=-m/b}return _}function Af(p){return p.reduce((m,b)=>m*b,1)}function Mu(p,m){for(var b=m||Bs(p);Array.isArray(p)&&1===p.length;)p=p[0],b.shift();for(var _=b.length;1===b[_-1];)_--;return _<b.length&&(p=Jd(p,_,0),b.length=_),p}function Jd(p,m,b){var _,y;if(b<m){var C=b+1;for(_=0,y=p.length;_<y;_++)p[_]=Jd(p[_],m,C)}else for(;Array.isArray(p);)p=p[0];return p}function W_(p,m,b,_){var y=_||Bs(p);if(b)for(var C=0;C<b;C++)p=[p],y.unshift(1);for(p=Iu(p,m,0);y.length<m;)y.push(1);return p}function Iu(p,m,b){var _,y;if(Array.isArray(p)){var C=b+1;for(_=0,y=p.length;_<y;_++)p[_]=Iu(p[_],m,C)}else for(var A=b;A<m;A++)p=[p];return p}function ns(p){if(!Array.isArray(p))return p;var m=[];return p.forEach(function b(_){Array.isArray(_)?_.forEach(b):m.push(_)}),m}function Hu(p,m){return Array.prototype.map.call(p,m)}function gf(p,m){Array.prototype.forEach.call(p,m)}function xh(p,m){if(1!==Bs(p).length)throw new Error("Only one dimensional matrices supported");return Array.prototype.filter.call(p,b=>m.test(b))}function Tv(p,m){return Array.prototype.join.call(p,m)}function Md(p){if(!Array.isArray(p))throw new TypeError("Array input expected");if(0===p.length)return p;var m=[],b=0;m[0]={value:p[0],identifier:0};for(var _=1;_<p.length;_++)p[_]===p[_-1]?b++:b=0,m.push({value:p[_],identifier:b});return m}function Of(p){if(!Array.isArray(p))throw new TypeError("Array input expected");if(0===p.length)return p;for(var m=[],b=0;b<p.length;b++)m.push(p[b].value);return m}function Qf(p,m){for(var b,_=0,y=0;y<p.length;y++){var C=p[y],A=Array.isArray(C);if(0===y&&A&&(_=C.length),A&&C.length!==_)return;var k=A?Qf(C,m):m(C);if(void 0===b)b=k;else if(b!==k)return"mixed"}return b}function Ip(p,m,b,_){if(_<b){if(p.length!==m.length)throw new va(p.length,m.length);for(var y=[],C=0;C<p.length;C++)y[C]=Ip(p[C],m[C],b,_+1);return y}return p.concat(m)}function Mv(){var p=Array.prototype.slice.call(arguments,0,-1),m=Array.prototype.slice.call(arguments,-1);if(1===p.length)return p[0];if(p.length>1)return p.slice(1).reduce(function(b,_){return Ip(b,_,m,0)},p[0]);throw new Error("Wrong number of arguments in function concat")}function Xh(){for(var p=arguments.length,m=new Array(p),b=0;b<p;b++)m[b]=arguments[b];for(var _=m.map(H=>H.length),y=Math.max(..._),C=new Array(y).fill(null),A=0;A<m.length;A++)for(var k=m[A],R=_[A],O=0;O<R;O++){var F=y-R+O;k[O]>C[F]&&(C[F]=k[O])}for(var B=0;B<m.length;B++)Nm(m[B],C);return C}function Nm(p,m){for(var b=m.length,_=p.length,y=0;y<_;y++){var C=b-_+y;if(p[y]<m[C]&&p[y]>1||p[y]>m[C])throw new Error("shape missmatch: missmatch is found in arg with shape (".concat(p,") not possible to broadcast dimension ").concat(_," with size ").concat(p[y]," to size ").concat(m[C]))}}function od(p,m){var b=Bs(p);if(qn(b,m))return p;Nm(b,m);var _=Xh(b,m),y=_.length,C=[...Array(y-b.length).fill(1),...b],A=function H_(p){return e([],p)}(p);b.length<y&&(b=Bs(A=Fm(A,C)));for(var k=0;k<y;k++)b[k]<_[k]&&(b=Bs(A=Iv(A,_[k],k)));return A}function Iv(p,m,b){return Mv(...Array(m).fill(p),b)}function mu(p,m){if(!Array.isArray(p))throw new Error("Array expected");var b=Bs(p);if(m.length!==b.length)throw new va(m.length,b.length);for(var _=0;_<m.length;_++)zl(m[_],b[_]);return m.reduce((y,C)=>y[C],p)}function Zh(p,m,b,_){return Array.isArray(p)?p.map(function(y,C){return Zh(y,m.concat(C),b,_)}):_(p,m,b)}(va.prototype=new RangeError).constructor=RangeError,va.prototype.name="DimensionError",va.prototype.isDimensionError=!0,(bc.prototype=new RangeError).constructor=RangeError,bc.prototype.name="IndexError",bc.prototype.isIndexError=!0;var Ff=S(616);function yd(p,m,b){if(Ff.isTypedFunction(p)){var _=(m.isMatrix?m.size():Bs(m)).map(()=>0),y=m.isMatrix?m.get(_):mu(m,_),C=1===Object.keys(p.signatures).length,A=function Rm(p,m,b,_){for(var y=[m,b,_],C=3;C>0;C--){var A=y.slice(0,C);if(null!==Ff.resolve(p,A))return C}}(p,y,_,m),k=C?Object.values(p.signatures)[0]:p;return A>=1&&A<=3?function(){for(var R=arguments.length,O=new Array(R),F=0;F<R;F++)O[F]=arguments[F];return Lm(k,O.slice(0,A),b,p.name)}:function(){for(var R=arguments.length,O=new Array(R),F=0;F<R;F++)O[F]=arguments[F];return Lm(k,O,b,p.name)}}return p}function Lm(p,m,b,_){try{return p(...m)}catch(y){!function Sh(p,m,b,_){var y;if(p instanceof TypeError&&"wrongType"===(null===(y=p.data)||void 0===y?void 0:y.category)){var C=[];throw C.push("value: ".concat(pi(m[0]))),m.length>=2&&C.push("index: ".concat(pi(m[1]))),m.length>=3&&C.push("array: ".concat(pi(m[2]))),new TypeError("Function ".concat(b," cannot apply callback arguments ")+"".concat(_,"(").concat(C.join(", "),") at index ").concat(JSON.stringify(m[1])))}throw new TypeError("Function ".concat(b," cannot apply callback arguments ")+"to function ".concat(_,": ").concat(p.message))}(y,m,b,_)}}var Nf=re("DenseMatrix",["Matrix"],p=>{var{Matrix:m}=p;function b(F,B){if(!(this instanceof b))throw new SyntaxError("Constructor must be called with the new operator");if(B&&!Ae(B))throw new Error("Invalid datatype: "+B);if(ut(F))"DenseMatrix"===F.type?(this._data=At(F._data),this._size=At(F._size),this._datatype=B||F._datatype):(this._data=F.toArray(),this._size=F.size(),this._datatype=B||F._datatype);else if(F&&dt(F.data)&&dt(F.size))this._data=F.data,this._size=F.size,Om(this._data,this._size),this._datatype=B||F.datatype;else if(dt(F))this._data=O(F),this._size=Bs(this._data),Om(this._data,this._size),this._datatype=B;else{if(F)throw new TypeError("Unsupported type of data ("+pi(F)+")");this._data=[],this._size=[0],this._datatype=B}}function y(F,B,H,G){var J=G===H-1,te=B.dimension(G);return J?te.map(function(be){return zl(be,F.length),F[be]}).valueOf():te.map(function(be){return zl(be,F.length),y(F[be],B,H,G+1)}).valueOf()}function A(F,B,H,G,J){var te=J===G-1;B.dimension(J).forEach(te?function(we,Le){zl(we),F[we]=H[Le[0]]}:function(we,Le){zl(we),A(F[we],B,H[Le[0]],G,J+1)})}function k(F,B,H){if(0===B.length){for(var G=F._data;dt(G);)G=G[0];return G}return F._size=B.slice(0),F._data=Mp(F._data,F._size,H),F}function R(F,B,H){for(var G=F._size.slice(0),J=!1;G.length<B.length;)G.push(0),J=!0;for(var te=0,be=B.length;te<be;te++)B[te]>G[te]&&(G[te]=B[te],J=!0);J&&k(F,G,H)}function O(F){return ut(F)?O(F.valueOf()):dt(F)?F.map(O):F}return(b.prototype=new m).createDenseMatrix=function(F,B){return new b(F,B)},Object.defineProperty(b,"name",{value:"DenseMatrix"}),b.prototype.constructor=b,b.prototype.type="DenseMatrix",b.prototype.isDenseMatrix=!0,b.prototype.getDataType=function(){return Qf(this._data,pi)},b.prototype.storage=function(){return"dense"},b.prototype.datatype=function(){return this._datatype},b.prototype.create=function(F,B){return new b(F,B)},b.prototype.subset=function(F,B,H){switch(arguments.length){case 1:return function _(F,B){if(!pn(B))throw new TypeError("Invalid index");if(B.isScalar())return F.get(B.min());var G=B.size();if(G.length!==F._size.length)throw new va(G.length,F._size.length);for(var J=B.min(),te=B.max(),be=0,we=F._size.length;be<we;be++)zl(J[be],F._size[be]),zl(te[be],F._size[be]);return new b(y(F._data,B,G.length,0),F._datatype)}(this,F);case 2:case 3:return function C(F,B,H,G){if(!B||!0!==B.isIndex)throw new TypeError("Invalid index");var be,J=B.size(),te=B.isScalar();if(ut(H)?(be=H.size(),H=H.valueOf()):be=Bs(H),te){if(0!==be.length)throw new TypeError("Scalar expected");F.set(B.min(),H,G)}else{if(!qn(be,J))try{be=Bs(H=od(0===be.length?[H]:H,J))}catch{}if(J.length<F._size.length)throw new va(J.length,F._size.length,"<");if(be.length<J.length){for(var we=0,Le=0;1===J[we]&&1===be[we];)we++;for(;1===J[we];)Le++,we++;H=W_(H,J.length,Le,be)}if(!qn(J,be))throw new va(J,be,">");R(F,B.max().map(function(pe){return pe+1}),G),A(F._data,B,H,J.length,0)}return F}(this,F,B,H);default:throw new SyntaxError("Wrong number of arguments")}},b.prototype.get=function(F){return mu(this._data,F)},b.prototype.set=function(F,B,H){if(!dt(F))throw new TypeError("Array expected");if(F.length<this._size.length)throw new va(F.length,this._size.length,"<");var G,J,te;R(this,F.map(function(Le){return Le+1}),H);var we=this._data;for(G=0,J=F.length-1;G<J;G++)zl(te=F[G],we.length),we=we[te];return zl(te=F[F.length-1],we.length),we[te]=B,this},b.prototype.resize=function(F,B,H){if(!Mt(F))throw new TypeError("Array or Matrix expected");var G=F.valueOf().map(te=>Array.isArray(te)&&1===te.length?te[0]:te);return k(H?this.clone():this,G,B)},b.prototype.reshape=function(F,B){var H=B?this.clone():this;H._data=Fm(H._data,F);var G=H._size.reduce((J,te)=>J*te);return H._size=ap(F,G),H},b.prototype.clone=function(){return new b({data:At(this._data),size:At(this._size),datatype:this._datatype})},b.prototype.size=function(){return this._size.slice(0)},b.prototype._forEach=function(F){var B=this,H=B.size();if(1!==H.length){var J=Array(H.length).fill(0),te=Array(H.length-1),be=te.length-1;te[0]=B._data[0];for(var we=0;we<be;we++)te[we+1]=te[we][0];for(J[be]=-1;;){var Le=void 0;for(Le=be;Le>=0;Le--){if(J[Le]++,J[Le]!==H[Le]){te[Le]=0===Le?B._data[J[Le]]:te[Le-1][J[Le]];for(var de=Le;de<be;de++)te[de+1]=te[de][0];for(var Te=0;Te<H[te.length];Te++)J[te.length]=Te,F(te[be],Te,J.slice(0));break}J[Le]=0}if(-1===Le)break}}else for(var G=0;G<H[0];G++)F(B._data,G,[G])},b.prototype.map=function(F){var B=this,H=new b(B),G=yd(F,B._data,"map");return H._forEach(function(J,te,be){J[te]=G(J[te],be,B)}),H},b.prototype.forEach=function(F){var B=this,H=yd(F,B._data,"map");B._forEach(function(G,J,te){H(G[J],te,B)})},b.prototype[Symbol.iterator]=function*(){var F=function*(H,G){if(dt(H))for(var J=0;J<H.length;J++)yield*F(H[J],G.concat(J));else yield{value:H,index:G}};yield*F(this._data,[])},b.prototype.rows=function(){var F=[];if(2!==this.size().length)throw new TypeError("Rows can only be returned for a 2D matrix.");var H=this._data;for(var G of H)F.push(new b([G],this._datatype));return F},b.prototype.columns=function(){var F=this,B=[],H=this.size();if(2!==H.length)throw new TypeError("Rows can only be returned for a 2D matrix.");for(var G=this._data,J=function(we){var Le=G.map(de=>[de[we]]);B.push(new b(Le,F._datatype))},te=0;te<H[1];te++)J(te);return B},b.prototype.toArray=function(){return At(this._data)},b.prototype.valueOf=function(){return this._data},b.prototype.format=function(F){return xs(this._data,F)},b.prototype.toString=function(){return xs(this._data)},b.prototype.toJSON=function(){return{mathjs:"DenseMatrix",data:this._data,size:this._size,datatype:this._datatype}},b.prototype.diagonal=function(F){if(F){if(en(F)&&(F=F.toNumber()),!ct(F)||!ai(F))throw new TypeError("The parameter k must be an integer number")}else F=0;for(var B=F>0?F:0,H=F<0?-F:0,te=Math.min(this._size[0]-H,this._size[1]-B),be=[],we=0;we<te;we++)be[we]=this._data[we+H][we+B];return new b({data:be,size:[te],datatype:this._datatype})},b.diagonal=function(F,B,H,G){if(!dt(F))throw new TypeError("Array expected, size parameter");if(2!==F.length)throw new Error("Only two dimensions matrix are supported");if(F=F.map(function(Be){if(en(Be)&&(Be=Be.toNumber()),!ct(Be)||!ai(Be)||Be<1)throw new Error("Size values must be positive integers");return Be}),H){if(en(H)&&(H=H.toNumber()),!ct(H)||!ai(H))throw new TypeError("The parameter k must be an integer number")}else H=0;var de,J=H>0?H:0,te=H<0?-H:0,be=F[0],we=F[1],Le=Math.min(be-te,we-J);if(dt(B)){if(B.length!==Le)throw new Error("Invalid value array length");de=function(We){return B[We]}}else if(ut(B)){var Te=B.size();if(1!==Te.length||Te[0]!==Le)throw new Error("Invalid matrix length");de=function(We){return B.get([We])}}else de=function(){return B};G||(G=en(de(0))?de(0).mul(0):0);var De=[];if(F.length>0){De=Mp(De,F,G);for(var pe=0;pe<Le;pe++)De[pe+te][pe+J]=de(pe)}return new b({data:De,size:[be,we]})},b.fromJSON=function(F){return new b(F)},b.prototype.swapRows=function(F,B){if(!(ct(F)&&ai(F)&&ct(B)&&ai(B)))throw new Error("Row index must be positive integers");if(2!==this._size.length)throw new Error("Only two dimensional matrix is supported");return zl(F,this._size[0]),zl(B,this._size[0]),b._swapRows(F,B,this._data),this},b._swapRows=function(F,B,H){var G=H[F];H[F]=H[B],H[B]=G},b},{isClass:!0}),io=re("replacer",[],()=>function(m,b){return"number"!=typeof b||isFinite(b)&&!isNaN(b)?"bigint"==typeof b?{mathjs:"bigint",value:String(b)}:b:{mathjs:"number",value:String(b)}}),Ps=function(){return Ps=Ff.create,Ff},Xl=re("typed",["?BigNumber","?Complex","?DenseMatrix","?Fraction"],function(m){var{BigNumber:b,Complex:_,DenseMatrix:y,Fraction:C}=m,A=Ps();return A.clear(),A.addTypes([{name:"number",test:ct},{name:"Complex",test:un},{name:"BigNumber",test:en},{name:"bigint",test:an},{name:"Fraction",test:vn},{name:"Unit",test:Pt},{name:"identifier",test:k=>Ae&&/^(?:[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE3F\uDE40\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDF02\uDF04-\uDF10\uDF12-\uDF33\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD887][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2F\uDC41-\uDC46]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD32\uDD50-\uDD52\uDD55\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E\uDF25-\uDF2A]|\uD838[\uDC30-\uDC6D\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDCD0-\uDCEB\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF39\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0\uDFF0-\uDFFF]|\uD87B[\uDC00-\uDE5D]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD888[\uDC00-\uDFAF])(?:[0-9A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE3F\uDE40\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDF02\uDF04-\uDF10\uDF12-\uDF33\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD887][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2F\uDC41-\uDC46]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD32\uDD50-\uDD52\uDD55\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E\uDF25-\uDF2A]|\uD838[\uDC30-\uDC6D\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDCD0-\uDCEB\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF39\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0\uDFF0-\uDFFF]|\uD87B[\uDC00-\uDE5D]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD888[\uDC00-\uDFAF])*$/.test(k)},{name:"string",test:Ae},{name:"Chain",test:ri},{name:"Array",test:dt},{name:"Matrix",test:ut},{name:"DenseMatrix",test:Wt},{name:"SparseMatrix",test:It},{name:"Range",test:Vn},{name:"Index",test:pn},{name:"boolean",test:Wn},{name:"ResultSet",test:ji},{name:"Help",test:An},{name:"function",test:St},{name:"Date",test:qt},{name:"RegExp",test:Ht},{name:"null",test:Zn},{name:"undefined",test:Dn},{name:"AccessorNode",test:gn},{name:"ArrayNode",test:Nn},{name:"AssignmentNode",test:Yn},{name:"BlockNode",test:cr},{name:"ConditionalNode",test:Ai},{name:"ConstantNode",test:Qi},{name:"FunctionNode",test:eo},{name:"FunctionAssignmentNode",test:Ur},{name:"IndexNode",test:as},{name:"Node",test:uo},{name:"ObjectNode",test:mi},{name:"OperatorNode",test:ci},{name:"ParenthesisNode",test:yt},{name:"RangeNode",test:hn},{name:"RelationalNode",test:Gt},{name:"SymbolNode",test:Gn},{name:"Map",test:Cn},{name:"Object",test:on}]),A.addConversions([{from:"number",to:"BigNumber",convert:function(R){if(b||nc(R),function Qn(p){return p.toExponential().replace(/e.*$/,"").replace(/^0\.?0*|\./,"").length}(R)>15)throw new TypeError("Cannot implicitly convert a number with >15 significant digits to BigNumber (value: "+R+"). Use function bignumber(x) to convert to BigNumber.");return new b(R)}},{from:"number",to:"Complex",convert:function(R){return _||ra(R),new _(R,0)}},{from:"BigNumber",to:"Complex",convert:function(R){return _||ra(R),new _(R.toNumber(),0)}},{from:"bigint",to:"number",convert:function(R){if(R>Number.MAX_SAFE_INTEGER)throw new TypeError("Cannot implicitly convert bigint to number: value exceeds the max safe integer value (value: "+R+")");return Number(R)}},{from:"bigint",to:"BigNumber",convert:function(R){return b||nc(R),new b(R.toString())}},{from:"bigint",to:"Fraction",convert:function(R){return C||Ja(R),new C(R.toString())}},{from:"Fraction",to:"BigNumber",convert:function(R){throw new TypeError("Cannot implicitly convert a Fraction to BigNumber or vice versa. Use function bignumber(x) to convert to BigNumber or fraction(x) to convert to Fraction.")}},{from:"Fraction",to:"Complex",convert:function(R){return _||ra(R),new _(R.valueOf(),0)}},{from:"number",to:"Fraction",convert:function(R){C||Ja(R);var O=new C(R);if(O.valueOf()!==R)throw new TypeError("Cannot implicitly convert a number to a Fraction when there will be a loss of precision (value: "+R+"). Use function fraction(x) to convert to Fraction.");return O}},{from:"string",to:"number",convert:function(R){var O=Number(R);if(isNaN(O))throw new Error('Cannot convert "'+R+'" to a number');return O}},{from:"string",to:"BigNumber",convert:function(R){b||nc(R);try{return new b(R)}catch{throw new Error('Cannot convert "'+R+'" to BigNumber')}}},{from:"string",to:"bigint",convert:function(R){try{return BigInt(R)}catch{throw new Error('Cannot convert "'+R+'" to BigInt')}}},{from:"string",to:"Fraction",convert:function(R){C||Ja(R);try{return new C(R)}catch{throw new Error('Cannot convert "'+R+'" to Fraction')}}},{from:"string",to:"Complex",convert:function(R){_||ra(R);try{return new _(R)}catch{throw new Error('Cannot convert "'+R+'" to Complex')}}},{from:"boolean",to:"number",convert:function(R){return+R}},{from:"boolean",to:"BigNumber",convert:function(R){return b||nc(R),new b(+R)}},{from:"boolean",to:"bigint",convert:function(R){return BigInt(+R)}},{from:"boolean",to:"Fraction",convert:function(R){return C||Ja(R),new C(+R)}},{from:"boolean",to:"string",convert:function(R){return String(R)}},{from:"Array",to:"Matrix",convert:function(R){return y||function Rf(){throw new Error("Cannot convert array into a Matrix: no class 'DenseMatrix' provided")}(),new y(R)}},{from:"Matrix",to:"Array",convert:function(R){return R.valueOf()}}]),A.onMismatch=(k,R,O)=>{var F=A.createError(k,R,O);if(["wrongType","mismatch"].includes(F.data.category)&&1===R.length&&Mt(R[0])&&O.some(H=>!H.params.includes(","))){var B=new TypeError("Function '".concat(k,"' doesn't apply to matrices. To call it ")+"elementwise on a matrix 'M', try 'map(M, ".concat(k,")'."));throw B.data=F.data,B}throw F},A.onMismatch=(k,R,O)=>{var F=A.createError(k,R,O);if(["wrongType","mismatch"].includes(F.data.category)&&1===R.length&&Mt(R[0])&&O.some(H=>!H.params.includes(","))){var B=new TypeError("Function '".concat(k,"' doesn't apply to matrices. To call it ")+"elementwise on a matrix 'M', try 'map(M, ".concat(k,")'."));throw B.data=F.data,B}throw F},A});function nc(p){throw new Error("Cannot convert value ".concat(p," into a BigNumber: no class 'BigNumber' provided"))}function ra(p){throw new Error("Cannot convert value ".concat(p," into a Complex number: no class 'Complex' provided"))}function Ja(p){throw new Error("Cannot convert value ".concat(p," into a Fraction, no class 'Fraction' provided."))}function Jc(p){var _,y,m=p.length,b=p[0].length,C=[];for(y=0;y<b;y++){var A=[];for(_=0;_<m;_++)A.push(p[_][y]);C.push(A)}return C}function sd(p){for(var m=0;m<p.length;m++)if(Mt(p[m]))return!0;return!1}function Ss(p,m){ut(p)&&(p=p.valueOf());for(var b=0,_=p.length;b<_;b++){var y=p[b];Array.isArray(y)?Ss(y,m):m(y)}}function ps(p,m,b){return p&&"function"==typeof p.map?p.map(function(_){return ps(_,m,b)}):m(p)}function eh(p,m,b){var _=Array.isArray(p)?Bs(p):p.size();if(m<0||m>=_.length)throw new bc(m,_.length);return ut(p)?p.create(Eh(p.valueOf(),m,b),p.datatype()):Eh(p,m,b)}function Eh(p,m,b){var _,y,C,A;if(m<=0){if(Array.isArray(p[0])){for(A=Jc(p),y=[],_=0;_<A.length;_++)y[_]=Eh(A[_],m-1,b);return y}for(C=p[0],_=1;_<p.length;_++)C=b(C,p[_]);return C}for(y=[],_=0;_<p.length;_++)y[_]=Eh(p[_],m-1,b);return y}function Gl(p,m,b,_,y,C,A,k,R,O,F){var J,be,we,B=p._values,H=p._index,G=p._ptr;if(_)for(be=G[m+1],J=G[m];J<be;J++)b[we=H[J]]!==C?(b[we]=C,A.push(we),O?(_[we]=R?k(B[J],F):k(F,B[J]),y[we]=C):_[we]=B[J]):(_[we]=R?k(B[J],_[we]):k(_[we],B[J]),y[we]=C);else for(be=G[m+1],J=G[m];J<be;J++)b[we=H[J]]!==C?(b[we]=C,A.push(we)):y[we]=C}var zu="number",Bd="number, number";function th(p){return Math.abs(p)}function V(p,m){return p+m}function Qe(p,m){return p-m}function E(p,m){return p*m}function ee(p){return-p}function Xe(p){return p}function Nt(p){return Ms(p)}function Ei(p){return p*p*p}function gr(p){return Math.exp(p)}function ur(p){return Ds(p)}function Gr(p,m){if(!ai(p)||!ai(m))throw new Error("Parameters in function lcm must be integer numbers");if(0===p||0===m)return 0;for(var b,_=p*m;0!==m;)m=p%(b=m),p=b;return Math.abs(_/p)}function cs(p){return Vr(p)}function el(p){return ho(p)}function Ga(p){var m=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,b=m<0;if(b&&(m=-m),0===m)throw new Error("Root must be non-zero");if(p<0&&Math.abs(m)%2!=1)throw new Error("Root must be odd when a is negative.");if(0===p)return b?1/0:0;if(!isFinite(p))return b?0:p;var _=Math.pow(Math.abs(p),1/m);return _=p<0?-_:_,b?1/_:_}function qa(p){return zr(p)}function Pm(p){return p*p}function nh(p,m){var b,_,y,C=0,A=1,k=1,R=0;if(!ai(p)||!ai(m))throw new Error("Parameters in function xgcd must be integer numbers");for(;m;)y=p-(_=Math.floor(p/m))*m,b=C,C=A-_*C,A=b,b=k,k=R-_*k,R=b,p=m,m=y;return p<0?[-p,-A,-R]:[p,p?A:0,R]}function ih(p,m){return p*p<1&&m===1/0||p*p>1&&m===-1/0?0:Math.pow(p,m)}function Jh(p){var m=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(!ai(m)||m<0||m>15)throw new Error("Number of decimals in function round must be an integer from 0 to 15 inclusive");return parseFloat(at(p,m))}th.signature=zu,V.signature=Bd,Qe.signature=Bd,E.signature=Bd,ee.signature=zu,Xe.signature=zu,Nt.signature=zu,Ei.signature=zu,gr.signature=zu,ur.signature=zu,Gr.signature=Bd,cs.signature=zu,el.signature=zu,qa.signature=zu,Pm.signature=zu,nh.signature=Bd,ih.signature=Bd;var ef=re("abs",["typed"],p=>{var{typed:m}=p;return m("abs",{number:th,"Complex | BigNumber | Fraction | Unit":b=>b.abs(),bigint:b=>b<0n?-b:b,"Array | Matrix":m.referToSelf(b=>_=>ps(_,b,!0))})}),wg=re("acos",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("acos",{number:function(C){return C>=-1&&C<=1||b.predictable?Math.acos(C):new _(C,0).acos()},Complex:function(C){return C.acos()},BigNumber:function(C){return C.acos()}})}),Dc="number";function tm(p){return fo(p)}function T(p){return Math.atan(1/p)}function P(p){return isFinite(p)?(Math.log((p+1)/p)+Math.log(p/(p-1)))/2:0}function W(p){return Math.asin(1/p)}function se(p){var m=1/p;return Math.log(m+Math.sqrt(m*m+1))}function me(p){return Math.acos(1/p)}function Fe(p){var m=1/p,b=Math.sqrt(m*m-1);return Math.log(b+m)}function Bt(p){return Uo(p)}function yi(p){return Gs(p)}function Wr(p){return 1/Math.tan(p)}function Yo(p){var m=Math.exp(2*p);return(m+1)/(m-1)}function Cl(p){return 1/Math.sin(p)}function pc(p){return 0===p?Number.POSITIVE_INFINITY:Math.abs(2/(Math.exp(p)-Math.exp(-p)))*zr(p)}function Yu(p){return 1/Math.cos(p)}function Yf(p){return 2/(Math.exp(p)+Math.exp(-p))}function vu(p){return Za(p)}tm.signature=Dc,T.signature=Dc,P.signature=Dc,W.signature=Dc,se.signature=Dc,me.signature=Dc,Fe.signature=Dc,Bt.signature=Dc,yi.signature=Dc,Wr.signature=Dc,Yo.signature=Dc,Cl.signature=Dc,pc.signature=Dc,Yu.signature=Dc,Yf.signature=Dc,vu.signature=Dc;var Tr=re("acot",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("acot",{number:T,Complex:function(y){return y.acot()},BigNumber:function(y){return new b(1).div(y).atan()}})}),ka=re("acsc",["typed","config","Complex","BigNumber"],p=>{var{typed:m,config:b,Complex:_,BigNumber:y}=p;return m("acsc",{number:function(A){return A<=-1||A>=1||b.predictable?W(A):new _(A,0).acsc()},Complex:function(A){return A.acsc()},BigNumber:function(A){return new y(1).div(A).asin()}})}),Lf="addScalar",oh=re(Lf,["typed"],p=>{var{typed:m}=p;return m(Lf,{"number, number":V,"Complex, Complex":function(_,y){return _.add(y)},"BigNumber, BigNumber":function(_,y){return _.plus(y)},"bigint, bigint":function(_,y){return _+y},"Fraction, Fraction":function(_,y){return _.add(y)},"Unit, Unit":m.referToSelf(b=>(_,y)=>{if(null==_.value)throw new Error("Parameter x contains a unit with undefined value");if(null==y.value)throw new Error("Parameter y contains a unit with undefined value");if(!_.equalBase(y))throw new Error("Units do not match");var C=_.clone();return C.value=m.find(b,[C.valueType(),y.valueType()])(C.value,y.value),C.fixPrefix=!1,C})})}),vf=re("arg",["typed"],p=>{var{typed:m}=p;return m("arg",{number:function(_){return Math.atan2(0,_)},BigNumber:function(_){return _.constructor.atan2(0,_)},Complex:function(_){return _.arg()},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),Bm=re("asech",["typed","config","Complex","BigNumber"],p=>{var{typed:m,config:b,Complex:_,BigNumber:y}=p;return m("asech",{number:function(A){if(A<=1&&A>=-1||b.predictable){var k=1/A;if(k>0||b.predictable)return Fe(A);var R=Math.sqrt(k*k-1);return new _(Math.log(R-k),Math.PI)}return new _(A,0).asech()},Complex:function(A){return A.asech()},BigNumber:function(A){return new y(1).div(A).acosh()}})}),Ko=re("asinh",["typed"],p=>{var{typed:m}=p;return m("asinh",{number:Bt,Complex:function(_){return _.asinh()},BigNumber:function(_){return _.asinh()}})}),wc=re("atan",["typed"],p=>{var{typed:m}=p;return m("atan",{number:function(_){return Math.atan(_)},Complex:function(_){return _.atan()},BigNumber:function(_){return _.atan()}})}),Mh=re("atanh",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("atanh",{number:function(C){return C<=1&&C>=-1||b.predictable?yi(C):new _(C,0).atanh()},Complex:function(C){return C.atanh()},BigNumber:function(C){return C.atanh()}})}),nD=re("bigint",["typed"],p=>{var{typed:m}=p,b=m("bigint",{"":function(){return 0n},bigint:function(y){return y},number:function(y){return BigInt(y.toFixed())},BigNumber:function(y){return BigInt(y.round().toString())},Fraction:function(y){return BigInt(y.valueOf().toFixed())},"string | boolean":function(y){return BigInt(y)},null:function(y){return 0n},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))});return b.fromJSON=function(_){return BigInt(_.value)},b});function iD(p,m){if(p.isFinite()&&!p.isInteger()||m.isFinite()&&!m.isInteger())throw new Error("Integers expected in function bitAnd");var b=p.constructor;if(p.isNaN()||m.isNaN())return new b(NaN);if(p.isZero()||m.eq(-1)||p.eq(m))return p;if(m.isZero()||p.eq(-1))return m;if(!p.isFinite()||!m.isFinite()){if(!p.isFinite()&&!m.isFinite())return p.isNegative()===m.isNegative()?p:new b(0);if(!p.isFinite())return m.isNegative()?p:p.isNegative()?new b(0):m;if(!m.isFinite())return p.isNegative()?m:m.isNegative()?new b(0):p}return Sg(p,m,function(_,y){return _&y})}function T0(p){if(p.isFinite()&&!p.isInteger())throw new Error("Integer expected in function bitNot");var m=p.constructor,b=m.precision;m.config({precision:1e9});var _=p.plus(new m(1));return _.s=-_.s||null,m.config({precision:b}),_}function cx(p,m){if(p.isFinite()&&!p.isInteger()||m.isFinite()&&!m.isInteger())throw new Error("Integers expected in function bitOr");var b=p.constructor;if(p.isNaN()||m.isNaN())return new b(NaN);var _=new b(-1);return p.isZero()||m.eq(_)||p.eq(m)?m:m.isZero()||p.eq(_)?p:p.isFinite()&&m.isFinite()?Sg(p,m,function(y,C){return y|C}):!p.isFinite()&&!p.isNegative()&&m.isNegative()||p.isNegative()&&!m.isNegative()&&!m.isFinite()?_:p.isNegative()&&m.isNegative()?p.isFinite()?p:m:p.isFinite()?m:p}function Sg(p,m,b){var y,C,F,B,H,_=p.constructor,A=+(p.s<0),k=+(m.s<0);if(A){y=rD(T0(p));for(var R=0;R<y.length;++R)y[R]^=1}else y=rD(p);if(k){C=rD(T0(m));for(var O=0;O<C.length;++O)C[O]^=1}else C=rD(m);y.length<=C.length?(F=y,B=C,H=A):(F=C,B=y,H=k);var G=F.length,J=B.length,te=1^b(A,k),be=new _(1^te),we=new _(1),Le=new _(2),de=_.precision;for(_.config({precision:1e9});G>0;)b(F[--G],B[--J])===te&&(be=be.plus(we)),we=we.times(Le);for(;J>0;)b(H,B[--J])===te&&(be=be.plus(we)),we=we.times(Le);return _.config({precision:de}),0===te&&(be.s=-be.s),be}function rD(p){for(var m=p.d,b=m[0]+"",_=1;_<m.length;++_){for(var y=m[_]+"",C=7-y.length;C--;)y="0"+y;b+=y}for(var A=b.length;"0"===b.charAt(A);)A--;var k=p.e,R=b.slice(0,A+1||1),O=R.length;if(k>0)if(++k>O)for(k-=O;k--;)R+="0";else k<O&&(R=R.slice(0,k)+"."+R.slice(k));for(var F=[0],B=0;B<R.length;){for(var H=F.length;H--;)F[H]*=10;F[0]+=parseInt(R.charAt(B++));for(var G=0;G<F.length;++G)F[G]>1&&(null==F[G+1]&&(F[G+1]=0),F[G+1]+=F[G]>>1,F[G]&=1)}return F.reverse()}function ux(p,m){if(p.isFinite()&&!p.isInteger()||m.isFinite()&&!m.isInteger())throw new Error("Integers expected in function bitXor");var b=p.constructor;if(p.isNaN()||m.isNaN())return new b(NaN);if(p.isZero())return m;if(m.isZero())return p;if(p.eq(m))return new b(0);var _=new b(-1);return p.eq(_)?T0(m):m.eq(_)?T0(p):p.isFinite()&&m.isFinite()?Sg(p,m,function(y,C){return y^C}):p.isFinite()||m.isFinite()?new b(p.isNegative()===m.isNegative()?1/0:-1/0):_}function Ap(p,m){if(p.isFinite()&&!p.isInteger()||m.isFinite()&&!m.isInteger())throw new Error("Integers expected in function leftShift");var b=p.constructor;return p.isNaN()||m.isNaN()||m.isNegative()&&!m.isZero()?new b(NaN):p.isZero()||m.isZero()?p:p.isFinite()||m.isFinite()?m.lt(55)?p.times(Math.pow(2,m.toNumber())+""):p.times(new b(2).pow(m)):new b(NaN)}function _E(p,m){if(p.isFinite()&&!p.isInteger()||m.isFinite()&&!m.isInteger())throw new Error("Integers expected in function rightArithShift");var b=p.constructor;return p.isNaN()||m.isNaN()||m.isNegative()&&!m.isZero()?new b(NaN):p.isZero()||m.isZero()?p:m.isFinite()?m.lt(55)?p.div(Math.pow(2,m.toNumber())+"").floor():p.div(new b(2).pow(m)).floor():p.isNegative()?new b(-1):p.isFinite()?new b(0):new b(NaN)}var mr="number, number";function Ua(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function bitAnd");return p&m}function Op(p){if(!ai(p))throw new Error("Integer expected in function bitNot");return~p}function oD(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function bitOr");return p|m}function Pl(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function bitXor");return p^m}function dx(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function leftShift");return p<<m}function fa(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function rightArithShift");return p>>m}function Ih(p,m){if(!ai(p)||!ai(m))throw new Error("Integers expected in function rightLogShift");return p>>>m}Ua.signature=mr,Op.signature="number",oD.signature=mr,Pl.signature=mr,dx.signature=mr,fa.signature=mr,Ih.signature=mr;var a1=re("bitNot",["typed"],p=>{var{typed:m}=p;return m("bitNot",{number:Op,BigNumber:T0,bigint:b=>~b,"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),yE="boolean",I0=re(yE,["typed"],p=>{var{typed:m}=p;return m(yE,{"":function(){return!1},boolean:function(_){return _},number:function(_){return!!_},null:function(_){return!1},BigNumber:function(_){return!_.isZero()},string:function(_){var y=_.toLowerCase();if("true"===y)return!0;if("false"===y)return!1;var C=Number(_);if(""!==_&&!isNaN(C))return!!C;throw new Error('Cannot convert "'+_+'" to a boolean')},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),nf=re("clone",["typed"],p=>{var{typed:m}=p;return m("clone",{any:At})});function _f(p,m){if(m<p)return 1;if(m===p)return m;var b=m+p>>1;return _f(p,b)*_f(b+1,m)}function lD(p,m){if(!ai(p)||p<0)throw new TypeError("Positive integer value expected in function combinations");if(!ai(m)||m<0)throw new TypeError("Positive integer value expected in function combinations");if(m>p)throw new TypeError("k must be less than or equal to n");for(var b=p-m,_=1,C=2,A=m<b?m:b,k=m<b?b+1:m+1;k<=p;++k)for(_*=k;C<=A&&_%C==0;)_/=C,++C;return C<=A&&(_/=_f(C,A)),_}lD.signature="number, number";var Fp="combinations",cD=re(Fp,["typed"],p=>{var{typed:m}=p;return m(Fp,{"number, number":lD,"BigNumber, BigNumber":function(_,y){var A,k,C=_.constructor,R=_.minus(y),O=new C(1);if(!uD(_)||!uD(y))throw new TypeError("Positive integer value expected in function combinations");if(y.gt(_))throw new TypeError("k must be less than n in function combinations");if(A=O,y.lt(R))for(k=O;k.lte(R);k=k.plus(O))A=A.times(y.plus(k)).dividedBy(k);else for(k=O;k.lte(y);k=k.plus(O))A=A.times(R.plus(k)).dividedBy(k);return A}})});function uD(p){return p.isInteger()&&p.gte(0)}var Fv=re("complex",["typed","Complex"],p=>{var{typed:m,Complex:b}=p;return m("complex",{"":function(){return b.ZERO},number:function(y){return new b(y,0)},"number, number":function(y,C){return new b(y,C)},"BigNumber, BigNumber":function(y,C){return new b(y.toNumber(),C.toNumber())},Fraction:function(y){return new b(y.valueOf(),0)},Complex:function(y){return y.clone()},string:function(y){return b(y)},null:function(y){return b(0)},Object:function(y){if("re"in y&&"im"in y)return new b(y.re,y.im);if("r"in y&&"phi"in y||"abs"in y&&"arg"in y)return new b(y);throw new Error("Expected object with properties (re and im) or (r and phi) or (abs and arg)")},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),K_=re("conj",["typed"],p=>{var{typed:m}=p;return m("conj",{"number | BigNumber | Fraction":b=>b,Complex:b=>b.conjugate(),"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),q_=re("trigUnit",["typed"],p=>{var{typed:m}=p;return{Unit:m.referToSelf(b=>_=>{if(!_.hasBase(_.constructor.BASE_UNITS.ANGLE))throw new TypeError("Unit in function cot is no angle");return m.find(b,_.valueType())(_.value)})}}),l1=re("cos",["typed"],p=>{var{typed:m}=p,b=q_({typed:m});return m("cos",{number:Math.cos,"Complex | BigNumber":_=>_.cos()},b)}),Tg=re("cot",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("cot",{number:Wr,Complex:y=>y.cot(),BigNumber:y=>new b(1).div(y.tan())},q_({typed:m}))}),Vd=re("csc",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("csc",{number:Cl,Complex:y=>y.csc(),BigNumber:y=>new b(1).div(y.sin())},q_({typed:m}))}),A0=re("cube",["typed"],p=>{var{typed:m}=p;return m("cube",{number:Ei,Complex:function(_){return _.mul(_).mul(_)},BigNumber:function(_){return _.times(_).times(_)},bigint:function(_){return _*_*_},Fraction:function(_){return _.pow(3)},Unit:function(_){return _.pow(3)}})});function Zf(p,m){var b=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e-9,_=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;if(b<=0)throw new Error("Relative tolerance must be greater than 0");if(_<0)throw new Error("Absolute tolerance must be at least 0");return!p.isNaN()&&!m.isNaN()&&(p.isFinite()&&m.isFinite()?!!p.eq(m)||p.minus(m).abs().lte(p.constructor.max(p.constructor.max(p.abs(),m.abs()).mul(b),_)):p.eq(m))}var Nv=re("compareUnits",["typed"],p=>{var{typed:m}=p;return{"Unit, Unit":m.referToSelf(b=>(_,y)=>{if(!_.equalBase(y))throw new Error("Cannot compare units with different base");return m.find(b,[_.valueType(),y.valueType()])(_.value,y.value)})}}),c1="equalScalar",Rv=re(c1,["typed","config"],p=>{var{typed:m,config:b}=p,_=Nv({typed:m});return m(c1,{"boolean, boolean":function(C,A){return C===A},"number, number":function(C,A){return Di(C,A,b.relTol,b.absTol)},"BigNumber, BigNumber":function(C,A){return C.eq(A)||Zf(C,A,b.relTol,b.absTol)},"bigint, bigint":function(C,A){return C===A},"Fraction, Fraction":function(C,A){return C.equals(A)},"Complex, Complex":function(C,A){return function pD(p,m,b,_){return Di(p.re,m.re,b,_)&&Di(p.im,m.im,b,_)}(C,A,b.relTol,b.absTol)}},_)}),Q_=(re(c1,["typed","config"],p=>{var{typed:m,config:b}=p;return m(c1,{"number, number":function(y,C){return Di(y,C,b.relTol,b.absTol)}})}),re("erf",["typed"],p=>{var{typed:m}=p;return m("name",{number:function(A){var k=Math.abs(A);return k>=wE?zr(A):k<=d1?zr(A)*function b(C){var O,A=C*C,k=Np[0][4]*A,R=A;for(O=0;O<3;O+=1)k=(k+Np[0][O])*A,R=(R+Y_[0][O])*A;return C*(k+Np[0][3])/(R+Y_[0][3])}(k):k<=4?zr(A)*(1-function _(C){var R,A=Np[1][8]*C,k=C;for(R=0;R<7;R+=1)A=(A+Np[1][R])*C,k=(k+Y_[1][R])*C;var O=(A+Np[1][7])/(k+Y_[1][7]),F=parseInt(16*C)/16,B=(C-F)*(C+F);return Math.exp(-F*F)*Math.exp(-B)*O}(k)):zr(A)*(1-function y(C){var O,A=1/(C*C),k=Np[2][5]*A,R=A;for(O=0;O<4;O+=1)k=(k+Np[2][O])*A,R=(R+Y_[2][O])*A;var F=A*(k+Np[2][4])/(R+Y_[2][4]);F=(Lv-F)/C;var B=(C-(A=parseInt(16*C)/16))*(C+A);return Math.exp(-A*A)*Math.exp(-B)*F}(k))},"Array | Matrix":m.referToSelf(C=>A=>ps(A,C))})})),d1=.46875,Lv=.5641895835477563,Np=[[3.1611237438705655,113.86415415105016,377.485237685302,3209.3775891384694,.18577770618460315],[.5641884969886701,8.883149794388377,66.11919063714163,298.6351381974001,881.952221241769,1712.0476126340707,2051.0783778260716,1230.3393547979972,2.1531153547440383e-8],[.30532663496123236,.36034489994980445,.12578172611122926,.016083785148742275,.0006587491615298378,.016315387137302097]],Y_=[[23.601290952344122,244.02463793444417,1282.6165260773723,2844.236833439171],[15.744926110709835,117.6939508913125,537.1811018620099,1621.3895745666903,3290.7992357334597,4362.619090143247,3439.3676741437216,1230.3393548037495],[2.568520192289822,1.8729528499234604,.5279051029514285,.06051834131244132,.0023352049762686918]],wE=Math.pow(2,53),F0=re("exp",["typed"],p=>{var{typed:m}=p;return m("exp",{number:gr,Complex:function(_){return _.exp()},BigNumber:function(_){return _.exp()}})}),Um=re("expm1",["typed","Complex"],p=>{var{typed:m,Complex:b}=p;return m("expm1",{number:ur,Complex:function(y){var C=Math.exp(y.re);return new b(C*Math.cos(y.im)-1,C*Math.sin(y.im))},BigNumber:function(y){return y.exp().minus(1)}})}),mD=re("filter",["typed"],p=>{var{typed:m}=p;return m("filter",{"Array, function":gD,"Matrix, function":function(_,y){return _.create(gD(_.valueOf(),y),_.datatype())},"Array, RegExp":xh,"Matrix, RegExp":function(_,y){return _.create(xh(_.valueOf(),y),_.datatype())}})});function gD(p,m){var b=yd(m,p,"filter");return function Zp(p,m){if(1!==Bs(p).length)throw new Error("Only one dimensional matrices supported");return Array.prototype.filter.call(p,m)}(p,function(_,y,C){return b(_,[y],C)})}var nm="flatten",$m=re(nm,["typed"],p=>{var{typed:m}=p;return m(nm,{Array:function(_){return ns(_)},Matrix:function(_){return _.create(ns(_.toArray()),_.datatype())}})}),im="forEach",Oh=re(im,["typed"],p=>{var{typed:m}=p;return m(im,{"Array, function":N0,"Matrix, function":function(_,y){_.forEach(y)}})});function N0(p,m){Zh(p,[],p,yd(m,p,im))}var _D=re("format",["typed"],p=>{var{typed:m}=p;return m("format",{any:xs,"any, Object | function | number | BigNumber":xs})}),_x="getMatrixDataType",p1=re(_x,["typed"],p=>{var{typed:m}=p;return m(_x,{Array:function(_){return Qf(_,pi)},Matrix:function(_){return _.getDataType()}})}),Pv=re("hex",["typed","format"],p=>{var{typed:m,format:b}=p;return m("hex",{"number | BigNumber":function(y){return b(y,{notation:"hex"})},"number | BigNumber, number | BigNumber":function(y,C){return b(y,{notation:"hex",wordSize:C})}})}),Og=re("im",["typed"],p=>{var{typed:m}=p;return m("im",{number:()=>0,"BigNumber | Fraction":b=>b.mul(0),Complex:b=>b.im,"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),ah="isInteger",rm=re(ah,["typed"],p=>{var{typed:m}=p;return m(ah,{number:ai,BigNumber:function(_){return _.isInt()},bigint:function(_){return!0},Fraction:function(_){return 1===_.d&&isFinite(_.n)},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),om="number";function yD(p){return p<0}function Cx(p){return p>0}function ic(p){return Number.isNaN(p)}yD.signature=om,Cx.signature=om,ic.signature=om;var Dx="isNegative",Bv=re(Dx,["typed","config"],p=>{var{typed:m,config:b}=p;return m(Dx,{number:_=>!Di(_,0,b.relTol,b.absTol)&&yD(_),BigNumber:_=>!Zf(_,new _.constructor(0),b.relTol,b.absTol)&&_.isNeg()&&!_.isZero()&&!_.isNaN(),bigint:_=>_<0n,Fraction:_=>_.s<0,Unit:m.referToSelf(_=>y=>m.find(_,y.valueType())(y.value)),"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),Fg="isPositive",ad=re(Fg,["typed","config"],p=>{var{typed:m,config:b}=p;return m(Fg,{number:_=>!Di(_,0,b.relTol,b.absTol)&&Cx(_),BigNumber:_=>!(Zf(_,new _.constructor(0),b.relTol,b.absTol)||_.isNeg()||_.isZero()||_.isNaN()),bigint:_=>_>0n,Fraction:_=>_.s>0&&_.n>0,Unit:m.referToSelf(_=>y=>m.find(_,y.valueType())(y.value)),"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),Ng=re("isZero",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return m("isZero",{"number | BigNumber | Complex | Fraction":_=>b(_,0),bigint:_=>0n===_,Unit:m.referToSelf(_=>y=>m.find(_,y.valueType())(y.value)),"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})});function Id(p){var m;if(ai(p))return p<=0?isFinite(p)?1/0:NaN:p>171?1/0:_f(1,p-1);if(p<.5)return Math.PI/(Math.sin(Math.PI*p)*Id(1-p));if(p>=171.35)return 1/0;if(p>85){var b=p*p,_=b*p,y=_*p,C=y*p;return Math.sqrt(2*Math.PI/p)*Math.pow(p/Math.E,p)*(1+1/(12*p)+1/(288*b)-139/(51840*_)-571/(2488320*y)+163879/(209018880*C)+5246819/(75246796800*C*p))}--p,m=up[0];for(var A=1;A<up.length;++A)m+=up[A]/(p+A);var k=p+J_+.5;return Math.sqrt(2*Math.PI)*Math.pow(k,p+.5)*Math.exp(-k)*m}Id.signature="number";var J_=4.7421875,up=[.9999999999999971,57.15623566586292,-59.59796035547549,14.136097974741746,-.4919138160976202,3399464998481189e-20,4652362892704858e-20,-9837447530487956e-20,.0001580887032249125,-.00021026444172410488,.00021743961811521265,-.0001643181065367639,8441822398385275e-20,-26190838401581408e-21,36899182659531625e-22],ey=.9189385332046728,P0=[1.000000000190015,76.18009172947146,-86.50532032941678,24.01409824083091,-1.231739572450155,.001208650973866179,-5395239384953e-18];function kf(p){if(p<0)return NaN;if(0===p)return 1/0;if(!isFinite(p))return p;if(p<.5)return Math.log(Math.PI/Math.sin(Math.PI*p))-kf(1-p);for(var m=5+(p-=1)+.5,b=P0[0],_=6;_>=1;_--)b+=P0[_]/(p+_);return ey+(p+.5)*Math.log(m)-m+Math.log(b)}kf.signature="number";var B0=re("lgamma",["Complex","typed"],p=>{var{Complex:m,typed:b}=p,C=[-.029550653594771242,.00641025641025641,-.0019175269175269176,.0008417508417508417,-.0005952380952380953,.0007936507936507937,-.002777777777777778,.08333333333333333];return b("lgamma",{number:kf,Complex:function A(O){if(O.isNaN())return new m(NaN,NaN);if(0===O.im)return new m(kf(O.re),0);if(O.re>=7||Math.abs(O.im)>=7)return k(O);if(O.re<=.1){var G=function ac(p,m){return(p>0||!(p<0)&&1/p==1/0)^(m>0||!(m<0)&&1/m==1/0)?-p:p}(6.283185307179586,O.im)*Math.floor(.5*O.re+.25),J=O.mul(Math.PI).sin().log(),te=A(new m(1-O.re,-O.im));return new m(1.1447298858494002,G).sub(J).sub(te)}return O.im>=0?R(O):R(O.conjugate()).conjugate()},BigNumber:function(){throw new Error("mathjs doesn't yet provide an implementation of the algorithm lgamma for BigNumber")}});function k(O){for(var F=O.sub(.5).mul(O.log()).sub(O).add(ey),B=new m(1,0).div(O),H=B.div(O),G=C[0],J=C[1],te=2*H.re,be=H.re*H.re+H.im*H.im,we=2;we<8;we++){var Le=J;J=-be*G+C[we],G=te*G+Le}var de=B.mul(H.mul(G).add(J));return F.add(de)}function R(O){var F=0,B=0,H=O;for(O=O.add(1);O.re<=7;){var G=(H=H.mul(O)).im<0?1:0;0!==G&&0===B&&F++,B=G,O=O.add(1)}return k(O).sub(H.log()).sub(new m(0,2*F*Math.PI*1))}}),ty=re("log10",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("log10",{number:function(C){return C>=0||b.predictable?cs(C):new _(C,0).log().div(Math.LN10)},Complex:function(C){return new _(C).log().div(Math.LN10)},BigNumber:function(C){return!C.isNegative()||b.predictable?C.log():new _(C.toNumber(),0).log().div(Math.LN10)},"Array | Matrix":m.referToSelf(y=>C=>ps(C,y))})}),hl=re("log2",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("log2",{number:function(A){return A>=0||b.predictable?el(A):y(new _(A,0))},Complex:y,BigNumber:function(A){return!A.isNegative()||b.predictable?A.log(2):y(new _(A.toNumber(),0))},"Array | Matrix":m.referToSelf(C=>A=>ps(A,C))});function y(C){var A=Math.sqrt(C.re*C.re+C.im*C.im);return new _(Math.log2?Math.log2(A):Math.log(A)/Math.LN2,Math.atan2(C.im,C.re)/Math.LN2)}}),Ou=re("map",["typed"],p=>{var{typed:m}=p;return m("map",{"Array, function":_,"Matrix, function":function(C,A){return C.map(A)},"Array|Matrix, Array|Matrix, ...Array|Matrix|function":(y,C,A)=>function b(y,C){if("function"!=typeof C)throw new Error("Last argument must be a callback function");var F,A=y[0].isMatrix,k=Xh(...y.map(Te=>Te.isMatrix?Te.size():Bs(Te))),R=A?(Te,De)=>Te.get(De):mu,O=y.map(A?Te=>Te.isMatrix?Te.create(od(Te.toArray(),k),Te.datatype()):y[0].create(od(Te.valueOf(),k)):Te=>od(Te.isMatrix?Te.toArray():Te,k));if(m.isTypedFunction(C)){var B=k.map(()=>0),H=O.map(Te=>R(Te,B)),G=function de(Te,De,pe,Be){return null!==m.resolve(Te,[...De,pe,...Be])?2:null!==m.resolve(Te,[...De,pe])?1:(m.resolve(Te,De),0)}(C,H,B,O);F=we(G)}else{var te=function Le(Te,De){return Te.length>De+1?2:Te.length===De+1?1:0}(C,y.length);F=we(te)}var be=(Te,De)=>F([Te,...O.slice(1).map(pe=>R(pe,De))],De);return A?O[0].map(be):_(O[0],be);function we(Te){switch(Te){case 0:return De=>C(...De);case 1:return(De,pe)=>C(...De,pe);case 2:return(De,pe)=>C(...De,pe,...O)}}}([y,C,...A.slice(0,A.length-1)],A[A.length-1])});function _(y,C){return Zh(y,[],y,yd(C,y,"map"))}}),m1=re("multiplyScalar",["typed"],p=>{var{typed:m}=p;return m("multiplyScalar",{"number, number":E,"Complex, Complex":function(_,y){return _.mul(y)},"BigNumber, BigNumber":function(_,y){return _.times(y)},"bigint, bigint":function(_,y){return _*y},"Fraction, Fraction":function(_,y){return _.mul(y)},"number | Fraction | BigNumber | Complex, Unit":(b,_)=>_.multiply(b),"Unit, number | Fraction | BigNumber | Complex | Unit":(b,_)=>b.multiply(_)})}),wD="number, number";function Lg(p){return!p}function V0(p,m){return!(!p&&!m)}function ny(p,m){return!!p!=!!m}function iy(p,m){return!(!p||!m)}Lg.signature="number",V0.signature=wD,ny.signature=wD,iy.signature=wD;var Wm=re("not",["typed"],p=>{var{typed:m}=p;return m("not",{"null | undefined":()=>!0,number:Lg,Complex:function(_){return 0===_.re&&0===_.im},BigNumber:function(_){return _.isZero()||_.isNaN()},bigint:b=>!b,Unit:m.referToSelf(b=>_=>m.find(b,_.valueType())(_.value)),"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),xD=re("number",["typed"],p=>{var{typed:m}=p,b=m("number",{"":function(){return 0},number:function(y){return y},string:function(y){if("NaN"===y)return NaN;var C=function Ad(p){var m=p.match(/(0[box])([0-9a-fA-F]*)\.([0-9a-fA-F]*)/);return m?{input:p,radix:{"0b":2,"0o":8,"0x":16}[m[1]],integerPart:m[2],fractionalPart:m[3]}:null}(y);if(C)return function ry(p){for(var m=parseInt(p.integerPart,p.radix),b=0,_=0;_<p.fractionalPart.length;_++)b+=parseInt(p.fractionalPart[_],p.radix)/Math.pow(p.radix,_+1);var C=m+b;if(isNaN(C))throw new SyntaxError('String "'+p.input+'" is not a valid number');return C}(C);var A=0,k=y.match(/(0[box][0-9a-fA-F]*)i([0-9]*)/);k&&(A=Number(k[2]),y=k[1]);var R=Number(y);if(isNaN(R))throw new SyntaxError('String "'+y+'" is not a valid number');if(k){if(R>2**A-1)throw new SyntaxError('String "'.concat(y,'" is out of range'));R>=2**(A-1)&&(R-=2**A)}return R},BigNumber:function(y){return y.toNumber()},bigint:function(y){return Number(y)},Fraction:function(y){return y.valueOf()},Unit:m.referToSelf(_=>y=>{var C=y.clone();return C.value=_(y.value),C}),null:function(y){return 0},"Unit, string | Unit":function(y,C){return y.toNumber(C)},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))});return b.fromJSON=function(_){return parseFloat(_.value)},b}),Lp=re("oct",["typed","format"],p=>{var{typed:m,format:b}=p;return m("oct",{"number | BigNumber":function(y){return b(y,{notation:"oct"})},"number | BigNumber, number | BigNumber":function(y,C){return b(y,{notation:"oct",wordSize:C})}})}),yf=S(6433),Uc=yf(Date.now());function am(p){var m;return function b(y){m=null===y?Uc:yf(String(y))}(p),function _(){return m()}}var oy="pickRandom",v1=re(oy,["typed","config","?on"],p=>{var{typed:m,config:b,on:_}=p,y=am(b.randomSeed);return _&&_("config",function(A,k){A.randomSeed!==k.randomSeed&&(y=am(A.randomSeed))}),m(oy,{"Array | Matrix":function(k){return C(k,{})},"Array | Matrix, Object":function(k,R){return C(k,R)},"Array | Matrix, number":function(k,R){return C(k,{number:R})},"Array | Matrix, Array | Matrix":function(k,R){return C(k,{weights:R})},"Array | Matrix, Array | Matrix, number":function(k,R,O){return C(k,{number:O,weights:R})},"Array | Matrix, number, Array | Matrix":function(k,R,O){return C(k,{number:R,weights:O})}});function C(A,k){var{number:R,weights:O,elementWise:F=!0}=k,B=typeof R>"u";B&&(R=1);var H=ut(A)?A.create:ut(O)?O.create:null;A=A.valueOf(),O&&(O=O.valueOf()),!0===F&&(A=ns(A),O=ns(O));var G=0;if(typeof O<"u"){if(O.length!==A.length)throw new Error("Weights must have the same length as possibles");for(var J=0,te=O.length;J<te;J++){if(!ct(O[J])||O[J]<0)throw new Error("Weights must be an array of positive numbers");G+=O[J]}}for(var Le,be=A.length,we=[];we.length<R;){if(typeof O>"u")Le=A[Math.floor(y()*be)];else for(var de=y()*G,Te=0,De=A.length;Te<De;Te++)if((de-=O[Te])<0){Le=A[Te];break}we.push(Le)}return B?we[0]:H?H(we):we}}),_1=/\$([\w.]+)/g,$v=re("print",["typed"],p=>{var{typed:m}=p;return m("print",{"string, Object | Array":Ax,"string, Object | Array, number | Object":Ax})});function Ax(p,m,b){return p.replace(_1,function(_,y){var C=y.split("."),A=m[C.shift()];for(void 0!==A&&A.isMatrix&&(A=A.toArray());C.length&&void 0!==A;){var k=C.shift();A=k?A[k]:A+"."}return void 0!==A?Ae(A)?A:xs(A,b):_})}function Ox(p,m){var b=[];if((p=p.slice(0)).length>1)for(var _=0,y=p.shift();_<y;_++)b.push(Ox(p,m));else for(var C=0,A=p.shift();C<A;C++)b.push(m());return b}var Lh=re("random",["typed","config","?on"],p=>{var{typed:m,config:b,on:_}=p,y=am(b.randomSeed);return _&&_("config",function(k,R){k.randomSeed!==R.randomSeed&&(y=am(k.randomSeed))}),m("random",{"":()=>A(0,1),number:k=>A(0,k),"number, number":(k,R)=>A(k,R),"Array | Matrix":k=>C(k,0,1),"Array | Matrix, number":(k,R)=>C(k,0,R),"Array | Matrix, number, number":(k,R,O)=>C(k,R,O)});function C(k,R,O){var F=Ox(k.valueOf(),()=>A(R,O));return ut(k)?k.create(F,"number"):F}function A(k,R){return k+y()*(R-k)}}),SD=re("re",["typed"],p=>{var{typed:m}=p;return m("re",{"number | BigNumber | Fraction":b=>b,Complex:b=>b.re,"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),$0=re("sec",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("sec",{number:Yu,Complex:y=>y.sec(),BigNumber:y=>new b(1).div(y.cos())},q_({typed:m}))}),Hm=re("sign",["typed","BigNumber","Fraction","complex"],p=>{var{typed:m,BigNumber:b,complex:_,Fraction:y}=p;return m("sign",{number:qa,Complex:function(A){return 0===A.im?_(qa(A.re)):A.sign()},BigNumber:function(A){return new b(A.cmp(0))},bigint:function(A){return A>0n?1n:A<0n?-1n:0n},Fraction:function(A){return new y(A.s,1)},"Array | Matrix":m.referToSelf(C=>A=>ps(A,C,!0)),Unit:m.referToSelf(C=>A=>{if(!A._isDerived()&&0!==A.units[0].unit.offset)throw new TypeError("sign is ambiguous for units with offset");return m.find(C,A.valueType())(A.value)})})}),lm=re("sin",["typed"],p=>{var{typed:m}=p,b=q_({typed:m});return m("sin",{number:Math.sin,"Complex | BigNumber":_=>_.sin()},b)}),H0=re("SparseMatrix",["typed","equalScalar","Matrix"],p=>{var{typed:m,equalScalar:b,Matrix:_}=p;function y(te,be){if(!(this instanceof y))throw new SyntaxError("Constructor must be called with the new operator");if(be&&!Ae(be))throw new Error("Invalid datatype: "+be);if(ut(te))!function C(te,be,we){"SparseMatrix"===be.type?(te._values=be._values?At(be._values):void 0,te._index=At(be._index),te._ptr=At(be._ptr),te._size=At(be._size),te._datatype=we||be._datatype):A(te,be.valueOf(),we||be._datatype)}(this,te,be);else if(te&&dt(te.index)&&dt(te.ptr)&&dt(te.size))this._values=te.values,this._index=te.index,this._ptr=te.ptr,this._size=te.size,this._datatype=be||te.datatype;else if(dt(te))A(this,te,be);else{if(te)throw new TypeError("Unsupported type of data ("+pi(te)+")");this._values=[],this._index=[],this._ptr=[0],this._size=[0,0],this._datatype=be}}function A(te,be,we){te._values=[],te._index=[],te._ptr=[],te._datatype=we;var Le=be.length,de=0,Te=b,De=0;if(Ae(we)&&(Te=m.find(b,[we,we])||b,De=m.convert(0,we)),Le>0){var pe=0;do{te._ptr.push(te._index.length);for(var Be=0;Be<Le;Be++){var We=be[Be];if(dt(We)){if(0===pe&&de<We.length&&(de=We.length),pe<We.length){var ke=We[pe];Te(ke,De)||(te._values.push(ke),te._index.push(Be))}}else 0===pe&&de<1&&(de=1),Te(We,De)||(te._values.push(We),te._index.push(Be))}pe++}while(pe<de)}te._ptr.push(te._index.length),te._size=[Le,de]}function O(te,be,we,Le){if(we-be==0)return we;for(var de=be;de<we;de++)if(Le[de]===te)return de;return be}function B(te,be,we,Le,de,Te,De){de.splice(te,0,Le),Te.splice(te,0,be);for(var pe=we+1;pe<De.length;pe++)De[pe]++}function H(te,be,we,Le){var de=Le||0,Te=b,De=0;Ae(te._datatype)&&(Te=m.find(b,[te._datatype,te._datatype])||b,De=m.convert(0,te._datatype),de=m.convert(de,te._datatype));var ke,ze,et,pe=!Te(de,De),Be=te._size[0],We=te._size[1];if(we>We){for(ze=We;ze<we;ze++)if(te._ptr[ze]=te._values.length,pe)for(ke=0;ke<Be;ke++)te._values.push(de),te._index.push(ke);te._ptr[we]=te._values.length}else we<We&&(te._ptr.splice(we+1,We-we),te._values.splice(te._ptr[we],te._values.length),te._index.splice(te._ptr[we],te._index.length));if(We=we,be>Be){if(pe){var pt=0;for(ze=0;ze<We;ze++){te._ptr[ze]=te._ptr[ze]+pt,et=te._ptr[ze+1]+pt;var $t=0;for(ke=Be;ke<be;ke++,$t++)te._values.splice(et+$t,0,de),te._index.splice(et+$t,0,ke),pt++}te._ptr[We]=te._values.length}}else if(be<Be){var Zt=0;for(ze=0;ze<We;ze++){te._ptr[ze]=te._ptr[ze]-Zt;var lt=te._ptr[ze+1]-Zt;for(et=te._ptr[ze];et<lt;et++)(ke=te._index[et])>be-1&&(te._values.splice(et,1),te._index.splice(et,1),Zt++)}te._ptr[ze]=te._values.length}return te._size[0]=be,te._size[1]=we,te}function J(te,be,we,Le,de){var Be,We,Te=Le[0],De=Le[1],pe=[];for(Be=0;Be<Te;Be++)for(pe[Be]=[],We=0;We<De;We++)pe[Be][We]=0;for(We=0;We<De;We++)for(var ze=we[We+1],et=we[We];et<ze;et++)pe[Be=be[et]][We]=te?de?At(te[et]):te[et]:1;return pe}return(y.prototype=new _).createSparseMatrix=function(te,be){return new y(te,be)},Object.defineProperty(y,"name",{value:"SparseMatrix"}),y.prototype.constructor=y,y.prototype.type="SparseMatrix",y.prototype.isSparseMatrix=!0,y.prototype.getDataType=function(){return Qf(this._values,pi)},y.prototype.storage=function(){return"sparse"},y.prototype.datatype=function(){return this._datatype},y.prototype.create=function(te,be){return new y(te,be)},y.prototype.density=function(){var te=this._size[0],be=this._size[1];return 0!==te&&0!==be?this._index.length/(te*be):0},y.prototype.subset=function(te,be,we){if(!this._values)throw new Error("Cannot invoke subset on a Pattern only matrix");switch(arguments.length){case 1:return function k(te,be){if(!pn(be))throw new TypeError("Invalid index");if(be.isScalar())return te.get(be.min());var Le=be.size();if(Le.length!==te._size.length)throw new va(Le.length,te._size.length);var de,Te,De,pe,Be=be.min(),We=be.max();for(de=0,Te=te._size.length;de<Te;de++)zl(Be[de],te._size[de]),zl(We[de],te._size[de]);var ke=te._values,ze=te._index,et=te._ptr,pt=be.dimension(0),$t=be.dimension(1),Zt=[],Kt=[];pt.forEach(function(_t,di){Kt[_t]=di[0],Zt[_t]=!0});var lt=ke?[]:void 0,st=[],En=[];return $t.forEach(function(_t){for(En.push(st.length),De=et[_t],pe=et[_t+1];De<pe;De++)!0===Zt[de=ze[De]]&&(st.push(Kt[de]),lt&<.push(ke[De]))}),En.push(st.length),new y({values:lt,index:st,ptr:En,size:Le,datatype:te._datatype})}(this,te);case 2:case 3:return function R(te,be,we,Le){if(!be||!0!==be.isIndex)throw new TypeError("Invalid index");var De,de=be.size(),Te=be.isScalar();if(ut(we)?(De=we.size(),we=we.toArray()):De=Bs(we),Te){if(0!==De.length)throw new TypeError("Scalar expected");te.set(be.min(),we,Le)}else{if(1!==de.length&&2!==de.length)throw new va(de.length,te._size.length,"<");if(De.length<de.length){for(var pe=0,Be=0;1===de[pe]&&1===De[pe];)pe++;for(;1===de[pe];)Be++,pe++;we=W_(we,de.length,Be,De)}if(!qn(de,De))throw new va(de,De,">");if(1===de.length)be.dimension(0).forEach(function(et,pt){zl(et),te.set([et,0],we[pt[0]],Le)});else{var ke=be.dimension(0),ze=be.dimension(1);ke.forEach(function(et,pt){zl(et),ze.forEach(function($t,Zt){zl($t),te.set([et,$t],we[pt[0]][Zt[0]],Le)})})}}return te}(this,te,be,we);default:throw new SyntaxError("Wrong number of arguments")}},y.prototype.get=function(te){if(!dt(te))throw new TypeError("Array expected");if(te.length!==this._size.length)throw new va(te.length,this._size.length);if(!this._values)throw new Error("Cannot invoke get on a Pattern only matrix");var be=te[0],we=te[1];zl(be,this._size[0]),zl(we,this._size[1]);var Le=O(be,this._ptr[we],this._ptr[we+1],this._index);return Le<this._ptr[we+1]&&this._index[Le]===be?this._values[Le]:0},y.prototype.set=function(te,be,we){if(!dt(te))throw new TypeError("Array expected");if(te.length!==this._size.length)throw new va(te.length,this._size.length);if(!this._values)throw new Error("Cannot invoke set on a Pattern only matrix");var Le=te[0],de=te[1],Te=this._size[0],De=this._size[1],pe=b,Be=0;Ae(this._datatype)&&(pe=m.find(b,[this._datatype,this._datatype])||b,Be=m.convert(0,this._datatype)),(Le>Te-1||de>De-1)&&(H(this,Math.max(Le+1,Te),Math.max(de+1,De),we),Te=this._size[0],De=this._size[1]),zl(Le,Te),zl(de,De);var We=O(Le,this._ptr[de],this._ptr[de+1],this._index);return We<this._ptr[de+1]&&this._index[We]===Le?pe(be,Be)?function F(te,be,we,Le,de){we.splice(te,1),Le.splice(te,1);for(var Te=be+1;Te<de.length;Te++)de[Te]--}(We,de,this._values,this._index,this._ptr):this._values[We]=be:pe(be,Be)||B(We,Le,de,be,this._values,this._index,this._ptr),this},y.prototype.resize=function(te,be,we){if(!Mt(te))throw new TypeError("Array or Matrix expected");var Le=te.valueOf().map(Te=>Array.isArray(Te)&&1===Te.length?Te[0]:Te);if(2!==Le.length)throw new Error("Only two dimensions matrix are supported");return Le.forEach(function(Te){if(!ct(Te)||!ai(Te)||Te<0)throw new TypeError("Invalid size, must contain positive integers (size: "+xs(Le)+")")}),H(we?this.clone():this,Le[0],Le[1],be)},y.prototype.reshape=function(te,be){if(!dt(te))throw new TypeError("Array expected");if(2!==te.length)throw new Error("Sparse matrices can only be reshaped in two dimensions");te.forEach(function(_t){if(!ct(_t)||!ai(_t)||_t<=-2||0===_t)throw new TypeError("Invalid size, must contain positive integers or -1 (size: "+xs(te)+")")});var we=this._size[0]*this._size[1];if(we!==(te=ap(te,we))[0]*te[1])throw new Error("Reshaping sparse matrix will result in the wrong number of elements");var de=be?this.clone():this;if(this._size[0]===te[0]&&this._size[1]===te[1])return de;for(var Te=[],De=0;De<de._ptr.length;De++)for(var pe=0;pe<de._ptr[De+1]-de._ptr[De];pe++)Te.push(De);for(var Be=de._values.slice(),We=de._index.slice(),ke=0;ke<de._index.length;ke++){var pt=We[ke]*de._size[1]+Te[ke];Te[ke]=pt%te[1],We[ke]=Math.floor(pt/te[1])}de._values.length=0,de._index.length=0,de._ptr.length=te[1]+1,de._size=te.slice();for(var $t=0;$t<de._ptr.length;$t++)de._ptr[$t]=0;for(var Zt=0;Zt<Be.length;Zt++){var Kt=We[Zt],lt=Te[Zt],st=Be[Zt];B(O(Kt,de._ptr[lt],de._ptr[lt+1],de._index),Kt,lt,st,de._values,de._index,de._ptr)}return de},y.prototype.clone=function(){return new y({values:this._values?At(this._values):void 0,index:At(this._index),ptr:At(this._ptr),size:At(this._size),datatype:this._datatype})},y.prototype.size=function(){return this._size.slice(0)},y.prototype.map=function(te,be){if(!this._values)throw new Error("Cannot invoke map on a Pattern only matrix");var we=this,Le=this._size[0],de=this._size[1],Te=yd(te,we,"map");return function G(te,be,we,Le,de,Te,De){var pe=[],Be=[],We=[],ke=b,ze=0;Ae(te._datatype)&&(ke=m.find(b,[te._datatype,te._datatype])||b,ze=m.convert(0,te._datatype));for(var et=function(_n,Ni,kr){var Pi=Te(_n,Ni,kr);ke(Pi,ze)||(pe.push(Pi),Be.push(Ni))},pt=Le;pt<=de;pt++){We.push(pe.length);var $t=te._ptr[pt],Zt=te._ptr[pt+1];if(De)for(var Kt=$t;Kt<Zt;Kt++){var lt=te._index[Kt];lt>=be&<<=we&&et(te._values[Kt],lt-be,pt-Le)}else{for(var st={},En=$t;En<Zt;En++)st[te._index[En]]=te._values[En];for(var di=be;di<=we;di++)et(di in st?st[di]:0,di-be,pt-Le)}}return We.push(pe.length),new y({values:pe,index:Be,ptr:We,size:[we-be+1,de-Le+1]})}(this,0,Le-1,0,de-1,function(Be,We,ke){return Te(Be,[We,ke],we)},be)},y.prototype.forEach=function(te,be){if(!this._values)throw new Error("Cannot invoke forEach on a Pattern only matrix");for(var Le=this._size[0],de=this._size[1],Te=yd(te,this,"forEach"),De=0;De<de;De++){var pe=this._ptr[De],Be=this._ptr[De+1];if(be)for(var We=pe;We<Be;We++)Te(this._values[We],[this._index[We],De],this);else{for(var ze={},et=pe;et<Be;et++)ze[this._index[et]]=this._values[et];for(var $t=0;$t<Le;$t++)Te($t in ze?ze[$t]:0,[$t,De],this)}}},y.prototype[Symbol.iterator]=function*(){if(!this._values)throw new Error("Cannot iterate a Pattern only matrix");for(var te=this._size[1],be=0;be<te;be++)for(var Le=this._ptr[be+1],de=this._ptr[be];de<Le;de++){var Te=this._index[de];yield{value:this._values[de],index:[Te,be]}}},y.prototype.toArray=function(){return J(this._values,this._index,this._ptr,this._size,!0)},y.prototype.valueOf=function(){return J(this._values,this._index,this._ptr,this._size,!1)},y.prototype.format=function(te){for(var be=this._size[0],we=this._size[1],Le=this.density(),de="Sparse Matrix ["+xs(be,te)+" x "+xs(we,te)+"] density: "+xs(Le,te)+"\n",Te=0;Te<we;Te++)for(var pe=this._ptr[Te+1],Be=this._ptr[Te];Be<pe;Be++)de+="\n ("+xs(this._index[Be],te)+", "+xs(Te,te)+") ==> "+(this._values?xs(this._values[Be],te):"X");return de},y.prototype.toString=function(){return xs(this.toArray())},y.prototype.toJSON=function(){return{mathjs:"SparseMatrix",values:this._values,index:this._index,ptr:this._ptr,size:this._size,datatype:this._datatype}},y.prototype.diagonal=function(te){if(te){if(en(te)&&(te=te.toNumber()),!ct(te)||!ai(te))throw new TypeError("The parameter k must be an integer number")}else te=0;var be=te>0?te:0,we=te<0?-te:0,de=this._size[1],Te=Math.min(this._size[0]-we,de-be),De=[],pe=[],Be=[];Be[0]=0;for(var We=be;We<de&&De.length<Te;We++)for(var ze=this._ptr[We+1],et=this._ptr[We];et<ze;et++){var pt=this._index[et];if(pt===We-be+we){De.push(this._values[et]),pe[De.length-1]=pt-we;break}}return Be.push(De.length),new y({values:De,index:pe,ptr:Be,size:[Te,1]})},y.fromJSON=function(te){return new y(te)},y.diagonal=function(te,be,we,Le,de){if(!dt(te))throw new TypeError("Array expected, size parameter");if(2!==te.length)throw new Error("Only two dimensions matrix are supported");if(te=te.map(function(_t){if(en(_t)&&(_t=_t.toNumber()),!ct(_t)||!ai(_t)||_t<1)throw new Error("Size values must be positive integers");return _t}),we){if(en(we)&&(we=we.toNumber()),!ct(we)||!ai(we))throw new TypeError("The parameter k must be an integer number")}else we=0;var Te=b,De=0;Ae(de)&&(Te=m.find(b,[de,de])||b,De=m.convert(0,de));var et,pe=we>0?we:0,Be=we<0?-we:0,We=te[0],ke=te[1],ze=Math.min(We-Be,ke-pe);if(dt(be)){if(be.length!==ze)throw new Error("Invalid value array length");et=function(di){return be[di]}}else if(ut(be)){var pt=be.size();if(1!==pt.length||pt[0]!==ze)throw new Error("Invalid matrix length");et=function(di){return be.get([di])}}else et=function(){return be};for(var $t=[],Zt=[],Kt=[],lt=0;lt<ke;lt++){Kt.push($t.length);var st=lt-pe;if(st>=0&&st<ze){var En=et(st);Te(En,De)||(Zt.push(st+Be),$t.push(En))}}return Kt.push($t.length),new y({values:$t,index:Zt,ptr:Kt,size:[We,ke]})},y.prototype.swapRows=function(te,be){if(!(ct(te)&&ai(te)&&ct(be)&&ai(be)))throw new Error("Row index must be positive integers");if(2!==this._size.length)throw new Error("Only two dimensional matrix is supported");return zl(te,this._size[0]),zl(be,this._size[0]),y._swapRows(te,be,this._size[1],this._values,this._index,this._ptr),this},y._forEachRow=function(te,be,we,Le,de){for(var De=Le[te+1],pe=Le[te];pe<De;pe++)de(we[pe],be[pe])},y._swapRows=function(te,be,we,Le,de,Te){for(var De=0;De<we;De++){var pe=Te[De],Be=Te[De+1],We=O(te,pe,Be,de),ke=O(be,pe,Be,de);if(We<Be&&ke<Be&&de[We]===te&&de[ke]===be){if(Le){var ze=Le[We];Le[We]=Le[ke],Le[ke]=ze}}else if(We<Be&&de[We]===te&&(ke>=Be||de[ke]!==be)){var et=Le?Le[We]:void 0;de.splice(ke,0,be),Le&&Le.splice(ke,0,et),de.splice(ke<=We?We+1:We,1),Le&&Le.splice(ke<=We?We+1:We,1)}else if(ke<Be&&de[ke]===be&&(We>=Be||de[We]!==te)){var pt=Le?Le[ke]:void 0;de.splice(We,0,te),Le&&Le.splice(We,0,pt),de.splice(We<=ke?ke+1:ke,1),Le&&Le.splice(We<=ke?ke+1:ke,1)}}},y},{isClass:!0}),ED="splitUnit",kg=re(ED,["typed"],p=>{var{typed:m}=p;return m(ED,{"Unit, Array":function(_,y){return _.splitUnit(y)}})}),TD=re("square",["typed"],p=>{var{typed:m}=p;return m("square",{number:Pm,Complex:function(_){return _.mul(_)},BigNumber:function(_){return _.times(_)},bigint:function(_){return _*_},Fraction:function(_){return _.mul(_)},Unit:function(_){return _.pow(2)}})}),G0=re("string",["typed"],p=>{var{typed:m}=p;return m("string",{"":function(){return""},number:na,null:function(_){return"null"},boolean:function(_){return _+""},string:function(_){return _},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b)),any:function(_){return String(_)}})}),K0="subtractScalar",Cd=re(K0,["typed"],p=>{var{typed:m}=p;return m(K0,{"number, number":Qe,"Complex, Complex":function(_,y){return _.sub(y)},"BigNumber, BigNumber":function(_,y){return _.minus(y)},"bigint, bigint":function(_,y){return _-y},"Fraction, Fraction":function(_,y){return _.sub(y)},"Unit, Unit":m.referToSelf(b=>(_,y)=>{if(null==_.value)throw new Error("Parameter x contains a unit with undefined value");if(null==y.value)throw new Error("Parameter y contains a unit with undefined value");if(!_.equalBase(y))throw new Error("Units do not match");var C=_.clone();return C.value=m.find(b,[C.valueType(),y.valueType()])(C.value,y.value),C.fixPrefix=!1,C})})}),zv=re("tan",["typed"],p=>{var{typed:m}=p,b=q_({typed:m});return m("tan",{number:Math.tan,"Complex | BigNumber":_=>_.tan()},b)}),rf=re("typeOf",["typed"],p=>{var{typed:m}=p;return m("typeOf",{any:pi})}),D1=re("acosh",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("acosh",{number:function(C){return C>=1||b.predictable?tm(C):C<=-1?new _(Math.log(Math.sqrt(C*C-1)-C),Math.PI):new _(C,0).acosh()},Complex:function(C){return C.acosh()},BigNumber:function(C){return C.acosh()}})}),w1=re("acsch",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("acsch",{number:se,Complex:function(y){return y.acsch()},BigNumber:function(y){return new b(1).div(y).asinh()}})}),Kv=re("apply",["typed","isInteger"],p=>{var{typed:m,isInteger:b}=p;return m("apply",{"Array | Matrix, number | BigNumber, function":function(y,C,A){if(!b(C))throw new TypeError("Integer number expected for dimension");var k=Array.isArray(y)?Bs(y):y.size();if(C<0||C>=k.length)throw new bc(C,k.length);return ut(y)?y.create(OD(y.valueOf(),C,A),y.datatype()):OD(y,C,A)}})});function OD(p,m,b){var _,y,C;if(m<=0){if(Array.isArray(p[0])){for(C=function FE(p){var _,y,m=p.length,b=p[0].length,C=[];for(y=0;y<b;y++){var A=[];for(_=0;_<m;_++)A.push(p[_][y]);C.push(A)}return C}(p),y=[],_=0;_<C.length;_++)y[_]=OD(C[_],m-1,b);return y}return b(p)}for(y=[],_=0;_<p.length;_++)y[_]=OD(p[_],m-1,b);return y}var sy=re("asec",["typed","config","Complex","BigNumber"],p=>{var{typed:m,config:b,Complex:_,BigNumber:y}=p;return m("asec",{number:function(A){return A<=-1||A>=1||b.predictable?me(A):new _(A,0).asec()},Complex:function(A){return A.asec()},BigNumber:function(A){return new y(1).div(A).acos()}})}),qv=re("bignumber",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("bignumber",{"":function(){return new b(0)},number:function(y){return new b(y+"")},string:function(y){var C=y.match(/(0[box][0-9a-fA-F]*)i([0-9]*)/);if(C){var A=C[2],k=b(C[1]),R=new b(2).pow(Number(A));if(k.gt(R.sub(1)))throw new SyntaxError('String "'.concat(y,'" is out of range'));var O=new b(2).pow(Number(A)-1);return k.gte(O)?k.sub(R):k}return new b(y)},BigNumber:function(y){return y},bigint:function(y){return new b(y.toString())},Unit:m.referToSelf(_=>y=>{var C=y.clone();return C.value=_(y.value),C}),Fraction:function(y){return new b(y.n).div(y.d).times(y.s)},null:function(y){return new b(0)},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),Pg="combinationsWithRep",Q0=re(Pg,["typed"],p=>{var{typed:m}=p;return m(Pg,{"number, number":function(_,y){if(!ai(_)||_<0)throw new TypeError("Positive integer value expected in function combinationsWithRep");if(!ai(y)||y<0)throw new TypeError("Positive integer value expected in function combinationsWithRep");if(_<1)throw new TypeError("k must be less than or equal to n + k - 1");return y<_-1?_f(_,_+y-1)/_f(1,y):_f(y+1,_+y-1)/_f(1,_-1)},"BigNumber, BigNumber":function(_,y){var A,k,R=new(0,_.constructor)(1),O=_.minus(R);if(!S1(_)||!S1(y))throw new TypeError("Positive integer value expected in function combinationsWithRep");if(_.lt(R))throw new TypeError("k must be less than or equal to n + k - 1 in function combinationsWithRep");if(A=R,y.lt(O))for(k=R;k.lte(O);k=k.plus(R))A=A.times(y.plus(k)).dividedBy(k);else for(k=R;k.lte(y);k=k.plus(R))A=A.times(O.plus(k)).dividedBy(k);return A}})});function S1(p){return p.isInteger()&&p.gte(0)}var FD=re("cosh",["typed"],p=>{var{typed:m}=p;return m("cosh",{number:ba,"Complex | BigNumber":b=>b.cosh()})}),T1=re("csch",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("csch",{number:pc,Complex:_=>_.csch(),BigNumber:_=>new b(1).div(_.sinh())})}),M1=re("isNaN",["typed"],p=>{var{typed:m}=p;return m("isNaN",{number:ic,BigNumber:function(_){return _.isNaN()},bigint:function(_){return!1},Fraction:function(_){return!1},Complex:function(_){return _.isNaN()},Unit:function(_){return Number.isNaN(_.value)},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),MM="isPrime",ND=re(MM,["typed"],p=>{var{typed:m}=p;return m(MM,{number:function(_){if(_<=3)return _>1;if(_%2==0||_%3==0)return!1;for(var y=5;y*y<=_;y+=6)if(_%y==0||_%(y+2)==0)return!1;return!0},bigint:function(_){if(_<=3n)return _>1n;if(_%2n===0n||_%3n===0n)return!1;for(var y=5n;y*y<=_;y+=6n)if(_%y===0n||_%(y+2n)===0n)return!1;return!0},BigNumber:function(_){if(_.lte(3))return _.gt(1);if(_.mod(2).eq(0)||_.mod(3).eq(0))return!1;if(_.lt(Math.pow(2,32))){for(var y=_.toNumber(),C=5;C*C<=y;C+=6)if(y%C==0||y%(C+2)==0)return!1;return!0}function A(Le,de,Te){for(var De=1;!de.eq(0);)de.mod(2).eq(0)?(de=de.div(2),Le=Le.mul(Le).mod(Te)):(de=de.sub(1),De=Le.mul(De).mod(Te));return De}for(var k=_.constructor.clone({precision:2*_.toFixed(0).length}),R=0,O=(_=new k(_)).sub(1);O.mod(2).eq(0);)O=O.div(2),R+=1;var F=null;if(_.lt("3317044064679887385961981"))F=[2,3,5,7,11,13,17,19,23,29,31,37,41].filter(Le=>Le<_);else{var B=Math.min(_.toNumber()-2,Math.floor(2*Math.pow(_.toFixed(0).length*Math.log(10),2)));F=[];for(var H=2;H<=B;H+=1)F.push(B)}for(var G=0;G<F.length;G+=1){var J=F[G],te=A(_.sub(_).add(J),O,_);if(!te.eq(1))for(var be=0,we=te;!we.eq(_.sub(1));be+=1,we=we.mul(we).mod(_))if(be===R-1)return!1}return!0},"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),I1="randomInt",fp=re(I1,["typed","config","?on"],p=>{var{typed:m,config:b,on:_}=p,y=am(b.randomSeed);return _&&_("config",function(k,R){k.randomSeed!==R.randomSeed&&(y=am(k.randomSeed))}),m(I1,{"":()=>A(0,1),number:k=>A(0,k),"number, number":(k,R)=>A(k,R),"Array | Matrix":k=>C(k,0,1),"Array | Matrix, number":(k,R)=>C(k,0,R),"Array | Matrix, number, number":(k,R,O)=>C(k,R,O)});function C(k,R,O){var F=Ox(k.valueOf(),()=>A(R,O));return ut(k)?k.create(F,"number"):F}function A(k,R){return Math.floor(k+y()*(R-k))}}),Qv=re("sech",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("sech",{number:Yf,Complex:_=>_.sech(),BigNumber:_=>new b(1).div(_.cosh())})}),ay=re("sinh",["typed"],p=>{var{typed:m}=p;return m("sinh",{number:vu,"Complex | BigNumber":b=>b.sinh()})}),Z0=re("sparse",["typed","SparseMatrix"],p=>{var{typed:m,SparseMatrix:b}=p;return m("sparse",{"":function(){return new b([])},string:function(y){return new b([],y)},"Array | Matrix":function(y){return new b(y)},"Array | Matrix, string":function(y,C){return new b(y,C)}})}),zm=re("sqrt",["config","typed","Complex"],p=>{var{config:m,typed:b,Complex:_}=p;return b("sqrt",{number:y,Complex:function(A){return A.sqrt()},BigNumber:function(A){return!A.isNegative()||m.predictable?A.sqrt():y(A.toNumber())},Unit:function(A){return A.pow(.5)}});function y(C){return isNaN(C)?NaN:C>=0||m.predictable?Math.sqrt(C):new _(C,0).sqrt()}}),Xv="squeeze",Zv=re(Xv,["typed"],p=>{var{typed:m}=p;return m(Xv,{Array:function(_){return Mu(At(_))},Matrix:function(_){var y=Mu(_.toArray());return Array.isArray(y)?_.create(y,_.datatype()):y},any:function(_){return At(_)}})}),Vg=re("tanh",["typed"],p=>{var{typed:m}=p;return m("tanh",{number:Ks,"Complex | BigNumber":b=>b.tanh()})}),ly="unaryMinus",jg=re(ly,["typed"],p=>{var{typed:m}=p;return m(ly,{number:ee,"Complex | BigNumber | Fraction":b=>b.neg(),bigint:b=>-b,Unit:m.referToSelf(b=>_=>{var y=_.clone();return y.value=m.find(b,y.valueType())(_.value),y}),"Array | Matrix":m.referToSelf(b=>_=>ps(_,b,!0))})}),Ug=re("acoth",["typed","config","Complex","BigNumber"],p=>{var{typed:m,config:b,Complex:_,BigNumber:y}=p;return m("acoth",{number:function(A){return A>=1||A<=-1||b.predictable?P(A):new _(A,0).acoth()},Complex:function(A){return A.acoth()},BigNumber:function(A){return new y(1).div(A).atanh()}})}),$g=re("bin",["typed","format"],p=>{var{typed:m,format:b}=p;return m("bin",{"number | BigNumber":function(y){return b(y,{notation:"bin"})},"number | BigNumber, number | BigNumber":function(y,C){return b(y,{notation:"bin",wordSize:C})}})}),jd=re("coth",["typed","BigNumber"],p=>{var{typed:m,BigNumber:b}=p;return m("coth",{number:Yo,Complex:_=>_.coth(),BigNumber:_=>new b(1).div(_.tanh())})}),pp=re("fraction",["typed","Fraction"],p=>{var{typed:m,Fraction:b}=p;return m("fraction",{number:function(y){if(!isFinite(y)||isNaN(y))throw new Error(y+" cannot be represented as a fraction");return new b(y)},string:function(y){return new b(y)},"number, number":function(y,C){return new b(y,C)},null:function(y){return new b(0)},BigNumber:function(y){return new b(y.toString())},bigint:function(y){return new b(y.toString())},Fraction:function(y){return y},Unit:m.referToSelf(_=>y=>{var C=y.clone();return C.value=_(y.value),C}),Object:function(y){return new b(y)},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),J0="isNumeric",tp=re(J0,["typed"],p=>{var{typed:m}=p;return m(J0,{"number | BigNumber | bigint | Fraction | boolean":()=>!0,"Complex | Unit | string | null | undefined | Node":()=>!1,"Array | Matrix":m.referToSelf(b=>_=>ps(_,b))})}),Wg=re("matrix",["typed","Matrix","DenseMatrix","SparseMatrix"],p=>{var{typed:m,DenseMatrix:_,SparseMatrix:y}=p;return m("matrix",{"":function(){return C([])},string:function(k){return C([],k)},"string, string":function(k,R){return C([],k,R)},Array:function(k){return C(k)},Matrix:function(k){return C(k,k.storage())},"Array | Matrix, string":C,"Array | Matrix, string, string":C});function C(A,k,R){if("dense"===k||"default"===k||void 0===k)return new _(A,R);if("sparse"===k)return new y(A,R);throw new TypeError("Unknown matrix type "+JSON.stringify(k)+".")}}),_a="matrixFromFunction",cl=re(_a,["typed","matrix","isZero"],p=>{var{typed:m,matrix:b,isZero:_}=p;return m(_a,{"Array | Matrix, function, string, string":function(A,k,R,O){return y(A,k,R,O)},"Array | Matrix, function, string":function(A,k,R){return y(A,k,R)},"Matrix, function":function(A,k){return y(A,k,"dense")},"Array, function":function(A,k){return y(A,k,"dense").toArray()},"Array | Matrix, string, function":function(A,k,R){return y(A,R,k)},"Array | Matrix, string, string, function":function(A,k,R,O){return y(A,O,k,R)}});function y(C,A,k,R){var O;return(O=void 0!==R?b(k,R):b(k)).resize(C),O.forEach(function(F,B){var H=A(B);_(H)||O.set(B,H)}),O}}),np=re("mode",["typed","isNaN","isNumeric"],p=>{var{typed:m,isNaN:b,isNumeric:_}=p;return m("mode",{"Array | Matrix":y,"...":function(A){return y(A)}});function y(C){if(0===(C=ns(C.valueOf())).length)throw new Error("Cannot calculate mode of an empty array");for(var k={},R=[],O=0,F=0;F<C.length;F++){var B=C[F];if(_(B)&&b(B))throw new Error("Cannot calculate mode of an array containing NaN values");B in k||(k[B]=0),k[B]++,k[B]===O?R.push(B):k[B]>O&&(O=k[B],R=[B])}return R}});function dm(){throw new Error('No "bignumber" implementation available')}function PD(){throw new Error('No "fraction" implementation available')}function hp(){throw new Error('No "matrix" implementation available')}var N1=re("numeric",["number","?bignumber","?fraction"],p=>{var{number:m,bignumber:b,fraction:_}=p,y={string:!0,number:!0,BigNumber:!0,Fraction:!0},C={number:A=>m(A),BigNumber:b?A=>b(A):dm,bigint:A=>BigInt(A),Fraction:_?A=>_(A):PD};return function(k){var R=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"number";if(void 0!==(arguments.length>2?arguments[2]:void 0))throw new SyntaxError("numeric() takes one or two arguments");var F=pi(k);if(!(F in y))throw new TypeError("Cannot convert "+k+' of type "'+F+'"; valid input types are '+Object.keys(y).join(", "));if(!(R in C))throw new TypeError("Cannot convert "+k+' to type "'+R+'"; valid output types are '+Object.keys(C).join(", "));return R===F?k:C[R](k)}});function tu(p,m,b){var _;return String(p).includes("Unexpected type")?(_=arguments.length>2?" (type: "+pi(b)+", value: "+JSON.stringify(b)+")":" (type: "+p.data.actual+")",new TypeError("Cannot calculate "+m+", unexpected type of argument"+_)):String(p).includes("complex numbers")?(_=arguments.length>2?" (type: "+pi(b)+", value: "+JSON.stringify(b)+")":"",new TypeError("Cannot calculate "+m+", no ordering relation is defined for complex numbers"+_)):p}var $d=re("prod",["typed","config","multiplyScalar","numeric"],p=>{var{typed:m,config:b,multiplyScalar:_,numeric:y}=p;return m("prod",{"Array | Matrix":C,"Array | Matrix, number | BigNumber":function(k,R){throw new Error("prod(A, dim) is not yet supported")},"...":function(k){return C(k)}});function C(A){var k;if(Ss(A,function(R){try{k=void 0===k?R:_(k,R)}catch(O){throw tu(O,"prod",R)}}),"string"==typeof k&&(k=y(k,Fr(k,b))),void 0===k)throw new Error("Cannot calculate prod of an empty array");return k}}),Wd="reshape",Zu=re(Wd,["typed","isInteger","matrix"],p=>{var{typed:m,isInteger:b}=p;return m(Wd,{"Matrix, Array":function(y,C){return y.reshape(C,!0)},"Array, Array":function(y,C){return C.forEach(function(A){if(!b(A))throw new TypeError("Invalid size for dimension: "+A)}),Fm(y,C)}})}),bf=re("size",["typed","config","?matrix"],p=>{var{typed:m,config:b,matrix:_}=p;return m("size",{Matrix:function(C){return C.create(C.size(),"number")},Array:Bs,string:function(C){return"Array"===b.matrix?[C.length]:_([C.length],"dense","number")},"number | Complex | BigNumber | Unit | boolean | null":function(C){return"Array"===b.matrix?[]:_?_([],"dense","number"):hp()}})}),eb="transpose",Hg=re(eb,["typed","matrix"],p=>{var{typed:m,matrix:b}=p;return m(eb,{Array:A=>_(b(A)).valueOf(),Matrix:_,any:At});function _(A){var R,k=A.size();switch(k.length){case 1:R=A.clone();break;case 2:var O=k[0],F=k[1];if(0===F)throw new RangeError("Cannot transpose a 2D matrix with no columns (size: "+xs(k)+")");switch(A.storage()){case"dense":R=function y(A,k,R){for(var B,O=A._data,F=[],H=0;H<R;H++){B=F[H]=[];for(var G=0;G<k;G++)B[G]=At(O[G][H])}return A.createDenseMatrix({data:F,size:[R,k],datatype:A._datatype})}(A,O,F);break;case"sparse":R=function C(A,k,R){for(var O=A._values,F=A._index,B=A._ptr,H=O?[]:void 0,G=[],J=[],te=[],be=0;be<k;be++)te[be]=0;var we,Le,de;for(we=0,Le=F.length;we<Le;we++)te[F[we]]++;for(var Te=0,De=0;De<k;De++)J.push(Te),Te+=te[De],te[De]=J[De];for(J.push(Te),de=0;de<R;de++)for(var Be=B[de+1],We=B[de];We<Be;We++){var ke=te[F[We]]++;G[ke]=de,O&&(H[ke]=At(O[We]))}return A.createSparseMatrix({values:H,index:G,ptr:J,size:[R,k],datatype:A._datatype})}(A,O,F)}break;default:throw new RangeError("Matrix must be a vector or two dimensional (size: "+xs(k)+")")}return R}}),Kr=re("xgcd",["typed","config","matrix","BigNumber"],p=>{var{typed:m,config:b,matrix:_,BigNumber:y}=p;return m("xgcd",{"number, number":function(k,R){var O=nh(k,R);return"Array"===b.matrix?O:_(O)},"BigNumber, BigNumber":function C(A,k){var R,O,F,we,B=new y(0),H=new y(1),G=B,J=H,te=H,be=B;if(!A.isInt()||!k.isInt())throw new Error("Parameters in function xgcd must be integer numbers");for(;!k.isZero();)O=A.div(k).floor(),F=A.mod(k),R=G,G=J.minus(O.times(G)),J=R,R=te,te=be.minus(O.times(te)),be=R,A=k,k=F;return we=A.lt(B)?[A.neg(),J.neg(),be.neg()]:[A,A.isZero()?0:J,be],"Array"===b.matrix?we:_(we)}})}),jD=re("zeros",["typed","config","matrix","BigNumber"],p=>{var{typed:m,config:b,matrix:_,BigNumber:y}=p;return m("zeros",{"":function(){return"Array"===b.matrix?C([]):C([],"default")},"...number | BigNumber | string":function(O){if("string"==typeof O[O.length-1]){var B=O.pop();return C(O,B)}return"Array"===b.matrix?C(O):C(O,"default")},Array:C,Matrix:function(O){var F=O.storage();return C(O.valueOf(),F)},"Array | Matrix, string":function(O,F){return C(O.valueOf(),F)}});function C(R,O){var F=function A(R){var O=!1;return R.forEach(function(F,B,H){en(F)&&(O=!0,H[B]=F.toNumber())}),O}(R),B=F?new y(0):0;if(function k(R){R.forEach(function(O){if("number"!=typeof O||!ai(O)||O<0)throw new Error("Parameters in function zeros must be positive integers")})}(R),O){var H=_(O);return R.length>0?H.resize(R,B):H}var G=[];return R.length>0?Mp(G,R,B):G}}),R1=re("asin",["typed","config","Complex"],p=>{var{typed:m,config:b,Complex:_}=p;return m("asin",{number:function(C){return C>=-1&&C<=1||b.predictable?Math.asin(C):new _(C,0).asin()},Complex:function(C){return C.asin()},BigNumber:function(C){return C.asin()}})}),mp=re("cbrt",["config","typed","isNegative","unaryMinus","matrix","Complex","BigNumber","Fraction"],p=>{var{config:m,typed:b,isNegative:_,unaryMinus:y,matrix:C,Complex:A,BigNumber:k,Fraction:R}=p;return b("cbrt",{number:Nt,Complex:O,"Complex, boolean":O,BigNumber:function(H){return H.cbrt()},Unit:function F(B){if(B.value&&un(B.value)){var H=B.clone();return H.value=1,(H=H.pow(1/3)).value=O(B.value),H}var J,G=_(B.value);G&&(B.value=y(B.value)),J=en(B.value)?new k(1).div(3):vn(B.value)?new R(1,3):1/3;var te=B.pow(J);return G&&(te.value=y(te.value)),te}});function O(B,H){var G=B.arg()/3,J=B.abs(),te=new A(Nt(J),0).mul(new A(0,G).exp());if(H){var be=[te,new A(Nt(J),0).mul(new A(0,G+2*Math.PI/3).exp()),new A(Nt(J),0).mul(new A(0,G-2*Math.PI/3).exp())];return"Array"===m.matrix?be:C(be)}return te}}),Gm=re("concat",["typed","matrix","isInteger"],p=>{var{typed:m,matrix:b,isInteger:_}=p;return m("concat",{"...Array | Matrix | number | BigNumber":function(C){var A,O,k=C.length,R=-1,F=!1,B=[];for(A=0;A<k;A++){var H=C[A];if(ut(H)&&(F=!0),ct(H)||en(H)){if(A!==k-1)throw new Error("Dimension must be specified as last argument");if(O=R,R=H.valueOf(),!_(R))throw new TypeError("Integer number expected for dimension");if(R<0||A>0&&R>O)throw new bc(R,O+1)}else{var G=At(H).valueOf(),J=Bs(G);if(B[A]=G,O=R,R=J.length-1,A>0&&R!==O)throw new va(O+1,R+1)}}if(0===B.length)throw new SyntaxError("At least one matrix expected");for(var te=B.shift();B.length;)te=Mv(te,B.shift(),R);return F?b(te):te},"...string":function(C){return C.join("")}})}),n_=re("count",["typed","size","prod"],p=>{var{typed:m,size:b,prod:_}=p;return m("count",{string:function(C){return C.length},"Matrix | Array":function(C){return _(b(C))}})}),jE="ctranspose",Pa=re(jE,["typed","transpose","conj"],p=>{var{typed:m,transpose:b,conj:_}=p;return m(jE,{any:function(C){return _(b(C))}})}),i_=re("diag",["typed","matrix","DenseMatrix","SparseMatrix"],p=>{var{typed:m,matrix:b,DenseMatrix:_,SparseMatrix:y}=p;return m("diag",{Array:function(O){return C(O,0,Bs(O),null)},"Array, number":function(O,F){return C(O,F,Bs(O),null)},"Array, BigNumber":function(O,F){return C(O,F.toNumber(),Bs(O),null)},"Array, string":function(O,F){return C(O,0,Bs(O),F)},"Array, number, string":function(O,F,B){return C(O,F,Bs(O),B)},"Array, BigNumber, string":function(O,F,B){return C(O,F.toNumber(),Bs(O),B)},Matrix:function(O){return C(O,0,O.size(),O.storage())},"Matrix, number":function(O,F){return C(O,F,O.size(),O.storage())},"Matrix, BigNumber":function(O,F){return C(O,F.toNumber(),O.size(),O.storage())},"Matrix, string":function(O,F){return C(O,0,O.size(),F)},"Matrix, number, string":function(O,F,B){return C(O,F,O.size(),B)},"Matrix, BigNumber, string":function(O,F,B){return C(O,F.toNumber(),O.size(),B)}});function C(R,O,F,B){if(!ai(O))throw new TypeError("Second parameter in function diag must be an integer");var H=O>0?O:0,G=O<0?-O:0;switch(F.length){case 1:return function A(R,O,F,B,H,G){var J=[B+H,B+G];if(F&&"sparse"!==F&&"dense"!==F)throw new TypeError("Unknown matrix type ".concat(F,'"'));var te="sparse"===F?y.diagonal(J,R,O):_.diagonal(J,R,O);return null!==F?te:te.valueOf()}(R,O,B,F[0],G,H);case 2:return function k(R,O,F,B,H,G){if(ut(R)){var J=R.diagonal(O);return null!==F?F!==J.storage()?b(J,F):J:J.valueOf()}for(var te=Math.min(B[0]-H,B[1]-G),be=[],we=0;we<te;we++)be[we]=R[we+H][we+G];return null!==F?b(be):be}(R,O,B,F,G,H)}throw new RangeError("Matrix for function diag must be 2 dimensional")}}),yu="divideScalar",k1=re(yu,["typed","numeric"],p=>{var{typed:m}=p;return m(yu,{"number, number":function(y,C){return y/C},"Complex, Complex":function(y,C){return y.div(C)},"BigNumber, BigNumber":function(y,C){return y.div(C)},"bigint, bigint":function(y,C){return y/C},"Fraction, Fraction":function(y,C){return y.div(C)},"Unit, number | Complex | Fraction | BigNumber | Unit":(_,y)=>_.divide(y),"number | Fraction | Complex | BigNumber, Unit":(_,y)=>y.divideInto(_)})}),gp=re("matAlgo02xDS0",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A,k){var R=y._data,O=y._size,F=y._datatype||y.getDataType(),B=C._values,H=C._index,G=C._ptr,J=C._size,te=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(O.length!==J.length)throw new va(O.length,J.length);if(O[0]!==J[0]||O[1]!==J[1])throw new RangeError("Dimension mismatch. Matrix A ("+O+") must match Matrix B ("+J+")");if(!B)throw new Error("Cannot perform operation on Dense Matrix and Pattern Sparse Matrix");var Le,be=O[0],we=O[1],de=b,Te=0,De=A;"string"==typeof F&&F===te&&"mixed"!==F&&(de=m.find(b,[Le=F,Le]),Te=m.convert(0,Le),De=m.find(A,[Le,Le]));for(var pe=[],Be=[],We=[],ke=0;ke<we;ke++){We[ke]=Be.length;for(var et=G[ke+1],pt=G[ke];pt<et;pt++){var $t=H[pt],Zt=k?De(B[pt],R[$t][ke]):De(R[$t][ke],B[pt]);de(Zt,Te)||(Be.push($t),pe.push(Zt))}}return We[we]=Be.length,C.createSparseMatrix({values:pe,index:Be,ptr:We,size:[be,we],datatype:F===y._datatype&&te===C._datatype?Le:void 0})}}),Hd=re("matAlgo03xDSf",["typed"],p=>{var{typed:m}=p;return function(_,y,C,A){var k=_._data,R=_._size,O=_._datatype||_.getDataType(),F=y._values,B=y._index,H=y._ptr,G=y._size,J=y._datatype||void 0===y._data?y._datatype:y.getDataType();if(R.length!==G.length)throw new va(R.length,G.length);if(R[0]!==G[0]||R[1]!==G[1])throw new RangeError("Dimension mismatch. Matrix A ("+R+") must match Matrix B ("+G+")");if(!F)throw new Error("Cannot perform operation on Dense Matrix and Pattern Sparse Matrix");var we,te=R[0],be=R[1],Le=0,de=C;"string"==typeof O&&O===J&&"mixed"!==O&&(Le=m.convert(0,we=O),de=m.find(C,[we,we]));for(var Te=[],De=0;De<te;De++)Te[De]=[];for(var pe=[],Be=[],We=0;We<be;We++){for(var ke=We+1,et=H[We+1],pt=H[We];pt<et;pt++){var $t=B[pt];pe[$t]=A?de(F[pt],k[$t][We]):de(k[$t][We],F[pt]),Be[$t]=ke}for(var Zt=0;Zt<te;Zt++)Te[Zt][We]=Be[Zt]===ke?pe[Zt]:A?de(Le,k[Zt][We]):de(k[Zt][We],Le)}return _.createDenseMatrix({data:Te,size:[te,be],datatype:O===_._datatype&&J===y._datatype?we:void 0})}}),Gg=re("matAlgo07xSSf",["typed","DenseMatrix"],p=>{var{typed:m,DenseMatrix:b}=p;return function(C,A,k){var R=C._size,O=C._datatype||void 0===C._data?C._datatype:C.getDataType(),F=A._size,B=A._datatype||void 0===A._data?A._datatype:A.getDataType();if(R.length!==F.length)throw new va(R.length,F.length);if(R[0]!==F[0]||R[1]!==F[1])throw new RangeError("Dimension mismatch. Matrix A ("+R+") must match Matrix B ("+F+")");var J,H=R[0],G=R[1],te=0,be=k;"string"==typeof O&&O===B&&"mixed"!==O&&(te=m.convert(0,J=O),be=m.find(k,[J,J]));var we,Le,de=[];for(we=0;we<H;we++)de[we]=[];var Te=[],De=[],pe=[],Be=[];for(Le=0;Le<G;Le++){var We=Le+1;for(_(C,Le,pe,Te,We),_(A,Le,Be,De,We),we=0;we<H;we++)de[we][Le]=be(pe[we]===We?Te[we]:te,Be[we]===We?De[we]:te)}return new b({data:de,size:[H,G],datatype:O===C._datatype&&B===A._datatype?J:void 0})};function _(y,C,A,k,R){for(var O=y._values,F=y._index,B=y._ptr,H=B[C],G=B[C+1];H<G;H++){var J=F[H];A[J]=R,k[J]=O[H]}}}),Bf=re("matAlgo11xS0s",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A,k){var R=y._values,O=y._index,F=y._ptr,B=y._size,H=y._datatype;if(!R)throw new Error("Cannot perform operation on Pattern Sparse Matrix and Scalar value");var te,G=B[0],J=B[1],be=b,we=0,Le=A;"string"==typeof H&&(be=m.find(b,[te=H,te]),we=m.convert(0,te),C=m.convert(C,te),Le=m.find(A,[te,te]));for(var de=[],Te=[],De=[],pe=0;pe<J;pe++){De[pe]=Te.length;for(var We=F[pe+1],ke=F[pe];ke<We;ke++){var ze=O[ke],et=k?Le(C,R[ke]):Le(R[ke],C);be(et,we)||(Te.push(ze),de.push(et))}}return De[J]=Te.length,y.createSparseMatrix({values:de,index:Te,ptr:De,size:[G,J],datatype:te})}}),Od=re("matAlgo12xSfs",["typed","DenseMatrix"],p=>{var{typed:m,DenseMatrix:b}=p;return function(y,C,A,k){var R=y._values,O=y._index,F=y._ptr,B=y._size,H=y._datatype;if(!R)throw new Error("Cannot perform operation on Pattern Sparse Matrix and Scalar value");var te,G=B[0],J=B[1],be=A;"string"==typeof H&&(C=m.convert(C,te=H),be=m.find(A,[te,te]));for(var we=[],Le=[],de=[],Te=0;Te<J;Te++){for(var De=Te+1,Be=F[Te+1],We=F[Te];We<Be;We++){var ke=O[We];Le[ke]=R[We],de[ke]=De}for(var ze=0;ze<G;ze++)0===Te&&(we[ze]=[]),we[ze][Te]=de[ze]===De?k?be(C,Le[ze]):be(Le[ze],C):k?be(C,0):be(0,C)}return new b({data:we,size:[G,J],datatype:te})}}),FM=re("matAlgo13xDD",["typed"],p=>{var{typed:m}=p;return function(y,C,A){var k=y._data,R=y._size,O=y._datatype,F=C._data,B=C._size,H=C._datatype,G=[];if(R.length!==B.length)throw new va(R.length,B.length);for(var J=0;J<R.length;J++){if(R[J]!==B[J])throw new RangeError("Dimension mismatch. Matrix A ("+R+") must match Matrix B ("+B+")");G[J]=R[J]}var te,be=A;"string"==typeof O&&O===H&&(be=m.find(A,[te=O,te]));var we=G.length>0?b(be,0,G,G[0],k,F):[];return y.createDenseMatrix({data:we,size:G,datatype:te})};function b(_,y,C,A,k,R){var O=[];if(y===C.length-1)for(var F=0;F<A;F++)O[F]=_(k[F],R[F]);else for(var B=0;B<A;B++)O[B]=b(_,y+1,C,C[y+1],k[B],R[B]);return O}}),Bp=re("matAlgo14xDs",["typed"],p=>{var{typed:m}=p;return function(y,C,A,k){var B,R=y._data,O=y._size,F=y._datatype,H=A;"string"==typeof F&&(C=m.convert(C,B=F),H=m.find(A,[B,B]));var G=O.length>0?b(H,0,O,O[0],R,C,k):[];return y.createDenseMatrix({data:G,size:At(O),datatype:B})};function b(_,y,C,A,k,R,O){var F=[];if(y===C.length-1)for(var B=0;B<A;B++)F[B]=O?_(R,k[B]):_(k[B],R);else for(var H=0;H<A;H++)F[H]=b(_,y+1,C,C[y+1],k[H],R,O);return F}});function Fd(p,m){if(qn(p.size(),m.size()))return[p,m];var b=Xh(p.size(),m.size());return[p,m].map(_=>function Qx(p,m){return qn(p.size(),m)?p:p.create(od(p.valueOf(),m),p.datatype())}(_,b))}var $c=re("matrixAlgorithmSuite",["typed","matrix"],p=>{var{typed:m,matrix:b}=p,_=FM({typed:m}),y=Bp({typed:m});return function(A){var O,k=A.elop,R=A.SD||A.DS;k?(O={"DenseMatrix, DenseMatrix":(G,J)=>_(...Fd(G,J),k),"Array, Array":(G,J)=>_(...Fd(b(G),b(J)),k).valueOf(),"Array, DenseMatrix":(G,J)=>_(...Fd(b(G),J),k),"DenseMatrix, Array":(G,J)=>_(...Fd(G,b(J)),k)},A.SS&&(O["SparseMatrix, SparseMatrix"]=(G,J)=>A.SS(...Fd(G,J),k,!1)),A.DS&&(O["DenseMatrix, SparseMatrix"]=(G,J)=>A.DS(...Fd(G,J),k,!1),O["Array, SparseMatrix"]=(G,J)=>A.DS(...Fd(b(G),J),k,!1)),R&&(O["SparseMatrix, DenseMatrix"]=(G,J)=>R(...Fd(J,G),k,!0),O["SparseMatrix, Array"]=(G,J)=>R(...Fd(b(J),G),k,!0))):(O={"DenseMatrix, DenseMatrix":m.referToSelf(G=>(J,te)=>_(...Fd(J,te),G)),"Array, Array":m.referToSelf(G=>(J,te)=>_(...Fd(b(J),b(te)),G).valueOf()),"Array, DenseMatrix":m.referToSelf(G=>(J,te)=>_(...Fd(b(J),te),G)),"DenseMatrix, Array":m.referToSelf(G=>(J,te)=>_(...Fd(J,b(te)),G))},A.SS&&(O["SparseMatrix, SparseMatrix"]=m.referToSelf(G=>(J,te)=>A.SS(...Fd(J,te),G,!1))),A.DS&&(O["DenseMatrix, SparseMatrix"]=m.referToSelf(G=>(J,te)=>A.DS(...Fd(J,te),G,!1)),O["Array, SparseMatrix"]=m.referToSelf(G=>(J,te)=>A.DS(...Fd(b(J),te),G,!1))),R&&(O["SparseMatrix, DenseMatrix"]=m.referToSelf(G=>(J,te)=>R(...Fd(te,J),G,!0)),O["SparseMatrix, Array"]=m.referToSelf(G=>(J,te)=>R(...Fd(b(te),J),G,!0))));var F=A.scalar||"any";(A.Ds||A.Ss)&&(k?(O["DenseMatrix,"+F]=(G,J)=>y(G,J,k,!1),O[F+", DenseMatrix"]=(G,J)=>y(J,G,k,!0),O["Array,"+F]=(G,J)=>y(b(G),J,k,!1).valueOf(),O[F+", Array"]=(G,J)=>y(b(J),G,k,!0).valueOf()):(O["DenseMatrix,"+F]=m.referToSelf(G=>(J,te)=>y(J,te,G,!1)),O[F+", DenseMatrix"]=m.referToSelf(G=>(J,te)=>y(te,J,G,!0)),O["Array,"+F]=m.referToSelf(G=>(J,te)=>y(b(J),te,G,!1).valueOf()),O[F+", Array"]=m.referToSelf(G=>(J,te)=>y(b(te),J,G,!0).valueOf())));var H=void 0!==A.sS?A.sS:A.Ss;return k?(A.Ss&&(O["SparseMatrix,"+F]=(G,J)=>A.Ss(G,J,k,!1)),H&&(O[F+", SparseMatrix"]=(G,J)=>H(J,G,k,!0))):(A.Ss&&(O["SparseMatrix,"+F]=m.referToSelf(G=>(J,te)=>A.Ss(J,te,G,!1))),H&&(O[F+", SparseMatrix"]=m.referToSelf(G=>(J,te)=>H(te,J,G,!0)))),k&&k.signatures&&Mn(O,k.signatures),O}}),Yx="dotDivide",Kg=re(Yx,["typed","matrix","equalScalar","divideScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,divideScalar:y,DenseMatrix:C,concat:A}=p,k=gp({typed:m,equalScalar:_}),R=Hd({typed:m}),O=Gg({typed:m,DenseMatrix:C}),F=Bf({typed:m,equalScalar:_}),B=Od({typed:m,DenseMatrix:C}),H=$c({typed:m,matrix:b,concat:A});return m(Yx,H({elop:y,SS:O,DS:R,SD:k,Ss:F,sS:B}))}),B1="equal",V1=re(B1,["typed","matrix","equalScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=Gg({typed:m,DenseMatrix:y}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:b,concat:C});return m(B1,RM({typed:m,equalScalar:_}),O({elop:_,SS:k,DS:A,Ss:R}))}),RM=re(B1,["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return m(B1,{"any, any":function(y,C){return null===y?null===C:null===C?null===y:void 0===y?void 0===C:void 0===C?void 0===y:b(y,C)}})}),j1="hasNumericValue",U1=re(j1,["typed","isNumeric"],p=>{var{typed:m,isNumeric:b}=p;return m(j1,{boolean:()=>!0,string:function(y){return y.trim().length>0&&!isNaN(Number(y))},any:function(y){return b(y)}})}),Vf="identity",$a=re(Vf,["typed","config","matrix","BigNumber","DenseMatrix","SparseMatrix"],p=>{var{typed:m,config:b,matrix:_,BigNumber:y,DenseMatrix:C,SparseMatrix:A}=p;return m(Vf,{"":function(){return"Matrix"===b.matrix?_([]):[]},string:function(F){return _(F)},"number | BigNumber":function(F){return R(F,F,"Matrix"===b.matrix?"dense":void 0)},"number | BigNumber, string":function(F,B){return R(F,F,B)},"number | BigNumber, number | BigNumber":function(F,B){return R(F,B,"Matrix"===b.matrix?"dense":void 0)},"number | BigNumber, number | BigNumber, string":function(F,B,H){return R(F,B,H)},Array:function(F){return k(F)},"Array, string":function(F,B){return k(F,B)},Matrix:function(F){return k(F.valueOf(),F.storage())},"Matrix, string":function(F,B){return k(F.valueOf(),B)}});function k(O,F){switch(O.length){case 0:return F?_(F):[];case 1:return R(O[0],O[0],F);case 2:return R(O[0],O[1],F);default:throw new Error("Vector containing two values expected")}}function R(O,F,B){var H=en(O)||en(F)?y:null;if(en(O)&&(O=O.toNumber()),en(F)&&(F=F.toNumber()),!ai(O)||O<1)throw new Error("Parameters in function identity must be positive integers");if(!ai(F)||F<1)throw new Error("Parameters in function identity must be positive integers");var G=H?new y(1):1,J=H?new H(0):0,te=[O,F];if(B){if("sparse"===B)return A.diagonal(te,G,0,J);if("dense"===B)return C.diagonal(te,G,0,J);throw new TypeError('Unknown matrix type "'.concat(B,'"'))}for(var be=Mp([],te,J),we=O<F?O:F,Le=0;Le<we;Le++)be[Le][Le]=G;return be}}),kh=re("kron",["typed","matrix","multiplyScalar"],p=>{var{typed:m,matrix:b,multiplyScalar:_}=p;return m("kron",{"Matrix, Matrix":function(A,k){return b(y(A.toArray(),k.toArray()))},"Matrix, Array":function(A,k){return b(y(A.toArray(),k))},"Array, Matrix":function(A,k){return b(y(A,k.toArray()))},"Array, Array":y});function y(C,A){if(1===Bs(C).length&&(C=[C]),1===Bs(A).length&&(A=[A]),Bs(C).length>2||Bs(A).length>2)throw new RangeError("Vectors with dimensions greater then 2 are not supported expected (Size x = "+JSON.stringify(C.length)+", y = "+JSON.stringify(A.length)+")");var k=[],R=[];return C.map(function(O){return A.map(function(F){return k.push(R=[]),O.map(function(B){return F.map(function(H){return R.push(_(B,H))})})})})&&k}}),Yg="largerEq",fy=re(Yg,["typed","config","matrix","DenseMatrix","concat"],p=>{var{typed:m,config:b,matrix:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=Gg({typed:m,DenseMatrix:y}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:_,concat:C}),F=Nv({typed:m});return m(Yg,_s({typed:m,config:b}),{"boolean, boolean":(B,H)=>B>=H,"BigNumber, BigNumber":function(H,G){return H.gte(G)||Zf(H,G,b.relTol,b.absTol)},"bigint, bigint":function(H,G){return H>=G},"Fraction, Fraction":(B,H)=>-1!==B.compare(H),"Complex, Complex":function(){throw new TypeError("No ordering relation is defined for complex numbers")}},F,O({SS:k,DS:A,Ss:R}))}),_s=re(Yg,["typed","config"],p=>{var{typed:m,config:b}=p;return m(Yg,{"number, number":function(y,C){return y>=C||Di(y,C,b.relTol,b.absTol)}})}),Df=re("matAlgo01xDSid",["typed"],p=>{var{typed:m}=p;return function(_,y,C,A){var k=_._data,R=_._size,O=_._datatype||_.getDataType(),F=y._values,B=y._index,H=y._ptr,G=y._size,J=y._datatype||void 0===y._data?y._datatype:y.getDataType();if(R.length!==G.length)throw new va(R.length,G.length);if(R[0]!==G[0]||R[1]!==G[1])throw new RangeError("Dimension mismatch. Matrix A ("+R+") must match Matrix B ("+G+")");if(!F)throw new Error("Cannot perform operation on Dense Matrix and Pattern Sparse Matrix");var de,Te,te=R[0],be=R[1],we="string"==typeof O&&"mixed"!==O&&O===J?O:void 0,Le=we?m.find(C,[we,we]):C,De=[];for(de=0;de<te;de++)De[de]=[];var pe=[],Be=[];for(Te=0;Te<be;Te++){for(var We=Te+1,ze=H[Te+1],et=H[Te];et<ze;et++)pe[de=B[et]]=A?Le(F[et],k[de][Te]):Le(k[de][Te],F[et]),Be[de]=We;for(de=0;de<te;de++)De[de][Te]=Be[de]===We?pe[de]:k[de][Te]}return _.createDenseMatrix({data:De,size:[te,be],datatype:O===_._datatype&&J===y._datatype?we:void 0})}}),o_=re("matAlgo10xSids",["typed","DenseMatrix"],p=>{var{typed:m,DenseMatrix:b}=p;return function(y,C,A,k){var R=y._values,O=y._index,F=y._ptr,B=y._size,H=y._datatype;if(!R)throw new Error("Cannot perform operation on Pattern Sparse Matrix and Scalar value");var te,G=B[0],J=B[1],be=A;"string"==typeof H&&(C=m.convert(C,te=H),be=m.find(A,[te,te]));for(var we=[],Le=[],de=[],Te=0;Te<J;Te++){for(var De=Te+1,Be=F[Te+1],We=F[Te];We<Be;We++){var ke=O[We];Le[ke]=R[We],de[ke]=De}for(var ze=0;ze<G;ze++)0===Te&&(we[ze]=[]),we[ze][Te]=de[ze]===De?k?be(C,Le[ze]):be(Le[ze],C):C}return new b({data:we,size:[G,J],datatype:te})}}),qE=re("matAlgo08xS0Sid",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A){var k=y._values,R=y._index,O=y._ptr,F=y._size,B=y._datatype||void 0===y._data?y._datatype:y.getDataType(),H=C._values,G=C._index,J=C._ptr,te=C._size,be=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(F.length!==te.length)throw new va(F.length,te.length);if(F[0]!==te[0]||F[1]!==te[1])throw new RangeError("Dimension mismatch. Matrix A ("+F+") must match Matrix B ("+te+")");if(!k||!H)throw new Error("Cannot perform operation on Pattern Sparse Matrices");var de,we=F[0],Le=F[1],Te=b,De=0,pe=A;"string"==typeof B&&B===be&&"mixed"!==B&&(Te=m.find(b,[de=B,de]),De=m.convert(0,de),pe=m.find(A,[de,de]));for(var pt,Zt,Kt,Be=[],We=[],ke=[],ze=[],et=[],lt=0;lt<Le;lt++){ke[lt]=We.length;var st=lt+1;for(Zt=O[lt+1],pt=O[lt];pt<Zt;pt++)et[Kt=R[pt]]=st,ze[Kt]=k[pt],We.push(Kt);for(Zt=J[lt+1],pt=J[lt];pt<Zt;pt++)et[Kt=G[pt]]===st&&(ze[Kt]=pe(ze[Kt],H[pt]));for(pt=ke[lt];pt<We.length;){var En=ze[Kt=We[pt]];Te(En,De)?We.splice(pt,1):(Be.push(En),pt++)}}return ke[Le]=We.length,y.createSparseMatrix({values:Be,index:We,ptr:ke,size:[we,Le],datatype:B===y._datatype&&be===C._datatype?de:void 0})}}),eS=re("useMatrixForArrayScalar",["typed","matrix"],p=>{var{typed:m,matrix:b}=p;return{"Array, number":m.referTo("DenseMatrix, number",_=>(y,C)=>_(b(y),C).valueOf()),"Array, BigNumber":m.referTo("DenseMatrix, BigNumber",_=>(y,C)=>_(b(y),C).valueOf()),"number, Array":m.referTo("number, DenseMatrix",_=>(y,C)=>_(y,b(C)).valueOf()),"BigNumber, Array":m.referTo("BigNumber, DenseMatrix",_=>(y,C)=>_(y,b(C)).valueOf())}}),tS="leftShift",py=re(tS,["typed","matrix","equalScalar","zeros","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,DenseMatrix:C,concat:A}=p,k=Df({typed:m}),R=gp({typed:m,equalScalar:_}),O=qE({typed:m,equalScalar:_}),F=o_({typed:m,DenseMatrix:C}),B=Bf({typed:m,equalScalar:_}),H=Bp({typed:m}),G=$c({typed:m,matrix:b,concat:A}),J=eS({typed:m,matrix:b});return m(tS,{"number, number":dx,"BigNumber, BigNumber":Ap,"bigint, bigint":(te,be)=>te<<be,"SparseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():B(be,we,te,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():H(be,we,te,!1)),"number | BigNumber, SparseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):F(we,be,te,!0)),"number | BigNumber, DenseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):H(we,be,te,!0))},J,G({SS:O,DS:k,SD:R}))});function hy(p){var{DenseMatrix:m}=p;return function(_,y,C){var A=_.size();if(2!==A.length)throw new RangeError("Matrix must be two dimensional (size: "+xs(A)+")");var k=A[0];if(k!==A[1])throw new RangeError("Matrix must be square (size: "+xs(A)+")");var O=[];if(ut(y)){var F=y.size(),B=y._data;if(1===F.length){if(F[0]!==k)throw new RangeError("Dimension mismatch. Matrix columns must match vector length.");for(var H=0;H<k;H++)O[H]=[B[H]];return new m({data:O,size:[k,1],datatype:y._datatype})}if(2===F.length){if(F[0]!==k||1!==F[1])throw new RangeError("Dimension mismatch. Matrix columns must match vector length.");if(Wt(y)){if(C){O=[];for(var G=0;G<k;G++)O[G]=[B[G][0]];return new m({data:O,size:[k,1],datatype:y._datatype})}return y}if(It(y)){for(var J=0;J<k;J++)O[J]=[0];for(var te=y._values,be=y._index,we=y._ptr,Le=we[1],de=we[0];de<Le;de++)O[be[de]][0]=te[de];return new m({data:O,size:[k,1],datatype:y._datatype})}}throw new RangeError("Dimension mismatch. The right side has to be either 1- or 2-dimensional vector.")}if(dt(y)){var De=Bs(y);if(1===De.length){if(De[0]!==k)throw new RangeError("Dimension mismatch. Matrix columns must match vector length.");for(var pe=0;pe<k;pe++)O[pe]=[y[pe]];return new m({data:O,size:[k,1]})}if(2===De.length){if(De[0]!==k||1!==De[1])throw new RangeError("Dimension mismatch. Matrix columns must match vector length.");for(var Be=0;Be<k;Be++)O[Be]=[y[Be][0]];return new m({data:O,size:[k,1]})}throw new RangeError("Dimension mismatch. The right side has to be either 1- or 2-dimensional vector.")}}}var my=re("lsolve",["typed","matrix","divideScalar","multiplyScalar","subtractScalar","equalScalar","DenseMatrix"],p=>{var{typed:m,matrix:b,divideScalar:_,multiplyScalar:y,subtractScalar:C,equalScalar:A,DenseMatrix:k}=p,R=hy({DenseMatrix:k});return m("lsolve",{"SparseMatrix, Array | Matrix":function(H,G){return function F(B,H){for(var G=(H=R(B,H,!0))._data,J=B._size[0],te=B._size[1],be=B._values,we=B._index,Le=B._ptr,de=[],Te=0;Te<te;Te++){var De=G[Te][0]||0;if(A(De,0))de[Te]=[0];else{for(var pe=0,Be=[],We=[],ze=Le[Te+1],et=Le[Te];et<ze;et++){var pt=we[et];pt===Te?pe=be[et]:pt>Te&&(Be.push(be[et]),We.push(pt))}if(A(pe,0))throw new Error("Linear system cannot be solved since matrix is singular");for(var $t=_(De,pe),Zt=0,Kt=We.length;Zt<Kt;Zt++){var lt=We[Zt];G[lt]=[C(G[lt][0]||0,y($t,Be[Zt]))]}de[Te]=[$t]}}return new k({data:de,size:[J,1]})}(H,G)},"DenseMatrix, Array | Matrix":function(H,G){return O(H,G)},"Array, Array | Matrix":function(H,G){return O(b(H),G).valueOf()}});function O(B,H){for(var G=(H=R(B,H,!0))._data,J=B._size[0],te=B._size[1],be=[],we=B._data,Le=0;Le<te;Le++){var de=G[Le][0]||0,Te=void 0;if(A(de,0))Te=0;else{var De=we[Le][Le];if(A(De,0))throw new Error("Linear system cannot be solved since matrix is singular");Te=_(de,De);for(var pe=Le+1;pe<J;pe++)G[pe]=[C(G[pe][0]||0,y(Te,we[pe][Le]))]}be[Le]=[Te]}return new k({data:be,size:[J,1]})}}),Ea="matrixFromColumns",Oa=re(Ea,["typed","matrix","flatten","size"],p=>{var{typed:m,matrix:b,flatten:_,size:y}=p;return m(Ea,{"...Array":function(R){return C(R)},"...Matrix":function(R){return b(C(R.map(O=>O.toArray())))}});function C(k){if(0===k.length)throw new TypeError("At least one column is needed to construct a matrix.");for(var R=A(k[0]),O=[],F=0;F<R;F++)O[F]=[];for(var B of k){var H=A(B);if(H!==R)throw new TypeError("The vectors had different length: "+(0|R)+" \u2260 "+(0|H));for(var G=_(B),J=0;J<R;J++)O[J].push(G[J])}return O}function A(k){var R=y(k);if(1===R.length)return R[0];if(2===R.length){if(1===R[0])return R[1];if(1===R[1])return R[0];throw new TypeError("At least one of the arguments is not a vector.")}throw new TypeError("Only one- or two-dimensional vectors are supported.")}}),dh=re("matAlgo06xS0S0",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A){var k=y._values,R=y._size,O=y._datatype||void 0===y._data?y._datatype:y.getDataType(),F=C._values,B=C._size,H=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(R.length!==B.length)throw new va(R.length,B.length);if(R[0]!==B[0]||R[1]!==B[1])throw new RangeError("Dimension mismatch. Matrix A ("+R+") must match Matrix B ("+B+")");var te,G=R[0],J=R[1],be=b,we=0,Le=A;"string"==typeof O&&O===H&&"mixed"!==O&&(be=m.find(b,[te=O,te]),we=m.convert(0,te),Le=m.find(A,[te,te]));for(var de=k&&F?[]:void 0,Te=[],De=[],pe=de?[]:void 0,Be=[],We=[],ke=0;ke<J;ke++){De[ke]=Te.length;var ze=ke+1;if(Gl(y,ke,Be,pe,We,ze,Te,Le),Gl(C,ke,Be,pe,We,ze,Te,Le),pe)for(var et=De[ke];et<Te.length;){var pt=Te[et];if(We[pt]===ze){var $t=pe[pt];be($t,we)?Te.splice(et,1):(de.push($t),et++)}else Te.splice(et,1)}else for(var Zt=De[ke];Zt<Te.length;)We[Te[Zt]]!==ze?Te.splice(Zt,1):Zt++}return De[J]=Te.length,y.createSparseMatrix({values:de,index:Te,ptr:De,size:[G,J],datatype:O===y._datatype&&H===C._datatype?te:void 0})}}),gy="nthRoot",nS=re(gy,["typed","matrix","equalScalar","BigNumber","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,BigNumber:y,concat:C}=p,A=Df({typed:m}),k=gp({typed:m,equalScalar:_}),R=dh({typed:m,equalScalar:_}),O=Bf({typed:m,equalScalar:_}),F=$c({typed:m,matrix:b,concat:C});function B(){throw new Error("Complex number not supported in function nthRoot. Use nthRoots instead.")}return m(gy,{number:Ga,"number, number":Ga,BigNumber:G=>H(G,new y(2)),"BigNumber, BigNumber":H,Complex:B,"Complex, number":B,Array:m.referTo("DenseMatrix,number",G=>J=>G(b(J),2).valueOf()),DenseMatrix:m.referTo("DenseMatrix,number",G=>J=>G(J,2)),SparseMatrix:m.referTo("SparseMatrix,number",G=>J=>G(J,2)),"SparseMatrix, SparseMatrix":m.referToSelf(G=>(J,te)=>{if(1===te.density())return R(J,te,G);throw new Error("Root must be non-zero")}),"DenseMatrix, SparseMatrix":m.referToSelf(G=>(J,te)=>{if(1===te.density())return A(J,te,G,!1);throw new Error("Root must be non-zero")}),"Array, SparseMatrix":m.referTo("DenseMatrix,SparseMatrix",G=>(J,te)=>G(b(J),te)),"number | BigNumber, SparseMatrix":m.referToSelf(G=>(J,te)=>{if(1===te.density())return O(te,J,G,!0);throw new Error("Root must be non-zero")})},F({scalar:"number | BigNumber",SD:k,Ss:O,sS:!1}));function H(G,J){var te=y.precision,be=y.clone({precision:te+2}),we=new y(0),Le=new be(1),de=J.isNegative();if(de&&(J=J.neg()),J.isZero())throw new Error("Root must be non-zero");if(G.isNegative()&&!J.abs().mod(2).equals(1))throw new Error("Root must be odd when a is negative.");if(G.isZero())return de?new be(1/0):0;if(!G.isFinite())return de?we:G;var Te=G.abs().pow(Le.div(J));return Te=G.isNeg()?Te.neg():Te,new y((de?Le.div(Te):Te).toPrecision(te))}}),ob=re("ones",["typed","config","matrix","BigNumber"],p=>{var{typed:m,config:b,matrix:_,BigNumber:y}=p;return m("ones",{"":function(){return"Array"===b.matrix?C([]):C([],"default")},"...number | BigNumber | string":function(O){if("string"==typeof O[O.length-1]){var B=O.pop();return C(O,B)}return"Array"===b.matrix?C(O):C(O,"default")},Array:C,Matrix:function(O){var F=O.storage();return C(O.valueOf(),F)},"Array | Matrix, string":function(O,F){return C(O.valueOf(),F)}});function C(R,O){var F=function A(R){var O=!1;return R.forEach(function(F,B,H){en(F)&&(O=!0,H[B]=F.toNumber())}),O}(R),B=F?new y(1):1;if(function k(R){R.forEach(function(O){if("number"!=typeof O||!ai(O)||O<0)throw new Error("Parameters in function ones must be positive integers")})}(R),O){var H=_(O);return R.length>0?H.resize(R,B):H}var G=[];return R.length>0?Mp(G,R,B):G}}),mm=re("qr",["typed","matrix","zeros","identity","isZero","equal","sign","sqrt","conj","unaryMinus","addScalar","divideScalar","multiplyScalar","subtractScalar","complex"],p=>{var{typed:m,matrix:b,zeros:_,identity:y,isZero:C,equal:A,sign:k,sqrt:R,conj:O,unaryMinus:F,addScalar:B,divideScalar:H,multiplyScalar:G,subtractScalar:J,complex:te}=p;return e(m("qr",{DenseMatrix:function(Te){return we(Te)},SparseMatrix:function(Te){return function Le(){throw new Error("qr not implemented for sparse matrices yet")}()},Array:function(Te){var pe=we(b(Te));return{Q:pe.Q.valueOf(),R:pe.R.valueOf()}}}),{_denseQRimpl:be});function be(de){var ze,et,pt,Te=de._size[0],De=de._size[1],pe=y([Te],"dense"),Be=pe._data,We=de.clone(),ke=We._data,$t=_([Te],"");for(pt=0;pt<Math.min(De,Te);++pt){var Zt=ke[pt][pt],Kt=F(A(Zt,0)?1:k(Zt)),lt=O(Kt),st=0;for(ze=pt;ze<Te;ze++)st=B(st,G(ke[ze][pt],O(ke[ze][pt])));var En=G(Kt,R(st));if(!C(En)){var _t=J(Zt,En);for($t[pt]=1,ze=pt+1;ze<Te;ze++)$t[ze]=H(ke[ze][pt],_t);var di=F(O(H(_t,En))),ki=void 0;for(et=pt;et<De;et++){for(ki=0,ze=pt;ze<Te;ze++)ki=B(ki,G(O($t[ze]),ke[ze][et]));for(ki=G(ki,di),ze=pt;ze<Te;ze++)ke[ze][et]=G(J(ke[ze][et],G($t[ze],ki)),lt)}for(ze=0;ze<Te;ze++){for(ki=0,et=pt;et<Te;et++)ki=B(ki,G(Be[ze][et],$t[et]));for(ki=G(ki,di),et=pt;et<Te;++et)Be[ze][et]=H(J(Be[ze][et],G(ki,O($t[et]))),lt)}}}return{Q:pe,R:We,toString:function(){return"Q: "+this.Q.toString()+"\nR: "+this.R.toString()}}}function we(de){var Te=be(de),De=Te.R._data;if(de._data.length>0)for(var pe="Complex"===De[0][0].type?te(0):0,Be=0;Be<De.length;++Be)for(var We=0;We<Be&&We<(De[0]||[]).length;++We)De[Be][We]=pe;return Te}});function af(p,m,b,_){if(!(this instanceof af))throw new SyntaxError("Constructor must be called with the new operator");this.fn=p,this.count=m,this.min=b,this.max=_,this.message="Wrong number of arguments in function "+p+" ("+m+" provided, "+b+(null!=_?"-"+_:"")+" expected)",this.stack=(new Error).stack}(af.prototype=new Error).constructor=Error,af.prototype.name="ArgumentsError",af.prototype.isArgumentsError=!0;var W1=re("resize",["config","matrix"],p=>{var{config:m,matrix:b}=p;return function(C,A,k){if(2!==arguments.length&&3!==arguments.length)throw new af("resize",arguments.length,2,3);if(ut(A)&&(A=A.valueOf()),en(A[0])&&(A=A.map(function(F){return en(F)?F.toNumber():F})),ut(C))return C.resize(A,k,!0);if("string"==typeof C)return function _(y,C,A){if(void 0!==A){if("string"!=typeof A||1!==A.length)throw new TypeError("Single character expected as defaultValue")}else A=" ";if(1!==C.length)throw new va(C.length,1);var k=C[0];if("number"!=typeof k||!ai(k))throw new TypeError("Invalid size, must contain positive integers (size: "+xs(C)+")");if(y.length>k)return y.substring(0,k);if(y.length<k){for(var R=y,O=0,F=k-y.length;O<F;O++)R+=A;return R}return y}(C,A,k);var R=!Array.isArray(C)&&"Array"!==m.matrix;if(0===A.length){for(;Array.isArray(C);)C=C[0];return At(C)}Array.isArray(C)||(C=[C]);var O=Mp(C=At(C),A,k);return R?b(O):O}}),sb="rightArithShift",H1=re(sb,["typed","matrix","equalScalar","zeros","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,DenseMatrix:C,concat:A}=p,k=Df({typed:m}),R=gp({typed:m,equalScalar:_}),O=qE({typed:m,equalScalar:_}),F=o_({typed:m,DenseMatrix:C}),B=Bf({typed:m,equalScalar:_}),H=Bp({typed:m}),G=$c({typed:m,matrix:b,concat:A}),J=eS({typed:m,matrix:b});return m(sb,{"number, number":fa,"BigNumber, BigNumber":_E,"bigint, bigint":(te,be)=>te>>be,"SparseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():B(be,we,te,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():H(be,we,te,!1)),"number | BigNumber, SparseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):F(we,be,te,!0)),"number | BigNumber, DenseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):H(we,be,te,!0))},J,G({SS:O,DS:k,SD:R}))}),lb="Number of decimals in function round must be an integer",z1=re("round",["typed","config","matrix","equalScalar","zeros","BigNumber","DenseMatrix"],p=>{var{typed:m,config:b,matrix:_,equalScalar:y,zeros:C,BigNumber:A,DenseMatrix:k}=p,R=Bf({typed:m,equalScalar:y}),O=Od({typed:m,DenseMatrix:k}),F=Bp({typed:m});function B(H){return Math.abs(ya(H).exponent)}return m("round",{number:function(G){var J=Jh(G,B(b.relTol));return Jh(Di(G,J,b.relTol,b.absTol)?J:G)},"number, number":function(G,J){var te=B(b.relTol);if(J>=te)return Jh(G,J);var be=Jh(G,te);return Jh(Di(G,be,b.relTol,b.absTol)?be:G,J)},"number, BigNumber":function(G,J){if(!J.isInteger())throw new TypeError(lb);return new A(G).toDecimalPlaces(J.toNumber())},Complex:function(G){return G.round()},"Complex, number":function(G,J){if(J%1)throw new TypeError(lb);return G.round(J)},"Complex, BigNumber":function(G,J){if(!J.isInteger())throw new TypeError(lb);var te=J.toNumber();return G.round(te)},BigNumber:function(G){var J=new A(G).toDecimalPlaces(B(b.relTol));return(Zf(G,J,b.relTol,b.absTol)?J:G).toDecimalPlaces(0)},"BigNumber, BigNumber":function(G,J){if(!J.isInteger())throw new TypeError(lb);var te=B(b.relTol);if(J>=te)return G.toDecimalPlaces(J.toNumber());var be=G.toDecimalPlaces(te);return(Zf(G,be,b.relTol,b.absTol)?be:G).toDecimalPlaces(J.toNumber())},Fraction:function(G){return G.round()},"Fraction, number":function(G,J){if(J%1)throw new TypeError(lb);return G.round(J)},"Fraction, BigNumber":function(G,J){if(!J.isInteger())throw new TypeError(lb);return G.round(J.toNumber())},"Unit, number, Unit":m.referToSelf(H=>function(G,J,te){var be=G.toNumeric(te);return te.multiply(H(be,J))}),"Unit, BigNumber, Unit":m.referToSelf(H=>(G,J,te)=>H(G,J.toNumber(),te)),"Unit, Unit":m.referToSelf(H=>(G,J)=>H(G,0,J)),"Array | Matrix, number, Unit":m.referToSelf(H=>(G,J,te)=>ps(G,be=>H(be,J,te),!0)),"Array | Matrix, BigNumber, Unit":m.referToSelf(H=>(G,J,te)=>H(G,J.toNumber(),te)),"Array | Matrix, Unit":m.referToSelf(H=>(G,J)=>H(G,0,J)),"Array | Matrix":m.referToSelf(H=>G=>ps(G,H,!0)),"SparseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>R(G,J,H,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>F(G,J,H,!1)),"Array, number | BigNumber":m.referToSelf(H=>(G,J)=>F(_(G),J,H,!1).valueOf()),"number | Complex | BigNumber | Fraction, SparseMatrix":m.referToSelf(H=>(G,J)=>y(G,0)?C(J.size(),J.storage()):O(J,G,H,!0)),"number | Complex | BigNumber | Fraction, DenseMatrix":m.referToSelf(H=>(G,J)=>y(G,0)?C(J.size(),J.storage()):F(J,G,H,!0)),"number | Complex | BigNumber | Fraction, Array":m.referToSelf(H=>(G,J)=>F(_(J),G,H,!0).valueOf())})}),cb="smaller",jf=re(cb,["typed","config","matrix","DenseMatrix","concat"],p=>{var{typed:m,config:b,matrix:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=Gg({typed:m,DenseMatrix:y}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:_,concat:C}),F=Nv({typed:m});return m(cb,G1({typed:m,config:b}),{"boolean, boolean":(B,H)=>B<H,"BigNumber, BigNumber":function(H,G){return H.lt(G)&&!Zf(H,G,b.relTol,b.absTol)},"bigint, bigint":(B,H)=>B<H,"Fraction, Fraction":(B,H)=>-1===B.compare(H),"Complex, Complex":function(H,G){throw new TypeError("No ordering relation is defined for complex numbers")}},F,O({SS:k,DS:A,Ss:R}))}),G1=re(cb,["typed","config"],p=>{var{typed:m,config:b}=p;return m(cb,{"number, number":function(y,C){return y<C&&!Di(y,C,b.relTol,b.absTol)}})}),YD=re("matAlgo05xSfSf",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A){var k=y._values,R=y._index,O=y._ptr,F=y._size,B=y._datatype||void 0===y._data?y._datatype:y.getDataType(),H=C._values,G=C._index,J=C._ptr,te=C._size,be=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(F.length!==te.length)throw new va(F.length,te.length);if(F[0]!==te[0]||F[1]!==te[1])throw new RangeError("Dimension mismatch. Matrix A ("+F+") must match Matrix B ("+te+")");var de,we=F[0],Le=F[1],Te=b,De=0,pe=A;"string"==typeof B&&B===be&&"mixed"!==B&&(Te=m.find(b,[de=B,de]),De=m.convert(0,de),pe=m.find(A,[de,de]));var Zt,Kt,lt,st,Be=k&&H?[]:void 0,We=[],ke=[],ze=Be?[]:void 0,et=Be?[]:void 0,pt=[],$t=[];for(Kt=0;Kt<Le;Kt++){ke[Kt]=We.length;var En=Kt+1;for(lt=O[Kt],st=O[Kt+1];lt<st;lt++)We.push(Zt=R[lt]),pt[Zt]=En,ze&&(ze[Zt]=k[lt]);for(lt=J[Kt],st=J[Kt+1];lt<st;lt++)pt[Zt=G[lt]]!==En&&We.push(Zt),$t[Zt]=En,et&&(et[Zt]=H[lt]);if(Be)for(lt=ke[Kt];lt<We.length;){var _t=pt[Zt=We[lt]],di=$t[Zt];if(_t===En||di===En){var _n=pe(_t===En?ze[Zt]:De,di===En?et[Zt]:De);Te(_n,De)?We.splice(lt,1):(Be.push(_n),lt++)}}}return ke[Le]=We.length,y.createSparseMatrix({values:Be,index:We,ptr:ke,size:[we,Le],datatype:B===y._datatype&&be===C._datatype?de:void 0})}}),q1="subtract",Vp=re(q1,["typed","matrix","equalScalar","subtractScalar","unaryMinus","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,subtractScalar:y,DenseMatrix:A,concat:k}=p,R=Df({typed:m}),O=Hd({typed:m}),F=YD({typed:m,equalScalar:_}),B=o_({typed:m,DenseMatrix:A}),H=Od({typed:m,DenseMatrix:A}),G=$c({typed:m,matrix:b,concat:k});return m(q1,{"any, any":y},G({elop:y,SS:F,DS:R,SD:O,Ss:H,sS:B}))}),s_=re("to",["typed","matrix","concat"],p=>{var{typed:m,matrix:b,concat:_}=p;return m("to",{"Unit, Unit | string":(C,A)=>C.to(A)},$c({typed:m,matrix:b,concat:_})({Ds:!0}))}),JD="unaryPlus",_y=re(JD,["typed","config","numeric"],p=>{var{typed:m,config:b,numeric:_}=p;return m(JD,{number:Xe,Complex:function(C){return C},BigNumber:function(C){return C},bigint:function(C){return C},Fraction:function(C){return C},Unit:function(C){return C.clone()},"Array | Matrix":m.referToSelf(y=>C=>ps(C,y,!0)),boolean:function(C){return _(C?1:0,b.number)},string:function(C){return _(C,Fr(C,b))}})}),yy=re("usolve",["typed","matrix","divideScalar","multiplyScalar","subtractScalar","equalScalar","DenseMatrix"],p=>{var{typed:m,matrix:b,divideScalar:_,multiplyScalar:y,subtractScalar:C,equalScalar:A,DenseMatrix:k}=p,R=hy({DenseMatrix:k});return m("usolve",{"SparseMatrix, Array | Matrix":function(H,G){return function F(B,H){for(var G=(H=R(B,H,!0))._data,J=B._size[0],be=B._values,we=B._index,Le=B._ptr,de=[],Te=B._size[1]-1;Te>=0;Te--){var De=G[Te][0]||0;if(A(De,0))de[Te]=[0];else{for(var pe=0,Be=[],We=[],ke=Le[Te],et=Le[Te+1]-1;et>=ke;et--){var pt=we[et];pt===Te?pe=be[et]:pt<Te&&(Be.push(be[et]),We.push(pt))}if(A(pe,0))throw new Error("Linear system cannot be solved since matrix is singular");for(var $t=_(De,pe),Zt=0,Kt=We.length;Zt<Kt;Zt++){var lt=We[Zt];G[lt]=[C(G[lt][0],y($t,Be[Zt]))]}de[Te]=[$t]}}return new k({data:de,size:[J,1]})}(H,G)},"DenseMatrix, Array | Matrix":function(H,G){return O(H,G)},"Array, Array | Matrix":function(H,G){return O(b(H),G).valueOf()}});function O(B,H){for(var G=(H=R(B,H,!0))._data,J=B._size[0],be=[],we=B._data,Le=B._size[1]-1;Le>=0;Le--){var de=G[Le][0]||0,Te=void 0;if(A(de,0))Te=0;else{var De=we[Le][Le];if(A(De,0))throw new Error("Linear system cannot be solved since matrix is singular");Te=_(de,De);for(var pe=Le-1;pe>=0;pe--)G[pe]=[C(G[pe][0]||0,y(Te,we[pe][Le]))]}be[Le]=[Te]}return new k({data:be,size:[J,1]})}}),Zg=re("xor",["typed","matrix","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,DenseMatrix:_,concat:y}=p,C=Hd({typed:m}),A=Gg({typed:m,DenseMatrix:_}),k=Od({typed:m,DenseMatrix:_}),R=$c({typed:m,matrix:b,concat:y});return m("xor",{"number, number":ny,"Complex, Complex":function(F,B){return(0!==F.re||0!==F.im)!=(0!==B.re||0!==B.im)},"bigint, bigint":ny,"BigNumber, BigNumber":function(F,B){return(!F.isZero()&&!F.isNaN())!=(!B.isZero()&&!B.isNaN())},"Unit, Unit":m.referToSelf(O=>(F,B)=>O(F.value||0,B.value||0))},R({SS:A,DS:C,Ss:k}))}),nw=re("matAlgo04xSidSid",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A){var k=y._values,R=y._index,O=y._ptr,F=y._size,B=y._datatype||void 0===y._data?y._datatype:y.getDataType(),H=C._values,G=C._index,J=C._ptr,te=C._size,be=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(F.length!==te.length)throw new va(F.length,te.length);if(F[0]!==te[0]||F[1]!==te[1])throw new RangeError("Dimension mismatch. Matrix A ("+F+") must match Matrix B ("+te+")");var de,we=F[0],Le=F[1],Te=b,De=0,pe=A;"string"==typeof B&&B===be&&"mixed"!==B&&(Te=m.find(b,[de=B,de]),De=m.convert(0,de),pe=m.find(A,[de,de]));var Zt,Kt,lt,En,Be=k&&H?[]:void 0,We=[],ke=[],ze=k&&H?[]:void 0,et=k&&H?[]:void 0,pt=[],$t=[];for(Kt=0;Kt<Le;Kt++){ke[Kt]=We.length;var _t=Kt+1;for(En=O[Kt+1],lt=O[Kt];lt<En;lt++)We.push(Zt=R[lt]),pt[Zt]=_t,ze&&(ze[Zt]=k[lt]);for(En=J[Kt+1],lt=J[Kt];lt<En;lt++)if(pt[Zt=G[lt]]===_t){if(ze){var di=pe(ze[Zt],H[lt]);Te(di,De)?pt[Zt]=null:ze[Zt]=di}}else We.push(Zt),$t[Zt]=_t,et&&(et[Zt]=H[lt]);if(ze&&et)for(lt=ke[Kt];lt<We.length;)pt[Zt=We[lt]]===_t?(Be[lt]=ze[Zt],lt++):$t[Zt]===_t?(Be[lt]=et[Zt],lt++):We.splice(lt,1)}return ke[Le]=We.length,y.createSparseMatrix({values:Be,index:We,ptr:ke,size:[we,Le],datatype:B===y._datatype&&be===C._datatype?de:void 0})}}),db=re("add",["typed","matrix","addScalar","equalScalar","DenseMatrix","SparseMatrix","concat"],p=>{var{typed:m,matrix:b,addScalar:_,equalScalar:y,DenseMatrix:C,concat:k}=p,R=Df({typed:m}),O=nw({typed:m,equalScalar:y}),F=o_({typed:m,DenseMatrix:C}),B=$c({typed:m,matrix:b,concat:k});return m("add",{"any, any":_,"any, any, ...any":m.referToSelf(H=>(G,J,te)=>{for(var be=H(G,J),we=0;we<te.length;we++)be=H(be,te[we]);return be})},B({elop:_,DS:R,SS:O,Ss:F}))}),oS=re("matAlgo09xS0Sf",["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return function(y,C,A){var k=y._values,R=y._index,O=y._ptr,F=y._size,B=y._datatype||void 0===y._data?y._datatype:y.getDataType(),H=C._values,G=C._index,J=C._ptr,te=C._size,be=C._datatype||void 0===C._data?C._datatype:C.getDataType();if(F.length!==te.length)throw new va(F.length,te.length);if(F[0]!==te[0]||F[1]!==te[1])throw new RangeError("Dimension mismatch. Matrix A ("+F+") must match Matrix B ("+te+")");var de,we=F[0],Le=F[1],Te=b,De=0,pe=A;"string"==typeof B&&B===be&&"mixed"!==B&&(Te=m.find(b,[de=B,de]),De=m.convert(0,de),pe=m.find(A,[de,de]));var pt,$t,Zt,lt,Be=k&&H?[]:void 0,We=[],ke=[],ze=Be?[]:void 0,et=[];for($t=0;$t<Le;$t++){ke[$t]=We.length;var st=$t+1;if(ze)for(lt=J[$t+1],Zt=J[$t];Zt<lt;Zt++)et[pt=G[Zt]]=st,ze[pt]=H[Zt];for(lt=O[$t+1],Zt=O[$t];Zt<lt;Zt++)if(pt=R[Zt],ze){var _t=pe(k[Zt],et[pt]===st?ze[pt]:De);Te(_t,De)||(We.push(pt),Be.push(_t))}else We.push(pt)}return ke[Le]=We.length,y.createSparseMatrix({values:Be,index:We,ptr:ke,size:[we,Le],datatype:B===y._datatype&&be===C._datatype?de:void 0})}}),a_=re("atan2",["typed","matrix","equalScalar","BigNumber","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,BigNumber:y,DenseMatrix:C,concat:A}=p,k=gp({typed:m,equalScalar:_}),R=Hd({typed:m}),O=oS({typed:m,equalScalar:_}),F=Bf({typed:m,equalScalar:_}),B=Od({typed:m,DenseMatrix:C}),H=$c({typed:m,matrix:b,concat:A});return m("atan2",{"number, number":Math.atan2,"BigNumber, BigNumber":(G,J)=>y.atan2(G,J)},H({scalar:"number | BigNumber",SS:O,DS:R,SD:k,Ss:F,sS:B}))}),Vh=re("bitAnd",["typed","matrix","equalScalar","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,concat:y}=p,C=gp({typed:m,equalScalar:_}),A=dh({typed:m,equalScalar:_}),k=Bf({typed:m,equalScalar:_});return m("bitAnd",{"number, number":Ua,"BigNumber, BigNumber":iD,"bigint, bigint":(O,F)=>O&F},$c({typed:m,matrix:b,concat:y})({SS:A,DS:C,Ss:k}))}),by=re("bitOr",["typed","matrix","equalScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C}=p,A=Df({typed:m}),k=nw({typed:m,equalScalar:_}),R=o_({typed:m,DenseMatrix:y});return m("bitOr",{"number, number":oD,"BigNumber, BigNumber":cx,"bigint, bigint":(F,B)=>F|B},$c({typed:m,matrix:b,concat:C})({SS:k,DS:A,Ss:R}))}),gm=re("bitXor",["typed","matrix","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,DenseMatrix:_,concat:y}=p,C=Hd({typed:m}),A=Gg({typed:m,DenseMatrix:_}),k=Od({typed:m,DenseMatrix:_});return m("bitXor",{"number, number":Pl,"BigNumber, BigNumber":ux,"bigint, bigint":(O,F)=>O^F},$c({typed:m,matrix:b,concat:y})({SS:A,DS:C,Ss:k}))}),fb="catalan",c_=re(fb,["typed","addScalar","divideScalar","multiplyScalar","combinations","isNegative","isInteger"],p=>{var{typed:m,addScalar:b,divideScalar:_,multiplyScalar:y,combinations:C,isNegative:A,isInteger:k}=p;return m(fb,{"number | BigNumber":function(O){if(!k(O)||A(O))throw new TypeError("Non-negative integer value expected in function catalan");return _(C(y(O,2),O),b(O,1))}})}),Cy="compare",Dy=re(Cy,["typed","config","matrix","equalScalar","BigNumber","Fraction","DenseMatrix","concat"],p=>{var{typed:m,config:b,equalScalar:_,matrix:y,BigNumber:C,Fraction:A,DenseMatrix:k,concat:R}=p,O=Hd({typed:m}),F=YD({typed:m,equalScalar:_}),B=Od({typed:m,DenseMatrix:k}),H=$c({typed:m,matrix:y,concat:R}),G=Nv({typed:m});return m(Cy,mb({typed:m,config:b}),{"boolean, boolean":function(te,be){return te===be?0:te>be?1:-1},"BigNumber, BigNumber":function(te,be){return Zf(te,be,b.relTol,b.absTol)?new C(0):new C(te.cmp(be))},"bigint, bigint":function(te,be){return te===be?0n:te>be?1n:-1n},"Fraction, Fraction":function(te,be){return new A(te.compare(be))},"Complex, Complex":function(){throw new TypeError("No ordering relation is defined for complex numbers")}},G,H({SS:F,DS:O,Ss:B}))}),mb=re(Cy,["typed","config"],p=>{var{typed:m,config:b}=p;return m(Cy,{"number, number":function(y,C){return Di(y,C,b.relTol,b.absTol)?0:y>C?1:-1}})}),ph="compareText",JE=["typed","matrix","concat"];Ep.signature="any, any";var ev=re(ph,JE,p=>{var{typed:m,matrix:b,concat:_}=p,y=$c({typed:m,matrix:b,concat:_});return m(ph,Ep,y({elop:Ep,Ds:!0}))}),wy="cumsum",xy=re(wy,["typed","add","unaryPlus"],p=>{var{typed:m,add:b,unaryPlus:_}=p;return m(wy,{Array:y,Matrix:function(O){return O.create(y(O.valueOf(),O.datatype()))},"Array, number | BigNumber":A,"Matrix, number | BigNumber":function(O,F){return O.create(A(O.valueOf(),F),O.datatype())},"...":function(O){if(sd(O))throw new TypeError("All values expected to be scalar in function cumsum");return y(O)}});function y(R){try{return C(R)}catch(O){throw tu(O,wy)}}function C(R){if(0===R.length)return[];for(var O=[_(R[0])],F=1;F<R.length;++F)O.push(b(O[F-1],R[F]));return O}function A(R,O){var F=Bs(R);if(O<0||O>=F.length)throw new bc(O,F.length);try{return k(R,O)}catch(B){throw tu(B,wy)}}function k(R,O){var F,B,H;if(O<=0){if(Array.isArray(R[0][0])){for(H=Jc(R),B=[],F=0;F<H.length;F++)B[F]=k(H[F],O-1);return B}return C(R)}for(B=[],F=0;F<R.length;F++)B[F]=k(R[F],O-1);return B}}),bo="deepEqual",mc=re(bo,["typed","equal"],p=>{var{typed:m,equal:b}=p;return m(bo,{"any, any":function(C,A){return _(C.valueOf(),A.valueOf())}});function _(y,C){if(Array.isArray(y)){if(Array.isArray(C)){var A=y.length;if(A!==C.length)return!1;for(var k=0;k<A;k++)if(!_(y[k],C[k]))return!1;return!0}return!1}return!Array.isArray(C)&&b(y,C)}}),Sy=re("diff",["typed","matrix","subtract","number"],p=>{var{typed:m,matrix:b,subtract:_,number:y}=p;return m("diff",{"Array | Matrix":function(F){return ut(F)?b(A(F.toArray())):A(F)},"Array | Matrix, number":function(F,B){if(!ai(B))throw new RangeError("Dimension must be a whole number");return ut(F)?b(C(F.toArray(),B)):C(F,B)},"Array, BigNumber":m.referTo("Array,number",O=>(F,B)=>O(F,y(B))),"Matrix, BigNumber":m.referTo("Matrix,number",O=>(F,B)=>O(F,y(B)))});function C(O,F){if(ut(O)&&(O=O.toArray()),!Array.isArray(O))throw RangeError("Array/Matrix does not have that many dimensions");if(F>0){var B=[];return O.forEach(H=>{B.push(C(H,F-1))}),B}if(0===F)return A(O);throw RangeError("Cannot have negative dimension")}function A(O){for(var F=[],B=O.length,H=1;H<B;H++)F.push(k(O[H-1],O[H]));return F}function k(O,F){ut(O)&&(O=O.toArray()),ut(F)&&(F=F.toArray());var B=Array.isArray(O),H=Array.isArray(F);if(B&&H)return function R(O,F){if(O.length!==F.length)throw RangeError("Not all sub-arrays have the same length");for(var B=[],H=O.length,G=0;G<H;G++)B.push(k(O[G],F[G]));return B}(O,F);if(!B&&!H)return _(F,O);throw TypeError("Cannot calculate difference between 1 array and 1 non-array")}}),Uf="distance",gb=re(Uf,["typed","addScalar","subtractScalar","divideScalar","multiplyScalar","deepEqual","sqrt","abs"],p=>{var{typed:m,addScalar:b,subtractScalar:_,multiplyScalar:y,divideScalar:C,deepEqual:A,sqrt:k,abs:R}=p;return m(Uf,{"Array, Array, Array":function(De,pe,Be){if(2===De.length&&2===pe.length&&2===Be.length){if(!F(De))throw new TypeError("Array with 2 numbers or BigNumbers expected for first argument");if(!F(pe))throw new TypeError("Array with 2 numbers or BigNumbers expected for second argument");if(!F(Be))throw new TypeError("Array with 2 numbers or BigNumbers expected for third argument");if(A(pe,Be))throw new TypeError("LinePoint1 should not be same with LinePoint2");var We=_(Be[1],pe[1]),ke=_(pe[0],Be[0]),ze=_(y(Be[0],pe[1]),y(pe[0],Be[1]));return be(De[0],De[1],We,ke,ze)}throw new TypeError("Invalid Arguments: Try again")},"Object, Object, Object":function(De,pe,Be){if(2===Object.keys(De).length&&2===Object.keys(pe).length&&2===Object.keys(Be).length){if(!F(De))throw new TypeError("Values of pointX and pointY should be numbers or BigNumbers");if(!F(pe))throw new TypeError("Values of lineOnePtX and lineOnePtY should be numbers or BigNumbers");if(!F(Be))throw new TypeError("Values of lineTwoPtX and lineTwoPtY should be numbers or BigNumbers");if(A(J(pe),J(Be)))throw new TypeError("LinePoint1 should not be same with LinePoint2");if("pointX"in De&&"pointY"in De&&"lineOnePtX"in pe&&"lineOnePtY"in pe&&"lineTwoPtX"in Be&&"lineTwoPtY"in Be){var We=_(Be.lineTwoPtY,pe.lineOnePtY),ke=_(pe.lineOnePtX,Be.lineTwoPtX),ze=_(y(Be.lineTwoPtX,pe.lineOnePtY),y(pe.lineOnePtX,Be.lineTwoPtY));return be(De.pointX,De.pointY,We,ke,ze)}throw new TypeError("Key names do not match")}throw new TypeError("Invalid Arguments: Try again")},"Array, Array":function(De,pe){if(2===De.length&&3===pe.length){if(!F(De))throw new TypeError("Array with 2 numbers or BigNumbers expected for first argument");if(!B(pe))throw new TypeError("Array with 3 numbers or BigNumbers expected for second argument");return be(De[0],De[1],pe[0],pe[1],pe[2])}if(3===De.length&&6===pe.length){if(!B(De))throw new TypeError("Array with 3 numbers or BigNumbers expected for first argument");if(!G(pe))throw new TypeError("Array with 6 numbers or BigNumbers expected for second argument");return we(De[0],De[1],De[2],pe[0],pe[1],pe[2],pe[3],pe[4],pe[5])}if(De.length===pe.length&&De.length>0){if(!H(De))throw new TypeError("All values of an array should be numbers or BigNumbers");if(!H(pe))throw new TypeError("All values of an array should be numbers or BigNumbers");return Le(De,pe)}throw new TypeError("Invalid Arguments: Try again")},"Object, Object":function(De,pe){if(2===Object.keys(De).length&&3===Object.keys(pe).length){if(!F(De))throw new TypeError("Values of pointX and pointY should be numbers or BigNumbers");if(!B(pe))throw new TypeError("Values of xCoeffLine, yCoeffLine and constant should be numbers or BigNumbers");if("pointX"in De&&"pointY"in De&&"xCoeffLine"in pe&&"yCoeffLine"in pe&&"constant"in pe)return be(De.pointX,De.pointY,pe.xCoeffLine,pe.yCoeffLine,pe.constant);throw new TypeError("Key names do not match")}if(3===Object.keys(De).length&&6===Object.keys(pe).length){if(!B(De))throw new TypeError("Values of pointX, pointY and pointZ should be numbers or BigNumbers");if(!G(pe))throw new TypeError("Values of x0, y0, z0, a, b and c should be numbers or BigNumbers");if("pointX"in De&&"pointY"in De&&"x0"in pe&&"y0"in pe&&"z0"in pe&&"a"in pe&&"b"in pe&&"c"in pe)return we(De.pointX,De.pointY,De.pointZ,pe.x0,pe.y0,pe.z0,pe.a,pe.b,pe.c);throw new TypeError("Key names do not match")}if(2===Object.keys(De).length&&2===Object.keys(pe).length){if(!F(De))throw new TypeError("Values of pointOneX and pointOneY should be numbers or BigNumbers");if(!F(pe))throw new TypeError("Values of pointTwoX and pointTwoY should be numbers or BigNumbers");if("pointOneX"in De&&"pointOneY"in De&&"pointTwoX"in pe&&"pointTwoY"in pe)return Le([De.pointOneX,De.pointOneY],[pe.pointTwoX,pe.pointTwoY]);throw new TypeError("Key names do not match")}if(3===Object.keys(De).length&&3===Object.keys(pe).length){if(!B(De))throw new TypeError("Values of pointOneX, pointOneY and pointOneZ should be numbers or BigNumbers");if(!B(pe))throw new TypeError("Values of pointTwoX, pointTwoY and pointTwoZ should be numbers or BigNumbers");if("pointOneX"in De&&"pointOneY"in De&&"pointOneZ"in De&&"pointTwoX"in pe&&"pointTwoY"in pe&&"pointTwoZ"in pe)return Le([De.pointOneX,De.pointOneY,De.pointOneZ],[pe.pointTwoX,pe.pointTwoY,pe.pointTwoZ]);throw new TypeError("Key names do not match")}throw new TypeError("Invalid Arguments: Try again")},Array:function(De){if(!function te(Te){if(2===Te[0].length&&O(Te[0][0])&&O(Te[0][1])){if(Te.some(De=>2!==De.length||!O(De[0])||!O(De[1])))return!1}else{if(!(3===Te[0].length&&O(Te[0][0])&&O(Te[0][1])&&O(Te[0][2])))return!1;if(Te.some(De=>3!==De.length||!O(De[0])||!O(De[1])||!O(De[2])))return!1}return!0}(De))throw new TypeError("Incorrect array format entered for pairwise distance calculation");return function de(Te){for(var De=[],pe=[],Be=[],We=0;We<Te.length-1;We++)for(var ke=We+1;ke<Te.length;ke++)2===Te[0].length?(pe=[Te[We][0],Te[We][1]],Be=[Te[ke][0],Te[ke][1]]):3===Te[0].length&&(pe=[Te[We][0],Te[We][1],Te[We][2]],Be=[Te[ke][0],Te[ke][1],Te[ke][2]]),De.push(Le(pe,Be));return De}(De)}});function O(Te){return"number"==typeof Te||en(Te)}function F(Te){return Te.constructor!==Array&&(Te=J(Te)),O(Te[0])&&O(Te[1])}function B(Te){return Te.constructor!==Array&&(Te=J(Te)),O(Te[0])&&O(Te[1])&&O(Te[2])}function H(Te){return Array.isArray(Te)||(Te=J(Te)),Te.every(O)}function G(Te){return Te.constructor!==Array&&(Te=J(Te)),O(Te[0])&&O(Te[1])&&O(Te[2])&&O(Te[3])&&O(Te[4])&&O(Te[5])}function J(Te){for(var De=Object.keys(Te),pe=[],Be=0;Be<De.length;Be++)pe.push(Te[De[Be]]);return pe}function be(Te,De,pe,Be,We){var ke=R(b(b(y(pe,Te),y(Be,De)),We)),ze=k(b(y(pe,pe),y(Be,Be)));return C(ke,ze)}function we(Te,De,pe,Be,We,ke,ze,et,pt){var $t=[_(y(_(We,De),pt),y(_(ke,pe),et)),_(y(_(ke,pe),ze),y(_(Be,Te),pt)),_(y(_(Be,Te),et),y(_(We,De),ze))];$t=k(b(b(y($t[0],$t[0]),y($t[1],$t[1])),y($t[2],$t[2])));var Zt=k(b(b(y(ze,ze),y(et,et)),y(pt,pt)));return C($t,Zt)}function Le(Te,De){for(var pe=Te.length,Be=0,We=0,ke=0;ke<pe;ke++)We=_(Te[ke],De[ke]),Be=b(y(We,We),Be);return k(Be)}}),jh=re("dot",["typed","addScalar","multiplyScalar","conj","size"],p=>{var{typed:m,addScalar:b,multiplyScalar:_,conj:y,size:C}=p;return m("dot",{"Array | DenseMatrix, Array | DenseMatrix":function k(F,B){var H=A(F,B),G=ut(F)?F._data:F,J=ut(F)?F._datatype||F.getDataType():void 0,te=ut(B)?B._data:B,be=ut(B)?B._datatype||B.getDataType():void 0,we=2===O(F).length,Le=2===O(B).length,de=b,Te=_;if(J&&be&&J===be&&"string"==typeof J&&"mixed"!==J){var De=J;de=m.find(b,[De,De]),Te=m.find(_,[De,De])}if(!we&&!Le){for(var pe=Te(y(G[0]),te[0]),Be=1;Be<H;Be++)pe=de(pe,Te(y(G[Be]),te[Be]));return pe}if(!we&&Le){for(var We=Te(y(G[0]),te[0][0]),ke=1;ke<H;ke++)We=de(We,Te(y(G[ke]),te[ke][0]));return We}if(we&&!Le){for(var ze=Te(y(G[0][0]),te[0]),et=1;et<H;et++)ze=de(ze,Te(y(G[et][0]),te[et]));return ze}if(we&&Le){for(var pt=Te(y(G[0][0]),te[0][0]),$t=1;$t<H;$t++)pt=de(pt,Te(y(G[$t][0]),te[$t][0]));return pt}},"SparseMatrix, SparseMatrix":function R(F,B){A(F,B);for(var H=F._index,G=F._values,J=B._index,te=B._values,be=0,we=b,Le=_,de=0,Te=0;de<H.length&&Te<J.length;){var De=H[de],pe=J[Te];De<pe?de++:De>pe?Te++:De===pe&&(be=we(be,Le(G[de],te[Te])),de++,Te++)}return be}});function A(F,B){var J,te,H=O(F),G=O(B);if(1===H.length)J=H[0];else{if(2!==H.length||1!==H[1])throw new RangeError("Expected a column vector, instead got a matrix of size ("+H.join(", ")+")");J=H[0]}if(1===G.length)te=G[0];else{if(2!==G.length||1!==G[1])throw new RangeError("Expected a column vector, instead got a matrix of size ("+G.join(", ")+")");te=G[0]}if(J!==te)throw new RangeError("Vectors must have equal length ("+J+" != "+te+")");if(0===J)throw new RangeError("Cannot calculate the dot product of empty vectors");return J}function O(F){return ut(F)?F.size():C(F)}}),lS="equalText",Qs=re(lS,["typed","compareText","isZero"],p=>{var{typed:m,compareText:b,isZero:_}=p;return m(lS,{"any, any":function(C,A){return _(b(C,A))}})}),vb="floor",nT=["typed","config","round","matrix","equalScalar","zeros","DenseMatrix"],qo=re(vb,["typed","config","round"],p=>{var{typed:m,config:b,round:_}=p;return m(vb,{number:function(C){return Di(C,_(C),b.relTol,b.absTol)?_(C):Math.floor(C)},"number, number":function(C,A){if(Di(C,_(C,A),b.relTol,b.absTol))return _(C,A);var[k,R]="".concat(C,"e").split("e"),O=Math.floor(Number("".concat(k,"e").concat(Number(R)+A)));return[k,R]="".concat(O,"e").split("e"),Number("".concat(k,"e").concat(Number(R)-A))}})}),Xm=re(vb,nT,p=>{var{typed:m,config:b,round:_,matrix:y,equalScalar:C,zeros:A,DenseMatrix:k}=p,R=Bf({typed:m,equalScalar:C}),O=Od({typed:m,DenseMatrix:k}),F=Bp({typed:m}),B=qo({typed:m,config:b,round:_});return m("floor",{number:B.signatures.number,"number,number":B.signatures["number,number"],Complex:function(G){return G.floor()},"Complex, number":function(G,J){return G.floor(J)},"Complex, BigNumber":function(G,J){return G.floor(J.toNumber())},BigNumber:function(G){return Zf(G,_(G),b.relTol,b.absTol)?_(G):G.floor()},"BigNumber, BigNumber":function(G,J){return Zf(G,_(G,J),b.relTol,b.absTol)?_(G,J):G.toDecimalPlaces(J.toNumber(),Se.ROUND_FLOOR)},Fraction:function(G){return G.floor()},"Fraction, number":function(G,J){return G.floor(J)},"Fraction, BigNumber":function(G,J){return G.floor(J.toNumber())},"Array | Matrix":m.referToSelf(H=>G=>ps(G,H,!0)),"Array, number | BigNumber":m.referToSelf(H=>(G,J)=>ps(G,te=>H(te,J),!0)),"SparseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>R(G,J,H,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>F(G,J,H,!1)),"number | Complex | Fraction | BigNumber, Array":m.referToSelf(H=>(G,J)=>F(y(J),G,H,!0).valueOf()),"number | Complex | Fraction | BigNumber, Matrix":m.referToSelf(H=>(G,J)=>C(G,0)?A(J.size(),J.storage()):"dense"===J.storage()?F(J,G,H,!0):O(J,G,H,!0))})}),Ey=re("mod",["typed","config","round","matrix","equalScalar","zeros","DenseMatrix","concat"],p=>{var{typed:m,config:b,round:_,matrix:y,equalScalar:C,zeros:A,DenseMatrix:k,concat:R}=p,O=Xm({typed:m,config:b,round:_,matrix:y,equalScalar:C,zeros:A,DenseMatrix:k}),F=gp({typed:m,equalScalar:C}),B=Hd({typed:m}),H=YD({typed:m,equalScalar:C}),G=Bf({typed:m,equalScalar:C}),J=Od({typed:m,DenseMatrix:k});return m("mod",{"number, number":function be(we,Le){return 0===Le?we:we-Le*O(we/Le)},"BigNumber, BigNumber":function(Le,de){return de.isZero()?Le:Le.sub(de.mul(O(Le.div(de))))},"bigint, bigint":function(Le,de){if(0n===de)return Le;if(Le<0){var Te=Le%de;return 0n===Te?Te:Te+de}return Le%de},"Fraction, Fraction":function(Le,de){return de.equals(0)?Le:Le.sub(de.mul(O(Le.div(de))))}},$c({typed:m,matrix:y,concat:R})({SS:H,DS:B,SD:F,Ss:G,sS:J}))}),lu=["typed","config","round","matrix","equalScalar","zeros","BigNumber","DenseMatrix","concat"],vp="number | BigNumber | Fraction | Matrix | Array",Uh="".concat(vp,", ").concat(vp,", ...").concat(vp);function J1(p){return!p.some(m=>Array.isArray(m))}var eC=re("gcd",lu,p=>{var{typed:m,matrix:b,config:_,round:y,equalScalar:C,zeros:A,BigNumber:k,DenseMatrix:R,concat:O}=p,F=Ey({typed:m,config:_,round:y,matrix:b,equalScalar:C,zeros:A,DenseMatrix:R,concat:O}),B=Df({typed:m}),H=nw({typed:m,equalScalar:C}),G=o_({typed:m,DenseMatrix:R});return m("gcd",{"number, number":function te(we,Le){if(!ai(we)||!ai(Le))throw new Error("Parameters in function gcd must be integer numbers");for(var de;0!==Le;)de=F(we,Le),we=Le,Le=de;return we<0?-we:we},"BigNumber, BigNumber":function be(we,Le){if(!we.isInt()||!Le.isInt())throw new Error("Parameters in function gcd must be integer numbers");for(var de=new k(0);!Le.isZero();){var Te=F(we,Le);we=Le,Le=Te}return we.lt(de)?we.neg():we},"Fraction, Fraction":(we,Le)=>we.gcd(Le)},$c({typed:m,matrix:b,concat:O})({SS:H,DS:B,Ss:G}),{[Uh]:m.referToSelf(we=>(Le,de,Te)=>{for(var De=we(Le,de),pe=0;pe<Te.length;pe++)De=we(De,Te[pe]);return De}),Array:m.referToSelf(we=>Le=>{if(1===Le.length&&Array.isArray(Le[0])&&J1(Le[0]))return we(...Le[0]);if(J1(Le))return we(...Le);throw new af("gcd() supports only 1d matrices!")}),Matrix:m.referToSelf(we=>Le=>we(Le.toArray()))})}),Ty=re("hypot",["typed","abs","addScalar","divideScalar","multiplyScalar","sqrt","smaller","isPositive"],p=>{var{typed:m,abs:b,addScalar:_,divideScalar:y,multiplyScalar:C,sqrt:A,smaller:k,isPositive:R}=p;return m("hypot",{"... number | BigNumber":O,Array:O,Matrix:F=>O(ns(F.toArray()))});function O(F){for(var B=0,H=0,G=0;G<F.length;G++){if(un(F[G]))throw new TypeError("Unexpected type of argument to hypot");var J=b(F[G]);k(H,J)?(B=C(B,C(y(H,J),y(H,J))),B=_(B,1),H=J):B=_(B,R(J)?C(y(J,H),y(J,H)):J)}return C(H,A(B))}}),_b=re("ImmutableDenseMatrix",["smaller","DenseMatrix"],p=>{var{smaller:m,DenseMatrix:b}=p;function _(y,C){if(!(this instanceof _))throw new SyntaxError("Constructor must be called with the new operator");if(C&&!Ae(C))throw new Error("Invalid datatype: "+C);if(ut(y)||dt(y)){var A=new b(y,C);this._data=A._data,this._size=A._size,this._datatype=A._datatype,this._min=null,this._max=null}else if(y&&dt(y.data)&&dt(y.size))this._data=y.data,this._size=y.size,this._datatype=y.datatype,this._min=typeof y.min<"u"?y.min:null,this._max=typeof y.max<"u"?y.max:null;else{if(y)throw new TypeError("Unsupported type of data ("+pi(y)+")");this._data=[],this._size=[0],this._datatype=C,this._min=null,this._max=null}}return(_.prototype=new b).type="ImmutableDenseMatrix",_.prototype.isImmutableDenseMatrix=!0,_.prototype.subset=function(y){switch(arguments.length){case 1:var C=b.prototype.subset.call(this,y);return ut(C)?new _({data:C._data,size:C._size,datatype:C._datatype}):C;case 2:case 3:throw new Error("Cannot invoke set subset on an Immutable Matrix instance");default:throw new SyntaxError("Wrong number of arguments")}},_.prototype.set=function(){throw new Error("Cannot invoke set on an Immutable Matrix instance")},_.prototype.resize=function(){throw new Error("Cannot invoke resize on an Immutable Matrix instance")},_.prototype.reshape=function(){throw new Error("Cannot invoke reshape on an Immutable Matrix instance")},_.prototype.clone=function(){return new _({data:At(this._data),size:At(this._size),datatype:this._datatype})},_.prototype.toJSON=function(){return{mathjs:"ImmutableDenseMatrix",data:this._data,size:this._size,datatype:this._datatype}},_.fromJSON=function(y){return new _(y)},_.prototype.swapRows=function(){throw new Error("Cannot invoke swapRows on an Immutable Matrix instance")},_.prototype.min=function(){if(null===this._min){var y=null;this.forEach(function(C){(null===y||m(C,y))&&(y=C)}),this._min=null!==y?y:void 0}return this._min},_.prototype.max=function(){if(null===this._max){var y=null;this.forEach(function(C){(null===y||m(y,C))&&(y=C)}),this._max=null!==y?y:void 0}return this._max},_},{isClass:!0}),tv=re("Index",["ImmutableDenseMatrix","getMatrixDataType"],p=>{var{ImmutableDenseMatrix:m,getMatrixDataType:b}=p;function _(C){if(!(this instanceof _))throw new SyntaxError("Constructor must be called with the new operator");this._dimensions=[],this._sourceSize=[],this._isScalar=!0;for(var A=0,k=arguments.length;A<k;A++){var R=arguments[A],O=dt(R),F=ut(R),B=null;if(Vn(R))this._dimensions.push(R),this._isScalar=!1;else if(O||F){var H=void 0;"boolean"===b(R)?(O&&(H=y(nv(R).valueOf())),F&&(H=y(nv(R._data).valueOf())),B=R.valueOf().length):H=y(R.valueOf()),this._dimensions.push(H);var G=H.size();(1!==G.length||1!==G[0]||null!==B)&&(this._isScalar=!1)}else if("number"==typeof R)this._dimensions.push(y([R]));else{if("string"!=typeof R)throw new TypeError("Dimension must be an Array, Matrix, number, string, or Range");this._dimensions.push(R)}this._sourceSize.push(B)}}function y(C){for(var A=0,k=C.length;A<k;A++)if("number"!=typeof C[A]||!ai(C[A]))throw new TypeError("Index parameters must be positive integer numbers");return new m(C)}return _.prototype.type="Index",_.prototype.isIndex=!0,_.prototype.clone=function(){var C=new _;return C._dimensions=At(this._dimensions),C._isScalar=this._isScalar,C._sourceSize=this._sourceSize,C},_.create=function(C){var A=new _;return _.apply(A,C),A},_.prototype.size=function(){for(var C=[],A=0,k=this._dimensions.length;A<k;A++){var R=this._dimensions[A];C[A]="string"==typeof R?1:R.size()[0]}return C},_.prototype.max=function(){for(var C=[],A=0,k=this._dimensions.length;A<k;A++){var R=this._dimensions[A];C[A]="string"==typeof R?R:R.max()}return C},_.prototype.min=function(){for(var C=[],A=0,k=this._dimensions.length;A<k;A++){var R=this._dimensions[A];C[A]="string"==typeof R?R:R.min()}return C},_.prototype.forEach=function(C){for(var A=0,k=this._dimensions.length;A<k;A++)C(this._dimensions[A],A,this)},_.prototype.dimension=function(C){return this._dimensions[C]||null},_.prototype.isObjectProperty=function(){return 1===this._dimensions.length&&"string"==typeof this._dimensions[0]},_.prototype.getObjectProperty=function(){return this.isObjectProperty()?this._dimensions[0]:null},_.prototype.isScalar=function(){return this._isScalar},_.prototype.valueOf=_.prototype.toArray=function(){for(var C=[],A=0,k=this._dimensions.length;A<k;A++){var R=this._dimensions[A];C.push("string"==typeof R?R:R.toArray())}return C},_.prototype.toString=function(){for(var C=[],A=0,k=this._dimensions.length;A<k;A++){var R=this._dimensions[A];C.push("string"==typeof R?JSON.stringify(R):R.toString())}return"["+C.join(", ")+"]"},_.prototype.toJSON=function(){return{mathjs:"Index",dimensions:this._dimensions}},_.fromJSON=function(C){return _.create(C.dimensions)},_},{isClass:!0});function nv(p){var m=[];return p.forEach((b,_)=>{b&&m.push(_)}),m}var wf="larger",My=re(wf,["typed","config","matrix","DenseMatrix","concat"],p=>{var{typed:m,config:b,matrix:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=Gg({typed:m,DenseMatrix:y}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:_,concat:C}),F=Nv({typed:m});return m(wf,pS({typed:m,config:b}),{"boolean, boolean":(B,H)=>B>H,"BigNumber, BigNumber":function(H,G){return H.gt(G)&&!Zf(H,G,b.relTol,b.absTol)},"bigint, bigint":(B,H)=>B>H,"Fraction, Fraction":(B,H)=>1===B.compare(H),"Complex, Complex":function(){throw new TypeError("No ordering relation is defined for complex numbers")}},F,O({SS:k,DS:A,Ss:R}))}),pS=re(wf,["typed","config"],p=>{var{typed:m,config:b}=p;return m(wf,{"number, number":function(y,C){return y>C&&!Di(y,C,b.relTol,b.absTol)}})}),u_=re("log",["config","typed","divideScalar","Complex"],p=>{var{typed:m,config:b,divideScalar:_,Complex:y}=p;return m("log",{number:function(A){return A>=0||b.predictable?function jo(p,m){return m?Math.log(p)/Math.log(m):Math.log(p)}(A):new y(A,0).log()},Complex:function(A){return A.log()},BigNumber:function(A){return!A.isNegative()||b.predictable?A.ln():new y(A.toNumber(),0).log()},"any, any":m.referToSelf(C=>(A,k)=>_(C(A),C(k)))})}),Jm="lsolveAll",Ay=re(Jm,["typed","matrix","divideScalar","multiplyScalar","subtractScalar","equalScalar","DenseMatrix"],p=>{var{typed:m,matrix:b,divideScalar:_,multiplyScalar:y,subtractScalar:C,equalScalar:A,DenseMatrix:k}=p,R=hy({DenseMatrix:k});return m(Jm,{"SparseMatrix, Array | Matrix":function(H,G){return function F(B,H){for(var G=[R(B,H,!0)._data.map(ki=>ki[0])],J=B._size[0],te=B._size[1],be=B._values,we=B._index,Le=B._ptr,de=0;de<te;de++)for(var Te=G.length,De=0;De<Te;De++){for(var pe=G[De],Be=[],We=[],ze=Le[de+1],et=0,pt=Le[de];pt<ze;pt++){var $t=we[pt];$t===de?et=be[pt]:$t>de&&(Be.push(be[pt]),We.push($t))}if(A(et,0))if(A(pe[de],0)){if(0===De){var st=[...pe];st[de]=1;for(var En=0,_t=We.length;En<_t;En++){var di=We[En];st[di]=C(st[di],Be[En])}G.push(st)}}else{if(0===De)return[];G.splice(De,1),De-=1,Te-=1}else{pe[de]=_(pe[de],et);for(var Zt=0,Kt=We.length;Zt<Kt;Zt++){var lt=We[Zt];pe[lt]=C(pe[lt],y(pe[de],Be[Zt]))}}}return G.map(ki=>new k({data:ki.map(Xn=>[Xn]),size:[J,1]}))}(H,G)},"DenseMatrix, Array | Matrix":function(H,G){return O(H,G)},"Array, Array | Matrix":function(H,G){return O(b(H),G).map(be=>be.valueOf())}});function O(B,H){for(var G=[R(B,H,!0)._data.map(We=>We[0])],J=B._data,te=B._size[0],be=B._size[1],we=0;we<be;we++)for(var Le=G.length,de=0;de<Le;de++){var Te=G[de];if(A(J[we][we],0))if(A(Te[we],0)){if(0===de){var pe=[...Te];pe[we]=1;for(var Be=we+1;Be<be;Be++)pe[Be]=C(pe[Be],J[Be][we]);G.push(pe)}}else{if(0===de)return[];G.splice(de,1),de-=1,Le-=1}else{Te[we]=_(Te[we],J[we][we]);for(var De=we+1;De<be;De++)Te[De]=C(Te[De],y(Te[we],J[De][we]))}}return G.map(We=>new k({data:We.map(ke=>[ke]),size:[te,1]}))}}),iv="matrixFromRows",Oy=re(iv,["typed","matrix","flatten","size"],p=>{var{typed:m,matrix:b,flatten:_,size:y}=p;return m(iv,{"...Array":function(R){return C(R)},"...Matrix":function(R){return b(C(R.map(O=>O.toArray())))}});function C(k){if(0===k.length)throw new TypeError("At least one row is needed to construct a matrix.");var R=A(k[0]),O=[];for(var F of k){var B=A(F);if(B!==R)throw new TypeError("The vectors had different length: "+(0|R)+" \u2260 "+(0|B));O.push(_(F))}return O}function A(k){var R=y(k);if(1===R.length)return R[0];if(2===R.length){if(1===R[0])return R[1];if(1===R[1])return R[0];throw new TypeError("At least one of the arguments is not a vector.")}throw new TypeError("Only one- or two-dimensional vectors are supported.")}}),rC=re("min",["typed","config","numeric","smaller"],p=>{var{typed:m,config:b,numeric:_,smaller:y}=p;return m("min",{"Array | Matrix":A,"Array | Matrix, number | BigNumber":function(R,O){return eh(R,O.valueOf(),C)},"...":function(R){if(sd(R))throw new TypeError("Scalar values expected in function min");return A(R)}});function C(k,R){try{return y(k,R)?k:R}catch(O){throw tu(O,"min",R)}}function A(k){var R;if(Ss(k,function(O){try{isNaN(O)&&"number"==typeof O?R=NaN:(void 0===R||y(O,R))&&(R=O)}catch(F){throw tu(F,"min",O)}}),void 0===R)throw new Error("Cannot calculate min of an empty array");return"string"==typeof R&&(R=_(R,Fr(R,b))),R}}),yb="multiply",bb=re(yb,["typed","matrix","addScalar","multiplyScalar","equalScalar","dot"],p=>{var{typed:m,matrix:b,addScalar:_,multiplyScalar:y,equalScalar:C,dot:A}=p,k=Bf({typed:m,equalScalar:C}),R=Bp({typed:m});function O(De,pe){switch(De.length){case 1:switch(pe.length){case 1:if(De[0]!==pe[0])throw new RangeError("Dimension mismatch in multiplication. Vectors must have the same length");break;case 2:if(De[0]!==pe[0])throw new RangeError("Dimension mismatch in multiplication. Vector length ("+De[0]+") must match Matrix rows ("+pe[0]+")");break;default:throw new Error("Can only multiply a 1 or 2 dimensional matrix (Matrix B has "+pe.length+" dimensions)")}break;case 2:switch(pe.length){case 1:if(De[1]!==pe[0])throw new RangeError("Dimension mismatch in multiplication. Matrix columns ("+De[1]+") must match Vector length ("+pe[0]+")");break;case 2:if(De[1]!==pe[0])throw new RangeError("Dimension mismatch in multiplication. Matrix A columns ("+De[1]+") must match Matrix B rows ("+pe[0]+")");break;default:throw new Error("Can only multiply a 1 or 2 dimensional matrix (Matrix B has "+pe.length+" dimensions)")}break;default:throw new Error("Can only multiply a 1 or 2 dimensional matrix (Matrix A has "+De.length+" dimensions)")}}var G=m("_multiplyMatrixVector",{"DenseMatrix, any":function te(De,pe){var Zt,Be=De._data,We=De._size,ke=De._datatype||De.getDataType(),ze=pe._data,et=pe._datatype||pe.getDataType(),pt=We[0],$t=We[1],Kt=_,lt=y;ke&&et&&ke===et&&"string"==typeof ke&&"mixed"!==ke&&(Kt=m.find(_,[Zt=ke,Zt]),lt=m.find(y,[Zt,Zt]));for(var st=[],En=0;En<pt;En++){for(var _t=Be[En],di=lt(_t[0],ze[0]),ki=1;ki<$t;ki++)di=Kt(di,lt(_t[ki],ze[ki]));st[En]=di}return De.createDenseMatrix({data:st,size:[pt],datatype:ke===De._datatype&&et===pe._datatype?Zt:void 0})},"SparseMatrix, any":function Le(De,pe){var Be=De._values,We=De._index,ke=De._ptr,ze=De._datatype||void 0===De._data?De._datatype:De.getDataType();if(!Be)throw new Error("Cannot multiply Pattern only Matrix times Dense Matrix");var En,et=pe._data,pt=pe._datatype||pe.getDataType(),$t=De._size[0],Zt=pe._size[0],Kt=[],lt=[],st=[],_t=_,di=y,ki=C,Xn=0;ze&&pt&&ze===pt&&"string"==typeof ze&&"mixed"!==ze&&(_t=m.find(_,[En=ze,En]),di=m.find(y,[En,En]),ki=m.find(C,[En,En]),Xn=m.convert(0,En));var _n=[],Ni=[];st[0]=0;for(var kr=0;kr<Zt;kr++){var Pi=et[kr];if(!ki(Pi,Xn))for(var Sr=ke[kr+1],ir=ke[kr];ir<Sr;ir++){var lr=We[ir];Ni[lr]?_n[lr]=_t(_n[lr],di(Pi,Be[ir])):(Ni[lr]=!0,lt.push(lr),_n[lr]=di(Pi,Be[ir]))}}for(var wr=lt.length,$r=0;$r<wr;$r++)Kt[$r]=_n[lt[$r]];return st[1]=lt.length,De.createSparseMatrix({values:Kt,index:lt,ptr:st,size:[$t,1],datatype:ze===De._datatype&&pt===pe._datatype?En:void 0})}}),J=m("_multiplyMatrixMatrix",{"DenseMatrix, DenseMatrix":function be(De,pe){var lt,Be=De._data,We=De._size,ke=De._datatype||De.getDataType(),ze=pe._data,et=pe._size,pt=pe._datatype||pe.getDataType(),$t=We[0],Zt=We[1],Kt=et[1],st=_,En=y;ke&&pt&&ke===pt&&"string"==typeof ke&&"mixed"!==ke&&"mixed"!==ke&&(st=m.find(_,[lt=ke,lt]),En=m.find(y,[lt,lt]));for(var _t=[],di=0;di<$t;di++){var ki=Be[di];_t[di]=[];for(var Xn=0;Xn<Kt;Xn++){for(var _n=En(ki[0],ze[0][Xn]),Ni=1;Ni<Zt;Ni++)_n=st(_n,En(ki[Ni],ze[Ni][Xn]));_t[di][Xn]=_n}}return De.createDenseMatrix({data:_t,size:[$t,Kt],datatype:ke===De._datatype&&pt===pe._datatype?lt:void 0})},"DenseMatrix, SparseMatrix":function we(De,pe){var Be=De._data,We=De._size,ke=De._datatype||De.getDataType(),ze=pe._values,et=pe._index,pt=pe._ptr,$t=pe._size,Zt=pe._datatype||void 0===pe._data?pe._datatype:pe.getDataType();if(!ze)throw new Error("Cannot multiply Dense Matrix times Pattern only Matrix");var st,Kt=We[0],lt=$t[1],En=_,_t=y,di=C,ki=0;ke&&Zt&&ke===Zt&&"string"==typeof ke&&"mixed"!==ke&&(En=m.find(_,[st=ke,st]),_t=m.find(y,[st,st]),di=m.find(C,[st,st]),ki=m.convert(0,st));for(var Xn=[],_n=[],Ni=[],kr=pe.createSparseMatrix({values:Xn,index:_n,ptr:Ni,size:[Kt,lt],datatype:ke===De._datatype&&Zt===pe._datatype?st:void 0}),Pi=0;Pi<lt;Pi++){Ni[Pi]=_n.length;var nr=pt[Pi],Sr=pt[Pi+1];if(Sr>nr)for(var ir=0,lr=0;lr<Kt;lr++){for(var wr=lr+1,$r=void 0,Io=nr;Io<Sr;Io++){var ms=et[Io];ir!==wr?($r=_t(Be[lr][ms],ze[Io]),ir=wr):$r=En($r,_t(Be[lr][ms],ze[Io]))}ir===wr&&!di($r,ki)&&(_n.push(lr),Xn.push($r))}}return Ni[lt]=_n.length,kr},"SparseMatrix, DenseMatrix":function de(De,pe){var Be=De._values,We=De._index,ke=De._ptr,ze=De._datatype||void 0===De._data?De._datatype:De.getDataType();if(!Be)throw new Error("Cannot multiply Pattern only Matrix times Dense Matrix");var lt,et=pe._data,pt=pe._datatype||pe.getDataType(),$t=De._size[0],Zt=pe._size[0],Kt=pe._size[1],st=_,En=y,_t=C,di=0;ze&&pt&&ze===pt&&"string"==typeof ze&&"mixed"!==ze&&(st=m.find(_,[lt=ze,lt]),En=m.find(y,[lt,lt]),_t=m.find(C,[lt,lt]),di=m.convert(0,lt));for(var ki=[],Xn=[],_n=[],Ni=De.createSparseMatrix({values:ki,index:Xn,ptr:_n,size:[$t,Kt],datatype:ze===De._datatype&&pt===pe._datatype?lt:void 0}),kr=[],Pi=[],nr=0;nr<Kt;nr++){_n[nr]=Xn.length;for(var Sr=nr+1,ir=0;ir<Zt;ir++){var lr=et[ir][nr];if(!_t(lr,di))for(var $r=ke[ir+1],Io=ke[ir];Io<$r;Io++){var ms=We[Io];Pi[ms]!==Sr?(Pi[ms]=Sr,Xn.push(ms),kr[ms]=En(lr,Be[Io])):kr[ms]=st(kr[ms],En(lr,Be[Io]))}}for(var $n=Xn.length,Zi=_n[nr];Zi<$n;Zi++)ki[Zi]=kr[Xn[Zi]]}return _n[Kt]=Xn.length,Ni},"SparseMatrix, SparseMatrix":function Te(De,pe){var En,Be=De._values,We=De._index,ke=De._ptr,ze=De._datatype||void 0===De._data?De._datatype:De.getDataType(),et=pe._values,pt=pe._index,$t=pe._ptr,Zt=pe._datatype||void 0===pe._data?pe._datatype:pe.getDataType(),Kt=De._size[0],lt=pe._size[1],st=Be&&et,_t=_,di=y;ze&&Zt&&ze===Zt&&"string"==typeof ze&&"mixed"!==ze&&(_t=m.find(_,[En=ze,En]),di=m.find(y,[En,En]));for(var nr,ir,lr,$r,Io,ms,ki=st?[]:void 0,Xn=[],_n=[],Ni=De.createSparseMatrix({values:ki,index:Xn,ptr:_n,size:[Kt,lt],datatype:ze===De._datatype&&Zt===pe._datatype?En:void 0}),kr=st?[]:void 0,Pi=[],xn=0;xn<lt;xn++){_n[xn]=Xn.length;var $n=xn+1;for($r=$t[xn+1],lr=$t[xn];lr<$r;lr++)if(ms=pt[lr],st)for(ir=ke[ms+1],nr=ke[ms];nr<ir;nr++)Pi[Io=We[nr]]!==$n?(Pi[Io]=$n,Xn.push(Io),kr[Io]=di(et[lr],Be[nr])):kr[Io]=_t(kr[Io],di(et[lr],Be[nr]));else for(ir=ke[ms+1],nr=ke[ms];nr<ir;nr++)Pi[Io=We[nr]]!==$n&&(Pi[Io]=$n,Xn.push(Io));if(st)for(var Fn=Xn.length,ti=_n[xn];ti<Fn;ti++)ki[ti]=kr[Xn[ti]]}return _n[lt]=Xn.length,Ni}});return m(yb,y,{"Array, Array":m.referTo("Matrix, Matrix",De=>(pe,Be)=>{O(Bs(pe),Bs(Be));var We=De(b(pe),b(Be));return ut(We)?We.valueOf():We}),"Matrix, Matrix":function(pe,Be){var We=pe.size(),ke=Be.size();return O(We,ke),1===We.length?1===ke.length?function F(De,pe,Be){if(0===Be)throw new Error("Cannot multiply two empty vectors");return A(De,pe)}(pe,Be,We[0]):function B(De,pe){if("dense"!==pe.storage())throw new Error("Support for SparseMatrix not implemented");return function H(De,pe){var Kt,Be=De._data,We=De._size,ke=De._datatype||De.getDataType(),ze=pe._data,et=pe._size,pt=pe._datatype||pe.getDataType(),$t=We[0],Zt=et[1],lt=_,st=y;ke&&pt&&ke===pt&&"string"==typeof ke&&"mixed"!==ke&&(lt=m.find(_,[Kt=ke,Kt]),st=m.find(y,[Kt,Kt]));for(var En=[],_t=0;_t<Zt;_t++){for(var di=st(Be[0],ze[0][_t]),ki=1;ki<$t;ki++)di=lt(di,st(Be[ki],ze[ki][_t]));En[_t]=di}return De.createDenseMatrix({data:En,size:[Zt],datatype:ke===De._datatype&&pt===pe._datatype?Kt:void 0})}(De,pe)}(pe,Be):1===ke.length?G(pe,Be):J(pe,Be)},"Matrix, Array":m.referTo("Matrix,Matrix",De=>(pe,Be)=>De(pe,b(Be))),"Array, Matrix":m.referToSelf(De=>(pe,Be)=>De(b(pe,Be.storage()),Be)),"SparseMatrix, any":function(pe,Be){return k(pe,Be,y,!1)},"DenseMatrix, any":function(pe,Be){return R(pe,Be,y,!1)},"any, SparseMatrix":function(pe,Be){return k(Be,pe,y,!0)},"any, DenseMatrix":function(pe,Be){return R(Be,pe,y,!0)},"Array, any":function(pe,Be){return R(b(pe),Be,y,!1).valueOf()},"any, Array":function(pe,Be){return R(b(Be),pe,y,!0).valueOf()},"any, any":y,"any, any, ...any":m.referToSelf(De=>(pe,Be,We)=>{for(var ke=De(pe,Be),ze=0;ze<We.length;ze++)ke=De(ke,We[ze]);return ke})})}),Cb="nthRoots",ng=re(Cb,["config","typed","divideScalar","Complex"],p=>{var{typed:m,Complex:y}=p,C=[function(R){return new y(R,0)},function(R){return new y(0,R)},function(R){return new y(-R,0)},function(R){return new y(0,-R)}];function A(k,R){if(R<0)throw new Error("Root must be greater than zero");if(0===R)throw new Error("Root must be non-zero");if(R%1!=0)throw new Error("Root must be an integer");if(0===k||0===k.abs())return[new y(0,0)];var F,O="number"==typeof k;(O||0===k.re||0===k.im)&&(F=O?2*+(k<0):0===k.im?2*+(k.re<0):2*+(k.im<0)+1);for(var B=k.arg(),H=k.abs(),G=[],J=Math.pow(H,1/R),te=0;te<R;te++){var be=(F+4*te)/R;be!==Math.round(be)?G.push(new y({r:J,phi:(B+2*Math.PI*te)/R})):G.push(C[be%4](J))}return G}return m(Cb,{Complex:function(R){return A(R,2)},"Complex, number":A})}),rv=re("or",["typed","matrix","equalScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=YD({typed:m,equalScalar:_}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:b,concat:C});return m("or",{"number, number":V0,"Complex, Complex":function(B,H){return 0!==B.re||0!==B.im||0!==H.re||0!==H.im},"BigNumber, BigNumber":function(B,H){return!B.isZero()&&!B.isNaN()||!H.isZero()&&!H.isNaN()},"bigint, bigint":V0,"Unit, Unit":m.referToSelf(F=>(B,H)=>F(B.value||0,H.value||0))},O({SS:k,DS:A,Ss:R}))}),cw="partitionSelect",Db=re(cw,["typed","isNumeric","isNaN","compare"],p=>{var{typed:m,isNumeric:b,isNaN:_,compare:y}=p,C=y,A=(O,F)=>-y(O,F);return m(cw,{"Array | Matrix, number":function(F,B){return k(F,B,C)},"Array | Matrix, number, string":function(F,B,H){if("asc"===H)return k(F,B,C);if("desc"===H)return k(F,B,A);throw new Error('Compare string must be "asc" or "desc"')},"Array | Matrix, number, function":k});function k(O,F,B){if(!ai(F)||F<0)throw new Error("k must be a non-negative integer");if(ut(O)){if(O.size().length>1)throw new Error("Only one dimensional matrices supported");return R(O.valueOf(),F,B)}if(Array.isArray(O))return R(O,F,B)}function R(O,F,B){if(F>=O.length)throw new Error("k out of bounds");for(var H=0;H<O.length;H++)if(b(O[H])&&_(O[H]))return O[H];for(var G=0,J=O.length-1;G<J;){for(var te=G,be=J,we=O[Math.floor(Math.random()*(J-G+1))+G];te<be;)if(B(O[te],we)>=0){var Le=O[be];O[be]=O[te],O[te]=Le,--be}else++te;B(O[te],we)>0&&--te,F<=te?J=te:G=te+1}return O[F]}}),sC="rightLogShift",d_=re(sC,["typed","matrix","equalScalar","zeros","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,DenseMatrix:C,concat:A}=p,k=Df({typed:m}),R=gp({typed:m,equalScalar:_}),O=qE({typed:m,equalScalar:_}),F=o_({typed:m,DenseMatrix:C}),B=Bf({typed:m,equalScalar:_}),H=Bp({typed:m}),G=$c({typed:m,matrix:b,concat:A}),J=eS({typed:m,matrix:b});return m(sC,{"number, number":Ih,"SparseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():B(be,we,te,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(te=>(be,we)=>_(we,0)?be.clone():H(be,we,te,!1)),"number | BigNumber, SparseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):F(we,be,te,!0)),"number | BigNumber, DenseMatrix":m.referToSelf(te=>(be,we)=>_(be,0)?y(we.size(),we.storage()):H(we,be,te,!0))},J,G({SS:O,DS:k,SD:R}))});function jp(p,m,b,_,y,C,A){var k=0;for(b[A]=p;k>=0;){var R=b[A+k],O=b[_+R];-1===O?(k--,C[m++]=R):(b[_+R]=b[y+O],b[A+ ++k]=O)}return m}function Up(p){return-p-2}var oT=re("csAmd",["add","multiply","transpose"],p=>{var{add:m,multiply:b,transpose:_}=p;return function(F,B){if(!B||F<=0||F>3)return null;var H=B._size,G=H[0],J=H[1],te=0,be=Math.max(16,10*Math.sqrt(J)),we=function y(O,F,B,H,G){var J=_(F);if(1===O&&H===B)return m(F,J);if(2===O){for(var te=J._index,be=J._ptr,we=0,Le=0;Le<B;Le++){var de=be[Le];if(be[Le]=we,!(be[Le+1]-de>G))for(var Te=be[Le+1];de<Te;de++)te[we++]=te[de]}return be[B]=we,F=_(J),b(J,F)}return b(J,F)}(F,B,G,J,be=Math.min(J-2,be));!function Ac(p,m,b){for(var _=p._values,y=p._index,C=p._ptr,k=p._size[1],R=0,O=0;O<k;O++){var F=C[O];for(C[O]=R;F<C[O+1];F++)m(y[F],O,_?_[F]:1,b)&&(y[R]=y[F],_&&(_[R]=_[F]),R++)}C[k]=R,y.splice(R,y.length-R),_&&_.splice(R,_.length-R)}(we,R,null);for(var _t,di,ki,Xn,_n,Ni,kr,Pi,nr,Sr,ir,lr,wr,$r,Io,ms,Le=we._index,de=we._ptr,Te=de[J],De=[],pe=[],We=J+1,ke=2*(J+1),ze=3*(J+1),et=4*(J+1),pt=5*(J+1),$t=6*(J+1),Zt=7*(J+1),Kt=De,lt=function C(O,F,B,H,G,J,te,be,we,Le,de,Te){for(var De=0;De<O;De++)B[H+De]=F[De+1]-F[De];B[H+O]=0;for(var pe=0;pe<=O;pe++)B[G+pe]=-1,J[pe]=-1,B[te+pe]=-1,B[be+pe]=-1,B[we+pe]=1,B[Le+pe]=1,B[de+pe]=0,B[Te+pe]=B[H+pe];var Be=k(0,0,B,Le,O);return B[de+O]=-2,F[O]=-1,B[Le+O]=0,Be}(J,de,pe,0,ze,Kt,ke,Zt,We,$t,et,pt),st=function A(O,F,B,H,G,J,te,be,we,Le,de){for(var Te=0,De=0;De<O;De++){var pe=B[H+De];if(0===pe)B[G+De]=-2,Te++,F[De]=-1,B[J+De]=0;else if(pe>te)B[be+De]=0,B[G+De]=-1,Te++,F[De]=Up(O),B[be+O]++;else{var Be=B[we+pe];-1!==Be&&(Le[Be]=De),B[de+De]=B[we+pe],B[we+pe]=De}}return Te}(J,de,pe,pt,et,$t,be,We,ze,Kt,ke),En=0;st<J;){for(ki=-1;En<J&&-1===(ki=pe[ze+En]);En++);-1!==pe[ke+ki]&&(Kt[pe[ke+ki]]=-1),pe[ze+En]=pe[ke+ki];var xn=pe[et+ki],$n=pe[We+ki];st+=$n;var Zi=0;pe[We+ki]=-$n;var Fn=de[ki],ti=0===xn?Fn:Te,Mi=ti;for(Xn=1;Xn<=xn+1;Xn++){for(Xn>xn?(Ni=ki,kr=Fn,Pi=pe[0+ki]-xn):(kr=de[Ni=Le[Fn++]],Pi=pe[0+Ni]),_n=1;_n<=Pi;_n++)!((nr=pe[We+(_t=Le[kr++])])<=0)&&(Zi+=nr,pe[We+_t]=-nr,Le[Mi++]=_t,-1!==pe[ke+_t]&&(Kt[pe[ke+_t]]=Kt[_t]),-1!==Kt[_t]?pe[ke+Kt[_t]]=pe[ke+_t]:pe[ze+pe[pt+_t]]=pe[ke+_t]);Ni!==ki&&(de[Ni]=Up(ki),pe[$t+Ni]=0)}for(0!==xn&&(Te=Mi),pe[pt+ki]=Zi,de[ki]=ti,pe[0+ki]=Mi-ti,pe[et+ki]=-2,lt=k(lt,te,pe,$t,J),Sr=ti;Sr<Mi;Sr++)if(!((ir=pe[et+(_t=Le[Sr])])<=0)){var Pr=lt-(nr=-pe[We+_t]);for(Fn=de[_t],lr=de[_t]+ir-1;Fn<=lr;Fn++)pe[$t+(Ni=Le[Fn])]>=lt?pe[$t+Ni]-=nr:0!==pe[$t+Ni]&&(pe[$t+Ni]=pe[pt+Ni]+Pr)}for(Sr=ti;Sr<Mi;Sr++){for(wr=(lr=de[_t=Le[Sr]])+pe[et+_t]-1,$r=lr,Io=0,ms=0,Fn=lr;Fn<=wr;Fn++)if(0!==pe[$t+(Ni=Le[Fn])]){var Br=pe[$t+Ni]-lt;Br>0?(ms+=Br,Le[$r++]=Ni,Io+=Ni):(de[Ni]=Up(ki),pe[$t+Ni]=0)}pe[et+_t]=$r-lr+1;var Go=$r,Zr=lr+pe[0+_t];for(Fn=wr+1;Fn<Zr;Fn++){var rl=pe[We+(di=Le[Fn])];rl<=0||(ms+=rl,Le[$r++]=di,Io+=di)}0===ms?(de[_t]=Up(ki),Zi-=nr=-pe[We+_t],$n+=nr,st+=nr,pe[We+_t]=0,pe[et+_t]=-1):(pe[pt+_t]=Math.min(pe[pt+_t],ms),Le[$r]=Le[Go],Le[Go]=Le[lr],Le[lr]=ki,pe[0+_t]=$r-lr+1,pe[ke+_t]=pe[Zt+(Io=(Io<0?-Io:Io)%J)],pe[Zt+Io]=_t,Kt[_t]=Io)}for(pe[pt+ki]=Zi,lt=k(lt+(te=Math.max(te,Zi)),te,pe,$t,J),Sr=ti;Sr<Mi;Sr++)if(!(pe[We+(_t=Le[Sr])]>=0))for(_t=pe[Zt+(Io=Kt[_t])],pe[Zt+Io]=-1;-1!==_t&&-1!==pe[ke+_t];_t=pe[ke+_t],lt++){for(Pi=pe[0+_t],ir=pe[et+_t],Fn=de[_t]+1;Fn<=de[_t]+Pi-1;Fn++)pe[$t+Le[Fn]]=lt;var Nl=_t;for(di=pe[ke+_t];-1!==di;){var Ru=pe[0+di]===Pi&&pe[et+di]===ir;for(Fn=de[di]+1;Ru&&Fn<=de[di]+Pi-1;Fn++)pe[$t+Le[Fn]]!==lt&&(Ru=0);Ru?(de[di]=Up(_t),pe[We+_t]+=pe[We+di],pe[We+di]=0,pe[et+di]=-1,pe[ke+Nl]=di=pe[ke+di]):(Nl=di,di=pe[ke+di])}}for(Fn=ti,Sr=ti;Sr<Mi;Sr++)!((nr=-pe[We+(_t=Le[Sr])])<=0)&&(pe[We+_t]=nr,ms=pe[pt+_t]+Zi-nr,-1!==pe[ze+(ms=Math.min(ms,J-st-nr))]&&(Kt[pe[ze+ms]]=_t),pe[ke+_t]=pe[ze+ms],Kt[_t]=-1,pe[ze+ms]=_t,En=Math.min(En,ms),pe[pt+_t]=ms,Le[Fn++]=_t);pe[We+ki]=$n,0==(pe[0+ki]=Fn-ti)&&(de[ki]=-1,pe[$t+ki]=0),0!==xn&&(Te=Fn)}for(_t=0;_t<J;_t++)de[_t]=Up(de[_t]);for(di=0;di<=J;di++)pe[ze+di]=-1;for(di=J;di>=0;di--)pe[We+di]>0||(pe[ke+di]=pe[ze+de[di]],pe[ze+de[di]]=di);for(Ni=J;Ni>=0;Ni--)pe[We+Ni]<=0||-1!==de[Ni]&&(pe[ke+Ni]=pe[ze+de[Ni]],pe[ze+de[Ni]]=Ni);for(ki=0,_t=0;_t<=J;_t++)-1===de[_t]&&(ki=jp(_t,ki,pe,ze,ke,De,$t));return De.splice(De.length-1,1),De};function k(O,F,B,H,G){if(O<2||O+F<0){for(var J=0;J<G;J++)0!==B[H+J]&&(B[H+J]=1);O=2}return O}function R(O,F){return O!==F}});function MA(p,m,b,_,y,C,A){var k,R,F,O=0;if(p<=m||b[_+m]<=b[y+p])return-1;b[y+p]=b[_+m];var B=b[C+p];if(b[C+p]=m,-1===B)O=1,F=p;else{for(O=2,F=B;F!==b[A+F];F=b[A+F]);for(k=B;k!==F;k=R)R=b[A+k],b[A+k]=F}return{jleaf:O,q:F}}var dw=re("csCounts",["transpose"],p=>{var{transpose:m}=p;return function(b,_,y,C){if(!b||!_||!y)return null;var O,F,B,H,G,te,A=b._size,k=A[0],R=A[1],be=4*R+(C?R+k+1:0),we=[],de=R,Te=2*R,De=3*R,pe=4*R,Be=5*R+1;for(B=0;B<be;B++)we[B]=-1;var We=[],ke=m(b),ze=ke._index,et=ke._ptr;for(B=0;B<R;B++)for(We[F=y[B]]=-1===we[De+F]?1:0;-1!==F&&-1===we[De+F];F=_[F])we[De+F]=B;if(C){for(B=0;B<R;B++)we[y[B]]=B;for(O=0;O<k;O++){for(B=R,te=et[O+1],G=et[O];G<te;G++)B=Math.min(B,we[ze[G]]);we[Be+O]=we[pe+B],we[pe+B]=O}}for(O=0;O<R;O++)we[0+O]=O;for(B=0;B<R;B++){for(-1!==_[F=y[B]]&&We[_[F]]--,H=C?we[pe+B]:F;-1!==H;H=C?we[Be+H]:-1)for(G=et[H];G<et[H+1];G++){var pt=MA(O=ze[G],F,we,De,de,Te,0);pt.jleaf>=1&&We[F]++,2===pt.jleaf&&We[pt.q]--}-1!==_[F]&&(we[0+F]=_[F])}for(F=0;F<R;F++)-1!==_[F]&&(We[_[F]]+=We[F]);return We}}),WM=re("csSqr",["add","multiply","transpose"],p=>{var{add:m,multiply:b,transpose:_}=p,y=oT({add:m,multiply:b,transpose:_}),C=dw({transpose:_});return function(R,O,F){var J,B=O._ptr,G=O._size[1],te={};if(te.q=y(R,O),R&&!te.q)return null;if(F){var be=R?function aC(p,m,b,_){for(var y=p._values,C=p._index,A=p._ptr,k=p._size,R=p._datatype,O=k[0],F=k[1],B=_&&p._values?[]:null,H=[],G=[],J=0,te=0;te<F;te++){G[te]=J;for(var be=b?b[te]:te,Le=A[be+1],de=A[be];de<Le;de++)H[J]=m?m[C[de]]:C[de],B&&(B[J]=y[de]),J++}return G[F]=J,p.createSparseMatrix({values:B,index:H,ptr:G,size:[O,F],datatype:R})}(O,null,te.q,0):O;te.parent=function wb(p,m){if(!p)return null;var B,H,b=p._index,_=p._ptr,y=p._size,C=y[0],A=y[1],k=[],R=[],F=A;if(m)for(B=0;B<C;B++)R[F+B]=-1;for(var G=0;G<A;G++){k[G]=-1,R[0+G]=-1;for(var te=_[G+1],be=_[G];be<te;be++){var we=b[be];for(B=m?R[F+we]:we;-1!==B&&B<G;B=H)H=R[0+B],R[0+B]=G,-1===H&&(k[B]=G);m&&(R[F+we]=G)}}return k}(be,1);var we=function Fy(p,m){if(!p)return null;var _,b=0,y=[],C=[],k=m,R=2*m;for(_=0;_<m;_++)C[0+_]=-1;for(_=m-1;_>=0;_--)-1!==p[_]&&(C[k+_]=C[0+p[_]],C[0+p[_]]=_);for(_=0;_<m;_++)-1===p[_]&&(b=jp(_,b,C,0,k,y,R));return y}(te.parent,G);if(te.cp=C(be,te.parent,we,1),be&&te.parent&&te.cp&&function A(k,R){var O=k._ptr,F=k._index,B=k._size,H=B[0],G=B[1];R.pinv=[],R.leftmost=[];var pe,Be,We,ze,J=R.parent,te=R.pinv,be=R.leftmost,we=[],de=H,Te=H+G,De=H+2*G;for(Be=0;Be<G;Be++)we[de+Be]=-1,we[Te+Be]=-1,we[De+Be]=0;for(pe=0;pe<H;pe++)be[pe]=-1;for(Be=G-1;Be>=0;Be--)for(ze=O[Be+1],We=O[Be];We<ze;We++)be[F[We]]=Be;for(pe=H-1;pe>=0;pe--)te[pe]=-1,-1!==(Be=be[pe])&&(0==we[De+Be]++&&(we[Te+Be]=pe),we[0+pe]=we[de+Be],we[de+Be]=pe);for(R.lnz=0,R.m2=H,Be=0;Be<G;Be++)if(pe=we[de+Be],R.lnz++,pe<0&&(pe=R.m2++),te[pe]=Be,!(--De[Be]<=0)){R.lnz+=we[De+Be];var et=J[Be];-1!==et&&(0===we[De+et]&&(we[Te+et]=we[Te+Be]),we[0+we[Te+Be]]=we[de+et],we[de+et]=we[0+pe],we[De+et]+=we[De+Be])}for(pe=0;pe<H;pe++)te[pe]<0&&(te[pe]=Be++);return!0}(be,te))for(te.unz=0,J=0;J<G;J++)te.unz+=te.cp[J]}else te.unz=4*B[G]+G,te.lnz=te.unz;return te}});function lC(p,m){return p[m]<0}function cC(p,m){p[m]=Up(p[m])}function uC(p){return p<0?Up(p):p}function xb(p,m,b,_,y){var O,F,B,C=m._index,A=m._ptr,R=m._size[1],H=0;for(_[0]=p;H>=0;){p=_[H];var G=y?y[p]:p;lC(A,p)||(cC(A,p),_[R+H]=G<0?0:uC(A[G]));var J=1;for(F=_[R+H],B=G<0?0:uC(A[G+1]);F<B;F++)if(!lC(A,O=C[F])){_[R+H]=F,_[++H]=O,J=0;break}J&&(H--,_[--b]=p)}return b}var fw=re("csSpsolve",["divideScalar","multiply","subtract"],p=>{var{divideScalar:m,multiply:b,subtract:_}=p;return function(C,A,k,R,O,F,B){var Te,De,pe,Be,H=C._values,G=C._index,J=C._ptr,be=C._size[1],we=A._values,Le=A._index,de=A._ptr,We=function f_(p,m,b,_,y){var F,H,C=p._ptr,k=m._index,R=m._ptr,O=p._size[1],G=O;for(H=R[b+1],F=R[b];F<H;F++){var J=k[F];lC(C,J)||(G=xb(J,p,G,_,y))}for(F=G;F<O;F++)cC(C,_[F]);return G}(C,A,k,R,F);for(Te=We;Te<be;Te++)O[R[Te]]=0;for(pe=de[k+1],Te=De=de[k];Te<pe;Te++)O[Le[Te]]=we[Te];for(var ke=We;ke<be;ke++){var ze=R[ke],et=F?F[ze]:ze;if(!(et<0))for(De=J[et],pe=J[et+1],O[ze]=m(O[ze],H[B?De:pe-1]),Te=B?De+1:De,Be=B?pe:pe-1;Te<Be;Te++){var pt=G[Te];O[pt]=_(O[pt],b(H[Te],O[ze]))}}return We}}),dC=re("csLu",["abs","divideScalar","multiply","subtract","larger","largerEq","SparseMatrix"],p=>{var{abs:m,divideScalar:b,multiply:_,subtract:y,larger:C,largerEq:A,SparseMatrix:k}=p,R=fw({divideScalar:b,multiply:_,subtract:y});return function(F,B,H){if(!F)return null;var te,J=F._size[1],be=100,we=100;B&&(te=B.q,be=B.lnz||be,we=B.unz||we);var et,pt,Le=[],de=[],Te=[],De=new k({values:Le,index:de,ptr:Te,size:[J,J]}),pe=[],Be=[],We=[],ke=new k({values:pe,index:Be,ptr:We,size:[J,J]}),ze=[],$t=[],Zt=[];for(et=0;et<J;et++)$t[et]=0,ze[et]=-1,Te[et+1]=0;be=0,we=0;for(var Kt=0;Kt<J;Kt++){Te[Kt]=be,We[Kt]=we;var lt=te?te[Kt]:Kt,st=R(De,F,lt,Zt,$t,ze,1),En=-1,_t=-1;for(pt=st;pt<J;pt++)if(ze[et=Zt[pt]]<0){var di=m($t[et]);C(di,_t)&&(_t=di,En=et)}else Be[we]=ze[et],pe[we++]=$t[et];if(-1===En||_t<=0)return null;ze[lt]<0&&A(m($t[lt]),_(_t,H))&&(En=lt);var ki=$t[En];for(Be[we]=Kt,pe[we++]=ki,ze[En]=Kt,de[be]=En,Le[be++]=1,pt=st;pt<J;pt++)ze[et=Zt[pt]]<0&&(de[be]=et,Le[be++]=b($t[et],ki)),$t[et]=0}for(Te[J]=be,We[J]=we,pt=0;pt<be;pt++)de[pt]=ze[de[pt]];return Le.splice(be,Le.length-be),de.splice(be,de.length-be),pe.splice(we,pe.length-we),Be.splice(we,Be.length-we),{L:De,U:ke,pinv:ze}}}),h_=re("slu",["typed","abs","add","multiply","transpose","divideScalar","subtract","larger","largerEq","SparseMatrix"],p=>{var{typed:m,abs:b,add:_,multiply:y,transpose:C,divideScalar:A,subtract:k,larger:R,largerEq:O,SparseMatrix:F}=p,B=WM({add:_,multiply:y,transpose:C}),H=dC({abs:b,divideScalar:A,multiply:y,subtract:k,larger:R,largerEq:O,SparseMatrix:F});return m("slu",{"SparseMatrix, number, number":function(J,te,be){if(!ai(te)||te<0||te>3)throw new Error("Symbolic Ordering and Analysis order must be an integer number in the interval [0, 3]");if(be<0||be>1)throw new Error("Partial pivoting threshold must be a number from 0 to 1");var we=B(te,J,!1),Le=H(J,we,be);return{L:Le.L,U:Le.U,p:Le.pinv,q:we.q,toString:function(){return"L: "+this.L.toString()+"\nU: "+this.U.toString()+"\np: "+this.p.toString()+(this.q?"\nq: "+this.q.toString():"")+"\n"}}}})}),ov=re("subset",["typed","matrix","zeros","add"],p=>{var{typed:m,matrix:b,zeros:_,add:y}=p;return m("subset",{"Matrix, Index":function(k,R){return Tp(R)?b():(Wu(k,R),k.subset(R))},"Array, Index":m.referTo("Matrix, Index",function(A){return function(k,R){var O=A(b(k),R);return R.isScalar()?O:O.valueOf()}}),"Object, Index":m_,"string, Index":pw,"Matrix, Index, any, any":function(k,R,O,F){return Tp(R)?k:(Wu(k,R),k.clone().subset(R,function C(A,k){if("string"==typeof A)throw new Error("can't boradcast a string");if(k._isScalar)return A;var R=k.size();if(!R.every(O=>O>0))return A;try{return y(A,_(R))}catch{return A}}(O,R),F))},"Array, Index, any, any":m.referTo("Matrix, Index, any, any",function(A){return function(k,R,O,F){var B=A(b(k),R,O,F);return B.isMatrix?B.valueOf():B}}),"Array, Index, any":m.referTo("Matrix, Index, any, any",function(A){return function(k,R,O){return A(b(k),R,O,void 0).valueOf()}}),"Matrix, Index, any":m.referTo("Matrix, Index, any, any",function(A){return function(k,R,O){return A(k,R,O,void 0)}}),"string, Index, string":hw,"string, Index, string, string":hw,"Object, Index, any":cT})});function pw(p,m){if(!pn(m))throw new TypeError("Index expected");if(Tp(m))return"";if(Wu(Array.from(p),m),1!==m.size().length)throw new va(m.size().length,1);var b=p.length;zl(m.min()[0],b),zl(m.max()[0],b);var _=m.dimension(0),y="";return _.forEach(function(C){y+=p.charAt(C)}),y}function hw(p,m,b,_){if(!m||!0!==m.isIndex)throw new TypeError("Index expected");if(Tp(m))return p;if(Wu(Array.from(p),m),1!==m.size().length)throw new va(m.size().length,1);if(void 0!==_){if("string"!=typeof _||1!==_.length)throw new TypeError("Single character expected as defaultValue")}else _=" ";var y=m.dimension(0);if(y.size()[0]!==b.length)throw new va(y.size()[0],b.length);var A=p.length;zl(m.min()[0]),zl(m.max()[0]);for(var k=[],R=0;R<A;R++)k[R]=p.charAt(R);if(y.forEach(function(B,H){k[B]=b.charAt(H[0])}),k.length>A)for(var O=A-1,F=k.length;O<F;O++)k[O]||(k[O]=_);return k.join("")}function m_(p,m){if(!Tp(m)){if(1!==m.size().length)throw new va(m.size(),1);var b=m.dimension(0);if("string"!=typeof b)throw new TypeError("String expected as index to retrieve an object property");return X(p,b)}}function cT(p,m,b){if(Tp(m))return p;if(1!==m.size().length)throw new va(m.size(),1);var _=m.dimension(0);if("string"!=typeof _)throw new TypeError("String expected as index to retrieve an object property");var y=At(p);return ie(y,_,b),y}var ig=re("sum",["typed","config","add","numeric"],p=>{var{typed:m,config:b,add:_,numeric:y}=p;return m("sum",{"Array | Matrix":C,"Array | Matrix, number | BigNumber":function A(k,R){try{return eh(k,R,_)}catch(F){throw tu(F,"sum")}},"...":function(R){if(sd(R))throw new TypeError("Scalar values expected in function sum");return C(R)}});function C(k){var R;return Ss(k,function(O){try{R=void 0===R?O:_(R,O)}catch(F){throw tu(F,"sum",O)}}),void 0===R&&(R=y(0,b.number)),"string"==typeof R&&(R=y(R,Fr(R,b))),R}}),vm=re("trace",["typed","matrix","add"],p=>{var{typed:m,matrix:b,add:_}=p;return m("trace",{Array:function(k){return y(b(k))},SparseMatrix:function C(A){var k=A._values,R=A._index,O=A._ptr,F=A._size,H=F[1];if(F[0]===H){var G=0;if(k.length>0)for(var J=0;J<H;J++)for(var be=O[J+1],we=O[J];we<be;we++){var Le=R[we];if(Le===J){G=_(G,k[we]);break}if(Le>J)break}return G}throw new RangeError("Matrix must be square (size: "+xs(F)+")")},DenseMatrix:y,any:At});function y(A){var k=A._size,R=A._data;switch(k.length){case 1:if(1===k[0])return At(R[0]);throw new RangeError("Matrix must be square (size: "+xs(k)+")");case 2:var O=k[0];if(O===k[1]){for(var B=0,H=0;H<O;H++)B=_(B,R[H][H]);return B}throw new RangeError("Matrix must be square (size: "+xs(k)+")");default:throw new RangeError("Matrix must be two dimensional (size: "+xs(k)+")")}}}),bS="usolveAll",Fs=re(bS,["typed","matrix","divideScalar","multiplyScalar","subtractScalar","equalScalar","DenseMatrix"],p=>{var{typed:m,matrix:b,divideScalar:_,multiplyScalar:y,subtractScalar:C,equalScalar:A,DenseMatrix:k}=p,R=hy({DenseMatrix:k});return m(bS,{"SparseMatrix, Array | Matrix":function(H,G){return function F(B,H){for(var G=[R(B,H,!0)._data.map(ki=>ki[0])],J=B._size[0],be=B._values,we=B._index,Le=B._ptr,de=B._size[1]-1;de>=0;de--)for(var Te=G.length,De=0;De<Te;De++){for(var pe=G[De],Be=[],We=[],ke=Le[de],et=0,pt=Le[de+1]-1;pt>=ke;pt--){var $t=we[pt];$t===de?et=be[pt]:$t<de&&(Be.push(be[pt]),We.push($t))}if(A(et,0))if(A(pe[de],0)){if(0===De){var st=[...pe];st[de]=1;for(var En=0,_t=We.length;En<_t;En++){var di=We[En];st[di]=C(st[di],Be[En])}G.push(st)}}else{if(0===De)return[];G.splice(De,1),De-=1,Te-=1}else{pe[de]=_(pe[de],et);for(var Zt=0,Kt=We.length;Zt<Kt;Zt++){var lt=We[Zt];pe[lt]=C(pe[lt],y(pe[de],Be[Zt]))}}}return G.map(ki=>new k({data:ki.map(Xn=>[Xn]),size:[J,1]}))}(H,G)},"DenseMatrix, Array | Matrix":function(H,G){return O(H,G)},"Array, Array | Matrix":function(H,G){return O(b(H),G).map(be=>be.valueOf())}});function O(B,H){for(var G=[R(B,H,!0)._data.map(We=>We[0])],J=B._data,te=B._size[0],we=B._size[1]-1;we>=0;we--)for(var Le=G.length,de=0;de<Le;de++){var Te=G[de];if(A(J[we][we],0))if(A(Te[we],0)){if(0===de){var pe=[...Te];pe[we]=1;for(var Be=we-1;Be>=0;Be--)pe[Be]=C(pe[Be],J[Be][we]);G.push(pe)}}else{if(0===de)return[];G.splice(de,1),de-=1,Le-=1}else{Te[we]=_(Te[we],J[we][we]);for(var De=we-1;De>=0;De--)Te[De]=C(Te[De],y(Te[we],J[De][we]))}}return G.map(We=>new k({data:We.map(ke=>[ke]),size:[te,1]}))}}),rg=re("zpk2tf",["typed","add","multiply","Complex","number"],p=>{var{typed:m,add:b,multiply:_,Complex:y,number:C}=p;return m("zpk2tf",{"Array,Array,number":function(O,F,B){return A(O,F,B)},"Array,Array":function(O,F){return A(O,F,1)},"Matrix,Matrix,number":function(O,F,B){return A(O.valueOf(),F.valueOf(),B)},"Matrix,Matrix":function(O,F){return A(O.valueOf(),F.valueOf(),1)}});function A(R,O,F){R.some(Le=>"BigNumber"===Le.type)&&(R=R.map(Le=>C(Le))),O.some(Le=>"BigNumber"===Le.type)&&(O=O.map(Le=>C(Le)));for(var B=[y(1,0)],H=[y(1,0)],G=0;G<R.length;G++){var J=R[G];"number"==typeof J&&(J=y(J,0)),B=k(B,[y(1,0),y(-J.re,-J.im)])}for(var te=0;te<O.length;te++){var be=O[te];"number"==typeof be&&(be=y(be,0)),H=k(H,[y(1,0),y(-be.re,-be.im)])}for(var we=0;we<B.length;we++)B[we]=_(B[we],F);return[B,H]}function k(R,O){for(var F=[],B=0;B<R.length+O.length-1;B++){F[B]=y(0,0);for(var H=0;H<R.length;H++)B-H>=0&&B-H<O.length&&(F[B]=b(F[B],_(R[H],O[B-H])))}return F}}),CS="ceil",dT=["typed","config","round","matrix","equalScalar","zeros","DenseMatrix"],HM=re(CS,["typed","config","round"],p=>{var{typed:m,config:b,round:_}=p;return m(CS,{number:function(C){return Di(C,_(C),b.relTol,b.absTol)?_(C):Math.ceil(C)},"number, number":function(C,A){if(Di(C,_(C,A),b.relTol,b.absTol))return _(C,A);var[k,R]="".concat(C,"e").split("e"),O=Math.ceil(Number("".concat(k,"e").concat(Number(R)+A)));return[k,R]="".concat(O,"e").split("e"),Number("".concat(k,"e").concat(Number(R)-A))}})}),hC=re(CS,dT,p=>{var{typed:m,config:b,round:_,matrix:y,equalScalar:C,zeros:A,DenseMatrix:k}=p,R=Bf({typed:m,equalScalar:C}),O=Od({typed:m,DenseMatrix:k}),F=Bp({typed:m}),B=HM({typed:m,config:b,round:_});return m("ceil",{number:B.signatures.number,"number,number":B.signatures["number,number"],Complex:function(G){return G.ceil()},"Complex, number":function(G,J){return G.ceil(J)},"Complex, BigNumber":function(G,J){return G.ceil(J.toNumber())},BigNumber:function(G){return Zf(G,_(G),b.relTol,b.absTol)?_(G):G.ceil()},"BigNumber, BigNumber":function(G,J){return Zf(G,_(G,J),b.relTol,b.absTol)?_(G,J):G.toDecimalPlaces(J.toNumber(),Se.ROUND_CEIL)},Fraction:function(G){return G.ceil()},"Fraction, number":function(G,J){return G.ceil(J)},"Fraction, BigNumber":function(G,J){return G.ceil(J.toNumber())},"Array | Matrix":m.referToSelf(H=>G=>ps(G,H,!0)),"Array, number | BigNumber":m.referToSelf(H=>(G,J)=>ps(G,te=>H(te,J),!0)),"SparseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>R(G,J,H,!1)),"DenseMatrix, number | BigNumber":m.referToSelf(H=>(G,J)=>F(G,J,H,!1)),"number | Complex | Fraction | BigNumber, Array":m.referToSelf(H=>(G,J)=>F(y(J),G,H,!0).valueOf()),"number | Complex | Fraction | BigNumber, Matrix":m.referToSelf(H=>(G,J)=>C(G,0)?A(J.size(),J.storage()):"dense"===J.storage()?F(J,G,H,!0):O(J,G,H,!0))})}),g_=S(7955),Eb="compareNatural",$h=re(Eb,["typed","compare"],p=>{var{typed:m,compare:b}=p,_=b.signatures["boolean,boolean"];return m(Eb,{"any, any":function y(R,O){var H,F=pi(R),B=pi(O);if(!("number"!==F&&"BigNumber"!==F&&"Fraction"!==F||"number"!==B&&"BigNumber"!==B&&"Fraction"!==B))return"0"!==(H=b(R,O)).toString()?H>0?1:-1:g_(F,B);var G=["Array","DenseMatrix","SparseMatrix"];if(G.includes(F)||G.includes(B))return 0!==(H=C(y,R,O))?H:g_(F,B);if(F!==B)return g_(F,B);if("Complex"===F)return function DS(p,m){return p.re>m.re?1:p.re<m.re?-1:p.im>m.im?1:p.im<m.im?-1:0}(R,O);if("Unit"===F)return R.equalBase(O)?y(R.value,O.value):A(y,R.formatUnits(),O.formatUnits());if("boolean"===F)return _(R,O);if("string"===F)return g_(R,O);if("Object"===F)return function k(R,O,F){var B=Object.keys(O),H=Object.keys(F);B.sort(g_),H.sort(g_);var G=A(R,B,H);if(0!==G)return G;for(var J=0;J<B.length;J++){var te=R(O[B[J]],F[H[J]]);if(0!==te)return te}return 0}(y,R,O);if("null"===F||"undefined"===F)return 0;throw new TypeError('Unsupported type of value "'+F+'"')}});function C(R,O,F){return It(O)&&It(F)?A(R,O.toJSON().values,F.toJSON().values):It(O)?C(R,O.toArray(),F):It(F)?C(R,O,F.toArray()):Wt(O)?C(R,O.toJSON().data,F):Wt(F)?C(R,O,F.toJSON().data):Array.isArray(O)?Array.isArray(F)?A(R,O,F):C(R,O,[F]):C(R,[O],F)}function A(R,O,F){for(var B=0,H=Math.min(O.length,F.length);B<H;B++){var G=R(O[B],F[B]);if(0!==G)return G}return O.length>F.length?1:O.length<F.length?-1:0}}),Tb="composition",wS=re(Tb,["typed","addScalar","combinations","isNegative","isPositive","isInteger","larger"],p=>{var{typed:m,addScalar:b,combinations:_,isPositive:y,isInteger:A,larger:k}=p;return m(Tb,{"number | BigNumber, number | BigNumber":function(O,F){if(!(A(O)&&y(O)&&A(F)&&y(F)))throw new TypeError("Positive integer value expected in function composition");if(k(F,O))throw new TypeError("k must be less than or equal to n in function composition");return _(b(O,-1),b(F,-1))}})}),v_=re("cross",["typed","matrix","subtract","multiply"],p=>{var{typed:m,matrix:b,subtract:_,multiply:y}=p;return m("cross",{"Matrix, Matrix":function(k,R){return b(C(k.toArray(),R.toArray()))},"Matrix, Array":function(k,R){return b(C(k.toArray(),R))},"Array, Matrix":function(k,R){return b(C(k,R.toArray()))},"Array, Array":C});function C(A,k){var R=Math.max(Bs(A).length,Bs(k).length);A=Mu(A),k=Mu(k);var O=Bs(A),F=Bs(k);if(1!==O.length||1!==F.length||3!==O[0]||3!==F[0])throw new RangeError("Vectors with length 3 expected (Size A = ["+O.join(", ")+"], B = ["+F.join(", ")+"])");var B=[_(y(A[1],k[2]),y(A[2],k[1])),_(y(A[2],k[0]),y(A[0],k[2])),_(y(A[0],k[1]),y(A[1],k[0]))];return R>1?[B]:B}}),vw=re("det",["typed","matrix","subtractScalar","multiply","divideScalar","isZero","unaryMinus"],p=>{var{typed:m,matrix:b,subtractScalar:_,multiply:y,divideScalar:C,isZero:A,unaryMinus:k}=p;return m("det",{any:function(F){return At(F)},"Array | Matrix":function(F){var B;switch((B=ut(F)?F.size():Array.isArray(F)?(F=b(F)).size():[]).length){case 0:return At(F);case 1:if(1===B[0])return At(F.valueOf()[0]);if(0===B[0])return 1;throw new RangeError("Matrix must be square (size: "+xs(B)+")");case 2:var H=B[0],G=B[1];if(H===G)return function R(O,F){if(1===F)return At(O[0][0]);if(2===F)return _(y(O[0][0],O[1][1]),y(O[1][0],O[0][1]));for(var H=!1,G=new Array(F).fill(0).map((Be,We)=>We),J=0;J<F;J++){var te=G[J];if(A(O[te][J])){var be=void 0;for(be=J+1;be<F;be++)if(!A(O[G[be]][J])){te=G[be],G[be]=G[J],G[J]=te,H=!H;break}if(be===F)return O[te][J]}for(var we=O[te][J],Le=0===J?1:O[G[J-1]][J-1],de=J+1;de<F;de++)for(var Te=G[de],De=J+1;De<F;De++)O[Te][De]=C(_(y(O[Te][De],we),y(O[Te][J],O[te][De])),Le)}var pe=O[G[F-1]][F-1];return H?k(pe):pe}(F.clone().valueOf(),H);if(0===G)return 1;throw new RangeError("Matrix must be square (size: "+xs(B)+")");default:throw new RangeError("Matrix must be two dimensional (size: "+xs(B)+")")}}})}),_w="dotMultiply",Mb=re(_w,["typed","matrix","equalScalar","multiplyScalar","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,multiplyScalar:y,concat:C}=p,A=gp({typed:m,equalScalar:_}),k=oS({typed:m,equalScalar:_}),R=Bf({typed:m,equalScalar:_}),O=$c({typed:m,matrix:b,concat:C});return m(_w,O({elop:y,SS:k,DS:A,Ss:R}))}),Ib=re("FibonacciHeap",["smaller","larger"],p=>{var{smaller:m,larger:b}=p,_=1/Math.log((1+Math.sqrt(5))/2);function y(){if(!(this instanceof y))throw new SyntaxError("Constructor must be called with the new operator");this._minimum=null,this._size=0}function A(F,B,H){B.left.right=B.right,B.right.left=B.left,H.degree--,H.child===B&&(H.child=B.right),0===H.degree&&(H.child=null),B.left=F,B.right=F.right,F.right=B,B.right.left=B,B.parent=null,B.mark=!1}function k(F,B){var H=B.parent;H&&(B.mark?(A(F,B,H),k(H)):B.mark=!0)}y.prototype.type="FibonacciHeap",y.prototype.isFibonacciHeap=!0,y.prototype.insert=function(F,B){var H={key:F,value:B,degree:0};if(this._minimum){var G=this._minimum;H.left=G,H.right=G.right,G.right=H,H.right.left=H,m(F,G.key)&&(this._minimum=H)}else H.left=H,H.right=H,this._minimum=H;return this._size++,H},y.prototype.size=function(){return this._size},y.prototype.clear=function(){this._minimum=null,this._size=0},y.prototype.isEmpty=function(){return 0===this._size},y.prototype.extractMinimum=function(){var F=this._minimum;if(null===F)return F;for(var B=this._minimum,H=F.degree,G=F.child;H>0;){var J=G.right;G.left.right=G.right,G.right.left=G.left,G.left=B,G.right=B.right,B.right=G,G.right.left=G,G.parent=null,G=J,H--}return F.left.right=F.right,F.right.left=F.left,B=F===F.right?null:function O(F,B){var be,H=Math.floor(Math.log(B)*_)+1,G=new Array(H),J=0,te=F;if(te)for(J++,te=te.right;te!==F;)J++,te=te.right;for(;J>0;){for(var we=te.degree,Le=te.right;be=G[we];){if(b(te.key,be.key)){var de=be;be=te,te=de}R(be,te),G[we]=null,we++}G[we]=te,te=Le,J--}F=null;for(var Te=0;Te<H;Te++)(be=G[Te])&&(F?(be.left.right=be.right,be.right.left=be.left,be.left=F,be.right=F.right,F.right=be,be.right.left=be,m(be.key,F.key)&&(F=be)):F=be);return F}(B=F.right,this._size),this._size--,this._minimum=B,F},y.prototype.remove=function(F){this._minimum=function C(F,B,H){B.key=H;var G=B.parent;return G&&m(B.key,G.key)&&(A(F,B,G),k(F,G)),m(B.key,F.key)&&(F=B),F}(this._minimum,F,-1),this.extractMinimum()};var R=function(B,H){B.left.right=B.right,B.right.left=B.left,B.parent=H,H.child?(B.left=H.child,B.right=H.child.right,H.child.right=B,B.right.left=B):(H.child=B,B.right=B,B.left=B),H.degree++,B.mark=!1};return y},{isClass:!0}),TS=["typed","Complex","matrix","ceil","floor","equalScalar","zeros","DenseMatrix"],gT=re("fix",["typed","ceil","floor"],p=>{var{typed:m,ceil:b,floor:_}=p;return m("fix",{number:function(C){return C>0?_(C):b(C)},"number, number":function(C,A){return C>0?_(C,A):b(C,A)}})}),Ab=re("fix",TS,p=>{var{typed:m,Complex:b,matrix:_,ceil:y,floor:C,equalScalar:A,zeros:k,DenseMatrix:R}=p,O=Od({typed:m,DenseMatrix:R}),F=Bp({typed:m}),B=gT({typed:m,ceil:y,floor:C});return m("fix",{number:B.signatures.number,"number, number | BigNumber":B.signatures["number,number"],Complex:function(G){return new b(G.re>0?Math.floor(G.re):Math.ceil(G.re),G.im>0?Math.floor(G.im):Math.ceil(G.im))},"Complex, number":function(G,J){return new b(G.re>0?C(G.re,J):y(G.re,J),G.im>0?C(G.im,J):y(G.im,J))},"Complex, BigNumber":function(G,J){var te=J.toNumber();return new b(G.re>0?C(G.re,te):y(G.re,te),G.im>0?C(G.im,te):y(G.im,te))},BigNumber:function(G){return G.isNegative()?y(G):C(G)},"BigNumber, number | BigNumber":function(G,J){return G.isNegative()?y(G,J):C(G,J)},Fraction:function(G){return G.s<0?G.ceil():G.floor()},"Fraction, number | BigNumber":function(G,J){return G.s<0?y(G,J):C(G,J)},"Array | Matrix":m.referToSelf(H=>G=>ps(G,H,!0)),"Array | Matrix, number | BigNumber":m.referToSelf(H=>(G,J)=>ps(G,te=>H(te,J),!0)),"number | Complex | Fraction | BigNumber, Array":m.referToSelf(H=>(G,J)=>F(_(J),G,H,!0).valueOf()),"number | Complex | Fraction | BigNumber, Matrix":m.referToSelf(H=>(G,J)=>A(G,0)?k(J.size(),J.storage()):"dense"===J.storage()?F(J,G,H,!0):O(J,G,H,!0))})}),By=re("index",["typed","Index"],p=>{var{typed:m,Index:b}=p;return m("index",{"...number | string | BigNumber | Range | Array | Matrix":function(y){var C=y.map(function(k){return en(k)?k.toNumber():dt(k)||ut(k)?k.map(function(R){return en(R)?R.toNumber():R}):k}),A=new b;return b.apply(A,C),A}})}),og=re("intersect",["typed","config","abs","add","addScalar","matrix","multiply","multiplyScalar","divideScalar","subtract","smaller","equalScalar","flatten","isZero","isNumeric"],p=>{var{typed:m,config:b,abs:_,add:y,addScalar:C,matrix:A,multiply:k,multiplyScalar:R,divideScalar:O,subtract:F,smaller:B,equalScalar:H,flatten:G,isZero:J,isNumeric:te}=p;return m("intersect",{"Array, Array, Array":be,"Array, Array, Array, Array":we,"Matrix, Matrix, Matrix":function(et,pt,$t){var Zt=be(et.valueOf(),pt.valueOf(),$t.valueOf());return null===Zt?null:A(Zt)},"Matrix, Matrix, Matrix, Matrix":function(et,pt,$t,Zt){var Kt=we(et.valueOf(),pt.valueOf(),$t.valueOf(),Zt.valueOf());return null===Kt?null:A(Kt)}});function be(ze,et,pt){if(ze=Le(ze),et=Le(et),pt=Le(pt),!Te(ze))throw new TypeError("Array with 3 numbers or BigNumbers expected for first argument");if(!Te(et))throw new TypeError("Array with 3 numbers or BigNumbers expected for second argument");if(!function De(ze){return 4===ze.length&&te(ze[0])&&te(ze[1])&&te(ze[2])&&te(ze[3])}(pt))throw new TypeError("Array with 4 numbers expected as third argument");return function ke(ze,et,pt,$t,Zt,Kt,lt,st,En,_t){var di=R(ze,lt),ki=R($t,lt),Xn=R(et,st),_n=R(Zt,st),Ni=R(pt,En),kr=R(Kt,En),Pi=F(F(F(_t,di),Xn),Ni),nr=F(F(F(C(C(ki,_n),kr),di),Xn),Ni),Sr=O(Pi,nr);return[C(ze,R(Sr,F($t,ze))),C(et,R(Sr,F(Zt,et))),C(pt,R(Sr,F(Kt,pt)))]}(ze[0],ze[1],ze[2],et[0],et[1],et[2],pt[0],pt[1],pt[2],pt[3])}function we(ze,et,pt,$t){if(ze=Le(ze),et=Le(et),pt=Le(pt),$t=Le($t),2===ze.length){if(!de(ze))throw new TypeError("Array with 2 numbers or BigNumbers expected for first argument");if(!de(et))throw new TypeError("Array with 2 numbers or BigNumbers expected for second argument");if(!de(pt))throw new TypeError("Array with 2 numbers or BigNumbers expected for third argument");if(!de($t))throw new TypeError("Array with 2 numbers or BigNumbers expected for fourth argument");return function pe(ze,et,pt,$t){var Zt=ze,Kt=pt,lt=F(Zt,et),st=F(Kt,$t),En=F(R(lt[0],st[1]),R(st[0],lt[1]));if(J(En)||B(_(En),b.relTol))return null;var _t=R(st[0],Zt[1]),di=R(st[1],Zt[0]),ki=R(st[0],Kt[1]),Xn=R(st[1],Kt[0]),_n=O(C(F(F(_t,di),ki),Xn),En);return y(k(lt,_n),Zt)}(ze,et,pt,$t)}if(3===ze.length){if(!Te(ze))throw new TypeError("Array with 3 numbers or BigNumbers expected for first argument");if(!Te(et))throw new TypeError("Array with 3 numbers or BigNumbers expected for second argument");if(!Te(pt))throw new TypeError("Array with 3 numbers or BigNumbers expected for third argument");if(!Te($t))throw new TypeError("Array with 3 numbers or BigNumbers expected for fourth argument");return function We(ze,et,pt,$t,Zt,Kt,lt,st,En,_t,di,ki){var Xn=Be(ze,lt,_t,lt,et,st,di,st,pt,En,ki,En),_n=Be(_t,lt,$t,ze,di,st,Zt,et,ki,En,Kt,pt),Ni=Be(ze,lt,$t,ze,et,st,Zt,et,pt,En,Kt,pt),kr=Be(_t,lt,_t,lt,di,st,di,st,ki,En,ki,En),Pi=Be($t,ze,$t,ze,Zt,et,Zt,et,Kt,pt,Kt,pt),nr=F(R(Xn,_n),R(Ni,kr)),Sr=F(R(Pi,kr),R(_n,_n));if(J(Sr))return null;var ir=O(nr,Sr),lr=O(C(Xn,R(ir,_n)),kr),wr=C(ze,R(ir,F($t,ze))),$r=C(et,R(ir,F(Zt,et))),Io=C(pt,R(ir,F(Kt,pt))),ms=C(lt,R(lr,F(_t,lt))),xn=C(st,R(lr,F(di,st))),$n=C(En,R(lr,F(ki,En)));return H(wr,ms)&&H($r,xn)&&H(Io,$n)?[wr,$r,Io]:null}(ze[0],ze[1],ze[2],et[0],et[1],et[2],pt[0],pt[1],pt[2],$t[0],$t[1],$t[2])}throw new TypeError("Arrays with two or thee dimensional points expected")}function Le(ze){return 1===ze.length?ze[0]:ze.length>1&&Array.isArray(ze[0])&&ze.every(et=>Array.isArray(et)&&1===et.length)?G(ze):ze}function de(ze){return 2===ze.length&&te(ze[0])&&te(ze[1])}function Te(ze){return 3===ze.length&&te(ze[0])&&te(ze[1])&&te(ze[2])}function Be(ze,et,pt,$t,Zt,Kt,lt,st,En,_t,di,ki){var Xn=R(F(ze,et),F(pt,$t)),_n=R(F(Zt,Kt),F(lt,st)),Ni=R(F(En,_t),F(di,ki));return C(C(Xn,_n),Ni)}}),Cw=re("invmod",["typed","config","BigNumber","xgcd","equal","smaller","mod","add","isInteger"],p=>{var{typed:m,BigNumber:_,xgcd:y,equal:C,smaller:A,mod:k,add:R,isInteger:O}=p;return m("invmod",{"number, number":F,"BigNumber, BigNumber":F});function F(B,H){if(!O(B)||!O(H))throw new Error("Parameters in function invmod must be integer numbers");if(B=k(B,H),C(H,0))throw new Error("Divisor must be non zero");var G=y(B,H);G=G.valueOf();var[J,te]=G;return C(J,_(1))?(te=k(te,H),A(te,_(0))&&(te=R(te,H)),te):NaN}}),Vy=re("lcm",["typed","matrix","equalScalar","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,concat:y}=p,C=gp({typed:m,equalScalar:_}),A=dh({typed:m,equalScalar:_}),k=Bf({typed:m,equalScalar:_}),R=$c({typed:m,matrix:b,concat:y}),O="number | BigNumber | Fraction | Matrix | Array",F={};return F["".concat(O,", ").concat(O,", ...").concat(O)]=m.referToSelf(H=>(G,J,te)=>{for(var be=H(G,J),we=0;we<te.length;we++)be=H(be,te[we]);return be}),m("lcm",{"number, number":Gr,"BigNumber, BigNumber":function B(H,G){if(!H.isInt()||!G.isInt())throw new Error("Parameters in function lcm must be integer numbers");if(H.isZero())return H;if(G.isZero())return G;for(var J=H.times(G);!G.isZero();){var te=G;G=H.mod(te),H=te}return J.div(H).abs()},"Fraction, Fraction":(H,G)=>H.lcm(G)},R({SS:A,DS:C,Ss:k}),F)}),jy=re("log1p",["typed","config","divideScalar","log","Complex"],p=>{var{typed:m,config:b,divideScalar:_,log:y,Complex:C}=p;return m("log1p",{number:function(R){return R>=-1||b.predictable?is(R):A(new C(R,0))},Complex:A,BigNumber:function(R){var O=R.plus(1);return!O.isNegative()||b.predictable?O.ln():A(new C(R.toNumber(),0))},"Array | Matrix":m.referToSelf(k=>R=>ps(R,k)),"any, any":m.referToSelf(k=>(R,O)=>_(k(R),y(O)))});function A(k){var R=k.re+1;return new C(Math.log(Math.sqrt(R*R+k.im*k.im)),Math.atan2(k.im,R))}}),Uy=re("max",["typed","config","numeric","larger"],p=>{var{typed:m,config:b,numeric:_,larger:y}=p;return m("max",{"Array | Matrix":A,"Array | Matrix, number | BigNumber":function(R,O){return eh(R,O.valueOf(),C)},"...":function(R){if(sd(R))throw new TypeError("Scalar values expected in function max");return A(R)}});function C(k,R){try{return y(k,R)?k:R}catch(O){throw tu(O,"max",R)}}function A(k){var R;if(Ss(k,function(O){try{isNaN(O)&&"number"==typeof O?R=NaN:(void 0===R||y(O,R))&&(R=O)}catch(F){throw tu(F,"max",O)}}),void 0===R)throw new Error("Cannot calculate max of an empty array");return"string"==typeof R&&(R=_(R,Fr(R,b))),R}}),gC="setCartesian",Fb=re(gC,["typed","size","subset","compareNatural","Index","DenseMatrix"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C,DenseMatrix:A}=p;return m(gC,{"Array | Matrix, Array | Matrix":function(R,O){var F=[];if(0!==_(b(R),new C(0))&&0!==_(b(O),new C(0))){var B=ns(Array.isArray(R)?R:R.toArray()).sort(y),H=ns(Array.isArray(O)?O:O.toArray()).sort(y);F=[];for(var G=0;G<B.length;G++)for(var J=0;J<H.length;J++)F.push([B[G],H[J]])}return Array.isArray(R)&&Array.isArray(O)?F:new A(F)}})}),IS="setDistinct",xw=re(IS,["typed","size","subset","compareNatural","Index","DenseMatrix"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C,DenseMatrix:A}=p;return m(IS,{"Array | Matrix":function(R){var O;if(0===_(b(R),new C(0)))O=[];else{var F=ns(Array.isArray(R)?R:R.toArray()).sort(y);(O=[]).push(F[0]);for(var B=1;B<F.length;B++)0!==y(F[B],F[B-1])&&O.push(F[B])}return Array.isArray(R)?O:new A(O)}})}),AS="setIsSubset",Wh=re(AS,["typed","size","subset","compareNatural","Index"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C}=p;return m(AS,{"Array | Matrix, Array | Matrix":function(k,R){if(0===_(b(k),new C(0)))return!0;if(0===_(b(R),new C(0)))return!1;for(var B,O=Md(ns(Array.isArray(k)?k:k.toArray()).sort(y)),F=Md(ns(Array.isArray(R)?R:R.toArray()).sort(y)),H=0;H<O.length;H++){B=!1;for(var G=0;G<F.length;G++)if(0===y(O[H].value,F[G].value)&&O[H].identifier===F[G].identifier){B=!0;break}if(!1===B)return!1}return!0}})}),Wp="setPowerset",sg=re(Wp,["typed","size","subset","compareNatural","Index"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C}=p;return m(Wp,{"Array | Matrix":function(O){if(0===_(b(O),new C(0)))return[];for(var F=ns(Array.isArray(O)?O:O.toArray()).sort(y),B=[],H=0;H.toString(2).length<=F.length;)B.push(A(F,H.toString(2).split("").reverse())),H++;return function k(R){for(var O=[],F=R.length-1;F>0;F--)for(var B=0;B<F;B++)R[B].length>R[B+1].length&&(O=R[B],R[B]=R[B+1],R[B+1]=O);return R}(B)}});function A(R,O){for(var F=[],B=0;B<O.length;B++)"1"===O[B]&&F.push(R[B]);return F}}),av="smallerEq",Ys=re(av,["typed","config","matrix","DenseMatrix","concat"],p=>{var{typed:m,config:b,matrix:_,DenseMatrix:y,concat:C}=p,A=Hd({typed:m}),k=Gg({typed:m,DenseMatrix:y}),R=Od({typed:m,DenseMatrix:y}),O=$c({typed:m,matrix:_,concat:C}),F=Nv({typed:m});return m(av,lv({typed:m,config:b}),{"boolean, boolean":(B,H)=>B<=H,"BigNumber, BigNumber":function(H,G){return H.lte(G)||Zf(H,G,b.relTol,b.absTol)},"bigint, bigint":(B,H)=>B<=H,"Fraction, Fraction":(B,H)=>1!==B.compare(H),"Complex, Complex":function(){throw new TypeError("No ordering relation is defined for complex numbers")}},F,O({SS:k,DS:A,Ss:R}))}),lv=re(av,["typed","config"],p=>{var{typed:m,config:b}=p;return m(av,{"number, number":function(y,C){return y<=C||Di(y,C,b.relTol,b.absTol)}})}),$f=re("sort",["typed","matrix","compare","compareNatural"],p=>{var{typed:m,matrix:b,compare:_,compareNatural:y}=p,C=_,A=(F,B)=>-_(F,B);return m("sort",{Array:function(B){return R(B),B.sort(C)},Matrix:function(B){return O(B),b(B.toArray().sort(C),B.storage())},"Array, function":function(B,H){return R(B),B.sort(H)},"Matrix, function":function(B,H){return O(B),b(B.toArray().sort(H),B.storage())},"Array, string":function(B,H){return R(B),B.sort(k(H))},"Matrix, string":function(B,H){return O(B),b(B.toArray().sort(k(H)),B.storage())}});function k(F){if("asc"===F)return C;if("desc"===F)return A;if("natural"===F)return y;throw new Error('String "asc", "desc", or "natural" expected')}function R(F){if(1!==Bs(F).length)throw new Error("One dimensional array expected")}function O(F){if(1!==F.size().length)throw new Error("One dimensional matrix expected")}}),ag="unequal",Rb=re(ag,["typed","config","equalScalar","matrix","DenseMatrix","concat"],p=>{var{typed:m,equalScalar:_,matrix:y,DenseMatrix:C,concat:A}=p,k=Hd({typed:m}),R=Gg({typed:m,DenseMatrix:C}),O=Od({typed:m,DenseMatrix:C}),F=$c({typed:m,matrix:y,concat:A});return m(ag,Sw({typed:m,equalScalar:_}),F({elop:function B(H,G){return!_(H,G)},SS:R,DS:k,Ss:O}))}),Sw=re(ag,["typed","equalScalar"],p=>{var{typed:m,equalScalar:b}=p;return m(ag,{"any, any":function(y,C){return null===y?null!==C:null===C?null!==y:void 0===y?void 0!==C:void 0===C?void 0!==y:!b(y,C)}})}),Wf=re("and",["typed","matrix","equalScalar","zeros","not","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,not:C,concat:A}=p,k=gp({typed:m,equalScalar:_}),R=dh({typed:m,equalScalar:_}),O=Bf({typed:m,equalScalar:_}),F=Bp({typed:m}),B=$c({typed:m,matrix:b,concat:A});return m("and",{"number, number":iy,"Complex, Complex":function(G,J){return!(0===G.re&&0===G.im||0===J.re&&0===J.im)},"BigNumber, BigNumber":function(G,J){return!(G.isZero()||J.isZero()||G.isNaN()||J.isNaN())},"bigint, bigint":iy,"Unit, Unit":m.referToSelf(H=>(G,J)=>H(G.value||0,J.value||0)),"SparseMatrix, any":m.referToSelf(H=>(G,J)=>C(J)?y(G.size(),G.storage()):O(G,J,H,!1)),"DenseMatrix, any":m.referToSelf(H=>(G,J)=>C(J)?y(G.size(),G.storage()):F(G,J,H,!1)),"any, SparseMatrix":m.referToSelf(H=>(G,J)=>C(G)?y(G.size(),G.storage()):O(J,G,H,!0)),"any, DenseMatrix":m.referToSelf(H=>(G,J)=>C(G)?y(G.size(),G.storage()):F(J,G,H,!0)),"Array, any":m.referToSelf(H=>(G,J)=>H(b(G),J).valueOf()),"any, Array":m.referToSelf(H=>(G,J)=>H(G,b(J)).valueOf())},B({SS:R,DS:k}))}),nu=re("range",["typed","config","?matrix","?bignumber","smaller","smallerEq","larger","largerEq","add","isPositive"],p=>{var{typed:m,config:b,matrix:_,bignumber:y,smaller:C,smallerEq:A,larger:k,largerEq:R,add:O,isPositive:F}=p;return m("range",{string:H,"string, boolean":H,"number, number":function(be,we){return B(G(be,we,1,!1))},"number, number, number":function(be,we,Le){return B(G(be,we,Le,!1))},"number, number, boolean":function(be,we,Le){return B(G(be,we,1,Le))},"number, number, number, boolean":function(be,we,Le,de){return B(G(be,we,Le,de))},"BigNumber, BigNumber":function(be,we){return B(G(be,we,new(0,be.constructor)(1),!1))},"BigNumber, BigNumber, BigNumber":function(be,we,Le){return B(G(be,we,Le,!1))},"BigNumber, BigNumber, boolean":function(be,we,Le){return B(G(be,we,new(0,be.constructor)(1),Le))},"BigNumber, BigNumber, BigNumber, boolean":function(be,we,Le,de){return B(G(be,we,Le,de))},"Unit, Unit, Unit":function(be,we,Le){return B(G(be,we,Le,!1))},"Unit, Unit, Unit, boolean":function(be,we,Le,de){return B(G(be,we,Le,de))}});function B(te){return"Matrix"===b.matrix?_?_(te):hp():te}function H(te,be){var we=function J(te){var we=te.split(":").map(function(de){return Number(de)});if(we.some(function(de){return isNaN(de)}))return null;switch(we.length){case 2:return{start:we[0],end:we[1],step:1};case 3:return{start:we[0],end:we[2],step:we[1]};default:return null}}(te);if(!we)throw new SyntaxError('String "'+te+'" is no valid range');return"BigNumber"===b.number?(void 0===y&&dm(),B(G(y(we.start),y(we.end),y(we.step)))):B(G(we.start,we.end,we.step,be))}function G(te,be,we,Le){for(var de=[],Te=F(we)?Le?A:C:Le?R:k,De=te;Te(De,be);)de.push(De),De=O(De,we);return de}}),ym=re("row",["typed","Index","matrix","range"],p=>{var{typed:m,Index:b,matrix:_,range:y}=p;return m("row",{"Matrix, number":C,"Array, number":function(k,R){return C(_(At(k)),R).valueOf()}});function C(A,k){if(2!==A.size().length)throw new Error("Only two dimensional matrix is supported");zl(k,A.size()[0]);var R=y(0,A.size()[1]),O=new b(k,R),F=A.subset(O);return ut(F)?F:_([[F]])}}),cu="setDifference",Hh=re(cu,["typed","size","subset","compareNatural","Index","DenseMatrix"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C,DenseMatrix:A}=p;return m(cu,{"Array | Matrix, Array | Matrix":function(R,O){var F;if(0===_(b(R),new C(0)))F=[];else{if(0===_(b(O),new C(0)))return ns(R.toArray());var B=Md(ns(Array.isArray(R)?R:R.toArray()).sort(y)),H=Md(ns(Array.isArray(O)?O:O.toArray()).sort(y));F=[];for(var G,J=0;J<B.length;J++){G=!1;for(var te=0;te<H.length;te++)if(0===y(B[J].value,H[te].value)&&B[J].identifier===H[te].identifier){G=!0;break}G||F.push(B[J])}}return Array.isArray(R)&&Array.isArray(O)?Of(F):new A(Of(F))}})}),Ew="setMultiplicity",cd=re(Ew,["typed","size","subset","compareNatural","Index"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C}=p;return m(Ew,{"number | BigNumber | Fraction | Complex, Array | Matrix":function(k,R){if(0===_(b(R),new C(0)))return 0;for(var O=ns(Array.isArray(R)?R:R.toArray()),F=0,B=0;B<O.length;B++)0===y(O[B],k)&&F++;return F}})}),Hy="setSymDifference",hh=re(Hy,["typed","size","concat","subset","setDifference","Index"],p=>{var{typed:m,size:b,concat:_,subset:y,setDifference:C,Index:A}=p;return m(Hy,{"Array | Matrix, Array | Matrix":function(R,O){if(0===y(b(R),new A(0)))return ns(O);if(0===y(b(O),new A(0)))return ns(R);var F=ns(R),B=ns(O);return _(C(F,B),C(B,F))}})}),C_=re("Spa",["addScalar","equalScalar","FibonacciHeap"],p=>{var{addScalar:m,equalScalar:b,FibonacciHeap:_}=p;function y(){if(!(this instanceof y))throw new SyntaxError("Constructor must be called with the new operator");this._values=[],this._heap=new _}return y.prototype.type="Spa",y.prototype.isSpa=!0,y.prototype.set=function(C,A){if(this._values[C])this._values[C].value=A;else{var k=this._heap.insert(C,A);this._values[C]=k}},y.prototype.get=function(C){var A=this._values[C];return A?A.value:0},y.prototype.accumulate=function(C,A){var k=this._values[C];k?k.value=m(k.value,A):(k=this._heap.insert(C,A),this._values[C]=k)},y.prototype.forEach=function(C,A,k){var R=this._heap,O=this._values,F=[],B=R.extractMinimum();for(B&&F.push(B);B&&B.key<=A;)B.key>=C&&(b(B.value,0)||k(B.key,B.value,this)),(B=R.extractMinimum())&&F.push(B);for(var H=0;H<F.length;H++){var G=F[H];O[(B=R.insert(G.key,G.value)).key]=B}},y.prototype.swap=function(C,A){var k=this._values[C],R=this._values[A];if(!k&&R)k=this._heap.insert(C,R.value),this._heap.remove(R),this._values[C]=k,this._values[A]=void 0;else if(k&&!R)R=this._heap.insert(A,k.value),this._heap.remove(k),this._values[A]=R,this._values[C]=void 0;else if(k&&R){var O=k.value;k.value=R.value,R.value=O}},y},{isClass:!0}),zy=re("column",["typed","Index","matrix","range"],p=>{var{typed:m,Index:b,matrix:_,range:y}=p;return m("column",{"Matrix, number":C,"Array, number":function(k,R){return C(_(At(k)),R).valueOf()}});function C(A,k){if(2!==A.size().length)throw new Error("Only two dimensional matrix is supported");zl(k,A.size()[1]);var R=y(0,A.size()[0]),O=new b(R,k),F=A.subset(O);return ut(F)?F:_([[F]])}}),Ju=re("inv",["typed","matrix","divideScalar","addScalar","multiply","unaryMinus","det","identity","abs"],p=>{var{typed:m,matrix:b,divideScalar:_,addScalar:y,multiply:C,unaryMinus:A,det:k,identity:R,abs:O}=p;return m("inv",{"Array | Matrix":function(H){var G=ut(H)?H.size():Bs(H);switch(G.length){case 1:if(1===G[0])return ut(H)?b([_(1,H.valueOf()[0])]):[_(1,H[0])];throw new RangeError("Matrix must be square (size: "+xs(G)+")");case 2:var J=G[0],te=G[1];if(J===te)return ut(H)?b(F(H.valueOf(),J,te),H.storage()):F(H,J,te);throw new RangeError("Matrix must be square (size: "+xs(G)+")");default:throw new RangeError("Matrix must be two dimensional (size: "+xs(G)+")")}},any:function(H){return _(1,H)}});function F(B,H,G){var J,te,be,we,Le;if(1===H){if(0===(we=B[0][0]))throw Error("Cannot calculate inverse, determinant is zero");return[[_(1,we)]]}if(2===H){var de=k(B);if(0===de)throw Error("Cannot calculate inverse, determinant is zero");return[[_(B[1][1],de),_(A(B[0][1]),de)],[_(A(B[1][0]),de),_(B[0][0],de)]]}var Te=B.concat();for(J=0;J<H;J++)Te[J]=Te[J].concat();for(var De=R(H).valueOf(),pe=0;pe<G;pe++){var Be=O(Te[pe][pe]),We=pe;for(J=pe+1;J<H;)O(Te[J][pe])>Be&&(Be=O(Te[J][pe]),We=J),J++;if(0===Be)throw Error("Cannot calculate inverse, determinant is zero");(J=We)!==pe&&(Le=Te[pe],Te[pe]=Te[J],Te[J]=Le,Le=De[pe],De[pe]=De[J],De[J]=Le);var ke=Te[pe],ze=De[pe];for(J=0;J<H;J++){var et=Te[J],pt=De[J];if(J!==pe){if(0!==et[pe]){for(be=_(A(et[pe]),ke[pe]),te=pe;te<G;te++)et[te]=y(et[te],C(be,ke[te]));for(te=0;te<G;te++)pt[te]=y(pt[te],C(be,ze[te]))}}else{for(be=ke[pe],te=pe;te<G;te++)et[te]=_(et[te],be);for(te=0;te<G;te++)pt[te]=_(pt[te],be)}}}return De}}),Gy=re("lup",["typed","matrix","abs","addScalar","divideScalar","multiplyScalar","subtractScalar","larger","equalScalar","unaryMinus","DenseMatrix","SparseMatrix","Spa"],p=>{var{typed:m,matrix:b,abs:_,addScalar:y,divideScalar:C,multiplyScalar:A,subtractScalar:k,larger:R,equalScalar:O,unaryMinus:F,DenseMatrix:B,SparseMatrix:H,Spa:G}=p;return m("lup",{DenseMatrix:function(we){return J(we)},SparseMatrix:function(we){return function te(be){var Kt,lt,st,we=be._size[0],Le=be._size[1],de=Math.min(we,Le),Te=be._values,De=be._index,pe=be._ptr,Be=[],We=[],ke=[],ze=[we,de],et=[],pt=[],$t=[],Zt=[de,Le],En=[],_t=[];for(Kt=0;Kt<we;Kt++)En[Kt]=Kt,_t[Kt]=Kt;var ki=function(){var _n=new G;lt<we&&(ke.push(Be.length),Be.push(1),We.push(lt)),$t.push(et.length);var kr=pe[lt+1];for(st=pe[lt];st<kr;st++)_n.set(En[Kt=De[st]],Te[st]);lt>0&&_n.forEach(0,lt-1,function(ir,lr){H._forEachRow(ir,Be,We,ke,function(wr,$r){wr>ir&&_n.accumulate(wr,F(A($r,lr)))})});var Pi=lt,nr=_n.get(lt),Sr=_(nr);_n.forEach(lt+1,we-1,function(ir,lr){var wr=_(lr);R(wr,Sr)&&(Pi=ir,Sr=wr,nr=lr)}),lt!==Pi&&(H._swapRows(lt,Pi,ze[1],Be,We,ke),H._swapRows(lt,Pi,Zt[1],et,pt,$t),_n.swap(lt,Pi),function(_n,Ni){var kr=_t[_n],Pi=_t[Ni];En[kr]=Ni,En[Pi]=_n,_t[_n]=Pi,_t[Ni]=kr}(lt,Pi)),_n.forEach(0,we-1,function(ir,lr){ir<=lt?(et.push(lr),pt.push(ir)):(lr=C(lr,nr),O(lr,0)||(Be.push(lr),We.push(ir)))})};for(lt=0;lt<Le;lt++)ki();return $t.push(et.length),ke.push(Be.length),{L:new H({values:Be,index:We,ptr:ke,size:ze}),U:new H({values:et,index:pt,ptr:$t,size:Zt}),p:En,toString:function(){return"L: "+this.L.toString()+"\nU: "+this.U.toString()+"\nP: "+this.p}}}(we)},Array:function(we){var de=J(b(we));return{L:de.L.valueOf(),U:de.U.valueOf(),p:de.p}}});function J(be){var ke,ze,et,we=be._size[0],Le=be._size[1],de=Math.min(we,Le),Te=At(be._data),De=[],pe=[we,de],Be=[],We=[de,Le],pt=[];for(ke=0;ke<we;ke++)pt[ke]=ke;for(ze=0;ze<Le;ze++){if(ze>0)for(ke=0;ke<we;ke++){var $t=Math.min(ke,ze),Zt=0;for(et=0;et<$t;et++)Zt=y(Zt,A(Te[ke][et],Te[et][ze]));Te[ke][ze]=k(Te[ke][ze],Zt)}var Kt=ze,lt=0,st=0;for(ke=ze;ke<we;ke++){var En=Te[ke][ze],_t=_(En);R(_t,lt)&&(Kt=ke,lt=_t,st=En)}if(ze!==Kt&&(pt[ze]=[pt[Kt],pt[Kt]=pt[ze]][0],B._swapRows(ze,Kt,Te)),ze<we)for(ke=ze+1;ke<we;ke++)O(Te[ke][ze],0)||(Te[ke][ze]=C(Te[ke][ze],st))}for(ze=0;ze<Le;ze++)for(ke=0;ke<we;ke++)0===ze&&(ke<Le&&(Be[ke]=[]),De[ke]=[]),ke<ze?(ke<Le&&(Be[ke][ze]=Te[ke][ze]),ze<we&&(De[ke][ze]=0)):ke!==ze?(ke<Le&&(Be[ke][ze]=0),ze<we&&(De[ke][ze]=Te[ke][ze])):(ke<Le&&(Be[ke][ze]=Te[ke][ze]),ze<we&&(De[ke][ze]=1));var ki=new B({data:De,size:pe}),Xn=new B({data:Be,size:We}),_n=[];for(ke=0,de=pt.length;ke<de;ke++)_n[pt[ke]]=ke;return{L:ki,U:Xn,p:_n,toString:function(){return"L: "+this.L.toString()+"\nU: "+this.U.toString()+"\nP: "+this.p}}}}),Jl=re("pinv",["typed","matrix","inv","deepEqual","equal","dotDivide","dot","ctranspose","divideScalar","multiply","add","Complex"],p=>{var{typed:m,matrix:b,inv:_,deepEqual:y,equal:C,dotDivide:A,dot:k,ctranspose:R,divideScalar:O,multiply:F,add:B,Complex:H}=p;return m("pinv",{"Array | Matrix":function(de){var Te=ut(de)?de.size():Bs(de);switch(Te.length){case 1:return we(de)?R(de):1===Te[0]?_(de):A(R(de),k(de,de));case 2:if(we(de))return R(de);var De=Te[0],pe=Te[1];if(De===pe)try{return _(de)}catch(Be){if(!(Be instanceof Error&&Be.message.match(/Cannot calculate inverse, determinant is zero/)))throw Be}return ut(de)?b(G(de.valueOf(),De,pe),de.storage()):G(de,De,pe);default:throw new RangeError("Matrix must be two dimensional (size: "+xs(Te)+")")}},any:function(de){return C(de,0)?At(de):O(1,de)}});function G(Le,de,Te){var{C:De,F:pe}=function te(Le,de,Te){var De=function J(Le,de,Te){for(var De=At(Le),pe=0,Be=0;Be<de;Be++){if(Te<=pe)return De;for(var We=Be;be(De[We][pe]);)if(de===++We&&(We=Be,Te===++pe))return De;[De[We],De[Be]]=[De[Be],De[We]];for(var ke=De[Be][pe],ze=0;ze<Te;ze++)De[Be][ze]=A(De[Be][ze],ke);for(var et=0;et<de;et++)if(et!==Be){ke=De[et][pe];for(var pt=0;pt<Te;pt++)De[et][pt]=B(De[et][pt],F(-1,F(ke,De[Be][pt])))}pe++}return De}(Le,de,Te),pe=Le.map((We,ke)=>We.filter((ze,et)=>et<de&&!be(k(De[et],De[et]))));return{C:pe,F:De.filter((We,ke)=>!be(k(De[ke],De[ke])))}}(Le,de,Te),Be=F(_(F(R(De),De)),R(De)),We=F(R(pe),_(F(pe,R(pe))));return F(We,Be)}function be(Le){return C(B(Le,H(1,1)),B(0,H(1,1)))}function we(Le){return y(B(Le,H(1,1)),B(F(Le,0),H(1,1)))}}),zh=re("pow",["typed","config","identity","multiply","matrix","inv","fraction","number","Complex"],p=>{var{typed:m,config:b,identity:_,multiply:y,matrix:C,inv:A,number:k,fraction:R,Complex:O}=p;return m("pow",{"number, number":F,"Complex, Complex":function(J,te){return J.pow(te)},"BigNumber, BigNumber":function(J,te){return te.isInteger()||J>=0||b.predictable?J.pow(te):new O(J.toNumber(),0).pow(te.toNumber(),0)},"bigint, bigint":(G,J)=>G**J,"Fraction, Fraction":function(J,te){var be=J.pow(te);if(null!=be)return be;if(b.predictable)throw new Error("Result of pow is non-rational and cannot be expressed as a fraction");return F(J.valueOf(),te.valueOf())},"Array, number":B,"Array, BigNumber":function(J,te){return B(J,te.toNumber())},"Matrix, number":H,"Matrix, BigNumber":function(J,te){return H(J,te.toNumber())},"Unit, number | BigNumber":function(J,te){return J.pow(te)}});function F(G,J){if(b.predictable&&!ai(J)&&G<0)try{var te=R(J),be=k(te);if((J===be||Math.abs((J-be)/J)<1e-14)&&te.d%2==1)return(te.n%2==0?1:-1)*Math.pow(-G,J)}catch{}return b.predictable&&(G<-1&&J===1/0||G>-1&&G<0&&J===-1/0)?NaN:ai(J)||G>=0||b.predictable?ih(G,J):G*G<1&&J===1/0||G*G>1&&J===-1/0?0:new O(G,0).pow(J,0)}function B(G,J){if(!ai(J))throw new TypeError("For A^b, b must be an integer (value is "+J+")");var te=Bs(G);if(2!==te.length)throw new Error("For A^b, A must be 2 dimensional (A has "+te.length+" dimensions)");if(te[0]!==te[1])throw new Error("For A^b, A must be square (size is "+te[0]+"x"+te[1]+")");if(J<0)try{return B(A(G),-J)}catch(Le){throw"Cannot calculate inverse, determinant is zero"===Le.message?new TypeError("For A^b, when A is not invertible, b must be a positive integer (value is "+J+")"):Le}for(var be=_(te[0]).valueOf(),we=G;J>=1;)!(1&~J)&&(be=y(we,be)),J>>=1,we=y(we,we);return be}function H(G,J){return C(B(G.valueOf(),J))}}),cv="setIntersect",w_=re(cv,["typed","size","subset","compareNatural","Index","DenseMatrix"],p=>{var{typed:m,size:b,subset:_,compareNatural:y,Index:C,DenseMatrix:A}=p;return m(cv,{"Array | Matrix, Array | Matrix":function(R,O){var F;if(0===_(b(R),new C(0))||0===_(b(O),new C(0)))F=[];else{var B=Md(ns(Array.isArray(R)?R:R.toArray()).sort(y)),H=Md(ns(Array.isArray(O)?O:O.toArray()).sort(y));F=[];for(var G=0;G<B.length;G++)for(var J=0;J<H.length;J++)if(0===y(B[G].value,H[J].value)&&B[G].identifier===H[J].identifier){F.push(B[G]);break}}return Array.isArray(R)&&Array.isArray(O)?Of(F):new A(Of(F))}})}),dg="setUnion",fg=re(dg,["typed","size","concat","subset","setIntersect","setSymDifference","Index"],p=>{var{typed:m,size:b,concat:_,subset:y,setIntersect:C,setSymDifference:A,Index:k}=p;return m(dg,{"Array | Matrix, Array | Matrix":function(O,F){if(0===y(b(O),new k(0)))return ns(F);if(0===y(b(F),new k(0)))return ns(O);var B=ns(O),H=ns(F);return _(A(B,H),C(B,H))}})}),pg=re("sqrtm",["typed","abs","add","multiply","map","sqrt","subtract","inv","size","max","identity"],p=>{var{typed:m,abs:b,add:_,multiply:y,map:C,sqrt:A,subtract:k,inv:R,size:O,max:F,identity:B}=p,G=1e-6;return m("sqrtm",{"Array | Matrix":function(be){var we=ut(be)?be.size():Bs(be);switch(we.length){case 1:if(1===we[0])return C(be,A);throw new RangeError("Matrix must be square (size: "+xs(we)+")");case 2:if(we[0]===we[1])return function J(te){var be,we=0,Le=te,de=B(O(te));do{var Te=Le;if(Le=y(.5,_(Te,R(de))),de=y(.5,_(de,R(Te))),(be=F(b(k(Le,Te))))>G&&++we>1e3)throw new Error("computing square root of matrix: iterative method could not converge")}while(be>G);return Le}(be);throw new RangeError("Matrix must be square (size: "+xs(we)+")");default:throw new RangeError("Matrix must be at most two dimensional (size: "+xs(we)+")")}}})});function Gh(p){return(Gh="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(m){return typeof m}:function(m){return m&&"function"==typeof Symbol&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m})(p)}function ud(p,m,b){return(m=function NS(p){var m=function CC(p,m){if("object"!=Gh(p)||!p)return p;var b=p[Symbol.toPrimitive];if(void 0!==b){var _=b.call(p,m||"default");if("object"!=Gh(_))return _;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===m?String:Number)(p)}(p,"string");return"symbol"==Gh(m)?m:m+""}(m))in p?Object.defineProperty(p,m,{value:b,enumerable:!0,configurable:!0,writable:!0}):p[m]=b,p}function x_(p,m){var b=Object.keys(p);if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(p);m&&(_=_.filter(function(y){return Object.getOwnPropertyDescriptor(p,y).enumerable})),b.push.apply(b,_)}return b}function hg(p){for(var m=1;m<arguments.length;m++){var b=null!=arguments[m]?arguments[m]:{};m%2?x_(Object(b),!0).forEach(function(_){ud(p,_,b[_])}):Object.getOwnPropertyDescriptors?Object.defineProperties(p,Object.getOwnPropertyDescriptors(b)):x_(Object(b)).forEach(function(_){Object.defineProperty(p,_,Object.getOwnPropertyDescriptor(b,_))})}return p}var cf=re("Unit",["?on","config","addScalar","subtractScalar","multiplyScalar","divideScalar","pow","abs","fix","round","equal","isNumeric","format","number","Complex","BigNumber","Fraction"],p=>{var Te,De,pe,{on:m,config:b,addScalar:_,subtractScalar:y,multiplyScalar:C,divideScalar:A,pow:k,abs:R,fix:O,round:F,equal:B,isNumeric:H,format:G,number:J,Complex:te,BigNumber:be,Fraction:we}=p,Le=J;function de(xn,$n){if(!(this instanceof de))throw new Error("Constructor must be called with the new operator");if(null!=xn&&!H(xn)&&!un(xn))throw new TypeError("First parameter in Unit constructor must be number, BigNumber, Fraction, Complex, or undefined");if(this.fixPrefix=!1,this.skipAutomaticSimplification=!0,void 0===$n)this.units=[],this.dimensions=En.map(Fn=>0);else if("string"==typeof $n){var Zi=de.parse($n);this.units=Zi.units,this.dimensions=Zi.dimensions}else{if(!Pt($n)||null!==$n.value)throw new TypeError("Second parameter in Unit constructor must be a string or valueless Unit");this.fixPrefix=$n.fixPrefix,this.skipAutomaticSimplification=$n.skipAutomaticSimplification,this.dimensions=$n.dimensions.slice(0),this.units=$n.units.map(Fn=>e({},Fn))}this.value=this._normalize(xn)}function Be(){for(;" "===pe||"\t"===pe;)ze()}function ke(xn){return xn>="0"&&xn<="9"}function ze(){De++,pe=Te.charAt(De)}function et(xn){pe=Te.charAt(De=xn)}function pt(){var xn="",$n=De;if("+"===pe?ze():"-"===pe&&(xn+=pe,ze()),!function We(xn){return xn>="0"&&xn<="9"||"."===xn}(pe))return et($n),null;if("."===pe){if(xn+=pe,ze(),!ke(pe))return et($n),null}else{for(;ke(pe);)xn+=pe,ze();"."===pe&&(xn+=pe,ze())}for(;ke(pe);)xn+=pe,ze();if("E"===pe||"e"===pe){var Zi="",Fn=De;if(Zi+=pe,ze(),("+"===pe||"-"===pe)&&(Zi+=pe,ze()),!ke(pe))return et(Fn),xn;for(xn+=Zi;ke(pe);)xn+=pe,ze()}return xn}function $t(){for(var xn="";ke(pe)||de.isValidAlpha(pe);)xn+=pe,ze();var $n=xn.charAt(0);return de.isValidAlpha($n)?xn:null}function Zt(xn){return pe===xn?(ze(),xn):null}Object.defineProperty(de,"name",{value:"Unit"}),de.prototype.constructor=de,de.prototype.type="Unit",de.prototype.isUnit=!0,de.parse=function(xn,$n){if($n=$n||{},De=-1,pe="","string"!=typeof(Te=xn))throw new TypeError("Invalid argument in Unit.parse, string expected");var Zi=new de;Zi.units=[];var Fn=1,ti=!1;ze(),Be();var Mi=pt(),Pr=null;if(Mi){if("BigNumber"===b.number)Pr=new be(Mi);else if("Fraction"===b.number)try{Pr=new we(Mi)}catch{Pr=parseFloat(Mi)}else Pr=parseFloat(Mi);Be(),Zt("*")?(Fn=1,ti=!0):Zt("/")&&(Fn=-1,ti=!0)}for(var Br=[],Go=1;;){for(Be();"("===pe;)Br.push(Fn),Go*=Fn,Fn=1,ze(),Be();var Zr;if(!pe)break;var rl=pe;if(null===(Zr=$t()))throw new SyntaxError('Unexpected "'+rl+'" in "'+Te+'" at index '+De.toString());var Nl=Kt(Zr);if(null===Nl)throw new SyntaxError('Unit "'+Zr+'" not found.');var Ru=Fn*Go;if(Be(),Zt("^")){Be();var Kd=pt();if(null===Kd)throw new SyntaxError('In "'+xn+'", "^" must be followed by a floating-point number');Ru*=Kd}Zi.units.push({unit:Nl.unit,prefix:Nl.prefix,power:Ru});for(var Mf=0;Mf<En.length;Mf++)Zi.dimensions[Mf]+=(Nl.unit.dimensions[Mf]||0)*Ru;for(Be();")"===pe;){if(0===Br.length)throw new SyntaxError('Unmatched ")" in "'+Te+'" at index '+De.toString());Go/=Br.pop(),ze(),Be()}ti=!1,Zt("*")?(Fn=1,ti=!0):Zt("/")?(Fn=-1,ti=!0):Fn=1,Nl.unit.base&&(Pi.auto[Nl.unit.base.key]={unit:Nl.unit,prefix:Nl.prefix})}if(Be(),pe)throw new SyntaxError('Could not parse: "'+xn+'"');if(ti)throw new SyntaxError('Trailing characters: "'+xn+'"');if(0!==Br.length)throw new SyntaxError('Unmatched "(" in "'+Te+'"');if(0===Zi.units.length&&!$n.allowNoUnits)throw new SyntaxError('"'+xn+'" contains no units');return Zi.value=void 0!==Pr?Zi._normalize(Pr):null,Zi},de.prototype.clone=function(){var xn=new de;xn.fixPrefix=this.fixPrefix,xn.skipAutomaticSimplification=this.skipAutomaticSimplification,xn.value=At(this.value),xn.dimensions=this.dimensions.slice(0),xn.units=[];for(var $n=0;$n<this.units.length;$n++)for(var Zi in xn.units[$n]={},this.units[$n])Jt(this.units[$n],Zi)&&(xn.units[$n][Zi]=this.units[$n][Zi]);return xn},de.prototype.valueType=function(){return pi(this.value)},de.prototype._isDerived=function(){return 0!==this.units.length&&(this.units.length>1||Math.abs(this.units[0].power-1)>1e-15)},de.prototype._normalize=function(xn){if(null==xn||0===this.units.length)return xn;for(var $n=xn,Zi=de._getNumberConverter(pi(xn)),Fn=0;Fn<this.units.length;Fn++){var ti=Zi(this.units[Fn].unit.value),Mi=Zi(this.units[Fn].prefix.value),Pr=Zi(this.units[Fn].power);$n=C($n,k(C(ti,Mi),Pr))}return $n},de.prototype._denormalize=function(xn,$n){if(null==xn||0===this.units.length)return xn;for(var Zi=xn,Fn=de._getNumberConverter(pi(xn)),ti=0;ti<this.units.length;ti++){var Mi=Fn(this.units[ti].unit.value),Pr=Fn(this.units[ti].prefix.value),Br=Fn(this.units[ti].power);Zi=A(Zi,k(C(Mi,Pr),Br))}return Zi};var Kt=_c(xn=>{if(Jt(_n,xn)){var $n=_n[xn];return{unit:$n,prefix:$n.prefixes[""]}}for(var Fn in _n)if(Jt(_n,Fn)&&ja(xn,Fn)){var ti=_n[Fn],Pr=xn.substring(0,xn.length-Fn.length),Br=Jt(ti.prefixes,Pr)?ti.prefixes[Pr]:void 0;if(void 0!==Br)return{unit:ti,prefix:Br}}return null},{hasher:xn=>xn[0],limit:100});function lt(xn){return xn.equalBase(_t.NONE)&&null!==xn.value&&!b.predictable?xn.value:xn}de.isValuelessUnit=function(xn){return null!==Kt(xn)},de.prototype.hasBase=function(xn){if("string"==typeof xn&&(xn=_t[xn]),!xn)return!1;for(var $n=0;$n<En.length;$n++)if(Math.abs((this.dimensions[$n]||0)-(xn.dimensions[$n]||0))>1e-12)return!1;return!0},de.prototype.equalBase=function(xn){for(var $n=0;$n<En.length;$n++)if(Math.abs((this.dimensions[$n]||0)-(xn.dimensions[$n]||0))>1e-12)return!1;return!0},de.prototype.equals=function(xn){return this.equalBase(xn)&&B(this.value,xn.value)},de.prototype.multiply=function(xn){for(var $n=this.clone(),Zi=Pt(xn)?xn:new de(xn),Fn=0;Fn<En.length;Fn++)$n.dimensions[Fn]=(this.dimensions[Fn]||0)+(Zi.dimensions[Fn]||0);for(var ti=0;ti<Zi.units.length;ti++){var Mi=hg({},Zi.units[ti]);$n.units.push(Mi)}if(null!==this.value||null!==Zi.value){var Pr=null===this.value?this._normalize(1):this.value,Br=null===Zi.value?Zi._normalize(1):Zi.value;$n.value=C(Pr,Br)}else $n.value=null;return Pt(xn)&&($n.skipAutomaticSimplification=!1),lt($n)},de.prototype.divideInto=function(xn){return new de(xn).divide(this)},de.prototype.divide=function(xn){for(var $n=this.clone(),Zi=Pt(xn)?xn:new de(xn),Fn=0;Fn<En.length;Fn++)$n.dimensions[Fn]=(this.dimensions[Fn]||0)-(Zi.dimensions[Fn]||0);for(var ti=0;ti<Zi.units.length;ti++){var Mi=hg(hg({},Zi.units[ti]),{},{power:-Zi.units[ti].power});$n.units.push(Mi)}if(null!==this.value||null!==Zi.value){var Pr=null===this.value?this._normalize(1):this.value,Br=null===Zi.value?Zi._normalize(1):Zi.value;$n.value=A(Pr,Br)}else $n.value=null;return Pt(xn)&&($n.skipAutomaticSimplification=!1),lt($n)},de.prototype.pow=function(xn){for(var $n=this.clone(),Zi=0;Zi<En.length;Zi++)$n.dimensions[Zi]=(this.dimensions[Zi]||0)*xn;for(var Fn=0;Fn<$n.units.length;Fn++)$n.units[Fn].power*=xn;return $n.value=null!==$n.value?k($n.value,xn):null,$n.skipAutomaticSimplification=!1,lt($n)},de.prototype.abs=function(){var xn=this.clone();if(null!==xn.value)if(xn._isDerived()||0===xn.units.length||0===xn.units[0].unit.offset)xn.value=R(xn.value);else{var $n=xn._numberConverter(),Zi=$n(xn.units[0].unit.value),Fn=$n(xn.units[0].unit.offset),ti=C(Zi,Fn);xn.value=y(R(_(xn.value,ti)),ti)}for(var Mi in xn.units)("VA"===xn.units[Mi].unit.name||"VAR"===xn.units[Mi].unit.name)&&(xn.units[Mi].unit=_n.W);return xn},de.prototype.to=function(xn){var Zi,$n=null===this.value?this._normalize(1):this.value;if("string"==typeof xn)Zi=de.parse(xn);else{if(!Pt(xn))throw new Error("String or Unit expected as parameter");Zi=xn.clone()}if(!this.equalBase(Zi))throw new Error("Units do not match ('".concat(Zi.toString(),"' != '").concat(this.toString(),"')"));if(null!==Zi.value)throw new Error("Cannot convert to a unit with a value");if(null===this.value||this._isDerived()||0===this.units.length||0===Zi.units.length||this.units[0].unit.offset===Zi.units[0].unit.offset)Zi.value=At($n);else{var Fn=de._getNumberConverter(pi($n)),Pr=C(this.units[0].unit.value,this.units[0].unit.offset),Zr=C(Zi.units[0].unit.value,Zi.units[0].unit.offset);Zi.value=_($n,Fn(y(Pr,Zr)))}return Zi.fixPrefix=!0,Zi.skipAutomaticSimplification=!0,Zi},de.prototype.toNumber=function(xn){return Le(this.toNumeric(xn))},de.prototype.toNumeric=function(xn){var $n;return($n=xn?this.to(xn):this.clone())._isDerived()||0===$n.units.length?$n._denormalize($n.value):$n._denormalize($n.value,$n.units[0].prefix.value)},de.prototype.toString=function(){return this.format()},de.prototype.toJSON=function(){return{mathjs:"Unit",value:this._denormalize(this.value),unit:this.units.length>0?this.formatUnits():null,fixPrefix:this.fixPrefix}},de.fromJSON=function(xn){var $n,Zi=new de(xn.value,null!==($n=xn.unit)&&void 0!==$n?$n:void 0);return Zi.fixPrefix=xn.fixPrefix||!1,Zi},de.prototype.valueOf=de.prototype.toString,de.prototype.simplify=function(){var Zi,ti,xn=this.clone(),$n=[];for(var Fn in nr)if(Jt(nr,Fn)&&xn.hasBase(_t[Fn])){Zi=Fn;break}if("NONE"===Zi)xn.units=[];else if(Zi&&Jt(nr,Zi)&&(ti=nr[Zi]),ti)xn.units=[{unit:ti.unit,prefix:ti.prefix,power:1}];else{for(var Mi=!1,Pr=0;Pr<En.length;Pr++){var Br=En[Pr];Math.abs(xn.dimensions[Pr]||0)>1e-12&&(Jt(nr,Br)?$n.push({unit:nr[Br].unit,prefix:nr[Br].prefix,power:xn.dimensions[Pr]||0}):Mi=!0)}$n.length<xn.units.length&&!Mi&&(xn.units=$n)}return xn},de.prototype.toSI=function(){for(var xn=this.clone(),$n=[],Zi=0;Zi<En.length;Zi++){var Fn=En[Zi];if(Math.abs(xn.dimensions[Zi]||0)>1e-12){if(!Jt(Pi.si,Fn))throw new Error("Cannot express custom unit "+Fn+" in SI units");$n.push({unit:Pi.si[Fn].unit,prefix:Pi.si[Fn].prefix,power:xn.dimensions[Zi]||0})}}return xn.units=$n,xn.fixPrefix=!0,xn.skipAutomaticSimplification=!0,null!==this.value?(xn.value=null,this.to(xn)):xn},de.prototype.formatUnits=function(){for(var xn="",$n="",Zi=0,Fn=0,ti=0;ti<this.units.length;ti++)this.units[ti].power>0?(Zi++,xn+=" "+this.units[ti].prefix.name+this.units[ti].unit.name,Math.abs(this.units[ti].power-1)>1e-15&&(xn+="^"+this.units[ti].power)):this.units[ti].power<0&&Fn++;if(Fn>0)for(var Mi=0;Mi<this.units.length;Mi++)this.units[Mi].power<0&&(Zi>0?($n+=" "+this.units[Mi].prefix.name+this.units[Mi].unit.name,Math.abs(this.units[Mi].power+1)>1e-15&&($n+="^"+-this.units[Mi].power)):($n+=" "+this.units[Mi].prefix.name+this.units[Mi].unit.name,$n+="^"+this.units[Mi].power));xn=xn.substr(1),$n=$n.substr(1),Zi>1&&Fn>0&&(xn="("+xn+")"),Fn>1&&Zi>0&&($n="("+$n+")");var Pr=xn;return Zi>0&&Fn>0&&(Pr+=" / "),Pr+$n},de.prototype.format=function(xn){var $n=this.skipAutomaticSimplification||null===this.value?this.clone():this.simplify(),Zi=!1;for(var Fn in typeof $n.value<"u"&&null!==$n.value&&un($n.value)&&(Zi=Math.abs($n.value.re)<1e-14),$n.units)Jt($n.units,Fn)&&$n.units[Fn].unit&&("VA"===$n.units[Fn].unit.name&&Zi?$n.units[Fn].unit=_n.VAR:"VAR"===$n.units[Fn].unit.name&&!Zi&&($n.units[Fn].unit=_n.VA));1===$n.units.length&&!$n.fixPrefix&&Math.abs($n.units[0].power-Math.round($n.units[0].power))<1e-14&&($n.units[0].prefix=$n._bestPrefix());var ti=$n._denormalize($n.value),Mi=null!==$n.value?G(ti,xn||{}):"",Pr=$n.formatUnits();return $n.value&&un($n.value)&&(Mi="("+Mi+")"),Pr.length>0&&Mi.length>0&&(Mi+=" "),Mi+Pr},de.prototype._bestPrefix=function(){if(1!==this.units.length)throw new Error("Can only compute the best prefix for single units with integer powers, like kg, s^2, N^-1, and so forth!");if(Math.abs(this.units[0].power-Math.round(this.units[0].power))>=1e-14)throw new Error("Can only compute the best prefix for single units with integer powers, like kg, s^2, N^-1, and so forth!");var xn=null!==this.value?R(this.value):0,$n=R(this.units[0].unit.value),Zi=this.units[0].prefix;if(0===xn)return Zi;var Fn=this.units[0].power,ti=Math.log(xn/Math.pow(Zi.value*$n,Fn))/Math.LN10-1.2;if(ti>-2.200001&&ti<1.800001)return Zi;ti=Math.abs(ti);var Mi=this.units[0].unit.prefixes;for(var Pr in Mi)if(Jt(Mi,Pr)){var Br=Mi[Pr];if(Br.scientific){var Go=Math.abs(Math.log(xn/Math.pow(Br.value*$n,Fn))/Math.LN10-1.2);(Go<ti||Go===ti&&Br.name.length<Zi.name.length)&&(Zi=Br,ti=Go)}}return Zi},de.prototype.splitUnit=function(xn){for(var $n=this.clone(),Zi=[],Fn=0;Fn<xn.length&&($n=$n.to(xn[Fn]),Fn!==xn.length-1);Fn++){var ti=$n.toNumeric(),Mi=F(ti),Go=new de(B(Mi,ti)?Mi:O($n.toNumeric()),xn[Fn].toString());Zi.push(Go),$n=y($n,Go)}for(var Zr=0,rl=0;rl<Zi.length;rl++)Zr=_(Zr,Zi[rl].value);return B(Zr,this.value)&&($n.value=0),Zi.push($n),Zi};var st={NONE:{"":{name:"",value:1,scientific:!0}},SHORT:{"":{name:"",value:1,scientific:!0},da:{name:"da",value:10,scientific:!1},h:{name:"h",value:100,scientific:!1},k:{name:"k",value:1e3,scientific:!0},M:{name:"M",value:1e6,scientific:!0},G:{name:"G",value:1e9,scientific:!0},T:{name:"T",value:1e12,scientific:!0},P:{name:"P",value:1e15,scientific:!0},E:{name:"E",value:1e18,scientific:!0},Z:{name:"Z",value:1e21,scientific:!0},Y:{name:"Y",value:1e24,scientific:!0},R:{name:"R",value:1e27,scientific:!0},Q:{name:"Q",value:1e30,scientific:!0},d:{name:"d",value:.1,scientific:!1},c:{name:"c",value:.01,scientific:!1},m:{name:"m",value:.001,scientific:!0},u:{name:"u",value:1e-6,scientific:!0},n:{name:"n",value:1e-9,scientific:!0},p:{name:"p",value:1e-12,scientific:!0},f:{name:"f",value:1e-15,scientific:!0},a:{name:"a",value:1e-18,scientific:!0},z:{name:"z",value:1e-21,scientific:!0},y:{name:"y",value:1e-24,scientific:!0},r:{name:"r",value:1e-27,scientific:!0},q:{name:"q",value:1e-30,scientific:!0}},LONG:{"":{name:"",value:1,scientific:!0},deca:{name:"deca",value:10,scientific:!1},hecto:{name:"hecto",value:100,scientific:!1},kilo:{name:"kilo",value:1e3,scientific:!0},mega:{name:"mega",value:1e6,scientific:!0},giga:{name:"giga",value:1e9,scientific:!0},tera:{name:"tera",value:1e12,scientific:!0},peta:{name:"peta",value:1e15,scientific:!0},exa:{name:"exa",value:1e18,scientific:!0},zetta:{name:"zetta",value:1e21,scientific:!0},yotta:{name:"yotta",value:1e24,scientific:!0},ronna:{name:"ronna",value:1e27,scientific:!0},quetta:{name:"quetta",value:1e30,scientific:!0},deci:{name:"deci",value:.1,scientific:!1},centi:{name:"centi",value:.01,scientific:!1},milli:{name:"milli",value:.001,scientific:!0},micro:{name:"micro",value:1e-6,scientific:!0},nano:{name:"nano",value:1e-9,scientific:!0},pico:{name:"pico",value:1e-12,scientific:!0},femto:{name:"femto",value:1e-15,scientific:!0},atto:{name:"atto",value:1e-18,scientific:!0},zepto:{name:"zepto",value:1e-21,scientific:!0},yocto:{name:"yocto",value:1e-24,scientific:!0},ronto:{name:"ronto",value:1e-27,scientific:!0},quecto:{name:"quecto",value:1e-30,scientific:!0}},SQUARED:{"":{name:"",value:1,scientific:!0},da:{name:"da",value:100,scientific:!1},h:{name:"h",value:1e4,scientific:!1},k:{name:"k",value:1e6,scientific:!0},M:{name:"M",value:1e12,scientific:!0},G:{name:"G",value:1e18,scientific:!0},T:{name:"T",value:1e24,scientific:!0},P:{name:"P",value:1e30,scientific:!0},E:{name:"E",value:1e36,scientific:!0},Z:{name:"Z",value:1e42,scientific:!0},Y:{name:"Y",value:1e48,scientific:!0},R:{name:"R",value:1e54,scientific:!0},Q:{name:"Q",value:1e60,scientific:!0},d:{name:"d",value:.01,scientific:!1},c:{name:"c",value:1e-4,scientific:!1},m:{name:"m",value:1e-6,scientific:!0},u:{name:"u",value:1e-12,scientific:!0},n:{name:"n",value:1e-18,scientific:!0},p:{name:"p",value:1e-24,scientific:!0},f:{name:"f",value:1e-30,scientific:!0},a:{name:"a",value:1e-36,scientific:!0},z:{name:"z",value:1e-42,scientific:!0},y:{name:"y",value:1e-48,scientific:!0},r:{name:"r",value:1e-54,scientific:!0},q:{name:"q",value:1e-60,scientific:!0}},CUBIC:{"":{name:"",value:1,scientific:!0},da:{name:"da",value:1e3,scientific:!1},h:{name:"h",value:1e6,scientific:!1},k:{name:"k",value:1e9,scientific:!0},M:{name:"M",value:1e18,scientific:!0},G:{name:"G",value:1e27,scientific:!0},T:{name:"T",value:1e36,scientific:!0},P:{name:"P",value:1e45,scientific:!0},E:{name:"E",value:1e54,scientific:!0},Z:{name:"Z",value:1e63,scientific:!0},Y:{name:"Y",value:1e72,scientific:!0},R:{name:"R",value:1e81,scientific:!0},Q:{name:"Q",value:1e90,scientific:!0},d:{name:"d",value:.001,scientific:!1},c:{name:"c",value:1e-6,scientific:!1},m:{name:"m",value:1e-9,scientific:!0},u:{name:"u",value:1e-18,scientific:!0},n:{name:"n",value:1e-27,scientific:!0},p:{name:"p",value:1e-36,scientific:!0},f:{name:"f",value:1e-45,scientific:!0},a:{name:"a",value:1e-54,scientific:!0},z:{name:"z",value:1e-63,scientific:!0},y:{name:"y",value:1e-72,scientific:!0},r:{name:"r",value:1e-81,scientific:!0},q:{name:"q",value:1e-90,scientific:!0}},BINARY_SHORT_SI:{"":{name:"",value:1,scientific:!0},k:{name:"k",value:1e3,scientific:!0},M:{name:"M",value:1e6,scientific:!0},G:{name:"G",value:1e9,scientific:!0},T:{name:"T",value:1e12,scientific:!0},P:{name:"P",value:1e15,scientific:!0},E:{name:"E",value:1e18,scientific:!0},Z:{name:"Z",value:1e21,scientific:!0},Y:{name:"Y",value:1e24,scientific:!0}},BINARY_SHORT_IEC:{"":{name:"",value:1,scientific:!0},Ki:{name:"Ki",value:1024,scientific:!0},Mi:{name:"Mi",value:Math.pow(1024,2),scientific:!0},Gi:{name:"Gi",value:Math.pow(1024,3),scientific:!0},Ti:{name:"Ti",value:Math.pow(1024,4),scientific:!0},Pi:{name:"Pi",value:Math.pow(1024,5),scientific:!0},Ei:{name:"Ei",value:Math.pow(1024,6),scientific:!0},Zi:{name:"Zi",value:Math.pow(1024,7),scientific:!0},Yi:{name:"Yi",value:Math.pow(1024,8),scientific:!0}},BINARY_LONG_SI:{"":{name:"",value:1,scientific:!0},kilo:{name:"kilo",value:1e3,scientific:!0},mega:{name:"mega",value:1e6,scientific:!0},giga:{name:"giga",value:1e9,scientific:!0},tera:{name:"tera",value:1e12,scientific:!0},peta:{name:"peta",value:1e15,scientific:!0},exa:{name:"exa",value:1e18,scientific:!0},zetta:{name:"zetta",value:1e21,scientific:!0},yotta:{name:"yotta",value:1e24,scientific:!0}},BINARY_LONG_IEC:{"":{name:"",value:1,scientific:!0},kibi:{name:"kibi",value:1024,scientific:!0},mebi:{name:"mebi",value:Math.pow(1024,2),scientific:!0},gibi:{name:"gibi",value:Math.pow(1024,3),scientific:!0},tebi:{name:"tebi",value:Math.pow(1024,4),scientific:!0},pebi:{name:"pebi",value:Math.pow(1024,5),scientific:!0},exi:{name:"exi",value:Math.pow(1024,6),scientific:!0},zebi:{name:"zebi",value:Math.pow(1024,7),scientific:!0},yobi:{name:"yobi",value:Math.pow(1024,8),scientific:!0}},BTU:{"":{name:"",value:1,scientific:!0},MM:{name:"MM",value:1e6,scientific:!0}}};st.SHORTLONG=e({},st.SHORT,st.LONG),st.BINARY_SHORT=e({},st.BINARY_SHORT_SI,st.BINARY_SHORT_IEC),st.BINARY_LONG=e({},st.BINARY_LONG_SI,st.BINARY_LONG_IEC);var En=["MASS","LENGTH","TIME","CURRENT","TEMPERATURE","LUMINOUS_INTENSITY","AMOUNT_OF_SUBSTANCE","ANGLE","BIT"],_t={NONE:{dimensions:[0,0,0,0,0,0,0,0,0]},MASS:{dimensions:[1,0,0,0,0,0,0,0,0]},LENGTH:{dimensions:[0,1,0,0,0,0,0,0,0]},TIME:{dimensions:[0,0,1,0,0,0,0,0,0]},CURRENT:{dimensions:[0,0,0,1,0,0,0,0,0]},TEMPERATURE:{dimensions:[0,0,0,0,1,0,0,0,0]},LUMINOUS_INTENSITY:{dimensions:[0,0,0,0,0,1,0,0,0]},AMOUNT_OF_SUBSTANCE:{dimensions:[0,0,0,0,0,0,1,0,0]},FORCE:{dimensions:[1,1,-2,0,0,0,0,0,0]},SURFACE:{dimensions:[0,2,0,0,0,0,0,0,0]},VOLUME:{dimensions:[0,3,0,0,0,0,0,0,0]},ENERGY:{dimensions:[1,2,-2,0,0,0,0,0,0]},POWER:{dimensions:[1,2,-3,0,0,0,0,0,0]},PRESSURE:{dimensions:[1,-1,-2,0,0,0,0,0,0]},ELECTRIC_CHARGE:{dimensions:[0,0,1,1,0,0,0,0,0]},ELECTRIC_CAPACITANCE:{dimensions:[-1,-2,4,2,0,0,0,0,0]},ELECTRIC_POTENTIAL:{dimensions:[1,2,-3,-1,0,0,0,0,0]},ELECTRIC_RESISTANCE:{dimensions:[1,2,-3,-2,0,0,0,0,0]},ELECTRIC_INDUCTANCE:{dimensions:[1,2,-2,-2,0,0,0,0,0]},ELECTRIC_CONDUCTANCE:{dimensions:[-1,-2,3,2,0,0,0,0,0]},MAGNETIC_FLUX:{dimensions:[1,2,-2,-1,0,0,0,0,0]},MAGNETIC_FLUX_DENSITY:{dimensions:[1,0,-2,-1,0,0,0,0,0]},FREQUENCY:{dimensions:[0,0,-1,0,0,0,0,0,0]},ANGLE:{dimensions:[0,0,0,0,0,0,0,1,0]},BIT:{dimensions:[0,0,0,0,0,0,0,0,1]}};for(var di in _t)Jt(_t,di)&&(_t[di].key=di);var Xn={name:"",base:{},value:1,offset:0,dimensions:En.map(xn=>0)},_n={meter:{name:"meter",base:_t.LENGTH,prefixes:st.LONG,value:1,offset:0},inch:{name:"inch",base:_t.LENGTH,prefixes:st.NONE,value:.0254,offset:0},foot:{name:"foot",base:_t.LENGTH,prefixes:st.NONE,value:.3048,offset:0},yard:{name:"yard",base:_t.LENGTH,prefixes:st.NONE,value:.9144,offset:0},mile:{name:"mile",base:_t.LENGTH,prefixes:st.NONE,value:1609.344,offset:0},link:{name:"link",base:_t.LENGTH,prefixes:st.NONE,value:.201168,offset:0},rod:{name:"rod",base:_t.LENGTH,prefixes:st.NONE,value:5.0292,offset:0},chain:{name:"chain",base:_t.LENGTH,prefixes:st.NONE,value:20.1168,offset:0},angstrom:{name:"angstrom",base:_t.LENGTH,prefixes:st.NONE,value:1e-10,offset:0},m:{name:"m",base:_t.LENGTH,prefixes:st.SHORT,value:1,offset:0},in:{name:"in",base:_t.LENGTH,prefixes:st.NONE,value:.0254,offset:0},ft:{name:"ft",base:_t.LENGTH,prefixes:st.NONE,value:.3048,offset:0},yd:{name:"yd",base:_t.LENGTH,prefixes:st.NONE,value:.9144,offset:0},mi:{name:"mi",base:_t.LENGTH,prefixes:st.NONE,value:1609.344,offset:0},li:{name:"li",base:_t.LENGTH,prefixes:st.NONE,value:.201168,offset:0},rd:{name:"rd",base:_t.LENGTH,prefixes:st.NONE,value:5.02921,offset:0},ch:{name:"ch",base:_t.LENGTH,prefixes:st.NONE,value:20.1168,offset:0},mil:{name:"mil",base:_t.LENGTH,prefixes:st.NONE,value:254e-7,offset:0},m2:{name:"m2",base:_t.SURFACE,prefixes:st.SQUARED,value:1,offset:0},sqin:{name:"sqin",base:_t.SURFACE,prefixes:st.NONE,value:64516e-8,offset:0},sqft:{name:"sqft",base:_t.SURFACE,prefixes:st.NONE,value:.09290304,offset:0},sqyd:{name:"sqyd",base:_t.SURFACE,prefixes:st.NONE,value:.83612736,offset:0},sqmi:{name:"sqmi",base:_t.SURFACE,prefixes:st.NONE,value:2589988.110336,offset:0},sqrd:{name:"sqrd",base:_t.SURFACE,prefixes:st.NONE,value:25.29295,offset:0},sqch:{name:"sqch",base:_t.SURFACE,prefixes:st.NONE,value:404.6873,offset:0},sqmil:{name:"sqmil",base:_t.SURFACE,prefixes:st.NONE,value:6.4516e-10,offset:0},acre:{name:"acre",base:_t.SURFACE,prefixes:st.NONE,value:4046.86,offset:0},hectare:{name:"hectare",base:_t.SURFACE,prefixes:st.NONE,value:1e4,offset:0},m3:{name:"m3",base:_t.VOLUME,prefixes:st.CUBIC,value:1,offset:0},L:{name:"L",base:_t.VOLUME,prefixes:st.SHORT,value:.001,offset:0},l:{name:"l",base:_t.VOLUME,prefixes:st.SHORT,value:.001,offset:0},litre:{name:"litre",base:_t.VOLUME,prefixes:st.LONG,value:.001,offset:0},cuin:{name:"cuin",base:_t.VOLUME,prefixes:st.NONE,value:16387064e-12,offset:0},cuft:{name:"cuft",base:_t.VOLUME,prefixes:st.NONE,value:.028316846592,offset:0},cuyd:{name:"cuyd",base:_t.VOLUME,prefixes:st.NONE,value:.764554857984,offset:0},teaspoon:{name:"teaspoon",base:_t.VOLUME,prefixes:st.NONE,value:5e-6,offset:0},tablespoon:{name:"tablespoon",base:_t.VOLUME,prefixes:st.NONE,value:15e-6,offset:0},drop:{name:"drop",base:_t.VOLUME,prefixes:st.NONE,value:5e-8,offset:0},gtt:{name:"gtt",base:_t.VOLUME,prefixes:st.NONE,value:5e-8,offset:0},minim:{name:"minim",base:_t.VOLUME,prefixes:st.NONE,value:6.1611519921875e-8,offset:0},fluiddram:{name:"fluiddram",base:_t.VOLUME,prefixes:st.NONE,value:36966911953125e-19,offset:0},fluidounce:{name:"fluidounce",base:_t.VOLUME,prefixes:st.NONE,value:295735295625e-16,offset:0},gill:{name:"gill",base:_t.VOLUME,prefixes:st.NONE,value:.00011829411825,offset:0},cc:{name:"cc",base:_t.VOLUME,prefixes:st.NONE,value:1e-6,offset:0},cup:{name:"cup",base:_t.VOLUME,prefixes:st.NONE,value:.0002365882365,offset:0},pint:{name:"pint",base:_t.VOLUME,prefixes:st.NONE,value:.000473176473,offset:0},quart:{name:"quart",base:_t.VOLUME,prefixes:st.NONE,value:.000946352946,offset:0},gallon:{name:"gallon",base:_t.VOLUME,prefixes:st.NONE,value:.003785411784,offset:0},beerbarrel:{name:"beerbarrel",base:_t.VOLUME,prefixes:st.NONE,value:.117347765304,offset:0},oilbarrel:{name:"oilbarrel",base:_t.VOLUME,prefixes:st.NONE,value:.158987294928,offset:0},hogshead:{name:"hogshead",base:_t.VOLUME,prefixes:st.NONE,value:.238480942392,offset:0},g:{name:"g",base:_t.MASS,prefixes:st.SHORT,value:.001,offset:0},gram:{name:"gram",base:_t.MASS,prefixes:st.LONG,value:.001,offset:0},ton:{name:"ton",base:_t.MASS,prefixes:st.SHORT,value:907.18474,offset:0},t:{name:"t",base:_t.MASS,prefixes:st.SHORT,value:1e3,offset:0},tonne:{name:"tonne",base:_t.MASS,prefixes:st.LONG,value:1e3,offset:0},grain:{name:"grain",base:_t.MASS,prefixes:st.NONE,value:6479891e-11,offset:0},dram:{name:"dram",base:_t.MASS,prefixes:st.NONE,value:.0017718451953125,offset:0},ounce:{name:"ounce",base:_t.MASS,prefixes:st.NONE,value:.028349523125,offset:0},poundmass:{name:"poundmass",base:_t.MASS,prefixes:st.NONE,value:.45359237,offset:0},hundredweight:{name:"hundredweight",base:_t.MASS,prefixes:st.NONE,value:45.359237,offset:0},stick:{name:"stick",base:_t.MASS,prefixes:st.NONE,value:.115,offset:0},stone:{name:"stone",base:_t.MASS,prefixes:st.NONE,value:6.35029318,offset:0},gr:{name:"gr",base:_t.MASS,prefixes:st.NONE,value:6479891e-11,offset:0},dr:{name:"dr",base:_t.MASS,prefixes:st.NONE,value:.0017718451953125,offset:0},oz:{name:"oz",base:_t.MASS,prefixes:st.NONE,value:.028349523125,offset:0},lbm:{name:"lbm",base:_t.MASS,prefixes:st.NONE,value:.45359237,offset:0},cwt:{name:"cwt",base:_t.MASS,prefixes:st.NONE,value:45.359237,offset:0},s:{name:"s",base:_t.TIME,prefixes:st.SHORT,value:1,offset:0},min:{name:"min",base:_t.TIME,prefixes:st.NONE,value:60,offset:0},h:{name:"h",base:_t.TIME,prefixes:st.NONE,value:3600,offset:0},second:{name:"second",base:_t.TIME,prefixes:st.LONG,value:1,offset:0},sec:{name:"sec",base:_t.TIME,prefixes:st.LONG,value:1,offset:0},minute:{name:"minute",base:_t.TIME,prefixes:st.NONE,value:60,offset:0},hour:{name:"hour",base:_t.TIME,prefixes:st.NONE,value:3600,offset:0},day:{name:"day",base:_t.TIME,prefixes:st.NONE,value:86400,offset:0},week:{name:"week",base:_t.TIME,prefixes:st.NONE,value:604800,offset:0},month:{name:"month",base:_t.TIME,prefixes:st.NONE,value:2629800,offset:0},year:{name:"year",base:_t.TIME,prefixes:st.NONE,value:31557600,offset:0},decade:{name:"decade",base:_t.TIME,prefixes:st.NONE,value:315576e3,offset:0},century:{name:"century",base:_t.TIME,prefixes:st.NONE,value:315576e4,offset:0},millennium:{name:"millennium",base:_t.TIME,prefixes:st.NONE,value:315576e5,offset:0},hertz:{name:"Hertz",base:_t.FREQUENCY,prefixes:st.LONG,value:1,offset:0,reciprocal:!0},Hz:{name:"Hz",base:_t.FREQUENCY,prefixes:st.SHORT,value:1,offset:0,reciprocal:!0},rad:{name:"rad",base:_t.ANGLE,prefixes:st.SHORT,value:1,offset:0},radian:{name:"radian",base:_t.ANGLE,prefixes:st.LONG,value:1,offset:0},deg:{name:"deg",base:_t.ANGLE,prefixes:st.SHORT,value:null,offset:0},degree:{name:"degree",base:_t.ANGLE,prefixes:st.LONG,value:null,offset:0},grad:{name:"grad",base:_t.ANGLE,prefixes:st.SHORT,value:null,offset:0},gradian:{name:"gradian",base:_t.ANGLE,prefixes:st.LONG,value:null,offset:0},cycle:{name:"cycle",base:_t.ANGLE,prefixes:st.NONE,value:null,offset:0},arcsec:{name:"arcsec",base:_t.ANGLE,prefixes:st.NONE,value:null,offset:0},arcmin:{name:"arcmin",base:_t.ANGLE,prefixes:st.NONE,value:null,offset:0},A:{name:"A",base:_t.CURRENT,prefixes:st.SHORT,value:1,offset:0},ampere:{name:"ampere",base:_t.CURRENT,prefixes:st.LONG,value:1,offset:0},K:{name:"K",base:_t.TEMPERATURE,prefixes:st.SHORT,value:1,offset:0},degC:{name:"degC",base:_t.TEMPERATURE,prefixes:st.SHORT,value:1,offset:273.15},degF:{name:"degF",base:_t.TEMPERATURE,prefixes:st.SHORT,value:new we(5,9),offset:459.67},degR:{name:"degR",base:_t.TEMPERATURE,prefixes:st.SHORT,value:new we(5,9),offset:0},kelvin:{name:"kelvin",base:_t.TEMPERATURE,prefixes:st.LONG,value:1,offset:0},celsius:{name:"celsius",base:_t.TEMPERATURE,prefixes:st.LONG,value:1,offset:273.15},fahrenheit:{name:"fahrenheit",base:_t.TEMPERATURE,prefixes:st.LONG,value:new we(5,9),offset:459.67},rankine:{name:"rankine",base:_t.TEMPERATURE,prefixes:st.LONG,value:new we(5,9),offset:0},mol:{name:"mol",base:_t.AMOUNT_OF_SUBSTANCE,prefixes:st.SHORT,value:1,offset:0},mole:{name:"mole",base:_t.AMOUNT_OF_SUBSTANCE,prefixes:st.LONG,value:1,offset:0},cd:{name:"cd",base:_t.LUMINOUS_INTENSITY,prefixes:st.SHORT,value:1,offset:0},candela:{name:"candela",base:_t.LUMINOUS_INTENSITY,prefixes:st.LONG,value:1,offset:0},N:{name:"N",base:_t.FORCE,prefixes:st.SHORT,value:1,offset:0},newton:{name:"newton",base:_t.FORCE,prefixes:st.LONG,value:1,offset:0},dyn:{name:"dyn",base:_t.FORCE,prefixes:st.SHORT,value:1e-5,offset:0},dyne:{name:"dyne",base:_t.FORCE,prefixes:st.LONG,value:1e-5,offset:0},lbf:{name:"lbf",base:_t.FORCE,prefixes:st.NONE,value:4.4482216152605,offset:0},poundforce:{name:"poundforce",base:_t.FORCE,prefixes:st.NONE,value:4.4482216152605,offset:0},kip:{name:"kip",base:_t.FORCE,prefixes:st.LONG,value:4448.2216,offset:0},kilogramforce:{name:"kilogramforce",base:_t.FORCE,prefixes:st.NONE,value:9.80665,offset:0},J:{name:"J",base:_t.ENERGY,prefixes:st.SHORT,value:1,offset:0},joule:{name:"joule",base:_t.ENERGY,prefixes:st.LONG,value:1,offset:0},erg:{name:"erg",base:_t.ENERGY,prefixes:st.SHORTLONG,value:1e-7,offset:0},Wh:{name:"Wh",base:_t.ENERGY,prefixes:st.SHORT,value:3600,offset:0},BTU:{name:"BTU",base:_t.ENERGY,prefixes:st.BTU,value:1055.05585262,offset:0},eV:{name:"eV",base:_t.ENERGY,prefixes:st.SHORT,value:1602176565e-28,offset:0},electronvolt:{name:"electronvolt",base:_t.ENERGY,prefixes:st.LONG,value:1602176565e-28,offset:0},W:{name:"W",base:_t.POWER,prefixes:st.SHORT,value:1,offset:0},watt:{name:"watt",base:_t.POWER,prefixes:st.LONG,value:1,offset:0},hp:{name:"hp",base:_t.POWER,prefixes:st.NONE,value:745.6998715386,offset:0},VAR:{name:"VAR",base:_t.POWER,prefixes:st.SHORT,value:te.I,offset:0},VA:{name:"VA",base:_t.POWER,prefixes:st.SHORT,value:1,offset:0},Pa:{name:"Pa",base:_t.PRESSURE,prefixes:st.SHORT,value:1,offset:0},psi:{name:"psi",base:_t.PRESSURE,prefixes:st.NONE,value:6894.75729276459,offset:0},atm:{name:"atm",base:_t.PRESSURE,prefixes:st.NONE,value:101325,offset:0},bar:{name:"bar",base:_t.PRESSURE,prefixes:st.SHORTLONG,value:1e5,offset:0},torr:{name:"torr",base:_t.PRESSURE,prefixes:st.NONE,value:133.322,offset:0},mmHg:{name:"mmHg",base:_t.PRESSURE,prefixes:st.NONE,value:133.322,offset:0},mmH2O:{name:"mmH2O",base:_t.PRESSURE,prefixes:st.NONE,value:9.80665,offset:0},cmH2O:{name:"cmH2O",base:_t.PRESSURE,prefixes:st.NONE,value:98.0665,offset:0},coulomb:{name:"coulomb",base:_t.ELECTRIC_CHARGE,prefixes:st.LONG,value:1,offset:0},C:{name:"C",base:_t.ELECTRIC_CHARGE,prefixes:st.SHORT,value:1,offset:0},farad:{name:"farad",base:_t.ELECTRIC_CAPACITANCE,prefixes:st.LONG,value:1,offset:0},F:{name:"F",base:_t.ELECTRIC_CAPACITANCE,prefixes:st.SHORT,value:1,offset:0},volt:{name:"volt",base:_t.ELECTRIC_POTENTIAL,prefixes:st.LONG,value:1,offset:0},V:{name:"V",base:_t.ELECTRIC_POTENTIAL,prefixes:st.SHORT,value:1,offset:0},ohm:{name:"ohm",base:_t.ELECTRIC_RESISTANCE,prefixes:st.SHORTLONG,value:1,offset:0},henry:{name:"henry",base:_t.ELECTRIC_INDUCTANCE,prefixes:st.LONG,value:1,offset:0},H:{name:"H",base:_t.ELECTRIC_INDUCTANCE,prefixes:st.SHORT,value:1,offset:0},siemens:{name:"siemens",base:_t.ELECTRIC_CONDUCTANCE,prefixes:st.LONG,value:1,offset:0},S:{name:"S",base:_t.ELECTRIC_CONDUCTANCE,prefixes:st.SHORT,value:1,offset:0},weber:{name:"weber",base:_t.MAGNETIC_FLUX,prefixes:st.LONG,value:1,offset:0},Wb:{name:"Wb",base:_t.MAGNETIC_FLUX,prefixes:st.SHORT,value:1,offset:0},tesla:{name:"tesla",base:_t.MAGNETIC_FLUX_DENSITY,prefixes:st.LONG,value:1,offset:0},T:{name:"T",base:_t.MAGNETIC_FLUX_DENSITY,prefixes:st.SHORT,value:1,offset:0},b:{name:"b",base:_t.BIT,prefixes:st.BINARY_SHORT,value:1,offset:0},bits:{name:"bits",base:_t.BIT,prefixes:st.BINARY_LONG,value:1,offset:0},B:{name:"B",base:_t.BIT,prefixes:st.BINARY_SHORT,value:8,offset:0},bytes:{name:"bytes",base:_t.BIT,prefixes:st.BINARY_LONG,value:8,offset:0}},Ni={meters:"meter",inches:"inch",feet:"foot",yards:"yard",miles:"mile",links:"link",rods:"rod",chains:"chain",angstroms:"angstrom",lt:"l",litres:"litre",liter:"litre",liters:"litre",teaspoons:"teaspoon",tablespoons:"tablespoon",minims:"minim",fldr:"fluiddram",fluiddrams:"fluiddram",floz:"fluidounce",fluidounces:"fluidounce",gi:"gill",gills:"gill",cp:"cup",cups:"cup",pt:"pint",pints:"pint",qt:"quart",quarts:"quart",gal:"gallon",gallons:"gallon",bbl:"beerbarrel",beerbarrels:"beerbarrel",obl:"oilbarrel",oilbarrels:"oilbarrel",hogsheads:"hogshead",gtts:"gtt",grams:"gram",tons:"ton",tonnes:"tonne",grains:"grain",drams:"dram",ounces:"ounce",poundmasses:"poundmass",hundredweights:"hundredweight",sticks:"stick",lb:"lbm",lbs:"lbm",kips:"kip",kgf:"kilogramforce",acres:"acre",hectares:"hectare",sqfeet:"sqft",sqyard:"sqyd",sqmile:"sqmi",sqmiles:"sqmi",mmhg:"mmHg",mmh2o:"mmH2O",cmh2o:"cmH2O",seconds:"second",secs:"second",minutes:"minute",mins:"minute",hours:"hour",hr:"hour",hrs:"hour",days:"day",weeks:"week",months:"month",years:"year",decades:"decade",centuries:"century",millennia:"millennium",hertz:"hertz",radians:"radian",degrees:"degree",gradians:"gradian",cycles:"cycle",arcsecond:"arcsec",arcseconds:"arcsec",arcminute:"arcmin",arcminutes:"arcmin",BTUs:"BTU",watts:"watt",joules:"joule",amperes:"ampere",amps:"ampere",amp:"ampere",coulombs:"coulomb",volts:"volt",ohms:"ohm",farads:"farad",webers:"weber",teslas:"tesla",electronvolts:"electronvolt",moles:"mole",bit:"bits",byte:"bytes"};function kr(xn){if("BigNumber"===xn.number){var $n=Tc(be);_n.rad.value=new be(1),_n.deg.value=$n.div(180),_n.grad.value=$n.div(200),_n.cycle.value=$n.times(2),_n.arcsec.value=$n.div(648e3),_n.arcmin.value=$n.div(10800)}else _n.rad.value=1,_n.deg.value=Math.PI/180,_n.grad.value=Math.PI/200,_n.cycle.value=2*Math.PI,_n.arcsec.value=Math.PI/648e3,_n.arcmin.value=Math.PI/10800;_n.radian.value=_n.rad.value,_n.degree.value=_n.deg.value,_n.gradian.value=_n.grad.value}kr(b),m&&m("config",function(xn,$n){xn.number!==$n.number&&kr(xn)});var Pi={si:{NONE:{unit:Xn,prefix:st.NONE[""]},LENGTH:{unit:_n.m,prefix:st.SHORT[""]},MASS:{unit:_n.g,prefix:st.SHORT.k},TIME:{unit:_n.s,prefix:st.SHORT[""]},CURRENT:{unit:_n.A,prefix:st.SHORT[""]},TEMPERATURE:{unit:_n.K,prefix:st.SHORT[""]},LUMINOUS_INTENSITY:{unit:_n.cd,prefix:st.SHORT[""]},AMOUNT_OF_SUBSTANCE:{unit:_n.mol,prefix:st.SHORT[""]},ANGLE:{unit:_n.rad,prefix:st.SHORT[""]},BIT:{unit:_n.bits,prefix:st.SHORT[""]},FORCE:{unit:_n.N,prefix:st.SHORT[""]},ENERGY:{unit:_n.J,prefix:st.SHORT[""]},POWER:{unit:_n.W,prefix:st.SHORT[""]},PRESSURE:{unit:_n.Pa,prefix:st.SHORT[""]},ELECTRIC_CHARGE:{unit:_n.C,prefix:st.SHORT[""]},ELECTRIC_CAPACITANCE:{unit:_n.F,prefix:st.SHORT[""]},ELECTRIC_POTENTIAL:{unit:_n.V,prefix:st.SHORT[""]},ELECTRIC_RESISTANCE:{unit:_n.ohm,prefix:st.SHORT[""]},ELECTRIC_INDUCTANCE:{unit:_n.H,prefix:st.SHORT[""]},ELECTRIC_CONDUCTANCE:{unit:_n.S,prefix:st.SHORT[""]},MAGNETIC_FLUX:{unit:_n.Wb,prefix:st.SHORT[""]},MAGNETIC_FLUX_DENSITY:{unit:_n.T,prefix:st.SHORT[""]},FREQUENCY:{unit:_n.Hz,prefix:st.SHORT[""]}}};Pi.cgs=JSON.parse(JSON.stringify(Pi.si)),Pi.cgs.LENGTH={unit:_n.m,prefix:st.SHORT.c},Pi.cgs.MASS={unit:_n.g,prefix:st.SHORT[""]},Pi.cgs.FORCE={unit:_n.dyn,prefix:st.SHORT[""]},Pi.cgs.ENERGY={unit:_n.erg,prefix:st.NONE[""]},Pi.us=JSON.parse(JSON.stringify(Pi.si)),Pi.us.LENGTH={unit:_n.ft,prefix:st.NONE[""]},Pi.us.MASS={unit:_n.lbm,prefix:st.NONE[""]},Pi.us.TEMPERATURE={unit:_n.degF,prefix:st.NONE[""]},Pi.us.FORCE={unit:_n.lbf,prefix:st.NONE[""]},Pi.us.ENERGY={unit:_n.BTU,prefix:st.BTU[""]},Pi.us.POWER={unit:_n.hp,prefix:st.NONE[""]},Pi.us.PRESSURE={unit:_n.psi,prefix:st.NONE[""]},Pi.auto=JSON.parse(JSON.stringify(Pi.si));var nr=Pi.auto;for(var Sr in de.setUnitSystem=function(xn){if(!Jt(Pi,xn))throw new Error("Unit system "+xn+" does not exist. Choices are: "+Object.keys(Pi).join(", "));nr=Pi[xn]},de.getUnitSystem=function(){for(var xn in Pi)if(Jt(Pi,xn)&&Pi[xn]===nr)return xn},de.typeConverters={BigNumber:function($n){return null!=$n&&$n.isFraction?new be($n.n).div($n.d).times($n.s):new be($n+"")},Fraction:function($n){return new we($n)},Complex:function($n){return $n},number:function($n){return null!=$n&&$n.isFraction?J($n):$n}},de.prototype._numberConverter=function(){var xn=de.typeConverters[this.valueType()];if(xn)return xn;throw new TypeError('Unsupported Unit value type "'+this.valueType()+'"')},de._getNumberConverter=function(xn){if(!de.typeConverters[xn])throw new TypeError('Unsupported type "'+xn+'"');return de.typeConverters[xn]},_n)if(Jt(_n,Sr)){var ir=_n[Sr];ir.dimensions=ir.base.dimensions}for(var lr in Ni)if(Jt(Ni,lr)){var wr=_n[Ni[lr]],$r={};for(var Io in wr)Jt(wr,Io)&&($r[Io]=wr[Io]);$r.name=lr,_n[lr]=$r}return de.isValidAlpha=function($n){return/^[a-zA-Z]$/.test($n)},de.createUnit=function(xn,$n){if("object"!=typeof xn)throw new TypeError("createUnit expects first parameter to be of type 'Object'");if($n&&$n.override)for(var Zi in xn)if(Jt(xn,Zi)&&de.deleteUnit(Zi),xn[Zi].aliases)for(var Fn=0;Fn<xn[Zi].aliases.length;Fn++)de.deleteUnit(xn[Zi].aliases[Fn]);var ti;for(var Mi in xn)Jt(xn,Mi)&&(ti=de.createUnitSingle(Mi,xn[Mi]));return ti},de.createUnitSingle=function(xn,$n){if((typeof $n>"u"||null===$n)&&($n={}),"string"!=typeof xn)throw new TypeError("createUnitSingle expects first parameter to be of type 'string'");if(Jt(_n,xn))throw new Error('Cannot create unit "'+xn+'": a unit with that name already exists');!function ms(xn){for(var $n=0;$n<xn.length;$n++){if(pe=xn.charAt($n),0===$n&&!de.isValidAlpha(pe))throw new Error('Invalid unit name (must begin with alpha character): "'+xn+'"');if($n>0&&!de.isValidAlpha(pe)&&!ke(pe))throw new Error('Invalid unit name (only alphanumeric characters are allowed): "'+xn+'"')}}(xn);var Mi,Pr,Br,Zi=null,Fn=[],ti=0;if($n&&"Unit"===$n.type)Zi=$n.clone();else if("string"==typeof $n)""!==$n&&(Mi=$n);else{if("object"!=typeof $n)throw new TypeError('Cannot create unit "'+xn+'" from "'+$n.toString()+'": expecting "string" or "Unit" or "Object"');Mi=$n.definition,Pr=$n.prefixes,ti=$n.offset,Br=$n.baseName,$n.aliases&&(Fn=$n.aliases.valueOf())}if(Fn)for(var Go=0;Go<Fn.length;Go++)if(Jt(_n,Fn[Go]))throw new Error('Cannot create alias "'+Fn[Go]+'": a unit with that name already exists');if(Mi&&"string"==typeof Mi&&!Zi)try{Zi=de.parse(Mi,{allowNoUnits:!0})}catch(ot){throw ot.message='Could not create unit "'+xn+'" from "'+Mi+'": '+ot.message,ot}else Mi&&"Unit"===Mi.type&&(Zi=Mi.clone());Fn=Fn||[],ti=ti||0,Pr=Pr&&Pr.toUpperCase&&st[Pr.toUpperCase()]||st.NONE;var Zr={};if(Zi){Zr={name:xn,value:Zi.value,dimensions:Zi.dimensions.slice(0),prefixes:Pr,offset:ti};var Kd=!1;for(var Mf in _t)if(Jt(_t,Mf)){for(var b0=!0,j_=0;j_<En.length;j_++)if(Math.abs((Zr.dimensions[j_]||0)-(_t[Mf].dimensions[j_]||0))>1e-12){b0=!1;break}if(b0){Kd=!0,Zr.base=_t[Mf];break}}if(!Kd){Br=Br||xn+"_STUFF";var cO={dimensions:Zi.dimensions.slice(0)};cO.key=Br,_t[Br]=cO,nr[Br]={unit:Zr,prefix:st.NONE[""]},Zr.base=_t[Br]}}else{if(En.indexOf(Br=Br||xn+"_STUFF")>=0)throw new Error('Cannot create new base unit "'+xn+'": a base unit with that name already exists (and cannot be overridden)');for(var rl in En.push(Br),_t)Jt(_t,rl)&&(_t[rl].dimensions[En.length-1]=0);for(var Nl={dimensions:[]},Ru=0;Ru<En.length;Ru++)Nl.dimensions[Ru]=0;Nl.dimensions[En.length-1]=1,Nl.key=Br,_t[Br]=Nl,Zr={name:xn,value:1,dimensions:_t[Br].dimensions.slice(0),prefixes:Pr,offset:ti,base:_t[Br]},nr[Br]={unit:Zr,prefix:st.NONE[""]}}de.UNITS[xn]=Zr;for(var CM=0;CM<Fn.length;CM++){var mE=Fn[CM],du={};for(var uO in Zr)Jt(Zr,uO)&&(du[uO]=Zr[uO]);du.name=mE,de.UNITS[mE]=du}return delete Kt.cache,new de(null,xn)},de.deleteUnit=function(xn){delete de.UNITS[xn],delete Kt.cache},de.PREFIXES=st,de.BASE_DIMENSIONS=En,de.BASE_UNITS=_t,de.UNIT_SYSTEMS=Pi,de.UNITS=_n,de},{isClass:!0}),iu=re("dotPow",["typed","equalScalar","matrix","pow","DenseMatrix","concat"],p=>{var{typed:m,equalScalar:b,matrix:_,pow:y,DenseMatrix:C,concat:A}=p,k=Hd({typed:m}),R=Gg({typed:m,DenseMatrix:C}),O=Bf({typed:m,equalScalar:b}),F=Od({typed:m,DenseMatrix:C}),B=$c({typed:m,matrix:_,concat:A}),H={};for(var G in y.signatures)Object.prototype.hasOwnProperty.call(y.signatures,G)&&!G.includes("Matrix")&&!G.includes("Array")&&(H[G]=y.signatures[G]);var J=m(H);return m("dotPow",B({elop:J,SS:R,DS:k,Ss:O,sS:F}))}),S_=re("expm",["typed","abs","add","identity","inv","multiply"],p=>{var{typed:m,abs:b,add:_,identity:y,inv:C,multiply:A}=p;return m("expm",{Matrix:function(B){var H=B.size();if(2!==H.length||H[0]!==H[1])throw new RangeError("Matrix must be square (size: "+xs(H)+")");for(var G=H[0],te=function k(F){for(var B=F.size()[0],H=0,G=0;G<B;G++){for(var J=0,te=0;te<B;te++)J+=b(F.get([G,te]));H=Math.max(J,H)}return H}(B),be=function R(F,B){for(var G=0;G<30;G++)for(var J=0;J<=G;J++){var te=G-J;if(O(F,J,te)<B)return{q:J,j:te}}throw new Error("Could not find acceptable parameters to compute the matrix exponential (try increasing maxSearchSize in expm.js)")}(te,1e-15),we=be.q,Le=be.j,de=A(B,Math.pow(2,-Le)),Te=y(G),De=y(G),pe=1,Be=de,We=-1,ke=1;ke<=we;ke++)ke>1&&(Be=A(Be,de),We=-We),Te=_(Te,A(pe=pe*(we-ke+1)/((2*we-ke+1)*ke),Be)),De=_(De,A(pe*We,Be));for(var ze=A(C(De),Te),et=0;et<Le;et++)ze=A(ze,ze);return It(B)?B.createSparseMatrix(ze):ze}});function O(F,B,H){for(var G=1,J=2;J<=B;J++)G*=J;for(var te=G,be=B+1;be<=2*B;be++)te*=be;var we=te*(2*B+1);return 8*Math.pow(F/Math.pow(2,H),2*B)*G*G/(te*we)}}),dd=re("fft",["typed","matrix","addScalar","multiplyScalar","divideScalar","exp","tau","i","dotDivide","conj","pow","ceil","log2"],p=>{var{typed:m,addScalar:_,multiplyScalar:y,divideScalar:C,exp:A,tau:k,i:R,dotDivide:O,conj:F,pow:B,ceil:H,log2:G}=p;return m("fft",{Array:J,Matrix:function(de){return de.create(J(de.valueOf()),de.datatype())}});function J(Le){var de=Bs(Le);return 1===de.length?we(Le):te(Le.map(Te=>J(Te,de.slice(1))),0)}function te(Le,de){var Te=Bs(Le);if(0!==de)return new Array(Te[0]).fill(0).map((pe,Be)=>te(Le[Be],de-1));if(1===Te.length)return we(Le);function De(pe){var Be=Bs(pe);return new Array(Be[1]).fill(0).map((We,ke)=>new Array(Be[0]).fill(0).map((ze,et)=>pe[et][ke]))}return De(te(De(Le),1))}function we(Le){var de=Le.length;if(1===de)return[Le[0]];if(de%2==0){for(var Te=[...we(Le.filter((We,ke)=>ke%2==0)),...we(Le.filter((We,ke)=>ke%2==1))],De=0;De<de/2;De++){var pe=Te[De],Be=y(Te[De+de/2],A(y(y(k,R),C(-De,de))));Te[De]=_(pe,Be),Te[De+de/2]=_(pe,y(-1,Be))}return Te}return function be(Le){for(var de=Le.length,Te=A(C(y(-1,y(R,k)),de)),De=[],pe=1-de;pe<de;pe++)De.push(B(Te,C(B(pe,2),2)));for(var Be=B(2,H(G(de+de-1))),We=[...new Array(de).fill(0).map((lt,st)=>y(Le[st],De[de-1+st])),...new Array(Be-de).fill(0)],ke=[...new Array(de+de-1).fill(0).map((lt,st)=>C(1,De[st])),...new Array(Be-(de+de-1)).fill(0)],ze=we(We),et=we(ke),pt=new Array(Be).fill(0).map((lt,st)=>y(ze[st],et[st])),$t=O(F(J(F(pt))),Be),Zt=[],Kt=de-1;Kt<de+de-1;Kt++)Zt.push(y($t[Kt],De[Kt]));return Zt}(Le)}}),kb=re("gamma",["typed","config","multiplyScalar","pow","BigNumber","Complex"],p=>{var{typed:m,config:b,BigNumber:C,Complex:A}=p;return m("gamma",{number:Id,Complex:function k(O){if(0===O.im)return Id(O.re);if(O.re<.5){var F=new A(1-O.re,-O.im),B=new A(Math.PI*O.re,Math.PI*O.im);return new A(Math.PI).div(B.sin()).div(k(F))}O=new A(O.re-1,O.im);for(var H=new A(up[0],0),G=1;G<up.length;++G){var J=new A(up[G],0);H=H.add(J.div(O.add(G)))}var te=new A(O.re+J_+.5,O.im),be=Math.sqrt(2*Math.PI),we=te.pow(O.add(.5)),Le=te.neg().exp();return H.mul(be).mul(we).mul(Le)},BigNumber:function(F){if(F.isInteger())return F.isNegative()||F.isZero()?new C(1/0):R(F.minus(1));if(!F.isFinite())return new C(F.isNegative()?NaN:1/0);throw new Error("Integer BigNumber expected")}});function R(O){if(O<8)return new C([1,1,2,6,24,120,720,5040][O]);var F=b.precision+(0|Math.log(O.toNumber())),B=C.clone({precision:F});if(O%2==1)return O.times(R(new C(O-1)));for(var H=O,G=new B(O),J=O.toNumber();H>2;)G=G.times(J+=H-=2);return new C(G.toPrecision(C.precision))}}),hv=re("ifft",["typed","fft","dotDivide","conj"],p=>{var{typed:m,fft:b,dotDivide:_,conj:y}=p;return m("ifft",{"Array | Matrix":function(A){var k=ut(A)?A.size():Bs(A);return _(y(b(y(A))),k.reduce((R,O)=>R*O,1))}})}),Hc="createUnit",mv=re(Hc,["typed","Unit"],p=>{var{typed:m,Unit:b}=p;return m(Hc,{"Object, Object":function(y,C){return b.createUnit(y,C)},Object:function(y){return b.createUnit(y,{})},"string, Unit | string | Object, Object":function(y,C,A){var k={};return k[y]=C,b.createUnit(k,A)},"string, Unit | string | Object":function(y,C){var A={};return A[y]=C,b.createUnit(A,{})},string:function(y){var C={};return C[y]={},b.createUnit(C,{})}})}),xC=re("divide",["typed","matrix","multiply","equalScalar","divideScalar","inv"],p=>{var{typed:m,matrix:b,multiply:_,equalScalar:y,divideScalar:C,inv:A}=p,k=Bf({typed:m,equalScalar:y}),R=Bp({typed:m});return m("divide",Mn({"Array | Matrix, Array | Matrix":function(F,B){return _(F,A(B))},"DenseMatrix, any":function(F,B){return R(F,B,C,!1)},"SparseMatrix, any":function(F,B){return k(F,B,C,!1)},"Array, any":function(F,B){return R(b(F),B,C,!1).valueOf()},"any, Array | Matrix":function(F,B){return _(F,A(B))}},C.signatures))}),SC="factorial",Dd=re(SC,["typed","gamma"],p=>{var{typed:m,gamma:b}=p;return m(SC,{number:function(y){if(y<0)throw new Error("Value must be non-negative");return b(y+1)},BigNumber:function(y){if(y.isNegative())throw new Error("Value must be non-negative");return b(y.plus(1))},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})});function LS(p,m){var b,_=m.length,y=[];if(p)for(b=0;b<_;b++)y[p[b]]=m[b];else for(b=0;b<_;b++)y[b]=m[b];return y}var Iw="lusolve",EC=re(Iw,["typed","matrix","lup","slu","usolve","lsolve","DenseMatrix"],p=>{var{typed:m,matrix:b,lup:_,slu:y,usolve:C,lsolve:A,DenseMatrix:k}=p,R=hy({DenseMatrix:k});return m(Iw,{"Array, Array | Matrix":function(H,G){H=b(H);var J=_(H);return F(J.L,J.U,J.p,null,G).valueOf()},"DenseMatrix, Array | Matrix":function(H,G){var J=_(H);return F(J.L,J.U,J.p,null,G)},"SparseMatrix, Array | Matrix":function(H,G){var J=_(H);return F(J.L,J.U,J.p,null,G)},"SparseMatrix, Array | Matrix, number, number":function(H,G,J,te){var be=y(H,J,te);return F(be.L,be.U,be.p,be.q,G)},"Object, Array | Matrix":function(H,G){return F(H.L,H.U,H.p,H.q,G)}});function O(B){if(ut(B))return B;if(dt(B))return b(B);throw new TypeError("Invalid Matrix LU decomposition")}function F(B,H,G,J,te){B=O(B),H=O(H),G&&((te=R(B,te,!0))._data=LS(G,te._data));var be=A(B,te),we=C(H,be);return J&&(we._data=LS(J,we._data)),we}}),Aw="multinomial",Jy=re(Aw,["typed","add","divide","multiply","factorial","isInteger","isPositive"],p=>{var{typed:m,add:b,divide:_,multiply:y,factorial:C,isInteger:A,isPositive:k}=p;return m(Aw,{"Array | Matrix":function(O){var F=0,B=1;return Ss(O,function(H){if(!A(H)||!k(H))throw new TypeError("Positive integer value expected in function multinomial");F=b(F,H),B=y(B,C(H))}),_(C(F),B)}})}),Ow="permutations",e0=re(Ow,["typed","factorial"],p=>{var{typed:m,factorial:b}=p;return m(Ow,{"number | BigNumber":b,"number, number":function(y,C){if(!ai(y)||y<0)throw new TypeError("Positive integer value expected in function permutations");if(!ai(C)||C<0)throw new TypeError("Positive integer value expected in function permutations");if(C>y)throw new TypeError("second argument k must be less than or equal to first argument n");return _f(y-C+1,y)},"BigNumber, BigNumber":function(y,C){var A,k;if(!Bb(y)||!Bb(C))throw new TypeError("Positive integer value expected in function permutations");if(C.gt(y))throw new TypeError("second argument k must be less than or equal to first argument n");for(A=y.mul(0).add(1),k=y.minus(C).plus(1);k.lte(y);k=k.plus(1))A=A.times(k);return A}})});function Bb(p){return p.isInteger()&&p.gte(0)}var T_="polynomialRoot",t0=re(T_,["typed","isZero","equalScalar","add","subtract","multiply","divide","sqrt","unaryMinus","cbrt","typeOf","im","re"],p=>{var{typed:m,isZero:b,equalScalar:_,add:y,subtract:C,multiply:A,divide:k,sqrt:R,unaryMinus:O,cbrt:F,typeOf:B,im:H,re:G}=p;return m(T_,{"number|Complex, ...number|Complex":(J,te)=>{for(var be=[J,...te];be.length>0&&b(be[be.length-1]);)be.pop();if(be.length<2)throw new RangeError("Polynomial [".concat(J,", ").concat(te,"] must have a non-zero non-constant coefficient"));switch(be.length){case 2:return[O(k(be[0],be[1]))];case 3:var[we,Le,de]=be,Te=A(2,de),De=A(Le,Le),pe=A(4,de,we);if(_(De,pe))return[k(O(Le),Te)];var Be=R(C(De,pe));return[k(C(Be,Le),Te),k(C(O(Be),Le),Te)];case 4:var[We,ke,ze,et]=be,pt=O(A(3,et)),$t=A(ze,ze),Zt=A(3,et,ke),Kt=y(A(2,ze,ze,ze),A(27,et,et,We)),lt=A(9,et,ze,ke);if(_($t,Zt)&&_(Kt,lt))return[k(ze,pt)];var ki,st=C($t,Zt),En=C(Kt,lt),_t=y(A(18,et,ze,ke,We),A(ze,ze,ke,ke)),di=y(A(4,ze,ze,ze,We),A(4,et,ke,ke,ke),A(27,et,et,We,We));return _(_t,di)?[k(C(A(4,et,ze,ke),y(A(9,et,et,We),A(ze,ze,ze))),A(et,st)),k(C(A(9,et,We),A(ze,ke)),A(2,st))]:(ki=_($t,Zt)?En:k(y(En,R(C(A(En,En),A(4,st,st,st)))),2),F(ki,!0).toArray().map(Ni=>k(y(ze,Ni,k(st,Ni)),pt)).map(Ni=>"Complex"===B(Ni)&&_(G(Ni),G(Ni)+H(Ni))?G(Ni):Ni));default:throw new RangeError("only implemented for cubic or lower-order polynomials, not ".concat(be))}}})}),M_="setSize",Vb=re(M_,["typed","compareNatural"],p=>{var{typed:m,compareNatural:b}=p;return m(M_,{"Array | Matrix":function(y){return Array.isArray(y)?ns(y).length:ns(y.toArray()).length},"Array | Matrix, boolean":function(y,C){if(!1===C||0===y.length)return Array.isArray(y)?ns(y).length:ns(y.toArray()).length;for(var A=ns(Array.isArray(y)?y:y.toArray()).sort(b),k=1,R=1;R<A.length;R++)0!==b(A[R],A[R-1])&&k++;return k}})});function n0(p,m){var b=Object.keys(p);if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(p);m&&(_=_.filter(function(y){return Object.getOwnPropertyDescriptor(p,y).enumerable})),b.push.apply(b,_)}return b}var IC=re("solveODE",["typed","add","subtract","multiply","divide","max","map","abs","isPositive","isNegative","larger","smaller","matrix","bignumber","unaryMinus"],p=>{var{typed:m,add:b,subtract:_,multiply:y,divide:C,max:A,map:k,abs:R,isPositive:O,isNegative:F,larger:B,smaller:H,matrix:G,bignumber:J,unaryMinus:te}=p;function be(We){return function(ke,ze,et,pt){if(2!==ze.length||!ze.every(pe)&&!ze.every(Pt))throw new Error('"tspan" must be an Array of two numeric values or two units [tStart, tEnd]');var Zt=ze[0],Kt=ze[1],lt=B(Kt,Zt),st=pt.firstStep;if(void 0!==st&&!O(st))throw new Error('"firstStep" must be positive');var En=pt.maxStep;if(void 0!==En&&!O(En))throw new Error('"maxStep" must be positive');var _t=pt.minStep;if(_t&&F(_t))throw new Error('"minStep" must be positive or zero');var di=[Zt,Kt,st,_t,En].filter(Go=>void 0!==Go);if(!di.every(pe)&&!di.every(Pt))throw new Error('Inconsistent type of "t" dependant variables');for(var Xn=pt.tol?pt.tol:1e-4,_n=pt.minDelta?pt.minDelta:.2,Ni=pt.maxDelta?pt.maxDelta:5,kr=pt.maxIter?pt.maxIter:1e4,Pi=[Zt,Kt,...et,En,_t].some(en),[nr,Sr,ir,lr]=Pi?[J(We.a),J(We.c),J(We.b),J(We.bp)]:[We.a,We.c,We.b,We.bp],wr=st?lt?st:te(st):C(_(Kt,Zt),1),$r=[Zt],Io=[et],ms=_(ir,lr),xn=0,$n=0,Zi=function Te(We){return We?H:B}(lt),Fn=function De(We){var ke=We?B:H;return function(ze,et,pt){var $t=b(ze,pt);return ke($t,et)?_(et,ze):pt}}(lt);Zi($r[xn],Kt);){var ti=[];wr=Fn($r[xn],Kt,wr),ti.push(ke($r[xn],Io[xn]));for(var Mi=1;Mi<Sr.length;++Mi)ti.push(ke(b($r[xn],y(Sr[Mi],wr)),b(Io[xn],y(wr,nr[Mi],ti))));var Pr=A(R(k(y(ms,ti),Go=>Pt(Go)?Go.value:Go)));Pr<Xn&&Xn/Pr>1/4&&($r.push(b($r[xn],wr)),Io.push(b(Io[xn],y(wr,ir,ti))),xn++);var Br=.84*(Xn/Pr)**.2;if(H(Br,_n)?Br=_n:B(Br,Ni)&&(Br=Ni),Br=Pi?J(Br):Br,wr=y(wr,Br),En&&B(R(wr),En)?wr=lt?En:te(En):_t&&H(R(wr),_t)&&(wr=lt?_t:te(_t)),++$n>kr)throw new Error("Maximum number of iterations reached, try changing options")}return{t:$r,y:Io}}}function we(We,ke,ze,et){return be({a:[[],[.5],[0,.75],[.2222222222222222,.3333333333333333,.4444444444444444]],c:[null,.5,3/4,1],b:[2/9,1/3,4/9,0],bp:[7/24,1/4,1/3,1/8]})(We,ke,ze,et)}function Le(We,ke,ze,et){return be({a:[[],[.2],[.075,.225],[.9777777777777777,-3.7333333333333334,3.5555555555555554],[2.9525986892242035,-11.595793324188385,9.822892851699436,-.2908093278463649],[2.8462752525252526,-10.757575757575758,8.906422717743473,.2784090909090909,-.2735313036020583],[.09114583333333333,0,.44923629829290207,.6510416666666666,-.322376179245283,.13095238095238096]],c:[null,.2,.3,.8,8/9,1,1],b:[35/384,0,500/1113,125/192,-2187/6784,11/84,0],bp:[5179/57600,0,7571/16695,393/640,-92097/339200,187/2100,1/40]})(We,ke,ze,et)}function de(We,ke,ze,et){var pt=et.method?et.method:"RK45",$t={RK23:we,RK45:Le};if(pt.toUpperCase()in $t){var Zt=function TC(p){for(var m=1;m<arguments.length;m++){var b=null!=arguments[m]?arguments[m]:{};m%2?n0(Object(b),!0).forEach(function(_){ud(p,_,b[_])}):Object.getOwnPropertyDescriptors?Object.defineProperties(p,Object.getOwnPropertyDescriptors(b)):n0(Object(b)).forEach(function(_){Object.defineProperty(p,_,Object.getOwnPropertyDescriptor(b,_))})}return p}({},et);return delete Zt.method,$t[pt.toUpperCase()](We,ke,ze,Zt)}var Kt=Object.keys($t).map(st=>'"'.concat(st,'"')),lt="".concat(Kt.slice(0,-1).join(", ")," and ").concat(Kt.slice(-1));throw new Error('Unavailable method "'.concat(pt,'". Available methods are ').concat(lt))}function pe(We){return en(We)||ct(We)}function Be(We,ke,ze,et){var pt=de(We,ke.toArray(),ze.toArray(),et);return{t:G(pt.t),y:G(pt.y)}}return m("solveODE",{"function, Array, Array, Object":de,"function, Matrix, Matrix, Object":Be,"function, Array, Array":(We,ke,ze)=>de(We,ke,ze,{}),"function, Matrix, Matrix":(We,ke,ze)=>Be(We,ke,ze,{}),"function, Array, number | BigNumber | Unit":(We,ke,ze)=>{var et=de(We,ke,[ze],{});return{t:et.t,y:et.y.map(pt=>pt[0])}},"function, Matrix, number | BigNumber | Unit":(We,ke,ze)=>{var et=de(We,ke.toArray(),[ze],{});return{t:G(et.t),y:G(et.y.map(pt=>pt[0]))}},"function, Array, number | BigNumber | Unit, Object":(We,ke,ze,et)=>{var pt=de(We,ke,[ze],et);return{t:pt.t,y:pt.y.map($t=>$t[0])}},"function, Matrix, number | BigNumber | Unit, Object":(We,ke,ze,et)=>{var pt=de(We,ke.toArray(),[ze],et);return{t:G(pt.t),y:G(pt.y.map($t=>$t[0]))}}})}),AC="stirlingS2",OC=re(AC,["typed","addScalar","subtractScalar","multiplyScalar","divideScalar","pow","factorial","combinations","isNegative","isInteger","number","?bignumber","larger"],p=>{var{typed:m,addScalar:b,multiplyScalar:y,isNegative:O,isInteger:F,number:B,bignumber:H,larger:G}=p,J=[],te=[];return m(AC,{"number | BigNumber, number | BigNumber":function(we,Le){if(!F(we)||O(we)||!F(Le)||O(Le))throw new TypeError("Non-negative integer value expected in function stirlingS2");if(G(Le,we))throw new TypeError("k must be less than or equal to n in function stirlingS2");var de=!(ct(we)&&ct(Le)),Te=de?te:J,De=de?H:B,pe=B(we),Be=B(Le);if(Te[pe]&&Te[pe].length>Be)return Te[pe][Be];for(var We=0;We<=pe;++We)if(Te[We]||(Te[We]=[De(0===We?1:0)]),0!==We)for(var ke=Te[We],ze=Te[We-1],et=ke.length;et<=We&&et<=Be;++et)ke[et]=et===We?1:b(y(De(et),ze[et]),ze[et-1]);return Te[pe][Be]}})}),mh=re("unit",["typed","Unit"],p=>{var{typed:m,Unit:b}=p;return m("unit",{Unit:function(y){return y.clone()},string:function(y){return b.isValuelessUnit(y)?new b(null,y):b.parse(y,{allowNoUnits:!0})},"number | BigNumber | Fraction | Complex, string | Unit":function(y,C){return new b(y,C)},"number | BigNumber | Fraction":function(y){return new b(y)},"Array | Matrix":m.referToSelf(_=>y=>ps(y,_))})}),FC="bellNumbers",r0=re(FC,["typed","addScalar","isNegative","isInteger","stirlingS2"],p=>{var{typed:m,addScalar:b,isNegative:_,isInteger:y,stirlingS2:C}=p;return m(FC,{"number | BigNumber":function(k){if(!y(k)||_(k))throw new TypeError("Non-negative integer value expected in function bellNumbers");for(var R=0,O=0;O<=k;O++)R=b(R,C(k,O));return R}})});var US=["config","typed","matrix","addScalar","equal","subtract","abs","atan","cos","sin","multiplyScalar","divideScalar","inv","bignumber","multiply","add","larger","column","flatten","number","complex","sqrt","diag","size","reshape","qr","usolve","usolveAll","im","re","smaller","matrixFromColumns","dot"],jb=re("eigs",US,p=>{var{config:m,typed:b,matrix:_,addScalar:y,subtract:C,equal:A,abs:k,atan:R,cos:O,sin:F,multiplyScalar:B,divideScalar:H,inv:G,bignumber:J,multiply:te,add:be,larger:we,column:Le,flatten:de,number:Te,complex:De,sqrt:pe,diag:Be,size:We,reshape:ke,qr:ze,usolve:et,usolveAll:pt,im:$t,re:Zt,smaller:Kt,matrixFromColumns:lt,dot:st}=p,En=function NC(p){var{config:m,addScalar:b,subtract:_,abs:y,atan:C,cos:A,sin:k,multiplyScalar:R,inv:O,bignumber:F,multiply:B,add:H}=p;function be(ke,ze,et){return Math.abs(ze-ke)<=m.relTol?Math.PI/4:.5*Math.atan(2*et/(ze-ke))}function we(ke,ze,et){var pt=_(ze,ke);return y(pt)<=m.relTol?F(-1).acos().div(4):R(.5,C(B(2,et,O(pt))))}function Le(ke,ze,et,pt){for(var $t=ke.length,Zt=Math.cos(ze),Kt=Math.sin(ze),lt=Array($t).fill(0),st=Array($t).fill(0),En=0;En<$t;En++)lt[En]=Zt*ke[En][et]-Kt*ke[En][pt],st[En]=Kt*ke[En][et]+Zt*ke[En][pt];for(var _t=0;_t<$t;_t++)ke[_t][et]=lt[_t],ke[_t][pt]=st[_t];return ke}function de(ke,ze,et,pt){for(var $t=ke.length,Zt=A(ze),Kt=k(ze),lt=Array($t).fill(F(0)),st=Array($t).fill(F(0)),En=0;En<$t;En++)lt[En]=_(R(Zt,ke[En][et]),R(Kt,ke[En][pt])),st[En]=b(R(Kt,ke[En][et]),R(Zt,ke[En][pt]));for(var _t=0;_t<$t;_t++)ke[_t][et]=lt[_t],ke[_t][pt]=st[_t];return ke}function Te(ke,ze,et,pt){for(var $t=ke.length,Zt=F(A(ze)),Kt=F(k(ze)),lt=R(Zt,Zt),st=R(Kt,Kt),En=Array($t).fill(F(0)),_t=Array($t).fill(F(0)),di=B(F(2),Zt,Kt,ke[et][pt]),ki=b(_(R(lt,ke[et][et]),di),R(st,ke[pt][pt])),Xn=H(R(st,ke[et][et]),di,R(lt,ke[pt][pt])),_n=0;_n<$t;_n++)En[_n]=_(R(Zt,ke[et][_n]),R(Kt,ke[pt][_n])),_t[_n]=b(R(Kt,ke[et][_n]),R(Zt,ke[pt][_n]));ke[et][et]=ki,ke[pt][pt]=Xn,ke[et][pt]=F(0),ke[pt][et]=F(0);for(var Ni=0;Ni<$t;Ni++)Ni!==et&&Ni!==pt&&(ke[et][Ni]=En[Ni],ke[Ni][et]=En[Ni],ke[pt][Ni]=_t[Ni],ke[Ni][pt]=_t[Ni]);return ke}function De(ke,ze,et,pt){for(var $t=ke.length,Zt=Math.cos(ze),Kt=Math.sin(ze),lt=Zt*Zt,st=Kt*Kt,En=Array($t).fill(0),_t=Array($t).fill(0),di=lt*ke[et][et]-2*Zt*Kt*ke[et][pt]+st*ke[pt][pt],ki=st*ke[et][et]+2*Zt*Kt*ke[et][pt]+lt*ke[pt][pt],Xn=0;Xn<$t;Xn++)En[Xn]=Zt*ke[et][Xn]-Kt*ke[pt][Xn],_t[Xn]=Kt*ke[et][Xn]+Zt*ke[pt][Xn];ke[et][et]=di,ke[pt][pt]=ki,ke[et][pt]=0,ke[pt][et]=0;for(var _n=0;_n<$t;_n++)_n!==et&&_n!==pt&&(ke[et][_n]=En[_n],ke[_n][et]=En[_n],ke[pt][_n]=_t[_n],ke[_n][pt]=_t[_n]);return ke}function pe(ke){for(var ze=ke.length,et=0,pt=[0,1],$t=0;$t<ze;$t++)for(var Zt=$t+1;Zt<ze;Zt++)Math.abs(et)<Math.abs(ke[$t][Zt])&&(et=Math.abs(ke[$t][Zt]),pt=[$t,Zt]);return[pt,et]}function Be(ke){for(var ze=ke.length,et=0,pt=[0,1],$t=0;$t<ze;$t++)for(var Zt=$t+1;Zt<ze;Zt++)y(et)<y(ke[$t][Zt])&&(et=y(ke[$t][Zt]),pt=[$t,Zt]);return[pt,et]}function We(ke,ze,et){var Zt,pt=ke.length,$t=Array(pt);if(et){Zt=Array(pt);for(var Kt=0;Kt<pt;Kt++)Zt[Kt]=Array(pt)}for(var lt=0;lt<pt;lt++){for(var st=0,En=ke[0],_t=0;_t<ke.length;_t++)y(ke[_t])<y(En)&&(En=ke[st=_t]);if($t[lt]=ke.splice(st,1)[0],et)for(var di=0;di<pt;di++)Zt[lt][di]=ze[di][st],ze[di].splice(st,1)}if(!et)return{values:$t};var ki=Zt.map((Xn,_n)=>({value:$t[_n],vector:Xn}));return{values:$t,eigenvectors:ki}}return function G(ke,ze){var et=arguments.length>2&&void 0!==arguments[2]?arguments[2]:m.relTol,pt=arguments.length>3?arguments[3]:void 0,$t=arguments.length>4?arguments[4]:void 0;if("number"===pt)return function J(ke,ze,et){var Zt,Kt,pt=ke.length,$t=Math.abs(ze/pt);if(et){Kt=new Array(pt);for(var lt=0;lt<pt;lt++)Kt[lt]=Array(pt).fill(0),Kt[lt][lt]=1}for(var st=pe(ke);Math.abs(st[1])>=Math.abs($t);){var En=st[0][0],_t=st[0][1];ke=De(ke,Zt=be(ke[En][En],ke[_t][_t],ke[En][_t]),En,_t),et&&(Kt=Le(Kt,Zt,En,_t)),st=pe(ke)}for(var di=Array(pt).fill(0),ki=0;ki<pt;ki++)di[ki]=ke[ki][ki];return We(At(di),Kt,et)}(ke,et,$t);if("BigNumber"===pt)return function te(ke,ze,et){var Zt,Kt,pt=ke.length,$t=y(ze/pt);if(et){Kt=new Array(pt);for(var lt=0;lt<pt;lt++)Kt[lt]=Array(pt).fill(0),Kt[lt][lt]=1}for(var st=Be(ke);y(st[1])>=y($t);){var En=st[0][0],_t=st[0][1];ke=Te(ke,Zt=we(ke[En][En],ke[_t][_t],ke[En][_t]),En,_t),et&&(Kt=de(Kt,Zt,En,_t)),st=Be(ke)}for(var di=Array(pt).fill(0),ki=0;ki<pt;ki++)di[ki]=ke[ki][ki];return We(At(di),Kt,et)}(ke,et,$t);throw TypeError("Unsupported data type: "+pt)}}({config:m,addScalar:y,subtract:C,column:Le,flatten:de,equal:A,abs:k,atan:R,cos:O,sin:F,multiplyScalar:B,inv:G,bignumber:J,complex:De,multiply:te,add:be}),_t=function DT(p){var{addScalar:m,subtract:b,flatten:_,multiply:y,multiplyScalar:C,divideScalar:A,sqrt:k,abs:R,bignumber:O,diag:F,size:B,reshape:H,inv:G,qr:J,usolve:te,usolveAll:be,equal:we,complex:Le,larger:de,smaller:Te,dot:pe}=p;function pt(Xn,_n,Ni,kr){var Pi=m(Xn,kr),nr=b(C(Xn,kr),C(_n,Ni)),Sr=C(Pi,.5),ir=C(k(b(C(Pi,Pi),C(4,nr))),.5);return[m(Sr,ir),b(Sr,ir)]}function $t(Xn,_n,Ni,kr,Pi,nr,Sr,ir){var lr="BigNumber"===ir,wr="Complex"===ir,$r=lr?O(0):wr?Le(0):0,Io=lr?O(1):wr?Le(1):1;if(Te(R(Ni),Sr))return[[Io,$r],[$r,Io]];if(de(R(b(Pi,nr)),Sr))return[[b(Pi,kr),b(nr,kr)],[Ni,Ni]];var ms=b(Xn,Pi),xn=b(kr,Pi);return Te(R(_n),Sr)&&Te(R(xn),Sr)?[[ms,Io],[Ni,$r]]:[[_n,$r],[xn,Io]]}function Zt(Xn,_n){for(var Ni=0;Ni<Xn.length;Ni++)Xn[Ni].push(...Array(_n-Xn[Ni].length).fill(0));for(var kr=Xn.length;kr<_n;kr++)Xn.push(Array(_n).fill(0)),Xn[kr][kr]=1;return Xn}function lt(Xn,_n,Ni){for(var kr=0;kr<Xn.length;kr++)if(Ni(Xn[kr],_n))return kr;return-1}function st(Xn,_n,Ni,kr,Pi){for(var Sr,nr="BigNumber"===Pi?O(1e3):1e3,ir=0;ir<5;++ir){Sr=En(_n,Ni,Pi);try{Sr=te(Xn,Sr)}catch{continue}if(de(di(Sr),nr))break}if(ir>=5)return null;for(ir=0;;){var lr=te(Xn,Sr);if(Te(di(_t(Sr,[lr])),kr))break;if(++ir>=10)return null;Sr=ki(lr)}return Sr}function En(Xn,_n,Ni){var kr="BigNumber"===Ni,Pi="Complex"===Ni,nr=Array(Xn).fill(0).map(Sr=>2*Math.random()-1);return kr&&(nr=nr.map(Sr=>O(Sr))),Pi&&(nr=nr.map(Sr=>Le(Sr))),ki(nr=_t(nr,_n),Ni)}function _t(Xn,_n){var Ni=B(Xn);for(var kr of _n)kr=H(kr,Ni),Xn=b(Xn,y(A(pe(kr,Xn),pe(kr,kr)),kr));return Xn}function di(Xn){return R(k(pe(Xn,Xn)))}function ki(Xn,_n){var kr="Complex"===_n,Pi="BigNumber"===_n?O(1):kr?Le(1):1;return y(A(Pi,di(Xn)),Xn)}return function Be(Xn,_n,Ni,kr){var Pi=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],nr=function We(Xn,_n,Ni,kr,Pi){var ms,nr="BigNumber"===kr,Sr="Complex"===kr,ir=nr?O(0):0,lr=nr?O(1):Sr?Le(1):1,wr=nr?O(1):1,$r=nr?O(10):2,Io=C($r,$r);Pi&&(ms=Array(_n).fill(lr));for(var xn=!1;!xn;){xn=!0;for(var $n=0;$n<_n;$n++){for(var Zi=ir,Fn=ir,ti=0;ti<_n;ti++)$n!==ti&&(Zi=m(Zi,R(Xn[ti][$n])),Fn=m(Fn,R(Xn[$n][ti])));if(!we(Zi,0)&&!we(Fn,0)){for(var Mi=wr,Pr=Zi,Br=A(Fn,$r),Go=C(Fn,$r);Te(Pr,Br);)Pr=C(Pr,Io),Mi=C(Mi,$r);for(;de(Pr,Go);)Pr=A(Pr,Io),Mi=A(Mi,$r);if(Te(A(m(Pr,Fn),Mi),C(m(Zi,Fn),.95))){xn=!1;for(var rl=A(1,Mi),Nl=0;Nl<_n;Nl++)$n!==Nl&&(Xn[$n][Nl]=C(Xn[$n][Nl],rl),Xn[Nl][$n]=C(Xn[Nl][$n],Mi));Pi&&(ms[$n]=C(ms[$n],rl))}}}}return Pi?F(ms):null}(Xn,_n,0,kr,Pi);!function ke(Xn,_n,Ni,kr,Pi,nr){var Sr="BigNumber"===kr,ir="Complex"===kr,lr=Sr?O(0):ir?Le(0):0;Sr&&(Ni=O(Ni));for(var wr=0;wr<_n-2;wr++){for(var $r=0,Io=lr,ms=wr+1;ms<_n;ms++){var xn=Xn[ms][wr];Te(R(Io),R(xn))&&(Io=xn,$r=ms)}if(!Te(R(Io),Ni)){if($r!==wr+1){var $n=Xn[$r];Xn[$r]=Xn[wr+1],Xn[wr+1]=$n;for(var Zi=0;Zi<_n;Zi++){var Fn=Xn[Zi][$r];Xn[Zi][$r]=Xn[Zi][wr+1],Xn[Zi][wr+1]=Fn}if(Pi){var ti=nr[$r];nr[$r]=nr[wr+1],nr[wr+1]=ti}}for(var Mi=wr+2;Mi<_n;Mi++){var Pr=A(Xn[Mi][wr],Io);if(0!==Pr){for(var Br=0;Br<_n;Br++)Xn[Mi][Br]=b(Xn[Mi][Br],C(Pr,Xn[wr+1][Br]));for(var Go=0;Go<_n;Go++)Xn[Go][wr+1]=m(Xn[Go][wr+1],C(Pr,Xn[Go][Mi]));if(Pi)for(var Zr=0;Zr<_n;Zr++)nr[Mi][Zr]=b(nr[Mi][Zr],C(Pr,nr[wr+1][Zr]))}}}}}(Xn,_n,Ni,kr,Pi,nr);var{values:Sr,C:ir}=function ze(Xn,_n,Ni,kr,Pi){var nr="BigNumber"===kr,Sr="Complex"===kr,ir=nr?O(1):Sr?Le(1):1;nr&&(Ni=O(Ni));for(var lr=At(Xn),wr=[],$r=_n,Io=[],ms=Pi?F(Array(_n).fill(ir)):void 0,xn=Pi?F(Array($r).fill(ir)):void 0,$n=0;$n<=100;){$n+=1;for(var Zi=lr[$r-1][$r-1],Fn=0;Fn<$r;Fn++)lr[Fn][Fn]=b(lr[Fn][Fn],Zi);var{Q:ti,R:Mi}=J(lr);lr=y(Mi,ti);for(var Pr=0;Pr<$r;Pr++)lr[Pr][Pr]=m(lr[Pr][Pr],Zi);if(Pi&&(xn=y(xn,ti)),1===$r||Te(R(lr[$r-1][$r-2]),Ni)){$n=0,wr.push(lr[$r-1][$r-1]),Pi&&(Io.unshift([[1]]),Zt(xn,_n),ms=y(ms,xn),$r>1&&(xn=F(Array($r-1).fill(ir)))),$r-=1,lr.pop();for(var Br=0;Br<$r;Br++)lr[Br].pop()}else if(2===$r||Te(R(lr[$r-2][$r-3]),Ni)){$n=0;var Go=pt(lr[$r-2][$r-2],lr[$r-2][$r-1],lr[$r-1][$r-2],lr[$r-1][$r-1]);wr.push(...Go),Pi&&(Io.unshift($t(lr[$r-2][$r-2],lr[$r-2][$r-1],lr[$r-1][$r-2],lr[$r-1][$r-1],Go[0],Go[1],Ni,kr)),Zt(xn,_n),ms=y(ms,xn),$r>2&&(xn=F(Array($r-2).fill(ir)))),$r-=2,lr.pop(),lr.pop();for(var Zr=0;Zr<$r;Zr++)lr[Zr].pop(),lr[Zr].pop()}if(0===$r)break}if(wr.sort((Ru,Kd)=>+b(R(Ru),R(Kd))),$n>100){var rl=Error("The eigenvalues failed to converge. Only found these eigenvalues: "+wr.join(", "));throw rl.values=wr,rl.vectors=[],rl}var Nl=Pi?y(ms,function Kt(Xn,_n){for(var Ni=[],kr=0;kr<_n;kr++)Ni[kr]=Array(_n).fill(0);var Pi=0;for(var nr of Xn){for(var Sr=nr.length,ir=0;ir<Sr;ir++)for(var lr=0;lr<Sr;lr++)Ni[Pi+ir][Pi+lr]=nr[ir][lr];Pi+=Sr}return Ni}(Io,_n)):void 0;return{values:wr,C:Nl}}(Xn,_n,Ni,kr,Pi);if(Pi){var lr=function et(Xn,_n,Ni,kr,Pi,nr,Sr){var ir=G(Ni),lr=y(ir,Xn,Ni),wr="BigNumber"===Sr,$r="Complex"===Sr,Io=wr?O(0):$r?Le(0):0,ms=wr?O(1):$r?Le(1):1,xn=[],$n=[];for(var Zi of Pi){var Fn=lt(xn,Zi,we);-1===Fn?(xn.push(Zi),$n.push(1)):$n[Fn]+=1}for(var ti=[],Mi=xn.length,Pr=Array(_n).fill(Io),Br=F(Array(_n).fill(ms)),Go=function(){var Nl=xn[Zr],Ru=b(lr,y(Nl,Br)),Kd=be(Ru,Pr);for(Kd.shift();Kd.length<$n[Zr];){var Mf=st(Ru,_n,Kd,nr,Sr);if(null===Mf)break;Kd.push(Mf)}var b0=y(G(kr),Ni);Kd=Kd.map(j_=>y(b0,j_)),ti.push(...Kd.map(j_=>({value:Nl,vector:_(j_)})))},Zr=0;Zr<Mi;Zr++)Go();return ti}(Xn,_n,ir,nr,Sr,Ni,kr);return{values:Sr,eigenvectors:lr}}return{values:Sr}}}({config:m,addScalar:y,subtract:C,multiply:te,multiplyScalar:B,flatten:de,divideScalar:H,sqrt:pe,abs:k,bignumber:J,diag:Be,size:We,reshape:ke,qr:ze,inv:G,usolve:et,usolveAll:pt,equal:A,complex:De,larger:we,smaller:Kt,matrixFromColumns:lt,dot:st});return b("eigs",{Array:function(nr){return di(_(nr))},"Array, number|BigNumber":function(nr,Sr){return di(_(nr),{precision:Sr})},"Array, Object":(Pi,nr)=>di(_(Pi),nr),Matrix:function(nr){return di(nr,{matricize:!0})},"Matrix, number|BigNumber":function(nr,Sr){return di(nr,{precision:Sr,matricize:!0})},"Matrix, Object":function(nr,Sr){var ir={matricize:!0};return e(ir,Sr),di(nr,ir)}});function di(Pi){var nr,Sr=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},ir=!("eigenvectors"in Sr)||Sr.eigenvectors,wr=function ki(Pi,nr,Sr){var ir=Pi.toArray(),lr=Pi.size();if(2!==lr.length||lr[0]!==lr[1])throw new RangeError("Matrix must be square (size: ".concat(xs(lr),")"));var wr=lr[0];if(function _n(Pi,nr,Sr){for(var ir=0;ir<nr;ir++)for(var lr=0;lr<nr;lr++)if(we(J(k($t(Pi[ir][lr]))),Sr))return!1;return!0}(ir,wr,nr)&&(function Ni(Pi,nr){for(var Sr=0;Sr<nr;Sr++)for(var ir=0;ir<nr;ir++)Pi[Sr][ir]=Zt(Pi[Sr][ir])}(ir,wr),function Xn(Pi,nr,Sr){for(var ir=0;ir<nr;ir++)for(var lr=ir;lr<nr;lr++)if(we(J(k(C(Pi[ir][lr],Pi[lr][ir]))),Sr))return!1;return!0}(ir,wr,nr))){var $r=kr(Pi,ir,wr);return En(ir,wr,nr,$r,Sr)}var Io=kr(Pi,ir,wr);return _t(ir,wr,nr,Io,Sr)}(Pi,null!==(nr=Sr.precision)&&void 0!==nr?nr:m.relTol,ir);return Sr.matricize&&(wr.values=_(wr.values),ir&&(wr.eigenvectors=wr.eigenvectors.map($r=>{var{value:Io,vector:ms}=$r;return{value:Io,vector:_(ms)}}))),ir&&Object.defineProperty(wr,"vectors",{enumerable:!1,get:()=>{throw new Error("eigs(M).vectors replaced with eigs(M).eigenvectors")}}),wr}function kr(Pi,nr,Sr){var ir=Pi.datatype();if("number"===ir||"BigNumber"===ir||"Complex"===ir)return ir;for(var lr=!1,wr=!1,$r=!1,Io=0;Io<Sr;Io++)for(var ms=0;ms<Sr;ms++){var xn=nr[Io][ms];if(ct(xn)||vn(xn))lr=!0;else if(en(xn))wr=!0;else{if(!un(xn))throw TypeError("Unsupported type in Matrix: "+pi(xn));$r=!0}}if(wr&&$r&&console.warn("Complex BigNumbers not supported, this operation will lose precission."),$r){for(var $n=0;$n<Sr;$n++)for(var Zi=0;Zi<Sr;Zi++)nr[$n][Zi]=De(nr[$n][Zi]);return"Complex"}if(wr){for(var Fn=0;Fn<Sr;Fn++)for(var ti=0;ti<Sr;ti++)nr[Fn][ti]=J(nr[Fn][ti]);return"BigNumber"}if(lr){for(var Mi=0;Mi<Sr;Mi++)for(var Pr=0;Pr<Sr;Pr++)nr[Mi][Pr]=Te(nr[Mi][Pr]);return"number"}throw TypeError("Matrix contains unsupported types only.")}}),o0="kldivergence",s0=["typed","matrix","divide","sum","multiply","map","dotDivide","log","isNumeric"],Ub=re(o0,s0,p=>{var{typed:m,matrix:b,divide:_,sum:y,multiply:C,map:A,dotDivide:k,log:R,isNumeric:O}=p;return m(o0,{"Array, Array":function(H,G){return F(b(H),b(G))},"Matrix, Array":function(H,G){return F(H,b(G))},"Array, Matrix":function(H,G){return F(b(H),G)},"Matrix, Matrix":function(H,G){return F(H,G)}});function F(B,H){var G=H.size().length,J=B.size().length;if(G>1)throw new Error("first object must be one dimensional");if(J>1)throw new Error("second object must be one dimensional");if(G!==J)throw new Error("Length of two vectors must be equal");if(0===y(B))throw new Error("Sum of elements in first object must be non zero");if(0===y(H))throw new Error("Sum of elements in second object must be non zero");var we=_(B,y(B)),Le=_(H,y(H)),de=y(C(we,A(k(we,Le),Te=>R(Te))));return O(de)?de:Number.NaN}}),Nw=["typed","add","divide"],RC=re("mean",Nw,p=>{var{typed:m,add:b,divide:_}=p;return m("mean",{"Array | Matrix":C,"Array | Matrix, number | BigNumber":function y(A,k){try{var R=eh(A,k,b),O=Array.isArray(A)?Bs(A):A.size();return _(R,O[k])}catch(F){throw tu(F,"mean")}},"...":function(k){if(sd(k))throw new TypeError("Scalar values expected in function mean");return C(k)}});function C(A){var k,R=0;if(Ss(A,function(O){try{k=void 0===k?O:b(k,O),R++}catch(F){throw tu(F,"mean",O)}}),0===R)throw new Error("Cannot calculate the mean of an empty array");return _(k,R)}}),Rw="quantileSeq",$S=["typed","?bignumber","add","subtract","divide","multiply","partitionSelect","compare","isInteger","smaller","smallerEq","larger"],I_=re(Rw,$S,p=>{var{typed:m,bignumber:b,add:_,subtract:y,divide:C,multiply:A,partitionSelect:k,compare:R,isInteger:O,smaller:F,smallerEq:B,larger:H}=p,G=Kv({typed:m,isInteger:O});return m(Rw,{"Array | Matrix, number | BigNumber":(Le,de)=>te(Le,de,!1),"Array | Matrix, number | BigNumber, number":(Le,de,Te)=>J(Le,de,!1,Te,te),"Array | Matrix, number | BigNumber, boolean":te,"Array | Matrix, number | BigNumber, boolean, number":(Le,de,Te,De)=>J(Le,de,Te,De,te),"Array | Matrix, Array | Matrix":(Le,de)=>be(Le,de,!1),"Array | Matrix, Array | Matrix, number":(Le,de,Te)=>J(Le,de,!1,Te,be),"Array | Matrix, Array | Matrix, boolean":be,"Array | Matrix, Array | Matrix, boolean, number":(Le,de,Te,De)=>J(Le,de,Te,De,be)});function J(Le,de,Te,De,pe){return G(Le,De,Be=>pe(Be,de,Te))}function te(Le,de,Te){var De,pe=Le.valueOf();if(F(de,0))throw new Error("N/prob must be non-negative");if(B(de,1))return ct(de)?we(pe,de,Te):b(we(pe,de,Te));if(H(de,1)){if(!O(de))throw new Error("N must be a positive integer");if(H(de,4294967295))throw new Error("N must be less than or equal to 2^32-1, as that is the maximum length of an Array");var Be=_(de,1);De=[];for(var We=0;F(We,de);We++){var ke=C(We+1,Be);De.push(we(pe,ke,Te))}return ct(de)?De:b(De)}}function be(Le,de,Te){for(var De=Le.valueOf(),pe=de.valueOf(),Be=[],We=0;We<pe.length;++We)Be.push(we(De,pe[We],Te));return Be}function we(Le,de,Te){var De=ns(Le),pe=De.length;if(0===pe)throw new Error("Cannot calculate quantile of an empty sequence");var ze,et,Be=ct(de)?de*(pe-1):de.times(pe-1),We=ct(de)?Math.floor(Be):Be.floor().toNumber(),ke=ct(de)?Be%1:Be.minus(We);if(O(Be))return Te?De[Be]:k(De,ct(de)?Be:Be.valueOf());if(Te)ze=De[We],et=De[We+1];else{et=k(De,We+1),ze=De[We];for(var pt=0;pt<We;++pt)R(De[pt],ze)>0&&(ze=De[pt])}return _(A(ze,y(1,ke)),A(et,ke))}}),a0="unbiased",pa="variance",gv=["typed","add","subtract","multiply","divide","apply","isNaN"],A_=re(pa,gv,p=>{var{typed:m,add:b,subtract:_,multiply:y,divide:C,apply:A,isNaN:k}=p;return m(pa,{"Array | Matrix":function(B){return R(B,a0)},"Array | Matrix, string":R,"Array | Matrix, number | BigNumber":function(B,H){return O(B,H,a0)},"Array | Matrix, number | BigNumber, string":O,"...":function(B){return R(B,a0)}});function R(F,B){var H,G=0;if(0===F.length)throw new SyntaxError("Function variance requires one or more parameters (0 provided)");if(Ss(F,function(be){try{H=void 0===H?be:b(H,be),G++}catch(we){throw tu(we,"variance",be)}}),0===G)throw new Error("Cannot calculate variance of an empty array");var J=C(H,G);if(H=void 0,Ss(F,function(be){var we=_(be,J);H=void 0===H?y(we,we):b(H,y(we,we))}),k(H))return H;switch(B){case"uncorrected":return C(H,G);case"biased":return C(H,G+1);case"unbiased":var te=en(H)?H.mul(0):0;return 1===G?te:C(H,G-1);default:throw new Error('Unknown normalization "'+B+'". Choose "unbiased" (default), "uncorrected", or "biased".')}}function O(F,B,H){try{if(0===F.length)throw new SyntaxError("Function variance requires one or more parameters (0 provided)");return A(F,B,G=>R(G,H))}catch(G){throw tu(G,"variance")}}}),l0=["typed","add","divide","compare","partitionSelect"],wm=re("median",l0,p=>{var{typed:m,add:b,divide:_,compare:y,partitionSelect:C}=p;function A(O){try{var F=(O=ns(O.valueOf())).length;if(0===F)throw new Error("Cannot calculate median of an empty array");if(F%2==0){for(var B=F/2-1,H=C(O,B+1),G=O[B],J=0;J<B;++J)y(O[J],G)>0&&(G=O[J]);return R(G,H)}var te=C(O,(F-1)/2);return k(te)}catch(be){throw tu(be,"median")}}var k=m({"number | BigNumber | Complex | Unit":function(F){return F}}),R=m({"number | BigNumber | Complex | Unit, number | BigNumber | Complex | Unit":function(F,B){return _(b(F,B),2)}});return m("median",{"Array | Matrix":A,"Array | Matrix, number | BigNumber":function(F,B){throw new Error("median(A, dim) is not yet supported")},"...":function(F){if(sd(F))throw new TypeError("Scalar values expected in function median");return A(F)}})}),O_=["typed","matrix","mean","sqrt","sum","add","subtract","multiply","pow","divide"],Wb=re("corr",O_,p=>{var{typed:m,matrix:b,sqrt:_,sum:y,add:C,subtract:A,multiply:k,pow:R,divide:O}=p;return m("corr",{"Array, Array":function(G,J){return F(G,J)},"Matrix, Matrix":function(G,J){var te=F(G.toArray(),J.toArray());return Array.isArray(te)?b(te):te}});function F(H,G){var J=[];if(Array.isArray(H[0])&&Array.isArray(G[0])){if(H.length!==G.length)throw new SyntaxError("Dimension mismatch. Array A and B must have the same length.");for(var te=0;te<H.length;te++){if(H[te].length!==G[te].length)throw new SyntaxError("Dimension mismatch. Array A and B must have the same number of elements.");J.push(B(H[te],G[te]))}return J}if(H.length!==G.length)throw new SyntaxError("Dimension mismatch. Array A and B must have the same number of elements.");return B(H,G)}function B(H,G){var J=H.length,te=y(H),be=y(G),we=H.reduce((pe,Be,We)=>C(pe,k(Be,G[We])),0),Le=y(H.map(pe=>R(pe,2))),de=y(G.map(pe=>R(pe,2))),Te=A(k(J,we),k(te,be)),De=_(k(A(k(J,Le),R(te,2)),A(k(J,de),R(be,2))));return O(Te,De)}}),WS=["typed","add","multiply","Complex","divide","matrix"],c0=re("freqz",WS,p=>{var{typed:m,add:b,multiply:_,Complex:y,divide:C,matrix:A}=p;return m("freqz",{"Array, Array":function(F,B){return k(F,B,R(512))},"Array, Array, Array":function(F,B,H){return k(F,B,H)},"Array, Array, number":function(F,B,H){if(H<0)throw new Error("w must be a positive number");return k(F,B,R(H))},"Matrix, Matrix":function(F,B){var H=R(512),{w:G,h:J}=k(F.valueOf(),B.valueOf(),H);return{w:A(G),h:A(J)}},"Matrix, Matrix, Matrix":function(F,B,H){var{h:G}=k(F.valueOf(),B.valueOf(),H.valueOf());return{h:A(G),w:A(H)}},"Matrix, Matrix, number":function(F,B,H){if(H<0)throw new Error("w must be a positive number");var G=R(H),{h:J}=k(F.valueOf(),B.valueOf(),G);return{h:A(J),w:A(G)}}});function k(O,F,B){for(var H=[],G=[],J=0;J<B.length;J++){for(var te=y(0,0),be=y(0,0),we=0;we<O.length;we++)te=b(te,_(O[we],y(Math.cos(-we*B[J]),Math.sin(-we*B[J]))));for(var Le=0;Le<F.length;Le++)be=b(be,_(F[Le],y(Math.cos(-Le*B[J]),Math.sin(-Le*B[J]))));H.push(te),G.push(be)}for(var de=[],Te=0;Te<H.length;Te++)de.push(C(H[Te],G[Te]));return{h:de,w:B}}function R(O){for(var F=[],B=0;B<O;B++)F.push(B/O*Math.PI);return F}}),xT=["typed","abs","map","median","subtract"],zb=re("mad",xT,p=>{var{typed:m,abs:b,map:_,median:y,subtract:C}=p;return m("mad",{"Array | Matrix":A,"...":function(R){return A(R)}});function A(k){if(0===(k=ns(k.valueOf())).length)throw new Error("Cannot calculate median absolute deviation (mad) of an empty array");try{var R=y(k);return y(_(k,function(O){return b(C(O,R))}))}catch(O){throw O instanceof TypeError&&O.message.includes("median")?new TypeError(O.message.replace("median","mad")):tu(O,"mad")}}}),c=["typed","map","sqrt","variance"],g=re("std",c,p=>{var{typed:m,map:b,sqrt:_,variance:y}=p;return m("std",{"Array | Matrix":C,"Array | Matrix, string":C,"Array | Matrix, number | BigNumber":C,"Array | Matrix, number | BigNumber, string":C,"...":function(k){return C(k)}});function C(A,k){if(0===A.length)throw new SyntaxError("Function std requires one or more parameters (0 provided)");try{var R=y.apply(null,arguments);return Mt(R)?b(R,_):_(R)}catch(O){throw O instanceof TypeError&&O.message.includes(" variance")?new TypeError(O.message.replace(" variance"," std")):O}}}),a="zeta",u=["typed","config","multiply","pow","divide","factorial","equal","smallerEq","isNegative","gamma","sin","subtract","add","?Complex","?BigNumber","pi"],x=re(a,u,p=>{var{typed:m,config:b,multiply:_,pow:y,divide:C,factorial:A,equal:k,smallerEq:R,isNegative:O,gamma:F,sin:B,subtract:H,add:G,Complex:J,BigNumber:te,pi:be}=p;return m(a,{number:pe=>we(pe,Be=>Be,()=>20),BigNumber:pe=>we(pe,Be=>new te(Be),()=>Math.abs(Math.log10(b.relTol))),Complex:function Le(pe){return 0===pe.re&&0===pe.im?new J(-.5):1===pe.re?new J(NaN,NaN):pe.re===1/0&&0===pe.im?new J(1):pe.im===1/0||pe.re===-1/0?new J(NaN,NaN):de(pe,Be=>Be,Be=>Math.round(19.5+.9*Math.abs(Be.im)),Be=>Be.re)}});function we(pe,Be,We){return k(pe,0)?Be(-.5):k(pe,1)?Be(NaN):isFinite(pe)?de(pe,Be,We,ke=>ke):O(pe)?Be(NaN):Be(1)}function de(pe,Be,We,ke){var ze=We(pe);if(ke(pe)>-(ze-1)/2)return function De(pe,Be,We){for(var ke=C(1,_(Te(We(0),Be),H(1,y(2,H(1,pe))))),ze=We(0),et=We(1);R(et,Be);et=G(et,1))ze=G(ze,C(_((-1)**(et-1),Te(et,Be)),y(et,pe)));return _(ke,ze)}(pe,Be(ze),Be);var et=_(y(2,pe),y(Be(be),H(pe,1)));return et=_(et,B(_(C(Be(be),2),pe))),et=_(et,F(H(1,pe))),_(et,de(H(1,pe),Be,We,ke))}function Te(pe,Be){for(var We=pe,ke=pe;R(ke,Be);ke=G(ke,1)){var ze=C(_(A(G(Be,H(ke,1))),y(4,ke)),_(A(H(Be,ke)),A(_(2,ke))));We=G(We,ze)}return _(Be,We)}}),I="norm",K=["typed","abs","add","pow","conj","sqrt","multiply","equalScalar","larger","smaller","matrix","ctranspose","eigs"],ye=re(I,K,p=>{var{typed:m,abs:b,add:_,pow:y,conj:C,sqrt:A,multiply:k,equalScalar:R,larger:O,smaller:F,matrix:B,ctranspose:H,eigs:G}=p;return m(I,{number:Math.abs,Complex:function(We){return We.abs()},BigNumber:function(We){return We.abs()},boolean:function(We){return Math.abs(We)},Array:function(We){return pe(B(We),2)},Matrix:function(We){return pe(We,2)},"Array, number | BigNumber | string":function(We,ke){return pe(B(We),ke)},"Matrix, number | BigNumber | string":function(We,ke){return pe(We,ke)}});function pe(Be,We){var ke=Be.size();if(1===ke.length)return function be(Be,We){if(We===Number.POSITIVE_INFINITY||"inf"===We)return function J(Be){var We=0;return Be.forEach(function(ke){var ze=b(ke);O(ze,We)&&(We=ze)},!0),We}(Be);if(We===Number.NEGATIVE_INFINITY||"-inf"===We)return function te(Be){var We;return Be.forEach(function(ke){var ze=b(ke);(!We||F(ze,We))&&(We=ze)},!0),We||0}(Be);if("fro"===We)return pe(Be,2);if("number"==typeof We&&!isNaN(We)){if(!R(We,0)){var ke=0;return Be.forEach(function(ze){ke=_(y(b(ze),We),ke)},!0),y(ke,1/We)}return Number.POSITIVE_INFINITY}throw new Error("Unsupported parameter value")}(Be,We);if(2===ke.length){if(ke[0]&&ke[1])return function De(Be,We){if(1===We)return function Le(Be){var We=[],ke=0;return Be.forEach(function(ze,et){var pt=et[1],$t=_(We[pt]||0,b(ze));O($t,ke)&&(ke=$t),We[pt]=$t},!0),ke}(Be);if(We===Number.POSITIVE_INFINITY||"inf"===We)return function Te(Be){var We=[],ke=0;return Be.forEach(function(ze,et){var pt=et[0],$t=_(We[pt]||0,b(ze));O($t,ke)&&(ke=$t),We[pt]=$t},!0),ke}(Be);if("fro"===We)return function we(Be){var We=0;return Be.forEach(function(ke,ze){We=_(We,k(ke,C(ke)))}),b(A(We))}(Be);if(2===We)return function de(Be){var We=Be.size();if(We[0]!==We[1])throw new RangeError("Invalid matrix dimensions");var ke=H(Be),ze=k(ke,Be),et=G(ze).values.toArray();return b(A(et[et.length-1]))}(Be);throw new Error("Unsupported parameter value "+We)}(Be,We);throw new RangeError("Invalid matrix dimensions")}}}),Ye="rotationMatrix",$e=["typed","config","multiplyScalar","addScalar","unaryMinus","norm","matrix","BigNumber","DenseMatrix","SparseMatrix","cos","sin"],ht=re(Ye,$e,p=>{var{typed:m,config:b,multiplyScalar:_,addScalar:y,unaryMinus:C,norm:A,BigNumber:k,matrix:R,DenseMatrix:O,SparseMatrix:F,cos:B,sin:H}=p;return m(Ye,{"":function(){return"Matrix"===b.matrix?R([]):[]},string:function(de){return R(de)},"number | BigNumber | Complex | Unit":function(de){return G(de,"Matrix"===b.matrix?"dense":void 0)},"number | BigNumber | Complex | Unit, string":function(de,Te){return G(de,Te)},"number | BigNumber | Complex | Unit, Array":function(de,Te){var De=R(Te);return J(De),we(de,De,void 0)},"number | BigNumber | Complex | Unit, Matrix":function(de,Te){J(Te);var De=Te.storage()||("Matrix"===b.matrix?"dense":void 0);return we(de,Te,De)},"number | BigNumber | Complex | Unit, Array, string":function(de,Te,De){var pe=R(Te);return J(pe),we(de,pe,De)},"number | BigNumber | Complex | Unit, Matrix, string":function(de,Te,De){return J(Te),we(de,Te,De)}});function G(Le,de){var De=en(Le)?new k(-1):-1,pe=B(Le),Be=H(Le);return be([[pe,_(De,Be)],[Be,pe]],de)}function J(Le){var de=Le.size();if(de.length<1||3!==de[0])throw new RangeError("Vector must be of dimensions 1x3")}function te(Le){return Le.reduce((de,Te)=>_(de,Te))}function be(Le,de){if(de){if("sparse"===de)return new F(Le);if("dense"===de)return new O(Le);throw new TypeError('Unknown matrix type "'.concat(de,'"'))}return Le}function we(Le,de,Te){var De=A(de);if(0===De)throw new RangeError("Rotation around zero vector");var pe=en(Le)?k:null,Be=pe?new pe(1):1,We=pe?new pe(-1):-1,ke=pe?new pe(de.get([0])/De):de.get([0])/De,ze=pe?new pe(de.get([1])/De):de.get([1])/De,et=pe?new pe(de.get([2])/De):de.get([2])/De,pt=B(Le),$t=y(Be,C(pt)),Zt=H(Le);return be([[y(pt,te([ke,ke,$t])),y(te([ke,ze,$t]),te([We,et,Zt])),y(te([ke,et,$t]),te([ze,Zt]))],[y(te([ke,ze,$t]),te([et,Zt])),y(pt,te([ze,ze,$t])),y(te([ze,et,$t]),te([We,ke,Zt]))],[y(te([ke,et,$t]),te([We,ze,Zt])),y(te([ze,et,$t]),te([ke,Zt])),y(pt,te([et,et,$t]))]],Te)}}),zt=["typed","matrix","identity","multiply","qr","norm","subtract"],yn=re("schur",zt,p=>{var{typed:m,matrix:b,identity:_,multiply:y,qr:C,norm:A,subtract:k}=p;return m("schur",{Array:function(F){var B=R(b(F));return{U:B.U.valueOf(),T:B.T.valueOf()}},Matrix:function(F){return R(F)}});function R(O){var J,F=O.size()[0],B=O,H=_(F),G=0;do{J=B;var te=C(B),be=te.Q;if(B=y(te.R,be),H=y(H,be),G++>100)break}while(A(k(B,J))>1e-4);return{U:H,T:B}}}),pr=["typed","multiply","rotationMatrix"],si=re("rotate",pr,p=>{var{typed:m,multiply:b,rotationMatrix:_}=p;return m("rotate",{"Array , number | BigNumber | Complex | Unit":function(A,k){return y(A,2),b(_(k),A).toArray()},"Matrix , number | BigNumber | Complex | Unit":function(A,k){return y(A,2),b(_(k),A)},"Array, number | BigNumber | Complex | Unit, Array | Matrix":function(A,k,R){return y(A,3),b(_(k,R),A)},"Matrix, number | BigNumber | Complex | Unit, Array | Matrix":function(A,k,R){return y(A,3),b(_(k,R),A)}});function y(C,A){var k=Array.isArray(C)?Bs(C):C.size();if(k.length>2)throw new RangeError("Vector must be of dimensions 1x".concat(A));if(2===k.length&&1!==k[1])throw new RangeError("Vector must be of dimensions 1x".concat(A));if(k[0]!==A)throw new RangeError("Vector must be of dimensions 1x".concat(A))}}),hr="sylvester",_o=["typed","schur","matrixFromColumns","matrix","multiply","range","concat","transpose","index","subset","add","subtract","identity","lusolve","abs"],jr=re(hr,_o,p=>{var{typed:m,schur:b,matrixFromColumns:_,matrix:y,multiply:C,range:A,concat:k,transpose:R,index:O,subset:F,add:B,subtract:H,identity:G,lusolve:J,abs:te}=p;return m(hr,{"Matrix, Matrix, Matrix":be,"Array, Matrix, Matrix":function(Le,de,Te){return be(y(Le),de,Te)},"Array, Array, Matrix":function(Le,de,Te){return be(y(Le),y(de),Te)},"Array, Matrix, Array":function(Le,de,Te){return be(y(Le),de,y(Te))},"Matrix, Array, Matrix":function(Le,de,Te){return be(Le,y(de),Te)},"Matrix, Array, Array":function(Le,de,Te){return be(Le,y(de),y(Te))},"Matrix, Matrix, Array":function(Le,de,Te){return be(Le,de,y(Te))},"Array, Array, Array":function(Le,de,Te){return be(y(Le),y(de),y(Te)).toArray()}});function be(we,Le,de){for(var Te=Le.size()[0],De=we.size()[0],pe=b(we),Be=pe.T,We=pe.U,ke=b(C(-1,Le)),ze=ke.T,et=ke.U,pt=C(C(R(We),de),et),$t=A(0,De),Zt=[],Kt=($r,Io)=>k($r,Io,1),lt=($r,Io)=>k($r,Io,0),st=0;st<Te;st++)if(st<Te-1&&te(F(ze,O(st+1,st)))>1e-5){for(var En=lt(F(pt,O($t,st)),F(pt,O($t,st+1))),_t=0;_t<st;_t++)En=B(En,lt(C(Zt[_t],F(ze,O(_t,st))),C(Zt[_t],F(ze,O(_t,st+1)))));var di=C(G(De),C(-1,F(ze,O(st,st)))),ki=C(G(De),C(-1,F(ze,O(st+1,st)))),Xn=C(G(De),C(-1,F(ze,O(st,st+1)))),_n=C(G(De),C(-1,F(ze,O(st+1,st+1)))),Ni=lt(Kt(B(Be,di),ki),Kt(Xn,B(Be,_n))),kr=J(Ni,En);Zt[st]=kr.subset(O(A(0,De),0)),Zt[st+1]=kr.subset(O(A(De,2*De),0)),st++}else{for(var Pi=F(pt,O($t,st)),nr=0;nr<st;nr++)Pi=B(Pi,C(Zt[nr],F(ze,O(nr,st))));var Sr=F(ze,O(st,st)),ir=H(Be,C(Sr,G(De)));Zt[st]=J(ir,Pi)}var lr=y(_(...Zt));return C(We,C(lr,R(et)))}}),lo=["typed","matrix","sylvester","multiply","transpose"],mo=re("lyap",lo,p=>{var{typed:m,matrix:b,sylvester:_,multiply:y,transpose:C}=p;return m("lyap",{"Matrix, Matrix":function(k,R){return _(k,C(k),y(-1,R))},"Array, Matrix":function(k,R){return _(b(k),C(b(k)),y(-1,R))},"Matrix, Array":function(k,R){return _(k,C(b(k)),b(y(-1,R)))},"Array, Array":function(k,R){return _(b(k),C(b(k)),b(y(-1,R))).toArray()}})}),br=$i({config:Sn}),yo=nd({}),ml=qs({BigNumber:br,config:Sn}),Ca=md({}),oo=ia({BigNumber:br,config:Sn}),Ba=bg({}),Co=id({Complex:yo}),us=gd({BigNumber:br,config:Sn}),Rr=su({BigNumber:br,config:Sn}),xo=xa({BigNumber:br,config:Sn}),Jr=Ch({}),No=Eu({BigNumber:br,config:Sn}),Hr=Ld({}),ys=Xc({BigNumber:br,config:Sn}),Ns=If({}),Ml=xr({}),Nu=vd({BigNumber:br,config:Sn}),Rd=Ie({BigNumber:br,config:Sn}),ru=Lc({BigNumber:br,config:Sn}),wd=Su({}),jl=hu({}),Os=Nf({Matrix:Jr}),Cr=Ue({BigNumber:br,config:Sn}),So=Bu({BigNumber:br,config:Sn}),Po=Pu({BigNumber:br,config:Sn}),wi=io({}),ha=Vu({BigNumber:br,config:Sn}),dn=Xl({BigNumber:br,Complex:yo,DenseMatrix:Os,Fraction:Ba}),Ol=yc({BigNumber:br,config:Sn}),Fa=ef({typed:dn}),hs=wg({Complex:yo,config:Sn,typed:dn}),Ka=Tr({BigNumber:br,typed:dn}),mg=ka({BigNumber:br,Complex:yo,config:Sn,typed:dn}),Du=oh({typed:dn}),Bw=vf({typed:dn}),F_=Bm({BigNumber:br,Complex:yo,config:Sn,typed:dn}),Gb=Ko({typed:dn}),LC=wc({typed:dn}),N_=Mh({Complex:yo,config:Sn,typed:dn}),ST=nD({typed:dn}),HS=a1({typed:dn}),R_=I0({typed:dn}),kC=nf({typed:dn}),Kb=cD({typed:dn}),uf=Fv({Complex:yo,typed:dn}),L_=K_({typed:dn}),PC=l1({typed:dn}),AA=Tg({BigNumber:br,typed:dn}),QM=Vd({BigNumber:br,typed:dn}),BC=A0({typed:dn}),nl=Rv({config:Sn,typed:dn}),OA=Q_({typed:dn}),ET=F0({typed:dn}),FA=Um({Complex:yo,typed:dn}),zS=mD({typed:dn}),VC=$m({typed:dn}),YM=Oh({typed:dn}),Vw=_D({typed:dn}),jw=p1({typed:dn}),TT=Pv({format:Vw,typed:dn}),jC=Og({typed:dn}),zp=rm({typed:dn}),vv=Bv({config:Sn,typed:dn}),u0=ad({config:Sn,typed:dn}),Kh=Ng({equalScalar:nl,typed:dn}),XM=Is({BigNumber:br,config:Sn}),MT=B0({Complex:yo,typed:dn}),ZM=ty({Complex:yo,config:Sn,typed:dn}),GS=hl({Complex:yo,config:Sn,typed:dn}),d0=Ou({typed:dn}),Ku=m1({typed:dn}),Cs=Wm({typed:dn}),Ul=xD({typed:dn}),JM=Lp({format:Vw,typed:dn}),xd=v1({config:Sn,typed:dn}),ua=$v({typed:dn}),yp=Lh({config:Sn,typed:dn}),UC=SD({typed:dn}),Wa=$0({BigNumber:br,typed:dn}),Sf=Hm({BigNumber:br,Fraction:Ba,complex:uf,typed:dn}),wl=lm({typed:dn}),$l=H0({Matrix:Jr,equalScalar:nl,typed:dn}),eI=kg({typed:dn}),NA=TD({typed:dn}),f0=G0({typed:dn}),gh=Cd({typed:dn}),xm=zv({typed:dn}),Gp=rf({typed:dn}),p0=D1({Complex:yo,config:Sn,typed:dn}),tI=w1({BigNumber:br,typed:dn}),h0=Kv({isInteger:zp,typed:dn}),IT=sy({BigNumber:br,Complex:yo,config:Sn,typed:dn}),Gf=qv({BigNumber:br,typed:dn}),$C=Q0({typed:dn}),WC=FD({typed:dn}),_v=T1({BigNumber:br,typed:dn}),Kp=M1({typed:dn}),HC=ND({typed:dn}),zC=fp({config:Sn,typed:dn}),GC=Qv({BigNumber:br,typed:dn}),qb=ay({typed:dn}),Uw=Z0({SparseMatrix:$l,typed:dn}),vh=zm({Complex:yo,config:Sn,typed:dn}),KS=Zv({typed:dn}),$w=Vg({typed:dn}),bp=jg({typed:dn}),Qb=Ug({BigNumber:br,Complex:yo,config:Sn,typed:dn}),qS=$g({format:Vw,typed:dn}),KC=jd({BigNumber:br,typed:dn}),k_=pp({Fraction:Ba,typed:dn}),N=tp({typed:dn}),$=Wg({DenseMatrix:Os,Matrix:Jr,SparseMatrix:$l,typed:dn}),ge=cl({isZero:Kh,matrix:$,typed:dn}),nt=np({isNaN:Kp,isNumeric:N,typed:dn}),Lt=N1({bignumber:Gf,fraction:k_,number:Ul}),bn=$d({config:Sn,multiplyScalar:Ku,numeric:Lt,typed:dn}),ui=Zu({isInteger:zp,matrix:$,typed:dn}),Hi=bf({matrix:$,config:Sn,typed:dn}),yr=Hg({matrix:$,typed:dn}),fs=Kr({BigNumber:br,config:Sn,matrix:$,typed:dn}),co=jD({BigNumber:br,config:Sn,matrix:$,typed:dn}),Do=R1({Complex:yo,config:Sn,typed:dn}),Ts=mp({BigNumber:br,Complex:yo,Fraction:Ba,config:Sn,isNegative:vv,matrix:$,typed:dn,unaryMinus:bp}),os=Gm({isInteger:zp,matrix:$,typed:dn}),gl=n_({prod:bn,size:Hi,typed:dn}),Xs=Pa({conj:L_,transpose:yr,typed:dn}),il=i_({DenseMatrix:Os,SparseMatrix:$l,matrix:$,typed:dn}),Da=k1({numeric:Lt,typed:dn}),fd=Kg({DenseMatrix:Os,concat:os,divideScalar:Da,equalScalar:nl,matrix:$,typed:dn}),zd=V1({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),Sm=U1({isNumeric:N,typed:dn}),Ef=$a({BigNumber:br,DenseMatrix:Os,SparseMatrix:$l,config:Sn,matrix:$,typed:dn}),df=kh({matrix:$,multiplyScalar:Ku,typed:dn}),Cp=fy({DenseMatrix:Os,concat:os,config:Sn,matrix:$,typed:dn}),Yb=py({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn,zeros:co}),Em=my({DenseMatrix:Os,divideScalar:Da,equalScalar:nl,matrix:$,multiplyScalar:Ku,subtractScalar:gh,typed:dn}),AT=Oa({flatten:VC,matrix:$,size:Hi,typed:dn}),dO=nS({BigNumber:br,concat:os,equalScalar:nl,matrix:$,typed:dn}),nI=ob({BigNumber:br,config:Sn,matrix:$,typed:dn}),RA=mm({addScalar:Du,complex:uf,conj:L_,divideScalar:Da,equal:zd,identity:Ef,isZero:Kh,matrix:$,multiplyScalar:Ku,sign:Sf,sqrt:vh,subtractScalar:gh,typed:dn,unaryMinus:bp,zeros:co}),iI=W1({config:Sn,matrix:$}),Ww=H1({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn,zeros:co}),Xb=z1({BigNumber:br,DenseMatrix:Os,config:Sn,equalScalar:nl,matrix:$,typed:dn,zeros:co}),Dp=jf({DenseMatrix:Os,concat:os,config:Sn,matrix:$,typed:dn}),zc=Vp({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,subtractScalar:gh,typed:dn,unaryMinus:bp}),fO=s_({concat:os,matrix:$,typed:dn}),QS=_y({config:Sn,numeric:Lt,typed:dn}),gg=yy({DenseMatrix:Os,divideScalar:Da,equalScalar:nl,matrix:$,multiplyScalar:Ku,subtractScalar:gh,typed:dn}),yv=Zg({DenseMatrix:Os,concat:os,matrix:$,typed:dn}),Ha=db({DenseMatrix:Os,SparseMatrix:$l,addScalar:Du,concat:os,equalScalar:nl,matrix:$,typed:dn}),pO=a_({BigNumber:br,DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),hO=Vh({concat:os,equalScalar:nl,matrix:$,typed:dn}),LN=by({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),kN=gm({DenseMatrix:Os,concat:os,matrix:$,typed:dn}),PN=c_({addScalar:Du,combinations:Kb,divideScalar:Da,isInteger:zp,isNegative:vv,multiplyScalar:Ku,typed:dn}),Hw=Dy({BigNumber:br,DenseMatrix:Os,Fraction:Ba,concat:os,config:Sn,equalScalar:nl,matrix:$,typed:dn}),rI=ev({concat:os,matrix:$,typed:dn}),OT=xy({add:Ha,typed:dn,unaryPlus:QS}),LA=mc({equal:zd,typed:dn}),mO=Sy({matrix:$,number:Ul,subtract:zc,typed:dn}),BN=gb({abs:Fa,addScalar:Du,deepEqual:LA,divideScalar:Da,multiplyScalar:Ku,sqrt:vh,subtractScalar:gh,typed:dn}),oI=jh({addScalar:Du,conj:L_,multiplyScalar:Ku,size:Hi,typed:dn}),gO=Qs({compareText:rI,isZero:Kh,typed:dn}),kA=Xm({DenseMatrix:Os,config:Sn,equalScalar:nl,matrix:$,round:Xb,typed:dn,zeros:co}),FT=eC({BigNumber:br,DenseMatrix:Os,concat:os,config:Sn,equalScalar:nl,matrix:$,round:Xb,typed:dn,zeros:co}),VN=Ty({abs:Fa,addScalar:Du,divideScalar:Da,isPositive:u0,multiplyScalar:Ku,smaller:Dp,sqrt:vh,typed:dn}),PA=_b({DenseMatrix:Os,smaller:Dp}),qp=tv({ImmutableDenseMatrix:PA,getMatrixDataType:jw}),_h=My({DenseMatrix:Os,concat:os,config:Sn,matrix:$,typed:dn}),sI=u_({Complex:yo,config:Sn,divideScalar:Da,typed:dn}),vO=Ay({DenseMatrix:Os,divideScalar:Da,equalScalar:nl,matrix:$,multiplyScalar:Ku,subtractScalar:gh,typed:dn}),BA=Oy({flatten:VC,matrix:$,size:Hi,typed:dn}),_O=rC({config:Sn,numeric:Lt,smaller:Dp,typed:dn}),VA=Ey({DenseMatrix:Os,concat:os,config:Sn,equalScalar:nl,matrix:$,round:Xb,typed:dn,zeros:co}),Gc=bb({addScalar:Du,dot:oI,equalScalar:nl,matrix:$,multiplyScalar:Ku,typed:dn}),yO=ng({Complex:yo,config:Sn,divideScalar:Da,typed:dn}),bO=rv({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),aI=Db({compare:Hw,isNaN:Kp,isNumeric:N,typed:dn}),jA=d_({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn,zeros:co}),jN=h_({SparseMatrix:$l,abs:Fa,add:Ha,divideScalar:Da,larger:_h,largerEq:Cp,multiply:Gc,subtract:zc,transpose:yr,typed:dn}),vg=ov({add:Ha,matrix:$,typed:dn,zeros:co}),NT=ig({add:Ha,config:Sn,numeric:Lt,typed:dn}),CO=vm({add:Ha,matrix:$,typed:dn}),RT=Fs({DenseMatrix:Os,divideScalar:Da,equalScalar:nl,matrix:$,multiplyScalar:Ku,subtractScalar:gh,typed:dn}),DO=rg({Complex:yo,add:Ha,multiply:Gc,number:Ul,typed:dn}),lI=hC({DenseMatrix:Os,config:Sn,equalScalar:nl,matrix:$,round:Xb,typed:dn,zeros:co}),P_=$h({compare:Hw,typed:dn}),wO=wS({addScalar:Du,combinations:Kb,isInteger:zp,isNegative:vv,isPositive:u0,larger:_h,typed:dn}),xO=v_({matrix:$,multiply:Gc,subtract:zc,typed:dn}),SO=vw({divideScalar:Da,isZero:Kh,matrix:$,multiply:Gc,subtractScalar:gh,typed:dn,unaryMinus:bp}),cI=Mb({concat:os,equalScalar:nl,matrix:$,multiplyScalar:Ku,typed:dn}),UN=Ib({larger:_h,smaller:Dp}),$N=Ab({Complex:yo,DenseMatrix:Os,ceil:lI,equalScalar:nl,floor:kA,matrix:$,typed:dn,zeros:co}),EO=By({Index:qp,typed:dn}),TO=og({abs:Fa,add:Ha,addScalar:Du,config:Sn,divideScalar:Da,equalScalar:nl,flatten:VC,isNumeric:N,isZero:Kh,matrix:$,multiply:Gc,multiplyScalar:Ku,smaller:Dp,subtract:zc,typed:dn}),uI=Cw({BigNumber:br,add:Ha,config:Sn,equal:zd,isInteger:zp,mod:VA,smaller:Dp,typed:dn,xgcd:fs}),WN=Vy({concat:os,equalScalar:nl,matrix:$,typed:dn}),HN=jy({Complex:yo,config:Sn,divideScalar:Da,log:sI,typed:dn}),LT=Uy({config:Sn,larger:_h,numeric:Lt,typed:dn}),zN=Fb({DenseMatrix:Os,Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),dI=xw({DenseMatrix:Os,Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),fI=Wh({Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),UA=sg({Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),zw=Ys({DenseMatrix:Os,concat:os,config:Sn,matrix:$,typed:dn}),GN=$f({compare:Hw,compareNatural:P_,matrix:$,typed:dn}),KN=Rb({DenseMatrix:Os,concat:os,config:Sn,equalScalar:nl,matrix:$,typed:dn}),MO=Wf({concat:os,equalScalar:nl,matrix:$,not:Cs,typed:dn,zeros:co}),m0=nu({bignumber:Gf,matrix:$,add:Ha,config:Sn,isPositive:u0,larger:_h,largerEq:Cp,smaller:Dp,smallerEq:zw,typed:dn}),pI=ym({Index:qp,matrix:$,range:m0,typed:dn}),hI=Hh({DenseMatrix:Os,Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),Gw=cd({Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),IO=hh({Index:qp,concat:os,setDifference:hI,size:Hi,subset:vg,typed:dn}),AO=C_({FibonacciHeap:UN,addScalar:Du,equalScalar:nl}),$A=zy({Index:qp,matrix:$,range:m0,typed:dn}),g0=Ju({abs:Fa,addScalar:Du,det:SO,divideScalar:Da,identity:Ef,matrix:$,multiply:Gc,typed:dn,unaryMinus:bp}),kT=Gy({DenseMatrix:Os,Spa:AO,SparseMatrix:$l,abs:Fa,addScalar:Du,divideScalar:Da,equalScalar:nl,larger:_h,matrix:$,multiplyScalar:Ku,subtractScalar:gh,typed:dn,unaryMinus:bp}),Kw=Jl({Complex:yo,add:Ha,ctranspose:Xs,deepEqual:LA,divideScalar:Da,dot:oI,dotDivide:fd,equal:zd,inv:g0,matrix:$,multiply:Gc,typed:dn}),bv=zh({Complex:yo,config:Sn,fraction:k_,identity:Ef,inv:g0,matrix:$,multiply:Gc,number:Ul,typed:dn}),mI=w_({DenseMatrix:Os,Index:qp,compareNatural:P_,size:Hi,subset:vg,typed:dn}),qC=fg({Index:qp,concat:os,setIntersect:mI,setSymDifference:IO,size:Hi,subset:vg,typed:dn}),qN=pg({abs:Fa,add:Ha,identity:Ef,inv:g0,map:d0,max:LT,multiply:Gc,size:Hi,sqrt:vh,subtract:zc,typed:dn}),Ta=cf({BigNumber:br,Complex:yo,Fraction:Ba,abs:Fa,addScalar:Du,config:Sn,divideScalar:Da,equal:zd,fix:$N,format:Vw,isNumeric:N,multiplyScalar:Ku,number:Ul,pow:bv,round:Xb,subtractScalar:gh}),QN=Pc({BigNumber:br,Unit:Ta,config:Sn}),WA=rn({BigNumber:br,Unit:Ta,config:Sn}),HA=ne({BigNumber:br,Unit:Ta,config:Sn}),YN=Bc({BigNumber:br,Unit:Ta,config:Sn}),YS=rt({BigNumber:br,Unit:Ta,config:Sn}),zA=pf({BigNumber:br,Unit:Ta,config:Sn}),XN=ju({BigNumber:br,Unit:Ta,config:Sn}),ZN=Qo({BigNumber:br,Unit:Ta,config:Sn}),PT=iu({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,pow:bv,typed:dn}),JN=Td({BigNumber:br,Unit:Ta,config:Sn}),gI=Yl({BigNumber:br,Unit:Ta,config:Sn}),vI=S_({abs:Fa,add:Ha,identity:Ef,inv:g0,multiply:Gc,typed:dn}),Tm=Ut({BigNumber:br,Unit:Ta,config:Sn}),GA=dd({addScalar:Du,ceil:lI,conj:L_,divideScalar:Da,dotDivide:fd,exp:ET,i:Co,log2:GS,matrix:$,multiplyScalar:Ku,pow:bv,tau:ru,typed:dn}),_I=kb({BigNumber:br,Complex:yo,config:Sn,multiplyScalar:Ku,pow:bv,typed:dn}),eR=kc({BigNumber:br,Unit:Ta,config:Sn}),XS=La({BigNumber:br,Unit:Ta,config:Sn}),ZS=hv({conj:L_,dotDivide:fd,fft:GA,typed:dn}),tR=Re({BigNumber:br,Unit:Ta,config:Sn}),nR=Kn({BigNumber:br,Unit:Ta,config:Sn}),KA=kd({BigNumber:br,Unit:Ta,config:Sn}),JS=Si({BigNumber:br,Unit:Ta,config:Sn}),OO=Ce({BigNumber:br,Unit:Ta,config:Sn}),iR=ll({BigNumber:br,Unit:Ta,config:Sn}),rR=Dt({BigNumber:br,Unit:Ta,config:Sn}),qA=Hl({BigNumber:br,Unit:Ta,config:Sn}),FO=rs({BigNumber:br,Unit:Ta,config:Sn}),NO=dc({BigNumber:br,Unit:Ta,config:Sn}),oR=vs({BigNumber:br,Unit:Ta,config:Sn}),RO=Sa({BigNumber:br,Unit:Ta,config:Sn}),sR=uc({BigNumber:br,Unit:Ta,config:Sn}),Ek=$o({BigNumber:br,Unit:Ta,config:Sn}),Tk=Ze({BigNumber:br,Unit:Ta,config:Sn}),Mk=Ed({BigNumber:br,Unit:Ta,config:Sn}),Ik=kt({BigNumber:br,Unit:Ta,config:Sn}),LO=Mc({BigNumber:br,Unit:Ta,config:Sn}),yI=Pe({BigNumber:br,Unit:Ta,config:Sn}),aR=mn({BigNumber:br,Unit:Ta,config:Sn}),lR=mv({Unit:Ta,typed:dn}),Kf=xC({divideScalar:Da,equalScalar:nl,inv:g0,matrix:$,multiply:Gc,typed:dn}),eE=rr({BigNumber:br,Unit:Ta,config:Sn}),BT=Dd({gamma:_I,typed:dn}),cR=Rn({BigNumber:br,Unit:Ta,config:Sn}),kO=Yr({BigNumber:br,Unit:Ta,config:Sn}),uR=hf({BigNumber:br,Unit:Ta,config:Sn}),dR=EC({DenseMatrix:Os,lsolve:Em,lup:kT,matrix:$,slu:jN,typed:dn,usolve:gg}),fR=_e({BigNumber:br,Unit:Ta,config:Sn}),PO=oi({BigNumber:br,Unit:Ta,config:Sn}),pR=Jy({add:Ha,divide:Kf,factorial:BT,isInteger:zp,isPositive:u0,multiply:Gc,typed:dn}),hR=e0({factorial:BT,typed:dn}),tE=ls({BigNumber:br,Unit:Ta,config:Sn}),BO=t0({add:Ha,cbrt:Ts,divide:Kf,equalScalar:nl,im:jC,isZero:Kh,multiply:Gc,re:UC,sqrt:vh,subtract:zc,typeOf:Gp,typed:dn,unaryMinus:bp}),VO=Vb({compareNatural:P_,typed:dn}),jO=IC({abs:Fa,add:Ha,bignumber:Gf,divide:Kf,isNegative:vv,isPositive:u0,larger:_h,map:d0,matrix:$,max:LT,multiply:Gc,smaller:Dp,subtract:zc,typed:dn,unaryMinus:bp}),QA=OC({bignumber:Gf,addScalar:Du,combinations:Kb,divideScalar:Da,factorial:BT,isInteger:zp,isNegative:vv,larger:_h,multiplyScalar:Ku,number:Ul,pow:bv,subtractScalar:gh,typed:dn}),UO=mh({Unit:Ta,typed:dn}),mR=r0({addScalar:Du,isInteger:zp,isNegative:vv,stirlingS2:QA,typed:dn}),bI=jb({abs:Fa,add:Ha,addScalar:Du,atan:LC,bignumber:Gf,column:$A,complex:uf,config:Sn,cos:PC,diag:il,divideScalar:Da,dot:oI,equal:zd,flatten:VC,im:jC,inv:g0,larger:_h,matrix:$,matrixFromColumns:AT,multiply:Gc,multiplyScalar:Ku,number:Ul,qr:RA,re:UC,reshape:ui,sin:wl,size:Hi,smaller:Dp,sqrt:vh,subtract:zc,typed:dn,usolve:gg,usolveAll:RT}),$O=or({BigNumber:br,Unit:Ta,config:Sn}),WO=Y({BigNumber:br,Unit:Ta,config:Sn}),HO=Ub({divide:Kf,dotDivide:fd,isNumeric:N,log:sI,map:d0,matrix:$,multiply:Gc,sum:NT,typed:dn}),zO=RC({add:Ha,divide:Kf,typed:dn}),gR=ue({BigNumber:br,Unit:Ta,config:Sn}),vR=El({BigNumber:br,Unit:Ta,config:Sn}),YA=I_({bignumber:Gf,add:Ha,compare:Hw,divide:Kf,isInteger:zp,larger:_h,multiply:Gc,partitionSelect:aI,smaller:Dp,smallerEq:zw,subtract:zc,typed:dn}),XA=A_({add:Ha,apply:h0,divide:Kf,isNaN:Kp,multiply:Gc,subtract:zc,typed:dn}),GO=gi({BigNumber:br,Unit:Ta,config:Sn}),KO=wm({add:Ha,compare:Hw,divide:Kf,partitionSelect:aI,typed:dn}),_R=Wb({add:Ha,divide:Kf,matrix:$,mean:zO,multiply:Gc,pow:bv,sqrt:vh,subtract:zc,sum:NT,typed:dn}),yR=c0({Complex:yo,add:Ha,divide:Kf,matrix:$,multiply:Gc,typed:dn}),bR=zb({abs:Fa,map:d0,median:KO,subtract:zc,typed:dn}),CR=g({map:d0,sqrt:vh,typed:dn,variance:XA}),DR=x({BigNumber:br,Complex:yo,add:Ha,config:Sn,divide:Kf,equal:zd,factorial:BT,gamma:_I,isNegative:vv,multiply:Gc,pi:Po,pow:bv,sin:wl,smallerEq:zw,subtract:zc,typed:dn}),ZA=ye({abs:Fa,add:Ha,conj:L_,ctranspose:Xs,eigs:bI,equalScalar:nl,larger:_h,matrix:$,multiply:Gc,pow:bv,smaller:Dp,sqrt:vh,typed:dn}),qO=ht({BigNumber:br,DenseMatrix:Os,SparseMatrix:$l,addScalar:Du,config:Sn,cos:PC,matrix:$,multiplyScalar:Ku,norm:ZA,sin:wl,typed:dn,unaryMinus:bp}),JA=Zo({BigNumber:br,Unit:Ta,config:Sn}),CI=yn({identity:Ef,matrix:$,multiply:Gc,norm:ZA,qr:RA,subtract:zc,typed:dn}),QO=si({multiply:Gc,rotationMatrix:qO,typed:dn}),e2=jr({abs:Fa,add:Ha,concat:os,identity:Ef,index:EO,lusolve:dR,matrix:$,matrixFromColumns:AT,multiply:Gc,range:m0,schur:CI,subset:vg,subtract:zc,transpose:yr,typed:dn}),t2=mo({matrix:$,multiply:Gc,sylvester:e2,transpose:yr,typed:dn}),YO=new Set(["end"]),DI=re("Node",["mathWithTransform"],p=>{var{mathWithTransform:m}=p;return class _{get type(){return"Node"}get isNode(){return!0}evaluate(C){return this.compile().evaluate(C)}compile(){var C=this._compile(m,{}),A={};return{evaluate:function R(O){var F=wt(O);return function b(y){for(var C of[...YO])if(y.has(C))throw new Error('Scope contains an illegal symbol, "'+C+'" is a reserved keyword')}(F),C(F,A,null)}}}_compile(C,A){throw new Error("Method _compile must be implemented by type "+this.type)}forEach(C){throw new Error("Cannot run forEach on a Node interface")}map(C){throw new Error("Cannot run map on a Node interface")}_ifNode(C){if(!uo(C))throw new TypeError("Callback function must return a Node");return C}traverse(C){C(this,null,null),function A(k,R){k.forEach(function(O,F,B){R(O,F,B),A(O,R)})}(this,C)}transform(C){return function A(k,R,O){var F=C(k,R,O);return F!==k?F:k.map(A)}(this,null,null)}filter(C){var A=[];return this.traverse(function(k,R,O){C(k,R,O)&&A.push(k)}),A}clone(){throw new Error("Cannot clone a Node interface")}cloneDeep(){return this.map(function(C){return C.cloneDeep()})}equals(C){return!!C&&this.type===C.type&&qn(this,C)}toString(C){var A=this._getCustomString(C);return typeof A<"u"?A:this._toString(C)}_toString(){throw new Error("_toString not implemented for "+this.type)}toJSON(){throw new Error("Cannot serialize object: toJSON not implemented by "+this.type)}toHTML(C){var A=this._getCustomString(C);return typeof A<"u"?A:this._toHTML(C)}_toHTML(){throw new Error("_toHTML not implemented for "+this.type)}toTex(C){var A=this._getCustomString(C);return typeof A<"u"?A:this._toTex(C)}_toTex(C){throw new Error("_toTex not implemented for "+this.type)}_getCustomString(C){if(C&&"object"==typeof C)switch(typeof C.handler){case"object":case"undefined":return;case"function":return C.handler(this,C);default:throw new TypeError("Object or function expected as callback")}}getIdentifier(){return this.type}getContent(){return this}}},{isClass:!0,isNode:!0}),VT="ObjectNode",n2=re(VT,["Node"],p=>{var{Node:m}=p;class b extends m{constructor(y){if(super(),this.properties=y||{},y&&("object"!=typeof y||!Object.keys(y).every(function(C){return uo(y[C])})))throw new TypeError("Object containing Nodes expected")}get type(){return VT}get isObjectNode(){return!0}_compile(y,C){var A={};for(var k in this.properties)if(Jt(this.properties,k)){var R=Yd(k),O=JSON.parse(R),F=X(this.properties,k);A[O]=F._compile(y,C)}return function(H,G,J){var te={};for(var be in A)Jt(A,be)&&(te[be]=A[be](H,G,J));return te}}forEach(y){for(var C in this.properties)Jt(this.properties,C)&&y(this.properties[C],"properties["+Yd(C)+"]",this)}map(y){var C={};for(var A in this.properties)Jt(this.properties,A)&&(C[A]=this._ifNode(y(this.properties[A],"properties["+Yd(A)+"]",this)));return new b(C)}clone(){var y={};for(var C in this.properties)Jt(this.properties,C)&&(y[C]=this.properties[C]);return new b(y)}_toString(y){var C=[];for(var A in this.properties)Jt(this.properties,A)&&C.push(Yd(A)+": "+this.properties[A].toString(y));return"{"+C.join(", ")+"}"}toJSON(){return{mathjs:VT,properties:this.properties}}static fromJSON(y){return new b(y.properties)}_toHTML(y){var C=[];for(var A in this.properties)Jt(this.properties,A)&&C.push('<span class="math-symbol math-property">'+Xd(A)+'</span><span class="math-operator math-assignment-operator math-property-assignment-operator math-binary-operator">:</span>'+this.properties[A].toHTML(y));return'<span class="math-parenthesis math-curly-parenthesis">{</span>'+C.join('<span class="math-separator">,</span>')+'<span class="math-parenthesis math-curly-parenthesis">}</span>'}_toTex(y){var C=[];for(var A in this.properties)Jt(this.properties,A)&&C.push("\\mathbf{"+A+":} & "+this.properties[A].toTex(y)+"\\\\");return"\\left\\{\\begin{array}{ll}"+C.join("\n")+"\\end{array}\\right\\}"}}return ud(b,"name",VT),b},{isClass:!0,isNode:!0});function nE(p,m){return new le(p,new ce(m),new Set(Object.keys(m)))}var B_=[{AssignmentNode:{},FunctionAssignmentNode:{}},{ConditionalNode:{latexLeftParens:!1,latexRightParens:!1,latexParens:!1}},{"OperatorNode:or":{op:"or",associativity:"left",associativeWith:[]}},{"OperatorNode:xor":{op:"xor",associativity:"left",associativeWith:[]}},{"OperatorNode:and":{op:"and",associativity:"left",associativeWith:[]}},{"OperatorNode:bitOr":{op:"|",associativity:"left",associativeWith:[]}},{"OperatorNode:bitXor":{op:"^|",associativity:"left",associativeWith:[]}},{"OperatorNode:bitAnd":{op:"&",associativity:"left",associativeWith:[]}},{"OperatorNode:equal":{op:"==",associativity:"left",associativeWith:[]},"OperatorNode:unequal":{op:"!=",associativity:"left",associativeWith:[]},"OperatorNode:smaller":{op:"<",associativity:"left",associativeWith:[]},"OperatorNode:larger":{op:">",associativity:"left",associativeWith:[]},"OperatorNode:smallerEq":{op:"<=",associativity:"left",associativeWith:[]},"OperatorNode:largerEq":{op:">=",associativity:"left",associativeWith:[]},RelationalNode:{associativity:"left",associativeWith:[]}},{"OperatorNode:leftShift":{op:"<<",associativity:"left",associativeWith:[]},"OperatorNode:rightArithShift":{op:">>",associativity:"left",associativeWith:[]},"OperatorNode:rightLogShift":{op:">>>",associativity:"left",associativeWith:[]}},{"OperatorNode:to":{op:"to",associativity:"left",associativeWith:[]}},{RangeNode:{}},{"OperatorNode:add":{op:"+",associativity:"left",associativeWith:["OperatorNode:add","OperatorNode:subtract"]},"OperatorNode:subtract":{op:"-",associativity:"left",associativeWith:[]}},{"OperatorNode:multiply":{op:"*",associativity:"left",associativeWith:["OperatorNode:multiply","OperatorNode:divide","Operator:dotMultiply","Operator:dotDivide"]},"OperatorNode:divide":{op:"/",associativity:"left",associativeWith:[],latexLeftParens:!1,latexRightParens:!1,latexParens:!1},"OperatorNode:dotMultiply":{op:".*",associativity:"left",associativeWith:["OperatorNode:multiply","OperatorNode:divide","OperatorNode:dotMultiply","OperatorNode:doDivide"]},"OperatorNode:dotDivide":{op:"./",associativity:"left",associativeWith:[]},"OperatorNode:mod":{op:"mod",associativity:"left",associativeWith:[]}},{"OperatorNode:multiply":{associativity:"left",associativeWith:["OperatorNode:multiply","OperatorNode:divide","Operator:dotMultiply","Operator:dotDivide"]}},{"OperatorNode:unaryPlus":{op:"+",associativity:"right"},"OperatorNode:unaryMinus":{op:"-",associativity:"right"},"OperatorNode:bitNot":{op:"~",associativity:"right"},"OperatorNode:not":{op:"not",associativity:"right"}},{"OperatorNode:pow":{op:"^",associativity:"right",associativeWith:[],latexRightParens:!1},"OperatorNode:dotPow":{op:".^",associativity:"right",associativeWith:[]}},{"OperatorNode:factorial":{op:"!",associativity:"left"}},{"OperatorNode:ctranspose":{op:"'",associativity:"left"}}];function wI(p,m){if(!m||"auto"!==m)return p;for(var b=p;yt(b);)b=b.content;return b}function ed(p,m,b,_){var y=p;"keep"!==m&&(y=p.getContent());for(var C=y.getIdentifier(),A=null,k=0;k<B_.length;k++)if(C in B_[k]){A=k;break}if("OperatorNode:multiply"===C&&y.implicit&&"show"!==b){var R=wI(y.args[0],m);!(Qi(R)&&_&&"OperatorNode:divide"===_.getIdentifier()&&Xr(wI(_.args[0],m)))&&("OperatorNode:divide"!==R.getIdentifier()||!Xr(wI(R.args[0],m))||!Qi(wI(R.args[1])))&&(A+=1)}return A}function jT(p,m){var b=p;"keep"!==m&&(b=p.getContent());var _=b.getIdentifier(),y=ed(b,m);if(null===y)return null;var C=B_[y][_];if(Jt(C,"associativity")){if("left"===C.associativity)return"left";if("right"===C.associativity)return"right";throw Error("'"+_+"' has the invalid associativity '"+C.associativity+"'.")}return null}function ZO(p,m,b){var _="keep"!==b?p.getContent():p,y="keep"!==b?p.getContent():m,C=_.getIdentifier(),A=y.getIdentifier(),k=ed(_,b);if(null===k)return null;var R=B_[k][C];if(Jt(R,"associativeWith")&&R.associativeWith instanceof Array){for(var O=0;O<R.associativeWith.length;O++)if(R.associativeWith[O]===A)return!0;return!1}return null}var ER=S(4987),JO={Alpha:"A",alpha:"\\alpha",Beta:"B",beta:"\\beta",Gamma:"\\Gamma",gamma:"\\gamma",Delta:"\\Delta",delta:"\\delta",Epsilon:"E",epsilon:"\\epsilon",varepsilon:"\\varepsilon",Zeta:"Z",zeta:"\\zeta",Eta:"H",eta:"\\eta",Theta:"\\Theta",theta:"\\theta",vartheta:"\\vartheta",Iota:"I",iota:"\\iota",Kappa:"K",kappa:"\\kappa",varkappa:"\\varkappa",Lambda:"\\Lambda",lambda:"\\lambda",Mu:"M",mu:"\\mu",Nu:"N",nu:"\\nu",Xi:"\\Xi",xi:"\\xi",Omicron:"O",omicron:"o",Pi:"\\Pi",pi:"\\pi",varpi:"\\varpi",Rho:"P",rho:"\\rho",varrho:"\\varrho",Sigma:"\\Sigma",sigma:"\\sigma",varsigma:"\\varsigma",Tau:"T",tau:"\\tau",Upsilon:"\\Upsilon",upsilon:"\\upsilon",Phi:"\\Phi",phi:"\\phi",varphi:"\\varphi",Chi:"X",chi:"\\chi",Psi:"\\Psi",psi:"\\psi",Omega:"\\Omega",omega:"\\omega",true:"\\mathrm{True}",false:"\\mathrm{False}",i:"i",inf:"\\infty",Inf:"\\infty",infinity:"\\infty",Infinity:"\\infty",oo:"\\infty",lim:"\\lim",undefined:"\\mathbf{?}"},rc={transpose:"^\\top",ctranspose:"^H",factorial:"!",pow:"^",dotPow:".^\\wedge",unaryPlus:"+",unaryMinus:"-",bitNot:"\\~",not:"\\neg",multiply:"\\cdot",divide:"\\frac",dotMultiply:".\\cdot",dotDivide:".:",mod:"\\mod",add:"+",subtract:"-",to:"\\rightarrow",leftShift:"<<",rightArithShift:">>",rightLogShift:">>>",equal:"=",unequal:"\\neq",smaller:"<",larger:">",smallerEq:"\\leq",largerEq:"\\geq",bitAnd:"\\&",bitXor:"\\underline{|}",bitOr:"|",and:"\\wedge",xor:"\\veebar",or:"\\vee"},UT={abs:{1:"\\left|${args[0]}\\right|"},add:{2:"\\left(${args[0]}".concat(rc.add,"${args[1]}\\right)")},cbrt:{1:"\\sqrt[3]{${args[0]}}"},ceil:{1:"\\left\\lceil${args[0]}\\right\\rceil"},cube:{1:"\\left(${args[0]}\\right)^3"},divide:{2:"\\frac{${args[0]}}{${args[1]}}"},dotDivide:{2:"\\left(${args[0]}".concat(rc.dotDivide,"${args[1]}\\right)")},dotMultiply:{2:"\\left(${args[0]}".concat(rc.dotMultiply,"${args[1]}\\right)")},dotPow:{2:"\\left(${args[0]}".concat(rc.dotPow,"${args[1]}\\right)")},exp:{1:"\\exp\\left(${args[0]}\\right)"},expm1:"\\left(e".concat(rc.pow,"{${args[0]}}-1\\right)"),fix:{1:"\\mathrm{${name}}\\left(${args[0]}\\right)"},floor:{1:"\\left\\lfloor${args[0]}\\right\\rfloor"},gcd:"\\gcd\\left(${args}\\right)",hypot:"\\hypot\\left(${args}\\right)",log:{1:"\\ln\\left(${args[0]}\\right)",2:"\\log_{${args[1]}}\\left(${args[0]}\\right)"},log10:{1:"\\log_{10}\\left(${args[0]}\\right)"},log1p:{1:"\\ln\\left(${args[0]}+1\\right)",2:"\\log_{${args[1]}}\\left(${args[0]}+1\\right)"},log2:"\\log_{2}\\left(${args[0]}\\right)",mod:{2:"\\left(${args[0]}".concat(rc.mod,"${args[1]}\\right)")},multiply:{2:"\\left(${args[0]}".concat(rc.multiply,"${args[1]}\\right)")},norm:{1:"\\left\\|${args[0]}\\right\\|",2:void 0},nthRoot:{2:"\\sqrt[${args[1]}]{${args[0]}}"},nthRoots:{2:"\\{y : $y^{args[1]} = {${args[0]}}\\}"},pow:{2:"\\left(${args[0]}\\right)".concat(rc.pow,"{${args[1]}}")},round:{1:"\\left\\lfloor${args[0]}\\right\\rceil",2:void 0},sign:{1:"\\mathrm{${name}}\\left(${args[0]}\\right)"},sqrt:{1:"\\sqrt{${args[0]}}"},square:{1:"\\left(${args[0]}\\right)^2"},subtract:{2:"\\left(${args[0]}".concat(rc.subtract,"${args[1]}\\right)")},unaryMinus:{1:"".concat(rc.unaryMinus,"\\left(${args[0]}\\right)")},unaryPlus:{1:"".concat(rc.unaryPlus,"\\left(${args[0]}\\right)")},bitAnd:{2:"\\left(${args[0]}".concat(rc.bitAnd,"${args[1]}\\right)")},bitNot:{1:rc.bitNot+"\\left(${args[0]}\\right)"},bitOr:{2:"\\left(${args[0]}".concat(rc.bitOr,"${args[1]}\\right)")},bitXor:{2:"\\left(${args[0]}".concat(rc.bitXor,"${args[1]}\\right)")},leftShift:{2:"\\left(${args[0]}".concat(rc.leftShift,"${args[1]}\\right)")},rightArithShift:{2:"\\left(${args[0]}".concat(rc.rightArithShift,"${args[1]}\\right)")},rightLogShift:{2:"\\left(${args[0]}".concat(rc.rightLogShift,"${args[1]}\\right)")},bellNumbers:{1:"\\mathrm{B}_{${args[0]}}"},catalan:{1:"\\mathrm{C}_{${args[0]}}"},stirlingS2:{2:"\\mathrm{S}\\left(${args}\\right)"},arg:{1:"\\arg\\left(${args[0]}\\right)"},conj:{1:"\\left(${args[0]}\\right)^*"},im:{1:"\\Im\\left\\lbrace${args[0]}\\right\\rbrace"},re:{1:"\\Re\\left\\lbrace${args[0]}\\right\\rbrace"},and:{2:"\\left(${args[0]}".concat(rc.and,"${args[1]}\\right)")},not:{1:rc.not+"\\left(${args[0]}\\right)"},or:{2:"\\left(${args[0]}".concat(rc.or,"${args[1]}\\right)")},xor:{2:"\\left(${args[0]}".concat(rc.xor,"${args[1]}\\right)")},cross:{2:"\\left(${args[0]}\\right)\\times\\left(${args[1]}\\right)"},ctranspose:{1:"\\left(${args[0]}\\right)".concat(rc.ctranspose)},det:{1:"\\det\\left(${args[0]}\\right)"},dot:{2:"\\left(${args[0]}\\cdot${args[1]}\\right)"},expm:{1:"\\exp\\left(${args[0]}\\right)"},inv:{1:"\\left(${args[0]}\\right)^{-1}"},pinv:{1:"\\left(${args[0]}\\right)^{+}"},sqrtm:{1:"{${args[0]}}".concat(rc.pow,"{\\frac{1}{2}}")},trace:{1:"\\mathrm{tr}\\left(${args[0]}\\right)"},transpose:{1:"\\left(${args[0]}\\right)".concat(rc.transpose)},combinations:{2:"\\binom{${args[0]}}{${args[1]}}"},combinationsWithRep:{2:"\\left(\\!\\!{\\binom{${args[0]}}{${args[1]}}}\\!\\!\\right)"},factorial:{1:"\\left(${args[0]}\\right)".concat(rc.factorial)},gamma:{1:"\\Gamma\\left(${args[0]}\\right)"},lgamma:{1:"\\ln\\Gamma\\left(${args[0]}\\right)"},equal:{2:"\\left(${args[0]}".concat(rc.equal,"${args[1]}\\right)")},larger:{2:"\\left(${args[0]}".concat(rc.larger,"${args[1]}\\right)")},largerEq:{2:"\\left(${args[0]}".concat(rc.largerEq,"${args[1]}\\right)")},smaller:{2:"\\left(${args[0]}".concat(rc.smaller,"${args[1]}\\right)")},smallerEq:{2:"\\left(${args[0]}".concat(rc.smallerEq,"${args[1]}\\right)")},unequal:{2:"\\left(${args[0]}".concat(rc.unequal,"${args[1]}\\right)")},erf:{1:"erf\\left(${args[0]}\\right)"},max:"\\max\\left(${args}\\right)",min:"\\min\\left(${args}\\right)",variance:"\\mathrm{Var}\\left(${args}\\right)",acos:{1:"\\cos^{-1}\\left(${args[0]}\\right)"},acosh:{1:"\\cosh^{-1}\\left(${args[0]}\\right)"},acot:{1:"\\cot^{-1}\\left(${args[0]}\\right)"},acoth:{1:"\\coth^{-1}\\left(${args[0]}\\right)"},acsc:{1:"\\csc^{-1}\\left(${args[0]}\\right)"},acsch:{1:"\\mathrm{csch}^{-1}\\left(${args[0]}\\right)"},asec:{1:"\\sec^{-1}\\left(${args[0]}\\right)"},asech:{1:"\\mathrm{sech}^{-1}\\left(${args[0]}\\right)"},asin:{1:"\\sin^{-1}\\left(${args[0]}\\right)"},asinh:{1:"\\sinh^{-1}\\left(${args[0]}\\right)"},atan:{1:"\\tan^{-1}\\left(${args[0]}\\right)"},atan2:{2:"\\mathrm{atan2}\\left(${args}\\right)"},atanh:{1:"\\tanh^{-1}\\left(${args[0]}\\right)"},cos:{1:"\\cos\\left(${args[0]}\\right)"},cosh:{1:"\\cosh\\left(${args[0]}\\right)"},cot:{1:"\\cot\\left(${args[0]}\\right)"},coth:{1:"\\coth\\left(${args[0]}\\right)"},csc:{1:"\\csc\\left(${args[0]}\\right)"},csch:{1:"\\mathrm{csch}\\left(${args[0]}\\right)"},sec:{1:"\\sec\\left(${args[0]}\\right)"},sech:{1:"\\mathrm{sech}\\left(${args[0]}\\right)"},sin:{1:"\\sin\\left(${args[0]}\\right)"},sinh:{1:"\\sinh\\left(${args[0]}\\right)"},tan:{1:"\\tan\\left(${args[0]}\\right)"},tanh:{1:"\\tanh\\left(${args[0]}\\right)"},to:{2:"\\left(${args[0]}".concat(rc.to,"${args[1]}\\right)")},numeric:function(m,b){return m.args[0].toTex()},number:{0:"0",1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)${args[1]}\\right)"},string:{0:'\\mathtt{""}',1:"\\mathrm{string}\\left(${args[0]}\\right)"},bignumber:{0:"0",1:"\\left(${args[0]}\\right)"},bigint:{0:"0",1:"\\left(${args[0]}\\right)"},complex:{0:"0",1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)+".concat(JO.i,"\\cdot\\left(${args[1]}\\right)\\right)")},matrix:{0:"\\begin{bmatrix}\\end{bmatrix}",1:"\\left(${args[0]}\\right)",2:"\\left(${args[0]}\\right)"},sparse:{0:"\\begin{bsparse}\\end{bsparse}",1:"\\left(${args[0]}\\right)"},unit:{1:"\\left(${args[0]}\\right)",2:"\\left(\\left(${args[0]}\\right)${args[1]}\\right)"}},r2={deg:"^\\circ"};function xI(p){return ER(p,{preserveFormatting:!0})}function o2(p,m){return(m=!(typeof m>"u")&&m)?Jt(r2,p)?r2[p]:"\\mathrm{"+xI(p)+"}":Jt(JO,p)?JO[p]:xI(p)}var iE="OperatorNode",$T=re(iE,["Node"],p=>{var{Node:m}=p;function b(C,A){var k=C;if("auto"===A)for(;yt(k);)k=k.content;return!!Qi(k)||!!ci(k)&&b(k.args[0],A)}function _(C,A,k,R,O){var H,F=ed(C,A,k),B=jT(C,A);if("all"===A||R.length>2&&"OperatorNode:add"!==C.getIdentifier()&&"OperatorNode:multiply"!==C.getIdentifier())return R.map(function(ze){switch(ze.getContent().type){case"ArrayNode":case"ConstantNode":case"SymbolNode":case"ParenthesisNode":return!1;default:return!0}});switch(R.length){case 0:H=[];break;case 1:var G=ed(R[0],A,k,C);if(O&&null!==G){var J,te;if("keep"===A?(J=R[0].getIdentifier(),te=C.getIdentifier()):(J=R[0].getContent().getIdentifier(),te=C.getContent().getIdentifier()),!1===B_[F][te].latexLeftParens){H=[!1];break}if(!1===B_[G][J].latexParens){H=[!1];break}}if(null===G){H=[!1];break}if(G<=F){H=[!0];break}H=[!1];break;case 2:var be,we=ed(R[0],A,k,C),Le=ZO(C,R[0],A);be=null!==we&&(we===F&&"right"===B&&!Le||we<F);var de,pe,Be,We,Te=ed(R[1],A,k,C),De=ZO(C,R[1],A);de=null!==Te&&(Te===F&&"left"===B&&!De||Te<F),O&&("keep"===A?(pe=C.getIdentifier(),Be=C.args[0].getIdentifier(),We=C.args[1].getIdentifier()):(pe=C.getContent().getIdentifier(),Be=C.args[0].getContent().getIdentifier(),We=C.args[1].getContent().getIdentifier()),null!==we&&(!1===B_[F][pe].latexLeftParens&&(be=!1),!1===B_[we][Be].latexParens&&(be=!1)),null!==Te&&(!1===B_[F][pe].latexRightParens&&(de=!1),!1===B_[Te][We].latexParens&&(de=!1))),H=[be,de];break;default:("OperatorNode:add"===C.getIdentifier()||"OperatorNode:multiply"===C.getIdentifier())&&(H=R.map(function(ze){var et=ed(ze,A,k,C),pt=ZO(C,ze,A),$t=jT(ze,A);return null!==et&&(F===et&&B===$t&&!pt||et<F)}))}if(R.length>=2&&"OperatorNode:multiply"===C.getIdentifier()&&C.implicit&&"all"!==A&&"hide"===k)for(var ke=1;ke<H.length;++ke)b(R[ke],A)&&!H[ke-1]&&("keep"!==A||!yt(R[ke-1]))&&(H[ke]=!0);return H}class y extends m{constructor(A,k,R,O,F){if(super(),"string"!=typeof A)throw new TypeError('string expected for parameter "op"');if("string"!=typeof k)throw new TypeError('string expected for parameter "fn"');if(!Array.isArray(R)||!R.every(uo))throw new TypeError('Array containing Nodes expected for parameter "args"');this.implicit=!0===O,this.isPercentage=!0===F,this.op=A,this.fn=k,this.args=R||[]}get type(){return iE}get isOperatorNode(){return!0}_compile(A,k){if("string"!=typeof this.fn||!he(A,this.fn))throw A[this.fn]?new Error('No access to function "'+this.fn+'"'):new Error("Function "+this.fn+' missing in provided namespace "math"');var R=X(A,this.fn),O=Hu(this.args,function(J){return J._compile(A,k)});if("function"==typeof R&&!0===R.rawArgs){var F=this.args;return function(te,be,we){return R(F,A,nE(te,be))}}if(1===O.length){var B=O[0];return function(te,be,we){return R(B(te,be,we))}}if(2===O.length){var H=O[0],G=O[1];return function(te,be,we){return R(H(te,be,we),G(te,be,we))}}return function(te,be,we){return R.apply(null,Hu(O,function(Le){return Le(te,be,we)}))}}forEach(A){for(var k=0;k<this.args.length;k++)A(this.args[k],"args["+k+"]",this)}map(A){for(var k=[],R=0;R<this.args.length;R++)k[R]=this._ifNode(A(this.args[R],"args["+R+"]",this));return new y(this.op,this.fn,k,this.implicit,this.isPercentage)}clone(){return new y(this.op,this.fn,this.args.slice(0),this.implicit,this.isPercentage)}isUnary(){return 1===this.args.length}isBinary(){return 2===this.args.length}_toString(A){var k=A&&A.parenthesis?A.parenthesis:"keep",R=A&&A.implicit?A.implicit:"hide",O=this.args,F=_(this,k,R,O,!1);if(1===O.length){var B=jT(this,k),H=O[0].toString(A);F[0]&&(H="("+H+")");var G=/[a-zA-Z]+/.test(this.op);return"right"===B?this.op+(G?" ":"")+H:"left"===B?H+(G?" ":"")+this.op:H+this.op}if(2===O.length){var J=O[0].toString(A),te=O[1].toString(A);return F[0]&&(J="("+J+")"),F[1]&&(te="("+te+")"),this.implicit&&"OperatorNode:multiply"===this.getIdentifier()&&"hide"===R?J+" "+te:J+" "+this.op+" "+te}if(O.length>2&&("OperatorNode:add"===this.getIdentifier()||"OperatorNode:multiply"===this.getIdentifier())){var be=O.map(function(we,Le){return we=we.toString(A),F[Le]&&(we="("+we+")"),we});return this.implicit&&"OperatorNode:multiply"===this.getIdentifier()&&"hide"===R?be.join(" "):be.join(" "+this.op+" ")}return this.fn+"("+this.args.join(", ")+")"}toJSON(){return{mathjs:iE,op:this.op,fn:this.fn,args:this.args,implicit:this.implicit,isPercentage:this.isPercentage}}static fromJSON(A){return new y(A.op,A.fn,A.args,A.implicit,A.isPercentage)}_toHTML(A){var k=A&&A.parenthesis?A.parenthesis:"keep",R=A&&A.implicit?A.implicit:"hide",O=this.args,F=_(this,k,R,O,!1);if(1===O.length){var B=jT(this,k),H=O[0].toHTML(A);return F[0]&&(H='<span class="math-parenthesis math-round-parenthesis">(</span>'+H+'<span class="math-parenthesis math-round-parenthesis">)</span>'),"right"===B?'<span class="math-operator math-unary-operator math-lefthand-unary-operator">'+Xd(this.op)+"</span>"+H:H+'<span class="math-operator math-unary-operator math-righthand-unary-operator">'+Xd(this.op)+"</span>"}if(2===O.length){var G=O[0].toHTML(A),J=O[1].toHTML(A);return F[0]&&(G='<span class="math-parenthesis math-round-parenthesis">(</span>'+G+'<span class="math-parenthesis math-round-parenthesis">)</span>'),F[1]&&(J='<span class="math-parenthesis math-round-parenthesis">(</span>'+J+'<span class="math-parenthesis math-round-parenthesis">)</span>'),this.implicit&&"OperatorNode:multiply"===this.getIdentifier()&&"hide"===R?G+'<span class="math-operator math-binary-operator math-implicit-binary-operator"></span>'+J:G+'<span class="math-operator math-binary-operator math-explicit-binary-operator">'+Xd(this.op)+"</span>"+J}var te=O.map(function(be,we){return be=be.toHTML(A),F[we]&&(be='<span class="math-parenthesis math-round-parenthesis">(</span>'+be+'<span class="math-parenthesis math-round-parenthesis">)</span>'),be});return O.length>2&&("OperatorNode:add"===this.getIdentifier()||"OperatorNode:multiply"===this.getIdentifier())?this.implicit&&"OperatorNode:multiply"===this.getIdentifier()&&"hide"===R?te.join('<span class="math-operator math-binary-operator math-implicit-binary-operator"></span>'):te.join('<span class="math-operator math-binary-operator math-explicit-binary-operator">'+Xd(this.op)+"</span>"):'<span class="math-function">'+Xd(this.fn)+'</span><span class="math-paranthesis math-round-parenthesis">(</span>'+te.join('<span class="math-separator">,</span>')+'<span class="math-paranthesis math-round-parenthesis">)</span>'}_toTex(A){var k=A&&A.parenthesis?A.parenthesis:"keep",R=A&&A.implicit?A.implicit:"hide",O=this.args,F=_(this,k,R,O,!0),B=rc[this.fn];if(B=typeof B>"u"?this.op:B,1===O.length){var H=jT(this,k),G=O[0].toTex(A);return F[0]&&(G="\\left(".concat(G,"\\right)")),"right"===H?B+G:G+B}if(2===O.length){var J=O[0],te=J.toTex(A);F[0]&&(te="\\left(".concat(te,"\\right)"));var Le,we=O[1].toTex(A);switch(F[1]&&(we="\\left(".concat(we,"\\right)")),Le="keep"===k?J.getIdentifier():J.getContent().getIdentifier(),this.getIdentifier()){case"OperatorNode:divide":return B+"{"+te+"}{"+we+"}";case"OperatorNode:pow":switch(te="{"+te+"}",we="{"+we+"}",Le){case"ConditionalNode":case"OperatorNode:divide":te="\\left(".concat(te,"\\right)")}break;case"OperatorNode:multiply":if(this.implicit&&"hide"===R)return te+"~"+we}return te+B+we}if(O.length>2&&("OperatorNode:add"===this.getIdentifier()||"OperatorNode:multiply"===this.getIdentifier())){var de=O.map(function(Te,De){return Te=Te.toTex(A),F[De]&&(Te="\\left(".concat(Te,"\\right)")),Te});return"OperatorNode:multiply"===this.getIdentifier()&&this.implicit&&"hide"===R?de.join("~"):de.join(B)}return"\\mathrm{"+this.fn+"}\\left("+O.map(function(Te){return Te.toTex(A)}).join(",")+"\\right)"}getIdentifier(){return this.type+":"+this.fn}}return ud(y,"name",iE),y},{isClass:!0,isNode:!0}),WT="ParenthesisNode",SI=re(WT,["Node"],p=>{var{Node:m}=p;class b extends m{constructor(y){if(super(),!uo(y))throw new TypeError('Node expected for parameter "content"');this.content=y}get type(){return WT}get isParenthesisNode(){return!0}_compile(y,C){return this.content._compile(y,C)}getContent(){return this.content.getContent()}forEach(y){y(this.content,"content",this)}map(y){var C=y(this.content,"content",this);return new b(C)}clone(){return new b(this.content)}_toString(y){return!y||y&&!y.parenthesis||y&&"keep"===y.parenthesis?"("+this.content.toString(y)+")":this.content.toString(y)}toJSON(){return{mathjs:WT,content:this.content}}static fromJSON(y){return new b(y.content)}_toHTML(y){return!y||y&&!y.parenthesis||y&&"keep"===y.parenthesis?'<span class="math-parenthesis math-round-parenthesis">(</span>'+this.content.toHTML(y)+'<span class="math-parenthesis math-round-parenthesis">)</span>':this.content.toHTML(y)}_toTex(y){return!y||y&&!y.parenthesis||y&&"keep"===y.parenthesis?"\\left(".concat(this.content.toTex(y),"\\right)"):this.content.toTex(y)}}return ud(b,"name",WT),b},{isClass:!0,isNode:!0}),EI="RelationalNode",HT=re(EI,["Node"],p=>{var{Node:m}=p,b={equal:"==",unequal:"!=",smaller:"<",larger:">",smallerEq:"<=",largerEq:">="};class _ extends m{constructor(C,A){if(super(),!Array.isArray(C))throw new TypeError("Parameter conditionals must be an array");if(!Array.isArray(A))throw new TypeError("Parameter params must be an array");if(C.length!==A.length-1)throw new TypeError("Parameter params must contain exactly one more element than parameter conditionals");this.conditionals=C,this.params=A}get type(){return EI}get isRelationalNode(){return!0}_compile(C,A){var k=this,R=this.params.map(O=>O._compile(C,A));return function(F,B,H){for(var G,J=R[0](F,B,H),te=0;te<k.conditionals.length;te++)if(G=J,J=R[te+1](F,B,H),!X(C,k.conditionals[te])(G,J))return!1;return!0}}forEach(C){this.params.forEach((A,k)=>C(A,"params["+k+"]",this),this)}map(C){return new _(this.conditionals.slice(),this.params.map((A,k)=>this._ifNode(C(A,"params["+k+"]",this)),this))}clone(){return new _(this.conditionals,this.params)}_toString(C){for(var A=C&&C.parenthesis?C.parenthesis:"keep",k=ed(this,A,C&&C.implicit),R=this.params.map(function(B,H){var G=ed(B,A,C&&C.implicit);return"all"===A||null!==G&&G<=k?"("+B.toString(C)+")":B.toString(C)}),O=R[0],F=0;F<this.conditionals.length;F++)O+=" "+b[this.conditionals[F]],O+=" "+R[F+1];return O}toJSON(){return{mathjs:EI,conditionals:this.conditionals,params:this.params}}static fromJSON(C){return new _(C.conditionals,C.params)}_toHTML(C){for(var A=C&&C.parenthesis?C.parenthesis:"keep",k=ed(this,A,C&&C.implicit),R=this.params.map(function(B,H){var G=ed(B,A,C&&C.implicit);return"all"===A||null!==G&&G<=k?'<span class="math-parenthesis math-round-parenthesis">(</span>'+B.toHTML(C)+'<span class="math-parenthesis math-round-parenthesis">)</span>':B.toHTML(C)}),O=R[0],F=0;F<this.conditionals.length;F++)O+='<span class="math-operator math-binary-operator math-explicit-binary-operator">'+Xd(b[this.conditionals[F]])+"</span>"+R[F+1];return O}_toTex(C){for(var A=C&&C.parenthesis?C.parenthesis:"keep",k=ed(this,A,C&&C.implicit),R=this.params.map(function(B,H){var G=ed(B,A,C&&C.implicit);return"all"===A||null!==G&&G<=k?"\\left("+B.toTex(C)+"\right)":B.toTex(C)}),O=R[0],F=0;F<this.conditionals.length;F++)O+=rc[this.conditionals[F]]+R[F+1];return O}}return ud(_,"name",EI),_},{isClass:!0,isNode:!0}),zT="ArrayNode",rE=re(zT,["Node"],p=>{var{Node:m}=p;class b extends m{constructor(y){if(super(),this.items=y||[],!Array.isArray(this.items)||!this.items.every(uo))throw new TypeError("Array containing Nodes expected")}get type(){return zT}get isArrayNode(){return!0}_compile(y,C){var A=Hu(this.items,function(O){return O._compile(y,C)});if("Array"!==y.config.matrix){var R=y.matrix;return function(F,B,H){return R(Hu(A,function(G){return G(F,B,H)}))}}return function(F,B,H){return Hu(A,function(G){return G(F,B,H)})}}forEach(y){for(var C=0;C<this.items.length;C++)y(this.items[C],"items["+C+"]",this)}map(y){for(var C=[],A=0;A<this.items.length;A++)C[A]=this._ifNode(y(this.items[A],"items["+A+"]",this));return new b(C)}clone(){return new b(this.items.slice(0))}_toString(y){return"["+this.items.map(function(A){return A.toString(y)}).join(", ")+"]"}toJSON(){return{mathjs:zT,items:this.items}}static fromJSON(y){return new b(y.items)}_toHTML(y){return'<span class="math-parenthesis math-square-parenthesis">[</span>'+this.items.map(function(A){return A.toHTML(y)}).join('<span class="math-separator">,</span>')+'<span class="math-parenthesis math-square-parenthesis">]</span>'}_toTex(y){return function C(A,k){var R=A.some(Nn)&&!A.every(Nn),O=k||R,F=O?"&":"\\\\",B=A.map(function(H){return H.items?C(H.items,!k):H.toTex(y)}).join(F);return R||!O||O&&!k?"\\begin{bmatrix}"+B+"\\end{bmatrix}":B}(this.items,!1)}}return ud(b,"name",zT),b},{isClass:!0,isNode:!0}),TI="BlockNode",MI=re(TI,["ResultSet","Node"],p=>{var{ResultSet:m,Node:b}=p;class _ extends b{constructor(C){if(super(),!Array.isArray(C))throw new Error("Array expected");this.blocks=C.map(function(A){var k=A&&A.node,R=!A||void 0===A.visible||A.visible;if(!uo(k))throw new TypeError('Property "node" must be a Node');if("boolean"!=typeof R)throw new TypeError('Property "visible" must be a boolean');return{node:k,visible:R}})}get type(){return TI}get isBlockNode(){return!0}_compile(C,A){var k=Hu(this.blocks,function(R){return{evaluate:R.node._compile(C,A),visible:R.visible}});return function(O,F,B){var H=[];return gf(k,function(J){var te=J.evaluate(O,F,B);J.visible&&H.push(te)}),new m(H)}}forEach(C){for(var A=0;A<this.blocks.length;A++)C(this.blocks[A].node,"blocks["+A+"].node",this)}map(C){for(var A=[],k=0;k<this.blocks.length;k++){var R=this.blocks[k],O=this._ifNode(C(R.node,"blocks["+k+"].node",this));A[k]={node:O,visible:R.visible}}return new _(A)}clone(){var C=this.blocks.map(function(A){return{node:A.node,visible:A.visible}});return new _(C)}_toString(C){return this.blocks.map(function(A){return A.node.toString(C)+(A.visible?"":";")}).join("\n")}toJSON(){return{mathjs:TI,blocks:this.blocks}}static fromJSON(C){return new _(C.blocks)}_toHTML(C){return this.blocks.map(function(A){return A.node.toHTML(C)+(A.visible?"":'<span class="math-separator">;</span>')}).join('<span class="math-separator"><br /></span>')}_toTex(C){return this.blocks.map(function(A){return A.node.toTex(C)+(A.visible?"":";")}).join("\\;\\;\n")}}return ud(_,"name",TI),_},{isClass:!0,isNode:!0}),II="ConditionalNode",QC=re(II,["Node"],p=>{var{Node:m}=p;class _ extends m{constructor(C,A,k){if(super(),!uo(C))throw new TypeError("Parameter condition must be a Node");if(!uo(A))throw new TypeError("Parameter trueExpr must be a Node");if(!uo(k))throw new TypeError("Parameter falseExpr must be a Node");this.condition=C,this.trueExpr=A,this.falseExpr=k}get type(){return II}get isConditionalNode(){return!0}_compile(C,A){var k=this.condition._compile(C,A),R=this.trueExpr._compile(C,A),O=this.falseExpr._compile(C,A);return function(B,H,G){return function b(y){if("number"==typeof y||"boolean"==typeof y||"string"==typeof y)return!!y;if(y){if(en(y))return!y.isZero();if(un(y))return!(!y.re&&!y.im);if(Pt(y))return!!y.value}if(null==y)return!1;throw new TypeError('Unsupported type of condition "'+pi(y)+'"')}(k(B,H,G))?R(B,H,G):O(B,H,G)}}forEach(C){C(this.condition,"condition",this),C(this.trueExpr,"trueExpr",this),C(this.falseExpr,"falseExpr",this)}map(C){return new _(this._ifNode(C(this.condition,"condition",this)),this._ifNode(C(this.trueExpr,"trueExpr",this)),this._ifNode(C(this.falseExpr,"falseExpr",this)))}clone(){return new _(this.condition,this.trueExpr,this.falseExpr)}_toString(C){var A=C&&C.parenthesis?C.parenthesis:"keep",k=ed(this,A,C&&C.implicit),R=this.condition.toString(C),O=ed(this.condition,A,C&&C.implicit);("all"===A||"OperatorNode"===this.condition.type||null!==O&&O<=k)&&(R="("+R+")");var F=this.trueExpr.toString(C),B=ed(this.trueExpr,A,C&&C.implicit);("all"===A||"OperatorNode"===this.trueExpr.type||null!==B&&B<=k)&&(F="("+F+")");var H=this.falseExpr.toString(C),G=ed(this.falseExpr,A,C&&C.implicit);return("all"===A||"OperatorNode"===this.falseExpr.type||null!==G&&G<=k)&&(H="("+H+")"),R+" ? "+F+" : "+H}toJSON(){return{mathjs:II,condition:this.condition,trueExpr:this.trueExpr,falseExpr:this.falseExpr}}static fromJSON(C){return new _(C.condition,C.trueExpr,C.falseExpr)}_toHTML(C){var A=C&&C.parenthesis?C.parenthesis:"keep",k=ed(this,A,C&&C.implicit),R=this.condition.toHTML(C),O=ed(this.condition,A,C&&C.implicit);("all"===A||"OperatorNode"===this.condition.type||null!==O&&O<=k)&&(R='<span class="math-parenthesis math-round-parenthesis">(</span>'+R+'<span class="math-parenthesis math-round-parenthesis">)</span>');var F=this.trueExpr.toHTML(C),B=ed(this.trueExpr,A,C&&C.implicit);("all"===A||"OperatorNode"===this.trueExpr.type||null!==B&&B<=k)&&(F='<span class="math-parenthesis math-round-parenthesis">(</span>'+F+'<span class="math-parenthesis math-round-parenthesis">)</span>');var H=this.falseExpr.toHTML(C),G=ed(this.falseExpr,A,C&&C.implicit);return("all"===A||"OperatorNode"===this.falseExpr.type||null!==G&&G<=k)&&(H='<span class="math-parenthesis math-round-parenthesis">(</span>'+H+'<span class="math-parenthesis math-round-parenthesis">)</span>'),R+'<span class="math-operator math-conditional-operator">?</span>'+F+'<span class="math-operator math-conditional-operator">:</span>'+H}_toTex(C){return"\\begin{cases} {"+this.trueExpr.toTex(C)+"}, &\\quad{\\text{if }\\;"+this.condition.toTex(C)+"}\\\\{"+this.falseExpr.toTex(C)+"}, &\\quad{\\text{otherwise}}\\end{cases}"}}return ud(_,"name",II),_},{isClass:!0,isNode:!0}),GT="ConstantNode",qw=re(GT,["Node"],p=>{var{Node:m}=p;class b extends m{constructor(y){super(),this.value=y}get type(){return GT}get isConstantNode(){return!0}_compile(y,C){var A=this.value;return function(){return A}}forEach(y){}map(y){return this.clone()}clone(){return new b(this.value)}_toString(y){return xs(this.value,y)}_toHTML(y){var C=this._toString(y);switch(pi(this.value)){case"number":case"bigint":case"BigNumber":case"Fraction":return'<span class="math-number">'+C+"</span>";case"string":return'<span class="math-string">'+C+"</span>";case"boolean":return'<span class="math-boolean">'+C+"</span>";case"null":return'<span class="math-null-symbol">'+C+"</span>";case"undefined":return'<span class="math-undefined">'+C+"</span>";default:return'<span class="math-symbol">'+C+"</span>"}}toJSON(){return{mathjs:GT,value:this.value}}static fromJSON(y){return new b(y.value)}_toTex(y){var C=this._toString(y),A=pi(this.value);switch(A){case"string":return"\\mathtt{"+xI(C)+"}";case"number":case"BigNumber":if(!("BigNumber"===A?this.value.isFinite():isFinite(this.value)))return this.value.valueOf()<0?"-\\infty":"\\infty";var R=C.toLowerCase().indexOf("e");return-1!==R?C.substring(0,R)+"\\cdot10^{"+C.substring(R+1)+"}":C;case"bigint":return C.toString();case"Fraction":return this.value.toLatex();default:return C}}}return ud(b,"name",GT),b},{isClass:!0,isNode:!0}),KT="RangeNode",QT=re(KT,["Node"],p=>{var{Node:m}=p;function b(y,C,A){var k=ed(y,C,A),R={},O=ed(y.start,C,A);if(R.start=null!==O&&O<=k||"all"===C,y.step){var F=ed(y.step,C,A);R.step=null!==F&&F<=k||"all"===C}var B=ed(y.end,C,A);return R.end=null!==B&&B<=k||"all"===C,R}class _ extends m{constructor(C,A,k){if(super(),!uo(C))throw new TypeError("Node expected");if(!uo(A))throw new TypeError("Node expected");if(k&&!uo(k))throw new TypeError("Node expected");if(arguments.length>3)throw new Error("Too many arguments");this.start=C,this.end=A,this.step=k||null}get type(){return KT}get isRangeNode(){return!0}needsEnd(){return this.filter(function(A){return Gn(A)&&"end"===A.name}).length>0}_compile(C,A){var k=C.range,R=this.start._compile(C,A),O=this.end._compile(C,A);if(this.step){var F=this.step._compile(C,A);return function(H,G,J){return k(R(H,G,J),O(H,G,J),F(H,G,J))}}return function(H,G,J){return k(R(H,G,J),O(H,G,J))}}forEach(C){C(this.start,"start",this),C(this.end,"end",this),this.step&&C(this.step,"step",this)}map(C){return new _(this._ifNode(C(this.start,"start",this)),this._ifNode(C(this.end,"end",this)),this.step&&this._ifNode(C(this.step,"step",this)))}clone(){return new _(this.start,this.end,this.step&&this.step)}_toString(C){var R,k=b(this,C&&C.parenthesis?C.parenthesis:"keep",C&&C.implicit),O=this.start.toString(C);if(k.start&&(O="("+O+")"),R=O,this.step){var F=this.step.toString(C);k.step&&(F="("+F+")"),R+=":"+F}var B=this.end.toString(C);return k.end&&(B="("+B+")"),R+":"+B}toJSON(){return{mathjs:KT,start:this.start,end:this.end,step:this.step}}static fromJSON(C){return new _(C.start,C.end,C.step)}_toHTML(C){var R,k=b(this,C&&C.parenthesis?C.parenthesis:"keep",C&&C.implicit),O=this.start.toHTML(C);if(k.start&&(O='<span class="math-parenthesis math-round-parenthesis">(</span>'+O+'<span class="math-parenthesis math-round-parenthesis">)</span>'),R=O,this.step){var F=this.step.toHTML(C);k.step&&(F='<span class="math-parenthesis math-round-parenthesis">(</span>'+F+'<span class="math-parenthesis math-round-parenthesis">)</span>'),R+='<span class="math-operator math-range-operator">:</span>'+F}var B=this.end.toHTML(C);return k.end&&(B='<span class="math-parenthesis math-round-parenthesis">(</span>'+B+'<span class="math-parenthesis math-round-parenthesis">)</span>'),R+'<span class="math-operator math-range-operator">:</span>'+B}_toTex(C){var k=b(this,C&&C.parenthesis?C.parenthesis:"keep",C&&C.implicit),R=this.start.toTex(C);if(k.start&&(R="\\left(".concat(R,"\\right)")),this.step){var O=this.step.toTex(C);k.step&&(O="\\left(".concat(O,"\\right)")),R+=":"+O}var F=this.end.toTex(C);return k.end&&(F="\\left(".concat(F,"\\right)")),R+":"+F}}return ud(_,"name",KT),_},{isClass:!0,isNode:!0}),YT=re("reviver",["classes"],p=>{var{classes:m}=p;return function(_,y){var C=m[y&&y.mathjs];return C&&"function"==typeof C.fromJSON?C.fromJSON(y):y}}),XT=re("Chain",["?on","math","typed"],p=>{var{on:m,math:b,typed:_}=p;function y(O){if(!(this instanceof y))throw new SyntaxError("Constructor must be called with the new operator");this.value=ri(O)?O.value:O}function A(O,F){Ii(y.prototype,O,function(){var H=F();if("function"==typeof H)return k(H)})}function k(O){return function(){if(0===arguments.length)return new y(O(this.value));for(var F=[this.value],B=0;B<arguments.length;B++)F[B+1]=arguments[B];if(_.isTypedFunction(O)){var H=_.resolve(O,F);if(1===H.params.length)throw new Error("chain function "+O.name+" cannot match rest parameter between chain value and additional arguments.");return new y(H.implementation.apply(O,F))}return new y(O.apply(O,F))}}y.prototype.type="Chain",y.prototype.isChain=!0,y.prototype.done=function(){return this.value},y.prototype.valueOf=function(){return this.value},y.prototype.toString=function(){return xs(this.value)},y.prototype.toJSON=function(){return{mathjs:"Chain",value:this.value}},y.fromJSON=function(O){return new y(O.value)},y.createProxy=function(O,F){if("string"==typeof O)!function C(O,F){"function"==typeof F&&(y.prototype[O]=k(F))}(O,F);else{var B=function(J){Jt(O,J)&&void 0===R[J]&&A(J,()=>O[J])};for(var H in O)B(H)}};var R={expression:!0,docs:!0,type:!0,classes:!0,json:!0,error:!0,isChain:!0};return y.createProxy(b),m&&m("import",function(O,F,B){B||A(O,F)}),y},{isClass:!0}),Qw="FunctionAssignmentNode",OI=re(Qw,["typed","Node"],p=>{var{typed:m,Node:b}=p;function _(C,A,k){var R=ed(C,A,k),O=ed(C.expr,A,k);return"all"===A||null!==O&&O<=R}class y extends b{constructor(A,k,R){if(super(),"string"!=typeof A)throw new TypeError('String expected for parameter "name"');if(!Array.isArray(k))throw new TypeError('Array containing strings or objects expected for parameter "params"');if(!uo(R))throw new TypeError('Node expected for parameter "expr"');if(YO.has(A))throw new Error('Illegal function name, "'+A+'" is a reserved keyword');var O=new Set;for(var F of k){var B="string"==typeof F?F:F.name;if(O.has(B))throw new Error('Duplicate parameter name "'.concat(B,'"'));O.add(B)}this.name=A,this.params=k.map(function(H){return H&&H.name||H}),this.types=k.map(function(H){return H&&H.type||"any"}),this.expr=R}get type(){return Qw}get isFunctionAssignmentNode(){return!0}_compile(A,k){var R=Object.create(k);gf(this.params,function(J){R[J]=!0});var O=this.expr._compile(A,R),F=this.name,B=this.params,H=Tv(this.types,","),G=F+"("+Tv(this.params,", ")+")";return function(te,be,we){var Le={};Le[H]=function(){for(var Te=Object.create(be),De=0;De<B.length;De++)Te[B[De]]=arguments[De];return O(te,Te,we)};var de=m(F,Le);return de.syntax=G,te.set(F,de),de}}forEach(A){A(this.expr,"expr",this)}map(A){var k=this._ifNode(A(this.expr,"expr",this));return new y(this.name,this.params.slice(0),k)}clone(){return new y(this.name,this.params.slice(0),this.expr)}_toString(A){var k=A&&A.parenthesis?A.parenthesis:"keep",R=this.expr.toString(A);return _(this,k,A&&A.implicit)&&(R="("+R+")"),this.name+"("+this.params.join(", ")+") = "+R}toJSON(){var A=this.types;return{mathjs:Qw,name:this.name,params:this.params.map(function(k,R){return{name:k,type:A[R]}}),expr:this.expr}}static fromJSON(A){return new y(A.name,A.params,A.expr)}_toHTML(A){for(var k=A&&A.parenthesis?A.parenthesis:"keep",R=[],O=0;O<this.params.length;O++)R.push('<span class="math-symbol math-parameter">'+Xd(this.params[O])+"</span>");var F=this.expr.toHTML(A);return _(this,k,A&&A.implicit)&&(F='<span class="math-parenthesis math-round-parenthesis">(</span>'+F+'<span class="math-parenthesis math-round-parenthesis">)</span>'),'<span class="math-function">'+Xd(this.name)+'</span><span class="math-parenthesis math-round-parenthesis">(</span>'+R.join('<span class="math-separator">,</span>')+'<span class="math-parenthesis math-round-parenthesis">)</span><span class="math-operator math-assignment-operator math-variable-assignment-operator math-binary-operator">=</span>'+F}_toTex(A){var k=A&&A.parenthesis?A.parenthesis:"keep",R=this.expr.toTex(A);return _(this,k,A&&A.implicit)&&(R="\\left(".concat(R,"\\right)")),"\\mathrm{"+this.name+"}\\left("+this.params.map(o2).join(",")+"\\right)="+R}}return ud(y,"name",Qw),y},{isClass:!0,isNode:!0}),ZT=re("chain",["typed","Chain"],p=>{var{typed:m,Chain:b}=p;return m("chain",{"":function(){return new b},any:function(y){return new b(y)}})}),Yw="IndexNode",JT=re(Yw,["Node","size"],p=>{var{Node:m,size:b}=p;class _ extends m{constructor(C,A){if(super(),this.dimensions=C,this.dotNotation=A||!1,!Array.isArray(C)||!C.every(uo))throw new TypeError('Array containing Nodes expected for parameter "dimensions"');if(this.dotNotation&&!this.isObjectProperty())throw new Error("dotNotation only applicable for object properties")}get type(){return Yw}get isIndexNode(){return!0}_compile(C,A){var k=Hu(this.dimensions,function(O,F){if(O.filter(J=>J.isSymbolNode&&"end"===J.name).length>0){var H=Object.create(A);H.end=!0;var G=O._compile(C,H);return function(te,be,we){if(!ut(we)&&!dt(we)&&!Ae(we))throw new TypeError('Cannot resolve "end": context must be a Matrix, Array, or string but is '+pi(we));var Le=b(we).valueOf(),de=Object.create(be);return de.end=Le[F],G(te,de,we)}}return O._compile(C,A)}),R=X(C,"index");return function(F,B,H){var G=Hu(k,function(J){return J(F,B,H)});return R(...G)}}forEach(C){for(var A=0;A<this.dimensions.length;A++)C(this.dimensions[A],"dimensions["+A+"]",this)}map(C){for(var A=[],k=0;k<this.dimensions.length;k++)A[k]=this._ifNode(C(this.dimensions[k],"dimensions["+k+"]",this));return new _(A,this.dotNotation)}clone(){return new _(this.dimensions.slice(0),this.dotNotation)}isObjectProperty(){return 1===this.dimensions.length&&Qi(this.dimensions[0])&&"string"==typeof this.dimensions[0].value}getObjectProperty(){return this.isObjectProperty()?this.dimensions[0].value:null}_toString(C){return this.dotNotation?"."+this.getObjectProperty():"["+this.dimensions.join(", ")+"]"}toJSON(){return{mathjs:Yw,dimensions:this.dimensions,dotNotation:this.dotNotation}}static fromJSON(C){return new _(C.dimensions,C.dotNotation)}_toHTML(C){for(var A=[],k=0;k<this.dimensions.length;k++)A[k]=this.dimensions[k].toHTML();return this.dotNotation?'<span class="math-operator math-accessor-operator">.</span><span class="math-symbol math-property">'+Xd(this.getObjectProperty())+"</span>":'<span class="math-parenthesis math-square-parenthesis">[</span>'+A.join('<span class="math-separator">,</span>')+'<span class="math-parenthesis math-square-parenthesis">]</span>'}_toTex(C){var A=this.dimensions.map(function(k){return k.toTex(C)});return this.dotNotation?"."+this.getObjectProperty():"_{"+A.join(",")+"}"}}return ud(_,"name",Yw),_},{isClass:!0,isNode:!0});function yh(p){return p&&p.isIndexError?new bc(p.index+1,p.min+1,void 0!==p.max?p.max+1:void 0):p}function FI(p){var{subset:m}=p;return function(_,y){try{if(Array.isArray(_))return m(_,y);if(_&&"function"==typeof _.subset)return _.subset(y);if("string"==typeof _)return m(_,y);if("object"==typeof _){if(!y.isObjectProperty())throw new TypeError("Cannot apply a numeric index as object property");return X(_,y.getObjectProperty())}throw new TypeError("Cannot apply index: unsupported type of object")}catch(C){throw yh(C)}}}var oE="AccessorNode",eM=re(oE,["subset","Node"],p=>{var{subset:m,Node:b}=p,_=FI({subset:m});function y(A){return!(gn(A)||Nn(A)||Qi(A)||eo(A)||mi(A)||yt(A)||Gn(A))}class C extends b{constructor(k,R){if(super(),!uo(k))throw new TypeError('Node expected for parameter "object"');if(!as(R))throw new TypeError('IndexNode expected for parameter "index"');this.object=k,this.index=R}get name(){return this.index?this.index.isObjectProperty()?this.index.getObjectProperty():"":this.object.name||""}get type(){return oE}get isAccessorNode(){return!0}_compile(k,R){var O=this.object._compile(k,R),F=this.index._compile(k,R);if(this.index.isObjectProperty()){var B=this.index.getObjectProperty();return function(G,J,te){return X(O(G,J,te),B)}}return function(G,J,te){var be=O(G,J,te),we=F(G,J,be);return _(be,we)}}forEach(k){k(this.object,"object",this),k(this.index,"index",this)}map(k){return new C(this._ifNode(k(this.object,"object",this)),this._ifNode(k(this.index,"index",this)))}clone(){return new C(this.object,this.index)}_toString(k){var R=this.object.toString(k);return y(this.object)&&(R="("+R+")"),R+this.index.toString(k)}_toHTML(k){var R=this.object.toHTML(k);return y(this.object)&&(R='<span class="math-parenthesis math-round-parenthesis">(</span>'+R+'<span class="math-parenthesis math-round-parenthesis">)</span>'),R+this.index.toHTML(k)}_toTex(k){var R=this.object.toTex(k);return y(this.object)&&(R="\\left(' + object + '\\right)"),R+this.index.toTex(k)}toJSON(){return{mathjs:oE,object:this.object,index:this.index}}static fromJSON(k){return new C(k.object,k.index)}}return ud(C,"name",oE),C},{isClass:!0,isNode:!0}),tM="AssignmentNode",nM=re(tM,["subset","?matrix","Node"],p=>{var{subset:m,matrix:b,Node:_}=p,y=FI({subset:m}),C=function oF(p){var{subset:m,matrix:b}=p;return function(y,C,A){try{if(Array.isArray(y))return b(y).subset(C,A).valueOf().forEach((R,O)=>{y[O]=R}),y;if(y&&"function"==typeof y.subset)return y.subset(C,A);if("string"==typeof y)return m(y,C,A);if("object"==typeof y){if(!C.isObjectProperty())throw TypeError("Cannot apply a numeric index as object property");return ie(y,C.getObjectProperty(),A),y}throw new TypeError("Cannot apply index: unsupported type of object")}catch(R){throw yh(R)}}}({subset:m,matrix:b});function A(R,O,F){O||(O="keep");var B=ed(R,O,F),H=ed(R.value,O,F);return"all"===O||null!==H&&H<=B}class k extends _{constructor(O,F,B){if(super(),this.object=O,this.index=B?F:null,this.value=B||F,!Gn(O)&&!gn(O))throw new TypeError('SymbolNode or AccessorNode expected as "object"');if(Gn(O)&&"end"===O.name)throw new Error('Cannot assign to symbol "end"');if(this.index&&!as(this.index))throw new TypeError('IndexNode expected as "index"');if(!uo(this.value))throw new TypeError('Node expected as "value"')}get name(){return this.index?this.index.isObjectProperty()?this.index.getObjectProperty():"":this.object.name||""}get type(){return tM}get isAssignmentNode(){return!0}_compile(O,F){var B=this.object._compile(O,F),H=this.index?this.index._compile(O,F):null,G=this.value._compile(O,F),J=this.object.name;if(this.index){if(this.index.isObjectProperty()){var te=this.index.getObjectProperty();return function(Te,De,pe){var Be=B(Te,De,pe),We=G(Te,De,pe);return ie(Be,te,We),We}}if(Gn(this.object))return function(Te,De,pe){var Be=B(Te,De,pe),We=G(Te,De,pe),ke=H(Te,De,Be);return Te.set(J,C(Be,ke,We)),We};var be=this.object.object._compile(O,F);if(this.object.index.isObjectProperty()){var we=this.object.index.getObjectProperty();return function(Te,De,pe){var Be=be(Te,De,pe),We=X(Be,we),ke=H(Te,De,We),ze=G(Te,De,pe);return ie(Be,we,C(We,ke,ze)),ze}}var Le=this.object.index._compile(O,F);return function(Te,De,pe){var Be=be(Te,De,pe),We=Le(Te,De,Be),ke=y(Be,We),ze=H(Te,De,ke),et=G(Te,De,pe);return C(Be,We,C(ke,ze,et)),et}}if(!Gn(this.object))throw new TypeError("SymbolNode expected as object");return function(Te,De,pe){var Be=G(Te,De,pe);return Te.set(J,Be),Be}}forEach(O){O(this.object,"object",this),this.index&&O(this.index,"index",this),O(this.value,"value",this)}map(O){var F=this._ifNode(O(this.object,"object",this)),B=this.index?this._ifNode(O(this.index,"index",this)):null,H=this._ifNode(O(this.value,"value",this));return new k(F,B,H)}clone(){return new k(this.object,this.index,this.value)}_toString(O){var F=this.object.toString(O),B=this.index?this.index.toString(O):"",H=this.value.toString(O);return A(this,O&&O.parenthesis,O&&O.implicit)&&(H="("+H+")"),F+B+" = "+H}toJSON(){return{mathjs:tM,object:this.object,index:this.index,value:this.value}}static fromJSON(O){return new k(O.object,O.index,O.value)}_toHTML(O){var F=this.object.toHTML(O),B=this.index?this.index.toHTML(O):"",H=this.value.toHTML(O);return A(this,O&&O.parenthesis,O&&O.implicit)&&(H='<span class="math-paranthesis math-round-parenthesis">(</span>'+H+'<span class="math-paranthesis math-round-parenthesis">)</span>'),F+B+'<span class="math-operator math-assignment-operator math-variable-assignment-operator math-binary-operator">=</span>'+H}_toTex(O){var F=this.object.toTex(O),B=this.index?this.index.toTex(O):"",H=this.value.toTex(O);return A(this,O&&O.parenthesis,O&&O.implicit)&&(H="\\left(".concat(H,"\\right)")),F+B+"="+H}}return ud(k,"name",tM),k},{isClass:!0,isNode:!0}),NI=re("SymbolNode",["math","?Unit","Node"],p=>{var{math:m,Unit:b,Node:_}=p;function y(A){return!!b&&b.isValuelessUnit(A)}class C extends _{constructor(k){if(super(),"string"!=typeof k)throw new TypeError('String expected for parameter "name"');this.name=k}get type(){return"SymbolNode"}get isSymbolNode(){return!0}_compile(k,R){var O=this.name;if(!0===R[O])return function(B,H,G){return X(H,O)};if(O in k)return function(B,H,G){return B.has(O)?B.get(O):X(k,O)};var F=y(O);return function(B,H,G){return B.has(O)?B.get(O):F?new b(null,O):C.onUndefinedSymbol(O)}}forEach(k){}map(k){return this.clone()}static onUndefinedSymbol(k){throw new Error("Undefined symbol "+k)}clone(){return new C(this.name)}_toString(k){return this.name}_toHTML(k){var R=Xd(this.name);return"true"===R||"false"===R?'<span class="math-symbol math-boolean">'+R+"</span>":"i"===R?'<span class="math-symbol math-imaginary-symbol">'+R+"</span>":"Infinity"===R?'<span class="math-symbol math-infinity-symbol">'+R+"</span>":"NaN"===R?'<span class="math-symbol math-nan-symbol">'+R+"</span>":"null"===R?'<span class="math-symbol math-null-symbol">'+R+"</span>":"undefined"===R?'<span class="math-symbol math-undefined-symbol">'+R+"</span>":'<span class="math-symbol">'+R+"</span>"}toJSON(){return{mathjs:"SymbolNode",name:this.name}}static fromJSON(k){return new C(k.name)}_toTex(k){var R=!1;typeof m[this.name]>"u"&&y(this.name)&&(R=!0);var O=o2(this.name,R);return"\\"===O[0]?O:" "+O}}return C},{isClass:!0,isNode:!0}),RI="FunctionNode",iM=re(RI,["math","Node","SymbolNode"],p=>{var m,{math:b,Node:_,SymbolNode:y}=p,C=R=>xs(R,{truncate:78});function A(R,O,F){for(var J,B="",H=/\$(?:\{([a-z_][a-z_0-9]*)(?:\[([0-9]+)\])?\}|\$)/gi,G=0;null!==(J=H.exec(R));)if(B+=R.substring(G,J.index),G=J.index,"$$"===J[0])B+="$",G++;else{G+=J[0].length;var te=O[J[1]];if(!te)throw new ReferenceError("Template: Property "+J[1]+" does not exist.");if(void 0===J[2])switch(typeof te){case"string":B+=te;break;case"object":if(uo(te))B+=te.toTex(F);else{if(!Array.isArray(te))throw new TypeError("Template: "+J[1]+" has to be a Node, String or array of Nodes");B+=te.map(function(be,we){if(uo(be))return be.toTex(F);throw new TypeError("Template: "+J[1]+"["+we+"] is not a Node.")}).join(",")}break;default:throw new TypeError("Template: "+J[1]+" has to be a Node, String or array of Nodes")}else{if(!uo(te[J[2]]&&te[J[2]]))throw new TypeError("Template: "+J[1]+"["+J[2]+"] is not a Node.");B+=te[J[2]].toTex(F)}}return B+R.slice(G)}class k extends _{constructor(O,F){if(super(),"string"==typeof O&&(O=new y(O)),!uo(O))throw new TypeError('Node expected as parameter "fn"');if(!Array.isArray(F)||!F.every(uo))throw new TypeError('Array containing Nodes expected for parameter "args"');this.fn=O,this.args=F||[]}get name(){return this.fn.name||""}get type(){return RI}get isFunctionNode(){return!0}_compile(O,F){var B=this.args.map(We=>We._compile(O,F));if(!Gn(this.fn)){if(gn(this.fn)&&as(this.fn.index)&&this.fn.index.isObjectProperty()){var Le=this.fn.object._compile(O,F),de=this.fn.index.getObjectProperty(),Te=this.args;return function(ke,ze,et){var pt=Le(ke,ze,et),$t=function Ee(p,m){if(!he(p,m))throw new Error('No access to method "'+m+'"');return p[m]}(pt,de);if(null!=$t&&$t.rawArgs)return $t(Te,O,nE(ke,ze));var Zt=B.map(Kt=>Kt(ke,ze,et));return $t.apply(pt,Zt)}}var De=this.fn.toString(),pe=this.fn._compile(O,F),Be=this.args;return function(ke,ze,et){var pt=pe(ke,ze,et);if("function"!=typeof pt)throw new TypeError("Expression '".concat(De,"' did not evaluate to a function; value is:")+"\n ".concat(C(pt)));if(pt.rawArgs)return pt(Be,O,nE(ke,ze));var $t=B.map(Zt=>Zt(ke,ze,et));return pt.apply(pt,$t)}}var H=this.fn.name;if(F[H]){var we=this.args;return function(ke,ze,et){var pt=X(ze,H);if("function"!=typeof pt)throw new TypeError("Argument '".concat(H,"' was not a function; received: ").concat(C(pt)));if(pt.rawArgs)return pt(we,O,nE(ke,ze));var $t=B.map(Zt=>Zt(ke,ze,et));return pt.apply(pt,$t)}}var G=H in O?X(O,H):void 0,te=We=>{var ke;if(We.has(H))ke=We.get(H);else{if(!(H in O))return k.onUndefinedFunction(H);ke=X(O,H)}if("function"==typeof ke)return ke;throw new TypeError("'".concat(H,"' is not a function; its value is:\n ").concat(C(ke)))};if("function"==typeof G&&!0===G.rawArgs){var be=this.args;return function(ke,ze,et){var pt=te(ke);return!0===pt.rawArgs?pt(be,O,nE(ke,ze)):pt(...B.map(Zt=>Zt(ke,ze,et)))}}switch(B.length){case 0:return function(ke,ze,et){return te(ke)()};case 1:return function(ke,ze,et){return te(ke)((0,B[0])(ke,ze,et))};case 2:return function(ke,ze,et){var pt=te(ke),Zt=B[1];return pt((0,B[0])(ke,ze,et),Zt(ke,ze,et))};default:return function(ke,ze,et){return te(ke)(...B.map(Zt=>Zt(ke,ze,et)))}}}forEach(O){O(this.fn,"fn",this);for(var F=0;F<this.args.length;F++)O(this.args[F],"args["+F+"]",this)}map(O){for(var F=this._ifNode(O(this.fn,"fn",this)),B=[],H=0;H<this.args.length;H++)B[H]=this._ifNode(O(this.args[H],"args["+H+"]",this));return new k(F,B)}clone(){return new k(this.fn,this.args.slice(0))}toString(O){var F,B=this.fn.toString(O);return O&&"object"==typeof O.handler&&Jt(O.handler,B)&&(F=O.handler[B](this,O)),typeof F<"u"?F:super.toString(O)}_toString(O){var F=this.args.map(function(H){return H.toString(O)});return(Ur(this.fn)?"("+this.fn.toString(O)+")":this.fn.toString(O))+"("+F.join(", ")+")"}toJSON(){return{mathjs:RI,fn:this.fn,args:this.args}}_toHTML(O){var F=this.args.map(function(B){return B.toHTML(O)});return'<span class="math-function">'+Xd(this.fn)+'</span><span class="math-paranthesis math-round-parenthesis">(</span>'+F.join('<span class="math-separator">,</span>')+'<span class="math-paranthesis math-round-parenthesis">)</span>'}toTex(O){var F;return O&&"object"==typeof O.handler&&Jt(O.handler,this.name)&&(F=O.handler[this.name](this,O)),typeof F<"u"?F:super.toTex(O)}_toTex(O){var B,H,F=this.args.map(function(G){return G.toTex(O)});switch(UT[this.name]&&(B=UT[this.name]),b[this.name]&&("function"==typeof b[this.name].toTex||"object"==typeof b[this.name].toTex||"string"==typeof b[this.name].toTex)&&(B=b[this.name].toTex),typeof B){case"function":H=B(this,O);break;case"string":H=A(B,this,O);break;case"object":switch(typeof B[F.length]){case"function":H=B[F.length](this,O);break;case"string":H=A(B[F.length],this,O)}}return typeof H<"u"?H:A("\\mathrm{${name}}\\left(${args}\\right)",this,O)}getIdentifier(){return this.type+":"+this.name}}return m=k,ud(k,"name",RI),ud(k,"onUndefinedFunction",function(R){throw new Error("Undefined function "+R)}),ud(k,"fromJSON",function(R){return new m(R.fn,R.args)}),k},{isClass:!0,isNode:!0}),rM=re("parse",["typed","numeric","config","AccessorNode","ArrayNode","AssignmentNode","BlockNode","ConditionalNode","ConstantNode","FunctionAssignmentNode","FunctionNode","IndexNode","ObjectNode","OperatorNode","ParenthesisNode","RangeNode","RelationalNode","SymbolNode"],p=>{var{typed:m,numeric:b,config:_,AccessorNode:y,ArrayNode:C,AssignmentNode:A,BlockNode:k,ConditionalNode:R,ConstantNode:O,FunctionAssignmentNode:F,FunctionNode:B,IndexNode:H,ObjectNode:G,OperatorNode:J,ParenthesisNode:te,RangeNode:be,RelationalNode:we,SymbolNode:Le}=p,de=m("parse",{string:function(ii){return ki(ii,{})},"Array | Matrix":function(ii){return Te(ii,{})},"string, Object":function(ii,Dr){return ki(ii,void 0!==Dr.nodes?Dr.nodes:{})},"Array | Matrix, Object":Te});function Te(ot){var ii=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},Dr=void 0!==ii.nodes?ii.nodes:{};return ps(ot,function(Fo){if("string"!=typeof Fo)throw new TypeError("String expected");return ki(Fo,Dr)})}var De={NULL:0,DELIMITER:1,NUMBER:2,SYMBOL:3,UNKNOWN:4},pe={",":!0,"(":!0,")":!0,"[":!0,"]":!0,"{":!0,"}":!0,'"':!0,"'":!0,";":!0,"+":!0,"-":!0,"*":!0,".*":!0,"/":!0,"./":!0,"%":!0,"^":!0,".^":!0,"~":!0,"!":!0,"&":!0,"|":!0,"^|":!0,"=":!0,":":!0,"?":!0,"==":!0,"!=":!0,"<":!0,">":!0,"<=":!0,">=":!0,"<<":!0,">>":!0,">>>":!0},Be={mod:!0,to:!0,in:!0,and:!0,xor:!0,or:!0,not:!0},We={true:!0,false:!1,null:null,undefined:void 0},ke=["NaN","Infinity"],ze={'"':'"',"'":"'","\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"};function pt(ot,ii){return ot.expression.substr(ot.index,ii)}function $t(ot){return pt(ot,1)}function Zt(ot){ot.index++}function Kt(ot){return ot.expression.charAt(ot.index-1)}function lt(ot){return ot.expression.charAt(ot.index+1)}function st(ot){for(ot.tokenType=De.NULL,ot.token="",ot.comment="";;){if("#"===$t(ot))for(;"\n"!==$t(ot)&&""!==$t(ot);)ot.comment+=$t(ot),Zt(ot);if(!de.isWhitespace($t(ot),ot.nestingLevel))break;Zt(ot)}if(""!==$t(ot)){if("\n"===$t(ot)&&!ot.nestingLevel)return ot.tokenType=De.DELIMITER,ot.token=$t(ot),void Zt(ot);var ii=$t(ot),Dr=pt(ot,2),Fo=pt(ot,3);if(3===Fo.length&&pe[Fo])return ot.tokenType=De.DELIMITER,ot.token=Fo,Zt(ot),Zt(ot),void Zt(ot);if(2===Dr.length&&pe[Dr])return ot.tokenType=De.DELIMITER,ot.token=Dr,Zt(ot),void Zt(ot);if(pe[ii])return ot.tokenType=De.DELIMITER,ot.token=ii,void Zt(ot);if(de.isDigitDot(ii)){ot.tokenType=De.NUMBER;var Wl=pt(ot,2);if("0b"===Wl||"0o"===Wl||"0x"===Wl){for(ot.token+=$t(ot),Zt(ot),ot.token+=$t(ot),Zt(ot);de.isHexDigit($t(ot));)ot.token+=$t(ot),Zt(ot);if("."===$t(ot))for(ot.token+=".",Zt(ot);de.isHexDigit($t(ot));)ot.token+=$t(ot),Zt(ot);else if("i"===$t(ot))for(ot.token+="i",Zt(ot);de.isDigit($t(ot));)ot.token+=$t(ot),Zt(ot);return}if("."===$t(ot)){if(ot.token+=$t(ot),Zt(ot),!de.isDigit($t(ot)))return void(ot.tokenType=De.DELIMITER)}else{for(;de.isDigit($t(ot));)ot.token+=$t(ot),Zt(ot);de.isDecimalMark($t(ot),lt(ot))&&(ot.token+=$t(ot),Zt(ot))}for(;de.isDigit($t(ot));)ot.token+=$t(ot),Zt(ot);if("E"===$t(ot)||"e"===$t(ot))if(de.isDigit(lt(ot))||"-"===lt(ot)||"+"===lt(ot)){if(ot.token+=$t(ot),Zt(ot),("+"===$t(ot)||"-"===$t(ot))&&(ot.token+=$t(ot),Zt(ot)),!de.isDigit($t(ot)))throw du(ot,'Digit expected, got "'+$t(ot)+'"');for(;de.isDigit($t(ot));)ot.token+=$t(ot),Zt(ot);if(de.isDecimalMark($t(ot),lt(ot)))throw du(ot,'Digit expected, got "'+$t(ot)+'"')}else if("."===lt(ot))throw Zt(ot),du(ot,'Digit expected, got "'+$t(ot)+'"')}else{if(!de.isAlpha($t(ot),Kt(ot),lt(ot))){for(ot.tokenType=De.UNKNOWN;""!==$t(ot);)ot.token+=$t(ot),Zt(ot);throw du(ot,'Syntax error in part "'+ot.token+'"')}for(;de.isAlpha($t(ot),Kt(ot),lt(ot))||de.isDigit($t(ot));)ot.token+=$t(ot),Zt(ot);ot.tokenType=Jt(Be,ot.token)?De.DELIMITER:De.SYMBOL}}else ot.tokenType=De.DELIMITER}function En(ot){do{st(ot)}while("\n"===ot.token)}function _t(ot){ot.nestingLevel++}function di(ot){ot.nestingLevel--}function ki(ot,ii){var Dr=function et(){return{extraNodes:{},expression:"",comment:"",index:0,token:"",tokenType:De.NULL,nestingLevel:0,conditionalLevel:null}}();e(Dr,{expression:ot,extraNodes:ii}),st(Dr);var Fo=function Xn(ot){var ii,Dr=[];for(""!==ot.token&&"\n"!==ot.token&&";"!==ot.token&&(ii=_n(ot),ot.comment&&(ii.comment=ot.comment));"\n"===ot.token||";"===ot.token;)0===Dr.length&&ii&&Dr.push({node:ii,visible:";"!==ot.token}),st(ot),"\n"!==ot.token&&";"!==ot.token&&""!==ot.token&&(ii=_n(ot),ot.comment&&(ii.comment=ot.comment),Dr.push({node:ii,visible:";"!==ot.token}));return Dr.length>0?new k(Dr):(ii||(ii=new O(void 0),ot.comment&&(ii.comment=ot.comment)),ii)}(Dr);if(""!==Dr.token)throw Dr.tokenType===De.DELIMITER?uO(Dr,"Unexpected operator "+Dr.token):du(Dr,'Unexpected part "'+Dr.token+'"');return Fo}function _n(ot){var ii,Dr,Fo,Wl,gc=function Ni(ot){for(var ii=function kr(ot){for(var ii=Pi(ot);"or"===ot.token;)En(ot),ii=new J("or","or",[ii,Pi(ot)]);return ii}(ot);"?"===ot.token;){var Dr=ot.conditionalLevel;ot.conditionalLevel=ot.nestingLevel,En(ot);var Fo=ii,Wl=_n(ot);if(":"!==ot.token)throw du(ot,"False part of conditional expression expected");ot.conditionalLevel=null,En(ot);var gc=_n(ot);ii=new R(Fo,Wl,gc),ot.conditionalLevel=Dr}return ii}(ot);if("="===ot.token){if(Gn(gc))return ii=gc.name,En(ot),Fo=_n(ot),new A(new Le(ii),Fo);if(gn(gc))return En(ot),Fo=_n(ot),new A(gc.object,gc.index,Fo);if(eo(gc)&&Gn(gc.fn)&&(Wl=!0,Dr=[],ii=gc.name,gc.args.forEach(function(gE,q5){Gn(gE)?Dr[q5]=gE.name:Wl=!1}),Wl))return En(ot),Fo=_n(ot),new F(ii,Dr,Fo);throw du(ot,"Invalid left hand side of assignment operator =")}return gc}function Pi(ot){for(var ii=nr(ot);"xor"===ot.token;)En(ot),ii=new J("xor","xor",[ii,nr(ot)]);return ii}function nr(ot){for(var ii=Sr(ot);"and"===ot.token;)En(ot),ii=new J("and","and",[ii,Sr(ot)]);return ii}function Sr(ot){for(var ii=ir(ot);"|"===ot.token;)En(ot),ii=new J("|","bitOr",[ii,ir(ot)]);return ii}function ir(ot){for(var ii=lr(ot);"^|"===ot.token;)En(ot),ii=new J("^|","bitXor",[ii,lr(ot)]);return ii}function lr(ot){for(var ii=wr(ot);"&"===ot.token;)En(ot),ii=new J("&","bitAnd",[ii,wr(ot)]);return ii}function wr(ot){for(var ii=[$r(ot)],Dr=[],Fo={"==":"equal","!=":"unequal","<":"smaller",">":"larger","<=":"smallerEq",">=":"largerEq"};Jt(Fo,ot.token);)Dr.push({name:ot.token,fn:Fo[ot.token]}),En(ot),ii.push($r(ot));return 1===ii.length?ii[0]:2===ii.length?new J(Dr[0].name,Dr[0].fn,ii):new we(Dr.map(gc=>gc.fn),ii)}function $r(ot){var ii,Dr,Fo,Wl;ii=Io(ot);for(var gc={"<<":"leftShift",">>":"rightArithShift",">>>":"rightLogShift"};Jt(gc,ot.token);)Fo=gc[Dr=ot.token],En(ot),Wl=[ii,Io(ot)],ii=new J(Dr,Fo,Wl);return ii}function Io(ot){var ii,Dr,Fo,Wl;ii=ms(ot);for(var gc={to:"to",in:"to"};Jt(gc,ot.token);)Fo=gc[Dr=ot.token],En(ot),"in"===Dr&&""===ot.token?ii=new J("*","multiply",[ii,new Le("in")],!0):(Wl=[ii,ms(ot)],ii=new J(Dr,Fo,Wl));return ii}function ms(ot){var ii,Dr=[];if(ii=":"===ot.token?new O(1):xn(ot),":"===ot.token&&ot.conditionalLevel!==ot.nestingLevel){for(Dr.push(ii);":"===ot.token&&Dr.length<3;)En(ot),Dr.push(")"===ot.token||"]"===ot.token||","===ot.token||""===ot.token?new Le("end"):xn(ot));ii=3===Dr.length?new be(Dr[0],Dr[2],Dr[1]):new be(Dr[0],Dr[1])}return ii}function xn(ot){var ii,Dr,Fo,Wl;ii=$n(ot);for(var gc={"+":"add","-":"subtract"};Jt(gc,ot.token);){Fo=gc[Dr=ot.token],En(ot);var gE=$n(ot);Wl=gE.isPercentage?[ii,new J("*","multiply",[ii,gE])]:[ii,gE],ii=new J(Dr,Fo,Wl)}return ii}function $n(ot){var ii,Dr,Fo,Wl;Dr=ii=Zi(ot);for(var gc={"*":"multiply",".*":"dotMultiply","/":"divide","./":"dotDivide"};Jt(gc,ot.token);)Wl=gc[Fo=ot.token],En(ot),Dr=Zi(ot),ii=new J(Fo,Wl,[ii,Dr]);return ii}function Zi(ot){var ii,Dr;for(Dr=ii=Fn(ot);ot.tokenType===De.SYMBOL||"in"===ot.token&&Qi(ii)||"in"===ot.token&&ci(ii)&&"unaryMinus"===ii.fn&&Qi(ii.args[0])||ot.tokenType===De.NUMBER&&!Qi(Dr)&&(!ci(Dr)||"!"===Dr.op)||"("===ot.token;)Dr=Fn(ot),ii=new J("*","multiply",[ii,Dr],!0);return ii}function Fn(ot){for(var ii=ti(ot),Dr=ii,Fo=[];"/"===ot.token&&Xr(Dr);){if(Fo.push(e({},ot)),En(ot),ot.tokenType!==De.NUMBER){e(ot,Fo.pop());break}if(Fo.push(e({},ot)),En(ot),ot.tokenType!==De.SYMBOL&&"("!==ot.token){Fo.pop(),e(ot,Fo.pop());break}e(ot,Fo.pop()),Fo.pop(),Dr=ti(ot),ii=new J("/","divide",[ii,Dr])}return ii}function ti(ot){var ii,Dr,Fo,Wl;ii=Mi(ot);for(var gc={"%":"mod",mod:"mod"};Jt(gc,ot.token);)Fo=gc[Dr=ot.token],En(ot),"%"===Dr&&ot.tokenType===De.DELIMITER&&"("!==ot.token?ii=new J("/","divide",[ii,new O(100)],!1,!0):(Wl=[ii,Mi(ot)],ii=new J(Dr,Fo,Wl));return ii}function Mi(ot){var ii,Dr,Fo,Wl={"-":"unaryMinus","+":"unaryPlus","~":"bitNot",not:"not"};return Jt(Wl,ot.token)?(Fo=Wl[ot.token],ii=ot.token,En(ot),Dr=[Mi(ot)],new J(ii,Fo,Dr)):function Pr(ot){var ii,Dr,Fo,Wl;return ii=function Br(ot){var ii,Dr,Fo;ii=function Go(ot){var ii=[];if(ot.tokenType===De.SYMBOL&&Jt(ot.extraNodes,ot.token)){var Dr=ot.extraNodes[ot.token];if(st(ot),"("===ot.token){if(ii=[],_t(ot),st(ot),")"!==ot.token)for(ii.push(_n(ot));","===ot.token;)st(ot),ii.push(_n(ot));if(")"!==ot.token)throw du(ot,"Parenthesis ) expected");di(ot),st(ot)}return new Dr(ii)}return function Zr(ot){var Dr;return ot.tokenType===De.SYMBOL||ot.tokenType===De.DELIMITER&&ot.token in Be?(Dr=ot.token,st(ot),rl(ot,Jt(We,Dr)?new O(We[Dr]):ke.includes(Dr)?new O(b(Dr,"number")):new Le(Dr))):function Nl(ot){var Dr;return'"'===ot.token||"'"===ot.token?(Dr=Ru(ot,ot.token),rl(ot,new O(Dr))):function Kd(ot){var ii,Dr,Fo,Wl;if("["===ot.token){if(_t(ot),st(ot),"]"!==ot.token){var gc=Mf(ot);if(";"===ot.token){for(Fo=1,Dr=[gc];";"===ot.token;)st(ot),"]"!==ot.token&&(Dr[Fo]=Mf(ot),Fo++);if("]"!==ot.token)throw du(ot,"End of matrix ] expected");di(ot),st(ot),Wl=Dr[0].items.length;for(var gE=1;gE<Fo;gE++)if(Dr[gE].items.length!==Wl)throw uO(ot,"Column dimensions mismatch ("+Dr[gE].items.length+" !== "+Wl+")");ii=new C(Dr)}else{if("]"!==ot.token)throw du(ot,"End of matrix ] expected");di(ot),st(ot),ii=gc}}else di(ot),st(ot),ii=new C([]);return rl(ot,ii)}return function b0(ot){if("{"===ot.token){_t(ot);var ii,Dr={};do{if(st(ot),"}"!==ot.token){if('"'===ot.token||"'"===ot.token)ii=Ru(ot,ot.token);else{if(!(ot.tokenType===De.SYMBOL||ot.tokenType===De.DELIMITER&&ot.token in Be))throw du(ot,"Symbol or string expected as object key");ii=ot.token,st(ot)}if(":"!==ot.token)throw du(ot,"Colon : expected after object key");st(ot),Dr[ii]=_n(ot)}}while(","===ot.token);if("}"!==ot.token)throw du(ot,"Comma , or bracket } expected after object value");di(ot),st(ot);var Fo=new G(Dr);return rl(ot,Fo)}return function j_(ot){var ii;if(ot.tokenType===De.NUMBER){ii=ot.token,st(ot);var Dr=Fr(ii,_),Fo=b(ii,Dr);return new O(Fo)}return function cO(ot){var ii;if("("===ot.token){if(_t(ot),st(ot),ii=_n(ot),")"!==ot.token)throw du(ot,"Parenthesis ) expected");return di(ot),st(ot),rl(ot,ii=new te(ii))}return function CM(ot){throw du(ot,""===ot.token?"Unexpected end of expression":"Value expected")}(ot)}(ot)}(ot)}(ot)}(ot)}(ot)}(ot)}(ot);for(var gc={"!":"factorial","'":"ctranspose"};Jt(gc,ot.token);)Fo=gc[Dr=ot.token],st(ot),ii=rl(ot,ii=new J(Dr,Fo,[ii]));return ii}(ot),("^"===ot.token||".^"===ot.token)&&(Fo="^"===(Dr=ot.token)?"pow":"dotPow",En(ot),Wl=[ii,Mi(ot)],ii=new J(Dr,Fo,Wl)),ii}(ot)}function rl(ot,ii,Dr){for(var Fo;("("===ot.token||"["===ot.token||"."===ot.token)&&(!Dr||Dr.includes(ot.token));)if(Fo=[],"("===ot.token){if(!Gn(ii)&&!gn(ii))return ii;if(_t(ot),st(ot),")"!==ot.token)for(Fo.push(_n(ot));","===ot.token;)st(ot),Fo.push(_n(ot));if(")"!==ot.token)throw du(ot,"Parenthesis ) expected");di(ot),st(ot),ii=new B(ii,Fo)}else if("["===ot.token){if(_t(ot),st(ot),"]"!==ot.token)for(Fo.push(_n(ot));","===ot.token;)st(ot),Fo.push(_n(ot));if("]"!==ot.token)throw du(ot,"Parenthesis ] expected");di(ot),st(ot),ii=new y(ii,new H(Fo))}else{if(st(ot),!(ot.tokenType===De.SYMBOL||ot.tokenType===De.DELIMITER&&ot.token in Be))throw du(ot,"Property name expected after dot");Fo.push(new O(ot.token)),st(ot),ii=new y(ii,new H(Fo,!0))}return ii}function Ru(ot,ii){for(var Dr="";""!==$t(ot)&&$t(ot)!==ii;)if("\\"===$t(ot)){Zt(ot);var Fo=$t(ot),Wl=ze[Fo];if(void 0!==Wl)Dr+=Wl,ot.index+=1;else{if("u"!==Fo)throw du(ot,"Bad escape character \\".concat(Fo));var gc=ot.expression.slice(ot.index+1,ot.index+5);if(!/^[0-9A-Fa-f]{4}$/.test(gc))throw du(ot,"Invalid unicode character \\u".concat(gc));Dr+=String.fromCharCode(parseInt(gc,16)),ot.index+=5}}else Dr+=$t(ot),Zt(ot);if(st(ot),ot.token!==ii)throw du(ot,"End of string ".concat(ii," expected"));return st(ot),Dr}function Mf(ot){for(var ii=[_n(ot)],Dr=1;","===ot.token;)st(ot),"]"!==ot.token&&";"!==ot.token&&(ii[Dr]=_n(ot),Dr++);return new C(ii)}function mE(ot){return ot.index-ot.token.length+1}function du(ot,ii){var Dr=mE(ot),Fo=new SyntaxError(ii+" (char "+Dr+")");return Fo.char=Dr,Fo}function uO(ot,ii){var Dr=mE(ot),Fo=new SyntaxError(ii+" (char "+Dr+")");return Fo.char=Dr,Fo}return de.isAlpha=function(ii,Dr,Fo){return de.isValidLatinOrGreek(ii)||de.isValidMathSymbol(ii,Fo)||de.isValidMathSymbol(Dr,ii)},de.isValidLatinOrGreek=function(ii){return/^[a-zA-Z_$\u00C0-\u02AF\u0370-\u03FF\u2100-\u214F]$/.test(ii)},de.isValidMathSymbol=function(ii,Dr){return/^[\uD835]$/.test(ii)&&/^[\uDC00-\uDFFF]$/.test(Dr)&&/^[^\uDC55\uDC9D\uDCA0\uDCA1\uDCA3\uDCA4\uDCA7\uDCA8\uDCAD\uDCBA\uDCBC\uDCC4\uDD06\uDD0B\uDD0C\uDD15\uDD1D\uDD3A\uDD3F\uDD45\uDD47-\uDD49\uDD51\uDEA6\uDEA7\uDFCC\uDFCD]$/.test(Dr)},de.isWhitespace=function(ii,Dr){return" "===ii||"\t"===ii||"\n"===ii&&Dr>0},de.isDecimalMark=function(ii,Dr){return"."===ii&&"/"!==Dr&&"*"!==Dr&&"^"!==Dr},de.isDigitDot=function(ii){return ii>="0"&&ii<="9"||"."===ii},de.isDigit=function(ii){return ii>="0"&&ii<="9"},de.isHexDigit=function(ii){return ii>="0"&&ii<="9"||ii>="a"&&ii<="f"||ii>="A"&&ii<="F"},m.addConversion({from:"string",to:"Node",convert:de}),de}),Xw=re("resolve",["typed","parse","ConstantNode","FunctionNode","OperatorNode","ParenthesisNode"],p=>{var{typed:m,parse:b,ConstantNode:_,FunctionNode:y,OperatorNode:C,ParenthesisNode:A}=p;function k(R,O){var F=arguments.length>2&&void 0!==arguments[2]?arguments[2]:new Set;if(!O)return R;if(Gn(R)){if(F.has(R.name)){var B=Array.from(F).join(", ");throw new ReferenceError("recursive loop of variable definitions among {".concat(B,"}"))}var H=O.get(R.name);if(uo(H)){var G=new Set(F);return G.add(R.name),k(H,O,G)}return"number"==typeof H?b(String(H)):void 0!==H?new _(H):R}if(ci(R)){var J=R.args.map(function(be){return k(be,O,F)});return new C(R.op,R.fn,J,R.implicit)}if(yt(R))return new A(k(R.content,O,F));if(eo(R)){var te=R.args.map(function(be){return k(be,O,F)});return new y(R.name,te)}return R.map(be=>k(be,O,F))}return m("resolve",{Node:k,"Node, Map | null | undefined":k,"Node, Object":(R,O)=>k(R,wt(O)),"Array | Matrix":m.referToSelf(R=>O=>O.map(F=>R(F))),"Array | Matrix, null | undefined":m.referToSelf(R=>O=>O.map(F=>R(F))),"Array, Object":m.referTo("Array,Map",R=>(O,F)=>R(O,wt(F))),"Matrix, Object":m.referTo("Matrix,Map",R=>(O,F)=>R(O,wt(F))),"Array | Matrix, Map":m.referToSelf(R=>(O,F)=>O.map(B=>R(B,F)))})});function aF(p,m){var b=Object.keys(p);if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(p);m&&(_=_.filter(function(y){return Object.getOwnPropertyDescriptor(p,y).enumerable})),b.push.apply(b,_)}return b}function oM(p){for(var m=1;m<arguments.length;m++){var b=null!=arguments[m]?arguments[m]:{};m%2?aF(Object(b),!0).forEach(function(_){ud(p,_,b[_])}):Object.getOwnPropertyDescriptors?Object.defineProperties(p,Object.getOwnPropertyDescriptors(b)):aF(Object(b)).forEach(function(_){Object.defineProperty(p,_,Object.getOwnPropertyDescriptor(b,_))})}return p}var f2=re("simplifyUtil",["FunctionNode","OperatorNode","SymbolNode"],p=>{var{FunctionNode:m,OperatorNode:b,SymbolNode:_}=p,y=!0,C=!1,A="defaultF",k={add:{trivial:y,total:y,commutative:y,associative:y},unaryPlus:{trivial:y,total:y,commutative:y,associative:y},subtract:{trivial:C,total:y,commutative:C,associative:C},multiply:{trivial:y,total:y,commutative:y,associative:y},divide:{trivial:C,total:y,commutative:C,associative:C},paren:{trivial:y,total:y,commutative:y,associative:C},defaultF:{trivial:C,total:y,commutative:C,associative:C}};function F(de,Te){var De=arguments.length>2&&void 0!==arguments[2]?arguments[2]:k,pe=A;if("string"==typeof de?pe=de:ci(de)?pe=de.fn.toString():eo(de)?pe=de.name:yt(de)&&(pe="paren"),Jt(De,pe)){var Be=De[pe];if(Jt(Be,Te))return Be[Te];if(Jt(k,pe))return k[pe][Te]}if(Jt(De,A)){var We=De[A];return Jt(We,Te)?We[Te]:k[A][Te]}if(Jt(k,pe)){var ke=k[pe];if(Jt(ke,Te))return ke[Te]}return k[A][Te]}function H(de){return F(de,"associative",arguments.length>1&&void 0!==arguments[1]?arguments[1]:k)}function te(de,Te){var De,pe=[],Be=function(ke){for(var ze=0;ze<ke.args.length;ze++){var et=ke.args[ze];ci(et)&&De===et.op?Be(et):pe.push(et)}};return H(de,Te)?(De=de.op,Be(de),pe):de.args}function Le(de){return ci(de)?function(Te){try{return new b(de.op,de.fn,Te,de.implicit)}catch(De){return console.error(De),[]}}:function(Te){return new m(new _(de.name),Te)}}return{createMakeNodeFunction:Le,hasProperty:F,isCommutative:function B(de){return F(de,"commutative",arguments.length>1&&void 0!==arguments[1]?arguments[1]:k)},isAssociative:H,mergeContext:function G(de,Te){var De=oM({},de);for(var pe in Te)De[pe]=Jt(de,pe)?oM(oM({},Te[pe]),de[pe]):Te[pe];return De},flatten:function J(de,Te){if(!de.args||0===de.args.length)return de;de.args=te(de,Te);for(var De=0;De<de.args.length;De++)J(de.args[De],Te)},allChildren:te,unflattenr:function be(de,Te){if(de.args&&0!==de.args.length){for(var De=Le(de),pe=de.args.length,Be=0;Be<pe;Be++)be(de.args[Be],Te);if(pe>2&&H(de,Te)){for(var We=de.args.pop();de.args.length>0;)We=De([de.args.pop(),We]);de.args=We.args}}},unflattenl:function we(de,Te){if(de.args&&0!==de.args.length){for(var De=Le(de),pe=de.args.length,Be=0;Be<pe;Be++)we(de.args[Be],Te);if(pe>2&&H(de,Te)){for(var We=de.args.shift();de.args.length>0;)We=De([We,de.args.shift()]);de.args=We.args}}},defaultContext:k,realContext:{divide:{total:C},log:{total:C}},positiveContext:{subtract:{total:C},abs:{trivial:y},log:{total:y}}}}),sM=re("simplifyConstant",["typed","config","mathWithTransform","matrix","?fraction","?bignumber","AccessorNode","ArrayNode","ConstantNode","FunctionNode","IndexNode","ObjectNode","OperatorNode","SymbolNode"],p=>{var{typed:m,config:b,mathWithTransform:_,matrix:y,fraction:C,bignumber:A,AccessorNode:k,ArrayNode:R,ConstantNode:O,FunctionNode:F,IndexNode:B,ObjectNode:H,OperatorNode:G,SymbolNode:J}=p,{isCommutative:te,isAssociative:be,allChildren:we,createMakeNodeFunction:Le}=f2({FunctionNode:F,OperatorNode:G,SymbolNode:J}),de=m("simplifyConstant",{Node:Kt=>Be(Zt(Kt,{})),"Node, Object":function(lt,st){return Be(Zt(lt,st))}});function Te(Kt){return vn(Kt)?Kt.valueOf():Kt instanceof Array?Kt.map(Te):ut(Kt)?y(Te(Kt.valueOf())):Kt}function De(Kt,lt,st){try{return _[Kt].apply(null,lt)}catch{return lt=lt.map(Te),ke(_[Kt].apply(null,lt),st)}}var pe=m({Fraction:function et(Kt){var lt,st=Kt.s*Kt.n;return lt=st<0?new G("-","unaryMinus",[new O(-st)]):new O(st),1===Kt.d?lt:new G("/","divide",[lt,new O(Kt.d)])},number:function(lt){return lt<0?ze(new O(-lt)):new O(lt)},BigNumber:function(lt){return lt<0?ze(new O(-lt)):new O(lt)},bigint:function(lt){return lt<0n?ze(new O(-lt)):new O(lt)},Complex:function(lt){throw new Error("Cannot convert Complex number to Node")},string:function(lt){return new O(lt)},Matrix:function(lt){return new R(lt.valueOf().map(st=>pe(st)))}});function Be(Kt){return uo(Kt)?Kt:pe(Kt)}function We(Kt,lt){if(lt&&!1!==lt.exactFractions&&isFinite(Kt)&&C){var En=C(Kt),_t=lt&&"number"==typeof lt.fractionsLimit?lt.fractionsLimit:1/0;if(En.valueOf()===Kt&&En.n<_t&&En.d<_t)return En}return Kt}var ke=m({"string, Object":function(lt,st){var En=Fr(lt,b);return"BigNumber"===En?(void 0===A&&dm(),A(lt)):"bigint"===En?BigInt(lt):"Fraction"===En?(void 0===C&&PD(),C(lt)):We(parseFloat(lt),st)},"Fraction, Object":function(lt,st){return lt},"BigNumber, Object":function(lt,st){return lt},"number, Object":function(lt,st){return We(lt,st)},"bigint, Object":function(lt,st){return lt},"Complex, Object":function(lt,st){return 0!==lt.im?lt:We(lt.re,st)},"Matrix, Object":function(lt,st){return y(We(lt.valueOf()))},"Array, Object":function(lt,st){return lt.map(We)}});function ze(Kt){return new G("-","unaryMinus",[Kt])}function $t(Kt,lt,st,En){var _t=lt.shift(),di=lt.reduce((ki,Xn)=>{if(!uo(Xn)){var _n=ki.pop();if(uo(_n))return[_n,Xn];try{return ki.push(De(Kt,[_n,Xn],En)),ki}catch{ki.push(_n)}}ki.push(Be(ki.pop()));var Ni=1===ki.length?ki[0]:st(ki);return[st([Ni,Be(Xn)])]},[_t]);return 1===di.length?di[0]:st([di[0],pe(di[1])])}function Zt(Kt,lt){switch(Kt.type){case"SymbolNode":return Kt;case"ConstantNode":switch(typeof Kt.value){case"number":case"bigint":return ke(Kt.value,lt);case"string":return Kt.value;default:if(!isNaN(Kt.value))return ke(Kt.value,lt)}return Kt;case"FunctionNode":if(_[Kt.name]&&_[Kt.name].rawArgs)return Kt;if(!["add","multiply"].includes(Kt.name)){var En=Kt.args.map(wr=>Zt(wr,lt));if(!En.some(uo))try{return De(Kt.name,En,lt)}catch{}if("size"===Kt.name&&1===En.length&&Nn(En[0])){for(var _t=[],di=En[0];Nn(di);)_t.push(di.items.length),di=di.items[0];return y(_t)}return new F(Kt.name,En.map(Be))}case"OperatorNode":var Xn,_n,ki=Kt.fn.toString(),Ni=Le(Kt);if(ci(Kt)&&Kt.isUnary())_n=uo((Xn=[Zt(Kt.args[0],lt)])[0])?Ni(Xn):De(ki,Xn,lt);else if(be(Kt,lt.context))if(Xn=(Xn=we(Kt,lt.context)).map(wr=>Zt(wr,lt)),te(ki,lt.context)){for(var kr=[],Pi=[],nr=0;nr<Xn.length;nr++)uo(Xn[nr])?Pi.push(Xn[nr]):kr.push(Xn[nr]);kr.length>1?(_n=$t(ki,kr,Ni,lt),Pi.unshift(_n),_n=$t(ki,Pi,Ni,lt)):_n=$t(ki,Xn,Ni,lt)}else _n=$t(ki,Xn,Ni,lt);else _n=$t(ki,Xn=Kt.args.map(wr=>Zt(wr,lt)),Ni,lt);return _n;case"ParenthesisNode":return Zt(Kt.content,lt);case"AccessorNode":return function pt(Kt,lt,st){if(!as(lt))return new k(Be(Kt),Be(lt));if(Nn(Kt)||ut(Kt)){for(var En=Array.from(lt.dimensions);En.length>0;)if(Qi(En[0])&&"string"!=typeof En[0].value){var _t=ke(En.shift().value,st);Nn(Kt)?Kt=Kt.items[_t-1]:(Kt=Kt.valueOf()[_t-1])instanceof Array&&(Kt=y(Kt))}else{if(!(En.length>1&&Qi(En[1])&&"string"!=typeof En[1].value))break;var di=ke(En[1].value,st),ki=[],Xn=Nn(Kt)?Kt.items:Kt.valueOf();for(var _n of Xn)if(Nn(_n))ki.push(_n.items[di-1]);else{if(!ut(Kt))break;ki.push(_n[di-1])}if(ki.length!==Xn.length)break;Kt=Nn(Kt)?new R(ki):y(ki),En.splice(1,1)}return En.length===lt.dimensions.length?new k(Be(Kt),lt):En.length>0?(lt=new B(En),new k(Be(Kt),lt)):Kt}if(mi(Kt)&&1===lt.dimensions.length&&Qi(lt.dimensions[0])){var Ni=lt.dimensions[0].value;return Ni in Kt.properties?Kt.properties[Ni]:new O}return new k(Be(Kt),lt)}(Zt(Kt.object,lt),Zt(Kt.index,lt),lt);case"ArrayNode":var Sr=Kt.items.map(wr=>Zt(wr,lt));return Sr.some(uo)?new R(Sr.map(Be)):y(Sr);case"IndexNode":return new B(Kt.dimensions.map(wr=>de(wr,lt)));case"ObjectNode":var ir={};for(var lr in Kt.properties)ir[lr]=de(Kt.properties[lr],lt);return new H(ir);default:throw new Error("Unimplemented node type in simplifyConstant: ".concat(Kt.type))}}return de}),LI="compile",kI=re(LI,["typed","parse"],p=>{var{typed:m,parse:b}=p;return m(LI,{string:function(y){return b(y).compile()},"Array | Matrix":function(y){return ps(y,function(C){return b(C).compile()})}})}),h2="simplifyCore",PI=re(h2,["typed","parse","equal","isZero","add","subtract","multiply","divide","pow","AccessorNode","ArrayNode","ConstantNode","FunctionNode","IndexNode","ObjectNode","OperatorNode","ParenthesisNode","SymbolNode"],p=>{var{typed:m,equal:_,isZero:y,AccessorNode:F,ArrayNode:B,ConstantNode:H,FunctionNode:G,IndexNode:J,ObjectNode:te,OperatorNode:be,SymbolNode:Le}=p,de=new H(0),Te=new H(1),De=new H(!0),pe=new H(!1);function Be(et){return ci(et)&&["and","not","or"].includes(et.op)}var{hasProperty:We,isCommutative:ke}=f2({FunctionNode:G,OperatorNode:be,SymbolNode:Le});function ze(et){var pt=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},$t=pt?pt.context:void 0;if(We(et,"trivial",$t)){if(eo(et)&&1===et.args.length)return ze(et.args[0],pt);var Zt=!1,Kt=0;if(et.forEach(Pi=>{1==++Kt&&(Zt=ze(Pi,pt))}),1===Kt)return Zt}var lt=et;if(eo(lt)){var st=function SR(p){var m="OperatorNode:"+p;for(var b of B_)if(m in b)return b[m].op;return null}(lt.name);if(!st)return new G(ze(lt.fn),lt.args.map(Pi=>ze(Pi,pt)));if(lt.args.length>2&&We(lt,"associative",$t))for(;lt.args.length>2;){var En=lt.args.pop(),_t=lt.args.pop();lt.args.push(new be(st,lt.name,[En,_t]))}lt=new be(st,lt.name,lt.args)}if(ci(lt)&<.isUnary()){var di=ze(lt.args[0],pt);if("~"===lt.op&&ci(di)&&di.isUnary()&&"~"===di.op||"not"===lt.op&&ci(di)&&di.isUnary()&&"not"===di.op&&Be(di.args[0]))return di.args[0];var ki=!0;if("-"===lt.op&&ci(di)&&(di.isBinary()&&"subtract"===di.fn&&(lt=new be("-","subtract",[di.args[1],di.args[0]]),ki=!1),di.isUnary()&&"-"===di.op))return di.args[0];if(ki)return new be(lt.op,lt.fn,[di])}if(ci(lt)&<.isBinary()){var Xn=ze(lt.args[0],pt),_n=ze(lt.args[1],pt);if("+"===lt.op){if(Qi(Xn)&&y(Xn.value))return _n;if(Qi(_n)&&y(_n.value))return Xn;ci(_n)&&_n.isUnary()&&"-"===_n.op&&(lt=new be("-","subtract",[Xn,_n=_n.args[0]]))}if("-"===lt.op)return ci(_n)&&_n.isUnary()&&"-"===_n.op?ze(new be("+","add",[Xn,_n.args[0]]),pt):Qi(Xn)&&y(Xn.value)?ze(new be("-","unaryMinus",[_n])):Qi(_n)&&y(_n.value)?Xn:new be(lt.op,lt.fn,[Xn,_n]);if("*"===lt.op){if(Qi(Xn)){if(y(Xn.value))return de;if(_(Xn.value,1))return _n}if(Qi(_n)){if(y(_n.value))return de;if(_(_n.value,1))return Xn;if(ke(lt,$t))return new be(lt.op,lt.fn,[_n,Xn],lt.implicit)}return new be(lt.op,lt.fn,[Xn,_n],lt.implicit)}if("/"===lt.op)return Qi(Xn)&&y(Xn.value)?de:Qi(_n)&&_(_n.value,1)?Xn:new be(lt.op,lt.fn,[Xn,_n]);if("^"===lt.op&&Qi(_n)){if(y(_n.value))return Te;if(_(_n.value,1))return Xn}if("and"===lt.op){if(Qi(Xn)){if(!Xn.value)return pe;if(Be(_n))return _n;if(Qi(_n))return _n.value?De:pe}if(Qi(_n)){if(!_n.value)return pe;if(Be(Xn))return Xn}}if("or"===lt.op){if(Qi(Xn)){if(Xn.value)return De;if(Be(_n))return _n}if(Qi(_n)){if(_n.value)return De;if(Be(Xn))return Xn}}return new be(lt.op,lt.fn,[Xn,_n])}if(ci(lt))return new be(lt.op,lt.fn,lt.args.map(Pi=>ze(Pi,pt)));if(Nn(lt))return new B(lt.items.map(Pi=>ze(Pi,pt)));if(gn(lt))return new F(ze(lt.object,pt),ze(lt.index,pt));if(as(lt))return new J(lt.dimensions.map(Pi=>ze(Pi,pt)));if(mi(lt)){var Ni={};for(var kr in lt.properties)Ni[kr]=ze(lt.properties[kr],pt);return new te(Ni)}return lt}return m(h2,{Node:ze,"Node,Object":ze})}),m2="evaluate",BI=re(m2,["typed","parse"],p=>{var{typed:m,parse:b}=p;return m(m2,{string:function(y){var C=Et();return b(y).compile().evaluate(C)},"string, Map | Object":function(y,C){return b(y).compile().evaluate(C)},"Array | Matrix":function(y){var C=Et();return ps(y,function(A){return b(A).compile().evaluate(C)})},"Array | Matrix, Map | Object":function(y,C){return ps(y,function(A){return b(A).compile().evaluate(C)})}})}),aM=re("Help",["evaluate"],p=>{var{evaluate:m}=p;function b(_){if(!(this instanceof b))throw new SyntaxError("Constructor must be called with the new operator");if(!_)throw new Error('Argument "doc" missing');this.doc=_}return b.prototype.type="Help",b.prototype.isHelp=!0,b.prototype.toString=function(){var _=this.doc||{},y="\n";if(_.name&&(y+="Name: "+_.name+"\n\n"),_.category&&(y+="Category: "+_.category+"\n\n"),_.description&&(y+="Description:\n "+_.description+"\n\n"),_.syntax&&(y+="Syntax:\n "+_.syntax.join("\n ")+"\n\n"),_.examples){y+="Examples:\n";for(var C=!1,A=m("config()"),k={config:B=>(C=!0,m("config(newConfig)",{newConfig:B}))},R=0;R<_.examples.length;R++){var O=_.examples[R];y+=" "+O+"\n";var F=void 0;try{F=m(O,k)}catch(B){F=B}void 0!==F&&!An(F)&&(y+=" "+xs(F,{precision:14})+"\n")}y+="\n",C&&m("config(originalConfig)",{originalConfig:A})}return _.mayThrow&&_.mayThrow.length&&(y+="Throws: "+_.mayThrow.join(", ")+"\n\n"),_.seealso&&_.seealso.length&&(y+="See also: "+_.seealso.join(", ")+"\n"),y},b.prototype.toJSON=function(){var _=At(this.doc);return _.mathjs="Help",_},b.fromJSON=function(_){var y={};return Object.keys(_).filter(C=>"mathjs"!==C).forEach(C=>{y[C]=_[C]}),new b(y)},b.prototype.valueOf=b.prototype.toString,b},{isClass:!0}),Zb=re("Parser",["evaluate"],p=>{var{evaluate:m}=p;function b(){if(!(this instanceof b))throw new SyntaxError("Constructor must be called with the new operator");Object.defineProperty(this,"scope",{value:Et(),writable:!1})}return b.prototype.type="Parser",b.prototype.isParser=!0,b.prototype.evaluate=function(_){return m(_,this.scope)},b.prototype.get=function(_){if(this.scope.has(_))return this.scope.get(_)},b.prototype.getAll=function(){return function ve(p){if(p instanceof ce)return p.wrappedObject;var m={};for(var b of p.keys())ie(m,b,p.get(b));return m}(this.scope)},b.prototype.getAllAsMap=function(){return this.scope},b.prototype.set=function(_,y){return this.scope.set(_,y),y},b.prototype.remove=function(_){this.scope.delete(_)},b.prototype.clear=function(){this.scope.clear()},b},{isClass:!0});function v2(p){return Qi(p)||ci(p)&&p.isUnary()&&Qi(p.args[0])}function lM(p){return!!(Qi(p)||(eo(p)||ci(p))&&p.args.every(lM)||yt(p)&&lM(p.content))}var VI=re("simplify",["config","typed","parse","add","subtract","multiply","divide","pow","isZero","equal","resolve","simplifyConstant","simplifyCore","?fraction","?bignumber","mathWithTransform","matrix","AccessorNode","ArrayNode","ConstantNode","FunctionNode","IndexNode","ObjectNode","OperatorNode","ParenthesisNode","SymbolNode"],p=>{var{typed:b,parse:_,equal:F,resolve:B,simplifyConstant:H,simplifyCore:G,AccessorNode:Le,ArrayNode:de,ConstantNode:Te,FunctionNode:De,IndexNode:pe,ObjectNode:Be,OperatorNode:We,ParenthesisNode:ke,SymbolNode:ze}=p,{hasProperty:et,isCommutative:pt,isAssociative:$t,mergeContext:Zt,flatten:Kt,unflattenr:lt,unflattenl:st,createMakeNodeFunction:En,defaultContext:_t,realContext:di,positiveContext:ki}=f2({FunctionNode:De,OperatorNode:We,SymbolNode:ze});b.addConversion({from:"Object",to:"Map",convert:wt});var Xn=b("simplify",{Node:ir,"Node, Map":(Fn,ti)=>ir(Fn,!1,ti),"Node, Map, Object":(Fn,ti,Mi)=>ir(Fn,!1,ti,Mi),"Node, Array":ir,"Node, Array, Map":ir,"Node, Array, Map, Object":ir});function _n(Fn){return Fn.transform(function(ti,Mi,Pr){return yt(ti)?_n(ti.content):ti})}b.removeConversion({from:"Object",to:"Map",convert:wt}),Xn.defaultContext=_t,Xn.realContext=di,Xn.positiveContext=ki;var Ni={true:!0,false:!0,e:!0,i:!0,Infinity:!0,LN2:!0,LN10:!0,LOG2E:!0,LOG10E:!0,NaN:!0,phi:!0,pi:!0,SQRT1_2:!0,SQRT2:!0,tau:!0};function kr(Fn,ti){var Mi={};if(Fn.s){var Pr=Fn.s.split("->");if(2!==Pr.length)throw SyntaxError("Could not parse rule: "+Fn.s);Mi.l=Pr[0],Mi.r=Pr[1]}else Mi.l=Fn.l,Mi.r=Fn.r;for(var Br of(Mi.l=_n(_(Mi.l)),Mi.r=_n(_(Mi.r)),["imposeContext","repeat","assuming"]))Br in Fn&&(Mi[Br]=Fn[Br]);if(Fn.evaluate&&(Mi.evaluate=_(Fn.evaluate)),$t(Mi.l,ti)){var Zr,Go=!pt(Mi.l,ti);Go&&(Zr=Sr());var rl=En(Mi.l),Nl=Sr();Mi.expanded={},Mi.expanded.l=rl([Mi.l,Nl]),Kt(Mi.expanded.l,ti),lt(Mi.expanded.l,ti),Mi.expanded.r=rl([Mi.r,Nl]),Go&&(Mi.expandedNC1={},Mi.expandedNC1.l=rl([Zr,Mi.l]),Mi.expandedNC1.r=rl([Zr,Mi.r]),Mi.expandedNC2={},Mi.expandedNC2.l=rl([Zr,Mi.expanded.l]),Mi.expandedNC2.r=rl([Zr,Mi.expanded.r]))}return Mi}Xn.rules=[G,{l:"log(e)",r:"1"},{s:"n-n1 -> n+-n1",assuming:{subtract:{total:!0}}},{s:"n-n -> 0",assuming:{subtract:{total:!1}}},{s:"-(cl*v) -> v * (-cl)",assuming:{multiply:{commutative:!0},subtract:{total:!0}}},{s:"-(cl*v) -> (-cl) * v",assuming:{multiply:{commutative:!1},subtract:{total:!0}}},{s:"-(v*cl) -> v * (-cl)",assuming:{multiply:{commutative:!1},subtract:{total:!0}}},{l:"-(n1/n2)",r:"-n1/n2"},{l:"-v",r:"v * (-1)"},{l:"(n1 + n2)*(-1)",r:"n1*(-1) + n2*(-1)",repeat:!0},{l:"n/n1^n2",r:"n*n1^-n2"},{l:"n/n1",r:"n*n1^-1"},{s:"(n1*n2)^n3 -> n1^n3 * n2^n3",assuming:{multiply:{commutative:!0}}},{s:"(n1*n2)^(-1) -> n2^(-1) * n1^(-1)",assuming:{multiply:{commutative:!1}}},{s:"(n ^ n1) ^ n2 -> n ^ (n1 * n2)",assuming:{divide:{total:!0}}},{l:" vd * ( vd * n1 + n2)",r:"vd^2 * n1 + vd * n2"},{s:" vd * (vd^n4 * n1 + n2) -> vd^(1+n4) * n1 + vd * n2",assuming:{divide:{total:!0}}},{s:"vd^n3 * ( vd * n1 + n2) -> vd^(n3+1) * n1 + vd^n3 * n2",assuming:{divide:{total:!0}}},{s:"vd^n3 * (vd^n4 * n1 + n2) -> vd^(n3+n4) * n1 + vd^n3 * n2",assuming:{divide:{total:!0}}},{l:"n*n",r:"n^2"},{s:"n * n^n1 -> n^(n1+1)",assuming:{divide:{total:!0}}},{s:"n^n1 * n^n2 -> n^(n1+n2)",assuming:{divide:{total:!0}}},H,{s:"n+n -> 2*n",assuming:{add:{total:!0}}},{l:"n+-n",r:"0"},{l:"vd*n + vd",r:"vd*(n+1)"},{l:"n3*n1 + n3*n2",r:"n3*(n1+n2)"},{l:"n3^(-n4)*n1 + n3 * n2",r:"n3^(-n4)*(n1 + n3^(n4+1) *n2)"},{l:"n3^(-n4)*n1 + n3^n5 * n2",r:"n3^(-n4)*(n1 + n3^(n4+n5)*n2)"},{s:"n*vd + vd -> (n+1)*vd",assuming:{multiply:{commutative:!1}}},{s:"vd + n*vd -> (1+n)*vd",assuming:{multiply:{commutative:!1}}},{s:"n1*n3 + n2*n3 -> (n1+n2)*n3",assuming:{multiply:{commutative:!1}}},{s:"n^n1 * n -> n^(n1+1)",assuming:{divide:{total:!0},multiply:{commutative:!1}}},{s:"n1*n3^(-n4) + n2 * n3 -> (n1 + n2*n3^(n4 + 1))*n3^(-n4)",assuming:{multiply:{commutative:!1}}},{s:"n1*n3^(-n4) + n2 * n3^n5 -> (n1 + n2*n3^(n4 + n5))*n3^(-n4)",assuming:{multiply:{commutative:!1}}},{l:"n*cd + cd",r:"(n+1)*cd"},{s:"cd*n + cd -> cd*(n+1)",assuming:{multiply:{commutative:!1}}},{s:"cd + cd*n -> cd*(1+n)",assuming:{multiply:{commutative:!1}}},H,{s:"(-n)*n1 -> -(n*n1)",assuming:{subtract:{total:!0}}},{s:"n1*(-n) -> -(n1*n)",assuming:{subtract:{total:!0},multiply:{commutative:!1}}},{s:"ce+ve -> ve+ce",assuming:{add:{commutative:!0}},imposeContext:{add:{commutative:!1}}},{s:"vd*cd -> cd*vd",assuming:{multiply:{commutative:!0}},imposeContext:{multiply:{commutative:!1}}},{l:"n+-n1",r:"n-n1"},{l:"n+-(n1)",r:"n-(n1)"},{s:"n*(n1^-1) -> n/n1",assuming:{multiply:{commutative:!0}}},{s:"n*n1^-n2 -> n/n1^n2",assuming:{multiply:{commutative:!0}}},{s:"n^-1 -> 1/n",assuming:{multiply:{commutative:!0}}},{l:"n^1",r:"n"},{s:"n*(n1/n2) -> (n*n1)/n2",assuming:{multiply:{associative:!0}}},{s:"n-(n1+n2) -> n-n1-n2",assuming:{addition:{associative:!0,commutative:!0}}},{l:"1*n",r:"n",imposeContext:{multiply:{commutative:!0}}},{s:"n1/(n2/n3) -> (n1*n3)/n2",assuming:{multiply:{associative:!0}}},{l:"n1/(-n2)",r:"-n1/n2"}];var nr=0;function Sr(){return new ze("_p"+nr++)}function ir(Fn,ti){var Mi=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Et(),Pr=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},Br=Pr.consoleDebug;ti=function Pi(Fn,ti){for(var Mi=[],Pr=0;Pr<Fn.length;Pr++){var Br=Fn[Pr],Go=void 0,Zr=typeof Br;switch(Zr){case"string":Br={s:Br};case"object":Go=kr(Br,ti);break;case"function":Go=Br;break;default:throw TypeError("Unsupported type of rule: "+Zr)}Mi.push(Go)}return Mi}(ti||Xn.rules,Pr.context);for(var Go=B(Fn,Mi),Zr={},rl=(Go=_n(Go)).toString({parenthesis:"all"});!Zr[rl];){Zr[rl]=!0,nr=0;var Nl=rl;Br&&console.log("Working on: ",rl);for(var Ru=0;Ru<ti.length;Ru++){var Kd="";if("function"==typeof ti[Ru]?(Go=ti[Ru](Go,Pr),Br&&(Kd=ti[Ru].name)):(Kt(Go,Pr.context),Go=wr(Go,ti[Ru],Pr.context),Br&&(Kd="".concat(ti[Ru].l.toString()," -> ").concat(ti[Ru].r.toString()))),Br){var Mf=Go.toString({parenthesis:"all"});Mf!==Nl&&(console.log("Applying",Kd,"produced",Mf),Nl=Mf)}st(Go,Pr.context)}rl=Go.toString({parenthesis:"all"})}return Go}function lr(Fn,ti,Mi){var Pr=Fn;if(Fn)for(var Br=0;Br<Fn.length;++Br){var Go=wr(Fn[Br],ti,Mi);Go!==Fn[Br]&&(Pr===Fn&&(Pr=Fn.slice()),Pr[Br]=Go)}return Pr}function wr(Fn,ti,Mi){if(ti.assuming)for(var Pr in ti.assuming)for(var Br in ti.assuming[Pr])if(et(Pr,Br,Mi)!==ti.assuming[Pr][Br])return Fn;var Go=Zt(ti.imposeContext,Mi),Zr=Fn;if(Zr instanceof We||Zr instanceof De){var rl=lr(Zr.args,ti,Mi);rl!==Zr.args&&((Zr=Zr.clone()).args=rl)}else if(Zr instanceof ke){if(Zr.content){var Nl=wr(Zr.content,ti,Mi);Nl!==Zr.content&&(Zr=new ke(Nl))}}else if(Zr instanceof de){var Ru=lr(Zr.items,ti,Mi);Ru!==Zr.items&&(Zr=new de(Ru))}else if(Zr instanceof Le){var Kd=Zr.object;Zr.object&&(Kd=wr(Zr.object,ti,Mi));var Mf=Zr.index;Zr.index&&(Mf=wr(Zr.index,ti,Mi)),(Kd!==Zr.object||Mf!==Zr.index)&&(Zr=new Le(Kd,Mf))}else if(Zr instanceof pe){var b0=lr(Zr.dimensions,ti,Mi);b0!==Zr.dimensions&&(Zr=new pe(b0))}else if(Zr instanceof Be){var j_=!1,cO={};for(var CM in Zr.properties)cO[CM]=wr(Zr.properties[CM],ti,Mi),cO[CM]!==Zr.properties[CM]&&(j_=!0);j_&&(Zr=new Be(cO))}var mE=ti.r,du=$n(ti.l,Zr,Go)[0];if(!du&&ti.expanded&&(mE=ti.expanded.r,du=$n(ti.expanded.l,Zr,Go)[0]),!du&&ti.expandedNC1&&(mE=ti.expandedNC1.r,(du=$n(ti.expandedNC1.l,Zr,Go)[0])||(mE=ti.expandedNC2.r,du=$n(ti.expandedNC2.l,Zr,Go)[0])),du){var uO=Zr.implicit;Zr=mE.clone(),uO&&"implicit"in mE&&(Zr.implicit=!0),Zr=Zr.transform(function(ot){return ot.isSymbolNode&&Jt(du.placeholders,ot.name)?du.placeholders[ot.name].clone():ot})}return ti.repeat&&Zr!==Fn&&(Zr=wr(Zr,ti,Mi)),Zr}function Io(Fn,ti){var Mi={placeholders:{}};if(!Fn.placeholders&&!ti.placeholders)return Mi;if(!Fn.placeholders)return ti;if(!ti.placeholders)return Fn;for(var Pr in Fn.placeholders)if(Jt(Fn.placeholders,Pr)&&(Mi.placeholders[Pr]=Fn.placeholders[Pr],Jt(ti.placeholders,Pr)&&!Zi(Fn.placeholders[Pr],ti.placeholders[Pr])))return null;for(var Br in ti.placeholders)Jt(ti.placeholders,Br)&&(Mi.placeholders[Br]=ti.placeholders[Br]);return Mi}function ms(Fn,ti){var Mi=[];if(0===Fn.length||0===ti.length)return Mi;for(var Pr,Br=0;Br<Fn.length;Br++)for(var Go=0;Go<ti.length;Go++)(Pr=Io(Fn[Br],ti[Go]))&&Mi.push(Pr);return Mi}function $n(Fn,ti,Mi,Pr){var Br=[{placeholders:{}}];if(Fn instanceof We&&ti instanceof We||Fn instanceof De&&ti instanceof De){if(Fn instanceof We){if(Fn.op!==ti.op||Fn.fn!==ti.fn)return[]}else if(Fn instanceof De&&Fn.name!==ti.name)return[];if(!(1===ti.args.length&&1===Fn.args.length||!$t(ti,Mi)&&ti.args.length===Fn.args.length||Pr)){if(ti.args.length>=2&&2===Fn.args.length){for(var Kd=function $r(Fn,ti){var Pr,Br,Mi=[],Go=En(Fn);if(pt(Fn,ti))for(var Zr=0;Zr<Fn.args.length;Zr++)(Br=Fn.args.slice(0)).splice(Zr,1),Pr=1===Br.length?Br[0]:Go(Br),Mi.push(Go([Fn.args[Zr],Pr]));else for(var rl=1;rl<Fn.args.length;rl++){var Nl=Fn.args[0];rl>1&&(Nl=Go(Fn.args.slice(0,rl))),Pr=1===(Br=Fn.args.slice(rl)).length?Br[0]:Go(Br),Mi.push(Go([Nl,Pr]))}return Mi}(ti,Mi),Mf=[],b0=0;b0<Kd.length;b0++){var j_=$n(Fn,Kd[b0],Mi,!0);Mf=Mf.concat(j_)}return Mf}if(Fn.args.length>2)throw Error("Unexpected non-binary associative function: "+Fn.toString());return[]}for(var Go=[],Zr=0;Zr<Fn.args.length;Zr++){var rl=$n(Fn.args[Zr],ti.args[Zr],Mi);if(0===rl.length)break;Go.push(rl)}if(Go.length!==Fn.args.length){if(!pt(ti,Mi)||1===Fn.args.length)return[];if(Fn.args.length>2)throw new Error("permuting >2 commutative non-associative rule arguments not yet implemented");var Nl=$n(Fn.args[0],ti.args[1],Mi);if(0===Nl.length)return[];var Ru=$n(Fn.args[1],ti.args[0],Mi);if(0===Ru.length)return[];Go=[Nl,Ru]}Br=function xn(Fn){if(0===Fn.length)return Fn;for(var ti=Fn.reduce(ms),Mi=[],Pr={},Br=0;Br<ti.length;Br++){var Go=JSON.stringify(ti[Br]);Pr[Go]||(Pr[Go]=!0,Mi.push(ti[Br]))}return Mi}(Go)}else if(Fn instanceof ze){if(0===Fn.name.length)throw new Error("Symbol in rule has 0 length...!?");if(Ni[Fn.name]){if(Fn.name!==ti.name)return[]}else switch(Fn.name[1]>="a"&&Fn.name[1]<="z"?Fn.name.substring(0,2):Fn.name[0]){case"n":case"_p":Br[0].placeholders[Fn.name]=ti;break;case"c":case"cl":if(!Qi(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"v":if(Qi(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"vl":if(!Gn(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"cd":if(!v2(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"vd":if(v2(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"ce":if(!lM(ti))return[];Br[0].placeholders[Fn.name]=ti;break;case"ve":if(lM(ti))return[];Br[0].placeholders[Fn.name]=ti;break;default:throw new Error("Invalid symbol in rule: "+Fn.name)}}else{if(!(Fn instanceof Te))return[];if(!F(Fn.value,ti.value))return[]}return Br}function Zi(Fn,ti){if(Fn instanceof Te&&ti instanceof Te){if(!F(Fn.value,ti.value))return!1}else if(Fn instanceof ze&&ti instanceof ze){if(Fn.name!==ti.name)return!1}else{if(!(Fn instanceof We&&ti instanceof We||Fn instanceof De&&ti instanceof De))return!1;if(Fn instanceof We){if(Fn.op!==ti.op||Fn.fn!==ti.fn)return!1}else if(Fn instanceof De&&Fn.name!==ti.name)return!1;if(Fn.args.length!==ti.args.length)return!1;for(var Mi=0;Mi<Fn.args.length;Mi++)if(!Zi(Fn.args[Mi],ti.args[Mi]))return!1}return!0}return Xn}),jI="symbolicEqual",fF=re(jI,["parse","simplify","typed","OperatorNode"],p=>{var{simplify:b,typed:_,OperatorNode:y}=p;function C(A,k){var R=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},O=new y("-","subtract",[A,k]),F=b(O,{},R);return Qi(F)&&!F.value}return _(jI,{"Node, Node":C,"Node, Node, Object":C})}),Lk="leafCount",$I=re(Lk,["parse","typed"],p=>{var{typed:b}=p;function _(y){var C=0;return y.forEach(A=>{C+=_(A)}),C||1}return b(Lk,{Node:function(C){return _(C)}})}),Zw=re("parser",["typed","Parser"],p=>{var{typed:m,Parser:b}=p;return m("parser",{"":function(){return new b}})}),cM="rationalize",uM=re(cM,["config","typed","equal","isZero","add","subtract","multiply","divide","pow","parse","simplifyConstant","simplifyCore","simplify","?bignumber","?fraction","mathWithTransform","matrix","AccessorNode","ArrayNode","ConstantNode","FunctionNode","IndexNode","ObjectNode","OperatorNode","SymbolNode","ParenthesisNode"],p=>{var{typed:b,simplifyConstant:B,simplifyCore:H,simplify:G,ConstantNode:Te,OperatorNode:We,SymbolNode:ke}=p;function et(lt){var st=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},En=arguments.length>2&&void 0!==arguments[2]&&arguments[2],_t=function $t(){var lt=[H,{l:"n+n",r:"2*n"},{l:"n+-n",r:"0"},B,{l:"n*(n1^-1)",r:"n/n1"},{l:"n*n1^-n2",r:"n/n1^n2"},{l:"n1^-1",r:"1/n1"},{l:"n*(n1/n2)",r:"(n*n1)/n2"},{l:"1*n",r:"n"}],st=[{l:"(-n1)/(-n2)",r:"n1/n2"},{l:"(-n1)*(-n2)",r:"n1*n2"},{l:"n1--n2",r:"n1+n2"},{l:"n1-n2",r:"n1+(-n2)"},{l:"(n1+n2)*n3",r:"(n1*n3 + n2*n3)"},{l:"n1*(n2+n3)",r:"(n1*n2+n1*n3)"},{l:"c1*n + c2*n",r:"(c1+c2)*n"},{l:"c1*n + n",r:"(c1+1)*n"},{l:"c1*n - c2*n",r:"(c1-c2)*n"},{l:"c1*n - n",r:"(c1-1)*n"},{l:"v/c",r:"(1/c)*v"},{l:"v/-c",r:"-(1/c)*v"},{l:"-v*-c",r:"c*v"},{l:"-v*c",r:"-c*v"},{l:"v*-c",r:"-c*v"},{l:"v*c",r:"c*v"},{l:"-(-n1*n2)",r:"(n1*n2)"},{l:"-(n1*n2)",r:"(-n1*n2)"},{l:"-(-n1+n2)",r:"(n1-n2)"},{l:"-(n1+n2)",r:"(-n1-n2)"},{l:"(n1^n2)^n3",r:"(n1^(n2*n3))"},{l:"-(-n1/n2)",r:"(n1/n2)"},{l:"-(n1/n2)",r:"(-n1/n2)"}],_t=[{l:"(n1/(n2/n3))",r:"((n1*n3)/n2)"},{l:"(n1/n2/n3)",r:"(n1/(n2*n3))"}],di={};return di.firstRules=lt.concat(st,_t),di.distrDivRules=[{l:"(n1/n2 + n3/n4)",r:"((n1*n4 + n3*n2)/(n2*n4))"},{l:"(n1/n2 + n3)",r:"((n1 + n3*n2)/n2)"},{l:"(n1 + n2/n3)",r:"((n1*n3 + n2)/n3)"}],di.sucDivRules=_t,di.firstRulesAgain=lt.concat(st),di.finalRules=[H,{l:"n*-n",r:"-n^2"},{l:"n*n",r:"n^2"},B,{l:"n*-n^n1",r:"-n^(n1+1)"},{l:"n*n^n1",r:"n^(n1+1)"},{l:"n^n1*-n^n2",r:"-n^(n1+n2)"},{l:"n^n1*n^n2",r:"n^(n1+n2)"},{l:"n^n1*-n",r:"-n^(n1+1)"},{l:"n^n1*n",r:"n^(n1+1)"},{l:"n^n1/-n",r:"-n^(n1-1)"},{l:"n^n1/n",r:"n^(n1-1)"},{l:"n/-n^n1",r:"-n^(1-n1)"},{l:"n/n^n1",r:"n^(1-n1)"},{l:"n^n1/-n^n2",r:"n^(n1-n2)"},{l:"n^n1/n^n2",r:"n^(n1-n2)"},{l:"n1+(-n2*n3)",r:"n1-n2*n3"},{l:"v*(-c)",r:"-c*v"},{l:"n1+-n2",r:"n1-n2"},{l:"v*c",r:"c*v"},{l:"(n1^n2)^n3",r:"(n1^(n2*n3))"}],di}(),di=function pt(lt,st,En,_t){var di=[],ki=G(lt,_t,st,{exactFractions:!1}),Xn="+-*"+((En=!!En)?"/":"");!function Ni(kr){var Pi=kr.type;if("FunctionNode"===Pi)throw new Error("There is an unsolved function call");if("OperatorNode"===Pi)if("^"===kr.op){if("ConstantNode"!==kr.args[1].type||!ai(parseFloat(kr.args[1].value)))throw new Error("There is a non-integer exponent");Ni(kr.args[0])}else{if(!Xn.includes(kr.op))throw new Error("Operator "+kr.op+" invalid in polynomial expression");for(var nr=0;nr<kr.args.length;nr++)Ni(kr.args[nr])}else if("SymbolNode"===Pi){var Sr=kr.name;-1===di.indexOf(Sr)&&di.push(Sr)}else if("ParenthesisNode"===Pi)Ni(kr.content);else if("ConstantNode"!==Pi)throw new Error("type "+Pi+" is not allowed in polynomial expression")}(ki);var _n={};return _n.expression=ki,_n.variables=di,_n}(lt,st,!0,_t.firstRules),ki=di.variables.length,Xn={exactFractions:!1},_n={exactFractions:!0};if(lt=di.expression,ki>=1){lt=Zt(lt);var Ni,kr,Sr,Pi=!0,nr=!1;for(lt=G(lt,_t.firstRules,{},Xn);kr=Pi?_t.distrDivRules:_t.sucDivRules,Pi=!Pi,(Sr=(lt=G(lt,kr,{},_n)).toString())!==Ni;)nr=!0,Ni=Sr;nr&&(lt=G(lt,_t.firstRulesAgain,{},Xn)),lt=G(lt,_t.finalRules,{},Xn)}var ir=[],lr={};return"OperatorNode"===lt.type&<.isBinary()&&"/"===lt.op?(1===ki&&(lt.args[0]=Kt(lt.args[0],ir),lt.args[1]=Kt(lt.args[1])),En&&(lr.numerator=lt.args[0],lr.denominator=lt.args[1])):(1===ki&&(lt=Kt(lt,ir)),En&&(lr.numerator=lt,lr.denominator=null)),En?(lr.coefficients=ir,lr.variables=di.variables,lr.expression=lt,lr):lt}return b(cM,{Node:et,"Node, boolean":(lt,st)=>et(lt,{},st),"Node, Object":et,"Node, Object, boolean":et});function Zt(lt,st,En){var _t=lt.type,di=arguments.length>1;if("OperatorNode"===_t&<.isBinary()){var Xn,ki=!1;if("^"===lt.op&&("ParenthesisNode"===lt.args[0].type||"OperatorNode"===lt.args[0].type)&&"ConstantNode"===lt.args[1].type&&(ki=(Xn=parseFloat(lt.args[1].value))>=2&&ai(Xn)),ki){if(Xn>2){var _n=lt.args[0],Ni=new We("^","pow",[lt.args[0].cloneDeep(),new Te(Xn-1)]);lt=new We("*","multiply",[_n,Ni])}else lt=new We("*","multiply",[lt.args[0],lt.args[0].cloneDeep()]);di&&("content"===En?st.content=lt:st.args[En]=lt)}}if("ParenthesisNode"===_t)Zt(lt.content,lt,"content");else if("ConstantNode"!==_t&&"SymbolNode"!==_t)for(var kr=0;kr<lt.args.length;kr++)Zt(lt.args[kr],lt,kr);if(!di)return lt}function Kt(lt,st){void 0===st&&(st=[]),st[0]=0;var _t=0,di="";!function Sr(ir,lr,wr){var $r=ir.type;if("FunctionNode"===$r)throw new Error("There is an unsolved function call");if("OperatorNode"===$r){if(!"+-*^".includes(ir.op))throw new Error("Operator "+ir.op+" invalid");if(null!==lr){if(("unaryMinus"===ir.fn||"pow"===ir.fn)&&"add"!==lr.fn&&"subtract"!==lr.fn&&"multiply"!==lr.fn)throw new Error("Invalid "+ir.op+" placing");if(("subtract"===ir.fn||"add"===ir.fn||"multiply"===ir.fn)&&"add"!==lr.fn&&"subtract"!==lr.fn)throw new Error("Invalid "+ir.op+" placing");if(("subtract"===ir.fn||"add"===ir.fn||"unaryMinus"===ir.fn)&&0!==wr.noFil)throw new Error("Invalid "+ir.op+" placing")}("^"===ir.op||"*"===ir.op)&&(wr.fire=ir.op);for(var Io=0;Io<ir.args.length;Io++)"unaryMinus"===ir.fn&&(wr.oper="-"),("+"===ir.op||"subtract"===ir.fn)&&(wr.fire="",wr.cte=1,wr.oper=0===Io?"+":ir.op),wr.noFil=Io,Sr(ir.args[Io],ir,wr)}else if("SymbolNode"===$r){if(ir.name!==di&&""!==di)throw new Error("There is more than one variable");if(di=ir.name,null===lr)return void(st[1]=1);if("^"===lr.op&&0!==wr.noFil)throw new Error("In power the variable should be the first parameter");if("*"===lr.op&&1!==wr.noFil)throw new Error("In multiply the variable should be the second parameter");(""===wr.fire||"*"===wr.fire)&&(_t<1&&(st[1]=0),st[1]+=wr.cte*("+"===wr.oper?1:-1),_t=Math.max(1,_t))}else{if("ConstantNode"!==$r)throw new Error("Type "+$r+" is not allowed");var ms=parseFloat(ir.value);if(null===lr)return void(st[0]=ms);if("^"===lr.op){if(1!==wr.noFil)throw new Error("Constant cannot be powered");if(!ai(ms)||ms<=0)throw new Error("Non-integer exponent is not allowed");for(var xn=_t+1;xn<ms;xn++)st[xn]=0;return ms>_t&&(st[ms]=0),st[ms]+=wr.cte*("+"===wr.oper?1:-1),void(_t=Math.max(ms,_t))}wr.cte=ms,""===wr.fire&&(st[0]+=wr.cte*("+"===wr.oper?1:-1))}}(lt,null,{cte:1,oper:"+",fire:""});for(var Xn,ki=!0,_n=_t=st.length-1;_n>=0;_n--)if(0!==st[_n]){var Ni=new Te(ki?st[_n]:Math.abs(st[_n])),kr=st[_n]<0?"-":"+";if(_n>0){var Pi=new ke(di);if(_n>1){var nr=new Te(_n);Pi=new We("^","pow",[Pi,nr])}Ni=-1===st[_n]&&ki?new We("-","unaryMinus",[Pi]):1===Math.abs(st[_n])?Pi:new We("*","multiply",[Ni,Pi])}Xn=ki?Ni:"+"===kr?new We("+","add",[Xn,Ni]):new We("-","subtract",[Xn,Ni]),ki=!1}return ki?new Te(0):Xn}}),pF="derivative",YC=re(pF,["typed","config","parse","simplify","equal","isZero","numeric","ConstantNode","FunctionNode","OperatorNode","ParenthesisNode","SymbolNode"],p=>{var{typed:m,config:b,parse:_,simplify:y,equal:C,isZero:A,numeric:k,ConstantNode:R,FunctionNode:O,OperatorNode:F,ParenthesisNode:B,SymbolNode:H}=p;function G(Te,De){var pe=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{simplify:!0},Be={};we(Be,Te,De.name);var We=Le(Te,Be);return pe.simplify?y(We):We}function J(Te){var De=_(Te);if(!De.isSymbolNode)throw new TypeError("Invalid variable. "+"Cannot parse ".concat(JSON.stringify(Te)," into a variable in function derivative"));return De}var te=m(pF,{"Node, SymbolNode":G,"Node, SymbolNode, Object":G,"Node, string":(Te,De)=>G(Te,J(De)),"Node, string, Object":(Te,De,pe)=>G(Te,J(De),pe)});te._simplify=!0,te.toTex=function(Te){return be.apply(null,Te.args)};var be=m("_derivTex",{"Node, SymbolNode":function(De,pe){return Qi(De)&&"string"===pi(De.value)?be(_(De.value).toString(),pe.toString(),1):be(De.toTex(),pe.toString(),1)},"Node, ConstantNode":function(De,pe){if("string"===pi(pe.value))return be(De,_(pe.value));throw new Error("The second parameter to 'derivative' is a non-string constant")},"Node, SymbolNode, ConstantNode":function(De,pe,Be){return be(De.toString(),pe.name,Be.value)},"string, string, number":function(De,pe,Be){return(1===Be?"{d\\over d"+pe+"}":"{d^{"+Be+"}\\over d"+pe+"^{"+Be+"}}")+"\\left[".concat(De,"\\right]")}}),we=m("constTag",{"Object, ConstantNode, string":function(De,pe){return De[pe]=!0,!0},"Object, SymbolNode, string":function(De,pe,Be){return pe.name!==Be&&(De[pe]=!0,!0)},"Object, ParenthesisNode, string":function(De,pe,Be){return we(De,pe.content,Be)},"Object, FunctionAssignmentNode, string":function(De,pe,Be){return pe.params.includes(Be)?we(De,pe.expr,Be):(De[pe]=!0,!0)},"Object, FunctionNode | OperatorNode, string":function(De,pe,Be){if(pe.args.length>0){for(var We=we(De,pe.args[0],Be),ke=1;ke<pe.args.length;++ke)We=we(De,pe.args[ke],Be)&&We;if(We)return De[pe]=!0,!0}return!1}}),Le=m("_derivative",{"ConstantNode, Object":function(De){return de(0)},"SymbolNode, Object":function(De,pe){return de(void 0!==pe[De]?0:1)},"ParenthesisNode, Object":function(De,pe){return new B(Le(De.content,pe))},"FunctionAssignmentNode, Object":function(De,pe){return void 0!==pe[De]?de(0):Le(De.expr,pe)},"FunctionNode, Object":function(De,pe){if(void 0!==pe[De])return de(0);var We,et,pt,$t,Be=De.args[0],ke=!1,ze=!1;switch(De.name){case"cbrt":ke=!0,et=new F("*","multiply",[de(3),new F("^","pow",[Be,new F("/","divide",[de(2),de(3)])])]);break;case"sqrt":case"nthRoot":if(1===De.args.length)ke=!0,et=new F("*","multiply",[de(2),new O("sqrt",[Be])]);else if(2===De.args.length)return pe[We=new F("/","divide",[de(1),De.args[1]])]=pe[De.args[1]],Le(new F("^","pow",[Be,We]),pe);break;case"log10":We=de(10);case"log":if(We||1!==De.args.length){if(1===De.args.length&&We||2===De.args.length&&void 0!==pe[De.args[1]])et=new F("*","multiply",[Be.clone(),new O("log",[We||De.args[1]])]),ke=!0;else if(2===De.args.length)return Le(new F("/","divide",[new O("log",[Be]),new O("log",[De.args[1]])]),pe)}else et=Be.clone(),ke=!0;break;case"pow":if(2===De.args.length)return pe[We]=pe[De.args[1]],Le(new F("^","pow",[Be,De.args[1]]),pe);break;case"exp":et=new O("exp",[Be.clone()]);break;case"sin":et=new O("cos",[Be.clone()]);break;case"cos":et=new F("-","unaryMinus",[new O("sin",[Be.clone()])]);break;case"tan":et=new F("^","pow",[new O("sec",[Be.clone()]),de(2)]);break;case"sec":et=new F("*","multiply",[De,new O("tan",[Be.clone()])]);break;case"csc":ze=!0,et=new F("*","multiply",[De,new O("cot",[Be.clone()])]);break;case"cot":ze=!0,et=new F("^","pow",[new O("csc",[Be.clone()]),de(2)]);break;case"asin":ke=!0,et=new O("sqrt",[new F("-","subtract",[de(1),new F("^","pow",[Be.clone(),de(2)])])]);break;case"acos":ke=!0,ze=!0,et=new O("sqrt",[new F("-","subtract",[de(1),new F("^","pow",[Be.clone(),de(2)])])]);break;case"atan":ke=!0,et=new F("+","add",[new F("^","pow",[Be.clone(),de(2)]),de(1)]);break;case"asec":ke=!0,et=new F("*","multiply",[new O("abs",[Be.clone()]),new O("sqrt",[new F("-","subtract",[new F("^","pow",[Be.clone(),de(2)]),de(1)])])]);break;case"acsc":ke=!0,ze=!0,et=new F("*","multiply",[new O("abs",[Be.clone()]),new O("sqrt",[new F("-","subtract",[new F("^","pow",[Be.clone(),de(2)]),de(1)])])]);break;case"acot":ke=!0,ze=!0,et=new F("+","add",[new F("^","pow",[Be.clone(),de(2)]),de(1)]);break;case"sinh":et=new O("cosh",[Be.clone()]);break;case"cosh":et=new O("sinh",[Be.clone()]);break;case"tanh":et=new F("^","pow",[new O("sech",[Be.clone()]),de(2)]);break;case"sech":ze=!0,et=new F("*","multiply",[De,new O("tanh",[Be.clone()])]);break;case"csch":ze=!0,et=new F("*","multiply",[De,new O("coth",[Be.clone()])]);break;case"coth":ze=!0,et=new F("^","pow",[new O("csch",[Be.clone()]),de(2)]);break;case"asinh":ke=!0,et=new O("sqrt",[new F("+","add",[new F("^","pow",[Be.clone(),de(2)]),de(1)])]);break;case"acosh":ke=!0,et=new O("sqrt",[new F("-","subtract",[new F("^","pow",[Be.clone(),de(2)]),de(1)])]);break;case"atanh":ke=!0,et=new F("-","subtract",[de(1),new F("^","pow",[Be.clone(),de(2)])]);break;case"asech":ke=!0,ze=!0,et=new F("*","multiply",[Be.clone(),new O("sqrt",[new F("-","subtract",[de(1),new F("^","pow",[Be.clone(),de(2)])])])]);break;case"acsch":ke=!0,ze=!0,et=new F("*","multiply",[new O("abs",[Be.clone()]),new O("sqrt",[new F("+","add",[new F("^","pow",[Be.clone(),de(2)]),de(1)])])]);break;case"acoth":ke=!0,ze=!0,et=new F("-","subtract",[de(1),new F("^","pow",[Be.clone(),de(2)])]);break;case"abs":et=new F("/","divide",[new O(new H("abs"),[Be.clone()]),Be.clone()]);break;default:throw new Error('Cannot process function "'+De.name+'" in derivative: the function is not supported, undefined, or the number of arguments passed to it are not supported')}ke?(pt="/",$t="divide"):(pt="*",$t="multiply");var Zt=Le(Be,pe);return ze&&(Zt=new F("-","unaryMinus",[Zt])),new F(pt,$t,[Zt,et])},"OperatorNode, Object":function(De,pe){if(void 0!==pe[De])return de(0);if("+"===De.op)return new F(De.op,De.fn,De.args.map(function(lt){return Le(lt,pe)}));if("-"===De.op){if(De.isUnary())return new F(De.op,De.fn,[Le(De.args[0],pe)]);if(De.isBinary())return new F(De.op,De.fn,[Le(De.args[0],pe),Le(De.args[1],pe)])}if("*"===De.op){var Be=De.args.filter(function(lt){return void 0!==pe[lt]});if(Be.length>0){var We=De.args.filter(function(lt){return void 0===pe[lt]}),ke=1===We.length?We[0]:new F("*","multiply",We),ze=Be.concat(Le(ke,pe));return new F("*","multiply",ze)}return new F("+","add",De.args.map(function(lt){return new F("*","multiply",De.args.map(function(st){return st===lt?Le(st,pe):st.clone()}))}))}if("/"===De.op&&De.isBinary()){var et=De.args[0],pt=De.args[1];return void 0!==pe[pt]?new F("/","divide",[Le(et,pe),pt]):void 0!==pe[et]?new F("*","multiply",[new F("-","unaryMinus",[et]),new F("/","divide",[Le(pt,pe),new F("^","pow",[pt.clone(),de(2)])])]):new F("/","divide",[new F("-","subtract",[new F("*","multiply",[Le(et,pe),pt.clone()]),new F("*","multiply",[et.clone(),Le(pt,pe)])]),new F("^","pow",[pt.clone(),de(2)])])}if("^"===De.op&&De.isBinary()){var $t=De.args[0],Zt=De.args[1];if(void 0!==pe[$t])return Qi($t)&&(A($t.value)||C($t.value,1))?de(0):new F("*","multiply",[De,new F("*","multiply",[new O("log",[$t.clone()]),Le(Zt.clone(),pe)])]);if(void 0!==pe[Zt]){if(Qi(Zt)){if(A(Zt.value))return de(0);if(C(Zt.value,1))return Le($t,pe)}var Kt=new F("^","pow",[$t.clone(),new F("-","subtract",[Zt,de(1)])]);return new F("*","multiply",[Zt.clone(),new F("*","multiply",[Le($t,pe),Kt])])}return new F("*","multiply",[new F("^","pow",[$t.clone(),Zt.clone()]),new F("+","add",[new F("*","multiply",[Le($t,pe),new F("/","divide",[Zt.clone(),$t.clone()])]),new F("*","multiply",[Le(Zt,pe),new O("log",[$t.clone()])])])])}throw new Error('Cannot process operator "'+De.op+'" in derivative: the operator is not supported, undefined, or the number of arguments passed to it are not supported')}});function de(Te,De){return new R(k(Te,De||Fr(String(Te),b)))}return te}),$R={name:"e",category:"Constants",syntax:["e"],description:"Euler's number, the base of the natural logarithm. Approximately equal to 2.71828",examples:["e","e ^ 2","exp(2)","log(e)"],seealso:["exp"]},mF={name:"pi",category:"Constants",syntax:["pi"],description:"The number pi is a mathematical constant that is the ratio of a circle's circumference to its diameter, and is approximately equal to 3.14159",examples:["pi","sin(pi/2)"],seealso:["tau"]},oA={bignumber:{name:"bignumber",category:"Construction",syntax:["bignumber(x)"],description:"Create a big number from a number or string.",examples:["0.1 + 0.2","bignumber(0.1) + bignumber(0.2)",'bignumber("7.2")','bignumber("7.2e500")',"bignumber([0.1, 0.2, 0.3])"],seealso:["boolean","bigint","complex","fraction","index","matrix","string","unit"]},bigint:{name:"bigint",category:"Construction",syntax:["bigint(x)"],description:"Create a bigint, an integer with an arbitrary number of digits, from a number or string.",examples:["123123123123123123 # a large number will lose digits",'bigint("123123123123123123")','bignumber(["1", "3", "5"])'],seealso:["boolean","bignumber","number","complex","fraction","index","matrix","string","unit"]},boolean:{name:"boolean",category:"Construction",syntax:["x","boolean(x)"],description:"Convert a string or number into a boolean.",examples:["boolean(0)","boolean(1)","boolean(3)",'boolean("true")','boolean("false")',"boolean([1, 0, 1, 1])"],seealso:["bignumber","complex","index","matrix","number","string","unit"]},complex:{name:"complex",category:"Construction",syntax:["complex()","complex(re, im)","complex(string)"],description:"Create a complex number.",examples:["complex()","complex(2, 3)",'complex("7 - 2i")'],seealso:["bignumber","boolean","index","matrix","number","string","unit"]},createUnit:{name:"createUnit",category:"Construction",syntax:["createUnit(definitions)","createUnit(name, definition)"],description:"Create a user-defined unit and register it with the Unit type.",examples:['createUnit("foo")','createUnit("knot", {definition: "0.514444444 m/s", aliases: ["knots", "kt", "kts"]})','createUnit("mph", "1 mile/hour")'],seealso:["unit","splitUnit"]},fraction:{name:"fraction",category:"Construction",syntax:["fraction(num)","fraction(matrix)","fraction(num,den)","fraction({n: num, d: den})"],description:"Create a fraction from a number or from integer numerator and denominator.",examples:["fraction(0.125)","fraction(1, 3) + fraction(2, 5)","fraction({n: 333, d: 53})","fraction([sqrt(9), sqrt(10), sqrt(11)])"],seealso:["bignumber","boolean","complex","index","matrix","string","unit"]},index:{name:"index",category:"Construction",syntax:["[start]","[start:end]","[start:step:end]","[start1, start 2, ...]","[start1:end1, start2:end2, ...]","[start1:step1:end1, start2:step2:end2, ...]"],description:"Create an index to get or replace a subset of a matrix",examples:["A = [1, 2, 3; 4, 5, 6]","A[1, :]","A[1, 2] = 50","A[1:2, 1:2] = 1","B = [1, 2, 3]","B[B>1 and B<3]"],seealso:["bignumber","boolean","complex","matrix,","number","range","string","unit"]},matrix:{name:"matrix",category:"Construction",syntax:["[]","[a1, b1, ...; a2, b2, ...]","matrix()",'matrix("dense")',"matrix([...])"],description:"Create a matrix.",examples:["[]","[1, 2, 3]","[1, 2, 3; 4, 5, 6]","matrix()","matrix([3, 4])",'matrix([3, 4; 5, 6], "sparse")','matrix([3, 4; 5, 6], "sparse", "number")'],seealso:["bignumber","boolean","complex","index","number","string","unit","sparse"]},number:{name:"number",category:"Construction",syntax:["x","number(x)","number(unit, valuelessUnit)"],description:"Create a number or convert a string or boolean into a number.",examples:["2","2e3","4.05","number(2)",'number("7.2")',"number(true)","number([true, false, true, true])",'number(unit("52cm"), "m")'],seealso:["bignumber","bigint","boolean","complex","fraction","index","matrix","string","unit"]},sparse:{name:"sparse",category:"Construction",syntax:["sparse()","sparse([a1, b1, ...; a1, b2, ...])",'sparse([a1, b1, ...; a1, b2, ...], "number")'],description:"Create a sparse matrix.",examples:["sparse()","sparse([3, 4; 5, 6])",'sparse([3, 0; 5, 0], "number")'],seealso:["bignumber","boolean","complex","index","number","string","unit","matrix"]},splitUnit:{name:"splitUnit",category:"Construction",syntax:["splitUnit(unit: Unit, parts: Unit[])"],description:"Split a unit in an array of units whose sum is equal to the original unit.",examples:['splitUnit(1 m, ["feet", "inch"])'],seealso:["unit","createUnit"]},string:{name:"string",category:"Construction",syntax:['"text"',"string(x)"],description:"Create a string or convert a value to a string",examples:['"Hello World!"',"string(4.2)","string(3 + 2i)"],seealso:["bignumber","boolean","complex","index","matrix","number","unit"]},unit:{name:"unit",category:"Construction",syntax:["value unit","unit(value, unit)","unit(string)"],description:"Create a unit.",examples:["5.5 mm","3 inch",'unit(7.1, "kilogram")','unit("23 deg")'],seealso:["bignumber","boolean","complex","index","matrix","number","string"]},e:$R,E:$R,false:{name:"false",category:"Constants",syntax:["false"],description:"Boolean value false",examples:["false"],seealso:["true"]},i:{name:"i",category:"Constants",syntax:["i"],description:"Imaginary unit, defined as i*i=-1. A complex number is described as a + b*i, where a is the real part, and b is the imaginary part.",examples:["i","i * i","sqrt(-1)"],seealso:[]},Infinity:{name:"Infinity",category:"Constants",syntax:["Infinity"],description:"Infinity, a number which is larger than the maximum number that can be handled by a floating point number.",examples:["Infinity","1 / 0"],seealso:[]},LN2:{name:"LN2",category:"Constants",syntax:["LN2"],description:"Returns the natural logarithm of 2, approximately equal to 0.693",examples:["LN2","log(2)"],seealso:[]},LN10:{name:"LN10",category:"Constants",syntax:["LN10"],description:"Returns the natural logarithm of 10, approximately equal to 2.302",examples:["LN10","log(10)"],seealso:[]},LOG2E:{name:"LOG2E",category:"Constants",syntax:["LOG2E"],description:"Returns the base-2 logarithm of E, approximately equal to 1.442",examples:["LOG2E","log(e, 2)"],seealso:[]},LOG10E:{name:"LOG10E",category:"Constants",syntax:["LOG10E"],description:"Returns the base-10 logarithm of E, approximately equal to 0.434",examples:["LOG10E","log(e, 10)"],seealso:[]},NaN:{name:"NaN",category:"Constants",syntax:["NaN"],description:"Not a number",examples:["NaN","0 / 0"],seealso:[]},null:{name:"null",category:"Constants",syntax:["null"],description:"Value null",examples:["null"],seealso:["true","false"]},pi:mF,PI:mF,phi:{name:"phi",category:"Constants",syntax:["phi"],description:"Phi is the golden ratio. Two quantities are in the golden ratio if their ratio is the same as the ratio of their sum to the larger of the two quantities. Phi is defined as `(1 + sqrt(5)) / 2` and is approximately 1.618034...",examples:["phi"],seealso:[]},SQRT1_2:{name:"SQRT1_2",category:"Constants",syntax:["SQRT1_2"],description:"Returns the square root of 1/2, approximately equal to 0.707",examples:["SQRT1_2","sqrt(1/2)"],seealso:[]},SQRT2:{name:"SQRT2",category:"Constants",syntax:["SQRT2"],description:"Returns the square root of 2, approximately equal to 1.414",examples:["SQRT2","sqrt(2)"],seealso:[]},tau:{name:"tau",category:"Constants",syntax:["tau"],description:"Tau is the ratio constant of a circle's circumference to radius, equal to 2 * pi, approximately 6.2832.",examples:["tau","2 * pi"],seealso:["pi"]},true:{name:"true",category:"Constants",syntax:["true"],description:"Boolean value true",examples:["true"],seealso:["false"]},version:{name:"version",category:"Constants",syntax:["version"],description:"A string with the version number of math.js",examples:["version"],seealso:[]},speedOfLight:{description:"Speed of light in vacuum",examples:["speedOfLight"]},gravitationConstant:{description:"Newtonian constant of gravitation",examples:["gravitationConstant"]},planckConstant:{description:"Planck constant",examples:["planckConstant"]},reducedPlanckConstant:{description:"Reduced Planck constant",examples:["reducedPlanckConstant"]},magneticConstant:{description:"Magnetic constant (vacuum permeability)",examples:["magneticConstant"]},electricConstant:{description:"Electric constant (vacuum permeability)",examples:["electricConstant"]},vacuumImpedance:{description:"Characteristic impedance of vacuum",examples:["vacuumImpedance"]},coulomb:{description:"Coulomb's constant",examples:["coulomb"]},elementaryCharge:{description:"Elementary charge",examples:["elementaryCharge"]},bohrMagneton:{description:"Bohr magneton",examples:["bohrMagneton"]},conductanceQuantum:{description:"Conductance quantum",examples:["conductanceQuantum"]},inverseConductanceQuantum:{description:"Inverse conductance quantum",examples:["inverseConductanceQuantum"]},magneticFluxQuantum:{description:"Magnetic flux quantum",examples:["magneticFluxQuantum"]},nuclearMagneton:{description:"Nuclear magneton",examples:["nuclearMagneton"]},klitzing:{description:"Von Klitzing constant",examples:["klitzing"]},bohrRadius:{description:"Bohr radius",examples:["bohrRadius"]},classicalElectronRadius:{description:"Classical electron radius",examples:["classicalElectronRadius"]},electronMass:{description:"Electron mass",examples:["electronMass"]},fermiCoupling:{description:"Fermi coupling constant",examples:["fermiCoupling"]},fineStructure:{description:"Fine-structure constant",examples:["fineStructure"]},hartreeEnergy:{description:"Hartree energy",examples:["hartreeEnergy"]},protonMass:{description:"Proton mass",examples:["protonMass"]},deuteronMass:{description:"Deuteron Mass",examples:["deuteronMass"]},neutronMass:{description:"Neutron mass",examples:["neutronMass"]},quantumOfCirculation:{description:"Quantum of circulation",examples:["quantumOfCirculation"]},rydberg:{description:"Rydberg constant",examples:["rydberg"]},thomsonCrossSection:{description:"Thomson cross section",examples:["thomsonCrossSection"]},weakMixingAngle:{description:"Weak mixing angle",examples:["weakMixingAngle"]},efimovFactor:{description:"Efimov factor",examples:["efimovFactor"]},atomicMass:{description:"Atomic mass constant",examples:["atomicMass"]},avogadro:{description:"Avogadro's number",examples:["avogadro"]},boltzmann:{description:"Boltzmann constant",examples:["boltzmann"]},faraday:{description:"Faraday constant",examples:["faraday"]},firstRadiation:{description:"First radiation constant",examples:["firstRadiation"]},loschmidt:{description:"Loschmidt constant at T=273.15 K and p=101.325 kPa",examples:["loschmidt"]},gasConstant:{description:"Gas constant",examples:["gasConstant"]},molarPlanckConstant:{description:"Molar Planck constant",examples:["molarPlanckConstant"]},molarVolume:{description:"Molar volume of an ideal gas at T=273.15 K and p=101.325 kPa",examples:["molarVolume"]},sackurTetrode:{description:"Sackur-Tetrode constant at T=1 K and p=101.325 kPa",examples:["sackurTetrode"]},secondRadiation:{description:"Second radiation constant",examples:["secondRadiation"]},stefanBoltzmann:{description:"Stefan-Boltzmann constant",examples:["stefanBoltzmann"]},wienDisplacement:{description:"Wien displacement law constant",examples:["wienDisplacement"]},molarMass:{description:"Molar mass constant",examples:["molarMass"]},molarMassC12:{description:"Molar mass constant of carbon-12",examples:["molarMassC12"]},gravity:{description:"Standard acceleration of gravity (standard acceleration of free-fall on Earth)",examples:["gravity"]},planckLength:{description:"Planck length",examples:["planckLength"]},planckMass:{description:"Planck mass",examples:["planckMass"]},planckTime:{description:"Planck time",examples:["planckTime"]},planckCharge:{description:"Planck charge",examples:["planckCharge"]},planckTemperature:{description:"Planck temperature",examples:["planckTemperature"]},derivative:{name:"derivative",category:"Algebra",syntax:["derivative(expr, variable)","derivative(expr, variable, {simplify: boolean})"],description:"Takes the derivative of an expression expressed in parser Nodes. The derivative will be taken over the supplied variable in the second parameter. If there are multiple variables in the expression, it will return a partial derivative.",examples:['derivative("2x^3", "x")','derivative("2x^3", "x", {simplify: false})','derivative("2x^2 + 3x + 4", "x")','derivative("sin(2x)", "x")','f = parse("x^2 + x")','x = parse("x")',"df = derivative(f, x)","df.evaluate({x: 3})"],seealso:["simplify","parse","evaluate"]},lsolve:{name:"lsolve",category:"Algebra",syntax:["x=lsolve(L, b)"],description:"Finds one solution of the linear system L * x = b where L is an [n x n] lower triangular matrix and b is a [n] column vector.",examples:["a = [-2, 3; 2, 1]","b = [11, 9]","x = lsolve(a, b)"],seealso:["lsolveAll","lup","lusolve","usolve","matrix","sparse"]},lsolveAll:{name:"lsolveAll",category:"Algebra",syntax:["x=lsolveAll(L, b)"],description:"Finds all solutions of the linear system L * x = b where L is an [n x n] lower triangular matrix and b is a [n] column vector.",examples:["a = [-2, 3; 2, 1]","b = [11, 9]","x = lsolve(a, b)"],seealso:["lsolve","lup","lusolve","usolve","matrix","sparse"]},lup:{name:"lup",category:"Algebra",syntax:["lup(m)"],description:"Calculate the Matrix LU decomposition with partial pivoting. Matrix A is decomposed in three matrices (L, U, P) where P * A = L * U",examples:["lup([[2, 1], [1, 4]])","lup(matrix([[2, 1], [1, 4]]))","lup(sparse([[2, 1], [1, 4]]))"],seealso:["lusolve","lsolve","usolve","matrix","sparse","slu","qr"]},lusolve:{name:"lusolve",category:"Algebra",syntax:["x=lusolve(A, b)","x=lusolve(lu, b)"],description:"Solves the linear system A * x = b where A is an [n x n] matrix and b is a [n] column vector.",examples:["a = [-2, 3; 2, 1]","b = [11, 9]","x = lusolve(a, b)"],seealso:["lup","slu","lsolve","usolve","matrix","sparse"]},leafCount:{name:"leafCount",category:"Algebra",syntax:["leafCount(expr)"],description:"Computes the number of leaves in the parse tree of the given expression",examples:['leafCount("e^(i*pi)-1")','leafCount(parse("{a: 22/7, b: 10^(1/2)}"))'],seealso:["simplify"]},polynomialRoot:{name:"polynomialRoot",category:"Algebra",syntax:["x=polynomialRoot(-6, 3)","x=polynomialRoot(4, -4, 1)","x=polynomialRoot(-8, 12, -6, 1)"],description:"Finds the roots of a univariate polynomial given by its coefficients starting from constant, linear, and so on, increasing in degree.",examples:["a = polynomialRoot(-6, 11, -6, 1)"],seealso:["cbrt","sqrt"]},resolve:{name:"resolve",category:"Algebra",syntax:["resolve(node, scope)"],description:"Recursively substitute variables in an expression tree.",examples:['resolve(parse("1 + x"), { x: 7 })','resolve(parse("size(text)"), { text: "Hello World" })','resolve(parse("x + y"), { x: parse("3z") })','resolve(parse("3x"), { x: parse("y+z"), z: parse("w^y") })'],seealso:["simplify","evaluate"],mayThrow:["ReferenceError"]},simplify:{name:"simplify",category:"Algebra",syntax:["simplify(expr)","simplify(expr, rules)"],description:"Simplify an expression tree.",examples:['simplify("3 + 2 / 4")','simplify("2x + x")','f = parse("x * (x + 2 + x)")',"simplified = simplify(f)","simplified.evaluate({x: 2})"],seealso:["simplifyCore","derivative","evaluate","parse","rationalize","resolve"]},simplifyConstant:{name:"simplifyConstant",category:"Algebra",syntax:["simplifyConstant(expr)","simplifyConstant(expr, options)"],description:"Replace constant subexpressions of node with their values.",examples:['simplifyConstant("(3-3)*x")','simplifyConstant(parse("z-cos(tau/8)"))'],seealso:["simplify","simplifyCore","evaluate"]},simplifyCore:{name:"simplifyCore",category:"Algebra",syntax:["simplifyCore(node)"],description:"Perform simple one-pass simplifications on an expression tree.",examples:['simplifyCore(parse("0*x"))','simplifyCore(parse("(x+0)*2"))'],seealso:["simplify","simplifyConstant","evaluate"]},symbolicEqual:{name:"symbolicEqual",category:"Algebra",syntax:["symbolicEqual(expr1, expr2)","symbolicEqual(expr1, expr2, options)"],description:"Returns true if the difference of the expressions simplifies to 0",examples:['symbolicEqual("x*y","y*x")','symbolicEqual("abs(x^2)", "x^2")','symbolicEqual("abs(x)", "x", {context: {abs: {trivial: true}}})'],seealso:["simplify","evaluate"]},rationalize:{name:"rationalize",category:"Algebra",syntax:["rationalize(expr)","rationalize(expr, scope)","rationalize(expr, scope, detailed)"],description:"Transform a rationalizable expression in a rational fraction. If rational fraction is one variable polynomial then converts the numerator and denominator in canonical form, with decreasing exponents, returning the coefficients of numerator.",examples:['rationalize("2x/y - y/(x+1)")','rationalize("2x/y - y/(x+1)", true)'],seealso:["simplify"]},slu:{name:"slu",category:"Algebra",syntax:["slu(A, order, threshold)"],description:"Calculate the Matrix LU decomposition with full pivoting. Matrix A is decomposed in two matrices (L, U) and two permutation vectors (pinv, q) where P * A * Q = L * U",examples:["slu(sparse([4.5, 0, 3.2, 0; 3.1, 2.9, 0, 0.9; 0, 1.7, 3, 0; 3.5, 0.4, 0, 1]), 1, 0.001)"],seealso:["lusolve","lsolve","usolve","matrix","sparse","lup","qr"]},usolve:{name:"usolve",category:"Algebra",syntax:["x=usolve(U, b)"],description:"Finds one solution of the linear system U * x = b where U is an [n x n] upper triangular matrix and b is a [n] column vector.",examples:["x=usolve(sparse([1, 1, 1, 1; 0, 1, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1]), [1; 2; 3; 4])"],seealso:["usolveAll","lup","lusolve","lsolve","matrix","sparse"]},usolveAll:{name:"usolveAll",category:"Algebra",syntax:["x=usolve(U, b)"],description:"Finds all solutions of the linear system U * x = b where U is an [n x n] upper triangular matrix and b is a [n] column vector.",examples:["x=usolve(sparse([1, 1, 1, 1; 0, 1, 1, 1; 0, 0, 1, 1; 0, 0, 0, 1]), [1; 2; 3; 4])"],seealso:["usolve","lup","lusolve","lsolve","matrix","sparse"]},qr:{name:"qr",category:"Algebra",syntax:["qr(A)"],description:"Calculates the Matrix QR decomposition. Matrix `A` is decomposed in two matrices (`Q`, `R`) where `Q` is an orthogonal matrix and `R` is an upper triangular matrix.",examples:["qr([[1, -1, 4], [1, 4, -2], [1, 4, 2], [1, -1, 0]])"],seealso:["lup","slu","matrix"]},abs:{name:"abs",category:"Arithmetic",syntax:["abs(x)"],description:"Compute the absolute value.",examples:["abs(3.5)","abs(-4.2)"],seealso:["sign"]},add:{name:"add",category:"Operators",syntax:["x + y","add(x, y)"],description:"Add two values.",examples:["a = 2.1 + 3.6","a - 3.6","3 + 2i","3 cm + 2 inch",'"2.3" + "4"'],seealso:["subtract"]},cbrt:{name:"cbrt",category:"Arithmetic",syntax:["cbrt(x)","cbrt(x, allRoots)"],description:"Compute the cubic root value. If x = y * y * y, then y is the cubic root of x. When `x` is a number or complex number, an optional second argument `allRoots` can be provided to return all three cubic roots. If not provided, the principal root is returned",examples:["cbrt(64)","cube(4)","cbrt(-8)","cbrt(2 + 3i)","cbrt(8i)","cbrt(8i, true)","cbrt(27 m^3)"],seealso:["square","sqrt","cube","multiply"]},ceil:{name:"ceil",category:"Arithmetic",syntax:["ceil(x)"],description:"Round a value towards plus infinity. If x is complex, both real and imaginary part are rounded towards plus infinity.",examples:["ceil(3.2)","ceil(3.8)","ceil(-4.2)"],seealso:["floor","fix","round"]},cube:{name:"cube",category:"Arithmetic",syntax:["cube(x)"],description:"Compute the cube of a value. The cube of x is x * x * x.",examples:["cube(2)","2^3","2 * 2 * 2"],seealso:["multiply","square","pow"]},divide:{name:"divide",category:"Operators",syntax:["x / y","divide(x, y)"],description:"Divide two values.",examples:["a = 2 / 3","a * 3","4.5 / 2","3 + 4 / 2","(3 + 4) / 2","18 km / 4.5"],seealso:["multiply"]},dotDivide:{name:"dotDivide",category:"Operators",syntax:["x ./ y","dotDivide(x, y)"],description:"Divide two values element wise.",examples:["a = [1, 2, 3; 4, 5, 6]","b = [2, 1, 1; 3, 2, 5]","a ./ b"],seealso:["multiply","dotMultiply","divide"]},dotMultiply:{name:"dotMultiply",category:"Operators",syntax:["x .* y","dotMultiply(x, y)"],description:"Multiply two values element wise.",examples:["a = [1, 2, 3; 4, 5, 6]","b = [2, 1, 1; 3, 2, 5]","a .* b"],seealso:["multiply","divide","dotDivide"]},dotPow:{name:"dotPow",category:"Operators",syntax:["x .^ y","dotPow(x, y)"],description:"Calculates the power of x to y element wise.",examples:["a = [1, 2, 3; 4, 5, 6]","a .^ 2"],seealso:["pow"]},exp:{name:"exp",category:"Arithmetic",syntax:["exp(x)"],description:"Calculate the exponent of a value.",examples:["exp(1.3)","e ^ 1.3","log(exp(1.3))","x = 2.4","(exp(i*x) == cos(x) + i*sin(x)) # Euler's formula"],seealso:["expm","expm1","pow","log"]},expm:{name:"expm",category:"Arithmetic",syntax:["exp(x)"],description:"Compute the matrix exponential, expm(A) = e^A. The matrix must be square. Not to be confused with exp(a), which performs element-wise exponentiation.",examples:["expm([[0,2],[0,0]])"],seealso:["exp"]},expm1:{name:"expm1",category:"Arithmetic",syntax:["expm1(x)"],description:"Calculate the value of subtracting 1 from the exponential value.",examples:["expm1(2)","pow(e, 2) - 1","log(expm1(2) + 1)"],seealso:["exp","pow","log"]},fix:{name:"fix",category:"Arithmetic",syntax:["fix(x)"],description:"Round a value towards zero. If x is complex, both real and imaginary part are rounded towards zero.",examples:["fix(3.2)","fix(3.8)","fix(-4.2)","fix(-4.8)"],seealso:["ceil","floor","round"]},floor:{name:"floor",category:"Arithmetic",syntax:["floor(x)"],description:"Round a value towards minus infinity.If x is complex, both real and imaginary part are rounded towards minus infinity.",examples:["floor(3.2)","floor(3.8)","floor(-4.2)"],seealso:["ceil","fix","round"]},gcd:{name:"gcd",category:"Arithmetic",syntax:["gcd(a, b)","gcd(a, b, c, ...)"],description:"Compute the greatest common divisor.",examples:["gcd(8, 12)","gcd(-4, 6)","gcd(25, 15, -10)"],seealso:["lcm","xgcd"]},hypot:{name:"hypot",category:"Arithmetic",syntax:["hypot(a, b, c, ...)","hypot([a, b, c, ...])"],description:"Calculate the hypotenuse of a list with values.",examples:["hypot(3, 4)","sqrt(3^2 + 4^2)","hypot(-2)","hypot([3, 4, 5])"],seealso:["abs","norm"]},lcm:{name:"lcm",category:"Arithmetic",syntax:["lcm(x, y)"],description:"Compute the least common multiple.",examples:["lcm(4, 6)","lcm(6, 21)","lcm(6, 21, 5)"],seealso:["gcd"]},log:{name:"log",category:"Arithmetic",syntax:["log(x)","log(x, base)"],description:"Compute the logarithm of a value. If no base is provided, the natural logarithm of x is calculated. If base if provided, the logarithm is calculated for the specified base. log(x, base) is defined as log(x) / log(base).",examples:["log(3.5)","a = log(2.4)","exp(a)","10 ^ 4","log(10000, 10)","log(10000) / log(10)","b = log(1024, 2)","2 ^ b"],seealso:["exp","log1p","log2","log10"]},log2:{name:"log2",category:"Arithmetic",syntax:["log2(x)"],description:"Calculate the 2-base of a value. This is the same as calculating `log(x, 2)`.",examples:["log2(0.03125)","log2(16)","log2(16) / log2(2)","pow(2, 4)"],seealso:["exp","log1p","log","log10"]},log1p:{name:"log1p",category:"Arithmetic",syntax:["log1p(x)","log1p(x, base)"],description:"Calculate the logarithm of a `value+1`",examples:["log1p(2.5)","exp(log1p(1.4))","pow(10, 4)","log1p(9999, 10)","log1p(9999) / log(10)"],seealso:["exp","log","log2","log10"]},log10:{name:"log10",category:"Arithmetic",syntax:["log10(x)"],description:"Compute the 10-base logarithm of a value.",examples:["log10(0.00001)","log10(10000)","10 ^ 4","log(10000) / log(10)","log(10000, 10)"],seealso:["exp","log"]},mod:{name:"mod",category:"Operators",syntax:["x % y","x mod y","mod(x, y)"],description:"Calculates the modulus, the remainder of an integer division.",examples:["7 % 3","11 % 2","10 mod 4","isOdd(x) = x % 2","isOdd(2)","isOdd(3)"],seealso:["divide"]},multiply:{name:"multiply",category:"Operators",syntax:["x * y","multiply(x, y)"],description:"multiply two values.",examples:["a = 2.1 * 3.4","a / 3.4","2 * 3 + 4","2 * (3 + 4)","3 * 2.1 km"],seealso:["divide"]},norm:{name:"norm",category:"Arithmetic",syntax:["norm(x)","norm(x, p)"],description:"Calculate the norm of a number, vector or matrix.",examples:["abs(-3.5)","norm(-3.5)","norm(3 - 4i)","norm([1, 2, -3], Infinity)","norm([1, 2, -3], -Infinity)","norm([3, 4], 2)","norm([[1, 2], [3, 4]], 1)",'norm([[1, 2], [3, 4]], "inf")','norm([[1, 2], [3, 4]], "fro")']},nthRoot:{name:"nthRoot",category:"Arithmetic",syntax:["nthRoot(a)","nthRoot(a, root)"],description:'Calculate the nth root of a value. The principal nth root of a positive real number A, is the positive real solution of the equation "x^root = A".',examples:["4 ^ 3","nthRoot(64, 3)","nthRoot(9, 2)","sqrt(9)"],seealso:["nthRoots","pow","sqrt"]},nthRoots:{name:"nthRoots",category:"Arithmetic",syntax:["nthRoots(A)","nthRoots(A, root)"],description:'Calculate the nth roots of a value. An nth root of a positive real number A, is a positive real solution of the equation "x^root = A". This function returns an array of complex values.',examples:["nthRoots(1)","nthRoots(1, 3)"],seealso:["sqrt","pow","nthRoot"]},pow:{name:"pow",category:"Operators",syntax:["x ^ y","pow(x, y)"],description:"Calculates the power of x to y, x^y.",examples:["2^3","2*2*2","1 + e ^ (pi * i)","pow([[1, 2], [4, 3]], 2)","pow([[1, 2], [4, 3]], -1)"],seealso:["multiply","nthRoot","nthRoots","sqrt"]},round:{name:"round",category:"Arithmetic",syntax:["round(x)","round(x, n)","round(unit, valuelessUnit)","round(unit, n, valuelessUnit)"],description:"round a value towards the nearest integer.If x is complex, both real and imaginary part are rounded towards the nearest integer. When n is specified, the value is rounded to n decimals.",examples:["round(3.2)","round(3.8)","round(-4.2)","round(-4.8)","round(pi, 3)","round(123.45678, 2)","round(3.241cm, 2, cm)","round([3.2, 3.8, -4.7])"],seealso:["ceil","floor","fix"]},sign:{name:"sign",category:"Arithmetic",syntax:["sign(x)"],description:"Compute the sign of a value. The sign of a value x is 1 when x>1, -1 when x<0, and 0 when x=0.",examples:["sign(3.5)","sign(-4.2)","sign(0)"],seealso:["abs"]},sqrt:{name:"sqrt",category:"Arithmetic",syntax:["sqrt(x)"],description:"Compute the square root value. If x = y * y, then y is the square root of x.",examples:["sqrt(25)","5 * 5","sqrt(-1)"],seealso:["square","sqrtm","multiply","nthRoot","nthRoots","pow"]},sqrtm:{name:"sqrtm",category:"Arithmetic",syntax:["sqrtm(x)"],description:"Calculate the principal square root of a square matrix. The principal square root matrix `X` of another matrix `A` is such that `X * X = A`.",examples:["sqrtm([[33, 24], [48, 57]])"],seealso:["sqrt","abs","square","multiply"]},square:{name:"square",category:"Arithmetic",syntax:["square(x)"],description:"Compute the square of a value. The square of x is x * x.",examples:["square(3)","sqrt(9)","3^2","3 * 3"],seealso:["multiply","pow","sqrt","cube"]},subtract:{name:"subtract",category:"Operators",syntax:["x - y","subtract(x, y)"],description:"subtract two values.",examples:["a = 5.3 - 2","a + 2","2/3 - 1/6","2 * 3 - 3","2.1 km - 500m"],seealso:["add"]},unaryMinus:{name:"unaryMinus",category:"Operators",syntax:["-x","unaryMinus(x)"],description:"Inverse the sign of a value. Converts booleans and strings to numbers.",examples:["-4.5","-(-5.6)",'-"22"'],seealso:["add","subtract","unaryPlus"]},unaryPlus:{name:"unaryPlus",category:"Operators",syntax:["+x","unaryPlus(x)"],description:"Converts booleans and strings to numbers.",examples:["+true",'+"2"'],seealso:["add","subtract","unaryMinus"]},xgcd:{name:"xgcd",category:"Arithmetic",syntax:["xgcd(a, b)"],description:"Calculate the extended greatest common divisor for two values. The result is an array [d, x, y] with 3 entries, where d is the greatest common divisor, and d = x * a + y * b.",examples:["xgcd(8, 12)","gcd(8, 12)","xgcd(36163, 21199)"],seealso:["gcd","lcm"]},invmod:{name:"invmod",category:"Arithmetic",syntax:["invmod(a, b)"],description:"Calculate the (modular) multiplicative inverse of a modulo b. Solution to the equation ax \u2263 1 (mod b)",examples:["invmod(8, 12)","invmod(7, 13)","invmod(15151, 15122)"],seealso:["gcd","xgcd"]},bitAnd:{name:"bitAnd",category:"Bitwise",syntax:["x & y","bitAnd(x, y)"],description:"Bitwise AND operation. Performs the logical AND operation on each pair of the corresponding bits of the two given values by multiplying them. If both bits in the compared position are 1, the bit in the resulting binary representation is 1, otherwise, the result is 0",examples:["5 & 3","bitAnd(53, 131)","[1, 12, 31] & 42"],seealso:["bitNot","bitOr","bitXor","leftShift","rightArithShift","rightLogShift"]},bitNot:{name:"bitNot",category:"Bitwise",syntax:["~x","bitNot(x)"],description:"Bitwise NOT operation. Performs a logical negation on each bit of the given value. Bits that are 0 become 1, and those that are 1 become 0.",examples:["~1","~2","bitNot([2, -3, 4])"],seealso:["bitAnd","bitOr","bitXor","leftShift","rightArithShift","rightLogShift"]},bitOr:{name:"bitOr",category:"Bitwise",syntax:["x | y","bitOr(x, y)"],description:"Bitwise OR operation. Performs the logical inclusive OR operation on each pair of corresponding bits of the two given values. The result in each position is 1 if the first bit is 1 or the second bit is 1 or both bits are 1, otherwise, the result is 0.",examples:["5 | 3","bitOr([1, 2, 3], 4)"],seealso:["bitAnd","bitNot","bitXor","leftShift","rightArithShift","rightLogShift"]},bitXor:{name:"bitXor",category:"Bitwise",syntax:["bitXor(x, y)"],description:"Bitwise XOR operation, exclusive OR. Performs the logical exclusive OR operation on each pair of corresponding bits of the two given values. The result in each position is 1 if only the first bit is 1 or only the second bit is 1, but will be 0 if both are 0 or both are 1.",examples:["bitOr(1, 2)","bitXor([2, 3, 4], 4)"],seealso:["bitAnd","bitNot","bitOr","leftShift","rightArithShift","rightLogShift"]},leftShift:{name:"leftShift",category:"Bitwise",syntax:["x << y","leftShift(x, y)"],description:"Bitwise left logical shift of a value x by y number of bits.",examples:["4 << 1","8 >> 1"],seealso:["bitAnd","bitNot","bitOr","bitXor","rightArithShift","rightLogShift"]},rightArithShift:{name:"rightArithShift",category:"Bitwise",syntax:["x >> y","rightArithShift(x, y)"],description:"Bitwise right arithmetic shift of a value x by y number of bits.",examples:["8 >> 1","4 << 1","-12 >> 2"],seealso:["bitAnd","bitNot","bitOr","bitXor","leftShift","rightLogShift"]},rightLogShift:{name:"rightLogShift",category:"Bitwise",syntax:["x >>> y","rightLogShift(x, y)"],description:"Bitwise right logical shift of a value x by y number of bits.",examples:["8 >>> 1","4 << 1","-12 >>> 2"],seealso:["bitAnd","bitNot","bitOr","bitXor","leftShift","rightArithShift"]},bellNumbers:{name:"bellNumbers",category:"Combinatorics",syntax:["bellNumbers(n)"],description:"The Bell Numbers count the number of partitions of a set. A partition is a pairwise disjoint subset of S whose union is S. `bellNumbers` only takes integer arguments. The following condition must be enforced: n >= 0.",examples:["bellNumbers(3)","bellNumbers(8)"],seealso:["stirlingS2"]},catalan:{name:"catalan",category:"Combinatorics",syntax:["catalan(n)"],description:"The Catalan Numbers enumerate combinatorial structures of many different types. catalan only takes integer arguments. The following condition must be enforced: n >= 0.",examples:["catalan(3)","catalan(8)"],seealso:["bellNumbers"]},composition:{name:"composition",category:"Combinatorics",syntax:["composition(n, k)"],description:"The composition counts of n into k parts. composition only takes integer arguments. The following condition must be enforced: k <= n.",examples:["composition(5, 3)"],seealso:["combinations"]},stirlingS2:{name:"stirlingS2",category:"Combinatorics",syntax:["stirlingS2(n, k)"],description:"he Stirling numbers of the second kind, counts the number of ways to partition a set of n labelled objects into k nonempty unlabelled subsets. `stirlingS2` only takes integer arguments. The following condition must be enforced: k <= n. If n = k or k = 1, then s(n,k) = 1.",examples:["stirlingS2(5, 3)"],seealso:["bellNumbers"]},config:{name:"config",category:"Core",syntax:["config()","config(options)"],description:"Get configuration or change configuration.",examples:["config()","1/3 + 1/4",'config({number: "Fraction"})',"1/3 + 1/4"],seealso:[]},import:{name:"import",category:"Core",syntax:["import(functions)","import(functions, options)"],description:"Import functions or constants from an object.",examples:["import({myFn: f(x)=x^2, myConstant: 32 })","myFn(2)","myConstant"],seealso:[]},typed:{name:"typed",category:"Core",syntax:["typed(signatures)","typed(name, signatures)"],description:"Create a typed function.",examples:['double = typed({ "number": f(x)=x+x, "string": f(x)=concat(x,x) })',"double(2)",'double("hello")'],seealso:[]},arg:{name:"arg",category:"Complex",syntax:["arg(x)"],description:"Compute the argument of a complex value. If x = a+bi, the argument is computed as atan2(b, a).",examples:["arg(2 + 2i)","atan2(3, 2)","arg(2 + 3i)"],seealso:["re","im","conj","abs"]},conj:{name:"conj",category:"Complex",syntax:["conj(x)"],description:"Compute the complex conjugate of a complex value. If x = a+bi, the complex conjugate is a-bi.",examples:["conj(2 + 3i)","conj(2 - 3i)","conj(-5.2i)"],seealso:["re","im","abs","arg"]},re:{name:"re",category:"Complex",syntax:["re(x)"],description:"Get the real part of a complex number.",examples:["re(2 + 3i)","im(2 + 3i)","re(-5.2i)","re(2.4)"],seealso:["im","conj","abs","arg"]},im:{name:"im",category:"Complex",syntax:["im(x)"],description:"Get the imaginary part of a complex number.",examples:["im(2 + 3i)","re(2 + 3i)","im(-5.2i)","im(2.4)"],seealso:["re","conj","abs","arg"]},evaluate:{name:"evaluate",category:"Expression",syntax:["evaluate(expression)","evaluate(expression, scope)","evaluate([expr1, expr2, expr3, ...])","evaluate([expr1, expr2, expr3, ...], scope)"],description:"Evaluate an expression or an array with expressions.",examples:['evaluate("2 + 3")','evaluate("sqrt(16)")','evaluate("2 inch to cm")','evaluate("sin(x * pi)", { "x": 1/2 })','evaluate(["width=2", "height=4","width*height"])'],seealso:[]},help:{name:"help",category:"Expression",syntax:["help(object)","help(string)"],description:"Display documentation on a function or data type.",examples:["help(sqrt)",'help("complex")'],seealso:[]},distance:{name:"distance",category:"Geometry",syntax:["distance([x1, y1], [x2, y2])","distance([[x1, y1], [x2, y2]])"],description:"Calculates the Euclidean distance between two points.",examples:["distance([0,0], [4,4])","distance([[0,0], [4,4]])"],seealso:[]},intersect:{name:"intersect",category:"Geometry",syntax:["intersect(expr1, expr2, expr3, expr4)","intersect(expr1, expr2, expr3)"],description:"Computes the intersection point of lines and/or planes.",examples:["intersect([0, 0], [10, 10], [10, 0], [0, 10])","intersect([1, 0, 1], [4, -2, 2], [1, 1, 1, 6])"],seealso:[]},and:{name:"and",category:"Logical",syntax:["x and y","and(x, y)"],description:"Logical and. Test whether two values are both defined with a nonzero/nonempty value.",examples:["true and false","true and true","2 and 4"],seealso:["not","or","xor"]},not:{name:"not",category:"Logical",syntax:["not x","not(x)"],description:"Logical not. Flips the boolean value of given argument.",examples:["not true","not false","not 2","not 0"],seealso:["and","or","xor"]},or:{name:"or",category:"Logical",syntax:["x or y","or(x, y)"],description:"Logical or. Test if at least one value is defined with a nonzero/nonempty value.",examples:["true or false","false or false","0 or 4"],seealso:["not","and","xor"]},xor:{name:"xor",category:"Logical",syntax:["x xor y","xor(x, y)"],description:"Logical exclusive or, xor. Test whether one and only one value is defined with a nonzero/nonempty value.",examples:["true xor false","false xor false","true xor true","0 xor 4"],seealso:["not","and","or"]},concat:{name:"concat",category:"Matrix",syntax:["concat(A, B, C, ...)","concat(A, B, C, ..., dim)"],description:"Concatenate matrices. By default, the matrices are concatenated by the last dimension. The dimension on which to concatenate can be provided as last argument.",examples:["A = [1, 2; 5, 6]","B = [3, 4; 7, 8]","concat(A, B)","concat(A, B, 1)","concat(A, B, 2)"],seealso:["det","diag","identity","inv","ones","range","size","squeeze","subset","trace","transpose","zeros"]},count:{name:"count",category:"Matrix",syntax:["count(x)"],description:"Count the number of elements of a matrix, array or string.",examples:["a = [1, 2; 3, 4; 5, 6]","count(a)","size(a)",'count("hello world")'],seealso:["size"]},cross:{name:"cross",category:"Matrix",syntax:["cross(A, B)"],description:"Calculate the cross product for two vectors in three dimensional space.",examples:["cross([1, 1, 0], [0, 1, 1])","cross([3, -3, 1], [4, 9, 2])","cross([2, 3, 4], [5, 6, 7])"],seealso:["multiply","dot"]},column:{name:"column",category:"Matrix",syntax:["column(x, index)"],description:"Return a column from a matrix or array.",examples:["A = [[1, 2], [3, 4]]","column(A, 1)","column(A, 2)"],seealso:["row","matrixFromColumns"]},ctranspose:{name:"ctranspose",category:"Matrix",syntax:["x'","ctranspose(x)"],description:"Complex Conjugate and Transpose a matrix",examples:["a = [1, 2, 3; 4, 5, 6]","a'","ctranspose(a)"],seealso:["concat","det","diag","identity","inv","ones","range","size","squeeze","subset","trace","zeros"]},det:{name:"det",category:"Matrix",syntax:["det(x)"],description:"Calculate the determinant of a matrix",examples:["det([1, 2; 3, 4])","det([-2, 2, 3; -1, 1, 3; 2, 0, -1])"],seealso:["concat","diag","identity","inv","ones","range","size","squeeze","subset","trace","transpose","zeros"]},diag:{name:"diag",category:"Matrix",syntax:["diag(x)","diag(x, k)"],description:"Create a diagonal matrix or retrieve the diagonal of a matrix. When x is a vector, a matrix with the vector values on the diagonal will be returned. When x is a matrix, a vector with the diagonal values of the matrix is returned. When k is provided, the k-th diagonal will be filled in or retrieved, if k is positive, the values are placed on the super diagonal. When k is negative, the values are placed on the sub diagonal.",examples:["diag(1:3)","diag(1:3, 1)","a = [1, 2, 3; 4, 5, 6; 7, 8, 9]","diag(a)"],seealso:["concat","det","identity","inv","ones","range","size","squeeze","subset","trace","transpose","zeros"]},diff:{name:"diff",category:"Matrix",syntax:["diff(arr)","diff(arr, dim)"],description:["Create a new matrix or array with the difference of the passed matrix or array.","Dim parameter is optional and used to indicate the dimension of the array/matrix to apply the difference","If no dimension parameter is passed it is assumed as dimension 0","Dimension is zero-based in javascript and one-based in the parser","Arrays must be 'rectangular' meaning arrays like [1, 2]","If something is passed as a matrix it will be returned as a matrix but other than that all matrices are converted to arrays"],examples:["A = [1, 2, 4, 7, 0]","diff(A)","diff(A, 1)","B = [[1, 2], [3, 4]]","diff(B)","diff(B, 1)","diff(B, 2)","diff(B, bignumber(2))","diff([[1, 2], matrix([3, 4])], 2)"],seealso:["subtract","partitionSelect"]},dot:{name:"dot",category:"Matrix",syntax:["dot(A, B)","A * B"],description:"Calculate the dot product of two vectors. The dot product of A = [a1, a2, a3, ..., an] and B = [b1, b2, b3, ..., bn] is defined as dot(A, B) = a1 * b1 + a2 * b2 + a3 * b3 + ... + an * bn",examples:["dot([2, 4, 1], [2, 2, 3])","[2, 4, 1] * [2, 2, 3]"],seealso:["multiply","cross"]},getMatrixDataType:{name:"getMatrixDataType",category:"Matrix",syntax:["getMatrixDataType(x)"],description:'Find the data type of all elements in a matrix or array, for example "number" if all items are a number and "Complex" if all values are complex numbers. If a matrix contains more than one data type, it will return "mixed".',examples:["getMatrixDataType([1, 2, 3])","getMatrixDataType([[5 cm], [2 inch]])",'getMatrixDataType([1, "text"])',"getMatrixDataType([1, bignumber(4)])"],seealso:["matrix","sparse","typeOf"]},identity:{name:"identity",category:"Matrix",syntax:["identity(n)","identity(m, n)","identity([m, n])"],description:"Returns the identity matrix with size m-by-n. The matrix has ones on the diagonal and zeros elsewhere.",examples:["identity(3)","identity(3, 5)","a = [1, 2, 3; 4, 5, 6]","identity(size(a))"],seealso:["concat","det","diag","inv","ones","range","size","squeeze","subset","trace","transpose","zeros"]},filter:{name:"filter",category:"Matrix",syntax:["filter(x, test)"],description:"Filter items in a matrix.",examples:["isPositive(x) = x > 0","filter([6, -2, -1, 4, 3], isPositive)","filter([6, -2, 0, 1, 0], x != 0)"],seealso:["sort","map","forEach"]},flatten:{name:"flatten",category:"Matrix",syntax:["flatten(x)"],description:"Flatten a multi dimensional matrix into a single dimensional matrix.",examples:["a = [1, 2, 3; 4, 5, 6]","size(a)","b = flatten(a)","size(b)"],seealso:["concat","resize","size","squeeze"]},forEach:{name:"forEach",category:"Matrix",syntax:["forEach(x, callback)"],description:"Iterates over all elements of a matrix/array, and executes the given callback function.",examples:["numberOfPets = {}","addPet(n) = numberOfPets[n] = (numberOfPets[n] ? numberOfPets[n]:0 ) + 1;",'forEach(["Dog","Cat","Cat"], addPet)',"numberOfPets"],seealso:["map","sort","filter"]},inv:{name:"inv",category:"Matrix",syntax:["inv(x)"],description:"Calculate the inverse of a matrix",examples:["inv([1, 2; 3, 4])","inv(4)","1 / 4"],seealso:["concat","det","diag","identity","ones","range","size","squeeze","subset","trace","transpose","zeros"]},pinv:{name:"pinv",category:"Matrix",syntax:["pinv(x)"],description:"Calculate the Moore\u2013Penrose inverse of a matrix",examples:["pinv([1, 2; 3, 4])","pinv([[1, 0], [0, 1], [0, 1]])","pinv(4)"],seealso:["inv"]},eigs:{name:"eigs",category:"Matrix",syntax:["eigs(x)"],description:"Calculate the eigenvalues and optionally eigenvectors of a square matrix",examples:["eigs([[5, 2.3], [2.3, 1]])","eigs([[1, 2, 3], [4, 5, 6], [7, 8, 9]], { precision: 1e-6, eigenvectors: false })"],seealso:["inv"]},kron:{name:"kron",category:"Matrix",syntax:["kron(x, y)"],description:"Calculates the Kronecker product of 2 matrices or vectors.",examples:["kron([[1, 0], [0, 1]], [[1, 2], [3, 4]])","kron([1,1], [2,3,4])"],seealso:["multiply","dot","cross"]},matrixFromFunction:{name:"matrixFromFunction",category:"Matrix",syntax:["matrixFromFunction(size, fn)","matrixFromFunction(size, fn, format)","matrixFromFunction(size, fn, format, datatype)","matrixFromFunction(size, format, fn)","matrixFromFunction(size, format, datatype, fn)"],description:"Create a matrix by evaluating a generating function at each index.",examples:["f(I) = I[1] - I[2]","matrixFromFunction([3,3], f)","g(I) = I[1] - I[2] == 1 ? 4 : 0",'matrixFromFunction([100, 100], "sparse", g)',"matrixFromFunction([5], random)"],seealso:["matrix","matrixFromRows","matrixFromColumns","zeros"]},matrixFromRows:{name:"matrixFromRows",category:"Matrix",syntax:["matrixFromRows(...arr)","matrixFromRows(row1, row2)","matrixFromRows(row1, row2, row3)"],description:"Create a dense matrix from vectors as individual rows.",examples:["matrixFromRows([1, 2, 3], [[4],[5],[6]])"],seealso:["matrix","matrixFromColumns","matrixFromFunction","zeros"]},matrixFromColumns:{name:"matrixFromColumns",category:"Matrix",syntax:["matrixFromColumns(...arr)","matrixFromColumns(row1, row2)","matrixFromColumns(row1, row2, row3)"],description:"Create a dense matrix from vectors as individual columns.",examples:["matrixFromColumns([1, 2, 3], [[4],[5],[6]])"],seealso:["matrix","matrixFromRows","matrixFromFunction","zeros"]},map:{name:"map",category:"Matrix",syntax:["map(x, callback)","map(x, y, ..., callback)"],description:"Create a new matrix or array with the results of the callback function executed on each entry of the matrix/array or the matrices/arrays.",examples:["map([1, 2, 3], square)","map([1, 2], [3, 4], f(a,b) = a + b)"],seealso:["filter","forEach"]},ones:{name:"ones",category:"Matrix",syntax:["ones(m)","ones(m, n)","ones(m, n, p, ...)","ones([m])","ones([m, n])","ones([m, n, p, ...])"],description:"Create a matrix containing ones.",examples:["ones(3)","ones(3, 5)","ones([2,3]) * 4.5","a = [1, 2, 3; 4, 5, 6]","ones(size(a))"],seealso:["concat","det","diag","identity","inv","range","size","squeeze","subset","trace","transpose","zeros"]},partitionSelect:{name:"partitionSelect",category:"Matrix",syntax:["partitionSelect(x, k)","partitionSelect(x, k, compare)"],description:"Partition-based selection of an array or 1D matrix. Will find the kth smallest value, and mutates the input array. Uses Quickselect.",examples:["partitionSelect([5, 10, 1], 2)",'partitionSelect(["C", "B", "A", "D"], 1, compareText)',"arr = [5, 2, 1]","partitionSelect(arr, 0) # returns 1, arr is now: [1, 2, 5]","arr","partitionSelect(arr, 1, 'desc') # returns 2, arr is now: [5, 2, 1]","arr"],seealso:["sort"]},range:{name:"range",category:"Type",syntax:["start:end","start:step:end","range(start, end)","range(start, end, step)","range(string)"],description:"Create a range. Lower bound of the range is included, upper bound is excluded.",examples:["1:5","3:-1:-3","range(3, 7)","range(0, 12, 2)",'range("4:10")',"range(1m, 1m, 3m)","a = [1, 2, 3, 4; 5, 6, 7, 8]","a[1:2, 1:2]"],seealso:["concat","det","diag","identity","inv","ones","size","squeeze","subset","trace","transpose","zeros"]},resize:{name:"resize",category:"Matrix",syntax:["resize(x, size)","resize(x, size, defaultValue)"],description:"Resize a matrix.",examples:["resize([1,2,3,4,5], [3])","resize([1,2,3], [5])","resize([1,2,3], [5], -1)","resize(2, [2, 3])",'resize("hello", [8], "!")'],seealso:["size","subset","squeeze","reshape"]},reshape:{name:"reshape",category:"Matrix",syntax:["reshape(x, sizes)"],description:"Reshape a multi dimensional array to fit the specified dimensions.",examples:["reshape([1, 2, 3, 4, 5, 6], [2, 3])","reshape([[1, 2], [3, 4]], [1, 4])","reshape([[1, 2], [3, 4]], [4])","reshape([1, 2, 3, 4], [-1, 2])"],seealso:["size","squeeze","resize"]},rotate:{name:"rotate",category:"Matrix",syntax:["rotate(w, theta)","rotate(w, theta, v)"],description:"Returns a 2-D rotation matrix (2x2) for a given angle (in radians). Returns a 2-D rotation matrix (3x3) of a given angle (in radians) around given axis.",examples:["rotate([1, 0], pi / 2)",'rotate(matrix([1, 0]), unit("35deg"))','rotate([1, 0, 0], unit("90deg"), [0, 0, 1])','rotate(matrix([1, 0, 0]), unit("90deg"), matrix([0, 0, 1]))'],seealso:["matrix","rotationMatrix"]},rotationMatrix:{name:"rotationMatrix",category:"Matrix",syntax:["rotationMatrix(theta)","rotationMatrix(theta, v)","rotationMatrix(theta, v, format)"],description:"Returns a 2-D rotation matrix (2x2) for a given angle (in radians). Returns a 2-D rotation matrix (3x3) of a given angle (in radians) around given axis.",examples:["rotationMatrix(pi / 2)",'rotationMatrix(unit("45deg"), [0, 0, 1])','rotationMatrix(1, matrix([0, 0, 1]), "sparse")'],seealso:["cos","sin"]},row:{name:"row",category:"Matrix",syntax:["row(x, index)"],description:"Return a row from a matrix or array.",examples:["A = [[1, 2], [3, 4]]","row(A, 1)","row(A, 2)"],seealso:["column","matrixFromRows"]},size:{name:"size",category:"Matrix",syntax:["size(x)"],description:"Calculate the size of a matrix.",examples:["size(2.3)",'size("hello world")',"a = [1, 2; 3, 4; 5, 6]","size(a)","size(1:6)"],seealso:["concat","count","det","diag","identity","inv","ones","range","squeeze","subset","trace","transpose","zeros"]},sort:{name:"sort",category:"Matrix",syntax:["sort(x)","sort(x, compare)"],description:'Sort the items in a matrix. Compare can be a string "asc", "desc", "natural", or a custom sort function.',examples:["sort([5, 10, 1])",'sort(["C", "B", "A", "D"], "natural")',"sortByLength(a, b) = size(a)[1] - size(b)[1]",'sort(["Langdon", "Tom", "Sara"], sortByLength)','sort(["10", "1", "2"], "natural")'],seealso:["map","filter","forEach"]},squeeze:{name:"squeeze",category:"Matrix",syntax:["squeeze(x)"],description:"Remove inner and outer singleton dimensions from a matrix.",examples:["a = zeros(3,2,1)","size(squeeze(a))","b = zeros(1,1,3)","size(squeeze(b))"],seealso:["concat","det","diag","identity","inv","ones","range","size","subset","trace","transpose","zeros"]},subset:{name:"subset",category:"Matrix",syntax:["value(index)","value(index) = replacement","subset(value, [index])","subset(value, [index], replacement)"],description:"Get or set a subset of the entries of a matrix or characters of a string. Indexes are one-based. There should be one index specification for each dimension of the target. Each specification can be a single index, a list of indices, or a range in colon notation `l:u`. In a range, both the lower bound l and upper bound u are included; and if a bound is omitted it defaults to the most extreme valid value. The cartesian product of the indices specified in each dimension determines the target of the operation.",examples:["d = [1, 2; 3, 4]","e = []","e[1, 1:2] = [5, 6]","e[2, :] = [7, 8]","f = d * e","f[2, 1]","f[:, 1]","f[[1,2], [1,3]] = [9, 10; 11, 12]","f"],seealso:["concat","det","diag","identity","inv","ones","range","size","squeeze","trace","transpose","zeros"]},trace:{name:"trace",category:"Matrix",syntax:["trace(A)"],description:"Calculate the trace of a matrix: the sum of the elements on the main diagonal of a square matrix.",examples:["A = [1, 2, 3; -1, 2, 3; 2, 0, 3]","trace(A)"],seealso:["concat","det","diag","identity","inv","ones","range","size","squeeze","subset","transpose","zeros"]},transpose:{name:"transpose",category:"Matrix",syntax:["x'","transpose(x)"],description:"Transpose a matrix",examples:["a = [1, 2, 3; 4, 5, 6]","a'","transpose(a)"],seealso:["concat","det","diag","identity","inv","ones","range","size","squeeze","subset","trace","zeros"]},zeros:{name:"zeros",category:"Matrix",syntax:["zeros(m)","zeros(m, n)","zeros(m, n, p, ...)","zeros([m])","zeros([m, n])","zeros([m, n, p, ...])"],description:"Create a matrix containing zeros.",examples:["zeros(3)","zeros(3, 5)","a = [1, 2, 3; 4, 5, 6]","zeros(size(a))"],seealso:["concat","det","diag","identity","inv","ones","range","size","squeeze","subset","trace","transpose"]},fft:{name:"fft",category:"Matrix",syntax:["fft(x)"],description:"Calculate N-dimensional Fourier transform",examples:["fft([[1, 0], [1, 0]])"],seealso:["ifft"]},ifft:{name:"ifft",category:"Matrix",syntax:["ifft(x)"],description:"Calculate N-dimensional inverse Fourier transform",examples:["ifft([[2, 2], [0, 0]])"],seealso:["fft"]},sylvester:{name:"sylvester",category:"Algebra",syntax:["sylvester(A,B,C)"],description:"Solves the real-valued Sylvester equation AX+XB=C for X",examples:["sylvester([[-1, -2], [1, 1]], [[-2, 1], [-1, 2]], [[-3, 2], [3, 0]])","A = [[-1, -2], [1, 1]]; B = [[2, -1], [1, -2]]; C = [[-3, 2], [3, 0]]","sylvester(A, B, C)"],seealso:["schur","lyap"]},schur:{name:"schur",category:"Algebra",syntax:["schur(A)"],description:"Performs a real Schur decomposition of the real matrix A = UTU'",examples:["schur([[1, 0], [-4, 3]])","A = [[1, 0], [-4, 3]]","schur(A)"],seealso:["lyap","sylvester"]},lyap:{name:"lyap",category:"Algebra",syntax:["lyap(A,Q)"],description:"Solves the Continuous-time Lyapunov equation AP+PA'+Q=0 for P",examples:["lyap([[-2, 0], [1, -4]], [[3, 1], [1, 3]])","A = [[-2, 0], [1, -4]]","Q = [[3, 1], [1, 3]]","lyap(A,Q)"],seealso:["schur","sylvester"]},solveODE:{name:"solveODE",category:"Numeric",syntax:["solveODE(func, tspan, y0)","solveODE(func, tspan, y0, options)"],description:"Numerical Integration of Ordinary Differential Equations.",examples:["f(t,y) = y","tspan = [0, 4]","solveODE(f, tspan, 1)","solveODE(f, tspan, [1, 2])",'solveODE(f, tspan, 1, { method:"RK23", maxStep:0.1 })'],seealso:["derivative","simplifyCore"]},combinations:{name:"combinations",category:"Probability",syntax:["combinations(n, k)"],description:"Compute the number of combinations of n items taken k at a time",examples:["combinations(7, 5)"],seealso:["combinationsWithRep","permutations","factorial"]},combinationsWithRep:{name:"combinationsWithRep",category:"Probability",syntax:["combinationsWithRep(n, k)"],description:"Compute the number of combinations of n items taken k at a time with replacements.",examples:["combinationsWithRep(7, 5)"],seealso:["combinations","permutations","factorial"]},factorial:{name:"factorial",category:"Probability",syntax:["n!","factorial(n)"],description:"Compute the factorial of a value",examples:["5!","5 * 4 * 3 * 2 * 1","3!"],seealso:["combinations","combinationsWithRep","permutations","gamma"]},gamma:{name:"gamma",category:"Probability",syntax:["gamma(n)"],description:"Compute the gamma function. For small values, the Lanczos approximation is used, and for large values the extended Stirling approximation.",examples:["gamma(4)","3!","gamma(1/2)","sqrt(pi)"],seealso:["factorial"]},kldivergence:{name:"kldivergence",category:"Probability",syntax:["kldivergence(x, y)"],description:"Calculate the Kullback-Leibler (KL) divergence between two distributions.",examples:["kldivergence([0.7,0.5,0.4], [0.2,0.9,0.5])"],seealso:[]},lgamma:{name:"lgamma",category:"Probability",syntax:["lgamma(n)"],description:"Logarithm of the gamma function for real, positive numbers and complex numbers, using Lanczos approximation for numbers and Stirling series for complex numbers.",examples:["lgamma(4)","lgamma(1/2)","lgamma(i)","lgamma(complex(1.1, 2))"],seealso:["gamma"]},multinomial:{name:"multinomial",category:"Probability",syntax:["multinomial(A)"],description:"Multinomial Coefficients compute the number of ways of picking a1, a2, ..., ai unordered outcomes from `n` possibilities. multinomial takes one array of integers as an argument. The following condition must be enforced: every ai > 0.",examples:["multinomial([1, 2, 1])"],seealso:["combinations","factorial"]},permutations:{name:"permutations",category:"Probability",syntax:["permutations(n)","permutations(n, k)"],description:"Compute the number of permutations of n items taken k at a time",examples:["permutations(5)","permutations(5, 3)"],seealso:["combinations","combinationsWithRep","factorial"]},pickRandom:{name:"pickRandom",category:"Probability",syntax:["pickRandom(array)","pickRandom(array, number)","pickRandom(array, weights)","pickRandom(array, number, weights)","pickRandom(array, weights, number)"],description:"Pick a random entry from a given array.",examples:["pickRandom(0:10)","pickRandom([1, 3, 1, 6])","pickRandom([1, 3, 1, 6], 2)","pickRandom([1, 3, 1, 6], [2, 3, 2, 1])","pickRandom([1, 3, 1, 6], 2, [2, 3, 2, 1])","pickRandom([1, 3, 1, 6], [2, 3, 2, 1], 2)"],seealso:["random","randomInt"]},random:{name:"random",category:"Probability",syntax:["random()","random(max)","random(min, max)","random(size)","random(size, max)","random(size, min, max)"],description:"Return a random number.",examples:["random()","random(10, 20)","random([2, 3])"],seealso:["pickRandom","randomInt"]},randomInt:{name:"randomInt",category:"Probability",syntax:["randomInt(max)","randomInt(min, max)","randomInt(size)","randomInt(size, max)","randomInt(size, min, max)"],description:"Return a random integer number",examples:["randomInt(10, 20)","randomInt([2, 3], 10)"],seealso:["pickRandom","random"]},compare:{name:"compare",category:"Relational",syntax:["compare(x, y)"],description:"Compare two values. Returns 1 when x > y, -1 when x < y, and 0 when x == y.",examples:["compare(2, 3)","compare(3, 2)","compare(2, 2)","compare(5cm, 40mm)","compare(2, [1, 2, 3])"],seealso:["equal","unequal","smaller","smallerEq","largerEq","compareNatural","compareText"]},compareNatural:{name:"compareNatural",category:"Relational",syntax:["compareNatural(x, y)"],description:"Compare two values of any type in a deterministic, natural way. Returns 1 when x > y, -1 when x < y, and 0 when x == y.",examples:["compareNatural(2, 3)","compareNatural(3, 2)","compareNatural(2, 2)","compareNatural(5cm, 40mm)",'compareNatural("2", "10")',"compareNatural(2 + 3i, 2 + 4i)","compareNatural([1, 2, 4], [1, 2, 3])","compareNatural([1, 5], [1, 2, 3])","compareNatural([1, 2], [1, 2])","compareNatural({a: 2}, {a: 4})"],seealso:["equal","unequal","smaller","smallerEq","largerEq","compare","compareText"]},compareText:{name:"compareText",category:"Relational",syntax:["compareText(x, y)"],description:"Compare two strings lexically. Comparison is case sensitive. Returns 1 when x > y, -1 when x < y, and 0 when x == y.",examples:['compareText("B", "A")','compareText("A", "B")','compareText("A", "A")','compareText("2", "10")','compare("2", "10")',"compare(2, 10)",'compareNatural("2", "10")','compareText("B", ["A", "B", "C"])'],seealso:["compare","compareNatural"]},deepEqual:{name:"deepEqual",category:"Relational",syntax:["deepEqual(x, y)"],description:"Check equality of two matrices element wise. Returns true if the size of both matrices is equal and when and each of the elements are equal.",examples:["deepEqual([1,3,4], [1,3,4])","deepEqual([1,3,4], [1,3])"],seealso:["equal","unequal","smaller","larger","smallerEq","largerEq","compare"]},equal:{name:"equal",category:"Relational",syntax:["x == y","equal(x, y)"],description:"Check equality of two values. Returns true if the values are equal, and false if not.",examples:["2+2 == 3","2+2 == 4","a = 3.2","b = 6-2.8","a == b","50cm == 0.5m"],seealso:["unequal","smaller","larger","smallerEq","largerEq","compare","deepEqual","equalText"]},equalText:{name:"equalText",category:"Relational",syntax:["equalText(x, y)"],description:"Check equality of two strings. Comparison is case sensitive. Returns true if the values are equal, and false if not.",examples:['equalText("Hello", "Hello")','equalText("a", "A")','equal("2e3", "2000")','equalText("2e3", "2000")','equalText("B", ["A", "B", "C"])'],seealso:["compare","compareNatural","compareText","equal"]},larger:{name:"larger",category:"Relational",syntax:["x > y","larger(x, y)"],description:"Check if value x is larger than y. Returns true if x is larger than y, and false if not.",examples:["2 > 3","5 > 2*2","a = 3.3","b = 6-2.8","(a > b)","(b < a)","5 cm > 2 inch"],seealso:["equal","unequal","smaller","smallerEq","largerEq","compare"]},largerEq:{name:"largerEq",category:"Relational",syntax:["x >= y","largerEq(x, y)"],description:"Check if value x is larger or equal to y. Returns true if x is larger or equal to y, and false if not.",examples:["2 >= 1+1","2 > 1+1","a = 3.2","b = 6-2.8","(a >= b)"],seealso:["equal","unequal","smallerEq","smaller","compare"]},smaller:{name:"smaller",category:"Relational",syntax:["x < y","smaller(x, y)"],description:"Check if value x is smaller than value y. Returns true if x is smaller than y, and false if not.",examples:["2 < 3","5 < 2*2","a = 3.3","b = 6-2.8","(a < b)","5 cm < 2 inch"],seealso:["equal","unequal","larger","smallerEq","largerEq","compare"]},smallerEq:{name:"smallerEq",category:"Relational",syntax:["x <= y","smallerEq(x, y)"],description:"Check if value x is smaller or equal to value y. Returns true if x is smaller than y, and false if not.",examples:["2 <= 1+1","2 < 1+1","a = 3.2","b = 6-2.8","(a <= b)"],seealso:["equal","unequal","larger","smaller","largerEq","compare"]},unequal:{name:"unequal",category:"Relational",syntax:["x != y","unequal(x, y)"],description:"Check unequality of two values. Returns true if the values are unequal, and false if they are equal.",examples:["2+2 != 3","2+2 != 4","a = 3.2","b = 6-2.8","a != b","50cm != 0.5m","5 cm != 2 inch"],seealso:["equal","smaller","larger","smallerEq","largerEq","compare","deepEqual"]},setCartesian:{name:"setCartesian",category:"Set",syntax:["setCartesian(set1, set2)"],description:"Create the cartesian product of two (multi)sets. Multi-dimension arrays will be converted to single-dimension arrays and the values will be sorted in ascending order before the operation.",examples:["setCartesian([1, 2], [3, 4])"],seealso:["setUnion","setIntersect","setDifference","setPowerset"]},setDifference:{name:"setDifference",category:"Set",syntax:["setDifference(set1, set2)"],description:"Create the difference of two (multi)sets: every element of set1, that is not the element of set2. Multi-dimension arrays will be converted to single-dimension arrays before the operation.",examples:["setDifference([1, 2, 3, 4], [3, 4, 5, 6])","setDifference([[1, 2], [3, 4]], [[3, 4], [5, 6]])"],seealso:["setUnion","setIntersect","setSymDifference"]},setDistinct:{name:"setDistinct",category:"Set",syntax:["setDistinct(set)"],description:"Collect the distinct elements of a multiset. A multi-dimension array will be converted to a single-dimension array before the operation.",examples:["setDistinct([1, 1, 1, 2, 2, 3])"],seealso:["setMultiplicity"]},setIntersect:{name:"setIntersect",category:"Set",syntax:["setIntersect(set1, set2)"],description:"Create the intersection of two (multi)sets. Multi-dimension arrays will be converted to single-dimension arrays before the operation.",examples:["setIntersect([1, 2, 3, 4], [3, 4, 5, 6])","setIntersect([[1, 2], [3, 4]], [[3, 4], [5, 6]])"],seealso:["setUnion","setDifference"]},setIsSubset:{name:"setIsSubset",category:"Set",syntax:["setIsSubset(set1, set2)"],description:"Check whether a (multi)set is a subset of another (multi)set: every element of set1 is the element of set2. Multi-dimension arrays will be converted to single-dimension arrays before the operation.",examples:["setIsSubset([1, 2], [3, 4, 5, 6])","setIsSubset([3, 4], [3, 4, 5, 6])"],seealso:["setUnion","setIntersect","setDifference"]},setMultiplicity:{name:"setMultiplicity",category:"Set",syntax:["setMultiplicity(element, set)"],description:"Count the multiplicity of an element in a multiset. A multi-dimension array will be converted to a single-dimension array before the operation.",examples:["setMultiplicity(1, [1, 2, 2, 4])","setMultiplicity(2, [1, 2, 2, 4])"],seealso:["setDistinct","setSize"]},setPowerset:{name:"setPowerset",category:"Set",syntax:["setPowerset(set)"],description:"Create the powerset of a (multi)set: the powerset contains very possible subsets of a (multi)set. A multi-dimension array will be converted to a single-dimension array before the operation.",examples:["setPowerset([1, 2, 3])"],seealso:["setCartesian"]},setSize:{name:"setSize",category:"Set",syntax:["setSize(set)","setSize(set, unique)"],description:'Count the number of elements of a (multi)set. When the second parameter "unique" is true, count only the unique values. A multi-dimension array will be converted to a single-dimension array before the operation.',examples:["setSize([1, 2, 2, 4])","setSize([1, 2, 2, 4], true)"],seealso:["setUnion","setIntersect","setDifference"]},setSymDifference:{name:"setSymDifference",category:"Set",syntax:["setSymDifference(set1, set2)"],description:"Create the symmetric difference of two (multi)sets. Multi-dimension arrays will be converted to single-dimension arrays before the operation.",examples:["setSymDifference([1, 2, 3, 4], [3, 4, 5, 6])","setSymDifference([[1, 2], [3, 4]], [[3, 4], [5, 6]])"],seealso:["setUnion","setIntersect","setDifference"]},setUnion:{name:"setUnion",category:"Set",syntax:["setUnion(set1, set2)"],description:"Create the union of two (multi)sets. Multi-dimension arrays will be converted to single-dimension arrays before the operation.",examples:["setUnion([1, 2, 3, 4], [3, 4, 5, 6])","setUnion([[1, 2], [3, 4]], [[3, 4], [5, 6]])"],seealso:["setIntersect","setDifference"]},zpk2tf:{name:"zpk2tf",category:"Signal",syntax:["zpk2tf(z, p, k)"],description:"Compute the transfer function of a zero-pole-gain model.",examples:["zpk2tf([1, 2], [-1, -2], 1)","zpk2tf([1, 2], [-1, -2])","zpk2tf([1 - 3i, 2 + 2i], [-1, -2])"],seealso:[]},freqz:{name:"freqz",category:"Signal",syntax:["freqz(b, a)","freqz(b, a, w)"],description:"Calculates the frequency response of a filter given its numerator and denominator coefficients.",examples:["freqz([1, 2], [1, 2, 3])","freqz([1, 2], [1, 2, 3], [0, 1])","freqz([1, 2], [1, 2, 3], 512)"],seealso:[]},erf:{name:"erf",category:"Special",syntax:["erf(x)"],description:"Compute the erf function of a value using a rational Chebyshev approximations for different intervals of x",examples:["erf(0.2)","erf(-0.5)","erf(4)"],seealso:[]},zeta:{name:"zeta",category:"Special",syntax:["zeta(s)"],description:"Compute the Riemann Zeta Function using an infinite series and Riemann's Functional Equation for the entire complex plane",examples:["zeta(0.2)","zeta(-0.5)","zeta(4)"],seealso:[]},cumsum:{name:"cumsum",category:"Statistics",syntax:["cumsum(a, b, c, ...)","cumsum(A)"],description:"Compute the cumulative sum of all values.",examples:["cumsum(2, 3, 4, 1)","cumsum([2, 3, 4, 1])","cumsum([1, 2; 3, 4])","cumsum([1, 2; 3, 4], 1)","cumsum([1, 2; 3, 4], 2)"],seealso:["max","mean","median","min","prod","std","sum","variance"]},mad:{name:"mad",category:"Statistics",syntax:["mad(a, b, c, ...)","mad(A)"],description:"Compute the median absolute deviation of a matrix or a list with values. The median absolute deviation is defined as the median of the absolute deviations from the median.",examples:["mad(10, 20, 30)","mad([1, 2, 3])"],seealso:["mean","median","std","abs"]},max:{name:"max",category:"Statistics",syntax:["max(a, b, c, ...)","max(A)","max(A, dimension)"],description:"Compute the maximum value of a list of values.",examples:["max(2, 3, 4, 1)","max([2, 3, 4, 1])","max([2, 5; 4, 3])","max([2, 5; 4, 3], 1)","max([2, 5; 4, 3], 2)","max(2.7, 7.1, -4.5, 2.0, 4.1)","min(2.7, 7.1, -4.5, 2.0, 4.1)"],seealso:["mean","median","min","prod","std","sum","variance"]},mean:{name:"mean",category:"Statistics",syntax:["mean(a, b, c, ...)","mean(A)","mean(A, dimension)"],description:"Compute the arithmetic mean of a list of values.",examples:["mean(2, 3, 4, 1)","mean([2, 3, 4, 1])","mean([2, 5; 4, 3])","mean([2, 5; 4, 3], 1)","mean([2, 5; 4, 3], 2)","mean([1.0, 2.7, 3.2, 4.0])"],seealso:["max","median","min","prod","std","sum","variance"]},median:{name:"median",category:"Statistics",syntax:["median(a, b, c, ...)","median(A)"],description:"Compute the median of all values. The values are sorted and the middle value is returned. In case of an even number of values, the average of the two middle values is returned.",examples:["median(5, 2, 7)","median([3, -1, 5, 7])"],seealso:["max","mean","min","prod","std","sum","variance","quantileSeq"]},min:{name:"min",category:"Statistics",syntax:["min(a, b, c, ...)","min(A)","min(A, dimension)"],description:"Compute the minimum value of a list of values.",examples:["min(2, 3, 4, 1)","min([2, 3, 4, 1])","min([2, 5; 4, 3])","min([2, 5; 4, 3], 1)","min([2, 5; 4, 3], 2)","min(2.7, 7.1, -4.5, 2.0, 4.1)","max(2.7, 7.1, -4.5, 2.0, 4.1)"],seealso:["max","mean","median","prod","std","sum","variance"]},mode:{name:"mode",category:"Statistics",syntax:["mode(a, b, c, ...)","mode(A)","mode(A, a, b, B, c, ...)"],description:"Computes the mode of all values as an array. In case mode being more than one, multiple values are returned in an array.",examples:["mode(2, 1, 4, 3, 1)","mode([1, 2.7, 3.2, 4, 2.7])","mode(1, 4, 6, 1, 6)"],seealso:["max","mean","min","median","prod","std","sum","variance"]},prod:{name:"prod",category:"Statistics",syntax:["prod(a, b, c, ...)","prod(A)"],description:"Compute the product of all values.",examples:["prod(2, 3, 4)","prod([2, 3, 4])","prod([2, 5; 4, 3])"],seealso:["max","mean","min","median","min","std","sum","variance"]},quantileSeq:{name:"quantileSeq",category:"Statistics",syntax:["quantileSeq(A, prob[, sorted])","quantileSeq(A, [prob1, prob2, ...][, sorted])","quantileSeq(A, N[, sorted])"],description:"Compute the prob order quantile of a matrix or a list with values. The sequence is sorted and the middle value is returned. Supported types of sequence values are: Number, BigNumber, Unit Supported types of probability are: Number, BigNumber. \n\nIn case of a (multi dimensional) array or matrix, the prob order quantile of all elements will be calculated.",examples:["quantileSeq([3, -1, 5, 7], 0.5)","quantileSeq([3, -1, 5, 7], [1/3, 2/3])","quantileSeq([3, -1, 5, 7], 2)","quantileSeq([-1, 3, 5, 7], 0.5, true)"],seealso:["mean","median","min","max","prod","std","sum","variance"]},std:{name:"std",category:"Statistics",syntax:["std(a, b, c, ...)","std(A)","std(A, dimension)","std(A, normalization)","std(A, dimension, normalization)"],description:'Compute the standard deviation of all values, defined as std(A) = sqrt(variance(A)). Optional parameter normalization can be "unbiased" (default), "uncorrected", or "biased".',examples:["std(2, 4, 6)","std([2, 4, 6, 8])",'std([2, 4, 6, 8], "uncorrected")','std([2, 4, 6, 8], "biased")',"std([1, 2, 3; 4, 5, 6])"],seealso:["max","mean","min","median","prod","sum","variance"]},sum:{name:"sum",category:"Statistics",syntax:["sum(a, b, c, ...)","sum(A)","sum(A, dimension)"],description:"Compute the sum of all values.",examples:["sum(2, 3, 4, 1)","sum([2, 3, 4, 1])","sum([2, 5; 4, 3])"],seealso:["max","mean","median","min","prod","std","sum","variance"]},variance:{name:"variance",category:"Statistics",syntax:["variance(a, b, c, ...)","variance(A)","variance(A, dimension)","variance(A, normalization)","variance(A, dimension, normalization)"],description:'Compute the variance of all values. Optional parameter normalization can be "unbiased" (default), "uncorrected", or "biased".',examples:["variance(2, 4, 6)","variance([2, 4, 6, 8])",'variance([2, 4, 6, 8], "uncorrected")','variance([2, 4, 6, 8], "biased")',"variance([1, 2, 3; 4, 5, 6])"],seealso:["max","mean","min","median","min","prod","std","sum"]},corr:{name:"corr",category:"Statistics",syntax:["corr(A,B)"],description:"Compute the correlation coefficient of a two list with values, For matrices, the matrix correlation coefficient is calculated.",examples:["corr([2, 4, 6, 8],[1, 2, 3, 6])","corr(matrix([[1, 2.2, 3, 4.8, 5], [1, 2, 3, 4, 5]]), matrix([[4, 5.3, 6.6, 7, 8], [1, 2, 3, 4, 5]]))"],seealso:["max","mean","min","median","min","prod","std","sum"]},acos:{name:"acos",category:"Trigonometry",syntax:["acos(x)"],description:"Compute the inverse cosine of a value in radians.",examples:["acos(0.5)","acos(cos(2.3))"],seealso:["cos","atan","asin"]},acosh:{name:"acosh",category:"Trigonometry",syntax:["acosh(x)"],description:"Calculate the hyperbolic arccos of a value, defined as `acosh(x) = ln(sqrt(x^2 - 1) + x)`.",examples:["acosh(1.5)"],seealso:["cosh","asinh","atanh"]},acot:{name:"acot",category:"Trigonometry",syntax:["acot(x)"],description:"Calculate the inverse cotangent of a value.",examples:["acot(0.5)","acot(cot(0.5))","acot(2)"],seealso:["cot","atan"]},acoth:{name:"acoth",category:"Trigonometry",syntax:["acoth(x)"],description:"Calculate the inverse hyperbolic tangent of a value, defined as `acoth(x) = (ln((x+1)/x) + ln(x/(x-1))) / 2`.",examples:["acoth(2)","acoth(0.5)"],seealso:["acsch","asech"]},acsc:{name:"acsc",category:"Trigonometry",syntax:["acsc(x)"],description:"Calculate the inverse cotangent of a value.",examples:["acsc(2)","acsc(csc(0.5))","acsc(0.5)"],seealso:["csc","asin","asec"]},acsch:{name:"acsch",category:"Trigonometry",syntax:["acsch(x)"],description:"Calculate the inverse hyperbolic cosecant of a value, defined as `acsch(x) = ln(1/x + sqrt(1/x^2 + 1))`.",examples:["acsch(0.5)"],seealso:["asech","acoth"]},asec:{name:"asec",category:"Trigonometry",syntax:["asec(x)"],description:"Calculate the inverse secant of a value.",examples:["asec(0.5)","asec(sec(0.5))","asec(2)"],seealso:["acos","acot","acsc"]},asech:{name:"asech",category:"Trigonometry",syntax:["asech(x)"],description:"Calculate the inverse secant of a value.",examples:["asech(0.5)"],seealso:["acsch","acoth"]},asin:{name:"asin",category:"Trigonometry",syntax:["asin(x)"],description:"Compute the inverse sine of a value in radians.",examples:["asin(0.5)","asin(sin(0.5))"],seealso:["sin","acos","atan"]},asinh:{name:"asinh",category:"Trigonometry",syntax:["asinh(x)"],description:"Calculate the hyperbolic arcsine of a value, defined as `asinh(x) = ln(x + sqrt(x^2 + 1))`.",examples:["asinh(0.5)"],seealso:["acosh","atanh"]},atan:{name:"atan",category:"Trigonometry",syntax:["atan(x)"],description:"Compute the inverse tangent of a value in radians.",examples:["atan(0.5)","atan(tan(0.5))"],seealso:["tan","acos","asin"]},atanh:{name:"atanh",category:"Trigonometry",syntax:["atanh(x)"],description:"Calculate the hyperbolic arctangent of a value, defined as `atanh(x) = ln((1 + x)/(1 - x)) / 2`.",examples:["atanh(0.5)"],seealso:["acosh","asinh"]},atan2:{name:"atan2",category:"Trigonometry",syntax:["atan2(y, x)"],description:"Computes the principal value of the arc tangent of y/x in radians.",examples:["atan2(2, 2) / pi","angle = 60 deg in rad","x = cos(angle)","y = sin(angle)","atan2(y, x)"],seealso:["sin","cos","tan"]},cos:{name:"cos",category:"Trigonometry",syntax:["cos(x)"],description:"Compute the cosine of x in radians.",examples:["cos(2)","cos(pi / 4) ^ 2","cos(180 deg)","cos(60 deg)","sin(0.2)^2 + cos(0.2)^2"],seealso:["acos","sin","tan"]},cosh:{name:"cosh",category:"Trigonometry",syntax:["cosh(x)"],description:"Compute the hyperbolic cosine of x in radians.",examples:["cosh(0.5)"],seealso:["sinh","tanh","coth"]},cot:{name:"cot",category:"Trigonometry",syntax:["cot(x)"],description:"Compute the cotangent of x in radians. Defined as 1/tan(x)",examples:["cot(2)","1 / tan(2)"],seealso:["sec","csc","tan"]},coth:{name:"coth",category:"Trigonometry",syntax:["coth(x)"],description:"Compute the hyperbolic cotangent of x in radians.",examples:["coth(2)","1 / tanh(2)"],seealso:["sech","csch","tanh"]},csc:{name:"csc",category:"Trigonometry",syntax:["csc(x)"],description:"Compute the cosecant of x in radians. Defined as 1/sin(x)",examples:["csc(2)","1 / sin(2)"],seealso:["sec","cot","sin"]},csch:{name:"csch",category:"Trigonometry",syntax:["csch(x)"],description:"Compute the hyperbolic cosecant of x in radians. Defined as 1/sinh(x)",examples:["csch(2)","1 / sinh(2)"],seealso:["sech","coth","sinh"]},sec:{name:"sec",category:"Trigonometry",syntax:["sec(x)"],description:"Compute the secant of x in radians. Defined as 1/cos(x)",examples:["sec(2)","1 / cos(2)"],seealso:["cot","csc","cos"]},sech:{name:"sech",category:"Trigonometry",syntax:["sech(x)"],description:"Compute the hyperbolic secant of x in radians. Defined as 1/cosh(x)",examples:["sech(2)","1 / cosh(2)"],seealso:["coth","csch","cosh"]},sin:{name:"sin",category:"Trigonometry",syntax:["sin(x)"],description:"Compute the sine of x in radians.",examples:["sin(2)","sin(pi / 4) ^ 2","sin(90 deg)","sin(30 deg)","sin(0.2)^2 + cos(0.2)^2"],seealso:["asin","cos","tan"]},sinh:{name:"sinh",category:"Trigonometry",syntax:["sinh(x)"],description:"Compute the hyperbolic sine of x in radians.",examples:["sinh(0.5)"],seealso:["cosh","tanh"]},tan:{name:"tan",category:"Trigonometry",syntax:["tan(x)"],description:"Compute the tangent of x in radians.",examples:["tan(0.5)","sin(0.5) / cos(0.5)","tan(pi / 4)","tan(45 deg)"],seealso:["atan","sin","cos"]},tanh:{name:"tanh",category:"Trigonometry",syntax:["tanh(x)"],description:"Compute the hyperbolic tangent of x in radians.",examples:["tanh(0.5)","sinh(0.5) / cosh(0.5)"],seealso:["sinh","cosh"]},to:{name:"to",category:"Units",syntax:["x to unit","to(x, unit)"],description:"Change the unit of a value.",examples:["5 inch to cm","3.2kg to g","16 bytes in bits"],seealso:[]},clone:{name:"clone",category:"Utils",syntax:["clone(x)"],description:"Clone a variable. Creates a copy of primitive variables, and a deep copy of matrices",examples:["clone(3.5)","clone(2 - 4i)","clone(45 deg)","clone([1, 2; 3, 4])",'clone("hello world")'],seealso:[]},format:{name:"format",category:"Utils",syntax:["format(value)","format(value, precision)"],description:"Format a value of any type as string.",examples:["format(2.3)","format(3 - 4i)","format([])","format(pi, 3)"],seealso:["print"]},bin:{name:"bin",category:"Utils",syntax:["bin(value)"],description:"Format a number as binary",examples:["bin(2)"],seealso:["oct","hex"]},oct:{name:"oct",category:"Utils",syntax:["oct(value)"],description:"Format a number as octal",examples:["oct(56)"],seealso:["bin","hex"]},hex:{name:"hex",category:"Utils",syntax:["hex(value)"],description:"Format a number as hexadecimal",examples:["hex(240)"],seealso:["bin","oct"]},isNaN:{name:"isNaN",category:"Utils",syntax:["isNaN(x)"],description:"Test whether a value is NaN (not a number)",examples:["isNaN(2)","isNaN(0 / 0)","isNaN(NaN)","isNaN(Infinity)"],seealso:["isNegative","isNumeric","isPositive","isZero"]},isInteger:{name:"isInteger",category:"Utils",syntax:["isInteger(x)"],description:"Test whether a value is an integer number.",examples:["isInteger(2)","isInteger(3.5)","isInteger([3, 0.5, -2])"],seealso:["isNegative","isNumeric","isPositive","isZero"]},isNegative:{name:"isNegative",category:"Utils",syntax:["isNegative(x)"],description:"Test whether a value is negative: smaller than zero.",examples:["isNegative(2)","isNegative(0)","isNegative(-4)","isNegative([3, 0.5, -2])"],seealso:["isInteger","isNumeric","isPositive","isZero"]},isNumeric:{name:"isNumeric",category:"Utils",syntax:["isNumeric(x)"],description:"Test whether a value is a numeric value. Returns true when the input is a number, BigNumber, Fraction, or boolean.",examples:["isNumeric(2)",'isNumeric("2")','hasNumericValue("2")',"isNumeric(0)","isNumeric(bignumber(500))","isNumeric(fraction(0.125))","isNumeric(2 + 3i)",'isNumeric([2.3, "foo", false])'],seealso:["isInteger","isZero","isNegative","isPositive","isNaN","hasNumericValue"]},hasNumericValue:{name:"hasNumericValue",category:"Utils",syntax:["hasNumericValue(x)"],description:"Test whether a value is an numeric value. In case of a string, true is returned if the string contains a numeric value.",examples:["hasNumericValue(2)",'hasNumericValue("2")','isNumeric("2")',"hasNumericValue(0)","hasNumericValue(bignumber(500))","hasNumericValue(fraction(0.125))","hasNumericValue(2 + 3i)",'hasNumericValue([2.3, "foo", false])'],seealso:["isInteger","isZero","isNegative","isPositive","isNaN","isNumeric"]},isPositive:{name:"isPositive",category:"Utils",syntax:["isPositive(x)"],description:"Test whether a value is positive: larger than zero.",examples:["isPositive(2)","isPositive(0)","isPositive(-4)","isPositive([3, 0.5, -2])"],seealso:["isInteger","isNumeric","isNegative","isZero"]},isPrime:{name:"isPrime",category:"Utils",syntax:["isPrime(x)"],description:"Test whether a value is prime: has no divisors other than itself and one.",examples:["isPrime(3)","isPrime(-2)","isPrime([2, 17, 100])"],seealso:["isInteger","isNumeric","isNegative","isZero"]},isZero:{name:"isZero",category:"Utils",syntax:["isZero(x)"],description:"Test whether a value is zero.",examples:["isZero(2)","isZero(0)","isZero(-4)","isZero([3, 0, -2, 0])"],seealso:["isInteger","isNumeric","isNegative","isPositive"]},print:{name:"print",category:"Utils",syntax:["print(template, values)","print(template, values, precision)"],description:"Interpolate values into a string template.",examples:['print("Lucy is $age years old", {age: 5})','print("The value of pi is $pi", {pi: pi}, 3)','print("Hello, $user.name!", {user: {name: "John"}})','print("Values: $1, $2, $3", [6, 9, 4])'],seealso:["format"]},typeOf:{name:"typeOf",category:"Utils",syntax:["typeOf(x)"],description:"Get the type of a variable.",examples:["typeOf(3.5)","typeOf(2 - 4i)","typeOf(45 deg)",'typeOf("hello world")'],seealso:["getMatrixDataType"]},numeric:{name:"numeric",category:"Utils",syntax:["numeric(x)"],description:"Convert a numeric input to a specific numeric type: number, BigNumber, bigint, or Fraction.",examples:['numeric("4")','numeric("4", "number")','numeric("4", "bigint")','numeric("4", "BigNumber")','numeric("4", "Fraction")','numeric(4, "Fraction")','numeric(fraction(2, 5), "number")'],seealso:["number","bigint","fraction","bignumber","string","format"]}},aA=re("help",["typed","mathWithTransform","Help"],p=>{var{typed:m,mathWithTransform:b,Help:_}=p;return m("help",{any:function(C){var A,k=C;if("string"!=typeof C)for(A in b)if(Jt(b,A)&&C===b[A]){k=A;break}var R=X(oA,k);if(!R)throw new Error('No documentation found on "'+("function"==typeof k?k.name:k)+'"');return new _(R)}})});function nk(p,m,b){var _=p.filter(function(R){return Gn(R)&&!(R.name in m)&&!b.has(R.name)})[0];if(!_)throw new Error('No undefined variable found in inline expression "'+p+'"');var y=_.name,C=new Map,A=new le(b,C,new Set([y])),k=p.compile();return function(O){return C.set(y,O),k.evaluate(A)}}var ik=re("transformCallback",["typed"],p=>{var{typed:m}=p;return function(_,y){return m.isTypedFunction(_)?b(_,y):NP(_,_.length,y)};function b(_,y){var C=Object.fromEntries(Object.entries(_.signatures).map(A=>{var[k,R]=A,O=k.split(",").length;return m.isTypedFunction(R)?[k,b(R,y)]:[k,NP(R,O,y)]}));return"string"==typeof _.name?m(_.name,C):m(C)}});function NP(p,m,b){return m===b?p:m===b+1?function(){for(var _=arguments.length,y=new Array(_),C=0;C<_;C++)y[C]=arguments[C];var A=y.slice(0,b),k=rk(y[b]);return p(...A,k)}:m>b+1?function(){for(var _=arguments.length,y=new Array(_),C=0;C<_;C++)y[C]=arguments[C];var A=y.slice(0,b),k=rk(y[b]),R=y.slice(b+1);return p(...A,k,...R)}:p}function rk(p){return p.map(m=>m+1)}var lA=re("filter",["typed"],p=>{var{typed:m}=p;function b(y,C,A){var k=mD({typed:m}),R=ik({typed:m});if(0===y.length)return k();var O=y[0];if(1===y.length)return k(O);var F=y.length-1,B=y[F];return O&&(O=_(O,A)),B&&(B=Gn(B)||Ur(B)?_(B,A):nk(B,C,A)),k(O,R(B,F))}function _(y,C){return y.compile().evaluate(C)}return b.rawArgs=!0,b},{isTransformFunction:!0}),G2=re("forEach",["typed"],p=>{var{typed:m}=p,b=Oh({typed:m}),_=ik({typed:m});function y(A,k,R){if(0===A.length)return b();var O=A[0];if(1===A.length)return b(O);var F=A.length-1,B=A[F];return O&&(O=C(O,R)),B&&(B=Gn(B)||Ur(B)?C(B,R):nk(B,k,R)),b(O,_(B,F))}function C(A,k){return A.compile().evaluate(k)}return y.rawArgs=!0,y},{isTransformFunction:!0}),K2=re("map",["typed"],p=>{var{typed:m}=p,b=Ou({typed:m}),_=ik({typed:m});function y(C,A,k){if(0===C.length)return b();if(1===C.length)return b(C[0]);var R=C.length-1,O=C.slice(0,R),F=C[R];return O=O.map(H=>B(H,k)),F&&(F=Gn(F)||Ur(F)?B(F,k):nk(F,A,k)),b(...O,_(F,R));function B(H,G){return H.compile().evaluate(G)}}return y.rawArgs=!0,y},{isTransformFunction:!0}),cA=re("apply",["typed","isInteger"],p=>{var{typed:m,isInteger:b}=p,_=Kv({typed:m,isInteger:b});return m("apply",{"...any":function(C){var A=C[1];ct(A)?C[1]=A-1:en(A)&&(C[1]=A.minus(1));try{return _.apply(null,C)}catch(k){throw yh(k)}}})},{isTransformFunction:!0}),Q2=re("or",["typed","matrix","equalScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C}=p,A=rv({typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C});function k(R,O,F){var B=R[0].compile().evaluate(F);if(!Mt(B)&&A(B,!1))return!0;var H=R[1].compile().evaluate(F);return A(B,H)}return k.rawArgs=!0,k},{isTransformFunction:!0}),Y2=re("and",["typed","matrix","zeros","add","equalScalar","not","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,not:C,concat:A}=p,k=Wf({typed:m,matrix:b,equalScalar:_,zeros:y,not:C,concat:A});function R(O,F,B){var H=O[0].compile().evaluate(B);if(!Mt(H)&&!k(H,!0))return!1;var G=O[1].compile().evaluate(B);return k(H,G)}return R.rawArgs=!0,R},{isTransformFunction:!0}),cE=re("concat",["typed","matrix","isInteger"],p=>{var{typed:m,matrix:b,isInteger:_}=p,y=Gm({typed:m,matrix:b,isInteger:_});return m("concat",{"...any":function(A){var k=A.length-1,R=A[k];ct(R)?A[k]=R-1:en(R)&&(A[k]=R.minus(1));try{return y.apply(null,A)}catch(O){throw yh(O)}}})},{isTransformFunction:!0});function ZC(p){if(2===p.length&&Mt(p[0])){var m=(p=p.slice())[1];(function ak(p){return ct(p)||en(p)})(m)&&(p[1]=function WP(p){return ct(p)?p-1:en(p)?p.minus(1):p}(m))}return p}var tx=re("max",["typed","config","numeric","larger"],p=>{var{typed:m,config:b,numeric:_,larger:y}=p,C=Uy({typed:m,config:b,numeric:_,larger:y});return m("max",{"...any":function(k){k=ZC(k);try{return C.apply(null,k)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),uA=re("print",["typed","matrix","zeros","add"],p=>{var{typed:m,matrix:b,zeros:_,add:y}=p,C=$v({typed:m,matrix:b,zeros:_,add:y});return m("print",{"string, Object | Array":function(R,O){return C(A(R),O)},"string, Object | Array, number | Object":function(R,O,F){return C(A(R),O,F)}});function A(k){return k.replace(_1,R=>"$"+R.slice(1).split(".").map(function(B){return!isNaN(B)&&B.length>0?parseInt(B)-1:B}).join("."))}},{isTransformFunction:!0}),fA=re("bitAnd",["typed","matrix","zeros","add","equalScalar","not","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,zeros:y,not:C,concat:A}=p,k=Vh({typed:m,matrix:b,equalScalar:_,zeros:y,not:C,concat:A});function R(O,F,B){var H=O[0].compile().evaluate(B);if(!Mt(H)){if(isNaN(H))return NaN;if(0===H||!1===H)return 0}var G=O[1].compile().evaluate(B);return k(H,G)}return R.rawArgs=!0,R},{isTransformFunction:!0}),t1=re("diff",["typed","matrix","subtract","number","bignumber"],p=>{var{typed:m,matrix:b,subtract:_,number:y,bignumber:C}=p,A=Sy({typed:m,matrix:b,subtract:_,number:y,bignumber:C});return m("diff",{"...any":function(R){R=ZC(R);try{return A.apply(null,R)}catch(O){throw yh(O)}}})},{isTransformFunction:!0}),pA=re("min",["typed","config","numeric","smaller"],p=>{var{typed:m,config:b,numeric:_,smaller:y}=p,C=rC({typed:m,config:b,numeric:_,smaller:y});return m("min",{"...any":function(k){k=ZC(k);try{return C.apply(null,k)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),hA=re("subset",["typed","matrix","zeros","add"],p=>{var{typed:m,matrix:b,zeros:_,add:y}=p,C=ov({typed:m,matrix:b,zeros:_,add:y});return m("subset",{"...any":function(k){try{return C.apply(null,k)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),tO=re("bitOr",["typed","matrix","equalScalar","DenseMatrix","concat"],p=>{var{typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C}=p,A=by({typed:m,matrix:b,equalScalar:_,DenseMatrix:y,concat:C});function k(R,O,F){var B=R[0].compile().evaluate(F);if(!Mt(B)){if(isNaN(B))return NaN;if(-1===B)return-1;if(!0===B)return 1}var H=R[1].compile().evaluate(F);return A(B,H)}return k.rawArgs=!0,k},{isTransformFunction:!0}),mA=re("cumsum",["typed","add","unaryPlus"],p=>{var{typed:m,add:b,unaryPlus:_}=p,y=xy({typed:m,add:b,unaryPlus:_});return m("cumsum",{"...any":function(A){if(2===A.length&&Mt(A[0])){var k=A[1];ct(k)?A[1]=k-1:en(k)&&(A[1]=k.minus(1))}try{return y.apply(null,A)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),gA=re("index",["Index","getMatrixDataType"],p=>{var{Index:m,getMatrixDataType:b}=p;return function(){for(var y=[],C=0,A=arguments.length;C<A;C++){var k=arguments[C];if(Vn(k))k.start--,k.end-=k.step>0?0:2;else if(k&&!0===k.isSet)k=k.map(function(O){return O-1});else if(dt(k)||ut(k))"boolean"!==b(k)&&(k=k.map(function(O){return O-1}));else if(ct(k))k--;else if(en(k))k=k.toNumber()-1;else if("string"!=typeof k)throw new TypeError("Dimension must be an Array, Matrix, number, string, or Range");y[C]=k}var R=new m;return m.apply(R,y),R}},{isTransformFunction:!0}),vA=re("sum",["typed","config","add","numeric"],p=>{var{typed:m,config:b,add:_,numeric:y}=p,C=ig({typed:m,config:b,add:_,numeric:y});return m("sum",{"...any":function(k){k=ZC(k);try{return C.apply(null,k)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),_A=re("range",["typed","config","?matrix","?bignumber","smaller","smallerEq","larger","largerEq","add","isPositive"],p=>{var{typed:m,config:b,matrix:_,bignumber:y,smaller:C,smallerEq:A,larger:k,largerEq:R,add:O,isPositive:F}=p,B=nu({typed:m,config:b,matrix:_,bignumber:y,smaller:C,smallerEq:A,larger:k,largerEq:R,add:O,isPositive:F});return m("range",{"...any":function(G){return"boolean"!=typeof G[G.length-1]&&G.push(!0),B.apply(null,G)}})},{isTransformFunction:!0}),yA=re("row",["typed","Index","matrix","range"],p=>{var{typed:m,Index:b,matrix:_,range:y}=p,C=ym({typed:m,Index:b,matrix:_,range:y});return m("row",{"...any":function(k){var R=k.length-1,O=k[R];ct(O)&&(k[R]=O-1);try{return C.apply(null,k)}catch(F){throw yh(F)}}})},{isTransformFunction:!0}),gM=re("column",["typed","Index","matrix","range"],p=>{var{typed:m,Index:b,matrix:_,range:y}=p,C=zy({typed:m,Index:b,matrix:_,range:y});return m("column",{"...any":function(k){var R=k.length-1,O=k[R];ct(O)&&(k[R]=O-1);try{return C.apply(null,k)}catch(F){throw yh(F)}}})},{isTransformFunction:!0}),uE=re("mean",["typed","add","divide"],p=>{var{typed:m,add:b,divide:_}=p,y=RC({typed:m,add:b,divide:_});return m("mean",{"...any":function(A){A=ZC(A);try{return y.apply(null,A)}catch(k){throw yh(k)}}})},{isTransformFunction:!0}),l=re("quantileSeq",["typed","bignumber","add","subtract","divide","multiply","partitionSelect","compare","isInteger","smaller","smallerEq","larger"],p=>{var{typed:m,bignumber:b,add:_,subtract:y,divide:C,multiply:A,partitionSelect:k,compare:R,isInteger:O,smaller:F,smallerEq:B,larger:H}=p,G=I_({typed:m,bignumber:b,add:_,subtract:y,divide:C,multiply:A,partitionSelect:k,compare:R,isInteger:O,smaller:F,smallerEq:B,larger:H});return m("quantileSeq",{"Array | Matrix, number | BigNumber":G,"Array | Matrix, number | BigNumber, number":(te,be,we)=>G(te,be,J(we)),"Array | Matrix, number | BigNumber, boolean":G,"Array | Matrix, number | BigNumber, boolean, number":(te,be,we,Le)=>G(te,be,we,J(Le)),"Array | Matrix, Array | Matrix":G,"Array | Matrix, Array | Matrix, number":(te,be,we)=>G(te,be,J(we)),"Array | Matrix, Array | Matrix, boolean":G,"Array | Matrix, Array | Matrix, boolean, number":(te,be,we,Le)=>G(te,be,we,J(Le))});function J(te){return ZC([[],te])[1]}},{isTransformFunction:!0}),d="variance",w=re(d,["typed","add","subtract","multiply","divide","apply","isNaN"],p=>{var{typed:m,add:b,subtract:_,multiply:y,divide:C,apply:A,isNaN:k}=p,R=A_({typed:m,add:b,subtract:_,multiply:y,divide:C,apply:A,isNaN:k});return m(d,{"...any":function(F){F=ZC(F);try{return R.apply(null,F)}catch(B){throw yh(B)}}})},{isTransformFunction:!0}),ae=re("std",["typed","map","sqrt","variance"],p=>{var{typed:m,map:b,sqrt:_,variance:y}=p,C=g({typed:m,map:b,sqrt:_,variance:y});return m("std",{"...any":function(k){k=ZC(k);try{return C.apply(null,k)}catch(R){throw yh(R)}}})},{isTransformFunction:!0}),xe={},qe={},ft={},Xt=DI({mathWithTransform:qe}),Ln=n2({Node:Xt}),zn=$T({Node:Xt}),xi=SI({Node:Xt}),Nr=HT({Node:Xt}),go=rE({Node:Xt}),Oo=MI({Node:Xt,ResultSet:Ml}),Ar=QC({Node:Xt}),ma=qw({Node:Xt}),oc=QT({Node:Xt}),qu=YT({classes:ft}),Gd=XT({math:xe,typed:dn}),qh=OI({Node:Xt,typed:dn}),dE=ZT({Chain:Gd,typed:dn}),nx=JT({Node:Xt,size:Hi}),bA=eM({Node:Xt,subset:vg}),gk=nM({matrix:$,Node:Xt,subset:vg}),ix=NI({Unit:Ta,Node:Xt,math:xe}),n1=iM({Node:Xt,SymbolNode:ix,math:xe}),JC=rM({AccessorNode:bA,ArrayNode:go,AssignmentNode:gk,BlockNode:Oo,ConditionalNode:Ar,ConstantNode:ma,FunctionAssignmentNode:qh,FunctionNode:n1,IndexNode:nx,ObjectNode:Ln,OperatorNode:zn,ParenthesisNode:xi,RangeNode:oc,RelationalNode:Nr,SymbolNode:ix,config:Sn,numeric:Lt,typed:dn}),qP=Xw({ConstantNode:ma,FunctionNode:n1,OperatorNode:zn,ParenthesisNode:xi,parse:JC,typed:dn}),vk=sM({bignumber:Gf,fraction:k_,AccessorNode:bA,ArrayNode:go,ConstantNode:ma,FunctionNode:n1,IndexNode:nx,ObjectNode:Ln,OperatorNode:zn,SymbolNode:ix,config:Sn,mathWithTransform:qe,matrix:$,typed:dn}),C3=kI({parse:JC,typed:dn}),_k=PI({AccessorNode:bA,ArrayNode:go,ConstantNode:ma,FunctionNode:n1,IndexNode:nx,ObjectNode:Ln,OperatorNode:zn,ParenthesisNode:xi,SymbolNode:ix,add:Ha,divide:Kf,equal:zd,isZero:Kh,multiply:Gc,parse:JC,pow:bv,subtract:zc,typed:dn}),iO=BI({parse:JC,typed:dn}),QP=aM({evaluate:iO}),YP=Zb({evaluate:iO}),TN=VI({bignumber:Gf,fraction:k_,AccessorNode:bA,ArrayNode:go,ConstantNode:ma,FunctionNode:n1,IndexNode:nx,ObjectNode:Ln,OperatorNode:zn,ParenthesisNode:xi,SymbolNode:ix,add:Ha,config:Sn,divide:Kf,equal:zd,isZero:Kh,mathWithTransform:qe,matrix:$,multiply:Gc,parse:JC,pow:bv,resolve:qP,simplifyConstant:vk,simplifyCore:_k,subtract:zc,typed:dn}),D3=fF({OperatorNode:zn,parse:JC,simplify:TN,typed:dn}),w3=$I({parse:JC,typed:dn}),x3=Zw({Parser:YP,typed:dn}),S3=uM({bignumber:Gf,fraction:k_,AccessorNode:bA,ArrayNode:go,ConstantNode:ma,FunctionNode:n1,IndexNode:nx,ObjectNode:Ln,OperatorNode:zn,ParenthesisNode:xi,SymbolNode:ix,add:Ha,config:Sn,divide:Kf,equal:zd,isZero:Kh,mathWithTransform:qe,matrix:$,multiply:Gc,parse:JC,pow:bv,simplify:TN,simplifyConstant:vk,simplifyCore:_k,subtract:zc,typed:dn}),E3=YC({ConstantNode:ma,FunctionNode:n1,OperatorNode:zn,ParenthesisNode:xi,SymbolNode:ix,config:Sn,equal:zd,isZero:Kh,numeric:Lt,parse:JC,simplify:TN,typed:dn}),T3=aA({Help:QP,mathWithTransform:qe,typed:dn});e(xe,{e:ml,false:Ca,fineStructure:oo,i:Co,Infinity:us,LN10:Rr,LOG10E:xo,NaN:No,null:Hr,phi:ys,SQRT1_2:Nu,sackurTetrode:Rd,tau:ru,true:wd,E:ml,version:jl,efimovFactor:Cr,LN2:So,pi:Po,replacer:wi,reviver:qu,SQRT2:ha,typed:dn,PI:Po,weakMixingAngle:Ol,abs:Fa,acos:hs,acot:Ka,acsc:mg,addScalar:Du,arg:Bw,asech:F_,asinh:Gb,atan:LC,atanh:N_,bigint:ST,bitNot:HS,boolean:R_,clone:kC,combinations:Kb,complex:uf,conj:L_,cos:PC,cot:AA,csc:QM,cube:BC,equalScalar:nl,erf:OA,exp:ET,expm1:FA,filter:zS,flatten:VC,forEach:YM,format:Vw,getMatrixDataType:jw,hex:TT,im:jC,isInteger:zp,isNegative:vv,isPositive:u0,isZero:Kh,LOG2E:XM,lgamma:MT,log10:ZM,log2:GS,map:d0,multiplyScalar:Ku,not:Cs,number:Ul,oct:JM,pickRandom:xd,print:ua,random:yp,re:UC,sec:Wa,sign:Sf,sin:wl,splitUnit:eI,square:NA,string:f0,subtractScalar:gh,tan:xm,typeOf:Gp,acosh:p0,acsch:tI,apply:h0,asec:IT,bignumber:Gf,chain:dE,combinationsWithRep:$C,cosh:WC,csch:_v,isNaN:Kp,isPrime:HC,randomInt:zC,sech:GC,sinh:qb,sparse:Uw,sqrt:vh,squeeze:KS,tanh:$w,unaryMinus:bp,acoth:Qb,bin:qS,coth:KC,fraction:k_,isNumeric:N,matrix:$,matrixFromFunction:ge,mode:nt,numeric:Lt,prod:bn,reshape:ui,size:Hi,transpose:yr,xgcd:fs,zeros:co,asin:Do,cbrt:Ts,concat:os,count:gl,ctranspose:Xs,diag:il,divideScalar:Da,dotDivide:fd,equal:zd,hasNumericValue:Sm,identity:Ef,kron:df,largerEq:Cp,leftShift:Yb,lsolve:Em,matrixFromColumns:AT,nthRoot:dO,ones:nI,qr:RA,resize:iI,rightArithShift:Ww,round:Xb,smaller:Dp,subtract:zc,to:fO,unaryPlus:QS,usolve:gg,xor:yv,add:Ha,atan2:pO,bitAnd:hO,bitOr:LN,bitXor:kN,catalan:PN,compare:Hw,compareText:rI,cumsum:OT,deepEqual:LA,diff:mO,distance:BN,dot:oI,equalText:gO,floor:kA,gcd:FT,hypot:VN,larger:_h,log:sI,lsolveAll:vO,matrixFromRows:BA,min:_O,mod:VA,multiply:Gc,nthRoots:yO,or:bO,partitionSelect:aI,rightLogShift:jA,slu:jN,subset:vg,sum:NT,trace:CO,usolveAll:RT,zpk2tf:DO,ceil:lI,compareNatural:P_,composition:wO,cross:xO,det:SO,dotMultiply:cI,fix:$N,index:EO,intersect:TO,invmod:uI,lcm:WN,log1p:HN,max:LT,setCartesian:zN,setDistinct:dI,setIsSubset:fI,setPowerset:UA,smallerEq:zw,sort:GN,unequal:KN,and:MO,range:m0,row:pI,setDifference:hI,setMultiplicity:Gw,setSymDifference:IO,column:$A,inv:g0,lup:kT,pinv:Kw,pow:bv,setIntersect:mI,setUnion:qC,sqrtm:qN,vacuumImpedance:QN,wienDisplacement:WA,atomicMass:HA,bohrMagneton:YN,boltzmann:YS,conductanceQuantum:zA,coulomb:XN,deuteronMass:ZN,dotPow:PT,electricConstant:JN,elementaryCharge:gI,expm:vI,faraday:Tm,fft:GA,gamma:_I,gravitationConstant:eR,hartreeEnergy:XS,ifft:ZS,klitzing:tR,loschmidt:nR,magneticConstant:KA,molarMass:JS,molarPlanckConstant:OO,neutronMass:iR,nuclearMagneton:rR,planckCharge:qA,planckLength:FO,planckTemperature:NO,protonMass:oR,quantumOfCirculation:RO,reducedPlanckConstant:sR,rydberg:Ek,secondRadiation:Tk,speedOfLight:Mk,stefanBoltzmann:Ik,thomsonCrossSection:LO,avogadro:yI,bohrRadius:aR,createUnit:lR,divide:Kf,electronMass:eE,factorial:BT,firstRadiation:cR,gravity:kO,inverseConductanceQuantum:uR,lusolve:dR,magneticFluxQuantum:fR,molarMassC12:PO,multinomial:pR,parse:JC,permutations:hR,planckMass:tE,polynomialRoot:BO,resolve:qP,setSize:VO,simplifyConstant:vk,solveODE:jO,stirlingS2:QA,unit:UO,bellNumbers:mR,compile:C3,eigs:bI,fermiCoupling:$O,gasConstant:WO,kldivergence:HO,mean:zO,molarVolume:gR,planckConstant:vR,quantileSeq:YA,simplifyCore:_k,variance:XA,classicalElectronRadius:GO,evaluate:iO,median:KO,simplify:TN,symbolicEqual:D3,corr:_R,freqz:yR,leafCount:w3,mad:bR,parser:x3,rationalize:S3,std:CR,zeta:DR,derivative:E3,norm:ZA,rotationMatrix:qO,help:T3,planckTime:JA,schur:CI,rotate:QO,sylvester:e2,lyap:t2,config:Sn}),e(qe,xe,{filter:lA({typed:dn}),forEach:G2({typed:dn}),map:K2({typed:dn}),apply:cA({isInteger:zp,typed:dn}),or:Q2({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),and:Y2({add:Ha,concat:os,equalScalar:nl,matrix:$,not:Cs,typed:dn,zeros:co}),concat:cE({isInteger:zp,matrix:$,typed:dn}),max:tx({config:Sn,larger:_h,numeric:Lt,typed:dn}),print:uA({add:Ha,matrix:$,typed:dn,zeros:co}),bitAnd:fA({add:Ha,concat:os,equalScalar:nl,matrix:$,not:Cs,typed:dn,zeros:co}),diff:t1({bignumber:Gf,matrix:$,number:Ul,subtract:zc,typed:dn}),min:pA({config:Sn,numeric:Lt,smaller:Dp,typed:dn}),subset:hA({add:Ha,matrix:$,typed:dn,zeros:co}),bitOr:tO({DenseMatrix:Os,concat:os,equalScalar:nl,matrix:$,typed:dn}),cumsum:mA({add:Ha,typed:dn,unaryPlus:QS}),index:gA({Index:qp,getMatrixDataType:jw}),sum:vA({add:Ha,config:Sn,numeric:Lt,typed:dn}),range:_A({bignumber:Gf,matrix:$,add:Ha,config:Sn,isPositive:u0,larger:_h,largerEq:Cp,smaller:Dp,smallerEq:zw,typed:dn}),row:yA({Index:qp,matrix:$,range:m0,typed:dn}),column:gM({Index:qp,matrix:$,range:m0,typed:dn}),mean:uE({add:Ha,divide:Kf,typed:dn}),quantileSeq:l({add:Ha,bignumber:Gf,compare:Hw,divide:Kf,isInteger:zp,larger:_h,multiply:Gc,partitionSelect:aI,smaller:Dp,smallerEq:zw,subtract:zc,typed:dn}),variance:w({add:Ha,apply:h0,divide:Kf,isNaN:Kp,multiply:Gc,subtract:zc,typed:dn}),std:ae({map:d0,sqrt:vh,typed:dn,variance:XA})}),e(ft,{BigNumber:br,Complex:yo,Fraction:Ba,Matrix:Jr,Node:Xt,ObjectNode:Ln,OperatorNode:zn,ParenthesisNode:xi,Range:Ns,RelationalNode:Nr,ResultSet:Ml,ArrayNode:go,BlockNode:Oo,ConditionalNode:Ar,ConstantNode:ma,DenseMatrix:Os,RangeNode:oc,Chain:Gd,FunctionAssignmentNode:qh,SparseMatrix:$l,IndexNode:nx,ImmutableDenseMatrix:PA,Index:qp,AccessorNode:bA,AssignmentNode:gk,FibonacciHeap:UN,Spa:AO,Unit:Ta,SymbolNode:ix,FunctionNode:n1,Help:QP,Parser:YP}),Gd.createProxy(xe);var To={createBigNumberClass:$i},pd={createComplexClass:nd},yk={createMatrixClass:Ch},Fl={MatrixDependencies:yk,createDenseMatrixClass:Nf},CA={createFractionClass:bg},Pn={BigNumberDependencies:To,ComplexDependencies:pd,DenseMatrixDependencies:Fl,FractionDependencies:CA,createTyped:Xl},Cv={typedDependencies:Pn,createAbs:ef},Im={createNode:DI},Kl={typedDependencies:Pn,createEqualScalar:Rv},fE={MatrixDependencies:yk,equalScalarDependencies:Kl,typedDependencies:Pn,createSparseMatrixClass:H0},r={typedDependencies:Pn,createAddScalar:oh},v={typedDependencies:Pn,createIsInteger:rm},t={DenseMatrixDependencies:Fl,MatrixDependencies:yk,SparseMatrixDependencies:fE,typedDependencies:Pn,createMatrix:Wg},n={isIntegerDependencies:v,matrixDependencies:t,typedDependencies:Pn,createConcat:Gm},o={DenseMatrixDependencies:Fl,SparseMatrixDependencies:fE,addScalarDependencies:r,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createAdd:db},f={BigNumberDependencies:To,matrixDependencies:t,typedDependencies:Pn,createZeros:jD},D={addDependencies:o,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createSubset:ov},j={NodeDependencies:Im,subsetDependencies:D,createAccessorNode:eM},fe={ComplexDependencies:pd,typedDependencies:Pn,createAcos:wg},Ne={ComplexDependencies:pd,typedDependencies:Pn,createAcosh:D1},vt={BigNumberDependencies:To,typedDependencies:Pn,createAcot:Tr},ln={BigNumberDependencies:To,ComplexDependencies:pd,typedDependencies:Pn,createAcoth:Ug},Hn={BigNumberDependencies:To,ComplexDependencies:pd,typedDependencies:Pn,createAcsc:ka},Oi={BigNumberDependencies:To,typedDependencies:Pn,createAcsch:w1},Lr={typedDependencies:Pn,createNot:Wm},to={concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,notDependencies:Lr,typedDependencies:Pn,zerosDependencies:f,createAnd:Wf},Mr={addDependencies:o,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,notDependencies:Lr,typedDependencies:Pn,zerosDependencies:f,createAndTransform:Y2},ss={isIntegerDependencies:v,typedDependencies:Pn,createApply:Kv},Rs={isIntegerDependencies:v,typedDependencies:Pn,createApplyTransform:cA},Us={typedDependencies:Pn,createArg:vf},wu={NodeDependencies:Im,createArrayNode:rE},Tf={BigNumberDependencies:To,ComplexDependencies:pd,typedDependencies:Pn,createAsec:sy},vM={BigNumberDependencies:To,ComplexDependencies:pd,typedDependencies:Pn,createAsech:Bm},L3={ComplexDependencies:pd,typedDependencies:Pn,createAsin:R1},eV={typedDependencies:Pn,createAsinh:Ko},iB={matrixDependencies:t,NodeDependencies:Im,subsetDependencies:D,createAssignmentNode:nM},rB={typedDependencies:Pn,createAtan:wc},tV={BigNumberDependencies:To,DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createAtan2:a_},nV={ComplexDependencies:pd,typedDependencies:Pn,createAtanh:Mh},eD={BigNumberDependencies:To,typedDependencies:Pn,createBignumber:qv},bk={FractionDependencies:CA,typedDependencies:Pn,createFraction:pp},DA={typedDependencies:Pn,createNumber:xD},rx={bignumberDependencies:eD,fractionDependencies:bk,numberDependencies:DA,createNumeric:N1},rp={numericDependencies:rx,typedDependencies:Pn,createDivideScalar:k1},ox={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createEqual:V1},Ck={BigNumberDependencies:To,DenseMatrixDependencies:Fl,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createRound:z1},k3={DenseMatrixDependencies:Fl,equalScalarDependencies:Kl,matrixDependencies:t,roundDependencies:Ck,typedDependencies:Pn,zerosDependencies:f,createCeil:hC},oB={DenseMatrixDependencies:Fl,equalScalarDependencies:Kl,matrixDependencies:t,roundDependencies:Ck,typedDependencies:Pn,zerosDependencies:f,createFloor:Xm},sB={ComplexDependencies:pd,DenseMatrixDependencies:Fl,ceilDependencies:k3,equalScalarDependencies:Kl,floorDependencies:oB,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createFix:Ab},XP={typedDependencies:Pn,createFormat:_D},MN={typedDependencies:Pn,createIsNumeric:tp},Yp={typedDependencies:Pn,createMultiplyScalar:m1},rO={BigNumberDependencies:To,DenseMatrixDependencies:Fl,SparseMatrixDependencies:fE,matrixDependencies:t,typedDependencies:Pn,createIdentity:$a},pE={equalScalarDependencies:Kl,typedDependencies:Pn,createIsZero:Ng},IN={typedDependencies:Pn,createConj:K_},Dv={matrixDependencies:t,typedDependencies:Pn,createSize:bf},M3={addScalarDependencies:r,conjDependencies:IN,multiplyScalarDependencies:Yp,sizeDependencies:Dv,typedDependencies:Pn,createDot:jh},td={addScalarDependencies:r,dotDependencies:M3,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,typedDependencies:Pn,createMultiply:bb},sx={typedDependencies:Pn,createSubtractScalar:Cd},_M={typedDependencies:Pn,createUnaryMinus:jg},aB={divideScalarDependencies:rp,isZeroDependencies:pE,matrixDependencies:t,multiplyDependencies:td,subtractScalarDependencies:sx,typedDependencies:Pn,unaryMinusDependencies:_M,createDet:vw},AN={absDependencies:Cv,addScalarDependencies:r,detDependencies:aB,divideScalarDependencies:rp,identityDependencies:rO,matrixDependencies:t,multiplyDependencies:td,typedDependencies:Pn,unaryMinusDependencies:_M,createInv:Ju},ax={ComplexDependencies:pd,fractionDependencies:bk,identityDependencies:rO,invDependencies:AN,matrixDependencies:t,multiplyDependencies:td,numberDependencies:DA,typedDependencies:Pn,createPow:zh},ul={BigNumberDependencies:To,ComplexDependencies:pd,FractionDependencies:CA,absDependencies:Cv,addScalarDependencies:r,divideScalarDependencies:rp,equalDependencies:ox,fixDependencies:sB,formatDependencies:XP,isNumericDependencies:MN,multiplyScalarDependencies:Yp,numberDependencies:DA,powDependencies:ax,roundDependencies:Ck,subtractScalarDependencies:sx,createUnitClass:cf},iV={BigNumberDependencies:To,UnitDependencies:ul,createAtomicMass:ne},rV={BigNumberDependencies:To,UnitDependencies:ul,createAvogadro:Pe},oO={typedDependencies:Pn,createIsNegative:Bv},I3={typedDependencies:Pn,createCombinations:cD},P3={BigNumberDependencies:To,ComplexDependencies:pd,multiplyScalarDependencies:Yp,powDependencies:ax,typedDependencies:Pn,createGamma:kb},ZP={gammaDependencies:P3,typedDependencies:Pn,createFactorial:Dd},_0={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createLarger:My},lB={bignumberDependencies:eD,addScalarDependencies:r,combinationsDependencies:I3,divideScalarDependencies:rp,factorialDependencies:ZP,isIntegerDependencies:v,isNegativeDependencies:oO,largerDependencies:_0,multiplyScalarDependencies:Yp,numberDependencies:DA,powDependencies:ax,subtractScalarDependencies:sx,typedDependencies:Pn,createStirlingS2:OC},oV={addScalarDependencies:r,isIntegerDependencies:v,isNegativeDependencies:oO,stirlingS2Dependencies:lB,typedDependencies:Pn,createBellNumbers:r0},sV={typedDependencies:Pn,createBigint:nD},aV={formatDependencies:XP,typedDependencies:Pn,createBin:$g},lV={concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createBitAnd:Vh},cV={addDependencies:o,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,notDependencies:Lr,typedDependencies:Pn,zerosDependencies:f,createBitAndTransform:fA},uV={typedDependencies:Pn,createBitNot:a1},dV={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createBitOr:by},fV={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createBitOrTransform:tO},pV={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createBitXor:gm},cB={createResultSet:xr},uB={NodeDependencies:Im,ResultSetDependencies:cB,createBlockNode:MI},hV={BigNumberDependencies:To,UnitDependencies:ul,createBohrMagneton:Bc},mV={BigNumberDependencies:To,UnitDependencies:ul,createBohrRadius:mn},gV={BigNumberDependencies:To,UnitDependencies:ul,createBoltzmann:rt},vV={typedDependencies:Pn,createBoolean:I0},_V={addScalarDependencies:r,combinationsDependencies:I3,divideScalarDependencies:rp,isIntegerDependencies:v,isNegativeDependencies:oO,multiplyScalarDependencies:Yp,typedDependencies:Pn,createCatalan:c_},dB={BigNumberDependencies:To,ComplexDependencies:pd,FractionDependencies:CA,isNegativeDependencies:oO,matrixDependencies:t,typedDependencies:Pn,unaryMinusDependencies:_M,createCbrt:mp},fB={typedDependencies:Pn,createChainClass:XT},yV={ChainDependencies:fB,typedDependencies:Pn,createChain:ZT},bV={BigNumberDependencies:To,UnitDependencies:ul,createClassicalElectronRadius:gi},CV={typedDependencies:Pn,createClone:nf},y0={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createSmaller:jf},pB={DenseMatrixDependencies:Fl,smallerDependencies:y0,createImmutableDenseMatrixClass:_b},B3={typedDependencies:Pn,createGetMatrixDataType:p1},V_={ImmutableDenseMatrixDependencies:pB,getMatrixDataTypeDependencies:B3,createIndexClass:tv},ON={typedDependencies:Pn,createIsPositive:ad},A3={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createLargerEq:fy},Dk={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createSmallerEq:Ys},wk={bignumberDependencies:eD,matrixDependencies:t,addDependencies:o,isPositiveDependencies:ON,largerDependencies:_0,largerEqDependencies:A3,smallerDependencies:y0,smallerEqDependencies:Dk,typedDependencies:Pn,createRange:nu},hB={IndexDependencies:V_,matrixDependencies:t,rangeDependencies:wk,typedDependencies:Pn,createColumn:zy},DV={IndexDependencies:V_,matrixDependencies:t,rangeDependencies:wk,typedDependencies:Pn,createColumnTransform:gM},wV={typedDependencies:Pn,createCombinationsWithRep:Q0},FN={BigNumberDependencies:To,DenseMatrixDependencies:Fl,FractionDependencies:CA,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createCompare:Dy},yM={compareDependencies:FN,typedDependencies:Pn,createCompareNatural:$h},mB={concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createCompareText:ev},gB={NodeDependencies:Im,createConditionalNode:QC},sO={NodeDependencies:Im,createConstantNode:qw},vB={NodeDependencies:Im,typedDependencies:Pn,createFunctionAssignmentNode:OI},aO={UnitDependencies:ul,NodeDependencies:Im,createSymbolNode:NI},lO={NodeDependencies:Im,SymbolNodeDependencies:aO,createFunctionNode:iM},xk={NodeDependencies:Im,sizeDependencies:Dv,createIndexNode:JT},Sk={NodeDependencies:Im,createObjectNode:n2},wA={NodeDependencies:Im,createOperatorNode:$T},NN={NodeDependencies:Im,createParenthesisNode:SI},_B={NodeDependencies:Im,createRangeNode:QT},yB={NodeDependencies:Im,createRelationalNode:HT},bM={AccessorNodeDependencies:j,ArrayNodeDependencies:wu,AssignmentNodeDependencies:iB,BlockNodeDependencies:uB,ConditionalNodeDependencies:gB,ConstantNodeDependencies:sO,FunctionAssignmentNodeDependencies:vB,FunctionNodeDependencies:lO,IndexNodeDependencies:xk,ObjectNodeDependencies:Sk,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,RangeNodeDependencies:_B,RelationalNodeDependencies:yB,SymbolNodeDependencies:aO,numericDependencies:rx,typedDependencies:Pn,createParse:rM},xV={parseDependencies:bM,typedDependencies:Pn,createCompile:kI},O3={ComplexDependencies:pd,typedDependencies:Pn,createComplex:Fv},SV={addScalarDependencies:r,combinationsDependencies:I3,isIntegerDependencies:v,isNegativeDependencies:oO,isPositiveDependencies:ON,largerDependencies:_0,typedDependencies:Pn,createComposition:wS},EV={isIntegerDependencies:v,matrixDependencies:t,typedDependencies:Pn,createConcatTransform:cE},TV={BigNumberDependencies:To,UnitDependencies:ul,createConductanceQuantum:pf},_g={divideScalarDependencies:rp,equalScalarDependencies:Kl,invDependencies:AN,matrixDependencies:t,multiplyDependencies:td,typedDependencies:Pn,createDivide:xC},bB={addDependencies:o,divideDependencies:_g,typedDependencies:Pn,createMean:RC},hE={ComplexDependencies:pd,typedDependencies:Pn,createSqrt:zm},Xp={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,subtractScalarDependencies:sx,typedDependencies:Pn,unaryMinusDependencies:_M,createSubtract:Vp},V3={addDependencies:o,numericDependencies:rx,typedDependencies:Pn,createSum:ig},MV={addDependencies:o,divideDependencies:_g,matrixDependencies:t,meanDependencies:bB,multiplyDependencies:td,powDependencies:ax,sqrtDependencies:hE,subtractDependencies:Xp,sumDependencies:V3,typedDependencies:Pn,createCorr:Wb},j3={typedDependencies:Pn,createCos:l1},IV={typedDependencies:Pn,createCosh:FD},AV={BigNumberDependencies:To,typedDependencies:Pn,createCot:Tg},OV={BigNumberDependencies:To,typedDependencies:Pn,createCoth:jd},FV={BigNumberDependencies:To,UnitDependencies:ul,createCoulomb:ju},CB={multiplyScalarDependencies:Yp,numericDependencies:rx,typedDependencies:Pn,createProd:$d},NV={prodDependencies:CB,sizeDependencies:Dv,typedDependencies:Pn,createCount:n_},RV={UnitDependencies:ul,typedDependencies:Pn,createCreateUnit:mv},LV={matrixDependencies:t,multiplyDependencies:td,subtractDependencies:Xp,typedDependencies:Pn,createCross:v_},kV={BigNumberDependencies:To,typedDependencies:Pn,createCsc:Vd},PV={BigNumberDependencies:To,typedDependencies:Pn,createCsch:T1},JP={matrixDependencies:t,typedDependencies:Pn,createTranspose:Hg},U3={conjDependencies:IN,transposeDependencies:JP,typedDependencies:Pn,createCtranspose:Pa},BV={typedDependencies:Pn,createCube:A0},$3={numericDependencies:rx,typedDependencies:Pn,createUnaryPlus:_y},VV={addDependencies:o,typedDependencies:Pn,unaryPlusDependencies:$3,createCumSum:xy},jV={addDependencies:o,typedDependencies:Pn,unaryPlusDependencies:$3,createCumSumTransform:mA},W3={equalDependencies:ox,typedDependencies:Pn,createDeepEqual:mc},DB={ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,parseDependencies:bM,typedDependencies:Pn,createResolve:Xw},H3={bignumberDependencies:eD,fractionDependencies:bk,AccessorNodeDependencies:j,ArrayNodeDependencies:wu,ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,IndexNodeDependencies:xk,ObjectNodeDependencies:Sk,OperatorNodeDependencies:wA,SymbolNodeDependencies:aO,matrixDependencies:t,typedDependencies:Pn,createSimplifyConstant:sM},z3={AccessorNodeDependencies:j,ArrayNodeDependencies:wu,ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,IndexNodeDependencies:xk,ObjectNodeDependencies:Sk,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,SymbolNodeDependencies:aO,addDependencies:o,divideDependencies:_g,equalDependencies:ox,isZeroDependencies:pE,multiplyDependencies:td,parseDependencies:bM,powDependencies:ax,subtractDependencies:Xp,typedDependencies:Pn,createSimplifyCore:PI},F3={bignumberDependencies:eD,fractionDependencies:bk,AccessorNodeDependencies:j,ArrayNodeDependencies:wu,ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,IndexNodeDependencies:xk,ObjectNodeDependencies:Sk,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,SymbolNodeDependencies:aO,addDependencies:o,divideDependencies:_g,equalDependencies:ox,isZeroDependencies:pE,matrixDependencies:t,multiplyDependencies:td,parseDependencies:bM,powDependencies:ax,resolveDependencies:DB,simplifyConstantDependencies:H3,simplifyCoreDependencies:z3,subtractDependencies:Xp,typedDependencies:Pn,createSimplify:VI},UV={ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,SymbolNodeDependencies:aO,equalDependencies:ox,isZeroDependencies:pE,numericDependencies:rx,parseDependencies:bM,simplifyDependencies:F3,typedDependencies:Pn,createDerivative:YC},$V={BigNumberDependencies:To,UnitDependencies:ul,createDeuteronMass:Qo},wB={DenseMatrixDependencies:Fl,SparseMatrixDependencies:fE,matrixDependencies:t,typedDependencies:Pn,createDiag:i_},WV={matrixDependencies:t,numberDependencies:DA,subtractDependencies:Xp,typedDependencies:Pn,createDiff:Sy},HV={bignumberDependencies:eD,matrixDependencies:t,numberDependencies:DA,subtractDependencies:Xp,typedDependencies:Pn,createDiffTransform:t1},zV={absDependencies:Cv,addScalarDependencies:r,deepEqualDependencies:W3,divideScalarDependencies:rp,multiplyScalarDependencies:Yp,sqrtDependencies:hE,subtractScalarDependencies:sx,typedDependencies:Pn,createDistance:gb},e3={DenseMatrixDependencies:Fl,concatDependencies:n,divideScalarDependencies:rp,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createDotDivide:Kg},GV={concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,typedDependencies:Pn,createDotMultiply:Mb},KV={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,powDependencies:ax,typedDependencies:Pn,createDotPow:iu},xB={BigNumberDependencies:To,createE:qs},qV={BigNumberDependencies:To,createEfimovFactor:Ue},t3={typedDependencies:Pn,createFlatten:$m},G3={typedDependencies:Pn,createIm:Og},K3={flattenDependencies:t3,matrixDependencies:t,sizeDependencies:Dv,typedDependencies:Pn,createMatrixFromColumns:Oa},SB={BigNumberDependencies:To,FractionDependencies:CA,complexDependencies:O3,typedDependencies:Pn,createSign:Hm},q3={addScalarDependencies:r,complexDependencies:O3,conjDependencies:IN,divideScalarDependencies:rp,equalDependencies:ox,identityDependencies:rO,isZeroDependencies:pE,matrixDependencies:t,multiplyScalarDependencies:Yp,signDependencies:SB,sqrtDependencies:hE,subtractScalarDependencies:sx,typedDependencies:Pn,unaryMinusDependencies:_M,zerosDependencies:f,createQr:mm},Q3={typedDependencies:Pn,createRe:SD},EB={isIntegerDependencies:v,matrixDependencies:t,typedDependencies:Pn,createReshape:Zu},N3={typedDependencies:Pn,createSin:lm},Y3={DenseMatrixDependencies:Fl,divideScalarDependencies:rp,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,subtractScalarDependencies:sx,typedDependencies:Pn,createUsolve:yy},TB={DenseMatrixDependencies:Fl,divideScalarDependencies:rp,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,subtractScalarDependencies:sx,typedDependencies:Pn,createUsolveAll:Fs},MB={absDependencies:Cv,addDependencies:o,addScalarDependencies:r,atanDependencies:rB,bignumberDependencies:eD,columnDependencies:hB,complexDependencies:O3,cosDependencies:j3,diagDependencies:wB,divideScalarDependencies:rp,dotDependencies:M3,equalDependencies:ox,flattenDependencies:t3,imDependencies:G3,invDependencies:AN,largerDependencies:_0,matrixDependencies:t,matrixFromColumnsDependencies:K3,multiplyDependencies:td,multiplyScalarDependencies:Yp,numberDependencies:DA,qrDependencies:q3,reDependencies:Q3,reshapeDependencies:EB,sinDependencies:N3,sizeDependencies:Dv,smallerDependencies:y0,sqrtDependencies:hE,subtractDependencies:Xp,typedDependencies:Pn,usolveDependencies:Y3,usolveAllDependencies:TB,createEigs:jb},QV={BigNumberDependencies:To,UnitDependencies:ul,createElectricConstant:Td},YV={BigNumberDependencies:To,UnitDependencies:ul,createElectronMass:rr},XV={BigNumberDependencies:To,UnitDependencies:ul,createElementaryCharge:Yl},ZV={compareTextDependencies:mB,isZeroDependencies:pE,typedDependencies:Pn,createEqualText:Qs},JV={typedDependencies:Pn,createErf:Q_},X3={parseDependencies:bM,typedDependencies:Pn,createEvaluate:BI},IB={typedDependencies:Pn,createExp:F0},ej={absDependencies:Cv,addDependencies:o,identityDependencies:rO,invDependencies:AN,multiplyDependencies:td,typedDependencies:Pn,createExpm:S_},tj={ComplexDependencies:pd,typedDependencies:Pn,createExpm1:Um},nj={createFalse:md},ij={BigNumberDependencies:To,UnitDependencies:ul,createFaraday:Ut},rj={BigNumberDependencies:To,UnitDependencies:ul,createFermiCoupling:or},AB={ComplexDependencies:pd,createI:id},OB={ComplexDependencies:pd,typedDependencies:Pn,createLog2:hl},FB={BigNumberDependencies:To,createTau:Lc},NB={addScalarDependencies:r,ceilDependencies:k3,conjDependencies:IN,divideScalarDependencies:rp,dotDivideDependencies:e3,expDependencies:IB,iDependencies:AB,log2Dependencies:OB,matrixDependencies:t,multiplyScalarDependencies:Yp,powDependencies:ax,tauDependencies:FB,typedDependencies:Pn,createFft:dd},RB={largerDependencies:_0,smallerDependencies:y0,createFibonacciHeapClass:Ib},oj={typedDependencies:Pn,createFilter:mD},sj={typedDependencies:Pn,createFilterTransform:lA},aj={BigNumberDependencies:To,createFineStructure:ia},lj={BigNumberDependencies:To,UnitDependencies:ul,createFirstRadiation:Rn},cj={typedDependencies:Pn,createForEach:Oh},uj={typedDependencies:Pn,createForEachTransform:G2},dj={ComplexDependencies:pd,addDependencies:o,divideDependencies:_g,matrixDependencies:t,multiplyDependencies:td,typedDependencies:Pn,createFreqz:c0},fj={BigNumberDependencies:To,UnitDependencies:ul,createGasConstant:Y},pj={BigNumberDependencies:To,DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,roundDependencies:Ck,typedDependencies:Pn,zerosDependencies:f,createGcd:eC},hj={BigNumberDependencies:To,UnitDependencies:ul,createGravitationConstant:kc},mj={BigNumberDependencies:To,UnitDependencies:ul,createGravity:Yr},gj={BigNumberDependencies:To,UnitDependencies:ul,createHartreeEnergy:La},vj={isNumericDependencies:MN,typedDependencies:Pn,createHasNumericValue:U1},LB={evaluateDependencies:X3,createHelpClass:aM},_j={HelpDependencies:LB,typedDependencies:Pn,createHelp:aA},yj={formatDependencies:XP,typedDependencies:Pn,createHex:Pv},bj={absDependencies:Cv,addScalarDependencies:r,divideScalarDependencies:rp,isPositiveDependencies:ON,multiplyScalarDependencies:Yp,smallerDependencies:y0,sqrtDependencies:hE,typedDependencies:Pn,createHypot:Ty},Cj={conjDependencies:IN,dotDivideDependencies:e3,fftDependencies:NB,typedDependencies:Pn,createIfft:hv},kB={IndexDependencies:V_,typedDependencies:Pn,createIndex:By},Dj={IndexDependencies:V_,getMatrixDataTypeDependencies:B3,createIndexTransform:gA},wj={BigNumberDependencies:To,createInfinity:gd},xj={absDependencies:Cv,addDependencies:o,addScalarDependencies:r,divideScalarDependencies:rp,equalScalarDependencies:Kl,flattenDependencies:t3,isNumericDependencies:MN,isZeroDependencies:pE,matrixDependencies:t,multiplyDependencies:td,multiplyScalarDependencies:Yp,smallerDependencies:y0,subtractDependencies:Xp,typedDependencies:Pn,createIntersect:og},Sj={BigNumberDependencies:To,UnitDependencies:ul,createInverseConductanceQuantum:hf},PB={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,roundDependencies:Ck,typedDependencies:Pn,zerosDependencies:f,createMod:Ey},BB={BigNumberDependencies:To,matrixDependencies:t,typedDependencies:Pn,createXgcd:Kr},Ej={BigNumberDependencies:To,addDependencies:o,equalDependencies:ox,isIntegerDependencies:v,modDependencies:PB,smallerDependencies:y0,typedDependencies:Pn,xgcdDependencies:BB,createInvmod:Cw},n3={typedDependencies:Pn,createIsNaN:M1},Tj={typedDependencies:Pn,createIsPrime:ND},Z3={ComplexDependencies:pd,divideScalarDependencies:rp,typedDependencies:Pn,createLog:u_},RN={typedDependencies:Pn,createMap:Ou},Mj={divideDependencies:_g,dotDivideDependencies:e3,isNumericDependencies:MN,logDependencies:Z3,mapDependencies:RN,matrixDependencies:t,multiplyDependencies:td,sumDependencies:V3,typedDependencies:Pn,createKldivergence:Ub},Ij={BigNumberDependencies:To,UnitDependencies:ul,createKlitzing:Re},Aj={matrixDependencies:t,multiplyScalarDependencies:Yp,typedDependencies:Pn,createKron:kh},Oj={BigNumberDependencies:To,createLN10:su},Fj={BigNumberDependencies:To,createLN2:Bu},Nj={BigNumberDependencies:To,createLOG10E:xa},Rj={BigNumberDependencies:To,createLOG2E:Is},Lj={concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createLcm:Vy},kj={parseDependencies:bM,typedDependencies:Pn,createLeafCount:$I},Pj={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createLeftShift:py},Bj={ComplexDependencies:pd,typedDependencies:Pn,createLgamma:B0},Vj={ComplexDependencies:pd,typedDependencies:Pn,createLog10:ty},jj={ComplexDependencies:pd,divideScalarDependencies:rp,logDependencies:Z3,typedDependencies:Pn,createLog1p:jy},Uj={BigNumberDependencies:To,UnitDependencies:ul,createLoschmidt:Kn},VB={DenseMatrixDependencies:Fl,divideScalarDependencies:rp,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,subtractScalarDependencies:sx,typedDependencies:Pn,createLsolve:my},$j={DenseMatrixDependencies:Fl,divideScalarDependencies:rp,equalScalarDependencies:Kl,matrixDependencies:t,multiplyScalarDependencies:Yp,subtractScalarDependencies:sx,typedDependencies:Pn,createLsolveAll:Ay},jB={FibonacciHeapDependencies:RB,addScalarDependencies:r,equalScalarDependencies:Kl,createSpaClass:C_},UB={DenseMatrixDependencies:Fl,SpaDependencies:jB,SparseMatrixDependencies:fE,absDependencies:Cv,addScalarDependencies:r,divideScalarDependencies:rp,equalScalarDependencies:Kl,largerDependencies:_0,matrixDependencies:t,multiplyScalarDependencies:Yp,subtractScalarDependencies:sx,typedDependencies:Pn,unaryMinusDependencies:_M,createLup:Gy},$B={SparseMatrixDependencies:fE,absDependencies:Cv,addDependencies:o,divideScalarDependencies:rp,largerDependencies:_0,largerEqDependencies:A3,multiplyDependencies:td,subtractDependencies:Xp,transposeDependencies:JP,typedDependencies:Pn,createSlu:h_},WB={DenseMatrixDependencies:Fl,lsolveDependencies:VB,lupDependencies:UB,matrixDependencies:t,sluDependencies:$B,typedDependencies:Pn,usolveDependencies:Y3,createLusolve:EC},J3={absDependencies:Cv,addDependencies:o,conjDependencies:IN,ctransposeDependencies:U3,eigsDependencies:MB,equalScalarDependencies:Kl,largerDependencies:_0,matrixDependencies:t,multiplyDependencies:td,powDependencies:ax,smallerDependencies:y0,sqrtDependencies:hE,typedDependencies:Pn,createNorm:ye},HB={identityDependencies:rO,matrixDependencies:t,multiplyDependencies:td,normDependencies:J3,qrDependencies:q3,subtractDependencies:Xp,typedDependencies:Pn,createSchur:yn},zB={absDependencies:Cv,addDependencies:o,concatDependencies:n,identityDependencies:rO,indexDependencies:kB,lusolveDependencies:WB,matrixDependencies:t,matrixFromColumnsDependencies:K3,multiplyDependencies:td,rangeDependencies:wk,schurDependencies:HB,subsetDependencies:D,subtractDependencies:Xp,transposeDependencies:JP,typedDependencies:Pn,createSylvester:jr},Wj={matrixDependencies:t,multiplyDependencies:td,sylvesterDependencies:zB,transposeDependencies:JP,typedDependencies:Pn,createLyap:mo},R3={compareDependencies:FN,isNaNDependencies:n3,isNumericDependencies:MN,typedDependencies:Pn,createPartitionSelect:Db},GB={addDependencies:o,compareDependencies:FN,divideDependencies:_g,partitionSelectDependencies:R3,typedDependencies:Pn,createMedian:wm},Hj={absDependencies:Cv,mapDependencies:RN,medianDependencies:GB,subtractDependencies:Xp,typedDependencies:Pn,createMad:zb},zj={BigNumberDependencies:To,UnitDependencies:ul,createMagneticConstant:kd},Gj={BigNumberDependencies:To,UnitDependencies:ul,createMagneticFluxQuantum:_e},Kj={typedDependencies:Pn,createMapTransform:K2},qj={isZeroDependencies:pE,matrixDependencies:t,typedDependencies:Pn,createMatrixFromFunction:cl},Qj={flattenDependencies:t3,matrixDependencies:t,sizeDependencies:Dv,typedDependencies:Pn,createMatrixFromRows:Oy},eB={largerDependencies:_0,numericDependencies:rx,typedDependencies:Pn,createMax:Uy},Yj={largerDependencies:_0,numericDependencies:rx,typedDependencies:Pn,createMaxTransform:tx},Xj={addDependencies:o,divideDependencies:_g,typedDependencies:Pn,createMeanTransform:uE},Zj={numericDependencies:rx,smallerDependencies:y0,typedDependencies:Pn,createMin:rC},Jj={numericDependencies:rx,smallerDependencies:y0,typedDependencies:Pn,createMinTransform:pA},e4={isNaNDependencies:n3,isNumericDependencies:MN,typedDependencies:Pn,createMode:np},t4={BigNumberDependencies:To,UnitDependencies:ul,createMolarMass:Si},n4={BigNumberDependencies:To,UnitDependencies:ul,createMolarMassC12:oi},r4={BigNumberDependencies:To,UnitDependencies:ul,createMolarPlanckConstant:Ce},o4={BigNumberDependencies:To,UnitDependencies:ul,createMolarVolume:ue},s4={addDependencies:o,divideDependencies:_g,factorialDependencies:ZP,isIntegerDependencies:v,isPositiveDependencies:ON,multiplyDependencies:td,typedDependencies:Pn,createMultinomial:Jy},a4={BigNumberDependencies:To,createNaN:Eu},l4={BigNumberDependencies:To,UnitDependencies:ul,createNeutronMass:ll},c4={BigNumberDependencies:To,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createNthRoot:nS},u4={ComplexDependencies:pd,divideScalarDependencies:rp,typedDependencies:Pn,createNthRoots:ng},d4={BigNumberDependencies:To,UnitDependencies:ul,createNuclearMagneton:Dt},f4={createNull:Ld},p4={formatDependencies:XP,typedDependencies:Pn,createOct:Lp},h4={BigNumberDependencies:To,matrixDependencies:t,typedDependencies:Pn,createOnes:ob},m4={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createOr:rv},g4={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createOrTransform:Q2},KB={evaluateDependencies:X3,createParserClass:Zb},v4={ParserDependencies:KB,typedDependencies:Pn,createParser:Zw},_4={factorialDependencies:ZP,typedDependencies:Pn,createPermutations:e0},y4={BigNumberDependencies:To,createPhi:Xc},tB={BigNumberDependencies:To,createPi:Pu},b4={typedDependencies:Pn,createPickRandom:v1},C4={ComplexDependencies:pd,addDependencies:o,ctransposeDependencies:U3,deepEqualDependencies:W3,divideScalarDependencies:rp,dotDependencies:M3,dotDivideDependencies:e3,equalDependencies:ox,invDependencies:AN,matrixDependencies:t,multiplyDependencies:td,typedDependencies:Pn,createPinv:Jl},D4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckCharge:Hl},w4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckConstant:El},x4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckLength:rs},S4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckMass:ls},E4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckTemperature:dc},T4={BigNumberDependencies:To,UnitDependencies:ul,createPlanckTime:Zo},qB={typedDependencies:Pn,createTypeOf:rf},M4={addDependencies:o,cbrtDependencies:dB,divideDependencies:_g,equalScalarDependencies:Kl,imDependencies:G3,isZeroDependencies:pE,multiplyDependencies:td,reDependencies:Q3,sqrtDependencies:hE,subtractDependencies:Xp,typeOfDependencies:qB,typedDependencies:Pn,unaryMinusDependencies:_M,createPolynomialRoot:t0},I4={typedDependencies:Pn,createPrint:$v},A4={addDependencies:o,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createPrintTransform:uA},O4={BigNumberDependencies:To,UnitDependencies:ul,createProtonMass:vs},F4={bignumberDependencies:eD,addDependencies:o,compareDependencies:FN,divideDependencies:_g,isIntegerDependencies:v,largerDependencies:_0,multiplyDependencies:td,partitionSelectDependencies:R3,smallerDependencies:y0,smallerEqDependencies:Dk,subtractDependencies:Xp,typedDependencies:Pn,createQuantileSeq:I_},N4={addDependencies:o,bignumberDependencies:eD,compareDependencies:FN,divideDependencies:_g,isIntegerDependencies:v,largerDependencies:_0,multiplyDependencies:td,partitionSelectDependencies:R3,smallerDependencies:y0,smallerEqDependencies:Dk,subtractDependencies:Xp,typedDependencies:Pn,createQuantileSeqTransform:l},R4={BigNumberDependencies:To,UnitDependencies:ul,createQuantumOfCirculation:Sa},L4={typedDependencies:Pn,createRandom:Lh},k4={typedDependencies:Pn,createRandomInt:fp},P4={createRangeClass:If},B4={bignumberDependencies:eD,matrixDependencies:t,addDependencies:o,isPositiveDependencies:ON,largerDependencies:_0,largerEqDependencies:A3,smallerDependencies:y0,smallerEqDependencies:Dk,typedDependencies:Pn,createRangeTransform:_A},V4={bignumberDependencies:eD,fractionDependencies:bk,AccessorNodeDependencies:j,ArrayNodeDependencies:wu,ConstantNodeDependencies:sO,FunctionNodeDependencies:lO,IndexNodeDependencies:xk,ObjectNodeDependencies:Sk,OperatorNodeDependencies:wA,ParenthesisNodeDependencies:NN,SymbolNodeDependencies:aO,addDependencies:o,divideDependencies:_g,equalDependencies:ox,isZeroDependencies:pE,matrixDependencies:t,multiplyDependencies:td,parseDependencies:bM,powDependencies:ax,simplifyDependencies:F3,simplifyConstantDependencies:H3,simplifyCoreDependencies:z3,subtractDependencies:Xp,typedDependencies:Pn,createRationalize:uM},j4={BigNumberDependencies:To,UnitDependencies:ul,createReducedPlanckConstant:uc},U4={createReplacer:io},$4={matrixDependencies:t,createResize:W1},W4={createReviver:YT},H4={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createRightArithShift:H1},z4={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createRightLogShift:d_},QB={BigNumberDependencies:To,DenseMatrixDependencies:Fl,SparseMatrixDependencies:fE,addScalarDependencies:r,cosDependencies:j3,matrixDependencies:t,multiplyScalarDependencies:Yp,normDependencies:J3,sinDependencies:N3,typedDependencies:Pn,unaryMinusDependencies:_M,createRotationMatrix:ht},G4={multiplyDependencies:td,rotationMatrixDependencies:QB,typedDependencies:Pn,createRotate:si},K4={IndexDependencies:V_,matrixDependencies:t,rangeDependencies:wk,typedDependencies:Pn,createRow:ym},q4={IndexDependencies:V_,matrixDependencies:t,rangeDependencies:wk,typedDependencies:Pn,createRowTransform:yA},Q4={BigNumberDependencies:To,UnitDependencies:ul,createRydberg:$o},Y4={BigNumberDependencies:To,createSQRT1_2:vd},X4={BigNumberDependencies:To,createSQRT2:Vu},Z4={BigNumberDependencies:To,createSackurTetrode:Ie},J4={BigNumberDependencies:To,typedDependencies:Pn,createSec:$0},e5={BigNumberDependencies:To,typedDependencies:Pn,createSech:Qv},t5={BigNumberDependencies:To,UnitDependencies:ul,createSecondRadiation:Ze},n5={DenseMatrixDependencies:Fl,IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetCartesian:Fb},YB={DenseMatrixDependencies:Fl,IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetDifference:Hh},r5={DenseMatrixDependencies:Fl,IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetDistinct:xw},XB={DenseMatrixDependencies:Fl,IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetIntersect:w_},o5={IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetIsSubset:Wh},s5={IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetMultiplicity:cd},a5={IndexDependencies:V_,compareNaturalDependencies:yM,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetPowerset:sg},l5={compareNaturalDependencies:yM,typedDependencies:Pn,createSetSize:Vb},ZB={IndexDependencies:V_,concatDependencies:n,setDifferenceDependencies:YB,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetSymDifference:hh},c5={IndexDependencies:V_,concatDependencies:n,setIntersectDependencies:XB,setSymDifferenceDependencies:ZB,sizeDependencies:Dv,subsetDependencies:D,typedDependencies:Pn,createSetUnion:fg},u5={typedDependencies:Pn,createSinh:ay},d5={absDependencies:Cv,addDependencies:o,bignumberDependencies:eD,divideDependencies:_g,isNegativeDependencies:oO,isPositiveDependencies:ON,largerDependencies:_0,mapDependencies:RN,matrixDependencies:t,maxDependencies:eB,multiplyDependencies:td,smallerDependencies:y0,subtractDependencies:Xp,typedDependencies:Pn,unaryMinusDependencies:_M,createSolveODE:IC},f5={compareDependencies:FN,compareNaturalDependencies:yM,matrixDependencies:t,typedDependencies:Pn,createSort:$f},p5={SparseMatrixDependencies:fE,typedDependencies:Pn,createSparse:Z0},h5={BigNumberDependencies:To,UnitDependencies:ul,createSpeedOfLight:Ed},m5={typedDependencies:Pn,createSplitUnit:kg},g5={absDependencies:Cv,addDependencies:o,identityDependencies:rO,invDependencies:AN,mapDependencies:RN,maxDependencies:eB,multiplyDependencies:td,sizeDependencies:Dv,sqrtDependencies:hE,subtractDependencies:Xp,typedDependencies:Pn,createSqrtm:pg},v5={typedDependencies:Pn,createSquare:TD},_5={typedDependencies:Pn,createSqueeze:Zv},nB={addDependencies:o,applyDependencies:ss,divideDependencies:_g,isNaNDependencies:n3,multiplyDependencies:td,subtractDependencies:Xp,typedDependencies:Pn,createVariance:A_},y5={mapDependencies:RN,sqrtDependencies:hE,typedDependencies:Pn,varianceDependencies:nB,createStd:g},b5={mapDependencies:RN,sqrtDependencies:hE,typedDependencies:Pn,varianceDependencies:nB,createStdTransform:ae},C5={BigNumberDependencies:To,UnitDependencies:ul,createStefanBoltzmann:kt},D5={typedDependencies:Pn,createString:G0},w5={addDependencies:o,matrixDependencies:t,typedDependencies:Pn,zerosDependencies:f,createSubsetTransform:hA},x5={addDependencies:o,numericDependencies:rx,typedDependencies:Pn,createSumTransform:vA},S5={OperatorNodeDependencies:wA,parseDependencies:bM,simplifyDependencies:F3,typedDependencies:Pn,createSymbolicEqual:fF},E5={typedDependencies:Pn,createTan:zv},T5={typedDependencies:Pn,createTanh:Vg},M5={BigNumberDependencies:To,UnitDependencies:ul,createThomsonCrossSection:Mc},I5={concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createTo:s_},A5={addDependencies:o,matrixDependencies:t,typedDependencies:Pn,createTrace:vm},O5={createTrue:Su},F5={DenseMatrixDependencies:Fl,concatDependencies:n,equalScalarDependencies:Kl,matrixDependencies:t,typedDependencies:Pn,createUnequal:Rb},N5={UnitDependencies:ul,typedDependencies:Pn,createUnitFunction:mh},R5={eDependencies:xB,createUppercaseE:pu},L5={piDependencies:tB,createUppercasePi:Sd},k5={BigNumberDependencies:To,UnitDependencies:ul,createVacuumImpedance:Pc},P5={addDependencies:o,applyDependencies:ss,divideDependencies:_g,isNaNDependencies:n3,multiplyDependencies:td,subtractDependencies:Xp,typedDependencies:Pn,createVarianceTransform:w},B5={createVersion:hu},V5={BigNumberDependencies:To,createWeakMixingAngle:yc},j5={BigNumberDependencies:To,UnitDependencies:ul,createWienDisplacement:rn},U5={DenseMatrixDependencies:Fl,concatDependencies:n,matrixDependencies:t,typedDependencies:Pn,createXor:Zg},$5={BigNumberDependencies:To,ComplexDependencies:pd,addDependencies:o,divideDependencies:_g,equalDependencies:ox,factorialDependencies:ZP,gammaDependencies:P3,isNegativeDependencies:oO,multiplyDependencies:td,piDependencies:tB,powDependencies:ax,sinDependencies:N3,smallerEqDependencies:Dk,subtractDependencies:Xp,typedDependencies:Pn,createZeta:x},W5={ComplexDependencies:pd,addDependencies:o,multiplyDependencies:td,numberDependencies:DA,typedDependencies:Pn,createZpk2tf:rg},H5=i,z5=S(1425);function JB(p,m){var b=e({},M,m);if("function"!=typeof Object.create)throw new Error("ES5 not supported by this JavaScript engine. Please load the es5-shim and es5-sham library for compatibility.");var _=function G5(p){var m=new z5;return p.on=m.on.bind(m),p.off=m.off.bind(m),p.once=m.once.bind(m),p.emit=m.emit.bind(m),p}({isNumber:ct,isComplex:un,isBigNumber:en,isBigInt:an,isFraction:vn,isUnit:Pt,isString:Ae,isArray:dt,isMatrix:ut,isCollection:Mt,isDenseMatrix:Wt,isSparseMatrix:It,isRange:Vn,isIndex:pn,isBoolean:Wn,isResultSet:ji,isHelp:An,isFunction:St,isDate:qt,isRegExp:Ht,isObject:on,isMap:Cn,isPartitionedMap:tn,isObjectWrappingMap:fi,isNull:Zn,isUndefined:Dn,isAccessorNode:gn,isArrayNode:Nn,isAssignmentNode:Yn,isBlockNode:cr,isConditionalNode:Ai,isConstantNode:Qi,isFunctionAssignmentNode:Ur,isFunctionNode:eo,isIndexNode:as,isNode:uo,isObjectNode:mi,isOperatorNode:ci,isParenthesisNode:yt,isRangeNode:hn,isRelationalNode:Gt,isSymbolNode:Gn,isChain:ri});_.config=nn(b,_.emit),_.expression={transform:{},mathWithTransform:{config:_.config}};var k={};function R(){for(var F=arguments.length,B=new Array(F),H=0;H<F;H++)B[H]=arguments[H];return _.typed.apply(_.typed,B)}R.isTypedFunction=Ff.isTypedFunction;var O=function K5(p,m,b,_){function C(be,we,Le){if(Le.wrap&&"function"==typeof we&&(we=function R(be){var we=function(){for(var de=[],Te=0,De=arguments.length;Te<De;Te++){var pe=arguments[Te];de[Te]=pe&&pe.valueOf()}return be.apply(b,de)};return be.transform&&(we.transform=be.transform),we}(we)),function B(be){return"function"==typeof be&&"string"==typeof be.signature}(we)&&(we=p(be,{[we.signature]:we})),p.isTypedFunction(b[be])&&p.isTypedFunction(we))return we=Le.override?p(be,we.signatures):p(b[be],we),b[be]=we,delete _[be],A(be,we),void b.emit("import",be,function(){return we});if(void 0===b[be]||Le.override)return b[be]=we,delete _[be],A(be,we),void b.emit("import",be,function(){return we});if(!Le.silent)throw new Error('Cannot import "'+be+'": already exists')}function A(be,we){we&&"function"==typeof we.transform?(b.expression.transform[be]=we.transform,H(be)&&(b.expression.mathWithTransform[be]=we.transform)):(delete b.expression.transform[be],H(be)&&(b.expression.mathWithTransform[be]=we))}function k(be){delete b.expression.transform[be],H(be)?b.expression.mathWithTransform[be]=b[be]:delete b.expression.mathWithTransform[be]}function O(be,we){var Le=arguments.length>2&&void 0!==arguments[2]?arguments[2]:be.fn;if(Le.includes("."))throw new Error("Factory name should not contain a nested path. Name: "+JSON.stringify(Le));var de=J(be)?b.expression.transform:b,Te=Le in b.expression.transform,De=Jt(de,Le)?de[Le]:void 0,pe=function(){var We={};be.dependencies.map(vi).forEach(ze=>{if(ze.includes("."))throw new Error("Factory dependency should not contain a nested path. Name: "+JSON.stringify(ze));"math"===ze?We.math=b:"mathWithTransform"===ze?We.mathWithTransform=b.expression.mathWithTransform:"classes"===ze?We.classes=b:We[ze]=b[ze]});var ke=be(We);if(ke&&"function"==typeof ke.transform)throw new Error('Transforms cannot be attached to factory functions. Please create a separate function for it with export const path = "expression.transform"');if(void 0===De||we.override)return ke;if(p.isTypedFunction(De)&&p.isTypedFunction(ke))return p(De,ke);if(we.silent)return De;throw new Error('Cannot import "'+Le+'": already exists')};be.meta&&!1===be.meta.lazy?(de[Le]=pe(),De&&Te?k(Le):(J(be)||G(be))&&Ii(b.expression.mathWithTransform,Le,()=>de[Le])):(Ii(de,Le,pe),De&&Te?k(Le):(J(be)||G(be))&&Ii(b.expression.mathWithTransform,Le,()=>de[Le])),_[Le]=be,b.emit("import",Le,pe)}function F(be){return"function"==typeof be||"number"==typeof be||"string"==typeof be||"boolean"==typeof be||null===be||Pt(be)||un(be)||en(be)||vn(be)||ut(be)||Array.isArray(be)}function H(be){return!Jt(te,be)}function G(be){return!(be.fn.includes(".")||Jt(te,be.fn)||be.meta&&be.meta.isClass)}function J(be){return void 0!==be&&void 0!==be.meta&&!0===be.meta.isTransformFunction||!1}var te={expression:!0,type:!0,docs:!0,error:!0,json:!0,chain:!0};return function y(be,we){var Le=arguments.length;if(1!==Le&&2!==Le)throw new af("import",Le,1,2);we||(we={});var Te={};for(var De in function de(Be,We,ke){if(Array.isArray(We))We.forEach(pt=>de(Be,pt));else if("object"==typeof We)for(var ze in We)Jt(We,ze)&&de(Be,We[ze],ze);else if(Qt(We)||void 0!==ke){var et=Qt(We)?J(We)?We.fn+".transform":We.fn:ke;if(Jt(Be,et)&&Be[et]!==We&&!we.silent)throw new Error('Cannot import "'+et+'" twice');Be[et]=We}else if(!we.silent)throw new TypeError("Factory, Object, or Array expected")}(Te,be),Te)if(Jt(Te,De)){var pe=Te[De];if(Qt(pe))O(pe,we);else if(F(pe))C(De,pe,we);else if(!we.silent)throw new TypeError("Factory, Object, or Array expected")}}}(R,0,_,k);return _.import=O,_.on("config",()=>{Object.values(k).forEach(F=>{F&&F.meta&&F.meta.recreateOnConfigChange&&O(F,{override:!0})})}),_.create=JB.bind(null,p),_.factory=re,_.import(Object.values(Ti(p))),_.ArgumentsError=af,_.DimensionError=va,_.IndexError=bc,_}},936:(Ot,Me,S)=>{S.r(Me),S.d(Me,{backInDown:()=>ar,backInLeft:()=>er,backInRight:()=>Or,backInUp:()=>Ui,backOutDown:()=>cn,backOutLeft:()=>Ri,backOutRight:()=>Tn,backOutUp:()=>Tt,bounce:()=>M,bounceIn:()=>wt,bounceInDown:()=>ct,bounceInLeft:()=>an,bounceInRight:()=>un,bounceInUp:()=>en,bounceInX:()=>fn,bounceInY:()=>ve,bounceOut:()=>vn,bounceOutDown:()=>dt,bounceOutLeft:()=>Mt,bounceOutRight:()=>Wt,bounceOutUp:()=>ut,bounceOutX:()=>Ae,bounceOutY:()=>Pt,fadeIn:()=>Wn,fadeInBottomLeft:()=>Dn,fadeInBottomRight:()=>gn,fadeInDown:()=>ji,fadeInDownBig:()=>An,fadeInLeft:()=>Ht,fadeInLeftBig:()=>on,fadeInRight:()=>Cn,fadeInRightBig:()=>tn,fadeInTopLeft:()=>fi,fadeInTopRight:()=>Zn,fadeInUp:()=>St,fadeInUpBig:()=>qt,fadeInX:()=>Vn,fadeInY:()=>pn,fadeOut:()=>cr,fadeOutBottomLeft:()=>hn,fadeOutBottomRight:()=>Gt,fadeOutDown:()=>Ai,fadeOutDownBig:()=>Qi,fadeOutLeft:()=>eo,fadeOutLeftBig:()=>as,fadeOutRight:()=>uo,fadeOutRightBig:()=>mi,fadeOutTopLeft:()=>ci,fadeOutTopRight:()=>yt,fadeOutUp:()=>Xr,fadeOutUpBig:()=>Ur,fadeOutX:()=>Nn,fadeOutY:()=>Yn,fadeXY:()=>It,flash:()=>X,flip:()=>Gi,flipIn:()=>Ii,flipInX:()=>Ki,flipInY:()=>Jt,flipOut:()=>hi,flipOutX:()=>Ft,flipOutY:()=>it,headShake:()=>Et,heartBeat:()=>je,hinge:()=>vl,jackInTheBox:()=>Na,jello:()=>le,lightSpeedIn:()=>Ve,lightSpeedInLeft:()=>sn,lightSpeedInRight:()=>He,lightSpeedOut:()=>mt,lightSpeedOutLeft:()=>nn,lightSpeedOutRight:()=>bt,pulse:()=>ie,rollIn:()=>_l,rollOut:()=>gs,rotateIn:()=>_r,rotateInDirection:()=>Jn,rotateInDownLeft:()=>qr,rotateInDownRight:()=>Bo,rotateInUpLeft:()=>Eo,rotateInUpRight:()=>Ro,rotateOut:()=>Ls,rotateOutDirection:()=>Sn,rotateOutDownLeft:()=>ol,rotateOutDownRight:()=>Va,rotateOutUpLeft:()=>Ao,rotateOutUpRight:()=>za,rubberBand:()=>Q,shake:()=>Ee,shakeX:()=>he,shakeY:()=>q,slideInDown:()=>At,slideInLeft:()=>Bn,slideInRight:()=>Mn,slideInUp:()=>pi,slideOutDown:()=>qn,slideOutLeft:()=>Ti,slideOutRight:()=>Bi,slideOutUp:()=>ni,slideX:()=>Gn,slideY:()=>ri,swing:()=>oe,tada:()=>Z,wobble:()=>ce,zoomIn:()=>Zs,zoomInDown:()=>xl,zoomInLeft:()=>dl,zoomInRight:()=>Ya,zoomInUp:()=>Qr,zoomInX:()=>no,zoomInY:()=>oa,zoomOut:()=>Lo,zoomOutDown:()=>In,zoomOutLeft:()=>jn,zoomOutRight:()=>Fi,zoomOutUp:()=>Rt,zoomOutX:()=>jt,zoomOutY:()=>ko});var i=S(2810);const e=1,M=(0,i.animation)([(0,i.style)({transform:"translate3d(0, 0, 0)"}),(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"translate3d(0, 0, 0)",offset:.2}),(0,i.style)({transform:"translate3d(0, -30px, 0)",offset:.4}),(0,i.style)({transform:"translate3d(0, 0, 0)",offset:.53}),(0,i.style)({transform:"translate3d(0, -15px, 0)",offset:.7}),(0,i.style)({transform:"translate3d(0, -4px, 0)",offset:.9}),(0,i.style)({transform:"translate3d(0, 0, 0)",offset:1})]))],{params:{timing:e,delay:0}}),X=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1}),(0,i.style)({opacity:0}),(0,i.style)({opacity:1}),(0,i.style)({opacity:0}),(0,i.style)({opacity:1})])),{params:{timing:e,delay:0}}),ie=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"scale3d(1, 1, 1)"}),(0,i.style)({transform:"scale3d({{ scale }}, {{ scale }}, {{ scale }})"}),(0,i.style)({transform:"scale3d(1, 1, 1)"})])),{params:{scale:1.25,timing:e,delay:0}}),Q=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"scale3d(1, 1, 1)",offset:0}),(0,i.style)({transform:"scale3d(1.25, 0.75, 1)",offset:.3}),(0,i.style)({transform:"scale3d(0.75, 1.25, 1)",offset:.4}),(0,i.style)({transform:"scale3d(1.15, 0.85, 1)",offset:.5}),(0,i.style)({transform:"scale3d(.95, 1.05, 1)",offset:.65}),(0,i.style)({transform:"scale3d(1.05, .95, 1)",offset:.75}),(0,i.style)({transform:"scale3d(1, 1, 1)",offset:1})])),{params:{timing:e,delay:0}}),Ee=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"translate3d(0, 0, 0)",offset:0}),(0,i.style)({transform:"translate3d({{ translateB }})",offset:.1}),(0,i.style)({transform:"translate3d({{ translateA }})",offset:.2}),(0,i.style)({transform:"translate3d({{ translateB }})",offset:.3}),(0,i.style)({transform:"translate3d({{ translateA }})",offset:.4}),(0,i.style)({transform:"translate3d({{ translateB }})",offset:.5}),(0,i.style)({transform:"translate3d({{ translateA }})",offset:.6}),(0,i.style)({transform:"translate3d({{ translateB }})",offset:.7}),(0,i.style)({transform:"translate3d({{ translateA }})",offset:.8}),(0,i.style)({transform:"translate3d({{ translateB }})",offset:.9}),(0,i.style)({transform:"translate3d(0, 0, 0)",offset:1})])),{params:{timing:e,delay:0,translateA:"-10px, 0, 0",translateB:"10px, 0, 0"}}),he=Ee,q=(0,i.useAnimation)(Ee,{params:{translateA:"0, -10px, 0",translateB:"0, 10px, 0"}}),oe=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"rotate3d(0, 0, 1, 15deg)",offset:.2}),(0,i.style)({transform:"rotate3d(0, 0, 1, -10deg)",offset:.4}),(0,i.style)({transform:"rotate3d(0, 0, 1, 5deg)",offset:.6}),(0,i.style)({transform:"rotate3d(0, 0, 1, -5deg)",offset:.8}),(0,i.style)({transform:"rotate3d(0, 0, 1, 0deg)",offset:1})])),{params:{timing:e,delay:0}}),Z=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"scale3d(1, 1, 1)",offset:0}),(0,i.style)({transform:"scale3d(.9, .9, .9) rotate3d(0, 0, 1, -3deg)",offset:.1}),(0,i.style)({transform:"scale3d(.9, .9, .9) rotate3d(0, 0, 1, -3deg)",offset:.2}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg)",offset:.3}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg)",offset:.4}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg)",offset:.5}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg)",offset:.6}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg)",offset:.7}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg)",offset:.8}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg)",offset:.9}),(0,i.style)({transform:"scale3d(1, 1, 1)",offset:1})])),{params:{timing:e,delay:0}}),ce=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"none",offset:0}),(0,i.style)({transform:"translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg)",offset:.15}),(0,i.style)({transform:"translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg)",offset:.3}),(0,i.style)({transform:"translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg)",offset:.45}),(0,i.style)({transform:"translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg)",offset:.6}),(0,i.style)({transform:"translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg)",offset:.75}),(0,i.style)({transform:"none",offset:1})])),{params:{timing:e,delay:0}}),le=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"none",offset:0}),(0,i.style)({transform:"none",offset:.11}),(0,i.style)({transform:"skewX(-12.5deg) skewY(-12.5deg)",offset:.22}),(0,i.style)({transform:"skewX(6.25deg) skewY(6.25deg)",offset:.33}),(0,i.style)({transform:"skewX(-3.125deg) skewY(-3.125deg)",offset:.44}),(0,i.style)({transform:"skewX(1.5625deg) skewY(1.5625deg)",offset:.55}),(0,i.style)({transform:"skewX(-0.78125deg) skewY(-0.78125deg)",offset:.66}),(0,i.style)({transform:"skewX(0.390625deg) skewY(0.390625deg)",offset:.77}),(0,i.style)({transform:"skewX(-0.1953125deg) skewY(-0.1953125deg)",offset:.88}),(0,i.style)({transform:"none",offset:1})])),{params:{timing:e,delay:0}}),je=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-in-out",(0,i.keyframes)([(0,i.style)({transform:"scale(1)",offset:0}),(0,i.style)({transform:"scale({{ scale }})",offset:.14}),(0,i.style)({transform:"scale(1)",offset:.28}),(0,i.style)({transform:"scale({{ scale }})",offset:.42}),(0,i.style)({transform:"scale(1)",offset:.7})])),{params:{timing:1.3*e,scale:1.3,delay:0}}),Et=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-in-out",(0,i.keyframes)([(0,i.style)({transform:"translateX(0)",offset:0}),(0,i.style)({transform:"translateX(-6px) rotateY(-9deg)",offset:.065}),(0,i.style)({transform:"translateX(5px) rotateY(7deg)",offset:.185}),(0,i.style)({transform:"translateX(-3px) rotateY(-5deg)",offset:.315}),(0,i.style)({transform:"translateX(2px) rotateY(3deg)",offset:.435}),(0,i.style)({transform:"translateX(0)",offset:.5})])),{params:{timing:e,delay:0}}),wt=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.215, 0.610, 0.355, 1.000)",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"scale3d(.3, .3, .3)",offset:0}),(0,i.style)({transform:"scale3d(1.1, 1.1, 1.1)",offset:.2}),(0,i.style)({transform:"scale3d(.9, .9, .9)",offset:.4}),(0,i.style)({opacity:1,transform:"scale3d(1.03, 1.03, 1.03)",offset:.6}),(0,i.style)({transform:"scale3d(.97, .97, .97)",offset:.8}),(0,i.style)({opacity:1,transform:"scale3d(1, 1, 1)",offset:1})])),{params:{timing:e,delay:0}});function ve(Un,Yi,Wi,fr){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.215, 0.610, 0.355, 1.000)",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"translate3d(0, {{ a }}, 0)",offset:0}),(0,i.style)({opacity:1,transform:"translate3d(0, {{ b }}, 0)",offset:.6}),(0,i.style)({transform:"translate3d(0, {{ c }}, 0)",offset:.75}),(0,i.style)({transform:"translate3d(0, {{ d }}, 0)",offset:.9}),(0,i.style)({opacity:1,transform:"none",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi,c:Wi,d:fr}})}function fn(Un,Yi,Wi,fr){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.215, 0.610, 0.355, 1.000)",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"translate3d({{ a }}, 0, 0)",offset:0}),(0,i.style)({opacity:1,transform:"translate3d({{ b }}, 0, 0)",offset:.6}),(0,i.style)({transform:"translate3d({{ c }}, 0, 0)",offset:.75}),(0,i.style)({transform:"translate3d({{ d }}, 0, 0)",offset:.9}),(0,i.style)({opacity:1,transform:"none",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi,c:Wi,d:fr}})}const ct=ve("-3000px","25px","-10px","5px"),en=ve("3000px","-25px","10px","-5px"),an=fn("-3000px","25px","-10px","5px"),un=fn("3000px","-25px","10px","-5px"),vn=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"scale3d(.9, .9, .9)",offset:.2}),(0,i.style)({opacity:1,transform:"scale3d({{ scale }}, {{ scale }}, {{ scale }})",offset:.5}),(0,i.style)({opacity:1,transform:"scale3d({{ scale }}, {{ scale }}, {{ scale }})",offset:.55}),(0,i.style)({opacity:0,transform:"scale3d(.3, .3, .3)",offset:1})])),{params:{timing:e,delay:0,scale:1.1}});function Pt(Un,Yi,Wi,fr){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"translate3d(0, {{ a }}, 0)",offset:.2}),(0,i.style)({opacity:1,transform:"translate3d(0, {{ b }}, 0)",offset:.4}),(0,i.style)({opacity:1,transform:"translate3d(0, {{ c }}, 0)",offset:.45}),(0,i.style)({opacity:0,transform:"translate3d(0, {{ d }}, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi,c:Wi,d:fr}})}function Ae(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"translate3d({{ a }}, 0, 0)",offset:.2}),(0,i.style)({opacity:0,transform:"translate3d({{ b }}, 0, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}const dt=Pt("10px","-20px","-20px","2000px"),ut=Pt("-10px","20px","20px","-2000px"),Mt=Ae("20px","-2000px"),Wt=Ae("-20px","2000px");function It(Un,Yi,Wi,fr,Li=0,Vo=1){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:"{{ fromOpacity }}",transform:"translate3d({{ fromX }}, {{ fromY }}, 0)",offset:0}),(0,i.style)({opacity:"{{ toOpacity }}",transform:"translate3d({{ toX }}, {{ toY }}, 0)",offset:1})])),{params:{timing:e,delay:0,fromX:Un,toX:Wi,fromY:Yi,toY:fr,fromOpacity:Li,toOpacity:Vo}})}function Vn(Un,Yi,Wi=0,fr=1){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:"{{ fromOpacity }}",transform:"translate3d({{ a }}, 0, 0)",offset:0}),(0,i.style)({opacity:"{{ toOpacity }}",transform:"translate3d({{ b }}, 0, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi,fromOpacity:Wi,toOpacity:fr}})}function pn(Un,Yi,Wi=0,fr=1){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:"{{ fromOpacity }}",transform:"translate3d(0, {{ a }}, 0)",offset:0}),(0,i.style)({opacity:"{{ toOpacity }}",transform:"translate3d(0, {{ b }}, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi,fromOpacity:Wi,toOpacity:fr}})}const Wn=Vn(0,0),ji=pn("-100%",0),An=pn("-2000px",0),St=pn("100%",0),qt=pn("2000px",0),Ht=Vn("-100%",0),on=Vn("-2000px",0),Cn=Vn("100%",0),tn=Vn("2000px",0),fi=It("-100%","-100%",0,0),Zn=It("100%","-100%",0,0),Dn=It("-100%","100%",0,0),gn=It("100%","100%",0,0);function Nn(Un,Yi){return Vn(Un,Yi,1,0)}function Yn(Un,Yi){return pn(Un,Yi,1,0)}const cr=Nn(0,0),Ai=Yn(0,"100%"),Qi=Yn(0,"2000px"),Xr=Yn(0,"-100%"),Ur=Yn(0,"-2000px"),eo=Nn(0,"-100%"),as=Nn(0,"-2000px"),uo=Nn(0,"100%"),mi=Nn(0,"2000px"),ci=It(0,0,"-100%","-100%",1,0),yt=It(0,0,"100%","-100%",1,0),hn=It(0,0,"-100%","100%",1,0),Gt=It(0,0,"100%","100%",1,0);function Gn(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"translate3d({{ a }}, 0, 0)",offset:0}),(0,i.style)({transform:"translate3d({{ b }}, 0, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}function ri(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"translate3d(0, {{ a }}, 0)",offset:0}),(0,i.style)({transform:"translate3d(0, {{ b }}, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}const pi=ri("-100%",0),At=ri("100%",0),Bn=Gn("-100%",0),Mn=Gn("100%",0),ni=ri(0,"-100%"),qn=ri(0,"100%"),Ti=Gn(0,"-100%"),Bi=Gn(0,"100%"),Gi=(0,i.animation)([(0,i.style)({"backface-visibility":"visible"}),(0,i.animate)("{{ timing }}s {{ delay }}s ease-out",(0,i.keyframes)([(0,i.style)({transform:"perspective(400px) rotate3d(0, 1, 0, -360deg)",offset:0}),(0,i.style)({transform:"perspective(400px) scale3d(1.5, 1.5, 1.5) rotate3d(0, 1, 0, -190deg)",offset:.4}),(0,i.style)({transform:"perspective(400px) scale3d(1.5, 1.5, 1.5) rotate3d(0, 1, 0, -170deg)",offset:.5}),(0,i.style)({transform:"perspective(400px) scale3d(.95, .95, .95)",offset:.8}),(0,i.style)({transform:"perspective(400px)",offset:1})]))],{params:{timing:e,delay:0}});function Ii(Un,Yi){return(0,i.animation)([(0,i.style)({"backface-visibility":"visible"}),(0,i.animate)("{{ timing }}s {{ delay }}s ease-in",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, 90deg)",offset:0}),(0,i.style)({opacity:1,transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, -20deg)",offset:.4}),(0,i.style)({transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, 10deg)",offset:.6}),(0,i.style)({transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, -5deg)",offset:.8}),(0,i.style)({transform:"perspective(400px) rotate3d(0, 0, 0, 0)",offset:1})]))],{params:{timing:e,delay:0,rotateX:Un,rotateY:Yi}})}const Ki=Ii(1,0),Jt=Ii(0,1);function hi(Un,Yi){return(0,i.animation)([(0,i.style)({"backface-visibility":"visible"}),(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({transform:"perspective(400px)",offset:0}),(0,i.style)({opacity:1,transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, -20deg)",offset:.3}),(0,i.style)({opacity:0,transform:"perspective(400px) rotate3d({{ rotateX }}, {{ rotateY }}, 0, 90deg)",offset:1})]))],{params:{timing:e,delay:0,rotateX:Un,rotateY:Yi}})}const Ft=hi(1,0),it=hi(0,1),sn=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-out",(0,i.keyframes)([(0,i.style)({transform:"translate3d(-100%, 0, 0) skewX(30deg)",opacity:0,offset:0}),(0,i.style)({transform:"skewX(-20deg)",opacity:1,offset:.6}),(0,i.style)({transform:"skewX(5deg)",offset:.8}),(0,i.style)({transform:"translate3d(0, 0, 0)",offset:1})])),{params:{timing:e,delay:0}}),Ve=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-out",(0,i.keyframes)([(0,i.style)({transform:"translate3d(100%, 0, 0) skewX(-30deg)",opacity:0,offset:0}),(0,i.style)({transform:"skewX(20deg)",opacity:1,offset:.6}),(0,i.style)({transform:"skewX(-5deg)",offset:.8}),(0,i.style)({transform:"translate3d(0, 0, 0)",offset:1})])),{params:{timing:e,delay:0}}),He=Ve,mt=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-in",(0,i.keyframes)([(0,i.style)({opacity:1,offset:0}),(0,i.style)({opacity:0,transform:"translate3d(100%, 0, 0) skewX(30deg)",offset:1})])),{params:{timing:e,delay:0}}),bt=mt,nn=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s ease-in",(0,i.keyframes)([(0,i.style)({opacity:1,offset:0}),(0,i.style)({opacity:0,transform:"translate3d(-100%, 0, 0) skewX(-30deg)",offset:1})])),{params:{timing:e,delay:0}});function Jn(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({"transform-origin":"{{ origin }}",opacity:"{{ fromOpacity }}",transform:"rotate3d(0, 0, 1, {{ degrees }})",offset:0}),(0,i.style)({"transform-origin":"{{ origin }}",opacity:"{{ toOpacity }}",transform:"none",offset:1})])),{params:{timing:e,delay:0,origin:Un,degrees:Yi,fromOpacity:0,toOpacity:1}})}function Sn(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({"transform-origin":"{{ origin }}",opacity:"{{ fromOpacity }}",transform:"none",offset:0}),(0,i.style)({"transform-origin":"{{ origin }}",opacity:"{{ toOpacity }}",transform:"rotate3d(0, 0, 1, {{ degrees }})",offset:1})])),{params:{timing:e,delay:0,origin:Un,degrees:Yi,fromOpacity:1,toOpacity:0}})}const _r=Jn("center","-200deg"),qr=Jn("left bottom","-45deg"),Bo=Jn("right bottom","45deg"),Eo=Jn("left bottom","45deg"),Ro=Jn("right bottom","-90deg"),Ls=Sn("center","200deg"),ol=Sn("left bottom","45deg"),Va=Sn("right bottom","-45deg"),Ao=Sn("left bottom","-45deg"),za=Sn("right bottom","90deg"),vl=(0,i.animation)([(0,i.style)({"transform-origin":"top left"}),(0,i.animate)("{{ timing }}s {{ delay }}s ease-in-out",(0,i.keyframes)([(0,i.style)({transform:"rotate3d(0, 0, 1, 80deg)",offset:.2}),(0,i.style)({transform:"rotate3d(0, 0, 1, 60deg)",offset:.4}),(0,i.style)({transform:"rotate3d(0, 0, 1, 80deg)",offset:.6}),(0,i.style)({opacity:1,transform:"rotate3d(0, 0, 1, 60deg)",offset:.8}),(0,i.style)({opacity:0,transform:"translate3d(0, 700px, 0)",offset:1})]))],{params:{timing:e,delay:0}}),Na=(0,i.animation)([(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"scale(0.1) rotate(30deg)","transform-origin":"center bottom",offset:0}),(0,i.style)({opacity:.5,transform:"rotate(-10deg)",offset:.5}),(0,i.style)({opacity:.7,transform:"rotate(3deg)",offset:.7}),(0,i.style)({opacity:1,transform:"scale(1)",offset:1})]))],{params:{timing:e,delay:0}}),_l=(0,i.animation)([(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"translate3d(-100%, 0, 0) rotate3d(0, 0, 1, -120deg)",offset:0}),(0,i.style)({opacity:1,transform:"none",offset:1})]))],{params:{timing:e,delay:0}}),gs=(0,i.animation)([(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,offset:0}),(0,i.style)({opacity:0,transform:"translate3d(100%, 0, 0) rotate3d(0, 0, 1, 120deg)",offset:1})]))],{params:{timing:e,delay:0}}),Zs=(0,i.animation)([(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"scale3d(.3, .3, .3)",offset:0}),(0,i.style)({opacity:1,transform:"scale3d(1, 1, 1)",offset:.5})]))],{params:{timing:e,delay:0}});function oa(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.550, 0.055, 0.675, 0.190)",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"scale3d(.1, .1, .1) translate3d(0, {{ a }}, 0)",offset:0}),(0,i.style)({opacity:1,transform:"scale3d(.475, .475, .475) translate3d(0, {{ b }}, 0)",offset:.6})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}function no(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.550, 0.055, 0.675, 0.190)",(0,i.keyframes)([(0,i.style)({opacity:0,transform:"scale3d(.1, .1, .1) translate3d({{ a }}, 0, 0)",offset:0}),(0,i.style)({opacity:1,transform:"scale3d(.475, .475, .475) translate3d({{ b }}, 0, 0)",offset:.6})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}const xl=oa("-1000px","10px"),Qr=oa("1000px","-10px"),dl=no("-1000px","10px"),Ya=no("1000px","-10px"),Lo=(0,i.animation)([(0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,offset:0}),(0,i.style)({opacity:0,transform:"scale3d(.3, .3, .3)",offset:.5}),(0,i.style)({opacity:0,offset:1})]))],{params:{timing:e,delay:0}});function ko(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.550, 0.055, 0.675, 0.190)",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale3d(.475, .475, .475) translate3d(0, {{ a }}, 0)",offset:.4}),(0,i.style)({opacity:0,transform:"scale3d(.1, .1, .1) translate3d(0, {{ b }}, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}function jt(Un,Yi){return(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s cubic-bezier(0.550, 0.055, 0.675, 0.190)",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale3d(.475, .475, .475) translate3d({{ a }}, 0, 0)",offset:.4}),(0,i.style)({opacity:0,transform:"scale3d(.1, .1, .1) translate3d({{ b }}, 0, 0)",offset:1})])),{params:{timing:e,delay:0,a:Un,b:Yi}})}const In=ko("-60px","2000px"),Rt=ko("60px","-2000px"),jn=jt("42px","-2000px"),Fi=jt("-42px","2000px"),Ui=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:.7,transform:"translateY(1200px) scale(0.7)",offset:0}),(0,i.style)({opacity:.7,transform:"translateY(0px) scale(0.7)",offset:.8}),(0,i.style)({opacity:1,transform:"scale(1)",offset:1})])),{params:{timing:e,delay:0}}),ar=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:.7,transform:"translateY(-1200px) scale(0.7)",offset:0}),(0,i.style)({opacity:.7,transform:"translateY(0px) scale(0.7)",offset:.8}),(0,i.style)({opacity:1,transform:"scale(1)",offset:1})])),{params:{timing:e,delay:0}}),er=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:.7,transform:"translateX(-2000px) scale(0.7)",offset:0}),(0,i.style)({opacity:.7,transform:"translateX(0px) scale(0.7)",offset:.8}),(0,i.style)({opacity:1,transform:"scale(1)",offset:1})])),{params:{timing:e,delay:0}}),Or=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:.7,transform:"translateX(2000px) scale(0.7)",offset:0}),(0,i.style)({opacity:.7,transform:"translateX(0px) scale(0.7)",offset:.8}),(0,i.style)({opacity:1,transform:"scale(1)",offset:1})])),{params:{timing:e,delay:0}}),Tt=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale(1)"}),(0,i.style)({opacity:.7,transform:"translateY(0px) scale(0.7)"}),(0,i.style)({opacity:.7,transform:"translateY(-700px) scale(0.7)"})])),{params:{timing:e,delay:0}}),cn=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale(1)"}),(0,i.style)({opacity:.7,transform:"translateY(0px) scale(0.7)"}),(0,i.style)({opacity:.7,transform:"translateY(700px) scale(0.7)"})])),{params:{timing:e,delay:0}}),Tn=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale(1)"}),(0,i.style)({opacity:.7,transform:"translateX(0px) scale(0.7)"}),(0,i.style)({opacity:.7,transform:"translateX(2000px) scale(0.7)"})])),{params:{timing:e,delay:0}}),Ri=(0,i.animation)((0,i.animate)("{{ timing }}s {{ delay }}s",(0,i.keyframes)([(0,i.style)({opacity:1,transform:"scale(1)"}),(0,i.style)({opacity:.7,transform:"translateX(0px) scale(0.7)"}),(0,i.style)({opacity:.7,transform:"translateX(-2000px) scale(0.7)"})])),{params:{timing:e,delay:0}})},9664:(Ot,Me,S)=>{S.r(Me),S.d(Me,{DeleteIconComponent:()=>ni,HighlightPipe:()=>Nn,TagComponent:()=>Bi,TagInputComponent:()=>Jt,TagInputDropdown:()=>Ii,TagInputForm:()=>Bn,TagInputModule:()=>Ft,TagRipple:()=>Mn});var i=S(4523),e=S(1270),M=S(1738),X=S(2168),ie=S(2810);const Q=["*"];function Ee(it,sn){1&it&&(e.\u0275\u0275elementStart(0,"span",3),e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(1,"svg",4),e.\u0275\u0275element(2,"path",5)(3,"g")(4,"g")(5,"g")(6,"g")(7,"g")(8,"g"),e.\u0275\u0275elementEnd()())}function he(it,sn){if(1&it){const Ve=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",2),e.\u0275\u0275listener("click",function(){e.\u0275\u0275restoreView(Ve);const mt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(mt.hide())}),e.\u0275\u0275elementEnd()}}const q=[[["ng2-dropdown-button"]],[["ng2-dropdown-menu"]]],oe=["ng2-dropdown-button","ng2-dropdown-menu"];let Z=(()=>{class it{constructor(Ve){this.element=Ve,this.onMenuToggled=new e.EventEmitter,this.showCaret=!0}toggleMenu(){this.onMenuToggled.emit(!0)}getPosition(){return this.element.nativeElement.getBoundingClientRect()}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(e.ElementRef))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["ng2-dropdown-button"]],inputs:{showCaret:"showCaret"},outputs:{onMenuToggled:"onMenuToggled"},ngContentSelectors:Q,decls:4,vars:1,consts:[["type","button","tabindex","0s",1,"ng2-dropdown-button",3,"click"],[1,"ng2-dropdown-button__label"],["class","ng2-dropdown-button__caret",4,"ngIf"],[1,"ng2-dropdown-button__caret"],["enable-background","new 0 0 32 32","height","16px","id","\u0421\u043b\u043e\u0439_1","version","1.1","viewBox","0 0 32 32","width","16px",0,"xml","space","preserve","xmlns","http://www.w3.org/2000/svg",0,"xmlns","xlink","http://www.w3.org/1999/xlink"],["d","M24.285,11.284L16,19.571l-8.285-8.288c-0.395-0.395-1.034-0.395-1.429,0 c-0.394,0.395-0.394,1.035,0,1.43l8.999,9.002l0,0l0,0c0.394,0.395,1.034,0.395,1.428,0l8.999-9.002 c0.394-0.395,0.394-1.036,0-1.431C25.319,10.889,24.679,10.889,24.285,11.284z","fill","#121313","id","Expand_More"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"button",0),e.\u0275\u0275listener("click",function(){return He.toggleMenu()}),e.\u0275\u0275elementStart(1,"span",1),e.\u0275\u0275projection(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,Ee,9,0,"span",2),e.\u0275\u0275elementEnd()),2&Ve&&(e.\u0275\u0275advance(3),e.\u0275\u0275property("ngIf",He.showCaret))},dependencies:[X.NgIf],styles:[".ng2-dropdown-button[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,Helvetica,Arial;background:#fff;padding:.45rem .25rem;font-size:14px;letter-spacing:.08rem;color:#444;outline:0;cursor:pointer;font-weight:400;border:none;border-bottom:1px solid #efefef;text-align:left;min-width:100px;width:100%;display:flex;flex-direction:row;max-width:150px}.ng2-dropdown-button[_ngcontent-%COMP%]:hover{color:#222}.ng2-dropdown-button[_ngcontent-%COMP%]:active, .ng2-dropdown-button[_ngcontent-%COMP%]:focus{color:#222;border-bottom:2px solid #2196F3}.ng2-dropdown-button__label[_ngcontent-%COMP%]{flex:1 1 95%}.ng2-dropdown-button__caret[_ngcontent-%COMP%]{width:12px;height:12px;display:flex;flex:1 1 6%}.ng2-dropdown-button--icon[_nghost-%COMP%] .ng2-dropdown-button[_ngcontent-%COMP%], .ng2-dropdown-button--icon [_nghost-%COMP%] .ng2-dropdown-button[_ngcontent-%COMP%]{border:none;min-width:40px;width:40px;border-radius:100%;transition:all .2s;text-align:center;height:40px;padding:.5em}.ng2-dropdown-button--icon[_nghost-%COMP%] .ng2-dropdown-button[_ngcontent-%COMP%]:active, .ng2-dropdown-button--icon [_nghost-%COMP%] .ng2-dropdown-button[_ngcontent-%COMP%]:active{background:rgba(0,0,0,.2)}"]}),it})();const ce_BACKSPACE=9,ce_PREV=38,ce_NEXT=40,ce_ENTER=13,ce_ESCAPE=27,fn={[ce_BACKSPACE]:(it,sn,Ve)=>{Ve.select(it<sn.length-1?sn[it+1]:sn[0],!0)},[ce_PREV]:(it,sn,Ve)=>{it>0&&Ve.select(sn[it-1],!0)},[ce_NEXT]:(it,sn,Ve)=>{it<sn.length-1&&Ve.select(sn[it+1],!0)},[ce_ENTER]:(it,sn,Ve)=>Ve.selectedItem?Ve.selectedItem.click():void 0,[ce_ESCAPE]:function wt(){this.hide()}};function ct(it){[38,40].indexOf(it.keyCode)>-1&&it.preventDefault()}class en{constructor(){this.onItemSelected=new e.EventEmitter,this.onItemClicked=new e.EventEmitter,this.onItemDestroyed=new e.EventEmitter}get selectedItem(){return this._selectedItem}select(sn,Ve=!0){this._selectedItem=sn,Ve&&sn&&(sn.focus(),this.onItemSelected.emit(sn))}unselect(){this._selectedItem=void 0}}let an=(()=>{class it{constructor(){this.menuState={isVisible:!1,toString(){return!0===this.isVisible?"visible":"hidden"}},this.dropdownState=new en}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275prov=e.\u0275\u0275defineInjectable({token:it,factory:it.\u0275fac}),it})(),un=(()=>{class it{constructor(Ve,He){this.state=Ve,this.element=He,this.preventClose=!1}ngOnDestroy(){this.state.dropdownState.onItemDestroyed.emit(this)}get isSelected(){return this===this.state.dropdownState.selectedItem}select(Ve){this.state.dropdownState.select(this,!0),Ve&&(Ve.stopPropagation(),Ve.preventDefault())}click(){this.state.dropdownState.onItemClicked.emit(this)}focus(){this.element.nativeElement.children[0].focus()}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(an),e.\u0275\u0275directiveInject(e.ElementRef))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["ng2-menu-item"]],inputs:{preventClose:"preventClose",value:"value"},ngContentSelectors:Q,decls:2,vars:2,consts:[["role","button","tabindex","0",1,"ng2-menu-item",3,"keydown.enter","click","mouseover"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275listener("keydown.enter",function(){return He.click()})("click",function(){return He.click()})("mouseover",function(){return He.select()}),e.\u0275\u0275projection(1),e.\u0275\u0275elementEnd()),2&Ve&&e.\u0275\u0275classProp("ng2-menu-item--selected",He.isSelected)},styles:[".ng2-menu-item[_ngcontent-%COMP%]{font-family:Roboto,Helvetica Neue,Helvetica,Arial;background:#fff;color:#000000de;cursor:pointer;font-size:.9em;text-transform:none;font-weight:400;letter-spacing:.03em;height:48px;line-height:48px;padding:.3em 1.25rem;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;transition:background .25s}.ng2-menu-item--selected[_ngcontent-%COMP%]{background:rgba(158,158,158,.2);outline:0}.ng2-menu-item[_ngcontent-%COMP%]:focus{outline:0}.ng2-menu-item[_ngcontent-%COMP%]:active{background:rgba(158,158,158,.4)}ng2-menu-item[_nghost-%COMP%] [ng2-menu-item-icon]{vertical-align:middle;font-size:28px;width:1.5em;height:30px;color:#00000070}"]}),it})(),vn=(()=>{class it{constructor(Ve,He,mt){this.dropdownState=Ve,this.element=He,this.renderer=mt,this.width=4,this.focusFirstElement=!0,this.appendToBody=!0,this.zIndex=1e3,this.listeners={arrowHandler:void 0,handleKeypress:void 0}}show(Ve,He=!0){const mt=typeof document<"u"?document:void 0,bt=typeof window<"u"?window:void 0;this.dropdownState.menuState.isVisible||(this.listeners.handleKeypress=this.renderer.listen(mt.body,"keydown",this.handleKeypress.bind(this)),this.listeners.arrowHandler=this.renderer.listen(bt,"keydown",ct)),this.dropdownState.menuState.isVisible=!0,Ve&&this.updatePosition(Ve,He)}hide(){this.dropdownState.menuState.isVisible=!1,this.dropdownState.dropdownState.unselect(),this.listeners.arrowHandler&&this.listeners.arrowHandler(),this.listeners.handleKeypress&&this.listeners.handleKeypress()}updatePosition(Ve,He){this.position=Ve,this.updateOnChange(He)}handleKeypress(Ve){const He=Ve.keyCode,mt=this.items.toArray(),bt=mt.indexOf(this.dropdownState.dropdownState.selectedItem);fn.hasOwnProperty(He)&&fn[He].call(this,bt,mt,this.dropdownState.dropdownState)}getMenuElement(){return this.element.nativeElement.children[0]}calcPositionOffset(Ve){const He=typeof window<"u"?window:void 0,mt=typeof document<"u"?document:void 0;if(!He||!mt||!Ve)return;const bt=this.getMenuElement(),nn=void 0!==He.pageXOffset,Jn="CSS1Compat"===(mt.compatMode||""),Sn=nn?He.pageXOffset:Jn?mt.documentElement.scrollLeft:mt.body.scrollLeft,_r=nn?He.pageYOffset:Jn?mt.documentElement.scrollTop:mt.body.scrollTop;let{top:qr,left:Bo}=this.applyOffset(`${Ve.top+(this.appendToBody?_r-15:0)}px`,Ve.left+Sn-5+"px");const Eo=bt.clientWidth,Ro=bt.clientHeight,Ls=parseInt(qr)+Ro+(this.appendToBody?0:_r-15),ol=parseInt(Bo)+Eo,Ao=He.innerWidth+He.scrollX;if(Ls>=He.innerHeight+He.scrollY&&(qr=parseInt(qr.replace("px",""))-Ro+"px"),ol>=Ao){const za=ol-Ao+30;Bo=parseInt(Bo.replace("px",""))-za+"px"}return{top:qr,left:Bo}}applyOffset(Ve,He){if(!this.offset)return{top:Ve,left:He};const mt=this.offset.split(" ");return mt[1]||(mt[1]="0"),{top:Ve=`${parseInt(Ve.replace("px",""))+parseInt(mt[0])}px`,left:He=`${parseInt(He.replace("px",""))+parseInt(mt[1])}px`}}ngOnInit(){const Ve=typeof document<"u"?document:void 0;this.appendToBody&&Ve.body.appendChild(this.element.nativeElement)}updateOnChange(Ve=!0){const He=this.getMenuElement(),mt=this.calcPositionOffset(this.position);mt&&(this.renderer.setStyle(He,"top",mt.top.toString()),this.renderer.setStyle(He,"left",mt.left.toString())),this.focusFirstElement&&this.items.first&&!this.dropdownState.dropdownState.selectedItem&&this.dropdownState.dropdownState.select(this.items.first,!1)}ngOnDestroy(){const Ve=this.element.nativeElement;Ve.parentNode.removeChild(Ve),this.listeners.handleKeypress&&this.listeners.handleKeypress()}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(an),e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["ng2-dropdown-menu"]],contentQueries:function(Ve,He,mt){if(1&Ve&&e.\u0275\u0275contentQuery(mt,un,5),2&Ve){let bt;e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.items=bt)}},inputs:{width:"width",focusFirstElement:"focusFirstElement",offset:"offset",appendToBody:"appendToBody",zIndex:"zIndex"},ngContentSelectors:Q,decls:4,vars:12,consts:[[1,"ng2-dropdown-menu__options-container"],["class","ng2-dropdown-backdrop",3,"click",4,"ngIf"],[1,"ng2-dropdown-backdrop",3,"click"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"div")(1,"div",0),e.\u0275\u0275projection(2),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(3,he,1,0,"div",1)),2&Ve&&(e.\u0275\u0275classMapInterpolate1("ng2-dropdown-menu ng2-dropdown-menu---width--",He.width,""),e.\u0275\u0275styleProp("z-index",He.zIndex),e.\u0275\u0275classProp("ng2-dropdown-menu--inside-element",!He.appendToBody)("ng2-dropdown-menu--open",He.dropdownState.menuState.isVisible),e.\u0275\u0275property("@fade",He.dropdownState.menuState.toString()),e.\u0275\u0275advance(),e.\u0275\u0275property("@opacity",He.dropdownState.menuState.toString()),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",He.dropdownState.menuState.isVisible))},dependencies:[X.NgIf],styles:["[_nghost-%COMP%]{display:block}.ng2-dropdown-menu[_ngcontent-%COMP%]{overflow-y:auto;box-shadow:0 1px 2px #0000004d;position:absolute;padding:.5em 0;background:#fff;border-radius:1px;max-height:400px;width:260px;min-height:0;display:block}.ng2-dropdown-menu.ng2-dropdown-menu--inside-element[_ngcontent-%COMP%]{position:fixed}.ng2-dropdown-menu.ng2-dropdown-menu--width--2[_ngcontent-%COMP%]{width:200px}.ng2-dropdown-menu.ng2-dropdown-menu--width--4[_ngcontent-%COMP%]{width:260px}.ng2-dropdown-menu.ng2-dropdown-menu--width--6[_ngcontent-%COMP%]{width:320px}.ng2-dropdown-backdrop[_ngcontent-%COMP%]{position:fixed;top:0;left:0;width:100%;height:100%;z-index:1;overflow:hidden}[_nghost-%COMP%] .ng2-menu-divider{height:1px;min-height:1px;max-height:1px;width:100%;display:block;background:#f9f9f9}"],data:{animation:[(0,ie.trigger)("fade",[(0,ie.state)("visible",(0,ie.style)({opacity:1,height:"*",width:"*"})),(0,ie.state)("hidden",(0,ie.style)({opacity:0,overflow:"hidden",height:0,width:0})),(0,ie.transition)("hidden => visible",[(0,ie.animate)("250ms ease-in",(0,ie.style)({opacity:1,height:"*",width:"*"}))]),(0,ie.transition)("visible => hidden",[(0,ie.animate)("350ms ease-out",(0,ie.style)({opacity:0,width:0,height:0}))])]),(0,ie.trigger)("opacity",[(0,ie.transition)("hidden => visible",[(0,ie.animate)("450ms ease-in",(0,ie.keyframes)([(0,ie.style)({opacity:0,offset:0}),(0,ie.style)({opacity:1,offset:1})]))]),(0,ie.transition)("visible => hidden",[(0,ie.animate)("250ms ease-out",(0,ie.keyframes)([(0,ie.style)({opacity:1,offset:0}),(0,ie.style)({opacity:.5,offset:.3}),(0,ie.style)({opacity:0,offset:1})]))])])]}}),it})(),Pt=(()=>{class it{constructor(Ve){this.state=Ve,this.dynamicUpdate=!0,this.onItemClicked=new e.EventEmitter,this.onItemSelected=new e.EventEmitter,this.onShow=new e.EventEmitter,this.onHide=new e.EventEmitter}ngOnInit(){this.state.dropdownState.onItemClicked.subscribe(Ve=>{this.onItemClicked.emit(Ve),!Ve.preventClose&&this.hide.call(this)}),this.button&&this.button.onMenuToggled.subscribe(()=>{this.toggleMenu()}),this.state.dropdownState.onItemSelected.subscribe(Ve=>{this.onItemSelected.emit(Ve)}),this.state.dropdownState.onItemDestroyed.subscribe(Ve=>{let He;const mt=this.menu.items.toArray();Ve===this.state.dropdownState.selectedItem&&(this.menu.focusFirstElement&&(He=Ve===mt[0]&&mt.length>1?mt[1]:mt[0]),this.state.dropdownState.select(He))})}toggleMenu(Ve=this.button.getPosition()){this.state.menuState.isVisible?this.hide():this.show(Ve)}hide(){this.menu.hide(),this.onHide.emit(this)}show(Ve=this.button.getPosition()){this.menu.show(Ve,this.dynamicUpdate),this.onShow.emit(this)}scrollListener(){this.button&&this.dynamicUpdate&&this.menu.updatePosition(this.button.getPosition(),!0)}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(an))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["ng2-dropdown"]],contentQueries:function(Ve,He,mt){if(1&Ve&&(e.\u0275\u0275contentQuery(mt,Z,7),e.\u0275\u0275contentQuery(mt,vn,7)),2&Ve){let bt;e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.button=bt.first),e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.menu=bt.first)}},hostBindings:function(Ve,He){1&Ve&&e.\u0275\u0275listener("scroll",function(){return He.scrollListener()},!1,e.\u0275\u0275resolveWindow)},inputs:{dynamicUpdate:"dynamicUpdate"},outputs:{onItemClicked:"onItemClicked",onItemSelected:"onItemSelected",onShow:"onShow",onHide:"onHide"},features:[e.\u0275\u0275ProvidersFeature([an])],ngContentSelectors:oe,decls:3,vars:0,consts:[[1,"ng2-dropdown-container"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275projectionDef(q),e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275projection(1),e.\u0275\u0275projection(2,1),e.\u0275\u0275elementEnd())},encapsulation:2}),it})(),Ae=(()=>{class it{}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275mod=e.\u0275\u0275defineNgModule({type:it}),it.\u0275inj=e.\u0275\u0275defineInjector({imports:[[X.CommonModule]]}),it})();var dt=S(1647),ut=S(9335);const Mt=["input"],Wt=(it,sn)=>({item:it,index:sn});function It(it,sn){}function Vn(it,sn){if(1&it&&(e.\u0275\u0275elementStart(0,"div"),e.\u0275\u0275template(1,It,0,0,"ng-template",4),e.\u0275\u0275elementEnd()),2&it){const Ve=e.\u0275\u0275nextContext();e.\u0275\u0275attribute("contenteditable",Ve.editing),e.\u0275\u0275advance(),e.\u0275\u0275property("ngTemplateOutletContext",e.\u0275\u0275pureFunction2(3,Wt,Ve.model,Ve.index))("ngTemplateOutlet",Ve.template)}}function pn(it,sn){if(1&it){const Ve=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"delete-icon",8),e.\u0275\u0275listener("click",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext(2);return e.\u0275\u0275resetView(bt.remove(mt))}),e.\u0275\u0275elementEnd()}}function Wn(it,sn){if(1&it){const Ve=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"div",5)(1,"div",6),e.\u0275\u0275listener("keydown.enter",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.disableEditMode(mt))})("keydown.escape",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.disableEditMode(mt))})("click",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.editing?mt.stopPropagation():void 0)})("blur",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.onBlurred(mt))}),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,pn,1,0,"delete-icon",7),e.\u0275\u0275elementEnd()}if(2&it){const Ve=e.\u0275\u0275nextContext();e.\u0275\u0275advance(),e.\u0275\u0275attribute("contenteditable",Ve.editing)("title",Ve.getDisplayValue(Ve.model)),e.\u0275\u0275advance(),e.\u0275\u0275textInterpolate1(" ",Ve.getDisplayValue(Ve.model)," "),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",Ve.isDeleteIconVisible())}}function ji(it,sn){if(1&it&&e.\u0275\u0275element(0,"tag-ripple",9),2&it){const Ve=e.\u0275\u0275nextContext();e.\u0275\u0275property("state",Ve.rippleState),e.\u0275\u0275attribute("tabindex",-1)}}const An=(it,sn,Ve)=>({item:it,index:sn,last:Ve});function St(it,sn){if(1&it&&(e.\u0275\u0275element(0,"span",6),e.\u0275\u0275pipe(1,"highlight")),2&it){const Ve=e.\u0275\u0275nextContext().$implicit,He=e.\u0275\u0275nextContext();e.\u0275\u0275property("innerHTML",e.\u0275\u0275pipeBind2(1,1,Ve[He.displayBy],He.tagInput.inputForm.value.value),e.\u0275\u0275sanitizeHtml)}}function qt(it,sn){}function Ht(it,sn){if(1&it&&e.\u0275\u0275template(0,qt,0,0,"ng-template",7),2&it){const Ve=e.\u0275\u0275nextContext(),He=Ve.$implicit,mt=Ve.index,bt=Ve.last,nn=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngTemplateOutlet",nn.templates.first)("ngTemplateOutletContext",e.\u0275\u0275pureFunction3(2,An,He,mt,bt))}}function on(it,sn){if(1&it&&(e.\u0275\u0275elementStart(0,"ng2-menu-item",3),e.\u0275\u0275template(1,St,2,4,"span",4)(2,Ht,1,6,null,5),e.\u0275\u0275elementEnd()),2&it){const Ve=sn.$implicit,He=e.\u0275\u0275nextContext();e.\u0275\u0275property("value",Ve)("ngSwitch",!!He.templates.length),e.\u0275\u0275advance(),e.\u0275\u0275property("ngSwitchCase",!1)}}const Cn=["*"];function tn(it,sn){if(1&it){const Ve=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"tag",6),e.\u0275\u0275listener("onSelect",function(){const mt=e.\u0275\u0275restoreView(Ve).$implicit,bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.selectItem(mt))})("onRemove",function(){const mt=e.\u0275\u0275restoreView(Ve),bt=mt.$implicit,nn=mt.index,Jn=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(Jn.onRemoveRequested(bt,nn))})("onKeyDown",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.handleKeydown(mt))})("onTagEdited",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.updateEditedTag(mt))})("onBlur",function(mt){const bt=e.\u0275\u0275restoreView(Ve).index,nn=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(nn.onTagBlurred(mt,bt))})("dragstart",function(mt){const bt=e.\u0275\u0275restoreView(Ve),nn=bt.$implicit,Jn=bt.index,Sn=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(Sn.dragZone?Sn.onDragStarted(mt,nn,Jn):void 0)})("drop",function(mt){const bt=e.\u0275\u0275restoreView(Ve).index,nn=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(nn.dragZone?nn.onTagDropped(mt,bt):void 0)})("dragenter",function(mt){e.\u0275\u0275restoreView(Ve);const bt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(bt.dragZone?bt.onDragOver(mt):void 0)})("dragover",function(mt){const bt=e.\u0275\u0275restoreView(Ve).index,nn=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(nn.dragZone?nn.onDragOver(mt,bt):void 0)})("dragleave",function(){e.\u0275\u0275restoreView(Ve);const mt=e.\u0275\u0275nextContext();return e.\u0275\u0275resetView(mt.dragZone?mt.dragProvider.onDragEnd():void 0)}),e.\u0275\u0275elementEnd()}if(2&it){const Ve=sn.$implicit,He=sn.index,mt=e.\u0275\u0275nextContext();e.\u0275\u0275propertyInterpolate("draggable",mt.editable),e.\u0275\u0275property("canAddTag",mt.isTagValid)("disabled",mt.disable)("@animation",mt.animationMetadata)("hasRipple",mt.ripple)("index",He)("removable",mt.removable)("editable",mt.editable)("displayBy",mt.displayBy)("identifyBy",mt.identifyBy)("template",mt.hasCustomTemplate()?mt.templates.first:void 0)("draggable",mt.dragZone)("model",Ve),e.\u0275\u0275attribute("tabindex",0)}}function fi(it,sn){1&it&&e.\u0275\u0275element(0,"div",7)}function Zn(it,sn){if(1&it&&(e.\u0275\u0275elementStart(0,"p",10)(1,"span"),e.\u0275\u0275text(2),e.\u0275\u0275elementEnd()()),2&it){const Ve=sn.$implicit;e.\u0275\u0275advance(2),e.\u0275\u0275textInterpolate(Ve)}}function Dn(it,sn){if(1&it&&(e.\u0275\u0275elementStart(0,"div",8),e.\u0275\u0275template(1,Zn,3,1,"p",9),e.\u0275\u0275elementEnd()),2&it){const Ve=e.\u0275\u0275nextContext();e.\u0275\u0275property("ngClass",Ve.theme),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",Ve.errors)}}let Nn=(()=>{class it{transform(Ve,He){if(!He.trim())return Ve;try{const mt=new RegExp(`(${(it=>it.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))(He)})`,"i");return Ve.replace(mt,"<b>$1</b>")}catch{return Ve}}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275pipe=e.\u0275\u0275definePipe({name:"highlight",type:it,pure:!0}),it})();const Ai="keydown",Qi="keyup",as={8:"DELETE",46:"DELETE",37:"SWITCH_PREV",39:"SWITCH_NEXT",9:"TAB"},mi="NEXT",ci="PREV";let yt=(()=>{class it{constructor(){this.state={dragging:!1,dropping:!1,index:void 0}}setDraggedItem(Ve,He){Ve&&Ve.dataTransfer&&Ve.dataTransfer.setData("Text",JSON.stringify(He))}getDraggedItem(Ve){if(Ve&&Ve.dataTransfer){const He=Ve.dataTransfer.getData("Text");try{return JSON.parse(He)}catch{return}}}setSender(Ve){this.sender=Ve}setReceiver(Ve){this.receiver=Ve}onTagDropped(Ve,He,mt){this.onDragEnd(),this.sender.onRemoveRequested(Ve,He),this.receiver.onAddingRequested(!1,Ve,mt)}setState(Ve){this.state={...this.state,...Ve}}getState(Ve){return Ve?this.state[Ve]:this.state}onDragEnd(){this.setState({dragging:!1,dropping:!1,index:void 0})}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275prov=e.\u0275\u0275defineInjectable({token:it,factory:it.\u0275fac}),it})();const hn={tagInput:{separatorKeys:[],separatorKeyCodes:[],maxItems:1/0,placeholder:"+ Tag",secondaryPlaceholder:"Enter a new tag",validators:[],asyncValidators:[],onlyFromAutocomplete:!1,errorMessages:{},theme:"",onTextChangeDebounce:250,inputId:null,inputClass:"",clearOnBlur:!1,hideForm:!1,addOnBlur:!1,addOnPaste:!1,pasteSplitPattern:",",blinkIfDupe:!0,removable:!0,editable:!1,allowDupes:!1,modelAsStrings:!1,trimTags:!0,ripple:!0,tabIndex:"",disable:!1,dragZone:"",onRemoving:void 0,onAdding:void 0,displayBy:"display",identifyBy:"value",animationDuration:{enter:"250ms",leave:"150ms"}},dropdown:{displayBy:"display",identifyBy:"value",appendToBody:!0,offset:"50 0",focusFirstElement:!1,showDropdownIfEmpty:!1,minimumTextLength:1,limitItemsTo:1/0,keepOpen:!0,dynamicUpdate:!0,zIndex:1e3,matchingFn:function Gt(it,sn){const Ve=sn[this.displayBy].toString();return Ve&&Ve.toLowerCase().indexOf(it.toLowerCase())>=0}}};let Gn=(()=>{class it{setOptions(Ve){it.defaults.tagInput={...hn.tagInput,...Ve.tagInput},it.defaults.dropdown={...hn.dropdown,...Ve.dropdown}}}return it.defaults=hn,it})();function ri(it){return it===Object(it)}let pi=(()=>{class it{constructor(){this._items=[],this.displayBy=Gn.defaults.tagInput.displayBy,this.identifyBy=Gn.defaults.tagInput.identifyBy}get items(){return this._items}set items(Ve){this._items=Ve,this._onChangeCallback(this._items)}onTouched(){this._onTouchedCallback()}writeValue(Ve){this._items=Ve||[]}registerOnChange(Ve){this._onChangeCallback=Ve}registerOnTouched(Ve){this._onTouchedCallback=Ve}getItemValue(Ve,He=!1){const mt=He&&this.dropdown?this.dropdown.identifyBy:this.identifyBy;return ri(Ve)?Ve[mt]:Ve}getItemDisplay(Ve,He=!1){const mt=He&&this.dropdown?this.dropdown.displayBy:this.displayBy;return ri(Ve)?Ve[mt]:Ve}getItemsWithout(Ve){return this.items.filter((He,mt)=>mt!==Ve)}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275dir=e.\u0275\u0275defineDirective({type:it,inputs:{displayBy:"displayBy",identifyBy:"identifyBy"}}),it})();function At(it,sn,Ve=!0){if(!this.listeners.hasOwnProperty(it))throw new Error("The event entered may be wrong");Ve&&this.listeners[it].push(sn)}let Bn=(()=>{class it{constructor(){this.onSubmit=new e.EventEmitter,this.onBlur=new e.EventEmitter,this.onFocus=new e.EventEmitter,this.onKeyup=new e.EventEmitter,this.onKeydown=new e.EventEmitter,this.inputTextChange=new e.EventEmitter,this.validators=[],this.asyncValidators=[],this.tabindex="",this.disabled=!1,this.item=new M.FormControl({value:"",disabled:this.disabled})}get inputText(){return this.item.value}set inputText(Ve){this.item.setValue(Ve),this.inputTextChange.emit(Ve)}ngOnInit(){this.item.setValidators(this.validators),this.item.setAsyncValidators(this.asyncValidators),this.form=new M.FormGroup({item:this.item})}ngOnChanges(Ve){Ve.disabled&&!Ve.disabled.firstChange&&(Ve.disabled.currentValue?this.form.controls.item.disable():this.form.controls.item.enable())}get value(){return this.form.get("item")}isInputFocused(){const Ve=typeof document<"u"?document:void 0;return!!Ve&&Ve.activeElement===this.input.nativeElement}getErrorMessages(Ve){return Object.keys(Ve).filter(He=>this.value.hasError(He)).map(He=>Ve[He])}hasErrors(){const{dirty:Ve,value:He,valid:mt}=this.form;return Ve&&He.item&&!mt}focus(){this.input.nativeElement.focus()}blur(){this.input.nativeElement.blur()}getElementPosition(){return this.input.nativeElement.getBoundingClientRect()}destroy(){const Ve=this.input.nativeElement;Ve.parentElement.removeChild(Ve)}onKeyDown(Ve){if(this.inputText=this.value.value,"Enter"!==Ve.key)return this.onKeydown.emit(Ve);this.submit(Ve)}onKeyUp(Ve){return this.inputText=this.value.value,this.onKeyup.emit(Ve)}submit(Ve){Ve.preventDefault(),this.onSubmit.emit(Ve)}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["tag-input-form"]],viewQuery:function(Ve,He){if(1&Ve&&e.\u0275\u0275viewQuery(Mt,5),2&Ve){let mt;e.\u0275\u0275queryRefresh(mt=e.\u0275\u0275loadQuery())&&(He.input=mt.first)}},inputs:{placeholder:"placeholder",validators:"validators",asyncValidators:"asyncValidators",inputId:"inputId",inputClass:"inputClass",tabindex:"tabindex",disabled:"disabled",inputText:"inputText"},outputs:{onSubmit:"onSubmit",onBlur:"onBlur",onFocus:"onFocus",onKeyup:"onKeyup",onKeydown:"onKeydown",inputTextChange:"inputTextChange"},features:[e.\u0275\u0275NgOnChangesFeature],decls:3,vars:8,consts:[["input",""],[3,"ngSubmit","formGroup"],["type","text","autocomplete","off","minlength","1","formControlName","item",1,"ng2-tag-input__text-input",3,"focus","blur","keydown","keyup","tabindex","ngClass"]],template:function(Ve,He){if(1&Ve){const mt=e.\u0275\u0275getCurrentView();e.\u0275\u0275elementStart(0,"form",1),e.\u0275\u0275listener("ngSubmit",function(nn){return e.\u0275\u0275restoreView(mt),e.\u0275\u0275resetView(He.submit(nn))}),e.\u0275\u0275elementStart(1,"input",2,0),e.\u0275\u0275listener("focus",function(nn){return e.\u0275\u0275restoreView(mt),e.\u0275\u0275resetView(He.onFocus.emit(nn))})("blur",function(nn){return e.\u0275\u0275restoreView(mt),e.\u0275\u0275resetView(He.onBlur.emit(nn))})("keydown",function(nn){return e.\u0275\u0275restoreView(mt),e.\u0275\u0275resetView(He.onKeyDown(nn))})("keyup",function(nn){return e.\u0275\u0275restoreView(mt),e.\u0275\u0275resetView(He.onKeyUp(nn))}),e.\u0275\u0275elementEnd()()}2&Ve&&(e.\u0275\u0275property("formGroup",He.form),e.\u0275\u0275advance(),e.\u0275\u0275propertyInterpolate("tabindex",He.disabled?-1:He.tabindex?He.tabindex:0),e.\u0275\u0275property("ngClass",He.inputClass),e.\u0275\u0275attribute("id",He.inputId)("placeholder",He.placeholder)("aria-label",He.placeholder)("tabindex",He.tabindex)("disabled",He.disabled?He.disabled:null))},dependencies:[M.\u0275NgNoValidate,M.NgControlStatusGroup,M.FormGroupDirective,M.DefaultValueAccessor,M.MinLengthValidator,M.NgControlStatus,M.FormControlName,X.NgClass],styles:[".dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{box-shadow:0 0 0 1px #323232}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%]{background-color:#fff;display:inline-block;color:#555;vertical-align:middle;max-width:100%;height:42px;line-height:44px}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{border:none;box-shadow:none;outline:none;background-color:transparent;padding:0 6px;margin:0;width:auto;max-width:inherit}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-moz-placeholder{color:#777;opacity:1}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:-ms-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-webkit-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:focus{border:none;box-shadow:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #0006;border:1px solid #ccc}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #d9534f}.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;transition:all .25s;padding:.25rem 0;min-height:32px;cursor:text;border-bottom:2px solid #efefef}.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #2196F3}.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #f44336}.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.minimal.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:1px solid transparent}.minimal.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.minimal.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.minimal.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.minimal.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.minimal.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.dark.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #444}.dark.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.dark.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.dark.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.dark.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.dark.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #efefef}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #0275d8}.bootstrap.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #d9534f}.bootstrap.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;padding:4px;cursor:text;box-shadow:inset 0 1px 1px #00000013;border-radius:4px}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap3-info.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:1px solid #d9534f}.bootstrap3-info.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.error-message[_ngcontent-%COMP%]{font-size:.8em;color:#f44336;margin:.5em 0 0}.bootstrap[_ngcontent-%COMP%] .error-message[_ngcontent-%COMP%]{color:#d9534f}.ng2-tag-input__text-input[_ngcontent-%COMP%]{display:inline;vertical-align:middle;border:none;padding:0 .5rem;height:38px;font-size:1em;font-family:Roboto,Helvetica Neue,sans-serif}.ng2-tag-input__text-input[_ngcontent-%COMP%]:focus{outline:0}.ng2-tag-input__text-input[disabled=true][_ngcontent-%COMP%]{opacity:.5;background:#fff}"]}),it})(),Mn=(()=>{class it{constructor(){this.state="none"}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["tag-ripple"]],inputs:{state:"state"},decls:1,vars:1,consts:[[1,"tag-ripple"]],template:function(Ve,He){1&Ve&&e.\u0275\u0275element(0,"div",0),2&Ve&&e.\u0275\u0275property("@ink",He.state)},styles:["[_nghost-%COMP%]{width:100%;height:100%;left:0;overflow:hidden;position:absolute}.tag-ripple[_ngcontent-%COMP%]{background:rgba(0,0,0,.1);top:50%;left:50%;height:100%;transform:translate(-50%,-50%);position:absolute}"],data:{animation:[(0,ie.trigger)("ink",[(0,ie.state)("none",(0,ie.style)({width:0,opacity:0})),(0,ie.transition)("none => clicked",[(0,ie.animate)(300,(0,ie.keyframes)([(0,ie.style)({opacity:1,offset:0,width:"30%",borderRadius:"100%"}),(0,ie.style)({opacity:1,offset:.5,width:"50%"}),(0,ie.style)({opacity:.5,offset:1,width:"100%",borderRadius:"16px"})]))])])]}}),it})(),ni=(()=>{class it{}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["delete-icon"]],decls:3,vars:0,consts:[["height","16px","viewBox","0 0 32 32","width","16px"],["d","M17.459,16.014l8.239-8.194c0.395-0.391,0.395-1.024,0-1.414c-0.394-0.391-1.034-0.391-1.428,0 l-8.232,8.187L7.73,6.284c-0.394-0.395-1.034-0.395-1.428,0c-0.394,0.396-0.394,1.037,0,1.432l8.302,8.303l-8.332,8.286 c-0.394,0.391-0.394,1.024,0,1.414c0.394,0.391,1.034,0.391,1.428,0l8.325-8.279l8.275,8.276c0.394,0.395,1.034,0.395,1.428,0 c0.394-0.396,0.394-1.037,0-1.432L17.459,16.014z","fill","#121313"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275elementStart(0,"span"),e.\u0275\u0275namespaceSVG(),e.\u0275\u0275elementStart(1,"svg",0),e.\u0275\u0275element(2,"path",1),e.\u0275\u0275elementEnd()())},styles:[".dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{box-shadow:0 0 0 1px #323232}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%]{background-color:#fff;display:inline-block;color:#555;vertical-align:middle;max-width:100%;height:42px;line-height:44px}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{border:none;box-shadow:none;outline:none;background-color:transparent;padding:0 6px;margin:0;width:auto;max-width:inherit}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-moz-placeholder{color:#777;opacity:1}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:-ms-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-webkit-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:focus{border:none;box-shadow:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #0006;border:1px solid #ccc}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #d9534f}.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;transition:all .25s;padding:.25rem 0;min-height:32px;cursor:text;border-bottom:2px solid #efefef}.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #2196F3}.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #f44336}.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.minimal.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:1px solid transparent}.minimal.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.minimal.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.minimal.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.minimal.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.minimal.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.dark.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #444}.dark.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.dark.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.dark.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.dark.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.dark.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #efefef}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #0275d8}.bootstrap.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #d9534f}.bootstrap.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;padding:4px;cursor:text;box-shadow:inset 0 1px 1px #00000013;border-radius:4px}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap3-info.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:1px solid #d9534f}.bootstrap3-info.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.error-message[_ngcontent-%COMP%]{font-size:.8em;color:#f44336;margin:.5em 0 0}.bootstrap[_ngcontent-%COMP%] .error-message[_ngcontent-%COMP%]{color:#d9534f}delete-icon[_nghost-%COMP%]{width:20px;height:16px;transition:all .15s;display:inline-block;text-align:right}delete-icon[_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#444}delete-icon[_nghost-%COMP%] svg[_ngcontent-%COMP%]{vertical-align:bottom;height:34px}delete-icon[_nghost-%COMP%]:hover{transform:scale(1.5) translateY(-3px)}.dark[_nghost-%COMP%], .dark [_nghost-%COMP%]{text-align:right}.dark[_nghost-%COMP%] path[_ngcontent-%COMP%], .dark [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#fff}.dark[_nghost-%COMP%] svg[_ngcontent-%COMP%], .dark [_nghost-%COMP%] svg[_ngcontent-%COMP%]{vertical-align:bottom;height:34px}.minimal[_nghost-%COMP%], .minimal [_nghost-%COMP%]{text-align:right}.minimal[_nghost-%COMP%] path[_ngcontent-%COMP%], .minimal [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#444}.minimal[_nghost-%COMP%] svg[_ngcontent-%COMP%], .minimal [_nghost-%COMP%] svg[_ngcontent-%COMP%]{vertical-align:bottom;height:34px}.bootstrap[_nghost-%COMP%], .bootstrap [_nghost-%COMP%]{text-align:right}.bootstrap[_nghost-%COMP%] path[_ngcontent-%COMP%], .bootstrap [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#fff}.bootstrap[_nghost-%COMP%] svg[_ngcontent-%COMP%], .bootstrap [_nghost-%COMP%] svg[_ngcontent-%COMP%]{vertical-align:bottom;height:34px}tag:focus[_nghost-%COMP%] path[_ngcontent-%COMP%], tag:focus [_nghost-%COMP%] path[_ngcontent-%COMP%], tag:active[_nghost-%COMP%] path[_ngcontent-%COMP%], tag:active [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#fff}.dark tag:focus[_nghost-%COMP%] path[_ngcontent-%COMP%], .dark tag:focus [_nghost-%COMP%] path[_ngcontent-%COMP%], .dark tag:active[_nghost-%COMP%] path[_ngcontent-%COMP%], .dark tag:active [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#000}.minimal tag:focus[_nghost-%COMP%] path[_ngcontent-%COMP%], .minimal tag:focus [_nghost-%COMP%] path[_ngcontent-%COMP%], .minimal tag:active[_nghost-%COMP%] path[_ngcontent-%COMP%], .minimal tag:active [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#000}.bootstrap tag:focus[_nghost-%COMP%] path[_ngcontent-%COMP%], .bootstrap tag:focus [_nghost-%COMP%] path[_ngcontent-%COMP%], .bootstrap tag:active[_nghost-%COMP%] path[_ngcontent-%COMP%], .bootstrap tag:active [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#fff}.bootstrap3-info[_nghost-%COMP%], .bootstrap3-info [_nghost-%COMP%]{height:inherit}.bootstrap3-info[_nghost-%COMP%] path[_ngcontent-%COMP%], .bootstrap3-info [_nghost-%COMP%] path[_ngcontent-%COMP%]{fill:#fff}"]}),it})();const qn=typeof window<"u"?window.navigator:{userAgent:"Chrome",vendor:"Google Inc"},Ti=/Chrome/.test(qn.userAgent)&&/Google Inc/.test(qn.vendor);let Bi=(()=>{class it{constructor(Ve,He,mt){this.element=Ve,this.renderer=He,this.cdRef=mt,this.disabled=!1,this.onSelect=new e.EventEmitter,this.onRemove=new e.EventEmitter,this.onBlur=new e.EventEmitter,this.onKeyDown=new e.EventEmitter,this.onTagEdited=new e.EventEmitter,this.editing=!1,this.rippleState="none"}get readonly(){return"string"!=typeof this.model&&!0===this.model.readonly}select(Ve){this.readonly||this.disabled||(Ve&&Ve.stopPropagation(),this.focus(),this.onSelect.emit(this.model))}remove(Ve){Ve.stopPropagation(),this.onRemove.emit(this)}focus(){this.element.nativeElement.focus()}move(){this.moving=!0}keydown(Ve){if(this.editing){if(13===Ve.keyCode)return this.disableEditMode(Ve)}else this.onKeyDown.emit({event:Ve,model:this.model})}blink(){const Ve=this.element.nativeElement.classList;Ve.add("blink"),setTimeout(()=>Ve.remove("blink"),50)}toggleEditMode(){if(this.editable)return this.editing?void 0:this.activateEditMode()}onBlurred(Ve){if(!this.editable)return;this.disableEditMode();const He=Ve.target.innerText,mt="string"==typeof this.model?He:{...this.model,[this.displayBy]:He};this.onBlur.emit(mt)}getDisplayValue(Ve){return"string"==typeof Ve?Ve:Ve[this.displayBy]}get isRippleVisible(){return!this.readonly&&!this.editing&&Ti&&this.hasRipple}disableEditMode(Ve){const He=this.element.nativeElement.classList,mt=this.getContentEditableText();this.editing=!1,He.remove("tag--editing"),mt?(this.storeNewValue(mt),this.cdRef.detectChanges(),Ve&&Ve.preventDefault()):this.setContentEditableText(this.model)}isDeleteIconVisible(){return!this.readonly&&!this.disabled&&this.removable&&!this.editing}getContentEditableText(){const Ve=this.getContentEditable();return Ve?Ve.innerText.trim():""}setContentEditableText(Ve){const He=this.getContentEditable(),mt=this.getDisplayValue(Ve);He.innerText=mt}activateEditMode(){this.element.nativeElement.classList.add("tag--editing"),this.editing=!0}storeNewValue(Ve){if((nn=>"string"==typeof nn?nn===Ve:nn[this.displayBy]===Ve)(this.model))return;const bt="string"==typeof this.model?Ve:{index:this.index,[this.identifyBy]:(()=>this.model[this.identifyBy]!==this.model[this.displayBy])()?this.model[this.identifyBy]:Ve,[this.displayBy]:Ve};this.canAddTag(bt)?this.onTagEdited.emit({tag:bt,index:this.index}):this.setContentEditableText(this.model)}getContentEditable(){return this.element.nativeElement.querySelector("[contenteditable]")}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(e.ElementRef),e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(e.ChangeDetectorRef))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["tag"]],viewQuery:function(Ve,He){if(1&Ve&&e.\u0275\u0275viewQuery(Mn,5),2&Ve){let mt;e.\u0275\u0275queryRefresh(mt=e.\u0275\u0275loadQuery())&&(He.ripple=mt.first)}},hostVars:2,hostBindings:function(Ve,He){1&Ve&&e.\u0275\u0275listener("keydown",function(bt){return He.keydown(bt)}),2&Ve&&e.\u0275\u0275classProp("moving",He.moving)},inputs:{model:"model",removable:"removable",editable:"editable",template:"template",displayBy:"displayBy",identifyBy:"identifyBy",index:"index",hasRipple:"hasRipple",disabled:"disabled",canAddTag:"canAddTag"},outputs:{onSelect:"onSelect",onRemove:"onRemove",onBlur:"onBlur",onKeyDown:"onKeyDown",onTagEdited:"onTagEdited"},decls:4,vars:8,consts:[[3,"click","dblclick","mousedown","mouseup","ngSwitch"],[4,"ngSwitchCase"],["class","tag-wrapper",4,"ngSwitchCase"],[3,"state",4,"ngIf"],[3,"ngTemplateOutletContext","ngTemplateOutlet"],[1,"tag-wrapper"],["spellcheck","false",1,"tag__text","inline",3,"keydown.enter","keydown.escape","click","blur"],["aria-label","Remove tag","role","button",3,"click",4,"ngIf"],["aria-label","Remove tag","role","button",3,"click"],[3,"state"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275listener("click",function(bt){return He.select(bt)})("dblclick",function(){return He.toggleEditMode()})("mousedown",function(){return He.rippleState="clicked"})("mouseup",function(){return He.rippleState="none"}),e.\u0275\u0275template(1,Vn,2,6,"div",1)(2,Wn,4,4,"div",2),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(3,ji,1,2,"tag-ripple",3)),2&Ve&&(e.\u0275\u0275classProp("disabled",He.disabled),e.\u0275\u0275property("ngSwitch",!!He.template),e.\u0275\u0275attribute("tabindex",-1)("aria-label",He.getDisplayValue(He.model)),e.\u0275\u0275advance(),e.\u0275\u0275property("ngSwitchCase",!0),e.\u0275\u0275advance(),e.\u0275\u0275property("ngSwitchCase",!1),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",He.isRippleVisible))},dependencies:[ni,Mn,X.NgSwitch,X.NgSwitchCase,X.NgTemplateOutlet,X.NgIf],styles:["[_nghost-%COMP%], [_nghost-%COMP%] > div[_ngcontent-%COMP%], [_nghost-%COMP%] > div[_ngcontent-%COMP%]:focus{outline:0;overflow:hidden;transition:opacity 1s;z-index:1}[_nghost-%COMP%]{max-width:400px}.blink[_nghost-%COMP%]{-webkit-animation:_ngcontent-%COMP%_blink .3s normal forwards ease-in-out;animation:_ngcontent-%COMP%_blink .3s normal forwards ease-in-out}@-webkit-keyframes _ngcontent-%COMP%_blink{0%{opacity:.3}}@keyframes _ngcontent-%COMP%_blink{0%{opacity:.3}}[_nghost-%COMP%] .disabled[_ngcontent-%COMP%]{cursor:not-allowed}[_nghost-%COMP%] [contenteditable=true][_ngcontent-%COMP%]{outline:0}.tag-wrapper[_ngcontent-%COMP%]{flex-direction:row;display:flex}.tag__text[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}"]}),it})();const Gi=[(0,ie.trigger)("animation",[(0,ie.state)("in",(0,ie.style)({opacity:1})),(0,ie.state)("out",(0,ie.style)({opacity:0})),(0,ie.transition)(":enter",[(0,ie.animate)("{{ enter }}",(0,ie.keyframes)([(0,ie.style)({opacity:0,offset:0,transform:"translate(0px, 20px)"}),(0,ie.style)({opacity:.3,offset:.3,transform:"translate(0px, -10px)"}),(0,ie.style)({opacity:.5,offset:.5,transform:"translate(0px, 0px)"}),(0,ie.style)({opacity:.75,offset:.75,transform:"translate(0px, 5px)"}),(0,ie.style)({opacity:1,offset:1,transform:"translate(0px, 0px)"})]))]),(0,ie.transition)(":leave",[(0,ie.animate)("{{ leave }}",(0,ie.keyframes)([(0,ie.style)({opacity:1,transform:"translateX(0)",offset:0}),(0,ie.style)({opacity:1,transform:"translateX(-15px)",offset:.7}),(0,ie.style)({opacity:0,transform:"translateX(100%)",offset:1})]))])])];let Ii=(()=>{class it{constructor(Ve){var He=this;this.injector=Ve,this.offset=hn.dropdown.offset,this.focusFirstElement=hn.dropdown.focusFirstElement,this.showDropdownIfEmpty=hn.dropdown.showDropdownIfEmpty,this.minimumTextLength=hn.dropdown.minimumTextLength,this.limitItemsTo=hn.dropdown.limitItemsTo,this.displayBy=hn.dropdown.displayBy,this.identifyBy=hn.dropdown.identifyBy,this.matchingFn=hn.dropdown.matchingFn,this.appendToBody=hn.dropdown.appendToBody,this.keepOpen=hn.dropdown.keepOpen,this.dynamicUpdate=hn.dropdown.dynamicUpdate,this.zIndex=hn.dropdown.zIndex,this.items=[],this.tagInput=this.injector.get(Jt),this._autocompleteItems=[],this.show=()=>{const mt=this.tagInput.items.length===this.tagInput.maxItems,bt=this.getFormValue(),nn=bt.trim().length>=this.minimumTextLength,Jn=this.calculatePosition(),Sn=this.getMatchingItems(bt),_r=Sn.length>0,Eo=this.tagInput.disable,Ro=!1===this.isVisible&&(_r&&nn||this.showDropdownIfEmpty&&_r&&!bt),Ls=this.isVisible&&!_r;return this.autocompleteObservable&&nn?this.getItemsFromObservable(bt):!this.showDropdownIfEmpty&&!bt||mt||Eo?this.dropdown.hide():(this.setItems(Sn),void(Ro?this.dropdown.show(Jn):Ls&&this.hide()))},this.requestAdding=function(){var mt=(0,i.A)(function*(bt){const nn=He.createTagModel(bt);yield He.tagInput.onAddingRequested(!0,nn).catch(()=>{})});return function(bt){return mt.apply(this,arguments)}}(),this.resetItems=()=>{this.items=[]},this.getItemsFromObservable=mt=>{this.setLoadingState(!0),this.autocompleteObservable(mt).pipe((0,ut.first)()).subscribe(nn=>{this.setLoadingState(!1).populateItems(nn),this.setItems(this.getMatchingItems(mt)),this.items.length?this.dropdown.show(this.calculatePosition()):this.dropdown.hide()},()=>this.setLoadingState(!1))}}set autocompleteItems(Ve){this._autocompleteItems=Ve}get autocompleteItems(){const Ve=this._autocompleteItems;return Ve?Ve.map(He=>"string"==typeof He?{[this.displayBy]:He,[this.identifyBy]:He}:He):[]}ngAfterViewInit(){this.onItemClicked().subscribe(mt=>{this.requestAdding(mt)}),this.onHide().subscribe(this.resetItems);const He=this.keepOpen;this.tagInput.onTextChange.asObservable().pipe((0,ut.distinctUntilChanged)(),(0,ut.debounceTime)(200),(0,ut.filter)(mt=>!1!==He||mt.length>0)).subscribe(this.show)}updatePosition(){const Ve=this.tagInput.inputForm.getElementPosition();this.dropdown.menu.updatePosition(Ve,this.dynamicUpdate)}get isVisible(){return this.dropdown.menu.dropdownState.menuState.isVisible}onHide(){return this.dropdown.onHide}onItemClicked(){return this.dropdown.onItemClicked}get selectedItem(){return this.dropdown.menu.dropdownState.dropdownState.selectedItem}get state(){return this.dropdown.menu.dropdownState}hide(){this.resetItems(),this.dropdown.hide()}scrollListener(){!this.isVisible||!this.dynamicUpdate||this.updatePosition()}onWindowBlur(){this.dropdown.hide()}getFormValue(){const Ve=this.tagInput.formValue;return Ve?Ve.toString().trim():""}calculatePosition(){return this.tagInput.inputForm.getElementPosition()}createTagModel(Ve){const He="string"==typeof Ve.value?Ve.value:Ve.value[this.displayBy],mt="string"==typeof Ve.value?Ve.value:Ve.value[this.identifyBy];return{...Ve.value,[this.tagInput.displayBy]:He,[this.tagInput.identifyBy]:mt}}getMatchingItems(Ve){if(!Ve&&!this.showDropdownIfEmpty)return[];const He=this.tagInput.allowDupes;return this.autocompleteItems.filter(mt=>{const bt=!He&&this.tagInput.tags.some(nn=>("string"==typeof nn.model?nn.model:nn.model[this.tagInput.identifyBy])===mt[this.identifyBy]);return this.matchingFn(Ve,mt)&&!1===bt})}setItems(Ve){this.items=Ve.slice(0,this.limitItemsTo||Ve.length)}populateItems(Ve){return this.autocompleteItems=Ve.map(He=>"string"==typeof He?{[this.displayBy]:He,[this.identifyBy]:He}:He),this}setLoadingState(Ve){return this.tagInput.isLoading=Ve,this}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(e.Injector))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["tag-input-dropdown"]],contentQueries:function(Ve,He,mt){if(1&Ve&&e.\u0275\u0275contentQuery(mt,e.TemplateRef,4),2&Ve){let bt;e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.templates=bt)}},viewQuery:function(Ve,He){if(1&Ve&&e.\u0275\u0275viewQuery(Pt,5),2&Ve){let mt;e.\u0275\u0275queryRefresh(mt=e.\u0275\u0275loadQuery())&&(He.dropdown=mt.first)}},hostBindings:function(Ve,He){1&Ve&&e.\u0275\u0275listener("scroll",function(){return He.scrollListener()},!1,e.\u0275\u0275resolveWindow)("blur",function(){return He.onWindowBlur()},!1,e.\u0275\u0275resolveWindow)},inputs:{offset:"offset",focusFirstElement:"focusFirstElement",showDropdownIfEmpty:"showDropdownIfEmpty",autocompleteObservable:"autocompleteObservable",minimumTextLength:"minimumTextLength",limitItemsTo:"limitItemsTo",displayBy:"displayBy",identifyBy:"identifyBy",matchingFn:"matchingFn",appendToBody:"appendToBody",keepOpen:"keepOpen",dynamicUpdate:"dynamicUpdate",zIndex:"zIndex",autocompleteItems:"autocompleteItems"},decls:3,vars:6,consts:[[3,"dynamicUpdate"],[3,"focusFirstElement","zIndex","appendToBody","offset"],[3,"value","ngSwitch",4,"ngFor","ngForOf"],[3,"value","ngSwitch"],[3,"innerHTML",4,"ngSwitchCase"],[4,"ngSwitchDefault"],[3,"innerHTML"],[3,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275elementStart(0,"ng2-dropdown",0)(1,"ng2-dropdown-menu",1),e.\u0275\u0275template(2,on,3,3,"ng2-menu-item",2),e.\u0275\u0275elementEnd()()),2&Ve&&(e.\u0275\u0275property("dynamicUpdate",He.dynamicUpdate),e.\u0275\u0275advance(),e.\u0275\u0275property("focusFirstElement",He.focusFirstElement)("zIndex",He.zIndex)("appendToBody",He.appendToBody)("offset",He.offset),e.\u0275\u0275advance(),e.\u0275\u0275property("ngForOf",He.items))},dependencies:[Pt,vn,un,X.NgForOf,X.NgSwitch,X.NgSwitchCase,X.NgSwitchDefault,X.NgTemplateOutlet,Nn],encapsulation:2}),it})();const Ki={provide:M.NG_VALUE_ACCESSOR,useExisting:(0,e.forwardRef)(()=>Jt),multi:!0};let Jt=(()=>{class it extends pi{constructor(Ve,He){var mt;super(),mt=this,this.renderer=Ve,this.dragProvider=He,this.separatorKeys=hn.tagInput.separatorKeys,this.separatorKeyCodes=hn.tagInput.separatorKeyCodes,this.placeholder=hn.tagInput.placeholder,this.secondaryPlaceholder=hn.tagInput.secondaryPlaceholder,this.maxItems=hn.tagInput.maxItems,this.validators=hn.tagInput.validators,this.asyncValidators=hn.tagInput.asyncValidators,this.onlyFromAutocomplete=hn.tagInput.onlyFromAutocomplete,this.errorMessages=hn.tagInput.errorMessages,this.theme=hn.tagInput.theme,this.onTextChangeDebounce=hn.tagInput.onTextChangeDebounce,this.inputId=hn.tagInput.inputId,this.inputClass=hn.tagInput.inputClass,this.clearOnBlur=hn.tagInput.clearOnBlur,this.hideForm=hn.tagInput.hideForm,this.addOnBlur=hn.tagInput.addOnBlur,this.addOnPaste=hn.tagInput.addOnPaste,this.pasteSplitPattern=hn.tagInput.pasteSplitPattern,this.blinkIfDupe=hn.tagInput.blinkIfDupe,this.removable=hn.tagInput.removable,this.editable=hn.tagInput.editable,this.allowDupes=hn.tagInput.allowDupes,this.modelAsStrings=hn.tagInput.modelAsStrings,this.trimTags=hn.tagInput.trimTags,this.ripple=hn.tagInput.ripple,this.tabindex=hn.tagInput.tabIndex,this.disable=hn.tagInput.disable,this.dragZone=hn.tagInput.dragZone,this.onRemoving=hn.tagInput.onRemoving,this.onAdding=hn.tagInput.onAdding,this.animationDuration=hn.tagInput.animationDuration,this.onAdd=new e.EventEmitter,this.onRemove=new e.EventEmitter,this.onSelect=new e.EventEmitter,this.onFocus=new e.EventEmitter,this.onBlur=new e.EventEmitter,this.onTextChange=new e.EventEmitter,this.onPaste=new e.EventEmitter,this.onValidationError=new e.EventEmitter,this.onTagEdited=new e.EventEmitter,this.isLoading=!1,this.listeners={[Ai]:[],[Qi]:[]},this.inputTextChange=new e.EventEmitter,this.inputTextValue="",this.errors=[],this.appendTag=(bt,nn=this.items.length)=>{const Jn=this.items,Sn=this.modelAsStrings?bt[this.identifyBy]:bt;this.items=[...Jn.slice(0,nn),Sn,...Jn.slice(nn,Jn.length)]},this.createTag=bt=>{const nn=(Jn,Sn)=>"string"==typeof Jn?Jn.trim():Jn[Sn];return{..."string"!=typeof bt?bt:{},[this.displayBy]:this.trimTags?nn(bt,this.displayBy):bt,[this.identifyBy]:this.trimTags?nn(bt,this.identifyBy):bt}},this.isTagValid=(bt,nn=!1)=>{const Jn=this.dropdown?this.dropdown.selectedItem:void 0,Sn=this.getItemDisplay(bt).trim();if(Jn&&!nn||!Sn)return!1;const _r=this.findDupe(bt,nn);if(!this.allowDupes&&_r&&this.blinkIfDupe){const Eo=this.tags.find(Ro=>this.getItemValue(Ro.model)===this.getItemValue(_r));Eo&&Eo.blink()}const Bo=[!_r||this.allowDupes,!this.maxItemsReached,nn&&this.onlyFromAutocomplete||!this.onlyFromAutocomplete];return Bo.filter(Boolean).length===Bo.length},this.onPasteCallback=function(){var bt=(0,i.A)(function*(nn){const Sn=(()=>{const Bo=!!window.clipboardData,Eo=Bo?window.clipboardData:nn.clipboardData;return null===Eo?"":Eo.getData(Bo?"Text":"text/plain")||""})(),_r=Sn.split(mt.pasteSplitPattern).map(Bo=>{const Eo=mt.createTag(Bo);return mt.setInputValue(Eo[mt.displayBy]),mt.onAddingRequested(!1,Eo)}),qr=()=>setTimeout(()=>mt.setInputValue(""),50);Promise.all(_r).then(()=>{mt.onPaste.emit(Sn),qr()}).catch(qr)});return function(nn){return bt.apply(this,arguments)}}()}get inputText(){return this.inputTextValue}set inputText(Ve){this.inputTextValue=Ve,this.inputTextChange.emit(Ve)}get tabindexAttr(){return""!==this.tabindex?"-1":""}ngAfterViewInit(){this.setUpKeypressListeners(),this.setupSeparatorKeysListener(),this.setUpInputKeydownListeners(),this.onTextChange.observers.length&&this.setUpTextChangeSubscriber(),(this.clearOnBlur||this.addOnBlur)&&this.setUpOnBlurSubscriber(),this.addOnPaste&&this.setUpOnPasteListener();const Ve=this.inputForm.form.statusChanges;Ve.pipe((0,dt.filter)(He=>"PENDING"!==He)).subscribe(()=>{this.errors=this.inputForm.getErrorMessages(this.errorMessages)}),this.isProgressBarVisible$=Ve.pipe((0,dt.map)(He=>"PENDING"===He||this.isLoading)),this.hideForm&&this.inputForm.destroy()}ngOnInit(){void 0!==this.maxItems&&this.items&&this.items.length>this.maxItems&&(this.maxItems=this.items.length,console.warn("The number of items specified was greater than the property max-items.")),this.editable=!this.onlyFromAutocomplete&&this.editable,this.setAnimationMetadata()}onRemoveRequested(Ve,He){return new Promise(mt=>{const bt=nn=>{this.removeItem(nn,He),mt(Ve)};this.onRemoving?this.onRemoving(Ve).pipe((0,dt.first)()).subscribe(bt):bt(Ve)})}onAddingRequested(Ve,He,mt,bt){return new Promise((nn,Jn)=>{const Sn=_r=>this.addItem(Ve,_r,mt,bt).then(nn).catch(Jn);return this.onAdding?this.onAdding(He).pipe((0,dt.first)()).subscribe(Sn,Jn):Sn(He)})}selectItem(Ve,He=!0){Ve&&"string"!=typeof Ve&&Ve.readonly||this.selectedTag===Ve||(this.selectedTag=Ve,He&&this.onSelect.emit(Ve))}fireEvents(Ve,He){this.listeners[Ve].forEach(mt=>mt.call(this,He))}handleKeydown(Ve){const He=Ve.event,bt=He.shiftKey||!1;switch(as[He.keyCode||He.which]){case"DELETE":if(this.selectedTag&&this.removable){const nn=this.items.indexOf(this.selectedTag);this.onRemoveRequested(this.selectedTag,nn)}break;case"SWITCH_PREV":this.moveToTag(Ve.model,ci);break;case"SWITCH_NEXT":this.moveToTag(Ve.model,mi);break;case"TAB":if(bt){if(this.isFirstTag(Ve.model))return;this.moveToTag(Ve.model,ci)}else{if(this.isLastTag(Ve.model)&&(this.disable||this.maxItemsReached))return;this.moveToTag(Ve.model,mi)}break;default:return}He.preventDefault()}onFormSubmit(){var Ve=this;return(0,i.A)(function*(){try{yield Ve.onAddingRequested(!1,Ve.formValue)}catch{return}})()}setInputValue(Ve,He=!0){this.getControl().setValue(Ve,{emitEvent:He})}getControl(){return this.inputForm.value}focus(Ve=!1,He=!1){this.dragProvider.getState("dragging")||(this.selectItem(void 0,!1),Ve&&(this.inputForm.focus(),this.onFocus.emit(this.formValue)))}blur(){this.onTouched(),this.onBlur.emit(this.formValue)}hasErrors(){return!!this.inputForm&&this.inputForm.hasErrors()}isInputFocused(){return!!this.inputForm&&this.inputForm.isInputFocused()}hasCustomTemplate(){const Ve=this.templates?this.templates.first:void 0;return!(!Ve||Ve===(this.dropdown&&this.dropdown.templates?this.dropdown.templates.first:void 0))}get maxItemsReached(){return void 0!==this.maxItems&&this.items.length>=this.maxItems}get formValue(){const Ve=this.inputForm.value;return Ve?Ve.value:""}onDragStarted(Ve,He,mt){Ve.stopPropagation();const bt={zone:this.dragZone,tag:He,index:mt};this.dragProvider.setSender(this),this.dragProvider.setDraggedItem(Ve,bt),this.dragProvider.setState({dragging:!0,index:mt})}onDragOver(Ve,He){this.dragProvider.setState({dropping:!0}),this.dragProvider.setReceiver(this),Ve.preventDefault()}onTagDropped(Ve,He){const mt=this.dragProvider.getDraggedItem(Ve);!mt||mt.zone!==this.dragZone||(this.dragProvider.onTagDropped(mt.tag,mt.index,He),Ve.preventDefault(),Ve.stopPropagation())}isDropping(){const Ve=this.dragProvider.receiver===this,He=this.dragProvider.getState("dropping");return!(!Ve||!He)}onTagBlurred(Ve,He){this.items[He]=Ve,this.blur()}trackBy(Ve,He){return He[this.identifyBy]}updateEditedTag(Ve){this.onTagEdited.emit(Ve)}moveToTag(Ve,He){const mt=this.isLastTag(Ve),bt=this.isFirstTag(Ve);if(He===mi&&mt||He===ci&&bt)return void this.focus(!0);const Jn=He===mi?1:-1,Sn=this.getTagIndex(Ve)+Jn,_r=this.getTagAtIndex(Sn);return _r.select.call(_r)}isFirstTag(Ve){return this.tags.first.model===Ve}isLastTag(Ve){return this.tags.last.model===Ve}getTagIndex(Ve){return this.tags.toArray().findIndex(mt=>mt.model===Ve)}getTagAtIndex(Ve){return this.tags.toArray()[Ve]}removeItem(Ve,He){this.items=this.getItemsWithout(He),this.selectedTag===Ve&&this.selectItem(void 0,!1),this.focus(!0,!1),this.onRemove.emit(Ve)}addItem(Ve=!1,He,mt,bt){const nn=this.getItemDisplay(He),Jn=this.createTag(He);return Ve&&this.setInputValue(this.getItemValue(He,!0)),new Promise((Sn,_r)=>{const qr=()=>{this.setInputValue(""),this.focus(!bt,!1),Sn(nn)},Bo=()=>{this.appendTag(Jn,mt),this.onAdd.emit(Jn),this.dropdown&&(this.dropdown.hide(),this.dropdown.showDropdownIfEmpty&&this.dropdown.show())},Eo=this.inputForm.form.status,Ro=this.isTagValid(Jn,Ve),Ls=()=>(this.onValidationError.emit(Jn),_r());return"VALID"===Eo&&Ro?(Bo(),qr()):"INVALID"!==Eo&&Ro?"PENDING"===Eo?this.inputForm.form.statusChanges.pipe((0,dt.filter)(Va=>"PENDING"!==Va),(0,dt.first)()).subscribe(Va=>"VALID"===Va&&Ro?(Bo(),qr()):(qr(),Ls())):void 0:(qr(),Ls())})}setupSeparatorKeysListener(){At.call(this,Ai,mt=>{const bt=this.separatorKeyCodes.indexOf(mt.keyCode)>=0,nn=this.separatorKeys.indexOf(mt.key)>=0;(bt||nn&&229!==mt.keyCode)&&(mt.preventDefault(),this.onAddingRequested(!1,this.formValue).catch(()=>{}))},this.separatorKeyCodes.length>0||this.separatorKeys.length>0)}setUpKeypressListeners(){At.call(this,Ai,He=>{(37===He.keyCode||8===He.keyCode)&&!this.formValue&&this.items.length&&this.tags.last.select.call(this.tags.last)})}setUpInputKeydownListeners(){this.inputForm.onKeydown.subscribe(Ve=>{"Backspace"===Ve.key&&""===this.formValue.trim()&&Ve.preventDefault()})}setUpOnPasteListener(){this.renderer.listen(this.inputForm.input.nativeElement,"paste",He=>(this.onPasteCallback(He),He.preventDefault(),!0))}setUpTextChangeSubscriber(){this.inputForm.form.valueChanges.pipe((0,dt.debounceTime)(this.onTextChangeDebounce)).subscribe(Ve=>{this.onTextChange.emit(Ve.item)})}setUpOnBlurSubscriber(){this.inputForm.onBlur.pipe((0,dt.debounceTime)(100),(0,dt.filter)(()=>!(this.dropdown&&this.dropdown.isVisible||!this.formValue))).subscribe(()=>{const He=()=>this.setInputValue("");if(this.addOnBlur)return this.onAddingRequested(!1,this.formValue,void 0,!0).then(He).catch(He);He()})}findDupe(Ve,He){const bt=Ve[He?this.dropdown.identifyBy:this.identifyBy];return this.items.find(nn=>this.getItemValue(nn)===bt)}setAnimationMetadata(){this.animationMetadata={value:"in",params:{...this.animationDuration}}}}return it.\u0275fac=function(Ve){return new(Ve||it)(e.\u0275\u0275directiveInject(e.Renderer2),e.\u0275\u0275directiveInject(yt))},it.\u0275cmp=e.\u0275\u0275defineComponent({type:it,selectors:[["tag-input"]],contentQueries:function(Ve,He,mt){if(1&Ve&&(e.\u0275\u0275contentQuery(mt,Ii,5),e.\u0275\u0275contentQuery(mt,e.TemplateRef,4)),2&Ve){let bt;e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.dropdown=bt.first),e.\u0275\u0275queryRefresh(bt=e.\u0275\u0275loadQuery())&&(He.templates=bt)}},viewQuery:function(Ve,He){if(1&Ve&&(e.\u0275\u0275viewQuery(Bn,5),e.\u0275\u0275viewQuery(Bi,5)),2&Ve){let mt;e.\u0275\u0275queryRefresh(mt=e.\u0275\u0275loadQuery())&&(He.inputForm=mt.first),e.\u0275\u0275queryRefresh(mt=e.\u0275\u0275loadQuery())&&(He.tags=mt)}},hostVars:1,hostBindings:function(Ve,He){2&Ve&&e.\u0275\u0275attribute("tabindex",He.tabindexAttr)},inputs:{separatorKeys:"separatorKeys",separatorKeyCodes:"separatorKeyCodes",placeholder:"placeholder",secondaryPlaceholder:"secondaryPlaceholder",maxItems:"maxItems",validators:"validators",asyncValidators:"asyncValidators",onlyFromAutocomplete:"onlyFromAutocomplete",errorMessages:"errorMessages",theme:"theme",onTextChangeDebounce:"onTextChangeDebounce",inputId:"inputId",inputClass:"inputClass",clearOnBlur:"clearOnBlur",hideForm:"hideForm",addOnBlur:"addOnBlur",addOnPaste:"addOnPaste",pasteSplitPattern:"pasteSplitPattern",blinkIfDupe:"blinkIfDupe",removable:"removable",editable:"editable",allowDupes:"allowDupes",modelAsStrings:"modelAsStrings",trimTags:"trimTags",inputText:"inputText",ripple:"ripple",tabindex:"tabindex",disable:"disable",dragZone:"dragZone",onRemoving:"onRemoving",onAdding:"onAdding",animationDuration:"animationDuration"},outputs:{onAdd:"onAdd",onRemove:"onRemove",onSelect:"onSelect",onFocus:"onFocus",onBlur:"onBlur",onTextChange:"onTextChange",onPaste:"onPaste",onValidationError:"onValidationError",onTagEdited:"onTagEdited",inputTextChange:"inputTextChange"},features:[e.\u0275\u0275ProvidersFeature([Ki]),e.\u0275\u0275InheritDefinitionFeature],ngContentSelectors:Cn,decls:8,vars:27,consts:[[1,"ng2-tag-input",3,"click","drop","dragenter","dragover","dragend","ngClass"],[1,"ng2-tags-container"],[3,"draggable","canAddTag","disabled","hasRipple","index","removable","editable","displayBy","identifyBy","template","model","onSelect","onRemove","onKeyDown","onTagEdited","onBlur","dragstart","drop","dragenter","dragover","dragleave",4,"ngFor","ngForOf","ngForTrackBy"],[3,"onSubmit","onBlur","click","onKeydown","onKeyup","inputText","disabled","validators","asyncValidators","hidden","placeholder","inputClass","inputId","tabindex"],["class","progress-bar",4,"ngIf"],["class","error-messages",3,"ngClass",4,"ngIf"],[3,"onSelect","onRemove","onKeyDown","onTagEdited","onBlur","dragstart","drop","dragenter","dragover","dragleave","draggable","canAddTag","disabled","hasRipple","index","removable","editable","displayBy","identifyBy","template","model"],[1,"progress-bar"],[1,"error-messages",3,"ngClass"],["class","error-message",4,"ngFor","ngForOf"],[1,"error-message"]],template:function(Ve,He){1&Ve&&(e.\u0275\u0275projectionDef(),e.\u0275\u0275elementStart(0,"div",0),e.\u0275\u0275listener("click",function(){return He.focus(!0,!1)})("drop",function(bt){return He.dragZone?He.onTagDropped(bt,void 0):void 0})("dragenter",function(bt){return He.dragZone?He.onDragOver(bt):void 0})("dragover",function(bt){return He.dragZone?He.onDragOver(bt):void 0})("dragend",function(){return He.dragZone?He.dragProvider.onDragEnd():void 0}),e.\u0275\u0275elementStart(1,"div",1),e.\u0275\u0275template(2,tn,1,14,"tag",2),e.\u0275\u0275elementStart(3,"tag-input-form",3),e.\u0275\u0275listener("onSubmit",function(){return He.onFormSubmit()})("onBlur",function(){return He.blur()})("click",function(){return He.dropdown?He.dropdown.show():void 0})("onKeydown",function(bt){return He.fireEvents("keydown",bt)})("onKeyup",function(bt){return He.fireEvents("keyup",bt)}),e.\u0275\u0275elementEnd()(),e.\u0275\u0275template(4,fi,1,0,"div",4),e.\u0275\u0275pipe(5,"async"),e.\u0275\u0275elementEnd(),e.\u0275\u0275template(6,Dn,2,2,"div",5),e.\u0275\u0275projection(7)),2&Ve&&(e.\u0275\u0275classProp("ng2-tag-input--dropping",He.isDropping())("ng2-tag-input--disabled",He.disable)("ng2-tag-input--loading",He.isLoading)("ng2-tag-input--invalid",He.hasErrors())("ng2-tag-input--focused",He.isInputFocused()),e.\u0275\u0275property("ngClass",He.theme),e.\u0275\u0275attribute("tabindex",-1),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngForOf",He.items)("ngForTrackBy",He.trackBy),e.\u0275\u0275advance(),e.\u0275\u0275property("inputText",He.inputText)("disabled",He.disable)("validators",He.validators)("asyncValidators",He.asyncValidators)("hidden",He.maxItemsReached)("placeholder",He.items.length?He.placeholder:He.secondaryPlaceholder)("inputClass",He.inputClass)("inputId",He.inputId)("tabindex",He.tabindex),e.\u0275\u0275advance(),e.\u0275\u0275property("ngIf",e.\u0275\u0275pipeBind1(5,25,He.isProgressBarVisible$)),e.\u0275\u0275advance(2),e.\u0275\u0275property("ngIf",He.hasErrors()))},dependencies:[Bi,Bn,X.NgClass,X.NgForOf,X.NgIf,X.AsyncPipe],styles:['.dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{box-shadow:0 0 0 1px #323232}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%]{background-color:#fff;display:inline-block;color:#555;vertical-align:middle;max-width:100%;height:42px;line-height:44px}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{border:none;box-shadow:none;outline:none;background-color:transparent;padding:0 6px;margin:0;width:auto;max-width:inherit}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-moz-placeholder{color:#777;opacity:1}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:-ms-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%] input[_ngcontent-%COMP%]::-webkit-input-placeholder{color:#777}.ng2-tag-input.bootstrap3-info[_ngcontent-%COMP%] input[_ngcontent-%COMP%]:focus{border:none;box-shadow:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #0006;border:1px solid #ccc}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{box-shadow:inset 0 1px 1px #d9534f}.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;transition:all .25s;padding:.25rem 0;min-height:32px;cursor:text;border-bottom:2px solid #efefef}.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #2196F3}.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #f44336}.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.minimal.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:1px solid transparent}.minimal.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.minimal.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.minimal.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.minimal.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.minimal.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.dark.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #444}.dark.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.dark.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.dark.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.dark.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.dark.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;cursor:text;border-bottom:2px solid #efefef}.bootstrap.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap.ng2-tag-input.ng2-tag-input--focused[_ngcontent-%COMP%]{border-bottom:2px solid #0275d8}.bootstrap.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:2px solid #d9534f}.bootstrap.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]{display:block;flex-direction:row;flex-wrap:wrap;position:relative;padding:4px;cursor:text;box-shadow:inset 0 1px 1px #00000013;border-radius:4px}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%]:focus{outline:0}.bootstrap3-info.ng2-tag-input.ng2-tag-input--dropping[_ngcontent-%COMP%]{opacity:.7}.bootstrap3-info.ng2-tag-input.ng2-tag-input--invalid[_ngcontent-%COMP%]{border-bottom:1px solid #d9534f}.bootstrap3-info.ng2-tag-input.ng2-tag-input--loading[_ngcontent-%COMP%]{border:none}.bootstrap3-info.ng2-tag-input.ng2-tag-input--disabled[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{margin:.1em 0}.bootstrap3-info.ng2-tag-input[_ngcontent-%COMP%] .ng2-tags-container[_ngcontent-%COMP%]{flex-wrap:wrap;display:flex}.error-message[_ngcontent-%COMP%]{font-size:.8em;color:#f44336;margin:.5em 0 0}.bootstrap[_ngcontent-%COMP%] .error-message[_ngcontent-%COMP%]{color:#d9534f}.progress-bar[_ngcontent-%COMP%], .progress-bar[_ngcontent-%COMP%]:before{height:2px;width:100%;margin:0}.progress-bar[_ngcontent-%COMP%]{background-color:#2196f3;display:flex;position:absolute;bottom:0}.progress-bar[_ngcontent-%COMP%]:before{background-color:#82c4f8;content:"";-webkit-animation:_ngcontent-%COMP%_running-progress 2s cubic-bezier(.4,0,.2,1) infinite;animation:_ngcontent-%COMP%_running-progress 2s cubic-bezier(.4,0,.2,1) infinite}@-webkit-keyframes _ngcontent-%COMP%_running-progress{0%{margin-left:0;margin-right:100%}50%{margin-left:25%;margin-right:0}to{margin-left:100%;margin-right:0}}@keyframes _ngcontent-%COMP%_running-progress{0%{margin-left:0;margin-right:100%}50%{margin-left:25%;margin-right:0}to{margin-left:100%;margin-right:0}}tag[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;font-family:Roboto,Helvetica Neue,sans-serif;font-weight:400;font-size:1em;letter-spacing:.05rem;color:#444;border-radius:16px;transition:all .3s;margin:.1rem .3rem .1rem 0;padding:.08rem .45rem;height:32px;line-height:34px;background:#efefef;-webkit-user-select:none;-moz-user-select:none;user-select:none;overflow:hidden;outline:0;cursor:pointer;position:relative}tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):focus{background:#2196F3;color:#fff;box-shadow:0 2px 3px 1px #d4d1d1}tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):active{background:#0d8aee;color:#fff;box-shadow:0 2px 3px 1px #d4d1d1}tag[_ngcontent-%COMP%]:not(:focus):not(.tag--editing):not(:active):not(.readonly):hover{background:#e2e2e2;color:#000;color:initial;box-shadow:0 2px 3px 1px #d4d1d1}tag.readonly[_ngcontent-%COMP%]{cursor:default}tag.readonly[_ngcontent-%COMP%]:focus, tag[_ngcontent-%COMP%]:focus{outline:0}tag.tag--editing[_ngcontent-%COMP%]{background-color:#fff;border:1px solid #ccc;cursor:text}.minimal[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;border-radius:0;background:#f9f9f9;-webkit-user-select:none;-moz-user-select:none;user-select:none;overflow:hidden;outline:0;cursor:pointer;position:relative}.minimal[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):focus{background:#d0d0d0;color:#000;color:initial}.minimal[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):active{background:#d0d0d0;color:#000;color:initial}.minimal[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(:focus):not(.tag--editing):not(:active):not(.readonly):hover{background:#ececec}.minimal[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]{cursor:default}.minimal[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]:focus, .minimal[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{outline:0}.minimal[_ngcontent-%COMP%] tag.tag--editing[_ngcontent-%COMP%]{cursor:text}.dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;color:#f9f9f9;border-radius:3px;background:#444;-webkit-user-select:none;-moz-user-select:none;user-select:none;overflow:hidden;outline:0;cursor:pointer;position:relative}.dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):focus{background:#efefef;color:#444}.dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(:focus):not(.tag--editing):not(:active):not(.readonly):hover{background:#2b2b2b;color:#f9f9f9}.dark[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]{cursor:default}.dark[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]:focus, .dark[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{outline:0}.dark[_ngcontent-%COMP%] tag.tag--editing[_ngcontent-%COMP%]{cursor:text}.bootstrap[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;color:#f9f9f9;border-radius:.25rem;background:#0275d8;-webkit-user-select:none;-moz-user-select:none;user-select:none;overflow:hidden;outline:0;cursor:pointer;position:relative}.bootstrap[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):focus{background:#025aa5}.bootstrap[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):active{background:#025aa5}.bootstrap[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(:focus):not(.tag--editing):not(:active):not(.readonly):hover{background:#0267bf;color:#f9f9f9}.bootstrap[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]{cursor:default}.bootstrap[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]:focus, .bootstrap[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{outline:0}.bootstrap[_ngcontent-%COMP%] tag.tag--editing[_ngcontent-%COMP%]{cursor:text}.bootstrap3-info[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;font-family:inherit;font-weight:400;font-size:95%;color:#fff;border-radius:.25em;background:#5bc0de;-webkit-user-select:none;-moz-user-select:none;user-select:none;overflow:hidden;outline:0;cursor:pointer;position:relative;padding:.25em .6em;text-align:center;white-space:nowrap}.bootstrap3-info[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):focus{background:#28a1c5}.bootstrap3-info[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(.readonly):not(.tag--editing):active{background:#28a1c5}.bootstrap3-info[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:not(:focus):not(.tag--editing):not(:active):not(.readonly):hover{background:#46b8da;color:#fff}.bootstrap3-info[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]{cursor:default}.bootstrap3-info[_ngcontent-%COMP%] tag.readonly[_ngcontent-%COMP%]:focus, .bootstrap3-info[_ngcontent-%COMP%] tag[_ngcontent-%COMP%]:focus{outline:0}.bootstrap3-info[_ngcontent-%COMP%] tag.tag--editing[_ngcontent-%COMP%]{cursor:text}[_nghost-%COMP%]{display:block}'],data:{animation:Gi}}),it})();const hi=new Gn;let Ft=(()=>{class it{static withDefaults(Ve){hi.setOptions(Ve)}}return it.\u0275fac=function(Ve){return new(Ve||it)},it.\u0275mod=e.\u0275\u0275defineNgModule({type:it}),it.\u0275inj=e.\u0275\u0275defineInjector({providers:[yt,{provide:M.COMPOSITION_BUFFER_MODE,useValue:!1}],imports:[[X.CommonModule,M.ReactiveFormsModule,M.FormsModule,Ae]]}),it})()},7773:(Ot,Me,S)=>{S.d(Me,{DX:()=>wt,yN:()=>Xr,LV:()=>uo});const i=()=>Object.create(null),{forEach:e,slice:M}=Array.prototype,{hasOwnProperty:X}=Object.prototype;class ie{constructor(ci=!0,yt=i){this.weakness=ci,this.makeData=yt}lookup(...ci){return this.lookupArray(ci)}lookupArray(ci){let yt=this;return e.call(ci,hn=>yt=yt.getChildTrie(hn)),X.call(yt,"data")?yt.data:yt.data=this.makeData(M.call(ci))}peek(...ci){return this.peekArray(ci)}peekArray(ci){let yt=this;for(let hn=0,Gt=ci.length;yt&&hn<Gt;++hn){const Gn=this.weakness&&Q(ci[hn])?yt.weak:yt.strong;yt=Gn&&Gn.get(ci[hn])}return yt&&yt.data}getChildTrie(ci){const yt=this.weakness&&Q(ci)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map);let hn=yt.get(ci);return hn||yt.set(ci,hn=new ie(this.weakness,this.makeData)),hn}}function Q(mi){switch(typeof mi){case"object":if(null===mi)break;case"function":return!0}return!1}var Ee=S(6476);let he=null;const q={};let oe=1;function ce(mi){try{return mi()}catch{}}const le="@wry/context:Slot",Et=ce(()=>globalThis)||ce(()=>global)||Object.create(null),wt=Et[le]||Array[le]||function(mi){try{Object.defineProperty(Et,le,{value:mi,enumerable:!1,writable:!1,configurable:!0})}finally{return mi}}(class{constructor(){this.id=["slot",oe++,Date.now(),Math.random().toString(36).slice(2)].join(":")}hasValue(){for(let ci=he;ci;ci=ci.parent)if(this.id in ci.slots){const yt=ci.slots[this.id];if(yt===q)break;return ci!==he&&(he.slots[this.id]=yt),!0}return he&&(he.slots[this.id]=q),!1}getValue(){if(this.hasValue())return he.slots[this.id]}withValue(ci,yt,hn,Gt){const ri=he;he={parent:ri,slots:{__proto__:null,[this.id]:ci}};try{return yt.apply(Gt,hn)}finally{he=ri}}static bind(ci){const yt=he;return function(){const hn=he;try{return he=yt,ci.apply(this,arguments)}finally{he=hn}}}static noContext(ci,yt,hn){if(!he)return ci.apply(hn,yt);{const Gt=he;try{return he=null,ci.apply(hn,yt)}finally{he=Gt}}}}),Pt=new wt,{hasOwnProperty:dt}=Object.prototype,ut=Array.from||function(mi){const ci=[];return mi.forEach(yt=>ci.push(yt)),ci};function Mt(mi){const{unsubscribe:ci}=mi;"function"==typeof ci&&(mi.unsubscribe=void 0,ci())}const Wt=[],It=100;function Vn(mi,ci){if(!mi)throw new Error(ci||"assertion failure")}function pn(mi,ci){const yt=mi.length;return yt>0&&yt===ci.length&&mi[yt-1]===ci[yt-1]}function Wn(mi){switch(mi.length){case 0:throw new Error("unknown value");case 1:return mi[0];case 2:throw mi[1]}}function ji(mi){return mi.slice(0)}let An=(()=>{class mi{constructor(yt){this.fn=yt,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++mi.count}peek(){if(1===this.value.length&&!on(this))return St(this),this.value[0]}recompute(yt){return Vn(!this.recomputing,"already recomputing"),St(this),on(this)?function qt(mi,ci){return Yn(mi),Pt.withValue(mi,Ht,[mi,ci]),function Ai(mi,ci){if("function"==typeof mi.subscribe)try{Mt(mi),mi.unsubscribe=mi.subscribe.apply(null,ci)}catch{return mi.setDirty(),!1}return!0}(mi,ci)&&function Cn(mi){mi.dirty=!1,!on(mi)&&fi(mi)}(mi),Wn(mi.value)}(this,yt):Wn(this.value)}setDirty(){this.dirty||(this.dirty=!0,tn(this),Mt(this))}dispose(){this.setDirty(),Yn(this),Zn(this,(yt,hn)=>{yt.setDirty(),cr(yt,this)})}forget(){this.dispose()}dependOn(yt){yt.add(this),this.deps||(this.deps=Wt.pop()||new Set),this.deps.add(yt)}forgetDeps(){this.deps&&(ut(this.deps).forEach(yt=>yt.delete(this)),this.deps.clear(),Wt.push(this.deps),this.deps=null)}}return mi.count=0,mi})();function St(mi){const ci=Pt.getValue();if(ci)return mi.parents.add(ci),ci.childValues.has(mi)||ci.childValues.set(mi,[]),on(mi)?Dn(ci,mi):gn(ci,mi),ci}function Ht(mi,ci){mi.recomputing=!0;const{normalizeResult:yt}=mi;let hn;yt&&1===mi.value.length&&(hn=ji(mi.value)),mi.value.length=0;try{if(mi.value[0]=mi.fn.apply(null,ci),yt&&hn&&!pn(hn,mi.value))try{mi.value[0]=yt(mi.value[0],hn[0])}catch{}}catch(Gt){mi.value[1]=Gt}mi.recomputing=!1}function on(mi){return mi.dirty||!(!mi.dirtyChildren||!mi.dirtyChildren.size)}function tn(mi){Zn(mi,Dn)}function fi(mi){Zn(mi,gn)}function Zn(mi,ci){const yt=mi.parents.size;if(yt){const hn=ut(mi.parents);for(let Gt=0;Gt<yt;++Gt)ci(hn[Gt],mi)}}function Dn(mi,ci){Vn(mi.childValues.has(ci)),Vn(on(ci));const yt=!on(mi);if(mi.dirtyChildren){if(mi.dirtyChildren.has(ci))return}else mi.dirtyChildren=Wt.pop()||new Set;mi.dirtyChildren.add(ci),yt&&tn(mi)}function gn(mi,ci){Vn(mi.childValues.has(ci)),Vn(!on(ci));const yt=mi.childValues.get(ci);0===yt.length?mi.childValues.set(ci,ji(ci.value)):pn(yt,ci.value)||mi.setDirty(),Nn(mi,ci),!on(mi)&&fi(mi)}function Nn(mi,ci){const yt=mi.dirtyChildren;yt&&(yt.delete(ci),0===yt.size&&(Wt.length<It&&Wt.push(yt),mi.dirtyChildren=null))}function Yn(mi){mi.childValues.size>0&&mi.childValues.forEach((ci,yt)=>{cr(mi,yt)}),mi.forgetDeps(),Vn(null===mi.dirtyChildren)}function cr(mi,ci){ci.parents.delete(mi),mi.childValues.delete(ci),Nn(mi,ci)}const Qi={setDirty:!0,dispose:!0,forget:!0};function Xr(mi){const ci=new Map,yt=mi&&mi.subscribe;function hn(Gt){const Gn=Pt.getValue();if(Gn){let ri=ci.get(Gt);ri||ci.set(Gt,ri=new Set),Gn.dependOn(ri),"function"==typeof yt&&(Mt(ri),ri.unsubscribe=yt(Gt))}}return hn.dirty=function(Gn,ri){const pi=ci.get(Gn);if(pi){const At=ri&&dt.call(Qi,ri)?ri:"setDirty";ut(pi).forEach(Bn=>Bn[At]()),ci.delete(Gn),Mt(pi)}},hn}let Ur;function eo(...mi){return(Ur||(Ur=new ie("function"==typeof WeakMap))).lookupArray(mi)}const as=new Set;function uo(mi,{max:ci=Math.pow(2,16),keyArgs:yt,makeCacheKey:hn=eo,normalizeResult:Gt,subscribe:Gn,cache:ri=Ee.C}=Object.create(null)){const pi="function"==typeof ri?new ri(ci,qn=>qn.dispose()):ri,At=function(){const qn=hn.apply(null,yt?yt.apply(null,arguments):arguments);if(void 0===qn)return mi.apply(null,arguments);let Ti=pi.get(qn);Ti||(pi.set(qn,Ti=new An(mi)),Ti.normalizeResult=Gt,Ti.subscribe=Gn,Ti.forget=()=>pi.delete(qn));const Bi=Ti.recompute(Array.prototype.slice.call(arguments));return pi.set(qn,Ti),as.add(pi),Pt.hasValue()||(as.forEach(Gi=>Gi.clean()),as.clear()),Bi};function Bn(qn){const Ti=qn&&pi.get(qn);Ti&&Ti.setDirty()}function Mn(qn){const Ti=qn&&pi.get(qn);if(Ti)return Ti.peek()}function ni(qn){return!!qn&&pi.delete(qn)}return Object.defineProperty(At,"size",{get:()=>pi.size,configurable:!1,enumerable:!1}),Object.freeze(At.options={max:ci,keyArgs:yt,makeCacheKey:hn,normalizeResult:Gt,subscribe:Gn,cache:pi}),At.dirtyKey=Bn,At.dirty=function(){Bn(hn.apply(null,arguments))},At.peekKey=Mn,At.peek=function(){return Mn(hn.apply(null,arguments))},At.forgetKey=ni,At.forget=function(){return ni(hn.apply(null,arguments))},At.makeCacheKey=hn,At.getKey=yt?function(){return hn.apply(null,yt.apply(null,arguments))}:hn,Object.freeze(At)}},7994:(Ot,Me,S)=>{function M(Ae,dt){(null==dt||dt>Ae.length)&&(dt=Ae.length);for(var ut=0,Mt=new Array(dt);ut<dt;ut++)Mt[ut]=Ae[ut];return Mt}function X(Ae,dt){for(var ut=0;ut<dt.length;ut++){var Mt=dt[ut];Mt.enumerable=Mt.enumerable||!1,Mt.configurable=!0,"value"in Mt&&(Mt.writable=!0),Object.defineProperty(Ae,Mt.key,Mt)}}function ie(Ae,dt,ut){return dt&&X(Ae.prototype,dt),ut&&X(Ae,ut),Object.defineProperty(Ae,"prototype",{writable:!1}),Ae}S.d(Me,{c:()=>Pt});var Q=function(){return"function"==typeof Symbol},Ee=function(Ae){return Q()&&!!Symbol[Ae]},he=function(Ae){return Ee(Ae)?Symbol[Ae]:"@@"+Ae};Q()&&!Ee("observable")&&(Symbol.observable=Symbol("observable"));var q=he("iterator"),oe=he("observable"),Z=he("species");function ce(Ae,dt){var ut=Ae[dt];if(null!=ut){if("function"!=typeof ut)throw new TypeError(ut+" is not a function");return ut}}function le(Ae){var dt=Ae.constructor;return void 0!==dt&&null===(dt=dt[Z])&&(dt=void 0),void 0!==dt?dt:Pt}function Et(Ae){Et.log?Et.log(Ae):setTimeout(function(){throw Ae})}function wt(Ae){Promise.resolve().then(function(){try{Ae()}catch(dt){Et(dt)}})}function ve(Ae){var dt=Ae._cleanup;if(void 0!==dt&&(Ae._cleanup=void 0,dt))try{if("function"==typeof dt)dt();else{var ut=ce(dt,"unsubscribe");ut&&ut.call(dt)}}catch(Mt){Et(Mt)}}function fn(Ae){Ae._observer=void 0,Ae._queue=void 0,Ae._state="closed"}function en(Ae,dt,ut){Ae._state="running";var Mt=Ae._observer;try{var Wt=ce(Mt,dt);switch(dt){case"next":Wt&&Wt.call(Mt,ut);break;case"error":if(fn(Ae),!Wt)throw ut;Wt.call(Mt,ut);break;case"complete":fn(Ae),Wt&&Wt.call(Mt)}}catch(It){Et(It)}"closed"===Ae._state?ve(Ae):"running"===Ae._state&&(Ae._state="ready")}function an(Ae,dt,ut){if("closed"!==Ae._state){if("buffering"===Ae._state)return void Ae._queue.push({type:dt,value:ut});if("ready"!==Ae._state)return Ae._state="buffering",Ae._queue=[{type:dt,value:ut}],void wt(function(){return function ct(Ae){var dt=Ae._queue;if(dt){Ae._queue=void 0,Ae._state="ready";for(var ut=0;ut<dt.length&&(en(Ae,dt[ut].type,dt[ut].value),"closed"!==Ae._state);++ut);}}(Ae)});en(Ae,dt,ut)}}var un=function(){function Ae(ut,Mt){this._cleanup=void 0,this._observer=ut,this._queue=void 0,this._state="initializing";var Wt=new vn(this);try{this._cleanup=Mt.call(void 0,Wt)}catch(It){Wt.error(It)}"initializing"===this._state&&(this._state="ready")}return Ae.prototype.unsubscribe=function(){"closed"!==this._state&&(fn(this),ve(this))},ie(Ae,[{key:"closed",get:function(){return"closed"===this._state}}]),Ae}(),vn=function(){function Ae(ut){this._subscription=ut}var dt=Ae.prototype;return dt.next=function(Mt){an(this._subscription,"next",Mt)},dt.error=function(Mt){an(this._subscription,"error",Mt)},dt.complete=function(){an(this._subscription,"complete")},ie(Ae,[{key:"closed",get:function(){return"closed"===this._subscription._state}}]),Ae}(),Pt=function(){function Ae(ut){if(!(this instanceof Ae))throw new TypeError("Observable cannot be called as a function");if("function"!=typeof ut)throw new TypeError("Observable initializer must be a function");this._subscriber=ut}var dt=Ae.prototype;return dt.subscribe=function(Mt){return("object"!=typeof Mt||null===Mt)&&(Mt={next:Mt,error:arguments[1],complete:arguments[2]}),new un(Mt,this._subscriber)},dt.forEach=function(Mt){var Wt=this;return new Promise(function(It,Vn){if("function"==typeof Mt)var Wn=Wt.subscribe({next:function(ji){try{Mt(ji,pn)}catch(An){Vn(An),Wn.unsubscribe()}},error:Vn,complete:It});else Vn(new TypeError(Mt+" is not a function"));function pn(){Wn.unsubscribe(),It()}})},dt.map=function(Mt){var Wt=this;if("function"!=typeof Mt)throw new TypeError(Mt+" is not a function");return new(le(this))(function(Vn){return Wt.subscribe({next:function(pn){try{pn=Mt(pn)}catch(Wn){return Vn.error(Wn)}Vn.next(pn)},error:function(pn){Vn.error(pn)},complete:function(){Vn.complete()}})})},dt.filter=function(Mt){var Wt=this;if("function"!=typeof Mt)throw new TypeError(Mt+" is not a function");return new(le(this))(function(Vn){return Wt.subscribe({next:function(pn){try{if(!Mt(pn))return}catch(Wn){return Vn.error(Wn)}Vn.next(pn)},error:function(pn){Vn.error(pn)},complete:function(){Vn.complete()}})})},dt.reduce=function(Mt){var Wt=this;if("function"!=typeof Mt)throw new TypeError(Mt+" is not a function");var It=le(this),Vn=arguments.length>1,pn=!1,ji=arguments[1];return new It(function(An){return Wt.subscribe({next:function(St){var qt=!pn;if(pn=!0,!qt||Vn)try{ji=Mt(ji,St)}catch(Ht){return An.error(Ht)}else ji=St},error:function(St){An.error(St)},complete:function(){if(!pn&&!Vn)return An.error(new TypeError("Cannot reduce an empty sequence"));An.next(ji),An.complete()}})})},dt.concat=function(){for(var Mt=this,Wt=arguments.length,It=new Array(Wt),Vn=0;Vn<Wt;Vn++)It[Vn]=arguments[Vn];var pn=le(this);return new pn(function(Wn){var ji,An=0;return function St(qt){ji=qt.subscribe({next:function(Ht){Wn.next(Ht)},error:function(Ht){Wn.error(Ht)},complete:function(){An===It.length?(ji=void 0,Wn.complete()):St(pn.from(It[An++]))}})}(Mt),function(){ji&&(ji.unsubscribe(),ji=void 0)}})},dt.flatMap=function(Mt){var Wt=this;if("function"!=typeof Mt)throw new TypeError(Mt+" is not a function");var It=le(this);return new It(function(Vn){var pn=[],Wn=Wt.subscribe({next:function(An){if(Mt)try{An=Mt(An)}catch(qt){return Vn.error(qt)}var St=It.from(An).subscribe({next:function(qt){Vn.next(qt)},error:function(qt){Vn.error(qt)},complete:function(){var qt=pn.indexOf(St);qt>=0&&pn.splice(qt,1),ji()}});pn.push(St)},error:function(An){Vn.error(An)},complete:function(){ji()}});function ji(){Wn.closed&&0===pn.length&&Vn.complete()}return function(){pn.forEach(function(An){return An.unsubscribe()}),Wn.unsubscribe()}})},dt[oe]=function(){return this},Ae.from=function(Mt){var Wt="function"==typeof this?this:Ae;if(null==Mt)throw new TypeError(Mt+" is not an object");var It=ce(Mt,oe);if(It){var Vn=It.call(Mt);if(Object(Vn)!==Vn)throw new TypeError(Vn+" is not an object");return function je(Ae){return Ae instanceof Pt}(Vn)&&Vn.constructor===Wt?Vn:new Wt(function(pn){return Vn.subscribe(pn)})}if(Ee("iterator")&&(It=ce(Mt,q)))return new Wt(function(pn){wt(function(){if(!pn.closed){for(var ji,Wn=function i(Ae,dt){var ut=typeof Symbol<"u"&&Ae[Symbol.iterator]||Ae["@@iterator"];if(ut)return(ut=ut.call(Ae)).next.bind(ut);if(Array.isArray(Ae)||(ut=function e(Ae,dt){if(Ae){if("string"==typeof Ae)return M(Ae,dt);var ut=Object.prototype.toString.call(Ae).slice(8,-1);if("Object"===ut&&Ae.constructor&&(ut=Ae.constructor.name),"Map"===ut||"Set"===ut)return Array.from(Ae);if("Arguments"===ut||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ut))return M(Ae,dt)}}(Ae))||dt&&Ae&&"number"==typeof Ae.length){ut&&(Ae=ut);var Mt=0;return function(){return Mt>=Ae.length?{done:!0}:{done:!1,value:Ae[Mt++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(It.call(Mt));!(ji=Wn()).done;)if(pn.next(ji.value),pn.closed)return;pn.complete()}})});if(Array.isArray(Mt))return new Wt(function(pn){wt(function(){if(!pn.closed){for(var Wn=0;Wn<Mt.length;++Wn)if(pn.next(Mt[Wn]),pn.closed)return;pn.complete()}})});throw new TypeError(Mt+" is not observable")},Ae.of=function(){for(var Mt=arguments.length,Wt=new Array(Mt),It=0;It<Mt;It++)Wt[It]=arguments[It];return new("function"==typeof this?this:Ae)(function(pn){wt(function(){if(!pn.closed){for(var Wn=0;Wn<Wt.length;++Wn)if(pn.next(Wt[Wn]),pn.closed)return;pn.complete()}})})},ie(Ae,null,[{key:Z,get:function(){return this}}]),Ae}();Q()&&Object.defineProperty(Pt,Symbol("extensions"),{value:{symbol:oe,hostReportError:Et},configurable:!0})},3844:(Ot,Me,S)=>{S.d(Me,{C6:()=>e,Cl:()=>M,Tt:()=>X,YH:()=>le,fX:()=>en,sH:()=>ce});var i=function(St,qt){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Ht,on){Ht.__proto__=on}||function(Ht,on){for(var Cn in on)Object.prototype.hasOwnProperty.call(on,Cn)&&(Ht[Cn]=on[Cn])})(St,qt)};function e(St,qt){if("function"!=typeof qt&&null!==qt)throw new TypeError("Class extends value "+String(qt)+" is not a constructor or null");function Ht(){this.constructor=St}i(St,qt),St.prototype=null===qt?Object.create(qt):(Ht.prototype=qt.prototype,new Ht)}var M=function(){return M=Object.assign||function(qt){for(var Ht,on=1,Cn=arguments.length;on<Cn;on++)for(var tn in Ht=arguments[on])Object.prototype.hasOwnProperty.call(Ht,tn)&&(qt[tn]=Ht[tn]);return qt},M.apply(this,arguments)};function X(St,qt){var Ht={};for(var on in St)Object.prototype.hasOwnProperty.call(St,on)&&qt.indexOf(on)<0&&(Ht[on]=St[on]);if(null!=St&&"function"==typeof Object.getOwnPropertySymbols){var Cn=0;for(on=Object.getOwnPropertySymbols(St);Cn<on.length;Cn++)qt.indexOf(on[Cn])<0&&Object.prototype.propertyIsEnumerable.call(St,on[Cn])&&(Ht[on[Cn]]=St[on[Cn]])}return Ht}function ce(St,qt,Ht,on){return new(Ht||(Ht=Promise))(function(tn,fi){function Zn(Nn){try{gn(on.next(Nn))}catch(Yn){fi(Yn)}}function Dn(Nn){try{gn(on.throw(Nn))}catch(Yn){fi(Yn)}}function gn(Nn){Nn.done?tn(Nn.value):function Cn(tn){return tn instanceof Ht?tn:new Ht(function(fi){fi(tn)})}(Nn.value).then(Zn,Dn)}gn((on=on.apply(St,qt||[])).next())})}function le(St,qt){var on,Cn,tn,fi,Ht={label:0,sent:function(){if(1&tn[0])throw tn[1];return tn[1]},trys:[],ops:[]};return fi={next:Zn(0),throw:Zn(1),return:Zn(2)},"function"==typeof Symbol&&(fi[Symbol.iterator]=function(){return this}),fi;function Zn(gn){return function(Nn){return function Dn(gn){if(on)throw new TypeError("Generator is already executing.");for(;fi&&(fi=0,gn[0]&&(Ht=0)),Ht;)try{if(on=1,Cn&&(tn=2&gn[0]?Cn.return:gn[0]?Cn.throw||((tn=Cn.return)&&tn.call(Cn),0):Cn.next)&&!(tn=tn.call(Cn,gn[1])).done)return tn;switch(Cn=0,tn&&(gn=[2&gn[0],tn.value]),gn[0]){case 0:case 1:tn=gn;break;case 4:return Ht.label++,{value:gn[1],done:!1};case 5:Ht.label++,Cn=gn[1],gn=[0];continue;case 7:gn=Ht.ops.pop(),Ht.trys.pop();continue;default:if(!(tn=(tn=Ht.trys).length>0&&tn[tn.length-1])&&(6===gn[0]||2===gn[0])){Ht=0;continue}if(3===gn[0]&&(!tn||gn[1]>tn[0]&&gn[1]<tn[3])){Ht.label=gn[1];break}if(6===gn[0]&&Ht.label<tn[1]){Ht.label=tn[1],tn=gn;break}if(tn&&Ht.label<tn[2]){Ht.label=tn[2],Ht.ops.push(gn);break}tn[2]&&Ht.ops.pop(),Ht.trys.pop();continue}gn=qt.call(St,Ht)}catch(Nn){gn=[6,Nn],Cn=0}finally{on=tn=0}if(5&gn[0])throw gn[1];return{value:gn[0]?gn[1]:void 0,done:!0}}([gn,Nn])}}}function en(St,qt,Ht){if(Ht||2===arguments.length)for(var tn,on=0,Cn=qt.length;on<Cn;on++)(tn||!(on in qt))&&(tn||(tn=Array.prototype.slice.call(qt,0,on)),tn[on]=qt[on]);return St.concat(tn||Array.prototype.slice.call(qt))}"function"==typeof SuppressedError&&SuppressedError},7798:(Ot,Me,S)=>{function ce(St,qt,Ht,on){return new(Ht||(Ht=Promise))(function(tn,fi){function Zn(Nn){try{gn(on.next(Nn))}catch(Yn){fi(Yn)}}function Dn(Nn){try{gn(on.throw(Nn))}catch(Yn){fi(Yn)}}function gn(Nn){Nn.done?tn(Nn.value):function Cn(tn){return tn instanceof Ht?tn:new Ht(function(fi){fi(tn)})}(Nn.value).then(Zn,Dn)}gn((on=on.apply(St,qt||[])).next())})}function an(St){return this instanceof an?(this.v=St,this):new an(St)}function un(St,qt,Ht){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Cn,on=Ht.apply(St,qt||[]),tn=[];return Cn={},Zn("next"),Zn("throw"),Zn("return",function fi(Ai){return function(Qi){return Promise.resolve(Qi).then(Ai,Yn)}}),Cn[Symbol.asyncIterator]=function(){return this},Cn;function Zn(Ai,Qi){on[Ai]&&(Cn[Ai]=function(Xr){return new Promise(function(Ur,eo){tn.push([Ai,Xr,Ur,eo])>1||Dn(Ai,Xr)})},Qi&&(Cn[Ai]=Qi(Cn[Ai])))}function Dn(Ai,Qi){try{!function gn(Ai){Ai.value instanceof an?Promise.resolve(Ai.value.v).then(Nn,Yn):cr(tn[0][2],Ai)}(on[Ai](Qi))}catch(Xr){cr(tn[0][3],Xr)}}function Nn(Ai){Dn("next",Ai)}function Yn(Ai){Dn("throw",Ai)}function cr(Ai,Qi){Ai(Qi),tn.shift(),tn.length&&Dn(tn[0][0],tn[0][1])}}function Pt(St){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var Ht,qt=St[Symbol.asyncIterator];return qt?qt.call(St):(St=function wt(St){var qt="function"==typeof Symbol&&Symbol.iterator,Ht=qt&&St[qt],on=0;if(Ht)return Ht.call(St);if(St&&"number"==typeof St.length)return{next:function(){return St&&on>=St.length&&(St=void 0),{value:St&&St[on++],done:!St}}};throw new TypeError(qt?"Object is not iterable.":"Symbol.iterator is not defined.")}(St),Ht={},on("next"),on("throw"),on("return"),Ht[Symbol.asyncIterator]=function(){return this},Ht);function on(tn){Ht[tn]=St[tn]&&function(fi){return new Promise(function(Zn,Dn){!function Cn(tn,fi,Zn,Dn){Promise.resolve(Dn).then(function(gn){tn({value:gn,done:Zn})},fi)}(Zn,Dn,(fi=St[tn](fi)).done,fi.value)})}}}S.d(Me,{AQ:()=>un,N3:()=>an,sH:()=>ce,xN:()=>Pt}),"function"==typeof SuppressedError&&SuppressedError}},__webpack_module_cache__={};function __webpack_require__(Ot){var Me=__webpack_module_cache__[Ot];if(void 0!==Me)return Me.exports;var S=__webpack_module_cache__[Ot]={id:Ot,loaded:!1,exports:{}};return __webpack_modules__[Ot].call(S.exports,S,S.exports,__webpack_require__),S.loaded=!0,S.exports}__webpack_require__.m=__webpack_modules__,__webpack_require__.c=__webpack_module_cache__,__webpack_require__.amdD=function(){throw new Error("define cannot be used indirect")},__webpack_require__.amdO={},__webpack_require__.d=(Ot,Me)=>{for(var S in Me)__webpack_require__.o(Me,S)&&!__webpack_require__.o(Ot,S)&&Object.defineProperty(Ot,S,{enumerable:!0,get:Me[S]})},__webpack_require__.o=(Ot,Me)=>Object.prototype.hasOwnProperty.call(Ot,Me),__webpack_require__.r=Ot=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(Ot,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(Ot,"__esModule",{value:!0})},__webpack_require__.nmd=Ot=>(Ot.paths=[],Ot.children||(Ot.children=[]),Ot),(()=>{__webpack_require__.S={};var Ot={},Me={};__webpack_require__.I=(S,i)=>{i||(i=[]);var e=Me[S];if(e||(e=Me[S]={}),!(i.indexOf(e)>=0)){if(i.push(e),Ot[S])return Ot[S];__webpack_require__.o(__webpack_require__.S,S)||(__webpack_require__.S[S]={});var M=__webpack_require__.S[S],Q=(q,oe,Z,ce)=>{var le=M[q]=M[q]||{},je=le[oe];(!je||!je.loaded&&(!ce!=!je.eager?ce:"shell">je.from))&&(le[oe]={get:Z,from:"shell",eager:!!ce})},he=[];return"default"===S&&(Q("@angular/animations","18.2.8",()=>()=>__webpack_require__(9969),1),Q("@angular/cdk/observers","18.2.8",()=>()=>__webpack_require__(2318),1),Q("@angular/cdk/table","18.2.8",()=>()=>__webpack_require__(6398),1),Q("@angular/common/http","18.2.8",()=>()=>__webpack_require__(1626),1),Q("@angular/common","18.2.8",()=>()=>__webpack_require__(177),1),Q("@angular/core","18.2.8",()=>()=>__webpack_require__(3953),1),Q("@angular/forms","18.2.8",()=>()=>__webpack_require__(9417),1),Q("@angular/router","18.2.8",()=>()=>__webpack_require__(7901),1),Q("@ng-bootstrap/ng-bootstrap","17.0.1",()=>()=>__webpack_require__(6605),1),Q("@popperjs/core","2.11.8",()=>()=>__webpack_require__(1969),1),Q("@swimlane/ngx-charts","20.5.0",()=>()=>__webpack_require__(5568),1),Q("@tinymce/tinymce-angular","8.0.1",()=>()=>__webpack_require__(992),1),Q("angular-svg-icon","17.0.0",()=>()=>__webpack_require__(8606),1),Q("apollo-angular","7.2.0",()=>()=>__webpack_require__(4676),1),Q("core","8.8.0",()=>()=>__webpack_require__(1922),1),Q("graphql","16.9.0",()=>()=>__webpack_require__(8286),1),Q("lodash-es","4.17.21",()=>()=>__webpack_require__(3324),1),Q("luxon","3.5.0",()=>()=>__webpack_require__(4549),1),Q("mathjs","13.2.0",()=>()=>__webpack_require__(2739),1),Q("ng-animate","2.0.1",()=>()=>__webpack_require__(936),1),Q("ngx-chips","3.0.0",()=>()=>__webpack_require__(9664),1),Q("rxjs/operators","7.8.1",()=>()=>__webpack_require__(7037),1),Q("rxjs","7.8.1",()=>()=>__webpack_require__(4087),1)),Ot[S]=he.length?Promise.all(he).then(()=>Ot[S]=1):1}}})(),(()=>{var Ot=Pt=>{var Ae=Mt=>Mt.split(".").map(Wt=>+Wt==Wt?+Wt:Wt),dt=/^([^-+]+)?(?:-([^+]+))?(?:\+(.+))?$/.exec(Pt),ut=dt[1]?Ae(dt[1]):[];return dt[2]&&(ut.length++,ut.push.apply(ut,Ae(dt[2]))),dt[3]&&(ut.push([]),ut.push.apply(ut,Ae(dt[3]))),ut},S=Pt=>{var Ae=Pt[0],dt="";if(1===Pt.length)return"*";if(Ae+.5){dt+=0==Ae?">=":-1==Ae?"<":1==Ae?"^":2==Ae?"~":Ae>0?"=":"!=";for(var ut=1,Mt=1;Mt<Pt.length;Mt++)ut--,dt+="u"==(typeof(It=Pt[Mt]))[0]?"-":(ut>0?".":"")+(ut=2,It);return dt}var Wt=[];for(Mt=1;Mt<Pt.length;Mt++){var It=Pt[Mt];Wt.push(0===It?"not("+Vn()+")":1===It?"("+Vn()+" || "+Vn()+")":2===It?Wt.pop()+" "+Wt.pop():S(It))}return Vn();function Vn(){return Wt.pop().replace(/^\((.+)\)$/,"$1")}},i=(Pt,Ae)=>{if(0 in Pt){Ae=Ot(Ae);var dt=Pt[0],ut=dt<0;ut&&(dt=-dt-1);for(var Mt=0,Wt=1,It=!0;;Wt++,Mt++){var Vn,pn,Wn=Wt<Pt.length?(typeof Pt[Wt])[0]:"";if(Mt>=Ae.length||"o"==(pn=(typeof(Vn=Ae[Mt]))[0]))return!It||("u"==Wn?Wt>dt&&!ut:""==Wn!=ut);if("u"==pn){if(!It||"u"!=Wn)return!1}else if(It)if(Wn==pn)if(Wt<=dt){if(Vn!=Pt[Wt])return!1}else{if(ut?Vn>Pt[Wt]:Vn<Pt[Wt])return!1;Vn!=Pt[Wt]&&(It=!1)}else if("s"!=Wn&&"n"!=Wn){if(ut||Wt<=dt)return!1;It=!1,Wt--}else{if(Wt<=dt||pn<Wn!=ut)return!1;It=!1}else"s"!=Wn&&"n"!=Wn&&(It=!1,Wt--)}}var ji=[],An=ji.pop.bind(ji);for(Mt=1;Mt<Pt.length;Mt++){var St=Pt[Mt];ji.push(1==St?An()|An():2==St?An()&An():St?i(St,Ae):!An())}return!!An()},Ee=(Pt,Ae,dt)=>{var ut=dt?(Pt=>Object.keys(Pt).reduce((Ae,dt)=>(Pt[dt].eager&&(Ae[dt]=Pt[dt]),Ae),{}))(Pt[Ae]):Pt[Ae];return Object.keys(ut).reduce((Mt,Wt)=>!Mt||!ut[Mt].loaded&&((Pt,Ae)=>{Pt=Ot(Pt),Ae=Ot(Ae);for(var dt=0;;){if(dt>=Pt.length)return dt<Ae.length&&"u"!=(typeof Ae[dt])[0];var ut=Pt[dt],Mt=(typeof ut)[0];if(dt>=Ae.length)return"u"==Mt;var Wt=Ae[dt],It=(typeof Wt)[0];if(Mt!=It)return"o"==Mt&&"n"==It||"s"==It||"u"==Mt;if("o"!=Mt&&"u"!=Mt&&ut!=Wt)return ut<Wt;dt++}})(Mt,Wt)?Wt:Mt,0)},je=(Pt,Ae,dt)=>dt?dt():((Pt,Ae)=>(Pt=>{throw new Error(Pt)})("Shared module "+Ae+" doesn't exist in shared scope "+Pt))(Pt,Ae),ct=(Pt=>function(Ae,dt,ut,Mt,Wt){var It=__webpack_require__.I(Ae);return It&&It.then&&!ut?It.then(Pt.bind(Pt,Ae,__webpack_require__.S[Ae],dt,!1,Mt,Wt)):Pt(Ae,__webpack_require__.S[Ae],dt,ut,Mt,Wt)})((Pt,Ae,dt,ut,Mt,Wt)=>{if(!((Pt,Ae)=>Pt&&__webpack_require__.o(Pt,Ae))(Ae,dt))return je(Pt,dt,Wt);var It=Ee(Ae,dt,ut);return i(Mt,It)||(Pt=>{typeof console<"u"&&console.warn&&console.warn(Pt)})(((Pt,Ae,dt,ut)=>"Unsatisfied version "+dt+" from "+(dt&&Pt[Ae][dt].from)+" of shared singleton module "+Ae+" (required "+S(ut)+")")(Ae,dt,It,Mt)),(Pt=>(Pt.loaded=1,Pt.get()))(Ae[dt][It])}),an={},un={2168:()=>ct("default","@angular/common",!0,[4,18,2,8],()=>()=>__webpack_require__(177)),1270:()=>ct("default","@angular/core",!0,[4,18,2,8],()=>()=>__webpack_require__(3953)),1647:()=>ct("default","rxjs",!0,[1,7,8,1],()=>()=>__webpack_require__(4087)),9335:()=>ct("default","rxjs/operators",!0,[1,7,8,1],()=>()=>__webpack_require__(7037)),1975:()=>ct("default","@angular/common/http",!0,[4,18,2,8],()=>()=>__webpack_require__(1626)),1738:()=>ct("default","@angular/forms",!0,[4,18,2,8],()=>()=>__webpack_require__(9417)),6304:()=>ct("default","@popperjs/core",!0,[1,2,11,8],()=>()=>__webpack_require__(1969)),2810:()=>ct("default","@angular/animations",!0,[4,18,2,8],()=>()=>__webpack_require__(9969)),4335:()=>ct("default","graphql",!0,[1,16,9,0],()=>()=>__webpack_require__(8286)),788:()=>ct("default","apollo-angular",!0,[1,7,2,0],()=>()=>__webpack_require__(4676)),1834:()=>ct("default","lodash-es",!0,[1,4,17,21],()=>()=>__webpack_require__(3324)),5048:()=>ct("default","angular-svg-icon",!0,[1,17,0,0],()=>()=>__webpack_require__(8606)),677:()=>ct("default","@ng-bootstrap/ng-bootstrap",!0,[4,17,0,1],()=>()=>__webpack_require__(6605)),9218:()=>ct("default","luxon",!0,[4,3,5,0],()=>()=>__webpack_require__(4549)),2662:()=>ct("default","@swimlane/ngx-charts",!0,[1,20,5,0],()=>()=>__webpack_require__(5568)),6878:()=>ct("default","@angular/cdk/observers",!0,[4,18,2,8],()=>()=>__webpack_require__(2318)),1345:()=>ct("default","mathjs",!0,[1,13,2,0],()=>()=>__webpack_require__(2739)),1820:()=>ct("default","@angular/router",!0,[4,18,2,8],()=>()=>__webpack_require__(7901)),505:()=>ct("default","ngx-chips",!0,[1,3,0,0],()=>()=>__webpack_require__(9664)),4686:()=>ct("default","@tinymce/tinymce-angular",!0,[1,8,0,1],()=>()=>__webpack_require__(992)),4801:()=>ct("default","ng-animate",!0,[1,2,0,1],()=>()=>__webpack_require__(936)),4256:()=>ct("default","@angular/cdk/table",!0,[4,18,2,8],()=>()=>__webpack_require__(6398))};[2168,1270,1647,9335,1975,1738,6304,2810,4335,788,1834,5048,677,9218,2662,6878,1345,1820,505,4686,4801,4256].forEach(Pt=>{__webpack_require__.m[Pt]=Ae=>{an[Pt]=0,delete __webpack_require__.c[Pt];var dt=un[Pt]();if("function"!=typeof dt)throw new Error("Shared module is not available for eager consumption: "+Pt);Ae.exports=dt()}})})();var __webpack_exports__=__webpack_require__(2321);