@signalk/freeboard-sk
Version:
Openlayers chart plotter implementation for Signal K
4 lines • 3.17 MB
JavaScript
import{a as Te,b as si,c as we,d as _l,e as De}from"./chunk-FDERIQAA.js";var Da=we(yr=>{"use strict";Object.defineProperty(yr,"__esModule",{value:!0});yr.areaConversion=yr.timeConversion=yr.distanceConversion=yr.altitudeKeys=yr.latitudeKeys=yr.longitudeKeys=yr.MAXLON=yr.MINLON=yr.MAXLAT=yr.MINLAT=yr.earthRadius=yr.sexagesimalPattern=void 0;var vve=/^([0-9]{1,3})°\s*([0-9]{1,3}(?:\.(?:[0-9]{1,}))?)['′]\s*(([0-9]{1,3}(\.([0-9]{1,}))?)["″]\s*)?([NEOSW]?)$/;yr.sexagesimalPattern=vve;var Cve=6378137;yr.earthRadius=Cve;var xve=-90;yr.MINLAT=xve;var wve=90;yr.MAXLAT=wve;var Mve=-180;yr.MINLON=Mve;var Sve=180;yr.MAXLON=Sve;var Dve=["lng","lon","longitude",0];yr.longitudeKeys=Dve;var Eve=["lat","latitude",1];yr.latitudeKeys=Eve;var Tve=["alt","altitude","elevation","elev",2];yr.altitudeKeys=Tve;var Ive={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};yr.distanceConversion=Ive;var kve={m:60,h:3600,d:86400};yr.timeConversion=kve;var Qc={m2:1,km2:1e-6,ha:1e-4,a:.01,ft2:10.763911,yd2:1.19599,in2:1550.0031};yr.areaConversion=Qc;Qc.sqm=Qc.m2;Qc.sqkm=Qc.km2;Qc.sqft=Qc.ft2;Qc.sqyd=Qc.yd2;Qc.sqin=Qc.in2});var B1=we(PD=>{"use strict";Object.defineProperty(PD,"__esModule",{value:!0});PD.default=void 0;var Pve=function(t,e){return e.reduce(function(i,r){if(typeof t>"u"||t===null)throw new Error("'".concat(t,"' is no valid coordinate."));return Object.prototype.hasOwnProperty.call(t,r)&&typeof r<"u"&&typeof i>"u"?(i=r,r):i},void 0)},Ove=Pve;PD.default=Ove});var j1=we(OD=>{"use strict";Object.defineProperty(OD,"__esModule",{value:!0});OD.default=void 0;var Ave=function(t){var e=t.toString().trim();return isNaN(parseFloat(e))?!1:parseFloat(e)===Number(e)},Rve=Ave;OD.default=Rve});var z1=we(AD=>{"use strict";Object.defineProperty(AD,"__esModule",{value:!0});AD.default=void 0;var Lve=Da(),Fve=function(t){return Lve.sexagesimalPattern.test(t.toString().trim())},Nve=Fve;AD.default=Nve});var U1=we(RD=>{"use strict";Object.defineProperty(RD,"__esModule",{value:!0});RD.default=void 0;var Vve=Da(),Bve=function(t){var e=new RegExp(Vve.sexagesimalPattern).exec(t.toString().trim());if(typeof e>"u"||e===null)throw new Error("Given value is not in sexagesimal format");var i=Number(e[2])/60||0,r=Number(e[4])/3600||0,o=parseFloat(e[1])+i+r;return["S","W"].includes(e[7])?-o:o},jve=Bve;RD.default=jve});var FD=we(LD=>{"use strict";Object.defineProperty(LD,"__esModule",{value:!0});LD.default=void 0;var OL=Da(),AL=zve(B1());function zve(n){return n&&n.__esModule?n:{default:n}}function Kq(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable})),e.push.apply(e,i)}return e}function Uve(n){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?arguments[t]:{};t%2?Kq(Object(e),!0).forEach(function(i){Hve(n,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):Kq(Object(e)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(e,i))})}return n}function Hve(n,t,e){return t in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}var Wve=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{longitude:OL.longitudeKeys,latitude:OL.latitudeKeys,altitude:OL.altitudeKeys},i=(0,AL.default)(t,e.longitude),r=(0,AL.default)(t,e.latitude),o=(0,AL.default)(t,e.altitude);return Uve({latitude:r,longitude:i},o?{altitude:o}:{})},Gve=Wve;LD.default=Gve});var LL=we(ND=>{"use strict";Object.defineProperty(ND,"__esModule",{value:!0});ND.default=void 0;var $ve=RL(j1()),qve=RL(z1()),Kve=RL(U1()),Zq=Da();function RL(n){return n&&n.__esModule?n:{default:n}}var Zve=function n(t){return(0,$ve.default)(t)?!(parseFloat(t)>Zq.MAXLAT||t<Zq.MINLAT):(0,qve.default)(t)?n((0,Kve.default)(t)):!1},Xve=Zve;ND.default=Xve});var NL=we(VD=>{"use strict";Object.defineProperty(VD,"__esModule",{value:!0});VD.default=void 0;var Yve=FL(j1()),Qve=FL(z1()),Jve=FL(U1()),Xq=Da();function FL(n){return n&&n.__esModule?n:{default:n}}var e1e=function n(t){return(0,Yve.default)(t)?!(parseFloat(t)>Xq.MAXLON||t<Xq.MINLON):(0,Qve.default)(t)?n((0,Jve.default)(t)):!1},t1e=e1e;VD.default=t1e});var BL=we(BD=>{"use strict";Object.defineProperty(BD,"__esModule",{value:!0});BD.default=void 0;var i1e=VL(FD()),Yq=VL(LL()),Qq=VL(NL());function VL(n){return n&&n.__esModule?n:{default:n}}var n1e=function(t){var e=(0,i1e.default)(t),i=e.latitude,r=e.longitude;if(Array.isArray(t)&&t.length>=2)return(0,Qq.default)(t[0])&&(0,Yq.default)(t[1]);if(typeof i>"u"||typeof r>"u")return!1;var o=t[r],a=t[i];return!(typeof a>"u"||typeof o>"u"||(0,Yq.default)(a)===!1||(0,Qq.default)(o)===!1)},r1e=n1e;BD.default=r1e});var zD=we(jD=>{"use strict";Object.defineProperty(jD,"__esModule",{value:!0});jD.default=void 0;var o1e=H1(j1()),a1e=H1(z1()),s1e=H1(U1()),Jq=H1(BL()),l1e=H1(FD());function H1(n){return n&&n.__esModule?n:{default:n}}function eK(n,t){var e=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(n,r).enumerable})),e.push.apply(e,i)}return e}function jL(n){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?arguments[t]:{};t%2?eK(Object(e),!0).forEach(function(i){zL(n,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):eK(Object(e)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(e,i))})}return n}function zL(n,t,e){return t in n?Object.defineProperty(n,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):n[t]=e,n}var c1e=function n(t){if((0,o1e.default)(t))return Number(t);if((0,a1e.default)(t))return(0,s1e.default)(t);if((0,Jq.default)(t)){var e=(0,l1e.default)(t);return Array.isArray(t)?t.map(function(i,r){return[0,1].includes(r)?n(i):i}):jL(jL(jL({},t),e.latitude&&zL({},e.latitude,n(t[e.latitude]))),e.longitude&&zL({},e.longitude,n(t[e.longitude])))}return Array.isArray(t)?t.map(function(i){return(0,Jq.default)(i)?n(i):i}):t},d1e=c1e;jD.default=d1e});var ac=we(UD=>{"use strict";Object.defineProperty(UD,"__esModule",{value:!0});UD.default=void 0;var u1e=Da(),p1e=tK(B1()),f1e=tK(zD());function tK(n){return n&&n.__esModule?n:{default:n}}var m1e=function(t,e){var i=(0,p1e.default)(t,u1e.latitudeKeys);if(!(typeof i>"u"||i===null)){var r=t[i];return e===!0?r:(0,f1e.default)(r)}},h1e=m1e;UD.default=h1e});var sc=we(HD=>{"use strict";Object.defineProperty(HD,"__esModule",{value:!0});HD.default=void 0;var g1e=Da(),_1e=iK(B1()),b1e=iK(zD());function iK(n){return n&&n.__esModule?n:{default:n}}var y1e=function(t,e){var i=(0,_1e.default)(t,g1e.longitudeKeys);if(!(typeof i>"u"||i===null)){var r=t[i];return e===!0?r:(0,b1e.default)(r)}},v1e=y1e;HD.default=v1e});var Hd=we(WD=>{"use strict";Object.defineProperty(WD,"__esModule",{value:!0});WD.default=void 0;var C1e=function(t){return t*Math.PI/180},x1e=C1e;WD.default=x1e});var Nh=we(GD=>{"use strict";Object.defineProperty(GD,"__esModule",{value:!0});GD.default=void 0;var w1e=function(t){return t*180/Math.PI},M1e=w1e;GD.default=M1e});var rK=we(qD=>{"use strict";Object.defineProperty(qD,"__esModule",{value:!0});qD.default=void 0;var S1e=$D(ac()),D1e=$D(sc()),UL=$D(Hd()),HL=$D(Nh()),nK=Da();function $D(n){return n&&n.__esModule?n:{default:n}}var E1e=function(t,e,i){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:6371e3,o=(0,S1e.default)(t),a=(0,D1e.default)(t),s=e/r,l=(0,UL.default)(i),c=(0,UL.default)(o),d=(0,UL.default)(a),f=Math.asin(Math.sin(c)*Math.cos(s)+Math.cos(c)*Math.sin(s)*Math.cos(l)),_=d+Math.atan2(Math.sin(l)*Math.sin(s)*Math.cos(c),Math.cos(s)-Math.sin(c)*Math.sin(f)),g=(0,HL.default)(_);return(g<nK.MINLON||g>nK.MAXLON)&&(_=(_+3*Math.PI)%(2*Math.PI)-Math.PI,g=(0,HL.default)(_)),{latitude:(0,HL.default)(f),longitude:g}},T1e=E1e;qD.default=T1e});var oK=we(KD=>{"use strict";Object.defineProperty(KD,"__esModule",{value:!0});KD.default=void 0;var I1e=Da(),k1e=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"m",i=I1e.areaConversion[e];if(i)return t*i;throw new Error("Invalid unit used for area conversion.")},P1e=k1e;KD.default=P1e});var aK=we(ZD=>{"use strict";Object.defineProperty(ZD,"__esModule",{value:!0});ZD.default=void 0;var O1e=Da(),A1e=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"m",i=O1e.distanceConversion[e];if(i)return t*i;throw new Error("Invalid unit used for distance conversion.")},R1e=A1e;ZD.default=R1e});var sK=we(YD=>{"use strict";Object.defineProperty(YD,"__esModule",{value:!0});YD.default=void 0;var XD=Da(),L1e=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"kmh";switch(e){case"kmh":return t*XD.timeConversion.h*XD.distanceConversion.km;case"mph":return t*XD.timeConversion.h*XD.distanceConversion.mi;default:return t}},F1e=L1e;YD.default=F1e});var dK=we(QD=>{"use strict";Object.defineProperty(QD,"__esModule",{value:!0});QD.default=void 0;function lK(n,t){return j1e(n)||B1e(n,t)||V1e(n,t)||N1e()}function N1e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function V1e(n,t){if(n){if(typeof n=="string")return cK(n,t);var e=Object.prototype.toString.call(n).slice(8,-1);if(e==="Object"&&n.constructor&&(e=n.constructor.name),e==="Map"||e==="Set")return Array.from(n);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return cK(n,t)}}function cK(n,t){(t==null||t>n.length)&&(t=n.length);for(var e=0,i=new Array(t);e<t;e++)i[e]=n[e];return i}function B1e(n,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(n)))){var e=[],i=!0,r=!1,o=void 0;try{for(var a=n[Symbol.iterator](),s;!(i=(s=a.next()).done)&&(e.push(s.value),!(t&&e.length===t));i=!0);}catch(l){r=!0,o=l}finally{try{!i&&a.return!=null&&a.return()}finally{if(r)throw o}}return e}}function j1e(n){if(Array.isArray(n))return n}var z1e=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:4,i=Math.pow(10,e);return Math.round(t*i)/i},U1e=function(t){var e=t.toString().split("."),i=lK(e,2),r=i[0],o=i[1],a=Math.abs(Number(r)),s=+("0."+(o||0))*60,l=s.toString().split("."),c=Math.floor(s),d=z1e(+("0."+(l[1]||0))*60).toString(),f=d.split("."),_=lK(f,2),g=_[0],b=_[1],w=b===void 0?"0":b;return a+"\xB0 "+c.toString().padStart(2,"0")+"' "+g.padStart(2,"0")+"."+w.padEnd(1,"0")+'"'},H1e=U1e;QD.default=H1e});var WL=we(JD=>{"use strict";Object.defineProperty(JD,"__esModule",{value:!0});JD.default=void 0;var W1e=function(t){return t>1?1:t<-1?-1:t},G1e=W1e;JD.default=G1e});var zf=we(tE=>{"use strict";Object.defineProperty(tE,"__esModule",{value:!0});tE.default=void 0;var uK=eE(ac()),pK=eE(sc()),u_=eE(Hd()),$1e=eE(WL()),q1e=Da();function eE(n){return n&&n.__esModule?n:{default:n}}var K1e=function(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;i=typeof i<"u"&&!isNaN(i)?i:1;var r=(0,uK.default)(t),o=(0,pK.default)(t),a=(0,uK.default)(e),s=(0,pK.default)(e),l=Math.acos((0,$1e.default)(Math.sin((0,u_.default)(a))*Math.sin((0,u_.default)(r))+Math.cos((0,u_.default)(a))*Math.cos((0,u_.default)(r))*Math.cos((0,u_.default)(o)-(0,u_.default)(s))))*q1e.earthRadius;return Math.round(l/i)*i},Z1e=K1e;tE.default=Z1e});var GL=we(iE=>{"use strict";Object.defineProperty(iE,"__esModule",{value:!0});iE.default=void 0;var fK=X1e(zf());function X1e(n){return n&&n.__esModule?n:{default:n}}var Y1e=function(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:fK.default;return i=typeof i=="function"?i:fK.default,e.slice().sort(function(r,o){return i(t,r)-i(t,o)})},Q1e=Y1e;iE.default=Q1e});var mK=we(nE=>{"use strict";Object.defineProperty(nE,"__esModule",{value:!0});nE.default=void 0;var J1e=eCe(GL());function eCe(n){return n&&n.__esModule?n:{default:n}}var tCe=function(t,e){return(0,J1e.default)(t,e)[0]},iCe=tCe;nE.default=iCe});var _K=we(rE=>{"use strict";Object.defineProperty(rE,"__esModule",{value:!0});rE.default=void 0;var $L=qL(Hd()),nCe=qL(ac()),hK=qL(sc()),gK=Da();function qL(n){return n&&n.__esModule?n:{default:n}}var rCe=function(t){var e=0;if(t.length>2){for(var i,r,o,a=0;a<t.length;a++){a===t.length-2?(i=t.length-2,r=t.length-1,o=0):a===t.length-1?(i=t.length-1,r=0,o=1):(i=a,r=a+1,o=a+2);var s=(0,hK.default)(t[i]),l=(0,nCe.default)(t[r]),c=(0,hK.default)(t[o]);e+=((0,$L.default)(c)-(0,$L.default)(s))*Math.sin((0,$L.default)(l))}e=e*gK.earthRadius*gK.earthRadius/2}return Math.abs(e)},oCe=rCe;rE.default=oCe});var KL=we(oE=>{"use strict";Object.defineProperty(oE,"__esModule",{value:!0});oE.default=void 0;var aCe=bK(ac()),sCe=bK(sc());function bK(n){return n&&n.__esModule?n:{default:n}}var lCe=function(t){if(Array.isArray(t)===!1||t.length===0)throw new Error("No points were given.");return t.reduce(function(e,i){var r=(0,aCe.default)(i),o=(0,sCe.default)(i);return{maxLat:Math.max(r,e.maxLat),minLat:Math.min(r,e.minLat),maxLng:Math.max(o,e.maxLng),minLng:Math.min(o,e.minLng)}},{maxLat:-1/0,minLat:1/0,maxLng:-1/0,minLng:1/0})},cCe=lCe;oE.default=cCe});var yK=we(lE=>{"use strict";Object.defineProperty(lE,"__esModule",{value:!0});lE.default=void 0;var dCe=sE(ac()),uCe=sE(sc()),p_=sE(Hd()),aE=sE(Nh()),W1=Da();function sE(n){return n&&n.__esModule?n:{default:n}}var pCe=function(t,e){var i=(0,dCe.default)(t),r=(0,uCe.default)(t),o=(0,p_.default)(i),a=(0,p_.default)(r),s=e/W1.earthRadius,l=o-s,c=o+s,d=(0,p_.default)(W1.MAXLAT),f=(0,p_.default)(W1.MINLAT),_=(0,p_.default)(W1.MAXLON),g=(0,p_.default)(W1.MINLON),b,w;if(l>f&&c<d){var D=Math.asin(Math.sin(s)/Math.cos(o));b=a-D,b<g&&(b+=Math.PI*2),w=a+D,w>_&&(w-=Math.PI*2)}else l=Math.max(l,f),c=Math.min(c,d),b=g,w=_;return[{latitude:(0,aE.default)(l),longitude:(0,aE.default)(b)},{latitude:(0,aE.default)(c),longitude:(0,aE.default)(w)}]},fCe=pCe;lE.default=fCe});var xK=we(dE=>{"use strict";Object.defineProperty(dE,"__esModule",{value:!0});dE.default=void 0;var mCe=cE(ac()),hCe=cE(sc()),vK=cE(Hd()),CK=cE(Nh());function cE(n){return n&&n.__esModule?n:{default:n}}var gCe=function(t){if(Array.isArray(t)===!1||t.length===0)return!1;var e=t.length,i=t.reduce(function(s,l){var c=(0,vK.default)((0,mCe.default)(l)),d=(0,vK.default)((0,hCe.default)(l));return{X:s.X+Math.cos(c)*Math.cos(d),Y:s.Y+Math.cos(c)*Math.sin(d),Z:s.Z+Math.sin(c)}},{X:0,Y:0,Z:0}),r=i.X/e,o=i.Y/e,a=i.Z/e;return{longitude:(0,CK.default)(Math.atan2(o,r)),latitude:(0,CK.default)(Math.atan2(a,Math.sqrt(r*r+o*o)))}},_Ce=gCe;dE.default=_Ce});var wK=we(uE=>{"use strict";Object.defineProperty(uE,"__esModule",{value:!0});uE.default=void 0;var bCe=yCe(KL());function yCe(n){return n&&n.__esModule?n:{default:n}}var vCe=function(t){var e=(0,bCe.default)(t),i=e.minLat+(e.maxLat-e.minLat)/2,r=e.minLng+(e.maxLng-e.minLng)/2;return{latitude:parseFloat(i.toFixed(6)),longitude:parseFloat(r.toFixed(6))}},CCe=vCe;uE.default=CCe});var ZL=we(mE=>{"use strict";Object.defineProperty(mE,"__esModule",{value:!0});mE.default=void 0;var MK=fE(ac()),SK=fE(sc()),pE=fE(Hd()),xCe=fE(Nh());function fE(n){return n&&n.__esModule?n:{default:n}}var wCe=function(t,e){var i=(0,pE.default)((0,SK.default)(e))-(0,pE.default)((0,SK.default)(t)),r=Math.log(Math.tan((0,pE.default)((0,MK.default)(e))/2+Math.PI/4)/Math.tan((0,pE.default)((0,MK.default)(t))/2+Math.PI/4));return Math.abs(i)>Math.PI&&(i>0?i=(Math.PI*2-i)*-1:i=Math.PI*2+i),((0,xCe.default)(Math.atan2(i,r))+360)%360},MCe=wCe;mE.default=MCe});var EK=we(hE=>{"use strict";Object.defineProperty(hE,"__esModule",{value:!0});hE.default=void 0;var DK=SCe(ZL());function SCe(n){return n&&n.__esModule?n:{default:n}}var DCe=function(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:DK.default,r=typeof i=="function"?i(t,e):(0,DK.default)(t,e);if(isNaN(r))throw new Error("Could not calculate bearing for given points. Check your bearing function");switch(Math.round(r/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"}},ECe=DCe;hE.default=ECe});var YL=we(gE=>{"use strict";Object.defineProperty(gE,"__esModule",{value:!0});gE.default=void 0;var XL=IK(zf()),TK=IK(WL());function IK(n){return n&&n.__esModule?n:{default:n}}var TCe=function(t,e,i){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,o=(0,XL.default)(e,t,r),a=(0,XL.default)(t,i,r),s=(0,XL.default)(e,i,r),l=Math.acos((0,TK.default)((o*o+s*s-a*a)/(2*o*s))),c=Math.acos((0,TK.default)((a*a+s*s-o*o)/(2*a*s)));return l>Math.PI/2?o:c>Math.PI/2?a:Math.sin(l)*o},ICe=TCe;gE.default=ICe});var OK=we(bE=>{"use strict";Object.defineProperty(bE,"__esModule",{value:!0});bE.default=void 0;var kK=_E(ac()),PK=_E(sc()),rp=_E(Hd()),kCe=_E(Nh());function _E(n){return n&&n.__esModule?n:{default:n}}var PCe=function(t,e){var i=(0,kK.default)(e),r=(0,PK.default)(e),o=(0,kK.default)(t),a=(0,PK.default)(t),s=((0,kCe.default)(Math.atan2(Math.sin((0,rp.default)(r)-(0,rp.default)(a))*Math.cos((0,rp.default)(i)),Math.cos((0,rp.default)(o))*Math.sin((0,rp.default)(i))-Math.sin((0,rp.default)(o))*Math.cos((0,rp.default)(i))*Math.cos((0,rp.default)(r)-(0,rp.default)(a))))+360)%360;return s},OCe=PCe;bE.default=OCe});var AK=we(vE=>{"use strict";Object.defineProperty(vE,"__esModule",{value:!0});vE.default=void 0;var ACe=RCe(zf());function RCe(n){return n&&n.__esModule?n:{default:n}}function yE(n){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?yE=function(e){return typeof e}:yE=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yE(n)}var LCe=function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ACe.default;return t.reduce(function(i,r){return yE(i)==="object"&&i.last!==null&&(i.distance+=e(r,i.last)),i.last=r,i},{last:null,distance:0}).distance},FCe=LCe;vE.default=FCe});var NK=we(CE=>{"use strict";Object.defineProperty(CE,"__esModule",{value:!0});CE.default=void 0;var RK=JL(ac()),LK=JL(sc()),QL=JL(Hd()),FK=Da();function JL(n){return n&&n.__esModule?n:{default:n}}var NCe=function(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;i=typeof i<"u"&&!isNaN(i)?i:1;var r=(0,RK.default)(t),o=(0,LK.default)(t),a=(0,RK.default)(e),s=(0,LK.default)(e),l=6356752314245e-6,c=1/298.257223563,d=(0,QL.default)(s-o),f,_,g,b,w,D,I=Math.atan((1-c)*Math.tan((0,QL.default)(parseFloat(r)))),P=Math.atan((1-c)*Math.tan((0,QL.default)(parseFloat(a)))),k=Math.sin(I),T=Math.cos(I),E=Math.sin(P),F=Math.cos(P),H=d,O,$=100;do{var U=Math.sin(H),q=Math.cos(H);if(D=Math.sqrt(F*U*(F*U)+(T*E-k*F*q)*(T*E-k*F*q)),D===0)return 0;f=k*E+T*F*q,_=Math.atan2(D,f),g=T*F*U/D,b=1-g*g,w=f-2*k*E/b,isNaN(w)&&(w=0);var X=c/16*b*(4+c*(4-3*b));O=H,H=d+(1-X)*c*g*(_+X*D*(w+X*f*(-1+2*w*w)))}while(Math.abs(H-O)>1e-12&&--$>0);if($===0)return NaN;var J=b*(FK.earthRadius*FK.earthRadius-l*l)/(l*l),re=1+J/16384*(4096+J*(-768+J*(320-175*J))),ae=J/1024*(256+J*(-128+J*(74-47*J))),se=ae*D*(w+ae/4*(f*(-1+2*w*w)-ae/6*w*(-3+4*D*D)*(-3+4*w*w))),Be=l*re*(_-se);return Math.round(Be/i)*i},VCe=NCe;CE.default=VCe});var VK=we(xE=>{"use strict";Object.defineProperty(xE,"__esModule",{value:!0});xE.default=void 0;var BCe=function(t){if(/^(NNE|NE|NNW|N)$/.test(t))return"N";if(/^(ENE|E|ESE|SE)$/.test(t))return"E";if(/^(SSE|S|SSW|SW)$/.test(t))return"S";if(/^(WSW|W|WNW|NW)$/.test(t))return"W"},jCe=BCe;xE.default=jCe});var BK=we(wE=>{"use strict";Object.defineProperty(wE,"__esModule",{value:!0});wE.default=void 0;var zCe=UCe(zf());function UCe(n){return n&&n.__esModule?n:{default:n}}var HCe=function(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zCe.default,r=i(t,e),o=Number(e.time)-Number(t.time),a=r/o*1e3;return a},WCe=HCe;wE.default=WCe});var jK=we(ME=>{"use strict";Object.defineProperty(ME,"__esModule",{value:!0});ME.default=void 0;var eF=GCe(zf());function GCe(n){return n&&n.__esModule?n:{default:n}}var $Ce=function(t,e,i){return(0,eF.default)(e,t)+(0,eF.default)(t,i)===(0,eF.default)(e,i)},qCe=$Ce;ME.default=qCe});var UK=we(DE=>{"use strict";Object.defineProperty(DE,"__esModule",{value:!0});DE.default=void 0;var SE=zK(ac()),lc=zK(sc());function zK(n){return n&&n.__esModule?n:{default:n}}var KCe=function(t,e){for(var i=!1,r=e.length,o=-1,a=r-1;++o<r;a=o)((0,lc.default)(e[o])<=(0,lc.default)(t)&&(0,lc.default)(t)<(0,lc.default)(e[a])||(0,lc.default)(e[a])<=(0,lc.default)(t)&&(0,lc.default)(t)<(0,lc.default)(e[o]))&&(0,SE.default)(t)<((0,SE.default)(e[a])-(0,SE.default)(e[o]))*((0,lc.default)(t)-(0,lc.default)(e[o]))/((0,lc.default)(e[a])-(0,lc.default)(e[o]))+(0,SE.default)(e[o])&&(i=!i);return i},ZCe=KCe;DE.default=ZCe});var HK=we(EE=>{"use strict";Object.defineProperty(EE,"__esModule",{value:!0});EE.default=void 0;var XCe=YCe(YL());function YCe(n){return n&&n.__esModule?n:{default:n}}var QCe=function(t,e,i,r){return(0,XCe.default)(t,e,i)<r},JCe=QCe;EE.default=JCe});var WK=we(TE=>{"use strict";Object.defineProperty(TE,"__esModule",{value:!0});TE.default=void 0;var exe=txe(zf());function txe(n){return n&&n.__esModule?n:{default:n}}var ixe=function(t,e,i){var r=.01;return(0,exe.default)(t,e,r)<i},nxe=ixe;TE.default=nxe});var $K=we(IE=>{"use strict";Object.defineProperty(IE,"__esModule",{value:!0});IE.default=void 0;function rxe(n,t){return lxe(n)||sxe(n,t)||axe(n,t)||oxe()}function oxe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function axe(n,t){if(n){if(typeof n=="string")return GK(n,t);var e=Object.prototype.toString.call(n).slice(8,-1);if(e==="Object"&&n.constructor&&(e=n.constructor.name),e==="Map"||e==="Set")return Array.from(n);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return GK(n,t)}}function GK(n,t){(t==null||t>n.length)&&(t=n.length);for(var e=0,i=new Array(t);e<t;e++)i[e]=n[e];return i}function sxe(n,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(n)))){var e=[],i=!0,r=!1,o=void 0;try{for(var a=n[Symbol.iterator](),s;!(i=(s=a.next()).done)&&(e.push(s.value),!(t&&e.length===t));i=!0);}catch(l){r=!0,o=l}finally{try{!i&&a.return!=null&&a.return()}finally{if(r)throw o}}return e}}function lxe(n){if(Array.isArray(n))return n}var cxe=function(t){if(!t.startsWith("POLYGON"))throw new Error("Invalid wkt.");var e=t.slice(t.indexOf("(")+2,t.indexOf(")")).split(", "),i=e.map(function(r){var o=r.split(" "),a=rxe(o,2),s=a[0],l=a[1];return{longitude:parseFloat(s),latitude:parseFloat(l)}});return i},dxe=cxe;IE.default=dxe});var Wd=we(Vi=>{"use strict";Object.defineProperty(Vi,"__esModule",{value:!0});var uxe={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(Vi,"computeDestinationPoint",{enumerable:!0,get:function(){return pxe.default}});Object.defineProperty(Vi,"convertArea",{enumerable:!0,get:function(){return fxe.default}});Object.defineProperty(Vi,"convertDistance",{enumerable:!0,get:function(){return mxe.default}});Object.defineProperty(Vi,"convertSpeed",{enumerable:!0,get:function(){return hxe.default}});Object.defineProperty(Vi,"decimalToSexagesimal",{enumerable:!0,get:function(){return gxe.default}});Object.defineProperty(Vi,"findNearest",{enumerable:!0,get:function(){return _xe.default}});Object.defineProperty(Vi,"getAreaOfPolygon",{enumerable:!0,get:function(){return bxe.default}});Object.defineProperty(Vi,"getBounds",{enumerable:!0,get:function(){return yxe.default}});Object.defineProperty(Vi,"getBoundsOfDistance",{enumerable:!0,get:function(){return vxe.default}});Object.defineProperty(Vi,"getCenter",{enumerable:!0,get:function(){return Cxe.default}});Object.defineProperty(Vi,"getCenterOfBounds",{enumerable:!0,get:function(){return xxe.default}});Object.defineProperty(Vi,"getCompassDirection",{enumerable:!0,get:function(){return wxe.default}});Object.defineProperty(Vi,"getCoordinateKey",{enumerable:!0,get:function(){return Mxe.default}});Object.defineProperty(Vi,"getCoordinateKeys",{enumerable:!0,get:function(){return Sxe.default}});Object.defineProperty(Vi,"getDistance",{enumerable:!0,get:function(){return Dxe.default}});Object.defineProperty(Vi,"getDistanceFromLine",{enumerable:!0,get:function(){return Exe.default}});Object.defineProperty(Vi,"getGreatCircleBearing",{enumerable:!0,get:function(){return Txe.default}});Object.defineProperty(Vi,"getLatitude",{enumerable:!0,get:function(){return Ixe.default}});Object.defineProperty(Vi,"getLongitude",{enumerable:!0,get:function(){return kxe.default}});Object.defineProperty(Vi,"getPathLength",{enumerable:!0,get:function(){return Pxe.default}});Object.defineProperty(Vi,"getPreciseDistance",{enumerable:!0,get:function(){return Oxe.default}});Object.defineProperty(Vi,"getRhumbLineBearing",{enumerable:!0,get:function(){return Axe.default}});Object.defineProperty(Vi,"getRoughCompassDirection",{enumerable:!0,get:function(){return Rxe.default}});Object.defineProperty(Vi,"getSpeed",{enumerable:!0,get:function(){return Lxe.default}});Object.defineProperty(Vi,"isDecimal",{enumerable:!0,get:function(){return Fxe.default}});Object.defineProperty(Vi,"isPointInLine",{enumerable:!0,get:function(){return Nxe.default}});Object.defineProperty(Vi,"isPointInPolygon",{enumerable:!0,get:function(){return Vxe.default}});Object.defineProperty(Vi,"isPointNearLine",{enumerable:!0,get:function(){return Bxe.default}});Object.defineProperty(Vi,"isPointWithinRadius",{enumerable:!0,get:function(){return jxe.default}});Object.defineProperty(Vi,"isSexagesimal",{enumerable:!0,get:function(){return zxe.default}});Object.defineProperty(Vi,"isValidCoordinate",{enumerable:!0,get:function(){return Uxe.default}});Object.defineProperty(Vi,"isValidLatitude",{enumerable:!0,get:function(){return Hxe.default}});Object.defineProperty(Vi,"isValidLongitude",{enumerable:!0,get:function(){return Wxe.default}});Object.defineProperty(Vi,"orderByDistance",{enumerable:!0,get:function(){return Gxe.default}});Object.defineProperty(Vi,"sexagesimalToDecimal",{enumerable:!0,get:function(){return $xe.default}});Object.defineProperty(Vi,"toDecimal",{enumerable:!0,get:function(){return qxe.default}});Object.defineProperty(Vi,"toRad",{enumerable:!0,get:function(){return Kxe.default}});Object.defineProperty(Vi,"toDeg",{enumerable:!0,get:function(){return Zxe.default}});Object.defineProperty(Vi,"wktToPolygon",{enumerable:!0,get:function(){return Xxe.default}});var pxe=Zi(rK()),fxe=Zi(oK()),mxe=Zi(aK()),hxe=Zi(sK()),gxe=Zi(dK()),_xe=Zi(mK()),bxe=Zi(_K()),yxe=Zi(KL()),vxe=Zi(yK()),Cxe=Zi(xK()),xxe=Zi(wK()),wxe=Zi(EK()),Mxe=Zi(B1()),Sxe=Zi(FD()),Dxe=Zi(zf()),Exe=Zi(YL()),Txe=Zi(OK()),Ixe=Zi(ac()),kxe=Zi(sc()),Pxe=Zi(AK()),Oxe=Zi(NK()),Axe=Zi(ZL()),Rxe=Zi(VK()),Lxe=Zi(BK()),Fxe=Zi(j1()),Nxe=Zi(jK()),Vxe=Zi(UK()),Bxe=Zi(HK()),jxe=Zi(WK()),zxe=Zi(z1()),Uxe=Zi(BL()),Hxe=Zi(LL()),Wxe=Zi(NL()),Gxe=Zi(GL()),$xe=Zi(U1()),qxe=Zi(zD()),Kxe=Zi(Hd()),Zxe=Zi(Nh()),Xxe=Zi($K()),qK=Da();Object.keys(qK).forEach(function(n){n==="default"||n==="__esModule"||Object.prototype.hasOwnProperty.call(uxe,n)||Object.defineProperty(Vi,n,{enumerable:!0,get:function(){return qK[n]}})});function Zi(n){return n&&n.__esModule?n:{default:n}}});var MZ=we((Xxt,wZ)=>{var hF="0123456789bcdefghjkmnpqrstuvwxyz",yZ={};for(Z1=0;Z1<hF.length;Z1++)yZ[hF.charAt(Z1)]=Z1;var Z1,vZ="auto",h_=-90,g_=90,__=-180,Uf=180,hwe=[0,5,7,8,11,12,13,15,16,17,18],X1=function(n,t,e){if(e===vZ){if(typeof n=="number"||typeof t=="number")throw new Error("string notation required for auto precision.");var i=n.split(".")[1].length,r=t.split(".")[1].length,o=Math.max(i,r);e=hwe[o]}else e===void 0&&(e=9);for(var a=[],s=0,l=0,c=0,d=g_,f=h_,_=Uf,g=__,b;a.length<e;)if(l%2===0?(b=(_+g)/2,t>b?(c=(c<<1)+1,g=b):(c=(c<<1)+0,_=b)):(b=(d+f)/2,n>b?(c=(c<<1)+1,f=b):(c=(c<<1)+0,d=b)),s++,l++,s===5){var w=hF[c];a.push(w),s=0,c=0}return a.join("")},b_=function(n,t,e){e=e||52;for(var i=0,r=g_,o=h_,a=Uf,s=__,l,c=0;i<e;)c*=2,i%2===0?(l=(a+s)/2,t>l?(c+=1,s=l):a=l):(l=(r+o)/2,n>l?(c+=1,o=l):r=l),i++;return c},FE=function(n){for(var t=!0,e=g_,i=h_,r=Uf,o=__,a,s=0,l=0,c=n.length;l<c;l++){var d=n[l].toLowerCase();s=yZ[d];for(var f=4;f>=0;f--){var _=s>>f&1;t?(a=(r+o)/2,_===1?o=a:r=a):(a=(e+i)/2,_===1?i=a:e=a),t=!t}}return[i,o,e,r]},Y1=function(n,t){t=t||52;for(var e=g_,i=h_,r=Uf,o=__,a=0,s=0,l=t/2,c=0;c<l;c++)s=bZ(n,(l-c)*2-1),a=bZ(n,(l-c)*2-2),a===0?e=(e+i)/2:i=(e+i)/2,s===0?r=(r+o)/2:o=(r+o)/2;return[i,o,e,r]};function bZ(n,t){return n/Math.pow(2,t)&1}var NE=function(n){var t=FE(n),e=(t[0]+t[2])/2,i=(t[1]+t[3])/2,r=t[2]-e,o=t[3]-i;return{latitude:e,longitude:i,error:{latitude:r,longitude:o}}},Q1=function(n,t){var e=Y1(n,t),i=(e[0]+e[2])/2,r=(e[1]+e[3])/2,o=e[2]-i,a=e[3]-r;return{latitude:i,longitude:r,error:{latitude:o,longitude:a}}},CZ=function(n,t){var e=NE(n),i=e.latitude+t[0]*e.error.latitude*2,r=e.longitude+t[1]*e.error.longitude*2;return r=VE(r),i=BE(i),X1(i,r,n.length)},xZ=function(n,t,e){e=e||52;var i=Q1(n,e),r=i.latitude+t[0]*i.error.latitude*2,o=i.longitude+t[1]*i.error.longitude*2;return o=VE(o),r=BE(r),b_(r,o,e)},gwe=function(n){var t=n.length,e=NE(n),i=e.latitude,r=e.longitude,o=e.error.latitude*2,a=e.error.longitude*2,s,l,c=[d(1,0),d(1,1),d(0,1),d(-1,1),d(-1,0),d(-1,-1),d(0,-1),d(1,-1)];function d(f,_){return s=i+f*o,l=r+_*a,l=VE(l),s=BE(s),X1(s,l,t)}return c},_we=function(n,t){t=t||52;var e=Q1(n,t),i=e.latitude,r=e.longitude,o=e.error.latitude*2,a=e.error.longitude*2,s,l,c=[d(1,0),d(1,1),d(0,1),d(-1,1),d(-1,0),d(-1,-1),d(0,-1),d(1,-1)];function d(f,_){return s=i+f*o,l=r+_*a,l=VE(l),s=BE(s),b_(s,l,t)}return c},bwe=function(n,t,e,i,r){r=r||9;for(var o=X1(n,t,r),a=X1(e,i,r),s=NE(o),l=s.error.latitude*2,c=s.error.longitude*2,d=FE(o),f=FE(a),_=Math.round((f[0]-d[0])/l),g=Math.round((f[1]-d[1])/c),b=[],w=0;w<=_;w++)for(var D=0;D<=g;D++)b.push(CZ(o,[w,D]));return b},ywe=function(n,t,e,i,r){r=r||52;for(var o=b_(n,t,r),a=b_(e,i,r),s=Q1(o,r),l=s.error.latitude*2,c=s.error.longitude*2,d=Y1(o,r),f=Y1(a,r),_=Math.round((f[0]-d[0])/l),g=Math.round((f[1]-d[1])/c),b=[],w=0;w<=_;w++)for(var D=0;D<=g;D++)b.push(xZ(o,[w,D],r));return b};function VE(n){return n>Uf?__+n%Uf:n<__?Uf+n%Uf:n}function BE(n){return n>g_?g_:n<h_?h_:n}var vwe={ENCODE_AUTO:vZ,encode:X1,encode_uint64:b_,encode_int:b_,decode:NE,decode_int:Q1,decode_uint64:Q1,decode_bbox:FE,decode_bbox_uint64:Y1,decode_bbox_int:Y1,neighbor:CZ,neighbor_int:xZ,neighbors:gwe,neighbors_int:_we,bboxes:bwe,bboxes_int:ywe};wZ.exports=vwe});var dP=we(sV=>{(function(){sV.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline:`
`},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(sV)});var Cu=we((bne,km)=>{(function(){var n,t,e,i,r,o,a,s=[].slice,l={}.hasOwnProperty;n=function(){var c,d,f,_,g,b;if(b=arguments[0],g=2<=arguments.length?s.call(arguments,1):[],r(Object.assign))Object.assign.apply(null,arguments);else for(c=0,f=g.length;c<f;c++)if(_=g[c],_!=null)for(d in _)l.call(_,d)&&(b[d]=_[d]);return b},r=function(c){return!!c&&Object.prototype.toString.call(c)==="[object Function]"},o=function(c){var d;return!!c&&((d=typeof c)=="function"||d==="object")},e=function(c){return r(Array.isArray)?Array.isArray(c):Object.prototype.toString.call(c)==="[object Array]"},i=function(c){var d;if(e(c))return!c.length;for(d in c)if(l.call(c,d))return!1;return!0},a=function(c){var d,f;return o(c)&&(f=Object.getPrototypeOf(c))&&(d=f.constructor)&&typeof d=="function"&&d instanceof d&&Function.prototype.toString.call(d)===Function.prototype.toString.call(Object)},t=function(c){return r(c.valueOf)?c.valueOf():c},km.exports.assign=n,km.exports.isFunction=r,km.exports.isObject=o,km.exports.isArray=e,km.exports.isEmpty=i,km.exports.isPlainObject=a,km.exports.getValue=t}).call(bne)});var lV=we((yne,vne)=>{(function(){var n;vne.exports=n=(function(){function t(){}return t.prototype.hasFeature=function(e,i){return!0},t.prototype.createDocumentType=function(e,i,r){throw new Error("This DOM method is not implemented.")},t.prototype.createDocument=function(e,i,r){throw new Error("This DOM method is not implemented.")},t.prototype.createHTMLDocument=function(e){throw new Error("This DOM method is not implemented.")},t.prototype.getFeature=function(e,i){throw new Error("This DOM method is not implemented.")},t})()}).call(yne)});var wne=we((Cne,xne)=>{(function(){var n;xne.exports=n=(function(){function t(){}return t.prototype.handleError=function(e){throw new Error(e)},t})()}).call(Cne)});var Dne=we((Mne,Sne)=>{(function(){var n;Sne.exports=n=(function(){function t(e){this.arr=e||[]}return Object.defineProperty(t.prototype,"length",{get:function(){return this.arr.length}}),t.prototype.item=function(e){return this.arr[e]||null},t.prototype.contains=function(e){return this.arr.indexOf(e)!==-1},t})()}).call(Mne)});var Ine=we((Ene,Tne)=>{(function(){var n,t,e;t=wne(),e=Dne(),Tne.exports=n=(function(){function i(){var r;this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new t,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=r=Object.create(this.defaultParams)}return Object.defineProperty(i.prototype,"parameterNames",{get:function(){return new e(Object.keys(this.defaultParams))}}),i.prototype.getParameter=function(r){return this.params.hasOwnProperty(r)?this.params[r]:null},i.prototype.canSetParameter=function(r,o){return!0},i.prototype.setParameter=function(r,o){return o!=null?this.params[r]=o:delete this.params[r]},i})()}).call(Ene)});var To=we((kne,Pne)=>{(function(){Pne.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(kne)});var cV=we((One,Ane)=>{(function(){var n,t,e;n=To(),e=Ul(),Ane.exports=t=(function(){function i(r,o,a){if(this.parent=r,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),o==null)throw new Error("Missing attribute name. "+this.debugInfo(o));this.name=this.stringify.name(o),this.value=this.stringify.attValue(a),this.type=n.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(i.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(i.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(i.prototype,"textContent",{get:function(){return this.value},set:function(r){return this.value=r||""}}),Object.defineProperty(i.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(i.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(i.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(i.prototype,"specified",{get:function(){return!0}}),i.prototype.clone=function(){return Object.create(this)},i.prototype.toString=function(r){return this.options.writer.attribute(this,this.options.writer.filterOptions(r))},i.prototype.debugInfo=function(r){return r=r||this.name,r==null?"parent: <"+this.parent.name+">":"attribute: {"+r+"}, parent: <"+this.parent.name+">"},i.prototype.isEqualNode=function(r){return!(r.namespaceURI!==this.namespaceURI||r.prefix!==this.prefix||r.localName!==this.localName||r.value!==this.value)},i})()}).call(One)});var uP=we((Rne,Lne)=>{(function(){var n;Lne.exports=n=(function(){function t(e){this.nodes=e}return Object.defineProperty(t.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),t.prototype.clone=function(){return this.nodes=null},t.prototype.getNamedItem=function(e){return this.nodes[e]},t.prototype.setNamedItem=function(e){var i;return i=this.nodes[e.nodeName],this.nodes[e.nodeName]=e,i||null},t.prototype.removeNamedItem=function(e){var i;return i=this.nodes[e],delete this.nodes[e],i||null},t.prototype.item=function(e){return this.nodes[Object.keys(this.nodes)[e]]||null},t.prototype.getNamedItemNS=function(e,i){throw new Error("This DOM method is not implemented.")},t.prototype.setNamedItemNS=function(e){throw new Error("This DOM method is not implemented.")},t.prototype.removeNamedItemNS=function(e,i){throw new Error("This DOM method is not implemented.")},t})()}).call(Rne)});var pP=we((Fne,Nne)=>{(function(){var n,t,e,i,r,o,a,s,l,c=function(f,_){for(var g in _)d.call(_,g)&&(f[g]=_[g]);function b(){this.constructor=f}return b.prototype=_.prototype,f.prototype=new b,f.__super__=_.prototype,f},d={}.hasOwnProperty;l=Cu(),s=l.isObject,a=l.isFunction,o=l.getValue,r=Ul(),n=To(),t=cV(),i=uP(),Nne.exports=e=(function(f){c(_,f);function _(g,b,w){var D,I,P,k;if(_.__super__.constructor.call(this,g),b==null)throw new Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(b),this.type=n.Element,this.attribs={},this.schemaTypeInfo=null,w!=null&&this.attribute(w),g.type===n.Document&&(this.isRoot=!0,this.documentObject=g,g.rootObject=this,g.children)){for(k=g.children,I=0,P=k.length;I<P;I++)if(D=k[I],D.type===n.DocType){D.name=this.name;break}}}return Object.defineProperty(_.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(_.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(_.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(_.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(_.prototype,"id",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(_.prototype,"className",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(_.prototype,"classList",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(_.prototype,"attributes",{get:function(){return(!this.attributeMap||!this.attributeMap.nodes)&&(this.attributeMap=new i(this.attribs)),this.attributeMap}}),_.prototype.clone=function(){var g,b,w,D;w=Object.create(this),w.isRoot&&(w.documentObject=null),w.attribs={},D=this.attribs;for(b in D)d.call(D,b)&&(g=D[b],w.attribs[b]=g.clone());return w.children=[],this.children.forEach(function(I){var P;return P=I.clone(),P.parent=w,w.children.push(P)}),w},_.prototype.attribute=function(g,b){var w,D;if(g!=null&&(g=o(g)),s(g))for(w in g)d.call(g,w)&&(D=g[w],this.attribute(w,D));else a(b)&&(b=b.apply()),this.options.keepNullAttributes&&b==null?this.attribs[g]=new t(this,g,""):b!=null&&(this.attribs[g]=new t(this,g,b));return this},_.prototype.removeAttribute=function(g){var b,w,D;if(g==null)throw new Error("Missing attribute name. "+this.debugInfo());if(g=o(g),Array.isArray(g))for(w=0,D=g.length;w<D;w++)b=g[w],delete this.attribs[b];else delete this.attribs[g];return this},_.prototype.toString=function(g){return this.options.writer.element(this,this.options.writer.filterOptions(g))},_.prototype.att=function(g,b){return this.attribute(g,b)},_.prototype.a=function(g,b){return this.attribute(g,b)},_.prototype.getAttribute=function(g){return this.attribs.hasOwnProperty(g)?this.attribs[g].value:null},_.prototype.setAttribute=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getAttributeNode=function(g){return this.attribs.hasOwnProperty(g)?this.attribs[g]:null},_.prototype.setAttributeNode=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.removeAttributeNode=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getElementsByTagName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getAttributeNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.setAttributeNS=function(g,b,w){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.removeAttributeNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getAttributeNodeNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.setAttributeNodeNS=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getElementsByTagNameNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.hasAttribute=function(g){return this.attribs.hasOwnProperty(g)},_.prototype.hasAttributeNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.setIdAttribute=function(g,b){return this.attribs.hasOwnProperty(g)?this.attribs[g].isId:b},_.prototype.setIdAttributeNS=function(g,b,w){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.setIdAttributeNode=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getElementsByTagName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getElementsByTagNameNS=function(g,b){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.getElementsByClassName=function(g){throw new Error("This DOM method is not implemented."+this.debugInfo())},_.prototype.isEqualNode=function(g){var b,w,D;if(!_.__super__.isEqualNode.apply(this,arguments).isEqualNode(g)||g.namespaceURI!==this.namespaceURI||g.prefix!==this.prefix||g.localName!==this.localName||g.attribs.length!==this.attribs.length)return!1;for(b=w=0,D=this.attribs.length-1;0<=D?w<=D:w>=D;b=0<=D?++w:--w)if(!this.attribs[b].isEqualNode(g.attribs[b]))return!1;return!0},_})(r)}).call(Fne)});var hw=we((Vne,Bne)=>{(function(){var n,t,e=function(r,o){for(var a in o)i.call(o,a)&&(r[a]=o[a]);function s(){this.constructor=r}return s.prototype=o.prototype,r.prototype=new s,r.__super__=o.prototype,r},i={}.hasOwnProperty;t=Ul(),Bne.exports=n=(function(r){e(o,r);function o(a){o.__super__.constructor.call(this,a),this.value=""}return Object.defineProperty(o.prototype,"data",{get:function(){return this.value},set:function(a){return this.value=a||""}}),Object.defineProperty(o.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(o.prototype,"textContent",{get:function(){return this.value},set:function(a){return this.value=a||""}}),o.prototype.clone=function(){return Object.create(this)},o.prototype.substringData=function(a,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.appendData=function(a){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.insertData=function(a,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.deleteData=function(a,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.replaceData=function(a,s,l){throw new Error("This DOM method is not implemented."+this.debugInfo())},o.prototype.isEqualNode=function(a){return!(!o.__super__.isEqualNode.apply(this,arguments).isEqualNode(a)||a.data!==this.data)},o})(t)}).call(Vne)});var fP=we((jne,zne)=>{(function(){var n,t,e,i=function(o,a){for(var s in a)r.call(a,s)&&(o[s]=a[s]);function l(){this.constructor=o}return l.prototype=a.prototype,o.prototype=new l,o.__super__=a.prototype,o},r={}.hasOwnProperty;n=To(),e=hw(),zne.exports=t=(function(o){i(a,o);function a(s,l){if(a.__super__.constructor.call(this,s),l==null)throw new Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=n.CData,this.value=this.stringify.cdata(l)}return a.prototype.clone=function(){return Object.create(this)},a.prototype.toString=function(s){return this.options.writer.cdata(this,this.options.writer.filterOptions(s))},a})(e)}).call(jne)});var mP=we((Une,Hne)=>{(function(){var n,t,e,i=function(o,a){for(var s in a)r.call(a,s)&&(o[s]=a[s]);function l(){this.constructor=o}return l.prototype=a.prototype,o.prototype=new l,o.__super__=a.prototype,o},r={}.hasOwnProperty;n=To(),t=hw(),Hne.exports=e=(function(o){i(a,o);function a(s,l){if(a.__super__.constructor.call(this,s),l==null)throw new Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=n.Comment,this.value=this.stringify.comment(l)}return a.prototype.clone=function(){return Object.create(this)},a.prototype.toString=function(s){return this.options.writer.comment(this,this.options.writer.filterOptions(s))},a})(t)}).call(Une)});var hP=we((Wne,Gne)=>{(function(){var n,t,e,i,r=function(a,s){for(var l in s)o.call(s,l)&&(a[l]=s[l]);function c(){this.constructor=a}return c.prototype=s.prototype,a.prototype=new c,a.__super__=s.prototype,a},o={}.hasOwnProperty;i=Cu().isObject,e=Ul(),n=To(),Gne.exports=t=(function(a){r(s,a);function s(l,c,d,f){var _;s.__super__.constructor.call(this,l),i(c)&&(_=c,c=_.version,d=_.encoding,f=_.standalone),c||(c="1.0"),this.type=n.Declaration,this.version=this.stringify.xmlVersion(c),d!=null&&(this.encoding=this.stringify.xmlEncoding(d)),f!=null&&(this.standalone=this.stringify.xmlStandalone(f))}return s.prototype.toString=function(l){return this.options.writer.declaration(this,this.options.writer.filterOptions(l))},s})(e)}).call(Wne)});var gP=we(($ne,qne)=>{(function(){var n,t,e,i=function(o,a){for(var s in a)r.call(a,s)&&(o[s]=a[s]);function l(){this.constructor=o}return l.prototype=a.prototype,o.prototype=new l,o.__super__=a.prototype,o},r={}.hasOwnProperty;e=Ul(),n=To(),qne.exports=t=(function(o){i(a,o);function a(s,l,c,d,f,_){if(a.__super__.constructor.call(this,s),l==null)throw new Error("Missing DTD element name. "+this.debugInfo());if(c==null)throw new Error("Missing DTD attribute name. "+this.debugInfo(l));if(!d)throw new Error("Missing DTD attribute type. "+this.debugInfo(l));if(!f)throw new Error("Missing DTD attribute default. "+this.debugInfo(l));if(f.indexOf("#")!==0&&(f="#"+f),!f.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(l));if(_&&!f.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(l));this.elementName=this.stringify.name(l),this.type=n.AttributeDeclaration,this.attributeName=this.stringify.name(c),this.attributeType=this.stringify.dtdAttType(d),_&&(this.defaultValue=this.stringify.dtdAttDefault(_)),this.defaultValueType=f}return a.prototype.toString=function(s){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(s))},a})(e)}).call($ne)});var _P=we((Kne,Zne)=>{(function(){var n,t,e,i,r=function(a,s){for(var l in s)o.call(s,l)&&(a[l]=s[l]);function c(){this.constructor=a}return c.prototype=s.prototype,a.prototype=new c,a.__super__=s.prototype,a},o={}.hasOwnProperty;i=Cu().isObject,e=Ul(),n=To(),Zne.exports=t=(function(a){r(s,a);function s(l,c,d,f){if(s.__super__.constructor.call(this,l),d==null)throw new Error("Missing DTD entity name. "+this.debugInfo(d));if(f==null)throw new Error("Missing DTD entity value. "+this.debugInfo(d));if(this.pe=!!c,this.name=this.stringify.name(d),this.type=n.EntityDeclaration,!i(f))this.value=this.stringify.dtdEntityValue(f),this.internal=!0;else{if(!f.pubID&&!f.sysID)throw new Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(d));if(f.pubID&&!f.sysID)throw new Error("System identifier is required for a public external entity. "+this.debugInfo(d));if(this.internal=!1,f.pubID!=null&&(this.pubID=this.stringify.dtdPubID(f.pubID)),f.sysID!=null&&(this.sysID=this.stringify.dtdSysID(f.sysID)),f.nData!=null&&(this.nData=this.stringify.dtdNData(f.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(d))}}return Object.defineProperty(s.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(s.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(s.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(s.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(s.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(s.prototype,"xmlVersion",{get:function(){return null}}),s.prototype.toString=function(l)