@signalk/freeboard-sk 3.3.0 → 3.4.0-beta.1
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 +2 -2
- package/public/3rdpartylicenses.txt +37 -37
- package/public/assets/features/split-view-1.jpg +0 -0
- package/public/assets/features/split-view-2.jpg +0 -0
- package/public/assets/features/toolbar-overflow-1.jpg +0 -0
- package/public/assets/features/toolbar-overflow-2.jpg +0 -0
- package/public/assets/features-corpus.json +1 -1
- package/public/assets/help/index.html +32 -1
- package/public/{chunk-YSHHABBQ.js → chunk-5B3P22GG.js} +1 -1
- package/public/{chunk-PD55PKQG.js → chunk-5WUOKMEL.js} +5 -5
- package/public/{chunk-MYBGWSLC.js → chunk-CXU2QR7B.js} +1 -1
- package/public/chunk-D7NY4CGQ.js +1 -0
- package/public/{chunk-62WHV6CJ.js → chunk-DXAIA7TN.js} +4 -4
- package/public/chunk-FESHPCKG.js +106 -0
- package/public/{chunk-PAHYECKY.js → chunk-LZQNRNTA.js} +1 -1
- package/public/chunk-M3QKKNN7.js +1 -0
- package/public/{chunk-X6D4D6EN.js → chunk-M4D7Z434.js} +1 -1
- package/public/chunk-NL5F2VEH.js +4399 -0
- package/public/{chunk-45ZTFAA5.js → chunk-OMAUXPDZ.js} +1 -1
- package/public/{chunk-MX5HWKAH.js → chunk-RABBT5ST.js} +1 -1
- package/public/{chunk-Z5VKGWZC.js → chunk-SU5TGPFJ.js} +1 -1
- package/public/{chunk-ISXARX6U.js → chunk-U7APAW37.js} +1 -1
- package/public/{chunk-X2BSGTPL.js → chunk-W2UT4HJG.js} +1 -1
- package/public/chunk-XHD652B2.js +1 -0
- package/public/{chunk-RG7WQ7O2.js → chunk-XHH2BWBG.js} +1 -1
- package/public/chunk-XIEUBZE5.js +1 -0
- package/public/{chunk-T7ZWMXKZ.js → chunk-XRUZGBPD.js} +1 -1
- package/public/{chunk-YZN4NRWW.js → chunk-XSBLUIEK.js} +1 -1
- package/public/chunk-YP3ILUPZ.js +1 -0
- package/public/chunk-YXEZPMKV.js +1 -0
- package/public/chunk-ZJLAX3N2.js +1 -0
- package/public/index.html +2 -2
- package/public/main-C7W4SDMX.js +358 -0
- package/public/{styles-BRU77GKR.css → styles-ADI62PD5.css} +1 -1
- package/public/worker-KSHRWMJ6.js +3 -0
- package/public/chunk-2KQASZ2P.js +0 -1
- package/public/chunk-6E2BDKCH.js +0 -106
- package/public/chunk-B3ZGKAZU.js +0 -4170
- package/public/chunk-BXGNCKBA.js +0 -1
- package/public/chunk-EGNX7VBY.js +0 -1
- package/public/chunk-I33LU6L4.js +0 -1
- package/public/chunk-I75RV7GQ.js +0 -1
- package/public/chunk-NRPRHL2L.js +0 -1
- package/public/chunk-V2SBXN4Z.js +0 -1
- package/public/main-XWH2CEAU.js +0 -468
- package/public/worker-PCWM7FLK.js +0 -3
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
var Io=Object.create;var xn=Object.defineProperty;var Co=Object.getOwnPropertyDescriptor;var Eo=Object.getOwnPropertyNames;var qo=Object.getPrototypeOf,No=Object.prototype.hasOwnProperty;var c=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(r){throw t=0,r}};var jo=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Eo(t))!No.call(e,i)&&i!==r&&xn(e,i,{get:()=>t[i],enumerable:!(n=Co(t,i))||n.enumerable});return e};var yn=(e,t,r)=>(r=e!=null?Io(qo(e)):{},jo(t||!e||!e.__esModule?xn(r,"default",{value:e,enumerable:!0}):r,e));var _=c(g=>{"use strict";Object.defineProperty(g,"__esModule",{value:!0});g.timeConversion=g.sexagesimalPattern=g.longitudeKeys=g.latitudeKeys=g.earthRadius=g.distanceConversion=g.areaConversion=g.altitudeKeys=g.RAD_TO_DEG=g.MINLON=g.MINLAT=g.MAXLON=g.MAXLAT=g.DEG_TO_RAD=void 0;var _c=g.sexagesimalPattern=/^([0-9]{1,3})°\s*([0-9]{1,3}(?:\.(?:[0-9]{1,}))?)['′]\s*(([0-9]{1,3}(\.([0-9]{1,}))?)["″]\s*)?([NEOSW]?)$/,Mc=g.earthRadius=6378137,Sc=g.MINLAT=-90,Pc=g.MAXLAT=90,Tc=g.MINLON=-180,Ac=g.MAXLON=180,kc=g.DEG_TO_RAD=Math.PI/180,Oc=g.RAD_TO_DEG=180/Math.PI,Rc=g.longitudeKeys=["lng","lon","longitude",0],wc=g.latitudeKeys=["lat","latitude",1],Lc=g.altitudeKeys=["alt","altitude","elevation","elev",2],Dc=g.distanceConversion={m:1,km:.001,cm:100,mm:1e3,mi:1/1609.344,sm:1/1852.216,ft:100/30.48,in:100/2.54,yd:1/.9144},Ic=g.timeConversion={m:60,h:3600,d:86400},N=g.areaConversion={m2:1,km2:1e-6,ha:1e-4,a:.01,ft2:10.763911,yd2:1.19599,in2:1550.0031};N.sqm=N.m2;N.sqkm=N.km2;N.sqft=N.ft2;N.sqyd=N.yd2;N.sqin=N.in2});var ve=c(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.default=void 0;var zo=(e,t)=>{if(e==null)throw new Error(`'${e}' is no valid coordinate.`);return t.reduce((r,n)=>Object.prototype.hasOwnProperty.call(e,n)&&n!==void 0&&r===void 0?(r=n,n):r,void 0)},Ec=Ge.default=zo});var _e=c(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.default=void 0;var Xo=e=>{let t=e.toString().trim();return isNaN(parseFloat(t))?!1:parseFloat(t)===Number(t)},Nc=ze.default=Xo});var Me=c(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.default=void 0;var Zo=_(),Yo=e=>Zo.sexagesimalPattern.test(e.toString().trim()),Kc=Xe.default=Yo});var Se=c(Ze=>{"use strict";Object.defineProperty(Ze,"__esModule",{value:!0});Ze.default=void 0;var Jo=_(),Qo=e=>{let t=new RegExp(Jo.sexagesimalPattern).exec(e.toString().trim());if(t===null)throw new Error("Given value is not in sexagesimal format");let r=Number(t[2])/60||0,n=Number(t[4])/3600||0,i=parseFloat(t[1])+r+n;return["S","W"].includes(t[7])?-i:i},Fc=Ze.default=Qo});var Je=c(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.default=void 0;var xr=_(),yr=es(ve());function es(e){return e&&e.__esModule?e:{default:e}}var ts=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{longitude:xr.longitudeKeys,latitude:xr.latitudeKeys,altitude:xr.altitudeKeys},r=(0,yr.default)(e,t.longitude),n=(0,yr.default)(e,t.latitude),i=(0,yr.default)(e,t.altitude);return{latitude:n,longitude:r,...i?{altitude:i}:{}}},Hc=Ye.default=ts});var _r=c(Qe=>{"use strict";Object.defineProperty(Qe,"__esModule",{value:!0});Qe.default=void 0;var rs=vr(_e()),ns=vr(Me()),is=vr(Se()),Dn=_();function vr(e){return e&&e.__esModule?e:{default:e}}var In=e=>{if((0,rs.default)(e)){let t=parseFloat(e);return!(t>Dn.MAXLAT||t<Dn.MINLAT)}return(0,ns.default)(e)?In((0,is.default)(e)):!1},$c=Qe.default=In});var Sr=c(et=>{"use strict";Object.defineProperty(et,"__esModule",{value:!0});et.default=void 0;var os=Mr(_e()),ss=Mr(Me()),as=Mr(Se()),Cn=_();function Mr(e){return e&&e.__esModule?e:{default:e}}var En=e=>{if((0,os.default)(e)){let t=parseFloat(e);return!(t>Cn.MAXLON||t<Cn.MINLON)}return(0,ss.default)(e)?En((0,as.default)(e)):!1},Gc=et.default=En});var Tr=c(tt=>{"use strict";Object.defineProperty(tt,"__esModule",{value:!0});tt.default=void 0;var us=Pr(Je()),qn=Pr(_r()),Nn=Pr(Sr());function Pr(e){return e&&e.__esModule?e:{default:e}}var ls=e=>{let{latitude:t,longitude:r}=(0,us.default)(e);if(Array.isArray(e)&&e.length>=2)return(0,Nn.default)(e[0])&&(0,qn.default)(e[1]);if(t===void 0||r===void 0)return!1;let n=e[r],i=e[t];return i===void 0||n===void 0?!1:(0,qn.default)(i)&&(0,Nn.default)(n)},Xc=tt.default=ls});var nt=c(rt=>{"use strict";Object.defineProperty(rt,"__esModule",{value:!0});rt.default=void 0;var cs=Te(_e()),fs=Te(Me()),ds=Te(Se()),jn=Te(Tr()),ms=Te(Je());function Te(e){return e&&e.__esModule?e:{default:e}}var Pe=e=>{if((0,cs.default)(e))return Number(e);if((0,fs.default)(e))return(0,ds.default)(e);if((0,jn.default)(e)){let t=(0,ms.default)(e);return Array.isArray(e)?e.map((r,n)=>[0,1].includes(n)?Pe(r):r):{...e,...t.latitude&&{[t.latitude]:Pe(e[t.latitude])},...t.longitude&&{[t.longitude]:Pe(e[t.longitude])}}}return Array.isArray(e)?e.map(t=>(0,jn.default)(t)?Pe(t):t):e},Yc=rt.default=Pe});var w=c(it=>{"use strict";Object.defineProperty(it,"__esModule",{value:!0});it.default=void 0;var ps=_(),gs=Kn(ve()),hs=Kn(nt());function Kn(e){return e&&e.__esModule?e:{default:e}}var bs=(e,t)=>{let r=(0,gs.default)(e,ps.latitudeKeys);if(r==null)return;let n=e[r];return t===!0?n:(0,hs.default)(n)},Qc=it.default=bs});var L=c(ot=>{"use strict";Object.defineProperty(ot,"__esModule",{value:!0});ot.default=void 0;var xs=_(),ys=Un(ve()),vs=Un(nt());function Un(e){return e&&e.__esModule?e:{default:e}}var _s=(e,t)=>{let r=(0,ys.default)(e,xs.longitudeKeys);if(r==null)return;let n=e[r];return t===!0?n:(0,vs.default)(n)},tf=ot.default=_s});var j=c(st=>{"use strict";Object.defineProperty(st,"__esModule",{value:!0});st.default=void 0;var Ms=_(),Ss=e=>e*Ms.DEG_TO_RAD,nf=st.default=Ss});var X=c(at=>{"use strict";Object.defineProperty(at,"__esModule",{value:!0});at.default=void 0;var Ps=_(),Ts=e=>e*Ps.RAD_TO_DEG,sf=at.default=Ts});var Vn=c(lt=>{"use strict";Object.defineProperty(lt,"__esModule",{value:!0});lt.default=void 0;var As=ut(w()),ks=ut(L()),Ar=ut(j()),kr=ut(X()),Fn=_();function ut(e){return e&&e.__esModule?e:{default:e}}var Os=function(e,t,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:6371e3,i=(0,As.default)(e),o=(0,ks.default)(e),s=t/n,a=(0,Ar.default)(r),u=(0,Ar.default)(i),p=(0,Ar.default)(o),m=Math.asin(Math.sin(u)*Math.cos(s)+Math.cos(u)*Math.sin(s)*Math.cos(a)),h=p+Math.atan2(Math.sin(a)*Math.sin(s)*Math.cos(u),Math.cos(s)-Math.sin(u)*Math.sin(m)),b=(0,kr.default)(h);return(b<Fn.MINLON||b>Fn.MAXLON)&&(h=(h+3*Math.PI)%(2*Math.PI)-Math.PI,b=(0,kr.default)(h)),{latitude:(0,kr.default)(m),longitude:b}},uf=lt.default=Os});var Hn=c(ct=>{"use strict";Object.defineProperty(ct,"__esModule",{value:!0});ct.default=void 0;var Rs=_(),ws=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"m",r=Rs.areaConversion[t];if(r)return e*r;throw new Error("Invalid unit used for area conversion.")},cf=ct.default=ws});var Bn=c(ft=>{"use strict";Object.defineProperty(ft,"__esModule",{value:!0});ft.default=void 0;var Ls=_(),Ds=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"m",r=Ls.distanceConversion[t];if(r)return e*r;throw new Error("Invalid unit used for distance conversion.")},df=ft.default=Ds});var $n=c(mt=>{"use strict";Object.defineProperty(mt,"__esModule",{value:!0});mt.default=void 0;var dt=_(),Is=function(e){switch(arguments.length>1&&arguments[1]!==void 0?arguments[1]:"kmh"){case"kmh":return e*dt.timeConversion.h*dt.distanceConversion.km;case"mph":return e*dt.timeConversion.h*dt.distanceConversion.mi;default:return e}},pf=mt.default=Is});var Wn=c(pt=>{"use strict";Object.defineProperty(pt,"__esModule",{value:!0});pt.default=void 0;var Cs=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:4,r=Math.pow(10,t);return Math.round(e*r)/r},Es=e=>{let[t,r]=e.toString().split("."),n=Math.abs(Number(t)),i=+("0."+(r||0))*60,o=i.toString().split("."),s=Math.floor(i),a=Cs(+("0."+(o[1]||0))*60).toString(),[u,p="0"]=a.split(".");return n+"\xB0 "+s.toString().padStart(2,"0")+"' "+u.padStart(2,"0")+"."+p.padEnd(1,"0")+'"'},hf=pt.default=Es});var Or=c(gt=>{"use strict";Object.defineProperty(gt,"__esModule",{value:!0});gt.default=void 0;var qs=e=>e>1?1:e<-1?-1:e,xf=gt.default=qs});var B=c(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.default=void 0;var Gn=ht(w()),zn=ht(L()),Rr=ht(j()),Ns=ht(Or()),js=_();function ht(e){return e&&e.__esModule?e:{default:e}}var Ks=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;r=isNaN(r)?1:r;let n=(0,Rr.default)((0,Gn.default)(e)),i=(0,Rr.default)((0,Gn.default)(t)),o=(0,Rr.default)((0,zn.default)(e)-(0,zn.default)(t)),s=Math.acos((0,Ns.default)(Math.sin(i)*Math.sin(n)+Math.cos(i)*Math.cos(n)*Math.cos(o)))*js.earthRadius;return Math.round(s/r)*r},vf=bt.default=Ks});var wr=c(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.default=void 0;var Xn=Us(B());function Us(e){return e&&e.__esModule?e:{default:e}}var Fs=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Xn.default;return r=typeof r=="function"?r:Xn.default,t.slice().sort((n,i)=>r(e,n)-r(e,i))},Mf=xt.default=Fs});var Zn=c(yt=>{"use strict";Object.defineProperty(yt,"__esModule",{value:!0});yt.default=void 0;var Vs=Hs(wr());function Hs(e){return e&&e.__esModule?e:{default:e}}var Bs=(e,t)=>(0,Vs.default)(e,t)[0],Pf=yt.default=Bs});var Qn=c(vt=>{"use strict";Object.defineProperty(vt,"__esModule",{value:!0});vt.default=void 0;var Lr=Dr(j()),$s=Dr(w()),Yn=Dr(L()),Jn=_();function Dr(e){return e&&e.__esModule?e:{default:e}}var Ws=e=>{let t=0;if(e.length>2){let r,n,i;for(let o=0;o<e.length;o++){o===e.length-2?(r=e.length-2,n=e.length-1,i=0):o===e.length-1?(r=e.length-1,n=0,i=1):(r=o,n=o+1,i=o+2);let s=(0,Yn.default)(e[r]),a=(0,$s.default)(e[n]),u=(0,Yn.default)(e[i]);t+=((0,Lr.default)(u)-(0,Lr.default)(s))*Math.sin((0,Lr.default)(a))}t=t*Jn.earthRadius*Jn.earthRadius/2}return Math.abs(t)},Af=vt.default=Ws});var Ir=c(_t=>{"use strict";Object.defineProperty(_t,"__esModule",{value:!0});_t.default=void 0;var Gs=ei(w()),zs=ei(L());function ei(e){return e&&e.__esModule?e:{default:e}}var Xs=e=>{if(Array.isArray(e)===!1||e.length===0)throw new Error("No points were given.");return e.reduce((t,r)=>{let n=(0,Gs.default)(r),i=(0,zs.default)(r);return{maxLat:Math.max(n,t.maxLat),minLat:Math.min(n,t.minLat),maxLng:Math.max(i,t.maxLng),minLng:Math.min(i,t.minLng)}},{maxLat:-1/0,minLat:1/0,maxLng:-1/0,minLng:1/0})},Of=_t.default=Xs});var ti=c(Pt=>{"use strict";Object.defineProperty(Pt,"__esModule",{value:!0});Pt.default=void 0;var Zs=St(w()),Ys=St(L()),se=St(j()),Mt=St(X()),Ae=_();function St(e){return e&&e.__esModule?e:{default:e}}var Js=(e,t)=>{let r=(0,Zs.default)(e),n=(0,Ys.default)(e),i=(0,se.default)(r),o=(0,se.default)(n),s=t/Ae.earthRadius,a=i-s,u=i+s,p=(0,se.default)(Ae.MAXLAT),m=(0,se.default)(Ae.MINLAT),h=(0,se.default)(Ae.MAXLON),b=(0,se.default)(Ae.MINLON),S,v;if(a>m&&u<p){let O=Math.asin(Math.sin(s)/Math.cos(i));S=o-O,S<b&&(S+=Math.PI*2),v=o+O,v>h&&(v-=Math.PI*2)}else a=Math.max(a,m),u=Math.min(u,p),S=b,v=h;return[{latitude:(0,Mt.default)(a),longitude:(0,Mt.default)(S)},{latitude:(0,Mt.default)(u),longitude:(0,Mt.default)(v)}]},wf=Pt.default=Js});var ii=c(At=>{"use strict";Object.defineProperty(At,"__esModule",{value:!0});At.default=void 0;var Qs=Tt(w()),ea=Tt(L()),ri=Tt(j()),ni=Tt(X());function Tt(e){return e&&e.__esModule?e:{default:e}}var ta=e=>{if(Array.isArray(e)===!1||e.length===0)return!1;let t=e.length,r=e.reduce((s,a)=>{let u=(0,ri.default)((0,Qs.default)(a)),p=(0,ri.default)((0,ea.default)(a));return{X:s.X+Math.cos(u)*Math.cos(p),Y:s.Y+Math.cos(u)*Math.sin(p),Z:s.Z+Math.sin(u)}},{X:0,Y:0,Z:0}),n=r.X/t,i=r.Y/t,o=r.Z/t;return{longitude:(0,ni.default)(Math.atan2(i,n)),latitude:(0,ni.default)(Math.atan2(o,Math.sqrt(n*n+i*i)))}},Df=At.default=ta});var oi=c(kt=>{"use strict";Object.defineProperty(kt,"__esModule",{value:!0});kt.default=void 0;var ra=na(Ir());function na(e){return e&&e.__esModule?e:{default:e}}var ia=e=>{let t=(0,ra.default)(e),r=t.minLat+(t.maxLat-t.minLat)/2,n=t.minLng+(t.maxLng-t.minLng)/2;return{latitude:parseFloat(r.toFixed(6)),longitude:parseFloat(n.toFixed(6))}},Cf=kt.default=ia});var Cr=c(wt=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.default=void 0;var si=Rt(w()),ai=Rt(L()),Ot=Rt(j()),oa=Rt(X());function Rt(e){return e&&e.__esModule?e:{default:e}}var sa=(e,t)=>{let r=(0,Ot.default)((0,ai.default)(t))-(0,Ot.default)((0,ai.default)(e)),n=Math.log(Math.tan((0,Ot.default)((0,si.default)(t))/2+Math.PI/4)/Math.tan((0,Ot.default)((0,si.default)(e))/2+Math.PI/4));return Math.abs(r)>Math.PI&&(r>0?r=(Math.PI*2-r)*-1:r=Math.PI*2+r),((0,oa.default)(Math.atan2(r,n))+360)%360},qf=wt.default=sa});var li=c(Lt=>{"use strict";Object.defineProperty(Lt,"__esModule",{value:!0});Lt.default=void 0;var ui=aa(Cr());function aa(e){return e&&e.__esModule?e:{default:e}}var ua=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ui.default,n=typeof r=="function"?r(e,t):(0,ui.default)(e,t);if(isNaN(n))throw new Error("Could not calculate bearing for given points. Check your bearing function");switch(Math.round(n/22.5)){case 1:return"NNE";case 2:return"NE";case 3:return"ENE";case 4:return"E";case 5:return"ESE";case 6:return"SE";case 7:return"SSE";case 8:return"S";case 9:return"SSW";case 10:return"SW";case 11:return"WSW";case 12:return"W";case 13:return"WNW";case 14:return"NW";case 15:return"NNW";default:return"N"}},jf=Lt.default=ua});var qr=c(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.default=void 0;var Er=fi(B()),ci=fi(Or());function fi(e){return e&&e.__esModule?e:{default:e}}var la=function(e,t,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,i=(0,Er.default)(t,e,n),o=(0,Er.default)(e,r,n),s=(0,Er.default)(t,r,n),a=Math.acos((0,ci.default)((i*i+s*s-o*o)/(2*i*s))),u=Math.acos((0,ci.default)((o*o+s*s-i*i)/(2*o*s)));return i===0||o===0?0:s===0||a>Math.PI/2?i:u>Math.PI/2?o:Math.sin(a)*i},Uf=Dt.default=la});var pi=c(Ct=>{"use strict";Object.defineProperty(Ct,"__esModule",{value:!0});Ct.default=void 0;var di=It(w()),mi=It(L()),F=It(j()),ca=It(X());function It(e){return e&&e.__esModule?e:{default:e}}var fa=(e,t)=>{let r=(0,di.default)(t),n=(0,mi.default)(t),i=(0,di.default)(e),o=(0,mi.default)(e);return((0,ca.default)(Math.atan2(Math.sin((0,F.default)(n)-(0,F.default)(o))*Math.cos((0,F.default)(r)),Math.cos((0,F.default)(i))*Math.sin((0,F.default)(r))-Math.sin((0,F.default)(i))*Math.cos((0,F.default)(r))*Math.cos((0,F.default)(n)-(0,F.default)(o))))+360)%360},Vf=Ct.default=fa});var gi=c(Et=>{"use strict";Object.defineProperty(Et,"__esModule",{value:!0});Et.default=void 0;var da=ma(B());function ma(e){return e&&e.__esModule?e:{default:e}}var pa=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:da.default;return e.reduce((r,n)=>(typeof r=="object"&&r.last!==null&&(r.distance+=t(n,r.last)),r.last=n,r),{last:null,distance:0}).distance},Bf=Et.default=pa});var yi=c(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.default=void 0;var hi=jr(w()),bi=jr(L()),Nr=jr(j()),xi=_();function jr(e){return e&&e.__esModule?e:{default:e}}var ga=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;r=isNaN(r)?1:r;let n=(0,hi.default)(e),i=(0,bi.default)(e),o=(0,hi.default)(t),s=(0,bi.default)(t),a=6356752314245e-6,u=1/298.257223563,p=(0,Nr.default)(s-i),m,h,b,S,v,O,pn=Math.atan((1-u)*Math.tan((0,Nr.default)(parseFloat(n)))),gn=Math.atan((1-u)*Math.tan((0,Nr.default)(parseFloat(o)))),Ce=Math.sin(pn),Ee=Math.cos(pn),qe=Math.sin(gn),ee=Math.cos(gn),pe=p,hn,bn=100;do{let sr=Math.sin(pe),ar=Math.cos(pe);if(O=Math.sqrt(ee*sr*(ee*sr)+(Ee*qe-Ce*ee*ar)*(Ee*qe-Ce*ee*ar)),O===0)return 0;m=Ce*qe+Ee*ee*ar,h=Math.atan2(O,m),b=Ee*ee*sr/O,S=1-b*b,v=m-2*Ce*qe/S,isNaN(v)&&(v=0);let ur=u/16*S*(4+u*(4-3*S));hn=pe,pe=p+(1-ur)*u*b*(h+ur*O*(v+ur*m*(-1+2*v*v)))}while(Math.abs(pe-hn)>1e-12&&--bn>0);if(bn===0)return NaN;let H=S*(xi.earthRadius*xi.earthRadius-a*a)/(a*a),wo=1+H/16384*(4096+H*(-768+H*(320-175*H))),or=H/1024*(256+H*(-128+H*(74-47*H))),Lo=or*O*(v+or/4*(m*(-1+2*v*v)-or/6*v*(-3+4*O*O)*(-3+4*v*v))),Do=a*wo*(h-Lo);return Math.round(Do/r)*r},Wf=qt.default=ga});var vi=c(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.default=void 0;var ha=e=>{if(/^(NNE|NE|NNW|N)$/.test(e))return"N";if(/^(ENE|E|ESE|SE)$/.test(e))return"E";if(/^(SSE|S|SSW|SW)$/.test(e))return"S";if(/^(WSW|W|WNW|NW)$/.test(e))return"W"},zf=Nt.default=ha});var _i=c(jt=>{"use strict";Object.defineProperty(jt,"__esModule",{value:!0});jt.default=void 0;var ba=xa(B());function xa(e){return e&&e.__esModule?e:{default:e}}var ya=function(e,t){let n=(arguments.length>2&&arguments[2]!==void 0?arguments[2]:ba.default)(e,t),i=Number(t.time)-Number(e.time);return n/i*1e3},Zf=jt.default=ya});var Mi=c(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.default=void 0;var Kr=va(B());function va(e){return e&&e.__esModule?e:{default:e}}var _a=(e,t,r)=>(0,Kr.default)(t,e)+(0,Kr.default)(e,r)===(0,Kr.default)(t,r),Jf=Kt.default=_a});var Pi=c(Ft=>{"use strict";Object.defineProperty(Ft,"__esModule",{value:!0});Ft.default=void 0;var Ut=Si(w()),D=Si(L());function Si(e){return e&&e.__esModule?e:{default:e}}var Ma=(e,t)=>{let r=!1,n=t.length;for(let i=-1,o=n-1;++i<n;o=i)((0,D.default)(t[i])<=(0,D.default)(e)&&(0,D.default)(e)<(0,D.default)(t[o])||(0,D.default)(t[o])<=(0,D.default)(e)&&(0,D.default)(e)<(0,D.default)(t[i]))&&(0,Ut.default)(e)<((0,Ut.default)(t[o])-(0,Ut.default)(t[i]))*((0,D.default)(e)-(0,D.default)(t[i]))/((0,D.default)(t[o])-(0,D.default)(t[i]))+(0,Ut.default)(t[i])&&(r=!r);return r},ed=Ft.default=Ma});var Ti=c(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.default=void 0;var Sa=Pa(qr());function Pa(e){return e&&e.__esModule?e:{default:e}}var Ta=(e,t,r,n)=>(0,Sa.default)(e,t,r)<n,rd=Vt.default=Ta});var Ai=c(Ht=>{"use strict";Object.defineProperty(Ht,"__esModule",{value:!0});Ht.default=void 0;var Aa=ka(B());function ka(e){return e&&e.__esModule?e:{default:e}}var Oa=(e,t,r)=>(0,Aa.default)(e,t,.01)<r,id=Ht.default=Oa});var ki=c(Bt=>{"use strict";Object.defineProperty(Bt,"__esModule",{value:!0});Bt.default=void 0;var Ra=e=>{if(!e.startsWith("POLYGON"))throw new Error("Invalid wkt.");return e.slice(e.indexOf("(")+2,e.indexOf(")")).split(", ").map(n=>{let[i,o]=n.split(" ");return{longitude:parseFloat(i),latitude:parseFloat(o)}})},sd=Bt.default=Ra});var Oi=c(f=>{"use strict";Object.defineProperty(f,"__esModule",{value:!0});var wa={computeDestinationPoint:!0,convertArea:!0,convertDistance:!0,convertSpeed:!0,decimalToSexagesimal:!0,findNearest:!0,getAreaOfPolygon:!0,getBounds:!0,getBoundsOfDistance:!0,getCenter:!0,getCenterOfBounds:!0,getCompassDirection:!0,getCoordinateKey:!0,getCoordinateKeys:!0,getDistance:!0,getDistanceFromLine:!0,getGreatCircleBearing:!0,getLatitude:!0,getLongitude:!0,getPathLength:!0,getPreciseDistance:!0,getRhumbLineBearing:!0,getRoughCompassDirection:!0,getSpeed:!0,isDecimal:!0,isPointInLine:!0,isPointInPolygon:!0,isPointNearLine:!0,isPointWithinRadius:!0,isSexagesimal:!0,isValidCoordinate:!0,isValidLatitude:!0,isValidLongitude:!0,orderByDistance:!0,sexagesimalToDecimal:!0,toDecimal:!0,toRad:!0,toDeg:!0,wktToPolygon:!0};Object.defineProperty(f,"computeDestinationPoint",{enumerable:!0,get:function(){return La.default}});Object.defineProperty(f,"convertArea",{enumerable:!0,get:function(){return Da.default}});Object.defineProperty(f,"convertDistance",{enumerable:!0,get:function(){return Ia.default}});Object.defineProperty(f,"convertSpeed",{enumerable:!0,get:function(){return Ca.default}});Object.defineProperty(f,"decimalToSexagesimal",{enumerable:!0,get:function(){return Ea.default}});Object.defineProperty(f,"findNearest",{enumerable:!0,get:function(){return qa.default}});Object.defineProperty(f,"getAreaOfPolygon",{enumerable:!0,get:function(){return Na.default}});Object.defineProperty(f,"getBounds",{enumerable:!0,get:function(){return ja.default}});Object.defineProperty(f,"getBoundsOfDistance",{enumerable:!0,get:function(){return Ka.default}});Object.defineProperty(f,"getCenter",{enumerable:!0,get:function(){return Ua.default}});Object.defineProperty(f,"getCenterOfBounds",{enumerable:!0,get:function(){return Fa.default}});Object.defineProperty(f,"getCompassDirection",{enumerable:!0,get:function(){return Va.default}});Object.defineProperty(f,"getCoordinateKey",{enumerable:!0,get:function(){return Ha.default}});Object.defineProperty(f,"getCoordinateKeys",{enumerable:!0,get:function(){return Ba.default}});Object.defineProperty(f,"getDistance",{enumerable:!0,get:function(){return $a.default}});Object.defineProperty(f,"getDistanceFromLine",{enumerable:!0,get:function(){return Wa.default}});Object.defineProperty(f,"getGreatCircleBearing",{enumerable:!0,get:function(){return Ga.default}});Object.defineProperty(f,"getLatitude",{enumerable:!0,get:function(){return za.default}});Object.defineProperty(f,"getLongitude",{enumerable:!0,get:function(){return Xa.default}});Object.defineProperty(f,"getPathLength",{enumerable:!0,get:function(){return Za.default}});Object.defineProperty(f,"getPreciseDistance",{enumerable:!0,get:function(){return Ya.default}});Object.defineProperty(f,"getRhumbLineBearing",{enumerable:!0,get:function(){return Ja.default}});Object.defineProperty(f,"getRoughCompassDirection",{enumerable:!0,get:function(){return Qa.default}});Object.defineProperty(f,"getSpeed",{enumerable:!0,get:function(){return eu.default}});Object.defineProperty(f,"isDecimal",{enumerable:!0,get:function(){return tu.default}});Object.defineProperty(f,"isPointInLine",{enumerable:!0,get:function(){return ru.default}});Object.defineProperty(f,"isPointInPolygon",{enumerable:!0,get:function(){return nu.default}});Object.defineProperty(f,"isPointNearLine",{enumerable:!0,get:function(){return iu.default}});Object.defineProperty(f,"isPointWithinRadius",{enumerable:!0,get:function(){return ou.default}});Object.defineProperty(f,"isSexagesimal",{enumerable:!0,get:function(){return su.default}});Object.defineProperty(f,"isValidCoordinate",{enumerable:!0,get:function(){return au.default}});Object.defineProperty(f,"isValidLatitude",{enumerable:!0,get:function(){return uu.default}});Object.defineProperty(f,"isValidLongitude",{enumerable:!0,get:function(){return lu.default}});Object.defineProperty(f,"orderByDistance",{enumerable:!0,get:function(){return cu.default}});Object.defineProperty(f,"sexagesimalToDecimal",{enumerable:!0,get:function(){return fu.default}});Object.defineProperty(f,"toDecimal",{enumerable:!0,get:function(){return du.default}});Object.defineProperty(f,"toDeg",{enumerable:!0,get:function(){return pu.default}});Object.defineProperty(f,"toRad",{enumerable:!0,get:function(){return mu.default}});Object.defineProperty(f,"wktToPolygon",{enumerable:!0,get:function(){return gu.default}});var La=d(Vn()),Da=d(Hn()),Ia=d(Bn()),Ca=d($n()),Ea=d(Wn()),qa=d(Zn()),Na=d(Qn()),ja=d(Ir()),Ka=d(ti()),Ua=d(ii()),Fa=d(oi()),Va=d(li()),Ha=d(ve()),Ba=d(Je()),$a=d(B()),Wa=d(qr()),Ga=d(pi()),za=d(w()),Xa=d(L()),Za=d(gi()),Ya=d(yi()),Ja=d(Cr()),Qa=d(vi()),eu=d(_i()),tu=d(_e()),ru=d(Mi()),nu=d(Pi()),iu=d(Ti()),ou=d(Ai()),su=d(Me()),au=d(Tr()),uu=d(_r()),lu=d(Sr()),cu=d(wr()),fu=d(Se()),du=d(nt()),mu=d(j()),pu=d(X()),gu=d(ki()),Ur=_();Object.keys(Ur).forEach(function(e){e==="default"||e==="__esModule"||Object.prototype.hasOwnProperty.call(wa,e)||e in f&&f[e]===Ur[e]||Object.defineProperty(f,e,{enumerable:!0,get:function(){return Ur[e]}})});function d(e){return e&&e.__esModule?e:{default:e}}});var Ri=c(Br=>{"use strict";Br.__esModule=!0;function Vr(e,t){return e*e+t*t}function hu(e,t){return Vr(e[0]-t[0],e[1]-t[1])}function bu(e,t,r){var n=t[0],i=t[1],o=r[0]-n,s=r[1]-i;if(o!==0||s!==0){var a=((e[0]-n)*o+(e[1]-i)*s)/Vr(o,s);a>1?(n=r[0],i=r[1]):a>0&&(n+=o*a,i+=s*a)}return Vr(e[0]-n,e[1]-i)}function xu(e,t){for(var r=e[0],n,i=[r],o=1,s=e.length;o<s;o++)n=e[o],hu(n,r)>t&&(i.push(n),r=n);return r!==n&&i.push(n),i}function Hr(e,t,r,n,i){for(var o=n,s,a=t+1;a<r;a++){var u=bu(e[a],e[t],e[r]);u>o&&(s=a,o=u)}o>n&&(s-t>1&&Hr(e,t,s,n,i),i.push(e[s]),r-s>1&&Hr(e,s,r,n,i))}function yu(e,t){var r=e.length-1,n=[e[0]];return Hr(e,0,r,t,n),n.push(e[r]),n}function vu(e,t,r){if(t===void 0&&(t=1),r===void 0&&(r=!1),e.length<=2)return e;var n=t*t;return e=r?e:xu(e,n),e=yu(e,n),e}Br.SimplifyAP=vu});var wi=c(Gr=>{"use strict";Gr.__esModule=!0;function $r(e,t){return e*e+t*t}function _u(e,t){return $r(e.longitude-t.longitude,e.latitude-t.latitude)}function Mu(e,t,r){var n=t.longitude,i=t.latitude,o=r.longitude-n,s=r.latitude-i;if(o!==0||s!==0){var a=((e.longitude-n)*o+(e.latitude-i)*s)/$r(o,s);a>1?(n=r.longitude,i=r.latitude):a>0&&(n+=o*a,i+=s*a)}return $r(e.longitude-n,e.latitude-i)}function Su(e,t){for(var r=e[0],n,i=[r],o=1,s=e.length;o<s;o++)n=e[o],_u(n,r)>t&&(i.push(n),r=n);return r!==n&&i.push(n),i}function Wr(e,t,r,n,i){for(var o=n,s,a=t+1;a<r;a++){var u=Mu(e[a],e[t],e[r]);u>o&&(s=a,o=u)}o>n&&(s-t>1&&Wr(e,t,s,n,i),i.push(e[s]),r-s>1&&Wr(e,s,r,n,i))}function Pu(e,t){var r=e.length-1,n=[e[0]];return Wr(e,0,r,t,n),n.push(e[r]),n}function Tu(e,t,r){if(t===void 0&&(t=1),r===void 0&&(r=!1),e.length<=2)return e;var n=t*t;return e=r?e:Su(e,n),e=Pu(e,n),e}Gr.SimplifyLL=Tu});var Li=c(Zr=>{"use strict";Zr.__esModule=!0;function zr(e,t){return e*e+t*t}function Au(e,t){return zr(e.x-t.x,e.y-t.y)}function ku(e,t,r){var n=t.x,i=t.y,o=r.x-n,s=r.y-i;if(o!==0||s!==0){var a=((e.x-n)*o+(e.y-i)*s)/zr(o,s);a>1?(n=r.x,i=r.y):a>0&&(n+=o*a,i+=s*a)}return zr(e.x-n,e.y-i)}function Ou(e,t){for(var r=e[0],n,i=[r],o=1,s=e.length;o<s;o++)n=e[o],Au(n,r)>t&&(i.push(n),r=n);return r!==n&&i.push(n),i}function Xr(e,t,r,n,i){for(var o=n,s,a=t+1;a<r;a++){var u=ku(e[a],e[t],e[r]);u>o&&(s=a,o=u)}o>n&&(s-t>1&&Xr(e,t,s,n,i),i.push(e[s]),r-s>1&&Xr(e,s,r,n,i))}function Ru(e,t){var r=e.length-1,n=[e[0]];return Xr(e,0,r,t,n),n.push(e[r]),n}function wu(e,t,r){if(t===void 0&&(t=1),r===void 0&&(r=!1),e.length<=2)return e;var n=t*t;return e=r?e:Ou(e,n),e=Ru(e,n),e}Zr.Simplify=wu});var Di=c(ke=>{"use strict";ke.__esModule=!0;var Lu=Ri();ke.SimplifyAP=Lu.SimplifyAP;var Du=wi();ke.SimplifyLL=Du.SimplifyLL;var Iu=Li();ke.Simplify=Iu.Simplify});function R(e){return typeof e=="function"}function Ne(e){let r=e(n=>{Error.call(n),n.stack=new Error().stack});return r.prototype=Object.create(Error.prototype),r.prototype.constructor=r,r}var je=Ne(e=>function(r){e(this),this.message=r?`${r.length} errors occurred during unsubscription:
|
|
2
|
+
${r.map((n,i)=>`${i+1}) ${n.toString()}`).join(`
|
|
3
|
+
`)}`:"",this.name="UnsubscriptionError",this.errors=r});function ge(e,t){if(e){let r=e.indexOf(t);0<=r&&e.splice(r,1)}}var E=class e{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;let{_parentage:r}=this;if(r)if(this._parentage=null,Array.isArray(r))for(let o of r)o.remove(this);else r.remove(this);let{initialTeardown:n}=this;if(R(n))try{n()}catch(o){t=o instanceof je?o.errors:[o]}let{_finalizers:i}=this;if(i){this._finalizers=null;for(let o of i)try{vn(o)}catch(s){t=t??[],s instanceof je?t=[...t,...s.errors]:t.push(s)}}if(t)throw new je(t)}}add(t){var r;if(t&&t!==this)if(this.closed)vn(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(r=this._finalizers)!==null&&r!==void 0?r:[]).push(t)}}_hasParent(t){let{_parentage:r}=this;return r===t||Array.isArray(r)&&r.includes(t)}_addParent(t){let{_parentage:r}=this;this._parentage=Array.isArray(r)?(r.push(t),r):r?[r,t]:t}_removeParent(t){let{_parentage:r}=this;r===t?this._parentage=null:Array.isArray(r)&&ge(r,t)}remove(t){let{_finalizers:r}=this;r&&ge(r,t),t instanceof e&&t._removeParent(this)}};E.EMPTY=(()=>{let e=new E;return e.closed=!0,e})();var lr=E.EMPTY;function Ke(e){return e instanceof E||e&&"closed"in e&&R(e.remove)&&R(e.add)&&R(e.unsubscribe)}function vn(e){R(e)?e():e.unsubscribe()}var I={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var te={setTimeout(e,t,...r){let{delegate:n}=te;return n?.setTimeout?n.setTimeout(e,t,...r):setTimeout(e,t,...r)},clearTimeout(e){let{delegate:t}=te;return(t?.clearTimeout||clearTimeout)(e)},delegate:void 0};function _n(e){te.setTimeout(()=>{let{onUnhandledError:t}=I;if(t)t(e);else throw e})}function cr(){}var Mn=fr("C",void 0,void 0);function Sn(e){return fr("E",void 0,e)}function Pn(e){return fr("N",e,void 0)}function fr(e,t,r){return{kind:e,value:t,error:r}}var W=null;function re(e){if(I.useDeprecatedSynchronousErrorHandling){let t=!W;if(t&&(W={errorThrown:!1,error:null}),e(),t){let{errorThrown:r,error:n}=W;if(W=null,r)throw n}}else e()}function Tn(e){I.useDeprecatedSynchronousErrorHandling&&W&&(W.errorThrown=!0,W.error=e)}var he=class extends E{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Ke(t)&&t.add(this)):this.destination=Fo}static create(t,r,n){return new ne(t,r,n)}next(t){this.isStopped?mr(Pn(t),this):this._next(t)}error(t){this.isStopped?mr(Sn(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?mr(Mn,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},Ko=Function.prototype.bind;function dr(e,t){return Ko.call(e,t)}var pr=class{constructor(t){this.partialObserver=t}next(t){let{partialObserver:r}=this;if(r.next)try{r.next(t)}catch(n){Ue(n)}}error(t){let{partialObserver:r}=this;if(r.error)try{r.error(t)}catch(n){Ue(n)}else Ue(t)}complete(){let{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(r){Ue(r)}}},ne=class extends he{constructor(t,r,n){super();let i;if(R(t)||!t)i={next:t??void 0,error:r??void 0,complete:n??void 0};else{let o;this&&I.useDeprecatedNextContext?(o=Object.create(t),o.unsubscribe=()=>this.unsubscribe(),i={next:t.next&&dr(t.next,o),error:t.error&&dr(t.error,o),complete:t.complete&&dr(t.complete,o)}):i=t}this.destination=new pr(i)}};function Ue(e){I.useDeprecatedSynchronousErrorHandling?Tn(e):_n(e)}function Uo(e){throw e}function mr(e,t){let{onStoppedNotification:r}=I;r&&te.setTimeout(()=>r(e,t))}var Fo={closed:!0,next:cr,error:Uo,complete:cr};var An=typeof Symbol=="function"&&Symbol.observable||"@@observable";function kn(e){return e}function On(e){return e.length===0?kn:e.length===1?e[0]:function(r){return e.reduce((n,i)=>i(n),r)}}var G=class e{constructor(t){t&&(this._subscribe=t)}lift(t){let r=new e;return r.source=this,r.operator=t,r}subscribe(t,r,n){let i=Ho(t)?t:new ne(t,r,n);return re(()=>{let{operator:o,source:s}=this;i.add(o?o.call(i,s):s?this._subscribe(i):this._trySubscribe(i))}),i}_trySubscribe(t){try{return this._subscribe(t)}catch(r){t.error(r)}}forEach(t,r){return r=Rn(r),new r((n,i)=>{let o=new ne({next:s=>{try{t(s)}catch(a){i(a),o.unsubscribe()}},error:i,complete:n});this.subscribe(o)})}_subscribe(t){var r;return(r=this.source)===null||r===void 0?void 0:r.subscribe(t)}[An](){return this}pipe(...t){return On(t)(this)}toPromise(t){return t=Rn(t),new t((r,n)=>{let i;this.subscribe(o=>i=o,o=>n(o),()=>r(i))})}};G.create=e=>new G(e);function Rn(e){var t;return(t=e??I.Promise)!==null&&t!==void 0?t:Promise}function Vo(e){return e&&R(e.next)&&R(e.error)&&R(e.complete)}function Ho(e){return e&&e instanceof he||Vo(e)&&Ke(e)}var wn=Ne(e=>function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var q=class extends G{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(t){let r=new Fe(this,this);return r.operator=t,r}_throwIfClosed(){if(this.closed)throw new wn}next(t){re(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let r of this.currentObservers)r.next(t)}})}error(t){re(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=t;let{observers:r}=this;for(;r.length;)r.shift().error(t)}})}complete(){re(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:t}=this;for(;t.length;)t.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0}_trySubscribe(t){return this._throwIfClosed(),super._trySubscribe(t)}_subscribe(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)}_innerSubscribe(t){let{hasError:r,isStopped:n,observers:i}=this;return r||n?lr:(this.currentObservers=null,i.push(t),new E(()=>{this.currentObservers=null,ge(i,t)}))}_checkFinalizedStatuses(t){let{hasError:r,thrownError:n,isStopped:i}=this;r?t.error(n):i&&t.complete()}asObservable(){let t=new G;return t.source=this,t}};q.create=(e,t)=>new Fe(e,t);var Fe=class extends q{constructor(t,r){super(),this.destination=t,this.source=r}next(t){var r,n;(n=(r=this.destination)===null||r===void 0?void 0:r.next)===null||n===void 0||n.call(r,t)}error(t){var r,n;(n=(r=this.destination)===null||r===void 0?void 0:r.error)===null||n===void 0||n.call(r,t)}complete(){var t,r;(r=(t=this.destination)===null||t===void 0?void 0:t.complete)===null||r===void 0||r.call(t)}_subscribe(t){var r,n;return(n=(r=this.source)===null||r===void 0?void 0:r.subscribe(t))!==null&&n!==void 0?n:lr}};var P=[];for(let e=0;e<256;++e)P.push((e+256).toString(16).slice(1));function Ln(e,t=0){return(P[e[t+0]]+P[e[t+1]]+P[e[t+2]]+P[e[t+3]]+"-"+P[e[t+4]]+P[e[t+5]]+"-"+P[e[t+6]]+P[e[t+7]]+"-"+P[e[t+8]]+P[e[t+9]]+"-"+P[e[t+10]]+P[e[t+11]]+P[e[t+12]]+P[e[t+13]]+P[e[t+14]]+P[e[t+15]]).toLowerCase()}var Bo=new Uint8Array(16);function gr(){return crypto.getRandomValues(Bo)}function $o(e,t,r){return!t&&!e&&crypto.randomUUID?crypto.randomUUID():Wo(e,t,r)}function Wo(e,t,r){e=e||{};let n=e.random??e.rng?.()??gr();if(n.length<16)throw new Error("Random bytes length must be >= 16");if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){if(r=r||0,r<0||r+16>t.length)throw new RangeError(`UUID byte range ${r}:${r+15} is out of buffer bounds`);for(let i=0;i<16;++i)t[r+i]=n[i];return t}return Ln(n)}var hr=$o;var Ve=class{_connect;_close;_error;_message;ws;_filter="";_wsTimeout=2e4;_token="";_playbackMode=!1;onConnect;onClose;onError;onMessage;version=1;endpoint="";selfId="";_source=null;set source(t){this._source?this._source.label=t:this._source={label:t}}set authToken(t){this._token=t}get connectionTimeout(){return this._wsTimeout}set connectionTimeout(t){this._wsTimeout=t<3e3?3e3:t>6e4?6e4:t}get isOpen(){return!!(this.ws&&this.ws.readyState!==1&&this.ws.readyState!==3)}get filter(){return this._filter}set filter(t){t&&t.indexOf("self")!==-1?this._filter=this.selfId?this.selfId:"":this._filter=t}get playbackMode(){return this._playbackMode}constructor(){this._connect=new q,this.onConnect=this._connect.asObservable(),this._close=new q,this.onClose=this._close.asObservable(),this._error=new q,this.onError=this._error.asObservable(),this._message=new q,this.onMessage=this._message.asObservable()}close(){this.ws&&(this.ws.close(),this.ws=null)}open(t,r,n){if(t=t||this.endpoint,!t)return;let i=t.indexOf("?")===-1?"?":"&";r&&(t+=`${i}subscribe=${r}`),(this._token||n)&&(t+=`${r?"&":"?"}token=${this._token||n}`),this.close(),this.ws=new WebSocket(t),setTimeout(()=>{this.ws&&this.ws.readyState!==1&&this.ws.readyState!==3&&(console.warn(`Connection watchdog expired (${this._wsTimeout/1e3} sec): ${this.ws.readyState}... aborting connection...`),this.close())},this._wsTimeout),this.ws.onopen=o=>{this._connect.next(o)},this.ws.onclose=o=>{this._close.next(o)},this.ws.onerror=o=>{this._error.next(o)},this.ws.onmessage=o=>{this.parseOnMessage(o)}}parseOnMessage(t){let r;if(typeof t.data=="string")try{r=JSON.parse(t.data)}catch{return}this.isHello(r)?(this.selfId=r.self,this._playbackMode=typeof r.startTime<"u",this._message.next(r)):this.isResponse(r)?(typeof r.login<"u"&&typeof r.login.token<"u"&&(this._token=r.login.token),this._message.next(r)):this._filter&&this.isDelta(r)?r.context===this._filter&&this._message.next(r):this._message.next(r)}sendRequest(t){if(typeof t!="object")return"";let r=ie.request();return typeof t.login>"u"&&this._token&&(r.token=this._token),Object.keys(t).forEach(i=>{r[i]=t[i]}),this.send(r),r.requestId}put(t,r,n){let i={context:t==="self"?"vessels.self":t,put:{path:r,value:n}};return this.sendRequest(i)}login(t,r){let n={login:{username:t,password:r}};return this.sendRequest(n)}send(t){this.ws&&this.ws.send(typeof t=="object"?JSON.stringify(t):t)}sendUpdate(t="self",r,n){let i=ie.updates();this._token&&(i.token=this._token),i.context=t==="self"?"vessels.self":t,this._token&&(i.token=this._token);let o=[];typeof r=="string"&&o.push({path:r,value:n}),typeof r=="object"&&Array.isArray(r)&&(o=r);let s={timestamp:new Date().toISOString(),values:o};this._source&&(s.source=this._source),i.updates.push(s),this.send(i)}subscribe(t="*",r="*",n){let i=ie.subscribe();if(this._token&&(i.token=this._token),i.context=t==="self"?"vessels.self":t,this._token&&(i.token=this._token),typeof r=="object"&&Array.isArray(r)&&(i.subscribe=r),typeof r=="string"){let o={path:r};n&&typeof n=="object"&&(n.period&&(o.period=n.period),n.minPeriod&&(o.minPeriod=n.minPeriod),n.format&&(n.format==="delta"||n.format==="full")&&(o.format=n.format),n.policy&&(n.policy==="instant"||n.policy==="ideal"||n.policy==="fixed")&&(o.policy=n.policy)),i.subscribe.push(o)}this.send(i)}unsubscribe(t="*",r="*"){let n=ie.unsubscribe();this._token&&(n.token=this._token),n.context=t==="self"?"vessels.self":t,this._token&&(n.token=this._token),typeof r=="object"&&Array.isArray(r)&&(n.unsubscribe=r),typeof r=="string"&&n.unsubscribe.push({path:r}),this.send(n)}raiseAlarm(t="*",r,n){let i;typeof r=="string"?i=r.indexOf("notifications.")===-1?`notifications.${r}`:r:i=r,this.put(t,i,n.value)}clearAlarm(t="*",r){let n=r.indexOf("notifications.")===-1?`notifications.${r}`:r;this.put(t,n,null)}isSelf(t){return t.context===this.selfId}isDelta(t){return typeof t.context<"u"}isHello(t){return typeof t.version<"u"&&typeof t.self<"u"}isResponse(t){return typeof t.requestId<"u"}},ie=class{static updates(){return{context:null,updates:[]}}static subscribe(){return{context:null,subscribe:[]}}static unsubscribe(){return{context:null,unsubscribe:[]}}static request(){return{requestId:hr()}}},He=class{_state;_method=[];_message="";constructor(t,r,n,i){this._message=typeof t<"u"?t:"",this._state=typeof r<"u"?r:"alarm",n&&this._method.push("visual"),i&&this._method.push("sound")}get value(){return{message:this._message,state:this._state,method:this._method}}};var oe=class{id;name;mmsi;position=[0,0];positionReceived=!1;positionTimestamp="";positionUpdatedAt=0;state;type={id:-1,name:""};properties={};lastUpdated=new Date;callsignVhf;callsignHf;orientation=0;virtual},be=class extends oe{anchor={maxRadius:null,radius:null,position:null};autopilot={state:null,mode:null,target:null,enabled:!1,default:null,availableActions:[]};buddy=!1;closestApproach={distance:null,timeTo:null};cog;cogTrue=null;cogMagnetic=null;courseApi={arrivalCircle:0,activeRoute:{},nextPoint:{},previousPoint:{}};courseCalcs={};distanceToSelf;environment={mode:null,sun:null};heading;headingTrue=null;headingMagnetic=null;headingTrueUpdatedAt=0;headingMagneticUpdatedAt=0;magneticVariation=null;performance={beatAngle:null,gybeAngle:null};radars={};registrations={};resourceUpdates=[];sog;track=[];vectors={cog:[]};wind={direction:null,mwd:null,twd:null,tws:null,speedTrue:null,sog:null,awa:null,aws:null};design={airHeight:null,beam:null,draft:{current:null,maximum:null},length:null};destination={name:null,eta:null};flag;port},Be=class extends oe{constructor(){super()}},$e=class extends oe{sog=0;track=[];constructor(){super()}},xe=class extends oe{constructor(){super()}},We=class extends xe{twd;tws;temperature;constructor(){super()}};var br={K:{C:e=>e-273.15,F:e=>(e-273.15)*9/5+32},rad:{degree:e=>e*180/Math.PI},deg:{radian:e=>e*.0174532925199433},ratio:{percent:e=>e*100},"m/s":{kn:e=>e*1.94384,"km/h":e=>e*3.6,mph:e=>e*2.2369362920544025,Bf:e=>e/.836^.6666666666666666,fps:e=>e*3.280839895013124},"rad/s":{"deg/s":e=>e*57.2958,rpm:e=>e*9.549296585513723},Hz:{rpm:e=>e*60},m:{fathom:e=>e*.5467468562055768,league:e=>e*.0002071251035625518,kilometer:e=>e*.001,mile:e=>e*.000621371192237334,"naut-mile":e=>e*.0005399568034557236,foot:e=>e*3.280839895013124,yard:e=>e*1.0936132983377078},s:{hour:e=>e*.0002777777777777778,minute:e=>e*.016666666666666666,day:e=>e*11574074074074073e-21,year:e=>e*3168876461541279e-23},foot:{m:e=>e/3.280839895013124}},ye={degree:{symbol:"\xBA",name:"Degrees"},radian:{symbol:"rad",name:"Radians"},percent:{symbol:"%",name:"Percent"},kilometer:{symbol:"km",name:"Kilometer"},"naut-mile":{symbol:"nmi",name:"Nautical Mile"},foot:{symbol:"ft",name:"Feet"},yard:{symbol:"yd",name:"Yard"},fathom:{symbol:"fm",name:"Fathom"},hour:{symbol:"hr",name:"Hour"},minute:{symbol:"min",name:"Minute"},F:{symbol:"\xBAF",name:"Fahrenheit"},C:{symbol:"\xBAC",name:"Celcius"}},z=class{static transform(t,r,n){if(!Number.isFinite(t))return null;if(r===n)return t;try{return br[r][n](t)}catch{throw new Error("Transformation not found!")}}static setSymbol(t,r){t in ye&&(ye[t].symbol=r??ye[t].symbol)}static getSymbol(t){return t in ye?ye[t].symbol:t}static degreesToRadians(t){return br.deg.radian(t)}static radiansToDegrees(t=0){return br.rad.degree(t)}static nauticalMilesToKm(t=0){return t*1.852}static angleToDirection(t,r){let n=Math.PI*2;if(r||(r=0),t||(t=0),!Number.isFinite(r)||!Number.isFinite(t))return null;let i=r+t;return i>n?i-n:i<0?n+i:i}static directionToAngle(t,r){let n=Math.PI*2;if(r||(r=0),t||(t=0),!Number.isFinite(r)||!Number.isFinite(t))return null;let i=r-t,o;if(i>0)o=i>Math.PI?n-i:0-i;else if(i<0){let s=Math.abs(i);o=s>Math.PI?s-n:s}else o=i;return o}};var k=yn(Oi()),C=class e{static R=6371e3;static rhumbDestination(t,r,n){let i=e.R,o=n/i,s=t[1]*Math.PI/180,a=t[0]*Math.PI/180,u=r,p=o*Math.cos(u),m=s+p,h=o,b=89*Math.PI/180;m>b&&s<b?(h=o*(b-s)/p,m=b):m<-b&&s>-b&&(h=o*(-b-s)/p,m=-b);let S=Math.log(Math.tan(Math.PI/4+m/2)/Math.tan(Math.PI/4+s/2)),v=Math.abs(S)>1e-12?(m-s)/S:Math.cos(s),O=h*Math.sin(u)/v;return[(a+O)*180/Math.PI,m*180/Math.PI]}static destCoordinate(t,r,n){let i=(0,k.computeDestinationPoint)(t,n,z.radiansToDegrees(r));return[i.longitude,i.latitude]}static distanceTo(t,r){return(0,k.getDistance)(t,r)}static routeLength(t){return(0,k.getPathLength)(t)}static routeLegs(t,r){if(t.length<2)return[];let n=[];r?n.push({bearing:(0,k.getGreatCircleBearing)(r,t[0]),distance:e.distanceTo(r,t[0])}):n.push({bearing:0,distance:0});for(let i=1;i<t.length;++i){let o={bearing:(0,k.getGreatCircleBearing)(t[i-1],t[i]),distance:e.distanceTo(t[i-1],t[i])};n.push(o)}return n}static closestForwardPoint(t,r,n){if(t.length<2||!r)return-1;let i={index:-1,distance:-1};for(let o=0;o<t.length;++o){let s=(0,k.getGreatCircleBearing)(r,t[o]),a=Fr.difference(n,s);if(a>-90&&a<90){let u=e.distanceTo(r,t[o]);(i.distance===-1||u<i.distance)&&(i.distance=u,i.index=o)}}return i.index}static centreOfPolygon(t){let r=(0,k.getCenter)(t);return[r.longitude,r.latitude]}static inDLCrossingZone(t,r=170){return Math.abs(t[0])>=r}static inBounds(t,r){return(0,k.isPointInPolygon)(t,[[r[0],r[1]],[r[0],r[3]],[r[2],r[3]],[r[2],r[1]],[r[0],r[1]]])}static calcMapifiedExtent(t,r){let i=111111*Math.cos(z.degreesToRadians(t[1])),o=[0,0,0,0];return o[1]=t[1]+(0-Math.abs(r))/111111,o[3]=t[1]+Math.abs(r)/111111,o[0]=t[0]+(0-Math.abs(r))/i,o[2]=t[0]+Math.abs(r)/i,o}static normaliseCoords(t){if(!Array.isArray(t))return[0,0];if(typeof t[0]=="number"){if(t[0]>180)for(;t[0]>180;)t[0]=t[0]-360;else if(t[0]<-180)for(;t[0]<-180;)t[0]=360+t[0];return t}else if(Array.isArray(t[0]))return t.forEach(r=>this.normaliseCoords(r)),t}},Fr=class e{static difference(t,r){let n=360-r,i=t+n,o=e.normalise(i);return o<180?0-o:360-o}static add(t,r){return e.normalise(t+r)}static normalise(t){return t<0?t+360:t>=360?t-360:t}};var $t=class{action="notification";playback=!1;result=null;self=null;timestamp=new Date().toISOString();sourceRef},Z=class{action;playback=!1;result=null;timestamp;self=null;watchDogAlarm;constructor(){this.action="update"}},Wt=class extends Z{constructor(){super(),this.action="resource"}},Gt=class extends Z{constructor(){super(),this.action="radar"}},ae=class extends Z{timed;constructor(){super(),this.action="trail"}};var go=yn(Di());var Yr=2*Math.PI;function ue(e,t){return!Number.isFinite(e)||!Number.isFinite(t)?null:((e+t)%Yr+Yr)%Yr}var Ci="auto",Ii=1e4,Cu=.2572,Ei=new Set(["navigation.headingTrue","navigation.headingMagnetic","navigation.courseOverGroundTrue","navigation.courseOverGroundMagnetic","navigation.speedOverGround","navigation.magneticVariation"]);function qi(e){let t=Date.now();if(e.headingTrue!==null&&t-e.headingTrueUpdatedAt<=Ii){e.orientation=e.headingTrue;return}if(e.headingMagnetic!==null&&t-e.headingMagneticUpdatedAt<=Ii){e.orientation=ue(e.headingMagnetic,e.magneticVariation)??e.headingMagnetic;return}let r=e.cogTrue??ue(e.cogMagnetic,e.magneticVariation)??e.cogMagnetic;typeof r=="number"&&(e.sog??0)>=Cu&&(e.orientation=r)}var Eu=new Set(["navigation.headingMagnetic","navigation.courseOverGroundMagnetic"]);function Jr(e,t,r){return Eu.has(e)?ue(t,r)??t:t}function Ni(e,t){let r=t==="navigation.headingMagnetic"?e.headingMagnetic:t==="navigation.courseOverGroundMagnetic"?e.cogMagnetic:null;return Number.isFinite(r)?Jr(t,r,e.magneticVariation):null}var Zt={api:"none",serverHasTracksApi:!1,v1SelfTrack:!1,v1AisTracks:!1},qu="PT2H",Nu=120,ju=10,Ku=1e3,Yt=12;function Fi(e){let t=e.replace(/\/v1\/api\/?$/,"");return{features:`${t}/v2/features`,providers:`${t}/v2/api/tracks/_providers`,v1SelfTrack:`${e}/self/track?timespan=1h`,v1Tracks:`${e}/tracks`}}function en(e){return`${e.replace(/\/v1\/api\/?$/,"")}/v2/api/tracks`}var ji=async(e,t)=>{try{return(await e(t)).ok}catch{return!1}},Ki=async(e,t)=>{try{let r=await e(t);return r.ok?await r.json():void 0}catch{return}};function Uu(e){if(!e||typeof e!="object")return;let t=Object.entries(e);if(t.length!==0)return(t.find(([,r])=>r?.isDefault)??t[0])[0]}async function Vi(e,t){let r=await Ki(e,t.features),n=Array.isArray(r?.apis)&&r.apis.includes("tracks");if(n){let s=Uu(await Ki(e,t.providers));if(s)return{api:"v2",serverHasTracksApi:n,provider:s,v1SelfTrack:!1,v1AisTracks:!1}}let[i,o]=await Promise.all([ji(e,t.v1SelfTrack),ji(e,t.v1Tracks)]);return{api:i||o?"v1":"none",serverHasTracksApi:n,v1SelfTrack:i,v1AisTracks:o}}function zt(e){if(typeof e!="string")return;let t=e.trim();if(/^P/i.test(t))return t.toUpperCase();let r=/^(\d+)\s*([smh])$/i.exec(t);return r?`PT${Number(r[1])}${r[2].toUpperCase()}`:void 0}function Hi(e){return{lastHour:e.lastHour,next23:e.next23==="5s"?"1m":e.next23,beyond24:e.beyond24==="10s"?"5m":e.beyond24}}var Y=36e5,Oe=0,Bi=96;function $i(e,t,r,n,i){let o=u=>new Date(u).toISOString(),s=n===void 0?{simplify:!0}:{epsilon:n},a=[];return e===Oe||e>24?(a.push({...e===Oe?{}:{from:o(r-e*Y)},to:o(r-24*Y),resolution:zt(t.beyond24),...s,...e===Oe&&i?{bbox:i}:{}}),a.push({from:o(r-24*Y),to:o(r-Y),resolution:zt(t.next23),...s})):e>1&&a.push({from:o(r-e*Y),to:o(r-Y),resolution:zt(t.next23),...s}),a.push({from:o(r-Y),resolution:zt(t.lastHour)}),a}function Xt(e){return Object.entries(e).filter(([,t])=>t!==void 0&&t!=="").map(([t,r])=>`${t}=${encodeURIComponent(String(r))}`).join("&")}function Wi(e,t,r){return`${e}?${Xt({context:"self",from:t.from,to:t.to,resolution:t.resolution,epsilon:t.epsilon,simplify:t.simplify?"true":void 0,bbox:t.bbox?.join(","),times:"true",provider:r})}`}var tn=e=>typeof e?.from=="string",Gi=e=>{let t=e?.features;return Array.isArray(t)?t.filter(r=>tn(r?.properties)):[]},Qr=e=>e.geometry?.type==="MultiLineString"&&Array.isArray(e.geometry.coordinates)?e.geometry.coordinates:void 0;function zi(e){let t=Gi(e).filter(n=>n.properties?.isSelf&&Qr(n));if(t.length===0)return;let r=t[0].properties?.providerId;return t.filter(n=>n.properties?.providerId===r).flatMap(n=>Qr(n))}function Xi(e,t){let r=new Map,n=new Map;return Gi(e).forEach(i=>{let o=i.properties?.context,s=Qr(i);if(!o||i.properties?.isSelf||!s)return;let a=i.properties?.providerId;(!r.has(o)||a===t&&n.get(o)!==t)&&(r.set(o,s),n.set(o,a))}),r}function Ui(e){let t=((e+180)%360+360)%360-180;return t===-180&&e>0?180:t}function rn(e,t){if(!Array.isArray(e)||e.length!==4)return null;let[r,n,i,o]=e;if(![r,n,i,o].every(Number.isFinite)||i<r)return null;if(Array.isArray(t)&&t.length===4){let[a,u,p,m]=t,h=Math.round(((r+i)/2-(a+p)/2)/360)*360;if(r=Math.max(r,a+h),i=Math.min(i,p+h),n=Math.max(n,u),o=Math.min(o,m),r>=i||n>=o)return null}let s=a=>Math.round(a*1e6)/1e6;return n=s(Math.max(-90,n)),o=s(Math.min(90,o)),i-r>=360?[-180,n,180,o]:[s(Ui(r)),n,s(Ui(i)),o]}function Zi(e){if(e.showAll){if(!e.view||!(e.view.zoom>=ju))return null;let n=rn(e.view.extent,e.radiusBox);return n?Xt({bbox:n.join(","),duration:qu,maxPoints:Nu,times:"true",provider:e.provider}):null}let t=e.picks.filter(n=>e.targets.has(n));if(t.length===0)return null;let r=Number.isFinite(e.pickHours)&&e.pickHours>0?e.pickHours:Yt;return Xt({contexts:t.join(","),duration:`PT${r}H`,maxPoints:Ku,times:"true",provider:e.provider})}var Yi=.5,Ji=.5;function nn(e,t){let[r,n,i,o]=e,s=(i-r)*t,a=(o-n)*t;return[r-s,n-a,i+s,o+a]}function Qi(e,t){if(!e||Math.floor(e.zoom)!==Math.floor(t.zoom))return!0;let[r,n,i,o]=t.extent,[s,a,u,p]=e.extent;return r<s||n<a||i>u||o>p}function on(){let e=0;return{begin:()=>++e,invalidate:()=>{e++},isCurrent:t=>t===e}}var sn=6378137,to=2*Math.PI*sn/256;function eo(e){let t=Math.max(-85,Math.min(85,e));return sn*Math.log(Math.tan(Math.PI/4+t*Math.PI/360))}function ro(e,t){let r=(eo(e)+eo(t))/2/sn;return(2*Math.atan(Math.exp(r))-Math.PI/2)*180/Math.PI}var an=6e4,un=60*an,no=24*un;function oo(e,t){if(!Number.isFinite(e)||!Array.isArray(t)||t.length!==4)return null;let r=ro(t[1],t[3]);if(!Number.isFinite(r))return null;let n=Math.floor(e)+1,i=to/Math.pow(2,n)*Math.cos(r*Math.PI/180),o=Number(i.toPrecision(3));return o>0?o:null}var so=e=>{let t=e?.features;return Array.isArray(t)?t.filter(r=>tn(r?.properties)):[]},Fu=(e,t)=>{if(e.length===0)return[];let r=e.some(n=>n.properties?.providerId===t)?t:e[0].properties?.providerId;return e.filter(n=>n.properties?.providerId===r)};function ln(e,t,r){let n=[],i=[],o=!0,s,a;if(Fu(so(t),r).forEach(u=>{typeof u.properties?.resolution=="string"&&(s=u.properties.resolution),typeof u.properties?.epsilon=="number"&&(a=Math.max(a??0,u.properties.epsilon));let p=u.geometry?.type==="MultiLineString"&&Array.isArray(u.geometry.coordinates)?u.geometry.coordinates:[],m=u.properties?.coordTimes;p.forEach((h,b)=>{if(!Array.isArray(h)||h.length===0)return;n.push(h);let S=Array.isArray(m)?m[b]:void 0;Array.isArray(S)&&S.length===h.length?i.push(S):o=!1})}),n.length!==0)return{context:e,lines:n,...o&&{times:i},...s!==void 0&&{resolution:s},...a!==void 0&&{epsilon:a}}}function ao(e,t){let r=new Map;so(e).forEach(i=>{let o=i.properties?.context;o&&r.set(o,[...r.get(o)??[],i])});let n=new Map;return r.forEach((i,o)=>{let s=ln(o,{features:i},t);s?.times&&n.set(o,{lines:s.lines,times:s.times})}),n}var Pd=[5*an,15*an,un,6*un,no,7*no];var io=e=>e?Date.parse(e):NaN;var Vu=10*6e4;function uo(e,t){let r=[...e.lines],n=[...e.times];return t.lines.forEach((i,o)=>{let s=n[n.length-1],a=s?io(t.times[o][0])-io(s[s.length-1]):NaN;o===0&&a>=0&&a<=Vu?(r[r.length-1]=r[r.length-1].concat(i),n[n.length-1]=s.concat(t.times[o])):(r.push(i),n.push(t.times[o]))}),{lines:r,times:n}}var Hu=["environment.wind.speedTrue","environment.wind.speedOverGround","environment.wind.angleTrueGround","environment.wind.angleTrueWater","environment.wind.directionTrue","environment.wind.directionMagnetic","navigation.courseOverGroundTrue","navigation.courseOverGroundMagnetic","navigation.headingTrue","navigation.headingMagnetic"],y={active:!1,maxMsgIntervals:18,intervalCount:0,msgCount:0,alarm:!1},l,M,Qt,Le=[],er=[],cn=!1,Q,fe=Zt,ho=Promise.resolve(Zt),U=null,bo=null,xo=[],tr=!1,fn=Yt,lo,Bu=1e3,de=new Set,Ie=on(),$=on(),$u=5e3,x={signalk:{},aisState:[]},yo=[0,0,0,0],vo=60,Re=0,A,ce={},J=500,T=!1,_o,K={maxAge:54e4,staleAge:36e4,lastTick:new Date().valueOf(),maxTrack:20},dn={selfLines:{cog:{length:10}},aisCogLine:10},me={trailDuration:24,trailResolution:{lastHour:"5s",next23:"10s",beyond24:"1m"}},V,Mo,le="freeboard-sk";function Wu(){l={self:new be,aisTargets:new Map,aisStatus:{updated:[],stale:[],expired:[]},paths:{},atons:new Map,aircraft:new Map,sar:new Map,meteo:new Map},l.self.positionReceived=!1,de.clear(),Ie.invalidate(),So()}function So(){A={updated:{},stale:{},expired:{}}}function Jt({action:e,msg:t}){switch(e){case"onConnect":postMessage({action:"open",playback:T,result:t.target.readyState}),zu(),y.msgCount=0,y.intervalCount=0,y.alarm=!1,y.active=!0;break;case"onClose":Po(!1),co();break;case"onError":postMessage({action:"error",playback:T,result:"Connection error!"}),co();break;case"onMessage":y.msgCount++,il(t);break}}function co(){y.msgCount=0,y.intervalCount=0,y.active=!0,y.alarm=!0,nr(!0)}addEventListener("message",({data:e})=>{Gu(e)});function Gu(e){if(e.cmd)switch(e.cmd){case"open":fo(e.options),rl(e.options);break;case"close":Po(!0);break;case"subscribe":M.subscribe(e.options.context,e.options.path);break;case"settings":fo(e.options);break;case"alarm":nl(e.options);break;case"vessel":if(e.options){let t;e.options.context==="self"?t=l.self:t=l.aisTargets.get(e.options.context),t&&e.options.name&&(t.name=e.options.name)}break;case"auth":e.options&&typeof e.options.token<"u"&&(Qt=e.options.token);break;case"trail":e.options&&(me.trailDuration=e.options.trailDuration??24,e.options.trailResolution&&(me.trailResolution.lastHour=e.options.trailResolution.lastHour??"5s",me.trailResolution.next23=e.options.trailResolution.next23??"5s",me.trailResolution.beyond24=e.options.trailResolution.beyond24??"10s")),Xu();break;case"view":e.options?.extent&&(U={extent:e.options.extent,zoom:e.options.zoom},tr&&Qi(bo,U)&&rr());break;case"trackSelection":xo=Array.isArray(e.options?.ids)?e.options.ids:[],rr();break}}function fo(e={}){if(e.interval&&typeof e.interval=="number"&&(J=e.interval,Ro(),Oo(),vo=1/(J/1e3)*60),T=!!e.playback,e.config){typeof e.config.units.preferredPaths<"u"&&(ce=e.config.units.preferredPaths),e.config.vessels.aisMaxAge&&typeof e.config.vessels.aisMaxAge=="number"&&(K.maxAge=e.config.vessels.aisMaxAge),e.config.vessels.aisStaleAge&&typeof e.config.vessels.aisStaleAge=="number"&&(K.staleAge=e.config.vessels.aisStaleAge),typeof e.config.signalk.maxRadius=="number"&&(x.signalk=e.config.signalk),typeof e.config.selections.aisState<"u"&&Array.isArray(e.config.selections.aisState)&&(x.aisState=e.config.selections.aisState),dn=e.config.vessels,e.config.vessels.aisShowTrack!==tr&&(tr=e.config.vessels.aisShowTrack,rr());let t=e.config.vessels.aisTrackLength??Yt;t!==fn&&(fn=t,rr())}}function Po(e=!1){Ro(),Le.forEach(t=>t.unsubscribe()),M&&e&&M.close(),M=null,postMessage({action:"close",result:e,playback:T})}function De(e){return fetch(e).then(t=>t.json())}function To(e){return fetch(e,Qt?{headers:{Authorization:`Bearer ${Qt}`}}:void 0)}function Ao(e){return To(e).then(t=>{if(!t.ok)throw new Error(`${t.status}`);return t.json()})}function zu(){Q&&(ho=Vi(To,Fi(Q)).catch(()=>Zt).then(e=>(fe=e,postMessage({action:"trackSource",playback:T,result:e}),mn(),e)))}function Xu(){let e=$.begin();ho.then(t=>{if(t.api==="v2")Zu(en(Q),me,t.provider,e);else if(t.api==="v1"&&t.v1SelfTrack)tl(me,e);else if($.isCurrent(e)){let r=new ae;r.playback=T,r.result=null,postMessage(r)}})}function Zu(e,t,r,n=$.begin()){let i=(U&&oo(U.zoom,U.extent))??void 0,o=(U&&rn(nn(U.extent,Ji)))??void 0,s=$i(t.trailDuration,t.trailResolution,Date.now(),i,o),a=new ae;a.playback=T,Promise.all(s.map(u=>Ao(Wi(e,u,r)))).then(u=>{$.isCurrent(n)&&(a.result=ko(u.map(p=>zi(p)??null),s.map(p=>p.epsilon!==void 0||p.simplify===!0)),a.timed=Yu(u,r),postMessage(a))}).catch(()=>{$.isCurrent(n)&&(a.result=null,postMessage(a))})}function Yu(e,t){let r={lines:[],times:[]};for(let n of e){let i=ln("self",n,t);if(i&&!i.times)return;i&&(r=uo(r,{lines:i.lines,times:i.times}))}return r.lines.length?r:void 0}function rr(){Ie.invalidate(),clearTimeout(lo),lo=setTimeout(()=>{fe.api==="v2"&&mn()},Bu)}function mn(){T||!l||(fe.api==="v2"?Ju(fe.provider):fe.api==="v1"&&fe.v1AisTracks&&el())}function Ju(e){let t=U&&{extent:nn(U.extent,Yi),zoom:U.zoom};bo=t;let r=Zi({view:t,showAll:tr,picks:xo,targets:l.aisTargets,radiusBox:x.signalk.maxRadius&&l.self.positionReceived?C.calcMapifiedExtent(l.self.position,x.signalk.maxRadius):void 0,pickHours:fn,provider:e});if(!r){Ie.invalidate();return}let n=Ie.begin();Ao(`${en(Q)}?${r}`).then(i=>{Ie.isCurrent(n)&&!T&&(Qu(l.aisTargets,Xi(i,e)),postMessage({action:"aisTracksTimed",playback:T,result:ao(i,e)}))}).catch(()=>{})}function Qu(e,t){let r=[...de];de.clear(),t.forEach((n,i)=>{let o=e.get(i),s=n.filter(a=>Array.isArray(a)&&a.length>0);o?.positionReceived&&o.position&&s.length>0&&(o.track=s,de.add(i),ir(o))}),r.filter(n=>!de.has(n)).forEach(n=>{let i=e.get(n),o=i?.track?.[i.track.length-1];o&&(i.track=[o.slice(0-K.maxTrack)])})}function el(){let e=x&&x.signalk&&x.signalk.maxRadius?`?radius=${x.signalk.maxRadius}`:"?radius=10000";De(Q+"/tracks"+e).then(t=>{Object.entries(t).forEach(r=>{if(l.aisTargets.has(r[0])){let n=l.aisTargets.get(r[0]);n.track=r[1].coordinates,ir(n)}})}).catch(()=>{})}function tl(e,t=$.begin()){let r=Q+"/self/track?",n=Hi(e.trailResolution),i=e.trailDuration===Oe?Bi:e.trailDuration,o=[];i>24&&(o.push(De(`${r}timespan=${i-24}h&resolution=${n.beyond24}×panOffset=24`)),o.push(De(`${r}timespan=23h&resolution=${n.next23}×panOffset=1`))),i>1&&i<25&&o.push(De(`${r}timespan=${i-1}h&resolution=${n.next23}×panOffset=1`)),o.push(De(`${r}timespan=1h&resolution=${n.lastHour}`));let s=new ae;s.playback=T,Promise.all(o).then(a=>{$.isCurrent(t)&&(s.result=ko(a.map(u=>u?.type==="MultiLineString"&&Array.isArray(u.coordinates)?u.coordinates:null)),postMessage(s))}).catch(()=>{$.isCurrent(t)&&(s.result=null,postMessage(s))})}function ko(e,t=[]){let o=e.length-1,s=[];return e.forEach((a,u)=>{a&&(u!==o?a.forEach(p=>{let m=t[u]?p:(0,go.SimplifyAP)(p,5e-4,!0);for(;m.length>60;){let h=m.slice(0,60);s.push(h),m=m.slice(59),m[0]=[m[0][0]+5e-9,m[0][1]+5e-9]}m.length!==0&&s.push(m)}):s=s.concat(a))}),s}function rl(e){if(M)return;if(!e.url){postMessage({action:"error",result:"Valid options not provided!"});return}let t=e.url.split("/");if(t.pop(),t.push("api"),t[0]=t[0]==="wss:"?"https:":"http:",Q=t.join("/"),Wu(),M=new Ve,Le.push(M.onConnect.subscribe(r=>Jt({action:"onConnect",msg:r}))),Le.push(M.onClose.subscribe(r=>Jt({action:"onClose",msg:r}))),Le.push(M.onError.subscribe(r=>Jt({action:"onError",msg:r}))),Le.push(M.onMessage.subscribe(r=>Jt({action:"onMessage",msg:r}))),M.authToken=Qt,e.playback){let r=e.playbackOptions.startTime?`?startTime=${e.playbackOptions.startTime}`:null,n=e.playbackOptions.playbackRate?`playbackRate=${e.playbackOptions.playbackRate}`:null;n=n?r?"&"+n:"?"+n:null;let i=`${e.url}${r||""}${n||""}`;M.open(i,e.playbackOptions.subscribe,e.token)}else M.open(e.url,e.subscribe,e.token)}function nl(e){let t=e.type.indexOf("notifications.")===-1?`notifications.${e.type}`:e.type;e.raise?M.raiseAlarm("self",t,new He(e.message,e.state,!0,!0)):M.clearAlarm("self",t)}function il(e){M.isHello(e)?(postMessage({action:"hello",result:e,self:e.self,playback:T}),J&&Oo()):M.isDelta(e)?(cn=!0,e.updates.forEach(t=>{!("values"in t)||!t.values||(V=t.$source,Mo=t.timestamp,t.values.forEach(r=>{if(_o=t.timestamp,!!e.context)switch(e.context.split(".")[0]){case"shore":case"atons":x?.signalk.atons&&ll(e.context,r),we(e.context,l.atons,x?.signalk.atons);break;case"sar":x?.signalk.sar&&cl(e.context,r),we(e.context,l.sar,x?.signalk.sar);break;case"aircraft":x?.signalk.aircraft&&dl(e.context,r),we(e.context,l.aircraft,x?.signalk.aircraft);break;case"meteo":x?.signalk.meteo&&(fl(e.context,r),po(r)),we(e.context,l.meteo,x?.signalk.meteo);break;case"vessels":if(M.isSelf(e))l.self.id||(l.self.id=e.context),mo(l.self,r,!0),po(r);else{if(x?.signalk.vessels){let n=ol(e.context);mo(n,r)}we(e.context,l.aisTargets,x?.signalk.vessels,x?.aisState)}break}}))}),nr()):M.isResponse(e)&&postMessage({action:"response",result:e})}function we(e,t,r=!0,n=[]){if(r){let i=t.get(e);i&&n.includes(i?.state)&&(A.expired[e]=!0,i=null),i&&x.signalk.maxRadius?i.positionReceived&&C.inBounds(i.position,yo)?A.updated[e]=!0:(t.delete(e),A.expired[e]=!0):A.updated[e]=!0}else t.size!==0&&(t.forEach((i,o)=>{A.expired[o]=!0}),t.clear())}function nr(e=!1){if(!J||e){let t=new Z;t.watchDogAlarm=y.alarm,t.playback=T,l.aisStatus.updated=Object.keys(A.updated),l.aisStatus.stale=Object.keys(A.stale),l.aisStatus.expired=Object.keys(A.expired),t.result=l,t.timestamp=T?_o:l.self.lastUpdated.toISOString(),postMessage(t),So(),l.self.resourceUpdates=[],ul(),Re===0&&l.self.positionReceived&&x?.signalk.maxRadius&&(yo=C.calcMapifiedExtent(l.self.position,x.signalk.maxRadius),Re++),Re=Re>=vo?0:Re+1}}function Oo(){J&&typeof J=="number"&&er.push(setInterval(()=>{y.active&&!y.msgCount?(y.intervalCount=y.intervalCount+1,y.intervalCount>=y.maxMsgIntervals&&(y.intervalCount=0,y.alarm=!0,nr(!0))):(y.intervalCount=0,y.msgCount=0,y.alarm=!1),cn&&(nr(!0),cn=!1)},J)),er.push(setInterval(()=>mn(),6e4))}function Ro(){er.forEach(e=>clearInterval(e)),er=[]}function ol(e){if(!l.aisTargets.has(e)){let t=new be;t.id=e,t.position=null,l.aisTargets.set(e,t)}return l.aisTargets.get(e)}function mo(e,t,r=!1){let n=t.value;if(r){if(e.lastUpdated=new Date,t.path.startsWith("resources."))e.resourceUpdates.push(t),al(t);else if(t.path.startsWith("radars"))sl(t);else if(t.path.startsWith("navigation.racing"))e.properties[t.path]=n;else if(t.path==="performance.beatAngle")e.performance.beatAngle=n;else if(t.path==="performance.gybeAngle")e.performance.gybeAngle=n;else if(t.path.startsWith("navigation.course."))if(t.path.startsWith("navigation.course.calcValues.")){let a=t.path.split(".").slice(3).join(".");e.courseCalcs[a]=n}else t.path.includes("activeRoute")?e.courseApi.activeRoute=n:t.path.includes("nextPoint")?e.courseApi.nextPoint=n:t.path.includes("previousPoint")?e.courseApi.previousPoint=n:t.path.includes("arrivalCircle")&&(e.courseApi.arrivalCircle=n);else if(t.path.startsWith("radars.")){let a=t.path.split("."),u=a.slice(2).join(".");e.radars[a[1]]||(e.radars[a[1]]={}),e.radars[a[1]][u]=n}let s=t.path.indexOf("course")!==-1?t.path.split(".").slice(0,2).join("."):t.path;Hu.indexOf(s)!==-1&&(l.paths[s]=null)}else t.path==="navigation.distanceToSelf"&&(e.distanceToSelf=n),t.path==="navigation.closestApproach"&&(e.closestApproach=n);if(t.path==="")typeof n.name<"u"&&(e.name=n.name),typeof n.mmsi<"u"&&(e.mmsi=n.mmsi,e.lastUpdated=new Date),typeof n.registrations<"u"&&(e.registrations=n.registrations),typeof n.buddy<"u"&&(e.buddy=n.buddy),typeof n.communication<"u"&&(e.callsignVhf=n.communication.callsignVhf??"",e.callsignHf=n.communication.callsignHf??"");else if(t.path==="communication.callsignVhf")e.callsignVhf=n;else if(t.path==="communication.callsignHf")e.callsignHf=n;else if(t.path==="design.aisShipType")e.type=n;else if(t.path==="navigation.position"&&n){if(typeof n.latitude>"u"||typeof n.longitude>"u")return;e.position=C.normaliseCoords([n.longitude,n.latitude]),e.positionReceived=!0,e.positionTimestamp=Mo??"",e.positionUpdatedAt=Date.now(),e.lastUpdated=new Date,r||ir(e)}else t.path==="navigation.state"?e.state=n:t.path==="navigation.speedOverGround"?e.sog=n:t.path==="environment.mode"?e.environment.mode=n:t.path==="environment.sun"?e.environment.sun=n:t.path==="environment.wind.angleApparent"?e.wind.awa=n:t.path==="environment.wind.speedApparent"?e.wind.aws=n:t.path==="environment.wind.speedTrue"?e.wind.speedTrue=n:t.path==="environment.wind.speedOverGround"?e.wind.sog=n:t.path==="environment.wind.directionTrue"?e.wind.twd=n:t.path==="environment.wind.directionMagnetic"?e.wind.mwd=n:t.path==="navigation.anchor.position"?e.anchor.position=n:t.path==="navigation.anchor.maxRadius"?e.anchor.maxRadius=n:t.path==="navigation.anchor.currentRadius"?e.anchor.radius=n:t.path==="steering.autopilot.state"&&V===le?e.autopilot.state=n:t.path==="steering.autopilot.mode"&&V===le?e.autopilot.mode=n:t.path==="steering.autopilot.target"&&V===le?e.autopilot.target=n:t.path==="steering.autopilot.engaged"&&V===le?e.autopilot.enabled=n:t.path==="steering.autopilot.defaultPilot"?(e.autopilot.default=n,le=n):t.path==="steering.autopilot.availableActions"&&V===le?e.autopilot.availableActions=n??[]:t.path==="navigation.courseOverGroundTrue"?e.cogTrue=n:t.path==="navigation.courseOverGroundMagnetic"?e.cogMagnetic=n:t.path==="navigation.headingTrue"?(e.headingTrue=n,e.headingTrueUpdatedAt=Date.now()):t.path==="navigation.headingMagnetic"?(e.headingMagnetic=n,e.headingMagneticUpdatedAt=Date.now()):t.path==="navigation.magneticVariation"&&(e.magneticVariation=n);let i=ce.heading;typeof i>"u"||i===Ci?Ei.has(t.path)&&qi(e):t.path===i?e.orientation=Jr(t.path,n,e.magneticVariation):t.path==="navigation.magneticVariation"&&(e.orientation=Ni(e,i)??e.orientation),typeof ce.tws<"u"&&t.path===ce.tws&&(e.wind.tws=n),typeof ce.twd<"u"&&t.path===ce.twd&&(e.wind.direction=t.path==="environment.wind.angleTrueGround"||t.path==="environment.wind.angleTrueWater"?z.angleToDirection(n,e.orientation??0):n);let o=e.cogTrue??ue(e.cogMagnetic,e.magneticVariation)??e.cogMagnetic??void 0;if(typeof o<"u"&&e.position){let s=r?dn.selfLines.cog.length:dn.aisCogLine,a=(e.sog??0)*(s*60);e.vectors.cog=[e.position,C.rhumbDestination(e.position,o,a)]}}function sl(e){let t=new Gt;t.playback=T,t.result={path:e.path,value:e.value,sourceRef:V},postMessage(t)}function al(e){let t=new Wt;t.playback=T,t.result={path:e.path,value:e.value,sourceRef:V},postMessage(t)}function po(e){if(e.path.includes("notifications.")){let t=new $t;t.playback=T,t.result={path:e.path,value:e.value,sourceRef:V},postMessage(t)}}function ul(){let e=new Date().valueOf();l.aisTargets.forEach((t,r)=>{t.lastUpdated.valueOf()<e-K.maxAge?(A.expired[r]=!0,l.aisTargets.delete(r)):t.lastUpdated.valueOf()<e-K.staleAge&&(A.stale[r]=!0)}),l.aircraft.forEach((t,r)=>{t.lastUpdated.valueOf()<e-K.maxAge?(A.expired[r]=!0,l.aircraft.delete(r)):t.lastUpdated.valueOf()<e-K.staleAge&&(A.stale[r]=!0)}),l.sar.forEach((t,r)=>{t.lastUpdated.valueOf()<e-K.maxAge?(A.expired[r]=!0,l.sar.delete(r)):t.lastUpdated.valueOf()<e-K.staleAge&&(A.stale[r]=!0)})}function ll(e,t){let r=!1;if(e.indexOf("shore.basestations")!==-1&&(r=!0),!l.atons.has(e)){let i=new xe;i.id=e,i.position=null,i.type.id=null,r&&(i.type.id=-2,i.type.name="Basestation"),l.atons.set(e,i)}let n=l.atons.get(e);return t.path===""?(typeof t.value.name<"u"&&(n.name=t.value.name),typeof t.value.mmsi<"u"&&(n.mmsi=t.value.mmsi),typeof t.value.atonType<"u"&&(n.type=t.value.atonType)):t.path==="atonType"?n.type=t.value:t.path==="virtual"?n.virtual=t.value:t.path==="navigation.position"?(n.position=[t.value.longitude,t.value.latitude],n.positionReceived=!0):n.properties[t.path]=t.value,e}function cl(e,t){if(!l.sar.has(e)){let n=new Be;n.id=e,n.position=null,n.type.id=-1,n.type.name="SaR Beacon",l.sar.set(e,n)}let r=l.sar.get(e);t.path===""?(typeof t.value.name<"u"&&(r.name=t.value.name),typeof t.value.mmsi<"u"&&(r.mmsi=t.value.mmsi),typeof t.value.communication<"u"&&(r.callsignVhf=t.value.communication.callsignVhf??"",r.callsignHf=t.value.communication.callsignHf??"")):t.path==="communication.callsignVhf"?r.callsignVhf=t.value:t.path==="communication.callsignHf"?r.callsignHf=t.value:t.path==="navigation.position"&&t.value&&(r.position=C.normaliseCoords([t.value.longitude,t.value.latitude]),r.positionReceived=!0)}function fl(e,t){if(!l.meteo.has(e)){let n=new We;n.id=e,n.position=null,n.type.id=-1,n.type.name="Weather Station",l.meteo.set(e,n)}let r=l.meteo.get(e);if(t.path===""){if(typeof t.value.name<"u"&&(r.name=t.value.name),typeof t.value.mmsi<"u"){let n=e.split(":").slice(-2);r.mmsi=n.length===2?`${n[0]}:${n[1]}`:t.value.mmsi}typeof t.value.communication<"u"&&(r.callsignVhf=t.value.communication.callsignVhf??"",r.callsignHf=t.value.communication.callsignHf??"")}else t.path==="communication.callsignVhf"?r.callsignVhf=t.value:t.path==="communication.callsignHf"?r.callsignHf=t.value:t.path==="environment.outside.temperature"?r.temperature=t.value:t.path==="environment.wind.directionTrue"?r.twd=t.value:t.path==="environment.wind.averageSpeed"?r.tws=t.value:t.path==="navigation.position"&&t.value&&(r.position=C.normaliseCoords([t.value.longitude,t.value.latitude]),r.positionReceived=!0)}function dl(e,t){if(!l.aircraft.has(e)){let n=new $e;n.id=e,n.position=null,l.aircraft.set(e,n)}let r=l.aircraft.get(e);t.path===""?(typeof t.value.name<"u"&&(r.name=t.value.name),typeof t.value.mmsi<"u"&&(r.mmsi=t.value.mmsi),typeof t.value.communication<"u"&&(r.callsignVhf=t.value.communication.callsignVhf??"",r.callsignHf=t.value.communication.callsignHf??"")):t.path==="communication.callsignVhf"?r.callsignVhf=t.value:t.path==="communication.callsignHf"?r.callsignHf=t.value:t.path==="navigation.position"&&t.value?(r.position=C.normaliseCoords([t.value.longitude,t.value.latitude]),r.positionReceived=!0,ir(r)):t.path==="navigation.courseOverGroundTrue"?r.orientation=t.value:t.path==="navigation.speedOverGround"&&(r.sog=t.value)}function ir(e){if(e.track&&e.track.length===0)e.track.push([e.position]);else{let t=e.track[e.track.length-1].length,r=e.track[e.track.length-1][t-1];r[0]!==e.position[0]&&r[1]!==e.position[1]&&e.track[e.track.length-1].push(e.position)}e.track[e.track.length-1]=e.track[e.track.length-1].slice(0-(de.has(e.id)?$u:K.maxTrack))}export{De as apiGet,Qu as applyServerAisTracks,ko as assembleTrail,tl as getVesselTrail,Zu as getVesselTrailV2,Jt as handleStreamEvent,Wu as initVessels,mo as processVessel,Yu as timedTrail,To as trackFetch};
|
package/public/chunk-2KQASZ2P.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as Ie,b as O,c as Ae,d as Ke,e as Be}from"./chunk-AQKT2J2C.js";import{$ as Me,La as Re,Ma as Oe,Na as Ge,Oa as Fe,Pa as Xe,Q as Se,Qa as We,Za as Ve,_ as Pe,aa as De,f as ee,k as _e,l as ye,m as ke,n as Ce,o as ve,r as Ee,s as R}from"./chunk-B3ZGKAZU.js";import{a as be,b as Te,c as we}from"./chunk-ISXARX6U.js";import{j as oe,k as re,l as se}from"./chunk-62WHV6CJ.js";import{a as he,b as ge,d as xe}from"./chunk-MYBGWSLC.js";import{a as fe}from"./chunk-6E2BDKCH.js";import"./chunk-45ZTFAA5.js";import{b as le,i as ce,j as pe,n as de,o as me}from"./chunk-X6D4D6EN.js";import{b as ue}from"./chunk-PD55PKQG.js";import"./chunk-YZN4NRWW.js";import"./chunk-YSHHABBQ.js";import{$a as d,$d as J,Ha as f,Ia as _,Id as j,Jd as N,Ka as V,La as T,Ma as w,Md as U,N as B,Na as g,Oa as r,Od as z,Pa as s,Qa as L,Qd as q,R as b,Rd as Q,T as m,U as u,Xa as y,Za as h,Zd as Y,c as A,ce as Z,ee as te,jb as E,je as ie,l as K,ma as c,me as ae,ob as l,pb as H,qb as S,ra as C,sb as P,tb as M,ua as $,ub as D,ue as ne}from"./chunk-RG7WQ7O2.js";import{g as v}from"./chunk-NCEQPEJE.js";var G=class{gpx;constructor(){this.init()}init(){this.gpx=new Ie,this.gpx.metadata.name="Signal K Resource Export",this.gpx.metadata.desc="Freeboard export of Signal K resources"}toXML(){return this.gpx.toXML()}setRoutes(i,e){if(e)e.forEach(t=>{i[t]&&this.gpx.rte.push(this.packageRoute(t,i[t]))});else for(let t in i)this.gpx.rte.push(this.packageRoute(t,i[t]))}packageRoute(i,e){let t=new Ae;t.extensions=t.extensions??{},t.extensions.signalk={},t.extensions.signalk.uuid=i,e.distance&&(t.extensions.signalk.distance=e.distance),t.name=e.name||null,t.desc=e.description||null,t.cmt=e.feature.properties.cmt||null,t.src=e.feature.properties.src||null,t.number=e.feature.properties.number||null,t.type=e.feature.properties.type||null;for(let a of e.feature.geometry.coordinates){let n=new O;n.lon=a[0],n.lat=a[1],n.ele=a[2]||null,t.rtept.push(n),this.gpx.updateBounds(n)}return t}setWaypoints(i,e){if(e)e.forEach(t=>{i[t]&&this.gpx.wpt.push(this.packageWaypoint(t,i[t]))});else for(let t in i)this.gpx.wpt.push(this.packageWaypoint(t,i[t]))}packageWaypoint(i,e){let t=new O;if(t.extensions=t.extensions||{},t.extensions.signalk={},t.extensions.signalk.uuid=i,t.name=e.name||"",t.desc=e.description||"",t.cmt=e.feature.properties.cmt||null,t.geoidHeight=e.feature.properties.geoidHeight||null,t.src=e.feature.properties.src||null,t.sym=e.feature.properties.sym||null,t.type=e.feature.properties.type||null,e.type==="waypoint"){let a=Ee(e.feature.properties.skIcon);a?.gpxType&&(t.type=a.gpxType),a?.gpxSym&&(t.sym=a.gpxSym)}return t.fix=e.feature.properties.fix||null,t.sat=e.feature.properties.sat||null,t.hdop=e.feature.properties.hdop||null,t.vdop=e.feature.properties.vdop||null,t.pdop=e.feature.properties.pdop||null,t.ageOfGpsData=e.feature.properties.ageOfGpsData||null,t.dgpsid=e.feature.properties.dgpsid||null,t.lat=e.feature.geometry.coordinates[1],t.lon=e.feature.geometry.coordinates[0],t.ele=e.feature.geometry.coordinates[2]||null,this.gpx.updateBounds(t),t}setTracks(i,e){if(e)e.forEach(t=>{i[t]&&this.gpx.trk.push(this.packageTrack(t,i[t]))});else for(let t in i)this.gpx.trk.push(this.packageTrack(t,i[t]))}packageTrack(i,e){let t=new Ke;t.extensions=t.extensions||{},t.extensions.signalk={},t.extensions.signalk.uuid=i,t.name=e.feature.properties.name||null,t.desc=e.feature.properties.description||null,t.cmt=e.feature.properties.cmt||null,t.src=e.feature.properties.src||null,t.number=e.feature.properties.number||null,t.type=e.feature.properties.type||null;let a=e.feature.properties.coordTimes;return e.feature.geometry.coordinates.forEach((n,p)=>{let x=new Be;n.forEach((W,He)=>{let k=new O;k.lon=W[0],k.lat=W[1],k.ele=W[2]||null;let I=a?.[p]?.[He];I&&(k.datetime=new Date(I)),x.trkpt.push(k),this.gpx.updateBounds(k)}),t.trkseg.push(x)}),t}};var F=class o{resultSource;result$;sk2gpx;hasFSA;signalk=b(R);constructor(){this.resultSource=new A,this.result$=this.resultSource.asObservable(),this.hasFSA="showOpenFilePicker"in window}clear(){this.sk2gpx=null}prepData(i){let e={routes:[],waypoints:[],tracks:[]},t=1;return e.routes=i.routes.map(a=>{let n=a[1];return n.feature.id=a[0],n}),t=1,e.waypoints=i.waypoints.map(a=>{let n=a[1];return n.feature.id=a[0],n.name=n.name??`Wpt: ${t}`,t++,n}),e.tracks=i.tracks,e}saveToFile(i,e){this.sk2gpx=new G;let t={},a={},n={};for(let p=0;p<e.rte.selected.length;p++)e.rte.selected[p]&&(t[i.routes[p].feature.id]=i.routes[p]);this.sk2gpx.setRoutes(t);for(let p=0;p<e.wpt.selected.length;p++)e.wpt.selected[p]&&(a[i.waypoints[p].feature.id]=i.waypoints[p]);this.sk2gpx.setWaypoints(a),(e.trk.tracks??[]).forEach(p=>{let x=this.signalk.uuid;n[x]=We(x,p)}),this.sk2gpx.setTracks(n),this.hasFSA?this.fsaSaveFile():this.legacySaveToFile()}legacySaveToFile(){let i=new Blob([this.sk2gpx.toXML()],{type:"text/xml"}),e=document.createElement("a");e.href=URL.createObjectURL(i),e.download="fb_export.gpx",e.click(),URL.revokeObjectURL(e.href),e.remove(),this.resultSource.next(-1)}fsaSaveFile(){window.showSaveFilePicker({types:[{description:"GPX file",accept:{"text/xml":[".gpx"]}}]}).then(i=>{i.createWritable().then(e=>{let t=new Blob([this.sk2gpx.toXML()]);e.write(t).then(()=>{e.close(),this.resultSource.next(0)})}).catch(e=>{console.warn(e),this.resultSource.next(1)})}).catch(i=>{i?.name==="SecurityError"?this.legacySaveToFile():this.resultSource.next(-1)})}static \u0275fac=function(e){return new(e||o)};static \u0275prov=B({token:o,factory:o.\u0275fac,providedIn:"root"})};var Ue=(o,i)=>i.context;function ze(o,i){o&1&&L(0,"mat-progress-bar",10)}function qe(o,i){if(o&1){let e=y();r(0,"div",19)(1,"div",20),l(2),s(),r(3,"div",21)(4,"mat-checkbox",22,0),h("change",function(){let a=m(e).$index,n=E(5),p=d(2);return u(p.checkWpt(n.checked,a))}),s()()()}if(o&2){let e=i.$implicit,t=i.$index,a=d(2);c(2),H(e.name),c(2),g("checked",a.selWaypoints[t])}}function Qe(o,i){if(o&1){let e=y();r(0,"div",12)(1,"mat-expansion-panel",13),h("opened",function(){m(e);let a=d();return u(a.display.expand.waypoints=!0)})("closed",function(){m(e);let a=d();return u(a.display.expand.waypoints=!1)}),r(2,"mat-expansion-panel-header",14)(3,"mat-panel-title")(4,"mat-icon",15),l(5,"place"),s(),l(6," \xA0"),r(7,"b"),l(8,"Waypoints:"),s()(),r(9,"mat-panel-description")(10,"div",16)(11,"mat-checkbox",17),h("change",function(a){m(e);let n=d();return u(n.checkWpt(a.checked,-1))})("click",function(a){return a.cancelBubble=!0}),s()()()(),r(12,"div",18),T(13,qe,6,2,"div",19,V),s()()()}if(o&2){let e=d();c(),g("expanded",e.display.expand.waypoints),c(10),g("indeterminate",e.display.someWptChecked)("checked",e.display.allWaypointsChecked)("disabled",e.resData.waypoints.length===0),c(2),w(e.resData.waypoints)}}function Ye(o,i){if(o&1){let e=y();r(0,"div",19)(1,"div",20)(2,"mat-icon",23),l(3,"directions"),s(),l(4),s(),r(5,"div",21)(6,"mat-checkbox",25,1),h("change",function(){let a=m(e).$index,n=E(7),p=d(2);return u(p.checkRte(n.checked,a))}),s()()()}if(o&2){let e=i.$implicit,t=i.$index,a=d(2);c(4),S(" ",e.name," "),c(2),g("checked",a.selRoutes[t])}}function Je(o,i){if(o&1){let e=y();r(0,"div",12)(1,"mat-expansion-panel",13),h("opened",function(){m(e);let a=d();return u(a.display.expand.routes=!0)})("closed",function(){m(e);let a=d();return u(a.display.expand.routes=!1)}),r(2,"mat-expansion-panel-header",14)(3,"mat-panel-title")(4,"mat-icon",23),l(5,"directions"),s(),l(6," \xA0"),r(7,"b"),l(8,"Routes:"),s()(),r(9,"mat-panel-description")(10,"div",16)(11,"mat-checkbox",24),h("change",function(a){m(e);let n=d();return u(n.checkRte(a.checked,-1))})("click",function(a){return a.cancelBubble=!0}),s()()()(),r(12,"div",18),T(13,Ye,8,2,"div",19,V),s()()()}if(o&2){let e=d();c(),g("expanded",e.display.expand.routes),c(10),g("indeterminate",e.display.someRteChecked)("checked",e.display.allRoutesChecked)("disabled",e.resData.routes.length==0),c(2),w(e.resData.routes)}}function Ze(o,i){o&1&&(r(0,"div",30),l(1," Only the positions gathered while Freeboard was open: the server has no recorded track for this vessel. "),s())}function et(o,i){if(o&1){let e=y();r(0,"div",19)(1,"div",20)(2,"mat-icon",26),l(3,"directions_boat"),s(),l(4),s(),r(5,"div",21)(6,"mat-checkbox",29,2),h("change",function(){let a=m(e).$index,n=E(7),p=d(2);return u(p.checkTrk(n.checked,a))}),s()()(),f(8,Ze,2,0,"div",30)}if(o&2){let e=i.$implicit,t=i.$index,a=d(2);c(4),S(" ",e.label," "),c(2),g("checked",a.selTracks[t]),c(2),_(e.tailOnly&&a.trackChoice==="displayed"?8:-1)}}function tt(o,i){o&1&&(r(0,"mat-option",37),l(1,"Track history range"),s())}function it(o,i){o&1&&(r(0,"div",30),l(1,"Choose a From time before the To time."),s())}function at(o,i){if(o&1){let e=y();r(0,"div",39)(1,"mat-form-field")(2,"mat-label"),l(3,"From"),s(),r(4,"input",40),D("ngModelChange",function(a){m(e);let n=d(3);return M(n.customFrom,a)||(n.customFrom=a),u(a)}),s()(),r(5,"mat-form-field")(6,"mat-label"),l(7,"To"),s(),r(8,"input",40),D("ngModelChange",function(a){m(e);let n=d(3);return M(n.customTo,a)||(n.customTo=a),u(a)}),s()()(),f(9,it,2,0,"div",30)}if(o&2){let e=d(3);c(4),P("ngModel",e.customFrom),c(4),P("ngModel",e.customTo),c(),_(e.customInvalid?9:-1)}}function nt(o,i){o&1&&(r(0,"div",30),l(1," Fetched from the server when you save, in the most detail it provides. "),s())}function ot(o,i){if(o&1){let e=y();r(0,"div",28)(1,"mat-form-field",31)(2,"mat-label"),l(3,"Track to export"),s(),r(4,"mat-select",32),D("ngModelChange",function(a){m(e);let n=d(2);return M(n.trackChoice,a)||(n.trackChoice=a),u(a)}),r(5,"mat-option",33),l(6,"As displayed"),s(),r(7,"mat-option",34),l(8,"Last 7 days"),s(),r(9,"mat-option",35),l(10,"Last 30 days"),s(),r(11,"mat-option",36),l(12,"All recorded"),s(),f(13,tt,2,0,"mat-option",37),r(14,"mat-option",38),l(15,"Custom range"),s()()(),f(16,at,10,3)(17,nt,2,0,"div",30),s()}if(o&2){let e=d(2);c(4),P("ngModel",e.trackChoice),c(9),_(e.historyRange?13:-1),c(3),_(e.trackChoice==="custom"?16:e.trackChoice!=="displayed"?17:-1)}}function rt(o,i){if(o&1){let e=y();r(0,"div",12)(1,"mat-expansion-panel",13),h("opened",function(){m(e);let a=d();return u(a.display.expand.tracks=!0)})("closed",function(){m(e);let a=d();return u(a.display.expand.tracks=!1)}),r(2,"mat-expansion-panel-header",14)(3,"mat-panel-title")(4,"mat-icon",26),l(5,"show_chart"),s(),l(6," \xA0"),r(7,"b"),l(8,"Tracks:"),s()(),r(9,"mat-panel-description")(10,"div",16)(11,"mat-checkbox",27),h("change",function(a){m(e);let n=d();return u(n.checkTrk(a.checked,-1))})("click",function(a){return a.cancelBubble=!0}),s()()()(),r(12,"div",18),T(13,et,9,3,null,null,Ue),s(),f(15,ot,18,3,"div",28),s()()}if(o&2){let e=d();c(),g("expanded",e.display.expand.tracks),c(10),g("indeterminate",e.display.someTrkChecked)("checked",e.display.allTracksChecked)("disabled",e.resData.tracks.length==0),c(2),w(e.resData.tracks),c(2),_(e.rangeAvailable?15:-1)}}var st=36e5;function $e(o){let i=new Date(o),e=t=>String(t).padStart(2,"0");return`${i.getFullYear()}-${e(i.getMonth()+1)}-${e(i.getDate())}T${e(i.getHours())}:${e(i.getMinutes())}`}function X(o){let i=o?new Date(o).getTime():NaN;return Number.isFinite(i)?i:null}var Le=class o{constructor(i,e,t,a,n){this.app=i;this.skres=e;this.facade=t;this.dialogRef=a;this.data=n}app;skres;facade;dialogRef;data;resData={routes:[],waypoints:[],tracks:[]};trackChoice="displayed";customFrom="";customTo="";fetching=!1;closed=!1;signalk=b(R);trackHistory=b(De);selRoutes=[];selectedRoute=null;selWaypoints=[];selTracks=[];display={notValid:!1,allRoutesChecked:!1,allWaypointsChecked:!1,allTracksChecked:!1,someWptChecked:!1,someRteChecked:!1,someTrkChecked:!1,saveRoutesOK:!1,saveWaypointsOK:!1,saveTracksOK:!1,routeViewer:!1,selCount:{routes:0,waypoints:0,tracks:0},expand:{routes:!1,waypoints:!1,tracks:!1}};unsubscribe=[];ngOnInit(){let i=Date.now();this.customFrom=$e(i-24*st),this.customTo=$e(i),this.loadResources(),this.data.initialChoice&&this.rangeAvailable&&(this.data.initialChoice!=="history"||this.historyRange)&&(this.trackChoice=this.data.initialChoice),this.unsubscribe.push(this.facade.result$.subscribe(e=>{this.dialogRef.close(e)}))}ngOnDestroy(){this.closed=!0,this.unsubscribe.forEach(i=>i.unsubscribe()),this.facade.clear()}loadResources(){return v(this,null,function*(){if(this.data.tracksOnly){this.data.waypoints=[],this.parseResourceData();return}this.data.routes.sort((i,e)=>i[1].name.localeCompare(e[1].name));try{this.app.sIsFetching.set(!0);let i=yield this.skres.listFromServer("waypoints");i.sort((e,t)=>e[1].name.localeCompare(t[1].name)),this.data.waypoints=i,this.app.sIsFetching.set(!1)}catch(i){this.app.sIsFetching.set(!1),this.resData.waypoints=[]}this.parseResourceData()})}get rangeAvailable(){return!!this.app.featureFlags().tracksApi}get historyRange(){return this.resData.tracks.some(i=>this.trackHistory.isShown(i.context))?this.trackHistory.range():void 0}chosenRange(){return Re(this.trackChoice,Date.now(),{history:this.historyRange,custom:{from:X(this.customFrom),to:X(this.customTo)}})}get customInvalid(){return this.trackChoice==="custom"&&!Oe({from:X(this.customFrom),to:X(this.customTo)})}get rangeUnusable(){return this.rangeAvailable&&this.trackChoice!=="displayed"&&this.chosenRange()===null}get canSave(){return!this.fetching&&!(this.display.saveTracksOK&&this.rangeUnusable)&&(this.display.saveRoutesOK||this.display.saveWaypointsOK||this.display.saveTracksOK)}save(){return v(this,null,function*(){let i;try{i=yield this.selectedTracks()}catch(e){if(this.closed)return;this.app.showAlert("GPX Save","Unable to fetch the recorded track from the server.");return}i===null||this.closed||this.facade.saveToFile(this.resData,{rte:{selected:this.selRoutes},wpt:{selected:this.selWaypoints},trk:{tracks:i}})})}selectedTracks(){return v(this,null,function*(){let i=this.resData.tracks.filter((n,p)=>this.selTracks[p]);if(i.length===0)return[];let e=this.rangeAvailable?this.chosenRange():null,t=Date.now(),a=[];this.fetching=!0;try{for(let n of i){let p=e===null?n.displayed:yield this.fetchTrack(n.context,e),x=Xe(n.label,p,t);if(!x)return this.app.showAlert("GPX Save",e===null?`There is no track to save for ${n.label}.`:`No track is recorded for ${n.label} in the selected range.`),null;a.push(x)}}finally{this.fetching=!1}return a})}fetchTrack(i,e){return v(this,null,function*(){let t=this.app.trackSource()?.provider,a=this.signalk.api.get(2,`/tracks?${Ge(i,e,t)}`);if(!a)throw new Error("Not connected");let n=yield K(a),p=ee(i,n,t);return{lines:p?.lines??[],times:p?.times??(p?.lines??[]).map(x=>x.map(()=>{}))}})}parseResourceData(){this.display.allRoutesChecked=!1,this.display.saveRoutesOK=!1,this.selRoutes=[],this.display.allWaypointsChecked=!1,this.display.saveWaypointsOK=!1,this.selWaypoints=[],this.display.allTracksChecked=!1,this.display.saveTracksOK=!1,this.selTracks=[],this.display.selCount={routes:0,waypoints:0,tracks:0},this.display.expand={routes:!1,waypoints:!1,tracks:!1},this.display.notValid=!1,this.resData=this.facade.prepData(this.data),this.resData.tracks=this.resData.tracks.filter(i=>this.rangeAvailable||Fe(i.displayed?.lines)),this.resData.routes.forEach(()=>{this.selRoutes.push(!1)}),this.selRoutes.length===1&&(this.selRoutes[0]=!0,this.display.allRoutesChecked=!0,this.display.expand.routes=!0,this.display.saveRoutesOK=!0),this.resData.waypoints.forEach(()=>{this.selWaypoints.push(!1)}),this.resData.tracks.forEach(()=>{this.selTracks.push(!1)}),this.data.tracksOnly&&this.selTracks.length!==0&&(this.checkTrk(!0,-1),this.display.expand.tracks=!0)}checkRte(i,e=-1){let t=0;if(e!==-1){this.selRoutes[e]=i,this.display.saveRoutesOK=i;for(let a of this.selRoutes)a&&t++;this.display.saveRoutesOK=t!==0,this.display.selCount.routes=t,this.display.allRoutesChecked=t===this.selRoutes.length}else{for(let a=0;a<this.selRoutes.length;a++)this.selRoutes[a]=i,this.display.saveRoutesOK=i,this.display.allRoutesChecked=i;this.display.selCount.routes=i?this.selRoutes.length:0}this.display.someRteChecked=!(this.display.allRoutesChecked||t===0)}checkWpt(i,e=-1){let t=0;if(e!==-1){this.selWaypoints[e]=i,this.display.saveWaypointsOK=i;for(let a of this.selWaypoints)a&&t++;this.display.saveWaypointsOK=t!==0,this.display.selCount.waypoints=t,this.display.allWaypointsChecked=t===this.selWaypoints.length}else{for(let a=0;a<this.selWaypoints.length;a++)this.selWaypoints[a]=i,this.display.saveWaypointsOK=i,this.display.allWaypointsChecked=i;this.display.selCount.waypoints=i?this.selWaypoints.length:0}this.display.someWptChecked=!(this.display.allWaypointsChecked||t===0)}checkTrk(i,e=-1){let t=0;if(e!==-1){this.selTracks[e]=i,this.display.saveTracksOK=i;for(let a of this.selTracks)a&&t++;this.display.saveTracksOK=t!==0,this.display.selCount.tracks=t,this.display.allTracksChecked=t===this.selTracks.length}else{for(let a=0;a<this.selTracks.length;a++)this.selTracks[a]=i,this.display.saveTracksOK=i,this.display.allTracksChecked=i;this.display.selCount.tracks=i?this.selTracks.length:0}this.display.someTrkChecked=!(this.display.allTracksChecked||t===0)}static \u0275fac=function(e){return new(e||o)(C(Ve),C(Se),C(F),C(j),C(N))};static \u0275cmp=$({type:o,selectors:[["gpxsave-dialog"]],decls:19,vars:6,consts:[["wval",""],["rval",""],["tval",""],[1,"gpxsave-dialog"],[2,"background-color","transparent"],[2,"display","flex","width","100%"],["mat-raised-button","","matTooltip","Save selected resources","matTooltipPosition","right",2,"width","85px",3,"click","disabled"],[2,"flex","1 1 auto","text-align","center"],[2,"text-align","right"],["mat-icon-button","",3,"click"],["mode","indeterminate"],["mat-dialog-content","",2,"padding","2px"],[1,"card-group"],[3,"opened","closed","expanded"],[1,"panel-header"],[1,"icon-waypoint"],[1,"panel-description"],["matTooltip","Select all Waypoints","matTooltipPosition","before",3,"change","click","indeterminate","checked","disabled"],[1,"list-container-scrollable"],[1,"item-row"],[1,"name"],[1,"check"],["matTooltip","Select Waypoint","matTooltipPosition","below",3,"change","checked"],[1,"icon-route"],["matTooltip","Select all Routes","matTooltipPosition","before",3,"change","click","indeterminate","checked","disabled"],["matTooltip","Select this Route","matTooltipPosition","below",3,"change","checked"],[1,"icon-track"],["matTooltip","Select all Tracks","matTooltipPosition","before",3,"change","click","indeterminate","checked","disabled"],[1,"track-range"],["matTooltip","Select this Track","matTooltipPosition","below",3,"change","checked"],[1,"track-note"],[1,"track-range-select"],[3,"ngModelChange","ngModel"],["value","displayed"],["value","7d"],["value","30d"],["value","all"],["value","history"],["value","custom"],[1,"track-range-custom"],["matInput","","type","datetime-local",3,"ngModelChange","ngModel"]],template:function(e,t){e&1&&(r(0,"div",3)(1,"mat-toolbar",4)(2,"div",5)(3,"div")(4,"button",6),h("click",function(){return t.save()}),r(5,"mat-icon"),l(6,"save"),s(),l(7,"\xA0Save\xA0 "),s()(),r(8,"div",7),l(9),s(),r(10,"div",8)(11,"button",9),h("click",function(){return t.dialogRef.close(-1)}),r(12,"mat-icon"),l(13,"close"),s()()()()(),f(14,ze,1,0,"mat-progress-bar",10),r(15,"div",11),f(16,Qe,15,4,"div",12),f(17,Je,15,4,"div",12),f(18,rt,16,5,"div",12),s()()),e&2&&(c(4),g("disabled",!t.canSave),c(5),S(" ",t.data.tracksOnly?"Export track to GPX":"Export to GPX"," "),c(5),_(t.fetching?14:-1),c(2),_(t.resData.waypoints.length!==0?16:-1),c(),_(t.resData.routes.length!==0?17:-1),c(),_(t.resData.tracks.length!==0?18:-1))},dependencies:[Te,be,Me,Pe,z,U,Q,q,Z,J,Y,oe,pe,ce,le,me,de,ue,ve,_e,ye,Ce,ke,se,re,we,fe,xe,ge,he,ne,te,ie,ae],styles:[".gpxsave-dialog[_ngcontent-%COMP%]{font-family:roboto;position:relative}.dialog-content[_ngcontent-%COMP%]{position:relative;min-height:300px;max-height:400px;width:100%;min-width:240px;overflow-y:auto}.dialog-icon[_ngcontent-%COMP%]{display:none}.card-group[_ngcontent-%COMP%]{padding:5px 5%}.card-group[_ngcontent-%COMP%] .panel-header[_ngcontent-%COMP%]{padding:0 5px}.card-group[_ngcontent-%COMP%] .panel-description[_ngcontent-%COMP%]{text-align:right;width:100%;padding-right:10px}.card-group-title[_ngcontent-%COMP%]{font-weight:700;font-size:10pt;font-family:Arial,Helvetica,sans-serif;padding:10px 0}button[_ngcontent-%COMP%]{min-width:unset;padding:unset}.item-row[_ngcontent-%COMP%]{display:flex;width:100%;padding:2px 0}.item-row[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{flex:1 1 auto;overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1;text-overflow:ellipsis;line-height:2.5em}.item-row[_ngcontent-%COMP%] .check[_ngcontent-%COMP%]{text-align:right;padding-right:15px}.track-note[_ngcontent-%COMP%]{font-size:.85em;opacity:.8;padding:0 15px 4px 30px}.track-range[_ngcontent-%COMP%]{padding:8px 5px 0}.track-range-select[_ngcontent-%COMP%]{width:100%}.track-range-custom[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:0 8px}.track-range-custom[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{flex:1 1 220px}@media only screen and (min-width:475px){button[_ngcontent-%COMP%]{min-width:inherit;padding:inherit}.dialog-content[_ngcontent-%COMP%]{min-width:400px}.dialog-icon[_ngcontent-%COMP%]{display:inline}}@media only screen and (min-width:800px){.card-group[_ngcontent-%COMP%]{padding:5px 5%}}"]})};export{Le as GPXExportDialog,X as fromLocalInput,$e as toLocalInput};
|
package/public/chunk-6E2BDKCH.js
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import{$ as w,Ad as v,Ec as X,Hd as Z,K as r,Nc as z,P as _,R as n,Ra as f,Sa as R,Uc as G,Wc as j,X as p,Y as T,Za as A,Zc as F,_a as O,_b as H,bd as U,c,db as M,eb as x,fa as h,fb as S,hd as B,kd as $,lb as u,ma as D,na as m,nb as L,ob as k,pb as N,qa as P,qc as V,ta as C,ua as I,wa as E,wc as g,wd as y,yc as Y}from"./chunk-RG7WQ7O2.js";import{a as l}from"./chunk-NCEQPEJE.js";var q=["tooltip"],K=20;var J=new _("mat-tooltip-scroll-strategy",{providedIn:"root",factory:()=>{let a=n(p);return()=>j(a,{scrollThrottle:K})}}),tt=new _("mat-tooltip-default-options",{providedIn:"root",factory:()=>({showDelay:0,hideDelay:0,touchendHideDelay:1500})});var Q="tooltip-panel",et={passive:!0},it=8,ot=8,st=24,nt=200,It=(()=>{class a{_elementRef=n(h);_ngZone=n(w);_platform=n(V);_ariaDescriber=n(Z);_focusMonitor=n(B);_dir=n(Y);_injector=n(p);_viewContainerRef=n(C);_mediaMatcher=n($);_document=n(T);_renderer=n(P);_animationsDisabled=v();_defaultOptions=n(tt,{optional:!0});_overlayRef=null;_tooltipInstance=null;_overlayPanelClass;_portal;_position="below";_positionAtOrigin=!1;_disabled=!1;_tooltipClass;_viewInitialized=!1;_pointerExitEventsInitialized=!1;_tooltipComponent=at;_viewportMargin=8;_currentPosition;_cssClassPrefix="mat-mdc";_ariaDescriptionPending=!1;_dirSubscribed=!1;get position(){return this._position}set position(t){t!==this._position&&(this._position=t,this._overlayRef&&(this._updatePosition(this._overlayRef),this._tooltipInstance?.show(0),this._overlayRef.updatePosition()))}get positionAtOrigin(){return this._positionAtOrigin}set positionAtOrigin(t){this._positionAtOrigin=y(t),this._detach(),this._overlayRef=null}get disabled(){return this._disabled}set disabled(t){let e=y(t);this._disabled!==e&&(this._disabled=e,e?this.hide(0):this._setupPointerEnterEventsIfNeeded(),this._syncAriaDescription(this.message))}get showDelay(){return this._showDelay}set showDelay(t){this._showDelay=g(t)}_showDelay;get hideDelay(){return this._hideDelay}set hideDelay(t){this._hideDelay=g(t),this._tooltipInstance&&(this._tooltipInstance._mouseLeaveHideDelay=this._hideDelay)}_hideDelay;touchGestures="auto";get message(){return this._message}set message(t){let e=this._message;this._message=t!=null?String(t).trim():"",!this._message&&this._isTooltipVisible()?this.hide(0):(this._setupPointerEnterEventsIfNeeded(),this._updateTooltipMessage()),this._syncAriaDescription(e)}_message="";get tooltipClass(){return this._tooltipClass}set tooltipClass(t){this._tooltipClass=t,this._tooltipInstance&&this._setTooltipClass(this._tooltipClass)}_eventCleanups=[];_touchstartTimeout=null;_destroyed=new c;_isDestroyed=!1;constructor(){let t=this._defaultOptions;t&&(this._showDelay=t.showDelay,this._hideDelay=t.hideDelay,t.position&&(this.position=t.position),t.positionAtOrigin&&(this.positionAtOrigin=t.positionAtOrigin),t.touchGestures&&(this.touchGestures=t.touchGestures),t.tooltipClass&&(this.tooltipClass=t.tooltipClass)),this._viewportMargin=it}ngAfterViewInit(){this._viewInitialized=!0,this._setupPointerEnterEventsIfNeeded(),this._focusMonitor.monitor(this._elementRef).pipe(r(this._destroyed)).subscribe(t=>{t?t==="keyboard"&&this._ngZone.run(()=>this.show()):this._ngZone.run(()=>this.hide(0))})}ngOnDestroy(){let t=this._elementRef.nativeElement;this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this._overlayRef&&(this._overlayRef.dispose(),this._tooltipInstance=null),this._eventCleanups.forEach(e=>e()),this._eventCleanups.length=0,this._destroyed.next(),this._destroyed.complete(),this._isDestroyed=!0,this._ariaDescriber.removeDescription(t,this.message,"tooltip"),this._focusMonitor.stopMonitoring(t)}show(t=this.showDelay,e){if(this.disabled||!this.message||this._isTooltipVisible()){this._tooltipInstance?._cancelPendingAnimations();return}let i=this._createOverlay(e);this._detach(),this._portal=this._portal||new z(this._tooltipComponent,this._viewContainerRef);let o=this._tooltipInstance=i.attach(this._portal).instance;o._triggerElement=this._elementRef.nativeElement,o._mouseLeaveHideDelay=this._hideDelay,o.afterHidden().pipe(r(this._destroyed)).subscribe(()=>this._detach()),this._setTooltipClass(this._tooltipClass),this._updateTooltipMessage(),o.show(t)}hide(t=this.hideDelay){let e=this._tooltipInstance;e&&(e.isVisible()?e.hide(t):(e._cancelPendingAnimations(),this._detach()))}toggle(t){this._isTooltipVisible()?this.hide():this.show(void 0,t)}_isTooltipVisible(){return!!this._tooltipInstance&&this._tooltipInstance.isVisible()}_createOverlay(t){if(this._overlayRef){let s=this._overlayRef.getConfig().positionStrategy;if((!this.positionAtOrigin||!t)&&s._origin instanceof h)return this._overlayRef;this._detach()}let e=this._injector.get(X).getAncestorScrollContainers(this._elementRef),i=`${this._cssClassPrefix}-${Q}`,o=F(this._injector,this.positionAtOrigin?t||this._elementRef:this._elementRef).withTransformOriginOn(`.${this._cssClassPrefix}-tooltip`).withFlexibleDimensions(!1).withViewportMargin(this._viewportMargin).withScrollableContainers(e).withPopoverLocation("global");return o.positionChanges.pipe(r(this._destroyed)).subscribe(s=>{this._updateCurrentPositionClass(s.connectionPair),this._tooltipInstance&&s.scrollableViewProperties.isOverlayClipped&&this._tooltipInstance.isVisible()&&this._ngZone.run(()=>this.hide(0))}),this._overlayRef=U(this._injector,{direction:this._dir,positionStrategy:o,panelClass:this._overlayPanelClass?[...this._overlayPanelClass,i]:i,scrollStrategy:this._injector.get(J)(),disableAnimations:this._animationsDisabled,eventPredicate:this._overlayEventPredicate}),this._updatePosition(this._overlayRef),this._overlayRef.detachments().pipe(r(this._destroyed)).subscribe(()=>this._detach()),this._overlayRef.outsidePointerEvents().pipe(r(this._destroyed)).subscribe(()=>this._tooltipInstance?._handleBodyInteraction()),this._overlayRef.keydownEvents().pipe(r(this._destroyed)).subscribe(s=>{s.preventDefault(),s.stopPropagation(),this._ngZone.run(()=>this.hide(0))}),this._defaultOptions?.disableTooltipInteractivity&&this._overlayRef.addPanelClass(`${this._cssClassPrefix}-tooltip-panel-non-interactive`),this._dirSubscribed||(this._dirSubscribed=!0,this._dir.change.pipe(r(this._destroyed)).subscribe(()=>{this._overlayRef&&this._updatePosition(this._overlayRef)})),this._overlayRef}_detach(){this._overlayRef&&this._overlayRef.hasAttached()&&this._overlayRef.detach(),this._tooltipInstance=null}_updatePosition(t){let e=t.getConfig().positionStrategy,i=this._getOrigin(),o=this._getOverlayPosition();e.withPositions([this._addOffset(l(l({},i.main),o.main)),this._addOffset(l(l({},i.fallback),o.fallback))])}_addOffset(t){let e=ot,i=!this._dir||this._dir.value=="ltr";return t.originY==="top"?t.offsetY=-e:t.originY==="bottom"?t.offsetY=e:t.originX==="start"?t.offsetX=i?-e:e:t.originX==="end"&&(t.offsetX=i?e:-e),t}_getOrigin(){let t=!this._dir||this._dir.value=="ltr",e=this.position,i;e=="above"||e=="below"?i={originX:"center",originY:e=="above"?"top":"bottom"}:e=="before"||e=="left"&&t||e=="right"&&!t?i={originX:"start",originY:"center"}:(e=="after"||e=="right"&&t||e=="left"&&!t)&&(i={originX:"end",originY:"center"});let{x:o,y:s}=this._invertPosition(i.originX,i.originY);return{main:i,fallback:{originX:o,originY:s}}}_getOverlayPosition(){let t=!this._dir||this._dir.value=="ltr",e=this.position,i;e=="above"?i={overlayX:"center",overlayY:"bottom"}:e=="below"?i={overlayX:"center",overlayY:"top"}:e=="before"||e=="left"&&t||e=="right"&&!t?i={overlayX:"end",overlayY:"center"}:(e=="after"||e=="right"&&t||e=="left"&&!t)&&(i={overlayX:"start",overlayY:"center"});let{x:o,y:s}=this._invertPosition(i.overlayX,i.overlayY);return{main:i,fallback:{overlayX:o,overlayY:s}}}_updateTooltipMessage(){this._tooltipInstance&&(this._tooltipInstance.message=this.message,this._tooltipInstance._markForCheck(),m(()=>{this._tooltipInstance&&this._overlayRef.updatePosition()},{injector:this._injector}))}_setTooltipClass(t){this._tooltipInstance&&(this._tooltipInstance.tooltipClass=t instanceof Set?Array.from(t):t,this._tooltipInstance._markForCheck())}_invertPosition(t,e){return this.position==="above"||this.position==="below"?e==="top"?e="bottom":e==="bottom"&&(e="top"):t==="end"?t="start":t==="start"&&(t="end"),{x:t,y:e}}_updateCurrentPositionClass(t){let{overlayY:e,originX:i,originY:o}=t,s;if(e==="center"?this._dir&&this._dir.value==="rtl"?s=i==="end"?"left":"right":s=i==="start"?"left":"right":s=e==="bottom"&&o==="top"?"above":"below",s!==this._currentPosition){let d=this._overlayRef;if(d){let b=`${this._cssClassPrefix}-${Q}-`;d.removePanelClass(b+this._currentPosition),d.addPanelClass(b+s)}this._currentPosition=s}}_setupPointerEnterEventsIfNeeded(){this._disabled||!this.message||!this._viewInitialized||this._eventCleanups.length||(this._isTouchPlatform()?this.touchGestures!=="off"&&(this._disableNativeGesturesIfNecessary(),this._addListener("touchstart",t=>{let e=t.targetTouches?.[0],i=e?{x:e.clientX,y:e.clientY}:void 0;this._setupPointerExitEventsIfNeeded(),this._touchstartTimeout&&clearTimeout(this._touchstartTimeout);let o=500;this._touchstartTimeout=setTimeout(()=>{this._touchstartTimeout=null,this.show(void 0,i)},this._defaultOptions?.touchLongPressShowDelay??o)})):this._addListener("mouseenter",t=>{this._setupPointerExitEventsIfNeeded();let e;t.x!==void 0&&t.y!==void 0&&(e=t),this.show(void 0,e)}))}_setupPointerExitEventsIfNeeded(){if(!this._pointerExitEventsInitialized){if(this._pointerExitEventsInitialized=!0,!this._isTouchPlatform())this._addListener("mouseleave",t=>{let e=t.relatedTarget;(!e||!this._overlayRef?.overlayElement.contains(e))&&this.hide()}),this._addListener("wheel",t=>{if(this._isTooltipVisible()){let e=this._document.elementFromPoint(t.clientX,t.clientY),i=this._elementRef.nativeElement;e!==i&&!i.contains(e)&&this.hide()}});else if(this.touchGestures!=="off"){this._disableNativeGesturesIfNecessary();let t=()=>{this._touchstartTimeout&&clearTimeout(this._touchstartTimeout),this.hide(this._defaultOptions?.touchendHideDelay)};this._addListener("touchend",t),this._addListener("touchcancel",t)}}}_addListener(t,e){this._eventCleanups.push(this._renderer.listen(this._elementRef.nativeElement,t,e,et))}_isTouchPlatform(){let t=this._defaultOptions?.detectHoverCapability;return typeof t=="function"?!t():this._platform.IOS||this._platform.ANDROID?!0:this._platform.isBrowser?!!t&&this._mediaMatcher.matchMedia("(any-hover: none)").matches:!1}_disableNativeGesturesIfNecessary(){let t=this.touchGestures;if(t!=="off"){let e=this._elementRef.nativeElement,i=e.style;(t==="on"||e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA")&&(i.userSelect=i.msUserSelect=i.webkitUserSelect=i.MozUserSelect="none"),(t==="on"||!e.draggable)&&(i.webkitUserDrag="none"),i.touchAction="none",i.webkitTapHighlightColor="transparent"}}_syncAriaDescription(t){this._ariaDescriptionPending||(this._ariaDescriptionPending=!0,this._ariaDescriber.removeDescription(this._elementRef.nativeElement,t,"tooltip"),this._isDestroyed||m({write:()=>{this._ariaDescriptionPending=!1,this.message&&!this.disabled&&this._ariaDescriber.describe(this._elementRef.nativeElement,this.message,"tooltip")}},{injector:this._injector}))}_overlayEventPredicate=t=>t.type==="keydown"?this._isTooltipVisible()&&t.keyCode===27&&!G(t):!0;static \u0275fac=function(e){return new(e||a)};static \u0275dir=E({type:a,selectors:[["","matTooltip",""]],hostAttrs:[1,"mat-mdc-tooltip-trigger"],hostVars:2,hostBindings:function(e,i){e&2&&u("mat-mdc-tooltip-disabled",i.disabled)},inputs:{position:[0,"matTooltipPosition","position"],positionAtOrigin:[0,"matTooltipPositionAtOrigin","positionAtOrigin"],disabled:[0,"matTooltipDisabled","disabled"],showDelay:[0,"matTooltipShowDelay","showDelay"],hideDelay:[0,"matTooltipHideDelay","hideDelay"],touchGestures:[0,"matTooltipTouchGestures","touchGestures"],message:[0,"matTooltip","message"],tooltipClass:[0,"matTooltipClass","tooltipClass"]},exportAs:["matTooltip"]})}return a})(),at=(()=>{class a{_changeDetectorRef=n(H);_elementRef=n(h);_isMultiline=!1;message;tooltipClass;_showTimeoutId;_hideTimeoutId;_triggerElement;_mouseLeaveHideDelay;_animationsDisabled=v();_tooltip;_closeOnInteraction=!1;_isVisible=!1;_onHide=new c;_showAnimation="mat-mdc-tooltip-show";_hideAnimation="mat-mdc-tooltip-hide";constructor(){}show(t){this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=setTimeout(()=>{this._toggleVisibility(!0),this._showTimeoutId=void 0},t)}hide(t){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId=setTimeout(()=>{this._toggleVisibility(!1),this._hideTimeoutId=void 0},t)}afterHidden(){return this._onHide}isVisible(){return this._isVisible}ngOnDestroy(){this._cancelPendingAnimations(),this._onHide.complete(),this._triggerElement=null}_handleBodyInteraction(){this._closeOnInteraction&&this.hide(0)}_markForCheck(){this._changeDetectorRef.markForCheck()}_handleMouseLeave({relatedTarget:t}){(!t||!this._triggerElement.contains(t))&&(this.isVisible()?this.hide(this._mouseLeaveHideDelay):this._finalizeAnimation(!1))}_onShow(){this._isMultiline=this._isTooltipMultiline(),this._markForCheck()}_isTooltipMultiline(){let t=this._elementRef.nativeElement.getBoundingClientRect();return t.height>st&&t.width>=nt}_handleAnimationEnd({animationName:t}){(t===this._showAnimation||t===this._hideAnimation)&&this._finalizeAnimation(t===this._showAnimation)}_cancelPendingAnimations(){this._showTimeoutId!=null&&clearTimeout(this._showTimeoutId),this._hideTimeoutId!=null&&clearTimeout(this._hideTimeoutId),this._showTimeoutId=this._hideTimeoutId=void 0}_finalizeAnimation(t){t?this._closeOnInteraction=!0:this.isVisible()||this._onHide.next()}_toggleVisibility(t){let e=this._tooltip.nativeElement,i=this._showAnimation,o=this._hideAnimation;if(e.classList.remove(t?o:i),e.classList.add(t?i:o),this._isVisible!==t&&(this._isVisible=t,this._changeDetectorRef.markForCheck()),t&&!this._animationsDisabled&&typeof getComputedStyle=="function"){let s=getComputedStyle(e);(s.getPropertyValue("animation-duration")==="0s"||s.getPropertyValue("animation-name")==="none")&&(this._animationsDisabled=!0)}t&&this._onShow(),this._animationsDisabled&&(e.classList.add("_mat-animation-noopable"),this._finalizeAnimation(t))}static \u0275fac=function(e){return new(e||a)};static \u0275cmp=I({type:a,selectors:[["mat-tooltip-component"]],viewQuery:function(e,i){if(e&1&&M(q,7),e&2){let o;x(o=S())&&(i._tooltip=o.first)}},hostAttrs:["aria-hidden","true"],hostBindings:function(e,i){e&1&&A("mouseleave",function(s){return i._handleMouseLeave(s)})},decls:4,vars:5,consts:[["tooltip",""],[1,"mdc-tooltip","mat-mdc-tooltip",3,"animationend"],[1,"mat-mdc-tooltip-surface","mdc-tooltip__surface"]],template:function(e,i){e&1&&(f(0,"div",1,0),O("animationend",function(s){return i._handleAnimationEnd(s)}),f(2,"div",2),k(3),R()()),e&2&&(L(i.tooltipClass),u("mdc-tooltip--multiline",i._isMultiline),D(3),N(i.message))},styles:[`.mat-mdc-tooltip {
|
|
2
|
-
position: relative;
|
|
3
|
-
transform: scale(0);
|
|
4
|
-
display: inline-flex;
|
|
5
|
-
}
|
|
6
|
-
.mat-mdc-tooltip::before {
|
|
7
|
-
content: "";
|
|
8
|
-
top: 0;
|
|
9
|
-
right: 0;
|
|
10
|
-
bottom: 0;
|
|
11
|
-
left: 0;
|
|
12
|
-
z-index: -1;
|
|
13
|
-
position: absolute;
|
|
14
|
-
}
|
|
15
|
-
.mat-mdc-tooltip-panel-below .mat-mdc-tooltip::before {
|
|
16
|
-
top: -8px;
|
|
17
|
-
}
|
|
18
|
-
.mat-mdc-tooltip-panel-above .mat-mdc-tooltip::before {
|
|
19
|
-
bottom: -8px;
|
|
20
|
-
}
|
|
21
|
-
.mat-mdc-tooltip-panel-right .mat-mdc-tooltip::before {
|
|
22
|
-
left: -8px;
|
|
23
|
-
}
|
|
24
|
-
.mat-mdc-tooltip-panel-left .mat-mdc-tooltip::before {
|
|
25
|
-
right: -8px;
|
|
26
|
-
}
|
|
27
|
-
.mat-mdc-tooltip._mat-animation-noopable {
|
|
28
|
-
animation: none;
|
|
29
|
-
transform: scale(1);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.mat-mdc-tooltip-surface {
|
|
33
|
-
word-break: normal;
|
|
34
|
-
overflow-wrap: anywhere;
|
|
35
|
-
padding: 4px 8px;
|
|
36
|
-
min-width: 40px;
|
|
37
|
-
max-width: 200px;
|
|
38
|
-
min-height: 24px;
|
|
39
|
-
max-height: 40vh;
|
|
40
|
-
box-sizing: border-box;
|
|
41
|
-
overflow: hidden;
|
|
42
|
-
text-align: center;
|
|
43
|
-
will-change: transform, opacity;
|
|
44
|
-
background-color: var(--mat-tooltip-container-color, var(--mat-sys-inverse-surface));
|
|
45
|
-
color: var(--mat-tooltip-supporting-text-color, var(--mat-sys-inverse-on-surface));
|
|
46
|
-
border-radius: var(--mat-tooltip-container-shape, var(--mat-sys-corner-extra-small));
|
|
47
|
-
font-family: var(--mat-tooltip-supporting-text-font, var(--mat-sys-body-small-font));
|
|
48
|
-
font-size: var(--mat-tooltip-supporting-text-size, var(--mat-sys-body-small-size));
|
|
49
|
-
font-weight: var(--mat-tooltip-supporting-text-weight, var(--mat-sys-body-small-weight));
|
|
50
|
-
line-height: var(--mat-tooltip-supporting-text-line-height, var(--mat-sys-body-small-line-height));
|
|
51
|
-
letter-spacing: var(--mat-tooltip-supporting-text-tracking, var(--mat-sys-body-small-tracking));
|
|
52
|
-
}
|
|
53
|
-
.mat-mdc-tooltip-surface::before {
|
|
54
|
-
position: absolute;
|
|
55
|
-
box-sizing: border-box;
|
|
56
|
-
width: 100%;
|
|
57
|
-
height: 100%;
|
|
58
|
-
top: 0;
|
|
59
|
-
left: 0;
|
|
60
|
-
border: 1px solid transparent;
|
|
61
|
-
border-radius: inherit;
|
|
62
|
-
content: "";
|
|
63
|
-
pointer-events: none;
|
|
64
|
-
}
|
|
65
|
-
.mdc-tooltip--multiline .mat-mdc-tooltip-surface {
|
|
66
|
-
text-align: left;
|
|
67
|
-
}
|
|
68
|
-
[dir=rtl] .mdc-tooltip--multiline .mat-mdc-tooltip-surface {
|
|
69
|
-
text-align: right;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.mat-mdc-tooltip-panel {
|
|
73
|
-
line-height: normal;
|
|
74
|
-
}
|
|
75
|
-
.mat-mdc-tooltip-panel.mat-mdc-tooltip-panel-non-interactive {
|
|
76
|
-
pointer-events: none;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
@keyframes mat-mdc-tooltip-show {
|
|
80
|
-
0% {
|
|
81
|
-
opacity: 0;
|
|
82
|
-
transform: scale(0.8);
|
|
83
|
-
}
|
|
84
|
-
100% {
|
|
85
|
-
opacity: 1;
|
|
86
|
-
transform: scale(1);
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
@keyframes mat-mdc-tooltip-hide {
|
|
90
|
-
0% {
|
|
91
|
-
opacity: 1;
|
|
92
|
-
transform: scale(1);
|
|
93
|
-
}
|
|
94
|
-
100% {
|
|
95
|
-
opacity: 0;
|
|
96
|
-
transform: scale(0.8);
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
.mat-mdc-tooltip-show {
|
|
100
|
-
animation: mat-mdc-tooltip-show 150ms cubic-bezier(0, 0, 0.2, 1) forwards;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
.mat-mdc-tooltip-hide {
|
|
104
|
-
animation: mat-mdc-tooltip-hide 75ms cubic-bezier(0.4, 0, 1, 1) forwards;
|
|
105
|
-
}
|
|
106
|
-
`],encapsulation:2,changeDetection:0})}return a})();export{It as a};
|