@vlci/cdmciutat 30.0.0 → 32.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/js/legacy.js CHANGED
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see legacy.js.LICENSE.txt */
2
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.legacy=e():t.legacy=e()}(self,(()=>(()=>{var t={7526:(t,e)=>{"use strict";e.byteLength=function(t){var e=a(t),r=e[0],n=e[1];return 3*(r+n)/4-n},e.toByteArray=function(t){var e,r,i=a(t),s=i[0],u=i[1],c=new o(function(t,e,r){return 3*(e+r)/4-r}(0,s,u)),f=0,p=u>0?s-4:s;for(r=0;r<p;r+=4)e=n[t.charCodeAt(r)]<<18|n[t.charCodeAt(r+1)]<<12|n[t.charCodeAt(r+2)]<<6|n[t.charCodeAt(r+3)],c[f++]=e>>16&255,c[f++]=e>>8&255,c[f++]=255&e;return 2===u&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,c[f++]=255&e),1===u&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,c[f++]=e>>8&255,c[f++]=255&e),c},e.fromByteArray=function(t){for(var e,n=t.length,o=n%3,i=[],s=16383,a=0,c=n-o;a<c;a+=s)i.push(u(t,a,a+s>c?c:a+s));return 1===o?(e=t[n-1],i.push(r[e>>2]+r[e<<4&63]+"==")):2===o&&(e=(t[n-2]<<8)+t[n-1],i.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0;s<64;++s)r[s]=i[s],n[i.charCodeAt(s)]=s;function a(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function u(t,e,n){for(var o,i,s=[],a=e;a<n;a+=3)o=(t[a]<<16&16711680)+(t[a+1]<<8&65280)+(255&t[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},8287:(t,e,r)=>{"use strict";const n=r(7526),o=r(251),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=u,e.SlowBuffer=function(t){return+t!=t&&(t=0),u.alloc(+t)},e.INSPECT_MAX_BYTES=50;const s=2147483647;function a(t){if(t>s)throw new RangeError('The value "'+t+'" is invalid for option "size"');const e=new Uint8Array(t);return Object.setPrototypeOf(e,u.prototype),e}function u(t,e,r){if("number"==typeof t){if("string"==typeof e)throw new TypeError('The "string" argument must be of type string. Received type number');return p(t)}return c(t,e,r)}function c(t,e,r){if("string"==typeof t)return function(t,e){if("string"==typeof e&&""!==e||(e="utf8"),!u.isEncoding(e))throw new TypeError("Unknown encoding: "+e);const r=0|g(t,e);let n=a(r);const o=n.write(t,e);return o!==r&&(n=n.slice(0,o)),n}(t,e);if(ArrayBuffer.isView(t))return function(t){if(Y(t,Uint8Array)){const e=new Uint8Array(t);return h(e.buffer,e.byteOffset,e.byteLength)}return l(t)}(t);if(null==t)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(Y(t,ArrayBuffer)||t&&Y(t.buffer,ArrayBuffer))return h(t,e,r);if("undefined"!=typeof SharedArrayBuffer&&(Y(t,SharedArrayBuffer)||t&&Y(t.buffer,SharedArrayBuffer)))return h(t,e,r);if("number"==typeof t)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return u.from(n,e,r);const o=function(t){if(u.isBuffer(t)){const e=0|y(t.length),r=a(e);return 0===r.length||t.copy(r,0,0,e),r}return void 0!==t.length?"number"!=typeof t.length||q(t.length)?a(0):l(t):"Buffer"===t.type&&Array.isArray(t.data)?l(t.data):void 0}(t);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return u.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function f(t){if("number"!=typeof t)throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function p(t){return f(t),a(t<0?0:0|y(t))}function l(t){const e=t.length<0?0:0|y(t.length),r=a(e);for(let n=0;n<e;n+=1)r[n]=255&t[n];return r}function h(t,e,r){if(e<0||t.byteLength<e)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return n=void 0===e&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,e):new Uint8Array(t,e,r),Object.setPrototypeOf(n,u.prototype),n}function y(t){if(t>=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|t}function g(t,e){if(u.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||Y(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);const r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return J(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return V(t).length;default:if(o)return n?-1:J(t).length;e=(""+e).toLowerCase(),o=!0}}function d(t,e,r){let n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return T(this,e,r);case"utf8":case"utf-8":return x(this,e,r);case"ascii":return O(this,e,r);case"latin1":case"binary":return P(this,e,r);case"base64":return A(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function b(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}function w(t,e,r,n,o){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),q(r=+r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof e&&(e=u.from(e,n)),u.isBuffer(e))return 0===e.length?-1:m(t,e,r,n,o);if("number"==typeof e)return e&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):m(t,[e],r,n,o);throw new TypeError("val must be string, number or Buffer")}function m(t,e,r,n,o){let i,s=1,a=t.length,u=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}function c(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(o){let n=-1;for(i=r;i<a;i++)if(c(t,i)===c(e,-1===n?0:i-n)){if(-1===n&&(n=i),i-n+1===u)return n*s}else-1!==n&&(i-=i-n),n=-1}else for(r+u>a&&(r=a-u),i=r;i>=0;i--){let r=!0;for(let n=0;n<u;n++)if(c(t,i+n)!==c(e,n)){r=!1;break}if(r)return i}return-1}function v(t,e,r,n){r=Number(r)||0;const o=t.length-r;n?(n=Number(n))>o&&(n=o):n=o;const i=e.length;let s;for(n>i/2&&(n=i/2),s=0;s<n;++s){const n=parseInt(e.substr(2*s,2),16);if(q(n))return s;t[r+s]=n}return s}function S(t,e,r,n){return H(J(e,t.length-r),t,r,n)}function M(t,e,r,n){return H(function(t){const e=[];for(let r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function E(t,e,r,n){return H(V(e),t,r,n)}function k(t,e,r,n){return H(function(t,e){let r,n,o;const i=[];for(let s=0;s<t.length&&!((e-=2)<0);++s)r=t.charCodeAt(s),n=r>>8,o=r%256,i.push(o),i.push(n);return i}(e,t.length-r),t,r,n)}function A(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function x(t,e,r){r=Math.min(t.length,r);const n=[];let o=e;for(;o<r;){const e=t[o];let i=null,s=e>239?4:e>223?3:e>191?2:1;if(o+s<=r){let r,n,a,u;switch(s){case 1:e<128&&(i=e);break;case 2:r=t[o+1],128==(192&r)&&(u=(31&e)<<6|63&r,u>127&&(i=u));break;case 3:r=t[o+1],n=t[o+2],128==(192&r)&&128==(192&n)&&(u=(15&e)<<12|(63&r)<<6|63&n,u>2047&&(u<55296||u>57343)&&(i=u));break;case 4:r=t[o+1],n=t[o+2],a=t[o+3],128==(192&r)&&128==(192&n)&&128==(192&a)&&(u=(15&e)<<18|(63&r)<<12|(63&n)<<6|63&a,u>65535&&u<1114112&&(i=u))}}null===i?(i=65533,s=1):i>65535&&(i-=65536,n.push(i>>>10&1023|55296),i=56320|1023&i),n.push(i),o+=s}return function(t){const e=t.length;if(e<=I)return String.fromCharCode.apply(String,t);let r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=I));return r}(n)}e.kMaxLength=s,u.TYPED_ARRAY_SUPPORT=function(){try{const t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}(),u.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}}),u.poolSize=8192,u.from=function(t,e,r){return c(t,e,r)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array),u.alloc=function(t,e,r){return function(t,e,r){return f(t),t<=0?a(t):void 0!==e?"string"==typeof r?a(t).fill(e,r):a(t).fill(e):a(t)}(t,e,r)},u.allocUnsafe=function(t){return p(t)},u.allocUnsafeSlow=function(t){return p(t)},u.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==u.prototype},u.compare=function(t,e){if(Y(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),Y(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(t)||!u.isBuffer(e))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;let r=t.length,n=e.length;for(let o=0,i=Math.min(r,n);o<i;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:n<r?1:0},u.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(t,e){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return u.alloc(0);let r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;const n=u.allocUnsafe(e);let o=0;for(r=0;r<t.length;++r){let e=t[r];if(Y(e,Uint8Array))o+e.length>n.length?(u.isBuffer(e)||(e=u.from(e)),e.copy(n,o)):Uint8Array.prototype.set.call(n,e,o);else{if(!u.isBuffer(e))throw new TypeError('"list" argument must be an Array of Buffers');e.copy(n,o)}o+=e.length}return n},u.byteLength=g,u.prototype._isBuffer=!0,u.prototype.swap16=function(){const t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let e=0;e<t;e+=2)b(this,e,e+1);return this},u.prototype.swap32=function(){const t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let e=0;e<t;e+=4)b(this,e,e+3),b(this,e+1,e+2);return this},u.prototype.swap64=function(){const t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let e=0;e<t;e+=8)b(this,e,e+7),b(this,e+1,e+6),b(this,e+2,e+5),b(this,e+3,e+4);return this},u.prototype.toString=function(){const t=this.length;return 0===t?"":0===arguments.length?x(this,0,t):d.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(t){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===u.compare(this,t)},u.prototype.inspect=function(){let t="";const r=e.INSPECT_MAX_BYTES;return t=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(t+=" ... "),"<Buffer "+t+">"},i&&(u.prototype[i]=u.prototype.inspect),u.prototype.compare=function(t,e,r,n,o){if(Y(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),!u.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return-1;if(e>=r)return 1;if(this===t)return 0;let i=(o>>>=0)-(n>>>=0),s=(r>>>=0)-(e>>>=0);const a=Math.min(i,s),c=this.slice(n,o),f=t.slice(e,r);for(let t=0;t<a;++t)if(c[t]!==f[t]){i=c[t],s=f[t];break}return i<s?-1:s<i?1:0},u.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},u.prototype.indexOf=function(t,e,r){return w(this,t,e,r,!0)},u.prototype.lastIndexOf=function(t,e,r){return w(this,t,e,r,!1)},u.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const o=this.length-e;if((void 0===r||r>o)&&(r=o),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let i=!1;for(;;)switch(n){case"hex":return v(this,t,e,r);case"utf8":case"utf-8":return S(this,t,e,r);case"ascii":case"latin1":case"binary":return M(this,t,e,r);case"base64":return E(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,t,e,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const I=4096;function O(t,e,r){let n="";r=Math.min(t.length,r);for(let o=e;o<r;++o)n+=String.fromCharCode(127&t[o]);return n}function P(t,e,r){let n="";r=Math.min(t.length,r);for(let o=e;o<r;++o)n+=String.fromCharCode(t[o]);return n}function T(t,e,r){const n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);let o="";for(let n=e;n<r;++n)o+=X[t[n]];return o}function _(t,e,r){const n=t.slice(e,r);let o="";for(let t=0;t<n.length-1;t+=2)o+=String.fromCharCode(n[t]+256*n[t+1]);return o}function B(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function R(t,e,r,n,o,i){if(!u.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>o||e<i)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function U(t,e,r,n,o){G(e,n,o,t,r,7);let i=Number(e&BigInt(4294967295));t[r++]=i,i>>=8,t[r++]=i,i>>=8,t[r++]=i,i>>=8,t[r++]=i;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,r}function F(t,e,r,n,o){G(e,n,o,t,r,7);let i=Number(e&BigInt(4294967295));t[r+7]=i,i>>=8,t[r+6]=i,i>>=8,t[r+5]=i,i>>=8,t[r+4]=i;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r+3]=s,s>>=8,t[r+2]=s,s>>=8,t[r+1]=s,s>>=8,t[r]=s,r+8}function L(t,e,r,n,o,i){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function $(t,e,r,n,i){return e=+e,r>>>=0,i||L(t,0,r,4),o.write(t,e,r,n,23,4),r+4}function W(t,e,r,n,i){return e=+e,r>>>=0,i||L(t,0,r,8),o.write(t,e,r,n,52,8),r+8}u.prototype.slice=function(t,e){const r=this.length;(t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e<t&&(e=t);const n=this.subarray(t,e);return Object.setPrototypeOf(n,u.prototype),n},u.prototype.readUintLE=u.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t],o=1,i=0;for(;++i<e&&(o*=256);)n+=this[t+i]*o;return n},u.prototype.readUintBE=u.prototype.readUIntBE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t+--e],o=1;for(;e>0&&(o*=256);)n+=this[t+--e]*o;return n},u.prototype.readUint8=u.prototype.readUInt8=function(t,e){return t>>>=0,e||B(t,1,this.length),this[t]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(t,e){return t>>>=0,e||B(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(t,e){return t>>>=0,e||B(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(t,e){return t>>>=0,e||B(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(t,e){return t>>>=0,e||B(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readBigUInt64LE=K((function(t){C(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=e+256*this[++t]+65536*this[++t]+this[++t]*2**24,o=this[++t]+256*this[++t]+65536*this[++t]+r*2**24;return BigInt(n)+(BigInt(o)<<BigInt(32))})),u.prototype.readBigUInt64BE=K((function(t){C(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=e*2**24+65536*this[++t]+256*this[++t]+this[++t],o=this[++t]*2**24+65536*this[++t]+256*this[++t]+r;return(BigInt(n)<<BigInt(32))+BigInt(o)})),u.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t],o=1,i=0;for(;++i<e&&(o*=256);)n+=this[t+i]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*e)),n},u.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=e,o=1,i=this[t+--n];for(;n>0&&(o*=256);)i+=this[t+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*e)),i},u.prototype.readInt8=function(t,e){return t>>>=0,e||B(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function(t,e){t>>>=0,e||B(t,2,this.length);const r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(t,e){t>>>=0,e||B(t,2,this.length);const r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(t,e){return t>>>=0,e||B(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,e){return t>>>=0,e||B(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readBigInt64LE=K((function(t){C(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=this[t+4]+256*this[t+5]+65536*this[t+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(e+256*this[++t]+65536*this[++t]+this[++t]*2**24)})),u.prototype.readBigInt64BE=K((function(t){C(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=(e<<24)+65536*this[++t]+256*this[++t]+this[++t];return(BigInt(n)<<BigInt(32))+BigInt(this[++t]*2**24+65536*this[++t]+256*this[++t]+r)})),u.prototype.readFloatLE=function(t,e){return t>>>=0,e||B(t,4,this.length),o.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,e){return t>>>=0,e||B(t,4,this.length),o.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,e){return t>>>=0,e||B(t,8,this.length),o.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,e){return t>>>=0,e||B(t,8,this.length),o.read(this,t,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||R(this,t,e,r,Math.pow(2,8*r)-1,0);let o=1,i=0;for(this[e]=255&t;++i<r&&(o*=256);)this[e+i]=t/o&255;return e+r},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||R(this,t,e,r,Math.pow(2,8*r)-1,0);let o=r-1,i=1;for(this[e+o]=255&t;--o>=0&&(i*=256);)this[e+o]=t/i&255;return e+r},u.prototype.writeUint8=u.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,1,255,0),this[e]=255&t,e+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeBigUInt64LE=K((function(t,e=0){return U(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeBigUInt64BE=K((function(t,e=0){return F(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}let o=0,i=1,s=0;for(this[e]=255&t;++o<r&&(i*=256);)t<0&&0===s&&0!==this[e+o-1]&&(s=1),this[e+o]=(t/i|0)-s&255;return e+r},u.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}let o=r-1,i=1,s=0;for(this[e+o]=255&t;--o>=0&&(i*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/i|0)-s&255;return e+r},u.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},u.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},u.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeBigInt64LE=K((function(t,e=0){return U(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeBigInt64BE=K((function(t,e=0){return F(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeFloatLE=function(t,e,r){return $(this,t,e,!0,r)},u.prototype.writeFloatBE=function(t,e,r){return $(this,t,e,!1,r)},u.prototype.writeDoubleLE=function(t,e,r){return W(this,t,e,!0,r)},u.prototype.writeDoubleBE=function(t,e,r){return W(this,t,e,!1,r)},u.prototype.copy=function(t,e,r,n){if(!u.isBuffer(t))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);const o=n-r;return this===t&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(e,r,n):Uint8Array.prototype.set.call(t,this.subarray(r,n),e),o},u.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!u.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===t.length){const e=t.charCodeAt(0);("utf8"===n&&e<128||"latin1"===n)&&(t=e)}}else"number"==typeof t?t&=255:"boolean"==typeof t&&(t=Number(t));if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;let o;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{const i=u.isBuffer(t)?t:u.from(t,n),s=i.length;if(0===s)throw new TypeError('The value "'+t+'" is invalid for argument "value"');for(o=0;o<r-e;++o)this[o+e]=i[o%s]}return this};const j={};function N(t,e,r){j[t]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:e.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(t){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:t,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}function Z(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function G(t,e,r,n,o,i){if(t>r||t<e){const n="bigint"==typeof e?"n":"";let o;throw o=i>3?0===e||e===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(i+1)}${n}`:`>= -(2${n} ** ${8*(i+1)-1}${n}) and < 2 ** ${8*(i+1)-1}${n}`:`>= ${e}${n} and <= ${r}${n}`,new j.ERR_OUT_OF_RANGE("value",o,t)}!function(t,e,r){C(e,"offset"),void 0!==t[e]&&void 0!==t[e+r]||D(e,t.length-(r+1))}(n,o,i)}function C(t,e){if("number"!=typeof t)throw new j.ERR_INVALID_ARG_TYPE(e,"number",t)}function D(t,e,r){if(Math.floor(t)!==t)throw C(t,r),new j.ERR_OUT_OF_RANGE(r||"offset","an integer",t);if(e<0)throw new j.ERR_BUFFER_OUT_OF_BOUNDS;throw new j.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${e}`,t)}N("ERR_BUFFER_OUT_OF_BOUNDS",(function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),N("ERR_INVALID_ARG_TYPE",(function(t,e){return`The "${t}" argument must be of type number. Received type ${typeof e}`}),TypeError),N("ERR_OUT_OF_RANGE",(function(t,e,r){let n=`The value of "${t}" is out of range.`,o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=Z(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=Z(o)),o+="n"),n+=` It must be ${e}. Received ${o}`,n}),RangeError);const z=/[^+/0-9A-Za-z-_]/g;function J(t,e){let r;e=e||1/0;const n=t.length;let o=null;const i=[];for(let s=0;s<n;++s){if(r=t.charCodeAt(s),r>55295&&r<57344){if(!o){if(r>56319){(e-=3)>-1&&i.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(e-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(e-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((e-=1)<0)break;i.push(r)}else if(r<2048){if((e-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function V(t){return n.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace(z,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function H(t,e,r,n){let o;for(o=0;o<n&&!(o+r>=e.length||o>=t.length);++o)e[o+r]=t[o];return o}function Y(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}function q(t){return t!=t}const X=function(){const t="0123456789abcdef",e=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)e[n+o]=t[r]+t[o]}return e}();function K(t){return"undefined"==typeof BigInt?Q:t}function Q(){throw new Error("BigInt not supported")}},8075:(t,e,r)=>{"use strict";var n=r(453),o=r(487),i=o(n("String.prototype.indexOf"));t.exports=function(t,e){var r=n(t,!!e);return"function"==typeof r&&i(t,".prototype.")>-1?o(r):r}},487:(t,e,r)=>{"use strict";var n=r(6743),o=r(453),i=r(6897),s=r(9675),a=o("%Function.prototype.apply%"),u=o("%Function.prototype.call%"),c=o("%Reflect.apply%",!0)||n.call(u,a),f=r(655),p=o("%Math.max%");t.exports=function(t){if("function"!=typeof t)throw new s("a function is required");var e=c(n,u,arguments);return i(e,1+p(0,t.length-(arguments.length-1)),!0)};var l=function(){return c(n,a,arguments)};f?f(t.exports,"apply",{value:l}):t.exports.apply=l},41:(t,e,r)=>{"use strict";var n=r(655),o=r(8068),i=r(9675),s=r(5795);t.exports=function(t,e,r){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new i("`obj` must be an object or a function`");if("string"!=typeof e&&"symbol"!=typeof e)throw new i("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new i("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new i("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new i("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new i("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,u=arguments.length>4?arguments[4]:null,c=arguments.length>5?arguments[5]:null,f=arguments.length>6&&arguments[6],p=!!s&&s(t,e);if(n)n(t,e,{configurable:null===c&&p?p.configurable:!c,enumerable:null===a&&p?p.enumerable:!a,value:r,writable:null===u&&p?p.writable:!u});else{if(!f&&(a||u||c))throw new o("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");t[e]=r}}},655:(t,e,r)=>{"use strict";var n=r(453)("%Object.defineProperty%",!0)||!1;if(n)try{n({},"a",{value:1})}catch(t){n=!1}t.exports=n},1237:t=>{"use strict";t.exports=EvalError},9383:t=>{"use strict";t.exports=Error},9290:t=>{"use strict";t.exports=RangeError},9538:t=>{"use strict";t.exports=ReferenceError},8068:t=>{"use strict";t.exports=SyntaxError},9675:t=>{"use strict";t.exports=TypeError},5345:t=>{"use strict";t.exports=URIError},2682:(t,e,r)=>{"use strict";var n=r(9600),o=Object.prototype.toString,i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){if(!n(e))throw new TypeError("iterator must be a function");var s;arguments.length>=3&&(s=r),"[object Array]"===o.call(t)?function(t,e,r){for(var n=0,o=t.length;n<o;n++)i.call(t,n)&&(null==r?e(t[n],n,t):e.call(r,t[n],n,t))}(t,e,s):"string"==typeof t?function(t,e,r){for(var n=0,o=t.length;n<o;n++)null==r?e(t.charAt(n),n,t):e.call(r,t.charAt(n),n,t)}(t,e,s):function(t,e,r){for(var n in t)i.call(t,n)&&(null==r?e(t[n],n,t):e.call(r,t[n],n,t))}(t,e,s)}},9353:t=>{"use strict";var e=Object.prototype.toString,r=Math.max,n=function(t,e){for(var r=[],n=0;n<t.length;n+=1)r[n]=t[n];for(var o=0;o<e.length;o+=1)r[o+t.length]=e[o];return r};t.exports=function(t){var o=this;if("function"!=typeof o||"[object Function]"!==e.apply(o))throw new TypeError("Function.prototype.bind called on incompatible "+o);for(var i,s=function(t){for(var e=[],r=1,n=0;r<t.length;r+=1,n+=1)e[n]=t[r];return e}(arguments),a=r(0,o.length-s.length),u=[],c=0;c<a;c++)u[c]="$"+c;if(i=Function("binder","return function ("+function(t){for(var e="",r=0;r<t.length;r+=1)e+=t[r],r+1<t.length&&(e+=",");return e}(u)+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof i){var e=o.apply(this,n(s,arguments));return Object(e)===e?e:this}return o.apply(t,n(s,arguments))})),o.prototype){var f=function(){};f.prototype=o.prototype,i.prototype=new f,f.prototype=null}return i}},6743:(t,e,r)=>{"use strict";var n=r(9353);t.exports=Function.prototype.bind||n},453:(t,e,r)=>{"use strict";var n,o=r(9383),i=r(1237),s=r(9290),a=r(9538),u=r(8068),c=r(9675),f=r(5345),p=Function,l=function(t){try{return p('"use strict"; return ('+t+").constructor;")()}catch(t){}},h=Object.getOwnPropertyDescriptor;if(h)try{h({},"")}catch(t){h=null}var y=function(){throw new c},g=h?function(){try{return y}catch(t){try{return h(arguments,"callee").get}catch(t){return y}}}():y,d=r(4039)(),b=r(24)(),w=Object.getPrototypeOf||(b?function(t){return t.__proto__}:null),m={},v="undefined"!=typeof Uint8Array&&w?w(Uint8Array):n,S={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":d&&w?w([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":m,"%AsyncGenerator%":m,"%AsyncGeneratorFunction%":m,"%AsyncIteratorPrototype%":m,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?n:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?n:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":o,"%eval%":eval,"%EvalError%":i,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":p,"%GeneratorFunction%":m,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":d&&w?w(w([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&d&&w?w((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":s,"%ReferenceError%":a,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&d&&w?w((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":d&&w?w(""[Symbol.iterator]()):n,"%Symbol%":d?Symbol:n,"%SyntaxError%":u,"%ThrowTypeError%":g,"%TypedArray%":v,"%TypeError%":c,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":f,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet};if(w)try{null.error}catch(t){var M=w(w(t));S["%Error.prototype%"]=M}var E=function t(e){var r;if("%AsyncFunction%"===e)r=l("async function () {}");else if("%GeneratorFunction%"===e)r=l("function* () {}");else if("%AsyncGeneratorFunction%"===e)r=l("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var o=t("%AsyncGenerator%");o&&w&&(r=w(o.prototype))}return S[e]=r,r},k={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},A=r(6743),x=r(9957),I=A.call(Function.call,Array.prototype.concat),O=A.call(Function.apply,Array.prototype.splice),P=A.call(Function.call,String.prototype.replace),T=A.call(Function.call,String.prototype.slice),_=A.call(Function.call,RegExp.prototype.exec),B=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,R=/\\(\\)?/g,U=function(t,e){var r,n=t;if(x(k,n)&&(n="%"+(r=k[n])[0]+"%"),x(S,n)){var o=S[n];if(o===m&&(o=E(n)),void 0===o&&!e)throw new c("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new u("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new c("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new c('"allowMissing" argument must be a boolean');if(null===_(/^%?[^%]*%?$/,t))throw new u("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=function(t){var e=T(t,0,1),r=T(t,-1);if("%"===e&&"%"!==r)throw new u("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==e)throw new u("invalid intrinsic syntax, expected opening `%`");var n=[];return P(t,B,(function(t,e,r,o){n[n.length]=r?P(o,R,"$1"):e||t})),n}(t),n=r.length>0?r[0]:"",o=U("%"+n+"%",e),i=o.name,s=o.value,a=!1,f=o.alias;f&&(n=f[0],O(r,I([0,1],f)));for(var p=1,l=!0;p<r.length;p+=1){var y=r[p],g=T(y,0,1),d=T(y,-1);if(('"'===g||"'"===g||"`"===g||'"'===d||"'"===d||"`"===d)&&g!==d)throw new u("property names with quotes must have matching quotes");if("constructor"!==y&&l||(a=!0),x(S,i="%"+(n+="."+y)+"%"))s=S[i];else if(null!=s){if(!(y in s)){if(!e)throw new c("base intrinsic for "+t+" exists, but the property is not available.");return}if(h&&p+1>=r.length){var b=h(s,y);s=(l=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:s[y]}else l=x(s,y),s=s[y];l&&!a&&(S[i]=s)}}return s}},5795:(t,e,r)=>{"use strict";var n=r(453)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(t){n=null}t.exports=n},592:(t,e,r)=>{"use strict";var n=r(655),o=function(){return!!n};o.hasArrayLengthDefineBug=function(){if(!n)return null;try{return 1!==n([],"length",{value:1}).length}catch(t){return!0}},t.exports=o},24:t=>{"use strict";var e={__proto__:null,foo:{}},r={__proto__:e}.foo===e.foo&&!(e instanceof Object);t.exports=function(){return r}},4039:(t,e,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(1333);t.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},1333:t=>{"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e)return!1;if("[object Symbol]"!==Object.prototype.toString.call(e))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(var n in t[e]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var o=Object.getOwnPropertySymbols(t);if(1!==o.length||o[0]!==e)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},9092:(t,e,r)=>{"use strict";var n=r(1333);t.exports=function(){return n()&&!!Symbol.toStringTag}},9957:(t,e,r)=>{"use strict";var n=Function.prototype.call,o=Object.prototype.hasOwnProperty,i=r(6743);t.exports=i.call(n,o)},251:(t,e)=>{e.read=function(t,e,r,n,o){var i,s,a=8*o-n-1,u=(1<<a)-1,c=u>>1,f=-7,p=r?o-1:0,l=r?-1:1,h=t[e+p];for(p+=l,i=h&(1<<-f)-1,h>>=-f,f+=a;f>0;i=256*i+t[e+p],p+=l,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=n;f>0;s=256*s+t[e+p],p+=l,f-=8);if(0===i)i=1-c;else{if(i===u)return s?NaN:1/0*(h?-1:1);s+=Math.pow(2,n),i-=c}return(h?-1:1)*s*Math.pow(2,i-n)},e.write=function(t,e,r,n,o,i){var s,a,u,c=8*i-o-1,f=(1<<c)-1,p=f>>1,l=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:i-1,y=n?1:-1,g=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=f):(s=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-s))<1&&(s--,u*=2),(e+=s+p>=1?l/u:l*Math.pow(2,1-p))*u>=2&&(s++,u/=2),s+p>=f?(a=0,s=f):s+p>=1?(a=(e*u-1)*Math.pow(2,o),s+=p):(a=e*Math.pow(2,p-1)*Math.pow(2,o),s=0));o>=8;t[r+h]=255&a,h+=y,a/=256,o-=8);for(s=s<<o|a,c+=o;c>0;t[r+h]=255&s,h+=y,s/=256,c-=8);t[r+h-y]|=128*g}},6698:t=>{"function"==typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},7244:(t,e,r)=>{"use strict";var n=r(9092)(),o=r(8075)("Object.prototype.toString"),i=function(t){return!(n&&t&&"object"==typeof t&&Symbol.toStringTag in t)&&"[object Arguments]"===o(t)},s=function(t){return!!i(t)||null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Array]"!==o(t)&&"[object Function]"===o(t.callee)},a=function(){return i(arguments)}();i.isLegacyArguments=s,t.exports=a?i:s},9600:t=>{"use strict";var e,r,n=Function.prototype.toString,o="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof o&&"function"==typeof Object.defineProperty)try{e=Object.defineProperty({},"length",{get:function(){throw r}}),r={},o((function(){throw 42}),null,e)}catch(t){t!==r&&(o=null)}else o=null;var i=/^\s*class\b/,s=function(t){try{var e=n.call(t);return i.test(e)}catch(t){return!1}},a=function(t){try{return!s(t)&&(n.call(t),!0)}catch(t){return!1}},u=Object.prototype.toString,c="function"==typeof Symbol&&!!Symbol.toStringTag,f=!(0 in[,]),p=function(){return!1};if("object"==typeof document){var l=document.all;u.call(l)===u.call(document.all)&&(p=function(t){if((f||!t)&&(void 0===t||"object"==typeof t))try{var e=u.call(t);return("[object HTMLAllCollection]"===e||"[object HTML document.all class]"===e||"[object HTMLCollection]"===e||"[object Object]"===e)&&null==t("")}catch(t){}return!1})}t.exports=o?function(t){if(p(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;try{o(t,null,e)}catch(t){if(t!==r)return!1}return!s(t)&&a(t)}:function(t){if(p(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if(c)return a(t);if(s(t))return!1;var e=u.call(t);return!("[object Function]"!==e&&"[object GeneratorFunction]"!==e&&!/^\[object HTML/.test(e))&&a(t)}},8184:(t,e,r)=>{"use strict";var n,o=Object.prototype.toString,i=Function.prototype.toString,s=/^\s*(?:function)?\*/,a=r(9092)(),u=Object.getPrototypeOf;t.exports=function(t){if("function"!=typeof t)return!1;if(s.test(i.call(t)))return!0;if(!a)return"[object GeneratorFunction]"===o.call(t);if(!u)return!1;if(void 0===n){var e=function(){if(!a)return!1;try{return Function("return function*() {}")()}catch(t){}}();n=!!e&&u(e)}return u(t)===n}},5680:(t,e,r)=>{"use strict";var n=r(5767);t.exports=function(t){return!!n(t)}},6578:t=>{"use strict";t.exports=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]},5606:t=>{var e,r,n=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(t){if(e===setTimeout)return setTimeout(t,0);if((e===o||!e)&&setTimeout)return e=setTimeout,setTimeout(t,0);try{return e(t,0)}catch(r){try{return e.call(null,t,0)}catch(r){return e.call(this,t,0)}}}!function(){try{e="function"==typeof setTimeout?setTimeout:o}catch(t){e=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(t){r=i}}();var a,u=[],c=!1,f=-1;function p(){c&&a&&(c=!1,a.length?u=a.concat(u):f=-1,u.length&&l())}function l(){if(!c){var t=s(p);c=!0;for(var e=u.length;e;){for(a=u,u=[];++f<e;)a&&a[f].run();f=-1,e=u.length}a=null,c=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{return r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function y(){}n.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];u.push(new h(t,e)),1!==u.length||c||s(l)},h.prototype.run=function(){this.fun.apply(null,this.array)},n.title="browser",n.browser=!0,n.env={},n.argv=[],n.version="",n.versions={},n.on=y,n.addListener=y,n.once=y,n.off=y,n.removeListener=y,n.removeAllListeners=y,n.emit=y,n.prependListener=y,n.prependOnceListener=y,n.listeners=function(t){return[]},n.binding=function(t){throw new Error("process.binding is not supported")},n.cwd=function(){return"/"},n.chdir=function(t){throw new Error("process.chdir is not supported")},n.umask=function(){return 0}},6897:(t,e,r)=>{"use strict";var n=r(453),o=r(41),i=r(592)(),s=r(5795),a=r(9675),u=n("%Math.floor%");t.exports=function(t,e){if("function"!=typeof t)throw new a("`fn` is not a function");if("number"!=typeof e||e<0||e>4294967295||u(e)!==e)throw new a("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],n=!0,c=!0;if("length"in t&&s){var f=s(t,"length");f&&!f.configurable&&(n=!1),f&&!f.writable&&(c=!1)}return(n||c||!r)&&(i?o(t,"length",e,!0,!0):o(t,"length",e)),t}},1135:t=>{t.exports=function(t){return t&&"object"==typeof t&&"function"==typeof t.copy&&"function"==typeof t.fill&&"function"==typeof t.readUInt8}},9032:(t,e,r)=>{"use strict";var n=r(7244),o=r(8184),i=r(5767),s=r(5680);function a(t){return t.call.bind(t)}var u="undefined"!=typeof BigInt,c="undefined"!=typeof Symbol,f=a(Object.prototype.toString),p=a(Number.prototype.valueOf),l=a(String.prototype.valueOf),h=a(Boolean.prototype.valueOf);if(u)var y=a(BigInt.prototype.valueOf);if(c)var g=a(Symbol.prototype.valueOf);function d(t,e){if("object"!=typeof t)return!1;try{return e(t),!0}catch(t){return!1}}function b(t){return"[object Map]"===f(t)}function w(t){return"[object Set]"===f(t)}function m(t){return"[object WeakMap]"===f(t)}function v(t){return"[object WeakSet]"===f(t)}function S(t){return"[object ArrayBuffer]"===f(t)}function M(t){return"undefined"!=typeof ArrayBuffer&&(S.working?S(t):t instanceof ArrayBuffer)}function E(t){return"[object DataView]"===f(t)}function k(t){return"undefined"!=typeof DataView&&(E.working?E(t):t instanceof DataView)}e.isArgumentsObject=n,e.isGeneratorFunction=o,e.isTypedArray=s,e.isPromise=function(t){return"undefined"!=typeof Promise&&t instanceof Promise||null!==t&&"object"==typeof t&&"function"==typeof t.then&&"function"==typeof t.catch},e.isArrayBufferView=function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):s(t)||k(t)},e.isUint8Array=function(t){return"Uint8Array"===i(t)},e.isUint8ClampedArray=function(t){return"Uint8ClampedArray"===i(t)},e.isUint16Array=function(t){return"Uint16Array"===i(t)},e.isUint32Array=function(t){return"Uint32Array"===i(t)},e.isInt8Array=function(t){return"Int8Array"===i(t)},e.isInt16Array=function(t){return"Int16Array"===i(t)},e.isInt32Array=function(t){return"Int32Array"===i(t)},e.isFloat32Array=function(t){return"Float32Array"===i(t)},e.isFloat64Array=function(t){return"Float64Array"===i(t)},e.isBigInt64Array=function(t){return"BigInt64Array"===i(t)},e.isBigUint64Array=function(t){return"BigUint64Array"===i(t)},b.working="undefined"!=typeof Map&&b(new Map),e.isMap=function(t){return"undefined"!=typeof Map&&(b.working?b(t):t instanceof Map)},w.working="undefined"!=typeof Set&&w(new Set),e.isSet=function(t){return"undefined"!=typeof Set&&(w.working?w(t):t instanceof Set)},m.working="undefined"!=typeof WeakMap&&m(new WeakMap),e.isWeakMap=function(t){return"undefined"!=typeof WeakMap&&(m.working?m(t):t instanceof WeakMap)},v.working="undefined"!=typeof WeakSet&&v(new WeakSet),e.isWeakSet=function(t){return v(t)},S.working="undefined"!=typeof ArrayBuffer&&S(new ArrayBuffer),e.isArrayBuffer=M,E.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&E(new DataView(new ArrayBuffer(1),0,1)),e.isDataView=k;var A="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function x(t){return"[object SharedArrayBuffer]"===f(t)}function I(t){return void 0!==A&&(void 0===x.working&&(x.working=x(new A)),x.working?x(t):t instanceof A)}function O(t){return d(t,p)}function P(t){return d(t,l)}function T(t){return d(t,h)}function _(t){return u&&d(t,y)}function B(t){return c&&d(t,g)}e.isSharedArrayBuffer=I,e.isAsyncFunction=function(t){return"[object AsyncFunction]"===f(t)},e.isMapIterator=function(t){return"[object Map Iterator]"===f(t)},e.isSetIterator=function(t){return"[object Set Iterator]"===f(t)},e.isGeneratorObject=function(t){return"[object Generator]"===f(t)},e.isWebAssemblyCompiledModule=function(t){return"[object WebAssembly.Module]"===f(t)},e.isNumberObject=O,e.isStringObject=P,e.isBooleanObject=T,e.isBigIntObject=_,e.isSymbolObject=B,e.isBoxedPrimitive=function(t){return O(t)||P(t)||T(t)||_(t)||B(t)},e.isAnyArrayBuffer=function(t){return"undefined"!=typeof Uint8Array&&(M(t)||I(t))},["isProxy","isExternal","isModuleNamespaceObject"].forEach((function(t){Object.defineProperty(e,t,{enumerable:!1,value:function(){throw new Error(t+" is not supported in userland")}})}))},537:(t,e,r)=>{var n=r(5606),o=Object.getOwnPropertyDescriptors||function(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++)r[e[n]]=Object.getOwnPropertyDescriptor(t,e[n]);return r},i=/%[sdj%]/g;e.format=function(t){if(!m(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(c(arguments[r]));return e.join(" ")}r=1;for(var n=arguments,o=n.length,s=String(t).replace(i,(function(t){if("%%"===t)return"%";if(r>=o)return t;switch(t){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(t){return"[Circular]"}default:return t}})),a=n[r];r<o;a=n[++r])b(a)||!M(a)?s+=" "+a:s+=" "+c(a);return s},e.deprecate=function(t,r){if(void 0!==n&&!0===n.noDeprecation)return t;if(void 0===n)return function(){return e.deprecate(t,r).apply(this,arguments)};var o=!1;return function(){if(!o){if(n.throwDeprecation)throw new Error(r);n.traceDeprecation?console.trace(r):console.error(r),o=!0}return t.apply(this,arguments)}};var s={},a=/^$/;if(n.env.NODE_DEBUG){var u=n.env.NODE_DEBUG;u=u.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),a=new RegExp("^"+u+"$","i")}function c(t,r){var n={seen:[],stylize:p};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),d(r)?n.showHidden=r:r&&e._extend(n,r),v(n.showHidden)&&(n.showHidden=!1),v(n.depth)&&(n.depth=2),v(n.colors)&&(n.colors=!1),v(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=f),l(n,t,n.depth)}function f(t,e){var r=c.styles[e];return r?"["+c.colors[r][0]+"m"+t+"["+c.colors[r][1]+"m":t}function p(t,e){return t}function l(t,r,n){if(t.customInspect&&r&&A(r.inspect)&&r.inspect!==e.inspect&&(!r.constructor||r.constructor.prototype!==r)){var o=r.inspect(n,t);return m(o)||(o=l(t,o,n)),o}var i=function(t,e){if(v(e))return t.stylize("undefined","undefined");if(m(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}return w(e)?t.stylize(""+e,"number"):d(e)?t.stylize(""+e,"boolean"):b(e)?t.stylize("null","null"):void 0}(t,r);if(i)return i;var s=Object.keys(r),a=function(t){var e={};return t.forEach((function(t,r){e[t]=!0})),e}(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(r)),k(r)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return h(r);if(0===s.length){if(A(r)){var u=r.name?": "+r.name:"";return t.stylize("[Function"+u+"]","special")}if(S(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(E(r))return t.stylize(Date.prototype.toString.call(r),"date");if(k(r))return h(r)}var c,f="",p=!1,M=["{","}"];return g(r)&&(p=!0,M=["[","]"]),A(r)&&(f=" [Function"+(r.name?": "+r.name:"")+"]"),S(r)&&(f=" "+RegExp.prototype.toString.call(r)),E(r)&&(f=" "+Date.prototype.toUTCString.call(r)),k(r)&&(f=" "+h(r)),0!==s.length||p&&0!=r.length?n<0?S(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),c=p?function(t,e,r,n,o){for(var i=[],s=0,a=e.length;s<a;++s)P(e,String(s))?i.push(y(t,e,r,n,String(s),!0)):i.push("");return o.forEach((function(o){o.match(/^\d+$/)||i.push(y(t,e,r,n,o,!0))})),i}(t,r,n,a,s):s.map((function(e){return y(t,r,n,a,e,p)})),t.seen.pop(),function(t,e,r){return t.reduce((function(t,e){return e.indexOf("\n"),t+e.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60?r[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+r[1]:r[0]+e+" "+t.join(", ")+" "+r[1]}(c,f,M)):M[0]+f+M[1]}function h(t){return"["+Error.prototype.toString.call(t)+"]"}function y(t,e,r,n,o,i){var s,a,u;if((u=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]}).get?a=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(a=t.stylize("[Setter]","special")),P(n,o)||(s="["+o+"]"),a||(t.seen.indexOf(u.value)<0?(a=b(r)?l(t,u.value,null):l(t,u.value,r-1)).indexOf("\n")>-1&&(a=i?a.split("\n").map((function(t){return" "+t})).join("\n").slice(2):"\n"+a.split("\n").map((function(t){return" "+t})).join("\n")):a=t.stylize("[Circular]","special")),v(s)){if(i&&o.match(/^\d+$/))return a;(s=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.slice(1,-1),s=t.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=t.stylize(s,"string"))}return s+": "+a}function g(t){return Array.isArray(t)}function d(t){return"boolean"==typeof t}function b(t){return null===t}function w(t){return"number"==typeof t}function m(t){return"string"==typeof t}function v(t){return void 0===t}function S(t){return M(t)&&"[object RegExp]"===x(t)}function M(t){return"object"==typeof t&&null!==t}function E(t){return M(t)&&"[object Date]"===x(t)}function k(t){return M(t)&&("[object Error]"===x(t)||t instanceof Error)}function A(t){return"function"==typeof t}function x(t){return Object.prototype.toString.call(t)}function I(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(t){if(t=t.toUpperCase(),!s[t])if(a.test(t)){var r=n.pid;s[t]=function(){var n=e.format.apply(e,arguments);console.error("%s %d: %s",t,r,n)}}else s[t]=function(){};return s[t]},e.inspect=c,c.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.types=r(9032),e.isArray=g,e.isBoolean=d,e.isNull=b,e.isNullOrUndefined=function(t){return null==t},e.isNumber=w,e.isString=m,e.isSymbol=function(t){return"symbol"==typeof t},e.isUndefined=v,e.isRegExp=S,e.types.isRegExp=S,e.isObject=M,e.isDate=E,e.types.isDate=E,e.isError=k,e.types.isNativeError=k,e.isFunction=A,e.isPrimitive=function(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t},e.isBuffer=r(1135);var O=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){var t,r;console.log("%s - %s",(r=[I((t=new Date).getHours()),I(t.getMinutes()),I(t.getSeconds())].join(":"),[t.getDate(),O[t.getMonth()],r].join(" ")),e.format.apply(e,arguments))},e.inherits=r(6698),e._extend=function(t,e){if(!e||!M(e))return t;for(var r=Object.keys(e),n=r.length;n--;)t[r[n]]=e[r[n]];return t};var T="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function _(t,e){if(!t){var r=new Error("Promise was rejected with a falsy value");r.reason=t,t=r}return e(t)}e.promisify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');if(T&&t[T]){var e;if("function"!=typeof(e=t[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,r,n=new Promise((function(t,n){e=t,r=n})),o=[],i=0;i<arguments.length;i++)o.push(arguments[i]);o.push((function(t,n){t?r(t):e(n)}));try{t.apply(this,o)}catch(t){r(t)}return n}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),T&&Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(e,o(t))},e.promisify.custom=T,e.callbackify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');function e(){for(var e=[],r=0;r<arguments.length;r++)e.push(arguments[r]);var o=e.pop();if("function"!=typeof o)throw new TypeError("The last argument must be of type Function");var i=this,s=function(){return o.apply(i,arguments)};t.apply(this,e).then((function(t){n.nextTick(s.bind(null,null,t))}),(function(t){n.nextTick(_.bind(null,t,s))}))}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),Object.defineProperties(e,o(t)),e}},5767:(t,e,r)=>{"use strict";var n=r(2682),o=r(9209),i=r(487),s=r(8075),a=r(5795),u=s("Object.prototype.toString"),c=r(9092)(),f="undefined"==typeof globalThis?r.g:globalThis,p=o(),l=s("String.prototype.slice"),h=Object.getPrototypeOf,y=s("Array.prototype.indexOf",!0)||function(t,e){for(var r=0;r<t.length;r+=1)if(t[r]===e)return r;return-1},g={__proto__:null};n(p,c&&a&&h?function(t){var e=new f[t];if(Symbol.toStringTag in e){var r=h(e),n=a(r,Symbol.toStringTag);if(!n){var o=h(r);n=a(o,Symbol.toStringTag)}g["$"+t]=i(n.get)}}:function(t){var e=new f[t],r=e.slice||e.set;r&&(g["$"+t]=i(r))}),t.exports=function(t){if(!t||"object"!=typeof t)return!1;if(!c){var e=l(u(t),8,-1);return y(p,e)>-1?e:"Object"===e&&function(t){var e=!1;return n(g,(function(r,n){if(!e)try{r(t),e=l(n,1)}catch(t){}})),e}(t)}return a?function(t){var e=!1;return n(g,(function(r,n){if(!e)try{"$"+r(t)===n&&(e=l(n,1))}catch(t){}})),e}(t):null}},4047:(t,e,r)=>{var n=r(8287).Buffer;function o(t,e){this.buffer=t,this.position=0,this.isBigEndian=e||!1}function i(t,e,r){return function(){var n;return n=this.isBigEndian?e.call(this.buffer,this.position):t.call(this.buffer,this.position),this.position+=r,n}}t.exports=o,o.prototype.readUInt8=i(n.prototype.readUInt8,n.prototype.readUInt8,1),o.prototype.readUInt16=i(n.prototype.readUInt16LE,n.prototype.readUInt16BE,2),o.prototype.readUInt32=i(n.prototype.readUInt32LE,n.prototype.readUInt32BE,4),o.prototype.readInt8=i(n.prototype.readInt8,n.prototype.readInt8,1),o.prototype.readInt16=i(n.prototype.readInt16LE,n.prototype.readInt16BE,2),o.prototype.readInt32=i(n.prototype.readInt32LE,n.prototype.readInt32BE,4),o.prototype.readFloat=i(n.prototype.readFloatLE,n.prototype.readFloatBE,4),o.prototype.readDouble=i(n.prototype.readDoubleLE,n.prototype.readDoubleBE,8),o.prototype.readVarInt=function(){var t,e=0,r=0;do{e+=(127&(t=this.buffer[this.position+r]))<<7*r,r++}while(t>=128);return this.position+=r,e}},1199:(t,e,r)=>{var n=r(8287).Buffer;function o(t,e){this.buffer=new n(t),this.position=0,this.allowResize=e}function i(t,e){return function(r,n){this.ensureSize(e),t.call(this.buffer,r,this.position,n),this.position+=e}}t.exports=o,o.prototype.writeUInt8=i(n.prototype.writeUInt8,1),o.prototype.writeUInt16LE=i(n.prototype.writeUInt16LE,2),o.prototype.writeUInt16BE=i(n.prototype.writeUInt16BE,2),o.prototype.writeUInt32LE=i(n.prototype.writeUInt32LE,4),o.prototype.writeUInt32BE=i(n.prototype.writeUInt32BE,4),o.prototype.writeInt8=i(n.prototype.writeInt8,1),o.prototype.writeInt16LE=i(n.prototype.writeInt16LE,2),o.prototype.writeInt16BE=i(n.prototype.writeInt16BE,2),o.prototype.writeInt32LE=i(n.prototype.writeInt32LE,4),o.prototype.writeInt32BE=i(n.prototype.writeInt32BE,4),o.prototype.writeFloatLE=i(n.prototype.writeFloatLE,4),o.prototype.writeFloatBE=i(n.prototype.writeFloatBE,4),o.prototype.writeDoubleLE=i(n.prototype.writeDoubleLE,8),o.prototype.writeDoubleBE=i(n.prototype.writeDoubleBE,8),o.prototype.writeBuffer=function(t){this.ensureSize(t.length),t.copy(this.buffer,this.position,0,t.length),this.position+=t.length},o.prototype.writeVarInt=function(t){for(var e=1;4294967168&t;)this.writeUInt8(127&t|128),t>>>=7,e++;return this.writeUInt8(127&t),e},o.prototype.ensureSize=function(t){if(this.buffer.length<this.position+t){if(!this.allowResize)throw new RangeError("index out of range");var e=new n(this.position+t);this.buffer.copy(e,0,0,this.buffer.length),this.buffer=e}}},2957:(t,e,r)=>{var n=r(8287).Buffer;t.exports=d;var o=r(740),i=r(4263),s=r(350),a=r(743),u=r(3452),c=r(3959),f=r(9236),p=r(1141),l=r(4047),h=r(1199),y=r(2104),g=r(1865);function d(){this.srid=void 0,this.hasZ=!1,this.hasM=!1}d.parse=function(t,e){if("string"==typeof t||t instanceof y)return d._parseWkt(t);if(n.isBuffer(t)||t instanceof l)return d._parseWkb(t,e);throw new Error("first argument must be a string or Buffer")},d._parseWkt=function(t){var e,r,n=(e=t instanceof y?t:new y(t)).matchRegex([/^SRID=(\d+);/]);n&&(r=parseInt(n[1],10));var l=e.matchType(),h=e.matchDimension(),g={srid:r,hasZ:h.hasZ,hasM:h.hasM};switch(l){case o.wkt.Point:return i._parseWkt(e,g);case o.wkt.LineString:return s._parseWkt(e,g);case o.wkt.Polygon:return a._parseWkt(e,g);case o.wkt.MultiPoint:return u._parseWkt(e,g);case o.wkt.MultiLineString:return c._parseWkt(e,g);case o.wkt.MultiPolygon:return f._parseWkt(e,g);case o.wkt.GeometryCollection:return p._parseWkt(e,g)}},d._parseWkb=function(t,e){var r,n,h,y={};switch((r=t instanceof l?t:new l(t)).isBigEndian=!r.readInt8(),n=r.readUInt32(),y.hasSrid=!(536870912&~n),y.isEwkb=536870912&n||1073741824&n||2147483648&n,y.hasSrid&&(y.srid=r.readUInt32()),y.hasZ=!1,y.hasM=!1,y.isEwkb||e&&e.isEwkb?(2147483648&n&&(y.hasZ=!0),1073741824&n&&(y.hasM=!0),h=15&n):n>=1e3&&n<2e3?(y.hasZ=!0,h=n-1e3):n>=2e3&&n<3e3?(y.hasM=!0,h=n-2e3):n>=3e3&&n<4e3?(y.hasZ=!0,y.hasM=!0,h=n-3e3):h=n,h){case o.wkb.Point:return i._parseWkb(r,y);case o.wkb.LineString:return s._parseWkb(r,y);case o.wkb.Polygon:return a._parseWkb(r,y);case o.wkb.MultiPoint:return u._parseWkb(r,y);case o.wkb.MultiLineString:return c._parseWkb(r,y);case o.wkb.MultiPolygon:return f._parseWkb(r,y);case o.wkb.GeometryCollection:return p._parseWkb(r,y);default:throw new Error("GeometryType "+h+" not supported")}},d.parseTwkb=function(t){var e,r={},n=(e=t instanceof l?t:new l(t)).readUInt8(),h=e.readUInt8(),y=15&n;if(r.precision=g.decode(n>>4),r.precisionFactor=Math.pow(10,r.precision),r.hasBoundingBox=1&h,r.hasSizeAttribute=h>>1&1,r.hasIdList=h>>2&1,r.hasExtendedPrecision=h>>3&1,r.isEmpty=h>>4&1,r.hasExtendedPrecision){var d=e.readUInt8();r.hasZ=!(1&~d),r.hasM=!(2&~d),r.zPrecision=g.decode((28&d)>>2),r.zPrecisionFactor=Math.pow(10,r.zPrecision),r.mPrecision=g.decode((224&d)>>5),r.mPrecisionFactor=Math.pow(10,r.mPrecision)}else r.hasZ=!1,r.hasM=!1;if(r.hasSizeAttribute&&e.readVarInt(),r.hasBoundingBox){var b=2;r.hasZ&&b++,r.hasM&&b++;for(var w=0;w<b;w++)e.readVarInt(),e.readVarInt()}switch(y){case o.wkb.Point:return i._parseTwkb(e,r);case o.wkb.LineString:return s._parseTwkb(e,r);case o.wkb.Polygon:return a._parseTwkb(e,r);case o.wkb.MultiPoint:return u._parseTwkb(e,r);case o.wkb.MultiLineString:return c._parseTwkb(e,r);case o.wkb.MultiPolygon:return f._parseTwkb(e,r);case o.wkb.GeometryCollection:return p._parseTwkb(e,r);default:throw new Error("GeometryType "+y+" not supported")}},d.parseGeoJSON=function(t){return d._parseGeoJSON(t)},d._parseGeoJSON=function(t,e){var r;switch(t.type){case o.geoJSON.Point:r=i._parseGeoJSON(t);break;case o.geoJSON.LineString:r=s._parseGeoJSON(t);break;case o.geoJSON.Polygon:r=a._parseGeoJSON(t);break;case o.geoJSON.MultiPoint:r=u._parseGeoJSON(t);break;case o.geoJSON.MultiLineString:r=c._parseGeoJSON(t);break;case o.geoJSON.MultiPolygon:r=f._parseGeoJSON(t);break;case o.geoJSON.GeometryCollection:r=p._parseGeoJSON(t);break;default:throw new Error("GeometryType "+t.type+" not supported")}if(t.crs&&t.crs.type&&"name"===t.crs.type&&t.crs.properties&&t.crs.properties.name){var n=t.crs.properties.name;if(0===n.indexOf("EPSG:"))r.srid=parseInt(n.substring(5));else{if(0!==n.indexOf("urn:ogc:def:crs:EPSG::"))throw new Error("Unsupported crs: "+n);r.srid=parseInt(n.substring(22))}}else e||(r.srid=4326);return r},d.prototype.toEwkt=function(){return"SRID="+this.srid+";"+this.toWkt()},d.prototype.toEwkb=function(){var t=new h(this._getWkbSize()+4),e=this.toWkb();return t.writeInt8(1),t.writeUInt32LE((536870912|e.slice(1,5).readUInt32LE(0))>>>0,!0),t.writeUInt32LE(this.srid),t.writeBuffer(e.slice(5)),t.buffer},d.prototype._getWktType=function(t,e){var r=t;return this.hasZ&&this.hasM?r+=" ZM ":this.hasZ?r+=" Z ":this.hasM&&(r+=" M "),!e||this.hasZ||this.hasM||(r+=" "),e&&(r+="EMPTY"),r},d.prototype._getWktCoordinate=function(t){var e=t.x+" "+t.y;return this.hasZ&&(e+=" "+t.z),this.hasM&&(e+=" "+t.m),e},d.prototype._writeWkbType=function(t,e,r){var n=0;void 0!==this.srid||r&&void 0!==r.srid?(this.hasZ&&(n|=2147483648),this.hasM&&(n|=1073741824)):this.hasZ&&this.hasM?n+=3e3:this.hasZ?n+=1e3:this.hasM&&(n+=2e3),t.writeUInt32LE(n+e>>>0,!0)},d.getTwkbPrecision=function(t,e,r){return{xy:t,z:e,m:r,xyFactor:Math.pow(10,t),zFactor:Math.pow(10,e),mFactor:Math.pow(10,r)}},d.prototype._writeTwkbHeader=function(t,e,r,n){var o=(g.encode(r.xy)<<4)+e,i=(this.hasZ||this.hasM)<<3;if(i+=n<<4,t.writeUInt8(o),t.writeUInt8(i),this.hasZ||this.hasM){var s=0;this.hasZ&&(s|=1),this.hasM&&(s|=2),t.writeUInt8(s)}},d.prototype.toGeoJSON=function(t){var e={};return this.srid&&t&&(t.shortCrs?e.crs={type:"name",properties:{name:"EPSG:"+this.srid}}:t.longCrs&&(e.crs={type:"name",properties:{name:"urn:ogc:def:crs:EPSG::"+this.srid}})),e}},1141:(t,e,r)=>{t.exports=a;var n=r(537),o=r(740),i=r(2957),s=r(1199);function a(t,e){i.call(this),this.geometries=t||[],this.srid=e,this.geometries.length>0&&(this.hasZ=this.geometries[0].hasZ,this.hasM=this.geometries[0].hasM)}n.inherits(a,i),a.Z=function(t,e){var r=new a(t,e);return r.hasZ=!0,r},a.M=function(t,e){var r=new a(t,e);return r.hasM=!0,r},a.ZM=function(t,e){var r=new a(t,e);return r.hasZ=!0,r.hasM=!0,r},a._parseWkt=function(t,e){var r=new a;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{r.geometries.push(i.parse(t))}while(t.isMatch([","]));return t.expectGroupEnd(),r},a._parseWkb=function(t,e){var r=new a;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.geometries.push(i.parse(t,e));return r},a._parseTwkb=function(t,e){var r=new a;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=t.readVarInt(),o=0;o<n;o++)r.geometries.push(i.parseTwkb(t));return r},a._parseGeoJSON=function(t){for(var e=new a,r=0;r<t.geometries.length;r++)e.geometries.push(i._parseGeoJSON(t.geometries[r],!0));return e.geometries.length>0&&(e.hasZ=e.geometries[0].hasZ),e},a.prototype.toWkt=function(){if(0===this.geometries.length)return this._getWktType(o.wkt.GeometryCollection,!0);for(var t=this._getWktType(o.wkt.GeometryCollection,!1)+"(",e=0;e<this.geometries.length;e++)t+=this.geometries[e].toWkt()+",";return(t=t.slice(0,-1))+")"},a.prototype.toWkb=function(){var t=new s(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.GeometryCollection),t.writeUInt32LE(this.geometries.length);for(var e=0;e<this.geometries.length;e++)t.writeBuffer(this.geometries[e].toWkb({srid:this.srid}));return t.buffer},a.prototype.toTwkb=function(){var t=new s(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.geometries.length;if(this._writeTwkbHeader(t,o.wkb.GeometryCollection,e,r),this.geometries.length>0){t.writeVarInt(this.geometries.length);for(var n=0;n<this.geometries.length;n++)t.writeBuffer(this.geometries[n].toTwkb())}return t.buffer},a.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.geometries.length;e++)t+=this.geometries[e]._getWkbSize();return t},a.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.GeometryCollection,e.geometries=[];for(var r=0;r<this.geometries.length;r++)e.geometries.push(this.geometries[r].toGeoJSON());return e}},350:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(4263),a=r(1199);function u(t,e){o.call(this),this.points=t||[],this.srid=e,this.points.length>0&&(this.hasZ=this.points[0].hasZ,this.hasM=this.points[0].hasM)}n.inherits(u,o),u.Z=function(t,e){var r=new u(t,e);return r.hasZ=!0,r},u.M=function(t,e){var r=new u(t,e);return r.hasM=!0,r},u.ZM=function(t,e){var r=new u(t,e);return r.hasZ=!0,r.hasM=!0,r},u._parseWkt=function(t,e){var r=new u;return r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"])||(t.expectGroupStart(),r.points.push.apply(r.points,t.matchCoordinates(e)),t.expectGroupEnd()),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.points.push(s._readWkbPoint(t,e));return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++)r.points.push(s._readTwkbPoint(t,e,n));return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&(e.hasZ=t.coordinates[0].length>2);for(var r=0;r<t.coordinates.length;r++)e.points.push(s._readGeoJSONPoint(t.coordinates[r]));return e},u.prototype.toWkt=function(){return 0===this.points.length?this._getWktType(i.wkt.LineString,!0):this._getWktType(i.wkt.LineString,!1)+this._toInnerWkt()},u.prototype._toInnerWkt=function(){for(var t="(",e=0;e<this.points.length;e++)t+=this._getWktCoordinate(this.points[e])+",";return(t=t.slice(0,-1))+")"},u.prototype.toWkb=function(t){var e=new a(this._getWkbSize());e.writeInt8(1),this._writeWkbType(e,i.wkb.LineString,t),e.writeUInt32LE(this.points.length);for(var r=0;r<this.points.length;r++)this.points[r]._writeWkbPoint(e);return e.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=o.getTwkbPrecision(5,0,0),r=0===this.points.length;if(this._writeTwkbHeader(t,i.wkb.LineString,e,r),this.points.length>0){t.writeVarInt(this.points.length);for(var n=new s(0,0,0,0),u=0;u<this.points.length;u++)this.points[u]._writeTwkbPoint(t,e,n)}return t.buffer},u.prototype._getWkbSize=function(){var t=16;return this.hasZ&&(t+=8),this.hasM&&(t+=8),9+this.points.length*t},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);e.type=i.geoJSON.LineString,e.coordinates=[];for(var r=0;r<this.points.length;r++)this.hasZ?e.coordinates.push([this.points[r].x,this.points[r].y,this.points[r].z]):e.coordinates.push([this.points[r].x,this.points[r].y]);return e}},3959:(t,e,r)=>{t.exports=c;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(350),u=r(1199);function c(t,e){i.call(this),this.lineStrings=t||[],this.srid=e,this.lineStrings.length>0&&(this.hasZ=this.lineStrings[0].hasZ,this.hasM=this.lineStrings[0].hasM)}n.inherits(c,i),c.Z=function(t,e){var r=new c(t,e);return r.hasZ=!0,r},c.M=function(t,e){var r=new c(t,e);return r.hasM=!0,r},c.ZM=function(t,e){var r=new c(t,e);return r.hasZ=!0,r.hasM=!0,r},c._parseWkt=function(t,e){var r=new c;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{t.expectGroupStart(),r.lineStrings.push(new a(t.matchCoordinates(e))),t.expectGroupEnd()}while(t.isMatch([","]));return t.expectGroupEnd(),r},c._parseWkb=function(t,e){var r=new c;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.lineStrings.push(i.parse(t,e));return r},c._parseTwkb=function(t,e){var r=new c;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++){var u=new a;u.hasZ=e.hasZ,u.hasM=e.hasM;for(var f=t.readVarInt(),p=0;p<f;p++)u.points.push(s._readTwkbPoint(t,e,n));r.lineStrings.push(u)}return r},c._parseGeoJSON=function(t){var e=new c;t.coordinates.length>0&&t.coordinates[0].length>0&&(e.hasZ=t.coordinates[0][0].length>2);for(var r=0;r<t.coordinates.length;r++)e.lineStrings.push(a._parseGeoJSON({coordinates:t.coordinates[r]}));return e},c.prototype.toWkt=function(){if(0===this.lineStrings.length)return this._getWktType(o.wkt.MultiLineString,!0);for(var t=this._getWktType(o.wkt.MultiLineString,!1)+"(",e=0;e<this.lineStrings.length;e++)t+=this.lineStrings[e]._toInnerWkt()+",";return(t=t.slice(0,-1))+")"},c.prototype.toWkb=function(){var t=new u(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiLineString),t.writeUInt32LE(this.lineStrings.length);for(var e=0;e<this.lineStrings.length;e++)t.writeBuffer(this.lineStrings[e].toWkb({srid:this.srid}));return t.buffer},c.prototype.toTwkb=function(){var t=new u(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.lineStrings.length;if(this._writeTwkbHeader(t,o.wkb.MultiLineString,e,r),this.lineStrings.length>0){t.writeVarInt(this.lineStrings.length);for(var n=new s(0,0,0,0),a=0;a<this.lineStrings.length;a++){t.writeVarInt(this.lineStrings[a].points.length);for(var c=0;c<this.lineStrings[a].points.length;c++)this.lineStrings[a].points[c]._writeTwkbPoint(t,e,n)}}return t.buffer},c.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.lineStrings.length;e++)t+=this.lineStrings[e]._getWkbSize();return t},c.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiLineString,e.coordinates=[];for(var r=0;r<this.lineStrings.length;r++)e.coordinates.push(this.lineStrings[r].toGeoJSON().coordinates);return e}},3452:(t,e,r)=>{t.exports=u;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(1199);function u(t,e){i.call(this),this.points=t||[],this.srid=e,this.points.length>0&&(this.hasZ=this.points[0].hasZ,this.hasM=this.points[0].hasM)}n.inherits(u,i),u.Z=function(t,e){var r=new u(t,e);return r.hasZ=!0,r},u.M=function(t,e){var r=new u(t,e);return r.hasM=!0,r},u.ZM=function(t,e){var r=new u(t,e);return r.hasZ=!0,r.hasM=!0,r},u._parseWkt=function(t,e){var r=new u;return r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"])||(t.expectGroupStart(),r.points.push.apply(r.points,t.matchCoordinates(e)),t.expectGroupEnd()),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.points.push(i.parse(t,e));return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++)r.points.push(s._readTwkbPoint(t,e,n));return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&(e.hasZ=t.coordinates[0].length>2);for(var r=0;r<t.coordinates.length;r++)e.points.push(s._parseGeoJSON({coordinates:t.coordinates[r]}));return e},u.prototype.toWkt=function(){if(0===this.points.length)return this._getWktType(o.wkt.MultiPoint,!0);for(var t=this._getWktType(o.wkt.MultiPoint,!1)+"(",e=0;e<this.points.length;e++)t+=this._getWktCoordinate(this.points[e])+",";return(t=t.slice(0,-1))+")"},u.prototype.toWkb=function(){var t=new a(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiPoint),t.writeUInt32LE(this.points.length);for(var e=0;e<this.points.length;e++)t.writeBuffer(this.points[e].toWkb({srid:this.srid}));return t.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.points.length;if(this._writeTwkbHeader(t,o.wkb.MultiPoint,e,r),this.points.length>0){t.writeVarInt(this.points.length);for(var n=new s(0,0,0,0),u=0;u<this.points.length;u++)this.points[u]._writeTwkbPoint(t,e,n)}return t.buffer},u.prototype._getWkbSize=function(){var t=16;return this.hasZ&&(t+=8),this.hasM&&(t+=8),t+=5,9+this.points.length*t},u.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiPoint,e.coordinates=[];for(var r=0;r<this.points.length;r++)e.coordinates.push(this.points[r].toGeoJSON().coordinates);return e}},9236:(t,e,r)=>{t.exports=c;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(743),u=r(1199);function c(t,e){i.call(this),this.polygons=t||[],this.srid=e,this.polygons.length>0&&(this.hasZ=this.polygons[0].hasZ,this.hasM=this.polygons[0].hasM)}n.inherits(c,i),c.Z=function(t,e){var r=new c(t,e);return r.hasZ=!0,r},c.M=function(t,e){var r=new c(t,e);return r.hasM=!0,r},c.ZM=function(t,e){var r=new c(t,e);return r.hasZ=!0,r.hasM=!0,r},c._parseWkt=function(t,e){var r=new c;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{t.expectGroupStart();var n=[],o=[];for(t.expectGroupStart(),n.push.apply(n,t.matchCoordinates(e)),t.expectGroupEnd();t.isMatch([","]);)t.expectGroupStart(),o.push(t.matchCoordinates(e)),t.expectGroupEnd();r.polygons.push(new a(n,o)),t.expectGroupEnd()}while(t.isMatch([","]));return t.expectGroupEnd(),r},c._parseWkb=function(t,e){var r=new c;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.polygons.push(i.parse(t,e));return r},c._parseTwkb=function(t,e){var r=new c;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++){var u=new a;u.hasZ=e.hasZ,u.hasM=e.hasM;for(var f=t.readVarInt(),p=t.readVarInt(),l=0;l<p;l++)u.exteriorRing.push(s._readTwkbPoint(t,e,n));for(l=1;l<f;l++){for(var h=[],y=t.readVarInt(),g=0;g<y;g++)h.push(s._readTwkbPoint(t,e,n));u.interiorRings.push(h)}r.polygons.push(u)}return r},c._parseGeoJSON=function(t){var e=new c;t.coordinates.length>0&&t.coordinates[0].length>0&&t.coordinates[0][0].length>0&&(e.hasZ=t.coordinates[0][0][0].length>2);for(var r=0;r<t.coordinates.length;r++)e.polygons.push(a._parseGeoJSON({coordinates:t.coordinates[r]}));return e},c.prototype.toWkt=function(){if(0===this.polygons.length)return this._getWktType(o.wkt.MultiPolygon,!0);for(var t=this._getWktType(o.wkt.MultiPolygon,!1)+"(",e=0;e<this.polygons.length;e++)t+=this.polygons[e]._toInnerWkt()+",";return(t=t.slice(0,-1))+")"},c.prototype.toWkb=function(){var t=new u(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiPolygon),t.writeUInt32LE(this.polygons.length);for(var e=0;e<this.polygons.length;e++)t.writeBuffer(this.polygons[e].toWkb({srid:this.srid}));return t.buffer},c.prototype.toTwkb=function(){var t=new u(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.polygons.length;if(this._writeTwkbHeader(t,o.wkb.MultiPolygon,e,r),this.polygons.length>0){t.writeVarInt(this.polygons.length);for(var n=new s(0,0,0,0),a=0;a<this.polygons.length;a++){t.writeVarInt(1+this.polygons[a].interiorRings.length),t.writeVarInt(this.polygons[a].exteriorRing.length);for(var c=0;c<this.polygons[a].exteriorRing.length;c++)this.polygons[a].exteriorRing[c]._writeTwkbPoint(t,e,n);for(c=0;c<this.polygons[a].interiorRings.length;c++){t.writeVarInt(this.polygons[a].interiorRings[c].length);for(var f=0;f<this.polygons[a].interiorRings[c].length;f++)this.polygons[a].interiorRings[c][f]._writeTwkbPoint(t,e,n)}}}return t.buffer},c.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.polygons.length;e++)t+=this.polygons[e]._getWkbSize();return t},c.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiPolygon,e.coordinates=[];for(var r=0;r<this.polygons.length;r++)e.coordinates.push(this.polygons[r].toGeoJSON().coordinates);return e}},4263:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(1199),a=r(1865);function u(t,e,r,n,i){o.call(this),this.x=t,this.y=e,this.z=r,this.m=n,this.srid=i,this.hasZ=void 0!==this.z,this.hasM=void 0!==this.m}n.inherits(u,o),u.Z=function(t,e,r,n){var o=new u(t,e,r,void 0,n);return o.hasZ=!0,o},u.M=function(t,e,r,n){var o=new u(t,e,void 0,r,n);return o.hasM=!0,o},u.ZM=function(t,e,r,n,o){var i=new u(t,e,r,n,o);return i.hasZ=!0,i.hasM=!0,i},u._parseWkt=function(t,e){var r=new u;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();var n=t.matchCoordinate(e);return r.x=n.x,r.y=n.y,r.z=n.z,r.m=n.m,t.expectGroupEnd(),r},u._parseWkb=function(t,e){var r=u._readWkbPoint(t,e);return r.srid=e.srid,r},u._readWkbPoint=function(t,e){return new u(t.readDouble(),t.readDouble(),e.hasZ?t.readDouble():void 0,e.hasM?t.readDouble():void 0)},u._parseTwkb=function(t,e){var r=new u;return r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty||(r.x=a.decode(t.readVarInt())/e.precisionFactor,r.y=a.decode(t.readVarInt())/e.precisionFactor,r.z=e.hasZ?a.decode(t.readVarInt())/e.zPrecisionFactor:void 0,r.m=e.hasM?a.decode(t.readVarInt())/e.mPrecisionFactor:void 0),r},u._readTwkbPoint=function(t,e,r){return r.x+=a.decode(t.readVarInt())/e.precisionFactor,r.y+=a.decode(t.readVarInt())/e.precisionFactor,e.hasZ&&(r.z+=a.decode(t.readVarInt())/e.zPrecisionFactor),e.hasM&&(r.m+=a.decode(t.readVarInt())/e.mPrecisionFactor),new u(r.x,r.y,r.z,r.m)},u._parseGeoJSON=function(t){return u._readGeoJSONPoint(t.coordinates)},u._readGeoJSONPoint=function(t){return 0===t.length?new u:t.length>2?new u(t[0],t[1],t[2]):new u(t[0],t[1])},u.prototype.toWkt=function(){return void 0===this.x&&void 0===this.y&&void 0===this.z&&void 0===this.m?this._getWktType(i.wkt.Point,!0):this._getWktType(i.wkt.Point,!1)+"("+this._getWktCoordinate(this)+")"},u.prototype.toWkb=function(t){var e=new s(this._getWkbSize());return e.writeInt8(1),this._writeWkbType(e,i.wkb.Point,t),void 0===this.x&&void 0===this.y?(e.writeDoubleLE(NaN),e.writeDoubleLE(NaN),this.hasZ&&e.writeDoubleLE(NaN),this.hasM&&e.writeDoubleLE(NaN)):this._writeWkbPoint(e),e.buffer},u.prototype._writeWkbPoint=function(t){t.writeDoubleLE(this.x),t.writeDoubleLE(this.y),this.hasZ&&t.writeDoubleLE(this.z),this.hasM&&t.writeDoubleLE(this.m)},u.prototype.toTwkb=function(){var t=new s(0,!0),e=o.getTwkbPrecision(5,0,0),r=void 0===this.x&&void 0===this.y;return this._writeTwkbHeader(t,i.wkb.Point,e,r),r||this._writeTwkbPoint(t,e,new u(0,0,0,0)),t.buffer},u.prototype._writeTwkbPoint=function(t,e,r){var n=this.x*e.xyFactor,o=this.y*e.xyFactor,i=this.z*e.zFactor,s=this.m*e.mFactor;t.writeVarInt(a.encode(n-r.x)),t.writeVarInt(a.encode(o-r.y)),this.hasZ&&t.writeVarInt(a.encode(i-r.z)),this.hasM&&t.writeVarInt(a.encode(s-r.m)),r.x=n,r.y=o,r.z=i,r.m=s},u.prototype._getWkbSize=function(){var t=21;return this.hasZ&&(t+=8),this.hasM&&(t+=8),t},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);return e.type=i.geoJSON.Point,void 0===this.x&&void 0===this.y?e.coordinates=[]:void 0!==this.z?e.coordinates=[this.x,this.y,this.z]:e.coordinates=[this.x,this.y],e}},743:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(4263),a=r(1199);function u(t,e,r){o.call(this),this.exteriorRing=t||[],this.interiorRings=e||[],this.srid=r,this.exteriorRing.length>0&&(this.hasZ=this.exteriorRing[0].hasZ,this.hasM=this.exteriorRing[0].hasM)}n.inherits(u,o),u.Z=function(t,e,r){var n=new u(t,e,r);return n.hasZ=!0,n},u.M=function(t,e,r){var n=new u(t,e,r);return n.hasM=!0,n},u.ZM=function(t,e,r){var n=new u(t,e,r);return n.hasZ=!0,n.hasM=!0,n},u._parseWkt=function(t,e){var r=new u;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;for(t.expectGroupStart(),t.expectGroupStart(),r.exteriorRing.push.apply(r.exteriorRing,t.matchCoordinates(e)),t.expectGroupEnd();t.isMatch([","]);)t.expectGroupStart(),r.interiorRings.push(t.matchCoordinates(e)),t.expectGroupEnd();return t.expectGroupEnd(),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;var n=t.readUInt32();if(n>0){for(var o=t.readUInt32(),i=0;i<o;i++)r.exteriorRing.push(s._readWkbPoint(t,e));for(i=1;i<n;i++){for(var a=[],c=t.readUInt32(),f=0;f<c;f++)a.push(s._readWkbPoint(t,e));r.interiorRings.push(a)}}return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=t.readVarInt(),a=0;a<i;a++)r.exteriorRing.push(s._readTwkbPoint(t,e,n));for(a=1;a<o;a++){for(var c=[],f=t.readVarInt(),p=0;p<f;p++)c.push(s._readTwkbPoint(t,e,n));r.interiorRings.push(c)}return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&t.coordinates[0].length>0&&(e.hasZ=t.coordinates[0][0].length>2);for(var r=0;r<t.coordinates.length;r++){r>0&&e.interiorRings.push([]);for(var n=0;n<t.coordinates[r].length;n++)0===r?e.exteriorRing.push(s._readGeoJSONPoint(t.coordinates[r][n])):e.interiorRings[r-1].push(s._readGeoJSONPoint(t.coordinates[r][n]))}return e},u.prototype.toWkt=function(){return 0===this.exteriorRing.length?this._getWktType(i.wkt.Polygon,!0):this._getWktType(i.wkt.Polygon,!1)+this._toInnerWkt()},u.prototype._toInnerWkt=function(){for(var t="((",e=0;e<this.exteriorRing.length;e++)t+=this._getWktCoordinate(this.exteriorRing[e])+",";for(t=t.slice(0,-1),t+=")",e=0;e<this.interiorRings.length;e++){t+=",(";for(var r=0;r<this.interiorRings[e].length;r++)t+=this._getWktCoordinate(this.interiorRings[e][r])+",";t=t.slice(0,-1),t+=")"}return t+")"},u.prototype.toWkb=function(t){var e=new a(this._getWkbSize());e.writeInt8(1),this._writeWkbType(e,i.wkb.Polygon,t),this.exteriorRing.length>0?(e.writeUInt32LE(1+this.interiorRings.length),e.writeUInt32LE(this.exteriorRing.length)):e.writeUInt32LE(0);for(var r=0;r<this.exteriorRing.length;r++)this.exteriorRing[r]._writeWkbPoint(e);for(r=0;r<this.interiorRings.length;r++){e.writeUInt32LE(this.interiorRings[r].length);for(var n=0;n<this.interiorRings[r].length;n++)this.interiorRings[r][n]._writeWkbPoint(e)}return e.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=o.getTwkbPrecision(5,0,0),r=0===this.exteriorRing.length;if(this._writeTwkbHeader(t,i.wkb.Polygon,e,r),this.exteriorRing.length>0){t.writeVarInt(1+this.interiorRings.length),t.writeVarInt(this.exteriorRing.length);for(var n=new s(0,0,0,0),u=0;u<this.exteriorRing.length;u++)this.exteriorRing[u]._writeTwkbPoint(t,e,n);for(u=0;u<this.interiorRings.length;u++){t.writeVarInt(this.interiorRings[u].length);for(var c=0;c<this.interiorRings[u].length;c++)this.interiorRings[u][c]._writeTwkbPoint(t,e,n)}}return t.buffer},u.prototype._getWkbSize=function(){var t=16;this.hasZ&&(t+=8),this.hasM&&(t+=8);var e=9;this.exteriorRing.length>0&&(e+=4+this.exteriorRing.length*t);for(var r=0;r<this.interiorRings.length;r++)e+=4+this.interiorRings[r].length*t;return e},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);if(e.type=i.geoJSON.Polygon,e.coordinates=[],this.exteriorRing.length>0){for(var r=[],n=0;n<this.exteriorRing.length;n++)this.hasZ?r.push([this.exteriorRing[n].x,this.exteriorRing[n].y,this.exteriorRing[n].z]):r.push([this.exteriorRing[n].x,this.exteriorRing[n].y]);e.coordinates.push(r)}for(var s=0;s<this.interiorRings.length;s++){for(var a=[],u=0;u<this.interiorRings[s].length;u++)this.hasZ?a.push([this.interiorRings[s][u].x,this.interiorRings[s][u].y,this.interiorRings[s][u].z]):a.push([this.interiorRings[s][u].x,this.interiorRings[s][u].y]);e.coordinates.push(a)}return e}},740:t=>{t.exports={wkt:{Point:"POINT",LineString:"LINESTRING",Polygon:"POLYGON",MultiPoint:"MULTIPOINT",MultiLineString:"MULTILINESTRING",MultiPolygon:"MULTIPOLYGON",GeometryCollection:"GEOMETRYCOLLECTION"},wkb:{Point:1,LineString:2,Polygon:3,MultiPoint:4,MultiLineString:5,MultiPolygon:6,GeometryCollection:7},geoJSON:{Point:"Point",LineString:"LineString",Polygon:"Polygon",MultiPoint:"MultiPoint",MultiLineString:"MultiLineString",MultiPolygon:"MultiPolygon",GeometryCollection:"GeometryCollection"}}},2104:(t,e,r)=>{t.exports=i;var n=r(740),o=r(4263);function i(t){this.value=t,this.position=0}i.prototype.match=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++)if(0===this.value.substring(this.position).indexOf(t[e]))return this.position+=t[e].length,t[e];return null},i.prototype.matchRegex=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++){var r=this.value.substring(this.position).match(t[e]);if(r)return this.position+=r[0].length,r}return null},i.prototype.isMatch=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++)if(0===this.value.substring(this.position).indexOf(t[e]))return this.position+=t[e].length,!0;return!1},i.prototype.matchType=function(){var t=this.match([n.wkt.Point,n.wkt.LineString,n.wkt.Polygon,n.wkt.MultiPoint,n.wkt.MultiLineString,n.wkt.MultiPolygon,n.wkt.GeometryCollection]);if(!t)throw new Error("Expected geometry type");return t},i.prototype.matchDimension=function(){switch(this.match(["ZM","Z","M"])){case"ZM":return{hasZ:!0,hasM:!0};case"Z":return{hasZ:!0,hasM:!1};case"M":return{hasZ:!1,hasM:!0};default:return{hasZ:!1,hasM:!1}}},i.prototype.expectGroupStart=function(){if(!this.isMatch(["("]))throw new Error("Expected group start")},i.prototype.expectGroupEnd=function(){if(!this.isMatch([")"]))throw new Error("Expected group end")},i.prototype.matchCoordinate=function(t){var e;if(!(e=t.hasZ&&t.hasM?this.matchRegex([/^(\S*)\s+(\S*)\s+(\S*)\s+([^\s,)]*)/]):t.hasZ||t.hasM?this.matchRegex([/^(\S*)\s+(\S*)\s+([^\s,)]*)/]):this.matchRegex([/^(\S*)\s+([^\s,)]*)/])))throw new Error("Expected coordinates");return t.hasZ&&t.hasM?new o(parseFloat(e[1]),parseFloat(e[2]),parseFloat(e[3]),parseFloat(e[4])):t.hasZ?new o(parseFloat(e[1]),parseFloat(e[2]),parseFloat(e[3])):t.hasM?new o(parseFloat(e[1]),parseFloat(e[2]),void 0,parseFloat(e[3])):new o(parseFloat(e[1]),parseFloat(e[2]))},i.prototype.matchCoordinates=function(t){var e=[];do{var r=this.isMatch(["("]);e.push(this.matchCoordinate(t)),r&&this.expectGroupEnd()}while(this.isMatch([","]));return e},i.prototype.skipWhitespaces=function(){for(;this.position<this.value.length&&" "===this.value[this.position];)this.position++}},543:(t,e,r)=>{e.Types=r(740),e.Geometry=r(2957),e.Point=r(4263),e.LineString=r(350),e.Polygon=r(743),e.MultiPoint=r(3452),e.MultiLineString=r(3959),e.MultiPolygon=r(9236),e.GeometryCollection=r(1141)},1865:t=>{t.exports={encode:function(t){return t<<1^t>>31},decode:function(t){return t>>1^-(1&t)}}},9209:(t,e,r)=>{"use strict";var n=r(6578),o="undefined"==typeof globalThis?r.g:globalThis;t.exports=function(){for(var t=[],e=0;e<n.length;e++)"function"==typeof o[n[e]]&&(t[t.length]=n[e]);return t}}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={exports:{}};return t[n](i,i.exports,r),i.exports}r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};return(()=>{"use strict";r.r(n),r.d(n,{addDatesToGaps:()=>Mt,addPointInteger:()=>d,calcularRuta:()=>rt,calculateXAxisMonth:()=>b,calculateXAxisStart:()=>gt,calculateXAxisYear:()=>w,changeImg:()=>tt,closeFilter:()=>xt,closePopUp:()=>kt,commonPostFetch:()=>q,configureDataGaugeMonth:()=>H,configureDataLine:()=>V,configureGaugeYearBig:()=>wt,createCheckBoxFilter:()=>it,createCheckBoxFilterVar:()=>at,createGauge:()=>J,createLeafletMap:()=>Pt,createLeafletMapPolygon:()=>Ot,createObjectMarkerElements:()=>Tt,drawMarkers:()=>Bt,drawMarkersPolygon:()=>Rt,echartGaugeMonth:()=>R,echartGaugeYear:()=>U,echartLine:()=>bt,echartVerStackedBar:()=>B,filterDatesUpdate:()=>S,filterVarUpdate:()=>st,filterWindow:()=>At,formatDDMM:()=>ht,formatName:()=>z,formatRoundTooltip:()=>W,formatSixDigitDate:()=>ft,formatTooltip:()=>m,formatearFecha:()=>lt,formatoFecha:()=>ut,formatoFecha2:()=>ct,formatoFecha3:()=>pt,formatterReloj:()=>T,generateDatesArray:()=>St,getCommonOptionDonut:()=>N,getCommonOptionGaugeUmbral:()=>j,getCommonOptionPie:()=>Z,getCommonOptions:()=>_,getCommonOptionsBar:()=>F,getCommonOptionsGaugeMonth:()=>D,getCommonOptionsGaugeYears:()=>C,getConfigurationGaugeYears:()=>G,getDateFromStr:()=>mt,getMaxValue:()=>O,getMonth:()=>E,getMonthComplete:()=>k,getStringFromDate:()=>vt,getTime:()=>yt,getWidthElementChart:()=>P,includeHTMLCabecera:()=>X,includeHTMLFooter:()=>Q,includeHTMLMenu:()=>K,indoPopUp:()=>Et,initChart:()=>Y,llamadasIniciales:()=>ot,normalImg:()=>et,obtenerGeoJson:()=>_t,obtenerRuta:()=>nt,printDataChart:()=>x,printNoDataChart:()=>A,splitData:()=>I,xAxisFormatWithoutYear:()=>dt,yAxisFormat:()=>v});const t="8%",e="2.5%",o="5%",i="18%",s="20%",a="10%",u="90%",c="1%",f="0%",p=["#9c89b8","#4ea8de","#05668d","#ffbf69","#e56b6f","#83c5be","#02c39a","#ee9b00","#cdb4db","#ffadad","#ce4257","#b7b7a4"],l=33,h=[39.46975,-.37739],y=27,g=30;function d(t){let e=navigator.language||navigator.userLanguage;e=e.length<=2?`${e}-${e.toUpperCase()}`:e;const r={minimumFractionDigits:0,maximumFractionDigits:2};return"es-ES"===e?t.toLocaleString("de-DE",r):t.toLocaleString(e,r)}function b(t){return 100*(1-17/t)}function w(t){return 100*(1-7/t)}function m(t,e=!1){let r=`<p>${t[0].name}</p>`;return t.forEach((t=>{const n=e?Math.round(t.data):t.data,o=`<div>${i=t.color,`<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:${i}"></span>`} ${t.seriesName}: <strong style="float: right; margin-left:20px">${t.data?d(n):"-"}</strong></div>`;var i;r+=o})),r}function v(t){return d(t)}function S(){const t=$("#formFilterDates").find("input"),e=[];$(t).each(((t,r)=>{r.checked&&e.push(r.id)})),Dashboards.fireChange("filterDatesParam",e),Dashboards.fireChange("updateFilter","True")}function M(){const t=$("#formFilterDates").find("input");$(t).each(((t,e)=>{e.checked&&(e.checked=!1)}));const e=$("#formFilterVar").find("input");$(e).each(((t,e)=>{e.checked&&(e.checked=!1)})),function(){let t=0;const e=$("#formFilterDates").find("input");$(e).each(((e,r)=>{t+=1,r.checked=!0})),t=0;const r=$("#formFilterVar").find("input");$(r).each(((e,r)=>{t+=1,null!=render_tableVariacio?t<=2&&(r.checked=!0):t<=3&&(r.checked=!0)})),console.error(`VALORES FILTRO: ${Dashboards.getParameterValue("filterVarParam")}`),Dashboards.getParameterValue("filterVarParam").length>0&&Dashboards.fireChange("filterVarParam")}()}function E(t){return{1:"Gen",2:"Feb",3:"Mar",4:"Abr",5:"Mai",6:"Jun",7:"Jul",8:"Ago",9:"Sep",10:"Oct",11:"Nov",12:"Des"}[parseInt(t.toString(),10)]}function k(t){return{1:"GENER",2:"FEBRER",3:"MARÇ",4:"ABRIL",5:"MAIG",6:"JUNY",7:"JULIO",8:"AGOST",9:"SETEMBRE",10:"OCTUBRE",11:"NOVEMBRE",12:"DESEMBRE"}[t]}function A(t,e){const r=t?document.querySelector(t):null,n=e?document.querySelector(e):null;r&&(r.hidden=!0),n&&(n.style.background="url('./build/images/nodata1.png') no-repeat top center",n.hidden=!1)}function x(t,e){const r=t?document.querySelector(t):null,n=e?document.querySelector(e):null;r&&(r.hidden=!0),n&&(n.style.background="#ffffff",n.hidden=!1)}function I(t,e){return t.reduce(((t,r)=>{const n=r[e];return t[n]||(t[n]=[]),t[n].push(r),t}),{})}function O(t,e,r=1){const n=Math.max(...t.map((t=>t[e])))*r;return 5e3*Math.ceil(n/5e3)}function P(t){return Math.round(document.getElementById(t).offsetWidth/l)}function T(t,e,r){const n=d(Math.round(e)),o=E(t[r][0]),i=t[r][1],s=`\n\n\n${o} ${i} : ${n}`,a=`${n}\n${o} ${i}`;return window.innerWidth<=1710?s:a}function _(r,n,p,l,h,y,g,d=5,b="",w=h,S=100,M,E=void 0,k=void 0){return{title:{text:b,left:"center",top:"top",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"axis",show:!0,formatter:t=>m(t),textStyle:{fontFamily:"Montserrat"}},legend:n?{type:"plain",data:n,textStyle:{fontFamily:"Montserrat"},top:E||t,selected:M}:null,grid:{left:e,right:o,bottom:i,top:n?E?"30%":s:a,heigh:u,containLabel:!0},xAxis:{type:"category",data:p,boundaryGap:!1,splitLine:{show:!1},axisLabel:{textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#666"}}},yAxis:{name:l,nameLocation:"end",nameTextStyle:{fontFamily:"Montserrat",fontWeight:"bold",padding:[0,0,0,g]},type:"value",scale:!0,min:k,axisLabel:{margin:d,formatter:v,textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#666"}}},series:r,dataZoom:[{show:y,data:p,start:w,end:S,borderColor:"#eee",fillerColor:"rgba(0,0,0,.05)",textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#333",textBorderColor:"#fff",textBorderWidth:3,fontWeight:"600"},selectedDataBackground:{lineStyle:{color:"#333"},areaStyle:{color:"#ffcd00"}},dataBackground:{backgroundColor:"rgba(0,0,0,1)",lineStyle:{color:"#333"},areaStyle:{color:"rgba(0,0,0,0.5)"}},handleStyle:{color:"rgba(0,0,0,0.2)"},moveHandleStyle:{color:"rgba(0,0,0,0.3)"},emphasis:{handleStyle:{color:"rgba(255,205,0,1)"},moveHandleStyle:{color:"rgba(255,205,0,1)"}}}],toolbox:{show:y,feature:{restore:{title:"Restablir"},saveAsImage:{title:"Desar"}},right:c,top:f}}}function B(t,r,n,a,c="",f="total",l=0,h=1,y=2,g=p){if(0===n.length)A(`#${t}`,`#${r}`);else{x(`#${r}`,`#${t}`);const p=[];let S=I(n,l);const M=new Set(n.map((t=>t[h]))),E=Object.keys(S);M.forEach((t=>{E.forEach((e=>{void 0===S[e].find((e=>e[h]===t))&&(S[e].push([S[e][0][l],t,void 0]),S[e][0][1].length>4?S[e].sort(((t,e)=>{const[r,n]=t[1].split("/"),[o,i]=e[1].split("/"),s=new Date(n,r-1,1),a=new Date(i,o-1,1);return s.getTime()-a.getTime()})):S[e].sort())}))}));const k=Object.entries(S).sort(((t,e)=>t[0].localeCompare(e[0]))),A=""===f?90:0;S=Object.fromEntries(k),Object.keys(S).forEach((t=>{p.push({name:t,type:"bar",stack:f,label:{show:!0,fontFamily:"Montserrat",rotate:A,formatter:t=>d(Math.round(t.value))},emphasis:{focus:"series"},data:S[t].map((t=>t[y]))})}));const O=""!==f?b(M.size):w(M.size);Y(t,{color:g,title:{text:c,left:"center",top:"top",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"},textStyle:{fontFamily:"Montserrat"},formatter:t=>m(t,!0)},legend:{padding:40,textStyle:{fontFamily:"Montserrat"}},grid:{left:e,right:o,bottom:i,top:s,heigh:u,containLabel:!0},yAxis:{type:"value",splitNumber:4,name:a,nameLocation:"end",nameTextStyle:{fontWeight:"bold",fontFamily:"Montserrat",color:"#666"},axisLabel:{formatter:v,textStyle:{fontSize:8,fontFamily:"Montserrat",color:"#666"}}},xAxis:{type:"category",data:[...M],axisLabel:{textStyle:{fontFamily:"Montserrat"}}},series:p,toolbox:{show:!0,feature:{restore:{title:"Restablir"},saveAsImage:{title:"Desar"}},right:50},dataZoom:[{show:!0,data:[...M],start:O,end:100,borderColor:"#eee",fillerColor:"rgba(0,0,0,.05)",textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#333",textBorderColor:"#fff",textBorderWidth:3,fontWeight:"600"},selectedDataBackground:{lineStyle:{color:"#333"},areaStyle:{color:"#ffcd00"}},dataBackground:{backgroundColor:"rgba(0,0,0,1)",lineStyle:{color:"#333"},areaStyle:{color:"rgba(0,0,0,0.5)"}},handleStyle:{color:"rgba(0,0,0,0.2)"},moveHandleStyle:{color:"rgba(0,0,0,0.3)"},emphasis:{handleStyle:{color:"rgba(255,205,0,1)"},moveHandleStyle:{color:"rgba(255,205,0,1)"}}}]})}}function R(t,e,r,n,o,i,s){if(0===o.length)A(`#${t}`,`#${r}`),A(`#${e}`,`#${n}`);else{x(`#${r}`,`#${t}`),x(`#${n}`,`#${e}`);const a=0,u=2,c=H(o,u,1),f=c[0],p=c[1],l=c[2],h=c[3],y=c[5],g=P(t),d=J(f,u,a,y,g),b=J(p,u,a,y,g);Y(t,G(`${i}${k(String(Object.keys(l)[1]))}`,h,d,g)),Y(e,G(`${s}${k(String(Object.keys(l)[0]))}`,h,b,g))}}function U(t,e,r,n){0===r.length?A(`#${t}`,`#${e}`):x(`#${e}`,`#${t}`);const o=O(r,1,1.1),i=P(t);let s=180;o>9999999&&(s=95);const a=J(r,1,0,s,i);Y(t,G(`${n} ${r[0][2]}`,o,a,i))}function F(t,e,r=-45,n="",o=e){const i=new Set,s=[];t.forEach((t=>{const e=t[0].toString().padStart(2,"0");i.add(`${e}/${t[1]}`),s.push(Math.round(t[2]))}));const a=s.length<100?40:80;return _({name:o,type:"bar",smooth:!1,barMaxWidth:40,itemStyle:{color:"#5470c6"},textStyle:{fontFamily:"Montserrat"},data:s},null,Array.from(i.values()),e,a,!0,r,25,n)}function W(t,e){const r=`<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:${t.color};"></span>`;let n=`${t.name} : `;return n+=`<span style="font-weight:bold">${d(t.value)}</span>`,e&&(n+=`<span> (${t.percent}%)</span>`),r+n}function j(t,e,r,n){return{series:[{type:"gauge",center:["50%","50%"],startAngle:200,endAngle:-20,min:0,max:100,splitNumber:0,progress:{show:!1,width:5,itemStyle:{color:"#666"}},axisLine:{lineStyle:{width:18}},axisTick:{show:!1},splitLine:{length:15,lineStyle:{width:2,color:"#999"}},axisLabel:{distance:25,color:"#999",fontSize:20,show:!1},anchor:{show:!0,showAbove:!0,size:25,itemStyle:{borderWidth:10},show:!1},pointer:{show:!0,icon:"path://M12.8,0.7l12,40.1H0.7L12.8,0.7z",length:"12%",width:20,offsetCenter:[0,"-40%"],itemStyle:{color:"#ccc"}},axisLine:{lineStyle:{width:35,color:[[e,"#e56b6f"],[e+r,"#ffbf69"],[1,"#a1c483"]]}},axisTick:{show:!1},splitLine:{show:!1},axisLabel:{show:!1},title:{show:!0,offsetCenter:[0,"45%"],textStyle:{color:"#000",fontStyle:"normal",fontWeight:"400",fontFamily:"Montserrat",fontSize:15}},detail:{fontSize:30,offsetCenter:[0,"90%"],valueAnimation:!0,color:"#666",textStyle:{color:"#000",fontStyle:"normal",fontWeight:"400",fontFamily:"Montserrat",fontSize:35}},data:[{value:t,name:n}]}]}}function N(t,e,r,n){return{tooltip:{trigger:"item",formatter:t=>W(t,!1),textStyle:{fontSize:13.5,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},title:{text:e,left:"center",top:"40%",textStyle:{fontSize:13.5,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},legend:{left:"center",bottom:"0%",textStyle:{fontSize:10,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},series:[{top:"0%",bottom:"15%",type:"pie",radius:r||["65%","75%"],avoidLabelOverlap:!1,itemStyle:{borderRadius:5,borderColor:"#f1f1f1",borderWidth:1},label:{show:!1,position:"center",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},emphasis:{label:{show:!1,fontSize:20}},labelLine:{show:!1},color:n||["#fcb9b2","#ffd97d","#64a6bd","#98c9a3","#ff9b85"],data:t}]}}function Z(t,e,r,n=p){return{textStyle:{fontFamily:"Montserrat"},title:{text:t,left:"center",top:"top",padding:10,textStyle:{fontSize:r-4,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"item",textStyle:{fontFamily:"Montserrat"},formatter:t=>W(t,!0)},legend:{orient:"horizontal",textStyle:{fontFamily:"Montserrat"},left:e.length>5?"10%":"12%",bottom:"10%",top:"65%",selectedMode:!1},series:[{type:"pie",radius:"33%",data:e,color:n,top:"-30%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}],toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:10,top:20}}}function G(t,e,r,n){return{color:p,title:{text:t,left:"center",top:"top",padding:10,textStyle:{fontSize:n,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{show:!0,textStyle:{fontFamily:"Montserrat"},formatter:t=>W(t,!1)},splitNumber:3,series:{type:"gauge",max:e,startAngle:-180,endAngle:0,splitNumber:2,pointer:{show:!1,icon:"roundRect"},progress:{show:!0,overlap:!1,roundCap:!0,clip:!0,itemStyle:{borderWidth:1,borderColor:"#464646"}},axisLine:{lineStyle:{width:60}},splitLine:{show:!0,distance:10,length:10},axisTick:{show:!0,splitNumber:5},axisLabel:{show:!0,distance:70,formatter:t=>d(Math.round(t)),fontFamily:"Montserrat",color:"#666"},data:r,detail:{fontSize:n/1.2,color:"inherit",formatter:t=>d(Math.round(t))}},toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:y,top:g}}}function C(t,e="",r){const n=[],o=O(t,1,1.1),i=o.toString().length>=9?100:95,s=115===i?-45:-35;let a=t.length<5?t.length*s:-190;for(let e=0;e<t.length;e+=1)n.push({value:t[e][1],name:String(t[e][0]),title:{offsetCenter:[String(a),"20%"],fontFamily:"Montserrat"},detail:{offsetCenter:[String(a),"35%"],fontFamily:"Montserrat"}}),a+=i;return G(e,o,n,r)}function D(t,e,r="",n){return{title:{text:r,left:"center",top:"top",padding:10,textStyle:{fontSize:n,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},series:{type:"gauge",startAngle:-180,endAngle:0,splitNumber:2,max:O(t,2),itemStyle:{color:"#FFAB91"},progress:{show:!0,width:30},pointer:{show:!1},axisLine:{lineStyle:{width:30}},axisTick:{distance:10,splitNumber:5,lineStyle:{width:2,color:"#999"}},splitLine:{distance:10,length:14,lineStyle:{width:3,color:"#999"}},axisLabel:{fontFamily:"Montserrat",color:"#666",fontSize:14,show:!0,distance:40,formatter:t=>d(Math.round(t))},anchor:{show:!1},title:{show:!1},detail:{valueAnimation:!0,width:"60%",lineHeight:40,borderRadius:8,offsetCenter:[-5,"-10%"],fontSize:n+5,fontWeight:"bolder",formatter:r=>T(t,r,e),fontFamily:"Montserrat",color:"inherit"},data:[{value:t[e][2]}]},toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:y,top:g}}}function z(t){if(t.length>=29){const e=t.split(" ");let r="",n="";for(const t of e)`${r} ${t}`.length<=29?r+=(r?" ":"")+t:(n+=`${r}\n`,r=t);return n+=r,n}return t}function J(t,e,r,n,o){let i=20,s=35,a=-190,u=n;t.length<=2&&(a=-140,u+=100,i=25,s=42);const c=p.slice(),f=[];for(let n=0;n<t.length;n+=1)f.push({value:t[n][e],name:z(t[n][r]),color:c.shift(),title:{offsetCenter:[String(a),`${String(i)}%`],fontFamily:"Montserrat",fontSize:o-3},detail:{offsetCenter:[String(a),`${String(s)}%`],fontFamily:"Montserrat"}}),a+=u,(n+1)%3==0&&(s+=30,i+=30,a=-190);return f}function V(t,e,r=!1){const{resultset:n}={resultset:t},o=new Set,i=new Set,s=e,a=n.map((([t,e,n])=>{const s=r?Math.round(n):n;return o.add(t),i.add(e),{day:e,type:t,value:s}})),u=Array.from(i.values()),c=Array.from(o.values());return c.sort(((t,e)=>t.toLowerCase().localeCompare(e.toLowerCase(),"es",{ignorePunctuation:!0}))),[c.map((t=>{const e=a.filter((e=>e.type===t)).map((({day:e,value:r})=>[e,t,r])),r=u.map((t=>{const r=e.find((([e])=>e===t));return r?r[2]:null}));return{name:t,type:"line",symbol:"circle",color:s.shift(),symbolSize:6,smooth:!1,data:r}})),i,c]}function H(t,e,r){const n=O(t,e,1.1);let o=50,i=180;n>9999999&&(o=65,i=95);const s=I(t,r);let[a,u]=Object.values(s);return Object.values(s).slice(1).forEach((t=>{u=t})),[u,a,s,n,o,i]}function Y(t,e){const r=document.getElementById(t);if(!r)return console.error(`No se pudo encontrar el elemento con ID ${t}.`),null;const n=echarts.init(r);return n.setOption(e,!0),$(window).on("resize",(()=>{null!=n&&void 0!==n&&n.resize()})),n}function q(){$("#chart2").css("width","100%")}function X(){let t,e,r,n;const o=document.getElementsByTagName("*");for(t=0;t<o.length;t+=1)if(e=o[t],r=e.getAttribute("include-html-cabecera"),r)return n=new XMLHttpRequest,n.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(e.innerHTML=this.responseText),404===this.status&&(e.innerHTML="No se ha podido cargar correctamente."))},n.open("GET",r,!0),void n.send()}function K(t){let e,r,n,o;const i=document.getElementsByTagName("*");for(e=0;e<i.length;e+=1)if(r=i[e],n=r.getAttribute("include-html-menu"),n)return o=new XMLHttpRequest,o.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(r.innerHTML=this.responseText,$(t).removeClass("imgNavMenu"),$(t).addClass("imgNavMenuActive")),404===this.status&&(r.innerHTML="No se ha podido cargar correctamente."))},o.open("GET",n,!0),void o.send()}function Q(){let t,e,r,n;const o=document.getElementsByTagName("*");for(t=0;t<o.length;t+=1)if(e=o[t],r=e.getAttribute("include-html-footer"),r)return n=new XMLHttpRequest,n.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(e.innerHTML=this.responseText),404===this.status&&(e.innerHTML="No se ha podido cargar correctamente."))},n.open("GET",r,!0),void n.send()}function tt(t,e){0!==t.childNodes[1].childNodes.length?$(`#${t.children[0].children[0].children[0].children[0].id}`).attr("src",`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages/${t.children[0].children[0].children[0].children[0].src.split("/").pop().split(".")[0]}_hover.svg}`):t.children[0].src=`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages%3A${e}_hover.svg/content`}function et(t,e){0!=t.childNodes[1].childNodes.length?$(`#${t.children[0].children[0].children[0].children[0].id}`).attr("src",`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages/${t.children[0].children[0].children[0].children[0].src.split("/").pop().split("_")[0]}.svg}`):t.children[0].src=`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages%3A${e}.svg/content`}function rt(t){document.location=`${document.documentURI.split("%3A")[0]}%3A${document.documentURI.split("%3A")[1]}%3A${document.documentURI.split("%3A")[2]}%3A${document.documentURI.split("%3A")[3]}%3A${t}`}function nt(t){return`${document.documentURI.split("%3A")[0]}%3A${document.documentURI.split("%3A")[1]}%3A${document.documentURI.split("%3A")[2]}%3A${document.documentURI.split("%3A")[3]}%3A${t}`}function ot(t){$(document).click((()=>{const t=$("#layoutFilter");t.is(event.target)||t.has(event.target).length||t.hide()})),X(),K(t),Q()}function it(t,e,r){const n=$("#formFilterDates");if(""===Dashboards.getParameterValue("updateFilter")){const r=new Set;for(let n=t-1;n>0;--n)r.add(e[n]);for(const[t,e]of r.entries())n.append(`<input type="checkbox" id="${t}" onclick="legacy.filterDatesUpdate();" />${e}<br /></input>`);M(),S()}}function st(){const t=$("#idFilterVar").find("input"),e=[];$(t).each(((t,r)=>{r.checked&&e.push(r.id.replaceAll("/","-"))})),Dashboards.fireChange("filterVarParam",e),Dashboards.fireChange("updateFilterVar","True")}function at(t,e){const r=new Event("tableCreated"),n=$("#formFilterVar");if(""===Dashboards.getParameterValue("updateFilterVar")){for(let t=e.length-1;t>=0;t--)n.append(`<input type="checkbox" id="${e[t]}" onclick="legacy.filterVarUpdate();" />${e[t]}<br /></input>`);M(),st()}console.error("Dispatching tableCreated event..."),document.dispatchEvent(r),console.error("tableCreated event dispatched.")}function ut(t){return t.replace(/^(\d{4})[-|\/](\d{2})[-|\/](\d{2})$/g,"$3/$2/$1")}function ct(t){return t.replace(/^(\d{4})(\d{2})(\d{2})$/g,"$3/$2/$1")}function ft(t){const e=`20${t.slice(0,2)}`,r=t.slice(2,4);return`${t.slice(4,6)}/${r}/${e}`}function pt(t,e){const r=t.slice(0,2),n=t.slice(3,6);let o;return o=null==e?`20${t.slice(7,9)}`:`20${e.slice(5,7)}`,2===o.length&&(o="2022"),`${r}/${{Gen:"01",Feb:"02",Mar:"03",Abr:"04",Mai:"05",Jun:"06",Jul:"07",Ago:"08",Sep:"09",Oct:"10",Nov:"11",Des:"12"}[n]}/${o}`}function lt(t){let e=t.getUTCDate().toString();1===e.length&&(e=`0${e}`);let r=(t.getMonth()+1).toString();return 1===r.length&&(r=`0${r}`),`${e}/${r}/${t.getFullYear().toString()}`}function ht(t){const e=t.slice(0,2);return`${t.slice(3,5)}/${e}`}function yt(t){const e=t.toString().match(/(\d{2}:\d{2})/);return e?e[1]:null}function gt(t){return 100*(t-120)/t}function dt(t){return Array.from(t.values()).map((t=>{const[e,r]=t.split("/");return ht(t)}))}function bt(t,e,r,n,o,i,s,a,u=!1,c=!1,f=void 0,l=!0,h=p.slice(),y=!1,g=void 0,d=void 0){const w=t.resultset||t;if(0===w.length)A(`#${i}`,`#${s}`),a&&A(`#${a}`,`#${s}`);else{x(`#${s}`,`#${i}`),a&&x(`#${s}`,`#${a}`);const t=V(w,h,y),p=t[0],m=t[1],v=t[2],S=l?v:null,M=c?dt(m):Array.from(m.values());void 0===f&&(f=u?b(m.size):gt(m.size)),Y(i,_(p,S,M,o,f,e,r,void 0,n,void 0,void 0,void 0,g,d))}}function wt(t,e,r=!1){const n=[],o=1.1*O(t,1);let i,s=50,a=250,u=20,c=30,f=-80;o>9999999&&(s=65,a=75);const p=r?4:3;for(let r=0;r<t.length;r+=1)i=String(t[r][0]).replace(/\[.*?\]/g,""),i=z(i),n.push({value:t[r][1],name:i,title:{offsetCenter:[`${String(f)}%`,`${String(u)}%`],fontFamily:"Montserrat",fontSize:e},detail:{offsetCenter:[`${String(f)}%`,`${String(c)}%`],fontFamily:"Montserrat",fontSize:e}}),f+=a,(r+1)%p==0&&(c+=30,u+=30,f=-80);return[o,n,s]}function mt(t){const e=t.split("/"),r=parseInt(e[0],10),n=parseInt(e[1],10)-1,o=parseInt(e[2],10);return new Date(o,n,r)}function vt(t){return`${String(t.getDate()).padStart(2,"0")}/${String(t.getMonth()+1).padStart(2,"0")}/${String(t.getFullYear())}`}function St(t,e){const r=[];for(;t<=e;){const e=vt(t);r.push(e),t.setDate(t.getDate()+1)}return r}function Mt(t){const e=Array.from(t.keys(),(t=>mt(t))),r=[],n=[],o=St(new Date(Math.min(...e)),new Date(Math.max(...e)));return o.forEach((e=>{if(t.has(e)){const r=t.get(e);n.push(r)}else n.push(null)})),r.push(o),r.push(n),r}function Et(){$("#idPopupInfo").show()}function kt(){$("#idPopupInfo").hide()}function At(){const t=$("#layoutFilter");"none"===t.css("display")?t.show():t.hide()}function xt(){$("#layoutFilter").hide()}let It;function Ot(t,e,r,n,o,i,s,a=!1){const u=_t(r,e.id,e.addres,e.location),c=L.map(t).setView(h,s?s.initialZoom:13),f=L.tileLayer("https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png",{attribution:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors &copy; <a href="https://carto.com/attributions">CARTO</a>',subdomains:"abcd",maxZoom:20});c.setMinZoom(s?s.minZoom:5),c.setMaxZoom(s?s.maxZoom:20),f.addTo(c),Rt(c,u,r,e,a,n,o,i)}function Pt(t="myMap",e=5,r=20,n=13,o,i,s,a){const u=L.map(t).setView([39.46975,-.37739],n),c=L.tileLayer("https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png",{attribution:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors &copy; <a href="https://carto.com/attributions">CARTO</a>',subdomains:"abcd",maxZoom:20});u.setMinZoom(e),u.setMaxZoom(r),c.addTo(u),Bt(u,o,i,s,Tt(),a)}function Tt(){return{listOfselectedElements:[],elementExist(t){return this.listOfselectedElements.filter((e=>e===t)).length>0},deleteElementOfList(t){const e=this.listOfselectedElements.indexOf(t);e>-1&&this.listOfselectedElements.splice(e,1)}}}function _t(t,e=0,n=1,o=2){const{Buffer:i}=r(8287),s=r(543),a={type:"FeatureCollection",features:[]},u=[],c=new Set;return t.forEach((t=>{const e=t[o];c.has(e)||(c.add(e),u.push(t))})),u.forEach((t=>{const r=s.Geometry.parse(i.from(t[o],"hex")),u={type:"Feature",properties:{objectoId:t[e],address:t[n]},geometry:r.toGeoJSON()};a.features.push(u)})),a}function Bt(t,e,r,n,o,i){function s(t){return{iconUrl:nt(t),iconSize:[34,34],shadowSize:[50,64],iconAnchor:[17,17],shadowAnchor:[4,62],popupAnchor:[-3,-76]}}const a=L.icon(s(r)),u=L.icon(s(n));L.geoJSON(e,{onEachFeature:function(s,a){s.properties&&s.properties.address&&a.on("click",(()=>{o.elementExist(s.properties.objectoId)?o.deleteElementOfList(s.properties.objectoId):o.listOfselectedElements.push(s.properties.objectoId),i&&Dashboards.fireChange(i,o.listOfselectedElements),Bt(t,e,r,n,o,i)}))},pointToLayer(t,e){let r=a;return o.elementExist(t.properties.objectoId)&&(r=u),L.marker(e,{icon:r})}}).addTo(t)}function Rt(t,e,r,n,o,i,s,a){L.geoJSON(e,{onEachFeature(t,e){t.properties.address===s&&(It=e),function(t,e,r,n,o){const i=r.properties.address,s=r.properties.objectoId;r.properties&&i&&n.on("click",(()=>{const r=t.filter((t=>t[e.id]===s));o(r,i)}))}(r,n,t,e,a),function(t,e,r,n){const o=t.properties.address;r&&(e.on("mouseover",(()=>{e.bindPopup(o).openPopup()})),e.on("mouseout",(()=>{e.closePopup()}))),e.on("click",(()=>{It?(It.setStyle(n.unselected),e.setStyle(n.selected)):e.setStyle(n.selected),It=e}))}(t,e,o,i)},style:t=>t.properties.address===s?i.selected:i.unselected}).addTo(t)}})(),n})()));
2
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.legacy=e():t.legacy=e()}(self,(()=>(()=>{var t={7526:(t,e)=>{"use strict";e.byteLength=function(t){var e=a(t),r=e[0],n=e[1];return 3*(r+n)/4-n},e.toByteArray=function(t){var e,r,i=a(t),s=i[0],u=i[1],c=new o(function(t,e,r){return 3*(e+r)/4-r}(0,s,u)),f=0,p=u>0?s-4:s;for(r=0;r<p;r+=4)e=n[t.charCodeAt(r)]<<18|n[t.charCodeAt(r+1)]<<12|n[t.charCodeAt(r+2)]<<6|n[t.charCodeAt(r+3)],c[f++]=e>>16&255,c[f++]=e>>8&255,c[f++]=255&e;return 2===u&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,c[f++]=255&e),1===u&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,c[f++]=e>>8&255,c[f++]=255&e),c},e.fromByteArray=function(t){for(var e,n=t.length,o=n%3,i=[],s=16383,a=0,c=n-o;a<c;a+=s)i.push(u(t,a,a+s>c?c:a+s));return 1===o?(e=t[n-1],i.push(r[e>>2]+r[e<<4&63]+"==")):2===o&&(e=(t[n-2]<<8)+t[n-1],i.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0;s<64;++s)r[s]=i[s],n[i.charCodeAt(s)]=s;function a(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function u(t,e,n){for(var o,i,s=[],a=e;a<n;a+=3)o=(t[a]<<16&16711680)+(t[a+1]<<8&65280)+(255&t[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},8287:(t,e,r)=>{"use strict";const n=r(7526),o=r(251),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=u,e.SlowBuffer=function(t){return+t!=t&&(t=0),u.alloc(+t)},e.INSPECT_MAX_BYTES=50;const s=2147483647;function a(t){if(t>s)throw new RangeError('The value "'+t+'" is invalid for option "size"');const e=new Uint8Array(t);return Object.setPrototypeOf(e,u.prototype),e}function u(t,e,r){if("number"==typeof t){if("string"==typeof e)throw new TypeError('The "string" argument must be of type string. Received type number');return p(t)}return c(t,e,r)}function c(t,e,r){if("string"==typeof t)return function(t,e){if("string"==typeof e&&""!==e||(e="utf8"),!u.isEncoding(e))throw new TypeError("Unknown encoding: "+e);const r=0|g(t,e);let n=a(r);const o=n.write(t,e);return o!==r&&(n=n.slice(0,o)),n}(t,e);if(ArrayBuffer.isView(t))return function(t){if(Y(t,Uint8Array)){const e=new Uint8Array(t);return h(e.buffer,e.byteOffset,e.byteLength)}return l(t)}(t);if(null==t)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(Y(t,ArrayBuffer)||t&&Y(t.buffer,ArrayBuffer))return h(t,e,r);if("undefined"!=typeof SharedArrayBuffer&&(Y(t,SharedArrayBuffer)||t&&Y(t.buffer,SharedArrayBuffer)))return h(t,e,r);if("number"==typeof t)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return u.from(n,e,r);const o=function(t){if(u.isBuffer(t)){const e=0|y(t.length),r=a(e);return 0===r.length||t.copy(r,0,0,e),r}return void 0!==t.length?"number"!=typeof t.length||q(t.length)?a(0):l(t):"Buffer"===t.type&&Array.isArray(t.data)?l(t.data):void 0}(t);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return u.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function f(t){if("number"!=typeof t)throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function p(t){return f(t),a(t<0?0:0|y(t))}function l(t){const e=t.length<0?0:0|y(t.length),r=a(e);for(let n=0;n<e;n+=1)r[n]=255&t[n];return r}function h(t,e,r){if(e<0||t.byteLength<e)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return n=void 0===e&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,e):new Uint8Array(t,e,r),Object.setPrototypeOf(n,u.prototype),n}function y(t){if(t>=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|t}function g(t,e){if(u.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||Y(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);const r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return J(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return V(t).length;default:if(o)return n?-1:J(t).length;e=(""+e).toLowerCase(),o=!0}}function d(t,e,r){let n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return T(this,e,r);case"utf8":case"utf-8":return A(this,e,r);case"ascii":return O(this,e,r);case"latin1":case"binary":return P(this,e,r);case"base64":return k(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return _(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function b(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}function w(t,e,r,n,o){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),q(r=+r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof e&&(e=u.from(e,n)),u.isBuffer(e))return 0===e.length?-1:m(t,e,r,n,o);if("number"==typeof e)return e&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):m(t,[e],r,n,o);throw new TypeError("val must be string, number or Buffer")}function m(t,e,r,n,o){let i,s=1,a=t.length,u=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}function c(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(o){let n=-1;for(i=r;i<a;i++)if(c(t,i)===c(e,-1===n?0:i-n)){if(-1===n&&(n=i),i-n+1===u)return n*s}else-1!==n&&(i-=i-n),n=-1}else for(r+u>a&&(r=a-u),i=r;i>=0;i--){let r=!0;for(let n=0;n<u;n++)if(c(t,i+n)!==c(e,n)){r=!1;break}if(r)return i}return-1}function v(t,e,r,n){r=Number(r)||0;const o=t.length-r;n?(n=Number(n))>o&&(n=o):n=o;const i=e.length;let s;for(n>i/2&&(n=i/2),s=0;s<n;++s){const n=parseInt(e.substr(2*s,2),16);if(q(n))return s;t[r+s]=n}return s}function S(t,e,r,n){return H(J(e,t.length-r),t,r,n)}function M(t,e,r,n){return H(function(t){const e=[];for(let r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function x(t,e,r,n){return H(V(e),t,r,n)}function E(t,e,r,n){return H(function(t,e){let r,n,o;const i=[];for(let s=0;s<t.length&&!((e-=2)<0);++s)r=t.charCodeAt(s),n=r>>8,o=r%256,i.push(o),i.push(n);return i}(e,t.length-r),t,r,n)}function k(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function A(t,e,r){r=Math.min(t.length,r);const n=[];let o=e;for(;o<r;){const e=t[o];let i=null,s=e>239?4:e>223?3:e>191?2:1;if(o+s<=r){let r,n,a,u;switch(s){case 1:e<128&&(i=e);break;case 2:r=t[o+1],128==(192&r)&&(u=(31&e)<<6|63&r,u>127&&(i=u));break;case 3:r=t[o+1],n=t[o+2],128==(192&r)&&128==(192&n)&&(u=(15&e)<<12|(63&r)<<6|63&n,u>2047&&(u<55296||u>57343)&&(i=u));break;case 4:r=t[o+1],n=t[o+2],a=t[o+3],128==(192&r)&&128==(192&n)&&128==(192&a)&&(u=(15&e)<<18|(63&r)<<12|(63&n)<<6|63&a,u>65535&&u<1114112&&(i=u))}}null===i?(i=65533,s=1):i>65535&&(i-=65536,n.push(i>>>10&1023|55296),i=56320|1023&i),n.push(i),o+=s}return function(t){const e=t.length;if(e<=I)return String.fromCharCode.apply(String,t);let r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=I));return r}(n)}e.kMaxLength=s,u.TYPED_ARRAY_SUPPORT=function(){try{const t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}(),u.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}}),u.poolSize=8192,u.from=function(t,e,r){return c(t,e,r)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array),u.alloc=function(t,e,r){return function(t,e,r){return f(t),t<=0?a(t):void 0!==e?"string"==typeof r?a(t).fill(e,r):a(t).fill(e):a(t)}(t,e,r)},u.allocUnsafe=function(t){return p(t)},u.allocUnsafeSlow=function(t){return p(t)},u.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==u.prototype},u.compare=function(t,e){if(Y(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),Y(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(t)||!u.isBuffer(e))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;let r=t.length,n=e.length;for(let o=0,i=Math.min(r,n);o<i;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:n<r?1:0},u.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(t,e){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return u.alloc(0);let r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;const n=u.allocUnsafe(e);let o=0;for(r=0;r<t.length;++r){let e=t[r];if(Y(e,Uint8Array))o+e.length>n.length?(u.isBuffer(e)||(e=u.from(e)),e.copy(n,o)):Uint8Array.prototype.set.call(n,e,o);else{if(!u.isBuffer(e))throw new TypeError('"list" argument must be an Array of Buffers');e.copy(n,o)}o+=e.length}return n},u.byteLength=g,u.prototype._isBuffer=!0,u.prototype.swap16=function(){const t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let e=0;e<t;e+=2)b(this,e,e+1);return this},u.prototype.swap32=function(){const t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let e=0;e<t;e+=4)b(this,e,e+3),b(this,e+1,e+2);return this},u.prototype.swap64=function(){const t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let e=0;e<t;e+=8)b(this,e,e+7),b(this,e+1,e+6),b(this,e+2,e+5),b(this,e+3,e+4);return this},u.prototype.toString=function(){const t=this.length;return 0===t?"":0===arguments.length?A(this,0,t):d.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(t){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===u.compare(this,t)},u.prototype.inspect=function(){let t="";const r=e.INSPECT_MAX_BYTES;return t=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(t+=" ... "),"<Buffer "+t+">"},i&&(u.prototype[i]=u.prototype.inspect),u.prototype.compare=function(t,e,r,n,o){if(Y(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),!u.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return-1;if(e>=r)return 1;if(this===t)return 0;let i=(o>>>=0)-(n>>>=0),s=(r>>>=0)-(e>>>=0);const a=Math.min(i,s),c=this.slice(n,o),f=t.slice(e,r);for(let t=0;t<a;++t)if(c[t]!==f[t]){i=c[t],s=f[t];break}return i<s?-1:s<i?1:0},u.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},u.prototype.indexOf=function(t,e,r){return w(this,t,e,r,!0)},u.prototype.lastIndexOf=function(t,e,r){return w(this,t,e,r,!1)},u.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const o=this.length-e;if((void 0===r||r>o)&&(r=o),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let i=!1;for(;;)switch(n){case"hex":return v(this,t,e,r);case"utf8":case"utf-8":return S(this,t,e,r);case"ascii":case"latin1":case"binary":return M(this,t,e,r);case"base64":return x(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,t,e,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const I=4096;function O(t,e,r){let n="";r=Math.min(t.length,r);for(let o=e;o<r;++o)n+=String.fromCharCode(127&t[o]);return n}function P(t,e,r){let n="";r=Math.min(t.length,r);for(let o=e;o<r;++o)n+=String.fromCharCode(t[o]);return n}function T(t,e,r){const n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);let o="";for(let n=e;n<r;++n)o+=X[t[n]];return o}function _(t,e,r){const n=t.slice(e,r);let o="";for(let t=0;t<n.length-1;t+=2)o+=String.fromCharCode(n[t]+256*n[t+1]);return o}function B(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function R(t,e,r,n,o,i){if(!u.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>o||e<i)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function U(t,e,r,n,o){C(e,n,o,t,r,7);let i=Number(e&BigInt(4294967295));t[r++]=i,i>>=8,t[r++]=i,i>>=8,t[r++]=i,i>>=8,t[r++]=i;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,s>>=8,t[r++]=s,r}function F(t,e,r,n,o){C(e,n,o,t,r,7);let i=Number(e&BigInt(4294967295));t[r+7]=i,i>>=8,t[r+6]=i,i>>=8,t[r+5]=i,i>>=8,t[r+4]=i;let s=Number(e>>BigInt(32)&BigInt(4294967295));return t[r+3]=s,s>>=8,t[r+2]=s,s>>=8,t[r+1]=s,s>>=8,t[r]=s,r+8}function L(t,e,r,n,o,i){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function $(t,e,r,n,i){return e=+e,r>>>=0,i||L(t,0,r,4),o.write(t,e,r,n,23,4),r+4}function j(t,e,r,n,i){return e=+e,r>>>=0,i||L(t,0,r,8),o.write(t,e,r,n,52,8),r+8}u.prototype.slice=function(t,e){const r=this.length;(t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e<t&&(e=t);const n=this.subarray(t,e);return Object.setPrototypeOf(n,u.prototype),n},u.prototype.readUintLE=u.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t],o=1,i=0;for(;++i<e&&(o*=256);)n+=this[t+i]*o;return n},u.prototype.readUintBE=u.prototype.readUIntBE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t+--e],o=1;for(;e>0&&(o*=256);)n+=this[t+--e]*o;return n},u.prototype.readUint8=u.prototype.readUInt8=function(t,e){return t>>>=0,e||B(t,1,this.length),this[t]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(t,e){return t>>>=0,e||B(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(t,e){return t>>>=0,e||B(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(t,e){return t>>>=0,e||B(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(t,e){return t>>>=0,e||B(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readBigUInt64LE=K((function(t){G(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=e+256*this[++t]+65536*this[++t]+this[++t]*2**24,o=this[++t]+256*this[++t]+65536*this[++t]+r*2**24;return BigInt(n)+(BigInt(o)<<BigInt(32))})),u.prototype.readBigUInt64BE=K((function(t){G(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=e*2**24+65536*this[++t]+256*this[++t]+this[++t],o=this[++t]*2**24+65536*this[++t]+256*this[++t]+r;return(BigInt(n)<<BigInt(32))+BigInt(o)})),u.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=this[t],o=1,i=0;for(;++i<e&&(o*=256);)n+=this[t+i]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*e)),n},u.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||B(t,e,this.length);let n=e,o=1,i=this[t+--n];for(;n>0&&(o*=256);)i+=this[t+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*e)),i},u.prototype.readInt8=function(t,e){return t>>>=0,e||B(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function(t,e){t>>>=0,e||B(t,2,this.length);const r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(t,e){t>>>=0,e||B(t,2,this.length);const r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(t,e){return t>>>=0,e||B(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,e){return t>>>=0,e||B(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readBigInt64LE=K((function(t){G(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=this[t+4]+256*this[t+5]+65536*this[t+6]+(r<<24);return(BigInt(n)<<BigInt(32))+BigInt(e+256*this[++t]+65536*this[++t]+this[++t]*2**24)})),u.prototype.readBigInt64BE=K((function(t){G(t>>>=0,"offset");const e=this[t],r=this[t+7];void 0!==e&&void 0!==r||D(t,this.length-8);const n=(e<<24)+65536*this[++t]+256*this[++t]+this[++t];return(BigInt(n)<<BigInt(32))+BigInt(this[++t]*2**24+65536*this[++t]+256*this[++t]+r)})),u.prototype.readFloatLE=function(t,e){return t>>>=0,e||B(t,4,this.length),o.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,e){return t>>>=0,e||B(t,4,this.length),o.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,e){return t>>>=0,e||B(t,8,this.length),o.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,e){return t>>>=0,e||B(t,8,this.length),o.read(this,t,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||R(this,t,e,r,Math.pow(2,8*r)-1,0);let o=1,i=0;for(this[e]=255&t;++i<r&&(o*=256);)this[e+i]=t/o&255;return e+r},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(t,e,r,n){t=+t,e>>>=0,r>>>=0,n||R(this,t,e,r,Math.pow(2,8*r)-1,0);let o=r-1,i=1;for(this[e+o]=255&t;--o>=0&&(i*=256);)this[e+o]=t/i&255;return e+r},u.prototype.writeUint8=u.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,1,255,0),this[e]=255&t,e+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeBigUInt64LE=K((function(t,e=0){return U(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeBigUInt64BE=K((function(t,e=0){return F(this,t,e,BigInt(0),BigInt("0xffffffffffffffff"))})),u.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}let o=0,i=1,s=0;for(this[e]=255&t;++o<r&&(i*=256);)t<0&&0===s&&0!==this[e+o-1]&&(s=1),this[e+o]=(t/i|0)-s&255;return e+r},u.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){const n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}let o=r-1,i=1,s=0;for(this[e+o]=255&t;--o>=0&&(i*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/i|0)-s&255;return e+r},u.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},u.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},u.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||R(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeBigInt64LE=K((function(t,e=0){return U(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeBigInt64BE=K((function(t,e=0){return F(this,t,e,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),u.prototype.writeFloatLE=function(t,e,r){return $(this,t,e,!0,r)},u.prototype.writeFloatBE=function(t,e,r){return $(this,t,e,!1,r)},u.prototype.writeDoubleLE=function(t,e,r){return j(this,t,e,!0,r)},u.prototype.writeDoubleBE=function(t,e,r){return j(this,t,e,!1,r)},u.prototype.copy=function(t,e,r,n){if(!u.isBuffer(t))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);const o=n-r;return this===t&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(e,r,n):Uint8Array.prototype.set.call(t,this.subarray(r,n),e),o},u.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!u.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===t.length){const e=t.charCodeAt(0);("utf8"===n&&e<128||"latin1"===n)&&(t=e)}}else"number"==typeof t?t&=255:"boolean"==typeof t&&(t=Number(t));if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;let o;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{const i=u.isBuffer(t)?t:u.from(t,n),s=i.length;if(0===s)throw new TypeError('The value "'+t+'" is invalid for argument "value"');for(o=0;o<r-e;++o)this[o+e]=i[o%s]}return this};const W={};function N(t,e,r){W[t]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:e.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(t){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:t,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}function Z(t){let e="",r=t.length;const n="-"===t[0]?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function C(t,e,r,n,o,i){if(t>r||t<e){const n="bigint"==typeof e?"n":"";let o;throw o=i>3?0===e||e===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(i+1)}${n}`:`>= -(2${n} ** ${8*(i+1)-1}${n}) and < 2 ** ${8*(i+1)-1}${n}`:`>= ${e}${n} and <= ${r}${n}`,new W.ERR_OUT_OF_RANGE("value",o,t)}!function(t,e,r){G(e,"offset"),void 0!==t[e]&&void 0!==t[e+r]||D(e,t.length-(r+1))}(n,o,i)}function G(t,e){if("number"!=typeof t)throw new W.ERR_INVALID_ARG_TYPE(e,"number",t)}function D(t,e,r){if(Math.floor(t)!==t)throw G(t,r),new W.ERR_OUT_OF_RANGE(r||"offset","an integer",t);if(e<0)throw new W.ERR_BUFFER_OUT_OF_BOUNDS;throw new W.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${e}`,t)}N("ERR_BUFFER_OUT_OF_BOUNDS",(function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),N("ERR_INVALID_ARG_TYPE",(function(t,e){return`The "${t}" argument must be of type number. Received type ${typeof e}`}),TypeError),N("ERR_OUT_OF_RANGE",(function(t,e,r){let n=`The value of "${t}" is out of range.`,o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=Z(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=Z(o)),o+="n"),n+=` It must be ${e}. Received ${o}`,n}),RangeError);const z=/[^+/0-9A-Za-z-_]/g;function J(t,e){let r;e=e||1/0;const n=t.length;let o=null;const i=[];for(let s=0;s<n;++s){if(r=t.charCodeAt(s),r>55295&&r<57344){if(!o){if(r>56319){(e-=3)>-1&&i.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(e-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(e-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((e-=1)<0)break;i.push(r)}else if(r<2048){if((e-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function V(t){return n.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace(z,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function H(t,e,r,n){let o;for(o=0;o<n&&!(o+r>=e.length||o>=t.length);++o)e[o+r]=t[o];return o}function Y(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}function q(t){return t!=t}const X=function(){const t="0123456789abcdef",e=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)e[n+o]=t[r]+t[o]}return e}();function K(t){return"undefined"==typeof BigInt?Q:t}function Q(){throw new Error("BigInt not supported")}},3144:(t,e,r)=>{"use strict";var n=r(6743),o=r(1002),i=r(76),s=r(7119);t.exports=s||n.call(i,o)},2205:(t,e,r)=>{"use strict";var n=r(6743),o=r(1002),i=r(3144);t.exports=function(){return i(n,o,arguments)}},1002:t=>{"use strict";t.exports=Function.prototype.apply},76:t=>{"use strict";t.exports=Function.prototype.call},3126:(t,e,r)=>{"use strict";var n=r(6743),o=r(9675),i=r(76),s=r(3144);t.exports=function(t){if(t.length<1||"function"!=typeof t[0])throw new o("a function is required");return s(n,i,t)}},7119:t=>{"use strict";t.exports="undefined"!=typeof Reflect&&Reflect&&Reflect.apply},487:(t,e,r)=>{"use strict";var n=r(6897),o=r(655),i=r(3126),s=r(2205);t.exports=function(t){var e=i(arguments),r=t.length-(arguments.length-1);return n(e,1+(r>0?r:0),!0)},o?o(t.exports,"apply",{value:s}):t.exports.apply=s},6556:(t,e,r)=>{"use strict";var n=r(453),o=r(3126),i=o([n("%String.prototype.indexOf%")]);t.exports=function(t,e){var r=n(t,!!e);return"function"==typeof r&&i(t,".prototype.")>-1?o([r]):r}},41:(t,e,r)=>{"use strict";var n=r(655),o=r(8068),i=r(9675),s=r(5795);t.exports=function(t,e,r){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new i("`obj` must be an object or a function`");if("string"!=typeof e&&"symbol"!=typeof e)throw new i("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new i("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new i("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new i("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new i("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,u=arguments.length>4?arguments[4]:null,c=arguments.length>5?arguments[5]:null,f=arguments.length>6&&arguments[6],p=!!s&&s(t,e);if(n)n(t,e,{configurable:null===c&&p?p.configurable:!c,enumerable:null===a&&p?p.enumerable:!a,value:r,writable:null===u&&p?p.writable:!u});else{if(!f&&(a||u||c))throw new o("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");t[e]=r}}},7176:(t,e,r)=>{"use strict";var n,o=r(3126),i=r(5795);try{n=[].__proto__===Array.prototype}catch(t){if(!t||"object"!=typeof t||!("code"in t)||"ERR_PROTO_ACCESS"!==t.code)throw t}var s=!!n&&i&&i(Object.prototype,"__proto__"),a=Object,u=a.getPrototypeOf;t.exports=s&&"function"==typeof s.get?o([s.get]):"function"==typeof u&&function(t){return u(null==t?t:a(t))}},655:t=>{"use strict";var e=Object.defineProperty||!1;if(e)try{e({},"a",{value:1})}catch(t){e=!1}t.exports=e},1237:t=>{"use strict";t.exports=EvalError},9383:t=>{"use strict";t.exports=Error},9290:t=>{"use strict";t.exports=RangeError},9538:t=>{"use strict";t.exports=ReferenceError},8068:t=>{"use strict";t.exports=SyntaxError},9675:t=>{"use strict";t.exports=TypeError},5345:t=>{"use strict";t.exports=URIError},9612:t=>{"use strict";t.exports=Object},2682:(t,e,r)=>{"use strict";var n=r(9600),o=Object.prototype.toString,i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){if(!n(e))throw new TypeError("iterator must be a function");var s;arguments.length>=3&&(s=r),"[object Array]"===o.call(t)?function(t,e,r){for(var n=0,o=t.length;n<o;n++)i.call(t,n)&&(null==r?e(t[n],n,t):e.call(r,t[n],n,t))}(t,e,s):"string"==typeof t?function(t,e,r){for(var n=0,o=t.length;n<o;n++)null==r?e(t.charAt(n),n,t):e.call(r,t.charAt(n),n,t)}(t,e,s):function(t,e,r){for(var n in t)i.call(t,n)&&(null==r?e(t[n],n,t):e.call(r,t[n],n,t))}(t,e,s)}},9353:t=>{"use strict";var e=Object.prototype.toString,r=Math.max,n=function(t,e){for(var r=[],n=0;n<t.length;n+=1)r[n]=t[n];for(var o=0;o<e.length;o+=1)r[o+t.length]=e[o];return r};t.exports=function(t){var o=this;if("function"!=typeof o||"[object Function]"!==e.apply(o))throw new TypeError("Function.prototype.bind called on incompatible "+o);for(var i,s=function(t){for(var e=[],r=1,n=0;r<t.length;r+=1,n+=1)e[n]=t[r];return e}(arguments),a=r(0,o.length-s.length),u=[],c=0;c<a;c++)u[c]="$"+c;if(i=Function("binder","return function ("+function(t){for(var e="",r=0;r<t.length;r+=1)e+=t[r],r+1<t.length&&(e+=",");return e}(u)+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof i){var e=o.apply(this,n(s,arguments));return Object(e)===e?e:this}return o.apply(t,n(s,arguments))})),o.prototype){var f=function(){};f.prototype=o.prototype,i.prototype=new f,f.prototype=null}return i}},6743:(t,e,r)=>{"use strict";var n=r(9353);t.exports=Function.prototype.bind||n},453:(t,e,r)=>{"use strict";var n,o=r(9612),i=r(9383),s=r(1237),a=r(9290),u=r(9538),c=r(8068),f=r(9675),p=r(5345),l=r(1514),h=r(8968),y=r(6188),g=r(8002),d=r(5880),b=r(414),w=r(3093),m=Function,v=function(t){try{return m('"use strict"; return ('+t+").constructor;")()}catch(t){}},S=r(5795),M=r(655),x=function(){throw new f},E=S?function(){try{return x}catch(t){try{return S(arguments,"callee").get}catch(t){return x}}}():x,k=r(4039)(),A=r(3628),I=r(1064),O=r(8648),P=r(1002),T=r(76),_={},B="undefined"!=typeof Uint8Array&&A?A(Uint8Array):n,R={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":k&&A?A([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":_,"%AsyncGenerator%":_,"%AsyncGeneratorFunction%":_,"%AsyncIteratorPrototype%":_,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?n:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?n:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":i,"%eval%":eval,"%EvalError%":s,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":m,"%GeneratorFunction%":_,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":k&&A?A(A([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&k&&A?A((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":o,"%Object.getOwnPropertyDescriptor%":S,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":a,"%ReferenceError%":u,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&k&&A?A((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":k&&A?A(""[Symbol.iterator]()):n,"%Symbol%":k?Symbol:n,"%SyntaxError%":c,"%ThrowTypeError%":E,"%TypedArray%":B,"%TypeError%":f,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":p,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet,"%Function.prototype.call%":T,"%Function.prototype.apply%":P,"%Object.defineProperty%":M,"%Object.getPrototypeOf%":I,"%Math.abs%":l,"%Math.floor%":h,"%Math.max%":y,"%Math.min%":g,"%Math.pow%":d,"%Math.round%":b,"%Math.sign%":w,"%Reflect.getPrototypeOf%":O};if(A)try{null.error}catch(t){var U=A(A(t));R["%Error.prototype%"]=U}var F=function t(e){var r;if("%AsyncFunction%"===e)r=v("async function () {}");else if("%GeneratorFunction%"===e)r=v("function* () {}");else if("%AsyncGeneratorFunction%"===e)r=v("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var o=t("%AsyncGenerator%");o&&A&&(r=A(o.prototype))}return R[e]=r,r},L={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},$=r(6743),j=r(9957),W=$.call(T,Array.prototype.concat),N=$.call(P,Array.prototype.splice),Z=$.call(T,String.prototype.replace),C=$.call(T,String.prototype.slice),G=$.call(T,RegExp.prototype.exec),D=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,z=/\\(\\)?/g,J=function(t,e){var r,n=t;if(j(L,n)&&(n="%"+(r=L[n])[0]+"%"),j(R,n)){var o=R[n];if(o===_&&(o=F(n)),void 0===o&&!e)throw new f("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new c("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new f("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new f('"allowMissing" argument must be a boolean');if(null===G(/^%?[^%]*%?$/,t))throw new c("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=function(t){var e=C(t,0,1),r=C(t,-1);if("%"===e&&"%"!==r)throw new c("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==e)throw new c("invalid intrinsic syntax, expected opening `%`");var n=[];return Z(t,D,(function(t,e,r,o){n[n.length]=r?Z(o,z,"$1"):e||t})),n}(t),n=r.length>0?r[0]:"",o=J("%"+n+"%",e),i=o.name,s=o.value,a=!1,u=o.alias;u&&(n=u[0],N(r,W([0,1],u)));for(var p=1,l=!0;p<r.length;p+=1){var h=r[p],y=C(h,0,1),g=C(h,-1);if(('"'===y||"'"===y||"`"===y||'"'===g||"'"===g||"`"===g)&&y!==g)throw new c("property names with quotes must have matching quotes");if("constructor"!==h&&l||(a=!0),j(R,i="%"+(n+="."+h)+"%"))s=R[i];else if(null!=s){if(!(h in s)){if(!e)throw new f("base intrinsic for "+t+" exists, but the property is not available.");return}if(S&&p+1>=r.length){var d=S(s,h);s=(l=!!d)&&"get"in d&&!("originalValue"in d.get)?d.get:s[h]}else l=j(s,h),s=s[h];l&&!a&&(R[i]=s)}}return s}},1064:(t,e,r)=>{"use strict";var n=r(9612);t.exports=n.getPrototypeOf||null},8648:t=>{"use strict";t.exports="undefined"!=typeof Reflect&&Reflect.getPrototypeOf||null},3628:(t,e,r)=>{"use strict";var n=r(8648),o=r(1064),i=r(7176);t.exports=n?function(t){return n(t)}:o?function(t){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new TypeError("getProto: not an object");return o(t)}:i?function(t){return i(t)}:null},6549:t=>{"use strict";t.exports=Object.getOwnPropertyDescriptor},5795:(t,e,r)=>{"use strict";var n=r(6549);if(n)try{n([],"length")}catch(t){n=null}t.exports=n},592:(t,e,r)=>{"use strict";var n=r(655),o=function(){return!!n};o.hasArrayLengthDefineBug=function(){if(!n)return null;try{return 1!==n([],"length",{value:1}).length}catch(t){return!0}},t.exports=o},4039:(t,e,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(1333);t.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},1333:t=>{"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e)return!1;if("[object Symbol]"!==Object.prototype.toString.call(e))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(var n in t[e]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var o=Object.getOwnPropertySymbols(t);if(1!==o.length||o[0]!==e)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},9092:(t,e,r)=>{"use strict";var n=r(1333);t.exports=function(){return n()&&!!Symbol.toStringTag}},9957:(t,e,r)=>{"use strict";var n=Function.prototype.call,o=Object.prototype.hasOwnProperty,i=r(6743);t.exports=i.call(n,o)},251:(t,e)=>{e.read=function(t,e,r,n,o){var i,s,a=8*o-n-1,u=(1<<a)-1,c=u>>1,f=-7,p=r?o-1:0,l=r?-1:1,h=t[e+p];for(p+=l,i=h&(1<<-f)-1,h>>=-f,f+=a;f>0;i=256*i+t[e+p],p+=l,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=n;f>0;s=256*s+t[e+p],p+=l,f-=8);if(0===i)i=1-c;else{if(i===u)return s?NaN:1/0*(h?-1:1);s+=Math.pow(2,n),i-=c}return(h?-1:1)*s*Math.pow(2,i-n)},e.write=function(t,e,r,n,o,i){var s,a,u,c=8*i-o-1,f=(1<<c)-1,p=f>>1,l=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:i-1,y=n?1:-1,g=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=f):(s=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-s))<1&&(s--,u*=2),(e+=s+p>=1?l/u:l*Math.pow(2,1-p))*u>=2&&(s++,u/=2),s+p>=f?(a=0,s=f):s+p>=1?(a=(e*u-1)*Math.pow(2,o),s+=p):(a=e*Math.pow(2,p-1)*Math.pow(2,o),s=0));o>=8;t[r+h]=255&a,h+=y,a/=256,o-=8);for(s=s<<o|a,c+=o;c>0;t[r+h]=255&s,h+=y,s/=256,c-=8);t[r+h-y]|=128*g}},6698:t=>{"function"==typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},7244:(t,e,r)=>{"use strict";var n=r(9092)(),o=r(6556)("Object.prototype.toString"),i=function(t){return!(n&&t&&"object"==typeof t&&Symbol.toStringTag in t)&&"[object Arguments]"===o(t)},s=function(t){return!!i(t)||null!==t&&"object"==typeof t&&"length"in t&&"number"==typeof t.length&&t.length>=0&&"[object Array]"!==o(t)&&"callee"in t&&"[object Function]"===o(t.callee)},a=function(){return i(arguments)}();i.isLegacyArguments=s,t.exports=a?i:s},9600:t=>{"use strict";var e,r,n=Function.prototype.toString,o="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof o&&"function"==typeof Object.defineProperty)try{e=Object.defineProperty({},"length",{get:function(){throw r}}),r={},o((function(){throw 42}),null,e)}catch(t){t!==r&&(o=null)}else o=null;var i=/^\s*class\b/,s=function(t){try{var e=n.call(t);return i.test(e)}catch(t){return!1}},a=function(t){try{return!s(t)&&(n.call(t),!0)}catch(t){return!1}},u=Object.prototype.toString,c="function"==typeof Symbol&&!!Symbol.toStringTag,f=!(0 in[,]),p=function(){return!1};if("object"==typeof document){var l=document.all;u.call(l)===u.call(document.all)&&(p=function(t){if((f||!t)&&(void 0===t||"object"==typeof t))try{var e=u.call(t);return("[object HTMLAllCollection]"===e||"[object HTML document.all class]"===e||"[object HTMLCollection]"===e||"[object Object]"===e)&&null==t("")}catch(t){}return!1})}t.exports=o?function(t){if(p(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;try{o(t,null,e)}catch(t){if(t!==r)return!1}return!s(t)&&a(t)}:function(t){if(p(t))return!0;if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if(c)return a(t);if(s(t))return!1;var e=u.call(t);return!("[object Function]"!==e&&"[object GeneratorFunction]"!==e&&!/^\[object HTML/.test(e))&&a(t)}},8184:(t,e,r)=>{"use strict";var n,o=r(6556),i=r(9721)(/^\s*(?:function)?\*/),s=r(9092)(),a=r(3628),u=o("Object.prototype.toString"),c=o("Function.prototype.toString");t.exports=function(t){if("function"!=typeof t)return!1;if(i(c(t)))return!0;if(!s)return"[object GeneratorFunction]"===u(t);if(!a)return!1;if(void 0===n){var e=function(){if(!s)return!1;try{return Function("return function*() {}")()}catch(t){}}();n=!!e&&a(e)}return a(t)===n}},4035:(t,e,r)=>{"use strict";var n,o=r(6556),i=r(9092)(),s=r(9957),a=r(5795);if(i){var u=o("RegExp.prototype.exec"),c={},f=function(){throw c},p={toString:f,valueOf:f};"symbol"==typeof Symbol.toPrimitive&&(p[Symbol.toPrimitive]=f),n=function(t){if(!t||"object"!=typeof t)return!1;var e=a(t,"lastIndex");if(!e||!s(e,"value"))return!1;try{u(t,p)}catch(t){return t===c}}}else{var l=o("Object.prototype.toString");n=function(t){return!(!t||"object"!=typeof t&&"function"!=typeof t)&&"[object RegExp]"===l(t)}}t.exports=n},5680:(t,e,r)=>{"use strict";var n=r(5767);t.exports=function(t){return!!n(t)}},1514:t=>{"use strict";t.exports=Math.abs},8968:t=>{"use strict";t.exports=Math.floor},4459:t=>{"use strict";t.exports=Number.isNaN||function(t){return t!=t}},6188:t=>{"use strict";t.exports=Math.max},8002:t=>{"use strict";t.exports=Math.min},5880:t=>{"use strict";t.exports=Math.pow},414:t=>{"use strict";t.exports=Math.round},3093:(t,e,r)=>{"use strict";var n=r(4459);t.exports=function(t){return n(t)||0===t?t:t<0?-1:1}},6578:t=>{"use strict";t.exports=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]},5606:t=>{var e,r,n=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(t){if(e===setTimeout)return setTimeout(t,0);if((e===o||!e)&&setTimeout)return e=setTimeout,setTimeout(t,0);try{return e(t,0)}catch(r){try{return e.call(null,t,0)}catch(r){return e.call(this,t,0)}}}!function(){try{e="function"==typeof setTimeout?setTimeout:o}catch(t){e=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(t){r=i}}();var a,u=[],c=!1,f=-1;function p(){c&&a&&(c=!1,a.length?u=a.concat(u):f=-1,u.length&&l())}function l(){if(!c){var t=s(p);c=!0;for(var e=u.length;e;){for(a=u,u=[];++f<e;)a&&a[f].run();f=-1,e=u.length}a=null,c=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{return r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function y(){}n.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];u.push(new h(t,e)),1!==u.length||c||s(l)},h.prototype.run=function(){this.fun.apply(null,this.array)},n.title="browser",n.browser=!0,n.env={},n.argv=[],n.version="",n.versions={},n.on=y,n.addListener=y,n.once=y,n.off=y,n.removeListener=y,n.removeAllListeners=y,n.emit=y,n.prependListener=y,n.prependOnceListener=y,n.listeners=function(t){return[]},n.binding=function(t){throw new Error("process.binding is not supported")},n.cwd=function(){return"/"},n.chdir=function(t){throw new Error("process.chdir is not supported")},n.umask=function(){return 0}},9721:(t,e,r)=>{"use strict";var n=r(6556),o=r(4035),i=n("RegExp.prototype.exec"),s=r(9675);t.exports=function(t){if(!o(t))throw new s("`regex` must be a RegExp");return function(e){return null!==i(t,e)}}},6897:(t,e,r)=>{"use strict";var n=r(453),o=r(41),i=r(592)(),s=r(5795),a=r(9675),u=n("%Math.floor%");t.exports=function(t,e){if("function"!=typeof t)throw new a("`fn` is not a function");if("number"!=typeof e||e<0||e>4294967295||u(e)!==e)throw new a("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],n=!0,c=!0;if("length"in t&&s){var f=s(t,"length");f&&!f.configurable&&(n=!1),f&&!f.writable&&(c=!1)}return(n||c||!r)&&(i?o(t,"length",e,!0,!0):o(t,"length",e)),t}},1135:t=>{t.exports=function(t){return t&&"object"==typeof t&&"function"==typeof t.copy&&"function"==typeof t.fill&&"function"==typeof t.readUInt8}},9032:(t,e,r)=>{"use strict";var n=r(7244),o=r(8184),i=r(5767),s=r(5680);function a(t){return t.call.bind(t)}var u="undefined"!=typeof BigInt,c="undefined"!=typeof Symbol,f=a(Object.prototype.toString),p=a(Number.prototype.valueOf),l=a(String.prototype.valueOf),h=a(Boolean.prototype.valueOf);if(u)var y=a(BigInt.prototype.valueOf);if(c)var g=a(Symbol.prototype.valueOf);function d(t,e){if("object"!=typeof t)return!1;try{return e(t),!0}catch(t){return!1}}function b(t){return"[object Map]"===f(t)}function w(t){return"[object Set]"===f(t)}function m(t){return"[object WeakMap]"===f(t)}function v(t){return"[object WeakSet]"===f(t)}function S(t){return"[object ArrayBuffer]"===f(t)}function M(t){return"undefined"!=typeof ArrayBuffer&&(S.working?S(t):t instanceof ArrayBuffer)}function x(t){return"[object DataView]"===f(t)}function E(t){return"undefined"!=typeof DataView&&(x.working?x(t):t instanceof DataView)}e.isArgumentsObject=n,e.isGeneratorFunction=o,e.isTypedArray=s,e.isPromise=function(t){return"undefined"!=typeof Promise&&t instanceof Promise||null!==t&&"object"==typeof t&&"function"==typeof t.then&&"function"==typeof t.catch},e.isArrayBufferView=function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):s(t)||E(t)},e.isUint8Array=function(t){return"Uint8Array"===i(t)},e.isUint8ClampedArray=function(t){return"Uint8ClampedArray"===i(t)},e.isUint16Array=function(t){return"Uint16Array"===i(t)},e.isUint32Array=function(t){return"Uint32Array"===i(t)},e.isInt8Array=function(t){return"Int8Array"===i(t)},e.isInt16Array=function(t){return"Int16Array"===i(t)},e.isInt32Array=function(t){return"Int32Array"===i(t)},e.isFloat32Array=function(t){return"Float32Array"===i(t)},e.isFloat64Array=function(t){return"Float64Array"===i(t)},e.isBigInt64Array=function(t){return"BigInt64Array"===i(t)},e.isBigUint64Array=function(t){return"BigUint64Array"===i(t)},b.working="undefined"!=typeof Map&&b(new Map),e.isMap=function(t){return"undefined"!=typeof Map&&(b.working?b(t):t instanceof Map)},w.working="undefined"!=typeof Set&&w(new Set),e.isSet=function(t){return"undefined"!=typeof Set&&(w.working?w(t):t instanceof Set)},m.working="undefined"!=typeof WeakMap&&m(new WeakMap),e.isWeakMap=function(t){return"undefined"!=typeof WeakMap&&(m.working?m(t):t instanceof WeakMap)},v.working="undefined"!=typeof WeakSet&&v(new WeakSet),e.isWeakSet=function(t){return v(t)},S.working="undefined"!=typeof ArrayBuffer&&S(new ArrayBuffer),e.isArrayBuffer=M,x.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&x(new DataView(new ArrayBuffer(1),0,1)),e.isDataView=E;var k="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function A(t){return"[object SharedArrayBuffer]"===f(t)}function I(t){return void 0!==k&&(void 0===A.working&&(A.working=A(new k)),A.working?A(t):t instanceof k)}function O(t){return d(t,p)}function P(t){return d(t,l)}function T(t){return d(t,h)}function _(t){return u&&d(t,y)}function B(t){return c&&d(t,g)}e.isSharedArrayBuffer=I,e.isAsyncFunction=function(t){return"[object AsyncFunction]"===f(t)},e.isMapIterator=function(t){return"[object Map Iterator]"===f(t)},e.isSetIterator=function(t){return"[object Set Iterator]"===f(t)},e.isGeneratorObject=function(t){return"[object Generator]"===f(t)},e.isWebAssemblyCompiledModule=function(t){return"[object WebAssembly.Module]"===f(t)},e.isNumberObject=O,e.isStringObject=P,e.isBooleanObject=T,e.isBigIntObject=_,e.isSymbolObject=B,e.isBoxedPrimitive=function(t){return O(t)||P(t)||T(t)||_(t)||B(t)},e.isAnyArrayBuffer=function(t){return"undefined"!=typeof Uint8Array&&(M(t)||I(t))},["isProxy","isExternal","isModuleNamespaceObject"].forEach((function(t){Object.defineProperty(e,t,{enumerable:!1,value:function(){throw new Error(t+" is not supported in userland")}})}))},537:(t,e,r)=>{var n=r(5606),o=Object.getOwnPropertyDescriptors||function(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++)r[e[n]]=Object.getOwnPropertyDescriptor(t,e[n]);return r},i=/%[sdj%]/g;e.format=function(t){if(!m(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(c(arguments[r]));return e.join(" ")}r=1;for(var n=arguments,o=n.length,s=String(t).replace(i,(function(t){if("%%"===t)return"%";if(r>=o)return t;switch(t){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(t){return"[Circular]"}default:return t}})),a=n[r];r<o;a=n[++r])b(a)||!M(a)?s+=" "+a:s+=" "+c(a);return s},e.deprecate=function(t,r){if(void 0!==n&&!0===n.noDeprecation)return t;if(void 0===n)return function(){return e.deprecate(t,r).apply(this,arguments)};var o=!1;return function(){if(!o){if(n.throwDeprecation)throw new Error(r);n.traceDeprecation?console.trace(r):console.error(r),o=!0}return t.apply(this,arguments)}};var s={},a=/^$/;if(n.env.NODE_DEBUG){var u=n.env.NODE_DEBUG;u=u.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),a=new RegExp("^"+u+"$","i")}function c(t,r){var n={seen:[],stylize:p};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),d(r)?n.showHidden=r:r&&e._extend(n,r),v(n.showHidden)&&(n.showHidden=!1),v(n.depth)&&(n.depth=2),v(n.colors)&&(n.colors=!1),v(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=f),l(n,t,n.depth)}function f(t,e){var r=c.styles[e];return r?"["+c.colors[r][0]+"m"+t+"["+c.colors[r][1]+"m":t}function p(t,e){return t}function l(t,r,n){if(t.customInspect&&r&&k(r.inspect)&&r.inspect!==e.inspect&&(!r.constructor||r.constructor.prototype!==r)){var o=r.inspect(n,t);return m(o)||(o=l(t,o,n)),o}var i=function(t,e){if(v(e))return t.stylize("undefined","undefined");if(m(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}return w(e)?t.stylize(""+e,"number"):d(e)?t.stylize(""+e,"boolean"):b(e)?t.stylize("null","null"):void 0}(t,r);if(i)return i;var s=Object.keys(r),a=function(t){var e={};return t.forEach((function(t,r){e[t]=!0})),e}(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(r)),E(r)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return h(r);if(0===s.length){if(k(r)){var u=r.name?": "+r.name:"";return t.stylize("[Function"+u+"]","special")}if(S(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(x(r))return t.stylize(Date.prototype.toString.call(r),"date");if(E(r))return h(r)}var c,f="",p=!1,M=["{","}"];return g(r)&&(p=!0,M=["[","]"]),k(r)&&(f=" [Function"+(r.name?": "+r.name:"")+"]"),S(r)&&(f=" "+RegExp.prototype.toString.call(r)),x(r)&&(f=" "+Date.prototype.toUTCString.call(r)),E(r)&&(f=" "+h(r)),0!==s.length||p&&0!=r.length?n<0?S(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),c=p?function(t,e,r,n,o){for(var i=[],s=0,a=e.length;s<a;++s)P(e,String(s))?i.push(y(t,e,r,n,String(s),!0)):i.push("");return o.forEach((function(o){o.match(/^\d+$/)||i.push(y(t,e,r,n,o,!0))})),i}(t,r,n,a,s):s.map((function(e){return y(t,r,n,a,e,p)})),t.seen.pop(),function(t,e,r){return t.reduce((function(t,e){return e.indexOf("\n"),t+e.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60?r[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+r[1]:r[0]+e+" "+t.join(", ")+" "+r[1]}(c,f,M)):M[0]+f+M[1]}function h(t){return"["+Error.prototype.toString.call(t)+"]"}function y(t,e,r,n,o,i){var s,a,u;if((u=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]}).get?a=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(a=t.stylize("[Setter]","special")),P(n,o)||(s="["+o+"]"),a||(t.seen.indexOf(u.value)<0?(a=b(r)?l(t,u.value,null):l(t,u.value,r-1)).indexOf("\n")>-1&&(a=i?a.split("\n").map((function(t){return" "+t})).join("\n").slice(2):"\n"+a.split("\n").map((function(t){return" "+t})).join("\n")):a=t.stylize("[Circular]","special")),v(s)){if(i&&o.match(/^\d+$/))return a;(s=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.slice(1,-1),s=t.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=t.stylize(s,"string"))}return s+": "+a}function g(t){return Array.isArray(t)}function d(t){return"boolean"==typeof t}function b(t){return null===t}function w(t){return"number"==typeof t}function m(t){return"string"==typeof t}function v(t){return void 0===t}function S(t){return M(t)&&"[object RegExp]"===A(t)}function M(t){return"object"==typeof t&&null!==t}function x(t){return M(t)&&"[object Date]"===A(t)}function E(t){return M(t)&&("[object Error]"===A(t)||t instanceof Error)}function k(t){return"function"==typeof t}function A(t){return Object.prototype.toString.call(t)}function I(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(t){if(t=t.toUpperCase(),!s[t])if(a.test(t)){var r=n.pid;s[t]=function(){var n=e.format.apply(e,arguments);console.error("%s %d: %s",t,r,n)}}else s[t]=function(){};return s[t]},e.inspect=c,c.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.types=r(9032),e.isArray=g,e.isBoolean=d,e.isNull=b,e.isNullOrUndefined=function(t){return null==t},e.isNumber=w,e.isString=m,e.isSymbol=function(t){return"symbol"==typeof t},e.isUndefined=v,e.isRegExp=S,e.types.isRegExp=S,e.isObject=M,e.isDate=x,e.types.isDate=x,e.isError=E,e.types.isNativeError=E,e.isFunction=k,e.isPrimitive=function(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t},e.isBuffer=r(1135);var O=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){var t,r;console.log("%s - %s",(r=[I((t=new Date).getHours()),I(t.getMinutes()),I(t.getSeconds())].join(":"),[t.getDate(),O[t.getMonth()],r].join(" ")),e.format.apply(e,arguments))},e.inherits=r(6698),e._extend=function(t,e){if(!e||!M(e))return t;for(var r=Object.keys(e),n=r.length;n--;)t[r[n]]=e[r[n]];return t};var T="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function _(t,e){if(!t){var r=new Error("Promise was rejected with a falsy value");r.reason=t,t=r}return e(t)}e.promisify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');if(T&&t[T]){var e;if("function"!=typeof(e=t[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,r,n=new Promise((function(t,n){e=t,r=n})),o=[],i=0;i<arguments.length;i++)o.push(arguments[i]);o.push((function(t,n){t?r(t):e(n)}));try{t.apply(this,o)}catch(t){r(t)}return n}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),T&&Object.defineProperty(e,T,{value:e,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(e,o(t))},e.promisify.custom=T,e.callbackify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');function e(){for(var e=[],r=0;r<arguments.length;r++)e.push(arguments[r]);var o=e.pop();if("function"!=typeof o)throw new TypeError("The last argument must be of type Function");var i=this,s=function(){return o.apply(i,arguments)};t.apply(this,e).then((function(t){n.nextTick(s.bind(null,null,t))}),(function(t){n.nextTick(_.bind(null,t,s))}))}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),Object.defineProperties(e,o(t)),e}},5767:(t,e,r)=>{"use strict";var n=r(2682),o=r(9209),i=r(487),s=r(6556),a=r(5795),u=s("Object.prototype.toString"),c=r(9092)(),f="undefined"==typeof globalThis?r.g:globalThis,p=o(),l=s("String.prototype.slice"),h=Object.getPrototypeOf,y=s("Array.prototype.indexOf",!0)||function(t,e){for(var r=0;r<t.length;r+=1)if(t[r]===e)return r;return-1},g={__proto__:null};n(p,c&&a&&h?function(t){var e=new f[t];if(Symbol.toStringTag in e){var r=h(e),n=a(r,Symbol.toStringTag);if(!n){var o=h(r);n=a(o,Symbol.toStringTag)}g["$"+t]=i(n.get)}}:function(t){var e=new f[t],r=e.slice||e.set;r&&(g["$"+t]=i(r))}),t.exports=function(t){if(!t||"object"!=typeof t)return!1;if(!c){var e=l(u(t),8,-1);return y(p,e)>-1?e:"Object"===e&&function(t){var e=!1;return n(g,(function(r,n){if(!e)try{r(t),e=l(n,1)}catch(t){}})),e}(t)}return a?function(t){var e=!1;return n(g,(function(r,n){if(!e)try{"$"+r(t)===n&&(e=l(n,1))}catch(t){}})),e}(t):null}},4047:(t,e,r)=>{var n=r(8287).Buffer;function o(t,e){this.buffer=t,this.position=0,this.isBigEndian=e||!1}function i(t,e,r){return function(){var n;return n=this.isBigEndian?e.call(this.buffer,this.position):t.call(this.buffer,this.position),this.position+=r,n}}t.exports=o,o.prototype.readUInt8=i(n.prototype.readUInt8,n.prototype.readUInt8,1),o.prototype.readUInt16=i(n.prototype.readUInt16LE,n.prototype.readUInt16BE,2),o.prototype.readUInt32=i(n.prototype.readUInt32LE,n.prototype.readUInt32BE,4),o.prototype.readInt8=i(n.prototype.readInt8,n.prototype.readInt8,1),o.prototype.readInt16=i(n.prototype.readInt16LE,n.prototype.readInt16BE,2),o.prototype.readInt32=i(n.prototype.readInt32LE,n.prototype.readInt32BE,4),o.prototype.readFloat=i(n.prototype.readFloatLE,n.prototype.readFloatBE,4),o.prototype.readDouble=i(n.prototype.readDoubleLE,n.prototype.readDoubleBE,8),o.prototype.readVarInt=function(){var t,e=0,r=0;do{e+=(127&(t=this.buffer[this.position+r]))<<7*r,r++}while(t>=128);return this.position+=r,e}},1199:(t,e,r)=>{var n=r(8287).Buffer;function o(t,e){this.buffer=new n(t),this.position=0,this.allowResize=e}function i(t,e){return function(r,n){this.ensureSize(e),t.call(this.buffer,r,this.position,n),this.position+=e}}t.exports=o,o.prototype.writeUInt8=i(n.prototype.writeUInt8,1),o.prototype.writeUInt16LE=i(n.prototype.writeUInt16LE,2),o.prototype.writeUInt16BE=i(n.prototype.writeUInt16BE,2),o.prototype.writeUInt32LE=i(n.prototype.writeUInt32LE,4),o.prototype.writeUInt32BE=i(n.prototype.writeUInt32BE,4),o.prototype.writeInt8=i(n.prototype.writeInt8,1),o.prototype.writeInt16LE=i(n.prototype.writeInt16LE,2),o.prototype.writeInt16BE=i(n.prototype.writeInt16BE,2),o.prototype.writeInt32LE=i(n.prototype.writeInt32LE,4),o.prototype.writeInt32BE=i(n.prototype.writeInt32BE,4),o.prototype.writeFloatLE=i(n.prototype.writeFloatLE,4),o.prototype.writeFloatBE=i(n.prototype.writeFloatBE,4),o.prototype.writeDoubleLE=i(n.prototype.writeDoubleLE,8),o.prototype.writeDoubleBE=i(n.prototype.writeDoubleBE,8),o.prototype.writeBuffer=function(t){this.ensureSize(t.length),t.copy(this.buffer,this.position,0,t.length),this.position+=t.length},o.prototype.writeVarInt=function(t){for(var e=1;4294967168&t;)this.writeUInt8(127&t|128),t>>>=7,e++;return this.writeUInt8(127&t),e},o.prototype.ensureSize=function(t){if(this.buffer.length<this.position+t){if(!this.allowResize)throw new RangeError("index out of range");var e=new n(this.position+t);this.buffer.copy(e,0,0,this.buffer.length),this.buffer=e}}},2957:(t,e,r)=>{var n=r(8287).Buffer;t.exports=d;var o=r(740),i=r(4263),s=r(350),a=r(743),u=r(3452),c=r(3959),f=r(9236),p=r(1141),l=r(4047),h=r(1199),y=r(2104),g=r(1865);function d(){this.srid=void 0,this.hasZ=!1,this.hasM=!1}d.parse=function(t,e){if("string"==typeof t||t instanceof y)return d._parseWkt(t);if(n.isBuffer(t)||t instanceof l)return d._parseWkb(t,e);throw new Error("first argument must be a string or Buffer")},d._parseWkt=function(t){var e,r,n=(e=t instanceof y?t:new y(t)).matchRegex([/^SRID=(\d+);/]);n&&(r=parseInt(n[1],10));var l=e.matchType(),h=e.matchDimension(),g={srid:r,hasZ:h.hasZ,hasM:h.hasM};switch(l){case o.wkt.Point:return i._parseWkt(e,g);case o.wkt.LineString:return s._parseWkt(e,g);case o.wkt.Polygon:return a._parseWkt(e,g);case o.wkt.MultiPoint:return u._parseWkt(e,g);case o.wkt.MultiLineString:return c._parseWkt(e,g);case o.wkt.MultiPolygon:return f._parseWkt(e,g);case o.wkt.GeometryCollection:return p._parseWkt(e,g)}},d._parseWkb=function(t,e){var r,n,h,y={};switch((r=t instanceof l?t:new l(t)).isBigEndian=!r.readInt8(),n=r.readUInt32(),y.hasSrid=!(536870912&~n),y.isEwkb=536870912&n||1073741824&n||2147483648&n,y.hasSrid&&(y.srid=r.readUInt32()),y.hasZ=!1,y.hasM=!1,y.isEwkb||e&&e.isEwkb?(2147483648&n&&(y.hasZ=!0),1073741824&n&&(y.hasM=!0),h=15&n):n>=1e3&&n<2e3?(y.hasZ=!0,h=n-1e3):n>=2e3&&n<3e3?(y.hasM=!0,h=n-2e3):n>=3e3&&n<4e3?(y.hasZ=!0,y.hasM=!0,h=n-3e3):h=n,h){case o.wkb.Point:return i._parseWkb(r,y);case o.wkb.LineString:return s._parseWkb(r,y);case o.wkb.Polygon:return a._parseWkb(r,y);case o.wkb.MultiPoint:return u._parseWkb(r,y);case o.wkb.MultiLineString:return c._parseWkb(r,y);case o.wkb.MultiPolygon:return f._parseWkb(r,y);case o.wkb.GeometryCollection:return p._parseWkb(r,y);default:throw new Error("GeometryType "+h+" not supported")}},d.parseTwkb=function(t){var e,r={},n=(e=t instanceof l?t:new l(t)).readUInt8(),h=e.readUInt8(),y=15&n;if(r.precision=g.decode(n>>4),r.precisionFactor=Math.pow(10,r.precision),r.hasBoundingBox=1&h,r.hasSizeAttribute=h>>1&1,r.hasIdList=h>>2&1,r.hasExtendedPrecision=h>>3&1,r.isEmpty=h>>4&1,r.hasExtendedPrecision){var d=e.readUInt8();r.hasZ=!(1&~d),r.hasM=!(2&~d),r.zPrecision=g.decode((28&d)>>2),r.zPrecisionFactor=Math.pow(10,r.zPrecision),r.mPrecision=g.decode((224&d)>>5),r.mPrecisionFactor=Math.pow(10,r.mPrecision)}else r.hasZ=!1,r.hasM=!1;if(r.hasSizeAttribute&&e.readVarInt(),r.hasBoundingBox){var b=2;r.hasZ&&b++,r.hasM&&b++;for(var w=0;w<b;w++)e.readVarInt(),e.readVarInt()}switch(y){case o.wkb.Point:return i._parseTwkb(e,r);case o.wkb.LineString:return s._parseTwkb(e,r);case o.wkb.Polygon:return a._parseTwkb(e,r);case o.wkb.MultiPoint:return u._parseTwkb(e,r);case o.wkb.MultiLineString:return c._parseTwkb(e,r);case o.wkb.MultiPolygon:return f._parseTwkb(e,r);case o.wkb.GeometryCollection:return p._parseTwkb(e,r);default:throw new Error("GeometryType "+y+" not supported")}},d.parseGeoJSON=function(t){return d._parseGeoJSON(t)},d._parseGeoJSON=function(t,e){var r;switch(t.type){case o.geoJSON.Point:r=i._parseGeoJSON(t);break;case o.geoJSON.LineString:r=s._parseGeoJSON(t);break;case o.geoJSON.Polygon:r=a._parseGeoJSON(t);break;case o.geoJSON.MultiPoint:r=u._parseGeoJSON(t);break;case o.geoJSON.MultiLineString:r=c._parseGeoJSON(t);break;case o.geoJSON.MultiPolygon:r=f._parseGeoJSON(t);break;case o.geoJSON.GeometryCollection:r=p._parseGeoJSON(t);break;default:throw new Error("GeometryType "+t.type+" not supported")}if(t.crs&&t.crs.type&&"name"===t.crs.type&&t.crs.properties&&t.crs.properties.name){var n=t.crs.properties.name;if(0===n.indexOf("EPSG:"))r.srid=parseInt(n.substring(5));else{if(0!==n.indexOf("urn:ogc:def:crs:EPSG::"))throw new Error("Unsupported crs: "+n);r.srid=parseInt(n.substring(22))}}else e||(r.srid=4326);return r},d.prototype.toEwkt=function(){return"SRID="+this.srid+";"+this.toWkt()},d.prototype.toEwkb=function(){var t=new h(this._getWkbSize()+4),e=this.toWkb();return t.writeInt8(1),t.writeUInt32LE((536870912|e.slice(1,5).readUInt32LE(0))>>>0,!0),t.writeUInt32LE(this.srid),t.writeBuffer(e.slice(5)),t.buffer},d.prototype._getWktType=function(t,e){var r=t;return this.hasZ&&this.hasM?r+=" ZM ":this.hasZ?r+=" Z ":this.hasM&&(r+=" M "),!e||this.hasZ||this.hasM||(r+=" "),e&&(r+="EMPTY"),r},d.prototype._getWktCoordinate=function(t){var e=t.x+" "+t.y;return this.hasZ&&(e+=" "+t.z),this.hasM&&(e+=" "+t.m),e},d.prototype._writeWkbType=function(t,e,r){var n=0;void 0!==this.srid||r&&void 0!==r.srid?(this.hasZ&&(n|=2147483648),this.hasM&&(n|=1073741824)):this.hasZ&&this.hasM?n+=3e3:this.hasZ?n+=1e3:this.hasM&&(n+=2e3),t.writeUInt32LE(n+e>>>0,!0)},d.getTwkbPrecision=function(t,e,r){return{xy:t,z:e,m:r,xyFactor:Math.pow(10,t),zFactor:Math.pow(10,e),mFactor:Math.pow(10,r)}},d.prototype._writeTwkbHeader=function(t,e,r,n){var o=(g.encode(r.xy)<<4)+e,i=(this.hasZ||this.hasM)<<3;if(i+=n<<4,t.writeUInt8(o),t.writeUInt8(i),this.hasZ||this.hasM){var s=0;this.hasZ&&(s|=1),this.hasM&&(s|=2),t.writeUInt8(s)}},d.prototype.toGeoJSON=function(t){var e={};return this.srid&&t&&(t.shortCrs?e.crs={type:"name",properties:{name:"EPSG:"+this.srid}}:t.longCrs&&(e.crs={type:"name",properties:{name:"urn:ogc:def:crs:EPSG::"+this.srid}})),e}},1141:(t,e,r)=>{t.exports=a;var n=r(537),o=r(740),i=r(2957),s=r(1199);function a(t,e){i.call(this),this.geometries=t||[],this.srid=e,this.geometries.length>0&&(this.hasZ=this.geometries[0].hasZ,this.hasM=this.geometries[0].hasM)}n.inherits(a,i),a.Z=function(t,e){var r=new a(t,e);return r.hasZ=!0,r},a.M=function(t,e){var r=new a(t,e);return r.hasM=!0,r},a.ZM=function(t,e){var r=new a(t,e);return r.hasZ=!0,r.hasM=!0,r},a._parseWkt=function(t,e){var r=new a;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{r.geometries.push(i.parse(t))}while(t.isMatch([","]));return t.expectGroupEnd(),r},a._parseWkb=function(t,e){var r=new a;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.geometries.push(i.parse(t,e));return r},a._parseTwkb=function(t,e){var r=new a;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=t.readVarInt(),o=0;o<n;o++)r.geometries.push(i.parseTwkb(t));return r},a._parseGeoJSON=function(t){for(var e=new a,r=0;r<t.geometries.length;r++)e.geometries.push(i._parseGeoJSON(t.geometries[r],!0));return e.geometries.length>0&&(e.hasZ=e.geometries[0].hasZ),e},a.prototype.toWkt=function(){if(0===this.geometries.length)return this._getWktType(o.wkt.GeometryCollection,!0);for(var t=this._getWktType(o.wkt.GeometryCollection,!1)+"(",e=0;e<this.geometries.length;e++)t+=this.geometries[e].toWkt()+",";return(t=t.slice(0,-1))+")"},a.prototype.toWkb=function(){var t=new s(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.GeometryCollection),t.writeUInt32LE(this.geometries.length);for(var e=0;e<this.geometries.length;e++)t.writeBuffer(this.geometries[e].toWkb({srid:this.srid}));return t.buffer},a.prototype.toTwkb=function(){var t=new s(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.geometries.length;if(this._writeTwkbHeader(t,o.wkb.GeometryCollection,e,r),this.geometries.length>0){t.writeVarInt(this.geometries.length);for(var n=0;n<this.geometries.length;n++)t.writeBuffer(this.geometries[n].toTwkb())}return t.buffer},a.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.geometries.length;e++)t+=this.geometries[e]._getWkbSize();return t},a.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.GeometryCollection,e.geometries=[];for(var r=0;r<this.geometries.length;r++)e.geometries.push(this.geometries[r].toGeoJSON());return e}},350:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(4263),a=r(1199);function u(t,e){o.call(this),this.points=t||[],this.srid=e,this.points.length>0&&(this.hasZ=this.points[0].hasZ,this.hasM=this.points[0].hasM)}n.inherits(u,o),u.Z=function(t,e){var r=new u(t,e);return r.hasZ=!0,r},u.M=function(t,e){var r=new u(t,e);return r.hasM=!0,r},u.ZM=function(t,e){var r=new u(t,e);return r.hasZ=!0,r.hasM=!0,r},u._parseWkt=function(t,e){var r=new u;return r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"])||(t.expectGroupStart(),r.points.push.apply(r.points,t.matchCoordinates(e)),t.expectGroupEnd()),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.points.push(s._readWkbPoint(t,e));return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++)r.points.push(s._readTwkbPoint(t,e,n));return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&(e.hasZ=t.coordinates[0].length>2);for(var r=0;r<t.coordinates.length;r++)e.points.push(s._readGeoJSONPoint(t.coordinates[r]));return e},u.prototype.toWkt=function(){return 0===this.points.length?this._getWktType(i.wkt.LineString,!0):this._getWktType(i.wkt.LineString,!1)+this._toInnerWkt()},u.prototype._toInnerWkt=function(){for(var t="(",e=0;e<this.points.length;e++)t+=this._getWktCoordinate(this.points[e])+",";return(t=t.slice(0,-1))+")"},u.prototype.toWkb=function(t){var e=new a(this._getWkbSize());e.writeInt8(1),this._writeWkbType(e,i.wkb.LineString,t),e.writeUInt32LE(this.points.length);for(var r=0;r<this.points.length;r++)this.points[r]._writeWkbPoint(e);return e.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=o.getTwkbPrecision(5,0,0),r=0===this.points.length;if(this._writeTwkbHeader(t,i.wkb.LineString,e,r),this.points.length>0){t.writeVarInt(this.points.length);for(var n=new s(0,0,0,0),u=0;u<this.points.length;u++)this.points[u]._writeTwkbPoint(t,e,n)}return t.buffer},u.prototype._getWkbSize=function(){var t=16;return this.hasZ&&(t+=8),this.hasM&&(t+=8),9+this.points.length*t},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);e.type=i.geoJSON.LineString,e.coordinates=[];for(var r=0;r<this.points.length;r++)this.hasZ?e.coordinates.push([this.points[r].x,this.points[r].y,this.points[r].z]):e.coordinates.push([this.points[r].x,this.points[r].y]);return e}},3959:(t,e,r)=>{t.exports=c;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(350),u=r(1199);function c(t,e){i.call(this),this.lineStrings=t||[],this.srid=e,this.lineStrings.length>0&&(this.hasZ=this.lineStrings[0].hasZ,this.hasM=this.lineStrings[0].hasM)}n.inherits(c,i),c.Z=function(t,e){var r=new c(t,e);return r.hasZ=!0,r},c.M=function(t,e){var r=new c(t,e);return r.hasM=!0,r},c.ZM=function(t,e){var r=new c(t,e);return r.hasZ=!0,r.hasM=!0,r},c._parseWkt=function(t,e){var r=new c;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{t.expectGroupStart(),r.lineStrings.push(new a(t.matchCoordinates(e))),t.expectGroupEnd()}while(t.isMatch([","]));return t.expectGroupEnd(),r},c._parseWkb=function(t,e){var r=new c;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.lineStrings.push(i.parse(t,e));return r},c._parseTwkb=function(t,e){var r=new c;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++){var u=new a;u.hasZ=e.hasZ,u.hasM=e.hasM;for(var f=t.readVarInt(),p=0;p<f;p++)u.points.push(s._readTwkbPoint(t,e,n));r.lineStrings.push(u)}return r},c._parseGeoJSON=function(t){var e=new c;t.coordinates.length>0&&t.coordinates[0].length>0&&(e.hasZ=t.coordinates[0][0].length>2);for(var r=0;r<t.coordinates.length;r++)e.lineStrings.push(a._parseGeoJSON({coordinates:t.coordinates[r]}));return e},c.prototype.toWkt=function(){if(0===this.lineStrings.length)return this._getWktType(o.wkt.MultiLineString,!0);for(var t=this._getWktType(o.wkt.MultiLineString,!1)+"(",e=0;e<this.lineStrings.length;e++)t+=this.lineStrings[e]._toInnerWkt()+",";return(t=t.slice(0,-1))+")"},c.prototype.toWkb=function(){var t=new u(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiLineString),t.writeUInt32LE(this.lineStrings.length);for(var e=0;e<this.lineStrings.length;e++)t.writeBuffer(this.lineStrings[e].toWkb({srid:this.srid}));return t.buffer},c.prototype.toTwkb=function(){var t=new u(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.lineStrings.length;if(this._writeTwkbHeader(t,o.wkb.MultiLineString,e,r),this.lineStrings.length>0){t.writeVarInt(this.lineStrings.length);for(var n=new s(0,0,0,0),a=0;a<this.lineStrings.length;a++){t.writeVarInt(this.lineStrings[a].points.length);for(var c=0;c<this.lineStrings[a].points.length;c++)this.lineStrings[a].points[c]._writeTwkbPoint(t,e,n)}}return t.buffer},c.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.lineStrings.length;e++)t+=this.lineStrings[e]._getWkbSize();return t},c.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiLineString,e.coordinates=[];for(var r=0;r<this.lineStrings.length;r++)e.coordinates.push(this.lineStrings[r].toGeoJSON().coordinates);return e}},3452:(t,e,r)=>{t.exports=u;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(1199);function u(t,e){i.call(this),this.points=t||[],this.srid=e,this.points.length>0&&(this.hasZ=this.points[0].hasZ,this.hasM=this.points[0].hasM)}n.inherits(u,i),u.Z=function(t,e){var r=new u(t,e);return r.hasZ=!0,r},u.M=function(t,e){var r=new u(t,e);return r.hasM=!0,r},u.ZM=function(t,e){var r=new u(t,e);return r.hasZ=!0,r.hasM=!0,r},u._parseWkt=function(t,e){var r=new u;return r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"])||(t.expectGroupStart(),r.points.push.apply(r.points,t.matchCoordinates(e)),t.expectGroupEnd()),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.points.push(i.parse(t,e));return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++)r.points.push(s._readTwkbPoint(t,e,n));return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&(e.hasZ=t.coordinates[0].length>2);for(var r=0;r<t.coordinates.length;r++)e.points.push(s._parseGeoJSON({coordinates:t.coordinates[r]}));return e},u.prototype.toWkt=function(){if(0===this.points.length)return this._getWktType(o.wkt.MultiPoint,!0);for(var t=this._getWktType(o.wkt.MultiPoint,!1)+"(",e=0;e<this.points.length;e++)t+=this._getWktCoordinate(this.points[e])+",";return(t=t.slice(0,-1))+")"},u.prototype.toWkb=function(){var t=new a(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiPoint),t.writeUInt32LE(this.points.length);for(var e=0;e<this.points.length;e++)t.writeBuffer(this.points[e].toWkb({srid:this.srid}));return t.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.points.length;if(this._writeTwkbHeader(t,o.wkb.MultiPoint,e,r),this.points.length>0){t.writeVarInt(this.points.length);for(var n=new s(0,0,0,0),u=0;u<this.points.length;u++)this.points[u]._writeTwkbPoint(t,e,n)}return t.buffer},u.prototype._getWkbSize=function(){var t=16;return this.hasZ&&(t+=8),this.hasM&&(t+=8),t+=5,9+this.points.length*t},u.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiPoint,e.coordinates=[];for(var r=0;r<this.points.length;r++)e.coordinates.push(this.points[r].toGeoJSON().coordinates);return e}},9236:(t,e,r)=>{t.exports=c;var n=r(537),o=r(740),i=r(2957),s=r(4263),a=r(743),u=r(1199);function c(t,e){i.call(this),this.polygons=t||[],this.srid=e,this.polygons.length>0&&(this.hasZ=this.polygons[0].hasZ,this.hasM=this.polygons[0].hasM)}n.inherits(c,i),c.Z=function(t,e){var r=new c(t,e);return r.hasZ=!0,r},c.M=function(t,e){var r=new c(t,e);return r.hasM=!0,r},c.ZM=function(t,e){var r=new c(t,e);return r.hasZ=!0,r.hasM=!0,r},c._parseWkt=function(t,e){var r=new c;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();do{t.expectGroupStart();var n=[],o=[];for(t.expectGroupStart(),n.push.apply(n,t.matchCoordinates(e)),t.expectGroupEnd();t.isMatch([","]);)t.expectGroupStart(),o.push(t.matchCoordinates(e)),t.expectGroupEnd();r.polygons.push(new a(n,o)),t.expectGroupEnd()}while(t.isMatch([","]));return t.expectGroupEnd(),r},c._parseWkb=function(t,e){var r=new c;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;for(var n=t.readUInt32(),o=0;o<n;o++)r.polygons.push(i.parse(t,e));return r},c._parseTwkb=function(t,e){var r=new c;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=0;i<o;i++){var u=new a;u.hasZ=e.hasZ,u.hasM=e.hasM;for(var f=t.readVarInt(),p=t.readVarInt(),l=0;l<p;l++)u.exteriorRing.push(s._readTwkbPoint(t,e,n));for(l=1;l<f;l++){for(var h=[],y=t.readVarInt(),g=0;g<y;g++)h.push(s._readTwkbPoint(t,e,n));u.interiorRings.push(h)}r.polygons.push(u)}return r},c._parseGeoJSON=function(t){var e=new c;t.coordinates.length>0&&t.coordinates[0].length>0&&t.coordinates[0][0].length>0&&(e.hasZ=t.coordinates[0][0][0].length>2);for(var r=0;r<t.coordinates.length;r++)e.polygons.push(a._parseGeoJSON({coordinates:t.coordinates[r]}));return e},c.prototype.toWkt=function(){if(0===this.polygons.length)return this._getWktType(o.wkt.MultiPolygon,!0);for(var t=this._getWktType(o.wkt.MultiPolygon,!1)+"(",e=0;e<this.polygons.length;e++)t+=this.polygons[e]._toInnerWkt()+",";return(t=t.slice(0,-1))+")"},c.prototype.toWkb=function(){var t=new u(this._getWkbSize());t.writeInt8(1),this._writeWkbType(t,o.wkb.MultiPolygon),t.writeUInt32LE(this.polygons.length);for(var e=0;e<this.polygons.length;e++)t.writeBuffer(this.polygons[e].toWkb({srid:this.srid}));return t.buffer},c.prototype.toTwkb=function(){var t=new u(0,!0),e=i.getTwkbPrecision(5,0,0),r=0===this.polygons.length;if(this._writeTwkbHeader(t,o.wkb.MultiPolygon,e,r),this.polygons.length>0){t.writeVarInt(this.polygons.length);for(var n=new s(0,0,0,0),a=0;a<this.polygons.length;a++){t.writeVarInt(1+this.polygons[a].interiorRings.length),t.writeVarInt(this.polygons[a].exteriorRing.length);for(var c=0;c<this.polygons[a].exteriorRing.length;c++)this.polygons[a].exteriorRing[c]._writeTwkbPoint(t,e,n);for(c=0;c<this.polygons[a].interiorRings.length;c++){t.writeVarInt(this.polygons[a].interiorRings[c].length);for(var f=0;f<this.polygons[a].interiorRings[c].length;f++)this.polygons[a].interiorRings[c][f]._writeTwkbPoint(t,e,n)}}}return t.buffer},c.prototype._getWkbSize=function(){for(var t=9,e=0;e<this.polygons.length;e++)t+=this.polygons[e]._getWkbSize();return t},c.prototype.toGeoJSON=function(t){var e=i.prototype.toGeoJSON.call(this,t);e.type=o.geoJSON.MultiPolygon,e.coordinates=[];for(var r=0;r<this.polygons.length;r++)e.coordinates.push(this.polygons[r].toGeoJSON().coordinates);return e}},4263:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(1199),a=r(1865);function u(t,e,r,n,i){o.call(this),this.x=t,this.y=e,this.z=r,this.m=n,this.srid=i,this.hasZ=void 0!==this.z,this.hasM=void 0!==this.m}n.inherits(u,o),u.Z=function(t,e,r,n){var o=new u(t,e,r,void 0,n);return o.hasZ=!0,o},u.M=function(t,e,r,n){var o=new u(t,e,void 0,r,n);return o.hasM=!0,o},u.ZM=function(t,e,r,n,o){var i=new u(t,e,r,n,o);return i.hasZ=!0,i.hasM=!0,i},u._parseWkt=function(t,e){var r=new u;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;t.expectGroupStart();var n=t.matchCoordinate(e);return r.x=n.x,r.y=n.y,r.z=n.z,r.m=n.m,t.expectGroupEnd(),r},u._parseWkb=function(t,e){var r=u._readWkbPoint(t,e);return r.srid=e.srid,r},u._readWkbPoint=function(t,e){return new u(t.readDouble(),t.readDouble(),e.hasZ?t.readDouble():void 0,e.hasM?t.readDouble():void 0)},u._parseTwkb=function(t,e){var r=new u;return r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty||(r.x=a.decode(t.readVarInt())/e.precisionFactor,r.y=a.decode(t.readVarInt())/e.precisionFactor,r.z=e.hasZ?a.decode(t.readVarInt())/e.zPrecisionFactor:void 0,r.m=e.hasM?a.decode(t.readVarInt())/e.mPrecisionFactor:void 0),r},u._readTwkbPoint=function(t,e,r){return r.x+=a.decode(t.readVarInt())/e.precisionFactor,r.y+=a.decode(t.readVarInt())/e.precisionFactor,e.hasZ&&(r.z+=a.decode(t.readVarInt())/e.zPrecisionFactor),e.hasM&&(r.m+=a.decode(t.readVarInt())/e.mPrecisionFactor),new u(r.x,r.y,r.z,r.m)},u._parseGeoJSON=function(t){return u._readGeoJSONPoint(t.coordinates)},u._readGeoJSONPoint=function(t){return 0===t.length?new u:t.length>2?new u(t[0],t[1],t[2]):new u(t[0],t[1])},u.prototype.toWkt=function(){return void 0===this.x&&void 0===this.y&&void 0===this.z&&void 0===this.m?this._getWktType(i.wkt.Point,!0):this._getWktType(i.wkt.Point,!1)+"("+this._getWktCoordinate(this)+")"},u.prototype.toWkb=function(t){var e=new s(this._getWkbSize());return e.writeInt8(1),this._writeWkbType(e,i.wkb.Point,t),void 0===this.x&&void 0===this.y?(e.writeDoubleLE(NaN),e.writeDoubleLE(NaN),this.hasZ&&e.writeDoubleLE(NaN),this.hasM&&e.writeDoubleLE(NaN)):this._writeWkbPoint(e),e.buffer},u.prototype._writeWkbPoint=function(t){t.writeDoubleLE(this.x),t.writeDoubleLE(this.y),this.hasZ&&t.writeDoubleLE(this.z),this.hasM&&t.writeDoubleLE(this.m)},u.prototype.toTwkb=function(){var t=new s(0,!0),e=o.getTwkbPrecision(5,0,0),r=void 0===this.x&&void 0===this.y;return this._writeTwkbHeader(t,i.wkb.Point,e,r),r||this._writeTwkbPoint(t,e,new u(0,0,0,0)),t.buffer},u.prototype._writeTwkbPoint=function(t,e,r){var n=this.x*e.xyFactor,o=this.y*e.xyFactor,i=this.z*e.zFactor,s=this.m*e.mFactor;t.writeVarInt(a.encode(n-r.x)),t.writeVarInt(a.encode(o-r.y)),this.hasZ&&t.writeVarInt(a.encode(i-r.z)),this.hasM&&t.writeVarInt(a.encode(s-r.m)),r.x=n,r.y=o,r.z=i,r.m=s},u.prototype._getWkbSize=function(){var t=21;return this.hasZ&&(t+=8),this.hasM&&(t+=8),t},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);return e.type=i.geoJSON.Point,void 0===this.x&&void 0===this.y?e.coordinates=[]:void 0!==this.z?e.coordinates=[this.x,this.y,this.z]:e.coordinates=[this.x,this.y],e}},743:(t,e,r)=>{t.exports=u;var n=r(537),o=r(2957),i=r(740),s=r(4263),a=r(1199);function u(t,e,r){o.call(this),this.exteriorRing=t||[],this.interiorRings=e||[],this.srid=r,this.exteriorRing.length>0&&(this.hasZ=this.exteriorRing[0].hasZ,this.hasM=this.exteriorRing[0].hasM)}n.inherits(u,o),u.Z=function(t,e,r){var n=new u(t,e,r);return n.hasZ=!0,n},u.M=function(t,e,r){var n=new u(t,e,r);return n.hasM=!0,n},u.ZM=function(t,e,r){var n=new u(t,e,r);return n.hasZ=!0,n.hasM=!0,n},u._parseWkt=function(t,e){var r=new u;if(r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM,t.isMatch(["EMPTY"]))return r;for(t.expectGroupStart(),t.expectGroupStart(),r.exteriorRing.push.apply(r.exteriorRing,t.matchCoordinates(e)),t.expectGroupEnd();t.isMatch([","]);)t.expectGroupStart(),r.interiorRings.push(t.matchCoordinates(e)),t.expectGroupEnd();return t.expectGroupEnd(),r},u._parseWkb=function(t,e){var r=new u;r.srid=e.srid,r.hasZ=e.hasZ,r.hasM=e.hasM;var n=t.readUInt32();if(n>0){for(var o=t.readUInt32(),i=0;i<o;i++)r.exteriorRing.push(s._readWkbPoint(t,e));for(i=1;i<n;i++){for(var a=[],c=t.readUInt32(),f=0;f<c;f++)a.push(s._readWkbPoint(t,e));r.interiorRings.push(a)}}return r},u._parseTwkb=function(t,e){var r=new u;if(r.hasZ=e.hasZ,r.hasM=e.hasM,e.isEmpty)return r;for(var n=new s(0,0,e.hasZ?0:void 0,e.hasM?0:void 0),o=t.readVarInt(),i=t.readVarInt(),a=0;a<i;a++)r.exteriorRing.push(s._readTwkbPoint(t,e,n));for(a=1;a<o;a++){for(var c=[],f=t.readVarInt(),p=0;p<f;p++)c.push(s._readTwkbPoint(t,e,n));r.interiorRings.push(c)}return r},u._parseGeoJSON=function(t){var e=new u;t.coordinates.length>0&&t.coordinates[0].length>0&&(e.hasZ=t.coordinates[0][0].length>2);for(var r=0;r<t.coordinates.length;r++){r>0&&e.interiorRings.push([]);for(var n=0;n<t.coordinates[r].length;n++)0===r?e.exteriorRing.push(s._readGeoJSONPoint(t.coordinates[r][n])):e.interiorRings[r-1].push(s._readGeoJSONPoint(t.coordinates[r][n]))}return e},u.prototype.toWkt=function(){return 0===this.exteriorRing.length?this._getWktType(i.wkt.Polygon,!0):this._getWktType(i.wkt.Polygon,!1)+this._toInnerWkt()},u.prototype._toInnerWkt=function(){for(var t="((",e=0;e<this.exteriorRing.length;e++)t+=this._getWktCoordinate(this.exteriorRing[e])+",";for(t=t.slice(0,-1),t+=")",e=0;e<this.interiorRings.length;e++){t+=",(";for(var r=0;r<this.interiorRings[e].length;r++)t+=this._getWktCoordinate(this.interiorRings[e][r])+",";t=t.slice(0,-1),t+=")"}return t+")"},u.prototype.toWkb=function(t){var e=new a(this._getWkbSize());e.writeInt8(1),this._writeWkbType(e,i.wkb.Polygon,t),this.exteriorRing.length>0?(e.writeUInt32LE(1+this.interiorRings.length),e.writeUInt32LE(this.exteriorRing.length)):e.writeUInt32LE(0);for(var r=0;r<this.exteriorRing.length;r++)this.exteriorRing[r]._writeWkbPoint(e);for(r=0;r<this.interiorRings.length;r++){e.writeUInt32LE(this.interiorRings[r].length);for(var n=0;n<this.interiorRings[r].length;n++)this.interiorRings[r][n]._writeWkbPoint(e)}return e.buffer},u.prototype.toTwkb=function(){var t=new a(0,!0),e=o.getTwkbPrecision(5,0,0),r=0===this.exteriorRing.length;if(this._writeTwkbHeader(t,i.wkb.Polygon,e,r),this.exteriorRing.length>0){t.writeVarInt(1+this.interiorRings.length),t.writeVarInt(this.exteriorRing.length);for(var n=new s(0,0,0,0),u=0;u<this.exteriorRing.length;u++)this.exteriorRing[u]._writeTwkbPoint(t,e,n);for(u=0;u<this.interiorRings.length;u++){t.writeVarInt(this.interiorRings[u].length);for(var c=0;c<this.interiorRings[u].length;c++)this.interiorRings[u][c]._writeTwkbPoint(t,e,n)}}return t.buffer},u.prototype._getWkbSize=function(){var t=16;this.hasZ&&(t+=8),this.hasM&&(t+=8);var e=9;this.exteriorRing.length>0&&(e+=4+this.exteriorRing.length*t);for(var r=0;r<this.interiorRings.length;r++)e+=4+this.interiorRings[r].length*t;return e},u.prototype.toGeoJSON=function(t){var e=o.prototype.toGeoJSON.call(this,t);if(e.type=i.geoJSON.Polygon,e.coordinates=[],this.exteriorRing.length>0){for(var r=[],n=0;n<this.exteriorRing.length;n++)this.hasZ?r.push([this.exteriorRing[n].x,this.exteriorRing[n].y,this.exteriorRing[n].z]):r.push([this.exteriorRing[n].x,this.exteriorRing[n].y]);e.coordinates.push(r)}for(var s=0;s<this.interiorRings.length;s++){for(var a=[],u=0;u<this.interiorRings[s].length;u++)this.hasZ?a.push([this.interiorRings[s][u].x,this.interiorRings[s][u].y,this.interiorRings[s][u].z]):a.push([this.interiorRings[s][u].x,this.interiorRings[s][u].y]);e.coordinates.push(a)}return e}},740:t=>{t.exports={wkt:{Point:"POINT",LineString:"LINESTRING",Polygon:"POLYGON",MultiPoint:"MULTIPOINT",MultiLineString:"MULTILINESTRING",MultiPolygon:"MULTIPOLYGON",GeometryCollection:"GEOMETRYCOLLECTION"},wkb:{Point:1,LineString:2,Polygon:3,MultiPoint:4,MultiLineString:5,MultiPolygon:6,GeometryCollection:7},geoJSON:{Point:"Point",LineString:"LineString",Polygon:"Polygon",MultiPoint:"MultiPoint",MultiLineString:"MultiLineString",MultiPolygon:"MultiPolygon",GeometryCollection:"GeometryCollection"}}},2104:(t,e,r)=>{t.exports=i;var n=r(740),o=r(4263);function i(t){this.value=t,this.position=0}i.prototype.match=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++)if(0===this.value.substring(this.position).indexOf(t[e]))return this.position+=t[e].length,t[e];return null},i.prototype.matchRegex=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++){var r=this.value.substring(this.position).match(t[e]);if(r)return this.position+=r[0].length,r}return null},i.prototype.isMatch=function(t){this.skipWhitespaces();for(var e=0;e<t.length;e++)if(0===this.value.substring(this.position).indexOf(t[e]))return this.position+=t[e].length,!0;return!1},i.prototype.matchType=function(){var t=this.match([n.wkt.Point,n.wkt.LineString,n.wkt.Polygon,n.wkt.MultiPoint,n.wkt.MultiLineString,n.wkt.MultiPolygon,n.wkt.GeometryCollection]);if(!t)throw new Error("Expected geometry type");return t},i.prototype.matchDimension=function(){switch(this.match(["ZM","Z","M"])){case"ZM":return{hasZ:!0,hasM:!0};case"Z":return{hasZ:!0,hasM:!1};case"M":return{hasZ:!1,hasM:!0};default:return{hasZ:!1,hasM:!1}}},i.prototype.expectGroupStart=function(){if(!this.isMatch(["("]))throw new Error("Expected group start")},i.prototype.expectGroupEnd=function(){if(!this.isMatch([")"]))throw new Error("Expected group end")},i.prototype.matchCoordinate=function(t){var e;if(!(e=t.hasZ&&t.hasM?this.matchRegex([/^(\S*)\s+(\S*)\s+(\S*)\s+([^\s,)]*)/]):t.hasZ||t.hasM?this.matchRegex([/^(\S*)\s+(\S*)\s+([^\s,)]*)/]):this.matchRegex([/^(\S*)\s+([^\s,)]*)/])))throw new Error("Expected coordinates");return t.hasZ&&t.hasM?new o(parseFloat(e[1]),parseFloat(e[2]),parseFloat(e[3]),parseFloat(e[4])):t.hasZ?new o(parseFloat(e[1]),parseFloat(e[2]),parseFloat(e[3])):t.hasM?new o(parseFloat(e[1]),parseFloat(e[2]),void 0,parseFloat(e[3])):new o(parseFloat(e[1]),parseFloat(e[2]))},i.prototype.matchCoordinates=function(t){var e=[];do{var r=this.isMatch(["("]);e.push(this.matchCoordinate(t)),r&&this.expectGroupEnd()}while(this.isMatch([","]));return e},i.prototype.skipWhitespaces=function(){for(;this.position<this.value.length&&" "===this.value[this.position];)this.position++}},543:(t,e,r)=>{e.Types=r(740),e.Geometry=r(2957),e.Point=r(4263),e.LineString=r(350),e.Polygon=r(743),e.MultiPoint=r(3452),e.MultiLineString=r(3959),e.MultiPolygon=r(9236),e.GeometryCollection=r(1141)},1865:t=>{t.exports={encode:function(t){return t<<1^t>>31},decode:function(t){return t>>1^-(1&t)}}},9209:(t,e,r)=>{"use strict";var n=r(6578),o="undefined"==typeof globalThis?r.g:globalThis;t.exports=function(){for(var t=[],e=0;e<n.length;e++)"function"==typeof o[n[e]]&&(t[t.length]=n[e]);return t}}},e={};function r(n){var o=e[n];if(void 0!==o)return o.exports;var i=e[n]={exports:{}};return t[n](i,i.exports,r),i.exports}r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};return(()=>{"use strict";r.r(n),r.d(n,{addDatesToGaps:()=>Mt,addPointInteger:()=>d,calcularRuta:()=>rt,calculateXAxisMonth:()=>b,calculateXAxisStart:()=>gt,calculateXAxisYear:()=>w,changeImg:()=>tt,closeFilter:()=>At,closePopUp:()=>Et,commonPostFetch:()=>q,configureDataGaugeMonth:()=>H,configureDataLine:()=>V,configureGaugeYearBig:()=>wt,createCheckBoxFilter:()=>it,createCheckBoxFilterVar:()=>at,createGauge:()=>J,createLeafletMap:()=>Pt,createLeafletMapPolygon:()=>Ot,createObjectMarkerElements:()=>Tt,drawMarkers:()=>Bt,drawMarkersPolygon:()=>Rt,echartGaugeMonth:()=>R,echartGaugeYear:()=>U,echartLine:()=>bt,echartVerStackedBar:()=>B,filterDatesUpdate:()=>S,filterVarUpdate:()=>st,filterWindow:()=>kt,formatDDMM:()=>ht,formatName:()=>z,formatRoundTooltip:()=>j,formatSixDigitDate:()=>ft,formatTooltip:()=>m,formatearFecha:()=>lt,formatoFecha:()=>ut,formatoFecha2:()=>ct,formatoFecha3:()=>pt,formatterReloj:()=>T,generateDatesArray:()=>St,getCommonOptionDonut:()=>N,getCommonOptionGaugeUmbral:()=>W,getCommonOptionPie:()=>Z,getCommonOptions:()=>_,getCommonOptionsBar:()=>F,getCommonOptionsGaugeMonth:()=>D,getCommonOptionsGaugeYears:()=>G,getConfigurationGaugeYears:()=>C,getDateFromStr:()=>mt,getMaxValue:()=>O,getMonth:()=>x,getMonthComplete:()=>E,getStringFromDate:()=>vt,getTime:()=>yt,getWidthElementChart:()=>P,includeHTMLCabecera:()=>X,includeHTMLFooter:()=>Q,includeHTMLMenu:()=>K,indoPopUp:()=>xt,initChart:()=>Y,llamadasIniciales:()=>ot,normalImg:()=>et,obtenerGeoJson:()=>_t,obtenerRuta:()=>nt,printDataChart:()=>A,printNoDataChart:()=>k,splitData:()=>I,xAxisFormatWithoutYear:()=>dt,yAxisFormat:()=>v});const t="8%",e="2.5%",o="5%",i="18%",s="20%",a="10%",u="90%",c="1%",f="0%",p=["#9c89b8","#4ea8de","#05668d","#ffbf69","#e56b6f","#83c5be","#02c39a","#ee9b00","#cdb4db","#ffadad","#ce4257","#b7b7a4"],l=33,h=[39.46975,-.37739],y=27,g=30;function d(t){let e=navigator.language||navigator.userLanguage;e=e.length<=2?`${e}-${e.toUpperCase()}`:e;const r={minimumFractionDigits:0,maximumFractionDigits:2};return"es-ES"===e?t.toLocaleString("de-DE",r):t.toLocaleString(e,r)}function b(t){return 100*(1-17/t)}function w(t){return 100*(1-7/t)}function m(t,e=!1){let r=`<p>${t[0].name}</p>`;return t.forEach((t=>{const n=e?Math.round(t.data):t.data,o=`<div>${i=t.color,`<span style="display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:${i}"></span>`} ${t.seriesName}: <strong style="float: right; margin-left:20px">${t.data?d(n):"-"}</strong></div>`;var i;r+=o})),r}function v(t){return d(t)}function S(){const t=$("#formFilterDates").find("input"),e=[];$(t).each(((t,r)=>{r.checked&&e.push(r.id)})),Dashboards.fireChange("filterDatesParam",e),Dashboards.fireChange("updateFilter","True")}function M(){const t=$("#formFilterDates").find("input");$(t).each(((t,e)=>{e.checked&&(e.checked=!1)}));const e=$("#formFilterVar").find("input");$(e).each(((t,e)=>{e.checked&&(e.checked=!1)})),function(){let t=0;const e=$("#formFilterDates").find("input");$(e).each(((e,r)=>{t+=1,r.checked=!0})),t=0;const r=$("#formFilterVar").find("input");$(r).each(((e,r)=>{t+=1,null!=render_tableVariacio?t<=2&&(r.checked=!0):t<=3&&(r.checked=!0)})),console.error(`VALORES FILTRO: ${Dashboards.getParameterValue("filterVarParam")}`),Dashboards.getParameterValue("filterVarParam").length>0&&Dashboards.fireChange("filterVarParam")}()}function x(t){return{1:"Gen",2:"Feb",3:"Mar",4:"Abr",5:"Mai",6:"Jun",7:"Jul",8:"Ago",9:"Sep",10:"Oct",11:"Nov",12:"Des"}[parseInt(t.toString(),10)]}function E(t){return{1:"GENER",2:"FEBRER",3:"MARÇ",4:"ABRIL",5:"MAIG",6:"JUNY",7:"JULIO",8:"AGOST",9:"SETEMBRE",10:"OCTUBRE",11:"NOVEMBRE",12:"DESEMBRE"}[t]}function k(t,e){const r=t?document.querySelector(t):null,n=e?document.querySelector(e):null;r&&(r.hidden=!0),n&&(n.style.background="url('./build/images/nodata1.png') no-repeat top center",n.hidden=!1)}function A(t,e){const r=t?document.querySelector(t):null,n=e?document.querySelector(e):null;r&&(r.hidden=!0),n&&(n.style.background="#ffffff",n.hidden=!1)}function I(t,e){return t.reduce(((t,r)=>{const n=r[e];return t[n]||(t[n]=[]),t[n].push(r),t}),{})}function O(t,e,r=1){const n=Math.max(...t.map((t=>t[e])))*r;return 5e3*Math.ceil(n/5e3)}function P(t){return Math.round(document.getElementById(t).offsetWidth/l)}function T(t,e,r){const n=d(Math.round(e)),o=x(t[r][0]),i=t[r][1],s=`\n\n\n${o} ${i} : ${n}`,a=`${n}\n${o} ${i}`;return window.innerWidth<=1710?s:a}function _(r,n,p,l,h,y,g,d=5,b="",w=h,S=100,M,x=void 0,E=void 0){return{title:{text:b,left:"center",top:"top",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"axis",show:!0,formatter:t=>m(t),textStyle:{fontFamily:"Montserrat"}},legend:n?{type:"plain",data:n,textStyle:{fontFamily:"Montserrat"},top:x||t,selected:M}:null,grid:{left:e,right:o,bottom:i,top:n?x?"30%":s:a,heigh:u,containLabel:!0},xAxis:{type:"category",data:p,boundaryGap:!1,splitLine:{show:!1},axisLabel:{textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#666"}}},yAxis:{name:l,nameLocation:"end",nameTextStyle:{fontFamily:"Montserrat",fontWeight:"bold",padding:[0,0,0,g]},type:"value",scale:!0,min:E,axisLabel:{margin:d,formatter:v,textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#666"}}},series:r,dataZoom:[{show:y,data:p,start:w,end:S,borderColor:"#eee",fillerColor:"rgba(0,0,0,.05)",textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#333",textBorderColor:"#fff",textBorderWidth:3,fontWeight:"600"},selectedDataBackground:{lineStyle:{color:"#333"},areaStyle:{color:"#ffcd00"}},dataBackground:{backgroundColor:"rgba(0,0,0,1)",lineStyle:{color:"#333"},areaStyle:{color:"rgba(0,0,0,0.5)"}},handleStyle:{color:"rgba(0,0,0,0.2)"},moveHandleStyle:{color:"rgba(0,0,0,0.3)"},emphasis:{handleStyle:{color:"rgba(255,205,0,1)"},moveHandleStyle:{color:"rgba(255,205,0,1)"}}}],toolbox:{show:y,feature:{restore:{title:"Restablir"},saveAsImage:{title:"Desar"}},right:c,top:f}}}function B(t,r,n,a,c="",f="total",l=0,h=1,y=2,g=p){if(0===n.length)k(`#${t}`,`#${r}`);else{A(`#${r}`,`#${t}`);const p=[];let S=I(n,l);const M=new Set(n.map((t=>t[h]))),x=Object.keys(S);M.forEach((t=>{x.forEach((e=>{void 0===S[e].find((e=>e[h]===t))&&(S[e].push([S[e][0][l],t,void 0]),S[e][0][1].length>4?S[e].sort(((t,e)=>{const[r,n]=t[1].split("/"),[o,i]=e[1].split("/"),s=new Date(n,r-1,1),a=new Date(i,o-1,1);return s.getTime()-a.getTime()})):S[e].sort())}))}));const E=Object.entries(S).sort(((t,e)=>t[0].localeCompare(e[0]))),k=""===f?90:0;S=Object.fromEntries(E),Object.keys(S).forEach((t=>{p.push({name:t,type:"bar",stack:f,label:{show:!0,fontFamily:"Montserrat",rotate:k,formatter:t=>d(Math.round(t.value))},emphasis:{focus:"series"},data:S[t].map((t=>t[y]))})}));const O=""!==f?b(M.size):w(M.size);Y(t,{color:g,title:{text:c,left:"center",top:"top",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"},textStyle:{fontFamily:"Montserrat"},formatter:t=>m(t,!0)},legend:{padding:40,textStyle:{fontFamily:"Montserrat"}},grid:{left:e,right:o,bottom:i,top:s,heigh:u,containLabel:!0},yAxis:{type:"value",splitNumber:4,name:a,nameLocation:"end",nameTextStyle:{fontWeight:"bold",fontFamily:"Montserrat",color:"#666"},axisLabel:{formatter:v,textStyle:{fontSize:8,fontFamily:"Montserrat",color:"#666"}}},xAxis:{type:"category",data:[...M],axisLabel:{textStyle:{fontFamily:"Montserrat"}}},series:p,toolbox:{show:!0,feature:{restore:{title:"Restablir"},saveAsImage:{title:"Desar"}},right:50},dataZoom:[{show:!0,data:[...M],start:O,end:100,borderColor:"#eee",fillerColor:"rgba(0,0,0,.05)",textStyle:{fontSize:10,fontFamily:"Montserrat",color:"#333",textBorderColor:"#fff",textBorderWidth:3,fontWeight:"600"},selectedDataBackground:{lineStyle:{color:"#333"},areaStyle:{color:"#ffcd00"}},dataBackground:{backgroundColor:"rgba(0,0,0,1)",lineStyle:{color:"#333"},areaStyle:{color:"rgba(0,0,0,0.5)"}},handleStyle:{color:"rgba(0,0,0,0.2)"},moveHandleStyle:{color:"rgba(0,0,0,0.3)"},emphasis:{handleStyle:{color:"rgba(255,205,0,1)"},moveHandleStyle:{color:"rgba(255,205,0,1)"}}}]})}}function R(t,e,r,n,o,i,s){if(0===o.length)k(`#${t}`,`#${r}`),k(`#${e}`,`#${n}`);else{A(`#${r}`,`#${t}`),A(`#${n}`,`#${e}`);const a=0,u=2,c=H(o,u,1),f=c[0],p=c[1],l=c[2],h=c[3],y=c[5],g=P(t),d=J(f,u,a,y,g),b=J(p,u,a,y,g);Y(t,C(`${i}${E(String(Object.keys(l)[1]))}`,h,d,g)),Y(e,C(`${s}${E(String(Object.keys(l)[0]))}`,h,b,g))}}function U(t,e,r,n){0===r.length?k(`#${t}`,`#${e}`):A(`#${e}`,`#${t}`);const o=O(r,1,1.1),i=P(t);let s=180;o>9999999&&(s=95);const a=J(r,1,0,s,i);Y(t,C(`${n} ${r[0][2]}`,o,a,i))}function F(t,e,r=-45,n="",o=e){const i=new Set,s=[];t.forEach((t=>{const e=t[0].toString().padStart(2,"0");i.add(`${e}/${t[1]}`),s.push(Math.round(t[2]))}));const a=s.length<100?40:80;return _({name:o,type:"bar",smooth:!1,barMaxWidth:40,itemStyle:{color:"#5470c6"},textStyle:{fontFamily:"Montserrat"},data:s},null,Array.from(i.values()),e,a,!0,r,25,n)}function j(t,e){const r=`<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:${t.color};"></span>`;let n=`${t.name} : `;return n+=`<span style="font-weight:bold">${d(t.value)}</span>`,e&&(n+=`<span> (${t.percent}%)</span>`),r+n}function W(t,e,r,n){return{series:[{type:"gauge",center:["50%","50%"],startAngle:200,endAngle:-20,min:0,max:100,splitNumber:0,progress:{show:!1,width:5,itemStyle:{color:"#666"}},axisLine:{lineStyle:{width:18}},axisTick:{show:!1},splitLine:{length:15,lineStyle:{width:2,color:"#999"}},axisLabel:{distance:25,color:"#999",fontSize:20,show:!1},anchor:{show:!0,showAbove:!0,size:25,itemStyle:{borderWidth:10},show:!1},pointer:{show:!0,icon:"path://M12.8,0.7l12,40.1H0.7L12.8,0.7z",length:"12%",width:20,offsetCenter:[0,"-40%"],itemStyle:{color:"#ccc"}},axisLine:{lineStyle:{width:35,color:[[e,"#e56b6f"],[e+r,"#ffbf69"],[1,"#a1c483"]]}},axisTick:{show:!1},splitLine:{show:!1},axisLabel:{show:!1},title:{show:!0,offsetCenter:[0,"45%"],textStyle:{color:"#000",fontStyle:"normal",fontWeight:"400",fontFamily:"Montserrat",fontSize:15}},detail:{fontSize:30,offsetCenter:[0,"90%"],valueAnimation:!0,color:"#666",textStyle:{color:"#000",fontStyle:"normal",fontWeight:"400",fontFamily:"Montserrat",fontSize:35}},data:[{value:t,name:n}]}]}}function N(t,e,r,n){return{tooltip:{trigger:"item",formatter:t=>j(t,!1),textStyle:{fontSize:13.5,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},title:{text:e,left:"center",top:"40%",textStyle:{fontSize:13.5,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},legend:{left:"center",bottom:"0%",textStyle:{fontSize:10,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},series:[{top:"0%",bottom:"15%",type:"pie",radius:r||["65%","75%"],avoidLabelOverlap:!1,itemStyle:{borderRadius:5,borderColor:"#f1f1f1",borderWidth:1},label:{show:!1,position:"center",textStyle:{fontSize:20,fontFamily:"Montserrat",fontWeight:400,color:"#333"}},emphasis:{label:{show:!1,fontSize:20}},labelLine:{show:!1},color:n||["#fcb9b2","#ffd97d","#64a6bd","#98c9a3","#ff9b85"],data:t}]}}function Z(t,e,r,n=p){return{textStyle:{fontFamily:"Montserrat"},title:{text:t,left:"center",top:"top",padding:10,textStyle:{fontSize:r-4,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{trigger:"item",textStyle:{fontFamily:"Montserrat"},formatter:t=>j(t,!0)},legend:{orient:"horizontal",textStyle:{fontFamily:"Montserrat"},left:e.length>5?"10%":"12%",bottom:"10%",top:"65%",selectedMode:!1},series:[{type:"pie",radius:"33%",data:e,color:n,top:"-30%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}],toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:10,top:20}}}function C(t,e,r,n){return{color:p,title:{text:t,left:"center",top:"top",padding:10,textStyle:{fontSize:n,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},tooltip:{show:!0,textStyle:{fontFamily:"Montserrat"},formatter:t=>j(t,!1)},splitNumber:3,series:{type:"gauge",max:e,startAngle:-180,endAngle:0,splitNumber:2,pointer:{show:!1,icon:"roundRect"},progress:{show:!0,overlap:!1,roundCap:!0,clip:!0,itemStyle:{borderWidth:1,borderColor:"#464646"}},axisLine:{lineStyle:{width:60}},splitLine:{show:!0,distance:10,length:10},axisTick:{show:!0,splitNumber:5},axisLabel:{show:!0,distance:70,formatter:t=>d(Math.round(t)),fontFamily:"Montserrat",color:"#666"},data:r,detail:{fontSize:n/1.2,color:"inherit",formatter:t=>d(Math.round(t))}},toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:y,top:g}}}function G(t,e="",r){const n=[],o=O(t,1,1.1),i=o.toString().length>=9?100:95,s=115===i?-45:-35;let a=t.length<5?t.length*s:-190;for(let e=0;e<t.length;e+=1)n.push({value:t[e][1],name:String(t[e][0]),title:{offsetCenter:[String(a),"20%"],fontFamily:"Montserrat"},detail:{offsetCenter:[String(a),"35%"],fontFamily:"Montserrat"}}),a+=i;return C(e,o,n,r)}function D(t,e,r="",n){return{title:{text:r,left:"center",top:"top",padding:10,textStyle:{fontSize:n,fontFamily:"Montserrat",fontWeight:600,color:"#666"}},series:{type:"gauge",startAngle:-180,endAngle:0,splitNumber:2,max:O(t,2),itemStyle:{color:"#FFAB91"},progress:{show:!0,width:30},pointer:{show:!1},axisLine:{lineStyle:{width:30}},axisTick:{distance:10,splitNumber:5,lineStyle:{width:2,color:"#999"}},splitLine:{distance:10,length:14,lineStyle:{width:3,color:"#999"}},axisLabel:{fontFamily:"Montserrat",color:"#666",fontSize:14,show:!0,distance:40,formatter:t=>d(Math.round(t))},anchor:{show:!1},title:{show:!1},detail:{valueAnimation:!0,width:"60%",lineHeight:40,borderRadius:8,offsetCenter:[-5,"-10%"],fontSize:n+5,fontWeight:"bolder",formatter:r=>T(t,r,e),fontFamily:"Montserrat",color:"inherit"},data:[{value:t[e][2]}]},toolbox:{show:!0,feature:{saveAsImage:{title:"Desar"}},right:y,top:g}}}function z(t){if(t.length>=29){const e=t.split(" ");let r="",n="";for(const t of e)`${r} ${t}`.length<=29?r+=(r?" ":"")+t:(n+=`${r}\n`,r=t);return n+=r,n}return t}function J(t,e,r,n,o){let i=20,s=35,a=-190,u=n;t.length<=2&&(a=-140,u+=100,i=25,s=42);const c=p.slice(),f=[];for(let n=0;n<t.length;n+=1)f.push({value:t[n][e],name:z(t[n][r]),color:c.shift(),title:{offsetCenter:[String(a),`${String(i)}%`],fontFamily:"Montserrat",fontSize:o-3},detail:{offsetCenter:[String(a),`${String(s)}%`],fontFamily:"Montserrat"}}),a+=u,(n+1)%3==0&&(s+=30,i+=30,a=-190);return f}function V(t,e,r=!1){const{resultset:n}={resultset:t},o=new Set,i=new Set,s=e,a=n.map((([t,e,n])=>{const s=r?Math.round(n):n;return o.add(t),i.add(e),{day:e,type:t,value:s}})),u=Array.from(i.values()),c=Array.from(o.values());return c.sort(((t,e)=>t.toLowerCase().localeCompare(e.toLowerCase(),"es",{ignorePunctuation:!0}))),[c.map((t=>{const e=a.filter((e=>e.type===t)).map((({day:e,value:r})=>[e,t,r])),r=u.map((t=>{const r=e.find((([e])=>e===t));return r?r[2]:null}));return{name:t,type:"line",symbol:"circle",color:s.shift(),symbolSize:6,smooth:!1,data:r}})),i,c]}function H(t,e,r){const n=O(t,e,1.1);let o=50,i=180;n>9999999&&(o=65,i=95);const s=I(t,r);let[a,u]=Object.values(s);return Object.values(s).slice(1).forEach((t=>{u=t})),[u,a,s,n,o,i]}function Y(t,e){const r=document.getElementById(t);if(!r)return console.error(`No se pudo encontrar el elemento con ID ${t}.`),null;const n=echarts.init(r);return n.setOption(e,!0),$(window).on("resize",(()=>{null!=n&&void 0!==n&&n.resize()})),n}function q(){$("#chart2").css("width","100%")}function X(){let t,e,r,n;const o=document.getElementsByTagName("*");for(t=0;t<o.length;t+=1)if(e=o[t],r=e.getAttribute("include-html-cabecera"),r)return n=new XMLHttpRequest,n.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(e.innerHTML=this.responseText),404===this.status&&(e.innerHTML="No se ha podido cargar correctamente."))},n.open("GET",r,!0),void n.send()}function K(t){let e,r,n,o;const i=document.getElementsByTagName("*");for(e=0;e<i.length;e+=1)if(r=i[e],n=r.getAttribute("include-html-menu"),n)return o=new XMLHttpRequest,o.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(r.innerHTML=this.responseText,$(t).removeClass("imgNavMenu"),$(t).addClass("imgNavMenuActive")),404===this.status&&(r.innerHTML="No se ha podido cargar correctamente."))},o.open("GET",n,!0),void o.send()}function Q(){let t,e,r,n;const o=document.getElementsByTagName("*");for(t=0;t<o.length;t+=1)if(e=o[t],r=e.getAttribute("include-html-footer"),r)return n=new XMLHttpRequest,n.onreadystatechange=function(){4===this.readyState&&(200===this.status&&(e.innerHTML=this.responseText),404===this.status&&(e.innerHTML="No se ha podido cargar correctamente."))},n.open("GET",r,!0),void n.send()}function tt(t,e){0!==t.childNodes[1].childNodes.length?$(`#${t.children[0].children[0].children[0].children[0].id}`).attr("src",`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages/${t.children[0].children[0].children[0].children[0].src.split("/").pop().split(".")[0]}_hover.svg}`):t.children[0].src=`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages%3A${e}_hover.svg/content`}function et(t,e){0!=t.childNodes[1].childNodes.length?$(`#${t.children[0].children[0].children[0].children[0].id}`).attr("src",`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages/${t.children[0].children[0].children[0].children[0].src.split("/").pop().split("_")[0]}.svg}`):t.children[0].src=`/pentaho/api/repos/%3Apublic%3Asc_valencia%3ACiutat%3Abuild%3Aimages%3A${e}.svg/content`}function rt(t){document.location=`${document.documentURI.split("%3A")[0]}%3A${document.documentURI.split("%3A")[1]}%3A${document.documentURI.split("%3A")[2]}%3A${document.documentURI.split("%3A")[3]}%3A${t}`}function nt(t){return`${document.documentURI.split("%3A")[0]}%3A${document.documentURI.split("%3A")[1]}%3A${document.documentURI.split("%3A")[2]}%3A${document.documentURI.split("%3A")[3]}%3A${t}`}function ot(t){$(document).click((()=>{const t=$("#layoutFilter");t.is(event.target)||t.has(event.target).length||t.hide()})),X(),K(t),Q()}function it(t,e,r){const n=$("#formFilterDates");if(""===Dashboards.getParameterValue("updateFilter")){const r=new Set;for(let n=t-1;n>0;--n)r.add(e[n]);for(const[t,e]of r.entries())n.append(`<input type="checkbox" id="${t}" onclick="legacy.filterDatesUpdate();" />${e}<br /></input>`);M(),S()}}function st(){const t=$("#idFilterVar").find("input"),e=[];$(t).each(((t,r)=>{r.checked&&e.push(r.id.replaceAll("/","-"))})),Dashboards.fireChange("filterVarParam",e),Dashboards.fireChange("updateFilterVar","True")}function at(t,e){const r=new Event("tableCreated"),n=$("#formFilterVar");if(""===Dashboards.getParameterValue("updateFilterVar")){for(let t=e.length-1;t>=0;t--)n.append(`<input type="checkbox" id="${e[t]}" onclick="legacy.filterVarUpdate();" />${e[t]}<br /></input>`);M(),st()}console.error("Dispatching tableCreated event..."),document.dispatchEvent(r),console.error("tableCreated event dispatched.")}function ut(t){return t.replace(/^(\d{4})[-|\/](\d{2})[-|\/](\d{2})$/g,"$3/$2/$1")}function ct(t){return t.replace(/^(\d{4})(\d{2})(\d{2})$/g,"$3/$2/$1")}function ft(t){const e=`20${t.slice(0,2)}`,r=t.slice(2,4);return`${t.slice(4,6)}/${r}/${e}`}function pt(t,e){const r=t.slice(0,2),n=t.slice(3,6);let o;return o=null==e?`20${t.slice(7,9)}`:`20${e.slice(5,7)}`,2===o.length&&(o="2022"),`${r}/${{Gen:"01",Feb:"02",Mar:"03",Abr:"04",Mai:"05",Jun:"06",Jul:"07",Ago:"08",Sep:"09",Oct:"10",Nov:"11",Des:"12"}[n]}/${o}`}function lt(t){let e=t.getUTCDate().toString();1===e.length&&(e=`0${e}`);let r=(t.getMonth()+1).toString();return 1===r.length&&(r=`0${r}`),`${e}/${r}/${t.getFullYear().toString()}`}function ht(t){const e=t.slice(0,2);return`${t.slice(3,5)}/${e}`}function yt(t){const e=t.toString().match(/(\d{2}:\d{2})/);return e?e[1]:null}function gt(t){return 100*(t-120)/t}function dt(t){return Array.from(t.values()).map((t=>{const[e,r]=t.split("/");return ht(t)}))}function bt(t,e,r,n,o,i,s,a,u=!1,c=!1,f=void 0,l=!0,h=p.slice(),y=!1,g=void 0,d=void 0){const w=t.resultset||t;if(0===w.length)k(`#${i}`,`#${s}`),a&&k(`#${a}`,`#${s}`);else{A(`#${s}`,`#${i}`),a&&A(`#${s}`,`#${a}`);const t=V(w,h,y),p=t[0],m=t[1],v=t[2],S=l?v:null,M=c?dt(m):Array.from(m.values());void 0===f&&(f=u?b(m.size):gt(m.size)),Y(i,_(p,S,M,o,f,e,r,void 0,n,void 0,void 0,void 0,g,d))}}function wt(t,e,r=!1){const n=[],o=1.1*O(t,1);let i,s=50,a=250,u=20,c=30,f=-80;o>9999999&&(s=65,a=75);const p=r?4:3;for(let r=0;r<t.length;r+=1)i=String(t[r][0]).replace(/\[.*?\]/g,""),i=z(i),n.push({value:t[r][1],name:i,title:{offsetCenter:[`${String(f)}%`,`${String(u)}%`],fontFamily:"Montserrat",fontSize:e},detail:{offsetCenter:[`${String(f)}%`,`${String(c)}%`],fontFamily:"Montserrat",fontSize:e}}),f+=a,(r+1)%p==0&&(c+=30,u+=30,f=-80);return[o,n,s]}function mt(t){const e=t.split("/"),r=parseInt(e[0],10),n=parseInt(e[1],10)-1,o=parseInt(e[2],10);return new Date(o,n,r)}function vt(t){return`${String(t.getDate()).padStart(2,"0")}/${String(t.getMonth()+1).padStart(2,"0")}/${String(t.getFullYear())}`}function St(t,e){const r=[];for(;t<=e;){const e=vt(t);r.push(e),t.setDate(t.getDate()+1)}return r}function Mt(t){const e=Array.from(t.keys(),(t=>mt(t))),r=[],n=[],o=St(new Date(Math.min(...e)),new Date(Math.max(...e)));return o.forEach((e=>{if(t.has(e)){const r=t.get(e);n.push(r)}else n.push(null)})),r.push(o),r.push(n),r}function xt(){$("#idPopupInfo").show()}function Et(){$("#idPopupInfo").hide()}function kt(){const t=$("#layoutFilter");"none"===t.css("display")?t.show():t.hide()}function At(){$("#layoutFilter").hide()}let It;function Ot(t,e,r,n,o,i,s,a=!1){const u=_t(r,e.id,e.addres,e.location),c=L.map(t).setView(h,s?s.initialZoom:13),f=L.tileLayer("https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png",{attribution:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors &copy; <a href="https://carto.com/attributions">CARTO</a>',subdomains:"abcd",maxZoom:20});c.setMinZoom(s?s.minZoom:5),c.setMaxZoom(s?s.maxZoom:20),f.addTo(c),Rt(c,u,r,e,a,n,o,i)}function Pt(t="myMap",e=5,r=20,n=13,o,i,s,a){const u=L.map(t).setView([39.46975,-.37739],n),c=L.tileLayer("https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png",{attribution:'&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors &copy; <a href="https://carto.com/attributions">CARTO</a>',subdomains:"abcd",maxZoom:20});u.setMinZoom(e),u.setMaxZoom(r),c.addTo(u),Bt(u,o,i,s,Tt(),a)}function Tt(){return{listOfselectedElements:[],elementExist(t){return this.listOfselectedElements.filter((e=>e===t)).length>0},deleteElementOfList(t){const e=this.listOfselectedElements.indexOf(t);e>-1&&this.listOfselectedElements.splice(e,1)}}}function _t(t,e=0,n=1,o=2){const{Buffer:i}=r(8287),s=r(543),a={type:"FeatureCollection",features:[]},u=[],c=new Set;return t.forEach((t=>{const e=t[o];c.has(e)||(c.add(e),u.push(t))})),u.forEach((t=>{const r=s.Geometry.parse(i.from(t[o],"hex")),u={type:"Feature",properties:{objectoId:t[e],address:t[n]},geometry:r.toGeoJSON()};a.features.push(u)})),a}function Bt(t,e,r,n,o,i){function s(t){return{iconUrl:nt(t),iconSize:[34,34],shadowSize:[50,64],iconAnchor:[17,17],shadowAnchor:[4,62],popupAnchor:[-3,-76]}}const a=L.icon(s(r)),u=L.icon(s(n));L.geoJSON(e,{onEachFeature:function(s,a){s.properties&&s.properties.address&&a.on("click",(()=>{o.elementExist(s.properties.objectoId)?o.deleteElementOfList(s.properties.objectoId):o.listOfselectedElements.push(s.properties.objectoId),i&&Dashboards.fireChange(i,o.listOfselectedElements),Bt(t,e,r,n,o,i)}))},pointToLayer(t,e){let r=a;return o.elementExist(t.properties.objectoId)&&(r=u),L.marker(e,{icon:r})}}).addTo(t)}function Rt(t,e,r,n,o,i,s,a){L.geoJSON(e,{onEachFeature(t,e){t.properties.address===s&&(It=e),function(t,e,r,n,o){const i=r.properties.address,s=r.properties.objectoId;r.properties&&i&&n.on("click",(()=>{const r=t.filter((t=>t[e.id]===s));o(r,i)}))}(r,n,t,e,a),function(t,e,r,n){const o=t.properties.address;r&&(e.on("mouseover",(()=>{e.bindPopup(o).openPopup()})),e.on("mouseout",(()=>{e.closePopup()}))),e.on("click",(()=>{It?(It.setStyle(n.unselected),e.setStyle(n.selected)):e.setStyle(n.selected),It=e}))}(t,e,o,i)},style:t=>t.properties.address===s?i.selected:i.unselected}).addTo(t)}})(),n})()));