UNPKG

gisq-ol-mobile-offline

Version:

## Project setup ``` npm install ```

6 lines 215 kB
(function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"==typeof window?"undefined"==typeof global?"undefined"==typeof self?this:self:global:window,t.shp=e()}})(function(){var a=Math.log,n=Math.abs,r=Math.floor,o=Math.pow,d=String.fromCharCode,l=Math.min,p;return function(){function s(d,e,n){function t(o,i){if(!e[o]){if(!d[o]){var l="function"==typeof require&&require;if(!i&&l)return l(o,!0);if(r)return r(o,!0);var c=new Error("Cannot find module '"+o+"'");throw c.code="MODULE_NOT_FOUND",c}var a=e[o]={exports:{}};d[o][0].call(a.exports,function(e){var a=d[o][1][e];return t(a||e)},a,a.exports,s,d,e,n)}return e[o].exports}for(var r="function"==typeof require&&require,a=0;a<n.length;a++)t(n[a]);return t}return s}()({1:[function(e,t){'use strict';var a=e("lie"),n=e("buffer").Buffer;t.exports=function(e){return new a(function(t,a){var r=e.slice(-3),s=new XMLHttpRequest;s.open("GET",e,!0),"prj"!==r&&"cpg"!==r&&(s.responseType="arraybuffer"),s.addEventListener("load",function(){return 399<s.status?"prj"===r||"cpg"===r?t(!1):a(new Error(s.status)):"prj"!==r&&"cpg"!==r?t(n.from(s.response)):t(s.response)},!1),s.send()})}},{buffer:7,lie:35}],2:[function(e,t){(function(a){'use strict';var n=e("./binaryajax-browser"),r=e("buffer").Buffer;t.exports=async function(e){if(!a.fetch)return n(e);var t=e.slice(-3).toLowerCase(),s="prj"===t||"cpg"===t;try{var i=await fetch(e);if(399<i.status)throw new Error(i.statusText);if(s)return i.text();var i=await i.arrayBuffer();return r.from(i)}catch(t){if(s)return!1;throw t}}}).call(this,"undefined"==typeof global?"undefined"==typeof self?"undefined"==typeof window?{}:window:self:global)},{"./binaryajax-browser":1,buffer:7}],3:[function(e,t){'use strict';function n(e){for(var t=0,a=1,n=e.length,r,s;a<n;)r=s||e[0],s=e[a],t+=(s[0]-r[0])*(s[1]+r[1]),a++;return 0<t}function r(e,t){return n(t)||!e.length?e.push([t]):e[e.length-1].push(t),e}function s(e){return e?function(t,a){return e.inverse([t.readDoubleLE(a),t.readDoubleLE(a+8)])}:function(e,t){return[e.readDoubleLE(t),e.readDoubleLE(t+8)]}}function i(e,t){return this instanceof i?void(this.buffer=e,this.shpFuncs(t),this.rows=this.getRows()):new i(e,t)}i.prototype.parsePoint=function(e){return{type:"Point",coordinates:this.parseCoord(e,0)}},i.prototype.parseZPoint=function(e){var t=this.parsePoint(e);return t.coordinates.push(e.readDoubleLE(16)),t},i.prototype.parsePointArray=function(e,t,a){for(var n=[],r=0;r<a;)n.push(this.parseCoord(e,t)),t+=16,r++;return n},i.prototype.parseZPointArray=function(e,t,a,n){for(var r=0;r<a;)n[r].push(e.readDoubleLE(t)),r++,t+=8;return n},i.prototype.parseArrayGroup=function(e,t,a,n,r){for(var s=[],i=0,o=0,d,l;i<n;)(i++,a+=4,d=o,o=i===n?r:e.readInt32LE(a),l=o-d,!!l)&&(s.push(this.parsePointArray(e,t,l)),t+=l<<4);return s},i.prototype.parseZArrayGroup=function(e,t,a,n){for(var r=0;r<a;)n[r]=this.parseZPointArray(e,t,n[r].length,n[r]),t+=n[r].length<<3,r++;return n},i.prototype.parseMultiPoint=function(e){var t={},a=this.parseCoord(e,0),n=this.parseCoord(e,16);t.bbox=[a[0],a[1],n[0],n[1]];var r=e.readInt32LE(32,!0),s=36;return 1===r?(t.type="Point",t.coordinates=this.parseCoord(e,s)):(t.type="MultiPoint",t.coordinates=this.parsePointArray(e,s,r)),t},i.prototype.parseZMultiPoint=function(e){var t=this.parseMultiPoint(e),a;if("Point"===t.type)return t.coordinates.push(e.readDoubleLE(72)),t;a=t.coordinates.length;var n=52+(a<<4);return t.coordinates=this.parseZPointArray(e,n,a,t.coordinates),t},i.prototype.parsePolyline=function(e){var t={},a=this.parseCoord(e,0),n=this.parseCoord(e,16);t.bbox=[a[0],a[1],n[0],n[1]];var r=e.readInt32LE(32),s=e.readInt32LE(36),i,o;return 1===r?(t.type="LineString",i=44,t.coordinates=this.parsePointArray(e,i,s)):(t.type="MultiLineString",i=40+(r<<2),o=40,t.coordinates=this.parseArrayGroup(e,i,o,r,s)),t},i.prototype.parseZPolyline=function(e){var t=this.parsePolyline(e),a=t.coordinates.length,n;if("LineString"===t.type)return n=60+(a<<4),t.coordinates=this.parseZPointArray(e,n,a,t.coordinates),t;var r=t.coordinates.reduce(function(e,t){return e+t.length},0);return n=56+(r<<4)+(a<<2),t.coordinates=this.parseZArrayGroup(e,n,a,t.coordinates),t},i.prototype.polyFuncs=function(e){return"LineString"===e.type?(e.type="Polygon",e.coordinates=[e.coordinates],e):(e.coordinates=e.coordinates.reduce(r,[]),1===e.coordinates.length?(e.type="Polygon",e.coordinates=e.coordinates[0],e):(e.type="MultiPolygon",e))},i.prototype.parsePolygon=function(e){return this.polyFuncs(this.parsePolyline(e))},i.prototype.parseZPolygon=function(e){return this.polyFuncs(this.parseZPolyline(e))};var o={1:"parsePoint",3:"parsePolyline",5:"parsePolygon",8:"parseMultiPoint",11:"parseZPoint",13:"parseZPolyline",15:"parseZPolygon",18:"parseZMultiPoint"};i.prototype.shpFuncs=function(e){var t=this.getShpCode();if(20<t&&(t-=20),!(t in o))throw new Error("I don't know that shp type");this.parseFunc=this[o[t]],this.parseCoord=s(e)},i.prototype.getShpCode=function(){return this.parseHeader().shpCode},i.prototype.parseHeader=function(){var e=this.buffer.slice(0,100);return{length:e.readInt32BE(24),version:e.readInt32LE(28),shpCode:e.readInt32LE(32),bbox:[e.readDoubleLE(36),e.readDoubleLE(44),e.readDoubleLE(52),e.readDoubleLE(52)]}},i.prototype.getRows=function(){for(var e=100,t=this.buffer.byteLength,a=[],n;e<t;)n=this.getRow(e),e+=8,e+=n.len,n.type?a.push(this.parseFunc(n.data)):a.push(null);return a},i.prototype.getRow=function(e){var t=this.buffer.slice(e,e+12),a=t.readInt32BE(4)<<1,n=this.buffer.slice(e+12,e+a+8);return{id:t.readInt32BE(0),len:a,data:n,type:t.readInt32LE(8)}},t.exports=function(e,t){return new i(e,t).rows}},{}],4:[function(e,t){'use strict';var a=e("jszip");t.exports=function(e){var t=new a(e),n=t.file(/.+/),r={};return n.forEach(function(e){r[e.name]="shp"===e.name.slice(-3).toLowerCase()||"dbf"===e.name.slice(-3).toLowerCase()?e.asNodeBuffer():e.asText()}),r}},{jszip:20}],5:[function(e,t,a){'use strict';function n(e){var t=e.length;if(0<t%4)throw new Error("Invalid string. Length must be a multiple of 4");var a=e.indexOf("=");-1===a&&(a=t);var n=a===t?0:4-a%4;return[a,n]}function r(e,t,a){return 3*(t+a)/4-a}function s(e){var t=n(e),a=t[0],s=t[1],o=new u(r(e,a,s)),d=0,l=0<s?a-4:a,p,m;for(m=0;m<l;m+=4)p=c[e.charCodeAt(m)]<<18|c[e.charCodeAt(m+1)]<<12|c[e.charCodeAt(m+2)]<<6|c[e.charCodeAt(m+3)],o[d++]=255&p>>16,o[d++]=255&p>>8,o[d++]=255&p;return 2===s&&(p=c[e.charCodeAt(m)]<<2|c[e.charCodeAt(m+1)]>>4,o[d++]=255&p),1===s&&(p=c[e.charCodeAt(m)]<<10|c[e.charCodeAt(m+1)]<<4|c[e.charCodeAt(m+2)]>>2,o[d++]=255&p>>8,o[d++]=255&p),o}function o(e){return p[63&e>>18]+p[63&e>>12]+p[63&e>>6]+p[63&e]}function d(e,t,a){for(var n=[],r=t,s;r<a;r+=3)s=(16711680&e[r]<<16)+(65280&e[r+1]<<8)+(255&e[r+2]),n.push(o(s));return n.join("")}function l(e){for(var t=e.length,a=t%3,n=[],r=16383,s=0,o=t-a,l;s<o;s+=r)n.push(d(e,s,s+r>o?o:s+r));return 1===a?(l=e[t-1],n.push(p[l>>2]+p[63&l<<4]+"==")):2===a&&(l=(e[t-2]<<8)+e[t-1],n.push(p[l>>10]+p[63&l>>4]+p[63&l<<2]+"=")),n.join("")}a.byteLength=function(e){var t=n(e),a=t[0],r=t[1];return 3*(a+r)/4-r},a.toByteArray=s,a.fromByteArray=l;for(var p=[],c=[],u="undefined"==typeof Uint8Array?Array:Uint8Array,m="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",_=0,f=m.length;_<f;++_)p[_]=m[_],c[m.charCodeAt(_)]=_;c[45]=62,c[95]=63},{}],6:[function(){},{}],7:[function(e,t,a){(function(t,n){/*!
 * The buffer module from node.js, for the browser.
 *
 * @author   Feross Aboukhadijeh <http://feross.org>
 * @license  MIT
 */'use strict';function s(){return n.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function p(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return n.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t),e.__proto__=n.prototype):(null===e&&(e=new n(t)),e.length=t),e}function n(e,t,a){if(!n.TYPED_ARRAY_SUPPORT&&!(this instanceof n))return new n(e,t,a);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return _(this,e)}return c(this,e,t,a)}function c(e,t,a,n){if("number"==typeof t)throw new TypeError("\"value\" argument must not be a number");return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?g(e,t,a,n):"string"==typeof t?f(e,t,a):y(e,t)}function u(e){if("number"!=typeof e)throw new TypeError("\"size\" argument must be a number");else if(0>e)throw new RangeError("\"size\" argument must not be negative")}function m(e,t,a,n){return u(t),0>=t?p(e,t):void 0===a?p(e,t):"string"==typeof n?p(e,t).fill(a,n):p(e,t).fill(a)}function _(e,t){if(u(t),e=p(e,0>t?0:0|b(t)),!n.TYPED_ARRAY_SUPPORT)for(var a=0;a<t;++a)e[a]=0;return e}function f(e,t,a){if(("string"!=typeof a||""===a)&&(a="utf8"),!n.isEncoding(a))throw new TypeError("\"encoding\" must be a valid string encoding");var r=0|w(t,a);e=p(e,r);var s=e.write(t,a);return s!==r&&(e=e.slice(0,s)),e}function h(e,t){var a=0>t.length?0:0|b(t.length);e=p(e,a);for(var n=0;n<a;n+=1)e[n]=255&t[n];return e}function g(e,t,a,r){if(t.byteLength,0>a||t.byteLength<a)throw new RangeError("'offset' is out of bounds");if(t.byteLength<a+(r||0))throw new RangeError("'length' is out of bounds");return t=void 0===a&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,a):new Uint8Array(t,a,r),n.TYPED_ARRAY_SUPPORT?(e=t,e.__proto__=n.prototype):e=h(e,t),e}function y(e,t){if(n.isBuffer(t)){var a=0|b(t.length);return(e=p(e,a),0===e.length)?e:(t.copy(e,0,0,a),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||ee(t.length)?p(e,0):h(e,t);if("Buffer"===t.type&&ne(t.data))return h(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function b(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function x(e){return+e!=e&&(e=0),n.alloc(+e)}function w(e,t){if(n.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var a=e.length;if(0===a)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return a;case"utf8":case"utf-8":case void 0:return W(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*a;case"hex":return a>>>1;case"base64":return V(e).length;default:if(r)return W(e).length;t=(""+t).toLowerCase(),r=!0;}}function E(e,t,a){var n=!1;if((void 0===t||0>t)&&(t=0),t>this.length)return"";if((void 0===a||a>this.length)&&(a=this.length),0>=a)return"";if(a>>>=0,t>>>=0,a<=t)return"";for(e||(e="utf8");;)switch(e){case"hex":return D(this,t,a);case"utf8":case"utf-8":return T(this,t,a);case"ascii":return P(this,t,a);case"latin1":case"binary":return N(this,t,a);case"base64":return L(this,t,a);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return j(this,t,a);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0;}}function C(e,t,a){var n=e[t];e[t]=e[a],e[a]=n}function A(e,t,a,r,s){if(0===e.length)return-1;if("string"==typeof a?(r=a,a=0):2147483647<a?a=2147483647:-2147483648>a&&(a=-2147483648),a=+a,isNaN(a)&&(a=s?0:e.length-1),0>a&&(a=e.length+a),a>=e.length){if(s)return-1;a=e.length-1}else if(0>a)if(s)a=0;else return-1;if("string"==typeof t&&(t=n.from(t,r)),n.isBuffer(t))return 0===t.length?-1:S(e,t,a,r,s);if("number"==typeof t)return t&=255,n.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?s?Uint8Array.prototype.indexOf.call(e,t,a):Uint8Array.prototype.lastIndexOf.call(e,t,a):S(e,[t],a,r,s);throw new TypeError("val must be string, number or Buffer")}function S(e,t,a,n,r){function s(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}var o=1,d=e.length,l=t.length;if(void 0!==n&&(n=(n+"").toLowerCase(),"ucs2"===n||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(2>e.length||2>t.length)return-1;o=2,d/=2,l/=2,a/=2}var p;if(r){var c=-1;for(p=a;p<d;p++)if(s(e,p)!==s(t,-1===c?0:p-c))-1!==c&&(p-=p-c),c=-1;else if(-1===c&&(c=p),p-c+1===l)return c*o}else for(a+l>d&&(a=d-l),p=a;0<=p;p--){for(var u=!0,m=0;m<l;m++)if(s(e,p+m)!==s(t,m)){u=!1;break}if(u)return p}return-1}function k(e,t,a,n){a=+a||0;var r=e.length-a;n?(n=+n,n>r&&(n=r)):n=r;var s=t.length;if(0!=s%2)throw new TypeError("Invalid hex string");n>s/2&&(n=s/2);for(var o=0,d;o<n;++o){if(d=parseInt(t.substr(2*o,2),16),isNaN(d))return o;e[a+o]=d}return o}function v(e,t,a,n){return $(W(t,e.length-a),e,a,n)}function I(e,t,a,n){return $(Q(t),e,a,n)}function R(e,t,a,n){return I(e,t,a,n)}function O(e,t,a,n){return $(V(t),e,a,n)}function z(e,t,a,n){return $(J(t,e.length-a),e,a,n)}function L(e,t,a){return 0===t&&a===e.length?te.fromByteArray(e):te.fromByteArray(e.slice(t,a))}function T(e,t,a){a=l(e.length,a);for(var n=[],r=t;r<a;){var s=e[r],o=null,d=239<s?4:223<s?3:191<s?2:1;if(r+d<=a){var p,c,u,m;1===d?128>s&&(o=s):2===d?(p=e[r+1],128==(192&p)&&(m=(31&s)<<6|63&p,127<m&&(o=m))):3===d?(p=e[r+1],c=e[r+2],128==(192&p)&&128==(192&c)&&(m=(15&s)<<12|(63&p)<<6|63&c,2047<m&&(55296>m||57343<m)&&(o=m))):4===d?(p=e[r+1],c=e[r+2],u=e[r+3],128==(192&p)&&128==(192&c)&&128==(192&u)&&(m=(15&s)<<18|(63&p)<<12|(63&c)<<6|63&u,65535<m&&1114112>m&&(o=m))):void 0}null===o?(o=65533,d=1):65535<o&&(o-=65536,n.push(55296|1023&o>>>10),o=56320|1023&o),n.push(o),r+=d}return B(n)}function B(e){var t=e.length;if(t<=4096)return d.apply(String,e);for(var a="",n=0;n<t;)a+=d.apply(String,e.slice(n,n+=4096));return a}function P(e,t,a){var n="";a=l(e.length,a);for(var r=t;r<a;++r)n+=d(127&e[r]);return n}function N(e,t,a){var n="";a=l(e.length,a);for(var r=t;r<a;++r)n+=d(e[r]);return n}function D(e,t,a){var n=e.length;(!t||0>t)&&(t=0),(!a||0>a||a>n)&&(a=n);for(var r="",s=t;s<a;++s)r+=X(e[s]);return r}function j(e,t,a){for(var n=e.slice(t,a),r="",s=0;s<n.length;s+=2)r+=d(n[s]+256*n[s+1]);return r}function U(e,t,a){if(0!=e%1||0>e)throw new RangeError("offset is not uint");if(e+t>a)throw new RangeError("Trying to access beyond buffer length")}function F(e,t,a,r,s,i){if(!n.isBuffer(e))throw new TypeError("\"buffer\" argument must be a Buffer instance");if(t>s||t<i)throw new RangeError("\"value\" argument is out of bounds");if(a+r>e.length)throw new RangeError("Index out of range")}function M(e,t,a,n){0>t&&(t=65535+t+1);for(var r=0,s=l(e.length-a,2);r<s;++r)e[a+r]=(t&255<<8*(n?r:1-r))>>>8*(n?r:1-r)}function G(e,t,a,n){0>t&&(t=4294967295+t+1);for(var r=0,s=l(e.length-a,4);r<s;++r)e[a+r]=255&t>>>8*(n?r:3-r)}function Z(e,t,a,n){if(a+n>e.length)throw new RangeError("Index out of range");if(0>a)throw new RangeError("Index out of range")}function Y(e,t,a,n,r){return r||Z(e,t,a,4,34028234663852886e22,-34028234663852886e22),ae.write(e,t,a,n,23,4),a+4}function q(e,t,a,n,r){return r||Z(e,t,a,8,17976931348623157e292,-17976931348623157e292),ae.write(e,t,a,n,52,8),a+8}function H(e){if(e=K(e).replace(re,""),2>e.length)return"";for(;0!=e.length%4;)e+="=";return e}function K(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function X(e){return 16>e?"0"+e.toString(16):e.toString(16)}function W(e,t){t=t||1/0;for(var a=e.length,n=null,r=[],s=0,o;s<a;++s){if(o=e.charCodeAt(s),55295<o&&57344>o){if(!n){if(56319<o){-1<(t-=3)&&r.push(239,191,189);continue}else if(s+1===a){-1<(t-=3)&&r.push(239,191,189);continue}n=o;continue}if(56320>o){-1<(t-=3)&&r.push(239,191,189),n=o;continue}o=(n-55296<<10|o-56320)+65536}else n&&-1<(t-=3)&&r.push(239,191,189);if(n=null,128>o){if(0>(t-=1))break;r.push(o)}else if(2048>o){if(0>(t-=2))break;r.push(192|o>>6,128|63&o)}else if(65536>o){if(0>(t-=3))break;r.push(224|o>>12,128|63&o>>6,128|63&o)}else if(1114112>o){if(0>(t-=4))break;r.push(240|o>>18,128|63&o>>12,128|63&o>>6,128|63&o)}else throw new Error("Invalid code point")}return r}function Q(e){for(var t=[],a=0;a<e.length;++a)t.push(255&e.charCodeAt(a));return t}function J(e,t){for(var a=[],n=0,r,s,o;n<e.length&&!(0>(t-=2));++n)r=e.charCodeAt(n),s=r>>8,o=r%256,a.push(o),a.push(s);return a}function V(e){return te.toByteArray(H(e))}function $(e,t,a,n){for(var r=0;r<n&&!(r+a>=t.length||r>=e.length);++r)t[r+a]=e[r];return r}function ee(e){return e!==e}var te=e("base64-js"),ae=e("ieee754"),ne=e("isarray");a.Buffer=n,a.SlowBuffer=x,a.INSPECT_MAX_BYTES=50,n.TYPED_ARRAY_SUPPORT=t.TYPED_ARRAY_SUPPORT===void 0?function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(t){return!1}}():t.TYPED_ARRAY_SUPPORT,a.kMaxLength=s(),n.poolSize=8192,n._augment=function(e){return e.__proto__=n.prototype,e},n.from=function(e,t,a){return c(null,e,t,a)},n.TYPED_ARRAY_SUPPORT&&(n.prototype.__proto__=Uint8Array.prototype,n.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&n[Symbol.species]===n&&Object.defineProperty(n,Symbol.species,{value:null,configurable:!0})),n.alloc=function(e,t,a){return m(null,e,t,a)},n.allocUnsafe=function(e){return _(null,e)},n.allocUnsafeSlow=function(e){return _(null,e)},n.isBuffer=function(e){return!!(null!=e&&e._isBuffer)},n.compare=function(e,t){if(!n.isBuffer(e)||!n.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var a=e.length,r=t.length,s=0,o=l(a,r);s<o;++s)if(e[s]!==t[s]){a=e[s],r=t[s];break}return a<r?-1:r<a?1:0},n.isEncoding=function(e){switch((e+"").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;}},n.concat=function(e,t){if(!ne(e))throw new TypeError("\"list\" argument must be an Array of Buffers");if(0===e.length)return n.alloc(0);var a;if(t===void 0)for(t=0,a=0;a<e.length;++a)t+=e[a].length;var r=n.allocUnsafe(t),s=0;for(a=0;a<e.length;++a){var o=e[a];if(!n.isBuffer(o))throw new TypeError("\"list\" argument must be an Array of Buffers");o.copy(r,s),s+=o.length}return r},n.byteLength=w,n.prototype._isBuffer=!0,n.prototype.swap16=function(){var e=this.length;if(0!=e%2)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)C(this,t,t+1);return this},n.prototype.swap32=function(){var e=this.length;if(0!=e%4)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)C(this,t,t+3),C(this,t+1,t+2);return this},n.prototype.swap64=function(){var e=this.length;if(0!=e%8)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)C(this,t,t+7),C(this,t+1,t+6),C(this,t+2,t+5),C(this,t+3,t+4);return this},n.prototype.toString=function(){var e=0|this.length;return 0==e?"":0===arguments.length?T(this,0,e):E.apply(this,arguments)},n.prototype.equals=function(e){if(!n.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===n.compare(this,e)},n.prototype.inspect=function(){var e="",t=a.INSPECT_MAX_BYTES;return 0<this.length&&(e=this.toString("hex",0,t).match(/.{2}/g).join(" "),this.length>t&&(e+=" ... ")),"<Buffer "+e+">"},n.prototype.compare=function(e,t,a,r,s){if(!n.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===a&&(a=e?e.length:0),void 0===r&&(r=0),void 0===s&&(s=this.length),0>t||a>e.length||0>r||s>this.length)throw new RangeError("out of range index");if(r>=s&&t>=a)return 0;if(r>=s)return-1;if(t>=a)return 1;if(t>>>=0,a>>>=0,r>>>=0,s>>>=0,this===e)return 0;for(var o=s-r,d=a-t,p=l(o,d),c=this.slice(r,s),u=e.slice(t,a),m=0;m<p;++m)if(c[m]!==u[m]){o=c[m],d=u[m];break}return o<d?-1:d<o?1:0},n.prototype.includes=function(e,t,a){return-1!==this.indexOf(e,t,a)},n.prototype.indexOf=function(e,t,a){return A(this,e,t,a,!0)},n.prototype.lastIndexOf=function(e,t,a){return A(this,e,t,a,!1)},n.prototype.write=function(e,t,a,n){if(void 0===t)n="utf8",a=this.length,t=0;else if(void 0===a&&"string"==typeof t)n=t,a=this.length,t=0;else if(isFinite(t))t|=0,isFinite(a)?(a|=0,void 0===n&&(n="utf8")):(n=a,a=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var r=this.length-t;if((void 0===a||a>r)&&(a=r),0<e.length&&(0>a||0>t)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var s=!1;;)switch(n){case"hex":return k(this,e,t,a);case"utf8":case"utf-8":return v(this,e,t,a);case"ascii":return I(this,e,t,a);case"latin1":case"binary":return R(this,e,t,a);case"base64":return O(this,e,t,a);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return z(this,e,t,a);default:if(s)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),s=!0;}},n.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};n.prototype.slice=function(e,t){var a=this.length;e=~~e,t=t===void 0?a:~~t,0>e?(e+=a,0>e&&(e=0)):e>a&&(e=a),0>t?(t+=a,0>t&&(t=0)):t>a&&(t=a),t<e&&(t=e);var r;if(n.TYPED_ARRAY_SUPPORT)r=this.subarray(e,t),r.__proto__=n.prototype;else{var s=t-e;r=new n(s,void 0);for(var o=0;o<s;++o)r[o]=this[o+e]}return r},n.prototype.readUIntLE=function(e,t,a){e|=0,t|=0,a||U(e,t,this.length);for(var n=this[e],r=1,s=0;++s<t&&(r*=256);)n+=this[e+s]*r;return n},n.prototype.readUIntBE=function(e,t,a){e|=0,t|=0,a||U(e,t,this.length);for(var n=this[e+--t],r=1;0<t&&(r*=256);)n+=this[e+--t]*r;return n},n.prototype.readUInt8=function(e,t){return t||U(e,1,this.length),this[e]},n.prototype.readUInt16LE=function(e,t){return t||U(e,2,this.length),this[e]|this[e+1]<<8},n.prototype.readUInt16BE=function(e,t){return t||U(e,2,this.length),this[e]<<8|this[e+1]},n.prototype.readUInt32LE=function(e,t){return t||U(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},n.prototype.readUInt32BE=function(e,t){return t||U(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},n.prototype.readIntLE=function(e,t,a){e|=0,t|=0,a||U(e,t,this.length);for(var n=this[e],r=1,s=0;++s<t&&(r*=256);)n+=this[e+s]*r;return r*=128,n>=r&&(n-=o(2,8*t)),n},n.prototype.readIntBE=function(e,t,a){e|=0,t|=0,a||U(e,t,this.length);for(var n=t,r=1,s=this[e+--n];0<n&&(r*=256);)s+=this[e+--n]*r;return r*=128,s>=r&&(s-=o(2,8*t)),s},n.prototype.readInt8=function(e,t){return t||U(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},n.prototype.readInt16LE=function(e,t){t||U(e,2,this.length);var a=this[e]|this[e+1]<<8;return 32768&a?4294901760|a:a},n.prototype.readInt16BE=function(e,t){t||U(e,2,this.length);var a=this[e+1]|this[e]<<8;return 32768&a?4294901760|a:a},n.prototype.readInt32LE=function(e,t){return t||U(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},n.prototype.readInt32BE=function(e,t){return t||U(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},n.prototype.readFloatLE=function(e,t){return t||U(e,4,this.length),ae.read(this,e,!0,23,4)},n.prototype.readFloatBE=function(e,t){return t||U(e,4,this.length),ae.read(this,e,!1,23,4)},n.prototype.readDoubleLE=function(e,t){return t||U(e,8,this.length),ae.read(this,e,!0,52,8)},n.prototype.readDoubleBE=function(e,t){return t||U(e,8,this.length),ae.read(this,e,!1,52,8)},n.prototype.writeUIntLE=function(e,t,a,n){if(e=+e,t|=0,a|=0,!n){var r=o(2,8*a)-1;F(this,e,t,a,r,0)}var s=1,d=0;for(this[t]=255&e;++d<a&&(s*=256);)this[t+d]=255&e/s;return t+a},n.prototype.writeUIntBE=function(e,t,a,n){if(e=+e,t|=0,a|=0,!n){var r=o(2,8*a)-1;F(this,e,t,a,r,0)}var s=a-1,d=1;for(this[t+s]=255&e;0<=--s&&(d*=256);)this[t+s]=255&e/d;return t+a},n.prototype.writeUInt8=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,1,255,0),n.TYPED_ARRAY_SUPPORT||(e=r(e)),this[t]=255&e,t+1},n.prototype.writeUInt16LE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,2,65535,0),n.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},n.prototype.writeUInt16BE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,2,65535,0),n.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},n.prototype.writeUInt32LE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,4,4294967295,0),n.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):G(this,e,t,!0),t+4},n.prototype.writeUInt32BE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,4,4294967295,0),n.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):G(this,e,t,!1),t+4},n.prototype.writeIntLE=function(e,t,a,n){if(e=+e,t|=0,!n){var r=o(2,8*a-1);F(this,e,t,a,r-1,-r)}var s=0,d=1,l=0;for(this[t]=255&e;++s<a&&(d*=256);)0>e&&0===l&&0!==this[t+s-1]&&(l=1),this[t+s]=255&(e/d>>0)-l;return t+a},n.prototype.writeIntBE=function(e,t,a,n){if(e=+e,t|=0,!n){var r=o(2,8*a-1);F(this,e,t,a,r-1,-r)}var s=a-1,d=1,l=0;for(this[t+s]=255&e;0<=--s&&(d*=256);)0>e&&0===l&&0!==this[t+s+1]&&(l=1),this[t+s]=255&(e/d>>0)-l;return t+a},n.prototype.writeInt8=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,1,127,-128),n.TYPED_ARRAY_SUPPORT||(e=r(e)),0>e&&(e=255+e+1),this[t]=255&e,t+1},n.prototype.writeInt16LE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,2,32767,-32768),n.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):M(this,e,t,!0),t+2},n.prototype.writeInt16BE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,2,32767,-32768),n.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):M(this,e,t,!1),t+2},n.prototype.writeInt32LE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,4,2147483647,-2147483648),n.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):G(this,e,t,!0),t+4},n.prototype.writeInt32BE=function(e,t,a){return e=+e,t|=0,a||F(this,e,t,4,2147483647,-2147483648),0>e&&(e=4294967295+e+1),n.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):G(this,e,t,!1),t+4},n.prototype.writeFloatLE=function(e,t,a){return Y(this,e,t,!0,a)},n.prototype.writeFloatBE=function(e,t,a){return Y(this,e,t,!1,a)},n.prototype.writeDoubleLE=function(e,t,a){return q(this,e,t,!0,a)},n.prototype.writeDoubleBE=function(e,t,a){return q(this,e,t,!1,a)},n.prototype.copy=function(e,t,a,r){if(a||(a=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),0<r&&r<a&&(r=a),r===a)return 0;if(0===e.length||0===this.length)return 0;if(0>t)throw new RangeError("targetStart out of bounds");if(0>a||a>=this.length)throw new RangeError("sourceStart out of bounds");if(0>r)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-a&&(r=e.length-t+a);var s=r-a,o;if(this===e&&a<t&&t<r)for(o=s-1;0<=o;--o)e[o+t]=this[o+a];else if(1e3>s||!n.TYPED_ARRAY_SUPPORT)for(o=0;o<s;++o)e[o+t]=this[o+a];else Uint8Array.prototype.set.call(e,this.subarray(a,a+s),t);return s},n.prototype.fill=function(e,t,a,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,a=this.length):"string"==typeof a&&(r=a,a=this.length),1===e.length){var s=e.charCodeAt(0);256>s&&(e=s)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!n.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(0>t||this.length<t||this.length<a)throw new RangeError("Out of range index");if(a<=t)return this;t>>>=0,a=a===void 0?this.length:a>>>0,e||(e=0);var o;if("number"==typeof e)for(o=t;o<a;++o)this[o]=e;else{var d=n.isBuffer(e)?e:W(new n(e,r).toString()),l=d.length;for(o=0;o<a-t;++o)this[o+t]=d[o%l]}return this};var re=/[^+\/0-9A-Za-z-_]/g}).call(this,"undefined"==typeof global?"undefined"==typeof self?"undefined"==typeof window?{}:window:self:global,e("buffer").Buffer)},{"base64-js":5,buffer:7,ieee754:8,isarray:10}],8:[function(e,t,s){s.read=function(t,a,n,r,l){var p=8*l-r-1,c=(1<<p)-1,u=c>>1,_=-7,f=n?l-1:0,h=n?-1:1,d=t[a+f],g,y;for(f+=h,g=d&(1<<-_)-1,d>>=-_,_+=p;0<_;g=256*g+t[a+f],f+=h,_-=8);for(y=g&(1<<-_)-1,g>>=-_,_+=r;0<_;y=256*y+t[a+f],f+=h,_-=8);if(0===g)g=1-u;else{if(g===c)return y?NaN:(d?-1:1)*(1/0);y+=o(2,r),g-=u}return(d?-1:1)*y*o(2,g-r)},s.write=function(t,l,p,u,_,f){var h=Math.LN2,g=8*f-_-1,y=(1<<g)-1,b=y>>1,x=23===_?o(2,-24)-o(2,-77):0,w=u?0:f-1,E=u?1:-1,d=0>l||0===l&&0>1/l?1:0,s,C,A;for(l=n(l),isNaN(l)||l===1/0?(C=isNaN(l)?1:0,s=y):(s=r(a(l)/h),1>l*(A=o(2,-s))&&(s--,A*=2),l+=1<=s+b?x/A:x*o(2,1-b),2<=l*A&&(s++,A/=2),s+b>=y?(C=0,s=y):1<=s+b?(C=(l*A-1)*o(2,_),s+=b):(C=l*o(2,b-1)*o(2,_),s=0));8<=_;t[p+w]=255&C,w+=E,C/=256,_-=8);for(s=s<<_|C,g+=_;0<g;t[p+w]=255&s,w+=E,s/=256,g-=8);t[p+w-E]|=128*d}},{}],9:[function(e,t){(function(e){'use strict';function a(){c=!0;for(var e=p.length,t,a;e;){for(a=p,p=[],t=-1;++t<e;)a[t]();e=p.length}c=!1}function n(e){1!==p.push(e)||c||s()}var r=e.MutationObserver||e.WebKitMutationObserver,s;if(r){var i=0,o=new r(a),d=e.document.createTextNode("");o.observe(d,{characterData:!0}),s=function(){d.data=i=++i%2}}else if(!e.setImmediate&&"undefined"!=typeof e.MessageChannel){var l=new e.MessageChannel;l.port1.onmessage=a,s=function(){l.port2.postMessage(0)}}else s="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){a(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(a,0)};var p=[],c;t.exports=n}).call(this,"undefined"==typeof global?"undefined"==typeof self?"undefined"==typeof window?{}:window:self:global)},{}],10:[function(e,t){var a={}.toString;t.exports=Array.isArray||function(e){return"[object Array]"==a.call(e)}},{}],11:[function(e,t){'use strict';function a(e){if(e){this.data=e,this.length=this.data.length,this.index=0,this.zero=0;for(var t=0;t<this.data.length;t++)e[t]&=255}}var n=e("./dataReader");a.prototype=new n,a.prototype.byteAt=function(e){return this.data[this.zero+e]},a.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),a=e.charCodeAt(1),n=e.charCodeAt(2),r=e.charCodeAt(3),s=this.length-4;0<=s;--s)if(this.data[s]===t&&this.data[s+1]===a&&this.data[s+2]===n&&this.data[s+3]===r)return s-this.zero;return-1},a.prototype.readData=function(e){if(this.checkOffset(e),0===e)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=a},{"./dataReader":16}],12:[function(e,t,a){'use strict';a.encode=function(e){for(var t="",a=0,n,r,s,o,d,l,p;a<e.length;)n=e.charCodeAt(a++),r=e.charCodeAt(a++),s=e.charCodeAt(a++),o=n>>2,d=(3&n)<<4|r>>4,l=(15&r)<<2|s>>6,p=63&s,isNaN(r)?l=p=64:isNaN(s)&&(p=64),t=t+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(o)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(d)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(l)+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".charAt(p);return t},a.decode=function(e){var t="",a=0,n,r,s,o,l,p,c;for(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");a<e.length;)o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(e.charAt(a++)),l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(e.charAt(a++)),p="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(e.charAt(a++)),c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(e.charAt(a++)),n=o<<2|l>>4,r=(15&l)<<4|p>>2,s=(3&p)<<6|c,t+=d(n),64!=p&&(t+=d(r)),64!=c&&(t+=d(s));return t}},{}],13:[function(e,t){'use strict';function a(){this.compressedSize=0,this.uncompressedSize=0,this.crc32=0,this.compressionMethod=null,this.compressedContent=null}a.prototype={getContent:function(){return null},getCompressedContent:function(){return null}},t.exports=a},{}],14:[function(e,t,a){'use strict';a.STORE={magic:"\0\0",compress:function(e){return e},uncompress:function(e){return e},compressInputType:null,uncompressInputType:null},a.DEFLATE=e("./flate")},{"./flate":19}],15:[function(e,t){'use strict';var a=e("./utils"),n=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];t.exports=function(e,t){if("undefined"==typeof e||!e.length)return 0;var r="string"!==a.getTypeOf(e);"undefined"==typeof t&&(t=0);var s=0,o=0,d=0;t^=-1;for(var l=0,p=e.length;l<p;l++)d=r?e[l]:e.charCodeAt(l),o=255&(t^d),s=n[o],t=t>>>8^s;return-1^t}},{"./utils":32}],16:[function(e,t){'use strict';function a(){this.data=null,this.length=0,this.index=0,this.zero=0}var n=e("./utils");a.prototype={checkOffset:function(e){this.checkIndex(this.index+e)},checkIndex:function(e){if(this.length<this.zero+e||0>e)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},setIndex:function(e){this.checkIndex(e),this.index=e},skip:function(e){this.setIndex(this.index+e)},byteAt:function(){},readInt:function(e){var t=0,a;for(this.checkOffset(e),a=this.index+e-1;a>=this.index;a--)t=(t<<8)+this.byteAt(a);return this.index+=e,t},readString:function(e){return n.transformTo("string",this.readData(e))},readData:function(){},lastIndexOfSignature:function(){},readDate:function(){var e=this.readInt(4);return new Date((127&e>>25)+1980,(15&e>>21)-1,31&e>>16,31&e>>11,63&e>>5,(31&e)<<1)}},t.exports=a},{"./utils":32}],17:[function(e,t,a){'use strict';a.base64=!1,a.binary=!1,a.dir=!1,a.createFolders=!1,a.date=null,a.compression=null,a.compressionOptions=null,a.comment=null,a.unixPermissions=null,a.dosPermissions=null},{}],18:[function(e,t,a){'use strict';var n=e("./utils");a.string2binary=function(e){return n.string2binary(e)},a.string2Uint8Array=function(e){return n.transformTo("uint8array",e)},a.uint8Array2String=function(e){return n.transformTo("string",e)},a.string2Blob=function(e){var t=n.transformTo("arraybuffer",e);return n.arrayBuffer2Blob(t)},a.arrayBuffer2Blob=function(e){return n.arrayBuffer2Blob(e)},a.transformTo=function(e,t){return n.transformTo(e,t)},a.getTypeOf=function(e){return n.getTypeOf(e)},a.checkSupport=function(e){return n.checkSupport(e)},a.MAX_VALUE_16BITS=n.MAX_VALUE_16BITS,a.MAX_VALUE_32BITS=n.MAX_VALUE_32BITS,a.pretty=function(e){return n.pretty(e)},a.findCompression=function(e){return n.findCompression(e)},a.isRegExp=function(e){return n.isRegExp(e)}},{"./utils":32}],19:[function(e,t,a){'use strict';var n="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,r=e("pako");a.uncompressInputType=n?"uint8array":"array",a.compressInputType=n?"uint8array":"array",a.magic="\b\0",a.compress=function(e,t){return r.deflateRaw(e,{level:t.level||-1})},a.uncompress=function(e){return r.inflateRaw(e)}},{pako:37}],20:[function(e,t){'use strict';function a(e,t){return this instanceof a?void(this.files={},this.comment=null,this.root="",e&&this.load(e,t),this.clone=function(){var e=new a;for(var t in this)"function"!=typeof this[t]&&(e[t]=this[t]);return e}):new a(e,t)}var n=e("./base64");a.prototype=e("./object"),a.prototype.load=e("./load"),a.support=e("./support"),a.defaults=e("./defaults"),a.utils=e("./deprecatedPublicUtils"),a.base64={encode:function(e){return n.encode(e)},decode:function(e){return n.decode(e)}},a.compressions=e("./compressions"),t.exports=a},{"./base64":12,"./compressions":14,"./defaults":17,"./deprecatedPublicUtils":18,"./load":21,"./object":24,"./support":28}],21:[function(e,t){'use strict';var a=e("./base64"),n=e("./utf8"),r=e("./utils"),s=e("./zipEntries");t.exports=function(e,t){var o,d,l,p;for(t=r.extend(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:n.utf8decode}),t.base64&&(e=a.decode(e)),d=new s(e,t),o=d.files,l=0;l<o.length;l++)p=o[l],this.file(p.fileNameStr,p.decompressed,{binary:!0,optimizedBinaryString:!0,date:p.date,dir:p.dir,comment:p.fileCommentStr.length?p.fileCommentStr:null,unixPermissions:p.unixPermissions,dosPermissions:p.dosPermissions,createFolders:t.createFolders});return d.zipComment.length&&(this.comment=d.zipComment),this}},{"./base64":12,"./utf8":31,"./utils":32,"./zipEntries":33}],22:[function(e,t){(function(e){'use strict';t.exports=function(t,a){return new e(t,a)},t.exports.test=function(t){return e.isBuffer(t)}}).call(this,e("buffer").Buffer)},{buffer:7}],23:[function(e,t){'use strict';function a(e){this.data=e,this.length=this.data.length,this.index=0,this.zero=0}var n=e("./uint8ArrayReader");a.prototype=new n,a.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=a},{"./uint8ArrayReader":29}],24:[function(e,t){'use strict';var a=e("./support"),n=e("./utils"),r=e("./crc32"),s=e("./signature"),i=e("./defaults"),o=e("./base64"),l=e("./compressions"),p=e("./compressedObject"),c=e("./nodeBuffer"),u=e("./utf8"),m=e("./stringWriter"),_=e("./uint8ArrayWriter"),f=function(e){if(e._data instanceof p&&(e._data=e._data.getContent(),e.options.binary=!0,e.options.base64=!1,"uint8array"===n.getTypeOf(e._data))){var t=e._data;e._data=new Uint8Array(t.length),0!==t.length&&e._data.set(t,0)}return e._data},h=function(e){var t=f(e),r=n.getTypeOf(t);return"string"===r?!e.options.binary&&a.nodebuffer?c(t,"utf-8"):e.asBinary():t},g=function(e){var t=f(this);return null===t||"undefined"==typeof t?"":(this.options.base64&&(t=o.decode(t)),t=e&&this.options.binary?R.utf8decode(t):n.transformTo("string",t),e||this.options.binary||(t=n.transformTo("string",R.utf8encode(t))),t)},y=function(e,t,a){this.name=e,this.dir=a.dir,this.date=a.date,this.comment=a.comment,this.unixPermissions=a.unixPermissions,this.dosPermissions=a.dosPermissions,this._data=t,this.options=a,this._initialMetadata={dir:a.dir,date:a.date}};y.prototype={asText:function(){return g.call(this,!0)},asBinary:function(){return g.call(this,!1)},asNodeBuffer:function(){var e=h(this);return n.transformTo("nodebuffer",e)},asUint8Array:function(){var e=h(this);return n.transformTo("uint8array",e)},asArrayBuffer:function(){return this.asUint8Array().buffer}};var b=function(e,t){var a="",n;for(n=0;n<t;n++)a+=d(255&e),e>>>=8;return a},x=function(e){return e=e||{},!0===e.base64&&(null===e.binary||void 0===e.binary)&&(e.binary=!0),e=n.extend(e,i),e.date=e.date||new Date,null!==e.compression&&(e.compression=e.compression.toUpperCase()),e},w=function(e,t,a){var r=n.getTypeOf(t),s;if(a=x(a),"string"==typeof a.unixPermissions&&(a.unixPermissions=parseInt(a.unixPermissions,8)),a.unixPermissions&&16384&a.unixPermissions&&(a.dir=!0),a.dosPermissions&&16&a.dosPermissions&&(a.dir=!0),a.dir&&(e=C(e)),a.createFolders&&(s=E(e))&&A.call(this,s,!0),a.dir||null===t||"undefined"==typeof t)a.base64=!1,a.binary=!1,t=null,r=null;else if("string"===r)a.binary&&!a.base64&&!0!==a.optimizedBinaryString&&(t=n.string2binary(t));else{if(a.base64=!1,a.binary=!0,!r&&!(t instanceof p))throw new Error("The data of '"+e+"' is in an unsupported format !");"arraybuffer"==r&&(t=n.transformTo("uint8array",t))}var i=new y(e,t,a);return this.files[e]=i,i},E=function(e){"/"==e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return 0<t?e.substring(0,t):""},C=function(e){return"/"!=e.slice(-1)&&(e+="/"),e},A=function(e,t){return t="undefined"!=typeof t&&t,e=C(e),this.files[e]||w.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]},S=function(e,t,a){var s=new p,i;return e._data instanceof p?(s.uncompressedSize=e._data.uncompressedSize,s.crc32=e._data.crc32,0===s.uncompressedSize||e.dir?(t=l.STORE,s.compressedContent="",s.crc32=0):e._data.compressionMethod===t.magic?s.compressedContent=e._data.getCompressedContent():(i=e._data.getContent(),s.compressedContent=t.compress(n.transformTo(t.compressInputType,i),a))):(i=h(e),(!i||0===i.length||e.dir)&&(t=l.STORE,i=""),s.uncompressedSize=i.length,s.crc32=r(i),s.compressedContent=t.compress(n.transformTo(t.compressInputType,i),a)),s.compressedSize=s.compressedContent.length,s.compressionMethod=t.magic,s},k=function(e,t){var a=e;return e||(a=t?16893:33204),(65535&a)<<16},v=function(e){return 63&(e||0)},I=function(e,t,a,i,d,l){var p=a.compressedContent,c=l!==u.utf8encode,m=n.transformTo("string",l(t.name)),_=n.transformTo("string",u.utf8encode(t.name)),f=t.comment||"",h=n.transformTo("string",l(f)),g=n.transformTo("string",u.utf8encode(f)),y=_.length!==t.name.length,x=g.length!==f.length,w=t.options,o="",E="",C="",A,S,I,R;I=t._initialMetadata.dir===t.dir?w.dir:t.dir,R=t._initialMetadata.date===t.date?w.date:t.date;var O=0,z=0;I&&(O|=16),"UNIX"===d?(z=798,O|=k(t.unixPermissions,I)):(z=20,O|=v(t.dosPermissions,I)),A=R.getHours(),A<<=6,A|=R.getMinutes(),A<<=5,A|=R.getSeconds()/2,S=R.getFullYear()-1980,S<<=4,S|=R.getMonth()+1,S<<=5,S|=R.getDate(),y&&(E=b(1,1)+b(r(m),4)+_,o+="up"+b(E.length,2)+E),x&&(C=b(1,1)+b(this.crc32(h),4)+g,o+="uc"+b(C.length,2)+C);var L="";L+="\n\0",L+=!c&&(y||x)?"\0\b":"\0\0",L+=a.compressionMethod,L+=b(A,2),L+=b(S,2),L+=b(a.crc32,4),L+=b(a.compressedSize,4),L+=b(a.uncompressedSize,4),L+=b(m.length,2),L+=b(o.length,2);var T=s.LOCAL_FILE_HEADER+L+m+o,B=s.CENTRAL_FILE_HEADER+b(z,2)+L+b(h.length,2)+"\0\0\0\0"+b(O,4)+b(i,4)+m+o+h;return{fileRecord:T,dirRecord:B,compressedObject:a}},R={load:function(){throw new Error("Load method is not defined. Is the file jszip-load.js included ?")},filter:function(e){var t=[],a,r,s,i;for(a in this.files)this.files.hasOwnProperty(a)&&(s=this.files[a],i=new y(s.name,s._data,n.extend(s.options)),r=a.slice(this.root.length,a.length),a.slice(0,this.root.length)===this.root&&e(r,i)&&t.push(i));return t},file:function(e,t,a){if(1===arguments.length){if(n.isRegExp(e)){var r=e;return this.filter(function(e,t){return!t.dir&&r.test(e)})}return this.filter(function(t,a){return!a.dir&&t===e})[0]||null}return e=this.root+e,w.call(this,e,t,a),this},folder:function(e){if(!e)return this;if(n.isRegExp(e))return this.filter(function(t,a){return a.dir&&e.test(t)});var t=this.root+e,a=A.call(this,t),r=this.clone();return r.root=a.name,r},remove:function(e){e=this.root+e;var t=this.files[e];if(t||("/"!=e.slice(-1)&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var a=this.filter(function(t,a){return a.name.slice(0,e.length)===e}),n=0;n<a.length;n++)delete this.files[a[n].name];return this},generate:function(e){e=n.extend(e||{},{base64:!0,compression:"STORE",compressionOptions:null,type:"base64",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:u.utf8encode}),n.checkSupport(e.type),("darwin"===e.platform||"freebsd"===e.platform||"linux"===e.platform||"sunos"===e.platform)&&(e.platform="UNIX"),"win32"===e.platform&&(e.platform="DOS");var t=[],a=0,r=0,d=n.transformTo("string",e.encodeFileName(e.comment||this.comment||"")),p,c;for(var f in this.files)if(this.files.hasOwnProperty(f)){var h=this.files[f],g=h.options.compression||e.compression.toUpperCase(),y=l[g];if(!y)throw new Error(g+" is not a valid compression method !");var x=h.options.compressionOptions||e.compressionOptions||{},w=S.call(this,h,y,x),E=I.call(this,f,h,w,a,e.platform,e.encodeFileName);a+=E.fileRecord.length+w.compressedSize,r+=E.dirRecord.length,t.push(E)}var C="";C=s.CENTRAL_DIRECTORY_END+"\0\0\0\0"+b(t.length,2)+b(t.length,2)+b(r,4)+b(a,4)+b(d.length,2)+d;var A=e.type.toLowerCase();for(p="uint8array"===A||"arraybuffer"===A||"blob"===A||"nodebuffer"===A?new _(a+r+C.length):new m(a+r+C.length),c=0;c<t.length;c++)p.append(t[c].fileRecord),p.append(t[c].compressedObject.compressedContent);for(c=0;c<t.length;c++)p.append(t[c].dirRecord);p.append(C);var k=p.finalize();switch(e.type.toLowerCase()){case"uint8array":case"arraybuffer":case"nodebuffer":return n.transformTo(e.type.toLowerCase(),k);case"blob":return n.arrayBuffer2Blob(n.transformTo("arraybuffer",k),e.mimeType);case"base64":return e.base64?o.encode(k):k;default:return k;}},crc32:function(e,t){return r(e,t)},utf8encode:function(e){return n.transformTo("string",u.utf8encode(e))},utf8decode:function(e){return u.utf8decode(e)}};t.exports=R},{"./base64":12,"./compressedObject":13,"./compressions":14,"./crc32":15,"./defaults":17,"./nodeBuffer":22,"./signature":25,"./stringWriter":27,"./support":28,"./uint8ArrayWriter":30,"./utf8":31,"./utils":32}],25:[function(e,t,a){'use strict';a.LOCAL_FILE_HEADER="PK\x03\x04",a.CENTRAL_FILE_HEADER="PK\x01\x02",a.CENTRAL_DIRECTORY_END="PK\x05\x06",a.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x06\x07",a.ZIP64_CENTRAL_DIRECTORY_END="PK\x06\x06",a.DATA_DESCRIPTOR="PK\x07\b"},{}],26:[function(e,t){'use strict';function a(e,t){this.data=e,t||(this.data=r.string2binary(this.data)),this.length=this.data.length,this.index=0,this.zero=0}var n=e("./dataReader"),r=e("./utils");a.prototype=new n,a.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},a.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},a.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=a},{"./dataReader":16,"./utils":32}],27:[function(e,t){'use strict';var a=e("./utils"),n=function(){this.data=[]};n.prototype={append:function(e){e=a.transformTo("string",e),this.data.push(e)},finalize:function(){return this.data.join("")}},t.exports=n},{"./utils":32}],28:[function(e,t,a){(function(e){'use strict';if(a.base64=!0,a.array=!0,a.string=!0,a.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,a.nodebuffer="undefined"!=typeof e,a.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)a.blob=!1;else{var t=new ArrayBuffer(0);try{a.blob=0===new Blob([t],{type:"application/zip"}).size}catch(s){try{var n=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,r=new n;r.append(t),a.blob=0===r.getBlob("application/zip").size}catch(t){a.blob=!1}}}}).call(this,e("buffer").Buffer)},{buffer:7}],29:[function(e,t){'use strict';function a(e){e&&(this.data=e,this.length=this.data.length,this.index=0,this.zero=0)}var n=e("./arrayReader");a.prototype=new n,a.prototype.readData=function(e){if(this.checkOffset(e),0===e)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t.exports=a},{"./arrayReader":11}],30:[function(e,t){'use strict';var a=e("./utils"),n=function(e){this.data=new Uint8Array(e),this.index=0};n.prototype={append:function(e){0!==e.length&&(e=a.transformTo("uint8array",e),this.data.set(e,this.index),this.index+=e.length)},finalize:function(){return this.data}},t.exports=n},{"./utils":32}],31:[function(e,t,a){'use strict';for(var n=e("./utils"),r=e("./support"),s=e("./nodeBuffer"),o=Array(256),d=0;256>d;d++)o[d]=252<=d?6:248<=d?5:240<=d?4:224<=d?3:192<=d?2:1;o[254]=o[254]=1;var p=function(e){var t=e.length,a=0,n,s,o,d,l;for(d=0;d<t;d++)s=e.charCodeAt(d),55296==(64512&s)&&d+1<t&&(o=e.charCodeAt(d+1),56320==(64512&o)&&(s=65536+(s-55296<<10)+(o-56320),d++)),a+=128>s?1:2048>s?2:65536>s?3:4;for(n=r.uint8array?new Uint8Array(a):Array(a),l=0,d=0;l<a;d++)s=e.charCodeAt(d),55296==(64512&s)&&d+1<t&&(o=e.charCodeAt(d+1),56320==(64512&o)&&(s=65536+(s-55296<<10)+(o-56320),d++)),128>s?n[l++]=s:2048>s?(n[l++]=192|s>>>6,n[l++]=128|63&s):65536>s?(n[l++]=224|s>>>12,n[l++]=128|63&s>>>6,n[l++]=128|63&s):(n[l++]=240|s>>>18,n[l++]=128|63&s>>>12,n[l++]=128|63&s>>>6,n[l++]=128|63&s);return n},c=function(e,t){var a;for(t=t||e.length,t>e.length&&(t=e.length),a=t-1;0<=a&&128==(192&e[a]);)a--;return 0>a?t:0===a?t:a+o[e[a]]>t?a:t},u=function(e){var t=e.length,a=Array(2*t),r,s,d,l;for(s=0,r=0;r<t;){if(d=e[r++],128>d){a[s++]=d;continue}if(l=o[d],4<l){a[s++]=65533,r+=l-1;continue}for(d&=2===l?31:3===l?15:7;1<l&&r<t;)d=d<<6|63&e[r++],l--;if(1<l){a[s++]=65533;continue}65536>d?a[s++]=d:(d-=65536,a[s++]=55296|1023&d>>10,a[s++]=56320|1023&d)}return a.length!==s&&(a.subarray?a=a.subarray(0,s):a.length=s),n.applyFromCharCode(a)};a.utf8encode=function(e){return r.nodebuffer?s(e,"utf-8"):p(e)},a.utf8decode=function(e){if(r.nodebuffer)return n.transformTo("nodebuffer",e).toString("utf-8");e=n.transformTo(r.uint8array?"uint8array":"array",e);for(var t=[],a=0,s=e.length;a<s;){var i=c(e,l(a+65536,s));r.uint8array?t.push(u(e.subarray(a,i))):t.push(u(e.slice(a,i))),a=i}return t.join("")}},{"./nodeBuffer":22,"./support":28,"./utils":32}],32:[function(e,t,a){'use strict';function n(e){return e}function s(e,t){for(var a=0;a<e.length;++a)t[a]=255&e.charCodeAt(a);return t}function i(e){var t=65536,n=[],s=e.length,o=a.getTypeOf(e),p=0,c=!0;try{"uint8array"===o?d.apply(null,new Uint8Array(0)):"nodebuffer"===o?d.apply(null,u(0)):void 0}catch(t){c=!1}if(!c){for(var m="",_=0;_<e.length;_++)m+=d(e[_]);return m}for(;p<s&&1<t;)try{"array"===o||"nodebuffer"===o?n.push(d.apply(null,e.slice(p,l(p+t,s)))):n.push(d.apply(null,e.subarray(p,l(p+t,s)))),p+=t}catch(a){t=r(t/2)}return n.join("")}function o(e,t){for(var a=0;a<e.length;a++)t[a]=e[a];return t}var p=e("./support"),c=e("./compressions"),u=e("./nodeBuffer");a.string2binary=function(e){for(var t="",a=0;a<e.length;a++)t+=d(255&e.charCodeAt(a));return t},a.arrayBuffer2Blob=function(e,t){a.checkSupport("blob"),t=t||"application/zip";try{return new Blob([e],{type:t})}catch(a){try{var n=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,r=new n;return r.append(e),r.getBlob(t)}catch(t){throw new Error("Bug : can't construct the Blob.")}}},a.applyFromCharCode=i;var m={};m.string={string:n,array:function(e){return s(e,Array(e.length))},arraybuffer:function(e){return m.string.uint8array(e).buffer},uint8array:function(e){return s(e,new Uint8Array(e.length))},nodebuffer:function(e){return s(e,u(e.length))}},m.array={string:i,array:n,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return u(e)}},m.arraybuffer={string:function(e){return i(new Uint8Array(e))},array:function(e){return o(new Uint8Array(e),Array(e.byteLength))},arraybuffer:n,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return u(new Uint8Array(e))}},m.uint8array={string:i,array:function(e){return o(e,Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:n,nodebuffer:function(e){return u(e)}},m.nodebuffer={string:i,array:function(e){return o(e,Array(e.length))},arraybuffer:function(e){return m.nodebuffer.uint8array(e).buffer},uint8array:function(e){return o(e,new Uint8Array(e.length))},nodebuffer:n},a.transformTo=function(e,t){if(t||(t=""),!e)return t;a.checkSupport(e);var n=a.getTypeOf(t),r=m[n][e](t);return r},a.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":p.nodebuffer&&u.test(e)?"nodebuffer":p.uint8array&&e instanceof Uint8Array?"uint8array":p.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},a.checkSupport=function(e){var t=p[e.toLowerCase()];if(!t)throw new Error(e+" is not supported by this browser")},a.MAX_VALUE_16BITS=65535,a.MAX_VALUE_32BITS=-1,a.pretty=function(e){var t="",a,n;for(n=0;n<(e||"").length;n++)a=e.charCodeAt(n),t+="\\x"+(16>a?"0":"")+a.toString(16).toUpperCase();return t},a.findCompression=function(e){for(var t in c)if(c.hasOwnProperty(t)&&c[t].magic===e)return c[t];return null},a.isRegExp=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},a.extend=function(){var e={},t,a;for(t=0;t<arguments.length;t++)for(a in arguments[t])arguments[t].hasOwnProperty(a)&&"undefined"==typeof e[a]&&(e[a]=arguments[t][a]);return e}},{"./compressions":14,"./nodeBuffer":22,"./support":28}],33:[function(e,t){'use strict';function a(e,t){this.files=[],this.loadOptions=t,e&&this.load(e)}var r=e("./stringReader"),s=e("./nodeBufferReader"),i=e("./uint8ArrayReader"),o=e("./arrayReader"),d=e("./utils"),l=e("./signature"),p=e("./zipEntry"),c=e("./support"),u=e("./object");a.prototype={checkSignature:function(e){var t=this.reader.readString(4);if(t!==e)throw new Error("Corrupted zip or bug : unexpected signature ("+d.pretty(t)+", expected "+d.pretty(e)+")")},isSignature:function(e,t){var a=this.reader.index;this.reader.setIndex(e);var n=this.reader.readString(4);return this.reader.setIndex(a),n===t},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=c.uint8array?"uint8array":"array",a=d.transformTo(t,e);this.zipComment=this.loadOptions.decodeFileName(a)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.versionMadeBy=this.reader.readString(2),this.versionNeeded=this.reader.readInt(2),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e=this.zip64EndOfCentralSize-44,t,a,n;0<e;)t=this.reader.readInt(2),a=this.reader.readInt(4),n=this.reader.readString(a),this.zip64ExtensibleData[t]={id:t,length:a,value:n}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(l.LOCAL_FILE_HEADER),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},readCentralDir:function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readString(4)===l.CENTRAL_FILE_HEADER;)e=new p({zip64:this.zip64},this.loadOptions),e.readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length)if(0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length);else;},readEndOfCentral:function(){var e=this.reader.lastIndexOfSignature(l.CENTRAL_DIRECTORY_END);if(0>e){var t=!this.isSignature(0,l.LOCAL_FILE_HEADER);if(t)throw new Error("Can't find end of central directory : is this a zip file ? If it is, see http://stuk.github.io/jszip/documentation/howto/read_zip.html");else throw new Error("Corrupted zip : can't find end of central directory")}this.reader.setIndex(e);var a=e;if(this.checkSignature(l.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===d.MAX_VALUE_16BITS||this.diskWithCentralDirStart===d.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===d.MAX_VALUE_16BITS||this.centralDirRecords===d.MAX_VALUE_16BITS||this.centralDirSize===d.MAX_VALUE_32BITS||this.centralDirOffset===d.MAX_VALUE_32BITS){if(this.zip64=!0,e=this.reader.lastIndexOfSignature(l.ZIP64_CENTRAL_DIRECTORY_LOCATOR),0>e)throw new Error("Corrupted zip : can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(l.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,l.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(l.ZIP64_CENTRAL_DIRECTORY_END),0>this.relativeOffsetEndOfZip64CentralDir))throw new Error("Corrupted zip : can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(l.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var r=this.centralDirOffset+this.centralDirSize;this.zip64&&(r+=20,r+=12+this.zip64EndOfCentralSize);var s=a-r;if(0<s)this.isSignature(a,l.CENTRAL_FILE_HEADER)||(this.reader.zero=s);else if(0>s)throw new Error("Corrupted zip: missing "+n(s)+" bytes.")},prepareReader:function(e){var t=d.getTypeOf(e);if(d.checkSupport(t),"string"===t&&!c.uint8array)this.reader=new r(e,this.loadOptions.optimizedBinaryString);else if("nodebuffer"===t)this.reader=new s(e);else if(c.uint8array)this.reader=new i(d.transformTo("uint8array",e));else if(c.array)this.reader=new o(d.transformTo("array",e));else throw new Error("Unexpected error: unsupported type '"+t+"'")},load:function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},t.exports=a},{"./arrayReader":11,"./nodeBufferReader":23,"./object":24,"./signature":25,"./stringReader":26,"./support":28,"./uint8ArrayReader":29,"./utils":32,"./zipEntry":34}],34:[function(e,t){'use strict';function a(e,t){this.options=e,this.loadOptions=t}var n=e("./stringReader"),r=e("./utils"),s=e("./compressedObject"),i=e("./object"),o=e("./support");a.prototype={isEncrypted:function(){return 1==(1&this.bitFlag)},useUTF8:function(){return 2048==(2048&this.bitFlag)},prepareCompressedContent:function(e,t,a){return function(){var n=e.index;e.setIndex(t);var r=e.readData(a);return e.setIndex(n),r}},prepareContent:function(e,t,a,n,s){return function(){var e=r.transformTo(n.uncompressInputType,this.getCompressedContent()),t=n.uncompress(e);if(t.length!==s)throw new Error("Bug : uncompressed data size mismatch");return t}},readLocalPart:function(e){var t,a;if(e.skip(22),this.fileNameLength=e.readInt(2),a=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(a),-1==this.compressedSize||-1==this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize == -1 || uncompressedSize == -1)");if(t=r.findCompression(this.compressionMethod),null===t)throw new Error("Corrupted zip : compression "+r.pretty(this.compressionMethod)+" unknown (inner file : "+r.transformTo("string",this.fileName)+")");if(this.decompressed=new s,this.decompressed.compressedSize=this.compressedSize,this.decompressed.uncompressedSize=this.uncompressedSize,this.decompressed.crc32=this.crc32,this.decompressed.compressionMethod=this.compressionMethod,this.decompressed.getCompressedContent=this.prepareCompressedContent(e,e.index,this.compressedSize,t),this.decompressed.getContent=this.prepareContent(e,e.index,this.compressedSize,t,this.uncompressedSize),this.loadOptions.checkCRC32&&(this.decompressed=r.transformTo("string",this.decompressed.getContent()),i.crc32(this.decompressed)!==this.crc32))throw new Error("Corrupted zip : CRC32 mismatch")},readCentralPart:function(e){if(this.versionMadeBy=e.readInt(2),this.versionNeeded=e.readInt(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4),this.fileNameLength=e.readInt(2),this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");this.fileName=e.readData(this.fileNameLength),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),e===0&&(this.dosPermissions=63&this.externalFileAttributes),e===3&&(this.unixPermissions=65535&this.externalFileAttributes>>16),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var e=new n(this.extraFields[1].value);this.uncompressedSize===r.MAX_VALUE_32BITS&&(this.uncompressedSize=e.readInt(8)),this.compressedSize===r.MAX_VALUE_32BITS&&(this.compressedSize=e.readInt(8)),this.localHeaderOffset===r.MAX_VALUE_32BITS&&(this.localHeaderOffset=e.readInt(8)),this.diskNumberStart===r.MAX_VALUE_32BITS&&(this.diskNumberStart=e.readInt(4))}},readExtraFields:function(e){var t=e.index,a,n,r;for(this.extraFields=this.extraFields||{};e.index<t+this.extraFieldsLength;)a=e.readInt(2),n=e.readInt(2),r=e.readString(n),this.extraFields[a]={id:a,length:n,value:r}},handleUTF8:function(){var e=o.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=i.utf8decode(this.fileName),this.fileCommentStr=i.utf8decode(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var a=r.transformTo(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(a)}var n=this.findExtraFieldUnicodeComment();if(null!==n)this.fileCommentStr=n;else{var s=r.transformTo(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(s)}}},findExtraFieldUnicodePath:function(){var e=this.extraFields[28789];if(e){var t=new n(e.value);return 1===t.readInt(1)?i.crc32(this.fileName)===t.readInt(4)?i.utf8decode(t.readString(e.length-5)):null:null}return null},findExtraFieldUnicodeComment:function(){var e=this.extraFields[25461];if(e){var t=new n(e.value);return 1===t.readInt(1)?i.crc32(this.fileComment)===t.readInt(4)?i.utf8decode(t.readString(e.length-5)):null:null}return null}},t.exports=a},{"./compressedObject":13,"./object":24,"./stringReader":26,"./support":28,"./utils":32}],35:[function(e,t){'use strict';function a(){}function n(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=_,this.queue=[],this.outcome=void 0,e!==a&&d(this,e)}function r(e,t,a){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof a&&(this.onRejected=a,this.callRejected=this.otherCallRejected)}function s(t,a,n){p(function(){var e;try{e=a(n)}catch(a){return c.reject(t,a)}e===t?c.reject(t,new TypeError("Cannot resolve promise with itself")):c.resolve(t,e)})}function o(e){var t=e&&e.then;if(e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function d(e,t){function a(t){r||(r=!0,c.reject(e,t))}function n(t){r||(r=!0,c.resolve(e,t))}var r=!1,s=l(function(){t(n,a)});"error"===s.status&&a(s.value)}function l(e,t){var a={};try{a.value=e(t),a.status="success"}catch(t){a.status="error",a.value=t}return a}var p=e("immediate"),c={},u=["REJECTED"],m=["FULFILLED"],_=["PENDING"];t.exports=n,n.prototype["finally"]=function(e){if("function"!=typeof e)return this;var t=this.constructor;return this.then(function(a){return t.resolve(e()).then(function(){return a})},function(a){return t.resolve(e()).then(function(){throw a})})},n.prototype["catch"]=function(e){return this.then(null,e)},n.prototype.then=function(e,t){if("function"!=typeof e&&this.state===m||"function"!=typeof t&&this.state===u)return this;var n=new this.constructor(a);if(this.state!==_){var i=this.state===m?e:t;s(n,i,this.outcome)}else this.queue.push(new r(n,e,t));return n},r.prototype.callFulfilled=function(e){c.resolve(this.promise,e)},r.prototype.otherCallFulfilled=function(e){s(this.promise,this.onFulfilled,e)},r.prototype.callRejected=function(e){c.reject(this.promise,e)},r.prototype.otherCallRejected=function(e){s(this.promise,this.onRejected,e)},c.resolve=function(e,t){var a=l(o,t);if("error"===a.status)return c.reject(e,a.value);var n=a.value;if(n)d(e,n);else{e.state=m,e.outcome=t;for(var r=-1,s=e.queue.length;++r<s;)e.queue[r].callFulfilled(t)}return e},c.reject=function(e,t){e.state=u,e.outcome=t;for(var a=-1,n=e.queue.length;++a<n;)e.queue[a].callRejected(t);return e},n.resolve=function(e){return e instanceof this?e:c.resolve(new this(a),e)},n.reject=function(e){var t=new this(a);return c.reject(t,e)},n.all=function(e){function t(e,t){function a(e){o[t]=e,++d!==r||s||(s=!0,c.resolve(p,o))}n.resolve(e).then(a,function(e){s||(s=!0,c.reject(p,e))})}var n=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var r=e.length,s=!1;if(!r)return this.resolve([]);for(var o=Array(r),d=0,l=-1,p=new this(a);++l<r;)t(e[l],l);return p},n.race=function(e){function t(e){n.resolve(e).then(function(e){s||(s=!0,c.resolve(d,e))},function(e){s||(s=!0,c.reject(d,e))})}var n=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var r=e.length,s=!1;if(!r)return this.resolve([]);for(var o=-1,d=new this(a);++o<r;)t(e[o]);return d}},{immediate:9}],36:[function(e,t){(function(){function e(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function a(){return 1}function n(e){m||"string"==typeof e||"number"==typeof e||(m=!0,console.error(new TypeError("LRU: key must be a string or number. Almost certainly a bug! "+typeof e).stack))}function r(e){return this instanceof r?void("number"==typeof e&&(e={max:e}),!e&&(e={}),this._max=e.max,(!this._max||"number"!=typeof this._max||0>=this._max)&&(this._max=1/0),this._lengthCalculator=e.length||a,"function"!=typeof this._lengthCalculator&&(this._lengthCalculator=a),this._allowStale=e.stale||!1,this._maxAge=e.maxAge||null,this._dispose=e.dispose,this.reset()):new r(e)}function s(e,t,a){n(t);var r=e._cache[t];return r&&(o(e,r)?(c(e,r),!e._allowStale&&(r=void 0)):a&&d(e,r),r&&(r=r.value)),r}function o(e,t){if(!t||!t.maxAge&&!e._maxAge)return!1;var a=!1,n=Date.now()-t.now;return a=t.maxAge?n>t.maxAge:e._maxAge&&n>e._maxAge,a}function d(e,t){p(e,t),t.lu=e._mru++,e._lruList[t.lu]=t}function l(e){for(;e._lru<e._mru&&e._length>e._max;)c(e,e._lruList[e._lru])}function p(e,t){for(delete e._lruList[t.lu];e._lru<e._mru&&!e._lruList[e._lru];)e._lru++}function c(e,t){t&&(e._dispose&&e._dispose(t.key,t.value),e._length-=t.length,e._itemCount--,delete e._cache[t.key],p(e,t))}function u(e,t,a,n,r,s){this.key=e,this.value=t,this.lu=a,this.length=n,this.now=r,s&&(this.maxAge=s)}"object"==typeof t&&t.exports?t.exports=r:this.LRUCache=r;var m=!1;Object.defineProperty(r.prototype,"max",{set:function(e){e&&"number"==typeof e&&!(0>=e)||(e=1/0),this._max=e,this._length>this._max&&l(this)},get:function(){return this._max},enumerable:!0}),Object.defineProperty(r.prototype,"lengthCalculator",{set:function(e){if("function"!=typeof e)for(var t in this._lengthCalculator=a,this._length=this._itemCount,this._cache)this._cache[t].length=1;else for(var t in this._lengthCalculator=e,this._length=0,this._cache)this._cache[t].length=this._lengthCalculator(this._cache[t].value),this._length+=this._cache[t].length;this._length>this._max&&l(this)},get:function(){return this._lengthCalculator},enumerable:!0}),Object.defineProperty(r.prototype,"length",{get:function(){return this._length},enumerable:!0}),Object.defineProperty(r.prototype,"itemCount",{get:function(){return this._itemCount},enumerable:!0}),r.prototype.forEach=function(e,t){t=t||this;for(var a=0,n=this._itemCount,r=this._mru-1;0<=r&&a<n;r--)if(this._lruList[r]){a++;var s=this._lruList[r];o(this,s)&&(c(this,s),!this._allowStale&&(s=void 0)),s&&e.call(t,s.value,s.key,this)}},r.prototype.keys=function(){for(var e=Array(this._itemCount),t=0,a=this._mru-1;0<=a&&t<this._itemCount;a--)if(this._lruList[a]){var n=this._lruList[a];e[t++]=n.key}return e},r.prototype.values=function(){for(var e=Array(this._itemCount),t=0,a=this._mru-1;0<=a&&t<this._itemCount;a--)if(this._lruList[a]){var n=this._lruList[a];e[t++]=n.value}return e},r.prototype.reset=function(){if(this._dispose&&this._cache)for(var e in this._cache)this._dispose(e,this._cache[e].value);this._cache=Object.create(null),this._lruList=Object.create(null),this._mru=0,this._lru=0,this._length=0,this._itemCount=0},r.prototype.dump=function(){for(var e=[],t=0,a=this._mru-1;0<=a&&t<this._itemCount;a--)if(this._lruList[a]){var n=this._lruList[a];o(this,n)||(++t,e.push({k:n.key,v:n.value,e:n.now+(n.maxAge||0)}))}return e},r.prototype.dumpLru=function(){return this._lruList},r.prototype.set=function(t,a,r){r=r||this._maxAge,n(t);var s=r?Date.now():0,i=this._lengthCalculator(a);if(e(this._cache,t))return i>this._max?(c(this,this._cache[t]),!1):(this._dispose&&this._dispose(t,this._cache[t].value),this._cache[t].now=s,this._cache[t].maxAge=r,this._cache[t].value=a,this._length+=i-this._cache[t].length,this._cache[t].length=i,this.get(t),this._length>this._max&&l(this),!0);var o=new u(t,a,this._mru++,i,s,r);return o.length>this._max?(this._dispose&&this._dispose(t,a),!1):(this._length+=o.length,this._lruList[o.lu]=this._cache[t]=o,this._itemCount++,this._length>this._max&&l(this),!0)},r.prototype.has=function(t){if(n(t),!e(this._cache,t))return!1;var a=this._cache[t];return!o(this,a)},r.prototype.get=function(e){return n(e),s(this,e,!0)},r.prototype.peek=function(e){return n(e),s(this,e,!1)},r.prototype.pop=function(){var e=this._lruList[this._lru];return c(this,e),e||null},r.prototype.del=function(e){n(e),c(this,this._cache[e])},r.prototype.load=function(e){this.reset();for(var t=Date.now(),a=e.length-1,r;0<=a;a--){r=e[a],n(r.k);var s=r.e||0;if(0===s)this.set(r.k,r.v);else{var i=s-t;0<i&&this.set(r.k,r.v,i)}}}})()},{}],37:[function(e,t){'use strict';var a=e("./lib/utils/common").assign,n=e("./lib/deflate"),r=e("./lib/inflate"),s=e("./lib/zlib/constants"),i={};a(i,n,r,s),t.exports=i},{"./lib/deflate":38,"./lib/inflate":39,"./lib/utils/common":40,"./lib/zlib/constants":43}],38:[function(e,t,a){'use strict';function n(e){if(!(this instanceof n))return new n(e);this.options=i.assign({level:-1,method:8,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,to:""},e||{});var t=this.options;t.raw&&0<t.windowBits?t.windowBits=-t.windowBits:t.gzip&&0<t.windowBits&&16>t.windowBits&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var a=s.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(0!==a)throw new Error(d[a]);if(t.header&&s.deflateSetHeader(this.strm,t.header),t.dictionary){var r;if(r="string"==typeof t.dictionary?o.string2buf(t.dictionary):"[object ArrayBuffer]"===p.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,a=s.deflateSetDictionary(this.strm,r),0!==a)throw new Error(d[a]);this._dict_set=!0}}function r(e,t){var a=new n(t);if(a.push(e,!0),a.err)throw a.msg||d[a.err];return a.result}var s=e("./zlib/deflate"),i=e("./utils/common"),o=e("./utils/strings"),d=e("./zlib/messages"),l=e("./zlib/zstream"),p=Object.prototype.toString,c=4,u=0,m=1,_=2;n.prototype.push=function(e,t){var a=this.strm,n=this.options.chunkSize,r,d;if(this.ended)return!1;d=t===~~t?t:!0===t?c:0,a.input="string"==typeof e?o.string2buf(e):"[object ArrayBuffer]"===p.call(e)?new Uint8Array(e):e,a.next_in=0,a.avail_in=a.input.length;do{if(0===a.avail_out&&(a.output=new i.Buf8(n),a.next_out=0,a.avail_out=n),r=s.deflate(a,d),r!==m&&r!==u)return this.onEnd(r),this.ended=!0,!1;(0===a.avail_out||0===a.avail_in&&(d===c||d===_))&&("string"===this.options.to?this.onData(o.buf2binstring(i.shrinkBuf(a.output,a.next_out))):this.onData(i.shrinkBuf(a.output,a.next_out)))}while((0<a.avail_in||0===a.avail_out)&&r!==m);return d===c?(r=s.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===u):d!==_||(this.onEnd(u),a.avail_out=0,!0)},n.prototype.onData=function(e){this.chunks.push(e)},n.prototype.onEnd=function(e){e===u&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},a.Deflate=n,a.deflate=r,a.deflateRaw=function(e,t){return t=t||{},t.raw=!0,r(e,t)},a.gzip=function(e,t){return t=t||{},t.gzip=!0,r(e,t)}},{"./utils/common":40,"./utils/strings":41,"./zlib/deflate":45,"./zlib/messages":50,"./zlib/zstream":52}],39:[function(e,t,a){'use strict';function n(e){if(!(this instanceof n))return new n(e);this.options=i.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&0<=t.windowBits&&16>t.windowBits&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),0<=t.windowBits&&16>t.windowBits&&!(e&&e.windowBits)&&(t.windowBits+=32),15<t.windowBits&&48>t.windowBits&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new p,this.strm.avail_out=0;var a=s.inflateInit2(this.strm,t.windowBits);if(a!==d.Z_OK)throw new Error(l[a]);if(this.header=new c,s.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=o.string2buf(t.dictionary):"[object ArrayBuffer]"===u.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(a=s.inflateSetDictionary(this.strm,t.dictionary),a!==d.Z_OK)))throw new Error(l[a])}function r(e,t){var a=new n(t);if(a.push(e,!0),a.err)throw a.msg||l[a.err];return a.result}var s=e("./zlib/inflate"),i=e("./utils/common"),o=e("./utils/strings"),d=e("./zlib/constants"),l=e("./zlib/messages"),p=e("./zlib/zstream"),c=e("./zlib/gzheader"),u=Object.prototype.toString;n.prototype.push=function(e,t){var a=this.strm,n=this.options.chunkSize,r=this.options.dictionary,l=!1,p,c,m,_,f;if(this.ended)return!1;c=t===~~t?t:!0===t?d.Z_FINISH:d.Z_NO_FLUSH,a.input="string"==typeof e?o.binstring2buf(e):"[object ArrayBuffer]"===u.call(e)?new Uint8Array(e):e,a.next_in=0,a.avail_in=a.input.length;do{if(0===a.avail_out&&(a.output=new i.Buf8(n),a.next_out=0,a.avail_out=n),p=s.inflate(a,d.Z_NO_FLUSH),p===d.Z_NEED_DICT&&r&&(p=s.inflateSetDictionary(this.strm,r)),p===d.Z_BUF_ERROR&&!0===l&&(p=d.Z_OK,l=!1),p!==d.Z_STREAM_END&&p!==d.Z_OK)return this.onEnd(p),this.ended=!0,!1;a.next_out&&(0===a.avail_out||p===d.Z_STREAM_END||0===a.avail_in&&(c===d.Z_FINISH||c===d.Z_SYNC_FLUSH))&&("string"===this.options.to?(m=o.utf8border(a.output,a.next_out),_=a.next_out-m,f=o.buf2string(a.output,m),a.next_out=_,a.avail_out=n-_,_&&i.arraySet(a.output,a.output,m,_,0),this.onData(f)):this.onData(i.shrinkBuf(a.output,a.next_out))),0===a.avail_in&&0===a.avail_out&&(l=!0)}while((0<a.avail_in||0===a.avail_out)&&p!==d.Z_STREAM_END);return p===d.Z_STREAM_END&&(c=d.Z_FINISH),c===d.Z_FINISH?(p=s.inflateEnd(this.strm),this.onEnd(p),this.ended=!0,p===d.Z_OK):c!==d.Z_SYNC_FLUSH||(this.onEnd(d.Z_OK),a.avail_out=0,!0)},n.prototype.onData=function(e){this.chunks.push(e)},n.prototype.onEnd=function(e){e===d.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},a.Inflate=n,a.inflate=r,a.inflateRaw=function(e,t){return t=t||{},t.raw=!0,r(e,t)},a.ungzip=r},{"./utils/common":40,"./utils/strings":41,"./zlib/constants":43,"./zlib/gzheader":46,"./zlib/inflate":48,"./zlib/messages":50,"./zlib/zstream":52}],40:[function(e,t,a){'use strict';function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;a.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var a=t.shift();if(a){if("object"!=typeof a)throw new TypeError(a+"must be non-object");for(var r in a)n(a,r)&&(e[r]=a[r])}}return e},a.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var s={arraySet:function(e,t,a,n,r){if(t.subarray&&e.subarray)return void e.set(t.subarray(a,a+n),r);for(var s=0;s<n;s++)e[r+s]=t[a+s]},flattenChunks:function(e){var t,a,n,r,s,o;for(n=0,t=0,a=e.length;t<a;t++)n+=e[t].length;for(o=new Uint8Array(n),r=0,(t=0,a=e.length);t<a;t++)s=e[t],o.set(s,r),r+=s.length;return o}},i={arraySet:function(e,t,a,n,r){for(var s=0;s<n;s++)e[r+s]=t[a+s]},flattenChunks:function(e){return[].concat.apply([],e)}};a.setTyped=function(e){e?(a.Buf8=Uint8Array,a.Buf16=Uint16Array,a.Buf32=Int32Array,a.assign(a,s)):(a.Buf8=Array,a.Buf16=Array,a.Buf32=Array,a.assign(a,i))},a.setTyped(r)},{}],41:[function(e,t,a){'use strict';function n(e,t){if(65534>t&&(e.subarray&&o||!e.subarray&&s))return d.apply(null,r.shrinkBuf(e,t));for(var a="",n=0;n<t;n++)a+=d(e[n]);return a}var r=e("./common"),s=!0,o=!0;try{d.apply(null,[0])}catch(e){s=!1}try{d.apply(null,new Uint8Array(1))}catch(e){o=!1}for(var l=new r.Buf8(256),p=0;256>p;p++)l[p]=252<=p?6:248<=p?5:240<=p?4:224<=p?3:192<=p?2:1;l[254]=l[254]=1,a.string2buf=function(e){var t=e.length,a=0,n,s,o,d,l;for(d=0;d<t;d++)s=e.charCodeAt(d),55296==(64512&s)&&d+1<t&&(o=e.charCodeAt(d+1),56320==(64512&o)&&(s=65536+(s-55296<<10)+(o-56320),d++)),a+=128>s?1:2048>s?2:65536>s?3:4;for(n=new r.Buf8(a),l=0,d=0;l<a;d++)s=e.charCodeAt(d),55296==(64512&s)&&d+1<t&&(o=e.charCodeAt(d+1),56320==(64512&o)&&(s=65536+(s-55296<<10)+(o-56320),d++)),128>s?n[l++]=s:2048>s?(n[l++]=192|s>>>6,n[l++]=128|63&s):65536>s?(n[l++]=224|s>>>12,n[l++]=128|63&s>>>6,n[l++]=128|63&s):(n[l++]=240|s>>>18,n[l++]=128|63&s>>>12,n[l++]=128|63&s>>>6,n[l++]=128|63&s);return n},a.buf2binstring=function(e){return n(e,e.length)},a.binstring2buf=function(e){for(var t=new r.Buf8(e.length),a=0,n=t.length;a<n;a++)t[a]=e.charCodeAt(a);return t},a.buf2string=function(e,t){var a=t||e.length,r=Array(2*a),s,o,d,p;for(o=0,s=0;s<a;){if(d=e[s++],128>d){r[o++]=d;continue}if(p=l[d],4<p){r[o++]=65533,s+=p-1;continue}for(d&=2===p?31:3===p?15:7;1<p&&s<a;)d=d<<6|63&e[s++],p--;if(1<p){r[o++]=65533;continue}65536>d?r[o++]=d:(d-=65536,r[o++]=55296|1023&d>>10,r[o++]=56320|1023&d)}return n(r,o)},a.utf8border=function(e,t){var a;for(t=t||e.length,t>e.length&&(t=e.length),a=t-1;0<=a&&128==(192&e[a]);)a--;return 0>a?t:0===a?t:a+l[e[a]]>t?a:t}},{"./common":40}],42:[function(e,t){'use strict';t.exports=function(e,t,a,r){for(var s=0|65535&e,i=0|65535&e>>>16,o=0;0!==a;){o=2e3<a?2e3:a,a-=o;do s=0|s+t[r++],i=0|i+s;while(--o);s%=65521,i%=65521}return 0|(s|i<<16)}},{}],43:[function(e,t){'use strict';t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],44:[function(e,t){'use strict';var a=function(){for(var e=[],t=0,a;256>t;t++){a=t;for(var r=0;8>r;r++)a=1&a?3988292384^a>>>1:a>>>1;e[t]=a}return e}();t.exports=function(e,t,n,r){e^=-1;for(var s=r;s<r+n;s++)e=e>>>8^a[255&(e^t[s])];return-1^e}},{}],45:[function(e,t,a){'use strict';function n(e,t){return e.msg=R[t],t}function r(e){return(e<<1)-(4<e?9:0)}function i(e){for(var t=e.length;0<=--t;)e[t]=0}function o(e){var t=e.state,a=t.pending;a>e.avail_out&&(a=e.avail_out);0===a||(S.arraySet(e.output,t.pending_buf,t.pending_out,a,e.next_out),e.next_out+=a,t.pending_out+=a,e.total_out+=a,e.avail_out-=a,t.pending-=a,0===t.pending&&(t.pending_out=0))}function d(e,t){k._tr_flush_block(e,0<=e.block_start?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,o(e.strm)}function l(e,t){e.pending_buf[e.pending++]=t}function p(e,t){e.pending_buf[e.pending++]=255&t>>>8,e.pending_buf[e.pending++]=255&t}function c(e,t,a,n){var r=e.avail_in;return(r>n&&(r=n),0===r)?0:(e.avail_in-=r,S.arraySet(t,e.input,e.next_in,r,a),1===e.state.wrap?e.adler=v(e.adler,t,r,a):2===e.state.wrap&&(e.adler=I(e.adler,t,r,a)),e.next_in+=r,e.total_in+=r,r)}function u(e,t){var a=e.max_chain_length,n=e.strstart,r=e.prev_length,s=e.nice_match,i=e.strstart>e.w_size-262?e.strstart-(e.w_size-262):0,o=e.window,d=e.w_mask,l=e.prev,p=e.strstart+258,c=o[n+r-1],u=o[n+r],m,_;e.prev_length>=e.good_match&&(a>>=2),s>e.lookahead&&(s=e.lookahead);do{if(m=t,o[m+r]!==u||o[m+r-1]!==c||o[m]!==o[n]||o[++m]!==o[n+1])continue;n+=2,m++;do;while(o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&o[++n]===o[++m]&&n<p);if(_=258-(p-n),n=p-258,_>r){if(e.match_start=t,r=_,_>=s)break;c=o[n+r-1],u=o[n+r]}}while((t=l[t&d])>i&&0!=--a);return r<=e.lookahead?r:e.lookahead}function m(e){var t=e.w_size,a,r,s,i,o;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-262)){S.arraySet(e.window,e.window,t,t,0),e.match_start-=t,e.strstart-=t,e.block_start-=t,r=e.hash_size,a=r;do s=e.head[--a],e.head[a]=s>=t?s-t:0;while(--r);r=t,a=r;do s=e.prev[--a],e.prev[a]=s>=t?s-t:0;while(--r);i+=t}if(0===e.strm.avail_in)break;if(r=c(e.strm,e.window,e.strstart+e.lookahead,i),e.lookahead+=r,3<=e.lookahead+e.insert)for(o=e.strstart-e.insert,e.ins_h=e.window[o],e.ins_h=(e.ins_h<<e.hash_shift^e.window[o+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[o+3-1])&e.hash_mask,e.prev[o&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=o,o++,e.insert--,!(3>e.lookahead+e.insert)););}while(262>e.lookahead&&0!==e.strm.avail_in)}function _(e,t){for(var a,n;;){if(262>e.lookahead){if(m(e),262>e.lookahead&&0===t)return 1;if(0===e.lookahead)break}if(a=0,3<=e.lookahead&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,a=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==a&&e.strstart-a<=e.w_size-262&&(e.match_length=u(e,a)),!(3<=e.match_length))n=k._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;else if(n=k._tr_tally(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&3<=e.lookahead){e.match_length--;do e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,a=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;if(n&&(d(e,!1),0===e.strm.avail_out))return 1}return e.insert=2>e.strstart?e.strstart:2,4===t?(d(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(d(e,!1),0===e.strm.avail_out)?1:2}function f(e,t){for(var a,n,r;;){if(262>e.lookahead){if(m(e),262>e.lookahead&&0===t)return 1;if(0===e.lookahead)break}if(a=0,3<=e.lookahead&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,a=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==a&&e.prev_length<e.max_lazy_match&&e.strstart-a<=e.w_size-262&&(e.match_length=u(e,a),5>=e.match_length&&(1===e.strategy||3===e.match_length&&4096<e.strstart-e.match_start)&&(e.match_length=2)),3<=e.prev_length&&e.match_length<=e.prev_length){r=e.strstart+e.lookahead-3,n=k._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=r&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,a=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,n&&(d(e,!1),0===e.strm.avail_out))return 1}else if(!e.match_available)e.match_available=1,e.strstart++,e.lookahead--;else if(n=k._tr_tally(e,0,e.window[e.strstart-1]),n&&d(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}return e.match_available&&(n=k._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=2>e.strstart?e.strstart:2,4===t?(d(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(d(e,!1),0===e.strm.avail_out)?1:2}function h(e,t){for(var a=e.window,n,r,s,i;;){if(258>=e.lookahead){if(m(e),258>=e.lookahead&&0===t)return 1;if(0===e.lookahead)break}if(e.match_length=0,3<=e.lookahead&&0<e.strstart&&(s=e.strstart-1,r=a[s],r===a[++s]&&r===a[++s]&&r===a[++s])){i=e.strstart+258;do;while(r===a[++s]&&r===a[++s]&&r===a[++s]&&r===a[++s]&&r===a[++s]&&r===a[++s]&&r===a[++s]&&r===a[++s]&&s<i);e.match_length=258-(i-s),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(3<=e.match_length?(n=k._tr_tally(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=k._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(d(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(d(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(d(e,!1),0===e.strm.avail_out)?1:2}function g(e,t){for(var a;;){if(0===e.lookahead&&(m(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,a=k._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,a&&(d(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(d(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(d(e,!1),0===e.strm.avail_out)?1:2}function y(e,t,a,n,r){this.good_length=e,this.max_lazy=t,this.nice_length=a,this.max_chain=n,this.func=r}function b(e){e.window_size=2*e.w_size,i(e.head),e.max_lazy_match=O[e.level].max_lazy,e.good_match=O[e.level].good_length,e.nice_match=O[e.level].nice_length,e.max_chain_length=O[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=2,e.match_available=0,e.ins_h=0}function x(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new S.Buf16(1146),this.dyn_dtree=new S.Buf16(122),this.bl_tree=new S.Buf16(78),i(this.dyn_ltree),i(this.dyn_dtree),i(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new S.Buf16(16),this.heap=new S.Buf16(573),i(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new S.Buf16(573),i(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function w(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=2,t=e.state,t.pending=0,t.pending_out=0,0>t.wrap&&(t.wrap=-t.wrap),t.status=t.wrap?42:113,e.adler=2===t.wrap?0:1,t.last_flush=0,k._tr_init(t),0):n(e,-2)}function E(e){var t=w(e);return 0===t&&b(e.state),t}function C(e,t,a,r,i,o){if(!e)return-2;var d=1;if(-1===t&&(t=6),0>r?(d=0,r=-r):15<r&&(d=2,r-=16),1>i||9<i||8!==a||8>r||15<r||0>t||9<t||0>o||4<o)return n(e,-2);8===r&&(r=9);var l=new x;return e.state=l,l.strm=e,l.wrap=d,l.gzhead=null,l.w_bits=r,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=i+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+3-1)/3),l.window=new S.Buf8(2*l.w_size),l.head=new S.Buf16(l.hash_size),l.prev=new S.Buf16(l.w_size),l.lit_bufsize=1<<i+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new S.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=t,l.strategy=o,l.method=a,E(e)}function A(e,t){var a,d,c,u;if(!e||!e.state||5<t||0>t)return e?n(e,-2):-2;if(d=e.state,!e.output||!e.input&&0!==e.avail_in||666===d.status&&4!==t)return n(e,0===e.avail_out?-5:-2);if(d.strm=e,a=d.last_flush,d.last_flush=t,42===d.status)if(2===d.wrap)e.adler=0,l(d,31),l(d,139),l(d,8),d.gzhead?(l(d,(d.gzhead.text?1:0)+(d.gzhead.hcrc?2:0)+(d.gzhead.extra?4:0)+(d.gzhead.name?8:0)+(d.gzhead.comment?16:0)),l(d,255&d.gzhead.time),l(d,255&d.gzhead.time>>8),l(d,255&d.gzhead.time>>16),l(d,255&d.gzhead.time>>24),l(d,9===d.level?2:2<=d.strategy||2>d.level?4:0),l(d,255&d.gzhead.os),d.gzhead.extra&&d.gzhead.extra.length&&(l(d,255&d.gzhead.extra.length),l(d,255&d.gzhead.extra.length>>8)),d.gzhead.hcrc&&(e.adler=I(e.adler,d.pending_buf,d.pending,0)),d.gzindex=0,d.status=69):(l(d,0),l(d,0),l(d,0),l(d,0),l(d,0),l(d,9===d.level?2:2<=d.strategy||2>d.level?4:0),l(d,3),d.status=113);else{var m=8+(d.w_bits-8<<4)<<8,_=-1;_=2<=d.strategy||2>d.level?0:6>d.level?1:6===d.level?2:3,m|=_<<6,0!==d.strstart&&(m|=32),m+=31-m%31,d.status=113,p(d,m),0!==d.strstart&&(p(d,e.adler>>>16),p(d,65535&e.adler)),e.adler=1}if(69===d.status)if(d.gzhead.extra){for(c=d.pending;d.gzindex<(65535&d.gzhead.extra.length)&&!(d.pending===d.pending_buf_size&&(d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),o(e),c=d.pending,d.pending===d.pending_buf_size));)l(d,255&d.gzhead.extra[d.gzindex]),d.gzindex++;d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),d.gzindex===d.gzhead.extra.length&&(d.gzindex=0,d.status=73)}else d.status=73;if(73===d.status)if(d.gzhead.name){c=d.pending;do{if(d.pending===d.pending_buf_size&&(d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),o(e),c=d.pending,d.pending===d.pending_buf_size)){u=1;break}u=d.gzindex<d.gzhead.name.length?255&d.gzhead.name.charCodeAt(d.gzindex++):0,l(d,u)}while(0!==u);d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),0===u&&(d.gzindex=0,d.status=91)}else d.status=91;if(91===d.status)if(d.gzhead.comment){c=d.pending;do{if(d.pending===d.pending_buf_size&&(d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),o(e),c=d.pending,d.pending===d.pending_buf_size)){u=1;break}u=d.gzindex<d.gzhead.comment.length?255&d.gzhead.comment.charCodeAt(d.gzindex++):0,l(d,u)}while(0!==u);d.gzhead.hcrc&&d.pending>c&&(e.adler=I(e.adler,d.pending_buf,d.pending-c,c)),0===u&&(d.status=103)}else d.status=103;if(103===d.status&&(d.gzhead.hcrc?(d.pending+2>d.pending_buf_size&&o(e),d.pending+2<=d.pending_buf_size&&(l(d,255&e.adler),l(d,255&e.adler>>8),e.adler=0,d.status=113)):d.status=113),0!==d.pending){if(o(e),0===e.avail_out)return d.last_flush=-1,0;}else if(0===e.avail_in&&r(t)<=r(a)&&4!==t)return n(e,-5);if(666===d.status&&0!==e.avail_in)return n(e,-5);if(0!==e.avail_in||0!==d.lookahead||0!==t&&666!==d.status){var f=2===d.strategy?g(d,t):3===d.strategy?h(d,t):O[d.level].func(d,t);if((3===f||4===f)&&(d.status=666),1===f||3===f)return 0===e.avail_out&&(d.last_flush=-1),0;if(2===f&&(1===t?k._tr_align(d):5!==t&&(k._tr_stored_block(d,0,0,!1),3===t&&(i(d.head),0===d.lookahead&&(d.strstart=0,d.block_start=0,d.insert=0))),o(e),0===e.avail_out))return d.last_flush=-1,0}return 4===t?0>=d.wrap?1:(2===d.wrap?(l(d,255&e.adler),l(d,255&e.adler>>8),l(d,255&e.adler>>16),l(d,255&e.adler>>24),l(d,255&e.total_in),l(d,255&e.total_in>>8),l(d,255&e.total_in>>16),l(d,255&e.total_in>>24)):(p(d,e.adler>>>16),p(d,65535&e.adler)),o(e),0<d.wrap&&(d.wrap=-d.wrap),0===d.pending?1:0):0}var S=e("../utils/common"),k=e("./trees"),v=e("./adler32"),I=e("./crc32"),R=e("./messages"),O;O=[new y(0,0,0,0,function(e,t){var a=65535;for(a>e.pending_buf_size-5&&(a=e.pending_buf_size-5);;){if(1>=e.lookahead){if(m(e),0===e.lookahead&&0===t)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+a;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,d(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-262&&(d(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(d(e,!0),0===e.strm.avail_out?3:4):e.strstart>e.block_start&&(d(e,!1),0===e.strm.avail_out)?1:1}),new y(4,4,8,4,_),new y(4,5,16,8,_),new y(4,6,32,32,_),new y(4,4,16,16,f),new y(8,16,32,32,f),new y(8,16,128,128,f),new y(8,32,128,256,f),new y(32,128,258,1024,f),new y(32,258,258,4096,f)],a.deflateInit=function(e,t){return C(e,t,8,15,8,0)},a.deflateInit2=C,a.deflateReset=E,a.deflateResetKeep=w,a.deflateSetHeader=function(e,t){return e&&e.state?2===e.state.wrap?(e.state.gzhead=t,0):-2:-2},a.deflate=A,a.deflateEnd=function(e){var t;return e&&e.state?(t=e.state.status,42!==t&&69!==t&&73!==t&&91!==t&&103!==t&&113!==t&&666!==t)?n(e,-2):(e.state=null,113===t?n(e,-3):0):-2},a.deflateSetDictionary=function(e,t){var a=t.length,r,o,d,l,p,c,u,_;if(!e||!e.state)return-2;if(r=e.state,l=r.wrap,2===l||1===l&&42!==r.status||r.lookahead)return-2;for(1===l&&(e.adler=v(e.adler,t,a,0)),r.wrap=0,a>=r.w_size&&(0===l&&(i(r.head),r.strstart=0,r.block_start=0,r.insert=0),_=new S.Buf8(r.w_size),S.arraySet(_,t,a-r.w_size,r.w_size,0),t=_,a=r.w_size),p=e.avail_in,c=e.next_in,u=e.input,e.avail_in=a,e.next_in=0,e.input=t,m(r);3<=r.lookahead;){o=r.strstart,d=r.lookahead-2;do r.ins_h=(r.ins_h<<r.hash_shift^r.window[o+3-1])&r.hash_mask,r.prev[o&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=o,o++;while(--d);r.strstart=o,r.lookahead=2,m(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,e.next_in=c,e.input=u,e.avail_in=p,r.wrap=l,0},a.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":40,"./adler32":42,"./crc32":44,"./messages":50,"./trees":51}],46:[function(e,t){'use strict';t.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],47:[function(e,t){'use strict';t.exports=function(e,t){var a,n,r,s,i,o,d,l,p,c,u,m,_,f,h,g,y,b,x,w,E,C,A,S,k;a=e.state,n=e.next_in,S=e.input,r=n+(e.avail_in-5),s=e.next_out,k=e.output,i=s-(t-e.avail_out),o=s+(e.avail_out-257),d=a.dmax,l=a.wsize,p=a.whave,c=a.wnext,u=a.window,m=a.hold,_=a.bits,f=a.lencode,h=a.distcode,g=(1<<a.lenbits)-1,y=(1<<a.distbits)-1;top:do{15>_&&(m+=S[n++]<<_,_+=8,m+=S[n++]<<_,_+=8),b=f[m&g];dolen:for(;;){if(x=b>>>24,m>>>=x,_-=x,x=255&b>>>16,0===x)k[s++]=65535&b;else if(16&x){w=65535&b,x&=15,x&&(_<x&&(m+=S[n++]<<_,_+=8),w+=m&(1<<x)-1,m>>>=x,_-=x),15>_&&(m+=S[n++]<<_,_+=8,m+=S[n++]<<_,_+=8),b=h[m&y];dodist:for(;;){if(x=b>>>24,m>>>=x,_-=x,x=255&b>>>16,16&x){if(E=65535&b,x&=15,_<x&&(m+=S[n++]<<_,_+=8,_<x&&(m+=S[n++]<<_,_+=8)),E+=m&(1<<x)-1,E>d){e.msg="invalid distance too far back",a.mode=30;break top}if(m>>>=x,_-=x,x=s-i,E>x){if(x=E-x,x>p&&a.sane){e.msg="invalid distance too far back",a.mode=30;break top}if(C=0,A=u,0===c){if(C+=l-x,x<w){w-=x;do k[s++]=u[C++];while(--x);C=s-E,A=k}}else if(c<x){if(C+=l+c-x,x-=c,x<w){w-=x;do k[s++]=u[C++];while(--x);if(C=0,c<w){x=c,w-=x;do k[s++]=u[C++];while(--x);C=s-E,A=k}}}else if(C+=c-x,x<w){w-=x;do k[s++]=u[C++];while(--x);C=s-E,A=k}for(;2<w;)k[s++]=A[C++],k[s++]=A[C++],k[s++]=A[C++],w-=3;w&&(k[s++]=A[C++],1<w&&(k[s++]=A[C++]))}else{C=s-E;do k[s++]=k[C++],k[s++]=k[C++],k[s++]=k[C++],w-=3;while(2<w);w&&(k[s++]=k[C++],1<w&&(k[s++]=k[C++]))}}else if(0==(64&x)){b=h[(65535&b)+(m&(1<<x)-1)];continue dodist}else{e.msg="invalid distance code",a.mode=30;break top}break}}else if(0==(64&x)){b=f[(65535&b)+(m&(1<<x)-1)];continue dolen}else if(32&x){a.mode=12;break top}else{e.msg="invalid literal/length code",a.mode=30;break top}break}}while(n<r&&s<o);return w=_>>3,n-=w,_-=w<<3,m&=(1<<_)-1,e.next_in=n,e.next_out=s,e.avail_in=n<r?5+(r-n):5-(n-r),e.avail_out=s<o?257+(o-s):257-(s-o),a.hold=m,void(a.bits=_)}},{}],48:[function(e,t,a){'use strict';function r(e){return(255&e>>>24)+(65280&e>>>8)+((65280&e)<<8)+((255&e)<<24)}function s(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new m.Buf16(320),this.work=new m.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function i(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new m.Buf32(852),t.distcode=t.distdyn=new m.Buf32(592),t.sane=1,t.back=-1,0):-2}function o(e){var t;return e&&e.state?(t=e.state,t.wsize=0,t.whave=0,t.wnext=0,i(e)):-2}function l(e,t){var a,n;return e&&e.state?(n=e.state,0>t?(a=0,t=-t):(a=(t>>4)+1,48>t&&(t&=15)),t&&(8>t||15<t))?-2:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=a,n.wbits=t,o(e)):-2}function p(e,t){var a,n;return e?(n=new s,e.state=n,n.window=null,a=l(e,t),0!==a&&(e.state=null),a):-2}function c(e){if(y){var t;for(b=new m.Buf32(512),x=new m.Buf32(32),t=0;144>t;)e.lens[t++]=8;for(;256>t;)e.lens[t++]=9;for(;280>t;)e.lens[t++]=7;for(;288>t;)e.lens[t++]=8;for(g(1,e.lens,0,288,b,0,e.work,{bits:9}),t=0;32>t;)e.lens[t++]=5;g(2,e.lens,0,32,x,0,e.work,{bits:5}),y=!1}e.lencode=b,e.lenbits=9,e.distcode=x,e.distbits=5}function u(e,t,a,n){var r=e.state,s;return null===r.window&&(r.wsize=1<<r.wbits,r.wnext=0,r.whave=0,r.window=new m.Buf8(r.wsize)),n>=r.wsize?(m.arraySet(r.window,t,a-r.wsize,r.wsize,0),r.wnext=0,r.whave=r.wsize):(s=r.wsize-r.wnext,s>n&&(s=n),m.arraySet(r.window,t,a-n,s,r.wnext),n-=s,n?(m.arraySet(r.window,t,a-n,n,0),r.wnext=n,r.whave=r.wsize):(r.wnext+=s,r.wnext===r.wsize&&(r.wnext=0),r.whave<r.wsize&&(r.whave+=s))),0}var m=e("../utils/common"),_=e("./adler32"),f=e("./crc32"),h=e("./inffast"),g=e("./inftrees"),y=!0,b,x;a.inflateReset=o,a.inflateReset2=l,a.inflateResetKeep=i,a.inflateInit=function(e){return p(e,15)},a.inflateInit2=p,a.inflate=function(e,t){var a=0,s=new m.Buf8(4),i=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],o,l,p,y,b,x,w,E,C,A,S,k,v,I,R,O,z,L,T,B,P,N,D,j;if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return-2;o=e.state,12===o.mode&&(o.mode=13),b=e.next_out,p=e.output,w=e.avail_out,y=e.next_in,l=e.input,x=e.avail_in,E=o.hold,C=o.bits,A=x,S=w,N=0;inf_leave:for(;;)switch(o.mode){case 1:if(0===o.wrap){o.mode=13;break}for(;16>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(2&o.wrap&&35615===E){o.check=0,s[0]=255&E,s[1]=255&E>>>8,o.check=f(o.check,s,2,0),E=0,C=0,o.mode=2;break}if(o.flags=0,o.head&&(o.head.done=!1),!(1&o.wrap)||(((255&E)<<8)+(E>>8))%31){e.msg="incorrect header check",o.mode=30;break}if(8!==(15&E)){e.msg="unknown compression method",o.mode=30;break}if(E>>>=4,C-=4,P=(15&E)+8,0===o.wbits)o.wbits=P;else if(P>o.wbits){e.msg="invalid window size",o.mode=30;break}o.dmax=1<<P,e.adler=o.check=1,o.mode=512&E?10:12,E=0,C=0;break;case 2:for(;16>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(o.flags=E,8!==(255&o.flags)){e.msg="unknown compression method",o.mode=30;break}if(57344&o.flags){e.msg="unknown header flags set",o.mode=30;break}o.head&&(o.head.text=1&E>>8),512&o.flags&&(s[0]=255&E,s[1]=255&E>>>8,o.check=f(o.check,s,2,0)),E=0,C=0,o.mode=3;case 3:for(;32>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.head&&(o.head.time=E),512&o.flags&&(s[0]=255&E,s[1]=255&E>>>8,s[2]=255&E>>>16,s[3]=255&E>>>24,o.check=f(o.check,s,4,0)),E=0,C=0,o.mode=4;case 4:for(;16>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.head&&(o.head.xflags=255&E,o.head.os=E>>8),512&o.flags&&(s[0]=255&E,s[1]=255&E>>>8,o.check=f(o.check,s,2,0)),E=0,C=0,o.mode=5;case 5:if(1024&o.flags){for(;16>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.length=E,o.head&&(o.head.extra_len=E),512&o.flags&&(s[0]=255&E,s[1]=255&E>>>8,o.check=f(o.check,s,2,0)),E=0,C=0}else o.head&&(o.head.extra=null);o.mode=6;case 6:if(1024&o.flags&&(k=o.length,k>x&&(k=x),k&&(o.head&&(P=o.head.extra_len-o.length,!o.head.extra&&(o.head.extra=Array(o.head.extra_len)),m.arraySet(o.head.extra,l,y,k,P)),512&o.flags&&(o.check=f(o.check,l,k,y)),x-=k,y+=k,o.length-=k),o.length))break inf_leave;o.length=0,o.mode=7;case 7:if(2048&o.flags){if(0===x)break inf_leave;k=0;do P=l[y+k++],o.head&&P&&65536>o.length&&(o.head.name+=d(P));while(P&&k<x);if(512&o.flags&&(o.check=f(o.check,l,k,y)),x-=k,y+=k,P)break inf_leave}else o.head&&(o.head.name=null);o.length=0,o.mode=8;case 8:if(4096&o.flags){if(0===x)break inf_leave;k=0;do P=l[y+k++],o.head&&P&&65536>o.length&&(o.head.comment+=d(P));while(P&&k<x);if(512&o.flags&&(o.check=f(o.check,l,k,y)),x-=k,y+=k,P)break inf_leave}else o.head&&(o.head.comment=null);o.mode=9;case 9:if(512&o.flags){for(;16>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(E!==(65535&o.check)){e.msg="header crc mismatch",o.mode=30;break}E=0,C=0}o.head&&(o.head.hcrc=1&o.flags>>9,o.head.done=!0),e.adler=o.check=0,o.mode=12;break;case 10:for(;32>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}e.adler=o.check=r(E),E=0,C=0,o.mode=11;case 11:if(0===o.havedict)return e.next_out=b,e.avail_out=w,e.next_in=y,e.avail_in=x,o.hold=E,o.bits=C,2;e.adler=o.check=1,o.mode=12;case 12:if(5===t||6===t)break inf_leave;case 13:if(o.last){E>>>=7&C,C-=7&C,o.mode=27;break}for(;3>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}switch(o.last=1&E,E>>>=1,C-=1,3&E){case 0:o.mode=14;break;case 1:if(c(o),o.mode=20,6===t){E>>>=2,C-=2;break inf_leave}break;case 2:o.mode=17;break;case 3:e.msg="invalid block type",o.mode=30;}E>>>=2,C-=2;break;case 14:for(E>>>=7&C,C-=7&C;32>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if((65535&E)!=(65535^E>>>16)){e.msg="invalid stored block lengths",o.mode=30;break}if(o.length=65535&E,E=0,C=0,o.mode=15,6===t)break inf_leave;case 15:o.mode=16;case 16:if(k=o.length,k){if(k>x&&(k=x),k>w&&(k=w),0===k)break inf_leave;m.arraySet(p,l,y,k,b),x-=k,y+=k,w-=k,b+=k,o.length-=k;break}o.mode=12;break;case 17:for(;14>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(o.nlen=(31&E)+257,E>>>=5,C-=5,o.ndist=(31&E)+1,E>>>=5,C-=5,o.ncode=(15&E)+4,E>>>=4,C-=4,286<o.nlen||30<o.ndist){e.msg="too many length or distance symbols",o.mode=30;break}o.have=0,o.mode=18;case 18:for(;o.have<o.ncode;){for(;3>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.lens[i[o.have++]]=7&E,E>>>=3,C-=3}for(;19>o.have;)o.lens[i[o.have++]]=0;if(o.lencode=o.lendyn,o.lenbits=7,D={bits:o.lenbits},N=g(0,o.lens,0,19,o.lencode,0,o.work,D),o.lenbits=D.bits,N){e.msg="invalid code lengths set",o.mode=30;break}o.have=0,o.mode=19;case 19:for(;o.have<o.nlen+o.ndist;){for(;;){if(a=o.lencode[E&(1<<o.lenbits)-1],R=a>>>24,O=255&a>>>16,z=65535&a,R<=C)break;if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(16>z)E>>>=R,C-=R,o.lens[o.have++]=z;else{if(16===z){for(j=R+2;C<j;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(E>>>=R,C-=R,0===o.have){e.msg="invalid bit length repeat",o.mode=30;break}P=o.lens[o.have-1],k=3+(3&E),E>>>=2,C-=2}else if(17===z){for(j=R+3;C<j;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}E>>>=R,C-=R,P=0,k=3+(7&E),E>>>=3,C-=3}else{for(j=R+7;C<j;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}E>>>=R,C-=R,P=0,k=11+(127&E),E>>>=7,C-=7}if(o.have+k>o.nlen+o.ndist){e.msg="invalid bit length repeat",o.mode=30;break}for(;k--;)o.lens[o.have++]=P}}if(30===o.mode)break;if(0===o.lens[256]){e.msg="invalid code -- missing end-of-block",o.mode=30;break}if(o.lenbits=9,D={bits:o.lenbits},N=g(1,o.lens,0,o.nlen,o.lencode,0,o.work,D),o.lenbits=D.bits,N){e.msg="invalid literal/lengths set",o.mode=30;break}if(o.distbits=6,o.distcode=o.distdyn,D={bits:o.distbits},N=g(2,o.lens,o.nlen,o.ndist,o.distcode,0,o.work,D),o.distbits=D.bits,N){e.msg="invalid distances set",o.mode=30;break}if(o.mode=20,6===t)break inf_leave;case 20:o.mode=21;case 21:if(6<=x&&258<=w){e.next_out=b,e.avail_out=w,e.next_in=y,e.avail_in=x,o.hold=E,o.bits=C,h(e,S),b=e.next_out,p=e.output,w=e.avail_out,y=e.next_in,l=e.input,x=e.avail_in,E=o.hold,C=o.bits,12===o.mode&&(o.back=-1);break}for(o.back=0;;){if(a=o.lencode[E&(1<<o.lenbits)-1],R=a>>>24,O=255&a>>>16,z=65535&a,R<=C)break;if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(O&&0==(240&O)){for(L=R,T=O,B=z;;){if(a=o.lencode[B+((E&(1<<L+T)-1)>>L)],R=a>>>24,O=255&a>>>16,z=65535&a,L+R<=C)break;if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}E>>>=L,C-=L,o.back+=L}if(E>>>=R,C-=R,o.back+=R,o.length=z,0===O){o.mode=26;break}if(32&O){o.back=-1,o.mode=12;break}if(64&O){e.msg="invalid literal/length code",o.mode=30;break}o.extra=15&O,o.mode=22;case 22:if(o.extra){for(j=o.extra;C<j;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.length+=E&(1<<o.extra)-1,E>>>=o.extra,C-=o.extra,o.back+=o.extra}o.was=o.length,o.mode=23;case 23:for(;;){if(a=o.distcode[E&(1<<o.distbits)-1],R=a>>>24,O=255&a>>>16,z=65535&a,R<=C)break;if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(0==(240&O)){for(L=R,T=O,B=z;;){if(a=o.distcode[B+((E&(1<<L+T)-1)>>L)],R=a>>>24,O=255&a>>>16,z=65535&a,L+R<=C)break;if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}E>>>=L,C-=L,o.back+=L}if(E>>>=R,C-=R,o.back+=R,64&O){e.msg="invalid distance code",o.mode=30;break}o.offset=z,o.extra=15&O,o.mode=24;case 24:if(o.extra){for(j=o.extra;C<j;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}o.offset+=E&(1<<o.extra)-1,E>>>=o.extra,C-=o.extra,o.back+=o.extra}if(o.offset>o.dmax){e.msg="invalid distance too far back",o.mode=30;break}o.mode=25;case 25:if(0===w)break inf_leave;if(k=S-w,o.offset>k){if(k=o.offset-k,k>o.whave&&o.sane){e.msg="invalid distance too far back",o.mode=30;break}k>o.wnext?(k-=o.wnext,v=o.wsize-k):v=o.wnext-k,k>o.length&&(k=o.length),I=o.window}else I=p,v=b-o.offset,k=o.length;k>w&&(k=w),w-=k,o.length-=k;do p[b++]=I[v++];while(--k);0===o.length&&(o.mode=21);break;case 26:if(0===w)break inf_leave;p[b++]=o.length,w--,o.mode=21;break;case 27:if(o.wrap){for(;32>C;){if(0===x)break inf_leave;x--,E|=l[y++]<<C,C+=8}if(S-=w,e.total_out+=S,o.total+=S,S&&(e.adler=o.check=o.flags?f(o.check,p,S,b-S):_(o.check,p,S,b-S)),S=w,(o.flags?E:r(E))!==o.check){e.msg="incorrect data check",o.mode=30;break}E=0,C=0}o.mode=28;case 28:if(o.wrap&&o.flags){for(;32>C;){if(0===x)break inf_leave;x--,E+=l[y++]<<C,C+=8}if(E!==(4294967295&o.total)){e.msg="incorrect length check",o.mode=30;break}E=0,C=0}o.mode=29;case 29:N=1;break inf_leave;case 30:N=-3;break inf_leave;case 31:return-4;case 32:default:return-2;}return(e.next_out=b,e.avail_out=w,e.next_in=y,e.avail_in=x,o.hold=E,o.bits=C,(o.wsize||S!==e.avail_out&&30>o.mode&&(27>o.mode||4!==t))&&u(e,e.output,e.next_out,S-e.avail_out))?(o.mode=31,-4):(A-=e.avail_in,S-=e.avail_out,e.total_in+=A,e.total_out+=S,o.total+=S,o.wrap&&S&&(e.adler=o.check=o.flags?f(o.check,p,S,e.next_out-S):_(o.check,p,S,e.next_out-S)),e.data_type=o.bits+(o.last?64:0)+(12===o.mode?128:0)+(20===o.mode||15===o.mode?256:0),(0===A&&0===S||4===t)&&0===N&&(N=-5),N)},a.inflateEnd=function(e){if(!e||!e.state)return-2;var t=e.state;return t.window&&(t.window=null),e.state=null,0},a.inflateGetHeader=function(e,t){var a;return e&&e.state?(a=e.state,0==(2&a.wrap))?-2:(a.head=t,t.done=!1,0):-2},a.inflateSetDictionary=function(e,t){var a=t.length,n,r,s;return e&&e.state?(n=e.state,0!==n.wrap&&11!==n.mode)?-2:11===n.mode&&(r=1,r=_(r,t,a,0),r!==n.check)?-3:(s=u(e,t,a,a),s)?(n.mode=31,-4):(n.havedict=1,0):-2},a.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":40,"./adler32":42,"./crc32":44,"./inffast":47,"./inftrees":49}],49:[function(e,t){'use strict';var a=e("../utils/common"),n=15,r=852,s=592,i=0,o=1,d=2,l=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],p=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],c=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],u=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];t.exports=function(e,t,m,_,f,h,g,y){var b=y.bits,x=0,w=0,E=0,C=0,A=0,S=0,k=0,v=0,I=0,R=0,O=null,z=0,L=new a.Buf16(n+1),T=new a.Buf16(n+1),B=null,P=0,N,D,j,U,F,M,G,Z,Y;for(x=0;x<=n;x++)L[x]=0;for(w=0;w<_;w++)L[t[m+w]]++;for(A=b,C=n;1<=C&&0===L[C];C--);if(A>C&&(A=C),0===C)return f[h++]=20971520,f[h++]=20971520,y.bits=1,0;for(E=1;E<C&&0===L[E];E++);for(A<E&&(A=E),v=1,x=1;x<=n;x++)if(v<<=1,v-=L[x],0>v)return-1;if(0<v&&(e===i||1!==C))return-1;for(T[1]=0,x=1;x<n;x++)T[x+1]=T[x]+L[x];for(w=0;w<_;w++)0!==t[m+w]&&(g[T[t[m+w]]++]=w);if(e===i?(O=B=g,M=19):e===o?(O=l,z-=257,B=p,P-=257,M=256):(O=c,B=u,M=-1),R=0,w=0,x=E,F=h,S=A,k=0,j=-1,I=1<<A,U=I-1,e===o&&I>r||e===d&&I>s)return 1;for(;;){G=x-k,g[w]<M?(Z=0,Y=g[w]):g[w]>M?(Z=B[P+g[w]],Y=O[z+g[w]]):(Z=96,Y=0),N=1<<x-k,D=1<<S,E=D;do D-=N,f[F+(R>>k)+D]=0|(G<<24|Z<<16|Y);while(0!==D);for(N=1<<x-1;R&N;)N>>=1;if(0===N?R=0:(R&=N-1,R+=N),w++,0==--L[x]){if(x===C)break;x=t[m+g[w]]}if(x>A&&(R&U)!==j){for(0===k&&(k=A),F+=E,S=x-k,v=1<<S;S+k<C&&(v-=L[S+k],!(0>=v));)S++,v<<=1;if(I+=1<<S,e===o&&I>r||e===d&&I>s)return 1;j=R&U,f[j]=0|(A<<24|S<<16|F-h)}}return 0!==R&&(f[F+R]=0|(4194304|x-k<<24)),y.bits=A,0}},{"../utils/common":40}],50:[function(e,t){'use strict';t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],51:[function(e,t,a){'use strict';function n(e){for(var t=e.length;0<=--t;)e[t]=0}function r(e,t,a,n,r){this.static_tree=e,this.extra_bits=t,this.extra_base=a,this.elems=n,this.max_length=r,this.has_stree=e&&e.length}function i(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function o(e){return 256>e?M[e]:M[256+(e>>>7)]}function d(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=255&t>>>8}function l(e,t,a){e.bi_valid>16-a?(e.bi_buf|=65535&t<<e.bi_valid,d(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=a-16):(e.bi_buf|=65535&t<<e.bi_valid,e.bi_valid+=a)}function p(e,t,a){l(e,a[2*t],a[2*t+1])}function c(e,t){var a=0;do a|=1&e,e>>>=1,a<<=1;while(0<--t);return a>>>1}function u(e){16===e.bi_valid?(d(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):8<=e.bi_valid&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}function _(e,t){var a=t.dyn_tree,r=t.max_code,s=t.stat_desc.static_tree,i=t.stat_desc.has_stree,o=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,l=t.stat_desc.max_length,p=0,c,u,_,g,y,b;for(g=0;g<=15;g++)e.bl_count[g]=0;for(a[2*e.heap[e.heap_max]+1]=0,c=e.heap_max+1;573>c;c++)(u=e.heap[c],g=a[2*a[2*u+1]+1]+1,g>l&&(g=l,p++),a[2*u+1]=g,!(u>r))&&(e.bl_count[g]++,y=0,u>=d&&(y=o[u-d]),b=a[2*u],e.opt_len+=b*(g+y),i&&(e.static_len+=b*(s[2*u+1]+y)));if(0!==p){do{for(g=l-1;0===e.bl_count[g];)g--;e.bl_count[g]--,e.bl_count[g+1]+=2,e.bl_count[l]--,p-=2}while(0<p);for(g=l;0!==g;g--)for(u=e.bl_count[g];0!==u;)(_=e.heap[--c],!(_>r))&&(a[2*_+1]!==g&&(e.opt_len+=(g-a[2*_+1])*a[2*_],a[2*_+1]=g),u--)}}function f(e,t,a){var r=Array(16),s=0,i,o;for(i=1;i<=15;i++)r[i]=s=s+a[i-1]<<1;for(o=0;o<=t;o++){var d=e[2*o+1];0!==d&&(e[2*o]=c(r[d]++,d))}}function h(){var e=Array(16),t,a,s,i,o;for(s=0,i=0;i<28;i++)for(Z[i]=s,t=0;t<1<<P[i];t++)G[s++]=i;for(G[s-1]=i,o=0,i=0;16>i;i++)for(Y[i]=o,t=0;t<1<<N[i];t++)M[o++]=i;for(o>>=7;i<30;i++)for(Y[i]=o<<7,t=0;t<1<<N[i]-7;t++)M[256+o++]=i;for(a=0;a<=15;a++)e[a]=0;for(t=0;143>=t;)U[2*t+1]=8,t++,e[8]++;for(;255>=t;)U[2*t+1]=9,t++,e[9]++;for(;279>=t;)U[2*t+1]=7,t++,e[7]++;for(;287>=t;)U[2*t+1]=8,t++,e[8]++;for(f(U,287,e),t=0;t<30;t++)F[2*t+1]=5,F[2*t]=c(t,5);H=new r(U,P,257,286,15),K=new r(F,N,0,30,15),X=new r([],D,0,19,7)}function g(e){var t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function y(e){8<e.bi_valid?d(e,e.bi_buf):0<e.bi_valid&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function b(e,t,a,n){y(e),n&&(d(e,a),d(e,~a)),z.arraySet(e.pending_buf,e.window,t,a,e.pending),e.pending+=a}function x(e,t,a,n){var r=2*t,s=2*a;return e[r]<e[s]||e[r]===e[s]&&n[t]<=n[a]}function w(e,t,a){for(var n=e.heap[a],r=a<<1;r<=e.heap_len&&(r<e.heap_len&&x(t,e.heap[r+1],e.heap[r],e.depth)&&r++,!x(t,n,e.heap[r],e.depth));)e.heap[a]=e.heap[r],a=r,r<<=1;e.heap[a]=n}function E(e,t,a){var n=0,r,s,i,d;if(0!==e.last_lit)do r=e.pending_buf[e.d_buf+2*n]<<8|e.pending_buf[e.d_buf+2*n+1],s=e.pending_buf[e.l_buf+n],n++,0===r?p(e,s,t):(i=G[s],p(e,i+256+1,t),d=P[i],0!==d&&(s-=Z[i],l(e,s,d)),r--,i=o(r),p(e,i,a),d=N[i],0!==d&&(r-=Y[i],l(e,r,d)));while(n<e.last_lit);p(e,256,t)}function C(e,t){var a=t.dyn_tree,r=t.stat_desc.static_tree,s=t.stat_desc.has_stree,i=t.stat_desc.elems,o=-1,d,l,p;for(e.heap_len=0,e.heap_max=573,d=0;d<i;d++)0===a[2*d]?a[2*d+1]=0:(e.heap[++e.heap_len]=o=d,e.depth[d]=0);for(;2>e.heap_len;)p=e.heap[++e.heap_len]=2>o?++o:0,a[2*p]=1,e.depth[p]=0,e.opt_len--,s&&(e.static_len-=r[2*p+1]);for(t.max_code=o,d=e.heap_len>>1;1<=d;d--)w(e,a,d);p=i;do d=e.heap[1],e.heap[1]=e.heap[e.heap_len--],w(e,a,1),l=e.heap[1],e.heap[--e.heap_max]=d,e.heap[--e.heap_max]=l,a[2*p]=a[2*d]+a[2*l],e.depth[p]=(e.depth[d]>=e.depth[l]?e.depth[d]:e.depth[l])+1,a[2*d+1]=a[2*l+1]=p,e.heap[1]=p++,w(e,a,1);while(2<=e.heap_len);e.heap[--e.heap_max]=e.heap[1],_(e,t),f(a,o,e.bl_count)}function A(e,t,a){var r=-1,s=t[1],i=0,o=7,d=4,l,p;for(0===s&&(o=138,d=3),t[2*(a+1)+1]=65535,l=0;l<=a;l++){if(p=s,s=t[2*(l+1)+1],++i<o&&p===s)continue;else i<d?e.bl_tree[2*p]+=i:0===p?10>=i?e.bl_tree[34]++:e.bl_tree[36]++:(p!==r&&e.bl_tree[2*p]++,e.bl_tree[32]++);i=0,r=p,0===s?(o=138,d=3):p===s?(o=6,d=3):(o=7,d=4)}}function S(e,t,a){var r=-1,s=t[1],i=0,o=7,d=4,c,u;for(0===s&&(o=138,d=3),c=0;c<=a;c++){if(u=s,s=t[2*(c+1)+1],++i<o&&u===s)continue;else if(i<d)do p(e,u,e.bl_tree);while(0!=--i);else 0===u?10>=i?(p(e,17,e.bl_tree),l(e,i-3,3)):(p(e,18,e.bl_tree),l(e,i-11,7)):(u!==r&&(p(e,u,e.bl_tree),i--),p(e,16,e.bl_tree),l(e,i-3,2));i=0,r=u,0===s?(o=138,d=3):u===s?(o=6,d=3):(o=7,d=4)}}function k(e){var t;for(A(e,e.dyn_ltree,e.l_desc.max_code),A(e,e.dyn_dtree,e.d_desc.max_code),C(e,e.bl_desc),t=18;3<=t&&0===e.bl_tree[2*j[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}function v(e,t,a,n){var r;for(l(e,t-257,5),l(e,a-1,5),l(e,n-4,4),r=0;r<n;r++)l(e,e.bl_tree[2*j[r]+1],3);S(e,e.dyn_ltree,t-1),S(e,e.dyn_dtree,a-1)}function I(e){var t=4093624447,a;for(a=0;31>=a;a++,t>>>=1)if(1&t&&0!==e.dyn_ltree[2*a])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(a=32;a<256;a++)if(0!==e.dyn_ltree[2*a])return 1;return 0}function R(e){q||(h(),q=!0),e.l_desc=new i(e.dyn_ltree,H),e.d_desc=new i(e.dyn_dtree,K),e.bl_desc=new i(e.bl_tree,X),e.bi_buf=0,e.bi_valid=0,g(e)}function O(e,t,a,n){l(e,0+(n?1:0),3),b(e,t,a,!0)}var z=e("../utils/common"),L=29,T=256+1+L,B=30,P=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],N=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],D=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],j=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],U=Array(2*(T+2));n(U);var F=Array(2*B);n(F);var M=Array(512);n(M);var G=Array(258-3+1);n(G);var Z=Array(L);n(Z);var Y=Array(B);n(Y);var q=!1,H,K,X;a._tr_init=R,a._tr_stored_block=O,a._tr_flush_block=function(e,t,a,n){var r=0,s,i;0<e.level?(e.strm.data_type===2&&(e.strm.data_type=I(e)),C(e,e.l_desc),C(e,e.d_desc),r=k(e),s=e.opt_len+3+7>>>3,i=e.static_len+3+7>>>3,i<=s&&(s=i)):s=i=a+5,a+4<=s&&-1!==t?O(e,t,a,n):e.strategy===4||i===s?(l(e,2+(n?1:0),3),E(e,U,F)):(l(e,4+(n?1:0),3),v(e,e.l_desc.max_code+1,e.d_desc.max_code+1,r+1),E(e,e.dyn_ltree,e.dyn_dtree)),g(e),n&&y(e)},a._tr_tally=function(e,t,a){return e.pending_buf[e.d_buf+2*e.last_lit]=255&t>>>8,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&a,e.last_lit++,0===t?e.dyn_ltree[2*a]++:(e.matches++,t--,e.dyn_ltree[2*(G[a]+256+1)]++,e.dyn_dtree[2*o(t)]++),e.last_lit===e.lit_bufsize-1},a._tr_align=function(e){l(e,2,3),p(e,256,U),u(e)}},{"../utils/common":40}],52:[function(e,t){'use strict';t.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],53:[function(e,t){function a(e){var t=new r,a=t.write(e)+t.end();return a.replace(/\0/g,"").trim()}function n(t,r){if(!t)return a;try{new TextDecoder(t.trim())}catch(o){var i=s.exec(t);return i&&!r?n("windows-"+i[1],!0):a}return function(e){var a=new TextDecoder(t),n=a.decode(e,{stream:!0})+a.decode();return n.replace(/\0/g,"").trim()}}e("text-encoding-polyfill");var r=e("string_decoder").StringDecoder;t.exports=n;var s=/^(?:ASNI\s)?(\d+)$/m},{string_decoder:56,"text-encoding-polyfill":57}],54:[function(e,t){function a(e){var t={lastUpdated:new Date(e.readUInt8(1)+1900,e.readUInt8(2),e.readUInt8(3)),records:e.readUInt32LE(4),headerLen:e.readUInt16LE(8),recLen:e.readUInt16LE(10)};return t}function n(e,t,a){for(var n=[],r=32;r<t&&(n.push({name:a(e.slice(r,r+11)),dataType:d(e.readUInt8(r+11)),len:e.readUInt8(r+16),decimal:e.readUInt8(r+17)}),13!==e.readUInt8(r+32));)r+=32;return n}function r(e,t,a,n,r){var s=e.slice(t,t+a),i=r(s);return"N"===n||"F"===n||"O"===n?parseFloat(i,10):"D"===n?new Date(i.slice(0,4),parseInt(i.slice(4,6),10)-1,i.slice(6,8)):"L"===n?"y"===i.toLowerCase()||"t"===i.toLowerCase():i}function s(e,t,a,n){for(var s={},o=0,d=a.length,l,p;o<d;)p=a[o],l=r(e,t,p.len,p.dataType,n),t+=p.len,"undefined"!=typeof l&&(s[p.name]=l),o++;return s}var i=e("./decoder");t.exports=function(e,t){for(var r=i(t),o=a(e),d=n(e,o.headerLen-1,r),l=(d.length+1<<5)+2,p=o.recLen,c=o.records,u=[];c;)u.push(s(e,l,d,r)),l+=p,c--;return u}},{"./decoder":53}],55:[function(e,t,s){(function(e,a){"object"==typeof s&&"undefined"!=typeof t?t.exports=a():"function"==typeof p&&p.amd?p(a):e.proj4=a()})(this,function(){'use strict';var le=Math.asin,pe=Math.acos,ue=Math.atan2,me=Math.PI,_e=Math.atan,fe=Math.exp,he=Math.tan,ge=Math.sin,ye=Math.cos,be=Math.sqrt;function e(e,t){if(e[t])return e[t];for(var a=Object.keys(e),n=t.toLowerCase().replace(Pe,""),r=-1,s,o;++r<a.length;)if(s=a[r],o=s.toLowerCase().replace(Pe,""),o===n)return e[s]}function t(e){if("string"!=typeof e)throw new Error("not a string");this.text=e.trim(),this.level=0,this.place=0,this.root=null,this.stack=[],this.currentObject=null,this.state=1}function s(e){var a=new t(e);return a.output()}function p(e,t,a){Array.isArray(t)&&(a.unshift(t),t=null);var n=t?{}:e,r=a.reduce(function(e,t){return c(t,e),e},n);t&&(e[t]=r)}function c(e,t){if(!Array.isArray(e))return void(t[e]=!0);var a=e.shift();if("PARAMETER"===a&&(a=e.shift()),1===e.length)return Array.isArray(e[0])?(t[a]={},void c(e[0],t[a])):void(t[a]=e[0]);if(!e.length)return void(t[a]=!0);if("TOWGS84"===a)return void(t[a]=e);if("AXIS"===a)return a in t||(t[a]=[]),void t[a].push(e);Array.isArray(a)||(t[a]={});var n;switch(a){case"UNIT":case"PRIMEM":case"VERT_DATUM":return t[a]={name:e[0].toLowerCase(),convert:e[1]},void(3===e.length&&c(e[2],t[a]));case"SPHEROID":case"ELLIPSOID":return t[a]={name:e[0],a:e[1],rf:e[2]},void(4===e.length&&c(e[3],t[a]));case"PROJECTEDCRS":case"PROJCRS":case"GEOGCS":case"GEOCCS":case"PROJCS":case"LOCAL_CS":case"GEODCRS":case"GEODETICCRS":case"GEODETICDATUM":case"EDATUM":case"ENGINEERINGDATUM":case"VERT_CS":case"VERTCRS":case"VERTICALCRS":case"COMPD_CS":case"COMPOUNDCRS":case"ENGINEERINGCRS":case"ENGCRS":case"FITTED_CS":case"LOCAL_DATUM":case"DATUM":return e[0]=["name",e[0]],void p(t,a,e);default:for(n=-1;++n<e.length;)if(!Array.isArray(e[n]))return c(e,t[a]);return p(t,a,e);}}function u(e,t){var a=t[0],n=t[1];!(a in e)&&n in e&&(e[a]=e[n],3===t.length&&(e[a]=t[2](e[a])))}function m(e){return e*qe}function _(e){function t(t){var a=e.to_meter||1;return t*a}if("GEOGCS"===e.type?e.projName="longlat":"LOCAL_CS"===e.type?(e.projName="identity",e.local=!0):"object"==typeof e.PROJECTION?e.projName=Object.keys(e.PROJECTION)[0]:e.projName=e.PROJECTION,e.AXIS){for(var a="",n=0,r=e.AXIS.length;n<r;++n){var s=e.AXIS[n],o=s[0].toLowerCase();-1===o.indexOf("north")?-1===o.indexOf("south")?-1===o.indexOf("east")?-1!==o.indexOf("west")&&(a+="w"):a+="e":a+="s":a+="n"}2===a.length&&(a+="u"),3===a.length&&(e.axis=a)}e.UNIT&&(e.units=e.UNIT.name.toLowerCase(),"metre"===e.units&&(e.units="meter"),e.UNIT.convert&&("GEOGCS"===e.type?e.DATUM&&e.DATUM.SPHEROID&&(e.to_meter=e.UNIT.convert*e.DATUM.SPHEROID.a):e.to_meter=e.UNIT.convert));var d=e.GEOGCS;"GEOGCS"===e.type&&(d=e),d&&(e.datumCode=d.DATUM?d.DATUM.name.toLowerCase():d.name.toLowerCase(),"d_"===e.datumCode.slice(0,2)&&(e.datumCode=e.datumCode.slice(2)),("new_zealand_geodetic_datum_1949"===e.datumCode||"new_zealand_1949"===e.datumCode)&&(e.datumCode="nzgd49"),("wgs_1984"===e.datumCode||"world_geodetic_system_1984"===e.datumCode)&&("Mercator_Auxiliary_Sphere"===e.PROJECTION&&(e.sphere=!0),e.datumCode="wgs84"),"_ferro"===e.datumCode.slice(-6)&&(e.datumCode=e.datumCode.slice(0,-6)),"_jakarta"===e.datumCode.slice(-8)&&(e.datumCode=e.datumCode.slice(0,-8)),~e.datumCode.indexOf("belge")&&(e.datumCode="rnb72"),d.DATUM&&d.DATUM.SPHEROID&&(e.ellps=d.DATUM.SPHEROID.name.replace("_19","").replace(/[Cc]larke\_18/,"clrk"),"international"===e.ellps.toLowerCase().slice(0,13)&&(e.ellps="intl"),e.a=d.DATUM.SPHEROID.a,e.rf=parseFloat(d.DATUM.SPHEROID.rf,10)),d.DATUM&&d.DATUM.TOWGS84&&(e.datum_params=d.DATUM.TOWGS84),~e.datumCode.indexOf("osgb_1936")&&(e.datumCode="osgb36"),~e.datumCode.indexOf("osni_1952")&&(e.datumCode="osni52"),(~e.datumCode.indexOf("tm65")||~e.datumCode.indexOf("geodetic_datum_of_1965"))&&(e.datumCode="ire65"),"ch1903+"===e.datumCode&&(e.datumCode="ch1903"),~e.datumCode.indexOf("israel")&&(e.datumCode="isr93")),e.b&&!isFinite(e.b)&&(e.b=e.a);[["standard_parallel_1","Standard_Parallel_1"],["standard_parallel_2","Standard_Parallel_2"],["false_easting","False_Easting"],["false_northing","False_Northing"],["central_meridian","Central_Meridian"],["latitude_of_origin","Latitude_Of_Origin"],["latitude_of_origin","Central_Parallel"],["scale_factor","Scale_Factor"],["k0","scale_factor"],["latitude_of_center","Latitude_Of_Center"],["latitude_of_center","Latitude_of_center"],["lat0","latitude_of_center",m],["longitude_of_center","Longitude_Of_Center"],["longitude_of_center","Longitude_of_center"],["longc","longitude_of_center",m],["x0","false_easting",t],["y0","false_northing",t],["long0","central_meridian",m],["lat0","latitude_of_origin",m],["lat0","standard_parallel_1",m],["lat1","standard_parallel_1",m],["lat2","standard_parallel_2",m],["azimuth","Azimuth"],["alpha","azimuth",m],["srsCode","name"]].forEach(function(t){return u(e,t)}),!e.long0&&e.longc&&("Albers_Conic_Equal_Area"===e.projName||"Lambert_Azimuthal_Equal_Area"===e.projName)&&(e.long0=e.longc),!e.lat_ts&&e.lat1&&("Stereographic_South_Pole"===e.projName||"Polar Stereographic (variant B)"===e.projName)&&(e.lat0=m(0<e.lat1?90:-90),e.lat_ts=e.lat1)}function f(e){var t=this;if(2===arguments.length){var a=arguments[1];f[e]="string"==typeof a?"+"===a.charAt(0)?Ne(arguments[1]):He(arguments[1]):a}else if(1===arguments.length){if(Array.isArray(e))return e.map(function(e){Array.isArray(e)?f.apply(t,e):f(e)});if("string"!=typeof e)"EPSG"in e?f["EPSG:"+e.EPSG]=e:"ESRI"in e?f["ESRI:"+e.ESRI]=e:"IAU2000"in e?f["IAU2000:"+e.IAU2000]=e:console.log(e);else if(e in f)return f[e]}}function h(e){return"string"==typeof e}function g(e){return e in f}function y(e){return Ke.some(function(t){return-1<e.indexOf(t)})}function b(t){var a=e(t,"authority");if(a){var n=e(a,"epsg");return n&&-1<Xe.indexOf(n)}}function x(t){var a=e(t,"extension");return a?e(a,"proj4"):void 0}function w(e){return"+"===e[0]}function E(e){if(h(e)){if(g(e))return f[e];if(y(e)){var t=He(e);if(b(t))return f["EPSG:3857"];var a=x(t);return a?Ne(a):t}if(w(e))return Ne(e)}else return e}function C(){var e=this.b/this.a;this.es=1-e*e,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=be(this.es),this.lat_ts?this.sphere?this.k0=ye(this.lat_ts):this.k0=Qe(this.e,ge(this.lat_ts),ye(this.lat_ts)):!this.k0&&(this.k?this.k0=this.k:this.k0=1)}function A(e){return e}function S(e,t){var a=nt.length;return e.names?(nt[a]=e,e.names.forEach(function(e){at[e.toLowerCase()]=a}),this):(console.log(t),!0)}function k(t,n,r,s){var i=t*t,o=n*n,d=(i-o)/i,l=0;s?(t*=1-d*(Ae+d*(Se+d*ke)),i=t*t,d=0):l=be(d);var p=(i-o)/o;return{es:d,e:l,ep2:p}}function v(t,r,s,i,o){if(!t){var d=e(rt,i);d||(d=st),t=d.a,r=d.b,s=d.rf}return s&&!r&&(r=(1-1/s)*t),(0===s||n(t-r)<ve)&&(o=!0,r=t),{a:t,b:r,rf:s,sphere:o}}function I(e,t,n,a,r,s){var i={};return i.datum_type=void 0===e||"none"===e?5:4,t&&(i.datum_params=t.map(parseFloat),(0!==i.datum_params[0]||0!==i.datum_params[1]||0!==i.datum_params[2])&&(i.datum_type=1),3<i.datum_params.length&&(0!==i.datum_params[3]||0!==i.datum_params[4]||0!==i.datum_params[5]||0!==i.datum_params[6])&&(i.datum_type=2,i.datum_params[3]*=we,i.datum_params[4]*=we,i.datum_params[5]*=we,i.datum_params[6]=i.datum_params[6]/1e6+1)),i.a=n,i.b=a,i.es=r,i.ep2=s,i}function R(t,a){if(!(this instanceof R))return new R(t);a=a||function(e){if(e)throw e};var n=E(t);if("object"!=typeof n)return void a(t);var r=R.projections.get(n.projName);if(!r)return void a(t);if(n.datumCode&&"none"!==n.datumCode){var s=e(it,n.datumCode);s&&(n.datum_params=s.towgs84?s.towgs84.split(","):null,n.ellps=s.ellipse,n.datumName=s.datumName?s.datumName:n.datumCode)}n.k0=n.k0||1,n.axis=n.axis||"enu",n.ellps=n.ellps||"wgs84";var i=v(n.a,n.b,n.rf,n.ellps,n.sphere),o=k(i.a,i.b,i.rf,n.R_A),d=n.datum||I(n.datumCode,n.datum_params,i.a,i.b,o.es,o.ep2);We(this,n),We(this,r),this.a=i.a,this.b=i.b,this.rf=i.rf,this.sphere=i.sphere,this.es=o.es,this.e=o.e,this.ep2=o.ep2,this.datum=d,this.init(),a(null,this)}function O(e,t){return e.datum_type===t.datum_type&&!(e.a!==t.a||5e-11<n(e.es-t.es))&&(1===e.datum_type?e.datum_params[0]===t.datum_params[0]&&e.datum_params[1]===t.datum_params[1]&&e.datum_params[2]===t.datum_params[2]:2!==e.datum_type||e.datum_params[0]===t.datum_params[0]&&e.datum_params[1]===t.datum_params[1]&&e.datum_params[2]===t.datum_params[2]&&e.datum_params[3]===t.datum_params[3]&&e.datum_params[4]===t.datum_params[4]&&e.datum_params[5]===t.datum_params[5]&&e.datum_params[6]===t.datum_params[6])}function z(e,t,n){var a=e.x,r=e.y,s=e.z?e.z:0,i,o,d,l;if(r<-Ce&&r>-1.001*Ce)r=-Ce;else if(r>Ce&&r<1.001*Ce)r=Ce;else{if(r<-Ce)return{x:-Infinity,y:-Infinity,z:e.z};if(r>Ce)return{x:1/0,y:1/0,z:e.z}}return a>me&&(a-=2*me),o=ge(r),l=ye(r),d=o*o,i=n/be(1-t*d),{x:(i+s)*l*ye(a),y:(i+s)*l*ge(a),z:(i*(1-t)+s)*o}}function L(e,t,r,a){var s=1e-12,i=e.x,o=e.y,d=e.z?e.z:0,l,p,c,u,m,_,f,h,g,y,b,x,w,E,C,A;if(l=be(i*i+o*o),p=be(i*i+o*o+d*d),!(l/r<s))E=ue(o,i);else if(E=0,p/r<s)return C=Ce,A=-a,{x:e.x,y:e.y,z:e.z};c=d/p,u=l/p,m=1/be(1-t*(2-t)*u*u),h=u*(1-t)*m,g=c*m,w=0;do w++,f=r/be(1-t*g*g),A=l*h+d*g-f*(1-t*g*g),_=t*f/(f+A),m=1/be(1-_*(2-_)*u*u),y=u*(1-_)*m,b=c*m,x=b*h-y*g,h=y,g=b;while(x*x>s*s&&w<30);return C=_e(b/n(y)),{x:E,y:C,z:A}}function T(e,t,a){if(1===t)return{x:e.x+a[0],y:e.y+a[1],z:e.z+a[2]};if(2===t){var n=a[0],r=a[1],s=a[2],i=a[3],o=a[4],d=a[5],l=a[6];return{x:l*(e.x-d*e.y+o*e.z)+n,y:l*(d*e.x+e.y-i*e.z)+r,z:l*(-o*e.x+i*e.y+e.z)+s}}}function B(e,t,a){if(1===t)return{x:e.x-a[0],y:e.y-a[1],z:e.z-a[2]};if(2===t){var n=a[0],r=a[1],s=a[2],i=a[3],o=a[4],d=a[5],l=a[6],p=(e.x-n)/l,c=(e.y-r)/l,u=(e.z-s)/l;return{x:p+d*c-o*u,y:-d*p+c+i*u,z:o*p-i*c+u}}}function P(e){return 1===e||2===e}function N(e){var t=Number.isFinite;if("function"==typeof t){if(t(e))return;throw new TypeError("coordinates must be finite numbers")}if("number"!=typeof e||e!==e||!isFinite(e))throw new TypeError("coordinates must be finite numbers")}function D(e,t){return(1===e.datum.datum_type||2===e.datum.datum_type)&&"WGS84"!==t.datumCode||(1===t.datum.datum_type||2===t.datum.datum_type)&&"WGS84"!==e.datumCode}function j(e,t,a){var n;return Array.isArray(a)&&(a=lt(a)),pt(a),e.datum&&t.datum&&D(e,t)&&(n=new R("WGS84"),a=j(e,n,a),e=n),"enu"!==e.axis&&(a=dt(e,!1,a)),"longlat"===e.projName?a={x:a.x*Ie,y:a.y*Ie,z:a.z||0}:(e.to_meter&&(a={x:a.x*e.to_meter,y:a.y*e.to_meter,z:a.z||0}),a=e.inverse(a)),e.from_greenwich&&(a.x+=e.from_greenwich),a=ot(e.datum,t.datum,a),t.from_greenwich&&(a={x:a.x-t.from_greenwich,y:a.y,z:a.z||0}),"longlat"===t.projName?a={x:a.x*Re,y:a.y*Re,z:a.z||0}:(a=t.forward(a),t.to_meter&&(a={x:a.x/t.to_meter,y:a.y/t.to_meter,z:a.z||0})),"enu"===t.axis?a:dt(t,!0,a)}function U(e,t,a){var n,r,s;return Array.isArray(a)?(n=j(e,t,a)||{x:NaN,y:NaN},2<a.length?"undefined"!=typeof e.name&&"geocent"===e.name||"undefined"!=typeof t.name&&"geocent"===t.name?"number"==typeof n.z?[n.x,n.y,n.z].concat(a.splice(3)):[n.x,n.y,a[2]].concat(a.splice(3)):[n.x,n.y].concat(a.splice(2)):[n.x,n.y]):(r=j(e,t,a),s=Object.keys(a),2===s.length)?r:(s.forEach(function(n){if("undefined"!=typeof e.name&&"geocent"===e.name||"undefined"!=typeof t.name&&"geocent"===t.name){if("x"===n||"y"===n||"z"===n)return;}else if("x"===n||"y"===n)return;r[n]=a[n]}),r)}function F(e){return e instanceof R?e:e.oProj?e.oProj:R(e)}function M(e,t,a){e=F(e);var n=!1,r;return"undefined"==typeof t?(t=e,e=ct,n=!0):("undefined"!=typeof t.x||Array.isArray(t))&&(a=t,t=e,e=ct,n=!0),t=F(t),a?U(e,t,a):(r={forward:function(a){return U(e,t,a)},inverse:function(a){return U(t,e,a)}},n&&(r.oProj=t),r)}function G(e,t){return t=t||5,W(H({lat:e[1],lon:e[0]}),t)}function Z(e){var t=K($(e.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat]:[(t.left+t.right)/2,(t.top+t.bottom)/2]}function Y(e){return e*(me/180)}function q(e){return 180*(e/me)}function H(e){var t=Math.round,n=e.lat,s=e.lon,i=6378137,a=.00669438,o=.9996,d=Y(n),l=Y(s),p,c,u,m,_,f,h,g,y;y=r((s+180)/6)+1,180===s&&(y=60),56<=n&&64>n&&3<=s&&12>s&&(y=32),72<=n&&84>n&&(0<=s&&9>s?y=31:9<=s&&21>s?y=33:21<=s&&33>s?y=35:33<=s&&42>s&&(y=37)),p=6*(y-1)-180+3,g=Y(p),c=a/(1-a),u=i/be(1-a*ge(d)*ge(d)),m=he(d)*he(d),_=c*ye(d)*ye(d),f=ye(d)*(l-g),h=i*((1-a/4-3*a*a/64-5*a*a*a/256)*d-(3*a/8+3*a*a/32+45*a*a*a/1024)*ge(2*d)+(15*a*a/256+45*a*a*a/1024)*ge(4*d)-35*a*a*a/3072*ge(6*d));var b=o*u*(65+65*(65*(65*(1-m+_)))/6+65*(65*(65*(65*(65*(5-18*m+m*m+72*_-58*c)))))/120)+5e5,x=o*(h+u*he(d)*(4225/2+65*(65*(65*(65*(5-m+9*_+4*_*_))))/24+65*(65*(65*(65*(65*(65*(61-58*m+m*m+600*_-330*c))))))/720));return 0>n&&(x+=1e7),{northing:t(x),easting:t(b),zoneNumber:y,zoneLetter:X(n)}}function K(e){var t=e.northing,n=e.easting,r=e.zoneLetter,s=e.zoneNumber;if(0>s||60<s)return null;var i=.9996,d=6378137,a=.00669438,l=(1-be(1-a))/(1+be(1-a)),p=t,c,u,m,_,f,h,g,b,x,w;"N">r&&(p-=1e7),b=6*(s-1)-180+3,c=a/(1-a),g=p/i,x=g/(d*(1-a/4-3*a*a/64-5*a*a*a/256)),w=x+(3*l/2-27*l*l*l/32)*ge(2*x)+(21*l*l/16-55*l*l*l*l/32)*ge(4*x)+151*l*l*l/96*ge(6*x),u=d/be(1-a*ge(w)*ge(w)),m=he(w)*he(w),_=c*ye(w)*ye(w),f=d*(1-a)/o(1-a*ge(w)*ge(w),1.5),h=(n-5e5)/(u*i);var E=w-u*he(w)/f*(h*h/2-(5+3*m+10*_-4*_*_-9*c)*h*h*h*h/24+(61+90*m+298*_+45*m*m-252*c-3*_*_)*h*h*h*h*h*h/720);E=q(E);var C=(h-(1+2*m+_)*h*h*h/6+(5-2*_+28*m-3*_*_+8*c+24*m*m)*h*h*h*h*h/120)/ye(w);C=b+q(C);var A;if(e.accuracy){var S=K({northing:e.northing+e.accuracy,easting:e.easting+e.accuracy,zoneLetter:e.zoneLetter,zoneNumber:e.zoneNumber});A={top:S.lat,right:S.lon,bottom:E,left:C}}else A={lat:E,lon:C};return A}function X(e){var t="Z";return 84>=e&&72<=e?t="X":72>e&&64<=e?t="W":64>e&&56<=e?t="V":56>e&&48<=e?t="U":48>e&&40<=e?t="T":40>e&&32<=e?t="S":32>e&&24<=e?t="R":24>e&&16<=e?t="Q":16>e&&8<=e?t="P":8>e&&0<=e?t="N":0>e&&-8<=e?t="M":-8>e&&-16<=e?t="L":-16>e&&-24<=e?t="K":-24>e&&-32<=e?t="J":-32>e&&-40<=e?t="H":-40>e&&-48<=e?t="G":-48>e&&-56<=e?t="F":-56>e&&-64<=e?t="E":-64>e&&-72<=e?t="D":-72>e&&-80<=e&&(t="C"),t}function W(e,t){var a="00000"+e.easting,n="00000"+e.northing;return e.zoneNumber+e.zoneLetter+Q(e.easting,e.northing,e.zoneNumber)+a.substr(a.length-5,t)+n.substr(n.length-5,t)}function Q(e,t,a){var n=J(a),s=r(e/1e5),i=r(t/1e5)%20;return V(s,i,n)}function J(e){var t=e%6;return 0===t&&(t=6),t}function V(e,t,a){var n=a-1,r="AJSAJS".charCodeAt(n),s="AFAFAF".charCodeAt(n),i=r+e-1,o=s+t,l=!1;90<i&&(i=i-90+65-1,l=!0),(73===i||73>r&&73<i||(73<i||73>r)&&l)&&i++,(79===i||79>r&&79<i||(79<i||79>r)&&l)&&(i++,73===i&&i++),90<i&&(i=i-90+65-1),86<o?(o=o-86+65-1,l=!0):l=!1,(73===o||73>s&&73<o||(73<o||73>s)&&l)&&o++,(79===o||79>s&&79<o||(79<o||79>s)&&l)&&(o++,73===o&&o++),86<o&&(o=o-86+65-1);var p=d(i)+d(o);return p}function $(e){if(e&&0===e.length)throw"MGRSPoint coverting from nothing";for(var t=e.length,a=null,n="",r=0,s;!/[A-Z]/.test(s=e.charAt(r));){if(2<=r)throw"MGRSPoint bad conversion from: "+e;n+=s,r++}var d=parseInt(n,10);if(0===r||r+3>t)throw"MGRSPoint bad conversion from: "+e;var l=e.charAt(r++);if("A">=l||"B"===l||"Y"===l||"Z"<=l||"I"===l||"O"===l)throw"MGRSPoint zone letter "+l+" not handled: "+e;a=e.substring(r,r+=2);for(var p=J(d),c=ee(a.charAt(0),p),u=te(a.charAt(1),p);u<ae(l);)u+=2e6;var m=t-r;if(0!=m%2)throw"MGRSPoint has to have an even number \nof digits after the zone letter and two 100km letters - front \nhalf for easting meters, second half for \nnorthing meters"+e;var _=m/2,f=0,h=0,g,y,b,x,w;return 0<_&&(g=1e5/o(10,_),y=e.substring(r,r+_),f=parseFloat(y)*g,b=e.substring(r+_),h=parseFloat(b)*g),x=f+c,w=h+u,{easting:x,northing:w,zoneLetter:l,zoneNumber:d,accuracy:g}}function ee(t,e){for(var a="AJSAJS".charCodeAt(e-1),n=1e5,r=!1;a!==t.charCodeAt(0);){if(a++,73===a&&a++,79===a&&a++,90<a){if(r)throw"Bad character: "+t;a=65,r=!0}n+=1e5}return n}function te(e,t){if("V"<e)throw"MGRSPoint given invalid Northing "+e;for(var a="AFAFAF".charCodeAt(t-1),n=0,r=!1;a!==e.charCodeAt(0);){if(a++,73===a&&a++,79===a&&a++,86<a){if(r)throw"Bad character: "+e;a=65,r=!0}n+=1e5}return n}function ae(e){var t;if(t="C"===e?11e5:"D"===e?2e6:"E"===e?28e5:"F"===e?37e5:"G"===e?46e5:"H"===e?55e5:"J"===e?64e5:"K"===e?73e5:"L"===e?82e5:"M"===e?91e5:"N"===e?0:"P"===e?8e5:"Q"===e?17e5:"R"===e?26e5:"S"===e?35e5:"T"===e?44e5:"U"===e?53e5:"V"===e?62e5:"W"===e?7e6:"X"===e?79e5:-1,0<=t)return t;throw"Invalid zone letter: "+e}function ne(e,t,a){if(!(this instanceof ne))return new ne(e,t,a);if(Array.isArray(e))this.x=e[0],this.y=e[1],this.z=e[2]||0;else if("object"==typeof e)this.x=e.x,this.y=e.y,this.z=e.z||0;else if("string"==typeof e&&"undefined"==typeof t){var n=e.split(",");this.x=parseFloat(n[0],10),this.y=parseFloat(n[1],10),this.z=parseFloat(n[2],10)||0}else this.x=e,this.y=t,this.z=a||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}function re(e){var a=[],n;return a[0]=e*qt,n=e*e,a[0]+=n*Ht,a[1]=n*Xt,n*=e,a[0]+=n*Kt,a[1]+=n*Wt,a[2]=n*Qt,a}function se(e,a){var n=e+e;return e+a[0]*ge(n)+a[1]*ge(n+n)+a[2]*ge(n+n+n)}function ie(e,t,a,r){var s;return e<ve?(r.value=_a.AREA_0,s=0):(s=ue(t,a),n(s)<=Oe?r.value=_a.AREA_0:s>Oe&&s<=Ce+Oe?(r.value=_a.AREA_1,s-=Ce):s>Ce+Oe||s<=-(Ce+Oe)?(r.value=_a.AREA_2,s=0<=s?s-Le:s+Le):(r.value=_a.AREA_3,s+=Ce)),s}function oe(e,t){var a=e+t;return a<-Le?a+=ze:a>+Le&&(a-=ze),a}function de(e,t,a,r){for(var s=t,i;r&&(i=e(s),s-=i,!(n(i)<a));--r);return s}var xe=5,we=484813681109536e-20,Ce=me/2,Ae=.16666666666666666,Se=.04722222222222222,ke=.022156084656084655,ve=1e-10,Ie=.017453292519943295,Re=57.29577951308232,Oe=me/4,ze=2*me,Le=3.14159265359,Te={};Te.greenwich=0,Te.lisbon=-9.131906111111,Te.paris=2.337229166667,Te.bogota=-74.080916666667,Te.madrid=-3.687938888889,Te.rome=12.452333333333,Te.bern=7.439583333333,Te.jakarta=106.807719444444,Te.ferro=-17.666666666667,Te.brussels=4.367975,Te.stockholm=18.058277777778,Te.athens=23.7163375,Te.oslo=10.722916666667;var Be={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}},Pe=/[\s_\-\/\(\)]/g,Ne=function(t){var a={},n=t.split("+").map(function(e){return e.trim()}).filter(function(e){return e}).reduce(function(e,t){var a=t.split("=");return a.push(!0),e[a[0].toLowerCase()]=a[1],e},{}),r={proj:"projName",datum:"datumCode",rf:function(e){a.rf=parseFloat(e)},lat_0:function(e){a.lat0=e*Ie},lat_1:function(e){a.lat1=e*Ie},lat_2:function(e){a.lat2=e*Ie},lat_ts:function(e){a.lat_ts=e*Ie},lon_0:function(e){a.long0=e*Ie},lon_1:function(e){a.long1=e*Ie},lon_2:function(e){a.long2=e*Ie},alpha:function(e){a.alpha=parseFloat(e)*Ie},lonc:function(e){a.longc=e*Ie},x_0:function(e){a.x0=parseFloat(e)},y_0:function(e){a.y0=parseFloat(e)},k_0:function(e){a.k0=parseFloat(e)},k:function(e){a.k0=parseFloat(e)},a:function(e){a.a=parseFloat(e)},b:function(e){a.b=parseFloat(e)},r_a:function(){a.R_A=!0},zone:function(e){a.zone=parseInt(e,10)},south:function(){a.utmSouth=!0},towgs84:function(e){a.datum_params=e.split(",").map(function(e){return parseFloat(e)})},to_meter:function(e){a.to_meter=parseFloat(e)},units:function(t){a.units=t;var n=e(Be,t);n&&(a.to_meter=n.to_meter)},from_greenwich:function(e){a.from_greenwich=e*Ie},pm:function(t){var n=e(Te,t);a.from_greenwich=(n?n:parseFloat(t))*Ie},nadgrids:function(e){"@null"===e?a.datumCode="none":a.nadgrids=e},axis:function(e){3===e.length&&-1!=="ewnsud".indexOf(e.substr(0,1))&&-1!=="ewnsud".indexOf(e.substr(1,1))&&-1!=="ewnsud".indexOf(e.substr(2,1))&&(a.axis=e)}},s,i,o;for(s in n)i=n[s],s in r?(o=r[s],"function"==typeof o?o(i):a[o]=i):a[s]=i;return"string"==typeof a.datumCode&&"WGS84"!==a.datumCode&&(a.datumCode=a.datumCode.toLowerCase()),a},De=1,je=2,Ue=3,Fe=4,Me=5,Ge=-1,Ze=/[,\]]/,Ye=/[\d\.E\-\+]/;t.prototype.readCharicter=function(){var e=this.text[this.place++];if(this.state!==Fe)for(;/\s/.test(e);){if(this.place>=this.text.length)return;e=this.text[this.place++]}switch(this.state){case De:return this.neutral(e);case je:return this.keyword(e);case Fe:return this.quoted(e);case Me:return this.afterquote(e);case Ue:return this.number(e);case Ge:}},t.prototype.afterquote=function(e){if("\""===e)return this.word+="\"",void(this.state=Fe);if(Ze.test(e))return this.word=this.word.trim(),void this.afterItem(e);throw new Error("havn't handled \""+e+"\" in afterquote yet, index "+this.place)},t.prototype.afterItem=function(e){return","===e?(null!==this.word&&this.currentObject.push(this.word),this.word=null,void(this.state=De)):"]"===e?(this.level--,null!==this.word&&(this.currentObject.push(this.word),this.word=null),this.state=De,this.currentObject=this.stack.pop(),void(this.currentObject||(this.state=Ge))):void 0},t.prototype.number=function(e){if(Ye.test(e))return void(this.word+=e);if(Ze.test(e))return this.word=parseFloat(this.word),void this.afterItem(e);throw new Error("havn't handled \""+e+"\" in number yet, index "+this.place)},t.prototype.quoted=function(e){return"\""===e?void(this.state=Me):void(this.word+=e)},t.prototype.keyword=function(e){if(/[A-Za-z84]/.test(e))return void(this.word+=e);if("["===e){var t=[];return t.push(this.word),this.level++,null===this.root?this.root=t:this.currentObject.push(t),this.stack.push(this.currentObject),this.currentObject=t,void(this.state=De)}if(Ze.test(e))return void this.afterItem(e);throw new Error("havn't handled \""+e+"\" in keyword yet, index "+this.place)},t.prototype.neutral=function(e){if(/[A-Za-z]/.test(e))return this.word=e,void(this.state=je);if("\""===e)return this.word="",void(this.state=Fe);if(Ye.test(e))return this.word=e,void(this.state=Ue);if(Ze.test(e))return void this.afterItem(e);throw new Error("havn't handled \""+e+"\" in neutral yet, index "+this.place)},t.prototype.output=function(){for(;this.place<this.text.length;)this.readCharicter();if(this.state===Ge)return this.root;throw new Error("unable to parse string \""+this.text+"\". State is "+this.state)};var qe=.017453292519943295,He=function(e){var t=s(e),a=t.shift(),n=t.shift();t.unshift(["name",n]),t.unshift(["type",a]);var r={};return c(t,r),_(r),r};(function(e){e("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),e("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),e("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),e.WGS84=e["EPSG:4326"],e["EPSG:3785"]=e["EPSG:3857"],e.GOOGLE=e["EPSG:3857"],e["EPSG:900913"]=e["EPSG:3857"],e["EPSG:102113"]=e["EPSG:3857"]})(f);var Ke=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"],Xe=["3857","900913","3785","102113"],We=function(e,t){e=e||{};var a,n;if(!t)return e;for(n in t)a=t[n],void 0!==a&&(e[n]=a);return e},Qe=function(e,t,a){var n=e*t;return a/be(1-n*n)},Je=function(e){return 0>e?-1:1},Ve=function(e){return n(e)<=Le?e:e-Je(e)*ze},$e=function(e,t,a){var n=e*a;return n=o((1-n)/(1+n),.5*e),he(.5*(Ce-t))/n},et=function(e,t){for(var a=Ce-2*_e(t),r=0,s,d;15>=r;r++)if(s=e*ge(a),d=Ce-2*_e(t*o((1-s)/(1+s),.5*e))-a,a+=d,1e-10>=n(d))return a;return-9999},tt=[{init:C,forward:function(e){var t=e.x,r=e.y;if(90<r*Re&&-90>r*Re&&180<t*Re&&-180>t*Re)return null;var s,i;if(n(n(r)-Ce)<=ve)return null;if(this.sphere)s=this.x0+this.a*this.k0*Ve(t-this.long0),i=this.y0+this.a*this.k0*a(he(Oe+.5*r));else{var o=ge(r),d=$e(this.e,r,o);s=this.x0+this.a*this.k0*Ve(t-this.long0),i=this.y0-this.a*this.k0*a(d)}return e.x=s,e.y=i,e},inverse:function(e){var t=e.x-this.x0,a=e.y-this.y0,n,r;if(this.sphere)r=Ce-2*_e(fe(-a/(this.a*this.k0)));else{var s=fe(-a/(this.a*this.k0));if(r=et(this.e,s),-9999===r)return null}return n=Ve(this.long0+t/(this.a*this.k0)),e.x=n,e.y=r,e},names:["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"]},{init:function(){},forward:A,inverse:A,names:["longlat","identity"]}],at={},nt=[],rt={};rt.MERIT={a:6378137,rf:298.257,ellipseName:"MERIT 1983"},rt.SGS85={a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"},rt.GRS80={a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"},rt.IAU76={a:6378140,rf:298.257,ellipseName:"IAU 1976"},rt.airy={a:6377563.396,b:6356256.91,ellipseName:"Airy 1830"},rt.APL4={a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"},rt.NWL9D={a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"},rt.mod_airy={a:6377340.189,b:6356034.446,ellipseName:"Modified Airy"},rt.andrae={a:6377104.43,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"},rt.aust_SA={a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"},rt.GRS67={a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"},rt.bessel={a:6377397.155,rf:299.1528128,ellipseName:"Bessel 1841"},rt.bess_nam={a:6377483.865,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"},rt.clrk66={a:6378206.4,b:6356583.8,ellipseName:"Clarke 1866"},rt.clrk80={a:6378249.145,rf:293.4663,ellipseName:"Clarke 1880 mod."},rt.clrk58={a:6378293.645208759,rf:294.2606763692654,ellipseName:"Clarke 1858"},rt.CPM={a:6375738.7,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"},rt.delmbr={a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"},rt.engelis={a:6378136.05,rf:298.2566,ellipseName:"Engelis 1985"},rt.evrst30={a:6377276.345,rf:300.8017,ellipseName:"Everest 1830"},rt.evrst48={a:6377304.063,rf:300.8017,ellipseName:"Everest 1948"},rt.evrst56={a:6377301.243,rf:300.8017,ellipseName:"Everest 1956"},rt.evrst69={a:6377295.664,rf:300.8017,ellipseName:"Everest 1969"},rt.evrstSS={a:6377298.556,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"},rt.fschr60={a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"},rt.fschr60m={a:6378155,rf:298.3,ellipseName:"Fischer 1960"},rt.fschr68={a:6378150,rf:298.3,ellipseName:"Fischer 1968"},rt.helmert={a:6378200,rf:298.3,ellipseName:"Helmert 1906"},rt.hough={a:6378270,rf:297,ellipseName:"Hough"},rt.intl={a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"},rt.kaula={a:6378163,rf:298.24,ellipseName:"Kaula 1961"},rt.lerch={a:6378139,rf:298.257,ellipseName:"Lerch 1979"},rt.mprts={a:6397300,rf:191,ellipseName:"Maupertius 1738"},rt.new_intl={a:6378157.5,b:6356772.2,ellipseName:"New International 1967"},rt.plessis={a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"},rt.krass={a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"},rt.SEasia={a:6378155,b:6356773.3205,ellipseName:"Southeast Asia"},rt.walbeck={a:6376896,b:6355834.8467,ellipseName:"Walbeck"},rt.WGS60={a:6378165,rf:298.3,ellipseName:"WGS 60"},rt.WGS66={a:6378145,rf:298.25,ellipseName:"WGS 66"},rt.WGS7={a:6378135,rf:298.26,ellipseName:"WGS 72"};var st=rt.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};rt.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};var it={};it.wgs84={towgs84:"0,0,0",ellipse:"WGS84",datumName:"WGS84"},it.ch1903={towgs84:"674.374,15.056,405.346",ellipse:"bessel",datumName:"swiss"},it.ggrs87={towgs84:"-199.87,74.79,246.62",ellipse:"GRS80",datumName:"Greek_Geodetic_Reference_System_1987"},it.nad83={towgs84:"0,0,0",ellipse:"GRS80",datumName:"North_American_Datum_1983"},it.nad27={nadgrids:"@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",ellipse:"clrk66",datumName:"North_American_Datum_1927"},it.potsdam={towgs84:"606.0,23.0,413.0",ellipse:"bessel",datumName:"Potsdam Rauenberg 1950 DHDN"},it.carthage={towgs84:"-263.0,6.0,431.0",ellipse:"clark80",datumName:"Carthage 1934 Tunisia"},it.hermannskogel={towgs84:"653.0,-212.0,449.0",ellipse:"bessel",datumName:"Hermannskogel"},it.osni52={towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"airy",datumName:"Irish National"},it.ire65={towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"mod_airy",datumName:"Ireland 1965"},it.rassadiran={towgs84:"-133.63,-157.5,-158.62",ellipse:"intl",datumName:"Rassadiran"},it.nzgd49={towgs84:"59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",ellipse:"intl",datumName:"New Zealand Geodetic Datum 1949"},it.osgb36={towgs84:"446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",ellipse:"airy",datumName:"Airy 1830"},it.s_jtsk={towgs84:"589,76,480",ellipse:"bessel",datumName:"S-JTSK (Ferro)"},it.beduaram={towgs84:"-106,-87,188",ellipse:"clrk80",datumName:"Beduaram"},it.gunung_segara={towgs84:"-403,684,41",ellipse:"bessel",datumName:"Gunung Segara Jakarta"},it.rnb72={towgs84:"106.869,-52.2978,103.724,-0.33657,0.456955,-1.84218,1",ellipse:"intl",datumName:"Reseau National Belge 1972"},R.projections={start:function(){tt.forEach(S)},add:S,get:function(e){if(!e)return!1;var t=e.toLowerCase();if("undefined"!=typeof at[t]&&nt[at[t]])return nt[at[t]]}},R.projections.start(),"use strict";var ot=function(e,t,a){return O(e,t)?a:e.datum_type===xe||t.datum_type===xe?a:e.es!==t.es||e.a!==t.a||P(e.datum_type)||P(t.datum_type)?(a=z(a,e.es,e.a),P(e.datum_type)&&(a=T(a,e.datum_type,e.datum_params)),P(t.datum_type)&&(a=B(a,t.datum_type,t.datum_params)),L(a,t.es,t.a,t.b)):a},dt=function(e,a,n){var r=n.x,s=n.y,o=n.z||0,d={},l,p,c;for(c=0;3>c;c++)if(!(a&&2===c&&void 0===n.z))switch(0===c?(l=r,p=-1==="ew".indexOf(e.axis[c])?"y":"x"):1===c?(l=s,p=-1==="ns".indexOf(e.axis[c])?"x":"y"):(l=o,p="z"),e.axis[c]){case"e":case"w":case"n":case"s":d[p]=l;break;case"u":void 0!==n[p]&&(d.z=l);break;case"d":void 0!==n[p]&&(d.z=-l);break;default:return null;}return d},lt=function(e){var t={x:e[0],y:e[1]};return 2<e.length&&(t.z=e[2]),3<e.length&&(t.m=e[3]),t},pt=function(e){N(e.x),N(e.y)},ct=R("WGS84");ne.fromMGRS=function(e){return new ne(Z(e))},ne.prototype.toMGRS=function(e){return G([this.x,this.y],e)};var ut=.046875,mt=.01953125,_t=.01068115234375,ft=function(e){var a=[];a[0]=1-e*(.25+e*(ut+e*(mt+e*_t))),a[1]=e*(.75-e*(ut+e*(mt+e*_t)));var n=e*e;return a[2]=n*(.46875-e*(.013020833333333334+e*.007120768229166667)),n*=e,a[3]=n*(.3645833333333333-e*.005696614583333333),a[4]=n*e*.3076171875,a},ht=function(e,t,a,n){return a*=t,t*=t,n[0]*e-a*(n[1]+t*(n[2]+t*(n[3]+t*n[4])))},gt=function(e,a,r){for(var o=e,d=20;d;--d){var l=ge(o),s=1-a*l*l;if(s=(ht(o,l,ye(o),r)-e)*(s*be(s))*(1/(1-a)),o-=s,n(s)<ve)return o}return o},yt={init:function(){this.x0=void 0===this.x0?0:this.x0,this.y0=void 0===this.y0?0:this.y0,this.long0=void 0===this.long0?0:this.long0,this.lat0=void 0===this.lat0?0:this.lat0,this.es&&(this.en=ft(this.es),this.ml0=ht(this.lat0,ge(this.lat0),ye(this.lat0),this.en))},forward:function(e){var r=e.x,s=e.y,i=Ve(r-this.long0),d=ge(s),l=ye(s),p,u,m;if(!this.es){var _=l*ge(i);if(n(n(_)-1)<ve)return 93;if(u=.5*this.a*this.k0*a((1+_)/(1-_))+this.x0,m=l*ye(i)/be(1-o(_,2)),_=n(m),1<=_){if(_-1>ve)return 93;m=0}else m=pe(m);0>s&&(m=-m),m=this.a*this.k0*(m-this.lat0)+this.y0}else{var f=l*i,h=o(f,2),g=this.ep2*o(l,2),c=o(g,2),w=n(l)>ve?he(s):0,E=o(w,2),t=o(E,2);p=1-this.es*o(d,2),f/=be(p);var C=ht(s,d,l,this.en);u=this.a*(this.k0*f*(1+h/6*(1-E+g+h/20*(5-18*E+t+14*g-58*E*g+h/42*(61+179*t-t*E-479*E)))))+this.x0,m=this.a*(this.k0*(C-this.ml0+d*i*f/2*(1+h/12*(5-E+9*g+4*c+h/30*(61+t-58*E+270*g-330*E*g+h/56*(1385+543*t-t*E-3111*E))))))+this.y0}return e.x=u,e.y=m,e},inverse:function(e){var a=(e.x-this.x0)*(1/this.a),r=(e.y-this.y0)*(1/this.a),s,i,l,p;if(!this.es){var u=fe(a/this.k0),m=.5*(u-1/u),_=this.lat0+r/this.k0,f=ye(_);s=be((1-o(f,2))/(1+o(m,2))),l=le(s),0>r&&(l=-l),p=0===m&&0===f?0:Ve(ue(m,f)+this.long0)}else if(s=this.ml0+r/this.k0,i=gt(s,this.es,this.en),n(i)<Ce){var h=ge(i),g=ye(i),y=n(g)>ve?he(i):0,b=this.ep2*o(g,2),c=o(b,2),x=o(y,2),t=o(x,2);s=1-this.es*o(h,2);var w=a*be(s)/this.k0,d=o(w,2);s*=y,l=i-.5*(s*d/(1-this.es))*(1-d/12*(5+3*x-9*b*x+b-4*c-d/30*(61+90*x-252*b*x+45*t+46*b-d/56*(1385+3633*x+4095*t+1574*t*x)))),p=Ve(this.long0+w*(1-d/6*(1+2*x+b-d/20*(5+28*x+24*t+8*b*x+6*b-d/42*(61+662*x+1320*t+720*t*x))))/g)}else l=Ce*Je(r),p=0;return e.x=p,e.y=l,e},names:["Transverse_Mercator","Transverse Mercator","tmerc"]},bt=function(e){var t=fe(e);return t=(t-1/t)/2,t},xt=function(e,t){var r=Math.max;e=n(e),t=n(t);var s=r(e,t),a=l(e,t)/(s?s:1);return s*be(1+o(a,2))},wt=function(e){var t=1+e,n=t-1;return 0===n?e:e*a(t)/n},Et=function(e){var t=n(e);return t=wt(t*(1+t/(xt(1,t)+1))),0>e?-t:t},Ct=function(e,t){for(var a=2*ye(2*t),n=e.length-1,r=e[n],s=0,o;0<=--n;)o=-s+a*r+e[n],s=r,r=o;return t+o*ge(2*t)},At=function(e,t){for(var a=2*ye(t),n=e.length-1,r=e[n],s=0,o;0<=--n;)o=-s+a*r+e[n],s=r,r=o;return ge(t)*o},St=function(e){var t=fe(e);return t=(t+1/t)/2,t},kt=function(e,t,a){for(var n=ge(t),s=ye(t),o=bt(a),d=St(a),l=2*s*d,p=-2*n*o,c=e.length-1,u=e[c],m=0,_=0,f=0,h,g;0<=--c;)h=_,g=m,_=u,m=f,u=-h+l*_-p*m+e[c],f=-g+p*_+l*m;return l=n*d,p=s*o,[l*u-p*f,l*f+p*u]},vt={init:function(){if(void 0===this.es||0>=this.es)throw new Error("incorrect elliptical usage");this.x0=void 0===this.x0?0:this.x0,this.y0=void 0===this.y0?0:this.y0,this.long0=void 0===this.long0?0:this.long0,this.lat0=void 0===this.lat0?0:this.lat0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var e=this.es/(1+be(1-this.es)),t=e/(2-e),a=t;this.cgb[0]=t*(2+t*(-2/3+t*(-2+t*(116/45+t*(26/45+t*(-2854/675)))))),this.cbg[0]=t*(-2+t*(2/3+t*(4/3+t*(-82/45+t*(32/45+t*(4642/4725)))))),a*=t,this.cgb[1]=a*(7/3+t*(-8/5+t*(-227/45+t*(2704/315+t*(2323/945))))),this.cbg[1]=a*(5/3+t*(-16/15+t*(-13/9+t*(904/315+t*(-1522/945))))),a*=t,this.cgb[2]=a*(56/15+t*(-136/35+t*(-1262/105+t*(73814/2835)))),this.cbg[2]=a*(-26/15+t*(34/21+t*(8/5+t*(-12686/2835)))),a*=t,this.cgb[3]=a*(4279/630+t*(-332/35+t*(-399572/14175))),this.cbg[3]=a*(1237/630+t*(-12/5+t*(-24832/14175))),a*=t,this.cgb[4]=a*(4174/315+t*(-144838/6237)),this.cbg[4]=a*(-734/315+t*(109598/31185)),a*=t,this.cgb[5]=a*(601676/22275),this.cbg[5]=a*(444337/155925),a=o(t,2),this.Qn=this.k0/(1+t)*(1+a*(1/4+a*(1/64+a/256))),this.utg[0]=t*(-.5+t*(2/3+t*(-37/96+t*(1/360+t*(81/512+t*(-96199/604800)))))),this.gtu[0]=t*(.5+t*(-2/3+t*(5/16+t*(41/180+t*(-127/288+t*(7891/37800)))))),this.utg[1]=a*(-1/48+t*(-1/15+t*(437/1440+t*(-46/105+t*(1118711/3870720))))),this.gtu[1]=a*(13/48+t*(-3/5+t*(557/1440+t*(281/630+t*(-1983433/1935360))))),a*=t,this.utg[2]=a*(-17/480+t*(37/840+t*(209/4480+t*(-5569/90720)))),this.gtu[2]=a*(61/240+t*(-103/140+t*(15061/26880+t*(167603/181440)))),a*=t,this.utg[3]=a*(-4397/161280+t*(11/504+t*(830251/7257600))),this.gtu[3]=a*(49561/161280+t*(-179/168+t*(6601661/7257600))),a*=t,this.utg[4]=a*(-4583/161280+t*(108847/3991680)),this.gtu[4]=a*(34729/80640+t*(-3418889/1995840)),a*=t,this.utg[5]=a*(-20648693/638668800),this.gtu[5]=a*(212378941/319334400);var n=Ct(this.cbg,this.lat0);this.Zb=-this.Qn*(n+At(this.gtu,2*n))},forward:function(e){var t=Ve(e.x-this.long0),a=e.y;a=Ct(this.cbg,a);var r=ge(a),s=ye(a),i=ge(t),o=ye(t);a=ue(r,o*s),t=ue(i*s,xt(r,s*o)),t=Et(he(t));var d=kt(this.gtu,2*a,2*t);a+=d[0],t+=d[1];var l,p;return 2.623395162778>=n(t)?(l=this.a*(this.Qn*t)+this.x0,p=this.a*(this.Qn*a+this.Zb)+this.y0):(l=1/0,p=1/0),e.x=l,e.y=p,e},inverse:function(e){var t=(e.x-this.x0)*(1/this.a),a=(e.y-this.y0)*(1/this.a);a=(a-this.Zb)/this.Qn,t/=this.Qn;var r,s;if(2.623395162778>=n(t)){var i=kt(this.utg,2*a,2*t);a+=i[0],t+=i[1],t=_e(bt(t));var o=ge(a),d=ye(a),l=ge(t),p=ye(t);a=ue(o*p,xt(l,p*d)),t=ue(l,p*d),r=Ve(t+this.long0),s=Ct(this.cgb,a)}else r=1/0,s=1/0;return e.x=r,e.y=s,e},names:["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc"]},It=function(e,t){if(void 0===e){if(e=r(30*(Ve(t)+me)/me)+1,0>e)return 0;if(60<e)return 60}return e},Rt={init:function(){var e=It(this.zone,this.long0);if(void 0===e)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*n(e)-183)*Ie,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,vt.init.apply(this),this.forward=vt.forward,this.inverse=vt.inverse},names:["Universal Transverse Mercator System","utm"],dependsOn:"etmerc"},Ot=function(e,t){return o((1-e)/(1+e),t)},zt={init:function(){var e=ge(this.lat0),t=ye(this.lat0);t*=t,this.rc=be(1-this.es)/(1-this.es*e*e),this.C=be(1+this.es*t*t/(1-this.es)),this.phic0=le(e/this.C),this.ratexp=.5*this.C*this.e,this.K=he(.5*this.phic0+Oe)/(o(he(.5*this.lat0+Oe),this.C)*Ot(this.e*e,this.ratexp))},forward:function(e){var t=e.x,a=e.y;return e.y=2*_e(this.K*o(he(.5*a+Oe),this.C)*Ot(this.e*ge(a),this.ratexp))-Ce,e.x=this.C*t,e},inverse:function(e){for(var t=e.x/this.C,a=e.y,r=o(he(.5*a+Oe)/this.K,1/this.C),s=20;0<s&&(a=2*_e(r*Ot(this.e*ge(e.y),-.5*this.e))-Ce,!(n(a-e.y)<1e-14));--s)e.y=a;return s?(e.x=t,e.y=a,e):null},names:["gauss"]},Lt={init:function(){zt.init.apply(this),this.rc&&(this.sinc0=ge(this.phic0),this.cosc0=ye(this.phic0),this.R2=2*this.rc,!this.title&&(this.title="Oblique Stereographic Alternative"))},forward:function(e){var t,a,n,r;return e.x=Ve(e.x-this.long0),zt.forward.apply(this,[e]),t=ge(e.y),a=ye(e.y),n=ye(e.x),r=this.k0*this.R2/(1+this.sinc0*t+this.cosc0*a*n),e.x=r*a*ge(e.x),e.y=r*(this.cosc0*t-this.sinc0*a*n),e.x=this.a*e.x+this.x0,e.y=this.a*e.y+this.y0,e},inverse:function(e){var t,a,n,r,s;if(e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,e.x/=this.k0,e.y/=this.k0,s=be(e.x*e.x+e.y*e.y)){var i=2*ue(s,this.R2);t=ge(i),a=ye(i),r=le(a*this.sinc0+e.y*t*this.cosc0/s),n=ue(e.x*t,s*this.cosc0*a-e.y*this.sinc0*t)}else r=this.phic0,n=0;return e.x=n,e.y=r,zt.inverse.apply(this,[e]),e.x=Ve(e.x+this.long0),e},names:["Stereographic_North_Pole","Oblique_Stereographic","Polar_Stereographic","sterea","Oblique Stereographic Alternative","Double_Stereographic"]},Tt={init:function(){this.coslat0=ye(this.lat0),this.sinlat0=ge(this.lat0),this.sphere?1===this.k0&&!isNaN(this.lat_ts)&&n(this.coslat0)<=ve&&(this.k0=.5*(1+Je(this.lat0)*ge(this.lat_ts))):(n(this.coslat0)<=ve&&(0<this.lat0?this.con=1:this.con=-1),this.cons=be(o(1+this.e,1+this.e)*o(1-this.e,1-this.e)),1===this.k0&&!isNaN(this.lat_ts)&&n(this.coslat0)<=ve&&(this.k0=.5*this.cons*Qe(this.e,ge(this.lat_ts),ye(this.lat_ts))/$e(this.e,this.con*this.lat_ts,this.con*ge(this.lat_ts))),this.ms1=Qe(this.e,this.sinlat0,this.coslat0),this.X0=2*_e(this.ssfn_(this.lat0,this.sinlat0,this.e))-Ce,this.cosX0=ye(this.X0),this.sinX0=ge(this.X0))},forward:function(e){var t=e.x,a=e.y,r=ge(a),s=ye(a),i=Ve(t-this.long0),o,d,l,p,c,u;return n(n(t-this.long0)-me)<=ve&&n(a+this.lat0)<=ve?(e.x=NaN,e.y=NaN,e):this.sphere?(o=2*this.k0/(1+this.sinlat0*r+this.coslat0*s*ye(i)),e.x=65*this.a*s*ge(i)+this.x0,e.y=65*this.a*(this.coslat0*r-this.sinlat0*s*ye(i))+this.y0,e):(d=2*_e(this.ssfn_(a,r,this.e))-Ce,p=ye(d),l=ge(d),n(this.coslat0)<=ve)?(c=$e(this.e,a*this.con,this.con*r),u=2*this.a*this.k0*c/this.cons,e.x=this.x0+u*ge(t-this.long0),e.y=this.y0-this.con*u*ye(t-this.long0),e):(n(this.sinlat0)<ve?(o=2*this.a*this.k0/(1+p*ye(i)),e.y=65*l):(o=2*this.a*this.k0*this.ms1/(this.cosX0*(1+this.sinX0*l+this.cosX0*p*ye(i))),e.y=65*(this.cosX0*l-this.sinX0*p*ye(i))+this.y0),e.x=65*p*ge(i)+this.x0,e)},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t=be(e.x*e.x+e.y*e.y),a,r,s,i,o;if(this.sphere){var d=2*_e(t/(2*this.a*this.k0));return(a=this.long0,r=this.lat0,t<=ve)?(e.x=a,e.y=r,e):(r=le(ye(d)*this.sinlat0+e.y*ge(d)*this.coslat0/t),a=n(this.coslat0)<ve?0<this.lat0?Ve(this.long0+ue(e.x,-1*e.y)):Ve(this.long0+ue(e.x,e.y)):Ve(this.long0+ue(e.x*ge(d),t*this.coslat0*ye(d)-e.y*this.sinlat0*ge(d))),e.x=a,e.y=r,e)}if(n(this.coslat0)<=ve){if(t<=ve)return r=this.lat0,a=this.long0,e.x=a,e.y=r,e;e.x*=this.con,e.y*=this.con,s=t*this.cons/(2*this.a*this.k0),r=this.con*et(this.e,s),a=this.con*Ve(this.con*this.long0+ue(e.x,-1*e.y))}else i=2*_e(t*this.cosX0/(2*this.a*this.k0*this.ms1)),a=this.long0,t<=ve?o=this.X0:(o=le(ye(i)*this.sinX0+e.y*ge(i)*this.cosX0/t),a=Ve(this.long0+ue(e.x*ge(i),t*this.cosX0*ye(i)-e.y*this.sinX0*ge(i)))),r=-1*et(this.e,he(.5*(Ce+o)));return e.x=a,e.y=r,e},names:["stere","Stereographic_South_Pole","Polar Stereographic (variant B)"],ssfn_:function(e,t,a){return t*=a,he(.5*(Ce+e))*o((1-t)/(1+t),.5*a)}},Bt={init:function(){var t=this.lat0;this.lambda0=this.long0;var n=ge(t),r=this.a,s=this.rf,i=1/s,d=2*i-o(i,2),l=this.e=be(d);this.R=this.k0*r*be(1-d)/(1-d*o(n,2)),this.alpha=be(1+d/(1-d)*o(ye(t),4)),this.b0=le(n/this.alpha);var e=a(he(me/4+this.b0/2)),p=a(he(me/4+t/2)),c=a((1+l*n)/(1-l*n));this.K=e-this.alpha*p+this.alpha*l/2*c},forward:function(e){var t=a(he(me/4-e.y/2)),n=this.e/2*a((1+this.e*ge(e.y))/(1-this.e*ge(e.y))),r=-this.alpha*(t+n)+this.K,s=2*(_e(fe(r))-me/4),i=this.alpha*(e.x-this.lambda0),o=_e(ge(73)/(ge(this.b0)*he(s)+ye(this.b0)*ye(73))),d=le(ye(this.b0)*ge(s)-ge(this.b0)*ye(s)*ye(73));return e.y=this.R/2*a((1+ge(d))/(1-ge(d)))+this.y0,e.x=this.R*o+this.x0,e},inverse:function(e){for(var t=e.x-this.x0,r=e.y-this.y0,s=t/this.R,i=2*(_e(fe(r/this.R))-me/4),o=le(ye(this.b0)*ge(i)+ge(this.b0)*ye(i)*ye(s)),d=_e(ge(s)/(ye(this.b0)*ye(s)-ge(this.b0)*he(i))),l=this.lambda0+73/this.alpha,p=0,c=o,u=-1e3,m=0;1e-7<n(c-u);){if(20<++m)return;p=1/this.alpha*(a(he(me/4+o/2))-this.K)+this.e*a(he(me/4+le(this.e*ge(c))/2)),u=c,c=2*_e(fe(p))-me/2}return e.x=l,e.y=c,e},names:["somerc"]},Pt={init:function(){this.no_off=this.no_off||!1,this.no_rot=this.no_rot||!1,isNaN(this.k0)&&(this.k0=1);var e=ge(this.lat0),t=ye(this.lat0),a=this.e*e;this.bl=be(1+this.es/(1-this.es)*o(t,4)),this.al=this.a*this.bl*this.k0*be(1-this.es)/(1-a*a);var n=$e(this.e,this.lat0,e),r=this.bl/t*be((1-this.es)/(1-a*a));1>r*r&&(r=1);var s,i;if(!isNaN(this.longc))s=0<=this.lat0?r+be(r*r-1):r-be(r*r-1),this.el=s*o(n,this.bl),i=.5*(s-1/s),this.gamma0=le(ge(this.alpha)/r),this.long0=this.longc-le(i*he(this.gamma0))/this.bl;else{var d=$e(this.e,this.lat1,ge(this.lat1)),l=$e(this.e,this.lat2,ge(this.lat2));this.el=0<=this.lat0?(r+be(r*r-1))*o(n,this.bl):(r-be(r*r-1))*o(n,this.bl);var p=o(d,this.bl),c=o(l,this.bl);s=this.el/p,i=.5*(s-1/s);var u=(this.el*this.el-c*p)/(this.el*this.el+c*p),m=Ve(this.long1-this.long2);this.long0=.5*(this.long1+this.long2)-_e(u*he(.5*this.bl*m)/((c-p)/(c+p)))/this.bl,this.long0=Ve(this.long0);var _=Ve(this.long1-this.long0);this.gamma0=_e(ge(this.bl*_)/i),this.alpha=le(r*ge(this.gamma0))}this.uc=this.no_off?0:0<=this.lat0?this.al/this.bl*ue(be(r*r-1),ye(this.alpha)):-1*this.al/this.bl*ue(be(r*r-1),ye(this.alpha))},forward:function(e){var r=Number.POSITIVE_INFINITY,s=e.x,i=e.y,d=Ve(s-this.long0),l,p,c;if(n(n(i)-Ce)<=ve)c=0<i?-1:1,p=this.al/this.bl*a(he(Oe+.5*(c*this.gamma0))),l=-1*c*Ce*this.al/this.bl;else{var u=$e(this.e,i,ge(i)),t=this.el/o(u,this.bl),m=.5*(t-1/t),_=ge(this.bl*d),f=(m*ge(this.gamma0)-_*ye(this.gamma0))/(.5*(t+1/t));p=n(n(f)-1)<=ve?r:.5*this.al*a((1-f)/(1+f))/this.bl,l=n(ye(this.bl*d))<=ve?this.al*this.bl*d:this.al*ue(m*ye(this.gamma0)+_*ge(this.gamma0),ye(this.bl*d))/this.bl}return this.no_rot?(e.x=this.x0+l,e.y=this.y0+p):(l-=this.uc,e.x=this.x0+p*ye(this.alpha)+l*ge(this.alpha),e.y=this.y0+l*ye(this.alpha)-p*ge(this.alpha)),e},inverse:function(e){var t,a;this.no_rot?(a=e.y-this.y0,t=e.x-this.x0):(a=(e.x-this.x0)*ye(this.alpha)-(e.y-this.y0)*ge(this.alpha),t=(e.y-this.y0)*ye(this.alpha)+(e.x-this.x0)*ge(this.alpha),t+=this.uc);var r=fe(-1*this.bl*a/this.al),s=.5*(r-1/r),i=ge(this.bl*t/this.al),d=(i*ye(this.gamma0)+s*ge(this.gamma0))/(.5*(r+1/r)),l=o(this.el/be((1+d)/(1-d)),1/this.bl);return n(d-1)<ve?(e.x=this.long0,e.y=Ce):n(d+1)<ve?(e.x=this.long0,e.y=-1*Ce):(e.y=et(this.e,l),e.x=Ve(this.long0-ue(s*ye(this.gamma0)-i*ge(this.gamma0),ye(this.bl*t/this.al))/this.bl)),e},names:["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","omerc"]},Nt={init:function(){if(this.lat2||(this.lat2=this.lat1),this.k0||(this.k0=1),this.x0=this.x0||0,this.y0=this.y0||0,!(n(this.lat1+this.lat2)<ve)){var e=this.b/this.a;this.e=be(1-e*e);var t=ge(this.lat1),r=ye(this.lat1),s=Qe(this.e,t,r),i=$e(this.e,this.lat1,t),d=ge(this.lat2),l=ye(this.lat2),p=Qe(this.e,d,l),c=$e(this.e,this.lat2,d),u=$e(this.e,this.lat0,ge(this.lat0));this.ns=n(this.lat1-this.lat2)>ve?a(s/p)/a(i/c):t,isNaN(this.ns)&&(this.ns=t),this.f0=s/(this.ns*o(i,this.ns)),this.rh=this.a*this.f0*o(u,this.ns),this.title||(this.title="Lambert Conformal Conic")}},forward:function(e){var t=e.x,a=e.y;n(2*n(a)-me)<=ve&&(a=Je(a)*(Ce-2*ve));var r=n(n(a)-Ce),s,i;if(r>ve)s=$e(this.e,a,ge(a)),i=this.a*this.f0*o(s,this.ns);else{if(r=a*this.ns,0>=r)return null;i=0}var d=this.ns*Ve(t-this.long0);return e.x=this.k0*(i*ge(d))+this.x0,e.y=this.k0*(this.rh-i*ye(d))+this.y0,e},inverse:function(e){var t=(e.x-this.x0)/this.k0,a=this.rh-(e.y-this.y0)/this.k0,n,r,s,i,d;0<this.ns?(n=be(t*t+a*a),r=1):(n=-be(t*t+a*a),r=-1);var l=0;if(0!==n&&(l=ue(r*t,r*a)),!(0!==n||0<this.ns))i=-Ce;else if(r=1/this.ns,s=o(n/(this.a*this.f0),r),i=et(this.e,s),-9999===i)return null;return d=Ve(l/this.ns+this.long0),e.x=d,e.y=i,e},names:["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_2SP","lcc"]},Dt={init:function(){this.a=6377397.155,this.es=.006674372230614,this.e=be(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.7417649320975901-.308341501185665),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=be(this.e2),this.alfa=be(1+this.e2*o(ye(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=le(ge(this.fi0)/this.alfa),this.g=o((1+this.e*ge(this.fi0))/(1-this.e*ge(this.fi0)),this.alfa*this.e/2),this.k=he(this.u0/2+this.s45)/o(he(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*be(1-this.e2)/(1-this.e2*o(ge(this.fi0),2)),this.s0=1.37008346281555,this.n=ge(this.s0),this.ro0=this.k1*this.n0/he(this.s0),this.ad=this.s90-this.uq},forward:function(e){var t=e.x,a=e.y,n=Ve(t-this.long0),r,i,l,p,c,m,_;return r=o((1+this.e*ge(a))/(1-this.e*ge(a)),this.alfa*this.e/2),i=2*(_e(this.k*o(he(a/2+this.s45),this.alfa)/r)-this.s45),l=-n*this.alfa,p=le(ye(this.ad)*ge(i)+ge(this.ad)*ye(i)*ye(l)),c=le(ye(i)*ge(l)/ye(p)),m=this.n*c,_=this.ro0*o(he(this.s0/2+this.s45),this.n)/o(he(p/2+this.s45),this.n),e.y=_*ye(m)/1,e.x=_*ge(m)/1,this.czech||(e.y*=-1,e.x*=-1),e},inverse:function(e){var t=e.x,a,r,i,l,p,c,m,_;e.x=e.y,e.y=t,this.czech||(e.y*=-1,e.x*=-1),c=be(e.x*e.x+e.y*e.y),p=ue(e.y,e.x),l=p/ge(this.s0),i=2*(_e(o(this.ro0/c,1/this.n)*he(this.s0/2+this.s45))-this.s45),a=le(ye(this.ad)*ge(i)-ge(this.ad)*ye(i)*ye(l)),r=le(ye(i)*ge(l)/ye(a)),e.x=this.long0-r/this.alfa,m=a,_=0;var f=0;do e.y=2*(_e(o(this.k,-1/this.alfa)*o(he(a/2+this.s45),1/this.alfa)*o((1+this.e*ge(m))/(1-this.e*ge(m)),this.e/2))-this.s45),1e-10>n(m-e.y)&&(_=1),m=e.y,f+=1;while(0===_&&15>f);return 15<=f?null:e},names:["Krovak","krovak"]},jt=function(e,t,a,n,r){return e*r-t*ge(2*r)+a*ge(4*r)-n*ge(6*r)},Ut=function(e){return 1-.25*e*(1+e/16*(3+1.25*e))},Ft=function(e){return .375*e*(1+.25*e*(1+.46875*e))},Mt=function(e){return .05859375*e*e*(1+.75*e)},Gt=function(e){return e*e*e*(35/3072)},Zt=function(t,a,e){var n=a*e;return t/be(1-n*n)},i=function(e){return n(e)<Ce?e:e-Je(e)*me},ce=function(e,t,a,r,s){var o,d;o=e/t;for(var l=0;15>l;l++)if(d=(e-(t*o-a*ge(2*o)+r*ge(4*o)-s*ge(6*o)))/(t-2*a*ye(2*o)+4*r*ye(4*o)-6*s*ye(6*o)),o+=d,1e-10>=n(d))return o;return NaN},Ee={init:function(){this.sphere||(this.e0=Ut(this.es),this.e1=Ft(this.es),this.e2=Mt(this.es),this.e3=Gt(this.es),this.ml0=this.a*jt(this.e0,this.e1,this.e2,this.e3,this.lat0))},forward:function(e){var t=e.x,a=e.y,n,r;if(t=Ve(t-this.long0),this.sphere)n=this.a*le(ye(a)*ge(t)),r=this.a*(ue(he(a),ye(t))-this.lat0);else{var s=ge(a),i=ye(a),o=Zt(this.a,this.e,s),d=he(a)*he(a),l=t*ye(a),p=l*l,c=this.es*i*i/(1-this.es),u=this.a*jt(this.e0,this.e1,this.e2,this.e3,a);n=o*l*(1-p*d*(1/6-(8-d+8*c)*p/120)),r=u-this.ml0+o*s/i*p*(.5+(5-d+6*c)*p/24)}return e.x=n+this.x0,e.y=r+this.y0,e},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t=e.x/this.a,a=e.y/this.a,r,s;if(this.sphere){var d=a+this.lat0;r=le(ge(d)*ye(t)),s=ue(he(t),ye(d))}else{var l=this.ml0/this.a+a,p=ce(l,this.e0,this.e1,this.e2,this.e3);if(n(n(p)-Ce)<=ve)return e.x=this.long0,e.y=Ce,0>a&&(e.y*=-1),e;var c=Zt(this.a,this.e,ge(p)),u=c*c*c/this.a/this.a*(1-this.es),m=o(he(p),2),_=t*this.a/c,f=_*_;r=p-c*he(p)/u*_*_*(.5-(1+3*m)*_*_/24),s=_*(1-f*(m/3+(1+3*m)*m*f/15))/ye(p)}return e.x=Ve(s+this.long0),e.y=i(r),e},names:["Cassini","Cassini_Soldner","cass"]},Yt=function(e,t){var n;return 1e-7<e?(n=e*t,(1-e*e)*(t/(1-n*n)-.5/e*a((1-n)/(1+n)))):2*t},qt=.3333333333333333,Ht=.17222222222222222,Kt=.10257936507936508,Xt=.06388888888888888,Wt=.0664021164021164,Qt=.016415012942191543,Jt={init:function(){var e=n(this.lat0);if(this.mode=n(e-Ce)<ve?0>this.lat0?this.S_POLE:this.N_POLE:n(e)<ve?this.EQUIT:this.OBLIQ,0<this.es){var t;switch(this.qp=Yt(this.e,1),this.mmf=.5/(1-this.es),this.apa=re(this.es),this.mode){case this.N_POLE:this.dd=1;break;case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=be(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=be(.5*this.qp),t=ge(this.lat0),this.sinb1=Yt(this.e,t)/this.qp,this.cosb1=be(1-this.sinb1*this.sinb1),this.dd=ye(this.lat0)/(be(1-this.es*t*t)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd;}}else this.mode===this.OBLIQ&&(this.sinph0=ge(this.lat0),this.cosph0=ye(this.lat0))},forward:function(e){var t=e.x,a=e.y,r,s,i,o,d,l,p,c,u,m;if(t=Ve(t-this.long0),!this.sphere){switch(p=0,c=0,u=0,i=ye(t),o=ge(t),d=ge(a),l=Yt(this.e,d),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(p=l/this.qp,c=be(1-p*p)),this.mode){case this.OBLIQ:u=1+this.sinb1*p+this.cosb1*c*i;break;case this.EQUIT:u=1+c*i;break;case this.N_POLE:u=Ce+a,l=this.qp-l;break;case this.S_POLE:u=a-Ce,l=this.qp+l;}if(n(u)<ve)return null;switch(this.mode){case this.OBLIQ:case this.EQUIT:u=be(2/u),s=this.mode===this.OBLIQ?this.ymf*u*(this.cosb1*p-this.sinb1*c*i):(u=be(2/(1+c*i)))*p*this.ymf,r=this.xmf*u*c*o;break;case this.N_POLE:case this.S_POLE:0<=l?(r=(u=be(l))*o,s=i*(this.mode===this.S_POLE?u:-u)):r=s=0;}}else if(d=ge(a),m=ye(a),i=ye(t),this.mode===this.OBLIQ||this.mode===this.EQUIT){if(s=this.mode===this.EQUIT?1+m*i:1+this.sinph0*d+this.cosph0*m*i,s<=ve)return null;s=be(2/s),r=s*m*ge(t),s*=this.mode===this.EQUIT?d:this.cosph0*d-this.sinph0*m*i}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(i=-i),n(a+this.phi0)<ve)return null;s=Oe-.5*a,s=2*(this.mode===this.S_POLE?ye(s):ge(s)),r=s*ge(t),s*=i}return e.x=this.a*r+this.x0,e.y=this.a*s+this.y0,e},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t=e.x/this.a,a=e.y/this.a,r,s,i,o,d,l,p;if(this.sphere){var c=0,u=0,m;if(m=be(t*t+a*a),s=.5*m,1<s)return null;switch(s=2*le(s),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(u=ge(s),c=ye(s)),this.mode){case this.EQUIT:s=n(m)<=ve?0:le(a*u/m),t*=u,a=c*m;break;case this.OBLIQ:s=n(m)<=ve?this.phi0:le(c*this.sinph0+a*u*this.cosph0/m),t*=u*this.cosph0,a=(c-ge(s)*this.sinph0)*m;break;case this.N_POLE:a=-a,s=Ce-s;break;case this.S_POLE:s-=Ce;}r=0===a&&(this.mode===this.EQUIT||this.mode===this.OBLIQ)?0:ue(t,a)}else{if(p=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(t/=this.dd,a*=this.dd,l=be(t*t+a*a),l<ve)return e.x=0,e.y=this.phi0,e;o=2*le(.5*l/this.rq),i=ye(o),t*=o=ge(o),this.mode===this.OBLIQ?(p=i*this.sinb1+a*o*this.cosb1/l,d=this.qp*p,a=l*this.cosb1*i-a*this.sinb1*o):(p=a*o/l,d=this.qp*p,a=l*i)}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(a=-a),d=t*t+a*a,!d)return e.x=0,e.y=this.phi0,e;p=1-d/this.qp,this.mode===this.S_POLE&&(p=-p)}r=ue(t,a),s=se(le(p),this.apa)}return e.x=Ve(this.long0+r),e.y=s,e},names:["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"],S_POLE:1,N_POLE:2,EQUIT:3,OBLIQ:4},Vt=function(e){return 1<n(e)&&(e=1<e?1:-1),le(e)},$t={init:function(){n(this.lat1+this.lat2)<ve||(this.temp=this.b/this.a,this.es=1-o(this.temp,2),this.e3=be(this.es),this.sin_po=ge(this.lat1),this.cos_po=ye(this.lat1),this.t1=this.sin_po,this.con=this.sin_po,this.ms1=Qe(this.e3,this.sin_po,this.cos_po),this.qs1=Yt(this.e3,this.sin_po,this.cos_po),this.sin_po=ge(this.lat2),this.cos_po=ye(this.lat2),this.t2=this.sin_po,this.ms2=Qe(this.e3,this.sin_po,this.cos_po),this.qs2=Yt(this.e3,this.sin_po,this.cos_po),this.sin_po=ge(this.lat0),this.cos_po=ye(this.lat0),this.t3=this.sin_po,this.qs0=Yt(this.e3,this.sin_po,this.cos_po),this.ns0=n(this.lat1-this.lat2)>ve?(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*be(this.c-this.ns0*this.qs0)/this.ns0)},forward:function(e){var t=e.x,a=e.y;this.sin_phi=ge(a),this.cos_phi=ye(a);var n=Yt(this.e3,this.sin_phi,this.cos_phi),r=this.a*be(this.c-this.ns0*n)/this.ns0,s=this.ns0*Ve(t-this.long0),i=r*ge(s)+this.x0,o=this.rh-r*ye(s)+this.y0;return e.x=i,e.y=o,e},inverse:function(e){var t,a,n,r,s,i;return e.x-=this.x0,e.y=this.rh-e.y+this.y0,0<=this.ns0?(t=be(e.x*e.x+e.y*e.y),n=1):(t=-be(e.x*e.x+e.y*e.y),n=-1),r=0,0!==t&&(r=ue(n*e.x,n*e.y)),n=t*this.ns0/this.a,this.sphere?i=le((this.c-n*n)/(2*this.ns0)):(a=(this.c-n*n)/this.ns0,i=this.phi1z(this.e3,a)),s=Ve(r/this.ns0+this.long0),e.x=s,e.y=i,e},names:["Albers_Conic_Equal_Area","Albers","aea"],phi1z:function(e,t){var r=Vt(.5*t),s,o,d,l,p;if(e<ve)return r;for(var c=1;25>=c;c++)if(s=ge(r),o=ye(r),d=e*s,l=1-d*d,p=.5*l*l/o*(t/(1-e*e)-s/l+.5/e*a((1-d)/(1+d))),r+=p,1e-7>=n(p))return r;return null}},ea={init:function(){this.sin_p14=ge(this.lat0),this.cos_p14=ye(this.lat0),this.infinity_dist=1e3*this.a,this.rc=1},forward:function(e){var t=e.x,a=e.y,r,s,i,o,d,l,p,c;return i=Ve(t-this.long0),r=ge(a),s=ye(a),o=ye(i),l=this.sin_p14*r+this.cos_p14*s*o,d=1,0<l||n(l)<=ve?(p=this.x0+this.a*d*s*ge(i)/l,c=this.y0+this.a*d*(this.cos_p14*r-this.sin_p14*s*o)/l):(p=this.x0+this.infinity_dist*s*ge(i),c=this.y0+this.infinity_dist*(this.cos_p14*r-this.sin_p14*s*o)),e.x=p,e.y=c,e},inverse:function(e){var t,a,n,r,s,i;return e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,e.x/=this.k0,e.y/=this.k0,(t=be(e.x*e.x+e.y*e.y))?(r=ue(t,this.rc),a=ge(r),n=ye(r),i=Vt(n*this.sin_p14+e.y*a*this.cos_p14/t),s=ue(e.x*a,t*this.cos_p14*n-e.y*this.sin_p14*a),s=Ve(this.long0+s)):(i=this.phic0,s=0),e.x=s,e.y=i,e},names:["gnom"]},ta=function(e,t){var r=1-(1-e*e)/(2*e)*a((1-e)/(1+e));if(1e-6>n(n(t)-r))return 0>t?-1*Ce:Ce;for(var s=le(.5*t),d=0,l,p,c,u;30>d;d++)if(p=ge(s),c=ye(s),u=e*p,l=o(1-u*u,2)/(2*c)*(t/(1-e*e)-p/(1-u*u)+.5/e*a((1-u)/(1+u))),s+=l,1e-10>=n(l))return s;return NaN},aa={init:function(){this.sphere||(this.k0=Qe(this.e,ge(this.lat_ts),ye(this.lat_ts)))},forward:function(e){var t=e.x,a=e.y,n=Ve(t-this.long0),r,s;if(this.sphere)r=this.x0+this.a*n*ye(this.lat_ts),s=this.y0+this.a*ge(a)/ye(this.lat_ts);else{var i=Yt(this.e,ge(a));r=this.x0+this.a*this.k0*n,s=this.y0+.5*(this.a*i)/this.k0}return e.x=r,e.y=s,e},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t,a;return this.sphere?(t=Ve(this.long0+e.x/this.a/ye(this.lat_ts)),a=le(e.y/this.a*ye(this.lat_ts))):(a=ta(this.e,2*e.y*this.k0/this.a),t=Ve(this.long0+e.x/(this.a*this.k0))),e.x=t,e.y=a,e},names:["cea"]},na={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=ye(this.lat_ts)},forward:function(e){var t=e.x,a=e.y,n=Ve(t-this.long0),r=i(a-this.lat0);return e.x=this.x0+this.a*n*this.rc,e.y=this.y0+this.a*r,e},inverse:function(e){var t=e.x,a=e.y;return e.x=Ve(this.long0+(t-this.x0)/(this.a*this.rc)),e.y=i(this.lat0+(a-this.y0)/this.a),e},names:["Equirectangular","Equidistant_Cylindrical","eqc"]},ra={init:function(){this.temp=this.b/this.a,this.es=1-o(this.temp,2),this.e=be(this.es),this.e0=Ut(this.es),this.e1=Ft(this.es),this.e2=Mt(this.es),this.e3=Gt(this.es),this.ml0=this.a*jt(this.e0,this.e1,this.e2,this.e3,this.lat0)},forward:function(e){var t=e.x,a=e.y,r=Ve(t-this.long0),s,o,d;if(d=r*ge(a),this.sphere)n(a)<=ve?(s=this.a*r,o=-1*this.a*this.lat0):(s=this.a*ge(d)/he(a),o=this.a*(i(a-this.lat0)+(1-ye(d))/he(a)));else if(n(a)<=ve)s=this.a*r,o=-1*this.ml0;else{var l=Zt(this.a,this.e,ge(a))/he(a);s=l*ge(d),o=this.a*jt(this.e0,this.e1,this.e2,this.e3,a)-this.ml0+l*(1-ye(d))}return e.x=s+this.x0,e.y=o+this.y0,e},inverse:function(e){var t,a,r,s,d,l,p,c,u;if(r=e.x-this.x0,s=e.y-this.y0,this.sphere){if(n(s+this.a*this.lat0)<=ve)t=Ve(r/this.a+this.long0),a=0;else{l=this.lat0+s/this.a,p=r*r/this.a/this.a+l*l,c=l;var m;for(d=20;d;--d)if(m=he(c),u=-1*(l*(c*m+1)-c-.5*(c*c+p)*m)/((c-l)/m-1),c+=u,n(u)<=ve){a=c;break}t=Ve(this.long0+le(r*he(c)/this.a)/ge(a))}}else if(n(s+this.ml0)<=ve)a=0,t=Ve(this.long0+r/this.a);else{l=(this.ml0+s)/this.a,p=r*r/this.a/this.a+l*l,c=l;var _,f,h,g,b;for(d=20;d;--d)if(b=this.e*ge(c),_=be(1-b*b)*he(c),f=this.a*jt(this.e0,this.e1,this.e2,this.e3,c),h=this.e0-2*this.e1*ye(2*c)+4*this.e2*ye(4*c)-6*this.e3*ye(6*c),g=f/this.a,u=(l*(_*g+1)-g-.5*_*(g*g+p))/(this.es*ge(2*c)*(g*g+p-2*l*g)/(4*_)+(l-g)*(_*h-2/ge(2*c))-h),c-=u,n(u)<=ve){a=c;break}_=be(1-this.es*o(ge(a),2))*he(a),t=Ve(this.long0+le(r*_/this.a)/ge(a))}return e.x=t,e.y=a,e},names:["Polyconic","poly"]},sa={init:function(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013},forward:function(e){var t=e.x,a=e.y,r=a-this.lat0,s=t-this.long0,i=1,o=0,d;for(d=1;10>=d;d++)i*=1E-5*(r/we),o+=this.A[d]*i;var l=o,p=s,c=1,u=0,m=0,_=0,f,h;for(d=1;6>=d;d++)f=c*l-u*p,h=u*l+c*p,c=f,u=h,m=m+this.B_re[d]*c-this.B_im[d]*u,_=_+this.B_im[d]*c+this.B_re[d]*u;return e.x=_*this.a+this.x0,e.y=m*this.a+this.y0,e},inverse:function(e){var t=e.x,a=e.y,r=t-this.x0,s=a-this.y0,o=s/this.a,d=r/this.a,l=1,p=0,c=0,u=0,m,_,f;for(m=1;6>=m;m++)_=l*o-p*d,f=p*o+l*d,l=_,p=f,c=c+this.C_re[m]*l-this.C_im[m]*p,u=u+this.C_im[m]*l+this.C_re[m]*p;for(var h=0;h<this.iterations;h++){var g=c,y=u,b=o,x=d,w,E;for(m=2;6>=m;m++)w=g*c-y*u,E=y*c+g*u,g=w,y=E,b+=(m-1)*(this.B_re[m]*g-this.B_im[m]*y),x+=(m-1)*(this.B_im[m]*g+this.B_re[m]*y);g=1,y=0;var C=this.B_re[1],A=this.B_im[1];for(m=2;6>=m;m++)w=g*c-y*u,E=y*c+g*u,g=w,y=E,C+=m*(this.B_re[m]*g-this.B_im[m]*y),A+=m*(this.B_im[m]*g+this.B_re[m]*y);var S=C*C+A*A;c=(b*C+x*A)/S,u=(x*C-b*A)/S}var k=c,v=u,I=1,R=0;for(m=1;9>=m;m++)I*=k,R+=this.D[m]*I;var O=this.lat0+1E5*(R*we),z=this.long0+v;return e.x=z,e.y=O,e},names:["New_Zealand_Map_Grid","nzmg"]},ia={init:function(){},forward:function(e){var t=e.x,n=e.y,r=Ve(t-this.long0),s=this.x0+this.a*r,i=this.y0+1.25*(this.a*a(he(me/4+n/2.5)));return e.x=s,e.y=i,e},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t=Ve(this.long0+e.x/this.a),a=2.5*(_e(fe(.8*e.y/this.a))-me/4);return e.x=t,e.y=a,e},names:["Miller_Cylindrical","mill"]},oa={init:function(){this.sphere?(this.n=1,this.m=0,this.es=0,this.C_y=be((this.m+1)/this.n),this.C_x=this.C_y/(this.m+1)):this.en=ft(this.es)},forward:function(e){var t=e.x,a=e.y,r,o;if(t=Ve(t-this.long0),this.sphere){if(!this.m)a=1===this.n?a:le(this.n*ge(a));else for(var d=this.n*ge(a),l=20,p;l&&(p=(this.m*a+ge(a)-d)/(this.m+ye(a)),a-=p,!(n(p)<ve));--l);r=this.a*this.C_x*t*(this.m+ye(a)),o=this.a*this.C_y*a}else{var u=ge(a),s=ye(a);o=this.a*ht(a,u,s,this.en),r=this.a*t*s/be(1-this.es*u*u)}return e.x=r,e.y=o,e},inverse:function(e){var t,a,r,o;return e.x-=this.x0,r=e.x/this.a,e.y-=this.y0,t=e.y/this.a,this.sphere?(t/=this.C_y,r/=this.C_x*(this.m+ye(t)),this.m?t=Vt((this.m*t+ge(t))/this.n):1!==this.n&&(t=Vt(ge(t)/this.n)),r=Ve(r+this.long0),t=i(t)):(t=gt(e.y/this.a,this.es,this.en),o=n(t),o<Ce?(o=ge(t),a=this.long0+e.x*be(1-this.es*o*o)/(this.a*ye(t)),r=Ve(a)):o-ve<Ce&&(r=this.long0)),e.x=r,e.y=t,e},names:["Sinusoidal","sinu"]},da={init:function(){},forward:function(e){for(var t=e.x,a=e.y,r=Ve(t-this.long0),s=a,i=me*ge(a),o;o=-(s+ge(s)-i)/(1+ye(s)),s+=o,!(n(o)<ve););s/=2,me/2-n(a)<ve&&(r=0);var d=.900316316158*this.a*r*ye(s)+this.x0,l=1.4142135623731*this.a*ge(s)+this.y0;return e.x=d,e.y=l,e},inverse:function(e){var t,a;e.x-=this.x0,e.y-=this.y0,a=e.y/(1.4142135623731*this.a),.999999999999<n(a)&&(a=.999999999999),t=le(a);var r=Ve(this.long0+e.x/(.900316316158*this.a*ye(t)));r<-me&&(r=-me),r>me&&(r=me),a=(2*t+ge(2*t))/me,1<n(a)&&(a=1);var s=le(a);return e.x=r,e.y=s,e},names:["Mollweide","moll"]},la={init:function(){n(this.lat1+this.lat2)<ve||(this.lat2=this.lat2||this.lat1,this.temp=this.b/this.a,this.es=1-o(this.temp,2),this.e=be(this.es),this.e0=Ut(this.es),this.e1=Ft(this.es),this.e2=Mt(this.es),this.e3=Gt(this.es),this.sinphi=ge(this.lat1),this.cosphi=ye(this.lat1),this.ms1=Qe(this.e,this.sinphi,this.cosphi),this.ml1=jt(this.e0,this.e1,this.e2,this.e3,this.lat1),n(this.lat1-this.lat2)<ve?this.ns=this.sinphi:(this.sinphi=ge(this.lat2),this.cosphi=ye(this.lat2),this.ms2=Qe(this.e,this.sinphi,this.cosphi),this.ml2=jt(this.e0,this.e1,this.e2,this.e3,this.lat2),this.ns=(this.ms1-this.ms2)/(this.ml2-this.ml1)),this.g=this.ml1+this.ms1/this.ns,this.ml0=jt(this.e0,this.e1,this.e2,this.e3,this.lat0),this.rh=this.a*(this.g-this.ml0))},forward:function(e){var t=e.x,a=e.y,n;if(this.sphere)n=this.a*(this.g-a);else{var r=jt(this.e0,this.e1,this.e2,this.e3,a);n=this.a*(this.g-r)}var s=this.ns*Ve(t-this.long0),i=this.x0+n*ge(s),o=this.y0+this.rh-n*ye(s);return e.x=i,e.y=o,e},inverse:function(e){e.x-=this.x0,e.y=this.rh-e.y+this.y0;var t,a,n,r;0<=this.ns?(a=be(e.x*e.x+e.y*e.y),t=1):(a=-be(e.x*e.x+e.y*e.y),t=-1);var s=0;if(0!==a&&(s=ue(t*e.x,t*e.y)),this.sphere)return r=Ve(this.long0+s/this.ns),n=i(this.g-a/this.a),e.x=r,e.y=n,e;var o=this.g-a/this.a;return n=ce(o,this.e0,this.e1,this.e2,this.e3),r=Ve(this.long0+s/this.ns),e.x=r,e.y=n,e},names:["Equidistant_Conic","eqdc"]},pa={init:function(){this.R=this.a},forward:function(e){var t=e.x,a=e.y,r=Ve(t-this.long0),s,i;n(a)<=ve&&(s=this.x0+this.R*r,i=this.y0);var o=Vt(2*n(a/me));(n(r)<=ve||n(n(a)-Ce)<=ve)&&(s=this.x0,i=0<=a?this.y0+me*this.R*he(.5*o):this.y0+me*this.R*-he(.5*o));var d=.5*n(me/r-r/me),l=d*d,p=ge(o),c=ye(o),u=c/(p+c-1),_=u*(2/p-1),m=_*_,f=me*this.R*(d*(u-m)+be(l*(u-m)*(u-m)-(m+l)*(u*u-m)))/(m+l);0>r&&(f=-f),s=this.x0+f;var h=l+u;return f=me*this.R*(_*h-d*be((m+l)*(l+1)-h*h))/(m+l),i=0<=a?this.y0+f:this.y0-f,e.x=s,e.y=i,e},inverse:function(e){var t,a,r,s,i,o,l,p,c,u,m,_,f;return e.x-=this.x0,e.y-=this.y0,m=me*this.R,r=e.x/m,s=e.y/m,i=r*r+s*s,o=-n(s)*(1+i),l=o-2*s*s+r*r,p=-2*o+1+2*s*s+i*i,f=s*s/p+(2*l*l*l/p/p/p-9*o*l/p/p)/27,c=(o-l*l/3/p)/p,u=2*be(-c/3),m=3*f/c/u,1<n(m)&&(0<=m?m=1:m=-1),_=pe(m)/3,a=0<=e.y?(-u*ye(_+me/3)-l/3/p)*me:-(-u*ye(_+me/3)-l/3/p)*me,t=n(r)<ve?this.long0:Ve(this.long0+me*(i-1+be(1+2*(r*r-s*s)+i*i))/2/r),e.x=t,e.y=a,e},names:["Van_der_Grinten_I","VanDerGrinten","vandg"]},ca={init:function(){this.sin_p12=ge(this.lat0),this.cos_p12=ye(this.lat0)},forward:function(e){var t=e.x,a=e.y,r=ge(e.y),i=ye(e.y),o=Ve(t-this.long0),d,l,p,u,m,_,f,h,g,y,b,x,w,E,C,A,S,k,v,I,R,O,z;return this.sphere?n(this.sin_p12-1)<=ve?(e.x=this.x0+this.a*(Ce-a)*ge(o),e.y=this.y0-this.a*(Ce-a)*ye(o),e):n(this.sin_p12+1)<=ve?(e.x=this.x0+this.a*(Ce+a)*ge(o),e.y=this.y0+this.a*(Ce+a)*ye(o),e):(k=this.sin_p12*r+this.cos_p12*i*ye(o),A=pe(k),S=A/ge(A),e.x=this.x0+this.a*S*i*ge(o),e.y=this.y0+this.a*S*(this.cos_p12*r-this.sin_p12*i*ye(o)),e):(d=Ut(this.es),l=Ft(this.es),p=Mt(this.es),u=Gt(this.es),n(this.sin_p12-1)<=ve?(m=this.a*jt(d,l,p,u,Ce),_=this.a*jt(d,l,p,u,a),e.x=this.x0+(m-_)*ge(o),e.y=this.y0-(m-_)*ye(o),e):n(this.sin_p12+1)<=ve?(m=this.a*jt(d,l,p,u,Ce),_=this.a*jt(d,l,p,u,a),e.x=this.x0+(m+_)*ge(o),e.y=this.y0+(m+_)*ye(o),e):(f=r/i,h=Zt(this.a,this.e,this.sin_p12),g=Zt(this.a,this.e,r),y=_e((1-this.es)*f+this.es*h*this.sin_p12/(g*i)),b=ue(ge(o),this.cos_p12*he(y)-this.sin_p12*ye(o)),v=0===b?le(this.cos_p12*ge(y)-this.sin_p12*ye(y)):n(n(b)-me)<=ve?-le(this.cos_p12*ge(y)-this.sin_p12*ye(y)):le(ge(o)*ye(y)/ge(b)),x=this.e*this.sin_p12/be(1-this.es),w=this.e*this.cos_p12*ye(b)/be(1-this.es),E=x*w,C=w*w,I=v*v,R=I*v,O=R*v,z=O*v,A=h*v*(1-I*C*(1-C)/6+R/8*E*(1-2*C)+O/120*(C*(4-7*C)-3*x*x*(1-7*C))-z/48*E),e.x=this.x0+A*ge(b),e.y=this.y0+A*ye(b),e))},inverse:function(e){e.x-=this.x0,e.y-=this.y0;var t,a,r,s,i,d,l,p,c,u,m,_,f,h,g,y,b,x,w,E,C,S,k;return this.sphere?(t=be(e.x*e.x+e.y*e.y),t>2*Ce*this.a)?void 0:(a=t/this.a,r=ge(a),s=ye(a),i=this.long0,n(t)<=ve?d=this.lat0:(d=Vt(s*this.sin_p12+e.y*r*this.cos_p12/t),l=n(this.lat0)-Ce,i=n(l)<=ve?0<=this.lat0?Ve(this.long0+ue(e.x,-e.y)):Ve(this.long0-ue(-e.x,e.y)):Ve(this.long0+ue(e.x*r,t*this.cos_p12*s-e.y*this.sin_p12*r))),e.x=i,e.y=d,e):(p=Ut(this.es),c=Ft(this.es),u=Mt(this.es),m=Gt(this.es),n(this.sin_p12-1)<=ve?(_=this.a*jt(p,c,u,m,Ce),t=be(e.x*e.x+e.y*e.y),f=_-t,d=ce(f/this.a,p,c,u,m),i=Ve(this.long0+ue(e.x,-1*e.y)),e.x=i,e.y=d,e):n(this.sin_p12+1)<=ve?(_=this.a*jt(p,c,u,m,Ce),t=be(e.x*e.x+e.y*e.y),f=t-_,d=ce(f/this.a,p,c,u,m),i=Ve(this.long0+ue(e.x,e.y)),e.x=i,e.y=d,e):(t=be(e.x*e.x+e.y*e.y),y=ue(e.x,e.y),h=Zt(this.a,this.e,this.sin_p12),b=ye(y),x=this.e*this.cos_p12*b,w=-x*x/(1-this.es),E=3*this.es*(1-w)*this.sin_p12*this.cos_p12*b/(1-this.es),C=t/h,S=C-w*(1+w)*o(C,3)/6-E*(1+3*w)*o(C,4)/24,k=1-w*S*S/2-C*S*S*S/6,g=le(this.sin_p12*ye(S)+this.cos_p12*ge(S)*b),i=Ve(this.long0+le(ge(y)*ge(S)/ye(g))),d=_e((1-this.es*k*this.sin_p12/ge(g))*he(g)/(1-this.es)),e.x=i,e.y=d,e))},names:["Azimuthal_Equidistant","aeqd"]},ua={init:function(){this.sin_p14=ge(this.lat0),this.cos_p14=ye(this.lat0)},forward:function(e){var t=e.x,a=e.y,r,s,i,o,d,l,p,c;return i=Ve(t-this.long0),r=ge(a),s=ye(a),o=ye(i),l=this.sin_p14*r+this.cos_p14*s*o,d=1,(0<l||n(l)<=ve)&&(p=this.a*d*s*ge(i),c=this.y0+this.a*d*(this.cos_p14*r-this.sin_p14*s*o)),e.x=p,e.y=c,e},inverse:function(e){var t,a,r,s,i,o,d;return(e.x-=this.x0,e.y-=this.y0,t=be(e.x*e.x+e.y*e.y),a=Vt(t/this.a),r=ge(a),s=ye(a),o=this.long0,n(t)<=ve)?(d=this.lat0,e.x=o,e.y=d,e):(d=Vt(s*this.sin_p14+e.y*r*this.cos_p14/t),i=n(this.lat0)-Ce,n(i)<=ve)?(o=0<=this.lat0?Ve(this.long0+ue(e.x,-e.y)):Ve(this.long0-ue(-e.x,e.y)),e.x=o,e.y=d,e):(o=Ve(this.long0+ue(e.x*r,t*this.cos_p14*s-e.y*this.sin_p14*r)),e.x=o,e.y=d,e)},names:["ortho"]},ma={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},_a={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4},fa={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.face=this.lat0>=Ce-Oe/2?ma.TOP:this.lat0<=-(Ce-Oe/2)?ma.BOTTOM:n(this.long0)<=Oe?ma.FRONT:n(this.long0)<=Ce+Oe?0<this.long0?ma.RIGHT:ma.LEFT:ma.BACK,0!==this.es&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)},forward:function(e){var a={x:0,y:0},n={value:0},i,o,d,l,p,c;if(e.x-=this.long0,i=0===this.es?e.y:_e(this.one_minus_f_squared*he(e.y)),o=e.x,this.face===ma.TOP)l=Ce-i,o>=Oe&&o<=Ce+Oe?(n.value=_a.AREA_0,d=o-Ce):o>Ce+Oe||o<=-(Ce+Oe)?(n.value=_a.AREA_1,d=0<o?o-Le:o+Le):o>-(Ce+Oe)&&o<=-Oe?(n.value=_a.AREA_2,d=o+Ce):(n.value=_a.AREA_3,d=o);else if(this.face===ma.BOTTOM)l=Ce+i,o>=Oe&&o<=Ce+Oe?(n.value=_a.AREA_0,d=-o+Ce):o<Oe&&o>=-Oe?(n.value=_a.AREA_1,d=-o):o<-Oe&&o>=-(Ce+Oe)?(n.value=_a.AREA_2,d=-o-Ce):(n.value=_a.AREA_3,d=0<o?-o+Le:-o-Le);else{var u,m,_,f,h,g,y;this.face===ma.RIGHT?o=oe(o,+Ce):this.face===ma.BACK?o=oe(o,+Le):this.face===ma.LEFT&&(o=oe(o,-Ce)),f=ge(i),h=ye(i),g=ge(o),y=ye(o),u=h*y,m=h*g,_=f,this.face===ma.FRONT?(l=pe(u),d=ie(l,_,m,n)):this.face===ma.RIGHT?(l=pe(m),d=ie(l,_,-u,n)):this.face===ma.BACK?(l=pe(-u),d=ie(l,_,-m,n)):this.face===ma.LEFT?(l=pe(-m),d=ie(l,_,u,n)):(l=d=0,n.value=_a.AREA_0)}return c=_e(12/Le*(d+pe(ge(d)*ye(Oe))-Ce)),p=be((1-ye(l))/(ye(c)*ye(c))/(1-ye(_e(1/ye(d))))),n.value===_a.AREA_1?c+=Ce:n.value===_a.AREA_2?c+=Le:n.value===_a.AREA_3&&(c+=1.5*Le),a.x=p*ye(c),a.y=p*ge(c),a.x=a.x*this.a+this.x0,a.y=a.y*this.a+this.y0,e.x=a.x,e.y=a.y,e},inverse:function(e){var a={lam:0,phi:0},i={value:0},o,d,l,p,c,u,m,_,f;if(e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,d=_e(be(e.x*e.x+e.y*e.y)),o=ue(e.y,e.x),0<=e.x&&e.x>=n(e.y)?i.value=_a.AREA_0:0<=e.y&&e.y>=n(e.x)?(i.value=_a.AREA_1,o-=Ce):0>e.x&&-e.x>=n(e.y)?(i.value=_a.AREA_2,o=0>o?o+Le:o-Le):(i.value=_a.AREA_3,o+=Ce),f=Le/12*he(o),c=ge(f)/(ye(f)-1/be(2)),u=_e(c),l=ye(o),p=he(d),m=1-l*l*p*p*(1-ye(_e(1/ye(u)))),-1>m?m=-1:1<m&&(m=1),this.face===ma.TOP)_=pe(m),a.phi=Ce-_,a.lam=i.value===_a.AREA_0?u+Ce:i.value===_a.AREA_1?0>u?u+Le:u-Le:i.value===_a.AREA_2?u-Ce:u;else if(this.face===ma.BOTTOM)_=pe(m),a.phi=_-Ce,a.lam=i.value===_a.AREA_0?-u+Ce:i.value===_a.AREA_1?-u:i.value===_a.AREA_2?-u-Ce:0>u?-u-Le:-u+Le;else{var h,g,y;h=m,f=h*h,y=1<=f?0:be(1-f)*ge(u),f+=y*y,g=1<=f?0:be(1-f),i.value===_a.AREA_1?(f=g,g=-y,y=f):i.value===_a.AREA_2?(g=-g,y=-y):i.value===_a.AREA_3&&(f=g,g=y,y=-f),this.face===ma.RIGHT?(f=h,h=-g,g=f):this.face===ma.BACK?(h=-h,g=-g):this.face===ma.LEFT&&(f=h,h=g,g=-f),a.phi=pe(-y)-Ce,a.lam=ue(g,h),this.face===ma.RIGHT?a.lam=oe(a.lam,-Ce):this.face===ma.BACK?a.lam=oe(a.lam,-Le):this.face===ma.LEFT&&(a.lam=oe(a.lam,+Ce))}if(0!==this.es){var b,x,w;b=0>a.phi?1:0,x=he(a.phi),w=this.b/be(x*x+this.one_minus_f_squared),a.phi=_e(be(this.a*this.a-w*w)/(this.one_minus_f*w)),b&&(a.phi=-a.phi)}return a.lam+=this.long0,e.x=a.lam,e.y=a.phi,e},names:["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"]},ha=[[1,22199e-21,-715515e-10,31103e-10],[.9986,-482243e-9,-24897e-9,-13309e-10],[.9954,-83103e-8,-448605e-10,-9.86701e-7],[.99,-.00135364,-59661e-9,36777e-10],[.9822,-.00167442,-449547e-11,-572411e-11],[.973,-.00214868,-903571e-10,1.8736e-8],[.96,-.00305085,-900761e-10,164917e-11],[.9427,-.00382792,-653386e-10,-26154e-10],[.9216,-.00467746,-10457e-8,481243e-11],[.8962,-.00536223,-323831e-10,-543432e-11],[.8679,-.00609363,-113898e-9,332484e-11],[.835,-.00698325,-640253e-10,9.34959e-7],[.7986,-.00755338,-500009e-10,9.35324e-7],[.7597,-.00798324,-35971e-9,-227626e-11],[.7186,-.00851367,-701149e-10,-86303e-10],[.6732,-.00986209,-199569e-9,191974e-10],[.6213,-.010418,883923e-10,624051e-11],[.5722,-.00906601,182e-6,624051e-11],[.5322,-.00677797,275608e-9,624051e-11]],ga=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-1.26793e-9,422642e-15],[.124,.0124,5.07171e-9,-1.60604e-9],[.186,.0123999,-1.90189e-8,6.00152e-9],[.248,.0124002,7.10039e-8,-2.24e-8],[.31,.0123992,-2.64997e-7,8.35986e-8],[.372,.0124029,9.88983e-7,-3.11994e-7],[.434,.0123893,-369093e-11,-4.35621e-7],[.4958,.0123198,-102252e-10,-3.45523e-7],[.5571,.0121916,-154081e-10,-5.82288e-7],[.6176,.0119938,-241424e-10,-5.25327e-7],[.6769,.011713,-320223e-10,-5.16405e-7],[.7346,.0113541,-397684e-10,-6.09052e-7],[.7903,.0109107,-489042e-10,-104739e-11],[.8435,.0103431,-64615e-9,-1.40374e-9],[.8936,.00969686,-64636e-9,-8547e-9],[.9394,.00840947,-192841e-9,-42106e-10],[.9761,.00616527,-256e-6,-42106e-10],[1,.00328947,-319159e-9,-42106e-10]],ya=.8487,ba=1.3523,xa=Re/5,wa=function(e,t){return e[0]+t*(e[1]+t*(e[2]+t*e[3]))},Ea=function(e,t){return e[1]+t*(2*e[2]+3*t*e[3])},Ca={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.long0=this.long0||0,this.es=0,this.title=this.title||"Robinson"},forward:function(e){var t=Ve(e.x-this.long0),a=n(e.y),s=r(a*xa);0>s?s=0:18<=s&&(s=17),a=Re*(a-1/xa*s);var o={x:wa(ha[s],a)*t,y:wa(ga[s],a)};return 0>e.y&&(o.y=-o.y),o.x=o.x*this.a*ya+this.x0,o.y=o.y*this.a*ba+this.y0,o},inverse:function(e){var a={x:(e.x-this.x0)/(this.a*ya),y:n(e.y-this.y0)/(this.a*ba)};if(1<=a.y)a.x/=ha[18][0],a.y=0>e.y?-Ce:Ce;else{var s=r(18*a.y);for(0>s?s=0:18<=s&&(s=17);;)if(ga[s][0]>a.y)--s;else if(ga[s+1][0]<=a.y)++s;else break;var o=ga[s],d=5*(a.y-o[0])/(ga[s+1][0]-o[0]);d=de(function(e){return(wa(o,e)-a.y)/Ea(o,e)},d,ve,100),a.x/=wa(ha[s],d),a.y=(5*s+d)*Ie,0>e.y&&(a.y=-a.y)}return a.x=Ve(a.x+this.long0),a},names:["Robinson","robin"]},Aa={init:function(){this.name="geocent"},forward:function(e){var t=z(e,this.es,this.a);return t},inverse:function(e){var t=L(e,this.es,this.a,this.b);return t},names:["Geocentric","geocentric","geocent","Geocent"]};return M.defaultDatum="WGS84",M.Proj=R,M.WGS84=new M.Proj("WGS84"),M.Point=ne,M.toPoint=lt,M.defs=f,M.transform=j,M.mgrs={forward:G,inverse:function(e){var t=K($(e.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat,t.lon,t.lat]:[t.left,t.bottom,t.right,t.top]},toPoint:Z},M.version="2.6.1",function(e){e.Proj.projections.add(yt),e.Proj.projections.add(vt),e.Proj.projections.add(Rt),e.Proj.projections.add(Lt),e.Proj.projections.add(Tt),e.Proj.projections.add(Bt),e.Proj.projections.add(Pt),e.Proj.projections.add(Nt),e.Proj.projections.add(Dt),e.Proj.projections.add(Ee),e.Proj.projections.add(Jt),e.Proj.projections.add($t),e.Proj.projections.add(ea),e.Proj.projections.add(aa),e.Proj.projections.add(na),e.Proj.projections.add(ra),e.Proj.projections.add(sa),e.Proj.projections.add(ia),e.Proj.projections.add(oa),e.Proj.projections.add(da),e.Proj.projections.add(la),e.Proj.projections.add(pa),e.Proj.projections.add(ca),e.Proj.projections.add(ua),e.Proj.projections.add(fa),e.Proj.projections.add(Ca),e.Proj.projections.add(Aa)}(M),M})},{}],56:[function(e,t,a){function n(e){if(e&&!d(e))throw new Error("Unknown encoding: "+e)}function r(e){return e.toString(this.encoding)}function s(e){this.charReceived=e.length%2,this.charLength=this.charReceived?2:0}function i(e){this.charReceived=e.length%3,this.charLength=this.charReceived?3:0}var o=e("buffer").Buffer,d=o.isEncoding||function(e){switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1;}},l=a.StringDecoder=function(e){switch(this.encoding=(e||"utf8").toLowerCase().replace(/[-_]/,""),n(e),this.encoding){case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=s;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=i;break;default:return void(this.write=r);}this.charBuffer=new o(6),this.charReceived=0,this.charLength=0};l.prototype.write=function(e){for(var t="",a;this.charLength;){if(a=e.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:e.length,e.copy(this.charBuffer,this.charReceived,0,a),this.charReceived+=a,this.charReceived<this.charLength)return"";e=e.slice(a,e.length),t=this.charBuffer.slice(0,this.charLength).toString(this.encoding);var n=t.charCodeAt(t.length-1);if(55296<=n&&56319>=n){this.charLength+=this.surrogateSize,t="";continue}if(this.charReceived=this.charLength=0,0===e.length)return t;break}this.detectIncompleteChar(e);var r=e.length;this.charLength&&(e.copy(this.charBuffer,0,e.length-this.charReceived,r),r-=this.charReceived),t+=e.toString(this.encoding,0,r);var r=t.length-1,n=t.charCodeAt(r);if(55296<=n&&56319>=n){var s=this.surrogateSize;return this.charLength+=s,this.charReceived+=s,this.charBuffer.copy(this.charBuffer,s,0,s),e.copy(this.charBuffer,0,0,s),t.substring(0,r)}return t},l.prototype.detectIncompleteChar=function(e){for(var t=3<=e.length?3:e.length;0<t;t--){var a=e[e.length-t];if(1==t&&6==a>>5){this.charLength=2;break}if(2>=t&&14==a>>4){this.charLength=3;break}if(3>=t&&30==a>>3){this.charLength=4;break}}this.charReceived=t},l.prototype.end=function(e){var t="";if(e&&e.length&&(t=this.write(e)),this.charReceived){var a=this.charReceived,n=this.charBuffer,r=this.encoding;t+=n.slice(0,a).toString(r)}return t}},{buffer:7}],57:[function(e,t){t.exports=e("./lib/encoding.js")},{"./lib/encoding.js":58}],58:[function(e,t){(function(a){'use strict';function n(e,t,a){return t<=e&&e<=a}function s(e,t){return-1!==e.indexOf(t)}function i(e){if(e===void 0)return{};if(e===Object(e))return e;throw TypeError("Could not convert argument to dictionary")}function o(e){for(var t=e+"",a=t.length,n=0,r=[];n<a;){var s=t.charCodeAt(n);if(55296>s||57343<s)r.push(s);else if(56320<=s&&57343>=s)r.push(65533);else if(55296<=s&&56319>=s)if(n===a-1)r.push(65533);else{var o=t.charCodeAt(n+1);if(56320<=o&&57343>=o){r.push(65536+((1023&s)<<10)+(1023&o)),n+=1}else r.push(65533)}n+=1}return r}function l(e){for(var t="",a=0,n;a<e.length;++a)n=e[a],65535>=n?t+=d(n):(n-=65536,t+=d((n>>10)+55296,(1023&n)+56320));return t}function p(e){return 0<=e&&127>=e}function c(e){this.tokens=[].slice.call(e),this.tokens.reverse()}function u(e,t){if(e)throw TypeError("Decoder error");return t||65533}function m(e){throw TypeError("The code point "+e+" could not be encoded.")}function _(e){return e=(e+"").trim().toLowerCase(),Object.prototype.hasOwnProperty.call(W,e)?W[e]:null}function f(e,t){return t?t[e]||null:null}function h(e,t){var a=t.indexOf(e);return-1===a?null:a}function g(e){if(!("encoding-indexes"in a))throw Error("Indexes missing. Did you forget to include encoding-indexes.js first?");return a["encoding-indexes"][e]}function y(e){if(39419<e&&189e3>e||1237575<e)return null;if(7457===e)return 59335;var t=0,a=0,n=g("gb18030-ranges"),r;for(r=0;r<n.length;++r){var s=n[r];if(s[0]<=e)t=s[0],a=s[1];else break}return a+e-t}function b(e){if(59335===e)return 7457;var t=0,a=0,n=g("gb18030-ranges"),r;for(r=0;r<n.length;++r){var s=n[r];if(s[1]<=e)t=s[1],a=s[0];else break}return a+e-t}function x(e){V=V||g("jis0208").map(function(e,t){return n(t,8272,8835)?null:e});var t=V;return t.indexOf(e)}function w(e){$=$||g("big5").map(function(e,t){return t<5024?null:e});var t=$;return 9552===e||9566===e||9569===e||9578===e||21313===e||21317===e?t.lastIndexOf(e):h(e,t)}function E(e,t){if(!(this instanceof E))throw TypeError("Called as a function. Did you forget 'new'?");e=void 0===e?"utf-8":e+"",t=i(t),this._encoding=null,this._decoder=null,this._ignoreBOM=!1,this._BOMseen=!1,this._error_mode="replacement",this._do_not_flush=!1;var a=_(e);if(null===a||"replacement"===a.name)throw RangeError("Unknown encoding: "+e);if(!J[a.name])throw Error("Decoder not present. Did you forget to include encoding-indexes.js first?");var n=this;return n._encoding=a,!!t.fatal&&(n._error_mode="fatal"),!!t.ignoreBOM&&(n._ignoreBOM=!0),Object.defineProperty||(this.encoding=n._encoding.name.toLowerCase(),this.fatal="fatal"===n._error_mode,this.ignoreBOM=n._ignoreBOM),n}function C(e,t){if(!(this instanceof C))throw TypeError("Called as a function. Did you forget 'new'?");t=i(t),this._encoding=null,this._encoder=null,this._do_not_flush=!1,this._fatal=!t.fatal?"replacement":"fatal";var n=this;if(!!t.NONSTANDARD_allowLegacyEncoding){e=void 0===e?"utf-8":e+"";var r=_(e);if(null===r||"replacement"===r.name)throw RangeError("Unknown encoding: "+e);if(!Q[r.name])throw Error("Encoder not present. Did you forget to include encoding-indexes.js first?");n._encoding=r}else n._encoding=_("utf-8"),void 0!==e&&"console"in a&&console.warn("TextEncoder constructor called with encoding label, which is ignored.");return Object.defineProperty||(this.encoding=n._encoding.name.toLowerCase()),n}function A(e){var t=e.fatal,a=0,r=0,s=0,i=128,o=191;this.handler=function(e,d){if(-1===d&&0!==s)return s=0,u(t);if(-1===d)return-1;if(0===s){if(n(d,0,127))return d;if(n(d,194,223))s=1,a=31&d;else if(n(d,224,239))224===d&&(i=160),237===d&&(o=159),s=2,a=15&d;else if(n(d,240,244))240===d&&(i=144),244===d&&(o=143),s=3,a=7&d;else return u(t);return null}if(!n(d,i,o))return a=s=r=0,i=128,o=191,e.prepend(d),u(t);if(i=128,o=191,a=a<<6|63&d,r+=1,r!==s)return null;var l=a;return a=s=r=0,l}}function S(e){e.fatal;this.handler=function(e,t){if(t===-1)return-1;if(H(t))return t;var a,r;n(t,128,2047)?(a=1,r=192):n(t,2048,65535)?(a=2,r=224):n(t,65536,1114111)&&(a=3,r=240);for(var s=[(t>>6*a)+r];0<a;){var i=t>>6*(a-1);s.push(128|63&i),a-=1}return s}}function k(e,t){var a=t.fatal;this.handler=function(t,n){if(n===-1)return-1;if(p(n))return n;var r=e[n-128];return null===r?u(a):r}}function v(e,t){t.fatal;this.handler=function(t,a){if(-1===a)return-1;if(H(a))return a;var n=h(a,e);return null===n&&m(a),n+128}}function I(e){var t=e.fatal,a=0,r=0,s=0;this.handler=function(e,i){if(i===-1&&0===a&&0===r&&0===s)return-1;i===-1&&(0!==a||0!==r||0!==s)&&(a=0,r=0,s=0,u(t));var o;if(0!==s){o=null,n(i,48,57)&&(o=y(10*(126*(10*(a-129)+r-48)+s-129)+i-48));var d=[r,s,i];return a=0,r=0,s=0,null===o?(e.prepend(d),u(t)):o}if(0!==r)return n(i,129,254)?(s=i,null):(e.prepend([r,i]),a=0,r=0,u(t));if(0!==a){if(n(i,48,57))return r=i,null;var l=a,c=null;a=0;var m=127>i?64:65;return(n(i,64,126)||n(i,128,254))&&(c=190*(l-129)+(i-m)),o=null===c?null:f(c,g("gb18030")),null===o&&p(i)&&e.prepend(i),null===o?u(t):o}return p(i)?i:128===i?8364:n(i,129,254)?(a=i,null):u(t)}}function R(e,t){e.fatal;this.handler=function(e,a){if(a===-1)return-1;if(H(a))return a;if(58853===a)return m(a);if(t&&8364===a)return 128;var n=h(a,g("gb18030"));if(null!==n){var r=q(n/190)+129,s=n%190,i=63>s?64:65;return[r,s+i]}if(t)return m(a);n=b(a);var o=q(n/10/126/10);n-=10*(126*(10*o));var d=q(n/10/126);n-=126*(10*d);var l=q(n/10),p=n-10*l;return[o+129,d+48,l+129,p+48]}}function O(e){var t=e.fatal,a=0;this.handler=function(e,r){if(-1===r&&0!==a)return a=0,u(t);if(-1===r&&0===a)return-1;if(0!==a){var s=a,i=null;a=0;var o=127>r?64:98;switch((n(r,64,126)||n(r,161,254))&&(i=157*(s-129)+(r-o)),i){case 1133:return[202,772];case 1135:return[202,780];case 1164:return[234,772];case 1166:return[234,780];}var d=null===i?null:f(i,g("big5"));return null===d&&p(r)&&e.prepend(r),null===d?u(t):d}return p(r)?r:n(r,129,254)?(a=r,null):u(t)}}function z(e){e.fatal;this.handler=function(e,t){if(t===-1)return-1;if(H(t))return t;var a=w(t);if(null===a)return m(t);var n=q(a/157)+129;if(161>n)return m(t);var r=a%157,s=63>r?64:98;return[n,r+s]}}function L(e){var t=e.fatal,a=!1,r=0;this.handler=function(e,s){if(-1===s&&0!==r)return r=0,u(t);if(-1===s&&0===r)return-1;if(142===r&&n(s,161,223))return r=0,65216+s;if(143===r&&n(s,161,254))return a=!0,r=s,null;if(0!==r){var i=r;r=0;var o=null;return n(i,161,254)&&n(s,161,254)&&(o=f(94*(i-161)+(s-161),g(a?"jis0212":"jis0208"))),a=!1,n(s,161,254)||e.prepend(s),null===o?u(t):o}return p(s)?s:142===s||143===s||n(s,161,254)?(r=s,null):u(t)}}function T(e){e.fatal;this.handler=function(e,t){if(t===-1)return-1;if(H(t))return t;if(165===t)return 92;if(8254===t)return 126;if(n(t,65377,65439))return[142,t-65377+161];8722===t&&(t=65293);var a=h(t,g("jis0208"));if(null===a)return m(t);var r=q(a/94)+161;return[r,a%94+161]}}function B(e){var t=e.fatal,a={ASCII:0,Roman:1,Katakana:2,LeadByte:3,TrailByte:4,EscapeStart:5,Escape:6},r=a.ASCII,s=a.ASCII,i=0,o=!1;this.handler=function(e,d){switch(r){default:case a.ASCII:return 27===d?(r=a.EscapeStart,null):n(d,0,127)&&14!==d&&15!==d&&27!==d?(o=!1,d):-1===d?-1:(o=!1,u(t));case a.Roman:return 27===d?(r=a.EscapeStart,null):92===d?(o=!1,165):126===d?(o=!1,8254):n(d,0,127)&&14!==d&&15!==d&&27!==d&&92!==d&&126!==d?(o=!1,d):-1===d?-1:(o=!1,u(t));case a.Katakana:return 27===d?(r=a.EscapeStart,null):n(d,33,95)?(o=!1,65344+d):-1===d?-1:(o=!1,u(t));case a.LeadByte:return 27===d?(r=a.EscapeStart,null):n(d,33,126)?(o=!1,i=d,r=a.TrailByte,null):-1===d?-1:(o=!1,u(t));case a.TrailByte:if(27===d)return r=a.EscapeStart,u(t);if(n(d,33,126)){r=a.LeadByte;var l=94*(i-33)+d-33,p=f(l,g("jis0208"));return null===p?u(t):p}return-1===d?(r=a.LeadByte,e.prepend(d),u(t)):(r=a.LeadByte,u(t));case a.EscapeStart:return 36===d||40===d?(i=d,r=a.Escape,null):(e.prepend(d),o=!1,r=s,u(t));case a.Escape:var c=i;i=0;var m=null;if(40===c&&66===d&&(m=a.ASCII),40===c&&74===d&&(m=a.Roman),40===c&&73===d&&(m=a.Katakana),36===c&&(64===d||66===d)&&(m=a.LeadByte),null!==m){r=r=m;var _=o;return o=!0,_?u(t):null}return e.prepend([c,d]),o=!1,r=s,u(t);}}}function P(e){var t=e.fatal,a={ASCII:0,Roman:1,jis0208:2},n=a.ASCII;this.handler=function(e,t){if(-1===t&&n!==a.ASCII)return e.prepend(t),n=a.ASCII,[27,40,66];if(-1===t&&n===a.ASCII)return-1;if((n===a.ASCII||n===a.Roman)&&(14===t||15===t||27===t))return m(65533);if(n===a.ASCII&&H(t))return t;if(n===a.Roman&&(H(t)&&92!==t&&126!==t||165==t||8254==t)){if(H(t))return t;if(165===t)return 92;if(8254===t)return 126}if(H(t)&&n!==a.ASCII)return e.prepend(t),n=a.ASCII,[27,40,66];if((165===t||8254===t)&&n!==a.Roman)return e.prepend(t),n=a.Roman,[27,40,74];8722===t&&(t=65293);var r=h(t,g("jis0208"));if(null===r)return m(t);if(n!==a.jis0208)return e.prepend(t),n=a.jis0208,[27,36,66];var s=q(r/94)+33;return[s,r%94+33]}}function N(e){var t=e.fatal,a=0;this.handler=function(e,r){if(-1===r&&0!==a)return a=0,u(t);if(-1===r&&0===a)return-1;if(0!==a){var s=a,i=null;a=0;var o=127>r?64:65,d=160>s?129:193;if((n(r,64,126)||n(r,128,252))&&(i=188*(s-d)+r-o),n(i,8836,10715))return 48508+i;var l=null===i?null:f(i,g("jis0208"));return null===l&&p(r)&&e.prepend(r),null===l?u(t):l}return p(r)||128===r?r:n(r,161,223)?65216+r:n(r,129,159)||n(r,224,252)?(a=r,null):u(t)}}function D(e){e.fatal;this.handler=function(e,t){if(t===-1)return-1;if(H(t)||128===t)return t;if(165===t)return 92;if(8254===t)return 126;if(n(t,65377,65439))return t-65377+161;8722===t&&(t=65293);var a=x(t);if(null===a)return m(t);var r=q(a/188),s=31>r?129:193,i=a%188,o=63>i?64:65;return[r+s,i+o]}}function j(e){var t=e.fatal,a=0;this.handler=function(e,r){if(-1===r&&0!==a)return a=0,u(t);if(-1===r&&0===a)return-1;if(0!==a){var s=a,i=null;a=0,n(r,65,254)&&(i=190*(s-129)+(r-65));var o=null===i?null:f(i,g("euc-kr"));return null===i&&p(r)&&e.prepend(r),null===o?u(t):o}return p(r)?r:n(r,129,254)?(a=r,null):u(t)}}function U(e){e.fatal;this.handler=function(e,t){if(t===-1)return-1;if(H(t))return t;var a=h(t,g("euc-kr"));if(null===a)return m(t);var n=q(a/190)+129;return[n,a%190+65]}}function F(e,t){var a=e>>8,n=255&e;return t?[a,n]:[n,a]}function M(e,t){var a=t.fatal,r=null,s=null;this.handler=function(t,i){if(-1===i&&(null!==r||null!==s))return u(a);if(-1===i&&null===r&&null===s)return-1;if(null===r)return r=i,null;var o;if(o=e?(r<<8)+i:(i<<8)+r,r=null,null!==s){var d=s;return(s=null,n(o,56320,57343))?65536+1024*(d-55296)+(o-56320):(t.prepend(F(o,e)),u(a))}return n(o,55296,56319)?(s=o,null):n(o,56320,57343)?u(a):o}}function G(e,t){t.fatal;this.handler=function(t,a){if(a===-1)return-1;if(n(a,0,65535))return F(a,e);var r=F((a-65536>>10)+55296,e),s=F((1023&a-65536)+56320,e);return r.concat(s)}}function Z(e){e.fatal;this.handler=function(e,t){return-1===t?-1:p(t)?t:63360+t-128}}function Y(e){e.fatal;this.handler=function(e,t){return-1===t?-1:H(t)?t:n(t,63360,63487)?t-63360+128:m(t)}}"undefined"!=typeof t&&t.exports&&!a["encoding-indexes"]&&e("./encoding-indexes.js");var q=r,H=p,K=-1;c.prototype={endOfStream:function(){return!this.tokens.length},read:function(){return this.tokens.length?this.tokens.pop():K},prepend:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.push(t.pop());else this.tokens.push(e)},push:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.unshift(t.shift());else this.tokens.unshift(e)}};(function(){}).prototype={handler:function(){}},function(){}.prototype={handler:function(){}};var X=[{encodings:[{labels:["unicode-1-1-utf-8","utf-8","utf8"],name:"UTF-8"}],heading:"The Encoding"},{encodings:[{labels:["866","cp866","csibm866","ibm866"],name:"IBM866"},{labels:["csisolatin2","iso-8859-2","iso-ir-101","iso8859-2","iso88592","iso_8859-2","iso_8859-2:1987","l2","latin2"],name:"ISO-8859-2"},{labels:["csisolatin3","iso-8859-3","iso-ir-109","iso8859-3","iso88593","iso_8859-3","iso_8859-3:1988","l3","latin3"],name:"ISO-8859-3"},{labels:["csisolatin4","iso-8859-4","iso-ir-110","iso8859-4","iso88594","iso_8859-4","iso_8859-4:1988","l4","latin4"],name:"ISO-8859-4"},{labels:["csisolatincyrillic","cyrillic","iso-8859-5","iso-ir-144","iso8859-5","iso88595","iso_8859-5","iso_8859-5:1988"],name:"ISO-8859-5"},{labels:["arabic","asmo-708","csiso88596e","csiso88596i","csisolatinarabic","ecma-114","iso-8859-6","iso-8859-6-e","iso-8859-6-i","iso-ir-127","iso8859-6","iso88596","iso_8859-6","iso_8859-6:1987"],name:"ISO-8859-6"},{labels:["csisolatingreek","ecma-118","elot_928","greek","greek8","iso-8859-7","iso-ir-126","iso8859-7","iso88597","iso_8859-7","iso_8859-7:1987","sun_eu_greek"],name:"ISO-8859-7"},{labels:["csiso88598e","csisolatinhebrew","hebrew","iso-8859-8","iso-8859-8-e","iso-ir-138","iso8859-8","iso88598","iso_8859-8","iso_8859-8:1988","visual"],name:"ISO-8859-8"},{labels:["csiso88598i","iso-8859-8-i","logical"],name:"ISO-8859-8-I"},{labels:["csisolatin6","iso-8859-10","iso-ir-157","iso8859-10","iso885910","l6","latin6"],name:"ISO-8859-10"},{labels:["iso-8859-13","iso8859-13","iso885913"],name:"ISO-8859-13"},{labels:["iso-8859-14","iso8859-14","iso885914"],name:"ISO-8859-14"},{labels:["csisolatin9","iso-8859-15","iso8859-15","iso885915","iso_8859-15","l9"],name:"ISO-8859-15"},{labels:["iso-8859-16"],name:"ISO-8859-16"},{labels:["cskoi8r","koi","koi8","koi8-r","koi8_r"],name:"KOI8-R"},{labels:["koi8-ru","koi8-u"],name:"KOI8-U"},{labels:["csmacintosh","mac","macintosh","x-mac-roman"],name:"macintosh"},{labels:["dos-874","iso-8859-11","iso8859-11","iso885911","tis-620","windows-874"],name:"windows-874"},{labels:["cp1250","windows-1250","x-cp1250"],name:"windows-1250"},{labels:["cp1251","windows-1251","x-cp1251"],name:"windows-1251"},{labels:["ansi_x3.4-1968","ascii","cp1252","cp819","csisolatin1","ibm819","iso-8859-1","iso-ir-100","iso8859-1","iso88591","iso_8859-1","iso_8859-1:1987","l1","latin1","us-ascii","windows-1252","x-cp1252"],name:"windows-1252"},{labels:["cp1253","windows-1253","x-cp1253"],name:"windows-1253"},{labels:["cp1254","csisolatin5","iso-8859-9","iso-ir-148","iso8859-9","iso88599","iso_8859-9","iso_8859-9:1989","l5","latin5","windows-1254","x-cp1254"],name:"windows-1254"},{labels:["cp1255","windows-1255","x-cp1255"],name:"windows-1255"},{labels:["cp1256","windows-1256","x-cp1256"],name:"windows-1256"},{labels:["cp1257","windows-1257","x-cp1257"],name:"windows-1257"},{labels:["cp1258","windows-1258","x-cp1258"],name:"windows-1258"},{labels:["x-mac-cyrillic","x-mac-ukrainian"],name:"x-mac-cyrillic"}],heading:"Legacy single-byte encodings"},{encodings:[{labels:["chinese","csgb2312","csiso58gb231280","gb2312","gb_2312","gb_2312-80","gbk","iso-ir-58","x-gbk"],name:"GBK"},{labels:["gb18030"],name:"gb18030"}],heading:"Legacy multi-byte Chinese (simplified) encodings"},{encodings:[{labels:["big5","big5-hkscs","cn-big5","csbig5","x-x-big5"],name:"Big5"}],heading:"Legacy multi-byte Chinese (traditional) encodings"},{encodings:[{labels:["cseucpkdfmtjapanese","euc-jp","x-euc-jp"],name:"EUC-JP"},{labels:["csiso2022jp","iso-2022-jp"],name:"ISO-2022-JP"},{labels:["csshiftjis","ms932","ms_kanji","shift-jis","shift_jis","sjis","windows-31j","x-sjis"],name:"Shift_JIS"}],heading:"Legacy multi-byte Japanese encodings"},{encodings:[{labels:["cseuckr","csksc56011987","euc-kr","iso-ir-149","korean","ks_c_5601-1987","ks_c_5601-1989","ksc5601","ksc_5601","windows-949"],name:"EUC-KR"}],heading:"Legacy multi-byte Korean encodings"},{encodings:[{labels:["csiso2022kr","hz-gb-2312","iso-2022-cn","iso-2022-cn-ext","iso-2022-kr"],name:"replacement"},{labels:["utf-16be"],name:"UTF-16BE"},{labels:["utf-16","utf-16le"],name:"UTF-16LE"},{labels:["x-user-defined"],name:"x-user-defined"}],heading:"Legacy miscellaneous encodings"}],W={};X.forEach(function(e){e.encodings.forEach(function(e){e.labels.forEach(function(t){W[t]=e})})});var Q={},J={},V,$;Object.defineProperty&&(Object.defineProperty(E.prototype,"encoding",{get:function(){return this._encoding.name.toLowerCase()}}),Object.defineProperty(E.prototype,"fatal",{get:function(){return"fatal"===this._error_mode}}),Object.defineProperty(E.prototype,"ignoreBOM",{get:function(){return this._ignoreBOM}})),E.prototype.decode=function(e,t){var a;a="object"==typeof e&&e instanceof ArrayBuffer?new Uint8Array(e):"object"==typeof e&&"buffer"in e&&e.buffer instanceof ArrayBuffer?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(0),t=i(t),this._do_not_flush||(this._decoder=J[this._encoding.name]({fatal:"fatal"===this._error_mode}),this._BOMseen=!1),this._do_not_flush=!!t.stream;for(var n=new c(a),r=[],o,d;(d=n.read(),d!==K)&&!(o=this._decoder.handler(n,d),-1===o);)null!==o&&(Array.isArray(o)?r.push.apply(r,o):r.push(o));if(!this._do_not_flush){do{if(o=this._decoder.handler(n,n.read()),-1===o)break;if(null===o)continue;Array.isArray(o)?r.push.apply(r,o):r.push(o)}while(!n.endOfStream());this._decoder=null}return function(e){return!s(["UTF-8","UTF-16LE","UTF-16BE"],this._encoding.name)||this._ignoreBOM||this._BOMseen||(0<e.length&&65279===e[0]?(this._BOMseen=!0,e.shift()):0<e.length&&(this._BOMseen=!0)),l(e)}.call(this,r)},Object.defineProperty&&Object.defineProperty(C.prototype,"encoding",{get:function(){return this._encoding.name.toLowerCase()}}),C.prototype.encode=function(e,t){e=e===void 0?"":e+"",t=i(t),this._do_not_flush||(this._encoder=Q[this._encoding.name]({fatal:"fatal"===this._fatal})),this._do_not_flush=!!t.stream;for(var a=new c(o(e)),n=[],r,s;(s=a.read(),s!==K)&&!(r=this._encoder.handler(a,s),-1===r);)Array.isArray(r)?n.push.apply(n,r):n.push(r);if(!this._do_not_flush){for(;r=this._encoder.handler(a,a.read()),-1!==r;)Array.isArray(r)?n.push.apply(n,r):n.push(r);this._encoder=null}return new Uint8Array(n)},Q["UTF-8"]=function(e){return new S(e)},J["UTF-8"]=function(e){return new A(e)},function(){"encoding-indexes"in a&&X.forEach(function(e){"Legacy single-byte encodings"!==e.heading||e.encodings.forEach(function(e){var t=e.name,a=g(t.toLowerCase());J[t]=function(e){return new k(a,e)},Q[t]=function(e){return new v(a,e)}})})}(),J.GBK=function(e){return new I(e)},Q.GBK=function(e){return new R(e,!0)},Q.gb18030=function(e){return new R(e)},J.gb18030=function(e){return new I(e)},Q.Big5=function(e){return new z(e)},J.Big5=function(e){return new O(e)},Q["EUC-JP"]=function(e){return new T(e)},J["EUC-JP"]=function(e){return new L(e)},Q["ISO-2022-JP"]=function(e){return new P(e)},J["ISO-2022-JP"]=function(e){return new B(e)},Q.Shift_JIS=function(e){return new D(e)},J.Shift_JIS=function(e){return new N(e)},Q["EUC-KR"]=function(e){return new U(e)},J["EUC-KR"]=function(e){return new j(e)},Q["UTF-16BE"]=function(e){return new G(!0,e)},J["UTF-16BE"]=function(e){return new M(!0,e)},Q["UTF-16LE"]=function(e){return new G(!1,e)},J["UTF-16LE"]=function(e){return new M(!1,e)},Q["x-user-defined"]=function(e){return new Y(e)},J["x-user-defined"]=function(e){return new Z(e)},a.TextEncoder||(a.TextEncoder=C),a.TextDecoder||(a.TextDecoder=E),"undefined"!=typeof t&&t.exports&&(t.exports={TextEncoder:a.TextEncoder,TextDecoder:a.TextDecoder,EncodingIndexes:a["encoding-indexes"]})})(this||{})},{"./encoding-indexes.js":6}],59:[function(e,t){(function(a){'use strict';function n(e){if(!e)throw new Error("forgot to pass buffer");return m.isBuffer(e)?e:e instanceof a.ArrayBuffer?m.from(e):e.buffer instanceof a.ArrayBuffer?1===e.BYTES_PER_ELEMENT?m.from(e):m.from(e.buffer):void 0}function r(e,t){return"string"==typeof e&&_.has(e)?c.resolve(_.get(e)):r.getShapefile(e,t).then(function(t){return"string"==typeof e&&_.set(e,t),t})}function s(e,t){return d(e).then(function(e){return r.parseZip(e,t)})}var i=e("proj4");i.default&&(i=i.default);var o=e("./unzip"),d=e("./binaryajax"),l=e("./parseShp"),p=e("parsedbf"),c=e("lie"),u=e("lru-cache"),m=e("buffer").Buffer,_=new u({max:20});r.combine=function(e){for(var t={type:"FeatureCollection",features:[]},a=0,n=e[0].length;a<n;)t.features.push({type:"Feature",geometry:e[0][a],properties:e[1][a]}),a++;return t},r.parseZip=function(e,t){e=n(e);var a=o(e),s=[];for(var d in t=t||[],a)-1===d.indexOf("__MACOSX")&&("shp"===d.slice(-3).toLowerCase()?(s.push(d.slice(0,-4)),a[d.slice(0,-3)+d.slice(-3).toLowerCase()]=a[d]):"prj"===d.slice(-3).toLowerCase()?a[d.slice(0,-3)+d.slice(-3).toLowerCase()]=i(a[d]):"json"===d.slice(-4).toLowerCase()||-1<t.indexOf(d.split(".").pop())?s.push(d.slice(0,-3)+d.slice(-3).toLowerCase()):("dbf"===d.slice(-3).toLowerCase()||"cpg"===d.slice(-3).toLowerCase())&&(a[d.slice(0,-3)+d.slice(-3).toLowerCase()]=a[d]));if(!s.length)throw new Error("no layers founds");var c=s.map(function(e){var n=e.lastIndexOf("."),s,i;return-1<n&&-1<e.slice(n).indexOf("json")?(s=JSON.parse(a[e]),s.fileName=e.slice(0,n)):-1<t.indexOf(e.slice(n+1))?(s=a[e],s.fileName=e):(a[e+".dbf"]&&(i=p(a[e+".dbf"],a[e+".cpg"])),s=r.combine([l(a[e+".shp"],a[e+".prj"]),i]),s.fileName=e),s});return 1===c.length?c[0]:c},r.getShapefile=function(e,t){return"string"==typeof e?".zip"===e.slice(-4).toLowerCase()?s(e,t):c.all([c.all([d(e+".shp"),d(e+".prj")]).then(function(e){var t=!1;try{e[1]&&(t=i(e[1]))}catch(a){t=!1}return l(e[0],t)}),c.all([d(e+".dbf"),d(e+".cpg")]).then(function(e){return p(e[0],e[1])})]).then(r.combine):new c(function(t){t(r.parseZip(e))})},r.parseShp=function(e,t){if(e=n(e),m.isBuffer(t)&&(t=t.toString()),"string"==typeof t)try{t=i(t)}catch(a){t=!1}return l(e)},r.parseDbf=function(e,t){return e=n(e),p(e,t)},t.exports=r}).call(this,"undefined"==typeof global?"undefined"==typeof self?"undefined"==typeof window?{}:window:self:global)},{"./binaryajax":2,"./parseShp":3,"./unzip":4,buffer:7,lie:35,"lru-cache":36,parsedbf:54,proj4:55}]},{},[59])(59)})