@mxtommy/kip 4.4.0-beta.2 → 4.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -0
- package/README.md +1 -0
- package/package.json +1 -1
- package/public/assets/help-docs/dashboards.md +1 -0
- package/public/assets/svg/icons.svg +8 -2
- package/public/{chunk-57TQNMBB.js → chunk-2MWBAYPJ.js} +1 -1
- package/public/{chunk-LB67BVGG.js → chunk-3BGR52TW.js} +1 -1
- package/public/{chunk-ITJKRZX5.js → chunk-4IHRH3BQ.js} +1 -1
- package/public/{chunk-SIWREBK3.js → chunk-557F3J5T.js} +1 -1
- package/public/{chunk-SNX7XX5K.js → chunk-JP7ZAJ6C.js} +1 -1
- package/public/{chunk-PSWEVUQT.js → chunk-PGELIHBX.js} +1 -1
- package/public/index.html +1 -1
- package/public/{main-YDHULJ3Q.js → main-I7M3MAJT.js} +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{$ as Pn,A as Zs,B as Tr,C as yo,D as Qs,E as xo,F as Co,G as Fa,H as Ga,I as Xs,J as Ks,K as Ba,L as wo,M as Js,N as Yc,O as Zc,P as Qc,Q as Ua,R as Dn,S as za,T as Et,U as qa,V as Ha,W as ja,X as Er,Y as Dr,Z as Xc,_ as $a,a as Ht,b as ei,c as tn,d as Sr,e as qc,f as Hc,g as jc,h as $c,i as lt,j as ea,k as Pi,l as Tn,m as ta,n as cn,o as nn,p as an,q as Ii,r as En,s as oi,t as _r,u as Mr,v as La,w as ia,x as kr,y as Wa,z as Oi}from"./chunk-57TQNMBB.js";import{a as zc,b as wr}from"./chunk-5DLSQ773.js";import{a as Kc,b as Jc,c as eu,d as tu,e as iu}from"./chunk-2KMYPGX4.js";import{a as yi,b as kn,c as be,d as Ys,e as Uc,f as ti,g as st,i as Ya,j as Za}from"./chunk-VH4ZIU4T.js";import{a as Oc,b as Rc,c as Nc,d as Va,e as Vc,f as qt,g as Lc,h as Wc,i as Fc,k as Gc,m as Ao,n as Bc}from"./chunk-IWK4FHBL.js";import{a as Kd,c as Jd,d as ec}from"./chunk-PSF2OKKT.js";import{a as Ra,b as Na}from"./chunk-HJQQWPGC.js";import{a as $i,b as Cc,c as wc,d as Sc,e as Yi,f as vi,h as _c,i as Zi,j as Qi,k as Xi,l as Cn,m as Jt,o as _t,p as _n,q as Pc,r as Mn,t as Ic,v as Mt,w as bi,x as kt,y as Ai}from"./chunk-KKJXPB75.js";import{A as Ia,B as Ki,C as Ji,D as Ec,E as Dc,F as en,G as Ct,H as Oa,I as wn,J as wt,L as Sn,M as Ot,N as St,a as Gt,b as $d,d as Bt,e as gi,f as Yd,i as Zd,j as Qd,k as pr,l as Xd,m as At,n as Da,o as xt,q as zt,s as ut,t as It,u as Mc,v as kc,w as Cr,x as Tc,y as vt,z as Pa}from"./chunk-XEJJOWK6.js";import{b as cc,f as uc,g as mc,h as gc,i as fc,j as vc,m as bc,n as Ac,p as yc,t as xc}from"./chunk-PESXPDBT.js";import{$ as er,$a as Wd,$c as Hd,$d as Di,Aa as Ld,Ab as O,Ad as nc,Ba as ct,Bb as R,Cb as Ne,Cc as te,Ce as Je,D as kd,Da as Rt,Db as Gi,Dc as Bd,De as rt,E as Td,Ea as Fe,Eb as ye,Ed as gr,Fb as xe,Fc as ur,Ga as w,Gb as I,Gc as nt,Gd as Ta,H as Hn,Ha as V,Hb as l,Hc as y,Hd as ac,I as Xo,Ia as W,Ib as u,Ic as ce,Id as oc,J as li,Ja as Fi,Jb as N,K as di,Kb as E,Kc as Ud,Kd as Ea,Lb as P,Ma as qe,Mb as Q,Mc as Zt,Nb as Bi,Nd as rc,O as Ed,Ob as Ui,Oc as Xe,P as yn,Pb as cr,Pc as js,Q as ci,Qb as re,Qd as sc,Rb as Ti,Rd as Hi,S as Dd,Sa as or,Sb as z,Sd as xn,T as Pd,Ta as rr,Tb as vo,Td as lc,U as Ko,Ua as $n,Ub as T,V as Jo,Vb as xa,Vd as $s,Wb as Ca,Wd as fr,Xb as wa,Xd as dc,Ya as g,Yb as zi,Z as Id,Zb as Lt,Zc as zd,_ as Od,_a as sr,_b as Wt,_c as qd,a as ie,aa as tr,ac as Se,b as ue,ba,bb as ya,bc as _e,be as fi,ca as ir,cb as Yn,cc as Tt,cd as mr,d as lf,da as nr,dc as ge,dd as _a,e as Cd,ec as Qe,f as et,fa as ar,fb as lr,fc as Sa,fd as Ma,g as va,ga as Rd,gc as Ke,ha as Nd,hc as d,hd as jd,he as vr,ic as X,ie as br,j as Us,jb as H,jc as he,je as Ut,k as Vt,ka as Aa,kb as hi,kc as Ft,ke as Ar,la as pt,lb as bt,ld as hr,le as ji,m as Wi,ma as ui,mb as dr,mc as Zn,me as yr,n as wd,nb as Fd,nc as Qn,ne as yt,oa as mi,ob as fo,oc as Xn,pb as pi,pc as Kn,pd as tt,pe as xr,qa as A,qb as Gd,qc as sn,qd as qi,qe as ot,r as Sd,rc as ln,s as zs,sc as Ei,t as _d,ta as Vd,tc as Hs,uc as Jn,ud as ka,va as B,vc as bo,w as Qo,wa as U,x as qs,xa as J,xc as at,xe as hc,y as Md,ya as We,yb as Z,yc as Pt,yd as tc,z as Yt,za as jn,zc as dn,zd as ic,ze as pc}from"./chunk-TGGJAGV7.js";var Gl=lf((w7,Ss)=>{(function(n){"use strict";function a(h){if(Array.isArray(h)){for(var m=0,v=Array(h.length);m<h.length;m++)v[m]=h[m];return v}return Array.from(h)}function e(h,m){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!m||typeof m!="object"&&typeof m!="function"?h:m}function t(h,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);h.prototype=Object.create(m&&m.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(h,m):h.__proto__=m)}function i(h,m){if(!(h instanceof m))throw new TypeError("Cannot call a class as a function")}function o(h,m){if(m||(m=typeof window>"u"?global:window),m[h]!==void 0)return m[h];if(Zo===null){var v=window.getComputedStyle(document.documentElement,"");Zo=(Array.prototype.slice.call(v).join("").match(/-(moz|webkit|ms)-/)||v.OLink===""&&["","o"]||["",""])[1]}if(Zo==="")return null;var C=h.charAt(0).toUpperCase()+h.substr(1),M=m[Zo+C];return M!==void 0?M:null}function r(h,m,v,C,M,D,L){if(typeof C!="function")throw new TypeError("Invalid animation rule:",C);var q=h-v,G=q/M,$=0;G>1&&(G=1),G!==1&&($=C(G),isFinite($)&&!isNaN($)&&(G=$)),m&&m(G),q<M?L.frame=vd(function(oe){return r(oe,m,v,C,M,D,L)}):(D&&D(),L.inProgress=!1)}function s(){Array.prototype.constructor.apply(this,arguments)}function c(h){if(!(h instanceof DOMException&&h.result===2152923147))throw h}function p(h,m){return m.replace(of,function(v,C){var M=h[C];return M!==void 0?M:v})}function f(h){return h.majorTicks instanceof Array||(h.majorTicks=h.majorTicks?[h.majorTicks]:[]),h.majorTicks.length||(h.majorTicks.push(ve.formatMajorTickNumber(h.minValue,h)),h.majorTicks.push(ve.formatMajorTickNumber(h.maxValue,h))),[h.tickSide!=="right",h.tickSide!=="left"]}function b(h,m,v,C,M,D){h.beginPath(),h.moveTo(m+D,v),h.lineTo(m+C-D,v),h.quadraticCurveTo(m+C,v,m+C,v+D),h.lineTo(m+C,v+M-D),h.quadraticCurveTo(m+C,v+M,m+C-D,v+M),h.lineTo(m+D,v+M),h.quadraticCurveTo(m,v+M,m,v+M-D),h.lineTo(m,v+D),h.quadraticCurveTo(m,v,m+D,v),h.closePath()}function x(h,m){var v=m.valueDec,C=m.valueInt,M=0,D=void 0,L=void 0,q=void 0;if(h=parseFloat(h),q=h<0,h=Math.abs(h),v>0){for(L=h.toFixed(v).toString().split("."),D=C-L[0].length;M<D;++M)L[0]="0"+L[0];L=(q?"-":"")+L[0]+"."+L[1]}else{for(L=Math.round(h).toString(),D=C-L.length;M<D;++M)L="0"+L;L=(q?"-":"")+L}return L}function _(h,m){var v=void 0,C=!1;return v=m.majorTicksDec===0?Math.round(h).toString():h.toFixed(m.majorTicksDec),m.majorTicksInt>1?(C=~v.indexOf("."),~v.indexOf("-")?"-"+[m.majorTicksInt+m.majorTicksDec+2+(C?1:0)-v.length].join("0")+v.replace("-",""):[m.majorTicksInt+m.majorTicksDec+1+(C?1:0)-v.length].join("0")+v):v}function k(h){return h*Math.PI/180}function S(h,m){return{x:-h*Math.sin(m),y:h*Math.cos(m)}}function F(h,m,v,C){var M=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],D=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,L=h.createLinearGradient(M?0:D,M?D:0,M?0:C,M?C:0);return L.addColorStop(0,m),L.addColorStop(1,v),L}function j(h,m){m.needleShadow&&(h.shadowOffsetX=2,h.shadowOffsetY=2,h.shadowBlur=10,h.shadowColor=m.colorNeedleShadowDown)}function Y(h,m,v){return h["font"+m+"Style"]+" "+h["font"+m+"Weight"]+" "+h["font"+m+"Size"]*v+"px "+h["font"+m]}function K(h){h.shadowOffsetX=null,h.shadowOffsetY=null,h.shadowBlur=null,h.shadowColor="",h.strokeStyle=null,h.lineWidth=0,h.save()}function pe(h,m,v,C){m.valueTextShadow&&(h.shadowOffsetX=v,h.shadowOffsetY=v,h.shadowBlur=C,h.shadowColor=m.colorValueTextShadow)}function ee(h,m,v,C,M,D){if(m.valueBox){K(h);var L=m.valueDec?1+m.valueDec:0,q="9".repeat(Math.max.apply(null,[String(parseInt(v)).length+L].concat(m.majorTicks.map(function(ze){return String(parseInt(ze,10)).length+L})))),G=m.valueText||x(v,m),$=D/200,oe=D/100,se=.4*oe,we=1.2*oe;h.font=Y(m,"Value",$),pe(h,m,se,we);var ke=h.measureText(m.valueText?G:"-"+x(Number(q),m)).width;K(h);var Pe=parseFloat(m.fontValueSize)*$+se+we,$e=oe*parseFloat(m.valueBoxStroke),De=2*D-2*$e,He=ke+10*oe,je=1.1*Pe+se+we,Ye=oe*m.valueBoxBorderRadius,Ge=(parseFloat(m.valueBoxWidth)||0)/100*De;Ge>He&&(He=Ge),He>De&&(He=De);var Ue=C-He/2,Le=M-je/2,Ee=M-5.75*oe;if(h.beginPath(),Ye?b(h,Ue,Le,He,je,Ye):h.rect(Ue,Le,He,je),$e){var Ie=h.createRadialGradient(C,Ee,10*oe,C,Ee,20*oe);Ie.addColorStop(0,m.colorValueBoxRect),Ie.addColorStop(1,m.colorValueBoxRectEnd),h.strokeStyle=Ie,h.lineWidth=$e,h.stroke()}m.colorValueBoxShadow&&(h.shadowBlur=1.2*oe,h.shadowColor=m.colorValueBoxShadow),m.colorValueBoxBackground&&(h.fillStyle=m.colorValueBoxBackground,h.fill()),h.closePath(),h.restore(),pe(h,m,se,we),h.fillStyle=m.colorValueText,h.textAlign="center",h.textBaseline="alphabetic",h.fillText(G,Ue+He/2,M+je/2-Pe/3),h.restore()}}function Te(h){var m=h.value,v=h.minValue,C=h.maxValue,M=.01*(C-v);return{normal:m<v?v:m>C?C:m,indented:m<v?v-M:m>C?C+M:m}}function fe(h,m,v,C,M){v.beginPath(),v.arc(0,0,ki(h),0,2*po,!0),v.lineWidth=m,v.strokeStyle=M?ve.linearGradient(v,C,M,h):C,v.stroke(),v.closePath()}function ne(h,m){var v=Mi.pixelRatio;return h.maxRadius||(h.maxRadius=h.max-m.borderShadowWidth-m.borderOuterWidth*v-m.borderMiddleWidth*v-m.borderInnerWidth*v+(m.borderOuterWidth?.5:0)+(m.borderMiddleWidth?.5:0)+(m.borderInnerWidth?.5:0)),h.maxRadius}function le(h,m){function v(se,we,ke,Pe,$e,De){return we&&(!De&&m.borderShadowWidth&&(ke.save(),ke.shadowBlur=m.borderShadowWidth,ke.shadowColor=m.colorBorderShadow),fe(se,we*C,ke,Pe,$e),!De&&m.borderShadowWidth&&(De=!0,ke.restore())),De}var C=Mi.pixelRatio,M=m.borderShadowWidth*C,D=h.max-M-m.borderOuterWidth*C/2,L=D-m.borderOuterWidth*C/2-m.borderMiddleWidth*C/2+.5,q=L-m.borderMiddleWidth*C/2-m.borderInnerWidth*C/2+.5,G=ne(h,m),$=void 0,oe=!1;h.save(),oe=v(D,m.borderOuterWidth,h,m.colorBorderOuter,m.colorBorderOuterEnd,oe),oe=v(L,m.borderMiddleWidth,h,m.colorBorderMiddle,m.colorBorderMiddleEnd,oe),oe=v(q,m.borderInnerWidth,h,m.colorBorderInner,m.colorBorderInnerEnd,oe),!oe&&m.borderShadowWidth&&(h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),h.beginPath(),h.arc(0,0,ki(G),0,2*po,!0),m.colorPlateEnd?($=h.createRadialGradient(0,0,G/2,0,0,G),$.addColorStop(0,m.colorPlate),$.addColorStop(1,m.colorPlateEnd)):$=m.colorPlate,h.fillStyle=$,h.fill(),h.closePath(),h.restore()}function me(h,m){if(m.highlights!=="false"&&m.highlights.length&&m.highlightsWidth!==0){var v=h.max*(parseFloat(m.highlightsWidth)||0)/100,C=ki(Me(h,m)-v/2),M=m.highlights.length,D=(m.maxValue-m.minValue)/m.ticksAngle;h.save();for(var L=0;L<M;L++){var q=m.highlights[L];h.lineWidth=v,h.lineCap=m.highlightsLineCap,h.strokeStyle=q.color,h.beginPath(),h.rotate(Bs),h.arc(0,0,C,ve.radians(m.startAngle+(q.from-m.minValue)/D),ve.radians(m.startAngle+(q.to-m.minValue)/D),!1),h.stroke(),h.closePath(),h.restore(),h.save()}h.restore()}}function de(h,m){var v=Me(h,m),C=void 0,M=void 0,D=void 0,L=0,q=Math.abs(m.minorTicks)||0,G=m.ticksAngle/(m.maxValue-m.minValue);m.exactTicks?(M=m.maxValue-m.minValue,C=q?M/q:0,L=(Li.mod(m.majorTicks[0],q)||0)*G):C=q*(m.majorTicks.length-1),h.lineWidth=Mi.pixelRatio,h.strokeStyle=m.colorMinorTicks||m.colorStrokeTicks,h.save();for(var $=0;$<C;++$)(D=m.startAngle+L+$*(m.ticksAngle/C))<=m.ticksAngle+m.startAngle&&(h.rotate(ve.radians(D)),h.beginPath(),h.moveTo(0,v),h.lineTo(0,v-.075*h.max),it(h));h.restore()}function Me(h,m){var v=h.max/100;return ne(h,m)-5*v-(m.barWidth?2*(parseFloat(m.barStrokeWidth)||0)+((parseFloat(m.barWidth)||0)+5)*v:0)}function Ve(h,m){ve.prepareTicks(m);var v=ki(Me(h,m)),C=void 0,M=m.majorTicks.length,D=Mi.pixelRatio;h.lineWidth=2*D,C=m.colorMajorTicks instanceof Array?m.colorMajorTicks:new Array(M).fill(m.colorStrokeTicks||m.colorMajorTicks);for(var L=0;L<M;++L)h.save(),h.strokeStyle=C[L],h.rotate(ve.radians(Be(m,m.exactTicks?m.majorTicks[L]:L,M))),h.beginPath(),h.moveTo(0,v),h.lineTo(0,v-.15*h.max),h.stroke(),h.closePath(),h.restore();m.strokeTicks&&(h.save(),h.strokeStyle=m.colorStrokeTicks||C[0],h.rotate(Bs),h.beginPath(),h.arc(0,0,v,ve.radians(m.startAngle),ve.radians(m.startAngle+m.ticksAngle),!1),h.stroke(),h.closePath(),h.restore())}function Be(h,m,v){if(h.exactTicks){var C=h.ticksAngle/(h.maxValue-h.minValue);return h.startAngle+C*(m-h.minValue)}return h.startAngle+m*(h.ticksAngle/(v-1))}function it(h){h.stroke(),h.restore(),h.closePath(),h.save()}function ft(h,m){var v=Me(h,m)-.15*h.max,C={},M=0,D=m.majorTicks.length,L=m.animationTarget!=="needle",q=m.colorNumbers instanceof Array?m.colorNumbers:new Array(D).fill(m.colorNumbers),G=L?-(m.value-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle:0;for(L&&(h.save(),h.rotate(-ve.radians(G))),h.font=ve.font(m,"Numbers",h.max/200),h.lineWidth=0,h.textAlign="center",h.textBaseline="middle";M<D;++M){var $=G+Be(m,m.exactTicks?m.majorTicks[M]:M,D),oe=h.measureText(m.majorTicks[M]).width,se=m.fontNumbersSize,we=Math.sqrt(oe*oe+se*se)/2,ke=ve.radialPoint(v-we-m.numbersMargin/100*h.max,ve.radians($));$===360&&($=0),C[$]||(C[$]=!0,h.fillStyle=q[M],h.fillText(m.majorTicks[M],ke.x,ke.y))}L&&h.restore()}function Xt(h,m){m.title&&(h.save(),h.font=ve.font(m,"Title",h.max/200),h.fillStyle=m.colorTitle,h.textAlign="center",h.fillText(m.title,0,-h.max/4.25,.8*h.max),h.restore())}function bn(h,m){m.units&&(h.save(),h.font=ve.font(m,"Units",h.max/200),h.fillStyle=m.colorUnits,h.textAlign="center",h.fillText(ve.formatContext(m,m.units),0,h.max/3.25,.8*h.max),h.restore())}function An(h,m){if(m.needle){var v=m.animationTarget!=="needle",C=m.ticksAngle<360?ve.normalizedValue(m).indented:m.value,M=v?m.startAngle:m.startAngle+(C-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle;m.barStartPosition==="right"&&(M=m.startAngle+m.ticksAngle-(C-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle);var D=ne(h,m),L=ki(D/100*m.needleCircleSize),q=ki(D/100*m.needleCircleSize*.75),G=ki(D/100*m.needleEnd),$=ki(m.needleStart?D/100*m.needleStart:0),oe=D/100*m.needleWidth,se=D/100*m.needleWidth/2,we=Mi.pixelRatio;h.save(),ve.drawNeedleShadow(h,m),h.rotate(ve.radians(M)),h.fillStyle=ve.linearGradient(h,m.colorNeedle,m.colorNeedleEnd,G-$),m.needleType==="arrow"?(h.beginPath(),h.moveTo(-se,-$),h.lineTo(-oe,0),h.lineTo(-1*we,G),h.lineTo(we,G),h.lineTo(oe,0),h.lineTo(se,-$),h.closePath(),h.fill(),h.beginPath(),h.lineTo(-.5*we,G),h.lineTo(-1*we,G),h.lineTo(-oe,0),h.lineTo(-se,-$),h.lineTo(se/2*we-2*we,-$),h.closePath(),h.fillStyle=m.colorNeedleShadowUp,h.fill()):(h.beginPath(),h.moveTo(-se,G),h.lineTo(-se,$),h.lineTo(se,$),h.lineTo(se,G),h.closePath(),h.fill()),h.restore(),m.needleCircleSize&&(h.save(),ve.drawNeedleShadow(h,m),m.needleCircleOuter&&(h.beginPath(),h.arc(0,0,L,0,2*po,!0),h.fillStyle=ve.linearGradient(h,m.colorNeedleCircleOuter,m.colorNeedleCircleOuterEnd,L),h.fill(),h.closePath()),m.needleCircleInner&&(h.beginPath(),h.arc(0,0,q,0,2*po,!0),h.fillStyle=ve.linearGradient(h,m.colorNeedleCircleInner,m.colorNeedleCircleInnerEnd,q),h.fill(),h.closePath()),h.restore())}}function dd(h,m,v){ve.drawValueBox(h,m,v,0,h.max-.33*h.max,h.max)}function Fg(h){var m=h.startAngle,v=h.startAngle+h.ticksAngle,C=m,M=m+(ve.normalizedValue(h).normal-h.minValue)/(h.maxValue-h.minValue)*h.ticksAngle;if(h.barStartPosition==="middle"){var D=.5*(h.minValue+h.maxValue);h.value<D?(C=180-(D-ve.normalizedValue(h).normal)/(h.maxValue-h.minValue)*h.ticksAngle,M=180):(C=180,M=180+(ve.normalizedValue(h).normal-D)/(h.maxValue-h.minValue)*h.ticksAngle)}else h.barStartPosition==="right"&&(C=v-M+m,M=v);return{startAngle:C,endAngle:M}}function cd(h,m){var v=h.max/100,C=ne(h,m)-5*v,M=parseFloat(m.barStrokeWidth+"")||0,D=(parseFloat(m.barWidth+"")||0)*v,L=C-2*M-D,q=(C-L)/2,G=L+q,$=M/G,oe=m.startAngle,se=m.startAngle+m.ticksAngle;if(h.save(),h.rotate(Bs),M&&(h.beginPath(),h.arc(0,0,G,ve.radians(oe)-$,ve.radians(se)+$,!1),h.strokeStyle=m.colorBarStroke,h.lineWidth=2*q,h.stroke(),h.closePath()),D&&(h.beginPath(),h.arc(0,0,G,ve.radians(oe),ve.radians(se),!1),h.strokeStyle=m.colorBar,h.lineWidth=D,h.stroke(),h.closePath(),m.barShadow&&(h.save(),h.beginPath(),h.arc(0,0,C,ve.radians(oe),ve.radians(se),!1),h.clip(),h.beginPath(),h.strokeStyle=m.colorBar,h.lineWidth=1,h.shadowBlur=m.barShadow,h.shadowColor=m.colorBarShadow,h.shadowOffsetX=0,h.shadowOffsetY=0,h.arc(0,0,C,ve.radians(m.startAngle),ve.radians(m.startAngle+m.ticksAngle),!1),h.stroke(),h.closePath(),h.restore()),m.barProgress)){var we=Fg(m),ke=we.startAngle,Pe=we.endAngle;h.beginPath(),h.arc(0,0,G,ve.radians(ke),ve.radians(Pe),!1),h.strokeStyle=m.colorBarProgress,h.lineWidth=D,h.stroke(),h.closePath()}h.restore()}function ud(h){return h.options.animatedValue?h.options.value:h.value}function Gg(h,m,v,C,M,D,L,q){h.beginPath(),h.fillStyle=q?ve.linearGradient(h,L,q,M>D?M:D,D>M,M>D?v:C):L,m>0?ve.roundRect(h,v,C,M,D,m):h.rect(v,C,M,D),h.fill(),h.closePath()}function Bg(h,m,v,C,M,D,L,q,G){h.beginPath(),h.lineWidth=m,h.strokeStyle=G?ve.linearGradient(h,q,G,L,!0,M):q,v>0?ve.roundRect(h,C,M,D,L,v):h.rect(C,M,D,L),h.stroke(),h.closePath()}function Ug(h,m,v,C,M,D){function L(ze,Ze,dt,Kt){return ze&&(!Kt&&m.borderShadowWidth&&(h.save(),h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),Bg(h,ze*q,G,v+ze*q/2-Ee,C+ze*q/2-Ee,$,ke,Ze,dt),Ee+=.5*q,!Kt&&m.borderShadowWidth&&(Kt=!0,h.restore())),Kt}var q=Mi.pixelRatio,G=m.borderRadius*q,$=M-m.borderShadowWidth-m.borderOuterWidth*q,oe=$-m.borderOuterWidth*q-m.borderMiddleWidth*q,se=oe-m.borderMiddleWidth*q-m.borderInnerWidth*q,we=se-m.borderInnerWidth*q,ke=D-m.borderShadowWidth-m.borderOuterWidth*q,Pe=ke-m.borderOuterWidth*q-m.borderMiddleWidth*q,$e=Pe-m.borderMiddleWidth*q-m.borderInnerWidth*q,De=$e-m.borderInnerWidth*q,He=v-(oe-$)/2,je=He-(se-oe)/2,Ye=je-(we-se)/2,Ge=C-(Pe-ke)/2,Ue=Ge-($e-Pe)/2,Le=Ue-(De-$e)/2,Ee=0,Ie=!1;return h.save(),Ie=L(m.borderOuterWidth,m.colorBorderOuter,m.colorBorderOuterEnd,Ie),Ie=L(m.borderMiddleWidth,m.colorBorderMiddle,m.colorBorderMiddleEnd,Ie),Ie=L(m.borderInnerWidth,m.colorBorderInner,m.colorBorderInnerEnd,Ie),!Ie&&m.borderShadowWidth&&(h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),Gg(h,G,Ye,Le,we+2*Ee,De+2*Ee,m.colorPlate,m.colorPlateEnd),h.restore(),[Ye,Le,we,De]}function zg(h,m,v,C,M,D){var L=Mi.pixelRatio,q=D>=M,G=q?.85*M:D,$=q?D:M;v=q?Re(v+(M-G)/2):v;var oe=!!m.title,se=!!m.units,we=!!m.valueBox,ke=void 0,Pe=void 0,$e=void 0;q?(Pe=Re(.05*$),ke=Re(.075*$),$e=Re(.11*$),oe&&($-=ke,C+=ke),se&&($-=Pe),we&&($-=$e)):(Pe=ke=Re(.15*G),oe&&(G-=ke,C+=ke),se&&(G-=Pe));var De=2*m.barStrokeWidth,He=m.barBeginCircle?Re(G*m.barBeginCircle/200-De/2):0,je=Re(G*m.barWidth/100-De),Ye=Re($*m.barLength/100-De),Ge=Re(($-Ye)/2),Ue=Re(v+(q?G/2:Ge+He)),Le=Re(C+(q?$-Ge-He+De/2:G/2)),Ee=!q||m.hasLeft&&m.hasRight?0:(m.hasRight?-1:1)*m.ticksWidth/100*G,Ie=q||m.hasLeft&&m.hasRight?0:(m.hasRight?-1:1)*m.ticksWidth/100*G;return h.barDimensions={isVertical:q,width:G,length:$,barWidth:je,barLength:Ye,strokeWidth:De,barMargin:Ge,radius:He,pixelRatio:L,barOffset:null,titleMargin:oe?ke:0,unitsMargin:se?Pe:0,get ticksLength(){return this.barLength-this.barOffset-this.strokeWidth},X:v+Ee,Y:C+Ie,x0:Ue+Ee,y0:Le+Ie,baseX:v,baseY:C,ticksPadding:m.ticksPadding/100},h.barDimensions}function md(h,m,v,C,M,D,L){var q=zg(h,m,C,M,D,L),G=q.isVertical,$=q.width,oe=q.barWidth,se=q.barLength,we=q.strokeWidth,ke=q.barMargin,Pe=q.radius,$e=q.x0,De=q.y0,He=q.X,je=q.Y,Ye=se;h.save(),h.beginPath();var Ge=null;if(m.barBeginCircle){var Ue=ve.radians(G?270:0),Le=Math.asin(oe/2/Pe),Ee=Math.cos(Le),Ie=Math.sin(Le),ze=$e+(G?Pe*Ie:Pe*Ee-we/2),Ze=G?De-Pe*Ee:De+Pe*Ie,dt=ki(G?Ze-De:ze-$e);Ge=Re(dt+Pe);var Kt=G?Re($e-Pe*Ie):ze,si=G?Ze:Re(De-Pe*Ie);v==="progress"&&(se=Ge+(se-Ge)*(ve.normalizedValue(m).normal-m.minValue)/(m.maxValue-m.minValue));var go=Re(ze+se-Ge+we/2),qn=Re(Ze-se+Ge-we/2);h.arc($e,De,Pe,Ue+Le,Ue-Le),G?(h.moveTo(ze,si),h.lineTo(ze,qn),h.lineTo(Kt,qn),h.lineTo(Kt,si)):(h.moveTo(ze,si),h.lineTo(go,si),h.lineTo(go,Ze),h.lineTo(ze,Ze))}else{var yd=Re(G?He+($-oe)/2:He+ke),xd=Re(G?je+se+ke:je+($-oe)/2);v==="progress"&&(se*=(m.value-m.minValue)/(m.maxValue-m.minValue)),G?h.rect(yd,xd,oe,-se):h.rect(yd,xd,se,oe)}v!=="progress"&&m.barStrokeWidth&&(h.lineWidth=we,h.strokeStyle=m.colorBarStroke,h.stroke()),v!=="progress"&&m.colorBar?(h.fillStyle=m.colorBarEnd?ve.linearGradient(h,m.colorBar,m.colorBarEnd,se,G,G?je:He):m.colorBar,h.fill()):v==="progress"&&m.colorBarProgress&&(h.fillStyle=m.colorBarProgressEnd?ve.linearGradient(h,m.colorBarProgress,m.colorBarProgressEnd,Ye,G,G?je:He):m.colorBarProgress,h.fill()),h.closePath(),h.restore(),m.barBeginCircle&&(h.barDimensions.radius+=we),h.barDimensions.barOffset=Ge,h.barDimensions.barWidth+=we,h.barDimensions.barLength+=we}function qg(h,m,v,C,M,D){md(h,m,"",v,C,M,D)}function hd(h,m){return m.needleSide!==h||m.tickSide!==h||m.numberSide!==h}function Hg(h,m,v,C,M,D){m.barProgress&&md(h,m,"progress",v,C,M,D)}function jg(h,m){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.barWidth,q=v.barOffset,G=v.barMargin,$=v.X,oe=v.Y,se=v.ticksLength,we=v.ticksPadding,ke=M*(parseFloat(m.highlightsWidth)||0)/100;if(m.highlights&&ke){var Pe=m.tickSide!=="right",$e=m.tickSide!=="left",De=0,He=m.highlights.length,je=(M-L)/2,Ye=m.maxValue-m.minValue,Ge=Re(C?$+je:$+G+q),Ue=ke,Le=C?oe+D-G-q:oe+je,Ee=Re((m.ticksWidth/100+we)*M)+(ke-m.ticksWidth/100*M),Ie=Re(L+we*M);for(h.save();De<He;De++){var ze=m.highlights[De],Ze=se*ki(m.minValue-ze.from)/Ye,dt=se*ki((ze.to-ze.from)/Ye);h.beginPath(),h.fillStyle=ze.color,C?(Pe&&h.rect(Ge-Ee,Le-Ze,Ue,-dt),$e&&h.rect(Ge+Ie,Le-Ze,Ue,-dt)):(Pe&&h.rect(Ge+Ze,Le-Ee,dt,Ue),$e&&h.rect(Ge+Ze,Le+Ie,dt,Ue)),h.fill(),h.closePath()}h.restore()}}function $o(h,m,v,C,M){h.beginPath(),h.moveTo(m,v),h.lineTo(C,M),h.stroke(),h.closePath()}function pd(h,m,v,C,M,D,L,q,G){var $=h.barDimensions,oe=$.isVertical,se=$.length,we=$.barWidth,ke=$.barOffset,Pe=$.barMargin,$e=$.pixelRatio,De=$.width,He=$.X,je=$.Y,Ye=$.ticksLength,Ge=$.ticksPadding,Ue=(De-we)/2,Le=void 0,Ee=void 0,Ie=0,ze=v.length,Ze=void 0,dt=G*De,Kt=Ue-Ge*De,si=Ue+we+dt+Ge*De,go=m instanceof Array?m:new Array(v.length).fill(m);h.save(),h.lineWidth=q*$e;for(var qn=Ye/(M-C);Ie<ze;Ie++)Ze=v[Ie],h.strokeStyle=go[Ie],oe?(Ee=je+se-Pe-ke+(C-Ze)*qn,D&&(Le=He+Kt,$o(h,Le,Ee,Re(Le-dt),Ee)),L&&(Le=He+si,$o(h,Le,Ee,Re(Le-dt),Ee))):(Le=He+Pe+ke-(C-Ze)*qn,D&&(Ee=je+Kt,$o(h,Le,Ee,Le,Re(Ee-dt))),L&&(Ee=je+si,$o(h,Le,Re(Ee),Le,Ee-dt)));h.restore()}function $g(h,m){var v=ve.prepareTicks(m),C=fd(v,2),M=C[0],D=C[1],L=2,q=(m.maxValue-m.minValue)/(m.majorTicks.length-1),G=m.colorMajorTicks instanceof Array?m.colorMajorTicks:new Array(m.majorTicks.length).fill(m.colorStrokeTicks||m.colorMajorTicks);if(pd(h,G,m.exactTicks?m.majorTicks:m.majorTicks.map(function(dt,Kt){return m.minValue+q*Kt}),m.minValue,m.maxValue,M,D,L,m.ticksWidth/100),m.strokeTicks){var $=h.barDimensions,oe=$.isVertical,se=$.length,we=$.width,ke=$.barWidth,Pe=$.barMargin,$e=$.barOffset,De=$.X,He=$.Y,je=$.ticksLength,Ye=$.pixelRatio,Ge=$.ticksPadding,Ue=(we-ke)/2+ke+Ge*we,Le=(we-ke)/2-Ge*we,Ee=void 0,Ie=void 0,ze=void 0,Ze=void 0;h.strokeStyle=m.colorStrokeTicks||G[0],L*=Ye,oe?(Ie=He+se-Pe-$e+L/2,Ze=Ie-je-L,M&&(ze=Ee=Re(De+Le),Yo(h,Ee,Ie,ze,Ze)),D&&(ze=Ee=Re(De+Ue),Yo(h,Ee,Ie,ze,Ze))):(Ee=De+Pe+$e-L/2,ze=Ee+je+L,M&&(Ze=Ie=Re(He+Le),Yo(h,Ee,Ie,ze,Ze)),D&&(Ze=Ie=Re(He+Ue),Yo(h,Ee,Ie,ze,Ze)))}}function Yo(h,m,v,C,M){h.beginPath(),h.moveTo(m,v),h.lineTo(C,M),h.stroke(),h.closePath()}function Yg(h,m){var v=ve.prepareTicks(m),C=fd(v,2),M=C[0],D=C[1],L=[],q=m.minValue,G=Math.abs(m.minorTicks)||0,$=G?(m.maxValue-m.minValue)/(G*(m.majorTicks.length-1)):0;if(G)if(m.exactTicks)for(var oe=Li.mod(m.majorTicks[0],G)||0;q<m.maxValue;q+=G)oe+q<m.maxValue&&L.push(oe+q);else for(;q<m.maxValue;q+=$)L.push(q);pd(h,m.colorMinorTicks||m.colorStrokeTicks,L,m.minValue,m.maxValue,M,D,1,m.ticksWidthMinor/100)}function Zg(h,m){var v=h.barDimensions,C=v.isVertical,M=v.length,D=v.width,L=v.barWidth,q=v.barMargin,G=v.barOffset,$=v.X,oe=v.Y,se=v.ticksLength,we=v.ticksPadding,ke=m.maxValue-m.minValue,Pe=ke/(m.majorTicks.length-1),$e=m.exactTicks?m.majorTicks:m.majorTicks.map(function(go,qn){return m.minValue+Pe*qn}),De=$e.length,He=m.numberSide!=="right",je=m.numberSide!=="left",Ye=m.fontNumbersSize*D/200,Ge=0,Ue=(m.ticksWidth/100+2*we)*D,Le=(D-L)/2-Ue,Ee=(D-L)/2+L+Ue,Ie=void 0,ze=void 0,Ze=void 0,dt=void 0,Kt=m.colorNumbers instanceof Array?m.colorNumbers:new Array(De).fill(m.colorNumbers),si=m.numbersMargin/100*D;for(h.font=ve.font(m,"Numbers",D/200),h.lineWidth=0,h.textAlign="center";Ge<De;Ge++)h.fillStyle=Kt[Ge],dt=m.majorTicks[Ge],Ze=m.exactTicks?se*(($e[Ge]-m.minValue)/ke):Ge*se/(De-1),C?(ze=oe+M-q-G-Ze+Ye/3,He&&(h.textAlign="right",h.fillText(dt,$+Le-si,ze)),je&&(h.textAlign="left",h.fillText(dt,$+Ee+si,ze))):(h.measureText(dt).width,Ie=$+q+G+Ze,He&&h.fillText(dt,Ie,oe+Le-si),je&&h.fillText(dt,Ie,oe+Ee+Ye+si))}function Qg(h,m){if(m.title){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.baseX,q=v.baseY,G=v.titleMargin,$=m.fontTitleSize*M/200,oe=Re(L+(C?M:D)/2),se=Re(q+G/2-(C?$:$/2)-.025*(C?D:M));h.save(),h.textAlign="center",h.fillStyle=m.colorTitle,h.font=ve.font(m,"Title",M/200),h.lineWidth=0,h.fillText(m.title,oe,se,C?M:D),h.restore()}}function Xg(h,m){if(m.units){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.baseX,q=v.baseY,G=v.unitsMargin,$=m.fontUnitsSize*M/200,oe=Re(L+(C?M:D)/2),se=Re(q+(C?D:M)+G/2-$/2);h.save(),h.textAlign="center",h.fillStyle=m.colorUnits,h.font=ve.font(m,"Units",M/200),h.lineWidth=0,h.fillText(ve.formatContext(m,m.units),oe,se,C?M:D),h.restore()}}function Kg(h,m){if(m.needle){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.barWidth,q=v.barOffset,G=v.barMargin,$=v.ticksLength,oe=v.X,se=v.Y,we=v.ticksPadding,ke=m.needleSide!=="right",Pe=m.needleSide!=="left",$e=$*(ve.normalizedValue(m).indented-m.minValue)/(m.maxValue-m.minValue),De=(m.ticksWidth/100+we)*M,He=L/2+De,je=He*(m.needleEnd/100),Ye=void 0,Ge=void 0,Ue=void 0,Le=void 0,Ee=m.needleType.toLowerCase()==="arrow"?ef:Jg,Ie=(M-L)/2,ze=He*(m.needleStart/100),Ze=Ie-De-ze,dt=Ie+L+De+ze;h.save(),ve.drawNeedleShadow(h,m),C?(Ue=Re(se+D-G-q-$e),ke&&(Ye=Re(oe+Ze),Ge=Ye+je,Ee(h,m,Ye,Ue,Ge,Ue,je)),Pe&&(Ye=Re(oe+dt),Ge=Ye-je,Ee(h,m,Ye,Ue,Ge,Ue,je,!0))):(Ye=Re(oe+G+q+$e),ke&&(Ue=Re(se+Ze),Le=Ue+je,Ee(h,m,Ye,Ue,Ye,Le,je)),Pe&&(Ue=Re(se+dt),Le=Ue-je,Ee(h,m,Ye,Ue,Ye,Le,je,!0))),h.restore()}}function gd(h,m,v,C){return m.colorNeedleEnd?ve.linearGradient(h,C?m.colorNeedleEnd:m.colorNeedle,C?m.colorNeedle:m.colorNeedleEnd,v,!h.barDimensions.isVertical):m.colorNeedle}function Jg(h,m,v,C,M,D,L,q){h.lineWidth=m.needleWidth,h.strokeStyle=gd(h,m,L,q),h.beginPath(),h.moveTo(v,C),h.lineTo(M,D),h.stroke(),h.closePath()}function ef(h,m,v,C,M,D,L,q){var G=Re(.4*L),$=L-G,oe=v===M,se=m.needleWidth/2;h.fillStyle=gd(h,m,L,q),h.beginPath(),oe?(C>D&&($*=-1),h.moveTo(v-se,C),h.lineTo(v+se,C),h.lineTo(v+se,C+$),h.lineTo(v,D),h.lineTo(v-se,C+$),h.lineTo(v-se,C)):(v>M&&($*=-1),h.moveTo(v,C-se),h.lineTo(v,C+se),h.lineTo(v+$,C+se),h.lineTo(M,C),h.lineTo(v+$,C-se),h.lineTo(v,C-se)),h.fill(),h.closePath()}function tf(h,m,v,C,M,D,L){var q=(parseFloat(m.fontValueSize)||0)*D/200,G=(.11*L-q)/2;h.barDimensions.isVertical&&ve.drawValueBox(h,m,v,C+D/2,M+L-q-G,D)}var fd=(function(){function h(m,v){var C=[],M=!0,D=!1,L=void 0;try{for(var q,G=m[Symbol.iterator]();!(M=(q=G.next()).done)&&(C.push(q.value),!v||C.length!==v);M=!0);}catch($){D=!0,L=$}finally{try{!M&&G.return&&G.return()}finally{if(D)throw L}}return C}return function(m,v){if(Array.isArray(m))return m;if(Symbol.iterator in Object(m))return h(m,v);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),Ls=function h(m,v,C){m===null&&(m=Function.prototype);var M=Object.getOwnPropertyDescriptor(m,v);if(M===void 0){var D=Object.getPrototypeOf(m);return D===null?void 0:h(D,v,C)}if("value"in M)return M.value;var L=M.get;if(L!==void 0)return L.call(C)},nf=function h(m,v,C,M){var D=Object.getOwnPropertyDescriptor(m,v);if(D===void 0){var L=Object.getPrototypeOf(m);L!==null&&h(L,v,C,M)}else if("value"in D&&D.writable)D.value=C;else{var q=D.set;q!==void 0&&q.call(M,C)}return C},zn=(function(){function h(m,v){for(var C=0;C<v.length;C++){var M=v[C];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(m,M.key,M)}}return function(m,v,C){return v&&h(m.prototype,v),C&&h(m,C),m}})(),Zo=null,af=(function(){function h(){i(this,h),this._events={},this.addListener=this.on,this.removeListener=this.off}return zn(h,[{key:"emit",value:function(m){if(this._events[m]){for(var v=0,C=this._events[m].length,M=arguments.length,D=Array(M>1?M-1:0),L=1;L<M;L++)D[L-1]=arguments[L];for(;v<C;v++)this._events[m][v]&&this._events[m][v].apply(this,D)}}},{key:"once",value:function(m){for(var v=arguments.length,C=Array(v>1?v-1:0),M=1;M<v;M++)C[M-1]=arguments[M];for(var D=0,L=C.length,q=this;D<L;D++)(function(){var G=C[D],$=function oe(){q.off(m,oe),G.apply(q,arguments)};C[D]=$})();this.on.apply(this,[m].concat(C))}},{key:"on",value:function(m){this._events[m]||(this._events[m]=[]);for(var v=0,C=arguments.length<=1?0:arguments.length-1;v<C;v++)this._events[m].push(arguments.length<=v+1?void 0:arguments[v+1])}},{key:"off",value:function(m){if(this._events[m])for(var v=0,C=arguments.length<=1?0:arguments.length-1;v<C;v++)for(var M=arguments.length<=v+1?void 0:arguments[v+1],D=void 0;~(D=this._events[m].indexOf(M));)this._events[m].splice(D,1)}},{key:"removeAllListeners",value:function(m){delete this._events[m]}},{key:"listeners",get:function(){return this._events}}]),h})(),vd=o("requestAnimationFrame")||function(h){return setTimeout(function(){return h(new Date().getTime())},1e3/60)},mo={linear:function(h){return h},quad:function(h){return Math.pow(h,2)},dequad:function(h){return 1-mo.quad(1-h)},quint:function(h){return Math.pow(h,5)},dequint:function(h){return 1-Math.pow(1-h,5)},cycle:function(h){return 1-Math.sin(Math.acos(h))},decycle:function(h){return Math.sin(Math.acos(1-h))},bounce:function(h){return 1-mo.debounce(1-h)},debounce:function(h){for(var m=0,v=1;;m+=v,v/=2)if(h>=(7-4*m)/11)return-Math.pow((11-6*m-11*h)/4,2)+Math.pow(v,2)},elastic:function(h){return 1-mo.delastic(1-h)},delastic:function(h){return Math.pow(2,10*(h-1))*Math.cos(20*Math.PI*1.5/3*h)}},Ws=(function(){function h(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"linear",v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:250,C=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},M=arguments.length>3&&arguments[3]!==void 0?arguments[3]:function(){};if(i(this,h),this.duration=v,this.rule=m,this.draw=C,this.end=M,typeof this.draw!="function")throw new TypeError("Invalid animation draw callback:",C);if(typeof this.end!="function")throw new TypeError("Invalid animation end callback:",M)}return zn(h,[{key:"animate",value:function(m,v){var C=this;this.frame&&this.cancel();var M=window.performance&&window.performance.now?window.performance.now():o("animationStartTime")||Date.now();m=m||this.draw,v=v||this.end,this.draw=m,this.end=v,this.frame=vd(function(D){return r(D,m,M,mo[C.rule]||C.rule,C.duration,v,C)})}},{key:"cancel",value:function(){this.frame&&((o("cancelAnimationFrame")||function(m){})(this.frame),this.frame=null)}},{key:"destroy",value:function(){this.cancel(),this.draw=null,this.end=null}}]),h})();Ws.rules=mo;var fa=(function(){function h(m,v,C){i(this,h),this.options=m,this.element=v.toLowerCase(),this.type=h.toDashed(C),this.Type=n[C],this.mutationsObserved=!1,this.isObservable=!!window.MutationObserver,window.GAUGES_NO_AUTO_INIT||h.domReady(this.traverse.bind(this))}return zn(h,[{key:"isValidNode",value:function(m){return!(!m.tagName||m.tagName.toLowerCase()!==this.element||m.getAttribute("data-type")!==this.type)}},{key:"traverse",value:function(){for(var m=document.getElementsByTagName(this.element),v=0,C=m.length;v<C;v++)this.process(m[v]);this.isObservable&&!this.mutationsObserved&&(new MutationObserver(this.observe.bind(this)).observe(document.body,{childList:!0,subtree:!0,attributes:!0,characterData:!0,attributeOldValue:!0,characterDataOldValue:!0}),this.mutationsObserved=!0)}},{key:"observe",value:function(m){for(var v=0,C=m.length;v<C;v++){var M=m[v];if(M.type==="attributes"&&M.attributeName==="data-type"&&this.isValidNode(M.target)&&M.oldValue!==this.type)setTimeout(this.process.bind(this,M.target));else if(M.addedNodes&&M.addedNodes.length)for(var D=0,L=M.addedNodes.length;D<L;D++)setTimeout(this.process.bind(this,M.addedNodes[D]))}}},{key:"process",value:function(m){var v=this;if(!this.isValidNode(m))return null;var C=void 0,M=JSON.parse(JSON.stringify(this.options)),D=null;for(C in M)if(M.hasOwnProperty(C)){var L=h.toAttributeName(C),q=h.parse(m.getAttribute(L));q!=null&&(M[C]=q)}return M.renderTo=m,D=new this.Type(M),D.draw&&D.draw(),this.isObservable&&(D.observer=new MutationObserver(function(G){G.forEach(function($){if($.type==="attributes"){var oe=$.attributeName.toLowerCase(),se=m.getAttribute(oe).toLowerCase();if(oe==="data-type"&&se&&se!==v.type)D.observer.disconnect(),delete D.observer,D.destroy&&D.destroy();else if(oe.substr(0,5)==="data-"){var we=oe.substr(5).split("-").map(function(Pe,$e){return $e?Pe.charAt(0).toUpperCase()+Pe.substr(1):Pe}).join(""),ke={};ke[we]=h.parse(m.getAttribute($.attributeName)),we==="value"?D&&(D.value=ke[we]):D.update&&D.update(ke)}}})}),D.observer.observe(m,{attributes:!0})),D}}],[{key:"parse",value:function(m){if(m==="true")return!0;if(m==="false")return!1;if(m!=="undefined"){if(m==="null")return null;if(/^[-+#.\w\d\s]+(?:,[-+#.\w\d\s]*)+$/.test(m))return m.split(",");try{return JSON.parse(m)}catch(v){}return m}}},{key:"toDashed",value:function(m){for(var v=m.split(/(?=[A-Z])/),C=1,M=v.length,D=v[0].toLowerCase();C<M;C++)D+="-"+v[C].toLowerCase();return D}},{key:"toCamelCase",value:function(m){for(var v=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],C=m.split(/-/),M=0,D=C.length,L="";M<D;M++)L+=M||v?C[M][0].toUpperCase()+C[M].substr(1).toLowerCase():C[M].toLowerCase();return L}},{key:"toAttributeName",value:function(m){return"data-"+h.toDashed(m)}},{key:"domReady",value:function(m){if(/comp|inter|loaded/.test((window.document||{}).readyState+""))return m();window.addEventListener?window.addEventListener("DOMContentLoaded",m,!1):window.attachEvent&&window.attachEvent("onload",m)}}]),h})(),Mi=(function(){function h(m,v,C){i(this,h),h.collection.push(this),this.width=v||0,this.height=C||0,this.element=m,this.init()}return zn(h,[{key:"init",value:function(){var m=h.pixelRatio;this.element.width=this.width*m,this.element.height=this.height*m,this.element.style.width=this.width+"px",this.element.style.height=this.height+"px",this.elementClone=this.element.cloneNode(!0),this.context=this.element.getContext("2d"),this.contextClone=this.elementClone.getContext("2d"),this.drawWidth=this.element.width,this.drawHeight=this.element.height,this.drawX=this.drawWidth/2,this.drawY=this.drawHeight/2,this.minSide=this.drawX<this.drawY?this.drawX:this.drawY,this.contextClone.translate(this.drawX,this.drawY),this.elementClone.initialized=!1,this.context.translate(this.drawX,this.drawY),this.context.max=this.contextClone.max=this.minSide,this.context.maxRadius=this.contextClone.maxRadius=null}},{key:"destroy",value:function(){var m=h.collection.indexOf(this);~m&&h.collection.splice(m,1),this.context.clearRect(-this.drawX,-this.drawY,this.drawWidth,this.drawHeight),this.context.max=null,delete this.context.max,this.context.maxRadius=null,delete this.context.maxRadius,this.context=null,this.contextClone=null,this.elementClone=null,this.element=null,this.onRedraw=null}},{key:"commit",value:function(){var m=h.pixelRatio;return m!==1&&this.contextClone.scale(m,m),this}},{key:"redraw",value:function(){return this.init(),this.onRedraw&&this.onRedraw(),this}}],[{key:"redraw",value:function(){for(var m=0,v=h.collection.length;m<v;m++)h.collection[m].redraw()}},{key:"pixelRatio",get:function(){return window.devicePixelRatio||1}}]),h})();Mi.collection=[],window.matchMedia&&window.matchMedia("screen and (min-resolution: 2dppx)").addListener(Mi.redraw);var Fs={renderTo:null,width:0,height:0,minValue:0,maxValue:100,value:0,units:!1,exactTicks:!1,majorTicks:[0,20,40,60,80,100],minorTicks:10,strokeTicks:!0,animatedValue:!1,animateOnInit:!1,title:!1,borders:!0,numbersMargin:1,listeners:null,valueInt:3,valueDec:2,majorTicksInt:1,majorTicksDec:0,animation:!0,animationDuration:500,animationRule:"cycle",colorPlate:"#fff",colorPlateEnd:"",colorMajorTicks:"#444",colorMinorTicks:"#666",colorStrokeTicks:"",colorTitle:"#888",colorUnits:"#888",colorNumbers:"#444",colorNeedle:"rgba(240,128,128,1)",colorNeedleEnd:"rgba(255,160,122,.9)",colorValueText:"#444",colorValueTextShadow:"rgba(0,0,0,0.3)",colorBorderShadow:"rgba(0,0,0,0.5)",colorBorderOuter:"#ddd",colorBorderOuterEnd:"#aaa",colorBorderMiddle:"#eee",colorBorderMiddleEnd:"#f0f0f0",colorBorderInner:"#fafafa",colorBorderInnerEnd:"#ccc",colorValueBoxRect:"#888",colorValueBoxRectEnd:"#666",colorValueBoxBackground:"#babab2",colorValueBoxShadow:"rgba(0,0,0,1)",colorNeedleShadowUp:"rgba(2,255,255,0.2)",colorNeedleShadowDown:"rgba(188,143,143,0.45)",colorBarStroke:"#222",colorBar:"#ccc",colorBarProgress:"#888",colorBarShadow:"#000",fontNumbers:"Arial",fontTitle:"Arial",fontUnits:"Arial",fontValue:"Arial",fontNumbersSize:20,fontTitleSize:24,fontUnitsSize:22,fontValueSize:26,fontNumbersStyle:"normal",fontTitleStyle:"normal",fontUnitsStyle:"normal",fontValueStyle:"normal",fontNumbersWeight:"normal",fontTitleWeight:"normal",fontUnitsWeight:"normal",fontValueWeight:"normal",needle:!0,needleShadow:!0,needleType:"arrow",needleStart:5,needleEnd:85,needleWidth:4,borderOuterWidth:3,borderMiddleWidth:3,borderInnerWidth:3,borderShadowWidth:3,valueBox:!0,valueBoxStroke:5,valueBoxWidth:0,valueText:"",valueTextShadow:!0,valueBoxBorderRadius:2.5,highlights:[{from:20,to:60,color:"#eee"},{from:60,to:80,color:"#ccc"},{from:80,to:100,color:"#999"}],highlightsWidth:15,highlightsLineCap:"butt",barWidth:20,barStrokeWidth:0,barProgress:!0,barShadow:0};s.prototype=Object.create(Array.prototype),s.prototype.constructor=s,s.prototype.get=function(h){if(typeof h=="string")for(var m=0,v=this.length;m<v;m++){var C=this[m].options.renderTo.tagName?this[m].options.renderTo:document.getElementById(this[m].options.renderTo||"");if(C.getAttribute("id")===h)return this[m]}else if(typeof h=="number")return this[h];return null};var Gs="2.2.1",Re=Math.round,ki=Math.abs,ho=new s;ho.version=Gs;var Li=(function(h){function m(v){i(this,m);var C=e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this)),M=C.constructor.name;if(M==="BaseGauge")throw new TypeError("Attempt to instantiate abstract class!");if(ho.push(C),v.listeners&&Object.keys(v.listeners).forEach(function(L){(v.listeners[L]instanceof Array?v.listeners[L]:[v.listeners[L]]).forEach(function(q){C.on(L,q)})}),C.version=Gs,C.type=n[M]||m,C.initialized=!1,v.minValue=parseFloat(v.minValue),v.maxValue=parseFloat(v.maxValue),v.value=parseFloat(v.value)||0,v.borders||(v.borderInnerWidth=v.borderMiddleWidth=v.borderOuterWidth=0),!v.renderTo)throw TypeError("Canvas element was not specified when creating the Gauge object!");var D=v.renderTo.tagName?v.renderTo:document.getElementById(v.renderTo);if(!(D instanceof HTMLCanvasElement))throw TypeError("Given gauge canvas element is invalid!");return v.width=parseFloat(v.width)||0,v.height=parseFloat(v.height)||0,v.width&&v.height||(v.width||(v.width=D.parentNode?D.parentNode.offsetWidth:D.offsetWidth),v.height||(v.height=D.parentNode?D.parentNode.offsetHeight:D.offsetHeight)),C.options=v||{},C.options.animateOnInit&&(C._value=C.options.value,C.options.value=C.options.minValue),C.canvas=new Mi(D,v.width,v.height),C.canvas.onRedraw=C.draw.bind(C),C.animation=new Ws(v.animationRule,v.animationDuration),C}return t(m,h),zn(m,[{key:"update",value:function(v){return Object.assign(this.options,this.type.configure(v||{})),this.canvas.width=this.options.width,this.canvas.height=this.options.height,this.animation.rule=this.options.animationRule,this.animation.duration=this.options.animationDuration,this.canvas.redraw(),this}},{key:"destroy",value:function(){var v=ho.indexOf(this);~v&&ho.splice(v,1),this.canvas.destroy(),this.canvas=null,this.animation.destroy(),this.animation=null,this.emit("destroy")}},{key:"draw",value:function(){return this.options.animateOnInit&&!this.initialized&&(this.value=this._value,this.initialized=!0,this.emit("init")),this.emit("render"),this}},{key:"value",set:function(v){var C=this;v=m.ensureValue(v,this.options.minValue);var M=this.options.value;if(v!==M)if(this.options.animation){if(this.animation.frame&&(this.options.value=this._value,this._value===v))return this.animation.cancel(),void delete this._value;this._value===void 0&&(this._value=v),this.emit("animationStart"),this.animation.animate(function(D){var L=M+(v-M)*D;C.options.animatedValue&&C.emit("value",L,C.value),C.options.value=L,C.draw(),C.emit("animate",D,C.options.value)},function(){C._value!==void 0&&(C.emit("value",C._value,C.value),C.options.value=C._value,delete C._value),C.draw(),C.emit("animationEnd"),C.animation.frame=null})}else this.emit("value",v,this.value),this.options.value=v,this.draw()},get:function(){return this._value===void 0?this.options.value:this._value}}],[{key:"configure",value:function(v){return v}},{key:"initialize",value:function(v,C){return new fa(C,"canvas",v)}},{key:"fromElement",value:function(v){var C=fa.toCamelCase(v.getAttribute("data-type")),M=v.attributes,D=0,L=M.length,q={};if(C){for(/Gauge$/.test(C)||(C+="Gauge");D<L;D++)q[fa.toCamelCase(M[D].name.replace(/^data-/,""),!1)]=fa.parse(M[D].value);new fa(q,v.tagName,C).process(v)}}},{key:"ensureValue",value:function(v){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return v=parseFloat(v),!isNaN(v)&&isFinite(v)||(v=parseFloat(C)||0),v}},{key:"mod",value:function(v,C){return(v%C+C)%C}},{key:"version",get:function(){return Gs}}]),m})(af);n!==void 0&&(n.BaseGauge=Li,n.gauges=(window.document||{}).gauges=ho);var of=/{([_a-zA-Z]+[_a-zA-Z0-9]*)}/g,ve={roundRect:b,padValue:x,formatMajorTickNumber:_,radians:k,radialPoint:S,linearGradient:F,drawNeedleShadow:j,drawValueBox:ee,verifyError:c,prepareTicks:f,font:Y,normalizedValue:Te,formatContext:p},po=Math.PI,Bs=po/2,bd=Object.assign({},Fs,{ticksAngle:270,startAngle:45,colorNeedleCircleOuter:"#f0f0f0",colorNeedleCircleOuterEnd:"#ccc",colorNeedleCircleInner:"#e8e8e8",colorNeedleCircleInnerEnd:"#f5f5f5",needleCircleSize:10,needleCircleInner:!0,needleCircleOuter:!0,needleStart:20,animationTarget:"needle",useMinPath:!1,barWidth:0,barStartPosition:"left"}),rf=(function(h){function m(v){return i(this,m),v=Object.assign({},bd,v||{}),e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,m.configure(v)))}return t(m,h),zn(m,[{key:"draw",value:function(){try{var v=this.canvas,C=[-v.drawX,-v.drawY,v.drawWidth,v.drawHeight],M=C[0],D=C[1],L=C[2],q=C[3],G=this.options;if(G.animationTarget==="needle"){if(!v.elementClone.initialized){var $=v.contextClone;$.clearRect(M,D,L,q),this.emit("beforePlate"),le($,G),this.emit("beforeHighlights"),me($,G),this.emit("beforeMinorTicks"),de($,G),this.emit("beforeMajorTicks"),Ve($,G),this.emit("beforeNumbers"),ft($,G),this.emit("beforeTitle"),Xt($,G),this.emit("beforeUnits"),bn($,G),v.elementClone.initialized=!0}this.canvas.commit(),v.context.clearRect(M,D,L,q),v.context.drawImage(v.elementClone,M,D,L,q),this.emit("beforeProgressBar"),cd(v.context,G),this.emit("beforeValueBox"),dd(v.context,G,ud(this)),this.emit("beforeNeedle"),An(v.context,G)}else{var oe=-ve.radians((G.value-G.minValue)/(G.maxValue-G.minValue)*G.ticksAngle);if(v.context.clearRect(M,D,L,q),this.emit("beforePlate"),le(v.context,G),v.context.rotate(oe),this.emit("beforeHighlights"),me(v.context,G),this.emit("beforeMinorTicks"),de(v.context,G),this.emit("beforeMajorTicks"),Ve(v.context,G),this.emit("beforeNumbers"),ft(v.context,G),this.emit("beforeProgressBar"),cd(v.context,G),v.context.rotate(-oe),!v.elementClone.initialized){var se=v.contextClone;se.clearRect(M,D,L,q),this.emit("beforeTitle"),Xt(se,G),this.emit("beforeUnits"),bn(se,G),this.emit("beforeNeedle"),An(se,G),v.elementClone.initialized=!0}v.context.drawImage(v.elementClone,M,D,L,q)}this.emit("beforeValueBox"),dd(v.context,G,ud(this)),Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"draw",this).call(this)}catch(we){ve.verifyError(we)}return this}},{key:"value",set:function(v){v=Li.ensureValue(v,this.options.minValue),this.options.animation&&this.options.ticksAngle===360&&this.options.useMinPath&&(this._value=v,v=this.options.value+((v-this.options.value)%360+540)%360-180),nf(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"value",v,this)},get:function(){return Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"value",this)}}],[{key:"configure",value:function(v){return v.barWidth>50&&(v.barWidth=50),isNaN(v.startAngle)&&(v.startAngle=45),isNaN(v.ticksAngle)&&(v.ticksAngle=270),v.ticksAngle>360&&(v.ticksAngle=360),v.ticksAngle<0&&(v.ticksAngle=0),v.startAngle<0&&(v.startAngle=0),v.startAngle>360&&(v.startAngle=360),v}}]),m})(Li);n!==void 0&&(n.RadialGauge=rf),Li.initialize("RadialGauge",bd);var Ad=Object.assign({},Fs,{borderRadius:0,barBeginCircle:30,colorBarEnd:"",colorBarProgressEnd:"",needleWidth:6,tickSide:"both",needleSide:"both",numberSide:"both",ticksWidth:10,ticksWidthMinor:5,ticksPadding:5,barLength:85,fontTitleSize:26,highlightsWidth:10}),sf=(function(h){function m(v){return i(this,m),v=Object.assign({},Ad,v||{}),e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,m.configure(v)))}return t(m,h),zn(m,[{key:"draw",value:function(){try{var v=this.canvas,C=[-v.drawX,-v.drawY,v.drawWidth,v.drawHeight],M=C[0],D=C[1],L=C[2],q=C[3],G=this.options;if(!v.elementClone.initialized){var $=v.contextClone;$.clearRect(M,D,L,q),this.emit("beforePlate"),this.drawBox=Ug($,G,M,D,L,q),this.emit("beforeBar"),qg.apply(void 0,[$,G].concat(a(this.drawBox))),v.contextClone.barDimensions=$.barDimensions,this.emit("beforeHighlights"),jg($,G),this.emit("beforeMinorTicks"),Yg($,G),this.emit("beforeMajorTicks"),$g($,G),this.emit("beforeNumbers"),Zg($,G),this.emit("beforeTitle"),Qg($,G),this.emit("beforeUnits"),Xg($,G),v.elementClone.initialized=!0}this.canvas.commit(),v.context.clearRect(M,D,L,q),v.context.drawImage(v.elementClone,M,D,L,q),this.emit("beforeProgressBar"),Hg.apply(void 0,[v.context,G].concat(a(this.drawBox))),this.emit("beforeNeedle"),Kg(v.context,G),this.emit("beforeValueBox"),tf.apply(void 0,[v.context,G,G.animatedValue?this.options.value:this.value].concat(a(this.drawBox))),Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"draw",this).call(this)}catch(oe){ve.verifyError(oe)}return this}}],[{key:"configure",value:function(v){return v.barStrokeWidth>=v.barWidth&&(v.barStrokeWidth=Re(v.barWidth/2)),v.hasLeft=hd("right",v),v.hasRight=hd("left",v),v.value>v.maxValue&&(v.value=v.maxValue),v.value<v.minValue&&(v.value=v.minValue),Li.configure(v)}}]),m})(Li);n!==void 0&&(n.LinearGauge=sf),Li.initialize("LinearGauge",Ad),typeof Ss<"u"&&Object.assign(n,{Collection:s,GenericOptions:Fs,Animation:Ws,BaseGauge:Li,drawings:ve,SmartCanvas:Mi,DomObserver:fa,vendorize:o})})(typeof Ss<"u"?Ss.exports:window)});var nu=[{id:null,name:"Dashboard 1",icon:"dashboard-dashboard",configuration:[{w:24,h:24,id:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc",selector:"widget-host2",input:{widgetProperties:{type:"widget-tutorial",uuid:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc"}},x:0,y:0}],collapseSplitShell:!1}];var mt=(()=>{class n{_settings=A(At);_router=A(Jd);_destroyRef=A(ct);dashboards=w([],{equal:gi});activeDashboard=w(null);_widgetAction=new Wi(null);widgetAction$=this._widgetAction.asObservable();isDashboardStatic=w(!0);widgetClipboard=w(null);layoutEditSaved=w(0);layoutEditCanceled=w(0);constructor(){let e=this._settings.getDashboardConfig();if(!e||e.length===0){console.warn("[Dashboard Service] No dashboards found in settings, creating blank dashboard");let i=nu.map(o=>ue(ie({},o),{id:Gt.create()}));this.dashboards.set([...i])}else this.dashboards.set(e);this.applyDashboardParam(this.getRouteParam("id"),!1);let t=this._router.events.pipe(di(i=>i instanceof Kd),er({bufferSize:1,refCount:!0}),tt(this._destroyRef));t.pipe(ci(1),Yt(()=>this.getRouteParam("id"))).subscribe(i=>this.applyDashboardParam(i,!0)),t.pipe(tr(1),Yt(()=>this.getRouteParam("id")),Ko()).subscribe(i=>this.applyDashboardParam(i,!1)),V(()=>{let i=this.dashboards();W(()=>{this._settings.saveDashboards(i)})})}getRouteParam(e){let t=this._router.routerState.snapshot.root;for(;t;){if(t.paramMap.has(e))return t.paramMap.get(e);t=t.firstChild??null}return null}applyDashboardParam(e,t){if(e===null||e===""){t&&this.setActiveDashboardIndex(0);return}let i=Number(e);if(Number.isNaN(i)){t&&this.setActiveDashboardIndex(0);return}this.setActiveDashboardIndex(i)}setActiveDashboardIndex(e){e!==this.activeDashboard()&&(e>=0&&e<this.dashboards().length?this.activeDashboard.set(e):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`))}toggleStaticDashboard(){this.isDashboardStatic.set(!this.isDashboardStatic())}add(e,t,i,o){let r=0;return this.dashboards.update(s=>{let c=[...s,{id:Gt.create(),name:e,icon:i??"dashboard-dashboard",configuration:t,collapseSplitShell:o??!1}];return r=c.length-1,c}),r}update(e,t,i,o){this.dashboards.update(r=>r.map((s,c)=>c===e?ue(ie({},s),{name:t,icon:i??"dashboard-dashboard",collapseSplitShell:o??!1}):s))}delete(e){this.dashboards.update(t=>t.filter((i,o)=>o!==e)),this.dashboards().length===0?(this.add("Dashboard "+(this.dashboards().length+1),[]),this.activeDashboard.set(0)):this.activeDashboard()>this.dashboards().length-1&&this.activeDashboard.set(this.dashboards().length-1)}duplicate(e,t,i,o){if(e<0||e>=this.dashboards().length)return console.error(`[Dashboard Service] Invalid itemIndex: ${e}`),-1;let r=this.dashboards()[e],s=Bt(r);s.id=Gt.create(),s.name=t,s.icon=i||"dashboard-dashboard",s.collapseSplitShell=o??!1,Array.isArray(s.configuration)?s.configuration.forEach(p=>{p&&p.input?.widgetProperties?(p.id=Gt.create(),p.input.widgetProperties.uuid=p.id):console.error("Dashboard Service] Widget configuration is missing required properties:",p)}):(console.error("Dashboard Service] Dashboard configuration is not an array:",s.configuration),s.configuration=[]);let c=-1;return this.dashboards.update(p=>{let f=[...p,s];return c=f.length-1,f}),c}updateConfiguration(e,t){this.dashboards.update(i=>i.map((o,r)=>r===e?gi(o.configuration,t)?o:ue(ie({},o),{configuration:t}):o))}previousDashboard(){this.activeDashboard()+1>this.dashboards().length-1?this.activeDashboard.set(0):this.activeDashboard.set(this.activeDashboard()+1)}nextDashboard(){this.activeDashboard()-1<0?this.activeDashboard.set(this.dashboards().length-1):this.activeDashboard.set(this.activeDashboard()-1)}navigateToActive(){this._router.navigate(["/dashboard",this.activeDashboard()])}navigateTo(e){e>=0&&e<this.dashboards().length?this._router.navigate(["/dashboard",e]):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`)}navigateToNextDashboard(){let e=null;this.activeDashboard()-1<0?e=this.dashboards().length-1:e=this.activeDashboard()-1,this._router.navigate(["/dashboard",e])}navigateToPreviousDashboard(){let e=null;this.activeDashboard()+1>=this.dashboards().length?e=0:e=this.activeDashboard()+1,this._router.navigate(["/dashboard",e])}deleteWidget(e){this._widgetAction.next({id:e,operation:"delete"})}duplicateWidget(e){this._widgetAction.next({id:e,operation:"duplicate"})}copyWidget(e){this._widgetAction.next({id:e,operation:"copy"})}cutWidget(e){this._widgetAction.next({id:e,operation:"cut"})}setWidgetClipboardFromNode(e){let t=e?.input?.widgetProperties,i=t?.type;i&&this.widgetClipboard.set({w:e.w,h:e.h,selector:e.selector,input:{widgetProperties:{type:i,uuid:"clipboard",config:Bt(t.config)}}})}clearWidgetClipboard(){this.widgetClipboard.set(null)}setStaticDashboard(e){this.isDashboardStatic.set(e)}notifyLayoutEditSaved(){this.layoutEditSaved.update(e=>e+1)}notifyLayoutEditCanceled(){this.layoutEditCanceled.update(e=>e+1)}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var on=(()=>{class n{appSettings=A(At);data=A(ti);_svcDatasetConfigs=[];_svcDataSource=[];_svcSubjectObserverRegistry=[];signedAnglePaths=new Set(["self.navigation.attitude.roll","self.navigation.attitude.pitch","self.navigation.attitude.yaw","self.environment.wind.angleApparent","self.environment.wind.angleTrueGround","self.environment.wind.angleTrueWater","self.steering.rudderAngle"]);constructor(){this._svcDatasetConfigs=this.appSettings.getDataSets(),this.cleanupDatasets(),this.startAll()}cleanupDatasets(){if(this.appSettings.configUpgrade()||this.appSettings.getAppConfig().configVersion<12)return;let t=this.appSettings.getDashboardConfig(),i=new Set;t.forEach(c=>{c.configuration?.length&&c.configuration?.forEach(p=>{p?.id&&i.add(p.id)})});function o(c){let p=c.match(/^(windtrends|speedtrends)-(.+)$/);return p?p[2]:null}let r=[],s=[];for(let c of this._svcDatasetConfigs){let p=c.label||"",f=!1;if(p.startsWith("windtrends-")||p.startsWith("speedtrends-")){let b=o(p);f=!!(b&&i.has(b))}else(p.startsWith("simple-chart-")||(p.match(/\|/g)||[]).length===4)&&(f=i.has(c.uuid));f?s.push(c):r.push(c)}r.length&&(r.forEach(c=>{console.warn(`[DatasetService] Cleaned dataset: uuid=${c.uuid}, label="${c.label}"`)}),this._svcDatasetConfigs=s,this.appSettings.saveDataSets(this._svcDatasetConfigs))}setupServiceSubjectRegistry(e,t){let i=this._svcSubjectObserverRegistry.findIndex(o=>o.datasetUuid==e);i>=0&&(this._svcSubjectObserverRegistry[i].rxjsSubject.complete(),this._svcSubjectObserverRegistry.splice(i,1)),this._svcSubjectObserverRegistry.push({datasetUuid:e,rxjsSubject:new wd(t)})}createDataSourceConfiguration(e){let r={uuid:e.uuid,pathObserverSubscription:null,sampleTime:null,maxDataPoints:null,smoothingPeriod:null,historicalData:[]},s=p(e.timeScaleFormat,e.period),c=s>0?Math.max(100,Math.round(s/120)):1e3;return r.sampleTime=c,r.maxDataPoints=Math.max(1,Math.ceil(s/c)),r.smoothingPeriod=Math.max(1,Math.floor(r.maxDataPoints*.25)),(!r.maxDataPoints||r.maxDataPoints<1)&&(r.maxDataPoints=1),(!r.sampleTime||r.sampleTime<1)&&(r.sampleTime=1),r;function p(f,b){switch(f){case"Last Minute":return 6e4;case"Last 5 Minutes":return 5*6e4;case"Last 30 Minutes":return 30*6e4;case"hour":return Math.max(0,b)*60*6e4;case"minute":return Math.max(0,b)*6e4;case"second":return Math.max(0,b)*1e3;default:return 0}}}startAll(){console.log("[Dataset Service] Auto Starting "+this._svcDatasetConfigs.length.toString()+" Datasets");for(let e of this._svcDatasetConfigs)this.start(e.uuid)}start(e){let t=this._svcDatasetConfigs.find(f=>f.uuid==e);if(!t){console.warn(`[Dataset Service] Dataset UUID:${e} not found`);return}let i=this.createDataSourceConfiguration(t);this.setupServiceSubjectRegistry(i.uuid,i.maxDataPoints);let o=this._svcDataSource[this._svcDataSource.push(i)-1];console.log(`[Dataset Service] Starting recording process: ${t.path}, Scale: ${t.timeScaleFormat}, Period: ${t.period}, Datapoints: ${i.maxDataPoints}`);let r=this.resolveAngleDomain(t.path,t.baseUnit),s=this.data.subscribePath(t.path,t.pathSource).pipe(di(f=>f?.data?.value!==null),er({bufferSize:1,refCount:!0})),c=s.pipe(ci(1)),p=Hn(i.sampleTime,i.sampleTime).pipe(Nd(s,(f,b)=>b));o.pathObserverSubscription=li(c,p).subscribe(f=>{o.maxDataPoints>0&&o.historicalData.length>=o.maxDataPoints&&o.historicalData.shift(),o.historicalData.push(f.data.value);let b=this.updateDataset(o,t.baseUnit,r);this._svcSubjectObserverRegistry.find(x=>x.datasetUuid===o.uuid).rxjsSubject.next(b)})}stop(e){let t=this._svcDataSource.findIndex(i=>i.uuid==e);console.log(`[Dataset Service] Stopping Dataset ${e} data capture`),this._svcDataSource[t].pathObserverSubscription.unsubscribe(),this._svcDataSource.splice(t,1)}list(){return Bt(this._svcDatasetConfigs)}getDatasetConfig(e){return this._svcDatasetConfigs.find(t=>t.uuid===e)}getDataSourceInfo(e){return this._svcDataSource.find(t=>t.uuid===e)}create(e,t,i,o,r,s=!0,c=!0,p){if(!e||!t||!i||!o||!r)return null;let f=p||Gt.create(),b={uuid:f,path:e,pathSource:t,baseUnit:this.data.getPathUnitType(e),timeScaleFormat:i,period:o,label:r,editable:c};return console.log(`[Dataset Service] Creating ${s?"":"non-"}persistent ${c?"":"hidden "}dataset: ${b.uuid}, Path: ${b.path}, Source: ${b.pathSource} Scale: ${b.timeScaleFormat}, Period: ${b.period}`),this._svcDatasetConfigs.push(b),this.start(f),s===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),f}edit(e,t=!0){let i=this._svcDatasetConfigs.find(o=>o.uuid===e.uuid);return i?JSON.stringify(i)===JSON.stringify(e)?(console.log(`[Dataset Service] No changes detected for Dataset ${e.uuid}.`),!1):(this.stop(e.uuid),console.log(`[Dataset Service] Updating Dataset: ${e.uuid}`),e.baseUnit=this.data.getPathUnitType(e.path),this._svcDatasetConfigs.splice(this._svcDatasetConfigs.findIndex(o=>o.uuid===e.uuid),1,e),this.start(e.uuid),t===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),!0):!1}remove(e,t=!0){return!e||e===""||this._svcDatasetConfigs.findIndex(i=>i.uuid===e)===-1?!1:(this.stop(e),console.log(`[Dataset Service] Removing ${t?"":"non-"}persistent Dataset: ${e}`),this._svcDatasetConfigs.splice(this._svcDatasetConfigs.findIndex(i=>i.uuid===e),1),this._svcSubjectObserverRegistry.find(i=>i.datasetUuid===e).rxjsSubject.complete(),this._svcSubjectObserverRegistry.splice(this._svcSubjectObserverRegistry.findIndex(i=>i.datasetUuid===e),1),t===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),!0)}getDatasetObservable(e){let t=this._svcSubjectObserverRegistry.find(i=>i.datasetUuid==e);return t?t.rxjsSubject.asObservable():null}getDatasetBatchThenLiveObservable(e){let t=this._svcSubjectObserverRegistry.find(c=>c.datasetUuid==e);if(!t)return null;let i=t.rxjsSubject,o=i._buffer?i._buffer.slice():[],r=Sd([o]),s=i.pipe(tr(o.length));return kd(r,s)}updateDataset(e,t,i="scalar"){let o=null,r=null,s=null,c=null;if(t==="rad"){o=this.circularMeanRad(e.historicalData);let x=e.historicalData.slice(-e.smoothingPeriod);r=this.circularMeanRad(x);let{min:_,max:k}=this.circularMinMaxRad(e.historicalData);i==="direction"?(o=this.normalizeToDirection(o),r=this.normalizeToDirection(r),s=this.normalizeToDirection(_),c=this.normalizeToDirection(k)):i==="signed"?(o=this.normalizeToSigned(o),r=this.normalizeToSigned(r),s=this.normalizeToSigned(_),c=this.normalizeToSigned(k)):(s=_,c=k)}else o=f(e.historicalData),r=b(e.historicalData,e.smoothingPeriod),s=Math.min(...e.historicalData),c=Math.max(...e.historicalData);return{timestamp:Date.now(),data:{value:t==="rad"?i==="signed"?this.normalizeToSigned(e.historicalData[e.historicalData.length-1]):this.normalizeToDirection(e.historicalData[e.historicalData.length-1]):e.historicalData[e.historicalData.length-1],sma:r,ema:null,doubleEma:null,lastAverage:o,lastMinimum:s,lastMaximum:c}};function f(x){return x.length===0?null:x.reduce((k,S)=>k+S,0)/x.length}function b(x,_){x.length<_&&(_=x.length);let k=0;for(let S=x.length-_;S<x.length;S++)k+=x[S];return k/_}}circularMeanRad(e){if(e.length===0)return 0;let t=e.reduce((o,r)=>o+Math.sin(r),0),i=e.reduce((o,r)=>o+Math.cos(r),0);return Math.atan2(t/e.length,i/e.length)}circularMinMaxRad(e){if(e.length===0)return{min:0,max:0};let t=e.map(c=>(c*180/Math.PI+360)%360).sort((c,p)=>c-p),i=0,o=0;for(let c=0;c<t.length;c++){let p=(c+1)%t.length,f=(t[p]-t[c]+360)%360;f>i&&(i=f,o=p)}let r=t[o]*Math.PI/180,s=t[(o-1+t.length)%t.length]*Math.PI/180;return{min:r,max:s}}resolveAngleDomain(e,t){if(t!=="rad")return"scalar";let i=this.normalizePathKey(e);for(let o of this.signedAnglePaths)if(i===this.normalizePathKey(o))return"signed";return"direction"}normalizePathKey(e){return e.replace(/^vessels\.self\./,"").replace(/^self\./,"")}mod(e,t){return(e%t+t)%t}normalizeToDirection(e){let t=2*Math.PI;return this.mod(e,t)}normalizeToSigned(e){let t=2*Math.PI;return this.mod(e+Math.PI,t)-Math.PI}removeIfExists(e,t=!0){return!e||this._svcDatasetConfigs.findIndex(i=>i.uuid===e)===-1?!1:this.remove(e,t)}ngOnDestroy(){[...this._svcDataSource].forEach(e=>{try{this.stop(e.uuid)}catch(t){}}),this._svcSubjectObserverRegistry.forEach(e=>e.rxjsSubject.complete()),this._svcSubjectObserverRegistry=[]}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var au=(()=>{class n{kipTimers={};constructor(){}createTimer(e,t,i){return e in this.kipTimers?this.kipTimers[e].currentValue.asObservable():(this.kipTimers[e]={currentValue:new Wi(t),timeoutID:null,intervalMS:i},this.kipTimers[e].currentValue.asObservable())}startTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].timeoutID===null&&(this.kipTimers[e].timeoutID=setInterval(()=>{this.kipTimers[e].currentValue.next(this.kipTimers[e].currentValue.value+1)},this.kipTimers[e].intervalMS))}stopTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].timeoutID!==null&&(clearInterval(this.kipTimers[e].timeoutID),this.kipTimers[e].timeoutID=null)}setTimer(e,t){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].currentValue.next(t)}deleteTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&(this.stopTimer(e),this.kipTimers[e].currentValue.complete(),delete this.kipTimers[e])}isRunning(e){let t=!1;return e in this.kipTimers&&(t=this.kipTimers[e].timeoutID!==null),t}ngOnDestroy(){Object.keys(this.kipTimers).forEach(e=>{this.kipTimers[e].timeoutID&&(clearInterval(this.kipTimers[e].timeoutID),this.kipTimers[e].timeoutID=null),this.kipTimers[e].currentValue.complete()}),this.kipTimers={}}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var ou=(()=>{class n{sanitizer=A(ka);transform(e){return this.sanitizer.bypassSecurityTrustResourceUrl(e)}static \u0275fac=function(t){return new(t||n)};static \u0275pipe=dr({name:"safe",type:n,pure:!0})}return n})();var df={minDist:230,maxDur:550,minVelocity:1.5,axisDominance:1.8,deadzoneMs:160,purityRatio:.8,lockThreshold:28,directionLockAngle:25,reversalPrimaryThreshold:34};function Qa(n){let a=ie(ie({},df),n);return`(() => {
|
|
1
|
+
import{$ as Pn,A as Zs,B as Tr,C as yo,D as Qs,E as xo,F as Co,G as Fa,H as Ga,I as Xs,J as Ks,K as Ba,L as wo,M as Js,N as Yc,O as Zc,P as Qc,Q as Ua,R as Dn,S as za,T as Et,U as qa,V as Ha,W as ja,X as Er,Y as Dr,Z as Xc,_ as $a,a as Ht,b as ei,c as tn,d as Sr,e as qc,f as Hc,g as jc,h as $c,i as lt,j as ea,k as Pi,l as Tn,m as ta,n as cn,o as nn,p as an,q as Ii,r as En,s as oi,t as _r,u as Mr,v as La,w as ia,x as kr,y as Wa,z as Oi}from"./chunk-2MWBAYPJ.js";import{a as zc,b as wr}from"./chunk-5DLSQ773.js";import{a as Kc,b as Jc,c as eu,d as tu,e as iu}from"./chunk-2KMYPGX4.js";import{a as yi,b as kn,c as be,d as Ys,e as Uc,f as ti,g as st,i as Ya,j as Za}from"./chunk-VH4ZIU4T.js";import{a as Oc,b as Rc,c as Nc,d as Va,e as Vc,f as qt,g as Lc,h as Wc,i as Fc,k as Gc,m as Ao,n as Bc}from"./chunk-IWK4FHBL.js";import{a as Kd,c as Jd,d as ec}from"./chunk-PSF2OKKT.js";import{a as Ra,b as Na}from"./chunk-HJQQWPGC.js";import{a as $i,b as Cc,c as wc,d as Sc,e as Yi,f as vi,h as _c,i as Zi,j as Qi,k as Xi,l as Cn,m as Jt,o as _t,p as _n,q as Pc,r as Mn,t as Ic,v as Mt,w as bi,x as kt,y as Ai}from"./chunk-KKJXPB75.js";import{A as Ia,B as Ki,C as Ji,D as Ec,E as Dc,F as en,G as Ct,H as Oa,I as wn,J as wt,L as Sn,M as Ot,N as St,a as Gt,b as $d,d as Bt,e as gi,f as Yd,i as Zd,j as Qd,k as pr,l as Xd,m as At,n as Da,o as xt,q as zt,s as ut,t as It,u as Mc,v as kc,w as Cr,x as Tc,y as vt,z as Pa}from"./chunk-XEJJOWK6.js";import{b as cc,f as uc,g as mc,h as gc,i as fc,j as vc,m as bc,n as Ac,p as yc,t as xc}from"./chunk-PESXPDBT.js";import{$ as er,$a as Wd,$c as Hd,$d as Di,Aa as Ld,Ab as O,Ad as nc,Ba as ct,Bb as R,Cb as Ne,Cc as te,Ce as Je,D as kd,Da as Rt,Db as Gi,Dc as Bd,De as rt,E as Td,Ea as Fe,Eb as ye,Ed as gr,Fb as xe,Fc as ur,Ga as w,Gb as I,Gc as nt,Gd as Ta,H as Hn,Ha as V,Hb as l,Hc as y,Hd as ac,I as Xo,Ia as W,Ib as u,Ic as ce,Id as oc,J as li,Ja as Fi,Jb as N,K as di,Kb as E,Kc as Ud,Kd as Ea,Lb as P,Ma as qe,Mb as Q,Mc as Zt,Nb as Bi,Nd as rc,O as Ed,Ob as Ui,Oc as Xe,P as yn,Pb as cr,Pc as js,Q as ci,Qb as re,Qd as sc,Rb as Ti,Rd as Hi,S as Dd,Sa as or,Sb as z,Sd as xn,T as Pd,Ta as rr,Tb as vo,Td as lc,U as Ko,Ua as $n,Ub as T,V as Jo,Vb as xa,Vd as $s,Wb as Ca,Wd as fr,Xb as wa,Xd as dc,Ya as g,Yb as zi,Z as Id,Zb as Lt,Zc as zd,_ as Od,_a as sr,_b as Wt,_c as qd,a as ie,aa as tr,ac as Se,b as ue,ba,bb as ya,bc as _e,be as fi,ca as ir,cb as Yn,cc as Tt,cd as mr,d as lf,da as nr,dc as ge,dd as _a,e as Cd,ec as Qe,f as et,fa as ar,fb as lr,fc as Sa,fd as Ma,g as va,ga as Rd,gc as Ke,ha as Nd,hc as d,hd as jd,he as vr,ic as X,ie as br,j as Us,jb as H,jc as he,je as Ut,k as Vt,ka as Aa,kb as hi,kc as Ft,ke as Ar,la as pt,lb as bt,ld as hr,le as ji,m as Wi,ma as ui,mb as dr,mc as Zn,me as yr,n as wd,nb as Fd,nc as Qn,ne as yt,oa as mi,ob as fo,oc as Xn,pb as pi,pc as Kn,pd as tt,pe as xr,qa as A,qb as Gd,qc as sn,qd as qi,qe as ot,r as Sd,rc as ln,s as zs,sc as Ei,t as _d,ta as Vd,tc as Hs,uc as Jn,ud as ka,va as B,vc as bo,w as Qo,wa as U,x as qs,xa as J,xc as at,xe as hc,y as Md,ya as We,yb as Z,yc as Pt,yd as tc,z as Yt,za as jn,zc as dn,zd as ic,ze as pc}from"./chunk-TGGJAGV7.js";var Gl=lf((w7,Ss)=>{(function(n){"use strict";function a(h){if(Array.isArray(h)){for(var m=0,v=Array(h.length);m<h.length;m++)v[m]=h[m];return v}return Array.from(h)}function e(h,m){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!m||typeof m!="object"&&typeof m!="function"?h:m}function t(h,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);h.prototype=Object.create(m&&m.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(h,m):h.__proto__=m)}function i(h,m){if(!(h instanceof m))throw new TypeError("Cannot call a class as a function")}function o(h,m){if(m||(m=typeof window>"u"?global:window),m[h]!==void 0)return m[h];if(Zo===null){var v=window.getComputedStyle(document.documentElement,"");Zo=(Array.prototype.slice.call(v).join("").match(/-(moz|webkit|ms)-/)||v.OLink===""&&["","o"]||["",""])[1]}if(Zo==="")return null;var C=h.charAt(0).toUpperCase()+h.substr(1),M=m[Zo+C];return M!==void 0?M:null}function r(h,m,v,C,M,D,L){if(typeof C!="function")throw new TypeError("Invalid animation rule:",C);var q=h-v,G=q/M,$=0;G>1&&(G=1),G!==1&&($=C(G),isFinite($)&&!isNaN($)&&(G=$)),m&&m(G),q<M?L.frame=vd(function(oe){return r(oe,m,v,C,M,D,L)}):(D&&D(),L.inProgress=!1)}function s(){Array.prototype.constructor.apply(this,arguments)}function c(h){if(!(h instanceof DOMException&&h.result===2152923147))throw h}function p(h,m){return m.replace(of,function(v,C){var M=h[C];return M!==void 0?M:v})}function f(h){return h.majorTicks instanceof Array||(h.majorTicks=h.majorTicks?[h.majorTicks]:[]),h.majorTicks.length||(h.majorTicks.push(ve.formatMajorTickNumber(h.minValue,h)),h.majorTicks.push(ve.formatMajorTickNumber(h.maxValue,h))),[h.tickSide!=="right",h.tickSide!=="left"]}function b(h,m,v,C,M,D){h.beginPath(),h.moveTo(m+D,v),h.lineTo(m+C-D,v),h.quadraticCurveTo(m+C,v,m+C,v+D),h.lineTo(m+C,v+M-D),h.quadraticCurveTo(m+C,v+M,m+C-D,v+M),h.lineTo(m+D,v+M),h.quadraticCurveTo(m,v+M,m,v+M-D),h.lineTo(m,v+D),h.quadraticCurveTo(m,v,m+D,v),h.closePath()}function x(h,m){var v=m.valueDec,C=m.valueInt,M=0,D=void 0,L=void 0,q=void 0;if(h=parseFloat(h),q=h<0,h=Math.abs(h),v>0){for(L=h.toFixed(v).toString().split("."),D=C-L[0].length;M<D;++M)L[0]="0"+L[0];L=(q?"-":"")+L[0]+"."+L[1]}else{for(L=Math.round(h).toString(),D=C-L.length;M<D;++M)L="0"+L;L=(q?"-":"")+L}return L}function _(h,m){var v=void 0,C=!1;return v=m.majorTicksDec===0?Math.round(h).toString():h.toFixed(m.majorTicksDec),m.majorTicksInt>1?(C=~v.indexOf("."),~v.indexOf("-")?"-"+[m.majorTicksInt+m.majorTicksDec+2+(C?1:0)-v.length].join("0")+v.replace("-",""):[m.majorTicksInt+m.majorTicksDec+1+(C?1:0)-v.length].join("0")+v):v}function k(h){return h*Math.PI/180}function S(h,m){return{x:-h*Math.sin(m),y:h*Math.cos(m)}}function F(h,m,v,C){var M=!(arguments.length>4&&arguments[4]!==void 0)||arguments[4],D=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,L=h.createLinearGradient(M?0:D,M?D:0,M?0:C,M?C:0);return L.addColorStop(0,m),L.addColorStop(1,v),L}function j(h,m){m.needleShadow&&(h.shadowOffsetX=2,h.shadowOffsetY=2,h.shadowBlur=10,h.shadowColor=m.colorNeedleShadowDown)}function Y(h,m,v){return h["font"+m+"Style"]+" "+h["font"+m+"Weight"]+" "+h["font"+m+"Size"]*v+"px "+h["font"+m]}function K(h){h.shadowOffsetX=null,h.shadowOffsetY=null,h.shadowBlur=null,h.shadowColor="",h.strokeStyle=null,h.lineWidth=0,h.save()}function pe(h,m,v,C){m.valueTextShadow&&(h.shadowOffsetX=v,h.shadowOffsetY=v,h.shadowBlur=C,h.shadowColor=m.colorValueTextShadow)}function ee(h,m,v,C,M,D){if(m.valueBox){K(h);var L=m.valueDec?1+m.valueDec:0,q="9".repeat(Math.max.apply(null,[String(parseInt(v)).length+L].concat(m.majorTicks.map(function(ze){return String(parseInt(ze,10)).length+L})))),G=m.valueText||x(v,m),$=D/200,oe=D/100,se=.4*oe,we=1.2*oe;h.font=Y(m,"Value",$),pe(h,m,se,we);var ke=h.measureText(m.valueText?G:"-"+x(Number(q),m)).width;K(h);var Pe=parseFloat(m.fontValueSize)*$+se+we,$e=oe*parseFloat(m.valueBoxStroke),De=2*D-2*$e,He=ke+10*oe,je=1.1*Pe+se+we,Ye=oe*m.valueBoxBorderRadius,Ge=(parseFloat(m.valueBoxWidth)||0)/100*De;Ge>He&&(He=Ge),He>De&&(He=De);var Ue=C-He/2,Le=M-je/2,Ee=M-5.75*oe;if(h.beginPath(),Ye?b(h,Ue,Le,He,je,Ye):h.rect(Ue,Le,He,je),$e){var Ie=h.createRadialGradient(C,Ee,10*oe,C,Ee,20*oe);Ie.addColorStop(0,m.colorValueBoxRect),Ie.addColorStop(1,m.colorValueBoxRectEnd),h.strokeStyle=Ie,h.lineWidth=$e,h.stroke()}m.colorValueBoxShadow&&(h.shadowBlur=1.2*oe,h.shadowColor=m.colorValueBoxShadow),m.colorValueBoxBackground&&(h.fillStyle=m.colorValueBoxBackground,h.fill()),h.closePath(),h.restore(),pe(h,m,se,we),h.fillStyle=m.colorValueText,h.textAlign="center",h.textBaseline="alphabetic",h.fillText(G,Ue+He/2,M+je/2-Pe/3),h.restore()}}function Te(h){var m=h.value,v=h.minValue,C=h.maxValue,M=.01*(C-v);return{normal:m<v?v:m>C?C:m,indented:m<v?v-M:m>C?C+M:m}}function fe(h,m,v,C,M){v.beginPath(),v.arc(0,0,ki(h),0,2*po,!0),v.lineWidth=m,v.strokeStyle=M?ve.linearGradient(v,C,M,h):C,v.stroke(),v.closePath()}function ne(h,m){var v=Mi.pixelRatio;return h.maxRadius||(h.maxRadius=h.max-m.borderShadowWidth-m.borderOuterWidth*v-m.borderMiddleWidth*v-m.borderInnerWidth*v+(m.borderOuterWidth?.5:0)+(m.borderMiddleWidth?.5:0)+(m.borderInnerWidth?.5:0)),h.maxRadius}function le(h,m){function v(se,we,ke,Pe,$e,De){return we&&(!De&&m.borderShadowWidth&&(ke.save(),ke.shadowBlur=m.borderShadowWidth,ke.shadowColor=m.colorBorderShadow),fe(se,we*C,ke,Pe,$e),!De&&m.borderShadowWidth&&(De=!0,ke.restore())),De}var C=Mi.pixelRatio,M=m.borderShadowWidth*C,D=h.max-M-m.borderOuterWidth*C/2,L=D-m.borderOuterWidth*C/2-m.borderMiddleWidth*C/2+.5,q=L-m.borderMiddleWidth*C/2-m.borderInnerWidth*C/2+.5,G=ne(h,m),$=void 0,oe=!1;h.save(),oe=v(D,m.borderOuterWidth,h,m.colorBorderOuter,m.colorBorderOuterEnd,oe),oe=v(L,m.borderMiddleWidth,h,m.colorBorderMiddle,m.colorBorderMiddleEnd,oe),oe=v(q,m.borderInnerWidth,h,m.colorBorderInner,m.colorBorderInnerEnd,oe),!oe&&m.borderShadowWidth&&(h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),h.beginPath(),h.arc(0,0,ki(G),0,2*po,!0),m.colorPlateEnd?($=h.createRadialGradient(0,0,G/2,0,0,G),$.addColorStop(0,m.colorPlate),$.addColorStop(1,m.colorPlateEnd)):$=m.colorPlate,h.fillStyle=$,h.fill(),h.closePath(),h.restore()}function me(h,m){if(m.highlights!=="false"&&m.highlights.length&&m.highlightsWidth!==0){var v=h.max*(parseFloat(m.highlightsWidth)||0)/100,C=ki(Me(h,m)-v/2),M=m.highlights.length,D=(m.maxValue-m.minValue)/m.ticksAngle;h.save();for(var L=0;L<M;L++){var q=m.highlights[L];h.lineWidth=v,h.lineCap=m.highlightsLineCap,h.strokeStyle=q.color,h.beginPath(),h.rotate(Bs),h.arc(0,0,C,ve.radians(m.startAngle+(q.from-m.minValue)/D),ve.radians(m.startAngle+(q.to-m.minValue)/D),!1),h.stroke(),h.closePath(),h.restore(),h.save()}h.restore()}}function de(h,m){var v=Me(h,m),C=void 0,M=void 0,D=void 0,L=0,q=Math.abs(m.minorTicks)||0,G=m.ticksAngle/(m.maxValue-m.minValue);m.exactTicks?(M=m.maxValue-m.minValue,C=q?M/q:0,L=(Li.mod(m.majorTicks[0],q)||0)*G):C=q*(m.majorTicks.length-1),h.lineWidth=Mi.pixelRatio,h.strokeStyle=m.colorMinorTicks||m.colorStrokeTicks,h.save();for(var $=0;$<C;++$)(D=m.startAngle+L+$*(m.ticksAngle/C))<=m.ticksAngle+m.startAngle&&(h.rotate(ve.radians(D)),h.beginPath(),h.moveTo(0,v),h.lineTo(0,v-.075*h.max),it(h));h.restore()}function Me(h,m){var v=h.max/100;return ne(h,m)-5*v-(m.barWidth?2*(parseFloat(m.barStrokeWidth)||0)+((parseFloat(m.barWidth)||0)+5)*v:0)}function Ve(h,m){ve.prepareTicks(m);var v=ki(Me(h,m)),C=void 0,M=m.majorTicks.length,D=Mi.pixelRatio;h.lineWidth=2*D,C=m.colorMajorTicks instanceof Array?m.colorMajorTicks:new Array(M).fill(m.colorStrokeTicks||m.colorMajorTicks);for(var L=0;L<M;++L)h.save(),h.strokeStyle=C[L],h.rotate(ve.radians(Be(m,m.exactTicks?m.majorTicks[L]:L,M))),h.beginPath(),h.moveTo(0,v),h.lineTo(0,v-.15*h.max),h.stroke(),h.closePath(),h.restore();m.strokeTicks&&(h.save(),h.strokeStyle=m.colorStrokeTicks||C[0],h.rotate(Bs),h.beginPath(),h.arc(0,0,v,ve.radians(m.startAngle),ve.radians(m.startAngle+m.ticksAngle),!1),h.stroke(),h.closePath(),h.restore())}function Be(h,m,v){if(h.exactTicks){var C=h.ticksAngle/(h.maxValue-h.minValue);return h.startAngle+C*(m-h.minValue)}return h.startAngle+m*(h.ticksAngle/(v-1))}function it(h){h.stroke(),h.restore(),h.closePath(),h.save()}function ft(h,m){var v=Me(h,m)-.15*h.max,C={},M=0,D=m.majorTicks.length,L=m.animationTarget!=="needle",q=m.colorNumbers instanceof Array?m.colorNumbers:new Array(D).fill(m.colorNumbers),G=L?-(m.value-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle:0;for(L&&(h.save(),h.rotate(-ve.radians(G))),h.font=ve.font(m,"Numbers",h.max/200),h.lineWidth=0,h.textAlign="center",h.textBaseline="middle";M<D;++M){var $=G+Be(m,m.exactTicks?m.majorTicks[M]:M,D),oe=h.measureText(m.majorTicks[M]).width,se=m.fontNumbersSize,we=Math.sqrt(oe*oe+se*se)/2,ke=ve.radialPoint(v-we-m.numbersMargin/100*h.max,ve.radians($));$===360&&($=0),C[$]||(C[$]=!0,h.fillStyle=q[M],h.fillText(m.majorTicks[M],ke.x,ke.y))}L&&h.restore()}function Xt(h,m){m.title&&(h.save(),h.font=ve.font(m,"Title",h.max/200),h.fillStyle=m.colorTitle,h.textAlign="center",h.fillText(m.title,0,-h.max/4.25,.8*h.max),h.restore())}function bn(h,m){m.units&&(h.save(),h.font=ve.font(m,"Units",h.max/200),h.fillStyle=m.colorUnits,h.textAlign="center",h.fillText(ve.formatContext(m,m.units),0,h.max/3.25,.8*h.max),h.restore())}function An(h,m){if(m.needle){var v=m.animationTarget!=="needle",C=m.ticksAngle<360?ve.normalizedValue(m).indented:m.value,M=v?m.startAngle:m.startAngle+(C-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle;m.barStartPosition==="right"&&(M=m.startAngle+m.ticksAngle-(C-m.minValue)/(m.maxValue-m.minValue)*m.ticksAngle);var D=ne(h,m),L=ki(D/100*m.needleCircleSize),q=ki(D/100*m.needleCircleSize*.75),G=ki(D/100*m.needleEnd),$=ki(m.needleStart?D/100*m.needleStart:0),oe=D/100*m.needleWidth,se=D/100*m.needleWidth/2,we=Mi.pixelRatio;h.save(),ve.drawNeedleShadow(h,m),h.rotate(ve.radians(M)),h.fillStyle=ve.linearGradient(h,m.colorNeedle,m.colorNeedleEnd,G-$),m.needleType==="arrow"?(h.beginPath(),h.moveTo(-se,-$),h.lineTo(-oe,0),h.lineTo(-1*we,G),h.lineTo(we,G),h.lineTo(oe,0),h.lineTo(se,-$),h.closePath(),h.fill(),h.beginPath(),h.lineTo(-.5*we,G),h.lineTo(-1*we,G),h.lineTo(-oe,0),h.lineTo(-se,-$),h.lineTo(se/2*we-2*we,-$),h.closePath(),h.fillStyle=m.colorNeedleShadowUp,h.fill()):(h.beginPath(),h.moveTo(-se,G),h.lineTo(-se,$),h.lineTo(se,$),h.lineTo(se,G),h.closePath(),h.fill()),h.restore(),m.needleCircleSize&&(h.save(),ve.drawNeedleShadow(h,m),m.needleCircleOuter&&(h.beginPath(),h.arc(0,0,L,0,2*po,!0),h.fillStyle=ve.linearGradient(h,m.colorNeedleCircleOuter,m.colorNeedleCircleOuterEnd,L),h.fill(),h.closePath()),m.needleCircleInner&&(h.beginPath(),h.arc(0,0,q,0,2*po,!0),h.fillStyle=ve.linearGradient(h,m.colorNeedleCircleInner,m.colorNeedleCircleInnerEnd,q),h.fill(),h.closePath()),h.restore())}}function dd(h,m,v){ve.drawValueBox(h,m,v,0,h.max-.33*h.max,h.max)}function Fg(h){var m=h.startAngle,v=h.startAngle+h.ticksAngle,C=m,M=m+(ve.normalizedValue(h).normal-h.minValue)/(h.maxValue-h.minValue)*h.ticksAngle;if(h.barStartPosition==="middle"){var D=.5*(h.minValue+h.maxValue);h.value<D?(C=180-(D-ve.normalizedValue(h).normal)/(h.maxValue-h.minValue)*h.ticksAngle,M=180):(C=180,M=180+(ve.normalizedValue(h).normal-D)/(h.maxValue-h.minValue)*h.ticksAngle)}else h.barStartPosition==="right"&&(C=v-M+m,M=v);return{startAngle:C,endAngle:M}}function cd(h,m){var v=h.max/100,C=ne(h,m)-5*v,M=parseFloat(m.barStrokeWidth+"")||0,D=(parseFloat(m.barWidth+"")||0)*v,L=C-2*M-D,q=(C-L)/2,G=L+q,$=M/G,oe=m.startAngle,se=m.startAngle+m.ticksAngle;if(h.save(),h.rotate(Bs),M&&(h.beginPath(),h.arc(0,0,G,ve.radians(oe)-$,ve.radians(se)+$,!1),h.strokeStyle=m.colorBarStroke,h.lineWidth=2*q,h.stroke(),h.closePath()),D&&(h.beginPath(),h.arc(0,0,G,ve.radians(oe),ve.radians(se),!1),h.strokeStyle=m.colorBar,h.lineWidth=D,h.stroke(),h.closePath(),m.barShadow&&(h.save(),h.beginPath(),h.arc(0,0,C,ve.radians(oe),ve.radians(se),!1),h.clip(),h.beginPath(),h.strokeStyle=m.colorBar,h.lineWidth=1,h.shadowBlur=m.barShadow,h.shadowColor=m.colorBarShadow,h.shadowOffsetX=0,h.shadowOffsetY=0,h.arc(0,0,C,ve.radians(m.startAngle),ve.radians(m.startAngle+m.ticksAngle),!1),h.stroke(),h.closePath(),h.restore()),m.barProgress)){var we=Fg(m),ke=we.startAngle,Pe=we.endAngle;h.beginPath(),h.arc(0,0,G,ve.radians(ke),ve.radians(Pe),!1),h.strokeStyle=m.colorBarProgress,h.lineWidth=D,h.stroke(),h.closePath()}h.restore()}function ud(h){return h.options.animatedValue?h.options.value:h.value}function Gg(h,m,v,C,M,D,L,q){h.beginPath(),h.fillStyle=q?ve.linearGradient(h,L,q,M>D?M:D,D>M,M>D?v:C):L,m>0?ve.roundRect(h,v,C,M,D,m):h.rect(v,C,M,D),h.fill(),h.closePath()}function Bg(h,m,v,C,M,D,L,q,G){h.beginPath(),h.lineWidth=m,h.strokeStyle=G?ve.linearGradient(h,q,G,L,!0,M):q,v>0?ve.roundRect(h,C,M,D,L,v):h.rect(C,M,D,L),h.stroke(),h.closePath()}function Ug(h,m,v,C,M,D){function L(ze,Ze,dt,Kt){return ze&&(!Kt&&m.borderShadowWidth&&(h.save(),h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),Bg(h,ze*q,G,v+ze*q/2-Ee,C+ze*q/2-Ee,$,ke,Ze,dt),Ee+=.5*q,!Kt&&m.borderShadowWidth&&(Kt=!0,h.restore())),Kt}var q=Mi.pixelRatio,G=m.borderRadius*q,$=M-m.borderShadowWidth-m.borderOuterWidth*q,oe=$-m.borderOuterWidth*q-m.borderMiddleWidth*q,se=oe-m.borderMiddleWidth*q-m.borderInnerWidth*q,we=se-m.borderInnerWidth*q,ke=D-m.borderShadowWidth-m.borderOuterWidth*q,Pe=ke-m.borderOuterWidth*q-m.borderMiddleWidth*q,$e=Pe-m.borderMiddleWidth*q-m.borderInnerWidth*q,De=$e-m.borderInnerWidth*q,He=v-(oe-$)/2,je=He-(se-oe)/2,Ye=je-(we-se)/2,Ge=C-(Pe-ke)/2,Ue=Ge-($e-Pe)/2,Le=Ue-(De-$e)/2,Ee=0,Ie=!1;return h.save(),Ie=L(m.borderOuterWidth,m.colorBorderOuter,m.colorBorderOuterEnd,Ie),Ie=L(m.borderMiddleWidth,m.colorBorderMiddle,m.colorBorderMiddleEnd,Ie),Ie=L(m.borderInnerWidth,m.colorBorderInner,m.colorBorderInnerEnd,Ie),!Ie&&m.borderShadowWidth&&(h.shadowBlur=m.borderShadowWidth,h.shadowColor=m.colorBorderShadow),Gg(h,G,Ye,Le,we+2*Ee,De+2*Ee,m.colorPlate,m.colorPlateEnd),h.restore(),[Ye,Le,we,De]}function zg(h,m,v,C,M,D){var L=Mi.pixelRatio,q=D>=M,G=q?.85*M:D,$=q?D:M;v=q?Re(v+(M-G)/2):v;var oe=!!m.title,se=!!m.units,we=!!m.valueBox,ke=void 0,Pe=void 0,$e=void 0;q?(Pe=Re(.05*$),ke=Re(.075*$),$e=Re(.11*$),oe&&($-=ke,C+=ke),se&&($-=Pe),we&&($-=$e)):(Pe=ke=Re(.15*G),oe&&(G-=ke,C+=ke),se&&(G-=Pe));var De=2*m.barStrokeWidth,He=m.barBeginCircle?Re(G*m.barBeginCircle/200-De/2):0,je=Re(G*m.barWidth/100-De),Ye=Re($*m.barLength/100-De),Ge=Re(($-Ye)/2),Ue=Re(v+(q?G/2:Ge+He)),Le=Re(C+(q?$-Ge-He+De/2:G/2)),Ee=!q||m.hasLeft&&m.hasRight?0:(m.hasRight?-1:1)*m.ticksWidth/100*G,Ie=q||m.hasLeft&&m.hasRight?0:(m.hasRight?-1:1)*m.ticksWidth/100*G;return h.barDimensions={isVertical:q,width:G,length:$,barWidth:je,barLength:Ye,strokeWidth:De,barMargin:Ge,radius:He,pixelRatio:L,barOffset:null,titleMargin:oe?ke:0,unitsMargin:se?Pe:0,get ticksLength(){return this.barLength-this.barOffset-this.strokeWidth},X:v+Ee,Y:C+Ie,x0:Ue+Ee,y0:Le+Ie,baseX:v,baseY:C,ticksPadding:m.ticksPadding/100},h.barDimensions}function md(h,m,v,C,M,D,L){var q=zg(h,m,C,M,D,L),G=q.isVertical,$=q.width,oe=q.barWidth,se=q.barLength,we=q.strokeWidth,ke=q.barMargin,Pe=q.radius,$e=q.x0,De=q.y0,He=q.X,je=q.Y,Ye=se;h.save(),h.beginPath();var Ge=null;if(m.barBeginCircle){var Ue=ve.radians(G?270:0),Le=Math.asin(oe/2/Pe),Ee=Math.cos(Le),Ie=Math.sin(Le),ze=$e+(G?Pe*Ie:Pe*Ee-we/2),Ze=G?De-Pe*Ee:De+Pe*Ie,dt=ki(G?Ze-De:ze-$e);Ge=Re(dt+Pe);var Kt=G?Re($e-Pe*Ie):ze,si=G?Ze:Re(De-Pe*Ie);v==="progress"&&(se=Ge+(se-Ge)*(ve.normalizedValue(m).normal-m.minValue)/(m.maxValue-m.minValue));var go=Re(ze+se-Ge+we/2),qn=Re(Ze-se+Ge-we/2);h.arc($e,De,Pe,Ue+Le,Ue-Le),G?(h.moveTo(ze,si),h.lineTo(ze,qn),h.lineTo(Kt,qn),h.lineTo(Kt,si)):(h.moveTo(ze,si),h.lineTo(go,si),h.lineTo(go,Ze),h.lineTo(ze,Ze))}else{var yd=Re(G?He+($-oe)/2:He+ke),xd=Re(G?je+se+ke:je+($-oe)/2);v==="progress"&&(se*=(m.value-m.minValue)/(m.maxValue-m.minValue)),G?h.rect(yd,xd,oe,-se):h.rect(yd,xd,se,oe)}v!=="progress"&&m.barStrokeWidth&&(h.lineWidth=we,h.strokeStyle=m.colorBarStroke,h.stroke()),v!=="progress"&&m.colorBar?(h.fillStyle=m.colorBarEnd?ve.linearGradient(h,m.colorBar,m.colorBarEnd,se,G,G?je:He):m.colorBar,h.fill()):v==="progress"&&m.colorBarProgress&&(h.fillStyle=m.colorBarProgressEnd?ve.linearGradient(h,m.colorBarProgress,m.colorBarProgressEnd,Ye,G,G?je:He):m.colorBarProgress,h.fill()),h.closePath(),h.restore(),m.barBeginCircle&&(h.barDimensions.radius+=we),h.barDimensions.barOffset=Ge,h.barDimensions.barWidth+=we,h.barDimensions.barLength+=we}function qg(h,m,v,C,M,D){md(h,m,"",v,C,M,D)}function hd(h,m){return m.needleSide!==h||m.tickSide!==h||m.numberSide!==h}function Hg(h,m,v,C,M,D){m.barProgress&&md(h,m,"progress",v,C,M,D)}function jg(h,m){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.barWidth,q=v.barOffset,G=v.barMargin,$=v.X,oe=v.Y,se=v.ticksLength,we=v.ticksPadding,ke=M*(parseFloat(m.highlightsWidth)||0)/100;if(m.highlights&&ke){var Pe=m.tickSide!=="right",$e=m.tickSide!=="left",De=0,He=m.highlights.length,je=(M-L)/2,Ye=m.maxValue-m.minValue,Ge=Re(C?$+je:$+G+q),Ue=ke,Le=C?oe+D-G-q:oe+je,Ee=Re((m.ticksWidth/100+we)*M)+(ke-m.ticksWidth/100*M),Ie=Re(L+we*M);for(h.save();De<He;De++){var ze=m.highlights[De],Ze=se*ki(m.minValue-ze.from)/Ye,dt=se*ki((ze.to-ze.from)/Ye);h.beginPath(),h.fillStyle=ze.color,C?(Pe&&h.rect(Ge-Ee,Le-Ze,Ue,-dt),$e&&h.rect(Ge+Ie,Le-Ze,Ue,-dt)):(Pe&&h.rect(Ge+Ze,Le-Ee,dt,Ue),$e&&h.rect(Ge+Ze,Le+Ie,dt,Ue)),h.fill(),h.closePath()}h.restore()}}function $o(h,m,v,C,M){h.beginPath(),h.moveTo(m,v),h.lineTo(C,M),h.stroke(),h.closePath()}function pd(h,m,v,C,M,D,L,q,G){var $=h.barDimensions,oe=$.isVertical,se=$.length,we=$.barWidth,ke=$.barOffset,Pe=$.barMargin,$e=$.pixelRatio,De=$.width,He=$.X,je=$.Y,Ye=$.ticksLength,Ge=$.ticksPadding,Ue=(De-we)/2,Le=void 0,Ee=void 0,Ie=0,ze=v.length,Ze=void 0,dt=G*De,Kt=Ue-Ge*De,si=Ue+we+dt+Ge*De,go=m instanceof Array?m:new Array(v.length).fill(m);h.save(),h.lineWidth=q*$e;for(var qn=Ye/(M-C);Ie<ze;Ie++)Ze=v[Ie],h.strokeStyle=go[Ie],oe?(Ee=je+se-Pe-ke+(C-Ze)*qn,D&&(Le=He+Kt,$o(h,Le,Ee,Re(Le-dt),Ee)),L&&(Le=He+si,$o(h,Le,Ee,Re(Le-dt),Ee))):(Le=He+Pe+ke-(C-Ze)*qn,D&&(Ee=je+Kt,$o(h,Le,Ee,Le,Re(Ee-dt))),L&&(Ee=je+si,$o(h,Le,Re(Ee),Le,Ee-dt)));h.restore()}function $g(h,m){var v=ve.prepareTicks(m),C=fd(v,2),M=C[0],D=C[1],L=2,q=(m.maxValue-m.minValue)/(m.majorTicks.length-1),G=m.colorMajorTicks instanceof Array?m.colorMajorTicks:new Array(m.majorTicks.length).fill(m.colorStrokeTicks||m.colorMajorTicks);if(pd(h,G,m.exactTicks?m.majorTicks:m.majorTicks.map(function(dt,Kt){return m.minValue+q*Kt}),m.minValue,m.maxValue,M,D,L,m.ticksWidth/100),m.strokeTicks){var $=h.barDimensions,oe=$.isVertical,se=$.length,we=$.width,ke=$.barWidth,Pe=$.barMargin,$e=$.barOffset,De=$.X,He=$.Y,je=$.ticksLength,Ye=$.pixelRatio,Ge=$.ticksPadding,Ue=(we-ke)/2+ke+Ge*we,Le=(we-ke)/2-Ge*we,Ee=void 0,Ie=void 0,ze=void 0,Ze=void 0;h.strokeStyle=m.colorStrokeTicks||G[0],L*=Ye,oe?(Ie=He+se-Pe-$e+L/2,Ze=Ie-je-L,M&&(ze=Ee=Re(De+Le),Yo(h,Ee,Ie,ze,Ze)),D&&(ze=Ee=Re(De+Ue),Yo(h,Ee,Ie,ze,Ze))):(Ee=De+Pe+$e-L/2,ze=Ee+je+L,M&&(Ze=Ie=Re(He+Le),Yo(h,Ee,Ie,ze,Ze)),D&&(Ze=Ie=Re(He+Ue),Yo(h,Ee,Ie,ze,Ze)))}}function Yo(h,m,v,C,M){h.beginPath(),h.moveTo(m,v),h.lineTo(C,M),h.stroke(),h.closePath()}function Yg(h,m){var v=ve.prepareTicks(m),C=fd(v,2),M=C[0],D=C[1],L=[],q=m.minValue,G=Math.abs(m.minorTicks)||0,$=G?(m.maxValue-m.minValue)/(G*(m.majorTicks.length-1)):0;if(G)if(m.exactTicks)for(var oe=Li.mod(m.majorTicks[0],G)||0;q<m.maxValue;q+=G)oe+q<m.maxValue&&L.push(oe+q);else for(;q<m.maxValue;q+=$)L.push(q);pd(h,m.colorMinorTicks||m.colorStrokeTicks,L,m.minValue,m.maxValue,M,D,1,m.ticksWidthMinor/100)}function Zg(h,m){var v=h.barDimensions,C=v.isVertical,M=v.length,D=v.width,L=v.barWidth,q=v.barMargin,G=v.barOffset,$=v.X,oe=v.Y,se=v.ticksLength,we=v.ticksPadding,ke=m.maxValue-m.minValue,Pe=ke/(m.majorTicks.length-1),$e=m.exactTicks?m.majorTicks:m.majorTicks.map(function(go,qn){return m.minValue+Pe*qn}),De=$e.length,He=m.numberSide!=="right",je=m.numberSide!=="left",Ye=m.fontNumbersSize*D/200,Ge=0,Ue=(m.ticksWidth/100+2*we)*D,Le=(D-L)/2-Ue,Ee=(D-L)/2+L+Ue,Ie=void 0,ze=void 0,Ze=void 0,dt=void 0,Kt=m.colorNumbers instanceof Array?m.colorNumbers:new Array(De).fill(m.colorNumbers),si=m.numbersMargin/100*D;for(h.font=ve.font(m,"Numbers",D/200),h.lineWidth=0,h.textAlign="center";Ge<De;Ge++)h.fillStyle=Kt[Ge],dt=m.majorTicks[Ge],Ze=m.exactTicks?se*(($e[Ge]-m.minValue)/ke):Ge*se/(De-1),C?(ze=oe+M-q-G-Ze+Ye/3,He&&(h.textAlign="right",h.fillText(dt,$+Le-si,ze)),je&&(h.textAlign="left",h.fillText(dt,$+Ee+si,ze))):(h.measureText(dt).width,Ie=$+q+G+Ze,He&&h.fillText(dt,Ie,oe+Le-si),je&&h.fillText(dt,Ie,oe+Ee+Ye+si))}function Qg(h,m){if(m.title){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.baseX,q=v.baseY,G=v.titleMargin,$=m.fontTitleSize*M/200,oe=Re(L+(C?M:D)/2),se=Re(q+G/2-(C?$:$/2)-.025*(C?D:M));h.save(),h.textAlign="center",h.fillStyle=m.colorTitle,h.font=ve.font(m,"Title",M/200),h.lineWidth=0,h.fillText(m.title,oe,se,C?M:D),h.restore()}}function Xg(h,m){if(m.units){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.baseX,q=v.baseY,G=v.unitsMargin,$=m.fontUnitsSize*M/200,oe=Re(L+(C?M:D)/2),se=Re(q+(C?D:M)+G/2-$/2);h.save(),h.textAlign="center",h.fillStyle=m.colorUnits,h.font=ve.font(m,"Units",M/200),h.lineWidth=0,h.fillText(ve.formatContext(m,m.units),oe,se,C?M:D),h.restore()}}function Kg(h,m){if(m.needle){var v=h.barDimensions,C=v.isVertical,M=v.width,D=v.length,L=v.barWidth,q=v.barOffset,G=v.barMargin,$=v.ticksLength,oe=v.X,se=v.Y,we=v.ticksPadding,ke=m.needleSide!=="right",Pe=m.needleSide!=="left",$e=$*(ve.normalizedValue(m).indented-m.minValue)/(m.maxValue-m.minValue),De=(m.ticksWidth/100+we)*M,He=L/2+De,je=He*(m.needleEnd/100),Ye=void 0,Ge=void 0,Ue=void 0,Le=void 0,Ee=m.needleType.toLowerCase()==="arrow"?ef:Jg,Ie=(M-L)/2,ze=He*(m.needleStart/100),Ze=Ie-De-ze,dt=Ie+L+De+ze;h.save(),ve.drawNeedleShadow(h,m),C?(Ue=Re(se+D-G-q-$e),ke&&(Ye=Re(oe+Ze),Ge=Ye+je,Ee(h,m,Ye,Ue,Ge,Ue,je)),Pe&&(Ye=Re(oe+dt),Ge=Ye-je,Ee(h,m,Ye,Ue,Ge,Ue,je,!0))):(Ye=Re(oe+G+q+$e),ke&&(Ue=Re(se+Ze),Le=Ue+je,Ee(h,m,Ye,Ue,Ye,Le,je)),Pe&&(Ue=Re(se+dt),Le=Ue-je,Ee(h,m,Ye,Ue,Ye,Le,je,!0))),h.restore()}}function gd(h,m,v,C){return m.colorNeedleEnd?ve.linearGradient(h,C?m.colorNeedleEnd:m.colorNeedle,C?m.colorNeedle:m.colorNeedleEnd,v,!h.barDimensions.isVertical):m.colorNeedle}function Jg(h,m,v,C,M,D,L,q){h.lineWidth=m.needleWidth,h.strokeStyle=gd(h,m,L,q),h.beginPath(),h.moveTo(v,C),h.lineTo(M,D),h.stroke(),h.closePath()}function ef(h,m,v,C,M,D,L,q){var G=Re(.4*L),$=L-G,oe=v===M,se=m.needleWidth/2;h.fillStyle=gd(h,m,L,q),h.beginPath(),oe?(C>D&&($*=-1),h.moveTo(v-se,C),h.lineTo(v+se,C),h.lineTo(v+se,C+$),h.lineTo(v,D),h.lineTo(v-se,C+$),h.lineTo(v-se,C)):(v>M&&($*=-1),h.moveTo(v,C-se),h.lineTo(v,C+se),h.lineTo(v+$,C+se),h.lineTo(M,C),h.lineTo(v+$,C-se),h.lineTo(v,C-se)),h.fill(),h.closePath()}function tf(h,m,v,C,M,D,L){var q=(parseFloat(m.fontValueSize)||0)*D/200,G=(.11*L-q)/2;h.barDimensions.isVertical&&ve.drawValueBox(h,m,v,C+D/2,M+L-q-G,D)}var fd=(function(){function h(m,v){var C=[],M=!0,D=!1,L=void 0;try{for(var q,G=m[Symbol.iterator]();!(M=(q=G.next()).done)&&(C.push(q.value),!v||C.length!==v);M=!0);}catch($){D=!0,L=$}finally{try{!M&&G.return&&G.return()}finally{if(D)throw L}}return C}return function(m,v){if(Array.isArray(m))return m;if(Symbol.iterator in Object(m))return h(m,v);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),Ls=function h(m,v,C){m===null&&(m=Function.prototype);var M=Object.getOwnPropertyDescriptor(m,v);if(M===void 0){var D=Object.getPrototypeOf(m);return D===null?void 0:h(D,v,C)}if("value"in M)return M.value;var L=M.get;if(L!==void 0)return L.call(C)},nf=function h(m,v,C,M){var D=Object.getOwnPropertyDescriptor(m,v);if(D===void 0){var L=Object.getPrototypeOf(m);L!==null&&h(L,v,C,M)}else if("value"in D&&D.writable)D.value=C;else{var q=D.set;q!==void 0&&q.call(M,C)}return C},zn=(function(){function h(m,v){for(var C=0;C<v.length;C++){var M=v[C];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(m,M.key,M)}}return function(m,v,C){return v&&h(m.prototype,v),C&&h(m,C),m}})(),Zo=null,af=(function(){function h(){i(this,h),this._events={},this.addListener=this.on,this.removeListener=this.off}return zn(h,[{key:"emit",value:function(m){if(this._events[m]){for(var v=0,C=this._events[m].length,M=arguments.length,D=Array(M>1?M-1:0),L=1;L<M;L++)D[L-1]=arguments[L];for(;v<C;v++)this._events[m][v]&&this._events[m][v].apply(this,D)}}},{key:"once",value:function(m){for(var v=arguments.length,C=Array(v>1?v-1:0),M=1;M<v;M++)C[M-1]=arguments[M];for(var D=0,L=C.length,q=this;D<L;D++)(function(){var G=C[D],$=function oe(){q.off(m,oe),G.apply(q,arguments)};C[D]=$})();this.on.apply(this,[m].concat(C))}},{key:"on",value:function(m){this._events[m]||(this._events[m]=[]);for(var v=0,C=arguments.length<=1?0:arguments.length-1;v<C;v++)this._events[m].push(arguments.length<=v+1?void 0:arguments[v+1])}},{key:"off",value:function(m){if(this._events[m])for(var v=0,C=arguments.length<=1?0:arguments.length-1;v<C;v++)for(var M=arguments.length<=v+1?void 0:arguments[v+1],D=void 0;~(D=this._events[m].indexOf(M));)this._events[m].splice(D,1)}},{key:"removeAllListeners",value:function(m){delete this._events[m]}},{key:"listeners",get:function(){return this._events}}]),h})(),vd=o("requestAnimationFrame")||function(h){return setTimeout(function(){return h(new Date().getTime())},1e3/60)},mo={linear:function(h){return h},quad:function(h){return Math.pow(h,2)},dequad:function(h){return 1-mo.quad(1-h)},quint:function(h){return Math.pow(h,5)},dequint:function(h){return 1-Math.pow(1-h,5)},cycle:function(h){return 1-Math.sin(Math.acos(h))},decycle:function(h){return Math.sin(Math.acos(1-h))},bounce:function(h){return 1-mo.debounce(1-h)},debounce:function(h){for(var m=0,v=1;;m+=v,v/=2)if(h>=(7-4*m)/11)return-Math.pow((11-6*m-11*h)/4,2)+Math.pow(v,2)},elastic:function(h){return 1-mo.delastic(1-h)},delastic:function(h){return Math.pow(2,10*(h-1))*Math.cos(20*Math.PI*1.5/3*h)}},Ws=(function(){function h(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"linear",v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:250,C=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},M=arguments.length>3&&arguments[3]!==void 0?arguments[3]:function(){};if(i(this,h),this.duration=v,this.rule=m,this.draw=C,this.end=M,typeof this.draw!="function")throw new TypeError("Invalid animation draw callback:",C);if(typeof this.end!="function")throw new TypeError("Invalid animation end callback:",M)}return zn(h,[{key:"animate",value:function(m,v){var C=this;this.frame&&this.cancel();var M=window.performance&&window.performance.now?window.performance.now():o("animationStartTime")||Date.now();m=m||this.draw,v=v||this.end,this.draw=m,this.end=v,this.frame=vd(function(D){return r(D,m,M,mo[C.rule]||C.rule,C.duration,v,C)})}},{key:"cancel",value:function(){this.frame&&((o("cancelAnimationFrame")||function(m){})(this.frame),this.frame=null)}},{key:"destroy",value:function(){this.cancel(),this.draw=null,this.end=null}}]),h})();Ws.rules=mo;var fa=(function(){function h(m,v,C){i(this,h),this.options=m,this.element=v.toLowerCase(),this.type=h.toDashed(C),this.Type=n[C],this.mutationsObserved=!1,this.isObservable=!!window.MutationObserver,window.GAUGES_NO_AUTO_INIT||h.domReady(this.traverse.bind(this))}return zn(h,[{key:"isValidNode",value:function(m){return!(!m.tagName||m.tagName.toLowerCase()!==this.element||m.getAttribute("data-type")!==this.type)}},{key:"traverse",value:function(){for(var m=document.getElementsByTagName(this.element),v=0,C=m.length;v<C;v++)this.process(m[v]);this.isObservable&&!this.mutationsObserved&&(new MutationObserver(this.observe.bind(this)).observe(document.body,{childList:!0,subtree:!0,attributes:!0,characterData:!0,attributeOldValue:!0,characterDataOldValue:!0}),this.mutationsObserved=!0)}},{key:"observe",value:function(m){for(var v=0,C=m.length;v<C;v++){var M=m[v];if(M.type==="attributes"&&M.attributeName==="data-type"&&this.isValidNode(M.target)&&M.oldValue!==this.type)setTimeout(this.process.bind(this,M.target));else if(M.addedNodes&&M.addedNodes.length)for(var D=0,L=M.addedNodes.length;D<L;D++)setTimeout(this.process.bind(this,M.addedNodes[D]))}}},{key:"process",value:function(m){var v=this;if(!this.isValidNode(m))return null;var C=void 0,M=JSON.parse(JSON.stringify(this.options)),D=null;for(C in M)if(M.hasOwnProperty(C)){var L=h.toAttributeName(C),q=h.parse(m.getAttribute(L));q!=null&&(M[C]=q)}return M.renderTo=m,D=new this.Type(M),D.draw&&D.draw(),this.isObservable&&(D.observer=new MutationObserver(function(G){G.forEach(function($){if($.type==="attributes"){var oe=$.attributeName.toLowerCase(),se=m.getAttribute(oe).toLowerCase();if(oe==="data-type"&&se&&se!==v.type)D.observer.disconnect(),delete D.observer,D.destroy&&D.destroy();else if(oe.substr(0,5)==="data-"){var we=oe.substr(5).split("-").map(function(Pe,$e){return $e?Pe.charAt(0).toUpperCase()+Pe.substr(1):Pe}).join(""),ke={};ke[we]=h.parse(m.getAttribute($.attributeName)),we==="value"?D&&(D.value=ke[we]):D.update&&D.update(ke)}}})}),D.observer.observe(m,{attributes:!0})),D}}],[{key:"parse",value:function(m){if(m==="true")return!0;if(m==="false")return!1;if(m!=="undefined"){if(m==="null")return null;if(/^[-+#.\w\d\s]+(?:,[-+#.\w\d\s]*)+$/.test(m))return m.split(",");try{return JSON.parse(m)}catch(v){}return m}}},{key:"toDashed",value:function(m){for(var v=m.split(/(?=[A-Z])/),C=1,M=v.length,D=v[0].toLowerCase();C<M;C++)D+="-"+v[C].toLowerCase();return D}},{key:"toCamelCase",value:function(m){for(var v=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],C=m.split(/-/),M=0,D=C.length,L="";M<D;M++)L+=M||v?C[M][0].toUpperCase()+C[M].substr(1).toLowerCase():C[M].toLowerCase();return L}},{key:"toAttributeName",value:function(m){return"data-"+h.toDashed(m)}},{key:"domReady",value:function(m){if(/comp|inter|loaded/.test((window.document||{}).readyState+""))return m();window.addEventListener?window.addEventListener("DOMContentLoaded",m,!1):window.attachEvent&&window.attachEvent("onload",m)}}]),h})(),Mi=(function(){function h(m,v,C){i(this,h),h.collection.push(this),this.width=v||0,this.height=C||0,this.element=m,this.init()}return zn(h,[{key:"init",value:function(){var m=h.pixelRatio;this.element.width=this.width*m,this.element.height=this.height*m,this.element.style.width=this.width+"px",this.element.style.height=this.height+"px",this.elementClone=this.element.cloneNode(!0),this.context=this.element.getContext("2d"),this.contextClone=this.elementClone.getContext("2d"),this.drawWidth=this.element.width,this.drawHeight=this.element.height,this.drawX=this.drawWidth/2,this.drawY=this.drawHeight/2,this.minSide=this.drawX<this.drawY?this.drawX:this.drawY,this.contextClone.translate(this.drawX,this.drawY),this.elementClone.initialized=!1,this.context.translate(this.drawX,this.drawY),this.context.max=this.contextClone.max=this.minSide,this.context.maxRadius=this.contextClone.maxRadius=null}},{key:"destroy",value:function(){var m=h.collection.indexOf(this);~m&&h.collection.splice(m,1),this.context.clearRect(-this.drawX,-this.drawY,this.drawWidth,this.drawHeight),this.context.max=null,delete this.context.max,this.context.maxRadius=null,delete this.context.maxRadius,this.context=null,this.contextClone=null,this.elementClone=null,this.element=null,this.onRedraw=null}},{key:"commit",value:function(){var m=h.pixelRatio;return m!==1&&this.contextClone.scale(m,m),this}},{key:"redraw",value:function(){return this.init(),this.onRedraw&&this.onRedraw(),this}}],[{key:"redraw",value:function(){for(var m=0,v=h.collection.length;m<v;m++)h.collection[m].redraw()}},{key:"pixelRatio",get:function(){return window.devicePixelRatio||1}}]),h})();Mi.collection=[],window.matchMedia&&window.matchMedia("screen and (min-resolution: 2dppx)").addListener(Mi.redraw);var Fs={renderTo:null,width:0,height:0,minValue:0,maxValue:100,value:0,units:!1,exactTicks:!1,majorTicks:[0,20,40,60,80,100],minorTicks:10,strokeTicks:!0,animatedValue:!1,animateOnInit:!1,title:!1,borders:!0,numbersMargin:1,listeners:null,valueInt:3,valueDec:2,majorTicksInt:1,majorTicksDec:0,animation:!0,animationDuration:500,animationRule:"cycle",colorPlate:"#fff",colorPlateEnd:"",colorMajorTicks:"#444",colorMinorTicks:"#666",colorStrokeTicks:"",colorTitle:"#888",colorUnits:"#888",colorNumbers:"#444",colorNeedle:"rgba(240,128,128,1)",colorNeedleEnd:"rgba(255,160,122,.9)",colorValueText:"#444",colorValueTextShadow:"rgba(0,0,0,0.3)",colorBorderShadow:"rgba(0,0,0,0.5)",colorBorderOuter:"#ddd",colorBorderOuterEnd:"#aaa",colorBorderMiddle:"#eee",colorBorderMiddleEnd:"#f0f0f0",colorBorderInner:"#fafafa",colorBorderInnerEnd:"#ccc",colorValueBoxRect:"#888",colorValueBoxRectEnd:"#666",colorValueBoxBackground:"#babab2",colorValueBoxShadow:"rgba(0,0,0,1)",colorNeedleShadowUp:"rgba(2,255,255,0.2)",colorNeedleShadowDown:"rgba(188,143,143,0.45)",colorBarStroke:"#222",colorBar:"#ccc",colorBarProgress:"#888",colorBarShadow:"#000",fontNumbers:"Arial",fontTitle:"Arial",fontUnits:"Arial",fontValue:"Arial",fontNumbersSize:20,fontTitleSize:24,fontUnitsSize:22,fontValueSize:26,fontNumbersStyle:"normal",fontTitleStyle:"normal",fontUnitsStyle:"normal",fontValueStyle:"normal",fontNumbersWeight:"normal",fontTitleWeight:"normal",fontUnitsWeight:"normal",fontValueWeight:"normal",needle:!0,needleShadow:!0,needleType:"arrow",needleStart:5,needleEnd:85,needleWidth:4,borderOuterWidth:3,borderMiddleWidth:3,borderInnerWidth:3,borderShadowWidth:3,valueBox:!0,valueBoxStroke:5,valueBoxWidth:0,valueText:"",valueTextShadow:!0,valueBoxBorderRadius:2.5,highlights:[{from:20,to:60,color:"#eee"},{from:60,to:80,color:"#ccc"},{from:80,to:100,color:"#999"}],highlightsWidth:15,highlightsLineCap:"butt",barWidth:20,barStrokeWidth:0,barProgress:!0,barShadow:0};s.prototype=Object.create(Array.prototype),s.prototype.constructor=s,s.prototype.get=function(h){if(typeof h=="string")for(var m=0,v=this.length;m<v;m++){var C=this[m].options.renderTo.tagName?this[m].options.renderTo:document.getElementById(this[m].options.renderTo||"");if(C.getAttribute("id")===h)return this[m]}else if(typeof h=="number")return this[h];return null};var Gs="2.2.1",Re=Math.round,ki=Math.abs,ho=new s;ho.version=Gs;var Li=(function(h){function m(v){i(this,m);var C=e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this)),M=C.constructor.name;if(M==="BaseGauge")throw new TypeError("Attempt to instantiate abstract class!");if(ho.push(C),v.listeners&&Object.keys(v.listeners).forEach(function(L){(v.listeners[L]instanceof Array?v.listeners[L]:[v.listeners[L]]).forEach(function(q){C.on(L,q)})}),C.version=Gs,C.type=n[M]||m,C.initialized=!1,v.minValue=parseFloat(v.minValue),v.maxValue=parseFloat(v.maxValue),v.value=parseFloat(v.value)||0,v.borders||(v.borderInnerWidth=v.borderMiddleWidth=v.borderOuterWidth=0),!v.renderTo)throw TypeError("Canvas element was not specified when creating the Gauge object!");var D=v.renderTo.tagName?v.renderTo:document.getElementById(v.renderTo);if(!(D instanceof HTMLCanvasElement))throw TypeError("Given gauge canvas element is invalid!");return v.width=parseFloat(v.width)||0,v.height=parseFloat(v.height)||0,v.width&&v.height||(v.width||(v.width=D.parentNode?D.parentNode.offsetWidth:D.offsetWidth),v.height||(v.height=D.parentNode?D.parentNode.offsetHeight:D.offsetHeight)),C.options=v||{},C.options.animateOnInit&&(C._value=C.options.value,C.options.value=C.options.minValue),C.canvas=new Mi(D,v.width,v.height),C.canvas.onRedraw=C.draw.bind(C),C.animation=new Ws(v.animationRule,v.animationDuration),C}return t(m,h),zn(m,[{key:"update",value:function(v){return Object.assign(this.options,this.type.configure(v||{})),this.canvas.width=this.options.width,this.canvas.height=this.options.height,this.animation.rule=this.options.animationRule,this.animation.duration=this.options.animationDuration,this.canvas.redraw(),this}},{key:"destroy",value:function(){var v=ho.indexOf(this);~v&&ho.splice(v,1),this.canvas.destroy(),this.canvas=null,this.animation.destroy(),this.animation=null,this.emit("destroy")}},{key:"draw",value:function(){return this.options.animateOnInit&&!this.initialized&&(this.value=this._value,this.initialized=!0,this.emit("init")),this.emit("render"),this}},{key:"value",set:function(v){var C=this;v=m.ensureValue(v,this.options.minValue);var M=this.options.value;if(v!==M)if(this.options.animation){if(this.animation.frame&&(this.options.value=this._value,this._value===v))return this.animation.cancel(),void delete this._value;this._value===void 0&&(this._value=v),this.emit("animationStart"),this.animation.animate(function(D){var L=M+(v-M)*D;C.options.animatedValue&&C.emit("value",L,C.value),C.options.value=L,C.draw(),C.emit("animate",D,C.options.value)},function(){C._value!==void 0&&(C.emit("value",C._value,C.value),C.options.value=C._value,delete C._value),C.draw(),C.emit("animationEnd"),C.animation.frame=null})}else this.emit("value",v,this.value),this.options.value=v,this.draw()},get:function(){return this._value===void 0?this.options.value:this._value}}],[{key:"configure",value:function(v){return v}},{key:"initialize",value:function(v,C){return new fa(C,"canvas",v)}},{key:"fromElement",value:function(v){var C=fa.toCamelCase(v.getAttribute("data-type")),M=v.attributes,D=0,L=M.length,q={};if(C){for(/Gauge$/.test(C)||(C+="Gauge");D<L;D++)q[fa.toCamelCase(M[D].name.replace(/^data-/,""),!1)]=fa.parse(M[D].value);new fa(q,v.tagName,C).process(v)}}},{key:"ensureValue",value:function(v){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return v=parseFloat(v),!isNaN(v)&&isFinite(v)||(v=parseFloat(C)||0),v}},{key:"mod",value:function(v,C){return(v%C+C)%C}},{key:"version",get:function(){return Gs}}]),m})(af);n!==void 0&&(n.BaseGauge=Li,n.gauges=(window.document||{}).gauges=ho);var of=/{([_a-zA-Z]+[_a-zA-Z0-9]*)}/g,ve={roundRect:b,padValue:x,formatMajorTickNumber:_,radians:k,radialPoint:S,linearGradient:F,drawNeedleShadow:j,drawValueBox:ee,verifyError:c,prepareTicks:f,font:Y,normalizedValue:Te,formatContext:p},po=Math.PI,Bs=po/2,bd=Object.assign({},Fs,{ticksAngle:270,startAngle:45,colorNeedleCircleOuter:"#f0f0f0",colorNeedleCircleOuterEnd:"#ccc",colorNeedleCircleInner:"#e8e8e8",colorNeedleCircleInnerEnd:"#f5f5f5",needleCircleSize:10,needleCircleInner:!0,needleCircleOuter:!0,needleStart:20,animationTarget:"needle",useMinPath:!1,barWidth:0,barStartPosition:"left"}),rf=(function(h){function m(v){return i(this,m),v=Object.assign({},bd,v||{}),e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,m.configure(v)))}return t(m,h),zn(m,[{key:"draw",value:function(){try{var v=this.canvas,C=[-v.drawX,-v.drawY,v.drawWidth,v.drawHeight],M=C[0],D=C[1],L=C[2],q=C[3],G=this.options;if(G.animationTarget==="needle"){if(!v.elementClone.initialized){var $=v.contextClone;$.clearRect(M,D,L,q),this.emit("beforePlate"),le($,G),this.emit("beforeHighlights"),me($,G),this.emit("beforeMinorTicks"),de($,G),this.emit("beforeMajorTicks"),Ve($,G),this.emit("beforeNumbers"),ft($,G),this.emit("beforeTitle"),Xt($,G),this.emit("beforeUnits"),bn($,G),v.elementClone.initialized=!0}this.canvas.commit(),v.context.clearRect(M,D,L,q),v.context.drawImage(v.elementClone,M,D,L,q),this.emit("beforeProgressBar"),cd(v.context,G),this.emit("beforeValueBox"),dd(v.context,G,ud(this)),this.emit("beforeNeedle"),An(v.context,G)}else{var oe=-ve.radians((G.value-G.minValue)/(G.maxValue-G.minValue)*G.ticksAngle);if(v.context.clearRect(M,D,L,q),this.emit("beforePlate"),le(v.context,G),v.context.rotate(oe),this.emit("beforeHighlights"),me(v.context,G),this.emit("beforeMinorTicks"),de(v.context,G),this.emit("beforeMajorTicks"),Ve(v.context,G),this.emit("beforeNumbers"),ft(v.context,G),this.emit("beforeProgressBar"),cd(v.context,G),v.context.rotate(-oe),!v.elementClone.initialized){var se=v.contextClone;se.clearRect(M,D,L,q),this.emit("beforeTitle"),Xt(se,G),this.emit("beforeUnits"),bn(se,G),this.emit("beforeNeedle"),An(se,G),v.elementClone.initialized=!0}v.context.drawImage(v.elementClone,M,D,L,q)}this.emit("beforeValueBox"),dd(v.context,G,ud(this)),Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"draw",this).call(this)}catch(we){ve.verifyError(we)}return this}},{key:"value",set:function(v){v=Li.ensureValue(v,this.options.minValue),this.options.animation&&this.options.ticksAngle===360&&this.options.useMinPath&&(this._value=v,v=this.options.value+((v-this.options.value)%360+540)%360-180),nf(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"value",v,this)},get:function(){return Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"value",this)}}],[{key:"configure",value:function(v){return v.barWidth>50&&(v.barWidth=50),isNaN(v.startAngle)&&(v.startAngle=45),isNaN(v.ticksAngle)&&(v.ticksAngle=270),v.ticksAngle>360&&(v.ticksAngle=360),v.ticksAngle<0&&(v.ticksAngle=0),v.startAngle<0&&(v.startAngle=0),v.startAngle>360&&(v.startAngle=360),v}}]),m})(Li);n!==void 0&&(n.RadialGauge=rf),Li.initialize("RadialGauge",bd);var Ad=Object.assign({},Fs,{borderRadius:0,barBeginCircle:30,colorBarEnd:"",colorBarProgressEnd:"",needleWidth:6,tickSide:"both",needleSide:"both",numberSide:"both",ticksWidth:10,ticksWidthMinor:5,ticksPadding:5,barLength:85,fontTitleSize:26,highlightsWidth:10}),sf=(function(h){function m(v){return i(this,m),v=Object.assign({},Ad,v||{}),e(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,m.configure(v)))}return t(m,h),zn(m,[{key:"draw",value:function(){try{var v=this.canvas,C=[-v.drawX,-v.drawY,v.drawWidth,v.drawHeight],M=C[0],D=C[1],L=C[2],q=C[3],G=this.options;if(!v.elementClone.initialized){var $=v.contextClone;$.clearRect(M,D,L,q),this.emit("beforePlate"),this.drawBox=Ug($,G,M,D,L,q),this.emit("beforeBar"),qg.apply(void 0,[$,G].concat(a(this.drawBox))),v.contextClone.barDimensions=$.barDimensions,this.emit("beforeHighlights"),jg($,G),this.emit("beforeMinorTicks"),Yg($,G),this.emit("beforeMajorTicks"),$g($,G),this.emit("beforeNumbers"),Zg($,G),this.emit("beforeTitle"),Qg($,G),this.emit("beforeUnits"),Xg($,G),v.elementClone.initialized=!0}this.canvas.commit(),v.context.clearRect(M,D,L,q),v.context.drawImage(v.elementClone,M,D,L,q),this.emit("beforeProgressBar"),Hg.apply(void 0,[v.context,G].concat(a(this.drawBox))),this.emit("beforeNeedle"),Kg(v.context,G),this.emit("beforeValueBox"),tf.apply(void 0,[v.context,G,G.animatedValue?this.options.value:this.value].concat(a(this.drawBox))),Ls(m.prototype.__proto__||Object.getPrototypeOf(m.prototype),"draw",this).call(this)}catch(oe){ve.verifyError(oe)}return this}}],[{key:"configure",value:function(v){return v.barStrokeWidth>=v.barWidth&&(v.barStrokeWidth=Re(v.barWidth/2)),v.hasLeft=hd("right",v),v.hasRight=hd("left",v),v.value>v.maxValue&&(v.value=v.maxValue),v.value<v.minValue&&(v.value=v.minValue),Li.configure(v)}}]),m})(Li);n!==void 0&&(n.LinearGauge=sf),Li.initialize("LinearGauge",Ad),typeof Ss<"u"&&Object.assign(n,{Collection:s,GenericOptions:Fs,Animation:Ws,BaseGauge:Li,drawings:ve,SmartCanvas:Mi,DomObserver:fa,vendorize:o})})(typeof Ss<"u"?Ss.exports:window)});var nu=[{id:null,name:"Dashboard 1",icon:"dashboard-dashboard",configuration:[{w:24,h:24,id:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc",selector:"widget-host2",input:{widgetProperties:{type:"widget-tutorial",uuid:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc"}},x:0,y:0}],collapseSplitShell:!1}];var mt=(()=>{class n{_settings=A(At);_router=A(Jd);_destroyRef=A(ct);dashboards=w([],{equal:gi});activeDashboard=w(null);_widgetAction=new Wi(null);widgetAction$=this._widgetAction.asObservable();isDashboardStatic=w(!0);widgetClipboard=w(null);layoutEditSaved=w(0);layoutEditCanceled=w(0);constructor(){let e=this._settings.getDashboardConfig();if(!e||e.length===0){console.warn("[Dashboard Service] No dashboards found in settings, creating blank dashboard");let i=nu.map(o=>ue(ie({},o),{id:Gt.create()}));this.dashboards.set([...i])}else this.dashboards.set(e);this.applyDashboardParam(this.getRouteParam("id"),!1);let t=this._router.events.pipe(di(i=>i instanceof Kd),er({bufferSize:1,refCount:!0}),tt(this._destroyRef));t.pipe(ci(1),Yt(()=>this.getRouteParam("id"))).subscribe(i=>this.applyDashboardParam(i,!0)),t.pipe(tr(1),Yt(()=>this.getRouteParam("id")),Ko()).subscribe(i=>this.applyDashboardParam(i,!1)),V(()=>{let i=this.dashboards();W(()=>{this._settings.saveDashboards(i)})})}getRouteParam(e){let t=this._router.routerState.snapshot.root;for(;t;){if(t.paramMap.has(e))return t.paramMap.get(e);t=t.firstChild??null}return null}applyDashboardParam(e,t){if(e===null||e===""){t&&this.setActiveDashboardIndex(0);return}let i=Number(e);if(Number.isNaN(i)){t&&this.setActiveDashboardIndex(0);return}this.setActiveDashboardIndex(i)}setActiveDashboardIndex(e){e!==this.activeDashboard()&&(e>=0&&e<this.dashboards().length?this.activeDashboard.set(e):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`))}toggleStaticDashboard(){this.isDashboardStatic.set(!this.isDashboardStatic())}add(e,t,i,o){let r=0;return this.dashboards.update(s=>{let c=[...s,{id:Gt.create(),name:e,icon:i??"dashboard-dashboard",configuration:t,collapseSplitShell:o??!1}];return r=c.length-1,c}),r}update(e,t,i,o){this.dashboards.update(r=>r.map((s,c)=>c===e?ue(ie({},s),{name:t,icon:i??"dashboard-dashboard",collapseSplitShell:o??!1}):s))}delete(e){this.dashboards.update(t=>t.filter((i,o)=>o!==e)),this.dashboards().length===0?(this.add("Dashboard "+(this.dashboards().length+1),[]),this.activeDashboard.set(0)):this.activeDashboard()>this.dashboards().length-1&&this.activeDashboard.set(this.dashboards().length-1)}duplicate(e,t,i,o){if(e<0||e>=this.dashboards().length)return console.error(`[Dashboard Service] Invalid itemIndex: ${e}`),-1;let r=this.dashboards()[e],s=Bt(r);s.id=Gt.create(),s.name=t,s.icon=i||"dashboard-dashboard",s.collapseSplitShell=o??!1,Array.isArray(s.configuration)?s.configuration.forEach(p=>{p&&p.input?.widgetProperties?(p.id=Gt.create(),p.input.widgetProperties.uuid=p.id):console.error("Dashboard Service] Widget configuration is missing required properties:",p)}):(console.error("Dashboard Service] Dashboard configuration is not an array:",s.configuration),s.configuration=[]);let c=-1;return this.dashboards.update(p=>{let f=[...p,s];return c=f.length-1,f}),c}updateConfiguration(e,t){this.dashboards.update(i=>i.map((o,r)=>r===e?gi(o.configuration,t)?o:ue(ie({},o),{configuration:t}):o))}previousDashboard(){this.activeDashboard()+1>this.dashboards().length-1?this.activeDashboard.set(0):this.activeDashboard.set(this.activeDashboard()+1)}nextDashboard(){this.activeDashboard()-1<0?this.activeDashboard.set(this.dashboards().length-1):this.activeDashboard.set(this.activeDashboard()-1)}navigateToActive(){this._router.navigate(["/dashboard",this.activeDashboard()])}navigateTo(e){e>=0&&e<this.dashboards().length?this._router.navigate(["/dashboard",e]):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`)}navigateToNextDashboard(){let e=null;this.activeDashboard()-1<0?e=this.dashboards().length-1:e=this.activeDashboard()-1,this._router.navigate(["/dashboard",e])}navigateToPreviousDashboard(){let e=null;this.activeDashboard()+1>=this.dashboards().length?e=0:e=this.activeDashboard()+1,this._router.navigate(["/dashboard",e])}deleteWidget(e){this._widgetAction.next({id:e,operation:"delete"})}duplicateWidget(e){this._widgetAction.next({id:e,operation:"duplicate"})}copyWidget(e){this._widgetAction.next({id:e,operation:"copy"})}cutWidget(e){this._widgetAction.next({id:e,operation:"cut"})}setWidgetClipboardFromNode(e){let t=e?.input?.widgetProperties,i=t?.type;i&&this.widgetClipboard.set({w:e.w,h:e.h,selector:e.selector,input:{widgetProperties:{type:i,uuid:"clipboard",config:Bt(t.config)}}})}clearWidgetClipboard(){this.widgetClipboard.set(null)}setStaticDashboard(e){this.isDashboardStatic.set(e)}notifyLayoutEditSaved(){this.layoutEditSaved.update(e=>e+1)}notifyLayoutEditCanceled(){this.layoutEditCanceled.update(e=>e+1)}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var on=(()=>{class n{appSettings=A(At);data=A(ti);_svcDatasetConfigs=[];_svcDataSource=[];_svcSubjectObserverRegistry=[];signedAnglePaths=new Set(["self.navigation.attitude.roll","self.navigation.attitude.pitch","self.navigation.attitude.yaw","self.environment.wind.angleApparent","self.environment.wind.angleTrueGround","self.environment.wind.angleTrueWater","self.steering.rudderAngle"]);constructor(){this._svcDatasetConfigs=this.appSettings.getDataSets(),this.cleanupDatasets(),this.startAll()}cleanupDatasets(){if(this.appSettings.configUpgrade()||this.appSettings.getAppConfig().configVersion<12)return;let t=this.appSettings.getDashboardConfig(),i=new Set;t.forEach(c=>{c.configuration?.length&&c.configuration?.forEach(p=>{p?.id&&i.add(p.id)})});function o(c){let p=c.match(/^(windtrends|speedtrends)-(.+)$/);return p?p[2]:null}let r=[],s=[];for(let c of this._svcDatasetConfigs){let p=c.label||"",f=!1;if(p.startsWith("windtrends-")||p.startsWith("speedtrends-")){let b=o(p);f=!!(b&&i.has(b))}else(p.startsWith("simple-chart-")||(p.match(/\|/g)||[]).length===4)&&(f=i.has(c.uuid));f?s.push(c):r.push(c)}r.length&&(r.forEach(c=>{console.warn(`[DatasetService] Cleaned dataset: uuid=${c.uuid}, label="${c.label}"`)}),this._svcDatasetConfigs=s,this.appSettings.saveDataSets(this._svcDatasetConfigs))}setupServiceSubjectRegistry(e,t){let i=this._svcSubjectObserverRegistry.findIndex(o=>o.datasetUuid==e);i>=0&&(this._svcSubjectObserverRegistry[i].rxjsSubject.complete(),this._svcSubjectObserverRegistry.splice(i,1)),this._svcSubjectObserverRegistry.push({datasetUuid:e,rxjsSubject:new wd(t)})}createDataSourceConfiguration(e){let r={uuid:e.uuid,pathObserverSubscription:null,sampleTime:null,maxDataPoints:null,smoothingPeriod:null,historicalData:[]},s=p(e.timeScaleFormat,e.period),c=s>0?Math.max(100,Math.round(s/120)):1e3;return r.sampleTime=c,r.maxDataPoints=Math.max(1,Math.ceil(s/c)),r.smoothingPeriod=Math.max(1,Math.floor(r.maxDataPoints*.25)),(!r.maxDataPoints||r.maxDataPoints<1)&&(r.maxDataPoints=1),(!r.sampleTime||r.sampleTime<1)&&(r.sampleTime=1),r;function p(f,b){switch(f){case"Last Minute":return 6e4;case"Last 5 Minutes":return 5*6e4;case"Last 30 Minutes":return 30*6e4;case"hour":return Math.max(0,b)*60*6e4;case"minute":return Math.max(0,b)*6e4;case"second":return Math.max(0,b)*1e3;default:return 0}}}startAll(){console.log("[Dataset Service] Auto Starting "+this._svcDatasetConfigs.length.toString()+" Datasets");for(let e of this._svcDatasetConfigs)this.start(e.uuid)}start(e){let t=this._svcDatasetConfigs.find(f=>f.uuid==e);if(!t){console.warn(`[Dataset Service] Dataset UUID:${e} not found`);return}let i=this.createDataSourceConfiguration(t);this.setupServiceSubjectRegistry(i.uuid,i.maxDataPoints);let o=this._svcDataSource[this._svcDataSource.push(i)-1];console.log(`[Dataset Service] Starting recording process: ${t.path}, Scale: ${t.timeScaleFormat}, Period: ${t.period}, Datapoints: ${i.maxDataPoints}`);let r=this.resolveAngleDomain(t.path,t.baseUnit),s=this.data.subscribePath(t.path,t.pathSource).pipe(di(f=>f?.data?.value!==null),er({bufferSize:1,refCount:!0})),c=s.pipe(ci(1)),p=Hn(i.sampleTime,i.sampleTime).pipe(Nd(s,(f,b)=>b));o.pathObserverSubscription=li(c,p).subscribe(f=>{o.maxDataPoints>0&&o.historicalData.length>=o.maxDataPoints&&o.historicalData.shift(),o.historicalData.push(f.data.value);let b=this.updateDataset(o,t.baseUnit,r);this._svcSubjectObserverRegistry.find(x=>x.datasetUuid===o.uuid).rxjsSubject.next(b)})}stop(e){let t=this._svcDataSource.findIndex(i=>i.uuid==e);console.log(`[Dataset Service] Stopping Dataset ${e} data capture`),this._svcDataSource[t].pathObserverSubscription.unsubscribe(),this._svcDataSource.splice(t,1)}list(){return Bt(this._svcDatasetConfigs)}getDatasetConfig(e){return this._svcDatasetConfigs.find(t=>t.uuid===e)}getDataSourceInfo(e){return this._svcDataSource.find(t=>t.uuid===e)}create(e,t,i,o,r,s=!0,c=!0,p){if(!e||!t||!i||!o||!r)return null;let f=p||Gt.create(),b={uuid:f,path:e,pathSource:t,baseUnit:this.data.getPathUnitType(e),timeScaleFormat:i,period:o,label:r,editable:c};return console.log(`[Dataset Service] Creating ${s?"":"non-"}persistent ${c?"":"hidden "}dataset: ${b.uuid}, Path: ${b.path}, Source: ${b.pathSource} Scale: ${b.timeScaleFormat}, Period: ${b.period}`),this._svcDatasetConfigs.push(b),this.start(f),s===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),f}edit(e,t=!0){let i=this._svcDatasetConfigs.find(o=>o.uuid===e.uuid);return i?JSON.stringify(i)===JSON.stringify(e)?(console.log(`[Dataset Service] No changes detected for Dataset ${e.uuid}.`),!1):(this.stop(e.uuid),console.log(`[Dataset Service] Updating Dataset: ${e.uuid}`),e.baseUnit=this.data.getPathUnitType(e.path),this._svcDatasetConfigs.splice(this._svcDatasetConfigs.findIndex(o=>o.uuid===e.uuid),1,e),this.start(e.uuid),t===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),!0):!1}remove(e,t=!0){return!e||e===""||this._svcDatasetConfigs.findIndex(i=>i.uuid===e)===-1?!1:(this.stop(e),console.log(`[Dataset Service] Removing ${t?"":"non-"}persistent Dataset: ${e}`),this._svcDatasetConfigs.splice(this._svcDatasetConfigs.findIndex(i=>i.uuid===e),1),this._svcSubjectObserverRegistry.find(i=>i.datasetUuid===e).rxjsSubject.complete(),this._svcSubjectObserverRegistry.splice(this._svcSubjectObserverRegistry.findIndex(i=>i.datasetUuid===e),1),t===!0&&this.appSettings.saveDataSets(this._svcDatasetConfigs),!0)}getDatasetObservable(e){let t=this._svcSubjectObserverRegistry.find(i=>i.datasetUuid==e);return t?t.rxjsSubject.asObservable():null}getDatasetBatchThenLiveObservable(e){let t=this._svcSubjectObserverRegistry.find(c=>c.datasetUuid==e);if(!t)return null;let i=t.rxjsSubject,o=i._buffer?i._buffer.slice():[],r=Sd([o]),s=i.pipe(tr(o.length));return kd(r,s)}updateDataset(e,t,i="scalar"){let o=null,r=null,s=null,c=null;if(t==="rad"){o=this.circularMeanRad(e.historicalData);let x=e.historicalData.slice(-e.smoothingPeriod);r=this.circularMeanRad(x);let{min:_,max:k}=this.circularMinMaxRad(e.historicalData);i==="direction"?(o=this.normalizeToDirection(o),r=this.normalizeToDirection(r),s=this.normalizeToDirection(_),c=this.normalizeToDirection(k)):i==="signed"?(o=this.normalizeToSigned(o),r=this.normalizeToSigned(r),s=this.normalizeToSigned(_),c=this.normalizeToSigned(k)):(s=_,c=k)}else o=f(e.historicalData),r=b(e.historicalData,e.smoothingPeriod),s=Math.min(...e.historicalData),c=Math.max(...e.historicalData);return{timestamp:Date.now(),data:{value:t==="rad"?i==="signed"?this.normalizeToSigned(e.historicalData[e.historicalData.length-1]):this.normalizeToDirection(e.historicalData[e.historicalData.length-1]):e.historicalData[e.historicalData.length-1],sma:r,ema:null,doubleEma:null,lastAverage:o,lastMinimum:s,lastMaximum:c}};function f(x){return x.length===0?null:x.reduce((k,S)=>k+S,0)/x.length}function b(x,_){x.length<_&&(_=x.length);let k=0;for(let S=x.length-_;S<x.length;S++)k+=x[S];return k/_}}circularMeanRad(e){if(e.length===0)return 0;let t=e.reduce((o,r)=>o+Math.sin(r),0),i=e.reduce((o,r)=>o+Math.cos(r),0);return Math.atan2(t/e.length,i/e.length)}circularMinMaxRad(e){if(e.length===0)return{min:0,max:0};let t=e.map(c=>(c*180/Math.PI+360)%360).sort((c,p)=>c-p),i=0,o=0;for(let c=0;c<t.length;c++){let p=(c+1)%t.length,f=(t[p]-t[c]+360)%360;f>i&&(i=f,o=p)}let r=t[o]*Math.PI/180,s=t[(o-1+t.length)%t.length]*Math.PI/180;return{min:r,max:s}}resolveAngleDomain(e,t){if(t!=="rad")return"scalar";let i=this.normalizePathKey(e);for(let o of this.signedAnglePaths)if(i===this.normalizePathKey(o))return"signed";return"direction"}normalizePathKey(e){return e.replace(/^vessels\.self\./,"").replace(/^self\./,"")}mod(e,t){return(e%t+t)%t}normalizeToDirection(e){let t=2*Math.PI;return this.mod(e,t)}normalizeToSigned(e){let t=2*Math.PI;return this.mod(e+Math.PI,t)-Math.PI}removeIfExists(e,t=!0){return!e||this._svcDatasetConfigs.findIndex(i=>i.uuid===e)===-1?!1:this.remove(e,t)}ngOnDestroy(){[...this._svcDataSource].forEach(e=>{try{this.stop(e.uuid)}catch(t){}}),this._svcSubjectObserverRegistry.forEach(e=>e.rxjsSubject.complete()),this._svcSubjectObserverRegistry=[]}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var au=(()=>{class n{kipTimers={};constructor(){}createTimer(e,t,i){return e in this.kipTimers?this.kipTimers[e].currentValue.asObservable():(this.kipTimers[e]={currentValue:new Wi(t),timeoutID:null,intervalMS:i},this.kipTimers[e].currentValue.asObservable())}startTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].timeoutID===null&&(this.kipTimers[e].timeoutID=setInterval(()=>{this.kipTimers[e].currentValue.next(this.kipTimers[e].currentValue.value+1)},this.kipTimers[e].intervalMS))}stopTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].timeoutID!==null&&(clearInterval(this.kipTimers[e].timeoutID),this.kipTimers[e].timeoutID=null)}setTimer(e,t){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&this.kipTimers[e].currentValue.next(t)}deleteTimer(e){Object.prototype.hasOwnProperty.call(this.kipTimers,e)&&(this.stopTimer(e),this.kipTimers[e].currentValue.complete(),delete this.kipTimers[e])}isRunning(e){let t=!1;return e in this.kipTimers&&(t=this.kipTimers[e].timeoutID!==null),t}ngOnDestroy(){Object.keys(this.kipTimers).forEach(e=>{this.kipTimers[e].timeoutID&&(clearInterval(this.kipTimers[e].timeoutID),this.kipTimers[e].timeoutID=null),this.kipTimers[e].currentValue.complete()}),this.kipTimers={}}static \u0275fac=function(t){return new(t||n)};static \u0275prov=pt({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();var ou=(()=>{class n{sanitizer=A(ka);transform(e){return this.sanitizer.bypassSecurityTrustResourceUrl(e)}static \u0275fac=function(t){return new(t||n)};static \u0275pipe=dr({name:"safe",type:n,pure:!0})}return n})();var df={minDist:230,maxDur:550,minVelocity:1.5,axisDominance:1.8,deadzoneMs:160,purityRatio:.8,lockThreshold:28,directionLockAngle:25,reversalPrimaryThreshold:34};function Qa(n){let a=ie(ie({},df),n);return`(() => {
|
|
2
2
|
if (window.__kipSwipeInit) return; window.__kipSwipeInit = true;
|
|
3
3
|
const instanceId='${a.instanceId}';
|
|
4
4
|
let pointerId=null; let startX=0; let startY=0; let startT=0; let peakPrimary=0; let peakCross=0; let cancelled=false;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{T as Ct,a as st,aa as yi,c as lt,d as _i,f as fi,g as bi,i as vi}from"./chunk-57TQNMBB.js";import{a as Ee,b as hi,e as ui,f as rt,g as gi,i as wi}from"./chunk-VH4ZIU4T.js";import{a as Si}from"./chunk-UVAQADRE.js";import{f as Te,i as ot,n as pi}from"./chunk-IWK4FHBL.js";import{d as Zt}from"./chunk-PSF2OKKT.js";import{a as Ci}from"./chunk-KIR67PZ2.js";import{a as se}from"./chunk-HJQQWPGC.js";import{a as z,h as oi,o as ae,p as nt,v as oe,x as ke,y as at}from"./chunk-KKJXPB75.js";import{A as q,F as et,G as tt,J as ne,K as ci,L as mi,M as j,N as it,d as yt,h as jt,i as Kt,j as Gt,k as Ge,l as Qt,m as B,n as $e,o as Me,p as si,q as ri,s as H,t as X,v as li,w as te,y as di,z as ie}from"./chunk-XEJJOWK6.js";import{b as ii,f as ni,g as ai}from"./chunk-PESXPDBT.js";import{$a as Ot,$d as Ye,Aa as At,Ab as C,Ad as Qe,Ba as Pt,Bb as S,Cb as He,Da as E,Db as Ut,Ea as ge,Eb as Y,Ed as Ze,Fb as $,Fc as je,Ga as _e,Gb as h,Gd as we,Hb as a,Ib as s,Ic as ee,J as Rt,Ja as fe,Jb as g,K as Re,Ka as Vt,Kb as Xe,Kc as G,Kd as Je,Lb as ft,Ma as K,Mb as Bt,Mc as U,Na as Nt,Oc as M,Pc as A,Q as Dt,Qb as P,Rb as Wt,Rd as he,Sb as b,Sd as Jt,Ub as T,Ud as Yt,Vb as le,Wb as N,Xb as Ae,Ya as m,Yb as de,Zb as I,_b as R,ac as be,ba as _t,bb as De,bc as ve,be as Ce,cc as k,dc as qe,ec as L,ed as qt,ee as wt,f as Le,fb as Ft,g as Ue,gc as ce,ge as $t,hc as r,he as Ve,ic as Pe,ie as Se,jb as x,jc as zt,k as re,ka as Be,kb as J,kc as bt,ke as ei,lb as O,lc as vt,le as xe,ma as Z,mc as v,me as ti,nc as y,ne as W,oa as D,ob as ze,oc as w,pb as Lt,pd as ye,q as It,qa as c,qd as Ke,uc as V,va as p,vc as me,wa as u,xa as We,xc as Ht,yb as F,yc as Xt}from"./chunk-TGGJAGV7.js";var zi=(n,f)=>f.key,Hi=(n,f)=>f.measure;function Xi(n,f){if(n&1&&(a(0,"mat-option",6),r(1),s()),n&2){let e=f.$implicit;h("value",e.measure),m(),Pe(e.description)}}function qi(n,f){if(n&1&&(a(0,"mat-form-field")(1,"mat-label"),r(2),s(),a(3,"mat-select",5),Y(4,Xi,2,2,"mat-option",6,Hi),s()()),n&2){let e=f.$implicit,i=T();m(2),Pe(e.key),m(),h("placeholder",e.key)("formControlName",e.key),m(),$(i.groupUnits[e.key])}}var xi=(()=>{class n{units=c(gi);appSettingsService=c(B);toast=c(z);unitsFormGroup=new li({});groupUnits=[];ngOnInit(){let e=this.appSettingsService.getDefaultUnits(),i=this.units.getConversions();for(let t of i){if(t.group==="Position")continue;let o=[];for(let d of t.units)o.push(d);this.groupUnits[t.group]=o,this.unitsFormGroup.addControl(t.group,new di(e[t.group]))}this.unitsFormGroup.updateValueAndValidity()}submitConfig(){this.appSettingsService.setDefaultUnits(this.unitsFormGroup.value),this.toast.show("Configuration saved",1e3,!0,null,"message")}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["settings-units"]],decls:11,vars:4,consts:[[2,"height","100%",3,"ngSubmit","formGroup"],[1,"unit-grid"],[1,"formActionFooter"],[1,"formActionDivider"],["mat-flat-button","","type","submit",1,"formActionButton",3,"disabled"],["required","",3,"placeholder","formControlName"],[3,"value"]],template:function(i,t){i&1&&(a(0,"form",0),b("ngSubmit",function(){return t.submitConfig()}),a(1,"p"),r(2,"Configure your preferred default unit types. These defaults can be overridden within individual widget settings."),s(),a(3,"div",1),Y(4,qi,6,3,"mat-form-field",null,zi),Ht(6,"keyvalue"),s(),a(7,"div",2),g(8,"mat-divider",3),a(9,"button",4),r(10,"Save"),s()()()),i&2&&(h("formGroup",t.unitsFormGroup),m(4),$(Xt(6,2,t.unitsFormGroup.controls)),m(5),h("disabled",!t.unitsFormGroup.valid))},dependencies:[j,q,H,X,ne,it,tt,et,oe,ae,Ee,Te,se,W,qt],styles:[".unit-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,auto));gap:10px}"]})}return n})();var St=new D("CdkAccordion"),Mi=(()=>{class n{_stateChanges=new re;_openCloseAllActions=new re;id=c(he).getId("cdk-accordion-");multi=!1;openAll(){this.multi&&this._openCloseAllActions.next(!0)}closeAll(){this._openCloseAllActions.next(!1)}ngOnChanges(e){this._stateChanges.next(e)}ngOnDestroy(){this._stateChanges.complete(),this._openCloseAllActions.complete()}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:[2,"multi","multi",M]},exportAs:["cdkAccordion"],features:[V([{provide:St,useExisting:n}]),fe]})}return n})(),ki=(()=>{class n{accordion=c(St,{optional:!0,skipSelf:!0});_changeDetectorRef=c(U);_expansionDispatcher=c(ot);_openCloseAllSubscription=Ue.EMPTY;closed=new E;opened=new E;destroyed=new E;expandedChange=new E;id=c(he).getId("cdk-accordion-child-");get expanded(){return this._expanded}set expanded(e){if(this._expanded!==e){if(this._expanded=e,this.expandedChange.emit(e),e){this.opened.emit();let i=this.accordion?this.accordion.id:this.id;this._expansionDispatcher.notify(this.id,i)}else this.closed.emit();this._changeDetectorRef.markForCheck()}}_expanded=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=_e(!1);_removeUniqueSelectionListener=()=>{};constructor(){}ngOnInit(){this._removeUniqueSelectionListener=this._expansionDispatcher.listen((e,i)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===i&&this.id!==e&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",M],disabled:[2,"disabled","disabled",M]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[V([{provide:St,useValue:void 0}])]})}return n})(),Ti=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275mod=J({type:n});static \u0275inj=Z({})}return n})();var Gi=["body"],Qi=["bodyWrapper"],Zi=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],Ji=["mat-expansion-panel-header","*","mat-action-row"];function Yi(n,f){}var $i=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],en=["mat-panel-title","mat-panel-description","*"];function tn(n,f){n&1&&(Xe(0,"span",1),We(),Xe(1,"svg",2),Bt(2,"path",3),ft()())}var xt=new D("MAT_ACCORDION"),Ei=new D("MAT_EXPANSION_PANEL"),nn=(()=>{class n{_template=c(Ot);_expansionPanel=c(Ei,{optional:!0});constructor(){}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["ng-template","matExpansionPanelContent",""]]})}return n})(),Ii=new D("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),Ne=(()=>{class n extends ki{_viewContainerRef=c(Ft);_animationsDisabled=Ce();_document=c(At);_ngZone=c(ge);_elementRef=c(K);_renderer=c(De);_cleanupTransitionEnd;get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=e}_hideToggle=!1;get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_togglePosition;afterExpand=new E;afterCollapse=new E;_inputChanges=new re;accordion=c(xt,{optional:!0,skipSelf:!0});_lazyContent;_body;_bodyWrapper;_portal;_headerId=c(he).getId("mat-expansion-panel-header-");constructor(){super();let e=c(Ii,{optional:!0});this._expansionDispatcher=c(ot),e&&(this.hideToggle=e.hideToggle)}_hasSpacing(){return this.accordion?this.expanded&&this.accordion.displayMode==="default":!1}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(_t(null),Re(()=>this.expanded&&!this._portal),Dt(1)).subscribe(()=>{this._portal=new ii(this._lazyContent._template,this._viewContainerRef)}),this._setupAnimationEvents()}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTransitionEnd?.(),this._inputChanges.complete()}_containsFocus(){if(this._body){let e=this._document.activeElement,i=this._body.nativeElement;return e===i||i.contains(e)}return!1}_transitionEndListener=({target:e,propertyName:i})=>{e===this._bodyWrapper?.nativeElement&&i==="grid-template-rows"&&this._ngZone.run(()=>{this.expanded?this.afterExpand.emit():this.afterCollapse.emit()})};_setupAnimationEvents(){this._ngZone.runOutsideAngular(()=>{this._animationsDisabled?(this.opened.subscribe(()=>this._ngZone.run(()=>this.afterExpand.emit())),this.closed.subscribe(()=>this._ngZone.run(()=>this.afterCollapse.emit()))):setTimeout(()=>{let e=this._elementRef.nativeElement;this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this._transitionEndListener),e.classList.add("mat-expansion-panel-animations-enabled")},200)})}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["mat-expansion-panel"]],contentQueries:function(i,t,o){if(i&1&&Ae(o,nn,5),i&2){let d;I(d=R())&&(t._lazyContent=d.first)}},viewQuery:function(i,t){if(i&1&&de(Gi,5)(Qi,5),i&2){let o;I(o=R())&&(t._body=o.first),I(o=R())&&(t._bodyWrapper=o.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:4,hostBindings:function(i,t){i&2&&L("mat-expanded",t.expanded)("mat-expansion-panel-spacing",t._hasSpacing())},inputs:{hideToggle:[2,"hideToggle","hideToggle",M],togglePosition:"togglePosition"},outputs:{afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[V([{provide:xt,useValue:void 0},{provide:Ei,useExisting:n}]),ze,fe],ngContentSelectors:Ji,decls:9,vars:4,consts:[["bodyWrapper",""],["body",""],[1,"mat-expansion-panel-content-wrapper"],["role","region",1,"mat-expansion-panel-content",3,"id"],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(i,t){i&1&&(le(Zi),N(0),a(1,"div",2,0)(3,"div",3,1)(5,"div",4),N(6,1),Lt(7,Yi,0,0,"ng-template",5),s(),N(8,2),s()()),i&2&&(m(),F("inert",t.expanded?null:""),m(2),h("id",t.id),F("aria-labelledby",t._headerId),m(4),h("cdkPortalOutlet",t._portal))},dependencies:[ni],styles:[`.mat-expansion-panel{box-sizing:content-box;display:block;margin:0;overflow:hidden;position:relative;background:var(--mat-expansion-container-background-color, var(--mat-sys-surface));color:var(--mat-expansion-container-text-color, var(--mat-sys-on-surface));border-radius:var(--mat-expansion-container-shape, 12px)}.mat-expansion-panel.mat-expansion-panel-animations-enabled{transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel:not([class*=mat-elevation-z]){box-shadow:var(--mat-expansion-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:var(--mat-expansion-container-shape, 12px);border-top-left-radius:var(--mat-expansion-container-shape, 12px)}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:var(--mat-expansion-container-shape, 12px);border-bottom-left-radius:var(--mat-expansion-container-shape, 12px)}@media(forced-colors: active){.mat-expansion-panel{outline:solid 1px}}.mat-expansion-panel-content-wrapper{display:grid;grid-template-rows:0fr;grid-template-columns:100%}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content-wrapper{transition:grid-template-rows 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{grid-template-rows:1fr}@supports not (grid-template-rows: 0fr){.mat-expansion-panel-content-wrapper{height:0}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{height:auto}}@media print{.mat-expansion-panel-content-wrapper{height:0}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{height:auto}}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible;min-height:0;visibility:hidden;font-family:var(--mat-expansion-container-text-font, var(--mat-sys-body-large-font));font-size:var(--mat-expansion-container-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-expansion-container-text-weight, var(--mat-sys-body-large-weight));line-height:var(--mat-expansion-container-text-line-height, var(--mat-sys-body-large-line-height));letter-spacing:var(--mat-expansion-container-text-tracking, var(--mat-sys-body-large-tracking))}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content{transition:visibility 190ms linear}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper>.mat-expansion-panel-content{visibility:visible}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px;border-top-color:var(--mat-expansion-actions-divider-color, var(--mat-sys-outline))}.mat-action-row .mat-button-base,.mat-action-row .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row .mat-button-base,[dir=rtl] .mat-action-row .mat-mdc-button-base{margin-left:0;margin-right:8px}
|
|
1
|
+
import{T as Ct,a as st,aa as yi,c as lt,d as _i,f as fi,g as bi,i as vi}from"./chunk-2MWBAYPJ.js";import{a as Ee,b as hi,e as ui,f as rt,g as gi,i as wi}from"./chunk-VH4ZIU4T.js";import{a as Si}from"./chunk-UVAQADRE.js";import{f as Te,i as ot,n as pi}from"./chunk-IWK4FHBL.js";import{d as Zt}from"./chunk-PSF2OKKT.js";import{a as Ci}from"./chunk-KIR67PZ2.js";import{a as se}from"./chunk-HJQQWPGC.js";import{a as z,h as oi,o as ae,p as nt,v as oe,x as ke,y as at}from"./chunk-KKJXPB75.js";import{A as q,F as et,G as tt,J as ne,K as ci,L as mi,M as j,N as it,d as yt,h as jt,i as Kt,j as Gt,k as Ge,l as Qt,m as B,n as $e,o as Me,p as si,q as ri,s as H,t as X,v as li,w as te,y as di,z as ie}from"./chunk-XEJJOWK6.js";import{b as ii,f as ni,g as ai}from"./chunk-PESXPDBT.js";import{$a as Ot,$d as Ye,Aa as At,Ab as C,Ad as Qe,Ba as Pt,Bb as S,Cb as He,Da as E,Db as Ut,Ea as ge,Eb as Y,Ed as Ze,Fb as $,Fc as je,Ga as _e,Gb as h,Gd as we,Hb as a,Ib as s,Ic as ee,J as Rt,Ja as fe,Jb as g,K as Re,Ka as Vt,Kb as Xe,Kc as G,Kd as Je,Lb as ft,Ma as K,Mb as Bt,Mc as U,Na as Nt,Oc as M,Pc as A,Q as Dt,Qb as P,Rb as Wt,Rd as he,Sb as b,Sd as Jt,Ub as T,Ud as Yt,Vb as le,Wb as N,Xb as Ae,Ya as m,Yb as de,Zb as I,_b as R,ac as be,ba as _t,bb as De,bc as ve,be as Ce,cc as k,dc as qe,ec as L,ed as qt,ee as wt,f as Le,fb as Ft,g as Ue,gc as ce,ge as $t,hc as r,he as Ve,ic as Pe,ie as Se,jb as x,jc as zt,k as re,ka as Be,kb as J,kc as bt,ke as ei,lb as O,lc as vt,le as xe,ma as Z,mc as v,me as ti,nc as y,ne as W,oa as D,ob as ze,oc as w,pb as Lt,pd as ye,q as It,qa as c,qd as Ke,uc as V,va as p,vc as me,wa as u,xa as We,xc as Ht,yb as F,yc as Xt}from"./chunk-TGGJAGV7.js";var zi=(n,f)=>f.key,Hi=(n,f)=>f.measure;function Xi(n,f){if(n&1&&(a(0,"mat-option",6),r(1),s()),n&2){let e=f.$implicit;h("value",e.measure),m(),Pe(e.description)}}function qi(n,f){if(n&1&&(a(0,"mat-form-field")(1,"mat-label"),r(2),s(),a(3,"mat-select",5),Y(4,Xi,2,2,"mat-option",6,Hi),s()()),n&2){let e=f.$implicit,i=T();m(2),Pe(e.key),m(),h("placeholder",e.key)("formControlName",e.key),m(),$(i.groupUnits[e.key])}}var xi=(()=>{class n{units=c(gi);appSettingsService=c(B);toast=c(z);unitsFormGroup=new li({});groupUnits=[];ngOnInit(){let e=this.appSettingsService.getDefaultUnits(),i=this.units.getConversions();for(let t of i){if(t.group==="Position")continue;let o=[];for(let d of t.units)o.push(d);this.groupUnits[t.group]=o,this.unitsFormGroup.addControl(t.group,new di(e[t.group]))}this.unitsFormGroup.updateValueAndValidity()}submitConfig(){this.appSettingsService.setDefaultUnits(this.unitsFormGroup.value),this.toast.show("Configuration saved",1e3,!0,null,"message")}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["settings-units"]],decls:11,vars:4,consts:[[2,"height","100%",3,"ngSubmit","formGroup"],[1,"unit-grid"],[1,"formActionFooter"],[1,"formActionDivider"],["mat-flat-button","","type","submit",1,"formActionButton",3,"disabled"],["required","",3,"placeholder","formControlName"],[3,"value"]],template:function(i,t){i&1&&(a(0,"form",0),b("ngSubmit",function(){return t.submitConfig()}),a(1,"p"),r(2,"Configure your preferred default unit types. These defaults can be overridden within individual widget settings."),s(),a(3,"div",1),Y(4,qi,6,3,"mat-form-field",null,zi),Ht(6,"keyvalue"),s(),a(7,"div",2),g(8,"mat-divider",3),a(9,"button",4),r(10,"Save"),s()()()),i&2&&(h("formGroup",t.unitsFormGroup),m(4),$(Xt(6,2,t.unitsFormGroup.controls)),m(5),h("disabled",!t.unitsFormGroup.valid))},dependencies:[j,q,H,X,ne,it,tt,et,oe,ae,Ee,Te,se,W,qt],styles:[".unit-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,auto));gap:10px}"]})}return n})();var St=new D("CdkAccordion"),Mi=(()=>{class n{_stateChanges=new re;_openCloseAllActions=new re;id=c(he).getId("cdk-accordion-");multi=!1;openAll(){this.multi&&this._openCloseAllActions.next(!0)}closeAll(){this._openCloseAllActions.next(!1)}ngOnChanges(e){this._stateChanges.next(e)}ngOnDestroy(){this._stateChanges.complete(),this._openCloseAllActions.complete()}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["cdk-accordion"],["","cdkAccordion",""]],inputs:{multi:[2,"multi","multi",M]},exportAs:["cdkAccordion"],features:[V([{provide:St,useExisting:n}]),fe]})}return n})(),ki=(()=>{class n{accordion=c(St,{optional:!0,skipSelf:!0});_changeDetectorRef=c(U);_expansionDispatcher=c(ot);_openCloseAllSubscription=Ue.EMPTY;closed=new E;opened=new E;destroyed=new E;expandedChange=new E;id=c(he).getId("cdk-accordion-child-");get expanded(){return this._expanded}set expanded(e){if(this._expanded!==e){if(this._expanded=e,this.expandedChange.emit(e),e){this.opened.emit();let i=this.accordion?this.accordion.id:this.id;this._expansionDispatcher.notify(this.id,i)}else this.closed.emit();this._changeDetectorRef.markForCheck()}}_expanded=!1;get disabled(){return this._disabled()}set disabled(e){this._disabled.set(e)}_disabled=_e(!1);_removeUniqueSelectionListener=()=>{};constructor(){}ngOnInit(){this._removeUniqueSelectionListener=this._expansionDispatcher.listen((e,i)=>{this.accordion&&!this.accordion.multi&&this.accordion.id===i&&this.id!==e&&(this.expanded=!1)}),this.accordion&&(this._openCloseAllSubscription=this._subscribeToOpenCloseAllActions())}ngOnDestroy(){this.opened.complete(),this.closed.complete(),this.destroyed.emit(),this.destroyed.complete(),this._removeUniqueSelectionListener(),this._openCloseAllSubscription.unsubscribe()}toggle(){this.disabled||(this.expanded=!this.expanded)}close(){this.disabled||(this.expanded=!1)}open(){this.disabled||(this.expanded=!0)}_subscribeToOpenCloseAllActions(){return this.accordion._openCloseAllActions.subscribe(e=>{this.disabled||(this.expanded=e)})}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["cdk-accordion-item"],["","cdkAccordionItem",""]],inputs:{expanded:[2,"expanded","expanded",M],disabled:[2,"disabled","disabled",M]},outputs:{closed:"closed",opened:"opened",destroyed:"destroyed",expandedChange:"expandedChange"},exportAs:["cdkAccordionItem"],features:[V([{provide:St,useValue:void 0}])]})}return n})(),Ti=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275mod=J({type:n});static \u0275inj=Z({})}return n})();var Gi=["body"],Qi=["bodyWrapper"],Zi=[[["mat-expansion-panel-header"]],"*",[["mat-action-row"]]],Ji=["mat-expansion-panel-header","*","mat-action-row"];function Yi(n,f){}var $i=[[["mat-panel-title"]],[["mat-panel-description"]],"*"],en=["mat-panel-title","mat-panel-description","*"];function tn(n,f){n&1&&(Xe(0,"span",1),We(),Xe(1,"svg",2),Bt(2,"path",3),ft()())}var xt=new D("MAT_ACCORDION"),Ei=new D("MAT_EXPANSION_PANEL"),nn=(()=>{class n{_template=c(Ot);_expansionPanel=c(Ei,{optional:!0});constructor(){}static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["ng-template","matExpansionPanelContent",""]]})}return n})(),Ii=new D("MAT_EXPANSION_PANEL_DEFAULT_OPTIONS"),Ne=(()=>{class n extends ki{_viewContainerRef=c(Ft);_animationsDisabled=Ce();_document=c(At);_ngZone=c(ge);_elementRef=c(K);_renderer=c(De);_cleanupTransitionEnd;get hideToggle(){return this._hideToggle||this.accordion&&this.accordion.hideToggle}set hideToggle(e){this._hideToggle=e}_hideToggle=!1;get togglePosition(){return this._togglePosition||this.accordion&&this.accordion.togglePosition}set togglePosition(e){this._togglePosition=e}_togglePosition;afterExpand=new E;afterCollapse=new E;_inputChanges=new re;accordion=c(xt,{optional:!0,skipSelf:!0});_lazyContent;_body;_bodyWrapper;_portal;_headerId=c(he).getId("mat-expansion-panel-header-");constructor(){super();let e=c(Ii,{optional:!0});this._expansionDispatcher=c(ot),e&&(this.hideToggle=e.hideToggle)}_hasSpacing(){return this.accordion?this.expanded&&this.accordion.displayMode==="default":!1}_getExpandedState(){return this.expanded?"expanded":"collapsed"}toggle(){this.expanded=!this.expanded}close(){this.expanded=!1}open(){this.expanded=!0}ngAfterContentInit(){this._lazyContent&&this._lazyContent._expansionPanel===this&&this.opened.pipe(_t(null),Re(()=>this.expanded&&!this._portal),Dt(1)).subscribe(()=>{this._portal=new ii(this._lazyContent._template,this._viewContainerRef)}),this._setupAnimationEvents()}ngOnChanges(e){this._inputChanges.next(e)}ngOnDestroy(){super.ngOnDestroy(),this._cleanupTransitionEnd?.(),this._inputChanges.complete()}_containsFocus(){if(this._body){let e=this._document.activeElement,i=this._body.nativeElement;return e===i||i.contains(e)}return!1}_transitionEndListener=({target:e,propertyName:i})=>{e===this._bodyWrapper?.nativeElement&&i==="grid-template-rows"&&this._ngZone.run(()=>{this.expanded?this.afterExpand.emit():this.afterCollapse.emit()})};_setupAnimationEvents(){this._ngZone.runOutsideAngular(()=>{this._animationsDisabled?(this.opened.subscribe(()=>this._ngZone.run(()=>this.afterExpand.emit())),this.closed.subscribe(()=>this._ngZone.run(()=>this.afterCollapse.emit()))):setTimeout(()=>{let e=this._elementRef.nativeElement;this._cleanupTransitionEnd=this._renderer.listen(e,"transitionend",this._transitionEndListener),e.classList.add("mat-expansion-panel-animations-enabled")},200)})}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["mat-expansion-panel"]],contentQueries:function(i,t,o){if(i&1&&Ae(o,nn,5),i&2){let d;I(d=R())&&(t._lazyContent=d.first)}},viewQuery:function(i,t){if(i&1&&de(Gi,5)(Qi,5),i&2){let o;I(o=R())&&(t._body=o.first),I(o=R())&&(t._bodyWrapper=o.first)}},hostAttrs:[1,"mat-expansion-panel"],hostVars:4,hostBindings:function(i,t){i&2&&L("mat-expanded",t.expanded)("mat-expansion-panel-spacing",t._hasSpacing())},inputs:{hideToggle:[2,"hideToggle","hideToggle",M],togglePosition:"togglePosition"},outputs:{afterExpand:"afterExpand",afterCollapse:"afterCollapse"},exportAs:["matExpansionPanel"],features:[V([{provide:xt,useValue:void 0},{provide:Ei,useExisting:n}]),ze,fe],ngContentSelectors:Ji,decls:9,vars:4,consts:[["bodyWrapper",""],["body",""],[1,"mat-expansion-panel-content-wrapper"],["role","region",1,"mat-expansion-panel-content",3,"id"],[1,"mat-expansion-panel-body"],[3,"cdkPortalOutlet"]],template:function(i,t){i&1&&(le(Zi),N(0),a(1,"div",2,0)(3,"div",3,1)(5,"div",4),N(6,1),Lt(7,Yi,0,0,"ng-template",5),s(),N(8,2),s()()),i&2&&(m(),F("inert",t.expanded?null:""),m(2),h("id",t.id),F("aria-labelledby",t._headerId),m(4),h("cdkPortalOutlet",t._portal))},dependencies:[ni],styles:[`.mat-expansion-panel{box-sizing:content-box;display:block;margin:0;overflow:hidden;position:relative;background:var(--mat-expansion-container-background-color, var(--mat-sys-surface));color:var(--mat-expansion-container-text-color, var(--mat-sys-on-surface));border-radius:var(--mat-expansion-container-shape, 12px)}.mat-expansion-panel.mat-expansion-panel-animations-enabled{transition:margin 225ms cubic-bezier(0.4, 0, 0.2, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel:not([class*=mat-elevation-z]){box-shadow:var(--mat-expansion-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12))}.mat-accordion .mat-expansion-panel:not(.mat-expanded),.mat-accordion .mat-expansion-panel:not(.mat-expansion-panel-spacing){border-radius:0}.mat-accordion .mat-expansion-panel:first-of-type{border-top-right-radius:var(--mat-expansion-container-shape, 12px);border-top-left-radius:var(--mat-expansion-container-shape, 12px)}.mat-accordion .mat-expansion-panel:last-of-type{border-bottom-right-radius:var(--mat-expansion-container-shape, 12px);border-bottom-left-radius:var(--mat-expansion-container-shape, 12px)}@media(forced-colors: active){.mat-expansion-panel{outline:solid 1px}}.mat-expansion-panel-content-wrapper{display:grid;grid-template-rows:0fr;grid-template-columns:100%}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content-wrapper{transition:grid-template-rows 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{grid-template-rows:1fr}@supports not (grid-template-rows: 0fr){.mat-expansion-panel-content-wrapper{height:0}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{height:auto}}@media print{.mat-expansion-panel-content-wrapper{height:0}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper{height:auto}}.mat-expansion-panel-content{display:flex;flex-direction:column;overflow:visible;min-height:0;visibility:hidden;font-family:var(--mat-expansion-container-text-font, var(--mat-sys-body-large-font));font-size:var(--mat-expansion-container-text-size, var(--mat-sys-body-large-size));font-weight:var(--mat-expansion-container-text-weight, var(--mat-sys-body-large-weight));line-height:var(--mat-expansion-container-text-line-height, var(--mat-sys-body-large-line-height));letter-spacing:var(--mat-expansion-container-text-tracking, var(--mat-sys-body-large-tracking))}.mat-expansion-panel-animations-enabled .mat-expansion-panel-content{transition:visibility 190ms linear}.mat-expansion-panel.mat-expanded>.mat-expansion-panel-content-wrapper>.mat-expansion-panel-content{visibility:visible}.mat-expansion-panel-body{padding:0 24px 16px}.mat-expansion-panel-spacing{margin:16px 0}.mat-accordion>.mat-expansion-panel-spacing:first-child,.mat-accordion>*:first-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-top:0}.mat-accordion>.mat-expansion-panel-spacing:last-child,.mat-accordion>*:last-child:not(.mat-expansion-panel) .mat-expansion-panel-spacing{margin-bottom:0}.mat-action-row{border-top-style:solid;border-top-width:1px;display:flex;flex-direction:row;justify-content:flex-end;padding:16px 8px 16px 24px;border-top-color:var(--mat-expansion-actions-divider-color, var(--mat-sys-outline))}.mat-action-row .mat-button-base,.mat-action-row .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-action-row .mat-button-base,[dir=rtl] .mat-action-row .mat-mdc-button-base{margin-left:0;margin-right:8px}
|
|
2
2
|
`],encapsulation:2,changeDetection:0})}return n})();var Oe=(()=>{class n{panel=c(Ne,{host:!0});_element=c(K);_focusMonitor=c(Ze);_changeDetectorRef=c(U);_parentChangeSubscription=Ue.EMPTY;constructor(){c(we).load(Se);let e=this.panel,i=c(Ii,{optional:!0}),t=c(new je("tabindex"),{optional:!0}),o=e.accordion?e.accordion._stateChanges.pipe(Re(d=>!!(d.hideToggle||d.togglePosition))):It;this.tabIndex=parseInt(t||"")||0,this._parentChangeSubscription=Rt(e.opened,e.closed,o,e._inputChanges.pipe(Re(d=>!!(d.hideToggle||d.disabled||d.togglePosition)))).subscribe(()=>this._changeDetectorRef.markForCheck()),e.closed.pipe(Re(()=>e._containsFocus())).subscribe(()=>this._focusMonitor.focusVia(this._element,"program")),i&&(this.expandedHeight=i.expandedHeight,this.collapsedHeight=i.collapsedHeight)}expandedHeight;collapsedHeight;tabIndex=0;get disabled(){return this.panel.disabled}_toggle(){this.disabled||this.panel.toggle()}_isExpanded(){return this.panel.expanded}_getExpandedState(){return this.panel._getExpandedState()}_getPanelId(){return this.panel.id}_getTogglePosition(){return this.panel.togglePosition}_showToggle(){return!this.panel.hideToggle&&!this.panel.disabled}_getHeaderHeight(){let e=this._isExpanded();return e&&this.expandedHeight?this.expandedHeight:!e&&this.collapsedHeight?this.collapsedHeight:null}_keydown(e){switch(e.keyCode){case 32:case 13:Jt(e)||(e.preventDefault(),this._toggle());break;default:this.panel.accordion&&this.panel.accordion._handleHeaderKeydown(e);return}}focus(e,i){e?this._focusMonitor.focusVia(this._element,e,i):this._element.nativeElement.focus(i)}ngAfterViewInit(){this._focusMonitor.monitor(this._element).subscribe(e=>{e&&this.panel.accordion&&this.panel.accordion._handleHeaderFocus(this)})}ngOnDestroy(){this._parentChangeSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._element)}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["mat-expansion-panel-header"]],hostAttrs:["role","button",1,"mat-expansion-panel-header","mat-focus-indicator"],hostVars:13,hostBindings:function(i,t){i&1&&b("click",function(){return t._toggle()})("keydown",function(d){return t._keydown(d)}),i&2&&(F("id",t.panel._headerId)("tabindex",t.disabled?-1:t.tabIndex)("aria-controls",t._getPanelId())("aria-expanded",t._isExpanded())("aria-disabled",t.panel.disabled),qe("height",t._getHeaderHeight()),L("mat-expanded",t._isExpanded())("mat-expansion-toggle-indicator-after",t._getTogglePosition()==="after")("mat-expansion-toggle-indicator-before",t._getTogglePosition()==="before"))},inputs:{expandedHeight:"expandedHeight",collapsedHeight:"collapsedHeight",tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:A(e)]},ngContentSelectors:en,decls:5,vars:3,consts:[[1,"mat-content"],[1,"mat-expansion-indicator"],["xmlns","http://www.w3.org/2000/svg","viewBox","0 -960 960 960","aria-hidden","true","focusable","false"],["d","M480-345 240-585l56-56 184 184 184-184 56 56-240 240Z"]],template:function(i,t){i&1&&(le($i),Xe(0,"span",0),N(1),N(2,1),N(3,2),ft(),C(4,tn,3,0,"span",1)),i&2&&(L("mat-content-hide-toggle",!t._showToggle()),m(4),S(t._showToggle()?4:-1))},styles:[`.mat-expansion-panel-header{display:flex;flex-direction:row;align-items:center;padding:0 24px;border-radius:inherit;height:var(--mat-expansion-header-collapsed-state-height, 48px);font-family:var(--mat-expansion-header-text-font, var(--mat-sys-title-medium-font));font-size:var(--mat-expansion-header-text-size, var(--mat-sys-title-medium-size));font-weight:var(--mat-expansion-header-text-weight, var(--mat-sys-title-medium-weight));line-height:var(--mat-expansion-header-text-line-height, var(--mat-sys-title-medium-line-height));letter-spacing:var(--mat-expansion-header-text-tracking, var(--mat-sys-title-medium-tracking))}.mat-expansion-panel-animations-enabled .mat-expansion-panel-header{transition:height 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header::before{border-radius:inherit}.mat-expansion-panel-header.mat-expanded{height:var(--mat-expansion-header-expanded-state-height, 64px)}.mat-expansion-panel-header[aria-disabled=true]{color:var(--mat-expansion-header-disabled-state-text-color, color-mix(in srgb, var(--mat-sys-on-surface) 38%, transparent))}.mat-expansion-panel-header:not([aria-disabled=true]){cursor:pointer}.mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:not([aria-disabled=true]):hover{background:var(--mat-expansion-header-hover-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-hover-state-layer-opacity) * 100%), transparent))}@media(hover: none){.mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:not([aria-disabled=true]):hover{background:var(--mat-expansion-container-background-color, var(--mat-sys-surface))}}.mat-expansion-panel .mat-expansion-panel-header:not([aria-disabled=true]).cdk-keyboard-focused,.mat-expansion-panel .mat-expansion-panel-header:not([aria-disabled=true]).cdk-program-focused{background:var(--mat-expansion-header-focus-state-layer-color, color-mix(in srgb, var(--mat-sys-on-surface) calc(var(--mat-sys-focus-state-layer-opacity) * 100%), transparent))}.mat-expansion-panel-header._mat-animation-noopable{transition:none}.mat-expansion-panel-header:focus,.mat-expansion-panel-header:hover{outline:none}.mat-expansion-panel-header.mat-expanded:focus,.mat-expansion-panel-header.mat-expanded:hover{background:inherit}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before{flex-direction:row-reverse}.mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 16px 0 0}[dir=rtl] .mat-expansion-panel-header.mat-expansion-toggle-indicator-before .mat-expansion-indicator{margin:0 0 0 16px}.mat-content{display:flex;flex:1;flex-direction:row;overflow:hidden}.mat-content.mat-content-hide-toggle{margin-right:8px}[dir=rtl] .mat-content.mat-content-hide-toggle{margin-right:0;margin-left:8px}.mat-expansion-toggle-indicator-before .mat-content.mat-content-hide-toggle{margin-left:24px;margin-right:0}[dir=rtl] .mat-expansion-toggle-indicator-before .mat-content.mat-content-hide-toggle{margin-right:24px;margin-left:0}.mat-expansion-panel-header-title{color:var(--mat-expansion-header-text-color, var(--mat-sys-on-surface))}.mat-expansion-panel-header-title,.mat-expansion-panel-header-description{display:flex;flex-grow:1;flex-basis:0;margin-right:16px;align-items:center}[dir=rtl] .mat-expansion-panel-header-title,[dir=rtl] .mat-expansion-panel-header-description{margin-right:0;margin-left:16px}.mat-expansion-panel-header[aria-disabled=true] .mat-expansion-panel-header-title,.mat-expansion-panel-header[aria-disabled=true] .mat-expansion-panel-header-description{color:inherit}.mat-expansion-panel-header-description{flex-grow:2;color:var(--mat-expansion-header-description-color, var(--mat-sys-on-surface-variant))}.mat-expansion-panel-animations-enabled .mat-expansion-indicator{transition:transform 225ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-expansion-panel-header.mat-expanded .mat-expansion-indicator{transform:rotate(180deg)}.mat-expansion-indicator::after{border-style:solid;border-width:0 2px 2px 0;content:"";padding:3px;transform:rotate(45deg);vertical-align:middle;color:var(--mat-expansion-header-indicator-color, var(--mat-sys-on-surface-variant));display:var(--mat-expansion-legacy-header-indicator-display, none)}.mat-expansion-indicator svg{width:24px;height:24px;margin:0 -8px;vertical-align:middle;fill:var(--mat-expansion-header-indicator-color, var(--mat-sys-on-surface-variant));display:var(--mat-expansion-header-indicator-display, inline-block)}@media(forced-colors: active){.mat-expansion-panel-content{border-top:1px solid;border-top-left-radius:0;border-top-right-radius:0}}
|
|
3
3
|
`],encapsulation:2,changeDetection:0})}return n})(),ct=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["mat-panel-description"]],hostAttrs:[1,"mat-expansion-panel-header-description"]})}return n})(),mt=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275dir=O({type:n,selectors:[["mat-panel-title"]],hostAttrs:[1,"mat-expansion-panel-header-title"]})}return n})(),ht=(()=>{class n extends Mi{_keyManager;_ownHeaders=new Nt;_headers;hideToggle=!1;displayMode="default";togglePosition="after";ngAfterContentInit(){this._headers.changes.pipe(_t(this._headers)).subscribe(e=>{this._ownHeaders.reset(e.filter(i=>i.panel.accordion===this)),this._ownHeaders.notifyOnChanges()}),this._keyManager=new Yt(this._ownHeaders).withWrap().withHomeAndEnd()}_handleHeaderKeydown(e){this._keyManager.onKeydown(e)}_handleHeaderFocus(e){this._keyManager.updateActiveItem(e)}ngOnDestroy(){super.ngOnDestroy(),this._keyManager?.destroy(),this._ownHeaders.destroy()}static \u0275fac=(()=>{let e;return function(t){return(e||(e=Vt(n)))(t||n)}})();static \u0275dir=O({type:n,selectors:[["mat-accordion"]],contentQueries:function(i,t,o){if(i&1&&Ae(o,Oe,5),i&2){let d;I(d=R())&&(t._headers=d)}},hostAttrs:[1,"mat-accordion"],hostVars:2,hostBindings:function(i,t){i&2&&L("mat-accordion-multi",t.multi)},inputs:{hideToggle:[2,"hideToggle","hideToggle",M],displayMode:"displayMode",togglePosition:"togglePosition"},exportAs:["matAccordion"],features:[V([{provide:xt,useExisting:n}]),ze]})}return n})(),pt=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275mod=J({type:n});static \u0275inj=Z({imports:[Ti,ai,xe]})}return n})();var an=["switch"],on=["*"];function sn(n,f){n&1&&(a(0,"span",11),We(),a(1,"svg",13),g(2,"path",14),s(),a(3,"svg",15),g(4,"path",16),s()())}var rn=new D("mat-slide-toggle-default-options",{providedIn:"root",factory:()=>({disableToggleValue:!1,hideIcon:!1,disabledInteractive:!1})}),ut=class{source;checked;constructor(f,e){this.source=f,this.checked=e}},pe=(()=>{class n{_elementRef=c(K);_focusMonitor=c(Ze);_changeDetectorRef=c(U);defaults=c(rn);_onChange=e=>{};_onTouched=()=>{};_validatorOnChange=()=>{};_uniqueId;_checked=!1;_createChangeEvent(e){return new ut(this,e)}_labelId;get buttonId(){return`${this.id||this._uniqueId}-button`}_switchElement;focus(){this._switchElement.nativeElement.focus()}_noopAnimations=Ce();_focused=!1;name=null;id;labelPosition="after";ariaLabel=null;ariaLabelledby=null;ariaDescribedby;required=!1;color;disabled=!1;disableRipple=!1;tabIndex=0;get checked(){return this._checked}set checked(e){this._checked=e,this._changeDetectorRef.markForCheck()}hideIcon;disabledInteractive;change=new E;toggleChange=new E;get inputId(){return`${this.id||this._uniqueId}-input`}constructor(){c(we).load(Se);let e=c(new je("tabindex"),{optional:!0}),i=this.defaults;this.tabIndex=e==null?0:parseInt(e)||0,this.color=i.color||"accent",this.id=this._uniqueId=c(he).getId("mat-mdc-slide-toggle-"),this.hideIcon=i.hideIcon??!1,this.disabledInteractive=i.disabledInteractive??!1,this._labelId=this._uniqueId+"-label"}ngAfterContentInit(){this._focusMonitor.monitor(this._elementRef,!0).subscribe(e=>{e==="keyboard"||e==="program"?(this._focused=!0,this._changeDetectorRef.markForCheck()):e||Promise.resolve().then(()=>{this._focused=!1,this._onTouched(),this._changeDetectorRef.markForCheck()})})}ngOnChanges(e){e.required&&this._validatorOnChange()}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef)}writeValue(e){this.checked=!!e}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}validate(e){return this.required&&e.value!==!0?{required:!0}:null}registerOnValidatorChange(e){this._validatorOnChange=e}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck()}toggle(){this.checked=!this.checked,this._onChange(this.checked)}_emitChangeEvent(){this._onChange(this.checked),this.change.emit(this._createChangeEvent(this.checked))}_handleClick(){this.disabled||(this.toggleChange.emit(),this.defaults.disableToggleValue||(this.checked=!this.checked,this._onChange(this.checked),this.change.emit(new ut(this,this.checked))))}_getAriaLabelledBy(){return this.ariaLabelledby?this.ariaLabelledby:this.ariaLabel?null:this._labelId}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["mat-slide-toggle"]],viewQuery:function(i,t){if(i&1&&de(an,5),i&2){let o;I(o=R())&&(t._switchElement=o.first)}},hostAttrs:[1,"mat-mdc-slide-toggle"],hostVars:13,hostBindings:function(i,t){i&2&&(Wt("id",t.id),F("tabindex",null)("aria-label",null)("name",null)("aria-labelledby",null),ce(t.color?"mat-"+t.color:""),L("mat-mdc-slide-toggle-focused",t._focused)("mat-mdc-slide-toggle-checked",t.checked)("_mat-animation-noopable",t._noopAnimations))},inputs:{name:"name",id:"id",labelPosition:"labelPosition",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],ariaDescribedby:[0,"aria-describedby","ariaDescribedby"],required:[2,"required","required",M],color:"color",disabled:[2,"disabled","disabled",M],disableRipple:[2,"disableRipple","disableRipple",M],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:A(e)],checked:[2,"checked","checked",M],hideIcon:[2,"hideIcon","hideIcon",M],disabledInteractive:[2,"disabledInteractive","disabledInteractive",M]},outputs:{change:"change",toggleChange:"toggleChange"},exportAs:["matSlideToggle"],features:[V([{provide:$e,useExisting:Be(()=>n),multi:!0},{provide:si,useExisting:n,multi:!0}]),fe],ngContentSelectors:on,decls:14,vars:27,consts:[["switch",""],["mat-internal-form-field","",3,"labelPosition"],["role","switch","type","button",1,"mdc-switch",3,"click","tabIndex","disabled"],[1,"mat-mdc-slide-toggle-touch-target"],[1,"mdc-switch__track"],[1,"mdc-switch__handle-track"],[1,"mdc-switch__handle"],[1,"mdc-switch__shadow"],[1,"mdc-elevation-overlay"],[1,"mdc-switch__ripple"],["mat-ripple","",1,"mat-mdc-slide-toggle-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled","matRippleCentered"],[1,"mdc-switch__icons"],[1,"mdc-label",3,"click","for"],["viewBox","0 0 24 24","aria-hidden","true",1,"mdc-switch__icon","mdc-switch__icon--on"],["d","M19.69,5.23L8.96,15.96l-4.23-4.23L2.96,13.5l6,6L21.46,7L19.69,5.23z"],["viewBox","0 0 24 24","aria-hidden","true",1,"mdc-switch__icon","mdc-switch__icon--off"],["d","M20 13H4v-2h16v2z"]],template:function(i,t){if(i&1){let o=P();le(),a(0,"div",1)(1,"button",2,0),b("click",function(){return p(o),u(t._handleClick())}),g(3,"div",3)(4,"span",4),a(5,"span",5)(6,"span",6)(7,"span",7),g(8,"span",8),s(),a(9,"span",9),g(10,"span",10),s(),C(11,sn,5,0,"span",11),s()()(),a(12,"label",12),b("click",function(l){return p(o),u(l.stopPropagation())}),N(13),s()()}if(i&2){let o=k(2);h("labelPosition",t.labelPosition),m(),L("mdc-switch--selected",t.checked)("mdc-switch--unselected",!t.checked)("mdc-switch--checked",t.checked)("mdc-switch--disabled",t.disabled)("mat-mdc-slide-toggle-disabled-interactive",t.disabledInteractive),h("tabIndex",t.disabled&&!t.disabledInteractive?-1:t.tabIndex)("disabled",t.disabled&&!t.disabledInteractive),F("id",t.buttonId)("name",t.name)("aria-label",t.ariaLabel)("aria-labelledby",t._getAriaLabelledBy())("aria-describedby",t.ariaDescribedby)("aria-required",t.required||null)("aria-checked",t.checked)("aria-disabled",t.disabled&&t.disabledInteractive?"true":null),m(9),h("matRippleTrigger",o)("matRippleDisabled",t.disableRipple||t.disabled)("matRippleCentered",!0),m(),S(t.hideIcon?-1:11),m(),h("for",t.buttonId),F("id",t._labelId)}},dependencies:[Ve,pi],styles:[`.mdc-switch{align-items:center;background:none;border:none;cursor:pointer;display:inline-flex;flex-shrink:0;margin:0;outline:none;overflow:visible;padding:0;position:relative;width:var(--mat-slide-toggle-track-width, 52px)}.mdc-switch.mdc-switch--disabled{cursor:default;pointer-events:none}.mdc-switch.mat-mdc-slide-toggle-disabled-interactive{pointer-events:auto}.mdc-switch__track{overflow:hidden;position:relative;width:100%;height:var(--mat-slide-toggle-track-height, 32px);border-radius:var(--mat-slide-toggle-track-shape, var(--mat-sys-corner-full))}.mdc-switch--disabled.mdc-switch .mdc-switch__track{opacity:var(--mat-slide-toggle-disabled-track-opacity, 0.12)}.mdc-switch__track::before,.mdc-switch__track::after{border:1px solid rgba(0,0,0,0);border-radius:inherit;box-sizing:border-box;content:"";height:100%;left:0;position:absolute;width:100%;border-width:var(--mat-slide-toggle-track-outline-width, 2px);border-color:var(--mat-slide-toggle-track-outline-color, var(--mat-sys-outline))}.mdc-switch--selected .mdc-switch__track::before,.mdc-switch--selected .mdc-switch__track::after{border-width:var(--mat-slide-toggle-selected-track-outline-width, 2px);border-color:var(--mat-slide-toggle-selected-track-outline-color, transparent)}.mdc-switch--disabled .mdc-switch__track::before,.mdc-switch--disabled .mdc-switch__track::after{border-width:var(--mat-slide-toggle-disabled-unselected-track-outline-width, 2px);border-color:var(--mat-slide-toggle-disabled-unselected-track-outline-color, var(--mat-sys-on-surface))}@media(forced-colors: active){.mdc-switch__track{border-color:currentColor}}.mdc-switch__track::before{transition:transform 75ms 0ms cubic-bezier(0, 0, 0.2, 1);transform:translateX(0);background:var(--mat-slide-toggle-unselected-track-color, var(--mat-sys-surface-variant))}.mdc-switch--selected .mdc-switch__track::before{transition:transform 75ms 0ms cubic-bezier(0.4, 0, 0.6, 1);transform:translateX(100%)}[dir=rtl] .mdc-switch--selected .mdc-switch--selected .mdc-switch__track::before{transform:translateX(-100%)}.mdc-switch--selected .mdc-switch__track::before{opacity:var(--mat-slide-toggle-hidden-track-opacity, 0);transition:var(--mat-slide-toggle-hidden-track-transition, opacity 75ms)}.mdc-switch--unselected .mdc-switch__track::before{opacity:var(--mat-slide-toggle-visible-track-opacity, 1);transition:var(--mat-slide-toggle-visible-track-transition, opacity 75ms)}.mdc-switch:enabled:hover:not(:focus):not(:active) .mdc-switch__track::before{background:var(--mat-slide-toggle-unselected-hover-track-color, var(--mat-sys-surface-variant))}.mdc-switch:enabled:focus:not(:active) .mdc-switch__track::before{background:var(--mat-slide-toggle-unselected-focus-track-color, var(--mat-sys-surface-variant))}.mdc-switch:enabled:active .mdc-switch__track::before{background:var(--mat-slide-toggle-unselected-pressed-track-color, var(--mat-sys-surface-variant))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__track::before,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__track::before,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__track::before,.mdc-switch.mdc-switch--disabled .mdc-switch__track::before{background:var(--mat-slide-toggle-disabled-unselected-track-color, var(--mat-sys-surface-variant))}.mdc-switch__track::after{transform:translateX(-100%);background:var(--mat-slide-toggle-selected-track-color, var(--mat-sys-primary))}[dir=rtl] .mdc-switch__track::after{transform:translateX(100%)}.mdc-switch--selected .mdc-switch__track::after{transform:translateX(0)}.mdc-switch--selected .mdc-switch__track::after{opacity:var(--mat-slide-toggle-visible-track-opacity, 1);transition:var(--mat-slide-toggle-visible-track-transition, opacity 75ms)}.mdc-switch--unselected .mdc-switch__track::after{opacity:var(--mat-slide-toggle-hidden-track-opacity, 0);transition:var(--mat-slide-toggle-hidden-track-transition, opacity 75ms)}.mdc-switch:enabled:hover:not(:focus):not(:active) .mdc-switch__track::after{background:var(--mat-slide-toggle-selected-hover-track-color, var(--mat-sys-primary))}.mdc-switch:enabled:focus:not(:active) .mdc-switch__track::after{background:var(--mat-slide-toggle-selected-focus-track-color, var(--mat-sys-primary))}.mdc-switch:enabled:active .mdc-switch__track::after{background:var(--mat-slide-toggle-selected-pressed-track-color, var(--mat-sys-primary))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__track::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__track::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__track::after,.mdc-switch.mdc-switch--disabled .mdc-switch__track::after{background:var(--mat-slide-toggle-disabled-selected-track-color, var(--mat-sys-on-surface))}.mdc-switch__handle-track{height:100%;pointer-events:none;position:absolute;top:0;transition:transform 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1);left:0;right:auto;transform:translateX(0);width:calc(100% - var(--mat-slide-toggle-handle-width))}[dir=rtl] .mdc-switch__handle-track{left:auto;right:0}.mdc-switch--selected .mdc-switch__handle-track{transform:translateX(100%)}[dir=rtl] .mdc-switch--selected .mdc-switch__handle-track{transform:translateX(-100%)}.mdc-switch__handle{display:flex;pointer-events:auto;position:absolute;top:50%;transform:translateY(-50%);left:0;right:auto;transition:width 75ms cubic-bezier(0.4, 0, 0.2, 1),height 75ms cubic-bezier(0.4, 0, 0.2, 1),margin 75ms cubic-bezier(0.4, 0, 0.2, 1);width:var(--mat-slide-toggle-handle-width);height:var(--mat-slide-toggle-handle-height);border-radius:var(--mat-slide-toggle-handle-shape, var(--mat-sys-corner-full))}[dir=rtl] .mdc-switch__handle{left:auto;right:0}.mat-mdc-slide-toggle .mdc-switch--unselected .mdc-switch__handle{width:var(--mat-slide-toggle-unselected-handle-size, 16px);height:var(--mat-slide-toggle-unselected-handle-size, 16px);margin:var(--mat-slide-toggle-unselected-handle-horizontal-margin, 0 8px)}.mat-mdc-slide-toggle .mdc-switch--unselected .mdc-switch__handle:has(.mdc-switch__icons){margin:var(--mat-slide-toggle-unselected-with-icon-handle-horizontal-margin, 0 4px)}.mat-mdc-slide-toggle .mdc-switch--selected .mdc-switch__handle{width:var(--mat-slide-toggle-selected-handle-size, 24px);height:var(--mat-slide-toggle-selected-handle-size, 24px);margin:var(--mat-slide-toggle-selected-handle-horizontal-margin, 0 24px)}.mat-mdc-slide-toggle .mdc-switch--selected .mdc-switch__handle:has(.mdc-switch__icons){margin:var(--mat-slide-toggle-selected-with-icon-handle-horizontal-margin, 0 24px)}.mat-mdc-slide-toggle .mdc-switch__handle:has(.mdc-switch__icons){width:var(--mat-slide-toggle-with-icon-handle-size, 24px);height:var(--mat-slide-toggle-with-icon-handle-size, 24px)}.mat-mdc-slide-toggle .mdc-switch:active:not(.mdc-switch--disabled) .mdc-switch__handle{width:var(--mat-slide-toggle-pressed-handle-size, 28px);height:var(--mat-slide-toggle-pressed-handle-size, 28px)}.mat-mdc-slide-toggle .mdc-switch--selected:active:not(.mdc-switch--disabled) .mdc-switch__handle{margin:var(--mat-slide-toggle-selected-pressed-handle-horizontal-margin, 0 22px)}.mat-mdc-slide-toggle .mdc-switch--unselected:active:not(.mdc-switch--disabled) .mdc-switch__handle{margin:var(--mat-slide-toggle-unselected-pressed-handle-horizontal-margin, 0 2px)}.mdc-switch--disabled.mdc-switch--selected .mdc-switch__handle::after{opacity:var(--mat-slide-toggle-disabled-selected-handle-opacity, 1)}.mdc-switch--disabled.mdc-switch--unselected .mdc-switch__handle::after{opacity:var(--mat-slide-toggle-disabled-unselected-handle-opacity, 0.38)}.mdc-switch__handle::before,.mdc-switch__handle::after{border:1px solid rgba(0,0,0,0);border-radius:inherit;box-sizing:border-box;content:"";width:100%;height:100%;left:0;position:absolute;top:0;transition:background-color 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1),border-color 75ms 0ms cubic-bezier(0.4, 0, 0.2, 1);z-index:-1}@media(forced-colors: active){.mdc-switch__handle::before,.mdc-switch__handle::after{border-color:currentColor}}.mdc-switch--selected:enabled .mdc-switch__handle::after{background:var(--mat-slide-toggle-selected-handle-color, var(--mat-sys-on-primary))}.mdc-switch--selected:enabled:hover:not(:focus):not(:active) .mdc-switch__handle::after{background:var(--mat-slide-toggle-selected-hover-handle-color, var(--mat-sys-primary-container))}.mdc-switch--selected:enabled:focus:not(:active) .mdc-switch__handle::after{background:var(--mat-slide-toggle-selected-focus-handle-color, var(--mat-sys-primary-container))}.mdc-switch--selected:enabled:active .mdc-switch__handle::after{background:var(--mat-slide-toggle-selected-pressed-handle-color, var(--mat-sys-primary-container))}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:hover:not(:focus):not(:active) .mdc-switch__handle::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:focus:not(:active) .mdc-switch__handle::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled.mdc-switch--selected:active .mdc-switch__handle::after,.mdc-switch--selected.mdc-switch--disabled .mdc-switch__handle::after{background:var(--mat-slide-toggle-disabled-selected-handle-color, var(--mat-sys-surface))}.mdc-switch--unselected:enabled .mdc-switch__handle::after{background:var(--mat-slide-toggle-unselected-handle-color, var(--mat-sys-outline))}.mdc-switch--unselected:enabled:hover:not(:focus):not(:active) .mdc-switch__handle::after{background:var(--mat-slide-toggle-unselected-hover-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected:enabled:focus:not(:active) .mdc-switch__handle::after{background:var(--mat-slide-toggle-unselected-focus-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected:enabled:active .mdc-switch__handle::after{background:var(--mat-slide-toggle-unselected-pressed-handle-color, var(--mat-sys-on-surface-variant))}.mdc-switch--unselected.mdc-switch--disabled .mdc-switch__handle::after{background:var(--mat-slide-toggle-disabled-unselected-handle-color, var(--mat-sys-on-surface))}.mdc-switch__handle::before{background:var(--mat-slide-toggle-handle-surface-color)}.mdc-switch__shadow{border-radius:inherit;bottom:0;left:0;position:absolute;right:0;top:0}.mdc-switch:enabled .mdc-switch__shadow{box-shadow:var(--mat-slide-toggle-handle-elevation-shadow)}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:hover:not(:focus):not(:active) .mdc-switch__shadow,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:focus:not(:active) .mdc-switch__shadow,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:active .mdc-switch__shadow,.mdc-switch.mdc-switch--disabled .mdc-switch__shadow{box-shadow:var(--mat-slide-toggle-disabled-handle-elevation-shadow)}.mdc-switch__ripple{left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);z-index:-1;width:var(--mat-slide-toggle-state-layer-size, 40px);height:var(--mat-slide-toggle-state-layer-size, 40px)}.mdc-switch__ripple::after{content:"";opacity:0}.mdc-switch--disabled .mdc-switch__ripple::after{display:none}.mat-mdc-slide-toggle-disabled-interactive .mdc-switch__ripple::after{display:block}.mdc-switch:hover .mdc-switch__ripple::after{transition:75ms opacity cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:focus .mdc-switch__ripple::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:active .mdc-switch__ripple::after,.mat-mdc-slide-toggle-disabled-interactive.mdc-switch--disabled:enabled:hover:not(:focus) .mdc-switch__ripple::after,.mdc-switch--unselected:enabled:hover:not(:focus) .mdc-switch__ripple::after{background:var(--mat-slide-toggle-unselected-hover-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mat-slide-toggle-unselected-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mdc-switch--unselected:enabled:focus .mdc-switch__ripple::after{background:var(--mat-slide-toggle-unselected-focus-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mat-slide-toggle-unselected-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mdc-switch--unselected:enabled:active .mdc-switch__ripple::after{background:var(--mat-slide-toggle-unselected-pressed-state-layer-color, var(--mat-sys-on-surface));opacity:var(--mat-slide-toggle-unselected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));transition:opacity 75ms linear}.mdc-switch--selected:enabled:hover:not(:focus) .mdc-switch__ripple::after{background:var(--mat-slide-toggle-selected-hover-state-layer-color, var(--mat-sys-primary));opacity:var(--mat-slide-toggle-selected-hover-state-layer-opacity, var(--mat-sys-hover-state-layer-opacity))}.mdc-switch--selected:enabled:focus .mdc-switch__ripple::after{background:var(--mat-slide-toggle-selected-focus-state-layer-color, var(--mat-sys-primary));opacity:var(--mat-slide-toggle-selected-focus-state-layer-opacity, var(--mat-sys-focus-state-layer-opacity))}.mdc-switch--selected:enabled:active .mdc-switch__ripple::after{background:var(--mat-slide-toggle-selected-pressed-state-layer-color, var(--mat-sys-primary));opacity:var(--mat-slide-toggle-selected-pressed-state-layer-opacity, var(--mat-sys-pressed-state-layer-opacity));transition:opacity 75ms linear}.mdc-switch__icons{position:relative;height:100%;width:100%;z-index:1;transform:translateZ(0)}.mdc-switch--disabled.mdc-switch--unselected .mdc-switch__icons{opacity:var(--mat-slide-toggle-disabled-unselected-icon-opacity, 0.38)}.mdc-switch--disabled.mdc-switch--selected .mdc-switch__icons{opacity:var(--mat-slide-toggle-disabled-selected-icon-opacity, 0.38)}.mdc-switch__icon{bottom:0;left:0;margin:auto;position:absolute;right:0;top:0;opacity:0;transition:opacity 30ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-switch--unselected .mdc-switch__icon{width:var(--mat-slide-toggle-unselected-icon-size, 16px);height:var(--mat-slide-toggle-unselected-icon-size, 16px);fill:var(--mat-slide-toggle-unselected-icon-color, var(--mat-sys-surface-variant))}.mdc-switch--unselected.mdc-switch--disabled .mdc-switch__icon{fill:var(--mat-slide-toggle-disabled-unselected-icon-color, var(--mat-sys-surface-variant))}.mdc-switch--selected .mdc-switch__icon{width:var(--mat-slide-toggle-selected-icon-size, 16px);height:var(--mat-slide-toggle-selected-icon-size, 16px);fill:var(--mat-slide-toggle-selected-icon-color, var(--mat-sys-on-primary-container))}.mdc-switch--selected.mdc-switch--disabled .mdc-switch__icon{fill:var(--mat-slide-toggle-disabled-selected-icon-color, var(--mat-sys-on-surface))}.mdc-switch--selected .mdc-switch__icon--on,.mdc-switch--unselected .mdc-switch__icon--off{opacity:1;transition:opacity 45ms 30ms cubic-bezier(0, 0, 0.2, 1)}.mat-mdc-slide-toggle{-webkit-user-select:none;user-select:none;display:inline-block;-webkit-tap-highlight-color:rgba(0,0,0,0);outline:0}.mat-mdc-slide-toggle .mat-mdc-slide-toggle-ripple,.mat-mdc-slide-toggle .mdc-switch__ripple::after{top:0;left:0;right:0;bottom:0;position:absolute;border-radius:50%;pointer-events:none}.mat-mdc-slide-toggle .mat-mdc-slide-toggle-ripple:not(:empty),.mat-mdc-slide-toggle .mdc-switch__ripple::after:not(:empty){transform:translateZ(0)}.mat-mdc-slide-toggle.mat-mdc-slide-toggle-focused .mat-focus-indicator::before{content:""}.mat-mdc-slide-toggle .mat-internal-form-field{color:var(--mat-slide-toggle-label-text-color, var(--mat-sys-on-surface));font-family:var(--mat-slide-toggle-label-text-font, var(--mat-sys-body-medium-font));line-height:var(--mat-slide-toggle-label-text-line-height, var(--mat-sys-body-medium-line-height));font-size:var(--mat-slide-toggle-label-text-size, var(--mat-sys-body-medium-size));letter-spacing:var(--mat-slide-toggle-label-text-tracking, var(--mat-sys-body-medium-tracking));font-weight:var(--mat-slide-toggle-label-text-weight, var(--mat-sys-body-medium-weight))}.mat-mdc-slide-toggle .mat-ripple-element{opacity:.12}.mat-mdc-slide-toggle .mat-focus-indicator::before{border-radius:50%}.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle-track,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__icon,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle::before,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__handle::after,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__track::before,.mat-mdc-slide-toggle._mat-animation-noopable .mdc-switch__track::after{transition:none}.mat-mdc-slide-toggle .mdc-switch:enabled+.mdc-label{cursor:pointer}.mat-mdc-slide-toggle .mdc-switch--disabled+label{color:var(--mat-slide-toggle-disabled-label-text-color, var(--mat-sys-on-surface))}.mat-mdc-slide-toggle label:empty{display:none}.mat-mdc-slide-toggle-touch-target{position:absolute;top:50%;left:50%;height:var(--mat-slide-toggle-touch-target-size, 48px);width:100%;transform:translate(-50%, -50%);display:var(--mat-slide-toggle-touch-target-display, block)}[dir=rtl] .mat-mdc-slide-toggle-touch-target{left:auto;right:50%;transform:translate(50%, -50%)}
|
|
4
4
|
`],encapsulation:2,changeDetection:0})}return n})(),gt=(()=>{class n{static \u0275fac=function(i){return new(i||n)};static \u0275mod=J({type:n});static \u0275inj=Z({imports:[pe,xe]})}return n})();var ln=["notificationsForm"],dn=["statePanel"],cn=["soundPanel"];function mn(n,f){n&1&&(a(0,"mat-panel-description"),r(1," Filter Notifications sidenav items "),s())}function hn(n,f){n&1&&(a(0,"mat-panel-description"),r(1," Override server defined methods "),s())}var Ai=(()=>{class n{toast=c(z);settings=c(B);_responsive=c(Je);isPhonePortrait;notificationsForm=ee("notificationsForm");statePanel=ee("statePanel");soundPanel=ee("soundPanel");notificationConfig;notificationDisabledExpandPanel=!1;constructor(){this.isPhonePortrait=Ke(this._responsive.observe(Ye.HandsetPortrait)),this.notificationConfig=yt(this.settings.getNotificationConfig())}saveAllSettings(){this.settings.setNotificationConfig(yt(this.notificationConfig)),this.notificationsForm().form.markAsPristine(),this.toast.show("Configuration saved",1e3,!0,null,"message")}togglePanel(e){e.checked&&(this.notificationDisabledExpandPanel=!1,this.statePanel().close(),this.soundPanel().close())}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["settings-notifications"]],viewQuery:function(i,t){i&1&&be(t.notificationsForm,ln,5)(t.statePanel,dn,5)(t.soundPanel,cn,5),i&2&&ve(3)},decls:64,vars:17,consts:[["notificationsForm","ngForm"],["statePanel",""],["soundPanel",""],["id","notificationSetting",3,"ngSubmit"],["name","disableNotifications",3,"ngModelChange","ngModel"],["name","disableNotifications",3,"ngModelChange","change","ngModel"],[1,"notification-accordion"],[3,"disabled"],["name","showNormalState",3,"ngModelChange","ngModel"],["name","showNominalState",3,"ngModelChange","ngModel"],["name","muteAlert",3,"ngModelChange","ngModel","disabled"],["name","muteWarn",3,"ngModelChange","ngModel","disabled"],["name","muteAlarm",3,"ngModelChange","ngModel","disabled"],["name","muteEmergency",3,"ngModelChange","ngModel","disabled"],[1,"formActionFooter"],[1,"formActionDivider"],["mat-flat-button","","type","submit",1,"formActionButton",3,"disabled"]],template:function(i,t){if(i&1){let o=P();a(0,"form",3,0),b("ngSubmit",function(){return p(o),u(t.saveAllSettings())}),a(2,"p"),r(3,"Configure audio and visual notification settings and stay informed of critical events."),s(),a(4,"mat-slide-toggle",4),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.sound.disableSound,l)||(t.notificationConfig.sound.disableSound=l),u(l)}),r(5," Disable audio "),s(),g(6,"br")(7,"br"),a(8,"mat-slide-toggle",5),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.disableNotifications,l)||(t.notificationConfig.disableNotifications=l),u(l)}),b("change",function(l){return p(o),u(t.togglePanel(l))}),r(9," Disable Notifications "),s(),g(10,"br")(11,"br"),a(12,"div",6)(13,"mat-accordion")(14,"mat-expansion-panel",7,1)(16,"mat-expansion-panel-header")(17,"mat-panel-title"),r(18," States "),s(),C(19,mn,2,0,"mat-panel-description"),s(),a(20,"mat-checkbox",8),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.devices.showNormalState,l)||(t.notificationConfig.devices.showNormalState=l),u(l)}),r(21," Show "),a(22,"b"),r(23,"Normal"),s(),r(24," state "),s(),g(25,"br"),a(26,"mat-checkbox",9),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.devices.showNominalState,l)||(t.notificationConfig.devices.showNominalState=l),u(l)}),r(27," Show "),a(28,"b"),r(29,"Nominal"),s(),r(30," state "),s()(),a(31,"mat-expansion-panel",7,2)(33,"mat-expansion-panel-header")(34,"mat-panel-title"),r(35," Audio "),s(),C(36,hn,2,0,"mat-panel-description"),s(),a(37,"mat-checkbox",10),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.sound.muteAlert,l)||(t.notificationConfig.sound.muteAlert=l),u(l)}),r(38," Mute "),a(39,"b"),r(40,"all Alert"),s(),r(41," state "),s(),g(42,"br"),a(43,"mat-checkbox",11),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.sound.muteWarn,l)||(t.notificationConfig.sound.muteWarn=l),u(l)}),r(44," Mute "),a(45,"b"),r(46,"all Warn"),s(),r(47," state "),s(),g(48,"br"),a(49,"mat-checkbox",12),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.sound.muteAlarm,l)||(t.notificationConfig.sound.muteAlarm=l),u(l)}),r(50," Mute "),a(51,"b"),r(52,"all Alarm"),s(),r(53," state "),s(),g(54,"br"),a(55,"mat-checkbox",13),w("ngModelChange",function(l){return p(o),y(t.notificationConfig.sound.muteEmergency,l)||(t.notificationConfig.sound.muteEmergency=l),u(l)}),r(56," Mute "),a(57,"b"),r(58,"all Emergency"),s(),r(59," state "),s()()()(),a(60,"div",14),g(61,"mat-divider",15),a(62,"button",16),r(63,"Save"),s()()()}if(i&2){let o=k(1);m(4),v("ngModel",t.notificationConfig.sound.disableSound),m(4),v("ngModel",t.notificationConfig.disableNotifications),m(6),h("disabled",t.notificationConfig.disableNotifications),m(5),S(t.isPhonePortrait().matches?-1:19),m(),v("ngModel",t.notificationConfig.devices.showNormalState),m(6),v("ngModel",t.notificationConfig.devices.showNominalState),m(5),h("disabled",t.notificationConfig.disableNotifications),m(5),S(t.isPhonePortrait().matches?-1:36),m(),v("ngModel",t.notificationConfig.sound.muteAlert),h("disabled",t.notificationConfig.sound.disableSound),m(6),v("ngModel",t.notificationConfig.sound.muteWarn),h("disabled",t.notificationConfig.sound.disableSound),m(6),v("ngModel",t.notificationConfig.sound.muteAlarm),h("disabled",t.notificationConfig.sound.disableSound),m(6),v("ngModel",t.notificationConfig.sound.muteEmergency),h("disabled",t.notificationConfig.sound.disableSound),m(7),h("disabled",!o.form.dirty)}},dependencies:[j,q,H,X,ie,te,st,gt,pe,pt,ht,Ne,Oe,mt,ct,se,W],styles:[".notification-accordion[_ngcontent-%COMP%]{margin-left:25px}"]})}return n})();Ct.register(...yi);var Pi=Ct;var pn=["activityGraph"],Mt=()=>({standalone:!1}),un=()=>({standalone:!0}),Vi=(()=>{class n{dialog=c(oi);appSettingsService=c(B);app=c(lt);toast=c(z);DataService=c(rt);signalKConnectionService=c(Kt);deltaService=c(ui);connectionStateMachine=c(jt);auth=c(Ge);destroyRef=c(Pt);canvasService=c(vi);activityGraph=ee("activityGraph");connectionConfig;isConnecting=!1;authToken;endpointServiceStatus;streamStatus;_chart=null;textColor;ngOnInit(){this.connectionConfig=this.appSettingsService.getConnectionConfig(),this.auth.authToken$.pipe(ye(this.destroyRef)).subscribe(e=>{e?this.authToken=e:this.authToken=null}),this.signalKConnectionService.getServiceEndpointStatusAsO().pipe(ye(this.destroyRef)).subscribe(e=>{this.endpointServiceStatus=e}),this.deltaService.getDataStreamStatusAsO().pipe(ye(this.destroyRef)).subscribe(e=>{this.streamStatus=e})}ngAfterViewInit(){this.textColor=window.getComputedStyle(this.activityGraph().nativeElement).color,this._chart?.destroy(),this.startChart(),this.DataService.getSignalkDeltaUpdateStatistics().pipe(ye(this.destroyRef)).subscribe(e=>{this._chart.data.datasets[0].data.push({x:e.timestamp,y:e.value}),this._chart.data.datasets[0].data.length>10&&this._chart.data.datasets[0].data.shift(),this._chart?.update("none")})}openUserCredentialModal(e){this.dialog.open(Ci,{data:{user:this.connectionConfig.loginName,password:this.connectionConfig.loginPassword,error:e}}).afterClosed().pipe(ye(this.destroyRef)).subscribe(t=>{t&&(this.connectionConfig.loginName=t.user,this.connectionConfig.loginPassword=t.password,this.connectToServer())})}connectToServer(){return Le(this,null,function*(){if(this.connectionConfig.useSharedConfig&&(!this.connectionConfig.loginName||!this.connectionConfig.loginPassword)){this.openUserCredentialModal("Credentials required");return}this.isConnecting=!0;try{console.log("[Settings-SignalK] Validating Signal K server before connecting..."),yield this.signalKConnectionService.validateSignalKUrl(this.connectionConfig.signalKUrl),console.log("[Settings-SignalK] Validation successful - proceeding with connection"),this.appSettingsService.setConnectionConfig(this.connectionConfig),this.connectionStateMachine.shutdown("Configuration changed - restarting app"),this.authToken&&!this.connectionConfig.useSharedConfig&&!this.authToken.isDeviceAccessToken&&this.auth.deleteToken(),window.__KIP_TEST__||location.reload()}catch(e){this.isConnecting=!1;let i=e?.message||"Unknown validation error";console.error("[Settings-SignalK] Server validation failed:",i),this.toast.show(`${i}`,0,!1,null,"error")}})}startChart(){this._chart=new Pi(this.activityGraph().nativeElement.getContext("2d"),{type:"line",data:{datasets:[{data:[],fill:!0,borderColor:this.textColor}]},options:{maintainAspectRatio:!1,animation:!1,parsing:!1,scales:{x:{type:"time",display:!0,time:{unit:"minute",minUnit:"second",round:"second",displayFormats:{hour:"k:mm''",minute:"mm''",second:'mm ss"',millisecond:"SSS"}},position:"bottom",ticks:{display:!1},grid:{display:!0}},y:{beginAtZero:!0,type:"linear",position:"right",title:{text:"Delta / Sec",display:!0}}},plugins:{legend:{display:!1,labels:{color:this.textColor}}}}})}useSharedConfigToggleClick(e){if(e.checked){let i=this.signalKConnectionService.serverVersion$.getValue();if(!Gt(i,"1.46.2",">=")){this.toast.show("Configuration sharing requires Signal K version 1.46.2 or better",0,!1,null,"warn"),this.connectionConfig.useSharedConfig=!1;return}this.openUserCredentialModal(null)}}ngOnDestroy(){this._chart?.destroy();let e=this.activityGraph?.()?.nativeElement;this.canvasService.releaseCanvas(e,{clear:!0,removeFromDom:!0})}static \u0275fac=function(i){return new(i||n)};static \u0275cmp=x({type:n,selectors:[["settings-signalk"]],viewQuery:function(i,t){i&1&&be(t.activityGraph,pn,5),i&2&&ve()},decls:40,vars:22,consts:[["connectionForm","ngForm"],["useSharedConfigToggle",""],["activityGraph",""],["name","connectionForm",3,"ngSubmit"],[1,"connect-table"],[1,"url-cell"],[1,"connectUrlInput"],["type","url","matInput","","placeholder","Ex. http://192.168.0.1:3000","name","signalKURL","required","","pattern","https?://.+",3,"ngModelChange","ngModel","ngModelOptions"],[1,"connect-cell"],["mat-flat-button","","type","submit",1,"connect-btn",3,"disabled"],["colspan","2"],["name","useSharedConfigToggle","matTooltip","Activating authentication enables Signal K's user storage feature to save KIP configuration on the server. When authentication is not activated, KIP stores it's configuration locally in the Browser.",3,"ngModelChange","change","ngModel","ngModelOptions","disabled"],["mat-flat-button","","type","button","matTooltip","Configure Signal K user authentication credentials. The user must be a valid pre existing Signal K server user. It is strongly recommended not to use the default Signal K Admin user.",1,"credentials-btn",3,"click","disabled"],["name","signalKSubscribeAll",3,"ngModelChange","ngModel","ngModelOptions"],["name","isProxyEnabled",3,"ngModelChange","ngModel","ngModelOptions"],[1,"activity-container"],[1,"activity-graph-container"],[1,"activity-graph"],[1,"info-container"]],template:function(i,t){if(i&1){let o=P();a(0,"form",3,0),b("ngSubmit",function(){return p(o),u(t.connectToServer())}),g(2,"br"),a(3,"table",4)(4,"tr",4)(5,"td",5)(6,"mat-form-field",6)(7,"mat-label"),r(8,"Signal K URL"),s(),a(9,"input",7),w("ngModelChange",function(l){return p(o),y(t.connectionConfig.signalKUrl,l)||(t.connectionConfig.signalKUrl=l),u(l)}),s(),a(10,"mat-error"),r(11,' Valid URL is required. Ex. "https://demo.signalK.org" or "http://my.server.com:3000" '),s()()(),a(12,"td",8)(13,"button",9),r(14),s()()(),a(15,"tr",4)(16,"td",10)(17,"mat-slide-toggle",11,1),w("ngModelChange",function(l){return p(o),y(t.connectionConfig.useSharedConfig,l)||(t.connectionConfig.useSharedConfig=l),u(l)}),b("change",function(l){return p(o),u(t.useSharedConfigToggleClick(l))}),r(19," Login to server "),s(),a(20,"button",12),b("click",function(){return p(o),u(t.openUserCredentialModal(null))}),r(21," Set Credential "),s(),g(22,"br"),a(23,"mat-checkbox",13),w("ngModelChange",function(l){return p(o),y(t.connectionConfig.signalKSubscribeAll,l)||(t.connectionConfig.signalKSubscribeAll=l),u(l)}),r(24,"Subscribe to remote sources messages such as AIS and DSC targets. "),a(25,"i"),r(26,"Warning: this maybe generate heavy traffic."),s()()()(),a(27,"tr",4)(28,"td",10)(29,"mat-checkbox",14),w("ngModelChange",function(l){return p(o),y(t.connectionConfig.proxyEnabled,l)||(t.connectionConfig.proxyEnabled=l),u(l)}),r(30,"Signal K server is behind a Proxy"),s()()()()(),a(31,"div",15)(32,"div",16),g(33,"canvas",17,2),s(),a(35,"div",18)(36,"pre"),r(37),g(38,"br"),r(39),s()()()}if(i&2){let o=k(1);m(9),v("ngModel",t.connectionConfig.signalKUrl),h("ngModelOptions",me(18,Mt)),m(4),h("disabled",!o.form.valid||t.isConnecting),m(),zt(" ",t.isConnecting?"Validating...":"Connect"," "),m(3),v("ngModel",t.connectionConfig.useSharedConfig),h("ngModelOptions",me(19,un))("disabled",!t.connectionConfig.signalKUrl),m(3),h("disabled",!t.connectionConfig.useSharedConfig),m(3),v("ngModel",t.connectionConfig.signalKSubscribeAll),h("ngModelOptions",me(20,Mt)),m(6),v("ngModel",t.connectionConfig.proxyEnabled),h("ngModelOptions",me(21,Mt)),m(8),vt("KIP: ",t.app.appVersion(),`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as B}from"./chunk-
|
|
1
|
+
import{a as B}from"./chunk-JP7ZAJ6C.js";import{b as I,i as q}from"./chunk-3BGR52TW.js";import"./chunk-2MWBAYPJ.js";import"./chunk-5DLSQ773.js";import"./chunk-2KMYPGX4.js";import"./chunk-VH4ZIU4T.js";import"./chunk-IWK4FHBL.js";import"./chunk-PSF2OKKT.js";import"./chunk-HJQQWPGC.js";import"./chunk-KKJXPB75.js";import{m as N}from"./chunk-XEJJOWK6.js";import"./chunk-PESXPDBT.js";import{$d as L,Ab as b,Bb as P,Cc as u,Ce as V,De as Z,Ea as x,Ga as r,Gb as w,Ha as l,Hb as s,Ib as c,Ic as D,Jb as h,Kd as X,Qb as y,Sb as O,Ub as g,Ya as d,_c as T,ac as z,bc as E,dc as m,ec as R,hd as A,jb as W,pe as F,qa as a,qd as S,qe as U,va as v,wa as C,wc as k}from"./chunk-TGGJAGV7.js";var G=["panel"],Q=(i,f)=>[i,f];function j(i,f){if(i&1&&h(0,"div",7),i&2){let t=g();m("transform",t.ghostTransform())}}function H(i,f){if(i&1){let t=y();s(0,"div",8),O("pointerdown",function(e){v(t);let o=g();return C(o.startResize(e))}),s(1,"button",9),O("pointerdown",function(e){v(t);let o=g();return C(o.startResize(e))}),h(2,"mat-icon",10),c()()}}var ct=(()=>{class i{panelEl=D.required("panel");_settings=a(N);_dashboard=a(I);breakpointObserver=a(X);ngZone=a(x);side=r(this._settings.getSplitShellSide());panelRatio=r(this._settings.getSplitShellWidth());originalPanelRatio=null;panelWidth=r(0);panelCollapsed=u(()=>!!this._dashboard.dashboards()[this._dashboard.activeDashboard()]?.collapseSplitShell);fskShellSwipeDisabled=S(this._settings.getSplitShellSwipeDisabledAsO());handset$=this.breakpointObserver.observe(L.HandsetPortrait);handset=S(this.handset$,{initialValue:{matches:!1,breakpoints:{}}});freeboardWidgetStub={uuid:"persistent-freeboard-shell",type:"widget-freeboardsk",config:{}};chartplotterModeInPortrait=u(()=>this.handset().matches&&!this.panelCollapsed());canResize=u(()=>!this._dashboard.isDashboardStatic()&&!this.panelCollapsed());resizing=!1;startX=0;startW=0;boundMove=t=>this.onMove(t);boundUp=()=>this.onUp();static MIN_DELTA_PX=1;ghostActive=r(!1);ghostTransform=r("");ghostWidth=0;recomputeWidth=()=>{let t=this.panelEl()?.nativeElement.parentElement;if(!t)return;let n=t.clientWidth;this.panelWidth.set(Math.round(n*this.panelRatio()))};constructor(){window.addEventListener("resize",this.recomputeWidth,{passive:!0}),queueMicrotask(this.recomputeWidth),l(()=>{this.chartplotterModeInPortrait(),this.panelRatio(),this.recomputeWidth(),setTimeout(()=>window.dispatchEvent(new Event("resize")),0)}),l(()=>{let t=this._dashboard.isDashboardStatic();t||this.originalPanelRatio===null&&(this.originalPanelRatio=this.panelRatio()),t&&this.originalPanelRatio}),l(()=>{if(this._dashboard.layoutEditSaved(),this.originalPanelRatio!==null){let t=this.panelRatio();this._settings.setSplitShellWidth(t),this.originalPanelRatio=null}}),l(()=>{if(this._dashboard.layoutEditCanceled(),this.originalPanelRatio!==null){let t=this.originalPanelRatio;this.panelRatio.set(t),queueMicrotask(()=>this.recomputeWidth()),this.originalPanelRatio=null}})}startResize(t){this.canResize()&&(this.resizing=!0,this.startX=t.clientX,this.startW=this.panelWidth(),this.ghostWidth=this.startW,this.ghostActive.set(!0),this.updateGhostTransform(this.startW),t.target.setPointerCapture(t.pointerId),this.ngZone.runOutsideAngular(()=>{window.addEventListener("pointermove",this.boundMove,{passive:!0}),window.addEventListener("pointerup",this.boundUp,{passive:!0})}))}onMove(t){if(!this.resizing)return;let n=this.side()==="left"?t.clientX-this.startX:this.startX-t.clientX,o=this.panelEl()?.nativeElement.parentElement?.clientWidth??1,p=this.startW+n,_=o*.1,$=o*.9,M=Math.min($,Math.max(_,p));Math.abs(M-this.ghostWidth)<i.MIN_DELTA_PX||(this.ghostWidth=M,this.ngZone.runOutsideAngular(()=>this.updateGhostTransform(M)))}onUp(){if(!this.resizing)return;this.resizing=!1,window.removeEventListener("pointermove",this.boundMove),window.removeEventListener("pointerup",this.boundUp);let t=this.ghostWidth;this.ghostActive.set(!1);let n=this.panelEl();n&&!this.panelCollapsed()&&(n.nativeElement.style.width=t+"px"),this.ngZone.run(()=>{this.panelWidth.set(t);let o=this.panelEl()?.nativeElement.parentElement?.clientWidth??t,p=o?t/o:.3,_=this.panelRatio();Math.abs(p-_)>5e-4&&this.panelRatio.set(p)})}updateGhostTransform(t){this.side()==="left"?this.ghostTransform.set(`translateX(${t}px)`):this.ghostTransform.set(`translateX(-${t}px)`)}ngOnDestroy(){window.removeEventListener("resize",this.recomputeWidth),this.resizing&&(window.removeEventListener("pointermove",this.boundMove),window.removeEventListener("pointerup",this.boundUp))}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=W({type:i,selectors:[["split-shell"]],viewQuery:function(n,e){n&1&&z(e.panelEl,G,5),n&2&&E()},decls:8,vars:18,consts:[["panel",""],[1,"split-root",3,"ngClass"],[1,"resize-ghost",3,"transform"],[1,"fsk-shell"],["role","separator","aria-label","Resize Freeboard chartplotter panel","aria-orientation","vertical",1,"drag-handle"],[1,"fsk-iframe",3,"type","id","swipeDisabled","disableWidgetShell"],[1,"dash-container"],[1,"resize-ghost"],["role","separator","aria-label","Resize Freeboard chartplotter panel","aria-orientation","vertical",1,"drag-handle",3,"pointerdown"],["mat-mini-fab","","tabindex","-1","aria-hidden","true",1,"drag-fab",3,"pointerdown"],["fontIcon","drag_indicator"]],template:function(n,e){n&1&&(s(0,"div",1),b(1,j,1,2,"div",2),s(2,"div",3,0),b(4,H,3,0,"div",4),h(5,"widget-freeboardsk",5),c(),s(6,"div",6),h(7,"dashboard"),c()()),n&2&&(m("--panel-ratio",e.panelRatio()),w("ngClass",k(15,Q,e.side()==="left"?"side-left":"side-right",e.chartplotterModeInPortrait()?"portrait-column":"")),d(),P(e.ghostActive()?1:-1),d(),m("width",e.chartplotterModeInPortrait()?null:e.panelWidth(),"px"),R("collapsed",e.panelCollapsed())("drag-disabled",!e.canResize()),d(2),P(e.canResize()?4:-1),d(),w("type",e.freeboardWidgetStub.type)("id",e.freeboardWidgetStub.uuid)("swipeDisabled",e.fskShellSwipeDisabled())("disableWidgetShell",!0))},dependencies:[A,T,q,B,U,F,Z,V],styles:[".split-root[_ngcontent-%COMP%]{position:relative;width:100%;height:100%;display:flex;overflow:hidden}.split-root.side-left[_ngcontent-%COMP%]{flex-direction:row}.split-root.side-right[_ngcontent-%COMP%]{flex-direction:row-reverse}.split-root.portrait-column[_ngcontent-%COMP%]{flex-direction:column}.split-root.portrait-column[_ngcontent-%COMP%] .fsk-shell[_ngcontent-%COMP%], .split-root.portrait-column[_ngcontent-%COMP%] .dash-container[_ngcontent-%COMP%]{width:100%!important;min-height:0}.split-root.portrait-column[_ngcontent-%COMP%] .fsk-shell[_ngcontent-%COMP%]{flex:0 0 calc(var(--panel-ratio, .3) * 100%)}.split-root.portrait-column[_ngcontent-%COMP%] .dash-container[_ngcontent-%COMP%]{flex:1 1 auto;min-height:0;overflow:hidden}.split-root.side-left.portrait-column[_ngcontent-%COMP%] .dash-container[_ngcontent-%COMP%]{order:2}.split-root.side-left.portrait-column[_ngcontent-%COMP%] .fsk-shell[_ngcontent-%COMP%]{order:1}.split-root.side-right.portrait-column[_ngcontent-%COMP%] .fsk-shell[_ngcontent-%COMP%]{order:2}.split-root.side-right.portrait-column[_ngcontent-%COMP%] .dash-container[_ngcontent-%COMP%]{order:1}.split-root.portrait-column[_ngcontent-%COMP%] .fsk-shell.collapsed[_ngcontent-%COMP%]{flex:0 0 0!important}.split-root.portrait-column[_ngcontent-%COMP%] .drag-handle[_ngcontent-%COMP%], .split-root.portrait-column[_ngcontent-%COMP%] .resize-ghost[_ngcontent-%COMP%]{display:none}.fsk-shell[_ngcontent-%COMP%]{position:relative;height:100%;display:flex;flex-direction:column;background:var(--mat-sys-surface-container, #111);transition:width .2s ease}.fsk-shell.collapsed[_ngcontent-%COMP%]{width:1px!important;visibility:hidden;opacity:0;pointer-events:none}.fsk-iframe[_ngcontent-%COMP%]{flex:1 1 auto;min-width:0}.dash-container[_ngcontent-%COMP%]{flex:1 1 auto;min-width:0;height:100%}.drag-handle[_ngcontent-%COMP%]{position:absolute;top:0;bottom:0;width:3px;cursor:col-resize;background:var(--mat-sys-inverse-primary);z-index:5}.drag-handle[_ngcontent-%COMP%] .drag-fab[_ngcontent-%COMP%]{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:28px;height:28px;min-width:28px;cursor:col-resize;pointer-events:auto}.drag-handle[_ngcontent-%COMP%] .drag-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:20px;width:20px;height:20px;line-height:20px}.side-left[_ngcontent-%COMP%] .drag-handle[_ngcontent-%COMP%]{right:-2px}.side-right[_ngcontent-%COMP%] .drag-handle[_ngcontent-%COMP%]{left:-2px}.drag-handle[_ngcontent-%COMP%]:hover{background:var(--mat-sys-error-container)}.side-left[_ngcontent-%COMP%] .collapse-toggle[_ngcontent-%COMP%]{left:.25rem}.side-right[_ngcontent-%COMP%] .collapse-toggle[_ngcontent-%COMP%]{right:.25rem}.fsk-shell.drag-disabled[_ngcontent-%COMP%] .drag-handle[_ngcontent-%COMP%]{cursor:not-allowed;opacity:.4}.resize-ghost[_ngcontent-%COMP%]{position:absolute;top:0;bottom:0;width:2px;background:var(--mat-sys-error-container);opacity:.9;pointer-events:none;z-index:30;will-change:transform;transition:none}.side-left[_ngcontent-%COMP%] .resize-ghost[_ngcontent-%COMP%]{left:0}.side-right[_ngcontent-%COMP%] .resize-ghost[_ngcontent-%COMP%]{right:0}"]})}return i})();export{ct as SplitShellComponent};
|