@mxtommy/kip 3.9.0-beta.2 → 3.9.0-beta.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mxtommy/kip",
3
- "version": "3.9.0-beta.2",
3
+ "version": "3.9.0-beta.3",
4
4
  "description": "An advanced and versatile marine instrumentation package to display Signal K data.",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -1,4 +1,4 @@
1
- import{a as ai,b as ro,c as lo,d as so,e as co}from"./chunk-PKNLASTF.js";import{a as St}from"./chunk-VYUMZVH2.js";import{a as ao,b as oo,c as no,d as ii}from"./chunk-CBUY7NMR.js";import{a as Se,b as $e}from"./chunk-JY3WVS7C.js";import{a as Za,b as Xa,c as Ka,d as wt,e as Ja,f as Z,g as $a,h as eo,k as to,l as io,m as It,n as me,o as Je}from"./chunk-ZBCOJLI4.js";import{d as ca,g as da,l as pa,m as ee,n as Ce}from"./chunk-TXPLRBW5.js";import{a as Fa,b as La,c as Ba,d as qe,e as ze,g as Va,h as je,i as Ye,j as He,k as Ct,l as xe}from"./chunk-3LEMFOCV.js";import{a as bt}from"./chunk-FBFTGVZ6.js";import{a as Ha,b as ti}from"./chunk-2YVW3TBK.js";import{$ as we,A as Wa,B as Ua,C as de,D as Qa,E as Jt,F as Ze,G as Me,H,I as qa,J as za,K as Xe,L as $t,M as yt,N as L,P as xt,Q as ae,R as B,T as V,U as ei,V as ja,W as Mt,Y as Ya,_ as R,a as rt,ca as oe,da as Ke,e as na,f as la,h as sa,i as Ut,j as bi,k as Qt,p as ma,q as Kt,r as te,t as Y,w as F,x as ie,y as Ra,z as Na}from"./chunk-TA4GACKT.js";import{$b as b,$c as K,$d as ga,$e as Da,A as ct,Aa as w,Ab as Be,Ac as k,Ad as ia,Ae as Ca,Bc as U,Be as ya,Cb as Te,Cc as ht,Ce as Zt,Da as Fe,Db as Qi,De as se,Ec as Zi,Ed as aa,Ee as Xt,F as Oi,Fa as Le,Fb as le,Fc as Xi,Fe as Qe,Gb as ut,Gc as Ki,Hb as qi,He as xa,I as Ai,Ie as ce,Ja as D,K as Pe,Kc as Ee,Kd as oa,Ke as Ma,L as Oe,Mc as Re,Na as ot,Nc as Et,O as Fi,Oa as pt,Oe as wa,P as Bt,Pd as Ue,Pe as Sa,Qa as pe,Qc as Ne,Qd as ra,R as dt,Rb as q,Rc as We,Sb as u,Tb as A,U as Li,Ub as I,Ud as _i,Vb as Rt,Vd as ua,W as Bi,Wb as y,Wd as qt,We as ka,Xb as x,Xc as Ji,Xe as Ta,Yb as p,Yc as ft,Yd as Aa,Zb as n,Ze as Ea,_b as o,_c as $i,_e as Ci,a as re,ac as hi,ad as h,b as he,bc as fi,be as zt,cf as Ia,dc as zi,de as ha,df as Ga,ec as ji,ed as nt,ee as jt,ef as Pa,f as N,fa as mt,fc as Yi,fe as fa,g as lt,ga as Vt,gc as P,ge as ba,hc as Hi,hf as Oa,ia as Vi,ic as _,id as O,j as pi,kc as f,lb as c,lc as ve,le as Dt,m as st,mc as X,me as _t,na as Tt,nb as Ni,nc as ue,ne as _a,o as kt,oa as fe,oc as Ve,pa as be,pb as gi,pc as z,pe as vi,qc as j,qe as Yt,ra as J,sb as Wi,se as Ht,t as ui,ta as m,te as $,uc as Ae,vc as Nt,vd as ea,ve as De,wb as v,wc as W,wd as ta,we as ye,xa as Ri,xb as _e,xc as At,xe as vt,y as Lt,yb as Q,yc as gt,za as M,zb as Ui,zc as r,zd as Wt,ze as va}from"./chunk-35L7BBBD.js";var mo=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],Ie=(()=>{if(typeof document>"u")return!1;let a=mo[0],s={};for(let e of mo)if(e?.[1]in document){for(let[t,l]of e.entries())s[a[t]]=l;return s}return!1})(),po={change:Ie.fullscreenchange,error:Ie.fullscreenerror},ne={request(a=document.documentElement,s){return new Promise((e,i)=>{let t=()=>{ne.off("change",t),e()};ne.on("change",t);let l=a[Ie.requestFullscreen](s);l instanceof Promise&&l.then(t).catch(i)})},exit(){return new Promise((a,s)=>{if(!ne.isFullscreen){a();return}let e=()=>{ne.off("change",e),a()};ne.on("change",e);let i=document[Ie.exitFullscreen]();i instanceof Promise&&i.then(e).catch(s)})},toggle(a,s){return ne.isFullscreen?ne.exit():ne.request(a,s)},onchange(a){ne.on("change",a)},onerror(a){ne.on("error",a)},on(a,s){let e=po[a];e&&document.addEventListener(e,s,!1)},off(a,s){let e=po[a];e&&document.removeEventListener(e,s,!1)},raw:Ie};Object.defineProperties(ne,{isFullscreen:{get:()=>!!document[Ie.fullscreenElement]},element:{enumerable:!0,get:()=>document[Ie.fullscreenElement]??void 0},isEnabled:{enumerable:!0,get:()=>!!document[Ie.fullscreenEnabled]}});Ie||(ne={isEnabled:!1});var ge=ne;var Zo="data:video/webm;base64,GkXfowEAAAAAAAAfQoaBAUL3gQFC8oEEQvOBCEKChHdlYm1Ch4EEQoWBAhhTgGcBAAAAAAAVkhFNm3RALE27i1OrhBVJqWZTrIHfTbuMU6uEFlSua1OsggEwTbuMU6uEHFO7a1OsghV17AEAAAAAAACkAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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hhzTiKkFGPOOScRUoox55yTSjHmnHPOSSkZc8w556SUzjnnnHNSSuacc845KaVzzjnnnJRSSuecc05KKSWEzkEnpZTSOeecEwAAVOAAABBgo8jmBCNBhYasBABSAQAMjmNZmuZ5omialiRpmud5niiapiZJmuZ5nieKqsnzPE8URdE0VZXneZ4oiqJpqirXFUXTNE1VVV2yLIqmaZqq6rowTdNUVdd1XZimaaqq67oubFtVVdV1ZRm2raqq6rqyDFzXdWXZloEsu67s2rIAAPAEBwCgAhtWRzgpGgssNGQlAJABAEAYg5BCCCFlEEIKIYSUUggJAAAYcAAACDChDBQashIASAUAAIyx1lprrbXWQGettdZaa62AzFprrbXWWmuttdZaa6211lJrrbXWWmuttdZaa6211lprrbXWWmuttdZaa6211lprrbXWWmuttdZaa6211lprrbXWWmstpZRSSimllFJKKaWUUkoppZRSSgUA+lU4APg/2LA6wknRWGChISsBgHAAAMAYpRhzDEIppVQIMeacdFRai7FCiDHnJKTUWmzFc85BKCGV1mIsnnMOQikpxVZjUSmEUlJKLbZYi0qho5JSSq3VWIwxqaTWWoutxmKMSSm01FqLMRYjbE2ptdhqq7EYY2sqLbQYY4zFCF9kbC2m2moNxggjWywt1VprMMYY3VuLpbaaizE++NpSLDHWXAAAd4MDAESCjTOsJJ0VjgYXGrISAAgJACAQUooxxhhzzjnnpFKMOeaccw5CCKFUijHGnHMOQgghlIwx5pxzEEIIIYRSSsaccxBCCCGEkFLqnHMQQgghhBBKKZ1zDkIIIYQQQimlgxBCCCGEEEoopaQUQgghhBBCCKmklEIIIYRSQighlZRSCCGEEEIpJaSUUgohhFJCCKGElFJKKYUQQgillJJSSimlEkoJJYQSUikppRRKCCGUUkpKKaVUSgmhhBJKKSWllFJKIYQQSikFAAAcOAAABBhBJxlVFmGjCRcegEJDVgIAZAAAkKKUUiktRYIipRikGEtGFXNQWoqocgxSzalSziDmJJaIMYSUk1Qy5hRCDELqHHVMKQYtlRhCxhik2HJLoXMOAAAAQQCAgJAAAAMEBTMAwOAA4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YAAAE9AAABRAAAAUjAAAFPwAABVIAAAVuAAAFgQAABZ0AAAWwAAAFzAAABegAAAX7AAAGFwAAAGJ1ZHRhAAAAWm1ldGEAAAAAAAAAIWhkbHIAAAAAAAAAAG1kaXJhcHBsAAAAAAAAAAAAAAAALWlsc3QAAAAlqXRvbwAAAB1kYXRhAAAAAQAAAABMYXZmNTUuMzMuMTAw",yi=class{constructor(){this.enabled=!1}enable(){throw new Error("NoSleep using SSR/no-op mode; do not call enable.")}disable(){throw new Error("NoSleep using SSR/no-op mode; do not call disable.")}},xi=class{constructor(){this.enabled=!1;let s=()=>this.wakeLock&&document.visibilityState==="visible"&&this.enable();document.addEventListener("visibilitychange",s),document.addEventListener("fullscreenchange",s)}enable(){return N(this,null,function*(){try{this.wakeLock=yield navigator.wakeLock.request("screen"),this.enabled=!0,console.debug("Wake Lock active."),this.wakeLock.addEventListener("release",()=>{console.debug("Wake Lock released.")})}catch(s){this.enabled=!1,s instanceof Error&&console.error(`${s.name}, ${s.message}`)}})}disable(){var s;(s=this.wakeLock)==null||s.release(),this.wakeLock=void 0,this.enabled=!1}},Mi=class{constructor(){var s;this.enabled=!1,this.noSleepVideo=document.createElement("video"),this.noSleepVideo.setAttribute("title","No Sleep"),this.noSleepVideo.setAttribute("playsinline",""),this._addSourceToVideo(this.noSleepVideo,"webm",Zo),this._addSourceToVideo(this.noSleepVideo,"mp4",Xo),Object.assign(this.noSleepVideo.style,{position:"absolute",left:"-100%",top:"-100%"}),(s=document.querySelector("body"))==null||s.append(this.noSleepVideo),this.noSleepVideo.addEventListener("loadedmetadata",()=>{this.noSleepVideo.duration<=1?this.noSleepVideo.setAttribute("loop",""):this.noSleepVideo.addEventListener("timeupdate",()=>{this.noSleepVideo.currentTime>.5&&(this.noSleepVideo.currentTime=Math.random())})})}_addSourceToVideo(s,e,i){let t=document.createElement("source");t.src=i,t.type=`video/${e}`,s.appendChild(t)}enable(){return N(this,null,function*(){let s=this.noSleepVideo.play();try{let e=yield s;return this.enabled=!0,e}catch(e){this.enabled=!1,e instanceof Error&&console.error(`${e.name}, ${e.message}`)}})}disable(){this.noSleepVideo.pause(),this.enabled=!1}},uo=typeof navigator>"u"?yi:"wakeLock"in navigator&&!navigator.standalone?xi:Mi;var Ao=(()=>{class a{isDragging=D(!1);fullscreenStatus=D(!1);fullscreenSupported=D(!0);noSleepStatus=D(!1);noSleepSupported=D(!0);noSleep=null;initialTouchX=null;initialTouchY=null;hotkeyListeners=new Map;boundPreventGestures=null;fullscreenChangeHandler=()=>{if(this.fullscreenStatus.set(ge.isFullscreen),!ge.isFullscreen&&this.noSleep&&this.noSleepStatus()){try{this.noSleep.disable()}catch{}this.noSleepStatus.set(!1)}};constructor(){window.__KIP_TEST__?(this.fullscreenSupported.set(!1),this.noSleepSupported.set(!1)):(ge.isEnabled?ge.on("change",this.fullscreenChangeHandler):(this.fullscreenSupported.set(!1),console.log("[UI Event Service] Fullscreen mode is not supported by device/browser.")),this.checkNoSleepSupport(),this.checkPwaMode()&&this.noSleepSupported()&&!this.noSleepStatus()&&this.toggleNoSleep())}checkNoSleepSupport(){try{if(this.noSleep||(this.noSleep=new uo),!this.noSleep||typeof this.noSleep.enable!="function"||typeof this.noSleep.disable!="function")throw new Error("[UI Event Service] NoSleep methods not available")}catch(e){this.noSleepSupported.set(!1),console.warn(`[UI Event Service] NoSleep is not supported by this device/browser. Error: ${e}`),this.noSleep=null}}checkPwaMode(){let e=window.matchMedia("(display-mode: standalone)").matches||window.navigator.standalone!==void 0;return console.log("[UI Event Service] PWA mode:",e),e}toggleNoSleep(){if(this.noSleepSupported()){if(this.noSleepStatus())try{this.noSleep?.disable()}catch{}else{this.noSleep||this.checkNoSleepSupport();try{this.noSleep?.enable()}catch(e){console.warn("[UI Event Service] Failed to enable NoSleep:",e)}}this.noSleepStatus.set(!this.noSleepStatus()),console.log("[UI Event Service] NoSleep active:",this.noSleepStatus())}}toggleFullScreen(){if(ge.isEnabled){if(this.fullscreenStatus()){if(ge.isFullscreen&&ge.exit(),this.noSleepStatus()){try{this.noSleep?.disable()}catch{}this.noSleepStatus.set(!1)}}else if(ge.request(),!this.noSleepStatus()){this.noSleep||this.checkNoSleepSupport();try{this.noSleep?.enable(),this.noSleepStatus.set(!0)}catch{}}this.fullscreenStatus.set(!this.fullscreenStatus())}else this.fullscreenSupported.set(!1),console.log("[UI Event Service] Fullscreen mode is not supported by this browser.")}addGestureListeners(e,i){this.boundPreventGestures||(this.boundPreventGestures=this.preventBrowserHistorySwipeGestures.bind(this)),document.addEventListener("openLeftSidenav",e),document.addEventListener("openRightSidenav",i),document.addEventListener("touchstart",this.boundPreventGestures,{passive:!1}),document.addEventListener("touchmove",this.boundPreventGestures,{passive:!1}),document.addEventListener("touchend",this.boundPreventGestures),document.addEventListener("touchcancel",this.boundPreventGestures)}removeGestureListeners(e,i){document.removeEventListener("openLeftSidenav",e),document.removeEventListener("openRightSidenav",i),this.boundPreventGestures&&(document.removeEventListener("touchstart",this.boundPreventGestures),document.removeEventListener("touchmove",this.boundPreventGestures),document.removeEventListener("touchend",this.boundPreventGestures),document.removeEventListener("touchcancel",this.boundPreventGestures))}preventBrowserHistorySwipeGestures(e){if(e.touches.length===1){let i=e.touches[0],t=30;if(e.type==="touchstart")this.initialTouchX=i.clientX,this.initialTouchY=i.clientY;else if(e.type==="touchmove"&&this.initialTouchX!==null&&this.initialTouchY!==null){let l=Math.abs(i.clientX-this.initialTouchX),d=Math.abs(i.clientY-this.initialTouchY);l>10&&l>d&&(this.initialTouchX<t||this.initialTouchX>window.innerWidth-t)&&e.preventDefault(),d>10&&this.initialTouchY<50&&e.preventDefault()}else(e.type==="touchend"||e.type==="touchcancel")&&(this.initialTouchX=null,this.initialTouchY=null)}}addHotkeyListener(e,i){let t=l=>{if(l instanceof KeyboardEvent){let d=l.key.toLowerCase();if(i&&(i.keys&&!i.keys.includes(d)||i.ctrlKey!==void 0&&l.ctrlKey!==i.ctrlKey||i.shiftKey!==void 0&&l.shiftKey!==i.shiftKey))return;e(d,l)}else console.warn("[uiEvent Service] Non-keyboard event detected in addHotkeyListener:",l)};this.hotkeyListeners.set(e,t),document.addEventListener("keydown",t)}removeHotkeyListener(e){let i=this.hotkeyListeners.get(e);i&&(document.removeEventListener("keydown",i),this.hotkeyListeners.delete(e))}ngOnDestroy(){if(ge.isEnabled)try{ge.off("change",this.fullscreenChangeHandler)}catch{}if(this.noSleep&&this.noSleepStatus())try{this.noSleep.disable()}catch{}this.noSleep=null,this.boundPreventGestures&&(document.removeEventListener("touchstart",this.boundPreventGestures),document.removeEventListener("touchmove",this.boundPreventGestures),document.removeEventListener("touchend",this.boundPreventGestures),document.removeEventListener("touchcancel",this.boundPreventGestures),this.boundPreventGestures=null);for(let[,e]of this.hotkeyListeners.entries())document.removeEventListener("keydown",e);this.hotkeyListeners.clear()}static \u0275fac=function(i){return new(i||a)};static \u0275prov=fe({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})();var Xl=(()=>{class a{swipeMinDistance=h(30);swipeMaxDuration=h(600);longPressMs=h(500);doubleTapInterval=h(300);tapSlop=h(20);pressMoveSlop=h(10);swipeleft=K();swiperight=K();swipeup=K();swipedown=K();press=K();doubletap=K();zone=m(ut);destroyRef=m(Le);host=m(pe);uiEvent=m(Ao);pointerId=null;startX=0;startY=0;startTime=0;tracking=!1;longPressTimer=null;pressFired=!1;suppressionActive=!1;docPointerMoveSuppress;docPointerDownSuppress;docTouchMoveSuppress;docTouchStartSuppress;docMouseMoveSuppress;docMouseDownSuppress;lastTapTime=0;lastTapX=0;lastTapY=0;currentPointerType=null;lastTapUpTime=0;lastTapUpX=0;lastTapUpY=0;potentialDoubleTap=!1;dragEndedAt=0;constructor(){this.zone.runOutsideAngular(()=>{let e=this.host.nativeElement;e.style.touchAction||(e.style.touchAction="none","webkitTouchCallout"in e.style&&(e.style.webkitTouchCallout="none")),e.addEventListener("pointerdown",this.onPointerDown,{passive:!1}),e.addEventListener("pointermove",this.onPointerMove,{passive:!0}),e.addEventListener("pointerup",this.onPointerUp,{passive:!0}),e.addEventListener("pointercancel",this.onPointerCancel,{passive:!0}),e.addEventListener("lostpointercapture",this.onPointerCancel,{passive:!0}),e.addEventListener("dblclick",this.onNativeDblClick,{passive:!0}),this.destroyRef.onDestroy(()=>{e.removeEventListener("pointerdown",this.onPointerDown),e.removeEventListener("pointermove",this.onPointerMove),e.removeEventListener("pointerup",this.onPointerUp),e.removeEventListener("pointercancel",this.onPointerCancel),e.removeEventListener("lostpointercapture",this.onPointerCancel),e.removeEventListener("dblclick",this.onNativeDblClick),this.longPressTimer&&window.clearTimeout(this.longPressTimer),this.removeSuppression()})}),ft(()=>{this.uiEvent.isDragging()||(this.dragEndedAt=performance.now())})}onNativeDblClick=e=>{let i=new CustomEvent("doubletap",{detail:{x:e.clientX,y:e.clientY,native:!0}});this.zone.run(()=>this.doubletap.emit(i)),this.lastTapTime=0};onPointerDown=e=>{if(this.pointerId!==null)return;this.pointerId=e.pointerId,this.tracking=!0,this.pressFired=!1,this.currentPointerType=e.pointerType||null;let t=performance.now()-this.lastTapUpTime,l=Math.hypot(e.clientX-this.lastTapUpX,e.clientY-this.lastTapUpY);this.potentialDoubleTap=t<=this.doubleTapInterval()&&l<=this.tapSlop(),this.startX=e.clientX,this.startY=e.clientY,this.startTime=performance.now();try{e.target.setPointerCapture(e.pointerId)}catch{}this.longPressTimer&&window.clearTimeout(this.longPressTimer),!this.uiEvent.isDragging()&&!this.potentialDoubleTap&&(this.longPressTimer=window.setTimeout(()=>{if(!this.tracking||this.uiEvent.isDragging())return;let d=e.clientX-this.startX,g=e.clientY-this.startY,S=performance.now()-this.dragEndedAt<350&&this.currentPointerType==="touch"?15:0;if(Math.abs(d)<=this.pressMoveSlop()+S&&Math.abs(g)<=this.pressMoveSlop()+S){this.pressFired=!0;let T=new CustomEvent("press",{detail:{x:this.startX,y:this.startY,center:{x:this.startX,y:this.startY}}});this.zone.run(()=>this.press.emit(T)),this.addSuppression(e)}},this.longPressMs()))};onPointerMove=e=>{if(!(!this.tracking||e.pointerId!==this.pointerId)&&!this.pressFired){let i=e.clientX-this.startX,t=e.clientY-this.startY,d=performance.now()-this.dragEndedAt<350&&this.currentPointerType==="touch"?15:0,g=this.pressMoveSlop()+d;(this.uiEvent.isDragging()||Math.abs(i)>g||Math.abs(t)>g)&&this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null)}};onPointerUp=e=>{if(!this.tracking||e.pointerId!==this.pointerId)return;let i=performance.now(),t=i-this.startTime,l=e.clientX-this.startX,d=e.clientY-this.startY,g=Math.abs(l),C=Math.abs(d);if(this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null),!this.pressFired&&(t<=this.swipeMaxDuration()&&(g>=this.swipeMinDistance()&&g>=C?this.zone.run(()=>l>0?this.swiperight.emit(new CustomEvent("swiperight",{detail:{dx:l,dy:d,duration:t}})):this.swipeleft.emit(new CustomEvent("swipeleft",{detail:{dx:l,dy:d,duration:t}}))):C>=this.swipeMinDistance()&&C>g&&this.zone.run(()=>d>0?this.swipedown.emit(new CustomEvent("swipedown",{detail:{dx:l,dy:d,duration:t}})):this.swipeup.emit(new CustomEvent("swipeup",{detail:{dx:l,dy:d,duration:t}})))),this.currentPointerType!=="mouse"&&g<=this.tapSlop()&&C<=this.tapSlop()&&t<this.longPressMs())){let S=i,T=S-this.lastTapTime,E=Math.hypot(e.clientX-this.lastTapX,e.clientY-this.lastTapY);T<=this.doubleTapInterval()&&E<=this.tapSlop()?(this.zone.run(()=>this.doubletap.emit(new CustomEvent("doubletap",{detail:{x:e.clientX,y:e.clientY,dt:T}}))),this.lastTapTime=0,this.potentialDoubleTap=!1):(this.lastTapTime=S,this.lastTapX=e.clientX,this.lastTapY=e.clientY)}!this.pressFired&&g<=this.tapSlop()&&C<=this.tapSlop()&&t<this.longPressMs()?(this.lastTapUpTime=i,this.lastTapUpX=e.clientX,this.lastTapUpY=e.clientY):this.potentialDoubleTap=!1,this.reset()};onPointerCancel=e=>{e.pointerId===this.pointerId&&(this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null),this.reset())};reset(){this.pointerId=null,this.tracking=!1,this.pressFired=!1,this.currentPointerType=null}addSuppression(e){if(this.suppressionActive)return;this.suppressionActive=!0,this.docPointerMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docPointerDownSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docTouchMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docTouchStartSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docMouseMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docMouseDownSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},document.addEventListener("pointermove",this.docPointerMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("pointerdown",this.docPointerDownSuppress,{capture:!0,passive:!1}),document.addEventListener("touchmove",this.docTouchMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("touchstart",this.docTouchStartSuppress,{capture:!0,passive:!1}),document.addEventListener("mousemove",this.docMouseMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("mousedown",this.docMouseDownSuppress,{capture:!0,passive:!1});try{let t=e,l=typeof t.screenX=="number"?t.screenX:e.clientX,d=typeof t.screenY=="number"?t.screenY:e.clientY;if(e.pointerType==="mouse"){let g=new PointerEvent("pointerup",{bubbles:!0,cancelable:!0,pointerId:e.pointerId,pointerType:e.pointerType,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d});e.target.dispatchEvent(g);let C=new MouseEvent("mouseup",{bubbles:!0,cancelable:!0,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d,button:0});e.target.dispatchEvent(C)}else if(e.pointerType==="touch"){let g=new PointerEvent("pointercancel",{bubbles:!0,cancelable:!0,pointerId:e.pointerId,pointerType:e.pointerType,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d});e.target.dispatchEvent(g);try{let C=new TouchEvent("touchcancel",{bubbles:!0,cancelable:!0});e.target.dispatchEvent(C)}catch{}}}catch{}let i=t=>{t instanceof PointerEvent&&this.pointerId!==null&&t.pointerId!==this.pointerId||(this.removeSuppression(),document.removeEventListener("pointerup",i,!0),document.removeEventListener("pointercancel",i,!0),document.removeEventListener("touchend",i,!0),document.removeEventListener("touchcancel",i,!0))};document.addEventListener("pointerup",i,!0),document.addEventListener("pointercancel",i,!0),document.addEventListener("touchend",i,!0),document.addEventListener("touchcancel",i,!0)}removeSuppression(){this.suppressionActive&&(this.suppressionActive=!1,this.docPointerMoveSuppress&&document.removeEventListener("pointermove",this.docPointerMoveSuppress,!0),this.docPointerDownSuppress&&document.removeEventListener("pointerdown",this.docPointerDownSuppress,!0),this.docTouchMoveSuppress&&document.removeEventListener("touchmove",this.docTouchMoveSuppress,!0),this.docTouchStartSuppress&&document.removeEventListener("touchstart",this.docTouchStartSuppress,!0),this.docMouseMoveSuppress&&document.removeEventListener("mousemove",this.docMouseMoveSuppress,!0),this.docMouseDownSuppress&&document.removeEventListener("mousedown",this.docMouseDownSuppress,!0),this.docPointerMoveSuppress=void 0,this.docPointerDownSuppress=void 0,this.docTouchMoveSuppress=void 0,this.docTouchStartSuppress=void 0,this.docMouseMoveSuppress=void 0,this.docMouseDownSuppress=void 0)}static \u0275fac=function(i){return new(i||a)};static \u0275dir=Q({type:a,selectors:[["","kipGestures",""]],inputs:{swipeMinDistance:[1,"swipeMinDistance"],swipeMaxDuration:[1,"swipeMaxDuration"],longPressMs:[1,"longPressMs"],doubleTapInterval:[1,"doubleTapInterval"],tapSlop:[1,"tapSlop"],pressMoveSlop:[1,"pressMoveSlop"]},outputs:{swipeleft:"swipeleft",swiperight:"swiperight",swipeup:"swipeup",swipedown:"swipedown",press:"press",doubletap:"doubletap"}})}return a})();var ls=(()=>{class a{_settings=m(Ut);_router=m(da);dashboards=D([],{equal:bi});activeDashboard=D(0);_widgetAction=new kt(null);widgetAction$=this._widgetAction.asObservable();_isDashboardStatic=new kt(!0);isDashboardStatic$=this._isDashboardStatic.asObservable();isDashboardStatic=ra(this.isDashboardStatic$);blankDashboard=[{id:null,name:"Dashboard 1",configuration:[{w:12,h:12,id:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc",selector:"widget-tutorial",input:{widgetProperties:{type:"widget-tutorial",uuid:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc"}},x:0,y: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=this.blankDashboard.map(t=>he(re({},t),{id:rt.create()}));this.dashboards.set([...i])}else this.dashboards.set(this._settings.getDashboardConfig());ft(()=>{this._settings.saveDashboards(this.dashboards())})}toggleStaticDashboard(){this._isDashboardStatic.next(!this._isDashboardStatic.value)}add(e,i){this.dashboards.update(t=>[...t,{id:rt.create(),name:e,configuration:i}])}update(e,i){this.dashboards.update(t=>t.map((l,d)=>d===e?he(re({},l),{name:i}):l))}delete(e){this.dashboards.update(i=>i.filter((t,l)=>l!==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,i){if(e<0||e>=this.dashboards().length){console.error(`[Dashboard Service] Invalid itemIndex: ${e}`);return}let t=this.dashboards()[e],l=Qt(t);l.id=rt.create(),l.name=i,Array.isArray(l.configuration)?l.configuration.forEach(d=>{d&&d.input?.widgetProperties?(d.id=rt.create(),d.input.widgetProperties.uuid=d.id):console.error("Dashboard Service] Widget configuration is missing required properties:",d)}):(console.error("Dashboard Service] Dashboard configuration is not an array:",l.configuration),l.configuration=[]),this.dashboards.update(d=>[...d,l])}updateConfiguration(e,i){this.dashboards.update(t=>t.map((l,d)=>d===e?bi(l.configuration,i)?l:he(re({},l),{configuration:i}):l))}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)}setActiveDashboard(e){e>=0&&e<this.dashboards().length?this.activeDashboard.set(e):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`)}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"})}setStaticDashboard(e){this._isDashboardStatic.next(e)}static \u0275fac=function(i){return new(i||a)};static \u0275prov=fe({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})();function Ko(a,s){a&1&&Yi(0)}var go=(()=>{class a{data=m(ze);static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["dialog-frame"]],decls:8,vars:3,consts:[[1,"dialogue-header"],["mat-dialog-title",""],["mat-icon-button","",1,"dialog-close-icon",3,"mat-dialog-close"],[1,"dialog-content-padding"],[4,"ngComponentOutlet"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"h6",1),r(2),o(),n(3,"button",2)(4,"mat-icon"),r(5,"close"),o()()(),n(6,"mat-dialog-content",3),Te(7,Ko,1,0,"ng-container",4),o()),i&2&&(c(2),k(t.data.title),c(),p("mat-dialog-close",!1),c(4),p("ngComponentOutlet",t.data.componentType))},dependencies:[ee,xe,je,Ye,He,ce,se,ta],styles:[".dialogue-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline}.dialog-close-icon[_ngcontent-%COMP%]{margin-right:15px}.mat-mdc-dialog-content[_ngcontent-%COMP%]{max-height:max-content}.dialog-content-padding[_ngcontent-%COMP%]{--mat-dialog-content-padding: 0px 24px 20px 24px}"]})}return a})();function Jo(a,s){if(a&1&&(n(0,"button",4),r(1),o()),a&2){let e=f();p("mat-dialog-close",!0),c(),k(e.data.confirmBtnText)}}var ho=(()=>{class a{data=m(ze);static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["dialog-confirmation"]],decls:12,vars:6,consts:[[1,"dialogue-header"],["mat-dialog-title",""],["mat-icon-button","",1,"dialog-close-icon",3,"mat-dialog-close"],["align","end"],["mat-flat-button","",3,"mat-dialog-close"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"h5",1),r(2),o(),n(3,"button",2)(4,"mat-icon"),r(5,"close"),o()()(),n(6,"mat-dialog-content"),r(7),o(),n(8,"mat-dialog-actions",3)(9,"button",4),r(10),o(),u(11,Jo,2,2,"button",4),o()),i&2&&(c(2),k(t.data.title),c(),p("mat-dialog-close",!1),c(4),U(" ",t.data.message,`
1
+ import{a as ai,b as ro,c as lo,d as so,e as co}from"./chunk-PKNLASTF.js";import{a as St}from"./chunk-VYUMZVH2.js";import{a as ao,b as oo,c as no,d as ii}from"./chunk-CBUY7NMR.js";import{a as Se,b as $e}from"./chunk-JY3WVS7C.js";import{a as Za,b as Xa,c as Ka,d as wt,e as Ja,f as Z,g as $a,h as eo,k as to,l as io,m as It,n as me,o as Je}from"./chunk-ZBCOJLI4.js";import{d as ca,g as da,l as pa,m as ee,n as Ce}from"./chunk-TXPLRBW5.js";import{a as Fa,b as La,c as Ba,d as qe,e as ze,g as Va,h as je,i as Ye,j as He,k as Ct,l as xe}from"./chunk-3LEMFOCV.js";import{a as bt}from"./chunk-K22CSA3Y.js";import{a as Ha,b as ti}from"./chunk-2YVW3TBK.js";import{$ as we,A as Wa,B as Ua,C as de,D as Qa,E as Jt,F as Ze,G as Me,H,I as qa,J as za,K as Xe,L as $t,M as yt,N as L,P as xt,Q as ae,R as B,T as V,U as ei,V as ja,W as Mt,Y as Ya,_ as R,a as rt,ca as oe,da as Ke,e as na,f as la,h as sa,i as Ut,j as bi,k as Qt,p as ma,q as Kt,r as te,t as Y,w as F,x as ie,y as Ra,z as Na}from"./chunk-TA4GACKT.js";import{$b as b,$c as K,$d as ga,$e as Da,A as ct,Aa as w,Ab as Be,Ac as k,Ad as ia,Ae as Ca,Bc as U,Be as ya,Cb as Te,Cc as ht,Ce as Zt,Da as Fe,Db as Qi,De as se,Ec as Zi,Ed as aa,Ee as Xt,F as Oi,Fa as Le,Fb as le,Fc as Xi,Fe as Qe,Gb as ut,Gc as Ki,Hb as qi,He as xa,I as Ai,Ie as ce,Ja as D,K as Pe,Kc as Ee,Kd as oa,Ke as Ma,L as Oe,Mc as Re,Na as ot,Nc as Et,O as Fi,Oa as pt,Oe as wa,P as Bt,Pd as Ue,Pe as Sa,Qa as pe,Qc as Ne,Qd as ra,R as dt,Rb as q,Rc as We,Sb as u,Tb as A,U as Li,Ub as I,Ud as _i,Vb as Rt,Vd as ua,W as Bi,Wb as y,Wd as qt,We as ka,Xb as x,Xc as Ji,Xe as Ta,Yb as p,Yc as ft,Yd as Aa,Zb as n,Ze as Ea,_b as o,_c as $i,_e as Ci,a as re,ac as hi,ad as h,b as he,bc as fi,be as zt,cf as Ia,dc as zi,de as ha,df as Ga,ec as ji,ed as nt,ee as jt,ef as Pa,f as N,fa as mt,fc as Yi,fe as fa,g as lt,ga as Vt,gc as P,ge as ba,hc as Hi,hf as Oa,ia as Vi,ic as _,id as O,j as pi,kc as f,lb as c,lc as ve,le as Dt,m as st,mc as X,me as _t,na as Tt,nb as Ni,nc as ue,ne as _a,o as kt,oa as fe,oc as Ve,pa as be,pb as gi,pc as z,pe as vi,qc as j,qe as Yt,ra as J,sb as Wi,se as Ht,t as ui,ta as m,te as $,uc as Ae,vc as Nt,vd as ea,ve as De,wb as v,wc as W,wd as ta,we as ye,xa as Ri,xb as _e,xc as At,xe as vt,y as Lt,yb as Q,yc as gt,za as M,zb as Ui,zc as r,zd as Wt,ze as va}from"./chunk-35L7BBBD.js";var mo=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],Ie=(()=>{if(typeof document>"u")return!1;let a=mo[0],s={};for(let e of mo)if(e?.[1]in document){for(let[t,l]of e.entries())s[a[t]]=l;return s}return!1})(),po={change:Ie.fullscreenchange,error:Ie.fullscreenerror},ne={request(a=document.documentElement,s){return new Promise((e,i)=>{let t=()=>{ne.off("change",t),e()};ne.on("change",t);let l=a[Ie.requestFullscreen](s);l instanceof Promise&&l.then(t).catch(i)})},exit(){return new Promise((a,s)=>{if(!ne.isFullscreen){a();return}let e=()=>{ne.off("change",e),a()};ne.on("change",e);let i=document[Ie.exitFullscreen]();i instanceof Promise&&i.then(e).catch(s)})},toggle(a,s){return ne.isFullscreen?ne.exit():ne.request(a,s)},onchange(a){ne.on("change",a)},onerror(a){ne.on("error",a)},on(a,s){let e=po[a];e&&document.addEventListener(e,s,!1)},off(a,s){let e=po[a];e&&document.removeEventListener(e,s,!1)},raw:Ie};Object.defineProperties(ne,{isFullscreen:{get:()=>!!document[Ie.fullscreenElement]},element:{enumerable:!0,get:()=>document[Ie.fullscreenElement]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aoqME1VFQAAUOAAABBgg6bE4gCFhqwEAEICAByKYlma5nmeJ4qmqZokSdM8TxRF0TRNU1VJkqZ5niiKommapqqyLE3zPFEURdNUVVWFpnmeKIqiaaqq6sLzPE8URdE0VdV14XmeJ4qiaJqq6roQRVE0TdNUTVV1XSCKpmmaqqqqrgtETxRNU1Vd13WB54miaaqqq7ouEE3TVFVVdV1ZBpimaaqq68oyQFVV1XVdV5YBqqqqruu6sgxQVdd1XVmWZQCu67qyLMsCAAAOHAAAAoygk4wqi7DRhAsPQKEhKwKAKAAAwBimFFPKMCYhpBAaxiSEFEImJaXSUqogpFJSKRWEVEoqJaOUUmopVRBSKamUCkIqJZVSAADYgQMA2IGFUGjISgAgDwCAMEYpxhhzTiKkFGPOOScRUoox55yTSjHmnHPOSSkZc8w556SUzjnnnHNSSuacc845KaVzzjnnnJRSSuecc05KKSWEzkEnpZTSOeecEwAAVOAAABBgo8jmBCNBhYasBABSAQAMjmNZmuZ5omialiRpmud5niiapiZJmuZ5nieKqsnzPE8URdE0VZXneZ4oiqJpqirXFUXTNE1VVV2yLIqmaZqq6rowTdNUVdd1XZimaaqq67oubFtVVdV1ZRm2raqq6rqyDFzXdWXZloEsu67s2rIAAPAEBwCgAhtWRzgpGgssNGQlAJABAEAYg5BCCCFlEEIKIYSUUggJAAAYcAAACDChDBQashIASAUAAIyx1lprrbXWQGettdZaa62AzFprrbXWWmuttdZaa6211lJrrbXWWmuttdZaa6211lprrbXWWmuttdZaa6211lprrbXWWmuttdZaa6211lprrbXWWmstpZRSSimllFJKKaWUUkoppZRSSgUA+lU4APg/2LA6wknRWGChISsBgHAAAMAYpRhzDEIppVQIMeacdFRai7FCiDHnJKTUWmzFc85BKCGV1mIsnnMOQikpxVZjUSmEUlJKLbZYi0qho5JSSq3VWIwxqaTWWoutxmKMSSm01FqLMRYjbE2ptdhqq7EYY2sqLbQYY4zFCF9kbC2m2moNxggjWywt1VprMMYY3VuLpbaaizE++NpSLDHWXAAAd4MDAESCjTOs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AAAAAAAAAAAAADMAAAAaAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAACMc3RjbwAAAAAAAAAfAAAALAAAA1UAAANyAAADhgAAA6IAAAO+AAAD0QAAA+0AAAQAAAAEHAAABC8AAARLAAAEZwAABHoAAASWAAAEqQAABMUAAATYAAAE9AAABRAAAAUjAAAFPwAABVIAAAVuAAAFgQAABZ0AAAWwAAAFzAAABegAAAX7AAAGFwAAAGJ1ZHRhAAAAWm1ldGEAAAAAAAAAIWhkbHIAAAAAAAAAAG1kaXJhcHBsAAAAAAAAAAAAAAAALWlsc3QAAAAlqXRvbwAAAB1kYXRhAAAAAQAAAABMYXZmNTUuMzMuMTAw",yi=class{constructor(){this.enabled=!1}enable(){throw new Error("NoSleep using SSR/no-op mode; do not call enable.")}disable(){throw new Error("NoSleep using SSR/no-op mode; do not call disable.")}},xi=class{constructor(){this.enabled=!1;let s=()=>this.wakeLock&&document.visibilityState==="visible"&&this.enable();document.addEventListener("visibilitychange",s),document.addEventListener("fullscreenchange",s)}enable(){return N(this,null,function*(){try{this.wakeLock=yield navigator.wakeLock.request("screen"),this.enabled=!0,console.debug("Wake Lock active."),this.wakeLock.addEventListener("release",()=>{console.debug("Wake Lock released.")})}catch(s){this.enabled=!1,s instanceof Error&&console.error(`${s.name}, ${s.message}`)}})}disable(){var s;(s=this.wakeLock)==null||s.release(),this.wakeLock=void 0,this.enabled=!1}},Mi=class{constructor(){var s;this.enabled=!1,this.noSleepVideo=document.createElement("video"),this.noSleepVideo.setAttribute("title","No Sleep"),this.noSleepVideo.setAttribute("playsinline",""),this._addSourceToVideo(this.noSleepVideo,"webm",Zo),this._addSourceToVideo(this.noSleepVideo,"mp4",Xo),Object.assign(this.noSleepVideo.style,{position:"absolute",left:"-100%",top:"-100%"}),(s=document.querySelector("body"))==null||s.append(this.noSleepVideo),this.noSleepVideo.addEventListener("loadedmetadata",()=>{this.noSleepVideo.duration<=1?this.noSleepVideo.setAttribute("loop",""):this.noSleepVideo.addEventListener("timeupdate",()=>{this.noSleepVideo.currentTime>.5&&(this.noSleepVideo.currentTime=Math.random())})})}_addSourceToVideo(s,e,i){let t=document.createElement("source");t.src=i,t.type=`video/${e}`,s.appendChild(t)}enable(){return N(this,null,function*(){let s=this.noSleepVideo.play();try{let e=yield s;return this.enabled=!0,e}catch(e){this.enabled=!1,e instanceof Error&&console.error(`${e.name}, ${e.message}`)}})}disable(){this.noSleepVideo.pause(),this.enabled=!1}},uo=typeof navigator>"u"?yi:"wakeLock"in navigator&&!navigator.standalone?xi:Mi;var Ao=(()=>{class a{isDragging=D(!1);fullscreenStatus=D(!1);fullscreenSupported=D(!0);noSleepStatus=D(!1);noSleepSupported=D(!0);noSleep=null;initialTouchX=null;initialTouchY=null;hotkeyListeners=new Map;boundPreventGestures=null;fullscreenChangeHandler=()=>{if(this.fullscreenStatus.set(ge.isFullscreen),!ge.isFullscreen&&this.noSleep&&this.noSleepStatus()){try{this.noSleep.disable()}catch{}this.noSleepStatus.set(!1)}};constructor(){window.__KIP_TEST__?(this.fullscreenSupported.set(!1),this.noSleepSupported.set(!1)):(ge.isEnabled?ge.on("change",this.fullscreenChangeHandler):(this.fullscreenSupported.set(!1),console.log("[UI Event Service] Fullscreen mode is not supported by device/browser.")),this.checkNoSleepSupport(),this.checkPwaMode()&&this.noSleepSupported()&&!this.noSleepStatus()&&this.toggleNoSleep())}checkNoSleepSupport(){try{if(this.noSleep||(this.noSleep=new uo),!this.noSleep||typeof this.noSleep.enable!="function"||typeof this.noSleep.disable!="function")throw new Error("[UI Event Service] NoSleep methods not available")}catch(e){this.noSleepSupported.set(!1),console.warn(`[UI Event Service] NoSleep is not supported by this device/browser. Error: ${e}`),this.noSleep=null}}checkPwaMode(){let e=window.matchMedia("(display-mode: standalone)").matches||window.navigator.standalone!==void 0;return console.log("[UI Event Service] PWA mode:",e),e}toggleNoSleep(){if(this.noSleepSupported()){if(this.noSleepStatus())try{this.noSleep?.disable()}catch{}else{this.noSleep||this.checkNoSleepSupport();try{this.noSleep?.enable()}catch(e){console.warn("[UI Event Service] Failed to enable NoSleep:",e)}}this.noSleepStatus.set(!this.noSleepStatus()),console.log("[UI Event Service] NoSleep active:",this.noSleepStatus())}}toggleFullScreen(){if(ge.isEnabled){if(this.fullscreenStatus()){if(ge.isFullscreen&&ge.exit(),this.noSleepStatus()){try{this.noSleep?.disable()}catch{}this.noSleepStatus.set(!1)}}else if(ge.request(),!this.noSleepStatus()){this.noSleep||this.checkNoSleepSupport();try{this.noSleep?.enable(),this.noSleepStatus.set(!0)}catch{}}this.fullscreenStatus.set(!this.fullscreenStatus())}else this.fullscreenSupported.set(!1),console.log("[UI Event Service] Fullscreen mode is not supported by this browser.")}addGestureListeners(e,i){this.boundPreventGestures||(this.boundPreventGestures=this.preventBrowserHistorySwipeGestures.bind(this)),document.addEventListener("openLeftSidenav",e),document.addEventListener("openRightSidenav",i),document.addEventListener("touchstart",this.boundPreventGestures,{passive:!1}),document.addEventListener("touchmove",this.boundPreventGestures,{passive:!1}),document.addEventListener("touchend",this.boundPreventGestures),document.addEventListener("touchcancel",this.boundPreventGestures)}removeGestureListeners(e,i){document.removeEventListener("openLeftSidenav",e),document.removeEventListener("openRightSidenav",i),this.boundPreventGestures&&(document.removeEventListener("touchstart",this.boundPreventGestures),document.removeEventListener("touchmove",this.boundPreventGestures),document.removeEventListener("touchend",this.boundPreventGestures),document.removeEventListener("touchcancel",this.boundPreventGestures))}preventBrowserHistorySwipeGestures(e){if(e.touches.length===1){let i=e.touches[0],t=30;if(e.type==="touchstart")this.initialTouchX=i.clientX,this.initialTouchY=i.clientY;else if(e.type==="touchmove"&&this.initialTouchX!==null&&this.initialTouchY!==null){let l=Math.abs(i.clientX-this.initialTouchX),d=Math.abs(i.clientY-this.initialTouchY);l>10&&l>d&&(this.initialTouchX<t||this.initialTouchX>window.innerWidth-t)&&e.preventDefault(),d>10&&this.initialTouchY<50&&e.preventDefault()}else(e.type==="touchend"||e.type==="touchcancel")&&(this.initialTouchX=null,this.initialTouchY=null)}}addHotkeyListener(e,i){let t=l=>{if(l instanceof KeyboardEvent){let d=l.key.toLowerCase();if(i&&(i.keys&&!i.keys.includes(d)||i.ctrlKey!==void 0&&l.ctrlKey!==i.ctrlKey||i.shiftKey!==void 0&&l.shiftKey!==i.shiftKey))return;e(d,l)}else console.warn("[uiEvent Service] Non-keyboard event detected in addHotkeyListener:",l)};this.hotkeyListeners.set(e,t),document.addEventListener("keydown",t)}removeHotkeyListener(e){let i=this.hotkeyListeners.get(e);i&&(document.removeEventListener("keydown",i),this.hotkeyListeners.delete(e))}ngOnDestroy(){if(ge.isEnabled)try{ge.off("change",this.fullscreenChangeHandler)}catch{}if(this.noSleep&&this.noSleepStatus())try{this.noSleep.disable()}catch{}this.noSleep=null,this.boundPreventGestures&&(document.removeEventListener("touchstart",this.boundPreventGestures),document.removeEventListener("touchmove",this.boundPreventGestures),document.removeEventListener("touchend",this.boundPreventGestures),document.removeEventListener("touchcancel",this.boundPreventGestures),this.boundPreventGestures=null);for(let[,e]of this.hotkeyListeners.entries())document.removeEventListener("keydown",e);this.hotkeyListeners.clear()}static \u0275fac=function(i){return new(i||a)};static \u0275prov=fe({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})();var Xl=(()=>{class a{swipeMinDistance=h(30);swipeMaxDuration=h(600);longPressMs=h(500);doubleTapInterval=h(300);tapSlop=h(20);pressMoveSlop=h(10);swipeleft=K();swiperight=K();swipeup=K();swipedown=K();press=K();doubletap=K();zone=m(ut);destroyRef=m(Le);host=m(pe);uiEvent=m(Ao);pointerId=null;startX=0;startY=0;startTime=0;tracking=!1;longPressTimer=null;pressFired=!1;suppressionActive=!1;docPointerMoveSuppress;docPointerDownSuppress;docTouchMoveSuppress;docTouchStartSuppress;docMouseMoveSuppress;docMouseDownSuppress;lastTapTime=0;lastTapX=0;lastTapY=0;currentPointerType=null;lastTapUpTime=0;lastTapUpX=0;lastTapUpY=0;potentialDoubleTap=!1;dragEndedAt=0;constructor(){this.zone.runOutsideAngular(()=>{let e=this.host.nativeElement;e.style.touchAction||(e.style.touchAction="none","webkitTouchCallout"in e.style&&(e.style.webkitTouchCallout="none")),e.addEventListener("pointerdown",this.onPointerDown,{passive:!1}),e.addEventListener("pointermove",this.onPointerMove,{passive:!0}),e.addEventListener("pointerup",this.onPointerUp,{passive:!0}),e.addEventListener("pointercancel",this.onPointerCancel,{passive:!0}),e.addEventListener("lostpointercapture",this.onPointerCancel,{passive:!0}),e.addEventListener("dblclick",this.onNativeDblClick,{passive:!0}),this.destroyRef.onDestroy(()=>{e.removeEventListener("pointerdown",this.onPointerDown),e.removeEventListener("pointermove",this.onPointerMove),e.removeEventListener("pointerup",this.onPointerUp),e.removeEventListener("pointercancel",this.onPointerCancel),e.removeEventListener("lostpointercapture",this.onPointerCancel),e.removeEventListener("dblclick",this.onNativeDblClick),this.longPressTimer&&window.clearTimeout(this.longPressTimer),this.removeSuppression()})}),ft(()=>{this.uiEvent.isDragging()||(this.dragEndedAt=performance.now())})}onNativeDblClick=e=>{let i=new CustomEvent("doubletap",{detail:{x:e.clientX,y:e.clientY,native:!0}});this.zone.run(()=>this.doubletap.emit(i)),this.lastTapTime=0};onPointerDown=e=>{if(this.pointerId!==null)return;this.pointerId=e.pointerId,this.tracking=!0,this.pressFired=!1,this.currentPointerType=e.pointerType||null;let t=performance.now()-this.lastTapUpTime,l=Math.hypot(e.clientX-this.lastTapUpX,e.clientY-this.lastTapUpY);this.potentialDoubleTap=t<=this.doubleTapInterval()&&l<=this.tapSlop(),this.startX=e.clientX,this.startY=e.clientY,this.startTime=performance.now();try{e.target.setPointerCapture(e.pointerId)}catch{}this.longPressTimer&&window.clearTimeout(this.longPressTimer),!this.uiEvent.isDragging()&&!this.potentialDoubleTap&&(this.longPressTimer=window.setTimeout(()=>{if(!this.tracking||this.uiEvent.isDragging())return;let d=e.clientX-this.startX,g=e.clientY-this.startY,S=performance.now()-this.dragEndedAt<350&&this.currentPointerType==="touch"?15:0;if(Math.abs(d)<=this.pressMoveSlop()+S&&Math.abs(g)<=this.pressMoveSlop()+S){this.pressFired=!0;let T=new CustomEvent("press",{detail:{x:this.startX,y:this.startY,center:{x:this.startX,y:this.startY}}});this.zone.run(()=>this.press.emit(T)),this.addSuppression(e)}},this.longPressMs()))};onPointerMove=e=>{if(!(!this.tracking||e.pointerId!==this.pointerId)&&!this.pressFired){let i=e.clientX-this.startX,t=e.clientY-this.startY,d=performance.now()-this.dragEndedAt<350&&this.currentPointerType==="touch"?15:0,g=this.pressMoveSlop()+d;(this.uiEvent.isDragging()||Math.abs(i)>g||Math.abs(t)>g)&&this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null)}};onPointerUp=e=>{if(!this.tracking||e.pointerId!==this.pointerId)return;let i=performance.now(),t=i-this.startTime,l=e.clientX-this.startX,d=e.clientY-this.startY,g=Math.abs(l),C=Math.abs(d);if(this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null),!this.pressFired&&(t<=this.swipeMaxDuration()&&(g>=this.swipeMinDistance()&&g>=C?this.zone.run(()=>l>0?this.swiperight.emit(new CustomEvent("swiperight",{detail:{dx:l,dy:d,duration:t}})):this.swipeleft.emit(new CustomEvent("swipeleft",{detail:{dx:l,dy:d,duration:t}}))):C>=this.swipeMinDistance()&&C>g&&this.zone.run(()=>d>0?this.swipedown.emit(new CustomEvent("swipedown",{detail:{dx:l,dy:d,duration:t}})):this.swipeup.emit(new CustomEvent("swipeup",{detail:{dx:l,dy:d,duration:t}})))),this.currentPointerType!=="mouse"&&g<=this.tapSlop()&&C<=this.tapSlop()&&t<this.longPressMs())){let S=i,T=S-this.lastTapTime,E=Math.hypot(e.clientX-this.lastTapX,e.clientY-this.lastTapY);T<=this.doubleTapInterval()&&E<=this.tapSlop()?(this.zone.run(()=>this.doubletap.emit(new CustomEvent("doubletap",{detail:{x:e.clientX,y:e.clientY,dt:T}}))),this.lastTapTime=0,this.potentialDoubleTap=!1):(this.lastTapTime=S,this.lastTapX=e.clientX,this.lastTapY=e.clientY)}!this.pressFired&&g<=this.tapSlop()&&C<=this.tapSlop()&&t<this.longPressMs()?(this.lastTapUpTime=i,this.lastTapUpX=e.clientX,this.lastTapUpY=e.clientY):this.potentialDoubleTap=!1,this.reset()};onPointerCancel=e=>{e.pointerId===this.pointerId&&(this.longPressTimer&&(window.clearTimeout(this.longPressTimer),this.longPressTimer=null),this.reset())};reset(){this.pointerId=null,this.tracking=!1,this.pressFired=!1,this.currentPointerType=null}addSuppression(e){if(this.suppressionActive)return;this.suppressionActive=!0,this.docPointerMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docPointerDownSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docTouchMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docTouchStartSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docMouseMoveSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},this.docMouseDownSuppress=t=>{this.suppressionActive&&(t.stopImmediatePropagation(),t.cancelable&&t.preventDefault())},document.addEventListener("pointermove",this.docPointerMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("pointerdown",this.docPointerDownSuppress,{capture:!0,passive:!1}),document.addEventListener("touchmove",this.docTouchMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("touchstart",this.docTouchStartSuppress,{capture:!0,passive:!1}),document.addEventListener("mousemove",this.docMouseMoveSuppress,{capture:!0,passive:!1}),document.addEventListener("mousedown",this.docMouseDownSuppress,{capture:!0,passive:!1});try{let t=e,l=typeof t.screenX=="number"?t.screenX:e.clientX,d=typeof t.screenY=="number"?t.screenY:e.clientY;if(e.pointerType==="mouse"){let g=new PointerEvent("pointerup",{bubbles:!0,cancelable:!0,pointerId:e.pointerId,pointerType:e.pointerType,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d});e.target.dispatchEvent(g);let C=new MouseEvent("mouseup",{bubbles:!0,cancelable:!0,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d,button:0});e.target.dispatchEvent(C)}else if(e.pointerType==="touch"){let g=new PointerEvent("pointercancel",{bubbles:!0,cancelable:!0,pointerId:e.pointerId,pointerType:e.pointerType,clientX:e.clientX,clientY:e.clientY,screenX:l,screenY:d});e.target.dispatchEvent(g);try{let C=new TouchEvent("touchcancel",{bubbles:!0,cancelable:!0});e.target.dispatchEvent(C)}catch{}}}catch{}let i=t=>{t instanceof PointerEvent&&this.pointerId!==null&&t.pointerId!==this.pointerId||(this.removeSuppression(),document.removeEventListener("pointerup",i,!0),document.removeEventListener("pointercancel",i,!0),document.removeEventListener("touchend",i,!0),document.removeEventListener("touchcancel",i,!0))};document.addEventListener("pointerup",i,!0),document.addEventListener("pointercancel",i,!0),document.addEventListener("touchend",i,!0),document.addEventListener("touchcancel",i,!0)}removeSuppression(){this.suppressionActive&&(this.suppressionActive=!1,this.docPointerMoveSuppress&&document.removeEventListener("pointermove",this.docPointerMoveSuppress,!0),this.docPointerDownSuppress&&document.removeEventListener("pointerdown",this.docPointerDownSuppress,!0),this.docTouchMoveSuppress&&document.removeEventListener("touchmove",this.docTouchMoveSuppress,!0),this.docTouchStartSuppress&&document.removeEventListener("touchstart",this.docTouchStartSuppress,!0),this.docMouseMoveSuppress&&document.removeEventListener("mousemove",this.docMouseMoveSuppress,!0),this.docMouseDownSuppress&&document.removeEventListener("mousedown",this.docMouseDownSuppress,!0),this.docPointerMoveSuppress=void 0,this.docPointerDownSuppress=void 0,this.docTouchMoveSuppress=void 0,this.docTouchStartSuppress=void 0,this.docMouseMoveSuppress=void 0,this.docMouseDownSuppress=void 0)}static \u0275fac=function(i){return new(i||a)};static \u0275dir=Q({type:a,selectors:[["","kipGestures",""]],inputs:{swipeMinDistance:[1,"swipeMinDistance"],swipeMaxDuration:[1,"swipeMaxDuration"],longPressMs:[1,"longPressMs"],doubleTapInterval:[1,"doubleTapInterval"],tapSlop:[1,"tapSlop"],pressMoveSlop:[1,"pressMoveSlop"]},outputs:{swipeleft:"swipeleft",swiperight:"swiperight",swipeup:"swipeup",swipedown:"swipedown",press:"press",doubletap:"doubletap"}})}return a})();var ls=(()=>{class a{_settings=m(Ut);_router=m(da);dashboards=D([],{equal:bi});activeDashboard=D(0);_widgetAction=new kt(null);widgetAction$=this._widgetAction.asObservable();_isDashboardStatic=new kt(!0);isDashboardStatic$=this._isDashboardStatic.asObservable();isDashboardStatic=ra(this.isDashboardStatic$);blankDashboard=[{id:null,name:"Dashboard 1",configuration:[{w:12,h:12,id:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc",selector:"widget-tutorial",input:{widgetProperties:{type:"widget-tutorial",uuid:"d1d58e6f-f8b4-4a72-9597-7f92aa6776fc"}},x:0,y: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=this.blankDashboard.map(t=>he(re({},t),{id:rt.create()}));this.dashboards.set([...i])}else this.dashboards.set(this._settings.getDashboardConfig());ft(()=>{this._settings.saveDashboards(this.dashboards())})}toggleStaticDashboard(){this._isDashboardStatic.next(!this._isDashboardStatic.value)}add(e,i){this.dashboards.update(t=>[...t,{id:rt.create(),name:e,configuration:i}])}update(e,i){this.dashboards.update(t=>t.map((l,d)=>d===e?he(re({},l),{name:i}):l))}delete(e){this.dashboards.update(i=>i.filter((t,l)=>l!==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,i){if(e<0||e>=this.dashboards().length){console.error(`[Dashboard Service] Invalid itemIndex: ${e}`);return}let t=this.dashboards()[e],l=Qt(t);l.id=rt.create(),l.name=i,Array.isArray(l.configuration)?l.configuration.forEach(d=>{d&&d.input?.widgetProperties?(d.id=rt.create(),d.input.widgetProperties.uuid=d.id):console.error("Dashboard Service] Widget configuration is missing required properties:",d)}):(console.error("Dashboard Service] Dashboard configuration is not an array:",l.configuration),l.configuration=[]),this.dashboards.update(d=>[...d,l])}updateConfiguration(e,i){this.dashboards.update(t=>t.map((l,d)=>d===e?bi(l.configuration,i)?l:he(re({},l),{configuration:i}):l))}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)}setActiveDashboard(e){e>=0&&e<this.dashboards().length?this.activeDashboard.set(e):console.error(`[Dashboard Service] Invalid dashboard ID: ${e}`)}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"})}setStaticDashboard(e){this._isDashboardStatic.next(e)}static \u0275fac=function(i){return new(i||a)};static \u0275prov=fe({token:a,factory:a.\u0275fac,providedIn:"root"})}return a})();function Ko(a,s){a&1&&Yi(0)}var go=(()=>{class a{data=m(ze);static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["dialog-frame"]],decls:8,vars:3,consts:[[1,"dialogue-header"],["mat-dialog-title",""],["mat-icon-button","",1,"dialog-close-icon",3,"mat-dialog-close"],[1,"dialog-content-padding"],[4,"ngComponentOutlet"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"h6",1),r(2),o(),n(3,"button",2)(4,"mat-icon"),r(5,"close"),o()()(),n(6,"mat-dialog-content",3),Te(7,Ko,1,0,"ng-container",4),o()),i&2&&(c(2),k(t.data.title),c(),p("mat-dialog-close",!1),c(4),p("ngComponentOutlet",t.data.componentType))},dependencies:[ee,xe,je,Ye,He,ce,se,ta],styles:[".dialogue-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline}.dialog-close-icon[_ngcontent-%COMP%]{margin-right:15px}.mat-mdc-dialog-content[_ngcontent-%COMP%]{max-height:max-content}.dialog-content-padding[_ngcontent-%COMP%]{--mat-dialog-content-padding: 0px 24px 20px 24px}"]})}return a})();function Jo(a,s){if(a&1&&(n(0,"button",4),r(1),o()),a&2){let e=f();p("mat-dialog-close",!0),c(),k(e.data.confirmBtnText)}}var ho=(()=>{class a{data=m(ze);static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["dialog-confirmation"]],decls:12,vars:6,consts:[[1,"dialogue-header"],["mat-dialog-title",""],["mat-icon-button","",1,"dialog-close-icon",3,"mat-dialog-close"],["align","end"],["mat-flat-button","",3,"mat-dialog-close"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"h5",1),r(2),o(),n(3,"button",2)(4,"mat-icon"),r(5,"close"),o()()(),n(6,"mat-dialog-content"),r(7),o(),n(8,"mat-dialog-actions",3)(9,"button",4),r(10),o(),u(11,Jo,2,2,"button",4),o()),i&2&&(c(2),k(t.data.title),c(),p("mat-dialog-close",!1),c(4),U(" ",t.data.message,`
2
2
  `),c(2),p("mat-dialog-close",!1),c(),k(t.data.cancelBtnText),c(),A(t.data.confirmBtnText?11:-1))},dependencies:[ee,xe,je,Ye,Ct,He,ce,Qe,se],styles:[".dialogue-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline}.dialog-close-icon[_ngcontent-%COMP%]{margin-right:15px}.mat-mdc-dialog-content[_ngcontent-%COMP%]{max-height:max-content}"]})}return a})();function $o(a,s){if(a&1&&(n(0,"button",9),r(1),o()),a&2){let e=f(),i=Ae(1);p("disabled",!i.valid),c(),k(e.data.confirmBtnText)}}var bo=(()=>{class a{dialogRef=m(qe);data=m(ze);saveName(){this.dialogRef.close(this.data)}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["dialog-name"]],decls:19,vars:6,consts:[["name","ngForm"],["name","name",3,"ngSubmit"],[1,"dialogue-header"],["mat-dialog-title",""],["mat-icon-button","",1,"dialog-close-icon",3,"mat-dialog-close"],[1,"field-margin"],["matInput","","type","text","id","name","placeholder","Name","name","name","required","","cdkFocusInitial","",3,"ngModelChange","ngModel"],["align","end"],["mat-flat-button","",3,"mat-dialog-close"],["mat-flat-button","","type","submit",3,"disabled"]],template:function(i,t){if(i&1){let l=P();n(0,"form",1,0),_("ngSubmit",function(){return M(l),w(t.saveName())}),n(2,"div",2)(3,"h5",3),r(4),o(),n(5,"button",4)(6,"mat-icon"),r(7,"close"),o()()(),n(8,"mat-dialog-content")(9,"mat-form-field",5)(10,"mat-label"),r(11,"Name"),o(),n(12,"input",6),Ki("ngModelChange",function(g){return M(l),Xi(t.data.name,g)||(t.data.name=g),w(g)}),o(),n(13,"mat-error"),r(14," A name is required "),o()()(),n(15,"mat-dialog-actions",7)(16,"button",8),r(17),o(),u(18,$o,2,2,"button",9),o()()}i&2&&(c(4),k(t.data.title),c(),p("mat-dialog-close",!1),c(7),Zi("ngModel",t.data.name),c(4),p("mat-dialog-close",!1),c(),k(t.data.cancelBtnText),c(),A(t.data.confirmBtnText?18:-1))},dependencies:[xe,je,Ye,Ct,He,Ce,ee,we,R,V,ei,Ke,oe,ce,Qe,se,ae,Jt,te,F,ie,L,Qa,Wa],styles:[".dialogue-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:baseline}.dialog-close-icon[_ngcontent-%COMP%]{margin-right:15px}.mat-mdc-dialog-content[_ngcontent-%COMP%]{max-height:max-content}.field-margin[_ngcontent-%COMP%]{margin-left:15px;margin-bottom:15px}"]})}return a})();function en(a,s){if(a&1&&(n(0,"mat-option",12),r(1),o()),a&2){let e=s.$implicit;p("value",Ee(e.value)),c(),k(e.label)}}function tn(a,s){if(a&1){let e=P();n(0,"button",21),_("click",function(){M(e);let t=f();return w(t.moveCtrlUp())}),n(1,"mat-icon"),r(2,"arrow_drop_up"),o()()}}function an(a,s){if(a&1){let e=P();n(0,"button",22),_("click",function(){M(e);let t=f();return w(t.moveCtrlDown())}),n(1,"mat-icon"),r(2,"arrow_drop_down"),o()()}}var _o=(()=>{class a{app=m(bt);ctrlFormGroup=h.required();controlIndex=h(void 0);arrayLength=h(void 0);deleteCtrl=K();moveUp=K();moveDown=K();colors=[];ngOnInit(){this.colors=this.app.configurableThemeColors}deleteControl(){let e={ctrlIndex:this.controlIndex(),pathID:this.ctrlFormGroup().get("pathID").value};this.deleteCtrl.emit(e)}moveCtrlUp(){this.moveUp.emit(this.controlIndex())}moveCtrlDown(){this.moveDown.emit(this.controlIndex())}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["boolean-control-config"]],inputs:{ctrlFormGroup:[1,"ctrlFormGroup"],controlIndex:[1,"controlIndex"],arrayLength:[1,"arrayLength"]},outputs:{deleteCtrl:"deleteCtrl",moveUp:"moveUp",moveDown:"moveDown"},decls:36,vars:3,consts:[[1,"ctrl-grid","rounded-card","rounded-card-color",3,"formGroup"],[1,"controls","flex-container"],[1,"flex-label"],[1,"full-width"],["matInput","","type","string","placeholder","Enter a display label...","formControlName","ctrlLabel"],[1,"flex-settings"],[1,"settings"],["placeholder","Select Type...","formControlName","type","name","type","required",""],["value","1"],["value","2"],["value","3"],["placeholder","Select Color...","formControlName","color","name","color","required",""],[3,"value"],[1,"flex-full-width"],["formControlName","isNumeric"],[1,"actions"],[1,"flex-actions"],[1,"btn-grid"],["mat-icon-button","","type","button","aria-label","Move control up in the list",1,"up"],["mat-icon-button","","type","button","aria-label","Move control down in the list",1,"down"],["mat-icon-button","","type","button","aria-label","Delete control",1,"delete",3,"click"],["mat-icon-button","","type","button","aria-label","Move control up in the list",1,"up",3,"click"],["mat-icon-button","","type","button","aria-label","Move control down in the list",1,"down",3,"click"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"div",1)(2,"div",2)(3,"mat-form-field",3)(4,"mat-label"),r(5,"Label"),o(),b(6,"input",4),o()(),n(7,"div",5)(8,"mat-form-field",6)(9,"mat-label"),r(10,"Type"),o(),n(11,"mat-select",7)(12,"mat-option",8),r(13,"Toggle"),o(),n(14,"mat-option",9),r(15,"Push"),o(),n(16,"mat-option",10),r(17,"Indicator"),o()()()(),n(18,"div",5)(19,"mat-form-field",6)(20,"mat-label"),r(21,"Color"),o(),n(22,"mat-select",11),y(23,en,2,3,"mat-option",12,I),o()()(),n(25,"div",13)(26,"mat-checkbox",14),r(27," Use numeric path "),o()()(),n(28,"div",15)(29,"div",16)(30,"div",17),u(31,tn,3,0,"button",18),u(32,an,3,0,"button",19),n(33,"button",20),_("click",function(){return t.deleteControl()}),n(34,"mat-icon"),r(35,"delete"),o()()()()()()),i&2&&(p("formGroup",t.ctrlFormGroup()),c(23),x(t.colors),c(8),A(t.controlIndex()!==0?31:-1),c(),A(t.controlIndex()!==t.arrayLength()-1?32:-1))},dependencies:[ae,te,F,ie,L,B,H,Xe,R,V,oe,me,Z,se,$e,Se,Ce,ee],styles:['.ctrl-grid[_ngcontent-%COMP%]{display:grid;width:auto;height:auto;margin:0 0 10px;grid-template-columns:[col-start] calc(100% - 90px) [col1-end] 80px [col2-end];grid-template-areas:"controls actions";row-gap:0px;column-gap:10px;justify-items:center;align-items:center;justify-content:center;align-content:center;padding-top:20px}.controls[_ngcontent-%COMP%]{grid-area:controls;width:100%}.actions[_ngcontent-%COMP%]{grid-area:actions}.btn-grid[_ngcontent-%COMP%]{display:grid;width:80px;height:80px;margin:0;grid-template-columns:[col-start] 50% [col1-end] 50% [col2-end];grid-template-rows:[row-start] 50% [row1-end] 50% [row2-end];grid-template-areas:"up delete" "down delete";row-gap:0px;column-gap:0px;justify-items:center;align-items:center;justify-content:center;align-content:center}.up[_ngcontent-%COMP%]{grid-area:up}.down[_ngcontent-%COMP%]{grid-area:down}.delete[_ngcontent-%COMP%]{grid-area:delete}.flex-label[_ngcontent-%COMP%]{flex-grow:2;flex-shrink:2}.flex-settings[_ngcontent-%COMP%]{flex-grow:1;flex-shrink:1}.settings[_ngcontent-%COMP%]{min-width:100px}.flex-actions[_ngcontent-%COMP%]{flex-grow:0;flex-shrink:0}.flex-full-width[_ngcontent-%COMP%]{width:100%}']})}return a})();function on(a,s){if(a&1){let e=P();n(0,"boolean-control-config",4),_("moveUp",function(t){M(e);let l=f();return w(l.moveUp(t))})("moveDown",function(t){M(e);let l=f();return w(l.moveDown(t))})("deleteCtrl",function(t){M(e);let l=f();return w(l.deletePath(t))}),o()}if(a&2){let e=s.$implicit,i=s.$index,t=f();p("ctrlFormGroup",t.getFormGroup(e))("controlIndex",i)("arrayLength",t.arrayLength)}}var vo=(()=>{class a{fb=m(xt);multiCtrlArray=h.required();addPath=K();updatePath=K();delPath=K();multiFormGroup=null;arrayLength=0;multiCtrlArraySubscription=null;ngOnInit(){this.arrayLength=this.multiCtrlArray().length,this.multiFormGroup=new Ra({multiCtrlArray:this.multiCtrlArray()}),this.multiCtrlArraySubscription=this.multiCtrlArray().valueChanges.pipe(Bt(350)).subscribe(e=>{this.updatePath.emit(e)})}addCtrlGroup(){let e=rt.create();this.multiCtrlArray().push(this.fb.group({ctrlLabel:[null,Y.required],type:["1",Y.required],pathID:[e],color:["contrast"],isNumeric:[!1],value:[null]})),this.arrayLength=this.multiCtrlArray().length;let i={path:{description:null,path:null,pathID:e,source:"default",pathType:"boolean",supportsPut:!0,isPathConfigurable:!0,showPathSkUnitsFilter:!1,pathSkUnitsFilter:null,convertUnitTo:null,sampleTime:500},ctrlType:1};this.addPath.emit(i)}moveUp(e){let i=this.multiCtrlArray().at(e);this.multiCtrlArray().removeAt(e,{emitEvent:!1}),this.multiCtrlArray().insert(e-1,i,{emitEvent:!1})}moveDown(e){let i=this.multiCtrlArray().at(e);this.multiCtrlArray().removeAt(e,{emitEvent:!1}),this.multiCtrlArray().insert(e+1,i,{emitEvent:!1})}deletePath(e){this.delPath.emit(e),this.arrayLength=this.multiCtrlArray().length}getFormGroup(e){return e}ngOnDestroy(){this.multiCtrlArraySubscription?.unsubscribe()}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["boolean-multicontrol-options"]],inputs:{multiCtrlArray:[1,"multiCtrlArray"]},outputs:{addPath:"addPath",updatePath:"updatePath",delPath:"delPath"},decls:7,vars:1,consts:[[3,"formGroup"],["formArrayName","multiCtrlArray"],[1,"full-width",3,"ctrlFormGroup","controlIndex","arrayLength"],["type","button","mat-mini-fab","","color","primary","aria-label","Add control down in the list",1,"add-btn",3,"click"],[1,"full-width",3,"moveUp","moveDown","deleteCtrl","ctrlFormGroup","controlIndex","arrayLength"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"div",1),y(2,on,1,3,"boolean-control-config",2,Rt),n(4,"button",3),_("click",function(){return t.addCtrlGroup()}),n(5,"mat-icon"),r(6,"add"),o()()()()),i&2&&(p("formGroup",t.multiFormGroup),c(2),x(t.multiCtrlArray().controls))},dependencies:[ae,ie,B,H,za,_o,ce,xa,Ce,ee],styles:["[_nghost-%COMP%]{display:block;width:100%;height:100%;padding-top:15px;padding-bottom:15px}.add-btn[_ngcontent-%COMP%]{margin-left:calc(50% - 20px)}"]})}return a})();var nn=["*"];var rn=new J("MAT_CARD_CONFIG"),lc=(()=>{class a{appearance;constructor(){let e=m(rn,{optional:!0});this.appearance=e?.appearance||"raised"}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["mat-card"]],hostAttrs:[1,"mat-mdc-card","mdc-card"],hostVars:8,hostBindings:function(i,t){i&2&&W("mat-mdc-card-outlined",t.appearance==="outlined")("mdc-card--outlined",t.appearance==="outlined")("mat-mdc-card-filled",t.appearance==="filled")("mdc-card--filled",t.appearance==="filled")},inputs:{appearance:"appearance"},exportAs:["matCard"],ngContentSelectors:nn,decls:1,vars:0,template:function(i,t){i&1&&(ve(),X(0))},styles:[`.mat-mdc-card{display:flex;flex-direction:column;box-sizing:border-box;position:relative;border-style:solid;border-width:0;background-color:var(--mat-card-elevated-container-color, var(--mat-sys-surface-container-low));border-color:var(--mat-card-elevated-container-color, var(--mat-sys-surface-container-low));border-radius:var(--mat-card-elevated-container-shape, var(--mat-sys-corner-medium));box-shadow:var(--mat-card-elevated-container-elevation, var(--mat-sys-level1))}.mat-mdc-card::after{position:absolute;top:0;left:0;width:100%;height:100%;border:solid 1px rgba(0,0,0,0);content:"";display:block;pointer-events:none;box-sizing:border-box;border-radius:var(--mat-card-elevated-container-shape, var(--mat-sys-corner-medium))}.mat-mdc-card-outlined{background-color:var(--mat-card-outlined-container-color, var(--mat-sys-surface));border-radius:var(--mat-card-outlined-container-shape, var(--mat-sys-corner-medium));border-width:var(--mat-card-outlined-outline-width, 1px);border-color:var(--mat-card-outlined-outline-color, var(--mat-sys-outline-variant));box-shadow:var(--mat-card-outlined-container-elevation, var(--mat-sys-level0))}.mat-mdc-card-outlined::after{border:none}.mat-mdc-card-filled{background-color:var(--mat-card-filled-container-color, var(--mat-sys-surface-container-highest));border-radius:var(--mat-card-filled-container-shape, var(--mat-sys-corner-medium));box-shadow:var(--mat-card-filled-container-elevation, var(--mat-sys-level0))}.mdc-card__media{position:relative;box-sizing:border-box;background-repeat:no-repeat;background-position:center;background-size:cover}.mdc-card__media::before{display:block;content:""}.mdc-card__media:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}.mdc-card__media:last-child{border-bottom-left-radius:inherit;border-bottom-right-radius:inherit}.mat-mdc-card-actions{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:52px;padding:8px}.mat-mdc-card-title{font-family:var(--mat-card-title-text-font, var(--mat-sys-title-large-font));line-height:var(--mat-card-title-text-line-height, var(--mat-sys-title-large-line-height));font-size:var(--mat-card-title-text-size, var(--mat-sys-title-large-size));letter-spacing:var(--mat-card-title-text-tracking, var(--mat-sys-title-large-tracking));font-weight:var(--mat-card-title-text-weight, var(--mat-sys-title-large-weight))}.mat-mdc-card-subtitle{color:var(--mat-card-subtitle-text-color, var(--mat-sys-on-surface));font-family:var(--mat-card-subtitle-text-font, var(--mat-sys-title-medium-font));line-height:var(--mat-card-subtitle-text-line-height, var(--mat-sys-title-medium-line-height));font-size:var(--mat-card-subtitle-text-size, var(--mat-sys-title-medium-size));letter-spacing:var(--mat-card-subtitle-text-tracking, var(--mat-sys-title-medium-tracking));font-weight:var(--mat-card-subtitle-text-weight, var(--mat-sys-title-medium-weight))}.mat-mdc-card-title,.mat-mdc-card-subtitle{display:block;margin:0}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle{padding:16px 16px 0}.mat-mdc-card-header{display:flex;padding:16px 16px 0}.mat-mdc-card-content{display:block;padding:0 16px}.mat-mdc-card-content:first-child{padding-top:16px}.mat-mdc-card-content:last-child{padding-bottom:16px}.mat-mdc-card-title-group{display:flex;justify-content:space-between;width:100%}.mat-mdc-card-avatar{height:40px;width:40px;border-radius:50%;flex-shrink:0;margin-bottom:16px;object-fit:cover}.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-avatar~.mat-mdc-card-header-text .mat-mdc-card-title{line-height:normal}.mat-mdc-card-sm-image{width:80px;height:80px}.mat-mdc-card-md-image{width:112px;height:112px}.mat-mdc-card-lg-image{width:152px;height:152px}.mat-mdc-card-xl-image{width:240px;height:240px}.mat-mdc-card-subtitle~.mat-mdc-card-title,.mat-mdc-card-title~.mat-mdc-card-subtitle,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-title,.mat-mdc-card-header .mat-mdc-card-header-text .mat-mdc-card-subtitle,.mat-mdc-card-title-group .mat-mdc-card-title,.mat-mdc-card-title-group .mat-mdc-card-subtitle{padding-top:0}.mat-mdc-card-content>:last-child:not(.mat-mdc-card-footer){margin-bottom:0}.mat-mdc-card-actions-align-end{justify-content:flex-end}
3
3
  `],encapsulation:2,changeDetection:0})}return a})();var Co=(()=>{class a{static \u0275fac=function(i){return new(i||a)};static \u0275mod=_e({type:a});static \u0275inj=be({imports:[$,$]})}return a})();function ln(a,s){if(a&1&&(n(0,"mat-option",8),r(1),o()),a&2){let e=s.$implicit;p("value",Ee(e.value)),c(),k(e.label)}}var yo=(()=>{class a{app=m(bt);displayName=h.required();showLabel=h.required();convertUnitTo=h.required();datasetUUID=h.required();datasetAverageArray=h.required();showAverageData=h.required();trackAgainstAverage=h.required();showDatasetMinimumValueLine=h.required();showDatasetMaximumValueLine=h.required();showDatasetAverageValueLine=h.required();showDatasetAngleAverageValueLine=h.required();verticalChart=h.required();inverseYAxis=h.required();showTimeScale=h.required();showYScale=h.required();startScaleAtZero=h.required();yScaleSuggestedMin=h.required();yScaleSuggestedMax=h.required();enableMinMaxScaleLimit=h.required();yScaleMin=h.required();yScaleMax=h.required();numDecimal=h.required();color=h.required();colors=[];ngOnInit(){this.colors=this.app.configurableThemeColors,this.showAverageData()&&!this.showAverageData()?.value&&this.trackAgainstAverage().disable(),this.enableMinMaxScaleLimit()&&this.setValueScaleOptionsControls(this.enableMinMaxScaleLimit().value)}setValueScaleOptionsControls(e){e?(this.yScaleMin()?.enable(),this.yScaleMax()?.enable(),this.yScaleSuggestedMin()?.disable(),this.yScaleSuggestedMax()?.disable()):(this.yScaleMin()?.disable(),this.yScaleMax()?.disable(),this.yScaleSuggestedMin()?.enable(),this.yScaleSuggestedMax()?.enable())}setScaleControls(e){this.setValueScaleOptionsControls(e.value)}enableTrackAgainstMovingAverage(e){e.checked?this.trackAgainstAverage().enable():(this.trackAgainstAverage().setValue(e.checked),this.trackAgainstAverage().disable())}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["config-display-chart-options"]],inputs:{displayName:[1,"displayName"],showLabel:[1,"showLabel"],convertUnitTo:[1,"convertUnitTo"],datasetUUID:[1,"datasetUUID"],datasetAverageArray:[1,"datasetAverageArray"],showAverageData:[1,"showAverageData"],trackAgainstAverage:[1,"trackAgainstAverage"],showDatasetMinimumValueLine:[1,"showDatasetMinimumValueLine"],showDatasetMaximumValueLine:[1,"showDatasetMaximumValueLine"],showDatasetAverageValueLine:[1,"showDatasetAverageValueLine"],showDatasetAngleAverageValueLine:[1,"showDatasetAngleAverageValueLine"],verticalChart:[1,"verticalChart"],inverseYAxis:[1,"inverseYAxis"],showTimeScale:[1,"showTimeScale"],showYScale:[1,"showYScale"],startScaleAtZero:[1,"startScaleAtZero"],yScaleSuggestedMin:[1,"yScaleSuggestedMin"],yScaleSuggestedMax:[1,"yScaleSuggestedMax"],enableMinMaxScaleLimit:[1,"enableMinMaxScaleLimit"],yScaleMin:[1,"yScaleMin"],yScaleMax:[1,"yScaleMax"],numDecimal:[1,"numDecimal"],color:[1,"color"]},decls:84,vars:20,consts:[["minLine",""],[1,"tab-content"],[1,"chart-flex-container"],[1,"chart-panel-group"],[1,"full-width"],["matInput","","placeholder","Enter a label to display","name","displayName",3,"formControl"],["name","showLabel",1,"full-width",3,"formControl"],["placeholder","Select Color...","name","color","required","",3,"formControl"],[3,"value"],[1,"flex-item-rounded-card","rounded-card-color"],[2,"margin-left","10px"],["matInput","","type","number","min","0","max","5","placeholder","Enter or select number...","name","numDecimal","required","",3,"formControl"],["name","showAverageData",1,"full-width",2,"margin-top","10px",3,"change","formControl"],["name","trackAgainstAverage",1,"full-width",2,"margin-left","25px",3,"formControl"],["name","verticalChart",3,"formControl"],[1,"no-margin"],[1,"mat-caption"],["aria-label","Select an option","name","enableMinMaxScaleLimit",1,"chart-option-radio-group",3,"formControl"],[1,"chart-option-radio-button",3,"change","value"],[1,"chart-option-radio-button-config"],[1,"chart-option-radio-button-config-form-field"],["matInput","","type","number","name","yScaleSuggestedMin",3,"formControl"],["matInput","","type","number","name","yScaleSuggestedMax",3,"formControl"],[1,"chart-option-radio-button-config-item"],["matInput","","type","number","name","yScaleMin","required","",3,"formControl"],["matInput","","type","number","name","yScaleMax","required","",3,"formControl"],["name","showYScale",1,"full-width",3,"formControl"],["name","inverseYAxis",3,"formControl"],["name","showTimeScale",1,"full-width",3,"formControl"],["name","showDatasetMaximumValueLine",1,"full-width",3,"formControl"],["name","showDatasetAverageValueLine",1,"full-width",3,"formControl"],["name","showDatasetMinimumValueLine",1,"full-width",3,"formControl"]],template:function(i,t){if(i&1){let l=P();n(0,"div",1)(1,"div",2)(2,"div",3)(3,"mat-form-field",4)(4,"mat-label"),r(5,"Widget Label"),o(),b(6,"input",5),o()(),n(7,"div",3)(8,"mat-checkbox",6),r(9," Show Label "),o()()(),n(10,"div",2)(11,"mat-form-field",4)(12,"mat-label"),r(13,"Color"),o(),n(14,"mat-select",7),y(15,ln,2,3,"mat-option",8,I),o()()(),n(17,"div",2)(18,"div",9)(19,"div")(20,"p"),r(21,"Series"),o(),n(22,"mat-form-field",10)(23,"mat-label"),r(24,"Value Decimal Places"),o(),b(25,"input",11),o(),n(26,"mat-checkbox",12),_("change",function(g){return M(l),w(t.enableTrackAgainstMovingAverage(g))}),r(27," Display Moving Average "),o(),n(28,"mat-checkbox",13),r(29," Track Against Moving Average "),o()(),n(30,"mat-checkbox",14),r(31," Vertical Data Graph "),o()(),n(32,"div",9)(33,"div")(34,"p",15),r(35,"Data Scale"),o(),n(36,"span",16),r(37,"(Default node is automatic scale)"),o(),n(38,"mat-radio-group",17)(39,"mat-radio-button",18),_("change",function(g){return M(l),w(t.setScaleControls(g))}),r(40,"Auto Scale"),o(),n(41,"div",19)(42,"mat-form-field",20)(43,"mat-label"),r(44,"Suggested Min"),o(),b(45,"input",21),o(),n(46,"mat-form-field",20)(47,"mat-label"),r(48,"Suggested Max"),o(),b(49,"input",22),o()(),n(50,"mat-radio-button",18),_("change",function(g){return M(l),w(t.setScaleControls(g))}),r(51," Fixed Scale "),o(),n(52,"div",19)(53,"div",23)(54,"mat-form-field",20)(55,"mat-label"),r(56,"Min"),o(),b(57,"input",24),o()(),n(58,"div",23)(59,"mat-form-field",20)(60,"mat-label"),r(61,"Max"),o(),b(62,"input",25),o()()()(),n(63,"mat-checkbox",26),r(64," Show Scale Ticks "),o(),n(65,"mat-checkbox",27),r(66," Inverse Scale "),o()()(),n(67,"div",9)(68,"div")(69,"p",15),r(70,"Time Scale"),o(),n(71,"mat-checkbox",28),r(72," Show Scale Ticks "),o()()(),n(73,"div",9)(74,"div")(75,"p",15),r(76,"Dataset"),o(),n(77,"mat-checkbox",29),r(78," Show Maximum Line "),o(),n(79,"mat-checkbox",30),r(80," Show Average Line "),o(),n(81,"mat-checkbox",31,0),r(83," Show Minimum Line "),o()()()()()}i&2&&(c(6),p("formControl",t.displayName()),c(2),p("formControl",t.showLabel()),c(6),p("formControl",t.color()),c(),x(t.colors),c(10),p("formControl",t.numDecimal()),c(),p("formControl",t.showAverageData()),c(2),p("formControl",t.trackAgainstAverage()),c(2),p("formControl",t.verticalChart()),c(8),p("formControl",t.enableMinMaxScaleLimit()),c(),p("value",!1),c(6),p("formControl",t.yScaleSuggestedMin()),c(4),p("formControl",t.yScaleSuggestedMax()),c(),p("value",!0),c(7),p("formControl",t.yScaleMin()),c(5),p("formControl",t.yScaleMax()),c(),p("formControl",t.showYScale()),c(2),p("formControl",t.inverseYAxis()),c(6),p("formControl",t.showTimeScale()),c(6),p("formControl",t.showDatasetMaximumValueLine()),c(2),p("formControl",t.showDatasetAverageValueLine()),c(2),p("formControl",t.showDatasetMinimumValueLine()))},dependencies:[Co,we,R,V,$e,Se,Je,me,Z,It,Ke,oe,no,ao,oo,B,te,Ze,F,L,yt,$t,Me],styles:[".chart-flex-container[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;margin:15px 0;gap:15px;align-items:stretch}.chart-panel-group[_ngcontent-%COMP%]{min-width:250px;flex-grow:1}.no-margin[_ngcontent-%COMP%]{margin:0}.chart-option-radio-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:0;align-items:flex-start}.chart-option-radio-button[_ngcontent-%COMP%]{margin:0}.chart-option-radio-button-config[_ngcontent-%COMP%]{margin-left:35px;display:flex;flex-direction:row;flex-wrap:wrap;gap:10px;align-items:flex-start}.chart-option-radio-button-config-item[_ngcontent-%COMP%]{flex-grow:0;flex-shrink:1;min-width:50px}.chart-option-radio-button-config-form-field[_ngcontent-%COMP%]{display:block;max-width:118px}"]})}return a})();var sn=(a,s)=>s.uuid;function cn(a,s){if(a&1&&(n(0,"mat-option",4),r(1),o()),a&2){let e=s.$implicit;p("value",e.uuid),c(),U(" ",e.label," ")}}function dn(a,s){if(a&1&&(n(0,"mat-option",4),r(1),o()),a&2){let e=s.$implicit;p("value",e.measure),c(),U(" ",e.description," ")}}function mn(a,s){if(a&1&&(n(0,"mat-optgroup",6),y(1,dn,2,2,"mat-option",4,I),o()),a&2){let e=s.$implicit;p("label",e.group),c(),x(e.units)}}var xo=(()=>{class a{datasetService=m(ii);units=m(St);datasetUUID=h.required();convertUnitTo=h.required();availableDataSets=[];unitList={};ngOnInit(){this.availableDataSets=this.datasetService.list().filter(i=>i.editable!==!1).sort();let e=this.datasetUUID();e.value&&this.setPathUnits(e.value)}setPathUnits(e){let i=this.datasetService.getDatasetConfig(e);return e&&i?(this.unitList=this.units.getConversionsForPath(i.path),this.convertUnitTo()?.enable(),!0):(this.unitList=this.units.getConversionsForPath(""),this.convertUnitTo()?.disable(),!1)}datasetChanged(e){this.setPathUnits(e.value)}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["config-dataset-chart-options"]],inputs:{datasetUUID:[1,"datasetUUID"],convertUnitTo:[1,"convertUnitTo"]},decls:14,vars:2,consts:[[1,"display-content","tab-content"],[1,"widget-options-grid"],[1,"options-grid-span2"],["placeholder","Select dataset...","name","datasetUUID","required","",3,"selectionChange","formControl"],[3,"value"],["placeholder","Select unit...","name","convertUnitTo","required","",3,"formControl"],[3,"label"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"div",1)(2,"mat-form-field",2)(3,"mat-label"),r(4,"Dataset"),o(),n(5,"mat-select",3),_("selectionChange",function(d){return t.datasetChanged(d)}),y(6,cn,2,2,"mat-option",4,sn),o()(),n(8,"mat-form-field",2)(9,"mat-label"),r(10,"Display Format"),o(),n(11,"mat-select",5),y(12,mn,3,1,"mat-optgroup",6,I),o()()()()),i&2&&(c(5),p("formControl",t.datasetUUID()),c(),x(t.availableDataSets),c(5),p("formControl",t.convertUnitTo()),c(),x(t.unitList.conversions))},dependencies:[we,R,V,Je,me,Z,wt,B,F,L,Me],styles:[".display-content[_ngcontent-%COMP%]{display:block;height:100%;width:100%;padding-top:15px;padding-bottom:10px}"]})}return a})();var Mo=(()=>{class a{transform(e){return Object.keys(e)}static \u0275fac=function(i){return new(i||a)};static \u0275pipe=Ui({name:"objectKeys",type:a,pure:!0})}return a})();var un=["panel"],An=["*"];function gn(a,s){if(a&1&&(hi(0,"div",1,0),X(2),fi()),a&2){let e=s.id,i=f();gt(i._classList),W("mat-mdc-autocomplete-visible",i.showPanel)("mat-mdc-autocomplete-hidden",!i.showPanel)("mat-autocomplete-panel-animations-enabled",!i._animationsDisabled)("mat-primary",i._color==="primary")("mat-accent",i._color==="accent")("mat-warn",i._color==="warn"),Hi("id",i.id),q("aria-label",i.ariaLabel||null)("aria-labelledby",i._getPanelAriaLabelledby(e))}}var Ti=class{source;option;constructor(s,e){this.source=s,this.option=e}},ko=new J("mat-autocomplete-default-options",{providedIn:"root",factory:hn});function hn(){return{autoActiveFirstOption:!1,autoSelectActiveOption:!1,hideSingleSelectionIndicator:!1,requireSelection:!1,hasBackdrop:!1}}var si=(()=>{class a{_changeDetectorRef=m(nt);_elementRef=m(pe);_defaults=m(ko);_animationsDisabled=ye();_activeOptionChanges=lt.EMPTY;_keyManager;showPanel=!1;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=!1;_latestOpeningTrigger;_setColor(e){this._color=e,this._changeDetectorRef.markForCheck()}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple;optionSelected=new le;opened=new le;closed=new le;optionActivated=new le;set classList(e){this._classList=e,this._elementRef.nativeElement.className=""}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties()}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck()}id=m(Dt).getId("mat-autocomplete-");inertGroups;constructor(){let e=m(qt);this.inertGroups=e?.SAFARI||!1,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??!1}ngAfterContentInit(){this._keyManager=new _a(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(e=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[e]||null})}),this._setVisibility()}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe()}_setScrollTop(e){this.panel&&(this.panel.nativeElement.scrollTop=e)}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options?.length,this._changeDetectorRef.markForCheck()}_emitSelectEvent(e){let i=new Ti(this,e);this.optionSelected.emit(i)}_getPanelAriaLabelledby(e){if(this.ariaLabel)return null;let i=e?e+" ":"";return this.ariaLabelledby?i+this.ariaLabelledby:e}_skipPredicate(){return!1}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["mat-autocomplete"]],contentQueries:function(i,t,l){if(i&1&&(ue(l,Z,5),ue(l,Ka,5)),i&2){let d;z(d=j())&&(t.options=d),z(d=j())&&(t.optionGroups=d)}},viewQuery:function(i,t){if(i&1&&(Ve(Ni,7),Ve(un,5)),i&2){let l;z(l=j())&&(t.template=l.first),z(l=j())&&(t.panel=l.first)}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",O],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",O],requireSelection:[2,"requireSelection","requireSelection",O],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",O],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",O]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[Re([{provide:Xa,useExisting:a}])],ngContentSelectors:An,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(i,t){i&1&&(ve(),Qi(0,gn,3,17,"ng-template"))},styles:[`div.mat-mdc-autocomplete-panel{width:100%;max-height:256px;visibility:hidden;transform-origin:center top;overflow:auto;padding:8px 0;box-sizing:border-box;position:relative;border-radius:var(--mat-autocomplete-container-shape, var(--mat-sys-corner-extra-small));box-shadow:var(--mat-autocomplete-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));background-color:var(--mat-autocomplete-background-color, var(--mat-sys-surface-container))}@media(forced-colors: active){div.mat-mdc-autocomplete-panel{outline:solid 1px}}.cdk-overlay-pane:not(.mat-mdc-autocomplete-panel-above) div.mat-mdc-autocomplete-panel{border-top-left-radius:0;border-top-right-radius:0}.mat-mdc-autocomplete-panel-above div.mat-mdc-autocomplete-panel{border-bottom-left-radius:0;border-bottom-right-radius:0;transform-origin:center bottom}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-visible{visibility:visible}div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-hidden{visibility:hidden;pointer-events:none}@keyframes _mat-autocomplete-enter{from{opacity:0;transform:scaleY(0.8)}to{opacity:1;transform:none}}.mat-autocomplete-panel-animations-enabled{animation:_mat-autocomplete-enter 120ms cubic-bezier(0, 0, 0.2, 1)}mat-autocomplete{display:none}
4
4
  `],encapsulation:2,changeDetection:0})}return a})();var fn={provide:Kt,useExisting:Tt(()=>Pt),multi:!0};var To=new J("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{let a=m(Fe);return()=>Ci(a)}});function bn(a){let s=m(Fe);return()=>Ci(s)}var _n={provide:To,deps:[],useFactory:bn},Pt=(()=>{class a{_environmentInjector=m(Ri);_element=m(pe);_injector=m(Fe);_viewContainerRef=m(Wi);_zone=m(ut);_changeDetectorRef=m(nt);_dir=m(Ht,{optional:!0});_formField=m(Ya,{optional:!0,host:!0});_viewportRuler=m(ka);_scrollStrategy=m(To);_renderer=m(gi);_animationsDisabled=ye();_defaults=m(ko,{optional:!0});_overlayRef;_portal;_componentDestroyed=!1;_initialized=new st;_keydownSubscription;_outsideClickSubscription;_cleanupWindowBlur;_previousValue;_valueOnAttach;_valueOnLastKeydown;_positionStrategy;_manuallyFloatingLabel=!1;_closingActionsSubscription;_viewportSubscription=lt.EMPTY;_breakpointObserver=m(jt);_handsetLandscapeSubscription=lt.EMPTY;_canOpenOnNextFocus=!0;_valueBeforeAutoSelection;_pendingAutoselectedOption;_closeKeyEventStream=new st;_overlayPanelClass=ha(this._defaults?.overlayPanelClass||[]);_windowBlurHandler=()=>{this._canOpenOnNextFocus=this.panelOpen||!this._hasFocus()};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled;constructor(){}_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete(),this._cleanupWindowBlur=this._renderer.listen("window","blur",this._windowBlurHandler)}ngOnChanges(e){e.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition())}ngOnDestroy(){this._cleanupWindowBlur?.(),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=!0,this._destroyPanel(),this._closeKeyEventStream.complete(),this._clearFromModal()}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=!1;openPanel(){this._openPanelInternal()}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit()}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=!1,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=!1,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges(),this._trackedModal&&Yt(this._trackedModal,"aria-owns",this.autocomplete.id))}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition()}get panelClosingActions(){return Pe(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe(Oe(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe(Oe(()=>this._overlayAttached)):ui()).pipe(ct(e=>e instanceof Ja?e:null))}optionSelections=Oi(()=>{let e=this.autocomplete?this.autocomplete.options:null;return e?e.changes.pipe(mt(e),Vt(()=>Pe(...e.map(i=>i.onSelectionChange)))):this._initialized.pipe(Vt(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return new pi(e=>{let i=l=>{let d=ua(l),g=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,C=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;this._overlayAttached&&d!==this._element.nativeElement&&!this._hasFocus()&&(!g||!g.contains(d))&&(!C||!C.contains(d))&&this._overlayRef&&!this._overlayRef.overlayElement.contains(d)&&e.next(l)},t=[this._renderer.listen("document","click",i),this._renderer.listen("document","auxclick",i),this._renderer.listen("document","touchend",i)];return()=>{t.forEach(l=>l())}})}writeValue(e){Promise.resolve(null).then(()=>this._assignOptionValue(e))}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){this._element.nativeElement.disabled=e}_handleKeydown(e){let i=e,t=i.keyCode,l=_t(i);if(t===27&&!l&&i.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&t===13&&this.panelOpen&&!l)this.activeOption._selectViaInteraction(),this._resetActiveItem(),i.preventDefault();else if(this.autocomplete){let d=this.autocomplete._keyManager.activeItem,g=t===38||t===40;t===9||g&&!l&&this.panelOpen?this.autocomplete._keyManager.onKeydown(i):g&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(g||this.autocomplete._keyManager.activeItem!==d)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)))}}_handleInput(e){let i=e.target,t=i.value;if(i.type==="number"&&(t=t==""?null:parseFloat(t)),this._previousValue!==t){if(this._previousValue=t,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(t),!t)this._clearPreviousSelectedOption(null,!1);else if(this.panelOpen&&!this.autocomplete.requireSelection){let l=this.autocomplete.options?.find(d=>d.selected);if(l){let d=this._getDisplayValue(l.value);t!==d&&l.deselect(!1)}}if(this._canOpen()&&this._hasFocus()){let l=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(l)}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(!0)):this._canOpenOnNextFocus=!0}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal()}_hasFocus(){return _i()===this._element.nativeElement}_floatLabel(e=!1){this._formField&&this._formField.floatLabel==="auto"&&(e?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=!0)}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=!1)}_subscribeToClosingActions(){let e=new pi(t=>{qi(()=>{t.next()},{injector:this._environmentInjector})}),i=this.autocomplete.options?.changes.pipe(Vi(()=>this._positionStrategy.reapplyLastPosition()),Li(0))??ui();return Pe(e,i).pipe(Vt(()=>this._zone.run(()=>{let t=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),t!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),dt(1)).subscribe(t=>this._setValueAndClose(t))}_emitOpened(){this.autocomplete.opened.emit()}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null)}_getDisplayValue(e){let i=this.autocomplete;return i&&i.displayWith?i.displayWith(e):e}_assignOptionValue(e){let i=this._getDisplayValue(e);e==null&&this._clearPreviousSelectedOption(null,!1),this._updateNativeInputValue(i??"")}_updateNativeInputValue(e){this._formField?this._formField._control.value=e:this._element.nativeElement.value=e,this._previousValue=e}_setValueAndClose(e){let i=this.autocomplete,t=e?e.source:this._pendingAutoselectedOption;t?(this._clearPreviousSelectedOption(t),this._assignOptionValue(t.value),this._onChange(t.value),i._emitSelectEvent(t),this._element.nativeElement.focus()):i.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),this._onChange(null)),this.closePanel()}_clearPreviousSelectedOption(e,i){this.autocomplete?.options?.forEach(t=>{t!==e&&t.selected&&t.deselect(i)})}_openPanelInternal(e=this._element.nativeElement.value){if(this._attachOverlay(e),this._floatLabel(),this._trackedModal){let i=this.autocomplete.id;vi(this._trackedModal,"aria-owns",i)}}_attachOverlay(e){this.autocomplete;let i=this._overlayRef;i?(this._positionStrategy.setOrigin(this._getConnectedElement()),i.updateSize({width:this._getPanelWidth()})):(this._portal=new Ma(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),i=Pa(this._injector,this._getOverlayConfig()),this._overlayRef=i,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&i&&i.updateSize({width:this._getPanelWidth()})}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(De.HandsetLandscape).subscribe(l=>{l.matches?this._positionStrategy.withFlexibleDimensions(!0).withGrowAfterOpen(!0).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(!1).withGrowAfterOpen(!1).withViewportMargin(0)})),i&&!i.hasAttached()&&(i.attach(this._portal),this._valueOnAttach=e,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());let t=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=!0,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this._applyModalPanelOwnership(),this.panelOpen&&t!==this.panelOpen&&this._emitOpened()}_handlePanelKeydown=e=>{(e.keyCode===27&&!_t(e)||e.keyCode===38&&_t(e,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),e.stopPropagation(),e.preventDefault())};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){let e=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=e.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=e.outsidePointerEvents().subscribe())}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=null}_getOverlayConfig(){return new Da({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,hasBackdrop:this._defaults?.hasBackdrop,backdropClass:this._defaults?.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:this._overlayPanelClass,disableAnimations:this._animationsDisabled})}_getOverlayPosition(){let e=Ia(this._injector,this._getConnectedElement()).withFlexibleDimensions(!1).withPush(!1);return this._setStrategyPositions(e),this._positionStrategy=e,e}_setStrategyPositions(e){let i=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],t=this._aboveClass,l=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:t},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:t}],d;this.position==="above"?d=l:this.position==="below"?d=i:d=[...i,...l],e.withPositions(d)}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){let e=this.autocomplete;if(e.autoActiveFirstOption){let i=-1;for(let t=0;t<e.options.length;t++)if(!e.options.get(t).disabled){i=t;break}e._keyManager.setActiveItem(i)}else e._keyManager.setActiveItem(-1)}_canOpen(){let e=this._element.nativeElement;return!e.readOnly&&!e.disabled&&!this.autocompleteDisabled}_scrollToOption(e){let i=this.autocomplete,t=$a(e,i.options,i.optionGroups);if(e===0&&t===1)i._setScrollTop(0);else if(i.panel){let l=i.options.toArray()[e];if(l){let d=l._getHostElement(),g=eo(d.offsetTop,d.offsetHeight,i._getScrollTop(),i.panel.nativeElement.offsetHeight);i._setScrollTop(g)}}}_trackedModal=null;_applyModalPanelOwnership(){let e=this._element.nativeElement.closest('body > .cdk-overlay-container [aria-modal="true"]');if(!e)return;let i=this.autocomplete.id;this._trackedModal&&Yt(this._trackedModal,"aria-owns",i),vi(e,"aria-owns",i),this._trackedModal=e}_clearFromModal(){if(this._trackedModal){let e=this.autocomplete.id;Yt(this._trackedModal,"aria-owns",e),this._trackedModal=null}}static \u0275fac=function(i){return new(i||a)};static \u0275dir=Q({type:a,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(i,t){i&1&&_("focusin",function(){return t._handleFocus()})("blur",function(){return t._onTouched()})("input",function(d){return t._handleInput(d)})("keydown",function(d){return t._handleKeydown(d)})("click",function(){return t._handleClick()}),i&2&&q("autocomplete",t.autocompleteAttribute)("role",t.autocompleteDisabled?null:"combobox")("aria-autocomplete",t.autocompleteDisabled?null:"list")("aria-activedescendant",t.panelOpen&&t.activeOption?t.activeOption.id:null)("aria-expanded",t.autocompleteDisabled?null:t.panelOpen.toString())("aria-controls",t.autocompleteDisabled||!t.panelOpen||t.autocomplete==null?null:t.autocomplete.id)("aria-haspopup",t.autocompleteDisabled?null:"listbox")},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",O]},exportAs:["matAutocompleteTrigger"],features:[Re([fn]),ot]})}return a})(),Eo=(()=>{class a{static \u0275fac=function(i){return new(i||a)};static \u0275mod=_e({type:a});static \u0275inj=be({providers:[_n],imports:[Oa,It,$,Ta,It,$]})}return a})();var Cn=(a,s)=>s.path;function yn(a,s){a&1&&b(0,"i",22)}function xn(a,s){a&1&&b(0,"i",23)}function Mn(a,s){if(a&1&&(n(0,"mat-option",16),r(1),o()),a&2){let e=s.$implicit;p("value",e),c(),ht("",e.properties.quantity,": ",e.properties.display)}}function wn(a,s){if(a&1){let e=P();n(0,"div",5)(1,"mat-form-field",21)(2,"mat-label"),u(3,yn,1,0,"i",22)(4,xn,1,0,"i",23),r(5," Filter"),o(),n(6,"mat-select",24,2),_("selectionChange",function(){M(e),f();let t=Ae(11),l=f();return w(l.pathFormGroup().controls.path.setValue(t.value))}),n(8,"mat-option"),r(9,"All"),o(),y(10,Mn,2,3,"mat-option",16,I),o()()()}if(a&2){let e=Ae(7),i=f(2);c(3),A(e.value?4:3),c(3),p("formControl",i.pathSkUnitsFilterControl),c(4),x(i.pathSkUnitsFiltersList)}}function Sn(a,s){a&1&&(n(0,"span",8),r(1,"(optional)"),o())}function kn(a,s){a&1&&(n(0,"mat-hint"),r(1,"Leave blank to disable this path."),o())}function Tn(a,s){if(a&1){let e=P();n(0,"button",25),_("click",function(){M(e);let t=f(2);return w(t.pathFormGroup().controls.path.setValue(""))}),n(1,"mat-icon"),r(2,"close"),o()()}}function En(a,s){a&1&&(n(0,"mat-error"),r(1," Path is required. Please enter a valid Signal K path. "),o())}function Dn(a,s){a&1&&(n(0,"mat-error"),r(1," Path not recognized. Please enter a path from the server's published list. "),o())}function In(a,s){if(a&1&&(n(0,"span"),r(1),o(),b(2,"br"),n(3,"small",26),r(4),o()),a&2){let e=f().$implicit;c(),k(e.path),c(3),k(e.meta.description)}}function Gn(a,s){if(a&1&&r(0),a&2){let e=f().$implicit;U(" ",e.path," ")}}function Pn(a,s){if(a&1&&(n(0,"mat-option",11),u(1,In,5,2)(2,Gn,1,1),o()),a&2){let e=s.$implicit;p("value",e.path),c(),A(e.meta!==void 0?1:2)}}function On(a,s){if(a&1&&(n(0,"mat-option",16),r(1),o()),a&2){let e=s.$implicit;p("value",e),c(),U(" ",e," ")}}function Fn(a,s){if(a&1&&(n(0,"mat-option",16),r(1),o()),a&2){let e=s.$implicit;p("value",e.measure),c(),U(" ",e.description," ")}}function Ln(a,s){if(a&1&&(n(0,"mat-optgroup",28),y(1,Fn,2,2,"mat-option",16,I),o()),a&2){let e=s.$implicit;p("label",e.group),c(),x(e.units)}}function Bn(a,s){if(a&1&&(n(0,"mat-form-field",20)(1,"mat-label"),r(2,"Display Format"),o(),n(3,"mat-select",27),y(4,Ln,3,1,"mat-optgroup",28,I),o()()),a&2){let e=f(2);c(4),x(e.unitList.conversions)}}function Vn(a,s){if(a&1&&(n(0,"div",3)(1,"div",4)(2,"span"),r(3),o()(),u(4,wn,12,2,"div",5),n(5,"div",6)(6,"mat-form-field",7)(7,"mat-label"),r(8," Signal K Path "),u(9,Sn,2,0,"span",8),o(),b(10,"input",9,0),u(12,kn,2,0,"mat-hint"),u(13,Tn,3,0,"button",10),u(14,En,2,0,"mat-error")(15,Dn,2,0,"mat-error"),n(16,"mat-autocomplete",null,1),y(18,Pn,3,2,"mat-option",11,Cn),Ne(20,"async"),o()()(),n(21,"div",12)(22,"div",13)(23,"mat-form-field",14)(24,"mat-label"),r(25,"Data Source"),o(),n(26,"mat-select",15),y(27,On,2,2,"mat-option",16,I),o()()(),n(29,"div",17)(30,"mat-form-field",14)(31,"mat-label"),r(32,"Sample Time"),o(),b(33,"input",18),o()(),n(34,"div",19),u(35,Bn,6,0,"mat-form-field",20),o()()()),a&2){let e,i=Ae(17),t=f();p("formGroup",t.pathFormGroup()),c(2),Nt("color",t.pathFormGroup().enabled?"":"rgba(255,255,255,0.5)"),c(),k(t.pathFormGroup().value.description),c(),A(t.pathFormGroup().value.pathType==="number"&&t.showPathSkUnitsFilter?4:-1),c(5),A(t.pathFormGroup().value.pathRequired===!1?9:-1),c(),p("matAutocomplete",i),c(2),A(t.pathFormGroup().value.pathRequired===!1?12:-1),c(),A(t.pathFormGroup().value.path?13:-1),c(),A((e=t.pathFormGroup().controls.path.errors)!=null&&e.required?14:(e=t.pathFormGroup().controls.path.errors)!=null&&e.requireMatch?15:-1),c(4),x(We(20,11,t.filteredPaths)),c(9),x(t.availableSources),c(8),A(t.pathFormGroup().value.pathType==="number"&&t.pathFormGroup().value.showConvertUnitTo===void 0||t.pathFormGroup().value.pathType==="number"&&t.pathFormGroup().value.showConvertUnitTo===!0?35:-1)}}function Rn(a){return s=>{let e=s.parent?.value?.pathRequired!==!1,i=s.value;return e?i===null||i===""?{requireMatch:!0}:a().some(d=>d.path===i)?null:{requireMatch:!0}:i===null||i===""||a().some(d=>d.path===i)?null:{requireMatch:!0}}}var Do=(()=>{class a{_data=m(ma);_units=m(St);_connection=m(na);_destroyRef=m(Le);pathFormGroup=h.required();multiCTRLArray=h.required();filterSelfPaths=h.required();availablePaths;filteredPaths=new kt(null);availableSources;unitList={base:"",conversions:[]};showPathSkUnitsFilter=!1;pathSkUnitsFilterControl=new Ua(null);pathSkUnitsFiltersList;unitlessUnit={unit:"unitless",properties:{display:"(null)",quantity:"Unitless",quantityDisplay:"(null)",description:""}};ngOnInit(){let e=this.pathFormGroup();e.controls.path.disabled||(this.pathSkUnitsFiltersList=this._units.skBaseUnits.sort((i,t)=>i.properties.quantity>t.properties.quantity?1:-1),this.pathSkUnitsFiltersList.unshift(this.unitlessUnit),e.value.pathSkUnitsFilter&&this.pathSkUnitsFilterControl.setValue(this.pathSkUnitsFiltersList.find(i=>i.unit===this.pathFormGroup().value.pathSkUnitsFilter),{onlySelf:!0}),e.value.showPathSkUnitsFilter&&(this.showPathSkUnitsFilter=e.value.showPathSkUnitsFilter),e.controls.path.setValidators([Rn(()=>this.getPaths())]),e.controls.path.updateValueAndValidity({onlySelf:!0,emitEvent:!1}),e.controls.pathRequired&&e.controls.pathRequired.valueChanges.pipe(Ue(this._destroyRef)).subscribe(()=>{this.pathFormGroup().controls.path.updateValueAndValidity()}),e.controls.path.valid?this.enableFormFields(!1):this.disablePathFields(),e.controls.sampleTime||(e.addControl("sampleTime",new de("500",Y.required)),e.controls.sampleTime.updateValueAndValidity({onlySelf:!0,emitEvent:!1})),e.controls.path.valueChanges.pipe(Fi(i=>i===""?Ai(0):Ai(350)),mt(""),ct(i=>this.filterPaths(i||""))).pipe(Ue(this._destroyRef)).subscribe(()=>{let i=this.pathFormGroup();i.controls.path.pristine||(i.controls.path.valid?(this.enableFormFields(!0),this.updatePathMetaBoundDisplayName(i.controls.path.value),this.updatePathMetaBoundDisplayScale(i.controls.path.value)):this.disablePathFields())}),e.controls.pathType.valueChanges.pipe(Ue(this._destroyRef)).subscribe(()=>{let i=this.pathFormGroup();i.value.showPathSkUnitsFilter?this.pathSkUnitsFilterControl.setValue(this.unitlessUnit):this.pathSkUnitsFilterControl.setValue(null),i.controls.path.updateValueAndValidity()}))}ngOnChanges(e){e.filterSelfPaths&&!e.filterSelfPaths.firstChange&&this.pathFormGroup().controls.path.updateValueAndValidity()}getPaths(){let e=this.pathFormGroup().controls.pathType.value,i=this.filterSelfPaths(),t=!1,l=this.pathFormGroup();if(l.value.supportsPut){let d=!1;this.multiCTRLArray().length>0&&(d=this.multiCTRLArray().some(g=>g.pathID===this.pathFormGroup().value.pathID&&g.type==="3")),d?t=!1:t=la(this._connection.skServerVersion,"2.12.0",">=")?l.value.supportsPut:!1}return this._data.getPathsAndMetaByType(e,t,i).sort()}filterPaths(e){let i=e.toLowerCase(),t=this.getPaths();if(this.pathSkUnitsFilterControl.value){let l=this.pathSkUnitsFilterControl.value.unit;t=t.filter(d=>{let g=!!d.meta&&!!d.meta.units,C=l==="unitless";return g&&d.meta.units===l||!g&&C})}t=t.filter(l=>l.path.toLowerCase().includes(i)),this.filteredPaths.next(t)}enableFormFields(e){let i=this._data.getPathObject(this.pathFormGroup().controls.path.value);if(i!=null){this.pathFormGroup().controls.sampleTime.enable({onlySelf:!1});let t=this.pathFormGroup();t.controls.pathType.value=="number"&&(this.unitList=this._units.getConversionsForPath(t.controls.path.value),e&&t.controls.convertUnitTo.setValue(this.unitList.base,{onlySelf:!0}),t.controls.convertUnitTo.enable({onlySelf:!1})),Object.keys(i.sources).length==1?(this.availableSources=["default"],e?t.controls.source.value!="default"&&t.controls.source.setValue("default",{onlySelf:!0}):t.controls.source.value!="default"&&t.controls.source.setValue("",{onlySelf:!0})):Object.keys(i.sources).length>1&&(this.availableSources=Object.keys(i.sources),t.controls.source.value=="default"&&t.controls.source.reset()),t.controls.source.enable({onlySelf:!1})}else this.disablePathFields()}disablePathFields(){this.pathFormGroup().controls.source.reset("",{onlySelf:!0}),this.pathFormGroup().controls.source.disable({onlySelf:!1}),this.pathFormGroup().controls.sampleTime.disable({onlySelf:!1});let e=this.pathFormGroup();e.controls.pathType.value=="number"&&(e.controls.convertUnitTo.reset("",{onlySelf:!0}),e.controls.convertUnitTo.disable({onlySelf:!1}))}updatePathMetaBoundDisplayName(e){let i=this.pathFormGroup();if(!Object.prototype.hasOwnProperty.call(i.parent.parent.value,"displayName"))return;let t=this._data.getPathMeta(e);t?.displayName&&i.parent.parent.controls.displayName.setValue(t.displayName)}updatePathMetaBoundDisplayScale(e){let i=this.pathFormGroup();if(!Object.prototype.hasOwnProperty.call(i.parent.parent.value,"displayScale"))return;let t=this._data.getPathMeta(e);if(t?.displayScale){let l=i.parent.parent.get("displayScale"),d=i.controls.convertUnitTo.value;t.displayScale.lower!==null&&t.displayScale.lower!==void 0&&l.controls.lower.setValue(this._units.convertToUnit(d,t.displayScale.lower)),t.displayScale.upper!==null&&t.displayScale.upper!==void 0&&l.controls.upper.setValue(this._units.convertToUnit(d,t.displayScale.upper)),t.displayScale.type!==null&&t.displayScale.type!==void 0&&l.controls.type.setValue(t.displayScale.type),t.displayScale.power!==null&&t.displayScale.power!==void 0&&l.controls.power.setValue(t.displayScale.power)}}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["path-control-config"]],inputs:{pathFormGroup:[1,"pathFormGroup"],multiCTRLArray:[1,"multiCTRLArray"],filterSelfPaths:[1,"filterSelfPaths"]},features:[ot],decls:1,vars:1,consts:[["pathInput",""],["pathAutoComplete","matAutocomplete"],["pathUnitsFilter",""],[1,"flex-container","rounded-card","rounded-card-color",3,"formGroup"],[1,"flex-field-100"],[1,"flex-field-fixed"],[1,"flex-field-to-100"],["floatLabel","auto","appearance","fill",1,"pathField"],[1,"optional-label"],["type","text","matInput","","placeholder","Type to use autocomplete or select from list","formControlName","path",3,"matAutocomplete"],["mat-icon-button","","matIconSuffix","","aria-label","Clear"],[2,"min-height","48px","line-height","1.15","height","auto","padding","8px 16px","white-space","normal",3,"value"],[1,"pathProperties"],[1,"sourceField"],["appearance","outline","floatLabel","always",1,"fields"],["placeholder","Select source","formControlName","source","required",""],[3,"value"],[1,"sampleTimeField"],["matInput","","type","number","placeholder","Sample time in milliseconds","formControlName","sampleTime","required",""],[1,"unitField"],[1,"fields"],["floatLabel","auto","appearance","fill",1,"filter-path"],[1,"fa-solid","fa-filter"],[1,"fa-solid","fa-filter-circle-xmark"],["panelWidth","",3,"selectionChange","formControl"],["mat-icon-button","","matIconSuffix","","aria-label","Clear",3,"click"],[1,"pathMetaDescription"],["placeholder","Select unit","formControlName","convertUnitTo","required",""],[3,"label"]],template:function(i,t){i&1&&u(0,Vn,36,13,"div",3),i&2&&A(t.pathFormGroup().value.isPathConfigurable?0:-1)},dependencies:[ae,te,Ze,F,ie,L,B,Me,H,Xe,R,V,oe,Eo,si,Z,wt,Pt,se,Mt,ei,me,Ce,ee,ja,Wt],styles:[".pathGroup[_ngcontent-%COMP%]{width:100%}.pathGroupFields[_ngcontent-%COMP%]{display:block;width:calc(100% - 5px)}.pathField[_ngcontent-%COMP%]{width:100%}.pathProperties[_ngcontent-%COMP%]{display:flex;flex-flow:row wrap;justify-content:space-between;align-items:center;align-content:flex-start;gap:10px}.fields[_ngcontent-%COMP%]{width:100%}.sourceField[_ngcontent-%COMP%]{flex:3 1}.sampleTimeField[_ngcontent-%COMP%]{flex:1 3}.unitField[_ngcontent-%COMP%]{flex:3 1}"]})}return a})();function Nn(a,s){if(a&1&&b(0,"path-control-config",6),a&2){let e=s.$implicit,i=f(2);p("pathFormGroup",e)("filterSelfPaths",i.filterSelfPaths().value)("multiCTRLArray",i.multiCTRLArray)}}function Wn(a,s){if(a&1&&y(0,Nn,1,3,"path-control-config",6,I),a&2){let e=f();x(e.pathsFormGroup.controls)}}function Un(a,s){if(a&1&&b(0,"path-control-config",6),a&2){let e=s.$implicit,i=f(2);p("pathFormGroup",i.pathsFormGroup.get(e))("filterSelfPaths",i.filterSelfPaths().value)("multiCTRLArray",i.multiCTRLArray)}}function Qn(a,s){if(a&1&&(y(0,Un,1,3,"path-control-config",6,I),Ne(2,"objectKeys")),a&2){let e=f();x(We(2,0,e.pathsFormGroup.controls))}}var Io=(()=>{class a{rootFormGroup=m(H);fb=m(xt);formGroupName=h.required();isArray=h.required();enableTimeout=h.required();dataTimeout=h.required();filterSelfPaths=h.required();addPathEvent=h(void 0);delPathEvent=h(void 0);updatePathEvent=h(void 0);pathsFormGroup;multiCTRLArray=[];ngOnInit(){this.isArray()?(this.pathsFormGroup=this.rootFormGroup.control.get(this.formGroupName()),this.multiCTRLArray=this.rootFormGroup.control.get("multiChildCtrls").value):this.pathsFormGroup=this.rootFormGroup.control.get(this.formGroupName())}addPath(e){this.pathsFormGroup.push(this.fb.group({description:[e.path.description],path:[e.path.path,Y.required],pathID:[e.path.pathID],source:[e.path.source,Y.required],pathType:[e.path.pathType],isPathConfigurable:[e.path.isPathConfigurable],showPathSkUnitsFilter:[e.path.showPathSkUnitsFilter],pathSkUnitsFilter:[e.path.pathSkUnitsFilter],convertUnitTo:[e.path.convertUnitTo],sampleTime:[e.path.sampleTime],supportsPut:[e.path.supportsPut]})),this.pathsFormGroup.updateValueAndValidity(),this.multiCTRLArray=this.rootFormGroup.control.get("multiChildCtrls").value}delPath(){this.multiCTRLArray=this.rootFormGroup.control.get("multiChildCtrls").value}updatePath(e){this.multiCTRLArray=e}ngOnChanges(e){e.addPathEvent&&!e.addPathEvent.firstChange&&this.addPath(e.addPathEvent.currentValue),e.delPathEvent&&!e.delPathEvent.firstChange&&this.delPath(),e.updatePathEvent&&!e.updatePathEvent.firstChange&&this.updatePath(e.updatePathEvent.currentValue)}static \u0275fac=function(i){return new(i||a)};static \u0275cmp=v({type:a,selectors:[["paths-options"]],inputs:{formGroupName:[1,"formGroupName"],isArray:[1,"isArray"],enableTimeout:[1,"enableTimeout"],dataTimeout:[1,"dataTimeout"],filterSelfPaths:[1,"filterSelfPaths"],addPathEvent:[1,"addPathEvent"],delPathEvent:[1,"delPathEvent"],updatePathEvent:[1,"updatePathEvent"]},features:[ot],decls:14,vars:5,consts:[[1,"widget-options-grid"],["name","enableTimeout",3,"formControl"],["type","number","matNativeControl","","placeholder","Time in seconds...","name","dataTimeout","min","2","required","",3,"formControl"],["matTextSuffix",""],[3,"formGroup"],["name","filterSelfPaths",3,"formControl"],[2,"display","block",3,"pathFormGroup","filterSelfPaths","multiCTRLArray"]],template:function(i,t){i&1&&(n(0,"div",0)(1,"mat-checkbox",1),r(2," Enable Widget Data TTL "),o(),n(3,"mat-form-field")(4,"mat-label"),r(5,"TTL Timeout For Paths"),o(),b(6,"input",2),n(7,"span",3),r(8,"Seconds"),o()()(),zi(9,4),u(10,Wn,2,0)(11,Qn,3,2),ji(),n(12,"mat-checkbox",5),r(13,` Restrict to own vessel
@@ -1 +1 @@
1
- import{i as p,p as d}from"./chunk-TA4GACKT.js";import{Ja as i,Qd as s,Wc as u,Yc as a,m,o as g,oa as c,ta as l}from"./chunk-35L7BBBD.js";var h={name:"@mxtommy/kip",version:"3.9.0-beta.2",description:"An advanced and versatile marine instrumentation package to display Signal K data.",license:"MIT",author:{name:"Thomas St.Pierre, David Godin"},contributors:[{name:"David Godin",email:"godind@hotmail.com"},{name:"Thomas St.Pierre",email:"thomas@samoht.ca"}],homepage:"https://github.com/mxtommy/Kip",bugs:"https://github.com/mxtommy/Kip/issues",repository:{type:"git",url:"git+https://github.com/mxtommy/Kip.git"},keywords:["signalk-webapp","signalk-category-instruments","signal k","signalk","instruments","dashboard","marine","nmea"],signalk:{appIcon:"assets/icon-72x72.png",displayName:"KIP Instrument MFD"},scripts:{dev:"ng serve --configuration=dev --serve-path=/@mxtommy/kip/","build-dev":"ng build --configuration=dev","build-prod":"ng build --configuration=production",test:"ng test",lint:"ng lint",e2e:"ng e2e"},devDependencies:{"@angular-devkit/build-angular":"^20.1.6","@angular/animations":"20.1.7","@angular/build":"^20.1.6","@angular/cdk":"20.1.6","@angular/cli":"^20.1.6","@angular/common":"20.1.7","@angular/compiler":"20.1.7","@angular/compiler-cli":"20.1.7","@angular/core":"20.1.7","@angular/forms":"20.1.7","@angular/language-service":"20.1.7","@angular/material":"20.1.6","@angular/platform-browser":"20.1.7","@angular/platform-browser-dynamic":"20.1.7","@angular/router":"20.1.7","@godind/ng-canvas-gauges":"^6.2.1","@robloche/chartjs-plugin-streaming":"^3.1.0","@types/canvas-gauges":"^2.1.8","@types/hammerjs":"^2.0.45","@types/howler":"^2.2.10","@types/jasmine":"~3.6.0","@types/jasminewd2":"^2.0.9","@types/js-quantities":"^1.6.6","@types/lodash-es":"^4.17.9","@types/node":"^24.1.0","angular-eslint":"20.1.1","chart.js":"^4.4.9","chartjs-adapter-date-fns":"^3.0.0","chartjs-plugin-annotation":"^3.0.1",codelyzer:"^6.0.0","compare-versions":"^6.1.1","core-js":"^3.13.1","date-fns":"^2.30.0",eslint:"^9.29.0",gridstack:"^11.4.0",hammerjs:"^2.0.8",howler:"^2.2.4","jasmine-core":"~4.0.1","jasmine-spec-reporter":"~5.0.0","js-quantities":"^1.8.0",karma:"^6.4.4","karma-chrome-launcher":"~3.1.0","karma-cli":"~2.0.0","karma-coverage-istanbul-reporter":"^3.0.3","karma-jasmine":"~4.0.0","karma-jasmine-html-reporter":"^1.6.0","lodash-es":"^4.17.21","ng-packagr":"^20.0.1","ngx-markdown":"^20.0.0","ngx-resize-observer":"^3.1.0",protractor:"~7.0.0","pwa-asset-generator":"^8.0.4",rxjs:"^7.8.2",sass:"^1.49.9",screenfull:"^6.0.2","@zakj/no-sleep":"^0.13.5",steelseries:"^2.0.9","ts-node":"^10.9.2",tslib:"^2.6.2",typescript:"^5.8.3","zone.js":"^0.15.1"}};var N=(()=>{class o{MODE_PATH="self.environment.mode";configurableThemeColors=[{label:"Contrast",value:"contrast"},{label:"Blue",value:"blue"},{label:"Green",value:"green"},{label:"Orange",value:"orange"},{label:"Yellow",value:"yellow"},{label:"Pink",value:"pink"},{label:"Purple",value:"purple"},{label:"Grey",value:"grey"}];snackbarAppNotifications=new m;cssThemeColorRoles$=new g(null);_cssThemeColorRoles=null;_settings=l(p);_data=l(d);isNightMode=i(!1);_useAutoNightMode=s(this._settings.getAutoNightModeAsO(),{requireSync:!0});_theme=s(this._settings.getThemeNameAsO(),{requireSync:!0});_redNightMode=s(this._settings.getRedNightModeAsO(),{requireSync:!0});_environmentMode=s(this._data.subscribePath(this.MODE_PATH,"default"));appVersion=i(h.version);browserVersion=i("Unknown");osVersion=i("Unknown");constructor(){a(()=>{this._theme()==="light-theme"?document.body.classList.toggle("light-theme",this._theme()==="light-theme"):document.body.classList.remove("light-theme")}),a(()=>{let t=this._environmentMode().data.value;this._useAutoNightMode()&&(this.isNightMode.set(t==="night"),this.toggleDayNightMode())}),a(()=>{let t=this._redNightMode();u(()=>{t?this.toggleDayNightMode():this.toggleDayNightMode()})}),this.readThemeCssRoleVariables(),this._cssThemeColorRoles=this.cssThemeColorRoles$.getValue(),this.browserVersion.set(this.getBrowserVersion()),this.osVersion.set(this.getOSVersion()),console.log("*********** KIP Version Information ***********"),console.log(`** App Version: ${this.appVersion()}`),console.log(`** Browser Version: ${this.browserVersion()}`),console.log(`** OS Version: ${this.osVersion()}`),console.log("***********************************************")}sendSnackbarNotification(t,e=1e4,r=!1,n="Dismiss"){this.snackbarAppNotifications.next({message:t,duration:e,silent:r,action:n})}getSnackbarAppNotifications(){return this.snackbarAppNotifications.asObservable()}readThemeCssRoleVariables(){let t=document.body,e=getComputedStyle(t),r={background:e.getPropertyValue("--mat-sys-background").trim(),cardColor:e.getPropertyValue("--kip-widget-card-background-color").trim(),blue:e.getPropertyValue("--kip-blue-color").trim(),blueDim:e.getPropertyValue("--kip-blue-dim-color").trim(),blueDimmer:e.getPropertyValue("--kip-blue-dimmer-color").trim(),green:e.getPropertyValue("--kip-green-color").trim(),greenDim:e.getPropertyValue("--kip-green-dim-color").trim(),greenDimmer:e.getPropertyValue("--kip-green-dimmer-color").trim(),grey:e.getPropertyValue("--kip-grey-color").trim(),greyDim:e.getPropertyValue("--kip-grey-dim-color").trim(),greyDimmer:e.getPropertyValue("--kip-grey-dimmer-color").trim(),orange:e.getPropertyValue("--kip-orange-color").trim(),orangeDim:e.getPropertyValue("--kip-orange-dim-color").trim(),orangeDimmer:e.getPropertyValue("--kip-orange-dimmer-color").trim(),pink:e.getPropertyValue("--kip-pink-color").trim(),pinkDim:e.getPropertyValue("--kip-pink-dim-color").trim(),pinkDimmer:e.getPropertyValue("--kip-pink-dimmer-color").trim(),purple:e.getPropertyValue("--kip-purple-color").trim(),purpleDim:e.getPropertyValue("--kip-purple-dim-color").trim(),purpleDimmer:e.getPropertyValue("--kip-purple-dimmer-color").trim(),contrast:e.getPropertyValue("--kip-contrast-color").trim(),contrastDim:e.getPropertyValue("--kip-contrast-dim-color").trim(),contrastDimmer:e.getPropertyValue("--kip-contrast-dimmer-color").trim(),yellow:e.getPropertyValue("--kip-yellow-color").trim(),yellowDim:e.getPropertyValue("--kip-yellow-dim-color").trim(),yellowDimmer:e.getPropertyValue("--kip-yellow-dimmer-color").trim(),port:e.getPropertyValue("--kip-port-color").trim(),starboard:e.getPropertyValue("--kip-starboard-color").trim(),zoneNominal:e.getPropertyValue("--kip-zone-nominal-color").trim(),zoneAlert:e.getPropertyValue("--kip-zone-alert-color").trim(),zoneWarn:e.getPropertyValue("--kip-zone-warn-color").trim(),zoneAlarm:e.getPropertyValue("--kip-zone-alarm-color").trim(),zoneEmergency:e.getPropertyValue("--kip-zone-emergency-color").trim()};this.cssThemeColorRoles$.next(r)}get cssThemeColors(){return this._cssThemeColorRoles}setBrightness(t,e=!1){let r=document.body;r.style.setProperty("--kip-nightModeBrightness",`${t}`);let n=e?" sepia(0.5) hue-rotate(-30deg)":"";r.style.setProperty("--kip-nightModeFilters",n)}toggleDayNightMode(){this.isNightMode()?this._redNightMode()?(document.body.classList.toggle("night-theme",!0),this.setBrightness(1,!1)):(this.setBrightness(this._settings.getNightModeBrightness(),!0),document.body.classList.remove("night-theme"),this._theme()==="light-theme"?document.body.classList.toggle("light-theme",this._theme()==="light-theme"):document.body.classList.remove("light-theme")):(document.body.classList.remove("night-theme"),this._theme()==="light-theme"&&document.body.classList.toggle("light-theme",this._theme()==="light-theme"),this.setBrightness(1,!1)),this.readThemeCssRoleVariables(),this._cssThemeColorRoles=this.cssThemeColorRoles$.getValue()}getBrowserVersion(){let t=navigator.userAgent,e="Unknown";return t.includes("Edg")?e=`Edge ${t.match(/Edg\/(\d+)/)?.[1]}`:t.includes("Chrome")&&!t.includes("Edg")&&!t.includes("Chromium")?e=`Chrome ${t.match(/Chrome\/(\d+)/)?.[1]}`:t.includes("Chromium")?e=`Chromium ${t.match(/Chromium\/(\d+)/)?.[1]}`:t.includes("Firefox")?e=`Firefox ${t.match(/Firefox\/(\d+)/)?.[1]}`:t.includes("Safari")&&!t.includes("Chrome")&&!t.includes("Chromium")?e=`Safari ${t.match(/Version\/(\d+)/)?.[1]}`:(t.includes("Opera")||t.includes("OPR"))&&(e=`Opera ${t.match(/(Opera|OPR)\/(\d+)/)?.[2]}`),e}getOSVersion(){let t=navigator.platform,e=navigator.userAgent;return t.startsWith("Mac")?"macOS":t.startsWith("Win")?"Windows":/Linux/.test(t)?e.includes("ARM")||e.includes("aarch64")||e.includes("Raspberry")||t.includes("armv7l")||t.includes("armv8l")?"Raspberry Pi":"Linux":"Unknown OS"}static \u0275fac=function(e){return new(e||o)};static \u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}return o})();export{N as a};
1
+ import{i as p,p as d}from"./chunk-TA4GACKT.js";import{Ja as i,Qd as s,Wc as u,Yc as a,m,o as g,oa as c,ta as l}from"./chunk-35L7BBBD.js";var h={name:"@mxtommy/kip",version:"3.9.0-beta.3",description:"An advanced and versatile marine instrumentation package to display Signal K data.",license:"MIT",author:{name:"Thomas St.Pierre, David Godin"},contributors:[{name:"David Godin",email:"godind@hotmail.com"},{name:"Thomas St.Pierre",email:"thomas@samoht.ca"}],homepage:"https://github.com/mxtommy/Kip",bugs:"https://github.com/mxtommy/Kip/issues",repository:{type:"git",url:"git+https://github.com/mxtommy/Kip.git"},keywords:["signalk-webapp","signalk-category-instruments","signal k","signalk","instruments","dashboard","marine","nmea"],signalk:{appIcon:"assets/icon-72x72.png",displayName:"KIP Instrument MFD"},scripts:{dev:"ng serve --configuration=dev --serve-path=/@mxtommy/kip/","build-dev":"ng build --configuration=dev","build-prod":"ng build --configuration=production",test:"ng test",lint:"ng lint",e2e:"ng e2e"},devDependencies:{"@angular-devkit/build-angular":"^20.1.6","@angular/animations":"20.1.7","@angular/build":"^20.1.6","@angular/cdk":"20.1.6","@angular/cli":"^20.1.6","@angular/common":"20.1.7","@angular/compiler":"20.1.7","@angular/compiler-cli":"20.1.7","@angular/core":"20.1.7","@angular/forms":"20.1.7","@angular/language-service":"20.1.7","@angular/material":"20.1.6","@angular/platform-browser":"20.1.7","@angular/platform-browser-dynamic":"20.1.7","@angular/router":"20.1.7","@godind/ng-canvas-gauges":"^6.2.1","@robloche/chartjs-plugin-streaming":"^3.1.0","@types/canvas-gauges":"^2.1.8","@types/hammerjs":"^2.0.45","@types/howler":"^2.2.10","@types/jasmine":"~3.6.0","@types/jasminewd2":"^2.0.9","@types/js-quantities":"^1.6.6","@types/lodash-es":"^4.17.9","@types/node":"^24.1.0","angular-eslint":"20.1.1","chart.js":"^4.4.9","chartjs-adapter-date-fns":"^3.0.0","chartjs-plugin-annotation":"^3.0.1",codelyzer:"^6.0.0","compare-versions":"^6.1.1","core-js":"^3.13.1","date-fns":"^2.30.0",eslint:"^9.29.0",gridstack:"^11.4.0",hammerjs:"^2.0.8",howler:"^2.2.4","jasmine-core":"~4.0.1","jasmine-spec-reporter":"~5.0.0","js-quantities":"^1.8.0",karma:"^6.4.4","karma-chrome-launcher":"~3.1.0","karma-cli":"~2.0.0","karma-coverage-istanbul-reporter":"^3.0.3","karma-jasmine":"~4.0.0","karma-jasmine-html-reporter":"^1.6.0","lodash-es":"^4.17.21","ng-packagr":"^20.0.1","ngx-markdown":"^20.0.0","ngx-resize-observer":"^3.1.0",protractor:"~7.0.0","pwa-asset-generator":"^8.0.4",rxjs:"^7.8.2",sass:"^1.49.9",screenfull:"^6.0.2","@zakj/no-sleep":"^0.13.5",steelseries:"^2.0.9","ts-node":"^10.9.2",tslib:"^2.6.2",typescript:"^5.8.3","zone.js":"^0.15.1"}};var N=(()=>{class o{MODE_PATH="self.environment.mode";configurableThemeColors=[{label:"Contrast",value:"contrast"},{label:"Blue",value:"blue"},{label:"Green",value:"green"},{label:"Orange",value:"orange"},{label:"Yellow",value:"yellow"},{label:"Pink",value:"pink"},{label:"Purple",value:"purple"},{label:"Grey",value:"grey"}];snackbarAppNotifications=new m;cssThemeColorRoles$=new g(null);_cssThemeColorRoles=null;_settings=l(p);_data=l(d);isNightMode=i(!1);_useAutoNightMode=s(this._settings.getAutoNightModeAsO(),{requireSync:!0});_theme=s(this._settings.getThemeNameAsO(),{requireSync:!0});_redNightMode=s(this._settings.getRedNightModeAsO(),{requireSync:!0});_environmentMode=s(this._data.subscribePath(this.MODE_PATH,"default"));appVersion=i(h.version);browserVersion=i("Unknown");osVersion=i("Unknown");constructor(){a(()=>{this._theme()==="light-theme"?document.body.classList.toggle("light-theme",this._theme()==="light-theme"):document.body.classList.remove("light-theme")}),a(()=>{let t=this._environmentMode().data.value;this._useAutoNightMode()&&(this.isNightMode.set(t==="night"),this.toggleDayNightMode())}),a(()=>{let t=this._redNightMode();u(()=>{t?this.toggleDayNightMode():this.toggleDayNightMode()})}),this.readThemeCssRoleVariables(),this._cssThemeColorRoles=this.cssThemeColorRoles$.getValue(),this.browserVersion.set(this.getBrowserVersion()),this.osVersion.set(this.getOSVersion()),console.log("*********** KIP Version Information ***********"),console.log(`** App Version: ${this.appVersion()}`),console.log(`** Browser Version: ${this.browserVersion()}`),console.log(`** OS Version: ${this.osVersion()}`),console.log("***********************************************")}sendSnackbarNotification(t,e=1e4,r=!1,n="Dismiss"){this.snackbarAppNotifications.next({message:t,duration:e,silent:r,action:n})}getSnackbarAppNotifications(){return this.snackbarAppNotifications.asObservable()}readThemeCssRoleVariables(){let t=document.body,e=getComputedStyle(t),r={background:e.getPropertyValue("--mat-sys-background").trim(),cardColor:e.getPropertyValue("--kip-widget-card-background-color").trim(),blue:e.getPropertyValue("--kip-blue-color").trim(),blueDim:e.getPropertyValue("--kip-blue-dim-color").trim(),blueDimmer:e.getPropertyValue("--kip-blue-dimmer-color").trim(),green:e.getPropertyValue("--kip-green-color").trim(),greenDim:e.getPropertyValue("--kip-green-dim-color").trim(),greenDimmer:e.getPropertyValue("--kip-green-dimmer-color").trim(),grey:e.getPropertyValue("--kip-grey-color").trim(),greyDim:e.getPropertyValue("--kip-grey-dim-color").trim(),greyDimmer:e.getPropertyValue("--kip-grey-dimmer-color").trim(),orange:e.getPropertyValue("--kip-orange-color").trim(),orangeDim:e.getPropertyValue("--kip-orange-dim-color").trim(),orangeDimmer:e.getPropertyValue("--kip-orange-dimmer-color").trim(),pink:e.getPropertyValue("--kip-pink-color").trim(),pinkDim:e.getPropertyValue("--kip-pink-dim-color").trim(),pinkDimmer:e.getPropertyValue("--kip-pink-dimmer-color").trim(),purple:e.getPropertyValue("--kip-purple-color").trim(),purpleDim:e.getPropertyValue("--kip-purple-dim-color").trim(),purpleDimmer:e.getPropertyValue("--kip-purple-dimmer-color").trim(),contrast:e.getPropertyValue("--kip-contrast-color").trim(),contrastDim:e.getPropertyValue("--kip-contrast-dim-color").trim(),contrastDimmer:e.getPropertyValue("--kip-contrast-dimmer-color").trim(),yellow:e.getPropertyValue("--kip-yellow-color").trim(),yellowDim:e.getPropertyValue("--kip-yellow-dim-color").trim(),yellowDimmer:e.getPropertyValue("--kip-yellow-dimmer-color").trim(),port:e.getPropertyValue("--kip-port-color").trim(),starboard:e.getPropertyValue("--kip-starboard-color").trim(),zoneNominal:e.getPropertyValue("--kip-zone-nominal-color").trim(),zoneAlert:e.getPropertyValue("--kip-zone-alert-color").trim(),zoneWarn:e.getPropertyValue("--kip-zone-warn-color").trim(),zoneAlarm:e.getPropertyValue("--kip-zone-alarm-color").trim(),zoneEmergency:e.getPropertyValue("--kip-zone-emergency-color").trim()};this.cssThemeColorRoles$.next(r)}get cssThemeColors(){return this._cssThemeColorRoles}setBrightness(t,e=!1){let r=document.body;r.style.setProperty("--kip-nightModeBrightness",`${t}`);let n=e?" sepia(0.5) hue-rotate(-30deg)":"";r.style.setProperty("--kip-nightModeFilters",n)}toggleDayNightMode(){this.isNightMode()?this._redNightMode()?(document.body.classList.toggle("night-theme",!0),this.setBrightness(1,!1)):(this.setBrightness(this._settings.getNightModeBrightness(),!0),document.body.classList.remove("night-theme"),this._theme()==="light-theme"?document.body.classList.toggle("light-theme",this._theme()==="light-theme"):document.body.classList.remove("light-theme")):(document.body.classList.remove("night-theme"),this._theme()==="light-theme"&&document.body.classList.toggle("light-theme",this._theme()==="light-theme"),this.setBrightness(1,!1)),this.readThemeCssRoleVariables(),this._cssThemeColorRoles=this.cssThemeColorRoles$.getValue()}getBrowserVersion(){let t=navigator.userAgent,e="Unknown";return t.includes("Edg")?e=`Edge ${t.match(/Edg\/(\d+)/)?.[1]}`:t.includes("Chrome")&&!t.includes("Edg")&&!t.includes("Chromium")?e=`Chrome ${t.match(/Chrome\/(\d+)/)?.[1]}`:t.includes("Chromium")?e=`Chromium ${t.match(/Chromium\/(\d+)/)?.[1]}`:t.includes("Firefox")?e=`Firefox ${t.match(/Firefox\/(\d+)/)?.[1]}`:t.includes("Safari")&&!t.includes("Chrome")&&!t.includes("Chromium")?e=`Safari ${t.match(/Version\/(\d+)/)?.[1]}`:(t.includes("Opera")||t.includes("OPR"))&&(e=`Opera ${t.match(/(Opera|OPR)\/(\d+)/)?.[2]}`),e}getOSVersion(){let t=navigator.platform,e=navigator.userAgent;return t.startsWith("Mac")?"macOS":t.startsWith("Win")?"Windows":/Linux/.test(t)?e.includes("ARM")||e.includes("aarch64")||e.includes("Raspberry")||t.includes("armv7l")||t.includes("armv8l")?"Raspberry Pi":"Linux":"Unknown OS"}static \u0275fac=function(e){return new(e||o)};static \u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}return o})();export{N as a};
@@ -1 +1 @@
1
- import{a as c}from"./chunk-NMEZOCU2.js";import{g as l}from"./chunk-3LEMFOCV.js";import{a as g}from"./chunk-FBFTGVZ6.js";import"./chunk-2YVW3TBK.js";import{g as a,i as r}from"./chunk-TA4GACKT.js";import{ta as t,wb as s}from"./chunk-35L7BBBD.js";var v=(()=>{class o{dialog=t(l);auth=t(a);appService=t(g);appSettingsService=t(r);connectionConfig=null;ngOnInit(){this.connectionConfig=this.appSettingsService.getConnectionConfig(),this.openUserCredentialModal("Sign in failed: Incorrect user/password. Enter valide credentials or access the Confifuration/Settings menu, validate the server URL or/and disable the user Sign in option")}openUserCredentialModal(e){this.dialog.open(c,{disableClose:!0,data:{user:this.connectionConfig.loginName,password:this.connectionConfig.loginPassword,error:e}}).afterClosed().subscribe(i=>{i===void 0||!i||(this.connectionConfig.loginName=i.user,this.connectionConfig.loginPassword=i.password,this.appSettingsService.setConnectionConfig(this.connectionConfig),this.serverLogin())})}serverLogin(e){this.auth.login({usr:this.connectionConfig.loginName,pwd:this.connectionConfig.loginPassword,newUrl:e}).then(()=>{this.appSettingsService.reloadApp()}).catch(n=>{n.status==401?(this.openUserCredentialModal("Sign in failed: Invalide user/password. Enter valide credentials"),console.log("[Setting-SignalK Component] Sign in failed: "+n.error.message)):n.status==404?(this.appService.sendSnackbarNotification("Sign in failed: Login API not found at URL. See connection detail status in Configuration/Settings",5e3,!1),console.log("[Setting-SignalK Component] Sign in failed: "+n.error.message)):n.status==0?(this.appService.sendSnackbarNotification("Sign in failed: Cannot reach server at Signal K URL. See connection detail status in Configuration/Settings",5e3,!1),console.log("[Setting-SignalK Component] Sign in failed: Cannot reach server at Signal K URL:"+n.message)):(this.appService.sendSnackbarNotification("Unknown authentication failure: "+JSON.stringify(n),5e3,!1),console.log("[Setting-SignalK Component] Unknown login error response: "+JSON.stringify(n)))})}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=s({type:o,selectors:[["app-widget-login"]],decls:0,vars:0,template:function(n,i){},encapsulation:2})}return o})();export{v as WidgetLoginComponent};
1
+ import{a as c}from"./chunk-NMEZOCU2.js";import{g as l}from"./chunk-3LEMFOCV.js";import{a as g}from"./chunk-K22CSA3Y.js";import"./chunk-2YVW3TBK.js";import{g as a,i as r}from"./chunk-TA4GACKT.js";import{ta as t,wb as s}from"./chunk-35L7BBBD.js";var v=(()=>{class o{dialog=t(l);auth=t(a);appService=t(g);appSettingsService=t(r);connectionConfig=null;ngOnInit(){this.connectionConfig=this.appSettingsService.getConnectionConfig(),this.openUserCredentialModal("Sign in failed: Incorrect user/password. Enter valide credentials or access the Confifuration/Settings menu, validate the server URL or/and disable the user Sign in option")}openUserCredentialModal(e){this.dialog.open(c,{disableClose:!0,data:{user:this.connectionConfig.loginName,password:this.connectionConfig.loginPassword,error:e}}).afterClosed().subscribe(i=>{i===void 0||!i||(this.connectionConfig.loginName=i.user,this.connectionConfig.loginPassword=i.password,this.appSettingsService.setConnectionConfig(this.connectionConfig),this.serverLogin())})}serverLogin(e){this.auth.login({usr:this.connectionConfig.loginName,pwd:this.connectionConfig.loginPassword,newUrl:e}).then(()=>{this.appSettingsService.reloadApp()}).catch(n=>{n.status==401?(this.openUserCredentialModal("Sign in failed: Invalide user/password. Enter valide credentials"),console.log("[Setting-SignalK Component] Sign in failed: "+n.error.message)):n.status==404?(this.appService.sendSnackbarNotification("Sign in failed: Login API not found at URL. See connection detail status in Configuration/Settings",5e3,!1),console.log("[Setting-SignalK Component] Sign in failed: "+n.error.message)):n.status==0?(this.appService.sendSnackbarNotification("Sign in failed: Cannot reach server at Signal K URL. See connection detail status in Configuration/Settings",5e3,!1),console.log("[Setting-SignalK Component] Sign in failed: Cannot reach server at Signal K URL:"+n.message)):(this.appService.sendSnackbarNotification("Unknown authentication failure: "+JSON.stringify(n),5e3,!1),console.log("[Setting-SignalK Component] Unknown login error response: "+JSON.stringify(n)))})}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=s({type:o,selectors:[["app-widget-login"]],decls:0,vars:0,template:function(n,i){},encapsulation:2})}return o})();export{v as WidgetLoginComponent};
@@ -1 +1 @@
1
- import{a as re}from"./chunk-VHFBF47T.js";import{f as oe,n as ae}from"./chunk-ZBCOJLI4.js";import{h as I}from"./chunk-TXPLRBW5.js";import{a as R}from"./chunk-FBFTGVZ6.js";import{a as ie}from"./chunk-2YVW3TBK.js";import{A as B,D as G,E as K,H,K as z,N as Y,P as $,Q,R as X,T as Z,_ as ee,ca as te,da as ne,g as N,h as V,i as A,r as W,t as q,w as J,x as U}from"./chunk-TA4GACKT.js";import{$b as _,Aa as g,Cc as E,Ec as w,Fc as T,Fe as j,Gc as y,Nc as F,Sb as v,Tb as h,Ub as L,Vb as P,Wb as M,Xb as k,Yb as f,Zb as n,_b as i,f as O,gc as b,ic as m,kc as u,lb as c,ta as C,uc as x,wb as D,za as d,zc as o}from"./chunk-35L7BBBD.js";var le=()=>({standalone:!1});function se(r,p){r&1&&(n(0,"div"),o(1,' Writing to the server requires "Login to Server" authentication or a Device token '),i())}function ce(r,p){if(r&1){let e=b();n(0,"div")(1,"mat-form-field",31)(2,"mat-label"),o(3,"Scope"),i(),n(4,"mat-select",32),y("ngModelChange",function(t){d(e);let a=u();return T(a.saveConfigScope,t)||(a.saveConfigScope=t),g(t)}),n(5,"mat-option",33),o(6," Global "),i(),n(7,"mat-option",34),o(8," User "),i()()(),n(9,"mat-form-field",35)(10,"mat-label"),o(11,"Configuration Name"),i(),n(12,"input",36),y("ngModelChange",function(t){d(e);let a=u();return T(a.saveConfigName,t)||(a.saveConfigName=t),g(t)}),i()(),v(13,se,2,0,"div"),i()}if(r&2){let e=u();c(4),w("ngModel",e.saveConfigScope),c(8),w("ngModel",e.saveConfigName),f("ngModelOptions",F(4,le)),c(),h(e.hasToken?-1:13)}}function de(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Server authentication or Device Token required"),i()())}function ge(r,p){if(r&1&&(n(0,"mat-option",39),o(1),i()),r&2){let e=p.$implicit;f("value",e),c(),E(" ",e.scope," / ",e.name," ")}}function pe(r,p){if(r&1){let e=b();n(0,"div")(1,"mat-form-field",37)(2,"mat-label"),o(3,"Configuration"),i(),n(4,"mat-select",38),y("ngModelChange",function(t){d(e);let a=u();return T(a.deleteConfigItem,t)||(a.deleteConfigItem=t),g(t)}),M(5,ge,2,3,"mat-option",39,P),i()()()}if(r&2){let e=u();c(4),w("ngModel",e.deleteConfigItem),c(),k(e.serverConfigList)}}function me(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Authentication or Device Token required"),i()())}function fe(r,p){if(r&1&&(n(0,"mat-option",39),o(1),i()),r&2){let e=p.$implicit;f("value",e),c(),E(" ",e.scope," / ",e.name," ")}}function ue(r,p){if(r&1&&(n(0,"div")(1,"mat-form-field",37)(2,"mat-label"),o(3,"Configuration"),i(),n(4,"mat-select",40),M(5,fe,2,3,"mat-option",39,L),i()()()),r&2){let e=u();c(5),k(e.serverConfigList)}}function Ce(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Authentication or Device Token required"),i()())}var Ne=(()=>{class r{appSettingsService=C(A);storageSvc=C(V);appService=C(R);auth=C(N);fb=C($);pageTitle="Configurations";hasToken=!1;isTokenTypeDevice=!1;tokenSub;supportApplicationData=!1;serverConfigList=[];serverUpgradableConfigList=[];copyConfigForm;storageLocation=null;locations=["Local Storage","Server Storage"];saveConfigName=null;saveConfigScope=null;deleteConfigItem;jsonData=null;ngOnInit(){this.tokenSub=this.auth.authToken$.subscribe(e=>{e&&e.token?(this.hasToken=!0,this.isTokenTypeDevice=e.isDeviceAccessToken,e.isDeviceAccessToken?this.saveConfigScope="global":this.saveConfigScope="user"):this.hasToken=!1}),this.copyConfigForm=this.fb.group({sourceTarget:[{value:"",disabled:!1},q.required]}),this.supportApplicationData=this.storageSvc.isAppDataSupported,this.hasToken&&this.getServerConfigList()}getServerConfigList(e){this.supportApplicationData&&this.storageSvc.listConfigs(e).then(l=>{let t=l.filter(a=>!(a.scope==="user"&&a.name==="default"));e?this.serverUpgradableConfigList=t:this.serverConfigList=t}).catch(l=>{switch(l.status){case 401:this.appService.sendSnackbarNotification("Application Storage Error: "+l.statusText+". Signal K configuration must meet the following requirements; 1) Security enabled. 2) Application Data Storage Interface: On. 3) Either Allow Readonly Access enabled, or connecting with a user.",0,!1);break;default:this.appService.sendSnackbarNotification("Error listing server configurations: "+l,3e3,!1);break}})}saveConfig(e,l,t,a,s){if(this.supportApplicationData){if(l==="user"&&t==="default"&&!s){this.appService.sendSnackbarNotification("Saving configuration with scope 'user' and name 'default' is not allowed.",5e3,!1);return}this.storageSvc.setConfig(l,t,e)?(this.appService.sendSnackbarNotification(`Configuration [${t}] saved to [${l}] storage scope`,5e3,!1),a||this.getServerConfigList()):this.appService.sendSnackbarNotification("Error saving configuration to server",0,!1)}}saveToLocalstorage(e){this.appSettingsService.replaceConfig("appConfig",e.app,!1),this.appSettingsService.replaceConfig("dashboardsConfig",e.dashboards,!1),this.appSettingsService.replaceConfig("themeConfig",e.theme,!1)}copyConfig(){return O(this,null,function*(){let e=null;try{yield this.storageSvc.getConfig(this.copyConfigForm.value.sourceTarget.scope,this.copyConfigForm.value.sourceTarget.name).then(l=>{e=l})}catch(l){this.appService.sendSnackbarNotification("Error retrieving configuration from server: "+l.statusText,3e3,!1);return}this.saveConfig(e,"user","default",!1,!0),this.appSettingsService.reloadApp()})}deleteConfig(e,l,t,a){this.storageSvc.removeItem(e,l,t),this.appService.sendSnackbarNotification(`Configuration [${l}] deleted from [${e}] storage scope`,5e3,!1),a||this.getServerConfigList()}resetConfigToDefault(){this.appSettingsService.resetSettings()}resetConnectionToDefault(){this.appSettingsService.resetConnection()}loadDemoConfig(){this.appSettingsService.loadDemoConfig()}getActiveConfig(){let e;return this.appSettingsService.useSharedConfig?e=this.getLocalConfigFromMemory():e=this.getLocalConfigFromLocalStorage(),e}getLocalConfigFromMemory(){return{app:this.appSettingsService.getAppConfig(),dashboards:this.appSettingsService.getDashboardConfig(),theme:this.appSettingsService.getThemeConfig()}}getLocalConfigFromLocalStorage(){return{app:this.appSettingsService.loadConfigFromLocalStorage("appConfig"),dashboards:this.appSettingsService.loadConfigFromLocalStorage("dashboardsConfig"),theme:this.appSettingsService.loadConfigFromLocalStorage("themeConfig")}}downloadJsonConfig(){let e=this.getActiveConfig(),l=JSON.stringify(e,null,2),t=new Blob([l],{type:"application/json"}),a=window.URL.createObjectURL(t),s=document.createElement("a");s.href=a,s.download="KipConfig.json",document.body.appendChild(s),s.click(),document.body.removeChild(s),window.URL.revokeObjectURL(a)}uploadJsonConfig(e){let t=e.target.files?.[0];if(t&&t.type==="application/json"){let a=new FileReader;a.onload=s=>{try{this.jsonData=JSON.parse(s.target?.result),this.hasToken?this.saveConfig(this.jsonData,"user","default",!1,!0):this.saveToLocalstorage(this.jsonData),this.appSettingsService.reloadApp()}catch(S){this.appService.sendSnackbarNotification("Invalid JSON file",3e3,!1),console.error("Invalid JSON file:",S)}},a.readAsText(t)}else this.appService.sendSnackbarNotification("Please select a valid JSON file",0,!1)}ngOnDestroy(){this.tokenSub.unsubscribe()}static \u0275fac=function(l){return new(l||r)};static \u0275cmp=D({type:r,selectors:[["settings-config"]],decls:82,vars:8,consts:[["saveConfigForm","ngForm"],["deleteConfigForm","ngForm"],["fileInput",""],[3,"pageTitle"],[1,"page-content"],["routerLink","/help"],[1,"flex-container"],[1,"flex-item-rounded-card","rounded-card-color"],["name","saveConfigForm",3,"ngSubmit"],[2,"margin-bottom","16px"],[1,"no-token-notice"],[1,"formActionFooter"],[1,"formActionDivider"],["mat-flat-button","","type","submit","color","accent",3,"disabled"],["name","deleteConfigForm",3,"ngSubmit"],[3,"ngSubmit","formGroup"],[1,"flex-item-reset","rounded-card-color"],[1,"config-operation-container",2,"margin-top","20px"],[1,"download-txt"],[1,"download-btn","btn-div"],["mat-flat-button","","type","button",1,"adv-btn",3,"click"],[1,"upload-txt"],[1,"upload-btn","btn-div"],["type","file","accept",".json","hidden","",3,"change"],["mat-flat-button","",1,"adv-btn",3,"click"],[1,"demo-txt"],[1,"demo-btn","btn-div"],[1,"reset-txt"],[1,"reset-btn","btn-div"],[1,"config-txt"],[1,"config-btn","btn-div"],[2,"width","25%"],["name","serverConfiScope","required","",3,"ngModelChange","ngModel"],["value","global"],["value","user"],[2,"width","70%","padding-left","3%"],["matInput","","name","serverConfigName","placeholder","Enter a name for the configuration","required","",3,"ngModelChange","ngModel","ngModelOptions"],[2,"width","100%"],["name","selectedDeleteItem","required","",3,"ngModelChange","ngModel"],[3,"value"],["formControlName","sourceTarget"]],template:function(l,t){if(l&1){let a=b();_(0,"page-header",3),n(1,"div",4)(2,"p"),o(3," Recommended Reading: To understand configuration management and storage options, consult the "),n(4,"a",5),o(5,"Configuration Management Help"),i(),o(6," section. "),i(),n(7,"div",6)(8,"div",7)(9,"form",8,0),m("ngSubmit",function(){return d(a),g(t.saveConfig(t.getActiveConfig(),t.saveConfigScope,t.saveConfigName))}),n(11,"h2"),o(12,"Backup"),i(),n(13,"p",9),o(14," Create a backup of the current active configuration on the server. "),i(),v(15,ce,14,5,"div")(16,de,3,0,"div",10),n(17,"div",11),_(18,"mat-divider",12),n(19,"button",13),o(20," Create "),i()()()(),n(21,"div",7)(22,"form",14,1),m("ngSubmit",function(){return d(a),g(t.deleteConfig(t.deleteConfigItem.scope,t.deleteConfigItem.name))}),n(24,"h2"),o(25,"Delete"),i(),n(26,"p",9),o(27," Select a backup configuration to permanently delete from the server. "),i(),v(28,pe,7,1,"div")(29,me,3,0,"div",10),n(30,"div",11),_(31,"mat-divider",12),n(32,"button",13),o(33," Delete "),i()()()(),n(34,"div",7)(35,"form",15),m("ngSubmit",function(){return d(a),g(t.copyConfig())}),n(36,"h2"),o(37,"Restore"),i(),n(38,"p",9),o(39," Replace the current configuration with a backup from the server. "),i(),v(40,ue,7,0,"div")(41,Ce,3,0,"div",10),n(42,"div",11),_(43,"mat-divider",12),n(44,"button",13),o(45," Restore "),i()()()(),n(46,"div",16)(47,"h2"),o(48,"Advanced"),i(),n(49,"div",17)(50,"div",18)(51,"p"),o(52,"Download the active configuration to a file."),i()(),n(53,"div",19)(54,"button",20),m("click",function(){return d(a),g(t.downloadJsonConfig())}),o(55," Download "),i()(),n(56,"div",21)(57,"p"),o(58," Select a configuration file to upload. The file must be a valid KIP configuration file of JSON format. "),i()(),n(59,"div",22)(60,"input",23,2),m("change",function(S){return d(a),g(t.uploadJsonConfig(S))}),i(),n(62,"button",24),m("click",function(){d(a);let S=x(61);return g(S.click())}),o(63," Upload "),i()(),n(64,"div",25)(65,"p"),o(66," Load the demonstration configuration and connection to Signal K demo server. WARNING: This will completely reset all your settings. "),i()(),n(67,"div",26)(68,"button",20),m("click",function(){return d(a),g(t.loadDemoConfig())}),o(69," Demo "),i()(),n(70,"div",27)(71,"p"),o(72," Reset all your settings to default. The default configuration has a single Getting Started instruction widget. Your Signal K server connection settings will remain. "),i()(),n(73,"div",28)(74,"button",20),m("click",function(){return d(a),g(t.resetConfigToDefault())}),o(75," Default "),i()(),n(76,"div",29)(77,"p"),o(78," Clear the current connection configuration. This only affects Connectivity tab settings. "),i()(),n(79,"div",30)(80,"button",20),m("click",function(){return d(a),g(t.resetConnectionToDefault())}),o(81," Connection "),i()()()()()()}if(l&2){let a=x(10),s=x(23);f("pageTitle",t.pageTitle),c(15),h(t.hasToken?15:16),c(4),f("disabled",!t.hasToken||!a.valid),c(9),h(t.hasToken?28:29),c(4),f("disabled",!t.hasToken||!s.valid),c(3),f("formGroup",t.copyConfigForm),c(5),h(t.hasToken?40:41),c(4),f("disabled",!t.copyConfigForm.valid)}},dependencies:[I,Q,K,W,J,U,Y,G,B,ie,j,ee,Z,ae,oe,te,X,H,z,re,ne],styles:['[_nghost-%COMP%]{display:block;height:100%;width:100%}.page-content[_ngcontent-%COMP%]{width:100%;height:calc(100% - 63px);overflow-y:auto;scroll-behavior:smooth;padding:0 24px 10px}.flex-item-copy[_ngcontent-%COMP%]{flex:2 1 41%;padding:10px 20px;border-radius:15px}.flex-item-reset[_ngcontent-%COMP%]{flex:1 1 100%;padding:10px 20px;border-radius:15px}a[_ngcontent-%COMP%]{font-size:14px}a[_ngcontent-%COMP%]:hover{text-decoration:underline;cursor:pointer}a[_ngcontent-%COMP%]:link, a[_ngcontent-%COMP%]:visited{color:#8ab4f8;text-decoration:none}.warningText[_ngcontent-%COMP%]{padding-left:15px}.no-token-notice[_ngcontent-%COMP%]{height:58px;contain:content;text-align:center;font-style:italic}.mat-mdc-radio-button[_ngcontent-%COMP%] ~ .mat-radio-button[_ngcontent-%COMP%]{margin-right:16px;margin-left:16px}.config-column[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex-basis:100%;flex:1;margin:0 10px}.sources-radio-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}.sources-radio-button[_ngcontent-%COMP%]{margin:5px;margin-left:0!important}.select-config[_ngcontent-%COMP%]{margin-left:0}.config-row[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;width:100%}.btn-div[_ngcontent-%COMP%]{align-self:center}.adv-btn[_ngcontent-%COMP%]{width:100%}.config-operation-container[_ngcontent-%COMP%]{display:grid;grid-template-columns:[col-start] auto [col1-end] min-content [col2-end];grid-template-rows:[row-start] max-content [row1-end] max-content [row2-end];grid-template-areas:"download-txt download-btn" "upload-txt upload-btn" "demo-txt demo-btn" "reset-txt reset-btn" "config-txt config-btn";row-gap:20px;column-gap:10px}.upload-txt[_ngcontent-%COMP%]{grid-area:upload-txt}.upload-btn[_ngcontent-%COMP%]{grid-area:upload-btn}.download-txt[_ngcontent-%COMP%]{grid-area:download-txt}.download-btn[_ngcontent-%COMP%]{grid-area:download-btn}.demo-txt[_ngcontent-%COMP%]{grid-area:demo-txt}.demo-btn[_ngcontent-%COMP%]{grid-area:demo-btn}.reset-txt[_ngcontent-%COMP%]{grid-area:reset-txt}.reset-btn[_ngcontent-%COMP%]{grid-area:reset-btn}.config-txt[_ngcontent-%COMP%]{grid-area:config-txt}.config-btn[_ngcontent-%COMP%]{grid-area:config-btn}']})}return r})();export{Ne as SettingsConfigComponent};
1
+ import{a as re}from"./chunk-VHFBF47T.js";import{f as oe,n as ae}from"./chunk-ZBCOJLI4.js";import{h as I}from"./chunk-TXPLRBW5.js";import{a as R}from"./chunk-K22CSA3Y.js";import{a as ie}from"./chunk-2YVW3TBK.js";import{A as B,D as G,E as K,H,K as z,N as Y,P as $,Q,R as X,T as Z,_ as ee,ca as te,da as ne,g as N,h as V,i as A,r as W,t as q,w as J,x as U}from"./chunk-TA4GACKT.js";import{$b as _,Aa as g,Cc as E,Ec as w,Fc as T,Fe as j,Gc as y,Nc as F,Sb as v,Tb as h,Ub as L,Vb as P,Wb as M,Xb as k,Yb as f,Zb as n,_b as i,f as O,gc as b,ic as m,kc as u,lb as c,ta as C,uc as x,wb as D,za as d,zc as o}from"./chunk-35L7BBBD.js";var le=()=>({standalone:!1});function se(r,p){r&1&&(n(0,"div"),o(1,' Writing to the server requires "Login to Server" authentication or a Device token '),i())}function ce(r,p){if(r&1){let e=b();n(0,"div")(1,"mat-form-field",31)(2,"mat-label"),o(3,"Scope"),i(),n(4,"mat-select",32),y("ngModelChange",function(t){d(e);let a=u();return T(a.saveConfigScope,t)||(a.saveConfigScope=t),g(t)}),n(5,"mat-option",33),o(6," Global "),i(),n(7,"mat-option",34),o(8," User "),i()()(),n(9,"mat-form-field",35)(10,"mat-label"),o(11,"Configuration Name"),i(),n(12,"input",36),y("ngModelChange",function(t){d(e);let a=u();return T(a.saveConfigName,t)||(a.saveConfigName=t),g(t)}),i()(),v(13,se,2,0,"div"),i()}if(r&2){let e=u();c(4),w("ngModel",e.saveConfigScope),c(8),w("ngModel",e.saveConfigName),f("ngModelOptions",F(4,le)),c(),h(e.hasToken?-1:13)}}function de(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Server authentication or Device Token required"),i()())}function ge(r,p){if(r&1&&(n(0,"mat-option",39),o(1),i()),r&2){let e=p.$implicit;f("value",e),c(),E(" ",e.scope," / ",e.name," ")}}function pe(r,p){if(r&1){let e=b();n(0,"div")(1,"mat-form-field",37)(2,"mat-label"),o(3,"Configuration"),i(),n(4,"mat-select",38),y("ngModelChange",function(t){d(e);let a=u();return T(a.deleteConfigItem,t)||(a.deleteConfigItem=t),g(t)}),M(5,ge,2,3,"mat-option",39,P),i()()()}if(r&2){let e=u();c(4),w("ngModel",e.deleteConfigItem),c(),k(e.serverConfigList)}}function me(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Authentication or Device Token required"),i()())}function fe(r,p){if(r&1&&(n(0,"mat-option",39),o(1),i()),r&2){let e=p.$implicit;f("value",e),c(),E(" ",e.scope," / ",e.name," ")}}function ue(r,p){if(r&1&&(n(0,"div")(1,"mat-form-field",37)(2,"mat-label"),o(3,"Configuration"),i(),n(4,"mat-select",40),M(5,fe,2,3,"mat-option",39,L),i()()()),r&2){let e=u();c(5),k(e.serverConfigList)}}function Ce(r,p){r&1&&(n(0,"div",10)(1,"p"),o(2,"Authentication or Device Token required"),i()())}var Ne=(()=>{class r{appSettingsService=C(A);storageSvc=C(V);appService=C(R);auth=C(N);fb=C($);pageTitle="Configurations";hasToken=!1;isTokenTypeDevice=!1;tokenSub;supportApplicationData=!1;serverConfigList=[];serverUpgradableConfigList=[];copyConfigForm;storageLocation=null;locations=["Local Storage","Server Storage"];saveConfigName=null;saveConfigScope=null;deleteConfigItem;jsonData=null;ngOnInit(){this.tokenSub=this.auth.authToken$.subscribe(e=>{e&&e.token?(this.hasToken=!0,this.isTokenTypeDevice=e.isDeviceAccessToken,e.isDeviceAccessToken?this.saveConfigScope="global":this.saveConfigScope="user"):this.hasToken=!1}),this.copyConfigForm=this.fb.group({sourceTarget:[{value:"",disabled:!1},q.required]}),this.supportApplicationData=this.storageSvc.isAppDataSupported,this.hasToken&&this.getServerConfigList()}getServerConfigList(e){this.supportApplicationData&&this.storageSvc.listConfigs(e).then(l=>{let t=l.filter(a=>!(a.scope==="user"&&a.name==="default"));e?this.serverUpgradableConfigList=t:this.serverConfigList=t}).catch(l=>{switch(l.status){case 401:this.appService.sendSnackbarNotification("Application Storage Error: "+l.statusText+". Signal K configuration must meet the following requirements; 1) Security enabled. 2) Application Data Storage Interface: On. 3) Either Allow Readonly Access enabled, or connecting with a user.",0,!1);break;default:this.appService.sendSnackbarNotification("Error listing server configurations: "+l,3e3,!1);break}})}saveConfig(e,l,t,a,s){if(this.supportApplicationData){if(l==="user"&&t==="default"&&!s){this.appService.sendSnackbarNotification("Saving configuration with scope 'user' and name 'default' is not allowed.",5e3,!1);return}this.storageSvc.setConfig(l,t,e)?(this.appService.sendSnackbarNotification(`Configuration [${t}] saved to [${l}] storage scope`,5e3,!1),a||this.getServerConfigList()):this.appService.sendSnackbarNotification("Error saving configuration to server",0,!1)}}saveToLocalstorage(e){this.appSettingsService.replaceConfig("appConfig",e.app,!1),this.appSettingsService.replaceConfig("dashboardsConfig",e.dashboards,!1),this.appSettingsService.replaceConfig("themeConfig",e.theme,!1)}copyConfig(){return O(this,null,function*(){let e=null;try{yield this.storageSvc.getConfig(this.copyConfigForm.value.sourceTarget.scope,this.copyConfigForm.value.sourceTarget.name).then(l=>{e=l})}catch(l){this.appService.sendSnackbarNotification("Error retrieving configuration from server: "+l.statusText,3e3,!1);return}this.saveConfig(e,"user","default",!1,!0),this.appSettingsService.reloadApp()})}deleteConfig(e,l,t,a){this.storageSvc.removeItem(e,l,t),this.appService.sendSnackbarNotification(`Configuration [${l}] deleted from [${e}] storage scope`,5e3,!1),a||this.getServerConfigList()}resetConfigToDefault(){this.appSettingsService.resetSettings()}resetConnectionToDefault(){this.appSettingsService.resetConnection()}loadDemoConfig(){this.appSettingsService.loadDemoConfig()}getActiveConfig(){let e;return this.appSettingsService.useSharedConfig?e=this.getLocalConfigFromMemory():e=this.getLocalConfigFromLocalStorage(),e}getLocalConfigFromMemory(){return{app:this.appSettingsService.getAppConfig(),dashboards:this.appSettingsService.getDashboardConfig(),theme:this.appSettingsService.getThemeConfig()}}getLocalConfigFromLocalStorage(){return{app:this.appSettingsService.loadConfigFromLocalStorage("appConfig"),dashboards:this.appSettingsService.loadConfigFromLocalStorage("dashboardsConfig"),theme:this.appSettingsService.loadConfigFromLocalStorage("themeConfig")}}downloadJsonConfig(){let e=this.getActiveConfig(),l=JSON.stringify(e,null,2),t=new Blob([l],{type:"application/json"}),a=window.URL.createObjectURL(t),s=document.createElement("a");s.href=a,s.download="KipConfig.json",document.body.appendChild(s),s.click(),document.body.removeChild(s),window.URL.revokeObjectURL(a)}uploadJsonConfig(e){let t=e.target.files?.[0];if(t&&t.type==="application/json"){let a=new FileReader;a.onload=s=>{try{this.jsonData=JSON.parse(s.target?.result),this.hasToken?this.saveConfig(this.jsonData,"user","default",!1,!0):this.saveToLocalstorage(this.jsonData),this.appSettingsService.reloadApp()}catch(S){this.appService.sendSnackbarNotification("Invalid JSON file",3e3,!1),console.error("Invalid JSON file:",S)}},a.readAsText(t)}else this.appService.sendSnackbarNotification("Please select a valid JSON file",0,!1)}ngOnDestroy(){this.tokenSub.unsubscribe()}static \u0275fac=function(l){return new(l||r)};static \u0275cmp=D({type:r,selectors:[["settings-config"]],decls:82,vars:8,consts:[["saveConfigForm","ngForm"],["deleteConfigForm","ngForm"],["fileInput",""],[3,"pageTitle"],[1,"page-content"],["routerLink","/help"],[1,"flex-container"],[1,"flex-item-rounded-card","rounded-card-color"],["name","saveConfigForm",3,"ngSubmit"],[2,"margin-bottom","16px"],[1,"no-token-notice"],[1,"formActionFooter"],[1,"formActionDivider"],["mat-flat-button","","type","submit","color","accent",3,"disabled"],["name","deleteConfigForm",3,"ngSubmit"],[3,"ngSubmit","formGroup"],[1,"flex-item-reset","rounded-card-color"],[1,"config-operation-container",2,"margin-top","20px"],[1,"download-txt"],[1,"download-btn","btn-div"],["mat-flat-button","","type","button",1,"adv-btn",3,"click"],[1,"upload-txt"],[1,"upload-btn","btn-div"],["type","file","accept",".json","hidden","",3,"change"],["mat-flat-button","",1,"adv-btn",3,"click"],[1,"demo-txt"],[1,"demo-btn","btn-div"],[1,"reset-txt"],[1,"reset-btn","btn-div"],[1,"config-txt"],[1,"config-btn","btn-div"],[2,"width","25%"],["name","serverConfiScope","required","",3,"ngModelChange","ngModel"],["value","global"],["value","user"],[2,"width","70%","padding-left","3%"],["matInput","","name","serverConfigName","placeholder","Enter a name for the configuration","required","",3,"ngModelChange","ngModel","ngModelOptions"],[2,"width","100%"],["name","selectedDeleteItem","required","",3,"ngModelChange","ngModel"],[3,"value"],["formControlName","sourceTarget"]],template:function(l,t){if(l&1){let a=b();_(0,"page-header",3),n(1,"div",4)(2,"p"),o(3," Recommended Reading: To understand configuration management and storage options, consult the "),n(4,"a",5),o(5,"Configuration Management Help"),i(),o(6," section. "),i(),n(7,"div",6)(8,"div",7)(9,"form",8,0),m("ngSubmit",function(){return d(a),g(t.saveConfig(t.getActiveConfig(),t.saveConfigScope,t.saveConfigName))}),n(11,"h2"),o(12,"Backup"),i(),n(13,"p",9),o(14," Create a backup of the current active configuration on the server. "),i(),v(15,ce,14,5,"div")(16,de,3,0,"div",10),n(17,"div",11),_(18,"mat-divider",12),n(19,"button",13),o(20," Create "),i()()()(),n(21,"div",7)(22,"form",14,1),m("ngSubmit",function(){return d(a),g(t.deleteConfig(t.deleteConfigItem.scope,t.deleteConfigItem.name))}),n(24,"h2"),o(25,"Delete"),i(),n(26,"p",9),o(27," Select a backup configuration to permanently delete from the server. "),i(),v(28,pe,7,1,"div")(29,me,3,0,"div",10),n(30,"div",11),_(31,"mat-divider",12),n(32,"button",13),o(33," Delete "),i()()()(),n(34,"div",7)(35,"form",15),m("ngSubmit",function(){return d(a),g(t.copyConfig())}),n(36,"h2"),o(37,"Restore"),i(),n(38,"p",9),o(39," Replace the current configuration with a backup from the server. "),i(),v(40,ue,7,0,"div")(41,Ce,3,0,"div",10),n(42,"div",11),_(43,"mat-divider",12),n(44,"button",13),o(45," Restore "),i()()()(),n(46,"div",16)(47,"h2"),o(48,"Advanced"),i(),n(49,"div",17)(50,"div",18)(51,"p"),o(52,"Download the active configuration to a file."),i()(),n(53,"div",19)(54,"button",20),m("click",function(){return d(a),g(t.downloadJsonConfig())}),o(55," Download "),i()(),n(56,"div",21)(57,"p"),o(58," Select a configuration file to upload. The file must be a valid KIP configuration file of JSON format. "),i()(),n(59,"div",22)(60,"input",23,2),m("change",function(S){return d(a),g(t.uploadJsonConfig(S))}),i(),n(62,"button",24),m("click",function(){d(a);let S=x(61);return g(S.click())}),o(63," Upload "),i()(),n(64,"div",25)(65,"p"),o(66," Load the demonstration configuration and connection to Signal K demo server. WARNING: This will completely reset all your settings. "),i()(),n(67,"div",26)(68,"button",20),m("click",function(){return d(a),g(t.loadDemoConfig())}),o(69," Demo "),i()(),n(70,"div",27)(71,"p"),o(72," Reset all your settings to default. The default configuration has a single Getting Started instruction widget. Your Signal K server connection settings will remain. "),i()(),n(73,"div",28)(74,"button",20),m("click",function(){return d(a),g(t.resetConfigToDefault())}),o(75," Default "),i()(),n(76,"div",29)(77,"p"),o(78," Clear the current connection configuration. This only affects Connectivity tab settings. "),i()(),n(79,"div",30)(80,"button",20),m("click",function(){return d(a),g(t.resetConnectionToDefault())}),o(81," Connection "),i()()()()()()}if(l&2){let a=x(10),s=x(23);f("pageTitle",t.pageTitle),c(15),h(t.hasToken?15:16),c(4),f("disabled",!t.hasToken||!a.valid),c(9),h(t.hasToken?28:29),c(4),f("disabled",!t.hasToken||!s.valid),c(3),f("formGroup",t.copyConfigForm),c(5),h(t.hasToken?40:41),c(4),f("disabled",!t.copyConfigForm.valid)}},dependencies:[I,Q,K,W,J,U,Y,G,B,ie,j,ee,Z,ae,oe,te,X,H,z,re,ne],styles:['[_nghost-%COMP%]{display:block;height:100%;width:100%}.page-content[_ngcontent-%COMP%]{width:100%;height:calc(100% - 63px);overflow-y:auto;scroll-behavior:smooth;padding:0 24px 10px}.flex-item-copy[_ngcontent-%COMP%]{flex:2 1 41%;padding:10px 20px;border-radius:15px}.flex-item-reset[_ngcontent-%COMP%]{flex:1 1 100%;padding:10px 20px;border-radius:15px}a[_ngcontent-%COMP%]{font-size:14px}a[_ngcontent-%COMP%]:hover{text-decoration:underline;cursor:pointer}a[_ngcontent-%COMP%]:link, a[_ngcontent-%COMP%]:visited{color:#8ab4f8;text-decoration:none}.warningText[_ngcontent-%COMP%]{padding-left:15px}.no-token-notice[_ngcontent-%COMP%]{height:58px;contain:content;text-align:center;font-style:italic}.mat-mdc-radio-button[_ngcontent-%COMP%] ~ .mat-radio-button[_ngcontent-%COMP%]{margin-right:16px;margin-left:16px}.config-column[_ngcontent-%COMP%]{display:flex;flex-direction:column;flex-basis:100%;flex:1;margin:0 10px}.sources-radio-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}.sources-radio-button[_ngcontent-%COMP%]{margin:5px;margin-left:0!important}.select-config[_ngcontent-%COMP%]{margin-left:0}.config-row[_ngcontent-%COMP%]{display:flex;flex-direction:row;flex-wrap:wrap;width:100%}.btn-div[_ngcontent-%COMP%]{align-self:center}.adv-btn[_ngcontent-%COMP%]{width:100%}.config-operation-container[_ngcontent-%COMP%]{display:grid;grid-template-columns:[col-start] auto [col1-end] min-content [col2-end];grid-template-rows:[row-start] max-content [row1-end] max-content [row2-end];grid-template-areas:"download-txt download-btn" "upload-txt upload-btn" "demo-txt demo-btn" "reset-txt reset-btn" "config-txt config-btn";row-gap:20px;column-gap:10px}.upload-txt[_ngcontent-%COMP%]{grid-area:upload-txt}.upload-btn[_ngcontent-%COMP%]{grid-area:upload-btn}.download-txt[_ngcontent-%COMP%]{grid-area:download-txt}.download-btn[_ngcontent-%COMP%]{grid-area:download-btn}.demo-txt[_ngcontent-%COMP%]{grid-area:demo-txt}.demo-btn[_ngcontent-%COMP%]{grid-area:demo-btn}.reset-txt[_ngcontent-%COMP%]{grid-area:reset-txt}.reset-btn[_ngcontent-%COMP%]{grid-area:reset-btn}.config-txt[_ngcontent-%COMP%]{grid-area:config-txt}.config-btn[_ngcontent-%COMP%]{grid-area:config-btn}']})}return r})();export{Ne as SettingsConfigComponent};