geojs 1.14.1 → 1.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/geo.js +46 -21
- package/geo.lean.js +46 -21
- package/geo.lean.min.js +2 -2
- package/geo.min.js +2 -2
- package/package.json +4 -4
- package/src/quadFeature.js +5 -0
- package/src/trackFeature.js +2 -0
package/geo.min.js
CHANGED
|
@@ -35,7 +35,7 @@ t.exports=function(){"use strict";function t(){return t=Object.assign||function(
|
|
|
35
35
|
* @copyright 2017, Vladimir Agafonkin
|
|
36
36
|
* @license ISC
|
|
37
37
|
*/
|
|
38
|
-
var r=n(5616),i=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi;r.htmlPrefilter=function(t){return t.replace(i,"<$1></$2>")},n(7605),t.exports=Object.assign({annotationLayer:n(2075),camera:n(3578),choroplethFeature:n(3561),contourFeature:n(6761),domRenderer:n(9726),event:n(6409),feature:n(1275),featureLayer:n(6498),fetchQueue:n(5938),fileReader:n(3084),geo_action:n(8695),graphFeature:n(3187),heatmapFeature:n(9163),imageTile:n(4912),isolineFeature:n(2586),geojsonReader:n(5173),gridFeature:n(2499),layer:n(5156),lineFeature:n(9281),map:n(6211),mapInteractor:n(7908),markerFeature:n(2225),meshFeature:n(6124),object:n(1338),osmLayer:n(4880),pathFeature:n(2266),pointFeature:n(7541),polygonFeature:n(6645),quadFeature:n(3842),pixelmapFeature:n(7761),pixelmapLayer:n(534),renderer:n(2274),sceneObject:n(5402),textFeature:n(6546),tile:n(5289),tileCache:n(9123),tileLayer:n(9264),timestamp:n(77),trackFeature:n(338),transform:n(5325),typedef:n(3170),vectorFeature:n(6858),inherit:n(4626),version:n(4081),sha:n(9079),annotation:n(4655),util:n(642),jQuery:r,canvas:n(8074),svg:n(6488),vtkjs:n(394),webgl:n(8635),gui:n(4812),vgl:n(1611)},n(1098)),window&&!window.$&&(window.$=r),window&&!window.jQuery&&(window.jQuery=r),window&&!window.geojsMap&&(window.geojsMap=function(){var t=r(".geojs-map").map((function(t,e){return r(e).data("data-geojs-map")}));return 0===t.length?void 0:1===t.length?t[0]:t})},4626:function(t){t.exports=function(t,e){var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}},2586:function(t,e,n){var r=n(4626),i=n(6124),o=n(1098),a=n(642),s={17:[{l0:1,h0:2,l1:0,h1:2}],18:[{l0:0,h0:1,l1:2,h1:1}],20:[{l0:2,h0:0,l1:1,h1:0}],22:[{l0:2,h0:0,l1:2,h1:1}],21:[{l0:1,h0:2,l1:1,h1:0}],19:[{l0:0,h0:1,l1:0,h1:2}],1:[{l0:2,h0:3,l1:1,h1:3}],2:[{l0:0,h0:2,l1:3,h1:2}],4:[{l0:3,h0:1,l1:0,h1:1}],8:[{l0:1,h0:0,l1:2,h1:0}],14:[{l0:3,h0:1,l1:3,h1:2}],13:[{l0:2,h0:3,l1:2,h1:0}],11:[{l0:1,h0:0,l1:1,h1:3}],7:[{l0:0,h0:2,l1:0,h1:1}],3:[{l0:0,h0:2,l1:1,h1:3}],10:[{l0:1,h0:0,l1:3,h1:2}],12:[{l0:3,h0:1,l1:2,h1:0}],5:[{l0:2,h0:3,l1:0,h1:1}],6:[{l0:0,h0:2,l1:0,h1:1},{l0:3,h0:1,l1:3,h1:2}],9:[{l0:1,h0:0,l1:1,h1:3},{l0:2,h0:3,l1:2,h1:0}]},u=function(t){"use strict";if(!(this instanceof u))return new u(t);var e=n(5325),r=n(6409),l=n(6546);t=t||{},i.call(this,t);var c,f,h,d,p,m=this,g=this.draw,y=this._exit,v=this._init,x=this.modified,_=this._update;return this.featureType="isoline",this.contour=m.mesh,this.isoline=m.mesh,this._createIsolines=function(){var t,e=m.style.get("value"),n=void 0!==m.style("used")?m.style.get("used"):function(t,n){return a.isNonNullFinite(e(t,n))},r=!1,i=[],o=m._createMesh({used:n,value:e});return(t=m._getValueList(o)).length?(t.forEach((function(t){var e=m._isolinesForValue(o,t);e.length&&(i=i.concat(e),r=r||!!t.label)})),{lines:i,mesh:o,values:t,hasLabels:r}):{}},this._getValueList=function(t){var e,n,r,i,o,s,u,l=m.isoline,c=l.get("values")(t),f=l.get("spacing")(t),h=l.get("count")(t),d=l.get("autofit")(t),p=l.get("levels")(t);if(!t.numVertices||!t.numElements)return[];if(e=a.getMinMaxValues(t.value,l.get("min")(t),l.get("max")(t),!0),t.minValue=e.min,t.maxValue=e.max,(n=t.maxValue-t.minValue)<=0)return[];if(Array.isArray(c))c=(c=c.map((function(t,e){return{value:void 0!==t.value?t.value:t,position:e,level:t.level}}))).filter((function(e){return e.value>=t.minValue&&e.value<=t.maxValue}));else if(f||d)for(f||(r=n/(2*h/3),o=Math.floor(Math.log10(r)),s=Math.max(0,-o),f=(r=(r/=i=Math.pow(10,o))>=5?5:r>=2?2:1)*i),c=[],u=Math.ceil(t.minValue/f);u<=Math.floor(t.maxValue/f);u+=1)c.push({value:u*f,position:u,fixedDigits:s});else for(c=Array(h),u=0;u<h;u+=1)c[u]={value:t.minValue+n*(u+1)/(h+1),position:u+1};return p.length&&c.forEach((function(t,e){if(void 0===t.level){t.level=0;for(var n=0,r=p[0];n<p.length&&!(t.position%r);r*=p[n+=1])t.level=n+1}if(l.get("label")(t,t.position)){var i=l.get("labelText")(t,t.position);void 0===i&&(i=void 0!==t.fixedDigits?""+parseFloat(t.value.toFixed(t.fixedDigits)):""+t.value),i&&(t.label=i)}})),c},this._addSegment=function(t,e,n){var r,i,o,a,s,u,l=[e,n],c=t.length;for(t.push(l),i=0;i<2;i+=1){for(r=c-1;r>=0;r-=1){if(a=(o=t[r])[0],s=o[o.length-1],n[0]===a[0]&&n[1]===a[1])u=l.concat(o.slice(1));else{if(e[0]!==s[0]||e[1]!==s[1])continue;u=o.concat(l.slice(1))}t.splice(c,1),t[r]=l=u,c=r,e=l[0],n=l[l.length-1];break}if(r<0)break}return t},this._chainVertex=function(t,e,n){var r=n[0],i=n[1],o=3*r,a=3*i,s=(e.value-t.value[r])/(t.value[i]-t.value[r]),u=1-s;return{x:t.pos[o]*u+t.pos[a]*s,y:t.pos[o+1]*u+t.pos[a+1]*s,z:t.pos[o+2]*u+t.pos[a+2]*s}},this._isolinesForValue=function(t,e){var n,r,i,o,a=e.value,u=Array(t.value.length),l=[];for(n=u.length-1;n>=0;n-=1)u[n]=t.value[n]<=a?0:1;var c=t.verticesPerElement,f="square"===t.shape,h=t.elements,d=h.length;for(r=0;r<d;r+=c){if(f){if(0===(i=8*u[h[r]]+4*u[h[r+1]]+2*u[h[r+2]]+u[h[r+3]])||15===i)continue}else if(16===(i=16+4*u[h[r]]+2*u[h[r+1]]+u[h[r+2]])||23===i)continue;s[i].forEach((function(t){l=m._addSegment(l,[h[r+t.l0],h[r+t.h0]],[h[r+t.l1],h[r+t.h1]])}))}return o=l.map((function(n){var r=[];return n.forEach((function(n){var i=m._chainVertex(t,e,n);r.length&&i.x===r[r.length-1].x&&i.y===r[r.length-1].y||r.push(i)})),r.closed=r[0].x===r[r.length-1].x&&r[0].y===r[r.length-1].y,r.value=e.value,r.level=e.level,r.position=e.position,r.label=e.label,r})).filter((function(t){return t.length>1})),o},this.modified=function(){var t=x();return h&&h.modified(),p&&p.modified(),t},this.labelPositions=function(){if(m.dataTime().timestamp()>=m.buildTime().timestamp()&&m._build(),f=null,!p)return m;if(!(c&&c.hasLabels&&c.lines&&c.lines.length))return p.data([]),m;var t=m.isoline,n=t.get("labelSpacing"),r=t.get("labelOffset"),i=t.get("labelViewport")(c.mesh),o=m.gcs(),s=m.layer().map(),u=s.gcs(),l=s.rotation(),h=s.size(),d=[],g=0;return c.lines.forEach((function(t,c){if(t.label){var f,p,m,y,v,x,_,b,w,M,A,T=n(t.value,t.value.position),E=r(t.value,t.value.position)||0,C=s.gcsToDisplay(t,o),k=0;if(!(T<=0||isNaN(T))&&(g=Math.max(T,g),E=E+.5-Math.floor(E+.5),f=C.map((function(e,n){if(!t.closed&&n+1===C.length)return 0;var r=Math.sqrt(a.distance2dSquared(e,C[n+1<C.length?n+1:0]));return k+=r,r})),p=Math.floor(k/T)))for(A=e.transformCoordinates(o,u,t),y=(m=k/p)*E,v=0,x=0;x<C.length;x+=1){for(;v+f[x]>=y;)_=x+1===C.length?0:x+1,w=1-(b=(y-v)/f[x]),y+=m,i>0&&((M={x:C[x].x*w+C[_].x*b,y:C[x].y*w+C[_].y*b}).x<-i||M.x>h.width+i||M.y<-i||M.y>h.height+i)||d.push({x:A[x].x*w+A[_].x*b,y:A[x].y*w+A[_].y*b,z:A[x].z*w+A[_].z*b,line:t,rotation:Math.atan2(C[x].y-C[_].y,C[x].x-C[_].x)-l});v+=f[x]}}})),p.gcs(u),p.data(d),p.style("renderThreshold",2*g),f={zoom:s.zoom(),center:s.center(),rotation:l,size:h,labelViewport:i,maxSpacing:g,labelAutoUpdate:t.get("labelAutoUpdate")(c.mesh)},m},this.lastLabelPositions=function(){return Object.assign({},f)},this._updateLabelPositions=function(){var t=f;if(!t||!t.labelAutoUpdate)return m;var e=m.layer().map(),n=e.zoom(),r=e.size(),i=!!(Math.abs(n-t.zoom)>=2);if(!i&&t.labelViewport>0){var o=Math.sqrt(a.distance2dSquared(e.gcsToDisplay(e.center()),e.gcsToDisplay(t.center)))*Math.pow(2,t.zoom-n),s=t.labelViewport/2-2*t.maxSpacing-Math.max(r.width-t.size.width,r.height-t.size.height,0);i=i||o>=s}return i&&m.labelPositions().draw(),m},this._build=function(){if((c=m._createIsolines())&&c.lines&&c.lines.length){h||(h=m.layer().createFeature("line",{selectionAPI:!1,gcs:m.gcs(),visible:m.visible(void 0,!0),style:{closed:function(t){return t.closed}}}),m.dependentFeatures([h]));var t=m.style();if(h.data(c.lines).style({antialiasing:t.antialiasing,lineCap:t.lineCap,lineJoin:t.lineJoin,miterLimit:t.miterLimit,strokeWidth:t.strokeWidth,strokeStyle:t.strokeStyle,strokeColor:t.strokeColor,strokeOffset:t.strokeOffset,strokeOpacity:t.strokeOpacity}),c.hasLabels){if(!p){if(!(o.registries.features[m.layer().rendererName()]||{}).text){var e=o.rendererForFeatures(["text"]);d=o.createLayer("feature",m.layer().map(),{renderer:e}),m.layer().addChild(d),m.layer().node().append(d.node())}p=(d||m.layer()).createFeature("text",{selectionAPI:!1,gcs:m.gcs(),visible:m.visible(void 0,!0),style:{text:function(t){return t.line.label}}}).geoOn(r.pan,m._updateLabelPositions)}l.usedStyles.forEach((function(e){"visible"!==e&&p.style(e,t[e])})),m.dependentFeatures([h,p])}}else h&&h.data([]);return m.buildTime().modified(),m.labelPositions(),m},this._update=function(){return _.call(m),(m.dataTime().timestamp()>=m.buildTime().timestamp()||m.updateTime().timestamp()<=m.timestamp())&&m._build(),m.updateTime().modified(),m},this.draw=function(){var t=g();return h&&h.draw(),p&&p.draw(),t},this._exit=function(){p&&((d||m.layer())&&(d||m.layer()).deleteFeature(p),d&&m.layer()&&m.layer().removeChild(d)),h&&m.layer()&&m.layer().deleteFeature(h),p=null,d=null,h=null,m.dependentFeatures([]),y()},this._init=function(t){t=t||{},v.call(m,t);var e=Object.assign({},{opacity:1,value:function(t,e){return m.position()(t,e).z},rotateWithMap:!0,rotation:u.rotationFunction(),strokeWidth:function(t,e,n,r){return n.level+.5},strokeColor:{r:0,g:0,b:0},textStrokeColor:{r:1,g:1,b:1,a:.75},textStrokeWidth:2,fontSize:"12px"},void 0===t.style?{}:t.style);m.style(e),m.isoline(Object.assign({},{count:15,autofit:!0,levels:[5,5],label:function(t){return t.level>=1},labelSpacing:200,labelViewport:1e4,labelAutoUpdate:!0},t.mesh||{},t.contour||{},t.isoline||{})),(t.mesh||t.contour||t.isoline)&&m.dataTime().modified()},this};u.rotationFunction=function(t,e){var n={higher:function(t){return t.rotation},lower:function(t){return t.rotation+Math.PI},map:function(t){var e=t.rotation,n=a.wrapAngle(e,!0);return(n>Math.PI/2||n<-Math.PI/2)&&(e+=Math.PI),e},screen:function(t){var n=t.rotation,r=a.wrapAngle(n+e.rotation(),!0);return(r>Math.PI/2||r<-Math.PI/2)&&(n+=Math.PI),n}};return n[t]||n.higher},r(u,i),t.exports=u},5156:function(t,e,n){var r=n(4626),i=n(5402),o=n(1275),a=n(1098).checkRenderer,s=n(1098).rendererForFeatures,u=n(1098).rendererForAnnotations,l=function(t){"use strict";if(!(this instanceof l))return new l(t);t=t||{},i.call(this,t);var e,r=n(5616),o=n(77),c=n(2274),f=n(1098).createRenderer,h=n(1098).adjustLayerForRenderer,d=n(6409),p=this,m=this._exit,g=void 0===t.id?l.newLayerId():t.id,y=void 0===t.name?"":t.name,v=void 0===t.map?null:t.map,x=null,_=void 0===t.canvas?null:t.canvas,b=t.renderer instanceof c?t.renderer:null,w=!1,M=void 0!==t.renderer?t.renderer instanceof c?t.renderer.api():t.renderer:t.annotations?u(t.annotations):s(t.features),A=void 0===t.autoshareRenderer||t.autoshareRenderer,T=o(),E=o(),C=void 0===t.sticky||t.sticky,k=void 0===t.active||t.active,S=void 0===t.opacity?1:t.opacity,O=t.attribution||null,P=void 0===t.visible||t.visible,L=void 0===t.selectionAPI||t.selectionAPI;if(M=a(M),!v)throw new Error("Layers must be initialized on a map.");function R(){return(p.parent()||p.map()).children().filter((function(t){return t instanceof l}))}if(this.rendererName=function(){return M},this.autoshareRenderer=function(){return A},this.zIndex=function(t,n){return void 0===t?e:(n||R().reverse().forEach((function(e){e!==p&&e.zIndex()===t&&e.zIndex(t+1)})),t!==e&&(e=t,x.css("z-index",e),p.geoTrigger(d.layerMove,{layer:p})),p)},this.moveUp=function(t){var e,n,r,i,o=null;for(void 0===t&&(t=1),i=1,t<0&&(i=-1,t=-t),e=R().sort((function(t,e){return i*(t.zIndex()-e.zIndex())})),n=0;n<e.length;n+=1)if(null===o)e[n]===p&&(o=n);else{if(!(n-o<=t))break;r=p.zIndex(),p.zIndex(e[n].zIndex(),!0),e[n].zIndex(r,!0)}return p},this.moveDown=function(t){return void 0===t&&(t=1),p.moveUp(-t)},this.moveToTop=function(){return p.moveUp(R().length-1)},this.moveToBottom=function(){return p.moveDown(R().length-1)},this.sticky=function(){return C},this.active=function(t){return void 0===t?k:(k!==t&&(k=t,x.toggleClass("active",k)),p)},this.node=function(){return x},this.id=function(t){return void 0===t?g:(g=null===t?l.newLayerId():t,p.modified(),p)},this.name=function(t){return void 0===t?y:(y=t,x.attr("id",y),p.modified(),p)},this.map=function(){return v},this.renderer=function(){return b},this._renderer=function(t){return void 0===t?b:(b=t,p)},this.canvas=function(){return _},this._canvas=function(t){return void 0===t?_:(_=t,p)},this.dataTime=function(){return T},this.updateTime=function(){return E},this.initialized=function(t){return void 0!==t?(w=t,p):w},this.toLocal=function(t){return t},this.fromLocal=function(t){return t},this.attribution=function(t){return void 0!==t?(O=t,p.map().updateAttribution(),p):O},this.visible=function(t){return void 0===t?P:(P!==t&&(P=t,x.toggleClass("hidden",!P),p.modified()),p)},this.selectionAPI=function(t){return void 0===t?L:(L!==t&&(L=t),p)},this._init=function(e){if(w)return p;v.node().append(x);var n=Object.assign({},t);return delete n.map,b?p._canvas(b.canvas()):null===M?(p._renderer(null),p._canvas(x)):_?p._renderer(f(M,p,_,n)):(p._renderer(f(M,p,void 0,n)),p._canvas(b.canvas())),x.toggleClass("active",p.active()),w=!0,e||(p.geoOn(d.resize,(function(t){p._update({event:t})})),p.geoOn(d.pan,(function(t){p._update({event:t})})),p.geoOn(d.rotate,(function(t){p._update({event:t})})),p.geoOn(d.zoom,(function(t){p._update({event:t})}))),p},this._exit=function(){p.geoOff(),b&&b._exit(),x.off(),x.remove(),t={},p._canvas(null),p._renderer(null),m()},this._update=function(t){return p},this.width=function(){return p.map().size().width},this.height=function(){return p.map().size().height},this.opacity=function(t){return void 0!==t?(S=t,x.css("opacity",S),p):S},(x=r(document.createElement("div"))).addClass("geojs-layer"),x.attr("renderer",M),y&&x.attr("id",y),p.opacity(S),p.visible(P),void 0===t.zIndex){var I=-1;R().forEach((function(t){void 0!==t.zIndex()&&(I=Math.max(I,t.zIndex()))})),t.zIndex=I+1}return p.zIndex(t.zIndex),h("all",p),p};l.newLayerId=function(){"use strict";var t=1;return function(){var e=t;return t+=1,e}}(),l.create=function(t,e){"use strict";if((e=e||{}).type=e.type||"feature",e.renderer=void 0===e.renderer?"webgl":e.renderer,e.renderer=a(e.renderer),!e.renderer)return console.warn("Invalid renderer"),null;var n=t.createLayer(e.type,e);return n?(e.features&&e.features.forEach((function(t){t.data=t.data||e.data,t.feature=o.create(n,t)})),n):(console.warn("Unable to create a layer"),null)},r(l,i),t.exports=l},9281:function(t,e,n){var r=n(4626),i=n(1275),o=n(77),a=n(5325),s=n(642),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},i.call(this,t);var e,n=this,r=this._init,l=o();return this.featureType="line",this._subfeatureStyles={lineCap:!0,lineJoin:!0,strokeColor:!0,strokeOffset:!0,strokeOpacity:!0,strokeWidth:!0},this.line=function(t){return void 0===t?n.style("line"):(n.style("line",t),n.dataTime().modified(),n.modified(),n)},this.position=function(t){return void 0===t?n.style("position"):(n.style("position",t),n.dataTime().modified(),n.modified(),n)},this._updatePointSearchInfo=function(){if(l.timestamp()>=n.dataTime().timestamp()&&l.timestamp()>=n.timestamp())return e;l.modified(),e=[];for(var t=n.data(),r=n.line(),i=n.style.get("strokeWidth"),o=s.isFunction(n.style("strokeWidth"))?void 0:i(),u=n.position(),c=n.style.get("closed"),f=s.isFunction(n.style("closed"))?void 0:c(),h=n.style.get("uniformLine"),d=s.isFunction(n.style("uniformLine"))?void 0:h(),p=n.gcs(),m=n.layer().map().gcs(),g=a.onlyInvertedY(p,m),y=0;y<t.length;y+=1){for(var v=t[y],x=void 0===f?c(v,y):f,_=void 0,b=void 0,w=void 0,M=void 0,A=void 0,T=void 0,E=void 0,C=void 0,k=[],S=void 0===d?h(v,y):d,O=r(v,y),P=0;P<O.length;P+=1){var L=O[P],R=u(L,P,v,y);g?R={x:R.x,y:-R.y}:p!==m&&(R=a.transformCoordinates(p,m,R)),void 0===T&&(T={x:R.x,y:R.y}),void 0===E&&(E={x:R.x,y:R.y}),R.x<T.x&&(T.x=R.x),R.x>E.x&&(E.x=R.x),R.y<T.y&&(T.y=R.y),R.y>E.y&&(E.y=R.y),S&&P||(C=void 0===o?i(L,P,v,y):o);var I=Math.ceil(C/2)+2;(void 0===E.r||I>E.r)&&(E.r=I);var D=I*I;_&&k.push({u:R,v:_,r:w>I?w:I,r2:M>D?M:D,i:P,j:b}),_=R,b=P,w=I,M=D,!A&&x&&(A={p:R,r:I,r2:D,i:P})}x&&A&&(_.x!==A.p.x||_.y!==A.p.y)&&k.push({u:_,v:A.p,r:w>A.r?w:A.r,r2:M>A.r2?M:A.r2,i:b,j:A.i}),k.min=T,k.max=E,e.push(k)}return e},this.pointSearch=function(t,r){var i=n.data(),o=[],u=[],l={};if(!i||!i.length||!n.layer())return{found:u,index:o,extra:l};n._updatePointSearchInfo();var c=n.layer().map();r=null===r?c.gcs():void 0===r?c.ingcs():r;var f,h,d,p,m=c.unitsPerPixel(c.zoom()),g=m*m,y=a.transformCoordinates(r,c.gcs(),t),v=n.style.get("strokeWidth"),x=n.style.get("strokeOpacity"),_=n.line();for(h=0;h<e.length;h+=1)for(p=e[h],f=null,d=0;d<p.length;d+=1)if(s.distance2dToLineSquared(y,p[d].u,p[d].v)<=p[d].r2*g&&(f||(f=_(i[h],h)),(x(f[p[d].i],p[d].i,i[h],h)>0||x(f[p[d].j],p[d].j,i[h],h)>0)&&(v(f[p[d].i],p[d].i,i[h],h)>0||v(f[p[d].j],p[d].j,i[h],h)>0))){u.push(i[h]),o.push(h),l[h]=d;break}return{found:u,index:o,extra:l}},this.polygonSearch=function(t,r,i){var o,u,l=n.data(),c=[],f=[],h={},d=n.layer().map(),p=n.style.get("strokeWidth"),m=n.style.get("strokeOpacity"),g=n.line();if(i=null===i?d.gcs():void 0===i?d.ingcs():i,t.outer||(t={outer:t,inner:[]}),!l||!l.length||t.outer.length<3)return{found:f,index:c,extra:h};(r=r||{}).partial=r.partial||!1,(t={outer:a.transformCoordinates(i,d.gcs(),t.outer),inner:(t.inner||[]).map((function(t){return a.transformCoordinates(i,d.gcs(),t)}))}).outer.forEach((function(t){o||(o={x:t.x,y:t.y},u={x:t.x,y:t.y}),t.x<o.x&&(o.x=t.x),t.x>u.x&&(u.x=t.x),t.y<o.y&&(o.y=t.y),t.y>u.y&&(u.y=t.y)})),n._updatePointSearchInfo();var y,v,x,_,b,w,M=d.unitsPerPixel(d.zoom());for(y=0;y<e.length;y+=1)if(!(!(x=e[y]).max||x.max.x<o.x-x.max.r*M||x.min.x>u.x+x.max.r*M||x.max.y<o.y-x.max.r*M||x.min.y>u.y+x.max.r*M)){var A=void 0,T=void 0,E=void 0;for(v=0;v<x.length;v+=1)if(_=x[v].u,b=x[v].v,w=x[v].r,!(_.x<o.x-w*M&&b.x<o.x-w*M||_.x>u.x+w*M&&b.x>u.x+w*M||_.y<o.y-w*M&&b.y<o.y-w*M||_.y>u.y+w*M&&b.y>u.y+w*M||(E||(E=g(l[y],y)),m(E[x[v].i],x[v].i,l[y],y)<=0&&m(E[x[v].j],x[v].j,l[y],y)<=0||p(E[x[v].i],x[v].i,l[y],y)<=0&&p(E[x[v].j],x[v].j,l[y],y)<=0))){var C=s.distanceToPolygon2d(_,t),k=s.distanceToPolygon2d(b,t);if(C>-w*M&&C<w*M||k>-w*M&&k<w&M||C*k<0){T=!0;break}if(s.crossedLineSegmentPolygon2d(_,b,t)){T=!0;break}for(var S=w*w*M*M,O=0;O<t.outer.length&&!T;O+=1)T=s.distance2dToLineSquared(t.outer[O],_,b)<S;for(var P=0;P<t.inner.length&&!T;P+=1)for(var L=0;L<t.inner[P].length&&!T;L+=1)T=s.distance2dToLineSquared(t.inner[P][L],_,b)<S;if(T)break;C>0&&(A=!0)}(!r.partial&&A&&!T||r.partial&&(A||T))&&(c.push(y),f.push(l[y]),h[y]={partial:T,segment:v<e[y].length?v:0})}return{found:f,index:c,extra:h}},this.rdpSimplifyData=function(t,e,r,i){t=t||n.data(),r=r||n.style.get("position"),i=i||n.style.get("line");var o=n.layer().map(),u=o.gcs(),l=n.gcs(),c=n.style.get("closed");return void 0===e&&(e=.5*o.unitsPerPixel(o.zoom())),t=t.map((function(t,n){var o=i(t,n),f=a.transformCoordinates(l,u,o.map((function(e,i){return r(e,i,t,n)}))),h=s.rdpLineSimplify(f,e,c(t,n),[]);for(var d in(h.length<2||2===h.length&&s.distance2dSquared(h[0],h[1])<e*e)&&(h=[]),h=a.transformCoordinates(u,l,h),t)!t.hasOwnProperty(d)||Array.isArray(t)&&d>=0&&d<t.length||(h[d]=t[d]);return h})),n.style("position",s.identityFunction),n.style("line",s.identityFunction),n.data(t),n},this._init=function(t){t=t||{},r.call(n,t);var e=Object.assign({},{strokeWidth:1,strokeColor:{r:1,g:.8431372549,b:0},strokeStyle:"solid",strokeOpacity:1,antialiasing:2,closed:!1,line:s.identityFunction,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){return t.length>=3?t.slice(0,3):[0,0,0]}},void 0===t.style?{}:t.style);return void 0!==t.line&&(e.line=t.line),void 0!==t.position&&(e.position=t.position),n.style(e),n.dataTime().modified(),n},this._init(t),this};u.create=function(t,e){"use strict";return(e=e||{}).type="line",i.create(t,e)},u.capabilities={feature:"line",basic:"line.basic",multicolor:"line.multicolor"},r(u,i),t.exports=u},6211:function(t,e,n){var r=n(5616),i=n(4626),o=n(5402),a=function(t){"use strict";if(!(this instanceof a))return new a(t);if(void 0===(t=t||{}).node||null===t.node)return console.warn("map creation requires a node"),this;o.call(this,t);var e,i,s,u,l,c=n(3578),f=n(5325),h=n(642),d=n(1098),p=n(6409),m=n(7908),g=n(4231),y=this,v=this._exit,x=r(t.node),_=t.width||x.width()||512,b=t.height||x.height()||512,w=void 0===t.gcs?"EPSG:3857":t.gcs,M=void 0===t.ingcs?"EPSG:4326":t.ingcs,A={x:0,y:0},T=void 0===t.zoom?4:t.zoom,E=t.rotation?t.rotation:0,C=null,k=null,S={min:0,max:16,origMin:0},O=null,P=null,L=!!t.discreteZoom,R="function"==typeof t.allowRotation?t.allowRotation:void 0===t.allowRotation||!!t.allowRotation,I=t.maxBounds||{},D=t.camera||c(),N=t.animationQueue||[],F=void 0===t.autoResize||t.autoResize,j=t.autoshareRenderer,z=((I.left||0)+(I.right||0))/2,B=((I.bottom||0)+(I.top||0))/2;function V(){var t;void 0!==document.hidden?t="hidden":void 0!==document.msHidden?t="msHidden":void 0!==document.webkitHidden&&(t="webkitHidden"),y.geoTrigger(document[t]?p.hidden:p.unhidden)}function q(t){var e;void 0!==document.hidden?e="visibilitychange":void 0!==document.msHidden?e="msvisibilitychange":void 0!==document.webkitHidden&&(e="webkitvisibilitychange"),document.removeEventListener(e,V),!1!==t&&document.addEventListener(e,V)}function G(t,e){var n=t.zIndex(),r=e.zIndex();if(n!==r)return n-r;var i=t.node()[0],o=e.node()[0],a=i&&i.parentNode,s=o&&o.parentNode;if(a&&s&&a===s){var u=Array.from(a.children),l=u.indexOf(i),c=u.indexOf(o);if(l>=0&&c>=0)return l-c}return a?-1:s?1:0}function U(t,e,n,r,i){t.globalAlpha=e,i&&(t.globalCompositeOperation=i);var o=n.css("transform");o&&"matrix("===o.substr(0,7)?t.setTransform.apply(t,o.substr(7,o.length-8).split(",").map(parseFloat)):t.setTransform(1,0,0,1,0,0),t.drawImage(r,0,0),t.globalCompositeOperation="source-over"}function H(){for(var t=N.splice(0,N.length),e=1;e<t.length;e+=1)try{t[e].apply(y,arguments)}catch(t){console.error(t)}}function W(t,e,n){var r=e.width/2,i=e.height/2,o=Math.sin(n),a=Math.cos(n),s={},u={},l={},c={};return s.x=t.x+-r*a- -i*o,s.y=t.y+-r*o+-i*a,u.x=t.x+r*a- -i*o,u.y=t.y+r*o+-i*a,l.x=t.x+-r*a-i*o,l.y=t.y+-r*o+i*a,c.x=t.x+r*a-i*o,c.y=t.y+r*o+i*a,{left:Math.min(s.x,u.x,l.x,c.x),right:Math.max(s.x,u.x,l.x,c.x),bottom:Math.min(s.y,u.y,l.y,c.y),top:Math.max(s.y,u.y,l.y,c.y)}}function X(t,n){void 0===n&&(n=E),t=function(t,e){return e&&(t=W({x:(t.left+t.right)/2,y:(t.top+t.bottom)/2},{width:Math.abs(t.left-t.right),height:Math.abs(t.top-t.bottom)},e)),t}(t,n);var r=function(t){var e,n,r=t.right-t.left,i=t.top-t.bottom,o=Math.abs(r/i),a=_/b;return o>a?(e=1,n=o/a):(n=1,e=a/o),{x:e,y:n}}(t);return r.y>r.x?-Math.log2(Math.abs(t.right-t.left)*r.x/(_*e)):-Math.log2(Math.abs(t.top-t.bottom)*r.y/(b*e))}function K(){S.min=u?Math.max(S.origMin,X(I)):S.origMin}function Q(t,e,n){if(!R)return 0;if(e||"function"!=typeof R||(t=R(t)),!n){var r=2*Math.PI;t=t%r+(t>=0?0:r),Math.min(Math.abs(t),Math.abs(t-r))<1e-5&&(t=0)}return t}function Y(t,e,n,r){if(!i&&!s)return t;var o,a,u=I;if(e){u=Object.assign({},I);var l,c,f=Math.abs(t.right-t.left),h=Math.abs(t.top-t.bottom),d=Math.abs(Math.sin(e)),p=Math.abs(Math.cos(e));if(t.width&&t.height)l=t.width,c=t.height;else if(Math.abs(d-p)<5e-4)if(_&&b){var m=Math.abs(_/b),g=Math.pow(1+Math.pow(m,2),.5);c=(l=Math.max(f,h)/g)*m}else l=f*p,c=h*d;else l=(p*f-d*h)/(p*p-d*d),c=(p*h-d*f)/(p*p-d*d);var y=f-Math.max(p*l,d*c),v=h-Math.max(p*c,d*l);u.left-=y,u.right+=y,u.top+=v,u.bottom-=v}return r&&(u={left:u.left-(t.right-t.left)/2,right:u.right+(t.right-t.left)/2,top:u.top-(t.bottom-t.top)/2,bottom:u.bottom+(t.bottom-t.top)/2}),i&&(t.right-t.left>u.right-u.left?o=u.left-(t.right-t.left-(u.right-u.left))/2-t.left:t.left<u.left?o=u.left-t.left:t.right>u.right&&(o=u.right-t.right),o&&(!n||n.x*o>0)&&(n&&Math.abs(o)>Math.abs(n.x*n.unit)&&(o=Math.abs(n.x*n.unit)*o/Math.abs(o)),t={left:t.left+=o,right:t.right+=o,top:t.top,bottom:t.bottom})),s&&(t.top-t.bottom>u.top-u.bottom?a=u.bottom-(t.top-t.bottom-(u.top-u.bottom))/2-t.bottom:t.top>u.top?a=u.top-t.top:t.bottom<u.bottom&&(a=u.bottom-t.bottom),a&&(!n||-n.y*a>0)&&(n&&Math.abs(a)>Math.abs(n.y*n.unit)&&(a=Math.abs(n.y*n.unit)*a/Math.abs(a)),t={top:t.top+=a,bottom:t.bottom+=a,left:t.left,right:t.right})),t}function $(t,e){if(D.rotation=e||0,t.width&&t.height&&e){var n=(t.left+t.right)/2,r=(t.top+t.bottom)/2;D.viewFromCenterSizeRotation({x:n,y:r},t,e)}else D.bounds=t;A={x:(D.bounds.left+D.bounds.right)/2,y:(D.bounds.top+D.bounds.bottom)/2}}function Z(){y.size({width:x.width(),height:x.height()})}return I.left=f.transformCoordinates(I.gcs||M,w,{x:void 0!==I.left?I.left:-180,y:B}).x,I.right=f.transformCoordinates(I.gcs||M,w,{x:void 0!==I.right?I.right:180,y:B}).x,I.top=void 0!==I.top?f.transformCoordinates(I.gcs||M,w,{x:z,y:I.top}).y:I.right,I.bottom=void 0!==I.bottom?f.transformCoordinates(I.gcs||M,w,{x:z,y:I.bottom}).y:I.left,e=t.unitsPerPixel||(I.right-I.left)/256,D.viewport={width:_,height:b,left:x.offset().left,top:x.offset().top},t.center=h.normalizeCoordinates(t.center),i=void 0!==t.clampBoundsX&&t.clampBoundsX,s=void 0===t.clampBoundsY||t.clampBoundsY,u=void 0===t.clampZoom||t.clampZoom,this.unitsPerPixel=function(t,n){return t=t||0,n?(e=Math.pow(2,t)*n,y.draw(),y):Math.pow(2,-t)*e},this.animationQueue=function(t){if(void 0===t)return N;if(t!==N){if(N.length){t.length&&t[0]!==N[0]&&window.cancelAnimationFrame(N[0]);for(var e=t.length?1:0;e<N.length;e+=1)t.push(N[e])}N=t}return y},this.autoResize=function(t){return void 0===t?F:(t!==F&&(r(window).off("resize",Z),(F=t)&&r(window).on("resize",Z)),y)},this.clampBoundsX=function(t){return void 0===t?i:(t!==i&&(i=!!t,y.pan({x:0,y:0})),y)},this.clampBoundsY=function(t){return void 0===t?s:(t!==s&&(s=!!t,y.pan({x:0,y:0})),y)},this.clampZoom=function(t){return void 0===t?u:(t!==u&&(u=!!t,K(),y.zoom(T)),y)},this.allowRotation=function(t){return void 0===t?R:("function"!=typeof t&&(t=!!t),t!==R&&(R=t,y.rotation(E)),y)},this.origin=function(){return Object.assign({},l)},this.camera=function(){return D},this.gcs=function(t){if(void 0===t)return w;if(t!==w){var e=y.center(void 0,void 0);w=t,K();var n=y._fix_zoom(T);n!==T&&y.zoom(n),y.center(e,void 0)}return y},this.ingcs=function(t){return void 0===t?M:(M=t,y)},this.node=function(){return x},this.zoom=function(t,e,n,r,i){if(void 0===t)return T;var o,a,s=e&&(e.mapgcs||e.geo)&&e.map;if(s&&(r=!0),(t=y._fix_zoom(t,n))===T)return y;if(T=t,a=y.boundsFromZoomAndCenter(t,A,E,null,n,r),y.modified(),$(a,E),o={zoomLevel:T,screenPosition:e?e.map:void 0},i&&"pan"!==i||y.geoTrigger(p.zoom,o),s){var u=y.gcsToDisplay(e.mapgcs||e.geo,e.mapgcs?null:void 0);y.pan({x:e.map.x-u.x,y:e.map.y-u.y},n,!0,i)}else y.pan({x:0,y:0},n,r,i);return y},this.zoomAndCenter=function(t,e,n,r,i,o){return this.zoom(t,void 0,r,i,o||"pan"),this.center(e,n,r,i,o),this},this.pan=function(t,e,n,r){var i={screenDelta:t};if(t.x||t.y){var o=y.unitsPerPixel(T),a=Math.sin(E),s=Math.cos(E);D.pan({x:(t.x*s- -t.y*a)*o,y:(t.x*a+-t.y*s)*o})}var u=D.bounds;if((u=Y(u,E,"limited"===n?{x:t.x,y:t.y,unit:o}:void 0,!0===n))!==D.bounds){var l=y.gcsToDisplay({x:D.bounds.left,y:D.bounds.top},null);$(u=y.boundsFromZoomAndCenter(T,{x:(u.left+u.right)/2,y:(u.top+u.bottom)/2},E,null,e,!0),E);var c=y.gcsToDisplay({x:D.bounds.left,y:D.bounds.top},null);i.screenDelta.x+=c.x-l.x,i.screenDelta.y+=c.y-l.y}return A=D.displayToWorld({x:_/2,y:b/2}),r||y.geoTrigger(p.pan,i),y.modified(),y},this.rotation=function(t,e,n){if(void 0===t)return E;var r=e&&e.geo&&e.map;if((t=Q(t,n))===E)return y;E=t;var i=y.boundsFromZoomAndCenter(T,A,E,null,n,!0);y.modified(),$(i,E);var o={rotation:E,screenPosition:e?e.map:void 0};if(y.geoTrigger(p.rotate,o),r){var a=y.gcsToDisplay(e.geo);y.pan({x:e.map.x-a.x,y:e.map.y-a.y},void 0,!0)}else y.pan({x:0,y:0},void 0,!0);return K(),y.zoom(T,void 0,n),y},this.center=function(t,e,n,r,i){var o;return void 0===t?o=Object.assign({},y.worldToGcs(A,e)):(o=y.gcsToWorld(t,e),$(y.boundsFromZoomAndCenter(T,o,E,null,n,r),E),y.modified(),i||y.geoTrigger(p.pan,{screenDelta:{x:0,y:0}}),y)},this.createLayer=function(t,e){e=e||{},void 0!==y.autoshareRenderer()&&(e=Object.assign({autoshareRenderer:y.autoshareRenderer()},e));var n=d.createLayer(t,y,e);return n&&(y.addChild(n),y.children().forEach((function(t){t instanceof g&&t.moveToTop()})),n._update(),y.modified(),y.geoTrigger(p.layerAdd,{target:y,layer:n})),n},this.deleteLayer=function(t){return null!=t&&(t._exit(),y.removeChild(t),y.modified(),y.geoTrigger(p.layerRemove,{target:y,layer:t})),t},this.size=function(t){if(void 0===t)return{width:_,height:b};var e=y.center();_=t.width||_,b=t.height||b,K();var n=y._fix_zoom(T);return n!==T&&y.zoom(n),y.camera().viewport={width:_,height:b,left:x.offset().left,top:x.offset().top},y.center(e),y.geoTrigger(p.resize,{target:y,width:_,height:b}),y.modified(),y},this.rotatedSize=function(){if(!this.rotation())return{width:_,height:b};var t=W({x:0,y:0},{width:_,height:b},y.rotation());return{width:Math.abs(t.right-t.left),height:Math.abs(t.top-t.bottom)}},this.gcsToWorld=function(t,e){return Array.isArray(t)?t.map((function(t){return y.gcsToWorld(t,e)})):((e=null===e?w:void 0===e?M:e)!==w&&(t=f.transformCoordinates(e,w,t)),l.x||l.y||l.z?t=f.affineForward({origin:l},[t])[0]:"z"in t||(t={x:t.x,y:t.y,z:0}),t)},this.worldToGcs=function(t,e){return Array.isArray(t)?t.map((function(t){return y.worldToGcs(t,e)})):(l.x||l.y||l.z?t=f.affineInverse({origin:l},[t])[0]:"z"in t||(t={x:t.x,y:t.y,z:0}),(e=null===e?w:void 0===e?M:e)!==w&&(t=f.transformCoordinates(w,e,t)),t)},this.gcsToDisplay=function(t,e){return t=y.gcsToWorld(t,e),y.worldToDisplay(t)},this.worldToDisplay=function(t){return Array.isArray(t)?t.map((function(t){return D.worldToDisplay(t)})):D.worldToDisplay(t)},this.displayToGcs=function(t,e){return t=y.displayToWorld(t),y.worldToGcs(t,e)},this.displayToWorld=function(t){return Array.isArray(t)?t.map((function(t){return D.displayToWorld(t)})):D.displayToWorld(t)},this.draw=function(){var t,e=y.children();for(y.geoTrigger(p.draw,{target:y}),y._update(),t=0;t<e.length;t+=1)e[t].draw();return y.geoTrigger(p.drawEnd,{target:y}),y},this.fileReader=function(t,e){return void 0===t?C:("string"==typeof t?((e=e||{}).layer||(e.layer=y.createLayer("feature",Object.assign({},e))),e.renderer=e.layer.renderer().api(),C=d.createFileReader(t,e)):C=t,y)},this._init=function(t){if(null==x)throw new Error("Map require DIV node");return x.data("data-geojs-map")&&r.isFunction(x.data("data-geojs-map").exit)&&x.data("data-geojs-map").exit(),x.addClass("geojs-map"),x.data("data-geojs-map",y),q(),y},this._update=function(t){var e,n=y.children();for(e=0;e<n.length;e+=1)n[e]._update(t);return y},this.exit=function(){q(!1);var t,e=y.children();for(t=e.length-1;t>=0;t-=1)e[t]._exit(),y.removeChild(e[t]);y.interactor()&&(y.interactor().destroy(),y.interactor(null)),N=[],y.node().data("data-geojs-map",null),y.node().off(".geo"),y.node().empty(),r(window).off("resize",Z),v()},this.interactor=function(t){return void 0===t?k:(k&&k!==t&&k.destroy(),(k=t)&&(x.attr("tabindex")||x.attr("tabindex",0),k.map(y)),y)},this.zoomRange=function(t,e){return void 0===t?Object.assign({},S):(void 0!==t.max&&(S.max=t.max),void 0!==t.min&&(S.min=S.origMin=t.min),K(),e||y.zoom(T),y)},this.transition=function(t,e,n){if(void 0===t)return O;if(O){var i=h.deepMerge({},O.end);return i.center&&w!==M&&(i.center=f.transformCoordinates(w,M,i.center)),P=Object.assign({},i||{},P||{},t),y}var o=y.unitsPerPixel(0);function a(t){return Math.pow(2,-(t+1))*o*b}var s={center:void 0,zoom:y.zoom(),rotation:y.rotation(),duration:1e3,ease:function(t){return t},interp:function(t,e){return function(n){var i=[];return r.each(t,(function(r){i.push(function(t,e,n){return t+(e-t)*n}(t[r],e[r],n))})),i}},done:null,zCoord:!0};function u(e){var n=O.done,r=P;if(!0===O.cancel)return y.geoTrigger(p.transitioncancel,t),n&&n({cancel:!0,source:O.cancelSource,transition:O}),O=null,void(P&&(r=P,P=null,y.transition(r,void 0,e)));if(O.start.time||(O.start.time=e,O.end.time=e+t.duration),O.time=e-O.start.time,e>=O.end.time||r){if(!r){if(O.end.center){var i=T!==y._fix_zoom(O.end.zoom)||!1===t.endClamp;y.center(O.end.center,null,i,i)}y.zoom(O.end.zoom,O.zoomOrigin,!1===t.endClamp,!1===t.endClamp),y.rotation(Q(O.end.rotation))}return y.geoTrigger(p.transitionend,t),n&&n({next:!!r}),O=null,void(P&&(r=P,P=null,y.transition(r,void 0,e)))}var a=O.ease((e-O.start.time)/t.duration),s=O.interp(a);O.zCoord&&(s[2]=function(t){return-Math.log2(t/o/b)-1}(s[2])),y._fix_zoom(s[2],!0)===T?y.center({x:s[0],y:s[1]},null,!0,!0):(A=y.gcsToWorld({x:s[0],y:s[1]},null),y.zoom(s[2],O.zoomOrigin,!0,!0)),y.rotation(s[3],void 0,!0),y.scheduleAnimationFrame(u)}return t.center&&(e=null===e?w:void 0===e?M:e,(t=h.deepMerge({},t)).center=h.normalizeCoordinates(t.center),e!==w&&(t.center=f.transformCoordinates(e,w,t.center))),t=h.deepMerge({},s,t),(O={start:{center:y.center(void 0,null),zoom:y.zoom(),rotation:y.rotation()},end:{center:t.center,zoom:y._fix_zoom(t.zoom),rotation:Q(t.rotation,void 0,!0)},ease:t.ease,zCoord:t.zCoord,done:t.done,duration:t.duration,zoomOrigin:t.zoomOrigin,endClamp:t.endClamp}).interp=t.interp([O.start.center.x,O.start.center.y,t.zCoord?a(O.start.zoom):O.start.zoom,O.start.rotation],[O.end.center?O.end.center.x:O.start.center.x,O.end.center?O.end.center.y:O.start.center.y,t.zCoord?a(O.end.zoom):O.end.zoom,O.end.rotation]),y.geoTrigger(p.transitionstart,t),p.cancelNavigation?(O=null,y.geoTrigger(p.transitionend,t),y):(p.cancelAnimation?(t.duration=0,u(0)):n?u(n):y.scheduleAnimationFrame(u),y)},this.transitionCancel=function(t){return!(!O||!0===O.cancel&&!P)&&(O.cancel=!0,O.cancelSource=t||O.cancelSource||"",P=null,!0)},this.bounds=function(t,e){var n;if(e=null===e?w:void 0===e?M:e,void 0!==t){if(e!==w){var r=f.transformCoordinates(e,w,[{x:t.left,y:t.top},{x:t.right,y:t.bottom}]);t={left:r[0].x,top:r[0].y,right:r[1].x,bottom:r[1].y}}t=Y(t,E),n=y.zoomAndCenterFromBounds(t,E,null),y.zoom(n.zoom,void 0,void 0,void 0,"pan"),y.center(n.center,null)}return y.boundsFromZoomAndCenter(T,A,E,e,!0)},this.maxBounds=function(t,e){if(e=null===e?w:void 0===e?M:e,void 0===t)return{left:f.transformCoordinates(w,e,{x:I.left,y:0}).x,right:f.transformCoordinates(w,e,{x:I.right,y:0}).x,bottom:f.transformCoordinates(w,e,{x:0,y:I.bottom}).y,top:f.transformCoordinates(w,e,{x:0,y:I.top}).y};var n=((t.left||0)+(t.right||0))/2,r=((t.bottom||0)+(t.top||0))/2;return void 0!==t.left&&(I.left=f.transformCoordinates(e,w,{x:t.left,y:r}).x),void 0!==t.right&&(I.right=f.transformCoordinates(e,w,{x:t.right,y:r}).x),void 0!==t.bottom&&(I.bottom=f.transformCoordinates(e,w,{x:n,y:t.bottom}).y),void 0!==t.top&&(I.top=f.transformCoordinates(e,w,{x:n,y:t.top}).y),K(),y.zoom(T),y.pan({x:0,y:0}),y},this.corners=function(t){return[y.displayToGcs({x:0,y:0},t),y.displayToGcs({x:_,y:0},t),y.displayToGcs({x:_,y:b},t),y.displayToGcs({x:0,y:b},t)]},this.zoomAndCenterFromBounds=function(t,e,n){var r,i;if((n=null===n?w:void 0===n?M:n)!==w){var o=f.transformCoordinates(n,w,[{x:t.left,y:t.top},{x:t.right,y:t.bottom}]);t={left:o[0].x,top:o[0].y,right:o[1].x,bottom:o[1].y}}if(t.left>=t.right||t.bottom>=t.top)throw new Error("Invalid bounds provided");return i=y._fix_zoom(X(t,e)),r={x:((t=Y(t,e)).left+t.right)/2-l.x,y:(t.top+t.bottom)/2-l.y},n!==w&&(r=f.transformCoordinates(w,n,r)),{zoom:i,center:r}},this.boundsFromZoomAndCenter=function(t,e,n,r,i,o){var a,s,u,c,h,d;if(r=null===r?w:void 0===r?M:r,t=y._fix_zoom(t,i),d=y.unitsPerPixel(t),e=y.gcsToWorld(e,null),u=(a=_*d)/2,c=(s=b*d)/2,n?(e.x+=l.x,e.y+=l.y,(h=W(e,{width:a,height:s},n)).width=a,h.height=s,h=Y(h,n,void 0,o)):h=Y(h={left:e.x-u+l.x,right:e.x+u+l.x,bottom:e.y-c+l.y,top:e.y+c+l.y},0,void 0,o),r!==w){var p=f.transformCoordinates(w,r,[[h.left,h.top],[h.right,h.bottom]]);h={left:p[0][0],top:p[0][1],right:p[1][0],bottom:p[1][1]}}return h.width=a,h.height=s,h},this.discreteZoom=function(t){return void 0===t?L:(L!==(t=!!t)&&((L=t)&&y.zoom(Math.round(y.zoom())),y.interactor()&&y.interactor().options({discreteZoom:L})),y)},this.layers=this.children,this.sortedLayers=function(){return y.children().sort(G)},this.listSceneObjects=function(t){var e=[];return(t=t||y.sortedLayers()).forEach((function(t){if(e.indexOf(t)<0&&(e.push(t),t.children)){var n=t.children();n.length&&(e=e.concat(y.listSceneObjects(n)))}})),e},this.updateAttribution=function(){y.node().find(".geo-attribution").remove();var t=r("<div/>").addClass("geo-attribution").on("mousedown",(function(t){t.stopPropagation()}));return y.children().forEach((function(e){var n=e.attribution();n&&r("<span/>").addClass("geo-attribution-layer").html(n).appendTo(t)})),r("span",t).length&&t.appendTo(y.node()),y},this.screenshot=function(t,e,n,i){var o;if(!t||Array.isArray(t)||t.renderer||(e=e||t.type,n=n||t.encoderOptions,i=i||t,t=t.layers),(i=i||{}).wait){var a=Object.assign({},i,{wait:!1});o=r.Deferred();var s=function(){window.requestAnimationFrame((function(){o.resolve()}))};return"idle"===i.wait?y.onIdle(s):s(),o.then((function(){return y.screenshot(t,e,n,a)}))}o=r.when(),t?Array.isArray(t)||(t=[t]):(t=y.layers(),null!==i.attribution&&void 0!==i.attribution||(i.attribution=!0)),t=(t=t.filter((function(t){return y.layers().indexOf(t)>=0&&t.opacity()>0&&(!t.visible||t.visible())}))).sort(G);var u=document.createElement("canvas");u.width=_,u.height=b;var l=u.getContext("2d");if(!1!==i.background&&null!==i.background){var c=i.background;void 0===i.background&&(l.fillStyle="white",l.fillRect(0,0,u.width,u.height),y.node().parents().get().reverse().forEach((function(t){(c=window.getComputedStyle(t).backgroundColor)&&"transparent"!==c&&(l.fillStyle=c,l.fillRect(0,0,u.width,u.height))})),c=window.getComputedStyle(y.node()[0]).backgroundColor),c&&"transparent"!==c&&(l.fillStyle=c,l.fillRect(0,0,u.width,u.height))}return t.forEach((function(t){var e=t.opacity();t.node().children("canvas").each((function(){var n=r(this);o=o.then((function(){t.renderer()&&"webgl"===t.renderer().api()&&t.renderer()._renderFrame(),U(l,e,n,n[0],t.node().css("mix-blend-mode"))}))})),!t.node().children().not("canvas").length&&t.node().children().length||t.renderer()&&"webgl"===t.renderer().api()||(o=o.then((function(){return h.htmlToImage(t.node(),1).done((function(e){U(l,1,r([]),e,t.node().css("mix-blend-mode"))}))})))})),i.attribution&&y.node().find(".geo-attribution").each((function(){var t=r(this);o=o.then((function(){return h.htmlToImage(t,1).done((function(t){U(l,1,r([]),t)}))}))})),i.html&&r(i.html).each((function(){var t=r(this);o=o.then((function(){return h.htmlToImage(t,1).done((function(e){U(l,1,r([]),e,t.css("mix-blend-mode"))}))}))})),o=o.then((function(){var t=u;if("canvas"!==e)try{u=u.toDataURL(e,n)}catch(t){console.warn("Failed to convert screenshot to output",t);var i=r.Deferred();return i.reject(),i}return y.geoTrigger(p.screenshot.ready,{canvas:t,screenshot:u}),u}))},this.scheduleAnimationFrame=function(t,e){N.length||N.push(window.requestAnimationFrame(H));var n=N.indexOf(t,1);if(n>=0){if(!e)return;if(N.splice(n,1),"remove"===e)return}return N.push(t),N[0]},this._fix_zoom=function(t,e){return t=Math.round(1e6*t)/1e6,t=Math.max(Math.min(S.max,t),S.min),L&&!e&&(t=Math.round(t))<S.min&&(t=Math.ceil(S.min)),t},this.autoshareRenderer=function(t){return void 0===t?j:(j=null===t?void 0:t,y)},this._version=n(4081),this._geo=n(2257),this._init(t),this.node().on("dragover.geo",(function(t){var e=t.originalEvent;y.fileReader()&&(e.stopPropagation(),e.preventDefault(),e.dataTransfer.dropEffect="copy")})).on("drop.geo",(function(t){var e,n,r=t.originalEvent,i=y.fileReader();function o(){y.draw()}if(i)for(r.stopPropagation(),r.preventDefault(),e=0;e<r.dataTransfer.files.length;e+=1)n=r.dataTransfer.files[e],i.canRead(n)&&i.read(n,o)})),l={x:0,y:0},this.zoomRange(t,!0),T=this._fix_zoom(T),E=Q(E),this.center(Object.assign({},t.center||A),void 0),null!==t.interactor&&this.interactor(t.interactor||m({discreteZoom:L})),F&&r(window).on("resize",Z),y.geoOn([p.layerAdd,p.layerRemove],y.updateAttribution),this};a.create=function(t){"use strict";var e=a(t),r=n(5156);return e&&e.zoom?(t.data=t.data||[],t.layers=t.layers||[],t.layers.forEach((function(n){n.data=n.data||t.data,n.layer=r.create(e,n)})),e):(console.warn("Could not create map."),null)},i(a,o),t.exports=a},7908:function(t,e,n){var r=n(4626),i=n(1338),o=n(642),a=n(7549),s=function(t){"use strict";if(!(this instanceof s))return new s(t);i.call(this);var e,r,u,l,c,f,h,d,p,m,g=n(5616),y=n(6409),v=n(8695),x=n(642).throttle,_=n(642).debounce,b=n(642).actionMatch,w=n(3842),M=this,A=0,T=null,E=!1,C=!1,k=function(){};function S(t){var e=t.x,n=t.y;return Math.sqrt(e*e+n*n)}function O(){f={boundDocumentHandlers:f.boundDocumentHandlers}}function P(t,n){n=n<=0?30:n;var r=function(){var t,n,r,i;if(!e.spring.enabled)return{x:0,y:0};var o=M.map().maxBounds(void 0,null),a=M.map().gcsToDisplay({x:o.left,y:o.top},null),s=M.map().gcsToDisplay({x:o.right,y:o.bottom},null),u=e.spring.springConstant,l=M.map().node().width(),c=M.map().node().height();return t=u*Math.max(0,a.x),n=u*Math.max(0,l-s.x),r=u*Math.max(0,a.y)/2,i=u*Math.max(0,c-s.y)/2,{x:t-n,y:r-i}}(),i=S(t),o=t.x/i,a=t.y/i;return i*=Math.exp(-e.momentum.drag*n),S(r)*n+i<e.momentum.minSpeed?null:(i>0?(o*=i,a*=i):(o=0,a=0),{x:o-r.x*n,y:a-r.y*n})}return e=o.deepMerge({},{throttle:30,discreteZoom:!1,actions:[{action:v.pan,input:"left",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button pan"},{action:v.zoom,input:"right",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button zoom"},{action:v.zoom,input:"wheel",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"wheel zoom"},{action:v.rotate,input:"left",modifiers:{shift:!1,ctrl:!0},owner:"geo.mapInteractor",name:"button rotate"},{action:v.rotate,input:"wheel",modifiers:{shift:!1,ctrl:!0},owner:"geo.mapInteractor",name:"wheel rotate"},{action:v.select,input:"left",modifiers:{shift:!0,ctrl:!0},selectionRectangle:y.select,owner:"geo.mapInteractor",name:"drag select"},{action:v.zoomselect,input:"left",modifiers:{shift:!0,ctrl:!1},selectionRectangle:y.zoomselect,owner:"geo.mapInteractor",name:"drag zoom"},{action:v.unzoomselect,input:"right",modifiers:{shift:!0,ctrl:!1},selectionRectangle:y.unzoomselect,owner:"geo.mapInteractor",name:"drag unzoom"},{action:v.pan,input:"pan",owner:"geo.mapInteractor",name:"touch pan"},{action:v.zoomrotate,input:"rotate",owner:"geo.mapInteractor",name:"touch zoom and rotate"},{action:v.pan,input:"middle",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button pan"}],click:{enabled:!0,buttons:{left:!0,right:!0,middle:!0},duration:0,cancelOnMove:!0},keyboard:{actions:{"zoom.in":["plus","shift+plus","shift+ctrl+plus","=","shift+=","shift+ctrl+="],"zoom.out":["-","shift+-","shift+ctrl+-","_","shift+_","shift+ctrl+_"],"zoom.0":["1"],"zoom.3":["2"],"zoom.6":["3"],"zoom.9":["4"],"zoom.12":["5"],"zoom.15":["6"],"zoom.18":["7"],"pan.left":["left","shift+left","shift+ctrl+left"],"pan.right":["right","shift+right","shift+ctrl+right"],"pan.up":["up","shift+up","shift+ctrl+up"],"pan.down":["down","shift+down","shift+ctrl+down"],"rotate.ccw":["<","shift+<","shift+ctrl+<",".","shift+.","shift+ctrl+."],"rotate.cw":[">","shift+>","shift+ctrl+>",",","shift+,","shift+ctrl+,"],"rotate.0":["0"]},meta:{0:{shift:!1,ctrl:!1},1:{shift:!0,ctrl:!0},2:{shift:!0,ctrl:!1}},metakeyMouseEvents:["shift","ctrl","shift+ctrl","shift+alt","shift+meta"],focusHighlight:!0},alwaysTouch:!1,wheelScaleX:1,wheelScaleY:1,zoomScale:1,rotateWheelScale:6*Math.PI/180,zoomrotateMinimumRotation:5*Math.PI/180,zoomrotateReverseRotation:4*Math.PI/180,zoomrotateMinimumZoom:.05,zoomrotateMinimumPan:5,touchPanDelay:50,momentum:{enabled:!0,maxSpeed:2.5,minSpeed:.01,stopTime:250,drag:.01,actions:[v.pan,v.zoom]},spring:{enabled:!1,springConstant:5e-5},zoomAnimation:{enabled:!0,duration:500,ease:function(t){return(2-t)*t}}},t||{}),t&&t.actions&&(e.actions=o.deepMerge([],t.actions)),t&&t.momentum&&t.momentum.actions&&(e.momentum.actions=o.deepMerge([],t.momentum.actions)),t&&t.keyboard&&void 0!==t.keyboard.actions&&(e.keyboard.actions=o.deepMerge({},t.keyboard.actions)),r={page:{x:0,y:0},map:{x:0,y:0},geo:{x:0,y:0},mapgcs:{x:0,y:0},buttons:{left:!1,right:!1,middle:!1},modifiers:{alt:!1,ctrl:!1,shift:!1,meta:!1},time:new Date,deltaTime:1,velocity:{x:0,y:0}},f={},h={},this._handleKeys=function(t,n,r){r&&!0===r.simulated&&(n=r);var i,o,a=e.keyboard.meta||{0:{}},s=M.map(),u=s.size(),l=t,c="",f={};for(i in a)a.hasOwnProperty(i)&&(void 0!==a[i].shift&&n.shiftKey!==!!a[i].shift||void 0!==a[i].ctrl&&n.ctrlKey!==!!a[i].ctrl||void 0!==a[i].alt&&n.altKey!==!!a[i].alt||void 0!==a[i].meta&&n.metaKey!==!!a[i].meta||(o=i));if(void 0!==o){switch(n.stopPropagation(),n.preventDefault(),t.indexOf(".")>=0&&(l=t.substr(0,t.indexOf(".")),c=t.substr(t.indexOf(".")+1)),l){case"zoom":switch(c){case"in":f.zoomDelta=[.05,.25,1][o];break;case"out":f.zoomDelta=-[.05,.25,1][o];break;default:isNaN(parseFloat(c))||(f.zoom=parseFloat(c))}break;case"pan":switch(c){case"down":f.panY=-Math.max(1,[0,.05,.5][o]*u.height);break;case"left":f.panX=Math.max(1,[0,.05,.5][o]*u.width);break;case"right":f.panX=-Math.max(1,[0,.05,.5][o]*u.width);break;case"up":f.panY=Math.max(1,[0,.05,.5][o]*u.height)}break;case"rotate":switch(c){case"ccw":f.rotationDelta=[1,5,90][o]*Math.PI/180;break;case"cw":f.rotationDelta=-[1,5,90][o]*Math.PI/180;break;default:isNaN(parseFloat(c))||(f.rotation=parseFloat(c))}}s.geoTrigger(y.keyaction,{move:f,action:t,factor:o,event:n}),f.cancel||(void 0!==f.zoom?s.zoom(f.zoom):f.zoomDelta&&s.zoom(s.zoom()+f.zoomDelta),void 0!==f.rotation?s.rotation(f.rotation):f.rotationDelta&&s.rotation(s.rotation()+f.rotationDelta),(f.panX||f.panY)&&s.pan({x:f.panX||0,y:f.panY||0}))}},this.hasTouchSupport=function(){return"ontouchstart"in window||window.TouchEvent||window.DocumentTouch&&document instanceof window.DocumentTouch||(navigator.msMaxTouchPoints||navigator.maxTouchPoints)>1},this._handleTouch=function(t){var n=!1;if("mouse"===t.pointerType&&c.touchSupport&&(n=!0),"hammer.input"===t.type){if("pan"!==c.lastEventType||1===t.pointers.length)return;n=!0,c.lastEventType=null}var r=/^(.*)(start|end|move|tap)$/.exec(t.type);if(r&&3===r.length||(n=!0),n)f.boundDocumentHandlers&&c.lastEvent&&M._handleMouseUpDocument(c.lastEvent);else{t.which=r[1];var i=(new Date).valueOf();"pan"===t.which&&"pan"!==c.lastEventType&&i-c.lastTime<e.touchPanDelay||(c.lastTime=i,c.lastEventType=t.which,c.lastEvent=t,void 0===t.pageX&&void 0!==t.center&&void 0!==t.center.x&&(t.pageX=t.center.x,t.pageY=t.center.y),"start"===r[2]&&(M._handleMouseDown(t),M._setClickMaybe(!1),f.boundDocumentHandlers&&g(document).on("mousemove.geojs",M._handleMouseUpDocument)),"start"!==r[2]&&"move"!==r[2]||(f.boundDocumentHandlers?M._handleMouseMoveDocument(t):M._handleMouseMove(t)),"end"!==r[2]&&"cancel"!==r[2]||(f.boundDocumentHandlers?M._handleMouseUpDocument(t):M._handleMouseUp(t),c.lastEvent=null),"tap"!==r[2]||f.boundDocumentHandlers||(t.which=1,c.lastEventType=null,M._handleMouseDown(t),M._handleMouseUp(t),c.lastEventType=r[2]))}},this._repeatMouseMoveEvent=function(t){if(r&&r.modifiers){var e=r.modifiers.alt,n=r.modifiers.ctrl,i=r.modifiers.meta,o=r.modifiers.shift;M._getMouseModifiers(t),r.modifiers.alt===e&&r.modifiers.ctrl===n&&r.modifiers.meta===i&&r.modifiers.shift===o||(f.boundDocumentHandlers?M.map().geoTrigger(y.actionmove,{state:M.state(),mouse:M.mouse(),event:t}):M.map().geoTrigger(y.mousemove,M.mouse()))}},this.retriggerMouseMove=function(){M.map().geoTrigger(y.mousemove,M.mouse())},this._connectEvents=function(){if(!e.map)return M;M._disconnectEvents(),d=g(e.map.node()),M._handleMouseWheel=function(){var t={};function n(n){var r,i;E||(t!==h&&(h=t={kind:"wheel",scroll:{x:0,y:0}}),n.preventDefault(),n.deltaFactor=1,1===n.originalEvent.deltaMode?n.deltaFactor=40:2===n.originalEvent.deltaMode&&(n.deltaFactor=g(window).height()),r=n.originalEvent.deltaX||0,i=n.originalEvent.deltaY||0,r=r*e.wheelScaleX*n.deltaFactor/120,i=i*e.wheelScaleY*n.deltaFactor/120,t.scroll.x+=r,t.scroll.y+=i)}function i(n){var i,o;if(t===h){if(M._getMousePosition(n),M._getMouseButton(n),M._getMouseModifiers(n),o=(b({wheel:!0},r.modifiers,e.actions)||{}).action){var a=M.map().transitionCancel("wheel."+o);switch((a|=M.cancel(v.momentum,!0))&&(r.geo=M.map().displayToGcs(r.map),r.mapgcs=M.map().displayToGcs(r.map,null)),o){case v.pan:M.map().pan({x:h.scroll.x,y:h.scroll.y},void 0,"limited");break;case v.zoom:i=-h.scroll.y,k(i,r);break;case v.rotate:M.map().rotation(M.map().rotation()+h.scroll.y*e.rotateWheelScale,r)}M.map().geoTrigger(y.actionwheel,{state:M.state(),mouse:M.mouse(),eventData:n})}h={}}}return e.throttle>0?x(e.throttle,!1,i,n):function(t){n(t),i(t)}}(),k=function(){var t,n,r,i=0,a=400;function s(a,s){var u,l=M.map();t=o.deepMerge({},s),i+=a,void 0===r&&(n=r=l.zoom()),r+=a,l&&Math.abs(i)>=1&&e.discreteZoom&&!e.zoomAnimation.enabled&&(u=Math.round(i+l.zoom()),i=i+l.zoom()-u,l.zoom(u,t))}function u(){var o,a=M.map();a&&(e.zoomAnimation.enabled?(o=r,e.discreteZoom&&(o=Math.round(o))===n&&r!==n&&(o=n+(r>n?1:-1)),(o=Math.round(1e6*a._fix_zoom(o))/1e6)!==a.zoom()?(a.transitionCancel("debounced_zoom."+v.zoom),a.transition({zoom:o,zoomOrigin:t,duration:e.zoomAnimation.duration,ease:e.zoomAnimation.ease,done:function(t){t=t||{};var n=new RegExp("\\."+v.zoom+"$");t.next||t.cancel&&!((""+t.source).search(n)<0)||(r=void 0),e.discreteZoom&&t.cancel&&t.transition&&t.transition.end&&(""+t.source).search(n)<0&&a.zoom(t.transition.end.zoom,t.transition.end.zoomOrigin)}})):r=void 0):(o=i+a.zoom(),e.discreteZoom&&(o=Math.round(o)),a.zoom(o,t))),i=0}!0!==e.discreteZoom&&e.discreteZoom>0&&(a=e.discreteZoom);return(!0===e.discreteZoom||e.discreteZoom>0)&&!e.zoomAnimation.enabled?_(a,!1,u,s):function(t,e){(t||void 0!==r)&&(s(t,e),u())}}(),o.adjustActions(e.actions);var t={};if(["right","pan","rotate"].forEach((function(n){t[n]=e.actions.some((function(t){return t.input[n]}))})),d.on("wheel.geojs",M._handleMouseWheel),d.on("mousemove.geojs",M._handleMouseMove),d.on("mousedown.geojs",M._handleMouseDown),d.on("mouseup.geojs",M._handleMouseUp),d.on("dragstart",(function(){return!1})),t.right&&d.on("contextmenu.geojs",(function(){return!1})),e.keyboard&&e.keyboard.actions){u=a(d[0]);var i=[];for(var s in e.keyboard.actions)e.keyboard.actions.hasOwnProperty(s)&&(u.bind(e.keyboard.actions[s],function(t){return function(e,n){M._handleKeys(t,e,n)}}(s)),i=i.concat(e.keyboard.actions[s]));e.keyboard.metakeyMouseEvents&&e.keyboard.metakeyMouseEvents.forEach((function(t){u.bind(t,M._repeatMouseMoveEvent,"keydown"),u.bind(t,M._repeatMouseMoveEvent,"keyup"),i.push(t)})),l=i}if(d.toggleClass("highlight-focus",!!(l&&l.length&&e.keyboard.focusHighlight)),(M.hasTouchSupport()||e.alwaysTouch)&&(t.pan||t.rotate)){var f;try{(f=n(3267))&&f.Manager||(f=void 0)}catch(t){}if(void 0!==f){var p=[],m=["hammer.input"];t.rotate&&(p.push([f.Rotate,{enable:!0}]),m=m.concat(["rotatestart","rotateend","rotatemove"])),t.pan&&(p.push([f.Pan,{direction:f.DIRECTION_ALL}]),m=m.concat(["panstart","panend","panmove"])),p.push([f.Tap,{event:"doubletap",taps:2}]),p.push([f.Tap,{event:"singletap"},void 0,["doubletap"]]),m=m.concat(["singletap"]);var w={recognizers:p,preventDefault:!0};(c={manager:new f.Manager(d[0],w),touchSupport:M.hasTouchSupport(),lastTime:0}).manager.get("doubletap").recognizeWith("singletap"),m.forEach((function(t){c.manager.on(t,M._handleTouch)}))}}return M},this._disconnectEvents=function(){return l&&(u&&u.unbind(l),l=null,u=null),c&&(c.manager.destroy(),c=null),d&&(d.off(".geojs"),d=null),M._handleMouseWheel=function(){},k=function(){},M},this.map=function(t){return void 0!==t?(e.map=t,M._connectEvents(),M):e.map},this.options=function(t){return void 0===t?Object.assign({},e):(Object.assign(e,t),M._connectEvents(),M)},this._getMousePosition=function(t){if(void 0!==t.pageX&&void 0!==t.pageY){var e,n,i=d.offset();e=(n=(new Date).valueOf())-r.time,r.time=n,r.deltaTime=e,r.velocity={x:(t.pageX-r.page.x)/e,y:(t.pageY-r.page.y)/e},r.page={x:t.pageX,y:t.pageY},r.map={x:t.pageX-i.left,y:t.pageY-i.top};try{r.geo=M.map().displayToGcs(r.map),r.mapgcs=M.map().displayToGcs(r.map,null)}catch(t){r.geo=r.mapgcs=null}}},this._getMouseButton=function(t){if(void 0!==t.buttons||void 0!==t.which){for(var e in r.buttons)r.buttons.hasOwnProperty(e)&&(r.buttons[e]=!1);if(void 0!==t.buttons)r.buttons.left=!!(1&t.buttons),r.buttons.right=!!(2&t.buttons),r.buttons.middle=!!(4&t.buttons);else if("mouseup"!==t.type)switch(t.which){case 1:r.buttons.left=!0;break;case 2:r.buttons.middle=!0;break;case 3:r.buttons.right=!0}!t.which||t.which>=1&&t.which<=3||(r.buttons[t.which]=!0)}},this._getMouseModifiers=function(t){r.modifiers.alt=t.altKey,r.modifiers.ctrl=t.ctrlKey,r.modifiers.meta=t.metaKey,r.modifiers.shift=t.shiftKey},this._getSelection=function(){var t=f.origin,e=M.mouse(),n=M.map(),r={},i={},a=e.map;if(f.actionRecord&&o.isFunction(f.actionRecord.selectionConstraint)){var s=f.actionRecord.selectionConstraint(e.mapgcs,t.mapgcs);a=s?n.gcsToDisplay(s.pos,null):a}else if(e.modifiers.shift){var u=Math.pow(Math.abs((a.x-t.map.x)*(a.y-t.map.y)),.5);a={x:t.map.x+Math.sign(a.x-t.map.x)*u,y:t.map.y+Math.sign(a.y-t.map.y)*u}}return r.upperLeft={x:Math.min(t.map.x,a.x),y:Math.min(t.map.y,a.y)},r.lowerRight={x:Math.max(t.map.x,a.x),y:Math.max(t.map.y,a.y)},r.upperRight={x:r.lowerRight.x,y:r.upperLeft.y},r.lowerLeft={x:r.upperLeft.x,y:r.lowerRight.y},i.upperLeft=n.displayToGcs(r.upperLeft,null),i.lowerRight=n.displayToGcs(r.lowerRight,null),i.upperRight=n.displayToGcs(r.upperRight,null),i.lowerLeft=n.displayToGcs(r.lowerLeft,null),p.data([{ul:i.upperLeft,ur:i.upperRight,ll:i.lowerLeft,lr:i.lowerRight}]),p.draw(),{display:r,gcs:i,mouse:e,origin:Object.assign({},f.origin)}},this.cancel=function(t,e){var n;return(n=t?f.action===t:!!f.action)&&(e||(h={}),O()),n},this._setClickMaybe=function(t){C=t,m&&(window.clearTimeout(m),m=null)},this._handleMouseDown=function(t){var n,i;if(!(E||c&&"tap"===c.lastEventType&&(new Date).valueOf()-c.lastTime<1e3)){M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),M.map().geoTrigger(y.mousedown,M.mouse()),!e.click.enabled||r.buttons.left&&!e.click.buttons.left||r.buttons.right&&!e.click.buttons.right||r.buttons.middle&&!e.click.buttons.middle||(M._setClickMaybe({x:r.page.x,y:r.page.y,buttons:Object.assign({},r.buttons)}),e.click.duration>0&&(m=window.setTimeout((function(){C=!1,m=null}),e.click.duration))),n=((i=b(r.buttons,r.modifiers,e.actions))||{}).action;var a=M.map();a.transitionCancel("_handleMouseDown"+(n?"."+n:"")),M.cancel(v.momentum),r.velocity={x:0,y:0},n&&(h={kind:"move"},A+=1,f={action:n,actionRecord:i,origin:o.deepMerge({},r),initialZoom:a.zoom(),initialRotation:a.rotation(),initialEventRotation:t.rotation,stateId:A,delta:{x:0,y:0}},i.selectionRectangle&&(T&&(T.clear(),a.deleteLayer(T),T=null),T=a.createLayer("feature",{features:[w.capabilities.color],autoshareRenderer:!1}),(p=T.createFeature("quad",{gcs:a.gcs()})).style({opacity:.25,color:{r:.3,g:.3,b:.3}}),a.geoTrigger(y.brushstart,M._getSelection())),a.geoTrigger(y.actiondown,{state:M.state(),mouse:M.mouse(),event:t}),e.throttle>0?g(document).on("mousemove.geojs",x(e.throttle,M._handleMouseMoveDocument)):g(document).on("mousemove.geojs",M._handleMouseMoveDocument),g(document).on("mouseup.geojs",M._handleMouseUpDocument),f.boundDocumentHandlers=!0)}},this._handleMouseMove=function(t){E||f.boundDocumentHandlers||(e.click.cancelOnMove&&C&&M._setClickMaybe(!1),M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),C||M.map().geoTrigger(y.mousemove,M.mouse()))},this._handleZoomrotate=function(t){var n=Math.log2(t.scale);if(!f.zoomrotateAllowZoom&&n&&Math.abs(n)>=Math.log2(1+e.zoomrotateMinimumZoom)&&(e.zoomrotateMinimumZoom&&(f.initialZoom-=n),f.zoomrotateAllowZoom=!0),f.zoomrotateAllowZoom&&n){var r=f.initialZoom+n;M.map().zoom(r,f.origin)}var i=(t.rotation-f.initialEventRotation)*Math.PI/180;if(!f.zoomrotateAllowRotation&&i&&Math.abs(i)>=e.zoomrotateMinimumRotation&&(e.zoomrotateMinimumRotation&&(f.initialEventRotation=t.rotation,i=0),f.zoomrotateAllowRotation=!0),f.zoomrotateAllowRotation){var a=f.initialRotation+i;(i=o.wrapAngle(a-M.map().rotation()))&&(i*(f.lastRotationDelta||0)>=0||Math.abs(i)>=e.zoomrotateReverseRotation)&&(M.map().rotation(a,f.origin),f.lastRotationDelta=i)}var s=f.origin.page;if(f.initialEventGeo){var u=d.offset();(s=M.map().gcsToDisplay(f.initialEventGeo)).x+=u.left,s.y+=u.top}var l=t.pageX-s.x,c=t.pageY-s.y,h=l*l+c*c;!f.zoomrotateAllowPan&&h&&h>=e.zoomrotateMinimumPan*e.zoomrotateMinimumPan&&(e.zoomrotateMinimumPan?(l=c=0,f.initialEventGeo=M.mouse().geo):f.initialEventGeo=f.origin.geo,f.zoomrotateAllowPan=!0),f.zoomrotateAllowPan&&(l||c)&&M.map().pan({x:l,y:c})},this._handleMouseMoveDocument=function(t){var n,i,o;if(M.map()&&!E&&"move"===h.kind){if(M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),e.click.cancelOnMove)if(void 0===C.x||void 0===C.y)M._setClickMaybe(!1);else if(!0!==e.click.cancelOnMove||r.page.x===C.x&&r.page.y===C.y){Math.sqrt(Math.pow(r.page.x-C.x,2)+Math.pow(r.page.y-C.y,2))>=e.click.cancelOnMove&&M._setClickMaybe(!1)}else M._setClickMaybe(!1);if(!C)if(f.action){if(n=r.map.x-f.origin.map.x-f.delta.x,i=r.map.y-f.origin.map.y-f.delta.y,f.delta.x+=n,f.delta.y+=i,f.action===v.pan)M.map().pan({x:n,y:i},void 0,"limited");else if(f.action===v.zoom)k(-i*e.zoomScale/120,f);else if(f.action===v.rotate){var a,s;void 0===f.origin.rotation&&(a=f.origin.map.x-M.map().size().width/2,s=f.origin.map.y-M.map().size().height/2,f.origin.rotation=M.map().rotation()-Math.atan2(s,a)),a=r.map.x-M.map().size().width/2,s=r.map.y-M.map().size().height/2,M.map().rotation(f.origin.rotation+Math.atan2(s,a))}else f.action===v.zoomrotate?M._handleZoomrotate(t):f.actionRecord.selectionRectangle&&(o=M._getSelection(),M.map().geoTrigger(y.brush,o));M.map().geoTrigger(y.actionmove,{state:M.state(),mouse:M.mouse(),event:t}),t.preventDefault()}else console.log("WARNING: Invalid state in mapInteractor.")}},this._zoomFromSelection=function(t,e,n){if((t===v.zoomselect||t===v.unzoomselect)&&e.x!==n.x&&e.y!==n.y){var r,i,o=M.map(),a=o.size(),s={x:Math.abs((n.x-e.x)/a.width),y:Math.abs((n.y-e.y)/a.height)};if(t===v.zoomselect?(i=o.displayToGcs({x:(e.x+n.x)/2,y:(e.y+n.y)/2},null),r=o.zoom()-Math.log2(Math.max(s.x,s.y))):(r=o.zoom()+Math.log2(Math.max(s.x,s.y)),i=o.center(void 0,null)),o.discreteZoom()&&(r=Math.floor(r)),o.zoom(r),t===v.zoomselect)o.center(i,null);else{var u=o.gcsToDisplay(i,null);o.pan({x:(e.x+n.x)/2-u.x,y:(e.y+n.y)/2-u.y})}}},this._handleMouseUpDocument=function(t){var n,i;if(!E&&(h={},M._setClickMaybe(!1),M._getMouseButton(t),M._getMouseModifiers(t),g(document).off(".geojs"),f.boundDocumentHandlers=!1,r.buttons.right&&t.preventDefault(),f.actionRecord&&f.actionRecord.selectionRectangle&&(M._getMousePosition(t),n=M._getSelection(),T.clear(),M.map().deleteLayer(T),T=null,p=null,M.map().geoTrigger(y.brushend,n),!0!==f.actionRecord.selectionRectangle&&M.map().geoTrigger(f.actionRecord.selectionRectangle,n),M._zoomFromSelection(f.action,n.display.lowerLeft,n.display.upperRight),M.map().geoTrigger(y.actionselection,{state:M.state(),mouse:M.mouse(),event:t,lowerLeft:n.display.lowerLeft,upperRight:n.display.upperRight})),M.map().geoTrigger(y.actionup,{state:M.state(),mouse:M.mouse(),event:t}),i=f.action,O(),e.momentum.enabled&&e.momentum.actions.includes(i))){var o=(new Date).valueOf(),a=o-r.time+r.deltaTime;o-r.time<e.momentum.stopTime?(r.velocity.x*=r.deltaTime/a,r.velocity.y*=r.deltaTime/a,r.deltaTime=a):r.velocity.x=r.velocity.y=0,M.springBack(!0,i)}},this._handleMouseUp=function(t){if(!E){M._getMouseButton(t),C&&M._handleMouseClick(t);var e=M.mouse();e.buttonsDown=C.buttons,M.map().geoTrigger(y.mouseup,e)}},this._handleMouseClick=function(t){f.actionRecord&&f.actionRecord.selectionRectangle&&(T.clear(),M.map().deleteLayer(T),T=null,p=null,f.action=f.actionRecord=null),M._getMouseButton(t),M._getMouseModifiers(t),M.cancel(v.pan),g(document).off(".geojs"),f.boundDocumentHandlers=!1;var e=M.mouse();e.buttonsDown=C.buttons,e.evt=t,M._setClickMaybe(!1),M.map().geoTrigger(y.mouseclick,e)},this._handleMouseWheel=function(){},this.springBack=function(t,n){f.action!==v.momentum&&(t||(r.velocity={x:0,y:0}),f.origAction=n,f.action=v.momentum,f.origin=M.mouse(),f.momentum=M.mouse(),f.start=new Date,f.handler=function(){var t,n,r,i;if(f.action===v.momentum&&M.map()&&!M.map().transition())if(i=Math.min(f.momentum.deltaTime,30),r=f.start.valueOf(),f.start=new Date,t=P(f.momentum.velocity,f.start-r)){if((n=S(t))>e.momentum.maxSpeed&&(n=e.momentum.maxSpeed/n,t.x=t.x*n,t.y=t.y*n),isFinite(t.x)&&isFinite(t.y)||(t.x=0,t.y=0),f.momentum.velocity.x=t.x,f.momentum.velocity.y=t.y,f.origAction===v.zoom){var o=f.momentum.velocity.y*i;k(-o*e.zoomScale/120,f)}else M.map().pan({x:f.momentum.velocity.x*i,y:f.momentum.velocity.y*i},void 0,"limited");f.handler&&M.map().scheduleAnimationFrame(f.handler)}else O()},f.handler&&M.map().scheduleAnimationFrame(f.handler))},this.destroy=function(){M._disconnectEvents(),M.map()&&g(M.map().node()).removeClass("highlight-focus"),M.map(null)},this.mouse=function(){return o.deepMerge({},r)},this.keyboard=function(t){return void 0===t?o.deepMerge({},e.keyboard||{}):M.options({keyboard:t})},this.state=function(){return o.deepMerge({},f)},this.pause=function(t){return void 0===t?E:(E=!!t,M)},this.addAction=function(t,n){t&&t.action&&t.input&&(o.addAction(e.actions,t,n),e.map&&e.actions.some((function(t){return t.input.right}))&&(d.off("contextmenu.geojs"),d.on("contextmenu.geojs",(function(){return!1}))))},this.hasAction=function(t,n,r){return o.hasAction(e.actions,t,n,r)},this.removeAction=function(t,n,r){var i=o.removeAction(e.actions,t,n,r);return e.map&&!e.actions.some((function(t){return t.input.right}))&&d.off("contextmenu.geojs"),i},this.simulateEvent=function(t,e){var n,r,i,o,a;if(!M.map())return M;if("keyboard"===t&&u){var s={shiftKey:e.shift||e.shiftKey||!1,ctrlKey:e.ctrl||e.ctrlKey||!1,altKey:e.alt||e.altKey||!1,metaKey:e.meta||e.metaKey||!1,toString:function(){return e.keys},stopPropagation:function(){},preventDefault:function(){},simulated:!0};u.trigger(s,e.event)}else r=e.page||{},e.map&&(i=d.offset(),r.x=e.map.x+i.left,r.y=e.map.y+i.top),"left"===e.button?(o=1,a=1):"right"===e.button?(o=3,a=2):"middle"===e.button&&(o=2,a=4),e.modifiers=e.modifiers||[],e.wheelDelta=e.wheelDelta||{},n=g.Event(t,{pageX:r.x,pageY:r.y,which:o,buttons:a,altKey:e.modifiers.indexOf("alt")>=0,ctrlKey:e.modifiers.indexOf("ctrl")>=0,metaKey:e.modifiers.indexOf("meta")>=0,shiftKey:e.modifiers.indexOf("shift")>=0,center:e.center,rotation:e.touch?e.rotation||0:e.rotation,scale:e.touch?e.scale||1:e.scale,pointers:e.pointers,pointerType:e.pointerType,originalEvent:{deltaX:e.wheelDelta.x,deltaY:e.wheelDelta.y,deltaMode:e.wheelMode,preventDefault:function(){},stopPropagation:function(){},stopImmediatePropagation:function(){}}}),e.touch&&c?M._handleTouch(n):d.trigger(n),t.indexOf(".geojs")>=0&&g(document).trigger(n)},this._connectEvents(),this};r(s,i),t.exports=s},2225:function(t,e,n){function r(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||i(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var a=n(4626),s=n(1275),u=n(7541),l=function(t){"use strict";if(!(this instanceof l))return new l(t);t=t||{},u.call(this,t);var e=n(77),o=n(642),a=n(4279);a=a.__esModule?a.default:a;var s=this,c=this._init,f=null,h=e(),d=0,p=0,m=0;return this.featureType="marker",this._updateRangeTree=function(){if(!(h.timestamp()>=s.dataTime().timestamp()&&h.timestamp()>=s.timestamp())){var t,e,n=s.style.get("radius"),o=s.style.get("strokeWidth"),u=s.style.get("radiusIncludesStroke"),c=s.style.get("strokeOffset"),g=s.style.get("scaleWithZoom");e=s.position(),d=0,p=0,m=0,t=s.data().map((function(t,r){var i=e(t,r),a=g(t,r),s=n(t,r),f=o(t,r),h=Math.sign(c(t,r)),y=u(t,r),v=(y=void 0===y||y)?s+f*(h+1)/2:s+f,x=y?s+f*(h-1)/2:s;switch(a=l.scaleMode[a]||(a>=1&&a<=3?a:0)){case l.scaleMode.stroke:x>d&&(d=x),f>m&&(m=f);break;case l.scaleMode.fill:case l.scaleMode.all:v>p&&(p=v);break;default:v>d&&(d=v)}return[i.x,i.y]})),f=new a(t.length);var y,v=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=i(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(t);try{for(v.s();!(y=v.n()).done;){var x=r(y.value,2),_=x[0],b=x[1];f.add(_,b)}}catch(t){v.e(t)}finally{v.f()}f.finish(),h.modified()}},this._approximateMaxRadius=function(t){s._updateRangeTree();var e=Math.pow(2,t);return Math.max(d+m*e,p*e)},this.pointSearch=function(t,e){var n,r,i,o,a=[],u=[],c=[],h=s.gcs(),d=s.style.get("radius"),p=s.style.get("strokeWidth"),m=s.style.get("radiusIncludesStroke"),g=s.style.get("strokeOffset"),y=s.style.get("scaleWithZoom");if(!(i=s.data())||!i.length)return{found:[],index:[]};s._updateRangeTree();var v=s.layer().map();e=null===e?v.gcs():void 0===e?v.ingcs():e;var x=v.gcsToDisplay(t,e),_=v.zoom(),b=Math.pow(2,_),w=this._approximateMaxRadius(_);return o=[v.displayToGcs({x:x.x-w,y:x.y-w},h),v.displayToGcs({x:x.x+w,y:x.y-w},h),v.displayToGcs({x:x.x-w,y:x.y+w},h),v.displayToGcs({x:x.x+w,y:x.y+w},h)],n={x:Math.min(o[0].x,o[1].x,o[2].x,o[3].x),y:Math.min(o[0].y,o[1].y,o[2].y,o[3].y)},r={x:Math.max(o[0].x,o[1].x,o[2].x,o[3].x),y:Math.max(o[0].y,o[1].y,o[2].y,o[3].y)},a=f.range(n.x,n.y,r.x,r.y),(a=Uint32Array.from(a).sort()).forEach((function(t){var e=i[t],n=d(i[t],t),r=y(i[t],t),o=g(i[t],t),a=r?p(i[t],t):0,f=m(e,t),_=(f=void 0===f||f)?n+a*(o-1)/2:n;n=_+a;var w,M,A,T=s.position()(e,t);switch(r=l.scaleMode[r]||(r>=1&&r<=3?r:0)){case l.scaleMode.fill:n=_*b+a;break;case l.scaleMode.stroke:n=_+a*b;break;case l.scaleMode.all:n*=b}n&&(A=n*n,(w=(T=v.gcsToDisplay(T,h)).x-x.x)*w+(M=T.y-x.y)*M<=A&&(u.push(e),c.push(t)))})),{found:u,index:c}},this.polygonSearch=function(t,e,n){var r,i,a,u,c=s.gcs(),h=[],d=[],p={},m=s.layer().map(),g=s.data(),y=s.style.get("radius"),v=s.style.get("strokeWidth"),x=s.style.get("radiusIncludesStroke"),_=s.style.get("strokeOffset"),b=s.style.get("scaleWithZoom"),w=m.zoom(),M=Math.pow(2,w),A=this._approximateMaxRadius(w);return n=null===n?m.gcs():void 0===n?m.ingcs():n,t.outer||(t={outer:t,inner:[]}),t.outer.length<3||!g||!g.length?{found:[],index:[],extra:{}}:((e=e||{}).partial=e.partial||!1,(t={outer:m.gcsToDisplay(t.outer,n),inner:(t.inner||[]).map((function(t){return m.gcsToDisplay(t,n)}))}).outer.forEach((function(t){i||(i={x:t.x,y:t.y},a={x:t.x,y:t.y}),t.x<i.x&&(i.x=t.x),t.x>a.x&&(a.x=t.x),t.y<i.y&&(i.y=t.y),t.y>a.y&&(a.y=t.y)})),s._updateRangeTree(),u=[m.displayToGcs({x:i.x-A,y:i.y-A},c),m.displayToGcs({x:a.x+A,y:i.y-A},c),m.displayToGcs({x:a.x+A,y:a.y+A},c),m.displayToGcs({x:i.x-A,y:a.y+A},c)],i={x:Math.min(u[0].x,u[1].x,u[2].x,u[3].x),y:Math.min(u[0].y,u[1].y,u[2].y,u[3].y)},a={x:Math.max(u[0].x,u[1].x,u[2].x,u[3].x),y:Math.max(u[0].y,u[1].y,u[2].y,u[3].y)},r=f.range(i.x,i.y,a.x,a.y),(r=Uint32Array.from(r).sort()).forEach((function(n){var r=g[n],i=s.position()(r,n),a=y(r,n),u=b(r,n),f=_(r,n),w=u?v(r,n):0,A=x(r,n),T=(A=void 0===A||A)?a+w*(f-1)/2:a;switch(a=T+w,u=l.scaleMode[u]||(u>=1&&u<=3?u:0)){case l.scaleMode.fill:a=T*M+w;break;case l.scaleMode.stroke:a=T+w*M;break;case l.scaleMode.all:a*=M}if(a){i=m.gcsToDisplay(i,c);var E=o.distanceToPolygon2d(i,t);(E>=a||E>=0&&"center"===e.partial||E>=-a&&e.partial&&"center"!==e.partial)&&(h.push(r),d.push(n),p[n]={partial:E<a,distance:E})}})),{found:h,index:d,extra:p})},this._init=function(t){return t=o.deepMerge({},{style:Object.assign({},{radius:6.25,radiusIncludesStroke:!0,strokeColor:{r:.851,g:.604,b:0},strokeOffset:-1,strokeOpacity:1,strokeWidth:1.25,fillColor:{r:1,g:.839,b:.439},fillOpacity:.8,symbol:0,symbolValue:0,rotation:0,scaleWithZoom:l.scaleMode.none,rotateWithMap:!1},t&&void 0===t.style?{}:t.style)},t),c.call(s,t),s},s};l.create=function(t,e){"use strict";return(e=e||{}).type="marker",s.create(t,e)},l.capabilities={feature:"marker"},l.primitiveShapes=u.primitiveShapes,l.symbols={circle:0,ellipse:0,flowerBase:1,flowerMax:16,triangle:16,diamond:17,starBase:17,starMax:16,square:32,rectangle:32,crossBase:33,crossMax:16,oval:48,jackBase:49,jackMax:16,drop:64,dropBase:65,dropMax:16,arrow:80,arrowBase:81,arrowMax:16,length:96},["flower","star","cross","jack","drop","arrow"].forEach((function(t){for(var e=2;e<=l.symbols[t+"Max"];e+=1)l.symbols[t+e]=l.symbols[t+"Base"]-2+e})),l.scaleMode={none:0,fill:1,stroke:2,all:3},a(l,u),t.exports=l},6124:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);var e=n(642);t=t||{},i.call(this,t);var r=this,a=this._init,s={};return this.featureType="mesh",this.mesh=function(t,e){if(void 0===t)return s;if("string"==typeof t&&void 0===e)return s[t];if(void 0===e){var n=Object.assign({},{gridWidth:function(){return t.gridHeight?Math.floor(r.data().length/t.gridHeight):Math.floor(Math.sqrt(r.data().length))},gridHeight:function(){return t.gridWidth?Math.floor(r.data().length/t.gridWidth):Math.floor(Math.sqrt(r.data().length))}},s,t);s=n}else s[t]=e;return r.modified(),r},this.mesh.get=function(t){if(void 0===t){var n,i={};for(n in s)s.hasOwnProperty(n)&&(i[n]=r.mesh.get(n));return i}return e.ensureFunction(s[t])},this.position=function(t){return void 0===t?r.style("position"):(r.style("position",t),r.dataTime().modified(),r.modified(),r)},this._createMesh=function(t,e){t=t||{},e=e||{};var n,i,o,a,s,u,l,c,f,h,d,p,m,g,y,v,x=r.data(),_=r.position(),b=r.mesh.get("elements")(x),w=r.mesh.get("elementPacking")(x),M=r.mesh.get("gridWidth")(x),A=r.mesh.get("gridHeight")(x),T=r.mesh.get("wrapLongitude")(x),E=r.mesh.get("x0")(x),C=r.mesh.get("y0")(x),k=r.mesh.get("dx")(x),S=r.mesh.get("dy")(x),O=M,P={shape:"square",elements:[],elementIndex:[]};if(b){var L=b.length&&Array.isArray(b[0]);if("square"===w||"triangle"!==w&&(!L&&!(b.length%4)&&b.length%3||L&&4===b[0].length))if(P.shape="square",L)for(n=0;n<b.length;n+=1)P.elements.push(b[n][0]),P.elements.push(b[n][1]),P.elements.push(b[n][3]),P.elements.push(b[n][2]),P.elements.push(b[n][3]),P.elements.push(b[n][1]),P.elementIndex.push(n),P.elementIndex.push(n);else for(n=o=0;n<b.length-3;n+=4,o+=1)P.elements.push(b[n]),P.elements.push(b[n+1]),P.elements.push(b[n+3]),P.elements.push(b[n+2]),P.elements.push(b[n+3]),P.elements.push(b[n+1]),P.elementIndex.push(o),P.elementIndex.push(o);else if(P.shape="triangle",L)for(n=0;n<b.length;n+=1)P.elements.push(b[n][0]),P.elements.push(b[n][1]),P.elements.push(b[n][2]),P.elementIndex.push(n);else for(P.elements=b.slice(0,b.length-b.length%3),n=o=0;n<b.length-2;n+=3,o+=1)P.elementIndex.push(o);u=x.length,c=!0}else{if(Object.keys(t).length?M*A>x.length&&(A=Math.floor(x.length/M)):Object.keys(e).length&&(M-1)*(A-1)>x.length&&(A=Math.floor(x.length/(M-1))+1),T=!(void 0!==T&&!T),!(c=null==E||null==C||!k||!S)&&T&&(E<-180||E>180||E+k*(M-1)<-180||E+k*(M-1)>180)&&k>-180&&k<180&&k*(M-1)<360.0001){for(p=[],m=[],n=0;n<M;n+=1){for(y=E+n*k;y<-180;)y+=360;for(;y>180;)y-=360;n&&Math.abs(y-p[p.length-1])>180&&(y>p[p.length-1]?(p.push(y-360),p.push(p[p.length-2]+360),m.push(n),m.push(n+1)):(p.push(y+360),p.push(p[p.length-2]-360),m.push(n),m.push(n+1)),g=n),p.push(y),m.push(n)}if(M+=2,Math.abs(Math.abs(O*k)-360)<.01){for(M+=1,y=E+O*k;y<-180;)y+=360;for(;y>180;)y-=360;p.push(y),m.push(0)}}if(u=M*A,void 0!==g)for(P.index=new Array(u),n=0;n<u;n+=1)v=n-(o=Math.floor(n/M))*M,(v+=v>g?-2:0)>=O&&(v-=O),v+=o*O,P.index[n]=v;for(o=s=0;o<A-1;o+=1,s+=1)for(n=0;n<M-1;n+=1,s+=1)n!==g&&(P.elements.push(s),P.elements.push(s+1),P.elements.push(s+M),P.elements.push(s+M+1),P.elements.push(s+M),P.elements.push(s+1),P.elementIndex.push(o*(M-1)+(m?m[n]:n)),P.elementIndex.push(o*(M-1)+(m?m[n]:n)))}P.verticesPerElement="triangle"===P.shape?3:6;var R=P.verticesPerElement;if(e.used){var I=new Array(P.elementIndex[P.elementIndex.length-1]+1);for(n=0;n<I.length;n+=1)I[n]=e.used(x[n],n);for(n=0;n<P.elementIndex.length&&I[P.elementIndex[n]];n+=1);if(n<P.elementIndex.length){for(o=n;n<P.elementIndex.length;n+=1)if(I[P.elementIndex[n]]){for(P.elementIndex[o]=P.elementIndex[n],a=0;a<3;a+=1)P.elements[3*o+a]=P.elements[3*n+a];o+=1}P.elements.splice(3*o),P.elementIndex.splice(o)}}if(t.used){for(n=0;n<u&&(s=P.index?P.index[n]:n,t.used(x[s],s));n+=1);if(n!==u){l=n;var D=new Array(u);for(o=0;o<l;o+=1)D[o]=o;if(D[l]=-1,!P.index)for(P.index=new Array(x.length),o=0;o<x.length;o+=1)P.index[o]=o;for(n=l+1;n<u;n+=1)s=P.index[n],t.used(x[s],s)?(D[n]=l,P.index[l]=P.index[n],l+=1):D[n]=-1;for(P.index.splice(l),n=a=0;n<P.elements.length;n+=R){for(o=0;o<R&&!(D[P.elements[n+o]]<0);o+=1)P.elements[a+o]=D[P.elements[n+o]];o===R&&(P.elementIndex[Math.floor(a/3)]=P.elementIndex[Math.floor(n/3)],6===R&&(P.elementIndex[Math.floor(a/3)+1]=P.elementIndex[Math.floor(n/3)+1]),a+=R)}P.elements.splice(a),P.elementIndex.splice(Math.floor(a/3)),u=l}}if(e.used&&void 0===g){var N=new Array(u),F=P.index;for(P.index=[],n=0;n<P.elements.length;n+=1)void 0===N[a=P.elements[n]]&&(N[a]=P.index.length,P.index.push(F?F[a]:a)),P.elements[n]=N[a];u=P.index.length}for(h in P.pos=new Array(3*u),t)"used"!==h&&t.hasOwnProperty(h)&&(P[h]=new Array(u));for(n=i=0;n<u;n+=1,i+=3)for(h in f=x[s=P.index?P.index[n]:n],c?(d=_(f,s),P.pos[i]=d.x,P.pos[i+1]=d.y,P.pos[i+2]=d.z||0):(P.pos[i]=void 0===g?E+k*(s%M):p[n%M],P.pos[i+1]=C+S*Math.floor(s/M),P.pos[i+2]=0,d={x:P.pos[i],y:P.pos[i+1],z:P.pos[i+2]}),t)"used"!==h&&t.hasOwnProperty(h)&&(P[h][n]=t[h](f,s,d));for(h in e)if("used"!==h&&e.hasOwnProperty(h)){var j=e[h];for(P[h]=new Array(P.elementIndex.length),n=0;n<P.elementIndex.length;n+=1)f=x[s=P.elementIndex[n]],P[h][n]=j(f,s)}return P.numVertices=u,P.numElements=P.elements.length/P.verticesPerElement,P},this._init=function(t){a.call(r,t),t=t||{};var e=Object.assign({},{position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t}},t.style||{});r.mesh(t.mesh||{}),r.style(e)},this};r(o,i),t.exports=o},1338:function(t,e,n){var r=n(4626),i=n(77),o=0,a=function(){"use strict";if(!(this instanceof a))return new a;var t=n(642),e=this,r=++o,s={},u=[],l=0;return this.onIdle=function(t){return l?u.push(t):t(),e},Object.defineProperty(this,"idle",{get:function(){return!l},configurable:!0}),Object.defineProperty(this,"_promises",{get:function(){return l},configurable:!0}),this.addPromise=function(t){function n(){t._geojsTracked&&t._geojsTracked[r]&&(l-=1,delete t._geojsTracked[r]),l||u.splice(0,u.length).forEach((function(t){t()}))}return t._geojsTracked||(t._geojsTracked={}),t._geojsTracked[r]||(t._geojsTracked[r]=!0,l+=1),t.always?t.always(n):t.then(n,n),e},this.removePromise=function(t){return t._geojsTracked&&t._geojsTracked[r]&&(l-=1,delete t._geojsTracked[r],l||u.splice(0,u.length).forEach((function(t){t()}))),e},this.geoOn=function(n,r){return Array.isArray(n)?(n.forEach((function(t){e.geoOn(t,r)})),e):t.isFunction(r)?(s.hasOwnProperty(n)||(s[n]=[]),s[n].push(r),e):(console.warn("Handler for "+n+" is not a function",r,e),e)},this.geoOnce=function(t,n){var r=function(i){e.geoOff(t,r),n.call(e,i)};return e.geoOn(t,r),r},this.geoIsOn=function(t,n){return Array.isArray(t)?t.some((function(t){return e.geoIsOn(t,n)})):(s[t]||[]).some((function(t){return t===n||void 0===n}))},this.geoTrigger=function(t,n){return Array.isArray(t)?(t.forEach((function(t){e.geoTrigger(t,n)})),e):((n=n||{}).event=t,s.hasOwnProperty(t)&&s[t].forEach((function(r){try{r.call(e,n)}catch(e){console.warn("Event handler for "+t+" threw an error",e)}})),e)},this.geoOff=function(t,n){if(void 0===t&&(s={},u=[],l=0,r=++o),Array.isArray(t))return t.forEach((function(t){e.geoOff(t,n)})),e;if(n){if(Array.isArray(n))return n.forEach((function(n){e.geoOff(t,n)})),e}else s[t]=[];return s.hasOwnProperty(t)&&(s[t]=s[t].filter((function(t){return t!==n}))),e},this._eventHandlers=function(){return s},this._exit=function(){e.geoOff()},i.call(this),this.modified(),this};r(a,i),t.exports=a},4880:function(t,e,n){var r=n(4626),i=n(9264),o=n(1098),a=n(3842),s=n(642),u=function(t){var e=n(4912);if(!(this instanceof u))return new u(t);void 0!==(t=t||{}).mapOpacity&&void 0===t.opacity&&((t=Object.assign({},t)).opacity=t.mapOpacity),t=s.deepMerge({},this.constructor.defaults,u.tileSources[this.constructor.defaults.source]||{},u.tileSources[t.source]||{},{name:""},t),i.call(this,t);var r=this;this.mapOpacity=this.opacity,this._getTile=function(t,n){var i=n||t;return e({index:t,size:{x:r._options.tileWidth,y:r._options.tileHeight},queue:r._queue,overlap:r._options.tileOverlap,scale:r._options.tileScale,url:r._options.url.call(r,i.x,i.y,Math.max(i.level||0,0),r._options.subdomains),crossDomain:r._options.crossDomain})},this.source=function(t){if(void 0!==t)return u.tileSources[t]&&(r.url(u.tileSources[t].url),r.subdomains(u.tileSources[t].subdomains||"abc"),r.attribution(u.tileSources[t].attribution||""),r._options.maxLevel=u.tileSources[t].maxLevel||18,r._options.minLevel=u.tileSources[t].minLevel||0),r;for(var e in u.tileSources)if(u.tileSources[e].url===r.url())return e}};u.defaults=Object.assign({},i.defaults,{tileOffset:function(t){var e=256*Math.pow(2,t-1);return{x:e,y:e}},url:"",source:"osm"});var l='Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',c='<a href="https://carto.com"> Carto</a> Contributors <a href="https://www.openstreetmap.org/"> OpenStreetMap</a>';u.tileSources={"dark-matter-with-labels":{url:" https://{s}.basemaps.cartocdn.com/rastertiles/dark_all/{z}/{x}/{y}.png",attribution:c,name:"Carto Dark Matter With Labels",minLevel:0,maxLevel:18},"dark-matter-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/dark_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Dark Matter Without Labels",minLevel:0,maxLevel:18},"nationalmap-relief":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSShadedReliefOnly/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Shaded Relief",minLevel:0,maxLevel:16},"nationalmap-satellite":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryOnly/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Satellite",minLevel:0,maxLevel:16},"nationalmap-satellite-topo":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryTopo/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Satellite and Topo",minLevel:0,maxLevel:16},"nationalmap-topo":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSTopo/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Topo",minLevel:0,maxLevel:16},osm:{url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'Tile data © <a href="https://osm.org/copyright">OpenStreetMap</a> contributors',name:"OpenStreetMap",subdomains:"abc",minLevel:0,maxLevel:19},"positron-with-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/light_all/{z}/{x}/{y}.png",attribution:c,name:"Carto Positron With Labels",minLevel:0,maxLevel:18},"positron-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/light_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Positron Without Labels",minLevel:0,maxLevel:18},"stamen-terrain":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/terrain/{z}/{x}/{y}.png",attribution:l,name:"Stamen Terrain",subdomains:"abcd",minLevel:0,maxLevel:14},"stamen-terrain-background":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/terrain-background/{z}/{x}/{y}.png",attribution:l,name:"Stamen Terrain Background",subdomains:"abcd",minLevel:0,maxLevel:14},"stamen-toner":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/toner/{z}/{x}/{y}.png",attribution:l,name:"Stamen Toner",subdomains:"abcd",minLevel:0,maxLevel:20},"stamen-toner-lite":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png",attribution:l,name:"Stamen Toner Lite",subdomains:"abcd",minLevel:0,maxLevel:20},"voyager-with-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/voyager_labels_under/{z}/{x}/{y}.png",attribution:c,name:"Carto Voyager With Labels",minLevel:0,maxLevel:18},"voyager-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/voyager_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Voyager Without Labels",minLevel:0,maxLevel:18}},r(u,i),o.registerLayer("osm",u,[a.capabilities.image]),t.exports=u},2266:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=this,n=this._init;return this.featureType="path",this.position=function(t){return void 0===t?e.style("position"):(t!==e.style("position")&&(e.style("position",t),e.dataTime().modified(),e.modified()),e)},this._init=function(t){n.call(e,t);var r=Object.assign({},{strokeWidth:1,strokeColor:{r:1,g:1,b:1},position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t}},void 0===t.style?{}:t.style);return void 0!==t.position&&(r.position=t.position),e.style(r),r.position&&e.position(r.position),e.dataTime().modified(),e},this._init(t),this};r(o,i),t.exports=o},7761:function(t,e,n){var r=n(5616),i=n(4626),o=n(1275),a=n(642),s=function(t){"use strict";if(!(this instanceof s))return new s(t);t=t||{},o.call(this,t);var e,n=this,i=this._update,u=this._init;return this.featureType="pixelmap",this.position=function(t){return void 0===t?n.style("position"):(t!==n.style("position")&&(n.style("position",t),n.dataTime().modified(),n.modified()),n)},this.url=function(t){return void 0===t?n.style("url"):(t!==n.style("url")&&(n.m_srcImage=n.m_info=void 0,n.style("url",t),n.dataTime().modified(),n.modified()),n)},this.color=function(t){return void 0===t?n.style("color"):(t!==n.style("color")&&(n.style("color",t),n.dataTime().modified(),n.modified()),n)},this.indexModified=function(t,r){if(void 0===t){var i=e;return"clear"===r&&(e=void 0),i}return n.modified(),void 0===e&&(e=[t,t]),t<e[0]&&(e[0]=t),(r||t)>e[1]&&(e[1]=r||t),n},this._update=function(){return i.call(n),(n.buildTime().timestamp()<=n.dataTime().timestamp()||n.updateTime().timestamp()<n.timestamp())&&n._build(),n.updateTime().modified(),n},this.maxIndex=function(){if(n.m_info){if(void 0===n.m_info.maxIndex)for(var t in n.m_info.maxIndex=0,n.m_info.mappedColors)n.m_info.mappedColors.hasOwnProperty(t)&&(n.m_info.maxIndex=Math.max(n.m_info.maxIndex,t));return n.m_info.maxIndex}},this._computePixelmap=function(){},this._build=function(){if(n.m_srcImage)n.m_info&&n._computePixelmap();else{var t=n.style.get("url")();if(a.isReadyImage(t))n.m_srcImage=t,n._computePixelmap();else if(t){var e,i,o=r.Deferred();t instanceof Image?(n.m_srcImage=t,e=t.onload,i=t.onerror):(n.m_srcImage=new Image,t.indexOf(":")>=0&&t.indexOf("/")===t.indexOf(":")+1&&(n.m_srcImage.crossOrigin=n.style.get("crossDomain")()||"anonymous")),n.m_srcImage.onload=function(){e&&e.apply(n,arguments),n.style.get("url")()===t&&(n.m_info=void 0,n._computePixelmap()),o.resolve()},n.m_srcImage.onerror=function(){i&&i.apply(n,arguments),o.reject()},o.promise(n),n.layer().addPromise(n),t instanceof Image||(n.m_srcImage.src=t)}}return n.buildTime().modified(),n},this._init=function(t){t=t||{},u.call(n,t);var e=Object.assign({},{color:function(t,e){return{r:(255&e)/255,g:(e>>8&255)/255,b:(e>>16&255)/255,a:1}},position:a.identityFunction},void 0===t.style?{}:t.style);return void 0!==t.position&&(e.position=t.position),void 0!==t.url&&(e.url=t.url),void 0!==t.color&&(e.color=t.color),n.style(e),n.dataTime().modified(),t.quadFeature&&(n.m_srcImage=!0,n._computePixelmap()),n},this};s.create=function(t,e){"use strict";return(e=e||{}).type="pixelmap",o.create(t,e)},s.capabilities={feature:"pixelmap",lookup:"pixelmap.lookup"},i(s,o),t.exports=s},534:function(t,e,n){var r=n(4626),i=n(9264),o=n(1098),a=n(3842),s=n(7761),u=n(642),l=function(t){var e,r=n(4912);if(!(this instanceof l))return new l(t);(t=t||{}).data&&(e=t.data,delete t.data),t=u.deepMerge({},this.constructor.defaults,t),i.call(this,t);var o,a=this._init,s=this;return this._getTile=function(t,e){var n=e||t;return r({index:t,size:{x:s._options.tileWidth,y:s._options.tileHeight},queue:s._queue,overlap:s._options.tileOverlap,scale:s._options.tileScale,url:s._options.url.call(s,n.x,n.y,Math.max(n.level||0,0),s._options.subdomains),crossDomain:s._options.crossDomain})},this._init=function(){a.apply(s,arguments),s.nearestPixel(!0,!0);var n={quadFeature:s.features()[0]};t.style&&(n.style=t.style),t.color&&(n.color=t.color),o=s.createFeature("pixelmap",n),e&&o.data(e),s.style=o.style,s.data=o.data,s.indexModified=o.indexModified;var r=s.dataTime().modified;return s.dataTime().modified=function(){return o.dataTime().modified(),r()},["modified","geoOn","geoOff","geoOnce"].forEach((function(t){var e=s[t];s[t]=function(){return Array.isArray(arguments[0])||o[t].apply(this,arguments),e.apply(this,arguments)}})),s},s};l.defaults=Object.assign({},i.defaults,{features:[a.capabilities.image,s.capabilities.lookup],tileOffset:function(t){var e=256*Math.pow(2,t-1);return{x:e,y:e}},url:""}),r(l,i),o.registerLayer("pixelmap",l,[a.capabilities.image]),t.exports=l},7541:function(t,e,n){function r(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||i(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var a=n(4626),s=n(1275),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},s.call(this,t);var e=n(77),o=n(5966),a=n(6409),l=n(642),c=n(4279);c=c.__esModule?c.default:c;var f=this,h=this._init,d=null,p=e(),m=this.data,g=0,y=t.clustering,v=null,x=[],_=null,b=!1;return this.featureType="point",this.clustering=function(t){return void 0===t?y:(y&&!t?(v=null,y=!1,m(x)):t&&y!==t&&(y=t,f._clusterData()),f)},this._clusterData=function(){if(y){var t=!0===y?{radius:10}:y,e=f.position(),n=f.layer().map(),r=n.gcsToDisplay(n.center(void 0,null),null),i=n.displayToGcs(r,f.gcs()),a=n.displayToGcs({x:r.x+t.radius,y:r.y},f.gcs()),s=Math.pow(Math.pow(a.y-i.y,2)+Math.pow(a.x-i.x,2),.5),u=n.zoom(),c=s*Math.pow(2,u);t=Object.assign({},t,{radius:c}),v=new o(t),x.forEach((function(t,n){var r=l.normalizeCoordinates(e(t,n));r.index=n,v.addPoint(r)})),_=null,f._handleZoom(n.zoom())}},this._handleZoom=function(t){var e=Math.floor(t);if(y&&e!==_){_=e;var n=v.points(e).map((function(t){return x[t.index]}));v.clusters(e).forEach((function(t){t.__cluster=!0,t.__data=[],t.obj.each((function(e){t.__data.push(x[e.index])})),n.push(t)})),b=!0,f.data(n)}},this.position=function(t){if(void 0===t)return f.style("position");var e=l.isFunction(t);return f.style("position",(function(n,r){return null!=n&&n.__cluster?n:e?t(n,r):t})),f.dataTime().modified(),f.modified(),f},this._updateRangeTree=function(){if(!(p.timestamp()>=f.dataTime().timestamp()&&p.timestamp()>=f.timestamp())){var t,e,n=f.style.get("radius"),o=f.style.get("stroke"),a=f.style.get("strokeWidth");e=f.position(),g=0,t=f.data().map((function(t,r){var i=e(t,r);return g=Math.max(g,n(t,r)+(o(t,r)?a(t,r):0)),[i.x,i.y]})),d=new c(t.length);var s,u=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=i(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(t);try{for(u.s();!(s=u.n()).done;){var l=r(s.value,2),h=l[0],m=l[1];d.add(h,m)}}catch(t){u.e(t)}finally{u.f()}d.finish(),p.modified()}},this.pointSearch=function(t,e){var n,r,i,o,a,s,u=[],l=[],c=[],h=f.gcs(),p=f.style.get("fill"),m=f.style.get("stroke"),y=f.style.get("strokeWidth"),v=f.style.get("radius");return(i=f.data())&&i.length?(f._updateRangeTree(),o=f.layer().map(),a=o.gcsToDisplay(t,e),s=[o.displayToGcs({x:a.x-g,y:a.y-g},h),o.displayToGcs({x:a.x+g,y:a.y-g},h),o.displayToGcs({x:a.x-g,y:a.y+g},h),o.displayToGcs({x:a.x+g,y:a.y+g},h)],n={x:Math.min(s[0].x,s[1].x,s[2].x,s[3].x),y:Math.min(s[0].y,s[1].y,s[2].y,s[3].y)},r={x:Math.max(s[0].x,s[1].x,s[2].x,s[3].x),y:Math.max(s[0].y,s[1].y,s[2].y,s[3].y)},u=d.range(n.x,n.y,r.x,r.y),(u=Uint32Array.from(u).sort()).forEach((function(t){var e=i[t],n=m(i[t],t);if(n||p(i[t],t)){var r,s,u,d,g=f.position()(e,t);u=v(i[t],t),(u+=n?y(i[t],t):0)&&(d=u*u,(r=(g=o.gcsToDisplay(g,h)).x-a.x)*r+(s=g.y-a.y)*s<=d&&(l.push(e),c.push(t)))}})),{found:l,index:c}):{found:[],index:[]}},this.polygonSearch=function(t,e,n){var r,i,o,a,s=f.gcs(),u=[],c=[],h={},p=f.layer().map(),m=f.data(),y=f.style.get("fill"),v=f.style.get("stroke"),x=f.style.get("strokeWidth"),_=f.style.get("radius");return t.outer||(t={outer:t,inner:[]}),t.outer.length<3||!m||!m.length?{found:[],index:[],extra:{}}:((e=e||{}).partial=e.partial||!1,(t={outer:p.gcsToDisplay(t.outer,n),inner:(t.inner||[]).map((function(t){return p.gcsToDisplay(t,n)}))}).outer.forEach((function(t){i||(i={x:t.x,y:t.y},o={x:t.x,y:t.y}),t.x<i.x&&(i.x=t.x),t.x>o.x&&(o.x=t.x),t.y<i.y&&(i.y=t.y),t.y>o.y&&(o.y=t.y)})),f._updateRangeTree(),a=[p.displayToGcs({x:i.x-g,y:i.y-g},s),p.displayToGcs({x:o.x+g,y:i.y-g},s),p.displayToGcs({x:o.x+g,y:o.y+g},s),p.displayToGcs({x:i.x-g,y:o.y+g},s)],i={x:Math.min(a[0].x,a[1].x,a[2].x,a[3].x),y:Math.min(a[0].y,a[1].y,a[2].y,a[3].y)},o={x:Math.max(a[0].x,a[1].x,a[2].x,a[3].x),y:Math.max(a[0].y,a[1].y,a[2].y,a[3].y)},r=d.range(i.x,i.y,o.x,o.y),(r=Uint32Array.from(r).sort()).forEach((function(n){var r=m[n],i=v(m[n],n);if(i||y(m[n],n)){var o=f.position()(r,n),a=_(m[n],n);if(a+=i?x(m[n],n):0){o=p.gcsToDisplay(o,s);var d=l.distanceToPolygon2d(o,t);(d>=a||d>=0&&"center"===e.partial||d>=-a&&e.partial&&"center"!==e.partial)&&(u.push(r),c.push(n),h[n]={partial:d<a,distance:d})}}})),{found:u,index:c,extra:h})},this.data=function(t){return void 0===t?m():(b||(x=t),y&&!b?f._clusterData():m(t),b=!1,f)},this._init=function(t){t=t||{},h.call(f,t);var e=l.deepMerge({},{radius:5,stroke:!0,strokeColor:{r:.851,g:.604,b:0},strokeWidth:1.25,strokeOpacity:1,fillColor:{r:1,g:.839,b:.439},fill:!0,fillOpacity:.8,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){return t.length>=3?t.slice(0,3):[0,0,0]}},void 0===t.style?{}:t.style);return void 0!==t.position&&(e.position=t.position),f.style(e),e.position&&f.position(e.position),f.dataTime().modified(),f.geoOn(a.zoom,(function(t){f._handleZoom(t.zoomLevel)})),f},f};u.create=function(t,e){"use strict";return(e=e||{}).type="point",s.create(t,e)},u.capabilities={feature:"point",stroke:"point.stroke"},u.primitiveShapes={auto:"auto",sprite:"sprite",triangle:"triangle",square:"square"},a(u,s),t.exports=u},6645:function(t,e,n){var r=n(4626),i=n(1275),o=n(5325),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},i.call(this,t);var e,r=n(642),s=this,u=this._init,l=this._exit,c=this.data,f=this.draw,h=this.modified,d=this.style,p=[];function m(t,e,n){var r=s.gcs(),i=s.layer().map().gcs();return t=t||s.data(),e=e||s.style.get("position"),n=n||s.style.get("polygon"),t.map((function(t,a){var u=n(t,a);if(u){var l,c,f,h,d,p,m,g,y,v;for(h=u.outer||(Array.isArray(u)?u:[]),l=new Array(h.length),d=0;d<h.length;d+=1)l[d]=e.call(s,h[d],d,t,a),p=l[d].x,m=l[d].y,d?(p<f.min.x&&(f.min.x=p),m<f.min.y&&(f.min.y=m),p>f.max.x&&(f.max.x=p),m>f.max.y&&(f.max.y=m)):f={min:{x:p,y:m},max:{x:p,y:m}};for(c=(u.inner||[]).map((function(n){h=n||[];var r=new Array(h.length);for(d=0;d<h.length;d+=1)r[d]=e.call(s,h[d],d,t,a);return r})),g=o.transformCoordinates(r,i,l),y=c.map((function(t){return o.transformCoordinates(r,i,t)})),d=0;d<g.length;d+=1)p=g[d].x,m=g[d].y,d?(p<v.min.x&&(v.min.x=p),m<v.min.y&&(v.min.y=m),p>v.max.x&&(v.max.x=p),m>v.max.y&&(v.max.y=m)):v={min:{x:p,y:m},max:{x:p,y:m}};return{outer:l,inner:c,range:f,mapouter:g,mapinner:y,maprange:v}}}))}function g(t){return r.isFunction(t)?function(e){return t(e[0],e[1],e[2],e[3])}:t}return this.featureType="polygon",this._subfeatureStyles={fillColor:!0,fillOpacity:!0,lineCap:!0,lineJoin:!0,strokeColor:!0,strokeOffset:!0,strokeOpacity:!0,strokeWidth:!0},this.data=function(t){var e=c(t);return void 0!==t&&(p=m(),s._checkForStroke()),e},this.polygonCoordinates=function(){return p},this.polygon=function(t){return void 0===t?s.style("polygon"):(s.style("polygon",t),s.dataTime().modified(),s.modified(),p=m(),s)},this.position=function(t){return void 0===t?s.style("position"):(s.style("position",t),s.dataTime().modified(),s.modified(),p=m(),s)},this.pointSearch=function(t,n){var i=[],a=[],u={},l=s.data(),c=s.layer().map();n=null===n?c.gcs():void 0===n?c.ingcs():n;var f=o.transformCoordinates(n,c.gcs(),t);(p.forEach((function(t,e){r.pointInPolygon(f,t.mapouter,t.mapinner,t.maprange)&&(a.push(e),u[e]=!0,i.push(l[e]))})),e)&&e.pointSearch(t).found.forEach((function(t){t.length&&4===t[0].length&&!u[t[0][3]]&&(a.push(t[0][3]),u[t[0][3]]=!0,i.push(l[t[0][3]]))}));return{index:a,found:i}},this.polygonSearch=function(t,n,i){var a,u,l=s.data(),c=[],f=[],h={},d=t,m={},g=s.layer().map();if(i=null===i?g.gcs():void 0===i?g.ingcs():i,t.outer||(t={outer:t,inner:[]}),!l||!l.length||t.outer.length<3)return{found:f,index:c,extra:h};if((n=n||{}).partial=n.partial||!1,(t={outer:o.transformCoordinates(i,g.gcs(),t.outer),inner:(t.inner||[]).map((function(t){return o.transformCoordinates(i,g.gcs(),t)}))}).outer.forEach((function(t){a||(a={x:t.x,y:t.y},u={x:t.x,y:t.y}),t.x<a.x&&(a.x=t.x),t.x>u.x&&(u.x=t.x),t.y<a.y&&(a.y=t.y),t.y>u.y&&(u.y=t.y)})),p.forEach((function(e,i){if(!(!e.mapouter.length||e.maprange&&(e.maprange.max.x<a.x||e.maprange.min.x>u.x||e.maprange.max.y<a.y||e.maprange.min.y>u.y))){for(var o,s,d=-1;d<e.mapinner.length&&!s;d+=1)for(var p=d<0?e.mapouter:e.mapinner[d],g=0,y=p.length,v=y-1;g<y;v=g,g+=1){var x=r.distanceToPolygon2d(p[g],t);if(x*r.distanceToPolygon2d(p[v],t)<0){s=!0;break}if(r.crossedLineSegmentPolygon2d(p[g],p[v],t)){s=!0;break}x>0&&(o=!0)}o||s||!r.pointInPolygon(t.outer[0],e.mapouter,e.mapinner,e.maprange)||(s=!0),(!n.partial&&o&&!s||n.partial&&(o||s))&&(c.push(i),f.push(l[i]),h[i]={partial:s},m[i]=!0)}})),e){var y=e.polygonSearch(d,n);y.found.forEach((function(t,e){t.length&&4===t[0].length&&(m[t[0][3]]||(c.push(t[0][3]),m[t[0][3]]=!0,f.push(l[t[0][3]]),h[y.index[e]]={partial:!1}),y.extra[y.index[e]].partial&&(h[t[0][3]].partial=!0))}))}return{found:f,index:c,extra:h}},this.style=function(t,e){var n=d.apply(s,arguments);return void 0===t||"string"==typeof t&&void 0===e||s._checkForStroke(),n},this.style.get=d.get,this._getLoopData=function(t,e,n){var r,i=[];for(r=0;r<n.length;r+=1)i.push([n[r],r,t,e]);return i},this._checkForStroke=function(){if(!1!==d("stroke")){if(s.layer()){e||(e=s.layer().createFeature("line",{selectionAPI:!1,gcs:s.gcs(),visible:s.visible(void 0,!0)}),s.dependentFeatures([e]));var t,n=s.style();if(r.isFunction(n.stroke)||!n.stroke){var i=s.style.get("stroke"),o=s.style.get("strokeOpacity");t=function(t){return i(t[2],t[3])?o(t[0],t[1],t[2],t[3]):0}}else t=g(n.strokeOpacity);e.style({antialiasing:g(n.antialiasing),closed:!0,lineCap:g(n.lineCap),lineJoin:g(n.lineJoin),miterLimit:g(n.miterLimit),strokeWidth:g(n.strokeWidth),strokeStyle:g(n.strokeStyle),strokeColor:g(n.strokeColor),strokeOffset:g(n.strokeOffset),strokeOpacity:t,uniformLine:g(n.uniformPolygon)});var a=s.data(),u=s.style("position");if(a!==e._lastData||u!==e._lastPosVal){var l,c,f,h=[],p=s.style.get("position"),m=s.style.get("polygon");for(l=0;l<a.length;l+=1)(c=m(a[l],l))&&(f=c.outer||(Array.isArray(c)?c:[])).length>=2&&(h.push(s._getLoopData(a[l],l,f)),c.inner&&c.inner.forEach((function(t){t.length>=2&&h.push(s._getLoopData(a[l],l,t))})));e.position((function(t,e,n,r){return p(t[0],t[1],t[2],t[3])})),e.data(h),e._lastData=a,e._lastPosVal=u}}}else e&&s.layer()&&(s.layer().deleteFeature(e),e=null,s.dependentFeatures([]))},this.draw=function(){var t=f();return e&&e.draw(),t},this.modified=function(){var t=h();return e&&e.modified(),t},this.rdpSimplifyData=function(t,e,n,i,a){var u=s.layer().map(),l=u.gcs(),c=s.gcs(),f=m(t,n,i);return void 0===e&&(e=.5*u.unitsPerPixel(u.zoom())),f=f.map((function(t){return{outer:o.transformCoordinates(c,l,t.outer),inner:t.inner.map((function(t){return o.transformCoordinates(c,l,t)}))}})),t=t.map((function(t,n){var i=f[n],a={};for(var s in t)!t.hasOwnProperty(s)||Array.isArray(t)&&s>=0&&s<t.length||(a[s]=t[s]);if(i&&i.outer.length>=3)if(a.inner=i.inner.filter((function(t){return t.length>=3})),a.outer=r.rdpLineSimplify(i.outer,e,!0,a.inner),a.outer.length>=3){var u=a.inner.slice();a.inner.map((function(t,n){u[n]=a.outer;var i=r.rdpLineSimplify(t,e,!0,u);return u[n]=i,i})).filter((function(t){return t.length>=3})),a.outer=o.transformCoordinates(l,c,a.outer),a.inner=a.inner.map((function(t){return o.transformCoordinates(l,c,t)}))}else a.outer=a.inner=[];else a.outer=[];return a})),a?t:(s.style("position",r.identityFunction),s.style("polygon",r.identityFunction),s.data(t),s)},this.mouseOverOrderClosestBorder=function(t){var e=t.feature.data(),n=t.feature.layer().map(),i=o.transformCoordinates(n.ingcs(),t.feature.gcs(),t.mouse.geo),a=t.feature.polygonCoordinates(),s={};t.over.index.forEach((function(t,e){var n,o=a[t];o.outer.forEach((function(t,e){var a=o.outer[(e+1)%o.outer.length],s=r.distance2dToLineSquared(i,t,a);(void 0===n||s<n)&&(n=s)})),o.inner.forEach((function(t){t.forEach((function(e,o){var a=t[(o+1)%t.length],s=r.distance2dToLineSquared(i,e,a);(void 0===n||s<n)&&(n=s)}))})),s[t]=n})),t.over.index.sort((function(t,e){return s[t]-s[e]})).reverse(),t.over.index.forEach((function(n,r){t.over.found[r]=e[n]}))},this.toPolygonList=function(t){var e=s.style.get("polygon"),n=s.style.get("position");return s.data().map((function(t,r){var i=e(t,r),o=i.outer||(Array.isArray(i)?i:[]);if(o.length<3)return[];var a=[o.map((function(e,i){var o=n(e,i,t,r);return[o.x,o.y]}))];return i.inner&&i.inner.forEach((function(e){a.push(e.map((function(e,i){var o=n(e,i,t,r);return[o.x,o.y]})))})),a}))},this.fromPolygonList=function(t,e){return s.style({position:function(t){return{x:t[0],y:t[1]}},polygon:function(t){return{outer:t[0],inner:t.slice(1)}}}),s.data(t),s},this._exit=function(){e&&s.layer()&&(s.layer().deleteFeature(e),e=null,s.dependentFeatures([])),l()},this._init=function(t){t=t||{},u.call(s,t);var e=Object.assign({},{fill:!0,fillColor:{r:0,g:.5,b:.5},fillOpacity:1,stroke:!1,strokeWidth:1,strokeStyle:"solid",strokeColor:{r:0,g:1,b:1},strokeOpacity:1,polygon:r.identityFunction,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){for(var e=0;e<t.length;e+=1)if(t[e].vertices.length>=3)return t[e].vertices.slice(0,3);return[0,0,0]}},void 0===t.style?{}:t.style);void 0!==t.polygon&&(e.polygon=t.polygon),void 0!==t.position&&(e.position=t.position),s.style(e),s._checkForStroke()},this};a.create=function(t,e){"use strict";return(e=e||{}).type="polygon",i.create(t,e)},a.capabilities={feature:"polygon"},r(a,i),t.exports=a},3842:function(t,e,n){var r=n(5616),i=n(4626),o=n(1275),a=function(t){"use strict";var e=n(5325),i=n(642);if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var s,u,l=this,c=this._init,f=t.nearestPixel,h=0,d=[],p=[];return this.featureType="quad",this._objectListStart=function(t){r.each(t,(function(t,e){e.used=!1}))},this._objectListGet=function(t,e){for(var n=0;n<t.length;n+=1)if(t[n].entry===e)return t[n].used=!0,t[n].value},this._objectListAdd=function(t,e,n){t.push({entry:e,value:n,used:!0})},this._objectListEnd=function(t){for(var e=t.length-1;e>=0;e-=1)t[e].used||t.splice(e,1)},this.pointSearch=function(t,n){var o,a,s=[],c=[],f={},h=[{},{},{},{}],d=[{},{},{},{}],p=[0,1,2,0],m=[1,2,3,1],g=l.data(),y=l.layer().map();return n=null===n?y.gcs():void 0===n?y.ingcs():n,t=e.transformCoordinates(n,y.gcs(),t),u||l._generateQuads(),r.each([u.clrQuads,u.imgQuads,u.vidQuads],(function(e,n){n.forEach((function(e,n){for(o=0;o<p.length;o+=1)h[o].x=e.pos[3*p[o]],h[o].y=e.pos[3*p[o]+1],h[o].z=e.pos[3*p[o]+2],d[o].x=e.pos[3*m[o]],d[o].y=e.pos[3*m[o]+1],d[o].z=e.pos[3*m[o]+2];(i.pointInPolygon(t,h)||i.pointInPolygon(t,d))&&(c.push(e.idx),s.push(g[e.idx]),!(a=i.pointToTriangleBasis2d(t,h[0],h[1],h[2]))||a.x+a.y>1?(a=i.pointToTriangleBasis2d(t,d[2],d[1],d[0]))&&(a.x=1-a.x):a.y=1-a.y,a&&(f[e.idx]={basis:a,_quad:e}))}))})),{index:c,found:s,extra:f}},this.position=function(t){return void 0===t?l.style("position"):(l.style("position",i.ensureFunction(t)),l.dataTime().modified(),l.modified(),l)},this._positionToQuad=function(t,n,i,o){var a=t.call(l,i,o);if(a.ll&&a.ur||a.ul&&a.lr){var s=l.gcs(),u=l.layer().map().gcs(),c={};return r.each(["ll","lr","ul","ur"],(function(t,r){void 0!==a[r]&&(c[r]={},void 0===a[r].x?c[r]=[a[r][0],a[r][1],a[r][2]]:c[r]=[a[r].x,a[r].y,a[r].z],void 0===c[r][2]&&(c[r][2]=n.call(l,i,o)),s!==u&&!1!==s&&(c[r]=e.transformCoordinates(s,u,c[r])))})),c.ll=c.ll||[c.ul[0],c.lr[1],(c.ul[2]+c.lr[2])/2],c.lr=c.lr||[c.ur[0],c.ll[1],(c.ur[2]+c.ll[2])/2],c.ur=c.ur||[c.lr[0],c.ul[1],(c.lr[2]+c.ul[2])/2],c.ul=c.ul||[c.ll[0],c.ur[1],(c.ll[2]+c.ur[2])/2],c}},this._checkQuadUpdate=function(t,e){},this._generateQuads=function(){var t,e,n=l.position(),o=l.style.get("image"),a=l.style.get("video"),c=l.style.get("delayRenderWhenSeeking"),f=l.style.get("color"),m=l.style.get("depth"),g=l.style.get("opacity"),y=l.style.get("drawOnAsyncResourceLoaded"),v=l.style.get("previewColor"),x=l.style.get("previewImage"),_=l.data(),b=[],w=[],M=[],A=[0,0,0];return l._objectListStart(d),l._objectListStart(p),r.each(_,(function(u,_){if(_._cachedQuad)return e=_._cachedQuad.diag2,(void 0===t||_._cachedQuad.diag2&&_._cachedQuad.diag2<t)&&(A=_._cachedQuad.ll,t=_._cachedQuad.diag2),_._cachedQuad.clrquad&&b.push(_._cachedQuad.clrquad),_._cachedQuad.imgquad&&(_._cachedQuad.imageEntry&&l._objectListGet(d,_._cachedQuad.imageEntry),w.push(_._cachedQuad.imgquad)),void(_._cachedQuad.vidquad&&(_._cachedQuad.videoEntry&&l._objectListGet(p,_._cachedQuad.videoEntry),M.push(_._cachedQuad.vidquad)));var T,E,C,k,S,O,P,L,R,I,D,N,F={};if(P=l._positionToQuad(n,m,_,u),I=g.call(l,_,u),void 0!==P&&I&&!(I<0)){if(e=Math.pow(P.ll[0]-P.ur[0],2)+Math.pow(P.ll[1]-P.ur[1],2)+Math.pow(P.ll[2]-P.ur[0],2)+Math.pow(P.lr[0]-P.ur[0],2)+Math.pow(P.lr[1]-P.ur[1],2)+Math.pow(P.lr[2]-P.ur[0],2),F.diag2=e,F.ll=P.ll,(void 0===t||e&&e<t)&&(A=P.ll,t=e),P=[P.ll[0],P.ll[1],P.ll[2],P.lr[0],P.lr[1],P.lr[2],P.ul[0],P.ul[1],P.ul[2],P.ur[0],P.ur[1],P.ur[2]],T={idx:u,pos:P,opacity:I,zOffset:_.zOffset},_.reference&&(T.reference=_.reference),_.crop&&(T.crop=_.crop),R=(L=o.call(l,_,u))?null:a.call(l,_,u),L){if(F.imageEntry=L,void 0===(E=l._objectListGet(d,L))&&(L instanceof Image||L instanceof HTMLCanvasElement?E=L:(E=new Image).src=L,l._objectListAdd(d,L,E)),i.isReadyImage(E)||E instanceof HTMLCanvasElement)T.image=E;else if(D=void 0,(N=x.call(l,_,u))&&i.isReadyImage(N)?T.image=N:(D=v.call(l,_,u),T.color=i.convertColor(D),T.color&&void 0!==T.color.r&&void 0!==T.color.g&&void 0!==T.color.b?(b.push(T),F.clrquad=T):D=void 0),y.call(l,_,u))O=i.isReadyImage(E,!0)?null:r.Deferred(),k=E.onload,E.onload=function(){if(void 0!==D&&(b.includes(T)&&b.splice(b.indexOf(T),1),delete F.clrquad),T.image=E,l.dataTime().modified(),l.modified(),l._update(),l.layer().draw(),O&&O.resolve(),k)return k.apply(l,arguments)},S=E.onerror,E.onerror=function(){if(O&&O.reject(),S)return S.apply(l,arguments)},O&&l.layer().addPromise(O.promise());else if(void 0===D&&!T.image)return;w.push(T),F.imgquad=T}else if(R){if(F.videoEntry=R,void 0===(C=l._objectListGet(p,R))&&(R instanceof HTMLVideoElement?C=R:(C=document.createElement("video")).src=R,l._objectListAdd(p,R,C),r(C).off(".geojsvideo").on("seeking.geojsvideo canplay.geojsvideo pause.geojsvideo playing.geojsvideo",(function(t){l._checkQuadUpdate(T,t)}))),T.delayRenderWhenSeeking=c.call(l,_,u),void 0===T.delayRenderWhenSeeking&&(T.delayRenderWhenSeeking=!0),i.isReadyVideo(C))T.video=C;else if(D=v.call(l,_,u),T.color=i.convertColor(D),T.color&&void 0!==T.color.r&&void 0!==T.color.g&&void 0!==T.color.b?(b.push(T),F.clrquad=T):D=void 0,y.call(l,_,u))O=i.isReadyVideo(C,!0)?null:r.Deferred(),k=C.onloadeddata,C.onloadeddata=function(){if(void 0!==D&&(b.includes(T)&&b.splice(b.indexOf(T),1),delete F.clrquad),T.video=C,l.dataTime().modified(),l.modified(),l._update(),l.layer().draw(),O&&O.resolve(),k)return k.apply(l,arguments)},S=C.onerror,C.onerror=function(){if(O&&O.reject(),S)return S.apply(l,arguments)},O&&l.layer().addPromise(O.promise());else if(void 0===D&&!T.video)return;M.push(T),F.vidquad=T}else{if(T.color=i.convertColor(f.call(l,_,u)),!T.color||void 0===T.color.r||void 0===T.color.g||void 0===T.color.b)return;b.push(T),F.clrquad=T}F.clrquad&&(h+=1,F.clrquad.quadId=h),F.imgquad&&(h+=1,F.imgquad.quadId=h),F.vidquad&&(h+=1,F.vidquad.quadId=h),!1!==s&&(_._cachedQuad=F)}})),l._objectListEnd(d),l._objectListEnd(p),u={clrQuads:b,imgQuads:w,vidQuads:M,origin:new Float32Array(A)}},this.cacheUpdate=function(t){return null==t?r.each(l.data(),(function(t,e){e._cachedQuad&&delete e._cachedQuad})):(isFinite(t)&&(t=l.data()[t]),t._cachedQuad&&delete t._cachedQuad),l.modified(),l},this.video=function(t){var e,n;return isFinite(t)&&(t=l.data()[t]),t._cachedQuad?e=(t._cachedQuad.vidquad||{}).video:(u||l._generateQuads(),(n=l.data().indexOf(t))>=0&&(e=l._objectListGet(p,l.style.get("video")(t,n)))),e instanceof HTMLVideoElement?e:null},this.nearestPixel=function(t){return void 0===t?f:(f=t,l.modified(),l)},this._init=function(t){t=t||{},c.call(l,t),s=!1!==t.cacheQuads;var e=Object.assign({},{color:{r:1,g:1,b:1},opacity:1,depth:0,drawOnAsyncResourceLoaded:!0,previewColor:null,previewImage:null,image:function(t){return t.image},video:function(t){return t.video},position:i.identityFunction},void 0===t.style?{}:t.style);void 0!==t.position&&(e.position=i.ensureFunction(t.position)),l.style(e),l.dataTime().modified()},l};a.create=function(t,e){"use strict";return(e=e||{}).type="quad",o.create(t,e)},a.capabilities={color:"quad.color",image:"quad.image",imageCrop:"quad.imageCrop",imageFixedScale:"quad.imageFixedScale",imageFull:"quad.imageFull",canvas:"quad.canvas",video:"quad.video"},i(a,o),t.exports=a},1098:function(t,e,n){var r=n(8695),i=n(1949),o={dom:{}},a={},s={},u={},l={},c={},f={},h={},d={},p={registerFileReader:function(t,e){f[t]=e},createFileReader:function(t,e){return f.hasOwnProperty(t)?f[t](e):null},registerRenderer:function(t,e){u[t]=e},createRenderer:function(t,e,n,r){if(u.hasOwnProperty(t)){var i=u[t]({layer:e,canvas:n,options:r});return i._init(),i}return null},checkRenderer:function(t,e){if(null===t)return t;if(u.hasOwnProperty(t)){var n=u[t];if(!n.supported||n.supported())return n.apiname||t;if(!n.fallback||e)return!1;var r=p.checkRenderer(n.fallback(),!0);return!1!==r&&console.warn(t+" renderer is unavailable, using "+r+" renderer instead"),r}return!1},rendererForFeatures:function(t){var e,n,r,i,o,a,s=["webgl","canvas","svg","vtkjs",null];for(n=0;n<s.length;n+=1)if(e=s[n],!1!==p.checkRenderer(e,!0)){if(!t)return e;if(l[e]){for(a=!0,i=0;i<t.length;i+=1){if(o=null,(r=t[i]).indexOf(".")>=0&&(o=r,r=r.substr(0,r.indexOf("."))),void 0===l[e][r]){a=!1;break}if(o&&c[e][r]&&!c[e][r][o]){a=!1;break}}if(a)return e}}return console.warn('There is no renderer available for the feature list "'+(t||[]).join(", ")+'".'),!1},registerFeature:function(t,e,n,r){t in l||(l[t]={},c[t]={});var i=l[t][e];return i&&console.warn("The "+t+"."+e+" feature is already registered"),l[t][e]=n,c[t][e]=r,i},createFeature:function(t,e,n,r){var o=n.api(),a={layer:e,renderer:n};if(o in l&&t in l[o]){void 0!==r&&i.deepMerge(a,r);var s=l[o][t](a);return void 0===e.gcs&&(e.gcs=function(){return e.map().gcs()}),s}return null},registerLayerAdjustment:function(t,e,n){t in h||(h[t]={});var r=h[t][e];return r&&console.warn("The "+t+"."+e+" layer adjustment is already registered"),h[t][e]=n,r},adjustLayerForRenderer:function(t,e){var n=e.rendererName();n&&h&&h[n]&&h[n][t]&&h[n][t].apply(e)},registerLayer:function(t,e,n){a[t]=e,s[t]=n},createLayer:function(t,e,n){var r={map:e},o=null;if(t in a){if(n.renderer||n.features||!s||(r.features=s[t]),void 0!==n){var u=n.data;delete n.data,i.deepMerge(r,n),u&&(r.data=u)}return(o=a[t](r)).layerName=t,o._init(),o}return null},registerWidget:function(t,e,n){t in o||(o[t]={});var r=o[t][e];return r&&console.warn("The "+t+"."+e+" widget is already registered"),o[t][e]=n,r},createWidget:function(t,e,n){var r={layer:e};if(t in o.dom)return void 0!==n&&i.deepMerge(r,n),o.dom[t](r);throw new Error("Cannot create unknown widget "+t)},registerAnnotation:function(t,e,n){var i=d[t];return i&&console.warn("The "+t+" annotation is already registered"),d[t]={func:e,features:n||{}},r["annotation_"+t]="geo_annotation_"+t,i},createAnnotation:function(t,e){if(d[t])return d[t].func(e);console.warn("The "+t+" annotation is not registered")},listAnnotations:function(){return Object.keys(d)},featuresForAnnotations:function(t){var e=[];return(Array.isArray(t)?t:Object.keys(t)).forEach((function(n){d[n]&&Object.keys(d[n].features).forEach((function(r){Array.isArray(t)||!0===t[n]||!Array.isArray(d[n].features[r])?e.push(r):t[n].forEach((function(t){d[n].features[r].includes(t)&&e.push(r)}))}))})),e},rendererForAnnotations:function(t){return p.rendererForFeatures(p.featuresForAnnotations(t))}};p.registries={annotations:d,features:l,featureCapabilities:c,fileReaders:f,layers:a,renderers:u,widgets:o},t.exports=p},2274:function(t,e,n){var r=n(4626),i=n(1338),o=function(t){"use strict";if(!(this instanceof o))return new o(t);i.call(this);var e=this,n=0,r=0,a=void 0===(t=t||{}).layer?null:t.layer,s=void 0===t.canvas?null:t.canvas,u=!1;return this.layer=function(){return a},this.canvas=function(t){return void 0===t?s:(s=t,e.modified(),e)},this.map=function(){return a?a.map():null},this.initialized=function(t){return void 0===t?u:(u=t,e)},this.api=function(){throw new Error("Should be implemented by derived classes")},this.width=function(){return n},this.height=function(){return r},this._setWidthHeight=function(t,i){return n=t,r=i,e},this._init=function(){return e},this._resize=function(t,n,r,i){return e._setWidthHeight(r,i),e},this._render=function(){return e},this};r(o,i),t.exports=o},5402:function(t,e,n){var r=n(4626),i=n(1338),o=function(t){"use strict";if(!(this instanceof o))return new o;i.call(this,t);var e=this,n=null,r=[],a=this._exit,s=this.geoTrigger,u=this.addPromise,l=this.removePromise;return this.addPromise=function(t){return n&&n.addPromise(t),u(t),e},this.removePromise=function(t){return n&&n.removePromise(t),l(t),e},this.parent=function(t){return void 0===t?n:(n=t,e)},this.addChild=function(t){return Array.isArray(t)?(t.forEach(e.addChild),e):(t.parent(e),r.push(t),e)},this.removeChild=function(t){return Array.isArray(t)?(t.forEach(e.removeChild),e):(r=r.filter((function(e){return e!==t})),e)},this.children=function(){return r.slice()},this.draw=function(t){return e.children().forEach((function(e){e.draw(t)})),e},this.geoTrigger=function(t,i,o){var a;return a=(i=i||{}).geo||{},i.geo=a,a.stopPropagation?e:!o&&n&&a._triggeredBy!==n?(a._triggeredBy=e,n.geoTrigger(t,i),e):(s.call(e,t,i),a.stopPropagation||r.forEach((function(n){n.geoTrigger&&(a._triggeredBy=e,n.geoTrigger(t,i))})),e)},this._exit=function(){r=[],n=null,a()},this};r(o,i),t.exports=o},9079:function(t){t.exports="81c2c67b6f61c4292a790edab5e583c82095b099"},3832:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3187),a=function(t){"use strict";var e=this;return this instanceof a?(o.call(this,t),this.select=function(){var t=e.renderer(),n={},r=e.nodeFeature(),i=e.linkFeatures();return n.nodes=t.select(r._svgid()),n.links=i.map((function(e){return t.select(e._svgid())})),n},this):new a(t)};r(a,o),i("svg","graph",a),t.exports=a},6488:function(t,e,n){n(6409).svg={rescale:n(4765)},t.exports={graphFeature:n(3832),lineFeature:n(9456),object:n(5005),pathFeature:n(9927),pointFeature:n(2602),quadFeature:n(4087),renderer:n(2493),tileLayer:n(4061),trackFeature:n(2037),uniqueID:n(7376),vectorFeature:n(5747)}},9456:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(9281),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(2493).d3,r=n(5005),i=n(77),s=n(642);t=t||{},o.call(this,t),r.call(this);var u=this,l=this._init,c=i(),f=0,h=this._update;return this._init=function(t){return l.call(u,t),u},this._build=function(){var t,n,r=u.data()||[],i=u.style(),o=u.renderer(),a=u.position();for(h.call(u),i.fill=function(){return!1},r.forEach((function(n,r){var l,c,f=u.line()(n,r),h={};function d(t){return s.isFunction(t)?function(){return t(f[0],0,n,r)}:t}for(c in i)i.hasOwnProperty(c)&&(h[c]=d(i[c]));t=e.line().x((function(t){return u.featureGcsToDisplay(t).x})).y((function(t){return u.featureGcsToDisplay(t).y})).curve(u.style.get("closed")(n,r)&&f.length>2?e.curveLinearClosed:e.curveLinear),l={data:[f.map((function(t,e){return a(t,e,n,r)}))],append:"path",attributes:{d:t},id:u._svgid()+r,classes:["svgLineFeature","svgSubLine-"+r],visible:u.visible,style:h},o._drawFeatures(l)})),n=r.length;n<f;n+=1)o._removeFeature(u._svgid()+n);return f=r.length,c.modified(),u.updateTime().modified(),u},this._update=function(){return h.call(u),u.timestamp()>=c.timestamp()&&u._build(),u},this._init(t),this};r(a,o);var s={};s[o.capabilities.basic]=!0,s[o.capabilities.multicolor]=!1,i("svg","line",a,s),t.exports=a},5005:function(t,e,n){var r=function(t){"use strict";var e=n(1338),i=n(7376);if(!(this instanceof e))return new r(t);var o="svg-"+i(),a=this._exit,s=this,u=this.draw;return this._svgid=function(){return o},this.select=function(){return s.renderer().select(s._svgid())},this.draw=function(){return s.ready&&(s._update(),u()),s},this._exit=function(){s.renderer()._removeFeature(s._svgid()),a()},this};t.exports=r},9927:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2266),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5005),r=n(77);t=t||{},o.call(this,t),e.call(this);var i=this,s=r(),u=this._update,l={style:{}};return this._build=function(){var t,e,n=i.data()||[],r=i.style.get(),o=i.style.get("position");return u.call(i),e=function(t){return"M"+t.source.x+","+t.source.y+"C"+t.source.x+","+(t.source.y+t.target.y)/2+" "+t.target.x+","+(t.source.y+t.target.y)/2+" "+t.target.x+","+t.target.y},t=[],n.forEach((function(e,r){var a,s;r<n.length-1&&(a=o(e,r),s=o(n[r+1],r+1),t.push({source:i.featureGcsToDisplay(a),target:i.featureGcsToDisplay(s)}))})),l.data=t,l.attributes={d:e},l.id=i._svgid(),l.append="path",l.classes=["svgPathFeature"],l.style=Object.assign({fill:function(){return!1},fillColor:{r:0,g:0,b:0}},r),l.visible=i.visible,i.renderer()._drawFeatures(l),s.modified(),i.updateTime().modified(),i},this._update=function(){return u.call(i),i.dataTime().timestamp()>=s.timestamp()&&i._build(),i},this._init(t),this};r(a,o),i("svg","path",a),t.exports=a},2602:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7541),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5005),r=n(77);t=t||{},o.call(this,t),e.call(this);var i=this,s=this._init,u=this._update,l=r(),c={};return this._init=function(t){return s.call(i,t),i},this._build=function(){var t=i.data(),e=i.style.get(),n=i.renderer(),r=i.position();return u.call(i),t||(t=[]),c.id=i._svgid(),c.data=t,c.append="circle",c.attributes={r:n._convertScale(e.radius),cx:function(t){return i.featureGcsToDisplay(r(t)).x},cy:function(t){return i.featureGcsToDisplay(r(t)).y}},c.style=e,c.classes=["svgPointFeature"],c.visible=i.visible,i.renderer()._drawFeatures(c),l.modified(),i.updateTime().modified(),i},this._update=function(){return u.call(i),i.timestamp()>=l.timestamp()&&i._build(),i},this._init(t),this};r(a,o);var s={};s[o.capabilities.stroke]=!0,i("svg","point",a,s),t.exports=a},4087:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3842),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5616),r=n(2493).d3,i=n(5005);o.call(this,t),i.call(this);var s,u=this,l=this._exit,c=this._init,f=this._update;return this._build=function(){if(this.position()){var t=u.renderer(),n=t.layer().map();s=u._generateQuads();var i=[];e.each(s.clrQuads,(function(t,e){i.push({type:"clr",quad:e,zIndex:e.pos[2]})})),e.each(s.imgQuads,(function(t,e){e.image&&i.push({type:"img",quad:e,zIndex:e.pos[2]})}));var o={id:u._svgid(),data:i,dataIndex:function(t){return t.quad.quadId},append:function(t){var e=this.namespaceURI,n="clr"===t.type?"polygon":"image";return e?document.createElementNS(e,n):document.createElement(n)},attributes:{fill:function(t){if("clr"===t.type)return r.rgb(255*t.quad.color.r,255*t.quad.color.g,255*t.quad.color.b);1!==t.quad.opacity&&r.select(this).style("opacity",t.quad.opacity)},height:function(t){return"clr"===t.type?void 0:1},points:function(e){if("clr"===e.type&&!e.points){var r,i=[];for(r=0;r<e.quad.pos.length;r+=3){var o={x:e.quad.pos[r],y:e.quad.pos[r+1],z:e.quad.pos[r+2]};o=n.gcsToDisplay(o,null),o=t.baseToLocal(o),i.push(o.x+","+o.y)}e.points=i[0]+" "+i[1]+" "+i[3]+" "+i[2]}return"clr"===e.type?e.points:void 0},preserveAspectRatio:function(t){return"clr"===t.type?void 0:"none"},reference:function(t){return t.quad.reference},stroke:!1,transform:function(e){if("img"===e.type&&e.quad.image&&!e.svgTransform){var r,i,o,a,s=[],u=-1,l=e.quad.image.width,c=e.quad.image.height;for(o=0;o<e.quad.pos.length;o+=3){var f={x:e.quad.pos[o],y:e.quad.pos[o+1],z:e.quad.pos[o+2]};f=n.gcsToDisplay(f,null),f=t.baseToLocal(f),s.push(f)}for(o=0;o<4;o+=1)(r=Math.abs(s[(o+1)%4].x*(s[(o+2)%4].y-s[(o+3)%4].y)+s[(o+2)%4].x*(s[(o+3)%4].y-s[(o+1)%4].y)+s[(o+3)%4].x*(s[(o+1)%4].y-s[(o+2)%4].y))/2)>u&&(u=r,i=o);e.svgTransform=[3===i||2===i?s[1].x-s[0].x:s[3].x-s[2].x,3===i||2===i?s[1].y-s[0].y:s[3].y-s[2].y,0===i||2===i?s[1].x-s[3].x:s[0].x-s[2].x,0===i||2===i?s[1].y-s[3].y:s[0].y-s[2].y,2===i?s[3].x+s[0].x-s[1].x:s[2].x,2===i?s[3].y+s[0].y-s[1].y:s[2].y],Math.abs(e.svgTransform[1]/l)<1e-6&&Math.abs(e.svgTransform[2]/c)<1e-6&&(a=e.svgTransform[0]/l,e.svgTransform[4]=Math.round(e.svgTransform[4]/a)*a,a=e.svgTransform[3]/c,e.svgTransform[5]=Math.round(e.svgTransform[5]/a)*a)}return"img"===e.type&&e.quad.image?"matrix("+e.svgTransform.join(" ")+")":void 0},width:function(t){return"clr"===t.type?void 0:1},x:function(t){return"clr"===t.type?void 0:0},"xlink:href":function(t){return"clr"!==t.type&&t.quad.image?t.quad.image.src:void 0},y:function(t){return"clr"===t.type?void 0:0}},style:{fillOpacity:function(t){return"clr"===t.type?t.quad.opacity:void 0}},onlyRenderNew:!this.style("previewColor")&&!this.style("previewImage"),sortByZ:!0,visible:u.visible,classes:["svgQuadFeature"]};t._drawFeatures(o),u.buildTime().modified()}},this._update=function(){return f.call(u),(u.buildTime().timestamp()<=u.dataTime().timestamp()||u.buildTime().timestamp()<u.timestamp())&&u._build(),u},this._init=function(){c.call(u,t)},this._exit=function(){l.call(u)},u._init(t),this};r(a,o);var s={};s[o.capabilities.color]=!0,s[o.capabilities.image]=!0,s[o.capabilities.imageCrop]=!1,s[o.capabilities.imageFixedScale]=!1,s[o.capabilities.imageFull]=!1,s[o.capabilities.canvas]=!1,s[o.capabilities.video]=!1,i("svg","quad",a,s),t.exports=a},4765:function(t){t.exports="geo_svg_rescale"},2493:function(t,e,n){var r=n(4626),i=n(1098).registerRenderer,o=n(2274),a=function(t){"use strict";var e=a.d3,r=n(5005),i=n(642),s=n(6409),u=n(4765);if(!(this instanceof a))return new a(t);o.call(this,t);var l=this._exit;r.call(this,t),t=t||{};var c=this,f=null,h={},d=null,p=null,m=1,g={dx:0,dy:0,rx:0,ry:0,rotation:0},y={},v={},x=null,_=null;function b(t){return t?x.select(".group-"+t):x.select(".group-"+c._svgid())}function w(){var t=c.layer().map(),e=t.size().width,n=t.size().height;if(!e||!n)throw new Error("Map layer has size 0");c._setWidthHeight(e,n),p=Math.pow(e*e+n*n,.5),d={upperLeft:t.displayToGcs({x:0,y:0},null),lowerRight:t.displayToGcs({x:e,y:n},null),center:t.displayToGcs({x:e/2,y:n/2},null)}}return this._convertColor=function(t,n){return t=i.ensureFunction(t),n=n||function(){return!0},function(){var r="none";return n.apply(c,arguments)&&(r=t.apply(c,arguments)).hasOwnProperty("r")&&r.hasOwnProperty("g")&&r.hasOwnProperty("b")&&(r=e.rgb(255*r.r,255*r.g,255*r.b)),r}},this._convertScale=function(t){return t=i.ensureFunction(t),function(){return t.apply(c,arguments)/m}},this._setTransform=function(){if(d||w(),f){var t,e,n,r,i,o,a=c.layer().map(),s=a.gcsToDisplay(d.upperLeft,null),u=a.gcsToDisplay(d.lowerRight,null),l=a.gcsToDisplay(d.center,null),h=b();n=Math.sqrt(Math.pow(u.y-s.y,2)+Math.pow(u.x-s.x,2))/p,r=a.rotation(),i=-c.width()/2,o=-c.height()/2,t=n*i+l.x,e=n*o+l.y,r||(t=Math.round(t),e=Math.round(e));var y="matrix("+[n,0,0,n,t,e].join()+")";r&&(y+=" rotate("+[180*r/Math.PI,-i,-o].join()+")"),h.attr("transform",y),m=n,g.dx=t,g.dy=e,g.rx=i,g.ry=o,g.rotation=r}},this.baseToLocal=function(t){if(t={x:(t.x-g.dx)/m,y:(t.y-g.dy)/m},g.rotation){var e=Math.sin(-g.rotation),n=Math.cos(-g.rotation),r=t.x+g.rx,i=t.y+g.ry;t={x:r*n-i*e-g.rx,y:r*e+i*n-g.ry}}return t},this.localToBase=function(t){if(g.rotation){var e=Math.sin(g.rotation),n=Math.cos(g.rotation),r=t.x+g.rx,i=t.y+g.ry;t={x:r*n-i*e-g.rx,y:r*e+i*n-g.ry}}return t={x:t.x*m+g.dx,y:t.y*m+g.dy}},this._init=function(t){if(!c.canvas()){var n;t.widget=t.widget||!1,(x="d3Parent"in t?e.select(t.d3Parent).append("svg"):e.select(c.layer().node().get(0)).append("svg")).attr("display","block");var r=(_=x.append("defs")).append("filter").attr("id","geo-highlight").attr("x","-100%").attr("y","-100%").attr("width","300%").attr("height","300%");r.append("feMorphology").attr("operator","dilate").attr("radius",2).attr("in","SourceAlpha").attr("result","dilateOut"),r.append("feGaussianBlur").attr("stdDeviation",5).attr("in","dilateOut").attr("result","blurOut"),r.append("feColorMatrix").attr("type","matrix").attr("values","-1 0 0 0 1 0 -1 0 0 1 0 0 -1 0 1 0 0 0 1 0").attr("in","blurOut").attr("result","invertOut"),r.append("feBlend").attr("in","SourceGraphic").attr("in2","invertOut").attr("mode","normal"),t.widget||(n=t.canvas||x.append("g")),(r=_.append("filter").attr("id","geo-blur").attr("x","-100%").attr("y","-100%").attr("width","300%").attr("height","300%")).append("feGaussianBlur").attr("stdDeviation",20).attr("in","SourceGraphic"),f=c.layer().sticky(),x.attr("class",c._svgid()),x.attr("width",c.layer().node().width()),x.attr("height",c.layer().node().height()),t.widget?c.canvas(x):(n.attr("class","group-"+c._svgid()),c.canvas(n))}return c._setTransform(),c},this.api=function(){return a.apiname},this.scaleFactor=function(){return m},this._resize=function(t,e,n,r){return d||w(),x.attr("width",n),x.attr("height",r),c._setTransform(),c._setWidthHeight(n,r),c.layer().geoTrigger(u,{scale:m},!0),c},this._exit=function(){h={},c.canvas().remove(),x.remove(),x=void 0,_.remove(),_=void 0,y={},v={},l()},this._definitions=function(){return _},this._drawFeatures=function(t){return h[t.id]={data:t.data,index:t.dataIndex,style:t.style,visible:t.visible,attributes:t.attributes,classes:t.classes,append:t.append,onlyRenderNew:t.onlyRenderNew,sortByZ:t.sortByZ,parentId:t.parentId},c.__render(t.id,t.parentId)},this.__render=function(t,e){var n;if(void 0===t){for(n in h)h.hasOwnProperty(n)&&c.__render(n);return c}return e?c._renderFeature(t,e):(y[t]=!0,c.layer().map().scheduleAnimationFrame(c._renderFrame)),c},this._renderFrame=function(){var t;for(t in v)c.select(t).remove(),_.selectAll("."+t).remove();v={};var e=y;for(t in y={},e)e.hasOwnProperty(t)&&c._renderFeature(t)},this._renderFeature=function(t,e){if(!h[t])return c;var n,r,i=h[t].data,o=h[t].index,a=h[t].style,s=h[t].visible,u=h[t].attributes,l=h[t].classes,f=h[t].append,d=c.select(t,e).data(i,o);return n=d.enter().append(f),d.exit().remove(),function(t,e){var n;for(n in e)e.hasOwnProperty(n)&&t.attr(n,e[n])}(r=n,u),r.attr("class",l.concat([t]).join(" ")),function(t,e){var n,r,i;function o(){return e.fill.apply(c,arguments)?null:"none"}function a(){return e.stroke.apply(c,arguments)?null:"none"}for(n in e)e.hasOwnProperty(n)&&(i=null,r=null,"strokeColor"===n?(r="stroke",i=c._convertColor(e[n],e.stroke)):"stroke"===n&&e[n]&&!e.hasOwnProperty("strokeColor")?(r="stroke",i=a):"strokeWidth"===n?(r="stroke-width",i=c._convertScale(e[n])):"strokeOpacity"===n?(r="stroke-opacity",i=e[n]):"fillColor"===n?(r="fill",i=c._convertColor(e[n],e.fill)):"fill"!==n||e.hasOwnProperty("fillColor")?"fillOpacity"===n?(r="fill-opacity",i=e[n]):"lineCap"===n?(r="stroke-linecap",i=e[n]):"lineJoin"===n?(r="stroke-linejoin",i=e[n]):"miterLimit"===n&&(r="stroke-miterlimit",i=e[n]):(r="fill",i=o),r&&t.style(r,i))}(r,a),s&&r.style("visibility",s()?"visible":"hidden"),n.size()&&h[t].sortByZ&&d.sort((function(t,e){return(t.zIndex||0)-(e.zIndex||0)})),c},this.select=function(t,e){return b(e).selectAll("."+t)},this._removeFeature=function(t){return v[t]=!0,c.layer().map().scheduleAnimationFrame(c._renderFrame),delete h[t],y[t]&&delete y[t],c},this.draw=function(){},this.layer().geoOn(s.pan,c._setTransform),this.layer().geoOn(s.rotate,c._setTransform),this.layer().geoOn(s.zoom,(function(){c._setTransform(),c.__render(),c.layer().geoTrigger(u,{scale:m},!0)})),this.layer().geoOn(s.resize,(function(t){c._resize(t.x,t.y,t.width,t.height)})),this._init(t),this};a.apiname="svg",r(a,o),i("svg",a),i("d3",a),a.supported=function(){delete a.d3;try{a.d3=n(5127),a.d3&&a.d3.rgb||(a.d3=void 0)}catch(t){}return void 0!==a.d3},a.fallback=function(){return null},a.supported(),t.exports=a},4061:function(t,e,n){var r=function(){"use strict";var t,e=this,n=this._init,r=this._exit,i=this._update,o=0,a=[];this._drawTile=function(n){if(t){var r=e._tileBounds(n),i=n.index.level||0,s=e._tileOffset(i),u={};u.ul=e.fromLocal(e.fromLevel({x:r.left-s.x,y:r.top-s.y},i),0),u.ll=e.fromLocal(e.fromLevel({x:r.left-s.x,y:r.bottom-s.y},i),0),u.ur=e.fromLocal(e.fromLevel({x:r.right-s.x,y:r.top-s.y},i),0),u.lr=e.fromLocal(e.fromLevel({x:r.right-s.x,y:r.bottom-s.y},i),0),u.ul.z=u.ll.z=u.ur.z=u.lr.z=i,o+=1,u.id=o,n.quadId=u.id,u.image=n.image,u.reference=n.toString(),a.push(u),t.data(a),t._update(),e.draw()}},this._remove=function(n){if(void 0!==n.quadId&&t){for(var r=0;r<a.length;r+=1)if(a[r].id===n.quadId){a.splice(r,1);break}t.data(a),t._update(),e.draw()}},this._update=function(n){return i.call(e,n),e._addBaseQuadToTiles(t,a),e},this._exit=function(){e.deleteFeature(t),t=null,a=[],r.apply(e,arguments)},this._init=function(){n.apply(e,arguments),(t=e.createFeature("quad",{previewColor:e._options.previewColor,previewImage:e._options.previewImage})).geoTrigger=void 0,t.gcs(e._options.gcs||e.map().gcs()),t.data(a),t._update()},this._getSubLayer=function(){},this._updateSubLayers=void 0};(0,n(1098).registerLayerAdjustment)("svg","tile",r),t.exports=r},2037:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(338),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(5005).call(this),this._init(t),this):new a(t)};r(a,o),i("svg","track",a),t.exports=a},7376:function(t){var e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz";t.exports=function(){var t,n=[];for(n.length=8,t=0;t<8;t+=1)n[t]=e.charAt(Math.floor(61*Math.random()));return n.join("")}},5747:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6858),a={arrow:{attrs:{class:"geo-vector-arrow geo-vector-marker",viewBox:"0 0 10 10",refX:1,refY:5,markerHeight:5,markerWidth:5,orient:"auto"},path:"M 0 0 L 10 5 L 0 10 z"},point:{attrs:{class:"geo-vector-point geo-vector-marker",viewBox:"0 0 12 12",refX:6,refY:6,markerHeight:8,markerWidth:8,orient:"auto"},path:"M 6 3 A 3 3 0 1 1 5.99999 3 Z"},bar:{attrs:{class:"geo-vector-bar geo-vector-marker",viewBox:"0 0 10 10",refX:0,refY:5,markerHeight:6,markerWidth:6,orient:"auto"},path:"M 0 0 L 2 0 L 2 10 L 0 10 z"},wedge:{attrs:{class:"geo-vector-wedge geo-vector-marker",viewBox:"0 0 10 10",refX:10,refY:5,markerHeight:5,markerWidth:5,orient:"auto"},path:"M 0 0 L 1 0 L 10 5 L 1 10 L 0 10 L 9 5 L 0 0"}},s=function(t){"use strict";if(!(this instanceof s))return new s(t);var e=n(5005),r=n(77),i=n(2493).d3;t=t||{},o.call(this,t),e.call(this);var u=this,l=this._exit,c=this._update,f=r(),h={};function d(t,e,n){return u._svgid()+"_marker_"+e+"_"+n}function p(t,e,n,r,o){var s=u.renderer()._definitions().selectAll("g.marker-group#"+u._svgid()).data(t.length?[1]:[]);s.enter().append("g").attr("id",u._svgid).attr("class","marker-group"),s.exit().remove();var l=t.reduce((function(t,e,n){var i=a[o(e,n)],s=a[r(e,n)];return i&&t.push({data:e,dataIndex:n,head:!0}),s&&t.push({data:e,dataIndex:n,head:!1}),t}),[]),c=(s=u.renderer()._definitions().selectAll("g.marker-group#"+u._svgid())).selectAll("marker.geo-vector-marker").data(l),f=u.renderer();c.enter().append("marker").each((function(t){var e=i.select(this),n=t.head?a[o(t.data,t.dataIndex)]:a[r(t.data,t.dataIndex)];Object.keys(n.attrs).forEach((function(t){e.attr(t,n.attrs[t])}))})).attr("id",(function(t){return d(t.data,t.dataIndex,t.head?"head":"tail")})).style("stroke",(function(t){return f._convertColor(e)(t.data,t.dataIndex)})).style("fill",(function(t){return f._convertColor(e)(t.data,t.dataIndex)})).style("opacity",(function(t){return n(t.data,t.dataIndex)})).append("path").attr("d",(function(t){return t.head?a[o(t.data,t.dataIndex)].path:a[r(t.data,t.dataIndex)].path})),c.exit().remove()}return this._build=function(){var t,e=u.data(),n=u.style.get(),r=u.renderer(),i=u.origin(),o=u.delta(),a=u.style("scale"),s=0;function l(){return a/r.scaleFactor()}return c.call(u),e||(e=[]),t=e.map((function(t,e){var n=u.featureGcsToDisplay(i(t,e)),r=o(t,e);return s=Math.max(s,r.x*r.x+r.y*r.y),{x1:n.x,y1:n.y,dx:r.x,dy:-r.y}})),s=Math.sqrt(s),a||(a=75/(s||1)),h.id=u._svgid(),h.data=e,h.append="line",h.attributes={x1:function(e,n){return t[n].x1},y1:function(e,n){return t[n].y1},x2:function(e,n){return t[n].x1+l()*t[n].dx},y2:function(e,n){return t[n].y1+l()*t[n].dy},"marker-start":function(t,e){return"url(#"+d(0,e,"tail")+")"},"marker-end":function(t,e){return"url(#"+d(0,e,"head")+")"}},h.style={stroke:function(){return!0},strokeColor:n.strokeColor,strokeWidth:n.strokeWidth,strokeOpacity:n.strokeOpacity,originStyle:n.originStyle,endStyle:n.endStyle},h.classes=["svgVectorFeature"],h.visible=u.visible,p(e,n.strokeColor,n.strokeOpacity,n.originStyle,n.endStyle),u.renderer()._drawFeatures(h),f.modified(),u.updateTime().modified(),u},this._update=function(){return c.call(u),u.timestamp()>=f.timestamp()?u._build():p(h.data,h.style.strokeColor,h.style.strokeOpacity,h.style.originStyle,h.style.endStyle),u},this._exit=function(){l.call(u),h={},p([],null,null,null,null)},this._init(t),this};s.markerConfigs=a,r(s,o),i("svg","vector",s),t.exports=s},6546:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=this,n=this._init;return this.featureType="text",this.position=function(t){return void 0===t?e.style("position"):(t!==e.style("position")&&(e.style("position",t),e.dataTime().modified(),e.modified()),e)},this.text=function(t){return void 0===t?e.style("text"):(t!==e.style("text")&&(e.style("text",t),e.dataTime().modified(),e.modified()),e)},this._init=function(t){t=t||{},n.call(e,t);var r=Object.assign({},{font:"bold 16px sans-serif",textAlign:"center",textBaseline:"middle",color:{r:0,g:0,b:0},rotation:0,rotateWithMap:!1,textScaled:!1,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},text:function(t){return t.text}},void 0===t.style?{}:t.style);void 0!==t.position&&(r.position=t.position),void 0!==t.text&&(r.text=t.text),e.style(r),r.position&&e.position(r.position),r.text&&e.text(r.text),e.dataTime().modified()},this._init(t),e};o.usedStyles=["visible","font","fontStyle","fontVariant","fontWeight","fontStretch","fontSize","lineHeight","fontFamily","textAlign","textBaseline","color","textOpacity","rotation","rotateWithMap","textScaled","offset","shadowColor","shadowOffset","shadowBlur","shadowRotate","textStrokeColor","textStrokeWidth"],o.create=function(t,e){"use strict";return(e=e||{}).type="text",i.create(t,e)},o.capabilities={feature:"text"},r(o,i),t.exports=o},5289:function(t,e,n){var r=n(5616),i=function(t){if(!(this instanceof i))return new i(t);this._index=t.index,this._size=t.size,this._overlap=t.overlap||{x:0,y:0},this._wrap=t.wrap||{x:1,y:1},this._url=t.url,this._fetched=!1,this._queue=t.queue||null,Object.defineProperty(this,"index",{get:function(){return this._index}}),Object.defineProperty(this,"size",{get:function(){return this._size}}),Object.defineProperty(this,"overlap",{get:function(){return this._overlap}}),this.fetch=function(){return this._fetched||r.get(this._url).done(function(){this._fetched=!0}.bind(this)).promise(this),this},this.fetched=function(){return this._fetched},this.then=function(t,e){return this.fetched()||!this._queue||!this._queue.add||this.state&&"pending"!==this.state()?this.fetch():this._queue.add(this,this.fetch),this.done&&this.fail?this.done(t).fail(e):this.then(t,e),this},this.catch=function(t){return this.then(void 0,t),this},this.toString=function(){return[this._index.level||0,this._index.y,this._index.x,this._index.reference||0].join("_")},this.bounds=function(t,e){var n,r,i,o;return r=(n=this.size.x*(this.index.x-t.x)-this.overlap.x-e.x)+this.size.x+2*this.overlap.x,i=(o=this.size.y*(this.index.y-t.y)-this.overlap.y-e.y)+this.size.y+2*this.overlap.y,this.overlap.x&&this.index.x===t.x&&(n+=this.overlap.x),this.overlap.y&&this.index.y===t.y&&(o+=this.overlap.y),{left:n,right:r,bottom:i,top:o}},Object.defineProperty(this,"bottom",{get:function(){return this.size.y*(this.index.y+1)+this.overlap.y}}),Object.defineProperty(this,"top",{get:function(){return this.size.y*this.index.y-(this.index.y?this.overlap.y:0)}}),Object.defineProperty(this,"left",{get:function(){return this.size.x*this.index.x-(this.index.x?this.overlap.x:0)}}),Object.defineProperty(this,"right",{get:function(){return this.size.x*(this.index.x+1)+this.overlap.x}}),this.fadeIn=function(t){return r.noop(t),this}};t.exports=i},9123:function(t){var e=function(t){return this instanceof e?(t=t||{},this._size=t.size||64,Object.defineProperty(this,"size",{get:function(){return this._size},set:function(t){for(;this._atime.length>t;)this.remove(this._atime[this._atime.length-1]);this._size=t}}),Object.defineProperty(this,"length",{get:function(){return this._atime.length}}),this._access=function(t){return this._atime.indexOf(t)},this.remove=function(t){var e="string"==typeof t?t:t.toString();return e in this._cache&&(this._atime.splice(this._access(e),1),delete this._cache[e],!0)},this.clear=function(){return this._cache={},this._atime=[],this},this.get=function(t,e){return(t="string"==typeof t?t:t.toString())in this._cache?(e||(this._atime.splice(this._access(t),1),this._atime.unshift(t)),this._cache[t]):null},this.add=function(t,e,n){this.remove(t);var r=t.toString();this._cache[r]=t,this._atime.unshift(r),n||this.purge(e)},this.purge=function(t){for(var e;this._atime.length>this.size;){e=this._atime.pop();var n=this._cache[e];t&&t(n),delete this._cache[e]}},this.clear(),this):new e(t)};t.exports=e},9264:function(t,e,n){var r=n(4626),i=n(6498),o=n(642);function a(t,e){return(t%e+e)%e}function s(t){var e,n=/\$?\{(s|S|[sS]:[^{}]+|[^-{}]-[^-{}]|([^,{}]+,)+[^,{}]+)\}/,r=t.replace(new RegExp(n,"g"),"{s}").replace(/\$?\{[xX]\}/g,"{x}").replace(/\$?\{[yY]\}/g,"{y}").replace(/\$?\{[zZ]\}/g,"{z}"),i=t.match(n);if(i)if(i[2])e=i[1].split(",");else if(":"===i[1][1])e=i[1].substr(2).split("");else if("-"===i[1][1]){e=[];for(var o=i[1].charCodeAt(0),s=i[1].charCodeAt(2),u=Math.min(o,s);u<=Math.max(o,s);u+=1)e.push(String.fromCharCode(u))}return function(t,n,i,o){return r.replace(/\{s\}/g,function(t,e,n,r){return r[a(t+e+n,r.length)]}(t,n,i,e||o)).replace(/\{x\}/g,t).replace(/\{y\}/g,n).replace(/\{z\}/g,i)}}var u=function(t){"use strict";if(!(this instanceof u))return new u(t);i.call(this,t);var e=n(5616),r=n(6409),l=n(5325),c=n(9123),f=n(5938),h=n(1098).adjustLayerForRenderer,d=n(5289);if((t=o.deepMerge({},this.constructor.defaults,t||{})).cacheSize||(t.cacheSize=t.keepLower?600:200),"string"===e.type(t.subdomains)&&(t.subdomains=t.subdomains.split("")),t.baseUrl){var p=t.baseUrl;p&&"/"!==p.charAt(p.length-1)&&(p+="/"),t.url=p+"{z}/{x}/{y}."+(t.imageFormat||"png")}t.originalUrl=t.url,"string"===e.type(t.url)&&(t.url=s(t.url));var m,g,y,v=this._init,x=this._exit,_=this.visible,b=t.queueSize||6,w=t.initialQueueSize||0,M=[],A={},T=[],E=t.nearestPixel,C=this;this._options=o.deepMerge({},t),this.attribution(t.attribution),this._activeTiles={},this._tileTree={},this._cache=c({size:t.cacheSize}),this._queue=t.queue||f({size:b,initialSize:w,track:t.cacheSize,needed:function(t){return this._tileLayers&&this._tileLayers.length?this._tileLayers.some((function(e){return t===e.cache.get(t.toString(),!0)})):t===C.cache.get(t.toString(),!0)}}),this._queue._tileLayers=this._queue._tileLayers||[],this._queue._tileLayers.push(C),this._queue.initialTrack&&this._queue.track&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length);var k={};return Object.defineProperty(this,"options",{get:function(){return Object.assign({},C._options)}}),Object.defineProperty(this,"cache",{get:function(){return C._cache}}),Object.defineProperty(this,"activeTiles",{get:function(){return Object.assign({},C._activeTiles)}}),Object.defineProperty(this,"queue",{get:function(){return C._queue},set:function(t){C._queue!==t&&(this._queue&&this._queue._tileLayers&&this._queue._tileLayers.indexOf(C)>=0&&(this._queue._tileLayers.splice(this._queue._tileLayers.indexOf(C),1),this._queue.initialTrack&&this._queue.track&&this._queue._tileLayers.length&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length)),C._queue=t,C._queue._tileLayers=C._queue._tileLayers||[],C._queue._tileLayers.push(C),C._queue.initialTrack&&C._queue.track&&(C._queue.track=C._queue.initialTrack*C._queue._tileLayers.length))}}),Object.defineProperty(this,"queueSize",{get:function(){return b},set:function(t){b=t,C._queue.size=t}}),Object.defineProperty(this,"initialQueueSize",{get:function(){return w},set:function(t){w=t||0,C._queue.initialSize=t||b}}),Object.defineProperty(this,"reference",{get:function(){return C.id()+"_"+(m||0)},set:function(t){m=t},configurable:!0}),this.tilesAtZoom=function(t){if(C._options.tilesAtZoom)return C._options.tilesAtZoom.call(C,t);var e=Math.pow(2,t);return{x:e,y:e}},this.tilesMaxBounds=function(t){return C._options.tilesMaxBounds?C._options.tilesMaxBounds.call(C,t):null},this.tileCropFromBounds=function(t){if(C._options.tilesMaxBounds){var e=t.index.level,n=C._tileBounds(t);return void 0===T[e]&&(T[e]=C.tilesMaxBounds(e)||null),T[e]&&(n.right>T[e].x||n.bottom>T[e].y)?{x:Math.max(0,Math.min(T[e].x,n.right)-n.left),y:Math.max(0,Math.min(T[e].y,n.bottom)-n.top)}:void 0}},this.isValid=function(t){return C._options.minLevel<=t.level&&t.level<=C._options.maxLevel&&(!!(C._options.wrapX||0<=t.x&&t.x<=C.tilesAtZoom(t.level).x-1)&&!!(C._options.wrapY||0<=t.y&&t.y<=C.tilesAtZoom(t.level).y-1))},this._origin=function(t){var e,n=C.toLevel(C.toLocal(C.map().origin()),t),r=C._options;return{index:e={x:Math.floor(n.x/r.tileWidth),y:Math.floor(n.y/r.tileHeight)},offset:{x:n.x-r.tileWidth*e.x,y:n.y-r.tileHeight*e.y}}},this._tileBounds=function(t){var e=C._origin(t.index.level);return t.bounds(e.index,e.offset)},this.tileAtPoint=function(t,e){var n=C._origin(e),r=C.map();t=C.displayToLevel(r.gcsToDisplay(t,null),e),isNaN(t.x)&&(t.x=0),isNaN(t.y)&&(t.y=0);var i=C._tileOffset(e);return i&&(t.x+=i.x,t.y+=i.y),{x:Math.floor(n.index.x+(n.offset.x+t.x)/C._options.tileWidth),y:Math.floor(n.index.y+(n.offset.y+t.y)/C._options.tileHeight)}},this.gcsTileBounds=function(t,e){var n=t.index?t:d({index:t,size:{x:C._options.tileWidth,y:C._options.tileHeight},url:""}),r=C._tileOffset(n.index.level),i=n.bounds({x:0,y:0},r),o=C.map(),a=o.unitsPerPixel(n.index.level),s=[{x:i.left*a,y:C._topDown()*i.top*a},{x:i.right*a,y:C._topDown()*i.bottom*a}];return(e=null===e?o.gcs():void 0===e?o.ingcs():e)!==o.gcs()&&(s=l.transformCoordinates(o.gcs(),e,s)),{left:s[0].x,top:s[0].y,right:s[1].x,bottom:s[1].y}},this._getTile=function(t,e){var n=e||t;return d({index:t,size:{x:C._options.tileWidth,y:C._options.tileHeight},queue:C._queue,url:C._options.url.call(C,n.x,n.y,Math.max(n.level||0,0),C._options.subdomains)})},this._getTileCached=function(t,e,n){var r=C.cache.get(C._tileHash(t));return null===r&&(r=C._getTile(t,e),C.cache.add(r,C.remove,n)),r},this._tileHash=function(t){return[t.level||0,t.y,t.x,t.reference||0].join("_")},this._getTileRange=function(t,e){var n=[C.tileAtPoint({x:e.left,y:e.top},t),C.tileAtPoint({x:e.right,y:e.top},t),C.tileAtPoint({x:e.left,y:e.bottom},t),C.tileAtPoint({x:e.right,y:e.bottom},t)];return{start:{x:Math.min(n[0].x,n[1].x,n[2].x,n[3].x),y:Math.min(n[0].y,n[1].y,n[2].y,n[3].y)},end:{x:Math.max(n[0].x,n[1].x,n[2].x,n[3].x),y:Math.max(n[0].y,n[1].y,n[2].y,n[3].y)}}},this._getTiles=function(t,n,r,i){var o,s,u,l,c,f,h,d,p,m,g,y=[],v=!1,x=C._options.keepLower?C._options.minLevel:Math.min(Math.max(t,C._options.minLevel),C._options.maxLevel);for(t<x&&(t=x),g=x;g<=t&&(c=(h=C._getTileRange(g,n)).start,f=h.end,l=C.tilesAtZoom(g),C._options.wrapX||(c.x=Math.min(Math.max(c.x,0),l.x-1),f.x=Math.min(Math.max(f.x,0),l.x-1),g===x&&C._options.keepLower&&(c.x=0,f.x=l.x-1)),C._options.wrapY||(c.y=Math.min(Math.max(c.y,0),l.y-1),f.y=Math.min(Math.max(f.y,0),l.y-1),g===x&&C._options.keepLower&&(c.y=0,f.y=l.y-1)),!(C._options.gcs&&C._options.gcs!==C.map().gcs()&&g!==x&&(f.x+1-c.x)*(f.y+1-c.y)>C.map().size().width*C.map().size().height/C._options.tileWidth/C._options.tileHeight*16));g+=1)for(o=c.x;o<=f.x;o+=1)for(s=c.y;s<=f.y;s+=1)u={level:g,x:o,y:s,reference:C.reference},d={level:g,x:o,y:s,reference:C.reference},C._options.wrapX&&(d.x=a(d.x,l.x)),C._options.wrapY&&(d.y=a(d.y,l.y)),C.isValid(d)&&(i&&y.length<M.length&&(m=M[y.length],v=v||u.level!==m.level||u.x!==m.x||u.y!==m.y),y.push({index:u,source:d}));if(i){if(!v&&y.length===M.length)return;M.splice(0,M.length),e.each(y,(function(t,e){M.push(e.index)}))}if(r){p={x:(c.x+f.x)/2,y:(c.y+f.y)/2,level:t,bottomLevel:t};for(var _=Math.max(f.x-c.x,f.y-c.y)+1;_>=1;_/=2)p.bottomLevel-=1;y.sort(C._loadMetric(p)),C._queue&&C._queue.batch(!0)}for(C.cache.size<y.length&&(console.log("Increasing cache size to "+y.length),C.cache.size=y.length),o=0;o<y.length;o+=1)y[o]=C._getTileCached(y[o].index,y[o].source,!0);return C.cache.purge(C.remove),y},this.gcs=function(t){if(void 0===t)return C._options.gcs||C.map().gcs();var e=C.gcs();return null===t?delete C._options.gcs:C._options.gcs=t,C.gcs()!==e&&(C.clear(),C.gcsFeatures(C.gcs()),C.modified(),C._update()),C},this.prefetch=function(t,n){var r;return r=C._getTiles(t,n,!0),e.when.apply(e,r.map((function(t){return t.fetch()})))},this._loadMetric=function(t){return function(e,n){var r,i,o,a,s;return e=e.index||e,n=n.index||n,e.level!==n.level?t.bottomLevel&&e.level>=t.bottomLevel!=n.level>=t.bottomLevel?e.level>=t.bottomLevel?-1:1:e.level-n.level:(s=Math.pow(2,e.level-t.level),o=(t.x+.5)*s-.5,a=(t.y+.5)*s-.5,(r=e.x-o)*r+(i=e.y-a)*i-((r=n.x-o)*r+(i=n.y-a)*i))}},this.fromLevel=function(t,e){var n=Math.pow(2,-e);return{x:t.x*n,y:t.y*n}},this.toLevel=function(t,e){var n=Math.pow(2,e);return{x:t.x*n,y:t.y*n}},this.drawTile=function(t){var e=t.toString();C._activeTiles.hasOwnProperty(e)?C._moveToTop(t):C._drawTile(t),C._activeTiles[e]=t},this._drawTile=function(t){if(null!==C.renderer())throw new Error("This draw method is not valid on renderer managed layers.");var n,r=t.index.level,i=e(C._getSubLayer(r)),o=C._tileBounds(t),a=C._options.animationDuration,s=e('<div class="geo-tile-container"/>').attr("tile-reference",t.toString());s.append(t.image),s.css({left:o.left-parseInt(i.attr("offsetx")||0,10)+"px",top:o.top-parseInt(i.attr("offsety")||0,10)+"px"}),(n=C.tileCropFromBounds(t))&&s.addClass("crop").css({width:n.x+"px",height:n.y+"px"}),a>0&&t.fadeIn(a),i.append(s),t.catch((function(){console.warn("Could not load tile at "+t.toString()),C._remove(t)}))},this.remove=function(t){var e=t.toString(),n=C._activeTiles[e];return n instanceof d&&C._remove(n),delete C._activeTiles[e],n},this._remove=function(t){t.image&&(t.image.parentElement?e(t.image.parentElement).remove():console.log("No parent element to remove "+t.toString(),t),e(t.image).remove())},this._moveToTop=function(t){e.noop(t)},this._getViewBounds=function(){var t=C.map(),e=t.zoom(),n=C._options.tileRounding(e),r=Math.pow(2,e-n),i=t.size(),o=C.displayToLevel({x:0,y:0}),a=C.displayToLevel({x:i.width,y:0}),s=C.displayToLevel({x:0,y:i.height}),u=C.displayToLevel({x:i.width,y:i.height});return{level:n,scale:r,left:Math.min(o.x,a.x,s.x,u.x),right:Math.max(o.x,a.x,s.x,u.x),top:Math.min(o.y,a.y,s.y,u.y),bottom:Math.max(o.y,a.y,s.y,u.y)}},this._purge=function(t,e,n){var r,i;if(C._updating)return C;for(i in n||(n=C._getViewBounds()),C._activeTiles)r=C._activeTiles[i],C._canPurge(r,n,t,e)&&C.remove(r);return C},this.clear=function(){var t,e=[];for(t in C._activeTiles)e.push(C.remove(t));return C._tileTree={},M=[],e},this.reset=function(){return C.clear(),C._cache.clear(),C._queue.initialSize=w,C},this.toLocal=function(t,e){var n=C.map(),r=n.unitsPerPixel(void 0===e?n.zoom():e);return{x:t.x/r,y:C._topDown()*t.y/r}},this.fromLocal=function(t,e){var n=C.map(),r=n.unitsPerPixel(void 0===e?n.zoom():e);return{x:t.x*r,y:C._topDown()*t.y*r}},this._topDown=function(){return C._options.topDown?1:-1},this._getSubLayer=function(t){if(C.canvas()){var n=C.canvas().find("div[data-tile-layer="+t.toFixed()+"]").get(0);return n||(n=e('<div class=geo-tile-layer data-tile-layer="'+t.toFixed()+'"/>').get(0),C.canvas().append(n)),n}},this._updateSubLayers=function(t,n){var r=C.canvas(),i=parseInt(r.attr("lastlevel"),10),o=parseInt(r.attr("lastoffsetx")||0,10),a=parseInt(r.attr("lastoffsety")||0,10);if(i===t&&Math.abs(o-n.left)<65536&&Math.abs(a-n.top)<65536)return{x:o,y:a};var s=C.map(),u=C._tileOffset(t),l=parseInt((n.left+n.right-s.size().width)/2+u.x,10),c=parseInt((n.top+n.bottom-s.size().height)/2+u.y,10);return r.find(".geo-tile-layer").each((function(n,r){var i=e(r),o=parseInt(i.data("tileLayer"),10);i.css("transform","scale("+Math.pow(2,t-o)+")");var a=parseInt(l/Math.pow(2,t-o),10),s=parseInt(c/Math.pow(2,t-o),10),u=a-parseInt(i.attr("offsetx")||0,10),f=s-parseInt(i.attr("offsety")||0,10);i.attr({offsetx:a,offsety:s}),i.find(".geo-tile-container").each((function(t,n){e(n).css({left:parseInt(e(n).css("left"),10)-u+"px",top:parseInt(e(n).css("top"),10)-f+"px"})}))})),r.attr({lastoffsetx:l,lastoffsety:c,lastlevel:t}),{x:l,y:c}},this._update=function(t){if(t&&t.event&&(t.event.event===r.zoom||t.event.event===r.rotate))return C;if(!C.visible())return C;var n,i=C.map(),o=i.bounds(void 0,null),a=i.zoom(),s=C._options.tileRounding(a);if(C._updateSubLayers){var u=C._getViewBounds(),l=C._updateSubLayers(s,u)||{x:0,y:0},c=C._tileOffset(s);if(null===C.renderer()){var f=Math.pow(2,a-s),h=i.rotation(),d=-c.x+-(u.left+u.right)/2+l.x,p=-c.y+-(u.bottom+u.top)/2+l.y,m=d+i.size().width/2,y=p+i.size().height/2;C.canvas().css({"transform-origin":-d+"px "+-p+"px"});var v="translate("+m+"px,"+y+"px)scale("+f+")";h&&(v+="rotate("+180*h/Math.PI+"deg)"),C.canvas().css("transform",v)}C.canvas().attr({scale:Math.pow(2,a-s),dx:-c.x+-(u.left+u.right)/2,dy:-c.y+-(u.bottom+u.top)/2,offsetx:l.x,offsety:l.y,rotation:i.rotation()})}if(void 0===(n=C._getTiles(s,o,!0,!0)))return C;if(C._tileTree={},n.forEach((function(t){if(t.fetched())delete A[t.toString()],C.drawTile(t),C._setTileTree(t);else{if(t._queued)(C._queue?C._queue.get(t):-1)>=0&&C._queue.add(t);else t.then((function(){if(!g&&t===C.cache.get(t.toString())){var e=i.zoom(),n=C._options.tileRounding(e),r=C._getViewBounds();C._canPurge(t,r,n)?C.remove(t):(C.drawTile(t),C._setTileTree(t))}})),t._queued=!0;C.addPromise(t),A[t.toString()]=t}})),e.when.apply(e,n).done((function(){var t=C.map().zoom(),e=C._options.tileRounding(t);C._purge(e,!0)})),"all"!==C._options.idleAfter)for(var x in A){var _=A[x];n.indexOf(_)<0&&(C.removePromise(_),delete A[x])}return C},this._setTileTree=function(t){if(!C._options.keepLower){var e=t.index;C._tileTree[e.level]=C._tileTree[e.level]||{},C._tileTree[e.level][e.x]=C._tileTree[e.level][e.x]||{},C._tileTree[e.level][e.x][e.y]=t}},this._getTileTree=function(t){return((C._tileTree[t.level]||{})[t.x]||{})[t.y]||null},this._isCovered=function(t){var e=t.index.level,n=t.index.x,r=t.index.y,i=[];return(i=C._getTileTree({level:e-1,x:Math.floor(n/2),y:Math.floor(r/2)}))?[i]:(i=[C._getTileTree({level:e+1,x:2*n,y:2*r}),C._getTileTree({level:e+1,x:2*n+1,y:2*r}),C._getTileTree({level:e+1,x:2*n,y:2*r+1}),C._getTileTree({level:e+1,x:2*n+1,y:2*r+1})]).every((function(t){return null!==t}))?i:null},this._outOfBounds=function(t,e){var n=C._tileOffset(t.index.level),r=1;return t.index.level!==e.level&&(r=Math.pow(2,(e.level||0)-(t.index.level||0))),(t.bottom-n.y)*r<e.top||(t.left-n.x)*r>e.right||(t.top-n.y)*r>e.bottom||(t.right-n.x)*r<e.left},this._canPurge=function(t,e,n,r){if(C._options.keepLower){if((n=n||0)<t.index.level&&t.index.level!==C._options.minLevel)return!0;if(t.index.level===C._options.minLevel&&!C._options.wrapX&&!C._options.wrapY)return!1}else if((r||C._isCovered(t))&&n!==t.index.level&&(n>=C._options.minLevel||t.index.level!==C._options.minLevel)&&(n<C._options.maxLevel||t.index.level!==C._options.maxLevel))return!0;return!!e&&C._outOfBounds(t,e)},this.displayToLevel=function(t,e){var n,r=C.map(),i=r.zoom(),o=C._options.tileRounding(i),a=r.unitsPerPixel(void 0===e?o:e);if(void 0===t){var s=r.size();t={x:s.width/2,y:s.height/2}}try{n=r.displayToGcs(t,C._options.gcs||null)}catch(t){n={x:0,y:0}}return{x:n.x/a,y:C._topDown()*n.y/a}},this.url=function(t){return void 0===t?C._options.originalUrl:(t===C._options.originalUrl||(C._options.originalUrl=t,"string"===e.type(t)&&(t=s(t)),C._options.url=t,C.reset(),C.map().draw()),C)},this.subdomains=function(t){return void 0===t?C._options.subdomains:(t&&("string"===e.type(t)&&(t=t.indexOf(",")>=0?t.split(","):t.split("")),C._options.subdomains=t,C.reset(),C.map().draw()),C)},this._tileOffset=function(t){return void 0===k[t]&&(k[t]=C._options.tileOffset(t)),k[t]},this.visible=function(t){return void 0===t?_():(C.visible()!==t&&(_(t),t&&C._update()),C)},this.nearestPixel=function(t,e){return void 0===t?E:(E!==t&&(E=t,e||(C.modified(),C._update())),C)},Object.defineProperty(this,"baseQuad",{get:function(){return C._options.baseQuad},set:function(t){C._options.baseQuad=t,C._update()}}),this._addBaseQuadToTiles=function(t,e){t&&(this.baseQuad!==y&&(y&&e.splice(0,1),(y=this.baseQuad)&&(e.splice(0,0,this.baseQuad),t.cacheUpdate(0)),t.data(e)),t._update())},this._init=function(){var t;if(v.apply(C,arguments),null===C.renderer())for(t=0;t<=C._options.maxLevel;t+=1)C._getSubLayer(t);return C},this._exit=function(){return C.reset(),x.apply(C,arguments),g=!0,this._queue&&this._queue._tileLayers&&this._queue._tileLayers.indexOf(C)>=0&&(this._queue._tileLayers.splice(this._queue._tileLayers.indexOf(C),1),this._queue.initialTrack&&this._queue.track&&this._queue._tileLayers.length&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length)),C},h("tile",this),this};u.defaults={minLevel:0,maxLevel:18,tileOverlap:{x:0,y:0},tileWidth:256,tileHeight:256,wrapX:!0,wrapY:!1,url:null,subdomains:"abc",tileOffset:function(t){return{x:0,y:0}},tilesMaxBounds:null,topDown:!1,keepLower:!0,idleAfter:"view",tileRounding:Math.round,attribution:"",animationDuration:0},r(u,i),t.exports=u},77:function(t){var e=0,n=function(){"use strict";if(!(this instanceof n))return new n;var t=this,r=0;return this.modified=function(){return r=e+=1,t},this.timestamp=function(){return r},this.getMTime=this.timestamp,this};t.exports=n},338:function(t,e,n){var r=n(4626),i=n(1275),o=n(1098),a=n(642),s=function(t){"use strict";if(!(this instanceof s))return new s(t);var e=n(5325);t=t||{},i.call(this,t);var r,u,l,c,f,h=this,d={},p={startTime:void 0!==t.startTime?t.startTime:null,endTime:void 0!==t.endTime?t.endTime:null,duration:void 0!==t.duration?t.duration:null,start:0,end:0},m=this.draw,g=this._exit,y=this._init,v=this.modified,x=this.style,_=this._update;return this.featureType="track",this._linePosition=function(t){return function(e,n,r,i){var o=p.timeFunc(e,n,r,i);return"past"===t&&o>=p.start||"current"===t&&o<p.start?p.startPosition[i]:"current"===t&&o>p.end||"future"===t&&o<p.end?p.endPosition[i]:p.positionFunc(e,n,r,i)}},this._headPosition=function(t,e){return p.endPosition[e]},this._headText=function(t,e){return p.text[e]},this._updateTimeRange=function(){null!==p.endTime||null===p.endTime&&(null===p.startTime||null==p.duration)?(p.end=null!==p.endTime?p.endTime:p.timeExtents.end,null!==p.startTime&&(null===p.endTime||p.startTime<=p.endTime)?p.start=p.startTime:null!==p.duration?p.start=p.end-p.duration:p.start=p.timeExtents.start):(p.start=p.startTime,p.end=p.start+p.duration)},this.calculateTimePosition=function(t,n,r){h.dataTime().timestamp()>=h.buildTime().timestamp()&&h._build(),n=null===n?h.layer().map().gcs():void 0===n?h.gcs():n;var i=e({source:h.gcs(),target:n}),o=h.data(),a=[],s=o.map((function(e,n){var r=p.trackFunc(e,n);if(a.push(r),!r.length)return{x:0,y:0,z:0,posidx:-1};var i,o,s,u,l=0,c=r.length-1;if(1===r.length)return{posidx:l,angidx0:l,angidx1:l};if((i=p.timeFunc(r[l],l,e,n))>=t)return{posidx:l,angidx0:l,angidx1:l+1};if((o=p.timeFunc(r[c],c,e,n))<=t)return{posidx:c,angidx0:c-1,angidx1:c};for(;c-l>1;){if(s=Math.floor((c+l)/2),(u=p.timeFunc(r[s],s,e,n))===t)return{posidx:s,angidx0:s-1,angidx1:s+1};u<t?(i=u,l=s):(o=u,c=s)}var f=(t-i)/(o-i);return{posidx0:l,posidx1:c,factor0:1-f,factor1:f,angidx0:l,angidx1:c}}));return s.forEach((function(t,e){var n,o,s;t.posidx<0||(void 0===t.posidx1?n=p.positionFunc(a[e][t.posidx],t.posidx,a[e],e):(o=i.forward(p.positionFunc(a[e][t.posidx0],t.posidx0,a[e],e),!0),s=i.forward(p.positionFunc(a[e][t.posidx1],t.posidx1,a[e],e),!0),n=i.inverse({x:o.x*t.factor0+s.x*t.factor1,y:o.y*t.factor0+s.y*t.factor1,z:(o.z||0)*t.factor0+(s.z||0)*t.factor1},!0)),t.x=n.x,t.y=n.y,t.z=n.z||0,r&&(void 0===t.posidx1&&(o=i.forward(t.angidx0===t.posidx?n:p.positionFunc(a[e][t.angidx0],t.angidx0,a[e],e),!0),s=i.forward(t.angidx1===t.posidx?n:p.positionFunc(a[e][t.angidx1],t.angidx1,a[e],e),!0)),t.angle=Math.atan2(s.y-o.y,s.x-o.x)))})),s},this._build=function(){h.buildTime().modified(),r||(r={past:h.layer().createFeature("line"),future:h.layer().createFeature("line"),current:h.layer().createFeature("line")},h.dependentFeatures([r.past,r.current,r.future]));var t=h.data();p.data=t,p.timeFunc=h.style.get("time"),p.positionFunc=h.style.get("position"),p.trackFunc=h.style.get("track"),p.textFunc=h.style.get("text"),["past","current","future"].forEach((function(e){r[e].style(h.style()).style(h[e+"Style"]()).line(h.style("track")).gcs(h.gcs()).data(t).position(h._linePosition(e))}));var e,n,i={};if(t.forEach((function(t,e){var n,r=p.trackFunc(t,e);r.length&&(n=p.timeFunc(r[0],0,t,e),(void 0===i.start||n<i.start)&&(i.start=n),r.length>1&&(n=p.timeFunc(r[r.length-1],r.length-1,t,e)),(void 0===i.end||n>i.end)&&(i.end=n))})),p.timeExtents=i,h._updateTimeRange(),p.startPosition=h.calculateTimePosition(p.start,null),p.endPosition=h.calculateTimePosition(p.end,null,!0),p.text=t.map((function(t,r){var i=p.textFunc(t,r);return e|=null==i,null==i||""===i?"":(n=!0,p.startPosition[r].posidx<0&&(i=""),i)})),e&&!l){if(!(o.registries.features[h.layer().rendererName()]||{}).marker){var a=o.rendererForFeatures(["marker"]);u=o.createLayer("feature",h.layer().map(),{renderer:a}),h.layer().addChild(u),h.layer().node().append(u.node())}l=(u||h.layer()).createFeature("marker");var s=h.dependentFeatures();s.push(l),h.dependentFeatures(s)}if(n&&!f){if(!(o.registries.features[h.layer().rendererName()]||{}).text){var d=o.rendererForFeatures(["text"]);c=o.createLayer("feature",h.layer().map(),{renderer:d}),h.layer().addChild(c),h.layer().node().append(c.node())}f=(c||h.layer()).createFeature("text");var m=h.dependentFeatures();m.push(f),h.dependentFeatures(m)}if(l){l.headData=p.endPosition,l.style(h.markerStyle()).gcs(h.gcs()).data(t).position(h._headPosition);var g=l.style.get("radius");l.style("radius",(function(t,e){return p.text[e]||p.startPosition[e].posidx<0?0:g(t,e)}))}return f&&(f.headData=p.endPosition,f.style(h.textStyle()).gcs(h.gcs()).data(t).text(h._headText).position(h._headPosition)),h},this._updateTimeAndPosition=function(){r&&(h._updateTimeRange(),p.startPosition=h.calculateTimePosition(p.start,null),p.endPosition=h.calculateTimePosition(p.end,null,!0),r.past.modified(),r.current.modified(),r.future.modified(),l&&l.modified(),f&&f.modified(),h.updateTime().modified(),h.modified())},this._update=function(){return _.call(h),(h.dataTime().timestamp()>=h.buildTime().timestamp()||h.updateTime().timestamp()<=h.timestamp())&&h._build(),h.updateTime().modified(),h},this.draw=function(){var t=m();return r&&(r.past.draw(),r.current.draw(),r.future.draw()),l&&l.draw(),f&&f.draw(),t},this.modified=function(){var t=v();return r&&(r.past.modified(),r.current.modified(),r.future.modified()),l&&l.modified(),f&&f.modified(),t},this.style=function(t,e,n){return"style"===(n=n||"style")?x(t,e):void 0===t?d[n]:"string"==typeof t&&void 0===e?(d[n]||{})[t]:(void 0===d[n]&&(d[n]={}),void 0===e?d[n]=a.deepMerge(d[n],t):d[n][t]=e,h.modified(),h)},this.style.get=x.get,["markerStyle","textStyle","pastStyle","currentStyle","futureStyle"].forEach((function(t){h[t]=function(e,n){return h.style(e,n,t)}})),this.track=function(t){return void 0===t?h.style("track"):(h.style("track",t),h.dataTime().modified(),h.modified(),h)},this.position=function(t){return void 0===t?h.style("position"):(h.style("position",t),h.dataTime().modified(),h.modified(),h)},this.time=function(t){return void 0===t?h.style("time"):(h.style("time",t),h.dataTime().modified(),h.modified(),h)},this.timeRange=function(t){if(void 0===t)return{startTime:p.startTime,endTime:p.endTime,duration:p.duration,start:p.start,end:p.end,minimum:(p.timeExtents||{}).start,maximum:(p.timeExtents||{}).end};var e=!1;return void 0!==t.startTime&&t.startTime!==p.startTime&&(p.startTime=null===t.startTime?t.startTime:+t.startTime,e=!0),void 0!==t.endTime&&t.endTime!==p.endTime&&(p.endTime=null===t.endTime?t.endTime:+t.endTime,e=!0),void 0!==t.duration&&t.duration!==p.duration&&(p.duration=null===t.duration?t.duration:+t.duration,e=!0),e&&h._updateTimeAndPosition(),h},this.startTime=function(t){return void 0===t?p.startTime:(t!==p.startTime&&(p.startTime=null===t?t:+t,h._updateTimeAndPosition()),h)},this.endTime=function(t){return void 0===t?p.endTime:(t!==p.endTime&&(p.endTime=null===t?t:+t,h._updateTimeAndPosition()),h)},this.duration=function(t){return void 0===t?p.duration:(t!==p.duration&&(p.duration=null===t?t:+t,h._updateTimeAndPosition()),h)},this._mergeSearchResults=function(t,e){return t.extra=t.extra||{},e.forEach((function(e){return e.value.index.forEach((function(n,r){t.index.indexOf(n)<0&&(t.index.push(n),t.found.push(e.value.found[r]),t.where=t.where||{},e.value.extra&&e.value.extra[n]&&(t.extra[n]=e.value.extra[n]),a.isObject(t.extra[n])||(t.extra[n]={value:t.extra[n]}),t.extra[n].where=e.key)}))})),t},this.pointSearch=function(t){var e=r.current.pointSearch(t),n=r.past.pointSearch(t),i=r.future.pointSearch(t),o=l?l.pointSearch(t):{index:[]};return this._mergeSearchResults(e,[{key:"marker",value:o},{key:"past",value:n},{key:"future",value:i}])},this.polygonSearch=function(t,e){var n=r.current.polygonSearch(t,e),i=r.past.polygonSearch(t,e),o=r.future.polygonSearch(t,e),a=l?l.polygonSearch(t,e):{index:[]};return this._mergeSearchResults(n,[{key:"marker",value:a},{key:"past",value:i},{key:"future",value:o}])},this._exit=function(){r&&h.layer()&&(h.layer().deleteFeature(r.past),h.layer().deleteFeature(r.current),h.layer().deleteFeature(r.future)),r=null,(u||h.layer())&&l&&(u||h.layer()).deleteFeature(l),u&&h.layer()&&h.layer().removeChild(u),u=null,(c||h.layer())&&f&&(c||h.layer()).deleteFeature(f),c&&h.layer()&&h.layer().removeChild(c),c=null,h.dependentFeatures([]),g()},this._init=function(t){t=t||{},y.call(h,t);var e=a.deepMerge({},{track:a.identityFunction,position:a.identityFunction,time:function(t,e){return void 0!==t.t?t.t:e},uniformLine:"drop",closed:!1},void 0===t.style?{}:t.style),n=a.deepMerge({},{rotateWithMap:!0,rotation:function(t,e){return-p.endPosition[e].angle||0}},void 0===t.markerStyle?{}:t.markerStyle),r=a.deepMerge({},{rotateWithMap:!0,rotation:function(t,e){return void 0!==p.endPosition[e].angle?-p.endPosition[e].angle+Math.PI/2:0}},void 0===t.textStyle?{}:t.textStyle),i=a.deepMerge({},{strokeOpacity:.25},void 0===t.pastStyle?{}:t.pastStyle),o=a.deepMerge({},{},void 0===t.currentStyle?{}:t.currentStyle),s=a.deepMerge({},{strokeOpacity:.25},void 0===t.futureStyle?{}:t.futureStyle);["track","position","time"].forEach((function(n){void 0!==t[n]&&(e[n]=t[n])})),h.style(e),h.markerStyle(n),h.textStyle(r),h.pastStyle(i),h.currentStyle(o),h.futureStyle(s)},this};r(s,i),t.exports=s},5325:function(t,e,n){var r=n(1960),i=n(1982),o=n(3503),a=n(642);r=r.__esModule?r.default:r;var s=n(9689);s.keys().forEach((function(t){r.Proj.projections.add(s(t))}));var u={},l=/^(.* |)\+axis=e(n|s)u(| .*)$/,c=/(^|\s)\+(s[1-3][1-3]|[xyz]off)=\S/,f=function(t){"use strict";if(!(this instanceof f))return(t=t||{}).source in u||(Object.keys(u).length>=10&&(u={}),u[t.source]={}),t.target in u[t.source]||(Object.keys(u[t.source]).length>=10&&(u[t.source]={}),u[t.source][t.target]=new f(t)),u[t.source][t.target];var e,n,s,l,h,d,p,m=this,g={s11:0,s12:4,s13:8,xoff:12,s21:1,s22:5,s23:9,yoff:13,s31:2,s32:6,s33:10,zoff:14};function y(t){if(!c.exec(t))return{proj:t};var e,n,r=a.mat4AsArray(),i=[];return t.split(/(\s+)/).forEach((function(t){var e=/^\+(s[1-3][1-3]|[xyz]off)=(.*)$/.exec(t);e?r[g[e[1]]]=parseFloat(e[2]):i.push(t)})),n={proj:i.join(" "),orig:t},(e=o.invert(a.mat4AsArray(),r))?(n.matrix=r,n.inverse=e):console.warn("Affine transform is not invertable and will not be used: "+t),n}function v(){var t=y(m.source()),n=y(m.target()),i=t.proj,o=n.proj;l=t.matrix,h=t.inverse,d=n.matrix,p=n.inverse,e=new r(i,o)}this.source=function(t){return void 0===t?n||"EPSG:4326":(n=t,v(),m)},this.target=function(t){return void 0===t?s||"EPSG:3857":(s=t,v(),m)},this._forward=function(t){if(l){var n=i.transformMat4(a.vec3AsArray(),[t.x,t.y,t.z||0],h);t={x:n[0],y:n[1],z:n[2]}}var r=e.forward(t,!0);if(r.z=t.z||0,d){var o=i.transformMat4(a.vec3AsArray(),[r.x,r.y,r.z],d);r={x:o[0],y:o[1],z:o[2]}}return r},this._inverse=function(t){if(d){var n=i.transformMat4(a.vec3AsArray(),[t.x,t.y,t.z||0],p);t={x:n[0],y:n[1],z:n[2]}}var r=e.inverse(t,!0);if(r.z=t.z||0,l){var o=i.transformMat4(a.vec3AsArray(),[r.x,r.y,r.z],l);r={x:o[0],y:o[1],z:o[2]}}return r},this.forward=function(t){return Array.isArray(t)?t.map(m._forward):m._forward(t)},this.inverse=function(t){return Array.isArray(t)?t.map(m._inverse):m._inverse(t)},t=t||{};try{this.source(t.source)}catch(e){console.error("Can't use transform source: "+t.source),this.source("EPSG:4326")}try{this.target(t.target)}catch(e){console.error("Can't use transform target: "+t.target),this.target("EPSG:3857")}return this};f.defs=r.defs,f.lookup=function(t){var e,i,o=n(5616),a=o.Deferred();return r.defs.hasOwnProperty(t)?a.resolve(r.defs[t]):2!==(i=t.split(":")).length||"EPSG"!==i[0].toUpperCase()?a.reject("Invalid projection code").promise():(e=i[1],o.ajax({url:"https://epsg.io/"+encodeURIComponent(e)+".proj4"}).done((function(e){var n=(e.results||[])[0];return n?(r.defs(t,n),o.when(r.defs[t])):a.reject(e).promise()})))},f.transformCoordinates=function(t,e,n,r){"use strict";if(t===e||Array.isArray(n)&&!n.length)return n;if(Array.isArray(n)&&n.length>=3&&3===r&&!a.isObject(n[0])&&!c.test(t)&&!c.test(e))return f.transformCoordinatesFlatArray3(t,e,n);if(Array.isArray(n)&&n.length&&a.isObject(n[0])&&"x"in n[0]&&"y"in n[0]){var i=t.match(l),o=e.match(l);if(i&&o&&i[1]===o[1]&&i[3]===o[3])return"z"in n[0]?n.map((function(t){return{x:+t.x,y:-t.y,z:+t.z||0}})):n.map((function(t){return{x:+t.x,y:-t.y}}))}var s,u=f({source:t,target:e});return a.isObject(n)&&"x"in n&&"y"in n?(s=u.forward({x:+n.x,y:+n.y,z:+n.z||0},!0),"z"in n?s:{x:s.x,y:s.y}):Array.isArray(n)&&1===n.length&&a.isObject(n[0])&&"x"in n[0]&&"y"in n[0]?(s=u.forward({x:+n[0].x,y:+n[0].y,z:+n[0].z||0},!0),"z"in n[0]?[s]:[{x:s.x,y:s.y}]):f.transformCoordinatesArray(u,n,r)},f.transformCoordinatesArray=function(t,e,n){var r,i,o,s,u,l,c,f,h,d={};function p(){if(Array.isArray(e[0]))if(2===e[0].length)s=function(t){return+e[t][0]},u=function(t){return+e[t][1]},c=function(t,e,n){f[t]=[e,n]};else{if(3!==e[0].length)throw new Error("Invalid coordinates. Requires two or three components per array");s=function(t){return+e[t][0]},u=function(t){return+e[t][1]},l=function(t){return+e[t][2]},c=function(t,e,n,r){f[t]=[e,n,r]}}else if(2===e.length)o=2,s=function(t){return+e[t*o]},u=function(t){return+e[t*o+1]},c=function(t,e,n){f[t]=e,f[t+1]=n};else if(3===e.length)o=3,s=function(t){return+e[t*o]},u=function(t){return+e[t*o+1]},l=function(t){return+e[t*o+2]},c=function(t,e,n,r){f[t]=e,f[t+1]=n,f[t+2]=r};else{if(!n)throw new Error("Invalid coordinates");if(2!==n&&3!==n)throw new Error("Number of components should be two or three");o=n,s=function(t){return+e[t]},u=function(t){return+e[t+1]},2===n?c=function(t,e,n){f[t]=e,f[t+1]=n}:(l=function(t){return+e[t+2]},c=function(t,e,n,r){f[t]=e,f[t+1]=n,f[t+2]=r})}}if(l=function(){return 0},!Array.isArray(e))throw new Error("Coordinates are not valid");if((f=[]).length=e.length,i=e.length,!e.length)return f;for(Array.isArray(e[0])||a.isObject(e[0])?(o=1,Array.isArray(e[0])?p():a.isObject(e[0])&&function(){if(!(e[0]&&"x"in e[0]&&"y"in e[0]))throw new Error("Invalid coordinates");s=function(t){return+e[t].x},u=function(t){return+e[t].y},"z"in e[0]?(l=function(t){return+e[t].z},c=function(t,e,n,i){f[r]={x:e,y:n,z:i}}):c=function(t,e,n){f[t]={x:e,y:n}}}()):p(),r=0;r<i;r+=o)d.x=s(r),d.y=u(r),d.z=l(r),h=t.forward(d,!0),c(r,h.x,h.y,h.z);return f},f.transformCoordinatesFlatArray3=function(t,e,n){"use strict";var i,o=t.match(l),a=e.match(l);if(o&&a&&o[1]===a[1]&&o[3]===a[3]){for(i=n.length-3+1;i>=0;i-=3)n[i]*=-1;return n}var s,u=r.Proj(t),c=r.Proj(e),f={},h=new r(u,c);for(i=n.length-3;i>=0;i-=3)f.x=+n[i],f.y=+n[i+1],f.z=+(n[i+2]||0),s=h.forward(f,!0),n[i]=s.x,n[i+1]=s.y,n[i+2]=void 0===s.z?f.z:s.z;return n},f.affineForward=function(t,e){"use strict";var n,r=t.origin,i=t.scale||{x:1,y:1,z:1};for(n=0;n<e.length;n+=1)e[n].x=(e[n].x-r.x)*i.x,e[n].y=(e[n].y-r.y)*i.y,e[n].z=((e[n].z||0)-(r.z||0))*i.z;return e},f.affineInverse=function(t,e){"use strict";var n,r=t.origin,i=t.scale||{x:1,y:1,z:1};for(n=0;n<e.length;n+=1)e[n].x=e[n].x/i.x+r.x,e[n].y=e[n].y/i.y+r.y,e[n].z=(e[n].z||0)/i.z+(r.z||0);return e},f.sphericalDistance=function(t,e,n,i,o){if(i=i||"EPSG:4326",o=o||r.WGS84,(n=n||i)!==i){var a=f.transformCoordinates(n,i,[t,e]);t=a[0],e=a[1]}var s=t.y*Math.PI/180,u=e.y*Math.PI/180,l=(e.x-t.x)*Math.PI/180,c=Math.sin(s),h=Math.cos(s),d=Math.sin(u),p=Math.cos(u),m=Math.atan2(Math.pow(Math.pow(p*Math.sin(l),2)+Math.pow(h*d-c*p*Math.cos(l),2),.5),c*d+h*p*Math.cos(l));return o.a*m},f.vincentyDistance=function(t,e,n,i,o,a){if(i=i||"EPSG:4326",o=o||r.WGS84,a=a||100,(n=n||i)!==i){var s=f.transformCoordinates(n,i,[t,e]);t=s[0],e=s[1]}var u,l,c,h,d,p,m,g,y,v,x=o.a,_=o.b||o.a*(1-(o.f||1/o.rf)),b=o.f||(o.rf?1/o.rf:1-_/x),w=t.y*Math.PI/180,M=e.y*Math.PI/180,A=((e.x-t.x)%360+360)%360*Math.PI/180,T=Math.atan((1-b)*Math.tan(w)),E=Math.atan((1-b)*Math.tan(M)),C=Math.sin(T),k=Math.cos(T),S=Math.sin(E),O=Math.cos(E),P=A,L=A+2*Math.PI;if(w===M&&!A)return{distance:0,alpha1:0,alpha2:0};for(v=a;v>0&&Math.abs(P-L)>1e-12;v-=1)u=Math.pow(Math.pow(O*Math.sin(P),2)+Math.pow(k*S-C*O*Math.cos(P),2),.5),l=C*S+k*O*Math.cos(P),c=Math.atan2(u,l),h=k*O*Math.sin(P)/u,L=P,P=A+(1-(m=b/16*(d=1-Math.pow(h,2))*(4+b*(4-3*d))))*b*h*(c+m*u*((p=l-(d?2*C*S/d:0))+m*l*(2*Math.pow(p,2)-1)));return v?{distance:_*(1+(g=d*(x*x-_*_)/(_*_))/16384*(4096+g*(g*(320-175*g)-768)))*(c-(y=g/1024*(256+g*(g*(74-47*g)-128)))*u*(p+y/4*(l*(2*Math.pow(p,2)-1)-y/6*p*(4*u*u-3)*(4*Math.pow(p,2)-3)))),alpha1:Math.atan2(O*Math.sin(P),k*S-C*O*Math.cos(P)),alpha2:Math.atan2(k*Math.sin(P),-C*O+k*S*Math.cos(P))}:void 0},f.onlyInvertedY=function(t,e){var n=t.match(l),r=e.match(l);return n&&r&&n[1]===r[1]&&n[3]===r[3]},f.proj4=r,t.exports=f},3170:function(t){t.exports={}},5734:function(t,e,n){var r=n(2493).d3,i=n(8524),o=n(4626),a=n(1098).registerWidget,s=n(642),u=n(7376);n(1159);var l=function(t){"use strict";if(!(this instanceof l))return new l(t);i.call(this,t);var e=this,n=[],o=t.width||300,a=t.ticks||6,f=this._init;return this._init=function(){f();var n=e.canvas();r.select(n).attr("class","color-legend-container"),e.popup=r.select(n).append("div").attr("class","color-legend-popup"),t.categories&&e.categories(t.categories)},this._draw=function(){if(r.select(e.canvas()).selectAll("div.geojs-color-legends").remove(),n.length){r.select(e.canvas()).style("display","block");var t=r.select(e.canvas()).append("div").attr("class","geojs-color-legends"),i=o;n.forEach((function(n,r){var o=t.append("div").attr("class","geojs-color-legend");o.append("div").attr("class","geojs-title").text(n.name);var a=o.append("svg").attr("class","svg").attr("width",i).attr("height","40px").attr("viewBox","-20 0 "+i+" 40");"discrete"===n.type?e._drawDiscrete(a,i-40,n):"continuous"===n.type&&e._drawContinous(a,i-40,n)}))}else r.select(e.canvas()).style("display","none")},this.categories=function(t){return void 0===t?n:(n=e._prepareCategories(t),e._draw(),e)},this.addCategories=function(t){return n=n.concat(e._prepareCategories(t)),e._draw(),e},this.removeCategories=function(t){return n=n.filter((function(e){return-1===t.indexOf(e)})),e._draw(),e},this._prepareCategories=function(t){return t.forEach((function(t){t.color=t.colors.map((function(t){return s.convertColorToHex(t,!0)}))})),t},this._drawDiscrete=function(t,n,i){function o(t){var e=Math.ceil(t.domain().length/a),n=t.domain().filter((function(t,n){return n%e==0}));return r.axisBottom(t).tickFormat(r.format(".2s")).tickValues(n)}if(-1===["linear","log","sqrt","pow","quantile","ordinal"].indexOf(i.scale))throw new Error("unsupported scale");var u,l,f,h,d,p,m;if("ordinal"===i.scale){f=r.scaleOrdinal().domain(i.domain).range(i.colors),e._renderDiscreteColors(t,i.domain,f,n,(function(t){return t})),h=r.scaleBand().domain(i.domain).rangeRound([0,n]);var g=Math.ceil(i.domain.length/a),y=i.domain.filter((function(t,e){return e%g==0}));d=r.axisBottom(h).tickValues(y)}else if("quantile"===i.scale){u=[0,i.colors.length],p=s.range(0,i.colors.length-1),l=r.scaleQuantile().domain(i.domain).range(p),f=r.scaleQuantize().domain(u).range(i.colors),e._renderDiscreteColors(t,p,f,n,(function(t){return l.invertExtent(t).join(" - ")}));var v=[l.invertExtent(0)[0]];v=v.concat(p.map((function(t){return l.invertExtent(t)[1]}))),d=o(h=r.scalePoint().domain(v).range([0,n]))}else if(-1!==["linear","log","sqrt","pow"].indexOf(i.scale)){u=[0,i.colors.length],l=r["scale"+i.scale.charAt(0).toUpperCase()+i.scale.slice(1)]().domain(i.domain).range(u).nice(),f=r.scaleQuantize().domain(u).range(i.colors),p=s.range(0,i.colors.length-1);var x=Math.max.apply(null,i.domain.map((function(t){return c(t)})));e._renderDiscreteColors(t,p,f,n,(function(t){return e._popupFormatter(l.invert(t),x)+" - "+e._popupFormatter(l.invert(t+1),x)})),(m=p.slice()).push(i.colors.length),d=o(h=r.scalePoint().domain(m.map((function(t){return l.invert(t)}))).range([0,n]))}i.endAxisLabelOnly&&d.tickValues([h.domain()[0],h.domain()[h.domain().length-1]]),e._renderAxis(t,d)},this._renderDiscreteColors=function(t,n,r,i,o){t.selectAll("rect").data(n).enter().append("rect").attr("width",i/n.length).attr("height","20px").attr("fill",(function(t){return r(t)})).attr("transform",(function(t,e){return"translate("+e*i/n.length+" ,0)"})).on("mousemove",(function(t,n){e._showPopup(t,o(n))})).on("mouseout",e._hidePopup)},this._drawContinous=function(t,n,i){var o,s,l;if(-1===["linear","log","sqrt","pow"].indexOf(i.scale))throw new Error("unsupported scale");var f=[0];for(l=1;l<i.domain.length-1;l++)f.push(n/(i.domain.length-1)*l);f.push(n),o=r["scale"+i.scale.charAt(0).toUpperCase()+i.scale.slice(1)]().domain(i.domain).range(f).nice(),"log"===i.scale&&i.base&&o.base(i.base),"pow"===i.scale&&i.exponent&&o.exponent(i.exponent);var h=u(),d=Math.max.apply(null,i.domain.map((function(t){return c(t)}))),p=t.append("defs").append("linearGradient").attr("id","gradient"+h);for(p.append("stop").attr("offset","0%").attr("stop-color",i.colors[0]),l=1;l<i.colors.length-1;l++)p.append("stop").attr("offset",(100/(i.colors.length-1)*l).toFixed(6)+"%").attr("stop-color",i.colors[l]);p.append("stop").attr("offset","100%").attr("stop-color",i.colors[i.colors.length-1]),t.append("rect").attr("fill","url(#gradient"+h+")").attr("width",n).attr("height","20px").on("mousemove",(function(t){var n=o.invert(r.pointer(t)[0]),i=e._popupFormatter(n,d);e._showPopup(t,i)})).on("mouseout",e._hidePopup),s=r.axisBottom(o).ticks(a,".2s"),i.endAxisLabelOnly&&s.tickValues([i.domain[0],i.domain[i.domain.length-1]]),e._renderAxis(t,s)},this._renderAxis=function(t,e){t.append("g").attr("class","axis x").attr("transform","translate(0, 20)").call(e)},this._popupFormatter=function(t,e){return t=parseFloat(t.toFixed(8)),e=Math.min(e,c(t)),e=Math.min(e,Math.max(3,7-Math.trunc(t).toString().length)),r.format("."+e+"f")(t)},this._showPopup=function(t,n){var i=r.pointer(t,e.canvas());e.popup.text(n);var o=e.canvas().clientWidth,a=e.popup.node().clientWidth;e.popup.style("left",i[0]-(i[0]+a-o>-10?a:0)+"px").style("top",i[1]-22+"px").transition().duration(200).style("opacity",1)},this._hidePopup=function(){e.popup.transition().duration(200).style("opacity",0)},this};function c(t){if(!isFinite(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;){if(!isFinite(t*e))return 0;e*=10,n++}return n}o(l,i),a("dom","colorLegend",l),t.exports=l},8524:function(t,e,n){var r=n(8738),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=this;return this._init=function(){return t.hasOwnProperty("parent")&&t.parent.addChild(e),e._createCanvas(),e._appendCanvasToParent(),e.canvas().addEventListener("mousedown",(function(t){t.stopPropagation()})),e.reposition(),e},this._createCanvas=function(){e.canvas(document.createElement(t.el||"div"))},this};i(a,r),o("dom","dom",a),t.exports=a},4812:function(t,e,n){t.exports={colorLegendWidget:n(5734),domWidget:n(8524),legendWidget:n(9443),scaleWidget:n(2894),sliderWidget:n(3019),svgWidget:n(7854),uiLayer:n(4231),widget:n(8738)}},9443:function(t,e,n){var r=n(7854),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=n(2493).d3,i=n(6409),o=this,s=[],u=null,l=null,c=null;this.categories=function(t){return void 0===t?s.slice():(s=t.slice().map((function(t){return"line"===t.type&&(t.style.fill=!1,t.style.stroke=!0),t})),o.draw(),o)},this.size=function(){var t,n=1,r=e.select(o.canvas()).append("text").style("opacity",1e-6);return s.forEach((function(t){r.text(t.name),n=Math.max(n,r.node().getBBox().width)})),r.remove(),t=20*(s.length+1),{width:n+50,height:t}},this.draw=function(){function t(t){t.style("fill",(function(t){return t.style.fill||void 0===t.style.fill?t.style.fillColor:"none"})).style("fill-opacity",(function(t){return void 0===t.style.fillOpacity?1:t.style.fillOpacity})).style("stroke",(function(t){return t.style.stroke||void 0===t.style.stroke?t.style.strokeColor:"none"})).style("stroke-opacity",(function(t){return void 0===t.style.strokeOpacity?1:t.style.strokeOpacity})).style("stroke-width",(function(t){return void 0===t.style.strokeWidth?1.5:t.style.strokeWidth}))}o._init(),c.attr("height",o.size().height+24).style("display",null);var e=o._scale(),n=l.selectAll("g.geo-label").data(s,(function(t){return t.name})).enter().append("g").attr("class","geo-label").attr("transform",(function(t,n){return"translate(0,"+e.y(n)+")"}));return t(n.filter((function(t){return"point"!==t.type&&"line"!==t.type})).append("rect").attr("x",0).attr("y",-6).attr("rx",5).attr("ry",5).attr("width",40).attr("height",12)),t(n.filter((function(t){return"point"===t.type})).append("circle").attr("cx",20).attr("cy",0).attr("r",6)),t(n.filter((function(t){return"line"===t.type})).append("line").attr("x1",0).attr("y1",0).attr("x2",40).attr("y2",0)),n.append("text").attr("x","50px").attr("y",0).attr("dy","0.3em").text((function(t){return t.name})),o.reposition(),o},this._scale=function(){return{x:e.scaleLinear().domain([0,1]).range([0,o.size().width]),y:e.scaleLinear().domain([0,s.length-1]).range([6,o.size().height-6])}},this._init=function(){u||(o._createCanvas(),o._appendCanvasToParent());var t=o.size().width+24+4,n=o.size().height+24+4;u&&u.remove(),e.select(o.canvas()).attr("width",t).attr("height",n),u=e.select(o.canvas()).append("g"),l=u.append("g").attr("transform","translate("+[14,14]+")"),(c=l.append("rect").attr("x",-12).attr("y",-12).attr("width",t-4).attr("height",n-4).attr("rx",3).attr("ry",3)).style("stroke","black").style("stroke-width","1.5px").style("fill","white").style("fill-opacity",.75).style("display","none"),l.on("mousedown",(function(t){t.stopPropagation()})),l.on("mouseover",(function(){c.transition().duration(250).style("fill-opacity",1)})),l.on("mouseout",(function(){c.transition().duration(250).style("fill-opacity",.75)})),o.reposition()},this.geoOn(i.resize,(function(){o.draw()}))};i(a,r),o("dom","legend",a),t.exports=a},2894:function(t,e,n){var r=n(5616),i=n(4626),o=n(7854),a=n(1098).registerWidget;n(615);var s=function(t){"use strict";if(!(this instanceof s))return new s(t);o.call(this,t);var e=n(6409),i=n(5325),a=n(642),u=n(2493).d3,l=this,c=this._exit,f=Object.assign({},{scale:1,maxWidth:200,maxHeight:"left"===t.orientation||"right"===t.orientation?200:20,orientation:"bottom",strokeWidth:2,tickLength:10,units:"si",distance:function(t,e,n){return"+proj=longlat +axis=enu"===n?Math.sqrt(a.distance2dSquared(t,e)):i.sphericalDistance(t,e,n)}},t);this._init=function(){return l._createCanvas(),l._appendCanvasToParent(),l.reposition(),u.select(l.canvas()).attr("width",f.maxWidth).attr("height",f.maxHeight),l.geoOn(e.pan,l._update),l._render(),l},this._exit=function(){l.geoOff(e.pan,l._update),c()},this._vertical=function(){return"left"===f.orientation||"right"===f.orientation},this._scaleValue=function(t,e,n){var r,i,o,a=[{multiple:1,digits:1},{multiple:1.5,digits:2},{multiple:2,digits:1},{multiple:3,digits:1},{multiple:5,digits:1},{multiple:8,digits:1}],u=(n=s.unitsTable[n]||n||s.unitsTable[f.units]||f.units)[0];return n.forEach((function(e){t>=e.scale*(e.minimum||1)&&(u=e)})),i=Math.floor(Math.log(t/u.scale)/Math.log(u.basis||10)),(a=u.multiples||a).forEach((function(e){var n=u.scale*e.multiple*Math.pow(10,i);n<=t&&(r=e,o=n)})),{html:(r.multiple*Math.pow(10,i)).toFixed(Math.max(0,-i+r.digits-1))+" "+u.unit,value:o,pixels:o/t*e,power:i,multiple:r,unitRecord:u,originalValue:t,originalPixels:e}},this._render=function(){var t,e,n,i,o,a,s=u.select(l.canvas()),c=l.layer().map(),h=f.maxWidth,d=f.maxHeight,p=f.strokeWidth,m=.5*p,g=f.tickLength,y=l._vertical();if(t=(y?f.maxHeight:f.maxWidth)-p,n={x:(e={x:(e=r(s.node()).offset()).left+("left"===f.orientation?h-m:m),y:e.top+("top"===f.orientation?d-m:m)}).x+(y?0:t),y:e.y+(y?t:0)},(i=f.distance(c.displayToGcs(e,null),c.displayToGcs(n,null),c.gcs())*f.scale)<=0||!isFinite(i))console.warn("The distance calculated for the scale is invalid: "+i);else{switch(o=l._scaleValue(i,t),y?d=o.pixels+p:h=o.pixels+p,s.attr("width",h).attr("height",d),s.select("polyline").empty()&&s.append("polyline").classed("geojs-scale-widget-bar",!0).attr("fill","none").attr("stroke-width",p),s.select("text").empty()&&s.append("text").classed("geojs-scale-widget-text",!0),f.orientation){case"bottom":a=[[m,g],[m,m],[h-m,m],[h-m,g]],s.select("text").attr("x",h/2).attr("y",2*p).attr("text-anchor","middle").attr("dominant-baseline","hanging");break;case"top":a=[[m,d-g],[m,d-m],[h-m,d-m],[h-m,d-g]],s.select("text").attr("x",h/2).attr("y",d-2*p).attr("text-anchor","middle").attr("dominant-baseline","alphabetic");break;case"left":a=[[h-g,m],[h-m,m],[h-m,d-m],[h-g,d-m]],s.select("text").attr("x",h-2*p).attr("y",d/2).attr("text-anchor","end").attr("dominant-baseline","middle");break;case"right":a=[[g,m],[m,m],[m,d-m],[g,d-m]],s.select("text").attr("x",2*p).attr("y",d/2).attr("text-anchor","start").attr("dominant-baseline","middle")}s.select("polyline").attr("points",a.map((function(t){return t.join(",")})).join(" ")),s.select("text").html(o.html)}},this._update=function(){l._render()},this.options=function(t,e){if(void 0===t){var n=Object.assign({},f);return n.position=l.position(void 0,!0),n}return"string"==typeof t&&void 0===e?"position"===t?l.position(void 0,!0):f[t]:(void 0===e?f=a.deepMerge(f,t):f[t]=e,(t.position||"position"===t)&&l.position(t.position||e),l._render(),l)}};i(s,o),s.unitsTable={si:[{unit:"nm",scale:1e-9},{unit:"μm",scale:1e-6},{unit:"mm",scale:.001},{unit:"m",scale:1},{unit:"km",scale:1e3}],miles:[{unit:"in",scale:.0254},{unit:"in",scale:.0254,basis:12,multiples:[{multiple:1,digits:1},{multiple:1.5,digits:2},{multiple:2,digits:1},{multiple:3,digits:1},{multiple:6,digits:1},{multiple:9,digits:1}]},{unit:"ft",scale:.3048},{unit:"mi",scale:1609.344}],decmiles:[{unit:"mi",scale:1609.344}]},s.areaUnitsTable={si:[{unit:"nm²",scale:1e-18},{unit:"μm²",scale:1e-12},{unit:"mm²",scale:1e-6},{unit:"m²",scale:1},{unit:"km²",scale:1e6}],hectares:[{unit:"ha",scale:1e4}],decmiles:[{unit:"mi²",scale:2589988.110336}],miles:[{unit:"in²",scale:64516e-8},{unit:"ft²",scale:.09290304},{unit:"mi²",scale:2589988.110336}],acres:[{unit:"pl",scale:25.29285264},{unit:"rd",scale:1011.7141056},{unit:"ac",scale:4046.8564224}]},s.formatUnit=function(t,e,n,r){if(null!=t){if(!Array.isArray(e)){if(!(n=n||s.unitsTable)||!n[e||"si"])return;e=n[e||"si"]}var i;for(i=0;i<e.length-1&&!(t<e[i+1].scale);i+=1);if(t/=(e=e[i]).scale,!((r=Math.max(0,-Math.ceil(Math.log10(t))+(void 0===r||r<0?3:r)))>10)){var o=t.toFixed(r);if(r){for(;"0"===o.substr(o.length-1);)o=o.substr(0,o.length-1);"."===o.substr(o.length-1)&&(o=o.substr(0,o.length-1))}return o+" "+e.unit}}},a("dom","scale",s),t.exports=s},3019:function(t,e,n){var r=n(7854),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e,i,o,s,u,l,c,f=n(2493).d3,h=n(6409),d=this,p=this._exit,m=t.width||20,g=t.height||160,y=t.width?.5*t.width:10;function v(t,e,n,r,i){var o=e.append("g"),a=i/1024;return o.append("g").append("g").attr("transform","translate("+n+","+r+") scale("+a+") translate(-512,-512)").append("path").attr("d",t).attr("class","geo-glyphicon"),o}c={white:"#f4f4f4",black:"#505050"},this.size=function(){return{width:m,height:g}},this._init=function(){d._createCanvas(),d._appendCanvasToParent(),d.reposition();var t=f.select(d.canvas()),n=d.layer().map();function r(e,r){var o=i.invert(f.pointer(event,t.node())[1]),a=n.zoomRange();o=(1-o)*(a.max-a.min)+a.min,r?n.transition({zoom:o,ease:f.easeCubicInOut,duration:500,done:d._update()}):(n.zoom(o),d._update()),e.stopPropagation()}function a(){f.select(this).attr("filter",null),l.selectAll("circle,rect,path").transition().duration(100).style("fill",(function(t){return c[t.fill]||null})).style("stroke",(function(t){return c[t.stroke]||null}))}return t.attr("width",m).attr("height",g),e=f.scaleLinear().domain([-4,4]).range([0,m]),i=f.scaleLinear().domain([0,1]).range([1.5*m,g-1.5*m]),t=t.append("g").classed("geo-ui-slider",!0),l=t,(o=t.append("g")).append("circle").datum({fill:"white",stroke:null}).classed("geo-zoom-in",!0).attr("cx",e(0)).attr("cy",i(0)-m+2).attr("r",(m-2)/2).style("cursor","pointer").on("click",(function(){var t=n.zoom();n.transition({zoom:t+1,ease:f.easeCubicInOut,duration:500})})).on("mousedown",(function(t){t.stopPropagation()})),v("M512 81.92c-237.568 0-430.080 192.614-430.080 430.080 0 237.568 192.563 430.080 430.080 430.080s430.080-192.563 430.080-430.080c0-237.517-192.563-430.080-430.080-430.080zM564.326 564.326v206.182h-104.653v-206.182h-206.234v-104.653h206.182v-206.234h104.704v206.182h206.182v104.704h-206.182z",o,e(0),i(0)-m+2,m+4).style("cursor","pointer").style("pointer-events","none").select("path").datum({fill:"black",stroke:null}),(s=t.append("g")).append("circle").datum({fill:"white",stroke:null}).classed("geo-zoom-out",!0).attr("cx",e(0)).attr("cy",i(1)+m-2).attr("r",(m-2)/2).style("cursor","pointer").on("click",(function(){var t=n.zoom();n.transition({zoom:t-1,ease:f.easeCubicInOut,duration:500})})).on("mousedown",(function(t){t.stopPropagation()})),v("M512 81.92c-237.568 0-430.080 192.614-430.080 430.080 0 237.568 192.563 430.080 430.080 430.080s430.080-192.563 430.080-430.080c0-237.517-192.563-430.080-430.080-430.080zM770.56 459.674v104.704h-517.12v-104.704h517.12z",s,e(0),i(1)+m-2,m+4).style("cursor","pointer").style("pointer-events","none").select("path").datum({fill:"black",stroke:null}),t.append("rect").datum({fill:"white",stroke:"black"}).classed("geo-zoom-track",!0).attr("x",e(0)-m/6).attr("y",i(0)).attr("rx",m/10).attr("ry",m/10).attr("width",m/3).attr("height",g-3*m).style("cursor","pointer").on("click",(function(t){r(t,!0)})),u=t.append("rect").datum({fill:"black",stroke:null}).classed("geo-zoom-nub",!0).attr("x",e(-4)).attr("y",i(.5)-y/2).attr("rx",3).attr("ry",3).attr("width",m).attr("height",y).style("cursor","pointer").on("mousedown",(function(t){f.select(document).on("mousemove.geo.slider",(function(){r(t)})),f.select(document).on("mouseup.geo.slider",(function(){r(t),f.select(document).on(".geo.slider",null)})),t.stopPropagation()})),l.selectAll("*").on("mouseover",(function(){f.select(this).attr("filter","url(#geo-highlight)"),l.selectAll("rect,path,circle").transition().duration(100).style("fill",(function(t){return t.fill||null})).style("stroke",(function(t){return t.stroke||null}))})).on("mouseout",a),d.geoOn(h.zoom,d._update),a(),d._update(),d},this._exit=function(){d.geoOff(h.zoom,d._update),l.remove(),p()},this._update=function(t){var e=d.layer().map(),n=e.zoomRange(),r=e.zoom(),o=f.scaleLinear();r=(t=t||{}).value||r,o.domain([n.min,n.max]).range([1,0]).clamp(!0),u.attr("y",i(o(r))-y/2)}};i(a,r),o("dom","slider",a),t.exports=a},7854:function(t,e,n){var r=n(8738),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=n(2493),i=this,o=this._exit,s=null;return this._init=function(){var e;return t.hasOwnProperty("parent")&&(t.parent.addChild(i),e=t.parent.canvas()),i._createCanvas(e),i.canvas().addEventListener("mousedown",(function(t){t.stopPropagation()})),i.reposition(),i},this._exit=function(){s&&s._exit(),o()},this._createCanvas=function(t){var n={layer:i.layer(),widget:!0};t&&(n.d3Parent=t),(s=e(n))._resize=function(){},i.canvas(s.canvas().node())},this};i(a,r),o("dom","svg",a),t.exports=a},4231:function(t,e,n){var r=n(4626),i=n(1098).registerLayer,o=n(5156),a=function(t){"use strict";var e=n(1098).createWidget;if(t.renderer="dom",t.sticky=!1,!(this instanceof a))return new a(t);o.call(this,t);var r=this,i=this._exit;this.createWidget=function(t,n){var i=e(t,r,n);return n&&"parent"in n||r.addChild(i),i._init(n),r.modified(),i},this.deleteWidget=function(t){return t._exit(),r.removeChild(t),r.modified(),r},this._exit=function(){r.children().forEach((function(t){r.deleteWidget(t)})),i()}};r(a,o),i("ui",a),t.exports=a},8738:function(t,e,n){var r=n(4626),i=n(5402),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=n(6409),r=this,a=this._exit,s=t.layer,u=null,l=void 0===t.position?{left:0,top:0}:t.position;if(!(void 0===t.parent||t.parent instanceof o))throw new Error("Parent must be of type geo.gui.widget");t.parent&&r.parent(t.parent),this._init=function(){return r.modified(),r},this._exit=function(){if(r.children().forEach((function(t){r.removeChild(t),t._exit()})),r.layer().geoOff(e.pan,r.repositionEvent),r.parentCanvas().removeChild&&r.canvas())try{r.parentCanvas().removeChild(r.canvas())}catch(t){}a()},this.layer=function(){return s||r.parent()&&r.parent().layer()},this._createCanvas=function(){throw new Error("Must be defined in derived classes")},this.canvas=function(t){return void 0===t?u:(u=t,r)},this._appendCanvasToParent=function(){r.parentCanvas().appendChild(r.canvas())},this.parentCanvas=function(){return r.parent()?r.parent().canvas():r.layer().canvas()},this.position=function(t,n){if(void 0!==t){r.layer().geoOff(e.pan,r.repositionEvent);var i={};for(var o in l)l.hasOwnProperty(o)&&(i[o]=null);return(l=t).hasOwnProperty("x")&&l.hasOwnProperty("y")&&r.layer().geoOn(e.pan,r.repositionEvent),r.reposition(Object.assign(i,r.position())),r}if(l.hasOwnProperty("x")&&l.hasOwnProperty("y")&&!n){var a=r.layer().map().gcsToDisplay(l);return{left:a.x,top:a.y,right:null,bottom:null}}return l},this.reposition=function(t){if(t=t||r.position(),r.canvas()&&r.canvas().style)for(var e in r.canvas().style.position="absolute",t)t.hasOwnProperty(e)&&(/^\s*(-|\+)?(\d+(\.\d*)?|\d*\.\d+)([eE](-|\+)?\d+)?\s*$/.test(t[e])?r.canvas().style[e]=parseFloat(parseFloat(t[e]).toFixed(3))+"px":r.canvas().style[e]=t[e]);return r},this.repositionEvent=function(){return r.reposition()},this.isInViewport=function(){var t=r.position(),e=r.layer();return t.left>=0&&t.top>=0&&t.left<=e.width()&&t.top<=e.height()},l.hasOwnProperty("x")&&l.hasOwnProperty("y")&&this.layer().geoOn(e.pan,r.repositionEvent)};r(o,i),t.exports=o},5966:function(t,e,n){var r=n(5616);function i(t,e,n){this._group=t,this._zoom=e,this._points=[],this._clusters=[],this._count=0,this._parent=null,this._coord=null;var r=this;(n||[]).forEach((function(t){r._add(t)}))}function o(t){var e,r,o=n(7235);for(this._opts=Object.assign({maxZoom:18,radius:5},t),this._clusters={},this._points={},e=this._opts.maxZoom;e>=0;e-=1)r=this._opts.radius*Math.pow(2,-e),this._clusters[e]=new o(r),this._points[e]=new o(r);this._topClusterLevel=new i(this,-1)}i.prototype._add=function(t){var e=1;t instanceof i?(this._clusters.push(t),e=t._count):this._points.push(t),t._parent=this,this._increment(e)},i.prototype._increment=function(t){this._coord=null,this._count+=t,this._parent&&this._parent._increment(t)},i.prototype.count=function(){return this._count},i.prototype.each=function(t){var e;for(e=0;e<this._points.length;e+=1)t.call(this,this._points[e],this._zoom);for(e=0;e<this._clusters.length;e+=1)this._clusters[e].each.call(this._clusters[e],t)},i.prototype.coords=function(){var t,e={x:0,y:0};if(this._coord)return this._coord;for(t=0;t<this._points.length;t+=1)e.x+=this._points[t].x,e.y+=this._points[t].y;for(t=0;t<this._clusters.length;t+=1)e.x+=this._clusters[t].coords().x*this._clusters[t].count(),e.y+=this._clusters[t].coords().y*this._clusters[t].count();return{x:e.x/this.count(),y:e.y/this.count()}},o.prototype.addPoint=function(t){var e,n,o,a,s,u;for(e=this._opts.maxZoom;e>=0;e-=1){if(n=this._clusters[e].getNearObject(t))return void n._add(t);if(n=this._points[e].getNearObject(t)){if(o=n._parent)for(u=o._points.length-1;u>=0;u-=1)if(o._points[u]===n){o._points.splice(u,1),o._increment(-1);break}for(o||r.noop(),a=new i(this,e,[n,t]),this._clusters[e].addObject(a,a.coords()),s=a,u=e-1;u>o._zoom;u-=1)s=new i(this,u,[s]),this._clusters[u].addObject(s,s.coords());for(o._add(s),u=e;u>=0&&this._points[u].removeObject(n,n);u-=1);return}this._points[e].addObject(t,t)}this._topClusterLevel._add(t)},o.prototype.points=function(t){return t=Math.min(Math.max(Math.floor(t),0),this._opts.maxZoom-1),this._points[Math.floor(t)].contents()},o.prototype.clusters=function(t){return t=Math.min(Math.max(Math.floor(t),0),this._opts.maxZoom-1),this._clusters[Math.floor(t)].contents()},t.exports=o},5637:function(t,e,n){var r=n(1949),i=n(7715);i=i.__esModule?i.default:i;var o={maxCount:1e3,count:0,memo:{}};function a(t,e){return o.count+=1,o.count>=o.maxCount&&(o.memo={},o.count=0),o.memo[t]=e,e}var s={convertColor:function(t){if(null==t||void 0!==t.r&&void 0!==t.g&&void 0!==t.b)return t;if(void 0!==o.memo[t])return o.memo[t];var e,n=t;if("string"==typeof t){var r=t.toLowerCase();if(i.hasOwnProperty(r))t={r:i[r][0]/255,g:i[r][1]/255,b:i[r][2]/255};else if("#"===t.charAt(0))4===t.length||5===t.length?(5===t.length&&(e=parseInt(t.slice(4),16)/15),t=4352*(3840&(t=parseInt(t.slice(1,4),16)))+272*(240&t)+17*(15&t)):7!==t.length&&9!==t.length||(9===t.length&&(e=parseInt(t.slice(7),16)/255),t=parseInt(t.slice(1,7),16));else if("transparent"===r)e=t=0;else if(r.indexOf("(")>=0)for(var u=0;u<s.cssColorConversions.length;u+=1){var l=s.cssColorConversions[u].regex.exec(r);if(l)return a(n,t=s.cssColorConversions[u].process(r,l))}}return isFinite(t)&&(t={r:((16711680&t)>>16)/255,g:((65280&t)>>8)/255,b:(255&t)/255}),void 0!==e&&t&&void 0!==t.r&&(t.a=e),a(n,t)},convertColorAndOpacity:function(t,e,n){return(t=s.convertColor(t))&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b||(t=s.convertColor(n||{r:0,g:0,b:0})),t&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b||(t={r:0,g:0,b:0}),t={r:isFinite(t.r)&&t.r>=0?t.r<=1?+t.r:1:0,g:isFinite(t.g)&&t.g>=0?t.g<=1?+t.g:1:0,b:isFinite(t.b)&&t.b>=0?t.b<=1?+t.b:1:0,a:r.isNonNullFinite(t.a)&&t.a>=0&&t.a<1?+t.a:1},r.isNonNullFinite(e)&&e<1&&(t.a=e<=0?0:t.a*e),t},convertColorToHex:function(t,e){var n,r=s.convertColor(t);return n=r.r||r.g||r.b?"#"+((1<<24)+(Math.round(255*r.r)<<16)+(Math.round(255*r.g)<<8)+Math.round(255*r.b)).toString(16).slice(1):"#000000",void 0!==r.a&&e&&(r.a<1||"needed"!==e)&&(n+=(256+Math.round(255*r.a)).toString(16).slice(1)),n},convertColorToRGBA:function(t){var e=s.convertColor(t);return e||(e={r:0,g:0,b:0}),(!r.isNonNullFinite(e.a)||e.a>1)&&(e.a=1),"rgba("+Math.round(255*e.r)+", "+Math.round(255*e.g)+", "+Math.round(255*e.b)+", "+ +(+e.a).toFixed(5)+")"},cssAngleUnitsBase:{deg:360,grad:400,rad:2*Math.PI,turn:1},cssNumberRegex:"[+-]?(?:\\d+\\.?\\d*|\\.\\d+)(?:[eE][+-]?\\d+)?"};s.cssColorConversions=[{name:"rgb",regex:new RegExp("^\\s*rgba?\\(\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*,?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*,?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*([/,]?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*)?\\)\\s*$"),process:function(t,e){return t={r:Math.min(1,Math.max(0,+e[1]/(e[2]?100:255))),g:Math.min(1,Math.max(0,+e[3]/(e[4]?100:255))),b:Math.min(1,Math.max(0,+e[5]/(e[6]?100:255)))},e[7]&&(t.a=Math.min(1,Math.max(0,+e[8]/(e[9]?100:1)))),t}},{name:"hsl",regex:new RegExp("^\\s*hsla?\\(\\s*("+s.cssNumberRegex+")\\s*(deg|grad|rad|turn)?\\s*,?\\s*("+s.cssNumberRegex+")\\s*%\\s*,?\\s*("+s.cssNumberRegex+")\\s*%\\s*([/,]?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*)?\\)\\s*$"),process:function(t,e){var n=function(t,e,n){return 6*(n-=Math.floor(n))<1?t+(e-t)*n*6:6*n<3?e:6*n<4?t+(e-t)*(2/3-n)*6:t},r=+e[1]/(s.cssAngleUnitsBase[e[2]]||360),i=Math.min(1,Math.max(0,+e[3]/100)),o=Math.min(1,Math.max(0,+e[4]/100)),a=o<=.5?o*(i+1):o+i-o*i,u=2*o-a;return t={r:n(u,a,r+1/3),g:n(u,a,r),b:n(u,a,r-1/3)},e[5]&&(t.a=Math.min(1,Math.max(0,+e[6]/(e[7]?100:1)))),t}}],t.exports=s},1949:function(t,e,n){function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}var i=n(5616),o=n(1960);o=o.__esModule?o.default:o;var a,s,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",l='<svg xmlns="http://www.w3.org/2000/svg"><foreignObject width="100%" height="100%"></foreignObject></svg>',c={},f=200,h=15;function d(){var t;for(t=0;t<arguments.length;t+=1)if(isFinite(arguments[t]))return arguments[t]}var p={pointInPolygon:function(t,e,n,r){return e.outer&&(n=e.inner,e=e.outer),!(e.length<3)&&(!(r&&r.min&&r.max&&(t.x<r.min.x||t.y<r.min.y||t.x>r.max.x||t.y>r.max.y))&&p.distanceToPolygon2d(t,n?{outer:e,inner:n}:e,!0)>0)},pointToTriangleBasis2d:function(t,e,n,r){var i=n.x-e.x,o=r.x-e.x,a=n.y-e.y,s=r.y-e.y,u=t.x-e.x,l=t.y-e.y,c=i*s-o*a;if(c)return{x:(u*s-l*o)/c,y:(u*-a+l*i)/c}},isReadyImage:function(t,e){return!!(t instanceof Image&&t.complete&&t.src&&(t.naturalWidth&&t.naturalHeight||e))},isReadyVideo:function(t,e){return!!(t instanceof HTMLVideoElement&&t.src&&void 0!==t.HAVE_CURRENT_DATA&&(t.videoWidth&&t.videoHeight&&t.readyState>=t.HAVE_CURRENT_DATA||e&&t.error))},isFunction:function(t){return"function"==typeof t},ensureFunction:function(t){return p.isFunction(t)?t:function(){return t}},isNonNullFinite:function(t){return isFinite(t)&&null!==t&&!1!==t&&""!==t},randomString:function(t){var e,n,r;for(t=t||8,e="",n=0;n<t;n+=1)r=Math.floor(62*Math.random()),e+=u.substring(r,r+1);return e},normalizeCoordinates:function(t){return t=t||{},Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:{x:d(t.x,t.longitude,t.lng,t.lon,0),y:d(t.y,t.latitude,t.lat,0),z:d(t.z,t.elevation,t.elev,t.height,0)}},range:function(t,e,n){n=n||1;for(var r=[],i=t;i<=e;i+=n)r.push(i);return r},compareArrays:function(t,e){return t.length===e.length&&t.every((function(t,n){return t===e[n]}))},vec3AsArray:function(){return[0,0,0]},mat3AsArray:function(){return[1,0,0,0,1,0,0,0,1]},mat4AsArray:function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]},getGeomBuffer:function(t,e,n,r,i){r=void 0===r?.2:r,i=void 0===i?.1:i;var o=t.sourceByName(e),a=o.data(),s=Math.floor((r+1)*n);if((a=o.data())instanceof Float32Array&&(a.length===n||a.length>=n&&a.length<=s))return a;var u=n;return a instanceof Float32Array&&a.length&&n&&i>0&&(u=Math.floor((i+1)*n)),a=new Float32Array(u),o.setData(a),a},adjustActions:function(t){var e,n;for(n=0;n<t.length;n+=1){if(e=t[n],"string"===i.type(e.input)){var r={};r[e.input]=!0,e.input=r}if(e.modifiers||(e.modifiers={}),"string"===i.type(e.modifiers)){var o={};o[e.modifiers]=!0,e.modifiers=o}}},addAction:function(t,e,n){n?t.push(e):t.unshift(e),p.adjustActions(t)},hasAction:function(t,e,n,r){e&&e.action&&(n=e.name,r=e.owner,e=e.action);for(var i=0;i<t.length;i+=1)if(!(e&&t[i].action!==e||n&&t[i].name!==n||r&&t[i].owner!==r))return t[i];return null},removeAction:function(t,e,n,r){var i,o=0;do{(i=p.hasAction(t,e,n,r))&&(t.splice(t.indexOf(i),1),o+=1)}while(i);return o},actionMatch:function(t,e,n){var r;if(n.some((function(n){for(var i in n.input)if(n.input.hasOwnProperty(i)&&(!1===n.input[i]&&t[i]||n.input[i]&&!t[i]))return!1;for(var o in n.modifiers)if(n.modifiers.hasOwnProperty(o)&&(!1===n.modifiers[o]&&e[o]||n.modifiers[o]&&!e[o]))return!1;return r=n,!0})))return r},pixelCoordinateParams:function(t,e,n,r,o){var a,s,u;t&&(a=(t=i(t)).innerWidth(),s=t.innerHeight()),o=o||n,u=(r=r||e)!==e||o!==n;var l=Math.min(0,Math.floor(Math.log(Math.min((a||r)/r,(s||o)/o))/Math.log(2))),c=Math.ceil(Math.log(Math.max(e/r,n/o))/Math.log(2));return{map:{node:t,ingcs:"+proj=longlat +axis=esu",gcs:"+proj=longlat +axis=enu",maxBounds:{left:0,top:0,right:e,bottom:n},unitsPerPixel:Math.pow(2,c),center:{x:e/2,y:n/2},min:l,max:c,zoom:l,clampBoundsX:!0,clampBoundsY:!0,clampZoom:!0},layer:{maxLevel:c,minLevel:Math.min(0,c),wrapX:!1,wrapY:!1,tileOffset:function(){return{x:0,y:0}},attribution:"",tileWidth:r,tileHeight:o,tileRounding:Math.ceil,tilesAtZoom:u?function(t){var i=Math.pow(2,c-t);return{x:Math.ceil(e/r/i),y:Math.ceil(n/o/i)}}:void 0,tilesMaxBounds:u?function(t){var r=Math.pow(2,c-t);return{x:Math.floor(e/r),y:Math.floor(n/r)}}:void 0}}},centerFromPerimeter:function(t){var e,n,r,i,o,a;if(t&&t.outer&&(t=t.outer),t&&t.length){if(1===t.length)return{x:t[0].x,y:t[0].y};for(e={x:0,y:0},o=0,n=t[t.length-1],a=0;a<t.length;a+=1)r=n,n=t[a],i=Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2)),e.x+=(n.x+r.x)*i,e.y+=(n.y+r.y)*i,o+=2*i;return e.x/=o,e.y/=o,o?e:{x:n.x,y:n.y}}},distance2dSquared:function(t,e){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r},distance2dToLineSquared:function(t,e,n){var r=n.x-e.x,i=n.y-e.y,o=r*r+i*i,a=0;return o&&(a=((t.x-e.x)*r+(t.y-e.y)*i)/o,a=Math.max(0,Math.min(1,a))),p.distance2dSquared(t,{x:e.x+a*r,y:e.y+a*i})},distanceToPolygon2d:function(t,e,n){for(var r,i,o=e.outer||e,a=!1,s=0,u=o.length,l=u-1;s<u;l=s,s+=1){var c=o[s],f=o[l];c.y>t.y!=f.y>t.y&&t.x<(f.x-c.x)*(t.y-c.y)/(f.y-c.y)+c.x&&(a=!a),i=n?1:p.distance2dToLineSquared(t,c,f),(void 0===r||i<r)&&(r=i)}return e.inner&&e.inner.forEach((function(e){var i=p.distanceToPolygon2d(t,e,n);i*i<r&&(r=i*i),i>0&&(a=!a)})),(a?1:-1)*Math.sqrt(r)},triangleTwiceSignedArea2d:function(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)},crossedLineSegmentPolygon2d:function(t,e,n){var r,i,o=n.outer||n,a=o.length;for(r=0,i=a-1;r<a;i=r,r+=1)if(p.crossedLineSegments2d(t,e,o[r],o[i]))return!0;if(n.inner)for(r=0;r<n.inner.length;r+=1)if(p.crossedLineSegmentPolygon2d(t,e,n.inner[r]))return!0;return!1},crossedLineSegments2d:function(t,e,n,r){return!(t.x>n.x&&t.x>r.x&&e.x>n.x&&e.x>r.x||t.x<n.x&&t.x<r.x&&e.x<n.x&&e.x<r.x||t.y>n.y&&t.y>r.y&&e.y>n.y&&e.y>r.y||t.y<n.y&&t.y<r.y&&e.y<n.y&&e.y<r.y)&&(!(t.x===n.x&&t.y===n.y||t.x===r.x&&t.y===r.y||e.x===n.x&&e.y===n.y||e.x===r.x&&e.y===r.y)&&!(p.triangleTwiceSignedArea2d(t,e,n)*p.triangleTwiceSignedArea2d(t,e,r)>0||p.triangleTwiceSignedArea2d(n,r,t)*p.triangleTwiceSignedArea2d(n,r,e)>0))},segmentCrossesLineList2d:function(t,e,n){return n.some((function(n){return n.some((function(r,i){return!!i&&p.crossedLineSegments2d(t,e,n[i-1],r)}))}))},rdpLineSimplify:function(t,e,n,r){if(t.length<=2||e<0)return t;var i,o,a,s=-1,u=e*e;if(n){for(i=1;i<t.length;i+=1)(o=p.distance2dSquared(t[0],t[i]))>s&&(s=o,a=i);return 4*s<=u?t.slice(a,a+1):(t=t.slice(a).concat(t.slice(0,a+1)),(t=p.rdpLineSimplify(t,e,!1,r)).splice(t.length-1),t)}for(i=1;i<t.length-1;i+=1)(o=p.distance2dToLineSquared(t[i],t[0],t[t.length-1]))>s&&(s=o,a=i);if(s<=u&&(!r||!p.segmentCrossesLineList2d(t[0],t[t.length-1],r)))return[t[0],t[t.length-1]];var l=t.slice(0,a+1),c=t.slice(a),f=p.rdpLineSimplify(l,e,!1,r?r.concat([c]):null),h=p.rdpLineSimplify(c,e,!1,r?r.concat([l]):null);return f.slice(0,f.length-1).concat(h)},getMinMaxValues:function(t,e,n,r){if(t.length&&(r||!i.isNumeric(e)||!i.isNumeric(n))){var o,a,s=t[0],u=t[0];for(a=t.length-1;a>0;a-=1)(o=t[a])<s&&(s=o),o>u&&(u=o);(!i.isNumeric(e)||r&&s>e)&&(e=s),(!i.isNumeric(n)||r&&u<n)&&(n=u)}return{min:e,max:n}},wrapAngle:function(t){return(t%=2*Math.PI)<-Math.PI?t+=2*Math.PI:t>=Math.PI&&(t-=2*Math.PI),t},escapeUnicodeHTML:function(t){return t.replace(/[^- 0-9A-Za-z~`!@#$%^&*()_+={}|[\]\\:";'<>?,./]/g,(function(e,n){var r=e.charCodeAt(0);if(r<127)return e;if(r>=55296&&r<=57344){if(r<56320||n)return"";var i=t.charCodeAt(n-1);if(i<55296||i>=56320)return"";r=1024*(i-55296)+(r-56320)}return"&#"+r.toString(10)+";"}))},deepMerge:function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];for(var o=0,a=n;o<a.length;o++){var s=a[o];if(null!=s)for(var u in s)if("__proto__"!==u&&t!==s[u]){var l=s[u];if(l&&"object"===r(l)&&(l.constructor===Object||Array.isArray(l))){var c=t[u];Array.isArray(l)?Array.isArray(c)||(c=[]):("object"!==r(c)||Array.isArray(c))&&(c={}),t[u]=p.deepMerge(c,l)}else void 0!==l&&(t[u]=l)}}return t},dereferenceElements:function(t){var e=[];return i("img,image",t).each((function(){var t=i(this),n=t.is("image")?"href":"src";if(t.attr(n)){var r=new Image;("http"===t.attr(n).substr(0,4)||t[0].crossOrigin)&&(r.crossOrigin=t[0].crossOrigin||"anonymous");var o=i.Deferred();r.onload=function(){var e=document.createElement("canvas");e.width=r.naturalWidth,e.height=r.naturalHeight,e.getContext("2d").drawImage(r,0,0),t.attr(n,e.toDataURL("image/png")),"data:image"!==t.attr(n).substr(0,10)&&t.remove(),o.resolve()},r.onerror=function(){t.remove(),o.resolve()},r.src=t.attr(n),e.push(o)}})),e},dereferenceCssUrlsRegex:/url\(["']?(http[^)"']+|[^:)"']+)["']?\)/g,dereferenceCssUrls:function(t,e,n,r,o){var a=[],s=[];if(t=(t=t.replace(/\/\*[^\0]*?\*\//g,"")).replace(/\r/g,"\n").replace(/\s+\n/g,"\n").replace(/\n\s+/g,"\n").replace(/\n\n+/g,"\n"),o){var u=/(^[^?#]*)\/[^?#/]*([?#]|$)/g.exec(o);o=u&&u[1]?u[1]+"/":null}t.replace(p.dereferenceCssUrlsRegex,(function(t,e){var n=a.length,r=i.Deferred(),u=new XMLHttpRequest;return a.push(r),s.push(""),/^[^/:][^:]*(\/|$)/g.exec(e)&&o&&(e=o+e),u.open("GET",e,!0),u.responseType="arraybuffer",u.onload=function(){if(200===this.status){var t,e=new Uint8Array(this.response),i=new Array(e.length);for(t=0;t<e.length;t+=1)i[t]=String.fromCharCode(e[t]);i=i.join(""),s[n]="url(data:"+u.getResponseHeader("content-type")+";base64,"+btoa(i)+")"}r.resolve()},u.onerror=r.resolve,u.send(),t})),i.when.apply(i,a).then((function(){var i=0;t=t.replace(p.dereferenceCssUrlsRegex,(function(t,e){return s[(i+=1)-1]})),void 0===r?e.text(t):e.style[r]=t,n.resolve()}))},htmlToImageSupported:function(){if(void 0===s){var t=i.Deferred(),e=i(l);e.attr({width:"10px",height:"10px","text-rendering":"optimizeLegibility"}),i("foreignObject",e).append("<div/>");var n=new Image;return n.onload=n.onerror=function(){var e=document.createElement("canvas");e.width=10,e.height=10,e.getContext("2d").drawImage(n,0,0);try{e.toDataURL(),s=!0}catch(t){console.warn("This browser does not support converting HTML to an image via SVG foreignObject. Some functionality will be limited.",t),s=!1}t.resolve(s)},n.src="data:image/svg+xml;base64,"+btoa(p.escapeUnicodeHTML((new XMLSerializer).serializeToString(e[0]))),t}return s},htmlToImage:function(t,e){var n,r=i.Deferred(),o=[p.htmlToImageSupported()],a=i(t);for(t=i(t).clone();e&&e>0;)(a=a.parent()).is("div")&&((n=i("<div>").attr({class:a.attr("class"),id:a.attr("id")}).css({width:"100%",height:"100%",background:"none",margin:0})).append(t),t=n),e-=1;i("canvas",t).remove(),i("*",t).addBack().each((function(){for(var t=this.style,e=0;e<t.length;e+=1){var n=this.style[e];if(this.style[n].match(p.dereferenceCssUrlsRegex)){var r=i.Deferred();p.dereferenceCssUrls(this.style[n],this,r,n),o.push(r)}}})),(n=i('<div xmlns="http://www.w3.org/1999/xhtml">')).css({width:a.width()+"px",height:a.height()+"px"}),n.append(i("<head>"));var s=i("<body>");return n.append(s),s.css({width:a.width()+"px",height:a.height()+"px",background:"none",margin:0}),s.append(t),o=o.concat(p.dereferenceElements(t)),i('style,link[rel="stylesheet"]').each((function(){var t=i('<style type="text/css">'),e=i.Deferred();if(i(this).is("style")){var r=i(this).text();p.dereferenceCssUrls(r,t,e)}else{var a=i(this).attr("href");i.get(a).done((function(n){p.dereferenceCssUrls(n,t,e,void 0,a)})).fail((function(n,r,i){console.warn("Failed to dereference "+a,r,i),t.remove(),e.resolve()}))}o.push(e),i("head",n).append(t)})),i.when.apply(i,o).then((function(){var t=i(l);t.attr({width:a.width()+"px",height:a.height()+"px","text-rendering":"optimizeLegibility"}),i("foreignObject",t).append(n);var e=new Image;p.htmlToImageSupported()?(e.onload=function(){r.resolve(e)},e.onerror=function(){console.warn("Failed to render html to image"),r.reject()},e.src="data:image/svg+xml;base64,"+btoa(p.escapeUnicodeHTML((new XMLSerializer).serializeToString(t[0])))):r.resolve(e)})),r},timeReport:function(t){return i.each(c,(function(t,e){e.count?(e.stddev=Math.sqrt(Math.abs((e.sum2-e.sum*e.sum/e.count)/e.count)),e.average=e.sum/e.count):(e.stddev=0,e.average=0)})),t?c[t]:c},timeFunctionStart:function(t,e){c[t]&&!e||(c[t]={count:0,sum:0,sum2:0,max:0,recent:[]}),c[t].start=window.performance.now()},timeFunctionStop:function(t){if(c[t]&&c[t].start){var e=window.performance.now()-c[t].start;c[t].start=null,c[t].sum+=e,c[t].sum2+=e*e,c[t].count+=1,c[t].max=Math.max(c[t].max,e),c[t].recent.push(e),c[t].recent.length>f&&c[t].recent.splice(0,c[t].recent.length-f)}},timeRequestAnimationFrame:function(t,e,n,r){c.requestAnimationFrame&&!e||(c.requestAnimationFrame={count:0,sum:0,sum2:0,max:0,above_threshold:0,recent:[],recentsub:[]}),n&&(h=n),r&&(f=r),t&&a?(window.requestAnimationFrame=a,a=null):t||a||(a=window.requestAnimationFrame,window.requestAnimationFrame=function(t){return a.call(window,(function(e){var n,r=c.requestAnimationFrame;r.timestamp!==e&&(r.nowDelta=window.performance.now()-e,Math.abs(r.nowDelta)<1e3&&(r.nowDelta=0),r.timestamp=e,r.subcalls=r.subcalls||0,r.start={sum:r.sum,sum2:r.sum2,count:r.count,max:r.max,above_threshold:r.above_threshold},r.recent.push([0]),r.recentsub.push([]),r.recent.length>f&&(r.recent.splice(0,r.recent.length-f),r.recentsub.splice(0,r.recentsub.length-f))),r.subcalls+=1,t.apply(this,arguments);var i=window.performance.now()-e;i-=r.nowDelta,r.sum=r.start.sum+i,r.sum2=r.start.sum2+i*i,r.count=r.start.count+1,r.max=Math.max(r.max,i),r.above_threshold=r.start.above_threshold+(i>=h?1:0),r.recent[r.recent.length-1]=i,(n=r.recentsub[r.recent.length-1]).push({total_duration:i,duration:i-(n.length?n[n.length-1].total_duration:0),callback:t.name||t})}))})},isObject:function(t){var e=r(t);return null!=t&&("object"===e||"function"===e)},identityFunction:function(t){return t},radiusEarth:o.WGS84.a};t.exports=p},7235:function(t,e,n){var r=n(5616),i={};i.Util={stamp:function(t){return t._leaflet_id=t._leaflet_id||++i.Util.lastId,t._leaflet_id},lastId:0};var o=function(t){this._cellSize=t,this._sqCellSize=t*t,this._grid={},this._objectPoint={}};o.prototype={addObject:function(t,e){var n=this._getCoord(e.x),r=this._getCoord(e.y),o=this._grid,a=o[r]=o[r]||{},s=a[n]=a[n]||[],u=i.Util.stamp(t);e.obj=t,this._objectPoint[u]=e,s.push(t)},updateObject:function(t,e){this.removeObject(t),this.addObject(t,e)},removeObject:function(t,e){var n,r,o=this._getCoord(e.x),a=this._getCoord(e.y),s=this._grid,u=s[a]=s[a]||{},l=u[o]=u[o]||[];for(delete this._objectPoint[i.Util.stamp(t)],n=0,r=l.length;n<r;n++)if(l[n]===t)return l.splice(n,1),1===r&&delete u[o],!0},eachObject:function(t,e){var n,r,i,o,a,s,u=this._grid;for(n in u)for(r in a=u[n])for(i=0,o=(s=a[r]).length;i<o;i++)t.call(e,s[i])&&(i--,o--)},getNearObject:function(t){var e,n,r,o,a,s,u,l,c=this._getCoord(t.x),f=this._getCoord(t.y),h=this._objectPoint,d=this._sqCellSize,p=null;for(e=f-1;e<=f+1;e++)if(o=this._grid[e])for(n=c-1;n<=c+1;n++)if(a=o[n])for(r=0,s=a.length;r<s;r++)u=a[r],(l=this._sqDist(h[i.Util.stamp(u)],t))<d&&(d=l,p=u);return p},contents:function(){return r.map(this._objectPoint,(function(t){return t}))},_getCoord:function(t){return Math.floor(t/this._cellSize)},_sqDist:function(t,e){var n=e.x-t.x,r=e.y-t.y;return n*n+r*r}},t.exports=o},642:function(t,e,n){t.exports=Object.assign(n(1949),n(5637),n(208),n(269),{DistanceGrid:n(7235),ClusterGroup:n(5966),mesh:n(5905),polyops:n(5647)})},5905:function(t,e,n){t.exports={createColoredMesh:function(t,e){var r,i,o,a,s,u=n(642),l=t.mesh,c=t.style.get("value"),f={used:void 0!==t.style("used")?t.style.get("used"):function(t,e){return u.isNonNullFinite(c(t,e))},opacity:t.style.get("opacity"),value:c},h=t._createMesh(e?{}:f,e?f:{});if(h.elementValues=!!e,!h.numVertices||!h.numElements)return h;var d=l.get("stepped")(h),p=l.get("opacityRange")(h),m=l.get("rangeValues")(h);if(h.stepped=!(void 0!==d&&!d),h.colorMap=[],h.minColor=Object.assign({a:l.get("minOpacity")(h)||0},u.convertColor(l.get("minColor")(h))),h.maxColor=Object.assign({a:l.get("maxOpacity")(h)||0},u.convertColor(l.get("maxColor")(h))),l.get("colorRange")(h).forEach((function(t,e){h.colorMap.push(Object.assign({a:p&&void 0!==p[e]?p[e]:1},u.convertColor(t)))})),r=u.getMinMaxValues(h.value,l.get("min")(h),l.get("max")(h)),h.minValue=r.min,h.maxValue=r.max,m&&h.colorMap&&(m.length===h.colorMap.length+1||!d&&m.length===h.colorMap.length)||(m=null),m)for(s=1;s<m.length;s+=1)if(m[s-1]>m[s]){m=null;break}for(m&&(h.minValue=m[0],h.maxValue=m[m.length-1]),(o=h.maxValue-h.minValue)||(h.colorMap=h.colorMap.slice(0,1),o=1,m=null),h.rangeValues=m,h.factor=(h.colorMap.length-(d?0:1))/o,a=0;a<h.value.length;a+=1)if(i=h.value[a],m&&i>=h.minValue&&i<=h.maxValue){for(s=1;s<m.length;s+=1)if(i<=m[s]){h.value[a]=s-1+(i-m[s-1])/(m[s]-m[s-1]);break}}else h.value[a]=(i-h.minValue)*h.factor;return h}}},269:function(t,e,n){var r,i,o=n(7945);t.exports={},t.exports.mockWebglRenderer=function(t){"use strict";var e=n(1611);if(void 0===t&&(t=!0),e._mocked)throw new Error("webgl renderer already mocked");var a={},s=function(t){a[t]=(a[t]||0)+1},u=function(t){return function(){s(t)}},l=0,c=function(t){return function(){return s(t),l+=1}},f={activeTexture:u("activeTexture"),attachShader:u("attachShader"),bindAttribLocation:u("bindAttribLocation"),bindBuffer:u("bindBuffer"),bindFramebuffer:u("bindFramebuffer"),bindTexture:u("bindTexture"),blendFuncSeparate:u("blendFuncSeparate"),bufferData:u("bufferData"),bufferSubData:u("bufferSubData"),checkFramebufferStatus:function(t){if(s("checkFramebufferStatus"),t===e.GL.FRAMEBUFFER)return e.GL.FRAMEBUFFER_COMPLETE},clear:u("clear"),clearColor:u("clearColor"),clearDepth:u("clearDepth"),compileShader:u("compileShader"),createBuffer:c("createBuffer"),createFramebuffer:u("createFramebuffer"),createProgram:c("createProgram"),createShader:c("createShader"),createTexture:c("createTexture"),deleteBuffer:u("deleteBuffer"),deleteProgram:u("deleteProgram"),deleteShader:u("deleteShader"),deleteTexture:u("deleteTexture"),detachShader:u("detachShader"),depthFunc:u("depthFunc"),disable:u("disable"),disableVertexAttribArray:u("disableVertexAttribArray"),drawArrays:u("drawArrays"),enable:u("enable"),enableVertexAttribArray:u("enableVertexAttribArray"),finish:u("finish"),getError:u("getError"),getExtension:c("getExtension"),getParameter:function(t){switch(s("getParameter"),t){case e.GL.ALIASED_POINT_SIZE_RANGE:return[1,64];case e.GL.DEPTH_BITS:return 16;case e.GL.MAX_TEXTURE_SIZE:return 4096}},getProgramParameter:function(t,n){if(s("getProgramParameter"),n===e.GL.LINK_STATUS)return!0},getShaderInfoLog:function(){return s("getShaderInfoLog"),"log"},getShaderParameter:function(t,n){if(s("getShaderParameter"),n===e.GL.COMPILE_STATUS)return!0},getSupportedExtensions:function(){return s("getSupportedExtensions"),[]},getUniformLocation:c("getUniformLocation"),isEnabled:function(t){if(s("isEnabled"),t===e.GL.BLEND)return!0},linkProgram:u("linkProgram"),pixelStorei:u("pixelStorei"),shaderSource:u("shaderSource"),texImage2D:u("texImage2D"),texParameteri:u("texParameteri"),uniform1iv:u("uniform1iv"),uniform1fv:u("uniform1fv"),uniform2fv:u("uniform2fv"),uniform3fv:u("uniform3fv"),uniform4fv:u("uniform4fv"),uniformMatrix3fv:u("uniformMatrix3fv"),uniformMatrix4fv:u("uniformMatrix4fv"),useProgram:u("useProgram"),vertexAttribPointer:u("vertexAttribPointer"),vertexAttrib3fv:u("vertexAttrib3fv"),viewport:u("viewport")};r=e.renderWindow;var h=function(){e.renderWindow=r;var t,n=new e.renderWindow;return e.renderWindow=h,n._setup=function(){var r,i=n.renderers(),o=n.windowSize(),a=n.windowPosition();for(t=Object.assign({},e.GL,f),r=0;r<i.length;r+=1)(i[r].width()>o[0]||0===i[r].width()||i[r].height()>o[1]||0===i[r].height())&&i[r].resize(a[0],a[1],o[0],o[1]);return!0},n.context=function(){return t},n};e.renderWindow=h,i=o.supported,o.supported=function(){return!!t},o._maxTextureSize=4096,o._maxPointSize=64,e._mocked=!0,e.mockCounts=function(){return a}},t.exports.restoreWebglRenderer=function(){var t=n(1611);t._mocked&&(t.renderWindow=r,o.supported=i,delete t._mocked,delete t.mockCounts)}},5647:function(t,e,n){function r(t){return function(t){if(Array.isArray(t))return i(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return i(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var o=n(6820),a=n(6211),s=n(1949),u={"+":"union","|":"union",add:"union","-":"difference",sub:"difference",subtract:"difference",minus:"difference","*":"intersect","&":"intersect",mul:"intersect",multiply:"intersect",x:"xor","^":"xor"};function l(t,e,n){for(t="select"+t.charAt(0).toUpperCase()+t.slice(1),o.epsilon(e);n.length>1;){for(var r=[],i=Math.ceil(n.length/2),a=0;a<i;a+=1){var s=n[a];if(a+i<n.length){var u=n[a+i];try{s=o.combine(s,u)}catch(t){s=o.segments(o.polygon(s)),u=o.segments(o.polygon(u));for(var l=20;l>=6;l-=1){o.epsilon(Math.pow(.1,l));try{s=o.combine(s,u);break}catch(t){}}o.epsilon(e)}s.combined?(s.combined=s.combined.filter((function(t){return Math.abs(t.start[0]-t.end[0])>e||Math.abs(t.start[1]-t.end[1])>e})),s=o[t](s)):console.warn("Failed in polygon functions."),s.segments=s.segments.filter((function(t){return Math.abs(t.start[0]-t.end[0])>e||Math.abs(t.start[1]-t.end[1])>e}))}r.push(s)}n=r}return n}function c(t,e,n){if(e=e||{},t.toPolygonList){if(e.style=t,!(t=t.toPolygonList(n)).length)return e.min=e.max=[0,0],e.epsilon=1e-10,t}else{if(e.style="",t.outer?(e.style="-outer",t=[[t.outer].concat(r(t.inner||[]))]):t.length&&t[0].outer&&(e.style="-outer-list",t=t.map((function(t){return[t.outer].concat(r(t.inner||[]))}))),!t.length)return e.style="flat-listlist"+e.style,e.min=e.max=[0,0],e.epsilon=1e-10,t;void 0!==t[0].x?(e.style="object",t=[[t.map((function(t){return[t.x,t.y]}))]]):void 0!==t[0][0].x?(e.style="object-list"+e.style,t=[t.map((function(t){return t.map((function(t){return[t.x,t.y]}))}))]):void 0===t[0][0][0]?(e.style="flat",t=[[t]]):void 0!==t[0][0][0].x?(e.style="object-listlist"+e.style,t=t.map((function(t){return t.map((function(t){return t.map((function(t){return[t.x,t.y]}))}))}))):void 0===t[0][0][0][0]?(e.style="flat-list",t=[t]):e.style="flat-listlist"+e.style}return e.min=[t[0][0][0][0],t[0][0][0][1]],e.max=[t[0][0][0][0],t[0][0][0][1]],t.forEach((function(t){return t.forEach((function(t){return t.forEach((function(t){t[0]<e.min[0]&&(e.min[0]=t[0]),t[0]>e.max[0]&&(e.max[0]=t[0]),t[1]<e.min[1]&&(e.min[1]=t[1]),t[1]>e.max[1]&&(e.max[1]=t[1])}))}))})),e.epsilon=1e-10*Math.max(Math.max(e.max[0],e.max[1]),Math.max(Math.abs(e.min[0]),Math.abs(e.min[1]))),t}function f(t,e,n){return e.style.fromPolygonList?e.style.fromPolygonList(t,n):(e.style.includes("object")&&(t=t.map((function(t){return t.map((function(t){return t.map((function(t){return{x:t[0],y:t[1]}}))}))}))),e.style.includes("outer")&&(t=[t.map((function(t){return{outer:t[0],inner:t.slice(1)}}))]),e.style.endsWith("listlist")||(t=e.style.endsWith("list")?t[0]:t[0][0]),t)}function h(t,e,r,i){var h=n(5325);t=u[t]||t,e.poly1&&(e=(i=e).poly1,r=i.poly2);var d=(i=i||{}).ingcs||(i.map?i.map.ingcs():e.gcs?e.gcs():e.layer&&e.layer().gcs?e.layer().gcs():e.layer?e.layer().map().ingcs():e.map instanceof a?e.map().ingcs():void 0),p=i.ingcs||(i.map?i.map.ingcs():r.gcs?r.gcs():r.layer&&r.layer().gcs?r.layer().gcs():r.layer?r.layer().map().ingcs():r.map instanceof a?r.map().ingcs():d),m=i.gcs||(i.map?i.map.gcs():e.layer?e.layer().map().gcs():e.map instanceof a?e.map().gcs():void 0),g={},y={};e=c(e,g,i),r=c(r,y,i),g.epsilon=i.epsilon1||g.epsilon,y.epsilon=i.epsilon2||g.epsilon,d&&m&&d!==m&&(e=e.map((function(t){return t.map((function(t){return h.transformCoordinates(d,m,t)}))}))),p&&m&&p!==m&&(r=r.map((function(t){return t.map((function(t){return h.transformCoordinates(p,m,t)}))})));var v=e.map((function(t){return o.segments({regions:t})})),x=r.map((function(t){return o.segments({regions:t})}));v=l(i.innerOperation||"union",g.epsilon,v),x=l(i.innerOperation||"union",y.epsilon,x);var _=v;v[0]&&x[0]?(v[0].inverted=!1,x[0].inverted=!1,_=l(t,Math.max(g.epsilon,y.epsilon),[v[0],x[0]])):x[0]&&(_=x);var b,w,M=function(t){var e=[],n=[],r=[],i=[];t.forEach((function(t){return o.polygon(t).regions.forEach((function(t){var e=t.map((function(t){return{x:t[0],y:t[1]}}));e.length<3||(i.push([]),n.forEach((function(t,r){s.pointInPolygon(e[0],t)?i[n.length].push(r):s.pointInPolygon(t[0],e)&&i[r].push(n.length)})),r.push(t),n.push(e))}))}));for(var a=Array(r.length),u=0;u<r.length;){for(var l=0;l<r.length;l+=1)void 0!==a[l]||i[l].length||(a[l]=e.length,e.push([r[l].reverse()]),u+=1);for(var c=0;c<r.length;c+=1)void 0===a[c]&&1===i[c].length&&void 0!==a[i[c][0]]&&(e[a[i[c][0]]].push(r[c]),a[c]=a[i[c][0]],u+=1);for(var f=0;f<r.length;f+=1)i[f]=i[f].filter((function(t){return void 0===a[t]}))}return e.length?e:[[]]}(_);return i.correspond&&function(t,e,n,r){var i={},o=[];n.forEach((function(t,e){return t.forEach((function(t){return t.forEach((function(t){var n="_"+t[0]+"_"+t[1];i[n]?-1===i[n].indexOf(e)&&i[n].push(e):i[n]=[e],o.length<=e&&o.push(0),o[e]+=1}))}))})),["poly1","poly2"].forEach((function(a){var s="poly1"===a?t:e,u="poly1"===a?"exact1":"exact2";r[a]=Array(s.length),r[u]=Array(s.length),s.forEach((function(t,e){var s={},l=0;t.forEach((function(t){return t.forEach((function(t){var e="_"+t[0]+"_"+t[1];i[e]?i[e].forEach((function(t){s[t]=(s[t]||0)+1})):l+=1}))})),Object.keys(s).forEach((function(i){s[i]!==o[+i]||l||t.length!==n[+i].length||(r[u][e]||(r[u][e]=[]),r[u][e].push(+i)),s[i]>=2&&(r[a][e]||(r[a][e]=[]),r[a][e].push(+i))}))}))}))}(e,r,M,i.correspond),d&&m&&d!==m&&(M=M.map((function(t){return t.map((function(t){return h.transformCoordinates(m,d,t)}))}))),f(M,{style:i.style||(b=M,w=g.style,w.fromPolygonList?w:b.length>1?w.includes("outer")?w+(w.endsWith("list")?"":"-list"):w.endsWith("listlist")?w:w+(w.endsWith("list")?"list":"-listlist"):1===b.length&&b[0].length>1?w.includes("outer")||w.endsWith("list")?w:w+"-list":w)},i)}function d(t){return function(e,n,r){return h(t,e,n,r)}}t.exports={union:d("union"),intersect:d("intersect"),difference:d("difference"),xor:d("xor"),toPolygonList:c,fromPolygonList:f}},208:function(t){var e=function(t,e,n,r,i){var o,a=0;return"boolean"!=typeof e&&(i=r,r=n,n=e,e=void 0),"function"!=typeof r&&(i=r,r=function(){}),function(){var s=this,u=+new Date-a,l=arguments;function c(){a=+new Date,n.apply(s,l)}r.apply(s,l),i&&!o&&c(),o&&clearTimeout(o),void 0===i&&u>t?c():!0!==e&&(o=setTimeout(i?function(){o=void 0}:c,void 0===i?t-u:t))}};t.exports={throttle:e,debounce:function(t,n,r,i){return"boolean"!=typeof n&&(i=r,r=n,n=!1),e(t,!1,r,i=i||function(){},!!n)}}},6858:function(t,e,n){var r=n(4626),i=n(1275),o=n(642),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},i.call(this,t);var e=this,n=this._init;this.featureType="vector",this.origin=function(t){return void 0===t?e.style("origin"):(e.style("origin",t),e.dataTime().modified(),e)},this.delta=function(t){return void 0===t?e.style("delta"):(e.style("delta",t),e.dataTime().modified(),e)},this._init=function(t){n.call(e,t);var r=Object.assign({},{strokeColor:"black",strokeWidth:2,strokeOpacity:1,originStyle:"none",endStyle:"arrow",origin:{x:0,y:0,z:0},delta:o.identityFunction,scale:null},void 0===t.style?{}:t.style);return void 0!==t.origin&&(r.origin=t.origin),e.style(r),e.dataTime().modified(),e}};r(a,i),t.exports=a},4081:function(t){t.exports="1.14.1"},6552:function(t,e,n){n(698).GL={ACTIVE_ATTRIBUTES:35721,ACTIVE_TEXTURE:34016,ACTIVE_UNIFORMS:35718,ALIASED_LINE_WIDTH_RANGE:33902,ALIASED_POINT_SIZE_RANGE:33901,ALPHA:6406,ALPHA_BITS:3413,ALWAYS:519,ARRAY_BUFFER:34962,ARRAY_BUFFER_BINDING:34964,ATTACHED_SHADERS:35717,BACK:1029,BLEND:3042,BLEND_COLOR:32773,BLEND_DST_ALPHA:32970,BLEND_DST_RGB:32968,BLEND_EQUATION:32777,BLEND_EQUATION_ALPHA:34877,BLEND_EQUATION_RGB:32777,BLEND_SRC_ALPHA:32971,BLEND_SRC_RGB:32969,BLUE_BITS:3412,BOOL:35670,BOOL_VEC2:35671,BOOL_VEC3:35672,BOOL_VEC4:35673,BROWSER_DEFAULT_WEBGL:37444,BUFFER_SIZE:34660,BUFFER_USAGE:34661,BYTE:5120,CCW:2305,CLAMP_TO_EDGE:33071,COLOR_ATTACHMENT0:36064,COLOR_BUFFER_BIT:16384,COLOR_CLEAR_VALUE:3106,COLOR_WRITEMASK:3107,COMPILE_STATUS:35713,COMPRESSED_TEXTURE_FORMATS:34467,CONSTANT_ALPHA:32771,CONSTANT_COLOR:32769,CONTEXT_LOST_WEBGL:37442,CULL_FACE:2884,CULL_FACE_MODE:2885,CURRENT_PROGRAM:35725,CURRENT_VERTEX_ATTRIB:34342,CW:2304,DECR:7683,DECR_WRAP:34056,DELETE_STATUS:35712,DEPTH_ATTACHMENT:36096,DEPTH_BITS:3414,DEPTH_BUFFER_BIT:256,DEPTH_CLEAR_VALUE:2931,DEPTH_COMPONENT:6402,DEPTH_COMPONENT16:33189,DEPTH_FUNC:2932,DEPTH_RANGE:2928,DEPTH_STENCIL:34041,DEPTH_STENCIL_ATTACHMENT:33306,DEPTH_TEST:2929,DEPTH_WRITEMASK:2930,DITHER:3024,DONT_CARE:4352,DST_ALPHA:772,DST_COLOR:774,DYNAMIC_DRAW:35048,ELEMENT_ARRAY_BUFFER:34963,ELEMENT_ARRAY_BUFFER_BINDING:34965,EQUAL:514,FASTEST:4353,FLOAT:5126,FLOAT_MAT2:35674,FLOAT_MAT3:35675,FLOAT_MAT4:35676,FLOAT_VEC2:35664,FLOAT_VEC3:35665,FLOAT_VEC4:35666,FRAGMENT_SHADER:35632,FRAMEBUFFER:36160,FRAMEBUFFER_ATTACHMENT_OBJECT_NAME:36049,FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE:36048,FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE:36051,FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL:36050,FRAMEBUFFER_BINDING:36006,FRAMEBUFFER_COMPLETE:36053,FRAMEBUFFER_INCOMPLETE_ATTACHMENT:36054,FRAMEBUFFER_INCOMPLETE_DIMENSIONS:36057,FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:36055,FRAMEBUFFER_UNSUPPORTED:36061,FRONT:1028,FRONT_AND_BACK:1032,FRONT_FACE:2886,FUNC_ADD:32774,FUNC_REVERSE_SUBTRACT:32779,FUNC_SUBTRACT:32778,GENERATE_MIPMAP_HINT:33170,GEQUAL:518,GREATER:516,GREEN_BITS:3411,HIGH_FLOAT:36338,HIGH_INT:36341,INCR:7682,INCR_WRAP:34055,INT:5124,INT_VEC2:35667,INT_VEC3:35668,INT_VEC4:35669,INVALID_ENUM:1280,INVALID_FRAMEBUFFER_OPERATION:1286,INVALID_OPERATION:1282,INVALID_VALUE:1281,INVERT:5386,KEEP:7680,LEQUAL:515,LESS:513,LINEAR:9729,LINEAR_MIPMAP_LINEAR:9987,LINEAR_MIPMAP_NEAREST:9985,LINES:1,LINE_LOOP:2,LINE_STRIP:3,LINE_WIDTH:2849,LINK_STATUS:35714,LOW_FLOAT:36336,LOW_INT:36339,LUMINANCE:6409,LUMINANCE_ALPHA:6410,MAX_COMBINED_TEXTURE_IMAGE_UNITS:35661,MAX_CUBE_MAP_TEXTURE_SIZE:34076,MAX_FRAGMENT_UNIFORM_VECTORS:36349,MAX_RENDERBUFFER_SIZE:34024,MAX_TEXTURE_IMAGE_UNITS:34930,MAX_TEXTURE_SIZE:3379,MAX_VARYING_VECTORS:36348,MAX_VERTEX_ATTRIBS:34921,MAX_VERTEX_TEXTURE_IMAGE_UNITS:35660,MAX_VERTEX_UNIFORM_VECTORS:36347,MAX_VIEWPORT_DIMS:3386,MEDIUM_FLOAT:36337,MEDIUM_INT:36340,MIRRORED_REPEAT:33648,NEAREST:9728,NEAREST_MIPMAP_LINEAR:9986,NEAREST_MIPMAP_NEAREST:9984,NEVER:512,NICEST:4354,NONE:0,NOTEQUAL:517,NO_ERROR:0,ONE:1,ONE_MINUS_CONSTANT_ALPHA:32772,ONE_MINUS_CONSTANT_COLOR:32770,ONE_MINUS_DST_ALPHA:773,ONE_MINUS_DST_COLOR:775,ONE_MINUS_SRC_ALPHA:771,ONE_MINUS_SRC_COLOR:769,OUT_OF_MEMORY:1285,PACK_ALIGNMENT:3333,POINTS:0,POLYGON_OFFSET_FACTOR:32824,POLYGON_OFFSET_FILL:32823,POLYGON_OFFSET_UNITS:10752,RED_BITS:3410,RENDERBUFFER:36161,RENDERBUFFER_ALPHA_SIZE:36179,RENDERBUFFER_BINDING:36007,RENDERBUFFER_BLUE_SIZE:36178,RENDERBUFFER_DEPTH_SIZE:36180,RENDERBUFFER_GREEN_SIZE:36177,RENDERBUFFER_HEIGHT:36163,RENDERBUFFER_INTERNAL_FORMAT:36164,RENDERBUFFER_RED_SIZE:36176,RENDERBUFFER_STENCIL_SIZE:36181,RENDERBUFFER_WIDTH:36162,RENDERER:7937,REPEAT:10497,REPLACE:7681,RGB:6407,RGB565:36194,RGB5_A1:32855,RGBA:6408,RGBA4:32854,SAMPLER_2D:35678,SAMPLER_CUBE:35680,SAMPLES:32937,SAMPLE_ALPHA_TO_COVERAGE:32926,SAMPLE_BUFFERS:32936,SAMPLE_COVERAGE:32928,SAMPLE_COVERAGE_INVERT:32939,SAMPLE_COVERAGE_VALUE:32938,SCISSOR_BOX:3088,SCISSOR_TEST:3089,SHADER_TYPE:35663,SHADING_LANGUAGE_VERSION:35724,SHORT:5122,SRC_ALPHA:770,SRC_ALPHA_SATURATE:776,SRC_COLOR:768,STATIC_DRAW:35044,STENCIL_ATTACHMENT:36128,STENCIL_BACK_FAIL:34817,STENCIL_BACK_FUNC:34816,STENCIL_BACK_PASS_DEPTH_FAIL:34818,STENCIL_BACK_PASS_DEPTH_PASS:34819,STENCIL_BACK_REF:36003,STENCIL_BACK_VALUE_MASK:36004,STENCIL_BACK_WRITEMASK:36005,STENCIL_BITS:3415,STENCIL_BUFFER_BIT:1024,STENCIL_CLEAR_VALUE:2961,STENCIL_FAIL:2964,STENCIL_FUNC:2962,STENCIL_INDEX:6401,STENCIL_INDEX8:36168,STENCIL_PASS_DEPTH_FAIL:2965,STENCIL_PASS_DEPTH_PASS:2966,STENCIL_REF:2967,STENCIL_TEST:2960,STENCIL_VALUE_MASK:2963,STENCIL_WRITEMASK:2968,STREAM_DRAW:35040,SUBPIXEL_BITS:3408,TEXTURE:5890,TEXTURE0:33984,TEXTURE1:33985,TEXTURE10:33994,TEXTURE11:33995,TEXTURE12:33996,TEXTURE13:33997,TEXTURE14:33998,TEXTURE15:33999,TEXTURE16:34e3,TEXTURE17:34001,TEXTURE18:34002,TEXTURE19:34003,TEXTURE2:33986,TEXTURE20:34004,TEXTURE21:34005,TEXTURE22:34006,TEXTURE23:34007,TEXTURE24:34008,TEXTURE25:34009,TEXTURE26:34010,TEXTURE27:34011,TEXTURE28:34012,TEXTURE29:34013,TEXTURE3:33987,TEXTURE30:34014,TEXTURE31:34015,TEXTURE4:33988,TEXTURE5:33989,TEXTURE6:33990,TEXTURE7:33991,TEXTURE8:33992,TEXTURE9:33993,TEXTURE_2D:3553,TEXTURE_BINDING_2D:32873,TEXTURE_BINDING_CUBE_MAP:34068,TEXTURE_CUBE_MAP:34067,TEXTURE_CUBE_MAP_NEGATIVE_X:34070,TEXTURE_CUBE_MAP_NEGATIVE_Y:34072,TEXTURE_CUBE_MAP_NEGATIVE_Z:34074,TEXTURE_CUBE_MAP_POSITIVE_X:34069,TEXTURE_CUBE_MAP_POSITIVE_Y:34071,TEXTURE_CUBE_MAP_POSITIVE_Z:34073,TEXTURE_MAG_FILTER:10240,TEXTURE_MIN_FILTER:10241,TEXTURE_WRAP_S:10242,TEXTURE_WRAP_T:10243,TRIANGLES:4,TRIANGLE_FAN:6,TRIANGLE_STRIP:5,UNPACK_ALIGNMENT:3317,UNPACK_COLORSPACE_CONVERSION_WEBGL:37443,UNPACK_FLIP_Y_WEBGL:37440,UNPACK_PREMULTIPLY_ALPHA_WEBGL:37441,UNSIGNED_BYTE:5121,UNSIGNED_INT:5125,UNSIGNED_SHORT:5123,UNSIGNED_SHORT_4_4_4_4:32819,UNSIGNED_SHORT_5_5_5_1:32820,UNSIGNED_SHORT_5_6_5:33635,VALIDATE_STATUS:35715,VENDOR:7936,VERSION:7938,VERTEX_ATTRIB_ARRAY_BUFFER_BINDING:34975,VERTEX_ATTRIB_ARRAY_ENABLED:34338,VERTEX_ATTRIB_ARRAY_NORMALIZED:34922,VERTEX_ATTRIB_ARRAY_POINTER:34373,VERTEX_ATTRIB_ARRAY_SIZE:34339,VERTEX_ATTRIB_ARRAY_STRIDE:34340,VERTEX_ATTRIB_ARRAY_TYPE:34341,VERTEX_SHADER:35633,VIEWPORT:2978,ZERO:0}},10:function(t,e,n){var r=n(698),i=n(4626),o=n(1982),a=n(3503);r.actor=function(){"use strict";if(!(this instanceof r.actor))return new r.actor;r.node.call(this);var t=this,e=a.create(),n=r.boundingObject.ReferenceFrame.Relative,i=null;return this.matrix=function(){return e},this.referenceFrame=function(){return n},this.mapper=function(){return i},this.setMapper=function(e){e!==i&&(i=e,t.boundsModified())},this.computeBounds=function(){if(null!=i){var n,r,a,s,u=t.computeBoundsTimestamp();(t.boundsDirtyTimestamp().getMTime()>u.getMTime()||i.boundsDirtyTimestamp().getMTime()>u.getMTime())&&(i.computeBounds(),r=[(n=i.bounds())[0],n[2],n[4]],a=[n[1],n[3],n[5]],o.transformMat4(r,r,e),o.transformMat4(a,a,e),s=[r[0]>a[0]?a[0]:r[0],r[0]>a[0]?r[0]:a[0],r[1]>a[1]?a[1]:r[1],r[1]>a[1]?r[1]:a[1],r[2]>a[2]?a[2]:r[2],r[2]>a[2]?r[2]:a[2]],t.setBounds(s[0],s[1],s[2],s[3],s[4],s[5]),u.modified())}else t.resetBounds()},t},i(r.actor,r.node)},8576:function(t,e,n){var r=n(698),i=n(4626);r.blendFunction=function(t,e){"use strict";if(!(this instanceof r.blendFunction))return new r.blendFunction(t,e);var n=t,i=e;return this.apply=function(t){t.m_context.blendFuncSeparate(n,i,r.GL.ONE,r.GL.ONE_MINUS_SRC_ALPHA)},this},r.blend=function(){"use strict";if(!(this instanceof r.blend))return new r.blend;r.materialAttribute.call(this,r.materialAttributeType.Blend);var t=!1,e=r.blendFunction(r.GL.SRC_ALPHA,r.GL.ONE_MINUS_SRC_ALPHA);return this.bind=function(n){return t=n.m_context.isEnabled(r.GL.BLEND),this.enabled()?(n.m_context.enable(r.GL.BLEND),e.apply(n)):n.m_context.disable(r.GL.BLEND),!0},this.undoBind=function(e){return t?e.m_context.enable(r.GL.BLEND):e.m_context.disable(r.GL.BLEND),!0},this},i(r.blend,r.materialAttribute)},3556:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.boundingObject=function(){"use strict";if(!(this instanceof r.boundingObject))return new r.boundingObject;r.object.call(this);var t=[0,0,0,0,0,0],e=o(),n=o();return e.modified(),n.modified(),this.bounds=function(){return t},this.hasValidBounds=function(t){return t[0]!==Number.MAX_VALUE&&t[1]!==-Number.MAX_VALUE&&t[2]!==Number.MAX_VALUE&&t[3]!==-Number.MAX_VALUE&&t[4]!==Number.MAX_VALUE&&t[5]!==-Number.MAX_VALUE},this.setBounds=function(n,r,i,o,a,s){if(this.hasValidBounds([n,r,i,o,a,s]))return t[0]=n,t[1]=r,t[2]=i,t[3]=o,t[4]=a,t[5]=s,this.modified(),e.modified(),!0},this.resetBounds=function(){t[0]=Number.MAX_VALUE,t[1]=-Number.MAX_VALUE,t[2]=Number.MAX_VALUE,t[3]=-Number.MAX_VALUE,t[4]=Number.MAX_VALUE,t[5]=-Number.MAX_VALUE,this.modified()},this.computeBounds=function(){},this.computeBoundsTimestamp=function(){return e},this.boundsDirtyTimestamp=function(){return n},this.resetBounds(),this},r.boundingObject.ReferenceFrame={Relative:0,Absolute:1},i(r.boundingObject,r.object)},4580:function(t,e,n){var r=n(698),i=n(4626),o=n(77),a=n(1982),s=n(4663),u=n(3503);r.camera=function(t){"use strict";if(!(this instanceof r.camera))return new r.camera(t);r.groupNode.call(this),t=t||{};var e=30*Math.PI/180,n=s.fromValues(0,0,1,1),i=s.fromValues(0,0,0,1),l=s.fromValues(0,1,0,0),c=1,f=s.fromValues(0,0,-1,0),h=u.create(),d=u.create(),p=o(),m=o(),g=-1,y=1,v=1,x=-1,_={zoom:1,tilesize:256},b=!1,w=[0,0,0,0],M=r.GL.COLOR_BUFFER_BIT|r.GL.DEPTH_BUFFER_BIT;return void 0!==t.parallelProjection&&(b=!!t.parallelProjection),this.setViewAspect=function(t){c=t,this.modified()},this.parallelExtents=function(){return _},this.setParallelExtents=function(t){var e,n,r=["width","height","zoom","tilesize"],i=!1;for(e=0;e<r.length;e+=1)void 0!==t[n=r[e]]&&t[n]!==_[n]&&(_[n]=t[n],i=!0);if(i&&_.width&&_.height&&void 0!==_.zoom&&_.tilesize){var o=this.unitsPerPixel(_.zoom,_.tilesize);y=o*_.width/2,g=-y,v=o*_.height/2,x=-v,this.modified()}},this.unitsPerPixel=function(t,e){return e=e||256,360*Math.pow(2,-t)/e},this.viewMatrix=function(){return this.computeViewMatrix()},this.setViewMatrix=function(t,e){e?h=t.slice():u.copy(h,t),p.modified()},this.projectionMatrix=function(){return this.computeProjectionMatrix()},this.setProjectionMatrix=function(t){u.copy(d,t),m.modified()},this.clearMask=function(){return M},this.clearColor=function(){return w},this.clearDepth=function(){return 1},this.computeDirectionOfProjection=function(){a.subtract(f,i,n),a.normalize(f,f),this.modified()},this.computeViewMatrix=function(){return p.getMTime()<this.getMTime()&&(u.lookAt(h,n,i,l),p.modified()),h},this.computeProjectionMatrix=function(){return m.getMTime()<this.getMTime()&&(b?u.ortho(d,g,y,x,v,.01,1e4):u.perspective(d,e,c,.01,1e4),m.modified()),d},this.computeDirectionOfProjection(),this},i(r.camera,r.groupNode)},7695:function(t,e,n){var r=n(698);r.data=function(){"use strict";if(!(this instanceof r.data))return new r.data;this.type=function(){}},r.data.raster=0,r.data.point=1,r.data.lineString=2,r.data.polygon=3,r.data.geometry=10},4831:function(t,e,n){var r=n(698);r.event={},r.event.keyPress="vgl.event.keyPress",r.event.mousePress="vgl.event.mousePress",r.event.mouseRelease="vgl.event.mouseRelease",r.event.contextMenu="vgl.event.contextMenu",r.event.configure="vgl.event.configure",r.event.enable="vgl.event.enable",r.event.mouseWheel="vgl.event.mouseWheel",r.event.keyRelease="vgl.event.keyRelease",r.event.middleButtonPress="vgl.event.middleButtonPress",r.event.startInteraction="vgl.event.startInteraction",r.event.enter="vgl.event.enter",r.event.rightButtonPress="vgl.event.rightButtonPress",r.event.middleButtonRelease="vgl.event.middleButtonRelease",r.event.char="vgl.event.char",r.event.disable="vgl.event.disable",r.event.endInteraction="vgl.event.endInteraction",r.event.mouseMove="vgl.event.mouseMove",r.event.mouseOut="vgl.event.mouseOut",r.event.expose="vgl.event.expose",r.event.timer="vgl.event.timer",r.event.leftButtonPress="vgl.event.leftButtonPress",r.event.leave="vgl.event.leave",r.event.rightButtonRelease="vgl.event.rightButtonRelease",r.event.leftButtonRelease="vgl.event.leftButtonRelease",r.event.click="vgl.event.click",r.event.dblClick="vgl.event.dblClick"},7327:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.primitive=function(){"use strict";if(!(this instanceof r.primitive))return new r.primitive;var t=0,e=0,n=null;return this.indices=function(){return n},this.numberOfIndices=function(){return n.length},this.primitiveType=function(){return t},this.setPrimitiveType=function(e){t=e},this.indicesValueType=function(){return e},this.setIndicesValueType=function(t){e=t},this.setIndices=function(t){n=new Uint16Array(t)},this},r.triangles=function(){"use strict";return this instanceof r.triangles?(r.primitive.call(this),this.setPrimitiveType(r.GL.TRIANGLES),this.setIndicesValueType(r.GL.UNSIGNED_SHORT),this):new r.triangles},i(r.triangles,r.primitive),r.points=function(){"use strict";return this instanceof r.points?(r.primitive.call(this),this.setPrimitiveType(r.GL.POINTS),this.setIndicesValueType(r.GL.UNSIGNED_SHORT),this):new r.points},i(r.points,r.primitive),r.sourceData=function(t){"use strict";if(!(this instanceof r.sourceData))return new r.sourceData(t);var e={},n=[],i=(t=t||{}).name||"Source "+(new Date).toISOString(),o=function(){this.m_numberOfComponents=0,this.m_dataType=0,this.m_dataTypeSize=0,this.m_normalized=!1,this.m_stride=0,this.m_offset=0};return this.data=function(){return n},this.getData=function(){return this.data()},this.dataToFloat32Array=function(){return n instanceof Float32Array||(n=new Float32Array(n)),n},this.setData=function(t){t instanceof Array||t instanceof Float32Array?n=t instanceof Float32Array?t:t.slice(0):console.log("[error] Requires array")},this.addAttribute=function(t,n,r,i,a,s,u){if(!e.hasOwnProperty(t)){var l=new o;l.m_dataType=n,l.m_dataTypeSize=r,l.m_offset=i,l.m_stride=a,l.m_numberOfComponents=s,l.m_normalized=u,e[t]=l}},this.hasKey=function(t){return e.hasOwnProperty(t)},this.keys=function(){return Object.keys(e)},this.attributeNumberOfComponents=function(t){return e.hasOwnProperty(t)?e[t].m_numberOfComponents:0},this.normalized=function(t){return!!e.hasOwnProperty(t)&&e[t].m_normalized},this.attributeDataType=function(t){if(e.hasOwnProperty(t))return e[t].m_dataType},this.attributeOffset=function(t){return e.hasOwnProperty(t)?e[t].m_offset:0},this.attributeStride=function(t){return e.hasOwnProperty(t)?e[t].m_stride:0},this.pushBack=function(t){},this.insert=function(t){var e;if(!n.length&&t.length&&t instanceof Float32Array)n=t;else if(n.slice||!n.length&&t.slice||(n=Array.prototype.slice.call(n)),t.length)if(!n.length&&t.slice)n=t.slice(0);else for(e=0;e<t.length;e+=1)n[n.length]=t[e];else n[n.length]=t},this.name=function(){return i},this},r.sourceDataAnyfv=function(t,e,n){"use strict";return this instanceof r.sourceDataAnyfv?(r.sourceData.call(this,n),this.addAttribute(e,r.GL.FLOAT,4,0,4*t,t,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataAnyfv(t,e,n)},i(r.sourceDataAnyfv,r.sourceData),r.sourceDataP3fv=function(t){"use strict";return this instanceof r.sourceDataP3fv?(r.sourceData.call(this,t),this.addAttribute(r.vertexAttributeKeys.Position,r.GL.FLOAT,4,0,12,3,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataP3fv(t)},i(r.sourceDataP3fv,r.sourceData),r.sourceDataT2fv=function(t){"use strict";return this instanceof r.sourceDataT2fv?(r.sourceData.call(this,t),this.addAttribute(r.vertexAttributeKeys.TextureCoordinate,r.GL.FLOAT,4,0,8,2,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataT2fv(t)},i(r.sourceDataT2fv,r.sourceData),r.geometryData=function(){"use strict";if(!(this instanceof r.geometryData))return new r.geometryData;r.data.call(this);var t=[],e=[],n=[0,0,0,0,0,0],i=o(),a=o();return this.type=function(){return r.data.geometry},this.name=function(){return""},this.addSource=function(t){return-1===e.indexOf(t)&&(e.push(t),t.hasKey(r.vertexAttributeKeys.Position)&&a.modified(),!0)},this.source=function(t){return t<e.length?e[t]:0},this.sourceByName=function(t){for(var n=0;n<e.length;n+=1)if(e[n].name()===t)return e[n];return 0},this.numberOfSources=function(){return e.length},this.sourceData=function(t){var n;for(n=0;n<e.length;n+=1)if(e[n].hasKey(t))return e[n];return null},this.addPrimitive=function(e){return t.push(e),!0},this.primitive=function(e){return e<t.length?t[e]:null},this.numberOfPrimitives=function(){return t.length},this.bounds=function(){return a.getMTime()>i.getMTime()&&this.computeBounds(),n},this.boundsDirty=function(t){return t&&a.modified(),a.getMTime()>i.getMTime()},this.setBounds=function(t,e,r,o,a,s){return n[0]=t,n[1]=e,n[2]=r,n[3]=o,n[4]=a,n[5]=s,i.modified(),!0},this},i(r.geometryData,r.data)},29:function(t,e,n){var r=n(698),i=n(4626);r.graphicsObject=function(t){"use strict";if(!(this instanceof r.graphicsObject))return new r.graphicsObject;r.object.call(this);return this._setup=function(t){return!1},this._cleanup=function(t){return!1},this},i(r.graphicsObject,r.object)},7616:function(t,e,n){var r=n(698),i=n(4626);r.groupNode=function(){"use strict";if(!(this instanceof r.groupNode))return new r.groupNode;r.node.call(this);var t=[];return this.addChild=function(e){return e instanceof r.node&&(-1===t.indexOf(e)&&(e.setParent(this),t.push(e),this.boundsDirtyTimestamp().modified(),!0))},this.removeChild=function(e){if(e.parent()===this){var n=t.indexOf(e);if(n>=0)return t.splice(n,1),e.setParent(null),this.boundsDirtyTimestamp().modified(),!0}},this.removeChildren=function(){for(;t.length;)this.removeChild(t[0]);this.modified()},this.children=function(){return t},this.hasChild=function(e){var n=0,r=!1;for(n=0;n<t.length;n+=1)if(t[n]===e){r=!0;break}return r},this},i(r.groupNode,r.node)},1611:function(t,e,n){t.exports=n(698),n(6552),n(9156),n(3556),n(9838),n(4831),n(29),n(4970),n(1232),n(2971),n(10),n(7616),n(4580),n(8576),n(7695),n(7327),n(5763),n(5796),n(5794),n(796),n(8888),n(3471),n(4933),n(7205)},9838:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.mapper=function(t){"use strict";if(!(this instanceof r.mapper))return new r.mapper(t);r.boundingObject.call(this);var e=[0,1,1],n=null,i=[],a={},s=void 0!==(t=t||{}).dynamicDraw&&t.dynamicDraw,u=o(),l=null,c=this;function f(t){a={},i=[]}function h(t){c.deleteVertexBufferObjects(t),f(),function(t){if(n){t&&(l=t.m_context);var e,o,c,f,h,d,p,m=n.numberOfSources(),g=null;for(e=0;e<m;e+=1){for(g=l.createBuffer(),l.bindBuffer(r.GL.ARRAY_BUFFER,g),(p=n.source(e).data())instanceof Float32Array||(p=new Float32Array(p)),l.bufferData(r.GL.ARRAY_BUFFER,p,s?r.GL.DYNAMIC_DRAW:r.GL.STATIC_DRAW),f=n.source(e).keys(),h=[],o=0;o<f.length;o+=1)h.push(f[o]);a[e]=h,i[e]=g}for(d=n.numberOfPrimitives(),c=0;c<d;c+=1)g=l.createBuffer(),l.bindBuffer(r.GL.ARRAY_BUFFER,g),l.bufferData(r.GL.ARRAY_BUFFER,n.primitive(c).indices(),r.GL.STATIC_DRAW),i[e]=g,e+=1;u.modified()}}(t)}return this.deleteVertexBufferObjects=function(t){var e,n=l;if(t&&(n=t.m_context),n)for(e=0;e<i.length;e+=1)n.deleteBuffer(i[e])},this._cleanup=function(t){c.deleteVertexBufferObjects(t),f(t),c.modified()},this.computeBounds=function(){if(null!=n){var t=this.computeBoundsTimestamp(),e=null;this.boundsDirtyTimestamp().getMTime()>t.getMTime()&&(e=n.bounds(),this.setBounds(e[0],e[1],e[2],e[3],e[4],e[5]),t.modified())}else this.resetBounds()},this.color=function(){return e},this.geometryData=function(){return n},this.setGeometryData=function(t){n!==t&&(n=t,this.modified(),this.boundsDirtyTimestamp().modified())},this.updateSourceBuffer=function(t,e,o){if(o&&(l=o.m_context),!l)return!1;for(var a=-1,s=0;s<n.numberOfSources();s+=1)if(n.source(s).name()===t){a=s;break}return!(a<0||a>=i.length)&&(e||(e=n.source(s).dataToFloat32Array()),l.bindBuffer(r.GL.ARRAY_BUFFER,i[a]),e instanceof Float32Array?l.bufferSubData(r.GL.ARRAY_BUFFER,0,e):l.bufferSubData(r.GL.ARRAY_BUFFER,0,new Float32Array(e)),!0)},this.getSourceBuffer=function(t){var e=n.sourceByName(t);return e?e.dataToFloat32Array():new Float32Array},this.render=function(t,e){(this.getMTime()>u.getMTime()||t.m_contextChanged)&&h(t),(l=t.m_context).vertexAttrib3fv(r.vertexAttributeKeys.Color,this.color());var o,s,c=0,f=0,d=null;for(o in a)if(a.hasOwnProperty(o)){for(l.bindBuffer(r.GL.ARRAY_BUFFER,i[c]),f=0;f<a[o].length;f+=1)t.m_material.bindVertexData(t,a[o][f]);c+=1}for(s=n.numberOfPrimitives(),f=0;f<s;f+=1,c+=1)if((d=n.primitive(f)).numberOfIndices()){switch(l.bindBuffer(r.GL.ARRAY_BUFFER,i[c]),d.primitiveType()){case r.GL.POINTS:l.drawArrays(r.GL.POINTS,0,d.numberOfIndices());break;case r.GL.LINES:l.drawArrays(r.GL.LINES,0,d.numberOfIndices());break;case r.GL.LINE_STRIP:l.drawArrays(r.GL.LINE_STRIP,0,d.numberOfIndices());break;case r.GL.TRIANGLES:l.drawArrays(r.GL.TRIANGLES,0,d.numberOfIndices());break;case r.GL.TRIANGLE_STRIP:l.drawArrays(r.GL.TRIANGLE_STRIP,0,d.numberOfIndices())}l.bindBuffer(r.GL.ARRAY_BUFFER,null)}e||this.undoBindVertexData(t)},this.undoBindVertexData=function(t){var e,n;for(e in a)if(a.hasOwnProperty(e))for(n=0;n<a[e].length;n+=1)t.m_material.undoBindVertexData(t,a[e][n])},this},i(r.mapper,r.boundingObject)},4970:function(t,e,n){var r=n(698),i=n(4626);r.material=function(){"use strict";if(!(this instanceof r.material))return new r.material;r.graphicsObject.call(this);var t=this,e=new r.shaderProgram,n=100,i={},o={};return this.binNumber=function(){return n},this.setBinNumber=function(e){n=e,t.modified()},this.exists=function(t){return t.type()===r.materialAttributeType.Texture?i.hasOwnProperty(t.textureUnit()):o.hasOwnProperty(t.type())},this.addAttribute=function(n){return!t.exists(n)&&(n.type()===r.materialAttributeType.Texture?(i[n.textureUnit()]=n,t.modified(),!0):(n.type()===r.materialAttributeType.ShaderProgram&&(e=n),o[n.type()]=n,t.modified(),!0))},this.shaderProgram=function(){return e},this._cleanup=function(n){for(var r in o)o.hasOwnProperty(r)&&o[r]._cleanup(n);for(r in i)i.hasOwnProperty(r)&&i[r]._cleanup(n);e._cleanup(n),t.modified()},this.bind=function(t){var n=null;for(n in e.bind(t),o)o.hasOwnProperty(n)&&o[n]!==e&&o[n].bind(t);for(n in i)i.hasOwnProperty(n)&&i[n].bind(t)},this.undoBind=function(t){var e=null;for(e in o)o.hasOwnProperty(e)&&o[e].undoBind(t);for(e in i)i.hasOwnProperty(e)&&i[e].undoBind(t)},this.bindVertexData=function(t,e){var n=null;for(n in o)o.hasOwnProperty(n)&&o[n].bindVertexData(t,e)},this.undoBindVertexData=function(t,e){var n=null;for(n in o)o.hasOwnProperty(n)&&o[n].undoBindVertexData(t,e)},t},r.material.RenderBin={Base:0,Default:100,Opaque:100,Transparent:1e3,Overlay:1e4},i(r.material,r.graphicsObject)},1232:function(t,e,n){var r=n(698),i=n(4626);r.materialAttributeType={Undefined:0,ShaderProgram:1,Texture:2,Blend:3,Depth:4},r.materialAttribute=function(t){"use strict";if(!(this instanceof r.materialAttribute))return new r.materialAttribute(t);r.graphicsObject.call(this);var e=t;return this.type=function(){return e},this.enabled=function(){return true},this.bindVertexData=function(t,e){return!1},this.undoBindVertexData=function(t,e){return!1},this},i(r.materialAttribute,r.graphicsObject)},2971:function(t,e,n){var r=n(698),i=n(4626);r.node=function(){"use strict";if(!(this instanceof r.node))return new r.node;r.boundingObject.call(this);var t=null,e=null,n=!0;return this.material=function(){return e},this.setMaterial=function(t){return t!==e&&(e=t,this.modified(),!0)},this.visible=function(){return n},this.setVisible=function(t){return t!==n&&(n=t,this.modified(),!0)},this.parent=function(){return t},this.setParent=function(e){return e!==t&&(null!==t&&t.removeChild(this),t=e,this.modified(),!0)},this.boundsModified=function(){this.boundsDirtyTimestamp().modified(),null!==t&&t.boundsModified()},this},i(r.node,r.boundingObject)},9156:function(t,e,n){var r=n(698),i=n(77);r.object=function(){"use strict";if(!(this instanceof r.object))return new r.object;var t=i();return t.modified(),this.modified=function(){t.modified()},this.getMTime=function(){return t.getMTime()},this}},5763:function(t,e,n){var r=n(698),i=n(4626);r.renderWindow=function(t){"use strict";if(!(this instanceof r.renderWindow))return new r.renderWindow(t);r.graphicsObject.call(this);var e=this,n=0,i=0,o=400,a=400,s=t,u=null,l=[],c=null;return this.windowSize=function(){return[o,a]},this.windowPosition=function(){return[n,i]},this.renderers=function(){return l},this.activeRenderer=function(){return u},this.addRenderer=function(t){return!1===e.hasRenderer(t)&&(l.push(t),t.setRenderWindow(e),null===u&&(u=t),0!==t.layer()&&t.camera().setClearMask(r.GL.DepthBufferBit),e.modified(),!0)},this.hasRenderer=function(t){var e;for(e=0;e<l.length;e+=1)if(t===l[e])return!0;return!1},this.positionAndResize=function(t,r,s,u){var c;for(n=t,i=r,o=s,a=u,c=0;c<l.length;c+=1)l[c].positionAndResize(n,i,o,a);e.modified()},this._setup=function(t){c=null;try{var e;for(c=s.getContext("webgl")||s.getContext("experimental-webgl"),e=0;e<l.length;e+=1)(l[e].width()>o||0===l[e].width()||l[e].height()>a||0===l[e].height())&&l[e].resize(n,i,o,a);return!0}catch(t){}return c||console("[ERROR] Unable to initialize WebGL. Your browser may not support it."),!1},this.context=function(){return c},this._cleanup=function(t){var n;for(n=0;n<l.length;n+=1)l[n]._cleanup(t);r.clearCachedShaders(t?t.m_context:null),e.modified()},this.render=function(){var t;for(l.sort((function(t,e){return t.layer()-e.layer()})),t=0;t<l.length;t+=1)l[t].render()},e},i(r.renderWindow,r.graphicsObject)},5796:function(t,e,n){var r=n(698),i=n(4626),o=n(3503);r.renderState=function(){"use strict";this.m_context=null,this.m_modelViewMatrix=o.create(),this.m_normalMatrix=o.create(),this.m_projectionMatrix=null,this.m_material=null,this.m_mapper=null},r.renderer=function(t){"use strict";if(!(this instanceof r.renderer))return new r.renderer(t);r.graphicsObject.call(this),t=t||{};var e=this;return e.m_renderWindow=null,e.m_contextChanged=!1,e.m_sceneRoot=new r.groupNode,e.m_camera=new r.camera(t),e.m_nearClippingPlaneTolerance=null,e.m_x=0,e.m_y=0,e.m_width=0,e.m_height=0,e.m_resizable=!0,e.m_resetScene=!0,e.m_layer=0,e.m_renderPasses=null,e.m_resetClippingRange=!0,e.m_depthBits=null,e.m_camera.addChild(e.m_sceneRoot),this.width=function(){return e.m_width},this.height=function(){return e.m_height},this.layer=function(){return e.m_layer},this.setLayer=function(t){e.m_layer=t,e.modified()},this.renderWindow=function(){return e.m_renderWindow},this.setRenderWindow=function(t){e.m_renderWindow!==t&&(e.m_renderWindow&&e.m_renderWindow.removeRenderer(this),e.m_renderWindow=t,e.m_contextChanged=!0,e.modified())},this.camera=function(){return e.m_camera},this.render=function(){var t,n,i,a=null,s=[],u=o.create(),l=null;if((n=new r.renderState).m_renderer=e,n.m_context=e.renderWindow().context(),e.m_depthBits&&!e.m_contextChanged||(e.m_depthBits=n.m_context.getParameter(r.GL.DEPTH_BITS)),n.m_contextChanged=e.m_contextChanged,e.m_renderPasses)for(t=0;t<e.m_renderPasses.length;t+=1){if(e.m_renderPasses[t].render(n))return console.log("returning"),void e.m_renderPasses[t].remove(n);e.m_renderPasses[t].remove(n)}for(n.m_context.enable(r.GL.DEPTH_TEST),n.m_context.depthFunc(r.GL.LEQUAL),e.m_camera.clearMask()&r.GL.COLOR_BUFFER_BIT&&(l=e.m_camera.clearColor(),n.m_context.clearColor(l[0],l[1],l[2],l[3])),e.m_camera.clearMask()&r.GL.DEPTH_BUFFER_BIT&&n.m_context.clearDepth(e.m_camera.clearDepth()),n.m_context.clear(e.m_camera.clearMask()),n.m_context.viewport(e.m_x,e.m_y,e.m_width,e.m_height),(i=e.m_sceneRoot.children()).length>0&&e.m_resetScene&&(e.m_resetScene=!1),t=0;t<i.length;t+=1)(a=i[t]).computeBounds(),a.visible()&&a.material().binNumber()>=0&&s.push([a.material().binNumber(),a]);for(s.sort((function(t,e){return t[0]-e[0]})),t=0;t<s.length;t+=1){if((a=s[t][1]).referenceFrame()===r.boundingObject.ReferenceFrame.Relative){var c=e.m_camera.viewMatrix();c instanceof Array&&(n.m_modelViewMatrix=new Array(16)),o.multiply(n.m_modelViewMatrix,c,a.matrix()),n.m_projectionMatrix=e.m_camera.projectionMatrix(),n.m_modelViewAlignment=e.m_camera.viewAlignment()}else n.m_modelViewMatrix=a.matrix(),n.m_modelViewAlignment=null,n.m_projectionMatrix=o.create(),o.ortho(n.m_projectionMatrix,0,e.m_width,0,e.m_height,-1,1);o.invert(u,n.m_modelViewMatrix),o.transpose(n.m_normalMatrix,u),n.m_material=a.material(),n.m_mapper=a.mapper(),n.m_material.bind(n),n.m_mapper.render(n),n.m_material.undoBind(n)}n.m_context.finish(),e.m_contextChanged=!1,e.m_lastRenderState=n},this.resize=function(t,n){t&&n&&e.positionAndResize(e.m_x,e.m_y,t,n)},this.positionAndResize=function(t,n,r,i){var o;if(t<0||n<0||r<=0||i<=0)console.log("[error] Invalid position and resize values",t,n,r,i);else if(e.m_resizable&&(e.m_width=r,e.m_height=i,e.m_camera.setViewAspect(r/i),e.m_camera.setParallelExtents({width:r,height:i}),e.modified()),e.m_renderPasses)for(o=0;o<e.m_renderPasses.length;o+=1)e.m_renderPasses[o].resize(r,i),e.m_renderPasses[o].renderer().positionAndResize(t,n,r,i)},this.addActor=function(t){return t instanceof r.actor&&(e.m_sceneRoot.addChild(t),e.modified(),!0)},this.hasActor=function(t){return e.m_sceneRoot.hasChild(t)},this.removeActor=function(t){return-1!==e.m_sceneRoot.children().indexOf(t)&&(e.m_lastRenderState&&(t.mapper()&&t.mapper()._cleanup(e.m_lastRenderState),t.material()&&t.material()._cleanup(e.m_lastRenderState)),t.modified(),e.m_sceneRoot.removeChild(t),e.modified(),!0)},this.setResetScene=function(t){e.m_resetScene!==t&&(e.m_resetScene=t,e.modified())},this._cleanup=function(t){for(var n=e.m_sceneRoot.children(),r=0;r<n.length;r+=1){var i=n[r];i.material()._cleanup(t),i.mapper()._cleanup(t)}e.m_sceneRoot.removeChildren(),e.modified()},e},i(r.renderer,r.graphicsObject)},5794:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.shader=function(t){"use strict";if(!(this instanceof r.shader))return new r.shader(t);r.object.call(this);var e=[],n=t,i="";this._getContextEntry=function(t){var n,r,i=t.m_context;for(n=0;n<e.length;n+=1)if(e[n].context===i)return e[n];return r={context:i,compileTimestamp:o()},e.push(r),r},this.removeContext=function(t){var n,r=t.m_context;for(n=0;n<e.length;n+=1)if(e[n].context===r)return void e.splice(n,1)},this.shaderHandle=function(t){return this._getContextEntry(t).shaderHandle},this.setShaderSource=function(t){i=t,this.modified()},this.compile=function(t){var e=this._getContextEntry(t);return this.getMTime()<e.compileTimestamp.getMTime()?e.shaderHandle:(t.m_context.deleteShader(e.shaderHandle),e.shaderHandle=t.m_context.createShader(n),t.m_context.shaderSource(e.shaderHandle,i),t.m_context.compileShader(e.shaderHandle),t.m_context.getShaderParameter(e.shaderHandle,r.GL.COMPILE_STATUS)?(e.compileTimestamp.modified(),e.shaderHandle):(console.log("[ERROR] An error occurred compiling the shaders: "+t.m_context.getShaderInfoLog(e.shaderHandle)),console.log(i),t.m_context.deleteShader(e.shaderHandle),null))},this.attachShader=function(t,e){t.m_context.attachShader(e,this.shaderHandle(t))}},i(r.shader,r.object),function(){"use strict";var t=[];r.getCachedShader=function(e,n,i){for(var o=0;o<t.length;o+=1)if(t[o].type===e&&t[o].context===n&&t[o].source===i)return o&&t.splice(0,0,t.splice(o,1)[0]),t[0].shader;var a=new r.shader(e);return a.setShaderSource(i),t.unshift({type:e,context:n,source:i,shader:a}),t.length>=10&&t.splice(10,t.length-10),a},r.clearCachedShaders=function(e){for(var n=t.length-1;n>=0;n-=1)null!=e&&t[n].context!==e||t.splice(n,1)}}()},796:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.shaderProgram=function(){"use strict";if(!(this instanceof r.shaderProgram))return new r.shaderProgram;r.materialAttribute.call(this,r.materialAttributeType.ShaderProgram);var t=this,e=0,n=o(),i=o(),a=[],s=[],u={},l={},c={};return this.queryUniformLocation=function(t,n){return t.m_context.getUniformLocation(e,n)},this.queryAttributeLocation=function(t,n){return t.m_context.getAttribLocation(e,n)},this.addShader=function(e){if(a.indexOf(e)>-1)return!1;var n;for(n=a.length-2;n>=0;n-=1)a[n].shaderType()===e.shaderType()&&a.splice(n,1);return a.push(e),t.modified(),!0},this.addUniform=function(e){return!(s.indexOf(e)>-1)&&(s.push(e),t.modified(),!0)},this.addVertexAttribute=function(e,n){u[n]=e,t.modified()},this.uniformLocation=function(t){return l[t]},this.attributeLocation=function(t){return c[t]},this.uniform=function(t){var e;for(e=0;e<s.length;e+=1)if(s[e].name()===t)return s[e];return null},this.updateUniforms=function(t){var e;for(e=0;e<s.length;e+=1)s[e].callGL(t,l[s[e].name()])},this.link=function(t){return t.m_context.linkProgram(e),!!t.m_context.getProgramParameter(e,r.GL.LINK_STATUS)||(console.log("[ERROR] Unable to initialize the shader program."),!1)},this.use=function(t){t.m_context.useProgram(e)},this._setup=function(t){0===e&&(e=t.m_context.createProgram())},this._cleanup=function(e){t.deleteVertexAndFragment(e),t.deleteProgram(e),t.modified()},this.deleteProgram=function(t){e&&t.m_context.deleteProgram(e),e=0},this.deleteVertexAndFragment=function(t){var n;for(n=0;n<a.length;n+=1)a[n].shaderHandle(t)&&t.m_context.detachShader(e,a[n].shaderHandle(t)),t.m_context.deleteShader(a[n].shaderHandle(t)),a[n].removeContext(t)},this.compileAndLink=function(r){var i;if(!(n.getMTime()>=this.getMTime())){for(t._setup(r),i=0;i<a.length;i+=1)a[i].compile(r),a[i].attachShader(r,e);t.bindAttributes(r),t.link(r)||(console.log("[ERROR] Failed to link Program"),t._cleanup(r)),n.modified()}},this.bind=function(e){var n=0;for(i.getMTime()<t.getMTime()?(t.compileAndLink(e),t.use(e),t.bindUniforms(e),i.modified()):t.use(e),n=0;n<s.length;n+=1)s[n].update(e,t);t.updateUniforms(e)},this.undoBind=function(t){t.m_context.useProgram(null)},this.bindVertexData=function(t,e){u.hasOwnProperty(e)&&u[e].bindVertexData(t,e)},this.undoBindVertexData=function(t,e){u.hasOwnProperty(e)&&u[e].undoBindVertexData(t,e)},this.bindUniforms=function(t){var e;for(e=0;e<s.length;e+=1)l[s[e].name()]=this.queryUniformLocation(t,s[e].name())},this.bindAttributes=function(t){var n,r;for(n in u)u.hasOwnProperty(n)&&(r=u[n].name(),t.m_context.bindAttribLocation(e,n,r),c[r]=n)},t},i(r.shaderProgram,r.materialAttribute)},8888:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.texture=function(){"use strict";if(!(this instanceof r.texture))return new r.texture;r.materialAttribute.call(this,r.materialAttributeType.Texture),this.m_width=0,this.m_height=0,this.m_depth=0,this.m_textureHandle=null,this.m_textureUnit=0,this.m_pixelFormat=r.GL.RGBA,this.m_pixelDataType=r.GL.UNSIGNED_BYTE,this.m_internalFormat=r.GL.RGBA,this.m_nearestPixel=!1,this.m_image=null;var t=o(),e=this;function n(t){if(!(e.m_textureUnit>=0&&e.m_textureUnit<32))throw"[error] Texture unit "+e.m_textureUnit+" is not supported";t.m_context.activeTexture(r.GL.TEXTURE0+e.m_textureUnit)}return this.setup=function(e){n(e),e.m_context.deleteTexture(this.m_textureHandle),this.m_textureHandle=e.m_context.createTexture(),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,this.m_nearestPixel?r.GL.NEAREST:r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,this.m_nearestPixel?r.GL.NEAREST:r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_S,r.GL.CLAMP_TO_EDGE),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_T,r.GL.CLAMP_TO_EDGE),null!==this.m_image?(e.m_context.pixelStorei(r.GL.UNPACK_ALIGNMENT,1),e.m_context.pixelStorei(r.GL.UNPACK_FLIP_Y_WEBGL,!0),this.updateDimensions(),this.computeInternalFormatUsingImage(),e.m_context.texImage2D(r.GL.TEXTURE_2D,0,this.m_internalFormat,this.m_pixelFormat,this.m_pixelDataType,this.m_image)):e.m_context.texImage2D(r.GL.TEXTURE_2D,0,this.m_internalFormat,this.m_width,this.m_height,0,this.m_pixelFormat,this.m_pixelDataType,null),e.m_context.bindTexture(r.GL.TEXTURE_2D,null),t.modified()},this.bind=function(e){this.getMTime()>t.getMTime()&&this.setup(e),n(e),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle)},this.undoBind=function(t){t.m_context.bindTexture(r.GL.TEXTURE_2D,null)},this.image=function(){return this.m_image},this.setImage=function(t){return null!==t&&(this.m_image=t,this.updateDimensions(),this.modified(),!0)},this.nearestPixel=function(){return this.m_nearestPixel},this.setNearestPixel=function(t){return(t=!!t)!==this.m_nearestPixel&&(this.m_nearestPixel=t,this.modified(),!0)},this.textureUnit=function(){return this.m_textureUnit},this.setTextureUnit=function(t){return this.m_textureUnit!==t&&(this.m_textureUnit=t,this.modified(),!0)},this.computeInternalFormatUsingImage=function(){this.m_internalFormat=r.GL.RGBA,this.m_pixelFormat=r.GL.RGBA,this.m_pixelDataType=r.GL.UNSIGNED_BYTE},this.updateDimensions=function(){null!==this.m_image&&(this.m_width=this.m_image.width,this.m_height=this.m_image.height,this.m_depth=0)},this.textureHandle=function(){return this.m_textureHandle},this},i(r.texture,r.materialAttribute),r.lookupTable=function(){"use strict";if(!(this instanceof r.lookupTable))return new r.lookupTable;r.texture.call(this);var t=o();return this.m_colorTable=[.07514311,.468049805,1,1,.247872569,.498782363,1,1,.339526309,.528909511,1,1,.409505078,.558608486,1,1,.468487184,.588057293,1,1,.520796675,.617435078,1,1,.568724526,.646924167,1,1,.613686735,.676713218,1,1,.656658579,.707001303,1,1,.698372844,.738002964,1,1,.739424025,.769954435,1,1,.780330104,.803121429,1,1,.821573924,.837809045,1,1,.863634967,.874374691,1,1,.907017747,.913245283,1,1,.936129275,.938743558,.983038586,1,.943467973,.943498599,.943398095,1,.990146732,.928791426,.917447482,1,1,.88332677,.861943246,1,1,.833985467,.803839606,1,1,.788626485,.750707739,1,1,.746206642,.701389973,1,1,.70590052,.654994046,1,1,.667019783,.610806959,1,1,.6289553,.568237474,1,1,.591130233,.526775617,1,1,.552955184,.485962266,1,1,.513776083,.445364274,1,1,.472800903,.404551679,1,1,.428977855,.363073592,1,1,.380759558,.320428137,1,.961891484,.313155629,.265499262,1,.916482116,.236630659,.209939162,1].map((function(t){return 255*t})),this.setup=function(e){0===this.textureUnit()?e.m_context.activeTexture(r.GL.TEXTURE0):1===this.textureUnit()&&e.m_context.activeTexture(r.GL.TEXTURE1),e.m_context.deleteTexture(this.m_textureHandle),this.m_textureHandle=e.m_context.createTexture(),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_S,r.GL.CLAMP_TO_EDGE),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_T,r.GL.CLAMP_TO_EDGE),e.m_context.pixelStorei(r.GL.UNPACK_ALIGNMENT,1),this.m_width=this.m_colorTable.length/4,this.m_height=1,this.m_depth=0,e.m_context.texImage2D(r.GL.TEXTURE_2D,0,r.GL.RGBA,this.m_width,this.m_height,this.m_depth,r.GL.RGBA,r.GL.UNSIGNED_BYTE,new Uint8Array(this.m_colorTable)),e.m_context.bindTexture(r.GL.TEXTURE_2D,null),t.modified()},this.colorTable=function(){return this.m_colorTable},this.setColorTable=function(t){return this.m_colorTable!==t&&(this.m_colorTable=t,this.modified(),!0)},this},i(r.lookupTable,r.texture)},3471:function(t,e,n){var r=n(698),i=n(4626),o=n(3503);r.uniform=function(t,e){"use strict";if(!(this instanceof r.uniform))return new r.uniform(t,e);this.getTypeNumberOfComponents=function(t){switch(t){case r.GL.FLOAT:case r.GL.INT:case r.GL.BOOL:return 1;case r.GL.FLOAT_VEC2:case r.GL.INT_VEC2:case r.GL.BOOL_VEC2:return 2;case r.GL.FLOAT_VEC3:case r.GL.INT_VEC3:case r.GL.BOOL_VEC3:return 3;case r.GL.FLOAT_VEC4:case r.GL.INT_VEC4:case r.GL.BOOL_VEC4:return 4;case r.GL.FLOAT_MAT3:return 9;case r.GL.FLOAT_MAT4:return 16;default:return 0}};var n=t,i=e,o=new Array(this.getTypeNumberOfComponents(n)).fill(0);return this.name=function(){return i},this.set=function(t){var e=0,n=o.length;if(1!==n)for(e=0;e<n;e+=1)o[e]=t[e];else o[0]=t},this.callGL=function(t,e){switch(n){case r.GL.BOOL:case r.GL.INT:t.m_context.uniform1iv(e,o);break;case r.GL.FLOAT:t.m_context.uniform1fv(e,o);break;case r.GL.BOOL_VEC2:case r.GL.INT_VEC2:t.m_context.uniform2iv(e,o);break;case r.GL.FLOAT_VEC2:t.m_context.uniform2fv(e,o);break;case r.GL.BOOL_VEC3:case r.GL.INT_VEC3:t.m_context.uniform3iv(e,o);break;case r.GL.FLOAT_VEC3:t.m_context.uniform3fv(e,o);break;case r.GL.BOOL_VEC4:case r.GL.INT_VEC4:t.m_context.uniform4iv(e,o);break;case r.GL.FLOAT_VEC4:t.m_context.uniform4fv(e,o);break;case r.GL.FLOAT_MAT3:t.m_context.uniformMatrix3fv(e,r.GL.FALSE,o);break;case r.GL.FLOAT_MAT4:t.m_context.uniformMatrix4fv(e,r.GL.FALSE,o)}},this.update=function(t,e){},this},r.modelViewOriginUniform=function(t,e){"use strict";if(!(this instanceof r.modelViewOriginUniform))return new r.modelViewOriginUniform(t,e);t||(t="modelViewMatrix");var n=[(e=e||[0,0,0])[0],e[1],e[2]||0];return r.uniform.call(this,r.GL.FLOAT_MAT4,t),this.set(o.create()),this.setOrigin=function(t){n=[(t=t||[0,0,0])[0],t[1],t[2]||0]},this.update=function(t,e){var r=t.m_modelViewMatrix;if(t.m_modelViewAlignment){var i=t.m_modelViewAlignment;(r=r.slice?r.slice():Array.prototype.slice.call(r))[12]=Math.round(r[12]/i.roundx)*i.roundx+i.dx,r[13]=Math.round(r[13]/i.roundy)*i.roundy+i.dy}r=o.translate(o.create(),r,n),this.set(r)},this},i(r.modelViewOriginUniform,r.uniform),r.projectionUniform=function(t){"use strict";return this instanceof r.projectionUniform?(t||(t="projectionMatrix"),r.uniform.call(this,r.GL.FLOAT_MAT4,t),this.set(o.create()),this.update=function(t,e){this.set(t.m_projectionMatrix)},this):new r.projectionUniform(t)},i(r.projectionUniform,r.uniform),r.floatUniform=function(t,e){"use strict";if(!(this instanceof r.floatUniform))return new r.floatUniform(t,e);t||(t="floatUniform"),e=void 0===e?1:e,r.uniform.call(this,r.GL.FLOAT,t),this.set(e)},i(r.floatUniform,r.uniform)},4933:function(t,e,n){var r=n(698);r.vertexAttributeKeys={Position:0,Normal:1,TextureCoordinate:2,Color:3,Scalar:4,CountAttributeIndex:5},r.vertexAttributeKeysIndexed={Zero:0,One:1,Two:2,Three:3,Four:4,Five:5,Six:6,Seven:7,Eight:8,Nine:9},r.vertexAttribute=function(t){"use strict";if(!(this instanceof r.vertexAttribute))return new r.vertexAttribute(t);var e=t;this.name=function(){return e},this.bindVertexData=function(t,n){var r=t.m_mapper.geometryData().sourceData(n),i=t.m_material.shaderProgram();t.m_context.vertexAttribPointer(i.attributeLocation(e),r.attributeNumberOfComponents(n),r.attributeDataType(n),r.normalized(n),r.attributeStride(n),r.attributeOffset(n)),t.m_context.enableVertexAttribArray(i.attributeLocation(e))},this.undoBindVertexData=function(t,n){var r=t.m_material.shaderProgram();t.m_context.disableVertexAttribArray(r.attributeLocation(e))}}},698:function(t){t.exports={}},7205:function(t,e,n){var r=n(5616),i=n(698),o=n(4626);i.viewer=function(t,e){"use strict";if(!(this instanceof i.viewer))return new i.viewer(t,e);i.object.call(this);var n=t,o=i.renderer(e),a=i.renderWindow(n);return this.canvas=function(){return n},this.renderWindow=function(){return a},this.init=function(){null!==a?a._setup():console.log("[ERROR] No render window attached")},this.exit=function(t){null!==a?a._cleanup(t):console.log("[ERROR] No render window attached")},this.render=function(){a.render()},this.bindEventHandlers=function(){r(n).on("mousedown",this.handleMouseDown),r(n).on("mouseup",this.handleMouseUp),r(n).on("mousemove",this.handleMouseMove),r(n).on("mousewheel",this.handleMouseWheel),r(n).on("contextmenu",this.handleContextMenu)},this.unbindEventHandlers=function(){r(n).off("mousedown",this.handleMouseDown),r(n).off("mouseup",this.handleMouseUp),r(n).off("mousemove",this.handleMouseMove),r(n).off("mousewheel",this.handleMouseWheel),r(n).off("contextmenu",this.handleContextMenu)},this._init=function(){this.bindEventHandlers(),a.addRenderer(o)},this._init(),this},o(i.viewer,i.object)},394:function(t,e,n){t.exports={pointFeature:n(5380),vtkjsRenderer:n(9897)}},7015:function(t,e,n){var r=function(t){"use strict";if(!(this instanceof n(1338)))return new r(t);var e=this,i=this.draw;return this.draw=function(){return e.ready&&(e._update(),e.renderer()._render(),i()),e},this};t.exports=r},5380:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7541),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(5325),r=n(7015),i=n(9897).vtkjs,s=i.Rendering.Core.vtkActor,u=i.Common.Core.vtkDataArray,l=i.Rendering.Core.vtkGlyph3DMapper,c=i.Rendering.Core.vtkMapper,f=i.Common.DataModel.vtkPointSet,h=i.Filters.Sources.vtkSphereSource;r.call(this);var d,p,m,g,y,v=this,x=this._init,_=this._exit,b=this._update;return this._createPipeline=function(){p=f.newInstance(),(m=h.newInstance()).setThetaResolution(30),m.setPhiResolution(30);var t=l.newInstance({orient:!1,colorByArrayName:"color",scalarMode:c.ScalarMode.USE_POINT_FIELD_DATA,colorMode:c.ColorMode.DIRECT_SCALARS,scaling:!0,scaleArray:"diam",scaleMode:l.ScaleModes.SCALE_BY_MAGNITUDE});t.setInputData(p,0),t.setInputConnection(m.getOutputPort(),1),(d=s.newInstance()).setMapper(t),d.getProperty().setAmbient(1),v.renderer().contextRenderer().addActor(d)},this._init=function(){x.call(v,t),v.renderer().contextRenderer().setLayer(0),v._createPipeline()},this._build=function(){var t,n,r,i,o,a,s=v.data().length,l=new Array(3*s),c=v.data(),f=v.position(),h=v.style.get("radius"),d=v.style.get("fill"),m=v.style.get("fillColor"),x=v.style.get("fillOpacity"),_=v.layer().map().unitsPerPixel(v.layer().map().zoom());for(y&&y.length===s||(y=new Float32Array(s)),g&&g.length===4*s||(g=new Uint8Array(4*s)),t=n=r=0;t<s;t+=1,n+=3,r+=4)i=f(c[t],t),l[n]=i.x,l[n+1]=i.y,l[n+2]=i.z||0,a=a||l[n+2],y[t]=h(c[t],t)*_*2,o=m(c[t],t),g[r]=255*o.r,g[r+1]=255*o.g,g[r+2]=255*o.b,g[r+3]=d(c[t],t)?255*x(c[t],t):0;if(l=e.transformCoordinates(v.gcs(),v.layer().map().gcs(),l,3),!a&&v.gcs()!==v.layer().map().gcs())for(t=n=0;t<s;t+=1,n+=3)l[n+2]=0;p.getPoints().setData(l,3),p.getPointData().addArray(u.newInstance({name:"color",values:g,numberOfComponents:4})),p.getPointData().addArray(u.newInstance({name:"diam",values:y})),v.buildTime().modified()},this._update=function(){if(b.call(v),v.dataTime().getMTime()>=v.buildTime().getMTime()||v.updateTime().getMTime()<v.getMTime())v._build();else{var t=v.data(),e=v.style.get("radius"),n=v.layer().map().unitsPerPixel(v.layer().map().zoom()),r=p.getPointData().getArray("diam"),i=r.getData().map((function(r,i){return e(t[i],i)*n*2}));r.setData(i),p.modified()}v.updateTime().modified()},this._exit=function(){v.renderer().contextRenderer().removeActor(d),_()},v._init(),this};r(a,o);var s={};s[o.capabilities.stroke]=!1,i("vtkjs","point",a,s),t.exports=a},9897:function(t,e,n){var r=n(4626),i=n(1098).registerRenderer,o=n(2274),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(3503),r=n(6409),i=a.vtkjs.Rendering.Misc.vtkGenericRenderWindow,s=this,u=this._init,l=i.newInstance({background:[0,0,0,0]});l.setContainer(s.layer().node().get(0)),l.getInteractor().unbindEvents(),l.resize();var c=l.getRenderer(),f=l.getRenderWindow();return this.contextRenderer=function(){return c},this.api=function(){return a.apiname},this._init=function(){if(s.initialized())return s;u.call(s);var t=s.layer().map(),e=t.size();return s._resize(0,0,e.width,e.height),t.camera().clipbounds={near:-t.unitsPerPixel(),far:t.unitsPerPixel()},s},this._resize=function(t,e,n,r){return s._setWidthHeight(n,r),l.resize(),s._render(),s},this._render=function(){return s.layer().map().scheduleAnimationFrame(s._renderFrame,!0),s},this._renderFrame=function(){var t,e=s.layer().features();for(t=0;t<e.length;t+=1)e[t].visible()&&e[t]._update();s._updateRendererCamera(),f.render()},this._exit=function(){},this._updateRendererCamera=function(){var t=s.layer().map().camera(),n=t.view,r=t.projectionMatrix,i=e.create();e.copy(i,n);var o=e.create();e.copy(o,r),s.contextRenderer().getActiveCamera().setViewMatrix(i),s.contextRenderer().getActiveCamera().setProjectionMatrix(o)},s.layer().geoOn(r.pan,(function(t){s._render()})),s.layer().geoOn(r.parallelprojection,(function(t){})),this};a.apiname="vtkjs",r(a,o),i("vtkjs",a),a.supported=function(){delete a.vtkjs;try{a.vtkjs=n(4436)}catch(t){}return a.vtkjs&&a.vtkjs.Rendering||!window.vtk||!window.vtk.Rendering||(a.vtkjs=window.vtk),a.vtkjs&&a.vtkjs.Rendering||(a.vtkjs=void 0),void 0!==a.vtkjs},a.fallback=function(){return null},a.supported(),t.exports=a},3559:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3561),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=this,n=null,r=this._exit,i=this.draw,s=this._update;return this.draw=function(){if(e._update(),n)for(var t=0;t<n.length;t+=1)n[t].draw();return i(),e},this._build=function(){return e.buildTime().modified(),n=e.createChoropleth()},this._update=function(){s.call(e),(e.dataTime().timestamp()>=e.buildTime().timestamp()||e.updateTime().timestamp()<=e.timestamp())&&(e._wipePolygons(),e._build()),e.updateTime().modified()},this._wipePolygons=function(){n&&n.map((function(t){return t._exit()})),n=null},this._exit=function(){e._wipePolygons(),r()},this._init(t),this};r(a,o),i("webgl","choropleth",a),t.exports=a},6791:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6761),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t),n(2778).call(this,t);var e=this;return this._build=function(){e.actors()[0]&&e.renderer().contextRenderer().removeActor(e.actors()[0]),e.createGLMeshColored(e._createContours()),e.renderer().contextRenderer().addActor(e.actors()[0]),e.buildTime().modified()},this._init(t),this};r(a,o),i("webgl","contour",a),t.exports=a},8257:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2499),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t),n(2778).call(this,t);var e=this;return this._build=function(){e.actors()[0]&&e.renderer().contextRenderer().removeActor(e.actors()[0]),e.createGLMeshColored(e._createGrids()),e.renderer().contextRenderer().addActor(e.actors()[0]),e.buildTime().modified()},this._init(t),this};r(a,o),i("webgl","grid",a),t.exports=a},8635:function(t,e,n){t.exports={choroplethFeature:n(3559),contourFeature:n(6791),gridFeature:n(8257),isolineFeature:n(960),layer:n(6982),lineFeature:n(5795),lookupTable2D:n(411),markerFeature:n(3403),meshColored:n(2778),pixelmapFeature:n(7759),pointFeature:n(5407),polygonFeature:n(8511),quadFeature:n(9304),tileLayer:n(1474),trackFeature:n(536),webglRenderer:n(7945)}},960:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2586),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(4084).call(this),this._init(t),this):new a(t)};r(a,o),i("webgl","isoline",a),t.exports=a},6982:function(t,e,n){var r=function(){"use strict";var t=n(1098).createRenderer,e=n(6409),r=n(7945),i=n(9264),o=this,a=this._init,s=this.opacity,u=this.visible,l=this.zIndex;this.opacity=function(t){var e=s.apply(o,arguments);return void 0!==t&&o.initialized()&&o.map()._updateAutoshareRenderers(),e},this.visible=function(t){if(void 0===t)return u();var e=u(),n=u.apply(o,arguments);return e!==t&&o.initialized()&&(o.map().scheduleAnimationFrame(o._update,!0),o.renderer()._render()),n},this.zIndex=function(t,e){var n=l.apply(o,arguments);return void 0!==t&&o.initialized()&&(o.map().scheduleAnimationFrame(o._update,!0),o.renderer()._render(),o.map()._updateAutoshareRenderers()),n},this.switchRenderer=function(t,e){if(t instanceof r&&t!==o.renderer()){var n=o.renderer(),i=[],a=[];o.map().listSceneObjects([o]).forEach((function(t){t._cleanup&&(t._cleanup(),t._update&&a.push(t)),t.actors&&(i=i.concat(t.actors()))})),i.forEach((function(e){n.contextRenderer().removeActor(e),t.contextRenderer().addActor(e)})),o._renderer(t),o._canvas(t.canvas()),e&&(i.length||a.length)&&(n._render(),a.forEach((function(t){t._update()})),t._render())}return o},this._init=function(){var n=o.map();return n._updateAutoshareRenderers||(n._updateAutoshareRenderers=function(){var e,o,a,s=n.sortedLayers(),u=[];s.forEach((function(n){var s=n.autoshareRenderer(),l=n instanceof i;s&&n.renderer()&&n.renderer().api()===r.apiname?!e||n.opacity()!==o||"more"!==s&&(n.opacity()>0&&n.opacity()<1||l&&!a)?(n.node()[0].contains(n.renderer().canvas()[0])||(n.switchRenderer(t(r.apiname,n),!1),u.push(n.renderer())),e=n.renderer(),o=n.opacity(),a=l):(n.renderer()!==e&&(u.push(n.renderer()),n.switchRenderer(e,!1),u.push(n.renderer())),a&=l):e=null})),s.forEach((function(t){u.indexOf(t.renderer())>=0&&t._update&&t._update()})),s.forEach((function(t){u.indexOf(t.renderer())>=0&&(t.renderer()._renderFrame(),u=u.filter((function(e){return e!==t.renderer()})))})),u.forEach((function(t){t._exit()}))},n.geoOn(e.layerAdd,(function(){return n._updateAutoshareRenderers()})),n.geoOn(e.layerRemove,(function(){return n._updateAutoshareRenderers()}))),a.apply(o,arguments)}};(0,n(1098).registerLayerAdjustment)("webgl","all",r),t.exports=r},5795:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(9281),a=0,s=1,u=3,l={butt:0,square:1,round:2},c={passthrough:3,miter:4,bevel:5,round:6,"miter-clip":7},f={normal:0,debug:1},h=function(t){"use strict";if(!(this instanceof h))return new h(t);t=t||{},o.call(this,t);var e=n(1611),r=n(5325),i=n(642),d=n(4084),p=n(5685),m=n(1388),g=n(9336);d.call(this);var y,v,x,_,b,w,M,A,T,E,C,k=this,S=this._exit,O=void 0!==t.dynamicDraw&&t.dynamicDraw,P=this._init,L=this._update;return this.featureVertices=function(){return[[0,"corner",-1,a],[0,"near",1,s],[1,"far",-1,u],[1,"corner",1,a],[1,"near",-1,s],[0,"far",1,u]]},this.verticesPerFeature=function(){return k.featureVertices().length},this._init=function(t){var n,r=e.shaderProgram(),i=((n=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(g),n),o=function(t){var n=new e.shader(e.GL.FRAGMENT_SHADER);return n.setShaderSource(t?m:p),n}(void 0!==((t||{}).style||{}).debug),a=e.vertexAttribute("pos"),s=e.vertexAttribute("prev"),u=e.vertexAttribute("next"),l=e.vertexAttribute("far"),c=e.vertexAttribute("flags"),f=e.vertexAttribute("strokeWidth"),h=e.vertexAttribute("strokeColor"),d=e.vertexAttribute("strokeOpacity"),T=new e.projectionUniform("projectionMatrix"),E=e.geometryData(),S=e.sourceDataP3fv({name:"pos"}),L=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Four,{name:"prev"}),R=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Five,{name:"next"}),I=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Six,{name:"far"}),D=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Seven,{name:"flags"}),N=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.One,{name:"strokeWidth"}),F=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Two,{name:"strokeColor"}),j=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"strokeOpacity"}),z=e.triangles();return C=new e.modelViewOriginUniform("modelViewMatrix"),_=new e.floatUniform("pixelWidth",1/k.renderer().width()),b=new e.floatUniform("aspect",k.renderer().width()/k.renderer().height()),w=new e.floatUniform("miterLimit",10),M=new e.floatUniform("antialiasing",0),A=new e.floatUniform("fixedFlags",0),P.call(k,t),x=e.material(),v=e.mapper({dynamicDraw:O}),r.addVertexAttribute(a,e.vertexAttributeKeys.Position),r.addVertexAttribute(f,e.vertexAttributeKeysIndexed.One),r.addVertexAttribute(h,e.vertexAttributeKeysIndexed.Two),r.addVertexAttribute(d,e.vertexAttributeKeysIndexed.Three),r.addVertexAttribute(s,e.vertexAttributeKeysIndexed.Four),r.addVertexAttribute(u,e.vertexAttributeKeysIndexed.Five),r.addVertexAttribute(l,e.vertexAttributeKeysIndexed.Six),r.addVertexAttribute(c,e.vertexAttributeKeysIndexed.Seven),r.addUniform(C),r.addUniform(T),r.addUniform(_),r.addUniform(b),r.addUniform(w),r.addUniform(M),r.addUniform(A),r.addShader(o),r.addShader(i),x.addAttribute(r),x.addAttribute(e.blend()),(y=e.actor()).setMaterial(x),y.setMapper(v),E.addSource(S),E.addSource(L),E.addSource(R),E.addSource(I),E.addSource(N),E.addSource(F),E.addSource(j),E.addSource(D),z.setIndices(new Uint16Array(1)),E.addPrimitive(z),E.computeBounds=function(){E.setBounds(0,0,0,0,0,0)},v.setGeometryData(E),k},this.actors=function(){return y?[y]:[]},this._build=function(){return function(t){var e,n,o,a,s,u,h,d,p,m,g,y,x,_,b,S,O,P,L,R,I,D,N,F,j,z,B,V,q,G,U,H,W,X,K,Q,Y,$,Z,J,tt=k.data(),et=0,nt=[{strokeOffset:0,posStrokeOffset:0,negStrokeOffset:0},{strokeOffset:0,posStrokeOffset:0,negStrokeOffset:0}],rt=nt[1],it=k.gcs(),ot=k.layer().map().gcs(),at=k.line(),st=k.style.get("strokeWidth"),ut=k.style.get("strokeColor"),lt=k.style.get("strokeOpacity"),ct=k.style.get("lineCap"),ft=k.style.get("lineJoin"),ht=k.style.get("strokeOffset"),dt=k.style.get("miterLimit")(tt),pt=k.style.get("antialiasing")(tt)||0,mt=k.style.get("uniformLine"),gt=k.featureVertices(),yt=gt.length,vt=f[k.style.get("debug")(tt)?"debug":"normal"]||0,xt=v.geometryData(),_t=k.style.get("closed"),bt=!0;if(Z=i.isFunction(k.style("closed"))?void 0:_t()||!1,R=i.isFunction(k.style("lineCap"))?void 0:l[ct()||"butt"],I=i.isFunction(k.style("lineJoin"))?void 0:c[ft()||"miter"],P=i.isFunction(k.style("strokeColor"))?void 0:ut(),D=i.isFunction(k.style("strokeOffset"))?void 0:ht()||0,L=i.isFunction(k.style("strokeOpacity"))?void 0:lt(),O=i.isFunction(k.style("strokeWidth"))?void 0:st(),N=i.isFunction(k.style("uniformLine"))?void 0:mt(),void 0!==dt&&w.set(Math.max(1,Math.min(100,dt))),A.set(vt),M.set(pt),t)et=T.numSegments,J=T.closed,m=T.lineItemList,p=et*yt,bt=R!==T.lineCapVal||void 0===R||I!==T.lineJoinVal||void 0===I||D!==T.strokeOffsetVal||void 0===D;else{var wt=[],Mt=k.position();for(Mt=Mt===i.identityFunction?null:Mt,m=new Array(tt.length),J=new Array(tt.length),n=0;n<tt.length;n+=1)if(g=at(e=tt[n],n),m[n]=g,!(g.length<2)){for(et+=g.length-1,o=0;o<g.length;o+=1)x=Mt?Mt(g[o],o,e,n):g[o],wt.push(x.x),wt.push(x.y),wt.push(x.z||0),o||(b=x);g.length>2&&(void 0===Z?_t(e,n):Z)?x.x!==b.x||x.y!==b.y||x.z!==b.z?(et+=1,J[n]=2):J[n]=1:J[n]=0}if(wt=r.transformCoordinates(it,ot,wt,3),(E=new Float32Array(k.style.get("origin")(wt)))[0]||E[1]||E[2])for(n=0;n<wt.length;n+=3)wt[n]-=E[0],wt[n+1]-=E[1],wt[n+2]-=E[2];C.setOrigin(E),p=et*yt,q=i.getGeomBuffer(xt,"pos",3*p),G=i.getGeomBuffer(xt,"prev",3*p),U=i.getGeomBuffer(xt,"next",3*p),H=i.getGeomBuffer(xt,"far",3*p),xt.primitive(0).numberOfIndices()!==p&&(xt.primitive(0).numberOfIndices=function(){return p}),T={numSegments:et,closed:J,lineItemList:m,lineCapVal:R,lineJoinVal:I,strokeOffsetVal:D}}for(W=i.getGeomBuffer(xt,"flags",p),X=i.getGeomBuffer(xt,"strokeWidth",p),K=i.getGeomBuffer(xt,"strokeColor",3*p),Q=i.getGeomBuffer(xt,"strokeOpacity",p),n=_=Y=$=0;n<tt.length;n+=1)if(!((g=m[n]).length<2)){F=void 0===N?mt(g,n):N,e=tt[n],Z=J[n],S=_,d=g.length+(2===Z?1:0);var At=0;for(o=0;o<d;o+=1,_+=3)if(h=o,o===g.length&&(h=0,_-=3),y=g[h],o&&(rt=nt[0],nt[0]=nt[1],nt[1]=rt),t||(rt.pos=o===h?_:S,rt.prev=h?_-3:Z?S+3*(g.length-3+Z):_,rt.next=o+1<g.length?_+3:Z?o!==h?S+3:S+6-3*Z:_),F&&o>0?1===o&&(rt.strokeWidth=nt[0].strokeWidth,rt.strokeColor=nt[0].strokeColor,rt.strokeOpacity=nt[0].strokeOpacity):(rt.strokeWidth=void 0===O?st(y,h,e,n):O,rt.strokeColor=void 0===P?ut(y,h,e,n):P,rt.strokeOpacity=void 0===L?lt(y,h,e,n):L),bt&&(0!==D&&(F&&o>0?1===o&&(rt.strokeOffset=nt[0].strokeOffset):rt.strokeOffset=(void 0===D?ht(y,h,e,n):D)||0,rt.strokeOffset?(rt.posStrokeOffset=2047&Math.round(2048+1023*Math.min(1,Math.max(-1,rt.strokeOffset))),rt.negStrokeOffset=2047&Math.round(2048-1023*Math.min(1,Math.max(-1,rt.strokeOffset)))):rt.posStrokeOffset=rt.negStrokeOffset=0),Z||o&&o!==g.length-1?rt.flags=void 0===I?c[ft(y,h,e,n)]||c.miter:I:rt.flags=void 0===R?l[ct(y,h,e,n)]||l.butt:R),o){if("drop"===F&&o>1&&wt[nt[0].pos]===wt[nt[1].pos]&&wt[nt[0].pos+1]===wt[nt[1].pos+1]){At+=1;continue}for(a=0;a<yt;a+=1,Y+=1,$+=3)"drop"===F&&nt[0].strokeOpacity<=0&&nt[1].strokeOpacity<=0?Q[Y]=-1:(s=nt[j=gt[a][0]],u=nt[1-j],t||(q[$]=wt[s.pos],q[$+1]=wt[s.pos+1],q[$+2]=0,z=j?"next":"prev",B=j?"prev":"next",G[$]=wt[s[z]],G[$+1]=wt[s[z]+1],G[$+2]=0,U[$]=wt[s[B]],U[$+1]=wt[s[B]+1],U[$+2]=0,H[$]=wt[u[B]],H[$+1]=wt[u[B]+1],H[$+2]=0),bt&&(V=j?"posStrokeOffset":"negStrokeOffset",W[Y]=gt[a][3]+4*s.flags+32*u.flags+256*s[V]),X[Y]=s.strokeWidth,K[$]=s.strokeColor.r,K[$+1]=s.strokeColor.g,K[$+2]=s.strokeColor.b,s.strokeOpacity<=0&&u.strokeOpacity<=0||s.strokeWidth<=0&&u.strokeWidth<=0?Q[Y]=-1:Q[Y]=s.strokeOpacity)}if(At)for(a=0;a<At*yt;a+=1,Y+=1,$+=3)Q[Y]=-1}t?(bt&&v.updateSourceBuffer("flags"),v.updateSourceBuffer("strokeWidth"),v.updateSourceBuffer("strokeOpacity"),v.updateSourceBuffer("strokeColor")):(v.modified(),xt.boundsDirty(!0),v.boundsDirtyTimestamp().modified())}(!!(k.dataTime().timestamp()<k.buildTime().timestamp()&&T)),k.renderer().contextRenderer().hasActor(y)||k.renderer().contextRenderer().addActor(y),k.buildTime().modified(),k},this._update=function(){return L.call(k),(k.dataTime().timestamp()>=k.buildTime().timestamp()||k.updateTime().timestamp()<=k.timestamp())&&k._build(),_.set(1/k.renderer().width()),b.set(k.renderer().width()/k.renderer().height()),y.setVisible(k.visible()),y.material().setBinNumber(k.bin()),k.updateTime().modified(),k},this._exit=function(){k.renderer().contextRenderer().removeActor(y),y=null,S()},this._init(t),this};r(h,o);var d={};d[o.capabilities.basic]=!0,d[o.capabilities.multicolor]=!0,i("webgl","line",h,d),t.exports=h},411:function(t,e,n){var r=n(4626),i=n(77),o=n(1611);var a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.texture.call(this);var e,n=i(),r=t.maxWidth||4096,s=new Uint8Array([0,0,0,0]),u=this;return this.setup=function(t){!function(t,e){if(!(e>=0&&e<=31))throw Error("[error] Texture unit "+e+" is not supported");t.m_context.activeTexture(o.GL.TEXTURE0+e)}(t,u.textureUnit()),t.m_context.deleteTexture(u.m_textureHandle),u.m_textureHandle=t.m_context.createTexture(),t.m_context.bindTexture(o.GL.TEXTURE_2D,u.m_textureHandle),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_MIN_FILTER,o.GL.NEAREST),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_MAG_FILTER,o.GL.NEAREST),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_WRAP_S,o.GL.CLAMP_TO_EDGE),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_WRAP_T,o.GL.CLAMP_TO_EDGE),t.m_context.pixelStorei(o.GL.UNPACK_ALIGNMENT,1),t.m_context.pixelStorei(o.GL.UNPACK_FLIP_Y_WEBGL,!0),t.m_context.texImage2D(o.GL.TEXTURE_2D,0,o.GL.RGBA,u.width,u.height,0,o.GL.RGBA,o.GL.UNSIGNED_BYTE,s),t.m_context.bindTexture(o.GL.TEXTURE_2D,null),n.modified()},this.colorTable=function(t){return void 0===t?e:(e=t,t.length<4&&(t=[0,0,0,0]),u.width=Math.min(r,t.length/4),u.height=Math.ceil(t.length/4/r),t instanceof Uint8Array&&t.length===u.width*u.height*4?s=t:(t.length<u.width*u.height*4&&(t=t.concat(new Array(u.width*u.height*4-t.length).fill(0))),s=new Uint8Array(t)),u.modified(),u)},this.maxWidth=function(){return r},this.colorTable(t.colorTable||[]),this};r(a,o.texture),t.exports=a},3403:function(t,e,n){var r=n(5616),i=n(4626),o=n(1098).registerFeature,a=n(2225),s=n(7945),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},a.call(this,t);var e=n(1611),i=n(5325),o=n(642),l=n(4084),c=n(2709),f=n(6409),h=n(9923),d=n(3724),p=n(1202),m=n(7665);l.call(this);var g,y,v=this,x=this._exit,_=null,b=null,w={},M=this._init,A=this._update,T=this.updateStyleFromArray;function E(t){var e,n,r,u,l,c,f,h,d,p,m,x,w,M=v.data().length,A=v._pointPolygon(0,0,1,1),T=new Array(3*M),C={},k={},S={},O={},P={radius:1,fillColor:3,fillOpacity:1,strokeColor:3,strokeOpacity:1,strokeOffset:0,strokeWidth:1,symbol:1,symbolValue:1,rotation:1,scaleWithZoom:0,rotateWithMap:0,radiusIncludesStroke:0},L=v.verticesPerFeature(),R=v.data(),I=b.geometryData();for(var D in l=v.position(),P)S[D]=v.style.get(D),o.isFunction(v.style(D))||(O[D]=S[D]()),P[D]&&(C[D]=o.getGeomBuffer(I,D,L*M*P[D]));if(!t){for(e=x=0;e<M;e+=1,x+=3)u=l(R[e],e),T[x]=u.x,T[x+1]=u.y,T[x+2]=0;if(T=i.transformCoordinates(v.gcs(),v.layer().map().gcs(),T,3),(y=new Float32Array(v.style.get("origin")(T)))[0]||y[1]||y[2])for(e=x=0;e<M;e+=1,x+=3)T[x]-=y[0],T[x+1]-=y[1],T[x+2]-=y[2];g.setOrigin(y),r=o.getGeomBuffer(I,"pos",L*M*3),v._primitiveShape!==a.primitiveShapes.sprite&&(f=o.getGeomBuffer(I,"unit",L*M*2)),(c=I.primitive(0).indices())instanceof Uint16Array&&c.length===L*M||(c=new Uint16Array(L*M),I.primitive(0).setIndices(c))}for(e=d=p=m=x=0;e<M;e+=1,x+=3){if(h=R[e],!t&&v._primitiveShape!==a.primitiveShapes.sprite)for(n=0;n<A.length;n+=1,m+=1)f[m]=A[n];for(var N in P)k[N]=void 0===O[N]?S[N](h,e):O[N];for(k.scaleWithZoom=a.scaleMode[k.scaleWithZoom]||(k.scaleWithZoom>=1&&k.scaleWithZoom<=3?k.scaleWithZoom:0),k.symbolComputed=k.scaleWithZoom+(k.rotateWithMap?4:0)+16*(Math.sign(void 0!==k.radiusIncludesStroke&&k.radiusIncludesStroke?k.strokeOffset:1)+1)+64*k.symbol,k.symbolValue&&k.symbol>=a.symbols.arrow&&k.symbol<a.symbols.arrow+a.symbols.arrowMax&&(k.symbolValue=(w=k.symbolValue).length?((void 0===w[0]?0:Math.floor(250*Math.abs(w[0]))+1)+252*(void 0===w[1]?0:Math.floor(250*Math.abs(w[1]))+1)+252*(void 0===w[2]?0:Math.floor(250*Math.abs(w[2]))+1)*252)*(w[3]?-1:1):void 0===w?0:Math.floor(250*Math.abs(w))+1),n=0;n<L;n+=1,d+=1,p+=3)t||(r[p]=T[x],r[p+1]=T[x+1],r[p+2]=T[x+2]),C.radius[d]=k.radius,C.fillColor[p]=k.fillColor.r,C.fillColor[p+1]=k.fillColor.g,C.fillColor[p+2]=k.fillColor.b,C.fillOpacity[d]=k.fillOpacity,C.strokeColor[p]=k.strokeColor.r,C.strokeColor[p+1]=k.strokeColor.g,C.strokeColor[p+2]=k.strokeColor.b,C.strokeOpacity[d]=k.strokeOpacity,C.strokeWidth[d]=k.strokeWidth,C.symbol[d]=k.symbolComputed,C.symbolValue[d]=k.symbolValue,C.rotation[d]=k.rotation}if(v._primitiveShapeAuto){var F=v._approximateMaxRadius(v.renderer().map().zoom());if(v._primitiveShape===a.primitiveShapes.sprite&&F>s._maxPointSize||v._primitiveShape!==a.primitiveShapes.sprite&&F<=s._maxPointSize)return v._primitiveShape=F>s._maxPointSize?a.primitiveShapes.triangle:a.primitiveShapes.sprite,v.renderer().contextRenderer().removeActor(_),_=null,v._init(!0),void E()}t?Object.keys(C).forEach((function(t){return b.updateSourceBuffer(t)})):(I.boundsDirty(!0),b.modified(),b.boundsDirtyTimestamp().modified())}return c(v,t),this.actors=function(){return _?[_]:[]},this.updateStyleFromArray=function(t,e,n){var i,o,a={fillColor:3,fillOpacity:1,radius:1,strokeColor:3,strokeOpacity:1,strokeWidth:1,symbolComputed:1,symbolValueComputed:1};if("string"==typeof t){var s={};s[t]=e,t=s}return r.each(t,(function(t,e){var n,r,s,u,l,c,f,h,d,p;if(v.visible()&&_&&a[t]&&!i&&!v.clustering())if(d=a[t],u=v.data().length,p="symbolComputed"===t?"symbol":"symbolValueComputed"===t?"symbolValue":t,s=(r=_.mapper()).getSourceBuffer(p),n=v.verticesPerFeature(),s&&u&&u*n*d===s.length){switch(a[t]){case 1:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=1)s[h]=l;break;case 3:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=3)s[h]=l.r,s[h+1]=l.g,s[h+2]=l.b}r.updateSourceBuffer(p),o=!0}else i=!0;else i=!0;if(t===p){var m=v.modified;i||(v.modified=function(){}),T(t,e,!1),v.modified=m}})),n&&(v.visible()&&i?v.draw():o&&v.renderer()._render()),v},this._handleZoom=function(t){v._primitiveShapeAuto&&v._primitiveShape===a.primitiveShapes.sprite&&v._approximateMaxRadius(t)>s._maxPointSize&&(v._primitiveShape=a.primitiveShapes.triangle,v.renderer().contextRenderer().removeActor(v.actors()[0]),v._init(!0),v.dataTime().modified(),v.draw())},this._init=function(n){var r,i,o=e.shaderProgram(),s=((i=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(v._primitiveShape===a.primitiveShapes.sprite?m:p),i),u=function(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(v._primitiveShape===a.primitiveShapes.sprite?d:h),t}(),l=e.material(),c=e.blend(),x=e.geometryData(),A=e.sourceDataP3fv({name:"pos"}),T={radius:1,fillColor:3,fillOpacity:1,strokeColor:3,strokeOpacity:1,strokeWidth:1,symbol:1,symbolValue:1,rotation:1},E={pixelWidth:e.GL.FLOAT,aspect:e.GL.FLOAT,zoom:e.GL.FLOAT,rotationUniform:e.GL.FLOAT},C=new e.projectionUniform("projectionMatrix");g=new e.modelViewOriginUniform("modelViewMatrix",y),v._primitiveShape===a.primitiveShapes.sprite?r=new e.points:(r=new e.triangles,T.unit=2),r.setIndices(new Uint16Array),n||M.call(v,t),b=e.mapper(),o.addVertexAttribute(e.vertexAttribute("pos"),e.vertexAttributeKeys.Position),x.addSource(A),Object.keys(T).forEach((function(t,n){o.addVertexAttribute(e.vertexAttribute(t),n+1),x.addSource(e.sourceDataAnyfv(T[t],n+1,{name:t}))})),w={},Object.keys(E).forEach((function(t){w[t]=new e.uniform(E[t],t),o.addUniform(w[t])})),o.addUniform(g),o.addUniform(C),o.addShader(u),o.addShader(s),l.addAttribute(o),l.addAttribute(c),(_=e.actor()).setMaterial(l),_.setMapper(b),x.addPrimitive(r),x.computeBounds=function(){x.setBounds(0,0,0,0,0,0)},b.setGeometryData(x),n||v.geoOn(f.zoom,(function(t){v._handleZoom(t.zoomLevel)}))},this._build=function(){return E(v.dataTime().timestamp()<v.buildTime().timestamp()),v.renderer().contextRenderer().hasActor(_)||v.renderer().contextRenderer().addActor(_),v.buildTime().modified(),v},this._update=function(){return A.call(v),(v.dataTime().timestamp()>=v.buildTime().timestamp()||v.updateTime().timestamp()<v.timestamp())&&v._build(),w.pixelWidth.set(2/v.renderer().width()),w.aspect.set(v.renderer().width()/v.renderer().height()),w.zoom.set(v.renderer().map().zoom()),w.rotationUniform.set(v.renderer().map().rotation()),_.setVisible(v.visible()),_.material().setBinNumber(v.bin()),v.updateTime().modified(),v},this._exit=function(){v.renderer().contextRenderer().removeActor(_),_=null,w={},x()},v._init(),this};i(u,a);o("webgl","marker",u,{}),t.exports=u},2778:function(t,e,n){t.exports=function(t){"use strict";t=t||{};var e=n(1611),r=n(5325),i=n(642),o=n(428),a=n(4993);n(4084).call(this);var s,u,l=this,c=this._exit,f=null,h=null,d=null,p=null,m=null,g=null,y=null,v=null,x=void 0!==t.dynamicDraw&&t.dynamicDraw,_=this._init,b=this._update;function w(){var t=new e.shader(e.GL.VERTEX_SHADER);return t.setShaderSource(a),t}function M(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(o),t}return this.createGLMeshColored=function(t){var e,n,o,a,c,f,d,x,_,b=t.elements.length,w=[],M=h.geometryData();for(m.set([t.minColor.r,t.minColor.g,t.minColor.b,t.minColor.a]),g.set([t.maxColor.r,t.maxColor.g,t.maxColor.b,t.maxColor.a]),y.set(t.colorMap.length),v.set(t.stepped),e=-1;e<t.colorMap.length+1;e+=1)o=Math.max(0,Math.min(t.colorMap.length-1,e)),w.push(255*t.colorMap[o].r),w.push(255*t.colorMap[o].g),w.push(255*t.colorMap[o].b),w.push(255*t.colorMap[o].a);if(p.setColorTable(w),t.pos=r.transformCoordinates(l.gcs(),l.layer().map().gcs(),t.pos,3),(s=new Float32Array(l.style.get("origin")(t.pos)))[0]||s[1]||s[2])for(e=0;e<t.pos.length;e+=3)t.pos[e]-=s[0],t.pos[e+1]-=s[1],t.pos[e+2]-=s[2];for(u.setOrigin(s),f=i.getGeomBuffer(M,"pos",3*b),d=i.getGeomBuffer(M,"opacity",b),x=i.getGeomBuffer(M,"value",b),e=n=0;e<b;e+=1,n+=3)a=3*(o=t.elements[e]),f[n]=t.pos[a],f[n+1]=t.pos[a+1],f[n+2]=t.pos[a+2],c=t.elementValues?Math.floor(e/3):o,d[e]=t.opacity[c],x[e]=t.value[c];(_=M.primitive(0).indices())instanceof Uint16Array&&_.length===b||(_=new Uint16Array(b),M.primitive(0).setIndices(_)),M.boundsDirty(!0),h.modified(),h.boundsDirtyTimestamp().modified()},this._init=function(t){var n=e.blend(),r=e.shaderProgram(),i=e.material(),o=e.lookupTable(),a=e.geometryData(),s=new e.projectionUniform("projectionMatrix"),c=new e.uniform(e.GL.INT,"sampler2d"),b=w(),A=M(),T=e.vertexAttribute("pos"),E=e.vertexAttribute("value"),C=e.vertexAttribute("opacity"),k=e.sourceDataP3fv({name:"pos"}),S=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.One,{name:"value"}),O=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Two,{name:"opacity"}),P=new e.triangles;u=new e.modelViewOriginUniform("modelViewMatrix"),_.call(l,t),h=e.mapper({dynamicDraw:x}),r.addVertexAttribute(T,e.vertexAttributeKeys.Position),r.addVertexAttribute(E,e.vertexAttributeKeysIndexed.One),r.addVertexAttribute(C,e.vertexAttributeKeysIndexed.Two),r.addUniform(u),r.addUniform(s),m=new e.uniform(e.GL.FLOAT_VEC4,"minColor"),r.addUniform(m),g=new e.uniform(e.GL.FLOAT_VEC4,"maxColor"),r.addUniform(g),y=new e.uniform(e.GL.FLOAT,"steps"),r.addUniform(y),v=new e.uniform(e.GL.BOOL,"stepped"),r.addUniform(v),r.addShader(A),r.addShader(b),r.addUniform(c),o.setTextureUnit(7),c.set(7),(d=i).addAttribute(r),d.addAttribute(n),p=o,d.addAttribute(p),(f=e.actor()).setMaterial(d),f.setMapper(h),a.addSource(k),a.addSource(S),a.addSource(O),a.addPrimitive(P),a.computeBounds=function(){a.setBounds(0,0,0,0,0,0)},h.setGeometryData(a)},this.actors=function(){return f?[f]:[]},this._update=function(){b.call(l),(l.dataTime().timestamp()>=l.buildTime().timestamp()||l.updateTime().timestamp()<=l.timestamp())&&l._build(),f.setVisible(l.visible()),f.material().setBinNumber(l.bin()),l.updateTime().modified()},this._exit=function(){l.renderer().contextRenderer().removeActor(f),c()},this}},4084:function(t,e,n){var r=function(t){"use strict";if(!(this instanceof n(1338)))return new r(t);var e=this,i=this.draw;if(this.draw=function(){return e.ready&&(e._update({mayDelay:!0}),e.renderer()._render(),i()),e},this.bin){var o=this.bin;this.bin=function(t,n){if(void 0===t&&!n&&null===o(void 0,!0)){var r=e.layer&&e.layer(),i=r&&r.map&&r.map(),a=(i&&i.listSceneObjects()||[]).indexOf(e);if(a>=0)return a}return o.apply(e,arguments)}}return this};t.exports=r},7759:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7761),a=n(411),s=n(642),u=function(t){"use strict";if(!(this instanceof u))return new u(t);o.call(this,t),n(4084).call(this);var e,r,i,l=n(1611),c=n(3925),f=this._exit,h=this;return this.pointSearch=function(t,n){if(e&&h.m_info)for(var r=e.pointSearch(t,n),i=r.index.length-1;i>=0;i-=1)if(r.extra[r.index[i]]._quad&&r.extra[r.index[i]]._quad.image){var o=r.extra[r.index[i]]._quad.image,a=r.extra[r.index[i]].basis,s=Math.floor(a.x*o.width),u=Math.floor(a.y*o.height),l=document.createElement("canvas");l.width=l.height=1;var c=l.getContext("2d");c.drawImage(o,s,u,1,1,0,0,1,1);var f=c.getImageData(0,0,1,1).data,d=f[0]+256*f[1]+256*f[2]*256;return r={index:[d],found:[h.data()[d]]}}return{index:[],found:[]}},this._computePixelmap=function(){var t=h.data()||[],n=h.style.get("color"),o=h.indexModified(void 0,"clear"),u=h.dataTime().timestamp()>=h.buildTime().timestamp()||void 0===o;i||((i=a()).setTextureUnit(1),u=!0);var f,d=Math.max(1,t.length),p=i.maxWidth();d>p&&d%p&&(d+=p-d%p),u||(u=(f=i.colorTable()).length!==4*d,o[0]=Math.max(0,o[0]),o[1]=Math.min(t.length,o[1]+1)),u&&(f=new Uint8Array(4*d),o=[0,t.length]);for(var m=o[0];m<o[1];m+=1){var g=t[m],y=s.convertColor(n.call(h,g,m));f[4*m]=255*y.r,f[4*m+1]=255*y.g,f[4*m+2]=255*y.b,f[4*m+3]=void 0===y.a?255:255*y.a}h.m_info={colors:f};var v=i.colorTable();if(v&&v.length===f.length){for(var x=4*o[0];x<4*o[1]&&f[x]===v[x];x+=1);if(x===4*o[1])return}i.colorTable(f),e||(e=h.layer().createFeature("quad",{selectionAPI:!1,gcs:h.gcs(),visible:h.visible(void 0,!0),nearestPixel:!0}),r=!1),r||(h.dependentFeatures([e]),e.setShader("image_fragment",c),e._hookBuild=function(t){var e=new l.uniform(l.GL.INT,"lutSampler");e.set(i.textureUnit()),t.addUniform(e);var n=new l.uniform(l.GL.INT,"lutWidth");n.set(i.width),t.addUniform(n);var r=new l.uniform(l.GL.INT,"lutHeight");r.set(i.height),t.addUniform(r)},e._hookRenderImageQuads=function(t,e){i.bind(t,e)},!1===r&&e.style({image:h.m_srcImage,position:h.style.get("position")}).data([{}]).draw(),r=!0)},this._exit=function(){return e&&h.layer()&&(h.layer().deleteFeature(e),e=null,h.dependentFeatures([])),f(),h},t.quadFeature&&(e=t.quadFeature).nearestPixel&&e.nearestPixel(!0),this._init(t),this};r(u,o);var l={};l[o.capabilities.lookup]=!0,i("webgl","pixelmap",u,l),t.exports=u},5407:function(t,e,n){var r=n(5616),i=n(4626),o=n(1098).registerFeature,a=n(7541),s=n(7945),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},a.call(this,t);var e=n(1611),i=n(5325),o=n(642),l=n(4084),c=n(2709),f=n(4317),h=n(2682),d=n(8208),p=n(6979);l.call(this);var m,g,y=this,v=this._exit,x=null,_=null,b=null,w=null,M=void 0!==t.dynamicDraw&&t.dynamicDraw,A=this._init,T=this._update,E=this.updateStyleFromArray;function C(t){var e,n,r,u,l,c,f,h,d,p,v,b,w,M,A,T,E,k,S,O,P,L,R,I,D,N,F,j,z,B,V,q,G,U,H,W,X=y.data().length,K=y._pointPolygon(0,0,1,1),Q=new Array(3*X),Y=y.verticesPerFeature(),$=y.data(),Z=0,J=_.geometryData();if(l=y.position(),p=y.style.get("radius"),w=y.style.get("stroke"),T=y.style.get("strokeWidth"),S=y.style.get("strokeOpacity"),L=y.style.get("strokeColor"),D=y.style.get("fill"),j=y.style.get("fillOpacity"),V=y.style.get("fillColor"),!t){for(e=W=0;e<X;e+=1,W+=3)u=l($[e],e),Q[W]=u.x,Q[W+1]=u.y,Q[W+2]=0;if(Q=i.transformCoordinates(y.gcs(),y.layer().map().gcs(),Q,3),(g=new Float32Array(y.style.get("origin")(Q)))[0]||g[1]||g[2])for(e=W=0;e<X;e+=1,W+=3)Q[W]-=g[0],Q[W+1]-=g[1],Q[W+2]-=g[2];m.setOrigin(g),r=o.getGeomBuffer(J,"pos",Y*X*3),c=o.getGeomBuffer(J,"unit",Y*X*2),(f=J.primitive(0).indices())instanceof Uint16Array&&f.length===Y*X||(f=new Uint16Array(Y*X),J.primitive(0).setIndices(f))}for(h=o.getGeomBuffer(J,"radius",Y*X),v=o.getGeomBuffer(J,"stroke",Y*X),M=o.getGeomBuffer(J,"strokeWidth",Y*X),E=o.getGeomBuffer(J,"strokeOpacity",Y*X),O=o.getGeomBuffer(J,"strokeColor",Y*X*3),R=o.getGeomBuffer(J,"fill",Y*X),N=o.getGeomBuffer(J,"fillOpacity",Y*X),z=o.getGeomBuffer(J,"fillColor",Y*X*3),e=G=U=H=W=0;e<X;e+=1,W+=3){if(q=$[e],!t&&y._primitiveShape!==a.primitiveShapes.sprite)for(n=0;n<K.length;n+=1,H+=1)c[H]=K[n];for(d=p(q,e),b=w(q,e)?1:0,A=T(q,e),k=S(q,e),P=L(q,e),I=D(q,e)?1:0,F=j(q,e),B=V(q,e),y._primitiveShapeAuto&&(I&&F||b&&k)&&d+(b&&k?A:0)>Z&&(Z=d+(b&&k?A:0)),n=0;n<Y;n+=1,G+=1,U+=3)t||(r[U]=Q[W],r[U+1]=Q[W+1],r[U+2]=Q[W+2]),h[G]=d,v[G]=b,M[G]=A,E[G]=k,O[U]=P.r,O[U+1]=P.g,O[U+2]=P.b,R[G]=I,N[G]=F,z[U]=B.r,z[U+1]=B.g,z[U+2]=B.b}if(y._primitiveShapeAuto&&(y._primitiveShape===a.primitiveShapes.sprite&&Z>s._maxPointSize||y._primitiveShape!==a.primitiveShapes.sprite&&Z<=s._maxPointSize))return y._primitiveShape=Z>s._maxPointSize?a.primitiveShapes.triangle:a.primitiveShapes.sprite,y.renderer().contextRenderer().removeActor(x),x=null,y._init(!0),void C();t?(_.updateSourceBuffer("radius"),_.updateSourceBuffer("stroke"),_.updateSourceBuffer("strokeWidth"),_.updateSourceBuffer("strokeColor"),_.updateSourceBuffer("strokeOpacity"),_.updateSourceBuffer("fill"),_.updateSourceBuffer("fillColor"),_.updateSourceBuffer("fillOpacity")):(J.boundsDirty(!0),_.modified(),_.boundsDirtyTimestamp().modified())}return c(y,t),this.actors=function(){return x?[x]:[]},this.updateStyleFromArray=function(t,e,n){var i,o,a={fill:"bool",fillColor:3,fillOpacity:1,radius:1,stroke:"bool",strokeColor:3,strokeOpacity:1,strokeWidth:1};if("string"==typeof t){var s={};s[t]=e,t=s}return r.each(t,(function(t,e){var n,r,s,u,l,c,f,h,d;if(y.visible()&&x&&a[t]&&!i&&!y.clustering())if(d="bool"===a[t]?1:a[t],u=y.data().length,s=(r=x.mapper()).getSourceBuffer(t),n=y.verticesPerFeature(),s&&u&&u*n*d===s.length){switch(a[t]){case 1:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=1)s[h]=l;break;case 3:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=3)s[h]=l.r,s[h+1]=l.g,s[h+2]=l.b;break;case"bool":for(c=0,h=0;c<u;c+=1)for(l=e[c]?1:0,f=0;f<n;f+=1,h+=1)s[h]=l}r.updateSourceBuffer(t),o=!0}else i=!0;else i=!0;var p=y.modified;i||(y.modified=function(){}),E(t,e,!1),y.modified=p})),n&&(y.visible()&&i?y.draw():o&&y.renderer()._render()),y},this._init=function(n){var r,i,o=e.shaderProgram(),s=((i=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(y._primitiveShape===a.primitiveShapes.sprite?p:d),i),u=function(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(y._primitiveShape===a.primitiveShapes.sprite?h:f),t}(),l=e.vertexAttribute("pos"),c=e.vertexAttribute("unit"),v=e.vertexAttribute("radius"),T=e.vertexAttribute("strokeWidth"),E=e.vertexAttribute("fillColor"),C=e.vertexAttribute("fill"),k=e.vertexAttribute("strokeColor"),S=e.vertexAttribute("stroke"),O=e.vertexAttribute("fillOpacity"),P=e.vertexAttribute("strokeOpacity"),L=new e.projectionUniform("projectionMatrix"),R=e.material(),I=e.blend(),D=e.geometryData(),N=e.sourceDataP3fv({name:"pos"}),F=e.sourceDataAnyfv(2,e.vertexAttributeKeysIndexed.One,{name:"unit"}),j=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Two,{name:"radius"}),z=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"strokeWidth"}),B=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Four,{name:"fillColor"}),V=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Five,{name:"fill"}),q=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Six,{name:"strokeColor"}),G=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Seven,{name:"stroke"}),U=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Eight,{name:"fillOpacity"}),H=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Nine,{name:"strokeOpacity"});m=new e.modelViewOriginUniform("modelViewMatrix",g),(r=y._primitiveShape===a.primitiveShapes.sprite?new e.points:new e.triangles).setIndices(new Uint16Array),b=new e.floatUniform("pixelWidth",2/y.renderer().width()),w=new e.floatUniform("aspect",y.renderer().width()/y.renderer().height()),n||A.call(y,t),_=e.mapper({dynamicDraw:M}),o.addVertexAttribute(l,e.vertexAttributeKeys.Position),y._primitiveShape!==a.primitiveShapes.sprite&&o.addVertexAttribute(c,e.vertexAttributeKeysIndexed.One),o.addVertexAttribute(v,e.vertexAttributeKeysIndexed.Two),o.addVertexAttribute(T,e.vertexAttributeKeysIndexed.Three),o.addVertexAttribute(E,e.vertexAttributeKeysIndexed.Four),o.addVertexAttribute(C,e.vertexAttributeKeysIndexed.Five),o.addVertexAttribute(k,e.vertexAttributeKeysIndexed.Six),o.addVertexAttribute(S,e.vertexAttributeKeysIndexed.Seven),o.addVertexAttribute(O,e.vertexAttributeKeysIndexed.Eight),o.addVertexAttribute(P,e.vertexAttributeKeysIndexed.Nine),o.addUniform(b),o.addUniform(w),o.addUniform(m),o.addUniform(L),o.addShader(u),o.addShader(s),R.addAttribute(o),R.addAttribute(I),(x=e.actor()).setMaterial(R),x.setMapper(_),D.addSource(N),D.addSource(F),D.addSource(j),D.addSource(z),D.addSource(B),D.addSource(V),D.addSource(q),D.addSource(G),D.addSource(U),D.addSource(H),D.addPrimitive(r),D.computeBounds=function(){D.setBounds(0,0,0,0,0,0)},_.setGeometryData(D)},this._build=function(){return C(y.dataTime().timestamp()<y.buildTime().timestamp()),y.renderer().contextRenderer().hasActor(x)||y.renderer().contextRenderer().addActor(x),y.buildTime().modified(),y},this._update=function(){return T.call(y),(y.dataTime().timestamp()>=y.buildTime().timestamp()||y.updateTime().timestamp()<y.timestamp())&&y._build(),b.set(2/y.renderer().width()),w.set(y.renderer().width()/y.renderer().height()),x.setVisible(y.visible()),x.material().setBinNumber(y.bin()),y.updateTime().modified(),y},this._exit=function(){y.renderer().contextRenderer().removeActor(x),x=null,v()},y._init(),this};i(u,a);var l={};l[a.capabilities.stroke]=!0,o("webgl","point",u,l),t.exports=u},2709:function(t,e,n){var r=n(7541);t.exports=function(t,e){e=e||{},t._primitiveShapeAuto=!0,t._primitiveShape=r.primitiveShapes.auto,void 0!==r.primitiveShapes[e.primitiveShape]&&(t._primitiveShape=e.primitiveShape),t._primitiveShapeAuto=t._primitiveShape===r.primitiveShapes.auto,t._primitiveShapeAuto&&(t._primitiveShape=r.primitiveShapes.sprite,t._primitiveShapeAuto=!0),t._pointPolygon=function(e,n,i,o){var a;switch(t._primitiveShape){case r.primitiveShapes.triangle:a=[e,n-2*o,e-i*Math.sqrt(3),n+o,e+i*Math.sqrt(3),n+o];break;case r.primitiveShapes.square:a=[e-i,n+o,e-i,n-o,e+i,n+o,e-i,n-o,e+i,n-o,e+i,n+o];break;default:a=[e,n]}return a},t.verticesPerFeature=function(){return t._pointPolygon(0,0,1,1).length/2},t.primitiveShape=function(e,n){if(void 0===e)return n||!t._primitiveShapeAuto?t._primitiveShape:r.primitiveShapes.auto;if(void 0!==r.primitiveShapes[e]){var i=!1;e===r.primitiveShapes.auto?(i=!t._primitiveShapeAuto,t._primitiveShapeAuto=!0):(i=t._primitiveShapeAuto||t._primitiveShape!==e,t._primitiveShapeAuto=!1,t._primitiveShape=e),i&&(t.renderer().contextRenderer().removeActor(t.actors()[0]),t._init(!0),t.dataTime().modified())}return t}}},8511:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6645),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(1611),r=n(9747);r=r.__esModule?r.default:r;var i=n(5325),s=n(642),u=n(4084),l=n(4547),c=n(9506);u.call(this);var f,h,d,p,m,g=this,y=this._exit,v=e.actor(),x=e.mapper(),_=e.material(),b=this._init,w=this._update;function M(){var t=new e.shader(e.GL.VERTEX_SHADER);return t.setShaderSource(c),t}function A(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(l),t}return this._init=function(t){var n=e.shaderProgram(),r=e.vertexAttribute("pos"),i=e.vertexAttribute("fillColor"),o=e.vertexAttribute("fillOpacity"),a=new e.projectionUniform("projectionMatrix"),s=M(),u=A(),l=e.blend(),c=e.geometryData(),f=e.sourceDataP3fv({name:"pos"}),h=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Two,{name:"fillColor"}),p=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"fillOpacity"}),m=e.triangles();d=new e.modelViewOriginUniform("modelViewMatrix"),n.addVertexAttribute(r,e.vertexAttributeKeys.Position),n.addVertexAttribute(i,e.vertexAttributeKeysIndexed.Two),n.addVertexAttribute(o,e.vertexAttributeKeysIndexed.Three),n.addUniform(d),n.addUniform(a),n.addShader(u),n.addShader(s),_.addAttribute(n),_.addAttribute(l),v.setMaterial(_),v.setMapper(x),c.addSource(f),c.addSource(h),c.addSource(p),c.addPrimitive(m),c.computeBounds=function(){c.setBounds(0,0,0,0,0,0)},x.setGeometryData(c),b.call(g,t)},this.actors=function(){return[v]},this._build=function(){!function(t){var e,n,o,a,u,l,c,p,m,y,v,_,b,w,M,A,T,E,C,k,S,O,P,L,R,I,D,N,F,j=[],z=g.gcs(),B=g.layer().map().gcs(),V=0,q=x.geometryData();for(u=g.style.get("fillColor"),l=s.isFunction(g.style("fillColor"))?void 0:u(),p=g.style.get("fillOpacity"),m=s.isFunction(g.style("fillOpacity"))?void 0:p(),y=g.style.get("fill"),v=s.isFunction(g.style("fill"))?void 0:y(),_=g.style.get("uniformPolygon"),b=s.isFunction(g.style("uniformPolygon"))?void 0:_(),t?(j=f.items,V=f.numPts):(n=(n=g.style.get("position"))===s.identityFunction?null:n,o=(o=g.style.get("polygon"))===s.identityFunction?null:o,g.data().forEach((function(t,e){var a,s,u,l;if((a=o?o(t,e):t)&&!((s=a.outer||(Array.isArray(a)?a:[])).length<3)){for(u=new Array(3*s.length),O=k=0;O<s.length;O+=1,k+=3)l=n?n(s[O],O,t,e):s[O],u[k]=l.x,u[k+1]=l.y,u[k+2]=0;u={vertices:u,dimensions:3,holes:[]},F=s,a.inner&&a.inner.forEach((function(r){if(!(r.length<3))for(F=F.concat(r),u.holes.push(k/3),O=0;O<r.length;O+=1,k+=3)l=n?n(r[O],O,t,e):r[O],u.vertices[k]=l.x,u.vertices[k+1]=l.y,u.vertices[k+2]=0})),u.vertices=i.transformCoordinates(z,B,u.vertices,u.dimensions),(I={triangles:r(u.vertices,u.holes,u.dimensions),vertices:u.vertices,original:F,item:t,itemIndex:e}).triangles.length&&(j.push(I),V+=I.triangles.length)}})),e=s.getGeomBuffer(q,"pos",3*V),(M=q.primitive(0).indices())instanceof Uint16Array&&M.length===V||(M=new Uint16Array(V),q.primitive(0).setIndices(M)),f={items:j,numPts:V},h=new Float32Array(g.style.get("origin")(j)),d.setOrigin(h)),a=s.getGeomBuffer(q,"fillColor",3*V),c=s.getGeomBuffer(q,"fillOpacity",V),C=k=0,A=l,E=v,L=0;L<j.length;L+=1)if(R=j[L].triangles.length,S=j[L].vertices,D=j[L].item,N=j[L].itemIndex,F=j[L].original,T=m,(w=void 0===b?_(D,N):b)&&(void 0===l&&(A=u(S[0],0,D,N)),void 0===m&&(T=p(S[0],0,D,N))),void 0===v&&(E=y(D,N)),E||(T=0),w&&t&&j[L].uniform&&j[L].color&&A.r===j[L].color.r&&A.g===j[L].color.g&&A.b===j[L].color.b&&T===j[L].opacity)C+=R,k+=3*R;else{for(O=0;O<R;O+=1,C+=1,k+=3)t&&w?(a[k]=A.r,a[k+1]=A.g,a[k+2]=A.b,c[C]=T):(P=3*j[L].triangles[O],t||(e[k]=S[P]-h[0],e[k+1]=S[P+1]-h[1],e[k+2]=S[P+2]-h[2],M[C]=O),w||void 0!==l||(A=u(F[P],P,D,N)),a[k]=A.r,a[k+1]=A.g,a[k+2]=A.b,!w&&E&&void 0===m&&(T=p(F[P],P,D,N)),c[C]=T);(w||j[L].uniform)&&(j[L].uniform=w,j[L].color=A,j[L].opacity=T)}t?(x.updateSourceBuffer("fillOpacity"),x.updateSourceBuffer("fillColor")):(x.modified(),q.boundsDirty(!0),x.boundsDirtyTimestamp().modified())}(!!(g.dataTime().timestamp()<g.buildTime().timestamp()&&f)),g.renderer().contextRenderer().hasActor(v)||(g.renderer().contextRenderer().addActor(v),p=!0),g.buildTime().modified()},this._update=function(t){g.ready&&(t&&t.mayDelay&&p?m=g.layer().map().scheduleAnimationFrame(g._update):(m&&(g.layer().map().scheduleAnimationFrame(g._update,"remove"),m=null),w.call(g),(g.dataTime().timestamp()>=g.buildTime().timestamp()||g.updateTime().timestamp()<=g.timestamp())&&g._build(),v.setVisible(g.visible()),v.material().setBinNumber(g.bin()),g.updateTime().modified()))},this._exit=function(){m&&g.layer()&&(g.layer().map().scheduleAnimationFrame(g._update,"remove"),m=null),g.renderer().contextRenderer().removeActor(v),y()},this._init(t),this};r(a,o),i("webgl","polygon",a),t.exports=a},9304:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3842),a=n(77),s=n(642),u=16777216,l=function(t){"use strict";if(!(this instanceof l))return new l(t);o.call(this,t);var e=n(5616),r=n(1611),i=n(4084),c=n(8711),f=n(6238),h=n(8961),d=n(3260);i.call(this);var p,m,g,y,v,x,_,b=this,w=this._exit,M=this._update,A={},T=a(),E=a();function C(t){var e=new r.mapper({dynamicDraw:!0});return e.s_modified=e.modified,e.g_timestamp=a(),e.timestamp=e.g_timestamp.timestamp,e.modified=function(){return e.s_modified(),e.g_timestamp.modified(),e},e.s_render=e.render,e.render=t,e}return this.actors=function(){var t=[];return m&&t.push(m),g&&t.push(g),t},this._build=function(){var t,e,n,i,o,a,s,u,l;b.position()&&((_=b._generateQuads()).imgQuads.length&&!m&&(b.visible(!1),t=C(b._renderImageQuads),(m=new r.actor).setMapper(t),e=new r.material,(n=new r.shaderProgram).addVertexAttribute(new r.vertexAttribute("vertexPosition"),r.vertexAttributeKeys.Position),n.addVertexAttribute(new r.vertexAttribute("textureCoord"),r.vertexAttributeKeys.TextureCoordinate),p=new r.modelViewOriginUniform("modelViewMatrix",_.origin),n.addUniform(p),n.addUniform(new r.projectionUniform("projectionMatrix")),n.addUniform(new r.floatUniform("opacity",1)),n.addUniform(new r.floatUniform("zOffset",0)),(l=new r.uniform(r.GL.INT,"sampler2d")).set(0),n.addUniform(l),u=b.renderer()._glContext(),(o=new r.uniform(u.FLOAT_VEC2,"crop")).set([1,1]),n.addUniform(o),(a=new r.uniform(u.FLOAT_VEC4,"cropsource")).set([0,0,0,0]),n.addUniform(a),n.addShader(r.getCachedShader(u.VERTEX_SHADER,u,f)),n.addShader(r.getCachedShader(u.FRAGMENT_SHADER,u,c)),b._hookBuild&&b._hookBuild(n),e.addAttribute(n),e.addAttribute(new r.blend),s=new r.geometryData,y=void 0,(i=new r.sourceDataT2fv).pushBack([0,0,1,0,0,1,1,1]),s.addSource(i),t.setGeometryData(s),m.setMaterial(e),b.renderer().contextRenderer().addActor(m),b.visible(!0)),_.clrQuads.length&&!g&&(b.visible(!1),t=C(b._renderColorQuads),(g=new r.actor).setMapper(t),e=new r.material,(n=new r.shaderProgram).addVertexAttribute(new r.vertexAttribute("vertexPosition"),r.vertexAttributeKeys.Position),x=new r.modelViewOriginUniform("modelViewMatrix",_.origin),n.addUniform(x),n.addUniform(new r.projectionUniform("projectionMatrix")),n.addUniform(new r.floatUniform("opacity",1)),n.addUniform(new r.floatUniform("zOffset",0)),u=b.renderer()._glContext(),n.addUniform(new r.uniform(u.FLOAT_VEC3,"vertexColor")),n.addShader(r.getCachedShader(u.VERTEX_SHADER,u,d)),n.addShader(r.getCachedShader(u.FRAGMENT_SHADER,u,h)),e.addAttribute(n),e.addAttribute(new r.blend),s=new r.geometryData,v=void 0,t.setGeometryData(s),g.setMaterial(e),b.renderer().contextRenderer().addActor(g),b.visible(!0)),p&&p.setOrigin(_.origin),x&&x.setOrigin(_.origin),b._updateTextures(),b.buildTime().modified())},this._updateTextures=function(){var t;e.each(_.imgQuads,(function(e,n){if(n.image)if(n.image._texture)n.texture=n.image._texture;else{(t=new r.texture).setImage(n.image);var i=b.nearestPixel();if(void 0!==i)if(!0!==i&&s.isNonNullFinite(i))i=b.layer().map().zoom()>=i;i&&t.setNearestPixel(!0),n.texture=n.image._texture=t}}))},this._renderColorQuads=function(t){if(_.clrQuads.length){var n=this;(n.timestamp()>E.timestamp()||b.dataTime().timestamp()>E.timestamp()||t.m_contextChanged||!v||12*_.clrQuads.length>v.length)&&function(t){var n=t.m_context,r=!1;_.clrQuads.length&&((!v||v.length<12*_.clrQuads.length||!A.clrQuadsPosition)&&(A.clrQuadsPosition&&n.deleteBuffer(A.clrQuadsPosition),A.clrQuadsPosition=n.createBuffer(),v=new Float32Array(12*Math.max(128,2*_.clrQuads.length)),r=!0),e.each(_.clrQuads,(function(t,e){for(var n=0;n<12;n+=1)v[12*t+n]=e.pos[n]-_.origin[n%3]})),n.bindBuffer(n.ARRAY_BUFFER,A.clrQuadsPosition),r?n.bufferData(n.ARRAY_BUFFER,v,n.DYNAMIC_DRAW):n.bufferSubData(n.ARRAY_BUFFER,0,v)),E.modified()}(t),n.s_render(t,!0);var i,o,a,s=t.m_context;s.bindBuffer(s.ARRAY_BUFFER,A.clrQuadsPosition),e.each(_.clrQuads,(function(e,n){n.opacity!==i&&(i=n.opacity,s.uniform1fv(t.m_material.shaderProgram().uniformLocation("opacity"),new Float32Array([i]))),(n.zOffset||0)!==o&&(o=n.zOffset||0,s.uniform1fv(t.m_material.shaderProgram().uniformLocation("zOffset"),new Float32Array([o]))),a&&a.r===n.color.r&&a.g===n.color.g&&a.b===n.color.b||(a=n.color,s.uniform3fv(t.m_material.shaderProgram().uniformLocation("vertexColor"),new Float32Array([a.r,a.g,a.b]))),s.bindBuffer(s.ARRAY_BUFFER,A.clrQuadsPosition),s.vertexAttribPointer(r.vertexAttributeKeys.Position,3,s.FLOAT,!1,12,12*e*4),s.enableVertexAttribArray(r.vertexAttributeKeys.Position),s.drawArrays(s.TRIANGLE_STRIP,0,4)})),s.bindBuffer(s.ARRAY_BUFFER,null),n.undoBindVertexData(t)}},this._renderImageQuads=function(t){if(_.imgQuads.length){var n=this;(n.timestamp()>T.timestamp()||b.dataTime().timestamp()>T.timestamp()||t.m_contextChanged||!y||12*_.imgQuads.length>y.length)&&function(t){var n=t.m_context,r=!1;_.imgQuads.length&&((!y||y.length<12*_.imgQuads.length||!A.imgQuadsPosition)&&(A.imgQuadsPosition&&n.deleteBuffer(A.imgQuadsPosition),A.imgQuadsPosition=n.createBuffer(),y=new Float32Array(12*Math.max(128,2*_.imgQuads.length)),r=!0),e.each(_.imgQuads,(function(t,e){for(var n=0;n<12;n+=1)y[12*t+n]=e.pos[n]-_.origin[n%3]})),n.bindBuffer(n.ARRAY_BUFFER,A.imgQuadsPosition),r?n.bufferData(n.ARRAY_BUFFER,y,n.DYNAMIC_DRAW):n.bufferSubData(n.ARRAY_BUFFER,0,y)),T.modified()}(t),n.s_render(t,!0);var i,o,a,l,c,f,h,d,p=t.m_context,m={x:1,y:1},g={x0:0,y0:0,x1:1,y1:1},v=b.nearestPixel();if(void 0!==v){if(!0!==v&&s.isNonNullFinite(v)){var x=b.layer().map().zoom();v=x>=v}_.imgQuads.forEach((function(e){if(e.image&&e.texture&&e.texture.nearestPixel()!==v&&e.texture.textureHandle()){t.m_context.bindTexture(r.GL.TEXTURE_2D,e.texture.textureHandle()),t.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,v?r.GL.NEAREST:r.GL.LINEAR),t.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,v?r.GL.NEAREST:r.GL.LINEAR),t.m_context.bindTexture(r.GL.TEXTURE_2D,null);var n=e.texture.modified;e.texture.modified=function(){},e.texture.setNearestPixel(v),e.texture.modified=n}}))}b._hookRenderImageQuads&&b._hookRenderImageQuads(t,_.imgQuads),p.bindBuffer(p.ARRAY_BUFFER,A.imgQuadsPosition),e.each(_.imgQuads,(function(e,n){n.image&&(n.texture.bind(t),n.image.width*n.image.height>u&&(u=n.image.width*n.image.height,p.getError()===p.OUT_OF_MEMORY&&console.log("Insufficient GPU memory for texture")),n.opacity!==i&&(i=n.opacity,p.uniform1fv(t.m_material.shaderProgram().uniformLocation("opacity"),new Float32Array([i]))),(n.zOffset||0)!==o&&(o=n.zOffset||0,p.uniform1fv(t.m_material.shaderProgram().uniformLocation("zOffset"),new Float32Array([o]))),a=n.crop||{x:1,y:1},m&&a.x===m.x&&a.y===m.y||(m=a,p.uniform2fv(t.m_material.shaderProgram().uniformLocation("crop"),new Float32Array([void 0===m.x?1:m.x,void 0===m.y?1:m.y]))),c=n.image.width,f=n.image.height,l=n.crop||{left:0,top:0,right:c,bottom:f},g&&l.left===g.left&&l.top===g.top&&l.right===g.right&&l.bottom===g.bottom&&h===c&&d===f||(g=l,h=c,d=f,p.uniform4fv(t.m_material.shaderProgram().uniformLocation("cropsource"),new Float32Array([g.left/c,g.top/f,g.right/c,g.bottom/f]))),p.bindBuffer(p.ARRAY_BUFFER,A.imgQuadsPosition),p.vertexAttribPointer(r.vertexAttributeKeys.Position,3,p.FLOAT,!1,12,12*e*4),p.enableVertexAttribArray(r.vertexAttributeKeys.Position),p.drawArrays(p.TRIANGLE_STRIP,0,4),n.texture.undoBind(t))})),p.bindBuffer(p.ARRAY_BUFFER,null),n.undoBindVertexData(t)}},this._update=function(){M.call(b),(b.buildTime().timestamp()<=b.dataTime().timestamp()||b.updateTime().timestamp()<b.timestamp())&&b._build(),g&&(g.setVisible(b.visible()),g.material().setBinNumber(b.bin())),m&&(m.setVisible(b.visible()),m.material().setBinNumber(b.bin())),b.updateTime().modified()},this._cleanup=function(){m&&(b.renderer().contextRenderer().removeActor(m),m=null),g&&(b.renderer().contextRenderer().removeActor(g),g=null),y=void 0,v=void 0,Object.keys(A).forEach((function(t){delete A[t]})),_&&_.imgQuads&&(_.imgQuads.forEach((function(t){t.texture&&(delete t.texture,delete t.image._texture)})),b._updateTextures()),b.modified()},this.setShader=function(t,e){switch(t){case"image_vertex":f=e;break;case"image_fragment":c=e;break;case"color_vertex":d=e;break;case"color_fragment":h=e;break;default:return}return b},this._exit=function(){b._cleanup(),w.call(b)},b._init(t),this};r(l,o);var c={};c[o.capabilities.color]=!0,c[o.capabilities.image]=!0,c[o.capabilities.imageCrop]=!0,c[o.capabilities.imageFixedScale]=!1,c[o.capabilities.imageFull]=!0,c[o.capabilities.canvas]=!1,c[o.capabilities.video]=!1,i("webgl","quad",l,c),t.exports=l},1474:function(t,e,n){var r=n(1098).registerLayerAdjustment,i=n(9264),o=function(){"use strict";var t,e=n(6409),r=this,o=this._init,a=this._exit,s=this._update,u=this.visible,l=this.zIndex,c=0,f=[];this._drawTile=function(e){if(t){var n,o,a=r._tileBounds(e),s=e.index.level||0,u=r._tileOffset(s),l=r.tileCropFromBounds(e),h={},d=r.renderer().contextRenderer().m_depthBits;l&&(h.crop={x:l.x/r._options.tileWidth,y:l.y/r._options.tileHeight}),h.ul=r.fromLocal(r.fromLevel({x:a.left-u.x,y:a.top-u.y},s),0),h.ll=r.fromLocal(r.fromLevel({x:a.left-u.x,y:a.bottom-u.y},s),0),h.ur=r.fromLocal(r.fromLevel({x:a.right-u.x,y:a.top-u.y},s),0),h.lr=r.fromLocal(r.fromLevel({x:a.right-u.x,y:a.bottom-u.y},s),0),h.ul.z=h.ll.z=h.ur.z=h.lr.z=0,n=r._options.keepLower?r._options.maxLevel-s+1:1,(o=(o=r.map().listSceneObjects().filter((function(t){return t instanceof i}))).slice(o.indexOf(r)+1)).forEach((function(t){n+=t._options.keepLower?t._options.maxLevel-t._options.minLevel+1:1})),h.zOffset=n*Math.pow(2,-d)*i._zOffsetMultiple,c+=1,h.id=c,e.quadId=h.id,h.image=e.image,f.push(h),t.data(f),t._update(),r.draw()}},this._remove=function(e){if(void 0!==e.quadId&&t){for(var n=0;n<f.length;n+=1)if(f[n].id===e.quadId){f.splice(n,1);break}t.data(f),t._update(),r.draw()}},this.visible=function(e){return void 0===e?u():(r.visible()!==e&&(u(e),t&&t.visible(t.visible(void 0,!0),!0)),r)},this.zIndex=function(t,e){return void 0!==t&&r._clearQuads(),l.apply(r,arguments)},this._clearQuads=function(n){(!n||n.layer&&n.layer instanceof i&&n.layer.autoshareRenderer()&&(n.event!==e.layerAdd&&n.event!==e.layerRemove||!r.map().layers().every((function(t){return t===n.layer||n.layer.zIndex()>t.zIndex()}))))&&(r.clear(),t&&t.modified(),n&&r.draw())},this._update=function(e){return s.call(r,e),t&&t.nearestPixel&&t.nearestPixel(r.nearestPixel()),r._addBaseQuadToTiles(t,f),r},this._cleanup=function(){var t;if(r.cache&&r.cache._cache){for(var e in r.cache._cache)(t=r.cache._cache[e])._image&&t._image._texture&&delete t._image._texture;r.cache.clear()}r.clear()},this._exit=function(){var n=r.map();n.geoOff(e.layerAdd,r._clearQuads),n.geoOff(e.layerRemove,r._clearQuads),r._cleanup(),r.deleteFeature(t),t=null,f=[],a.apply(r,arguments)},this._init=function(){o.apply(r,arguments),(t=r.createFeature("quad",{previewColor:r._options.previewColor,previewImage:r._options.previewImage})).geoTrigger=void 0,t.gcs(r._options.gcs||r.map().gcs()),t.data(f),t._update();var n=r.map();n.geoOn(e.layerAdd,r._clearQuads),n.geoOn(e.layerRemove,r._clearQuads),r.geoOn(e.unhidden,(function(){r.map().scheduleAnimationFrame((function(){r._clearQuads(),r.map().draw()}))}))},this._getSubLayer=function(){},this._updateSubLayers=void 0};i._zOffsetMultiple=2,r("webgl","tile",o),t.exports=o},536:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(338),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(4084).call(this),this._init(t),this):new a(t)};r(a,o),i("webgl","track",a),t.exports=a},7945:function(t,e,n){var r,i=n(4626),o=n(1098).registerRenderer,a=n(2274),s=function(t){"use strict";if(!(this instanceof s))return new s(t);t=t||{},a.call(this,t);var e,r=n(5616),i=n(1611),o=n(3503),u=n(642),l=n(6409),c=this,f=null,h=null,d=!1,p=this._init,m=this._exit;return this.contextRenderer=function(){return f},this.api=function(){return s.apiname},this._init=function(){if(c.initialized())return c;p.call(c);var e=t.canvas||r(document.createElement("canvas"));if(e.addClass("webgl-canvas"),r(c.layer().node().get(0)).append(e),window.overrideContextAttributes){var n=e.get(0),o=n.getContext;n.getContext=function(t,e){if(e=e||{},window.overrideContextAttributes)for(var r in window.overrideContextAttributes)window.overrideContextAttributes.hasOwnProperty(r)&&(e[r]=window.overrideContextAttributes[r]);return o.call(n,t,e)}}(h=i.viewer(e.get(0),t.options)).init(),(f=h.renderWindow().activeRenderer()).setResetScene(!1),e.get(0).addEventListener("webglcontextlost",(function(t){return t.preventDefault()}),!1),e.get(0).addEventListener("webglcontextrestored",(function(){return h.renderWindow()._init()}),!1),h.renderWindow().renderers().length>0&&f.setLayer(h.renderWindow().renderers().length),c.canvas(e);var a=c.layer().map().size();return c._resize(0,0,a.width,a.height),c},this._resize=function(t,e,n,r){var i=h.renderWindow();return t===i.windowPosition[0]&&e===i.windowPosition[1]&&n===c.width()&&r===c.height()||(c._setWidthHeight(n,r),c.canvas().attr("width",n),c.canvas().attr("height",r),i.positionAndResize(t,e,n,r),d=!0,c._render()),c},this._render=function(){return c.layer().map().scheduleAnimationFrame(c._renderFrame,!0),c},this._renderFrame=function(){h&&(d&&(d=!1,c._updateRendererCamera()),h.render())},this._glContext=function(){return h&&h.renderWindow()?h.renderWindow().context():i.GL},this._exit=function(){if(c.layer().map().scheduleAnimationFrame(c._renderFrame,"remove"),c.canvas().remove(),h){var t=new i.renderState;t.m_renderer=h,t.m_context=c._glContext(),h.exit(t);var e=c._glContext();e!==i.GL&&e.getExtension("WEBGL_lose_context")&&e.getExtension("WEBGL_lose_context").loseContext&&e.getExtension("WEBGL_lose_context").loseContext()}i.clearCachedShaders(i.GL),h=null,m()},this._updateRendererCamera=function(){var t=h.renderWindow(),n=c.layer().map(),r=n.camera(),i=n.rotation()||0,a=r.view,s=r.projectionMatrix;if(s[15])s=o.copy(u.mat4AsArray(),s),s=o.scale(s,s,[1,1,-.5]),s=o.translate(s,s,[0,0,r.clipbounds.far]);else{var l=r.clipbounds.near,f=r.clipbounds.far;s=o.copy(u.mat4AsArray(),s),s=o.scale(s,s,[1/l,1/l,-1/f])}var d=Math.PI/2,p=i%d,m=Math.min(Math.abs(p),Math.abs(p-d))<1e-5;t.renderers().forEach((function(t){var i=t.camera();if(!u.compareArrays(a,i.viewMatrix())||!u.compareArrays(s,i.projectionMatrix())||e!==n.zoom()){e=n.zoom(),i.setViewMatrix(a,!0),i.setProjectionMatrix(s);var o=r.viewport;s[1]||s[2]||s[3]||s[4]||s[6]||s[7]||s[8]||s[9]||s[11]||1!==s[15]||!m||o.left&&o.left%1||o.top&&o.top%1||parseFloat(e.toFixed(6))!==parseFloat(e.toFixed(0))?i.viewAlignment=function(){return null}:i.viewAlignment=function(){var t={roundx:2/o.width,roundy:2/o.height};return t.dx=o.width%2?.5*t.roundx:0,t.dy=o.height%2?.5*t.roundy:0,t}}}))},c.layer().geoOn(l.pan,(function(t){d=!0})),c.layer().geoOn(l.parallelprojection,(function(t){var e=c.contextRenderer(),n=c.layer();if(t.geo&&t.geo._triggeredBy!==n){if(!e||!e.camera())return void console.log("Parallel projection event triggered on unconnected VGL renderer.");e.camera().setEnableParallelProjection(t.parallelProjection),d=!0}})),this};s.apiname="webgl",i(s,a),o("webgl",s),o("vgl",s),s.supported=function(){if(void 0===r){var t,e;try{(e=(t=document.createElement("canvas")).getContext("webgl")||t.getContext("experimental-webgl")).getSupportedExtensions().indexOf("WEBGL_debug_renderer_info")>=0&&(s._unmaskedRenderer=e.getParameter(e.getExtension("WEBGL_debug_renderer_info").UNMASKED_RENDERER_WEBGL)),s._maxTextureSize=e.getParameter(e.MAX_TEXTURE_SIZE),s._maxPointSize=e.getParameter(e.ALIASED_POINT_SIZE_RANGE)[1],r=!0}catch(t){console.warn("No webGL support"),r=!1}t=void 0,e=void 0}return r},s.fallback=function(){return null},t.exports=s},632:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o),s=n(3021),u=n.n(s),l=new URL(n(3158),n.b),c=new URL(n(5245),n.b),f=new URL(n(8546),n.b),h=new URL(n(9803),n.b),d=a()(i()),p=u()(l),m=u()(c),g=u()(f),y=u()(h);d.push([t.id,'.geojs-map{position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden}.geojs-map .geo-attribution{position:absolute;right:0;bottom:0;padding-right:5px;cursor:auto;font:11px/1.5 "Helvetica Neue",Arial,Helvetica,sans-serif;z-index:1001;background:rgba(255,255,255,0.7);clear:both;display:block;pointer-events:auto}.geojs-map .geo-attribution .geo-attribution-layer{padding-left:5px}.geojs-map .canvas-canvas{display:block;-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-o-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}.geojs-map .webgl-canvas{display:block}.geojs-map .geojs-layer{position:absolute;width:100%;height:100%;left:0;top:0;pointer-events:none}.geojs-map .geojs-layer.active:not(.hidden) > *{pointer-events:auto}.geojs-map .geojs-layer.hidden{display:none}.geojs-map .geojs-layer.hidden[renderer="webgl"]{display:inherit}.geojs-map .geo-tile-layer{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-o-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;line-height:0;font-size:0}.geojs-map.annotation-input{cursor:crosshair}.geojs-map.annotation-input.annotation-intersect{cursor:url('+p+") 12 12,crosshair}.geojs-map.annotation-input.annotation-difference{cursor:url("+m+") 12 12,crosshair}.geojs-map.annotation-input.annotation-union{cursor:url("+g+") 12 12,crosshair}.geojs-map.annotation-input.annotation-xor{cursor:url("+y+") 12 12,crosshair}.geojs-map.annotation-cursor{cursor:crosshair}.geojs-map.annotation-cursor.annotation-intersect{cursor:url("+p+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-difference{cursor:url("+m+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-union{cursor:url("+g+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-xor{cursor:url("+y+') 12 12,crosshair}.geojs-map.highlight-focus:after{content:"";display:block;position:absolute;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;left:0;top:0;right:0;bottom:0;border:3px solid Highlight;opacity:1;-ms-filter:none;filter:none;-webkit-transition:opacity 0s;-moz-transition:opacity 0s;-o-transition:opacity 0s;-ms-transition:opacity 0s;transition:opacity 0s;visibility:hidden}.geojs-map.highlight-focus:focus:after{visibility:visible;-webkit-transition:opacity 2.5s ease-in;-moz-transition:opacity 2.5s ease-in;-o-transition:opacity 2.5s ease-in;-ms-transition:opacity 2.5s ease-in;transition:opacity 2.5s ease-in;opacity:0;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";filter:alpha(opacity=0)}.geo-tile-container{position:absolute}.geo-tile-container.crop{overflow:hidden}',"",{version:3,sources:["webpack://./main.styl","webpack://./../node_modules/nib/lib/nib/vendor.styl","webpack://./../node_modules/nib/lib/nib/overflow.styl","webpack://./../node_modules/nib/lib/nib/flex.styl","webpack://./../node_modules/nib/lib/nib/border.styl"],names:[],mappings:"AAEA,WACE,iBAAS,CCwCO,wBAAG,CAAH,qBAAG,CAAH,oBAAG,CARN,gBAAG,CChBd,eAAU,CFZZ,4BACE,iBAAS,CACT,OAAM,CACN,QAAO,CACP,iBAAc,CC4ed,WAAO,CD1eP,yDAA8B,CAC9B,YAAQ,CC6dR,gCAAW,CD3dX,UAAM,CGMN,aAAS,CHJT,mBAAe,CAEf,mDACE,gBAAa,CAEjB,0BGDE,aAAS,CFqBK,4BAAG,CAAH,yBAAG,CAAH,uBAAG,CAAH,wBAAG,CARN,oBAAG,CDThB,yBGJE,aAAS,CHOX,wBACE,iBAAS,CACT,UAAM,CACN,WAAO,CACP,MAAK,CACL,KAAI,CACJ,mBAAe,CAEb,gDACE,mBAAe,CACnB,+BGjBA,YAAS,CHmBT,iDGnBA,eAAS,CHsBX,2BCDgB,4BAAG,CAAH,yBAAG,CAAH,uBAAG,CAAH,wBAAG,CARN,oBAAG,CDWd,aAAY,CACZ,WAAU,CAEZ,4BCscE,gBAAO,CDpcP,iDCocA,8DAAO,CDlcP,kDCkcA,8DAAO,CDhcP,6CCgcA,8DAAO,CD9bP,2CC8bA,8DAAO,CD3bT,6BC2bE,gBAAO,CDzbP,kDCybA,8DAAO,CDvbP,mDCubA,8DAAO,CDrbP,8CCqbA,8DAAO,CDnbP,4CCmbA,8DAAO,CD/aP,iCACE,UAAQ,CGnDV,aAAS,CHqDP,iBAAS,CChCG,6BAAG,CAAH,0BAAG,CARN,qBAAG,CD0CZ,MAAK,CACL,KAAI,CACJ,OAAM,CACN,QAAO,CIvET,0BAAQ,CH4PV,SAAS,CAQH,eAAY,CACZ,WAAQ,CArOE,6BAAG,CAAH,0BAAG,CAAH,wBAAG,CAAH,yBAAG,CARN,qBAAG,CDqDZ,iBAAW,CACb,uCACE,kBAAW,CC/CC,uCAAG,CAAH,oCAAG,CAAH,kCAAG,CAAH,mCAAG,CARN,+BAAG,CAoOhB,SAAS,CAWH,+DAAyE,CACzE,uBAAiC,CDrLzC,oBACE,iBAAS,CACT,yBE3EE,eAAU",sourcesContent:['@import \'~nib/index.styl\'\n\n.geojs-map\n position relative\n user-select none\n overflow hidden\n\n .geo-attribution\n position absolute\n right 0\n bottom 0\n padding-right 5px\n cursor auto\n font 11px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif\n z-index 1001\n background rgba(255,255,255,0.7)\n clear both\n display block\n pointer-events auto\n\n .geo-attribution-layer\n padding-left 5px\n\n .canvas-canvas\n display block\n transform-origin 0px 0px\n .webgl-canvas\n display block\n\n .geojs-layer\n position absolute\n width 100%\n height 100%\n left 0\n top 0\n pointer-events none\n &.active:not(.hidden)\n > *\n pointer-events auto\n &.hidden\n display none\n &.hidden[renderer="webgl"]\n display inherit\n\n .geo-tile-layer\n transform-origin 0px 0px\n line-height 0\n font-size 0\n\n &.annotation-input\n cursor crosshair\n &.annotation-intersect\n cursor embedurl("./css/cursor-crosshair-intersect.svg") 12 12,crosshair\n &.annotation-difference\n cursor embedurl("./css/cursor-crosshair-difference.svg") 12 12,crosshair\n &.annotation-union\n cursor embedurl("./css/cursor-crosshair-union.svg") 12 12,crosshair\n &.annotation-xor\n cursor embedurl("./css/cursor-crosshair-xor.svg") 12 12,crosshair\n\n &.annotation-cursor\n cursor crosshair\n &.annotation-intersect\n cursor embedurl("./css/cursor-crosshair-intersect.svg") 12 12,crosshair\n &.annotation-difference\n cursor embedurl("./css/cursor-crosshair-difference.svg") 12 12,crosshair\n &.annotation-union\n cursor embedurl("./css/cursor-crosshair-union.svg") 12 12,crosshair\n &.annotation-xor\n cursor embedurl("./css/cursor-crosshair-xor.svg") 12 12,crosshair\n\n &.highlight-focus\n &:after\n content ""\n display block\n position absolute\n box-sizing border-box\n left 0px\n top 0px\n right 0px\n bottom 0px\n // Highlight is technically a css2 color. We may need to specify it\n // explicitly. #3B66A6 seems close\n border 3px solid Highlight\n opacity 1\n transition opacity 0s\n visibility hidden\n &:focus:after\n visibility visible\n transition opacity 2.5s ease-in\n opacity 0\n\n.geo-tile-container\n position absolute\n &.crop\n overflow hidden\n',"use('../nodes/vendor-helpers.js')\n@import 'config'\n\n/*\n * Alias \"nowrap\" as \"no-wrap\".\n */\n\nno-wrap = unquote('nowrap')\n\n/*\n * Helper to find out if a given value is a width\n */\n\nis-width(val)\n if auto == val\n return true\n else if val && 'unit' == type(val)\n // Stylus does not short circuit so we need to perform this as a distinct\n // operation to prevent errors\n return '' != unit(val)\n return false\n\n/*\n * Vendor support for the given prop / arguments, optionally specifying the\n * only prefixes to utilize, or those which should be ignored.\n */\n\nvendor(prop, args, only = null, ignore = null, vendor-property = true)\n need_normalize = !vendor-property or prop in ('transition' 'transition-property' 'border-image' 'border-image-slice')\n for prefix in vendor-prefixes\n unless (only and !(prefix in only)) or (ignore and prefix in ignore)\n if official == prefix\n if need_normalize\n {prop}: normalize(prop,('%s' % args))\n else\n {prop}: args\n else\n newprop = prop\n newprop = '-' + prefix + '-' + prop if vendor-property\n\n if need_normalize\n {newprop}: normalize(prop,('%s' % args),prefix)\n else\n {newprop}: args\n/*\n * Vendorize the given value.\n */\n\nvendor-value(arg, only = null, ignore = null)\n prop = current-property[0]\n for prefix in vendor-prefixes\n unless (only and !(prefix in only)) or (ignore and prefix in ignore) or official == prefix\n add-property(prop, '-%s-%s' % (prefix arg))\n arg\n\n/*\n * Vendor \"box-shadow\" support.\n */\n\nbox-shadow()\n vendor('box-shadow', arguments, only: webkit official)\n\n/*\n * Vendor \"user-select\" support.\n */\n\nuser-select()\n vendor('user-select', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"column-count\" support.\n */\n\ncolumn-count()\n vendor('column-count', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-gap\" support.\n */\n\ncolumn-gap()\n vendor('column-gap', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule\" support.\n */\n\ncolumn-rule()\n vendor('column-rule', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-color\" support.\n */\n\ncolumn-rule-color()\n vendor('column-rule-color', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-width\" support.\n */\n\ncolumn-rule-width()\n vendor('column-rule-width', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-style\" support.\n */\n\ncolumn-rule-style()\n vendor('column-rule-style', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-width\" support.\n */\n\ncolumn-width()\n vendor('column-width', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-span\" support.\n */\n\ncolumn-span()\n vendor('column-span', arguments, only: webkit official)\n\n/*\n * Vendor \"column-fill\" support.\n */\n\ncolumn-fill()\n vendor('column-fill', arguments, only: moz official)\n\n/*\n * Legacy syntax support for background-clip and background-origin\n */\n\nlegacy-bg-values(property, args)\n legacy_args = ()\n importance = unquote('')\n for subargs in args\n for arg in subargs\n if arg in (border-box padding-box content-box)\n arg = unquote('border') if arg == border-box\n arg = unquote('padding') if arg == padding-box\n arg = unquote('content') if arg == content-box\n if arg != '!important'\n push(legacy_args,arg)\n else\n importance = !important\n vendor(property, unquote(join(', ',legacy_args)) importance, only: moz webkit)\n\n/*\n * Vendor \"background-clip\" support.\n */\n\nbackground-clip()\n if arguments[0] == text\n vendor('background-clip', arguments, only: webkit)\n else\n legacy-bg-values('background-clip', arguments)\n background-clip: arguments\n\n/*\n * Vendor \"background-origin\" support.\n */\n\nbackground-origin()\n legacy-bg-values('background-origin', arguments)\n background-origin: arguments\n\n/*\n * Vendor \"transform\" support.\n */\n\ntransform()\n vendor('transform', arguments)\n\n/*\n * Vendor \"transform-origin\" support.\n */\ntransform-origin()\n vendor('transform-origin', arguments)\n\n/*\n * Vendor \"transform-style\" support.\n */\n\ntransform-style()\n vendor('transform-style', arguments)\n\n/*\n * Vendor \"border-image\" support.\n */\n\nborder-image()\n vendor('border-image', arguments, only: webkit moz o official)\n\n/*\n * Vendor \"transition\" support.\n */\n\ntransition()\n vendor('transition', arguments)\n\n/*\n * Vendor \"transition-property\" support.\n */\n\ntransition-property()\n vendor('transition-property', arguments)\n\n/*\n * Vendor \"transition-duration\" support.\n */\n\ntransition-duration()\n vendor('transition-duration', arguments)\n\n/*\n * Vendor \"transition-timing-function\" support.\n */\n\ntransition-timing-function()\n vendor('transition-timing-function', arguments)\n\n/*\n * Vendor \"transition-delay\" support.\n */\n\ntransition-delay()\n vendor('transition-delay', arguments)\n\n/*\n * Vendor \"backface-visibility\" support.\n */\n\nbackface-visibility()\n vendor('backface-visibility', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"perspective\" support.\n */\n\nperspective()\n if mixin\n vendor('perspective', arguments, only: webkit moz ms official)\n else\n 'perspective(%s)' % arguments\n\n/*\n * Vendor \"perspective-origin\" support.\n */\n\nperspective-origin()\n vendor('perspective-origin', arguments, only: webkit moz ms official)\n\n/*\n * Opacity with conditional IE support.\n */\n\nopacity(n, args...)\n opacity: n args\n if support-for-ie\n if n == inherit or n == initial\n -ms-filter: n args\n filter: n args\n else\n val = round(n * 100)\n if val == 100\n -ms-filter: none args\n filter: none args\n else\n -ms-filter: '\"progid:DXImageTransform.Microsoft.Alpha(Opacity=%s)\"' % val args\n filter: 'alpha(opacity=%s)' % val args\n\n/*\n * Vendor \"text-size-adjust\"\n */\n\ntext-size-adjust()\n vendor('text-size-adjust', arguments)\n\n/*\n * Alias the \"white-space\" property.\n */\n\nwhitespace()\n white-space: arguments\n\n/*\n * Vendor \"box-sizing\" support.\n */\n\nbox-sizing()\n vendor('box-sizing', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-orient\" support.\n */\n\nbox-orient()\n vendor('box-orient', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-flex-group\" support.\n */\n\nbox-flex-group()\n vendor('box-flex-group', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-ordinal-group\" support.\n */\n\nbox-ordinal-group()\n vendor('box-ordinal-group', arguments, only: webkit moz ms official)\n\n\n/*\n * Vendor \"box-align\" support.\n */\n\nbox-align()\n vendor('box-align', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"box-pack\" support.\n */\n\nbox-pack()\n vendor('box-pack', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"box-direction\" support.\n */\n\nbox-direction()\n vendor('box-direction', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"animation\" support.\n */\n\nanimation()\n vendor('animation', arguments)\n\n\n/*\n * Vendor \"animation-name\" support.\n */\n\nanimation-name()\n vendor('animation-name', arguments)\n\n/*\n * Vendor \"animation-duration\" support.\n */\n\nanimation-duration()\n vendor('animation-duration', arguments)\n\n/*\n * Vendor \"animation-delay\" support.\n */\n\nanimation-delay()\n vendor('animation-delay', arguments)\n\n/*\n * Vendor \"animation-direction\" support.\n */\n\nanimation-direction()\n vendor('animation-direction', arguments)\n\n/*\n * Vendor \"animation-iteration-count\" support.\n */\n\nanimation-iteration-count()\n vendor('animation-iteration-count', arguments)\n\n/*\n * Vendor \"animation-timing-function\" support.\n */\n\nanimation-timing-function()\n vendor('animation-timing-function', arguments)\n\n/*\n * Vendor \"animation-play-state\" support.\n */\n\nanimation-play-state()\n vendor('animation-play-state', arguments)\n\n/*\n * Vendor \"animation-fill-mode\" support.\n */\n\nanimation-fill-mode()\n vendor('animation-fill-mode', arguments)\n\n/*\n * Vendor \"hyphens\" support.\n */\n\nhyphens()\n vendor('hyphens', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"appearance\" support.\n */\n\nappearance()\n vendor('appearance', arguments, only: webkit moz official)\n\n/*\n * Vendor \"tab-size\" support.\n */\n\ntab-size()\n vendor('tab-size', arguments, only: moz o official)\n\n/*\n * Vendor \"overflow-scrolling\" support.\n */\n\noverflow-scrolling()\n vendor('overflow-scrolling', arguments, only: webkit official)\n\n/*\n * Vendor \"text-overflow\" support, , -o- for opera 9.* - 10.*\n */\n\ntext-overflow()\n vendor('text-overflow', arguments, only: official o)\n\n/*\n * Vendor \"text-size-adjust\" support.\n */\ntext-size-adjust()\n vendor('text-size-adjust', arguments, only: official webkit ms)\n\n/*\n * Vendor \"font-smoothing\" support, webkit only.\n */\nfont-smoothing()\n vendor('font-smoothing', arguments, only: webkit)\n\n\n/**\n * Vendor input-placeholder/placeholder support.\n *\n * Examples:\n * // Default syntax\n * body\n * placeholder(color #333, font-weight normal)\n *\n * // The comma is important\n * .placeholder-red\n * placeholder(color red,)\n *\n * // We can pass a function\n * green-placeholder()\n * color green\n * .placeholder-green\n * placeholder(green-placeholder)\n *\n * // We can pass a hash\n * textarea\n * placeholder((font-style italic) (font-weight bold) (padding '4px 10px'))\n */\nplaceholder()\n for v in ':-webkit-input' '-moz' ':-moz' '-ms-input'\n &:{v}-placeholder\n for pair in arguments\n if typeof(pair) == 'function'\n pair()\n else if pair is not null && pair[0] is not null\n {pair[0]}: type(pair[1]) == 'string' ? s(pair[1]) : pair[1]\ninput-placeholder = placeholder\n\n/*\n * Vendor background support (gradients).\n */\n\nbackground()\n if match('-gradient\\(', ''+arguments)\n vendor('background', arguments, vendor-property: false)\n else\n background arguments\n\nbackground-image()\n if match('-gradient\\(', ''+arguments)\n vendor('background-image', arguments, vendor-property: false)\n else\n background-image arguments\n\ncursor()\n if match('-gradient\\(', ''+arguments)\n vendor('cursor', arguments, vendor-property: false)\n else\n cursor arguments\n\nlist-style()\n if match('-gradient\\(', ''+arguments)\n vendor('list-style', arguments, vendor-property: false)\n else\n list-style arguments\n\nlist-style-image()\n if match('-gradient\\(', ''+arguments)\n vendor('list-style-image', arguments, vendor-property: false)\n else\n list-style-image arguments\n","/*\n * Overflow utility. Maps to regular overflow, and adds an ellipsis value.\n *\n * Synopsis:\n *\n * overflow: <type>\n *\n * Examples:\n *\n * overflow: auto\n * overflow: hidden\n * overflow: ellipsis\n *\n */\n\noverflow()\n if arguments[0] == ellipsis\n ellipsis()\n else\n overflow: arguments\n","/*\n * Vendor \"display: flex\" support with fallback to obsolete versions.\n */\n\nflex-version ?= box flex\n\n//\n// 1. Display values\n// - http://www.w3.org/TR/css3-flexbox/#flex-containers\n//\ndisplay(type, args...)\n if flex == type || inline-flex == type\n if box in flex-version\n if flex == type\n display: -ms-flexbox args\n display: vendor-value(box args, only: moz webkit)\n else\n display: -ms-inline-flexbox args\n display: vendor-value(inline-box args, only: moz webkit)\n if flex in flex-version\n display: vendor-value(arguments, only: webkit official) // overwrites old webkit\n else\n display: arguments\n\n/*\n * New syntax for browsers like Google Chrome.\n * Plus a translation to the old syntax, if possible.\n */\n\n\n//\n// 5. Ordering and Orientation\n// - http://www.w3.org/TR/css3-flexbox/#ordering-and-orientation\n//\n-flex-obsolete-direction(direction)\n if box in flex-version\n if row-reverse == direction || column-reverse == direction\n vendor('box-direction', reverse, ignore: ms official)\n\n if row == direction || row-reverse == direction\n vendor('box-orient', horizontal, ignore: ms official)\n else if column == direction || column-reverse == direction\n vendor('box-orient', vertical, ignore: ms official)\n\n-flex-obsolete-wrap(value)\n if box in flex-version\n // WARN: wrap-reverse does not have a box equivalent. This will render in different manners\n // on box vs. flex values.\n if 'wrap' == value || wrap-reverse == value\n vendor('box-lines', multiple, ignore: ms official)\n else if nowrap == value\n vendor('box-lines', single, ignore: ms official)\n\nflex-direction(direction)\n // obsolete\n -flex-obsolete-direction(direction)\n\n // new\n if flex in flex-version\n vendor('flex-direction', arguments, only: webkit ms official)\n\nflex-wrap(value)\n // obsolete\n -flex-obsolete-wrap(value)\n\n if flex in flex-version\n vendor('flex-wrap', arguments, only: webkit ms official)\n\nflex-flow()\n // obsolete\n -flex-obsolete-direction(arguments[0])\n -flex-obsolete-direction(arguments[1])\n -flex-obsolete-wrap(arguments[0])\n -flex-obsolete-wrap(arguments[1])\n\n // new\n if flex in flex-version\n vendor('flex-flow', arguments, only: webkit ms official)\n\n\norder()\n // obsolete\n if box in flex-version\n vendor('box-ordinal-group', arguments, ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-order', arguments, only: ms)\n vendor('order', arguments, only: webkit official)\n\n\n//\n// 7. Flexibility\n// - http://www.w3.org/TR/css3-flexbox/#flexibility\n//\nflex-grow(growth)\n // obsolete\n if box in flex-version\n vendor('box-flex', growth)\n\n // new\n if flex in flex-version\n vendor('flex-grow', arguments, only: webkit official)\n\nflex-basis()\n if flex in flex-version\n vendor('flex-basis', arguments, only: webkit official)\n\nflex-shrink()\n if flex in flex-version\n vendor('flex-shrink', arguments, only: webkit official)\n\nflex(growth)\n\n // obsolete\n if box in flex-version\n shrink = 1\n\n if none == growth || initial == growth\n // Well known values\n shrink = 0 if none == growth\n growth = 0\n else if is-width(growth) == true\n // Basis is defined as the first parameter\n growth = arguments[1] || 0\n shrink = arguments[2] if 3 <= length(arguments)\n else if arguments[1] && is-width(arguments[1]) == false\n // Growth is first and shrink is second\n shrink = arguments[1]\n\n // Since we can't make the distinction between growing and shrinking in the box model, take\n // the one that provides the most flexibility.\n vendor('box-flex', max(growth, shrink), ignore: ms)\n\n // new\n if flex in flex-version\n vendor('flex', arguments, only: webkit ms official)\n\n\n// converts the justification alignment\n-convert-justify(align)\n if flex-start == align\n return start\n else if flex-end == align\n return end\n else if space-around == align\n return distribute\n else if space-between == align\n return justify\n else\n return align\n\n//\n// 8. Alignment\n// - http://www.w3.org/TR/css3-flexbox/#alignment\n//\njustify-content(align)\n // obsolete\n if box in flex-version\n vendor('box-pack', -convert-justify(align), ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-pack', -convert-justify(align), only: ms)\n vendor('justify-content', align, only: webkit official)\n\nalign-content(align)\n // WARN: Obsolete spec does not allow for adjustment here\n if flex in flex-version\n vendor('flex-line-pack', -convert-justify(align), only: ms)\n vendor('align-content', align, only: webkit official)\n\n// converts alignment from 'flex' to normal value\n-convert-alignment(align)\n if flex-start == align\n return start\n else if flex-end == align\n return end\n else\n return align\n\nalign-items(align)\n // obsolete\n if box in flex-version\n vendor('box-align', -convert-alignment(align), ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-align', -convert-alignment(align), only: ms)\n vendor('align-items', arguments, only: webkit official)\n\nalign-self(align)\n // WARN: Obsolete spec does not allow for overriding alignment on individual items.\n if flex in flex-version\n vendor('align-self', align, only: webkit official)\n vendor('flex-item-align', -convert-alignment(align), only: ms)\n","/*\n * border: <color>\n * border: ...\n */\n\nborder(color, args...)\n if color is a 'color'\n border: 1px solid color args\n else\n border: arguments\n"],sourceRoot:""}]),e.A=d},7046:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o)()(i());a.push([t.id,".color-legend-container{display:none;padding:10px;border:1.5px solid #000;border-radius:3px;transition:250ms background linear;background-color:rgba(255,255,255,0.75)}.color-legend-container:hover{background-color:#fff}.color-legend-container .geojs-color-legends .geojs-color-legend{margin-bottom:10px}.color-legend-container .geojs-color-legends .geojs-color-legend .geojs-title{text-align:center}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg{display:block}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x path.domain,.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x line{fill:none;stroke:#000;stroke-width:.7}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x text{font-size:12px}.color-legend-container .color-legend-popup{position:absolute;background:#fff;height:22px;font-size:14px;border:solid 1px #000;padding:0 5px;pointer-events:none;white-space:nowrap;z-index:100000;opacity:0}","",{version:3,sources:["webpack://./ui/colorLegendWidget.styl"],names:[],mappings:"AAAA,wBACE,YAAQ,CACR,YAAQ,CACR,uBAAO,CACP,iBAAc,CACd,kCAAW,CACX,uCAAiB,CAEjB,8BACE,qBAAiB,CAIjB,iEACE,kBAAc,CAEd,8EACE,iBAAW,CAEb,yEACE,aAAQ,CAGN,mLACE,SAAK,CACL,WAAO,CACP,eAAa,CACf,sFACE,cAAU,CAEpB,4CACE,iBAAS,CACT,eAAW,CACX,WAAO,CACP,cAAU,CACV,qBAAO,CACP,aAAQ,CACR,mBAAe,CACf,kBAAY,CACZ,cAAQ,CACR,SAAQ",sourcesContent:[".color-legend-container\n display none\n padding 10px\n border 1.5px solid black\n border-radius 3px\n transition 250ms background linear\n background-color rgba(255, 255, 255, 0.75)\n\n &:hover\n background-color rgba(255, 255, 255, 1)\n\n .geojs-color-legends\n\n .geojs-color-legend\n margin-bottom 10px\n\n .geojs-title\n text-align center\n\n svg.svg\n display block\n\n .axis.x\n path.domain, line\n fill none\n stroke black\n stroke-width 0.7\n text\n font-size 12px\n\n .color-legend-popup\n position absolute\n background white\n height 22px\n font-size 14px\n border solid 1px black\n padding 0 5px\n pointer-events none\n white-space nowrap\n z-index 100000\n opacity 0\n"],sourceRoot:""}]),e.A=a},5290:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o)()(i());a.push([t.id,".geojs-scale-widget-bar{stroke:#000}.geojs-scale-widget-text{font-weight:bold;font-size:16px;font-family:serif}","",{version:3,sources:["webpack://./ui/scaleWidget.styl"],names:[],mappings:"AAAA,wBACE,WAAO,CACT,yBACE,gBAAY,CACZ,cAAU,CACV,iBAAY",sourcesContent:[".geojs-scale-widget-bar\n stroke black\n.geojs-scale-widget-text\n font-weight bold\n font-size 16px\n font-family serif\n"],sourceRoot:""}]),e.A=a},278:function(t){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,i,o){"string"==typeof t&&(t=[[null,t,void 0]]);var a={};if(r)for(var s=0;s<this.length;s++){var u=this[s][0];null!=u&&(a[u]=!0)}for(var l=0;l<t.length;l++){var c=[].concat(t[l]);r&&a[c[0]]||(void 0!==o&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=o),n&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=n):c[2]=n),i&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=i):c[4]="".concat(i)),e.push(c))}},e}},3021:function(t){"use strict";t.exports=function(t,e){return e||(e={}),t?(t=String(t.__esModule?t.default:t),/^['"].*['"]$/.test(t)&&(t=t.slice(1,-1)),e.hash&&(t+=e.hash),/["'() \t\n]|(%20)/.test(t)||e.needQuotes?'"'.concat(t.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):t):t}},4942:function(t){"use strict";t.exports=function(t){var e=t[1],n=t[3];if(!n)return e;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),i="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),o="/*# ".concat(i," */");return[e].concat([o]).join("\n")}return[e].join("\n")}},3369:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8];return t[0]=a*c-s*l,t[1]=i*l-r*c,t[2]=r*s-i*a,t[3]=s*u-o*c,t[4]=n*c-i*u,t[5]=i*o-n*s,t[6]=o*l-a*u,t[7]=r*u-n*l,t[8]=n*a-r*o,t}},5723:function(t){t.exports=function(t){var e=new Float32Array(9);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}},817:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}},6396:function(t){t.exports=function(){var t=new Float32Array(9);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}},9133:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8];return e*(l*o-a*u)+n*(a*s-l*i)+r*(u*i-o*s)}},7053:function(t){t.exports=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]+t[3]*t[3]+t[4]*t[4]+t[5]*t[5]+t[6]*t[6]+t[7]*t[7]+t[8]*t[8])}},7068:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=0,t[3]=e[2],t[4]=e[3],t[5]=0,t[6]=e[4],t[7]=e[5],t[8]=1,t}},5018:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[4],t[4]=e[5],t[5]=e[6],t[6]=e[8],t[7]=e[9],t[8]=e[10],t}},3955:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,f=r*s,h=i*a,d=i*s,p=i*u,m=o*a,g=o*s,y=o*u;return t[0]=1-f-p,t[3]=c-y,t[6]=h+g,t[1]=c+y,t[4]=1-l-p,t[7]=d-m,t[2]=h-g,t[5]=d+m,t[8]=1-l-f,t}},6658:function(t){t.exports=function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}},3638:function(t,e,n){t.exports={adjoint:n(3369),clone:n(5723),copy:n(817),create:n(6396),determinant:n(9133),frob:n(7053),fromMat2:n(7068),fromMat4:n(5018),fromQuat:n(3955),identity:n(6658),invert:n(6028),multiply:n(4980),normalFromMat4:n(8093),rotate:n(8163),scale:n(2311),str:n(6321),translate:n(5068),transpose:n(6333)}},6028:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=c*a-s*l,h=-c*o+s*u,d=l*o-a*u,p=n*f+r*h+i*d;return p?(p=1/p,t[0]=f*p,t[1]=(-c*r+i*l)*p,t[2]=(s*r-i*a)*p,t[3]=h*p,t[4]=(c*n-i*u)*p,t[5]=(-s*n+i*o)*p,t[6]=d*p,t[7]=(-l*n+r*u)*p,t[8]=(a*n-r*o)*p,t):null}},4980:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=n[0],d=n[1],p=n[2],m=n[3],g=n[4],y=n[5],v=n[6],x=n[7],_=n[8];return t[0]=h*r+d*a+p*l,t[1]=h*i+d*s+p*c,t[2]=h*o+d*u+p*f,t[3]=m*r+g*a+y*l,t[4]=m*i+g*s+y*c,t[5]=m*o+g*u+y*f,t[6]=v*r+x*a+_*l,t[7]=v*i+x*s+_*c,t[8]=v*o+x*u+_*f,t}},8093:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15],v=n*s-r*a,x=n*u-i*a,_=n*l-o*a,b=r*u-i*s,w=r*l-o*s,M=i*l-o*u,A=c*m-f*p,T=c*g-h*p,E=c*y-d*p,C=f*g-h*m,k=f*y-d*m,S=h*y-d*g,O=v*S-x*k+_*C+b*E-w*T+M*A;return O?(O=1/O,t[0]=(s*S-u*k+l*C)*O,t[1]=(u*E-a*S-l*T)*O,t[2]=(a*k-s*E+l*A)*O,t[3]=(i*k-r*S-o*C)*O,t[4]=(n*S-i*E+o*T)*O,t[5]=(r*E-n*k-o*A)*O,t[6]=(m*M-g*w+y*b)*O,t[7]=(g*_-p*M-y*x)*O,t[8]=(p*w-m*_+y*v)*O,t):null}},8163:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=Math.sin(n),d=Math.cos(n);return t[0]=d*r+h*a,t[1]=d*i+h*s,t[2]=d*o+h*u,t[3]=d*a-h*r,t[4]=d*s-h*i,t[5]=d*u-h*o,t[6]=l,t[7]=c,t[8]=f,t}},2311:function(t){t.exports=function(t,e,n){var r=n[0],i=n[1];return t[0]=r*e[0],t[1]=r*e[1],t[2]=r*e[2],t[3]=i*e[3],t[4]=i*e[4],t[5]=i*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}},6321:function(t){t.exports=function(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"}},5068:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=n[0],d=n[1];return t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=h*r+d*a+l,t[7]=h*i+d*s+c,t[8]=h*o+d*u+f,t}},6333:function(t){t.exports=function(t,e){if(t===e){var n=e[1],r=e[2],i=e[5];t[1]=e[3],t[2]=e[6],t[3]=n,t[5]=e[7],t[6]=r,t[7]=i}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t}},5200:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15];return t[0]=s*(h*y-d*g)-f*(u*y-l*g)+m*(u*d-l*h),t[1]=-(r*(h*y-d*g)-f*(i*y-o*g)+m*(i*d-o*h)),t[2]=r*(u*y-l*g)-s*(i*y-o*g)+m*(i*l-o*u),t[3]=-(r*(u*d-l*h)-s*(i*d-o*h)+f*(i*l-o*u)),t[4]=-(a*(h*y-d*g)-c*(u*y-l*g)+p*(u*d-l*h)),t[5]=n*(h*y-d*g)-c*(i*y-o*g)+p*(i*d-o*h),t[6]=-(n*(u*y-l*g)-a*(i*y-o*g)+p*(i*l-o*u)),t[7]=n*(u*d-l*h)-a*(i*d-o*h)+c*(i*l-o*u),t[8]=a*(f*y-d*m)-c*(s*y-l*m)+p*(s*d-l*f),t[9]=-(n*(f*y-d*m)-c*(r*y-o*m)+p*(r*d-o*f)),t[10]=n*(s*y-l*m)-a*(r*y-o*m)+p*(r*l-o*s),t[11]=-(n*(s*d-l*f)-a*(r*d-o*f)+c*(r*l-o*s)),t[12]=-(a*(f*g-h*m)-c*(s*g-u*m)+p*(s*h-u*f)),t[13]=n*(f*g-h*m)-c*(r*g-i*m)+p*(r*h-i*f),t[14]=-(n*(s*g-u*m)-a*(r*g-i*m)+p*(r*u-i*s)),t[15]=n*(s*h-u*f)-a*(r*h-i*f)+c*(r*u-i*s),t}},1130:function(t){t.exports=function(t){var e=new Float32Array(16);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}},74:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}},3783:function(t){t.exports=function(){var t=new Float32Array(16);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},8844:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8],c=t[9],f=t[10],h=t[11],d=t[12],p=t[13],m=t[14],g=t[15];return(e*a-n*o)*(f*g-h*m)-(e*s-r*o)*(c*g-h*p)+(e*u-i*o)*(c*m-f*p)+(n*s-r*a)*(l*g-h*d)-(n*u-i*a)*(l*m-f*d)+(r*u-i*s)*(l*p-c*d)}},5936:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,f=r*s,h=i*a,d=i*s,p=i*u,m=o*a,g=o*s,y=o*u;return t[0]=1-f-p,t[1]=c+y,t[2]=h-g,t[3]=0,t[4]=c-y,t[5]=1-l-p,t[6]=d+m,t[7]=0,t[8]=h+g,t[9]=d-m,t[10]=1-l-f,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},5405:function(t){t.exports=function(t,e,n){var r,i,o,a=n[0],s=n[1],u=n[2],l=Math.sqrt(a*a+s*s+u*u);if(Math.abs(l)<1e-6)return null;return a*=l=1/l,s*=l,u*=l,r=Math.sin(e),i=Math.cos(e),o=1-i,t[0]=a*a*o+i,t[1]=s*a*o+u*r,t[2]=u*a*o-s*r,t[3]=0,t[4]=a*s*o-u*r,t[5]=s*s*o+i,t[6]=u*s*o+a*r,t[7]=0,t[8]=a*u*o+s*r,t[9]=s*u*o-a*r,t[10]=u*u*o+i,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3310:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=r+r,u=i+i,l=o+o,c=r*s,f=r*u,h=r*l,d=i*u,p=i*l,m=o*l,g=a*s,y=a*u,v=a*l;return t[0]=1-(d+m),t[1]=f+v,t[2]=h-y,t[3]=0,t[4]=f-v,t[5]=1-(c+m),t[6]=p+g,t[7]=0,t[8]=h+y,t[9]=p-g,t[10]=1-(c+d),t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}},1826:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=e[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},4692:function(t){t.exports=function(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=e[0],t[13]=e[1],t[14]=e[2],t[15]=1,t}},1349:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=r,t[6]=n,t[7]=0,t[8]=0,t[9]=-n,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},8034:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=0,t[2]=-n,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=n,t[9]=0,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},1655:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=n,t[2]=0,t[3]=0,t[4]=-n,t[5]=r,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3277:function(t){t.exports=function(t,e,n,r,i,o,a){var s=1/(n-e),u=1/(i-r),l=1/(o-a);return t[0]=2*o*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*o*u,t[6]=0,t[7]=0,t[8]=(n+e)*s,t[9]=(i+r)*u,t[10]=(a+o)*l,t[11]=-1,t[12]=0,t[13]=0,t[14]=a*o*2*l,t[15]=0,t}},257:function(t){t.exports=function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3503:function(t,e,n){t.exports={create:n(3783),clone:n(1130),copy:n(74),identity:n(257),transpose:n(2664),invert:n(6583),adjoint:n(5200),determinant:n(8844),multiply:n(9899),translate:n(573),scale:n(177),rotate:n(648),rotateX:n(5618),rotateY:n(5345),rotateZ:n(5208),fromRotation:n(5405),fromRotationTranslation:n(3310),fromScaling:n(1826),fromTranslation:n(4692),fromXRotation:n(1349),fromYRotation:n(8034),fromZRotation:n(1655),fromQuat:n(5936),frustum:n(3277),perspective:n(2649),perspectiveFromFieldOfView:n(7733),ortho:n(2337),lookAt:n(8541),str:n(6600)}},6583:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15],v=n*s-r*a,x=n*u-i*a,_=n*l-o*a,b=r*u-i*s,w=r*l-o*s,M=i*l-o*u,A=c*m-f*p,T=c*g-h*p,E=c*y-d*p,C=f*g-h*m,k=f*y-d*m,S=h*y-d*g,O=v*S-x*k+_*C+b*E-w*T+M*A;if(!O)return null;return O=1/O,t[0]=(s*S-u*k+l*C)*O,t[1]=(i*k-r*S-o*C)*O,t[2]=(m*M-g*w+y*b)*O,t[3]=(h*w-f*M-d*b)*O,t[4]=(u*E-a*S-l*T)*O,t[5]=(n*S-i*E+o*T)*O,t[6]=(g*_-p*M-y*x)*O,t[7]=(c*M-h*_+d*x)*O,t[8]=(a*k-s*E+l*A)*O,t[9]=(r*E-n*k-o*A)*O,t[10]=(p*w-m*_+y*v)*O,t[11]=(f*_-c*w-d*v)*O,t[12]=(s*T-a*C-u*A)*O,t[13]=(n*C-r*T+i*A)*O,t[14]=(m*x-p*b-g*v)*O,t[15]=(c*b-f*x+h*v)*O,t}},8541:function(t,e,n){var r=n(257);t.exports=function(t,e,n,i){var o,a,s,u,l,c,f,h,d,p,m=e[0],g=e[1],y=e[2],v=i[0],x=i[1],_=i[2],b=n[0],w=n[1],M=n[2];if(Math.abs(m-b)<1e-6&&Math.abs(g-w)<1e-6&&Math.abs(y-M)<1e-6)return r(t);f=m-b,h=g-w,d=y-M,p=1/Math.sqrt(f*f+h*h+d*d),o=x*(d*=p)-_*(h*=p),a=_*(f*=p)-v*d,s=v*h-x*f,(p=Math.sqrt(o*o+a*a+s*s))?(o*=p=1/p,a*=p,s*=p):(o=0,a=0,s=0);u=h*s-d*a,l=d*o-f*s,c=f*a-h*o,(p=Math.sqrt(u*u+l*l+c*c))?(u*=p=1/p,l*=p,c*=p):(u=0,l=0,c=0);return t[0]=o,t[1]=u,t[2]=f,t[3]=0,t[4]=a,t[5]=l,t[6]=h,t[7]=0,t[8]=s,t[9]=c,t[10]=d,t[11]=0,t[12]=-(o*m+a*g+s*y),t[13]=-(u*m+l*g+c*y),t[14]=-(f*m+h*g+d*y),t[15]=1,t}},9899:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=e[9],d=e[10],p=e[11],m=e[12],g=e[13],y=e[14],v=e[15],x=n[0],_=n[1],b=n[2],w=n[3];return t[0]=x*r+_*s+b*f+w*m,t[1]=x*i+_*u+b*h+w*g,t[2]=x*o+_*l+b*d+w*y,t[3]=x*a+_*c+b*p+w*v,x=n[4],_=n[5],b=n[6],w=n[7],t[4]=x*r+_*s+b*f+w*m,t[5]=x*i+_*u+b*h+w*g,t[6]=x*o+_*l+b*d+w*y,t[7]=x*a+_*c+b*p+w*v,x=n[8],_=n[9],b=n[10],w=n[11],t[8]=x*r+_*s+b*f+w*m,t[9]=x*i+_*u+b*h+w*g,t[10]=x*o+_*l+b*d+w*y,t[11]=x*a+_*c+b*p+w*v,x=n[12],_=n[13],b=n[14],w=n[15],t[12]=x*r+_*s+b*f+w*m,t[13]=x*i+_*u+b*h+w*g,t[14]=x*o+_*l+b*d+w*y,t[15]=x*a+_*c+b*p+w*v,t}},2337:function(t){t.exports=function(t,e,n,r,i,o,a){var s=1/(e-n),u=1/(r-i),l=1/(o-a);return t[0]=-2*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*u,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*l,t[11]=0,t[12]=(e+n)*s,t[13]=(i+r)*u,t[14]=(a+o)*l,t[15]=1,t}},2649:function(t){t.exports=function(t,e,n,r,i){var o=1/Math.tan(e/2),a=1/(r-i);return t[0]=o/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=o,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=(i+r)*a,t[11]=-1,t[12]=0,t[13]=0,t[14]=2*i*r*a,t[15]=0,t}},7733:function(t){t.exports=function(t,e,n,r){var i=Math.tan(e.upDegrees*Math.PI/180),o=Math.tan(e.downDegrees*Math.PI/180),a=Math.tan(e.leftDegrees*Math.PI/180),s=Math.tan(e.rightDegrees*Math.PI/180),u=2/(a+s),l=2/(i+o);return t[0]=u,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=l,t[6]=0,t[7]=0,t[8]=-(a-s)*u*.5,t[9]=(i-o)*l*.5,t[10]=r/(n-r),t[11]=-1,t[12]=0,t[13]=0,t[14]=r*n/(n-r),t[15]=0,t}},648:function(t){t.exports=function(t,e,n,r){var i,o,a,s,u,l,c,f,h,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k=r[0],S=r[1],O=r[2],P=Math.sqrt(k*k+S*S+O*O);if(Math.abs(P)<1e-6)return null;k*=P=1/P,S*=P,O*=P,i=Math.sin(n),o=Math.cos(n),a=1-o,s=e[0],u=e[1],l=e[2],c=e[3],f=e[4],h=e[5],d=e[6],p=e[7],m=e[8],g=e[9],y=e[10],v=e[11],x=k*k*a+o,_=S*k*a+O*i,b=O*k*a-S*i,w=k*S*a-O*i,M=S*S*a+o,A=O*S*a+k*i,T=k*O*a+S*i,E=S*O*a-k*i,C=O*O*a+o,t[0]=s*x+f*_+m*b,t[1]=u*x+h*_+g*b,t[2]=l*x+d*_+y*b,t[3]=c*x+p*_+v*b,t[4]=s*w+f*M+m*A,t[5]=u*w+h*M+g*A,t[6]=l*w+d*M+y*A,t[7]=c*w+p*M+v*A,t[8]=s*T+f*E+m*C,t[9]=u*T+h*E+g*C,t[10]=l*T+d*E+y*C,t[11]=c*T+p*E+v*C,e!==t&&(t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t}},5618:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[4],a=e[5],s=e[6],u=e[7],l=e[8],c=e[9],f=e[10],h=e[11];e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[4]=o*i+l*r,t[5]=a*i+c*r,t[6]=s*i+f*r,t[7]=u*i+h*r,t[8]=l*i-o*r,t[9]=c*i-a*r,t[10]=f*i-s*r,t[11]=h*i-u*r,t}},5345:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[8],c=e[9],f=e[10],h=e[11];e!==t&&(t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[0]=o*i-l*r,t[1]=a*i-c*r,t[2]=s*i-f*r,t[3]=u*i-h*r,t[8]=o*r+l*i,t[9]=a*r+c*i,t[10]=s*r+f*i,t[11]=u*r+h*i,t}},5208:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[4],c=e[5],f=e[6],h=e[7];e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[0]=o*i+l*r,t[1]=a*i+c*r,t[2]=s*i+f*r,t[3]=u*i+h*r,t[4]=l*i-o*r,t[5]=c*i-a*r,t[6]=f*i-s*r,t[7]=h*i-u*r,t}},177:function(t){t.exports=function(t,e,n){var r=n[0],i=n[1],o=n[2];return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}},6600:function(t){t.exports=function(t){return"mat4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+", "+t[9]+", "+t[10]+", "+t[11]+", "+t[12]+", "+t[13]+", "+t[14]+", "+t[15]+")"}},573:function(t){t.exports=function(t,e,n){var r,i,o,a,s,u,l,c,f,h,d,p,m=n[0],g=n[1],y=n[2];e===t?(t[12]=e[0]*m+e[4]*g+e[8]*y+e[12],t[13]=e[1]*m+e[5]*g+e[9]*y+e[13],t[14]=e[2]*m+e[6]*g+e[10]*y+e[14],t[15]=e[3]*m+e[7]*g+e[11]*y+e[15]):(r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=e[9],d=e[10],p=e[11],t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=l,t[7]=c,t[8]=f,t[9]=h,t[10]=d,t[11]=p,t[12]=r*m+s*g+f*y+e[12],t[13]=i*m+u*g+h*y+e[13],t[14]=o*m+l*g+d*y+e[14],t[15]=a*m+c*g+p*y+e[15]);return t}},2664:function(t){t.exports=function(t,e){if(t===e){var n=e[1],r=e[2],i=e[3],o=e[6],a=e[7],s=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=n,t[6]=e[9],t[7]=e[13],t[8]=r,t[9]=o,t[11]=e[14],t[12]=i,t[13]=a,t[14]=s}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t}},3197:function(t){t.exports=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t}},577:function(t,e,n){t.exports=function(t,e){var n=r(t[0],t[1],t[2]),a=r(e[0],e[1],e[2]);i(n,n),i(a,a);var s=o(n,a);return s>1?0:Math.acos(s)};var r=n(9666),i=n(1205),o=n(6517)},9913:function(t){t.exports=function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t[2]=Math.ceil(e[2]),t}},7091:function(t){t.exports=function(t){var e=new Float32Array(3);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}},3497:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}},1220:function(t){t.exports=function(){var t=new Float32Array(3);return t[0]=0,t[1]=0,t[2]=0,t}},6902:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2];return t[0]=i*u-o*s,t[1]=o*a-r*u,t[2]=r*s-i*a,t}},5140:function(t,e,n){t.exports=n(5055)},5055:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.sqrt(n*n+r*r+i*i)}},6669:function(t,e,n){t.exports=n(9737)},9737:function(t){t.exports=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t}},6517:function(t){t.exports=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}},6532:function(t){t.exports=1e-6},1077:function(t,e,n){t.exports=function(t,e){var n=t[0],i=t[1],o=t[2],a=e[0],s=e[1],u=e[2];return Math.abs(n-a)<=r*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(i-s)<=r*Math.max(1,Math.abs(i),Math.abs(s))&&Math.abs(o-u)<=r*Math.max(1,Math.abs(o),Math.abs(u))};var r=n(6532)},5696:function(t){t.exports=function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}},4280:function(t){t.exports=function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t[2]=Math.floor(e[2]),t}},9436:function(t,e,n){t.exports=function(t,e,n,i,o,a){var s,u;e||(e=3);n||(n=0);u=i?Math.min(i*e+n,t.length):t.length;for(s=n;s<u;s+=e)r[0]=t[s],r[1]=t[s+1],r[2]=t[s+2],o(r,r,a),t[s]=r[0],t[s+1]=r[1],t[s+2]=r[2];return t};var r=n(1220)()},9666:function(t){t.exports=function(t,e,n){var r=new Float32Array(3);return r[0]=t,r[1]=e,r[2]=n,r}},1982:function(t,e,n){t.exports={EPSILON:n(6532),create:n(1220),clone:n(7091),angle:n(577),fromValues:n(9666),copy:n(3497),set:n(3926),equals:n(1077),exactEquals:n(5696),add:n(3197),subtract:n(1040),sub:n(8560),multiply:n(8044),mul:n(8516),divide:n(9737),div:n(6669),min:n(4370),max:n(7484),floor:n(4280),ceil:n(9913),round:n(4622),scale:n(9404),scaleAndAdd:n(8544),distance:n(5055),dist:n(5140),squaredDistance:n(2340),sqrDist:n(3108),length:n(9852),len:n(4001),squaredLength:n(2775),sqrLen:n(9249),negate:n(2926),inverse:n(3346),normalize:n(1205),dot:n(6517),cross:n(6902),lerp:n(1817),random:n(9463),transformMat4:n(9564),transformMat3:n(553),transformQuat:n(4997),rotateX:n(6899),rotateY:n(8028),rotateZ:n(5493),forEach:n(9436)}},3346:function(t){t.exports=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}},4001:function(t,e,n){t.exports=n(9852)},9852:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}},1817:function(t){t.exports=function(t,e,n,r){var i=e[0],o=e[1],a=e[2];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=a+r*(n[2]-a),t}},7484:function(t){t.exports=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t}},4370:function(t){t.exports=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t}},8516:function(t,e,n){t.exports=n(8044)},8044:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t}},2926:function(t){t.exports=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}},1205:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o);return t}},9463:function(t){t.exports=function(t,e){e=e||1;var n=2*Math.random()*Math.PI,r=2*Math.random()-1,i=Math.sqrt(1-r*r)*e;return t[0]=Math.cos(n)*i,t[1]=Math.sin(n)*i,t[2]=r*e,t}},6899:function(t){t.exports=function(t,e,n,r){var i=n[1],o=n[2],a=e[1]-i,s=e[2]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=e[0],t[1]=i+a*l-s*u,t[2]=o+a*u+s*l,t}},8028:function(t){t.exports=function(t,e,n,r){var i=n[0],o=n[2],a=e[0]-i,s=e[2]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=i+s*u+a*l,t[1]=e[1],t[2]=o+s*l-a*u,t}},5493:function(t){t.exports=function(t,e,n,r){var i=n[0],o=n[1],a=e[0]-i,s=e[1]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=i+a*l-s*u,t[1]=o+a*u+s*l,t[2]=e[2],t}},4622:function(t){t.exports=function(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t[2]=Math.round(e[2]),t}},9404:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t}},8544:function(t){t.exports=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t}},3926:function(t){t.exports=function(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,t}},3108:function(t,e,n){t.exports=n(2340)},9249:function(t,e,n){t.exports=n(2775)},2340:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return n*n+r*r+i*i}},2775:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2];return e*e+n*n+r*r}},8560:function(t,e,n){t.exports=n(1040)},1040:function(t){t.exports=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}},553:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2];return t[0]=r*n[0]+i*n[3]+o*n[6],t[1]=r*n[1]+i*n[4]+o*n[7],t[2]=r*n[2]+i*n[5]+o*n[8],t}},9564:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,t}},4997:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2],l=n[3],c=l*r+s*o-u*i,f=l*i+u*r-a*o,h=l*o+a*i-s*r,d=-a*r-s*i-u*o;return t[0]=c*l+d*-a+f*-u-h*-s,t[1]=f*l+d*-s+h*-a-c*-u,t[2]=h*l+d*-u+c*-s-f*-a,t}},2108:function(t){t.exports=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t}},7682:function(t){t.exports=function(t){var e=new Float32Array(4);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}},9298:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}},3071:function(t){t.exports=function(){var t=new Float32Array(4);return t[0]=0,t[1]=0,t[2]=0,t[3]=0,t}},5476:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],o=e[3]-t[3];return Math.sqrt(n*n+r*r+i*i+o*o)}},1350:function(t){t.exports=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t[3]=e[3]/n[3],t}},216:function(t){t.exports=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]}},8741:function(t){t.exports=function(t,e,n,r){var i=new Float32Array(4);return i[0]=t,i[1]=e,i[2]=n,i[3]=r,i}},4663:function(t,e,n){t.exports={create:n(3071),clone:n(7682),fromValues:n(8741),copy:n(9298),set:n(6675),add:n(2108),subtract:n(6919),multiply:n(9363),divide:n(1350),min:n(9271),max:n(2045),scale:n(7705),scaleAndAdd:n(2869),distance:n(5476),squaredDistance:n(6733),length:n(7159),squaredLength:n(2678),negate:n(6977),inverse:n(3095),normalize:n(8308),dot:n(216),lerp:n(2710),random:n(9960),transformMat4:n(8773),transformQuat:n(2508)}},3095:function(t){t.exports=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t[3]=1/e[3],t}},7159:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3];return Math.sqrt(e*e+n*n+r*r+i*i)}},2710:function(t){t.exports=function(t,e,n,r){var i=e[0],o=e[1],a=e[2],s=e[3];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=a+r*(n[2]-a),t[3]=s+r*(n[3]-s),t}},2045:function(t){t.exports=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t[3]=Math.max(e[3],n[3]),t}},9271:function(t){t.exports=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t[3]=Math.min(e[3],n[3]),t}},9363:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t[3]=e[3]*n[3],t}},6977:function(t){t.exports=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=-e[3],t}},8308:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n*n+r*r+i*i+o*o;a>0&&(a=1/Math.sqrt(a),t[0]=n*a,t[1]=r*a,t[2]=i*a,t[3]=o*a);return t}},9960:function(t,e,n){var r=n(8308),i=n(7705);t.exports=function(t,e){return e=e||1,t[0]=Math.random(),t[1]=Math.random(),t[2]=Math.random(),t[3]=Math.random(),r(t,t),i(t,t,e),t}},7705:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t}},2869:function(t){t.exports=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t}},6675:function(t){t.exports=function(t,e,n,r,i){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t}},6733:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],o=e[3]-t[3];return n*n+r*r+i*i+o*o}},2678:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3];return e*e+n*n+r*r+i*i}},6919:function(t){t.exports=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t}},8773:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3];return t[0]=n[0]*r+n[4]*i+n[8]*o+n[12]*a,t[1]=n[1]*r+n[5]*i+n[9]*o+n[13]*a,t[2]=n[2]*r+n[6]*i+n[10]*o+n[14]*a,t[3]=n[3]*r+n[7]*i+n[11]*o+n[15]*a,t}},2508:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2],l=n[3],c=l*r+s*o-u*i,f=l*i+u*r-a*o,h=l*o+a*i-s*r,d=-a*r-s*i-u*o;return t[0]=c*l+d*-a+f*-u-h*-s,t[1]=f*l+d*-s+h*-a-c*-u,t[2]=h*l+d*-u+c*-s-f*-a,t[3]=e[3],t}},5616:function(t,e){var n;
|
|
38
|
+
var r=n(5616),i=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi;r.htmlPrefilter=function(t){return t.replace(i,"<$1></$2>")},n(7605),t.exports=Object.assign({annotationLayer:n(2075),camera:n(3578),choroplethFeature:n(3561),contourFeature:n(6761),domRenderer:n(9726),event:n(6409),feature:n(1275),featureLayer:n(6498),fetchQueue:n(5938),fileReader:n(3084),geo_action:n(8695),graphFeature:n(3187),heatmapFeature:n(9163),imageTile:n(4912),isolineFeature:n(2586),geojsonReader:n(5173),gridFeature:n(2499),layer:n(5156),lineFeature:n(9281),map:n(6211),mapInteractor:n(7908),markerFeature:n(2225),meshFeature:n(6124),object:n(1338),osmLayer:n(4880),pathFeature:n(2266),pointFeature:n(7541),polygonFeature:n(6645),quadFeature:n(3842),pixelmapFeature:n(7761),pixelmapLayer:n(534),renderer:n(2274),sceneObject:n(5402),textFeature:n(6546),tile:n(5289),tileCache:n(9123),tileLayer:n(9264),timestamp:n(77),trackFeature:n(338),transform:n(5325),typedef:n(3170),vectorFeature:n(6858),inherit:n(4626),version:n(4081),sha:n(9079),annotation:n(4655),util:n(642),jQuery:r,canvas:n(8074),svg:n(6488),vtkjs:n(394),webgl:n(8635),gui:n(4812),vgl:n(1611)},n(1098)),window&&!window.$&&(window.$=r),window&&!window.jQuery&&(window.jQuery=r),window&&!window.geojsMap&&(window.geojsMap=function(){var t=r(".geojs-map").map((function(t,e){return r(e).data("data-geojs-map")}));return 0===t.length?void 0:1===t.length?t[0]:t})},4626:function(t){t.exports=function(t,e){var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}},2586:function(t,e,n){var r=n(4626),i=n(6124),o=n(1098),a=n(642),s={17:[{l0:1,h0:2,l1:0,h1:2}],18:[{l0:0,h0:1,l1:2,h1:1}],20:[{l0:2,h0:0,l1:1,h1:0}],22:[{l0:2,h0:0,l1:2,h1:1}],21:[{l0:1,h0:2,l1:1,h1:0}],19:[{l0:0,h0:1,l1:0,h1:2}],1:[{l0:2,h0:3,l1:1,h1:3}],2:[{l0:0,h0:2,l1:3,h1:2}],4:[{l0:3,h0:1,l1:0,h1:1}],8:[{l0:1,h0:0,l1:2,h1:0}],14:[{l0:3,h0:1,l1:3,h1:2}],13:[{l0:2,h0:3,l1:2,h1:0}],11:[{l0:1,h0:0,l1:1,h1:3}],7:[{l0:0,h0:2,l1:0,h1:1}],3:[{l0:0,h0:2,l1:1,h1:3}],10:[{l0:1,h0:0,l1:3,h1:2}],12:[{l0:3,h0:1,l1:2,h1:0}],5:[{l0:2,h0:3,l1:0,h1:1}],6:[{l0:0,h0:2,l1:0,h1:1},{l0:3,h0:1,l1:3,h1:2}],9:[{l0:1,h0:0,l1:1,h1:3},{l0:2,h0:3,l1:2,h1:0}]},u=function(t){"use strict";if(!(this instanceof u))return new u(t);var e=n(5325),r=n(6409),l=n(6546);t=t||{},i.call(this,t);var c,f,h,d,p,m=this,g=this.draw,y=this._exit,v=this._init,x=this.modified,_=this._update;return this.featureType="isoline",this.contour=m.mesh,this.isoline=m.mesh,this._createIsolines=function(){var t,e=m.style.get("value"),n=void 0!==m.style("used")?m.style.get("used"):function(t,n){return a.isNonNullFinite(e(t,n))},r=!1,i=[],o=m._createMesh({used:n,value:e});return(t=m._getValueList(o)).length?(t.forEach((function(t){var e=m._isolinesForValue(o,t);e.length&&(i=i.concat(e),r=r||!!t.label)})),{lines:i,mesh:o,values:t,hasLabels:r}):{}},this._getValueList=function(t){var e,n,r,i,o,s,u,l=m.isoline,c=l.get("values")(t),f=l.get("spacing")(t),h=l.get("count")(t),d=l.get("autofit")(t),p=l.get("levels")(t);if(!t.numVertices||!t.numElements)return[];if(e=a.getMinMaxValues(t.value,l.get("min")(t),l.get("max")(t),!0),t.minValue=e.min,t.maxValue=e.max,(n=t.maxValue-t.minValue)<=0)return[];if(Array.isArray(c))c=(c=c.map((function(t,e){return{value:void 0!==t.value?t.value:t,position:e,level:t.level}}))).filter((function(e){return e.value>=t.minValue&&e.value<=t.maxValue}));else if(f||d)for(f||(r=n/(2*h/3),o=Math.floor(Math.log10(r)),s=Math.max(0,-o),f=(r=(r/=i=Math.pow(10,o))>=5?5:r>=2?2:1)*i),c=[],u=Math.ceil(t.minValue/f);u<=Math.floor(t.maxValue/f);u+=1)c.push({value:u*f,position:u,fixedDigits:s});else for(c=Array(h),u=0;u<h;u+=1)c[u]={value:t.minValue+n*(u+1)/(h+1),position:u+1};return p.length&&c.forEach((function(t,e){if(void 0===t.level){t.level=0;for(var n=0,r=p[0];n<p.length&&!(t.position%r);r*=p[n+=1])t.level=n+1}if(l.get("label")(t,t.position)){var i=l.get("labelText")(t,t.position);void 0===i&&(i=void 0!==t.fixedDigits?""+parseFloat(t.value.toFixed(t.fixedDigits)):""+t.value),i&&(t.label=i)}})),c},this._addSegment=function(t,e,n){var r,i,o,a,s,u,l=[e,n],c=t.length;for(t.push(l),i=0;i<2;i+=1){for(r=c-1;r>=0;r-=1){if(a=(o=t[r])[0],s=o[o.length-1],n[0]===a[0]&&n[1]===a[1])u=l.concat(o.slice(1));else{if(e[0]!==s[0]||e[1]!==s[1])continue;u=o.concat(l.slice(1))}t.splice(c,1),t[r]=l=u,c=r,e=l[0],n=l[l.length-1];break}if(r<0)break}return t},this._chainVertex=function(t,e,n){var r=n[0],i=n[1],o=3*r,a=3*i,s=(e.value-t.value[r])/(t.value[i]-t.value[r]),u=1-s;return{x:t.pos[o]*u+t.pos[a]*s,y:t.pos[o+1]*u+t.pos[a+1]*s,z:t.pos[o+2]*u+t.pos[a+2]*s}},this._isolinesForValue=function(t,e){var n,r,i,o,a=e.value,u=Array(t.value.length),l=[];for(n=u.length-1;n>=0;n-=1)u[n]=t.value[n]<=a?0:1;var c=t.verticesPerElement,f="square"===t.shape,h=t.elements,d=h.length;for(r=0;r<d;r+=c){if(f){if(0===(i=8*u[h[r]]+4*u[h[r+1]]+2*u[h[r+2]]+u[h[r+3]])||15===i)continue}else if(16===(i=16+4*u[h[r]]+2*u[h[r+1]]+u[h[r+2]])||23===i)continue;s[i].forEach((function(t){l=m._addSegment(l,[h[r+t.l0],h[r+t.h0]],[h[r+t.l1],h[r+t.h1]])}))}return o=l.map((function(n){var r=[];return n.forEach((function(n){var i=m._chainVertex(t,e,n);r.length&&i.x===r[r.length-1].x&&i.y===r[r.length-1].y||r.push(i)})),r.closed=r[0].x===r[r.length-1].x&&r[0].y===r[r.length-1].y,r.value=e.value,r.level=e.level,r.position=e.position,r.label=e.label,r})).filter((function(t){return t.length>1})),o},this.modified=function(){var t=x();return h&&h.modified(),p&&p.modified(),t},this.labelPositions=function(){if(m.dataTime().timestamp()>=m.buildTime().timestamp()&&m._build(),f=null,!p)return m;if(!(c&&c.hasLabels&&c.lines&&c.lines.length))return p.data([]),m;var t=m.isoline,n=t.get("labelSpacing"),r=t.get("labelOffset"),i=t.get("labelViewport")(c.mesh),o=m.gcs(),s=m.layer().map(),u=s.gcs(),l=s.rotation(),h=s.size(),d=[],g=0;return c.lines.forEach((function(t,c){if(t.label){var f,p,m,y,v,x,_,b,w,M,A,T=n(t.value,t.value.position),E=r(t.value,t.value.position)||0,C=s.gcsToDisplay(t,o),k=0;if(!(T<=0||isNaN(T))&&(g=Math.max(T,g),E=E+.5-Math.floor(E+.5),f=C.map((function(e,n){if(!t.closed&&n+1===C.length)return 0;var r=Math.sqrt(a.distance2dSquared(e,C[n+1<C.length?n+1:0]));return k+=r,r})),p=Math.floor(k/T)))for(A=e.transformCoordinates(o,u,t),y=(m=k/p)*E,v=0,x=0;x<C.length;x+=1){for(;v+f[x]>=y;)_=x+1===C.length?0:x+1,w=1-(b=(y-v)/f[x]),y+=m,i>0&&((M={x:C[x].x*w+C[_].x*b,y:C[x].y*w+C[_].y*b}).x<-i||M.x>h.width+i||M.y<-i||M.y>h.height+i)||d.push({x:A[x].x*w+A[_].x*b,y:A[x].y*w+A[_].y*b,z:A[x].z*w+A[_].z*b,line:t,rotation:Math.atan2(C[x].y-C[_].y,C[x].x-C[_].x)-l});v+=f[x]}}})),p.gcs(u),p.data(d),p.style("renderThreshold",2*g),f={zoom:s.zoom(),center:s.center(),rotation:l,size:h,labelViewport:i,maxSpacing:g,labelAutoUpdate:t.get("labelAutoUpdate")(c.mesh)},m},this.lastLabelPositions=function(){return Object.assign({},f)},this._updateLabelPositions=function(){var t=f;if(!t||!t.labelAutoUpdate)return m;var e=m.layer().map(),n=e.zoom(),r=e.size(),i=!!(Math.abs(n-t.zoom)>=2);if(!i&&t.labelViewport>0){var o=Math.sqrt(a.distance2dSquared(e.gcsToDisplay(e.center()),e.gcsToDisplay(t.center)))*Math.pow(2,t.zoom-n),s=t.labelViewport/2-2*t.maxSpacing-Math.max(r.width-t.size.width,r.height-t.size.height,0);i=i||o>=s}return i&&m.labelPositions().draw(),m},this._build=function(){if((c=m._createIsolines())&&c.lines&&c.lines.length){h||(h=m.layer().createFeature("line",{selectionAPI:!1,gcs:m.gcs(),visible:m.visible(void 0,!0),style:{closed:function(t){return t.closed}}}),m.dependentFeatures([h]));var t=m.style();if(h.data(c.lines).style({antialiasing:t.antialiasing,lineCap:t.lineCap,lineJoin:t.lineJoin,miterLimit:t.miterLimit,strokeWidth:t.strokeWidth,strokeStyle:t.strokeStyle,strokeColor:t.strokeColor,strokeOffset:t.strokeOffset,strokeOpacity:t.strokeOpacity}),c.hasLabels){if(!p){if(!(o.registries.features[m.layer().rendererName()]||{}).text){var e=o.rendererForFeatures(["text"]);d=o.createLayer("feature",m.layer().map(),{renderer:e}),m.layer().addChild(d),m.layer().node().append(d.node())}p=(d||m.layer()).createFeature("text",{selectionAPI:!1,gcs:m.gcs(),visible:m.visible(void 0,!0),style:{text:function(t){return t.line.label}}}).geoOn(r.pan,m._updateLabelPositions)}l.usedStyles.forEach((function(e){"visible"!==e&&p.style(e,t[e])})),m.dependentFeatures([h,p])}}else h&&h.data([]);return m.buildTime().modified(),m.labelPositions(),m},this._update=function(){return _.call(m),(m.dataTime().timestamp()>=m.buildTime().timestamp()||m.updateTime().timestamp()<=m.timestamp())&&m._build(),m.updateTime().modified(),m},this.draw=function(){var t=g();return h&&h.draw(),p&&p.draw(),t},this._exit=function(){p&&((d||m.layer())&&(d||m.layer()).deleteFeature(p),d&&m.layer()&&m.layer().removeChild(d)),h&&m.layer()&&m.layer().deleteFeature(h),p=null,d=null,h=null,m.dependentFeatures([]),y()},this._init=function(t){t=t||{},v.call(m,t);var e=Object.assign({},{opacity:1,value:function(t,e){return m.position()(t,e).z},rotateWithMap:!0,rotation:u.rotationFunction(),strokeWidth:function(t,e,n,r){return n.level+.5},strokeColor:{r:0,g:0,b:0},textStrokeColor:{r:1,g:1,b:1,a:.75},textStrokeWidth:2,fontSize:"12px"},void 0===t.style?{}:t.style);m.style(e),m.isoline(Object.assign({},{count:15,autofit:!0,levels:[5,5],label:function(t){return t.level>=1},labelSpacing:200,labelViewport:1e4,labelAutoUpdate:!0},t.mesh||{},t.contour||{},t.isoline||{})),(t.mesh||t.contour||t.isoline)&&m.dataTime().modified()},this};u.rotationFunction=function(t,e){var n={higher:function(t){return t.rotation},lower:function(t){return t.rotation+Math.PI},map:function(t){var e=t.rotation,n=a.wrapAngle(e,!0);return(n>Math.PI/2||n<-Math.PI/2)&&(e+=Math.PI),e},screen:function(t){var n=t.rotation,r=a.wrapAngle(n+e.rotation(),!0);return(r>Math.PI/2||r<-Math.PI/2)&&(n+=Math.PI),n}};return n[t]||n.higher},r(u,i),t.exports=u},5156:function(t,e,n){var r=n(4626),i=n(5402),o=n(1275),a=n(1098).checkRenderer,s=n(1098).rendererForFeatures,u=n(1098).rendererForAnnotations,l=function(t){"use strict";if(!(this instanceof l))return new l(t);t=t||{},i.call(this,t);var e,r=n(5616),o=n(77),c=n(2274),f=n(1098).createRenderer,h=n(1098).adjustLayerForRenderer,d=n(6409),p=this,m=this._exit,g=void 0===t.id?l.newLayerId():t.id,y=void 0===t.name?"":t.name,v=void 0===t.map?null:t.map,x=null,_=void 0===t.canvas?null:t.canvas,b=t.renderer instanceof c?t.renderer:null,w=!1,M=void 0!==t.renderer?t.renderer instanceof c?t.renderer.api():t.renderer:t.annotations?u(t.annotations):s(t.features),A=void 0===t.autoshareRenderer||t.autoshareRenderer,T=o(),E=o(),C=void 0===t.sticky||t.sticky,k=void 0===t.active||t.active,S=void 0===t.opacity?1:t.opacity,O=t.attribution||null,P=void 0===t.visible||t.visible,L=void 0===t.selectionAPI||t.selectionAPI;if(M=a(M),!v)throw new Error("Layers must be initialized on a map.");function R(){return(p.parent()||p.map()).children().filter((function(t){return t instanceof l}))}if(this.rendererName=function(){return M},this.autoshareRenderer=function(){return A},this.zIndex=function(t,n){return void 0===t?e:(n||R().reverse().forEach((function(e){e!==p&&e.zIndex()===t&&e.zIndex(t+1)})),t!==e&&(e=t,x.css("z-index",e),p.geoTrigger(d.layerMove,{layer:p})),p)},this.moveUp=function(t){var e,n,r,i,o=null;for(void 0===t&&(t=1),i=1,t<0&&(i=-1,t=-t),e=R().sort((function(t,e){return i*(t.zIndex()-e.zIndex())})),n=0;n<e.length;n+=1)if(null===o)e[n]===p&&(o=n);else{if(!(n-o<=t))break;r=p.zIndex(),p.zIndex(e[n].zIndex(),!0),e[n].zIndex(r,!0)}return p},this.moveDown=function(t){return void 0===t&&(t=1),p.moveUp(-t)},this.moveToTop=function(){return p.moveUp(R().length-1)},this.moveToBottom=function(){return p.moveDown(R().length-1)},this.sticky=function(){return C},this.active=function(t){return void 0===t?k:(k!==t&&(k=t,x.toggleClass("active",k)),p)},this.node=function(){return x},this.id=function(t){return void 0===t?g:(g=null===t?l.newLayerId():t,p.modified(),p)},this.name=function(t){return void 0===t?y:(y=t,x.attr("id",y),p.modified(),p)},this.map=function(){return v},this.renderer=function(){return b},this._renderer=function(t){return void 0===t?b:(b=t,p)},this.canvas=function(){return _},this._canvas=function(t){return void 0===t?_:(_=t,p)},this.dataTime=function(){return T},this.updateTime=function(){return E},this.initialized=function(t){return void 0!==t?(w=t,p):w},this.toLocal=function(t){return t},this.fromLocal=function(t){return t},this.attribution=function(t){return void 0!==t?(O=t,p.map().updateAttribution(),p):O},this.visible=function(t){return void 0===t?P:(P!==t&&(P=t,x.toggleClass("hidden",!P),p.modified()),p)},this.selectionAPI=function(t){return void 0===t?L:(L!==t&&(L=t),p)},this._init=function(e){if(w)return p;v.node().append(x);var n=Object.assign({},t);return delete n.map,b?p._canvas(b.canvas()):null===M?(p._renderer(null),p._canvas(x)):_?p._renderer(f(M,p,_,n)):(p._renderer(f(M,p,void 0,n)),p._canvas(b.canvas())),x.toggleClass("active",p.active()),w=!0,e||(p.geoOn(d.resize,(function(t){p._update({event:t})})),p.geoOn(d.pan,(function(t){p._update({event:t})})),p.geoOn(d.rotate,(function(t){p._update({event:t})})),p.geoOn(d.zoom,(function(t){p._update({event:t})}))),p},this._exit=function(){p.geoOff(),b&&b._exit(),x.off(),x.remove(),t={},p._canvas(null),p._renderer(null),m()},this._update=function(t){return p},this.width=function(){return p.map().size().width},this.height=function(){return p.map().size().height},this.opacity=function(t){return void 0!==t?(S=t,x.css("opacity",S),p):S},(x=r(document.createElement("div"))).addClass("geojs-layer"),x.attr("renderer",M),y&&x.attr("id",y),p.opacity(S),p.visible(P),void 0===t.zIndex){var I=-1;R().forEach((function(t){void 0!==t.zIndex()&&(I=Math.max(I,t.zIndex()))})),t.zIndex=I+1}return p.zIndex(t.zIndex),h("all",p),p};l.newLayerId=function(){"use strict";var t=1;return function(){var e=t;return t+=1,e}}(),l.create=function(t,e){"use strict";if((e=e||{}).type=e.type||"feature",e.renderer=void 0===e.renderer?"webgl":e.renderer,e.renderer=a(e.renderer),!e.renderer)return console.warn("Invalid renderer"),null;var n=t.createLayer(e.type,e);return n?(e.features&&e.features.forEach((function(t){t.data=t.data||e.data,t.feature=o.create(n,t)})),n):(console.warn("Unable to create a layer"),null)},r(l,i),t.exports=l},9281:function(t,e,n){var r=n(4626),i=n(1275),o=n(77),a=n(5325),s=n(642),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},i.call(this,t);var e,n=this,r=this._init,l=o();return this.featureType="line",this._subfeatureStyles={lineCap:!0,lineJoin:!0,strokeColor:!0,strokeOffset:!0,strokeOpacity:!0,strokeWidth:!0},this.line=function(t){return void 0===t?n.style("line"):(n.style("line",t),n.dataTime().modified(),n.modified(),n)},this.position=function(t){return void 0===t?n.style("position"):(n.style("position",t),n.dataTime().modified(),n.modified(),n)},this._updatePointSearchInfo=function(){if(l.timestamp()>=n.dataTime().timestamp()&&l.timestamp()>=n.timestamp())return e;l.modified(),e=[];for(var t=n.data(),r=n.line(),i=n.style.get("strokeWidth"),o=s.isFunction(n.style("strokeWidth"))?void 0:i(),u=n.position(),c=n.style.get("closed"),f=s.isFunction(n.style("closed"))?void 0:c(),h=n.style.get("uniformLine"),d=s.isFunction(n.style("uniformLine"))?void 0:h(),p=n.gcs(),m=n.layer().map().gcs(),g=a.onlyInvertedY(p,m),y=0;y<t.length;y+=1){for(var v=t[y],x=void 0===f?c(v,y):f,_=void 0,b=void 0,w=void 0,M=void 0,A=void 0,T=void 0,E=void 0,C=void 0,k=[],S=void 0===d?h(v,y):d,O=r(v,y),P=0;P<O.length;P+=1){var L=O[P],R=u(L,P,v,y);g?R={x:R.x,y:-R.y}:p!==m&&(R=a.transformCoordinates(p,m,R)),void 0===T&&(T={x:R.x,y:R.y}),void 0===E&&(E={x:R.x,y:R.y}),R.x<T.x&&(T.x=R.x),R.x>E.x&&(E.x=R.x),R.y<T.y&&(T.y=R.y),R.y>E.y&&(E.y=R.y),S&&P||(C=void 0===o?i(L,P,v,y):o);var I=Math.ceil(C/2)+2;(void 0===E.r||I>E.r)&&(E.r=I);var D=I*I;_&&k.push({u:R,v:_,r:w>I?w:I,r2:M>D?M:D,i:P,j:b}),_=R,b=P,w=I,M=D,!A&&x&&(A={p:R,r:I,r2:D,i:P})}x&&A&&(_.x!==A.p.x||_.y!==A.p.y)&&k.push({u:_,v:A.p,r:w>A.r?w:A.r,r2:M>A.r2?M:A.r2,i:b,j:A.i}),k.min=T,k.max=E,e.push(k)}return e},this.pointSearch=function(t,r){var i=n.data(),o=[],u=[],l={};if(!i||!i.length||!n.layer())return{found:u,index:o,extra:l};n._updatePointSearchInfo();var c=n.layer().map();r=null===r?c.gcs():void 0===r?c.ingcs():r;var f,h,d,p,m=c.unitsPerPixel(c.zoom()),g=m*m,y=a.transformCoordinates(r,c.gcs(),t),v=n.style.get("strokeWidth"),x=n.style.get("strokeOpacity"),_=n.line();for(h=0;h<e.length;h+=1)for(p=e[h],f=null,d=0;d<p.length;d+=1)if(s.distance2dToLineSquared(y,p[d].u,p[d].v)<=p[d].r2*g&&(f||(f=_(i[h],h)),(x(f[p[d].i],p[d].i,i[h],h)>0||x(f[p[d].j],p[d].j,i[h],h)>0)&&(v(f[p[d].i],p[d].i,i[h],h)>0||v(f[p[d].j],p[d].j,i[h],h)>0))){u.push(i[h]),o.push(h),l[h]=d;break}return{found:u,index:o,extra:l}},this.polygonSearch=function(t,r,i){var o,u,l=n.data(),c=[],f=[],h={},d=n.layer().map(),p=n.style.get("strokeWidth"),m=n.style.get("strokeOpacity"),g=n.line();if(i=null===i?d.gcs():void 0===i?d.ingcs():i,t.outer||(t={outer:t,inner:[]}),!l||!l.length||t.outer.length<3)return{found:f,index:c,extra:h};(r=r||{}).partial=r.partial||!1,(t={outer:a.transformCoordinates(i,d.gcs(),t.outer),inner:(t.inner||[]).map((function(t){return a.transformCoordinates(i,d.gcs(),t)}))}).outer.forEach((function(t){o||(o={x:t.x,y:t.y},u={x:t.x,y:t.y}),t.x<o.x&&(o.x=t.x),t.x>u.x&&(u.x=t.x),t.y<o.y&&(o.y=t.y),t.y>u.y&&(u.y=t.y)})),n._updatePointSearchInfo();var y,v,x,_,b,w,M=d.unitsPerPixel(d.zoom());for(y=0;y<e.length;y+=1)if(!(!(x=e[y]).max||x.max.x<o.x-x.max.r*M||x.min.x>u.x+x.max.r*M||x.max.y<o.y-x.max.r*M||x.min.y>u.y+x.max.r*M)){var A=void 0,T=void 0,E=void 0;for(v=0;v<x.length;v+=1)if(_=x[v].u,b=x[v].v,w=x[v].r,!(_.x<o.x-w*M&&b.x<o.x-w*M||_.x>u.x+w*M&&b.x>u.x+w*M||_.y<o.y-w*M&&b.y<o.y-w*M||_.y>u.y+w*M&&b.y>u.y+w*M||(E||(E=g(l[y],y)),m(E[x[v].i],x[v].i,l[y],y)<=0&&m(E[x[v].j],x[v].j,l[y],y)<=0||p(E[x[v].i],x[v].i,l[y],y)<=0&&p(E[x[v].j],x[v].j,l[y],y)<=0))){var C=s.distanceToPolygon2d(_,t),k=s.distanceToPolygon2d(b,t);if(C>-w*M&&C<w*M||k>-w*M&&k<w&M||C*k<0){T=!0;break}if(s.crossedLineSegmentPolygon2d(_,b,t)){T=!0;break}for(var S=w*w*M*M,O=0;O<t.outer.length&&!T;O+=1)T=s.distance2dToLineSquared(t.outer[O],_,b)<S;for(var P=0;P<t.inner.length&&!T;P+=1)for(var L=0;L<t.inner[P].length&&!T;L+=1)T=s.distance2dToLineSquared(t.inner[P][L],_,b)<S;if(T)break;C>0&&(A=!0)}(!r.partial&&A&&!T||r.partial&&(A||T))&&(c.push(y),f.push(l[y]),h[y]={partial:T,segment:v<e[y].length?v:0})}return{found:f,index:c,extra:h}},this.rdpSimplifyData=function(t,e,r,i){t=t||n.data(),r=r||n.style.get("position"),i=i||n.style.get("line");var o=n.layer().map(),u=o.gcs(),l=n.gcs(),c=n.style.get("closed");return void 0===e&&(e=.5*o.unitsPerPixel(o.zoom())),t=t.map((function(t,n){var o=i(t,n),f=a.transformCoordinates(l,u,o.map((function(e,i){return r(e,i,t,n)}))),h=s.rdpLineSimplify(f,e,c(t,n),[]);for(var d in(h.length<2||2===h.length&&s.distance2dSquared(h[0],h[1])<e*e)&&(h=[]),h=a.transformCoordinates(u,l,h),t)!t.hasOwnProperty(d)||Array.isArray(t)&&d>=0&&d<t.length||(h[d]=t[d]);return h})),n.style("position",s.identityFunction),n.style("line",s.identityFunction),n.data(t),n},this._init=function(t){t=t||{},r.call(n,t);var e=Object.assign({},{strokeWidth:1,strokeColor:{r:1,g:.8431372549,b:0},strokeStyle:"solid",strokeOpacity:1,antialiasing:2,closed:!1,line:s.identityFunction,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){return t.length>=3?t.slice(0,3):[0,0,0]}},void 0===t.style?{}:t.style);return void 0!==t.line&&(e.line=t.line),void 0!==t.position&&(e.position=t.position),n.style(e),n.dataTime().modified(),n},this._init(t),this};u.create=function(t,e){"use strict";return(e=e||{}).type="line",i.create(t,e)},u.capabilities={feature:"line",basic:"line.basic",multicolor:"line.multicolor"},r(u,i),t.exports=u},6211:function(t,e,n){var r=n(5616),i=n(4626),o=n(5402),a=function(t){"use strict";if(!(this instanceof a))return new a(t);if(void 0===(t=t||{}).node||null===t.node)return console.warn("map creation requires a node"),this;o.call(this,t);var e,i,s,u,l,c=n(3578),f=n(5325),h=n(642),d=n(1098),p=n(6409),m=n(7908),g=n(4231),y=this,v=this._exit,x=r(t.node),_=t.width||x.width()||512,b=t.height||x.height()||512,w=void 0===t.gcs?"EPSG:3857":t.gcs,M=void 0===t.ingcs?"EPSG:4326":t.ingcs,A={x:0,y:0},T=void 0===t.zoom?4:t.zoom,E=t.rotation?t.rotation:0,C=null,k=null,S={min:0,max:16,origMin:0},O=null,P=null,L=!!t.discreteZoom,R="function"==typeof t.allowRotation?t.allowRotation:void 0===t.allowRotation||!!t.allowRotation,I=t.maxBounds||{},D=t.camera||c(),N=t.animationQueue||[],F=void 0===t.autoResize||t.autoResize,j=t.autoshareRenderer,z=((I.left||0)+(I.right||0))/2,B=((I.bottom||0)+(I.top||0))/2;function V(){var t;void 0!==document.hidden?t="hidden":void 0!==document.msHidden?t="msHidden":void 0!==document.webkitHidden&&(t="webkitHidden"),y.geoTrigger(document[t]?p.hidden:p.unhidden)}function q(t){var e;void 0!==document.hidden?e="visibilitychange":void 0!==document.msHidden?e="msvisibilitychange":void 0!==document.webkitHidden&&(e="webkitvisibilitychange"),document.removeEventListener(e,V),!1!==t&&document.addEventListener(e,V)}function G(t,e){var n=t.zIndex(),r=e.zIndex();if(n!==r)return n-r;var i=t.node()[0],o=e.node()[0],a=i&&i.parentNode,s=o&&o.parentNode;if(a&&s&&a===s){var u=Array.from(a.children),l=u.indexOf(i),c=u.indexOf(o);if(l>=0&&c>=0)return l-c}return a?-1:s?1:0}function U(t,e,n,r,i){t.globalAlpha=e,i&&(t.globalCompositeOperation=i);var o=n.css("transform");o&&"matrix("===o.substr(0,7)?t.setTransform.apply(t,o.substr(7,o.length-8).split(",").map(parseFloat)):t.setTransform(1,0,0,1,0,0),t.drawImage(r,0,0),t.globalCompositeOperation="source-over"}function H(){for(var t=N.splice(0,N.length),e=1;e<t.length;e+=1)try{t[e].apply(y,arguments)}catch(t){console.error(t)}}function W(t,e,n){var r=e.width/2,i=e.height/2,o=Math.sin(n),a=Math.cos(n),s={},u={},l={},c={};return s.x=t.x+-r*a- -i*o,s.y=t.y+-r*o+-i*a,u.x=t.x+r*a- -i*o,u.y=t.y+r*o+-i*a,l.x=t.x+-r*a-i*o,l.y=t.y+-r*o+i*a,c.x=t.x+r*a-i*o,c.y=t.y+r*o+i*a,{left:Math.min(s.x,u.x,l.x,c.x),right:Math.max(s.x,u.x,l.x,c.x),bottom:Math.min(s.y,u.y,l.y,c.y),top:Math.max(s.y,u.y,l.y,c.y)}}function X(t,n){void 0===n&&(n=E),t=function(t,e){return e&&(t=W({x:(t.left+t.right)/2,y:(t.top+t.bottom)/2},{width:Math.abs(t.left-t.right),height:Math.abs(t.top-t.bottom)},e)),t}(t,n);var r=function(t){var e,n,r=t.right-t.left,i=t.top-t.bottom,o=Math.abs(r/i),a=_/b;return o>a?(e=1,n=o/a):(n=1,e=a/o),{x:e,y:n}}(t);return r.y>r.x?-Math.log2(Math.abs(t.right-t.left)*r.x/(_*e)):-Math.log2(Math.abs(t.top-t.bottom)*r.y/(b*e))}function K(){S.min=u?Math.max(S.origMin,X(I)):S.origMin}function Q(t,e,n){if(!R)return 0;if(e||"function"!=typeof R||(t=R(t)),!n){var r=2*Math.PI;t=t%r+(t>=0?0:r),Math.min(Math.abs(t),Math.abs(t-r))<1e-5&&(t=0)}return t}function Y(t,e,n,r){if(!i&&!s)return t;var o,a,u=I;if(e){u=Object.assign({},I);var l,c,f=Math.abs(t.right-t.left),h=Math.abs(t.top-t.bottom),d=Math.abs(Math.sin(e)),p=Math.abs(Math.cos(e));if(t.width&&t.height)l=t.width,c=t.height;else if(Math.abs(d-p)<5e-4)if(_&&b){var m=Math.abs(_/b),g=Math.pow(1+Math.pow(m,2),.5);c=(l=Math.max(f,h)/g)*m}else l=f*p,c=h*d;else l=(p*f-d*h)/(p*p-d*d),c=(p*h-d*f)/(p*p-d*d);var y=f-Math.max(p*l,d*c),v=h-Math.max(p*c,d*l);u.left-=y,u.right+=y,u.top+=v,u.bottom-=v}return r&&(u={left:u.left-(t.right-t.left)/2,right:u.right+(t.right-t.left)/2,top:u.top-(t.bottom-t.top)/2,bottom:u.bottom+(t.bottom-t.top)/2}),i&&(t.right-t.left>u.right-u.left?o=u.left-(t.right-t.left-(u.right-u.left))/2-t.left:t.left<u.left?o=u.left-t.left:t.right>u.right&&(o=u.right-t.right),o&&(!n||n.x*o>0)&&(n&&Math.abs(o)>Math.abs(n.x*n.unit)&&(o=Math.abs(n.x*n.unit)*o/Math.abs(o)),t={left:t.left+=o,right:t.right+=o,top:t.top,bottom:t.bottom})),s&&(t.top-t.bottom>u.top-u.bottom?a=u.bottom-(t.top-t.bottom-(u.top-u.bottom))/2-t.bottom:t.top>u.top?a=u.top-t.top:t.bottom<u.bottom&&(a=u.bottom-t.bottom),a&&(!n||-n.y*a>0)&&(n&&Math.abs(a)>Math.abs(n.y*n.unit)&&(a=Math.abs(n.y*n.unit)*a/Math.abs(a)),t={top:t.top+=a,bottom:t.bottom+=a,left:t.left,right:t.right})),t}function $(t,e){if(D.rotation=e||0,t.width&&t.height&&e){var n=(t.left+t.right)/2,r=(t.top+t.bottom)/2;D.viewFromCenterSizeRotation({x:n,y:r},t,e)}else D.bounds=t;A={x:(D.bounds.left+D.bounds.right)/2,y:(D.bounds.top+D.bounds.bottom)/2}}function Z(){y.size({width:x.width(),height:x.height()})}return I.left=f.transformCoordinates(I.gcs||M,w,{x:void 0!==I.left?I.left:-180,y:B}).x,I.right=f.transformCoordinates(I.gcs||M,w,{x:void 0!==I.right?I.right:180,y:B}).x,I.top=void 0!==I.top?f.transformCoordinates(I.gcs||M,w,{x:z,y:I.top}).y:I.right,I.bottom=void 0!==I.bottom?f.transformCoordinates(I.gcs||M,w,{x:z,y:I.bottom}).y:I.left,e=t.unitsPerPixel||(I.right-I.left)/256,D.viewport={width:_,height:b,left:x.offset().left,top:x.offset().top},t.center=h.normalizeCoordinates(t.center),i=void 0!==t.clampBoundsX&&t.clampBoundsX,s=void 0===t.clampBoundsY||t.clampBoundsY,u=void 0===t.clampZoom||t.clampZoom,this.unitsPerPixel=function(t,n){return t=t||0,n?(e=Math.pow(2,t)*n,y.draw(),y):Math.pow(2,-t)*e},this.animationQueue=function(t){if(void 0===t)return N;if(t!==N){if(N.length){t.length&&t[0]!==N[0]&&window.cancelAnimationFrame(N[0]);for(var e=t.length?1:0;e<N.length;e+=1)t.push(N[e])}N=t}return y},this.autoResize=function(t){return void 0===t?F:(t!==F&&(r(window).off("resize",Z),(F=t)&&r(window).on("resize",Z)),y)},this.clampBoundsX=function(t){return void 0===t?i:(t!==i&&(i=!!t,y.pan({x:0,y:0})),y)},this.clampBoundsY=function(t){return void 0===t?s:(t!==s&&(s=!!t,y.pan({x:0,y:0})),y)},this.clampZoom=function(t){return void 0===t?u:(t!==u&&(u=!!t,K(),y.zoom(T)),y)},this.allowRotation=function(t){return void 0===t?R:("function"!=typeof t&&(t=!!t),t!==R&&(R=t,y.rotation(E)),y)},this.origin=function(){return Object.assign({},l)},this.camera=function(){return D},this.gcs=function(t){if(void 0===t)return w;if(t!==w){var e=y.center(void 0,void 0);w=t,K();var n=y._fix_zoom(T);n!==T&&y.zoom(n),y.center(e,void 0)}return y},this.ingcs=function(t){return void 0===t?M:(M=t,y)},this.node=function(){return x},this.zoom=function(t,e,n,r,i){if(void 0===t)return T;var o,a,s=e&&(e.mapgcs||e.geo)&&e.map;if(s&&(r=!0),(t=y._fix_zoom(t,n))===T)return y;if(T=t,a=y.boundsFromZoomAndCenter(t,A,E,null,n,r),y.modified(),$(a,E),o={zoomLevel:T,screenPosition:e?e.map:void 0},i&&"pan"!==i||y.geoTrigger(p.zoom,o),s){var u=y.gcsToDisplay(e.mapgcs||e.geo,e.mapgcs?null:void 0);y.pan({x:e.map.x-u.x,y:e.map.y-u.y},n,!0,i)}else y.pan({x:0,y:0},n,r,i);return y},this.zoomAndCenter=function(t,e,n,r,i,o){return this.zoom(t,void 0,r,i,o||"pan"),this.center(e,n,r,i,o),this},this.pan=function(t,e,n,r){var i={screenDelta:t};if(t.x||t.y){var o=y.unitsPerPixel(T),a=Math.sin(E),s=Math.cos(E);D.pan({x:(t.x*s- -t.y*a)*o,y:(t.x*a+-t.y*s)*o})}var u=D.bounds;if((u=Y(u,E,"limited"===n?{x:t.x,y:t.y,unit:o}:void 0,!0===n))!==D.bounds){var l=y.gcsToDisplay({x:D.bounds.left,y:D.bounds.top},null);$(u=y.boundsFromZoomAndCenter(T,{x:(u.left+u.right)/2,y:(u.top+u.bottom)/2},E,null,e,!0),E);var c=y.gcsToDisplay({x:D.bounds.left,y:D.bounds.top},null);i.screenDelta.x+=c.x-l.x,i.screenDelta.y+=c.y-l.y}return A=D.displayToWorld({x:_/2,y:b/2}),r||y.geoTrigger(p.pan,i),y.modified(),y},this.rotation=function(t,e,n){if(void 0===t)return E;var r=e&&e.geo&&e.map;if((t=Q(t,n))===E)return y;E=t;var i=y.boundsFromZoomAndCenter(T,A,E,null,n,!0);y.modified(),$(i,E);var o={rotation:E,screenPosition:e?e.map:void 0};if(y.geoTrigger(p.rotate,o),r){var a=y.gcsToDisplay(e.geo);y.pan({x:e.map.x-a.x,y:e.map.y-a.y},void 0,!0)}else y.pan({x:0,y:0},void 0,!0);return K(),y.zoom(T,void 0,n),y},this.center=function(t,e,n,r,i){var o;return void 0===t?o=Object.assign({},y.worldToGcs(A,e)):(o=y.gcsToWorld(t,e),$(y.boundsFromZoomAndCenter(T,o,E,null,n,r),E),y.modified(),i||y.geoTrigger(p.pan,{screenDelta:{x:0,y:0}}),y)},this.createLayer=function(t,e){e=e||{},void 0!==y.autoshareRenderer()&&(e=Object.assign({autoshareRenderer:y.autoshareRenderer()},e));var n=d.createLayer(t,y,e);return n&&(y.addChild(n),y.children().forEach((function(t){t instanceof g&&t.moveToTop()})),n._update(),y.modified(),y.geoTrigger(p.layerAdd,{target:y,layer:n})),n},this.deleteLayer=function(t){return null!=t&&(t._exit(),y.removeChild(t),y.modified(),y.geoTrigger(p.layerRemove,{target:y,layer:t})),t},this.size=function(t){if(void 0===t)return{width:_,height:b};var e=y.center();_=t.width||_,b=t.height||b,K();var n=y._fix_zoom(T);return n!==T&&y.zoom(n),y.camera().viewport={width:_,height:b,left:x.offset().left,top:x.offset().top},y.center(e),y.geoTrigger(p.resize,{target:y,width:_,height:b}),y.modified(),y},this.rotatedSize=function(){if(!this.rotation())return{width:_,height:b};var t=W({x:0,y:0},{width:_,height:b},y.rotation());return{width:Math.abs(t.right-t.left),height:Math.abs(t.top-t.bottom)}},this.gcsToWorld=function(t,e){return Array.isArray(t)?t.map((function(t){return y.gcsToWorld(t,e)})):((e=null===e?w:void 0===e?M:e)!==w&&(t=f.transformCoordinates(e,w,t)),l.x||l.y||l.z?t=f.affineForward({origin:l},[t])[0]:"z"in t||(t={x:t.x,y:t.y,z:0}),t)},this.worldToGcs=function(t,e){return Array.isArray(t)?t.map((function(t){return y.worldToGcs(t,e)})):(l.x||l.y||l.z?t=f.affineInverse({origin:l},[t])[0]:"z"in t||(t={x:t.x,y:t.y,z:0}),(e=null===e?w:void 0===e?M:e)!==w&&(t=f.transformCoordinates(w,e,t)),t)},this.gcsToDisplay=function(t,e){return t=y.gcsToWorld(t,e),y.worldToDisplay(t)},this.worldToDisplay=function(t){return Array.isArray(t)?t.map((function(t){return D.worldToDisplay(t)})):D.worldToDisplay(t)},this.displayToGcs=function(t,e){return t=y.displayToWorld(t),y.worldToGcs(t,e)},this.displayToWorld=function(t){return Array.isArray(t)?t.map((function(t){return D.displayToWorld(t)})):D.displayToWorld(t)},this.draw=function(){var t,e=y.children();for(y.geoTrigger(p.draw,{target:y}),y._update(),t=0;t<e.length;t+=1)e[t].draw();return y.geoTrigger(p.drawEnd,{target:y}),y},this.fileReader=function(t,e){return void 0===t?C:("string"==typeof t?((e=e||{}).layer||(e.layer=y.createLayer("feature",Object.assign({},e))),e.renderer=e.layer.renderer().api(),C=d.createFileReader(t,e)):C=t,y)},this._init=function(t){if(null==x)throw new Error("Map require DIV node");return x.data("data-geojs-map")&&r.isFunction(x.data("data-geojs-map").exit)&&x.data("data-geojs-map").exit(),x.addClass("geojs-map"),x.data("data-geojs-map",y),q(),y},this._update=function(t){var e,n=y.children();for(e=0;e<n.length;e+=1)n[e]._update(t);return y},this.exit=function(){q(!1);var t,e=y.children();for(t=e.length-1;t>=0;t-=1)e[t]._exit(),y.removeChild(e[t]);y.interactor()&&(y.interactor().destroy(),y.interactor(null)),N=[],y.node().data("data-geojs-map",null),y.node().off(".geo"),y.node().empty(),r(window).off("resize",Z),v()},this.interactor=function(t){return void 0===t?k:(k&&k!==t&&k.destroy(),(k=t)&&(x.attr("tabindex")||x.attr("tabindex",0),k.map(y)),y)},this.zoomRange=function(t,e){return void 0===t?Object.assign({},S):(void 0!==t.max&&(S.max=t.max),void 0!==t.min&&(S.min=S.origMin=t.min),K(),e||y.zoom(T),y)},this.transition=function(t,e,n){if(void 0===t)return O;if(O){var i=h.deepMerge({},O.end);return i.center&&w!==M&&(i.center=f.transformCoordinates(w,M,i.center)),P=Object.assign({},i||{},P||{},t),y}var o=y.unitsPerPixel(0);function a(t){return Math.pow(2,-(t+1))*o*b}var s={center:void 0,zoom:y.zoom(),rotation:y.rotation(),duration:1e3,ease:function(t){return t},interp:function(t,e){return function(n){var i=[];return r.each(t,(function(r){i.push(function(t,e,n){return t+(e-t)*n}(t[r],e[r],n))})),i}},done:null,zCoord:!0};function u(e){var n=O.done,r=P;if(!0===O.cancel)return y.geoTrigger(p.transitioncancel,t),n&&n({cancel:!0,source:O.cancelSource,transition:O}),O=null,void(P&&(r=P,P=null,y.transition(r,void 0,e)));if(O.start.time||(O.start.time=e,O.end.time=e+t.duration),O.time=e-O.start.time,e>=O.end.time||r){if(!r){if(O.end.center){var i=T!==y._fix_zoom(O.end.zoom)||!1===t.endClamp;y.center(O.end.center,null,i,i)}y.zoom(O.end.zoom,O.zoomOrigin,!1===t.endClamp,!1===t.endClamp),y.rotation(Q(O.end.rotation))}return y.geoTrigger(p.transitionend,t),n&&n({next:!!r}),O=null,void(P&&(r=P,P=null,y.transition(r,void 0,e)))}var a=O.ease((e-O.start.time)/t.duration),s=O.interp(a);O.zCoord&&(s[2]=function(t){return-Math.log2(t/o/b)-1}(s[2])),y._fix_zoom(s[2],!0)===T?y.center({x:s[0],y:s[1]},null,!0,!0):(A=y.gcsToWorld({x:s[0],y:s[1]},null),y.zoom(s[2],O.zoomOrigin,!0,!0)),y.rotation(s[3],void 0,!0),y.scheduleAnimationFrame(u)}return t.center&&(e=null===e?w:void 0===e?M:e,(t=h.deepMerge({},t)).center=h.normalizeCoordinates(t.center),e!==w&&(t.center=f.transformCoordinates(e,w,t.center))),t=h.deepMerge({},s,t),(O={start:{center:y.center(void 0,null),zoom:y.zoom(),rotation:y.rotation()},end:{center:t.center,zoom:y._fix_zoom(t.zoom),rotation:Q(t.rotation,void 0,!0)},ease:t.ease,zCoord:t.zCoord,done:t.done,duration:t.duration,zoomOrigin:t.zoomOrigin,endClamp:t.endClamp}).interp=t.interp([O.start.center.x,O.start.center.y,t.zCoord?a(O.start.zoom):O.start.zoom,O.start.rotation],[O.end.center?O.end.center.x:O.start.center.x,O.end.center?O.end.center.y:O.start.center.y,t.zCoord?a(O.end.zoom):O.end.zoom,O.end.rotation]),y.geoTrigger(p.transitionstart,t),p.cancelNavigation?(O=null,y.geoTrigger(p.transitionend,t),y):(p.cancelAnimation?(t.duration=0,u(0)):n?u(n):y.scheduleAnimationFrame(u),y)},this.transitionCancel=function(t){return!(!O||!0===O.cancel&&!P)&&(O.cancel=!0,O.cancelSource=t||O.cancelSource||"",P=null,!0)},this.bounds=function(t,e){var n;if(e=null===e?w:void 0===e?M:e,void 0!==t){if(e!==w){var r=f.transformCoordinates(e,w,[{x:t.left,y:t.top},{x:t.right,y:t.bottom}]);t={left:r[0].x,top:r[0].y,right:r[1].x,bottom:r[1].y}}t=Y(t,E),n=y.zoomAndCenterFromBounds(t,E,null),y.zoom(n.zoom,void 0,void 0,void 0,"pan"),y.center(n.center,null)}return y.boundsFromZoomAndCenter(T,A,E,e,!0)},this.maxBounds=function(t,e){if(e=null===e?w:void 0===e?M:e,void 0===t)return{left:f.transformCoordinates(w,e,{x:I.left,y:0}).x,right:f.transformCoordinates(w,e,{x:I.right,y:0}).x,bottom:f.transformCoordinates(w,e,{x:0,y:I.bottom}).y,top:f.transformCoordinates(w,e,{x:0,y:I.top}).y};var n=((t.left||0)+(t.right||0))/2,r=((t.bottom||0)+(t.top||0))/2;return void 0!==t.left&&(I.left=f.transformCoordinates(e,w,{x:t.left,y:r}).x),void 0!==t.right&&(I.right=f.transformCoordinates(e,w,{x:t.right,y:r}).x),void 0!==t.bottom&&(I.bottom=f.transformCoordinates(e,w,{x:n,y:t.bottom}).y),void 0!==t.top&&(I.top=f.transformCoordinates(e,w,{x:n,y:t.top}).y),K(),y.zoom(T),y.pan({x:0,y:0}),y},this.corners=function(t){return[y.displayToGcs({x:0,y:0},t),y.displayToGcs({x:_,y:0},t),y.displayToGcs({x:_,y:b},t),y.displayToGcs({x:0,y:b},t)]},this.zoomAndCenterFromBounds=function(t,e,n){var r,i;if((n=null===n?w:void 0===n?M:n)!==w){var o=f.transformCoordinates(n,w,[{x:t.left,y:t.top},{x:t.right,y:t.bottom}]);t={left:o[0].x,top:o[0].y,right:o[1].x,bottom:o[1].y}}if(t.left>=t.right||t.bottom>=t.top)throw new Error("Invalid bounds provided");return i=y._fix_zoom(X(t,e)),r={x:((t=Y(t,e)).left+t.right)/2-l.x,y:(t.top+t.bottom)/2-l.y},n!==w&&(r=f.transformCoordinates(w,n,r)),{zoom:i,center:r}},this.boundsFromZoomAndCenter=function(t,e,n,r,i,o){var a,s,u,c,h,d;if(r=null===r?w:void 0===r?M:r,t=y._fix_zoom(t,i),d=y.unitsPerPixel(t),e=y.gcsToWorld(e,null),u=(a=_*d)/2,c=(s=b*d)/2,n?(e.x+=l.x,e.y+=l.y,(h=W(e,{width:a,height:s},n)).width=a,h.height=s,h=Y(h,n,void 0,o)):h=Y(h={left:e.x-u+l.x,right:e.x+u+l.x,bottom:e.y-c+l.y,top:e.y+c+l.y},0,void 0,o),r!==w){var p=f.transformCoordinates(w,r,[[h.left,h.top],[h.right,h.bottom]]);h={left:p[0][0],top:p[0][1],right:p[1][0],bottom:p[1][1]}}return h.width=a,h.height=s,h},this.discreteZoom=function(t){return void 0===t?L:(L!==(t=!!t)&&((L=t)&&y.zoom(Math.round(y.zoom())),y.interactor()&&y.interactor().options({discreteZoom:L})),y)},this.layers=this.children,this.sortedLayers=function(){return y.children().sort(G)},this.listSceneObjects=function(t){var e=[];return(t=t||y.sortedLayers()).forEach((function(t){if(e.indexOf(t)<0&&(e.push(t),t.children)){var n=t.children();n.length&&(e=e.concat(y.listSceneObjects(n)))}})),e},this.updateAttribution=function(){y.node().find(".geo-attribution").remove();var t=r("<div/>").addClass("geo-attribution").on("mousedown",(function(t){t.stopPropagation()}));return y.children().forEach((function(e){var n=e.attribution();n&&r("<span/>").addClass("geo-attribution-layer").html(n).appendTo(t)})),r("span",t).length&&t.appendTo(y.node()),y},this.screenshot=function(t,e,n,i){var o;if(!t||Array.isArray(t)||t.renderer||(e=e||t.type,n=n||t.encoderOptions,i=i||t,t=t.layers),(i=i||{}).wait){var a=Object.assign({},i,{wait:!1});o=r.Deferred();var s=function(){window.requestAnimationFrame((function(){o.resolve()}))};return"idle"===i.wait?y.onIdle(s):s(),o.then((function(){return y.screenshot(t,e,n,a)}))}o=r.when(),t?Array.isArray(t)||(t=[t]):(t=y.layers(),null!==i.attribution&&void 0!==i.attribution||(i.attribution=!0)),t=(t=t.filter((function(t){return y.layers().indexOf(t)>=0&&t.opacity()>0&&(!t.visible||t.visible())}))).sort(G);var u=document.createElement("canvas");u.width=_,u.height=b;var l=u.getContext("2d");if(!1!==i.background&&null!==i.background){var c=i.background;void 0===i.background&&(l.fillStyle="white",l.fillRect(0,0,u.width,u.height),y.node().parents().get().reverse().forEach((function(t){(c=window.getComputedStyle(t).backgroundColor)&&"transparent"!==c&&(l.fillStyle=c,l.fillRect(0,0,u.width,u.height))})),c=window.getComputedStyle(y.node()[0]).backgroundColor),c&&"transparent"!==c&&(l.fillStyle=c,l.fillRect(0,0,u.width,u.height))}return t.forEach((function(t){var e=t.opacity();t.node().children("canvas").each((function(){var n=r(this);o=o.then((function(){t.renderer()&&"webgl"===t.renderer().api()&&t.renderer()._renderFrame(),U(l,e,n,n[0],t.node().css("mix-blend-mode"))}))})),!t.node().children().not("canvas").length&&t.node().children().length||t.renderer()&&"webgl"===t.renderer().api()||(o=o.then((function(){return h.htmlToImage(t.node(),1).done((function(e){U(l,1,r([]),e,t.node().css("mix-blend-mode"))}))})))})),i.attribution&&y.node().find(".geo-attribution").each((function(){var t=r(this);o=o.then((function(){return h.htmlToImage(t,1).done((function(t){U(l,1,r([]),t)}))}))})),i.html&&r(i.html).each((function(){var t=r(this);o=o.then((function(){return h.htmlToImage(t,1).done((function(e){U(l,1,r([]),e,t.css("mix-blend-mode"))}))}))})),o=o.then((function(){var t=u;if("canvas"!==e)try{u=u.toDataURL(e,n)}catch(t){console.warn("Failed to convert screenshot to output",t);var i=r.Deferred();return i.reject(),i}return y.geoTrigger(p.screenshot.ready,{canvas:t,screenshot:u}),u}))},this.scheduleAnimationFrame=function(t,e){N.length||N.push(window.requestAnimationFrame(H));var n=N.indexOf(t,1);if(n>=0){if(!e)return;if(N.splice(n,1),"remove"===e)return}return N.push(t),N[0]},this._fix_zoom=function(t,e){return t=Math.round(1e6*t)/1e6,t=Math.max(Math.min(S.max,t),S.min),L&&!e&&(t=Math.round(t))<S.min&&(t=Math.ceil(S.min)),t},this.autoshareRenderer=function(t){return void 0===t?j:(j=null===t?void 0:t,y)},this._version=n(4081),this._geo=n(2257),this._init(t),this.node().on("dragover.geo",(function(t){var e=t.originalEvent;y.fileReader()&&(e.stopPropagation(),e.preventDefault(),e.dataTransfer.dropEffect="copy")})).on("drop.geo",(function(t){var e,n,r=t.originalEvent,i=y.fileReader();function o(){y.draw()}if(i)for(r.stopPropagation(),r.preventDefault(),e=0;e<r.dataTransfer.files.length;e+=1)n=r.dataTransfer.files[e],i.canRead(n)&&i.read(n,o)})),l={x:0,y:0},this.zoomRange(t,!0),T=this._fix_zoom(T),E=Q(E),this.center(Object.assign({},t.center||A),void 0),null!==t.interactor&&this.interactor(t.interactor||m({discreteZoom:L})),F&&r(window).on("resize",Z),y.geoOn([p.layerAdd,p.layerRemove],y.updateAttribution),this};a.create=function(t){"use strict";var e=a(t),r=n(5156);return e&&e.zoom?(t.data=t.data||[],t.layers=t.layers||[],t.layers.forEach((function(n){n.data=n.data||t.data,n.layer=r.create(e,n)})),e):(console.warn("Could not create map."),null)},i(a,o),t.exports=a},7908:function(t,e,n){var r=n(4626),i=n(1338),o=n(642),a=n(7549),s=function(t){"use strict";if(!(this instanceof s))return new s(t);i.call(this);var e,r,u,l,c,f,h,d,p,m,g=n(5616),y=n(6409),v=n(8695),x=n(642).throttle,_=n(642).debounce,b=n(642).actionMatch,w=n(3842),M=this,A=0,T=null,E=!1,C=!1,k=function(){};function S(t){var e=t.x,n=t.y;return Math.sqrt(e*e+n*n)}function O(){f={boundDocumentHandlers:f.boundDocumentHandlers}}function P(t,n){n=n<=0?30:n;var r=function(){var t,n,r,i;if(!e.spring.enabled)return{x:0,y:0};var o=M.map().maxBounds(void 0,null),a=M.map().gcsToDisplay({x:o.left,y:o.top},null),s=M.map().gcsToDisplay({x:o.right,y:o.bottom},null),u=e.spring.springConstant,l=M.map().node().width(),c=M.map().node().height();return t=u*Math.max(0,a.x),n=u*Math.max(0,l-s.x),r=u*Math.max(0,a.y)/2,i=u*Math.max(0,c-s.y)/2,{x:t-n,y:r-i}}(),i=S(t),o=t.x/i,a=t.y/i;return i*=Math.exp(-e.momentum.drag*n),S(r)*n+i<e.momentum.minSpeed?null:(i>0?(o*=i,a*=i):(o=0,a=0),{x:o-r.x*n,y:a-r.y*n})}return e=o.deepMerge({},{throttle:30,discreteZoom:!1,actions:[{action:v.pan,input:"left",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button pan"},{action:v.zoom,input:"right",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button zoom"},{action:v.zoom,input:"wheel",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"wheel zoom"},{action:v.rotate,input:"left",modifiers:{shift:!1,ctrl:!0},owner:"geo.mapInteractor",name:"button rotate"},{action:v.rotate,input:"wheel",modifiers:{shift:!1,ctrl:!0},owner:"geo.mapInteractor",name:"wheel rotate"},{action:v.select,input:"left",modifiers:{shift:!0,ctrl:!0},selectionRectangle:y.select,owner:"geo.mapInteractor",name:"drag select"},{action:v.zoomselect,input:"left",modifiers:{shift:!0,ctrl:!1},selectionRectangle:y.zoomselect,owner:"geo.mapInteractor",name:"drag zoom"},{action:v.unzoomselect,input:"right",modifiers:{shift:!0,ctrl:!1},selectionRectangle:y.unzoomselect,owner:"geo.mapInteractor",name:"drag unzoom"},{action:v.pan,input:"pan",owner:"geo.mapInteractor",name:"touch pan"},{action:v.zoomrotate,input:"rotate",owner:"geo.mapInteractor",name:"touch zoom and rotate"},{action:v.pan,input:"middle",modifiers:{shift:!1,ctrl:!1},owner:"geo.mapInteractor",name:"button pan"}],click:{enabled:!0,buttons:{left:!0,right:!0,middle:!0},duration:0,cancelOnMove:!0},keyboard:{actions:{"zoom.in":["plus","shift+plus","shift+ctrl+plus","=","shift+=","shift+ctrl+="],"zoom.out":["-","shift+-","shift+ctrl+-","_","shift+_","shift+ctrl+_"],"zoom.0":["1"],"zoom.3":["2"],"zoom.6":["3"],"zoom.9":["4"],"zoom.12":["5"],"zoom.15":["6"],"zoom.18":["7"],"pan.left":["left","shift+left","shift+ctrl+left"],"pan.right":["right","shift+right","shift+ctrl+right"],"pan.up":["up","shift+up","shift+ctrl+up"],"pan.down":["down","shift+down","shift+ctrl+down"],"rotate.ccw":["<","shift+<","shift+ctrl+<",".","shift+.","shift+ctrl+."],"rotate.cw":[">","shift+>","shift+ctrl+>",",","shift+,","shift+ctrl+,"],"rotate.0":["0"]},meta:{0:{shift:!1,ctrl:!1},1:{shift:!0,ctrl:!0},2:{shift:!0,ctrl:!1}},metakeyMouseEvents:["shift","ctrl","shift+ctrl","shift+alt","shift+meta"],focusHighlight:!0},alwaysTouch:!1,wheelScaleX:1,wheelScaleY:1,zoomScale:1,rotateWheelScale:6*Math.PI/180,zoomrotateMinimumRotation:5*Math.PI/180,zoomrotateReverseRotation:4*Math.PI/180,zoomrotateMinimumZoom:.05,zoomrotateMinimumPan:5,touchPanDelay:50,momentum:{enabled:!0,maxSpeed:2.5,minSpeed:.01,stopTime:250,drag:.01,actions:[v.pan,v.zoom]},spring:{enabled:!1,springConstant:5e-5},zoomAnimation:{enabled:!0,duration:500,ease:function(t){return(2-t)*t}}},t||{}),t&&t.actions&&(e.actions=o.deepMerge([],t.actions)),t&&t.momentum&&t.momentum.actions&&(e.momentum.actions=o.deepMerge([],t.momentum.actions)),t&&t.keyboard&&void 0!==t.keyboard.actions&&(e.keyboard.actions=o.deepMerge({},t.keyboard.actions)),r={page:{x:0,y:0},map:{x:0,y:0},geo:{x:0,y:0},mapgcs:{x:0,y:0},buttons:{left:!1,right:!1,middle:!1},modifiers:{alt:!1,ctrl:!1,shift:!1,meta:!1},time:new Date,deltaTime:1,velocity:{x:0,y:0}},f={},h={},this._handleKeys=function(t,n,r){r&&!0===r.simulated&&(n=r);var i,o,a=e.keyboard.meta||{0:{}},s=M.map(),u=s.size(),l=t,c="",f={};for(i in a)a.hasOwnProperty(i)&&(void 0!==a[i].shift&&n.shiftKey!==!!a[i].shift||void 0!==a[i].ctrl&&n.ctrlKey!==!!a[i].ctrl||void 0!==a[i].alt&&n.altKey!==!!a[i].alt||void 0!==a[i].meta&&n.metaKey!==!!a[i].meta||(o=i));if(void 0!==o){switch(n.stopPropagation(),n.preventDefault(),t.indexOf(".")>=0&&(l=t.substr(0,t.indexOf(".")),c=t.substr(t.indexOf(".")+1)),l){case"zoom":switch(c){case"in":f.zoomDelta=[.05,.25,1][o];break;case"out":f.zoomDelta=-[.05,.25,1][o];break;default:isNaN(parseFloat(c))||(f.zoom=parseFloat(c))}break;case"pan":switch(c){case"down":f.panY=-Math.max(1,[0,.05,.5][o]*u.height);break;case"left":f.panX=Math.max(1,[0,.05,.5][o]*u.width);break;case"right":f.panX=-Math.max(1,[0,.05,.5][o]*u.width);break;case"up":f.panY=Math.max(1,[0,.05,.5][o]*u.height)}break;case"rotate":switch(c){case"ccw":f.rotationDelta=[1,5,90][o]*Math.PI/180;break;case"cw":f.rotationDelta=-[1,5,90][o]*Math.PI/180;break;default:isNaN(parseFloat(c))||(f.rotation=parseFloat(c))}}s.geoTrigger(y.keyaction,{move:f,action:t,factor:o,event:n}),f.cancel||(void 0!==f.zoom?s.zoom(f.zoom):f.zoomDelta&&s.zoom(s.zoom()+f.zoomDelta),void 0!==f.rotation?s.rotation(f.rotation):f.rotationDelta&&s.rotation(s.rotation()+f.rotationDelta),(f.panX||f.panY)&&s.pan({x:f.panX||0,y:f.panY||0}))}},this.hasTouchSupport=function(){return"ontouchstart"in window||window.TouchEvent||window.DocumentTouch&&document instanceof window.DocumentTouch||(navigator.msMaxTouchPoints||navigator.maxTouchPoints)>1},this._handleTouch=function(t){var n=!1;if("mouse"===t.pointerType&&c.touchSupport&&(n=!0),"hammer.input"===t.type){if("pan"!==c.lastEventType||1===t.pointers.length)return;n=!0,c.lastEventType=null}var r=/^(.*)(start|end|move|tap)$/.exec(t.type);if(r&&3===r.length||(n=!0),n)f.boundDocumentHandlers&&c.lastEvent&&M._handleMouseUpDocument(c.lastEvent);else{t.which=r[1];var i=(new Date).valueOf();"pan"===t.which&&"pan"!==c.lastEventType&&i-c.lastTime<e.touchPanDelay||(c.lastTime=i,c.lastEventType=t.which,c.lastEvent=t,void 0===t.pageX&&void 0!==t.center&&void 0!==t.center.x&&(t.pageX=t.center.x,t.pageY=t.center.y),"start"===r[2]&&(M._handleMouseDown(t),M._setClickMaybe(!1),f.boundDocumentHandlers&&g(document).on("mousemove.geojs",M._handleMouseUpDocument)),"start"!==r[2]&&"move"!==r[2]||(f.boundDocumentHandlers?M._handleMouseMoveDocument(t):M._handleMouseMove(t)),"end"!==r[2]&&"cancel"!==r[2]||(f.boundDocumentHandlers?M._handleMouseUpDocument(t):M._handleMouseUp(t),c.lastEvent=null),"tap"!==r[2]||f.boundDocumentHandlers||(t.which=1,c.lastEventType=null,M._handleMouseDown(t),M._handleMouseUp(t),c.lastEventType=r[2]))}},this._repeatMouseMoveEvent=function(t){if(r&&r.modifiers){var e=r.modifiers.alt,n=r.modifiers.ctrl,i=r.modifiers.meta,o=r.modifiers.shift;M._getMouseModifiers(t),r.modifiers.alt===e&&r.modifiers.ctrl===n&&r.modifiers.meta===i&&r.modifiers.shift===o||(f.boundDocumentHandlers?M.map().geoTrigger(y.actionmove,{state:M.state(),mouse:M.mouse(),event:t}):M.map().geoTrigger(y.mousemove,M.mouse()))}},this.retriggerMouseMove=function(){M.map().geoTrigger(y.mousemove,M.mouse())},this._connectEvents=function(){if(!e.map)return M;M._disconnectEvents(),d=g(e.map.node()),M._handleMouseWheel=function(){var t={};function n(n){var r,i;E||(t!==h&&(h=t={kind:"wheel",scroll:{x:0,y:0}}),n.preventDefault(),n.deltaFactor=1,1===n.originalEvent.deltaMode?n.deltaFactor=40:2===n.originalEvent.deltaMode&&(n.deltaFactor=g(window).height()),r=n.originalEvent.deltaX||0,i=n.originalEvent.deltaY||0,r=r*e.wheelScaleX*n.deltaFactor/120,i=i*e.wheelScaleY*n.deltaFactor/120,t.scroll.x+=r,t.scroll.y+=i)}function i(n){var i,o;if(t===h){if(M._getMousePosition(n),M._getMouseButton(n),M._getMouseModifiers(n),o=(b({wheel:!0},r.modifiers,e.actions)||{}).action){var a=M.map().transitionCancel("wheel."+o);switch((a|=M.cancel(v.momentum,!0))&&(r.geo=M.map().displayToGcs(r.map),r.mapgcs=M.map().displayToGcs(r.map,null)),o){case v.pan:M.map().pan({x:h.scroll.x,y:h.scroll.y},void 0,"limited");break;case v.zoom:i=-h.scroll.y,k(i,r);break;case v.rotate:M.map().rotation(M.map().rotation()+h.scroll.y*e.rotateWheelScale,r)}M.map().geoTrigger(y.actionwheel,{state:M.state(),mouse:M.mouse(),eventData:n})}h={}}}return e.throttle>0?x(e.throttle,!1,i,n):function(t){n(t),i(t)}}(),k=function(){var t,n,r,i=0,a=400;function s(a,s){var u,l=M.map();t=o.deepMerge({},s),i+=a,void 0===r&&(n=r=l.zoom()),r+=a,l&&Math.abs(i)>=1&&e.discreteZoom&&!e.zoomAnimation.enabled&&(u=Math.round(i+l.zoom()),i=i+l.zoom()-u,l.zoom(u,t))}function u(){var o,a=M.map();a&&(e.zoomAnimation.enabled?(o=r,e.discreteZoom&&(o=Math.round(o))===n&&r!==n&&(o=n+(r>n?1:-1)),(o=Math.round(1e6*a._fix_zoom(o))/1e6)!==a.zoom()?(a.transitionCancel("debounced_zoom."+v.zoom),a.transition({zoom:o,zoomOrigin:t,duration:e.zoomAnimation.duration,ease:e.zoomAnimation.ease,done:function(t){t=t||{};var n=new RegExp("\\."+v.zoom+"$");t.next||t.cancel&&!((""+t.source).search(n)<0)||(r=void 0),e.discreteZoom&&t.cancel&&t.transition&&t.transition.end&&(""+t.source).search(n)<0&&a.zoom(t.transition.end.zoom,t.transition.end.zoomOrigin)}})):r=void 0):(o=i+a.zoom(),e.discreteZoom&&(o=Math.round(o)),a.zoom(o,t))),i=0}!0!==e.discreteZoom&&e.discreteZoom>0&&(a=e.discreteZoom);return(!0===e.discreteZoom||e.discreteZoom>0)&&!e.zoomAnimation.enabled?_(a,!1,u,s):function(t,e){(t||void 0!==r)&&(s(t,e),u())}}(),o.adjustActions(e.actions);var t={};if(["right","pan","rotate"].forEach((function(n){t[n]=e.actions.some((function(t){return t.input[n]}))})),d.on("wheel.geojs",M._handleMouseWheel),d.on("mousemove.geojs",M._handleMouseMove),d.on("mousedown.geojs",M._handleMouseDown),d.on("mouseup.geojs",M._handleMouseUp),d.on("dragstart",(function(){return!1})),t.right&&d.on("contextmenu.geojs",(function(){return!1})),e.keyboard&&e.keyboard.actions){u=a(d[0]);var i=[];for(var s in e.keyboard.actions)e.keyboard.actions.hasOwnProperty(s)&&(u.bind(e.keyboard.actions[s],function(t){return function(e,n){M._handleKeys(t,e,n)}}(s)),i=i.concat(e.keyboard.actions[s]));e.keyboard.metakeyMouseEvents&&e.keyboard.metakeyMouseEvents.forEach((function(t){u.bind(t,M._repeatMouseMoveEvent,"keydown"),u.bind(t,M._repeatMouseMoveEvent,"keyup"),i.push(t)})),l=i}if(d.toggleClass("highlight-focus",!!(l&&l.length&&e.keyboard.focusHighlight)),(M.hasTouchSupport()||e.alwaysTouch)&&(t.pan||t.rotate)){var f;try{(f=n(3267))&&f.Manager||(f=void 0)}catch(t){}if(void 0!==f){var p=[],m=["hammer.input"];t.rotate&&(p.push([f.Rotate,{enable:!0}]),m=m.concat(["rotatestart","rotateend","rotatemove"])),t.pan&&(p.push([f.Pan,{direction:f.DIRECTION_ALL}]),m=m.concat(["panstart","panend","panmove"])),p.push([f.Tap,{event:"doubletap",taps:2}]),p.push([f.Tap,{event:"singletap"},void 0,["doubletap"]]),m=m.concat(["singletap"]);var w={recognizers:p,preventDefault:!0};(c={manager:new f.Manager(d[0],w),touchSupport:M.hasTouchSupport(),lastTime:0}).manager.get("doubletap").recognizeWith("singletap"),m.forEach((function(t){c.manager.on(t,M._handleTouch)}))}}return M},this._disconnectEvents=function(){return l&&(u&&u.unbind(l),l=null,u=null),c&&(c.manager.destroy(),c=null),d&&(d.off(".geojs"),d=null),M._handleMouseWheel=function(){},k=function(){},M},this.map=function(t){return void 0!==t?(e.map=t,M._connectEvents(),M):e.map},this.options=function(t){return void 0===t?Object.assign({},e):(Object.assign(e,t),M._connectEvents(),M)},this._getMousePosition=function(t){if(void 0!==t.pageX&&void 0!==t.pageY){var e,n,i=d.offset();e=(n=(new Date).valueOf())-r.time,r.time=n,r.deltaTime=e,r.velocity={x:(t.pageX-r.page.x)/e,y:(t.pageY-r.page.y)/e},r.page={x:t.pageX,y:t.pageY},r.map={x:t.pageX-i.left,y:t.pageY-i.top};try{r.geo=M.map().displayToGcs(r.map),r.mapgcs=M.map().displayToGcs(r.map,null)}catch(t){r.geo=r.mapgcs=null}}},this._getMouseButton=function(t){if(void 0!==t.buttons||void 0!==t.which){for(var e in r.buttons)r.buttons.hasOwnProperty(e)&&(r.buttons[e]=!1);if(void 0!==t.buttons)r.buttons.left=!!(1&t.buttons),r.buttons.right=!!(2&t.buttons),r.buttons.middle=!!(4&t.buttons);else if("mouseup"!==t.type)switch(t.which){case 1:r.buttons.left=!0;break;case 2:r.buttons.middle=!0;break;case 3:r.buttons.right=!0}!t.which||t.which>=1&&t.which<=3||(r.buttons[t.which]=!0)}},this._getMouseModifiers=function(t){r.modifiers.alt=t.altKey,r.modifiers.ctrl=t.ctrlKey,r.modifiers.meta=t.metaKey,r.modifiers.shift=t.shiftKey},this._getSelection=function(){var t=f.origin,e=M.mouse(),n=M.map(),r={},i={},a=e.map;if(f.actionRecord&&o.isFunction(f.actionRecord.selectionConstraint)){var s=f.actionRecord.selectionConstraint(e.mapgcs,t.mapgcs);a=s?n.gcsToDisplay(s.pos,null):a}else if(e.modifiers.shift){var u=Math.pow(Math.abs((a.x-t.map.x)*(a.y-t.map.y)),.5);a={x:t.map.x+Math.sign(a.x-t.map.x)*u,y:t.map.y+Math.sign(a.y-t.map.y)*u}}return r.upperLeft={x:Math.min(t.map.x,a.x),y:Math.min(t.map.y,a.y)},r.lowerRight={x:Math.max(t.map.x,a.x),y:Math.max(t.map.y,a.y)},r.upperRight={x:r.lowerRight.x,y:r.upperLeft.y},r.lowerLeft={x:r.upperLeft.x,y:r.lowerRight.y},i.upperLeft=n.displayToGcs(r.upperLeft,null),i.lowerRight=n.displayToGcs(r.lowerRight,null),i.upperRight=n.displayToGcs(r.upperRight,null),i.lowerLeft=n.displayToGcs(r.lowerLeft,null),p.data([{ul:i.upperLeft,ur:i.upperRight,ll:i.lowerLeft,lr:i.lowerRight}]),p.draw(),{display:r,gcs:i,mouse:e,origin:Object.assign({},f.origin)}},this.cancel=function(t,e){var n;return(n=t?f.action===t:!!f.action)&&(e||(h={}),O()),n},this._setClickMaybe=function(t){C=t,m&&(window.clearTimeout(m),m=null)},this._handleMouseDown=function(t){var n,i;if(!(E||c&&"tap"===c.lastEventType&&(new Date).valueOf()-c.lastTime<1e3)){M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),M.map().geoTrigger(y.mousedown,M.mouse()),!e.click.enabled||r.buttons.left&&!e.click.buttons.left||r.buttons.right&&!e.click.buttons.right||r.buttons.middle&&!e.click.buttons.middle||(M._setClickMaybe({x:r.page.x,y:r.page.y,buttons:Object.assign({},r.buttons)}),e.click.duration>0&&(m=window.setTimeout((function(){C=!1,m=null}),e.click.duration))),n=((i=b(r.buttons,r.modifiers,e.actions))||{}).action;var a=M.map();a.transitionCancel("_handleMouseDown"+(n?"."+n:"")),M.cancel(v.momentum),r.velocity={x:0,y:0},n&&(h={kind:"move"},A+=1,f={action:n,actionRecord:i,origin:o.deepMerge({},r),initialZoom:a.zoom(),initialRotation:a.rotation(),initialEventRotation:t.rotation,stateId:A,delta:{x:0,y:0}},i.selectionRectangle&&(T&&(T.clear(),a.deleteLayer(T),T=null),T=a.createLayer("feature",{features:[w.capabilities.color],autoshareRenderer:!1}),(p=T.createFeature("quad",{gcs:a.gcs()})).style({opacity:.25,color:{r:.3,g:.3,b:.3}}),a.geoTrigger(y.brushstart,M._getSelection())),a.geoTrigger(y.actiondown,{state:M.state(),mouse:M.mouse(),event:t}),e.throttle>0?g(document).on("mousemove.geojs",x(e.throttle,M._handleMouseMoveDocument)):g(document).on("mousemove.geojs",M._handleMouseMoveDocument),g(document).on("mouseup.geojs",M._handleMouseUpDocument),f.boundDocumentHandlers=!0)}},this._handleMouseMove=function(t){E||f.boundDocumentHandlers||(e.click.cancelOnMove&&C&&M._setClickMaybe(!1),M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),C||M.map().geoTrigger(y.mousemove,M.mouse()))},this._handleZoomrotate=function(t){var n=Math.log2(t.scale);if(!f.zoomrotateAllowZoom&&n&&Math.abs(n)>=Math.log2(1+e.zoomrotateMinimumZoom)&&(e.zoomrotateMinimumZoom&&(f.initialZoom-=n),f.zoomrotateAllowZoom=!0),f.zoomrotateAllowZoom&&n){var r=f.initialZoom+n;M.map().zoom(r,f.origin)}var i=(t.rotation-f.initialEventRotation)*Math.PI/180;if(!f.zoomrotateAllowRotation&&i&&Math.abs(i)>=e.zoomrotateMinimumRotation&&(e.zoomrotateMinimumRotation&&(f.initialEventRotation=t.rotation,i=0),f.zoomrotateAllowRotation=!0),f.zoomrotateAllowRotation){var a=f.initialRotation+i;(i=o.wrapAngle(a-M.map().rotation()))&&(i*(f.lastRotationDelta||0)>=0||Math.abs(i)>=e.zoomrotateReverseRotation)&&(M.map().rotation(a,f.origin),f.lastRotationDelta=i)}var s=f.origin.page;if(f.initialEventGeo){var u=d.offset();(s=M.map().gcsToDisplay(f.initialEventGeo)).x+=u.left,s.y+=u.top}var l=t.pageX-s.x,c=t.pageY-s.y,h=l*l+c*c;!f.zoomrotateAllowPan&&h&&h>=e.zoomrotateMinimumPan*e.zoomrotateMinimumPan&&(e.zoomrotateMinimumPan?(l=c=0,f.initialEventGeo=M.mouse().geo):f.initialEventGeo=f.origin.geo,f.zoomrotateAllowPan=!0),f.zoomrotateAllowPan&&(l||c)&&M.map().pan({x:l,y:c})},this._handleMouseMoveDocument=function(t){var n,i,o;if(M.map()&&!E&&"move"===h.kind){if(M._getMousePosition(t),M._getMouseButton(t),M._getMouseModifiers(t),e.click.cancelOnMove)if(void 0===C.x||void 0===C.y)M._setClickMaybe(!1);else if(!0!==e.click.cancelOnMove||r.page.x===C.x&&r.page.y===C.y){Math.sqrt(Math.pow(r.page.x-C.x,2)+Math.pow(r.page.y-C.y,2))>=e.click.cancelOnMove&&M._setClickMaybe(!1)}else M._setClickMaybe(!1);if(!C)if(f.action){if(n=r.map.x-f.origin.map.x-f.delta.x,i=r.map.y-f.origin.map.y-f.delta.y,f.delta.x+=n,f.delta.y+=i,f.action===v.pan)M.map().pan({x:n,y:i},void 0,"limited");else if(f.action===v.zoom)k(-i*e.zoomScale/120,f);else if(f.action===v.rotate){var a,s;void 0===f.origin.rotation&&(a=f.origin.map.x-M.map().size().width/2,s=f.origin.map.y-M.map().size().height/2,f.origin.rotation=M.map().rotation()-Math.atan2(s,a)),a=r.map.x-M.map().size().width/2,s=r.map.y-M.map().size().height/2,M.map().rotation(f.origin.rotation+Math.atan2(s,a))}else f.action===v.zoomrotate?M._handleZoomrotate(t):f.actionRecord.selectionRectangle&&(o=M._getSelection(),M.map().geoTrigger(y.brush,o));M.map().geoTrigger(y.actionmove,{state:M.state(),mouse:M.mouse(),event:t}),t.preventDefault()}else console.log("WARNING: Invalid state in mapInteractor.")}},this._zoomFromSelection=function(t,e,n){if((t===v.zoomselect||t===v.unzoomselect)&&e.x!==n.x&&e.y!==n.y){var r,i,o=M.map(),a=o.size(),s={x:Math.abs((n.x-e.x)/a.width),y:Math.abs((n.y-e.y)/a.height)};if(t===v.zoomselect?(i=o.displayToGcs({x:(e.x+n.x)/2,y:(e.y+n.y)/2},null),r=o.zoom()-Math.log2(Math.max(s.x,s.y))):(r=o.zoom()+Math.log2(Math.max(s.x,s.y)),i=o.center(void 0,null)),o.discreteZoom()&&(r=Math.floor(r)),o.zoom(r),t===v.zoomselect)o.center(i,null);else{var u=o.gcsToDisplay(i,null);o.pan({x:(e.x+n.x)/2-u.x,y:(e.y+n.y)/2-u.y})}}},this._handleMouseUpDocument=function(t){var n,i;if(!E&&(h={},M._setClickMaybe(!1),M._getMouseButton(t),M._getMouseModifiers(t),g(document).off(".geojs"),f.boundDocumentHandlers=!1,r.buttons.right&&t.preventDefault(),f.actionRecord&&f.actionRecord.selectionRectangle&&(M._getMousePosition(t),n=M._getSelection(),T.clear(),M.map().deleteLayer(T),T=null,p=null,M.map().geoTrigger(y.brushend,n),!0!==f.actionRecord.selectionRectangle&&M.map().geoTrigger(f.actionRecord.selectionRectangle,n),M._zoomFromSelection(f.action,n.display.lowerLeft,n.display.upperRight),M.map().geoTrigger(y.actionselection,{state:M.state(),mouse:M.mouse(),event:t,lowerLeft:n.display.lowerLeft,upperRight:n.display.upperRight})),M.map().geoTrigger(y.actionup,{state:M.state(),mouse:M.mouse(),event:t}),i=f.action,O(),e.momentum.enabled&&e.momentum.actions.includes(i))){var o=(new Date).valueOf(),a=o-r.time+r.deltaTime;o-r.time<e.momentum.stopTime?(r.velocity.x*=r.deltaTime/a,r.velocity.y*=r.deltaTime/a,r.deltaTime=a):r.velocity.x=r.velocity.y=0,M.springBack(!0,i)}},this._handleMouseUp=function(t){if(!E){M._getMouseButton(t),C&&M._handleMouseClick(t);var e=M.mouse();e.buttonsDown=C.buttons,M.map().geoTrigger(y.mouseup,e)}},this._handleMouseClick=function(t){f.actionRecord&&f.actionRecord.selectionRectangle&&(T.clear(),M.map().deleteLayer(T),T=null,p=null,f.action=f.actionRecord=null),M._getMouseButton(t),M._getMouseModifiers(t),M.cancel(v.pan),g(document).off(".geojs"),f.boundDocumentHandlers=!1;var e=M.mouse();e.buttonsDown=C.buttons,e.evt=t,M._setClickMaybe(!1),M.map().geoTrigger(y.mouseclick,e)},this._handleMouseWheel=function(){},this.springBack=function(t,n){f.action!==v.momentum&&(t||(r.velocity={x:0,y:0}),f.origAction=n,f.action=v.momentum,f.origin=M.mouse(),f.momentum=M.mouse(),f.start=new Date,f.handler=function(){var t,n,r,i;if(f.action===v.momentum&&M.map()&&!M.map().transition())if(i=Math.min(f.momentum.deltaTime,30),r=f.start.valueOf(),f.start=new Date,t=P(f.momentum.velocity,f.start-r)){if((n=S(t))>e.momentum.maxSpeed&&(n=e.momentum.maxSpeed/n,t.x=t.x*n,t.y=t.y*n),isFinite(t.x)&&isFinite(t.y)||(t.x=0,t.y=0),f.momentum.velocity.x=t.x,f.momentum.velocity.y=t.y,f.origAction===v.zoom){var o=f.momentum.velocity.y*i;k(-o*e.zoomScale/120,f)}else M.map().pan({x:f.momentum.velocity.x*i,y:f.momentum.velocity.y*i},void 0,"limited");f.handler&&M.map().scheduleAnimationFrame(f.handler)}else O()},f.handler&&M.map().scheduleAnimationFrame(f.handler))},this.destroy=function(){M._disconnectEvents(),M.map()&&g(M.map().node()).removeClass("highlight-focus"),M.map(null)},this.mouse=function(){return o.deepMerge({},r)},this.keyboard=function(t){return void 0===t?o.deepMerge({},e.keyboard||{}):M.options({keyboard:t})},this.state=function(){return o.deepMerge({},f)},this.pause=function(t){return void 0===t?E:(E=!!t,M)},this.addAction=function(t,n){t&&t.action&&t.input&&(o.addAction(e.actions,t,n),e.map&&e.actions.some((function(t){return t.input.right}))&&(d.off("contextmenu.geojs"),d.on("contextmenu.geojs",(function(){return!1}))))},this.hasAction=function(t,n,r){return o.hasAction(e.actions,t,n,r)},this.removeAction=function(t,n,r){var i=o.removeAction(e.actions,t,n,r);return e.map&&!e.actions.some((function(t){return t.input.right}))&&d.off("contextmenu.geojs"),i},this.simulateEvent=function(t,e){var n,r,i,o,a;if(!M.map())return M;if("keyboard"===t&&u){var s={shiftKey:e.shift||e.shiftKey||!1,ctrlKey:e.ctrl||e.ctrlKey||!1,altKey:e.alt||e.altKey||!1,metaKey:e.meta||e.metaKey||!1,toString:function(){return e.keys},stopPropagation:function(){},preventDefault:function(){},simulated:!0};u.trigger(s,e.event)}else r=e.page||{},e.map&&(i=d.offset(),r.x=e.map.x+i.left,r.y=e.map.y+i.top),"left"===e.button?(o=1,a=1):"right"===e.button?(o=3,a=2):"middle"===e.button&&(o=2,a=4),e.modifiers=e.modifiers||[],e.wheelDelta=e.wheelDelta||{},n=g.Event(t,{pageX:r.x,pageY:r.y,which:o,buttons:a,altKey:e.modifiers.indexOf("alt")>=0,ctrlKey:e.modifiers.indexOf("ctrl")>=0,metaKey:e.modifiers.indexOf("meta")>=0,shiftKey:e.modifiers.indexOf("shift")>=0,center:e.center,rotation:e.touch?e.rotation||0:e.rotation,scale:e.touch?e.scale||1:e.scale,pointers:e.pointers,pointerType:e.pointerType,originalEvent:{deltaX:e.wheelDelta.x,deltaY:e.wheelDelta.y,deltaMode:e.wheelMode,preventDefault:function(){},stopPropagation:function(){},stopImmediatePropagation:function(){}}}),e.touch&&c?M._handleTouch(n):d.trigger(n),t.indexOf(".geojs")>=0&&g(document).trigger(n)},this._connectEvents(),this};r(s,i),t.exports=s},2225:function(t,e,n){function r(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||i(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var a=n(4626),s=n(1275),u=n(7541),l=function(t){"use strict";if(!(this instanceof l))return new l(t);t=t||{},u.call(this,t);var e=n(77),o=n(642),a=n(4279);a=a.__esModule?a.default:a;var s=this,c=this._init,f=null,h=e(),d=0,p=0,m=0;return this.featureType="marker",this._updateRangeTree=function(){if(!(h.timestamp()>=s.dataTime().timestamp()&&h.timestamp()>=s.timestamp())){var t,e,n=s.style.get("radius"),o=s.style.get("strokeWidth"),u=s.style.get("radiusIncludesStroke"),c=s.style.get("strokeOffset"),g=s.style.get("scaleWithZoom");e=s.position(),d=0,p=0,m=0,t=s.data().map((function(t,r){var i=e(t,r),a=g(t,r),s=n(t,r),f=o(t,r),h=Math.sign(c(t,r)),y=u(t,r),v=(y=void 0===y||y)?s+f*(h+1)/2:s+f,x=y?s+f*(h-1)/2:s;switch(a=l.scaleMode[a]||(a>=1&&a<=3?a:0)){case l.scaleMode.stroke:x>d&&(d=x),f>m&&(m=f);break;case l.scaleMode.fill:case l.scaleMode.all:v>p&&(p=v);break;default:v>d&&(d=v)}return[i.x,i.y]})),f=new a(t.length);var y,v=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=i(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(t);try{for(v.s();!(y=v.n()).done;){var x=r(y.value,2),_=x[0],b=x[1];f.add(_,b)}}catch(t){v.e(t)}finally{v.f()}f.finish(),h.modified()}},this._approximateMaxRadius=function(t){s._updateRangeTree();var e=Math.pow(2,t);return Math.max(d+m*e,p*e)},this.pointSearch=function(t,e){var n,r,i,o,a=[],u=[],c=[],h=s.gcs(),d=s.style.get("radius"),p=s.style.get("strokeWidth"),m=s.style.get("radiusIncludesStroke"),g=s.style.get("strokeOffset"),y=s.style.get("scaleWithZoom");if(!(i=s.data())||!i.length)return{found:[],index:[]};s._updateRangeTree();var v=s.layer().map();e=null===e?v.gcs():void 0===e?v.ingcs():e;var x=v.gcsToDisplay(t,e),_=v.zoom(),b=Math.pow(2,_),w=this._approximateMaxRadius(_);return o=[v.displayToGcs({x:x.x-w,y:x.y-w},h),v.displayToGcs({x:x.x+w,y:x.y-w},h),v.displayToGcs({x:x.x-w,y:x.y+w},h),v.displayToGcs({x:x.x+w,y:x.y+w},h)],n={x:Math.min(o[0].x,o[1].x,o[2].x,o[3].x),y:Math.min(o[0].y,o[1].y,o[2].y,o[3].y)},r={x:Math.max(o[0].x,o[1].x,o[2].x,o[3].x),y:Math.max(o[0].y,o[1].y,o[2].y,o[3].y)},a=f.range(n.x,n.y,r.x,r.y),(a=Uint32Array.from(a).sort()).forEach((function(t){var e=i[t],n=d(i[t],t),r=y(i[t],t),o=g(i[t],t),a=r?p(i[t],t):0,f=m(e,t),_=(f=void 0===f||f)?n+a*(o-1)/2:n;n=_+a;var w,M,A,T=s.position()(e,t);switch(r=l.scaleMode[r]||(r>=1&&r<=3?r:0)){case l.scaleMode.fill:n=_*b+a;break;case l.scaleMode.stroke:n=_+a*b;break;case l.scaleMode.all:n*=b}n&&(A=n*n,(w=(T=v.gcsToDisplay(T,h)).x-x.x)*w+(M=T.y-x.y)*M<=A&&(u.push(e),c.push(t)))})),{found:u,index:c}},this.polygonSearch=function(t,e,n){var r,i,a,u,c=s.gcs(),h=[],d=[],p={},m=s.layer().map(),g=s.data(),y=s.style.get("radius"),v=s.style.get("strokeWidth"),x=s.style.get("radiusIncludesStroke"),_=s.style.get("strokeOffset"),b=s.style.get("scaleWithZoom"),w=m.zoom(),M=Math.pow(2,w),A=this._approximateMaxRadius(w);return n=null===n?m.gcs():void 0===n?m.ingcs():n,t.outer||(t={outer:t,inner:[]}),t.outer.length<3||!g||!g.length?{found:[],index:[],extra:{}}:((e=e||{}).partial=e.partial||!1,(t={outer:m.gcsToDisplay(t.outer,n),inner:(t.inner||[]).map((function(t){return m.gcsToDisplay(t,n)}))}).outer.forEach((function(t){i||(i={x:t.x,y:t.y},a={x:t.x,y:t.y}),t.x<i.x&&(i.x=t.x),t.x>a.x&&(a.x=t.x),t.y<i.y&&(i.y=t.y),t.y>a.y&&(a.y=t.y)})),s._updateRangeTree(),u=[m.displayToGcs({x:i.x-A,y:i.y-A},c),m.displayToGcs({x:a.x+A,y:i.y-A},c),m.displayToGcs({x:a.x+A,y:a.y+A},c),m.displayToGcs({x:i.x-A,y:a.y+A},c)],i={x:Math.min(u[0].x,u[1].x,u[2].x,u[3].x),y:Math.min(u[0].y,u[1].y,u[2].y,u[3].y)},a={x:Math.max(u[0].x,u[1].x,u[2].x,u[3].x),y:Math.max(u[0].y,u[1].y,u[2].y,u[3].y)},r=f.range(i.x,i.y,a.x,a.y),(r=Uint32Array.from(r).sort()).forEach((function(n){var r=g[n],i=s.position()(r,n),a=y(r,n),u=b(r,n),f=_(r,n),w=u?v(r,n):0,A=x(r,n),T=(A=void 0===A||A)?a+w*(f-1)/2:a;switch(a=T+w,u=l.scaleMode[u]||(u>=1&&u<=3?u:0)){case l.scaleMode.fill:a=T*M+w;break;case l.scaleMode.stroke:a=T+w*M;break;case l.scaleMode.all:a*=M}if(a){i=m.gcsToDisplay(i,c);var E=o.distanceToPolygon2d(i,t);(E>=a||E>=0&&"center"===e.partial||E>=-a&&e.partial&&"center"!==e.partial)&&(h.push(r),d.push(n),p[n]={partial:E<a,distance:E})}})),{found:h,index:d,extra:p})},this._init=function(t){return t=o.deepMerge({},{style:Object.assign({},{radius:6.25,radiusIncludesStroke:!0,strokeColor:{r:.851,g:.604,b:0},strokeOffset:-1,strokeOpacity:1,strokeWidth:1.25,fillColor:{r:1,g:.839,b:.439},fillOpacity:.8,symbol:0,symbolValue:0,rotation:0,scaleWithZoom:l.scaleMode.none,rotateWithMap:!1},t&&void 0===t.style?{}:t.style)},t),c.call(s,t),s},s};l.create=function(t,e){"use strict";return(e=e||{}).type="marker",s.create(t,e)},l.capabilities={feature:"marker"},l.primitiveShapes=u.primitiveShapes,l.symbols={circle:0,ellipse:0,flowerBase:1,flowerMax:16,triangle:16,diamond:17,starBase:17,starMax:16,square:32,rectangle:32,crossBase:33,crossMax:16,oval:48,jackBase:49,jackMax:16,drop:64,dropBase:65,dropMax:16,arrow:80,arrowBase:81,arrowMax:16,length:96},["flower","star","cross","jack","drop","arrow"].forEach((function(t){for(var e=2;e<=l.symbols[t+"Max"];e+=1)l.symbols[t+e]=l.symbols[t+"Base"]-2+e})),l.scaleMode={none:0,fill:1,stroke:2,all:3},a(l,u),t.exports=l},6124:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);var e=n(642);t=t||{},i.call(this,t);var r=this,a=this._init,s={};return this.featureType="mesh",this.mesh=function(t,e){if(void 0===t)return s;if("string"==typeof t&&void 0===e)return s[t];if(void 0===e){var n=Object.assign({},{gridWidth:function(){return t.gridHeight?Math.floor(r.data().length/t.gridHeight):Math.floor(Math.sqrt(r.data().length))},gridHeight:function(){return t.gridWidth?Math.floor(r.data().length/t.gridWidth):Math.floor(Math.sqrt(r.data().length))}},s,t);s=n}else s[t]=e;return r.modified(),r},this.mesh.get=function(t){if(void 0===t){var n,i={};for(n in s)s.hasOwnProperty(n)&&(i[n]=r.mesh.get(n));return i}return e.ensureFunction(s[t])},this.position=function(t){return void 0===t?r.style("position"):(r.style("position",t),r.dataTime().modified(),r.modified(),r)},this._createMesh=function(t,e){t=t||{},e=e||{};var n,i,o,a,s,u,l,c,f,h,d,p,m,g,y,v,x=r.data(),_=r.position(),b=r.mesh.get("elements")(x),w=r.mesh.get("elementPacking")(x),M=r.mesh.get("gridWidth")(x),A=r.mesh.get("gridHeight")(x),T=r.mesh.get("wrapLongitude")(x),E=r.mesh.get("x0")(x),C=r.mesh.get("y0")(x),k=r.mesh.get("dx")(x),S=r.mesh.get("dy")(x),O=M,P={shape:"square",elements:[],elementIndex:[]};if(b){var L=b.length&&Array.isArray(b[0]);if("square"===w||"triangle"!==w&&(!L&&!(b.length%4)&&b.length%3||L&&4===b[0].length))if(P.shape="square",L)for(n=0;n<b.length;n+=1)P.elements.push(b[n][0]),P.elements.push(b[n][1]),P.elements.push(b[n][3]),P.elements.push(b[n][2]),P.elements.push(b[n][3]),P.elements.push(b[n][1]),P.elementIndex.push(n),P.elementIndex.push(n);else for(n=o=0;n<b.length-3;n+=4,o+=1)P.elements.push(b[n]),P.elements.push(b[n+1]),P.elements.push(b[n+3]),P.elements.push(b[n+2]),P.elements.push(b[n+3]),P.elements.push(b[n+1]),P.elementIndex.push(o),P.elementIndex.push(o);else if(P.shape="triangle",L)for(n=0;n<b.length;n+=1)P.elements.push(b[n][0]),P.elements.push(b[n][1]),P.elements.push(b[n][2]),P.elementIndex.push(n);else for(P.elements=b.slice(0,b.length-b.length%3),n=o=0;n<b.length-2;n+=3,o+=1)P.elementIndex.push(o);u=x.length,c=!0}else{if(Object.keys(t).length?M*A>x.length&&(A=Math.floor(x.length/M)):Object.keys(e).length&&(M-1)*(A-1)>x.length&&(A=Math.floor(x.length/(M-1))+1),T=!(void 0!==T&&!T),!(c=null==E||null==C||!k||!S)&&T&&(E<-180||E>180||E+k*(M-1)<-180||E+k*(M-1)>180)&&k>-180&&k<180&&k*(M-1)<360.0001){for(p=[],m=[],n=0;n<M;n+=1){for(y=E+n*k;y<-180;)y+=360;for(;y>180;)y-=360;n&&Math.abs(y-p[p.length-1])>180&&(y>p[p.length-1]?(p.push(y-360),p.push(p[p.length-2]+360),m.push(n),m.push(n+1)):(p.push(y+360),p.push(p[p.length-2]-360),m.push(n),m.push(n+1)),g=n),p.push(y),m.push(n)}if(M+=2,Math.abs(Math.abs(O*k)-360)<.01){for(M+=1,y=E+O*k;y<-180;)y+=360;for(;y>180;)y-=360;p.push(y),m.push(0)}}if(u=M*A,void 0!==g)for(P.index=new Array(u),n=0;n<u;n+=1)v=n-(o=Math.floor(n/M))*M,(v+=v>g?-2:0)>=O&&(v-=O),v+=o*O,P.index[n]=v;for(o=s=0;o<A-1;o+=1,s+=1)for(n=0;n<M-1;n+=1,s+=1)n!==g&&(P.elements.push(s),P.elements.push(s+1),P.elements.push(s+M),P.elements.push(s+M+1),P.elements.push(s+M),P.elements.push(s+1),P.elementIndex.push(o*(M-1)+(m?m[n]:n)),P.elementIndex.push(o*(M-1)+(m?m[n]:n)))}P.verticesPerElement="triangle"===P.shape?3:6;var R=P.verticesPerElement;if(e.used){var I=new Array(P.elementIndex[P.elementIndex.length-1]+1);for(n=0;n<I.length;n+=1)I[n]=e.used(x[n],n);for(n=0;n<P.elementIndex.length&&I[P.elementIndex[n]];n+=1);if(n<P.elementIndex.length){for(o=n;n<P.elementIndex.length;n+=1)if(I[P.elementIndex[n]]){for(P.elementIndex[o]=P.elementIndex[n],a=0;a<3;a+=1)P.elements[3*o+a]=P.elements[3*n+a];o+=1}P.elements.splice(3*o),P.elementIndex.splice(o)}}if(t.used){for(n=0;n<u&&(s=P.index?P.index[n]:n,t.used(x[s],s));n+=1);if(n!==u){l=n;var D=new Array(u);for(o=0;o<l;o+=1)D[o]=o;if(D[l]=-1,!P.index)for(P.index=new Array(x.length),o=0;o<x.length;o+=1)P.index[o]=o;for(n=l+1;n<u;n+=1)s=P.index[n],t.used(x[s],s)?(D[n]=l,P.index[l]=P.index[n],l+=1):D[n]=-1;for(P.index.splice(l),n=a=0;n<P.elements.length;n+=R){for(o=0;o<R&&!(D[P.elements[n+o]]<0);o+=1)P.elements[a+o]=D[P.elements[n+o]];o===R&&(P.elementIndex[Math.floor(a/3)]=P.elementIndex[Math.floor(n/3)],6===R&&(P.elementIndex[Math.floor(a/3)+1]=P.elementIndex[Math.floor(n/3)+1]),a+=R)}P.elements.splice(a),P.elementIndex.splice(Math.floor(a/3)),u=l}}if(e.used&&void 0===g){var N=new Array(u),F=P.index;for(P.index=[],n=0;n<P.elements.length;n+=1)void 0===N[a=P.elements[n]]&&(N[a]=P.index.length,P.index.push(F?F[a]:a)),P.elements[n]=N[a];u=P.index.length}for(h in P.pos=new Array(3*u),t)"used"!==h&&t.hasOwnProperty(h)&&(P[h]=new Array(u));for(n=i=0;n<u;n+=1,i+=3)for(h in f=x[s=P.index?P.index[n]:n],c?(d=_(f,s),P.pos[i]=d.x,P.pos[i+1]=d.y,P.pos[i+2]=d.z||0):(P.pos[i]=void 0===g?E+k*(s%M):p[n%M],P.pos[i+1]=C+S*Math.floor(s/M),P.pos[i+2]=0,d={x:P.pos[i],y:P.pos[i+1],z:P.pos[i+2]}),t)"used"!==h&&t.hasOwnProperty(h)&&(P[h][n]=t[h](f,s,d));for(h in e)if("used"!==h&&e.hasOwnProperty(h)){var j=e[h];for(P[h]=new Array(P.elementIndex.length),n=0;n<P.elementIndex.length;n+=1)f=x[s=P.elementIndex[n]],P[h][n]=j(f,s)}return P.numVertices=u,P.numElements=P.elements.length/P.verticesPerElement,P},this._init=function(t){a.call(r,t),t=t||{};var e=Object.assign({},{position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t}},t.style||{});r.mesh(t.mesh||{}),r.style(e)},this};r(o,i),t.exports=o},1338:function(t,e,n){var r=n(4626),i=n(77),o=0,a=function(){"use strict";if(!(this instanceof a))return new a;var t=n(642),e=this,r=++o,s={},u=[],l=0;return this.onIdle=function(t){return l?u.push(t):t(),e},Object.defineProperty(this,"idle",{get:function(){return!l},configurable:!0}),Object.defineProperty(this,"_promises",{get:function(){return l},configurable:!0}),this.addPromise=function(t){function n(){t._geojsTracked&&t._geojsTracked[r]&&(l-=1,delete t._geojsTracked[r]),l||u.splice(0,u.length).forEach((function(t){t()}))}return t._geojsTracked||(t._geojsTracked={}),t._geojsTracked[r]||(t._geojsTracked[r]=!0,l+=1),t.always?t.always(n):t.then(n,n),e},this.removePromise=function(t){return t._geojsTracked&&t._geojsTracked[r]&&(l-=1,delete t._geojsTracked[r],l||u.splice(0,u.length).forEach((function(t){t()}))),e},this.geoOn=function(n,r){return Array.isArray(n)?(n.forEach((function(t){e.geoOn(t,r)})),e):t.isFunction(r)?(s.hasOwnProperty(n)||(s[n]=[]),s[n].push(r),e):(console.warn("Handler for "+n+" is not a function",r,e),e)},this.geoOnce=function(t,n){var r=function(i){e.geoOff(t,r),n.call(e,i)};return e.geoOn(t,r),r},this.geoIsOn=function(t,n){return Array.isArray(t)?t.some((function(t){return e.geoIsOn(t,n)})):(s[t]||[]).some((function(t){return t===n||void 0===n}))},this.geoTrigger=function(t,n){return Array.isArray(t)?(t.forEach((function(t){e.geoTrigger(t,n)})),e):((n=n||{}).event=t,s.hasOwnProperty(t)&&s[t].forEach((function(r){try{r.call(e,n)}catch(e){console.warn("Event handler for "+t+" threw an error",e)}})),e)},this.geoOff=function(t,n){if(void 0===t&&(s={},u=[],l=0,r=++o),Array.isArray(t))return t.forEach((function(t){e.geoOff(t,n)})),e;if(n){if(Array.isArray(n))return n.forEach((function(n){e.geoOff(t,n)})),e}else s[t]=[];return s.hasOwnProperty(t)&&(s[t]=s[t].filter((function(t){return t!==n}))),e},this._eventHandlers=function(){return s},this._exit=function(){e.geoOff()},i.call(this),this.modified(),this};r(a,i),t.exports=a},4880:function(t,e,n){var r=n(4626),i=n(9264),o=n(1098),a=n(3842),s=n(642),u=function(t){var e=n(4912);if(!(this instanceof u))return new u(t);void 0!==(t=t||{}).mapOpacity&&void 0===t.opacity&&((t=Object.assign({},t)).opacity=t.mapOpacity),t=s.deepMerge({},this.constructor.defaults,u.tileSources[this.constructor.defaults.source]||{},u.tileSources[t.source]||{},{name:""},t),i.call(this,t);var r=this;this.mapOpacity=this.opacity,this._getTile=function(t,n){var i=n||t;return e({index:t,size:{x:r._options.tileWidth,y:r._options.tileHeight},queue:r._queue,overlap:r._options.tileOverlap,scale:r._options.tileScale,url:r._options.url.call(r,i.x,i.y,Math.max(i.level||0,0),r._options.subdomains),crossDomain:r._options.crossDomain})},this.source=function(t){if(void 0!==t)return u.tileSources[t]&&(r.url(u.tileSources[t].url),r.subdomains(u.tileSources[t].subdomains||"abc"),r.attribution(u.tileSources[t].attribution||""),r._options.maxLevel=u.tileSources[t].maxLevel||18,r._options.minLevel=u.tileSources[t].minLevel||0),r;for(var e in u.tileSources)if(u.tileSources[e].url===r.url())return e}};u.defaults=Object.assign({},i.defaults,{tileOffset:function(t){var e=256*Math.pow(2,t-1);return{x:e,y:e}},url:"",source:"osm"});var l='Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://www.openstreetmap.org/copyright">ODbL</a>.',c='<a href="https://carto.com"> Carto</a> Contributors <a href="https://www.openstreetmap.org/"> OpenStreetMap</a>';u.tileSources={"dark-matter-with-labels":{url:" https://{s}.basemaps.cartocdn.com/rastertiles/dark_all/{z}/{x}/{y}.png",attribution:c,name:"Carto Dark Matter With Labels",minLevel:0,maxLevel:18},"dark-matter-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/dark_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Dark Matter Without Labels",minLevel:0,maxLevel:18},"nationalmap-relief":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSShadedReliefOnly/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Shaded Relief",minLevel:0,maxLevel:16},"nationalmap-satellite":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryOnly/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Satellite",minLevel:0,maxLevel:16},"nationalmap-satellite-topo":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSImageryTopo/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Satellite and Topo",minLevel:0,maxLevel:16},"nationalmap-topo":{url:"https://basemap.nationalmap.gov/arcgis/rest/services/USGSTopo/MapServer/tile/{z}/{y}/{x}",attribution:'Tile data from <a href="https://basemap.nationalmap.gov/">USGS</a>',name:"National Map Topo",minLevel:0,maxLevel:16},osm:{url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'Tile data © <a href="https://osm.org/copyright">OpenStreetMap</a> contributors',name:"OpenStreetMap",subdomains:"abc",minLevel:0,maxLevel:19},"positron-with-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/light_all/{z}/{x}/{y}.png",attribution:c,name:"Carto Positron With Labels",minLevel:0,maxLevel:18},"positron-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/light_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Positron Without Labels",minLevel:0,maxLevel:18},"stamen-terrain":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/terrain/{z}/{x}/{y}.png",attribution:l,name:"Stamen Terrain",subdomains:"abcd",minLevel:0,maxLevel:14},"stamen-terrain-background":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/terrain-background/{z}/{x}/{y}.png",attribution:l,name:"Stamen Terrain Background",subdomains:"abcd",minLevel:0,maxLevel:14},"stamen-toner":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/toner/{z}/{x}/{y}.png",attribution:l,name:"Stamen Toner",subdomains:"abcd",minLevel:0,maxLevel:20},"stamen-toner-lite":{url:"https://stamen-tiles-{s}.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png",attribution:l,name:"Stamen Toner Lite",subdomains:"abcd",minLevel:0,maxLevel:20},"voyager-with-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/voyager_labels_under/{z}/{x}/{y}.png",attribution:c,name:"Carto Voyager With Labels",minLevel:0,maxLevel:18},"voyager-without-labels":{url:"https://{s}.basemaps.cartocdn.com/rastertiles/voyager_nolabels/{z}/{x}/{y}.png",attribution:c,name:"Carto Voyager Without Labels",minLevel:0,maxLevel:18}},r(u,i),o.registerLayer("osm",u,[a.capabilities.image]),t.exports=u},2266:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=this,n=this._init;return this.featureType="path",this.position=function(t){return void 0===t?e.style("position"):(t!==e.style("position")&&(e.style("position",t),e.dataTime().modified(),e.modified()),e)},this._init=function(t){n.call(e,t);var r=Object.assign({},{strokeWidth:1,strokeColor:{r:1,g:1,b:1},position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t}},void 0===t.style?{}:t.style);return void 0!==t.position&&(r.position=t.position),e.style(r),r.position&&e.position(r.position),e.dataTime().modified(),e},this._init(t),this};r(o,i),t.exports=o},7761:function(t,e,n){var r=n(5616),i=n(4626),o=n(1275),a=n(642),s=function(t){"use strict";if(!(this instanceof s))return new s(t);t=t||{},o.call(this,t);var e,n=this,i=this._update,u=this._init;return this.featureType="pixelmap",this.position=function(t){return void 0===t?n.style("position"):(t!==n.style("position")&&(n.style("position",t),n.dataTime().modified(),n.modified()),n)},this.url=function(t){return void 0===t?n.style("url"):(t!==n.style("url")&&(n.m_srcImage=n.m_info=void 0,n.style("url",t),n.dataTime().modified(),n.modified()),n)},this.color=function(t){return void 0===t?n.style("color"):(t!==n.style("color")&&(n.style("color",t),n.dataTime().modified(),n.modified()),n)},this.indexModified=function(t,r){if(void 0===t){var i=e;return"clear"===r&&(e=void 0),i}return n.modified(),void 0===e&&(e=[t,t]),t<e[0]&&(e[0]=t),(r||t)>e[1]&&(e[1]=r||t),n},this._update=function(){return i.call(n),(n.buildTime().timestamp()<=n.dataTime().timestamp()||n.updateTime().timestamp()<n.timestamp())&&n._build(),n.updateTime().modified(),n},this.maxIndex=function(){if(n.m_info){if(void 0===n.m_info.maxIndex)for(var t in n.m_info.maxIndex=0,n.m_info.mappedColors)n.m_info.mappedColors.hasOwnProperty(t)&&(n.m_info.maxIndex=Math.max(n.m_info.maxIndex,t));return n.m_info.maxIndex}},this._computePixelmap=function(){},this._build=function(){if(n.m_srcImage)n.m_info&&n._computePixelmap();else{var t=n.style.get("url")();if(a.isReadyImage(t))n.m_srcImage=t,n._computePixelmap();else if(t){var e,i,o=r.Deferred();t instanceof Image?(n.m_srcImage=t,e=t.onload,i=t.onerror):(n.m_srcImage=new Image,t.indexOf(":")>=0&&t.indexOf("/")===t.indexOf(":")+1&&(n.m_srcImage.crossOrigin=n.style.get("crossDomain")()||"anonymous")),n.m_srcImage.onload=function(){e&&e.apply(n,arguments),n.style.get("url")()===t&&(n.m_info=void 0,n._computePixelmap()),o.resolve()},n.m_srcImage.onerror=function(){i&&i.apply(n,arguments),o.reject()},o.promise(n),n.layer().addPromise(n),t instanceof Image||(n.m_srcImage.src=t)}}return n.buildTime().modified(),n},this._init=function(t){t=t||{},u.call(n,t);var e=Object.assign({},{color:function(t,e){return{r:(255&e)/255,g:(e>>8&255)/255,b:(e>>16&255)/255,a:1}},position:a.identityFunction},void 0===t.style?{}:t.style);return void 0!==t.position&&(e.position=t.position),void 0!==t.url&&(e.url=t.url),void 0!==t.color&&(e.color=t.color),n.style(e),n.dataTime().modified(),t.quadFeature&&(n.m_srcImage=!0,n._computePixelmap()),n},this};s.create=function(t,e){"use strict";return(e=e||{}).type="pixelmap",o.create(t,e)},s.capabilities={feature:"pixelmap",lookup:"pixelmap.lookup"},i(s,o),t.exports=s},534:function(t,e,n){var r=n(4626),i=n(9264),o=n(1098),a=n(3842),s=n(7761),u=n(642),l=function(t){var e,r=n(4912);if(!(this instanceof l))return new l(t);(t=t||{}).data&&(e=t.data,delete t.data),t=u.deepMerge({},this.constructor.defaults,t),i.call(this,t);var o,a=this._init,s=this;return this._getTile=function(t,e){var n=e||t;return r({index:t,size:{x:s._options.tileWidth,y:s._options.tileHeight},queue:s._queue,overlap:s._options.tileOverlap,scale:s._options.tileScale,url:s._options.url.call(s,n.x,n.y,Math.max(n.level||0,0),s._options.subdomains),crossDomain:s._options.crossDomain})},this._init=function(){a.apply(s,arguments),s.nearestPixel(!0,!0);var n={quadFeature:s.features()[0]};t.style&&(n.style=t.style),t.color&&(n.color=t.color),o=s.createFeature("pixelmap",n),e&&o.data(e),s.style=o.style,s.data=o.data,s.indexModified=o.indexModified;var r=s.dataTime().modified;return s.dataTime().modified=function(){return o.dataTime().modified(),r()},["modified","geoOn","geoOff","geoOnce"].forEach((function(t){var e=s[t];s[t]=function(){return Array.isArray(arguments[0])||o[t].apply(this,arguments),e.apply(this,arguments)}})),s},s};l.defaults=Object.assign({},i.defaults,{features:[a.capabilities.image,s.capabilities.lookup],tileOffset:function(t){var e=256*Math.pow(2,t-1);return{x:e,y:e}},url:""}),r(l,i),o.registerLayer("pixelmap",l,[a.capabilities.image]),t.exports=l},7541:function(t,e,n){function r(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||i(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var a=n(4626),s=n(1275),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},s.call(this,t);var e=n(77),o=n(5966),a=n(6409),l=n(642),c=n(4279);c=c.__esModule?c.default:c;var f=this,h=this._init,d=null,p=e(),m=this.data,g=0,y=t.clustering,v=null,x=[],_=null,b=!1;return this.featureType="point",this.clustering=function(t){return void 0===t?y:(y&&!t?(v=null,y=!1,m(x)):t&&y!==t&&(y=t,f._clusterData()),f)},this._clusterData=function(){if(y){var t=!0===y?{radius:10}:y,e=f.position(),n=f.layer().map(),r=n.gcsToDisplay(n.center(void 0,null),null),i=n.displayToGcs(r,f.gcs()),a=n.displayToGcs({x:r.x+t.radius,y:r.y},f.gcs()),s=Math.pow(Math.pow(a.y-i.y,2)+Math.pow(a.x-i.x,2),.5),u=n.zoom(),c=s*Math.pow(2,u);t=Object.assign({},t,{radius:c}),v=new o(t),x.forEach((function(t,n){var r=l.normalizeCoordinates(e(t,n));r.index=n,v.addPoint(r)})),_=null,f._handleZoom(n.zoom())}},this._handleZoom=function(t){var e=Math.floor(t);if(y&&e!==_){_=e;var n=v.points(e).map((function(t){return x[t.index]}));v.clusters(e).forEach((function(t){t.__cluster=!0,t.__data=[],t.obj.each((function(e){t.__data.push(x[e.index])})),n.push(t)})),b=!0,f.data(n)}},this.position=function(t){if(void 0===t)return f.style("position");var e=l.isFunction(t);return f.style("position",(function(n,r){return null!=n&&n.__cluster?n:e?t(n,r):t})),f.dataTime().modified(),f.modified(),f},this._updateRangeTree=function(){if(!(p.timestamp()>=f.dataTime().timestamp()&&p.timestamp()>=f.timestamp())){var t,e,n=f.style.get("radius"),o=f.style.get("stroke"),a=f.style.get("strokeWidth");e=f.position(),g=0,t=f.data().map((function(t,r){var i=e(t,r);return g=Math.max(g,n(t,r)+(o(t,r)?a(t,r):0)),[i.x,i.y]})),d=new c(t.length);var s,u=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=i(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}(t);try{for(u.s();!(s=u.n()).done;){var l=r(s.value,2),h=l[0],m=l[1];d.add(h,m)}}catch(t){u.e(t)}finally{u.f()}d.finish(),p.modified()}},this.pointSearch=function(t,e){var n,r,i,o,a,s,u=[],l=[],c=[],h=f.gcs(),p=f.style.get("fill"),m=f.style.get("stroke"),y=f.style.get("strokeWidth"),v=f.style.get("radius");return(i=f.data())&&i.length?(f._updateRangeTree(),o=f.layer().map(),a=o.gcsToDisplay(t,e),s=[o.displayToGcs({x:a.x-g,y:a.y-g},h),o.displayToGcs({x:a.x+g,y:a.y-g},h),o.displayToGcs({x:a.x-g,y:a.y+g},h),o.displayToGcs({x:a.x+g,y:a.y+g},h)],n={x:Math.min(s[0].x,s[1].x,s[2].x,s[3].x),y:Math.min(s[0].y,s[1].y,s[2].y,s[3].y)},r={x:Math.max(s[0].x,s[1].x,s[2].x,s[3].x),y:Math.max(s[0].y,s[1].y,s[2].y,s[3].y)},u=d.range(n.x,n.y,r.x,r.y),(u=Uint32Array.from(u).sort()).forEach((function(t){var e=i[t],n=m(i[t],t);if(n||p(i[t],t)){var r,s,u,d,g=f.position()(e,t);u=v(i[t],t),(u+=n?y(i[t],t):0)&&(d=u*u,(r=(g=o.gcsToDisplay(g,h)).x-a.x)*r+(s=g.y-a.y)*s<=d&&(l.push(e),c.push(t)))}})),{found:l,index:c}):{found:[],index:[]}},this.polygonSearch=function(t,e,n){var r,i,o,a,s=f.gcs(),u=[],c=[],h={},p=f.layer().map(),m=f.data(),y=f.style.get("fill"),v=f.style.get("stroke"),x=f.style.get("strokeWidth"),_=f.style.get("radius");return t.outer||(t={outer:t,inner:[]}),t.outer.length<3||!m||!m.length?{found:[],index:[],extra:{}}:((e=e||{}).partial=e.partial||!1,(t={outer:p.gcsToDisplay(t.outer,n),inner:(t.inner||[]).map((function(t){return p.gcsToDisplay(t,n)}))}).outer.forEach((function(t){i||(i={x:t.x,y:t.y},o={x:t.x,y:t.y}),t.x<i.x&&(i.x=t.x),t.x>o.x&&(o.x=t.x),t.y<i.y&&(i.y=t.y),t.y>o.y&&(o.y=t.y)})),f._updateRangeTree(),a=[p.displayToGcs({x:i.x-g,y:i.y-g},s),p.displayToGcs({x:o.x+g,y:i.y-g},s),p.displayToGcs({x:o.x+g,y:o.y+g},s),p.displayToGcs({x:i.x-g,y:o.y+g},s)],i={x:Math.min(a[0].x,a[1].x,a[2].x,a[3].x),y:Math.min(a[0].y,a[1].y,a[2].y,a[3].y)},o={x:Math.max(a[0].x,a[1].x,a[2].x,a[3].x),y:Math.max(a[0].y,a[1].y,a[2].y,a[3].y)},r=d.range(i.x,i.y,o.x,o.y),(r=Uint32Array.from(r).sort()).forEach((function(n){var r=m[n],i=v(m[n],n);if(i||y(m[n],n)){var o=f.position()(r,n),a=_(m[n],n);if(a+=i?x(m[n],n):0){o=p.gcsToDisplay(o,s);var d=l.distanceToPolygon2d(o,t);(d>=a||d>=0&&"center"===e.partial||d>=-a&&e.partial&&"center"!==e.partial)&&(u.push(r),c.push(n),h[n]={partial:d<a,distance:d})}}})),{found:u,index:c,extra:h})},this.data=function(t){return void 0===t?m():(b||(x=t),y&&!b?f._clusterData():m(t),b=!1,f)},this._init=function(t){t=t||{},h.call(f,t);var e=l.deepMerge({},{radius:5,stroke:!0,strokeColor:{r:.851,g:.604,b:0},strokeWidth:1.25,strokeOpacity:1,fillColor:{r:1,g:.839,b:.439},fill:!0,fillOpacity:.8,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){return t.length>=3?t.slice(0,3):[0,0,0]}},void 0===t.style?{}:t.style);return void 0!==t.position&&(e.position=t.position),f.style(e),e.position&&f.position(e.position),f.dataTime().modified(),f.geoOn(a.zoom,(function(t){f._handleZoom(t.zoomLevel)})),f},f};u.create=function(t,e){"use strict";return(e=e||{}).type="point",s.create(t,e)},u.capabilities={feature:"point",stroke:"point.stroke"},u.primitiveShapes={auto:"auto",sprite:"sprite",triangle:"triangle",square:"square"},a(u,s),t.exports=u},6645:function(t,e,n){var r=n(4626),i=n(1275),o=n(5325),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},i.call(this,t);var e,r=n(642),s=this,u=this._init,l=this._exit,c=this.data,f=this.draw,h=this.modified,d=this.style,p=[];function m(t,e,n){var r=s.gcs(),i=s.layer().map().gcs();return t=t||s.data(),e=e||s.style.get("position"),n=n||s.style.get("polygon"),t.map((function(t,a){var u=n(t,a);if(u){var l,c,f,h,d,p,m,g,y,v;for(h=u.outer||(Array.isArray(u)?u:[]),l=new Array(h.length),d=0;d<h.length;d+=1)l[d]=e.call(s,h[d],d,t,a),p=l[d].x,m=l[d].y,d?(p<f.min.x&&(f.min.x=p),m<f.min.y&&(f.min.y=m),p>f.max.x&&(f.max.x=p),m>f.max.y&&(f.max.y=m)):f={min:{x:p,y:m},max:{x:p,y:m}};for(c=(u.inner||[]).map((function(n){h=n||[];var r=new Array(h.length);for(d=0;d<h.length;d+=1)r[d]=e.call(s,h[d],d,t,a);return r})),g=o.transformCoordinates(r,i,l),y=c.map((function(t){return o.transformCoordinates(r,i,t)})),d=0;d<g.length;d+=1)p=g[d].x,m=g[d].y,d?(p<v.min.x&&(v.min.x=p),m<v.min.y&&(v.min.y=m),p>v.max.x&&(v.max.x=p),m>v.max.y&&(v.max.y=m)):v={min:{x:p,y:m},max:{x:p,y:m}};return{outer:l,inner:c,range:f,mapouter:g,mapinner:y,maprange:v}}}))}function g(t){return r.isFunction(t)?function(e){return t(e[0],e[1],e[2],e[3])}:t}return this.featureType="polygon",this._subfeatureStyles={fillColor:!0,fillOpacity:!0,lineCap:!0,lineJoin:!0,strokeColor:!0,strokeOffset:!0,strokeOpacity:!0,strokeWidth:!0},this.data=function(t){var e=c(t);return void 0!==t&&(p=m(),s._checkForStroke()),e},this.polygonCoordinates=function(){return p},this.polygon=function(t){return void 0===t?s.style("polygon"):(s.style("polygon",t),s.dataTime().modified(),s.modified(),p=m(),s)},this.position=function(t){return void 0===t?s.style("position"):(s.style("position",t),s.dataTime().modified(),s.modified(),p=m(),s)},this.pointSearch=function(t,n){var i=[],a=[],u={},l=s.data(),c=s.layer().map();n=null===n?c.gcs():void 0===n?c.ingcs():n;var f=o.transformCoordinates(n,c.gcs(),t);(p.forEach((function(t,e){r.pointInPolygon(f,t.mapouter,t.mapinner,t.maprange)&&(a.push(e),u[e]=!0,i.push(l[e]))})),e)&&e.pointSearch(t).found.forEach((function(t){t.length&&4===t[0].length&&!u[t[0][3]]&&(a.push(t[0][3]),u[t[0][3]]=!0,i.push(l[t[0][3]]))}));return{index:a,found:i}},this.polygonSearch=function(t,n,i){var a,u,l=s.data(),c=[],f=[],h={},d=t,m={},g=s.layer().map();if(i=null===i?g.gcs():void 0===i?g.ingcs():i,t.outer||(t={outer:t,inner:[]}),!l||!l.length||t.outer.length<3)return{found:f,index:c,extra:h};if((n=n||{}).partial=n.partial||!1,(t={outer:o.transformCoordinates(i,g.gcs(),t.outer),inner:(t.inner||[]).map((function(t){return o.transformCoordinates(i,g.gcs(),t)}))}).outer.forEach((function(t){a||(a={x:t.x,y:t.y},u={x:t.x,y:t.y}),t.x<a.x&&(a.x=t.x),t.x>u.x&&(u.x=t.x),t.y<a.y&&(a.y=t.y),t.y>u.y&&(u.y=t.y)})),p.forEach((function(e,i){if(!(!e.mapouter.length||e.maprange&&(e.maprange.max.x<a.x||e.maprange.min.x>u.x||e.maprange.max.y<a.y||e.maprange.min.y>u.y))){for(var o,s,d=-1;d<e.mapinner.length&&!s;d+=1)for(var p=d<0?e.mapouter:e.mapinner[d],g=0,y=p.length,v=y-1;g<y;v=g,g+=1){var x=r.distanceToPolygon2d(p[g],t);if(x*r.distanceToPolygon2d(p[v],t)<0){s=!0;break}if(r.crossedLineSegmentPolygon2d(p[g],p[v],t)){s=!0;break}x>0&&(o=!0)}o||s||!r.pointInPolygon(t.outer[0],e.mapouter,e.mapinner,e.maprange)||(s=!0),(!n.partial&&o&&!s||n.partial&&(o||s))&&(c.push(i),f.push(l[i]),h[i]={partial:s},m[i]=!0)}})),e){var y=e.polygonSearch(d,n);y.found.forEach((function(t,e){t.length&&4===t[0].length&&(m[t[0][3]]||(c.push(t[0][3]),m[t[0][3]]=!0,f.push(l[t[0][3]]),h[y.index[e]]={partial:!1}),y.extra[y.index[e]].partial&&(h[t[0][3]].partial=!0))}))}return{found:f,index:c,extra:h}},this.style=function(t,e){var n=d.apply(s,arguments);return void 0===t||"string"==typeof t&&void 0===e||s._checkForStroke(),n},this.style.get=d.get,this._getLoopData=function(t,e,n){var r,i=[];for(r=0;r<n.length;r+=1)i.push([n[r],r,t,e]);return i},this._checkForStroke=function(){if(!1!==d("stroke")){if(s.layer()){e||(e=s.layer().createFeature("line",{selectionAPI:!1,gcs:s.gcs(),visible:s.visible(void 0,!0)}),s.dependentFeatures([e]));var t,n=s.style();if(r.isFunction(n.stroke)||!n.stroke){var i=s.style.get("stroke"),o=s.style.get("strokeOpacity");t=function(t){return i(t[2],t[3])?o(t[0],t[1],t[2],t[3]):0}}else t=g(n.strokeOpacity);e.style({antialiasing:g(n.antialiasing),closed:!0,lineCap:g(n.lineCap),lineJoin:g(n.lineJoin),miterLimit:g(n.miterLimit),strokeWidth:g(n.strokeWidth),strokeStyle:g(n.strokeStyle),strokeColor:g(n.strokeColor),strokeOffset:g(n.strokeOffset),strokeOpacity:t,uniformLine:g(n.uniformPolygon)});var a=s.data(),u=s.style("position");if(a!==e._lastData||u!==e._lastPosVal){var l,c,f,h=[],p=s.style.get("position"),m=s.style.get("polygon");for(l=0;l<a.length;l+=1)(c=m(a[l],l))&&(f=c.outer||(Array.isArray(c)?c:[])).length>=2&&(h.push(s._getLoopData(a[l],l,f)),c.inner&&c.inner.forEach((function(t){t.length>=2&&h.push(s._getLoopData(a[l],l,t))})));e.position((function(t,e,n,r){return p(t[0],t[1],t[2],t[3])})),e.data(h),e._lastData=a,e._lastPosVal=u}}}else e&&s.layer()&&(s.layer().deleteFeature(e),e=null,s.dependentFeatures([]))},this.draw=function(){var t=f();return e&&e.draw(),t},this.modified=function(){var t=h();return e&&e.modified(),t},this.rdpSimplifyData=function(t,e,n,i,a){var u=s.layer().map(),l=u.gcs(),c=s.gcs(),f=m(t,n,i);return void 0===e&&(e=.5*u.unitsPerPixel(u.zoom())),f=f.map((function(t){return{outer:o.transformCoordinates(c,l,t.outer),inner:t.inner.map((function(t){return o.transformCoordinates(c,l,t)}))}})),t=t.map((function(t,n){var i=f[n],a={};for(var s in t)!t.hasOwnProperty(s)||Array.isArray(t)&&s>=0&&s<t.length||(a[s]=t[s]);if(i&&i.outer.length>=3)if(a.inner=i.inner.filter((function(t){return t.length>=3})),a.outer=r.rdpLineSimplify(i.outer,e,!0,a.inner),a.outer.length>=3){var u=a.inner.slice();a.inner.map((function(t,n){u[n]=a.outer;var i=r.rdpLineSimplify(t,e,!0,u);return u[n]=i,i})).filter((function(t){return t.length>=3})),a.outer=o.transformCoordinates(l,c,a.outer),a.inner=a.inner.map((function(t){return o.transformCoordinates(l,c,t)}))}else a.outer=a.inner=[];else a.outer=[];return a})),a?t:(s.style("position",r.identityFunction),s.style("polygon",r.identityFunction),s.data(t),s)},this.mouseOverOrderClosestBorder=function(t){var e=t.feature.data(),n=t.feature.layer().map(),i=o.transformCoordinates(n.ingcs(),t.feature.gcs(),t.mouse.geo),a=t.feature.polygonCoordinates(),s={};t.over.index.forEach((function(t,e){var n,o=a[t];o.outer.forEach((function(t,e){var a=o.outer[(e+1)%o.outer.length],s=r.distance2dToLineSquared(i,t,a);(void 0===n||s<n)&&(n=s)})),o.inner.forEach((function(t){t.forEach((function(e,o){var a=t[(o+1)%t.length],s=r.distance2dToLineSquared(i,e,a);(void 0===n||s<n)&&(n=s)}))})),s[t]=n})),t.over.index.sort((function(t,e){return s[t]-s[e]})).reverse(),t.over.index.forEach((function(n,r){t.over.found[r]=e[n]}))},this.toPolygonList=function(t){var e=s.style.get("polygon"),n=s.style.get("position");return s.data().map((function(t,r){var i=e(t,r),o=i.outer||(Array.isArray(i)?i:[]);if(o.length<3)return[];var a=[o.map((function(e,i){var o=n(e,i,t,r);return[o.x,o.y]}))];return i.inner&&i.inner.forEach((function(e){a.push(e.map((function(e,i){var o=n(e,i,t,r);return[o.x,o.y]})))})),a}))},this.fromPolygonList=function(t,e){return s.style({position:function(t){return{x:t[0],y:t[1]}},polygon:function(t){return{outer:t[0],inner:t.slice(1)}}}),s.data(t),s},this._exit=function(){e&&s.layer()&&(s.layer().deleteFeature(e),e=null,s.dependentFeatures([])),l()},this._init=function(t){t=t||{},u.call(s,t);var e=Object.assign({},{fill:!0,fillColor:{r:0,g:.5,b:.5},fillOpacity:1,stroke:!1,strokeWidth:1,strokeStyle:"solid",strokeColor:{r:0,g:1,b:1},strokeOpacity:1,polygon:r.identityFunction,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},origin:function(t){for(var e=0;e<t.length;e+=1)if(t[e].vertices.length>=3)return t[e].vertices.slice(0,3);return[0,0,0]}},void 0===t.style?{}:t.style);void 0!==t.polygon&&(e.polygon=t.polygon),void 0!==t.position&&(e.position=t.position),s.style(e),s._checkForStroke()},this};a.create=function(t,e){"use strict";return(e=e||{}).type="polygon",i.create(t,e)},a.capabilities={feature:"polygon"},r(a,i),t.exports=a},3842:function(t,e,n){var r=n(5616),i=n(4626),o=n(1275),a=function(t){"use strict";var e=n(5325),i=n(642);if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var s,u,l=this,c=this._init,f=t.nearestPixel,h=0,d=[],p=[];return this.featureType="quad",this._objectListStart=function(t){r.each(t,(function(t,e){e.used=!1}))},this._objectListGet=function(t,e){for(var n=0;n<t.length;n+=1)if(t[n].entry===e)return t[n].used=!0,t[n].value},this._objectListAdd=function(t,e,n){t.push({entry:e,value:n,used:!0})},this._objectListEnd=function(t){for(var e=t.length-1;e>=0;e-=1)t[e].used||t.splice(e,1)},this.pointSearch=function(t,n){var o,a,s=[],c=[],f={},h=[{},{},{},{}],d=[{},{},{},{}],p=[0,1,2,0],m=[1,2,3,1],g=l.data(),y=l.layer().map();return n=null===n?y.gcs():void 0===n?y.ingcs():n,t=e.transformCoordinates(n,y.gcs(),t),u||l._generateQuads(),r.each([u.clrQuads,u.imgQuads,u.vidQuads],(function(e,n){n.forEach((function(e,n){for(o=0;o<p.length;o+=1)h[o].x=e.pos[3*p[o]],h[o].y=e.pos[3*p[o]+1],h[o].z=e.pos[3*p[o]+2],d[o].x=e.pos[3*m[o]],d[o].y=e.pos[3*m[o]+1],d[o].z=e.pos[3*m[o]+2];if((i.pointInPolygon(t,h)||i.pointInPolygon(t,d))&&(c.push(e.idx),s.push(g[e.idx]),!(a=i.pointToTriangleBasis2d(t,h[0],h[1],h[2]))||a.x+a.y>1?(a=i.pointToTriangleBasis2d(t,d[2],d[1],d[0]))&&(a.x=1-a.x):a.y=1-a.y,a)){if(e.crop&&void 0!==e.crop.x&&void 0!==e.crop.y&&(a.x>=e.crop.x||a.y>=e.crop.y))return c.pop(),void s.pop();f[e.idx]={basis:a,_quad:e}}}))})),{index:c,found:s,extra:f}},this.position=function(t){return void 0===t?l.style("position"):(l.style("position",i.ensureFunction(t)),l.dataTime().modified(),l.modified(),l)},this._positionToQuad=function(t,n,i,o){var a=t.call(l,i,o);if(a.ll&&a.ur||a.ul&&a.lr){var s=l.gcs(),u=l.layer().map().gcs(),c={};return r.each(["ll","lr","ul","ur"],(function(t,r){void 0!==a[r]&&(c[r]={},void 0===a[r].x?c[r]=[a[r][0],a[r][1],a[r][2]]:c[r]=[a[r].x,a[r].y,a[r].z],void 0===c[r][2]&&(c[r][2]=n.call(l,i,o)),s!==u&&!1!==s&&(c[r]=e.transformCoordinates(s,u,c[r])))})),c.ll=c.ll||[c.ul[0],c.lr[1],(c.ul[2]+c.lr[2])/2],c.lr=c.lr||[c.ur[0],c.ll[1],(c.ur[2]+c.ll[2])/2],c.ur=c.ur||[c.lr[0],c.ul[1],(c.lr[2]+c.ul[2])/2],c.ul=c.ul||[c.ll[0],c.ur[1],(c.ll[2]+c.ur[2])/2],c}},this._checkQuadUpdate=function(t,e){},this._generateQuads=function(){var t,e,n=l.position(),o=l.style.get("image"),a=l.style.get("video"),c=l.style.get("delayRenderWhenSeeking"),f=l.style.get("color"),m=l.style.get("depth"),g=l.style.get("opacity"),y=l.style.get("drawOnAsyncResourceLoaded"),v=l.style.get("previewColor"),x=l.style.get("previewImage"),_=l.data(),b=[],w=[],M=[],A=[0,0,0];return l._objectListStart(d),l._objectListStart(p),r.each(_,(function(u,_){if(_._cachedQuad)return e=_._cachedQuad.diag2,(void 0===t||_._cachedQuad.diag2&&_._cachedQuad.diag2<t)&&(A=_._cachedQuad.ll,t=_._cachedQuad.diag2),_._cachedQuad.clrquad&&b.push(_._cachedQuad.clrquad),_._cachedQuad.imgquad&&(_._cachedQuad.imageEntry&&l._objectListGet(d,_._cachedQuad.imageEntry),w.push(_._cachedQuad.imgquad)),void(_._cachedQuad.vidquad&&(_._cachedQuad.videoEntry&&l._objectListGet(p,_._cachedQuad.videoEntry),M.push(_._cachedQuad.vidquad)));var T,E,C,k,S,O,P,L,R,I,D,N,F={};if(P=l._positionToQuad(n,m,_,u),I=g.call(l,_,u),void 0!==P&&I&&!(I<0)){if(e=Math.pow(P.ll[0]-P.ur[0],2)+Math.pow(P.ll[1]-P.ur[1],2)+Math.pow(P.ll[2]-P.ur[0],2)+Math.pow(P.lr[0]-P.ur[0],2)+Math.pow(P.lr[1]-P.ur[1],2)+Math.pow(P.lr[2]-P.ur[0],2),F.diag2=e,F.ll=P.ll,(void 0===t||e&&e<t)&&(A=P.ll,t=e),P=[P.ll[0],P.ll[1],P.ll[2],P.lr[0],P.lr[1],P.lr[2],P.ul[0],P.ul[1],P.ul[2],P.ur[0],P.ur[1],P.ur[2]],T={idx:u,pos:P,opacity:I,zOffset:_.zOffset},_.reference&&(T.reference=_.reference),_.crop&&(T.crop=_.crop),R=(L=o.call(l,_,u))?null:a.call(l,_,u),L){if(F.imageEntry=L,void 0===(E=l._objectListGet(d,L))&&(L instanceof Image||L instanceof HTMLCanvasElement?E=L:(E=new Image).src=L,l._objectListAdd(d,L,E)),i.isReadyImage(E)||E instanceof HTMLCanvasElement)T.image=E;else if(D=void 0,(N=x.call(l,_,u))&&i.isReadyImage(N)?T.image=N:(D=v.call(l,_,u),T.color=i.convertColor(D),T.color&&void 0!==T.color.r&&void 0!==T.color.g&&void 0!==T.color.b?(b.push(T),F.clrquad=T):D=void 0),y.call(l,_,u))O=i.isReadyImage(E,!0)?null:r.Deferred(),k=E.onload,E.onload=function(){if(void 0!==D&&(b.includes(T)&&b.splice(b.indexOf(T),1),delete F.clrquad),T.image=E,l.dataTime().modified(),l.modified(),l._update(),l.layer().draw(),O&&O.resolve(),k)return k.apply(l,arguments)},S=E.onerror,E.onerror=function(){if(O&&O.reject(),S)return S.apply(l,arguments)},O&&l.layer().addPromise(O.promise());else if(void 0===D&&!T.image)return;w.push(T),F.imgquad=T}else if(R){if(F.videoEntry=R,void 0===(C=l._objectListGet(p,R))&&(R instanceof HTMLVideoElement?C=R:(C=document.createElement("video")).src=R,l._objectListAdd(p,R,C),r(C).off(".geojsvideo").on("seeking.geojsvideo canplay.geojsvideo pause.geojsvideo playing.geojsvideo",(function(t){l._checkQuadUpdate(T,t)}))),T.delayRenderWhenSeeking=c.call(l,_,u),void 0===T.delayRenderWhenSeeking&&(T.delayRenderWhenSeeking=!0),i.isReadyVideo(C))T.video=C;else if(D=v.call(l,_,u),T.color=i.convertColor(D),T.color&&void 0!==T.color.r&&void 0!==T.color.g&&void 0!==T.color.b?(b.push(T),F.clrquad=T):D=void 0,y.call(l,_,u))O=i.isReadyVideo(C,!0)?null:r.Deferred(),k=C.onloadeddata,C.onloadeddata=function(){if(void 0!==D&&(b.includes(T)&&b.splice(b.indexOf(T),1),delete F.clrquad),T.video=C,l.dataTime().modified(),l.modified(),l._update(),l.layer().draw(),O&&O.resolve(),k)return k.apply(l,arguments)},S=C.onerror,C.onerror=function(){if(O&&O.reject(),S)return S.apply(l,arguments)},O&&l.layer().addPromise(O.promise());else if(void 0===D&&!T.video)return;M.push(T),F.vidquad=T}else{if(T.color=i.convertColor(f.call(l,_,u)),!T.color||void 0===T.color.r||void 0===T.color.g||void 0===T.color.b)return;b.push(T),F.clrquad=T}F.clrquad&&(h+=1,F.clrquad.quadId=h),F.imgquad&&(h+=1,F.imgquad.quadId=h),F.vidquad&&(h+=1,F.vidquad.quadId=h),!1!==s&&(_._cachedQuad=F)}})),l._objectListEnd(d),l._objectListEnd(p),u={clrQuads:b,imgQuads:w,vidQuads:M,origin:new Float32Array(A)}},this.cacheUpdate=function(t){return null==t?r.each(l.data(),(function(t,e){e._cachedQuad&&delete e._cachedQuad})):(isFinite(t)&&(t=l.data()[t]),t._cachedQuad&&delete t._cachedQuad),l.modified(),l},this.video=function(t){var e,n;return isFinite(t)&&(t=l.data()[t]),t._cachedQuad?e=(t._cachedQuad.vidquad||{}).video:(u||l._generateQuads(),(n=l.data().indexOf(t))>=0&&(e=l._objectListGet(p,l.style.get("video")(t,n)))),e instanceof HTMLVideoElement?e:null},this.nearestPixel=function(t){return void 0===t?f:(f=t,l.modified(),l)},this._init=function(t){t=t||{},c.call(l,t),s=!1!==t.cacheQuads;var e=Object.assign({},{color:{r:1,g:1,b:1},opacity:1,depth:0,drawOnAsyncResourceLoaded:!0,previewColor:null,previewImage:null,image:function(t){return t.image},video:function(t){return t.video},position:i.identityFunction},void 0===t.style?{}:t.style);void 0!==t.position&&(e.position=i.ensureFunction(t.position)),l.style(e),l.dataTime().modified()},l};a.create=function(t,e){"use strict";return(e=e||{}).type="quad",o.create(t,e)},a.capabilities={color:"quad.color",image:"quad.image",imageCrop:"quad.imageCrop",imageFixedScale:"quad.imageFixedScale",imageFull:"quad.imageFull",canvas:"quad.canvas",video:"quad.video"},i(a,o),t.exports=a},1098:function(t,e,n){var r=n(8695),i=n(1949),o={dom:{}},a={},s={},u={},l={},c={},f={},h={},d={},p={registerFileReader:function(t,e){f[t]=e},createFileReader:function(t,e){return f.hasOwnProperty(t)?f[t](e):null},registerRenderer:function(t,e){u[t]=e},createRenderer:function(t,e,n,r){if(u.hasOwnProperty(t)){var i=u[t]({layer:e,canvas:n,options:r});return i._init(),i}return null},checkRenderer:function(t,e){if(null===t)return t;if(u.hasOwnProperty(t)){var n=u[t];if(!n.supported||n.supported())return n.apiname||t;if(!n.fallback||e)return!1;var r=p.checkRenderer(n.fallback(),!0);return!1!==r&&console.warn(t+" renderer is unavailable, using "+r+" renderer instead"),r}return!1},rendererForFeatures:function(t){var e,n,r,i,o,a,s=["webgl","canvas","svg","vtkjs",null];for(n=0;n<s.length;n+=1)if(e=s[n],!1!==p.checkRenderer(e,!0)){if(!t)return e;if(l[e]){for(a=!0,i=0;i<t.length;i+=1){if(o=null,(r=t[i]).indexOf(".")>=0&&(o=r,r=r.substr(0,r.indexOf("."))),void 0===l[e][r]){a=!1;break}if(o&&c[e][r]&&!c[e][r][o]){a=!1;break}}if(a)return e}}return console.warn('There is no renderer available for the feature list "'+(t||[]).join(", ")+'".'),!1},registerFeature:function(t,e,n,r){t in l||(l[t]={},c[t]={});var i=l[t][e];return i&&console.warn("The "+t+"."+e+" feature is already registered"),l[t][e]=n,c[t][e]=r,i},createFeature:function(t,e,n,r){var o=n.api(),a={layer:e,renderer:n};if(o in l&&t in l[o]){void 0!==r&&i.deepMerge(a,r);var s=l[o][t](a);return void 0===e.gcs&&(e.gcs=function(){return e.map().gcs()}),s}return null},registerLayerAdjustment:function(t,e,n){t in h||(h[t]={});var r=h[t][e];return r&&console.warn("The "+t+"."+e+" layer adjustment is already registered"),h[t][e]=n,r},adjustLayerForRenderer:function(t,e){var n=e.rendererName();n&&h&&h[n]&&h[n][t]&&h[n][t].apply(e)},registerLayer:function(t,e,n){a[t]=e,s[t]=n},createLayer:function(t,e,n){var r={map:e},o=null;if(t in a){if(n.renderer||n.features||!s||(r.features=s[t]),void 0!==n){var u=n.data;delete n.data,i.deepMerge(r,n),u&&(r.data=u)}return(o=a[t](r)).layerName=t,o._init(),o}return null},registerWidget:function(t,e,n){t in o||(o[t]={});var r=o[t][e];return r&&console.warn("The "+t+"."+e+" widget is already registered"),o[t][e]=n,r},createWidget:function(t,e,n){var r={layer:e};if(t in o.dom)return void 0!==n&&i.deepMerge(r,n),o.dom[t](r);throw new Error("Cannot create unknown widget "+t)},registerAnnotation:function(t,e,n){var i=d[t];return i&&console.warn("The "+t+" annotation is already registered"),d[t]={func:e,features:n||{}},r["annotation_"+t]="geo_annotation_"+t,i},createAnnotation:function(t,e){if(d[t])return d[t].func(e);console.warn("The "+t+" annotation is not registered")},listAnnotations:function(){return Object.keys(d)},featuresForAnnotations:function(t){var e=[];return(Array.isArray(t)?t:Object.keys(t)).forEach((function(n){d[n]&&Object.keys(d[n].features).forEach((function(r){Array.isArray(t)||!0===t[n]||!Array.isArray(d[n].features[r])?e.push(r):t[n].forEach((function(t){d[n].features[r].includes(t)&&e.push(r)}))}))})),e},rendererForAnnotations:function(t){return p.rendererForFeatures(p.featuresForAnnotations(t))}};p.registries={annotations:d,features:l,featureCapabilities:c,fileReaders:f,layers:a,renderers:u,widgets:o},t.exports=p},2274:function(t,e,n){var r=n(4626),i=n(1338),o=function(t){"use strict";if(!(this instanceof o))return new o(t);i.call(this);var e=this,n=0,r=0,a=void 0===(t=t||{}).layer?null:t.layer,s=void 0===t.canvas?null:t.canvas,u=!1;return this.layer=function(){return a},this.canvas=function(t){return void 0===t?s:(s=t,e.modified(),e)},this.map=function(){return a?a.map():null},this.initialized=function(t){return void 0===t?u:(u=t,e)},this.api=function(){throw new Error("Should be implemented by derived classes")},this.width=function(){return n},this.height=function(){return r},this._setWidthHeight=function(t,i){return n=t,r=i,e},this._init=function(){return e},this._resize=function(t,n,r,i){return e._setWidthHeight(r,i),e},this._render=function(){return e},this};r(o,i),t.exports=o},5402:function(t,e,n){var r=n(4626),i=n(1338),o=function(t){"use strict";if(!(this instanceof o))return new o;i.call(this,t);var e=this,n=null,r=[],a=this._exit,s=this.geoTrigger,u=this.addPromise,l=this.removePromise;return this.addPromise=function(t){return n&&n.addPromise(t),u(t),e},this.removePromise=function(t){return n&&n.removePromise(t),l(t),e},this.parent=function(t){return void 0===t?n:(n=t,e)},this.addChild=function(t){return Array.isArray(t)?(t.forEach(e.addChild),e):(t.parent(e),r.push(t),e)},this.removeChild=function(t){return Array.isArray(t)?(t.forEach(e.removeChild),e):(r=r.filter((function(e){return e!==t})),e)},this.children=function(){return r.slice()},this.draw=function(t){return e.children().forEach((function(e){e.draw(t)})),e},this.geoTrigger=function(t,i,o){var a;return a=(i=i||{}).geo||{},i.geo=a,a.stopPropagation?e:!o&&n&&a._triggeredBy!==n?(a._triggeredBy=e,n.geoTrigger(t,i),e):(s.call(e,t,i),a.stopPropagation||r.forEach((function(n){n.geoTrigger&&(a._triggeredBy=e,n.geoTrigger(t,i))})),e)},this._exit=function(){r=[],n=null,a()},this};r(o,i),t.exports=o},9079:function(t){t.exports="8e2a6bf94ba85a370a33f2144165d89dd6061439"},3832:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3187),a=function(t){"use strict";var e=this;return this instanceof a?(o.call(this,t),this.select=function(){var t=e.renderer(),n={},r=e.nodeFeature(),i=e.linkFeatures();return n.nodes=t.select(r._svgid()),n.links=i.map((function(e){return t.select(e._svgid())})),n},this):new a(t)};r(a,o),i("svg","graph",a),t.exports=a},6488:function(t,e,n){n(6409).svg={rescale:n(4765)},t.exports={graphFeature:n(3832),lineFeature:n(9456),object:n(5005),pathFeature:n(9927),pointFeature:n(2602),quadFeature:n(4087),renderer:n(2493),tileLayer:n(4061),trackFeature:n(2037),uniqueID:n(7376),vectorFeature:n(5747)}},9456:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(9281),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(2493).d3,r=n(5005),i=n(77),s=n(642);t=t||{},o.call(this,t),r.call(this);var u=this,l=this._init,c=i(),f=0,h=this._update;return this._init=function(t){return l.call(u,t),u},this._build=function(){var t,n,r=u.data()||[],i=u.style(),o=u.renderer(),a=u.position();for(h.call(u),i.fill=function(){return!1},r.forEach((function(n,r){var l,c,f=u.line()(n,r),h={};function d(t){return s.isFunction(t)?function(){return t(f[0],0,n,r)}:t}for(c in i)i.hasOwnProperty(c)&&(h[c]=d(i[c]));t=e.line().x((function(t){return u.featureGcsToDisplay(t).x})).y((function(t){return u.featureGcsToDisplay(t).y})).curve(u.style.get("closed")(n,r)&&f.length>2?e.curveLinearClosed:e.curveLinear),l={data:[f.map((function(t,e){return a(t,e,n,r)}))],append:"path",attributes:{d:t},id:u._svgid()+r,classes:["svgLineFeature","svgSubLine-"+r],visible:u.visible,style:h},o._drawFeatures(l)})),n=r.length;n<f;n+=1)o._removeFeature(u._svgid()+n);return f=r.length,c.modified(),u.updateTime().modified(),u},this._update=function(){return h.call(u),u.timestamp()>=c.timestamp()&&u._build(),u},this._init(t),this};r(a,o);var s={};s[o.capabilities.basic]=!0,s[o.capabilities.multicolor]=!1,i("svg","line",a,s),t.exports=a},5005:function(t,e,n){var r=function(t){"use strict";var e=n(1338),i=n(7376);if(!(this instanceof e))return new r(t);var o="svg-"+i(),a=this._exit,s=this,u=this.draw;return this._svgid=function(){return o},this.select=function(){return s.renderer().select(s._svgid())},this.draw=function(){return s.ready&&(s._update(),u()),s},this._exit=function(){s.renderer()._removeFeature(s._svgid()),a()},this};t.exports=r},9927:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2266),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5005),r=n(77);t=t||{},o.call(this,t),e.call(this);var i=this,s=r(),u=this._update,l={style:{}};return this._build=function(){var t,e,n=i.data()||[],r=i.style.get(),o=i.style.get("position");return u.call(i),e=function(t){return"M"+t.source.x+","+t.source.y+"C"+t.source.x+","+(t.source.y+t.target.y)/2+" "+t.target.x+","+(t.source.y+t.target.y)/2+" "+t.target.x+","+t.target.y},t=[],n.forEach((function(e,r){var a,s;r<n.length-1&&(a=o(e,r),s=o(n[r+1],r+1),t.push({source:i.featureGcsToDisplay(a),target:i.featureGcsToDisplay(s)}))})),l.data=t,l.attributes={d:e},l.id=i._svgid(),l.append="path",l.classes=["svgPathFeature"],l.style=Object.assign({fill:function(){return!1},fillColor:{r:0,g:0,b:0}},r),l.visible=i.visible,i.renderer()._drawFeatures(l),s.modified(),i.updateTime().modified(),i},this._update=function(){return u.call(i),i.dataTime().timestamp()>=s.timestamp()&&i._build(),i},this._init(t),this};r(a,o),i("svg","path",a),t.exports=a},2602:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7541),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5005),r=n(77);t=t||{},o.call(this,t),e.call(this);var i=this,s=this._init,u=this._update,l=r(),c={};return this._init=function(t){return s.call(i,t),i},this._build=function(){var t=i.data(),e=i.style.get(),n=i.renderer(),r=i.position();return u.call(i),t||(t=[]),c.id=i._svgid(),c.data=t,c.append="circle",c.attributes={r:n._convertScale(e.radius),cx:function(t){return i.featureGcsToDisplay(r(t)).x},cy:function(t){return i.featureGcsToDisplay(r(t)).y}},c.style=e,c.classes=["svgPointFeature"],c.visible=i.visible,i.renderer()._drawFeatures(c),l.modified(),i.updateTime().modified(),i},this._update=function(){return u.call(i),i.timestamp()>=l.timestamp()&&i._build(),i},this._init(t),this};r(a,o);var s={};s[o.capabilities.stroke]=!0,i("svg","point",a,s),t.exports=a},4087:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3842),a=function(t){"use strict";if(!(this instanceof a))return new a(t);var e=n(5616),r=n(2493).d3,i=n(5005);o.call(this,t),i.call(this);var s,u=this,l=this._exit,c=this._init,f=this._update;return this._build=function(){if(this.position()){var t=u.renderer(),n=t.layer().map();s=u._generateQuads();var i=[];e.each(s.clrQuads,(function(t,e){i.push({type:"clr",quad:e,zIndex:e.pos[2]})})),e.each(s.imgQuads,(function(t,e){e.image&&i.push({type:"img",quad:e,zIndex:e.pos[2]})}));var o={id:u._svgid(),data:i,dataIndex:function(t){return t.quad.quadId},append:function(t){var e=this.namespaceURI,n="clr"===t.type?"polygon":"image";return e?document.createElementNS(e,n):document.createElement(n)},attributes:{fill:function(t){if("clr"===t.type)return r.rgb(255*t.quad.color.r,255*t.quad.color.g,255*t.quad.color.b);1!==t.quad.opacity&&r.select(this).style("opacity",t.quad.opacity)},height:function(t){return"clr"===t.type?void 0:1},points:function(e){if("clr"===e.type&&!e.points){var r,i=[];for(r=0;r<e.quad.pos.length;r+=3){var o={x:e.quad.pos[r],y:e.quad.pos[r+1],z:e.quad.pos[r+2]};o=n.gcsToDisplay(o,null),o=t.baseToLocal(o),i.push(o.x+","+o.y)}e.points=i[0]+" "+i[1]+" "+i[3]+" "+i[2]}return"clr"===e.type?e.points:void 0},preserveAspectRatio:function(t){return"clr"===t.type?void 0:"none"},reference:function(t){return t.quad.reference},stroke:!1,transform:function(e){if("img"===e.type&&e.quad.image&&!e.svgTransform){var r,i,o,a,s=[],u=-1,l=e.quad.image.width,c=e.quad.image.height;for(o=0;o<e.quad.pos.length;o+=3){var f={x:e.quad.pos[o],y:e.quad.pos[o+1],z:e.quad.pos[o+2]};f=n.gcsToDisplay(f,null),f=t.baseToLocal(f),s.push(f)}for(o=0;o<4;o+=1)(r=Math.abs(s[(o+1)%4].x*(s[(o+2)%4].y-s[(o+3)%4].y)+s[(o+2)%4].x*(s[(o+3)%4].y-s[(o+1)%4].y)+s[(o+3)%4].x*(s[(o+1)%4].y-s[(o+2)%4].y))/2)>u&&(u=r,i=o);e.svgTransform=[3===i||2===i?s[1].x-s[0].x:s[3].x-s[2].x,3===i||2===i?s[1].y-s[0].y:s[3].y-s[2].y,0===i||2===i?s[1].x-s[3].x:s[0].x-s[2].x,0===i||2===i?s[1].y-s[3].y:s[0].y-s[2].y,2===i?s[3].x+s[0].x-s[1].x:s[2].x,2===i?s[3].y+s[0].y-s[1].y:s[2].y],Math.abs(e.svgTransform[1]/l)<1e-6&&Math.abs(e.svgTransform[2]/c)<1e-6&&(a=e.svgTransform[0]/l,e.svgTransform[4]=Math.round(e.svgTransform[4]/a)*a,a=e.svgTransform[3]/c,e.svgTransform[5]=Math.round(e.svgTransform[5]/a)*a)}return"img"===e.type&&e.quad.image?"matrix("+e.svgTransform.join(" ")+")":void 0},width:function(t){return"clr"===t.type?void 0:1},x:function(t){return"clr"===t.type?void 0:0},"xlink:href":function(t){return"clr"!==t.type&&t.quad.image?t.quad.image.src:void 0},y:function(t){return"clr"===t.type?void 0:0}},style:{fillOpacity:function(t){return"clr"===t.type?t.quad.opacity:void 0}},onlyRenderNew:!this.style("previewColor")&&!this.style("previewImage"),sortByZ:!0,visible:u.visible,classes:["svgQuadFeature"]};t._drawFeatures(o),u.buildTime().modified()}},this._update=function(){return f.call(u),(u.buildTime().timestamp()<=u.dataTime().timestamp()||u.buildTime().timestamp()<u.timestamp())&&u._build(),u},this._init=function(){c.call(u,t)},this._exit=function(){l.call(u)},u._init(t),this};r(a,o);var s={};s[o.capabilities.color]=!0,s[o.capabilities.image]=!0,s[o.capabilities.imageCrop]=!1,s[o.capabilities.imageFixedScale]=!1,s[o.capabilities.imageFull]=!1,s[o.capabilities.canvas]=!1,s[o.capabilities.video]=!1,i("svg","quad",a,s),t.exports=a},4765:function(t){t.exports="geo_svg_rescale"},2493:function(t,e,n){var r=n(4626),i=n(1098).registerRenderer,o=n(2274),a=function(t){"use strict";var e=a.d3,r=n(5005),i=n(642),s=n(6409),u=n(4765);if(!(this instanceof a))return new a(t);o.call(this,t);var l=this._exit;r.call(this,t),t=t||{};var c=this,f=null,h={},d=null,p=null,m=1,g={dx:0,dy:0,rx:0,ry:0,rotation:0},y={},v={},x=null,_=null;function b(t){return t?x.select(".group-"+t):x.select(".group-"+c._svgid())}function w(){var t=c.layer().map(),e=t.size().width,n=t.size().height;if(!e||!n)throw new Error("Map layer has size 0");c._setWidthHeight(e,n),p=Math.pow(e*e+n*n,.5),d={upperLeft:t.displayToGcs({x:0,y:0},null),lowerRight:t.displayToGcs({x:e,y:n},null),center:t.displayToGcs({x:e/2,y:n/2},null)}}return this._convertColor=function(t,n){return t=i.ensureFunction(t),n=n||function(){return!0},function(){var r="none";return n.apply(c,arguments)&&(r=t.apply(c,arguments)).hasOwnProperty("r")&&r.hasOwnProperty("g")&&r.hasOwnProperty("b")&&(r=e.rgb(255*r.r,255*r.g,255*r.b)),r}},this._convertScale=function(t){return t=i.ensureFunction(t),function(){return t.apply(c,arguments)/m}},this._setTransform=function(){if(d||w(),f){var t,e,n,r,i,o,a=c.layer().map(),s=a.gcsToDisplay(d.upperLeft,null),u=a.gcsToDisplay(d.lowerRight,null),l=a.gcsToDisplay(d.center,null),h=b();n=Math.sqrt(Math.pow(u.y-s.y,2)+Math.pow(u.x-s.x,2))/p,r=a.rotation(),i=-c.width()/2,o=-c.height()/2,t=n*i+l.x,e=n*o+l.y,r||(t=Math.round(t),e=Math.round(e));var y="matrix("+[n,0,0,n,t,e].join()+")";r&&(y+=" rotate("+[180*r/Math.PI,-i,-o].join()+")"),h.attr("transform",y),m=n,g.dx=t,g.dy=e,g.rx=i,g.ry=o,g.rotation=r}},this.baseToLocal=function(t){if(t={x:(t.x-g.dx)/m,y:(t.y-g.dy)/m},g.rotation){var e=Math.sin(-g.rotation),n=Math.cos(-g.rotation),r=t.x+g.rx,i=t.y+g.ry;t={x:r*n-i*e-g.rx,y:r*e+i*n-g.ry}}return t},this.localToBase=function(t){if(g.rotation){var e=Math.sin(g.rotation),n=Math.cos(g.rotation),r=t.x+g.rx,i=t.y+g.ry;t={x:r*n-i*e-g.rx,y:r*e+i*n-g.ry}}return t={x:t.x*m+g.dx,y:t.y*m+g.dy}},this._init=function(t){if(!c.canvas()){var n;t.widget=t.widget||!1,(x="d3Parent"in t?e.select(t.d3Parent).append("svg"):e.select(c.layer().node().get(0)).append("svg")).attr("display","block");var r=(_=x.append("defs")).append("filter").attr("id","geo-highlight").attr("x","-100%").attr("y","-100%").attr("width","300%").attr("height","300%");r.append("feMorphology").attr("operator","dilate").attr("radius",2).attr("in","SourceAlpha").attr("result","dilateOut"),r.append("feGaussianBlur").attr("stdDeviation",5).attr("in","dilateOut").attr("result","blurOut"),r.append("feColorMatrix").attr("type","matrix").attr("values","-1 0 0 0 1 0 -1 0 0 1 0 0 -1 0 1 0 0 0 1 0").attr("in","blurOut").attr("result","invertOut"),r.append("feBlend").attr("in","SourceGraphic").attr("in2","invertOut").attr("mode","normal"),t.widget||(n=t.canvas||x.append("g")),(r=_.append("filter").attr("id","geo-blur").attr("x","-100%").attr("y","-100%").attr("width","300%").attr("height","300%")).append("feGaussianBlur").attr("stdDeviation",20).attr("in","SourceGraphic"),f=c.layer().sticky(),x.attr("class",c._svgid()),x.attr("width",c.layer().node().width()),x.attr("height",c.layer().node().height()),t.widget?c.canvas(x):(n.attr("class","group-"+c._svgid()),c.canvas(n))}return c._setTransform(),c},this.api=function(){return a.apiname},this.scaleFactor=function(){return m},this._resize=function(t,e,n,r){return d||w(),x.attr("width",n),x.attr("height",r),c._setTransform(),c._setWidthHeight(n,r),c.layer().geoTrigger(u,{scale:m},!0),c},this._exit=function(){h={},c.canvas().remove(),x.remove(),x=void 0,_.remove(),_=void 0,y={},v={},l()},this._definitions=function(){return _},this._drawFeatures=function(t){return h[t.id]={data:t.data,index:t.dataIndex,style:t.style,visible:t.visible,attributes:t.attributes,classes:t.classes,append:t.append,onlyRenderNew:t.onlyRenderNew,sortByZ:t.sortByZ,parentId:t.parentId},c.__render(t.id,t.parentId)},this.__render=function(t,e){var n;if(void 0===t){for(n in h)h.hasOwnProperty(n)&&c.__render(n);return c}return e?c._renderFeature(t,e):(y[t]=!0,c.layer().map().scheduleAnimationFrame(c._renderFrame)),c},this._renderFrame=function(){var t;for(t in v)c.select(t).remove(),_.selectAll("."+t).remove();v={};var e=y;for(t in y={},e)e.hasOwnProperty(t)&&c._renderFeature(t)},this._renderFeature=function(t,e){if(!h[t])return c;var n,r,i=h[t].data,o=h[t].index,a=h[t].style,s=h[t].visible,u=h[t].attributes,l=h[t].classes,f=h[t].append,d=c.select(t,e).data(i,o);return n=d.enter().append(f),d.exit().remove(),function(t,e){var n;for(n in e)e.hasOwnProperty(n)&&t.attr(n,e[n])}(r=n,u),r.attr("class",l.concat([t]).join(" ")),function(t,e){var n,r,i;function o(){return e.fill.apply(c,arguments)?null:"none"}function a(){return e.stroke.apply(c,arguments)?null:"none"}for(n in e)e.hasOwnProperty(n)&&(i=null,r=null,"strokeColor"===n?(r="stroke",i=c._convertColor(e[n],e.stroke)):"stroke"===n&&e[n]&&!e.hasOwnProperty("strokeColor")?(r="stroke",i=a):"strokeWidth"===n?(r="stroke-width",i=c._convertScale(e[n])):"strokeOpacity"===n?(r="stroke-opacity",i=e[n]):"fillColor"===n?(r="fill",i=c._convertColor(e[n],e.fill)):"fill"!==n||e.hasOwnProperty("fillColor")?"fillOpacity"===n?(r="fill-opacity",i=e[n]):"lineCap"===n?(r="stroke-linecap",i=e[n]):"lineJoin"===n?(r="stroke-linejoin",i=e[n]):"miterLimit"===n&&(r="stroke-miterlimit",i=e[n]):(r="fill",i=o),r&&t.style(r,i))}(r,a),s&&r.style("visibility",s()?"visible":"hidden"),n.size()&&h[t].sortByZ&&d.sort((function(t,e){return(t.zIndex||0)-(e.zIndex||0)})),c},this.select=function(t,e){return b(e).selectAll("."+t)},this._removeFeature=function(t){return v[t]=!0,c.layer().map().scheduleAnimationFrame(c._renderFrame),delete h[t],y[t]&&delete y[t],c},this.draw=function(){},this.layer().geoOn(s.pan,c._setTransform),this.layer().geoOn(s.rotate,c._setTransform),this.layer().geoOn(s.zoom,(function(){c._setTransform(),c.__render(),c.layer().geoTrigger(u,{scale:m},!0)})),this.layer().geoOn(s.resize,(function(t){c._resize(t.x,t.y,t.width,t.height)})),this._init(t),this};a.apiname="svg",r(a,o),i("svg",a),i("d3",a),a.supported=function(){delete a.d3;try{a.d3=n(5127),a.d3&&a.d3.rgb||(a.d3=void 0)}catch(t){}return void 0!==a.d3},a.fallback=function(){return null},a.supported(),t.exports=a},4061:function(t,e,n){var r=function(){"use strict";var t,e=this,n=this._init,r=this._exit,i=this._update,o=0,a=[];this._drawTile=function(n){if(t){var r=e._tileBounds(n),i=n.index.level||0,s=e._tileOffset(i),u={};u.ul=e.fromLocal(e.fromLevel({x:r.left-s.x,y:r.top-s.y},i),0),u.ll=e.fromLocal(e.fromLevel({x:r.left-s.x,y:r.bottom-s.y},i),0),u.ur=e.fromLocal(e.fromLevel({x:r.right-s.x,y:r.top-s.y},i),0),u.lr=e.fromLocal(e.fromLevel({x:r.right-s.x,y:r.bottom-s.y},i),0),u.ul.z=u.ll.z=u.ur.z=u.lr.z=i,o+=1,u.id=o,n.quadId=u.id,u.image=n.image,u.reference=n.toString(),a.push(u),t.data(a),t._update(),e.draw()}},this._remove=function(n){if(void 0!==n.quadId&&t){for(var r=0;r<a.length;r+=1)if(a[r].id===n.quadId){a.splice(r,1);break}t.data(a),t._update(),e.draw()}},this._update=function(n){return i.call(e,n),e._addBaseQuadToTiles(t,a),e},this._exit=function(){e.deleteFeature(t),t=null,a=[],r.apply(e,arguments)},this._init=function(){n.apply(e,arguments),(t=e.createFeature("quad",{previewColor:e._options.previewColor,previewImage:e._options.previewImage})).geoTrigger=void 0,t.gcs(e._options.gcs||e.map().gcs()),t.data(a),t._update()},this._getSubLayer=function(){},this._updateSubLayers=void 0};(0,n(1098).registerLayerAdjustment)("svg","tile",r),t.exports=r},2037:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(338),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(5005).call(this),this._init(t),this):new a(t)};r(a,o),i("svg","track",a),t.exports=a},7376:function(t){var e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz";t.exports=function(){var t,n=[];for(n.length=8,t=0;t<8;t+=1)n[t]=e.charAt(Math.floor(61*Math.random()));return n.join("")}},5747:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6858),a={arrow:{attrs:{class:"geo-vector-arrow geo-vector-marker",viewBox:"0 0 10 10",refX:1,refY:5,markerHeight:5,markerWidth:5,orient:"auto"},path:"M 0 0 L 10 5 L 0 10 z"},point:{attrs:{class:"geo-vector-point geo-vector-marker",viewBox:"0 0 12 12",refX:6,refY:6,markerHeight:8,markerWidth:8,orient:"auto"},path:"M 6 3 A 3 3 0 1 1 5.99999 3 Z"},bar:{attrs:{class:"geo-vector-bar geo-vector-marker",viewBox:"0 0 10 10",refX:0,refY:5,markerHeight:6,markerWidth:6,orient:"auto"},path:"M 0 0 L 2 0 L 2 10 L 0 10 z"},wedge:{attrs:{class:"geo-vector-wedge geo-vector-marker",viewBox:"0 0 10 10",refX:10,refY:5,markerHeight:5,markerWidth:5,orient:"auto"},path:"M 0 0 L 1 0 L 10 5 L 1 10 L 0 10 L 9 5 L 0 0"}},s=function(t){"use strict";if(!(this instanceof s))return new s(t);var e=n(5005),r=n(77),i=n(2493).d3;t=t||{},o.call(this,t),e.call(this);var u=this,l=this._exit,c=this._update,f=r(),h={};function d(t,e,n){return u._svgid()+"_marker_"+e+"_"+n}function p(t,e,n,r,o){var s=u.renderer()._definitions().selectAll("g.marker-group#"+u._svgid()).data(t.length?[1]:[]);s.enter().append("g").attr("id",u._svgid).attr("class","marker-group"),s.exit().remove();var l=t.reduce((function(t,e,n){var i=a[o(e,n)],s=a[r(e,n)];return i&&t.push({data:e,dataIndex:n,head:!0}),s&&t.push({data:e,dataIndex:n,head:!1}),t}),[]),c=(s=u.renderer()._definitions().selectAll("g.marker-group#"+u._svgid())).selectAll("marker.geo-vector-marker").data(l),f=u.renderer();c.enter().append("marker").each((function(t){var e=i.select(this),n=t.head?a[o(t.data,t.dataIndex)]:a[r(t.data,t.dataIndex)];Object.keys(n.attrs).forEach((function(t){e.attr(t,n.attrs[t])}))})).attr("id",(function(t){return d(t.data,t.dataIndex,t.head?"head":"tail")})).style("stroke",(function(t){return f._convertColor(e)(t.data,t.dataIndex)})).style("fill",(function(t){return f._convertColor(e)(t.data,t.dataIndex)})).style("opacity",(function(t){return n(t.data,t.dataIndex)})).append("path").attr("d",(function(t){return t.head?a[o(t.data,t.dataIndex)].path:a[r(t.data,t.dataIndex)].path})),c.exit().remove()}return this._build=function(){var t,e=u.data(),n=u.style.get(),r=u.renderer(),i=u.origin(),o=u.delta(),a=u.style("scale"),s=0;function l(){return a/r.scaleFactor()}return c.call(u),e||(e=[]),t=e.map((function(t,e){var n=u.featureGcsToDisplay(i(t,e)),r=o(t,e);return s=Math.max(s,r.x*r.x+r.y*r.y),{x1:n.x,y1:n.y,dx:r.x,dy:-r.y}})),s=Math.sqrt(s),a||(a=75/(s||1)),h.id=u._svgid(),h.data=e,h.append="line",h.attributes={x1:function(e,n){return t[n].x1},y1:function(e,n){return t[n].y1},x2:function(e,n){return t[n].x1+l()*t[n].dx},y2:function(e,n){return t[n].y1+l()*t[n].dy},"marker-start":function(t,e){return"url(#"+d(0,e,"tail")+")"},"marker-end":function(t,e){return"url(#"+d(0,e,"head")+")"}},h.style={stroke:function(){return!0},strokeColor:n.strokeColor,strokeWidth:n.strokeWidth,strokeOpacity:n.strokeOpacity,originStyle:n.originStyle,endStyle:n.endStyle},h.classes=["svgVectorFeature"],h.visible=u.visible,p(e,n.strokeColor,n.strokeOpacity,n.originStyle,n.endStyle),u.renderer()._drawFeatures(h),f.modified(),u.updateTime().modified(),u},this._update=function(){return c.call(u),u.timestamp()>=f.timestamp()?u._build():p(h.data,h.style.strokeColor,h.style.strokeOpacity,h.style.originStyle,h.style.endStyle),u},this._exit=function(){l.call(u),h={},p([],null,null,null,null)},this._init(t),this};s.markerConfigs=a,r(s,o),i("svg","vector",s),t.exports=s},6546:function(t,e,n){var r=n(4626),i=n(1275),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=this,n=this._init;return this.featureType="text",this.position=function(t){return void 0===t?e.style("position"):(t!==e.style("position")&&(e.style("position",t),e.dataTime().modified(),e.modified()),e)},this.text=function(t){return void 0===t?e.style("text"):(t!==e.style("text")&&(e.style("text",t),e.dataTime().modified(),e.modified()),e)},this._init=function(t){t=t||{},n.call(e,t);var r=Object.assign({},{font:"bold 16px sans-serif",textAlign:"center",textBaseline:"middle",color:{r:0,g:0,b:0},rotation:0,rotateWithMap:!1,textScaled:!1,position:function(t){return Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:t},text:function(t){return t.text}},void 0===t.style?{}:t.style);void 0!==t.position&&(r.position=t.position),void 0!==t.text&&(r.text=t.text),e.style(r),r.position&&e.position(r.position),r.text&&e.text(r.text),e.dataTime().modified()},this._init(t),e};o.usedStyles=["visible","font","fontStyle","fontVariant","fontWeight","fontStretch","fontSize","lineHeight","fontFamily","textAlign","textBaseline","color","textOpacity","rotation","rotateWithMap","textScaled","offset","shadowColor","shadowOffset","shadowBlur","shadowRotate","textStrokeColor","textStrokeWidth"],o.create=function(t,e){"use strict";return(e=e||{}).type="text",i.create(t,e)},o.capabilities={feature:"text"},r(o,i),t.exports=o},5289:function(t,e,n){var r=n(5616),i=function(t){if(!(this instanceof i))return new i(t);this._index=t.index,this._size=t.size,this._overlap=t.overlap||{x:0,y:0},this._wrap=t.wrap||{x:1,y:1},this._url=t.url,this._fetched=!1,this._queue=t.queue||null,Object.defineProperty(this,"index",{get:function(){return this._index}}),Object.defineProperty(this,"size",{get:function(){return this._size}}),Object.defineProperty(this,"overlap",{get:function(){return this._overlap}}),this.fetch=function(){return this._fetched||r.get(this._url).done(function(){this._fetched=!0}.bind(this)).promise(this),this},this.fetched=function(){return this._fetched},this.then=function(t,e){return this.fetched()||!this._queue||!this._queue.add||this.state&&"pending"!==this.state()?this.fetch():this._queue.add(this,this.fetch),this.done&&this.fail?this.done(t).fail(e):this.then(t,e),this},this.catch=function(t){return this.then(void 0,t),this},this.toString=function(){return[this._index.level||0,this._index.y,this._index.x,this._index.reference||0].join("_")},this.bounds=function(t,e){var n,r,i,o;return r=(n=this.size.x*(this.index.x-t.x)-this.overlap.x-e.x)+this.size.x+2*this.overlap.x,i=(o=this.size.y*(this.index.y-t.y)-this.overlap.y-e.y)+this.size.y+2*this.overlap.y,this.overlap.x&&this.index.x===t.x&&(n+=this.overlap.x),this.overlap.y&&this.index.y===t.y&&(o+=this.overlap.y),{left:n,right:r,bottom:i,top:o}},Object.defineProperty(this,"bottom",{get:function(){return this.size.y*(this.index.y+1)+this.overlap.y}}),Object.defineProperty(this,"top",{get:function(){return this.size.y*this.index.y-(this.index.y?this.overlap.y:0)}}),Object.defineProperty(this,"left",{get:function(){return this.size.x*this.index.x-(this.index.x?this.overlap.x:0)}}),Object.defineProperty(this,"right",{get:function(){return this.size.x*(this.index.x+1)+this.overlap.x}}),this.fadeIn=function(t){return r.noop(t),this}};t.exports=i},9123:function(t){var e=function(t){return this instanceof e?(t=t||{},this._size=t.size||64,Object.defineProperty(this,"size",{get:function(){return this._size},set:function(t){for(;this._atime.length>t;)this.remove(this._atime[this._atime.length-1]);this._size=t}}),Object.defineProperty(this,"length",{get:function(){return this._atime.length}}),this._access=function(t){return this._atime.indexOf(t)},this.remove=function(t){var e="string"==typeof t?t:t.toString();return e in this._cache&&(this._atime.splice(this._access(e),1),delete this._cache[e],!0)},this.clear=function(){return this._cache={},this._atime=[],this},this.get=function(t,e){return(t="string"==typeof t?t:t.toString())in this._cache?(e||(this._atime.splice(this._access(t),1),this._atime.unshift(t)),this._cache[t]):null},this.add=function(t,e,n){this.remove(t);var r=t.toString();this._cache[r]=t,this._atime.unshift(r),n||this.purge(e)},this.purge=function(t){for(var e;this._atime.length>this.size;){e=this._atime.pop();var n=this._cache[e];t&&t(n),delete this._cache[e]}},this.clear(),this):new e(t)};t.exports=e},9264:function(t,e,n){var r=n(4626),i=n(6498),o=n(642);function a(t,e){return(t%e+e)%e}function s(t){var e,n=/\$?\{(s|S|[sS]:[^{}]+|[^-{}]-[^-{}]|([^,{}]+,)+[^,{}]+)\}/,r=t.replace(new RegExp(n,"g"),"{s}").replace(/\$?\{[xX]\}/g,"{x}").replace(/\$?\{[yY]\}/g,"{y}").replace(/\$?\{[zZ]\}/g,"{z}"),i=t.match(n);if(i)if(i[2])e=i[1].split(",");else if(":"===i[1][1])e=i[1].substr(2).split("");else if("-"===i[1][1]){e=[];for(var o=i[1].charCodeAt(0),s=i[1].charCodeAt(2),u=Math.min(o,s);u<=Math.max(o,s);u+=1)e.push(String.fromCharCode(u))}return function(t,n,i,o){return r.replace(/\{s\}/g,function(t,e,n,r){return r[a(t+e+n,r.length)]}(t,n,i,e||o)).replace(/\{x\}/g,t).replace(/\{y\}/g,n).replace(/\{z\}/g,i)}}var u=function(t){"use strict";if(!(this instanceof u))return new u(t);i.call(this,t);var e=n(5616),r=n(6409),l=n(5325),c=n(9123),f=n(5938),h=n(1098).adjustLayerForRenderer,d=n(5289);if((t=o.deepMerge({},this.constructor.defaults,t||{})).cacheSize||(t.cacheSize=t.keepLower?600:200),"string"===e.type(t.subdomains)&&(t.subdomains=t.subdomains.split("")),t.baseUrl){var p=t.baseUrl;p&&"/"!==p.charAt(p.length-1)&&(p+="/"),t.url=p+"{z}/{x}/{y}."+(t.imageFormat||"png")}t.originalUrl=t.url,"string"===e.type(t.url)&&(t.url=s(t.url));var m,g,y,v=this._init,x=this._exit,_=this.visible,b=t.queueSize||6,w=t.initialQueueSize||0,M=[],A={},T=[],E=t.nearestPixel,C=this;this._options=o.deepMerge({},t),this.attribution(t.attribution),this._activeTiles={},this._tileTree={},this._cache=c({size:t.cacheSize}),this._queue=t.queue||f({size:b,initialSize:w,track:t.cacheSize,needed:function(t){return this._tileLayers&&this._tileLayers.length?this._tileLayers.some((function(e){return t===e.cache.get(t.toString(),!0)})):t===C.cache.get(t.toString(),!0)}}),this._queue._tileLayers=this._queue._tileLayers||[],this._queue._tileLayers.push(C),this._queue.initialTrack&&this._queue.track&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length);var k={};return Object.defineProperty(this,"options",{get:function(){return Object.assign({},C._options)}}),Object.defineProperty(this,"cache",{get:function(){return C._cache}}),Object.defineProperty(this,"activeTiles",{get:function(){return Object.assign({},C._activeTiles)}}),Object.defineProperty(this,"queue",{get:function(){return C._queue},set:function(t){C._queue!==t&&(this._queue&&this._queue._tileLayers&&this._queue._tileLayers.indexOf(C)>=0&&(this._queue._tileLayers.splice(this._queue._tileLayers.indexOf(C),1),this._queue.initialTrack&&this._queue.track&&this._queue._tileLayers.length&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length)),C._queue=t,C._queue._tileLayers=C._queue._tileLayers||[],C._queue._tileLayers.push(C),C._queue.initialTrack&&C._queue.track&&(C._queue.track=C._queue.initialTrack*C._queue._tileLayers.length))}}),Object.defineProperty(this,"queueSize",{get:function(){return b},set:function(t){b=t,C._queue.size=t}}),Object.defineProperty(this,"initialQueueSize",{get:function(){return w},set:function(t){w=t||0,C._queue.initialSize=t||b}}),Object.defineProperty(this,"reference",{get:function(){return C.id()+"_"+(m||0)},set:function(t){m=t},configurable:!0}),this.tilesAtZoom=function(t){if(C._options.tilesAtZoom)return C._options.tilesAtZoom.call(C,t);var e=Math.pow(2,t);return{x:e,y:e}},this.tilesMaxBounds=function(t){return C._options.tilesMaxBounds?C._options.tilesMaxBounds.call(C,t):null},this.tileCropFromBounds=function(t){if(C._options.tilesMaxBounds){var e=t.index.level,n=C._tileBounds(t);return void 0===T[e]&&(T[e]=C.tilesMaxBounds(e)||null),T[e]&&(n.right>T[e].x||n.bottom>T[e].y)?{x:Math.max(0,Math.min(T[e].x,n.right)-n.left),y:Math.max(0,Math.min(T[e].y,n.bottom)-n.top)}:void 0}},this.isValid=function(t){return C._options.minLevel<=t.level&&t.level<=C._options.maxLevel&&(!!(C._options.wrapX||0<=t.x&&t.x<=C.tilesAtZoom(t.level).x-1)&&!!(C._options.wrapY||0<=t.y&&t.y<=C.tilesAtZoom(t.level).y-1))},this._origin=function(t){var e,n=C.toLevel(C.toLocal(C.map().origin()),t),r=C._options;return{index:e={x:Math.floor(n.x/r.tileWidth),y:Math.floor(n.y/r.tileHeight)},offset:{x:n.x-r.tileWidth*e.x,y:n.y-r.tileHeight*e.y}}},this._tileBounds=function(t){var e=C._origin(t.index.level);return t.bounds(e.index,e.offset)},this.tileAtPoint=function(t,e){var n=C._origin(e),r=C.map();t=C.displayToLevel(r.gcsToDisplay(t,null),e),isNaN(t.x)&&(t.x=0),isNaN(t.y)&&(t.y=0);var i=C._tileOffset(e);return i&&(t.x+=i.x,t.y+=i.y),{x:Math.floor(n.index.x+(n.offset.x+t.x)/C._options.tileWidth),y:Math.floor(n.index.y+(n.offset.y+t.y)/C._options.tileHeight)}},this.gcsTileBounds=function(t,e){var n=t.index?t:d({index:t,size:{x:C._options.tileWidth,y:C._options.tileHeight},url:""}),r=C._tileOffset(n.index.level),i=n.bounds({x:0,y:0},r),o=C.map(),a=o.unitsPerPixel(n.index.level),s=[{x:i.left*a,y:C._topDown()*i.top*a},{x:i.right*a,y:C._topDown()*i.bottom*a}];return(e=null===e?o.gcs():void 0===e?o.ingcs():e)!==o.gcs()&&(s=l.transformCoordinates(o.gcs(),e,s)),{left:s[0].x,top:s[0].y,right:s[1].x,bottom:s[1].y}},this._getTile=function(t,e){var n=e||t;return d({index:t,size:{x:C._options.tileWidth,y:C._options.tileHeight},queue:C._queue,url:C._options.url.call(C,n.x,n.y,Math.max(n.level||0,0),C._options.subdomains)})},this._getTileCached=function(t,e,n){var r=C.cache.get(C._tileHash(t));return null===r&&(r=C._getTile(t,e),C.cache.add(r,C.remove,n)),r},this._tileHash=function(t){return[t.level||0,t.y,t.x,t.reference||0].join("_")},this._getTileRange=function(t,e){var n=[C.tileAtPoint({x:e.left,y:e.top},t),C.tileAtPoint({x:e.right,y:e.top},t),C.tileAtPoint({x:e.left,y:e.bottom},t),C.tileAtPoint({x:e.right,y:e.bottom},t)];return{start:{x:Math.min(n[0].x,n[1].x,n[2].x,n[3].x),y:Math.min(n[0].y,n[1].y,n[2].y,n[3].y)},end:{x:Math.max(n[0].x,n[1].x,n[2].x,n[3].x),y:Math.max(n[0].y,n[1].y,n[2].y,n[3].y)}}},this._getTiles=function(t,n,r,i){var o,s,u,l,c,f,h,d,p,m,g,y=[],v=!1,x=C._options.keepLower?C._options.minLevel:Math.min(Math.max(t,C._options.minLevel),C._options.maxLevel);for(t<x&&(t=x),g=x;g<=t&&(c=(h=C._getTileRange(g,n)).start,f=h.end,l=C.tilesAtZoom(g),C._options.wrapX||(c.x=Math.min(Math.max(c.x,0),l.x-1),f.x=Math.min(Math.max(f.x,0),l.x-1),g===x&&C._options.keepLower&&(c.x=0,f.x=l.x-1)),C._options.wrapY||(c.y=Math.min(Math.max(c.y,0),l.y-1),f.y=Math.min(Math.max(f.y,0),l.y-1),g===x&&C._options.keepLower&&(c.y=0,f.y=l.y-1)),!(C._options.gcs&&C._options.gcs!==C.map().gcs()&&g!==x&&(f.x+1-c.x)*(f.y+1-c.y)>C.map().size().width*C.map().size().height/C._options.tileWidth/C._options.tileHeight*16));g+=1)for(o=c.x;o<=f.x;o+=1)for(s=c.y;s<=f.y;s+=1)u={level:g,x:o,y:s,reference:C.reference},d={level:g,x:o,y:s,reference:C.reference},C._options.wrapX&&(d.x=a(d.x,l.x)),C._options.wrapY&&(d.y=a(d.y,l.y)),C.isValid(d)&&(i&&y.length<M.length&&(m=M[y.length],v=v||u.level!==m.level||u.x!==m.x||u.y!==m.y),y.push({index:u,source:d}));if(i){if(!v&&y.length===M.length)return;M.splice(0,M.length),e.each(y,(function(t,e){M.push(e.index)}))}if(r){p={x:(c.x+f.x)/2,y:(c.y+f.y)/2,level:t,bottomLevel:t};for(var _=Math.max(f.x-c.x,f.y-c.y)+1;_>=1;_/=2)p.bottomLevel-=1;y.sort(C._loadMetric(p)),C._queue&&C._queue.batch(!0)}for(C.cache.size<y.length&&(console.log("Increasing cache size to "+y.length),C.cache.size=y.length),o=0;o<y.length;o+=1)y[o]=C._getTileCached(y[o].index,y[o].source,!0);return C.cache.purge(C.remove),y},this.gcs=function(t){if(void 0===t)return C._options.gcs||C.map().gcs();var e=C.gcs();return null===t?delete C._options.gcs:C._options.gcs=t,C.gcs()!==e&&(C.clear(),C.gcsFeatures(C.gcs()),C.modified(),C._update()),C},this.prefetch=function(t,n){var r;return r=C._getTiles(t,n,!0),e.when.apply(e,r.map((function(t){return t.fetch()})))},this._loadMetric=function(t){return function(e,n){var r,i,o,a,s;return e=e.index||e,n=n.index||n,e.level!==n.level?t.bottomLevel&&e.level>=t.bottomLevel!=n.level>=t.bottomLevel?e.level>=t.bottomLevel?-1:1:e.level-n.level:(s=Math.pow(2,e.level-t.level),o=(t.x+.5)*s-.5,a=(t.y+.5)*s-.5,(r=e.x-o)*r+(i=e.y-a)*i-((r=n.x-o)*r+(i=n.y-a)*i))}},this.fromLevel=function(t,e){var n=Math.pow(2,-e);return{x:t.x*n,y:t.y*n}},this.toLevel=function(t,e){var n=Math.pow(2,e);return{x:t.x*n,y:t.y*n}},this.drawTile=function(t){var e=t.toString();C._activeTiles.hasOwnProperty(e)?C._moveToTop(t):C._drawTile(t),C._activeTiles[e]=t},this._drawTile=function(t){if(null!==C.renderer())throw new Error("This draw method is not valid on renderer managed layers.");var n,r=t.index.level,i=e(C._getSubLayer(r)),o=C._tileBounds(t),a=C._options.animationDuration,s=e('<div class="geo-tile-container"/>').attr("tile-reference",t.toString());s.append(t.image),s.css({left:o.left-parseInt(i.attr("offsetx")||0,10)+"px",top:o.top-parseInt(i.attr("offsety")||0,10)+"px"}),(n=C.tileCropFromBounds(t))&&s.addClass("crop").css({width:n.x+"px",height:n.y+"px"}),a>0&&t.fadeIn(a),i.append(s),t.catch((function(){console.warn("Could not load tile at "+t.toString()),C._remove(t)}))},this.remove=function(t){var e=t.toString(),n=C._activeTiles[e];return n instanceof d&&C._remove(n),delete C._activeTiles[e],n},this._remove=function(t){t.image&&(t.image.parentElement?e(t.image.parentElement).remove():console.log("No parent element to remove "+t.toString(),t),e(t.image).remove())},this._moveToTop=function(t){e.noop(t)},this._getViewBounds=function(){var t=C.map(),e=t.zoom(),n=C._options.tileRounding(e),r=Math.pow(2,e-n),i=t.size(),o=C.displayToLevel({x:0,y:0}),a=C.displayToLevel({x:i.width,y:0}),s=C.displayToLevel({x:0,y:i.height}),u=C.displayToLevel({x:i.width,y:i.height});return{level:n,scale:r,left:Math.min(o.x,a.x,s.x,u.x),right:Math.max(o.x,a.x,s.x,u.x),top:Math.min(o.y,a.y,s.y,u.y),bottom:Math.max(o.y,a.y,s.y,u.y)}},this._purge=function(t,e,n){var r,i;if(C._updating)return C;for(i in n||(n=C._getViewBounds()),C._activeTiles)r=C._activeTiles[i],C._canPurge(r,n,t,e)&&C.remove(r);return C},this.clear=function(){var t,e=[];for(t in C._activeTiles)e.push(C.remove(t));return C._tileTree={},M=[],e},this.reset=function(){return C.clear(),C._cache.clear(),C._queue.initialSize=w,C},this.toLocal=function(t,e){var n=C.map(),r=n.unitsPerPixel(void 0===e?n.zoom():e);return{x:t.x/r,y:C._topDown()*t.y/r}},this.fromLocal=function(t,e){var n=C.map(),r=n.unitsPerPixel(void 0===e?n.zoom():e);return{x:t.x*r,y:C._topDown()*t.y*r}},this._topDown=function(){return C._options.topDown?1:-1},this._getSubLayer=function(t){if(C.canvas()){var n=C.canvas().find("div[data-tile-layer="+t.toFixed()+"]").get(0);return n||(n=e('<div class=geo-tile-layer data-tile-layer="'+t.toFixed()+'"/>').get(0),C.canvas().append(n)),n}},this._updateSubLayers=function(t,n){var r=C.canvas(),i=parseInt(r.attr("lastlevel"),10),o=parseInt(r.attr("lastoffsetx")||0,10),a=parseInt(r.attr("lastoffsety")||0,10);if(i===t&&Math.abs(o-n.left)<65536&&Math.abs(a-n.top)<65536)return{x:o,y:a};var s=C.map(),u=C._tileOffset(t),l=parseInt((n.left+n.right-s.size().width)/2+u.x,10),c=parseInt((n.top+n.bottom-s.size().height)/2+u.y,10);return r.find(".geo-tile-layer").each((function(n,r){var i=e(r),o=parseInt(i.data("tileLayer"),10);i.css("transform","scale("+Math.pow(2,t-o)+")");var a=parseInt(l/Math.pow(2,t-o),10),s=parseInt(c/Math.pow(2,t-o),10),u=a-parseInt(i.attr("offsetx")||0,10),f=s-parseInt(i.attr("offsety")||0,10);i.attr({offsetx:a,offsety:s}),i.find(".geo-tile-container").each((function(t,n){e(n).css({left:parseInt(e(n).css("left"),10)-u+"px",top:parseInt(e(n).css("top"),10)-f+"px"})}))})),r.attr({lastoffsetx:l,lastoffsety:c,lastlevel:t}),{x:l,y:c}},this._update=function(t){if(t&&t.event&&(t.event.event===r.zoom||t.event.event===r.rotate))return C;if(!C.visible())return C;var n,i=C.map(),o=i.bounds(void 0,null),a=i.zoom(),s=C._options.tileRounding(a);if(C._updateSubLayers){var u=C._getViewBounds(),l=C._updateSubLayers(s,u)||{x:0,y:0},c=C._tileOffset(s);if(null===C.renderer()){var f=Math.pow(2,a-s),h=i.rotation(),d=-c.x+-(u.left+u.right)/2+l.x,p=-c.y+-(u.bottom+u.top)/2+l.y,m=d+i.size().width/2,y=p+i.size().height/2;C.canvas().css({"transform-origin":-d+"px "+-p+"px"});var v="translate("+m+"px,"+y+"px)scale("+f+")";h&&(v+="rotate("+180*h/Math.PI+"deg)"),C.canvas().css("transform",v)}C.canvas().attr({scale:Math.pow(2,a-s),dx:-c.x+-(u.left+u.right)/2,dy:-c.y+-(u.bottom+u.top)/2,offsetx:l.x,offsety:l.y,rotation:i.rotation()})}if(void 0===(n=C._getTiles(s,o,!0,!0)))return C;if(C._tileTree={},n.forEach((function(t){if(t.fetched())delete A[t.toString()],C.drawTile(t),C._setTileTree(t);else{if(t._queued)(C._queue?C._queue.get(t):-1)>=0&&C._queue.add(t);else t.then((function(){if(!g&&t===C.cache.get(t.toString())){var e=i.zoom(),n=C._options.tileRounding(e),r=C._getViewBounds();C._canPurge(t,r,n)?C.remove(t):(C.drawTile(t),C._setTileTree(t))}})),t._queued=!0;C.addPromise(t),A[t.toString()]=t}})),e.when.apply(e,n).done((function(){var t=C.map().zoom(),e=C._options.tileRounding(t);C._purge(e,!0)})),"all"!==C._options.idleAfter)for(var x in A){var _=A[x];n.indexOf(_)<0&&(C.removePromise(_),delete A[x])}return C},this._setTileTree=function(t){if(!C._options.keepLower){var e=t.index;C._tileTree[e.level]=C._tileTree[e.level]||{},C._tileTree[e.level][e.x]=C._tileTree[e.level][e.x]||{},C._tileTree[e.level][e.x][e.y]=t}},this._getTileTree=function(t){return((C._tileTree[t.level]||{})[t.x]||{})[t.y]||null},this._isCovered=function(t){var e=t.index.level,n=t.index.x,r=t.index.y,i=[];return(i=C._getTileTree({level:e-1,x:Math.floor(n/2),y:Math.floor(r/2)}))?[i]:(i=[C._getTileTree({level:e+1,x:2*n,y:2*r}),C._getTileTree({level:e+1,x:2*n+1,y:2*r}),C._getTileTree({level:e+1,x:2*n,y:2*r+1}),C._getTileTree({level:e+1,x:2*n+1,y:2*r+1})]).every((function(t){return null!==t}))?i:null},this._outOfBounds=function(t,e){var n=C._tileOffset(t.index.level),r=1;return t.index.level!==e.level&&(r=Math.pow(2,(e.level||0)-(t.index.level||0))),(t.bottom-n.y)*r<e.top||(t.left-n.x)*r>e.right||(t.top-n.y)*r>e.bottom||(t.right-n.x)*r<e.left},this._canPurge=function(t,e,n,r){if(C._options.keepLower){if((n=n||0)<t.index.level&&t.index.level!==C._options.minLevel)return!0;if(t.index.level===C._options.minLevel&&!C._options.wrapX&&!C._options.wrapY)return!1}else if((r||C._isCovered(t))&&n!==t.index.level&&(n>=C._options.minLevel||t.index.level!==C._options.minLevel)&&(n<C._options.maxLevel||t.index.level!==C._options.maxLevel))return!0;return!!e&&C._outOfBounds(t,e)},this.displayToLevel=function(t,e){var n,r=C.map(),i=r.zoom(),o=C._options.tileRounding(i),a=r.unitsPerPixel(void 0===e?o:e);if(void 0===t){var s=r.size();t={x:s.width/2,y:s.height/2}}try{n=r.displayToGcs(t,C._options.gcs||null)}catch(t){n={x:0,y:0}}return{x:n.x/a,y:C._topDown()*n.y/a}},this.url=function(t){return void 0===t?C._options.originalUrl:(t===C._options.originalUrl||(C._options.originalUrl=t,"string"===e.type(t)&&(t=s(t)),C._options.url=t,C.reset(),C.map().draw()),C)},this.subdomains=function(t){return void 0===t?C._options.subdomains:(t&&("string"===e.type(t)&&(t=t.indexOf(",")>=0?t.split(","):t.split("")),C._options.subdomains=t,C.reset(),C.map().draw()),C)},this._tileOffset=function(t){return void 0===k[t]&&(k[t]=C._options.tileOffset(t)),k[t]},this.visible=function(t){return void 0===t?_():(C.visible()!==t&&(_(t),t&&C._update()),C)},this.nearestPixel=function(t,e){return void 0===t?E:(E!==t&&(E=t,e||(C.modified(),C._update())),C)},Object.defineProperty(this,"baseQuad",{get:function(){return C._options.baseQuad},set:function(t){C._options.baseQuad=t,C._update()}}),this._addBaseQuadToTiles=function(t,e){t&&(this.baseQuad!==y&&(y&&e.splice(0,1),(y=this.baseQuad)&&(e.splice(0,0,this.baseQuad),t.cacheUpdate(0)),t.data(e)),t._update())},this._init=function(){var t;if(v.apply(C,arguments),null===C.renderer())for(t=0;t<=C._options.maxLevel;t+=1)C._getSubLayer(t);return C},this._exit=function(){return C.reset(),x.apply(C,arguments),g=!0,this._queue&&this._queue._tileLayers&&this._queue._tileLayers.indexOf(C)>=0&&(this._queue._tileLayers.splice(this._queue._tileLayers.indexOf(C),1),this._queue.initialTrack&&this._queue.track&&this._queue._tileLayers.length&&(this._queue.track=this._queue.initialTrack*this._queue._tileLayers.length)),C},h("tile",this),this};u.defaults={minLevel:0,maxLevel:18,tileOverlap:{x:0,y:0},tileWidth:256,tileHeight:256,wrapX:!0,wrapY:!1,url:null,subdomains:"abc",tileOffset:function(t){return{x:0,y:0}},tilesMaxBounds:null,topDown:!1,keepLower:!0,idleAfter:"view",tileRounding:Math.round,attribution:"",animationDuration:0},r(u,i),t.exports=u},77:function(t){var e=0,n=function(){"use strict";if(!(this instanceof n))return new n;var t=this,r=0;return this.modified=function(){return r=e+=1,t},this.timestamp=function(){return r},this.getMTime=this.timestamp,this};t.exports=n},338:function(t,e,n){var r=n(4626),i=n(1275),o=n(1098),a=n(642),s=function(t){"use strict";if(!(this instanceof s))return new s(t);var e=n(5325);t=t||{},i.call(this,t);var r,u,l,c,f,h=this,d={},p={startTime:void 0!==t.startTime?t.startTime:null,endTime:void 0!==t.endTime?t.endTime:null,duration:void 0!==t.duration?t.duration:null,start:0,end:0},m=this.draw,g=this._exit,y=this._init,v=this.modified,x=this.style,_=this._update;return this.featureType="track",this._linePosition=function(t){return function(e,n,r,i){var o=p.timeFunc(e,n,r,i);return"past"===t&&o>=p.start||"current"===t&&o<p.start?p.startPosition[i]:"current"===t&&o>p.end||"future"===t&&o<p.end?p.endPosition[i]:p.positionFunc(e,n,r,i)}},this._headPosition=function(t,e){return p.endPosition[e]},this._headText=function(t,e){return p.text[e]},this._updateTimeRange=function(){null!==p.endTime||null===p.endTime&&(null===p.startTime||null==p.duration)?(p.end=null!==p.endTime?p.endTime:p.timeExtents.end,null!==p.startTime&&(null===p.endTime||p.startTime<=p.endTime)?p.start=p.startTime:null!==p.duration?p.start=p.end-p.duration:p.start=p.timeExtents.start):(p.start=p.startTime,p.end=p.start+p.duration)},this.calculateTimePosition=function(t,n,r){h.dataTime().timestamp()>=h.buildTime().timestamp()&&h._build(),n=null===n?h.layer().map().gcs():void 0===n?h.gcs():n;var i=e({source:h.gcs(),target:n}),o=h.data(),a=[],s=o.map((function(e,n){var r=p.trackFunc(e,n);if(a.push(r),!r.length)return{x:0,y:0,z:0,posidx:-1};var i,o,s,u,l=0,c=r.length-1;if(1===r.length)return{posidx:l,angidx0:l,angidx1:l};if((i=p.timeFunc(r[l],l,e,n))>=t)return{posidx:l,angidx0:l,angidx1:l+1};if((o=p.timeFunc(r[c],c,e,n))<=t)return{posidx:c,angidx0:c-1,angidx1:c};for(;c-l>1;){if(s=Math.floor((c+l)/2),(u=p.timeFunc(r[s],s,e,n))===t)return{posidx:s,angidx0:s-1,angidx1:s+1};u<t?(i=u,l=s):(o=u,c=s)}var f=(t-i)/(o-i);return{posidx0:l,posidx1:c,factor0:1-f,factor1:f,angidx0:l,angidx1:c}}));return s.forEach((function(t,e){var n,o,s;t.posidx<0||(void 0===t.posidx1?n=p.positionFunc(a[e][t.posidx],t.posidx,a[e],e):(o=i.forward(p.positionFunc(a[e][t.posidx0],t.posidx0,a[e],e),!0),s=i.forward(p.positionFunc(a[e][t.posidx1],t.posidx1,a[e],e),!0),n=i.inverse({x:o.x*t.factor0+s.x*t.factor1,y:o.y*t.factor0+s.y*t.factor1,z:(o.z||0)*t.factor0+(s.z||0)*t.factor1},!0)),t.x=n.x,t.y=n.y,t.z=n.z||0,r&&(void 0===t.posidx1&&(o=i.forward(t.angidx0===t.posidx?n:p.positionFunc(a[e][t.angidx0],t.angidx0,a[e],e),!0),s=i.forward(t.angidx1===t.posidx?n:p.positionFunc(a[e][t.angidx1],t.angidx1,a[e],e),!0)),t.angle=Math.atan2(s.y-o.y,s.x-o.x)))})),s},this._build=function(){h.buildTime().modified(),r||(r={past:h.layer().createFeature("line"),future:h.layer().createFeature("line"),current:h.layer().createFeature("line")},h.dependentFeatures([r.past,r.current,r.future]));var t=h.data();p.data=t,p.timeFunc=h.style.get("time"),p.positionFunc=h.style.get("position"),p.trackFunc=h.style.get("track"),p.textFunc=h.style.get("text"),["past","current","future"].forEach((function(e){r[e].style(h.style()).style(h[e+"Style"]()).line(h.style("track")).gcs(h.gcs()).data(t).position(h._linePosition(e))}));var e,n,i={};if(t.forEach((function(t,e){var n,r=p.trackFunc(t,e);r.length&&(n=p.timeFunc(r[0],0,t,e),(void 0===i.start||n<i.start)&&(i.start=n),r.length>1&&(n=p.timeFunc(r[r.length-1],r.length-1,t,e)),(void 0===i.end||n>i.end)&&(i.end=n))})),p.timeExtents=i,h._updateTimeRange(),p.startPosition=h.calculateTimePosition(p.start,null),p.endPosition=h.calculateTimePosition(p.end,null,!0),p.text=t.map((function(t,r){var i=p.textFunc(t,r);return e|=null==i,null==i||""===i?"":(n=!0,p.startPosition[r].posidx<0&&(i=""),i)})),e&&!l){if(!(o.registries.features[h.layer().rendererName()]||{}).marker){var a=o.rendererForFeatures(["marker"]);u=o.createLayer("feature",h.layer().map(),{renderer:a}),h.layer().addChild(u),h.layer().node().append(u.node())}l=(u||h.layer()).createFeature("marker");var s=h.dependentFeatures();s.push(l),h.dependentFeatures(s)}if(n&&!f){if(!(o.registries.features[h.layer().rendererName()]||{}).text){var d=o.rendererForFeatures(["text"]);c=o.createLayer("feature",h.layer().map(),{renderer:d}),h.layer().addChild(c),h.layer().node().append(c.node())}f=(c||h.layer()).createFeature("text");var m=h.dependentFeatures();m.push(f),h.dependentFeatures(m)}if(l){l.headData=p.endPosition,l.style(h.markerStyle()).gcs(h.gcs()).data(t).position(h._headPosition);var g=l.style.get("radius");l.style("radius",(function(t,e){return p.text[e]||p.startPosition[e].posidx<0?0:g(t,e)}))}return f&&(f.headData=p.endPosition,f.style(h.textStyle()).gcs(h.gcs()).data(t).text(h._headText).position(h._headPosition)),h},this._updateTimeAndPosition=function(){r&&(h._updateTimeRange(),p.startPosition=h.calculateTimePosition(p.start,null),p.endPosition=h.calculateTimePosition(p.end,null,!0),r.past.modified(),r.current.modified(),r.future.modified(),l&&l.modified(),f&&f.modified(),h.updateTime().modified(),h.modified())},this._update=function(){return _.call(h),(h.dataTime().timestamp()>=h.buildTime().timestamp()||h.updateTime().timestamp()<=h.timestamp())&&h._build(),h.updateTime().modified(),h},this.draw=function(){var t=m();return r&&(r.past.draw(),r.current.draw(),r.future.draw()),l&&l.draw(),f&&f.draw(),t},this.modified=function(){var t=v();return r&&(r.past.modified(),r.current.modified(),r.future.modified()),l&&l.modified(),f&&f.modified(),t},this.style=function(t,e,n){return"style"===(n=n||"style")?x(t,e):void 0===t?d[n]:"string"==typeof t&&void 0===e?(d[n]||{})[t]:(void 0===d[n]&&(d[n]={}),void 0===e?d[n]=a.deepMerge(d[n],t):d[n][t]=e,h.modified(),h)},this.style.get=x.get,["markerStyle","textStyle","pastStyle","currentStyle","futureStyle"].forEach((function(t){h[t]=function(e,n){return h.style(e,n,t)}})),this.track=function(t){return void 0===t?h.style("track"):(h.style("track",t),h.dataTime().modified(),h.modified(),h)},this.position=function(t){return void 0===t?h.style("position"):(h.style("position",t),h.dataTime().modified(),h.modified(),h)},this.time=function(t){return void 0===t?h.style("time"):(h.style("time",t),h.dataTime().modified(),h.modified(),h)},this.timeRange=function(t){if(void 0===t)return{startTime:p.startTime,endTime:p.endTime,duration:p.duration,start:p.start,end:p.end,minimum:(p.timeExtents||{}).start,maximum:(p.timeExtents||{}).end};var e=!1;return void 0!==t.startTime&&t.startTime!==p.startTime&&(p.startTime=null===t.startTime?t.startTime:+t.startTime,e=!0),void 0!==t.endTime&&t.endTime!==p.endTime&&(p.endTime=null===t.endTime?t.endTime:+t.endTime,e=!0),void 0!==t.duration&&t.duration!==p.duration&&(p.duration=null===t.duration?t.duration:+t.duration,e=!0),e&&h._updateTimeAndPosition(),h},this.startTime=function(t){return void 0===t?p.startTime:(t!==p.startTime&&(p.startTime=null===t?t:+t,h._updateTimeAndPosition()),h)},this.endTime=function(t){return void 0===t?p.endTime:(t!==p.endTime&&(p.endTime=null===t?t:+t,h._updateTimeAndPosition()),h)},this.duration=function(t){return void 0===t?p.duration:(t!==p.duration&&(p.duration=null===t?t:+t,h._updateTimeAndPosition()),h)},this._mergeSearchResults=function(t,e){return t.extra=t.extra||{},e.forEach((function(e){return e.value.index.forEach((function(n,r){t.index.indexOf(n)<0&&(t.index.push(n),t.found.push(e.value.found[r]),t.where=t.where||{},e.value.extra&&e.value.extra[n]&&(t.extra[n]=e.value.extra[n]),a.isObject(t.extra[n])||(t.extra[n]={value:t.extra[n]}),t.extra[n].where=e.key)}))})),t},this.pointSearch=function(t){var e=r.current.pointSearch(t),n=r.past.pointSearch(t),i=r.future.pointSearch(t),o=l?l.pointSearch(t):{index:[]};return this._mergeSearchResults(e,[{key:"marker",value:o},{key:"past",value:n},{key:"future",value:i}])},this.polygonSearch=function(t,e){var n=r.current.polygonSearch(t,e),i=r.past.polygonSearch(t,e),o=r.future.polygonSearch(t,e),a=l?l.polygonSearch(t,e):{index:[]};return this._mergeSearchResults(n,[{key:"marker",value:a},{key:"past",value:i},{key:"future",value:o}])},this._exit=function(){r&&h.layer()&&(h.layer().deleteFeature(r.past),h.layer().deleteFeature(r.current),h.layer().deleteFeature(r.future)),r=null,(u||h.layer())&&l&&(u||h.layer()).deleteFeature(l),u&&h.layer()&&h.layer().removeChild(u),u=null,(c||h.layer())&&f&&(c||h.layer()).deleteFeature(f),c&&h.layer()&&h.layer().removeChild(c),c=null,h.dependentFeatures([]),g()},this._init=function(t){t=t||{},y.call(h,t);var e=a.deepMerge({},{track:a.identityFunction,position:a.identityFunction,time:function(t,e){return void 0!==t.t?t.t:e},uniformLine:"drop",closed:!1},void 0===t.style?{}:t.style),n=a.deepMerge({},{rotateWithMap:!0,rotation:function(t,e){return-p.endPosition[e].angle||0}},void 0===t.markerStyle?{}:t.markerStyle),r=a.deepMerge({},{rotateWithMap:!0,rotation:function(t,e){return void 0!==p.endPosition[e].angle?-p.endPosition[e].angle+Math.PI/2:0}},void 0===t.textStyle?{}:t.textStyle),i=a.deepMerge({},{strokeOpacity:.25},void 0===t.pastStyle?{}:t.pastStyle),o=a.deepMerge({},{},void 0===t.currentStyle?{}:t.currentStyle),s=a.deepMerge({},{strokeOpacity:.25},void 0===t.futureStyle?{}:t.futureStyle);["track","position","time"].forEach((function(n){void 0!==t[n]&&(e[n]=t[n])})),h.style(e),h.markerStyle(n),h.textStyle(r),h.pastStyle(i),h.currentStyle(o),h.futureStyle(s)},this};r(s,i),t.exports=s},5325:function(t,e,n){var r=n(1960),i=n(1982),o=n(3503),a=n(642);r=r.__esModule?r.default:r;var s=n(9689);s.keys().forEach((function(t){r.Proj.projections.add(s(t))}));var u={},l=/^(.* |)\+axis=e(n|s)u(| .*)$/,c=/(^|\s)\+(s[1-3][1-3]|[xyz]off)=\S/,f=function(t){"use strict";if(!(this instanceof f))return(t=t||{}).source in u||(Object.keys(u).length>=10&&(u={}),u[t.source]={}),t.target in u[t.source]||(Object.keys(u[t.source]).length>=10&&(u[t.source]={}),u[t.source][t.target]=new f(t)),u[t.source][t.target];var e,n,s,l,h,d,p,m=this,g={s11:0,s12:4,s13:8,xoff:12,s21:1,s22:5,s23:9,yoff:13,s31:2,s32:6,s33:10,zoff:14};function y(t){if(!c.exec(t))return{proj:t};var e,n,r=a.mat4AsArray(),i=[];return t.split(/(\s+)/).forEach((function(t){var e=/^\+(s[1-3][1-3]|[xyz]off)=(.*)$/.exec(t);e?r[g[e[1]]]=parseFloat(e[2]):i.push(t)})),n={proj:i.join(" "),orig:t},(e=o.invert(a.mat4AsArray(),r))?(n.matrix=r,n.inverse=e):console.warn("Affine transform is not invertable and will not be used: "+t),n}function v(){var t=y(m.source()),n=y(m.target()),i=t.proj,o=n.proj;l=t.matrix,h=t.inverse,d=n.matrix,p=n.inverse,e=new r(i,o)}this.source=function(t){return void 0===t?n||"EPSG:4326":(n=t,v(),m)},this.target=function(t){return void 0===t?s||"EPSG:3857":(s=t,v(),m)},this._forward=function(t){if(l){var n=i.transformMat4(a.vec3AsArray(),[t.x,t.y,t.z||0],h);t={x:n[0],y:n[1],z:n[2]}}var r=e.forward(t,!0);if(r.z=t.z||0,d){var o=i.transformMat4(a.vec3AsArray(),[r.x,r.y,r.z],d);r={x:o[0],y:o[1],z:o[2]}}return r},this._inverse=function(t){if(d){var n=i.transformMat4(a.vec3AsArray(),[t.x,t.y,t.z||0],p);t={x:n[0],y:n[1],z:n[2]}}var r=e.inverse(t,!0);if(r.z=t.z||0,l){var o=i.transformMat4(a.vec3AsArray(),[r.x,r.y,r.z],l);r={x:o[0],y:o[1],z:o[2]}}return r},this.forward=function(t){return Array.isArray(t)?t.map(m._forward):m._forward(t)},this.inverse=function(t){return Array.isArray(t)?t.map(m._inverse):m._inverse(t)},t=t||{};try{this.source(t.source)}catch(e){console.error("Can't use transform source: "+t.source),this.source("EPSG:4326")}try{this.target(t.target)}catch(e){console.error("Can't use transform target: "+t.target),this.target("EPSG:3857")}return this};f.defs=r.defs,f.lookup=function(t){var e,i,o=n(5616),a=o.Deferred();return r.defs.hasOwnProperty(t)?a.resolve(r.defs[t]):2!==(i=t.split(":")).length||"EPSG"!==i[0].toUpperCase()?a.reject("Invalid projection code").promise():(e=i[1],o.ajax({url:"https://epsg.io/"+encodeURIComponent(e)+".proj4"}).done((function(e){var n=(e.results||[])[0];return n?(r.defs(t,n),o.when(r.defs[t])):a.reject(e).promise()})))},f.transformCoordinates=function(t,e,n,r){"use strict";if(t===e||Array.isArray(n)&&!n.length)return n;if(Array.isArray(n)&&n.length>=3&&3===r&&!a.isObject(n[0])&&!c.test(t)&&!c.test(e))return f.transformCoordinatesFlatArray3(t,e,n);if(Array.isArray(n)&&n.length&&a.isObject(n[0])&&"x"in n[0]&&"y"in n[0]){var i=t.match(l),o=e.match(l);if(i&&o&&i[1]===o[1]&&i[3]===o[3])return"z"in n[0]?n.map((function(t){return{x:+t.x,y:-t.y,z:+t.z||0}})):n.map((function(t){return{x:+t.x,y:-t.y}}))}var s,u=f({source:t,target:e});return a.isObject(n)&&"x"in n&&"y"in n?(s=u.forward({x:+n.x,y:+n.y,z:+n.z||0},!0),"z"in n?s:{x:s.x,y:s.y}):Array.isArray(n)&&1===n.length&&a.isObject(n[0])&&"x"in n[0]&&"y"in n[0]?(s=u.forward({x:+n[0].x,y:+n[0].y,z:+n[0].z||0},!0),"z"in n[0]?[s]:[{x:s.x,y:s.y}]):f.transformCoordinatesArray(u,n,r)},f.transformCoordinatesArray=function(t,e,n){var r,i,o,s,u,l,c,f,h,d={};function p(){if(Array.isArray(e[0]))if(2===e[0].length)s=function(t){return+e[t][0]},u=function(t){return+e[t][1]},c=function(t,e,n){f[t]=[e,n]};else{if(3!==e[0].length)throw new Error("Invalid coordinates. Requires two or three components per array");s=function(t){return+e[t][0]},u=function(t){return+e[t][1]},l=function(t){return+e[t][2]},c=function(t,e,n,r){f[t]=[e,n,r]}}else if(2===e.length)o=2,s=function(t){return+e[t*o]},u=function(t){return+e[t*o+1]},c=function(t,e,n){f[t]=e,f[t+1]=n};else if(3===e.length)o=3,s=function(t){return+e[t*o]},u=function(t){return+e[t*o+1]},l=function(t){return+e[t*o+2]},c=function(t,e,n,r){f[t]=e,f[t+1]=n,f[t+2]=r};else{if(!n)throw new Error("Invalid coordinates");if(2!==n&&3!==n)throw new Error("Number of components should be two or three");o=n,s=function(t){return+e[t]},u=function(t){return+e[t+1]},2===n?c=function(t,e,n){f[t]=e,f[t+1]=n}:(l=function(t){return+e[t+2]},c=function(t,e,n,r){f[t]=e,f[t+1]=n,f[t+2]=r})}}if(l=function(){return 0},!Array.isArray(e))throw new Error("Coordinates are not valid");if((f=[]).length=e.length,i=e.length,!e.length)return f;for(Array.isArray(e[0])||a.isObject(e[0])?(o=1,Array.isArray(e[0])?p():a.isObject(e[0])&&function(){if(!(e[0]&&"x"in e[0]&&"y"in e[0]))throw new Error("Invalid coordinates");s=function(t){return+e[t].x},u=function(t){return+e[t].y},"z"in e[0]?(l=function(t){return+e[t].z},c=function(t,e,n,i){f[r]={x:e,y:n,z:i}}):c=function(t,e,n){f[t]={x:e,y:n}}}()):p(),r=0;r<i;r+=o)d.x=s(r),d.y=u(r),d.z=l(r),h=t.forward(d,!0),c(r,h.x,h.y,h.z);return f},f.transformCoordinatesFlatArray3=function(t,e,n){"use strict";var i,o=t.match(l),a=e.match(l);if(o&&a&&o[1]===a[1]&&o[3]===a[3]){for(i=n.length-3+1;i>=0;i-=3)n[i]*=-1;return n}var s,u=r.Proj(t),c=r.Proj(e),f={},h=new r(u,c);for(i=n.length-3;i>=0;i-=3)f.x=+n[i],f.y=+n[i+1],f.z=+(n[i+2]||0),s=h.forward(f,!0),n[i]=s.x,n[i+1]=s.y,n[i+2]=void 0===s.z?f.z:s.z;return n},f.affineForward=function(t,e){"use strict";var n,r=t.origin,i=t.scale||{x:1,y:1,z:1};for(n=0;n<e.length;n+=1)e[n].x=(e[n].x-r.x)*i.x,e[n].y=(e[n].y-r.y)*i.y,e[n].z=((e[n].z||0)-(r.z||0))*i.z;return e},f.affineInverse=function(t,e){"use strict";var n,r=t.origin,i=t.scale||{x:1,y:1,z:1};for(n=0;n<e.length;n+=1)e[n].x=e[n].x/i.x+r.x,e[n].y=e[n].y/i.y+r.y,e[n].z=(e[n].z||0)/i.z+(r.z||0);return e},f.sphericalDistance=function(t,e,n,i,o){if(i=i||"EPSG:4326",o=o||r.WGS84,(n=n||i)!==i){var a=f.transformCoordinates(n,i,[t,e]);t=a[0],e=a[1]}var s=t.y*Math.PI/180,u=e.y*Math.PI/180,l=(e.x-t.x)*Math.PI/180,c=Math.sin(s),h=Math.cos(s),d=Math.sin(u),p=Math.cos(u),m=Math.atan2(Math.pow(Math.pow(p*Math.sin(l),2)+Math.pow(h*d-c*p*Math.cos(l),2),.5),c*d+h*p*Math.cos(l));return o.a*m},f.vincentyDistance=function(t,e,n,i,o,a){if(i=i||"EPSG:4326",o=o||r.WGS84,a=a||100,(n=n||i)!==i){var s=f.transformCoordinates(n,i,[t,e]);t=s[0],e=s[1]}var u,l,c,h,d,p,m,g,y,v,x=o.a,_=o.b||o.a*(1-(o.f||1/o.rf)),b=o.f||(o.rf?1/o.rf:1-_/x),w=t.y*Math.PI/180,M=e.y*Math.PI/180,A=((e.x-t.x)%360+360)%360*Math.PI/180,T=Math.atan((1-b)*Math.tan(w)),E=Math.atan((1-b)*Math.tan(M)),C=Math.sin(T),k=Math.cos(T),S=Math.sin(E),O=Math.cos(E),P=A,L=A+2*Math.PI;if(w===M&&!A)return{distance:0,alpha1:0,alpha2:0};for(v=a;v>0&&Math.abs(P-L)>1e-12;v-=1)u=Math.pow(Math.pow(O*Math.sin(P),2)+Math.pow(k*S-C*O*Math.cos(P),2),.5),l=C*S+k*O*Math.cos(P),c=Math.atan2(u,l),h=k*O*Math.sin(P)/u,L=P,P=A+(1-(m=b/16*(d=1-Math.pow(h,2))*(4+b*(4-3*d))))*b*h*(c+m*u*((p=l-(d?2*C*S/d:0))+m*l*(2*Math.pow(p,2)-1)));return v?{distance:_*(1+(g=d*(x*x-_*_)/(_*_))/16384*(4096+g*(g*(320-175*g)-768)))*(c-(y=g/1024*(256+g*(g*(74-47*g)-128)))*u*(p+y/4*(l*(2*Math.pow(p,2)-1)-y/6*p*(4*u*u-3)*(4*Math.pow(p,2)-3)))),alpha1:Math.atan2(O*Math.sin(P),k*S-C*O*Math.cos(P)),alpha2:Math.atan2(k*Math.sin(P),-C*O+k*S*Math.cos(P))}:void 0},f.onlyInvertedY=function(t,e){var n=t.match(l),r=e.match(l);return n&&r&&n[1]===r[1]&&n[3]===r[3]},f.proj4=r,t.exports=f},3170:function(t){t.exports={}},5734:function(t,e,n){var r=n(2493).d3,i=n(8524),o=n(4626),a=n(1098).registerWidget,s=n(642),u=n(7376);n(1159);var l=function(t){"use strict";if(!(this instanceof l))return new l(t);i.call(this,t);var e=this,n=[],o=t.width||300,a=t.ticks||6,f=this._init;return this._init=function(){f();var n=e.canvas();r.select(n).attr("class","color-legend-container"),e.popup=r.select(n).append("div").attr("class","color-legend-popup"),t.categories&&e.categories(t.categories)},this._draw=function(){if(r.select(e.canvas()).selectAll("div.geojs-color-legends").remove(),n.length){r.select(e.canvas()).style("display","block");var t=r.select(e.canvas()).append("div").attr("class","geojs-color-legends"),i=o;n.forEach((function(n,r){var o=t.append("div").attr("class","geojs-color-legend");o.append("div").attr("class","geojs-title").text(n.name);var a=o.append("svg").attr("class","svg").attr("width",i).attr("height","40px").attr("viewBox","-20 0 "+i+" 40");"discrete"===n.type?e._drawDiscrete(a,i-40,n):"continuous"===n.type&&e._drawContinous(a,i-40,n)}))}else r.select(e.canvas()).style("display","none")},this.categories=function(t){return void 0===t?n:(n=e._prepareCategories(t),e._draw(),e)},this.addCategories=function(t){return n=n.concat(e._prepareCategories(t)),e._draw(),e},this.removeCategories=function(t){return n=n.filter((function(e){return-1===t.indexOf(e)})),e._draw(),e},this._prepareCategories=function(t){return t.forEach((function(t){t.color=t.colors.map((function(t){return s.convertColorToHex(t,!0)}))})),t},this._drawDiscrete=function(t,n,i){function o(t){var e=Math.ceil(t.domain().length/a),n=t.domain().filter((function(t,n){return n%e==0}));return r.axisBottom(t).tickFormat(r.format(".2s")).tickValues(n)}if(-1===["linear","log","sqrt","pow","quantile","ordinal"].indexOf(i.scale))throw new Error("unsupported scale");var u,l,f,h,d,p,m;if("ordinal"===i.scale){f=r.scaleOrdinal().domain(i.domain).range(i.colors),e._renderDiscreteColors(t,i.domain,f,n,(function(t){return t})),h=r.scaleBand().domain(i.domain).rangeRound([0,n]);var g=Math.ceil(i.domain.length/a),y=i.domain.filter((function(t,e){return e%g==0}));d=r.axisBottom(h).tickValues(y)}else if("quantile"===i.scale){u=[0,i.colors.length],p=s.range(0,i.colors.length-1),l=r.scaleQuantile().domain(i.domain).range(p),f=r.scaleQuantize().domain(u).range(i.colors),e._renderDiscreteColors(t,p,f,n,(function(t){return l.invertExtent(t).join(" - ")}));var v=[l.invertExtent(0)[0]];v=v.concat(p.map((function(t){return l.invertExtent(t)[1]}))),d=o(h=r.scalePoint().domain(v).range([0,n]))}else if(-1!==["linear","log","sqrt","pow"].indexOf(i.scale)){u=[0,i.colors.length],l=r["scale"+i.scale.charAt(0).toUpperCase()+i.scale.slice(1)]().domain(i.domain).range(u).nice(),f=r.scaleQuantize().domain(u).range(i.colors),p=s.range(0,i.colors.length-1);var x=Math.max.apply(null,i.domain.map((function(t){return c(t)})));e._renderDiscreteColors(t,p,f,n,(function(t){return e._popupFormatter(l.invert(t),x)+" - "+e._popupFormatter(l.invert(t+1),x)})),(m=p.slice()).push(i.colors.length),d=o(h=r.scalePoint().domain(m.map((function(t){return l.invert(t)}))).range([0,n]))}i.endAxisLabelOnly&&d.tickValues([h.domain()[0],h.domain()[h.domain().length-1]]),e._renderAxis(t,d)},this._renderDiscreteColors=function(t,n,r,i,o){t.selectAll("rect").data(n).enter().append("rect").attr("width",i/n.length).attr("height","20px").attr("fill",(function(t){return r(t)})).attr("transform",(function(t,e){return"translate("+e*i/n.length+" ,0)"})).on("mousemove",(function(t,n){e._showPopup(t,o(n))})).on("mouseout",e._hidePopup)},this._drawContinous=function(t,n,i){var o,s,l;if(-1===["linear","log","sqrt","pow"].indexOf(i.scale))throw new Error("unsupported scale");var f=[0];for(l=1;l<i.domain.length-1;l++)f.push(n/(i.domain.length-1)*l);f.push(n),o=r["scale"+i.scale.charAt(0).toUpperCase()+i.scale.slice(1)]().domain(i.domain).range(f).nice(),"log"===i.scale&&i.base&&o.base(i.base),"pow"===i.scale&&i.exponent&&o.exponent(i.exponent);var h=u(),d=Math.max.apply(null,i.domain.map((function(t){return c(t)}))),p=t.append("defs").append("linearGradient").attr("id","gradient"+h);for(p.append("stop").attr("offset","0%").attr("stop-color",i.colors[0]),l=1;l<i.colors.length-1;l++)p.append("stop").attr("offset",(100/(i.colors.length-1)*l).toFixed(6)+"%").attr("stop-color",i.colors[l]);p.append("stop").attr("offset","100%").attr("stop-color",i.colors[i.colors.length-1]),t.append("rect").attr("fill","url(#gradient"+h+")").attr("width",n).attr("height","20px").on("mousemove",(function(t){var n=o.invert(r.pointer(t)[0]),i=e._popupFormatter(n,d);e._showPopup(t,i)})).on("mouseout",e._hidePopup),s=r.axisBottom(o).ticks(a,".2s"),i.endAxisLabelOnly&&s.tickValues([i.domain[0],i.domain[i.domain.length-1]]),e._renderAxis(t,s)},this._renderAxis=function(t,e){t.append("g").attr("class","axis x").attr("transform","translate(0, 20)").call(e)},this._popupFormatter=function(t,e){return t=parseFloat(t.toFixed(8)),e=Math.min(e,c(t)),e=Math.min(e,Math.max(3,7-Math.trunc(t).toString().length)),r.format("."+e+"f")(t)},this._showPopup=function(t,n){var i=r.pointer(t,e.canvas());e.popup.text(n);var o=e.canvas().clientWidth,a=e.popup.node().clientWidth;e.popup.style("left",i[0]-(i[0]+a-o>-10?a:0)+"px").style("top",i[1]-22+"px").transition().duration(200).style("opacity",1)},this._hidePopup=function(){e.popup.transition().duration(200).style("opacity",0)},this};function c(t){if(!isFinite(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;){if(!isFinite(t*e))return 0;e*=10,n++}return n}o(l,i),a("dom","colorLegend",l),t.exports=l},8524:function(t,e,n){var r=n(8738),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=this;return this._init=function(){return t.hasOwnProperty("parent")&&t.parent.addChild(e),e._createCanvas(),e._appendCanvasToParent(),e.canvas().addEventListener("mousedown",(function(t){t.stopPropagation()})),e.reposition(),e},this._createCanvas=function(){e.canvas(document.createElement(t.el||"div"))},this};i(a,r),o("dom","dom",a),t.exports=a},4812:function(t,e,n){t.exports={colorLegendWidget:n(5734),domWidget:n(8524),legendWidget:n(9443),scaleWidget:n(2894),sliderWidget:n(3019),svgWidget:n(7854),uiLayer:n(4231),widget:n(8738)}},9443:function(t,e,n){var r=n(7854),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=n(2493).d3,i=n(6409),o=this,s=[],u=null,l=null,c=null;this.categories=function(t){return void 0===t?s.slice():(s=t.slice().map((function(t){return"line"===t.type&&(t.style.fill=!1,t.style.stroke=!0),t})),o.draw(),o)},this.size=function(){var t,n=1,r=e.select(o.canvas()).append("text").style("opacity",1e-6);return s.forEach((function(t){r.text(t.name),n=Math.max(n,r.node().getBBox().width)})),r.remove(),t=20*(s.length+1),{width:n+50,height:t}},this.draw=function(){function t(t){t.style("fill",(function(t){return t.style.fill||void 0===t.style.fill?t.style.fillColor:"none"})).style("fill-opacity",(function(t){return void 0===t.style.fillOpacity?1:t.style.fillOpacity})).style("stroke",(function(t){return t.style.stroke||void 0===t.style.stroke?t.style.strokeColor:"none"})).style("stroke-opacity",(function(t){return void 0===t.style.strokeOpacity?1:t.style.strokeOpacity})).style("stroke-width",(function(t){return void 0===t.style.strokeWidth?1.5:t.style.strokeWidth}))}o._init(),c.attr("height",o.size().height+24).style("display",null);var e=o._scale(),n=l.selectAll("g.geo-label").data(s,(function(t){return t.name})).enter().append("g").attr("class","geo-label").attr("transform",(function(t,n){return"translate(0,"+e.y(n)+")"}));return t(n.filter((function(t){return"point"!==t.type&&"line"!==t.type})).append("rect").attr("x",0).attr("y",-6).attr("rx",5).attr("ry",5).attr("width",40).attr("height",12)),t(n.filter((function(t){return"point"===t.type})).append("circle").attr("cx",20).attr("cy",0).attr("r",6)),t(n.filter((function(t){return"line"===t.type})).append("line").attr("x1",0).attr("y1",0).attr("x2",40).attr("y2",0)),n.append("text").attr("x","50px").attr("y",0).attr("dy","0.3em").text((function(t){return t.name})),o.reposition(),o},this._scale=function(){return{x:e.scaleLinear().domain([0,1]).range([0,o.size().width]),y:e.scaleLinear().domain([0,s.length-1]).range([6,o.size().height-6])}},this._init=function(){u||(o._createCanvas(),o._appendCanvasToParent());var t=o.size().width+24+4,n=o.size().height+24+4;u&&u.remove(),e.select(o.canvas()).attr("width",t).attr("height",n),u=e.select(o.canvas()).append("g"),l=u.append("g").attr("transform","translate("+[14,14]+")"),(c=l.append("rect").attr("x",-12).attr("y",-12).attr("width",t-4).attr("height",n-4).attr("rx",3).attr("ry",3)).style("stroke","black").style("stroke-width","1.5px").style("fill","white").style("fill-opacity",.75).style("display","none"),l.on("mousedown",(function(t){t.stopPropagation()})),l.on("mouseover",(function(){c.transition().duration(250).style("fill-opacity",1)})),l.on("mouseout",(function(){c.transition().duration(250).style("fill-opacity",.75)})),o.reposition()},this.geoOn(i.resize,(function(){o.draw()}))};i(a,r),o("dom","legend",a),t.exports=a},2894:function(t,e,n){var r=n(5616),i=n(4626),o=n(7854),a=n(1098).registerWidget;n(615);var s=function(t){"use strict";if(!(this instanceof s))return new s(t);o.call(this,t);var e=n(6409),i=n(5325),a=n(642),u=n(2493).d3,l=this,c=this._exit,f=Object.assign({},{scale:1,maxWidth:200,maxHeight:"left"===t.orientation||"right"===t.orientation?200:20,orientation:"bottom",strokeWidth:2,tickLength:10,units:"si",distance:function(t,e,n){return"+proj=longlat +axis=enu"===n?Math.sqrt(a.distance2dSquared(t,e)):i.sphericalDistance(t,e,n)}},t);this._init=function(){return l._createCanvas(),l._appendCanvasToParent(),l.reposition(),u.select(l.canvas()).attr("width",f.maxWidth).attr("height",f.maxHeight),l.geoOn(e.pan,l._update),l._render(),l},this._exit=function(){l.geoOff(e.pan,l._update),c()},this._vertical=function(){return"left"===f.orientation||"right"===f.orientation},this._scaleValue=function(t,e,n){var r,i,o,a=[{multiple:1,digits:1},{multiple:1.5,digits:2},{multiple:2,digits:1},{multiple:3,digits:1},{multiple:5,digits:1},{multiple:8,digits:1}],u=(n=s.unitsTable[n]||n||s.unitsTable[f.units]||f.units)[0];return n.forEach((function(e){t>=e.scale*(e.minimum||1)&&(u=e)})),i=Math.floor(Math.log(t/u.scale)/Math.log(u.basis||10)),(a=u.multiples||a).forEach((function(e){var n=u.scale*e.multiple*Math.pow(10,i);n<=t&&(r=e,o=n)})),{html:(r.multiple*Math.pow(10,i)).toFixed(Math.max(0,-i+r.digits-1))+" "+u.unit,value:o,pixels:o/t*e,power:i,multiple:r,unitRecord:u,originalValue:t,originalPixels:e}},this._render=function(){var t,e,n,i,o,a,s=u.select(l.canvas()),c=l.layer().map(),h=f.maxWidth,d=f.maxHeight,p=f.strokeWidth,m=.5*p,g=f.tickLength,y=l._vertical();if(t=(y?f.maxHeight:f.maxWidth)-p,n={x:(e={x:(e=r(s.node()).offset()).left+("left"===f.orientation?h-m:m),y:e.top+("top"===f.orientation?d-m:m)}).x+(y?0:t),y:e.y+(y?t:0)},(i=f.distance(c.displayToGcs(e,null),c.displayToGcs(n,null),c.gcs())*f.scale)<=0||!isFinite(i))console.warn("The distance calculated for the scale is invalid: "+i);else{switch(o=l._scaleValue(i,t),y?d=o.pixels+p:h=o.pixels+p,s.attr("width",h).attr("height",d),s.select("polyline").empty()&&s.append("polyline").classed("geojs-scale-widget-bar",!0).attr("fill","none").attr("stroke-width",p),s.select("text").empty()&&s.append("text").classed("geojs-scale-widget-text",!0),f.orientation){case"bottom":a=[[m,g],[m,m],[h-m,m],[h-m,g]],s.select("text").attr("x",h/2).attr("y",2*p).attr("text-anchor","middle").attr("dominant-baseline","hanging");break;case"top":a=[[m,d-g],[m,d-m],[h-m,d-m],[h-m,d-g]],s.select("text").attr("x",h/2).attr("y",d-2*p).attr("text-anchor","middle").attr("dominant-baseline","alphabetic");break;case"left":a=[[h-g,m],[h-m,m],[h-m,d-m],[h-g,d-m]],s.select("text").attr("x",h-2*p).attr("y",d/2).attr("text-anchor","end").attr("dominant-baseline","middle");break;case"right":a=[[g,m],[m,m],[m,d-m],[g,d-m]],s.select("text").attr("x",2*p).attr("y",d/2).attr("text-anchor","start").attr("dominant-baseline","middle")}s.select("polyline").attr("points",a.map((function(t){return t.join(",")})).join(" ")),s.select("text").html(o.html)}},this._update=function(){l._render()},this.options=function(t,e){if(void 0===t){var n=Object.assign({},f);return n.position=l.position(void 0,!0),n}return"string"==typeof t&&void 0===e?"position"===t?l.position(void 0,!0):f[t]:(void 0===e?f=a.deepMerge(f,t):f[t]=e,(t.position||"position"===t)&&l.position(t.position||e),l._render(),l)}};i(s,o),s.unitsTable={si:[{unit:"nm",scale:1e-9},{unit:"μm",scale:1e-6},{unit:"mm",scale:.001},{unit:"m",scale:1},{unit:"km",scale:1e3}],miles:[{unit:"in",scale:.0254},{unit:"in",scale:.0254,basis:12,multiples:[{multiple:1,digits:1},{multiple:1.5,digits:2},{multiple:2,digits:1},{multiple:3,digits:1},{multiple:6,digits:1},{multiple:9,digits:1}]},{unit:"ft",scale:.3048},{unit:"mi",scale:1609.344}],decmiles:[{unit:"mi",scale:1609.344}]},s.areaUnitsTable={si:[{unit:"nm²",scale:1e-18},{unit:"μm²",scale:1e-12},{unit:"mm²",scale:1e-6},{unit:"m²",scale:1},{unit:"km²",scale:1e6}],hectares:[{unit:"ha",scale:1e4}],decmiles:[{unit:"mi²",scale:2589988.110336}],miles:[{unit:"in²",scale:64516e-8},{unit:"ft²",scale:.09290304},{unit:"mi²",scale:2589988.110336}],acres:[{unit:"pl",scale:25.29285264},{unit:"rd",scale:1011.7141056},{unit:"ac",scale:4046.8564224}]},s.formatUnit=function(t,e,n,r){if(null!=t){if(!Array.isArray(e)){if(!(n=n||s.unitsTable)||!n[e||"si"])return;e=n[e||"si"]}var i;for(i=0;i<e.length-1&&!(t<e[i+1].scale);i+=1);if(t/=(e=e[i]).scale,!((r=Math.max(0,-Math.ceil(Math.log10(t))+(void 0===r||r<0?3:r)))>10)){var o=t.toFixed(r);if(r){for(;"0"===o.substr(o.length-1);)o=o.substr(0,o.length-1);"."===o.substr(o.length-1)&&(o=o.substr(0,o.length-1))}return o+" "+e.unit}}},a("dom","scale",s),t.exports=s},3019:function(t,e,n){var r=n(7854),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e,i,o,s,u,l,c,f=n(2493).d3,h=n(6409),d=this,p=this._exit,m=t.width||20,g=t.height||160,y=t.width?.5*t.width:10;function v(t,e,n,r,i){var o=e.append("g"),a=i/1024;return o.append("g").append("g").attr("transform","translate("+n+","+r+") scale("+a+") translate(-512,-512)").append("path").attr("d",t).attr("class","geo-glyphicon"),o}c={white:"#f4f4f4",black:"#505050"},this.size=function(){return{width:m,height:g}},this._init=function(){d._createCanvas(),d._appendCanvasToParent(),d.reposition();var t=f.select(d.canvas()),n=d.layer().map();function r(e,r){var o=i.invert(f.pointer(event,t.node())[1]),a=n.zoomRange();o=(1-o)*(a.max-a.min)+a.min,r?n.transition({zoom:o,ease:f.easeCubicInOut,duration:500,done:d._update()}):(n.zoom(o),d._update()),e.stopPropagation()}function a(){f.select(this).attr("filter",null),l.selectAll("circle,rect,path").transition().duration(100).style("fill",(function(t){return c[t.fill]||null})).style("stroke",(function(t){return c[t.stroke]||null}))}return t.attr("width",m).attr("height",g),e=f.scaleLinear().domain([-4,4]).range([0,m]),i=f.scaleLinear().domain([0,1]).range([1.5*m,g-1.5*m]),t=t.append("g").classed("geo-ui-slider",!0),l=t,(o=t.append("g")).append("circle").datum({fill:"white",stroke:null}).classed("geo-zoom-in",!0).attr("cx",e(0)).attr("cy",i(0)-m+2).attr("r",(m-2)/2).style("cursor","pointer").on("click",(function(){var t=n.zoom();n.transition({zoom:t+1,ease:f.easeCubicInOut,duration:500})})).on("mousedown",(function(t){t.stopPropagation()})),v("M512 81.92c-237.568 0-430.080 192.614-430.080 430.080 0 237.568 192.563 430.080 430.080 430.080s430.080-192.563 430.080-430.080c0-237.517-192.563-430.080-430.080-430.080zM564.326 564.326v206.182h-104.653v-206.182h-206.234v-104.653h206.182v-206.234h104.704v206.182h206.182v104.704h-206.182z",o,e(0),i(0)-m+2,m+4).style("cursor","pointer").style("pointer-events","none").select("path").datum({fill:"black",stroke:null}),(s=t.append("g")).append("circle").datum({fill:"white",stroke:null}).classed("geo-zoom-out",!0).attr("cx",e(0)).attr("cy",i(1)+m-2).attr("r",(m-2)/2).style("cursor","pointer").on("click",(function(){var t=n.zoom();n.transition({zoom:t-1,ease:f.easeCubicInOut,duration:500})})).on("mousedown",(function(t){t.stopPropagation()})),v("M512 81.92c-237.568 0-430.080 192.614-430.080 430.080 0 237.568 192.563 430.080 430.080 430.080s430.080-192.563 430.080-430.080c0-237.517-192.563-430.080-430.080-430.080zM770.56 459.674v104.704h-517.12v-104.704h517.12z",s,e(0),i(1)+m-2,m+4).style("cursor","pointer").style("pointer-events","none").select("path").datum({fill:"black",stroke:null}),t.append("rect").datum({fill:"white",stroke:"black"}).classed("geo-zoom-track",!0).attr("x",e(0)-m/6).attr("y",i(0)).attr("rx",m/10).attr("ry",m/10).attr("width",m/3).attr("height",g-3*m).style("cursor","pointer").on("click",(function(t){r(t,!0)})),u=t.append("rect").datum({fill:"black",stroke:null}).classed("geo-zoom-nub",!0).attr("x",e(-4)).attr("y",i(.5)-y/2).attr("rx",3).attr("ry",3).attr("width",m).attr("height",y).style("cursor","pointer").on("mousedown",(function(t){f.select(document).on("mousemove.geo.slider",(function(){r(t)})),f.select(document).on("mouseup.geo.slider",(function(){r(t),f.select(document).on(".geo.slider",null)})),t.stopPropagation()})),l.selectAll("*").on("mouseover",(function(){f.select(this).attr("filter","url(#geo-highlight)"),l.selectAll("rect,path,circle").transition().duration(100).style("fill",(function(t){return t.fill||null})).style("stroke",(function(t){return t.stroke||null}))})).on("mouseout",a),d.geoOn(h.zoom,d._update),a(),d._update(),d},this._exit=function(){d.geoOff(h.zoom,d._update),l.remove(),p()},this._update=function(t){var e=d.layer().map(),n=e.zoomRange(),r=e.zoom(),o=f.scaleLinear();r=(t=t||{}).value||r,o.domain([n.min,n.max]).range([1,0]).clamp(!0),u.attr("y",i(o(r))-y/2)}};i(a,r),o("dom","slider",a),t.exports=a},7854:function(t,e,n){var r=n(8738),i=n(4626),o=n(1098).registerWidget,a=function(t){"use strict";if(!(this instanceof a))return new a(t);r.call(this,t);var e=n(2493),i=this,o=this._exit,s=null;return this._init=function(){var e;return t.hasOwnProperty("parent")&&(t.parent.addChild(i),e=t.parent.canvas()),i._createCanvas(e),i.canvas().addEventListener("mousedown",(function(t){t.stopPropagation()})),i.reposition(),i},this._exit=function(){s&&s._exit(),o()},this._createCanvas=function(t){var n={layer:i.layer(),widget:!0};t&&(n.d3Parent=t),(s=e(n))._resize=function(){},i.canvas(s.canvas().node())},this};i(a,r),o("dom","svg",a),t.exports=a},4231:function(t,e,n){var r=n(4626),i=n(1098).registerLayer,o=n(5156),a=function(t){"use strict";var e=n(1098).createWidget;if(t.renderer="dom",t.sticky=!1,!(this instanceof a))return new a(t);o.call(this,t);var r=this,i=this._exit;this.createWidget=function(t,n){var i=e(t,r,n);return n&&"parent"in n||r.addChild(i),i._init(n),r.modified(),i},this.deleteWidget=function(t){return t._exit(),r.removeChild(t),r.modified(),r},this._exit=function(){r.children().forEach((function(t){r.deleteWidget(t)})),i()}};r(a,o),i("ui",a),t.exports=a},8738:function(t,e,n){var r=n(4626),i=n(5402),o=function(t){"use strict";if(!(this instanceof o))return new o(t);t=t||{},i.call(this,t);var e=n(6409),r=this,a=this._exit,s=t.layer,u=null,l=void 0===t.position?{left:0,top:0}:t.position;if(!(void 0===t.parent||t.parent instanceof o))throw new Error("Parent must be of type geo.gui.widget");t.parent&&r.parent(t.parent),this._init=function(){return r.modified(),r},this._exit=function(){if(r.children().forEach((function(t){r.removeChild(t),t._exit()})),r.layer().geoOff(e.pan,r.repositionEvent),r.parentCanvas().removeChild&&r.canvas())try{r.parentCanvas().removeChild(r.canvas())}catch(t){}a()},this.layer=function(){return s||r.parent()&&r.parent().layer()},this._createCanvas=function(){throw new Error("Must be defined in derived classes")},this.canvas=function(t){return void 0===t?u:(u=t,r)},this._appendCanvasToParent=function(){r.parentCanvas().appendChild(r.canvas())},this.parentCanvas=function(){return r.parent()?r.parent().canvas():r.layer().canvas()},this.position=function(t,n){if(void 0!==t){r.layer().geoOff(e.pan,r.repositionEvent);var i={};for(var o in l)l.hasOwnProperty(o)&&(i[o]=null);return(l=t).hasOwnProperty("x")&&l.hasOwnProperty("y")&&r.layer().geoOn(e.pan,r.repositionEvent),r.reposition(Object.assign(i,r.position())),r}if(l.hasOwnProperty("x")&&l.hasOwnProperty("y")&&!n){var a=r.layer().map().gcsToDisplay(l);return{left:a.x,top:a.y,right:null,bottom:null}}return l},this.reposition=function(t){if(t=t||r.position(),r.canvas()&&r.canvas().style)for(var e in r.canvas().style.position="absolute",t)t.hasOwnProperty(e)&&(/^\s*(-|\+)?(\d+(\.\d*)?|\d*\.\d+)([eE](-|\+)?\d+)?\s*$/.test(t[e])?r.canvas().style[e]=parseFloat(parseFloat(t[e]).toFixed(3))+"px":r.canvas().style[e]=t[e]);return r},this.repositionEvent=function(){return r.reposition()},this.isInViewport=function(){var t=r.position(),e=r.layer();return t.left>=0&&t.top>=0&&t.left<=e.width()&&t.top<=e.height()},l.hasOwnProperty("x")&&l.hasOwnProperty("y")&&this.layer().geoOn(e.pan,r.repositionEvent)};r(o,i),t.exports=o},5966:function(t,e,n){var r=n(5616);function i(t,e,n){this._group=t,this._zoom=e,this._points=[],this._clusters=[],this._count=0,this._parent=null,this._coord=null;var r=this;(n||[]).forEach((function(t){r._add(t)}))}function o(t){var e,r,o=n(7235);for(this._opts=Object.assign({maxZoom:18,radius:5},t),this._clusters={},this._points={},e=this._opts.maxZoom;e>=0;e-=1)r=this._opts.radius*Math.pow(2,-e),this._clusters[e]=new o(r),this._points[e]=new o(r);this._topClusterLevel=new i(this,-1)}i.prototype._add=function(t){var e=1;t instanceof i?(this._clusters.push(t),e=t._count):this._points.push(t),t._parent=this,this._increment(e)},i.prototype._increment=function(t){this._coord=null,this._count+=t,this._parent&&this._parent._increment(t)},i.prototype.count=function(){return this._count},i.prototype.each=function(t){var e;for(e=0;e<this._points.length;e+=1)t.call(this,this._points[e],this._zoom);for(e=0;e<this._clusters.length;e+=1)this._clusters[e].each.call(this._clusters[e],t)},i.prototype.coords=function(){var t,e={x:0,y:0};if(this._coord)return this._coord;for(t=0;t<this._points.length;t+=1)e.x+=this._points[t].x,e.y+=this._points[t].y;for(t=0;t<this._clusters.length;t+=1)e.x+=this._clusters[t].coords().x*this._clusters[t].count(),e.y+=this._clusters[t].coords().y*this._clusters[t].count();return{x:e.x/this.count(),y:e.y/this.count()}},o.prototype.addPoint=function(t){var e,n,o,a,s,u;for(e=this._opts.maxZoom;e>=0;e-=1){if(n=this._clusters[e].getNearObject(t))return void n._add(t);if(n=this._points[e].getNearObject(t)){if(o=n._parent)for(u=o._points.length-1;u>=0;u-=1)if(o._points[u]===n){o._points.splice(u,1),o._increment(-1);break}for(o||r.noop(),a=new i(this,e,[n,t]),this._clusters[e].addObject(a,a.coords()),s=a,u=e-1;u>o._zoom;u-=1)s=new i(this,u,[s]),this._clusters[u].addObject(s,s.coords());for(o._add(s),u=e;u>=0&&this._points[u].removeObject(n,n);u-=1);return}this._points[e].addObject(t,t)}this._topClusterLevel._add(t)},o.prototype.points=function(t){return t=Math.min(Math.max(Math.floor(t),0),this._opts.maxZoom-1),this._points[Math.floor(t)].contents()},o.prototype.clusters=function(t){return t=Math.min(Math.max(Math.floor(t),0),this._opts.maxZoom-1),this._clusters[Math.floor(t)].contents()},t.exports=o},5637:function(t,e,n){var r=n(1949),i=n(7715);i=i.__esModule?i.default:i;var o={maxCount:1e3,count:0,memo:{}};function a(t,e){return o.count+=1,o.count>=o.maxCount&&(o.memo={},o.count=0),o.memo[t]=e,e}var s={convertColor:function(t){if(null==t||void 0!==t.r&&void 0!==t.g&&void 0!==t.b)return t;if(void 0!==o.memo[t])return o.memo[t];var e,n=t;if("string"==typeof t){var r=t.toLowerCase();if(i.hasOwnProperty(r))t={r:i[r][0]/255,g:i[r][1]/255,b:i[r][2]/255};else if("#"===t.charAt(0))4===t.length||5===t.length?(5===t.length&&(e=parseInt(t.slice(4),16)/15),t=4352*(3840&(t=parseInt(t.slice(1,4),16)))+272*(240&t)+17*(15&t)):7!==t.length&&9!==t.length||(9===t.length&&(e=parseInt(t.slice(7),16)/255),t=parseInt(t.slice(1,7),16));else if("transparent"===r)e=t=0;else if(r.indexOf("(")>=0)for(var u=0;u<s.cssColorConversions.length;u+=1){var l=s.cssColorConversions[u].regex.exec(r);if(l)return a(n,t=s.cssColorConversions[u].process(r,l))}}return isFinite(t)&&(t={r:((16711680&t)>>16)/255,g:((65280&t)>>8)/255,b:(255&t)/255}),void 0!==e&&t&&void 0!==t.r&&(t.a=e),a(n,t)},convertColorAndOpacity:function(t,e,n){return(t=s.convertColor(t))&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b||(t=s.convertColor(n||{r:0,g:0,b:0})),t&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b||(t={r:0,g:0,b:0}),t={r:isFinite(t.r)&&t.r>=0?t.r<=1?+t.r:1:0,g:isFinite(t.g)&&t.g>=0?t.g<=1?+t.g:1:0,b:isFinite(t.b)&&t.b>=0?t.b<=1?+t.b:1:0,a:r.isNonNullFinite(t.a)&&t.a>=0&&t.a<1?+t.a:1},r.isNonNullFinite(e)&&e<1&&(t.a=e<=0?0:t.a*e),t},convertColorToHex:function(t,e){var n,r=s.convertColor(t);return n=r.r||r.g||r.b?"#"+((1<<24)+(Math.round(255*r.r)<<16)+(Math.round(255*r.g)<<8)+Math.round(255*r.b)).toString(16).slice(1):"#000000",void 0!==r.a&&e&&(r.a<1||"needed"!==e)&&(n+=(256+Math.round(255*r.a)).toString(16).slice(1)),n},convertColorToRGBA:function(t){var e=s.convertColor(t);return e||(e={r:0,g:0,b:0}),(!r.isNonNullFinite(e.a)||e.a>1)&&(e.a=1),"rgba("+Math.round(255*e.r)+", "+Math.round(255*e.g)+", "+Math.round(255*e.b)+", "+ +(+e.a).toFixed(5)+")"},cssAngleUnitsBase:{deg:360,grad:400,rad:2*Math.PI,turn:1},cssNumberRegex:"[+-]?(?:\\d+\\.?\\d*|\\.\\d+)(?:[eE][+-]?\\d+)?"};s.cssColorConversions=[{name:"rgb",regex:new RegExp("^\\s*rgba?\\(\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*,?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*,?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*([/,]?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*)?\\)\\s*$"),process:function(t,e){return t={r:Math.min(1,Math.max(0,+e[1]/(e[2]?100:255))),g:Math.min(1,Math.max(0,+e[3]/(e[4]?100:255))),b:Math.min(1,Math.max(0,+e[5]/(e[6]?100:255)))},e[7]&&(t.a=Math.min(1,Math.max(0,+e[8]/(e[9]?100:1)))),t}},{name:"hsl",regex:new RegExp("^\\s*hsla?\\(\\s*("+s.cssNumberRegex+")\\s*(deg|grad|rad|turn)?\\s*,?\\s*("+s.cssNumberRegex+")\\s*%\\s*,?\\s*("+s.cssNumberRegex+")\\s*%\\s*([/,]?\\s*("+s.cssNumberRegex+")\\s*(%?)\\s*)?\\)\\s*$"),process:function(t,e){var n=function(t,e,n){return 6*(n-=Math.floor(n))<1?t+(e-t)*n*6:6*n<3?e:6*n<4?t+(e-t)*(2/3-n)*6:t},r=+e[1]/(s.cssAngleUnitsBase[e[2]]||360),i=Math.min(1,Math.max(0,+e[3]/100)),o=Math.min(1,Math.max(0,+e[4]/100)),a=o<=.5?o*(i+1):o+i-o*i,u=2*o-a;return t={r:n(u,a,r+1/3),g:n(u,a,r),b:n(u,a,r-1/3)},e[5]&&(t.a=Math.min(1,Math.max(0,+e[6]/(e[7]?100:1)))),t}}],t.exports=s},1949:function(t,e,n){function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}var i=n(5616),o=n(1960);o=o.__esModule?o.default:o;var a,s,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",l='<svg xmlns="http://www.w3.org/2000/svg"><foreignObject width="100%" height="100%"></foreignObject></svg>',c={},f=200,h=15;function d(){var t;for(t=0;t<arguments.length;t+=1)if(isFinite(arguments[t]))return arguments[t]}var p={pointInPolygon:function(t,e,n,r){return e.outer&&(n=e.inner,e=e.outer),!(e.length<3)&&(!(r&&r.min&&r.max&&(t.x<r.min.x||t.y<r.min.y||t.x>r.max.x||t.y>r.max.y))&&p.distanceToPolygon2d(t,n?{outer:e,inner:n}:e,!0)>0)},pointToTriangleBasis2d:function(t,e,n,r){var i=n.x-e.x,o=r.x-e.x,a=n.y-e.y,s=r.y-e.y,u=t.x-e.x,l=t.y-e.y,c=i*s-o*a;if(c)return{x:(u*s-l*o)/c,y:(u*-a+l*i)/c}},isReadyImage:function(t,e){return!!(t instanceof Image&&t.complete&&t.src&&(t.naturalWidth&&t.naturalHeight||e))},isReadyVideo:function(t,e){return!!(t instanceof HTMLVideoElement&&t.src&&void 0!==t.HAVE_CURRENT_DATA&&(t.videoWidth&&t.videoHeight&&t.readyState>=t.HAVE_CURRENT_DATA||e&&t.error))},isFunction:function(t){return"function"==typeof t},ensureFunction:function(t){return p.isFunction(t)?t:function(){return t}},isNonNullFinite:function(t){return isFinite(t)&&null!==t&&!1!==t&&""!==t},randomString:function(t){var e,n,r;for(t=t||8,e="",n=0;n<t;n+=1)r=Math.floor(62*Math.random()),e+=u.substring(r,r+1);return e},normalizeCoordinates:function(t){return t=t||{},Array.isArray(t)?{x:t[0],y:t[1],z:t[2]||0}:{x:d(t.x,t.longitude,t.lng,t.lon,0),y:d(t.y,t.latitude,t.lat,0),z:d(t.z,t.elevation,t.elev,t.height,0)}},range:function(t,e,n){n=n||1;for(var r=[],i=t;i<=e;i+=n)r.push(i);return r},compareArrays:function(t,e){return t.length===e.length&&t.every((function(t,n){return t===e[n]}))},vec3AsArray:function(){return[0,0,0]},mat3AsArray:function(){return[1,0,0,0,1,0,0,0,1]},mat4AsArray:function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]},getGeomBuffer:function(t,e,n,r,i){r=void 0===r?.2:r,i=void 0===i?.1:i;var o=t.sourceByName(e),a=o.data(),s=Math.floor((r+1)*n);if((a=o.data())instanceof Float32Array&&(a.length===n||a.length>=n&&a.length<=s))return a;var u=n;return a instanceof Float32Array&&a.length&&n&&i>0&&(u=Math.floor((i+1)*n)),a=new Float32Array(u),o.setData(a),a},adjustActions:function(t){var e,n;for(n=0;n<t.length;n+=1){if(e=t[n],"string"===i.type(e.input)){var r={};r[e.input]=!0,e.input=r}if(e.modifiers||(e.modifiers={}),"string"===i.type(e.modifiers)){var o={};o[e.modifiers]=!0,e.modifiers=o}}},addAction:function(t,e,n){n?t.push(e):t.unshift(e),p.adjustActions(t)},hasAction:function(t,e,n,r){e&&e.action&&(n=e.name,r=e.owner,e=e.action);for(var i=0;i<t.length;i+=1)if(!(e&&t[i].action!==e||n&&t[i].name!==n||r&&t[i].owner!==r))return t[i];return null},removeAction:function(t,e,n,r){var i,o=0;do{(i=p.hasAction(t,e,n,r))&&(t.splice(t.indexOf(i),1),o+=1)}while(i);return o},actionMatch:function(t,e,n){var r;if(n.some((function(n){for(var i in n.input)if(n.input.hasOwnProperty(i)&&(!1===n.input[i]&&t[i]||n.input[i]&&!t[i]))return!1;for(var o in n.modifiers)if(n.modifiers.hasOwnProperty(o)&&(!1===n.modifiers[o]&&e[o]||n.modifiers[o]&&!e[o]))return!1;return r=n,!0})))return r},pixelCoordinateParams:function(t,e,n,r,o){var a,s,u;t&&(a=(t=i(t)).innerWidth(),s=t.innerHeight()),o=o||n,u=(r=r||e)!==e||o!==n;var l=Math.min(0,Math.floor(Math.log(Math.min((a||r)/r,(s||o)/o))/Math.log(2))),c=Math.ceil(Math.log(Math.max(e/r,n/o))/Math.log(2));return{map:{node:t,ingcs:"+proj=longlat +axis=esu",gcs:"+proj=longlat +axis=enu",maxBounds:{left:0,top:0,right:e,bottom:n},unitsPerPixel:Math.pow(2,c),center:{x:e/2,y:n/2},min:l,max:c,zoom:l,clampBoundsX:!0,clampBoundsY:!0,clampZoom:!0},layer:{maxLevel:c,minLevel:Math.min(0,c),wrapX:!1,wrapY:!1,tileOffset:function(){return{x:0,y:0}},attribution:"",tileWidth:r,tileHeight:o,tileRounding:Math.ceil,tilesAtZoom:u?function(t){var i=Math.pow(2,c-t);return{x:Math.ceil(e/r/i),y:Math.ceil(n/o/i)}}:void 0,tilesMaxBounds:u?function(t){var r=Math.pow(2,c-t);return{x:Math.floor(e/r),y:Math.floor(n/r)}}:void 0}}},centerFromPerimeter:function(t){var e,n,r,i,o,a;if(t&&t.outer&&(t=t.outer),t&&t.length){if(1===t.length)return{x:t[0].x,y:t[0].y};for(e={x:0,y:0},o=0,n=t[t.length-1],a=0;a<t.length;a+=1)r=n,n=t[a],i=Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2)),e.x+=(n.x+r.x)*i,e.y+=(n.y+r.y)*i,o+=2*i;return e.x/=o,e.y/=o,o?e:{x:n.x,y:n.y}}},distance2dSquared:function(t,e){var n=t.x-e.x,r=t.y-e.y;return n*n+r*r},distance2dToLineSquared:function(t,e,n){var r=n.x-e.x,i=n.y-e.y,o=r*r+i*i,a=0;return o&&(a=((t.x-e.x)*r+(t.y-e.y)*i)/o,a=Math.max(0,Math.min(1,a))),p.distance2dSquared(t,{x:e.x+a*r,y:e.y+a*i})},distanceToPolygon2d:function(t,e,n){for(var r,i,o=e.outer||e,a=!1,s=0,u=o.length,l=u-1;s<u;l=s,s+=1){var c=o[s],f=o[l];c.y>t.y!=f.y>t.y&&t.x<(f.x-c.x)*(t.y-c.y)/(f.y-c.y)+c.x&&(a=!a),i=n?1:p.distance2dToLineSquared(t,c,f),(void 0===r||i<r)&&(r=i)}return e.inner&&e.inner.forEach((function(e){var i=p.distanceToPolygon2d(t,e,n);i*i<r&&(r=i*i),i>0&&(a=!a)})),(a?1:-1)*Math.sqrt(r)},triangleTwiceSignedArea2d:function(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)},crossedLineSegmentPolygon2d:function(t,e,n){var r,i,o=n.outer||n,a=o.length;for(r=0,i=a-1;r<a;i=r,r+=1)if(p.crossedLineSegments2d(t,e,o[r],o[i]))return!0;if(n.inner)for(r=0;r<n.inner.length;r+=1)if(p.crossedLineSegmentPolygon2d(t,e,n.inner[r]))return!0;return!1},crossedLineSegments2d:function(t,e,n,r){return!(t.x>n.x&&t.x>r.x&&e.x>n.x&&e.x>r.x||t.x<n.x&&t.x<r.x&&e.x<n.x&&e.x<r.x||t.y>n.y&&t.y>r.y&&e.y>n.y&&e.y>r.y||t.y<n.y&&t.y<r.y&&e.y<n.y&&e.y<r.y)&&(!(t.x===n.x&&t.y===n.y||t.x===r.x&&t.y===r.y||e.x===n.x&&e.y===n.y||e.x===r.x&&e.y===r.y)&&!(p.triangleTwiceSignedArea2d(t,e,n)*p.triangleTwiceSignedArea2d(t,e,r)>0||p.triangleTwiceSignedArea2d(n,r,t)*p.triangleTwiceSignedArea2d(n,r,e)>0))},segmentCrossesLineList2d:function(t,e,n){return n.some((function(n){return n.some((function(r,i){return!!i&&p.crossedLineSegments2d(t,e,n[i-1],r)}))}))},rdpLineSimplify:function(t,e,n,r){if(t.length<=2||e<0)return t;var i,o,a,s=-1,u=e*e;if(n){for(i=1;i<t.length;i+=1)(o=p.distance2dSquared(t[0],t[i]))>s&&(s=o,a=i);return 4*s<=u?t.slice(a,a+1):(t=t.slice(a).concat(t.slice(0,a+1)),(t=p.rdpLineSimplify(t,e,!1,r)).splice(t.length-1),t)}for(i=1;i<t.length-1;i+=1)(o=p.distance2dToLineSquared(t[i],t[0],t[t.length-1]))>s&&(s=o,a=i);if(s<=u&&(!r||!p.segmentCrossesLineList2d(t[0],t[t.length-1],r)))return[t[0],t[t.length-1]];var l=t.slice(0,a+1),c=t.slice(a),f=p.rdpLineSimplify(l,e,!1,r?r.concat([c]):null),h=p.rdpLineSimplify(c,e,!1,r?r.concat([l]):null);return f.slice(0,f.length-1).concat(h)},getMinMaxValues:function(t,e,n,r){if(t.length&&(r||!i.isNumeric(e)||!i.isNumeric(n))){var o,a,s=t[0],u=t[0];for(a=t.length-1;a>0;a-=1)(o=t[a])<s&&(s=o),o>u&&(u=o);(!i.isNumeric(e)||r&&s>e)&&(e=s),(!i.isNumeric(n)||r&&u<n)&&(n=u)}return{min:e,max:n}},wrapAngle:function(t){return(t%=2*Math.PI)<-Math.PI?t+=2*Math.PI:t>=Math.PI&&(t-=2*Math.PI),t},escapeUnicodeHTML:function(t){return t.replace(/[^- 0-9A-Za-z~`!@#$%^&*()_+={}|[\]\\:";'<>?,./]/g,(function(e,n){var r=e.charCodeAt(0);if(r<127)return e;if(r>=55296&&r<=57344){if(r<56320||n)return"";var i=t.charCodeAt(n-1);if(i<55296||i>=56320)return"";r=1024*(i-55296)+(r-56320)}return"&#"+r.toString(10)+";"}))},deepMerge:function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i<e;i++)n[i-1]=arguments[i];for(var o=0,a=n;o<a.length;o++){var s=a[o];if(null!=s)for(var u in s)if("__proto__"!==u&&t!==s[u]){var l=s[u];if(l&&"object"===r(l)&&(l.constructor===Object||Array.isArray(l))){var c=t[u];Array.isArray(l)?Array.isArray(c)||(c=[]):("object"!==r(c)||Array.isArray(c))&&(c={}),t[u]=p.deepMerge(c,l)}else void 0!==l&&(t[u]=l)}}return t},dereferenceElements:function(t){var e=[];return i("img,image",t).each((function(){var t=i(this),n=t.is("image")?"href":"src";if(t.attr(n)){var r=new Image;("http"===t.attr(n).substr(0,4)||t[0].crossOrigin)&&(r.crossOrigin=t[0].crossOrigin||"anonymous");var o=i.Deferred();r.onload=function(){var e=document.createElement("canvas");e.width=r.naturalWidth,e.height=r.naturalHeight,e.getContext("2d").drawImage(r,0,0),t.attr(n,e.toDataURL("image/png")),"data:image"!==t.attr(n).substr(0,10)&&t.remove(),o.resolve()},r.onerror=function(){t.remove(),o.resolve()},r.src=t.attr(n),e.push(o)}})),e},dereferenceCssUrlsRegex:/url\(["']?(http[^)"']+|[^:)"']+)["']?\)/g,dereferenceCssUrls:function(t,e,n,r,o){var a=[],s=[];if(t=(t=t.replace(/\/\*[^\0]*?\*\//g,"")).replace(/\r/g,"\n").replace(/\s+\n/g,"\n").replace(/\n\s+/g,"\n").replace(/\n\n+/g,"\n"),o){var u=/(^[^?#]*)\/[^?#/]*([?#]|$)/g.exec(o);o=u&&u[1]?u[1]+"/":null}t.replace(p.dereferenceCssUrlsRegex,(function(t,e){var n=a.length,r=i.Deferred(),u=new XMLHttpRequest;return a.push(r),s.push(""),/^[^/:][^:]*(\/|$)/g.exec(e)&&o&&(e=o+e),u.open("GET",e,!0),u.responseType="arraybuffer",u.onload=function(){if(200===this.status){var t,e=new Uint8Array(this.response),i=new Array(e.length);for(t=0;t<e.length;t+=1)i[t]=String.fromCharCode(e[t]);i=i.join(""),s[n]="url(data:"+u.getResponseHeader("content-type")+";base64,"+btoa(i)+")"}r.resolve()},u.onerror=r.resolve,u.send(),t})),i.when.apply(i,a).then((function(){var i=0;t=t.replace(p.dereferenceCssUrlsRegex,(function(t,e){return s[(i+=1)-1]})),void 0===r?e.text(t):e.style[r]=t,n.resolve()}))},htmlToImageSupported:function(){if(void 0===s){var t=i.Deferred(),e=i(l);e.attr({width:"10px",height:"10px","text-rendering":"optimizeLegibility"}),i("foreignObject",e).append("<div/>");var n=new Image;return n.onload=n.onerror=function(){var e=document.createElement("canvas");e.width=10,e.height=10,e.getContext("2d").drawImage(n,0,0);try{e.toDataURL(),s=!0}catch(t){console.warn("This browser does not support converting HTML to an image via SVG foreignObject. Some functionality will be limited.",t),s=!1}t.resolve(s)},n.src="data:image/svg+xml;base64,"+btoa(p.escapeUnicodeHTML((new XMLSerializer).serializeToString(e[0]))),t}return s},htmlToImage:function(t,e){var n,r=i.Deferred(),o=[p.htmlToImageSupported()],a=i(t);for(t=i(t).clone();e&&e>0;)(a=a.parent()).is("div")&&((n=i("<div>").attr({class:a.attr("class"),id:a.attr("id")}).css({width:"100%",height:"100%",background:"none",margin:0})).append(t),t=n),e-=1;i("canvas",t).remove(),i("*",t).addBack().each((function(){for(var t=this.style,e=0;e<t.length;e+=1){var n=this.style[e];if(this.style[n].match(p.dereferenceCssUrlsRegex)){var r=i.Deferred();p.dereferenceCssUrls(this.style[n],this,r,n),o.push(r)}}})),(n=i('<div xmlns="http://www.w3.org/1999/xhtml">')).css({width:a.width()+"px",height:a.height()+"px"}),n.append(i("<head>"));var s=i("<body>");return n.append(s),s.css({width:a.width()+"px",height:a.height()+"px",background:"none",margin:0}),s.append(t),o=o.concat(p.dereferenceElements(t)),i('style,link[rel="stylesheet"]').each((function(){var t=i('<style type="text/css">'),e=i.Deferred();if(i(this).is("style")){var r=i(this).text();p.dereferenceCssUrls(r,t,e)}else{var a=i(this).attr("href");i.get(a).done((function(n){p.dereferenceCssUrls(n,t,e,void 0,a)})).fail((function(n,r,i){console.warn("Failed to dereference "+a,r,i),t.remove(),e.resolve()}))}o.push(e),i("head",n).append(t)})),i.when.apply(i,o).then((function(){var t=i(l);t.attr({width:a.width()+"px",height:a.height()+"px","text-rendering":"optimizeLegibility"}),i("foreignObject",t).append(n);var e=new Image;p.htmlToImageSupported()?(e.onload=function(){r.resolve(e)},e.onerror=function(){console.warn("Failed to render html to image"),r.reject()},e.src="data:image/svg+xml;base64,"+btoa(p.escapeUnicodeHTML((new XMLSerializer).serializeToString(t[0])))):r.resolve(e)})),r},timeReport:function(t){return i.each(c,(function(t,e){e.count?(e.stddev=Math.sqrt(Math.abs((e.sum2-e.sum*e.sum/e.count)/e.count)),e.average=e.sum/e.count):(e.stddev=0,e.average=0)})),t?c[t]:c},timeFunctionStart:function(t,e){c[t]&&!e||(c[t]={count:0,sum:0,sum2:0,max:0,recent:[]}),c[t].start=window.performance.now()},timeFunctionStop:function(t){if(c[t]&&c[t].start){var e=window.performance.now()-c[t].start;c[t].start=null,c[t].sum+=e,c[t].sum2+=e*e,c[t].count+=1,c[t].max=Math.max(c[t].max,e),c[t].recent.push(e),c[t].recent.length>f&&c[t].recent.splice(0,c[t].recent.length-f)}},timeRequestAnimationFrame:function(t,e,n,r){c.requestAnimationFrame&&!e||(c.requestAnimationFrame={count:0,sum:0,sum2:0,max:0,above_threshold:0,recent:[],recentsub:[]}),n&&(h=n),r&&(f=r),t&&a?(window.requestAnimationFrame=a,a=null):t||a||(a=window.requestAnimationFrame,window.requestAnimationFrame=function(t){return a.call(window,(function(e){var n,r=c.requestAnimationFrame;r.timestamp!==e&&(r.nowDelta=window.performance.now()-e,Math.abs(r.nowDelta)<1e3&&(r.nowDelta=0),r.timestamp=e,r.subcalls=r.subcalls||0,r.start={sum:r.sum,sum2:r.sum2,count:r.count,max:r.max,above_threshold:r.above_threshold},r.recent.push([0]),r.recentsub.push([]),r.recent.length>f&&(r.recent.splice(0,r.recent.length-f),r.recentsub.splice(0,r.recentsub.length-f))),r.subcalls+=1,t.apply(this,arguments);var i=window.performance.now()-e;i-=r.nowDelta,r.sum=r.start.sum+i,r.sum2=r.start.sum2+i*i,r.count=r.start.count+1,r.max=Math.max(r.max,i),r.above_threshold=r.start.above_threshold+(i>=h?1:0),r.recent[r.recent.length-1]=i,(n=r.recentsub[r.recent.length-1]).push({total_duration:i,duration:i-(n.length?n[n.length-1].total_duration:0),callback:t.name||t})}))})},isObject:function(t){var e=r(t);return null!=t&&("object"===e||"function"===e)},identityFunction:function(t){return t},radiusEarth:o.WGS84.a};t.exports=p},7235:function(t,e,n){var r=n(5616),i={};i.Util={stamp:function(t){return t._leaflet_id=t._leaflet_id||++i.Util.lastId,t._leaflet_id},lastId:0};var o=function(t){this._cellSize=t,this._sqCellSize=t*t,this._grid={},this._objectPoint={}};o.prototype={addObject:function(t,e){var n=this._getCoord(e.x),r=this._getCoord(e.y),o=this._grid,a=o[r]=o[r]||{},s=a[n]=a[n]||[],u=i.Util.stamp(t);e.obj=t,this._objectPoint[u]=e,s.push(t)},updateObject:function(t,e){this.removeObject(t),this.addObject(t,e)},removeObject:function(t,e){var n,r,o=this._getCoord(e.x),a=this._getCoord(e.y),s=this._grid,u=s[a]=s[a]||{},l=u[o]=u[o]||[];for(delete this._objectPoint[i.Util.stamp(t)],n=0,r=l.length;n<r;n++)if(l[n]===t)return l.splice(n,1),1===r&&delete u[o],!0},eachObject:function(t,e){var n,r,i,o,a,s,u=this._grid;for(n in u)for(r in a=u[n])for(i=0,o=(s=a[r]).length;i<o;i++)t.call(e,s[i])&&(i--,o--)},getNearObject:function(t){var e,n,r,o,a,s,u,l,c=this._getCoord(t.x),f=this._getCoord(t.y),h=this._objectPoint,d=this._sqCellSize,p=null;for(e=f-1;e<=f+1;e++)if(o=this._grid[e])for(n=c-1;n<=c+1;n++)if(a=o[n])for(r=0,s=a.length;r<s;r++)u=a[r],(l=this._sqDist(h[i.Util.stamp(u)],t))<d&&(d=l,p=u);return p},contents:function(){return r.map(this._objectPoint,(function(t){return t}))},_getCoord:function(t){return Math.floor(t/this._cellSize)},_sqDist:function(t,e){var n=e.x-t.x,r=e.y-t.y;return n*n+r*r}},t.exports=o},642:function(t,e,n){t.exports=Object.assign(n(1949),n(5637),n(208),n(269),{DistanceGrid:n(7235),ClusterGroup:n(5966),mesh:n(5905),polyops:n(5647)})},5905:function(t,e,n){t.exports={createColoredMesh:function(t,e){var r,i,o,a,s,u=n(642),l=t.mesh,c=t.style.get("value"),f={used:void 0!==t.style("used")?t.style.get("used"):function(t,e){return u.isNonNullFinite(c(t,e))},opacity:t.style.get("opacity"),value:c},h=t._createMesh(e?{}:f,e?f:{});if(h.elementValues=!!e,!h.numVertices||!h.numElements)return h;var d=l.get("stepped")(h),p=l.get("opacityRange")(h),m=l.get("rangeValues")(h);if(h.stepped=!(void 0!==d&&!d),h.colorMap=[],h.minColor=Object.assign({a:l.get("minOpacity")(h)||0},u.convertColor(l.get("minColor")(h))),h.maxColor=Object.assign({a:l.get("maxOpacity")(h)||0},u.convertColor(l.get("maxColor")(h))),l.get("colorRange")(h).forEach((function(t,e){h.colorMap.push(Object.assign({a:p&&void 0!==p[e]?p[e]:1},u.convertColor(t)))})),r=u.getMinMaxValues(h.value,l.get("min")(h),l.get("max")(h)),h.minValue=r.min,h.maxValue=r.max,m&&h.colorMap&&(m.length===h.colorMap.length+1||!d&&m.length===h.colorMap.length)||(m=null),m)for(s=1;s<m.length;s+=1)if(m[s-1]>m[s]){m=null;break}for(m&&(h.minValue=m[0],h.maxValue=m[m.length-1]),(o=h.maxValue-h.minValue)||(h.colorMap=h.colorMap.slice(0,1),o=1,m=null),h.rangeValues=m,h.factor=(h.colorMap.length-(d?0:1))/o,a=0;a<h.value.length;a+=1)if(i=h.value[a],m&&i>=h.minValue&&i<=h.maxValue){for(s=1;s<m.length;s+=1)if(i<=m[s]){h.value[a]=s-1+(i-m[s-1])/(m[s]-m[s-1]);break}}else h.value[a]=(i-h.minValue)*h.factor;return h}}},269:function(t,e,n){var r,i,o=n(7945);t.exports={},t.exports.mockWebglRenderer=function(t){"use strict";var e=n(1611);if(void 0===t&&(t=!0),e._mocked)throw new Error("webgl renderer already mocked");var a={},s=function(t){a[t]=(a[t]||0)+1},u=function(t){return function(){s(t)}},l=0,c=function(t){return function(){return s(t),l+=1}},f={activeTexture:u("activeTexture"),attachShader:u("attachShader"),bindAttribLocation:u("bindAttribLocation"),bindBuffer:u("bindBuffer"),bindFramebuffer:u("bindFramebuffer"),bindTexture:u("bindTexture"),blendFuncSeparate:u("blendFuncSeparate"),bufferData:u("bufferData"),bufferSubData:u("bufferSubData"),checkFramebufferStatus:function(t){if(s("checkFramebufferStatus"),t===e.GL.FRAMEBUFFER)return e.GL.FRAMEBUFFER_COMPLETE},clear:u("clear"),clearColor:u("clearColor"),clearDepth:u("clearDepth"),compileShader:u("compileShader"),createBuffer:c("createBuffer"),createFramebuffer:u("createFramebuffer"),createProgram:c("createProgram"),createShader:c("createShader"),createTexture:c("createTexture"),deleteBuffer:u("deleteBuffer"),deleteProgram:u("deleteProgram"),deleteShader:u("deleteShader"),deleteTexture:u("deleteTexture"),detachShader:u("detachShader"),depthFunc:u("depthFunc"),disable:u("disable"),disableVertexAttribArray:u("disableVertexAttribArray"),drawArrays:u("drawArrays"),enable:u("enable"),enableVertexAttribArray:u("enableVertexAttribArray"),finish:u("finish"),getError:u("getError"),getExtension:c("getExtension"),getParameter:function(t){switch(s("getParameter"),t){case e.GL.ALIASED_POINT_SIZE_RANGE:return[1,64];case e.GL.DEPTH_BITS:return 16;case e.GL.MAX_TEXTURE_SIZE:return 4096}},getProgramParameter:function(t,n){if(s("getProgramParameter"),n===e.GL.LINK_STATUS)return!0},getShaderInfoLog:function(){return s("getShaderInfoLog"),"log"},getShaderParameter:function(t,n){if(s("getShaderParameter"),n===e.GL.COMPILE_STATUS)return!0},getSupportedExtensions:function(){return s("getSupportedExtensions"),[]},getUniformLocation:c("getUniformLocation"),isEnabled:function(t){if(s("isEnabled"),t===e.GL.BLEND)return!0},linkProgram:u("linkProgram"),pixelStorei:u("pixelStorei"),shaderSource:u("shaderSource"),texImage2D:u("texImage2D"),texParameteri:u("texParameteri"),uniform1iv:u("uniform1iv"),uniform1fv:u("uniform1fv"),uniform2fv:u("uniform2fv"),uniform3fv:u("uniform3fv"),uniform4fv:u("uniform4fv"),uniformMatrix3fv:u("uniformMatrix3fv"),uniformMatrix4fv:u("uniformMatrix4fv"),useProgram:u("useProgram"),vertexAttribPointer:u("vertexAttribPointer"),vertexAttrib3fv:u("vertexAttrib3fv"),viewport:u("viewport")};r=e.renderWindow;var h=function(){e.renderWindow=r;var t,n=new e.renderWindow;return e.renderWindow=h,n._setup=function(){var r,i=n.renderers(),o=n.windowSize(),a=n.windowPosition();for(t=Object.assign({},e.GL,f),r=0;r<i.length;r+=1)(i[r].width()>o[0]||0===i[r].width()||i[r].height()>o[1]||0===i[r].height())&&i[r].resize(a[0],a[1],o[0],o[1]);return!0},n.context=function(){return t},n};e.renderWindow=h,i=o.supported,o.supported=function(){return!!t},o._maxTextureSize=4096,o._maxPointSize=64,e._mocked=!0,e.mockCounts=function(){return a}},t.exports.restoreWebglRenderer=function(){var t=n(1611);t._mocked&&(t.renderWindow=r,o.supported=i,delete t._mocked,delete t.mockCounts)}},5647:function(t,e,n){function r(t){return function(t){if(Array.isArray(t))return i(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return i(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var o=n(6820),a=n(6211),s=n(1949),u={"+":"union","|":"union",add:"union","-":"difference",sub:"difference",subtract:"difference",minus:"difference","*":"intersect","&":"intersect",mul:"intersect",multiply:"intersect",x:"xor","^":"xor"};function l(t,e,n){for(t="select"+t.charAt(0).toUpperCase()+t.slice(1),o.epsilon(e);n.length>1;){for(var r=[],i=Math.ceil(n.length/2),a=0;a<i;a+=1){var s=n[a];if(a+i<n.length){var u=n[a+i];try{s=o.combine(s,u)}catch(t){s=o.segments(o.polygon(s)),u=o.segments(o.polygon(u));for(var l=20;l>=6;l-=1){o.epsilon(Math.pow(.1,l));try{s=o.combine(s,u);break}catch(t){}}o.epsilon(e)}s.combined?(s.combined=s.combined.filter((function(t){return Math.abs(t.start[0]-t.end[0])>e||Math.abs(t.start[1]-t.end[1])>e})),s=o[t](s)):console.warn("Failed in polygon functions."),s.segments=s.segments.filter((function(t){return Math.abs(t.start[0]-t.end[0])>e||Math.abs(t.start[1]-t.end[1])>e}))}r.push(s)}n=r}return n}function c(t,e,n){if(e=e||{},t.toPolygonList){if(e.style=t,!(t=t.toPolygonList(n)).length)return e.min=e.max=[0,0],e.epsilon=1e-10,t}else{if(e.style="",t.outer?(e.style="-outer",t=[[t.outer].concat(r(t.inner||[]))]):t.length&&t[0].outer&&(e.style="-outer-list",t=t.map((function(t){return[t.outer].concat(r(t.inner||[]))}))),!t.length)return e.style="flat-listlist"+e.style,e.min=e.max=[0,0],e.epsilon=1e-10,t;void 0!==t[0].x?(e.style="object",t=[[t.map((function(t){return[t.x,t.y]}))]]):void 0!==t[0][0].x?(e.style="object-list"+e.style,t=[t.map((function(t){return t.map((function(t){return[t.x,t.y]}))}))]):void 0===t[0][0][0]?(e.style="flat",t=[[t]]):void 0!==t[0][0][0].x?(e.style="object-listlist"+e.style,t=t.map((function(t){return t.map((function(t){return t.map((function(t){return[t.x,t.y]}))}))}))):void 0===t[0][0][0][0]?(e.style="flat-list",t=[t]):e.style="flat-listlist"+e.style}return e.min=[t[0][0][0][0],t[0][0][0][1]],e.max=[t[0][0][0][0],t[0][0][0][1]],t.forEach((function(t){return t.forEach((function(t){return t.forEach((function(t){t[0]<e.min[0]&&(e.min[0]=t[0]),t[0]>e.max[0]&&(e.max[0]=t[0]),t[1]<e.min[1]&&(e.min[1]=t[1]),t[1]>e.max[1]&&(e.max[1]=t[1])}))}))})),e.epsilon=1e-10*Math.max(Math.max(e.max[0],e.max[1]),Math.max(Math.abs(e.min[0]),Math.abs(e.min[1]))),t}function f(t,e,n){return e.style.fromPolygonList?e.style.fromPolygonList(t,n):(e.style.includes("object")&&(t=t.map((function(t){return t.map((function(t){return t.map((function(t){return{x:t[0],y:t[1]}}))}))}))),e.style.includes("outer")&&(t=[t.map((function(t){return{outer:t[0],inner:t.slice(1)}}))]),e.style.endsWith("listlist")||(t=e.style.endsWith("list")?t[0]:t[0][0]),t)}function h(t,e,r,i){var h=n(5325);t=u[t]||t,e.poly1&&(e=(i=e).poly1,r=i.poly2);var d=(i=i||{}).ingcs||(i.map?i.map.ingcs():e.gcs?e.gcs():e.layer&&e.layer().gcs?e.layer().gcs():e.layer?e.layer().map().ingcs():e.map instanceof a?e.map().ingcs():void 0),p=i.ingcs||(i.map?i.map.ingcs():r.gcs?r.gcs():r.layer&&r.layer().gcs?r.layer().gcs():r.layer?r.layer().map().ingcs():r.map instanceof a?r.map().ingcs():d),m=i.gcs||(i.map?i.map.gcs():e.layer?e.layer().map().gcs():e.map instanceof a?e.map().gcs():void 0),g={},y={};e=c(e,g,i),r=c(r,y,i),g.epsilon=i.epsilon1||g.epsilon,y.epsilon=i.epsilon2||g.epsilon,d&&m&&d!==m&&(e=e.map((function(t){return t.map((function(t){return h.transformCoordinates(d,m,t)}))}))),p&&m&&p!==m&&(r=r.map((function(t){return t.map((function(t){return h.transformCoordinates(p,m,t)}))})));var v=e.map((function(t){return o.segments({regions:t})})),x=r.map((function(t){return o.segments({regions:t})}));v=l(i.innerOperation||"union",g.epsilon,v),x=l(i.innerOperation||"union",y.epsilon,x);var _=v;v[0]&&x[0]?(v[0].inverted=!1,x[0].inverted=!1,_=l(t,Math.max(g.epsilon,y.epsilon),[v[0],x[0]])):x[0]&&(_=x);var b,w,M=function(t){var e=[],n=[],r=[],i=[];t.forEach((function(t){return o.polygon(t).regions.forEach((function(t){var e=t.map((function(t){return{x:t[0],y:t[1]}}));e.length<3||(i.push([]),n.forEach((function(t,r){s.pointInPolygon(e[0],t)?i[n.length].push(r):s.pointInPolygon(t[0],e)&&i[r].push(n.length)})),r.push(t),n.push(e))}))}));for(var a=Array(r.length),u=0;u<r.length;){for(var l=0;l<r.length;l+=1)void 0!==a[l]||i[l].length||(a[l]=e.length,e.push([r[l].reverse()]),u+=1);for(var c=0;c<r.length;c+=1)void 0===a[c]&&1===i[c].length&&void 0!==a[i[c][0]]&&(e[a[i[c][0]]].push(r[c]),a[c]=a[i[c][0]],u+=1);for(var f=0;f<r.length;f+=1)i[f]=i[f].filter((function(t){return void 0===a[t]}))}return e.length?e:[[]]}(_);return i.correspond&&function(t,e,n,r){var i={},o=[];n.forEach((function(t,e){return t.forEach((function(t){return t.forEach((function(t){var n="_"+t[0]+"_"+t[1];i[n]?-1===i[n].indexOf(e)&&i[n].push(e):i[n]=[e],o.length<=e&&o.push(0),o[e]+=1}))}))})),["poly1","poly2"].forEach((function(a){var s="poly1"===a?t:e,u="poly1"===a?"exact1":"exact2";r[a]=Array(s.length),r[u]=Array(s.length),s.forEach((function(t,e){var s={},l=0;t.forEach((function(t){return t.forEach((function(t){var e="_"+t[0]+"_"+t[1];i[e]?i[e].forEach((function(t){s[t]=(s[t]||0)+1})):l+=1}))})),Object.keys(s).forEach((function(i){s[i]!==o[+i]||l||t.length!==n[+i].length||(r[u][e]||(r[u][e]=[]),r[u][e].push(+i)),s[i]>=2&&(r[a][e]||(r[a][e]=[]),r[a][e].push(+i))}))}))}))}(e,r,M,i.correspond),d&&m&&d!==m&&(M=M.map((function(t){return t.map((function(t){return h.transformCoordinates(m,d,t)}))}))),f(M,{style:i.style||(b=M,w=g.style,w.fromPolygonList?w:b.length>1?w.includes("outer")?w+(w.endsWith("list")?"":"-list"):w.endsWith("listlist")?w:w+(w.endsWith("list")?"list":"-listlist"):1===b.length&&b[0].length>1?w.includes("outer")||w.endsWith("list")?w:w+"-list":w)},i)}function d(t){return function(e,n,r){return h(t,e,n,r)}}t.exports={union:d("union"),intersect:d("intersect"),difference:d("difference"),xor:d("xor"),toPolygonList:c,fromPolygonList:f}},208:function(t){var e=function(t,e,n,r,i){var o,a=0;return"boolean"!=typeof e&&(i=r,r=n,n=e,e=void 0),"function"!=typeof r&&(i=r,r=function(){}),function(){var s=this,u=+new Date-a,l=arguments;function c(){a=+new Date,n.apply(s,l)}r.apply(s,l),i&&!o&&c(),o&&clearTimeout(o),void 0===i&&u>t?c():!0!==e&&(o=setTimeout(i?function(){o=void 0}:c,void 0===i?t-u:t))}};t.exports={throttle:e,debounce:function(t,n,r,i){return"boolean"!=typeof n&&(i=r,r=n,n=!1),e(t,!1,r,i=i||function(){},!!n)}}},6858:function(t,e,n){var r=n(4626),i=n(1275),o=n(642),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},i.call(this,t);var e=this,n=this._init;this.featureType="vector",this.origin=function(t){return void 0===t?e.style("origin"):(e.style("origin",t),e.dataTime().modified(),e)},this.delta=function(t){return void 0===t?e.style("delta"):(e.style("delta",t),e.dataTime().modified(),e)},this._init=function(t){n.call(e,t);var r=Object.assign({},{strokeColor:"black",strokeWidth:2,strokeOpacity:1,originStyle:"none",endStyle:"arrow",origin:{x:0,y:0,z:0},delta:o.identityFunction,scale:null},void 0===t.style?{}:t.style);return void 0!==t.origin&&(r.origin=t.origin),e.style(r),e.dataTime().modified(),e}};r(a,i),t.exports=a},4081:function(t){t.exports="1.14.2"},6552:function(t,e,n){n(698).GL={ACTIVE_ATTRIBUTES:35721,ACTIVE_TEXTURE:34016,ACTIVE_UNIFORMS:35718,ALIASED_LINE_WIDTH_RANGE:33902,ALIASED_POINT_SIZE_RANGE:33901,ALPHA:6406,ALPHA_BITS:3413,ALWAYS:519,ARRAY_BUFFER:34962,ARRAY_BUFFER_BINDING:34964,ATTACHED_SHADERS:35717,BACK:1029,BLEND:3042,BLEND_COLOR:32773,BLEND_DST_ALPHA:32970,BLEND_DST_RGB:32968,BLEND_EQUATION:32777,BLEND_EQUATION_ALPHA:34877,BLEND_EQUATION_RGB:32777,BLEND_SRC_ALPHA:32971,BLEND_SRC_RGB:32969,BLUE_BITS:3412,BOOL:35670,BOOL_VEC2:35671,BOOL_VEC3:35672,BOOL_VEC4:35673,BROWSER_DEFAULT_WEBGL:37444,BUFFER_SIZE:34660,BUFFER_USAGE:34661,BYTE:5120,CCW:2305,CLAMP_TO_EDGE:33071,COLOR_ATTACHMENT0:36064,COLOR_BUFFER_BIT:16384,COLOR_CLEAR_VALUE:3106,COLOR_WRITEMASK:3107,COMPILE_STATUS:35713,COMPRESSED_TEXTURE_FORMATS:34467,CONSTANT_ALPHA:32771,CONSTANT_COLOR:32769,CONTEXT_LOST_WEBGL:37442,CULL_FACE:2884,CULL_FACE_MODE:2885,CURRENT_PROGRAM:35725,CURRENT_VERTEX_ATTRIB:34342,CW:2304,DECR:7683,DECR_WRAP:34056,DELETE_STATUS:35712,DEPTH_ATTACHMENT:36096,DEPTH_BITS:3414,DEPTH_BUFFER_BIT:256,DEPTH_CLEAR_VALUE:2931,DEPTH_COMPONENT:6402,DEPTH_COMPONENT16:33189,DEPTH_FUNC:2932,DEPTH_RANGE:2928,DEPTH_STENCIL:34041,DEPTH_STENCIL_ATTACHMENT:33306,DEPTH_TEST:2929,DEPTH_WRITEMASK:2930,DITHER:3024,DONT_CARE:4352,DST_ALPHA:772,DST_COLOR:774,DYNAMIC_DRAW:35048,ELEMENT_ARRAY_BUFFER:34963,ELEMENT_ARRAY_BUFFER_BINDING:34965,EQUAL:514,FASTEST:4353,FLOAT:5126,FLOAT_MAT2:35674,FLOAT_MAT3:35675,FLOAT_MAT4:35676,FLOAT_VEC2:35664,FLOAT_VEC3:35665,FLOAT_VEC4:35666,FRAGMENT_SHADER:35632,FRAMEBUFFER:36160,FRAMEBUFFER_ATTACHMENT_OBJECT_NAME:36049,FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE:36048,FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE:36051,FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL:36050,FRAMEBUFFER_BINDING:36006,FRAMEBUFFER_COMPLETE:36053,FRAMEBUFFER_INCOMPLETE_ATTACHMENT:36054,FRAMEBUFFER_INCOMPLETE_DIMENSIONS:36057,FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:36055,FRAMEBUFFER_UNSUPPORTED:36061,FRONT:1028,FRONT_AND_BACK:1032,FRONT_FACE:2886,FUNC_ADD:32774,FUNC_REVERSE_SUBTRACT:32779,FUNC_SUBTRACT:32778,GENERATE_MIPMAP_HINT:33170,GEQUAL:518,GREATER:516,GREEN_BITS:3411,HIGH_FLOAT:36338,HIGH_INT:36341,INCR:7682,INCR_WRAP:34055,INT:5124,INT_VEC2:35667,INT_VEC3:35668,INT_VEC4:35669,INVALID_ENUM:1280,INVALID_FRAMEBUFFER_OPERATION:1286,INVALID_OPERATION:1282,INVALID_VALUE:1281,INVERT:5386,KEEP:7680,LEQUAL:515,LESS:513,LINEAR:9729,LINEAR_MIPMAP_LINEAR:9987,LINEAR_MIPMAP_NEAREST:9985,LINES:1,LINE_LOOP:2,LINE_STRIP:3,LINE_WIDTH:2849,LINK_STATUS:35714,LOW_FLOAT:36336,LOW_INT:36339,LUMINANCE:6409,LUMINANCE_ALPHA:6410,MAX_COMBINED_TEXTURE_IMAGE_UNITS:35661,MAX_CUBE_MAP_TEXTURE_SIZE:34076,MAX_FRAGMENT_UNIFORM_VECTORS:36349,MAX_RENDERBUFFER_SIZE:34024,MAX_TEXTURE_IMAGE_UNITS:34930,MAX_TEXTURE_SIZE:3379,MAX_VARYING_VECTORS:36348,MAX_VERTEX_ATTRIBS:34921,MAX_VERTEX_TEXTURE_IMAGE_UNITS:35660,MAX_VERTEX_UNIFORM_VECTORS:36347,MAX_VIEWPORT_DIMS:3386,MEDIUM_FLOAT:36337,MEDIUM_INT:36340,MIRRORED_REPEAT:33648,NEAREST:9728,NEAREST_MIPMAP_LINEAR:9986,NEAREST_MIPMAP_NEAREST:9984,NEVER:512,NICEST:4354,NONE:0,NOTEQUAL:517,NO_ERROR:0,ONE:1,ONE_MINUS_CONSTANT_ALPHA:32772,ONE_MINUS_CONSTANT_COLOR:32770,ONE_MINUS_DST_ALPHA:773,ONE_MINUS_DST_COLOR:775,ONE_MINUS_SRC_ALPHA:771,ONE_MINUS_SRC_COLOR:769,OUT_OF_MEMORY:1285,PACK_ALIGNMENT:3333,POINTS:0,POLYGON_OFFSET_FACTOR:32824,POLYGON_OFFSET_FILL:32823,POLYGON_OFFSET_UNITS:10752,RED_BITS:3410,RENDERBUFFER:36161,RENDERBUFFER_ALPHA_SIZE:36179,RENDERBUFFER_BINDING:36007,RENDERBUFFER_BLUE_SIZE:36178,RENDERBUFFER_DEPTH_SIZE:36180,RENDERBUFFER_GREEN_SIZE:36177,RENDERBUFFER_HEIGHT:36163,RENDERBUFFER_INTERNAL_FORMAT:36164,RENDERBUFFER_RED_SIZE:36176,RENDERBUFFER_STENCIL_SIZE:36181,RENDERBUFFER_WIDTH:36162,RENDERER:7937,REPEAT:10497,REPLACE:7681,RGB:6407,RGB565:36194,RGB5_A1:32855,RGBA:6408,RGBA4:32854,SAMPLER_2D:35678,SAMPLER_CUBE:35680,SAMPLES:32937,SAMPLE_ALPHA_TO_COVERAGE:32926,SAMPLE_BUFFERS:32936,SAMPLE_COVERAGE:32928,SAMPLE_COVERAGE_INVERT:32939,SAMPLE_COVERAGE_VALUE:32938,SCISSOR_BOX:3088,SCISSOR_TEST:3089,SHADER_TYPE:35663,SHADING_LANGUAGE_VERSION:35724,SHORT:5122,SRC_ALPHA:770,SRC_ALPHA_SATURATE:776,SRC_COLOR:768,STATIC_DRAW:35044,STENCIL_ATTACHMENT:36128,STENCIL_BACK_FAIL:34817,STENCIL_BACK_FUNC:34816,STENCIL_BACK_PASS_DEPTH_FAIL:34818,STENCIL_BACK_PASS_DEPTH_PASS:34819,STENCIL_BACK_REF:36003,STENCIL_BACK_VALUE_MASK:36004,STENCIL_BACK_WRITEMASK:36005,STENCIL_BITS:3415,STENCIL_BUFFER_BIT:1024,STENCIL_CLEAR_VALUE:2961,STENCIL_FAIL:2964,STENCIL_FUNC:2962,STENCIL_INDEX:6401,STENCIL_INDEX8:36168,STENCIL_PASS_DEPTH_FAIL:2965,STENCIL_PASS_DEPTH_PASS:2966,STENCIL_REF:2967,STENCIL_TEST:2960,STENCIL_VALUE_MASK:2963,STENCIL_WRITEMASK:2968,STREAM_DRAW:35040,SUBPIXEL_BITS:3408,TEXTURE:5890,TEXTURE0:33984,TEXTURE1:33985,TEXTURE10:33994,TEXTURE11:33995,TEXTURE12:33996,TEXTURE13:33997,TEXTURE14:33998,TEXTURE15:33999,TEXTURE16:34e3,TEXTURE17:34001,TEXTURE18:34002,TEXTURE19:34003,TEXTURE2:33986,TEXTURE20:34004,TEXTURE21:34005,TEXTURE22:34006,TEXTURE23:34007,TEXTURE24:34008,TEXTURE25:34009,TEXTURE26:34010,TEXTURE27:34011,TEXTURE28:34012,TEXTURE29:34013,TEXTURE3:33987,TEXTURE30:34014,TEXTURE31:34015,TEXTURE4:33988,TEXTURE5:33989,TEXTURE6:33990,TEXTURE7:33991,TEXTURE8:33992,TEXTURE9:33993,TEXTURE_2D:3553,TEXTURE_BINDING_2D:32873,TEXTURE_BINDING_CUBE_MAP:34068,TEXTURE_CUBE_MAP:34067,TEXTURE_CUBE_MAP_NEGATIVE_X:34070,TEXTURE_CUBE_MAP_NEGATIVE_Y:34072,TEXTURE_CUBE_MAP_NEGATIVE_Z:34074,TEXTURE_CUBE_MAP_POSITIVE_X:34069,TEXTURE_CUBE_MAP_POSITIVE_Y:34071,TEXTURE_CUBE_MAP_POSITIVE_Z:34073,TEXTURE_MAG_FILTER:10240,TEXTURE_MIN_FILTER:10241,TEXTURE_WRAP_S:10242,TEXTURE_WRAP_T:10243,TRIANGLES:4,TRIANGLE_FAN:6,TRIANGLE_STRIP:5,UNPACK_ALIGNMENT:3317,UNPACK_COLORSPACE_CONVERSION_WEBGL:37443,UNPACK_FLIP_Y_WEBGL:37440,UNPACK_PREMULTIPLY_ALPHA_WEBGL:37441,UNSIGNED_BYTE:5121,UNSIGNED_INT:5125,UNSIGNED_SHORT:5123,UNSIGNED_SHORT_4_4_4_4:32819,UNSIGNED_SHORT_5_5_5_1:32820,UNSIGNED_SHORT_5_6_5:33635,VALIDATE_STATUS:35715,VENDOR:7936,VERSION:7938,VERTEX_ATTRIB_ARRAY_BUFFER_BINDING:34975,VERTEX_ATTRIB_ARRAY_ENABLED:34338,VERTEX_ATTRIB_ARRAY_NORMALIZED:34922,VERTEX_ATTRIB_ARRAY_POINTER:34373,VERTEX_ATTRIB_ARRAY_SIZE:34339,VERTEX_ATTRIB_ARRAY_STRIDE:34340,VERTEX_ATTRIB_ARRAY_TYPE:34341,VERTEX_SHADER:35633,VIEWPORT:2978,ZERO:0}},10:function(t,e,n){var r=n(698),i=n(4626),o=n(1982),a=n(3503);r.actor=function(){"use strict";if(!(this instanceof r.actor))return new r.actor;r.node.call(this);var t=this,e=a.create(),n=r.boundingObject.ReferenceFrame.Relative,i=null;return this.matrix=function(){return e},this.referenceFrame=function(){return n},this.mapper=function(){return i},this.setMapper=function(e){e!==i&&(i=e,t.boundsModified())},this.computeBounds=function(){if(null!=i){var n,r,a,s,u=t.computeBoundsTimestamp();(t.boundsDirtyTimestamp().getMTime()>u.getMTime()||i.boundsDirtyTimestamp().getMTime()>u.getMTime())&&(i.computeBounds(),r=[(n=i.bounds())[0],n[2],n[4]],a=[n[1],n[3],n[5]],o.transformMat4(r,r,e),o.transformMat4(a,a,e),s=[r[0]>a[0]?a[0]:r[0],r[0]>a[0]?r[0]:a[0],r[1]>a[1]?a[1]:r[1],r[1]>a[1]?r[1]:a[1],r[2]>a[2]?a[2]:r[2],r[2]>a[2]?r[2]:a[2]],t.setBounds(s[0],s[1],s[2],s[3],s[4],s[5]),u.modified())}else t.resetBounds()},t},i(r.actor,r.node)},8576:function(t,e,n){var r=n(698),i=n(4626);r.blendFunction=function(t,e){"use strict";if(!(this instanceof r.blendFunction))return new r.blendFunction(t,e);var n=t,i=e;return this.apply=function(t){t.m_context.blendFuncSeparate(n,i,r.GL.ONE,r.GL.ONE_MINUS_SRC_ALPHA)},this},r.blend=function(){"use strict";if(!(this instanceof r.blend))return new r.blend;r.materialAttribute.call(this,r.materialAttributeType.Blend);var t=!1,e=r.blendFunction(r.GL.SRC_ALPHA,r.GL.ONE_MINUS_SRC_ALPHA);return this.bind=function(n){return t=n.m_context.isEnabled(r.GL.BLEND),this.enabled()?(n.m_context.enable(r.GL.BLEND),e.apply(n)):n.m_context.disable(r.GL.BLEND),!0},this.undoBind=function(e){return t?e.m_context.enable(r.GL.BLEND):e.m_context.disable(r.GL.BLEND),!0},this},i(r.blend,r.materialAttribute)},3556:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.boundingObject=function(){"use strict";if(!(this instanceof r.boundingObject))return new r.boundingObject;r.object.call(this);var t=[0,0,0,0,0,0],e=o(),n=o();return e.modified(),n.modified(),this.bounds=function(){return t},this.hasValidBounds=function(t){return t[0]!==Number.MAX_VALUE&&t[1]!==-Number.MAX_VALUE&&t[2]!==Number.MAX_VALUE&&t[3]!==-Number.MAX_VALUE&&t[4]!==Number.MAX_VALUE&&t[5]!==-Number.MAX_VALUE},this.setBounds=function(n,r,i,o,a,s){if(this.hasValidBounds([n,r,i,o,a,s]))return t[0]=n,t[1]=r,t[2]=i,t[3]=o,t[4]=a,t[5]=s,this.modified(),e.modified(),!0},this.resetBounds=function(){t[0]=Number.MAX_VALUE,t[1]=-Number.MAX_VALUE,t[2]=Number.MAX_VALUE,t[3]=-Number.MAX_VALUE,t[4]=Number.MAX_VALUE,t[5]=-Number.MAX_VALUE,this.modified()},this.computeBounds=function(){},this.computeBoundsTimestamp=function(){return e},this.boundsDirtyTimestamp=function(){return n},this.resetBounds(),this},r.boundingObject.ReferenceFrame={Relative:0,Absolute:1},i(r.boundingObject,r.object)},4580:function(t,e,n){var r=n(698),i=n(4626),o=n(77),a=n(1982),s=n(4663),u=n(3503);r.camera=function(t){"use strict";if(!(this instanceof r.camera))return new r.camera(t);r.groupNode.call(this),t=t||{};var e=30*Math.PI/180,n=s.fromValues(0,0,1,1),i=s.fromValues(0,0,0,1),l=s.fromValues(0,1,0,0),c=1,f=s.fromValues(0,0,-1,0),h=u.create(),d=u.create(),p=o(),m=o(),g=-1,y=1,v=1,x=-1,_={zoom:1,tilesize:256},b=!1,w=[0,0,0,0],M=r.GL.COLOR_BUFFER_BIT|r.GL.DEPTH_BUFFER_BIT;return void 0!==t.parallelProjection&&(b=!!t.parallelProjection),this.setViewAspect=function(t){c=t,this.modified()},this.parallelExtents=function(){return _},this.setParallelExtents=function(t){var e,n,r=["width","height","zoom","tilesize"],i=!1;for(e=0;e<r.length;e+=1)void 0!==t[n=r[e]]&&t[n]!==_[n]&&(_[n]=t[n],i=!0);if(i&&_.width&&_.height&&void 0!==_.zoom&&_.tilesize){var o=this.unitsPerPixel(_.zoom,_.tilesize);y=o*_.width/2,g=-y,v=o*_.height/2,x=-v,this.modified()}},this.unitsPerPixel=function(t,e){return e=e||256,360*Math.pow(2,-t)/e},this.viewMatrix=function(){return this.computeViewMatrix()},this.setViewMatrix=function(t,e){e?h=t.slice():u.copy(h,t),p.modified()},this.projectionMatrix=function(){return this.computeProjectionMatrix()},this.setProjectionMatrix=function(t){u.copy(d,t),m.modified()},this.clearMask=function(){return M},this.clearColor=function(){return w},this.clearDepth=function(){return 1},this.computeDirectionOfProjection=function(){a.subtract(f,i,n),a.normalize(f,f),this.modified()},this.computeViewMatrix=function(){return p.getMTime()<this.getMTime()&&(u.lookAt(h,n,i,l),p.modified()),h},this.computeProjectionMatrix=function(){return m.getMTime()<this.getMTime()&&(b?u.ortho(d,g,y,x,v,.01,1e4):u.perspective(d,e,c,.01,1e4),m.modified()),d},this.computeDirectionOfProjection(),this},i(r.camera,r.groupNode)},7695:function(t,e,n){var r=n(698);r.data=function(){"use strict";if(!(this instanceof r.data))return new r.data;this.type=function(){}},r.data.raster=0,r.data.point=1,r.data.lineString=2,r.data.polygon=3,r.data.geometry=10},4831:function(t,e,n){var r=n(698);r.event={},r.event.keyPress="vgl.event.keyPress",r.event.mousePress="vgl.event.mousePress",r.event.mouseRelease="vgl.event.mouseRelease",r.event.contextMenu="vgl.event.contextMenu",r.event.configure="vgl.event.configure",r.event.enable="vgl.event.enable",r.event.mouseWheel="vgl.event.mouseWheel",r.event.keyRelease="vgl.event.keyRelease",r.event.middleButtonPress="vgl.event.middleButtonPress",r.event.startInteraction="vgl.event.startInteraction",r.event.enter="vgl.event.enter",r.event.rightButtonPress="vgl.event.rightButtonPress",r.event.middleButtonRelease="vgl.event.middleButtonRelease",r.event.char="vgl.event.char",r.event.disable="vgl.event.disable",r.event.endInteraction="vgl.event.endInteraction",r.event.mouseMove="vgl.event.mouseMove",r.event.mouseOut="vgl.event.mouseOut",r.event.expose="vgl.event.expose",r.event.timer="vgl.event.timer",r.event.leftButtonPress="vgl.event.leftButtonPress",r.event.leave="vgl.event.leave",r.event.rightButtonRelease="vgl.event.rightButtonRelease",r.event.leftButtonRelease="vgl.event.leftButtonRelease",r.event.click="vgl.event.click",r.event.dblClick="vgl.event.dblClick"},7327:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.primitive=function(){"use strict";if(!(this instanceof r.primitive))return new r.primitive;var t=0,e=0,n=null;return this.indices=function(){return n},this.numberOfIndices=function(){return n.length},this.primitiveType=function(){return t},this.setPrimitiveType=function(e){t=e},this.indicesValueType=function(){return e},this.setIndicesValueType=function(t){e=t},this.setIndices=function(t){n=new Uint16Array(t)},this},r.triangles=function(){"use strict";return this instanceof r.triangles?(r.primitive.call(this),this.setPrimitiveType(r.GL.TRIANGLES),this.setIndicesValueType(r.GL.UNSIGNED_SHORT),this):new r.triangles},i(r.triangles,r.primitive),r.points=function(){"use strict";return this instanceof r.points?(r.primitive.call(this),this.setPrimitiveType(r.GL.POINTS),this.setIndicesValueType(r.GL.UNSIGNED_SHORT),this):new r.points},i(r.points,r.primitive),r.sourceData=function(t){"use strict";if(!(this instanceof r.sourceData))return new r.sourceData(t);var e={},n=[],i=(t=t||{}).name||"Source "+(new Date).toISOString(),o=function(){this.m_numberOfComponents=0,this.m_dataType=0,this.m_dataTypeSize=0,this.m_normalized=!1,this.m_stride=0,this.m_offset=0};return this.data=function(){return n},this.getData=function(){return this.data()},this.dataToFloat32Array=function(){return n instanceof Float32Array||(n=new Float32Array(n)),n},this.setData=function(t){t instanceof Array||t instanceof Float32Array?n=t instanceof Float32Array?t:t.slice(0):console.log("[error] Requires array")},this.addAttribute=function(t,n,r,i,a,s,u){if(!e.hasOwnProperty(t)){var l=new o;l.m_dataType=n,l.m_dataTypeSize=r,l.m_offset=i,l.m_stride=a,l.m_numberOfComponents=s,l.m_normalized=u,e[t]=l}},this.hasKey=function(t){return e.hasOwnProperty(t)},this.keys=function(){return Object.keys(e)},this.attributeNumberOfComponents=function(t){return e.hasOwnProperty(t)?e[t].m_numberOfComponents:0},this.normalized=function(t){return!!e.hasOwnProperty(t)&&e[t].m_normalized},this.attributeDataType=function(t){if(e.hasOwnProperty(t))return e[t].m_dataType},this.attributeOffset=function(t){return e.hasOwnProperty(t)?e[t].m_offset:0},this.attributeStride=function(t){return e.hasOwnProperty(t)?e[t].m_stride:0},this.pushBack=function(t){},this.insert=function(t){var e;if(!n.length&&t.length&&t instanceof Float32Array)n=t;else if(n.slice||!n.length&&t.slice||(n=Array.prototype.slice.call(n)),t.length)if(!n.length&&t.slice)n=t.slice(0);else for(e=0;e<t.length;e+=1)n[n.length]=t[e];else n[n.length]=t},this.name=function(){return i},this},r.sourceDataAnyfv=function(t,e,n){"use strict";return this instanceof r.sourceDataAnyfv?(r.sourceData.call(this,n),this.addAttribute(e,r.GL.FLOAT,4,0,4*t,t,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataAnyfv(t,e,n)},i(r.sourceDataAnyfv,r.sourceData),r.sourceDataP3fv=function(t){"use strict";return this instanceof r.sourceDataP3fv?(r.sourceData.call(this,t),this.addAttribute(r.vertexAttributeKeys.Position,r.GL.FLOAT,4,0,12,3,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataP3fv(t)},i(r.sourceDataP3fv,r.sourceData),r.sourceDataT2fv=function(t){"use strict";return this instanceof r.sourceDataT2fv?(r.sourceData.call(this,t),this.addAttribute(r.vertexAttributeKeys.TextureCoordinate,r.GL.FLOAT,4,0,8,2,!1),this.pushBack=function(t){this.insert(t)},this):new r.sourceDataT2fv(t)},i(r.sourceDataT2fv,r.sourceData),r.geometryData=function(){"use strict";if(!(this instanceof r.geometryData))return new r.geometryData;r.data.call(this);var t=[],e=[],n=[0,0,0,0,0,0],i=o(),a=o();return this.type=function(){return r.data.geometry},this.name=function(){return""},this.addSource=function(t){return-1===e.indexOf(t)&&(e.push(t),t.hasKey(r.vertexAttributeKeys.Position)&&a.modified(),!0)},this.source=function(t){return t<e.length?e[t]:0},this.sourceByName=function(t){for(var n=0;n<e.length;n+=1)if(e[n].name()===t)return e[n];return 0},this.numberOfSources=function(){return e.length},this.sourceData=function(t){var n;for(n=0;n<e.length;n+=1)if(e[n].hasKey(t))return e[n];return null},this.addPrimitive=function(e){return t.push(e),!0},this.primitive=function(e){return e<t.length?t[e]:null},this.numberOfPrimitives=function(){return t.length},this.bounds=function(){return a.getMTime()>i.getMTime()&&this.computeBounds(),n},this.boundsDirty=function(t){return t&&a.modified(),a.getMTime()>i.getMTime()},this.setBounds=function(t,e,r,o,a,s){return n[0]=t,n[1]=e,n[2]=r,n[3]=o,n[4]=a,n[5]=s,i.modified(),!0},this},i(r.geometryData,r.data)},29:function(t,e,n){var r=n(698),i=n(4626);r.graphicsObject=function(t){"use strict";if(!(this instanceof r.graphicsObject))return new r.graphicsObject;r.object.call(this);return this._setup=function(t){return!1},this._cleanup=function(t){return!1},this},i(r.graphicsObject,r.object)},7616:function(t,e,n){var r=n(698),i=n(4626);r.groupNode=function(){"use strict";if(!(this instanceof r.groupNode))return new r.groupNode;r.node.call(this);var t=[];return this.addChild=function(e){return e instanceof r.node&&(-1===t.indexOf(e)&&(e.setParent(this),t.push(e),this.boundsDirtyTimestamp().modified(),!0))},this.removeChild=function(e){if(e.parent()===this){var n=t.indexOf(e);if(n>=0)return t.splice(n,1),e.setParent(null),this.boundsDirtyTimestamp().modified(),!0}},this.removeChildren=function(){for(;t.length;)this.removeChild(t[0]);this.modified()},this.children=function(){return t},this.hasChild=function(e){var n=0,r=!1;for(n=0;n<t.length;n+=1)if(t[n]===e){r=!0;break}return r},this},i(r.groupNode,r.node)},1611:function(t,e,n){t.exports=n(698),n(6552),n(9156),n(3556),n(9838),n(4831),n(29),n(4970),n(1232),n(2971),n(10),n(7616),n(4580),n(8576),n(7695),n(7327),n(5763),n(5796),n(5794),n(796),n(8888),n(3471),n(4933),n(7205)},9838:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.mapper=function(t){"use strict";if(!(this instanceof r.mapper))return new r.mapper(t);r.boundingObject.call(this);var e=[0,1,1],n=null,i=[],a={},s=void 0!==(t=t||{}).dynamicDraw&&t.dynamicDraw,u=o(),l=null,c=this;function f(t){a={},i=[]}function h(t){c.deleteVertexBufferObjects(t),f(),function(t){if(n){t&&(l=t.m_context);var e,o,c,f,h,d,p,m=n.numberOfSources(),g=null;for(e=0;e<m;e+=1){for(g=l.createBuffer(),l.bindBuffer(r.GL.ARRAY_BUFFER,g),(p=n.source(e).data())instanceof Float32Array||(p=new Float32Array(p)),l.bufferData(r.GL.ARRAY_BUFFER,p,s?r.GL.DYNAMIC_DRAW:r.GL.STATIC_DRAW),f=n.source(e).keys(),h=[],o=0;o<f.length;o+=1)h.push(f[o]);a[e]=h,i[e]=g}for(d=n.numberOfPrimitives(),c=0;c<d;c+=1)g=l.createBuffer(),l.bindBuffer(r.GL.ARRAY_BUFFER,g),l.bufferData(r.GL.ARRAY_BUFFER,n.primitive(c).indices(),r.GL.STATIC_DRAW),i[e]=g,e+=1;u.modified()}}(t)}return this.deleteVertexBufferObjects=function(t){var e,n=l;if(t&&(n=t.m_context),n)for(e=0;e<i.length;e+=1)n.deleteBuffer(i[e])},this._cleanup=function(t){c.deleteVertexBufferObjects(t),f(t),c.modified()},this.computeBounds=function(){if(null!=n){var t=this.computeBoundsTimestamp(),e=null;this.boundsDirtyTimestamp().getMTime()>t.getMTime()&&(e=n.bounds(),this.setBounds(e[0],e[1],e[2],e[3],e[4],e[5]),t.modified())}else this.resetBounds()},this.color=function(){return e},this.geometryData=function(){return n},this.setGeometryData=function(t){n!==t&&(n=t,this.modified(),this.boundsDirtyTimestamp().modified())},this.updateSourceBuffer=function(t,e,o){if(o&&(l=o.m_context),!l)return!1;for(var a=-1,s=0;s<n.numberOfSources();s+=1)if(n.source(s).name()===t){a=s;break}return!(a<0||a>=i.length)&&(e||(e=n.source(s).dataToFloat32Array()),l.bindBuffer(r.GL.ARRAY_BUFFER,i[a]),e instanceof Float32Array?l.bufferSubData(r.GL.ARRAY_BUFFER,0,e):l.bufferSubData(r.GL.ARRAY_BUFFER,0,new Float32Array(e)),!0)},this.getSourceBuffer=function(t){var e=n.sourceByName(t);return e?e.dataToFloat32Array():new Float32Array},this.render=function(t,e){(this.getMTime()>u.getMTime()||t.m_contextChanged)&&h(t),(l=t.m_context).vertexAttrib3fv(r.vertexAttributeKeys.Color,this.color());var o,s,c=0,f=0,d=null;for(o in a)if(a.hasOwnProperty(o)){for(l.bindBuffer(r.GL.ARRAY_BUFFER,i[c]),f=0;f<a[o].length;f+=1)t.m_material.bindVertexData(t,a[o][f]);c+=1}for(s=n.numberOfPrimitives(),f=0;f<s;f+=1,c+=1)if((d=n.primitive(f)).numberOfIndices()){switch(l.bindBuffer(r.GL.ARRAY_BUFFER,i[c]),d.primitiveType()){case r.GL.POINTS:l.drawArrays(r.GL.POINTS,0,d.numberOfIndices());break;case r.GL.LINES:l.drawArrays(r.GL.LINES,0,d.numberOfIndices());break;case r.GL.LINE_STRIP:l.drawArrays(r.GL.LINE_STRIP,0,d.numberOfIndices());break;case r.GL.TRIANGLES:l.drawArrays(r.GL.TRIANGLES,0,d.numberOfIndices());break;case r.GL.TRIANGLE_STRIP:l.drawArrays(r.GL.TRIANGLE_STRIP,0,d.numberOfIndices())}l.bindBuffer(r.GL.ARRAY_BUFFER,null)}e||this.undoBindVertexData(t)},this.undoBindVertexData=function(t){var e,n;for(e in a)if(a.hasOwnProperty(e))for(n=0;n<a[e].length;n+=1)t.m_material.undoBindVertexData(t,a[e][n])},this},i(r.mapper,r.boundingObject)},4970:function(t,e,n){var r=n(698),i=n(4626);r.material=function(){"use strict";if(!(this instanceof r.material))return new r.material;r.graphicsObject.call(this);var t=this,e=new r.shaderProgram,n=100,i={},o={};return this.binNumber=function(){return n},this.setBinNumber=function(e){n=e,t.modified()},this.exists=function(t){return t.type()===r.materialAttributeType.Texture?i.hasOwnProperty(t.textureUnit()):o.hasOwnProperty(t.type())},this.addAttribute=function(n){return!t.exists(n)&&(n.type()===r.materialAttributeType.Texture?(i[n.textureUnit()]=n,t.modified(),!0):(n.type()===r.materialAttributeType.ShaderProgram&&(e=n),o[n.type()]=n,t.modified(),!0))},this.shaderProgram=function(){return e},this._cleanup=function(n){for(var r in o)o.hasOwnProperty(r)&&o[r]._cleanup(n);for(r in i)i.hasOwnProperty(r)&&i[r]._cleanup(n);e._cleanup(n),t.modified()},this.bind=function(t){var n=null;for(n in e.bind(t),o)o.hasOwnProperty(n)&&o[n]!==e&&o[n].bind(t);for(n in i)i.hasOwnProperty(n)&&i[n].bind(t)},this.undoBind=function(t){var e=null;for(e in o)o.hasOwnProperty(e)&&o[e].undoBind(t);for(e in i)i.hasOwnProperty(e)&&i[e].undoBind(t)},this.bindVertexData=function(t,e){var n=null;for(n in o)o.hasOwnProperty(n)&&o[n].bindVertexData(t,e)},this.undoBindVertexData=function(t,e){var n=null;for(n in o)o.hasOwnProperty(n)&&o[n].undoBindVertexData(t,e)},t},r.material.RenderBin={Base:0,Default:100,Opaque:100,Transparent:1e3,Overlay:1e4},i(r.material,r.graphicsObject)},1232:function(t,e,n){var r=n(698),i=n(4626);r.materialAttributeType={Undefined:0,ShaderProgram:1,Texture:2,Blend:3,Depth:4},r.materialAttribute=function(t){"use strict";if(!(this instanceof r.materialAttribute))return new r.materialAttribute(t);r.graphicsObject.call(this);var e=t;return this.type=function(){return e},this.enabled=function(){return true},this.bindVertexData=function(t,e){return!1},this.undoBindVertexData=function(t,e){return!1},this},i(r.materialAttribute,r.graphicsObject)},2971:function(t,e,n){var r=n(698),i=n(4626);r.node=function(){"use strict";if(!(this instanceof r.node))return new r.node;r.boundingObject.call(this);var t=null,e=null,n=!0;return this.material=function(){return e},this.setMaterial=function(t){return t!==e&&(e=t,this.modified(),!0)},this.visible=function(){return n},this.setVisible=function(t){return t!==n&&(n=t,this.modified(),!0)},this.parent=function(){return t},this.setParent=function(e){return e!==t&&(null!==t&&t.removeChild(this),t=e,this.modified(),!0)},this.boundsModified=function(){this.boundsDirtyTimestamp().modified(),null!==t&&t.boundsModified()},this},i(r.node,r.boundingObject)},9156:function(t,e,n){var r=n(698),i=n(77);r.object=function(){"use strict";if(!(this instanceof r.object))return new r.object;var t=i();return t.modified(),this.modified=function(){t.modified()},this.getMTime=function(){return t.getMTime()},this}},5763:function(t,e,n){var r=n(698),i=n(4626);r.renderWindow=function(t){"use strict";if(!(this instanceof r.renderWindow))return new r.renderWindow(t);r.graphicsObject.call(this);var e=this,n=0,i=0,o=400,a=400,s=t,u=null,l=[],c=null;return this.windowSize=function(){return[o,a]},this.windowPosition=function(){return[n,i]},this.renderers=function(){return l},this.activeRenderer=function(){return u},this.addRenderer=function(t){return!1===e.hasRenderer(t)&&(l.push(t),t.setRenderWindow(e),null===u&&(u=t),0!==t.layer()&&t.camera().setClearMask(r.GL.DepthBufferBit),e.modified(),!0)},this.hasRenderer=function(t){var e;for(e=0;e<l.length;e+=1)if(t===l[e])return!0;return!1},this.positionAndResize=function(t,r,s,u){var c;for(n=t,i=r,o=s,a=u,c=0;c<l.length;c+=1)l[c].positionAndResize(n,i,o,a);e.modified()},this._setup=function(t){c=null;try{var e;for(c=s.getContext("webgl")||s.getContext("experimental-webgl"),e=0;e<l.length;e+=1)(l[e].width()>o||0===l[e].width()||l[e].height()>a||0===l[e].height())&&l[e].resize(n,i,o,a);return!0}catch(t){}return c||console("[ERROR] Unable to initialize WebGL. Your browser may not support it."),!1},this.context=function(){return c},this._cleanup=function(t){var n;for(n=0;n<l.length;n+=1)l[n]._cleanup(t);r.clearCachedShaders(t?t.m_context:null),e.modified()},this.render=function(){var t;for(l.sort((function(t,e){return t.layer()-e.layer()})),t=0;t<l.length;t+=1)l[t].render()},e},i(r.renderWindow,r.graphicsObject)},5796:function(t,e,n){var r=n(698),i=n(4626),o=n(3503);r.renderState=function(){"use strict";this.m_context=null,this.m_modelViewMatrix=o.create(),this.m_normalMatrix=o.create(),this.m_projectionMatrix=null,this.m_material=null,this.m_mapper=null},r.renderer=function(t){"use strict";if(!(this instanceof r.renderer))return new r.renderer(t);r.graphicsObject.call(this),t=t||{};var e=this;return e.m_renderWindow=null,e.m_contextChanged=!1,e.m_sceneRoot=new r.groupNode,e.m_camera=new r.camera(t),e.m_nearClippingPlaneTolerance=null,e.m_x=0,e.m_y=0,e.m_width=0,e.m_height=0,e.m_resizable=!0,e.m_resetScene=!0,e.m_layer=0,e.m_renderPasses=null,e.m_resetClippingRange=!0,e.m_depthBits=null,e.m_camera.addChild(e.m_sceneRoot),this.width=function(){return e.m_width},this.height=function(){return e.m_height},this.layer=function(){return e.m_layer},this.setLayer=function(t){e.m_layer=t,e.modified()},this.renderWindow=function(){return e.m_renderWindow},this.setRenderWindow=function(t){e.m_renderWindow!==t&&(e.m_renderWindow&&e.m_renderWindow.removeRenderer(this),e.m_renderWindow=t,e.m_contextChanged=!0,e.modified())},this.camera=function(){return e.m_camera},this.render=function(){var t,n,i,a=null,s=[],u=o.create(),l=null;if((n=new r.renderState).m_renderer=e,n.m_context=e.renderWindow().context(),e.m_depthBits&&!e.m_contextChanged||(e.m_depthBits=n.m_context.getParameter(r.GL.DEPTH_BITS)),n.m_contextChanged=e.m_contextChanged,e.m_renderPasses)for(t=0;t<e.m_renderPasses.length;t+=1){if(e.m_renderPasses[t].render(n))return console.log("returning"),void e.m_renderPasses[t].remove(n);e.m_renderPasses[t].remove(n)}for(n.m_context.enable(r.GL.DEPTH_TEST),n.m_context.depthFunc(r.GL.LEQUAL),e.m_camera.clearMask()&r.GL.COLOR_BUFFER_BIT&&(l=e.m_camera.clearColor(),n.m_context.clearColor(l[0],l[1],l[2],l[3])),e.m_camera.clearMask()&r.GL.DEPTH_BUFFER_BIT&&n.m_context.clearDepth(e.m_camera.clearDepth()),n.m_context.clear(e.m_camera.clearMask()),n.m_context.viewport(e.m_x,e.m_y,e.m_width,e.m_height),(i=e.m_sceneRoot.children()).length>0&&e.m_resetScene&&(e.m_resetScene=!1),t=0;t<i.length;t+=1)(a=i[t]).computeBounds(),a.visible()&&a.material().binNumber()>=0&&s.push([a.material().binNumber(),a]);for(s.sort((function(t,e){return t[0]-e[0]})),t=0;t<s.length;t+=1){if((a=s[t][1]).referenceFrame()===r.boundingObject.ReferenceFrame.Relative){var c=e.m_camera.viewMatrix();c instanceof Array&&(n.m_modelViewMatrix=new Array(16)),o.multiply(n.m_modelViewMatrix,c,a.matrix()),n.m_projectionMatrix=e.m_camera.projectionMatrix(),n.m_modelViewAlignment=e.m_camera.viewAlignment()}else n.m_modelViewMatrix=a.matrix(),n.m_modelViewAlignment=null,n.m_projectionMatrix=o.create(),o.ortho(n.m_projectionMatrix,0,e.m_width,0,e.m_height,-1,1);o.invert(u,n.m_modelViewMatrix),o.transpose(n.m_normalMatrix,u),n.m_material=a.material(),n.m_mapper=a.mapper(),n.m_material.bind(n),n.m_mapper.render(n),n.m_material.undoBind(n)}n.m_context.finish(),e.m_contextChanged=!1,e.m_lastRenderState=n},this.resize=function(t,n){t&&n&&e.positionAndResize(e.m_x,e.m_y,t,n)},this.positionAndResize=function(t,n,r,i){var o;if(t<0||n<0||r<=0||i<=0)console.log("[error] Invalid position and resize values",t,n,r,i);else if(e.m_resizable&&(e.m_width=r,e.m_height=i,e.m_camera.setViewAspect(r/i),e.m_camera.setParallelExtents({width:r,height:i}),e.modified()),e.m_renderPasses)for(o=0;o<e.m_renderPasses.length;o+=1)e.m_renderPasses[o].resize(r,i),e.m_renderPasses[o].renderer().positionAndResize(t,n,r,i)},this.addActor=function(t){return t instanceof r.actor&&(e.m_sceneRoot.addChild(t),e.modified(),!0)},this.hasActor=function(t){return e.m_sceneRoot.hasChild(t)},this.removeActor=function(t){return-1!==e.m_sceneRoot.children().indexOf(t)&&(e.m_lastRenderState&&(t.mapper()&&t.mapper()._cleanup(e.m_lastRenderState),t.material()&&t.material()._cleanup(e.m_lastRenderState)),t.modified(),e.m_sceneRoot.removeChild(t),e.modified(),!0)},this.setResetScene=function(t){e.m_resetScene!==t&&(e.m_resetScene=t,e.modified())},this._cleanup=function(t){for(var n=e.m_sceneRoot.children(),r=0;r<n.length;r+=1){var i=n[r];i.material()._cleanup(t),i.mapper()._cleanup(t)}e.m_sceneRoot.removeChildren(),e.modified()},e},i(r.renderer,r.graphicsObject)},5794:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.shader=function(t){"use strict";if(!(this instanceof r.shader))return new r.shader(t);r.object.call(this);var e=[],n=t,i="";this._getContextEntry=function(t){var n,r,i=t.m_context;for(n=0;n<e.length;n+=1)if(e[n].context===i)return e[n];return r={context:i,compileTimestamp:o()},e.push(r),r},this.removeContext=function(t){var n,r=t.m_context;for(n=0;n<e.length;n+=1)if(e[n].context===r)return void e.splice(n,1)},this.shaderHandle=function(t){return this._getContextEntry(t).shaderHandle},this.setShaderSource=function(t){i=t,this.modified()},this.compile=function(t){var e=this._getContextEntry(t);return this.getMTime()<e.compileTimestamp.getMTime()?e.shaderHandle:(t.m_context.deleteShader(e.shaderHandle),e.shaderHandle=t.m_context.createShader(n),t.m_context.shaderSource(e.shaderHandle,i),t.m_context.compileShader(e.shaderHandle),t.m_context.getShaderParameter(e.shaderHandle,r.GL.COMPILE_STATUS)?(e.compileTimestamp.modified(),e.shaderHandle):(console.log("[ERROR] An error occurred compiling the shaders: "+t.m_context.getShaderInfoLog(e.shaderHandle)),console.log(i),t.m_context.deleteShader(e.shaderHandle),null))},this.attachShader=function(t,e){t.m_context.attachShader(e,this.shaderHandle(t))}},i(r.shader,r.object),function(){"use strict";var t=[];r.getCachedShader=function(e,n,i){for(var o=0;o<t.length;o+=1)if(t[o].type===e&&t[o].context===n&&t[o].source===i)return o&&t.splice(0,0,t.splice(o,1)[0]),t[0].shader;var a=new r.shader(e);return a.setShaderSource(i),t.unshift({type:e,context:n,source:i,shader:a}),t.length>=10&&t.splice(10,t.length-10),a},r.clearCachedShaders=function(e){for(var n=t.length-1;n>=0;n-=1)null!=e&&t[n].context!==e||t.splice(n,1)}}()},796:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.shaderProgram=function(){"use strict";if(!(this instanceof r.shaderProgram))return new r.shaderProgram;r.materialAttribute.call(this,r.materialAttributeType.ShaderProgram);var t=this,e=0,n=o(),i=o(),a=[],s=[],u={},l={},c={};return this.queryUniformLocation=function(t,n){return t.m_context.getUniformLocation(e,n)},this.queryAttributeLocation=function(t,n){return t.m_context.getAttribLocation(e,n)},this.addShader=function(e){if(a.indexOf(e)>-1)return!1;var n;for(n=a.length-2;n>=0;n-=1)a[n].shaderType()===e.shaderType()&&a.splice(n,1);return a.push(e),t.modified(),!0},this.addUniform=function(e){return!(s.indexOf(e)>-1)&&(s.push(e),t.modified(),!0)},this.addVertexAttribute=function(e,n){u[n]=e,t.modified()},this.uniformLocation=function(t){return l[t]},this.attributeLocation=function(t){return c[t]},this.uniform=function(t){var e;for(e=0;e<s.length;e+=1)if(s[e].name()===t)return s[e];return null},this.updateUniforms=function(t){var e;for(e=0;e<s.length;e+=1)s[e].callGL(t,l[s[e].name()])},this.link=function(t){return t.m_context.linkProgram(e),!!t.m_context.getProgramParameter(e,r.GL.LINK_STATUS)||(console.log("[ERROR] Unable to initialize the shader program."),!1)},this.use=function(t){t.m_context.useProgram(e)},this._setup=function(t){0===e&&(e=t.m_context.createProgram())},this._cleanup=function(e){t.deleteVertexAndFragment(e),t.deleteProgram(e),t.modified()},this.deleteProgram=function(t){e&&t.m_context.deleteProgram(e),e=0},this.deleteVertexAndFragment=function(t){var n;for(n=0;n<a.length;n+=1)a[n].shaderHandle(t)&&t.m_context.detachShader(e,a[n].shaderHandle(t)),t.m_context.deleteShader(a[n].shaderHandle(t)),a[n].removeContext(t)},this.compileAndLink=function(r){var i;if(!(n.getMTime()>=this.getMTime())){for(t._setup(r),i=0;i<a.length;i+=1)a[i].compile(r),a[i].attachShader(r,e);t.bindAttributes(r),t.link(r)||(console.log("[ERROR] Failed to link Program"),t._cleanup(r)),n.modified()}},this.bind=function(e){var n=0;for(i.getMTime()<t.getMTime()?(t.compileAndLink(e),t.use(e),t.bindUniforms(e),i.modified()):t.use(e),n=0;n<s.length;n+=1)s[n].update(e,t);t.updateUniforms(e)},this.undoBind=function(t){t.m_context.useProgram(null)},this.bindVertexData=function(t,e){u.hasOwnProperty(e)&&u[e].bindVertexData(t,e)},this.undoBindVertexData=function(t,e){u.hasOwnProperty(e)&&u[e].undoBindVertexData(t,e)},this.bindUniforms=function(t){var e;for(e=0;e<s.length;e+=1)l[s[e].name()]=this.queryUniformLocation(t,s[e].name())},this.bindAttributes=function(t){var n,r;for(n in u)u.hasOwnProperty(n)&&(r=u[n].name(),t.m_context.bindAttribLocation(e,n,r),c[r]=n)},t},i(r.shaderProgram,r.materialAttribute)},8888:function(t,e,n){var r=n(698),i=n(4626),o=n(77);r.texture=function(){"use strict";if(!(this instanceof r.texture))return new r.texture;r.materialAttribute.call(this,r.materialAttributeType.Texture),this.m_width=0,this.m_height=0,this.m_depth=0,this.m_textureHandle=null,this.m_textureUnit=0,this.m_pixelFormat=r.GL.RGBA,this.m_pixelDataType=r.GL.UNSIGNED_BYTE,this.m_internalFormat=r.GL.RGBA,this.m_nearestPixel=!1,this.m_image=null;var t=o(),e=this;function n(t){if(!(e.m_textureUnit>=0&&e.m_textureUnit<32))throw"[error] Texture unit "+e.m_textureUnit+" is not supported";t.m_context.activeTexture(r.GL.TEXTURE0+e.m_textureUnit)}return this.setup=function(e){n(e),e.m_context.deleteTexture(this.m_textureHandle),this.m_textureHandle=e.m_context.createTexture(),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,this.m_nearestPixel?r.GL.NEAREST:r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,this.m_nearestPixel?r.GL.NEAREST:r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_S,r.GL.CLAMP_TO_EDGE),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_T,r.GL.CLAMP_TO_EDGE),null!==this.m_image?(e.m_context.pixelStorei(r.GL.UNPACK_ALIGNMENT,1),e.m_context.pixelStorei(r.GL.UNPACK_FLIP_Y_WEBGL,!0),this.updateDimensions(),this.computeInternalFormatUsingImage(),e.m_context.texImage2D(r.GL.TEXTURE_2D,0,this.m_internalFormat,this.m_pixelFormat,this.m_pixelDataType,this.m_image)):e.m_context.texImage2D(r.GL.TEXTURE_2D,0,this.m_internalFormat,this.m_width,this.m_height,0,this.m_pixelFormat,this.m_pixelDataType,null),e.m_context.bindTexture(r.GL.TEXTURE_2D,null),t.modified()},this.bind=function(e){this.getMTime()>t.getMTime()&&this.setup(e),n(e),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle)},this.undoBind=function(t){t.m_context.bindTexture(r.GL.TEXTURE_2D,null)},this.image=function(){return this.m_image},this.setImage=function(t){return null!==t&&(this.m_image=t,this.updateDimensions(),this.modified(),!0)},this.nearestPixel=function(){return this.m_nearestPixel},this.setNearestPixel=function(t){return(t=!!t)!==this.m_nearestPixel&&(this.m_nearestPixel=t,this.modified(),!0)},this.textureUnit=function(){return this.m_textureUnit},this.setTextureUnit=function(t){return this.m_textureUnit!==t&&(this.m_textureUnit=t,this.modified(),!0)},this.computeInternalFormatUsingImage=function(){this.m_internalFormat=r.GL.RGBA,this.m_pixelFormat=r.GL.RGBA,this.m_pixelDataType=r.GL.UNSIGNED_BYTE},this.updateDimensions=function(){null!==this.m_image&&(this.m_width=this.m_image.width,this.m_height=this.m_image.height,this.m_depth=0)},this.textureHandle=function(){return this.m_textureHandle},this},i(r.texture,r.materialAttribute),r.lookupTable=function(){"use strict";if(!(this instanceof r.lookupTable))return new r.lookupTable;r.texture.call(this);var t=o();return this.m_colorTable=[.07514311,.468049805,1,1,.247872569,.498782363,1,1,.339526309,.528909511,1,1,.409505078,.558608486,1,1,.468487184,.588057293,1,1,.520796675,.617435078,1,1,.568724526,.646924167,1,1,.613686735,.676713218,1,1,.656658579,.707001303,1,1,.698372844,.738002964,1,1,.739424025,.769954435,1,1,.780330104,.803121429,1,1,.821573924,.837809045,1,1,.863634967,.874374691,1,1,.907017747,.913245283,1,1,.936129275,.938743558,.983038586,1,.943467973,.943498599,.943398095,1,.990146732,.928791426,.917447482,1,1,.88332677,.861943246,1,1,.833985467,.803839606,1,1,.788626485,.750707739,1,1,.746206642,.701389973,1,1,.70590052,.654994046,1,1,.667019783,.610806959,1,1,.6289553,.568237474,1,1,.591130233,.526775617,1,1,.552955184,.485962266,1,1,.513776083,.445364274,1,1,.472800903,.404551679,1,1,.428977855,.363073592,1,1,.380759558,.320428137,1,.961891484,.313155629,.265499262,1,.916482116,.236630659,.209939162,1].map((function(t){return 255*t})),this.setup=function(e){0===this.textureUnit()?e.m_context.activeTexture(r.GL.TEXTURE0):1===this.textureUnit()&&e.m_context.activeTexture(r.GL.TEXTURE1),e.m_context.deleteTexture(this.m_textureHandle),this.m_textureHandle=e.m_context.createTexture(),e.m_context.bindTexture(r.GL.TEXTURE_2D,this.m_textureHandle),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,r.GL.LINEAR),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_S,r.GL.CLAMP_TO_EDGE),e.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_WRAP_T,r.GL.CLAMP_TO_EDGE),e.m_context.pixelStorei(r.GL.UNPACK_ALIGNMENT,1),this.m_width=this.m_colorTable.length/4,this.m_height=1,this.m_depth=0,e.m_context.texImage2D(r.GL.TEXTURE_2D,0,r.GL.RGBA,this.m_width,this.m_height,this.m_depth,r.GL.RGBA,r.GL.UNSIGNED_BYTE,new Uint8Array(this.m_colorTable)),e.m_context.bindTexture(r.GL.TEXTURE_2D,null),t.modified()},this.colorTable=function(){return this.m_colorTable},this.setColorTable=function(t){return this.m_colorTable!==t&&(this.m_colorTable=t,this.modified(),!0)},this},i(r.lookupTable,r.texture)},3471:function(t,e,n){var r=n(698),i=n(4626),o=n(3503);r.uniform=function(t,e){"use strict";if(!(this instanceof r.uniform))return new r.uniform(t,e);this.getTypeNumberOfComponents=function(t){switch(t){case r.GL.FLOAT:case r.GL.INT:case r.GL.BOOL:return 1;case r.GL.FLOAT_VEC2:case r.GL.INT_VEC2:case r.GL.BOOL_VEC2:return 2;case r.GL.FLOAT_VEC3:case r.GL.INT_VEC3:case r.GL.BOOL_VEC3:return 3;case r.GL.FLOAT_VEC4:case r.GL.INT_VEC4:case r.GL.BOOL_VEC4:return 4;case r.GL.FLOAT_MAT3:return 9;case r.GL.FLOAT_MAT4:return 16;default:return 0}};var n=t,i=e,o=new Array(this.getTypeNumberOfComponents(n)).fill(0);return this.name=function(){return i},this.set=function(t){var e=0,n=o.length;if(1!==n)for(e=0;e<n;e+=1)o[e]=t[e];else o[0]=t},this.callGL=function(t,e){switch(n){case r.GL.BOOL:case r.GL.INT:t.m_context.uniform1iv(e,o);break;case r.GL.FLOAT:t.m_context.uniform1fv(e,o);break;case r.GL.BOOL_VEC2:case r.GL.INT_VEC2:t.m_context.uniform2iv(e,o);break;case r.GL.FLOAT_VEC2:t.m_context.uniform2fv(e,o);break;case r.GL.BOOL_VEC3:case r.GL.INT_VEC3:t.m_context.uniform3iv(e,o);break;case r.GL.FLOAT_VEC3:t.m_context.uniform3fv(e,o);break;case r.GL.BOOL_VEC4:case r.GL.INT_VEC4:t.m_context.uniform4iv(e,o);break;case r.GL.FLOAT_VEC4:t.m_context.uniform4fv(e,o);break;case r.GL.FLOAT_MAT3:t.m_context.uniformMatrix3fv(e,r.GL.FALSE,o);break;case r.GL.FLOAT_MAT4:t.m_context.uniformMatrix4fv(e,r.GL.FALSE,o)}},this.update=function(t,e){},this},r.modelViewOriginUniform=function(t,e){"use strict";if(!(this instanceof r.modelViewOriginUniform))return new r.modelViewOriginUniform(t,e);t||(t="modelViewMatrix");var n=[(e=e||[0,0,0])[0],e[1],e[2]||0];return r.uniform.call(this,r.GL.FLOAT_MAT4,t),this.set(o.create()),this.setOrigin=function(t){n=[(t=t||[0,0,0])[0],t[1],t[2]||0]},this.update=function(t,e){var r=t.m_modelViewMatrix;if(t.m_modelViewAlignment){var i=t.m_modelViewAlignment;(r=r.slice?r.slice():Array.prototype.slice.call(r))[12]=Math.round(r[12]/i.roundx)*i.roundx+i.dx,r[13]=Math.round(r[13]/i.roundy)*i.roundy+i.dy}r=o.translate(o.create(),r,n),this.set(r)},this},i(r.modelViewOriginUniform,r.uniform),r.projectionUniform=function(t){"use strict";return this instanceof r.projectionUniform?(t||(t="projectionMatrix"),r.uniform.call(this,r.GL.FLOAT_MAT4,t),this.set(o.create()),this.update=function(t,e){this.set(t.m_projectionMatrix)},this):new r.projectionUniform(t)},i(r.projectionUniform,r.uniform),r.floatUniform=function(t,e){"use strict";if(!(this instanceof r.floatUniform))return new r.floatUniform(t,e);t||(t="floatUniform"),e=void 0===e?1:e,r.uniform.call(this,r.GL.FLOAT,t),this.set(e)},i(r.floatUniform,r.uniform)},4933:function(t,e,n){var r=n(698);r.vertexAttributeKeys={Position:0,Normal:1,TextureCoordinate:2,Color:3,Scalar:4,CountAttributeIndex:5},r.vertexAttributeKeysIndexed={Zero:0,One:1,Two:2,Three:3,Four:4,Five:5,Six:6,Seven:7,Eight:8,Nine:9},r.vertexAttribute=function(t){"use strict";if(!(this instanceof r.vertexAttribute))return new r.vertexAttribute(t);var e=t;this.name=function(){return e},this.bindVertexData=function(t,n){var r=t.m_mapper.geometryData().sourceData(n),i=t.m_material.shaderProgram();t.m_context.vertexAttribPointer(i.attributeLocation(e),r.attributeNumberOfComponents(n),r.attributeDataType(n),r.normalized(n),r.attributeStride(n),r.attributeOffset(n)),t.m_context.enableVertexAttribArray(i.attributeLocation(e))},this.undoBindVertexData=function(t,n){var r=t.m_material.shaderProgram();t.m_context.disableVertexAttribArray(r.attributeLocation(e))}}},698:function(t){t.exports={}},7205:function(t,e,n){var r=n(5616),i=n(698),o=n(4626);i.viewer=function(t,e){"use strict";if(!(this instanceof i.viewer))return new i.viewer(t,e);i.object.call(this);var n=t,o=i.renderer(e),a=i.renderWindow(n);return this.canvas=function(){return n},this.renderWindow=function(){return a},this.init=function(){null!==a?a._setup():console.log("[ERROR] No render window attached")},this.exit=function(t){null!==a?a._cleanup(t):console.log("[ERROR] No render window attached")},this.render=function(){a.render()},this.bindEventHandlers=function(){r(n).on("mousedown",this.handleMouseDown),r(n).on("mouseup",this.handleMouseUp),r(n).on("mousemove",this.handleMouseMove),r(n).on("mousewheel",this.handleMouseWheel),r(n).on("contextmenu",this.handleContextMenu)},this.unbindEventHandlers=function(){r(n).off("mousedown",this.handleMouseDown),r(n).off("mouseup",this.handleMouseUp),r(n).off("mousemove",this.handleMouseMove),r(n).off("mousewheel",this.handleMouseWheel),r(n).off("contextmenu",this.handleContextMenu)},this._init=function(){this.bindEventHandlers(),a.addRenderer(o)},this._init(),this},o(i.viewer,i.object)},394:function(t,e,n){t.exports={pointFeature:n(5380),vtkjsRenderer:n(9897)}},7015:function(t,e,n){var r=function(t){"use strict";if(!(this instanceof n(1338)))return new r(t);var e=this,i=this.draw;return this.draw=function(){return e.ready&&(e._update(),e.renderer()._render(),i()),e},this};t.exports=r},5380:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7541),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(5325),r=n(7015),i=n(9897).vtkjs,s=i.Rendering.Core.vtkActor,u=i.Common.Core.vtkDataArray,l=i.Rendering.Core.vtkGlyph3DMapper,c=i.Rendering.Core.vtkMapper,f=i.Common.DataModel.vtkPointSet,h=i.Filters.Sources.vtkSphereSource;r.call(this);var d,p,m,g,y,v=this,x=this._init,_=this._exit,b=this._update;return this._createPipeline=function(){p=f.newInstance(),(m=h.newInstance()).setThetaResolution(30),m.setPhiResolution(30);var t=l.newInstance({orient:!1,colorByArrayName:"color",scalarMode:c.ScalarMode.USE_POINT_FIELD_DATA,colorMode:c.ColorMode.DIRECT_SCALARS,scaling:!0,scaleArray:"diam",scaleMode:l.ScaleModes.SCALE_BY_MAGNITUDE});t.setInputData(p,0),t.setInputConnection(m.getOutputPort(),1),(d=s.newInstance()).setMapper(t),d.getProperty().setAmbient(1),v.renderer().contextRenderer().addActor(d)},this._init=function(){x.call(v,t),v.renderer().contextRenderer().setLayer(0),v._createPipeline()},this._build=function(){var t,n,r,i,o,a,s=v.data().length,l=new Array(3*s),c=v.data(),f=v.position(),h=v.style.get("radius"),d=v.style.get("fill"),m=v.style.get("fillColor"),x=v.style.get("fillOpacity"),_=v.layer().map().unitsPerPixel(v.layer().map().zoom());for(y&&y.length===s||(y=new Float32Array(s)),g&&g.length===4*s||(g=new Uint8Array(4*s)),t=n=r=0;t<s;t+=1,n+=3,r+=4)i=f(c[t],t),l[n]=i.x,l[n+1]=i.y,l[n+2]=i.z||0,a=a||l[n+2],y[t]=h(c[t],t)*_*2,o=m(c[t],t),g[r]=255*o.r,g[r+1]=255*o.g,g[r+2]=255*o.b,g[r+3]=d(c[t],t)?255*x(c[t],t):0;if(l=e.transformCoordinates(v.gcs(),v.layer().map().gcs(),l,3),!a&&v.gcs()!==v.layer().map().gcs())for(t=n=0;t<s;t+=1,n+=3)l[n+2]=0;p.getPoints().setData(l,3),p.getPointData().addArray(u.newInstance({name:"color",values:g,numberOfComponents:4})),p.getPointData().addArray(u.newInstance({name:"diam",values:y})),v.buildTime().modified()},this._update=function(){if(b.call(v),v.dataTime().getMTime()>=v.buildTime().getMTime()||v.updateTime().getMTime()<v.getMTime())v._build();else{var t=v.data(),e=v.style.get("radius"),n=v.layer().map().unitsPerPixel(v.layer().map().zoom()),r=p.getPointData().getArray("diam"),i=r.getData().map((function(r,i){return e(t[i],i)*n*2}));r.setData(i),p.modified()}v.updateTime().modified()},this._exit=function(){v.renderer().contextRenderer().removeActor(d),_()},v._init(),this};r(a,o);var s={};s[o.capabilities.stroke]=!1,i("vtkjs","point",a,s),t.exports=a},9897:function(t,e,n){var r=n(4626),i=n(1098).registerRenderer,o=n(2274),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(3503),r=n(6409),i=a.vtkjs.Rendering.Misc.vtkGenericRenderWindow,s=this,u=this._init,l=i.newInstance({background:[0,0,0,0]});l.setContainer(s.layer().node().get(0)),l.getInteractor().unbindEvents(),l.resize();var c=l.getRenderer(),f=l.getRenderWindow();return this.contextRenderer=function(){return c},this.api=function(){return a.apiname},this._init=function(){if(s.initialized())return s;u.call(s);var t=s.layer().map(),e=t.size();return s._resize(0,0,e.width,e.height),t.camera().clipbounds={near:-t.unitsPerPixel(),far:t.unitsPerPixel()},s},this._resize=function(t,e,n,r){return s._setWidthHeight(n,r),l.resize(),s._render(),s},this._render=function(){return s.layer().map().scheduleAnimationFrame(s._renderFrame,!0),s},this._renderFrame=function(){var t,e=s.layer().features();for(t=0;t<e.length;t+=1)e[t].visible()&&e[t]._update();s._updateRendererCamera(),f.render()},this._exit=function(){},this._updateRendererCamera=function(){var t=s.layer().map().camera(),n=t.view,r=t.projectionMatrix,i=e.create();e.copy(i,n);var o=e.create();e.copy(o,r),s.contextRenderer().getActiveCamera().setViewMatrix(i),s.contextRenderer().getActiveCamera().setProjectionMatrix(o)},s.layer().geoOn(r.pan,(function(t){s._render()})),s.layer().geoOn(r.parallelprojection,(function(t){})),this};a.apiname="vtkjs",r(a,o),i("vtkjs",a),a.supported=function(){delete a.vtkjs;try{a.vtkjs=n(4436)}catch(t){}return a.vtkjs&&a.vtkjs.Rendering||!window.vtk||!window.vtk.Rendering||(a.vtkjs=window.vtk),a.vtkjs&&a.vtkjs.Rendering||(a.vtkjs=void 0),void 0!==a.vtkjs},a.fallback=function(){return null},a.supported(),t.exports=a},3559:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3561),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=this,n=null,r=this._exit,i=this.draw,s=this._update;return this.draw=function(){if(e._update(),n)for(var t=0;t<n.length;t+=1)n[t].draw();return i(),e},this._build=function(){return e.buildTime().modified(),n=e.createChoropleth()},this._update=function(){s.call(e),(e.dataTime().timestamp()>=e.buildTime().timestamp()||e.updateTime().timestamp()<=e.timestamp())&&(e._wipePolygons(),e._build()),e.updateTime().modified()},this._wipePolygons=function(){n&&n.map((function(t){return t._exit()})),n=null},this._exit=function(){e._wipePolygons(),r()},this._init(t),this};r(a,o),i("webgl","choropleth",a),t.exports=a},6791:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6761),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t),n(2778).call(this,t);var e=this;return this._build=function(){e.actors()[0]&&e.renderer().contextRenderer().removeActor(e.actors()[0]),e.createGLMeshColored(e._createContours()),e.renderer().contextRenderer().addActor(e.actors()[0]),e.buildTime().modified()},this._init(t),this};r(a,o),i("webgl","contour",a),t.exports=a},8257:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2499),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t),n(2778).call(this,t);var e=this;return this._build=function(){e.actors()[0]&&e.renderer().contextRenderer().removeActor(e.actors()[0]),e.createGLMeshColored(e._createGrids()),e.renderer().contextRenderer().addActor(e.actors()[0]),e.buildTime().modified()},this._init(t),this};r(a,o),i("webgl","grid",a),t.exports=a},8635:function(t,e,n){t.exports={choroplethFeature:n(3559),contourFeature:n(6791),gridFeature:n(8257),isolineFeature:n(960),layer:n(6982),lineFeature:n(5795),lookupTable2D:n(411),markerFeature:n(3403),meshColored:n(2778),pixelmapFeature:n(7759),pointFeature:n(5407),polygonFeature:n(8511),quadFeature:n(9304),tileLayer:n(1474),trackFeature:n(536),webglRenderer:n(7945)}},960:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(2586),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(4084).call(this),this._init(t),this):new a(t)};r(a,o),i("webgl","isoline",a),t.exports=a},6982:function(t,e,n){var r=function(){"use strict";var t=n(1098).createRenderer,e=n(6409),r=n(7945),i=n(9264),o=this,a=this._init,s=this.opacity,u=this.visible,l=this.zIndex;this.opacity=function(t){var e=s.apply(o,arguments);return void 0!==t&&o.initialized()&&o.map()._updateAutoshareRenderers(),e},this.visible=function(t){if(void 0===t)return u();var e=u(),n=u.apply(o,arguments);return e!==t&&o.initialized()&&(o.map().scheduleAnimationFrame(o._update,!0),o.renderer()._render()),n},this.zIndex=function(t,e){var n=l.apply(o,arguments);return void 0!==t&&o.initialized()&&(o.map().scheduleAnimationFrame(o._update,!0),o.renderer()._render(),o.map()._updateAutoshareRenderers()),n},this.switchRenderer=function(t,e){if(t instanceof r&&t!==o.renderer()){var n=o.renderer(),i=[],a=[];o.map().listSceneObjects([o]).forEach((function(t){t._cleanup&&(t._cleanup(),t._update&&a.push(t)),t.actors&&(i=i.concat(t.actors()))})),i.forEach((function(e){n.contextRenderer().removeActor(e),t.contextRenderer().addActor(e)})),o._renderer(t),o._canvas(t.canvas()),e&&(i.length||a.length)&&(n._render(),a.forEach((function(t){t._update()})),t._render())}return o},this._init=function(){var n=o.map();return n._updateAutoshareRenderers||(n._updateAutoshareRenderers=function(){var e,o,a,s=n.sortedLayers(),u=[];s.forEach((function(n){var s=n.autoshareRenderer(),l=n instanceof i;s&&n.renderer()&&n.renderer().api()===r.apiname?!e||n.opacity()!==o||"more"!==s&&(n.opacity()>0&&n.opacity()<1||l&&!a)?(n.node()[0].contains(n.renderer().canvas()[0])||(n.switchRenderer(t(r.apiname,n),!1),u.push(n.renderer())),e=n.renderer(),o=n.opacity(),a=l):(n.renderer()!==e&&(u.push(n.renderer()),n.switchRenderer(e,!1),u.push(n.renderer())),a&=l):e=null})),s.forEach((function(t){u.indexOf(t.renderer())>=0&&t._update&&t._update()})),s.forEach((function(t){u.indexOf(t.renderer())>=0&&(t.renderer()._renderFrame(),u=u.filter((function(e){return e!==t.renderer()})))})),u.forEach((function(t){t._exit()}))},n.geoOn(e.layerAdd,(function(){return n._updateAutoshareRenderers()})),n.geoOn(e.layerRemove,(function(){return n._updateAutoshareRenderers()}))),a.apply(o,arguments)}};(0,n(1098).registerLayerAdjustment)("webgl","all",r),t.exports=r},5795:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(9281),a=0,s=1,u=3,l={butt:0,square:1,round:2},c={passthrough:3,miter:4,bevel:5,round:6,"miter-clip":7},f={normal:0,debug:1},h=function(t){"use strict";if(!(this instanceof h))return new h(t);t=t||{},o.call(this,t);var e=n(1611),r=n(5325),i=n(642),d=n(4084),p=n(5685),m=n(1388),g=n(9336);d.call(this);var y,v,x,_,b,w,M,A,T,E,C,k=this,S=this._exit,O=void 0!==t.dynamicDraw&&t.dynamicDraw,P=this._init,L=this._update;return this.featureVertices=function(){return[[0,"corner",-1,a],[0,"near",1,s],[1,"far",-1,u],[1,"corner",1,a],[1,"near",-1,s],[0,"far",1,u]]},this.verticesPerFeature=function(){return k.featureVertices().length},this._init=function(t){var n,r=e.shaderProgram(),i=((n=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(g),n),o=function(t){var n=new e.shader(e.GL.FRAGMENT_SHADER);return n.setShaderSource(t?m:p),n}(void 0!==((t||{}).style||{}).debug),a=e.vertexAttribute("pos"),s=e.vertexAttribute("prev"),u=e.vertexAttribute("next"),l=e.vertexAttribute("far"),c=e.vertexAttribute("flags"),f=e.vertexAttribute("strokeWidth"),h=e.vertexAttribute("strokeColor"),d=e.vertexAttribute("strokeOpacity"),T=new e.projectionUniform("projectionMatrix"),E=e.geometryData(),S=e.sourceDataP3fv({name:"pos"}),L=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Four,{name:"prev"}),R=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Five,{name:"next"}),I=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Six,{name:"far"}),D=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Seven,{name:"flags"}),N=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.One,{name:"strokeWidth"}),F=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Two,{name:"strokeColor"}),j=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"strokeOpacity"}),z=e.triangles();return C=new e.modelViewOriginUniform("modelViewMatrix"),_=new e.floatUniform("pixelWidth",1/k.renderer().width()),b=new e.floatUniform("aspect",k.renderer().width()/k.renderer().height()),w=new e.floatUniform("miterLimit",10),M=new e.floatUniform("antialiasing",0),A=new e.floatUniform("fixedFlags",0),P.call(k,t),x=e.material(),v=e.mapper({dynamicDraw:O}),r.addVertexAttribute(a,e.vertexAttributeKeys.Position),r.addVertexAttribute(f,e.vertexAttributeKeysIndexed.One),r.addVertexAttribute(h,e.vertexAttributeKeysIndexed.Two),r.addVertexAttribute(d,e.vertexAttributeKeysIndexed.Three),r.addVertexAttribute(s,e.vertexAttributeKeysIndexed.Four),r.addVertexAttribute(u,e.vertexAttributeKeysIndexed.Five),r.addVertexAttribute(l,e.vertexAttributeKeysIndexed.Six),r.addVertexAttribute(c,e.vertexAttributeKeysIndexed.Seven),r.addUniform(C),r.addUniform(T),r.addUniform(_),r.addUniform(b),r.addUniform(w),r.addUniform(M),r.addUniform(A),r.addShader(o),r.addShader(i),x.addAttribute(r),x.addAttribute(e.blend()),(y=e.actor()).setMaterial(x),y.setMapper(v),E.addSource(S),E.addSource(L),E.addSource(R),E.addSource(I),E.addSource(N),E.addSource(F),E.addSource(j),E.addSource(D),z.setIndices(new Uint16Array(1)),E.addPrimitive(z),E.computeBounds=function(){E.setBounds(0,0,0,0,0,0)},v.setGeometryData(E),k},this.actors=function(){return y?[y]:[]},this._build=function(){return function(t){var e,n,o,a,s,u,h,d,p,m,g,y,x,_,b,S,O,P,L,R,I,D,N,F,j,z,B,V,q,G,U,H,W,X,K,Q,Y,$,Z,J,tt=k.data(),et=0,nt=[{strokeOffset:0,posStrokeOffset:0,negStrokeOffset:0},{strokeOffset:0,posStrokeOffset:0,negStrokeOffset:0}],rt=nt[1],it=k.gcs(),ot=k.layer().map().gcs(),at=k.line(),st=k.style.get("strokeWidth"),ut=k.style.get("strokeColor"),lt=k.style.get("strokeOpacity"),ct=k.style.get("lineCap"),ft=k.style.get("lineJoin"),ht=k.style.get("strokeOffset"),dt=k.style.get("miterLimit")(tt),pt=k.style.get("antialiasing")(tt)||0,mt=k.style.get("uniformLine"),gt=k.featureVertices(),yt=gt.length,vt=f[k.style.get("debug")(tt)?"debug":"normal"]||0,xt=v.geometryData(),_t=k.style.get("closed"),bt=!0;if(Z=i.isFunction(k.style("closed"))?void 0:_t()||!1,R=i.isFunction(k.style("lineCap"))?void 0:l[ct()||"butt"],I=i.isFunction(k.style("lineJoin"))?void 0:c[ft()||"miter"],P=i.isFunction(k.style("strokeColor"))?void 0:ut(),D=i.isFunction(k.style("strokeOffset"))?void 0:ht()||0,L=i.isFunction(k.style("strokeOpacity"))?void 0:lt(),O=i.isFunction(k.style("strokeWidth"))?void 0:st(),N=i.isFunction(k.style("uniformLine"))?void 0:mt(),void 0!==dt&&w.set(Math.max(1,Math.min(100,dt))),A.set(vt),M.set(pt),t)et=T.numSegments,J=T.closed,m=T.lineItemList,p=et*yt,bt=R!==T.lineCapVal||void 0===R||I!==T.lineJoinVal||void 0===I||D!==T.strokeOffsetVal||void 0===D;else{var wt=[],Mt=k.position();for(Mt=Mt===i.identityFunction?null:Mt,m=new Array(tt.length),J=new Array(tt.length),n=0;n<tt.length;n+=1)if(g=at(e=tt[n],n),m[n]=g,!(g.length<2)){for(et+=g.length-1,o=0;o<g.length;o+=1)x=Mt?Mt(g[o],o,e,n):g[o],wt.push(x.x),wt.push(x.y),wt.push(x.z||0),o||(b=x);g.length>2&&(void 0===Z?_t(e,n):Z)?x.x!==b.x||x.y!==b.y||x.z!==b.z?(et+=1,J[n]=2):J[n]=1:J[n]=0}if(wt=r.transformCoordinates(it,ot,wt,3),(E=new Float32Array(k.style.get("origin")(wt)))[0]||E[1]||E[2])for(n=0;n<wt.length;n+=3)wt[n]-=E[0],wt[n+1]-=E[1],wt[n+2]-=E[2];C.setOrigin(E),p=et*yt,q=i.getGeomBuffer(xt,"pos",3*p),G=i.getGeomBuffer(xt,"prev",3*p),U=i.getGeomBuffer(xt,"next",3*p),H=i.getGeomBuffer(xt,"far",3*p),xt.primitive(0).numberOfIndices()!==p&&(xt.primitive(0).numberOfIndices=function(){return p}),T={numSegments:et,closed:J,lineItemList:m,lineCapVal:R,lineJoinVal:I,strokeOffsetVal:D}}for(W=i.getGeomBuffer(xt,"flags",p),X=i.getGeomBuffer(xt,"strokeWidth",p),K=i.getGeomBuffer(xt,"strokeColor",3*p),Q=i.getGeomBuffer(xt,"strokeOpacity",p),n=_=Y=$=0;n<tt.length;n+=1)if(!((g=m[n]).length<2)){F=void 0===N?mt(g,n):N,e=tt[n],Z=J[n],S=_,d=g.length+(2===Z?1:0);var At=0;for(o=0;o<d;o+=1,_+=3)if(h=o,o===g.length&&(h=0,_-=3),y=g[h],o&&(rt=nt[0],nt[0]=nt[1],nt[1]=rt),t||(rt.pos=o===h?_:S,rt.prev=h?_-3:Z?S+3*(g.length-3+Z):_,rt.next=o+1<g.length?_+3:Z?o!==h?S+3:S+6-3*Z:_),F&&o>0?1===o&&(rt.strokeWidth=nt[0].strokeWidth,rt.strokeColor=nt[0].strokeColor,rt.strokeOpacity=nt[0].strokeOpacity):(rt.strokeWidth=void 0===O?st(y,h,e,n):O,rt.strokeColor=void 0===P?ut(y,h,e,n):P,rt.strokeOpacity=void 0===L?lt(y,h,e,n):L),bt&&(0!==D&&(F&&o>0?1===o&&(rt.strokeOffset=nt[0].strokeOffset):rt.strokeOffset=(void 0===D?ht(y,h,e,n):D)||0,rt.strokeOffset?(rt.posStrokeOffset=2047&Math.round(2048+1023*Math.min(1,Math.max(-1,rt.strokeOffset))),rt.negStrokeOffset=2047&Math.round(2048-1023*Math.min(1,Math.max(-1,rt.strokeOffset)))):rt.posStrokeOffset=rt.negStrokeOffset=0),Z||o&&o!==g.length-1?rt.flags=void 0===I?c[ft(y,h,e,n)]||c.miter:I:rt.flags=void 0===R?l[ct(y,h,e,n)]||l.butt:R),o){if("drop"===F&&o>1&&wt[nt[0].pos]===wt[nt[1].pos]&&wt[nt[0].pos+1]===wt[nt[1].pos+1]){At+=1;continue}for(a=0;a<yt;a+=1,Y+=1,$+=3)"drop"===F&&nt[0].strokeOpacity<=0&&nt[1].strokeOpacity<=0?Q[Y]=-1:(s=nt[j=gt[a][0]],u=nt[1-j],t||(q[$]=wt[s.pos],q[$+1]=wt[s.pos+1],q[$+2]=0,z=j?"next":"prev",B=j?"prev":"next",G[$]=wt[s[z]],G[$+1]=wt[s[z]+1],G[$+2]=0,U[$]=wt[s[B]],U[$+1]=wt[s[B]+1],U[$+2]=0,H[$]=wt[u[B]],H[$+1]=wt[u[B]+1],H[$+2]=0),bt&&(V=j?"posStrokeOffset":"negStrokeOffset",W[Y]=gt[a][3]+4*s.flags+32*u.flags+256*s[V]),X[Y]=s.strokeWidth,K[$]=s.strokeColor.r,K[$+1]=s.strokeColor.g,K[$+2]=s.strokeColor.b,s.strokeOpacity<=0&&u.strokeOpacity<=0||s.strokeWidth<=0&&u.strokeWidth<=0?Q[Y]=-1:Q[Y]=s.strokeOpacity)}if(At)for(a=0;a<At*yt;a+=1,Y+=1,$+=3)Q[Y]=-1}t?(bt&&v.updateSourceBuffer("flags"),v.updateSourceBuffer("strokeWidth"),v.updateSourceBuffer("strokeOpacity"),v.updateSourceBuffer("strokeColor")):(v.modified(),xt.boundsDirty(!0),v.boundsDirtyTimestamp().modified())}(!!(k.dataTime().timestamp()<k.buildTime().timestamp()&&T)),k.renderer().contextRenderer().hasActor(y)||k.renderer().contextRenderer().addActor(y),k.buildTime().modified(),k},this._update=function(){return L.call(k),(k.dataTime().timestamp()>=k.buildTime().timestamp()||k.updateTime().timestamp()<=k.timestamp())&&k._build(),_.set(1/k.renderer().width()),b.set(k.renderer().width()/k.renderer().height()),y.setVisible(k.visible()),y.material().setBinNumber(k.bin()),k.updateTime().modified(),k},this._exit=function(){k.renderer().contextRenderer().removeActor(y),y=null,S()},this._init(t),this};r(h,o);var d={};d[o.capabilities.basic]=!0,d[o.capabilities.multicolor]=!0,i("webgl","line",h,d),t.exports=h},411:function(t,e,n){var r=n(4626),i=n(77),o=n(1611);var a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.texture.call(this);var e,n=i(),r=t.maxWidth||4096,s=new Uint8Array([0,0,0,0]),u=this;return this.setup=function(t){!function(t,e){if(!(e>=0&&e<=31))throw Error("[error] Texture unit "+e+" is not supported");t.m_context.activeTexture(o.GL.TEXTURE0+e)}(t,u.textureUnit()),t.m_context.deleteTexture(u.m_textureHandle),u.m_textureHandle=t.m_context.createTexture(),t.m_context.bindTexture(o.GL.TEXTURE_2D,u.m_textureHandle),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_MIN_FILTER,o.GL.NEAREST),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_MAG_FILTER,o.GL.NEAREST),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_WRAP_S,o.GL.CLAMP_TO_EDGE),t.m_context.texParameteri(o.GL.TEXTURE_2D,o.GL.TEXTURE_WRAP_T,o.GL.CLAMP_TO_EDGE),t.m_context.pixelStorei(o.GL.UNPACK_ALIGNMENT,1),t.m_context.pixelStorei(o.GL.UNPACK_FLIP_Y_WEBGL,!0),t.m_context.texImage2D(o.GL.TEXTURE_2D,0,o.GL.RGBA,u.width,u.height,0,o.GL.RGBA,o.GL.UNSIGNED_BYTE,s),t.m_context.bindTexture(o.GL.TEXTURE_2D,null),n.modified()},this.colorTable=function(t){return void 0===t?e:(e=t,t.length<4&&(t=[0,0,0,0]),u.width=Math.min(r,t.length/4),u.height=Math.ceil(t.length/4/r),t instanceof Uint8Array&&t.length===u.width*u.height*4?s=t:(t.length<u.width*u.height*4&&(t=t.concat(new Array(u.width*u.height*4-t.length).fill(0))),s=new Uint8Array(t)),u.modified(),u)},this.maxWidth=function(){return r},this.colorTable(t.colorTable||[]),this};r(a,o.texture),t.exports=a},3403:function(t,e,n){var r=n(5616),i=n(4626),o=n(1098).registerFeature,a=n(2225),s=n(7945),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},a.call(this,t);var e=n(1611),i=n(5325),o=n(642),l=n(4084),c=n(2709),f=n(6409),h=n(9923),d=n(3724),p=n(1202),m=n(7665);l.call(this);var g,y,v=this,x=this._exit,_=null,b=null,w={},M=this._init,A=this._update,T=this.updateStyleFromArray;function E(t){var e,n,r,u,l,c,f,h,d,p,m,x,w,M=v.data().length,A=v._pointPolygon(0,0,1,1),T=new Array(3*M),C={},k={},S={},O={},P={radius:1,fillColor:3,fillOpacity:1,strokeColor:3,strokeOpacity:1,strokeOffset:0,strokeWidth:1,symbol:1,symbolValue:1,rotation:1,scaleWithZoom:0,rotateWithMap:0,radiusIncludesStroke:0},L=v.verticesPerFeature(),R=v.data(),I=b.geometryData();for(var D in l=v.position(),P)S[D]=v.style.get(D),o.isFunction(v.style(D))||(O[D]=S[D]()),P[D]&&(C[D]=o.getGeomBuffer(I,D,L*M*P[D]));if(!t){for(e=x=0;e<M;e+=1,x+=3)u=l(R[e],e),T[x]=u.x,T[x+1]=u.y,T[x+2]=0;if(T=i.transformCoordinates(v.gcs(),v.layer().map().gcs(),T,3),(y=new Float32Array(v.style.get("origin")(T)))[0]||y[1]||y[2])for(e=x=0;e<M;e+=1,x+=3)T[x]-=y[0],T[x+1]-=y[1],T[x+2]-=y[2];g.setOrigin(y),r=o.getGeomBuffer(I,"pos",L*M*3),v._primitiveShape!==a.primitiveShapes.sprite&&(f=o.getGeomBuffer(I,"unit",L*M*2)),(c=I.primitive(0).indices())instanceof Uint16Array&&c.length===L*M||(c=new Uint16Array(L*M),I.primitive(0).setIndices(c))}for(e=d=p=m=x=0;e<M;e+=1,x+=3){if(h=R[e],!t&&v._primitiveShape!==a.primitiveShapes.sprite)for(n=0;n<A.length;n+=1,m+=1)f[m]=A[n];for(var N in P)k[N]=void 0===O[N]?S[N](h,e):O[N];for(k.scaleWithZoom=a.scaleMode[k.scaleWithZoom]||(k.scaleWithZoom>=1&&k.scaleWithZoom<=3?k.scaleWithZoom:0),k.symbolComputed=k.scaleWithZoom+(k.rotateWithMap?4:0)+16*(Math.sign(void 0!==k.radiusIncludesStroke&&k.radiusIncludesStroke?k.strokeOffset:1)+1)+64*k.symbol,k.symbolValue&&k.symbol>=a.symbols.arrow&&k.symbol<a.symbols.arrow+a.symbols.arrowMax&&(k.symbolValue=(w=k.symbolValue).length?((void 0===w[0]?0:Math.floor(250*Math.abs(w[0]))+1)+252*(void 0===w[1]?0:Math.floor(250*Math.abs(w[1]))+1)+252*(void 0===w[2]?0:Math.floor(250*Math.abs(w[2]))+1)*252)*(w[3]?-1:1):void 0===w?0:Math.floor(250*Math.abs(w))+1),n=0;n<L;n+=1,d+=1,p+=3)t||(r[p]=T[x],r[p+1]=T[x+1],r[p+2]=T[x+2]),C.radius[d]=k.radius,C.fillColor[p]=k.fillColor.r,C.fillColor[p+1]=k.fillColor.g,C.fillColor[p+2]=k.fillColor.b,C.fillOpacity[d]=k.fillOpacity,C.strokeColor[p]=k.strokeColor.r,C.strokeColor[p+1]=k.strokeColor.g,C.strokeColor[p+2]=k.strokeColor.b,C.strokeOpacity[d]=k.strokeOpacity,C.strokeWidth[d]=k.strokeWidth,C.symbol[d]=k.symbolComputed,C.symbolValue[d]=k.symbolValue,C.rotation[d]=k.rotation}if(v._primitiveShapeAuto){var F=v._approximateMaxRadius(v.renderer().map().zoom());if(v._primitiveShape===a.primitiveShapes.sprite&&F>s._maxPointSize||v._primitiveShape!==a.primitiveShapes.sprite&&F<=s._maxPointSize)return v._primitiveShape=F>s._maxPointSize?a.primitiveShapes.triangle:a.primitiveShapes.sprite,v.renderer().contextRenderer().removeActor(_),_=null,v._init(!0),void E()}t?Object.keys(C).forEach((function(t){return b.updateSourceBuffer(t)})):(I.boundsDirty(!0),b.modified(),b.boundsDirtyTimestamp().modified())}return c(v,t),this.actors=function(){return _?[_]:[]},this.updateStyleFromArray=function(t,e,n){var i,o,a={fillColor:3,fillOpacity:1,radius:1,strokeColor:3,strokeOpacity:1,strokeWidth:1,symbolComputed:1,symbolValueComputed:1};if("string"==typeof t){var s={};s[t]=e,t=s}return r.each(t,(function(t,e){var n,r,s,u,l,c,f,h,d,p;if(v.visible()&&_&&a[t]&&!i&&!v.clustering())if(d=a[t],u=v.data().length,p="symbolComputed"===t?"symbol":"symbolValueComputed"===t?"symbolValue":t,s=(r=_.mapper()).getSourceBuffer(p),n=v.verticesPerFeature(),s&&u&&u*n*d===s.length){switch(a[t]){case 1:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=1)s[h]=l;break;case 3:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=3)s[h]=l.r,s[h+1]=l.g,s[h+2]=l.b}r.updateSourceBuffer(p),o=!0}else i=!0;else i=!0;if(t===p){var m=v.modified;i||(v.modified=function(){}),T(t,e,!1),v.modified=m}})),n&&(v.visible()&&i?v.draw():o&&v.renderer()._render()),v},this._handleZoom=function(t){v._primitiveShapeAuto&&v._primitiveShape===a.primitiveShapes.sprite&&v._approximateMaxRadius(t)>s._maxPointSize&&(v._primitiveShape=a.primitiveShapes.triangle,v.renderer().contextRenderer().removeActor(v.actors()[0]),v._init(!0),v.dataTime().modified(),v.draw())},this._init=function(n){var r,i,o=e.shaderProgram(),s=((i=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(v._primitiveShape===a.primitiveShapes.sprite?m:p),i),u=function(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(v._primitiveShape===a.primitiveShapes.sprite?d:h),t}(),l=e.material(),c=e.blend(),x=e.geometryData(),A=e.sourceDataP3fv({name:"pos"}),T={radius:1,fillColor:3,fillOpacity:1,strokeColor:3,strokeOpacity:1,strokeWidth:1,symbol:1,symbolValue:1,rotation:1},E={pixelWidth:e.GL.FLOAT,aspect:e.GL.FLOAT,zoom:e.GL.FLOAT,rotationUniform:e.GL.FLOAT},C=new e.projectionUniform("projectionMatrix");g=new e.modelViewOriginUniform("modelViewMatrix",y),v._primitiveShape===a.primitiveShapes.sprite?r=new e.points:(r=new e.triangles,T.unit=2),r.setIndices(new Uint16Array),n||M.call(v,t),b=e.mapper(),o.addVertexAttribute(e.vertexAttribute("pos"),e.vertexAttributeKeys.Position),x.addSource(A),Object.keys(T).forEach((function(t,n){o.addVertexAttribute(e.vertexAttribute(t),n+1),x.addSource(e.sourceDataAnyfv(T[t],n+1,{name:t}))})),w={},Object.keys(E).forEach((function(t){w[t]=new e.uniform(E[t],t),o.addUniform(w[t])})),o.addUniform(g),o.addUniform(C),o.addShader(u),o.addShader(s),l.addAttribute(o),l.addAttribute(c),(_=e.actor()).setMaterial(l),_.setMapper(b),x.addPrimitive(r),x.computeBounds=function(){x.setBounds(0,0,0,0,0,0)},b.setGeometryData(x),n||v.geoOn(f.zoom,(function(t){v._handleZoom(t.zoomLevel)}))},this._build=function(){return E(v.dataTime().timestamp()<v.buildTime().timestamp()),v.renderer().contextRenderer().hasActor(_)||v.renderer().contextRenderer().addActor(_),v.buildTime().modified(),v},this._update=function(){return A.call(v),(v.dataTime().timestamp()>=v.buildTime().timestamp()||v.updateTime().timestamp()<v.timestamp())&&v._build(),w.pixelWidth.set(2/v.renderer().width()),w.aspect.set(v.renderer().width()/v.renderer().height()),w.zoom.set(v.renderer().map().zoom()),w.rotationUniform.set(v.renderer().map().rotation()),_.setVisible(v.visible()),_.material().setBinNumber(v.bin()),v.updateTime().modified(),v},this._exit=function(){v.renderer().contextRenderer().removeActor(_),_=null,w={},x()},v._init(),this};i(u,a);o("webgl","marker",u,{}),t.exports=u},2778:function(t,e,n){t.exports=function(t){"use strict";t=t||{};var e=n(1611),r=n(5325),i=n(642),o=n(428),a=n(4993);n(4084).call(this);var s,u,l=this,c=this._exit,f=null,h=null,d=null,p=null,m=null,g=null,y=null,v=null,x=void 0!==t.dynamicDraw&&t.dynamicDraw,_=this._init,b=this._update;function w(){var t=new e.shader(e.GL.VERTEX_SHADER);return t.setShaderSource(a),t}function M(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(o),t}return this.createGLMeshColored=function(t){var e,n,o,a,c,f,d,x,_,b=t.elements.length,w=[],M=h.geometryData();for(m.set([t.minColor.r,t.minColor.g,t.minColor.b,t.minColor.a]),g.set([t.maxColor.r,t.maxColor.g,t.maxColor.b,t.maxColor.a]),y.set(t.colorMap.length),v.set(t.stepped),e=-1;e<t.colorMap.length+1;e+=1)o=Math.max(0,Math.min(t.colorMap.length-1,e)),w.push(255*t.colorMap[o].r),w.push(255*t.colorMap[o].g),w.push(255*t.colorMap[o].b),w.push(255*t.colorMap[o].a);if(p.setColorTable(w),t.pos=r.transformCoordinates(l.gcs(),l.layer().map().gcs(),t.pos,3),(s=new Float32Array(l.style.get("origin")(t.pos)))[0]||s[1]||s[2])for(e=0;e<t.pos.length;e+=3)t.pos[e]-=s[0],t.pos[e+1]-=s[1],t.pos[e+2]-=s[2];for(u.setOrigin(s),f=i.getGeomBuffer(M,"pos",3*b),d=i.getGeomBuffer(M,"opacity",b),x=i.getGeomBuffer(M,"value",b),e=n=0;e<b;e+=1,n+=3)a=3*(o=t.elements[e]),f[n]=t.pos[a],f[n+1]=t.pos[a+1],f[n+2]=t.pos[a+2],c=t.elementValues?Math.floor(e/3):o,d[e]=t.opacity[c],x[e]=t.value[c];(_=M.primitive(0).indices())instanceof Uint16Array&&_.length===b||(_=new Uint16Array(b),M.primitive(0).setIndices(_)),M.boundsDirty(!0),h.modified(),h.boundsDirtyTimestamp().modified()},this._init=function(t){var n=e.blend(),r=e.shaderProgram(),i=e.material(),o=e.lookupTable(),a=e.geometryData(),s=new e.projectionUniform("projectionMatrix"),c=new e.uniform(e.GL.INT,"sampler2d"),b=w(),A=M(),T=e.vertexAttribute("pos"),E=e.vertexAttribute("value"),C=e.vertexAttribute("opacity"),k=e.sourceDataP3fv({name:"pos"}),S=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.One,{name:"value"}),O=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Two,{name:"opacity"}),P=new e.triangles;u=new e.modelViewOriginUniform("modelViewMatrix"),_.call(l,t),h=e.mapper({dynamicDraw:x}),r.addVertexAttribute(T,e.vertexAttributeKeys.Position),r.addVertexAttribute(E,e.vertexAttributeKeysIndexed.One),r.addVertexAttribute(C,e.vertexAttributeKeysIndexed.Two),r.addUniform(u),r.addUniform(s),m=new e.uniform(e.GL.FLOAT_VEC4,"minColor"),r.addUniform(m),g=new e.uniform(e.GL.FLOAT_VEC4,"maxColor"),r.addUniform(g),y=new e.uniform(e.GL.FLOAT,"steps"),r.addUniform(y),v=new e.uniform(e.GL.BOOL,"stepped"),r.addUniform(v),r.addShader(A),r.addShader(b),r.addUniform(c),o.setTextureUnit(7),c.set(7),(d=i).addAttribute(r),d.addAttribute(n),p=o,d.addAttribute(p),(f=e.actor()).setMaterial(d),f.setMapper(h),a.addSource(k),a.addSource(S),a.addSource(O),a.addPrimitive(P),a.computeBounds=function(){a.setBounds(0,0,0,0,0,0)},h.setGeometryData(a)},this.actors=function(){return f?[f]:[]},this._update=function(){b.call(l),(l.dataTime().timestamp()>=l.buildTime().timestamp()||l.updateTime().timestamp()<=l.timestamp())&&l._build(),f.setVisible(l.visible()),f.material().setBinNumber(l.bin()),l.updateTime().modified()},this._exit=function(){l.renderer().contextRenderer().removeActor(f),c()},this}},4084:function(t,e,n){var r=function(t){"use strict";if(!(this instanceof n(1338)))return new r(t);var e=this,i=this.draw;if(this.draw=function(){return e.ready&&(e._update({mayDelay:!0}),e.renderer()._render(),i()),e},this.bin){var o=this.bin;this.bin=function(t,n){if(void 0===t&&!n&&null===o(void 0,!0)){var r=e.layer&&e.layer(),i=r&&r.map&&r.map(),a=(i&&i.listSceneObjects()||[]).indexOf(e);if(a>=0)return a}return o.apply(e,arguments)}}return this};t.exports=r},7759:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(7761),a=n(411),s=n(642),u=function(t){"use strict";if(!(this instanceof u))return new u(t);o.call(this,t),n(4084).call(this);var e,r,i,l=n(1611),c=n(3925),f=this._exit,h=this;return this.pointSearch=function(t,n){if(e&&h.m_info)for(var r=e.pointSearch(t,n),i=r.index.length-1;i>=0;i-=1)if(r.extra[r.index[i]]._quad&&r.extra[r.index[i]]._quad.image){var o=r.extra[r.index[i]]._quad.image,a=r.extra[r.index[i]].basis,s=Math.floor(a.x*o.width),u=Math.floor(a.y*o.height),l=document.createElement("canvas");l.width=l.height=1;var c=l.getContext("2d");c.drawImage(o,s,u,1,1,0,0,1,1);var f=c.getImageData(0,0,1,1).data,d=f[0]+256*f[1]+256*f[2]*256;return r={index:[d],found:[h.data()[d]]}}return{index:[],found:[]}},this._computePixelmap=function(){var t=h.data()||[],n=h.style.get("color"),o=h.indexModified(void 0,"clear"),u=h.dataTime().timestamp()>=h.buildTime().timestamp()||void 0===o;i||((i=a()).setTextureUnit(1),u=!0);var f,d=Math.max(1,t.length),p=i.maxWidth();d>p&&d%p&&(d+=p-d%p),u||(u=(f=i.colorTable()).length!==4*d,o[0]=Math.max(0,o[0]),o[1]=Math.min(t.length,o[1]+1)),u&&(f=new Uint8Array(4*d),o=[0,t.length]);for(var m=o[0];m<o[1];m+=1){var g=t[m],y=s.convertColor(n.call(h,g,m));f[4*m]=255*y.r,f[4*m+1]=255*y.g,f[4*m+2]=255*y.b,f[4*m+3]=void 0===y.a?255:255*y.a}h.m_info={colors:f};var v=i.colorTable();if(v&&v.length===f.length){for(var x=4*o[0];x<4*o[1]&&f[x]===v[x];x+=1);if(x===4*o[1])return}i.colorTable(f),e||(e=h.layer().createFeature("quad",{selectionAPI:!1,gcs:h.gcs(),visible:h.visible(void 0,!0),nearestPixel:!0}),r=!1),r||(h.dependentFeatures([e]),e.setShader("image_fragment",c),e._hookBuild=function(t){var e=new l.uniform(l.GL.INT,"lutSampler");e.set(i.textureUnit()),t.addUniform(e);var n=new l.uniform(l.GL.INT,"lutWidth");n.set(i.width),t.addUniform(n);var r=new l.uniform(l.GL.INT,"lutHeight");r.set(i.height),t.addUniform(r)},e._hookRenderImageQuads=function(t,e){i.bind(t,e)},!1===r&&e.style({image:h.m_srcImage,position:h.style.get("position")}).data([{}]).draw(),r=!0)},this._exit=function(){return e&&h.layer()&&(h.layer().deleteFeature(e),e=null,h.dependentFeatures([])),f(),h},t.quadFeature&&(e=t.quadFeature).nearestPixel&&e.nearestPixel(!0),this._init(t),this};r(u,o);var l={};l[o.capabilities.lookup]=!0,i("webgl","pixelmap",u,l),t.exports=u},5407:function(t,e,n){var r=n(5616),i=n(4626),o=n(1098).registerFeature,a=n(7541),s=n(7945),u=function(t){"use strict";if(!(this instanceof u))return new u(t);t=t||{},a.call(this,t);var e=n(1611),i=n(5325),o=n(642),l=n(4084),c=n(2709),f=n(4317),h=n(2682),d=n(8208),p=n(6979);l.call(this);var m,g,y=this,v=this._exit,x=null,_=null,b=null,w=null,M=void 0!==t.dynamicDraw&&t.dynamicDraw,A=this._init,T=this._update,E=this.updateStyleFromArray;function C(t){var e,n,r,u,l,c,f,h,d,p,v,b,w,M,A,T,E,k,S,O,P,L,R,I,D,N,F,j,z,B,V,q,G,U,H,W,X=y.data().length,K=y._pointPolygon(0,0,1,1),Q=new Array(3*X),Y=y.verticesPerFeature(),$=y.data(),Z=0,J=_.geometryData();if(l=y.position(),p=y.style.get("radius"),w=y.style.get("stroke"),T=y.style.get("strokeWidth"),S=y.style.get("strokeOpacity"),L=y.style.get("strokeColor"),D=y.style.get("fill"),j=y.style.get("fillOpacity"),V=y.style.get("fillColor"),!t){for(e=W=0;e<X;e+=1,W+=3)u=l($[e],e),Q[W]=u.x,Q[W+1]=u.y,Q[W+2]=0;if(Q=i.transformCoordinates(y.gcs(),y.layer().map().gcs(),Q,3),(g=new Float32Array(y.style.get("origin")(Q)))[0]||g[1]||g[2])for(e=W=0;e<X;e+=1,W+=3)Q[W]-=g[0],Q[W+1]-=g[1],Q[W+2]-=g[2];m.setOrigin(g),r=o.getGeomBuffer(J,"pos",Y*X*3),c=o.getGeomBuffer(J,"unit",Y*X*2),(f=J.primitive(0).indices())instanceof Uint16Array&&f.length===Y*X||(f=new Uint16Array(Y*X),J.primitive(0).setIndices(f))}for(h=o.getGeomBuffer(J,"radius",Y*X),v=o.getGeomBuffer(J,"stroke",Y*X),M=o.getGeomBuffer(J,"strokeWidth",Y*X),E=o.getGeomBuffer(J,"strokeOpacity",Y*X),O=o.getGeomBuffer(J,"strokeColor",Y*X*3),R=o.getGeomBuffer(J,"fill",Y*X),N=o.getGeomBuffer(J,"fillOpacity",Y*X),z=o.getGeomBuffer(J,"fillColor",Y*X*3),e=G=U=H=W=0;e<X;e+=1,W+=3){if(q=$[e],!t&&y._primitiveShape!==a.primitiveShapes.sprite)for(n=0;n<K.length;n+=1,H+=1)c[H]=K[n];for(d=p(q,e),b=w(q,e)?1:0,A=T(q,e),k=S(q,e),P=L(q,e),I=D(q,e)?1:0,F=j(q,e),B=V(q,e),y._primitiveShapeAuto&&(I&&F||b&&k)&&d+(b&&k?A:0)>Z&&(Z=d+(b&&k?A:0)),n=0;n<Y;n+=1,G+=1,U+=3)t||(r[U]=Q[W],r[U+1]=Q[W+1],r[U+2]=Q[W+2]),h[G]=d,v[G]=b,M[G]=A,E[G]=k,O[U]=P.r,O[U+1]=P.g,O[U+2]=P.b,R[G]=I,N[G]=F,z[U]=B.r,z[U+1]=B.g,z[U+2]=B.b}if(y._primitiveShapeAuto&&(y._primitiveShape===a.primitiveShapes.sprite&&Z>s._maxPointSize||y._primitiveShape!==a.primitiveShapes.sprite&&Z<=s._maxPointSize))return y._primitiveShape=Z>s._maxPointSize?a.primitiveShapes.triangle:a.primitiveShapes.sprite,y.renderer().contextRenderer().removeActor(x),x=null,y._init(!0),void C();t?(_.updateSourceBuffer("radius"),_.updateSourceBuffer("stroke"),_.updateSourceBuffer("strokeWidth"),_.updateSourceBuffer("strokeColor"),_.updateSourceBuffer("strokeOpacity"),_.updateSourceBuffer("fill"),_.updateSourceBuffer("fillColor"),_.updateSourceBuffer("fillOpacity")):(J.boundsDirty(!0),_.modified(),_.boundsDirtyTimestamp().modified())}return c(y,t),this.actors=function(){return x?[x]:[]},this.updateStyleFromArray=function(t,e,n){var i,o,a={fill:"bool",fillColor:3,fillOpacity:1,radius:1,stroke:"bool",strokeColor:3,strokeOpacity:1,strokeWidth:1};if("string"==typeof t){var s={};s[t]=e,t=s}return r.each(t,(function(t,e){var n,r,s,u,l,c,f,h,d;if(y.visible()&&x&&a[t]&&!i&&!y.clustering())if(d="bool"===a[t]?1:a[t],u=y.data().length,s=(r=x.mapper()).getSourceBuffer(t),n=y.verticesPerFeature(),s&&u&&u*n*d===s.length){switch(a[t]){case 1:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=1)s[h]=l;break;case 3:for(c=0,h=0;c<u;c+=1)for(l=e[c],f=0;f<n;f+=1,h+=3)s[h]=l.r,s[h+1]=l.g,s[h+2]=l.b;break;case"bool":for(c=0,h=0;c<u;c+=1)for(l=e[c]?1:0,f=0;f<n;f+=1,h+=1)s[h]=l}r.updateSourceBuffer(t),o=!0}else i=!0;else i=!0;var p=y.modified;i||(y.modified=function(){}),E(t,e,!1),y.modified=p})),n&&(y.visible()&&i?y.draw():o&&y.renderer()._render()),y},this._init=function(n){var r,i,o=e.shaderProgram(),s=((i=new e.shader(e.GL.VERTEX_SHADER)).setShaderSource(y._primitiveShape===a.primitiveShapes.sprite?p:d),i),u=function(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(y._primitiveShape===a.primitiveShapes.sprite?h:f),t}(),l=e.vertexAttribute("pos"),c=e.vertexAttribute("unit"),v=e.vertexAttribute("radius"),T=e.vertexAttribute("strokeWidth"),E=e.vertexAttribute("fillColor"),C=e.vertexAttribute("fill"),k=e.vertexAttribute("strokeColor"),S=e.vertexAttribute("stroke"),O=e.vertexAttribute("fillOpacity"),P=e.vertexAttribute("strokeOpacity"),L=new e.projectionUniform("projectionMatrix"),R=e.material(),I=e.blend(),D=e.geometryData(),N=e.sourceDataP3fv({name:"pos"}),F=e.sourceDataAnyfv(2,e.vertexAttributeKeysIndexed.One,{name:"unit"}),j=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Two,{name:"radius"}),z=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"strokeWidth"}),B=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Four,{name:"fillColor"}),V=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Five,{name:"fill"}),q=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Six,{name:"strokeColor"}),G=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Seven,{name:"stroke"}),U=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Eight,{name:"fillOpacity"}),H=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Nine,{name:"strokeOpacity"});m=new e.modelViewOriginUniform("modelViewMatrix",g),(r=y._primitiveShape===a.primitiveShapes.sprite?new e.points:new e.triangles).setIndices(new Uint16Array),b=new e.floatUniform("pixelWidth",2/y.renderer().width()),w=new e.floatUniform("aspect",y.renderer().width()/y.renderer().height()),n||A.call(y,t),_=e.mapper({dynamicDraw:M}),o.addVertexAttribute(l,e.vertexAttributeKeys.Position),y._primitiveShape!==a.primitiveShapes.sprite&&o.addVertexAttribute(c,e.vertexAttributeKeysIndexed.One),o.addVertexAttribute(v,e.vertexAttributeKeysIndexed.Two),o.addVertexAttribute(T,e.vertexAttributeKeysIndexed.Three),o.addVertexAttribute(E,e.vertexAttributeKeysIndexed.Four),o.addVertexAttribute(C,e.vertexAttributeKeysIndexed.Five),o.addVertexAttribute(k,e.vertexAttributeKeysIndexed.Six),o.addVertexAttribute(S,e.vertexAttributeKeysIndexed.Seven),o.addVertexAttribute(O,e.vertexAttributeKeysIndexed.Eight),o.addVertexAttribute(P,e.vertexAttributeKeysIndexed.Nine),o.addUniform(b),o.addUniform(w),o.addUniform(m),o.addUniform(L),o.addShader(u),o.addShader(s),R.addAttribute(o),R.addAttribute(I),(x=e.actor()).setMaterial(R),x.setMapper(_),D.addSource(N),D.addSource(F),D.addSource(j),D.addSource(z),D.addSource(B),D.addSource(V),D.addSource(q),D.addSource(G),D.addSource(U),D.addSource(H),D.addPrimitive(r),D.computeBounds=function(){D.setBounds(0,0,0,0,0,0)},_.setGeometryData(D)},this._build=function(){return C(y.dataTime().timestamp()<y.buildTime().timestamp()),y.renderer().contextRenderer().hasActor(x)||y.renderer().contextRenderer().addActor(x),y.buildTime().modified(),y},this._update=function(){return T.call(y),(y.dataTime().timestamp()>=y.buildTime().timestamp()||y.updateTime().timestamp()<y.timestamp())&&y._build(),b.set(2/y.renderer().width()),w.set(y.renderer().width()/y.renderer().height()),x.setVisible(y.visible()),x.material().setBinNumber(y.bin()),y.updateTime().modified(),y},this._exit=function(){y.renderer().contextRenderer().removeActor(x),x=null,v()},y._init(),this};i(u,a);var l={};l[a.capabilities.stroke]=!0,o("webgl","point",u,l),t.exports=u},2709:function(t,e,n){var r=n(7541);t.exports=function(t,e){e=e||{},t._primitiveShapeAuto=!0,t._primitiveShape=r.primitiveShapes.auto,void 0!==r.primitiveShapes[e.primitiveShape]&&(t._primitiveShape=e.primitiveShape),t._primitiveShapeAuto=t._primitiveShape===r.primitiveShapes.auto,t._primitiveShapeAuto&&(t._primitiveShape=r.primitiveShapes.sprite,t._primitiveShapeAuto=!0),t._pointPolygon=function(e,n,i,o){var a;switch(t._primitiveShape){case r.primitiveShapes.triangle:a=[e,n-2*o,e-i*Math.sqrt(3),n+o,e+i*Math.sqrt(3),n+o];break;case r.primitiveShapes.square:a=[e-i,n+o,e-i,n-o,e+i,n+o,e-i,n-o,e+i,n-o,e+i,n+o];break;default:a=[e,n]}return a},t.verticesPerFeature=function(){return t._pointPolygon(0,0,1,1).length/2},t.primitiveShape=function(e,n){if(void 0===e)return n||!t._primitiveShapeAuto?t._primitiveShape:r.primitiveShapes.auto;if(void 0!==r.primitiveShapes[e]){var i=!1;e===r.primitiveShapes.auto?(i=!t._primitiveShapeAuto,t._primitiveShapeAuto=!0):(i=t._primitiveShapeAuto||t._primitiveShape!==e,t._primitiveShapeAuto=!1,t._primitiveShape=e),i&&(t.renderer().contextRenderer().removeActor(t.actors()[0]),t._init(!0),t.dataTime().modified())}return t}}},8511:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(6645),a=function(t){"use strict";if(!(this instanceof a))return new a(t);t=t||{},o.call(this,t);var e=n(1611),r=n(9747);r=r.__esModule?r.default:r;var i=n(5325),s=n(642),u=n(4084),l=n(4547),c=n(9506);u.call(this);var f,h,d,p,m,g=this,y=this._exit,v=e.actor(),x=e.mapper(),_=e.material(),b=this._init,w=this._update;function M(){var t=new e.shader(e.GL.VERTEX_SHADER);return t.setShaderSource(c),t}function A(){var t=new e.shader(e.GL.FRAGMENT_SHADER);return t.setShaderSource(l),t}return this._init=function(t){var n=e.shaderProgram(),r=e.vertexAttribute("pos"),i=e.vertexAttribute("fillColor"),o=e.vertexAttribute("fillOpacity"),a=new e.projectionUniform("projectionMatrix"),s=M(),u=A(),l=e.blend(),c=e.geometryData(),f=e.sourceDataP3fv({name:"pos"}),h=e.sourceDataAnyfv(3,e.vertexAttributeKeysIndexed.Two,{name:"fillColor"}),p=e.sourceDataAnyfv(1,e.vertexAttributeKeysIndexed.Three,{name:"fillOpacity"}),m=e.triangles();d=new e.modelViewOriginUniform("modelViewMatrix"),n.addVertexAttribute(r,e.vertexAttributeKeys.Position),n.addVertexAttribute(i,e.vertexAttributeKeysIndexed.Two),n.addVertexAttribute(o,e.vertexAttributeKeysIndexed.Three),n.addUniform(d),n.addUniform(a),n.addShader(u),n.addShader(s),_.addAttribute(n),_.addAttribute(l),v.setMaterial(_),v.setMapper(x),c.addSource(f),c.addSource(h),c.addSource(p),c.addPrimitive(m),c.computeBounds=function(){c.setBounds(0,0,0,0,0,0)},x.setGeometryData(c),b.call(g,t)},this.actors=function(){return[v]},this._build=function(){!function(t){var e,n,o,a,u,l,c,p,m,y,v,_,b,w,M,A,T,E,C,k,S,O,P,L,R,I,D,N,F,j=[],z=g.gcs(),B=g.layer().map().gcs(),V=0,q=x.geometryData();for(u=g.style.get("fillColor"),l=s.isFunction(g.style("fillColor"))?void 0:u(),p=g.style.get("fillOpacity"),m=s.isFunction(g.style("fillOpacity"))?void 0:p(),y=g.style.get("fill"),v=s.isFunction(g.style("fill"))?void 0:y(),_=g.style.get("uniformPolygon"),b=s.isFunction(g.style("uniformPolygon"))?void 0:_(),t?(j=f.items,V=f.numPts):(n=(n=g.style.get("position"))===s.identityFunction?null:n,o=(o=g.style.get("polygon"))===s.identityFunction?null:o,g.data().forEach((function(t,e){var a,s,u,l;if((a=o?o(t,e):t)&&!((s=a.outer||(Array.isArray(a)?a:[])).length<3)){for(u=new Array(3*s.length),O=k=0;O<s.length;O+=1,k+=3)l=n?n(s[O],O,t,e):s[O],u[k]=l.x,u[k+1]=l.y,u[k+2]=0;u={vertices:u,dimensions:3,holes:[]},F=s,a.inner&&a.inner.forEach((function(r){if(!(r.length<3))for(F=F.concat(r),u.holes.push(k/3),O=0;O<r.length;O+=1,k+=3)l=n?n(r[O],O,t,e):r[O],u.vertices[k]=l.x,u.vertices[k+1]=l.y,u.vertices[k+2]=0})),u.vertices=i.transformCoordinates(z,B,u.vertices,u.dimensions),(I={triangles:r(u.vertices,u.holes,u.dimensions),vertices:u.vertices,original:F,item:t,itemIndex:e}).triangles.length&&(j.push(I),V+=I.triangles.length)}})),e=s.getGeomBuffer(q,"pos",3*V),(M=q.primitive(0).indices())instanceof Uint16Array&&M.length===V||(M=new Uint16Array(V),q.primitive(0).setIndices(M)),f={items:j,numPts:V},h=new Float32Array(g.style.get("origin")(j)),d.setOrigin(h)),a=s.getGeomBuffer(q,"fillColor",3*V),c=s.getGeomBuffer(q,"fillOpacity",V),C=k=0,A=l,E=v,L=0;L<j.length;L+=1)if(R=j[L].triangles.length,S=j[L].vertices,D=j[L].item,N=j[L].itemIndex,F=j[L].original,T=m,(w=void 0===b?_(D,N):b)&&(void 0===l&&(A=u(S[0],0,D,N)),void 0===m&&(T=p(S[0],0,D,N))),void 0===v&&(E=y(D,N)),E||(T=0),w&&t&&j[L].uniform&&j[L].color&&A.r===j[L].color.r&&A.g===j[L].color.g&&A.b===j[L].color.b&&T===j[L].opacity)C+=R,k+=3*R;else{for(O=0;O<R;O+=1,C+=1,k+=3)t&&w?(a[k]=A.r,a[k+1]=A.g,a[k+2]=A.b,c[C]=T):(P=3*j[L].triangles[O],t||(e[k]=S[P]-h[0],e[k+1]=S[P+1]-h[1],e[k+2]=S[P+2]-h[2],M[C]=O),w||void 0!==l||(A=u(F[P],P,D,N)),a[k]=A.r,a[k+1]=A.g,a[k+2]=A.b,!w&&E&&void 0===m&&(T=p(F[P],P,D,N)),c[C]=T);(w||j[L].uniform)&&(j[L].uniform=w,j[L].color=A,j[L].opacity=T)}t?(x.updateSourceBuffer("fillOpacity"),x.updateSourceBuffer("fillColor")):(x.modified(),q.boundsDirty(!0),x.boundsDirtyTimestamp().modified())}(!!(g.dataTime().timestamp()<g.buildTime().timestamp()&&f)),g.renderer().contextRenderer().hasActor(v)||(g.renderer().contextRenderer().addActor(v),p=!0),g.buildTime().modified()},this._update=function(t){g.ready&&(t&&t.mayDelay&&p?m=g.layer().map().scheduleAnimationFrame(g._update):(m&&(g.layer().map().scheduleAnimationFrame(g._update,"remove"),m=null),w.call(g),(g.dataTime().timestamp()>=g.buildTime().timestamp()||g.updateTime().timestamp()<=g.timestamp())&&g._build(),v.setVisible(g.visible()),v.material().setBinNumber(g.bin()),g.updateTime().modified()))},this._exit=function(){m&&g.layer()&&(g.layer().map().scheduleAnimationFrame(g._update,"remove"),m=null),g.renderer().contextRenderer().removeActor(v),y()},this._init(t),this};r(a,o),i("webgl","polygon",a),t.exports=a},9304:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(3842),a=n(77),s=n(642),u=16777216,l=function(t){"use strict";if(!(this instanceof l))return new l(t);o.call(this,t);var e=n(5616),r=n(1611),i=n(4084),c=n(8711),f=n(6238),h=n(8961),d=n(3260);i.call(this);var p,m,g,y,v,x,_,b=this,w=this._exit,M=this._update,A={},T=a(),E=a();function C(t){var e=new r.mapper({dynamicDraw:!0});return e.s_modified=e.modified,e.g_timestamp=a(),e.timestamp=e.g_timestamp.timestamp,e.modified=function(){return e.s_modified(),e.g_timestamp.modified(),e},e.s_render=e.render,e.render=t,e}return this.actors=function(){var t=[];return m&&t.push(m),g&&t.push(g),t},this._build=function(){var t,e,n,i,o,a,s,u,l;b.position()&&((_=b._generateQuads()).imgQuads.length&&!m&&(b.visible(!1),t=C(b._renderImageQuads),(m=new r.actor).setMapper(t),e=new r.material,(n=new r.shaderProgram).addVertexAttribute(new r.vertexAttribute("vertexPosition"),r.vertexAttributeKeys.Position),n.addVertexAttribute(new r.vertexAttribute("textureCoord"),r.vertexAttributeKeys.TextureCoordinate),p=new r.modelViewOriginUniform("modelViewMatrix",_.origin),n.addUniform(p),n.addUniform(new r.projectionUniform("projectionMatrix")),n.addUniform(new r.floatUniform("opacity",1)),n.addUniform(new r.floatUniform("zOffset",0)),(l=new r.uniform(r.GL.INT,"sampler2d")).set(0),n.addUniform(l),u=b.renderer()._glContext(),(o=new r.uniform(u.FLOAT_VEC2,"crop")).set([1,1]),n.addUniform(o),(a=new r.uniform(u.FLOAT_VEC4,"cropsource")).set([0,0,0,0]),n.addUniform(a),n.addShader(r.getCachedShader(u.VERTEX_SHADER,u,f)),n.addShader(r.getCachedShader(u.FRAGMENT_SHADER,u,c)),b._hookBuild&&b._hookBuild(n),e.addAttribute(n),e.addAttribute(new r.blend),s=new r.geometryData,y=void 0,(i=new r.sourceDataT2fv).pushBack([0,0,1,0,0,1,1,1]),s.addSource(i),t.setGeometryData(s),m.setMaterial(e),b.renderer().contextRenderer().addActor(m),b.visible(!0)),_.clrQuads.length&&!g&&(b.visible(!1),t=C(b._renderColorQuads),(g=new r.actor).setMapper(t),e=new r.material,(n=new r.shaderProgram).addVertexAttribute(new r.vertexAttribute("vertexPosition"),r.vertexAttributeKeys.Position),x=new r.modelViewOriginUniform("modelViewMatrix",_.origin),n.addUniform(x),n.addUniform(new r.projectionUniform("projectionMatrix")),n.addUniform(new r.floatUniform("opacity",1)),n.addUniform(new r.floatUniform("zOffset",0)),u=b.renderer()._glContext(),n.addUniform(new r.uniform(u.FLOAT_VEC3,"vertexColor")),n.addShader(r.getCachedShader(u.VERTEX_SHADER,u,d)),n.addShader(r.getCachedShader(u.FRAGMENT_SHADER,u,h)),e.addAttribute(n),e.addAttribute(new r.blend),s=new r.geometryData,v=void 0,t.setGeometryData(s),g.setMaterial(e),b.renderer().contextRenderer().addActor(g),b.visible(!0)),p&&p.setOrigin(_.origin),x&&x.setOrigin(_.origin),b._updateTextures(),b.buildTime().modified())},this._updateTextures=function(){var t;e.each(_.imgQuads,(function(e,n){if(n.image)if(n.image._texture)n.texture=n.image._texture;else{(t=new r.texture).setImage(n.image);var i=b.nearestPixel();if(void 0!==i)if(!0!==i&&s.isNonNullFinite(i))i=b.layer().map().zoom()>=i;i&&t.setNearestPixel(!0),n.texture=n.image._texture=t}}))},this._renderColorQuads=function(t){if(_.clrQuads.length){var n=this;(n.timestamp()>E.timestamp()||b.dataTime().timestamp()>E.timestamp()||t.m_contextChanged||!v||12*_.clrQuads.length>v.length)&&function(t){var n=t.m_context,r=!1;_.clrQuads.length&&((!v||v.length<12*_.clrQuads.length||!A.clrQuadsPosition)&&(A.clrQuadsPosition&&n.deleteBuffer(A.clrQuadsPosition),A.clrQuadsPosition=n.createBuffer(),v=new Float32Array(12*Math.max(128,2*_.clrQuads.length)),r=!0),e.each(_.clrQuads,(function(t,e){for(var n=0;n<12;n+=1)v[12*t+n]=e.pos[n]-_.origin[n%3]})),n.bindBuffer(n.ARRAY_BUFFER,A.clrQuadsPosition),r?n.bufferData(n.ARRAY_BUFFER,v,n.DYNAMIC_DRAW):n.bufferSubData(n.ARRAY_BUFFER,0,v)),E.modified()}(t),n.s_render(t,!0);var i,o,a,s=t.m_context;s.bindBuffer(s.ARRAY_BUFFER,A.clrQuadsPosition),e.each(_.clrQuads,(function(e,n){n.opacity!==i&&(i=n.opacity,s.uniform1fv(t.m_material.shaderProgram().uniformLocation("opacity"),new Float32Array([i]))),(n.zOffset||0)!==o&&(o=n.zOffset||0,s.uniform1fv(t.m_material.shaderProgram().uniformLocation("zOffset"),new Float32Array([o]))),a&&a.r===n.color.r&&a.g===n.color.g&&a.b===n.color.b||(a=n.color,s.uniform3fv(t.m_material.shaderProgram().uniformLocation("vertexColor"),new Float32Array([a.r,a.g,a.b]))),s.bindBuffer(s.ARRAY_BUFFER,A.clrQuadsPosition),s.vertexAttribPointer(r.vertexAttributeKeys.Position,3,s.FLOAT,!1,12,12*e*4),s.enableVertexAttribArray(r.vertexAttributeKeys.Position),s.drawArrays(s.TRIANGLE_STRIP,0,4)})),s.bindBuffer(s.ARRAY_BUFFER,null),n.undoBindVertexData(t)}},this._renderImageQuads=function(t){if(_.imgQuads.length){var n=this;(n.timestamp()>T.timestamp()||b.dataTime().timestamp()>T.timestamp()||t.m_contextChanged||!y||12*_.imgQuads.length>y.length)&&function(t){var n=t.m_context,r=!1;_.imgQuads.length&&((!y||y.length<12*_.imgQuads.length||!A.imgQuadsPosition)&&(A.imgQuadsPosition&&n.deleteBuffer(A.imgQuadsPosition),A.imgQuadsPosition=n.createBuffer(),y=new Float32Array(12*Math.max(128,2*_.imgQuads.length)),r=!0),e.each(_.imgQuads,(function(t,e){for(var n=0;n<12;n+=1)y[12*t+n]=e.pos[n]-_.origin[n%3]})),n.bindBuffer(n.ARRAY_BUFFER,A.imgQuadsPosition),r?n.bufferData(n.ARRAY_BUFFER,y,n.DYNAMIC_DRAW):n.bufferSubData(n.ARRAY_BUFFER,0,y)),T.modified()}(t),n.s_render(t,!0);var i,o,a,l,c,f,h,d,p=t.m_context,m={x:1,y:1},g={x0:0,y0:0,x1:1,y1:1},v=b.nearestPixel();if(void 0!==v){if(!0!==v&&s.isNonNullFinite(v)){var x=b.layer().map().zoom();v=x>=v}_.imgQuads.forEach((function(e){if(e.image&&e.texture&&e.texture.nearestPixel()!==v&&e.texture.textureHandle()){t.m_context.bindTexture(r.GL.TEXTURE_2D,e.texture.textureHandle()),t.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MIN_FILTER,v?r.GL.NEAREST:r.GL.LINEAR),t.m_context.texParameteri(r.GL.TEXTURE_2D,r.GL.TEXTURE_MAG_FILTER,v?r.GL.NEAREST:r.GL.LINEAR),t.m_context.bindTexture(r.GL.TEXTURE_2D,null);var n=e.texture.modified;e.texture.modified=function(){},e.texture.setNearestPixel(v),e.texture.modified=n}}))}b._hookRenderImageQuads&&b._hookRenderImageQuads(t,_.imgQuads),p.bindBuffer(p.ARRAY_BUFFER,A.imgQuadsPosition),e.each(_.imgQuads,(function(e,n){n.image&&(n.texture.bind(t),n.image.width*n.image.height>u&&(u=n.image.width*n.image.height,p.getError()===p.OUT_OF_MEMORY&&console.log("Insufficient GPU memory for texture")),n.opacity!==i&&(i=n.opacity,p.uniform1fv(t.m_material.shaderProgram().uniformLocation("opacity"),new Float32Array([i]))),(n.zOffset||0)!==o&&(o=n.zOffset||0,p.uniform1fv(t.m_material.shaderProgram().uniformLocation("zOffset"),new Float32Array([o]))),a=n.crop||{x:1,y:1},m&&a.x===m.x&&a.y===m.y||(m=a,p.uniform2fv(t.m_material.shaderProgram().uniformLocation("crop"),new Float32Array([void 0===m.x?1:m.x,void 0===m.y?1:m.y]))),c=n.image.width,f=n.image.height,l=n.crop||{left:0,top:0,right:c,bottom:f},g&&l.left===g.left&&l.top===g.top&&l.right===g.right&&l.bottom===g.bottom&&h===c&&d===f||(g=l,h=c,d=f,p.uniform4fv(t.m_material.shaderProgram().uniformLocation("cropsource"),new Float32Array([g.left/c,g.top/f,g.right/c,g.bottom/f]))),p.bindBuffer(p.ARRAY_BUFFER,A.imgQuadsPosition),p.vertexAttribPointer(r.vertexAttributeKeys.Position,3,p.FLOAT,!1,12,12*e*4),p.enableVertexAttribArray(r.vertexAttributeKeys.Position),p.drawArrays(p.TRIANGLE_STRIP,0,4),n.texture.undoBind(t))})),p.bindBuffer(p.ARRAY_BUFFER,null),n.undoBindVertexData(t)}},this._update=function(){M.call(b),(b.buildTime().timestamp()<=b.dataTime().timestamp()||b.updateTime().timestamp()<b.timestamp())&&b._build(),g&&(g.setVisible(b.visible()),g.material().setBinNumber(b.bin())),m&&(m.setVisible(b.visible()),m.material().setBinNumber(b.bin())),b.updateTime().modified()},this._cleanup=function(){m&&(b.renderer().contextRenderer().removeActor(m),m=null),g&&(b.renderer().contextRenderer().removeActor(g),g=null),y=void 0,v=void 0,Object.keys(A).forEach((function(t){delete A[t]})),_&&_.imgQuads&&(_.imgQuads.forEach((function(t){t.texture&&(delete t.texture,delete t.image._texture)})),b._updateTextures()),b.modified()},this.setShader=function(t,e){switch(t){case"image_vertex":f=e;break;case"image_fragment":c=e;break;case"color_vertex":d=e;break;case"color_fragment":h=e;break;default:return}return b},this._exit=function(){b._cleanup(),w.call(b)},b._init(t),this};r(l,o);var c={};c[o.capabilities.color]=!0,c[o.capabilities.image]=!0,c[o.capabilities.imageCrop]=!0,c[o.capabilities.imageFixedScale]=!1,c[o.capabilities.imageFull]=!0,c[o.capabilities.canvas]=!1,c[o.capabilities.video]=!1,i("webgl","quad",l,c),t.exports=l},1474:function(t,e,n){var r=n(1098).registerLayerAdjustment,i=n(9264),o=function(){"use strict";var t,e=n(6409),r=this,o=this._init,a=this._exit,s=this._update,u=this.visible,l=this.zIndex,c=0,f=[];this._drawTile=function(e){if(t){var n,o,a=r._tileBounds(e),s=e.index.level||0,u=r._tileOffset(s),l=r.tileCropFromBounds(e),h={},d=r.renderer().contextRenderer().m_depthBits;l&&(h.crop={x:l.x/r._options.tileWidth,y:l.y/r._options.tileHeight}),h.ul=r.fromLocal(r.fromLevel({x:a.left-u.x,y:a.top-u.y},s),0),h.ll=r.fromLocal(r.fromLevel({x:a.left-u.x,y:a.bottom-u.y},s),0),h.ur=r.fromLocal(r.fromLevel({x:a.right-u.x,y:a.top-u.y},s),0),h.lr=r.fromLocal(r.fromLevel({x:a.right-u.x,y:a.bottom-u.y},s),0),h.ul.z=h.ll.z=h.ur.z=h.lr.z=0,n=r._options.keepLower?r._options.maxLevel-s+1:1,(o=(o=r.map().listSceneObjects().filter((function(t){return t instanceof i}))).slice(o.indexOf(r)+1)).forEach((function(t){n+=t._options.keepLower?t._options.maxLevel-t._options.minLevel+1:1})),h.zOffset=n*Math.pow(2,-d)*i._zOffsetMultiple,c+=1,h.id=c,e.quadId=h.id,h.image=e.image,f.push(h),t.data(f),t._update(),r.draw()}},this._remove=function(e){if(void 0!==e.quadId&&t){for(var n=0;n<f.length;n+=1)if(f[n].id===e.quadId){f.splice(n,1);break}t.data(f),t._update(),r.draw()}},this.visible=function(e){return void 0===e?u():(r.visible()!==e&&(u(e),t&&t.visible(t.visible(void 0,!0),!0)),r)},this.zIndex=function(t,e){return void 0!==t&&r._clearQuads(),l.apply(r,arguments)},this._clearQuads=function(n){(!n||n.layer&&n.layer instanceof i&&n.layer.autoshareRenderer()&&(n.event!==e.layerAdd&&n.event!==e.layerRemove||!r.map().layers().every((function(t){return t===n.layer||n.layer.zIndex()>t.zIndex()}))))&&(r.clear(),t&&t.modified(),n&&r.draw())},this._update=function(e){return s.call(r,e),t&&t.nearestPixel&&t.nearestPixel(r.nearestPixel()),r._addBaseQuadToTiles(t,f),r},this._cleanup=function(){var t;if(r.cache&&r.cache._cache){for(var e in r.cache._cache)(t=r.cache._cache[e])._image&&t._image._texture&&delete t._image._texture;r.cache.clear()}r.clear()},this._exit=function(){var n=r.map();n.geoOff(e.layerAdd,r._clearQuads),n.geoOff(e.layerRemove,r._clearQuads),r._cleanup(),r.deleteFeature(t),t=null,f=[],a.apply(r,arguments)},this._init=function(){o.apply(r,arguments),(t=r.createFeature("quad",{previewColor:r._options.previewColor,previewImage:r._options.previewImage})).geoTrigger=void 0,t.gcs(r._options.gcs||r.map().gcs()),t.data(f),t._update();var n=r.map();n.geoOn(e.layerAdd,r._clearQuads),n.geoOn(e.layerRemove,r._clearQuads),r.geoOn(e.unhidden,(function(){r.map().scheduleAnimationFrame((function(){r._clearQuads(),r.map().draw()}))}))},this._getSubLayer=function(){},this._updateSubLayers=void 0};i._zOffsetMultiple=2,r("webgl","tile",o),t.exports=o},536:function(t,e,n){var r=n(4626),i=n(1098).registerFeature,o=n(338),a=function(t){"use strict";return this instanceof a?(t=t||{},o.call(this,t),n(4084).call(this),this._init(t),this):new a(t)};r(a,o),i("webgl","track",a),t.exports=a},7945:function(t,e,n){var r,i=n(4626),o=n(1098).registerRenderer,a=n(2274),s=function(t){"use strict";if(!(this instanceof s))return new s(t);t=t||{},a.call(this,t);var e,r=n(5616),i=n(1611),o=n(3503),u=n(642),l=n(6409),c=this,f=null,h=null,d=!1,p=this._init,m=this._exit;return this.contextRenderer=function(){return f},this.api=function(){return s.apiname},this._init=function(){if(c.initialized())return c;p.call(c);var e=t.canvas||r(document.createElement("canvas"));if(e.addClass("webgl-canvas"),r(c.layer().node().get(0)).append(e),window.overrideContextAttributes){var n=e.get(0),o=n.getContext;n.getContext=function(t,e){if(e=e||{},window.overrideContextAttributes)for(var r in window.overrideContextAttributes)window.overrideContextAttributes.hasOwnProperty(r)&&(e[r]=window.overrideContextAttributes[r]);return o.call(n,t,e)}}(h=i.viewer(e.get(0),t.options)).init(),(f=h.renderWindow().activeRenderer()).setResetScene(!1),e.get(0).addEventListener("webglcontextlost",(function(t){return t.preventDefault()}),!1),e.get(0).addEventListener("webglcontextrestored",(function(){return h.renderWindow()._init()}),!1),h.renderWindow().renderers().length>0&&f.setLayer(h.renderWindow().renderers().length),c.canvas(e);var a=c.layer().map().size();return c._resize(0,0,a.width,a.height),c},this._resize=function(t,e,n,r){var i=h.renderWindow();return t===i.windowPosition[0]&&e===i.windowPosition[1]&&n===c.width()&&r===c.height()||(c._setWidthHeight(n,r),c.canvas().attr("width",n),c.canvas().attr("height",r),i.positionAndResize(t,e,n,r),d=!0,c._render()),c},this._render=function(){return c.layer().map().scheduleAnimationFrame(c._renderFrame,!0),c},this._renderFrame=function(){h&&(d&&(d=!1,c._updateRendererCamera()),h.render())},this._glContext=function(){return h&&h.renderWindow()?h.renderWindow().context():i.GL},this._exit=function(){if(c.layer().map().scheduleAnimationFrame(c._renderFrame,"remove"),c.canvas().remove(),h){var t=new i.renderState;t.m_renderer=h,t.m_context=c._glContext(),h.exit(t);var e=c._glContext();e!==i.GL&&e.getExtension("WEBGL_lose_context")&&e.getExtension("WEBGL_lose_context").loseContext&&e.getExtension("WEBGL_lose_context").loseContext()}i.clearCachedShaders(i.GL),h=null,m()},this._updateRendererCamera=function(){var t=h.renderWindow(),n=c.layer().map(),r=n.camera(),i=n.rotation()||0,a=r.view,s=r.projectionMatrix;if(s[15])s=o.copy(u.mat4AsArray(),s),s=o.scale(s,s,[1,1,-.5]),s=o.translate(s,s,[0,0,r.clipbounds.far]);else{var l=r.clipbounds.near,f=r.clipbounds.far;s=o.copy(u.mat4AsArray(),s),s=o.scale(s,s,[1/l,1/l,-1/f])}var d=Math.PI/2,p=i%d,m=Math.min(Math.abs(p),Math.abs(p-d))<1e-5;t.renderers().forEach((function(t){var i=t.camera();if(!u.compareArrays(a,i.viewMatrix())||!u.compareArrays(s,i.projectionMatrix())||e!==n.zoom()){e=n.zoom(),i.setViewMatrix(a,!0),i.setProjectionMatrix(s);var o=r.viewport;s[1]||s[2]||s[3]||s[4]||s[6]||s[7]||s[8]||s[9]||s[11]||1!==s[15]||!m||o.left&&o.left%1||o.top&&o.top%1||parseFloat(e.toFixed(6))!==parseFloat(e.toFixed(0))?i.viewAlignment=function(){return null}:i.viewAlignment=function(){var t={roundx:2/o.width,roundy:2/o.height};return t.dx=o.width%2?.5*t.roundx:0,t.dy=o.height%2?.5*t.roundy:0,t}}}))},c.layer().geoOn(l.pan,(function(t){d=!0})),c.layer().geoOn(l.parallelprojection,(function(t){var e=c.contextRenderer(),n=c.layer();if(t.geo&&t.geo._triggeredBy!==n){if(!e||!e.camera())return void console.log("Parallel projection event triggered on unconnected VGL renderer.");e.camera().setEnableParallelProjection(t.parallelProjection),d=!0}})),this};s.apiname="webgl",i(s,a),o("webgl",s),o("vgl",s),s.supported=function(){if(void 0===r){var t,e;try{(e=(t=document.createElement("canvas")).getContext("webgl")||t.getContext("experimental-webgl")).getSupportedExtensions().indexOf("WEBGL_debug_renderer_info")>=0&&(s._unmaskedRenderer=e.getParameter(e.getExtension("WEBGL_debug_renderer_info").UNMASKED_RENDERER_WEBGL)),s._maxTextureSize=e.getParameter(e.MAX_TEXTURE_SIZE),s._maxPointSize=e.getParameter(e.ALIASED_POINT_SIZE_RANGE)[1],r=!0}catch(t){console.warn("No webGL support"),r=!1}t=void 0,e=void 0}return r},s.fallback=function(){return null},t.exports=s},632:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o),s=n(3021),u=n.n(s),l=new URL(n(3158),n.b),c=new URL(n(5245),n.b),f=new URL(n(8546),n.b),h=new URL(n(9803),n.b),d=a()(i()),p=u()(l),m=u()(c),g=u()(f),y=u()(h);d.push([t.id,'.geojs-map{position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden}.geojs-map .geo-attribution{position:absolute;right:0;bottom:0;padding-right:5px;cursor:auto;font:11px/1.5 "Helvetica Neue",Arial,Helvetica,sans-serif;z-index:1001;background:rgba(255,255,255,0.7);clear:both;display:block;pointer-events:auto}.geojs-map .geo-attribution .geo-attribution-layer{padding-left:5px}.geojs-map .canvas-canvas{display:block;-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-o-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}.geojs-map .webgl-canvas{display:block}.geojs-map .geojs-layer{position:absolute;width:100%;height:100%;left:0;top:0;pointer-events:none}.geojs-map .geojs-layer.active:not(.hidden) > *{pointer-events:auto}.geojs-map .geojs-layer.hidden{display:none}.geojs-map .geojs-layer.hidden[renderer="webgl"]{display:inherit}.geojs-map .geo-tile-layer{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;-o-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;line-height:0;font-size:0}.geojs-map.annotation-input{cursor:crosshair}.geojs-map.annotation-input.annotation-intersect{cursor:url('+p+") 12 12,crosshair}.geojs-map.annotation-input.annotation-difference{cursor:url("+m+") 12 12,crosshair}.geojs-map.annotation-input.annotation-union{cursor:url("+g+") 12 12,crosshair}.geojs-map.annotation-input.annotation-xor{cursor:url("+y+") 12 12,crosshair}.geojs-map.annotation-cursor{cursor:crosshair}.geojs-map.annotation-cursor.annotation-intersect{cursor:url("+p+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-difference{cursor:url("+m+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-union{cursor:url("+g+") 12 12,crosshair}.geojs-map.annotation-cursor.annotation-xor{cursor:url("+y+') 12 12,crosshair}.geojs-map.highlight-focus:after{content:"";display:block;position:absolute;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;left:0;top:0;right:0;bottom:0;border:3px solid Highlight;opacity:1;-ms-filter:none;filter:none;-webkit-transition:opacity 0s;-moz-transition:opacity 0s;-o-transition:opacity 0s;-ms-transition:opacity 0s;transition:opacity 0s;visibility:hidden}.geojs-map.highlight-focus:focus:after{visibility:visible;-webkit-transition:opacity 2.5s ease-in;-moz-transition:opacity 2.5s ease-in;-o-transition:opacity 2.5s ease-in;-ms-transition:opacity 2.5s ease-in;transition:opacity 2.5s ease-in;opacity:0;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";filter:alpha(opacity=0)}.geo-tile-container{position:absolute}.geo-tile-container.crop{overflow:hidden}',"",{version:3,sources:["webpack://./main.styl","webpack://./../node_modules/nib/lib/nib/vendor.styl","webpack://./../node_modules/nib/lib/nib/overflow.styl","webpack://./../node_modules/nib/lib/nib/flex.styl","webpack://./../node_modules/nib/lib/nib/border.styl"],names:[],mappings:"AAEA,WACE,iBAAS,CCwCO,wBAAG,CAAH,qBAAG,CAAH,oBAAG,CARN,gBAAG,CChBd,eAAU,CFZZ,4BACE,iBAAS,CACT,OAAM,CACN,QAAO,CACP,iBAAc,CC4ed,WAAO,CD1eP,yDAA8B,CAC9B,YAAQ,CC6dR,gCAAW,CD3dX,UAAM,CGMN,aAAS,CHJT,mBAAe,CAEf,mDACE,gBAAa,CAEjB,0BGDE,aAAS,CFqBK,4BAAG,CAAH,yBAAG,CAAH,uBAAG,CAAH,wBAAG,CARN,oBAAG,CDThB,yBGJE,aAAS,CHOX,wBACE,iBAAS,CACT,UAAM,CACN,WAAO,CACP,MAAK,CACL,KAAI,CACJ,mBAAe,CAEb,gDACE,mBAAe,CACnB,+BGjBA,YAAS,CHmBT,iDGnBA,eAAS,CHsBX,2BCDgB,4BAAG,CAAH,yBAAG,CAAH,uBAAG,CAAH,wBAAG,CARN,oBAAG,CDWd,aAAY,CACZ,WAAU,CAEZ,4BCscE,gBAAO,CDpcP,iDCocA,8DAAO,CDlcP,kDCkcA,8DAAO,CDhcP,6CCgcA,8DAAO,CD9bP,2CC8bA,8DAAO,CD3bT,6BC2bE,gBAAO,CDzbP,kDCybA,8DAAO,CDvbP,mDCubA,8DAAO,CDrbP,8CCqbA,8DAAO,CDnbP,4CCmbA,8DAAO,CD/aP,iCACE,UAAQ,CGnDV,aAAS,CHqDP,iBAAS,CChCG,6BAAG,CAAH,0BAAG,CARN,qBAAG,CD0CZ,MAAK,CACL,KAAI,CACJ,OAAM,CACN,QAAO,CIvET,0BAAQ,CH4PV,SAAS,CAQH,eAAY,CACZ,WAAQ,CArOE,6BAAG,CAAH,0BAAG,CAAH,wBAAG,CAAH,yBAAG,CARN,qBAAG,CDqDZ,iBAAW,CACb,uCACE,kBAAW,CC/CC,uCAAG,CAAH,oCAAG,CAAH,kCAAG,CAAH,mCAAG,CARN,+BAAG,CAoOhB,SAAS,CAWH,+DAAyE,CACzE,uBAAiC,CDrLzC,oBACE,iBAAS,CACT,yBE3EE,eAAU",sourcesContent:['@import \'~nib/index.styl\'\n\n.geojs-map\n position relative\n user-select none\n overflow hidden\n\n .geo-attribution\n position absolute\n right 0\n bottom 0\n padding-right 5px\n cursor auto\n font 11px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif\n z-index 1001\n background rgba(255,255,255,0.7)\n clear both\n display block\n pointer-events auto\n\n .geo-attribution-layer\n padding-left 5px\n\n .canvas-canvas\n display block\n transform-origin 0px 0px\n .webgl-canvas\n display block\n\n .geojs-layer\n position absolute\n width 100%\n height 100%\n left 0\n top 0\n pointer-events none\n &.active:not(.hidden)\n > *\n pointer-events auto\n &.hidden\n display none\n &.hidden[renderer="webgl"]\n display inherit\n\n .geo-tile-layer\n transform-origin 0px 0px\n line-height 0\n font-size 0\n\n &.annotation-input\n cursor crosshair\n &.annotation-intersect\n cursor embedurl("./css/cursor-crosshair-intersect.svg") 12 12,crosshair\n &.annotation-difference\n cursor embedurl("./css/cursor-crosshair-difference.svg") 12 12,crosshair\n &.annotation-union\n cursor embedurl("./css/cursor-crosshair-union.svg") 12 12,crosshair\n &.annotation-xor\n cursor embedurl("./css/cursor-crosshair-xor.svg") 12 12,crosshair\n\n &.annotation-cursor\n cursor crosshair\n &.annotation-intersect\n cursor embedurl("./css/cursor-crosshair-intersect.svg") 12 12,crosshair\n &.annotation-difference\n cursor embedurl("./css/cursor-crosshair-difference.svg") 12 12,crosshair\n &.annotation-union\n cursor embedurl("./css/cursor-crosshair-union.svg") 12 12,crosshair\n &.annotation-xor\n cursor embedurl("./css/cursor-crosshair-xor.svg") 12 12,crosshair\n\n &.highlight-focus\n &:after\n content ""\n display block\n position absolute\n box-sizing border-box\n left 0px\n top 0px\n right 0px\n bottom 0px\n // Highlight is technically a css2 color. We may need to specify it\n // explicitly. #3B66A6 seems close\n border 3px solid Highlight\n opacity 1\n transition opacity 0s\n visibility hidden\n &:focus:after\n visibility visible\n transition opacity 2.5s ease-in\n opacity 0\n\n.geo-tile-container\n position absolute\n &.crop\n overflow hidden\n',"use('../nodes/vendor-helpers.js')\n@import 'config'\n\n/*\n * Alias \"nowrap\" as \"no-wrap\".\n */\n\nno-wrap = unquote('nowrap')\n\n/*\n * Helper to find out if a given value is a width\n */\n\nis-width(val)\n if auto == val\n return true\n else if val && 'unit' == type(val)\n // Stylus does not short circuit so we need to perform this as a distinct\n // operation to prevent errors\n return '' != unit(val)\n return false\n\n/*\n * Vendor support for the given prop / arguments, optionally specifying the\n * only prefixes to utilize, or those which should be ignored.\n */\n\nvendor(prop, args, only = null, ignore = null, vendor-property = true)\n need_normalize = !vendor-property or prop in ('transition' 'transition-property' 'border-image' 'border-image-slice')\n for prefix in vendor-prefixes\n unless (only and !(prefix in only)) or (ignore and prefix in ignore)\n if official == prefix\n if need_normalize\n {prop}: normalize(prop,('%s' % args))\n else\n {prop}: args\n else\n newprop = prop\n newprop = '-' + prefix + '-' + prop if vendor-property\n\n if need_normalize\n {newprop}: normalize(prop,('%s' % args),prefix)\n else\n {newprop}: args\n/*\n * Vendorize the given value.\n */\n\nvendor-value(arg, only = null, ignore = null)\n prop = current-property[0]\n for prefix in vendor-prefixes\n unless (only and !(prefix in only)) or (ignore and prefix in ignore) or official == prefix\n add-property(prop, '-%s-%s' % (prefix arg))\n arg\n\n/*\n * Vendor \"box-shadow\" support.\n */\n\nbox-shadow()\n vendor('box-shadow', arguments, only: webkit official)\n\n/*\n * Vendor \"user-select\" support.\n */\n\nuser-select()\n vendor('user-select', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"column-count\" support.\n */\n\ncolumn-count()\n vendor('column-count', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-gap\" support.\n */\n\ncolumn-gap()\n vendor('column-gap', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule\" support.\n */\n\ncolumn-rule()\n vendor('column-rule', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-color\" support.\n */\n\ncolumn-rule-color()\n vendor('column-rule-color', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-width\" support.\n */\n\ncolumn-rule-width()\n vendor('column-rule-width', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-rule-style\" support.\n */\n\ncolumn-rule-style()\n vendor('column-rule-style', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-width\" support.\n */\n\ncolumn-width()\n vendor('column-width', arguments, only: webkit moz official)\n\n/*\n * Vendor \"column-span\" support.\n */\n\ncolumn-span()\n vendor('column-span', arguments, only: webkit official)\n\n/*\n * Vendor \"column-fill\" support.\n */\n\ncolumn-fill()\n vendor('column-fill', arguments, only: moz official)\n\n/*\n * Legacy syntax support for background-clip and background-origin\n */\n\nlegacy-bg-values(property, args)\n legacy_args = ()\n importance = unquote('')\n for subargs in args\n for arg in subargs\n if arg in (border-box padding-box content-box)\n arg = unquote('border') if arg == border-box\n arg = unquote('padding') if arg == padding-box\n arg = unquote('content') if arg == content-box\n if arg != '!important'\n push(legacy_args,arg)\n else\n importance = !important\n vendor(property, unquote(join(', ',legacy_args)) importance, only: moz webkit)\n\n/*\n * Vendor \"background-clip\" support.\n */\n\nbackground-clip()\n if arguments[0] == text\n vendor('background-clip', arguments, only: webkit)\n else\n legacy-bg-values('background-clip', arguments)\n background-clip: arguments\n\n/*\n * Vendor \"background-origin\" support.\n */\n\nbackground-origin()\n legacy-bg-values('background-origin', arguments)\n background-origin: arguments\n\n/*\n * Vendor \"transform\" support.\n */\n\ntransform()\n vendor('transform', arguments)\n\n/*\n * Vendor \"transform-origin\" support.\n */\ntransform-origin()\n vendor('transform-origin', arguments)\n\n/*\n * Vendor \"transform-style\" support.\n */\n\ntransform-style()\n vendor('transform-style', arguments)\n\n/*\n * Vendor \"border-image\" support.\n */\n\nborder-image()\n vendor('border-image', arguments, only: webkit moz o official)\n\n/*\n * Vendor \"transition\" support.\n */\n\ntransition()\n vendor('transition', arguments)\n\n/*\n * Vendor \"transition-property\" support.\n */\n\ntransition-property()\n vendor('transition-property', arguments)\n\n/*\n * Vendor \"transition-duration\" support.\n */\n\ntransition-duration()\n vendor('transition-duration', arguments)\n\n/*\n * Vendor \"transition-timing-function\" support.\n */\n\ntransition-timing-function()\n vendor('transition-timing-function', arguments)\n\n/*\n * Vendor \"transition-delay\" support.\n */\n\ntransition-delay()\n vendor('transition-delay', arguments)\n\n/*\n * Vendor \"backface-visibility\" support.\n */\n\nbackface-visibility()\n vendor('backface-visibility', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"perspective\" support.\n */\n\nperspective()\n if mixin\n vendor('perspective', arguments, only: webkit moz ms official)\n else\n 'perspective(%s)' % arguments\n\n/*\n * Vendor \"perspective-origin\" support.\n */\n\nperspective-origin()\n vendor('perspective-origin', arguments, only: webkit moz ms official)\n\n/*\n * Opacity with conditional IE support.\n */\n\nopacity(n, args...)\n opacity: n args\n if support-for-ie\n if n == inherit or n == initial\n -ms-filter: n args\n filter: n args\n else\n val = round(n * 100)\n if val == 100\n -ms-filter: none args\n filter: none args\n else\n -ms-filter: '\"progid:DXImageTransform.Microsoft.Alpha(Opacity=%s)\"' % val args\n filter: 'alpha(opacity=%s)' % val args\n\n/*\n * Vendor \"text-size-adjust\"\n */\n\ntext-size-adjust()\n vendor('text-size-adjust', arguments)\n\n/*\n * Alias the \"white-space\" property.\n */\n\nwhitespace()\n white-space: arguments\n\n/*\n * Vendor \"box-sizing\" support.\n */\n\nbox-sizing()\n vendor('box-sizing', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-orient\" support.\n */\n\nbox-orient()\n vendor('box-orient', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-flex-group\" support.\n */\n\nbox-flex-group()\n vendor('box-flex-group', arguments, only: webkit moz official)\n\n/*\n * Vendor \"box-ordinal-group\" support.\n */\n\nbox-ordinal-group()\n vendor('box-ordinal-group', arguments, only: webkit moz ms official)\n\n\n/*\n * Vendor \"box-align\" support.\n */\n\nbox-align()\n vendor('box-align', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"box-pack\" support.\n */\n\nbox-pack()\n vendor('box-pack', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"box-direction\" support.\n */\n\nbox-direction()\n vendor('box-direction', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"animation\" support.\n */\n\nanimation()\n vendor('animation', arguments)\n\n\n/*\n * Vendor \"animation-name\" support.\n */\n\nanimation-name()\n vendor('animation-name', arguments)\n\n/*\n * Vendor \"animation-duration\" support.\n */\n\nanimation-duration()\n vendor('animation-duration', arguments)\n\n/*\n * Vendor \"animation-delay\" support.\n */\n\nanimation-delay()\n vendor('animation-delay', arguments)\n\n/*\n * Vendor \"animation-direction\" support.\n */\n\nanimation-direction()\n vendor('animation-direction', arguments)\n\n/*\n * Vendor \"animation-iteration-count\" support.\n */\n\nanimation-iteration-count()\n vendor('animation-iteration-count', arguments)\n\n/*\n * Vendor \"animation-timing-function\" support.\n */\n\nanimation-timing-function()\n vendor('animation-timing-function', arguments)\n\n/*\n * Vendor \"animation-play-state\" support.\n */\n\nanimation-play-state()\n vendor('animation-play-state', arguments)\n\n/*\n * Vendor \"animation-fill-mode\" support.\n */\n\nanimation-fill-mode()\n vendor('animation-fill-mode', arguments)\n\n/*\n * Vendor \"hyphens\" support.\n */\n\nhyphens()\n vendor('hyphens', arguments, only: webkit moz ms official)\n\n/*\n * Vendor \"appearance\" support.\n */\n\nappearance()\n vendor('appearance', arguments, only: webkit moz official)\n\n/*\n * Vendor \"tab-size\" support.\n */\n\ntab-size()\n vendor('tab-size', arguments, only: moz o official)\n\n/*\n * Vendor \"overflow-scrolling\" support.\n */\n\noverflow-scrolling()\n vendor('overflow-scrolling', arguments, only: webkit official)\n\n/*\n * Vendor \"text-overflow\" support, , -o- for opera 9.* - 10.*\n */\n\ntext-overflow()\n vendor('text-overflow', arguments, only: official o)\n\n/*\n * Vendor \"text-size-adjust\" support.\n */\ntext-size-adjust()\n vendor('text-size-adjust', arguments, only: official webkit ms)\n\n/*\n * Vendor \"font-smoothing\" support, webkit only.\n */\nfont-smoothing()\n vendor('font-smoothing', arguments, only: webkit)\n\n\n/**\n * Vendor input-placeholder/placeholder support.\n *\n * Examples:\n * // Default syntax\n * body\n * placeholder(color #333, font-weight normal)\n *\n * // The comma is important\n * .placeholder-red\n * placeholder(color red,)\n *\n * // We can pass a function\n * green-placeholder()\n * color green\n * .placeholder-green\n * placeholder(green-placeholder)\n *\n * // We can pass a hash\n * textarea\n * placeholder((font-style italic) (font-weight bold) (padding '4px 10px'))\n */\nplaceholder()\n for v in ':-webkit-input' '-moz' ':-moz' '-ms-input'\n &:{v}-placeholder\n for pair in arguments\n if typeof(pair) == 'function'\n pair()\n else if pair is not null && pair[0] is not null\n {pair[0]}: type(pair[1]) == 'string' ? s(pair[1]) : pair[1]\ninput-placeholder = placeholder\n\n/*\n * Vendor background support (gradients).\n */\n\nbackground()\n if match('-gradient\\(', ''+arguments)\n vendor('background', arguments, vendor-property: false)\n else\n background arguments\n\nbackground-image()\n if match('-gradient\\(', ''+arguments)\n vendor('background-image', arguments, vendor-property: false)\n else\n background-image arguments\n\ncursor()\n if match('-gradient\\(', ''+arguments)\n vendor('cursor', arguments, vendor-property: false)\n else\n cursor arguments\n\nlist-style()\n if match('-gradient\\(', ''+arguments)\n vendor('list-style', arguments, vendor-property: false)\n else\n list-style arguments\n\nlist-style-image()\n if match('-gradient\\(', ''+arguments)\n vendor('list-style-image', arguments, vendor-property: false)\n else\n list-style-image arguments\n","/*\n * Overflow utility. Maps to regular overflow, and adds an ellipsis value.\n *\n * Synopsis:\n *\n * overflow: <type>\n *\n * Examples:\n *\n * overflow: auto\n * overflow: hidden\n * overflow: ellipsis\n *\n */\n\noverflow()\n if arguments[0] == ellipsis\n ellipsis()\n else\n overflow: arguments\n","/*\n * Vendor \"display: flex\" support with fallback to obsolete versions.\n */\n\nflex-version ?= box flex\n\n//\n// 1. Display values\n// - http://www.w3.org/TR/css3-flexbox/#flex-containers\n//\ndisplay(type, args...)\n if flex == type || inline-flex == type\n if box in flex-version\n if flex == type\n display: -ms-flexbox args\n display: vendor-value(box args, only: moz webkit)\n else\n display: -ms-inline-flexbox args\n display: vendor-value(inline-box args, only: moz webkit)\n if flex in flex-version\n display: vendor-value(arguments, only: webkit official) // overwrites old webkit\n else\n display: arguments\n\n/*\n * New syntax for browsers like Google Chrome.\n * Plus a translation to the old syntax, if possible.\n */\n\n\n//\n// 5. Ordering and Orientation\n// - http://www.w3.org/TR/css3-flexbox/#ordering-and-orientation\n//\n-flex-obsolete-direction(direction)\n if box in flex-version\n if row-reverse == direction || column-reverse == direction\n vendor('box-direction', reverse, ignore: ms official)\n\n if row == direction || row-reverse == direction\n vendor('box-orient', horizontal, ignore: ms official)\n else if column == direction || column-reverse == direction\n vendor('box-orient', vertical, ignore: ms official)\n\n-flex-obsolete-wrap(value)\n if box in flex-version\n // WARN: wrap-reverse does not have a box equivalent. This will render in different manners\n // on box vs. flex values.\n if 'wrap' == value || wrap-reverse == value\n vendor('box-lines', multiple, ignore: ms official)\n else if nowrap == value\n vendor('box-lines', single, ignore: ms official)\n\nflex-direction(direction)\n // obsolete\n -flex-obsolete-direction(direction)\n\n // new\n if flex in flex-version\n vendor('flex-direction', arguments, only: webkit ms official)\n\nflex-wrap(value)\n // obsolete\n -flex-obsolete-wrap(value)\n\n if flex in flex-version\n vendor('flex-wrap', arguments, only: webkit ms official)\n\nflex-flow()\n // obsolete\n -flex-obsolete-direction(arguments[0])\n -flex-obsolete-direction(arguments[1])\n -flex-obsolete-wrap(arguments[0])\n -flex-obsolete-wrap(arguments[1])\n\n // new\n if flex in flex-version\n vendor('flex-flow', arguments, only: webkit ms official)\n\n\norder()\n // obsolete\n if box in flex-version\n vendor('box-ordinal-group', arguments, ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-order', arguments, only: ms)\n vendor('order', arguments, only: webkit official)\n\n\n//\n// 7. Flexibility\n// - http://www.w3.org/TR/css3-flexbox/#flexibility\n//\nflex-grow(growth)\n // obsolete\n if box in flex-version\n vendor('box-flex', growth)\n\n // new\n if flex in flex-version\n vendor('flex-grow', arguments, only: webkit official)\n\nflex-basis()\n if flex in flex-version\n vendor('flex-basis', arguments, only: webkit official)\n\nflex-shrink()\n if flex in flex-version\n vendor('flex-shrink', arguments, only: webkit official)\n\nflex(growth)\n\n // obsolete\n if box in flex-version\n shrink = 1\n\n if none == growth || initial == growth\n // Well known values\n shrink = 0 if none == growth\n growth = 0\n else if is-width(growth) == true\n // Basis is defined as the first parameter\n growth = arguments[1] || 0\n shrink = arguments[2] if 3 <= length(arguments)\n else if arguments[1] && is-width(arguments[1]) == false\n // Growth is first and shrink is second\n shrink = arguments[1]\n\n // Since we can't make the distinction between growing and shrinking in the box model, take\n // the one that provides the most flexibility.\n vendor('box-flex', max(growth, shrink), ignore: ms)\n\n // new\n if flex in flex-version\n vendor('flex', arguments, only: webkit ms official)\n\n\n// converts the justification alignment\n-convert-justify(align)\n if flex-start == align\n return start\n else if flex-end == align\n return end\n else if space-around == align\n return distribute\n else if space-between == align\n return justify\n else\n return align\n\n//\n// 8. Alignment\n// - http://www.w3.org/TR/css3-flexbox/#alignment\n//\njustify-content(align)\n // obsolete\n if box in flex-version\n vendor('box-pack', -convert-justify(align), ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-pack', -convert-justify(align), only: ms)\n vendor('justify-content', align, only: webkit official)\n\nalign-content(align)\n // WARN: Obsolete spec does not allow for adjustment here\n if flex in flex-version\n vendor('flex-line-pack', -convert-justify(align), only: ms)\n vendor('align-content', align, only: webkit official)\n\n// converts alignment from 'flex' to normal value\n-convert-alignment(align)\n if flex-start == align\n return start\n else if flex-end == align\n return end\n else\n return align\n\nalign-items(align)\n // obsolete\n if box in flex-version\n vendor('box-align', -convert-alignment(align), ignore: ms official)\n\n // new\n if flex in flex-version\n vendor('flex-align', -convert-alignment(align), only: ms)\n vendor('align-items', arguments, only: webkit official)\n\nalign-self(align)\n // WARN: Obsolete spec does not allow for overriding alignment on individual items.\n if flex in flex-version\n vendor('align-self', align, only: webkit official)\n vendor('flex-item-align', -convert-alignment(align), only: ms)\n","/*\n * border: <color>\n * border: ...\n */\n\nborder(color, args...)\n if color is a 'color'\n border: 1px solid color args\n else\n border: arguments\n"],sourceRoot:""}]),e.A=d},7046:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o)()(i());a.push([t.id,".color-legend-container{display:none;padding:10px;border:1.5px solid #000;border-radius:3px;transition:250ms background linear;background-color:rgba(255,255,255,0.75)}.color-legend-container:hover{background-color:#fff}.color-legend-container .geojs-color-legends .geojs-color-legend{margin-bottom:10px}.color-legend-container .geojs-color-legends .geojs-color-legend .geojs-title{text-align:center}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg{display:block}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x path.domain,.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x line{fill:none;stroke:#000;stroke-width:.7}.color-legend-container .geojs-color-legends .geojs-color-legend svg.svg .axis.x text{font-size:12px}.color-legend-container .color-legend-popup{position:absolute;background:#fff;height:22px;font-size:14px;border:solid 1px #000;padding:0 5px;pointer-events:none;white-space:nowrap;z-index:100000;opacity:0}","",{version:3,sources:["webpack://./ui/colorLegendWidget.styl"],names:[],mappings:"AAAA,wBACE,YAAQ,CACR,YAAQ,CACR,uBAAO,CACP,iBAAc,CACd,kCAAW,CACX,uCAAiB,CAEjB,8BACE,qBAAiB,CAIjB,iEACE,kBAAc,CAEd,8EACE,iBAAW,CAEb,yEACE,aAAQ,CAGN,mLACE,SAAK,CACL,WAAO,CACP,eAAa,CACf,sFACE,cAAU,CAEpB,4CACE,iBAAS,CACT,eAAW,CACX,WAAO,CACP,cAAU,CACV,qBAAO,CACP,aAAQ,CACR,mBAAe,CACf,kBAAY,CACZ,cAAQ,CACR,SAAQ",sourcesContent:[".color-legend-container\n display none\n padding 10px\n border 1.5px solid black\n border-radius 3px\n transition 250ms background linear\n background-color rgba(255, 255, 255, 0.75)\n\n &:hover\n background-color rgba(255, 255, 255, 1)\n\n .geojs-color-legends\n\n .geojs-color-legend\n margin-bottom 10px\n\n .geojs-title\n text-align center\n\n svg.svg\n display block\n\n .axis.x\n path.domain, line\n fill none\n stroke black\n stroke-width 0.7\n text\n font-size 12px\n\n .color-legend-popup\n position absolute\n background white\n height 22px\n font-size 14px\n border solid 1px black\n padding 0 5px\n pointer-events none\n white-space nowrap\n z-index 100000\n opacity 0\n"],sourceRoot:""}]),e.A=a},5290:function(t,e,n){"use strict";var r=n(4942),i=n.n(r),o=n(278),a=n.n(o)()(i());a.push([t.id,".geojs-scale-widget-bar{stroke:#000}.geojs-scale-widget-text{font-weight:bold;font-size:16px;font-family:serif}","",{version:3,sources:["webpack://./ui/scaleWidget.styl"],names:[],mappings:"AAAA,wBACE,WAAO,CACT,yBACE,gBAAY,CACZ,cAAU,CACV,iBAAY",sourcesContent:[".geojs-scale-widget-bar\n stroke black\n.geojs-scale-widget-text\n font-weight bold\n font-size 16px\n font-family serif\n"],sourceRoot:""}]),e.A=a},278:function(t){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,i,o){"string"==typeof t&&(t=[[null,t,void 0]]);var a={};if(r)for(var s=0;s<this.length;s++){var u=this[s][0];null!=u&&(a[u]=!0)}for(var l=0;l<t.length;l++){var c=[].concat(t[l]);r&&a[c[0]]||(void 0!==o&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=o),n&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=n):c[2]=n),i&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=i):c[4]="".concat(i)),e.push(c))}},e}},3021:function(t){"use strict";t.exports=function(t,e){return e||(e={}),t?(t=String(t.__esModule?t.default:t),/^['"].*['"]$/.test(t)&&(t=t.slice(1,-1)),e.hash&&(t+=e.hash),/["'() \t\n]|(%20)/.test(t)||e.needQuotes?'"'.concat(t.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):t):t}},4942:function(t){"use strict";t.exports=function(t){var e=t[1],n=t[3];if(!n)return e;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),i="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),o="/*# ".concat(i," */");return[e].concat([o]).join("\n")}return[e].join("\n")}},3369:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8];return t[0]=a*c-s*l,t[1]=i*l-r*c,t[2]=r*s-i*a,t[3]=s*u-o*c,t[4]=n*c-i*u,t[5]=i*o-n*s,t[6]=o*l-a*u,t[7]=r*u-n*l,t[8]=n*a-r*o,t}},5723:function(t){t.exports=function(t){var e=new Float32Array(9);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e}},817:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}},6396:function(t){t.exports=function(){var t=new Float32Array(9);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}},9133:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8];return e*(l*o-a*u)+n*(a*s-l*i)+r*(u*i-o*s)}},7053:function(t){t.exports=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]+t[3]*t[3]+t[4]*t[4]+t[5]*t[5]+t[6]*t[6]+t[7]*t[7]+t[8]*t[8])}},7068:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=0,t[3]=e[2],t[4]=e[3],t[5]=0,t[6]=e[4],t[7]=e[5],t[8]=1,t}},5018:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[4],t[4]=e[5],t[5]=e[6],t[6]=e[8],t[7]=e[9],t[8]=e[10],t}},3955:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,f=r*s,h=i*a,d=i*s,p=i*u,m=o*a,g=o*s,y=o*u;return t[0]=1-f-p,t[3]=c-y,t[6]=h+g,t[1]=c+y,t[4]=1-l-p,t[7]=d-m,t[2]=h-g,t[5]=d+m,t[8]=1-l-f,t}},6658:function(t){t.exports=function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}},3638:function(t,e,n){t.exports={adjoint:n(3369),clone:n(5723),copy:n(817),create:n(6396),determinant:n(9133),frob:n(7053),fromMat2:n(7068),fromMat4:n(5018),fromQuat:n(3955),identity:n(6658),invert:n(6028),multiply:n(4980),normalFromMat4:n(8093),rotate:n(8163),scale:n(2311),str:n(6321),translate:n(5068),transpose:n(6333)}},6028:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=c*a-s*l,h=-c*o+s*u,d=l*o-a*u,p=n*f+r*h+i*d;return p?(p=1/p,t[0]=f*p,t[1]=(-c*r+i*l)*p,t[2]=(s*r-i*a)*p,t[3]=h*p,t[4]=(c*n-i*u)*p,t[5]=(-s*n+i*o)*p,t[6]=d*p,t[7]=(-l*n+r*u)*p,t[8]=(a*n-r*o)*p,t):null}},4980:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=n[0],d=n[1],p=n[2],m=n[3],g=n[4],y=n[5],v=n[6],x=n[7],_=n[8];return t[0]=h*r+d*a+p*l,t[1]=h*i+d*s+p*c,t[2]=h*o+d*u+p*f,t[3]=m*r+g*a+y*l,t[4]=m*i+g*s+y*c,t[5]=m*o+g*u+y*f,t[6]=v*r+x*a+_*l,t[7]=v*i+x*s+_*c,t[8]=v*o+x*u+_*f,t}},8093:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15],v=n*s-r*a,x=n*u-i*a,_=n*l-o*a,b=r*u-i*s,w=r*l-o*s,M=i*l-o*u,A=c*m-f*p,T=c*g-h*p,E=c*y-d*p,C=f*g-h*m,k=f*y-d*m,S=h*y-d*g,O=v*S-x*k+_*C+b*E-w*T+M*A;return O?(O=1/O,t[0]=(s*S-u*k+l*C)*O,t[1]=(u*E-a*S-l*T)*O,t[2]=(a*k-s*E+l*A)*O,t[3]=(i*k-r*S-o*C)*O,t[4]=(n*S-i*E+o*T)*O,t[5]=(r*E-n*k-o*A)*O,t[6]=(m*M-g*w+y*b)*O,t[7]=(g*_-p*M-y*x)*O,t[8]=(p*w-m*_+y*v)*O,t):null}},8163:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=Math.sin(n),d=Math.cos(n);return t[0]=d*r+h*a,t[1]=d*i+h*s,t[2]=d*o+h*u,t[3]=d*a-h*r,t[4]=d*s-h*i,t[5]=d*u-h*o,t[6]=l,t[7]=c,t[8]=f,t}},2311:function(t){t.exports=function(t,e,n){var r=n[0],i=n[1];return t[0]=r*e[0],t[1]=r*e[1],t[2]=r*e[2],t[3]=i*e[3],t[4]=i*e[4],t[5]=i*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}},6321:function(t){t.exports=function(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"}},5068:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=n[0],d=n[1];return t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=h*r+d*a+l,t[7]=h*i+d*s+c,t[8]=h*o+d*u+f,t}},6333:function(t){t.exports=function(t,e){if(t===e){var n=e[1],r=e[2],i=e[5];t[1]=e[3],t[2]=e[6],t[3]=n,t[5]=e[7],t[6]=r,t[7]=i}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t}},5200:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15];return t[0]=s*(h*y-d*g)-f*(u*y-l*g)+m*(u*d-l*h),t[1]=-(r*(h*y-d*g)-f*(i*y-o*g)+m*(i*d-o*h)),t[2]=r*(u*y-l*g)-s*(i*y-o*g)+m*(i*l-o*u),t[3]=-(r*(u*d-l*h)-s*(i*d-o*h)+f*(i*l-o*u)),t[4]=-(a*(h*y-d*g)-c*(u*y-l*g)+p*(u*d-l*h)),t[5]=n*(h*y-d*g)-c*(i*y-o*g)+p*(i*d-o*h),t[6]=-(n*(u*y-l*g)-a*(i*y-o*g)+p*(i*l-o*u)),t[7]=n*(u*d-l*h)-a*(i*d-o*h)+c*(i*l-o*u),t[8]=a*(f*y-d*m)-c*(s*y-l*m)+p*(s*d-l*f),t[9]=-(n*(f*y-d*m)-c*(r*y-o*m)+p*(r*d-o*f)),t[10]=n*(s*y-l*m)-a*(r*y-o*m)+p*(r*l-o*s),t[11]=-(n*(s*d-l*f)-a*(r*d-o*f)+c*(r*l-o*s)),t[12]=-(a*(f*g-h*m)-c*(s*g-u*m)+p*(s*h-u*f)),t[13]=n*(f*g-h*m)-c*(r*g-i*m)+p*(r*h-i*f),t[14]=-(n*(s*g-u*m)-a*(r*g-i*m)+p*(r*u-i*s)),t[15]=n*(s*h-u*f)-a*(r*h-i*f)+c*(r*u-i*s),t}},1130:function(t){t.exports=function(t){var e=new Float32Array(16);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}},74:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}},3783:function(t){t.exports=function(){var t=new Float32Array(16);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},8844:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8],c=t[9],f=t[10],h=t[11],d=t[12],p=t[13],m=t[14],g=t[15];return(e*a-n*o)*(f*g-h*m)-(e*s-r*o)*(c*g-h*p)+(e*u-i*o)*(c*m-f*p)+(n*s-r*a)*(l*g-h*d)-(n*u-i*a)*(l*m-f*d)+(r*u-i*s)*(l*p-c*d)}},5936:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,f=r*s,h=i*a,d=i*s,p=i*u,m=o*a,g=o*s,y=o*u;return t[0]=1-f-p,t[1]=c+y,t[2]=h-g,t[3]=0,t[4]=c-y,t[5]=1-l-p,t[6]=d+m,t[7]=0,t[8]=h+g,t[9]=d-m,t[10]=1-l-f,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},5405:function(t){t.exports=function(t,e,n){var r,i,o,a=n[0],s=n[1],u=n[2],l=Math.sqrt(a*a+s*s+u*u);if(Math.abs(l)<1e-6)return null;return a*=l=1/l,s*=l,u*=l,r=Math.sin(e),i=Math.cos(e),o=1-i,t[0]=a*a*o+i,t[1]=s*a*o+u*r,t[2]=u*a*o-s*r,t[3]=0,t[4]=a*s*o-u*r,t[5]=s*s*o+i,t[6]=u*s*o+a*r,t[7]=0,t[8]=a*u*o+s*r,t[9]=s*u*o-a*r,t[10]=u*u*o+i,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3310:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=r+r,u=i+i,l=o+o,c=r*s,f=r*u,h=r*l,d=i*u,p=i*l,m=o*l,g=a*s,y=a*u,v=a*l;return t[0]=1-(d+m),t[1]=f+v,t[2]=h-y,t[3]=0,t[4]=f-v,t[5]=1-(c+m),t[6]=p+g,t[7]=0,t[8]=h+y,t[9]=p-g,t[10]=1-(c+d),t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}},1826:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=e[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},4692:function(t){t.exports=function(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=e[0],t[13]=e[1],t[14]=e[2],t[15]=1,t}},1349:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=r,t[6]=n,t[7]=0,t[8]=0,t[9]=-n,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},8034:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=0,t[2]=-n,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=n,t[9]=0,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},1655:function(t){t.exports=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=n,t[2]=0,t[3]=0,t[4]=-n,t[5]=r,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3277:function(t){t.exports=function(t,e,n,r,i,o,a){var s=1/(n-e),u=1/(i-r),l=1/(o-a);return t[0]=2*o*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*o*u,t[6]=0,t[7]=0,t[8]=(n+e)*s,t[9]=(i+r)*u,t[10]=(a+o)*l,t[11]=-1,t[12]=0,t[13]=0,t[14]=a*o*2*l,t[15]=0,t}},257:function(t){t.exports=function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}},3503:function(t,e,n){t.exports={create:n(3783),clone:n(1130),copy:n(74),identity:n(257),transpose:n(2664),invert:n(6583),adjoint:n(5200),determinant:n(8844),multiply:n(9899),translate:n(573),scale:n(177),rotate:n(648),rotateX:n(5618),rotateY:n(5345),rotateZ:n(5208),fromRotation:n(5405),fromRotationTranslation:n(3310),fromScaling:n(1826),fromTranslation:n(4692),fromXRotation:n(1349),fromYRotation:n(8034),fromZRotation:n(1655),fromQuat:n(5936),frustum:n(3277),perspective:n(2649),perspectiveFromFieldOfView:n(7733),ortho:n(2337),lookAt:n(8541),str:n(6600)}},6583:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],y=e[15],v=n*s-r*a,x=n*u-i*a,_=n*l-o*a,b=r*u-i*s,w=r*l-o*s,M=i*l-o*u,A=c*m-f*p,T=c*g-h*p,E=c*y-d*p,C=f*g-h*m,k=f*y-d*m,S=h*y-d*g,O=v*S-x*k+_*C+b*E-w*T+M*A;if(!O)return null;return O=1/O,t[0]=(s*S-u*k+l*C)*O,t[1]=(i*k-r*S-o*C)*O,t[2]=(m*M-g*w+y*b)*O,t[3]=(h*w-f*M-d*b)*O,t[4]=(u*E-a*S-l*T)*O,t[5]=(n*S-i*E+o*T)*O,t[6]=(g*_-p*M-y*x)*O,t[7]=(c*M-h*_+d*x)*O,t[8]=(a*k-s*E+l*A)*O,t[9]=(r*E-n*k-o*A)*O,t[10]=(p*w-m*_+y*v)*O,t[11]=(f*_-c*w-d*v)*O,t[12]=(s*T-a*C-u*A)*O,t[13]=(n*C-r*T+i*A)*O,t[14]=(m*x-p*b-g*v)*O,t[15]=(c*b-f*x+h*v)*O,t}},8541:function(t,e,n){var r=n(257);t.exports=function(t,e,n,i){var o,a,s,u,l,c,f,h,d,p,m=e[0],g=e[1],y=e[2],v=i[0],x=i[1],_=i[2],b=n[0],w=n[1],M=n[2];if(Math.abs(m-b)<1e-6&&Math.abs(g-w)<1e-6&&Math.abs(y-M)<1e-6)return r(t);f=m-b,h=g-w,d=y-M,p=1/Math.sqrt(f*f+h*h+d*d),o=x*(d*=p)-_*(h*=p),a=_*(f*=p)-v*d,s=v*h-x*f,(p=Math.sqrt(o*o+a*a+s*s))?(o*=p=1/p,a*=p,s*=p):(o=0,a=0,s=0);u=h*s-d*a,l=d*o-f*s,c=f*a-h*o,(p=Math.sqrt(u*u+l*l+c*c))?(u*=p=1/p,l*=p,c*=p):(u=0,l=0,c=0);return t[0]=o,t[1]=u,t[2]=f,t[3]=0,t[4]=a,t[5]=l,t[6]=h,t[7]=0,t[8]=s,t[9]=c,t[10]=d,t[11]=0,t[12]=-(o*m+a*g+s*y),t[13]=-(u*m+l*g+c*y),t[14]=-(f*m+h*g+d*y),t[15]=1,t}},9899:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=e[9],d=e[10],p=e[11],m=e[12],g=e[13],y=e[14],v=e[15],x=n[0],_=n[1],b=n[2],w=n[3];return t[0]=x*r+_*s+b*f+w*m,t[1]=x*i+_*u+b*h+w*g,t[2]=x*o+_*l+b*d+w*y,t[3]=x*a+_*c+b*p+w*v,x=n[4],_=n[5],b=n[6],w=n[7],t[4]=x*r+_*s+b*f+w*m,t[5]=x*i+_*u+b*h+w*g,t[6]=x*o+_*l+b*d+w*y,t[7]=x*a+_*c+b*p+w*v,x=n[8],_=n[9],b=n[10],w=n[11],t[8]=x*r+_*s+b*f+w*m,t[9]=x*i+_*u+b*h+w*g,t[10]=x*o+_*l+b*d+w*y,t[11]=x*a+_*c+b*p+w*v,x=n[12],_=n[13],b=n[14],w=n[15],t[12]=x*r+_*s+b*f+w*m,t[13]=x*i+_*u+b*h+w*g,t[14]=x*o+_*l+b*d+w*y,t[15]=x*a+_*c+b*p+w*v,t}},2337:function(t){t.exports=function(t,e,n,r,i,o,a){var s=1/(e-n),u=1/(r-i),l=1/(o-a);return t[0]=-2*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*u,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*l,t[11]=0,t[12]=(e+n)*s,t[13]=(i+r)*u,t[14]=(a+o)*l,t[15]=1,t}},2649:function(t){t.exports=function(t,e,n,r,i){var o=1/Math.tan(e/2),a=1/(r-i);return t[0]=o/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=o,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=(i+r)*a,t[11]=-1,t[12]=0,t[13]=0,t[14]=2*i*r*a,t[15]=0,t}},7733:function(t){t.exports=function(t,e,n,r){var i=Math.tan(e.upDegrees*Math.PI/180),o=Math.tan(e.downDegrees*Math.PI/180),a=Math.tan(e.leftDegrees*Math.PI/180),s=Math.tan(e.rightDegrees*Math.PI/180),u=2/(a+s),l=2/(i+o);return t[0]=u,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=l,t[6]=0,t[7]=0,t[8]=-(a-s)*u*.5,t[9]=(i-o)*l*.5,t[10]=r/(n-r),t[11]=-1,t[12]=0,t[13]=0,t[14]=r*n/(n-r),t[15]=0,t}},648:function(t){t.exports=function(t,e,n,r){var i,o,a,s,u,l,c,f,h,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k=r[0],S=r[1],O=r[2],P=Math.sqrt(k*k+S*S+O*O);if(Math.abs(P)<1e-6)return null;k*=P=1/P,S*=P,O*=P,i=Math.sin(n),o=Math.cos(n),a=1-o,s=e[0],u=e[1],l=e[2],c=e[3],f=e[4],h=e[5],d=e[6],p=e[7],m=e[8],g=e[9],y=e[10],v=e[11],x=k*k*a+o,_=S*k*a+O*i,b=O*k*a-S*i,w=k*S*a-O*i,M=S*S*a+o,A=O*S*a+k*i,T=k*O*a+S*i,E=S*O*a-k*i,C=O*O*a+o,t[0]=s*x+f*_+m*b,t[1]=u*x+h*_+g*b,t[2]=l*x+d*_+y*b,t[3]=c*x+p*_+v*b,t[4]=s*w+f*M+m*A,t[5]=u*w+h*M+g*A,t[6]=l*w+d*M+y*A,t[7]=c*w+p*M+v*A,t[8]=s*T+f*E+m*C,t[9]=u*T+h*E+g*C,t[10]=l*T+d*E+y*C,t[11]=c*T+p*E+v*C,e!==t&&(t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t}},5618:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[4],a=e[5],s=e[6],u=e[7],l=e[8],c=e[9],f=e[10],h=e[11];e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[4]=o*i+l*r,t[5]=a*i+c*r,t[6]=s*i+f*r,t[7]=u*i+h*r,t[8]=l*i-o*r,t[9]=c*i-a*r,t[10]=f*i-s*r,t[11]=h*i-u*r,t}},5345:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[8],c=e[9],f=e[10],h=e[11];e!==t&&(t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[0]=o*i-l*r,t[1]=a*i-c*r,t[2]=s*i-f*r,t[3]=u*i-h*r,t[8]=o*r+l*i,t[9]=a*r+c*i,t[10]=s*r+f*i,t[11]=u*r+h*i,t}},5208:function(t){t.exports=function(t,e,n){var r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[4],c=e[5],f=e[6],h=e[7];e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]);return t[0]=o*i+l*r,t[1]=a*i+c*r,t[2]=s*i+f*r,t[3]=u*i+h*r,t[4]=l*i-o*r,t[5]=c*i-a*r,t[6]=f*i-s*r,t[7]=h*i-u*r,t}},177:function(t){t.exports=function(t,e,n){var r=n[0],i=n[1],o=n[2];return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}},6600:function(t){t.exports=function(t){return"mat4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+", "+t[9]+", "+t[10]+", "+t[11]+", "+t[12]+", "+t[13]+", "+t[14]+", "+t[15]+")"}},573:function(t){t.exports=function(t,e,n){var r,i,o,a,s,u,l,c,f,h,d,p,m=n[0],g=n[1],y=n[2];e===t?(t[12]=e[0]*m+e[4]*g+e[8]*y+e[12],t[13]=e[1]*m+e[5]*g+e[9]*y+e[13],t[14]=e[2]*m+e[6]*g+e[10]*y+e[14],t[15]=e[3]*m+e[7]*g+e[11]*y+e[15]):(r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=e[9],d=e[10],p=e[11],t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=l,t[7]=c,t[8]=f,t[9]=h,t[10]=d,t[11]=p,t[12]=r*m+s*g+f*y+e[12],t[13]=i*m+u*g+h*y+e[13],t[14]=o*m+l*g+d*y+e[14],t[15]=a*m+c*g+p*y+e[15]);return t}},2664:function(t){t.exports=function(t,e){if(t===e){var n=e[1],r=e[2],i=e[3],o=e[6],a=e[7],s=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=n,t[6]=e[9],t[7]=e[13],t[8]=r,t[9]=o,t[11]=e[14],t[12]=i,t[13]=a,t[14]=s}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t}},3197:function(t){t.exports=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t}},577:function(t,e,n){t.exports=function(t,e){var n=r(t[0],t[1],t[2]),a=r(e[0],e[1],e[2]);i(n,n),i(a,a);var s=o(n,a);return s>1?0:Math.acos(s)};var r=n(9666),i=n(1205),o=n(6517)},9913:function(t){t.exports=function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t[2]=Math.ceil(e[2]),t}},7091:function(t){t.exports=function(t){var e=new Float32Array(3);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}},3497:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}},1220:function(t){t.exports=function(){var t=new Float32Array(3);return t[0]=0,t[1]=0,t[2]=0,t}},6902:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2];return t[0]=i*u-o*s,t[1]=o*a-r*u,t[2]=r*s-i*a,t}},5140:function(t,e,n){t.exports=n(5055)},5055:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.sqrt(n*n+r*r+i*i)}},6669:function(t,e,n){t.exports=n(9737)},9737:function(t){t.exports=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t}},6517:function(t){t.exports=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}},6532:function(t){t.exports=1e-6},1077:function(t,e,n){t.exports=function(t,e){var n=t[0],i=t[1],o=t[2],a=e[0],s=e[1],u=e[2];return Math.abs(n-a)<=r*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(i-s)<=r*Math.max(1,Math.abs(i),Math.abs(s))&&Math.abs(o-u)<=r*Math.max(1,Math.abs(o),Math.abs(u))};var r=n(6532)},5696:function(t){t.exports=function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}},4280:function(t){t.exports=function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t[2]=Math.floor(e[2]),t}},9436:function(t,e,n){t.exports=function(t,e,n,i,o,a){var s,u;e||(e=3);n||(n=0);u=i?Math.min(i*e+n,t.length):t.length;for(s=n;s<u;s+=e)r[0]=t[s],r[1]=t[s+1],r[2]=t[s+2],o(r,r,a),t[s]=r[0],t[s+1]=r[1],t[s+2]=r[2];return t};var r=n(1220)()},9666:function(t){t.exports=function(t,e,n){var r=new Float32Array(3);return r[0]=t,r[1]=e,r[2]=n,r}},1982:function(t,e,n){t.exports={EPSILON:n(6532),create:n(1220),clone:n(7091),angle:n(577),fromValues:n(9666),copy:n(3497),set:n(3926),equals:n(1077),exactEquals:n(5696),add:n(3197),subtract:n(1040),sub:n(8560),multiply:n(8044),mul:n(8516),divide:n(9737),div:n(6669),min:n(4370),max:n(7484),floor:n(4280),ceil:n(9913),round:n(4622),scale:n(9404),scaleAndAdd:n(8544),distance:n(5055),dist:n(5140),squaredDistance:n(2340),sqrDist:n(3108),length:n(9852),len:n(4001),squaredLength:n(2775),sqrLen:n(9249),negate:n(2926),inverse:n(3346),normalize:n(1205),dot:n(6517),cross:n(6902),lerp:n(1817),random:n(9463),transformMat4:n(9564),transformMat3:n(553),transformQuat:n(4997),rotateX:n(6899),rotateY:n(8028),rotateZ:n(5493),forEach:n(9436)}},3346:function(t){t.exports=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t}},4001:function(t,e,n){t.exports=n(9852)},9852:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)}},1817:function(t){t.exports=function(t,e,n,r){var i=e[0],o=e[1],a=e[2];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=a+r*(n[2]-a),t}},7484:function(t){t.exports=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t}},4370:function(t){t.exports=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t}},8516:function(t,e,n){t.exports=n(8044)},8044:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t}},2926:function(t){t.exports=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}},1205:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o);return t}},9463:function(t){t.exports=function(t,e){e=e||1;var n=2*Math.random()*Math.PI,r=2*Math.random()-1,i=Math.sqrt(1-r*r)*e;return t[0]=Math.cos(n)*i,t[1]=Math.sin(n)*i,t[2]=r*e,t}},6899:function(t){t.exports=function(t,e,n,r){var i=n[1],o=n[2],a=e[1]-i,s=e[2]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=e[0],t[1]=i+a*l-s*u,t[2]=o+a*u+s*l,t}},8028:function(t){t.exports=function(t,e,n,r){var i=n[0],o=n[2],a=e[0]-i,s=e[2]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=i+s*u+a*l,t[1]=e[1],t[2]=o+s*l-a*u,t}},5493:function(t){t.exports=function(t,e,n,r){var i=n[0],o=n[1],a=e[0]-i,s=e[1]-o,u=Math.sin(r),l=Math.cos(r);return t[0]=i+a*l-s*u,t[1]=o+a*u+s*l,t[2]=e[2],t}},4622:function(t){t.exports=function(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t[2]=Math.round(e[2]),t}},9404:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t}},8544:function(t){t.exports=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t}},3926:function(t){t.exports=function(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,t}},3108:function(t,e,n){t.exports=n(2340)},9249:function(t,e,n){t.exports=n(2775)},2340:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return n*n+r*r+i*i}},2775:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2];return e*e+n*n+r*r}},8560:function(t,e,n){t.exports=n(1040)},1040:function(t){t.exports=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}},553:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2];return t[0]=r*n[0]+i*n[3]+o*n[6],t[1]=r*n[1]+i*n[4]+o*n[7],t[2]=r*n[2]+i*n[5]+o*n[8],t}},9564:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,t}},4997:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2],l=n[3],c=l*r+s*o-u*i,f=l*i+u*r-a*o,h=l*o+a*i-s*r,d=-a*r-s*i-u*o;return t[0]=c*l+d*-a+f*-u-h*-s,t[1]=f*l+d*-s+h*-a-c*-u,t[2]=h*l+d*-u+c*-s-f*-a,t}},2108:function(t){t.exports=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t}},7682:function(t){t.exports=function(t){var e=new Float32Array(4);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}},9298:function(t){t.exports=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}},3071:function(t){t.exports=function(){var t=new Float32Array(4);return t[0]=0,t[1]=0,t[2]=0,t[3]=0,t}},5476:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],o=e[3]-t[3];return Math.sqrt(n*n+r*r+i*i+o*o)}},1350:function(t){t.exports=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t[3]=e[3]/n[3],t}},216:function(t){t.exports=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]}},8741:function(t){t.exports=function(t,e,n,r){var i=new Float32Array(4);return i[0]=t,i[1]=e,i[2]=n,i[3]=r,i}},4663:function(t,e,n){t.exports={create:n(3071),clone:n(7682),fromValues:n(8741),copy:n(9298),set:n(6675),add:n(2108),subtract:n(6919),multiply:n(9363),divide:n(1350),min:n(9271),max:n(2045),scale:n(7705),scaleAndAdd:n(2869),distance:n(5476),squaredDistance:n(6733),length:n(7159),squaredLength:n(2678),negate:n(6977),inverse:n(3095),normalize:n(8308),dot:n(216),lerp:n(2710),random:n(9960),transformMat4:n(8773),transformQuat:n(2508)}},3095:function(t){t.exports=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t[3]=1/e[3],t}},7159:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3];return Math.sqrt(e*e+n*n+r*r+i*i)}},2710:function(t){t.exports=function(t,e,n,r){var i=e[0],o=e[1],a=e[2],s=e[3];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=a+r*(n[2]-a),t[3]=s+r*(n[3]-s),t}},2045:function(t){t.exports=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t[3]=Math.max(e[3],n[3]),t}},9271:function(t){t.exports=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t[3]=Math.min(e[3],n[3]),t}},9363:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t[3]=e[3]*n[3],t}},6977:function(t){t.exports=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t[3]=-e[3],t}},8308:function(t){t.exports=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n*n+r*r+i*i+o*o;a>0&&(a=1/Math.sqrt(a),t[0]=n*a,t[1]=r*a,t[2]=i*a,t[3]=o*a);return t}},9960:function(t,e,n){var r=n(8308),i=n(7705);t.exports=function(t,e){return e=e||1,t[0]=Math.random(),t[1]=Math.random(),t[2]=Math.random(),t[3]=Math.random(),r(t,t),i(t,t,e),t}},7705:function(t){t.exports=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t}},2869:function(t){t.exports=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t}},6675:function(t){t.exports=function(t,e,n,r,i){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t}},6733:function(t){t.exports=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2],o=e[3]-t[3];return n*n+r*r+i*i+o*o}},2678:function(t){t.exports=function(t){var e=t[0],n=t[1],r=t[2],i=t[3];return e*e+n*n+r*r+i*i}},6919:function(t){t.exports=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t}},8773:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3];return t[0]=n[0]*r+n[4]*i+n[8]*o+n[12]*a,t[1]=n[1]*r+n[5]*i+n[9]*o+n[13]*a,t[2]=n[2]*r+n[6]*i+n[10]*o+n[14]*a,t[3]=n[3]*r+n[7]*i+n[11]*o+n[15]*a,t}},2508:function(t){t.exports=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2],l=n[3],c=l*r+s*o-u*i,f=l*i+u*r-a*o,h=l*o+a*i-s*r,d=-a*r-s*i-u*o;return t[0]=c*l+d*-a+f*-u-h*-s,t[1]=f*l+d*-s+h*-a-c*-u,t[2]=h*l+d*-u+c*-s-f*-a,t[3]=e[3],t}},5616:function(t,e){var n;
|
|
39
39
|
/*!
|
|
40
40
|
* jQuery JavaScript Library v3.7.1
|
|
41
41
|
* https://jquery.com/
|
|
@@ -51,5 +51,5 @@ var r=n(5616),i=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^/\0
|
|
|
51
51
|
* @license MIT
|
|
52
52
|
* @preserve Project Home: https://github.com/voidqk/polybooljs
|
|
53
53
|
*/
|
|
54
|
-
var r,i=n(671),o=n(1526),a=n(3074),s=n(8534),u=n(8927),l=n(9779),c=!1,f=o();function h(t,e,n){var i=r.segments(t),o=r.segments(e),a=n(r.combine(i,o));return r.polygon(a)}r={buildLog:function(t){return!0===t?c=i():!1===t&&(c=!1),!1!==c&&c.list},epsilon:function(t){return f.epsilon(t)},segments:function(t){var e=a(!0,f,c);return t.regions.forEach(e.addRegion),{segments:e.calculate(t.inverted),inverted:t.inverted}},combine:function(t,e){return{combined:a(!1,f,c).calculate(t.segments,t.inverted,e.segments,e.inverted),inverted1:t.inverted,inverted2:e.inverted}},selectUnion:function(t){return{segments:u.union(t.combined,c),inverted:t.inverted1||t.inverted2}},selectIntersect:function(t){return{segments:u.intersect(t.combined,c),inverted:t.inverted1&&t.inverted2}},selectDifference:function(t){return{segments:u.difference(t.combined,c),inverted:t.inverted1&&!t.inverted2}},selectDifferenceRev:function(t){return{segments:u.differenceRev(t.combined,c),inverted:!t.inverted1&&t.inverted2}},selectXor:function(t){return{segments:u.xor(t.combined,c),inverted:t.inverted1!==t.inverted2}},polygon:function(t){return{regions:s(t.segments,f,c),inverted:t.inverted}},polygonFromGeoJSON:function(t){return l.toPolygon(r,t)},polygonToGeoJSON:function(t){return l.fromPolygon(r,f,t)},union:function(t,e){return h(t,e,r.selectUnion)},intersect:function(t,e){return h(t,e,r.selectIntersect)},difference:function(t,e){return h(t,e,r.selectDifference)},differenceRev:function(t,e){return h(t,e,r.selectDifferenceRev)},xor:function(t,e){return h(t,e,r.selectXor)}},"object"==typeof window&&(window.PolyBool=r),t.exports=r},671:function(t){t.exports=function(){var t,e=0,n=!1;function r(e,n){return t.list.push({type:e,data:n?JSON.parse(JSON.stringify(n)):void 0}),t}return t={list:[],segmentId:function(){return e++},checkIntersection:function(t,e){return r("check",{seg1:t,seg2:e})},segmentChop:function(t,e){return r("div_seg",{seg:t,pt:e}),r("chop",{seg:t,pt:e})},statusRemove:function(t){return r("pop_seg",{seg:t})},segmentUpdate:function(t){return r("seg_update",{seg:t})},segmentNew:function(t,e){return r("new_seg",{seg:t,primary:e})},segmentRemove:function(t){return r("rem_seg",{seg:t})},tempStatus:function(t,e,n){return r("temp_status",{seg:t,above:e,below:n})},rewind:function(t){return r("rewind",{seg:t})},status:function(t,e,n){return r("status",{seg:t,above:e,below:n})},vert:function(e){return e===n?t:(n=e,r("vert",{x:e}))},log:function(t){return"string"!=typeof t&&(t=JSON.stringify(t,!1," ")),r("log",{txt:t})},reset:function(){return r("reset")},selected:function(t){return r("selected",{segs:t})},chainStart:function(t){return r("chain_start",{seg:t})},chainRemoveHead:function(t,e){return r("chain_rem_head",{index:t,pt:e})},chainRemoveTail:function(t,e){return r("chain_rem_tail",{index:t,pt:e})},chainNew:function(t,e){return r("chain_new",{pt1:t,pt2:e})},chainMatch:function(t){return r("chain_match",{index:t})},chainClose:function(t){return r("chain_close",{index:t})},chainAddHead:function(t,e){return r("chain_add_head",{index:t,pt:e})},chainAddTail:function(t,e){return r("chain_add_tail",{index:t,pt:e})},chainConnect:function(t,e){return r("chain_con",{index1:t,index2:e})},chainReverse:function(t){return r("chain_rev",{index:t})},chainJoin:function(t,e){return r("chain_join",{index1:t,index2:e})},done:function(){return r("done")}}}},1526:function(t){t.exports=function(t){"number"!=typeof t&&(t=1e-10);var e={epsilon:function(e){return"number"==typeof e&&(t=e),t},pointAboveOrOnLine:function(e,n,r){var i=n[0],o=n[1],a=r[0],s=r[1],u=e[0],l=e[1],c=a-i,f=s-o,h=Math.sqrt(c*c+f*f);return c*(l-o)-f*(u-i)>=-t*h},pointBetween:function(t,n,r){if(e.pointsSame(t,n)||e.pointsSame(t,r))return!1;var i=t[1]-n[1],o=r[0]-n[0],a=t[0]-n[0],s=r[1]-n[1],u=a*o+i*s;return!(u<0)&&u<=o*o+s*s},pointsSameX:function(e,n){return Math.abs(e[0]-n[0])<t},pointsSameY:function(e,n){return Math.abs(e[1]-n[1])<t},pointsSame:function(t,n){return e.pointsSameX(t,n)&&e.pointsSameY(t,n)},pointsCompare:function(t,n){return e.pointsSameX(t,n)?e.pointsSameY(t,n)?0:t[1]<n[1]?-1:1:t[0]<n[0]?-1:1},pointsCollinear:function(e,n,r){var i=e[0]-n[0],o=e[1]-n[1],a=n[0]-r[0],s=n[1]-r[1],u=Math.sqrt(i*i+o*o),l=Math.sqrt(a*a+s*s);return Math.abs(i*s-a*o)<=t*(u+l)},linesIntersect:function(n,r,i,o){var a=r[0]-n[0],s=r[1]-n[1],u=o[0]-i[0],l=o[1]-i[1],c=a*l-s*u,f=Math.sqrt(a*a+s*s),h=Math.sqrt(u*u+l*l);if(Math.abs(c)<=t*(f+h))return!1;var d=n[0]-i[0],p=n[1]-i[1],m=(u*p-l*d)/c,g=(a*p-s*d)/c,y=[n[0]+m*a,n[1]+m*s],v={alongA:0,alongB:0,pt:y};return e.pointsSame(y,n)?v.alongA=-1:e.pointsSame(y,r)?v.alongA=1:m<0?v.alongA=-2:m>1&&(v.alongA=2),e.pointsSame(y,i)?v.alongB=-1:e.pointsSame(y,o)?v.alongB=1:g<0?v.alongB=-2:g>1&&(v.alongB=2),v},pointInsideRegion:function(e,n){for(var r=e[0],i=e[1],o=n[n.length-1][0],a=n[n.length-1][1],s=!1,u=0;u<n.length;u++){var l=n[u][0],c=n[u][1];c-i>t!=a-i>t&&(o-l)*(i-c)/(a-c)+l-r>t&&(s=!s),o=l,a=c}return s}};return e}},9779:function(t){var e={toPolygon:function(t,e){function n(e){if(e.length<=0)return t.segments({inverted:!1,regions:[]});function n(e){var n=e.slice(0,e.length-1);return t.segments({inverted:!1,regions:[n]})}for(var r=n(e[0]),i=1;i<e.length;i++)r=t.selectDifference(t.combine(r,n(e[i])));return r}if("Polygon"===e.type)return t.polygon(n(e.coordinates));if("MultiPolygon"===e.type){for(var r=t.segments({inverted:!1,regions:[]}),i=0;i<e.coordinates.length;i++)r=t.selectUnion(t.combine(r,n(e.coordinates[i])));return t.polygon(r)}throw new Error("PolyBool: Cannot convert GeoJSON object to PolyBool polygon")},fromPolygon:function(t,e,n){function r(t,n){return e.pointInsideRegion([.5*(t[0][0]+t[1][0]),.5*(t[0][1]+t[1][1])],n)}function i(t){return{region:t,children:[]}}n=t.polygon(t.segments(n));var o=i(null);function a(t,e){for(var n=0;n<t.children.length;n++){if(r(e,(s=t.children[n]).region))return void a(s,e)}var o=i(e);for(n=0;n<t.children.length;n++){var s;r((s=t.children[n]).region,e)&&(o.children.push(s),t.children.splice(n,1),n--)}t.children.push(o)}for(var s=0;s<n.regions.length;s++){var u=n.regions[s];u.length<3||a(o,u)}function l(t,e){for(var n=0,r=t[t.length-1][0],i=t[t.length-1][1],o=[],a=0;a<t.length;a++){var s=t[a][0],u=t[a][1];o.push([s,u]),n+=u*r-s*i,r=s,i=u}return n<0!==e&&o.reverse(),o.push([o[0][0],o[0][1]]),o}var c=[];function f(t){var e=[l(t.region,!1)];c.push(e);for(var n=0;n<t.children.length;n++)e.push(h(t.children[n]))}function h(t){for(var e=0;e<t.children.length;e++)f(t.children[e]);return l(t.region,!0)}for(s=0;s<o.children.length;s++)f(o.children[s]);return c.length<=0?{type:"Polygon",coordinates:[]}:1==c.length?{type:"Polygon",coordinates:c[0]}:{type:"MultiPolygon",coordinates:c}}};t.exports=e},3074:function(t,e,n){var r=n(4092);t.exports=function(t,e,n){function i(t,e,r){return{id:n?n.segmentId():-1,start:t,end:e,myFill:{above:r.myFill.above,below:r.myFill.below},otherFill:null}}var o=r.create();function a(t,n){o.insertBefore(t,(function(r){return function(t,n,r,i,o,a){var s=e.pointsCompare(n,o);return 0!==s?s:e.pointsSame(r,a)?0:t!==i?t?1:-1:e.pointAboveOrOnLine(r,i?o:a,i?a:o)?1:-1}(t.isStart,t.pt,n,r.isStart,r.pt,r.other.pt)<0}))}function s(t,e){var n=function(t,e){var n=r.node({isStart:!0,pt:t.start,seg:t,primary:e,other:null,status:null});return a(n,t.end),n}(t,e);return function(t,e,n){var i=r.node({isStart:!1,pt:e.end,seg:e,primary:n,other:t,status:null});t.other=i,a(i,t.pt)}(n,t,e),n}function u(t,e){var r=i(e,t.seg.end,t.seg);return function(t,e){n&&n.segmentChop(t.seg,e),t.other.remove(),t.seg.end=e,t.other.pt=e,a(t.other,t.pt)}(t,e),s(r,t.primary)}function l(i,a){var s=r.create();function l(t){return s.findTransition((function(n){var r,i,o,a,s,u;return(r=t,i=n.ev,o=r.seg.start,a=r.seg.end,s=i.seg.start,u=i.seg.end,e.pointsCollinear(o,s,u)?e.pointsCollinear(a,s,u)||e.pointAboveOrOnLine(a,s,u)?1:-1:e.pointAboveOrOnLine(o,s,u)?1:-1)>0}))}function c(t,r){var i=t.seg,o=r.seg,a=i.start,s=i.end,l=o.start,c=o.end;n&&n.checkIntersection(i,o);var f=e.linesIntersect(a,s,l,c);if(!1===f){if(!e.pointsCollinear(a,s,l))return!1;if(e.pointsSame(a,c)||e.pointsSame(s,l))return!1;var h=e.pointsSame(a,l),d=e.pointsSame(s,c);if(h&&d)return r;var p=!h&&e.pointBetween(a,l,c),m=!d&&e.pointBetween(s,l,c);if(h)return m?u(r,s):u(t,c),r;p&&(d||(m?u(r,s):u(t,c)),u(r,a))}else 0===f.alongA&&(-1===f.alongB?u(t,l):0===f.alongB?u(t,f.pt):1===f.alongB&&u(t,c)),0===f.alongB&&(-1===f.alongA?u(r,a):0===f.alongA?u(r,f.pt):1===f.alongA&&u(r,s));return!1}for(var f=[];!o.isEmpty();){var h=o.getHead();if(n&&n.vert(h.pt[0]),h.isStart){n&&n.segmentNew(h.seg,h.primary);var d=l(h),p=d.before?d.before.ev:null,m=d.after?d.after.ev:null;function g(){if(p){var t=c(h,p);if(t)return t}return!!m&&c(h,m)}n&&n.tempStatus(h.seg,!!p&&p.seg,!!m&&m.seg);var y,v=g();if(v){var x;if(t)(x=null===h.seg.myFill.below||h.seg.myFill.above!==h.seg.myFill.below)&&(v.seg.myFill.above=!v.seg.myFill.above);else v.seg.otherFill=h.seg.myFill;n&&n.segmentUpdate(v.seg),h.other.remove(),h.remove()}if(o.getHead()!==h){n&&n.rewind(h.seg);continue}if(t)x=null===h.seg.myFill.below||h.seg.myFill.above!==h.seg.myFill.below,h.seg.myFill.below=m?m.seg.myFill.above:i,h.seg.myFill.above=x?!h.seg.myFill.below:h.seg.myFill.below;else if(null===h.seg.otherFill)y=m?h.primary===m.primary?m.seg.otherFill.above:m.seg.myFill.above:h.primary?a:i,h.seg.otherFill={above:y,below:y};n&&n.status(h.seg,!!p&&p.seg,!!m&&m.seg),h.other.status=d.insert(r.node({ev:h}))}else{var _=h.status;if(null===_)throw new Error("PolyBool: Zero-length segment detected; your epsilon is probably too small or too large");if(s.exists(_.prev)&&s.exists(_.next)&&c(_.prev.ev,_.next.ev),n&&n.statusRemove(_.ev.seg),_.remove(),!h.primary){var b=h.seg.myFill;h.seg.myFill=h.seg.otherFill,h.seg.otherFill=b}f.push(h.seg)}o.getHead().remove()}return n&&n.done(),f}return t?{addRegion:function(t){for(var r,i,o,a=t[t.length-1],u=0;u<t.length;u++){r=a,a=t[u];var l=e.pointsCompare(r,a);0!==l&&s((i=l<0?r:a,o=l<0?a:r,{id:n?n.segmentId():-1,start:i,end:o,myFill:{above:null,below:null},otherFill:null}),!0)}},calculate:function(t){return l(t,!1)}}:{calculate:function(t,e,n,r){return t.forEach((function(t){s(i(t.start,t.end,t),!0)})),n.forEach((function(t){s(i(t.start,t.end,t),!1)})),l(e,r)}}}},4092:function(t){t.exports={create:function(){var t={root:{root:!0,next:null},exists:function(e){return null!==e&&e!==t.root},isEmpty:function(){return null===t.root.next},getHead:function(){return t.root.next},insertBefore:function(e,n){for(var r=t.root,i=t.root.next;null!==i;){if(n(i))return e.prev=i.prev,e.next=i,i.prev.next=e,void(i.prev=e);r=i,i=i.next}r.next=e,e.prev=r,e.next=null},findTransition:function(e){for(var n=t.root,r=t.root.next;null!==r&&!e(r);)n=r,r=r.next;return{before:n===t.root?null:n,after:r,insert:function(t){return t.prev=n,t.next=r,n.next=t,null!==r&&(r.prev=t),t}}}};return t},node:function(t){return t.prev=null,t.next=null,t.remove=function(){t.prev.next=t.next,t.next&&(t.next.prev=t.prev),t.prev=null,t.next=null},t}}},8534:function(t){t.exports=function(t,e,n){var r=[],i=[];return t.forEach((function(t){var o=t.start,a=t.end;if(e.pointsSame(o,a))console.warn("PolyBool: Warning: Zero-length segment detected; your epsilon is probably too small or too large");else{n&&n.chainStart(t);for(var s={index:0,matches_head:!1,matches_pt1:!1},u={index:0,matches_head:!1,matches_pt1:!1},l=s,c=0;c<r.length;c++){var f=(g=r[c])[0],h=(g[1],g[g.length-1]);g[g.length-2];if(e.pointsSame(f,o)){if(A(c,!0,!0))break}else if(e.pointsSame(f,a)){if(A(c,!0,!1))break}else if(e.pointsSame(h,o)){if(A(c,!1,!0))break}else if(e.pointsSame(h,a)&&A(c,!1,!1))break}if(l===s)return r.push([o,a]),void(n&&n.chainNew(o,a));if(l===u){n&&n.chainMatch(s.index);var d=s.index,p=s.matches_pt1?a:o,m=s.matches_head,g=r[d],y=m?g[0]:g[g.length-1],v=m?g[1]:g[g.length-2],x=m?g[g.length-1]:g[0],_=m?g[g.length-2]:g[1];return e.pointsCollinear(v,y,p)&&(m?(n&&n.chainRemoveHead(s.index,p),g.shift()):(n&&n.chainRemoveTail(s.index,p),g.pop()),y=v),e.pointsSame(x,p)?(r.splice(d,1),e.pointsCollinear(_,x,y)&&(m?(n&&n.chainRemoveTail(s.index,y),g.pop()):(n&&n.chainRemoveHead(s.index,y),g.shift())),n&&n.chainClose(s.index),void i.push(g)):void(m?(n&&n.chainAddHead(s.index,p),g.unshift(p)):(n&&n.chainAddTail(s.index,p),g.push(p)))}var b=s.index,w=u.index;n&&n.chainConnect(b,w);var M=r[b].length<r[w].length;s.matches_head?u.matches_head?M?(T(b),E(b,w)):(T(w),E(w,b)):E(w,b):u.matches_head?E(b,w):M?(T(b),E(w,b)):(T(w),E(b,w))}function A(t,e,n){return l.index=t,l.matches_head=e,l.matches_pt1=n,l===s?(l=u,!1):(l=null,!0)}function T(t){n&&n.chainReverse(t),r[t].reverse()}function E(t,i){var o=r[t],a=r[i],s=o[o.length-1],u=o[o.length-2],l=a[0],c=a[1];e.pointsCollinear(u,s,l)&&(n&&n.chainRemoveTail(t,s),o.pop(),s=u),e.pointsCollinear(s,l,c)&&(n&&n.chainRemoveHead(i,l),a.shift()),n&&n.chainJoin(t,i),r[t]=o.concat(a),r.splice(i,1)}})),i}},8927:function(t){function e(t,e,n){var r=[];return t.forEach((function(t){var i=(t.myFill.above?8:0)+(t.myFill.below?4:0)+(t.otherFill&&t.otherFill.above?2:0)+(t.otherFill&&t.otherFill.below?1:0);0!==e[i]&&r.push({id:n?n.segmentId():-1,start:t.start,end:t.end,myFill:{above:1===e[i],below:2===e[i]},otherFill:null})})),n&&n.selected(r),r}var n={union:function(t,n){return e(t,[0,2,1,0,2,2,0,0,1,0,1,0,0,0,0,0],n)},intersect:function(t,n){return e(t,[0,0,0,0,0,2,0,2,0,0,1,1,0,2,1,0],n)},difference:function(t,n){return e(t,[0,0,0,0,2,0,2,0,1,1,0,0,0,1,2,0],n)},differenceRev:function(t,n){return e(t,[0,2,1,0,0,0,1,1,0,2,0,2,0,0,0,0],n)},xor:function(t,n){return e(t,[0,2,1,0,2,0,0,1,1,0,0,2,0,1,2,0],n)}};t.exports=n},5473:function(t,e,n){"use strict";n.d(e,{A:function(){return o}});var r=n(2556),i=n(4205);function o(t){return Math.abs(t)<r.sK?t:t-(0,i.A)(t)*Math.PI}},737:function(t,e,n){"use strict";n.d(e,{A:function(){return o}});var r=n(2556),i=n(4205);function o(t){return Math.abs(t)<=r.DF?t:t-(0,i.A)(t)*r.JM}},8609:function(t,e,n){"use strict";function r(t){return Math.abs(t)>1&&(t=t>1?1:-1),Math.asin(t)}n.d(e,{A:function(){return r}})},4885:function(t,e,n){"use strict";function r(t){var e=Math.exp(t);return e=(e+1/e)/2}n.d(e,{A:function(){return r}})},8193:function(t,e,n){"use strict";function r(t){return 1-.25*t*(1+t/16*(3+1.25*t))}n.d(e,{A:function(){return r}})},9686:function(t,e,n){"use strict";function r(t){return.375*t*(1+.25*t*(1+.46875*t))}n.d(e,{A:function(){return r}})},7711:function(t,e,n){"use strict";function r(t){return.05859375*t*t*(1+.75*t)}n.d(e,{A:function(){return r}})},2060:function(t,e,n){"use strict";function r(t){return t*t*t*(35/3072)}n.d(e,{A:function(){return r}})},7973:function(t,e,n){"use strict";function r(t,e,n){var r=e*n;return t/Math.sqrt(1-r*r)}n.d(e,{A:function(){return r}})},1708:function(t,e,n){"use strict";function r(t,e){t=Math.abs(t),e=Math.abs(e);var n=Math.max(t,e),r=Math.min(t,e)/(n||1);return n*Math.sqrt(1+Math.pow(r,2))}n.d(e,{A:function(){return r}})},6592:function(t,e,n){"use strict";function r(t,e,n,r,i){var o,a;o=t/e;for(var s=0;s<15;s++)if(o+=a=(t-(e*o-n*Math.sin(2*o)+r*Math.sin(4*o)-i*Math.sin(6*o)))/(e-2*n*Math.cos(2*o)+4*r*Math.cos(4*o)-6*i*Math.cos(6*o)),Math.abs(a)<=1e-10)return o;return NaN}n.d(e,{A:function(){return r}})},4037:function(t,e,n){"use strict";function r(t,e,n,r,i){return t*i-e*Math.sin(2*i)+n*Math.sin(4*i)-r*Math.sin(6*i)}n.d(e,{A:function(){return r}})},444:function(t,e,n){"use strict";function r(t,e,n){var r=t*e;return n/Math.sqrt(1-r*r)}n.d(e,{A:function(){return r}})},1793:function(t,e,n){"use strict";n.d(e,{A:function(){return i}});var r=n(2556);function i(t,e){for(var n,i,o=.5*t,a=r.sK-2*Math.atan(e),s=0;s<=15;s++)if(n=t*Math.sin(a),a+=i=r.sK-2*Math.atan(e*Math.pow((1-n)/(1+n),o))-a,Math.abs(i)<=1e-10)return a;return-9999}},6366:function(t,e,n){"use strict";n.d(e,{A:function(){return m}});var r=1,i=.25,o=.046875,a=.01953125,s=.01068115234375,u=.75,l=.46875,c=.013020833333333334,f=.007120768229166667,h=.3645833333333333,d=.005696614583333333,p=.3076171875;function m(t){var e=[];e[0]=r-t*(i+t*(o+t*(a+t*s))),e[1]=t*(u-t*(o+t*(a+t*s)));var n=t*t;return e[2]=n*(l-t*(c+t*f)),n*=t,e[3]=n*(h-t*d),e[4]=n*t*p,e}},3220:function(t,e,n){"use strict";n.d(e,{A:function(){return a}});var r=n(2092),i=n(2556),o=20;function a(t,e,n){for(var a=1/(1-e),s=t,u=o;u;--u){var l=Math.sin(s),c=1-e*l*l;if(s-=c=((0,r.A)(s,l,Math.cos(s),n)-t)*(c*Math.sqrt(c))*a,Math.abs(c)<i.H0)return s}return s}},2092:function(t,e,n){"use strict";function r(t,e,n,r){return n*=e,e*=e,r[0]*t-n*(r[1]+e*(r[2]+e*(r[3]+e*r[4])))}n.d(e,{A:function(){return r}})},7200:function(t,e,n){"use strict";function r(t,e){var n;return t>1e-7?(1-t*t)*(e/(1-(n=t*e)*n)-.5/t*Math.log((1-n)/(1+n))):2*e}n.d(e,{A:function(){return r}})},4205:function(t,e,n){"use strict";function r(t){return t<0?-1:1}n.d(e,{A:function(){return r}})},3882:function(t,e,n){"use strict";function r(t){var e=Math.exp(t);return e=(e-1/e)/2}n.d(e,{A:function(){return r}})},9967:function(t,e,n){"use strict";n.d(e,{A:function(){return i}});var r=n(2556);function i(t,e,n){var i=t*n,o=.5*t;return i=Math.pow((1-i)/(1+i),o),Math.tan(.5*(r.sK-e))/i}},2556:function(t,e,n){"use strict";n.d(e,{A1:function(){return s},DF:function(){return b},G9:function(){return o},H0:function(){return g},JM:function(){return _},Q1:function(){return p},Vj:function(){return x},Y$:function(){return i},_3:function(){return f},a8:function(){return r},bA:function(){return d},bv:function(){return u},dX:function(){return v},ej:function(){return m},gS:function(){return c},sK:function(){return h},xK:function(){return a},zp:function(){return l},zq:function(){return y}});var r=1,i=2,o=3,a=4,s=5,u=6378137,l=6356752.314,c=.0066943799901413165,f=484813681109536e-20,h=Math.PI/2,d=.16666666666666666,p=.04722222222222222,m=.022156084656084655,g=1e-10,y=.017453292519943295,v=57.29577951308232,x=Math.PI/4,_=2*Math.PI,b=3.14159265359},9160:function(t,e,n){"use strict";n.d(e,{Fs:function(){return u},OI:function(){return i},Rw:function(){return a},jX:function(){return o},mj:function(){return s}});var r=n(2556);function i(t,e){return t.datum_type===e.datum_type&&(!(t.a!==e.a||Math.abs(t.es-e.es)>5e-11)&&(t.datum_type===r.a8?t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]:t.datum_type!==r.Y$||t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]&&t.datum_params[3]===e.datum_params[3]&&t.datum_params[4]===e.datum_params[4]&&t.datum_params[5]===e.datum_params[5]&&t.datum_params[6]===e.datum_params[6]))}function o(t,e,n){var i,o,a,s,u=t.x,l=t.y,c=t.z?t.z:0;if(l<-r.sK&&l>-1.001*r.sK)l=-r.sK;else if(l>r.sK&&l<1.001*r.sK)l=r.sK;else{if(l<-r.sK)return{x:-1/0,y:-1/0,z:t.z};if(l>r.sK)return{x:1/0,y:1/0,z:t.z}}return u>Math.PI&&(u-=2*Math.PI),o=Math.sin(l),s=Math.cos(l),a=o*o,{x:((i=n/Math.sqrt(1-e*a))+c)*s*Math.cos(u),y:(i+c)*s*Math.sin(u),z:(i*(1-e)+c)*o}}function a(t,e,n,i){var o,a,s,u,l,c,f,h,d,p,m,g,y,v,x,_=1e-12,b=t.x,w=t.y,M=t.z?t.z:0;if(o=Math.sqrt(b*b+w*w),a=Math.sqrt(b*b+w*w+M*M),o/n<_){if(v=0,a/n<_)return r.sK,x=-i,{x:t.x,y:t.y,z:t.z}}else v=Math.atan2(w,b);s=M/a,h=(u=o/a)*(1-e)*(l=1/Math.sqrt(1-e*(2-e)*u*u)),d=s*l,y=0;do{y++,c=e*(f=n/Math.sqrt(1-e*d*d))/(f+(x=o*h+M*d-f*(1-e*d*d))),g=(m=s*(l=1/Math.sqrt(1-c*(2-c)*u*u)))*h-(p=u*(1-c)*l)*d,h=p,d=m}while(g*g>1e-24&&y<30);return{x:v,y:Math.atan(m/Math.abs(p)),z:x}}function s(t,e,n){if(e===r.a8)return{x:t.x+n[0],y:t.y+n[1],z:t.z+n[2]};if(e===r.Y$){var i=n[0],o=n[1],a=n[2],s=n[3],u=n[4],l=n[5],c=n[6];return{x:c*(t.x-l*t.y+u*t.z)+i,y:c*(l*t.x+t.y-s*t.z)+o,z:c*(-u*t.x+s*t.y+t.z)+a}}}function u(t,e,n){if(e===r.a8)return{x:t.x-n[0],y:t.y-n[1],z:t.z-n[2]};if(e===r.Y$){var i=n[0],o=n[1],a=n[2],s=n[3],u=n[4],l=n[5],c=n[6],f=(t.x-i)/c,h=(t.y-o)/c,d=(t.z-a)/c;return{x:f+l*h-u*d,y:-l*f+h+s*d,z:u*f-s*h+d}}}},1960:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return le}});var r=n(2556),i={greenwich:0,lisbon:-9.131906111111,paris:2.337229166667,bogota:-74.080916666667,madrid:-3.687938888889,rome:12.452333333333,bern:7.439583333333,jakarta:106.807719444444,ferro:-17.666666666667,brussels:4.367975,stockholm:18.058277777778,athens:23.7163375,oslo:10.722916666667},o={mm:{to_meter:.001},cm:{to_meter:.01},ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937},fath:{to_meter:1.8288},kmi:{to_meter:1852},"us-ch":{to_meter:20.1168402336805},"us-mi":{to_meter:1609.34721869444},km:{to_meter:1e3},"ind-ft":{to_meter:.30479841},"ind-yd":{to_meter:.91439523},mi:{to_meter:1609.344},yd:{to_meter:.9144},ch:{to_meter:20.1168},link:{to_meter:.201168},dm:{to_meter:.01},in:{to_meter:.0254},"ind-ch":{to_meter:20.11669506},"us-in":{to_meter:.025400050800101},"us-yd":{to_meter:.914401828803658}},a=/[\s_\-\/\(\)]/g;function s(t,e){if(t[e])return t[e];for(var n,r=Object.keys(t),i=e.toLowerCase().replace(a,""),o=-1;++o<r.length;)if((n=r[o]).toLowerCase().replace(a,"")===i)return t[n]}function u(t){var e,n,a,u={},l=t.split("+").map((function(t){return t.trim()})).filter((function(t){return t})).reduce((function(t,e){var n=e.split("=");return n.push(!0),t[n[0].toLowerCase()]=n[1],t}),{}),c={proj:"projName",datum:"datumCode",rf:function(t){u.rf=parseFloat(t)},lat_0:function(t){u.lat0=t*r.zq},lat_1:function(t){u.lat1=t*r.zq},lat_2:function(t){u.lat2=t*r.zq},lat_ts:function(t){u.lat_ts=t*r.zq},lon_0:function(t){u.long0=t*r.zq},lon_1:function(t){u.long1=t*r.zq},lon_2:function(t){u.long2=t*r.zq},alpha:function(t){u.alpha=parseFloat(t)*r.zq},gamma:function(t){u.rectified_grid_angle=parseFloat(t)},lonc:function(t){u.longc=t*r.zq},x_0:function(t){u.x0=parseFloat(t)},y_0:function(t){u.y0=parseFloat(t)},k_0:function(t){u.k0=parseFloat(t)},k:function(t){u.k0=parseFloat(t)},a:function(t){u.a=parseFloat(t)},b:function(t){u.b=parseFloat(t)},r:function(t){u.a=u.b=parseFloat(t)},r_a:function(){u.R_A=!0},zone:function(t){u.zone=parseInt(t,10)},south:function(){u.utmSouth=!0},towgs84:function(t){u.datum_params=t.split(",").map((function(t){return parseFloat(t)}))},to_meter:function(t){u.to_meter=parseFloat(t)},units:function(t){u.units=t;var e=s(o,t);e&&(u.to_meter=e.to_meter)},from_greenwich:function(t){u.from_greenwich=t*r.zq},pm:function(t){var e=s(i,t);u.from_greenwich=(e||parseFloat(t))*r.zq},nadgrids:function(t){"@null"===t?u.datumCode="none":u.nadgrids=t},axis:function(t){var e="ewnsud";3===t.length&&-1!==e.indexOf(t.substr(0,1))&&-1!==e.indexOf(t.substr(1,1))&&-1!==e.indexOf(t.substr(2,1))&&(u.axis=t)},approx:function(){u.approx=!0}};for(e in l)n=l[e],e in c?"function"==typeof(a=c[e])?a(n):u[a]=n:u[e]=n;return"string"==typeof u.datumCode&&"WGS84"!==u.datumCode&&(u.datumCode=u.datumCode.toLowerCase()),u}var l=function(t){var e=new g(t);return e.output()},c=1,f=/\s/,h=/[A-Za-z]/,d=/[A-Za-z84_]/,p=/[,\]]/,m=/[\d\.E\-\+]/;function g(t){if("string"!=typeof t)throw new Error("not a string");this.text=t.trim(),this.level=0,this.place=0,this.root=null,this.stack=[],this.currentObject=null,this.state=c}function y(t,e,n){Array.isArray(e)&&(n.unshift(e),e=null);var r=e?{}:t,i=n.reduce((function(t,e){return v(e,t),t}),r);e&&(t[e]=i)}function v(t,e){if(Array.isArray(t)){var n=t.shift();if("PARAMETER"===n&&(n=t.shift()),1===t.length)return Array.isArray(t[0])?(e[n]={},void v(t[0],e[n])):void(e[n]=t[0]);if(t.length)if("TOWGS84"!==n){if("AXIS"===n)return n in e||(e[n]=[]),void e[n].push(t);var r;switch(Array.isArray(n)||(e[n]={}),n){case"UNIT":case"PRIMEM":case"VERT_DATUM":return e[n]={name:t[0].toLowerCase(),convert:t[1]},void(3===t.length&&v(t[2],e[n]));case"SPHEROID":case"ELLIPSOID":return e[n]={name:t[0],a:t[1],rf:t[2]},void(4===t.length&&v(t[3],e[n]));case"EDATUM":case"ENGINEERINGDATUM":case"LOCAL_DATUM":case"DATUM":case"VERT_CS":case"VERTCRS":case"VERTICALCRS":return t[0]=["name",t[0]],void y(e,n,t);case"COMPD_CS":case"COMPOUNDCRS":case"FITTED_CS":case"PROJECTEDCRS":case"PROJCRS":case"GEOGCS":case"GEOCCS":case"PROJCS":case"LOCAL_CS":case"GEODCRS":case"GEODETICCRS":case"GEODETICDATUM":case"ENGCRS":case"ENGINEERINGCRS":return t[0]=["name",t[0]],y(e,n,t),void(e[n].type=n);default:for(r=-1;++r<t.length;)if(!Array.isArray(t[r]))return v(t,e[n]);return y(e,n,t)}}else e[n]=t;else e[n]=!0}else e[t]=!0}g.prototype.readCharicter=function(){var t=this.text[this.place++];if(4!==this.state)for(;f.test(t);){if(this.place>=this.text.length)return;t=this.text[this.place++]}switch(this.state){case c:return this.neutral(t);case 2:return this.keyword(t);case 4:return this.quoted(t);case 5:return this.afterquote(t);case 3:return this.number(t);case-1:return}},g.prototype.afterquote=function(t){if('"'===t)return this.word+='"',void(this.state=4);if(p.test(t))return this.word=this.word.trim(),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in afterquote yet, index '+this.place)},g.prototype.afterItem=function(t){return","===t?(null!==this.word&&this.currentObject.push(this.word),this.word=null,void(this.state=c)):"]"===t?(this.level--,null!==this.word&&(this.currentObject.push(this.word),this.word=null),this.state=c,this.currentObject=this.stack.pop(),void(this.currentObject||(this.state=-1))):void 0},g.prototype.number=function(t){if(!m.test(t)){if(p.test(t))return this.word=parseFloat(this.word),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in number yet, index '+this.place)}this.word+=t},g.prototype.quoted=function(t){'"'!==t?this.word+=t:this.state=5},g.prototype.keyword=function(t){if(d.test(t))this.word+=t;else{if("["===t){var e=[];return e.push(this.word),this.level++,null===this.root?this.root=e:this.currentObject.push(e),this.stack.push(this.currentObject),this.currentObject=e,void(this.state=c)}if(!p.test(t))throw new Error("havn't handled \""+t+'" in keyword yet, index '+this.place);this.afterItem(t)}},g.prototype.neutral=function(t){if(h.test(t))return this.word=t,void(this.state=2);if('"'===t)return this.word="",void(this.state=4);if(m.test(t))return this.word=t,void(this.state=3);if(!p.test(t))throw new Error("havn't handled \""+t+'" in neutral yet, index '+this.place);this.afterItem(t)},g.prototype.output=function(){for(;this.place<this.text.length;)this.readCharicter();if(-1===this.state)return this.root;throw new Error('unable to parse string "'+this.text+'". State is '+this.state)};var x=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];function _(t){return.017453292519943295*t}function b(t){for(var e=Object.keys(t),n=0,r=e.length;n<r;++n){var i=e[n];-1!==x.indexOf(i)&&w(t[i]),"object"==typeof t[i]&&b(t[i])}}function w(t){if(t.AUTHORITY){var e=Object.keys(t.AUTHORITY)[0];e&&e in t.AUTHORITY&&(t.title=e+":"+t.AUTHORITY[e])}if("GEOGCS"===t.type?t.projName="longlat":"LOCAL_CS"===t.type?(t.projName="identity",t.local=!0):"object"==typeof t.PROJECTION?t.projName=Object.keys(t.PROJECTION)[0]:t.projName=t.PROJECTION,t.AXIS){for(var n="",r=0,i=t.AXIS.length;r<i;++r){var o=[t.AXIS[r][0].toLowerCase(),t.AXIS[r][1].toLowerCase()];-1!==o[0].indexOf("north")||("y"===o[0]||"lat"===o[0])&&"north"===o[1]?n+="n":-1!==o[0].indexOf("south")||("y"===o[0]||"lat"===o[0])&&"south"===o[1]?n+="s":-1!==o[0].indexOf("east")||("x"===o[0]||"lon"===o[0])&&"east"===o[1]?n+="e":-1===o[0].indexOf("west")&&("x"!==o[0]&&"lon"!==o[0]||"west"!==o[1])||(n+="w")}2===n.length&&(n+="u"),3===n.length&&(t.axis=n)}t.UNIT&&(t.units=t.UNIT.name.toLowerCase(),"metre"===t.units&&(t.units="meter"),t.UNIT.convert&&("GEOGCS"===t.type?t.DATUM&&t.DATUM.SPHEROID&&(t.to_meter=t.UNIT.convert*t.DATUM.SPHEROID.a):t.to_meter=t.UNIT.convert));var a=t.GEOGCS;function s(e){return e*(t.to_meter||1)}"GEOGCS"===t.type&&(a=t),a&&(a.DATUM?t.datumCode=a.DATUM.name.toLowerCase():t.datumCode=a.name.toLowerCase(),"d_"===t.datumCode.slice(0,2)&&(t.datumCode=t.datumCode.slice(2)),"new_zealand_1949"===t.datumCode&&(t.datumCode="nzgd49"),"wgs_1984"!==t.datumCode&&"world_geodetic_system_1984"!==t.datumCode||("Mercator_Auxiliary_Sphere"===t.PROJECTION&&(t.sphere=!0),t.datumCode="wgs84"),"belge_1972"===t.datumCode&&(t.datumCode="rnb72"),a.DATUM&&a.DATUM.SPHEROID&&(t.ellps=a.DATUM.SPHEROID.name.replace("_19","").replace(/[Cc]larke\_18/,"clrk"),"international"===t.ellps.toLowerCase().slice(0,13)&&(t.ellps="intl"),t.a=a.DATUM.SPHEROID.a,t.rf=parseFloat(a.DATUM.SPHEROID.rf,10)),a.DATUM&&a.DATUM.TOWGS84&&(t.datum_params=a.DATUM.TOWGS84),~t.datumCode.indexOf("osgb_1936")&&(t.datumCode="osgb36"),~t.datumCode.indexOf("osni_1952")&&(t.datumCode="osni52"),(~t.datumCode.indexOf("tm65")||~t.datumCode.indexOf("geodetic_datum_of_1965"))&&(t.datumCode="ire65"),"ch1903+"===t.datumCode&&(t.datumCode="ch1903"),~t.datumCode.indexOf("israel")&&(t.datumCode="isr93")),t.b&&!isFinite(t.b)&&(t.b=t.a);[["standard_parallel_1","Standard_Parallel_1"],["standard_parallel_1","Latitude of 1st standard parallel"],["standard_parallel_2","Standard_Parallel_2"],["standard_parallel_2","Latitude of 2nd standard parallel"],["false_easting","False_Easting"],["false_easting","False easting"],["false-easting","Easting at false origin"],["false_northing","False_Northing"],["false_northing","False northing"],["false_northing","Northing at false origin"],["central_meridian","Central_Meridian"],["central_meridian","Longitude of natural origin"],["central_meridian","Longitude of false origin"],["latitude_of_origin","Latitude_Of_Origin"],["latitude_of_origin","Central_Parallel"],["latitude_of_origin","Latitude of natural origin"],["latitude_of_origin","Latitude of false origin"],["scale_factor","Scale_Factor"],["k0","scale_factor"],["latitude_of_center","Latitude_Of_Center"],["latitude_of_center","Latitude_of_center"],["lat0","latitude_of_center",_],["longitude_of_center","Longitude_Of_Center"],["longitude_of_center","Longitude_of_center"],["longc","longitude_of_center",_],["x0","false_easting",s],["y0","false_northing",s],["long0","central_meridian",_],["lat0","latitude_of_origin",_],["lat0","standard_parallel_1",_],["lat1","standard_parallel_1",_],["lat2","standard_parallel_2",_],["azimuth","Azimuth"],["alpha","azimuth",_],["srsCode","name"]].forEach((function(e){return n=t,i=(r=e)[0],o=r[1],void(!(i in n)&&o in n&&(n[i]=n[o],3===r.length&&(n[i]=r[2](n[i]))));var n,r,i,o})),t.long0||!t.longc||"Albers_Conic_Equal_Area"!==t.projName&&"Lambert_Azimuthal_Equal_Area"!==t.projName||(t.long0=t.longc),t.lat_ts||!t.lat1||"Stereographic_South_Pole"!==t.projName&&"Polar Stereographic (variant B)"!==t.projName?!t.lat_ts&&t.lat0&&"Polar_Stereographic"===t.projName&&(t.lat_ts=t.lat0,t.lat0=_(t.lat0>0?90:-90)):(t.lat0=_(t.lat1>0?90:-90),t.lat_ts=t.lat1)}function M(t){var e=l(t),n=e[0],r={};return v(e,r),b(r),r[n]}function A(t){var e=this;if(2===arguments.length){var n=arguments[1];"string"==typeof n?"+"===n.charAt(0)?A[t]=u(arguments[1]):A[t]=M(arguments[1]):A[t]=n}else if(1===arguments.length){if(Array.isArray(t))return t.map((function(t){Array.isArray(t)?A.apply(e,t):A(t)}));if("string"==typeof t){if(t in A)return A[t]}else"EPSG"in t?A["EPSG:"+t.EPSG]=t:"ESRI"in t?A["ESRI:"+t.ESRI]=t:"IAU2000"in t?A["IAU2000:"+t.IAU2000]=t:console.log(t);return}}!function(t){t("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),t("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),t("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");for(var e=1;e<=60;++e)t("EPSG:"+(32600+e),"+proj=utm +zone="+e+" +datum=WGS84 +units=m"),t("EPSG:"+(32700+e),"+proj=utm +zone="+e+" +south +datum=WGS84 +units=m");t.WGS84=t["EPSG:4326"],t["EPSG:3785"]=t["EPSG:3857"],t.GOOGLE=t["EPSG:3857"],t["EPSG:900913"]=t["EPSG:3857"],t["EPSG:102113"]=t["EPSG:3857"]}(A);var T=A;var E=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];var C=["3857","900913","3785","102113"];var k=function(t){if(!function(t){return"string"==typeof t}(t))return t;if(function(t){return t in T}(t))return T[t];if(function(t){return E.some((function(e){return t.indexOf(e)>-1}))}(t)){var e=M(t);if(function(t){var e=s(t,"authority");if(e){var n=s(e,"epsg");return n&&C.indexOf(n)>-1}}(e))return T["EPSG:3857"];var n=function(t){var e=s(t,"extension");if(e)return s(e,"proj4")}(e);return n?u(n):e}return function(t){return"+"===t[0]}(t)?u(t):void 0};function S(t,e){var n,r;if(t=t||{},!e)return t;for(r in e)void 0!==(n=e[r])&&(t[r]=n);return t}var O=n(2286),P=n(2848),L=[O.default,P.default],R={},I=[];function D(t,e){var n=I.length;return t.names?(I[n]=t,t.names.forEach((function(t){R[t.toLowerCase()]=n})),this):(console.log(e),!0)}var N={start:function(){L.forEach(D)},add:D,get:function(t){if(!t)return!1;var e=t.toLowerCase();return void 0!==R[e]&&I[R[e]]?I[R[e]]:void 0}},F={MERIT:{a:6378137,rf:298.257,ellipseName:"MERIT 1983"},SGS85:{a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"},GRS80:{a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"},IAU76:{a:6378140,rf:298.257,ellipseName:"IAU 1976"},airy:{a:6377563.396,b:6356256.91,ellipseName:"Airy 1830"},APL4:{a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"},NWL9D:{a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"},mod_airy:{a:6377340.189,b:6356034.446,ellipseName:"Modified Airy"},andrae:{a:6377104.43,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"},aust_SA:{a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"},GRS67:{a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"},bessel:{a:6377397.155,rf:299.1528128,ellipseName:"Bessel 1841"},bess_nam:{a:6377483.865,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"},clrk66:{a:6378206.4,b:6356583.8,ellipseName:"Clarke 1866"},clrk80:{a:6378249.145,rf:293.4663,ellipseName:"Clarke 1880 mod."},clrk80ign:{a:6378249.2,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"},clrk58:{a:6378293.645208759,rf:294.2606763692654,ellipseName:"Clarke 1858"},CPM:{a:6375738.7,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"},delmbr:{a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"},engelis:{a:6378136.05,rf:298.2566,ellipseName:"Engelis 1985"},evrst30:{a:6377276.345,rf:300.8017,ellipseName:"Everest 1830"},evrst48:{a:6377304.063,rf:300.8017,ellipseName:"Everest 1948"},evrst56:{a:6377301.243,rf:300.8017,ellipseName:"Everest 1956"},evrst69:{a:6377295.664,rf:300.8017,ellipseName:"Everest 1969"},evrstSS:{a:6377298.556,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"},fschr60:{a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"},fschr60m:{a:6378155,rf:298.3,ellipseName:"Fischer 1960"},fschr68:{a:6378150,rf:298.3,ellipseName:"Fischer 1968"},helmert:{a:6378200,rf:298.3,ellipseName:"Helmert 1906"},hough:{a:6378270,rf:297,ellipseName:"Hough"},intl:{a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"},kaula:{a:6378163,rf:298.24,ellipseName:"Kaula 1961"},lerch:{a:6378139,rf:298.257,ellipseName:"Lerch 1979"},mprts:{a:6397300,rf:191,ellipseName:"Maupertius 1738"},new_intl:{a:6378157.5,b:6356772.2,ellipseName:"New International 1967"},plessis:{a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"},krass:{a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"},SEasia:{a:6378155,b:6356773.3205,ellipseName:"Southeast Asia"},walbeck:{a:6376896,b:6355834.8467,ellipseName:"Walbeck"},WGS60:{a:6378165,rf:298.3,ellipseName:"WGS 60"},WGS66:{a:6378145,rf:298.25,ellipseName:"WGS 66"},WGS7:{a:6378135,rf:298.26,ellipseName:"WGS 72"}},j=F.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};F.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};var z={wgs84:{towgs84:"0,0,0",ellipse:"WGS84",datumName:"WGS84"},ch1903:{towgs84:"674.374,15.056,405.346",ellipse:"bessel",datumName:"swiss"},ggrs87:{towgs84:"-199.87,74.79,246.62",ellipse:"GRS80",datumName:"Greek_Geodetic_Reference_System_1987"},nad83:{towgs84:"0,0,0",ellipse:"GRS80",datumName:"North_American_Datum_1983"},nad27:{nadgrids:"@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",ellipse:"clrk66",datumName:"North_American_Datum_1927"},potsdam:{towgs84:"598.1,73.7,418.2,0.202,0.045,-2.455,6.7",ellipse:"bessel",datumName:"Potsdam Rauenberg 1950 DHDN"},carthage:{towgs84:"-263.0,6.0,431.0",ellipse:"clark80",datumName:"Carthage 1934 Tunisia"},hermannskogel:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Hermannskogel"},mgi:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Militar-Geographische Institut"},osni52:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"airy",datumName:"Irish National"},ire65:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"mod_airy",datumName:"Ireland 1965"},rassadiran:{towgs84:"-133.63,-157.5,-158.62",ellipse:"intl",datumName:"Rassadiran"},nzgd49:{towgs84:"59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",ellipse:"intl",datumName:"New Zealand Geodetic Datum 1949"},osgb36:{towgs84:"446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",ellipse:"airy",datumName:"Ordnance Survey of Great Britain 1936"},s_jtsk:{towgs84:"589,76,480",ellipse:"bessel",datumName:"S-JTSK (Ferro)"},beduaram:{towgs84:"-106,-87,188",ellipse:"clrk80",datumName:"Beduaram"},gunung_segara:{towgs84:"-403,684,41",ellipse:"bessel",datumName:"Gunung Segara Jakarta"},rnb72:{towgs84:"106.869,-52.2978,103.724,-0.33657,0.456955,-1.84218,1",ellipse:"intl",datumName:"Reseau National Belge 1972"}};for(var B in z){var V=z[B];z[V.datumName]=V}var q=z;var G=function(t,e,n,i,o,a,s){var u={};return u.datum_type=void 0===t||"none"===t?r.A1:r.xK,e&&(u.datum_params=e.map(parseFloat),0===u.datum_params[0]&&0===u.datum_params[1]&&0===u.datum_params[2]||(u.datum_type=r.a8),u.datum_params.length>3&&(0===u.datum_params[3]&&0===u.datum_params[4]&&0===u.datum_params[5]&&0===u.datum_params[6]||(u.datum_type=r.Y$,u.datum_params[3]*=r._3,u.datum_params[4]*=r._3,u.datum_params[5]*=r._3,u.datum_params[6]=u.datum_params[6]/1e6+1))),s&&(u.datum_type=r.G9,u.grids=s),u.a=n,u.b=i,u.es=o,u.ep2=a,u},U={};function H(t){if(0===t.length)return null;var e="@"===t[0];return e&&(t=t.slice(1)),"null"===t?{name:"null",mandatory:!e,grid:null,isNull:!0}:{name:t,mandatory:!e,grid:U[t]||null,isNull:!1}}function W(t){return t/3600*Math.PI/180}function X(t,e,n){return String.fromCharCode.apply(null,new Uint8Array(t.buffer.slice(e,n)))}function K(t){return t.map((function(t){return[W(t.longitudeShift),W(t.latitudeShift)]}))}function Q(t,e,n){return{name:X(t,e+8,e+16).trim(),parent:X(t,e+24,e+24+8).trim(),lowerLatitude:t.getFloat64(e+72,n),upperLatitude:t.getFloat64(e+88,n),lowerLongitude:t.getFloat64(e+104,n),upperLongitude:t.getFloat64(e+120,n),latitudeInterval:t.getFloat64(e+136,n),longitudeInterval:t.getFloat64(e+152,n),gridNodeCount:t.getInt32(e+168,n)}}function Y(t,e,n,r){for(var i=e+176,o=[],a=0;a<n.gridNodeCount;a++){var s={latitudeShift:t.getFloat32(i+16*a,r),longitudeShift:t.getFloat32(i+16*a+4,r),latitudeAccuracy:t.getFloat32(i+16*a+8,r),longitudeAccuracy:t.getFloat32(i+16*a+12,r)};o.push(s)}return o}function $(t,e){if(!(this instanceof $))return new $(t);e=e||function(t){if(t)throw t};var n=k(t);if("object"==typeof n){var i=$.projections.get(n.projName);if(i){if(n.datumCode&&"none"!==n.datumCode){var o=s(q,n.datumCode);o&&(n.datum_params=n.datum_params||(o.towgs84?o.towgs84.split(","):null),n.ellps=o.ellipse,n.datumName=o.datumName?o.datumName:n.datumCode)}n.k0=n.k0||1,n.axis=n.axis||"enu",n.ellps=n.ellps||"wgs84",n.lat1=n.lat1||n.lat0;var a,u,l,c,f,h,d,p=function(t,e,n,i,o){if(!t){var a=s(F,i);a||(a=j),t=a.a,e=a.b,n=a.rf}return n&&!e&&(e=(1-1/n)*t),(0===n||Math.abs(t-e)<r.H0)&&(o=!0,e=t),{a:t,b:e,rf:n,sphere:o}}(n.a,n.b,n.rf,n.ellps,n.sphere),m=(a=p.a,u=p.b,p.rf,l=n.R_A,h=((c=a*a)-(f=u*u))/c,d=0,l?(c=(a*=1-h*(r.bA+h*(r.Q1+h*r.ej)))*a,h=0):d=Math.sqrt(h),{es:h,e:d,ep2:(c-f)/f}),g=function(t){return void 0===t?null:t.split(",").map(H)}(n.nadgrids),y=n.datum||G(n.datumCode,n.datum_params,p.a,p.b,m.es,m.ep2,g);S(this,n),S(this,i),this.a=p.a,this.b=p.b,this.rf=p.rf,this.sphere=p.sphere,this.es=m.es,this.e=m.e,this.ep2=m.ep2,this.datum=y,this.init(),e(null,this)}else e("Could not get projection name from: "+t)}else e("Could not parse to valid json: "+t)}$.projections=N,$.projections.start();var Z=$,J=n(9160),tt=n(737);function et(t){return t===r.a8||t===r.Y$}function nt(t,e,n){if(null===t.grids||0===t.grids.length)return console.log("Grid shift grids not found"),-1;var i={x:-n.x,y:n.y},o={x:Number.NaN,y:Number.NaN},a=[];t:for(var s=0;s<t.grids.length;s++){var u=t.grids[s];if(a.push(u.name),u.isNull){o=i;break}if(u.mandatory,null!==u.grid)for(var l=u.grid.subgrids,c=0,f=l.length;c<f;c++){var h=l[c],d=(Math.abs(h.del[1])+Math.abs(h.del[0]))/1e4,p=h.ll[0]-d,m=h.ll[1]-d,g=h.ll[0]+(h.lim[0]-1)*h.del[0]+d,y=h.ll[1]+(h.lim[1]-1)*h.del[1]+d;if(!(m>i.y||p>i.x||y<i.y||g<i.x)&&(o=rt(i,e,h),!isNaN(o.x)))break t}else if(u.mandatory)return console.log("Unable to find mandatory grid '"+u.name+"'"),-1}return isNaN(o.x)?(console.log("Failed to find a grid shift table for location '"+-i.x*r.dX+" "+i.y*r.dX+" tried: '"+a+"'"),-1):(n.x=-o.x,n.y=o.y,0)}function rt(t,e,n){var r={x:Number.NaN,y:Number.NaN};if(isNaN(t.x))return r;var i={x:t.x,y:t.y};i.x-=n.ll[0],i.y-=n.ll[1],i.x=(0,tt.A)(i.x-Math.PI)+Math.PI;var o=it(i,n);if(e){if(isNaN(o.x))return r;o.x=i.x-o.x,o.y=i.y-o.y;var a,s,u=9;do{if(s=it(o,n),isNaN(s.x)){console.log("Inverse grid shift iteration failed, presumably at grid edge. Using first approximation.");break}a={x:i.x-(s.x+o.x),y:i.y-(s.y+o.y)},o.x+=a.x,o.y+=a.y}while(u--&&Math.abs(a.x)>1e-12&&Math.abs(a.y)>1e-12);if(u<0)return console.log("Inverse grid shift iterator failed to converge."),r;r.x=(0,tt.A)(o.x+n.ll[0]),r.y=o.y+n.ll[1]}else isNaN(o.x)||(r.x=t.x+o.x,r.y=t.y+o.y);return r}function it(t,e){var n,r={x:t.x/e.del[0],y:t.y/e.del[1]},i=Math.floor(r.x),o=Math.floor(r.y),a=r.x-1*i,s=r.y-1*o,u={x:Number.NaN,y:Number.NaN};if(i<0||i>=e.lim[0])return u;if(o<0||o>=e.lim[1])return u;n=o*e.lim[0]+i;var l=e.cvs[n][0],c=e.cvs[n][1];n++;var f=e.cvs[n][0],h=e.cvs[n][1];n+=e.lim[0];var d=e.cvs[n][0],p=e.cvs[n][1];n--;var m=e.cvs[n][0],g=e.cvs[n][1],y=a*s,v=a*(1-s),x=(1-a)*(1-s),_=(1-a)*s;return u.x=x*l+v*f+_*m+y*d,u.y=x*c+v*h+_*g+y*p,u}function ot(t,e,n){var r,i,o,a=n.x,s=n.y,u=n.z||0,l={};for(o=0;o<3;o++)if(!e||2!==o||void 0!==n.z)switch(0===o?(r=a,i=-1!=="ew".indexOf(t.axis[o])?"x":"y"):1===o?(r=s,i=-1!=="ns".indexOf(t.axis[o])?"y":"x"):(r=u,i="z"),t.axis[o]){case"e":case"n":l[i]=r;break;case"w":case"s":l[i]=-r;break;case"u":void 0!==n[i]&&(l.z=r);break;case"d":void 0!==n[i]&&(l.z=-r);break;default:return null}return l}function at(t){var e={x:t[0],y:t[1]};return t.length>2&&(e.z=t[2]),t.length>3&&(e.m=t[3]),e}function st(t){if("function"==typeof Number.isFinite){if(Number.isFinite(t))return;throw new TypeError("coordinates must be finite numbers")}if("number"!=typeof t||t!=t||!isFinite(t))throw new TypeError("coordinates must be finite numbers")}function ut(t,e,n,i){var o,a=void 0!==(n=Array.isArray(n)?at(n):{x:n.x,y:n.y,z:n.z,m:n.m}).z;if(function(t){st(t.x),st(t.y)}(n),t.datum&&e.datum&&function(t,e){return(t.datum.datum_type===r.a8||t.datum.datum_type===r.Y$||t.datum.datum_type===r.G9)&&"WGS84"!==e.datumCode||(e.datum.datum_type===r.a8||e.datum.datum_type===r.Y$||e.datum.datum_type===r.G9)&&"WGS84"!==t.datumCode}(t,e)&&(n=ut(t,o=new Z("WGS84"),n,i),t=o),i&&"enu"!==t.axis&&(n=ot(t,!1,n)),"longlat"===t.projName)n={x:n.x*r.zq,y:n.y*r.zq,z:n.z||0};else if(t.to_meter&&(n={x:n.x*t.to_meter,y:n.y*t.to_meter,z:n.z||0}),!(n=t.inverse(n)))return;if(t.from_greenwich&&(n.x+=t.from_greenwich),n=function(t,e,n){if((0,J.OI)(t,e))return n;if(t.datum_type===r.A1||e.datum_type===r.A1)return n;var i=t.a,o=t.es;if(t.datum_type===r.G9){if(0!==nt(t,!1,n))return;i=r.bv,o=r.gS}var a=e.a,s=e.b,u=e.es;if(e.datum_type===r.G9&&(a=r.bv,s=r.zp,u=r.gS),o===u&&i===a&&!et(t.datum_type)&&!et(e.datum_type))return n;if(n=(0,J.jX)(n,o,i),et(t.datum_type)&&(n=(0,J.mj)(n,t.datum_type,t.datum_params)),et(e.datum_type)&&(n=(0,J.Fs)(n,e.datum_type,e.datum_params)),n=(0,J.Rw)(n,u,a,s),e.datum_type===r.G9&&0!==nt(e,!0,n))return;return n}(t.datum,e.datum,n),n)return e.from_greenwich&&(n={x:n.x-e.from_greenwich,y:n.y,z:n.z||0}),"longlat"===e.projName?n={x:n.x*r.dX,y:n.y*r.dX,z:n.z||0}:(n=e.forward(n),e.to_meter&&(n={x:n.x/e.to_meter,y:n.y/e.to_meter,z:n.z||0})),i&&"enu"!==e.axis?ot(e,!0,n):(n&&!a&&delete n.z,n)}var lt=Z("WGS84");function ct(t,e,n,r){var i,o,a;return Array.isArray(n)?(i=ut(t,e,n,r)||{x:NaN,y:NaN},n.length>2?void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name?"number"==typeof i.z?[i.x,i.y,i.z].concat(n.slice(3)):[i.x,i.y,n[2]].concat(n.slice(3)):[i.x,i.y].concat(n.slice(2)):[i.x,i.y]):(o=ut(t,e,n,r),2===(a=Object.keys(n)).length||a.forEach((function(r){if(void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name){if("x"===r||"y"===r||"z"===r)return}else if("x"===r||"y"===r)return;o[r]=n[r]})),o)}function ft(t){return t instanceof Z?t:t.oProj?t.oProj:Z(t)}var ht=function(t,e,n){t=ft(t);var r,i=!1;return void 0===e?(e=t,t=lt,i=!0):(void 0!==e.x||Array.isArray(e))&&(n=e,e=t,t=lt,i=!0),e=ft(e),n?ct(t,e,n):(r={forward:function(n,r){return ct(t,e,n,r)},inverse:function(n,r){return ct(e,t,n,r)}},i&&(r.oProj=e),r)},dt="AJSAJS",pt="AFAFAF",mt=65,gt=73,yt=79,vt=86,xt=90,_t={forward:bt,inverse:function(t){var e=Tt(kt(t.toUpperCase()));if(e.lat&&e.lon)return[e.lon,e.lat,e.lon,e.lat];return[e.left,e.bottom,e.right,e.top]},toPoint:wt};function bt(t,e){return e=e||5,function(t,e){var n="00000"+t.easting,r="00000"+t.northing;return t.zoneNumber+t.zoneLetter+(d=t.easting,p=t.northing,m=t.zoneNumber,g=Ct(m),y=Math.floor(d/1e5),v=Math.floor(p/1e5)%20,i=y,o=v,a=g,s=a-1,u=dt.charCodeAt(s),l=pt.charCodeAt(s),c=u+i-1,f=l+o,h=!1,c>xt&&(c=c-xt+mt-1,h=!0),(c===gt||u<gt&&c>gt||(c>gt||u<gt)&&h)&&c++,(c===yt||u<yt&&c>yt||(c>yt||u<yt)&&h)&&++c===gt&&c++,c>xt&&(c=c-xt+mt-1),f>vt?(f=f-vt+mt-1,h=!0):h=!1,(f===gt||l<gt&&f>gt||(f>gt||l<gt)&&h)&&f++,(f===yt||l<yt&&f>yt||(f>yt||l<yt)&&h)&&++f===gt&&f++,f>vt&&(f=f-vt+mt-1),String.fromCharCode(c)+String.fromCharCode(f))+n.substr(n.length-5,e)+r.substr(r.length-5,e);var i,o,a,s,u,l,c,f,h;var d,p,m,g,y,v}(function(t){var e,n,r,i,o,a,s,u,l=t.lat,c=t.lon,f=6378137,h=.00669438,d=.9996,p=Mt(l),m=Mt(c);u=Math.floor((c+180)/6)+1,180===c&&(u=60);l>=56&&l<64&&c>=3&&c<12&&(u=32);l>=72&&l<84&&(c>=0&&c<9?u=31:c>=9&&c<21?u=33:c>=21&&c<33?u=35:c>=33&&c<42&&(u=37));s=Mt(6*(u-1)-180+3),e=h/(1-h),n=f/Math.sqrt(1-h*Math.sin(p)*Math.sin(p)),r=Math.tan(p)*Math.tan(p),i=e*Math.cos(p)*Math.cos(p),o=Math.cos(p)*(m-s),a=f*((1-h/4-3*h*h/64-5*h*h*h/256)*p-(3*h/8+3*h*h/32+45*h*h*h/1024)*Math.sin(2*p)+(15*h*h/256+45*h*h*h/1024)*Math.sin(4*p)-35*h*h*h/3072*Math.sin(6*p));var g=d*n*(o+(1-r+i)*o*o*o/6+(5-18*r+r*r+72*i-58*e)*o*o*o*o*o/120)+5e5,y=d*(a+n*Math.tan(p)*(o*o/2+(5-r+9*i+4*i*i)*o*o*o*o/24+(61-58*r+r*r+600*i-330*e)*o*o*o*o*o*o/720));l<0&&(y+=1e7);return{northing:Math.round(y),easting:Math.round(g),zoneNumber:u,zoneLetter:Et(l)}}({lat:t[1],lon:t[0]}),e)}function wt(t){var e=Tt(kt(t.toUpperCase()));return e.lat&&e.lon?[e.lon,e.lat]:[(e.left+e.right)/2,(e.top+e.bottom)/2]}function Mt(t){return t*(Math.PI/180)}function At(t){return t/Math.PI*180}function Tt(t){var e=t.northing,n=t.easting,r=t.zoneLetter,i=t.zoneNumber;if(i<0||i>60)return null;var o,a,s,u,l,c,f,h,d,p=.9996,m=6378137,g=.00669438,y=(1-Math.sqrt(.99330562))/(1+Math.sqrt(.99330562)),v=n-5e5,x=e;r<"N"&&(x-=1e7),f=6*(i-1)-180+3,o=.006739496752268451,d=(h=x/p/6367449.145945056)+(3*y/2-27*y*y*y/32)*Math.sin(2*h)+(21*y*y/16-55*y*y*y*y/32)*Math.sin(4*h)+151*y*y*y/96*Math.sin(6*h),a=m/Math.sqrt(1-g*Math.sin(d)*Math.sin(d)),s=Math.tan(d)*Math.tan(d),u=o*Math.cos(d)*Math.cos(d),l=.99330562*m/Math.pow(1-g*Math.sin(d)*Math.sin(d),1.5),c=v/(a*p);var _=d-a*Math.tan(d)/l*(c*c/2-(5+3*s+10*u-4*u*u-9*o)*c*c*c*c/24+(61+90*s+298*u+45*s*s-1.6983531815716497-3*u*u)*c*c*c*c*c*c/720);_=At(_);var b,w=(c-(1+2*s+u)*c*c*c/6+(5-2*u+28*s-3*u*u+8*o+24*s*s)*c*c*c*c*c/120)/Math.cos(d);if(w=f+At(w),t.accuracy){var M=Tt({northing:t.northing+t.accuracy,easting:t.easting+t.accuracy,zoneLetter:t.zoneLetter,zoneNumber:t.zoneNumber});b={top:M.lat,right:M.lon,bottom:_,left:w}}else b={lat:_,lon:w};return b}function Et(t){var e="Z";return 84>=t&&t>=72?e="X":72>t&&t>=64?e="W":64>t&&t>=56?e="V":56>t&&t>=48?e="U":48>t&&t>=40?e="T":40>t&&t>=32?e="S":32>t&&t>=24?e="R":24>t&&t>=16?e="Q":16>t&&t>=8?e="P":8>t&&t>=0?e="N":0>t&&t>=-8?e="M":-8>t&&t>=-16?e="L":-16>t&&t>=-24?e="K":-24>t&&t>=-32?e="J":-32>t&&t>=-40?e="H":-40>t&&t>=-48?e="G":-48>t&&t>=-56?e="F":-56>t&&t>=-64?e="E":-64>t&&t>=-72?e="D":-72>t&&t>=-80&&(e="C"),e}function Ct(t){var e=t%6;return 0===e&&(e=6),e}function kt(t){if(t&&0===t.length)throw"MGRSPoint coverting from nothing";for(var e,n=t.length,r=null,i="",o=0;!/[A-Z]/.test(e=t.charAt(o));){if(o>=2)throw"MGRSPoint bad conversion from: "+t;i+=e,o++}var a=parseInt(i,10);if(0===o||o+3>n)throw"MGRSPoint bad conversion from: "+t;var s=t.charAt(o++);if(s<="A"||"B"===s||"Y"===s||s>="Z"||"I"===s||"O"===s)throw"MGRSPoint zone letter "+s+" not handled: "+t;r=t.substring(o,o+=2);for(var u=Ct(a),l=function(t,e){var n=dt.charCodeAt(e-1),r=1e5,i=!1;for(;n!==t.charCodeAt(0);){if(++n===gt&&n++,n===yt&&n++,n>xt){if(i)throw"Bad character: "+t;n=mt,i=!0}r+=1e5}return r}(r.charAt(0),u),c=function(t,e){if(t>"V")throw"MGRSPoint given invalid Northing "+t;var n=pt.charCodeAt(e-1),r=0,i=!1;for(;n!==t.charCodeAt(0);){if(++n===gt&&n++,n===yt&&n++,n>vt){if(i)throw"Bad character: "+t;n=mt,i=!0}r+=1e5}return r}(r.charAt(1),u);c<St(s);)c+=2e6;var f=n-o;if(f%2!=0)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"+t;var h,d,p,m=f/2,g=0,y=0;return m>0&&(h=1e5/Math.pow(10,m),d=t.substring(o,o+m),g=parseFloat(d)*h,p=t.substring(o+m),y=parseFloat(p)*h),{easting:g+l,northing:y+c,zoneLetter:s,zoneNumber:a,accuracy:h}}function St(t){var e;switch(t){case"C":e=11e5;break;case"D":e=2e6;break;case"E":e=28e5;break;case"F":e=37e5;break;case"G":e=46e5;break;case"H":e=55e5;break;case"J":e=64e5;break;case"K":e=73e5;break;case"L":e=82e5;break;case"M":e=91e5;break;case"N":e=0;break;case"P":e=8e5;break;case"Q":e=17e5;break;case"R":e=26e5;break;case"S":e=35e5;break;case"T":e=44e5;break;case"U":e=53e5;break;case"V":e=62e5;break;case"W":e=7e6;break;case"X":e=79e5;break;default:e=-1}if(e>=0)return e;throw"Invalid zone letter: "+t}function Ot(t,e,n){if(!(this instanceof Ot))return new Ot(t,e,n);if(Array.isArray(t))this.x=t[0],this.y=t[1],this.z=t[2]||0;else if("object"==typeof t)this.x=t.x,this.y=t.y,this.z=t.z||0;else if("string"==typeof t&&void 0===e){var r=t.split(",");this.x=parseFloat(r[0],10),this.y=parseFloat(r[1],10),this.z=parseFloat(r[2],10)||0}else this.x=t,this.y=e,this.z=n||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}Ot.fromMGRS=function(t){return new Ot(wt(t))},Ot.prototype.toMGRS=function(t){return bt([this.x,this.y],t)};var Pt=Ot,Lt=n(5602),Rt=n(994),It=n(6748),Dt=n(865),Nt=n(688),Ft=n(988),jt=n(7475),zt=n(9269),Bt=n(6507),Vt=n(529),qt=n(7406),Gt=n(5458),Ut=n(9462),Ht=n(4101),Wt=n(4256),Xt=n(2169),Kt=n(6407),Qt=n(5157),Yt=n(9006),$t=n(5967),Zt=n(7968),Jt=n(3211),te=n(8980),ee=n(8181),ne=n(5722),re=n(1295),ie=n(4876),oe=n(7127),ae=n(469),se=n(7129),ue=n(5789);ht.defaultDatum="WGS84",ht.Proj=Z,ht.WGS84=new ht.Proj("WGS84"),ht.Point=Pt,ht.toPoint=at,ht.defs=T,ht.nadgrid=function(t,e){var n=new DataView(e),r=function(t){var e=t.getInt32(8,!1);if(11===e)return!1;e=t.getInt32(8,!0),11!==e&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian");return!0}(n),i=function(t,e){return{nFields:t.getInt32(8,e),nSubgridFields:t.getInt32(24,e),nSubgrids:t.getInt32(40,e),shiftType:X(t,56,64).trim(),fromSemiMajorAxis:t.getFloat64(120,e),fromSemiMinorAxis:t.getFloat64(136,e),toSemiMajorAxis:t.getFloat64(152,e),toSemiMinorAxis:t.getFloat64(168,e)}}(n,r),o=function(t,e,n){for(var r=176,i=[],o=0;o<e.nSubgrids;o++){var a=Q(t,r,n),s=Y(t,r,a,n),u=Math.round(1+(a.upperLongitude-a.lowerLongitude)/a.longitudeInterval),l=Math.round(1+(a.upperLatitude-a.lowerLatitude)/a.latitudeInterval);i.push({ll:[W(a.lowerLongitude),W(a.lowerLatitude)],del:[W(a.longitudeInterval),W(a.latitudeInterval)],lim:[u,l],count:a.gridNodeCount,cvs:K(s)}),r+=176+16*a.gridNodeCount}return i}(n,i,r),a={header:i,subgrids:o};return U[t]=a,a},ht.transform=ut,ht.mgrs=_t,ht.version="__VERSION__",function(t){t.Proj.projections.add(Lt.default),t.Proj.projections.add(Rt.default),t.Proj.projections.add(It.default),t.Proj.projections.add(Dt.default),t.Proj.projections.add(Nt.default),t.Proj.projections.add(Ft.default),t.Proj.projections.add(jt.default),t.Proj.projections.add(zt.default),t.Proj.projections.add(Bt.default),t.Proj.projections.add(Vt.default),t.Proj.projections.add(qt.default),t.Proj.projections.add(Gt.default),t.Proj.projections.add(Ut.default),t.Proj.projections.add(Ht.default),t.Proj.projections.add(Wt.default),t.Proj.projections.add(Xt.default),t.Proj.projections.add(Kt.default),t.Proj.projections.add(Qt.default),t.Proj.projections.add(Yt.default),t.Proj.projections.add($t.default),t.Proj.projections.add(Zt.default),t.Proj.projections.add(Jt.default),t.Proj.projections.add(te.default),t.Proj.projections.add(ee.default),t.Proj.projections.add(ne.default),t.Proj.projections.add(re.default),t.Proj.projections.add(ie.default),t.Proj.projections.add(oe.default),t.Proj.projections.add(ae.default),t.Proj.projections.add(se.default),t.Proj.projections.add(ue.default)}(ht);var le=ht},5458:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return h},phi1z:function(){return f}});var r=n(444),i=n(7200),o=n(737),a=n(8609),s=n(2556);function u(){Math.abs(this.lat1+this.lat2)<s.H0||(this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e3=Math.sqrt(this.es),this.sin_po=Math.sin(this.lat1),this.cos_po=Math.cos(this.lat1),this.t1=this.sin_po,this.con=this.sin_po,this.ms1=(0,r.A)(this.e3,this.sin_po,this.cos_po),this.qs1=(0,i.A)(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat2),this.cos_po=Math.cos(this.lat2),this.t2=this.sin_po,this.ms2=(0,r.A)(this.e3,this.sin_po,this.cos_po),this.qs2=(0,i.A)(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat0),this.cos_po=Math.cos(this.lat0),this.t3=this.sin_po,this.qs0=(0,i.A)(this.e3,this.sin_po),Math.abs(this.lat1-this.lat2)>s.H0?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function l(t){var e=t.x,n=t.y;this.sin_phi=Math.sin(n),this.cos_phi=Math.cos(n);var r=(0,i.A)(this.e3,this.sin_phi),a=this.a*Math.sqrt(this.c-this.ns0*r)/this.ns0,s=this.ns0*(0,o.A)(e-this.long0),u=a*Math.sin(s)+this.x0,l=this.rh-a*Math.cos(s)+this.y0;return t.x=u,t.y=l,t}function c(t){var e,n,r,i,a,s;return t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns0>=0?(e=Math.sqrt(t.x*t.x+t.y*t.y),r=1):(e=-Math.sqrt(t.x*t.x+t.y*t.y),r=-1),i=0,0!==e&&(i=Math.atan2(r*t.x,r*t.y)),r=e*this.ns0/this.a,this.sphere?s=Math.asin((this.c-r*r)/(2*this.ns0)):(n=(this.c-r*r)/this.ns0,s=this.phi1z(this.e3,n)),a=(0,o.A)(i/this.ns0+this.long0),t.x=a,t.y=s,t}function f(t,e){var n,r,i,o,u=(0,a.A)(.5*e);if(t<s.H0)return u;for(var l=t*t,c=1;c<=25;c++)if(u+=o=.5*(i=1-(r=t*(n=Math.sin(u)))*r)*i/Math.cos(u)*(e/(1-l)-n/i+.5/t*Math.log((1-r)/(1+r))),Math.abs(o)<=1e-7)return u;return null}var h=["Albers_Conic_Equal_Area","Albers","aea"];e.default={init:u,forward:l,inverse:c,names:h,phi1z:f}},8980:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(737),i=n(2556),o=n(4037),a=n(8193),s=n(9686),u=n(7711),l=n(2060),c=n(7973),f=n(8609),h=n(6592);function d(){this.sin_p12=Math.sin(this.lat0),this.cos_p12=Math.cos(this.lat0)}function p(t){var e,n,f,h,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k,S,O,P=t.x,L=t.y,R=Math.sin(t.y),I=Math.cos(t.y),D=(0,r.A)(P-this.long0);return this.sphere?Math.abs(this.sin_p12-1)<=i.H0?(t.x=this.x0+this.a*(i.sK-L)*Math.sin(D),t.y=this.y0-this.a*(i.sK-L)*Math.cos(D),t):Math.abs(this.sin_p12+1)<=i.H0?(t.x=this.x0+this.a*(i.sK+L)*Math.sin(D),t.y=this.y0+this.a*(i.sK+L)*Math.cos(D),t):(E=this.sin_p12*R+this.cos_p12*I*Math.cos(D),T=(A=Math.acos(E))?A/Math.sin(A):1,t.x=this.x0+this.a*T*I*Math.sin(D),t.y=this.y0+this.a*T*(this.cos_p12*R-this.sin_p12*I*Math.cos(D)),t):(e=(0,a.A)(this.es),n=(0,s.A)(this.es),f=(0,u.A)(this.es),h=(0,l.A)(this.es),Math.abs(this.sin_p12-1)<=i.H0?(d=this.a*(0,o.A)(e,n,f,h,i.sK),p=this.a*(0,o.A)(e,n,f,h,L),t.x=this.x0+(d-p)*Math.sin(D),t.y=this.y0-(d-p)*Math.cos(D),t):Math.abs(this.sin_p12+1)<=i.H0?(d=this.a*(0,o.A)(e,n,f,h,i.sK),p=this.a*(0,o.A)(e,n,f,h,L),t.x=this.x0+(d+p)*Math.sin(D),t.y=this.y0+(d+p)*Math.cos(D),t):(m=R/I,g=(0,c.A)(this.a,this.e,this.sin_p12),y=(0,c.A)(this.a,this.e,R),v=Math.atan((1-this.es)*m+this.es*g*this.sin_p12/(y*I)),C=0===(x=Math.atan2(Math.sin(D),this.cos_p12*Math.tan(v)-this.sin_p12*Math.cos(D)))?Math.asin(this.cos_p12*Math.sin(v)-this.sin_p12*Math.cos(v)):Math.abs(Math.abs(x)-Math.PI)<=i.H0?-Math.asin(this.cos_p12*Math.sin(v)-this.sin_p12*Math.cos(v)):Math.asin(Math.sin(D)*Math.cos(v)/Math.sin(x)),_=this.e*this.sin_p12/Math.sqrt(1-this.es),A=g*C*(1-(k=C*C)*(M=(b=this.e*this.cos_p12*Math.cos(x)/Math.sqrt(1-this.es))*b)*(1-M)/6+(S=k*C)/8*(w=_*b)*(1-2*M)+(O=S*C)/120*(M*(4-7*M)-3*_*_*(1-7*M))-O*C/48*w),t.x=this.x0+A*Math.sin(x),t.y=this.y0+A*Math.cos(x),t))}function m(t){var e,n,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k,S,O,P,L,R,I;if(t.x-=this.x0,t.y-=this.y0,this.sphere){if((e=Math.sqrt(t.x*t.x+t.y*t.y))>2*i.sK*this.a)return;return n=e/this.a,d=Math.sin(n),p=Math.cos(n),m=this.long0,Math.abs(e)<=i.H0?g=this.lat0:(g=(0,f.A)(p*this.sin_p12+t.y*d*this.cos_p12/e),y=Math.abs(this.lat0)-i.sK,m=Math.abs(y)<=i.H0?this.lat0>=0?(0,r.A)(this.long0+Math.atan2(t.x,-t.y)):(0,r.A)(this.long0-Math.atan2(-t.x,t.y)):(0,r.A)(this.long0+Math.atan2(t.x*d,e*this.cos_p12*p-t.y*this.sin_p12*d))),t.x=m,t.y=g,t}return v=(0,a.A)(this.es),x=(0,s.A)(this.es),_=(0,u.A)(this.es),b=(0,l.A)(this.es),Math.abs(this.sin_p12-1)<=i.H0?(M=(w=this.a*(0,o.A)(v,x,_,b,i.sK))-(e=Math.sqrt(t.x*t.x+t.y*t.y)),g=(0,h.A)(M/this.a,v,x,_,b),m=(0,r.A)(this.long0+Math.atan2(t.x,-1*t.y)),t.x=m,t.y=g,t):Math.abs(this.sin_p12+1)<=i.H0?(w=this.a*(0,o.A)(v,x,_,b,i.sK),M=(e=Math.sqrt(t.x*t.x+t.y*t.y))-w,g=(0,h.A)(M/this.a,v,x,_,b),m=(0,r.A)(this.long0+Math.atan2(t.x,t.y)),t.x=m,t.y=g,t):(e=Math.sqrt(t.x*t.x+t.y*t.y),E=Math.atan2(t.x,t.y),A=(0,c.A)(this.a,this.e,this.sin_p12),C=Math.cos(E),S=-(k=this.e*this.cos_p12*C)*k/(1-this.es),O=3*this.es*(1-S)*this.sin_p12*this.cos_p12*C/(1-this.es),R=1-S*(L=(P=e/A)-S*(1+S)*Math.pow(P,3)/6-O*(1+3*S)*Math.pow(P,4)/24)*L/2-P*L*L*L/6,T=Math.asin(this.sin_p12*Math.cos(L)+this.cos_p12*Math.sin(L)*C),m=(0,r.A)(this.long0+Math.asin(Math.sin(E)*Math.sin(L)/Math.cos(T))),I=Math.sin(T),g=Math.atan2((I-this.es*R*this.sin_p12)*Math.tan(T),I*(1-this.es)),t.x=m,t.y=g,t)}var g=["Azimuthal_Equidistant","aeqd"];e.default={init:d,forward:p,inverse:m,names:g}},5789:function(t,e,n){"use strict";n.r(e),n.d(e,{init:function(){return f},names:function(){return g}});var r=n(5473),i=n(737),o=n(1708),a=n(6366),s=n(3220),u=n(2092),l=n(2556),c=1e-10;function f(){var t;if(this.phi1=this.lat1,Math.abs(this.phi1)<c)throw new Error;this.es?(this.en=(0,a.A)(this.es),this.m1=(0,u.A)(this.phi1,this.am1=Math.sin(this.phi1),t=Math.cos(this.phi1),this.en),this.am1=t/(Math.sqrt(1-this.es*this.am1*this.am1)*this.am1),this.inverse=d,this.forward=h):(Math.abs(this.phi1)+c>=l.sK?this.cphi1=0:this.cphi1=1/Math.tan(this.phi1),this.inverse=m,this.forward=p)}function h(t){var e,n,r,o=(0,i.A)(t.x-(this.long0||0)),a=t.y;return e=this.am1+this.m1-(0,u.A)(a,n=Math.sin(a),r=Math.cos(a),this.en),n=r*o/(e*Math.sqrt(1-this.es*n*n)),t.x=e*Math.sin(n),t.y=this.am1-e*Math.cos(n),t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function d(t){var e,n,a,u;if(t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a,n=(0,o.A)(t.x,t.y=this.am1-t.y),u=(0,s.A)(this.am1+this.m1-n,this.es,this.en),(e=Math.abs(u))<l.sK)e=Math.sin(u),a=n*Math.atan2(t.x,t.y)*Math.sqrt(1-this.es*e*e)/Math.cos(u);else{if(!(Math.abs(e-l.sK)<=c))throw new Error;a=0}return t.x=(0,i.A)(a+(this.long0||0)),t.y=(0,r.A)(u),t}function p(t){var e,n,r=(0,i.A)(t.x-(this.long0||0)),o=t.y;return n=this.cphi1+this.phi1-o,Math.abs(n)>c?(t.x=n*Math.sin(e=r*Math.cos(o)/n),t.y=this.cphi1-n*Math.cos(e)):t.x=t.y=0,t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function m(t){var e,n;t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a;var a=(0,o.A)(t.x,t.y=this.cphi1-t.y);if(n=this.cphi1+this.phi1-a,Math.abs(n)>l.sK)throw new Error;return e=Math.abs(Math.abs(n)-l.sK)<=c?0:a*Math.atan2(t.x,t.y)/Math.cos(n),t.x=(0,i.A)(e+(this.long0||0)),t.y=(0,r.A)(n),t}var g=["bonne","Bonne (Werner lat_1=90)"];e.default={init:f,names:g}},529:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(4037),i=n(8193),o=n(9686),a=n(7711),s=n(2060),u=n(7973),l=n(737),c=n(5473),f=n(6592),h=n(2556);function d(){this.sphere||(this.e0=(0,i.A)(this.es),this.e1=(0,o.A)(this.es),this.e2=(0,a.A)(this.es),this.e3=(0,s.A)(this.es),this.ml0=this.a*(0,r.A)(this.e0,this.e1,this.e2,this.e3,this.lat0))}function p(t){var e,n,i=t.x,o=t.y;if(i=(0,l.A)(i-this.long0),this.sphere)e=this.a*Math.asin(Math.cos(o)*Math.sin(i)),n=this.a*(Math.atan2(Math.tan(o),Math.cos(i))-this.lat0);else{var a=Math.sin(o),s=Math.cos(o),c=(0,u.A)(this.a,this.e,a),f=Math.tan(o)*Math.tan(o),h=i*Math.cos(o),d=h*h,p=this.es*s*s/(1-this.es);e=c*h*(1-d*f*(1/6-(8-f+8*p)*d/120)),n=this.a*(0,r.A)(this.e0,this.e1,this.e2,this.e3,o)-this.ml0+c*a/s*d*(.5+(5-f+6*p)*d/24)}return t.x=e+this.x0,t.y=n+this.y0,t}function m(t){t.x-=this.x0,t.y-=this.y0;var e,n,r=t.x/this.a,i=t.y/this.a;if(this.sphere){var o=i+this.lat0;e=Math.asin(Math.sin(o)*Math.cos(r)),n=Math.atan2(Math.tan(r),Math.cos(o))}else{var a=this.ml0/this.a+i,s=(0,f.A)(a,this.e0,this.e1,this.e2,this.e3);if(Math.abs(Math.abs(s)-h.sK)<=h.H0)return t.x=this.long0,t.y=h.sK,i<0&&(t.y*=-1),t;var d=(0,u.A)(this.a,this.e,Math.sin(s)),p=d*d*d/this.a/this.a*(1-this.es),m=Math.pow(Math.tan(s),2),g=r*this.a/d,y=g*g;e=s-d*Math.tan(s)/p*g*g*(.5-(1+3*m)*g*g/24),n=g*(1-y*(m/3+(1+3*m)*m*y/15))/Math.cos(s)}return t.x=(0,l.A)(n+this.long0),t.y=(0,c.A)(e),t}var g=["Cassini","Cassini_Soldner","cass"];e.default={init:d,forward:p,inverse:m,names:g}},4101:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return f},forward:function(){return u},init:function(){return s},inverse:function(){return l},names:function(){return c}});var r=n(737),i=n(7200),o=n(444),a=n(2556);function s(){this.sphere||(this.k0=(0,o.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function u(t){var e,n,o=t.x,a=t.y,s=(0,r.A)(o-this.long0);if(this.sphere)e=this.x0+this.a*s*Math.cos(this.lat_ts),n=this.y0+this.a*Math.sin(a)/Math.cos(this.lat_ts);else{var u=(0,i.A)(this.e,Math.sin(a));e=this.x0+this.a*this.k0*s,n=this.y0+this.a*u*.5/this.k0}return t.x=e,t.y=n,t}function l(t){var e,n;return t.x-=this.x0,t.y-=this.y0,this.sphere?(e=(0,r.A)(this.long0+t.x/this.a/Math.cos(this.lat_ts)),n=Math.asin(t.y/this.a*Math.cos(this.lat_ts))):(n=function(t,e){var n=1-(1-t*t)/(2*t)*Math.log((1-t)/(1+t));if(Math.abs(Math.abs(e)-n)<1e-6)return e<0?-1*a.sK:a.sK;for(var r,i,o,s,u=Math.asin(.5*e),l=0;l<30;l++)if(i=Math.sin(u),o=Math.cos(u),s=t*i,u+=r=Math.pow(1-s*s,2)/(2*o)*(e/(1-t*t)-i/(1-s*s)+.5/t*Math.log((1-s)/(1+s))),Math.abs(r)<=1e-10)return u;return NaN}(this.e,2*t.y*this.k0/this.a),e=(0,r.A)(this.long0+t.x/(this.a*this.k0))),t.x=e,t.y=n,t}var c=["cea"],f={init:s,forward:u,inverse:l,names:c}},4256:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},names:function(){return u}});var r=n(737),i=n(5473);function o(){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=Math.cos(this.lat_ts)}function a(t){var e=t.x,n=t.y,o=(0,r.A)(e-this.long0),a=(0,i.A)(n-this.lat0);return t.x=this.x0+this.a*o*this.rc,t.y=this.y0+this.a*a,t}function s(t){var e=t.x,n=t.y;return t.x=(0,r.A)(this.long0+(e-this.x0)/(this.a*this.rc)),t.y=(0,i.A)(this.lat0+(n-this.y0)/this.a),t}var u=["Equirectangular","Equidistant_Cylindrical","eqc"];e.default={init:o,forward:a,inverse:s,names:u}},7968:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(8193),i=n(9686),o=n(7711),a=n(2060),s=n(444),u=n(4037),l=n(737),c=n(5473),f=n(6592),h=n(2556);function d(){Math.abs(this.lat1+this.lat2)<h.H0||(this.lat2=this.lat2||this.lat1,this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=(0,r.A)(this.es),this.e1=(0,i.A)(this.es),this.e2=(0,o.A)(this.es),this.e3=(0,a.A)(this.es),this.sinphi=Math.sin(this.lat1),this.cosphi=Math.cos(this.lat1),this.ms1=(0,s.A)(this.e,this.sinphi,this.cosphi),this.ml1=(0,u.A)(this.e0,this.e1,this.e2,this.e3,this.lat1),Math.abs(this.lat1-this.lat2)<h.H0?this.ns=this.sinphi:(this.sinphi=Math.sin(this.lat2),this.cosphi=Math.cos(this.lat2),this.ms2=(0,s.A)(this.e,this.sinphi,this.cosphi),this.ml2=(0,u.A)(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=(0,u.A)(this.e0,this.e1,this.e2,this.e3,this.lat0),this.rh=this.a*(this.g-this.ml0))}function p(t){var e,n=t.x,r=t.y;if(this.sphere)e=this.a*(this.g-r);else{var i=(0,u.A)(this.e0,this.e1,this.e2,this.e3,r);e=this.a*(this.g-i)}var o=this.ns*(0,l.A)(n-this.long0),a=this.x0+e*Math.sin(o),s=this.y0+this.rh-e*Math.cos(o);return t.x=a,t.y=s,t}function m(t){var e,n,r,i;t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns>=0?(n=Math.sqrt(t.x*t.x+t.y*t.y),e=1):(n=-Math.sqrt(t.x*t.x+t.y*t.y),e=-1);var o=0;if(0!==n&&(o=Math.atan2(e*t.x,e*t.y)),this.sphere)return i=(0,l.A)(this.long0+o/this.ns),r=(0,c.A)(this.g-n/this.a),t.x=i,t.y=r,t;var a=this.g-n/this.a;return r=(0,f.A)(a,this.e0,this.e1,this.e2,this.e3),i=(0,l.A)(this.long0+o/this.ns),t.x=i,t.y=r,t}var g=["Equidistant_Conic","eqdc"];e.default={init:d,forward:p,inverse:m,names:g}},7129:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(737),i=1.340264,o=-.081106,a=893e-6,s=.003796,u=Math.sqrt(3)/2;function l(){this.es=0,this.long0=void 0!==this.long0?this.long0:0}function c(t){var e=(0,r.A)(t.x-this.long0),n=t.y,l=Math.asin(u*Math.sin(n)),c=l*l,f=c*c*c;return t.x=e*Math.cos(l)/(u*(i+3*o*c+f*(7*a+9*s*c))),t.y=l*(i+o*c+f*(a+s*c)),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function f(t){t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a;var e,n,l,c,f=t.y;for(c=0;c<12&&(f-=l=(f*(i+o*(e=f*f)+(n=e*e*e)*(a+s*e))-t.y)/(i+3*o*e+n*(7*a+9*s*e)),!(Math.abs(l)<1e-9));++c);return n=(e=f*f)*e*e,t.x=u*t.x*(i+3*o*e+n*(7*a+9*s*e))/Math.cos(f),t.y=Math.asin(Math.sin(f)/u),t.x=(0,r.A)(t.x+this.long0),t}var h=["eqearth","Equal Earth","Equal_Earth"];e.default={init:l,forward:c,inverse:f,names:h}},3667:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0}function o(t){var e=t.x,n=t.y,i=(0,r.A)(e-this.long0),o=this.x0+this.a*i*Math.cos(this.lat0),a=this.y0+this.a*n;return this.t1=o,this.t2=Math.cos(this.lat0),t.x=o,t.y=a,t}function a(t){t.x-=this.x0,t.y-=this.y0;var e=t.y/this.a,n=(0,r.A)(this.long0+t.x/(this.a*Math.cos(this.lat0)));t.x=n,t.y=e}var s=["equi"];e.default={init:i,forward:o,inverse:a,names:s}},994:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return m},forward:function(){return h},init:function(){return f},inverse:function(){return d},names:function(){return p}});var r=n(5602),i=n(3882),o=n(1708);function a(t){var e=Math.abs(t);return e=function(t){var e=1+t,n=e-1;return 0===n?t:t*Math.log(e)/n}(e*(1+e/((0,o.A)(1,e)+1))),t<0?-e:e}function s(t,e){for(var n,r=2*Math.cos(2*e),i=t.length-1,o=t[i],a=0;--i>=0;)n=r*o-a+t[i],a=o,o=n;return e+n*Math.sin(2*e)}var u=n(4885);function l(t,e,n){for(var r,o,a=Math.sin(e),s=Math.cos(e),l=(0,i.A)(n),c=(0,u.A)(n),f=2*s*c,h=-2*a*l,d=t.length-1,p=t[d],m=0,g=0,y=0;--d>=0;)r=g,o=m,p=f*(g=p)-r-h*(m=y)+t[d],y=h*g-o+f*m;return[(f=a*c)*p-(h=s*l)*y,f*y+h*p]}var c=n(737);function f(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&(r.default.init.apply(this),this.forward=r.default.forward,this.inverse=r.default.inverse),this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var t=this.es/(1+Math.sqrt(1-this.es)),e=t/(2-t),n=e;this.cgb[0]=e*(2+e*(-2/3+e*(e*(116/45+e*(26/45+e*(-2854/675)))-2))),this.cbg[0]=e*(e*(2/3+e*(4/3+e*(-82/45+e*(32/45+e*(4642/4725)))))-2),n*=e,this.cgb[1]=n*(7/3+e*(e*(-227/45+e*(2704/315+e*(2323/945)))-1.6)),this.cbg[1]=n*(5/3+e*(-16/15+e*(-13/9+e*(904/315+e*(-1522/945))))),n*=e,this.cgb[2]=n*(56/15+e*(-136/35+e*(-1262/105+e*(73814/2835)))),this.cbg[2]=n*(-26/15+e*(34/21+e*(1.6+e*(-12686/2835)))),n*=e,this.cgb[3]=n*(4279/630+e*(-332/35+e*(-399572/14175))),this.cbg[3]=n*(1237/630+e*(e*(-24832/14175)-2.4)),n*=e,this.cgb[4]=n*(4174/315+e*(-144838/6237)),this.cbg[4]=n*(-734/315+e*(109598/31185)),n*=e,this.cgb[5]=n*(601676/22275),this.cbg[5]=n*(444337/155925),n=Math.pow(e,2),this.Qn=this.k0/(1+e)*(1+n*(1/4+n*(1/64+n/256))),this.utg[0]=e*(e*(2/3+e*(-37/96+e*(1/360+e*(81/512+e*(-96199/604800)))))-.5),this.gtu[0]=e*(.5+e*(-2/3+e*(5/16+e*(41/180+e*(-127/288+e*(7891/37800)))))),this.utg[1]=n*(-1/48+e*(-1/15+e*(437/1440+e*(-46/105+e*(1118711/3870720))))),this.gtu[1]=n*(13/48+e*(e*(557/1440+e*(281/630+e*(-1983433/1935360)))-.6)),n*=e,this.utg[2]=n*(-17/480+e*(37/840+e*(209/4480+e*(-5569/90720)))),this.gtu[2]=n*(61/240+e*(-103/140+e*(15061/26880+e*(167603/181440)))),n*=e,this.utg[3]=n*(-4397/161280+e*(11/504+e*(830251/7257600))),this.gtu[3]=n*(49561/161280+e*(-179/168+e*(6601661/7257600))),n*=e,this.utg[4]=n*(-4583/161280+e*(108847/3991680)),this.gtu[4]=n*(34729/80640+e*(-3418889/1995840)),n*=e,this.utg[5]=n*(-20648693/638668800),this.gtu[5]=.6650675310896665*n;var i=s(this.cbg,this.lat0);this.Zb=-this.Qn*(i+function(t,e){for(var n,r=2*Math.cos(e),i=t.length-1,o=t[i],a=0;--i>=0;)n=r*o-a+t[i],a=o,o=n;return Math.sin(e)*n}(this.gtu,2*i))}function h(t){var e=(0,c.A)(t.x-this.long0),n=t.y;n=s(this.cbg,n);var r=Math.sin(n),i=Math.cos(n),u=Math.sin(e),f=Math.cos(e);n=Math.atan2(r,f*i),e=Math.atan2(u*i,(0,o.A)(r,i*f)),e=a(Math.tan(e));var h,d,p=l(this.gtu,2*n,2*e);return n+=p[0],e+=p[1],Math.abs(e)<=2.623395162778?(h=this.a*(this.Qn*e)+this.x0,d=this.a*(this.Qn*n+this.Zb)+this.y0):(h=1/0,d=1/0),t.x=h,t.y=d,t}function d(t){var e,n,r=(t.x-this.x0)*(1/this.a),a=(t.y-this.y0)*(1/this.a);if(a=(a-this.Zb)/this.Qn,r/=this.Qn,Math.abs(r)<=2.623395162778){var u=l(this.utg,2*a,2*r);a+=u[0],r+=u[1],r=Math.atan((0,i.A)(r));var f=Math.sin(a),h=Math.cos(a),d=Math.sin(r),p=Math.cos(r);a=Math.atan2(f*p,(0,o.A)(d,p*h)),r=Math.atan2(d,p*h),e=(0,c.A)(r+this.long0),n=s(this.cgb,a)}else e=1/0,n=1/0;return t.x=e,t.y=n,t}var p=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"],m={init:f,forward:h,inverse:d,names:p}},3246:function(t,e,n){"use strict";function r(t,e){return Math.pow((1-t)/(1+t),e)}n.r(e),n.d(e,{default:function(){return c},forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var i=n(2556),o=20;function a(){var t=Math.sin(this.lat0),e=Math.cos(this.lat0);e*=e,this.rc=Math.sqrt(1-this.es)/(1-this.es*t*t),this.C=Math.sqrt(1+this.es*e*e/(1-this.es)),this.phic0=Math.asin(t/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+i.Vj)/(Math.pow(Math.tan(.5*this.lat0+i.Vj),this.C)*r(this.e*t,this.ratexp))}function s(t){var e=t.x,n=t.y;return t.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*n+i.Vj),this.C)*r(this.e*Math.sin(n),this.ratexp))-i.sK,t.x=this.C*e,t}function u(t){for(var e=t.x/this.C,n=t.y,a=Math.pow(Math.tan(.5*n+i.Vj)/this.K,1/this.C),s=o;s>0&&(n=2*Math.atan(a*r(this.e*Math.sin(t.y),-.5*this.e))-i.sK,!(Math.abs(n-t.y)<1e-14));--s)t.y=n;return s?(t.x=e,t.y=n,t):null}var l=["gauss"],c={init:a,forward:s,inverse:u,names:l}},4876:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(9160);function i(){this.name="geocent"}function o(t){return(0,r.jX)(t,this.es,this.a)}function a(t){return(0,r.Rw)(t,this.es,this.a,this.b)}var s=["Geocentric","geocentric","geocent","Geocent"];e.default={init:i,forward:o,inverse:a,names:s}},469:function(t,e,n){"use strict";n.r(e),n.d(e,{init:function(){return i},names:function(){return o}});var r=n(1708);function i(){if(this.flip_axis="x"===this.sweep?1:0,this.h=Number(this.h),this.radius_g_1=this.h/this.a,this.radius_g_1<=0||this.radius_g_1>1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,0!==this.es){var t=1-this.es,e=1/t;this.radius_p=Math.sqrt(t),this.radius_p2=t,this.radius_p_inv2=e,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")}var o=["Geostationary Satellite View","Geostationary_Satellite","geos"];e.default={init:i,forward:function(t){var e,n,i,o,a=t.x,s=t.y;if(a-=this.long0,"ellipse"===this.shape){s=Math.atan(this.radius_p2*Math.tan(s));var u=this.radius_p/(0,r.A)(this.radius_p*Math.cos(s),Math.sin(s));if(n=u*Math.cos(a)*Math.cos(s),i=u*Math.sin(a)*Math.cos(s),o=u*Math.sin(s),(this.radius_g-n)*n-i*i-o*o*this.radius_p_inv2<0)return t.x=Number.NaN,t.y=Number.NaN,t;e=this.radius_g-n,this.flip_axis?(t.x=this.radius_g_1*Math.atan(i/(0,r.A)(o,e)),t.y=this.radius_g_1*Math.atan(o/e)):(t.x=this.radius_g_1*Math.atan(i/e),t.y=this.radius_g_1*Math.atan(o/(0,r.A)(i,e)))}else"sphere"===this.shape&&(e=Math.cos(s),n=Math.cos(a)*e,i=Math.sin(a)*e,o=Math.sin(s),e=this.radius_g-n,this.flip_axis?(t.x=this.radius_g_1*Math.atan(i/(0,r.A)(o,e)),t.y=this.radius_g_1*Math.atan(o/e)):(t.x=this.radius_g_1*Math.atan(i/e),t.y=this.radius_g_1*Math.atan(o/(0,r.A)(i,e))));return t.x=t.x*this.a,t.y=t.y*this.a,t},inverse:function(t){var e,n,i,o,a=-1,s=0,u=0;if(t.x=t.x/this.a,t.y=t.y/this.a,"ellipse"===this.shape){this.flip_axis?(u=Math.tan(t.y/this.radius_g_1),s=Math.tan(t.x/this.radius_g_1)*(0,r.A)(1,u)):(s=Math.tan(t.x/this.radius_g_1),u=Math.tan(t.y/this.radius_g_1)*(0,r.A)(1,s));var l=u/this.radius_p;if(e=s*s+l*l+a*a,(i=(n=2*this.radius_g*a)*n-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;o=(-n-Math.sqrt(i))/(2*e),a=this.radius_g+o*a,s*=o,u*=o,t.x=Math.atan2(s,a),t.y=Math.atan(u*Math.cos(t.x)/a),t.y=Math.atan(this.radius_p_inv2*Math.tan(t.y))}else if("sphere"===this.shape){if(this.flip_axis?(u=Math.tan(t.y/this.radius_g_1),s=Math.tan(t.x/this.radius_g_1)*Math.sqrt(1+u*u)):(s=Math.tan(t.x/this.radius_g_1),u=Math.tan(t.y/this.radius_g_1)*Math.sqrt(1+s*s)),e=s*s+u*u+a*a,(i=(n=2*this.radius_g*a)*n-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;o=(-n-Math.sqrt(i))/(2*e),a=this.radius_g+o*a,s*=o,u*=o,t.x=Math.atan2(s,a),t.y=Math.atan(u*Math.cos(t.x)/a)}return t.x=t.x+this.long0,t},names:o}},9462:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(8609),o=n(2556);function a(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0),this.infinity_dist=1e3*this.a,this.rc=1}function s(t){var e,n,i,a,s,u,l,c=t.x,f=t.y;return i=(0,r.A)(c-this.long0),e=Math.sin(f),n=Math.cos(f),a=Math.cos(i),(s=this.sin_p14*e+this.cos_p14*n*a)>0||Math.abs(s)<=o.H0?(u=this.x0+1*this.a*n*Math.sin(i)/s,l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*n*a)/s):(u=this.x0+this.infinity_dist*n*Math.sin(i),l=this.y0+this.infinity_dist*(this.cos_p14*e-this.sin_p14*n*a)),t.x=u,t.y=l,t}function u(t){var e,n,o,a,s,u;return t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,(e=Math.sqrt(t.x*t.x+t.y*t.y))?(a=Math.atan2(e,this.rc),n=Math.sin(a),o=Math.cos(a),u=(0,i.A)(o*this.sin_p14+t.y*n*this.cos_p14/e),s=Math.atan2(t.x*n,e*this.cos_p14*o-t.y*this.sin_p14*n),s=(0,r.A)(this.long0+s)):(u=this.phic0,s=0),t.x=s,t.y=u,t}var l=["gnom"];e.default={init:a,forward:s,inverse:u,names:l}},7041:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return h},forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(2556);function i(t,e,n){if(Math.abs(e)>r.sK)return Number.NaN;if(e===r.sK)return Number.POSITIVE_INFINITY;if(e===-1*r.sK)return Number.NEGATIVE_INFINITY;var i=t*n;return Math.log(Math.tan((r.sK+e)/2))+t*Math.log((1-i)/(1+i))/2}var o=n(3882),a=n(4885);function s(t,e){return 2*Math.atan(t*Math.exp(e))-r.sK}function u(){var t=this.b/this.a;this.e=Math.sqrt(1-t*t),this.lc=this.long0,this.rs=Math.sqrt(1+this.e*this.e*Math.pow(Math.cos(this.lat0),4)/(1-this.e*this.e));var e=Math.sin(this.lat0),n=Math.asin(e/this.rs),r=Math.sin(n);this.cp=i(0,n,r)-this.rs*i(this.e,this.lat0,e),this.n2=this.k0*this.a*Math.sqrt(1-this.e*this.e)/(1-this.e*this.e*e*e),this.xs=this.x0,this.ys=this.y0-this.n2*n,this.title||(this.title="Gauss Schreiber transverse mercator")}function l(t){var e=t.x,n=t.y,r=this.rs*(e-this.lc),s=this.cp+this.rs*i(this.e,n,Math.sin(n)),u=Math.asin(Math.sin(r)/(0,a.A)(s)),l=i(0,u,Math.sin(u));return t.x=this.xs+this.n2*l,t.y=this.ys+this.n2*Math.atan((0,o.A)(s)/Math.cos(r)),t}function c(t){var e=t.x,n=t.y,r=Math.atan((0,o.A)((e-this.xs)/this.n2)/Math.cos((n-this.ys)/this.n2)),u=Math.asin(Math.sin((n-this.ys)/this.n2)/(0,a.A)((e-this.xs)/this.n2)),l=i(0,u,Math.sin(u));return t.x=this.lc+r/this.rs,t.y=function(t,e){var n=s(1,e),r=0,i=0;do{r=n,i=t*Math.sin(r),n=s(Math.exp(t*Math.log((1+i)/(1-i))/2),e)}while(Math.abs(n-r)>1e-12);return n}(this.e,(l-this.cp)/this.rs),t}var f=["gstmerg","gstmerc"],h={init:u,forward:l,inverse:c,names:f}},6507:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){this.a=6377397.155,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.4334234309119251),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function o(t){var e,n,i,o,a,s,u,l=t.x,c=t.y,f=(0,r.A)(l-this.long0);return e=Math.pow((1+this.e*Math.sin(c))/(1-this.e*Math.sin(c)),this.alfa*this.e/2),n=2*(Math.atan(this.k*Math.pow(Math.tan(c/2+this.s45),this.alfa)/e)-this.s45),i=-f*this.alfa,o=Math.asin(Math.cos(this.ad)*Math.sin(n)+Math.sin(this.ad)*Math.cos(n)*Math.cos(i)),a=Math.asin(Math.cos(n)*Math.sin(i)/Math.cos(o)),s=this.n*a,u=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(o/2+this.s45),this.n),t.y=u*Math.cos(s)/1,t.x=u*Math.sin(s)/1,this.czech||(t.y*=-1,t.x*=-1),t}function a(t){var e,n,r,i,o,a,s,u=t.x;t.x=t.y,t.y=u,this.czech||(t.y*=-1,t.x*=-1),o=Math.sqrt(t.x*t.x+t.y*t.y),i=Math.atan2(t.y,t.x)/Math.sin(this.s0),r=2*(Math.atan(Math.pow(this.ro0/o,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),e=Math.asin(Math.cos(this.ad)*Math.sin(r)-Math.sin(this.ad)*Math.cos(r)*Math.cos(i)),n=Math.asin(Math.cos(r)*Math.sin(i)/Math.cos(e)),t.x=this.long0-n/this.alfa,a=e,s=0;var l=0;do{t.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(e/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(a))/(1-this.e*Math.sin(a)),this.e/2))-this.s45),Math.abs(a-t.y)<1e-10&&(s=1),a=t.y,l+=1}while(0===s&&l<15);return l>=15?null:t}var s=["Krovak","krovak"];e.default={init:i,forward:o,inverse:a,names:s}},7406:function(t,e,n){"use strict";n.r(e),n.d(e,{EQUIT:function(){return u},N_POLE:function(){return s},OBLIQ:function(){return l},S_POLE:function(){return a},forward:function(){return f},init:function(){return c},inverse:function(){return h},names:function(){return x}});var r=n(2556),i=n(7200),o=n(737),a=1,s=2,u=3,l=4;function c(){var t,e=Math.abs(this.lat0);if(Math.abs(e-r.sK)<r.H0?this.mode=this.lat0<0?this.S_POLE:this.N_POLE:Math.abs(e)<r.H0?this.mode=this.EQUIT:this.mode=this.OBLIQ,this.es>0)switch(this.qp=(0,i.A)(this.e,1),this.mmf=.5/(1-this.es),this.apa=function(t){var e,n=[];return n[0]=t*d,e=t*t,n[0]+=e*p,n[1]=e*g,e*=t,n[0]+=e*m,n[1]+=e*y,n[2]=e*v,n}(this.es),this.mode){case this.N_POLE:case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=(0,i.A)(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(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=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function f(t){var e,n,a,s,u,l,c,f,h,d,p=t.x,m=t.y;if(p=(0,o.A)(p-this.long0),this.sphere){if(u=Math.sin(m),d=Math.cos(m),a=Math.cos(p),this.mode===this.OBLIQ||this.mode===this.EQUIT){if((n=this.mode===this.EQUIT?1+d*a:1+this.sinph0*u+this.cosph0*d*a)<=r.H0)return null;e=(n=Math.sqrt(2/n))*d*Math.sin(p),n*=this.mode===this.EQUIT?u:this.cosph0*u-this.sinph0*d*a}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(a=-a),Math.abs(m+this.lat0)<r.H0)return null;n=r.Vj-.5*m,e=(n=2*(this.mode===this.S_POLE?Math.cos(n):Math.sin(n)))*Math.sin(p),n*=a}}else{switch(c=0,f=0,h=0,a=Math.cos(p),s=Math.sin(p),u=Math.sin(m),l=(0,i.A)(this.e,u),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(c=l/this.qp,f=Math.sqrt(1-c*c)),this.mode){case this.OBLIQ:h=1+this.sinb1*c+this.cosb1*f*a;break;case this.EQUIT:h=1+f*a;break;case this.N_POLE:h=r.sK+m,l=this.qp-l;break;case this.S_POLE:h=m-r.sK,l=this.qp+l}if(Math.abs(h)<r.H0)return null;switch(this.mode){case this.OBLIQ:case this.EQUIT:h=Math.sqrt(2/h),n=this.mode===this.OBLIQ?this.ymf*h*(this.cosb1*c-this.sinb1*f*a):(h=Math.sqrt(2/(1+f*a)))*c*this.ymf,e=this.xmf*h*f*s;break;case this.N_POLE:case this.S_POLE:l>=0?(e=(h=Math.sqrt(l))*s,n=a*(this.mode===this.S_POLE?h:-h)):e=n=0}}return t.x=this.a*e+this.x0,t.y=this.a*n+this.y0,t}function h(t){t.x-=this.x0,t.y-=this.y0;var e,n,i,a,s,u,l,c,f,h,d=t.x/this.a,p=t.y/this.a;if(this.sphere){var m,g=0,y=0;if((n=.5*(m=Math.sqrt(d*d+p*p)))>1)return null;switch(n=2*Math.asin(n),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(y=Math.sin(n),g=Math.cos(n)),this.mode){case this.EQUIT:n=Math.abs(m)<=r.H0?0:Math.asin(p*y/m),d*=y,p=g*m;break;case this.OBLIQ:n=Math.abs(m)<=r.H0?this.lat0:Math.asin(g*this.sinph0+p*y*this.cosph0/m),d*=y*this.cosph0,p=(g-Math.sin(n)*this.sinph0)*m;break;case this.N_POLE:p=-p,n=r.sK-n;break;case this.S_POLE:n-=r.sK}e=0!==p||this.mode!==this.EQUIT&&this.mode!==this.OBLIQ?Math.atan2(d,p):0}else{if(l=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(d/=this.dd,p*=this.dd,(u=Math.sqrt(d*d+p*p))<r.H0)return t.x=this.long0,t.y=this.lat0,t;a=2*Math.asin(.5*u/this.rq),i=Math.cos(a),d*=a=Math.sin(a),this.mode===this.OBLIQ?(l=i*this.sinb1+p*a*this.cosb1/u,s=this.qp*l,p=u*this.cosb1*i-p*this.sinb1*a):(l=p*a/u,s=this.qp*l,p=u*i)}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(p=-p),!(s=d*d+p*p))return t.x=this.long0,t.y=this.lat0,t;l=1-s/this.qp,this.mode===this.S_POLE&&(l=-l)}e=Math.atan2(d,p),c=Math.asin(l),f=this.apa,h=c+c,n=c+f[0]*Math.sin(h)+f[1]*Math.sin(h+h)+f[2]*Math.sin(h+h+h)}return t.x=(0,o.A)(this.long0+e),t.y=n,t}var d=.3333333333333333,p=.17222222222222222,m=.10257936507936508,g=.06388888888888888,y=.0664021164021164,v=.016415012942191543;var x=["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"];e.default={init:c,forward:f,inverse:h,names:x,S_POLE:a,N_POLE:s,EQUIT:u,OBLIQ:l}},9269:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(444),i=n(9967),o=n(4205),a=n(737),s=n(1793),u=n(2556);function l(){if(this.lat2||(this.lat2=this.lat1),this.k0||(this.k0=1),this.x0=this.x0||0,this.y0=this.y0||0,!(Math.abs(this.lat1+this.lat2)<u.H0)){var t=this.b/this.a;this.e=Math.sqrt(1-t*t);var e=Math.sin(this.lat1),n=Math.cos(this.lat1),o=(0,r.A)(this.e,e,n),a=(0,i.A)(this.e,this.lat1,e),s=Math.sin(this.lat2),l=Math.cos(this.lat2),c=(0,r.A)(this.e,s,l),f=(0,i.A)(this.e,this.lat2,s),h=(0,i.A)(this.e,this.lat0,Math.sin(this.lat0));Math.abs(this.lat1-this.lat2)>u.H0?this.ns=Math.log(o/c)/Math.log(a/f):this.ns=e,isNaN(this.ns)&&(this.ns=e),this.f0=o/(this.ns*Math.pow(a,this.ns)),this.rh=this.a*this.f0*Math.pow(h,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function c(t){var e=t.x,n=t.y;Math.abs(2*Math.abs(n)-Math.PI)<=u.H0&&(n=(0,o.A)(n)*(u.sK-2*u.H0));var r,s,l=Math.abs(Math.abs(n)-u.sK);if(l>u.H0)r=(0,i.A)(this.e,n,Math.sin(n)),s=this.a*this.f0*Math.pow(r,this.ns);else{if((l=n*this.ns)<=0)return null;s=0}var c=this.ns*(0,a.A)(e-this.long0);return t.x=this.k0*(s*Math.sin(c))+this.x0,t.y=this.k0*(this.rh-s*Math.cos(c))+this.y0,t}function f(t){var e,n,r,i,o,l=(t.x-this.x0)/this.k0,c=this.rh-(t.y-this.y0)/this.k0;this.ns>0?(e=Math.sqrt(l*l+c*c),n=1):(e=-Math.sqrt(l*l+c*c),n=-1);var f=0;if(0!==e&&(f=Math.atan2(n*l,n*c)),0!==e||this.ns>0){if(n=1/this.ns,r=Math.pow(e/(this.a*this.f0),n),-9999===(i=(0,s.A)(this.e,r)))return null}else i=-u.sK;return o=(0,a.A)(f/this.ns+this.long0),t.x=o,t.y=i,t}var h=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"];e.default={init:l,forward:c,inverse:f,names:h}},2848:function(t,e,n){"use strict";function r(){}function i(t){return t}n.r(e),n.d(e,{forward:function(){return i},init:function(){return r},inverse:function(){return i},names:function(){return o}});var o=["longlat","identity"];e.default={init:r,forward:i,inverse:i,names:o}},2286:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(444),i=n(737),o=n(9967),a=n(1793),s=n(2556);function u(){var t=this.b/this.a;this.es=1-t*t,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=(0,r.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function l(t){var e,n,r=t.x,a=t.y;if(a*s.dX>90&&a*s.dX<-90&&r*s.dX>180&&r*s.dX<-180)return null;if(Math.abs(Math.abs(a)-s.sK)<=s.H0)return null;if(this.sphere)e=this.x0+this.a*this.k0*(0,i.A)(r-this.long0),n=this.y0+this.a*this.k0*Math.log(Math.tan(s.Vj+.5*a));else{var u=Math.sin(a),l=(0,o.A)(this.e,a,u);e=this.x0+this.a*this.k0*(0,i.A)(r-this.long0),n=this.y0-this.a*this.k0*Math.log(l)}return t.x=e,t.y=n,t}function c(t){var e,n,r=t.x-this.x0,o=t.y-this.y0;if(this.sphere)n=s.sK-2*Math.atan(Math.exp(-o/(this.a*this.k0)));else{var u=Math.exp(-o/(this.a*this.k0));if(-9999===(n=(0,a.A)(this.e,u)))return null}return e=(0,i.A)(this.long0+r/(this.a*this.k0)),t.x=e,t.y=n,t}var f=["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"];e.default={init:u,forward:l,inverse:c,names:f}},5157:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){}function o(t){var e=t.x,n=t.y,i=(0,r.A)(e-this.long0),o=this.x0+this.a*i,a=this.y0+this.a*Math.log(Math.tan(Math.PI/4+n/2.5))*1.25;return t.x=o,t.y=a,t}function a(t){t.x-=this.x0,t.y-=this.y0;var e=(0,r.A)(this.long0+t.x/this.a),n=2.5*(Math.atan(Math.exp(.8*t.y/this.a))-Math.PI/4);return t.x=e,t.y=n,t}var s=["Miller_Cylindrical","mill"];e.default={init:i,forward:o,inverse:a,names:s}},5967:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},names:function(){return u}});var r=n(737),i=n(2556);function o(){}function a(t){for(var e=t.x,n=t.y,o=(0,r.A)(e-this.long0),a=n,s=Math.PI*Math.sin(n);;){var u=-(a+Math.sin(a)-s)/(1+Math.cos(a));if(a+=u,Math.abs(u)<i.H0)break}a/=2,Math.PI/2-Math.abs(n)<i.H0&&(o=0);var l=.900316316158*this.a*o*Math.cos(a)+this.x0,c=1.4142135623731*this.a*Math.sin(a)+this.y0;return t.x=l,t.y=c,t}function s(t){var e,n;t.x-=this.x0,t.y-=this.y0,n=t.y/(1.4142135623731*this.a),Math.abs(n)>.999999999999&&(n=.999999999999),e=Math.asin(n);var i=(0,r.A)(this.long0+t.x/(.900316316158*this.a*Math.cos(e)));i<-Math.PI&&(i=-Math.PI),i>Math.PI&&(i=Math.PI),n=(2*e+Math.sin(2*e))/Math.PI,Math.abs(n)>1&&(n=1);var o=Math.asin(n);return t.x=i,t.y=o,t}var u=["Mollweide","moll"];e.default={init:o,forward:a,inverse:s,names:u}},6407:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},iterations:function(){return i},names:function(){return u}});var r=n(2556),i=1;function o(){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}function a(t){var e,n=t.x,i=t.y-this.lat0,o=n-this.long0,a=i/r._3*1e-5,s=o,u=1,l=0;for(e=1;e<=10;e++)u*=a,l+=this.A[e]*u;var c,f=l,h=s,d=1,p=0,m=0,g=0;for(e=1;e<=6;e++)c=p*f+d*h,d=d*f-p*h,p=c,m=m+this.B_re[e]*d-this.B_im[e]*p,g=g+this.B_im[e]*d+this.B_re[e]*p;return t.x=g*this.a+this.x0,t.y=m*this.a+this.y0,t}function s(t){var e,n,i=t.x,o=t.y,a=i-this.x0,s=(o-this.y0)/this.a,u=a/this.a,l=1,c=0,f=0,h=0;for(e=1;e<=6;e++)n=c*s+l*u,l=l*s-c*u,c=n,f=f+this.C_re[e]*l-this.C_im[e]*c,h=h+this.C_im[e]*l+this.C_re[e]*c;for(var d=0;d<this.iterations;d++){var p,m=f,g=h,y=s,v=u;for(e=2;e<=6;e++)p=g*f+m*h,m=m*f-g*h,g=p,y+=(e-1)*(this.B_re[e]*m-this.B_im[e]*g),v+=(e-1)*(this.B_im[e]*m+this.B_re[e]*g);m=1,g=0;var x=this.B_re[1],_=this.B_im[1];for(e=2;e<=6;e++)p=g*f+m*h,m=m*f-g*h,g=p,x+=e*(this.B_re[e]*m-this.B_im[e]*g),_+=e*(this.B_im[e]*m+this.B_re[e]*g);var b=x*x+_*_;f=(y*x+v*_)/b,h=(v*x-y*_)/b}var w=f,M=h,A=1,T=0;for(e=1;e<=9;e++)A*=w,T+=this.D[e]*A;var E=this.lat0+T*r._3*1e5,C=this.long0+M;return t.x=C,t.y=E,t}var u=["New_Zealand_Map_Grid","nzmg"];e.default={init:o,forward:a,inverse:s,names:u}},7475:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(9967),i=n(737),o=n(1793),a=n(2556),s=1e-7;function u(){var t,e,n,o,u,l,c,f,h,d,p,m,g,y=0,v=0,x=0,_=0,b=0,w=0,M=0;this.no_off=(g="object"==typeof(m=this).PROJECTION?Object.keys(m.PROJECTION)[0]:m.PROJECTION,"no_uoff"in m||"no_off"in m||-1!==["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"].indexOf(g)),this.no_rot="no_rot"in this;var A=!1;"alpha"in this&&(A=!0);var T=!1;if("rectified_grid_angle"in this&&(T=!0),A&&(M=this.alpha),T&&(y=this.rectified_grid_angle*a.zq),A||T)v=this.longc;else if(x=this.long1,b=this.lat1,_=this.long2,w=this.lat2,Math.abs(b-w)<=s||(t=Math.abs(b))<=s||Math.abs(t-a.sK)<=s||Math.abs(Math.abs(this.lat0)-a.sK)<=s||Math.abs(Math.abs(w)-a.sK)<=s)throw new Error;var E=1-this.es;e=Math.sqrt(E),Math.abs(this.lat0)>a.H0?(f=Math.sin(this.lat0),n=Math.cos(this.lat0),t=1-this.es*f*f,this.B=n*n,this.B=Math.sqrt(1+this.es*this.B*this.B/E),this.A=this.B*this.k0*e/t,(u=(o=this.B*e/(n*Math.sqrt(t)))*o-1)<=0?u=0:(u=Math.sqrt(u),this.lat0<0&&(u=-u)),this.E=u+=o,this.E*=Math.pow((0,r.A)(this.e,this.lat0,f),this.B)):(this.B=1/e,this.A=this.k0,this.E=o=u=1),A||T?(A?(p=Math.asin(Math.sin(M)/o),T||(y=M)):(p=y,M=Math.asin(o*Math.sin(p))),this.lam0=v-Math.asin(.5*(u-1/u)*Math.tan(p))/this.B):(l=Math.pow((0,r.A)(this.e,b,Math.sin(b)),this.B),c=Math.pow((0,r.A)(this.e,w,Math.sin(w)),this.B),u=this.E/l,h=(c-l)/(c+l),d=((d=this.E*this.E)-c*l)/(d+c*l),(t=x-_)<-Math.pi?_-=a.JM:t>Math.pi&&(_+=a.JM),this.lam0=(0,i.A)(.5*(x+_)-Math.atan(d*Math.tan(.5*this.B*(x-_))/h)/this.B),p=Math.atan(2*Math.sin(this.B*(0,i.A)(x-this.lam0))/(u-1/u)),y=M=Math.asin(o*Math.sin(p))),this.singam=Math.sin(p),this.cosgam=Math.cos(p),this.sinrot=Math.sin(y),this.cosrot=Math.cos(y),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.A,this.B,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(o*o-1)/Math.cos(M))),this.lat0<0&&(this.u_0=-this.u_0)),u=.5*p,this.v_pole_n=this.ArB*Math.log(Math.tan(a.Vj-u)),this.v_pole_s=this.ArB*Math.log(Math.tan(a.Vj+u))}function l(t){var e,n,i,o,u,l,c,f,h={};if(t.x=t.x-this.lam0,Math.abs(Math.abs(t.y)-a.sK)>a.H0){if(e=.5*((u=this.E/Math.pow((0,r.A)(this.e,t.y,Math.sin(t.y)),this.B))-(l=1/u)),n=.5*(u+l),o=Math.sin(this.B*t.x),i=(e*this.singam-o*this.cosgam)/n,Math.abs(Math.abs(i)-1)<a.H0)throw new Error;f=.5*this.ArB*Math.log((1-i)/(1+i)),l=Math.cos(this.B*t.x),c=Math.abs(l)<s?this.A*t.x:this.ArB*Math.atan2(e*this.cosgam+o*this.singam,l)}else f=t.y>0?this.v_pole_n:this.v_pole_s,c=this.ArB*t.y;return this.no_rot?(h.x=c,h.y=f):(c-=this.u_0,h.x=f*this.cosrot+c*this.sinrot,h.y=c*this.cosrot-f*this.sinrot),h.x=this.a*h.x+this.x0,h.y=this.a*h.y+this.y0,h}function c(t){var e,n,r,i,s,u,l,c={};if(t.x=(t.x-this.x0)*(1/this.a),t.y=(t.y-this.y0)*(1/this.a),this.no_rot?(n=t.y,e=t.x):(n=t.x*this.cosrot-t.y*this.sinrot,e=t.y*this.cosrot+t.x*this.sinrot+this.u_0),i=.5*((r=Math.exp(-this.BrA*n))-1/r),s=.5*(r+1/r),l=((u=Math.sin(this.BrA*e))*this.cosgam+i*this.singam)/s,Math.abs(Math.abs(l)-1)<a.H0)c.x=0,c.y=l<0?-a.sK:a.sK;else{if(c.y=this.E/Math.sqrt((1+l)/(1-l)),c.y=(0,o.A)(this.e,Math.pow(c.y,1/this.B)),c.y===1/0)throw new Error;c.x=-this.rB*Math.atan2(i*this.cosgam-u*this.singam,Math.cos(this.BrA*e))}return c.x+=this.lam0,c}var f=["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Two_Point_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","Oblique_Mercator","omerc"];e.default={init:u,forward:l,inverse:c,names:f}},8181:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(8609),o=n(2556);function a(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function s(t){var e,n,i,a,s,u,l,c=t.x,f=t.y;return i=(0,r.A)(c-this.long0),e=Math.sin(f),n=Math.cos(f),a=Math.cos(i),((s=this.sin_p14*e+this.cos_p14*n*a)>0||Math.abs(s)<=o.H0)&&(u=1*this.a*n*Math.sin(i),l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*n*a)),t.x=u,t.y=l,t}function u(t){var e,n,a,s,u,l,c;return t.x-=this.x0,t.y-=this.y0,e=Math.sqrt(t.x*t.x+t.y*t.y),n=(0,i.A)(e/this.a),a=Math.sin(n),s=Math.cos(n),l=this.long0,Math.abs(e)<=o.H0?(c=this.lat0,t.x=l,t.y=c,t):(c=(0,i.A)(s*this.sin_p14+t.y*a*this.cos_p14/e),u=Math.abs(this.lat0)-o.sK,Math.abs(u)<=o.H0?(l=this.lat0>=0?(0,r.A)(this.long0+Math.atan2(t.x,-t.y)):(0,r.A)(this.long0-Math.atan2(-t.x,t.y)),t.x=l,t.y=c,t):(l=(0,r.A)(this.long0+Math.atan2(t.x*a,e*this.cos_p14*s-t.y*this.sin_p14*a)),t.x=l,t.y=c,t))}var l=["ortho"];e.default={init:a,forward:s,inverse:u,names:l}},2169:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(8193),i=n(9686),o=n(7711),a=n(2060),s=n(737),u=n(5473),l=n(4037),c=n(2556),f=n(7973),h=20;function d(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=(0,r.A)(this.es),this.e1=(0,i.A)(this.es),this.e2=(0,o.A)(this.es),this.e3=(0,a.A)(this.es),this.ml0=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,this.lat0)}function p(t){var e,n,r,i=t.x,o=t.y,a=(0,s.A)(i-this.long0);if(r=a*Math.sin(o),this.sphere)Math.abs(o)<=c.H0?(e=this.a*a,n=-1*this.a*this.lat0):(e=this.a*Math.sin(r)/Math.tan(o),n=this.a*((0,u.A)(o-this.lat0)+(1-Math.cos(r))/Math.tan(o)));else if(Math.abs(o)<=c.H0)e=this.a*a,n=-1*this.ml0;else{var h=(0,f.A)(this.a,this.e,Math.sin(o))/Math.tan(o);e=h*Math.sin(r),n=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,o)-this.ml0+h*(1-Math.cos(r))}return t.x=e+this.x0,t.y=n+this.y0,t}function m(t){var e,n,r,i,o,a,u,f,d;if(r=t.x-this.x0,i=t.y-this.y0,this.sphere)if(Math.abs(i+this.a*this.lat0)<=c.H0)e=(0,s.A)(r/this.a+this.long0),n=0;else{var p;for(a=this.lat0+i/this.a,u=r*r/this.a/this.a+a*a,f=a,o=h;o;--o)if(f+=d=-1*(a*(f*(p=Math.tan(f))+1)-f-.5*(f*f+u)*p)/((f-a)/p-1),Math.abs(d)<=c.H0){n=f;break}e=(0,s.A)(this.long0+Math.asin(r*Math.tan(f)/this.a)/Math.sin(n))}else if(Math.abs(i+this.ml0)<=c.H0)n=0,e=(0,s.A)(this.long0+r/this.a);else{var m,g,y,v,x;for(a=(this.ml0+i)/this.a,u=r*r/this.a/this.a+a*a,f=a,o=h;o;--o)if(x=this.e*Math.sin(f),m=Math.sqrt(1-x*x)*Math.tan(f),g=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,f),y=this.e0-2*this.e1*Math.cos(2*f)+4*this.e2*Math.cos(4*f)-6*this.e3*Math.cos(6*f),f-=d=(a*(m*(v=g/this.a)+1)-v-.5*m*(v*v+u))/(this.es*Math.sin(2*f)*(v*v+u-2*a*v)/(4*m)+(a-v)*(m*y-2/Math.sin(2*f))-y),Math.abs(d)<=c.H0){n=f;break}m=Math.sqrt(1-this.es*Math.pow(Math.sin(n),2))*Math.tan(n),e=(0,s.A)(this.long0+Math.asin(r*m/this.a)/Math.sin(n))}return t.x=e,t.y=n,t}var g=["Polyconic","poly"];e.default={init:d,forward:p,inverse:m,names:g}},5722:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return f}});var r=n(2556),i={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},o={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4};function a(){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.lat0>=r.sK-r.Vj/2?this.face=i.TOP:this.lat0<=-(r.sK-r.Vj/2)?this.face=i.BOTTOM:Math.abs(this.long0)<=r.Vj?this.face=i.FRONT:Math.abs(this.long0)<=r.sK+r.Vj?this.face=this.long0>0?i.RIGHT:i.LEFT:this.face=i.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)}function s(t){var e,n,a,s,u,f,h={x:0,y:0},d={value:0};if(t.x-=this.long0,e=0!==this.es?Math.atan(this.one_minus_f_squared*Math.tan(t.y)):t.y,n=t.x,this.face===i.TOP)s=r.sK-e,n>=r.Vj&&n<=r.sK+r.Vj?(d.value=o.AREA_0,a=n-r.sK):n>r.sK+r.Vj||n<=-(r.sK+r.Vj)?(d.value=o.AREA_1,a=n>0?n-r.DF:n+r.DF):n>-(r.sK+r.Vj)&&n<=-r.Vj?(d.value=o.AREA_2,a=n+r.sK):(d.value=o.AREA_3,a=n);else if(this.face===i.BOTTOM)s=r.sK+e,n>=r.Vj&&n<=r.sK+r.Vj?(d.value=o.AREA_0,a=-n+r.sK):n<r.Vj&&n>=-r.Vj?(d.value=o.AREA_1,a=-n):n<-r.Vj&&n>=-(r.sK+r.Vj)?(d.value=o.AREA_2,a=-n-r.sK):(d.value=o.AREA_3,a=n>0?-n+r.DF:-n-r.DF);else{var p,m,g,y,v,x;this.face===i.RIGHT?n=c(n,+r.sK):this.face===i.BACK?n=c(n,+r.DF):this.face===i.LEFT&&(n=c(n,-r.sK)),y=Math.sin(e),v=Math.cos(e),x=Math.sin(n),p=v*Math.cos(n),m=v*x,g=y,this.face===i.FRONT?a=l(s=Math.acos(p),g,m,d):this.face===i.RIGHT?a=l(s=Math.acos(m),g,-p,d):this.face===i.BACK?a=l(s=Math.acos(-p),g,-m,d):this.face===i.LEFT?a=l(s=Math.acos(-m),g,p,d):(s=a=0,d.value=o.AREA_0)}return f=Math.atan(12/r.DF*(a+Math.acos(Math.sin(a)*Math.cos(r.Vj))-r.sK)),u=Math.sqrt((1-Math.cos(s))/(Math.cos(f)*Math.cos(f))/(1-Math.cos(Math.atan(1/Math.cos(a))))),d.value===o.AREA_1?f+=r.sK:d.value===o.AREA_2?f+=r.DF:d.value===o.AREA_3&&(f+=1.5*r.DF),h.x=u*Math.cos(f),h.y=u*Math.sin(f),h.x=h.x*this.a+this.x0,h.y=h.y*this.a+this.y0,t.x=h.x,t.y=h.y,t}function u(t){var e,n,a,s,u,l,f,h,d,p,m,g,y={lam:0,phi:0},v={value:0};if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,n=Math.atan(Math.sqrt(t.x*t.x+t.y*t.y)),e=Math.atan2(t.y,t.x),t.x>=0&&t.x>=Math.abs(t.y)?v.value=o.AREA_0:t.y>=0&&t.y>=Math.abs(t.x)?(v.value=o.AREA_1,e-=r.sK):t.x<0&&-t.x>=Math.abs(t.y)?(v.value=o.AREA_2,e=e<0?e+r.DF:e-r.DF):(v.value=o.AREA_3,e+=r.sK),d=r.DF/12*Math.tan(e),u=Math.sin(d)/(Math.cos(d)-1/Math.sqrt(2)),l=Math.atan(u),(f=1-(a=Math.cos(e))*a*(s=Math.tan(n))*s*(1-Math.cos(Math.atan(1/Math.cos(l)))))<-1?f=-1:f>1&&(f=1),this.face===i.TOP)h=Math.acos(f),y.phi=r.sK-h,v.value===o.AREA_0?y.lam=l+r.sK:v.value===o.AREA_1?y.lam=l<0?l+r.DF:l-r.DF:v.value===o.AREA_2?y.lam=l-r.sK:y.lam=l;else if(this.face===i.BOTTOM)h=Math.acos(f),y.phi=h-r.sK,v.value===o.AREA_0?y.lam=-l+r.sK:v.value===o.AREA_1?y.lam=-l:v.value===o.AREA_2?y.lam=-l-r.sK:y.lam=l<0?-l-r.DF:-l+r.DF;else{var x,_,b;d=(x=f)*x,_=(d+=(b=d>=1?0:Math.sqrt(1-d)*Math.sin(l))*b)>=1?0:Math.sqrt(1-d),v.value===o.AREA_1?(d=_,_=-b,b=d):v.value===o.AREA_2?(_=-_,b=-b):v.value===o.AREA_3&&(d=_,_=b,b=-d),this.face===i.RIGHT?(d=x,x=-_,_=d):this.face===i.BACK?(x=-x,_=-_):this.face===i.LEFT&&(d=x,x=_,_=-d),y.phi=Math.acos(-b)-r.sK,y.lam=Math.atan2(_,x),this.face===i.RIGHT?y.lam=c(y.lam,-r.sK):this.face===i.BACK?y.lam=c(y.lam,-r.DF):this.face===i.LEFT&&(y.lam=c(y.lam,+r.sK))}0!==this.es&&(p=y.phi<0?1:0,m=Math.tan(y.phi),g=this.b/Math.sqrt(m*m+this.one_minus_f_squared),y.phi=Math.atan(Math.sqrt(this.a*this.a-g*g)/(this.one_minus_f*g)),p&&(y.phi=-y.phi));return y.lam+=this.long0,t.x=y.lam,t.y=y.phi,t}function l(t,e,n,i){var a;return t<r.H0?(i.value=o.AREA_0,a=0):(a=Math.atan2(e,n),Math.abs(a)<=r.Vj?i.value=o.AREA_0:a>r.Vj&&a<=r.sK+r.Vj?(i.value=o.AREA_1,a-=r.sK):a>r.sK+r.Vj||a<=-(r.sK+r.Vj)?(i.value=o.AREA_2,a=a>=0?a-r.DF:a+r.DF):(i.value=o.AREA_3,a+=r.sK)),a}function c(t,e){var n=t+e;return n<-r.DF?n+=r.JM:n>+r.DF&&(n-=r.JM),n}var f=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"];e.default={init:a,forward:s,inverse:u,names:f}},1295:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return m},init:function(){return p},inverse:function(){return g},names:function(){return y}});var r=n(2556),i=n(737),o=[[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]],a=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-1.26793e-9,4.22642e-10],[.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]],s=.8487,u=1.3523,l=r.dX/5,c=1/l,f=18,h=function(t,e){return t[0]+e*(t[1]+e*(t[2]+e*t[3]))},d=function(t,e){return t[1]+e*(2*t[2]+3*e*t[3])};function p(){this.x0=this.x0||0,this.y0=this.y0||0,this.long0=this.long0||0,this.es=0,this.title=this.title||"Robinson"}function m(t){var e=(0,i.A)(t.x-this.long0),n=Math.abs(t.y),d=Math.floor(n*l);d<0?d=0:d>=f&&(d=f-1),n=r.dX*(n-c*d);var p={x:h(o[d],n)*e,y:h(a[d],n)};return t.y<0&&(p.y=-p.y),p.x=p.x*this.a*s+this.x0,p.y=p.y*this.a*u+this.y0,p}function g(t){var e={x:(t.x-this.x0)/(this.a*s),y:Math.abs(t.y-this.y0)/(this.a*u)};if(e.y>=1)e.x/=o[f][0],e.y=t.y<0?-r.sK:r.sK;else{var n=Math.floor(e.y*f);for(n<0?n=0:n>=f&&(n=f-1);;)if(a[n][0]>e.y)--n;else{if(!(a[n+1][0]<=e.y))break;++n}var l=a[n],c=5*(e.y-l[0])/(a[n+1][0]-l[0]);c=function(t,e,n,r){for(var i=e;r;--r){var o=t(i);if(i-=o,Math.abs(o)<n)break}return i}((function(t){return(h(l,t)-e.y)/d(l,t)}),c,r.H0,100),e.x/=h(o[n],c),e.y=(5*n+c)*r.zq,t.y<0&&(e.y=-e.y)}return e.x=(0,i.A)(e.x+this.long0),e}var y=["Robinson","robin"];e.default={init:p,forward:m,inverse:g,names:y}},9006:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return h},init:function(){return f},inverse:function(){return d},names:function(){return p}});var r=n(737),i=n(5473),o=n(6366),a=n(2092),s=n(3220),u=n(2556),l=n(8609),c=20;function f(){this.sphere?(this.n=1,this.m=0,this.es=0,this.C_y=Math.sqrt((this.m+1)/this.n),this.C_x=this.C_y/(this.m+1)):this.en=(0,o.A)(this.es)}function h(t){var e,n,i=t.x,o=t.y;if(i=(0,r.A)(i-this.long0),this.sphere){if(this.m)for(var s=this.n*Math.sin(o),l=c;l;--l){var f=(this.m*o+Math.sin(o)-s)/(this.m+Math.cos(o));if(o-=f,Math.abs(f)<u.H0)break}else o=1!==this.n?Math.asin(this.n*Math.sin(o)):o;e=this.a*this.C_x*i*(this.m+Math.cos(o)),n=this.a*this.C_y*o}else{var h=Math.sin(o),d=Math.cos(o);n=this.a*(0,a.A)(o,h,d,this.en),e=this.a*i*d/Math.sqrt(1-this.es*h*h)}return t.x=e,t.y=n,t}function d(t){var e,n,o,a;return t.x-=this.x0,o=t.x/this.a,t.y-=this.y0,e=t.y/this.a,this.sphere?(e/=this.C_y,o/=this.C_x*(this.m+Math.cos(e)),this.m?e=(0,l.A)((this.m*e+Math.sin(e))/this.n):1!==this.n&&(e=(0,l.A)(Math.sin(e)/this.n)),o=(0,r.A)(o+this.long0),e=(0,i.A)(e)):(e=(0,s.A)(t.y/this.a,this.es,this.en),(a=Math.abs(e))<u.sK?(a=Math.sin(e),n=this.long0+t.x*Math.sqrt(1-this.es*a*a)/(this.a*Math.cos(e)),o=(0,r.A)(n)):a-u.H0<u.sK&&(o=this.long0)),t.x=o,t.y=e,t}var p=["Sinusoidal","sinu"];e.default={init:f,forward:h,inverse:d,names:p}},988:function(t,e,n){"use strict";function r(){var t=this.lat0;this.lambda0=this.long0;var e=Math.sin(t),n=this.a,r=1/this.rf,i=2*r-Math.pow(r,2),o=this.e=Math.sqrt(i);this.R=this.k0*n*Math.sqrt(1-i)/(1-i*Math.pow(e,2)),this.alpha=Math.sqrt(1+i/(1-i)*Math.pow(Math.cos(t),4)),this.b0=Math.asin(e/this.alpha);var a=Math.log(Math.tan(Math.PI/4+this.b0/2)),s=Math.log(Math.tan(Math.PI/4+t/2)),u=Math.log((1+o*e)/(1-o*e));this.K=a-this.alpha*s+this.alpha*o/2*u}function i(t){var e=Math.log(Math.tan(Math.PI/4-t.y/2)),n=this.e/2*Math.log((1+this.e*Math.sin(t.y))/(1-this.e*Math.sin(t.y))),r=-this.alpha*(e+n)+this.K,i=2*(Math.atan(Math.exp(r))-Math.PI/4),o=this.alpha*(t.x-this.lambda0),a=Math.atan(Math.sin(o)/(Math.sin(this.b0)*Math.tan(i)+Math.cos(this.b0)*Math.cos(o))),s=Math.asin(Math.cos(this.b0)*Math.sin(i)-Math.sin(this.b0)*Math.cos(i)*Math.cos(o));return t.y=this.R/2*Math.log((1+Math.sin(s))/(1-Math.sin(s)))+this.y0,t.x=this.R*a+this.x0,t}function o(t){for(var e=t.x-this.x0,n=t.y-this.y0,r=e/this.R,i=2*(Math.atan(Math.exp(n/this.R))-Math.PI/4),o=Math.asin(Math.cos(this.b0)*Math.sin(i)+Math.sin(this.b0)*Math.cos(i)*Math.cos(r)),a=Math.atan(Math.sin(r)/(Math.cos(this.b0)*Math.cos(r)-Math.sin(this.b0)*Math.tan(i))),s=this.lambda0+a/this.alpha,u=0,l=o,c=-1e3,f=0;Math.abs(l-c)>1e-7;){if(++f>20)return;u=1/this.alpha*(Math.log(Math.tan(Math.PI/4+o/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(l))/2)),c=l,l=2*Math.atan(Math.exp(u))-Math.PI/2}return t.x=s,t.y=l,t}n.r(e),n.d(e,{forward:function(){return i},init:function(){return r},inverse:function(){return o},names:function(){return a}});var a=["somerc"];e.default={init:r,forward:i,inverse:o,names:a}},688:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return f},init:function(){return c},inverse:function(){return h},names:function(){return d},ssfn_:function(){return l}});var r=n(2556),i=n(4205),o=n(444),a=n(9967),s=n(1793),u=n(737);function l(t,e,n){return e*=n,Math.tan(.5*(r.sK+t))*Math.pow((1-e)/(1+e),.5*n)}function c(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.coslat0=Math.cos(this.lat0),this.sinlat0=Math.sin(this.lat0),this.sphere?1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=r.H0&&(this.k0=.5*(1+(0,i.A)(this.lat0)*Math.sin(this.lat_ts))):(Math.abs(this.coslat0)<=r.H0&&(this.lat0>0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=r.H0&&Math.abs(Math.cos(this.lat_ts))>r.H0&&(this.k0=.5*this.cons*(0,o.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/(0,a.A)(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=(0,o.A)(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-r.sK,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function f(t){var e,n,i,o,s,l,c=t.x,f=t.y,h=Math.sin(f),d=Math.cos(f),p=(0,u.A)(c-this.long0);return Math.abs(Math.abs(c-this.long0)-Math.PI)<=r.H0&&Math.abs(f+this.lat0)<=r.H0?(t.x=NaN,t.y=NaN,t):this.sphere?(e=2*this.k0/(1+this.sinlat0*h+this.coslat0*d*Math.cos(p)),t.x=this.a*e*d*Math.sin(p)+this.x0,t.y=this.a*e*(this.coslat0*h-this.sinlat0*d*Math.cos(p))+this.y0,t):(n=2*Math.atan(this.ssfn_(f,h,this.e))-r.sK,o=Math.cos(n),i=Math.sin(n),Math.abs(this.coslat0)<=r.H0?(s=(0,a.A)(this.e,f*this.con,this.con*h),l=2*this.a*this.k0*s/this.cons,t.x=this.x0+l*Math.sin(c-this.long0),t.y=this.y0-this.con*l*Math.cos(c-this.long0),t):(Math.abs(this.sinlat0)<r.H0?(e=2*this.a*this.k0/(1+o*Math.cos(p)),t.y=e*i):(e=2*this.a*this.k0*this.ms1/(this.cosX0*(1+this.sinX0*i+this.cosX0*o*Math.cos(p))),t.y=e*(this.cosX0*i-this.sinX0*o*Math.cos(p))+this.y0),t.x=e*o*Math.sin(p)+this.x0,t))}function h(t){var e,n,i,o,a;t.x-=this.x0,t.y-=this.y0;var l=Math.sqrt(t.x*t.x+t.y*t.y);if(this.sphere){var c=2*Math.atan(l/(2*this.a*this.k0));return e=this.long0,n=this.lat0,l<=r.H0?(t.x=e,t.y=n,t):(n=Math.asin(Math.cos(c)*this.sinlat0+t.y*Math.sin(c)*this.coslat0/l),e=Math.abs(this.coslat0)<r.H0?this.lat0>0?(0,u.A)(this.long0+Math.atan2(t.x,-1*t.y)):(0,u.A)(this.long0+Math.atan2(t.x,t.y)):(0,u.A)(this.long0+Math.atan2(t.x*Math.sin(c),l*this.coslat0*Math.cos(c)-t.y*this.sinlat0*Math.sin(c))),t.x=e,t.y=n,t)}if(Math.abs(this.coslat0)<=r.H0){if(l<=r.H0)return n=this.lat0,e=this.long0,t.x=e,t.y=n,t;t.x*=this.con,t.y*=this.con,i=l*this.cons/(2*this.a*this.k0),n=this.con*(0,s.A)(this.e,i),e=this.con*(0,u.A)(this.con*this.long0+Math.atan2(t.x,-1*t.y))}else o=2*Math.atan(l*this.cosX0/(2*this.a*this.k0*this.ms1)),e=this.long0,l<=r.H0?a=this.X0:(a=Math.asin(Math.cos(o)*this.sinX0+t.y*Math.sin(o)*this.cosX0/l),e=(0,u.A)(this.long0+Math.atan2(t.x*Math.sin(o),l*this.cosX0*Math.cos(o)-t.y*this.sinX0*Math.sin(o)))),n=-1*(0,s.A)(this.e,Math.tan(.5*(r.sK+a)));return t.x=e,t.y=n,t}var d=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"];e.default={init:c,forward:f,inverse:h,names:d,ssfn_:l}},865:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(3246),i=n(737),o=n(1708);function a(){r.default.init.apply(this),this.rc&&(this.sinc0=Math.sin(this.phic0),this.cosc0=Math.cos(this.phic0),this.R2=2*this.rc,this.title||(this.title="Oblique Stereographic Alternative"))}function s(t){var e,n,o,a;return t.x=(0,i.A)(t.x-this.long0),r.default.forward.apply(this,[t]),e=Math.sin(t.y),n=Math.cos(t.y),o=Math.cos(t.x),a=this.k0*this.R2/(1+this.sinc0*e+this.cosc0*n*o),t.x=a*n*Math.sin(t.x),t.y=a*(this.cosc0*e-this.sinc0*n*o),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function u(t){var e,n,a,s,u;if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,u=(0,o.A)(t.x,t.y)){var l=2*Math.atan2(u,this.R2);e=Math.sin(l),n=Math.cos(l),s=Math.asin(n*this.sinc0+t.y*e*this.cosc0/u),a=Math.atan2(t.x*e,u*this.cosc0*n-t.y*this.sinc0*e)}else s=this.phic0,a=0;return t.x=a,t.y=s,r.default.inverse.apply(this,[t]),t.x=(0,i.A)(t.x+this.long0),t}var l=["Stereographic_North_Pole","Oblique_Stereographic","sterea","Oblique Stereographic Alternative","Double_Stereographic"];e.default={init:a,forward:s,inverse:u,names:l}},5602:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(6366),i=n(2092),o=n(3220),a=n(737),s=n(2556),u=n(4205);function l(){this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.es&&(this.en=(0,r.A)(this.es),this.ml0=(0,i.A)(this.lat0,Math.sin(this.lat0),Math.cos(this.lat0),this.en))}function c(t){var e,n,r,o=t.x,u=t.y,l=(0,a.A)(o-this.long0),c=Math.sin(u),f=Math.cos(u);if(this.es){var h=f*l,d=Math.pow(h,2),p=this.ep2*Math.pow(f,2),m=Math.pow(p,2),g=Math.abs(f)>s.H0?Math.tan(u):0,y=Math.pow(g,2),v=Math.pow(y,2);e=1-this.es*Math.pow(c,2),h/=Math.sqrt(e);var x=(0,i.A)(u,c,f,this.en);n=this.a*(this.k0*h*(1+d/6*(1-y+p+d/20*(5-18*y+v+14*p-58*y*p+d/42*(61+179*v-v*y-479*y)))))+this.x0,r=this.a*(this.k0*(x-this.ml0+c*l*h/2*(1+d/12*(5-y+9*p+4*m+d/30*(61+v-58*y+270*p-330*y*p+d/56*(1385+543*v-v*y-3111*y))))))+this.y0}else{var _=f*Math.sin(l);if(Math.abs(Math.abs(_)-1)<s.H0)return 93;if(n=.5*this.a*this.k0*Math.log((1+_)/(1-_))+this.x0,r=f*Math.cos(l)/Math.sqrt(1-Math.pow(_,2)),(_=Math.abs(r))>=1){if(_-1>s.H0)return 93;r=0}else r=Math.acos(r);u<0&&(r=-r),r=this.a*this.k0*(r-this.lat0)+this.y0}return t.x=n,t.y=r,t}function f(t){var e,n,r,i,l=(t.x-this.x0)*(1/this.a),c=(t.y-this.y0)*(1/this.a);if(this.es)if(e=this.ml0+c/this.k0,n=(0,o.A)(e,this.es,this.en),Math.abs(n)<s.sK){var f=Math.sin(n),h=Math.cos(n),d=Math.abs(h)>s.H0?Math.tan(n):0,p=this.ep2*Math.pow(h,2),m=Math.pow(p,2),g=Math.pow(d,2),y=Math.pow(g,2);e=1-this.es*Math.pow(f,2);var v=l*Math.sqrt(e)/this.k0,x=Math.pow(v,2);r=n-(e*=d)*x/(1-this.es)*.5*(1-x/12*(5+3*g-9*p*g+p-4*m-x/30*(61+90*g-252*p*g+45*y+46*p-x/56*(1385+3633*g+4095*y+1574*y*g)))),i=(0,a.A)(this.long0+v*(1-x/6*(1+2*g+p-x/20*(5+28*g+24*y+8*p*g+6*p-x/42*(61+662*g+1320*y+720*y*g))))/h)}else r=s.sK*(0,u.A)(c),i=0;else{var _=Math.exp(l/this.k0),b=.5*(_-1/_),w=this.lat0+c/this.k0,M=Math.cos(w);e=Math.sqrt((1-Math.pow(M,2))/(1+Math.pow(b,2))),r=Math.asin(e),c<0&&(r=-r),i=0===b&&0===M?0:(0,a.A)(Math.atan2(b,M)+this.long0)}return t.x=i,t.y=r,t}var h=["Fast_Transverse_Mercator","Fast Transverse Mercator"];e.default={init:l,forward:c,inverse:f,names:h}},7127:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return u},init:function(){return s},inverse:function(){return l},names:function(){return c}});var r=n(2556),i=n(1708),o={N_POLE:0,S_POLE:1,EQUIT:2,OBLIQ:3},a={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};function s(){if(Object.keys(a).forEach(function(t){if(void 0===this[t])this[t]=a[t].def;else{if(a[t].num&&isNaN(this[t]))throw new Error("Invalid parameter value, must be numeric "+t+" = "+this[t]);a[t].num&&(this[t]=parseFloat(this[t]))}a[t].degrees&&(this[t]=this[t]*r.zq)}.bind(this)),Math.abs(Math.abs(this.lat0)-r.sK)<r.H0?this.mode=this.lat0<0?o.S_POLE:o.N_POLE:Math.abs(this.lat0)<r.H0?this.mode=o.EQUIT:(this.mode=o.OBLIQ,this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0)),this.pn1=this.h/this.a,this.pn1<=0||this.pn1>1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var t=this.tilt,e=this.azi;this.cg=Math.cos(e),this.sg=Math.sin(e),this.cw=Math.cos(t),this.sw=Math.sin(t)}function u(t){t.x-=this.long0;var e,n,r,i,a=Math.sin(t.y),s=Math.cos(t.y),u=Math.cos(t.x);switch(this.mode){case o.OBLIQ:n=this.sinph0*a+this.cosph0*s*u;break;case o.EQUIT:n=s*u;break;case o.S_POLE:n=-a;break;case o.N_POLE:n=a}switch(e=(n=this.pn1/(this.p-n))*s*Math.sin(t.x),this.mode){case o.OBLIQ:n*=this.cosph0*a-this.sinph0*s*u;break;case o.EQUIT:n*=a;break;case o.N_POLE:n*=-s*u;break;case o.S_POLE:n*=s*u}return i=1/((r=n*this.cg+e*this.sg)*this.sw*this.h1+this.cw),e=(e*this.cg-n*this.sg)*this.cw*i,n=r*i,t.x=e*this.a,t.y=n*this.a,t}function l(t){t.x/=this.a,t.y/=this.a;var e,n,a,s={x:t.x,y:t.y};a=1/(this.pn1-t.y*this.sw),e=this.pn1*t.x*a,n=this.pn1*t.y*this.cw*a,t.x=e*this.cg+n*this.sg,t.y=n*this.cg-e*this.sg;var u=(0,i.A)(t.x,t.y);if(Math.abs(u)<r.H0)s.x=0,s.y=t.y;else{var l,c;switch(c=1-u*u*this.pfact,c=(this.p-Math.sqrt(c))/(this.pn1/u+u/this.pn1),l=Math.sqrt(1-c*c),this.mode){case o.OBLIQ:s.y=Math.asin(l*this.sinph0+t.y*c*this.cosph0/u),t.y=(l-this.sinph0*Math.sin(s.y))*u,t.x*=c*this.cosph0;break;case o.EQUIT:s.y=Math.asin(t.y*c/u),t.y=l*u,t.x*=c;break;case o.N_POLE:s.y=Math.asin(l),t.y=-t.y;break;case o.S_POLE:s.y=-Math.asin(l)}s.x=Math.atan2(t.x,t.y)}return t.x=s.x+this.long0,t.y=s.y,t}var c=["Tilted_Perspective","tpers"];e.default={init:s,forward:u,inverse:l,names:c}},6748:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return l},dependsOn:function(){return a},init:function(){return s},names:function(){return u}});var r=n(737);var i=n(994),o=n(2556),a="etmerc";function s(){var t=function(t,e){if(void 0===t){if((t=Math.floor(30*((0,r.A)(e)+Math.PI)/Math.PI)+1)<0)return 0;if(t>60)return 60}return t}(this.zone,this.long0);if(void 0===t)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(t)-183)*o.zq,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,i.default.init.apply(this),this.forward=i.default.forward,this.inverse=i.default.inverse}var u=["Universal Transverse Mercator System","utm"],l={init:s,names:u,dependsOn:a}},3211:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(2556),o=n(8609);function a(){this.R=this.a}function s(t){var e,n,a=t.x,s=t.y,u=(0,r.A)(a-this.long0);Math.abs(s)<=i.H0&&(e=this.x0+this.R*u,n=this.y0);var l=(0,o.A)(2*Math.abs(s/Math.PI));(Math.abs(u)<=i.H0||Math.abs(Math.abs(s)-i.sK)<=i.H0)&&(e=this.x0,n=s>=0?this.y0+Math.PI*this.R*Math.tan(.5*l):this.y0+Math.PI*this.R*-Math.tan(.5*l));var c=.5*Math.abs(Math.PI/u-u/Math.PI),f=c*c,h=Math.sin(l),d=Math.cos(l),p=d/(h+d-1),m=p*p,g=p*(2/h-1),y=g*g,v=Math.PI*this.R*(c*(p-y)+Math.sqrt(f*(p-y)*(p-y)-(y+f)*(m-y)))/(y+f);u<0&&(v=-v),e=this.x0+v;var x=f+p;return v=Math.PI*this.R*(g*x-c*Math.sqrt((y+f)*(f+1)-x*x))/(y+f),n=s>=0?this.y0+v:this.y0-v,t.x=e,t.y=n,t}function u(t){var e,n,o,a,s,u,l,c,f,h,d,p;return t.x-=this.x0,t.y-=this.y0,d=Math.PI*this.R,s=(o=t.x/d)*o+(a=t.y/d)*a,d=3*(a*a/(c=-2*(u=-Math.abs(a)*(1+s))+1+2*a*a+s*s)+(2*(l=u-2*a*a+o*o)*l*l/c/c/c-9*u*l/c/c)/27)/(f=(u-l*l/3/c)/c)/(h=2*Math.sqrt(-f/3)),Math.abs(d)>1&&(d=d>=0?1:-1),p=Math.acos(d)/3,n=t.y>=0?(-h*Math.cos(p+Math.PI/3)-l/3/c)*Math.PI:-(-h*Math.cos(p+Math.PI/3)-l/3/c)*Math.PI,e=Math.abs(o)<i.H0?this.long0:(0,r.A)(this.long0+Math.PI*(s-1+Math.sqrt(1+2*(o*o-a*a)+s*s))/2/o),t.x=e,t.y=n,t}var l=["Van_der_Grinten_I","VanDerGrinten","vandg"];e.default={init:a,forward:s,inverse:u,names:l}},9689:function(t,e,n){var r={"./aea.js":5458,"./aeqd.js":8980,"./bonne.js":5789,"./cass.js":529,"./cea.js":4101,"./eqc.js":4256,"./eqdc.js":7968,"./eqearth.js":7129,"./equi.js":3667,"./etmerc.js":994,"./gauss.js":3246,"./geocent.js":4876,"./geos.js":469,"./gnom.js":9462,"./gstmerc.js":7041,"./krovak.js":6507,"./laea.js":7406,"./lcc.js":9269,"./longlat.js":2848,"./merc.js":2286,"./mill.js":5157,"./moll.js":5967,"./nzmg.js":6407,"./omerc.js":7475,"./ortho.js":8181,"./poly.js":2169,"./qsc.js":5722,"./robin.js":1295,"./sinu.js":9006,"./somerc.js":988,"./stere.js":688,"./sterea.js":865,"./tmerc.js":5602,"./tpers.js":7127,"./utm.js":6748,"./vandg.js":3211};function i(t){var e=o(t);return n(e)}function o(t){if(!n.o(r,t)){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}return r[t]}i.keys=function(){return Object.keys(r)},i.resolve=o,t.exports=i,i.id=9689},5685:function(t){t.exports="/* lineFeature fragment shader */\n\n#ifdef GL_ES\n #ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n #else\n precision mediump float;\n #endif\n#endif\nvarying vec4 strokeColorVar;\nvarying vec4 subpos;\nvarying vec4 info;\nvarying vec4 angles;\nuniform float antialiasing;\nuniform float miterLimit;\nuniform float fixedFlags;\n\nvoid main () {\n vec4 color = strokeColorVar;\n float opacity = 1.0;\n int nearMode = int(floor(info.x + 0.5));\n int farMode = int(floor(info.y + 0.5));\n float cosABC = angles.x;\n float sinABC = angles.y;\n float cosBCD = angles.z;\n float sinBCD = angles.w;\n // never render on the opposite side of a miter. This uses a bit of\n // slop, via pow(smoothstep()) instead of step(), since there are\n // precision issues in this calculation. This doesn't wholly solve\n // the precision issue; sometimes pixels are missed or double\n // rendered along the inside seam of a miter.\n if (nearMode >= 4) {\n float dist = cosABC * subpos.x - sinABC * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n discard;\n }\n }\n if (farMode >= 4) {\n float dist = cosBCD * subpos.z - sinBCD * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n discard;\n }\n }\n // butt or square cap\n if ((nearMode == 0 || nearMode == 1) && subpos.x < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.x + subpos.w * float(nearMode)));\n }\n if ((farMode == 0 || farMode == 1) && subpos.z < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.z + subpos.w * float(farMode)));\n }\n // round cap\n if (nearMode == 2 && subpos.x <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n if (farMode == 2 && subpos.z <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n // bevel and clip joins\n if ((nearMode == 5 || nearMode == 7) && subpos.x < antialiasing) {\n float dist = (sinABC * subpos.x + cosABC * subpos.y) * sign(sinABC);\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n float maxDist;\n if (nearMode == 5) maxDist = cosABC * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n if ((farMode == 5 || farMode == 7) && subpos.z < antialiasing) {\n float dist = (sinBCD * subpos.z + cosBCD * subpos.y) * sign(sinBCD);\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n float maxDist;\n if (farMode == 5) maxDist = cosBCD * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n // round join\n if (nearMode == 6 && subpos.x <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y, 2.0))));\n }\n if (farMode == 6 && subpos.z <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y, 2.0))));\n }\n // antialias along main edges\n if (antialiasing > 0.0) {\n if (subpos.y > subpos.w * (1.0 + info.z) - antialiasing) {\n opacity = min(opacity, smoothstep(antialiasing, -antialiasing, subpos.y - subpos.w * (1.0 + info.z)));\n }\n if (subpos.y < subpos.w * (-1.0 + info.z) + antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.y - subpos.w * (-1.0 + info.z)));\n }\n }\n if (opacity == 0.0) {\n discard;\n }\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},9336:function(t){t.exports="/* lineFeature vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute vec3 prev;\nattribute vec3 next;\nattribute vec3 far;\nattribute float flags;\n\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\n\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nuniform float pixelWidth;\nuniform float aspect;\nuniform float miterLimit;\nuniform float antialiasing;\n\nvarying vec4 strokeColorVar;\nvarying vec4 subpos; /* px, py, length - px, width */\nvarying vec4 info; /* near mode, far mode, offset */\nvarying vec4 angles; /* near angle cos, sin, far angle cos, sin */\n\nconst float PI = 3.14159265358979323846264;\n\nvec4 viewCoord(vec3 c) {\n vec4 result = projectionMatrix * modelViewMatrix * vec4(c.xyz, 1.0);\n if (result.w != 0.0) result = result / result.w;\n return result;\n}\n\nfloat atan2(float y, float x) {\n if (x > 0.0) return atan(y / x);\n if (x < 0.0 && y >= 0.0) return atan(y / x) + PI;\n if (x < 0.0) return atan(y / x) - PI;\n return sign(y) * 0.5 * PI;\n}\n\nvoid main(void)\n{\n /* If any vertex has been deliberately set to a negative opacity,\n * skip doing computations on it. */\n if (strokeOpacity < 0.0) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return;\n }\n /* convert coordinates. We have four values, since we need to\n * calculate the angles between the lines formed by prev-pos and\n * pos-next, and between pos-next and next-far, plus know the angle\n * (prev)---(pos)---(next)---(far) => A---B---C---D */\n vec4 A = viewCoord(prev);\n vec4 B = viewCoord(pos);\n vec4 C = viewCoord(next);\n vec4 D = viewCoord(far);\n // calculate line segment vector and angle\n vec2 deltaCB = C.xy - B.xy;\n if (deltaCB == vec2(0.0, 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return;\n }\n float lineLength = length(vec2(deltaCB.x, deltaCB.y / aspect)) / pixelWidth;\n // if lines reverse upon themselves and are not nearly the same length, skip\n // joins. This is a heuristic; the correct method would to be to pass some\n // sort of length of the adjacent line to the fragment renderer and adjust\n // which fragments are rendered, but this is much more complex.\n float abLimit = length(vec2(A.x - B.x, (A.y - B.y) / aspect)) / pixelWidth;\n float dcLimit = length(vec2(D.x - C.x, (D.y - C.y) / aspect)) / pixelWidth;\n if (abLimit >= lineLength - antialiasing - strokeWidth * 0.5 && abLimit <= lineLength + antialiasing + strokeWidth * 0.5) {\n abLimit = 0.0001;\n } else {\n if (abLimit < lineLength) abLimit = lineLength;\n abLimit = (strokeWidth - antialiasing) / (abLimit + antialiasing);\n if (abLimit < 0.0001) abLimit = 0.0001;\n if (abLimit > 0.1) abLimit = 0.1;\n }\n if (dcLimit >= lineLength - antialiasing - strokeWidth * 0.5 && dcLimit <= lineLength + antialiasing + strokeWidth * 0.5) {\n dcLimit = 0.0001;\n } else {\n if (dcLimit < lineLength) dcLimit = lineLength;\n dcLimit = (strokeWidth - antialiasing) / (dcLimit + antialiasing);\n if (dcLimit < 0.0001) dcLimit = 0.0001;\n if (dcLimit > 0.1) dcLimit = 0.1;\n }\n float angleCB = atan2(deltaCB.y, deltaCB.x * aspect);\n // values we need to pass along\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // extract values from our flags field\n int vertex = int(mod(flags, 4.0));\n int nearMode = int(mod(floor(flags / 4.0), 8.0));\n int farMode = int(mod(floor(flags / 32.0), 8.0));\n // we use 11 bits of the flags for the offset, where -1023 to 1023\n // maps to -1 to 1. The 11 bits are a signed value, so simply\n // selecting the bits will result in an unsigned values that may be\n // greater than 1, in which case we have to subtract appropriately.\n float offset = mod(floor(flags / 256.0), 2048.0) / 1023.0;\n if (offset > 1.0) offset -= 2048.0 / 1023.0;\n // by default, offset by the width and don't extend lines. Later,\n // calculate line extensions based on end cap and end join modes\n float yOffset = strokeWidth + antialiasing;\n if (vertex == 0) yOffset *= -1.0;\n yOffset += strokeWidth * offset;\n float xOffset = 0.0;\n // end caps\n if (nearMode == 0) {\n xOffset = antialiasing;\n } else if (nearMode == 1 || nearMode == 2) {\n xOffset = strokeWidth + antialiasing;\n }\n\n // If joining lines, calculate the angles in screen space formed by\n // the near end (A-B-C) and far end (B-C-D), and determine how much\n // space is needed for the particular join.\n // This could be changed: if the lines are not a uniform width and\n // offset, then the functional join angle is not simply half the\n // angle between the two lines, but rather half the angle of the\n // inside edge of the the two lines.\n float cosABC = 1.0, sinABC = 0.0, cosBCD = 1.0, sinBCD = 0.0; // of half angles\n // handle near end\n if (nearMode >= 4) {\n float angleBA = atan2(B.y - A.y, (B.x - A.x) * aspect);\n if (A.xy == B.xy) angleBA = angleCB;\n float angleABC = angleCB - angleBA;\n // ensure angle is in the range [-PI, PI], then take the half angle\n angleABC = (mod(angleABC + 3.0 * PI, 2.0 * PI) - PI) / 2.0;\n cosABC = cos(angleABC); sinABC = sin(angleABC);\n // if this angle is close to flat, pass-through the join\n if (nearMode >= 4 && (cosABC > 0.999999 || cosABC < abLimit)) {\n nearMode = 3;\n }\n // miter, miter-clip\n if (nearMode == 4 || nearMode == 7) {\n if (cosABC < 0.000001 || 1.0 / cosABC > miterLimit) {\n if (nearMode == 4) {\n nearMode = 5;\n } else {\n xOffset = miterLimit * strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing;\n }\n } else {\n // we add an extra 1.0 to the xOffset to make sure that fragment\n // shader is doing the clipping\n xOffset = abs(sinABC / cosABC) * strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing + 1.0;\n nearMode = 4;\n }\n }\n // bevel or round join\n if (nearMode == 5 || nearMode == 6) {\n xOffset = strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing;\n }\n }\n\n // handle far end\n if (farMode >= 4) {\n float angleDC = atan2(D.y - C.y, (D.x - C.x) * aspect);\n if (D.xy == C.xy) angleDC = angleCB;\n float angleBCD = angleDC - angleCB;\n // ensure angle is in the range [-PI, PI], then take the half angle\n angleBCD = (mod(angleBCD + 3.0 * PI, 2.0 * PI) - PI) / 2.0;\n cosBCD = cos(angleBCD); sinBCD = sin(angleBCD);\n // if this angle is close to flat, pass-through the join\n if (farMode >= 4 && (cosBCD > 0.999999 || cosBCD < dcLimit)) {\n farMode = 3;\n }\n // miter, miter-clip\n if (farMode == 4 || farMode == 7) {\n if (cosBCD < 0.000001 || 1.0 / cosBCD > miterLimit) {\n if (farMode == 4) farMode = 5;\n } else {\n farMode = 4;\n }\n }\n }\n\n // compute the location of a vertex to include everything that might\n // need to be rendered\n xOffset *= -1.0;\n gl_Position = vec4(\n B.x + (xOffset * cos(angleCB) - yOffset * sin(angleCB)) * pixelWidth,\n B.y + (xOffset * sin(angleCB) + yOffset * cos(angleCB)) * pixelWidth * aspect,\n B.z, 1.0);\n // store other values needed to determine which pixels to plot.\n if (vertex == 0 || vertex == 1) {\n subpos = vec4(xOffset, yOffset, lineLength - xOffset, strokeWidth);\n info = vec4(float(nearMode), float(farMode), offset, 0.0);\n angles = vec4(cosABC, sinABC, cosBCD, sinBCD);\n } else {\n subpos = vec4(lineLength - xOffset, -yOffset, xOffset, strokeWidth);\n info = vec4(float(farMode), float(nearMode), -offset, 0.0);\n angles = vec4(cosBCD, -sinBCD, cosABC, -sinABC);\n }\n}\n"},1388:function(t){t.exports="/* lineFeature debug fragment shader */\n\n#ifdef GL_ES\n #ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n #else\n precision mediump float;\n #endif\n#endif\nvarying vec4 strokeColorVar;\nvarying vec4 subpos;\nvarying vec4 info;\nvarying vec4 angles;\nuniform float antialiasing;\nuniform float miterLimit;\nuniform float fixedFlags;\n\nvoid main () {\n vec4 color = strokeColorVar;\n bool debug = bool(mod(fixedFlags, 2.0));\n float opacity = 1.0;\n int nearMode = int(floor(info.x + 0.5));\n int farMode = int(floor(info.y + 0.5));\n float cosABC = angles.x;\n float sinABC = angles.y;\n float cosBCD = angles.z;\n float sinBCD = angles.w;\n // never render on the opposite side of a miter. This uses a bit of\n // slop, via pow(smoothstep()) instead of step(), since there are\n // precision issues in this calculation. This doesn't wholly solve\n // the precision issue; sometimes pixels are missed or double\n // rendered along the inside seam of a miter.\n if (nearMode >= 4) {\n float dist = cosABC * subpos.x - sinABC * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n if (debug) {\n color.r = 255.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n }\n if (farMode >= 4) {\n float dist = cosBCD * subpos.z - sinBCD * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n if (debug) {\n color.r = 254.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n }\n // butt or square cap\n if ((nearMode == 0 || nearMode == 1) && subpos.x < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.x + subpos.w * float(nearMode)));\n }\n if ((farMode == 0 || farMode == 1) && subpos.z < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.z + subpos.w * float(farMode)));\n }\n // round cap\n if (nearMode == 2 && subpos.x <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n if (farMode == 2 && subpos.z <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n // bevel and clip joins\n if ((nearMode == 5 || nearMode == 7) && subpos.x < antialiasing) {\n float dist = (sinABC * subpos.x + cosABC * subpos.y) * sign(sinABC);\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n float maxDist;\n if (nearMode == 5) maxDist = cosABC * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n if ((farMode == 5 || farMode == 7) && subpos.z < antialiasing) {\n float dist = (sinBCD * subpos.z + cosBCD * subpos.y) * sign(sinBCD);\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n float maxDist;\n if (farMode == 5) maxDist = cosBCD * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n // round join\n if (nearMode == 6 && subpos.x <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y, 2.0))));\n }\n if (farMode == 6 && subpos.z <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y, 2.0))));\n }\n // antialias along main edges\n if (antialiasing > 0.0) {\n if (subpos.y > subpos.w * (1.0 + info.z) - antialiasing) {\n opacity = min(opacity, smoothstep(antialiasing, -antialiasing, subpos.y - subpos.w * (1.0 + info.z)));\n }\n if (subpos.y < subpos.w * (-1.0 + info.z) + antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.y - subpos.w * (-1.0 + info.z)));\n }\n }\n if (opacity == 0.0) {\n if (debug) {\n color.r = 253.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},9923:function(t){t.exports="/* markerFeature square/triangle fragment shader */\n\n/* markerFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n// the square/triangle shader defines unitVar\nconst int symbolEllipse = 0;\nconst int symbolFlowerBase = 1;\nconst int symbolFlowerMax = 16;\nconst int symbolTriangle = 16;\nconst int symbolStarBase = 17;\nconst int symbolStarMax = 16;\nconst int symbolRectangle = 32;\nconst int symbolCrossBase = 33;\nconst int symbolCrossMax = 16;\nconst int symbolOval = 48;\nconst int symbolJackBase = 49;\nconst int symbolJackMax = 16;\nconst int symbolDrop = 64;\nconst int symbolDropBase = 65;\nconst int symbolDropMax = 16;\nconst int symbolArrow = 80;\nconst int symbolArrowBase = 81;\nconst int symbolArrowMax = 16;\n// Distance to antialias in pixels\nconst float antialiasDist = 1.5;\n\n/* Compute the distance from a point to an arrow defined by the radiusVar and a\n * packed value containing\n * headWidth: ratio to radius (0, 1]\n * headLength: ratio to diameter (0, 1]\n * stemWidth: ratio to headWidth [0, 1]\n * sweep: boolean\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float packed: the packed value.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToArrow(vec2 pos, float value) {\n bool sweep = value < 0.0;\n value = abs(value);\n float pack0 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack1 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack2 = (mod(value, 252.0) - 1.0) / 250.0;\n\n float headWidth = (pack0 > 0.0 ? pack0 : 2.0 / 3.0);\n float headEnd = 1.0 - 2.0 * (pack1 > 0.0 ? pack1 : 1.0 / 2.0);\n float stemWidth = headWidth * (pack2 >= 0.0 ? pack2 : 1.0 / 3.0);\n if (length(vec2(headWidth, headEnd)) > 1.0) {\n vec2 scaledHead = normalize(vec2(headWidth, headEnd));\n headWidth = scaledHead.x;\n headEnd = scaledHead.y;\n }\n float stemEnd = -cos(asin(stemWidth));\n\n headWidth *= radiusVar;\n headEnd *= radiusVar;\n stemWidth *= radiusVar;\n stemEnd *= radiusVar;\n pos.y = abs(pos.y);\n float stemDist = pos.y - stemWidth;\n float stemEndDist = stemEnd - pos.x;\n float B = (radiusVar - headEnd) / headWidth;\n float headDist = (pos.x + B * pos.y - radiusVar) / sqrt(1.0 + B * B);\n float headEndDist;\n if (sweep) {\n B = (radiusVar - headEnd) / 3.0 / headWidth;\n headEndDist = -(pos.x + B * pos.y - (radiusVar + headEnd * 2.0) / 3.0) / sqrt(1.0 + B * B);\n } else {\n headEndDist = headEnd - pos.x;\n }\n headEndDist = min(headEndDist, stemDist);\n return max(max(headDist, headEndDist), stemEndDist);\n}\n\n/* Compute the distance from a point to a drop defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major radii).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToDrop(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float r = radiusVar * ratio;\n float cx = radiusVar - r;\n float rad = distance(pos.xy, vec2(cx, 0.0)) - r;\n if (ratio < 0.5) {\n float x = radiusVar - r - r * r / cx;\n float y = sqrt(r * r - (cx - x) * (cx - x));\n float Bt = (cx - x) / y;\n if ((pos.x + Bt * abs(pos.y) - cx) / sqrt(1.0 + Bt * Bt) < 0.0) {\n float B = -x / y;\n return -(pos.x + B * abs(pos.y)) / sqrt(1.0 + B * B);\n }\n }\n return rad;\n}\n\n/* Compute the distance from a point to the ellipse defined by the radiusVar\n * (the semimajor axis) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the ellipse in pixels. Negative is\n * inside.\n */\nfloat distanceToEllipse(vec2 pos, float ratio) {\n // a and b are the semi-major and semi-minor axes\n // ratio is the between the minor and major axes. If > 1, swap these and\n // rotate 90 degrees.\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n float a = radiusVar, b = abs(radiusVar * ratio);\n if (b > a) {\n pos = vec2(pos.y, -pos.x);\n b = abs(radiusVar / ratio);\n }\n float a2 = a * a, b2 = b * b;\n // compute the distance to the ellipse. See this discussion:\n // https://stackoverflow.com/questions/22959698\n float f = sqrt(a2 - b2),\n // this value will be positive if outside and negative if inside. If\n // we used it directly, the stroke would be too thick along the long\n // edges of the ellipse\n d = (distance(pos, vec2(f, 0.0)) + distance(pos, vec2(-f, 0.0))) * 0.5 - a;\n // if we are outside of the ellipse, accuracy is not important, so return\n // early.\n if (d >= 0.0) {\n return d;\n }\n // work in one quadrant\n pos = abs(pos);\n // t (the angle from center) could start as `atan(pos.y, pos.x)`, but this\n // results in a slower solution near narrow ends\n float t = 0.7;\n float cost = cos(t), sint = sin(t), x = a * cost, y = b * sint;\n vec2 lastxy;\n for (int iter = 0; iter < 10; iter += 1) {\n lastxy = vec2(x, y);\n float ex = (a2 - b2) * pow(cost, 3.0) / a,\n ey = (b2 - a2) * pow(sint, 3.0) / b;\n vec2 r = vec2(x - ex, y - ey),\n q = vec2(pos.x - ex, pos.y - ey);\n float lenr = length(r);\n t += lenr * asin((r.x * q.y - r.y * q.x) / lenr / length(q)) / sqrt(a2 + b2 - x * x - y * y);\n t = clamp(t, 0.0, acos(0.0));\n cost = cos(t);\n sint = sin(t);\n x = a * cost;\n y = b * sint;\n if (distance(lastxy, vec2(x, y)) < 0.05) {\n break;\n }\n }\n return sign(d) * distance(pos, vec2(x, y));\n}\n\n/* Compute the distance from a point to an isosceles triangle.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: length of the base compared to the other sides.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToIsoscelesTriangle(vec2 pos, float ratio) {\n ratio = clamp(abs(ratio), 0.0, 2.0);\n if (ratio == 0.0 || ratio == 2.0) {\n ratio = 1.0;\n }\n float s1, s2, x0, x1, y1;\n if (ratio < sqrt(2.0)) {\n s1 = radiusVar * sqrt(4.0 - ratio * ratio); // length of equal sides\n s2 = s1 * ratio;\n y1 = s2 / 2.0;\n x0 = radiusVar;\n x1 = x0 - sqrt(s1 * s1 - y1 * y1);\n } else {\n s2 = radiusVar * 2.0;\n s1 = s2 / ratio;\n y1 = s2 / 2.0;\n x0 = sqrt(s1 * s1 - y1 * y1);\n x1 = 0.0;\n }\n float B = (x0 - x1) / y1;\n return max(x1 - pos.x, (pos.x + B * abs(pos.y) - x0) / sqrt(1.0 + B * B));\n}\n\n/* Compute the distance from a point to an oval defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major axes). Here an oval\n * is defined as two semicircles connected by straight line segments.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the oval in pixels. Negative is inside.\n */\nfloat distanceToOval(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float minor = radiusVar * ratio;\n float center = radiusVar - minor;\n pos = abs(pos);\n if (pos.x <= center) {\n return pos.y - minor;\n }\n return distance(pos, vec2(center, 0.0)) - minor;\n}\n\n/* Compute the distance from a point to a rectangle defined by the radiusVar\n * (the semidiagonal) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToRectangle(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n vec2 wh = normalize(vec2(1.0, abs(ratio))) * radiusVar;\n vec2 dist = abs(pos) - wh;\n return max(dist.x, dist.y);\n}\n\n/* Based on a repetition value, return a position for rotational symmetry.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * int repetitions: number of repetitions on the cross.\n * Exit: float dist: a point in the primary position.\n */\nvec2 rotationalSymmetry(vec2 pos, int repetitions) {\n float pi = acos(-1.0);\n float limit = pi / float(repetitions);\n float ang = atan(pos.y, pos.x);\n ang = mod(ang + pi * 2.0, limit * 2.0);\n if (ang > limit) {\n ang -= limit * 2.0;\n }\n return vec2(cos(ang), sin(ang)) * length(pos);\n}\n\nvoid markerFeatureFragment(vec2 pos) {\n // rad is a value in pixels from the edge of the symbol where negative is\n // inside the shape\n float rad = length(pos.xy) - radiusVar;\n // never allow points outside of the main radius\n if (rad > 0.0) {\n discard;\n return;\n }\n // apply clockwise rotation\n if (rotationVar != 0.0) {\n float cosr = cos(rotationVar), sinr = sin(rotationVar);\n pos = vec2(pos.x * cosr + pos.y * sinr, -pos.x * sinr + pos.y * cosr);\n }\n\n int symbol = int(floor(symbolVar / 64.0));\n bool isimage = bool(mod(floor(symbolVar / 8.0), 2.0));\n vec4 fillColor, strokeColor;\n float endStep;\n\n float ratio = symbolValueVar;\n // When ratio is 0, it usually gets changed to 1; some shapes could have\n // better defaults\n /* Symbol shapes */\n if (symbol == symbolTriangle) {\n rad = distanceToIsoscelesTriangle(pos, ratio);\n } else if (symbol == symbolRectangle) {\n rad = distanceToRectangle(pos, ratio);\n } else if (symbol == symbolOval) {\n rad = distanceToOval(pos, ratio);\n } else if (symbol == symbolDrop) {\n rad = distanceToDrop(pos, ratio);\n } else if (symbol == symbolArrow) {\n rad = distanceToArrow(pos, ratio);\n } else if (symbol >= symbolCrossBase && symbol <= symbolCrossBase + symbolCrossMax - 2) {\n rad = distanceToRectangle(rotationalSymmetry(pos, symbol - symbolCrossBase + 2), ratio);\n } else if (symbol >= symbolFlowerBase && symbol <= symbolFlowerBase + symbolFlowerMax - 2) {\n rad = distanceToEllipse(rotationalSymmetry(pos, symbol - symbolFlowerBase + 2), ratio);\n } else if (symbol >= symbolStarBase && symbol <= symbolStarBase + symbolStarMax - 2) {\n rad = distanceToIsoscelesTriangle(rotationalSymmetry(pos, symbol - symbolStarBase + 2), ratio);\n } else if (symbol >= symbolJackBase && symbol <= symbolJackBase + symbolJackMax - 2) {\n rad = distanceToOval(rotationalSymmetry(pos, symbol - symbolJackBase + 2), ratio);\n } else if (symbol >= symbolDropBase && symbol <= symbolDropBase + symbolDropMax - 2) {\n rad = distanceToDrop(rotationalSymmetry(pos, symbol - symbolDropBase + 2), ratio);\n } else if (symbol >= symbolArrowBase && symbol <= symbolArrowBase + symbolArrowMax - 2) {\n rad = distanceToArrow(rotationalSymmetry(pos, symbol - symbolArrowBase + 2), ratio);\n } else { // default - circle or ellipse; a value of 0 or 1 is a circle\n if (ratio != 0.0 && ratio != 1.0) {\n rad = distanceToEllipse(pos, ratio);\n }\n }\n\n if (rad >= 0.0) {\n discard;\n return;\n }\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0 || strokeWidthVar <= 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 0.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = -strokeWidthVar;\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0) {\n fillColor = vec4(strokeColorVar.rgb, 0.0);\n } else {\n fillColor = fillColorVar;\n }\n if (rad <= endStep) {\n float step = smoothstep(endStep - antialiasDist, endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\nvarying vec2 unitVar; // distinct for square/triangle\n\nvoid main() {\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n markerFeatureFragment(unitVar);\n}\n"},1202:function(t){t.exports="/* markerFeature square/triangle vertex shader */\n\n/* markerFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\nattribute float symbol; /* contains some bit fields */\nattribute float symbolValue;\nattribute float rotation;\nuniform float zoom;\nuniform float rotationUniform;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\n// non-sprite has other definitions.\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n\nfloat markerFeaturePrep(void)\n{\n // No stroke or fill implies nothing to draw\n if (radius <= 0.0 || (strokeOpacity <= 0.0 && fillOpacity <= 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return 0.0;\n }\n radiusVar = radius;\n strokeWidthVar = strokeWidth;\n int scaleMode = int(mod(symbol, 4.0));\n float strokeOffset = mod(floor(symbol / 16.0), 4.0) - 1.0;\n radiusVar += (strokeOffset + 1.0) / 2.0 * strokeWidthVar;\n if (scaleMode == 1) { // fill\n radiusVar = (radiusVar - strokeWidthVar) * exp2(zoom) + strokeWidthVar;\n } else if (scaleMode == 2) { // stroke\n radiusVar += strokeWidthVar * (exp2(zoom) - 1.0);\n strokeWidthVar *= exp2(zoom);\n } else if (scaleMode == 3) { // all\n radiusVar *= exp2(zoom);\n strokeWidthVar *= exp2(zoom);\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n symbolVar = symbol;\n symbolValueVar = symbolValue;\n rotationVar = rotation;\n if (bool(mod(floor(symbolVar / 4.0), 2.0))) {\n rotationVar += rotationUniform;\n }\n return radiusVar;\n}\n\n\nuniform float pixelWidth; // for non-sprite\nuniform float aspect; // for non-sprite\nattribute vec2 unit; // for non-sprite\nvarying vec2 unitVar; // for non-sprite\n\nvoid main(void)\n{\n radiusVar = markerFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for non-sprite\n unitVar = unit * radiusVar;\n unitVar.y *= -1.0;\n vec4 p = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n if (p.w != 0.0) {\n p = p / p.w;\n }\n p += radiusVar * vec4(unit.x * pixelWidth, unit.y * pixelWidth * aspect, 0.0, 1.0);\n gl_Position = vec4(p.xyz, 1.0);\n}\n"},3724:function(t){t.exports="/* markerFeature sprite fragment shader */\n\n/* markerFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n// the square/triangle shader defines unitVar\nconst int symbolEllipse = 0;\nconst int symbolFlowerBase = 1;\nconst int symbolFlowerMax = 16;\nconst int symbolTriangle = 16;\nconst int symbolStarBase = 17;\nconst int symbolStarMax = 16;\nconst int symbolRectangle = 32;\nconst int symbolCrossBase = 33;\nconst int symbolCrossMax = 16;\nconst int symbolOval = 48;\nconst int symbolJackBase = 49;\nconst int symbolJackMax = 16;\nconst int symbolDrop = 64;\nconst int symbolDropBase = 65;\nconst int symbolDropMax = 16;\nconst int symbolArrow = 80;\nconst int symbolArrowBase = 81;\nconst int symbolArrowMax = 16;\n// Distance to antialias in pixels\nconst float antialiasDist = 1.5;\n\n/* Compute the distance from a point to an arrow defined by the radiusVar and a\n * packed value containing\n * headWidth: ratio to radius (0, 1]\n * headLength: ratio to diameter (0, 1]\n * stemWidth: ratio to headWidth [0, 1]\n * sweep: boolean\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float packed: the packed value.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToArrow(vec2 pos, float value) {\n bool sweep = value < 0.0;\n value = abs(value);\n float pack0 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack1 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack2 = (mod(value, 252.0) - 1.0) / 250.0;\n\n float headWidth = (pack0 > 0.0 ? pack0 : 2.0 / 3.0);\n float headEnd = 1.0 - 2.0 * (pack1 > 0.0 ? pack1 : 1.0 / 2.0);\n float stemWidth = headWidth * (pack2 >= 0.0 ? pack2 : 1.0 / 3.0);\n if (length(vec2(headWidth, headEnd)) > 1.0) {\n vec2 scaledHead = normalize(vec2(headWidth, headEnd));\n headWidth = scaledHead.x;\n headEnd = scaledHead.y;\n }\n float stemEnd = -cos(asin(stemWidth));\n\n headWidth *= radiusVar;\n headEnd *= radiusVar;\n stemWidth *= radiusVar;\n stemEnd *= radiusVar;\n pos.y = abs(pos.y);\n float stemDist = pos.y - stemWidth;\n float stemEndDist = stemEnd - pos.x;\n float B = (radiusVar - headEnd) / headWidth;\n float headDist = (pos.x + B * pos.y - radiusVar) / sqrt(1.0 + B * B);\n float headEndDist;\n if (sweep) {\n B = (radiusVar - headEnd) / 3.0 / headWidth;\n headEndDist = -(pos.x + B * pos.y - (radiusVar + headEnd * 2.0) / 3.0) / sqrt(1.0 + B * B);\n } else {\n headEndDist = headEnd - pos.x;\n }\n headEndDist = min(headEndDist, stemDist);\n return max(max(headDist, headEndDist), stemEndDist);\n}\n\n/* Compute the distance from a point to a drop defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major radii).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToDrop(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float r = radiusVar * ratio;\n float cx = radiusVar - r;\n float rad = distance(pos.xy, vec2(cx, 0.0)) - r;\n if (ratio < 0.5) {\n float x = radiusVar - r - r * r / cx;\n float y = sqrt(r * r - (cx - x) * (cx - x));\n float Bt = (cx - x) / y;\n if ((pos.x + Bt * abs(pos.y) - cx) / sqrt(1.0 + Bt * Bt) < 0.0) {\n float B = -x / y;\n return -(pos.x + B * abs(pos.y)) / sqrt(1.0 + B * B);\n }\n }\n return rad;\n}\n\n/* Compute the distance from a point to the ellipse defined by the radiusVar\n * (the semimajor axis) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the ellipse in pixels. Negative is\n * inside.\n */\nfloat distanceToEllipse(vec2 pos, float ratio) {\n // a and b are the semi-major and semi-minor axes\n // ratio is the between the minor and major axes. If > 1, swap these and\n // rotate 90 degrees.\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n float a = radiusVar, b = abs(radiusVar * ratio);\n if (b > a) {\n pos = vec2(pos.y, -pos.x);\n b = abs(radiusVar / ratio);\n }\n float a2 = a * a, b2 = b * b;\n // compute the distance to the ellipse. See this discussion:\n // https://stackoverflow.com/questions/22959698\n float f = sqrt(a2 - b2),\n // this value will be positive if outside and negative if inside. If\n // we used it directly, the stroke would be too thick along the long\n // edges of the ellipse\n d = (distance(pos, vec2(f, 0.0)) + distance(pos, vec2(-f, 0.0))) * 0.5 - a;\n // if we are outside of the ellipse, accuracy is not important, so return\n // early.\n if (d >= 0.0) {\n return d;\n }\n // work in one quadrant\n pos = abs(pos);\n // t (the angle from center) could start as `atan(pos.y, pos.x)`, but this\n // results in a slower solution near narrow ends\n float t = 0.7;\n float cost = cos(t), sint = sin(t), x = a * cost, y = b * sint;\n vec2 lastxy;\n for (int iter = 0; iter < 10; iter += 1) {\n lastxy = vec2(x, y);\n float ex = (a2 - b2) * pow(cost, 3.0) / a,\n ey = (b2 - a2) * pow(sint, 3.0) / b;\n vec2 r = vec2(x - ex, y - ey),\n q = vec2(pos.x - ex, pos.y - ey);\n float lenr = length(r);\n t += lenr * asin((r.x * q.y - r.y * q.x) / lenr / length(q)) / sqrt(a2 + b2 - x * x - y * y);\n t = clamp(t, 0.0, acos(0.0));\n cost = cos(t);\n sint = sin(t);\n x = a * cost;\n y = b * sint;\n if (distance(lastxy, vec2(x, y)) < 0.05) {\n break;\n }\n }\n return sign(d) * distance(pos, vec2(x, y));\n}\n\n/* Compute the distance from a point to an isosceles triangle.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: length of the base compared to the other sides.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToIsoscelesTriangle(vec2 pos, float ratio) {\n ratio = clamp(abs(ratio), 0.0, 2.0);\n if (ratio == 0.0 || ratio == 2.0) {\n ratio = 1.0;\n }\n float s1, s2, x0, x1, y1;\n if (ratio < sqrt(2.0)) {\n s1 = radiusVar * sqrt(4.0 - ratio * ratio); // length of equal sides\n s2 = s1 * ratio;\n y1 = s2 / 2.0;\n x0 = radiusVar;\n x1 = x0 - sqrt(s1 * s1 - y1 * y1);\n } else {\n s2 = radiusVar * 2.0;\n s1 = s2 / ratio;\n y1 = s2 / 2.0;\n x0 = sqrt(s1 * s1 - y1 * y1);\n x1 = 0.0;\n }\n float B = (x0 - x1) / y1;\n return max(x1 - pos.x, (pos.x + B * abs(pos.y) - x0) / sqrt(1.0 + B * B));\n}\n\n/* Compute the distance from a point to an oval defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major axes). Here an oval\n * is defined as two semicircles connected by straight line segments.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the oval in pixels. Negative is inside.\n */\nfloat distanceToOval(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float minor = radiusVar * ratio;\n float center = radiusVar - minor;\n pos = abs(pos);\n if (pos.x <= center) {\n return pos.y - minor;\n }\n return distance(pos, vec2(center, 0.0)) - minor;\n}\n\n/* Compute the distance from a point to a rectangle defined by the radiusVar\n * (the semidiagonal) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToRectangle(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n vec2 wh = normalize(vec2(1.0, abs(ratio))) * radiusVar;\n vec2 dist = abs(pos) - wh;\n return max(dist.x, dist.y);\n}\n\n/* Based on a repetition value, return a position for rotational symmetry.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * int repetitions: number of repetitions on the cross.\n * Exit: float dist: a point in the primary position.\n */\nvec2 rotationalSymmetry(vec2 pos, int repetitions) {\n float pi = acos(-1.0);\n float limit = pi / float(repetitions);\n float ang = atan(pos.y, pos.x);\n ang = mod(ang + pi * 2.0, limit * 2.0);\n if (ang > limit) {\n ang -= limit * 2.0;\n }\n return vec2(cos(ang), sin(ang)) * length(pos);\n}\n\nvoid markerFeatureFragment(vec2 pos) {\n // rad is a value in pixels from the edge of the symbol where negative is\n // inside the shape\n float rad = length(pos.xy) - radiusVar;\n // never allow points outside of the main radius\n if (rad > 0.0) {\n discard;\n return;\n }\n // apply clockwise rotation\n if (rotationVar != 0.0) {\n float cosr = cos(rotationVar), sinr = sin(rotationVar);\n pos = vec2(pos.x * cosr + pos.y * sinr, -pos.x * sinr + pos.y * cosr);\n }\n\n int symbol = int(floor(symbolVar / 64.0));\n bool isimage = bool(mod(floor(symbolVar / 8.0), 2.0));\n vec4 fillColor, strokeColor;\n float endStep;\n\n float ratio = symbolValueVar;\n // When ratio is 0, it usually gets changed to 1; some shapes could have\n // better defaults\n /* Symbol shapes */\n if (symbol == symbolTriangle) {\n rad = distanceToIsoscelesTriangle(pos, ratio);\n } else if (symbol == symbolRectangle) {\n rad = distanceToRectangle(pos, ratio);\n } else if (symbol == symbolOval) {\n rad = distanceToOval(pos, ratio);\n } else if (symbol == symbolDrop) {\n rad = distanceToDrop(pos, ratio);\n } else if (symbol == symbolArrow) {\n rad = distanceToArrow(pos, ratio);\n } else if (symbol >= symbolCrossBase && symbol <= symbolCrossBase + symbolCrossMax - 2) {\n rad = distanceToRectangle(rotationalSymmetry(pos, symbol - symbolCrossBase + 2), ratio);\n } else if (symbol >= symbolFlowerBase && symbol <= symbolFlowerBase + symbolFlowerMax - 2) {\n rad = distanceToEllipse(rotationalSymmetry(pos, symbol - symbolFlowerBase + 2), ratio);\n } else if (symbol >= symbolStarBase && symbol <= symbolStarBase + symbolStarMax - 2) {\n rad = distanceToIsoscelesTriangle(rotationalSymmetry(pos, symbol - symbolStarBase + 2), ratio);\n } else if (symbol >= symbolJackBase && symbol <= symbolJackBase + symbolJackMax - 2) {\n rad = distanceToOval(rotationalSymmetry(pos, symbol - symbolJackBase + 2), ratio);\n } else if (symbol >= symbolDropBase && symbol <= symbolDropBase + symbolDropMax - 2) {\n rad = distanceToDrop(rotationalSymmetry(pos, symbol - symbolDropBase + 2), ratio);\n } else if (symbol >= symbolArrowBase && symbol <= symbolArrowBase + symbolArrowMax - 2) {\n rad = distanceToArrow(rotationalSymmetry(pos, symbol - symbolArrowBase + 2), ratio);\n } else { // default - circle or ellipse; a value of 0 or 1 is a circle\n if (ratio != 0.0 && ratio != 1.0) {\n rad = distanceToEllipse(pos, ratio);\n }\n }\n\n if (rad >= 0.0) {\n discard;\n return;\n }\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0 || strokeWidthVar <= 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 0.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = -strokeWidthVar;\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0) {\n fillColor = vec4(strokeColorVar.rgb, 0.0);\n } else {\n fillColor = fillColorVar;\n }\n if (rad <= endStep) {\n float step = smoothstep(endStep - antialiasDist, endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\n// the square/triangle shader defines unitVar\n\nvoid main(void) {\n // No stroke or fill implies nothing to draw\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n // for sprites, convert the position to [-radius,radius],[-radius,radius]\n vec2 pos = (gl_PointCoord.xy - 0.5) * 2.0 * radiusVar;\n markerFeatureFragment(pos);\n}\n"},7665:function(t){t.exports="/* markerFeature sprite vertex shader */\n\n/* markerFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\nattribute float symbol; /* contains some bit fields */\nattribute float symbolValue;\nattribute float rotation;\nuniform float zoom;\nuniform float rotationUniform;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\n// non-sprite has other definitions.\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n\nfloat markerFeaturePrep(void)\n{\n // No stroke or fill implies nothing to draw\n if (radius <= 0.0 || (strokeOpacity <= 0.0 && fillOpacity <= 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return 0.0;\n }\n radiusVar = radius;\n strokeWidthVar = strokeWidth;\n int scaleMode = int(mod(symbol, 4.0));\n float strokeOffset = mod(floor(symbol / 16.0), 4.0) - 1.0;\n radiusVar += (strokeOffset + 1.0) / 2.0 * strokeWidthVar;\n if (scaleMode == 1) { // fill\n radiusVar = (radiusVar - strokeWidthVar) * exp2(zoom) + strokeWidthVar;\n } else if (scaleMode == 2) { // stroke\n radiusVar += strokeWidthVar * (exp2(zoom) - 1.0);\n strokeWidthVar *= exp2(zoom);\n } else if (scaleMode == 3) { // all\n radiusVar *= exp2(zoom);\n strokeWidthVar *= exp2(zoom);\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n symbolVar = symbol;\n symbolValueVar = symbolValue;\n rotationVar = rotation;\n if (bool(mod(floor(symbolVar / 4.0), 2.0))) {\n rotationVar += rotationUniform;\n }\n return radiusVar;\n}\n\n\nvoid main(void)\n{\n radiusVar = markerFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for sprite\n gl_Position = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n gl_PointSize = 2.0 * radiusVar;\n}\n"},428:function(t){t.exports="/* contourFeature fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nuniform vec4 minColor;\nuniform vec4 maxColor;\nuniform float steps;\nuniform bool stepped;\nuniform sampler2D sampler2d;\nvarying float valueVar;\nvarying float opacityVar;\n\nvoid main () {\n vec4 clr;\n if (valueVar < 0.0) {\n clr = minColor;\n } else if (valueVar > steps) {\n clr = maxColor;\n } else {\n float step;\n if (stepped) {\n step = floor(valueVar) + 0.5;\n if (step > steps) {\n step = steps - 0.5;\n }\n } else {\n step = valueVar + 0.5;\n }\n // our texture is padded on either end by a repeated value to ensure\n // we interpolate smoothly at the ends.\n clr = texture2D(sampler2d, vec2((step + 1.0) / (steps + 2.0), 0.0));\n }\n gl_FragColor = vec4(clr.rgb, clr.a * opacityVar);\n}\n"},4993:function(t){t.exports="/* contourFeature vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float value;\nattribute float opacity;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying float valueVar;\nvarying float opacityVar;\n\nvoid main(void)\n{\n /* Don't use z values */\n vec4 scrPos = projectionMatrix * modelViewMatrix * vec4(pos.xy, 0, 1);\n if (scrPos.w != 0.0) {\n scrPos = scrPos / scrPos.w;\n }\n valueVar = value;\n opacityVar = opacity;\n gl_Position = scrPos;\n}\n"},3925:function(t){t.exports="/* pixelmapFeature fragment shader */\n\nvarying highp vec2 iTextureCoord;\nuniform sampler2D sampler2d;\nuniform sampler2D lutSampler;\nuniform int lutWidth;\nuniform int lutHeight;\nuniform mediump float opacity;\nuniform highp vec2 crop;\n\nvoid main(void) {\n if ((crop.s < 1.0 && iTextureCoord.s > crop.s) || (crop.t < 1.0 && 1.0 - iTextureCoord.t > crop.t)) {\n discard;\n }\n // to add anti-aliasing, we would need to know the current pixel size\n // (probably computed in the vertex shader) and then sample the base image at\n // multiple points, then average the output color.\n highp vec4 lutValue = texture2D(sampler2d, iTextureCoord);\n highp vec2 lutCoord;\n lutCoord.s = (\n mod(\n // add 0.5 to handle float imprecision\n floor(lutValue.r * 255.0 + 0.5) +\n floor(lutValue.g * 255.0 + 0.5) * 256.0,\n float(lutWidth)\n // center in pixel\n ) + 0.5) / float(lutWidth);\n // Our image is top-down, so invert the coordinate\n lutCoord.t = 1.0 - (\n floor(\n (\n // add 0.5 to handle float imprecision\n floor(lutValue.r * 255.0 + 0.5) +\n floor(lutValue.g * 255.0 + 0.5) * 256.0 +\n floor(lutValue.b * 255.0 + 0.5) * 256.0 * 256.0\n // We may want an option to use the alpha channel to allow more indices\n ) / float(lutWidth)\n // center in pixel\n ) + 0.5) / float(lutHeight);\n if (lutCoord.t < 0.0) {\n discard;\n }\n mediump vec4 color = texture2D(lutSampler, lutCoord);\n\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},4317:function(t){t.exports="/* pointFeature square/triangle fragment shader */\n\n/* pointFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nvoid pointFeatureFragment(float rad) {\n vec4 strokeColor, fillColor;\n float endStep;\n // No stroke or fill implies nothing to draw\n if (rad > 1.0)\n discard;\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 1.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = radiusVar / (radiusVar + strokeWidthVar);\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0)\n fillColor = vec4(strokeColor.rgb, 0.0);\n else\n fillColor = fillColorVar;\n // Distance to antialias over. First number is in pixels\n float antialiasDist = 1.5 / (radiusVar + strokeWidthVar);\n if (rad < endStep) {\n float step = smoothstep(max(0.0, endStep - antialiasDist), endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\nvarying vec3 unitVar; // distinct for square/triangle\n\nvoid main () {\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n float rad = length(unitVar.xy); // distinct for square/triangle\n pointFeatureFragment(rad);\n}\n"},8208:function(t){t.exports="/* pointFeature square/triangle vertex shader */\n\n/* pointFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute vec3 strokeColor;\nattribute float fillOpacity;\nattribute float strokeWidth;\nattribute float strokeOpacity;\nattribute float fill;\nattribute float stroke;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nfloat pointFeaturePrep() {\n strokeWidthVar = strokeWidth;\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // No stroke or fill implies nothing to draw\n if (stroke < 1.0 || strokeWidth <= 0.0 || strokeOpacity <= 0.0) {\n strokeColorVar.a = 0.0;\n strokeWidthVar = 0.0;\n }\n if (fill < 1.0 || radius <= 0.0 || fillOpacity <= 0.0)\n fillColorVar.a = 0.0;\n /* If the point has no visible pixels, skip doing computations on it. */\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0) {\n gl_Position = vec4(2, 2, 0, 1);\n return 0.0;\n }\n return radius;\n}\n\n\nuniform float pixelWidth; // for non-sprite\nuniform float aspect; // for non-sprite\nattribute vec2 unit; // for non-sprite\nvarying vec3 unitVar; // for non-sprite\n\nvoid main(void)\n{\n radiusVar = pointFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for non-sprite\n unitVar = vec3(unit, 1.0);\n vec4 p = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n if (p.w != 0.0) {\n p = p / p.w;\n }\n p += (radius + strokeWidthVar) *\n vec4(unit.x * pixelWidth, unit.y * pixelWidth * aspect, 0.0, 1.0);\n gl_Position = vec4(p.xyz, 1.0);\n}\n"},2682:function(t){t.exports="/* pointFeature sprite fragment shader */\n\n/* pointFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nvoid pointFeatureFragment(float rad) {\n vec4 strokeColor, fillColor;\n float endStep;\n // No stroke or fill implies nothing to draw\n if (rad > 1.0)\n discard;\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 1.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = radiusVar / (radiusVar + strokeWidthVar);\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0)\n fillColor = vec4(strokeColor.rgb, 0.0);\n else\n fillColor = fillColorVar;\n // Distance to antialias over. First number is in pixels\n float antialiasDist = 1.5 / (radiusVar + strokeWidthVar);\n if (rad < endStep) {\n float step = smoothstep(max(0.0, endStep - antialiasDist), endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\n// the square/triangle shader defines unitVar\n\nvoid main () {\n // No stroke or fill implies nothing to draw\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n float rad = 2.0 * length(gl_PointCoord - vec2(0.5)); // distinct for sprite\n pointFeatureFragment(rad);\n}\n"},6979:function(t){t.exports="/* pointFeature sprite vertex shader */\n\n/* pointFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute vec3 strokeColor;\nattribute float fillOpacity;\nattribute float strokeWidth;\nattribute float strokeOpacity;\nattribute float fill;\nattribute float stroke;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nfloat pointFeaturePrep() {\n strokeWidthVar = strokeWidth;\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // No stroke or fill implies nothing to draw\n if (stroke < 1.0 || strokeWidth <= 0.0 || strokeOpacity <= 0.0) {\n strokeColorVar.a = 0.0;\n strokeWidthVar = 0.0;\n }\n if (fill < 1.0 || radius <= 0.0 || fillOpacity <= 0.0)\n fillColorVar.a = 0.0;\n /* If the point has no visible pixels, skip doing computations on it. */\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0) {\n gl_Position = vec4(2, 2, 0, 1);\n return 0.0;\n }\n return radius;\n}\n\n\nvoid main(void)\n{\n radiusVar = pointFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for sprite\n gl_Position = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n gl_PointSize = 2.0 * (radius + strokeWidthVar);\n}\n"},4547:function(t){t.exports="/* polygonFeature fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\n\nvoid main () {\n gl_FragColor = fillColorVar;\n}\n"},9506:function(t){t.exports="/* polygonFeature vertex shader */\n\nattribute vec3 pos;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\n\nvoid main(void)\n{\n vec4 clipPos = projectionMatrix * modelViewMatrix * vec4(pos.xyz, 1.0);\n if (clipPos.w != 0.0) {\n clipPos = clipPos/clipPos.w;\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n gl_Position = clipPos;\n}\n"},8961:function(t){t.exports="/* quadFeature Color fragment shader */\n\nvarying mediump vec3 iVertexColor;\nuniform mediump float opacity;\n\nvoid main(void) {\n gl_FragColor = vec4(iVertexColor, opacity);\n}\n"},3260:function(t){t.exports="/* quadFeature Color vertex shader */\n\nattribute vec3 vertexPosition;\nuniform float zOffset;\nuniform vec3 vertexColor;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying mediump vec3 iVertexColor;\n\nvoid main(void) {\n gl_Position = projectionMatrix * modelViewMatrix * vec4(vertexPosition, 1.0);\n gl_Position.z += zOffset;\n iVertexColor = vertexColor;\n}\n"},8711:function(t){t.exports="/* quadFeature Image fragment shader */\n\nvarying highp vec2 iTextureCoord;\nuniform sampler2D sampler2d;\nuniform mediump float opacity;\nuniform highp vec2 crop;\n\nvoid main(void) {\n mediump vec4 color = texture2D(sampler2d, iTextureCoord);\n if ((crop.s < 1.0 && iTextureCoord.s > crop.s) || (crop.t < 1.0 && 1.0 - iTextureCoord.t > crop.t)) {\n discard;\n }\n color.w *= opacity;\n gl_FragColor = color;\n}\n"},6238:function(t){t.exports="/* quadFeature Image vertex shader */\n\nattribute vec3 vertexPosition;\nattribute vec2 textureCoord;\nuniform float zOffset;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying highp vec2 iTextureCoord;\nuniform highp vec4 cropsource;\n\nvoid main(void) {\n gl_Position = projectionMatrix * modelViewMatrix * vec4(vertexPosition, 1.0);\n gl_Position.z += zOffset;\n if (cropsource.p > cropsource.s && cropsource.q > cropsource.t && (cropsource.p < 1.0 || cropsource.s > 0.0 || cropsource.q < 1.0 || cropsource.t > 0.0)) {\n iTextureCoord.s = textureCoord.s * (cropsource.p - cropsource.s) + cropsource.s;\n iTextureCoord.t = textureCoord.t * (cropsource.q - cropsource.t) + cropsource.t;\n } else {\n iTextureCoord = textureCoord;\n }\n}\n"},7605:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(632),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},1159:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(7046),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},615:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(5290),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},5292:function(t){"use strict";var e=[];function n(t){for(var n=-1,r=0;r<e.length;r++)if(e[r].identifier===t){n=r;break}return n}function r(t,r){for(var o={},a=[],s=0;s<t.length;s++){var u=t[s],l=r.base?u[0]+r.base:u[0],c=o[l]||0,f="".concat(l," ").concat(c);o[l]=c+1;var h=n(f),d={css:u[1],media:u[2],sourceMap:u[3],supports:u[4],layer:u[5]};if(-1!==h)e[h].references++,e[h].updater(d);else{var p=i(d,r);r.byIndex=s,e.splice(s,0,{identifier:f,updater:p,references:1})}a.push(f)}return a}function i(t,e){var n=e.domAPI(e);n.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;n.update(t=e)}else n.remove()}}t.exports=function(t,i){var o=r(t=t||[],i=i||{});return function(t){t=t||[];for(var a=0;a<o.length;a++){var s=n(o[a]);e[s].references--}for(var u=r(t,i),l=0;l<o.length;l++){var c=n(o[l]);0===e[c].references&&(e[c].updater(),e.splice(c,1))}o=u}}},9383:function(t){"use strict";var e={};t.exports=function(t,n){var r=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9088:function(t){"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},6884:function(t,e,n){"use strict";t.exports=function(t){var e=n.nc;e&&t.setAttribute("nonce",e)}},9893:function(t){"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(n){!function(t,e,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,i&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),e.styleTagTransform(r,t,e.options)}(e,t,n)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},7997:function(t){"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},5245:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwyN2w4LDBsMCwybC04LDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},8546:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwyN2wzLDBsMCwtM2wyLDBsMCwzbDMsMGwwLDJsLTMsMGwwLDNsLTIsMGwwLC0zbC0zLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},3158:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwzMmwwLC00YTQsNCwwLDAsMSw4LDBsMCw0bC0yLDBsMCwtNGEyLDIsMCwwLDAsLTQsMGwwLDR6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},9803:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0zMiwzMC41OWwtMS40MSwxLjQxbC0yLjEyLC0yLjEybC0yLjEyLDIuMTJsLTEuNDEsLTEuNDFsMi4xMiwtMi4xMmwtMi4xMiwtMi4xMmwxLjQxLC0xLjQxbDIuMTIsMi4xMmwyLjEyLC0yLjEybDEuNDEsMS40MWwtMi4xMiwyLjEyeiIgZmlsbD0iYmxhY2siIHN0cm9rZS13aWR0aD0iMCIvPgo8L3N2Zz4K"},4436:function(e){"use strict";if(void 0===t){var n=new Error("Cannot find module 'vtk.js'");throw n.code="MODULE_NOT_FOUND",n}e.exports=t},9747:function(t,e,n){"use strict";function r(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return i(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function o(t,e){var n,r,i,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:2,s=e&&e.length,l=s?e[0]*o:t.length,c=a(t,0,l,o,!0),f=[];if(!c||c.next===c.prev)return f;if(s&&(c=function(t,e,n,r){for(var i=[],o=0,s=e.length;o<s;o++){var u=a(t,e[o]*r,o<s-1?e[o+1]*r:t.length,r,!1);u===u.next&&(u.steiner=!0),i.push(y(u))}i.sort(d);for(var l=0;l<i.length;l++)n=p(i[l],n);return n}(t,e,c,o)),t.length>80*o){n=1/0,r=1/0;for(var h=-1/0,m=-1/0,g=o;g<l;g+=o){var v=t[g],x=t[g+1];v<n&&(n=v),x<r&&(r=x),v>h&&(h=v),x>m&&(m=x)}i=0!==(i=Math.max(h-n,m-r))?32767/i:0}return u(c,f,o,n,r,i,0),f}function a(t,e,n,r,i){var o;if(i===P(t,e,n,r)>0)for(var a=e;a<n;a+=r)o=C(a/r|0,t[a],t[a+1],o);else for(var s=n-r;s>=e;s-=r)o=C(s/r|0,t[s],t[s+1],o);return o&&b(o,o.next)&&(k(o),o=o.next),o}function s(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!b(r,r.next)&&0!==_(r.prev,r,r.next))r=r.next;else{if(k(r),(r=e=r.prev)===r.next)break;n=!0}}while(n||r!==e);return e}function u(t,e,n,r,i,o,a){if(t){!a&&o&&function(t,e,n,r){var i=t;do{0===i.z&&(i.z=g(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,n=1;do{var r=t,i=void 0;t=null;var o=null;for(e=0;r;){e++;for(var a=r,s=0,u=0;u<n&&(s++,a=a.nextZ);u++);for(var l=n;s>0||l>0&&a;)0!==s&&(0===l||!a||r.z<=a.z)?(i=r,r=r.nextZ,s--):(i=a,a=a.nextZ,l--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;r=a}o.nextZ=null,n*=2}while(e>1)}(i)}(t,r,i,o);for(var d=t;t.prev!==t.next;){var p=t.prev,m=t.next;if(o?c(t,r,i,o):l(t))e.push(p.i,t.i,m.i),k(t),t=m.next,d=m.next;else if((t=m)===d){a?1===a?u(t=f(s(t),e),e,n,r,i,o,2):2===a&&h(t,e,n,r,i,o):u(s(t),e,n,r,i,o,1);break}}}}function l(t){var e=t.prev,n=t,r=t.next;if(_(e,n,r)>=0)return!1;for(var i=e.x,o=n.x,a=r.x,s=e.y,u=n.y,l=r.y,c=i<o?i<a?i:a:o<a?o:a,f=s<u?s<l?s:l:u<l?u:l,h=i>o?i>a?i:a:o>a?o:a,d=s>u?s>l?s:l:u>l?u:l,p=r.next;p!==e;){if(p.x>=c&&p.x<=h&&p.y>=f&&p.y<=d&&v(i,s,o,u,a,l,p.x,p.y)&&_(p.prev,p,p.next)>=0)return!1;p=p.next}return!0}function c(t,e,n,r){var i=t.prev,o=t,a=t.next;if(_(i,o,a)>=0)return!1;for(var s=i.x,u=o.x,l=a.x,c=i.y,f=o.y,h=a.y,d=s<u?s<l?s:l:u<l?u:l,p=c<f?c<h?c:h:f<h?f:h,m=s>u?s>l?s:l:u>l?u:l,y=c>f?c>h?c:h:f>h?f:h,x=g(d,p,e,n,r),b=g(m,y,e,n,r),w=t.prevZ,M=t.nextZ;w&&w.z>=x&&M&&M.z<=b;){if(w.x>=d&&w.x<=m&&w.y>=p&&w.y<=y&&w!==i&&w!==a&&v(s,c,u,f,l,h,w.x,w.y)&&_(w.prev,w,w.next)>=0)return!1;if(w=w.prevZ,M.x>=d&&M.x<=m&&M.y>=p&&M.y<=y&&M!==i&&M!==a&&v(s,c,u,f,l,h,M.x,M.y)&&_(M.prev,M,M.next)>=0)return!1;M=M.nextZ}for(;w&&w.z>=x;){if(w.x>=d&&w.x<=m&&w.y>=p&&w.y<=y&&w!==i&&w!==a&&v(s,c,u,f,l,h,w.x,w.y)&&_(w.prev,w,w.next)>=0)return!1;w=w.prevZ}for(;M&&M.z<=b;){if(M.x>=d&&M.x<=m&&M.y>=p&&M.y<=y&&M!==i&&M!==a&&v(s,c,u,f,l,h,M.x,M.y)&&_(M.prev,M,M.next)>=0)return!1;M=M.nextZ}return!0}function f(t,e){var n=t;do{var r=n.prev,i=n.next.next;!b(r,i)&&w(r,n,n.next,i)&&T(r,i)&&T(i,r)&&(e.push(r.i,n.i,i.i),k(n),k(n.next),n=t=i),n=n.next}while(n!==t);return s(n)}function h(t,e,n,r,i,o){var a=t;do{for(var l=a.next.next;l!==a.prev;){if(a.i!==l.i&&x(a,l)){var c=E(a,l);return a=s(a,a.next),c=s(c,c.next),u(a,e,n,r,i,o,0),void u(c,e,n,r,i,o,0)}l=l.next}a=a.next}while(a!==t)}function d(t,e){return t.x-e.x}function p(t,e){var n=function(t,e){var n,r=e,i=t.x,o=t.y,a=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var s=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(s<=i&&s>a&&(a=s,n=r.x<r.next.x?r:r.next,s===i))return n}r=r.next}while(r!==e);if(!n)return null;var u=n,l=n.x,c=n.y,f=1/0;r=n;do{if(i>=r.x&&r.x>=l&&i!==r.x&&v(o<c?i:a,o,l,c,o<c?a:i,o,r.x,r.y)){var h=Math.abs(o-r.y)/(i-r.x);T(r,t)&&(h<f||h===f&&(r.x>n.x||r.x===n.x&&m(n,r)))&&(n=r,f=h)}r=r.next}while(r!==u);return n}(t,e);if(!n)return e;var r=E(n,t);return s(r,r.next),s(n,n.next)}function m(t,e){return _(t.prev,t,e.prev)<0&&_(e.next,t,t.next)<0}function g(t,e,n,r,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=(t-n)*i|0)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=(e-r)*i|0)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function y(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function v(t,e,n,r,i,o,a,s){return(i-a)*(e-s)>=(t-a)*(o-s)&&(t-a)*(r-s)>=(n-a)*(e-s)&&(n-a)*(o-s)>=(i-a)*(r-s)}function x(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&w(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(T(t,e)&&T(e,t)&&function(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(_(t.prev,t,e.prev)||_(t,e.prev,e))||b(t,e)&&_(t.prev,t,t.next)>0&&_(e.prev,e,e.next)>0)}function _(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function b(t,e){return t.x===e.x&&t.y===e.y}function w(t,e,n,r){var i=A(_(t,e,n)),o=A(_(t,e,r)),a=A(_(n,r,t)),s=A(_(n,r,e));return i!==o&&a!==s||(!(0!==i||!M(t,n,e))||(!(0!==o||!M(t,r,e))||(!(0!==a||!M(n,t,r))||!(0!==s||!M(n,e,r)))))}function M(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function A(t){return t>0?1:t<0?-1:0}function T(t,e){return _(t.prev,t,t.next)<0?_(t,e,t.next)>=0&&_(t,t.prev,e)>=0:_(t,e,t.prev)<0||_(t,t.next,e)<0}function E(t,e){var n=S(t.i,t.x,t.y),r=S(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function C(t,e,n,r){var i=S(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function k(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function S(t,e,n){return{i:t,x:e,y:n,prev:null,next:null,z:0,prevZ:null,nextZ:null,steiner:!1}}function O(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,a=Math.abs(P(t,0,o,n));if(i)for(var s=0,u=e.length;s<u;s++){var l=e[s]*n,c=s<u-1?e[s+1]*n:t.length;a-=Math.abs(P(t,l,c,n))}for(var f=0,h=0;h<r.length;h+=3){var d=r[h]*n,p=r[h+1]*n,m=r[h+2]*n;f+=Math.abs((t[d]-t[m])*(t[p+1]-t[d+1])-(t[d]-t[p])*(t[m+1]-t[d+1]))}return 0===a&&0===f?0:Math.abs((f-a)/a)}function P(t,e,n,r){for(var i=0,o=e,a=n-r;o<n;o+=r)i+=(t[a]-t[o])*(t[o+1]+t[a+1]),a=o;return i}function L(t){var e,n=[],i=[],o=t[0][0].length,a=0,s=0,u=r(t);try{for(u.s();!(e=u.n()).done;){var l,c=e.value,f=r(c);try{for(f.s();!(l=f.n()).done;)for(var h=l.value,d=0;d<o;d++)n.push(h[d])}catch(t){f.e(t)}finally{f.f()}s&&(a+=s,i.push(a)),s=c.length}}catch(t){u.e(t)}finally{u.f()}return{vertices:n,holes:i,dimensions:o}}n.r(e),n.d(e,{default:function(){return o},deviation:function(){return O},flatten:function(){return L}})},4279:function(t,e,n){"use strict";function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||function(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function a(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,s(r.key),r)}}function s(t){var e=function(t,e){if("object"!=r(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,e||"default");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==r(e)?e:e+""}n.r(e),n.d(e,{default:function(){return l}});var u=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],l=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:64,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Float64Array,i=arguments.length>3?arguments[3]:void 0;if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),isNaN(e)||e<0)throw new Error("Unpexpected numItems value: ".concat(e,"."));this.numItems=+e,this.nodeSize=Math.min(Math.max(+n,2),65535),this.ArrayType=r,this.IndexArrayType=e<65536?Uint16Array:Uint32Array;var o=u.indexOf(this.ArrayType),a=2*e*this.ArrayType.BYTES_PER_ELEMENT,s=e*this.IndexArrayType.BYTES_PER_ELEMENT,l=(8-s%8)%8;if(o<0)throw new Error("Unexpected typed array class: ".concat(r,"."));i&&i instanceof ArrayBuffer?(this.data=i,this.ids=new this.IndexArrayType(this.data,8,e),this.coords=new this.ArrayType(this.data,8+s+l,2*e),this._pos=2*e,this._finished=!0):(this.data=new ArrayBuffer(8+a+s+l),this.ids=new this.IndexArrayType(this.data,8,e),this.coords=new this.ArrayType(this.data,8+s+l,2*e),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,16+o]),new Uint16Array(this.data,2,1)[0]=n,new Uint32Array(this.data,4,1)[0]=e)}return e=t,r=[{key:"from",value:function(e){if(!(e instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");var n=i(new Uint8Array(e,0,2),2),r=n[0],o=n[1];if(219!==r)throw new Error("Data does not appear to be in a KDBush format.");var a=o>>4;if(1!==a)throw new Error("Got v".concat(a," data when expected v").concat(1,"."));var s=u[15&o];if(!s)throw new Error("Unrecognized array type.");var l=i(new Uint16Array(e,2,1),1)[0];return new t(i(new Uint32Array(e,4,1),1)[0],l,s,e)}}],(n=[{key:"add",value:function(t,e){var n=this._pos>>1;return this.ids[n]=n,this.coords[this._pos++]=t,this.coords[this._pos++]=e,n}},{key:"finish",value:function(){var t=this._pos>>1;if(t!==this.numItems)throw new Error("Added ".concat(t," items when expected ").concat(this.numItems,"."));return c(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}},{key:"range",value:function(t,e,n,r){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var i=this.ids,o=this.coords,a=this.nodeSize,s=[0,i.length-1,0],u=[];s.length;){var l=s.pop()||0,c=s.pop()||0,f=s.pop()||0;if(c-f<=a)for(var h=f;h<=c;h++){var d=o[2*h],p=o[2*h+1];d>=t&&d<=n&&p>=e&&p<=r&&u.push(i[h])}else{var m=f+c>>1,g=o[2*m],y=o[2*m+1];g>=t&&g<=n&&y>=e&&y<=r&&u.push(i[m]),(0===l?t<=g:e<=y)&&(s.push(f),s.push(m-1),s.push(1-l)),(0===l?n>=g:r>=y)&&(s.push(m+1),s.push(c),s.push(1-l))}}return u}},{key:"within",value:function(t,e,n){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var r=this.ids,i=this.coords,o=this.nodeSize,a=[0,r.length-1,0],s=[],u=n*n;a.length;){var l=a.pop()||0,c=a.pop()||0,f=a.pop()||0;if(c-f<=o)for(var h=f;h<=c;h++)p(i[2*h],i[2*h+1],t,e)<=u&&s.push(r[h]);else{var d=f+c>>1,m=i[2*d],g=i[2*d+1];p(m,g,t,e)<=u&&s.push(r[d]),(0===l?t-n<=m:e-n<=g)&&(a.push(f),a.push(d-1),a.push(1-l)),(0===l?t+n>=m:e+n>=g)&&(a.push(d+1),a.push(c),a.push(1-l))}}return s}}])&&a(e.prototype,n),r&&a(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n,r}();function c(t,e,n,r,i,o){if(!(i-r<=n)){var a=r+i>>1;f(t,e,a,r,i,o),c(t,e,n,r,a-1,1-o),c(t,e,n,a+1,i,1-o)}}function f(t,e,n,r,i,o){for(;i>r;){if(i-r>600){var a=i-r+1,s=n-r+1,u=Math.log(a),l=.5*Math.exp(2*u/3),c=.5*Math.sqrt(u*l*(a-l)/a)*(s-a/2<0?-1:1);f(t,e,n,Math.max(r,Math.floor(n-s*l/a+c)),Math.min(i,Math.floor(n+(a-s)*l/a+c)),o)}var d=e[2*n+o],p=r,m=i;for(h(t,e,r,n),e[2*i+o]>d&&h(t,e,r,i);p<m;){for(h(t,e,p,m),p++,m--;e[2*p+o]<d;)p++;for(;e[2*m+o]>d;)m--}e[2*r+o]===d?h(t,e,r,m):h(t,e,++m,i),m<=n&&(r=m+1),n<=m&&(i=m-1)}}function h(t,e,n,r){d(t,n,r),d(e,2*n,2*r),d(e,2*n+1,2*r+1)}function d(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function p(t,e,n,r){var i=t-n,o=e-r;return i*i+o*o}},7715:function(t,e,n){"use strict";n.r(e),e.default={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},5127:function(t,e,n){"use strict";function r(t,e){return null==t||null==e?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function i(t,e){return null==t||null==e?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function o(t){let e,n,o;function s(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<0?i=e+1:o=e}while(i<o)}return i}return 2!==t.length?(e=r,n=(e,n)=>r(t(e),n),o=(e,n)=>t(e)-n):(e=t===r||t===i?t:a,n=t,o=t),{left:s,center:function(t,e,n=0,r=t.length){const i=s(t,e,n,r-1);return i>n&&o(t[i-1],e)>-o(t[i],e)?i-1:i},right:function(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<=0?i=e+1:o=e}while(i<o)}return i}}}function a(){return 0}function s(t){return null===t?NaN:+t}n.r(e),n.d(e,{Adder:function(){return S},Delaunay:function(){return Xs},FormatSpecifier:function(){return hc},InternMap:function(){return L},InternSet:function(){return R},Node:function(){return Fm},Path:function(){return la},Voronoi:function(){return Vs},ZoomTransform:function(){return XT},active:function(){return po},arc:function(){return PM},area:function(){return zM},areaRadial:function(){return KM},ascending:function(){return r},autoType:function(){return Cu},axisBottom:function(){return xe},axisLeft:function(){return _e},axisRight:function(){return ve},axisTop:function(){return ye},bin:function(){return dt},bisect:function(){return h},bisectCenter:function(){return f},bisectLeft:function(){return c},bisectRight:function(){return l},bisector:function(){return o},blob:function(){return gl},blur:function(){return d},blur2:function(){return p},blurImage:function(){return m},brush:function(){return Go},brushSelection:function(){return Bo},brushX:function(){return Vo},brushY:function(){return qo},buffer:function(){return vl},chord:function(){return ta},chordDirected:function(){return na},chordTranspose:function(){return ea},cluster:function(){return Om},color:function(){return hr},contourDensity:function(){return vs},contours:function(){return cs},count:function(){return _},create:function(){return oM},creator:function(){return Cn},cross:function(){return A},csv:function(){return Ml},csvFormat:function(){return pu},csvFormatBody:function(){return mu},csvFormatRow:function(){return yu},csvFormatRows:function(){return gu},csvFormatValue:function(){return vu},csvParse:function(){return hu},csvParseRows:function(){return du},cubehelix:function(){return ts},cumsum:function(){return T},curveBasis:function(){return jA},curveBasisClosed:function(){return BA},curveBasisOpen:function(){return qA},curveBumpX:function(){return ZM},curveBumpY:function(){return JM},curveBundle:function(){return UA},curveCardinal:function(){return XA},curveCardinalClosed:function(){return QA},curveCardinalOpen:function(){return $A},curveCatmullRom:function(){return tT},curveCatmullRomClosed:function(){return nT},curveCatmullRomOpen:function(){return iT},curveLinear:function(){return DM},curveLinearClosed:function(){return aT},curveMonotoneX:function(){return pT},curveMonotoneY:function(){return mT},curveNatural:function(){return vT},curveStep:function(){return _T},curveStepAfter:function(){return wT},curveStepBefore:function(){return bT},descending:function(){return i},deviation:function(){return C},difference:function(){return $t},disjoint:function(){return Zt},dispatch:function(){return Ee},drag:function(){return tu},dragDisable:function(){return Wn},dragEnable:function(){return Xn},dsv:function(){return wl},dsvFormat:function(){return cu},easeBack:function(){return cl},easeBackIn:function(){return ul},easeBackInOut:function(){return cl},easeBackOut:function(){return ll},easeBounce:function(){return ol},easeBounceIn:function(){return il},easeBounceInOut:function(){return al},easeBounceOut:function(){return ol},easeCircle:function(){return Xu},easeCircleIn:function(){return Hu},easeCircleInOut:function(){return Xu},easeCircleOut:function(){return Wu},easeCubic:function(){return lo},easeCubicIn:function(){return so},easeCubicInOut:function(){return lo},easeCubicOut:function(){return uo},easeElastic:function(){return dl},easeElasticIn:function(){return hl},easeElasticInOut:function(){return pl},easeElasticOut:function(){return dl},easeExp:function(){return Uu},easeExpIn:function(){return qu},easeExpInOut:function(){return Uu},easeExpOut:function(){return Gu},easeLinear:function(){return Su},easePoly:function(){return Du},easePolyIn:function(){return Ru},easePolyInOut:function(){return Du},easePolyOut:function(){return Iu},easeQuad:function(){return Lu},easeQuadIn:function(){return Ou},easeQuadInOut:function(){return Lu},easeQuadOut:function(){return Pu},easeSin:function(){return Bu},easeSinIn:function(){return ju},easeSinInOut:function(){return Bu},easeSinOut:function(){return zu},every:function(){return Ht},extent:function(){return k},fcumsum:function(){return P},filter:function(){return Xt},flatGroup:function(){return q},flatRollup:function(){return G},forceCenter:function(){return Ll},forceCollide:function(){return Hl},forceLink:function(){return Kl},forceManyBody:function(){return rc},forceRadial:function(){return ic},forceSimulation:function(){return nc},forceX:function(){return oc},forceY:function(){return ac},format:function(){return yc},formatDefaultLocale:function(){return wc},formatLocale:function(){return bc},formatPrefix:function(){return vc},formatSpecifier:function(){return fc},fsum:function(){return O},geoAlbers:function(){return Hp},geoAlbersUsa:function(){return Wp},geoArea:function(){return Cf},geoAzimuthalEqualArea:function(){return Yp},geoAzimuthalEqualAreaRaw:function(){return Qp},geoAzimuthalEquidistant:function(){return Zp},geoAzimuthalEquidistantRaw:function(){return $p},geoBounds:function(){return uh},geoCentroid:function(){return _h},geoCircle:function(){return Ph},geoClipAntimeridian:function(){return qh},geoClipCircle:function(){return Gh},geoClipExtent:function(){return $h},geoClipRectangle:function(){return Yh},geoConicConformal:function(){return im},geoConicConformalRaw:function(){return rm},geoConicEqualArea:function(){return Up},geoConicEqualAreaRaw:function(){return Gp},geoConicEquidistant:function(){return um},geoConicEquidistantRaw:function(){return sm},geoContains:function(){return pd},geoDistance:function(){return od},geoEqualEarth:function(){return mm},geoEqualEarthRaw:function(){return pm},geoEquirectangular:function(){return am},geoEquirectangularRaw:function(){return om},geoGnomonic:function(){return ym},geoGnomonicRaw:function(){return gm},geoGraticule:function(){return yd},geoGraticule10:function(){return vd},geoIdentity:function(){return vm},geoInterpolate:function(){return xd},geoLength:function(){return nd},geoMercator:function(){return tm},geoMercatorRaw:function(){return Jp},geoNaturalEarth1:function(){return _m},geoNaturalEarth1Raw:function(){return xm},geoOrthographic:function(){return wm},geoOrthographicRaw:function(){return bm},geoPath:function(){return Ep},geoProjection:function(){return Bp},geoProjectionMutator:function(){return Vp},geoRotation:function(){return kh},geoStereographic:function(){return Am},geoStereographicRaw:function(){return Mm},geoStream:function(){return nf},geoTransform:function(){return Cp},geoTransverseMercator:function(){return Em},geoTransverseMercatorRaw:function(){return Tm},gray:function(){return Ia},greatest:function(){return _t},greatestIndex:function(){return Ft},group:function(){return z},groupSort:function(){return tt},groups:function(){return B},hcl:function(){return Ga},hierarchy:function(){return Lm},histogram:function(){return dt},hsl:function(){return Tr},html:function(){return Ol},image:function(){return Tl},index:function(){return W},indexes:function(){return X},interpolate:function(){return Zr},interpolateArray:function(){return Ur},interpolateBasis:function(){return Pr},interpolateBasisClosed:function(){return Lr},interpolateBlues:function(){return Lw},interpolateBrBG:function(){return Ub},interpolateBuGn:function(){return uw},interpolateBuPu:function(){return cw},interpolateCividis:function(){return Gw},interpolateCool:function(){return Ww},interpolateCubehelix:function(){return $g},interpolateCubehelixDefault:function(){return Uw},interpolateCubehelixLong:function(){return Zg},interpolateDate:function(){return Wr},interpolateDiscrete:function(){return jg},interpolateGnBu:function(){return hw},interpolateGreens:function(){return Iw},interpolateGreys:function(){return Nw},interpolateHcl:function(){return Kg},interpolateHclLong:function(){return Qg},interpolateHsl:function(){return Ug},interpolateHslLong:function(){return Hg},interpolateHue:function(){return zg},interpolateInferno:function(){return rM},interpolateLab:function(){return Wg},interpolateMagma:function(){return nM},interpolateNumber:function(){return Xr},interpolateNumberArray:function(){return qr},interpolateObject:function(){return Kr},interpolateOrRd:function(){return pw},interpolateOranges:function(){return qw},interpolatePRGn:function(){return Wb},interpolatePiYG:function(){return Kb},interpolatePlasma:function(){return iM},interpolatePuBu:function(){return vw},interpolatePuBuGn:function(){return gw},interpolatePuOr:function(){return Yb},interpolatePuRd:function(){return _w},interpolatePurples:function(){return jw},interpolateRainbow:function(){return Kw},interpolateRdBu:function(){return Zb},interpolateRdGy:function(){return tw},interpolateRdPu:function(){return ww},interpolateRdYlBu:function(){return nw},interpolateRdYlGn:function(){return iw},interpolateReds:function(){return Bw},interpolateRgb:function(){return jr},interpolateRgbBasis:function(){return Br},interpolateRgbBasisClosed:function(){return Vr},interpolateRound:function(){return Bg},interpolateSinebow:function(){return Zw},interpolateSpectral:function(){return aw},interpolateString:function(){return $r},interpolateTransformCss:function(){return Ni},interpolateTransformSvg:function(){return Fi},interpolateTurbo:function(){return Jw},interpolateViridis:function(){return eM},interpolateWarm:function(){return Hw},interpolateYlGn:function(){return Ew},interpolateYlGnBu:function(){return Aw},interpolateYlOrBr:function(){return kw},interpolateYlOrRd:function(){return Ow},interpolateZoom:function(){return qg},interrupt:function(){return Oi},intersection:function(){return Jt},interval:function(){return UT},isoFormat:function(){return VT},isoParse:function(){return GT},json:function(){return Cl},lab:function(){return Da},lch:function(){return qa},least:function(){return Dt},leastIndex:function(){return Nt},line:function(){return jM},lineRadial:function(){return XM},link:function(){return rA},linkHorizontal:function(){return iA},linkRadial:function(){return aA},linkVertical:function(){return oA},local:function(){return sM},map:function(){return Kt},matcher:function(){return Le},max:function(){return pt},maxIndex:function(){return mt},mean:function(){return Et},median:function(){return Ct},medianIndex:function(){return kt},merge:function(){return St},min:function(){return gt},minIndex:function(){return yt},mode:function(){return Ot},namespace:function(){return Xe},namespaces:function(){return We},nice:function(){return ft},now:function(){return fi},pack:function(){return ug},packEnclose:function(){return Wm},packSiblings:function(){return ag},pairs:function(){return Pt},partition:function(){return pg},path:function(){return ca},pathRound:function(){return fa},permute:function(){return Y},pie:function(){return qM},piecewise:function(){return Jg},pointRadial:function(){return QM},pointer:function(){return ti},pointers:function(){return lM},polygonArea:function(){return ey},polygonCentroid:function(){return ny},polygonContains:function(){return sy},polygonHull:function(){return ay},polygonLength:function(){return uy},precisionFixed:function(){return Mc},precisionPrefix:function(){return Ac},precisionRound:function(){return Tc},quadtree:function(){return Fl},quantile:function(){return bt},quantileIndex:function(){return Mt},quantileSorted:function(){return wt},quantize:function(){return ty},quickselect:function(){return vt},radialArea:function(){return KM},radialLine:function(){return XM},randomBates:function(){return my},randomBernoulli:function(){return vy},randomBeta:function(){return by},randomBinomial:function(){return wy},randomCauchy:function(){return Ay},randomExponential:function(){return gy},randomGamma:function(){return _y},randomGeometric:function(){return xy},randomInt:function(){return fy},randomIrwinHall:function(){return py},randomLcg:function(){return Oy},randomLogNormal:function(){return dy},randomLogistic:function(){return Ty},randomNormal:function(){return hy},randomPareto:function(){return yy},randomPoisson:function(){return Ey},randomUniform:function(){return cy},randomWeibull:function(){return My},range:function(){return Rt},rank:function(){return It},reduce:function(){return Qt},reverse:function(){return Yt},rgb:function(){return gr},ribbon:function(){return wa},ribbonArrow:function(){return Ma},rollup:function(){return U},rollups:function(){return H},scaleBand:function(){return Dy},scaleDiverging:function(){return Tb},scaleDivergingLog:function(){return Eb},scaleDivergingPow:function(){return kb},scaleDivergingSqrt:function(){return Sb},scaleDivergingSymlog:function(){return Cb},scaleIdentity:function(){return Yy},scaleImplicit:function(){return Ry},scaleLinear:function(){return Qy},scaleLog:function(){return ov},scaleOrdinal:function(){return Iy},scalePoint:function(){return Fy},scalePow:function(){return pv},scaleQuantile:function(){return vv},scaleQuantize:function(){return xv},scaleRadial:function(){return yv},scaleSequential:function(){return vb},scaleSequentialLog:function(){return xb},scaleSequentialPow:function(){return bb},scaleSequentialQuantile:function(){return Mb},scaleSequentialSqrt:function(){return wb},scaleSequentialSymlog:function(){return _b},scaleSqrt:function(){return mv},scaleSymlog:function(){return lv},scaleThreshold:function(){return _v},scaleTime:function(){return pb},scaleUtc:function(){return mb},scan:function(){return jt},schemeAccent:function(){return Lb},schemeBlues:function(){return Pw},schemeBrBG:function(){return Gb},schemeBuGn:function(){return sw},schemeBuPu:function(){return lw},schemeCategory10:function(){return Pb},schemeDark2:function(){return Rb},schemeGnBu:function(){return fw},schemeGreens:function(){return Rw},schemeGreys:function(){return Dw},schemeObservable10:function(){return Ib},schemeOrRd:function(){return dw},schemeOranges:function(){return Vw},schemePRGn:function(){return Hb},schemePaired:function(){return Db},schemePastel1:function(){return Nb},schemePastel2:function(){return Fb},schemePiYG:function(){return Xb},schemePuBu:function(){return yw},schemePuBuGn:function(){return mw},schemePuOr:function(){return Qb},schemePuRd:function(){return xw},schemePurples:function(){return Fw},schemeRdBu:function(){return $b},schemeRdGy:function(){return Jb},schemeRdPu:function(){return bw},schemeRdYlBu:function(){return ew},schemeRdYlGn:function(){return rw},schemeReds:function(){return zw},schemeSet1:function(){return jb},schemeSet2:function(){return zb},schemeSet3:function(){return Bb},schemeSpectral:function(){return ow},schemeTableau10:function(){return Vb},schemeYlGn:function(){return Tw},schemeYlGnBu:function(){return Mw},schemeYlOrBr:function(){return Cw},schemeYlOrRd:function(){return Sw},select:function(){return Vn},selectAll:function(){return cM},selection:function(){return Bn},selector:function(){return ke},selectorAll:function(){return Pe},shuffle:function(){return zt},shuffler:function(){return Bt},some:function(){return Wt},sort:function(){return $},stack:function(){return CT},stackOffsetDiverging:function(){return ST},stackOffsetExpand:function(){return kT},stackOffsetNone:function(){return MT},stackOffsetSilhouette:function(){return OT},stackOffsetWiggle:function(){return PT},stackOrderAppearance:function(){return LT},stackOrderAscending:function(){return IT},stackOrderDescending:function(){return NT},stackOrderInsideOut:function(){return FT},stackOrderNone:function(){return AT},stackOrderReverse:function(){return jT},stratify:function(){return _g},style:function(){return on},subset:function(){return re},sum:function(){return Vt},superset:function(){return ee},svg:function(){return Pl},symbol:function(){return IA},symbolAsterisk:function(){return uA},symbolCircle:function(){return lA},symbolCross:function(){return cA},symbolDiamond:function(){return dA},symbolDiamond2:function(){return pA},symbolPlus:function(){return mA},symbolSquare:function(){return gA},symbolSquare2:function(){return yA},symbolStar:function(){return bA},symbolTimes:function(){return PA},symbolTriangle:function(){return MA},symbolTriangle2:function(){return TA},symbolWye:function(){return OA},symbolX:function(){return PA},symbols:function(){return LA},symbolsFill:function(){return LA},symbolsStroke:function(){return RA},text:function(){return _l},thresholdFreedmanDiaconis:function(){return At},thresholdScott:function(){return Tt},thresholdSturges:function(){return ht},tickFormat:function(){return Xy},tickIncrement:function(){return lt},tickStep:function(){return ct},ticks:function(){return ut},timeDay:function(){return Gv},timeDays:function(){return Uv},timeFormat:function(){return Gx},timeFormatDefaultLocale:function(){return cb},timeFormatLocale:function(){return Vx},timeFriday:function(){return ex},timeFridays:function(){return ux},timeHour:function(){return zv},timeHours:function(){return Bv},timeInterval:function(){return Ov},timeMillisecond:function(){return Pv},timeMilliseconds:function(){return Lv},timeMinute:function(){return Dv},timeMinutes:function(){return Nv},timeMonday:function(){return $v},timeMondays:function(){return ix},timeMonth:function(){return Tx},timeMonths:function(){return Ex},timeParse:function(){return Ux},timeSaturday:function(){return nx},timeSaturdays:function(){return lx},timeSecond:function(){return Rv},timeSeconds:function(){return Iv},timeSunday:function(){return Yv},timeSundays:function(){return rx},timeThursday:function(){return tx},timeThursdays:function(){return sx},timeTickInterval:function(){return Fx},timeTicks:function(){return Nx},timeTuesday:function(){return Zv},timeTuesdays:function(){return ox},timeWednesday:function(){return Jv},timeWednesdays:function(){return ax},timeWeek:function(){return Yv},timeWeeks:function(){return rx},timeYear:function(){return Sx},timeYears:function(){return Ox},timeout:function(){return xi},timer:function(){return pi},timerFlush:function(){return mi},transition:function(){return io},transpose:function(){return qt},tree:function(){return Sg},treemap:function(){return Ig},treemapBinary:function(){return Dg},treemapDice:function(){return dg},treemapResquarify:function(){return Fg},treemapSlice:function(){return Og},treemapSliceDice:function(){return Ng},treemapSquarify:function(){return Rg},tsv:function(){return Al},tsvFormat:function(){return wu},tsvFormatBody:function(){return Mu},tsvFormatRow:function(){return Tu},tsvFormatRows:function(){return Au},tsvFormatValue:function(){return Eu},tsvParse:function(){return _u},tsvParseRows:function(){return bu},union:function(){return ie},unixDay:function(){return Xv},unixDays:function(){return Kv},utcDay:function(){return Hv},utcDays:function(){return Wv},utcFormat:function(){return Hx},utcFriday:function(){return gx},utcFridays:function(){return Mx},utcHour:function(){return Vv},utcHours:function(){return qv},utcMillisecond:function(){return Pv},utcMilliseconds:function(){return Lv},utcMinute:function(){return Fv},utcMinutes:function(){return jv},utcMonday:function(){return hx},utcMondays:function(){return xx},utcMonth:function(){return Cx},utcMonths:function(){return kx},utcParse:function(){return Wx},utcSaturday:function(){return yx},utcSaturdays:function(){return Ax},utcSecond:function(){return Rv},utcSeconds:function(){return Iv},utcSunday:function(){return fx},utcSundays:function(){return vx},utcThursday:function(){return mx},utcThursdays:function(){return wx},utcTickInterval:function(){return Dx},utcTicks:function(){return Ix},utcTuesday:function(){return dx},utcTuesdays:function(){return _x},utcWednesday:function(){return px},utcWednesdays:function(){return bx},utcWeek:function(){return fx},utcWeeks:function(){return vx},utcYear:function(){return Px},utcYears:function(){return Lx},variance:function(){return E},window:function(){return tn},xml:function(){return Sl},zip:function(){return Ut},zoom:function(){return iE},zoomIdentity:function(){return KT},zoomTransform:function(){return QT}});const u=o(r),l=u.right,c=u.left,f=o(s).center;var h=l;function d(t,e){if(!((e=+e)>=0))throw new RangeError("invalid r");let n=t.length;if(!((n=Math.floor(n))>=0))throw new RangeError("invalid length");if(!n||!e)return t;const r=x(e),i=t.slice();return r(t,i,0,n,1),r(i,t,0,n,1),r(t,i,0,n,1),t}const p=g(x),m=g((function(t){const e=x(t);return(t,n,r,i,o)=>{e(t,n,(r<<=2)+0,(i<<=2)+0,o<<=2),e(t,n,r+1,i+1,o),e(t,n,r+2,i+2,o),e(t,n,r+3,i+3,o)}}));function g(t){return function(e,n,r=n){if(!((n=+n)>=0))throw new RangeError("invalid rx");if(!((r=+r)>=0))throw new RangeError("invalid ry");let{data:i,width:o,height:a}=e;if(!((o=Math.floor(o))>=0))throw new RangeError("invalid width");if(!((a=Math.floor(void 0!==a?a:i.length/o))>=0))throw new RangeError("invalid height");if(!o||!a||!n&&!r)return e;const s=n&&t(n),u=r&&t(r),l=i.slice();return s&&u?(y(s,l,i,o,a),y(s,i,l,o,a),y(s,l,i,o,a),v(u,i,l,o,a),v(u,l,i,o,a),v(u,i,l,o,a)):s?(y(s,i,l,o,a),y(s,l,i,o,a),y(s,i,l,o,a)):u&&(v(u,i,l,o,a),v(u,l,i,o,a),v(u,i,l,o,a)),e}}function y(t,e,n,r,i){for(let o=0,a=r*i;o<a;)t(e,n,o,o+=r,1)}function v(t,e,n,r,i){for(let o=0,a=r*i;o<r;++o)t(e,n,o,o+a,r)}function x(t){const e=Math.floor(t);if(e===t)return function(t){const e=2*t+1;return(n,r,i,o,a)=>{if(!((o-=a)>=i))return;let s=t*r[i];const u=a*t;for(let t=i,e=i+u;t<e;t+=a)s+=r[Math.min(o,t)];for(let t=i,l=o;t<=l;t+=a)s+=r[Math.min(o,t+u)],n[t]=s/e,s-=r[Math.max(i,t-u)]}}(t);const n=t-e,r=2*t+1;return(t,i,o,a,s)=>{if(!((a-=s)>=o))return;let u=e*i[o];const l=s*e,c=l+s;for(let t=o,e=o+l;t<e;t+=s)u+=i[Math.min(a,t)];for(let e=o,f=a;e<=f;e+=s)u+=i[Math.min(a,e+l)],t[e]=(u+n*(i[Math.max(o,e-c)]+i[Math.min(a,e+c)]))/r,u-=i[Math.max(o,e-l)]}}function _(t,e){let n=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&++n;else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(i=+i)>=i&&++n}return n}function b(t){return 0|t.length}function w(t){return!(t>0)}function M(t){return"object"!=typeof t||"length"in t?t:Array.from(t)}function A(...t){const e="function"==typeof t[t.length-1]&&function(t){return e=>t(...e)}(t.pop()),n=(t=t.map(M)).map(b),r=t.length-1,i=new Array(r+1).fill(0),o=[];if(r<0||n.some(w))return o;for(;;){o.push(i.map(((e,n)=>t[n][e])));let a=r;for(;++i[a]===n[a];){if(0===a)return e?o.map(e):o;i[a--]=0}}}function T(t,e){var n=0,r=0;return Float64Array.from(t,void 0===e?t=>n+=+t||0:i=>n+=+e(i,r++,t)||0)}function E(t,e){let n,r=0,i=0,o=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(n=e-i,i+=n/++r,o+=n*(e-i));else{let a=-1;for(let s of t)null!=(s=e(s,++a,t))&&(s=+s)>=s&&(n=s-i,i+=n/++r,o+=n*(s-i))}if(r>1)return o/(r-1)}function C(t,e){const n=E(t,e);return n?Math.sqrt(n):n}function k(t,e){let n,r;if(void 0===e)for(const e of t)null!=e&&(void 0===n?e>=e&&(n=r=e):(n>e&&(n=e),r<e&&(r=e)));else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(void 0===n?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}class S{constructor(){this._partials=new Float64Array(32),this._n=0}add(t){const e=this._partials;let n=0;for(let r=0;r<this._n&&r<32;r++){const i=e[r],o=t+i,a=Math.abs(t)<Math.abs(i)?t-(o-i):i-(o-t);a&&(e[n++]=a),t=o}return e[n]=t,this._n=n+1,this}valueOf(){const t=this._partials;let e,n,r,i=this._n,o=0;if(i>0){for(o=t[--i];i>0&&(e=o,n=t[--i],o=e+n,r=n-(o-e),!r););i>0&&(r<0&&t[i-1]<0||r>0&&t[i-1]>0)&&(n=2*r,e=o+n,n==e-o&&(o=e))}return o}}function O(t,e){const n=new S;if(void 0===e)for(let e of t)(e=+e)&&n.add(e);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&n.add(i)}return+n}function P(t,e){const n=new S;let r=-1;return Float64Array.from(t,void 0===e?t=>n.add(+t||0):i=>n.add(+e(i,++r,t)||0))}class L extends Map{constructor(t,e=F){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[e,n]of t)this.set(e,n)}get(t){return super.get(I(this,t))}has(t){return super.has(I(this,t))}set(t,e){return super.set(D(this,t),e)}delete(t){return super.delete(N(this,t))}}class R extends Set{constructor(t,e=F){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const e of t)this.add(e)}has(t){return super.has(I(this,t))}add(t){return super.add(D(this,t))}delete(t){return super.delete(N(this,t))}}function I({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):n}function D({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):(t.set(r,n),n)}function N({_intern:t,_key:e},n){const r=e(n);return t.has(r)&&(n=t.get(r),t.delete(r)),n}function F(t){return null!==t&&"object"==typeof t?t.valueOf():t}function j(t){return t}function z(t,...e){return Q(t,j,j,e)}function B(t,...e){return Q(t,Array.from,j,e)}function V(t,e){for(let n=1,r=e.length;n<r;++n)t=t.flatMap((t=>t.pop().map((([e,n])=>[...t,e,n]))));return t}function q(t,...e){return V(B(t,...e),e)}function G(t,e,...n){return V(H(t,e,...n),n)}function U(t,e,...n){return Q(t,j,e,n)}function H(t,e,...n){return Q(t,Array.from,e,n)}function W(t,...e){return Q(t,j,K,e)}function X(t,...e){return Q(t,Array.from,K,e)}function K(t){if(1!==t.length)throw new Error("duplicate key");return t[0]}function Q(t,e,n,r){return function t(i,o){if(o>=r.length)return n(i);const a=new L,s=r[o++];let u=-1;for(const t of i){const e=s(t,++u,i),n=a.get(e);n?n.push(t):a.set(e,[t])}for(const[e,n]of a)a.set(e,t(n,o));return e(a)}(t,0)}function Y(t,e){return Array.from(e,(e=>t[e]))}function $(t,...e){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");t=Array.from(t);let[n]=e;if(n&&2!==n.length||e.length>1){const r=Uint32Array.from(t,((t,e)=>e));return e.length>1?(e=e.map((e=>t.map(e))),r.sort(((t,n)=>{for(const r of e){const e=J(r[t],r[n]);if(e)return e}}))):(n=t.map(n),r.sort(((t,e)=>J(n[t],n[e])))),Y(t,r)}return t.sort(Z(n))}function Z(t=r){if(t===r)return J;if("function"!=typeof t)throw new TypeError("compare is not a function");return(e,n)=>{const r=t(e,n);return r||0===r?r:(0===t(n,n))-(0===t(e,e))}}function J(t,e){return(null==t||!(t>=t))-(null==e||!(e>=e))||(t<e?-1:t>e?1:0)}function tt(t,e,n){return(2!==e.length?$(U(t,e,n),(([t,e],[n,i])=>r(e,i)||r(t,n))):$(z(t,n),(([t,n],[i,o])=>e(n,o)||r(t,i)))).map((([t])=>t))}var et=Array.prototype,nt=et.slice;et.map;function rt(t){return()=>t}const it=Math.sqrt(50),ot=Math.sqrt(10),at=Math.sqrt(2);function st(t,e,n){const r=(e-t)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=it?10:o>=ot?5:o>=at?2:1;let s,u,l;return i<0?(l=Math.pow(10,-i)/a,s=Math.round(t*l),u=Math.round(e*l),s/l<t&&++s,u/l>e&&--u,l=-l):(l=Math.pow(10,i)*a,s=Math.round(t/l),u=Math.round(e/l),s*l<t&&++s,u*l>e&&--u),u<s&&.5<=n&&n<2?st(t,e,2*n):[s,u,l]}function ut(t,e,n){if(!((n=+n)>0))return[];if((t=+t)===(e=+e))return[t];const r=e<t,[i,o,a]=r?st(e,t,n):st(t,e,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let t=0;t<s;++t)u[t]=(o-t)/-a;else for(let t=0;t<s;++t)u[t]=(o-t)*a;else if(a<0)for(let t=0;t<s;++t)u[t]=(i+t)/-a;else for(let t=0;t<s;++t)u[t]=(i+t)*a;return u}function lt(t,e,n){return st(t=+t,e=+e,n=+n)[2]}function ct(t,e,n){n=+n;const r=(e=+e)<(t=+t),i=r?lt(e,t,n):lt(t,e,n);return(r?-1:1)*(i<0?1/-i:i)}function ft(t,e,n){let r;for(;;){const i=lt(t,e,n);if(i===r||0===i||!isFinite(i))return[t,e];i>0?(t=Math.floor(t/i)*i,e=Math.ceil(e/i)*i):i<0&&(t=Math.ceil(t*i)/i,e=Math.floor(e*i)/i),r=i}}function ht(t){return Math.max(1,Math.ceil(Math.log(_(t))/Math.LN2)+1)}function dt(){var t=j,e=k,n=ht;function r(r){Array.isArray(r)||(r=Array.from(r));var i,o,a,s=r.length,u=new Array(s);for(i=0;i<s;++i)u[i]=t(r[i],i,r);var l=e(u),c=l[0],f=l[1],d=n(u,c,f);if(!Array.isArray(d)){const t=f,n=+d;if(e===k&&([c,f]=ft(c,f,n)),(d=ut(c,f,n))[0]<=c&&(a=lt(c,f,n)),d[d.length-1]>=f)if(t>=f&&e===k){const t=lt(c,f,n);isFinite(t)&&(t>0?f=(Math.floor(f/t)+1)*t:t<0&&(f=(Math.ceil(f*-t)+1)/-t))}else d.pop()}for(var p=d.length,m=0,g=p;d[m]<=c;)++m;for(;d[g-1]>f;)--g;(m||g<p)&&(d=d.slice(m,g),p=g-m);var y,v=new Array(p+1);for(i=0;i<=p;++i)(y=v[i]=[]).x0=i>0?d[i-1]:c,y.x1=i<p?d[i]:f;if(isFinite(a)){if(a>0)for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=f&&v[Math.min(p,Math.floor((o-c)/a))].push(r[i]);else if(a<0)for(i=0;i<s;++i)if(null!=(o=u[i])&&c<=o&&o<=f){const t=Math.floor((c-o)*a);v[Math.min(p,t+(d[t]<=o))].push(r[i])}}else for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=f&&v[h(d,o,0,p)].push(r[i]);return v}return r.value=function(e){return arguments.length?(t="function"==typeof e?e:rt(e),r):t},r.domain=function(t){return arguments.length?(e="function"==typeof t?t:rt([t[0],t[1]]),r):e},r.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:rt(Array.isArray(t)?nt.call(t):t),r):n},r}function pt(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n<e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function mt(t,e){let n,r=-1,i=-1;if(void 0===e)for(const e of t)++i,null!=e&&(n<e||void 0===n&&e>=e)&&(n=e,r=i);else for(let o of t)null!=(o=e(o,++i,t))&&(n<o||void 0===n&&o>=o)&&(n=o,r=i);return r}function gt(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n>e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function yt(t,e){let n,r=-1,i=-1;if(void 0===e)for(const e of t)++i,null!=e&&(n>e||void 0===n&&e>=e)&&(n=e,r=i);else for(let o of t)null!=(o=e(o,++i,t))&&(n>o||void 0===n&&o>=o)&&(n=o,r=i);return r}function vt(t,e,n=0,r=1/0,i){if(e=Math.floor(e),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(t.length-1,r)),!(n<=e&&e<=r))return t;for(i=void 0===i?J:Z(i);r>n;){if(r-n>600){const o=r-n+1,a=e-n+1,s=Math.log(o),u=.5*Math.exp(2*s/3),l=.5*Math.sqrt(s*u*(o-u)/o)*(a-o/2<0?-1:1);vt(t,e,Math.max(n,Math.floor(e-a*u/o+l)),Math.min(r,Math.floor(e+(o-a)*u/o+l)),i)}const o=t[e];let a=n,s=r;for(xt(t,n,e),i(t[r],o)>0&&xt(t,n,r);a<s;){for(xt(t,a,s),++a,--s;i(t[a],o)<0;)++a;for(;i(t[s],o)>0;)--s}0===i(t[n],o)?xt(t,n,s):(++s,xt(t,s,r)),s<=e&&(n=s+1),e<=s&&(r=s-1)}return t}function xt(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function _t(t,e=r){let n,i=!1;if(1===e.length){let o;for(const a of t){const t=e(a);(i?r(t,o)>0:0===r(t,t))&&(n=a,o=t,i=!0)}}else for(const r of t)(i?e(r,n)>0:0===e(r,r))&&(n=r,i=!0);return n}function bt(t,e,n){if(t=Float64Array.from(function*(t,e){if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(yield e);else{let n=-1;for(let r of t)null!=(r=e(r,++n,t))&&(r=+r)>=r&&(yield r)}}(t,n)),(r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return gt(t);if(e>=1)return pt(t);var r,i=(r-1)*e,o=Math.floor(i),a=pt(vt(t,o).subarray(0,o+1));return a+(gt(t.subarray(o+1))-a)*(i-o)}}function wt(t,e,n=s){if((r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return+n(t[0],0,t);if(e>=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,o=Math.floor(i),a=+n(t[o],o,t);return a+(+n(t[o+1],o+1,t)-a)*(i-o)}}function Mt(t,e,n=s){if(!isNaN(e=+e)){if(r=Float64Array.from(t,((e,r)=>s(n(t[r],r,t)))),e<=0)return yt(r);if(e>=1)return mt(r);var r,i=Uint32Array.from(t,((t,e)=>e)),o=r.length-1,a=Math.floor(o*e);return vt(i,a,0,o,((t,e)=>J(r[t],r[e]))),(a=_t(i.subarray(0,a+1),(t=>r[t])))>=0?a:-1}}function At(t,e,n){const r=_(t),i=bt(t,.75)-bt(t,.25);return r&&i?Math.ceil((n-e)/(2*i*Math.pow(r,-1/3))):1}function Tt(t,e,n){const r=_(t),i=C(t);return r&&i?Math.ceil((n-e)*Math.cbrt(r)/(3.49*i)):1}function Et(t,e){let n=0,r=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(++n,r+=e);else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(o=+o)>=o&&(++n,r+=o)}if(n)return r/n}function Ct(t,e){return bt(t,.5,e)}function kt(t,e){return Mt(t,.5,e)}function St(t){return Array.from(function*(t){for(const e of t)yield*e}(t))}function Ot(t,e){const n=new L;if(void 0===e)for(let e of t)null!=e&&e>=e&&n.set(e,(n.get(e)||0)+1);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&i>=i&&n.set(i,(n.get(i)||0)+1)}let r,i=0;for(const[t,e]of n)e>i&&(i=e,r=t);return r}function Pt(t,e=Lt){const n=[];let r,i=!1;for(const o of t)i&&n.push(e(r,o)),r=o,i=!0;return n}function Lt(t,e){return[t,e]}function Rt(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}function It(t,e=r){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");let n=Array.from(t);const i=new Float64Array(n.length);2!==e.length&&(n=n.map(e),e=r);const o=(t,r)=>e(n[t],n[r]);let a,s;return(t=Uint32Array.from(n,((t,e)=>e))).sort(e===r?(t,e)=>J(n[t],n[e]):Z(o)),t.forEach(((t,e)=>{const n=o(t,void 0===a?t:a);n>=0?((void 0===a||n>0)&&(a=t,s=e),i[t]=s):i[t]=NaN})),i}function Dt(t,e=r){let n,i=!1;if(1===e.length){let o;for(const a of t){const t=e(a);(i?r(t,o)<0:0===r(t,t))&&(n=a,o=t,i=!0)}}else for(const r of t)(i?e(r,n)<0:0===e(r,r))&&(n=r,i=!0);return n}function Nt(t,e=r){if(1===e.length)return yt(t,e);let n,i=-1,o=-1;for(const r of t)++o,(i<0?0===e(r,r):e(r,n)<0)&&(n=r,i=o);return i}function Ft(t,e=r){if(1===e.length)return mt(t,e);let n,i=-1,o=-1;for(const r of t)++o,(i<0?0===e(r,r):e(r,n)>0)&&(n=r,i=o);return i}function jt(t,e){const n=Nt(t,e);return n<0?void 0:n}var zt=Bt(Math.random);function Bt(t){return function(e,n=0,r=e.length){let i=r-(n=+n);for(;i;){const r=t()*i--|0,o=e[i+n];e[i+n]=e[r+n],e[r+n]=o}return e}}function Vt(t,e){let n=0;if(void 0===e)for(let e of t)(e=+e)&&(n+=e);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&(n+=i)}return n}function qt(t){if(!(i=t.length))return[];for(var e=-1,n=gt(t,Gt),r=new Array(n);++e<n;)for(var i,o=-1,a=r[e]=new Array(i);++o<i;)a[o]=t[o][e];return r}function Gt(t){return t.length}function Ut(){return qt(arguments)}function Ht(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");let n=-1;for(const r of t)if(!e(r,++n,t))return!1;return!0}function Wt(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");let n=-1;for(const r of t)if(e(r,++n,t))return!0;return!1}function Xt(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");const n=[];let r=-1;for(const i of t)e(i,++r,t)&&n.push(i);return n}function Kt(t,e){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");if("function"!=typeof e)throw new TypeError("mapper is not a function");return Array.from(t,((n,r)=>e(n,r,t)))}function Qt(t,e,n){if("function"!=typeof e)throw new TypeError("reducer is not a function");const r=t[Symbol.iterator]();let i,o,a=-1;if(arguments.length<3){if(({done:i,value:n}=r.next()),i)return;++a}for(;({done:i,value:o}=r.next()),!i;)n=e(n,o,++a,t);return n}function Yt(t){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");return Array.from(t).reverse()}function $t(t,...e){t=new R(t);for(const n of e)for(const e of n)t.delete(e);return t}function Zt(t,e){const n=e[Symbol.iterator](),r=new R;for(const e of t){if(r.has(e))return!1;let t,i;for(;({value:t,done:i}=n.next())&&!i;){if(Object.is(e,t))return!1;r.add(t)}}return!0}function Jt(t,...e){t=new R(t),e=e.map(te);t:for(const n of t)for(const r of e)if(!r.has(n)){t.delete(n);continue t}return t}function te(t){return t instanceof R?t:new R(t)}function ee(t,e){const n=t[Symbol.iterator](),r=new Set;for(const t of e){const e=ne(t);if(r.has(e))continue;let i,o;for(;({value:i,done:o}=n.next());){if(o)return!1;const t=ne(i);if(r.add(t),Object.is(e,t))break}}return!0}function ne(t){return null!==t&&"object"==typeof t?t.valueOf():t}function re(t,e){return ee(e,t)}function ie(...t){const e=new R;for(const n of t)for(const t of n)e.add(t);return e}function oe(t){return t}var ae=1,se=2,ue=3,le=4,ce=1e-6;function fe(t){return"translate("+t+",0)"}function he(t){return"translate(0,"+t+")"}function de(t){return e=>+t(e)}function pe(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function me(){return!this.__axis}function ge(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u="undefined"!=typeof window&&window.devicePixelRatio>1?0:.5,l=t===ae||t===le?-1:1,c=t===le||t===se?"x":"y",f=t===ae||t===ue?fe:he;function h(h){var d=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,p=null==i?e.tickFormat?e.tickFormat.apply(e,n):oe:i,m=Math.max(o,0)+s,g=e.range(),y=+g[0]+u,v=+g[g.length-1]+u,x=(e.bandwidth?pe:de)(e.copy(),u),_=h.selection?h.selection():h,b=_.selectAll(".domain").data([null]),w=_.selectAll(".tick").data(d,e).order(),M=w.exit(),A=w.enter().append("g").attr("class","tick"),T=w.select("line"),E=w.select("text");b=b.merge(b.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),w=w.merge(A),T=T.merge(A.append("line").attr("stroke","currentColor").attr(c+"2",l*o)),E=E.merge(A.append("text").attr("fill","currentColor").attr(c,l*m).attr("dy",t===ae?"0em":t===ue?"0.71em":"0.32em")),h!==_&&(b=b.transition(h),w=w.transition(h),T=T.transition(h),E=E.transition(h),M=M.transition(h).attr("opacity",ce).attr("transform",(function(t){return isFinite(t=x(t))?f(t+u):this.getAttribute("transform")})),A.attr("opacity",ce).attr("transform",(function(t){var e=this.parentNode.__axis;return f((e&&isFinite(e=e(t))?e:x(t))+u)}))),M.remove(),b.attr("d",t===le||t===se?a?"M"+l*a+","+y+"H"+u+"V"+v+"H"+l*a:"M"+u+","+y+"V"+v:a?"M"+y+","+l*a+"V"+u+"H"+v+"V"+l*a:"M"+y+","+u+"H"+v),w.attr("opacity",1).attr("transform",(function(t){return f(x(t)+u)})),T.attr(c+"2",l*o),E.attr(c,l*m).text(p),_.filter(me).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===se?"start":t===le?"end":"middle"),_.each((function(){this.__axis=x}))}return h.scale=function(t){return arguments.length?(e=t,h):e},h.ticks=function(){return n=Array.from(arguments),h},h.tickArguments=function(t){return arguments.length?(n=null==t?[]:Array.from(t),h):n.slice()},h.tickValues=function(t){return arguments.length?(r=null==t?null:Array.from(t),h):r&&r.slice()},h.tickFormat=function(t){return arguments.length?(i=t,h):i},h.tickSize=function(t){return arguments.length?(o=a=+t,h):o},h.tickSizeInner=function(t){return arguments.length?(o=+t,h):o},h.tickSizeOuter=function(t){return arguments.length?(a=+t,h):a},h.tickPadding=function(t){return arguments.length?(s=+t,h):s},h.offset=function(t){return arguments.length?(u=+t,h):u},h}function ye(t){return ge(ae,t)}function ve(t){return ge(se,t)}function xe(t){return ge(ue,t)}function _e(t){return ge(le,t)}var be={value:()=>{}};function we(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new Me(r)}function Me(t){this._=t}function Ae(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function Te(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=be,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}Me.prototype=we.prototype={constructor:Me,on:function(t,e){var n,r,i=this._,o=(r=i,(t+"").trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");if(n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}}))),a=-1,s=o.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++a<s;)if(n=(t=o[a]).type)i[n]=Te(i[n],t.name,e);else if(null==e)for(n in i)i[n]=Te(i[n],t.name,null);return this}for(;++a<s;)if((n=(t=o[a]).type)&&(n=Ae(i[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new Me(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(r=this._[t]).length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var Ee=we;function Ce(){}function ke(t){return null==t?Ce:function(){return this.querySelector(t)}}function Se(t){return null==t?[]:Array.isArray(t)?t:Array.from(t)}function Oe(){return[]}function Pe(t){return null==t?Oe:function(){return this.querySelectorAll(t)}}function Le(t){return function(){return this.matches(t)}}function Re(t){return function(e){return e.matches(t)}}var Ie=Array.prototype.find;function De(){return this.firstElementChild}var Ne=Array.prototype.filter;function Fe(){return Array.from(this.children)}function je(t){return new Array(t.length)}function ze(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function Be(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new ze(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function Ve(t,e,n,r,i,o,a){var s,u,l,c=new Map,f=e.length,h=o.length,d=new Array(f);for(s=0;s<f;++s)(u=e[s])&&(d[s]=l=a.call(u,u.__data__,s,e)+"",c.has(l)?i[s]=u:c.set(l,u));for(s=0;s<h;++s)l=a.call(t,o[s],s,o)+"",(u=c.get(l))?(r[s]=u,u.__data__=o[s],c.delete(l)):n[s]=new ze(t,o[s]);for(s=0;s<f;++s)(u=e[s])&&c.get(d[s])===u&&(i[s]=u)}function qe(t){return t.__data__}function Ge(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function Ue(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}ze.prototype={constructor:ze,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var He="http://www.w3.org/1999/xhtml",We={svg:"http://www.w3.org/2000/svg",xhtml:He,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Xe(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),We.hasOwnProperty(e)?{space:We[e],local:t}:t}function Ke(t){return function(){this.removeAttribute(t)}}function Qe(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ye(t,e){return function(){this.setAttribute(t,e)}}function $e(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Ze(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Je(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function tn(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function en(t){return function(){this.style.removeProperty(t)}}function nn(t,e,n){return function(){this.style.setProperty(t,e,n)}}function rn(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function on(t,e){return t.style.getPropertyValue(e)||tn(t).getComputedStyle(t,null).getPropertyValue(e)}function an(t){return function(){delete this[t]}}function sn(t,e){return function(){this[t]=e}}function un(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function ln(t){return t.trim().split(/^|\s+/)}function cn(t){return t.classList||new fn(t)}function fn(t){this._node=t,this._names=ln(t.getAttribute("class")||"")}function hn(t,e){for(var n=cn(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function dn(t,e){for(var n=cn(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function pn(t){return function(){hn(this,t)}}function mn(t){return function(){dn(this,t)}}function gn(t,e){return function(){(e.apply(this,arguments)?hn:dn)(this,t)}}function yn(){this.textContent=""}function vn(t){return function(){this.textContent=t}}function xn(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function _n(){this.innerHTML=""}function bn(t){return function(){this.innerHTML=t}}function wn(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function Mn(){this.nextSibling&&this.parentNode.appendChild(this)}function An(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Tn(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===He&&e.documentElement.namespaceURI===He?e.createElement(t):e.createElementNS(n,t)}}function En(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Cn(t){var e=Xe(t);return(e.local?En:Tn)(e)}function kn(){return null}function Sn(){var t=this.parentNode;t&&t.removeChild(this)}function On(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Pn(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Ln(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.options);++i?e.length=i:delete this.__on}}}function Rn(t,e,n){return function(){var r,i=this.__on,o=function(t){return function(e){t.call(this,e,this.__data__)}}(e);if(i)for(var a=0,s=i.length;a<s;++a)if((r=i[a]).type===t.type&&r.name===t.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),void(r.value=e);this.addEventListener(t.type,o,n),r={type:t.type,name:t.name,value:e,listener:o,options:n},i?i.push(r):this.__on=[r]}}function In(t,e,n){var r=tn(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function Dn(t,e){return function(){return In(this,t,e)}}function Nn(t,e){return function(){return In(this,t,e.apply(this,arguments))}}fn.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Fn=[null];function jn(t,e){this._groups=t,this._parents=e}function zn(){return new jn([[document.documentElement]],Fn)}jn.prototype=zn.prototype={constructor:jn,select:function(t){"function"!=typeof t&&(t=ke(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,l=r[i]=new Array(u),c=0;c<u;++c)(o=s[c])&&(a=t.call(o,o.__data__,c,s))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new jn(r,this._parents)},selectAll:function(t){t="function"==typeof t?function(t){return function(){return Se(t.apply(this,arguments))}}(t):Pe(t);for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new jn(r,i)},selectChild:function(t){return this.select(null==t?De:function(t){return function(){return Ie.call(this.children,t)}}("function"==typeof t?t:Re(t)))},selectChildren:function(t){return this.selectAll(null==t?Fe:function(t){return function(){return Ne.call(this.children,t)}}("function"==typeof t?t:Re(t)))},filter:function(t){"function"!=typeof t&&(t=Le(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new jn(r,this._parents)},data:function(t,e){if(!arguments.length)return Array.from(this,qe);var n=e?Ve:Be,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),l=0;l<o;++l){var c=r[l],f=i[l],h=f.length,d=Ge(t.call(c,c&&c.__data__,l,r)),p=d.length,m=s[l]=new Array(p),g=a[l]=new Array(p);n(c,f,m,g,u[l]=new Array(h),d,e);for(var y,v,x=0,_=0;x<p;++x)if(y=m[x]){for(x>=_&&(_=x+1);!(v=g[_])&&++_<p;);y._next=v||null}}return(a=new jn(a,r))._enter=s,a._exit=u,a},enter:function(){return new jn(this._enter||this._groups.map(je),this._parents)},exit:function(){return new jn(this._exit||this._groups.map(je),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return"function"==typeof t?(r=t(r))&&(r=r.selection()):r=r.append(t+""),null!=e&&(i=e(i))&&(i=i.selection()),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){for(var e=t.selection?t.selection():t,n=this._groups,r=e._groups,i=n.length,o=r.length,a=Math.min(i,o),s=new Array(i),u=0;u<a;++u)for(var l,c=n[u],f=r[u],h=c.length,d=s[u]=new Array(h),p=0;p<h;++p)(l=c[p]||f[p])&&(d[p]=l);for(;u<i;++u)s[u]=n[u];return new jn(s,this._parents)},selection:function(){return this},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Ue);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new jn(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){let t=0;for(const e of this)++t;return t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,e){var n=Xe(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?Qe:Ke:"function"==typeof e?n.local?Je:Ze:n.local?$e:Ye)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?en:"function"==typeof e?rn:nn)(t,e,null==n?"":n)):on(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?an:"function"==typeof e?un:sn)(t,e)):this.node()[t]},classed:function(t,e){var n=ln(t+"");if(arguments.length<2){for(var r=cn(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?gn:e?pn:mn)(n,e))},text:function(t){return arguments.length?this.each(null==t?yn:("function"==typeof t?xn:vn)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?_n:("function"==typeof t?wn:bn)(t)):this.node().innerHTML},raise:function(){return this.each(Mn)},lower:function(){return this.each(An)},append:function(t){var e="function"==typeof t?t:Cn(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:Cn(t),r=null==e?kn:"function"==typeof e?e:ke(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(Sn)},clone:function(t){return this.select(t?Pn:On)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=function(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?Rn:Ln,r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value},dispatch:function(t,e){return this.each(("function"==typeof e?Nn:Dn)(t,e))},[Symbol.iterator]:function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r,i=t[e],o=0,a=i.length;o<a;++o)(r=i[o])&&(yield r)}};var Bn=zn;function Vn(t){return"string"==typeof t?new jn([[document.querySelector(t)]],[document.documentElement]):new jn([[t]],Fn)}const qn={passive:!1},Gn={capture:!0,passive:!1};function Un(t){t.stopImmediatePropagation()}function Hn(t){t.preventDefault(),t.stopImmediatePropagation()}function Wn(t){var e=t.document.documentElement,n=Vn(t).on("dragstart.drag",Hn,Gn);"onselectstart"in e?n.on("selectstart.drag",Hn,Gn):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function Xn(t,e){var n=t.document.documentElement,r=Vn(t).on("dragstart.drag",null);e&&(r.on("click.drag",Hn,Gn),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Kn(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Qn(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Yn(){}var $n=.7,Zn=1/$n,Jn="\\s*([+-]?\\d+)\\s*",tr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",er="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",nr=/^#([0-9a-f]{3,8})$/,rr=new RegExp(`^rgb\\(${Jn},${Jn},${Jn}\\)$`),ir=new RegExp(`^rgb\\(${er},${er},${er}\\)$`),or=new RegExp(`^rgba\\(${Jn},${Jn},${Jn},${tr}\\)$`),ar=new RegExp(`^rgba\\(${er},${er},${er},${tr}\\)$`),sr=new RegExp(`^hsl\\(${tr},${er},${er}\\)$`),ur=new RegExp(`^hsla\\(${tr},${er},${er},${tr}\\)$`),lr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function cr(){return this.rgb().formatHex()}function fr(){return this.rgb().formatRgb()}function hr(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=nr.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?dr(e):3===n?new yr(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?pr(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?pr(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=rr.exec(t))?new yr(e[1],e[2],e[3],1):(e=ir.exec(t))?new yr(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=or.exec(t))?pr(e[1],e[2],e[3],e[4]):(e=ar.exec(t))?pr(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=sr.exec(t))?Mr(e[1],e[2]/100,e[3]/100,1):(e=ur.exec(t))?Mr(e[1],e[2]/100,e[3]/100,e[4]):lr.hasOwnProperty(t)?dr(lr[t]):"transparent"===t?new yr(NaN,NaN,NaN,0):null}function dr(t){return new yr(t>>16&255,t>>8&255,255&t,1)}function pr(t,e,n,r){return r<=0&&(t=e=n=NaN),new yr(t,e,n,r)}function mr(t){return t instanceof Yn||(t=hr(t)),t?new yr((t=t.rgb()).r,t.g,t.b,t.opacity):new yr}function gr(t,e,n,r){return 1===arguments.length?mr(t):new yr(t,e,n,null==r?1:r)}function yr(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function vr(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}`}function xr(){const t=_r(this.opacity);return`${1===t?"rgb(":"rgba("}${br(this.r)}, ${br(this.g)}, ${br(this.b)}${1===t?")":`, ${t})`}`}function _r(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function br(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function wr(t){return((t=br(t))<16?"0":"")+t.toString(16)}function Mr(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Er(t,e,n,r)}function Ar(t){if(t instanceof Er)return new Er(t.h,t.s,t.l,t.opacity);if(t instanceof Yn||(t=hr(t)),!t)return new Er;if(t instanceof Er)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new Er(a,s,u,t.opacity)}function Tr(t,e,n,r){return 1===arguments.length?Ar(t):new Er(t,e,n,null==r?1:r)}function Er(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function Cr(t){return(t=(t||0)%360)<0?t+360:t}function kr(t){return Math.max(0,Math.min(1,t||0))}function Sr(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function Or(t,e,n,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*r+a*i)/6}function Pr(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,s=r<e-1?t[r+2]:2*o-i;return Or((n-r/e)*e,a,i,o,s)}}function Lr(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),i=t[(r+e-1)%e],o=t[r%e],a=t[(r+1)%e],s=t[(r+2)%e];return Or((n-r/e)*e,i,o,a,s)}}Kn(Yn,hr,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:cr,formatHex:cr,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ar(this).formatHsl()},formatRgb:fr,toString:fr}),Kn(yr,gr,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new yr(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new yr(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new yr(br(this.r),br(this.g),br(this.b),_r(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:vr,formatHex:vr,formatHex8:function(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}${wr(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:xr,toString:xr})),Kn(Er,Tr,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new Er(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new Er(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new yr(Sr(t>=240?t-240:t+120,i,r),Sr(t,i,r),Sr(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new Er(Cr(this.h),kr(this.s),kr(this.l),_r(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=_r(this.opacity);return`${1===t?"hsl(":"hsla("}${Cr(this.h)}, ${100*kr(this.s)}%, ${100*kr(this.l)}%${1===t?")":`, ${t})`}`}}));var Rr=t=>()=>t;function Ir(t,e){return function(n){return t+n*e}}function Dr(t,e){var n=e-t;return n?Ir(t,n>180||n<-180?n-360*Math.round(n/360):n):Rr(isNaN(t)?e:t)}function Nr(t){return 1==(t=+t)?Fr:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):Rr(isNaN(e)?n:e)}}function Fr(t,e){var n=e-t;return n?Ir(t,n):Rr(isNaN(t)?e:t)}var jr=function t(e){var n=Nr(e);function r(t,e){var r=n((t=gr(t)).r,(e=gr(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=Fr(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function zr(t){return function(e){var n,r,i=e.length,o=new Array(i),a=new Array(i),s=new Array(i);for(n=0;n<i;++n)r=gr(e[n]),o[n]=r.r||0,a[n]=r.g||0,s[n]=r.b||0;return o=t(o),a=t(a),s=t(s),r.opacity=1,function(t){return r.r=o(t),r.g=a(t),r.b=s(t),r+""}}}var Br=zr(Pr),Vr=zr(Lr);function qr(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}}function Gr(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Ur(t,e){return(Gr(e)?qr:Hr)(t,e)}function Hr(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=Zr(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}function Wr(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function Xr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function Kr(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=Zr(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var Qr=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Yr=new RegExp(Qr.source,"g");function $r(t,e){var n,r,i,o=Qr.lastIndex=Yr.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=Qr.exec(t))&&(r=Yr.exec(e));)(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:Xr(n,r)})),o=Yr.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})}function Zr(t,e){var n,r=typeof e;return null==e||"boolean"===r?Rr(e):("number"===r?Xr:"string"===r?(n=hr(e))?(e=n,jr):$r:e instanceof hr?jr:e instanceof Date?Wr:Gr(e)?qr:Array.isArray(e)?Hr:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?Kr:Xr)(t,e)}function Jr(t){let e;for(;e=t.sourceEvent;)t=e;return t}function ti(t,e){if(t=Jr(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,[(r=r.matrixTransform(e.getScreenCTM().inverse())).x,r.y]}if(e.getBoundingClientRect){var i=e.getBoundingClientRect();return[t.clientX-i.left-e.clientLeft,t.clientY-i.top-e.clientTop]}}return[t.pageX,t.pageY]}var ei,ni,ri=0,ii=0,oi=0,ai=0,si=0,ui=0,li="object"==typeof performance&&performance.now?performance:Date,ci="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function fi(){return si||(ci(hi),si=li.now()+ui)}function hi(){si=0}function di(){this._call=this._time=this._next=null}function pi(t,e,n){var r=new di;return r.restart(t,e,n),r}function mi(){fi(),++ri;for(var t,e=ei;e;)(t=si-e._time)>=0&&e._call.call(void 0,t),e=e._next;--ri}function gi(){si=(ai=li.now())+ui,ri=ii=0;try{mi()}finally{ri=0,function(){var t,e,n=ei,r=1/0;for(;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:ei=e);ni=t,vi(r)}(),si=0}}function yi(){var t=li.now(),e=t-ai;e>1e3&&(ui-=e,ai=t)}function vi(t){ri||(ii&&(ii=clearTimeout(ii)),t-si>24?(t<1/0&&(ii=setTimeout(gi,t-li.now()-ui)),oi&&(oi=clearInterval(oi))):(oi||(ai=li.now(),oi=setInterval(yi,1e3)),ri=1,ci(gi)))}function xi(t,e,n){var r=new di;return e=null==e?0:+e,r.restart((n=>{r.stop(),t(n+e)}),e,n),r}di.prototype=pi.prototype={constructor:di,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?fi():+n)+(null==e?0:+e),this._next||ni===this||(ni?ni._next=this:ei=this,ni=this),this._call=t,this._time=n,vi()},stop:function(){this._call&&(this._call=null,this._time=1/0,vi())}};var _i=Ee("start","end","cancel","interrupt"),bi=[],wi=1,Mi=2,Ai=5,Ti=6;function Ei(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(t){n.state=wi,n.timer.restart(a,n.delay,n.time),n.delay<=t&&a(t-n.delay)}function a(o){var l,c,f,h;if(n.state!==wi)return u();for(l in i)if((h=i[l]).name===n.name){if(3===h.state)return xi(a);4===h.state?(h.state=Ti,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[l]):+l<e&&(h.state=Ti,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[l])}if(xi((function(){3===n.state&&(n.state=4,n.timer.restart(s,n.delay,n.time),s(o))})),n.state=Mi,n.on.call("start",t,t.__data__,n.index,n.group),n.state===Mi){for(n.state=3,r=new Array(f=n.tween.length),l=0,c=-1;l<f;++l)(h=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=h);r.length=c+1}}function s(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(u),n.state=Ai,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);n.state===Ai&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){for(var r in n.state=Ti,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=pi(o,0,n.time)}(t,n,{name:e,index:r,group:i,on:_i,tween:bi,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Ci(t,e){var n=Si(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function ki(t,e){var n=Si(t,e);if(n.state>3)throw new Error("too late; already running");return n}function Si(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Oi(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>Mi&&n.state<Ai,n.state=Ti,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}}var Pi,Li=180/Math.PI,Ri={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Ii(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*Li,skewX:Math.atan(u)*Li,scaleX:a,scaleY:s}}function Di(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:Xr(t,i)},{i:u-2,x:Xr(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:Xr(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:Xr(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Xr(t,n)},{i:s-2,x:Xr(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var Ni=Di((function(t){const e=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Ri:Ii(e.a,e.b,e.c,e.d,e.e,e.f)}),"px, ","px)","deg)"),Fi=Di((function(t){return null==t?Ri:(Pi||(Pi=document.createElementNS("http://www.w3.org/2000/svg","g")),Pi.setAttribute("transform",t),(t=Pi.transform.baseVal.consolidate())?Ii((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Ri)}),", ",")",")");function ji(t,e){var n,r;return function(){var i=ki(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function zi(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=ki(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}}function Bi(t,e,n){var r=t._id;return t.each((function(){var t=ki(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return Si(t,r).value[e]}}function Vi(t,e){var n;return("number"==typeof e?Xr:e instanceof hr?jr:(n=hr(e))?(e=n,jr):$r)(t,e)}function qi(t){return function(){this.removeAttribute(t)}}function Gi(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ui(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function Hi(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function Wi(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttribute(t))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function Xi(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttributeNS(t.space,t.local))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Ki(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&function(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}(t,i)),n}return i._value=e,i}function Qi(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&function(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}(t,i)),n}return i._value=e,i}function Yi(t,e){return function(){Ci(this,t).delay=+e.apply(this,arguments)}}function $i(t,e){return e=+e,function(){Ci(this,t).delay=e}}function Zi(t,e){return function(){ki(this,t).duration=+e.apply(this,arguments)}}function Ji(t,e){return e=+e,function(){ki(this,t).duration=e}}var to=Bn.prototype.constructor;function eo(t){return function(){this.style.removeProperty(t)}}var no=0;function ro(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function io(t){return Bn().transition(t)}function oo(){return++no}var ao=Bn.prototype;function so(t){return t*t*t}function uo(t){return--t*t*t+1}function lo(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}ro.prototype=io.prototype={constructor:ro,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=ke(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,l=r[a],c=l.length,f=o[a]=new Array(c),h=0;h<c;++h)(s=l[h])&&(u=t.call(s,s.__data__,h,l))&&("__data__"in s&&(u.__data__=s.__data__),f[h]=u,Ei(f[h],e,n,h,f,Si(s,n)));return new ro(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Pe(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,l=r[s],c=l.length,f=0;f<c;++f)if(u=l[f]){for(var h,d=t.call(u,u.__data__,f,l),p=Si(u,n),m=0,g=d.length;m<g;++m)(h=d[m])&&Ei(h,e,n,m,d,p);o.push(d),a.push(u)}return new ro(o,a,e,n)},selectChild:ao.selectChild,selectChildren:ao.selectChildren,filter:function(t){"function"!=typeof t&&(t=Le(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new ro(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new ro(a,this._parents,this._name,this._id)},selection:function(){return new to(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=oo(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=Si(a,e);Ei(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new ro(r,this._parents,t,n)},call:ao.call,nodes:ao.nodes,node:ao.node,size:ao.size,empty:ao.empty,each:ao.each,on:function(t,e){var n=this._id;return arguments.length<2?Si(this.node(),n).on.on(t):this.each(function(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?Ci:ki;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}(n,t,e))},attr:function(t,e){var n=Xe(t),r="transform"===n?Fi:Vi;return this.attrTween(t,"function"==typeof e?(n.local?Xi:Wi)(n,r,Bi(this,"attr."+t,e)):null==e?(n.local?Gi:qi)(n):(n.local?Hi:Ui)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=Xe(t);return this.tween(n,(r.local?Ki:Qi)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?Ni:Vi;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=on(this,t),a=(this.style.removeProperty(t),on(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,eo(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=on(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=on(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,Bi(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=ki(this,t),l=u.on,c=null==u.value[a]?o||(o=eo(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=on(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,function(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&function(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}(t,o,n)),r}return o._value=e,o}(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(Bi(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,function(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&function(t){return function(e){this.textContent=t.call(this,e)}}(r)),e}return r._value=t,r}(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=Si(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?ji:zi)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Yi:$i)(e,t)):Si(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Zi:Ji)(e,t)):Si(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(function(t,e){if("function"!=typeof e)throw new Error;return function(){ki(this,t).ease=e}}(e,t)):Si(this.node(),e).ease},easeVarying:function(t){if("function"!=typeof t)throw new Error;return this.each(function(t,e){return function(){var n=e.apply(this,arguments);if("function"!=typeof n)throw new Error;ki(this,t).ease=n}}(this._id,t))},end:function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0==--i&&o()}};n.each((function(){var n=ki(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e})),0===i&&o()}))},[Symbol.iterator]:ao[Symbol.iterator]};var co={time:null,delay:0,duration:250,ease:lo};function fo(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}Bn.prototype.interrupt=function(t){return this.each((function(){Oi(this,t)}))},Bn.prototype.transition=function(t){var e,n;t instanceof ro?(e=t._id,t=t._name):(e=oo(),(n=co).time=fi(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&Ei(a,t,e,l,s,n||fo(a,e));return new ro(r,this._parents,t,e)};var ho=[null];function po(t,e){var n,r,i=t.__transition;if(i)for(r in e=null==e?null:e+"",i)if((n=i[r]).state>wi&&n.name===e)return new ro([[t]],ho,e,+r);return null}var mo=t=>()=>t;function go(t,{sourceEvent:e,target:n,selection:r,mode:i,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function yo(t){t.preventDefault(),t.stopImmediatePropagation()}var vo={name:"drag"},xo={name:"space"},_o={name:"handle"},bo={name:"center"};const{abs:wo,max:Mo,min:Ao}=Math;function To(t){return[+t[0],+t[1]]}function Eo(t){return[To(t[0]),To(t[1])]}var Co={name:"x",handles:["w","e"].map(Do),input:function(t,e){return null==t?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},ko={name:"y",handles:["n","s"].map(Do),input:function(t,e){return null==t?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},So={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(Do),input:function(t){return null==t?null:Eo(t)},output:function(t){return t}},Oo={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},Po={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},Lo={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},Ro={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Io={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Do(t){return{type:t}}function No(t){return!t.ctrlKey&&!t.button}function Fo(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function jo(){return navigator.maxTouchPoints||"ontouchstart"in this}function zo(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function Bo(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Vo(){return Uo(Co)}function qo(){return Uo(ko)}function Go(){return Uo(So)}function Uo(t){var e,n=Fo,r=No,i=jo,o=!0,a=Ee("start","brush","end"),s=6;function u(e){var n=e.property("__brush",m).selectAll(".overlay").data([Do("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",Oo.overlay).merge(n).each((function(){var t=zo(this).extent;Vn(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([Do("selection")]).enter().append("rect").attr("class","selection").attr("cursor",Oo.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var r=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));r.exit().remove(),r.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return Oo[t.type]})),e.each(l).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(i).on("touchstart.brush",h).on("touchmove.brush",d).on("touchend.brush touchcancel.brush",p).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function l(){var t=Vn(this),e=zo(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-s/2:e[0][0]-s/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-s/2:e[0][1]-s/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+s:s})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+s:s}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function c(t,e,n){var r=t.__brush.emitter;return!r||n&&r.clean?new f(t,e,n):r}function f(t,e,n){this.that=t,this.args=e,this.state=t.__brush,this.active=0,this.clean=n}function h(n){if((!e||n.touches)&&r.apply(this,arguments)){var i,a,s,u,f,h,d,p,m,g,y,v=this,x=n.target.__data__.type,_="selection"===(o&&n.metaKey?x="overlay":x)?vo:o&&n.altKey?bo:_o,b=t===ko?null:Ro[x],w=t===Co?null:Io[x],M=zo(v),A=M.extent,T=M.selection,E=A[0][0],C=A[0][1],k=A[1][0],S=A[1][1],O=0,P=0,L=b&&w&&o&&n.shiftKey,R=Array.from(n.touches||[n],(t=>{const e=t.identifier;return(t=ti(t,v)).point0=t.slice(),t.identifier=e,t}));Oi(v);var I=c(v,arguments,!0).beforestart();if("overlay"===x){T&&(m=!0);const e=[R[0],R[1]||R[0]];M.selection=T=[[i=t===ko?E:Ao(e[0][0],e[1][0]),s=t===Co?C:Ao(e[0][1],e[1][1])],[f=t===ko?k:Mo(e[0][0],e[1][0]),d=t===Co?S:Mo(e[0][1],e[1][1])]],R.length>1&&z(n)}else i=T[0][0],s=T[0][1],f=T[1][0],d=T[1][1];a=i,u=s,h=f,p=d;var D=Vn(v).attr("pointer-events","none"),N=D.selectAll(".overlay").attr("cursor",Oo[x]);if(n.touches)I.moved=j,I.ended=B;else{var F=Vn(n.view).on("mousemove.brush",j,!0).on("mouseup.brush",B,!0);o&&F.on("keydown.brush",(function(t){switch(t.keyCode){case 16:L=b&&w;break;case 18:_===_o&&(b&&(f=h-O*b,i=a+O*b),w&&(d=p-P*w,s=u+P*w),_=bo,z(t));break;case 32:_!==_o&&_!==bo||(b<0?f=h-O:b>0&&(i=a-O),w<0?d=p-P:w>0&&(s=u-P),_=xo,N.attr("cursor",Oo.selection),z(t));break;default:return}yo(t)}),!0).on("keyup.brush",(function(t){switch(t.keyCode){case 16:L&&(g=y=L=!1,z(t));break;case 18:_===bo&&(b<0?f=h:b>0&&(i=a),w<0?d=p:w>0&&(s=u),_=_o,z(t));break;case 32:_===xo&&(t.altKey?(b&&(f=h-O*b,i=a+O*b),w&&(d=p-P*w,s=u+P*w),_=bo):(b<0?f=h:b>0&&(i=a),w<0?d=p:w>0&&(s=u),_=_o),N.attr("cursor",Oo[x]),z(t));break;default:return}yo(t)}),!0),Wn(n.view)}l.call(v),I.start(n,_.name)}function j(t){for(const e of t.changedTouches||[t])for(const t of R)t.identifier===e.identifier&&(t.cur=ti(e,v));if(L&&!g&&!y&&1===R.length){const t=R[0];wo(t.cur[0]-t[0])>wo(t.cur[1]-t[1])?y=!0:g=!0}for(const t of R)t.cur&&(t[0]=t.cur[0],t[1]=t.cur[1]);m=!0,yo(t),z(t)}function z(t){const e=R[0],n=e.point0;var r;switch(O=e[0]-n[0],P=e[1]-n[1],_){case xo:case vo:b&&(O=Mo(E-i,Ao(k-f,O)),a=i+O,h=f+O),w&&(P=Mo(C-s,Ao(S-d,P)),u=s+P,p=d+P);break;case _o:R[1]?(b&&(a=Mo(E,Ao(k,R[0][0])),h=Mo(E,Ao(k,R[1][0])),b=1),w&&(u=Mo(C,Ao(S,R[0][1])),p=Mo(C,Ao(S,R[1][1])),w=1)):(b<0?(O=Mo(E-i,Ao(k-i,O)),a=i+O,h=f):b>0&&(O=Mo(E-f,Ao(k-f,O)),a=i,h=f+O),w<0?(P=Mo(C-s,Ao(S-s,P)),u=s+P,p=d):w>0&&(P=Mo(C-d,Ao(S-d,P)),u=s,p=d+P));break;case bo:b&&(a=Mo(E,Ao(k,i-O*b)),h=Mo(E,Ao(k,f+O*b))),w&&(u=Mo(C,Ao(S,s-P*w)),p=Mo(C,Ao(S,d+P*w)))}h<a&&(b*=-1,r=i,i=f,f=r,r=a,a=h,h=r,x in Po&&N.attr("cursor",Oo[x=Po[x]])),p<u&&(w*=-1,r=s,s=d,d=r,r=u,u=p,p=r,x in Lo&&N.attr("cursor",Oo[x=Lo[x]])),M.selection&&(T=M.selection),g&&(a=T[0][0],h=T[1][0]),y&&(u=T[0][1],p=T[1][1]),T[0][0]===a&&T[0][1]===u&&T[1][0]===h&&T[1][1]===p||(M.selection=[[a,u],[h,p]],l.call(v),I.brush(t,_.name))}function B(t){if(function(t){t.stopImmediatePropagation()}(t),t.touches){if(t.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500)}else Xn(t.view,m),F.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);D.attr("pointer-events","all"),N.attr("cursor",Oo.overlay),M.selection&&(T=M.selection),function(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}(T)&&(M.selection=null,l.call(v)),I.end(t,_.name)}}function d(t){c(this,arguments).moved(t)}function p(t){c(this,arguments).ended(t)}function m(){var e=this.__brush||{selection:null};return e.extent=Eo(n.apply(this,arguments)),e.dim=t,e}return u.move=function(e,n,r){e.tween?e.on("start.brush",(function(t){c(this,arguments).beforestart().start(t)})).on("interrupt.brush end.brush",(function(t){c(this,arguments).end(t)})).tween("brush",(function(){var e=this,r=e.__brush,i=c(e,arguments),o=r.selection,a=t.input("function"==typeof n?n.apply(this,arguments):n,r.extent),s=Zr(o,a);function u(t){r.selection=1===t&&null===a?null:s(t),l.call(e),i.brush()}return null!==o&&null!==a?u:u(1)})):e.each((function(){var e=this,i=arguments,o=e.__brush,a=t.input("function"==typeof n?n.apply(e,i):n,o.extent),s=c(e,i).beforestart();Oi(e),o.selection=null===a?null:a,l.call(e),s.start(r).brush(r).end(r)}))},u.clear=function(t,e){u.move(t,null,e)},f.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(t,e){return this.starting?(this.starting=!1,this.emit("start",t,e)):this.emit("brush",t),this},brush:function(t,e){return this.emit("brush",t,e),this},end:function(t,e){return 0==--this.active&&(delete this.state.emitter,this.emit("end",t,e)),this},emit:function(e,n,r){var i=Vn(this.that).datum();a.call(e,this.that,new go(e,{sourceEvent:n,target:u,selection:t.output(this.state.selection),mode:r,dispatch:a}),i)}},u.extent=function(t){return arguments.length?(n="function"==typeof t?t:mo(Eo(t)),u):n},u.filter=function(t){return arguments.length?(r="function"==typeof t?t:mo(!!t),u):r},u.touchable=function(t){return arguments.length?(i="function"==typeof t?t:mo(!!t),u):i},u.handleSize=function(t){return arguments.length?(s=+t,u):s},u.keyModifiers=function(t){return arguments.length?(o=!!t,u):o},u.on=function(){var t=a.on.apply(a,arguments);return t===a?u:t},u}var Ho=Math.abs,Wo=Math.cos,Xo=Math.sin,Ko=Math.PI,Qo=Ko/2,Yo=2*Ko,$o=Math.max,Zo=1e-12;function Jo(t,e){return Array.from({length:e-t},((e,n)=>t+n))}function ta(){return ra(!1,!1)}function ea(){return ra(!1,!0)}function na(){return ra(!0,!1)}function ra(t,e){var n=0,r=null,i=null,o=null;function a(a){var s,u=a.length,l=new Array(u),c=Jo(0,u),f=new Array(u*u),h=new Array(u),d=0;a=Float64Array.from({length:u*u},e?(t,e)=>a[e%u][e/u|0]:(t,e)=>a[e/u|0][e%u]);for(let e=0;e<u;++e){let n=0;for(let r=0;r<u;++r)n+=a[e*u+r]+t*a[r*u+e];d+=l[e]=n}s=(d=$o(0,Yo-n*u)/d)?n:Yo/u;{let e=0;r&&c.sort(((t,e)=>r(l[t],l[e])));for(const n of c){const r=e;if(t){const t=Jo(1+~u,u).filter((t=>t<0?a[~t*u+n]:a[n*u+t]));i&&t.sort(((t,e)=>i(t<0?-a[~t*u+n]:a[n*u+t],e<0?-a[~e*u+n]:a[n*u+e])));for(const r of t)if(r<0){(f[~r*u+n]||(f[~r*u+n]={source:null,target:null})).target={index:n,startAngle:e,endAngle:e+=a[~r*u+n]*d,value:a[~r*u+n]}}else{(f[n*u+r]||(f[n*u+r]={source:null,target:null})).source={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]}}h[n]={index:n,startAngle:r,endAngle:e,value:l[n]}}else{const t=Jo(0,u).filter((t=>a[n*u+t]||a[t*u+n]));i&&t.sort(((t,e)=>i(a[n*u+t],a[n*u+e])));for(const r of t){let t;if(n<r?(t=f[n*u+r]||(f[n*u+r]={source:null,target:null}),t.source={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]}):(t=f[r*u+n]||(f[r*u+n]={source:null,target:null}),t.target={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]},n===r&&(t.source=t.target)),t.source&&t.target&&t.source.value<t.target.value){const e=t.source;t.source=t.target,t.target=e}}h[n]={index:n,startAngle:r,endAngle:e,value:l[n]}}e+=s}}return(f=Object.values(f)).groups=h,o?f.sort(o):f}return a.padAngle=function(t){return arguments.length?(n=$o(0,t),a):n},a.sortGroups=function(t){return arguments.length?(r=t,a):r},a.sortSubgroups=function(t){return arguments.length?(i=t,a):i},a.sortChords=function(t){return arguments.length?(null==t?o=null:(e=t,o=function(t,n){return e(t.source.value+t.target.value,n.source.value+n.target.value)})._=t,a):o&&o._;var e},a}const ia=Math.PI,oa=2*ia,aa=1e-6,sa=oa-aa;function ua(t){this._+=t[0];for(let e=1,n=t.length;e<n;++e)this._+=arguments[e]+t[e]}class la{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==t?ua:function(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return ua;const n=10**e;return function(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=Math.round(arguments[e]*n)/n+t[e]}}(t)}moveTo(t,e){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,e){this._append`L${this._x1=+t},${this._y1=+e}`}quadraticCurveTo(t,e,n,r){this._append`Q${+t},${+e},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(t,e,n,r,i,o){this._append`C${+t},${+e},${+n},${+r},${this._x1=+i},${this._y1=+o}`}arcTo(t,e,n,r,i){if(t=+t,e=+e,n=+n,r=+r,(i=+i)<0)throw new Error(`negative radius: ${i}`);let o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,f=l*l+c*c;if(null===this._x1)this._append`M${this._x1=t},${this._y1=e}`;else if(f>aa)if(Math.abs(c*s-u*l)>aa&&i){let h=n-o,d=r-a,p=s*s+u*u,m=h*h+d*d,g=Math.sqrt(p),y=Math.sqrt(f),v=i*Math.tan((ia-Math.acos((p+f-m)/(2*g*y)))/2),x=v/y,_=v/g;Math.abs(x-1)>aa&&this._append`L${t+x*l},${e+x*c}`,this._append`A${i},${i},0,0,${+(c*h>l*d)},${this._x1=t+_*s},${this._y1=e+_*u}`}else this._append`L${this._x1=t},${this._y1=e}`;else;}arc(t,e,n,r,i,o){if(t=+t,e=+e,o=!!o,(n=+n)<0)throw new Error(`negative radius: ${n}`);let a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,f=o?r-i:i-r;null===this._x1?this._append`M${u},${l}`:(Math.abs(this._x1-u)>aa||Math.abs(this._y1-l)>aa)&&this._append`L${u},${l}`,n&&(f<0&&(f=f%oa+oa),f>sa?this._append`A${n},${n},0,1,${c},${t-a},${e-s}A${n},${n},0,1,${c},${this._x1=u},${this._y1=l}`:f>aa&&this._append`A${n},${n},0,${+(f>=ia)},${c},${this._x1=t+n*Math.cos(i)},${this._y1=e+n*Math.sin(i)}`)}rect(t,e,n,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}}function ca(){return new la}function fa(t=3){return new la(+t)}ca.prototype=la.prototype;var ha=Array.prototype.slice;function da(t){return function(){return t}}function pa(t){return t.source}function ma(t){return t.target}function ga(t){return t.radius}function ya(t){return t.startAngle}function va(t){return t.endAngle}function xa(){return 0}function _a(){return 10}function ba(t){var e=pa,n=ma,r=ga,i=ga,o=ya,a=va,s=xa,u=null;function l(){var l,c=e.apply(this,arguments),f=n.apply(this,arguments),h=s.apply(this,arguments)/2,d=ha.call(arguments),p=+r.apply(this,(d[0]=c,d)),m=o.apply(this,d)-Qo,g=a.apply(this,d)-Qo,y=+i.apply(this,(d[0]=f,d)),v=o.apply(this,d)-Qo,x=a.apply(this,d)-Qo;if(u||(u=l=ca()),h>Zo&&(Ho(g-m)>2*h+Zo?g>m?(m+=h,g-=h):(m-=h,g+=h):m=g=(m+g)/2,Ho(x-v)>2*h+Zo?x>v?(v+=h,x-=h):(v-=h,x+=h):v=x=(v+x)/2),u.moveTo(p*Wo(m),p*Xo(m)),u.arc(0,0,p,m,g),m!==v||g!==x)if(t){var _=y-+t.apply(this,arguments),b=(v+x)/2;u.quadraticCurveTo(0,0,_*Wo(v),_*Xo(v)),u.lineTo(y*Wo(b),y*Xo(b)),u.lineTo(_*Wo(x),_*Xo(x))}else u.quadraticCurveTo(0,0,y*Wo(v),y*Xo(v)),u.arc(0,0,y,v,x);if(u.quadraticCurveTo(0,0,p*Wo(m),p*Xo(m)),u.closePath(),l)return u=null,l+""||null}return t&&(l.headRadius=function(e){return arguments.length?(t="function"==typeof e?e:da(+e),l):t}),l.radius=function(t){return arguments.length?(r=i="function"==typeof t?t:da(+t),l):r},l.sourceRadius=function(t){return arguments.length?(r="function"==typeof t?t:da(+t),l):r},l.targetRadius=function(t){return arguments.length?(i="function"==typeof t?t:da(+t),l):i},l.startAngle=function(t){return arguments.length?(o="function"==typeof t?t:da(+t),l):o},l.endAngle=function(t){return arguments.length?(a="function"==typeof t?t:da(+t),l):a},l.padAngle=function(t){return arguments.length?(s="function"==typeof t?t:da(+t),l):s},l.source=function(t){return arguments.length?(e=t,l):e},l.target=function(t){return arguments.length?(n=t,l):n},l.context=function(t){return arguments.length?(u=null==t?null:t,l):u},l}function wa(){return ba()}function Ma(){return ba(_a)}const Aa=Math.PI/180,Ta=180/Math.PI,Ea=.96422,Ca=1,ka=.82521,Sa=4/29,Oa=6/29,Pa=3*Oa*Oa,La=Oa*Oa*Oa;function Ra(t){if(t instanceof Na)return new Na(t.l,t.a,t.b,t.opacity);if(t instanceof Ua)return Ha(t);t instanceof yr||(t=mr(t));var e,n,r=Ba(t.r),i=Ba(t.g),o=Ba(t.b),a=Fa((.2225045*r+.7168786*i+.0606169*o)/Ca);return r===i&&i===o?e=n=a:(e=Fa((.4360747*r+.3850649*i+.1430804*o)/Ea),n=Fa((.0139322*r+.0971045*i+.7141733*o)/ka)),new Na(116*a-16,500*(e-a),200*(a-n),t.opacity)}function Ia(t,e){return new Na(t,0,0,null==e?1:e)}function Da(t,e,n,r){return 1===arguments.length?Ra(t):new Na(t,e,n,null==r?1:r)}function Na(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}function Fa(t){return t>La?Math.pow(t,1/3):t/Pa+Sa}function ja(t){return t>Oa?t*t*t:Pa*(t-Sa)}function za(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Ba(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Va(t){if(t instanceof Ua)return new Ua(t.h,t.c,t.l,t.opacity);if(t instanceof Na||(t=Ra(t)),0===t.a&&0===t.b)return new Ua(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*Ta;return new Ua(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function qa(t,e,n,r){return 1===arguments.length?Va(t):new Ua(n,e,t,null==r?1:r)}function Ga(t,e,n,r){return 1===arguments.length?Va(t):new Ua(t,e,n,null==r?1:r)}function Ua(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}function Ha(t){if(isNaN(t.h))return new Na(t.l,0,0,t.opacity);var e=t.h*Aa;return new Na(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}Kn(Na,Da,Qn(Yn,{brighter(t){return new Na(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker(t){return new Na(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new yr(za(3.1338561*(e=Ea*ja(e))-1.6168667*(t=Ca*ja(t))-.4906146*(n=ka*ja(n))),za(-.9787684*e+1.9161415*t+.033454*n),za(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),Kn(Ua,Ga,Qn(Yn,{brighter(t){return new Ua(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker(t){return new Ua(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb(){return Ha(this).rgb()}}));var Wa=-.14861,Xa=1.78277,Ka=-.29227,Qa=-.90649,Ya=1.97294,$a=Ya*Qa,Za=Ya*Xa,Ja=Xa*Ka-Qa*Wa;function ts(t,e,n,r){return 1===arguments.length?function(t){if(t instanceof es)return new es(t.h,t.s,t.l,t.opacity);t instanceof yr||(t=mr(t));var e=t.r/255,n=t.g/255,r=t.b/255,i=(Ja*r+$a*e-Za*n)/(Ja+$a-Za),o=r-i,a=(Ya*(n-i)-Ka*o)/Qa,s=Math.sqrt(a*a+o*o)/(Ya*i*(1-i)),u=s?Math.atan2(a,o)*Ta-120:NaN;return new es(u<0?u+360:u,s,i,t.opacity)}(t):new es(t,e,n,null==r?1:r)}function es(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}Kn(es,ts,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new es(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new es(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=isNaN(this.h)?0:(this.h+120)*Aa,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),r=Math.cos(t),i=Math.sin(t);return new yr(255*(e+n*(Wa*r+Xa*i)),255*(e+n*(Ka*r+Qa*i)),255*(e+n*(Ya*r)),this.opacity)}}));var ns=Array.prototype.slice;function rs(t,e){return t-e}var is=t=>()=>t;function os(t,e){for(var n,r=-1,i=e.length;++r<i;)if(n=as(t,e[r]))return n;return 0}function as(t,e){for(var n=e[0],r=e[1],i=-1,o=0,a=t.length,s=a-1;o<a;s=o++){var u=t[o],l=u[0],c=u[1],f=t[s],h=f[0],d=f[1];if(ss(u,f,e))return 0;c>r!=d>r&&n<(h-l)*(r-c)/(d-c)+l&&(i=-i)}return i}function ss(t,e,n){var r,i,o,a;return function(t,e,n){return(e[0]-t[0])*(n[1]-t[1])==(n[0]-t[0])*(e[1]-t[1])}(t,e,n)&&(i=t[r=+(t[0]===e[0])],o=n[r],a=e[r],i<=o&&o<=a||a<=o&&o<=i)}function us(){}var ls=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]];function cs(){var t=1,e=1,n=ht,r=s;function i(t){var e=n(t);if(Array.isArray(e))e=e.slice().sort(rs);else{const n=k(t,fs);for(e=ut(...ft(n[0],n[1],e),e);e[e.length-1]>=n[1];)e.pop();for(;e[1]<n[0];)e.shift()}return e.map((e=>o(t,e)))}function o(n,i){const o=null==i?NaN:+i;if(isNaN(o))throw new Error(`invalid value: ${i}`);var s=[],u=[];return function(n,r,i){var o,s,u,l,c,f,h=new Array,d=new Array;o=s=-1,l=hs(n[0],r),ls[l<<1].forEach(p);for(;++o<t-1;)u=l,l=hs(n[o+1],r),ls[u|l<<1].forEach(p);ls[l|0].forEach(p);for(;++s<e-1;){for(o=-1,l=hs(n[s*t+t],r),c=hs(n[s*t],r),ls[l<<1|c<<2].forEach(p);++o<t-1;)u=l,l=hs(n[s*t+t+o+1],r),f=c,c=hs(n[s*t+o+1],r),ls[u|l<<1|c<<2|f<<3].forEach(p);ls[l|c<<3].forEach(p)}o=-1,c=n[s*t]>=r,ls[c<<2].forEach(p);for(;++o<t-1;)f=c,c=hs(n[s*t+o+1],r),ls[c<<2|f<<3].forEach(p);function p(t){var e,n,r=[t[0][0]+o,t[0][1]+s],u=[t[1][0]+o,t[1][1]+s],l=a(r),c=a(u);(e=d[l])?(n=h[c])?(delete d[e.end],delete h[n.start],e===n?(e.ring.push(u),i(e.ring)):h[e.start]=d[n.end]={start:e.start,end:n.end,ring:e.ring.concat(n.ring)}):(delete d[e.end],e.ring.push(u),d[e.end=c]=e):(e=h[c])?(n=d[l])?(delete h[e.start],delete d[n.end],e===n?(e.ring.push(u),i(e.ring)):h[n.start]=d[e.end]={start:n.start,end:e.end,ring:n.ring.concat(e.ring)}):(delete h[e.start],e.ring.unshift(r),h[e.start=l]=e):h[l]=d[c]={start:l,end:c,ring:[r,u]}}ls[c<<3].forEach(p)}(n,o,(function(t){r(t,n,o),function(t){for(var e=0,n=t.length,r=t[n-1][1]*t[0][0]-t[n-1][0]*t[0][1];++e<n;)r+=t[e-1][1]*t[e][0]-t[e-1][0]*t[e][1];return r}(t)>0?s.push([t]):u.push(t)})),u.forEach((function(t){for(var e,n=0,r=s.length;n<r;++n)if(-1!==os((e=s[n])[0],t))return void e.push(t)})),{type:"MultiPolygon",value:i,coordinates:s}}function a(e){return 2*e[0]+e[1]*(t+1)*4}function s(n,r,i){n.forEach((function(n){var o=n[0],a=n[1],s=0|o,u=0|a,l=ds(r[u*t+s]);o>0&&o<t&&s===o&&(n[0]=ps(o,ds(r[u*t+s-1]),l,i)),a>0&&a<e&&u===a&&(n[1]=ps(a,ds(r[(u-1)*t+s]),l,i))}))}return i.contour=o,i.size=function(n){if(!arguments.length)return[t,e];var r=Math.floor(n[0]),o=Math.floor(n[1]);if(!(r>=0&&o>=0))throw new Error("invalid size");return t=r,e=o,i},i.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?is(ns.call(t)):is(t),i):n},i.smooth=function(t){return arguments.length?(r=t?s:us,i):r===s},i}function fs(t){return isFinite(t)?t:NaN}function hs(t,e){return null!=t&&+t>=e}function ds(t){return null==t||isNaN(t=+t)?-1/0:t}function ps(t,e,n,r){const i=r-e,o=n-e,a=isFinite(i)||isFinite(o)?i/o:Math.sign(i)/Math.sign(o);return isNaN(a)?t:t+a-.5}function ms(t){return t[0]}function gs(t){return t[1]}function ys(){return 1}function vs(){var t=ms,e=gs,n=ys,r=960,i=500,o=20,a=2,s=3*o,u=r+2*s>>a,l=i+2*s>>a,c=is(20);function f(r){var i=new Float32Array(u*l),c=Math.pow(2,-a),f=-1;for(const o of r){var h=(t(o,++f,r)+s)*c,d=(e(o,f,r)+s)*c,m=+n(o,f,r);if(m&&h>=0&&h<u&&d>=0&&d<l){var g=Math.floor(h),y=Math.floor(d),v=h-g-.5,x=d-y-.5;i[g+y*u]+=(1-v)*(1-x)*m,i[g+1+y*u]+=v*(1-x)*m,i[g+1+(y+1)*u]+=v*x*m,i[g+(y+1)*u]+=(1-v)*x*m}}return p({data:i,width:u,height:l},o*c),i}function h(t){var e=f(t),n=c(e),r=Math.pow(2,2*a);return Array.isArray(n)||(n=ut(Number.MIN_VALUE,pt(e)/r,n)),cs().size([u,l]).thresholds(n.map((t=>t*r)))(e).map(((t,e)=>(t.value=+n[e],d(t))))}function d(t){return t.coordinates.forEach(m),t}function m(t){t.forEach(g)}function g(t){t.forEach(y)}function y(t){t[0]=t[0]*Math.pow(2,a)-s,t[1]=t[1]*Math.pow(2,a)-s}function v(){return u=r+2*(s=3*o)>>a,l=i+2*s>>a,h}return h.contours=function(t){var e=f(t),n=cs().size([u,l]),r=Math.pow(2,2*a),i=t=>{t=+t;var i=d(n.contour(e,t*r));return i.value=t,i};return Object.defineProperty(i,"max",{get:()=>pt(e)/r}),i},h.x=function(e){return arguments.length?(t="function"==typeof e?e:is(+e),h):t},h.y=function(t){return arguments.length?(e="function"==typeof t?t:is(+t),h):e},h.weight=function(t){return arguments.length?(n="function"==typeof t?t:is(+t),h):n},h.size=function(t){if(!arguments.length)return[r,i];var e=+t[0],n=+t[1];if(!(e>=0&&n>=0))throw new Error("invalid size");return r=e,i=n,v()},h.cellSize=function(t){if(!arguments.length)return 1<<a;if(!((t=+t)>=1))throw new Error("invalid cell size");return a=Math.floor(Math.log(t)/Math.LN2),v()},h.thresholds=function(t){return arguments.length?(c="function"==typeof t?t:Array.isArray(t)?is(ns.call(t)):is(t),h):c},h.bandwidth=function(t){if(!arguments.length)return Math.sqrt(o*(o+1));if(!((t=+t)>=0))throw new Error("invalid bandwidth");return o=(Math.sqrt(4*t*t+1)-1)/2,v()},h}const xs=134217729;function _s(t,e,n,r,i){let o,a,s,u,l=e[0],c=r[0],f=0,h=0;c>l==c>-l?(o=l,l=e[++f]):(o=c,c=r[++h]);let d=0;if(f<t&&h<n)for(c>l==c>-l?(a=l+o,s=o-(a-l),l=e[++f]):(a=c+o,s=o-(a-c),c=r[++h]),o=a,0!==s&&(i[d++]=s);f<t&&h<n;)c>l==c>-l?(a=o+l,u=a-o,s=o-(a-u)+(l-u),l=e[++f]):(a=o+c,u=a-o,s=o-(a-u)+(c-u),c=r[++h]),o=a,0!==s&&(i[d++]=s);for(;f<t;)a=o+l,u=a-o,s=o-(a-u)+(l-u),l=e[++f],o=a,0!==s&&(i[d++]=s);for(;h<n;)a=o+c,u=a-o,s=o-(a-u)+(c-u),c=r[++h],o=a,0!==s&&(i[d++]=s);return 0===o&&0!==d||(i[d++]=o),d}function bs(t){return new Float64Array(t)}const ws=bs(4),Ms=bs(8),As=bs(12),Ts=bs(16),Es=bs(4);function Cs(t,e,n,r,i,o){const a=(e-o)*(n-i),s=(t-i)*(r-o),u=a-s,l=Math.abs(a+s);return Math.abs(u)>=33306690738754716e-32*l?u:-function(t,e,n,r,i,o,a){let s,u,l,c,f,h,d,p,m,g,y,v,x,_,b,w,M,A;const T=t-i,E=n-i,C=e-o,k=r-o;_=T*k,h=xs*T,d=h-(h-T),p=T-d,h=xs*k,m=h-(h-k),g=k-m,b=p*g-(_-d*m-p*m-d*g),w=C*E,h=xs*C,d=h-(h-C),p=C-d,h=xs*E,m=h-(h-E),g=E-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,ws[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,ws[1]=x-(y+f)+(f-w),A=v+y,f=A-v,ws[2]=v-(A-f)+(y-f),ws[3]=A;let S=function(t,e){let n=e[0];for(let r=1;r<t;r++)n+=e[r];return n}(4,ws),O=22204460492503146e-32*a;if(S>=O||-S>=O)return S;if(f=t-T,s=t-(T+f)+(f-i),f=n-E,l=n-(E+f)+(f-i),f=e-C,u=e-(C+f)+(f-o),f=r-k,c=r-(k+f)+(f-o),0===s&&0===u&&0===l&&0===c)return S;if(O=11093356479670487e-47*a+33306690738754706e-32*Math.abs(S),S+=T*c+k*s-(C*l+E*u),S>=O||-S>=O)return S;_=s*k,h=xs*s,d=h-(h-s),p=s-d,h=xs*k,m=h-(h-k),g=k-m,b=p*g-(_-d*m-p*m-d*g),w=u*E,h=xs*u,d=h-(h-u),p=u-d,h=xs*E,m=h-(h-E),g=E-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const P=_s(4,ws,4,Es,Ms);_=T*c,h=xs*T,d=h-(h-T),p=T-d,h=xs*c,m=h-(h-c),g=c-m,b=p*g-(_-d*m-p*m-d*g),w=C*l,h=xs*C,d=h-(h-C),p=C-d,h=xs*l,m=h-(h-l),g=l-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const L=_s(P,Ms,4,Es,As);_=s*c,h=xs*s,d=h-(h-s),p=s-d,h=xs*c,m=h-(h-c),g=c-m,b=p*g-(_-d*m-p*m-d*g),w=u*l,h=xs*u,d=h-(h-u),p=u-d,h=xs*l,m=h-(h-l),g=l-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const R=_s(L,As,4,Es,Ts);return Ts[R-1]}(t,e,n,r,i,o,l)}bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(8),bs(8),bs(8),bs(4),bs(8),bs(8),bs(8),bs(12);bs(192),bs(192);bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(4),bs(4),bs(4),bs(8),bs(16),bs(16),bs(16),bs(32),bs(32),bs(48),bs(64);bs(1152),bs(1152);bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(1152),bs(1152),bs(1152),bs(1152),bs(1152),bs(2304),bs(2304),bs(3456),bs(5760),bs(8),bs(8),bs(8),bs(16),bs(24),bs(48),bs(48),bs(96),bs(192),bs(384),bs(384),bs(384),bs(768);bs(96),bs(96),bs(96),bs(1152);const ks=Math.pow(2,-52),Ss=new Uint32Array(512);class Os{static from(t,e=Ns,n=Fs){const r=t.length,i=new Float64Array(2*r);for(let o=0;o<r;o++){const r=t[o];i[2*o]=e(r),i[2*o+1]=n(r)}return new Os(i)}constructor(t){const e=t.length>>1;if(e>0&&"number"!=typeof t[0])throw new Error("Expected coords to contain numbers.");this.coords=t;const n=Math.max(2*e-5,0);this._triangles=new Uint32Array(3*n),this._halfedges=new Int32Array(3*n),this._hashSize=Math.ceil(Math.sqrt(e)),this._hullPrev=new Uint32Array(e),this._hullNext=new Uint32Array(e),this._hullTri=new Uint32Array(e),this._hullHash=new Int32Array(this._hashSize),this._ids=new Uint32Array(e),this._dists=new Float64Array(e),this.update()}update(){const{coords:t,_hullPrev:e,_hullNext:n,_hullTri:r,_hullHash:i}=this,o=t.length>>1;let a=1/0,s=1/0,u=-1/0,l=-1/0;for(let e=0;e<o;e++){const n=t[2*e],r=t[2*e+1];n<a&&(a=n),r<s&&(s=r),n>u&&(u=n),r>l&&(l=r),this._ids[e]=e}const c=(a+u)/2,f=(s+l)/2;let h,d,p;for(let e=0,n=1/0;e<o;e++){const r=Ps(c,f,t[2*e],t[2*e+1]);r<n&&(h=e,n=r)}const m=t[2*h],g=t[2*h+1];for(let e=0,n=1/0;e<o;e++){if(e===h)continue;const r=Ps(m,g,t[2*e],t[2*e+1]);r<n&&r>0&&(d=e,n=r)}let y=t[2*d],v=t[2*d+1],x=1/0;for(let e=0;e<o;e++){if(e===h||e===d)continue;const n=Rs(m,g,y,v,t[2*e],t[2*e+1]);n<x&&(p=e,x=n)}let _=t[2*p],b=t[2*p+1];if(x===1/0){for(let e=0;e<o;e++)this._dists[e]=t[2*e]-t[0]||t[2*e+1]-t[1];Is(this._ids,this._dists,0,o-1);const e=new Uint32Array(o);let n=0;for(let t=0,r=-1/0;t<o;t++){const i=this._ids[t],o=this._dists[i];o>r&&(e[n++]=i,r=o)}return this.hull=e.subarray(0,n),this.triangles=new Uint32Array(0),void(this.halfedges=new Uint32Array(0))}if(Cs(m,g,y,v,_,b)<0){const t=d,e=y,n=v;d=p,y=_,v=b,p=t,_=e,b=n}const w=function(t,e,n,r,i,o){const a=n-t,s=r-e,u=i-t,l=o-e,c=a*a+s*s,f=u*u+l*l,h=.5/(a*l-s*u),d=t+(l*c-s*f)*h,p=e+(a*f-u*c)*h;return{x:d,y:p}}(m,g,y,v,_,b);this._cx=w.x,this._cy=w.y;for(let e=0;e<o;e++)this._dists[e]=Ps(t[2*e],t[2*e+1],w.x,w.y);Is(this._ids,this._dists,0,o-1),this._hullStart=h;let M=3;n[h]=e[p]=d,n[d]=e[h]=p,n[p]=e[d]=h,r[h]=0,r[d]=1,r[p]=2,i.fill(-1),i[this._hashKey(m,g)]=h,i[this._hashKey(y,v)]=d,i[this._hashKey(_,b)]=p,this.trianglesLen=0,this._addTriangle(h,d,p,-1,-1,-1);for(let o,a,s=0;s<this._ids.length;s++){const u=this._ids[s],l=t[2*u],c=t[2*u+1];if(s>0&&Math.abs(l-o)<=ks&&Math.abs(c-a)<=ks)continue;if(o=l,a=c,u===h||u===d||u===p)continue;let f=0;for(let t=0,e=this._hashKey(l,c);t<this._hashSize&&(f=i[(e+t)%this._hashSize],-1===f||f===n[f]);t++);f=e[f];let m,g=f;for(;m=n[g],Cs(l,c,t[2*g],t[2*g+1],t[2*m],t[2*m+1])>=0;)if(g=m,g===f){g=-1;break}if(-1===g)continue;let y=this._addTriangle(g,u,n[g],-1,-1,r[g]);r[u]=this._legalize(y+2),r[g]=y,M++;let v=n[g];for(;m=n[v],Cs(l,c,t[2*v],t[2*v+1],t[2*m],t[2*m+1])<0;)y=this._addTriangle(v,u,m,r[u],-1,r[v]),r[u]=this._legalize(y+2),n[v]=v,M--,v=m;if(g===f)for(;m=e[g],Cs(l,c,t[2*m],t[2*m+1],t[2*g],t[2*g+1])<0;)y=this._addTriangle(m,u,g,-1,r[g],r[m]),this._legalize(y+2),r[m]=y,n[g]=g,M--,g=m;this._hullStart=e[u]=g,n[g]=e[v]=u,n[u]=v,i[this._hashKey(l,c)]=u,i[this._hashKey(t[2*g],t[2*g+1])]=g}this.hull=new Uint32Array(M);for(let t=0,e=this._hullStart;t<M;t++)this.hull[t]=e,e=n[e];this.triangles=this._triangles.subarray(0,this.trianglesLen),this.halfedges=this._halfedges.subarray(0,this.trianglesLen)}_hashKey(t,e){return Math.floor(function(t,e){const n=t/(Math.abs(t)+Math.abs(e));return(e>0?3-n:1+n)/4}(t-this._cx,e-this._cy)*this._hashSize)%this._hashSize}_legalize(t){const{_triangles:e,_halfedges:n,coords:r}=this;let i=0,o=0;for(;;){const a=n[t],s=t-t%3;if(o=s+(t+2)%3,-1===a){if(0===i)break;t=Ss[--i];continue}const u=a-a%3,l=s+(t+1)%3,c=u+(a+2)%3,f=e[o],h=e[t],d=e[l],p=e[c];if(Ls(r[2*f],r[2*f+1],r[2*h],r[2*h+1],r[2*d],r[2*d+1],r[2*p],r[2*p+1])){e[t]=p,e[a]=f;const r=n[c];if(-1===r){let e=this._hullStart;do{if(this._hullTri[e]===c){this._hullTri[e]=t;break}e=this._hullPrev[e]}while(e!==this._hullStart)}this._link(t,r),this._link(a,n[o]),this._link(o,c);const s=u+(a+1)%3;i<Ss.length&&(Ss[i++]=s)}else{if(0===i)break;t=Ss[--i]}}return o}_link(t,e){this._halfedges[t]=e,-1!==e&&(this._halfedges[e]=t)}_addTriangle(t,e,n,r,i,o){const a=this.trianglesLen;return this._triangles[a]=t,this._triangles[a+1]=e,this._triangles[a+2]=n,this._link(a,r),this._link(a+1,i),this._link(a+2,o),this.trianglesLen+=3,a}}function Ps(t,e,n,r){const i=t-n,o=e-r;return i*i+o*o}function Ls(t,e,n,r,i,o,a,s){const u=t-a,l=e-s,c=n-a,f=r-s,h=i-a,d=o-s,p=c*c+f*f,m=h*h+d*d;return u*(f*m-p*d)-l*(c*m-p*h)+(u*u+l*l)*(c*d-f*h)<0}function Rs(t,e,n,r,i,o){const a=n-t,s=r-e,u=i-t,l=o-e,c=a*a+s*s,f=u*u+l*l,h=.5/(a*l-s*u),d=(l*c-s*f)*h,p=(a*f-u*c)*h;return d*d+p*p}function Is(t,e,n,r){if(r-n<=20)for(let i=n+1;i<=r;i++){const r=t[i],o=e[r];let a=i-1;for(;a>=n&&e[t[a]]>o;)t[a+1]=t[a--];t[a+1]=r}else{let i=n+1,o=r;Ds(t,n+r>>1,i),e[t[n]]>e[t[r]]&&Ds(t,n,r),e[t[i]]>e[t[r]]&&Ds(t,i,r),e[t[n]]>e[t[i]]&&Ds(t,n,i);const a=t[i],s=e[a];for(;;){do{i++}while(e[t[i]]<s);do{o--}while(e[t[o]]>s);if(o<i)break;Ds(t,i,o)}t[n+1]=t[o],t[o]=a,r-i+1>=o-n?(Is(t,e,i,r),Is(t,e,n,o-1)):(Is(t,e,n,o-1),Is(t,e,i,r))}}function Ds(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function Ns(t){return t[0]}function Fs(t){return t[1]}const js=1e-6;class zs{constructor(){this._x0=this._y0=this._x1=this._y1=null,this._=""}moveTo(t,e){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")}lineTo(t,e){this._+=`L${this._x1=+t},${this._y1=+e}`}arc(t,e,n){const r=(t=+t)+(n=+n),i=e=+e;if(n<0)throw new Error("negative radius");null===this._x1?this._+=`M${r},${i}`:(Math.abs(this._x1-r)>js||Math.abs(this._y1-i)>js)&&(this._+="L"+r+","+i),n&&(this._+=`A${n},${n},0,1,1,${t-n},${e}A${n},${n},0,1,1,${this._x1=r},${this._y1=i}`)}rect(t,e,n,r){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${+n}v${+r}h${-n}Z`}value(){return this._||null}}class Bs{constructor(){this._=[]}moveTo(t,e){this._.push([t,e])}closePath(){this._.push(this._[0].slice())}lineTo(t,e){this._.push([t,e])}value(){return this._.length?this._:null}}class Vs{constructor(t,[e,n,r,i]=[0,0,960,500]){if(!((r=+r)>=(e=+e)&&(i=+i)>=(n=+n)))throw new Error("invalid bounds");this.delaunay=t,this._circumcenters=new Float64Array(2*t.points.length),this.vectors=new Float64Array(2*t.points.length),this.xmax=r,this.xmin=e,this.ymax=i,this.ymin=n,this._init()}update(){return this.delaunay.update(),this._init(),this}_init(){const{delaunay:{points:t,hull:e,triangles:n},vectors:r}=this;let i,o;const a=this.circumcenters=this._circumcenters.subarray(0,n.length/3*2);for(let r,s,u=0,l=0,c=n.length;u<c;u+=3,l+=2){const c=2*n[u],f=2*n[u+1],h=2*n[u+2],d=t[c],p=t[c+1],m=t[f],g=t[f+1],y=t[h],v=t[h+1],x=m-d,_=g-p,b=y-d,w=v-p,M=2*(x*w-_*b);if(Math.abs(M)<1e-9){if(void 0===i){i=o=0;for(const n of e)i+=t[2*n],o+=t[2*n+1];i/=e.length,o/=e.length}const n=1e9*Math.sign((i-d)*w-(o-p)*b);r=(d+y)/2-n*w,s=(p+v)/2+n*b}else{const t=1/M,e=x*x+_*_,n=b*b+w*w;r=d+(w*e-_*n)*t,s=p+(x*n-b*e)*t}a[l]=r,a[l+1]=s}let s,u,l,c=e[e.length-1],f=4*c,h=t[2*c],d=t[2*c+1];r.fill(0);for(let n=0;n<e.length;++n)c=e[n],s=f,u=h,l=d,f=4*c,h=t[2*c],d=t[2*c+1],r[s+2]=r[f]=l-d,r[s+3]=r[f+1]=h-u}render(t){const e=null==t?t=new zs:void 0,{delaunay:{halfedges:n,inedges:r,hull:i},circumcenters:o,vectors:a}=this;if(i.length<=1)return null;for(let e=0,r=n.length;e<r;++e){const r=n[e];if(r<e)continue;const i=2*Math.floor(e/3),a=2*Math.floor(r/3),s=o[i],u=o[i+1],l=o[a],c=o[a+1];this._renderSegment(s,u,l,c,t)}let s,u=i[i.length-1];for(let e=0;e<i.length;++e){s=u,u=i[e];const n=2*Math.floor(r[u]/3),l=o[n],c=o[n+1],f=4*s,h=this._project(l,c,a[f+2],a[f+3]);h&&this._renderSegment(l,c,h[0],h[1],t)}return e&&e.value()}renderBounds(t){const e=null==t?t=new zs:void 0;return t.rect(this.xmin,this.ymin,this.xmax-this.xmin,this.ymax-this.ymin),e&&e.value()}renderCell(t,e){const n=null==e?e=new zs:void 0,r=this._clip(t);if(null===r||!r.length)return;e.moveTo(r[0],r[1]);let i=r.length;for(;r[0]===r[i-2]&&r[1]===r[i-1]&&i>1;)i-=2;for(let t=2;t<i;t+=2)r[t]===r[t-2]&&r[t+1]===r[t-1]||e.lineTo(r[t],r[t+1]);return e.closePath(),n&&n.value()}*cellPolygons(){const{delaunay:{points:t}}=this;for(let e=0,n=t.length/2;e<n;++e){const t=this.cellPolygon(e);t&&(t.index=e,yield t)}}cellPolygon(t){const e=new Bs;return this.renderCell(t,e),e.value()}_renderSegment(t,e,n,r,i){let o;const a=this._regioncode(t,e),s=this._regioncode(n,r);0===a&&0===s?(i.moveTo(t,e),i.lineTo(n,r)):(o=this._clipSegment(t,e,n,r,a,s))&&(i.moveTo(o[0],o[1]),i.lineTo(o[2],o[3]))}contains(t,e,n){return(e=+e)==e&&(n=+n)==n&&this.delaunay._step(t,e,n)===t}*neighbors(t){const e=this._clip(t);if(e)for(const n of this.delaunay.neighbors(t)){const t=this._clip(n);if(t)t:for(let r=0,i=e.length;r<i;r+=2)for(let o=0,a=t.length;o<a;o+=2)if(e[r]===t[o]&&e[r+1]===t[o+1]&&e[(r+2)%i]===t[(o+a-2)%a]&&e[(r+3)%i]===t[(o+a-1)%a]){yield n;break t}}}_cell(t){const{circumcenters:e,delaunay:{inedges:n,halfedges:r,triangles:i}}=this,o=n[t];if(-1===o)return null;const a=[];let s=o;do{const n=Math.floor(s/3);if(a.push(e[2*n],e[2*n+1]),s=s%3==2?s-2:s+1,i[s]!==t)break;s=r[s]}while(s!==o&&-1!==s);return a}_clip(t){if(0===t&&1===this.delaunay.hull.length)return[this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax,this.xmin,this.ymin];const e=this._cell(t);if(null===e)return null;const{vectors:n}=this,r=4*t;return this._simplify(n[r]||n[r+1]?this._clipInfinite(t,e,n[r],n[r+1],n[r+2],n[r+3]):this._clipFinite(t,e))}_clipFinite(t,e){const n=e.length;let r,i,o,a,s=null,u=e[n-2],l=e[n-1],c=this._regioncode(u,l),f=0;for(let h=0;h<n;h+=2)if(r=u,i=l,u=e[h],l=e[h+1],o=c,c=this._regioncode(u,l),0===o&&0===c)a=f,f=0,s?s.push(u,l):s=[u,l];else{let e,n,h,d,p;if(0===o){if(null===(e=this._clipSegment(r,i,u,l,o,c)))continue;[n,h,d,p]=e}else{if(null===(e=this._clipSegment(u,l,r,i,c,o)))continue;[d,p,n,h]=e,a=f,f=this._edgecode(n,h),a&&f&&this._edge(t,a,f,s,s.length),s?s.push(n,h):s=[n,h]}a=f,f=this._edgecode(d,p),a&&f&&this._edge(t,a,f,s,s.length),s?s.push(d,p):s=[d,p]}if(s)a=f,f=this._edgecode(s[0],s[1]),a&&f&&this._edge(t,a,f,s,s.length);else if(this.contains(t,(this.xmin+this.xmax)/2,(this.ymin+this.ymax)/2))return[this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax,this.xmin,this.ymin];return s}_clipSegment(t,e,n,r,i,o){const a=i<o;for(a&&([t,e,n,r,i,o]=[n,r,t,e,o,i]);;){if(0===i&&0===o)return a?[n,r,t,e]:[t,e,n,r];if(i&o)return null;let s,u,l=i||o;8&l?(s=t+(n-t)*(this.ymax-e)/(r-e),u=this.ymax):4&l?(s=t+(n-t)*(this.ymin-e)/(r-e),u=this.ymin):2&l?(u=e+(r-e)*(this.xmax-t)/(n-t),s=this.xmax):(u=e+(r-e)*(this.xmin-t)/(n-t),s=this.xmin),i?(t=s,e=u,i=this._regioncode(t,e)):(n=s,r=u,o=this._regioncode(n,r))}}_clipInfinite(t,e,n,r,i,o){let a,s=Array.from(e);if((a=this._project(s[0],s[1],n,r))&&s.unshift(a[0],a[1]),(a=this._project(s[s.length-2],s[s.length-1],i,o))&&s.push(a[0],a[1]),s=this._clipFinite(t,s))for(let e,n=0,r=s.length,i=this._edgecode(s[r-2],s[r-1]);n<r;n+=2)e=i,i=this._edgecode(s[n],s[n+1]),e&&i&&(n=this._edge(t,e,i,s,n),r=s.length);else this.contains(t,(this.xmin+this.xmax)/2,(this.ymin+this.ymax)/2)&&(s=[this.xmin,this.ymin,this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax]);return s}_edge(t,e,n,r,i){for(;e!==n;){let n,o;switch(e){case 5:e=4;continue;case 4:e=6,n=this.xmax,o=this.ymin;break;case 6:e=2;continue;case 2:e=10,n=this.xmax,o=this.ymax;break;case 10:e=8;continue;case 8:e=9,n=this.xmin,o=this.ymax;break;case 9:e=1;continue;case 1:e=5,n=this.xmin,o=this.ymin}r[i]===n&&r[i+1]===o||!this.contains(t,n,o)||(r.splice(i,0,n,o),i+=2)}return i}_project(t,e,n,r){let i,o,a,s=1/0;if(r<0){if(e<=this.ymin)return null;(i=(this.ymin-e)/r)<s&&(a=this.ymin,o=t+(s=i)*n)}else if(r>0){if(e>=this.ymax)return null;(i=(this.ymax-e)/r)<s&&(a=this.ymax,o=t+(s=i)*n)}if(n>0){if(t>=this.xmax)return null;(i=(this.xmax-t)/n)<s&&(o=this.xmax,a=e+(s=i)*r)}else if(n<0){if(t<=this.xmin)return null;(i=(this.xmin-t)/n)<s&&(o=this.xmin,a=e+(s=i)*r)}return[o,a]}_edgecode(t,e){return(t===this.xmin?1:t===this.xmax?2:0)|(e===this.ymin?4:e===this.ymax?8:0)}_regioncode(t,e){return(t<this.xmin?1:t>this.xmax?2:0)|(e<this.ymin?4:e>this.ymax?8:0)}_simplify(t){if(t&&t.length>4){for(let e=0;e<t.length;e+=2){const n=(e+2)%t.length,r=(e+4)%t.length;(t[e]===t[n]&&t[n]===t[r]||t[e+1]===t[n+1]&&t[n+1]===t[r+1])&&(t.splice(n,2),e-=2)}t.length||(t=null)}return t}}const qs=2*Math.PI,Gs=Math.pow;function Us(t){return t[0]}function Hs(t){return t[1]}function Ws(t,e,n){return[t+Math.sin(t+e)*n,e+Math.cos(t-e)*n]}class Xs{static from(t,e=Us,n=Hs,r){return new Xs("length"in t?function(t,e,n,r){const i=t.length,o=new Float64Array(2*i);for(let a=0;a<i;++a){const i=t[a];o[2*a]=e.call(r,i,a,t),o[2*a+1]=n.call(r,i,a,t)}return o}(t,e,n,r):Float64Array.from(function*(t,e,n,r){let i=0;for(const o of t)yield e.call(r,o,i,t),yield n.call(r,o,i,t),++i}(t,e,n,r)))}constructor(t){this._delaunator=new Os(t),this.inedges=new Int32Array(t.length/2),this._hullIndex=new Int32Array(t.length/2),this.points=this._delaunator.coords,this._init()}update(){return this._delaunator.update(),this._init(),this}_init(){const t=this._delaunator,e=this.points;if(t.hull&&t.hull.length>2&&function(t){const{triangles:e,coords:n}=t;for(let t=0;t<e.length;t+=3){const r=2*e[t],i=2*e[t+1],o=2*e[t+2];if((n[o]-n[r])*(n[i+1]-n[r+1])-(n[i]-n[r])*(n[o+1]-n[r+1])>1e-10)return!1}return!0}(t)){this.collinear=Int32Array.from({length:e.length/2},((t,e)=>e)).sort(((t,n)=>e[2*t]-e[2*n]||e[2*t+1]-e[2*n+1]));const t=this.collinear[0],n=this.collinear[this.collinear.length-1],r=[e[2*t],e[2*t+1],e[2*n],e[2*n+1]],i=1e-8*Math.hypot(r[3]-r[1],r[2]-r[0]);for(let t=0,n=e.length/2;t<n;++t){const n=Ws(e[2*t],e[2*t+1],i);e[2*t]=n[0],e[2*t+1]=n[1]}this._delaunator=new Os(e)}else delete this.collinear;const n=this.halfedges=this._delaunator.halfedges,r=this.hull=this._delaunator.hull,i=this.triangles=this._delaunator.triangles,o=this.inedges.fill(-1),a=this._hullIndex.fill(-1);for(let t=0,e=n.length;t<e;++t){const e=i[t%3==2?t-2:t+1];-1!==n[t]&&-1!==o[e]||(o[e]=t)}for(let t=0,e=r.length;t<e;++t)a[r[t]]=t;r.length<=2&&r.length>0&&(this.triangles=new Int32Array(3).fill(-1),this.halfedges=new Int32Array(3).fill(-1),this.triangles[0]=r[0],o[r[0]]=1,2===r.length&&(o[r[1]]=0,this.triangles[1]=r[1],this.triangles[2]=r[1]))}voronoi(t){return new Vs(this,t)}*neighbors(t){const{inedges:e,hull:n,_hullIndex:r,halfedges:i,triangles:o,collinear:a}=this;if(a){const e=a.indexOf(t);return e>0&&(yield a[e-1]),void(e<a.length-1&&(yield a[e+1]))}const s=e[t];if(-1===s)return;let u=s,l=-1;do{if(yield l=o[u],u=u%3==2?u-2:u+1,o[u]!==t)return;if(u=i[u],-1===u){const e=n[(r[t]+1)%n.length];return void(e!==l&&(yield e))}}while(u!==s)}find(t,e,n=0){if((t=+t)!=t||(e=+e)!=e)return-1;const r=n;let i;for(;(i=this._step(n,t,e))>=0&&i!==n&&i!==r;)n=i;return i}_step(t,e,n){const{inedges:r,hull:i,_hullIndex:o,halfedges:a,triangles:s,points:u}=this;if(-1===r[t]||!u.length)return(t+1)%(u.length>>1);let l=t,c=Gs(e-u[2*t],2)+Gs(n-u[2*t+1],2);const f=r[t];let h=f;do{let r=s[h];const f=Gs(e-u[2*r],2)+Gs(n-u[2*r+1],2);if(f<c&&(c=f,l=r),h=h%3==2?h-2:h+1,s[h]!==t)break;if(h=a[h],-1===h){if(h=i[(o[t]+1)%i.length],h!==r&&Gs(e-u[2*h],2)+Gs(n-u[2*h+1],2)<c)return h;break}}while(h!==f);return l}render(t){const e=null==t?t=new zs:void 0,{points:n,halfedges:r,triangles:i}=this;for(let e=0,o=r.length;e<o;++e){const o=r[e];if(o<e)continue;const a=2*i[e],s=2*i[o];t.moveTo(n[a],n[a+1]),t.lineTo(n[s],n[s+1])}return this.renderHull(t),e&&e.value()}renderPoints(t,e){void 0!==e||t&&"function"==typeof t.moveTo||(e=t,t=null),e=null==e?2:+e;const n=null==t?t=new zs:void 0,{points:r}=this;for(let n=0,i=r.length;n<i;n+=2){const i=r[n],o=r[n+1];t.moveTo(i+e,o),t.arc(i,o,e,0,qs)}return n&&n.value()}renderHull(t){const e=null==t?t=new zs:void 0,{hull:n,points:r}=this,i=2*n[0],o=n.length;t.moveTo(r[i],r[i+1]);for(let e=1;e<o;++e){const i=2*n[e];t.lineTo(r[i],r[i+1])}return t.closePath(),e&&e.value()}hullPolygon(){const t=new Bs;return this.renderHull(t),t.value()}renderTriangle(t,e){const n=null==e?e=new zs:void 0,{points:r,triangles:i}=this,o=2*i[t*=3],a=2*i[t+1],s=2*i[t+2];return e.moveTo(r[o],r[o+1]),e.lineTo(r[a],r[a+1]),e.lineTo(r[s],r[s+1]),e.closePath(),n&&n.value()}*trianglePolygons(){const{triangles:t}=this;for(let e=0,n=t.length/3;e<n;++e)yield this.trianglePolygon(e)}trianglePolygon(t){const e=new Bs;return this.renderTriangle(t,e),e.value()}}var Ks=t=>()=>t;function Qs(t,{sourceEvent:e,subject:n,target:r,identifier:i,active:o,x:a,y:s,dx:u,dy:l,dispatch:c}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:o,enumerable:!0,configurable:!0},x:{value:a,enumerable:!0,configurable:!0},y:{value:s,enumerable:!0,configurable:!0},dx:{value:u,enumerable:!0,configurable:!0},dy:{value:l,enumerable:!0,configurable:!0},_:{value:c}})}function Ys(t){return!t.ctrlKey&&!t.button}function $s(){return this.parentNode}function Zs(t,e){return null==e?{x:t.x,y:t.y}:e}function Js(){return navigator.maxTouchPoints||"ontouchstart"in this}function tu(){var t,e,n,r,i=Ys,o=$s,a=Zs,s=Js,u={},l=Ee("start","drag","end"),c=0,f=0;function h(t){t.on("mousedown.drag",d).filter(s).on("touchstart.drag",g).on("touchmove.drag",y,qn).on("touchend.drag touchcancel.drag",v).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function d(a,s){if(!r&&i.call(this,a,s)){var u=x(this,o.call(this,a,s),a,s,"mouse");u&&(Vn(a.view).on("mousemove.drag",p,Gn).on("mouseup.drag",m,Gn),Wn(a.view),Un(a),n=!1,t=a.clientX,e=a.clientY,u("start",a))}}function p(r){if(Hn(r),!n){var i=r.clientX-t,o=r.clientY-e;n=i*i+o*o>f}u.mouse("drag",r)}function m(t){Vn(t.view).on("mousemove.drag mouseup.drag",null),Xn(t.view,n),Hn(t),u.mouse("end",t)}function g(t,e){if(i.call(this,t,e)){var n,r,a=t.changedTouches,s=o.call(this,t,e),u=a.length;for(n=0;n<u;++n)(r=x(this,s,t,e,a[n].identifier,a[n]))&&(Un(t),r("start",t,a[n]))}}function y(t){var e,n,r=t.changedTouches,i=r.length;for(e=0;e<i;++e)(n=u[r[e].identifier])&&(Hn(t),n("drag",t,r[e]))}function v(t){var e,n,i=t.changedTouches,o=i.length;for(r&&clearTimeout(r),r=setTimeout((function(){r=null}),500),e=0;e<o;++e)(n=u[i[e].identifier])&&(Un(t),n("end",t,i[e]))}function x(t,e,n,r,i,o){var s,f,d,p=l.copy(),m=ti(o||n,e);if(null!=(d=a.call(t,new Qs("beforestart",{sourceEvent:n,target:h,identifier:i,active:c,x:m[0],y:m[1],dx:0,dy:0,dispatch:p}),r)))return s=d.x-m[0]||0,f=d.y-m[1]||0,function n(o,a,l){var g,y=m;switch(o){case"start":u[i]=n,g=c++;break;case"end":delete u[i],--c;case"drag":m=ti(l||a,e),g=c}p.call(o,t,new Qs(o,{sourceEvent:a,subject:d,target:h,identifier:i,active:g,x:m[0]+s,y:m[1]+f,dx:m[0]-y[0],dy:m[1]-y[1],dispatch:p}),r)}}return h.filter=function(t){return arguments.length?(i="function"==typeof t?t:Ks(!!t),h):i},h.container=function(t){return arguments.length?(o="function"==typeof t?t:Ks(t),h):o},h.subject=function(t){return arguments.length?(a="function"==typeof t?t:Ks(t),h):a},h.touchable=function(t){return arguments.length?(s="function"==typeof t?t:Ks(!!t),h):s},h.on=function(){var t=l.on.apply(l,arguments);return t===l?h:t},h.clickDistance=function(t){return arguments.length?(f=(t=+t)*t,h):Math.sqrt(f)},h}Qs.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};var eu={},nu={},ru=34,iu=10,ou=13;function au(t){return new Function("d","return {"+t.map((function(t,e){return JSON.stringify(t)+": d["+e+'] || ""'})).join(",")+"}")}function su(t){var e=Object.create(null),n=[];return t.forEach((function(t){for(var r in t)r in e||n.push(e[r]=r)})),n}function uu(t,e){var n=t+"",r=n.length;return r<e?new Array(e-r+1).join(0)+n:n}function lu(t){var e,n=t.getUTCHours(),r=t.getUTCMinutes(),i=t.getUTCSeconds(),o=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":((e=t.getUTCFullYear())<0?"-"+uu(-e,6):e>9999?"+"+uu(e,6):uu(e,4))+"-"+uu(t.getUTCMonth()+1,2)+"-"+uu(t.getUTCDate(),2)+(o?"T"+uu(n,2)+":"+uu(r,2)+":"+uu(i,2)+"."+uu(o,3)+"Z":i?"T"+uu(n,2)+":"+uu(r,2)+":"+uu(i,2)+"Z":r||n?"T"+uu(n,2)+":"+uu(r,2)+"Z":"")}function cu(t){var e=new RegExp('["'+t+"\n\r]"),n=t.charCodeAt(0);function r(t,e){var r,i=[],o=t.length,a=0,s=0,u=o<=0,l=!1;function c(){if(u)return nu;if(l)return l=!1,eu;var e,r,i=a;if(t.charCodeAt(i)===ru){for(;a++<o&&t.charCodeAt(a)!==ru||t.charCodeAt(++a)===ru;);return(e=a)>=o?u=!0:(r=t.charCodeAt(a++))===iu?l=!0:r===ou&&(l=!0,t.charCodeAt(a)===iu&&++a),t.slice(i+1,e-1).replace(/""/g,'"')}for(;a<o;){if((r=t.charCodeAt(e=a++))===iu)l=!0;else if(r===ou)l=!0,t.charCodeAt(a)===iu&&++a;else if(r!==n)continue;return t.slice(i,e)}return u=!0,t.slice(i,o)}for(t.charCodeAt(o-1)===iu&&--o,t.charCodeAt(o-1)===ou&&--o;(r=c())!==nu;){for(var f=[];r!==eu&&r!==nu;)f.push(r),r=c();e&&null==(f=e(f,s++))||i.push(f)}return i}function i(e,n){return e.map((function(e){return n.map((function(t){return a(e[t])})).join(t)}))}function o(e){return e.map(a).join(t)}function a(t){return null==t?"":t instanceof Date?lu(t):e.test(t+="")?'"'+t.replace(/"/g,'""')+'"':t}return{parse:function(t,e){var n,i,o=r(t,(function(t,r){if(n)return n(t,r-1);i=t,n=e?function(t,e){var n=au(t);return function(r,i){return e(n(r),i,t)}}(t,e):au(t)}));return o.columns=i||[],o},parseRows:r,format:function(e,n){return null==n&&(n=su(e)),[n.map(a).join(t)].concat(i(e,n)).join("\n")},formatBody:function(t,e){return null==e&&(e=su(t)),i(t,e).join("\n")},formatRows:function(t){return t.map(o).join("\n")},formatRow:o,formatValue:a}}var fu=cu(","),hu=fu.parse,du=fu.parseRows,pu=fu.format,mu=fu.formatBody,gu=fu.formatRows,yu=fu.formatRow,vu=fu.formatValue,xu=cu("\t"),_u=xu.parse,bu=xu.parseRows,wu=xu.format,Mu=xu.formatBody,Au=xu.formatRows,Tu=xu.formatRow,Eu=xu.formatValue;function Cu(t){for(var e in t){var n,r,i=t[e].trim();if(i)if("true"===i)i=!0;else if("false"===i)i=!1;else if("NaN"===i)i=NaN;else if(isNaN(n=+i)){if(!(r=i.match(/^([-+]\d{2})?\d{4}(-\d{2}(-\d{2})?)?(T\d{2}:\d{2}(:\d{2}(\.\d{3})?)?(Z|[-+]\d{2}:\d{2})?)?$/)))continue;ku&&r[4]&&!r[7]&&(i=i.replace(/-/g,"/").replace(/T/," ")),i=new Date(i)}else i=n;else i=null;t[e]=i}return t}const ku=new Date("2019-01-01T00:00").getHours()||new Date("2019-07-01T00:00").getHours(),Su=t=>+t;function Ou(t){return t*t}function Pu(t){return t*(2-t)}function Lu(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}var Ru=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),Iu=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),Du=function t(e){function n(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,n.exponent=t,n}(3),Nu=Math.PI,Fu=Nu/2;function ju(t){return 1==+t?1:1-Math.cos(t*Fu)}function zu(t){return Math.sin(t*Fu)}function Bu(t){return(1-Math.cos(Nu*t))/2}function Vu(t){return 1.0009775171065494*(Math.pow(2,-10*t)-.0009765625)}function qu(t){return Vu(1-+t)}function Gu(t){return 1-Vu(t)}function Uu(t){return((t*=2)<=1?Vu(1-t):2-Vu(t-1))/2}function Hu(t){return 1-Math.sqrt(1-t*t)}function Wu(t){return Math.sqrt(1- --t*t)}function Xu(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var Ku=4/11,Qu=6/11,Yu=8/11,$u=3/4,Zu=9/11,Ju=10/11,tl=15/16,el=21/22,nl=63/64,rl=1/Ku/Ku;function il(t){return 1-ol(1-t)}function ol(t){return(t=+t)<Ku?rl*t*t:t<Yu?rl*(t-=Qu)*t+$u:t<Ju?rl*(t-=Zu)*t+tl:rl*(t-=el)*t+nl}function al(t){return((t*=2)<=1?1-ol(1-t):ol(t-1)+1)/2}var sl=1.70158,ul=function t(e){function n(t){return(t=+t)*t*(e*(t-1)+t)}return e=+e,n.overshoot=t,n}(sl),ll=function t(e){function n(t){return--t*t*((t+1)*e+t)+1}return e=+e,n.overshoot=t,n}(sl),cl=function t(e){function n(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,n.overshoot=t,n}(sl),fl=2*Math.PI,hl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return e*Vu(- --t)*Math.sin((r-t)/n)}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3),dl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return 1-e*Vu(t=+t)*Math.sin((t+r)/n)}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3),pl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return((t=2*t-1)<0?e*Vu(-t)*Math.sin((r-t)/n):2-e*Vu(t)*Math.sin((r+t)/n))/2}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3);function ml(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.blob()}function gl(t,e){return fetch(t,e).then(ml)}function yl(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.arrayBuffer()}function vl(t,e){return fetch(t,e).then(yl)}function xl(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.text()}function _l(t,e){return fetch(t,e).then(xl)}function bl(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=void 0),_l(e,n).then((function(e){return t(e,r)}))}}function wl(t,e,n,r){3===arguments.length&&"function"==typeof n&&(r=n,n=void 0);var i=cu(t);return _l(e,n).then((function(t){return i.parse(t,r)}))}var Ml=bl(hu),Al=bl(_u);function Tl(t,e){return new Promise((function(n,r){var i=new Image;for(var o in e)i[o]=e[o];i.onerror=r,i.onload=function(){n(i)},i.src=t}))}function El(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);if(204!==t.status&&205!==t.status)return t.json()}function Cl(t,e){return fetch(t,e).then(El)}function kl(t){return(e,n)=>_l(e,n).then((e=>(new DOMParser).parseFromString(e,t)))}var Sl=kl("application/xml"),Ol=kl("text/html"),Pl=kl("image/svg+xml");function Ll(t,e){var n,r=1;function i(){var i,o,a=n.length,s=0,u=0;for(i=0;i<a;++i)s+=(o=n[i]).x,u+=o.y;for(s=(s/a-t)*r,u=(u/a-e)*r,i=0;i<a;++i)(o=n[i]).x-=s,o.y-=u}return null==t&&(t=0),null==e&&(e=0),i.initialize=function(t){n=t},i.x=function(e){return arguments.length?(t=+e,i):t},i.y=function(t){return arguments.length?(e=+t,i):e},i.strength=function(t){return arguments.length?(r=+t,i):r},i}function Rl(t,e,n,r){if(isNaN(e)||isNaN(n))return t;var i,o,a,s,u,l,c,f,h,d=t._root,p={data:r},m=t._x0,g=t._y0,y=t._x1,v=t._y1;if(!d)return t._root=p,t;for(;d.length;)if((l=e>=(o=(m+y)/2))?m=o:y=o,(c=n>=(a=(g+v)/2))?g=a:v=a,i=d,!(d=d[f=c<<1|l]))return i[f]=p,t;if(s=+t._x.call(null,d.data),u=+t._y.call(null,d.data),e===s&&n===u)return p.next=d,i?i[f]=p:t._root=p,t;do{i=i?i[f]=new Array(4):t._root=new Array(4),(l=e>=(o=(m+y)/2))?m=o:y=o,(c=n>=(a=(g+v)/2))?g=a:v=a}while((f=c<<1|l)==(h=(u>=a)<<1|s>=o));return i[h]=d,i[f]=p,t}function Il(t,e,n,r,i){this.node=t,this.x0=e,this.y0=n,this.x1=r,this.y1=i}function Dl(t){return t[0]}function Nl(t){return t[1]}function Fl(t,e,n){var r=new jl(null==e?Dl:e,null==n?Nl:n,NaN,NaN,NaN,NaN);return null==t?r:r.addAll(t)}function jl(t,e,n,r,i,o){this._x=t,this._y=e,this._x0=n,this._y0=r,this._x1=i,this._y1=o,this._root=void 0}function zl(t){for(var e={data:t.data},n=e;t=t.next;)n=n.next={data:t.data};return e}var Bl=Fl.prototype=jl.prototype;function Vl(t){return function(){return t}}function ql(t){return 1e-6*(t()-.5)}function Gl(t){return t.x+t.vx}function Ul(t){return t.y+t.vy}function Hl(t){var e,n,r,i=1,o=1;function a(){for(var t,a,u,l,c,f,h,d=e.length,p=0;p<o;++p)for(a=Fl(e,Gl,Ul).visitAfter(s),t=0;t<d;++t)u=e[t],f=n[u.index],h=f*f,l=u.x+u.vx,c=u.y+u.vy,a.visit(m);function m(t,e,n,o,a){var s=t.data,d=t.r,p=f+d;if(!s)return e>l+p||o<l-p||n>c+p||a<c-p;if(s.index>u.index){var m=l-s.x-s.vx,g=c-s.y-s.vy,y=m*m+g*g;y<p*p&&(0===m&&(y+=(m=ql(r))*m),0===g&&(y+=(g=ql(r))*g),y=(p-(y=Math.sqrt(y)))/y*i,u.vx+=(m*=y)*(p=(d*=d)/(h+d)),u.vy+=(g*=y)*p,s.vx-=m*(p=1-p),s.vy-=g*p)}}}function s(t){if(t.data)return t.r=n[t.data.index];for(var e=t.r=0;e<4;++e)t[e]&&t[e].r>t.r&&(t.r=t[e].r)}function u(){if(e){var r,i,o=e.length;for(n=new Array(o),r=0;r<o;++r)i=e[r],n[i.index]=+t(i,r,e)}}return"function"!=typeof t&&(t=Vl(null==t?1:+t)),a.initialize=function(t,n){e=t,r=n,u()},a.iterations=function(t){return arguments.length?(o=+t,a):o},a.strength=function(t){return arguments.length?(i=+t,a):i},a.radius=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),u(),a):t},a}function Wl(t){return t.index}function Xl(t,e){var n=t.get(e);if(!n)throw new Error("node not found: "+e);return n}function Kl(t){var e,n,r,i,o,a,s=Wl,u=function(t){return 1/Math.min(i[t.source.index],i[t.target.index])},l=Vl(30),c=1;function f(r){for(var i=0,s=t.length;i<c;++i)for(var u,l,f,h,d,p,m,g=0;g<s;++g)l=(u=t[g]).source,h=(f=u.target).x+f.vx-l.x-l.vx||ql(a),d=f.y+f.vy-l.y-l.vy||ql(a),h*=p=((p=Math.sqrt(h*h+d*d))-n[g])/p*r*e[g],d*=p,f.vx-=h*(m=o[g]),f.vy-=d*m,l.vx+=h*(m=1-m),l.vy+=d*m}function h(){if(r){var a,u,l=r.length,c=t.length,f=new Map(r.map(((t,e)=>[s(t,e,r),t])));for(a=0,i=new Array(l);a<c;++a)(u=t[a]).index=a,"object"!=typeof u.source&&(u.source=Xl(f,u.source)),"object"!=typeof u.target&&(u.target=Xl(f,u.target)),i[u.source.index]=(i[u.source.index]||0)+1,i[u.target.index]=(i[u.target.index]||0)+1;for(a=0,o=new Array(c);a<c;++a)u=t[a],o[a]=i[u.source.index]/(i[u.source.index]+i[u.target.index]);e=new Array(c),d(),n=new Array(c),p()}}function d(){if(r)for(var n=0,i=t.length;n<i;++n)e[n]=+u(t[n],n,t)}function p(){if(r)for(var e=0,i=t.length;e<i;++e)n[e]=+l(t[e],e,t)}return null==t&&(t=[]),f.initialize=function(t,e){r=t,a=e,h()},f.links=function(e){return arguments.length?(t=e,h(),f):t},f.id=function(t){return arguments.length?(s=t,f):s},f.iterations=function(t){return arguments.length?(c=+t,f):c},f.strength=function(t){return arguments.length?(u="function"==typeof t?t:Vl(+t),d(),f):u},f.distance=function(t){return arguments.length?(l="function"==typeof t?t:Vl(+t),p(),f):l},f}Bl.copy=function(){var t,e,n=new jl(this._x,this._y,this._x0,this._y0,this._x1,this._y1),r=this._root;if(!r)return n;if(!r.length)return n._root=zl(r),n;for(t=[{source:r,target:n._root=new Array(4)}];r=t.pop();)for(var i=0;i<4;++i)(e=r.source[i])&&(e.length?t.push({source:e,target:r.target[i]=new Array(4)}):r.target[i]=zl(e));return n},Bl.add=function(t){const e=+this._x.call(null,t),n=+this._y.call(null,t);return Rl(this.cover(e,n),e,n,t)},Bl.addAll=function(t){var e,n,r,i,o=t.length,a=new Array(o),s=new Array(o),u=1/0,l=1/0,c=-1/0,f=-1/0;for(n=0;n<o;++n)isNaN(r=+this._x.call(null,e=t[n]))||isNaN(i=+this._y.call(null,e))||(a[n]=r,s[n]=i,r<u&&(u=r),r>c&&(c=r),i<l&&(l=i),i>f&&(f=i));if(u>c||l>f)return this;for(this.cover(u,l).cover(c,f),n=0;n<o;++n)Rl(this,a[n],s[n],t[n]);return this},Bl.cover=function(t,e){if(isNaN(t=+t)||isNaN(e=+e))return this;var n=this._x0,r=this._y0,i=this._x1,o=this._y1;if(isNaN(n))i=(n=Math.floor(t))+1,o=(r=Math.floor(e))+1;else{for(var a,s,u=i-n||1,l=this._root;n>t||t>=i||r>e||e>=o;)switch(s=(e<r)<<1|t<n,(a=new Array(4))[s]=l,l=a,u*=2,s){case 0:i=n+u,o=r+u;break;case 1:n=i-u,o=r+u;break;case 2:i=n+u,r=o-u;break;case 3:n=i-u,r=o-u}this._root&&this._root.length&&(this._root=l)}return this._x0=n,this._y0=r,this._x1=i,this._y1=o,this},Bl.data=function(){var t=[];return this.visit((function(e){if(!e.length)do{t.push(e.data)}while(e=e.next)})),t},Bl.extent=function(t){return arguments.length?this.cover(+t[0][0],+t[0][1]).cover(+t[1][0],+t[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]},Bl.find=function(t,e,n){var r,i,o,a,s,u,l,c=this._x0,f=this._y0,h=this._x1,d=this._y1,p=[],m=this._root;for(m&&p.push(new Il(m,c,f,h,d)),null==n?n=1/0:(c=t-n,f=e-n,h=t+n,d=e+n,n*=n);u=p.pop();)if(!(!(m=u.node)||(i=u.x0)>h||(o=u.y0)>d||(a=u.x1)<c||(s=u.y1)<f))if(m.length){var g=(i+a)/2,y=(o+s)/2;p.push(new Il(m[3],g,y,a,s),new Il(m[2],i,y,g,s),new Il(m[1],g,o,a,y),new Il(m[0],i,o,g,y)),(l=(e>=y)<<1|t>=g)&&(u=p[p.length-1],p[p.length-1]=p[p.length-1-l],p[p.length-1-l]=u)}else{var v=t-+this._x.call(null,m.data),x=e-+this._y.call(null,m.data),_=v*v+x*x;if(_<n){var b=Math.sqrt(n=_);c=t-b,f=e-b,h=t+b,d=e+b,r=m.data}}return r},Bl.remove=function(t){if(isNaN(o=+this._x.call(null,t))||isNaN(a=+this._y.call(null,t)))return this;var e,n,r,i,o,a,s,u,l,c,f,h,d=this._root,p=this._x0,m=this._y0,g=this._x1,y=this._y1;if(!d)return this;if(d.length)for(;;){if((l=o>=(s=(p+g)/2))?p=s:g=s,(c=a>=(u=(m+y)/2))?m=u:y=u,e=d,!(d=d[f=c<<1|l]))return this;if(!d.length)break;(e[f+1&3]||e[f+2&3]||e[f+3&3])&&(n=e,h=f)}for(;d.data!==t;)if(r=d,!(d=d.next))return this;return(i=d.next)&&delete d.next,r?(i?r.next=i:delete r.next,this):e?(i?e[f]=i:delete e[f],(d=e[0]||e[1]||e[2]||e[3])&&d===(e[3]||e[2]||e[1]||e[0])&&!d.length&&(n?n[h]=d:this._root=d),this):(this._root=i,this)},Bl.removeAll=function(t){for(var e=0,n=t.length;e<n;++e)this.remove(t[e]);return this},Bl.root=function(){return this._root},Bl.size=function(){var t=0;return this.visit((function(e){if(!e.length)do{++t}while(e=e.next)})),t},Bl.visit=function(t){var e,n,r,i,o,a,s=[],u=this._root;for(u&&s.push(new Il(u,this._x0,this._y0,this._x1,this._y1));e=s.pop();)if(!t(u=e.node,r=e.x0,i=e.y0,o=e.x1,a=e.y1)&&u.length){var l=(r+o)/2,c=(i+a)/2;(n=u[3])&&s.push(new Il(n,l,c,o,a)),(n=u[2])&&s.push(new Il(n,r,c,l,a)),(n=u[1])&&s.push(new Il(n,l,i,o,c)),(n=u[0])&&s.push(new Il(n,r,i,l,c))}return this},Bl.visitAfter=function(t){var e,n=[],r=[];for(this._root&&n.push(new Il(this._root,this._x0,this._y0,this._x1,this._y1));e=n.pop();){var i=e.node;if(i.length){var o,a=e.x0,s=e.y0,u=e.x1,l=e.y1,c=(a+u)/2,f=(s+l)/2;(o=i[0])&&n.push(new Il(o,a,s,c,f)),(o=i[1])&&n.push(new Il(o,c,s,u,f)),(o=i[2])&&n.push(new Il(o,a,f,c,l)),(o=i[3])&&n.push(new Il(o,c,f,u,l))}r.push(e)}for(;e=r.pop();)t(e.node,e.x0,e.y0,e.x1,e.y1);return this},Bl.x=function(t){return arguments.length?(this._x=t,this):this._x},Bl.y=function(t){return arguments.length?(this._y=t,this):this._y};const Ql=1664525,Yl=1013904223,$l=4294967296;function Zl(t){return t.x}function Jl(t){return t.y}var tc=10,ec=Math.PI*(3-Math.sqrt(5));function nc(t){var e,n=1,r=.001,i=1-Math.pow(r,1/300),o=0,a=.6,s=new Map,u=pi(f),l=Ee("tick","end"),c=function(){let t=1;return()=>(t=(Ql*t+Yl)%$l)/$l}();function f(){h(),l.call("tick",e),n<r&&(u.stop(),l.call("end",e))}function h(r){var u,l,c=t.length;void 0===r&&(r=1);for(var f=0;f<r;++f)for(n+=(o-n)*i,s.forEach((function(t){t(n)})),u=0;u<c;++u)null==(l=t[u]).fx?l.x+=l.vx*=a:(l.x=l.fx,l.vx=0),null==l.fy?l.y+=l.vy*=a:(l.y=l.fy,l.vy=0);return e}function d(){for(var e,n=0,r=t.length;n<r;++n){if((e=t[n]).index=n,null!=e.fx&&(e.x=e.fx),null!=e.fy&&(e.y=e.fy),isNaN(e.x)||isNaN(e.y)){var i=tc*Math.sqrt(.5+n),o=n*ec;e.x=i*Math.cos(o),e.y=i*Math.sin(o)}(isNaN(e.vx)||isNaN(e.vy))&&(e.vx=e.vy=0)}}function p(e){return e.initialize&&e.initialize(t,c),e}return null==t&&(t=[]),d(),e={tick:h,restart:function(){return u.restart(f),e},stop:function(){return u.stop(),e},nodes:function(n){return arguments.length?(t=n,d(),s.forEach(p),e):t},alpha:function(t){return arguments.length?(n=+t,e):n},alphaMin:function(t){return arguments.length?(r=+t,e):r},alphaDecay:function(t){return arguments.length?(i=+t,e):+i},alphaTarget:function(t){return arguments.length?(o=+t,e):o},velocityDecay:function(t){return arguments.length?(a=1-t,e):1-a},randomSource:function(t){return arguments.length?(c=t,s.forEach(p),e):c},force:function(t,n){return arguments.length>1?(null==n?s.delete(t):s.set(t,p(n)),e):s.get(t)},find:function(e,n,r){var i,o,a,s,u,l=0,c=t.length;for(null==r?r=1/0:r*=r,l=0;l<c;++l)(a=(i=e-(s=t[l]).x)*i+(o=n-s.y)*o)<r&&(u=s,r=a);return u},on:function(t,n){return arguments.length>1?(l.on(t,n),e):l.on(t)}}}function rc(){var t,e,n,r,i,o=Vl(-30),a=1,s=1/0,u=.81;function l(n){var i,o=t.length,a=Fl(t,Zl,Jl).visitAfter(f);for(r=n,i=0;i<o;++i)e=t[i],a.visit(h)}function c(){if(t){var e,n,r=t.length;for(i=new Array(r),e=0;e<r;++e)n=t[e],i[n.index]=+o(n,e,t)}}function f(t){var e,n,r,o,a,s=0,u=0;if(t.length){for(r=o=a=0;a<4;++a)(e=t[a])&&(n=Math.abs(e.value))&&(s+=e.value,u+=n,r+=n*e.x,o+=n*e.y);t.x=r/u,t.y=o/u}else{(e=t).x=e.data.x,e.y=e.data.y;do{s+=i[e.data.index]}while(e=e.next)}t.value=s}function h(t,o,l,c){if(!t.value)return!0;var f=t.x-e.x,h=t.y-e.y,d=c-o,p=f*f+h*h;if(d*d/u<p)return p<s&&(0===f&&(p+=(f=ql(n))*f),0===h&&(p+=(h=ql(n))*h),p<a&&(p=Math.sqrt(a*p)),e.vx+=f*t.value*r/p,e.vy+=h*t.value*r/p),!0;if(!(t.length||p>=s)){(t.data!==e||t.next)&&(0===f&&(p+=(f=ql(n))*f),0===h&&(p+=(h=ql(n))*h),p<a&&(p=Math.sqrt(a*p)));do{t.data!==e&&(d=i[t.data.index]*r/p,e.vx+=f*d,e.vy+=h*d)}while(t=t.next)}}return l.initialize=function(e,r){t=e,n=r,c()},l.strength=function(t){return arguments.length?(o="function"==typeof t?t:Vl(+t),c(),l):o},l.distanceMin=function(t){return arguments.length?(a=t*t,l):Math.sqrt(a)},l.distanceMax=function(t){return arguments.length?(s=t*t,l):Math.sqrt(s)},l.theta=function(t){return arguments.length?(u=t*t,l):Math.sqrt(u)},l}function ic(t,e,n){var r,i,o,a=Vl(.1);function s(t){for(var a=0,s=r.length;a<s;++a){var u=r[a],l=u.x-e||1e-6,c=u.y-n||1e-6,f=Math.sqrt(l*l+c*c),h=(o[a]-f)*i[a]*t/f;u.vx+=l*h,u.vy+=c*h}}function u(){if(r){var e,n=r.length;for(i=new Array(n),o=new Array(n),e=0;e<n;++e)o[e]=+t(r[e],e,r),i[e]=isNaN(o[e])?0:+a(r[e],e,r)}}return"function"!=typeof t&&(t=Vl(+t)),null==e&&(e=0),null==n&&(n=0),s.initialize=function(t){r=t,u()},s.strength=function(t){return arguments.length?(a="function"==typeof t?t:Vl(+t),u(),s):a},s.radius=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),u(),s):t},s.x=function(t){return arguments.length?(e=+t,s):e},s.y=function(t){return arguments.length?(n=+t,s):n},s}function oc(t){var e,n,r,i=Vl(.1);function o(t){for(var i,o=0,a=e.length;o<a;++o)(i=e[o]).vx+=(r[o]-i.x)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),r=new Array(a),o=0;o<a;++o)n[o]=isNaN(r[o]=+t(e[o],o,e))?0:+i(e[o],o,e)}}return"function"!=typeof t&&(t=Vl(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(i="function"==typeof t?t:Vl(+t),a(),o):i},o.x=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),a(),o):t},o}function ac(t){var e,n,r,i=Vl(.1);function o(t){for(var i,o=0,a=e.length;o<a;++o)(i=e[o]).vy+=(r[o]-i.y)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),r=new Array(a),o=0;o<a;++o)n[o]=isNaN(r[o]=+t(e[o],o,e))?0:+i(e[o],o,e)}}return"function"!=typeof t&&(t=Vl(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(i="function"==typeof t?t:Vl(+t),a(),o):i},o.y=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),a(),o):t},o}function sc(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function uc(t){return(t=sc(Math.abs(t)))?t[1]:NaN}var lc,cc=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function fc(t){if(!(e=cc.exec(t)))throw new Error("invalid format: "+t);var e;return new hc({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function hc(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function dc(t,e){var n=sc(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}fc.prototype=hc.prototype,hc.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var pc={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>dc(100*t,e),r:dc,s:function(t,e){var n=sc(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(lc=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+sc(t,Math.max(0,e+o-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function mc(t){return t}var gc,yc,vc,xc=Array.prototype.map,_c=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function bc(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?mc:(e=xc.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?mc:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(xc.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"−":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=fc(t)).fill,n=t.align,f=t.sign,h=t.symbol,d=t.zero,p=t.width,m=t.comma,g=t.precision,y=t.trim,v=t.type;"n"===v?(m=!0,v="g"):pc[v]||(void 0===g&&(g=12),y=!0,v="g"),(d||"0"===e&&"="===n)&&(d=!0,e="0",n="=");var x="$"===h?i:"#"===h&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",_="$"===h?o:/[%p]/.test(v)?u:"",b=pc[v],w=/[defgprs%]/.test(v);function M(t){var i,o,u,h=x,M=_;if("c"===v)M=b(t)+M,t="";else{var A=(t=+t)<0||1/t<0;if(t=isNaN(t)?c:b(Math.abs(t),g),y&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),A&&0==+t&&"+"!==f&&(A=!1),h=(A?"("===f?f:l:"-"===f||"("===f?"":f)+h,M=("s"===v?_c[8+lc/3]:"")+M+(A&&"("===f?")":""),w)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){M=(46===u?a+t.slice(i+1):t.slice(i))+M,t=t.slice(0,i);break}}m&&!d&&(t=r(t,1/0));var T=h.length+t.length+M.length,E=T<p?new Array(p-T+1).join(e):"";switch(m&&d&&(t=r(E+t,E.length?p-M.length:1/0),E=""),n){case"<":t=h+t+M+E;break;case"=":t=h+E+t+M;break;case"^":t=E.slice(0,T=E.length>>1)+h+t+M+E.slice(T);break;default:t=E+h+t+M}return s(t)}return g=void 0===g?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),M.toString=function(){return t+""},M}return{format:f,formatPrefix:function(t,e){var n=f(((t=fc(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(uc(e)/3))),i=Math.pow(10,-r),o=_c[8+r/3];return function(t){return n(i*t)+o}}}}function wc(t){return gc=bc(t),yc=gc.format,vc=gc.formatPrefix,gc}function Mc(t){return Math.max(0,-uc(Math.abs(t)))}function Ac(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(uc(e)/3)))-uc(Math.abs(t)))}function Tc(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,uc(e)-uc(t))+1}wc({thousands:",",grouping:[3],currency:["$",""]});var Ec=1e-6,Cc=1e-12,kc=Math.PI,Sc=kc/2,Oc=kc/4,Pc=2*kc,Lc=180/kc,Rc=kc/180,Ic=Math.abs,Dc=Math.atan,Nc=Math.atan2,Fc=Math.cos,jc=Math.ceil,zc=Math.exp,Bc=(Math.floor,Math.hypot),Vc=Math.log,qc=Math.pow,Gc=Math.sin,Uc=Math.sign||function(t){return t>0?1:t<0?-1:0},Hc=Math.sqrt,Wc=Math.tan;function Xc(t){return t>1?0:t<-1?kc:Math.acos(t)}function Kc(t){return t>1?Sc:t<-1?-Sc:Math.asin(t)}function Qc(t){return(t=Gc(t/2))*t}function Yc(){}function $c(t,e){t&&Jc.hasOwnProperty(t.type)&&Jc[t.type](t,e)}var Zc={Feature:function(t,e){$c(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)$c(n[r].geometry,e)}},Jc={Sphere:function(t,e){e.sphere()},Point:function(t,e){t=t.coordinates,e.point(t[0],t[1],t[2])},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)t=n[r],e.point(t[0],t[1],t[2])},LineString:function(t,e){tf(t.coordinates,e,0)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)tf(n[r],e,0)},Polygon:function(t,e){ef(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)ef(n[r],e)},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)$c(n[r],e)}};function tf(t,e,n){var r,i=-1,o=t.length-n;for(e.lineStart();++i<o;)r=t[i],e.point(r[0],r[1],r[2]);e.lineEnd()}function ef(t,e){var n=-1,r=t.length;for(e.polygonStart();++n<r;)tf(t[n],e,1);e.polygonEnd()}function nf(t,e){t&&Zc.hasOwnProperty(t.type)?Zc[t.type](t,e):$c(t,e)}var rf,of,af,sf,uf,lf,cf,ff,hf,df,pf,mf,gf,yf,vf,xf,_f=new S,bf=new S,wf={point:Yc,lineStart:Yc,lineEnd:Yc,polygonStart:function(){_f=new S,wf.lineStart=Mf,wf.lineEnd=Af},polygonEnd:function(){var t=+_f;bf.add(t<0?Pc+t:t),this.lineStart=this.lineEnd=this.point=Yc},sphere:function(){bf.add(Pc)}};function Mf(){wf.point=Tf}function Af(){Ef(rf,of)}function Tf(t,e){wf.point=Ef,rf=t,of=e,af=t*=Rc,sf=Fc(e=(e*=Rc)/2+Oc),uf=Gc(e)}function Ef(t,e){var n=(t*=Rc)-af,r=n>=0?1:-1,i=r*n,o=Fc(e=(e*=Rc)/2+Oc),a=Gc(e),s=uf*a,u=sf*o+s*Fc(i),l=s*r*Gc(i);_f.add(Nc(l,u)),af=t,sf=o,uf=a}function Cf(t){return bf=new S,nf(t,wf),2*bf}function kf(t){return[Nc(t[1],t[0]),Kc(t[2])]}function Sf(t){var e=t[0],n=t[1],r=Fc(n);return[r*Fc(e),r*Gc(e),Gc(n)]}function Of(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function Pf(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function Lf(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function Rf(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function If(t){var e=Hc(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}var Df,Nf,Ff,jf,zf,Bf,Vf,qf,Gf,Uf,Hf,Wf,Xf,Kf,Qf,Yf,$f={point:Zf,lineStart:th,lineEnd:eh,polygonStart:function(){$f.point=nh,$f.lineStart=rh,$f.lineEnd=ih,yf=new S,wf.polygonStart()},polygonEnd:function(){wf.polygonEnd(),$f.point=Zf,$f.lineStart=th,$f.lineEnd=eh,_f<0?(lf=-(ff=180),cf=-(hf=90)):yf>Ec?hf=90:yf<-Ec&&(cf=-90),xf[0]=lf,xf[1]=ff},sphere:function(){lf=-(ff=180),cf=-(hf=90)}};function Zf(t,e){vf.push(xf=[lf=t,ff=t]),e<cf&&(cf=e),e>hf&&(hf=e)}function Jf(t,e){var n=Sf([t*Rc,e*Rc]);if(gf){var r=Pf(gf,n),i=Pf([r[1],-r[0],0],r);If(i),i=kf(i);var o,a=t-df,s=a>0?1:-1,u=i[0]*Lc*s,l=Ic(a)>180;l^(s*df<u&&u<s*t)?(o=i[1]*Lc)>hf&&(hf=o):l^(s*df<(u=(u+360)%360-180)&&u<s*t)?(o=-i[1]*Lc)<cf&&(cf=o):(e<cf&&(cf=e),e>hf&&(hf=e)),l?t<df?oh(lf,t)>oh(lf,ff)&&(ff=t):oh(t,ff)>oh(lf,ff)&&(lf=t):ff>=lf?(t<lf&&(lf=t),t>ff&&(ff=t)):t>df?oh(lf,t)>oh(lf,ff)&&(ff=t):oh(t,ff)>oh(lf,ff)&&(lf=t)}else vf.push(xf=[lf=t,ff=t]);e<cf&&(cf=e),e>hf&&(hf=e),gf=n,df=t}function th(){$f.point=Jf}function eh(){xf[0]=lf,xf[1]=ff,$f.point=Zf,gf=null}function nh(t,e){if(gf){var n=t-df;yf.add(Ic(n)>180?n+(n>0?360:-360):n)}else pf=t,mf=e;wf.point(t,e),Jf(t,e)}function rh(){wf.lineStart()}function ih(){nh(pf,mf),wf.lineEnd(),Ic(yf)>Ec&&(lf=-(ff=180)),xf[0]=lf,xf[1]=ff,gf=null}function oh(t,e){return(e-=t)<0?e+360:e}function ah(t,e){return t[0]-e[0]}function sh(t,e){return t[0]<=t[1]?t[0]<=e&&e<=t[1]:e<t[0]||t[1]<e}function uh(t){var e,n,r,i,o,a,s;if(hf=ff=-(lf=cf=1/0),vf=[],nf(t,$f),n=vf.length){for(vf.sort(ah),e=1,o=[r=vf[0]];e<n;++e)sh(r,(i=vf[e])[0])||sh(r,i[1])?(oh(r[0],i[1])>oh(r[0],r[1])&&(r[1]=i[1]),oh(i[0],r[1])>oh(r[0],r[1])&&(r[0]=i[0])):o.push(r=i);for(a=-1/0,e=0,r=o[n=o.length-1];e<=n;r=i,++e)i=o[e],(s=oh(r[1],i[0]))>a&&(a=s,lf=i[0],ff=r[1])}return vf=xf=null,lf===1/0||cf===1/0?[[NaN,NaN],[NaN,NaN]]:[[lf,cf],[ff,hf]]}var lh={sphere:Yc,point:ch,lineStart:hh,lineEnd:mh,polygonStart:function(){lh.lineStart=gh,lh.lineEnd=yh},polygonEnd:function(){lh.lineStart=hh,lh.lineEnd=mh}};function ch(t,e){t*=Rc;var n=Fc(e*=Rc);fh(n*Fc(t),n*Gc(t),Gc(e))}function fh(t,e,n){++Df,Ff+=(t-Ff)/Df,jf+=(e-jf)/Df,zf+=(n-zf)/Df}function hh(){lh.point=dh}function dh(t,e){t*=Rc;var n=Fc(e*=Rc);Kf=n*Fc(t),Qf=n*Gc(t),Yf=Gc(e),lh.point=ph,fh(Kf,Qf,Yf)}function ph(t,e){t*=Rc;var n=Fc(e*=Rc),r=n*Fc(t),i=n*Gc(t),o=Gc(e),a=Nc(Hc((a=Qf*o-Yf*i)*a+(a=Yf*r-Kf*o)*a+(a=Kf*i-Qf*r)*a),Kf*r+Qf*i+Yf*o);Nf+=a,Bf+=a*(Kf+(Kf=r)),Vf+=a*(Qf+(Qf=i)),qf+=a*(Yf+(Yf=o)),fh(Kf,Qf,Yf)}function mh(){lh.point=ch}function gh(){lh.point=vh}function yh(){xh(Wf,Xf),lh.point=ch}function vh(t,e){Wf=t,Xf=e,t*=Rc,e*=Rc,lh.point=xh;var n=Fc(e);Kf=n*Fc(t),Qf=n*Gc(t),Yf=Gc(e),fh(Kf,Qf,Yf)}function xh(t,e){t*=Rc;var n=Fc(e*=Rc),r=n*Fc(t),i=n*Gc(t),o=Gc(e),a=Qf*o-Yf*i,s=Yf*r-Kf*o,u=Kf*i-Qf*r,l=Bc(a,s,u),c=Kc(l),f=l&&-c/l;Gf.add(f*a),Uf.add(f*s),Hf.add(f*u),Nf+=c,Bf+=c*(Kf+(Kf=r)),Vf+=c*(Qf+(Qf=i)),qf+=c*(Yf+(Yf=o)),fh(Kf,Qf,Yf)}function _h(t){Df=Nf=Ff=jf=zf=Bf=Vf=qf=0,Gf=new S,Uf=new S,Hf=new S,nf(t,lh);var e=+Gf,n=+Uf,r=+Hf,i=Bc(e,n,r);return i<Cc&&(e=Bf,n=Vf,r=qf,Nf<Ec&&(e=Ff,n=jf,r=zf),(i=Bc(e,n,r))<Cc)?[NaN,NaN]:[Nc(n,e)*Lc,Kc(r/i)*Lc]}function bh(t){return function(){return t}}function wh(t,e){function n(n,r){return n=t(n,r),e(n[0],n[1])}return t.invert&&e.invert&&(n.invert=function(n,r){return(n=e.invert(n,r))&&t.invert(n[0],n[1])}),n}function Mh(t,e){return Ic(t)>kc&&(t-=Math.round(t/Pc)*Pc),[t,e]}function Ah(t,e,n){return(t%=Pc)?e||n?wh(Eh(t),Ch(e,n)):Eh(t):e||n?Ch(e,n):Mh}function Th(t){return function(e,n){return Ic(e+=t)>kc&&(e-=Math.round(e/Pc)*Pc),[e,n]}}function Eh(t){var e=Th(t);return e.invert=Th(-t),e}function Ch(t,e){var n=Fc(t),r=Gc(t),i=Fc(e),o=Gc(e);function a(t,e){var a=Fc(e),s=Fc(t)*a,u=Gc(t)*a,l=Gc(e),c=l*n+s*r;return[Nc(u*i-c*o,s*n-l*r),Kc(c*i+u*o)]}return a.invert=function(t,e){var a=Fc(e),s=Fc(t)*a,u=Gc(t)*a,l=Gc(e),c=l*i-u*o;return[Nc(u*i+l*o,s*n+c*r),Kc(c*n-s*r)]},a}function kh(t){function e(e){return(e=t(e[0]*Rc,e[1]*Rc))[0]*=Lc,e[1]*=Lc,e}return t=Ah(t[0]*Rc,t[1]*Rc,t.length>2?t[2]*Rc:0),e.invert=function(e){return(e=t.invert(e[0]*Rc,e[1]*Rc))[0]*=Lc,e[1]*=Lc,e},e}function Sh(t,e,n,r,i,o){if(n){var a=Fc(e),s=Gc(e),u=r*n;null==i?(i=e+r*Pc,o=e-u/2):(i=Oh(a,i),o=Oh(a,o),(r>0?i<o:i>o)&&(i+=r*Pc));for(var l,c=i;r>0?c>o:c<o;c-=u)l=kf([a,-s*Fc(c),-s*Gc(c)]),t.point(l[0],l[1])}}function Oh(t,e){(e=Sf(e))[0]-=t,If(e);var n=Xc(-e[1]);return((-e[2]<0?-n:n)+Pc-Ec)%Pc}function Ph(){var t,e,n=bh([0,0]),r=bh(90),i=bh(2),o={point:function(n,r){t.push(n=e(n,r)),n[0]*=Lc,n[1]*=Lc}};function a(){var a=n.apply(this,arguments),s=r.apply(this,arguments)*Rc,u=i.apply(this,arguments)*Rc;return t=[],e=Ah(-a[0]*Rc,-a[1]*Rc,0).invert,Sh(o,s,u,1),a={type:"Polygon",coordinates:[t]},t=e=null,a}return a.center=function(t){return arguments.length?(n="function"==typeof t?t:bh([+t[0],+t[1]]),a):n},a.radius=function(t){return arguments.length?(r="function"==typeof t?t:bh(+t),a):r},a.precision=function(t){return arguments.length?(i="function"==typeof t?t:bh(+t),a):i},a}function Lh(){var t,e=[];return{point:function(e,n,r){t.push([e,n,r])},lineStart:function(){e.push(t=[])},lineEnd:Yc,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function Rh(t,e){return Ic(t[0]-e[0])<Ec&&Ic(t[1]-e[1])<Ec}function Ih(t,e,n,r){this.x=t,this.z=e,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Dh(t,e,n,r,i){var o,a,s=[],u=[];if(t.forEach((function(t){if(!((e=t.length-1)<=0)){var e,n,r=t[0],a=t[e];if(Rh(r,a)){if(!r[2]&&!a[2]){for(i.lineStart(),o=0;o<e;++o)i.point((r=t[o])[0],r[1]);return void i.lineEnd()}a[0]+=2*Ec}s.push(n=new Ih(r,t,null,!0)),u.push(n.o=new Ih(r,null,n,!1)),s.push(n=new Ih(a,t,null,!1)),u.push(n.o=new Ih(a,null,n,!0))}})),s.length){for(u.sort(e),Nh(s),Nh(u),o=0,a=u.length;o<a;++o)u[o].e=n=!n;for(var l,c,f=s[0];;){for(var h=f,d=!0;h.v;)if((h=h.n)===f)return;l=h.z,i.lineStart();do{if(h.v=h.o.v=!0,h.e){if(d)for(o=0,a=l.length;o<a;++o)i.point((c=l[o])[0],c[1]);else r(h.x,h.n.x,1,i);h=h.n}else{if(d)for(l=h.p.z,o=l.length-1;o>=0;--o)i.point((c=l[o])[0],c[1]);else r(h.x,h.p.x,-1,i);h=h.p}l=(h=h.o).z,d=!d}while(!h.v);i.lineEnd()}}}function Nh(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r<e;)i.n=n=t[r],n.p=i,i=n;i.n=n=t[0],n.p=i}}function Fh(t){return Ic(t[0])<=kc?t[0]:Uc(t[0])*((Ic(t[0])+kc)%Pc-kc)}function jh(t,e){var n=Fh(e),r=e[1],i=Gc(r),o=[Gc(n),-Fc(n),0],a=0,s=0,u=new S;1===i?r=Sc+Ec:-1===i&&(r=-Sc-Ec);for(var l=0,c=t.length;l<c;++l)if(h=(f=t[l]).length)for(var f,h,d=f[h-1],p=Fh(d),m=d[1]/2+Oc,g=Gc(m),y=Fc(m),v=0;v<h;++v,p=_,g=w,y=M,d=x){var x=f[v],_=Fh(x),b=x[1]/2+Oc,w=Gc(b),M=Fc(b),A=_-p,T=A>=0?1:-1,E=T*A,C=E>kc,k=g*w;if(u.add(Nc(k*T*Gc(E),y*M+k*Fc(E))),a+=C?A+T*Pc:A,C^p>=n^_>=n){var O=Pf(Sf(d),Sf(x));If(O);var P=Pf(o,O);If(P);var L=(C^A>=0?-1:1)*Kc(P[2]);(r>L||r===L&&(O[0]||O[1]))&&(s+=C^A>=0?1:-1)}}return(a<-Ec||a<Ec&&u<-Cc)^1&s}function zh(t,e,n,r){return function(i){var o,a,s,u=e(i),l=Lh(),c=e(l),f=!1,h={point:d,lineStart:m,lineEnd:g,polygonStart:function(){h.point=y,h.lineStart=v,h.lineEnd=x,a=[],o=[]},polygonEnd:function(){h.point=d,h.lineStart=m,h.lineEnd=g,a=St(a);var t=jh(o,r);a.length?(f||(i.polygonStart(),f=!0),Dh(a,Vh,t,n,i)):t&&(f||(i.polygonStart(),f=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),f&&(i.polygonEnd(),f=!1),a=o=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function d(e,n){t(e,n)&&i.point(e,n)}function p(t,e){u.point(t,e)}function m(){h.point=p,u.lineStart()}function g(){h.point=d,u.lineEnd()}function y(t,e){s.push([t,e]),c.point(t,e)}function v(){c.lineStart(),s=[]}function x(){y(s[0][0],s[0][1]),c.lineEnd();var t,e,n,r,u=c.clean(),h=l.result(),d=h.length;if(s.pop(),o.push(s),s=null,d)if(1&u){if((e=(n=h[0]).length-1)>0){for(f||(i.polygonStart(),f=!0),i.lineStart(),t=0;t<e;++t)i.point((r=n[t])[0],r[1]);i.lineEnd()}}else d>1&&2&u&&h.push(h.pop().concat(h.shift())),a.push(h.filter(Bh))}return h}}function Bh(t){return t.length>1}function Vh(t,e){return((t=t.x)[0]<0?t[1]-Sc-Ec:Sc-t[1])-((e=e.x)[0]<0?e[1]-Sc-Ec:Sc-e[1])}Mh.invert=Mh;var qh=zh((function(){return!0}),(function(t){var e,n=NaN,r=NaN,i=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(o,a){var s=o>0?kc:-kc,u=Ic(o-n);Ic(u-kc)<Ec?(t.point(n,r=(r+a)/2>0?Sc:-Sc),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),t.point(o,r),e=0):i!==s&&u>=kc&&(Ic(n-i)<Ec&&(n-=i*Ec),Ic(o-s)<Ec&&(o-=s*Ec),r=function(t,e,n,r){var i,o,a=Gc(t-n);return Ic(a)>Ec?Dc((Gc(e)*(o=Fc(r))*Gc(n)-Gc(r)*(i=Fc(e))*Gc(t))/(i*o*a)):(e+r)/2}(n,r,o,a),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),e=0),t.point(n=o,r=a),i=s},lineEnd:function(){t.lineEnd(),n=r=NaN},clean:function(){return 2-e}}}),(function(t,e,n,r){var i;if(null==t)i=n*Sc,r.point(-kc,i),r.point(0,i),r.point(kc,i),r.point(kc,0),r.point(kc,-i),r.point(0,-i),r.point(-kc,-i),r.point(-kc,0),r.point(-kc,i);else if(Ic(t[0]-e[0])>Ec){var o=t[0]<e[0]?kc:-kc;i=n*o/2,r.point(-o,i),r.point(0,i),r.point(o,i)}else r.point(e[0],e[1])}),[-kc,-Sc]);function Gh(t){var e=Fc(t),n=2*Rc,r=e>0,i=Ic(e)>Ec;function o(t,n){return Fc(t)*Fc(n)>e}function a(t,n,r){var i=[1,0,0],o=Pf(Sf(t),Sf(n)),a=Of(o,o),s=o[0],u=a-s*s;if(!u)return!r&&t;var l=e*a/u,c=-e*s/u,f=Pf(i,o),h=Rf(i,l);Lf(h,Rf(o,c));var d=f,p=Of(h,d),m=Of(d,d),g=p*p-m*(Of(h,h)-1);if(!(g<0)){var y=Hc(g),v=Rf(d,(-p-y)/m);if(Lf(v,h),v=kf(v),!r)return v;var x,_=t[0],b=n[0],w=t[1],M=n[1];b<_&&(x=_,_=b,b=x);var A=b-_,T=Ic(A-kc)<Ec;if(!T&&M<w&&(x=w,w=M,M=x),T||A<Ec?T?w+M>0^v[1]<(Ic(v[0]-_)<Ec?w:M):w<=v[1]&&v[1]<=M:A>kc^(_<=v[0]&&v[0]<=b)){var E=Rf(d,(-p+y)/m);return Lf(E,h),[v,kf(E)]}}}function s(e,n){var i=r?t:kc-t,o=0;return e<-i?o|=1:e>i&&(o|=2),n<-i?o|=4:n>i&&(o|=8),o}return zh(o,(function(t){var e,n,u,l,c;return{lineStart:function(){l=u=!1,c=1},point:function(f,h){var d,p=[f,h],m=o(f,h),g=r?m?0:s(f,h):m?s(f+(f<0?kc:-kc),h):0;if(!e&&(l=u=m)&&t.lineStart(),m!==u&&(!(d=a(e,p))||Rh(e,d)||Rh(p,d))&&(p[2]=1),m!==u)c=0,m?(t.lineStart(),d=a(p,e),t.point(d[0],d[1])):(d=a(e,p),t.point(d[0],d[1],2),t.lineEnd()),e=d;else if(i&&e&&r^m){var y;g&n||!(y=a(p,e,!0))||(c=0,r?(t.lineStart(),t.point(y[0][0],y[0][1]),t.point(y[1][0],y[1][1]),t.lineEnd()):(t.point(y[1][0],y[1][1]),t.lineEnd(),t.lineStart(),t.point(y[0][0],y[0][1],3)))}!m||e&&Rh(e,p)||t.point(p[0],p[1]),e=p,u=m,n=g},lineEnd:function(){u&&t.lineEnd(),e=null},clean:function(){return c|(l&&u)<<1}}}),(function(e,r,i,o){Sh(o,t,n,i,e,r)}),r?[0,-t]:[-kc,t-kc])}var Uh,Hh,Wh,Xh,Kh=1e9,Qh=-Kh;function Yh(t,e,n,r){function i(i,o){return t<=i&&i<=n&&e<=o&&o<=r}function o(i,o,s,l){var c=0,f=0;if(null==i||(c=a(i,s))!==(f=a(o,s))||u(i,o)<0^s>0)do{l.point(0===c||3===c?t:n,c>1?r:e)}while((c=(c+s+4)%4)!==f);else l.point(o[0],o[1])}function a(r,i){return Ic(r[0]-t)<Ec?i>0?0:3:Ic(r[0]-n)<Ec?i>0?2:1:Ic(r[1]-e)<Ec?i>0?1:0:i>0?3:2}function s(t,e){return u(t.x,e.x)}function u(t,e){var n=a(t,1),r=a(e,1);return n!==r?n-r:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(a){var u,l,c,f,h,d,p,m,g,y,v,x=a,_=Lh(),b={point:w,lineStart:function(){b.point=M,l&&l.push(c=[]);y=!0,g=!1,p=m=NaN},lineEnd:function(){u&&(M(f,h),d&&g&&_.rejoin(),u.push(_.result()));b.point=w,g&&x.lineEnd()},polygonStart:function(){x=_,u=[],l=[],v=!0},polygonEnd:function(){var e=function(){for(var e=0,n=0,i=l.length;n<i;++n)for(var o,a,s=l[n],u=1,c=s.length,f=s[0],h=f[0],d=f[1];u<c;++u)o=h,a=d,h=(f=s[u])[0],d=f[1],a<=r?d>r&&(h-o)*(r-a)>(d-a)*(t-o)&&++e:d<=r&&(h-o)*(r-a)<(d-a)*(t-o)&&--e;return e}(),n=v&&e,i=(u=St(u)).length;(n||i)&&(a.polygonStart(),n&&(a.lineStart(),o(null,null,1,a),a.lineEnd()),i&&Dh(u,s,e,o,a),a.polygonEnd());x=a,u=l=c=null}};function w(t,e){i(t,e)&&x.point(t,e)}function M(o,a){var s=i(o,a);if(l&&c.push([o,a]),y)f=o,h=a,d=s,y=!1,s&&(x.lineStart(),x.point(o,a));else if(s&&g)x.point(o,a);else{var u=[p=Math.max(Qh,Math.min(Kh,p)),m=Math.max(Qh,Math.min(Kh,m))],_=[o=Math.max(Qh,Math.min(Kh,o)),a=Math.max(Qh,Math.min(Kh,a))];!function(t,e,n,r,i,o){var a,s=t[0],u=t[1],l=0,c=1,f=e[0]-s,h=e[1]-u;if(a=n-s,f||!(a>0)){if(a/=f,f<0){if(a<l)return;a<c&&(c=a)}else if(f>0){if(a>c)return;a>l&&(l=a)}if(a=i-s,f||!(a<0)){if(a/=f,f<0){if(a>c)return;a>l&&(l=a)}else if(f>0){if(a<l)return;a<c&&(c=a)}if(a=r-u,h||!(a>0)){if(a/=h,h<0){if(a<l)return;a<c&&(c=a)}else if(h>0){if(a>c)return;a>l&&(l=a)}if(a=o-u,h||!(a<0)){if(a/=h,h<0){if(a>c)return;a>l&&(l=a)}else if(h>0){if(a<l)return;a<c&&(c=a)}return l>0&&(t[0]=s+l*f,t[1]=u+l*h),c<1&&(e[0]=s+c*f,e[1]=u+c*h),!0}}}}}(u,_,t,e,n,r)?s&&(x.lineStart(),x.point(o,a),v=!1):(g||(x.lineStart(),x.point(u[0],u[1])),x.point(_[0],_[1]),s||x.lineEnd(),v=!1)}p=o,m=a,g=s}return b}}function $h(){var t,e,n,r=0,i=0,o=960,a=500;return n={stream:function(n){return t&&e===n?t:t=Yh(r,i,o,a)(e=n)},extent:function(s){return arguments.length?(r=+s[0][0],i=+s[0][1],o=+s[1][0],a=+s[1][1],t=e=null,n):[[r,i],[o,a]]}}}var Zh={sphere:Yc,point:Yc,lineStart:function(){Zh.point=td,Zh.lineEnd=Jh},lineEnd:Yc,polygonStart:Yc,polygonEnd:Yc};function Jh(){Zh.point=Zh.lineEnd=Yc}function td(t,e){Hh=t*=Rc,Wh=Gc(e*=Rc),Xh=Fc(e),Zh.point=ed}function ed(t,e){t*=Rc;var n=Gc(e*=Rc),r=Fc(e),i=Ic(t-Hh),o=Fc(i),a=r*Gc(i),s=Xh*n-Wh*r*o,u=Wh*n+Xh*r*o;Uh.add(Nc(Hc(a*a+s*s),u)),Hh=t,Wh=n,Xh=r}function nd(t){return Uh=new S,nf(t,Zh),+Uh}var rd=[null,null],id={type:"LineString",coordinates:rd};function od(t,e){return rd[0]=t,rd[1]=e,nd(id)}var ad={Feature:function(t,e){return ud(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)if(ud(n[r].geometry,e))return!0;return!1}},sd={Sphere:function(){return!0},Point:function(t,e){return ld(t.coordinates,e)},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(ld(n[r],e))return!0;return!1},LineString:function(t,e){return cd(t.coordinates,e)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(cd(n[r],e))return!0;return!1},Polygon:function(t,e){return fd(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(fd(n[r],e))return!0;return!1},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)if(ud(n[r],e))return!0;return!1}};function ud(t,e){return!(!t||!sd.hasOwnProperty(t.type))&&sd[t.type](t,e)}function ld(t,e){return 0===od(t,e)}function cd(t,e){for(var n,r,i,o=0,a=t.length;o<a;o++){if(0===(r=od(t[o],e)))return!0;if(o>0&&(i=od(t[o],t[o-1]))>0&&n<=i&&r<=i&&(n+r-i)*(1-Math.pow((n-r)/i,2))<Cc*i)return!0;n=r}return!1}function fd(t,e){return!!jh(t.map(hd),dd(e))}function hd(t){return(t=t.map(dd)).pop(),t}function dd(t){return[t[0]*Rc,t[1]*Rc]}function pd(t,e){return(t&&ad.hasOwnProperty(t.type)?ad[t.type]:ud)(t,e)}function md(t,e,n){var r=Rt(t,e-Ec,n).concat(e);return function(t){return r.map((function(e){return[t,e]}))}}function gd(t,e,n){var r=Rt(t,e-Ec,n).concat(e);return function(t){return r.map((function(e){return[e,t]}))}}function yd(){var t,e,n,r,i,o,a,s,u,l,c,f,h=10,d=h,p=90,m=360,g=2.5;function y(){return{type:"MultiLineString",coordinates:v()}}function v(){return Rt(jc(r/p)*p,n,p).map(c).concat(Rt(jc(s/m)*m,a,m).map(f)).concat(Rt(jc(e/h)*h,t,h).filter((function(t){return Ic(t%p)>Ec})).map(u)).concat(Rt(jc(o/d)*d,i,d).filter((function(t){return Ic(t%m)>Ec})).map(l))}return y.lines=function(){return v().map((function(t){return{type:"LineString",coordinates:t}}))},y.outline=function(){return{type:"Polygon",coordinates:[c(r).concat(f(a).slice(1),c(n).reverse().slice(1),f(s).reverse().slice(1))]}},y.extent=function(t){return arguments.length?y.extentMajor(t).extentMinor(t):y.extentMinor()},y.extentMajor=function(t){return arguments.length?(r=+t[0][0],n=+t[1][0],s=+t[0][1],a=+t[1][1],r>n&&(t=r,r=n,n=t),s>a&&(t=s,s=a,a=t),y.precision(g)):[[r,s],[n,a]]},y.extentMinor=function(n){return arguments.length?(e=+n[0][0],t=+n[1][0],o=+n[0][1],i=+n[1][1],e>t&&(n=e,e=t,t=n),o>i&&(n=o,o=i,i=n),y.precision(g)):[[e,o],[t,i]]},y.step=function(t){return arguments.length?y.stepMajor(t).stepMinor(t):y.stepMinor()},y.stepMajor=function(t){return arguments.length?(p=+t[0],m=+t[1],y):[p,m]},y.stepMinor=function(t){return arguments.length?(h=+t[0],d=+t[1],y):[h,d]},y.precision=function(h){return arguments.length?(g=+h,u=md(o,i,90),l=gd(e,t,g),c=md(s,a,90),f=gd(r,n,g),y):g},y.extentMajor([[-180,-90+Ec],[180,90-Ec]]).extentMinor([[-180,-80-Ec],[180,80+Ec]])}function vd(){return yd()()}function xd(t,e){var n=t[0]*Rc,r=t[1]*Rc,i=e[0]*Rc,o=e[1]*Rc,a=Fc(r),s=Gc(r),u=Fc(o),l=Gc(o),c=a*Fc(n),f=a*Gc(n),h=u*Fc(i),d=u*Gc(i),p=2*Kc(Hc(Qc(o-r)+a*u*Qc(i-n))),m=Gc(p),g=p?function(t){var e=Gc(t*=p)/m,n=Gc(p-t)/m,r=n*c+e*h,i=n*f+e*d,o=n*s+e*l;return[Nc(i,r)*Lc,Nc(o,Hc(r*r+i*i))*Lc]}:function(){return[n*Lc,r*Lc]};return g.distance=p,g}var _d,bd,wd,Md,Ad=t=>t,Td=new S,Ed=new S,Cd={point:Yc,lineStart:Yc,lineEnd:Yc,polygonStart:function(){Cd.lineStart=kd,Cd.lineEnd=Pd},polygonEnd:function(){Cd.lineStart=Cd.lineEnd=Cd.point=Yc,Td.add(Ic(Ed)),Ed=new S},result:function(){var t=Td/2;return Td=new S,t}};function kd(){Cd.point=Sd}function Sd(t,e){Cd.point=Od,_d=wd=t,bd=Md=e}function Od(t,e){Ed.add(Md*t-wd*e),wd=t,Md=e}function Pd(){Od(_d,bd)}var Ld=Cd,Rd=1/0,Id=Rd,Dd=-Rd,Nd=Dd,Fd={point:function(t,e){t<Rd&&(Rd=t);t>Dd&&(Dd=t);e<Id&&(Id=e);e>Nd&&(Nd=e)},lineStart:Yc,lineEnd:Yc,polygonStart:Yc,polygonEnd:Yc,result:function(){var t=[[Rd,Id],[Dd,Nd]];return Dd=Nd=-(Id=Rd=1/0),t}};var jd,zd,Bd,Vd,qd=Fd,Gd=0,Ud=0,Hd=0,Wd=0,Xd=0,Kd=0,Qd=0,Yd=0,$d=0,Zd={point:Jd,lineStart:tp,lineEnd:rp,polygonStart:function(){Zd.lineStart=ip,Zd.lineEnd=op},polygonEnd:function(){Zd.point=Jd,Zd.lineStart=tp,Zd.lineEnd=rp},result:function(){var t=$d?[Qd/$d,Yd/$d]:Kd?[Wd/Kd,Xd/Kd]:Hd?[Gd/Hd,Ud/Hd]:[NaN,NaN];return Gd=Ud=Hd=Wd=Xd=Kd=Qd=Yd=$d=0,t}};function Jd(t,e){Gd+=t,Ud+=e,++Hd}function tp(){Zd.point=ep}function ep(t,e){Zd.point=np,Jd(Bd=t,Vd=e)}function np(t,e){var n=t-Bd,r=e-Vd,i=Hc(n*n+r*r);Wd+=i*(Bd+t)/2,Xd+=i*(Vd+e)/2,Kd+=i,Jd(Bd=t,Vd=e)}function rp(){Zd.point=Jd}function ip(){Zd.point=ap}function op(){sp(jd,zd)}function ap(t,e){Zd.point=sp,Jd(jd=Bd=t,zd=Vd=e)}function sp(t,e){var n=t-Bd,r=e-Vd,i=Hc(n*n+r*r);Wd+=i*(Bd+t)/2,Xd+=i*(Vd+e)/2,Kd+=i,Qd+=(i=Vd*t-Bd*e)*(Bd+t),Yd+=i*(Vd+e),$d+=3*i,Jd(Bd=t,Vd=e)}var up=Zd;function lp(t){this._context=t}lp.prototype={_radius:4.5,pointRadius:function(t){return this._radius=t,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._context.closePath(),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._context.moveTo(t,e),this._point=1;break;case 1:this._context.lineTo(t,e);break;default:this._context.moveTo(t+this._radius,e),this._context.arc(t,e,this._radius,0,Pc)}},result:Yc};var cp,fp,hp,dp,pp,mp=new S,gp={point:Yc,lineStart:function(){gp.point=yp},lineEnd:function(){cp&&vp(fp,hp),gp.point=Yc},polygonStart:function(){cp=!0},polygonEnd:function(){cp=null},result:function(){var t=+mp;return mp=new S,t}};function yp(t,e){gp.point=vp,fp=dp=t,hp=pp=e}function vp(t,e){dp-=t,pp-=e,mp.add(Hc(dp*dp+pp*pp)),dp=t,pp=e}var xp=gp;let _p,bp,wp,Mp;class Ap{constructor(t){this._append=null==t?Tp:function(t){const e=Math.floor(t);if(!(e>=0))throw new RangeError(`invalid digits: ${t}`);if(e>15)return Tp;if(e!==_p){const t=10**e;_p=e,bp=function(e){let n=1;this._+=e[0];for(const r=e.length;n<r;++n)this._+=Math.round(arguments[n]*t)/t+e[n]}}return bp}(t),this._radius=4.5,this._=""}pointRadius(t){return this._radius=+t,this}polygonStart(){this._line=0}polygonEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){0===this._line&&(this._+="Z"),this._point=NaN}point(t,e){switch(this._point){case 0:this._append`M${t},${e}`,this._point=1;break;case 1:this._append`L${t},${e}`;break;default:if(this._append`M${t},${e}`,this._radius!==wp||this._append!==bp){const t=this._radius,e=this._;this._="",this._append`m0,${t}a${t},${t} 0 1,1 0,${-2*t}a${t},${t} 0 1,1 0,${2*t}z`,wp=t,bp=this._append,Mp=this._,this._=e}this._+=Mp}}result(){const t=this._;return this._="",t.length?t:null}}function Tp(t){let e=1;this._+=t[0];for(const n=t.length;e<n;++e)this._+=arguments[e]+t[e]}function Ep(t,e){let n,r,i=3,o=4.5;function a(t){return t&&("function"==typeof o&&r.pointRadius(+o.apply(this,arguments)),nf(t,n(r))),r.result()}return a.area=function(t){return nf(t,n(Ld)),Ld.result()},a.measure=function(t){return nf(t,n(xp)),xp.result()},a.bounds=function(t){return nf(t,n(qd)),qd.result()},a.centroid=function(t){return nf(t,n(up)),up.result()},a.projection=function(e){return arguments.length?(n=null==e?(t=null,Ad):(t=e).stream,a):t},a.context=function(t){return arguments.length?(r=null==t?(e=null,new Ap(i)):new lp(e=t),"function"!=typeof o&&r.pointRadius(o),a):e},a.pointRadius=function(t){return arguments.length?(o="function"==typeof t?t:(r.pointRadius(+t),+t),a):o},a.digits=function(t){if(!arguments.length)return i;if(null==t)i=null;else{const e=Math.floor(t);if(!(e>=0))throw new RangeError(`invalid digits: ${t}`);i=e}return null===e&&(r=new Ap(i)),a},a.projection(t).digits(i).context(e)}function Cp(t){return{stream:kp(t)}}function kp(t){return function(e){var n=new Sp;for(var r in t)n[r]=t[r];return n.stream=e,n}}function Sp(){}function Op(t,e,n){var r=t.clipExtent&&t.clipExtent();return t.scale(150).translate([0,0]),null!=r&&t.clipExtent(null),nf(n,t.stream(qd)),e(qd.result()),null!=r&&t.clipExtent(r),t}function Pp(t,e,n){return Op(t,(function(n){var r=e[1][0]-e[0][0],i=e[1][1]-e[0][1],o=Math.min(r/(n[1][0]-n[0][0]),i/(n[1][1]-n[0][1])),a=+e[0][0]+(r-o*(n[1][0]+n[0][0]))/2,s=+e[0][1]+(i-o*(n[1][1]+n[0][1]))/2;t.scale(150*o).translate([a,s])}),n)}function Lp(t,e,n){return Pp(t,[[0,0],e],n)}function Rp(t,e,n){return Op(t,(function(n){var r=+e,i=r/(n[1][0]-n[0][0]),o=(r-i*(n[1][0]+n[0][0]))/2,a=-i*n[0][1];t.scale(150*i).translate([o,a])}),n)}function Ip(t,e,n){return Op(t,(function(n){var r=+e,i=r/(n[1][1]-n[0][1]),o=-i*n[0][0],a=(r-i*(n[1][1]+n[0][1]))/2;t.scale(150*i).translate([o,a])}),n)}Sp.prototype={constructor:Sp,point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};var Dp=16,Np=Fc(30*Rc);function Fp(t,e){return+e?function(t,e){function n(r,i,o,a,s,u,l,c,f,h,d,p,m,g){var y=l-r,v=c-i,x=y*y+v*v;if(x>4*e&&m--){var _=a+h,b=s+d,w=u+p,M=Hc(_*_+b*b+w*w),A=Kc(w/=M),T=Ic(Ic(w)-1)<Ec||Ic(o-f)<Ec?(o+f)/2:Nc(b,_),E=t(T,A),C=E[0],k=E[1],S=C-r,O=k-i,P=v*S-y*O;(P*P/x>e||Ic((y*S+v*O)/x-.5)>.3||a*h+s*d+u*p<Np)&&(n(r,i,o,a,s,u,C,k,T,_/=M,b/=M,w,m,g),g.point(C,k),n(C,k,T,_,b,w,l,c,f,h,d,p,m,g))}}return function(e){var r,i,o,a,s,u,l,c,f,h,d,p,m={point:g,lineStart:y,lineEnd:x,polygonStart:function(){e.polygonStart(),m.lineStart=_},polygonEnd:function(){e.polygonEnd(),m.lineStart=y}};function g(n,r){n=t(n,r),e.point(n[0],n[1])}function y(){c=NaN,m.point=v,e.lineStart()}function v(r,i){var o=Sf([r,i]),a=t(r,i);n(c,f,l,h,d,p,c=a[0],f=a[1],l=r,h=o[0],d=o[1],p=o[2],Dp,e),e.point(c,f)}function x(){m.point=g,e.lineEnd()}function _(){y(),m.point=b,m.lineEnd=w}function b(t,e){v(r=t,e),i=c,o=f,a=h,s=d,u=p,m.point=v}function w(){n(c,f,l,h,d,p,i,o,r,a,s,u,Dp,e),m.lineEnd=x,x()}return m}}(t,e):function(t){return kp({point:function(e,n){e=t(e,n),this.stream.point(e[0],e[1])}})}(t)}var jp=kp({point:function(t,e){this.stream.point(t*Rc,e*Rc)}});function zp(t,e,n,r,i,o){if(!o)return function(t,e,n,r,i){function o(o,a){return[e+t*(o*=r),n-t*(a*=i)]}return o.invert=function(o,a){return[(o-e)/t*r,(n-a)/t*i]},o}(t,e,n,r,i);var a=Fc(o),s=Gc(o),u=a*t,l=s*t,c=a/t,f=s/t,h=(s*n-a*e)/t,d=(s*e+a*n)/t;function p(t,o){return[u*(t*=r)-l*(o*=i)+e,n-l*t-u*o]}return p.invert=function(t,e){return[r*(c*t-f*e+h),i*(d-f*t-c*e)]},p}function Bp(t){return Vp((function(){return t}))()}function Vp(t){var e,n,r,i,o,a,s,u,l,c,f=150,h=480,d=250,p=0,m=0,g=0,y=0,v=0,x=0,_=1,b=1,w=null,M=qh,A=null,T=Ad,E=.5;function C(t){return u(t[0]*Rc,t[1]*Rc)}function k(t){return(t=u.invert(t[0],t[1]))&&[t[0]*Lc,t[1]*Lc]}function S(){var t=zp(f,0,0,_,b,x).apply(null,e(p,m)),r=zp(f,h-t[0],d-t[1],_,b,x);return n=Ah(g,y,v),s=wh(e,r),u=wh(n,s),a=Fp(s,E),O()}function O(){return l=c=null,C}return C.stream=function(t){return l&&c===t?l:l=jp(function(t){return kp({point:function(e,n){var r=t(e,n);return this.stream.point(r[0],r[1])}})}(n)(M(a(T(c=t)))))},C.preclip=function(t){return arguments.length?(M=t,w=void 0,O()):M},C.postclip=function(t){return arguments.length?(T=t,A=r=i=o=null,O()):T},C.clipAngle=function(t){return arguments.length?(M=+t?Gh(w=t*Rc):(w=null,qh),O()):w*Lc},C.clipExtent=function(t){return arguments.length?(T=null==t?(A=r=i=o=null,Ad):Yh(A=+t[0][0],r=+t[0][1],i=+t[1][0],o=+t[1][1]),O()):null==A?null:[[A,r],[i,o]]},C.scale=function(t){return arguments.length?(f=+t,S()):f},C.translate=function(t){return arguments.length?(h=+t[0],d=+t[1],S()):[h,d]},C.center=function(t){return arguments.length?(p=t[0]%360*Rc,m=t[1]%360*Rc,S()):[p*Lc,m*Lc]},C.rotate=function(t){return arguments.length?(g=t[0]%360*Rc,y=t[1]%360*Rc,v=t.length>2?t[2]%360*Rc:0,S()):[g*Lc,y*Lc,v*Lc]},C.angle=function(t){return arguments.length?(x=t%360*Rc,S()):x*Lc},C.reflectX=function(t){return arguments.length?(_=t?-1:1,S()):_<0},C.reflectY=function(t){return arguments.length?(b=t?-1:1,S()):b<0},C.precision=function(t){return arguments.length?(a=Fp(s,E=t*t),O()):Hc(E)},C.fitExtent=function(t,e){return Pp(C,t,e)},C.fitSize=function(t,e){return Lp(C,t,e)},C.fitWidth=function(t,e){return Rp(C,t,e)},C.fitHeight=function(t,e){return Ip(C,t,e)},function(){return e=t.apply(this,arguments),C.invert=e.invert&&k,S()}}function qp(t){var e=0,n=kc/3,r=Vp(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Rc,n=t[1]*Rc):[e*Lc,n*Lc]},i}function Gp(t,e){var n=Gc(t),r=(n+Gc(e))/2;if(Ic(r)<Ec)return function(t){var e=Fc(t);function n(t,n){return[t*e,Gc(n)/e]}return n.invert=function(t,n){return[t/e,Kc(n*e)]},n}(t);var i=1+n*(2*r-n),o=Hc(i)/r;function a(t,e){var n=Hc(i-2*r*Gc(e))/r;return[n*Gc(t*=r),o-n*Fc(t)]}return a.invert=function(t,e){var n=o-e,a=Nc(t,Ic(n))*Uc(n);return n*r<0&&(a-=kc*Uc(t)*Uc(n)),[a/r,Kc((i-(t*t+n*n)*r*r)/(2*r))]},a}function Up(){return qp(Gp).scale(155.424).center([0,33.6442])}function Hp(){return Up().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Wp(){var t,e,n,r,i,o,a=Hp(),s=Up().rotate([154,0]).center([-2,58.5]).parallels([55,65]),u=Up().rotate([157,0]).center([-3,19.9]).parallels([8,18]),l={point:function(t,e){o=[t,e]}};function c(t){var e=t[0],a=t[1];return o=null,n.point(e,a),o||(r.point(e,a),o)||(i.point(e,a),o)}function f(){return t=e=null,c}return c.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&i<.234&&r>=-.425&&r<-.214?s:i>=.166&&i<.234&&r>=-.214&&r<-.115?u:a).invert(t)},c.stream=function(n){return t&&e===n?t:(r=[a.stream(e=n),s.stream(n),u.stream(n)],i=r.length,t={point:function(t,e){for(var n=-1;++n<i;)r[n].point(t,e)},sphere:function(){for(var t=-1;++t<i;)r[t].sphere()},lineStart:function(){for(var t=-1;++t<i;)r[t].lineStart()},lineEnd:function(){for(var t=-1;++t<i;)r[t].lineEnd()},polygonStart:function(){for(var t=-1;++t<i;)r[t].polygonStart()},polygonEnd:function(){for(var t=-1;++t<i;)r[t].polygonEnd()}});var r,i},c.precision=function(t){return arguments.length?(a.precision(t),s.precision(t),u.precision(t),f()):a.precision()},c.scale=function(t){return arguments.length?(a.scale(t),s.scale(.35*t),u.scale(t),c.translate(a.translate())):a.scale()},c.translate=function(t){if(!arguments.length)return a.translate();var e=a.scale(),o=+t[0],c=+t[1];return n=a.translate(t).clipExtent([[o-.455*e,c-.238*e],[o+.455*e,c+.238*e]]).stream(l),r=s.translate([o-.307*e,c+.201*e]).clipExtent([[o-.425*e+Ec,c+.12*e+Ec],[o-.214*e-Ec,c+.234*e-Ec]]).stream(l),i=u.translate([o-.205*e,c+.212*e]).clipExtent([[o-.214*e+Ec,c+.166*e+Ec],[o-.115*e-Ec,c+.234*e-Ec]]).stream(l),f()},c.fitExtent=function(t,e){return Pp(c,t,e)},c.fitSize=function(t,e){return Lp(c,t,e)},c.fitWidth=function(t,e){return Rp(c,t,e)},c.fitHeight=function(t,e){return Ip(c,t,e)},c.scale(1070)}function Xp(t){return function(e,n){var r=Fc(e),i=Fc(n),o=t(r*i);return o===1/0?[2,0]:[o*i*Gc(e),o*Gc(n)]}}function Kp(t){return function(e,n){var r=Hc(e*e+n*n),i=t(r),o=Gc(i),a=Fc(i);return[Nc(e*o,r*a),Kc(r&&n*o/r)]}}var Qp=Xp((function(t){return Hc(2/(1+t))}));function Yp(){return Bp(Qp).scale(124.75).clipAngle(179.999)}Qp.invert=Kp((function(t){return 2*Kc(t/2)}));var $p=Xp((function(t){return(t=Xc(t))&&t/Gc(t)}));function Zp(){return Bp($p).scale(79.4188).clipAngle(179.999)}function Jp(t,e){return[t,Vc(Wc((Sc+e)/2))]}function tm(){return em(Jp).scale(961/Pc)}function em(t){var e,n,r,i=Bp(t),o=i.center,a=i.scale,s=i.translate,u=i.clipExtent,l=null;function c(){var o=kc*a(),s=i(kh(i.rotate()).invert([0,0]));return u(null==l?[[s[0]-o,s[1]-o],[s[0]+o,s[1]+o]]:t===Jp?[[Math.max(s[0]-o,l),e],[Math.min(s[0]+o,n),r]]:[[l,Math.max(s[1]-o,e)],[n,Math.min(s[1]+o,r)]])}return i.scale=function(t){return arguments.length?(a(t),c()):a()},i.translate=function(t){return arguments.length?(s(t),c()):s()},i.center=function(t){return arguments.length?(o(t),c()):o()},i.clipExtent=function(t){return arguments.length?(null==t?l=e=n=r=null:(l=+t[0][0],e=+t[0][1],n=+t[1][0],r=+t[1][1]),c()):null==l?null:[[l,e],[n,r]]},c()}function nm(t){return Wc((Sc+t)/2)}function rm(t,e){var n=Fc(t),r=t===e?Gc(t):Vc(n/Fc(e))/Vc(nm(e)/nm(t)),i=n*qc(nm(t),r)/r;if(!r)return Jp;function o(t,e){i>0?e<-Sc+Ec&&(e=-Sc+Ec):e>Sc-Ec&&(e=Sc-Ec);var n=i/qc(nm(e),r);return[n*Gc(r*t),i-n*Fc(r*t)]}return o.invert=function(t,e){var n=i-e,o=Uc(r)*Hc(t*t+n*n),a=Nc(t,Ic(n))*Uc(n);return n*r<0&&(a-=kc*Uc(t)*Uc(n)),[a/r,2*Dc(qc(i/o,1/r))-Sc]},o}function im(){return qp(rm).scale(109.5).parallels([30,30])}function om(t,e){return[t,e]}function am(){return Bp(om).scale(152.63)}function sm(t,e){var n=Fc(t),r=t===e?Gc(t):(n-Fc(e))/(e-t),i=n/r+t;if(Ic(r)<Ec)return om;function o(t,e){var n=i-e,o=r*t;return[n*Gc(o),i-n*Fc(o)]}return o.invert=function(t,e){var n=i-e,o=Nc(t,Ic(n))*Uc(n);return n*r<0&&(o-=kc*Uc(t)*Uc(n)),[o/r,i-Uc(r)*Hc(t*t+n*n)]},o}function um(){return qp(sm).scale(131.154).center([0,13.9389])}$p.invert=Kp((function(t){return t})),Jp.invert=function(t,e){return[t,2*Dc(zc(e))-Sc]},om.invert=om;var lm=1.340264,cm=-.081106,fm=893e-6,hm=.003796,dm=Hc(3)/2;function pm(t,e){var n=Kc(dm*Gc(e)),r=n*n,i=r*r*r;return[t*Fc(n)/(dm*(lm+3*cm*r+i*(7*fm+9*hm*r))),n*(lm+cm*r+i*(fm+hm*r))]}function mm(){return Bp(pm).scale(177.158)}function gm(t,e){var n=Fc(e),r=Fc(t)*n;return[n*Gc(t)/r,Gc(e)/r]}function ym(){return Bp(gm).scale(144.049).clipAngle(60)}function vm(){var t,e,n,r,i,o,a,s=1,u=0,l=0,c=1,f=1,h=0,d=null,p=1,m=1,g=kp({point:function(t,e){var n=x([t,e]);this.stream.point(n[0],n[1])}}),y=Ad;function v(){return p=s*c,m=s*f,o=a=null,x}function x(n){var r=n[0]*p,i=n[1]*m;if(h){var o=i*t-r*e;r=r*t+i*e,i=o}return[r+u,i+l]}return x.invert=function(n){var r=n[0]-u,i=n[1]-l;if(h){var o=i*t+r*e;r=r*t-i*e,i=o}return[r/p,i/m]},x.stream=function(t){return o&&a===t?o:o=g(y(a=t))},x.postclip=function(t){return arguments.length?(y=t,d=n=r=i=null,v()):y},x.clipExtent=function(t){return arguments.length?(y=null==t?(d=n=r=i=null,Ad):Yh(d=+t[0][0],n=+t[0][1],r=+t[1][0],i=+t[1][1]),v()):null==d?null:[[d,n],[r,i]]},x.scale=function(t){return arguments.length?(s=+t,v()):s},x.translate=function(t){return arguments.length?(u=+t[0],l=+t[1],v()):[u,l]},x.angle=function(n){return arguments.length?(e=Gc(h=n%360*Rc),t=Fc(h),v()):h*Lc},x.reflectX=function(t){return arguments.length?(c=t?-1:1,v()):c<0},x.reflectY=function(t){return arguments.length?(f=t?-1:1,v()):f<0},x.fitExtent=function(t,e){return Pp(x,t,e)},x.fitSize=function(t,e){return Lp(x,t,e)},x.fitWidth=function(t,e){return Rp(x,t,e)},x.fitHeight=function(t,e){return Ip(x,t,e)},x}function xm(t,e){var n=e*e,r=n*n;return[t*(.8707-.131979*n+r*(r*(.003971*n-.001529*r)-.013791)),e*(1.007226+n*(.015085+r*(.028874*n-.044475-.005916*r)))]}function _m(){return Bp(xm).scale(175.295)}function bm(t,e){return[Fc(e)*Gc(t),Gc(e)]}function wm(){return Bp(bm).scale(249.5).clipAngle(90+Ec)}function Mm(t,e){var n=Fc(e),r=1+Fc(t)*n;return[n*Gc(t)/r,Gc(e)/r]}function Am(){return Bp(Mm).scale(250).clipAngle(142)}function Tm(t,e){return[Vc(Wc((Sc+e)/2)),-t]}function Em(){var t=em(Tm),e=t.center,n=t.rotate;return t.center=function(t){return arguments.length?e([-t[1],t[0]]):[(t=e())[1],-t[0]]},t.rotate=function(t){return arguments.length?n([t[0],t[1],t.length>2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90]).scale(159.155)}function Cm(t,e){return t.parent===e.parent?1:2}function km(t,e){return t+e.x}function Sm(t,e){return Math.max(t,e.y)}function Om(){var t=Cm,e=1,n=1,r=!1;function i(i){var o,a=0;i.eachAfter((function(e){var n=e.children;n?(e.x=function(t){return t.reduce(km,0)/t.length}(n),e.y=function(t){return 1+t.reduce(Sm,0)}(n)):(e.x=o?a+=t(e,o):0,e.y=0,o=e)}));var s=function(t){for(var e;e=t.children;)t=e[0];return t}(i),u=function(t){for(var e;e=t.children;)t=e[e.length-1];return t}(i),l=s.x-t(s,u)/2,c=u.x+t(u,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-l)/(c-l)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function Pm(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function Lm(t,e){t instanceof Map?(t=[void 0,t],void 0===e&&(e=Im)):void 0===e&&(e=Rm);for(var n,r,i,o,a,s=new Fm(t),u=[s];n=u.pop();)if((i=e(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)u.push(r=i[o]=new Fm(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(Nm)}function Rm(t){return t.children}function Im(t){return Array.isArray(t)?t[1]:null}function Dm(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function Nm(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function Fm(t){this.data=t,this.depth=this.height=0,this.parent=null}function jm(t){return null==t?null:zm(t)}function zm(t){if("function"!=typeof t)throw new Error;return t}function Bm(){return 0}function Vm(t){return function(){return t}}pm.invert=function(t,e){for(var n,r=e,i=r*r,o=i*i*i,a=0;a<12&&(o=(i=(r-=n=(r*(lm+cm*i+o*(fm+hm*i))-e)/(lm+3*cm*i+o*(7*fm+9*hm*i)))*r)*i*i,!(Ic(n)<Cc));++a);return[dm*t*(lm+3*cm*i+o*(7*fm+9*hm*i))/Fc(r),Kc(Gc(r)/dm)]},gm.invert=Kp(Dc),xm.invert=function(t,e){var n,r=e,i=25;do{var o=r*r,a=o*o;r-=n=(r*(1.007226+o*(.015085+a*(.028874*o-.044475-.005916*a)))-e)/(1.007226+o*(.045255+a*(.259866*o-.311325-.005916*11*a)))}while(Ic(n)>Ec&&--i>0);return[t/(.8707+(o=r*r)*(o*(o*o*o*(.003971-.001529*o)-.013791)-.131979)),r]},bm.invert=Kp(Kc),Mm.invert=Kp((function(t){return 2*Dc(t)})),Tm.invert=function(t,e){return[-e,2*Dc(zc(t))-Sc]},Fm.prototype=Lm.prototype={constructor:Fm,count:function(){return this.eachAfter(Pm)},each:function(t,e){let n=-1;for(const r of this)t.call(e,r,++n,this);return this},eachAfter:function(t,e){for(var n,r,i,o=this,a=[o],s=[],u=-1;o=a.pop();)if(s.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);for(;o=s.pop();)t.call(e,o,++u,this);return this},eachBefore:function(t,e){for(var n,r,i=this,o=[i],a=-1;i=o.pop();)if(t.call(e,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},find:function(t,e){let n=-1;for(const r of this)if(t.call(e,r,++n,this))return r},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();for(;t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){return Array.from(this)},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return Lm(this).eachBefore(Dm)},[Symbol.iterator]:function*(){var t,e,n,r,i=this,o=[i];do{for(t=o.reverse(),o=[];i=t.pop();)if(yield i,e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n])}while(o.length)}};const qm=1664525,Gm=1013904223,Um=4294967296;function Hm(){let t=1;return()=>(t=(qm*t+Gm)%Um)/Um}function Wm(t){return Xm(t,Hm())}function Xm(t,e){for(var n,r,i=0,o=(t=function(t,e){let n,r,i=t.length;for(;i;)r=e()*i--|0,n=t[i],t[i]=t[r],t[r]=n;return t}(Array.from(t),e)).length,a=[];i<o;)n=t[i],r&&Ym(r,n)?++i:(r=Zm(a=Km(a,n)),i=0);return r}function Km(t,e){var n,r;if($m(e,t))return[e];for(n=0;n<t.length;++n)if(Qm(e,t[n])&&$m(Jm(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(r=n+1;r<t.length;++r)if(Qm(Jm(t[n],t[r]),e)&&Qm(Jm(t[n],e),t[r])&&Qm(Jm(t[r],e),t[n])&&$m(tg(t[n],t[r],e),t))return[t[n],t[r],e];throw new Error}function Qm(t,e){var n=t.r-e.r,r=e.x-t.x,i=e.y-t.y;return n<0||n*n<r*r+i*i}function Ym(t,e){var n=t.r-e.r+1e-9*Math.max(t.r,e.r,1),r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function $m(t,e){for(var n=0;n<e.length;++n)if(!Ym(t,e[n]))return!1;return!0}function Zm(t){switch(t.length){case 1:return function(t){return{x:t.x,y:t.y,r:t.r}}(t[0]);case 2:return Jm(t[0],t[1]);case 3:return tg(t[0],t[1],t[2])}}function Jm(t,e){var n=t.x,r=t.y,i=t.r,o=e.x,a=e.y,s=e.r,u=o-n,l=a-r,c=s-i,f=Math.sqrt(u*u+l*l);return{x:(n+o+u/f*c)/2,y:(r+a+l/f*c)/2,r:(f+i+s)/2}}function tg(t,e,n){var r=t.x,i=t.y,o=t.r,a=e.x,s=e.y,u=e.r,l=n.x,c=n.y,f=n.r,h=r-a,d=r-l,p=i-s,m=i-c,g=u-o,y=f-o,v=r*r+i*i-o*o,x=v-a*a-s*s+u*u,_=v-l*l-c*c+f*f,b=d*p-h*m,w=(p*_-m*x)/(2*b)-r,M=(m*g-p*y)/b,A=(d*x-h*_)/(2*b)-i,T=(h*y-d*g)/b,E=M*M+T*T-1,C=2*(o+w*M+A*T),k=w*w+A*A-o*o,S=-(Math.abs(E)>1e-6?(C+Math.sqrt(C*C-4*E*k))/(2*E):k/C);return{x:r+w+M*S,y:i+A+T*S,r:S}}function eg(t,e,n){var r,i,o,a,s=t.x-e.x,u=t.y-e.y,l=s*s+u*u;l?(i=e.r+n.r,i*=i,a=t.r+n.r,i>(a*=a)?(r=(l+a-i)/(2*l),o=Math.sqrt(Math.max(0,a/l-r*r)),n.x=t.x-r*s-o*u,n.y=t.y-r*u+o*s):(r=(l+i-a)/(2*l),o=Math.sqrt(Math.max(0,i/l-r*r)),n.x=e.x+r*s-o*u,n.y=e.y+r*u+o*s)):(n.x=e.x+n.r,n.y=e.y)}function ng(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function rg(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,o=(e.y*n.r+n.y*e.r)/r;return i*i+o*o}function ig(t){this._=t,this.next=null,this.previous=null}function og(t,e){if(!(o=(t=function(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}(t)).length))return 0;var n,r,i,o,a,s,u,l,c,f,h;if((n=t[0]).x=0,n.y=0,!(o>1))return n.r;if(r=t[1],n.x=-r.r,r.x=n.r,r.y=0,!(o>2))return n.r+r.r;eg(r,n,i=t[2]),n=new ig(n),r=new ig(r),i=new ig(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(u=3;u<o;++u){eg(n._,r._,i=t[u]),i=new ig(i),l=r.next,c=n.previous,f=r._.r,h=n._.r;do{if(f<=h){if(ng(l._,i._)){r=l,n.next=r,r.previous=n,--u;continue t}f+=l._.r,l=l.next}else{if(ng(c._,i._)){(n=c).next=r,r.previous=n,--u;continue t}h+=c._.r,c=c.previous}}while(l!==c.next);for(i.previous=n,i.next=r,n.next=r.previous=r=i,a=rg(n);(i=i.next)!==r;)(s=rg(i))<a&&(n=i,a=s);r=n.next}for(n=[r._],i=r;(i=i.next)!==r;)n.push(i._);for(i=Xm(n,e),u=0;u<o;++u)(n=t[u]).x-=i.x,n.y-=i.y;return i.r}function ag(t){return og(t,Hm()),t}function sg(t){return Math.sqrt(t.value)}function ug(){var t=null,e=1,n=1,r=Bm;function i(i){const o=Hm();return i.x=e/2,i.y=n/2,t?i.eachBefore(lg(t)).eachAfter(cg(r,.5,o)).eachBefore(fg(1)):i.eachBefore(lg(sg)).eachAfter(cg(Bm,1,o)).eachAfter(cg(r,i.r/Math.min(e,n),o)).eachBefore(fg(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=jm(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"==typeof t?t:Vm(+t),i):r},i}function lg(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function cg(t,e,n){return function(r){if(i=r.children){var i,o,a,s=i.length,u=t(r)*e||0;if(u)for(o=0;o<s;++o)i[o].r+=u;if(a=og(i,n),u)for(o=0;o<s;++o)i[o].r-=u;r.r=a+u}}}function fg(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}function hg(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function dg(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(r-e)/t.value;++s<u;)(o=a[s]).y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*l}function pg(){var t=1,e=1,n=0,r=!1;function i(i){var o=i.height+1;return i.x0=i.y0=n,i.x1=t,i.y1=e/o,i.eachBefore(function(t,e){return function(r){r.children&&dg(r,r.x0,t*(r.depth+1)/e,r.x1,t*(r.depth+2)/e);var i=r.x0,o=r.y0,a=r.x1-n,s=r.y1-n;a<i&&(i=a=(i+a)/2),s<o&&(o=s=(o+s)/2),r.x0=i,r.y0=o,r.x1=a,r.y1=s}}(e,o)),r&&i.eachBefore(hg),i}return i.round=function(t){return arguments.length?(r=!!t,i):r},i.size=function(n){return arguments.length?(t=+n[0],e=+n[1],i):[t,e]},i.padding=function(t){return arguments.length?(n=+t,i):n},i}var mg={depth:-1},gg={},yg={};function vg(t){return t.id}function xg(t){return t.parentId}function _g(){var t,e=vg,n=xg;function r(r){var i,o,a,s,u,l,c,f,h=Array.from(r),d=e,p=n,m=new Map;if(null!=t){const e=h.map(((e,n)=>function(t){t=`${t}`;let e=t.length;wg(t,e-1)&&!wg(t,e-2)&&(t=t.slice(0,-1));return"/"===t[0]?t:`/${t}`}(t(e,n,r)))),n=e.map(bg),i=new Set(e).add("");for(const t of n)i.has(t)||(i.add(t),e.push(t),n.push(bg(t)),h.push(yg));d=(t,n)=>e[n],p=(t,e)=>n[e]}for(a=0,i=h.length;a<i;++a)o=h[a],l=h[a]=new Fm(o),null!=(c=d(o,a,r))&&(c+="")&&(f=l.id=c,m.set(f,m.has(f)?gg:l)),null!=(c=p(o,a,r))&&(c+="")&&(l.parent=c);for(a=0;a<i;++a)if(c=(l=h[a]).parent){if(!(u=m.get(c)))throw new Error("missing: "+c);if(u===gg)throw new Error("ambiguous: "+c);u.children?u.children.push(l):u.children=[l],l.parent=u}else{if(s)throw new Error("multiple roots");s=l}if(!s)throw new Error("no root");if(null!=t){for(;s.data===yg&&1===s.children.length;)s=s.children[0],--i;for(let t=h.length-1;t>=0&&(l=h[t]).data===yg;--t)l.data=null}if(s.parent=mg,s.eachBefore((function(t){t.depth=t.parent.depth+1,--i})).eachBefore(Nm),s.parent=null,i>0)throw new Error("cycle");return s}return r.id=function(t){return arguments.length?(e=jm(t),r):e},r.parentId=function(t){return arguments.length?(n=jm(t),r):n},r.path=function(e){return arguments.length?(t=jm(e),r):t},r}function bg(t){let e=t.length;if(e<2)return"";for(;--e>1&&!wg(t,e););return t.slice(0,e)}function wg(t,e){if("/"===t[e]){let n=0;for(;e>0&&"\\"===t[--e];)++n;if(!(1&n))return!0}return!1}function Mg(t,e){return t.parent===e.parent?1:2}function Ag(t){var e=t.children;return e?e[0]:t.t}function Tg(t){var e=t.children;return e?e[e.length-1]:t.t}function Eg(t,e,n){var r=n/(e.i-t.i);e.c-=r,e.s+=n,t.c+=r,e.z+=n,e.m+=n}function Cg(t,e,n){return t.a.parent===e.parent?t.a:n}function kg(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}function Sg(){var t=Mg,e=1,n=1,r=null;function i(i){var u=function(t){for(var e,n,r,i,o,a=new kg(t,0),s=[a];e=s.pop();)if(r=e._.children)for(e.children=new Array(o=r.length),i=o-1;i>=0;--i)s.push(n=e.children[i]=new kg(r[i],i)),n.parent=e;return(a.parent=new kg(null,0)).children=[a],a}(i);if(u.eachAfter(o),u.parent.m=-u.z,u.eachBefore(a),r)i.eachBefore(s);else{var l=i,c=i,f=i;i.eachBefore((function(t){t.x<l.x&&(l=t),t.x>c.x&&(c=t),t.depth>f.depth&&(f=t)}));var h=l===c?1:t(l,c)/2,d=h-l.x,p=e/(c.x+h+d),m=n/(f.depth||1);i.eachBefore((function(t){t.x=(t.x+d)*p,t.y=t.depth*m}))}return i}function o(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){!function(t){for(var e,n=0,r=0,i=t.children,o=i.length;--o>=0;)(e=i[o]).z+=n,e.m+=n,n+=e.s+(r+=e.c)}(e);var o=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-o):e.z=o}else i&&(e.z=i.z+t(e._,i._));e.parent.A=function(e,n,r){if(n){for(var i,o=e,a=e,s=n,u=o.parent.children[0],l=o.m,c=a.m,f=s.m,h=u.m;s=Tg(s),o=Ag(o),s&&o;)u=Ag(u),(a=Tg(a)).a=e,(i=s.z+f-o.z-l+t(s._,o._))>0&&(Eg(Cg(s,e,r),e,i),l+=i,c+=i),f+=s.m,l+=o.m,h+=u.m,c+=a.m;s&&!Tg(a)&&(a.t=s,a.m+=f-c),o&&!Ag(u)&&(u.t=o,u.m+=l-h,r=e)}return r}(e,i,e.parent.A||r[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function Og(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(i-n)/t.value;++s<u;)(o=a[s]).x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*l}kg.prototype=Object.create(Fm.prototype);var Pg=(1+Math.sqrt(5))/2;function Lg(t,e,n,r,i,o){for(var a,s,u,l,c,f,h,d,p,m,g,y=[],v=e.children,x=0,_=0,b=v.length,w=e.value;x<b;){u=i-n,l=o-r;do{c=v[_++].value}while(!c&&_<b);for(f=h=c,g=c*c*(m=Math.max(l/u,u/l)/(w*t)),p=Math.max(h/g,g/f);_<b;++_){if(c+=s=v[_].value,s<f&&(f=s),s>h&&(h=s),g=c*c*m,(d=Math.max(h/g,g/f))>p){c-=s;break}p=d}y.push(a={value:c,dice:u<l,children:v.slice(x,_)}),a.dice?dg(a,n,r,i,w?r+=l*c/w:o):Og(a,n,r,w?n+=u*c/w:i,o),w-=c,x=_}return y}var Rg=function t(e){function n(t,n,r,i,o){Lg(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(Pg);function Ig(){var t=Rg,e=!1,n=1,r=1,i=[0],o=Bm,a=Bm,s=Bm,u=Bm,l=Bm;function c(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(f),i=[0],e&&t.eachBefore(hg),t}function f(e){var n=i[e.depth],r=e.x0+n,c=e.y0+n,f=e.x1-n,h=e.y1-n;f<r&&(r=f=(r+f)/2),h<c&&(c=h=(c+h)/2),e.x0=r,e.y0=c,e.x1=f,e.y1=h,e.children&&(n=i[e.depth+1]=o(e)/2,r+=l(e)-n,c+=a(e)-n,(f-=s(e)-n)<r&&(r=f=(r+f)/2),(h-=u(e)-n)<c&&(c=h=(c+h)/2),t(e,r,c,f,h))}return c.round=function(t){return arguments.length?(e=!!t,c):e},c.size=function(t){return arguments.length?(n=+t[0],r=+t[1],c):[n,r]},c.tile=function(e){return arguments.length?(t=zm(e),c):t},c.padding=function(t){return arguments.length?c.paddingInner(t).paddingOuter(t):c.paddingInner()},c.paddingInner=function(t){return arguments.length?(o="function"==typeof t?t:Vm(+t),c):o},c.paddingOuter=function(t){return arguments.length?c.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):c.paddingTop()},c.paddingTop=function(t){return arguments.length?(a="function"==typeof t?t:Vm(+t),c):a},c.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:Vm(+t),c):s},c.paddingBottom=function(t){return arguments.length?(u="function"==typeof t?t:Vm(+t),c):u},c.paddingLeft=function(t){return arguments.length?(l="function"==typeof t?t:Vm(+t),c):l},c}function Dg(t,e,n,r,i){var o,a,s=t.children,u=s.length,l=new Array(u+1);for(l[0]=a=o=0;o<u;++o)l[o+1]=a+=s[o].value;!function t(e,n,r,i,o,a,u){if(e>=n-1){var c=s[e];return c.x0=i,c.y0=o,c.x1=a,void(c.y1=u)}var f=l[e],h=r/2+f,d=e+1,p=n-1;for(;d<p;){var m=d+p>>>1;l[m]<h?d=m+1:p=m}h-l[d-1]<l[d]-h&&e+1<d&&--d;var g=l[d]-f,y=r-g;if(a-i>u-o){var v=r?(i*y+a*g)/r:a;t(e,d,g,i,o,v,u),t(d,n,y,v,o,a,u)}else{var x=r?(o*y+u*g)/r:u;t(e,d,g,i,o,a,x),t(d,n,y,i,x,a,u)}}(0,u,t.value,e,n,r,i)}function Ng(t,e,n,r,i){(1&t.depth?Og:dg)(t,e,n,r,i)}var Fg=function t(e){function n(t,n,r,i,o){if((a=t._squarify)&&a.ratio===e)for(var a,s,u,l,c,f=-1,h=a.length,d=t.value;++f<h;){for(u=(s=a[f]).children,l=s.value=0,c=u.length;l<c;++l)s.value+=u[l].value;s.dice?dg(s,n,r,i,d?r+=(o-r)*s.value/d:o):Og(s,n,r,d?n+=(i-n)*s.value/d:i,o),d-=s.value}else t._squarify=a=Lg(e,t,n,r,i,o),a.ratio=e}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(Pg);function jg(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}function zg(t,e){var n=Dr(+t,+e);return function(t){var e=n(t);return e-360*Math.floor(e/360)}}function Bg(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}function Vg(t){return((t=Math.exp(t))+1/t)/2}var qg=function t(e,n,r){function i(t,i){var o,a,s=t[0],u=t[1],l=t[2],c=i[0],f=i[1],h=i[2],d=c-s,p=f-u,m=d*d+p*p;if(m<1e-12)a=Math.log(h/l)/e,o=function(t){return[s+t*d,u+t*p,l*Math.exp(e*t*a)]};else{var g=Math.sqrt(m),y=(h*h-l*l+r*m)/(2*l*n*g),v=(h*h-l*l-r*m)/(2*h*n*g),x=Math.log(Math.sqrt(y*y+1)-y),_=Math.log(Math.sqrt(v*v+1)-v);a=(_-x)/e,o=function(t){var r=t*a,i=Vg(x),o=l/(n*g)*(i*function(t){return((t=Math.exp(2*t))-1)/(t+1)}(e*r+x)-function(t){return((t=Math.exp(t))-1/t)/2}(x));return[s+o*d,u+o*p,l*i/Vg(e*r+x)]}}return o.duration=1e3*a*e/Math.SQRT2,o}return i.rho=function(e){var n=Math.max(.001,+e),r=n*n;return t(n,r,r*r)},i}(Math.SQRT2,2,4);function Gg(t){return function(e,n){var r=t((e=Tr(e)).h,(n=Tr(n)).h),i=Fr(e.s,n.s),o=Fr(e.l,n.l),a=Fr(e.opacity,n.opacity);return function(t){return e.h=r(t),e.s=i(t),e.l=o(t),e.opacity=a(t),e+""}}}var Ug=Gg(Dr),Hg=Gg(Fr);function Wg(t,e){var n=Fr((t=Da(t)).l,(e=Da(e)).l),r=Fr(t.a,e.a),i=Fr(t.b,e.b),o=Fr(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=r(e),t.b=i(e),t.opacity=o(e),t+""}}function Xg(t){return function(e,n){var r=t((e=Ga(e)).h,(n=Ga(n)).h),i=Fr(e.c,n.c),o=Fr(e.l,n.l),a=Fr(e.opacity,n.opacity);return function(t){return e.h=r(t),e.c=i(t),e.l=o(t),e.opacity=a(t),e+""}}}var Kg=Xg(Dr),Qg=Xg(Fr);function Yg(t){return function e(n){function r(e,r){var i=t((e=ts(e)).h,(r=ts(r)).h),o=Fr(e.s,r.s),a=Fr(e.l,r.l),s=Fr(e.opacity,r.opacity);return function(t){return e.h=i(t),e.s=o(t),e.l=a(Math.pow(t,n)),e.opacity=s(t),e+""}}return n=+n,r.gamma=e,r}(1)}var $g=Yg(Dr),Zg=Yg(Fr);function Jg(t,e){void 0===e&&(e=t,t=Zr);for(var n=0,r=e.length-1,i=e[0],o=new Array(r<0?0:r);n<r;)o[n]=t(i,i=e[++n]);return function(t){var e=Math.max(0,Math.min(r-1,Math.floor(t*=r)));return o[e](t-e)}}function ty(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n}function ey(t){for(var e,n=-1,r=t.length,i=t[r-1],o=0;++n<r;)e=i,i=t[n],o+=e[1]*i[0]-e[0]*i[1];return o/2}function ny(t){for(var e,n,r=-1,i=t.length,o=0,a=0,s=t[i-1],u=0;++r<i;)e=s,s=t[r],u+=n=e[0]*s[1]-s[0]*e[1],o+=(e[0]+s[0])*n,a+=(e[1]+s[1])*n;return[o/(u*=3),a/u]}function ry(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function iy(t,e){return t[0]-e[0]||t[1]-e[1]}function oy(t){const e=t.length,n=[0,1];let r,i=2;for(r=2;r<e;++r){for(;i>1&&ry(t[n[i-2]],t[n[i-1]],t[r])<=0;)--i;n[i++]=r}return n.slice(0,i)}function ay(t){if((n=t.length)<3)return null;var e,n,r=new Array(n),i=new Array(n);for(e=0;e<n;++e)r[e]=[+t[e][0],+t[e][1],e];for(r.sort(iy),e=0;e<n;++e)i[e]=[r[e][0],-r[e][1]];var o=oy(r),a=oy(i),s=a[0]===o[0],u=a[a.length-1]===o[o.length-1],l=[];for(e=o.length-1;e>=0;--e)l.push(t[r[o[e]][2]]);for(e=+s;e<a.length-u;++e)l.push(t[r[a[e]][2]]);return l}function sy(t,e){for(var n,r,i=t.length,o=t[i-1],a=e[0],s=e[1],u=o[0],l=o[1],c=!1,f=0;f<i;++f)n=(o=t[f])[0],(r=o[1])>s!=l>s&&a<(u-n)*(s-r)/(l-r)+n&&(c=!c),u=n,l=r;return c}function uy(t){for(var e,n,r=-1,i=t.length,o=t[i-1],a=o[0],s=o[1],u=0;++r<i;)e=a,n=s,e-=a=(o=t[r])[0],n-=s=o[1],u+=Math.hypot(e,n);return u}var ly=Math.random,cy=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,1===arguments.length?(n=t,t=0):n-=t,function(){return e()*n+t}}return n.source=t,n}(ly),fy=function t(e){function n(t,n){return arguments.length<2&&(n=t,t=0),t=Math.floor(t),n=Math.floor(n)-t,function(){return Math.floor(e()*n+t)}}return n.source=t,n}(ly),hy=function t(e){function n(t,n){var r,i;return t=null==t?0:+t,n=null==n?1:+n,function(){var o;if(null!=r)o=r,r=null;else do{r=2*e()-1,o=2*e()-1,i=r*r+o*o}while(!i||i>1);return t+n*o*Math.sqrt(-2*Math.log(i)/i)}}return n.source=t,n}(ly),dy=function t(e){var n=hy.source(e);function r(){var t=n.apply(this,arguments);return function(){return Math.exp(t())}}return r.source=t,r}(ly),py=function t(e){function n(t){return(t=+t)<=0?()=>0:function(){for(var n=0,r=t;r>1;--r)n+=e();return n+r*e()}}return n.source=t,n}(ly),my=function t(e){var n=py.source(e);function r(t){if(0==(t=+t))return e;var r=n(t);return function(){return r()/t}}return r.source=t,r}(ly),gy=function t(e){function n(t){return function(){return-Math.log1p(-e())/t}}return n.source=t,n}(ly),yy=function t(e){function n(t){if((t=+t)<0)throw new RangeError("invalid alpha");return t=1/-t,function(){return Math.pow(1-e(),t)}}return n.source=t,n}(ly),vy=function t(e){function n(t){if((t=+t)<0||t>1)throw new RangeError("invalid p");return function(){return Math.floor(e()+t)}}return n.source=t,n}(ly),xy=function t(e){function n(t){if((t=+t)<0||t>1)throw new RangeError("invalid p");return 0===t?()=>1/0:1===t?()=>1:(t=Math.log1p(-t),function(){return 1+Math.floor(Math.log1p(-e())/t)})}return n.source=t,n}(ly),_y=function t(e){var n=hy.source(e)();function r(t,r){if((t=+t)<0)throw new RangeError("invalid k");if(0===t)return()=>0;if(r=null==r?1:+r,1===t)return()=>-Math.log1p(-e())*r;var i=(t<1?t+1:t)-1/3,o=1/(3*Math.sqrt(i)),a=t<1?()=>Math.pow(e(),1/t):()=>1;return function(){do{do{var t=n(),s=1+o*t}while(s<=0);s*=s*s;var u=1-e()}while(u>=1-.0331*t*t*t*t&&Math.log(u)>=.5*t*t+i*(1-s+Math.log(s)));return i*s*a()*r}}return r.source=t,r}(ly),by=function t(e){var n=_y.source(e);function r(t,e){var r=n(t),i=n(e);return function(){var t=r();return 0===t?0:t/(t+i())}}return r.source=t,r}(ly),wy=function t(e){var n=xy.source(e),r=by.source(e);function i(t,e){return t=+t,(e=+e)>=1?()=>t:e<=0?()=>0:function(){for(var i=0,o=t,a=e;o*a>16&&o*(1-a)>16;){var s=Math.floor((o+1)*a),u=r(s,o-s+1)();u<=a?(i+=s,o-=s,a=(a-u)/(1-u)):(o=s-1,a/=u)}for(var l=a<.5,c=n(l?a:1-a),f=c(),h=0;f<=o;++h)f+=c();return i+(l?h:o-h)}}return i.source=t,i}(ly),My=function t(e){function n(t,n,r){var i;return 0==(t=+t)?i=t=>-Math.log(t):(t=1/t,i=e=>Math.pow(e,t)),n=null==n?0:+n,r=null==r?1:+r,function(){return n+r*i(-Math.log1p(-e()))}}return n.source=t,n}(ly),Ay=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,function(){return t+n*Math.tan(Math.PI*e())}}return n.source=t,n}(ly),Ty=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,function(){var r=e();return t+n*Math.log(r/(1-r))}}return n.source=t,n}(ly),Ey=function t(e){var n=_y.source(e),r=wy.source(e);function i(t){return function(){for(var i=0,o=t;o>16;){var a=Math.floor(.875*o),s=n(a)();if(s>o)return i+r(a-1,o/s)();i+=a,o-=s}for(var u=-Math.log1p(-e()),l=0;u<=o;++l)u-=Math.log1p(-e());return i+l}}return i.source=t,i}(ly);const Cy=1664525,ky=1013904223,Sy=1/4294967296;function Oy(t=Math.random()){let e=0|(0<=t&&t<1?t/Sy:Math.abs(t));return()=>(e=Cy*e+ky|0,Sy*(e>>>0))}function Py(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function Ly(t,e){switch(arguments.length){case 0:break;case 1:"function"==typeof t?this.interpolator(t):this.range(t);break;default:this.domain(t),"function"==typeof e?this.interpolator(e):this.range(e)}return this}const Ry=Symbol("implicit");function Iy(){var t=new L,e=[],n=[],r=Ry;function i(i){let o=t.get(i);if(void 0===o){if(r!==Ry)return r;t.set(i,o=e.push(i)-1)}return n[o%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new L;for(const r of n)t.has(r)||t.set(r,e.push(r)-1);return i},i.range=function(t){return arguments.length?(n=Array.from(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Iy(e,n).unknown(r)},Py.apply(i,arguments),i}function Dy(){var t,e,n=Iy().unknown(void 0),r=n.domain,i=n.range,o=0,a=1,s=!1,u=0,l=0,c=.5;function f(){var n=r().length,f=a<o,h=f?a:o,d=f?o:a;t=(d-h)/Math.max(1,n-u+2*l),s&&(t=Math.floor(t)),h+=(d-h-t*(n-u))*c,e=t*(1-u),s&&(h=Math.round(h),e=Math.round(e));var p=Rt(n).map((function(e){return h+t*e}));return i(f?p.reverse():p)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),f()):r()},n.range=function(t){return arguments.length?([o,a]=t,o=+o,a=+a,f()):[o,a]},n.rangeRound=function(t){return[o,a]=t,o=+o,a=+a,s=!0,f()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(s=!!t,f()):s},n.padding=function(t){return arguments.length?(u=Math.min(1,l=+t),f()):u},n.paddingInner=function(t){return arguments.length?(u=Math.min(1,t),f()):u},n.paddingOuter=function(t){return arguments.length?(l=+t,f()):l},n.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),f()):c},n.copy=function(){return Dy(r(),[o,a]).round(s).paddingInner(u).paddingOuter(l).align(c)},Py.apply(f(),arguments)}function Ny(t){var e=t.copy;return t.padding=t.paddingOuter,delete t.paddingInner,delete t.paddingOuter,t.copy=function(){return Ny(e())},t}function Fy(){return Ny(Dy.apply(null,arguments).paddingInner(1))}function jy(t){return+t}var zy=[0,1];function By(t){return t}function Vy(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function qy(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=Vy(i,r),o=n(a,o)):(r=Vy(r,i),o=n(o,a)),function(t){return o(r(t))}}function Gy(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=Vy(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=h(t,e,1,r)-1;return o[n](i[n](e))}}function Uy(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Hy(){var t,e,n,r,i,o,a=zy,s=zy,u=Zr,l=By;function c(){var t=Math.min(a.length,s.length);return l!==By&&(l=function(t,e){var n;return t>e&&(n=t,t=e,e=n),function(n){return Math.max(t,Math.min(e,n))}}(a[0],a[t-1])),r=t>2?Gy:qy,i=o=null,f}function f(e){return null==e||isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return f.invert=function(n){return l(e((o||(o=r(s,a.map(t),Xr)))(n)))},f.domain=function(t){return arguments.length?(a=Array.from(t,jy),c()):a.slice()},f.range=function(t){return arguments.length?(s=Array.from(t),c()):s.slice()},f.rangeRound=function(t){return s=Array.from(t),u=Bg,c()},f.clamp=function(t){return arguments.length?(l=!!t||By,c()):l!==By},f.interpolate=function(t){return arguments.length?(u=t,c()):u},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,c()}}function Wy(){return Hy()(By,By)}function Xy(t,e,n,r){var i,o=ct(t,e,n);switch((r=fc(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=Ac(o,a))||(r.precision=i),vc(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=Tc(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=Mc(o))||(r.precision=i-2*("%"===r.type))}return yc(r)}function Ky(t){var e=t.domain;return t.ticks=function(t){var n=e();return ut(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return Xy(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i,o=e(),a=0,s=o.length-1,u=o[a],l=o[s],c=10;for(l<u&&(i=u,u=l,l=i,i=a,a=s,s=i);c-- >0;){if((i=lt(u,l,n))===r)return o[a]=u,o[s]=l,e(o);if(i>0)u=Math.floor(u/i)*i,l=Math.ceil(l/i)*i;else{if(!(i<0))break;u=Math.ceil(u*i)/i,l=Math.floor(l*i)/i}r=i}return t},t}function Qy(){var t=Wy();return t.copy=function(){return Uy(t,Qy())},Py.apply(t,arguments),Ky(t)}function Yy(t){var e;function n(t){return null==t||isNaN(t=+t)?e:t}return n.invert=n,n.domain=n.range=function(e){return arguments.length?(t=Array.from(e,jy),n):t.slice()},n.unknown=function(t){return arguments.length?(e=t,n):e},n.copy=function(){return Yy(t).unknown(e)},t=arguments.length?Array.from(t,jy):[0,1],Ky(n)}function $y(t,e){var n,r=0,i=(t=t.slice()).length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function Zy(t){return Math.log(t)}function Jy(t){return Math.exp(t)}function tv(t){return-Math.log(-t)}function ev(t){return-Math.exp(-t)}function nv(t){return isFinite(t)?+("1e"+t):t<0?0:t}function rv(t){return(e,n)=>-t(-e,n)}function iv(t){const e=t(Zy,Jy),n=e.domain;let r,i,o=10;function a(){return r=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}(o),i=function(t){return 10===t?nv:t===Math.E?Math.exp:e=>Math.pow(t,e)}(o),n()[0]<0?(r=rv(r),i=rv(i),t(tv,ev)):t(Zy,Jy),e}return e.base=function(t){return arguments.length?(o=+t,a()):o},e.domain=function(t){return arguments.length?(n(t),a()):n()},e.ticks=t=>{const e=n();let a=e[0],s=e[e.length-1];const u=s<a;u&&([a,s]=[s,a]);let l,c,f=r(a),h=r(s);const d=null==t?10:+t;let p=[];if(!(o%1)&&h-f<d){if(f=Math.floor(f),h=Math.ceil(h),a>0){for(;f<=h;++f)for(l=1;l<o;++l)if(c=f<0?l/i(-f):l*i(f),!(c<a)){if(c>s)break;p.push(c)}}else for(;f<=h;++f)for(l=o-1;l>=1;--l)if(c=f>0?l/i(-f):l*i(f),!(c<a)){if(c>s)break;p.push(c)}2*p.length<d&&(p=ut(a,s,d))}else p=ut(f,h,Math.min(h-f,d)).map(i);return u?p.reverse():p},e.tickFormat=(t,n)=>{if(null==t&&(t=10),null==n&&(n=10===o?"s":","),"function"!=typeof n&&(o%1||null!=(n=fc(n)).precision||(n.trim=!0),n=yc(n)),t===1/0)return n;const a=Math.max(1,o*t/e.ticks().length);return t=>{let e=t/i(Math.round(r(t)));return e*o<o-.5&&(e*=o),e<=a?n(t):""}},e.nice=()=>n($y(n(),{floor:t=>i(Math.floor(r(t))),ceil:t=>i(Math.ceil(r(t)))})),e}function ov(){const t=iv(Hy()).domain([1,10]);return t.copy=()=>Uy(t,ov()).base(t.base()),Py.apply(t,arguments),t}function av(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function sv(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function uv(t){var e=1,n=t(av(e),sv(e));return n.constant=function(n){return arguments.length?t(av(e=+n),sv(e)):e},Ky(n)}function lv(){var t=uv(Hy());return t.copy=function(){return Uy(t,lv()).constant(t.constant())},Py.apply(t,arguments)}function cv(t){return function(e){return e<0?-Math.pow(-e,t):Math.pow(e,t)}}function fv(t){return t<0?-Math.sqrt(-t):Math.sqrt(t)}function hv(t){return t<0?-t*t:t*t}function dv(t){var e=t(By,By),n=1;return e.exponent=function(e){return arguments.length?1===(n=+e)?t(By,By):.5===n?t(fv,hv):t(cv(n),cv(1/n)):n},Ky(e)}function pv(){var t=dv(Hy());return t.copy=function(){return Uy(t,pv()).exponent(t.exponent())},Py.apply(t,arguments),t}function mv(){return pv.apply(null,arguments).exponent(.5)}function gv(t){return Math.sign(t)*t*t}function yv(){var t,e=Wy(),n=[0,1],r=!1;function i(n){var i=function(t){return Math.sign(t)*Math.sqrt(Math.abs(t))}(e(n));return isNaN(i)?t:r?Math.round(i):i}return i.invert=function(t){return e.invert(gv(t))},i.domain=function(t){return arguments.length?(e.domain(t),i):e.domain()},i.range=function(t){return arguments.length?(e.range((n=Array.from(t,jy)).map(gv)),i):n.slice()},i.rangeRound=function(t){return i.range(t).round(!0)},i.round=function(t){return arguments.length?(r=!!t,i):r},i.clamp=function(t){return arguments.length?(e.clamp(t),i):e.clamp()},i.unknown=function(e){return arguments.length?(t=e,i):t},i.copy=function(){return yv(e.domain(),n).round(r).clamp(e.clamp()).unknown(t)},Py.apply(i,arguments),Ky(i)}function vv(){var t,e=[],n=[],i=[];function o(){var t=0,r=Math.max(1,n.length);for(i=new Array(r-1);++t<r;)i[t-1]=wt(e,t/r);return a}function a(e){return null==e||isNaN(e=+e)?t:n[h(i,e)]}return a.invertExtent=function(t){var r=n.indexOf(t);return r<0?[NaN,NaN]:[r>0?i[r-1]:e[0],r<i.length?i[r]:e[e.length-1]]},a.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let n of t)null==n||isNaN(n=+n)||e.push(n);return e.sort(r),o()},a.range=function(t){return arguments.length?(n=Array.from(t),o()):n.slice()},a.unknown=function(e){return arguments.length?(t=e,a):t},a.quantiles=function(){return i.slice()},a.copy=function(){return vv().domain(e).range(n).unknown(t)},Py.apply(a,arguments)}function xv(){var t,e=0,n=1,r=1,i=[.5],o=[0,1];function a(e){return null!=e&&e<=e?o[h(i,e,0,r)]:t}function s(){var t=-1;for(i=new Array(r);++t<r;)i[t]=((t+1)*n-(t-r)*e)/(r+1);return a}return a.domain=function(t){return arguments.length?([e,n]=t,e=+e,n=+n,s()):[e,n]},a.range=function(t){return arguments.length?(r=(o=Array.from(t)).length-1,s()):o.slice()},a.invertExtent=function(t){var a=o.indexOf(t);return a<0?[NaN,NaN]:a<1?[e,i[0]]:a>=r?[i[r-1],n]:[i[a-1],i[a]]},a.unknown=function(e){return arguments.length?(t=e,a):a},a.thresholds=function(){return i.slice()},a.copy=function(){return xv().domain([e,n]).range(o).unknown(t)},Py.apply(Ky(a),arguments)}function _v(){var t,e=[.5],n=[0,1],r=1;function i(i){return null!=i&&i<=i?n[h(e,i,0,r)]:t}return i.domain=function(t){return arguments.length?(e=Array.from(t),r=Math.min(e.length,n.length-1),i):e.slice()},i.range=function(t){return arguments.length?(n=Array.from(t),r=Math.min(e.length,n.length-1),i):n.slice()},i.invertExtent=function(t){var r=n.indexOf(t);return[e[r-1],e[r]]},i.unknown=function(e){return arguments.length?(t=e,i):t},i.copy=function(){return _v().domain(e).range(n).unknown(t)},Py.apply(i,arguments)}const bv=1e3,wv=6e4,Mv=36e5,Av=864e5,Tv=6048e5,Ev=2592e6,Cv=31536e6,kv=new Date,Sv=new Date;function Ov(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=e=>(t(e=new Date(+e)),e),i.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),i.round=t=>{const e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=(t,n)=>(e(t=new Date(+t),null==n?1:Math.floor(n)),t),i.range=(n,r,o)=>{const a=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return a;let s;do{a.push(s=new Date(+n)),e(n,o),t(n)}while(s<n&&n<r);return a},i.filter=n=>Ov((e=>{if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),((t,r)=>{if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););})),n&&(i.count=(e,r)=>(kv.setTime(+e),Sv.setTime(+r),t(kv),t(Sv),Math.floor(n(kv,Sv))),i.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?e=>r(e)%t==0:e=>i.count(0,e)%t==0):i:null)),i}const Pv=Ov((()=>{}),((t,e)=>{t.setTime(+t+e)}),((t,e)=>e-t));Pv.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?Ov((e=>{e.setTime(Math.floor(e/t)*t)}),((e,n)=>{e.setTime(+e+n*t)}),((e,n)=>(n-e)/t)):Pv:null);const Lv=Pv.range,Rv=Ov((t=>{t.setTime(t-t.getMilliseconds())}),((t,e)=>{t.setTime(+t+e*bv)}),((t,e)=>(e-t)/bv),(t=>t.getUTCSeconds())),Iv=Rv.range,Dv=Ov((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*bv)}),((t,e)=>{t.setTime(+t+e*wv)}),((t,e)=>(e-t)/wv),(t=>t.getMinutes())),Nv=Dv.range,Fv=Ov((t=>{t.setUTCSeconds(0,0)}),((t,e)=>{t.setTime(+t+e*wv)}),((t,e)=>(e-t)/wv),(t=>t.getUTCMinutes())),jv=Fv.range,zv=Ov((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*bv-t.getMinutes()*wv)}),((t,e)=>{t.setTime(+t+e*Mv)}),((t,e)=>(e-t)/Mv),(t=>t.getHours())),Bv=zv.range,Vv=Ov((t=>{t.setUTCMinutes(0,0,0)}),((t,e)=>{t.setTime(+t+e*Mv)}),((t,e)=>(e-t)/Mv),(t=>t.getUTCHours())),qv=Vv.range,Gv=Ov((t=>t.setHours(0,0,0,0)),((t,e)=>t.setDate(t.getDate()+e)),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wv)/Av),(t=>t.getDate()-1)),Uv=Gv.range,Hv=Ov((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/Av),(t=>t.getUTCDate()-1)),Wv=Hv.range,Xv=Ov((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/Av),(t=>Math.floor(t/Av))),Kv=Xv.range;function Qv(t){return Ov((e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),((t,e)=>{t.setDate(t.getDate()+7*e)}),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wv)/Tv))}const Yv=Qv(0),$v=Qv(1),Zv=Qv(2),Jv=Qv(3),tx=Qv(4),ex=Qv(5),nx=Qv(6),rx=Yv.range,ix=$v.range,ox=Zv.range,ax=Jv.range,sx=tx.range,ux=ex.range,lx=nx.range;function cx(t){return Ov((e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)}),((t,e)=>(e-t)/Tv))}const fx=cx(0),hx=cx(1),dx=cx(2),px=cx(3),mx=cx(4),gx=cx(5),yx=cx(6),vx=fx.range,xx=hx.range,_x=dx.range,bx=px.range,wx=mx.range,Mx=gx.range,Ax=yx.range,Tx=Ov((t=>{t.setDate(1),t.setHours(0,0,0,0)}),((t,e)=>{t.setMonth(t.getMonth()+e)}),((t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())),(t=>t.getMonth())),Ex=Tx.range,Cx=Ov((t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)}),((t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())),(t=>t.getUTCMonth())),kx=Cx.range,Sx=Ov((t=>{t.setMonth(0,1),t.setHours(0,0,0,0)}),((t,e)=>{t.setFullYear(t.getFullYear()+e)}),((t,e)=>e.getFullYear()-t.getFullYear()),(t=>t.getFullYear()));Sx.every=t=>isFinite(t=Math.floor(t))&&t>0?Ov((e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),((e,n)=>{e.setFullYear(e.getFullYear()+n*t)})):null;const Ox=Sx.range,Px=Ov((t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)}),((t,e)=>e.getUTCFullYear()-t.getUTCFullYear()),(t=>t.getUTCFullYear()));Px.every=t=>isFinite(t=Math.floor(t))&&t>0?Ov((e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),((e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null;const Lx=Px.range;function Rx(t,e,n,r,i,a){const s=[[Rv,1,bv],[Rv,5,5e3],[Rv,15,15e3],[Rv,30,3e4],[a,1,wv],[a,5,3e5],[a,15,9e5],[a,30,18e5],[i,1,Mv],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,Av],[r,2,1728e5],[n,1,Tv],[e,1,Ev],[e,3,7776e6],[t,1,Cv]];function u(e,n,r){const i=Math.abs(n-e)/r,a=o((([,,t])=>t)).right(s,i);if(a===s.length)return t.every(ct(e/Cv,n/Cv,r));if(0===a)return Pv.every(Math.max(ct(e,n,r),1));const[u,l]=s[i/s[a-1][2]<s[a][2]/i?a-1:a];return u.every(l)}return[function(t,e,n){const r=e<t;r&&([t,e]=[e,t]);const i=n&&"function"==typeof n.range?n:u(t,e,n),o=i?i.range(t,+e+1):[];return r?o.reverse():o},u]}const[Ix,Dx]=Rx(Px,Cx,fx,Xv,Vv,Fv),[Nx,Fx]=Rx(Sx,Tx,Yv,Gv,zv,Dv);function jx(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function zx(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Bx(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function Vx(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,l=Jx(i),c=t_(i),f=Jx(o),h=t_(o),d=Jx(a),p=t_(a),m=Jx(s),g=t_(s),y=Jx(u),v=t_(u),x={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:b_,e:b_,f:E_,g:F_,G:z_,H:w_,I:M_,j:A_,L:T_,m:C_,M:k_,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:ub,s:lb,S:S_,u:O_,U:P_,V:R_,w:I_,W:D_,x:null,X:null,y:N_,Y:j_,Z:B_,"%":sb},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:V_,e:V_,f:W_,g:rb,G:ob,H:q_,I:G_,j:U_,L:H_,m:X_,M:K_,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:ub,s:lb,S:Q_,u:Y_,U:$_,V:J_,w:tb,W:eb,x:null,X:null,y:nb,Y:ib,Z:ab,"%":sb},b={a:function(t,e,n){var r=d.exec(e.slice(n));return r?(t.w=p.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(t,e,n){var r=y.exec(e.slice(n));return r?(t.m=v.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=g.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(t,n,r){return A(t,e,n,r)},d:f_,e:f_,f:y_,g:s_,G:a_,H:d_,I:d_,j:h_,L:g_,m:c_,M:p_,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c.get(r[0].toLowerCase()),n+r[0].length):-1},q:l_,Q:x_,s:__,S:m_,u:n_,U:r_,V:i_,w:e_,W:o_,x:function(t,e,r){return A(t,n,e,r)},X:function(t,e,n){return A(t,r,e,n)},y:s_,Y:a_,Z:u_,"%":v_};function w(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Xx[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function M(t,e){return function(n){var r,i,o=Bx(1900,void 0,1);if(A(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=zx(Bx(o.y,0,1))).getUTCDay(),r=i>4||0===i?hx.ceil(r):hx(r),r=Hv.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=jx(Bx(o.y,0,1))).getDay(),r=i>4||0===i?$v.ceil(r):$v(r),r=Gv.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?zx(Bx(o.y,0,1)).getUTCDay():jx(Bx(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,zx(o)):jx(o)}}function A(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=b[i in Xx?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return x.x=w(n,x),x.X=w(r,x),x.c=w(e,x),_.x=w(n,_),_.X=w(r,_),_.c=w(e,_),{format:function(t){var e=w(t+="",x);return e.toString=function(){return t},e},parse:function(t){var e=M(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=M(t+="",!0);return e.toString=function(){return t},e}}}var qx,Gx,Ux,Hx,Wx,Xx={"-":"",_:" ",0:"0"},Kx=/^\s*\d+/,Qx=/^%/,Yx=/[\\^$*+?|[\]().{}]/g;function $x(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function Zx(t){return t.replace(Yx,"\\$&")}function Jx(t){return new RegExp("^(?:"+t.map(Zx).join("|")+")","i")}function t_(t){return new Map(t.map(((t,e)=>[t.toLowerCase(),e])))}function e_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function n_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function r_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function i_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function o_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function a_(t,e,n){var r=Kx.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function s_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function u_(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function l_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function c_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function f_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function h_(t,e,n){var r=Kx.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function d_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function p_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function m_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function g_(t,e,n){var r=Kx.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function y_(t,e,n){var r=Kx.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function v_(t,e,n){var r=Qx.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function x_(t,e,n){var r=Kx.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function __(t,e,n){var r=Kx.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function b_(t,e){return $x(t.getDate(),e,2)}function w_(t,e){return $x(t.getHours(),e,2)}function M_(t,e){return $x(t.getHours()%12||12,e,2)}function A_(t,e){return $x(1+Gv.count(Sx(t),t),e,3)}function T_(t,e){return $x(t.getMilliseconds(),e,3)}function E_(t,e){return T_(t,e)+"000"}function C_(t,e){return $x(t.getMonth()+1,e,2)}function k_(t,e){return $x(t.getMinutes(),e,2)}function S_(t,e){return $x(t.getSeconds(),e,2)}function O_(t){var e=t.getDay();return 0===e?7:e}function P_(t,e){return $x(Yv.count(Sx(t)-1,t),e,2)}function L_(t){var e=t.getDay();return e>=4||0===e?tx(t):tx.ceil(t)}function R_(t,e){return t=L_(t),$x(tx.count(Sx(t),t)+(4===Sx(t).getDay()),e,2)}function I_(t){return t.getDay()}function D_(t,e){return $x($v.count(Sx(t)-1,t),e,2)}function N_(t,e){return $x(t.getFullYear()%100,e,2)}function F_(t,e){return $x((t=L_(t)).getFullYear()%100,e,2)}function j_(t,e){return $x(t.getFullYear()%1e4,e,4)}function z_(t,e){var n=t.getDay();return $x((t=n>=4||0===n?tx(t):tx.ceil(t)).getFullYear()%1e4,e,4)}function B_(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+$x(e/60|0,"0",2)+$x(e%60,"0",2)}function V_(t,e){return $x(t.getUTCDate(),e,2)}function q_(t,e){return $x(t.getUTCHours(),e,2)}function G_(t,e){return $x(t.getUTCHours()%12||12,e,2)}function U_(t,e){return $x(1+Hv.count(Px(t),t),e,3)}function H_(t,e){return $x(t.getUTCMilliseconds(),e,3)}function W_(t,e){return H_(t,e)+"000"}function X_(t,e){return $x(t.getUTCMonth()+1,e,2)}function K_(t,e){return $x(t.getUTCMinutes(),e,2)}function Q_(t,e){return $x(t.getUTCSeconds(),e,2)}function Y_(t){var e=t.getUTCDay();return 0===e?7:e}function $_(t,e){return $x(fx.count(Px(t)-1,t),e,2)}function Z_(t){var e=t.getUTCDay();return e>=4||0===e?mx(t):mx.ceil(t)}function J_(t,e){return t=Z_(t),$x(mx.count(Px(t),t)+(4===Px(t).getUTCDay()),e,2)}function tb(t){return t.getUTCDay()}function eb(t,e){return $x(hx.count(Px(t)-1,t),e,2)}function nb(t,e){return $x(t.getUTCFullYear()%100,e,2)}function rb(t,e){return $x((t=Z_(t)).getUTCFullYear()%100,e,2)}function ib(t,e){return $x(t.getUTCFullYear()%1e4,e,4)}function ob(t,e){var n=t.getUTCDay();return $x((t=n>=4||0===n?mx(t):mx.ceil(t)).getUTCFullYear()%1e4,e,4)}function ab(){return"+0000"}function sb(){return"%"}function ub(t){return+t}function lb(t){return Math.floor(+t/1e3)}function cb(t){return qx=Vx(t),Gx=qx.format,Ux=qx.parse,Hx=qx.utcFormat,Wx=qx.utcParse,qx}function fb(t){return new Date(t)}function hb(t){return t instanceof Date?+t:+new Date(+t)}function db(t,e,n,r,i,o,a,s,u,l){var c=Wy(),f=c.invert,h=c.domain,d=l(".%L"),p=l(":%S"),m=l("%I:%M"),g=l("%I %p"),y=l("%a %d"),v=l("%b %d"),x=l("%B"),_=l("%Y");function b(t){return(u(t)<t?d:s(t)<t?p:a(t)<t?m:o(t)<t?g:r(t)<t?i(t)<t?y:v:n(t)<t?x:_)(t)}return c.invert=function(t){return new Date(f(t))},c.domain=function(t){return arguments.length?h(Array.from(t,hb)):h().map(fb)},c.ticks=function(e){var n=h();return t(n[0],n[n.length-1],null==e?10:e)},c.tickFormat=function(t,e){return null==e?b:l(e)},c.nice=function(t){var n=h();return t&&"function"==typeof t.range||(t=e(n[0],n[n.length-1],null==t?10:t)),t?h($y(n,t)):c},c.copy=function(){return Uy(c,db(t,e,n,r,i,o,a,s,u,l))},c}function pb(){return Py.apply(db(Nx,Fx,Sx,Tx,Yv,Gv,zv,Dv,Rv,Gx).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function mb(){return Py.apply(db(Ix,Dx,Px,Cx,fx,Hv,Vv,Fv,Rv,Hx).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function gb(){var t,e,n,r,i,o=0,a=1,s=By,u=!1;function l(e){return null==e||isNaN(e=+e)?i:s(0===n?.5:(e=(r(e)-t)*n,u?Math.max(0,Math.min(1,e)):e))}function c(t){return function(e){var n,r;return arguments.length?([n,r]=e,s=t(n,r),l):[s(0),s(1)]}}return l.domain=function(i){return arguments.length?([o,a]=i,t=r(o=+o),e=r(a=+a),n=t===e?0:1/(e-t),l):[o,a]},l.clamp=function(t){return arguments.length?(u=!!t,l):u},l.interpolator=function(t){return arguments.length?(s=t,l):s},l.range=c(Zr),l.rangeRound=c(Bg),l.unknown=function(t){return arguments.length?(i=t,l):i},function(i){return r=i,t=i(o),e=i(a),n=t===e?0:1/(e-t),l}}function yb(t,e){return e.domain(t.domain()).interpolator(t.interpolator()).clamp(t.clamp()).unknown(t.unknown())}function vb(){var t=Ky(gb()(By));return t.copy=function(){return yb(t,vb())},Ly.apply(t,arguments)}function xb(){var t=iv(gb()).domain([1,10]);return t.copy=function(){return yb(t,xb()).base(t.base())},Ly.apply(t,arguments)}function _b(){var t=uv(gb());return t.copy=function(){return yb(t,_b()).constant(t.constant())},Ly.apply(t,arguments)}function bb(){var t=dv(gb());return t.copy=function(){return yb(t,bb()).exponent(t.exponent())},Ly.apply(t,arguments)}function wb(){return bb.apply(null,arguments).exponent(.5)}function Mb(){var t=[],e=By;function n(n){if(null!=n&&!isNaN(n=+n))return e((h(t,n,1)-1)/(t.length-1))}return n.domain=function(e){if(!arguments.length)return t.slice();t=[];for(let n of e)null==n||isNaN(n=+n)||t.push(n);return t.sort(r),n},n.interpolator=function(t){return arguments.length?(e=t,n):e},n.range=function(){return t.map(((n,r)=>e(r/(t.length-1))))},n.quantiles=function(e){return Array.from({length:e+1},((n,r)=>bt(t,r/e)))},n.copy=function(){return Mb(e).domain(t)},Ly.apply(n,arguments)}function Ab(){var t,e,n,r,i,o,a,s=0,u=.5,l=1,c=1,f=By,h=!1;function d(t){return isNaN(t=+t)?a:(t=.5+((t=+o(t))-e)*(c*t<c*e?r:i),f(h?Math.max(0,Math.min(1,t)):t))}function p(t){return function(e){var n,r,i;return arguments.length?([n,r,i]=e,f=Jg(t,[n,r,i]),d):[f(0),f(.5),f(1)]}}return d.domain=function(a){return arguments.length?([s,u,l]=a,t=o(s=+s),e=o(u=+u),n=o(l=+l),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),c=e<t?-1:1,d):[s,u,l]},d.clamp=function(t){return arguments.length?(h=!!t,d):h},d.interpolator=function(t){return arguments.length?(f=t,d):f},d.range=p(Zr),d.rangeRound=p(Bg),d.unknown=function(t){return arguments.length?(a=t,d):a},function(a){return o=a,t=a(s),e=a(u),n=a(l),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),c=e<t?-1:1,d}}function Tb(){var t=Ky(Ab()(By));return t.copy=function(){return yb(t,Tb())},Ly.apply(t,arguments)}function Eb(){var t=iv(Ab()).domain([.1,1,10]);return t.copy=function(){return yb(t,Eb()).base(t.base())},Ly.apply(t,arguments)}function Cb(){var t=uv(Ab());return t.copy=function(){return yb(t,Cb()).constant(t.constant())},Ly.apply(t,arguments)}function kb(){var t=dv(Ab());return t.copy=function(){return yb(t,kb()).exponent(t.exponent())},Ly.apply(t,arguments)}function Sb(){return kb.apply(null,arguments).exponent(.5)}function Ob(t){for(var e=t.length/6|0,n=new Array(e),r=0;r<e;)n[r]="#"+t.slice(6*r,6*++r);return n}cb({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var Pb=Ob("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),Lb=Ob("7fc97fbeaed4fdc086ffff99386cb0f0027fbf5b17666666"),Rb=Ob("1b9e77d95f027570b3e7298a66a61ee6ab02a6761d666666"),Ib=Ob("4269d0efb118ff725c6cc5b03ca951ff8ab7a463f297bbf59c6b4e9498a0"),Db=Ob("a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928"),Nb=Ob("fbb4aeb3cde3ccebc5decbe4fed9a6ffffcce5d8bdfddaecf2f2f2"),Fb=Ob("b3e2cdfdcdaccbd5e8f4cae4e6f5c9fff2aef1e2cccccccc"),jb=Ob("e41a1c377eb84daf4a984ea3ff7f00ffff33a65628f781bf999999"),zb=Ob("66c2a5fc8d628da0cbe78ac3a6d854ffd92fe5c494b3b3b3"),Bb=Ob("8dd3c7ffffb3bebadafb807280b1d3fdb462b3de69fccde5d9d9d9bc80bdccebc5ffed6f"),Vb=Ob("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab"),qb=t=>Br(t[t.length-1]),Gb=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(Ob),Ub=qb(Gb),Hb=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(Ob),Wb=qb(Hb),Xb=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(Ob),Kb=qb(Xb),Qb=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(Ob),Yb=qb(Qb),$b=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(Ob),Zb=qb($b),Jb=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(Ob),tw=qb(Jb),ew=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(Ob),nw=qb(ew),rw=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(Ob),iw=qb(rw),ow=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(Ob),aw=qb(ow),sw=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(Ob),uw=qb(sw),lw=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(Ob),cw=qb(lw),fw=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(Ob),hw=qb(fw),dw=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(Ob),pw=qb(dw),mw=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(Ob),gw=qb(mw),yw=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(Ob),vw=qb(yw),xw=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(Ob),_w=qb(xw),bw=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(Ob),ww=qb(bw),Mw=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(Ob),Aw=qb(Mw),Tw=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(Ob),Ew=qb(Tw),Cw=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(Ob),kw=qb(Cw),Sw=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(Ob),Ow=qb(Sw),Pw=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(Ob),Lw=qb(Pw),Rw=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(Ob),Iw=qb(Rw),Dw=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(Ob),Nw=qb(Dw),Fw=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(Ob),jw=qb(Fw),zw=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(Ob),Bw=qb(zw),Vw=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(Ob),qw=qb(Vw);function Gw(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(-4.54-t*(35.34-t*(2381.73-t*(6402.7-t*(7024.72-2710.57*t)))))))+", "+Math.max(0,Math.min(255,Math.round(32.49+t*(170.73+t*(52.82-t*(131.46-t*(176.58-67.37*t)))))))+", "+Math.max(0,Math.min(255,Math.round(81.24+t*(442.36-t*(2482.43-t*(6167.24-t*(6614.94-2475.67*t)))))))+")"}var Uw=Zg(ts(300,.5,0),ts(-240,.5,1)),Hw=Zg(ts(-100,.75,.35),ts(80,1.5,.8)),Ww=Zg(ts(260,.75,.35),ts(80,1.5,.8)),Xw=ts();function Kw(t){(t<0||t>1)&&(t-=Math.floor(t));var e=Math.abs(t-.5);return Xw.h=360*t-100,Xw.s=1.5-1.5*e,Xw.l=.8-.9*e,Xw+""}var Qw=gr(),Yw=Math.PI/3,$w=2*Math.PI/3;function Zw(t){var e;return t=(.5-t)*Math.PI,Qw.r=255*(e=Math.sin(t))*e,Qw.g=255*(e=Math.sin(t+Yw))*e,Qw.b=255*(e=Math.sin(t+$w))*e,Qw+""}function Jw(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+t*(1172.33-t*(10793.56-t*(33300.12-t*(38394.49-14825.05*t)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+t*(557.33+t*(1225.33-t*(3574.96-t*(1073.77+707.56*t)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+t*(3211.1-t*(15327.97-t*(27814-t*(22569.18-6838.66*t)))))))+")"}function tM(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}var eM=tM(Ob("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725")),nM=tM(Ob("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),rM=tM(Ob("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),iM=tM(Ob("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921"));function oM(t){return Vn(Cn(t).call(document.documentElement))}var aM=0;function sM(){return new uM}function uM(){this._="@"+(++aM).toString(36)}function lM(t,e){return t.target&&(t=Jr(t),void 0===e&&(e=t.currentTarget),t=t.touches||[t]),Array.from(t,(t=>ti(t,e)))}function cM(t){return"string"==typeof t?new jn([document.querySelectorAll(t)],[document.documentElement]):new jn([Se(t)],Fn)}function fM(t){return function(){return t}}uM.prototype=sM.prototype={constructor:uM,get:function(t){for(var e=this._;!(e in t);)if(!(t=t.parentNode))return;return t[e]},set:function(t,e){return t[this._]=e},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};const hM=Math.abs,dM=Math.atan2,pM=Math.cos,mM=Math.max,gM=Math.min,yM=Math.sin,vM=Math.sqrt,xM=1e-12,_M=Math.PI,bM=_M/2,wM=2*_M;function MM(t){return t>=1?bM:t<=-1?-bM:Math.asin(t)}function AM(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(null==n)e=null;else{const t=Math.floor(n);if(!(t>=0))throw new RangeError(`invalid digits: ${n}`);e=t}return t},()=>new la(e)}function TM(t){return t.innerRadius}function EM(t){return t.outerRadius}function CM(t){return t.startAngle}function kM(t){return t.endAngle}function SM(t){return t&&t.padAngle}function OM(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/vM(s*s+u*u),c=l*u,f=-l*s,h=t+c,d=e+f,p=n+c,m=r+f,g=(h+p)/2,y=(d+m)/2,v=p-h,x=m-d,_=v*v+x*x,b=i-o,w=h*m-p*d,M=(x<0?-1:1)*vM(mM(0,b*b*_-w*w)),A=(w*x-v*M)/_,T=(-w*v-x*M)/_,E=(w*x+v*M)/_,C=(-w*v+x*M)/_,k=A-g,S=T-y,O=E-g,P=C-y;return k*k+S*S>O*O+P*P&&(A=E,T=C),{cx:A,cy:T,x01:-c,y01:-f,x11:A*(i/b-1),y11:T*(i/b-1)}}function PM(){var t=TM,e=EM,n=fM(0),r=null,i=CM,o=kM,a=SM,s=null,u=AM(l);function l(){var l,c,f=+t.apply(this,arguments),h=+e.apply(this,arguments),d=i.apply(this,arguments)-bM,p=o.apply(this,arguments)-bM,m=hM(p-d),g=p>d;if(s||(s=l=u()),h<f&&(c=h,h=f,f=c),h>xM)if(m>wM-xM)s.moveTo(h*pM(d),h*yM(d)),s.arc(0,0,h,d,p,!g),f>xM&&(s.moveTo(f*pM(p),f*yM(p)),s.arc(0,0,f,p,d,g));else{var y,v,x=d,_=p,b=d,w=p,M=m,A=m,T=a.apply(this,arguments)/2,E=T>xM&&(r?+r.apply(this,arguments):vM(f*f+h*h)),C=gM(hM(h-f)/2,+n.apply(this,arguments)),k=C,S=C;if(E>xM){var O=MM(E/f*yM(T)),P=MM(E/h*yM(T));(M-=2*O)>xM?(b+=O*=g?1:-1,w-=O):(M=0,b=w=(d+p)/2),(A-=2*P)>xM?(x+=P*=g?1:-1,_-=P):(A=0,x=_=(d+p)/2)}var L=h*pM(x),R=h*yM(x),I=f*pM(w),D=f*yM(w);if(C>xM){var N,F=h*pM(_),j=h*yM(_),z=f*pM(b),B=f*yM(b);if(m<_M)if(N=function(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,f=s-o,h=f*u-c*l;if(!(h*h<xM))return[t+(h=(c*(e-o)-f*(t-i))/h)*u,e+h*l]}(L,R,z,B,F,j,I,D)){var V=L-N[0],q=R-N[1],G=F-N[0],U=j-N[1],H=1/yM(function(t){return t>1?0:t<-1?_M:Math.acos(t)}((V*G+q*U)/(vM(V*V+q*q)*vM(G*G+U*U)))/2),W=vM(N[0]*N[0]+N[1]*N[1]);k=gM(C,(f-W)/(H-1)),S=gM(C,(h-W)/(H+1))}else k=S=0}A>xM?S>xM?(y=OM(z,B,L,R,h,S,g),v=OM(F,j,I,D,h,S,g),s.moveTo(y.cx+y.x01,y.cy+y.y01),S<C?s.arc(y.cx,y.cy,S,dM(y.y01,y.x01),dM(v.y01,v.x01),!g):(s.arc(y.cx,y.cy,S,dM(y.y01,y.x01),dM(y.y11,y.x11),!g),s.arc(0,0,h,dM(y.cy+y.y11,y.cx+y.x11),dM(v.cy+v.y11,v.cx+v.x11),!g),s.arc(v.cx,v.cy,S,dM(v.y11,v.x11),dM(v.y01,v.x01),!g))):(s.moveTo(L,R),s.arc(0,0,h,x,_,!g)):s.moveTo(L,R),f>xM&&M>xM?k>xM?(y=OM(I,D,F,j,f,-k,g),v=OM(L,R,z,B,f,-k,g),s.lineTo(y.cx+y.x01,y.cy+y.y01),k<C?s.arc(y.cx,y.cy,k,dM(y.y01,y.x01),dM(v.y01,v.x01),!g):(s.arc(y.cx,y.cy,k,dM(y.y01,y.x01),dM(y.y11,y.x11),!g),s.arc(0,0,f,dM(y.cy+y.y11,y.cx+y.x11),dM(v.cy+v.y11,v.cx+v.x11),g),s.arc(v.cx,v.cy,k,dM(v.y11,v.x11),dM(v.y01,v.x01),!g))):s.arc(0,0,f,w,b,g):s.lineTo(I,D)}else s.moveTo(0,0);if(s.closePath(),l)return s=null,l+""||null}return l.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-_M/2;return[pM(r)*n,yM(r)*n]},l.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),l):t},l.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),l):e},l.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:fM(+t),l):n},l.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:fM(+t),l):r},l.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),l):i},l.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:fM(+t),l):o},l.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:fM(+t),l):a},l.context=function(t){return arguments.length?(s=null==t?null:t,l):s},l}var LM=Array.prototype.slice;function RM(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function IM(t){this._context=t}function DM(t){return new IM(t)}function NM(t){return t[0]}function FM(t){return t[1]}function jM(t,e){var n=fM(!0),r=null,i=DM,o=null,a=AM(s);function s(s){var u,l,c,f=(s=RM(s)).length,h=!1;for(null==r&&(o=i(c=a())),u=0;u<=f;++u)!(u<f&&n(l=s[u],u,s))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+t(l,u,s),+e(l,u,s));if(c)return o=null,c+""||null}return t="function"==typeof t?t:void 0===t?NM:fM(t),e="function"==typeof e?e:void 0===e?FM:fM(e),s.x=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),s):t},s.y=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),s):e},s.defined=function(t){return arguments.length?(n="function"==typeof t?t:fM(!!t),s):n},s.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),s):i},s.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),s):r},s}function zM(t,e,n){var r=null,i=fM(!0),o=null,a=DM,s=null,u=AM(l);function l(l){var c,f,h,d,p,m=(l=RM(l)).length,g=!1,y=new Array(m),v=new Array(m);for(null==o&&(s=a(p=u())),c=0;c<=m;++c){if(!(c<m&&i(d=l[c],c,l))===g)if(g=!g)f=c,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),h=c-1;h>=f;--h)s.point(y[h],v[h]);s.lineEnd(),s.areaEnd()}g&&(y[c]=+t(d,c,l),v[c]=+e(d,c,l),s.point(r?+r(d,c,l):y[c],n?+n(d,c,l):v[c]))}if(p)return s=null,p+""||null}function c(){return jM().defined(i).curve(a).context(o)}return t="function"==typeof t?t:void 0===t?NM:fM(+t),e="function"==typeof e?e:fM(void 0===e?0:+e),n="function"==typeof n?n:void 0===n?FM:fM(+n),l.x=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),r=null,l):t},l.x0=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),l):t},l.x1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:fM(+t),l):r},l.y=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),n=null,l):e},l.y0=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),l):e},l.y1=function(t){return arguments.length?(n=null==t?null:"function"==typeof t?t:fM(+t),l):n},l.lineX0=l.lineY0=function(){return c().x(t).y(e)},l.lineY1=function(){return c().x(t).y(n)},l.lineX1=function(){return c().x(r).y(e)},l.defined=function(t){return arguments.length?(i="function"==typeof t?t:fM(!!t),l):i},l.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),l):a},l.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),l):o},l}function BM(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function VM(t){return t}function qM(){var t=VM,e=BM,n=null,r=fM(0),i=fM(wM),o=fM(0);function a(a){var s,u,l,c,f,h=(a=RM(a)).length,d=0,p=new Array(h),m=new Array(h),g=+r.apply(this,arguments),y=Math.min(wM,Math.max(-wM,i.apply(this,arguments)-g)),v=Math.min(Math.abs(y)/h,o.apply(this,arguments)),x=v*(y<0?-1:1);for(s=0;s<h;++s)(f=m[p[s]=s]=+t(a[s],s,a))>0&&(d+=f);for(null!=e?p.sort((function(t,n){return e(m[t],m[n])})):null!=n&&p.sort((function(t,e){return n(a[t],a[e])})),s=0,l=d?(y-h*x)/d:0;s<h;++s,g=c)u=p[s],c=g+((f=m[u])>0?f*l:0)+x,m[u]={data:a[u],index:s,value:f,startAngle:g,endAngle:c,padAngle:v};return m}return a.value=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:fM(+t),a):o},a}IM.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var GM=HM(DM);function UM(t){this._curve=t}function HM(t){function e(e){return new UM(t(e))}return e._curve=t,e}function WM(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(HM(t)):e()._curve},t}function XM(){return WM(jM().curve(GM))}function KM(){var t=zM().curve(GM),e=t.curve,n=t.lineX0,r=t.lineX1,i=t.lineY0,o=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return WM(n())},delete t.lineX0,t.lineEndAngle=function(){return WM(r())},delete t.lineX1,t.lineInnerRadius=function(){return WM(i())},delete t.lineY0,t.lineOuterRadius=function(){return WM(o())},delete t.lineY1,t.curve=function(t){return arguments.length?e(HM(t)):e()._curve},t}function QM(t,e){return[(e=+e)*Math.cos(t-=Math.PI/2),e*Math.sin(t)]}UM.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};class YM{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e)}this._x0=t,this._y0=e}}class $M{constructor(t){this._context=t}lineStart(){this._point=0}lineEnd(){}point(t,e){if(t=+t,e=+e,0===this._point)this._point=1;else{const n=QM(this._x0,this._y0),r=QM(this._x0,this._y0=(this._y0+e)/2),i=QM(t,this._y0),o=QM(t,e);this._context.moveTo(...n),this._context.bezierCurveTo(...r,...i,...o)}this._x0=t,this._y0=e}}function ZM(t){return new YM(t,!0)}function JM(t){return new YM(t,!1)}function tA(t){return new $M(t)}function eA(t){return t.source}function nA(t){return t.target}function rA(t){let e=eA,n=nA,r=NM,i=FM,o=null,a=null,s=AM(u);function u(){let u;const l=LM.call(arguments),c=e.apply(this,l),f=n.apply(this,l);if(null==o&&(a=t(u=s())),a.lineStart(),l[0]=c,a.point(+r.apply(this,l),+i.apply(this,l)),l[0]=f,a.point(+r.apply(this,l),+i.apply(this,l)),a.lineEnd(),u)return a=null,u+""||null}return u.source=function(t){return arguments.length?(e=t,u):e},u.target=function(t){return arguments.length?(n=t,u):n},u.x=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),u):r},u.y=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),u):i},u.context=function(e){return arguments.length?(null==e?o=a=null:a=t(o=e),u):o},u}function iA(){return rA(ZM)}function oA(){return rA(JM)}function aA(){const t=rA(tA);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t}const sA=vM(3);var uA={draw(t,e){const n=.59436*vM(e+gM(e/28,.75)),r=n/2,i=r*sA;t.moveTo(0,n),t.lineTo(0,-n),t.moveTo(-i,-r),t.lineTo(i,r),t.moveTo(-i,r),t.lineTo(i,-r)}},lA={draw(t,e){const n=vM(e/_M);t.moveTo(n,0),t.arc(0,0,n,0,wM)}},cA={draw(t,e){const n=vM(e/5)/2;t.moveTo(-3*n,-n),t.lineTo(-n,-n),t.lineTo(-n,-3*n),t.lineTo(n,-3*n),t.lineTo(n,-n),t.lineTo(3*n,-n),t.lineTo(3*n,n),t.lineTo(n,n),t.lineTo(n,3*n),t.lineTo(-n,3*n),t.lineTo(-n,n),t.lineTo(-3*n,n),t.closePath()}};const fA=vM(1/3),hA=2*fA;var dA={draw(t,e){const n=vM(e/hA),r=n*fA;t.moveTo(0,-n),t.lineTo(r,0),t.lineTo(0,n),t.lineTo(-r,0),t.closePath()}},pA={draw(t,e){const n=.62625*vM(e);t.moveTo(0,-n),t.lineTo(n,0),t.lineTo(0,n),t.lineTo(-n,0),t.closePath()}},mA={draw(t,e){const n=.87559*vM(e-gM(e/7,2));t.moveTo(-n,0),t.lineTo(n,0),t.moveTo(0,n),t.lineTo(0,-n)}},gA={draw(t,e){const n=vM(e),r=-n/2;t.rect(r,r,n,n)}},yA={draw(t,e){const n=.4431*vM(e);t.moveTo(n,n),t.lineTo(n,-n),t.lineTo(-n,-n),t.lineTo(-n,n),t.closePath()}};const vA=yM(_M/10)/yM(7*_M/10),xA=yM(wM/10)*vA,_A=-pM(wM/10)*vA;var bA={draw(t,e){const n=vM(.8908130915292852*e),r=xA*n,i=_A*n;t.moveTo(0,-n),t.lineTo(r,i);for(let e=1;e<5;++e){const o=wM*e/5,a=pM(o),s=yM(o);t.lineTo(s*n,-a*n),t.lineTo(a*r-s*i,s*r+a*i)}t.closePath()}};const wA=vM(3);var MA={draw(t,e){const n=-vM(e/(3*wA));t.moveTo(0,2*n),t.lineTo(-wA*n,-n),t.lineTo(wA*n,-n),t.closePath()}};const AA=vM(3);var TA={draw(t,e){const n=.6824*vM(e),r=n/2,i=n*AA/2;t.moveTo(0,-n),t.lineTo(i,r),t.lineTo(-i,r),t.closePath()}};const EA=-.5,CA=vM(3)/2,kA=1/vM(12),SA=3*(kA/2+1);var OA={draw(t,e){const n=vM(e/SA),r=n/2,i=n*kA,o=r,a=n*kA+n,s=-o,u=a;t.moveTo(r,i),t.lineTo(o,a),t.lineTo(s,u),t.lineTo(EA*r-CA*i,CA*r+EA*i),t.lineTo(EA*o-CA*a,CA*o+EA*a),t.lineTo(EA*s-CA*u,CA*s+EA*u),t.lineTo(EA*r+CA*i,EA*i-CA*r),t.lineTo(EA*o+CA*a,EA*a-CA*o),t.lineTo(EA*s+CA*u,EA*u-CA*s),t.closePath()}},PA={draw(t,e){const n=.6189*vM(e-gM(e/6,1.7));t.moveTo(-n,-n),t.lineTo(n,n),t.moveTo(-n,n),t.lineTo(n,-n)}};const LA=[lA,cA,dA,gA,bA,MA,OA],RA=[lA,mA,PA,TA,uA,yA,pA];function IA(t,e){let n=null,r=AM(i);function i(){let i;if(n||(n=i=r()),t.apply(this,arguments).draw(n,+e.apply(this,arguments)),i)return n=null,i+""||null}return t="function"==typeof t?t:fM(t||lA),e="function"==typeof e?e:fM(void 0===e?64:+e),i.type=function(e){return arguments.length?(t="function"==typeof e?e:fM(e),i):t},i.size=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),i):e},i.context=function(t){return arguments.length?(n=null==t?null:t,i):n},i}function DA(){}function NA(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function FA(t){this._context=t}function jA(t){return new FA(t)}function zA(t){this._context=t}function BA(t){return new zA(t)}function VA(t){this._context=t}function qA(t){return new VA(t)}function GA(t,e){this._basis=new FA(t),this._beta=e}FA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:NA(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},zA.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},VA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},GA.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var UA=function t(e){function n(t){return 1===e?new FA(t):new GA(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function HA(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function WA(t,e){this._context=t,this._k=(1-e)/6}WA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:HA(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var XA=function t(e){function n(t){return new WA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function KA(t,e){this._context=t,this._k=(1-e)/6}KA.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var QA=function t(e){function n(t){return new KA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function YA(t,e){this._context=t,this._k=(1-e)/6}YA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var $A=function t(e){function n(t){return new YA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function ZA(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>xM){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>xM){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/c,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/c}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function JA(t,e){this._context=t,this._alpha=e}JA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var tT=function t(e){function n(t){return e?new JA(t,e):new WA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function eT(t,e){this._context=t,this._alpha=e}eT.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var nT=function t(e){function n(t){return e?new eT(t,e):new KA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function rT(t,e){this._context=t,this._alpha=e}rT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var iT=function t(e){function n(t){return e?new rT(t,e):new YA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function oT(t){this._context=t}function aT(t){return new oT(t)}function sT(t){return t<0?-1:1}function uT(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(sT(o)+sT(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function lT(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function cT(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function fT(t){this._context=t}function hT(t){this._context=new dT(t)}function dT(t){this._context=t}function pT(t){return new fT(t)}function mT(t){return new hT(t)}function gT(t){this._context=t}function yT(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}function vT(t){return new gT(t)}function xT(t,e){this._context=t,this._t=e}function _T(t){return new xT(t,.5)}function bT(t){return new xT(t,0)}function wT(t){return new xT(t,1)}function MT(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]}function AT(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function TT(t,e){return t[e]}function ET(t){const e=[];return e.key=t,e}function CT(){var t=fM([]),e=AT,n=MT,r=TT;function i(i){var o,a,s=Array.from(t.apply(this,arguments),ET),u=s.length,l=-1;for(const t of i)for(o=0,++l;o<u;++o)(s[o][l]=[0,+r(t,s[o].key,l,i)]).data=t;for(o=0,a=RM(e(s));o<u;++o)s[a[o]].index=o;return n(s,a),s}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:fM(Array.from(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?AT:"function"==typeof t?t:fM(Array.from(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?MT:t,i):n},i}function kT(t,e){if((r=t.length)>0){for(var n,r,i,o=0,a=t[0].length;o<a;++o){for(i=n=0;n<r;++n)i+=t[n][o][1]||0;if(i)for(n=0;n<r;++n)t[n][o][1]/=i}MT(t,e)}}function ST(t,e){if((s=t.length)>0)for(var n,r,i,o,a,s,u=0,l=t[e[0]].length;u<l;++u)for(o=a=0,n=0;n<s;++n)(i=(r=t[e[n]][u])[1]-r[0])>0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=a,r[0]=a+=i):(r[0]=0,r[1]=i)}function OT(t,e){if((n=t.length)>0){for(var n,r=0,i=t[e[0]],o=i.length;r<o;++r){for(var a=0,s=0;a<n;++a)s+=t[a][r][1]||0;i[r][1]+=i[r][0]=-s/2}MT(t,e)}}function PT(t,e){if((i=t.length)>0&&(r=(n=t[e[0]]).length)>0){for(var n,r,i,o=0,a=1;a<r;++a){for(var s=0,u=0,l=0;s<i;++s){for(var c=t[e[s]],f=c[a][1]||0,h=(f-(c[a-1][1]||0))/2,d=0;d<s;++d){var p=t[e[d]];h+=(p[a][1]||0)-(p[a-1][1]||0)}u+=f,l+=h*f}n[a-1][1]+=n[a-1][0]=o,u&&(o-=l/u)}n[a-1][1]+=n[a-1][0]=o,MT(t,e)}}function LT(t){var e=t.map(RT);return AT(t).sort((function(t,n){return e[t]-e[n]}))}function RT(t){for(var e,n=-1,r=0,i=t.length,o=-1/0;++n<i;)(e=+t[n][1])>o&&(o=e,r=n);return r}function IT(t){var e=t.map(DT);return AT(t).sort((function(t,n){return e[t]-e[n]}))}function DT(t){for(var e,n=0,r=-1,i=t.length;++r<i;)(e=+t[r][1])&&(n+=e);return n}function NT(t){return IT(t).reverse()}function FT(t){var e,n,r=t.length,i=t.map(DT),o=LT(t),a=0,s=0,u=[],l=[];for(e=0;e<r;++e)n=o[e],a<s?(a+=i[n],u.push(n)):(s+=i[n],l.push(n));return l.reverse().concat(u)}function jT(t){return AT(t).reverse()}oT.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}},fT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:cT(this,this._t0,lT(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,cT(this,lT(this,n=uT(this,t,e)),n);break;default:cT(this,this._t0,n=uT(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(hT.prototype=Object.create(fT.prototype)).point=function(t,e){fT.prototype.point.call(this,e,t)},dT.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},gT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=yT(t),i=yT(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}},xT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var zT="%Y-%m-%dT%H:%M:%S.%LZ";var BT=Date.prototype.toISOString?function(t){return t.toISOString()}:Hx(zT),VT=BT;var qT=+new Date("2000-01-01T00:00:00.000Z")?function(t){var e=new Date(t);return isNaN(e)?null:e}:Wx(zT),GT=qT;function UT(t,e,n){var r=new di,i=e;return null==e?(r.restart(t,e,n),r):(r._restart=r.restart,r.restart=function(t,e,n){e=+e,n=null==n?fi():+n,r._restart((function o(a){a+=i,r._restart(o,i+=e,n),t(a)}),e,n)},r.restart(t,e,n),r)}var HT=t=>()=>t;function WT(t,{sourceEvent:e,target:n,transform:r,dispatch:i}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:i}})}function XT(t,e,n){this.k=t,this.x=e,this.y=n}XT.prototype={constructor:XT,scale:function(t){return 1===t?this:new XT(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new XT(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var KT=new XT(1,0,0);function QT(t){for(;!t.__zoom;)if(!(t=t.parentNode))return KT;return t.__zoom}function YT(t){t.stopImmediatePropagation()}function $T(t){t.preventDefault(),t.stopImmediatePropagation()}function ZT(t){return!(t.ctrlKey&&"wheel"!==t.type||t.button)}function JT(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t).hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]:[[0,0],[t.clientWidth,t.clientHeight]]}function tE(){return this.__zoom||KT}function eE(t){return-t.deltaY*(1===t.deltaMode?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function nE(){return navigator.maxTouchPoints||"ontouchstart"in this}function rE(t,e,n){var r=t.invertX(e[0][0])-n[0][0],i=t.invertX(e[1][0])-n[1][0],o=t.invertY(e[0][1])-n[0][1],a=t.invertY(e[1][1])-n[1][1];return t.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a))}function iE(){var t,e,n,r=ZT,i=JT,o=rE,a=eE,s=nE,u=[0,1/0],l=[[-1/0,-1/0],[1/0,1/0]],c=250,f=qg,h=Ee("start","zoom","end"),d=0,p=10;function m(t){t.property("__zoom",tE).on("wheel.zoom",w,{passive:!1}).on("mousedown.zoom",M).on("dblclick.zoom",A).filter(s).on("touchstart.zoom",T).on("touchmove.zoom",E).on("touchend.zoom touchcancel.zoom",C).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(t,e){return(e=Math.max(u[0],Math.min(u[1],e)))===t.k?t:new XT(e,t.x,t.y)}function y(t,e,n){var r=e[0]-n[0]*t.k,i=e[1]-n[1]*t.k;return r===t.x&&i===t.y?t:new XT(t.k,r,i)}function v(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function x(t,e,n,r){t.on("start.zoom",(function(){_(this,arguments).event(r).start()})).on("interrupt.zoom end.zoom",(function(){_(this,arguments).event(r).end()})).tween("zoom",(function(){var t=this,o=arguments,a=_(t,o).event(r),s=i.apply(t,o),u=null==n?v(s):"function"==typeof n?n.apply(t,o):n,l=Math.max(s[1][0]-s[0][0],s[1][1]-s[0][1]),c=t.__zoom,h="function"==typeof e?e.apply(t,o):e,d=f(c.invert(u).concat(l/c.k),h.invert(u).concat(l/h.k));return function(t){if(1===t)t=h;else{var e=d(t),n=l/e[2];t=new XT(n,u[0]-e[0]*n,u[1]-e[1]*n)}a.zoom(null,t)}}))}function _(t,e,n){return!n&&t.__zooming||new b(t,e)}function b(t,e){this.that=t,this.args=e,this.active=0,this.sourceEvent=null,this.extent=i.apply(t,e),this.taps=0}function w(t,...e){if(r.apply(this,arguments)){var n=_(this,e).event(t),i=this.__zoom,s=Math.max(u[0],Math.min(u[1],i.k*Math.pow(2,a.apply(this,arguments)))),c=ti(t);if(n.wheel)n.mouse[0][0]===c[0]&&n.mouse[0][1]===c[1]||(n.mouse[1]=i.invert(n.mouse[0]=c)),clearTimeout(n.wheel);else{if(i.k===s)return;n.mouse=[c,i.invert(c)],Oi(this),n.start()}$T(t),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),150),n.zoom("mouse",o(y(g(i,s),n.mouse[0],n.mouse[1]),n.extent,l))}}function M(t,...e){if(!n&&r.apply(this,arguments)){var i=t.currentTarget,a=_(this,e,!0).event(t),s=Vn(t.view).on("mousemove.zoom",(function(t){if($T(t),!a.moved){var e=t.clientX-c,n=t.clientY-f;a.moved=e*e+n*n>d}a.event(t).zoom("mouse",o(y(a.that.__zoom,a.mouse[0]=ti(t,i),a.mouse[1]),a.extent,l))}),!0).on("mouseup.zoom",(function(t){s.on("mousemove.zoom mouseup.zoom",null),Xn(t.view,a.moved),$T(t),a.event(t).end()}),!0),u=ti(t,i),c=t.clientX,f=t.clientY;Wn(t.view),YT(t),a.mouse=[u,this.__zoom.invert(u)],Oi(this),a.start()}}function A(t,...e){if(r.apply(this,arguments)){var n=this.__zoom,a=ti(t.changedTouches?t.changedTouches[0]:t,this),s=n.invert(a),u=n.k*(t.shiftKey?.5:2),f=o(y(g(n,u),a,s),i.apply(this,e),l);$T(t),c>0?Vn(this).transition().duration(c).call(x,f,a,t):Vn(this).call(m.transform,f,a,t)}}function T(n,...i){if(r.apply(this,arguments)){var o,a,s,u,l=n.touches,c=l.length,f=_(this,i,n.changedTouches.length===c).event(n);for(YT(n),a=0;a<c;++a)u=[u=ti(s=l[a],this),this.__zoom.invert(u),s.identifier],f.touch0?f.touch1||f.touch0[2]===u[2]||(f.touch1=u,f.taps=0):(f.touch0=u,o=!0,f.taps=1+!!t);t&&(t=clearTimeout(t)),o&&(f.taps<2&&(e=u[0],t=setTimeout((function(){t=null}),500)),Oi(this),f.start())}}function E(t,...e){if(this.__zooming){var n,r,i,a,s=_(this,e).event(t),u=t.changedTouches,c=u.length;for($T(t),n=0;n<c;++n)i=ti(r=u[n],this),s.touch0&&s.touch0[2]===r.identifier?s.touch0[0]=i:s.touch1&&s.touch1[2]===r.identifier&&(s.touch1[0]=i);if(r=s.that.__zoom,s.touch1){var f=s.touch0[0],h=s.touch0[1],d=s.touch1[0],p=s.touch1[1],m=(m=d[0]-f[0])*m+(m=d[1]-f[1])*m,v=(v=p[0]-h[0])*v+(v=p[1]-h[1])*v;r=g(r,Math.sqrt(m/v)),i=[(f[0]+d[0])/2,(f[1]+d[1])/2],a=[(h[0]+p[0])/2,(h[1]+p[1])/2]}else{if(!s.touch0)return;i=s.touch0[0],a=s.touch0[1]}s.zoom("touch",o(y(r,i,a),s.extent,l))}}function C(t,...r){if(this.__zooming){var i,o,a=_(this,r).event(t),s=t.changedTouches,u=s.length;for(YT(t),n&&clearTimeout(n),n=setTimeout((function(){n=null}),500),i=0;i<u;++i)o=s[i],a.touch0&&a.touch0[2]===o.identifier?delete a.touch0:a.touch1&&a.touch1[2]===o.identifier&&delete a.touch1;if(a.touch1&&!a.touch0&&(a.touch0=a.touch1,delete a.touch1),a.touch0)a.touch0[1]=this.__zoom.invert(a.touch0[0]);else if(a.end(),2===a.taps&&(o=ti(o,this),Math.hypot(e[0]-o[0],e[1]-o[1])<p)){var l=Vn(this).on("dblclick.zoom");l&&l.apply(this,arguments)}}}return m.transform=function(t,e,n,r){var i=t.selection?t.selection():t;i.property("__zoom",tE),t!==i?x(t,e,n,r):i.interrupt().each((function(){_(this,arguments).event(r).start().zoom(null,"function"==typeof e?e.apply(this,arguments):e).end()}))},m.scaleBy=function(t,e,n,r){m.scaleTo(t,(function(){return this.__zoom.k*("function"==typeof e?e.apply(this,arguments):e)}),n,r)},m.scaleTo=function(t,e,n,r){m.transform(t,(function(){var t=i.apply(this,arguments),r=this.__zoom,a=null==n?v(t):"function"==typeof n?n.apply(this,arguments):n,s=r.invert(a),u="function"==typeof e?e.apply(this,arguments):e;return o(y(g(r,u),a,s),t,l)}),n,r)},m.translateBy=function(t,e,n,r){m.transform(t,(function(){return o(this.__zoom.translate("function"==typeof e?e.apply(this,arguments):e,"function"==typeof n?n.apply(this,arguments):n),i.apply(this,arguments),l)}),null,r)},m.translateTo=function(t,e,n,r,a){m.transform(t,(function(){var t=i.apply(this,arguments),a=this.__zoom,s=null==r?v(t):"function"==typeof r?r.apply(this,arguments):r;return o(KT.translate(s[0],s[1]).scale(a.k).translate("function"==typeof e?-e.apply(this,arguments):-e,"function"==typeof n?-n.apply(this,arguments):-n),t,l)}),r,a)},b.prototype={event:function(t){return t&&(this.sourceEvent=t),this},start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(t,e){return this.mouse&&"mouse"!==t&&(this.mouse[1]=e.invert(this.mouse[0])),this.touch0&&"touch"!==t&&(this.touch0[1]=e.invert(this.touch0[0])),this.touch1&&"touch"!==t&&(this.touch1[1]=e.invert(this.touch1[0])),this.that.__zoom=e,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(t){var e=Vn(this.that).datum();h.call(t,this.that,new WT(t,{sourceEvent:this.sourceEvent,target:m,type:t,transform:this.that.__zoom,dispatch:h}),e)}},m.wheelDelta=function(t){return arguments.length?(a="function"==typeof t?t:HT(+t),m):a},m.filter=function(t){return arguments.length?(r="function"==typeof t?t:HT(!!t),m):r},m.touchable=function(t){return arguments.length?(s="function"==typeof t?t:HT(!!t),m):s},m.extent=function(t){return arguments.length?(i="function"==typeof t?t:HT([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),m):i},m.scaleExtent=function(t){return arguments.length?(u[0]=+t[0],u[1]=+t[1],m):[u[0],u[1]]},m.translateExtent=function(t){return arguments.length?(l[0][0]=+t[0][0],l[1][0]=+t[1][0],l[0][1]=+t[0][1],l[1][1]=+t[1][1],m):[[l[0][0],l[0][1]],[l[1][0],l[1][1]]]},m.constrain=function(t){return arguments.length?(o=t,m):o},m.duration=function(t){return arguments.length?(c=+t,m):c},m.interpolate=function(t){return arguments.length?(f=t,m):f},m.on=function(){var t=h.on.apply(h,arguments);return t===h?m:t},m.clickDistance=function(t){return arguments.length?(d=(t=+t)*t,m):Math.sqrt(d)},m.tapDistance=function(t){return arguments.length?(p=+t,m):p},m}QT.prototype=XT.prototype}},n={};function r(t){var i=n[t];if(void 0!==i)return i.exports;var o=n[t]={id:t,exports:{}};return e[t].call(o.exports,o,o.exports,r),o.exports}return r.m=e,r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.b=document.baseURI||self.location.href,r.nc=void 0,r(2257)}()}));
|
|
54
|
+
var r,i=n(671),o=n(1526),a=n(3074),s=n(8534),u=n(8927),l=n(9779),c=!1,f=o();function h(t,e,n){var i=r.segments(t),o=r.segments(e),a=n(r.combine(i,o));return r.polygon(a)}r={buildLog:function(t){return!0===t?c=i():!1===t&&(c=!1),!1!==c&&c.list},epsilon:function(t){return f.epsilon(t)},segments:function(t){var e=a(!0,f,c);return t.regions.forEach(e.addRegion),{segments:e.calculate(t.inverted),inverted:t.inverted}},combine:function(t,e){return{combined:a(!1,f,c).calculate(t.segments,t.inverted,e.segments,e.inverted),inverted1:t.inverted,inverted2:e.inverted}},selectUnion:function(t){return{segments:u.union(t.combined,c),inverted:t.inverted1||t.inverted2}},selectIntersect:function(t){return{segments:u.intersect(t.combined,c),inverted:t.inverted1&&t.inverted2}},selectDifference:function(t){return{segments:u.difference(t.combined,c),inverted:t.inverted1&&!t.inverted2}},selectDifferenceRev:function(t){return{segments:u.differenceRev(t.combined,c),inverted:!t.inverted1&&t.inverted2}},selectXor:function(t){return{segments:u.xor(t.combined,c),inverted:t.inverted1!==t.inverted2}},polygon:function(t){return{regions:s(t.segments,f,c),inverted:t.inverted}},polygonFromGeoJSON:function(t){return l.toPolygon(r,t)},polygonToGeoJSON:function(t){return l.fromPolygon(r,f,t)},union:function(t,e){return h(t,e,r.selectUnion)},intersect:function(t,e){return h(t,e,r.selectIntersect)},difference:function(t,e){return h(t,e,r.selectDifference)},differenceRev:function(t,e){return h(t,e,r.selectDifferenceRev)},xor:function(t,e){return h(t,e,r.selectXor)}},"object"==typeof window&&(window.PolyBool=r),t.exports=r},671:function(t){t.exports=function(){var t,e=0,n=!1;function r(e,n){return t.list.push({type:e,data:n?JSON.parse(JSON.stringify(n)):void 0}),t}return t={list:[],segmentId:function(){return e++},checkIntersection:function(t,e){return r("check",{seg1:t,seg2:e})},segmentChop:function(t,e){return r("div_seg",{seg:t,pt:e}),r("chop",{seg:t,pt:e})},statusRemove:function(t){return r("pop_seg",{seg:t})},segmentUpdate:function(t){return r("seg_update",{seg:t})},segmentNew:function(t,e){return r("new_seg",{seg:t,primary:e})},segmentRemove:function(t){return r("rem_seg",{seg:t})},tempStatus:function(t,e,n){return r("temp_status",{seg:t,above:e,below:n})},rewind:function(t){return r("rewind",{seg:t})},status:function(t,e,n){return r("status",{seg:t,above:e,below:n})},vert:function(e){return e===n?t:(n=e,r("vert",{x:e}))},log:function(t){return"string"!=typeof t&&(t=JSON.stringify(t,!1," ")),r("log",{txt:t})},reset:function(){return r("reset")},selected:function(t){return r("selected",{segs:t})},chainStart:function(t){return r("chain_start",{seg:t})},chainRemoveHead:function(t,e){return r("chain_rem_head",{index:t,pt:e})},chainRemoveTail:function(t,e){return r("chain_rem_tail",{index:t,pt:e})},chainNew:function(t,e){return r("chain_new",{pt1:t,pt2:e})},chainMatch:function(t){return r("chain_match",{index:t})},chainClose:function(t){return r("chain_close",{index:t})},chainAddHead:function(t,e){return r("chain_add_head",{index:t,pt:e})},chainAddTail:function(t,e){return r("chain_add_tail",{index:t,pt:e})},chainConnect:function(t,e){return r("chain_con",{index1:t,index2:e})},chainReverse:function(t){return r("chain_rev",{index:t})},chainJoin:function(t,e){return r("chain_join",{index1:t,index2:e})},done:function(){return r("done")}}}},1526:function(t){t.exports=function(t){"number"!=typeof t&&(t=1e-10);var e={epsilon:function(e){return"number"==typeof e&&(t=e),t},pointAboveOrOnLine:function(e,n,r){var i=n[0],o=n[1],a=r[0],s=r[1],u=e[0],l=e[1],c=a-i,f=s-o,h=Math.sqrt(c*c+f*f);return c*(l-o)-f*(u-i)>=-t*h},pointBetween:function(t,n,r){if(e.pointsSame(t,n)||e.pointsSame(t,r))return!1;var i=t[1]-n[1],o=r[0]-n[0],a=t[0]-n[0],s=r[1]-n[1],u=a*o+i*s;return!(u<0)&&u<=o*o+s*s},pointsSameX:function(e,n){return Math.abs(e[0]-n[0])<t},pointsSameY:function(e,n){return Math.abs(e[1]-n[1])<t},pointsSame:function(t,n){return e.pointsSameX(t,n)&&e.pointsSameY(t,n)},pointsCompare:function(t,n){return e.pointsSameX(t,n)?e.pointsSameY(t,n)?0:t[1]<n[1]?-1:1:t[0]<n[0]?-1:1},pointsCollinear:function(e,n,r){var i=e[0]-n[0],o=e[1]-n[1],a=n[0]-r[0],s=n[1]-r[1],u=Math.sqrt(i*i+o*o),l=Math.sqrt(a*a+s*s);return Math.abs(i*s-a*o)<=t*(u+l)},linesIntersect:function(n,r,i,o){var a=r[0]-n[0],s=r[1]-n[1],u=o[0]-i[0],l=o[1]-i[1],c=a*l-s*u,f=Math.sqrt(a*a+s*s),h=Math.sqrt(u*u+l*l);if(Math.abs(c)<=t*(f+h))return!1;var d=n[0]-i[0],p=n[1]-i[1],m=(u*p-l*d)/c,g=(a*p-s*d)/c,y=[n[0]+m*a,n[1]+m*s],v={alongA:0,alongB:0,pt:y};return e.pointsSame(y,n)?v.alongA=-1:e.pointsSame(y,r)?v.alongA=1:m<0?v.alongA=-2:m>1&&(v.alongA=2),e.pointsSame(y,i)?v.alongB=-1:e.pointsSame(y,o)?v.alongB=1:g<0?v.alongB=-2:g>1&&(v.alongB=2),v},pointInsideRegion:function(e,n){for(var r=e[0],i=e[1],o=n[n.length-1][0],a=n[n.length-1][1],s=!1,u=0;u<n.length;u++){var l=n[u][0],c=n[u][1];c-i>t!=a-i>t&&(o-l)*(i-c)/(a-c)+l-r>t&&(s=!s),o=l,a=c}return s}};return e}},9779:function(t){var e={toPolygon:function(t,e){function n(e){if(e.length<=0)return t.segments({inverted:!1,regions:[]});function n(e){var n=e.slice(0,e.length-1);return t.segments({inverted:!1,regions:[n]})}for(var r=n(e[0]),i=1;i<e.length;i++)r=t.selectDifference(t.combine(r,n(e[i])));return r}if("Polygon"===e.type)return t.polygon(n(e.coordinates));if("MultiPolygon"===e.type){for(var r=t.segments({inverted:!1,regions:[]}),i=0;i<e.coordinates.length;i++)r=t.selectUnion(t.combine(r,n(e.coordinates[i])));return t.polygon(r)}throw new Error("PolyBool: Cannot convert GeoJSON object to PolyBool polygon")},fromPolygon:function(t,e,n){function r(t,n){return e.pointInsideRegion([.5*(t[0][0]+t[1][0]),.5*(t[0][1]+t[1][1])],n)}function i(t){return{region:t,children:[]}}n=t.polygon(t.segments(n));var o=i(null);function a(t,e){for(var n=0;n<t.children.length;n++){if(r(e,(s=t.children[n]).region))return void a(s,e)}var o=i(e);for(n=0;n<t.children.length;n++){var s;r((s=t.children[n]).region,e)&&(o.children.push(s),t.children.splice(n,1),n--)}t.children.push(o)}for(var s=0;s<n.regions.length;s++){var u=n.regions[s];u.length<3||a(o,u)}function l(t,e){for(var n=0,r=t[t.length-1][0],i=t[t.length-1][1],o=[],a=0;a<t.length;a++){var s=t[a][0],u=t[a][1];o.push([s,u]),n+=u*r-s*i,r=s,i=u}return n<0!==e&&o.reverse(),o.push([o[0][0],o[0][1]]),o}var c=[];function f(t){var e=[l(t.region,!1)];c.push(e);for(var n=0;n<t.children.length;n++)e.push(h(t.children[n]))}function h(t){for(var e=0;e<t.children.length;e++)f(t.children[e]);return l(t.region,!0)}for(s=0;s<o.children.length;s++)f(o.children[s]);return c.length<=0?{type:"Polygon",coordinates:[]}:1==c.length?{type:"Polygon",coordinates:c[0]}:{type:"MultiPolygon",coordinates:c}}};t.exports=e},3074:function(t,e,n){var r=n(4092);t.exports=function(t,e,n){function i(t,e,r){return{id:n?n.segmentId():-1,start:t,end:e,myFill:{above:r.myFill.above,below:r.myFill.below},otherFill:null}}var o=r.create();function a(t,n){o.insertBefore(t,(function(r){return function(t,n,r,i,o,a){var s=e.pointsCompare(n,o);return 0!==s?s:e.pointsSame(r,a)?0:t!==i?t?1:-1:e.pointAboveOrOnLine(r,i?o:a,i?a:o)?1:-1}(t.isStart,t.pt,n,r.isStart,r.pt,r.other.pt)<0}))}function s(t,e){var n=function(t,e){var n=r.node({isStart:!0,pt:t.start,seg:t,primary:e,other:null,status:null});return a(n,t.end),n}(t,e);return function(t,e,n){var i=r.node({isStart:!1,pt:e.end,seg:e,primary:n,other:t,status:null});t.other=i,a(i,t.pt)}(n,t,e),n}function u(t,e){var r=i(e,t.seg.end,t.seg);return function(t,e){n&&n.segmentChop(t.seg,e),t.other.remove(),t.seg.end=e,t.other.pt=e,a(t.other,t.pt)}(t,e),s(r,t.primary)}function l(i,a){var s=r.create();function l(t){return s.findTransition((function(n){var r,i,o,a,s,u;return(r=t,i=n.ev,o=r.seg.start,a=r.seg.end,s=i.seg.start,u=i.seg.end,e.pointsCollinear(o,s,u)?e.pointsCollinear(a,s,u)||e.pointAboveOrOnLine(a,s,u)?1:-1:e.pointAboveOrOnLine(o,s,u)?1:-1)>0}))}function c(t,r){var i=t.seg,o=r.seg,a=i.start,s=i.end,l=o.start,c=o.end;n&&n.checkIntersection(i,o);var f=e.linesIntersect(a,s,l,c);if(!1===f){if(!e.pointsCollinear(a,s,l))return!1;if(e.pointsSame(a,c)||e.pointsSame(s,l))return!1;var h=e.pointsSame(a,l),d=e.pointsSame(s,c);if(h&&d)return r;var p=!h&&e.pointBetween(a,l,c),m=!d&&e.pointBetween(s,l,c);if(h)return m?u(r,s):u(t,c),r;p&&(d||(m?u(r,s):u(t,c)),u(r,a))}else 0===f.alongA&&(-1===f.alongB?u(t,l):0===f.alongB?u(t,f.pt):1===f.alongB&&u(t,c)),0===f.alongB&&(-1===f.alongA?u(r,a):0===f.alongA?u(r,f.pt):1===f.alongA&&u(r,s));return!1}for(var f=[];!o.isEmpty();){var h=o.getHead();if(n&&n.vert(h.pt[0]),h.isStart){n&&n.segmentNew(h.seg,h.primary);var d=l(h),p=d.before?d.before.ev:null,m=d.after?d.after.ev:null;function g(){if(p){var t=c(h,p);if(t)return t}return!!m&&c(h,m)}n&&n.tempStatus(h.seg,!!p&&p.seg,!!m&&m.seg);var y,v=g();if(v){var x;if(t)(x=null===h.seg.myFill.below||h.seg.myFill.above!==h.seg.myFill.below)&&(v.seg.myFill.above=!v.seg.myFill.above);else v.seg.otherFill=h.seg.myFill;n&&n.segmentUpdate(v.seg),h.other.remove(),h.remove()}if(o.getHead()!==h){n&&n.rewind(h.seg);continue}if(t)x=null===h.seg.myFill.below||h.seg.myFill.above!==h.seg.myFill.below,h.seg.myFill.below=m?m.seg.myFill.above:i,h.seg.myFill.above=x?!h.seg.myFill.below:h.seg.myFill.below;else if(null===h.seg.otherFill)y=m?h.primary===m.primary?m.seg.otherFill.above:m.seg.myFill.above:h.primary?a:i,h.seg.otherFill={above:y,below:y};n&&n.status(h.seg,!!p&&p.seg,!!m&&m.seg),h.other.status=d.insert(r.node({ev:h}))}else{var _=h.status;if(null===_)throw new Error("PolyBool: Zero-length segment detected; your epsilon is probably too small or too large");if(s.exists(_.prev)&&s.exists(_.next)&&c(_.prev.ev,_.next.ev),n&&n.statusRemove(_.ev.seg),_.remove(),!h.primary){var b=h.seg.myFill;h.seg.myFill=h.seg.otherFill,h.seg.otherFill=b}f.push(h.seg)}o.getHead().remove()}return n&&n.done(),f}return t?{addRegion:function(t){for(var r,i,o,a=t[t.length-1],u=0;u<t.length;u++){r=a,a=t[u];var l=e.pointsCompare(r,a);0!==l&&s((i=l<0?r:a,o=l<0?a:r,{id:n?n.segmentId():-1,start:i,end:o,myFill:{above:null,below:null},otherFill:null}),!0)}},calculate:function(t){return l(t,!1)}}:{calculate:function(t,e,n,r){return t.forEach((function(t){s(i(t.start,t.end,t),!0)})),n.forEach((function(t){s(i(t.start,t.end,t),!1)})),l(e,r)}}}},4092:function(t){t.exports={create:function(){var t={root:{root:!0,next:null},exists:function(e){return null!==e&&e!==t.root},isEmpty:function(){return null===t.root.next},getHead:function(){return t.root.next},insertBefore:function(e,n){for(var r=t.root,i=t.root.next;null!==i;){if(n(i))return e.prev=i.prev,e.next=i,i.prev.next=e,void(i.prev=e);r=i,i=i.next}r.next=e,e.prev=r,e.next=null},findTransition:function(e){for(var n=t.root,r=t.root.next;null!==r&&!e(r);)n=r,r=r.next;return{before:n===t.root?null:n,after:r,insert:function(t){return t.prev=n,t.next=r,n.next=t,null!==r&&(r.prev=t),t}}}};return t},node:function(t){return t.prev=null,t.next=null,t.remove=function(){t.prev.next=t.next,t.next&&(t.next.prev=t.prev),t.prev=null,t.next=null},t}}},8534:function(t){t.exports=function(t,e,n){var r=[],i=[];return t.forEach((function(t){var o=t.start,a=t.end;if(e.pointsSame(o,a))console.warn("PolyBool: Warning: Zero-length segment detected; your epsilon is probably too small or too large");else{n&&n.chainStart(t);for(var s={index:0,matches_head:!1,matches_pt1:!1},u={index:0,matches_head:!1,matches_pt1:!1},l=s,c=0;c<r.length;c++){var f=(g=r[c])[0],h=(g[1],g[g.length-1]);g[g.length-2];if(e.pointsSame(f,o)){if(A(c,!0,!0))break}else if(e.pointsSame(f,a)){if(A(c,!0,!1))break}else if(e.pointsSame(h,o)){if(A(c,!1,!0))break}else if(e.pointsSame(h,a)&&A(c,!1,!1))break}if(l===s)return r.push([o,a]),void(n&&n.chainNew(o,a));if(l===u){n&&n.chainMatch(s.index);var d=s.index,p=s.matches_pt1?a:o,m=s.matches_head,g=r[d],y=m?g[0]:g[g.length-1],v=m?g[1]:g[g.length-2],x=m?g[g.length-1]:g[0],_=m?g[g.length-2]:g[1];return e.pointsCollinear(v,y,p)&&(m?(n&&n.chainRemoveHead(s.index,p),g.shift()):(n&&n.chainRemoveTail(s.index,p),g.pop()),y=v),e.pointsSame(x,p)?(r.splice(d,1),e.pointsCollinear(_,x,y)&&(m?(n&&n.chainRemoveTail(s.index,y),g.pop()):(n&&n.chainRemoveHead(s.index,y),g.shift())),n&&n.chainClose(s.index),void i.push(g)):void(m?(n&&n.chainAddHead(s.index,p),g.unshift(p)):(n&&n.chainAddTail(s.index,p),g.push(p)))}var b=s.index,w=u.index;n&&n.chainConnect(b,w);var M=r[b].length<r[w].length;s.matches_head?u.matches_head?M?(T(b),E(b,w)):(T(w),E(w,b)):E(w,b):u.matches_head?E(b,w):M?(T(b),E(w,b)):(T(w),E(b,w))}function A(t,e,n){return l.index=t,l.matches_head=e,l.matches_pt1=n,l===s?(l=u,!1):(l=null,!0)}function T(t){n&&n.chainReverse(t),r[t].reverse()}function E(t,i){var o=r[t],a=r[i],s=o[o.length-1],u=o[o.length-2],l=a[0],c=a[1];e.pointsCollinear(u,s,l)&&(n&&n.chainRemoveTail(t,s),o.pop(),s=u),e.pointsCollinear(s,l,c)&&(n&&n.chainRemoveHead(i,l),a.shift()),n&&n.chainJoin(t,i),r[t]=o.concat(a),r.splice(i,1)}})),i}},8927:function(t){function e(t,e,n){var r=[];return t.forEach((function(t){var i=(t.myFill.above?8:0)+(t.myFill.below?4:0)+(t.otherFill&&t.otherFill.above?2:0)+(t.otherFill&&t.otherFill.below?1:0);0!==e[i]&&r.push({id:n?n.segmentId():-1,start:t.start,end:t.end,myFill:{above:1===e[i],below:2===e[i]},otherFill:null})})),n&&n.selected(r),r}var n={union:function(t,n){return e(t,[0,2,1,0,2,2,0,0,1,0,1,0,0,0,0,0],n)},intersect:function(t,n){return e(t,[0,0,0,0,0,2,0,2,0,0,1,1,0,2,1,0],n)},difference:function(t,n){return e(t,[0,0,0,0,2,0,2,0,1,1,0,0,0,1,2,0],n)},differenceRev:function(t,n){return e(t,[0,2,1,0,0,0,1,1,0,2,0,2,0,0,0,0],n)},xor:function(t,n){return e(t,[0,2,1,0,2,0,0,1,1,0,0,2,0,1,2,0],n)}};t.exports=n},5473:function(t,e,n){"use strict";n.d(e,{A:function(){return o}});var r=n(2556),i=n(4205);function o(t){return Math.abs(t)<r.sK?t:t-(0,i.A)(t)*Math.PI}},737:function(t,e,n){"use strict";n.d(e,{A:function(){return o}});var r=n(2556),i=n(4205);function o(t){return Math.abs(t)<=r.DF?t:t-(0,i.A)(t)*r.JM}},8609:function(t,e,n){"use strict";function r(t){return Math.abs(t)>1&&(t=t>1?1:-1),Math.asin(t)}n.d(e,{A:function(){return r}})},4885:function(t,e,n){"use strict";function r(t){var e=Math.exp(t);return e=(e+1/e)/2}n.d(e,{A:function(){return r}})},8193:function(t,e,n){"use strict";function r(t){return 1-.25*t*(1+t/16*(3+1.25*t))}n.d(e,{A:function(){return r}})},9686:function(t,e,n){"use strict";function r(t){return.375*t*(1+.25*t*(1+.46875*t))}n.d(e,{A:function(){return r}})},7711:function(t,e,n){"use strict";function r(t){return.05859375*t*t*(1+.75*t)}n.d(e,{A:function(){return r}})},2060:function(t,e,n){"use strict";function r(t){return t*t*t*(35/3072)}n.d(e,{A:function(){return r}})},7973:function(t,e,n){"use strict";function r(t,e,n){var r=e*n;return t/Math.sqrt(1-r*r)}n.d(e,{A:function(){return r}})},1708:function(t,e,n){"use strict";function r(t,e){t=Math.abs(t),e=Math.abs(e);var n=Math.max(t,e),r=Math.min(t,e)/(n||1);return n*Math.sqrt(1+Math.pow(r,2))}n.d(e,{A:function(){return r}})},6592:function(t,e,n){"use strict";function r(t,e,n,r,i){var o,a;o=t/e;for(var s=0;s<15;s++)if(o+=a=(t-(e*o-n*Math.sin(2*o)+r*Math.sin(4*o)-i*Math.sin(6*o)))/(e-2*n*Math.cos(2*o)+4*r*Math.cos(4*o)-6*i*Math.cos(6*o)),Math.abs(a)<=1e-10)return o;return NaN}n.d(e,{A:function(){return r}})},4037:function(t,e,n){"use strict";function r(t,e,n,r,i){return t*i-e*Math.sin(2*i)+n*Math.sin(4*i)-r*Math.sin(6*i)}n.d(e,{A:function(){return r}})},444:function(t,e,n){"use strict";function r(t,e,n){var r=t*e;return n/Math.sqrt(1-r*r)}n.d(e,{A:function(){return r}})},1793:function(t,e,n){"use strict";n.d(e,{A:function(){return i}});var r=n(2556);function i(t,e){for(var n,i,o=.5*t,a=r.sK-2*Math.atan(e),s=0;s<=15;s++)if(n=t*Math.sin(a),a+=i=r.sK-2*Math.atan(e*Math.pow((1-n)/(1+n),o))-a,Math.abs(i)<=1e-10)return a;return-9999}},6366:function(t,e,n){"use strict";n.d(e,{A:function(){return m}});var r=1,i=.25,o=.046875,a=.01953125,s=.01068115234375,u=.75,l=.46875,c=.013020833333333334,f=.007120768229166667,h=.3645833333333333,d=.005696614583333333,p=.3076171875;function m(t){var e=[];e[0]=r-t*(i+t*(o+t*(a+t*s))),e[1]=t*(u-t*(o+t*(a+t*s)));var n=t*t;return e[2]=n*(l-t*(c+t*f)),n*=t,e[3]=n*(h-t*d),e[4]=n*t*p,e}},3220:function(t,e,n){"use strict";n.d(e,{A:function(){return a}});var r=n(2092),i=n(2556),o=20;function a(t,e,n){for(var a=1/(1-e),s=t,u=o;u;--u){var l=Math.sin(s),c=1-e*l*l;if(s-=c=((0,r.A)(s,l,Math.cos(s),n)-t)*(c*Math.sqrt(c))*a,Math.abs(c)<i.H0)return s}return s}},2092:function(t,e,n){"use strict";function r(t,e,n,r){return n*=e,e*=e,r[0]*t-n*(r[1]+e*(r[2]+e*(r[3]+e*r[4])))}n.d(e,{A:function(){return r}})},7200:function(t,e,n){"use strict";function r(t,e){var n;return t>1e-7?(1-t*t)*(e/(1-(n=t*e)*n)-.5/t*Math.log((1-n)/(1+n))):2*e}n.d(e,{A:function(){return r}})},4205:function(t,e,n){"use strict";function r(t){return t<0?-1:1}n.d(e,{A:function(){return r}})},3882:function(t,e,n){"use strict";function r(t){var e=Math.exp(t);return e=(e-1/e)/2}n.d(e,{A:function(){return r}})},9967:function(t,e,n){"use strict";n.d(e,{A:function(){return i}});var r=n(2556);function i(t,e,n){var i=t*n,o=.5*t;return i=Math.pow((1-i)/(1+i),o),Math.tan(.5*(r.sK-e))/i}},2556:function(t,e,n){"use strict";n.d(e,{A1:function(){return s},DF:function(){return b},G9:function(){return o},H0:function(){return g},JM:function(){return _},Q1:function(){return p},Vj:function(){return x},Y$:function(){return i},_3:function(){return f},a8:function(){return r},bA:function(){return d},bv:function(){return u},dX:function(){return v},ej:function(){return m},gS:function(){return c},sK:function(){return h},xK:function(){return a},zp:function(){return l},zq:function(){return y}});var r=1,i=2,o=3,a=4,s=5,u=6378137,l=6356752.314,c=.0066943799901413165,f=484813681109536e-20,h=Math.PI/2,d=.16666666666666666,p=.04722222222222222,m=.022156084656084655,g=1e-10,y=.017453292519943295,v=57.29577951308232,x=Math.PI/4,_=2*Math.PI,b=3.14159265359},9160:function(t,e,n){"use strict";n.d(e,{Fs:function(){return u},OI:function(){return i},Rw:function(){return a},jX:function(){return o},mj:function(){return s}});var r=n(2556);function i(t,e){return t.datum_type===e.datum_type&&(!(t.a!==e.a||Math.abs(t.es-e.es)>5e-11)&&(t.datum_type===r.a8?t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]:t.datum_type!==r.Y$||t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]&&t.datum_params[3]===e.datum_params[3]&&t.datum_params[4]===e.datum_params[4]&&t.datum_params[5]===e.datum_params[5]&&t.datum_params[6]===e.datum_params[6]))}function o(t,e,n){var i,o,a,s,u=t.x,l=t.y,c=t.z?t.z:0;if(l<-r.sK&&l>-1.001*r.sK)l=-r.sK;else if(l>r.sK&&l<1.001*r.sK)l=r.sK;else{if(l<-r.sK)return{x:-1/0,y:-1/0,z:t.z};if(l>r.sK)return{x:1/0,y:1/0,z:t.z}}return u>Math.PI&&(u-=2*Math.PI),o=Math.sin(l),s=Math.cos(l),a=o*o,{x:((i=n/Math.sqrt(1-e*a))+c)*s*Math.cos(u),y:(i+c)*s*Math.sin(u),z:(i*(1-e)+c)*o}}function a(t,e,n,i){var o,a,s,u,l,c,f,h,d,p,m,g,y,v,x,_=1e-12,b=t.x,w=t.y,M=t.z?t.z:0;if(o=Math.sqrt(b*b+w*w),a=Math.sqrt(b*b+w*w+M*M),o/n<_){if(v=0,a/n<_)return r.sK,x=-i,{x:t.x,y:t.y,z:t.z}}else v=Math.atan2(w,b);s=M/a,h=(u=o/a)*(1-e)*(l=1/Math.sqrt(1-e*(2-e)*u*u)),d=s*l,y=0;do{y++,c=e*(f=n/Math.sqrt(1-e*d*d))/(f+(x=o*h+M*d-f*(1-e*d*d))),g=(m=s*(l=1/Math.sqrt(1-c*(2-c)*u*u)))*h-(p=u*(1-c)*l)*d,h=p,d=m}while(g*g>1e-24&&y<30);return{x:v,y:Math.atan(m/Math.abs(p)),z:x}}function s(t,e,n){if(e===r.a8)return{x:t.x+n[0],y:t.y+n[1],z:t.z+n[2]};if(e===r.Y$){var i=n[0],o=n[1],a=n[2],s=n[3],u=n[4],l=n[5],c=n[6];return{x:c*(t.x-l*t.y+u*t.z)+i,y:c*(l*t.x+t.y-s*t.z)+o,z:c*(-u*t.x+s*t.y+t.z)+a}}}function u(t,e,n){if(e===r.a8)return{x:t.x-n[0],y:t.y-n[1],z:t.z-n[2]};if(e===r.Y$){var i=n[0],o=n[1],a=n[2],s=n[3],u=n[4],l=n[5],c=n[6],f=(t.x-i)/c,h=(t.y-o)/c,d=(t.z-a)/c;return{x:f+l*h-u*d,y:-l*f+h+s*d,z:u*f-s*h+d}}}},1960:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return le}});var r=n(2556),i={greenwich:0,lisbon:-9.131906111111,paris:2.337229166667,bogota:-74.080916666667,madrid:-3.687938888889,rome:12.452333333333,bern:7.439583333333,jakarta:106.807719444444,ferro:-17.666666666667,brussels:4.367975,stockholm:18.058277777778,athens:23.7163375,oslo:10.722916666667},o={mm:{to_meter:.001},cm:{to_meter:.01},ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937},fath:{to_meter:1.8288},kmi:{to_meter:1852},"us-ch":{to_meter:20.1168402336805},"us-mi":{to_meter:1609.34721869444},km:{to_meter:1e3},"ind-ft":{to_meter:.30479841},"ind-yd":{to_meter:.91439523},mi:{to_meter:1609.344},yd:{to_meter:.9144},ch:{to_meter:20.1168},link:{to_meter:.201168},dm:{to_meter:.01},in:{to_meter:.0254},"ind-ch":{to_meter:20.11669506},"us-in":{to_meter:.025400050800101},"us-yd":{to_meter:.914401828803658}},a=/[\s_\-\/\(\)]/g;function s(t,e){if(t[e])return t[e];for(var n,r=Object.keys(t),i=e.toLowerCase().replace(a,""),o=-1;++o<r.length;)if((n=r[o]).toLowerCase().replace(a,"")===i)return t[n]}function u(t){var e,n,a,u={},l=t.split("+").map((function(t){return t.trim()})).filter((function(t){return t})).reduce((function(t,e){var n=e.split("=");return n.push(!0),t[n[0].toLowerCase()]=n[1],t}),{}),c={proj:"projName",datum:"datumCode",rf:function(t){u.rf=parseFloat(t)},lat_0:function(t){u.lat0=t*r.zq},lat_1:function(t){u.lat1=t*r.zq},lat_2:function(t){u.lat2=t*r.zq},lat_ts:function(t){u.lat_ts=t*r.zq},lon_0:function(t){u.long0=t*r.zq},lon_1:function(t){u.long1=t*r.zq},lon_2:function(t){u.long2=t*r.zq},alpha:function(t){u.alpha=parseFloat(t)*r.zq},gamma:function(t){u.rectified_grid_angle=parseFloat(t)},lonc:function(t){u.longc=t*r.zq},x_0:function(t){u.x0=parseFloat(t)},y_0:function(t){u.y0=parseFloat(t)},k_0:function(t){u.k0=parseFloat(t)},k:function(t){u.k0=parseFloat(t)},a:function(t){u.a=parseFloat(t)},b:function(t){u.b=parseFloat(t)},r:function(t){u.a=u.b=parseFloat(t)},r_a:function(){u.R_A=!0},zone:function(t){u.zone=parseInt(t,10)},south:function(){u.utmSouth=!0},towgs84:function(t){u.datum_params=t.split(",").map((function(t){return parseFloat(t)}))},to_meter:function(t){u.to_meter=parseFloat(t)},units:function(t){u.units=t;var e=s(o,t);e&&(u.to_meter=e.to_meter)},from_greenwich:function(t){u.from_greenwich=t*r.zq},pm:function(t){var e=s(i,t);u.from_greenwich=(e||parseFloat(t))*r.zq},nadgrids:function(t){"@null"===t?u.datumCode="none":u.nadgrids=t},axis:function(t){var e="ewnsud";3===t.length&&-1!==e.indexOf(t.substr(0,1))&&-1!==e.indexOf(t.substr(1,1))&&-1!==e.indexOf(t.substr(2,1))&&(u.axis=t)},approx:function(){u.approx=!0}};for(e in l)n=l[e],e in c?"function"==typeof(a=c[e])?a(n):u[a]=n:u[e]=n;return"string"==typeof u.datumCode&&"WGS84"!==u.datumCode&&(u.datumCode=u.datumCode.toLowerCase()),u}var l=function(t){var e=new g(t);return e.output()},c=1,f=/\s/,h=/[A-Za-z]/,d=/[A-Za-z84_]/,p=/[,\]]/,m=/[\d\.E\-\+]/;function g(t){if("string"!=typeof t)throw new Error("not a string");this.text=t.trim(),this.level=0,this.place=0,this.root=null,this.stack=[],this.currentObject=null,this.state=c}function y(t,e,n){Array.isArray(e)&&(n.unshift(e),e=null);var r=e?{}:t,i=n.reduce((function(t,e){return v(e,t),t}),r);e&&(t[e]=i)}function v(t,e){if(Array.isArray(t)){var n=t.shift();if("PARAMETER"===n&&(n=t.shift()),1===t.length)return Array.isArray(t[0])?(e[n]={},void v(t[0],e[n])):void(e[n]=t[0]);if(t.length)if("TOWGS84"!==n){if("AXIS"===n)return n in e||(e[n]=[]),void e[n].push(t);var r;switch(Array.isArray(n)||(e[n]={}),n){case"UNIT":case"PRIMEM":case"VERT_DATUM":return e[n]={name:t[0].toLowerCase(),convert:t[1]},void(3===t.length&&v(t[2],e[n]));case"SPHEROID":case"ELLIPSOID":return e[n]={name:t[0],a:t[1],rf:t[2]},void(4===t.length&&v(t[3],e[n]));case"EDATUM":case"ENGINEERINGDATUM":case"LOCAL_DATUM":case"DATUM":case"VERT_CS":case"VERTCRS":case"VERTICALCRS":return t[0]=["name",t[0]],void y(e,n,t);case"COMPD_CS":case"COMPOUNDCRS":case"FITTED_CS":case"PROJECTEDCRS":case"PROJCRS":case"GEOGCS":case"GEOCCS":case"PROJCS":case"LOCAL_CS":case"GEODCRS":case"GEODETICCRS":case"GEODETICDATUM":case"ENGCRS":case"ENGINEERINGCRS":return t[0]=["name",t[0]],y(e,n,t),void(e[n].type=n);default:for(r=-1;++r<t.length;)if(!Array.isArray(t[r]))return v(t,e[n]);return y(e,n,t)}}else e[n]=t;else e[n]=!0}else e[t]=!0}g.prototype.readCharicter=function(){var t=this.text[this.place++];if(4!==this.state)for(;f.test(t);){if(this.place>=this.text.length)return;t=this.text[this.place++]}switch(this.state){case c:return this.neutral(t);case 2:return this.keyword(t);case 4:return this.quoted(t);case 5:return this.afterquote(t);case 3:return this.number(t);case-1:return}},g.prototype.afterquote=function(t){if('"'===t)return this.word+='"',void(this.state=4);if(p.test(t))return this.word=this.word.trim(),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in afterquote yet, index '+this.place)},g.prototype.afterItem=function(t){return","===t?(null!==this.word&&this.currentObject.push(this.word),this.word=null,void(this.state=c)):"]"===t?(this.level--,null!==this.word&&(this.currentObject.push(this.word),this.word=null),this.state=c,this.currentObject=this.stack.pop(),void(this.currentObject||(this.state=-1))):void 0},g.prototype.number=function(t){if(!m.test(t)){if(p.test(t))return this.word=parseFloat(this.word),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in number yet, index '+this.place)}this.word+=t},g.prototype.quoted=function(t){'"'!==t?this.word+=t:this.state=5},g.prototype.keyword=function(t){if(d.test(t))this.word+=t;else{if("["===t){var e=[];return e.push(this.word),this.level++,null===this.root?this.root=e:this.currentObject.push(e),this.stack.push(this.currentObject),this.currentObject=e,void(this.state=c)}if(!p.test(t))throw new Error("havn't handled \""+t+'" in keyword yet, index '+this.place);this.afterItem(t)}},g.prototype.neutral=function(t){if(h.test(t))return this.word=t,void(this.state=2);if('"'===t)return this.word="",void(this.state=4);if(m.test(t))return this.word=t,void(this.state=3);if(!p.test(t))throw new Error("havn't handled \""+t+'" in neutral yet, index '+this.place);this.afterItem(t)},g.prototype.output=function(){for(;this.place<this.text.length;)this.readCharicter();if(-1===this.state)return this.root;throw new Error('unable to parse string "'+this.text+'". State is '+this.state)};var x=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];function _(t){return.017453292519943295*t}function b(t){for(var e=Object.keys(t),n=0,r=e.length;n<r;++n){var i=e[n];-1!==x.indexOf(i)&&w(t[i]),"object"==typeof t[i]&&b(t[i])}}function w(t){if(t.AUTHORITY){var e=Object.keys(t.AUTHORITY)[0];e&&e in t.AUTHORITY&&(t.title=e+":"+t.AUTHORITY[e])}if("GEOGCS"===t.type?t.projName="longlat":"LOCAL_CS"===t.type?(t.projName="identity",t.local=!0):"object"==typeof t.PROJECTION?t.projName=Object.keys(t.PROJECTION)[0]:t.projName=t.PROJECTION,t.AXIS){for(var n="",r=0,i=t.AXIS.length;r<i;++r){var o=[t.AXIS[r][0].toLowerCase(),t.AXIS[r][1].toLowerCase()];-1!==o[0].indexOf("north")||("y"===o[0]||"lat"===o[0])&&"north"===o[1]?n+="n":-1!==o[0].indexOf("south")||("y"===o[0]||"lat"===o[0])&&"south"===o[1]?n+="s":-1!==o[0].indexOf("east")||("x"===o[0]||"lon"===o[0])&&"east"===o[1]?n+="e":-1===o[0].indexOf("west")&&("x"!==o[0]&&"lon"!==o[0]||"west"!==o[1])||(n+="w")}2===n.length&&(n+="u"),3===n.length&&(t.axis=n)}t.UNIT&&(t.units=t.UNIT.name.toLowerCase(),"metre"===t.units&&(t.units="meter"),t.UNIT.convert&&("GEOGCS"===t.type?t.DATUM&&t.DATUM.SPHEROID&&(t.to_meter=t.UNIT.convert*t.DATUM.SPHEROID.a):t.to_meter=t.UNIT.convert));var a=t.GEOGCS;function s(e){return e*(t.to_meter||1)}"GEOGCS"===t.type&&(a=t),a&&(a.DATUM?t.datumCode=a.DATUM.name.toLowerCase():t.datumCode=a.name.toLowerCase(),"d_"===t.datumCode.slice(0,2)&&(t.datumCode=t.datumCode.slice(2)),"new_zealand_1949"===t.datumCode&&(t.datumCode="nzgd49"),"wgs_1984"!==t.datumCode&&"world_geodetic_system_1984"!==t.datumCode||("Mercator_Auxiliary_Sphere"===t.PROJECTION&&(t.sphere=!0),t.datumCode="wgs84"),"belge_1972"===t.datumCode&&(t.datumCode="rnb72"),a.DATUM&&a.DATUM.SPHEROID&&(t.ellps=a.DATUM.SPHEROID.name.replace("_19","").replace(/[Cc]larke\_18/,"clrk"),"international"===t.ellps.toLowerCase().slice(0,13)&&(t.ellps="intl"),t.a=a.DATUM.SPHEROID.a,t.rf=parseFloat(a.DATUM.SPHEROID.rf,10)),a.DATUM&&a.DATUM.TOWGS84&&(t.datum_params=a.DATUM.TOWGS84),~t.datumCode.indexOf("osgb_1936")&&(t.datumCode="osgb36"),~t.datumCode.indexOf("osni_1952")&&(t.datumCode="osni52"),(~t.datumCode.indexOf("tm65")||~t.datumCode.indexOf("geodetic_datum_of_1965"))&&(t.datumCode="ire65"),"ch1903+"===t.datumCode&&(t.datumCode="ch1903"),~t.datumCode.indexOf("israel")&&(t.datumCode="isr93")),t.b&&!isFinite(t.b)&&(t.b=t.a);[["standard_parallel_1","Standard_Parallel_1"],["standard_parallel_1","Latitude of 1st standard parallel"],["standard_parallel_2","Standard_Parallel_2"],["standard_parallel_2","Latitude of 2nd standard parallel"],["false_easting","False_Easting"],["false_easting","False easting"],["false-easting","Easting at false origin"],["false_northing","False_Northing"],["false_northing","False northing"],["false_northing","Northing at false origin"],["central_meridian","Central_Meridian"],["central_meridian","Longitude of natural origin"],["central_meridian","Longitude of false origin"],["latitude_of_origin","Latitude_Of_Origin"],["latitude_of_origin","Central_Parallel"],["latitude_of_origin","Latitude of natural origin"],["latitude_of_origin","Latitude of false origin"],["scale_factor","Scale_Factor"],["k0","scale_factor"],["latitude_of_center","Latitude_Of_Center"],["latitude_of_center","Latitude_of_center"],["lat0","latitude_of_center",_],["longitude_of_center","Longitude_Of_Center"],["longitude_of_center","Longitude_of_center"],["longc","longitude_of_center",_],["x0","false_easting",s],["y0","false_northing",s],["long0","central_meridian",_],["lat0","latitude_of_origin",_],["lat0","standard_parallel_1",_],["lat1","standard_parallel_1",_],["lat2","standard_parallel_2",_],["azimuth","Azimuth"],["alpha","azimuth",_],["srsCode","name"]].forEach((function(e){return n=t,i=(r=e)[0],o=r[1],void(!(i in n)&&o in n&&(n[i]=n[o],3===r.length&&(n[i]=r[2](n[i]))));var n,r,i,o})),t.long0||!t.longc||"Albers_Conic_Equal_Area"!==t.projName&&"Lambert_Azimuthal_Equal_Area"!==t.projName||(t.long0=t.longc),t.lat_ts||!t.lat1||"Stereographic_South_Pole"!==t.projName&&"Polar Stereographic (variant B)"!==t.projName?!t.lat_ts&&t.lat0&&"Polar_Stereographic"===t.projName&&(t.lat_ts=t.lat0,t.lat0=_(t.lat0>0?90:-90)):(t.lat0=_(t.lat1>0?90:-90),t.lat_ts=t.lat1)}function M(t){var e=l(t),n=e[0],r={};return v(e,r),b(r),r[n]}function A(t){var e=this;if(2===arguments.length){var n=arguments[1];"string"==typeof n?"+"===n.charAt(0)?A[t]=u(arguments[1]):A[t]=M(arguments[1]):A[t]=n}else if(1===arguments.length){if(Array.isArray(t))return t.map((function(t){Array.isArray(t)?A.apply(e,t):A(t)}));if("string"==typeof t){if(t in A)return A[t]}else"EPSG"in t?A["EPSG:"+t.EPSG]=t:"ESRI"in t?A["ESRI:"+t.ESRI]=t:"IAU2000"in t?A["IAU2000:"+t.IAU2000]=t:console.log(t);return}}!function(t){t("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),t("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),t("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");for(var e=1;e<=60;++e)t("EPSG:"+(32600+e),"+proj=utm +zone="+e+" +datum=WGS84 +units=m"),t("EPSG:"+(32700+e),"+proj=utm +zone="+e+" +south +datum=WGS84 +units=m");t.WGS84=t["EPSG:4326"],t["EPSG:3785"]=t["EPSG:3857"],t.GOOGLE=t["EPSG:3857"],t["EPSG:900913"]=t["EPSG:3857"],t["EPSG:102113"]=t["EPSG:3857"]}(A);var T=A;var E=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];var C=["3857","900913","3785","102113"];var k=function(t){if(!function(t){return"string"==typeof t}(t))return t;if(function(t){return t in T}(t))return T[t];if(function(t){return E.some((function(e){return t.indexOf(e)>-1}))}(t)){var e=M(t);if(function(t){var e=s(t,"authority");if(e){var n=s(e,"epsg");return n&&C.indexOf(n)>-1}}(e))return T["EPSG:3857"];var n=function(t){var e=s(t,"extension");if(e)return s(e,"proj4")}(e);return n?u(n):e}return function(t){return"+"===t[0]}(t)?u(t):void 0};function S(t,e){var n,r;if(t=t||{},!e)return t;for(r in e)void 0!==(n=e[r])&&(t[r]=n);return t}var O=n(2286),P=n(2848),L=[O.default,P.default],R={},I=[];function D(t,e){var n=I.length;return t.names?(I[n]=t,t.names.forEach((function(t){R[t.toLowerCase()]=n})),this):(console.log(e),!0)}var N={start:function(){L.forEach(D)},add:D,get:function(t){if(!t)return!1;var e=t.toLowerCase();return void 0!==R[e]&&I[R[e]]?I[R[e]]:void 0}},F={MERIT:{a:6378137,rf:298.257,ellipseName:"MERIT 1983"},SGS85:{a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"},GRS80:{a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"},IAU76:{a:6378140,rf:298.257,ellipseName:"IAU 1976"},airy:{a:6377563.396,b:6356256.91,ellipseName:"Airy 1830"},APL4:{a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"},NWL9D:{a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"},mod_airy:{a:6377340.189,b:6356034.446,ellipseName:"Modified Airy"},andrae:{a:6377104.43,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"},aust_SA:{a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"},GRS67:{a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"},bessel:{a:6377397.155,rf:299.1528128,ellipseName:"Bessel 1841"},bess_nam:{a:6377483.865,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"},clrk66:{a:6378206.4,b:6356583.8,ellipseName:"Clarke 1866"},clrk80:{a:6378249.145,rf:293.4663,ellipseName:"Clarke 1880 mod."},clrk80ign:{a:6378249.2,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"},clrk58:{a:6378293.645208759,rf:294.2606763692654,ellipseName:"Clarke 1858"},CPM:{a:6375738.7,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"},delmbr:{a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"},engelis:{a:6378136.05,rf:298.2566,ellipseName:"Engelis 1985"},evrst30:{a:6377276.345,rf:300.8017,ellipseName:"Everest 1830"},evrst48:{a:6377304.063,rf:300.8017,ellipseName:"Everest 1948"},evrst56:{a:6377301.243,rf:300.8017,ellipseName:"Everest 1956"},evrst69:{a:6377295.664,rf:300.8017,ellipseName:"Everest 1969"},evrstSS:{a:6377298.556,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"},fschr60:{a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"},fschr60m:{a:6378155,rf:298.3,ellipseName:"Fischer 1960"},fschr68:{a:6378150,rf:298.3,ellipseName:"Fischer 1968"},helmert:{a:6378200,rf:298.3,ellipseName:"Helmert 1906"},hough:{a:6378270,rf:297,ellipseName:"Hough"},intl:{a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"},kaula:{a:6378163,rf:298.24,ellipseName:"Kaula 1961"},lerch:{a:6378139,rf:298.257,ellipseName:"Lerch 1979"},mprts:{a:6397300,rf:191,ellipseName:"Maupertius 1738"},new_intl:{a:6378157.5,b:6356772.2,ellipseName:"New International 1967"},plessis:{a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"},krass:{a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"},SEasia:{a:6378155,b:6356773.3205,ellipseName:"Southeast Asia"},walbeck:{a:6376896,b:6355834.8467,ellipseName:"Walbeck"},WGS60:{a:6378165,rf:298.3,ellipseName:"WGS 60"},WGS66:{a:6378145,rf:298.25,ellipseName:"WGS 66"},WGS7:{a:6378135,rf:298.26,ellipseName:"WGS 72"}},j=F.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};F.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};var z={wgs84:{towgs84:"0,0,0",ellipse:"WGS84",datumName:"WGS84"},ch1903:{towgs84:"674.374,15.056,405.346",ellipse:"bessel",datumName:"swiss"},ggrs87:{towgs84:"-199.87,74.79,246.62",ellipse:"GRS80",datumName:"Greek_Geodetic_Reference_System_1987"},nad83:{towgs84:"0,0,0",ellipse:"GRS80",datumName:"North_American_Datum_1983"},nad27:{nadgrids:"@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",ellipse:"clrk66",datumName:"North_American_Datum_1927"},potsdam:{towgs84:"598.1,73.7,418.2,0.202,0.045,-2.455,6.7",ellipse:"bessel",datumName:"Potsdam Rauenberg 1950 DHDN"},carthage:{towgs84:"-263.0,6.0,431.0",ellipse:"clark80",datumName:"Carthage 1934 Tunisia"},hermannskogel:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Hermannskogel"},mgi:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Militar-Geographische Institut"},osni52:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"airy",datumName:"Irish National"},ire65:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"mod_airy",datumName:"Ireland 1965"},rassadiran:{towgs84:"-133.63,-157.5,-158.62",ellipse:"intl",datumName:"Rassadiran"},nzgd49:{towgs84:"59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",ellipse:"intl",datumName:"New Zealand Geodetic Datum 1949"},osgb36:{towgs84:"446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",ellipse:"airy",datumName:"Ordnance Survey of Great Britain 1936"},s_jtsk:{towgs84:"589,76,480",ellipse:"bessel",datumName:"S-JTSK (Ferro)"},beduaram:{towgs84:"-106,-87,188",ellipse:"clrk80",datumName:"Beduaram"},gunung_segara:{towgs84:"-403,684,41",ellipse:"bessel",datumName:"Gunung Segara Jakarta"},rnb72:{towgs84:"106.869,-52.2978,103.724,-0.33657,0.456955,-1.84218,1",ellipse:"intl",datumName:"Reseau National Belge 1972"}};for(var B in z){var V=z[B];z[V.datumName]=V}var q=z;var G=function(t,e,n,i,o,a,s){var u={};return u.datum_type=void 0===t||"none"===t?r.A1:r.xK,e&&(u.datum_params=e.map(parseFloat),0===u.datum_params[0]&&0===u.datum_params[1]&&0===u.datum_params[2]||(u.datum_type=r.a8),u.datum_params.length>3&&(0===u.datum_params[3]&&0===u.datum_params[4]&&0===u.datum_params[5]&&0===u.datum_params[6]||(u.datum_type=r.Y$,u.datum_params[3]*=r._3,u.datum_params[4]*=r._3,u.datum_params[5]*=r._3,u.datum_params[6]=u.datum_params[6]/1e6+1))),s&&(u.datum_type=r.G9,u.grids=s),u.a=n,u.b=i,u.es=o,u.ep2=a,u},U={};function H(t){if(0===t.length)return null;var e="@"===t[0];return e&&(t=t.slice(1)),"null"===t?{name:"null",mandatory:!e,grid:null,isNull:!0}:{name:t,mandatory:!e,grid:U[t]||null,isNull:!1}}function W(t){return t/3600*Math.PI/180}function X(t,e,n){return String.fromCharCode.apply(null,new Uint8Array(t.buffer.slice(e,n)))}function K(t){return t.map((function(t){return[W(t.longitudeShift),W(t.latitudeShift)]}))}function Q(t,e,n){return{name:X(t,e+8,e+16).trim(),parent:X(t,e+24,e+24+8).trim(),lowerLatitude:t.getFloat64(e+72,n),upperLatitude:t.getFloat64(e+88,n),lowerLongitude:t.getFloat64(e+104,n),upperLongitude:t.getFloat64(e+120,n),latitudeInterval:t.getFloat64(e+136,n),longitudeInterval:t.getFloat64(e+152,n),gridNodeCount:t.getInt32(e+168,n)}}function Y(t,e,n,r){for(var i=e+176,o=[],a=0;a<n.gridNodeCount;a++){var s={latitudeShift:t.getFloat32(i+16*a,r),longitudeShift:t.getFloat32(i+16*a+4,r),latitudeAccuracy:t.getFloat32(i+16*a+8,r),longitudeAccuracy:t.getFloat32(i+16*a+12,r)};o.push(s)}return o}function $(t,e){if(!(this instanceof $))return new $(t);e=e||function(t){if(t)throw t};var n=k(t);if("object"==typeof n){var i=$.projections.get(n.projName);if(i){if(n.datumCode&&"none"!==n.datumCode){var o=s(q,n.datumCode);o&&(n.datum_params=n.datum_params||(o.towgs84?o.towgs84.split(","):null),n.ellps=o.ellipse,n.datumName=o.datumName?o.datumName:n.datumCode)}n.k0=n.k0||1,n.axis=n.axis||"enu",n.ellps=n.ellps||"wgs84",n.lat1=n.lat1||n.lat0;var a,u,l,c,f,h,d,p=function(t,e,n,i,o){if(!t){var a=s(F,i);a||(a=j),t=a.a,e=a.b,n=a.rf}return n&&!e&&(e=(1-1/n)*t),(0===n||Math.abs(t-e)<r.H0)&&(o=!0,e=t),{a:t,b:e,rf:n,sphere:o}}(n.a,n.b,n.rf,n.ellps,n.sphere),m=(a=p.a,u=p.b,p.rf,l=n.R_A,h=((c=a*a)-(f=u*u))/c,d=0,l?(c=(a*=1-h*(r.bA+h*(r.Q1+h*r.ej)))*a,h=0):d=Math.sqrt(h),{es:h,e:d,ep2:(c-f)/f}),g=function(t){return void 0===t?null:t.split(",").map(H)}(n.nadgrids),y=n.datum||G(n.datumCode,n.datum_params,p.a,p.b,m.es,m.ep2,g);S(this,n),S(this,i),this.a=p.a,this.b=p.b,this.rf=p.rf,this.sphere=p.sphere,this.es=m.es,this.e=m.e,this.ep2=m.ep2,this.datum=y,this.init(),e(null,this)}else e("Could not get projection name from: "+t)}else e("Could not parse to valid json: "+t)}$.projections=N,$.projections.start();var Z=$,J=n(9160),tt=n(737);function et(t){return t===r.a8||t===r.Y$}function nt(t,e,n){if(null===t.grids||0===t.grids.length)return console.log("Grid shift grids not found"),-1;var i={x:-n.x,y:n.y},o={x:Number.NaN,y:Number.NaN},a=[];t:for(var s=0;s<t.grids.length;s++){var u=t.grids[s];if(a.push(u.name),u.isNull){o=i;break}if(u.mandatory,null!==u.grid)for(var l=u.grid.subgrids,c=0,f=l.length;c<f;c++){var h=l[c],d=(Math.abs(h.del[1])+Math.abs(h.del[0]))/1e4,p=h.ll[0]-d,m=h.ll[1]-d,g=h.ll[0]+(h.lim[0]-1)*h.del[0]+d,y=h.ll[1]+(h.lim[1]-1)*h.del[1]+d;if(!(m>i.y||p>i.x||y<i.y||g<i.x)&&(o=rt(i,e,h),!isNaN(o.x)))break t}else if(u.mandatory)return console.log("Unable to find mandatory grid '"+u.name+"'"),-1}return isNaN(o.x)?(console.log("Failed to find a grid shift table for location '"+-i.x*r.dX+" "+i.y*r.dX+" tried: '"+a+"'"),-1):(n.x=-o.x,n.y=o.y,0)}function rt(t,e,n){var r={x:Number.NaN,y:Number.NaN};if(isNaN(t.x))return r;var i={x:t.x,y:t.y};i.x-=n.ll[0],i.y-=n.ll[1],i.x=(0,tt.A)(i.x-Math.PI)+Math.PI;var o=it(i,n);if(e){if(isNaN(o.x))return r;o.x=i.x-o.x,o.y=i.y-o.y;var a,s,u=9;do{if(s=it(o,n),isNaN(s.x)){console.log("Inverse grid shift iteration failed, presumably at grid edge. Using first approximation.");break}a={x:i.x-(s.x+o.x),y:i.y-(s.y+o.y)},o.x+=a.x,o.y+=a.y}while(u--&&Math.abs(a.x)>1e-12&&Math.abs(a.y)>1e-12);if(u<0)return console.log("Inverse grid shift iterator failed to converge."),r;r.x=(0,tt.A)(o.x+n.ll[0]),r.y=o.y+n.ll[1]}else isNaN(o.x)||(r.x=t.x+o.x,r.y=t.y+o.y);return r}function it(t,e){var n,r={x:t.x/e.del[0],y:t.y/e.del[1]},i=Math.floor(r.x),o=Math.floor(r.y),a=r.x-1*i,s=r.y-1*o,u={x:Number.NaN,y:Number.NaN};if(i<0||i>=e.lim[0])return u;if(o<0||o>=e.lim[1])return u;n=o*e.lim[0]+i;var l=e.cvs[n][0],c=e.cvs[n][1];n++;var f=e.cvs[n][0],h=e.cvs[n][1];n+=e.lim[0];var d=e.cvs[n][0],p=e.cvs[n][1];n--;var m=e.cvs[n][0],g=e.cvs[n][1],y=a*s,v=a*(1-s),x=(1-a)*(1-s),_=(1-a)*s;return u.x=x*l+v*f+_*m+y*d,u.y=x*c+v*h+_*g+y*p,u}function ot(t,e,n){var r,i,o,a=n.x,s=n.y,u=n.z||0,l={};for(o=0;o<3;o++)if(!e||2!==o||void 0!==n.z)switch(0===o?(r=a,i=-1!=="ew".indexOf(t.axis[o])?"x":"y"):1===o?(r=s,i=-1!=="ns".indexOf(t.axis[o])?"y":"x"):(r=u,i="z"),t.axis[o]){case"e":case"n":l[i]=r;break;case"w":case"s":l[i]=-r;break;case"u":void 0!==n[i]&&(l.z=r);break;case"d":void 0!==n[i]&&(l.z=-r);break;default:return null}return l}function at(t){var e={x:t[0],y:t[1]};return t.length>2&&(e.z=t[2]),t.length>3&&(e.m=t[3]),e}function st(t){if("function"==typeof Number.isFinite){if(Number.isFinite(t))return;throw new TypeError("coordinates must be finite numbers")}if("number"!=typeof t||t!=t||!isFinite(t))throw new TypeError("coordinates must be finite numbers")}function ut(t,e,n,i){var o,a=void 0!==(n=Array.isArray(n)?at(n):{x:n.x,y:n.y,z:n.z,m:n.m}).z;if(function(t){st(t.x),st(t.y)}(n),t.datum&&e.datum&&function(t,e){return(t.datum.datum_type===r.a8||t.datum.datum_type===r.Y$||t.datum.datum_type===r.G9)&&"WGS84"!==e.datumCode||(e.datum.datum_type===r.a8||e.datum.datum_type===r.Y$||e.datum.datum_type===r.G9)&&"WGS84"!==t.datumCode}(t,e)&&(n=ut(t,o=new Z("WGS84"),n,i),t=o),i&&"enu"!==t.axis&&(n=ot(t,!1,n)),"longlat"===t.projName)n={x:n.x*r.zq,y:n.y*r.zq,z:n.z||0};else if(t.to_meter&&(n={x:n.x*t.to_meter,y:n.y*t.to_meter,z:n.z||0}),!(n=t.inverse(n)))return;if(t.from_greenwich&&(n.x+=t.from_greenwich),n=function(t,e,n){if((0,J.OI)(t,e))return n;if(t.datum_type===r.A1||e.datum_type===r.A1)return n;var i=t.a,o=t.es;if(t.datum_type===r.G9){if(0!==nt(t,!1,n))return;i=r.bv,o=r.gS}var a=e.a,s=e.b,u=e.es;if(e.datum_type===r.G9&&(a=r.bv,s=r.zp,u=r.gS),o===u&&i===a&&!et(t.datum_type)&&!et(e.datum_type))return n;if(n=(0,J.jX)(n,o,i),et(t.datum_type)&&(n=(0,J.mj)(n,t.datum_type,t.datum_params)),et(e.datum_type)&&(n=(0,J.Fs)(n,e.datum_type,e.datum_params)),n=(0,J.Rw)(n,u,a,s),e.datum_type===r.G9&&0!==nt(e,!0,n))return;return n}(t.datum,e.datum,n),n)return e.from_greenwich&&(n={x:n.x-e.from_greenwich,y:n.y,z:n.z||0}),"longlat"===e.projName?n={x:n.x*r.dX,y:n.y*r.dX,z:n.z||0}:(n=e.forward(n),e.to_meter&&(n={x:n.x/e.to_meter,y:n.y/e.to_meter,z:n.z||0})),i&&"enu"!==e.axis?ot(e,!0,n):(n&&!a&&delete n.z,n)}var lt=Z("WGS84");function ct(t,e,n,r){var i,o,a;return Array.isArray(n)?(i=ut(t,e,n,r)||{x:NaN,y:NaN},n.length>2?void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name?"number"==typeof i.z?[i.x,i.y,i.z].concat(n.slice(3)):[i.x,i.y,n[2]].concat(n.slice(3)):[i.x,i.y].concat(n.slice(2)):[i.x,i.y]):(o=ut(t,e,n,r),2===(a=Object.keys(n)).length||a.forEach((function(r){if(void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name){if("x"===r||"y"===r||"z"===r)return}else if("x"===r||"y"===r)return;o[r]=n[r]})),o)}function ft(t){return t instanceof Z?t:t.oProj?t.oProj:Z(t)}var ht=function(t,e,n){t=ft(t);var r,i=!1;return void 0===e?(e=t,t=lt,i=!0):(void 0!==e.x||Array.isArray(e))&&(n=e,e=t,t=lt,i=!0),e=ft(e),n?ct(t,e,n):(r={forward:function(n,r){return ct(t,e,n,r)},inverse:function(n,r){return ct(e,t,n,r)}},i&&(r.oProj=e),r)},dt="AJSAJS",pt="AFAFAF",mt=65,gt=73,yt=79,vt=86,xt=90,_t={forward:bt,inverse:function(t){var e=Tt(kt(t.toUpperCase()));if(e.lat&&e.lon)return[e.lon,e.lat,e.lon,e.lat];return[e.left,e.bottom,e.right,e.top]},toPoint:wt};function bt(t,e){return e=e||5,function(t,e){var n="00000"+t.easting,r="00000"+t.northing;return t.zoneNumber+t.zoneLetter+(d=t.easting,p=t.northing,m=t.zoneNumber,g=Ct(m),y=Math.floor(d/1e5),v=Math.floor(p/1e5)%20,i=y,o=v,a=g,s=a-1,u=dt.charCodeAt(s),l=pt.charCodeAt(s),c=u+i-1,f=l+o,h=!1,c>xt&&(c=c-xt+mt-1,h=!0),(c===gt||u<gt&&c>gt||(c>gt||u<gt)&&h)&&c++,(c===yt||u<yt&&c>yt||(c>yt||u<yt)&&h)&&++c===gt&&c++,c>xt&&(c=c-xt+mt-1),f>vt?(f=f-vt+mt-1,h=!0):h=!1,(f===gt||l<gt&&f>gt||(f>gt||l<gt)&&h)&&f++,(f===yt||l<yt&&f>yt||(f>yt||l<yt)&&h)&&++f===gt&&f++,f>vt&&(f=f-vt+mt-1),String.fromCharCode(c)+String.fromCharCode(f))+n.substr(n.length-5,e)+r.substr(r.length-5,e);var i,o,a,s,u,l,c,f,h;var d,p,m,g,y,v}(function(t){var e,n,r,i,o,a,s,u,l=t.lat,c=t.lon,f=6378137,h=.00669438,d=.9996,p=Mt(l),m=Mt(c);u=Math.floor((c+180)/6)+1,180===c&&(u=60);l>=56&&l<64&&c>=3&&c<12&&(u=32);l>=72&&l<84&&(c>=0&&c<9?u=31:c>=9&&c<21?u=33:c>=21&&c<33?u=35:c>=33&&c<42&&(u=37));s=Mt(6*(u-1)-180+3),e=h/(1-h),n=f/Math.sqrt(1-h*Math.sin(p)*Math.sin(p)),r=Math.tan(p)*Math.tan(p),i=e*Math.cos(p)*Math.cos(p),o=Math.cos(p)*(m-s),a=f*((1-h/4-3*h*h/64-5*h*h*h/256)*p-(3*h/8+3*h*h/32+45*h*h*h/1024)*Math.sin(2*p)+(15*h*h/256+45*h*h*h/1024)*Math.sin(4*p)-35*h*h*h/3072*Math.sin(6*p));var g=d*n*(o+(1-r+i)*o*o*o/6+(5-18*r+r*r+72*i-58*e)*o*o*o*o*o/120)+5e5,y=d*(a+n*Math.tan(p)*(o*o/2+(5-r+9*i+4*i*i)*o*o*o*o/24+(61-58*r+r*r+600*i-330*e)*o*o*o*o*o*o/720));l<0&&(y+=1e7);return{northing:Math.round(y),easting:Math.round(g),zoneNumber:u,zoneLetter:Et(l)}}({lat:t[1],lon:t[0]}),e)}function wt(t){var e=Tt(kt(t.toUpperCase()));return e.lat&&e.lon?[e.lon,e.lat]:[(e.left+e.right)/2,(e.top+e.bottom)/2]}function Mt(t){return t*(Math.PI/180)}function At(t){return t/Math.PI*180}function Tt(t){var e=t.northing,n=t.easting,r=t.zoneLetter,i=t.zoneNumber;if(i<0||i>60)return null;var o,a,s,u,l,c,f,h,d,p=.9996,m=6378137,g=.00669438,y=(1-Math.sqrt(.99330562))/(1+Math.sqrt(.99330562)),v=n-5e5,x=e;r<"N"&&(x-=1e7),f=6*(i-1)-180+3,o=.006739496752268451,d=(h=x/p/6367449.145945056)+(3*y/2-27*y*y*y/32)*Math.sin(2*h)+(21*y*y/16-55*y*y*y*y/32)*Math.sin(4*h)+151*y*y*y/96*Math.sin(6*h),a=m/Math.sqrt(1-g*Math.sin(d)*Math.sin(d)),s=Math.tan(d)*Math.tan(d),u=o*Math.cos(d)*Math.cos(d),l=.99330562*m/Math.pow(1-g*Math.sin(d)*Math.sin(d),1.5),c=v/(a*p);var _=d-a*Math.tan(d)/l*(c*c/2-(5+3*s+10*u-4*u*u-9*o)*c*c*c*c/24+(61+90*s+298*u+45*s*s-1.6983531815716497-3*u*u)*c*c*c*c*c*c/720);_=At(_);var b,w=(c-(1+2*s+u)*c*c*c/6+(5-2*u+28*s-3*u*u+8*o+24*s*s)*c*c*c*c*c/120)/Math.cos(d);if(w=f+At(w),t.accuracy){var M=Tt({northing:t.northing+t.accuracy,easting:t.easting+t.accuracy,zoneLetter:t.zoneLetter,zoneNumber:t.zoneNumber});b={top:M.lat,right:M.lon,bottom:_,left:w}}else b={lat:_,lon:w};return b}function Et(t){var e="Z";return 84>=t&&t>=72?e="X":72>t&&t>=64?e="W":64>t&&t>=56?e="V":56>t&&t>=48?e="U":48>t&&t>=40?e="T":40>t&&t>=32?e="S":32>t&&t>=24?e="R":24>t&&t>=16?e="Q":16>t&&t>=8?e="P":8>t&&t>=0?e="N":0>t&&t>=-8?e="M":-8>t&&t>=-16?e="L":-16>t&&t>=-24?e="K":-24>t&&t>=-32?e="J":-32>t&&t>=-40?e="H":-40>t&&t>=-48?e="G":-48>t&&t>=-56?e="F":-56>t&&t>=-64?e="E":-64>t&&t>=-72?e="D":-72>t&&t>=-80&&(e="C"),e}function Ct(t){var e=t%6;return 0===e&&(e=6),e}function kt(t){if(t&&0===t.length)throw"MGRSPoint coverting from nothing";for(var e,n=t.length,r=null,i="",o=0;!/[A-Z]/.test(e=t.charAt(o));){if(o>=2)throw"MGRSPoint bad conversion from: "+t;i+=e,o++}var a=parseInt(i,10);if(0===o||o+3>n)throw"MGRSPoint bad conversion from: "+t;var s=t.charAt(o++);if(s<="A"||"B"===s||"Y"===s||s>="Z"||"I"===s||"O"===s)throw"MGRSPoint zone letter "+s+" not handled: "+t;r=t.substring(o,o+=2);for(var u=Ct(a),l=function(t,e){var n=dt.charCodeAt(e-1),r=1e5,i=!1;for(;n!==t.charCodeAt(0);){if(++n===gt&&n++,n===yt&&n++,n>xt){if(i)throw"Bad character: "+t;n=mt,i=!0}r+=1e5}return r}(r.charAt(0),u),c=function(t,e){if(t>"V")throw"MGRSPoint given invalid Northing "+t;var n=pt.charCodeAt(e-1),r=0,i=!1;for(;n!==t.charCodeAt(0);){if(++n===gt&&n++,n===yt&&n++,n>vt){if(i)throw"Bad character: "+t;n=mt,i=!0}r+=1e5}return r}(r.charAt(1),u);c<St(s);)c+=2e6;var f=n-o;if(f%2!=0)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"+t;var h,d,p,m=f/2,g=0,y=0;return m>0&&(h=1e5/Math.pow(10,m),d=t.substring(o,o+m),g=parseFloat(d)*h,p=t.substring(o+m),y=parseFloat(p)*h),{easting:g+l,northing:y+c,zoneLetter:s,zoneNumber:a,accuracy:h}}function St(t){var e;switch(t){case"C":e=11e5;break;case"D":e=2e6;break;case"E":e=28e5;break;case"F":e=37e5;break;case"G":e=46e5;break;case"H":e=55e5;break;case"J":e=64e5;break;case"K":e=73e5;break;case"L":e=82e5;break;case"M":e=91e5;break;case"N":e=0;break;case"P":e=8e5;break;case"Q":e=17e5;break;case"R":e=26e5;break;case"S":e=35e5;break;case"T":e=44e5;break;case"U":e=53e5;break;case"V":e=62e5;break;case"W":e=7e6;break;case"X":e=79e5;break;default:e=-1}if(e>=0)return e;throw"Invalid zone letter: "+t}function Ot(t,e,n){if(!(this instanceof Ot))return new Ot(t,e,n);if(Array.isArray(t))this.x=t[0],this.y=t[1],this.z=t[2]||0;else if("object"==typeof t)this.x=t.x,this.y=t.y,this.z=t.z||0;else if("string"==typeof t&&void 0===e){var r=t.split(",");this.x=parseFloat(r[0],10),this.y=parseFloat(r[1],10),this.z=parseFloat(r[2],10)||0}else this.x=t,this.y=e,this.z=n||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}Ot.fromMGRS=function(t){return new Ot(wt(t))},Ot.prototype.toMGRS=function(t){return bt([this.x,this.y],t)};var Pt=Ot,Lt=n(5602),Rt=n(994),It=n(6748),Dt=n(865),Nt=n(688),Ft=n(988),jt=n(7475),zt=n(9269),Bt=n(6507),Vt=n(529),qt=n(7406),Gt=n(5458),Ut=n(9462),Ht=n(4101),Wt=n(4256),Xt=n(2169),Kt=n(6407),Qt=n(5157),Yt=n(9006),$t=n(5967),Zt=n(7968),Jt=n(3211),te=n(8980),ee=n(8181),ne=n(5722),re=n(1295),ie=n(4876),oe=n(7127),ae=n(469),se=n(7129),ue=n(5789);ht.defaultDatum="WGS84",ht.Proj=Z,ht.WGS84=new ht.Proj("WGS84"),ht.Point=Pt,ht.toPoint=at,ht.defs=T,ht.nadgrid=function(t,e){var n=new DataView(e),r=function(t){var e=t.getInt32(8,!1);if(11===e)return!1;e=t.getInt32(8,!0),11!==e&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian");return!0}(n),i=function(t,e){return{nFields:t.getInt32(8,e),nSubgridFields:t.getInt32(24,e),nSubgrids:t.getInt32(40,e),shiftType:X(t,56,64).trim(),fromSemiMajorAxis:t.getFloat64(120,e),fromSemiMinorAxis:t.getFloat64(136,e),toSemiMajorAxis:t.getFloat64(152,e),toSemiMinorAxis:t.getFloat64(168,e)}}(n,r),o=function(t,e,n){for(var r=176,i=[],o=0;o<e.nSubgrids;o++){var a=Q(t,r,n),s=Y(t,r,a,n),u=Math.round(1+(a.upperLongitude-a.lowerLongitude)/a.longitudeInterval),l=Math.round(1+(a.upperLatitude-a.lowerLatitude)/a.latitudeInterval);i.push({ll:[W(a.lowerLongitude),W(a.lowerLatitude)],del:[W(a.longitudeInterval),W(a.latitudeInterval)],lim:[u,l],count:a.gridNodeCount,cvs:K(s)}),r+=176+16*a.gridNodeCount}return i}(n,i,r),a={header:i,subgrids:o};return U[t]=a,a},ht.transform=ut,ht.mgrs=_t,ht.version="__VERSION__",function(t){t.Proj.projections.add(Lt.default),t.Proj.projections.add(Rt.default),t.Proj.projections.add(It.default),t.Proj.projections.add(Dt.default),t.Proj.projections.add(Nt.default),t.Proj.projections.add(Ft.default),t.Proj.projections.add(jt.default),t.Proj.projections.add(zt.default),t.Proj.projections.add(Bt.default),t.Proj.projections.add(Vt.default),t.Proj.projections.add(qt.default),t.Proj.projections.add(Gt.default),t.Proj.projections.add(Ut.default),t.Proj.projections.add(Ht.default),t.Proj.projections.add(Wt.default),t.Proj.projections.add(Xt.default),t.Proj.projections.add(Kt.default),t.Proj.projections.add(Qt.default),t.Proj.projections.add(Yt.default),t.Proj.projections.add($t.default),t.Proj.projections.add(Zt.default),t.Proj.projections.add(Jt.default),t.Proj.projections.add(te.default),t.Proj.projections.add(ee.default),t.Proj.projections.add(ne.default),t.Proj.projections.add(re.default),t.Proj.projections.add(ie.default),t.Proj.projections.add(oe.default),t.Proj.projections.add(ae.default),t.Proj.projections.add(se.default),t.Proj.projections.add(ue.default)}(ht);var le=ht},5458:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return h},phi1z:function(){return f}});var r=n(444),i=n(7200),o=n(737),a=n(8609),s=n(2556);function u(){Math.abs(this.lat1+this.lat2)<s.H0||(this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e3=Math.sqrt(this.es),this.sin_po=Math.sin(this.lat1),this.cos_po=Math.cos(this.lat1),this.t1=this.sin_po,this.con=this.sin_po,this.ms1=(0,r.A)(this.e3,this.sin_po,this.cos_po),this.qs1=(0,i.A)(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat2),this.cos_po=Math.cos(this.lat2),this.t2=this.sin_po,this.ms2=(0,r.A)(this.e3,this.sin_po,this.cos_po),this.qs2=(0,i.A)(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat0),this.cos_po=Math.cos(this.lat0),this.t3=this.sin_po,this.qs0=(0,i.A)(this.e3,this.sin_po),Math.abs(this.lat1-this.lat2)>s.H0?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function l(t){var e=t.x,n=t.y;this.sin_phi=Math.sin(n),this.cos_phi=Math.cos(n);var r=(0,i.A)(this.e3,this.sin_phi),a=this.a*Math.sqrt(this.c-this.ns0*r)/this.ns0,s=this.ns0*(0,o.A)(e-this.long0),u=a*Math.sin(s)+this.x0,l=this.rh-a*Math.cos(s)+this.y0;return t.x=u,t.y=l,t}function c(t){var e,n,r,i,a,s;return t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns0>=0?(e=Math.sqrt(t.x*t.x+t.y*t.y),r=1):(e=-Math.sqrt(t.x*t.x+t.y*t.y),r=-1),i=0,0!==e&&(i=Math.atan2(r*t.x,r*t.y)),r=e*this.ns0/this.a,this.sphere?s=Math.asin((this.c-r*r)/(2*this.ns0)):(n=(this.c-r*r)/this.ns0,s=this.phi1z(this.e3,n)),a=(0,o.A)(i/this.ns0+this.long0),t.x=a,t.y=s,t}function f(t,e){var n,r,i,o,u=(0,a.A)(.5*e);if(t<s.H0)return u;for(var l=t*t,c=1;c<=25;c++)if(u+=o=.5*(i=1-(r=t*(n=Math.sin(u)))*r)*i/Math.cos(u)*(e/(1-l)-n/i+.5/t*Math.log((1-r)/(1+r))),Math.abs(o)<=1e-7)return u;return null}var h=["Albers_Conic_Equal_Area","Albers","aea"];e.default={init:u,forward:l,inverse:c,names:h,phi1z:f}},8980:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(737),i=n(2556),o=n(4037),a=n(8193),s=n(9686),u=n(7711),l=n(2060),c=n(7973),f=n(8609),h=n(6592);function d(){this.sin_p12=Math.sin(this.lat0),this.cos_p12=Math.cos(this.lat0)}function p(t){var e,n,f,h,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k,S,O,P=t.x,L=t.y,R=Math.sin(t.y),I=Math.cos(t.y),D=(0,r.A)(P-this.long0);return this.sphere?Math.abs(this.sin_p12-1)<=i.H0?(t.x=this.x0+this.a*(i.sK-L)*Math.sin(D),t.y=this.y0-this.a*(i.sK-L)*Math.cos(D),t):Math.abs(this.sin_p12+1)<=i.H0?(t.x=this.x0+this.a*(i.sK+L)*Math.sin(D),t.y=this.y0+this.a*(i.sK+L)*Math.cos(D),t):(E=this.sin_p12*R+this.cos_p12*I*Math.cos(D),T=(A=Math.acos(E))?A/Math.sin(A):1,t.x=this.x0+this.a*T*I*Math.sin(D),t.y=this.y0+this.a*T*(this.cos_p12*R-this.sin_p12*I*Math.cos(D)),t):(e=(0,a.A)(this.es),n=(0,s.A)(this.es),f=(0,u.A)(this.es),h=(0,l.A)(this.es),Math.abs(this.sin_p12-1)<=i.H0?(d=this.a*(0,o.A)(e,n,f,h,i.sK),p=this.a*(0,o.A)(e,n,f,h,L),t.x=this.x0+(d-p)*Math.sin(D),t.y=this.y0-(d-p)*Math.cos(D),t):Math.abs(this.sin_p12+1)<=i.H0?(d=this.a*(0,o.A)(e,n,f,h,i.sK),p=this.a*(0,o.A)(e,n,f,h,L),t.x=this.x0+(d+p)*Math.sin(D),t.y=this.y0+(d+p)*Math.cos(D),t):(m=R/I,g=(0,c.A)(this.a,this.e,this.sin_p12),y=(0,c.A)(this.a,this.e,R),v=Math.atan((1-this.es)*m+this.es*g*this.sin_p12/(y*I)),C=0===(x=Math.atan2(Math.sin(D),this.cos_p12*Math.tan(v)-this.sin_p12*Math.cos(D)))?Math.asin(this.cos_p12*Math.sin(v)-this.sin_p12*Math.cos(v)):Math.abs(Math.abs(x)-Math.PI)<=i.H0?-Math.asin(this.cos_p12*Math.sin(v)-this.sin_p12*Math.cos(v)):Math.asin(Math.sin(D)*Math.cos(v)/Math.sin(x)),_=this.e*this.sin_p12/Math.sqrt(1-this.es),A=g*C*(1-(k=C*C)*(M=(b=this.e*this.cos_p12*Math.cos(x)/Math.sqrt(1-this.es))*b)*(1-M)/6+(S=k*C)/8*(w=_*b)*(1-2*M)+(O=S*C)/120*(M*(4-7*M)-3*_*_*(1-7*M))-O*C/48*w),t.x=this.x0+A*Math.sin(x),t.y=this.y0+A*Math.cos(x),t))}function m(t){var e,n,d,p,m,g,y,v,x,_,b,w,M,A,T,E,C,k,S,O,P,L,R,I;if(t.x-=this.x0,t.y-=this.y0,this.sphere){if((e=Math.sqrt(t.x*t.x+t.y*t.y))>2*i.sK*this.a)return;return n=e/this.a,d=Math.sin(n),p=Math.cos(n),m=this.long0,Math.abs(e)<=i.H0?g=this.lat0:(g=(0,f.A)(p*this.sin_p12+t.y*d*this.cos_p12/e),y=Math.abs(this.lat0)-i.sK,m=Math.abs(y)<=i.H0?this.lat0>=0?(0,r.A)(this.long0+Math.atan2(t.x,-t.y)):(0,r.A)(this.long0-Math.atan2(-t.x,t.y)):(0,r.A)(this.long0+Math.atan2(t.x*d,e*this.cos_p12*p-t.y*this.sin_p12*d))),t.x=m,t.y=g,t}return v=(0,a.A)(this.es),x=(0,s.A)(this.es),_=(0,u.A)(this.es),b=(0,l.A)(this.es),Math.abs(this.sin_p12-1)<=i.H0?(M=(w=this.a*(0,o.A)(v,x,_,b,i.sK))-(e=Math.sqrt(t.x*t.x+t.y*t.y)),g=(0,h.A)(M/this.a,v,x,_,b),m=(0,r.A)(this.long0+Math.atan2(t.x,-1*t.y)),t.x=m,t.y=g,t):Math.abs(this.sin_p12+1)<=i.H0?(w=this.a*(0,o.A)(v,x,_,b,i.sK),M=(e=Math.sqrt(t.x*t.x+t.y*t.y))-w,g=(0,h.A)(M/this.a,v,x,_,b),m=(0,r.A)(this.long0+Math.atan2(t.x,t.y)),t.x=m,t.y=g,t):(e=Math.sqrt(t.x*t.x+t.y*t.y),E=Math.atan2(t.x,t.y),A=(0,c.A)(this.a,this.e,this.sin_p12),C=Math.cos(E),S=-(k=this.e*this.cos_p12*C)*k/(1-this.es),O=3*this.es*(1-S)*this.sin_p12*this.cos_p12*C/(1-this.es),R=1-S*(L=(P=e/A)-S*(1+S)*Math.pow(P,3)/6-O*(1+3*S)*Math.pow(P,4)/24)*L/2-P*L*L*L/6,T=Math.asin(this.sin_p12*Math.cos(L)+this.cos_p12*Math.sin(L)*C),m=(0,r.A)(this.long0+Math.asin(Math.sin(E)*Math.sin(L)/Math.cos(T))),I=Math.sin(T),g=Math.atan2((I-this.es*R*this.sin_p12)*Math.tan(T),I*(1-this.es)),t.x=m,t.y=g,t)}var g=["Azimuthal_Equidistant","aeqd"];e.default={init:d,forward:p,inverse:m,names:g}},5789:function(t,e,n){"use strict";n.r(e),n.d(e,{init:function(){return f},names:function(){return g}});var r=n(5473),i=n(737),o=n(1708),a=n(6366),s=n(3220),u=n(2092),l=n(2556),c=1e-10;function f(){var t;if(this.phi1=this.lat1,Math.abs(this.phi1)<c)throw new Error;this.es?(this.en=(0,a.A)(this.es),this.m1=(0,u.A)(this.phi1,this.am1=Math.sin(this.phi1),t=Math.cos(this.phi1),this.en),this.am1=t/(Math.sqrt(1-this.es*this.am1*this.am1)*this.am1),this.inverse=d,this.forward=h):(Math.abs(this.phi1)+c>=l.sK?this.cphi1=0:this.cphi1=1/Math.tan(this.phi1),this.inverse=m,this.forward=p)}function h(t){var e,n,r,o=(0,i.A)(t.x-(this.long0||0)),a=t.y;return e=this.am1+this.m1-(0,u.A)(a,n=Math.sin(a),r=Math.cos(a),this.en),n=r*o/(e*Math.sqrt(1-this.es*n*n)),t.x=e*Math.sin(n),t.y=this.am1-e*Math.cos(n),t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function d(t){var e,n,a,u;if(t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a,n=(0,o.A)(t.x,t.y=this.am1-t.y),u=(0,s.A)(this.am1+this.m1-n,this.es,this.en),(e=Math.abs(u))<l.sK)e=Math.sin(u),a=n*Math.atan2(t.x,t.y)*Math.sqrt(1-this.es*e*e)/Math.cos(u);else{if(!(Math.abs(e-l.sK)<=c))throw new Error;a=0}return t.x=(0,i.A)(a+(this.long0||0)),t.y=(0,r.A)(u),t}function p(t){var e,n,r=(0,i.A)(t.x-(this.long0||0)),o=t.y;return n=this.cphi1+this.phi1-o,Math.abs(n)>c?(t.x=n*Math.sin(e=r*Math.cos(o)/n),t.y=this.cphi1-n*Math.cos(e)):t.x=t.y=0,t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function m(t){var e,n;t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a;var a=(0,o.A)(t.x,t.y=this.cphi1-t.y);if(n=this.cphi1+this.phi1-a,Math.abs(n)>l.sK)throw new Error;return e=Math.abs(Math.abs(n)-l.sK)<=c?0:a*Math.atan2(t.x,t.y)/Math.cos(n),t.x=(0,i.A)(e+(this.long0||0)),t.y=(0,r.A)(n),t}var g=["bonne","Bonne (Werner lat_1=90)"];e.default={init:f,names:g}},529:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(4037),i=n(8193),o=n(9686),a=n(7711),s=n(2060),u=n(7973),l=n(737),c=n(5473),f=n(6592),h=n(2556);function d(){this.sphere||(this.e0=(0,i.A)(this.es),this.e1=(0,o.A)(this.es),this.e2=(0,a.A)(this.es),this.e3=(0,s.A)(this.es),this.ml0=this.a*(0,r.A)(this.e0,this.e1,this.e2,this.e3,this.lat0))}function p(t){var e,n,i=t.x,o=t.y;if(i=(0,l.A)(i-this.long0),this.sphere)e=this.a*Math.asin(Math.cos(o)*Math.sin(i)),n=this.a*(Math.atan2(Math.tan(o),Math.cos(i))-this.lat0);else{var a=Math.sin(o),s=Math.cos(o),c=(0,u.A)(this.a,this.e,a),f=Math.tan(o)*Math.tan(o),h=i*Math.cos(o),d=h*h,p=this.es*s*s/(1-this.es);e=c*h*(1-d*f*(1/6-(8-f+8*p)*d/120)),n=this.a*(0,r.A)(this.e0,this.e1,this.e2,this.e3,o)-this.ml0+c*a/s*d*(.5+(5-f+6*p)*d/24)}return t.x=e+this.x0,t.y=n+this.y0,t}function m(t){t.x-=this.x0,t.y-=this.y0;var e,n,r=t.x/this.a,i=t.y/this.a;if(this.sphere){var o=i+this.lat0;e=Math.asin(Math.sin(o)*Math.cos(r)),n=Math.atan2(Math.tan(r),Math.cos(o))}else{var a=this.ml0/this.a+i,s=(0,f.A)(a,this.e0,this.e1,this.e2,this.e3);if(Math.abs(Math.abs(s)-h.sK)<=h.H0)return t.x=this.long0,t.y=h.sK,i<0&&(t.y*=-1),t;var d=(0,u.A)(this.a,this.e,Math.sin(s)),p=d*d*d/this.a/this.a*(1-this.es),m=Math.pow(Math.tan(s),2),g=r*this.a/d,y=g*g;e=s-d*Math.tan(s)/p*g*g*(.5-(1+3*m)*g*g/24),n=g*(1-y*(m/3+(1+3*m)*m*y/15))/Math.cos(s)}return t.x=(0,l.A)(n+this.long0),t.y=(0,c.A)(e),t}var g=["Cassini","Cassini_Soldner","cass"];e.default={init:d,forward:p,inverse:m,names:g}},4101:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return f},forward:function(){return u},init:function(){return s},inverse:function(){return l},names:function(){return c}});var r=n(737),i=n(7200),o=n(444),a=n(2556);function s(){this.sphere||(this.k0=(0,o.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function u(t){var e,n,o=t.x,a=t.y,s=(0,r.A)(o-this.long0);if(this.sphere)e=this.x0+this.a*s*Math.cos(this.lat_ts),n=this.y0+this.a*Math.sin(a)/Math.cos(this.lat_ts);else{var u=(0,i.A)(this.e,Math.sin(a));e=this.x0+this.a*this.k0*s,n=this.y0+this.a*u*.5/this.k0}return t.x=e,t.y=n,t}function l(t){var e,n;return t.x-=this.x0,t.y-=this.y0,this.sphere?(e=(0,r.A)(this.long0+t.x/this.a/Math.cos(this.lat_ts)),n=Math.asin(t.y/this.a*Math.cos(this.lat_ts))):(n=function(t,e){var n=1-(1-t*t)/(2*t)*Math.log((1-t)/(1+t));if(Math.abs(Math.abs(e)-n)<1e-6)return e<0?-1*a.sK:a.sK;for(var r,i,o,s,u=Math.asin(.5*e),l=0;l<30;l++)if(i=Math.sin(u),o=Math.cos(u),s=t*i,u+=r=Math.pow(1-s*s,2)/(2*o)*(e/(1-t*t)-i/(1-s*s)+.5/t*Math.log((1-s)/(1+s))),Math.abs(r)<=1e-10)return u;return NaN}(this.e,2*t.y*this.k0/this.a),e=(0,r.A)(this.long0+t.x/(this.a*this.k0))),t.x=e,t.y=n,t}var c=["cea"],f={init:s,forward:u,inverse:l,names:c}},4256:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},names:function(){return u}});var r=n(737),i=n(5473);function o(){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=Math.cos(this.lat_ts)}function a(t){var e=t.x,n=t.y,o=(0,r.A)(e-this.long0),a=(0,i.A)(n-this.lat0);return t.x=this.x0+this.a*o*this.rc,t.y=this.y0+this.a*a,t}function s(t){var e=t.x,n=t.y;return t.x=(0,r.A)(this.long0+(e-this.x0)/(this.a*this.rc)),t.y=(0,i.A)(this.lat0+(n-this.y0)/this.a),t}var u=["Equirectangular","Equidistant_Cylindrical","eqc"];e.default={init:o,forward:a,inverse:s,names:u}},7968:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(8193),i=n(9686),o=n(7711),a=n(2060),s=n(444),u=n(4037),l=n(737),c=n(5473),f=n(6592),h=n(2556);function d(){Math.abs(this.lat1+this.lat2)<h.H0||(this.lat2=this.lat2||this.lat1,this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=(0,r.A)(this.es),this.e1=(0,i.A)(this.es),this.e2=(0,o.A)(this.es),this.e3=(0,a.A)(this.es),this.sinphi=Math.sin(this.lat1),this.cosphi=Math.cos(this.lat1),this.ms1=(0,s.A)(this.e,this.sinphi,this.cosphi),this.ml1=(0,u.A)(this.e0,this.e1,this.e2,this.e3,this.lat1),Math.abs(this.lat1-this.lat2)<h.H0?this.ns=this.sinphi:(this.sinphi=Math.sin(this.lat2),this.cosphi=Math.cos(this.lat2),this.ms2=(0,s.A)(this.e,this.sinphi,this.cosphi),this.ml2=(0,u.A)(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=(0,u.A)(this.e0,this.e1,this.e2,this.e3,this.lat0),this.rh=this.a*(this.g-this.ml0))}function p(t){var e,n=t.x,r=t.y;if(this.sphere)e=this.a*(this.g-r);else{var i=(0,u.A)(this.e0,this.e1,this.e2,this.e3,r);e=this.a*(this.g-i)}var o=this.ns*(0,l.A)(n-this.long0),a=this.x0+e*Math.sin(o),s=this.y0+this.rh-e*Math.cos(o);return t.x=a,t.y=s,t}function m(t){var e,n,r,i;t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns>=0?(n=Math.sqrt(t.x*t.x+t.y*t.y),e=1):(n=-Math.sqrt(t.x*t.x+t.y*t.y),e=-1);var o=0;if(0!==n&&(o=Math.atan2(e*t.x,e*t.y)),this.sphere)return i=(0,l.A)(this.long0+o/this.ns),r=(0,c.A)(this.g-n/this.a),t.x=i,t.y=r,t;var a=this.g-n/this.a;return r=(0,f.A)(a,this.e0,this.e1,this.e2,this.e3),i=(0,l.A)(this.long0+o/this.ns),t.x=i,t.y=r,t}var g=["Equidistant_Conic","eqdc"];e.default={init:d,forward:p,inverse:m,names:g}},7129:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(737),i=1.340264,o=-.081106,a=893e-6,s=.003796,u=Math.sqrt(3)/2;function l(){this.es=0,this.long0=void 0!==this.long0?this.long0:0}function c(t){var e=(0,r.A)(t.x-this.long0),n=t.y,l=Math.asin(u*Math.sin(n)),c=l*l,f=c*c*c;return t.x=e*Math.cos(l)/(u*(i+3*o*c+f*(7*a+9*s*c))),t.y=l*(i+o*c+f*(a+s*c)),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function f(t){t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a;var e,n,l,c,f=t.y;for(c=0;c<12&&(f-=l=(f*(i+o*(e=f*f)+(n=e*e*e)*(a+s*e))-t.y)/(i+3*o*e+n*(7*a+9*s*e)),!(Math.abs(l)<1e-9));++c);return n=(e=f*f)*e*e,t.x=u*t.x*(i+3*o*e+n*(7*a+9*s*e))/Math.cos(f),t.y=Math.asin(Math.sin(f)/u),t.x=(0,r.A)(t.x+this.long0),t}var h=["eqearth","Equal Earth","Equal_Earth"];e.default={init:l,forward:c,inverse:f,names:h}},3667:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0}function o(t){var e=t.x,n=t.y,i=(0,r.A)(e-this.long0),o=this.x0+this.a*i*Math.cos(this.lat0),a=this.y0+this.a*n;return this.t1=o,this.t2=Math.cos(this.lat0),t.x=o,t.y=a,t}function a(t){t.x-=this.x0,t.y-=this.y0;var e=t.y/this.a,n=(0,r.A)(this.long0+t.x/(this.a*Math.cos(this.lat0)));t.x=n,t.y=e}var s=["equi"];e.default={init:i,forward:o,inverse:a,names:s}},994:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return m},forward:function(){return h},init:function(){return f},inverse:function(){return d},names:function(){return p}});var r=n(5602),i=n(3882),o=n(1708);function a(t){var e=Math.abs(t);return e=function(t){var e=1+t,n=e-1;return 0===n?t:t*Math.log(e)/n}(e*(1+e/((0,o.A)(1,e)+1))),t<0?-e:e}function s(t,e){for(var n,r=2*Math.cos(2*e),i=t.length-1,o=t[i],a=0;--i>=0;)n=r*o-a+t[i],a=o,o=n;return e+n*Math.sin(2*e)}var u=n(4885);function l(t,e,n){for(var r,o,a=Math.sin(e),s=Math.cos(e),l=(0,i.A)(n),c=(0,u.A)(n),f=2*s*c,h=-2*a*l,d=t.length-1,p=t[d],m=0,g=0,y=0;--d>=0;)r=g,o=m,p=f*(g=p)-r-h*(m=y)+t[d],y=h*g-o+f*m;return[(f=a*c)*p-(h=s*l)*y,f*y+h*p]}var c=n(737);function f(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&(r.default.init.apply(this),this.forward=r.default.forward,this.inverse=r.default.inverse),this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var t=this.es/(1+Math.sqrt(1-this.es)),e=t/(2-t),n=e;this.cgb[0]=e*(2+e*(-2/3+e*(e*(116/45+e*(26/45+e*(-2854/675)))-2))),this.cbg[0]=e*(e*(2/3+e*(4/3+e*(-82/45+e*(32/45+e*(4642/4725)))))-2),n*=e,this.cgb[1]=n*(7/3+e*(e*(-227/45+e*(2704/315+e*(2323/945)))-1.6)),this.cbg[1]=n*(5/3+e*(-16/15+e*(-13/9+e*(904/315+e*(-1522/945))))),n*=e,this.cgb[2]=n*(56/15+e*(-136/35+e*(-1262/105+e*(73814/2835)))),this.cbg[2]=n*(-26/15+e*(34/21+e*(1.6+e*(-12686/2835)))),n*=e,this.cgb[3]=n*(4279/630+e*(-332/35+e*(-399572/14175))),this.cbg[3]=n*(1237/630+e*(e*(-24832/14175)-2.4)),n*=e,this.cgb[4]=n*(4174/315+e*(-144838/6237)),this.cbg[4]=n*(-734/315+e*(109598/31185)),n*=e,this.cgb[5]=n*(601676/22275),this.cbg[5]=n*(444337/155925),n=Math.pow(e,2),this.Qn=this.k0/(1+e)*(1+n*(1/4+n*(1/64+n/256))),this.utg[0]=e*(e*(2/3+e*(-37/96+e*(1/360+e*(81/512+e*(-96199/604800)))))-.5),this.gtu[0]=e*(.5+e*(-2/3+e*(5/16+e*(41/180+e*(-127/288+e*(7891/37800)))))),this.utg[1]=n*(-1/48+e*(-1/15+e*(437/1440+e*(-46/105+e*(1118711/3870720))))),this.gtu[1]=n*(13/48+e*(e*(557/1440+e*(281/630+e*(-1983433/1935360)))-.6)),n*=e,this.utg[2]=n*(-17/480+e*(37/840+e*(209/4480+e*(-5569/90720)))),this.gtu[2]=n*(61/240+e*(-103/140+e*(15061/26880+e*(167603/181440)))),n*=e,this.utg[3]=n*(-4397/161280+e*(11/504+e*(830251/7257600))),this.gtu[3]=n*(49561/161280+e*(-179/168+e*(6601661/7257600))),n*=e,this.utg[4]=n*(-4583/161280+e*(108847/3991680)),this.gtu[4]=n*(34729/80640+e*(-3418889/1995840)),n*=e,this.utg[5]=n*(-20648693/638668800),this.gtu[5]=.6650675310896665*n;var i=s(this.cbg,this.lat0);this.Zb=-this.Qn*(i+function(t,e){for(var n,r=2*Math.cos(e),i=t.length-1,o=t[i],a=0;--i>=0;)n=r*o-a+t[i],a=o,o=n;return Math.sin(e)*n}(this.gtu,2*i))}function h(t){var e=(0,c.A)(t.x-this.long0),n=t.y;n=s(this.cbg,n);var r=Math.sin(n),i=Math.cos(n),u=Math.sin(e),f=Math.cos(e);n=Math.atan2(r,f*i),e=Math.atan2(u*i,(0,o.A)(r,i*f)),e=a(Math.tan(e));var h,d,p=l(this.gtu,2*n,2*e);return n+=p[0],e+=p[1],Math.abs(e)<=2.623395162778?(h=this.a*(this.Qn*e)+this.x0,d=this.a*(this.Qn*n+this.Zb)+this.y0):(h=1/0,d=1/0),t.x=h,t.y=d,t}function d(t){var e,n,r=(t.x-this.x0)*(1/this.a),a=(t.y-this.y0)*(1/this.a);if(a=(a-this.Zb)/this.Qn,r/=this.Qn,Math.abs(r)<=2.623395162778){var u=l(this.utg,2*a,2*r);a+=u[0],r+=u[1],r=Math.atan((0,i.A)(r));var f=Math.sin(a),h=Math.cos(a),d=Math.sin(r),p=Math.cos(r);a=Math.atan2(f*p,(0,o.A)(d,p*h)),r=Math.atan2(d,p*h),e=(0,c.A)(r+this.long0),n=s(this.cgb,a)}else e=1/0,n=1/0;return t.x=e,t.y=n,t}var p=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"],m={init:f,forward:h,inverse:d,names:p}},3246:function(t,e,n){"use strict";function r(t,e){return Math.pow((1-t)/(1+t),e)}n.r(e),n.d(e,{default:function(){return c},forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var i=n(2556),o=20;function a(){var t=Math.sin(this.lat0),e=Math.cos(this.lat0);e*=e,this.rc=Math.sqrt(1-this.es)/(1-this.es*t*t),this.C=Math.sqrt(1+this.es*e*e/(1-this.es)),this.phic0=Math.asin(t/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+i.Vj)/(Math.pow(Math.tan(.5*this.lat0+i.Vj),this.C)*r(this.e*t,this.ratexp))}function s(t){var e=t.x,n=t.y;return t.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*n+i.Vj),this.C)*r(this.e*Math.sin(n),this.ratexp))-i.sK,t.x=this.C*e,t}function u(t){for(var e=t.x/this.C,n=t.y,a=Math.pow(Math.tan(.5*n+i.Vj)/this.K,1/this.C),s=o;s>0&&(n=2*Math.atan(a*r(this.e*Math.sin(t.y),-.5*this.e))-i.sK,!(Math.abs(n-t.y)<1e-14));--s)t.y=n;return s?(t.x=e,t.y=n,t):null}var l=["gauss"],c={init:a,forward:s,inverse:u,names:l}},4876:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(9160);function i(){this.name="geocent"}function o(t){return(0,r.jX)(t,this.es,this.a)}function a(t){return(0,r.Rw)(t,this.es,this.a,this.b)}var s=["Geocentric","geocentric","geocent","Geocent"];e.default={init:i,forward:o,inverse:a,names:s}},469:function(t,e,n){"use strict";n.r(e),n.d(e,{init:function(){return i},names:function(){return o}});var r=n(1708);function i(){if(this.flip_axis="x"===this.sweep?1:0,this.h=Number(this.h),this.radius_g_1=this.h/this.a,this.radius_g_1<=0||this.radius_g_1>1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,0!==this.es){var t=1-this.es,e=1/t;this.radius_p=Math.sqrt(t),this.radius_p2=t,this.radius_p_inv2=e,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")}var o=["Geostationary Satellite View","Geostationary_Satellite","geos"];e.default={init:i,forward:function(t){var e,n,i,o,a=t.x,s=t.y;if(a-=this.long0,"ellipse"===this.shape){s=Math.atan(this.radius_p2*Math.tan(s));var u=this.radius_p/(0,r.A)(this.radius_p*Math.cos(s),Math.sin(s));if(n=u*Math.cos(a)*Math.cos(s),i=u*Math.sin(a)*Math.cos(s),o=u*Math.sin(s),(this.radius_g-n)*n-i*i-o*o*this.radius_p_inv2<0)return t.x=Number.NaN,t.y=Number.NaN,t;e=this.radius_g-n,this.flip_axis?(t.x=this.radius_g_1*Math.atan(i/(0,r.A)(o,e)),t.y=this.radius_g_1*Math.atan(o/e)):(t.x=this.radius_g_1*Math.atan(i/e),t.y=this.radius_g_1*Math.atan(o/(0,r.A)(i,e)))}else"sphere"===this.shape&&(e=Math.cos(s),n=Math.cos(a)*e,i=Math.sin(a)*e,o=Math.sin(s),e=this.radius_g-n,this.flip_axis?(t.x=this.radius_g_1*Math.atan(i/(0,r.A)(o,e)),t.y=this.radius_g_1*Math.atan(o/e)):(t.x=this.radius_g_1*Math.atan(i/e),t.y=this.radius_g_1*Math.atan(o/(0,r.A)(i,e))));return t.x=t.x*this.a,t.y=t.y*this.a,t},inverse:function(t){var e,n,i,o,a=-1,s=0,u=0;if(t.x=t.x/this.a,t.y=t.y/this.a,"ellipse"===this.shape){this.flip_axis?(u=Math.tan(t.y/this.radius_g_1),s=Math.tan(t.x/this.radius_g_1)*(0,r.A)(1,u)):(s=Math.tan(t.x/this.radius_g_1),u=Math.tan(t.y/this.radius_g_1)*(0,r.A)(1,s));var l=u/this.radius_p;if(e=s*s+l*l+a*a,(i=(n=2*this.radius_g*a)*n-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;o=(-n-Math.sqrt(i))/(2*e),a=this.radius_g+o*a,s*=o,u*=o,t.x=Math.atan2(s,a),t.y=Math.atan(u*Math.cos(t.x)/a),t.y=Math.atan(this.radius_p_inv2*Math.tan(t.y))}else if("sphere"===this.shape){if(this.flip_axis?(u=Math.tan(t.y/this.radius_g_1),s=Math.tan(t.x/this.radius_g_1)*Math.sqrt(1+u*u)):(s=Math.tan(t.x/this.radius_g_1),u=Math.tan(t.y/this.radius_g_1)*Math.sqrt(1+s*s)),e=s*s+u*u+a*a,(i=(n=2*this.radius_g*a)*n-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;o=(-n-Math.sqrt(i))/(2*e),a=this.radius_g+o*a,s*=o,u*=o,t.x=Math.atan2(s,a),t.y=Math.atan(u*Math.cos(t.x)/a)}return t.x=t.x+this.long0,t},names:o}},9462:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(8609),o=n(2556);function a(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0),this.infinity_dist=1e3*this.a,this.rc=1}function s(t){var e,n,i,a,s,u,l,c=t.x,f=t.y;return i=(0,r.A)(c-this.long0),e=Math.sin(f),n=Math.cos(f),a=Math.cos(i),(s=this.sin_p14*e+this.cos_p14*n*a)>0||Math.abs(s)<=o.H0?(u=this.x0+1*this.a*n*Math.sin(i)/s,l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*n*a)/s):(u=this.x0+this.infinity_dist*n*Math.sin(i),l=this.y0+this.infinity_dist*(this.cos_p14*e-this.sin_p14*n*a)),t.x=u,t.y=l,t}function u(t){var e,n,o,a,s,u;return t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,(e=Math.sqrt(t.x*t.x+t.y*t.y))?(a=Math.atan2(e,this.rc),n=Math.sin(a),o=Math.cos(a),u=(0,i.A)(o*this.sin_p14+t.y*n*this.cos_p14/e),s=Math.atan2(t.x*n,e*this.cos_p14*o-t.y*this.sin_p14*n),s=(0,r.A)(this.long0+s)):(u=this.phic0,s=0),t.x=s,t.y=u,t}var l=["gnom"];e.default={init:a,forward:s,inverse:u,names:l}},7041:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return h},forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(2556);function i(t,e,n){if(Math.abs(e)>r.sK)return Number.NaN;if(e===r.sK)return Number.POSITIVE_INFINITY;if(e===-1*r.sK)return Number.NEGATIVE_INFINITY;var i=t*n;return Math.log(Math.tan((r.sK+e)/2))+t*Math.log((1-i)/(1+i))/2}var o=n(3882),a=n(4885);function s(t,e){return 2*Math.atan(t*Math.exp(e))-r.sK}function u(){var t=this.b/this.a;this.e=Math.sqrt(1-t*t),this.lc=this.long0,this.rs=Math.sqrt(1+this.e*this.e*Math.pow(Math.cos(this.lat0),4)/(1-this.e*this.e));var e=Math.sin(this.lat0),n=Math.asin(e/this.rs),r=Math.sin(n);this.cp=i(0,n,r)-this.rs*i(this.e,this.lat0,e),this.n2=this.k0*this.a*Math.sqrt(1-this.e*this.e)/(1-this.e*this.e*e*e),this.xs=this.x0,this.ys=this.y0-this.n2*n,this.title||(this.title="Gauss Schreiber transverse mercator")}function l(t){var e=t.x,n=t.y,r=this.rs*(e-this.lc),s=this.cp+this.rs*i(this.e,n,Math.sin(n)),u=Math.asin(Math.sin(r)/(0,a.A)(s)),l=i(0,u,Math.sin(u));return t.x=this.xs+this.n2*l,t.y=this.ys+this.n2*Math.atan((0,o.A)(s)/Math.cos(r)),t}function c(t){var e=t.x,n=t.y,r=Math.atan((0,o.A)((e-this.xs)/this.n2)/Math.cos((n-this.ys)/this.n2)),u=Math.asin(Math.sin((n-this.ys)/this.n2)/(0,a.A)((e-this.xs)/this.n2)),l=i(0,u,Math.sin(u));return t.x=this.lc+r/this.rs,t.y=function(t,e){var n=s(1,e),r=0,i=0;do{r=n,i=t*Math.sin(r),n=s(Math.exp(t*Math.log((1+i)/(1-i))/2),e)}while(Math.abs(n-r)>1e-12);return n}(this.e,(l-this.cp)/this.rs),t}var f=["gstmerg","gstmerc"],h={init:u,forward:l,inverse:c,names:f}},6507:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){this.a=6377397.155,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.4334234309119251),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function o(t){var e,n,i,o,a,s,u,l=t.x,c=t.y,f=(0,r.A)(l-this.long0);return e=Math.pow((1+this.e*Math.sin(c))/(1-this.e*Math.sin(c)),this.alfa*this.e/2),n=2*(Math.atan(this.k*Math.pow(Math.tan(c/2+this.s45),this.alfa)/e)-this.s45),i=-f*this.alfa,o=Math.asin(Math.cos(this.ad)*Math.sin(n)+Math.sin(this.ad)*Math.cos(n)*Math.cos(i)),a=Math.asin(Math.cos(n)*Math.sin(i)/Math.cos(o)),s=this.n*a,u=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(o/2+this.s45),this.n),t.y=u*Math.cos(s)/1,t.x=u*Math.sin(s)/1,this.czech||(t.y*=-1,t.x*=-1),t}function a(t){var e,n,r,i,o,a,s,u=t.x;t.x=t.y,t.y=u,this.czech||(t.y*=-1,t.x*=-1),o=Math.sqrt(t.x*t.x+t.y*t.y),i=Math.atan2(t.y,t.x)/Math.sin(this.s0),r=2*(Math.atan(Math.pow(this.ro0/o,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),e=Math.asin(Math.cos(this.ad)*Math.sin(r)-Math.sin(this.ad)*Math.cos(r)*Math.cos(i)),n=Math.asin(Math.cos(r)*Math.sin(i)/Math.cos(e)),t.x=this.long0-n/this.alfa,a=e,s=0;var l=0;do{t.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(e/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(a))/(1-this.e*Math.sin(a)),this.e/2))-this.s45),Math.abs(a-t.y)<1e-10&&(s=1),a=t.y,l+=1}while(0===s&&l<15);return l>=15?null:t}var s=["Krovak","krovak"];e.default={init:i,forward:o,inverse:a,names:s}},7406:function(t,e,n){"use strict";n.r(e),n.d(e,{EQUIT:function(){return u},N_POLE:function(){return s},OBLIQ:function(){return l},S_POLE:function(){return a},forward:function(){return f},init:function(){return c},inverse:function(){return h},names:function(){return x}});var r=n(2556),i=n(7200),o=n(737),a=1,s=2,u=3,l=4;function c(){var t,e=Math.abs(this.lat0);if(Math.abs(e-r.sK)<r.H0?this.mode=this.lat0<0?this.S_POLE:this.N_POLE:Math.abs(e)<r.H0?this.mode=this.EQUIT:this.mode=this.OBLIQ,this.es>0)switch(this.qp=(0,i.A)(this.e,1),this.mmf=.5/(1-this.es),this.apa=function(t){var e,n=[];return n[0]=t*d,e=t*t,n[0]+=e*p,n[1]=e*g,e*=t,n[0]+=e*m,n[1]+=e*y,n[2]=e*v,n}(this.es),this.mode){case this.N_POLE:case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=(0,i.A)(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(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=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function f(t){var e,n,a,s,u,l,c,f,h,d,p=t.x,m=t.y;if(p=(0,o.A)(p-this.long0),this.sphere){if(u=Math.sin(m),d=Math.cos(m),a=Math.cos(p),this.mode===this.OBLIQ||this.mode===this.EQUIT){if((n=this.mode===this.EQUIT?1+d*a:1+this.sinph0*u+this.cosph0*d*a)<=r.H0)return null;e=(n=Math.sqrt(2/n))*d*Math.sin(p),n*=this.mode===this.EQUIT?u:this.cosph0*u-this.sinph0*d*a}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(a=-a),Math.abs(m+this.lat0)<r.H0)return null;n=r.Vj-.5*m,e=(n=2*(this.mode===this.S_POLE?Math.cos(n):Math.sin(n)))*Math.sin(p),n*=a}}else{switch(c=0,f=0,h=0,a=Math.cos(p),s=Math.sin(p),u=Math.sin(m),l=(0,i.A)(this.e,u),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(c=l/this.qp,f=Math.sqrt(1-c*c)),this.mode){case this.OBLIQ:h=1+this.sinb1*c+this.cosb1*f*a;break;case this.EQUIT:h=1+f*a;break;case this.N_POLE:h=r.sK+m,l=this.qp-l;break;case this.S_POLE:h=m-r.sK,l=this.qp+l}if(Math.abs(h)<r.H0)return null;switch(this.mode){case this.OBLIQ:case this.EQUIT:h=Math.sqrt(2/h),n=this.mode===this.OBLIQ?this.ymf*h*(this.cosb1*c-this.sinb1*f*a):(h=Math.sqrt(2/(1+f*a)))*c*this.ymf,e=this.xmf*h*f*s;break;case this.N_POLE:case this.S_POLE:l>=0?(e=(h=Math.sqrt(l))*s,n=a*(this.mode===this.S_POLE?h:-h)):e=n=0}}return t.x=this.a*e+this.x0,t.y=this.a*n+this.y0,t}function h(t){t.x-=this.x0,t.y-=this.y0;var e,n,i,a,s,u,l,c,f,h,d=t.x/this.a,p=t.y/this.a;if(this.sphere){var m,g=0,y=0;if((n=.5*(m=Math.sqrt(d*d+p*p)))>1)return null;switch(n=2*Math.asin(n),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(y=Math.sin(n),g=Math.cos(n)),this.mode){case this.EQUIT:n=Math.abs(m)<=r.H0?0:Math.asin(p*y/m),d*=y,p=g*m;break;case this.OBLIQ:n=Math.abs(m)<=r.H0?this.lat0:Math.asin(g*this.sinph0+p*y*this.cosph0/m),d*=y*this.cosph0,p=(g-Math.sin(n)*this.sinph0)*m;break;case this.N_POLE:p=-p,n=r.sK-n;break;case this.S_POLE:n-=r.sK}e=0!==p||this.mode!==this.EQUIT&&this.mode!==this.OBLIQ?Math.atan2(d,p):0}else{if(l=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(d/=this.dd,p*=this.dd,(u=Math.sqrt(d*d+p*p))<r.H0)return t.x=this.long0,t.y=this.lat0,t;a=2*Math.asin(.5*u/this.rq),i=Math.cos(a),d*=a=Math.sin(a),this.mode===this.OBLIQ?(l=i*this.sinb1+p*a*this.cosb1/u,s=this.qp*l,p=u*this.cosb1*i-p*this.sinb1*a):(l=p*a/u,s=this.qp*l,p=u*i)}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(p=-p),!(s=d*d+p*p))return t.x=this.long0,t.y=this.lat0,t;l=1-s/this.qp,this.mode===this.S_POLE&&(l=-l)}e=Math.atan2(d,p),c=Math.asin(l),f=this.apa,h=c+c,n=c+f[0]*Math.sin(h)+f[1]*Math.sin(h+h)+f[2]*Math.sin(h+h+h)}return t.x=(0,o.A)(this.long0+e),t.y=n,t}var d=.3333333333333333,p=.17222222222222222,m=.10257936507936508,g=.06388888888888888,y=.0664021164021164,v=.016415012942191543;var x=["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"];e.default={init:c,forward:f,inverse:h,names:x,S_POLE:a,N_POLE:s,EQUIT:u,OBLIQ:l}},9269:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(444),i=n(9967),o=n(4205),a=n(737),s=n(1793),u=n(2556);function l(){if(this.lat2||(this.lat2=this.lat1),this.k0||(this.k0=1),this.x0=this.x0||0,this.y0=this.y0||0,!(Math.abs(this.lat1+this.lat2)<u.H0)){var t=this.b/this.a;this.e=Math.sqrt(1-t*t);var e=Math.sin(this.lat1),n=Math.cos(this.lat1),o=(0,r.A)(this.e,e,n),a=(0,i.A)(this.e,this.lat1,e),s=Math.sin(this.lat2),l=Math.cos(this.lat2),c=(0,r.A)(this.e,s,l),f=(0,i.A)(this.e,this.lat2,s),h=(0,i.A)(this.e,this.lat0,Math.sin(this.lat0));Math.abs(this.lat1-this.lat2)>u.H0?this.ns=Math.log(o/c)/Math.log(a/f):this.ns=e,isNaN(this.ns)&&(this.ns=e),this.f0=o/(this.ns*Math.pow(a,this.ns)),this.rh=this.a*this.f0*Math.pow(h,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function c(t){var e=t.x,n=t.y;Math.abs(2*Math.abs(n)-Math.PI)<=u.H0&&(n=(0,o.A)(n)*(u.sK-2*u.H0));var r,s,l=Math.abs(Math.abs(n)-u.sK);if(l>u.H0)r=(0,i.A)(this.e,n,Math.sin(n)),s=this.a*this.f0*Math.pow(r,this.ns);else{if((l=n*this.ns)<=0)return null;s=0}var c=this.ns*(0,a.A)(e-this.long0);return t.x=this.k0*(s*Math.sin(c))+this.x0,t.y=this.k0*(this.rh-s*Math.cos(c))+this.y0,t}function f(t){var e,n,r,i,o,l=(t.x-this.x0)/this.k0,c=this.rh-(t.y-this.y0)/this.k0;this.ns>0?(e=Math.sqrt(l*l+c*c),n=1):(e=-Math.sqrt(l*l+c*c),n=-1);var f=0;if(0!==e&&(f=Math.atan2(n*l,n*c)),0!==e||this.ns>0){if(n=1/this.ns,r=Math.pow(e/(this.a*this.f0),n),-9999===(i=(0,s.A)(this.e,r)))return null}else i=-u.sK;return o=(0,a.A)(f/this.ns+this.long0),t.x=o,t.y=i,t}var h=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"];e.default={init:l,forward:c,inverse:f,names:h}},2848:function(t,e,n){"use strict";function r(){}function i(t){return t}n.r(e),n.d(e,{forward:function(){return i},init:function(){return r},inverse:function(){return i},names:function(){return o}});var o=["longlat","identity"];e.default={init:r,forward:i,inverse:i,names:o}},2286:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(444),i=n(737),o=n(9967),a=n(1793),s=n(2556);function u(){var t=this.b/this.a;this.es=1-t*t,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=(0,r.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function l(t){var e,n,r=t.x,a=t.y;if(a*s.dX>90&&a*s.dX<-90&&r*s.dX>180&&r*s.dX<-180)return null;if(Math.abs(Math.abs(a)-s.sK)<=s.H0)return null;if(this.sphere)e=this.x0+this.a*this.k0*(0,i.A)(r-this.long0),n=this.y0+this.a*this.k0*Math.log(Math.tan(s.Vj+.5*a));else{var u=Math.sin(a),l=(0,o.A)(this.e,a,u);e=this.x0+this.a*this.k0*(0,i.A)(r-this.long0),n=this.y0-this.a*this.k0*Math.log(l)}return t.x=e,t.y=n,t}function c(t){var e,n,r=t.x-this.x0,o=t.y-this.y0;if(this.sphere)n=s.sK-2*Math.atan(Math.exp(-o/(this.a*this.k0)));else{var u=Math.exp(-o/(this.a*this.k0));if(-9999===(n=(0,a.A)(this.e,u)))return null}return e=(0,i.A)(this.long0+r/(this.a*this.k0)),t.x=e,t.y=n,t}var f=["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"];e.default={init:u,forward:l,inverse:c,names:f}},5157:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return o},init:function(){return i},inverse:function(){return a},names:function(){return s}});var r=n(737);function i(){}function o(t){var e=t.x,n=t.y,i=(0,r.A)(e-this.long0),o=this.x0+this.a*i,a=this.y0+this.a*Math.log(Math.tan(Math.PI/4+n/2.5))*1.25;return t.x=o,t.y=a,t}function a(t){t.x-=this.x0,t.y-=this.y0;var e=(0,r.A)(this.long0+t.x/this.a),n=2.5*(Math.atan(Math.exp(.8*t.y/this.a))-Math.PI/4);return t.x=e,t.y=n,t}var s=["Miller_Cylindrical","mill"];e.default={init:i,forward:o,inverse:a,names:s}},5967:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},names:function(){return u}});var r=n(737),i=n(2556);function o(){}function a(t){for(var e=t.x,n=t.y,o=(0,r.A)(e-this.long0),a=n,s=Math.PI*Math.sin(n);;){var u=-(a+Math.sin(a)-s)/(1+Math.cos(a));if(a+=u,Math.abs(u)<i.H0)break}a/=2,Math.PI/2-Math.abs(n)<i.H0&&(o=0);var l=.900316316158*this.a*o*Math.cos(a)+this.x0,c=1.4142135623731*this.a*Math.sin(a)+this.y0;return t.x=l,t.y=c,t}function s(t){var e,n;t.x-=this.x0,t.y-=this.y0,n=t.y/(1.4142135623731*this.a),Math.abs(n)>.999999999999&&(n=.999999999999),e=Math.asin(n);var i=(0,r.A)(this.long0+t.x/(.900316316158*this.a*Math.cos(e)));i<-Math.PI&&(i=-Math.PI),i>Math.PI&&(i=Math.PI),n=(2*e+Math.sin(2*e))/Math.PI,Math.abs(n)>1&&(n=1);var o=Math.asin(n);return t.x=i,t.y=o,t}var u=["Mollweide","moll"];e.default={init:o,forward:a,inverse:s,names:u}},6407:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return a},init:function(){return o},inverse:function(){return s},iterations:function(){return i},names:function(){return u}});var r=n(2556),i=1;function o(){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}function a(t){var e,n=t.x,i=t.y-this.lat0,o=n-this.long0,a=i/r._3*1e-5,s=o,u=1,l=0;for(e=1;e<=10;e++)u*=a,l+=this.A[e]*u;var c,f=l,h=s,d=1,p=0,m=0,g=0;for(e=1;e<=6;e++)c=p*f+d*h,d=d*f-p*h,p=c,m=m+this.B_re[e]*d-this.B_im[e]*p,g=g+this.B_im[e]*d+this.B_re[e]*p;return t.x=g*this.a+this.x0,t.y=m*this.a+this.y0,t}function s(t){var e,n,i=t.x,o=t.y,a=i-this.x0,s=(o-this.y0)/this.a,u=a/this.a,l=1,c=0,f=0,h=0;for(e=1;e<=6;e++)n=c*s+l*u,l=l*s-c*u,c=n,f=f+this.C_re[e]*l-this.C_im[e]*c,h=h+this.C_im[e]*l+this.C_re[e]*c;for(var d=0;d<this.iterations;d++){var p,m=f,g=h,y=s,v=u;for(e=2;e<=6;e++)p=g*f+m*h,m=m*f-g*h,g=p,y+=(e-1)*(this.B_re[e]*m-this.B_im[e]*g),v+=(e-1)*(this.B_im[e]*m+this.B_re[e]*g);m=1,g=0;var x=this.B_re[1],_=this.B_im[1];for(e=2;e<=6;e++)p=g*f+m*h,m=m*f-g*h,g=p,x+=e*(this.B_re[e]*m-this.B_im[e]*g),_+=e*(this.B_im[e]*m+this.B_re[e]*g);var b=x*x+_*_;f=(y*x+v*_)/b,h=(v*x-y*_)/b}var w=f,M=h,A=1,T=0;for(e=1;e<=9;e++)A*=w,T+=this.D[e]*A;var E=this.lat0+T*r._3*1e5,C=this.long0+M;return t.x=C,t.y=E,t}var u=["New_Zealand_Map_Grid","nzmg"];e.default={init:o,forward:a,inverse:s,names:u}},7475:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return l},init:function(){return u},inverse:function(){return c},names:function(){return f}});var r=n(9967),i=n(737),o=n(1793),a=n(2556),s=1e-7;function u(){var t,e,n,o,u,l,c,f,h,d,p,m,g,y=0,v=0,x=0,_=0,b=0,w=0,M=0;this.no_off=(g="object"==typeof(m=this).PROJECTION?Object.keys(m.PROJECTION)[0]:m.PROJECTION,"no_uoff"in m||"no_off"in m||-1!==["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"].indexOf(g)),this.no_rot="no_rot"in this;var A=!1;"alpha"in this&&(A=!0);var T=!1;if("rectified_grid_angle"in this&&(T=!0),A&&(M=this.alpha),T&&(y=this.rectified_grid_angle*a.zq),A||T)v=this.longc;else if(x=this.long1,b=this.lat1,_=this.long2,w=this.lat2,Math.abs(b-w)<=s||(t=Math.abs(b))<=s||Math.abs(t-a.sK)<=s||Math.abs(Math.abs(this.lat0)-a.sK)<=s||Math.abs(Math.abs(w)-a.sK)<=s)throw new Error;var E=1-this.es;e=Math.sqrt(E),Math.abs(this.lat0)>a.H0?(f=Math.sin(this.lat0),n=Math.cos(this.lat0),t=1-this.es*f*f,this.B=n*n,this.B=Math.sqrt(1+this.es*this.B*this.B/E),this.A=this.B*this.k0*e/t,(u=(o=this.B*e/(n*Math.sqrt(t)))*o-1)<=0?u=0:(u=Math.sqrt(u),this.lat0<0&&(u=-u)),this.E=u+=o,this.E*=Math.pow((0,r.A)(this.e,this.lat0,f),this.B)):(this.B=1/e,this.A=this.k0,this.E=o=u=1),A||T?(A?(p=Math.asin(Math.sin(M)/o),T||(y=M)):(p=y,M=Math.asin(o*Math.sin(p))),this.lam0=v-Math.asin(.5*(u-1/u)*Math.tan(p))/this.B):(l=Math.pow((0,r.A)(this.e,b,Math.sin(b)),this.B),c=Math.pow((0,r.A)(this.e,w,Math.sin(w)),this.B),u=this.E/l,h=(c-l)/(c+l),d=((d=this.E*this.E)-c*l)/(d+c*l),(t=x-_)<-Math.pi?_-=a.JM:t>Math.pi&&(_+=a.JM),this.lam0=(0,i.A)(.5*(x+_)-Math.atan(d*Math.tan(.5*this.B*(x-_))/h)/this.B),p=Math.atan(2*Math.sin(this.B*(0,i.A)(x-this.lam0))/(u-1/u)),y=M=Math.asin(o*Math.sin(p))),this.singam=Math.sin(p),this.cosgam=Math.cos(p),this.sinrot=Math.sin(y),this.cosrot=Math.cos(y),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.A,this.B,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(o*o-1)/Math.cos(M))),this.lat0<0&&(this.u_0=-this.u_0)),u=.5*p,this.v_pole_n=this.ArB*Math.log(Math.tan(a.Vj-u)),this.v_pole_s=this.ArB*Math.log(Math.tan(a.Vj+u))}function l(t){var e,n,i,o,u,l,c,f,h={};if(t.x=t.x-this.lam0,Math.abs(Math.abs(t.y)-a.sK)>a.H0){if(e=.5*((u=this.E/Math.pow((0,r.A)(this.e,t.y,Math.sin(t.y)),this.B))-(l=1/u)),n=.5*(u+l),o=Math.sin(this.B*t.x),i=(e*this.singam-o*this.cosgam)/n,Math.abs(Math.abs(i)-1)<a.H0)throw new Error;f=.5*this.ArB*Math.log((1-i)/(1+i)),l=Math.cos(this.B*t.x),c=Math.abs(l)<s?this.A*t.x:this.ArB*Math.atan2(e*this.cosgam+o*this.singam,l)}else f=t.y>0?this.v_pole_n:this.v_pole_s,c=this.ArB*t.y;return this.no_rot?(h.x=c,h.y=f):(c-=this.u_0,h.x=f*this.cosrot+c*this.sinrot,h.y=c*this.cosrot-f*this.sinrot),h.x=this.a*h.x+this.x0,h.y=this.a*h.y+this.y0,h}function c(t){var e,n,r,i,s,u,l,c={};if(t.x=(t.x-this.x0)*(1/this.a),t.y=(t.y-this.y0)*(1/this.a),this.no_rot?(n=t.y,e=t.x):(n=t.x*this.cosrot-t.y*this.sinrot,e=t.y*this.cosrot+t.x*this.sinrot+this.u_0),i=.5*((r=Math.exp(-this.BrA*n))-1/r),s=.5*(r+1/r),l=((u=Math.sin(this.BrA*e))*this.cosgam+i*this.singam)/s,Math.abs(Math.abs(l)-1)<a.H0)c.x=0,c.y=l<0?-a.sK:a.sK;else{if(c.y=this.E/Math.sqrt((1+l)/(1-l)),c.y=(0,o.A)(this.e,Math.pow(c.y,1/this.B)),c.y===1/0)throw new Error;c.x=-this.rB*Math.atan2(i*this.cosgam-u*this.singam,Math.cos(this.BrA*e))}return c.x+=this.lam0,c}var f=["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Two_Point_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","Oblique_Mercator","omerc"];e.default={init:u,forward:l,inverse:c,names:f}},8181:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(8609),o=n(2556);function a(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function s(t){var e,n,i,a,s,u,l,c=t.x,f=t.y;return i=(0,r.A)(c-this.long0),e=Math.sin(f),n=Math.cos(f),a=Math.cos(i),((s=this.sin_p14*e+this.cos_p14*n*a)>0||Math.abs(s)<=o.H0)&&(u=1*this.a*n*Math.sin(i),l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*n*a)),t.x=u,t.y=l,t}function u(t){var e,n,a,s,u,l,c;return t.x-=this.x0,t.y-=this.y0,e=Math.sqrt(t.x*t.x+t.y*t.y),n=(0,i.A)(e/this.a),a=Math.sin(n),s=Math.cos(n),l=this.long0,Math.abs(e)<=o.H0?(c=this.lat0,t.x=l,t.y=c,t):(c=(0,i.A)(s*this.sin_p14+t.y*a*this.cos_p14/e),u=Math.abs(this.lat0)-o.sK,Math.abs(u)<=o.H0?(l=this.lat0>=0?(0,r.A)(this.long0+Math.atan2(t.x,-t.y)):(0,r.A)(this.long0-Math.atan2(-t.x,t.y)),t.x=l,t.y=c,t):(l=(0,r.A)(this.long0+Math.atan2(t.x*a,e*this.cos_p14*s-t.y*this.sin_p14*a)),t.x=l,t.y=c,t))}var l=["ortho"];e.default={init:a,forward:s,inverse:u,names:l}},2169:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return p},init:function(){return d},inverse:function(){return m},names:function(){return g}});var r=n(8193),i=n(9686),o=n(7711),a=n(2060),s=n(737),u=n(5473),l=n(4037),c=n(2556),f=n(7973),h=20;function d(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=(0,r.A)(this.es),this.e1=(0,i.A)(this.es),this.e2=(0,o.A)(this.es),this.e3=(0,a.A)(this.es),this.ml0=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,this.lat0)}function p(t){var e,n,r,i=t.x,o=t.y,a=(0,s.A)(i-this.long0);if(r=a*Math.sin(o),this.sphere)Math.abs(o)<=c.H0?(e=this.a*a,n=-1*this.a*this.lat0):(e=this.a*Math.sin(r)/Math.tan(o),n=this.a*((0,u.A)(o-this.lat0)+(1-Math.cos(r))/Math.tan(o)));else if(Math.abs(o)<=c.H0)e=this.a*a,n=-1*this.ml0;else{var h=(0,f.A)(this.a,this.e,Math.sin(o))/Math.tan(o);e=h*Math.sin(r),n=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,o)-this.ml0+h*(1-Math.cos(r))}return t.x=e+this.x0,t.y=n+this.y0,t}function m(t){var e,n,r,i,o,a,u,f,d;if(r=t.x-this.x0,i=t.y-this.y0,this.sphere)if(Math.abs(i+this.a*this.lat0)<=c.H0)e=(0,s.A)(r/this.a+this.long0),n=0;else{var p;for(a=this.lat0+i/this.a,u=r*r/this.a/this.a+a*a,f=a,o=h;o;--o)if(f+=d=-1*(a*(f*(p=Math.tan(f))+1)-f-.5*(f*f+u)*p)/((f-a)/p-1),Math.abs(d)<=c.H0){n=f;break}e=(0,s.A)(this.long0+Math.asin(r*Math.tan(f)/this.a)/Math.sin(n))}else if(Math.abs(i+this.ml0)<=c.H0)n=0,e=(0,s.A)(this.long0+r/this.a);else{var m,g,y,v,x;for(a=(this.ml0+i)/this.a,u=r*r/this.a/this.a+a*a,f=a,o=h;o;--o)if(x=this.e*Math.sin(f),m=Math.sqrt(1-x*x)*Math.tan(f),g=this.a*(0,l.A)(this.e0,this.e1,this.e2,this.e3,f),y=this.e0-2*this.e1*Math.cos(2*f)+4*this.e2*Math.cos(4*f)-6*this.e3*Math.cos(6*f),f-=d=(a*(m*(v=g/this.a)+1)-v-.5*m*(v*v+u))/(this.es*Math.sin(2*f)*(v*v+u-2*a*v)/(4*m)+(a-v)*(m*y-2/Math.sin(2*f))-y),Math.abs(d)<=c.H0){n=f;break}m=Math.sqrt(1-this.es*Math.pow(Math.sin(n),2))*Math.tan(n),e=(0,s.A)(this.long0+Math.asin(r*m/this.a)/Math.sin(n))}return t.x=e,t.y=n,t}var g=["Polyconic","poly"];e.default={init:d,forward:p,inverse:m,names:g}},5722:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return f}});var r=n(2556),i={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},o={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4};function a(){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.lat0>=r.sK-r.Vj/2?this.face=i.TOP:this.lat0<=-(r.sK-r.Vj/2)?this.face=i.BOTTOM:Math.abs(this.long0)<=r.Vj?this.face=i.FRONT:Math.abs(this.long0)<=r.sK+r.Vj?this.face=this.long0>0?i.RIGHT:i.LEFT:this.face=i.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)}function s(t){var e,n,a,s,u,f,h={x:0,y:0},d={value:0};if(t.x-=this.long0,e=0!==this.es?Math.atan(this.one_minus_f_squared*Math.tan(t.y)):t.y,n=t.x,this.face===i.TOP)s=r.sK-e,n>=r.Vj&&n<=r.sK+r.Vj?(d.value=o.AREA_0,a=n-r.sK):n>r.sK+r.Vj||n<=-(r.sK+r.Vj)?(d.value=o.AREA_1,a=n>0?n-r.DF:n+r.DF):n>-(r.sK+r.Vj)&&n<=-r.Vj?(d.value=o.AREA_2,a=n+r.sK):(d.value=o.AREA_3,a=n);else if(this.face===i.BOTTOM)s=r.sK+e,n>=r.Vj&&n<=r.sK+r.Vj?(d.value=o.AREA_0,a=-n+r.sK):n<r.Vj&&n>=-r.Vj?(d.value=o.AREA_1,a=-n):n<-r.Vj&&n>=-(r.sK+r.Vj)?(d.value=o.AREA_2,a=-n-r.sK):(d.value=o.AREA_3,a=n>0?-n+r.DF:-n-r.DF);else{var p,m,g,y,v,x;this.face===i.RIGHT?n=c(n,+r.sK):this.face===i.BACK?n=c(n,+r.DF):this.face===i.LEFT&&(n=c(n,-r.sK)),y=Math.sin(e),v=Math.cos(e),x=Math.sin(n),p=v*Math.cos(n),m=v*x,g=y,this.face===i.FRONT?a=l(s=Math.acos(p),g,m,d):this.face===i.RIGHT?a=l(s=Math.acos(m),g,-p,d):this.face===i.BACK?a=l(s=Math.acos(-p),g,-m,d):this.face===i.LEFT?a=l(s=Math.acos(-m),g,p,d):(s=a=0,d.value=o.AREA_0)}return f=Math.atan(12/r.DF*(a+Math.acos(Math.sin(a)*Math.cos(r.Vj))-r.sK)),u=Math.sqrt((1-Math.cos(s))/(Math.cos(f)*Math.cos(f))/(1-Math.cos(Math.atan(1/Math.cos(a))))),d.value===o.AREA_1?f+=r.sK:d.value===o.AREA_2?f+=r.DF:d.value===o.AREA_3&&(f+=1.5*r.DF),h.x=u*Math.cos(f),h.y=u*Math.sin(f),h.x=h.x*this.a+this.x0,h.y=h.y*this.a+this.y0,t.x=h.x,t.y=h.y,t}function u(t){var e,n,a,s,u,l,f,h,d,p,m,g,y={lam:0,phi:0},v={value:0};if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,n=Math.atan(Math.sqrt(t.x*t.x+t.y*t.y)),e=Math.atan2(t.y,t.x),t.x>=0&&t.x>=Math.abs(t.y)?v.value=o.AREA_0:t.y>=0&&t.y>=Math.abs(t.x)?(v.value=o.AREA_1,e-=r.sK):t.x<0&&-t.x>=Math.abs(t.y)?(v.value=o.AREA_2,e=e<0?e+r.DF:e-r.DF):(v.value=o.AREA_3,e+=r.sK),d=r.DF/12*Math.tan(e),u=Math.sin(d)/(Math.cos(d)-1/Math.sqrt(2)),l=Math.atan(u),(f=1-(a=Math.cos(e))*a*(s=Math.tan(n))*s*(1-Math.cos(Math.atan(1/Math.cos(l)))))<-1?f=-1:f>1&&(f=1),this.face===i.TOP)h=Math.acos(f),y.phi=r.sK-h,v.value===o.AREA_0?y.lam=l+r.sK:v.value===o.AREA_1?y.lam=l<0?l+r.DF:l-r.DF:v.value===o.AREA_2?y.lam=l-r.sK:y.lam=l;else if(this.face===i.BOTTOM)h=Math.acos(f),y.phi=h-r.sK,v.value===o.AREA_0?y.lam=-l+r.sK:v.value===o.AREA_1?y.lam=-l:v.value===o.AREA_2?y.lam=-l-r.sK:y.lam=l<0?-l-r.DF:-l+r.DF;else{var x,_,b;d=(x=f)*x,_=(d+=(b=d>=1?0:Math.sqrt(1-d)*Math.sin(l))*b)>=1?0:Math.sqrt(1-d),v.value===o.AREA_1?(d=_,_=-b,b=d):v.value===o.AREA_2?(_=-_,b=-b):v.value===o.AREA_3&&(d=_,_=b,b=-d),this.face===i.RIGHT?(d=x,x=-_,_=d):this.face===i.BACK?(x=-x,_=-_):this.face===i.LEFT&&(d=x,x=_,_=-d),y.phi=Math.acos(-b)-r.sK,y.lam=Math.atan2(_,x),this.face===i.RIGHT?y.lam=c(y.lam,-r.sK):this.face===i.BACK?y.lam=c(y.lam,-r.DF):this.face===i.LEFT&&(y.lam=c(y.lam,+r.sK))}0!==this.es&&(p=y.phi<0?1:0,m=Math.tan(y.phi),g=this.b/Math.sqrt(m*m+this.one_minus_f_squared),y.phi=Math.atan(Math.sqrt(this.a*this.a-g*g)/(this.one_minus_f*g)),p&&(y.phi=-y.phi));return y.lam+=this.long0,t.x=y.lam,t.y=y.phi,t}function l(t,e,n,i){var a;return t<r.H0?(i.value=o.AREA_0,a=0):(a=Math.atan2(e,n),Math.abs(a)<=r.Vj?i.value=o.AREA_0:a>r.Vj&&a<=r.sK+r.Vj?(i.value=o.AREA_1,a-=r.sK):a>r.sK+r.Vj||a<=-(r.sK+r.Vj)?(i.value=o.AREA_2,a=a>=0?a-r.DF:a+r.DF):(i.value=o.AREA_3,a+=r.sK)),a}function c(t,e){var n=t+e;return n<-r.DF?n+=r.JM:n>+r.DF&&(n-=r.JM),n}var f=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"];e.default={init:a,forward:s,inverse:u,names:f}},1295:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return m},init:function(){return p},inverse:function(){return g},names:function(){return y}});var r=n(2556),i=n(737),o=[[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]],a=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-1.26793e-9,4.22642e-10],[.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]],s=.8487,u=1.3523,l=r.dX/5,c=1/l,f=18,h=function(t,e){return t[0]+e*(t[1]+e*(t[2]+e*t[3]))},d=function(t,e){return t[1]+e*(2*t[2]+3*e*t[3])};function p(){this.x0=this.x0||0,this.y0=this.y0||0,this.long0=this.long0||0,this.es=0,this.title=this.title||"Robinson"}function m(t){var e=(0,i.A)(t.x-this.long0),n=Math.abs(t.y),d=Math.floor(n*l);d<0?d=0:d>=f&&(d=f-1),n=r.dX*(n-c*d);var p={x:h(o[d],n)*e,y:h(a[d],n)};return t.y<0&&(p.y=-p.y),p.x=p.x*this.a*s+this.x0,p.y=p.y*this.a*u+this.y0,p}function g(t){var e={x:(t.x-this.x0)/(this.a*s),y:Math.abs(t.y-this.y0)/(this.a*u)};if(e.y>=1)e.x/=o[f][0],e.y=t.y<0?-r.sK:r.sK;else{var n=Math.floor(e.y*f);for(n<0?n=0:n>=f&&(n=f-1);;)if(a[n][0]>e.y)--n;else{if(!(a[n+1][0]<=e.y))break;++n}var l=a[n],c=5*(e.y-l[0])/(a[n+1][0]-l[0]);c=function(t,e,n,r){for(var i=e;r;--r){var o=t(i);if(i-=o,Math.abs(o)<n)break}return i}((function(t){return(h(l,t)-e.y)/d(l,t)}),c,r.H0,100),e.x/=h(o[n],c),e.y=(5*n+c)*r.zq,t.y<0&&(e.y=-e.y)}return e.x=(0,i.A)(e.x+this.long0),e}var y=["Robinson","robin"];e.default={init:p,forward:m,inverse:g,names:y}},9006:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return h},init:function(){return f},inverse:function(){return d},names:function(){return p}});var r=n(737),i=n(5473),o=n(6366),a=n(2092),s=n(3220),u=n(2556),l=n(8609),c=20;function f(){this.sphere?(this.n=1,this.m=0,this.es=0,this.C_y=Math.sqrt((this.m+1)/this.n),this.C_x=this.C_y/(this.m+1)):this.en=(0,o.A)(this.es)}function h(t){var e,n,i=t.x,o=t.y;if(i=(0,r.A)(i-this.long0),this.sphere){if(this.m)for(var s=this.n*Math.sin(o),l=c;l;--l){var f=(this.m*o+Math.sin(o)-s)/(this.m+Math.cos(o));if(o-=f,Math.abs(f)<u.H0)break}else o=1!==this.n?Math.asin(this.n*Math.sin(o)):o;e=this.a*this.C_x*i*(this.m+Math.cos(o)),n=this.a*this.C_y*o}else{var h=Math.sin(o),d=Math.cos(o);n=this.a*(0,a.A)(o,h,d,this.en),e=this.a*i*d/Math.sqrt(1-this.es*h*h)}return t.x=e,t.y=n,t}function d(t){var e,n,o,a;return t.x-=this.x0,o=t.x/this.a,t.y-=this.y0,e=t.y/this.a,this.sphere?(e/=this.C_y,o/=this.C_x*(this.m+Math.cos(e)),this.m?e=(0,l.A)((this.m*e+Math.sin(e))/this.n):1!==this.n&&(e=(0,l.A)(Math.sin(e)/this.n)),o=(0,r.A)(o+this.long0),e=(0,i.A)(e)):(e=(0,s.A)(t.y/this.a,this.es,this.en),(a=Math.abs(e))<u.sK?(a=Math.sin(e),n=this.long0+t.x*Math.sqrt(1-this.es*a*a)/(this.a*Math.cos(e)),o=(0,r.A)(n)):a-u.H0<u.sK&&(o=this.long0)),t.x=o,t.y=e,t}var p=["Sinusoidal","sinu"];e.default={init:f,forward:h,inverse:d,names:p}},988:function(t,e,n){"use strict";function r(){var t=this.lat0;this.lambda0=this.long0;var e=Math.sin(t),n=this.a,r=1/this.rf,i=2*r-Math.pow(r,2),o=this.e=Math.sqrt(i);this.R=this.k0*n*Math.sqrt(1-i)/(1-i*Math.pow(e,2)),this.alpha=Math.sqrt(1+i/(1-i)*Math.pow(Math.cos(t),4)),this.b0=Math.asin(e/this.alpha);var a=Math.log(Math.tan(Math.PI/4+this.b0/2)),s=Math.log(Math.tan(Math.PI/4+t/2)),u=Math.log((1+o*e)/(1-o*e));this.K=a-this.alpha*s+this.alpha*o/2*u}function i(t){var e=Math.log(Math.tan(Math.PI/4-t.y/2)),n=this.e/2*Math.log((1+this.e*Math.sin(t.y))/(1-this.e*Math.sin(t.y))),r=-this.alpha*(e+n)+this.K,i=2*(Math.atan(Math.exp(r))-Math.PI/4),o=this.alpha*(t.x-this.lambda0),a=Math.atan(Math.sin(o)/(Math.sin(this.b0)*Math.tan(i)+Math.cos(this.b0)*Math.cos(o))),s=Math.asin(Math.cos(this.b0)*Math.sin(i)-Math.sin(this.b0)*Math.cos(i)*Math.cos(o));return t.y=this.R/2*Math.log((1+Math.sin(s))/(1-Math.sin(s)))+this.y0,t.x=this.R*a+this.x0,t}function o(t){for(var e=t.x-this.x0,n=t.y-this.y0,r=e/this.R,i=2*(Math.atan(Math.exp(n/this.R))-Math.PI/4),o=Math.asin(Math.cos(this.b0)*Math.sin(i)+Math.sin(this.b0)*Math.cos(i)*Math.cos(r)),a=Math.atan(Math.sin(r)/(Math.cos(this.b0)*Math.cos(r)-Math.sin(this.b0)*Math.tan(i))),s=this.lambda0+a/this.alpha,u=0,l=o,c=-1e3,f=0;Math.abs(l-c)>1e-7;){if(++f>20)return;u=1/this.alpha*(Math.log(Math.tan(Math.PI/4+o/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(l))/2)),c=l,l=2*Math.atan(Math.exp(u))-Math.PI/2}return t.x=s,t.y=l,t}n.r(e),n.d(e,{forward:function(){return i},init:function(){return r},inverse:function(){return o},names:function(){return a}});var a=["somerc"];e.default={init:r,forward:i,inverse:o,names:a}},688:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return f},init:function(){return c},inverse:function(){return h},names:function(){return d},ssfn_:function(){return l}});var r=n(2556),i=n(4205),o=n(444),a=n(9967),s=n(1793),u=n(737);function l(t,e,n){return e*=n,Math.tan(.5*(r.sK+t))*Math.pow((1-e)/(1+e),.5*n)}function c(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.coslat0=Math.cos(this.lat0),this.sinlat0=Math.sin(this.lat0),this.sphere?1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=r.H0&&(this.k0=.5*(1+(0,i.A)(this.lat0)*Math.sin(this.lat_ts))):(Math.abs(this.coslat0)<=r.H0&&(this.lat0>0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=r.H0&&Math.abs(Math.cos(this.lat_ts))>r.H0&&(this.k0=.5*this.cons*(0,o.A)(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/(0,a.A)(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=(0,o.A)(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-r.sK,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function f(t){var e,n,i,o,s,l,c=t.x,f=t.y,h=Math.sin(f),d=Math.cos(f),p=(0,u.A)(c-this.long0);return Math.abs(Math.abs(c-this.long0)-Math.PI)<=r.H0&&Math.abs(f+this.lat0)<=r.H0?(t.x=NaN,t.y=NaN,t):this.sphere?(e=2*this.k0/(1+this.sinlat0*h+this.coslat0*d*Math.cos(p)),t.x=this.a*e*d*Math.sin(p)+this.x0,t.y=this.a*e*(this.coslat0*h-this.sinlat0*d*Math.cos(p))+this.y0,t):(n=2*Math.atan(this.ssfn_(f,h,this.e))-r.sK,o=Math.cos(n),i=Math.sin(n),Math.abs(this.coslat0)<=r.H0?(s=(0,a.A)(this.e,f*this.con,this.con*h),l=2*this.a*this.k0*s/this.cons,t.x=this.x0+l*Math.sin(c-this.long0),t.y=this.y0-this.con*l*Math.cos(c-this.long0),t):(Math.abs(this.sinlat0)<r.H0?(e=2*this.a*this.k0/(1+o*Math.cos(p)),t.y=e*i):(e=2*this.a*this.k0*this.ms1/(this.cosX0*(1+this.sinX0*i+this.cosX0*o*Math.cos(p))),t.y=e*(this.cosX0*i-this.sinX0*o*Math.cos(p))+this.y0),t.x=e*o*Math.sin(p)+this.x0,t))}function h(t){var e,n,i,o,a;t.x-=this.x0,t.y-=this.y0;var l=Math.sqrt(t.x*t.x+t.y*t.y);if(this.sphere){var c=2*Math.atan(l/(2*this.a*this.k0));return e=this.long0,n=this.lat0,l<=r.H0?(t.x=e,t.y=n,t):(n=Math.asin(Math.cos(c)*this.sinlat0+t.y*Math.sin(c)*this.coslat0/l),e=Math.abs(this.coslat0)<r.H0?this.lat0>0?(0,u.A)(this.long0+Math.atan2(t.x,-1*t.y)):(0,u.A)(this.long0+Math.atan2(t.x,t.y)):(0,u.A)(this.long0+Math.atan2(t.x*Math.sin(c),l*this.coslat0*Math.cos(c)-t.y*this.sinlat0*Math.sin(c))),t.x=e,t.y=n,t)}if(Math.abs(this.coslat0)<=r.H0){if(l<=r.H0)return n=this.lat0,e=this.long0,t.x=e,t.y=n,t;t.x*=this.con,t.y*=this.con,i=l*this.cons/(2*this.a*this.k0),n=this.con*(0,s.A)(this.e,i),e=this.con*(0,u.A)(this.con*this.long0+Math.atan2(t.x,-1*t.y))}else o=2*Math.atan(l*this.cosX0/(2*this.a*this.k0*this.ms1)),e=this.long0,l<=r.H0?a=this.X0:(a=Math.asin(Math.cos(o)*this.sinX0+t.y*Math.sin(o)*this.cosX0/l),e=(0,u.A)(this.long0+Math.atan2(t.x*Math.sin(o),l*this.cosX0*Math.cos(o)-t.y*this.sinX0*Math.sin(o)))),n=-1*(0,s.A)(this.e,Math.tan(.5*(r.sK+a)));return t.x=e,t.y=n,t}var d=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"];e.default={init:c,forward:f,inverse:h,names:d,ssfn_:l}},865:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(3246),i=n(737),o=n(1708);function a(){r.default.init.apply(this),this.rc&&(this.sinc0=Math.sin(this.phic0),this.cosc0=Math.cos(this.phic0),this.R2=2*this.rc,this.title||(this.title="Oblique Stereographic Alternative"))}function s(t){var e,n,o,a;return t.x=(0,i.A)(t.x-this.long0),r.default.forward.apply(this,[t]),e=Math.sin(t.y),n=Math.cos(t.y),o=Math.cos(t.x),a=this.k0*this.R2/(1+this.sinc0*e+this.cosc0*n*o),t.x=a*n*Math.sin(t.x),t.y=a*(this.cosc0*e-this.sinc0*n*o),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function u(t){var e,n,a,s,u;if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,u=(0,o.A)(t.x,t.y)){var l=2*Math.atan2(u,this.R2);e=Math.sin(l),n=Math.cos(l),s=Math.asin(n*this.sinc0+t.y*e*this.cosc0/u),a=Math.atan2(t.x*e,u*this.cosc0*n-t.y*this.sinc0*e)}else s=this.phic0,a=0;return t.x=a,t.y=s,r.default.inverse.apply(this,[t]),t.x=(0,i.A)(t.x+this.long0),t}var l=["Stereographic_North_Pole","Oblique_Stereographic","sterea","Oblique Stereographic Alternative","Double_Stereographic"];e.default={init:a,forward:s,inverse:u,names:l}},5602:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return c},init:function(){return l},inverse:function(){return f},names:function(){return h}});var r=n(6366),i=n(2092),o=n(3220),a=n(737),s=n(2556),u=n(4205);function l(){this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.es&&(this.en=(0,r.A)(this.es),this.ml0=(0,i.A)(this.lat0,Math.sin(this.lat0),Math.cos(this.lat0),this.en))}function c(t){var e,n,r,o=t.x,u=t.y,l=(0,a.A)(o-this.long0),c=Math.sin(u),f=Math.cos(u);if(this.es){var h=f*l,d=Math.pow(h,2),p=this.ep2*Math.pow(f,2),m=Math.pow(p,2),g=Math.abs(f)>s.H0?Math.tan(u):0,y=Math.pow(g,2),v=Math.pow(y,2);e=1-this.es*Math.pow(c,2),h/=Math.sqrt(e);var x=(0,i.A)(u,c,f,this.en);n=this.a*(this.k0*h*(1+d/6*(1-y+p+d/20*(5-18*y+v+14*p-58*y*p+d/42*(61+179*v-v*y-479*y)))))+this.x0,r=this.a*(this.k0*(x-this.ml0+c*l*h/2*(1+d/12*(5-y+9*p+4*m+d/30*(61+v-58*y+270*p-330*y*p+d/56*(1385+543*v-v*y-3111*y))))))+this.y0}else{var _=f*Math.sin(l);if(Math.abs(Math.abs(_)-1)<s.H0)return 93;if(n=.5*this.a*this.k0*Math.log((1+_)/(1-_))+this.x0,r=f*Math.cos(l)/Math.sqrt(1-Math.pow(_,2)),(_=Math.abs(r))>=1){if(_-1>s.H0)return 93;r=0}else r=Math.acos(r);u<0&&(r=-r),r=this.a*this.k0*(r-this.lat0)+this.y0}return t.x=n,t.y=r,t}function f(t){var e,n,r,i,l=(t.x-this.x0)*(1/this.a),c=(t.y-this.y0)*(1/this.a);if(this.es)if(e=this.ml0+c/this.k0,n=(0,o.A)(e,this.es,this.en),Math.abs(n)<s.sK){var f=Math.sin(n),h=Math.cos(n),d=Math.abs(h)>s.H0?Math.tan(n):0,p=this.ep2*Math.pow(h,2),m=Math.pow(p,2),g=Math.pow(d,2),y=Math.pow(g,2);e=1-this.es*Math.pow(f,2);var v=l*Math.sqrt(e)/this.k0,x=Math.pow(v,2);r=n-(e*=d)*x/(1-this.es)*.5*(1-x/12*(5+3*g-9*p*g+p-4*m-x/30*(61+90*g-252*p*g+45*y+46*p-x/56*(1385+3633*g+4095*y+1574*y*g)))),i=(0,a.A)(this.long0+v*(1-x/6*(1+2*g+p-x/20*(5+28*g+24*y+8*p*g+6*p-x/42*(61+662*g+1320*y+720*y*g))))/h)}else r=s.sK*(0,u.A)(c),i=0;else{var _=Math.exp(l/this.k0),b=.5*(_-1/_),w=this.lat0+c/this.k0,M=Math.cos(w);e=Math.sqrt((1-Math.pow(M,2))/(1+Math.pow(b,2))),r=Math.asin(e),c<0&&(r=-r),i=0===b&&0===M?0:(0,a.A)(Math.atan2(b,M)+this.long0)}return t.x=i,t.y=r,t}var h=["Fast_Transverse_Mercator","Fast Transverse Mercator"];e.default={init:l,forward:c,inverse:f,names:h}},7127:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return u},init:function(){return s},inverse:function(){return l},names:function(){return c}});var r=n(2556),i=n(1708),o={N_POLE:0,S_POLE:1,EQUIT:2,OBLIQ:3},a={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};function s(){if(Object.keys(a).forEach(function(t){if(void 0===this[t])this[t]=a[t].def;else{if(a[t].num&&isNaN(this[t]))throw new Error("Invalid parameter value, must be numeric "+t+" = "+this[t]);a[t].num&&(this[t]=parseFloat(this[t]))}a[t].degrees&&(this[t]=this[t]*r.zq)}.bind(this)),Math.abs(Math.abs(this.lat0)-r.sK)<r.H0?this.mode=this.lat0<0?o.S_POLE:o.N_POLE:Math.abs(this.lat0)<r.H0?this.mode=o.EQUIT:(this.mode=o.OBLIQ,this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0)),this.pn1=this.h/this.a,this.pn1<=0||this.pn1>1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var t=this.tilt,e=this.azi;this.cg=Math.cos(e),this.sg=Math.sin(e),this.cw=Math.cos(t),this.sw=Math.sin(t)}function u(t){t.x-=this.long0;var e,n,r,i,a=Math.sin(t.y),s=Math.cos(t.y),u=Math.cos(t.x);switch(this.mode){case o.OBLIQ:n=this.sinph0*a+this.cosph0*s*u;break;case o.EQUIT:n=s*u;break;case o.S_POLE:n=-a;break;case o.N_POLE:n=a}switch(e=(n=this.pn1/(this.p-n))*s*Math.sin(t.x),this.mode){case o.OBLIQ:n*=this.cosph0*a-this.sinph0*s*u;break;case o.EQUIT:n*=a;break;case o.N_POLE:n*=-s*u;break;case o.S_POLE:n*=s*u}return i=1/((r=n*this.cg+e*this.sg)*this.sw*this.h1+this.cw),e=(e*this.cg-n*this.sg)*this.cw*i,n=r*i,t.x=e*this.a,t.y=n*this.a,t}function l(t){t.x/=this.a,t.y/=this.a;var e,n,a,s={x:t.x,y:t.y};a=1/(this.pn1-t.y*this.sw),e=this.pn1*t.x*a,n=this.pn1*t.y*this.cw*a,t.x=e*this.cg+n*this.sg,t.y=n*this.cg-e*this.sg;var u=(0,i.A)(t.x,t.y);if(Math.abs(u)<r.H0)s.x=0,s.y=t.y;else{var l,c;switch(c=1-u*u*this.pfact,c=(this.p-Math.sqrt(c))/(this.pn1/u+u/this.pn1),l=Math.sqrt(1-c*c),this.mode){case o.OBLIQ:s.y=Math.asin(l*this.sinph0+t.y*c*this.cosph0/u),t.y=(l-this.sinph0*Math.sin(s.y))*u,t.x*=c*this.cosph0;break;case o.EQUIT:s.y=Math.asin(t.y*c/u),t.y=l*u,t.x*=c;break;case o.N_POLE:s.y=Math.asin(l),t.y=-t.y;break;case o.S_POLE:s.y=-Math.asin(l)}s.x=Math.atan2(t.x,t.y)}return t.x=s.x+this.long0,t.y=s.y,t}var c=["Tilted_Perspective","tpers"];e.default={init:s,forward:u,inverse:l,names:c}},6748:function(t,e,n){"use strict";n.r(e),n.d(e,{default:function(){return l},dependsOn:function(){return a},init:function(){return s},names:function(){return u}});var r=n(737);var i=n(994),o=n(2556),a="etmerc";function s(){var t=function(t,e){if(void 0===t){if((t=Math.floor(30*((0,r.A)(e)+Math.PI)/Math.PI)+1)<0)return 0;if(t>60)return 60}return t}(this.zone,this.long0);if(void 0===t)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(t)-183)*o.zq,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,i.default.init.apply(this),this.forward=i.default.forward,this.inverse=i.default.inverse}var u=["Universal Transverse Mercator System","utm"],l={init:s,names:u,dependsOn:a}},3211:function(t,e,n){"use strict";n.r(e),n.d(e,{forward:function(){return s},init:function(){return a},inverse:function(){return u},names:function(){return l}});var r=n(737),i=n(2556),o=n(8609);function a(){this.R=this.a}function s(t){var e,n,a=t.x,s=t.y,u=(0,r.A)(a-this.long0);Math.abs(s)<=i.H0&&(e=this.x0+this.R*u,n=this.y0);var l=(0,o.A)(2*Math.abs(s/Math.PI));(Math.abs(u)<=i.H0||Math.abs(Math.abs(s)-i.sK)<=i.H0)&&(e=this.x0,n=s>=0?this.y0+Math.PI*this.R*Math.tan(.5*l):this.y0+Math.PI*this.R*-Math.tan(.5*l));var c=.5*Math.abs(Math.PI/u-u/Math.PI),f=c*c,h=Math.sin(l),d=Math.cos(l),p=d/(h+d-1),m=p*p,g=p*(2/h-1),y=g*g,v=Math.PI*this.R*(c*(p-y)+Math.sqrt(f*(p-y)*(p-y)-(y+f)*(m-y)))/(y+f);u<0&&(v=-v),e=this.x0+v;var x=f+p;return v=Math.PI*this.R*(g*x-c*Math.sqrt((y+f)*(f+1)-x*x))/(y+f),n=s>=0?this.y0+v:this.y0-v,t.x=e,t.y=n,t}function u(t){var e,n,o,a,s,u,l,c,f,h,d,p;return t.x-=this.x0,t.y-=this.y0,d=Math.PI*this.R,s=(o=t.x/d)*o+(a=t.y/d)*a,d=3*(a*a/(c=-2*(u=-Math.abs(a)*(1+s))+1+2*a*a+s*s)+(2*(l=u-2*a*a+o*o)*l*l/c/c/c-9*u*l/c/c)/27)/(f=(u-l*l/3/c)/c)/(h=2*Math.sqrt(-f/3)),Math.abs(d)>1&&(d=d>=0?1:-1),p=Math.acos(d)/3,n=t.y>=0?(-h*Math.cos(p+Math.PI/3)-l/3/c)*Math.PI:-(-h*Math.cos(p+Math.PI/3)-l/3/c)*Math.PI,e=Math.abs(o)<i.H0?this.long0:(0,r.A)(this.long0+Math.PI*(s-1+Math.sqrt(1+2*(o*o-a*a)+s*s))/2/o),t.x=e,t.y=n,t}var l=["Van_der_Grinten_I","VanDerGrinten","vandg"];e.default={init:a,forward:s,inverse:u,names:l}},9689:function(t,e,n){var r={"./aea.js":5458,"./aeqd.js":8980,"./bonne.js":5789,"./cass.js":529,"./cea.js":4101,"./eqc.js":4256,"./eqdc.js":7968,"./eqearth.js":7129,"./equi.js":3667,"./etmerc.js":994,"./gauss.js":3246,"./geocent.js":4876,"./geos.js":469,"./gnom.js":9462,"./gstmerc.js":7041,"./krovak.js":6507,"./laea.js":7406,"./lcc.js":9269,"./longlat.js":2848,"./merc.js":2286,"./mill.js":5157,"./moll.js":5967,"./nzmg.js":6407,"./omerc.js":7475,"./ortho.js":8181,"./poly.js":2169,"./qsc.js":5722,"./robin.js":1295,"./sinu.js":9006,"./somerc.js":988,"./stere.js":688,"./sterea.js":865,"./tmerc.js":5602,"./tpers.js":7127,"./utm.js":6748,"./vandg.js":3211};function i(t){var e=o(t);return n(e)}function o(t){if(!n.o(r,t)){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}return r[t]}i.keys=function(){return Object.keys(r)},i.resolve=o,t.exports=i,i.id=9689},5685:function(t){t.exports="/* lineFeature fragment shader */\n\n#ifdef GL_ES\n #ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n #else\n precision mediump float;\n #endif\n#endif\nvarying vec4 strokeColorVar;\nvarying vec4 subpos;\nvarying vec4 info;\nvarying vec4 angles;\nuniform float antialiasing;\nuniform float miterLimit;\nuniform float fixedFlags;\n\nvoid main () {\n vec4 color = strokeColorVar;\n float opacity = 1.0;\n int nearMode = int(floor(info.x + 0.5));\n int farMode = int(floor(info.y + 0.5));\n float cosABC = angles.x;\n float sinABC = angles.y;\n float cosBCD = angles.z;\n float sinBCD = angles.w;\n // never render on the opposite side of a miter. This uses a bit of\n // slop, via pow(smoothstep()) instead of step(), since there are\n // precision issues in this calculation. This doesn't wholly solve\n // the precision issue; sometimes pixels are missed or double\n // rendered along the inside seam of a miter.\n if (nearMode >= 4) {\n float dist = cosABC * subpos.x - sinABC * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n discard;\n }\n }\n if (farMode >= 4) {\n float dist = cosBCD * subpos.z - sinBCD * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n discard;\n }\n }\n // butt or square cap\n if ((nearMode == 0 || nearMode == 1) && subpos.x < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.x + subpos.w * float(nearMode)));\n }\n if ((farMode == 0 || farMode == 1) && subpos.z < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.z + subpos.w * float(farMode)));\n }\n // round cap\n if (nearMode == 2 && subpos.x <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n if (farMode == 2 && subpos.z <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n // bevel and clip joins\n if ((nearMode == 5 || nearMode == 7) && subpos.x < antialiasing) {\n float dist = (sinABC * subpos.x + cosABC * subpos.y) * sign(sinABC);\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n float maxDist;\n if (nearMode == 5) maxDist = cosABC * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n if ((farMode == 5 || farMode == 7) && subpos.z < antialiasing) {\n float dist = (sinBCD * subpos.z + cosBCD * subpos.y) * sign(sinBCD);\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n float maxDist;\n if (farMode == 5) maxDist = cosBCD * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n // round join\n if (nearMode == 6 && subpos.x <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y, 2.0))));\n }\n if (farMode == 6 && subpos.z <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y, 2.0))));\n }\n // antialias along main edges\n if (antialiasing > 0.0) {\n if (subpos.y > subpos.w * (1.0 + info.z) - antialiasing) {\n opacity = min(opacity, smoothstep(antialiasing, -antialiasing, subpos.y - subpos.w * (1.0 + info.z)));\n }\n if (subpos.y < subpos.w * (-1.0 + info.z) + antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.y - subpos.w * (-1.0 + info.z)));\n }\n }\n if (opacity == 0.0) {\n discard;\n }\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},9336:function(t){t.exports="/* lineFeature vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute vec3 prev;\nattribute vec3 next;\nattribute vec3 far;\nattribute float flags;\n\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\n\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nuniform float pixelWidth;\nuniform float aspect;\nuniform float miterLimit;\nuniform float antialiasing;\n\nvarying vec4 strokeColorVar;\nvarying vec4 subpos; /* px, py, length - px, width */\nvarying vec4 info; /* near mode, far mode, offset */\nvarying vec4 angles; /* near angle cos, sin, far angle cos, sin */\n\nconst float PI = 3.14159265358979323846264;\n\nvec4 viewCoord(vec3 c) {\n vec4 result = projectionMatrix * modelViewMatrix * vec4(c.xyz, 1.0);\n if (result.w != 0.0) result = result / result.w;\n return result;\n}\n\nfloat atan2(float y, float x) {\n if (x > 0.0) return atan(y / x);\n if (x < 0.0 && y >= 0.0) return atan(y / x) + PI;\n if (x < 0.0) return atan(y / x) - PI;\n return sign(y) * 0.5 * PI;\n}\n\nvoid main(void)\n{\n /* If any vertex has been deliberately set to a negative opacity,\n * skip doing computations on it. */\n if (strokeOpacity < 0.0) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return;\n }\n /* convert coordinates. We have four values, since we need to\n * calculate the angles between the lines formed by prev-pos and\n * pos-next, and between pos-next and next-far, plus know the angle\n * (prev)---(pos)---(next)---(far) => A---B---C---D */\n vec4 A = viewCoord(prev);\n vec4 B = viewCoord(pos);\n vec4 C = viewCoord(next);\n vec4 D = viewCoord(far);\n // calculate line segment vector and angle\n vec2 deltaCB = C.xy - B.xy;\n if (deltaCB == vec2(0.0, 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return;\n }\n float lineLength = length(vec2(deltaCB.x, deltaCB.y / aspect)) / pixelWidth;\n // if lines reverse upon themselves and are not nearly the same length, skip\n // joins. This is a heuristic; the correct method would to be to pass some\n // sort of length of the adjacent line to the fragment renderer and adjust\n // which fragments are rendered, but this is much more complex.\n float abLimit = length(vec2(A.x - B.x, (A.y - B.y) / aspect)) / pixelWidth;\n float dcLimit = length(vec2(D.x - C.x, (D.y - C.y) / aspect)) / pixelWidth;\n if (abLimit >= lineLength - antialiasing - strokeWidth * 0.5 && abLimit <= lineLength + antialiasing + strokeWidth * 0.5) {\n abLimit = 0.0001;\n } else {\n if (abLimit < lineLength) abLimit = lineLength;\n abLimit = (strokeWidth - antialiasing) / (abLimit + antialiasing);\n if (abLimit < 0.0001) abLimit = 0.0001;\n if (abLimit > 0.1) abLimit = 0.1;\n }\n if (dcLimit >= lineLength - antialiasing - strokeWidth * 0.5 && dcLimit <= lineLength + antialiasing + strokeWidth * 0.5) {\n dcLimit = 0.0001;\n } else {\n if (dcLimit < lineLength) dcLimit = lineLength;\n dcLimit = (strokeWidth - antialiasing) / (dcLimit + antialiasing);\n if (dcLimit < 0.0001) dcLimit = 0.0001;\n if (dcLimit > 0.1) dcLimit = 0.1;\n }\n float angleCB = atan2(deltaCB.y, deltaCB.x * aspect);\n // values we need to pass along\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // extract values from our flags field\n int vertex = int(mod(flags, 4.0));\n int nearMode = int(mod(floor(flags / 4.0), 8.0));\n int farMode = int(mod(floor(flags / 32.0), 8.0));\n // we use 11 bits of the flags for the offset, where -1023 to 1023\n // maps to -1 to 1. The 11 bits are a signed value, so simply\n // selecting the bits will result in an unsigned values that may be\n // greater than 1, in which case we have to subtract appropriately.\n float offset = mod(floor(flags / 256.0), 2048.0) / 1023.0;\n if (offset > 1.0) offset -= 2048.0 / 1023.0;\n // by default, offset by the width and don't extend lines. Later,\n // calculate line extensions based on end cap and end join modes\n float yOffset = strokeWidth + antialiasing;\n if (vertex == 0) yOffset *= -1.0;\n yOffset += strokeWidth * offset;\n float xOffset = 0.0;\n // end caps\n if (nearMode == 0) {\n xOffset = antialiasing;\n } else if (nearMode == 1 || nearMode == 2) {\n xOffset = strokeWidth + antialiasing;\n }\n\n // If joining lines, calculate the angles in screen space formed by\n // the near end (A-B-C) and far end (B-C-D), and determine how much\n // space is needed for the particular join.\n // This could be changed: if the lines are not a uniform width and\n // offset, then the functional join angle is not simply half the\n // angle between the two lines, but rather half the angle of the\n // inside edge of the the two lines.\n float cosABC = 1.0, sinABC = 0.0, cosBCD = 1.0, sinBCD = 0.0; // of half angles\n // handle near end\n if (nearMode >= 4) {\n float angleBA = atan2(B.y - A.y, (B.x - A.x) * aspect);\n if (A.xy == B.xy) angleBA = angleCB;\n float angleABC = angleCB - angleBA;\n // ensure angle is in the range [-PI, PI], then take the half angle\n angleABC = (mod(angleABC + 3.0 * PI, 2.0 * PI) - PI) / 2.0;\n cosABC = cos(angleABC); sinABC = sin(angleABC);\n // if this angle is close to flat, pass-through the join\n if (nearMode >= 4 && (cosABC > 0.999999 || cosABC < abLimit)) {\n nearMode = 3;\n }\n // miter, miter-clip\n if (nearMode == 4 || nearMode == 7) {\n if (cosABC < 0.000001 || 1.0 / cosABC > miterLimit) {\n if (nearMode == 4) {\n nearMode = 5;\n } else {\n xOffset = miterLimit * strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing;\n }\n } else {\n // we add an extra 1.0 to the xOffset to make sure that fragment\n // shader is doing the clipping\n xOffset = abs(sinABC / cosABC) * strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing + 1.0;\n nearMode = 4;\n }\n }\n // bevel or round join\n if (nearMode == 5 || nearMode == 6) {\n xOffset = strokeWidth * (1.0 - offset * sign(sinABC)) + antialiasing;\n }\n }\n\n // handle far end\n if (farMode >= 4) {\n float angleDC = atan2(D.y - C.y, (D.x - C.x) * aspect);\n if (D.xy == C.xy) angleDC = angleCB;\n float angleBCD = angleDC - angleCB;\n // ensure angle is in the range [-PI, PI], then take the half angle\n angleBCD = (mod(angleBCD + 3.0 * PI, 2.0 * PI) - PI) / 2.0;\n cosBCD = cos(angleBCD); sinBCD = sin(angleBCD);\n // if this angle is close to flat, pass-through the join\n if (farMode >= 4 && (cosBCD > 0.999999 || cosBCD < dcLimit)) {\n farMode = 3;\n }\n // miter, miter-clip\n if (farMode == 4 || farMode == 7) {\n if (cosBCD < 0.000001 || 1.0 / cosBCD > miterLimit) {\n if (farMode == 4) farMode = 5;\n } else {\n farMode = 4;\n }\n }\n }\n\n // compute the location of a vertex to include everything that might\n // need to be rendered\n xOffset *= -1.0;\n gl_Position = vec4(\n B.x + (xOffset * cos(angleCB) - yOffset * sin(angleCB)) * pixelWidth,\n B.y + (xOffset * sin(angleCB) + yOffset * cos(angleCB)) * pixelWidth * aspect,\n B.z, 1.0);\n // store other values needed to determine which pixels to plot.\n if (vertex == 0 || vertex == 1) {\n subpos = vec4(xOffset, yOffset, lineLength - xOffset, strokeWidth);\n info = vec4(float(nearMode), float(farMode), offset, 0.0);\n angles = vec4(cosABC, sinABC, cosBCD, sinBCD);\n } else {\n subpos = vec4(lineLength - xOffset, -yOffset, xOffset, strokeWidth);\n info = vec4(float(farMode), float(nearMode), -offset, 0.0);\n angles = vec4(cosBCD, -sinBCD, cosABC, -sinABC);\n }\n}\n"},1388:function(t){t.exports="/* lineFeature debug fragment shader */\n\n#ifdef GL_ES\n #ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n #else\n precision mediump float;\n #endif\n#endif\nvarying vec4 strokeColorVar;\nvarying vec4 subpos;\nvarying vec4 info;\nvarying vec4 angles;\nuniform float antialiasing;\nuniform float miterLimit;\nuniform float fixedFlags;\n\nvoid main () {\n vec4 color = strokeColorVar;\n bool debug = bool(mod(fixedFlags, 2.0));\n float opacity = 1.0;\n int nearMode = int(floor(info.x + 0.5));\n int farMode = int(floor(info.y + 0.5));\n float cosABC = angles.x;\n float sinABC = angles.y;\n float cosBCD = angles.z;\n float sinBCD = angles.w;\n // never render on the opposite side of a miter. This uses a bit of\n // slop, via pow(smoothstep()) instead of step(), since there are\n // precision issues in this calculation. This doesn't wholly solve\n // the precision issue; sometimes pixels are missed or double\n // rendered along the inside seam of a miter.\n if (nearMode >= 4) {\n float dist = cosABC * subpos.x - sinABC * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n if (debug) {\n color.r = 255.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n }\n if (farMode >= 4) {\n float dist = cosBCD * subpos.z - sinBCD * subpos.y;\n opacity = min(opacity, pow(smoothstep(-0.02, 0.02, dist), 0.5));\n if (opacity == 0.0) {\n if (debug) {\n color.r = 254.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n }\n // butt or square cap\n if ((nearMode == 0 || nearMode == 1) && subpos.x < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.x + subpos.w * float(nearMode)));\n }\n if ((farMode == 0 || farMode == 1) && subpos.z < antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.z + subpos.w * float(farMode)));\n }\n // round cap\n if (nearMode == 2 && subpos.x <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n if (farMode == 2 && subpos.z <= 0.0) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y - info.z * subpos.w, 2.0))));\n }\n // bevel and clip joins\n if ((nearMode == 5 || nearMode == 7) && subpos.x < antialiasing) {\n float dist = (sinABC * subpos.x + cosABC * subpos.y) * sign(sinABC);\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n float maxDist;\n if (nearMode == 5) maxDist = cosABC * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n if ((farMode == 5 || farMode == 7) && subpos.z < antialiasing) {\n float dist = (sinBCD * subpos.z + cosBCD * subpos.y) * sign(sinBCD);\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n float maxDist;\n if (farMode == 5) maxDist = cosBCD * w;\n else maxDist = miterLimit * w;\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, maxDist + dist));\n }\n // round join\n if (nearMode == 6 && subpos.x <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinABC));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.x, 2.0) + pow(subpos.y, 2.0))));\n }\n if (farMode == 6 && subpos.z <= 0.0) {\n float w = subpos.w * (1.0 - info.z * sign(sinBCD));\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, w - sqrt(pow(subpos.z, 2.0) + pow(subpos.y, 2.0))));\n }\n // antialias along main edges\n if (antialiasing > 0.0) {\n if (subpos.y > subpos.w * (1.0 + info.z) - antialiasing) {\n opacity = min(opacity, smoothstep(antialiasing, -antialiasing, subpos.y - subpos.w * (1.0 + info.z)));\n }\n if (subpos.y < subpos.w * (-1.0 + info.z) + antialiasing) {\n opacity = min(opacity, smoothstep(-antialiasing, antialiasing, subpos.y - subpos.w * (-1.0 + info.z)));\n }\n }\n if (opacity == 0.0) {\n if (debug) {\n color.r = 253.0 / 255.0;\n gl_FragColor = color;\n return;\n }\n discard;\n }\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},9923:function(t){t.exports="/* markerFeature square/triangle fragment shader */\n\n/* markerFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n// the square/triangle shader defines unitVar\nconst int symbolEllipse = 0;\nconst int symbolFlowerBase = 1;\nconst int symbolFlowerMax = 16;\nconst int symbolTriangle = 16;\nconst int symbolStarBase = 17;\nconst int symbolStarMax = 16;\nconst int symbolRectangle = 32;\nconst int symbolCrossBase = 33;\nconst int symbolCrossMax = 16;\nconst int symbolOval = 48;\nconst int symbolJackBase = 49;\nconst int symbolJackMax = 16;\nconst int symbolDrop = 64;\nconst int symbolDropBase = 65;\nconst int symbolDropMax = 16;\nconst int symbolArrow = 80;\nconst int symbolArrowBase = 81;\nconst int symbolArrowMax = 16;\n// Distance to antialias in pixels\nconst float antialiasDist = 1.5;\n\n/* Compute the distance from a point to an arrow defined by the radiusVar and a\n * packed value containing\n * headWidth: ratio to radius (0, 1]\n * headLength: ratio to diameter (0, 1]\n * stemWidth: ratio to headWidth [0, 1]\n * sweep: boolean\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float packed: the packed value.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToArrow(vec2 pos, float value) {\n bool sweep = value < 0.0;\n value = abs(value);\n float pack0 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack1 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack2 = (mod(value, 252.0) - 1.0) / 250.0;\n\n float headWidth = (pack0 > 0.0 ? pack0 : 2.0 / 3.0);\n float headEnd = 1.0 - 2.0 * (pack1 > 0.0 ? pack1 : 1.0 / 2.0);\n float stemWidth = headWidth * (pack2 >= 0.0 ? pack2 : 1.0 / 3.0);\n if (length(vec2(headWidth, headEnd)) > 1.0) {\n vec2 scaledHead = normalize(vec2(headWidth, headEnd));\n headWidth = scaledHead.x;\n headEnd = scaledHead.y;\n }\n float stemEnd = -cos(asin(stemWidth));\n\n headWidth *= radiusVar;\n headEnd *= radiusVar;\n stemWidth *= radiusVar;\n stemEnd *= radiusVar;\n pos.y = abs(pos.y);\n float stemDist = pos.y - stemWidth;\n float stemEndDist = stemEnd - pos.x;\n float B = (radiusVar - headEnd) / headWidth;\n float headDist = (pos.x + B * pos.y - radiusVar) / sqrt(1.0 + B * B);\n float headEndDist;\n if (sweep) {\n B = (radiusVar - headEnd) / 3.0 / headWidth;\n headEndDist = -(pos.x + B * pos.y - (radiusVar + headEnd * 2.0) / 3.0) / sqrt(1.0 + B * B);\n } else {\n headEndDist = headEnd - pos.x;\n }\n headEndDist = min(headEndDist, stemDist);\n return max(max(headDist, headEndDist), stemEndDist);\n}\n\n/* Compute the distance from a point to a drop defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major radii).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToDrop(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float r = radiusVar * ratio;\n float cx = radiusVar - r;\n float rad = distance(pos.xy, vec2(cx, 0.0)) - r;\n if (ratio < 0.5) {\n float x = radiusVar - r - r * r / cx;\n float y = sqrt(r * r - (cx - x) * (cx - x));\n float Bt = (cx - x) / y;\n if ((pos.x + Bt * abs(pos.y) - cx) / sqrt(1.0 + Bt * Bt) < 0.0) {\n float B = -x / y;\n return -(pos.x + B * abs(pos.y)) / sqrt(1.0 + B * B);\n }\n }\n return rad;\n}\n\n/* Compute the distance from a point to the ellipse defined by the radiusVar\n * (the semimajor axis) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the ellipse in pixels. Negative is\n * inside.\n */\nfloat distanceToEllipse(vec2 pos, float ratio) {\n // a and b are the semi-major and semi-minor axes\n // ratio is the between the minor and major axes. If > 1, swap these and\n // rotate 90 degrees.\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n float a = radiusVar, b = abs(radiusVar * ratio);\n if (b > a) {\n pos = vec2(pos.y, -pos.x);\n b = abs(radiusVar / ratio);\n }\n float a2 = a * a, b2 = b * b;\n // compute the distance to the ellipse. See this discussion:\n // https://stackoverflow.com/questions/22959698\n float f = sqrt(a2 - b2),\n // this value will be positive if outside and negative if inside. If\n // we used it directly, the stroke would be too thick along the long\n // edges of the ellipse\n d = (distance(pos, vec2(f, 0.0)) + distance(pos, vec2(-f, 0.0))) * 0.5 - a;\n // if we are outside of the ellipse, accuracy is not important, so return\n // early.\n if (d >= 0.0) {\n return d;\n }\n // work in one quadrant\n pos = abs(pos);\n // t (the angle from center) could start as `atan(pos.y, pos.x)`, but this\n // results in a slower solution near narrow ends\n float t = 0.7;\n float cost = cos(t), sint = sin(t), x = a * cost, y = b * sint;\n vec2 lastxy;\n for (int iter = 0; iter < 10; iter += 1) {\n lastxy = vec2(x, y);\n float ex = (a2 - b2) * pow(cost, 3.0) / a,\n ey = (b2 - a2) * pow(sint, 3.0) / b;\n vec2 r = vec2(x - ex, y - ey),\n q = vec2(pos.x - ex, pos.y - ey);\n float lenr = length(r);\n t += lenr * asin((r.x * q.y - r.y * q.x) / lenr / length(q)) / sqrt(a2 + b2 - x * x - y * y);\n t = clamp(t, 0.0, acos(0.0));\n cost = cos(t);\n sint = sin(t);\n x = a * cost;\n y = b * sint;\n if (distance(lastxy, vec2(x, y)) < 0.05) {\n break;\n }\n }\n return sign(d) * distance(pos, vec2(x, y));\n}\n\n/* Compute the distance from a point to an isosceles triangle.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: length of the base compared to the other sides.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToIsoscelesTriangle(vec2 pos, float ratio) {\n ratio = clamp(abs(ratio), 0.0, 2.0);\n if (ratio == 0.0 || ratio == 2.0) {\n ratio = 1.0;\n }\n float s1, s2, x0, x1, y1;\n if (ratio < sqrt(2.0)) {\n s1 = radiusVar * sqrt(4.0 - ratio * ratio); // length of equal sides\n s2 = s1 * ratio;\n y1 = s2 / 2.0;\n x0 = radiusVar;\n x1 = x0 - sqrt(s1 * s1 - y1 * y1);\n } else {\n s2 = radiusVar * 2.0;\n s1 = s2 / ratio;\n y1 = s2 / 2.0;\n x0 = sqrt(s1 * s1 - y1 * y1);\n x1 = 0.0;\n }\n float B = (x0 - x1) / y1;\n return max(x1 - pos.x, (pos.x + B * abs(pos.y) - x0) / sqrt(1.0 + B * B));\n}\n\n/* Compute the distance from a point to an oval defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major axes). Here an oval\n * is defined as two semicircles connected by straight line segments.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the oval in pixels. Negative is inside.\n */\nfloat distanceToOval(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float minor = radiusVar * ratio;\n float center = radiusVar - minor;\n pos = abs(pos);\n if (pos.x <= center) {\n return pos.y - minor;\n }\n return distance(pos, vec2(center, 0.0)) - minor;\n}\n\n/* Compute the distance from a point to a rectangle defined by the radiusVar\n * (the semidiagonal) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToRectangle(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n vec2 wh = normalize(vec2(1.0, abs(ratio))) * radiusVar;\n vec2 dist = abs(pos) - wh;\n return max(dist.x, dist.y);\n}\n\n/* Based on a repetition value, return a position for rotational symmetry.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * int repetitions: number of repetitions on the cross.\n * Exit: float dist: a point in the primary position.\n */\nvec2 rotationalSymmetry(vec2 pos, int repetitions) {\n float pi = acos(-1.0);\n float limit = pi / float(repetitions);\n float ang = atan(pos.y, pos.x);\n ang = mod(ang + pi * 2.0, limit * 2.0);\n if (ang > limit) {\n ang -= limit * 2.0;\n }\n return vec2(cos(ang), sin(ang)) * length(pos);\n}\n\nvoid markerFeatureFragment(vec2 pos) {\n // rad is a value in pixels from the edge of the symbol where negative is\n // inside the shape\n float rad = length(pos.xy) - radiusVar;\n // never allow points outside of the main radius\n if (rad > 0.0) {\n discard;\n return;\n }\n // apply clockwise rotation\n if (rotationVar != 0.0) {\n float cosr = cos(rotationVar), sinr = sin(rotationVar);\n pos = vec2(pos.x * cosr + pos.y * sinr, -pos.x * sinr + pos.y * cosr);\n }\n\n int symbol = int(floor(symbolVar / 64.0));\n bool isimage = bool(mod(floor(symbolVar / 8.0), 2.0));\n vec4 fillColor, strokeColor;\n float endStep;\n\n float ratio = symbolValueVar;\n // When ratio is 0, it usually gets changed to 1; some shapes could have\n // better defaults\n /* Symbol shapes */\n if (symbol == symbolTriangle) {\n rad = distanceToIsoscelesTriangle(pos, ratio);\n } else if (symbol == symbolRectangle) {\n rad = distanceToRectangle(pos, ratio);\n } else if (symbol == symbolOval) {\n rad = distanceToOval(pos, ratio);\n } else if (symbol == symbolDrop) {\n rad = distanceToDrop(pos, ratio);\n } else if (symbol == symbolArrow) {\n rad = distanceToArrow(pos, ratio);\n } else if (symbol >= symbolCrossBase && symbol <= symbolCrossBase + symbolCrossMax - 2) {\n rad = distanceToRectangle(rotationalSymmetry(pos, symbol - symbolCrossBase + 2), ratio);\n } else if (symbol >= symbolFlowerBase && symbol <= symbolFlowerBase + symbolFlowerMax - 2) {\n rad = distanceToEllipse(rotationalSymmetry(pos, symbol - symbolFlowerBase + 2), ratio);\n } else if (symbol >= symbolStarBase && symbol <= symbolStarBase + symbolStarMax - 2) {\n rad = distanceToIsoscelesTriangle(rotationalSymmetry(pos, symbol - symbolStarBase + 2), ratio);\n } else if (symbol >= symbolJackBase && symbol <= symbolJackBase + symbolJackMax - 2) {\n rad = distanceToOval(rotationalSymmetry(pos, symbol - symbolJackBase + 2), ratio);\n } else if (symbol >= symbolDropBase && symbol <= symbolDropBase + symbolDropMax - 2) {\n rad = distanceToDrop(rotationalSymmetry(pos, symbol - symbolDropBase + 2), ratio);\n } else if (symbol >= symbolArrowBase && symbol <= symbolArrowBase + symbolArrowMax - 2) {\n rad = distanceToArrow(rotationalSymmetry(pos, symbol - symbolArrowBase + 2), ratio);\n } else { // default - circle or ellipse; a value of 0 or 1 is a circle\n if (ratio != 0.0 && ratio != 1.0) {\n rad = distanceToEllipse(pos, ratio);\n }\n }\n\n if (rad >= 0.0) {\n discard;\n return;\n }\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0 || strokeWidthVar <= 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 0.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = -strokeWidthVar;\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0) {\n fillColor = vec4(strokeColorVar.rgb, 0.0);\n } else {\n fillColor = fillColorVar;\n }\n if (rad <= endStep) {\n float step = smoothstep(endStep - antialiasDist, endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\nvarying vec2 unitVar; // distinct for square/triangle\n\nvoid main() {\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n markerFeatureFragment(unitVar);\n}\n"},1202:function(t){t.exports="/* markerFeature square/triangle vertex shader */\n\n/* markerFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\nattribute float symbol; /* contains some bit fields */\nattribute float symbolValue;\nattribute float rotation;\nuniform float zoom;\nuniform float rotationUniform;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\n// non-sprite has other definitions.\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n\nfloat markerFeaturePrep(void)\n{\n // No stroke or fill implies nothing to draw\n if (radius <= 0.0 || (strokeOpacity <= 0.0 && fillOpacity <= 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return 0.0;\n }\n radiusVar = radius;\n strokeWidthVar = strokeWidth;\n int scaleMode = int(mod(symbol, 4.0));\n float strokeOffset = mod(floor(symbol / 16.0), 4.0) - 1.0;\n radiusVar += (strokeOffset + 1.0) / 2.0 * strokeWidthVar;\n if (scaleMode == 1) { // fill\n radiusVar = (radiusVar - strokeWidthVar) * exp2(zoom) + strokeWidthVar;\n } else if (scaleMode == 2) { // stroke\n radiusVar += strokeWidthVar * (exp2(zoom) - 1.0);\n strokeWidthVar *= exp2(zoom);\n } else if (scaleMode == 3) { // all\n radiusVar *= exp2(zoom);\n strokeWidthVar *= exp2(zoom);\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n symbolVar = symbol;\n symbolValueVar = symbolValue;\n rotationVar = rotation;\n if (bool(mod(floor(symbolVar / 4.0), 2.0))) {\n rotationVar += rotationUniform;\n }\n return radiusVar;\n}\n\n\nuniform float pixelWidth; // for non-sprite\nuniform float aspect; // for non-sprite\nattribute vec2 unit; // for non-sprite\nvarying vec2 unitVar; // for non-sprite\n\nvoid main(void)\n{\n radiusVar = markerFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for non-sprite\n unitVar = unit * radiusVar;\n unitVar.y *= -1.0;\n vec4 p = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n if (p.w != 0.0) {\n p = p / p.w;\n }\n p += radiusVar * vec4(unit.x * pixelWidth, unit.y * pixelWidth * aspect, 0.0, 1.0);\n gl_Position = vec4(p.xyz, 1.0);\n}\n"},3724:function(t){t.exports="/* markerFeature sprite fragment shader */\n\n/* markerFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n// the square/triangle shader defines unitVar\nconst int symbolEllipse = 0;\nconst int symbolFlowerBase = 1;\nconst int symbolFlowerMax = 16;\nconst int symbolTriangle = 16;\nconst int symbolStarBase = 17;\nconst int symbolStarMax = 16;\nconst int symbolRectangle = 32;\nconst int symbolCrossBase = 33;\nconst int symbolCrossMax = 16;\nconst int symbolOval = 48;\nconst int symbolJackBase = 49;\nconst int symbolJackMax = 16;\nconst int symbolDrop = 64;\nconst int symbolDropBase = 65;\nconst int symbolDropMax = 16;\nconst int symbolArrow = 80;\nconst int symbolArrowBase = 81;\nconst int symbolArrowMax = 16;\n// Distance to antialias in pixels\nconst float antialiasDist = 1.5;\n\n/* Compute the distance from a point to an arrow defined by the radiusVar and a\n * packed value containing\n * headWidth: ratio to radius (0, 1]\n * headLength: ratio to diameter (0, 1]\n * stemWidth: ratio to headWidth [0, 1]\n * sweep: boolean\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float packed: the packed value.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToArrow(vec2 pos, float value) {\n bool sweep = value < 0.0;\n value = abs(value);\n float pack0 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack1 = (mod(value, 252.0) - 1.0) / 250.0;\n value = floor(value / 252.0);\n float pack2 = (mod(value, 252.0) - 1.0) / 250.0;\n\n float headWidth = (pack0 > 0.0 ? pack0 : 2.0 / 3.0);\n float headEnd = 1.0 - 2.0 * (pack1 > 0.0 ? pack1 : 1.0 / 2.0);\n float stemWidth = headWidth * (pack2 >= 0.0 ? pack2 : 1.0 / 3.0);\n if (length(vec2(headWidth, headEnd)) > 1.0) {\n vec2 scaledHead = normalize(vec2(headWidth, headEnd));\n headWidth = scaledHead.x;\n headEnd = scaledHead.y;\n }\n float stemEnd = -cos(asin(stemWidth));\n\n headWidth *= radiusVar;\n headEnd *= radiusVar;\n stemWidth *= radiusVar;\n stemEnd *= radiusVar;\n pos.y = abs(pos.y);\n float stemDist = pos.y - stemWidth;\n float stemEndDist = stemEnd - pos.x;\n float B = (radiusVar - headEnd) / headWidth;\n float headDist = (pos.x + B * pos.y - radiusVar) / sqrt(1.0 + B * B);\n float headEndDist;\n if (sweep) {\n B = (radiusVar - headEnd) / 3.0 / headWidth;\n headEndDist = -(pos.x + B * pos.y - (radiusVar + headEnd * 2.0) / 3.0) / sqrt(1.0 + B * B);\n } else {\n headEndDist = headEnd - pos.x;\n }\n headEndDist = min(headEndDist, stemDist);\n return max(max(headDist, headEndDist), stemEndDist);\n}\n\n/* Compute the distance from a point to a drop defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major radii).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the drop in pixels. Negative is inside.\n */\nfloat distanceToDrop(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float r = radiusVar * ratio;\n float cx = radiusVar - r;\n float rad = distance(pos.xy, vec2(cx, 0.0)) - r;\n if (ratio < 0.5) {\n float x = radiusVar - r - r * r / cx;\n float y = sqrt(r * r - (cx - x) * (cx - x));\n float Bt = (cx - x) / y;\n if ((pos.x + Bt * abs(pos.y) - cx) / sqrt(1.0 + Bt * Bt) < 0.0) {\n float B = -x / y;\n return -(pos.x + B * abs(pos.y)) / sqrt(1.0 + B * B);\n }\n }\n return rad;\n}\n\n/* Compute the distance from a point to the ellipse defined by the radiusVar\n * (the semimajor axis) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the ellipse in pixels. Negative is\n * inside.\n */\nfloat distanceToEllipse(vec2 pos, float ratio) {\n // a and b are the semi-major and semi-minor axes\n // ratio is the between the minor and major axes. If > 1, swap these and\n // rotate 90 degrees.\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n float a = radiusVar, b = abs(radiusVar * ratio);\n if (b > a) {\n pos = vec2(pos.y, -pos.x);\n b = abs(radiusVar / ratio);\n }\n float a2 = a * a, b2 = b * b;\n // compute the distance to the ellipse. See this discussion:\n // https://stackoverflow.com/questions/22959698\n float f = sqrt(a2 - b2),\n // this value will be positive if outside and negative if inside. If\n // we used it directly, the stroke would be too thick along the long\n // edges of the ellipse\n d = (distance(pos, vec2(f, 0.0)) + distance(pos, vec2(-f, 0.0))) * 0.5 - a;\n // if we are outside of the ellipse, accuracy is not important, so return\n // early.\n if (d >= 0.0) {\n return d;\n }\n // work in one quadrant\n pos = abs(pos);\n // t (the angle from center) could start as `atan(pos.y, pos.x)`, but this\n // results in a slower solution near narrow ends\n float t = 0.7;\n float cost = cos(t), sint = sin(t), x = a * cost, y = b * sint;\n vec2 lastxy;\n for (int iter = 0; iter < 10; iter += 1) {\n lastxy = vec2(x, y);\n float ex = (a2 - b2) * pow(cost, 3.0) / a,\n ey = (b2 - a2) * pow(sint, 3.0) / b;\n vec2 r = vec2(x - ex, y - ey),\n q = vec2(pos.x - ex, pos.y - ey);\n float lenr = length(r);\n t += lenr * asin((r.x * q.y - r.y * q.x) / lenr / length(q)) / sqrt(a2 + b2 - x * x - y * y);\n t = clamp(t, 0.0, acos(0.0));\n cost = cos(t);\n sint = sin(t);\n x = a * cost;\n y = b * sint;\n if (distance(lastxy, vec2(x, y)) < 0.05) {\n break;\n }\n }\n return sign(d) * distance(pos, vec2(x, y));\n}\n\n/* Compute the distance from a point to an isosceles triangle.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: length of the base compared to the other sides.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToIsoscelesTriangle(vec2 pos, float ratio) {\n ratio = clamp(abs(ratio), 0.0, 2.0);\n if (ratio == 0.0 || ratio == 2.0) {\n ratio = 1.0;\n }\n float s1, s2, x0, x1, y1;\n if (ratio < sqrt(2.0)) {\n s1 = radiusVar * sqrt(4.0 - ratio * ratio); // length of equal sides\n s2 = s1 * ratio;\n y1 = s2 / 2.0;\n x0 = radiusVar;\n x1 = x0 - sqrt(s1 * s1 - y1 * y1);\n } else {\n s2 = radiusVar * 2.0;\n s1 = s2 / ratio;\n y1 = s2 / 2.0;\n x0 = sqrt(s1 * s1 - y1 * y1);\n x1 = 0.0;\n }\n float B = (x0 - x1) / y1;\n return max(x1 - pos.x, (pos.x + B * abs(pos.y) - x0) / sqrt(1.0 + B * B));\n}\n\n/* Compute the distance from a point to an oval defined by the radiusVar (the\n * semimajor axis) and ratio (between the minor and major axes). Here an oval\n * is defined as two semicircles connected by straight line segments.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the oval in pixels. Negative is inside.\n */\nfloat distanceToOval(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0 || ratio >= 1.0) {\n ratio = 1.0;\n }\n float minor = radiusVar * ratio;\n float center = radiusVar - minor;\n pos = abs(pos);\n if (pos.x <= center) {\n return pos.y - minor;\n }\n return distance(pos, vec2(center, 0.0)) - minor;\n}\n\n/* Compute the distance from a point to a rectangle defined by the radiusVar\n * (the semidiagonal) and ratio (between the minor and major axes).\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * float ratio: ratio of minor / major axes.\n * Exit: float dist: the distance to the rectangle in pixels. Negative is\n * inside.\n */\nfloat distanceToRectangle(vec2 pos, float ratio) {\n ratio = abs(ratio);\n if (ratio == 0.0) {\n ratio = 1.0;\n }\n vec2 wh = normalize(vec2(1.0, abs(ratio))) * radiusVar;\n vec2 dist = abs(pos) - wh;\n return max(dist.x, dist.y);\n}\n\n/* Based on a repetition value, return a position for rotational symmetry.\n *\n * Enter: vec2 pos: the point in pixel coordinates.\n * int repetitions: number of repetitions on the cross.\n * Exit: float dist: a point in the primary position.\n */\nvec2 rotationalSymmetry(vec2 pos, int repetitions) {\n float pi = acos(-1.0);\n float limit = pi / float(repetitions);\n float ang = atan(pos.y, pos.x);\n ang = mod(ang + pi * 2.0, limit * 2.0);\n if (ang > limit) {\n ang -= limit * 2.0;\n }\n return vec2(cos(ang), sin(ang)) * length(pos);\n}\n\nvoid markerFeatureFragment(vec2 pos) {\n // rad is a value in pixels from the edge of the symbol where negative is\n // inside the shape\n float rad = length(pos.xy) - radiusVar;\n // never allow points outside of the main radius\n if (rad > 0.0) {\n discard;\n return;\n }\n // apply clockwise rotation\n if (rotationVar != 0.0) {\n float cosr = cos(rotationVar), sinr = sin(rotationVar);\n pos = vec2(pos.x * cosr + pos.y * sinr, -pos.x * sinr + pos.y * cosr);\n }\n\n int symbol = int(floor(symbolVar / 64.0));\n bool isimage = bool(mod(floor(symbolVar / 8.0), 2.0));\n vec4 fillColor, strokeColor;\n float endStep;\n\n float ratio = symbolValueVar;\n // When ratio is 0, it usually gets changed to 1; some shapes could have\n // better defaults\n /* Symbol shapes */\n if (symbol == symbolTriangle) {\n rad = distanceToIsoscelesTriangle(pos, ratio);\n } else if (symbol == symbolRectangle) {\n rad = distanceToRectangle(pos, ratio);\n } else if (symbol == symbolOval) {\n rad = distanceToOval(pos, ratio);\n } else if (symbol == symbolDrop) {\n rad = distanceToDrop(pos, ratio);\n } else if (symbol == symbolArrow) {\n rad = distanceToArrow(pos, ratio);\n } else if (symbol >= symbolCrossBase && symbol <= symbolCrossBase + symbolCrossMax - 2) {\n rad = distanceToRectangle(rotationalSymmetry(pos, symbol - symbolCrossBase + 2), ratio);\n } else if (symbol >= symbolFlowerBase && symbol <= symbolFlowerBase + symbolFlowerMax - 2) {\n rad = distanceToEllipse(rotationalSymmetry(pos, symbol - symbolFlowerBase + 2), ratio);\n } else if (symbol >= symbolStarBase && symbol <= symbolStarBase + symbolStarMax - 2) {\n rad = distanceToIsoscelesTriangle(rotationalSymmetry(pos, symbol - symbolStarBase + 2), ratio);\n } else if (symbol >= symbolJackBase && symbol <= symbolJackBase + symbolJackMax - 2) {\n rad = distanceToOval(rotationalSymmetry(pos, symbol - symbolJackBase + 2), ratio);\n } else if (symbol >= symbolDropBase && symbol <= symbolDropBase + symbolDropMax - 2) {\n rad = distanceToDrop(rotationalSymmetry(pos, symbol - symbolDropBase + 2), ratio);\n } else if (symbol >= symbolArrowBase && symbol <= symbolArrowBase + symbolArrowMax - 2) {\n rad = distanceToArrow(rotationalSymmetry(pos, symbol - symbolArrowBase + 2), ratio);\n } else { // default - circle or ellipse; a value of 0 or 1 is a circle\n if (ratio != 0.0 && ratio != 1.0) {\n rad = distanceToEllipse(pos, ratio);\n }\n }\n\n if (rad >= 0.0) {\n discard;\n return;\n }\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0 || strokeWidthVar <= 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 0.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = -strokeWidthVar;\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0) {\n fillColor = vec4(strokeColorVar.rgb, 0.0);\n } else {\n fillColor = fillColorVar;\n }\n if (rad <= endStep) {\n float step = smoothstep(endStep - antialiasDist, endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(-antialiasDist, 0.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\n// the square/triangle shader defines unitVar\n\nvoid main(void) {\n // No stroke or fill implies nothing to draw\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n // for sprites, convert the position to [-radius,radius],[-radius,radius]\n vec2 pos = (gl_PointCoord.xy - 0.5) * 2.0 * radiusVar;\n markerFeatureFragment(pos);\n}\n"},7665:function(t){t.exports="/* markerFeature sprite vertex shader */\n\n/* markerFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nattribute vec3 strokeColor;\nattribute float strokeOpacity;\nattribute float strokeWidth;\nattribute float symbol; /* contains some bit fields */\nattribute float symbolValue;\nattribute float rotation;\nuniform float zoom;\nuniform float rotationUniform;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\n// non-sprite has other definitions.\nvarying float radiusVar;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float strokeWidthVar;\nvarying float symbolVar; /* contains some bit fields */\nvarying float symbolValueVar;\nvarying float rotationVar;\n\nfloat markerFeaturePrep(void)\n{\n // No stroke or fill implies nothing to draw\n if (radius <= 0.0 || (strokeOpacity <= 0.0 && fillOpacity <= 0.0)) {\n gl_Position = vec4(2.0, 2.0, 0.0, 1.0);\n return 0.0;\n }\n radiusVar = radius;\n strokeWidthVar = strokeWidth;\n int scaleMode = int(mod(symbol, 4.0));\n float strokeOffset = mod(floor(symbol / 16.0), 4.0) - 1.0;\n radiusVar += (strokeOffset + 1.0) / 2.0 * strokeWidthVar;\n if (scaleMode == 1) { // fill\n radiusVar = (radiusVar - strokeWidthVar) * exp2(zoom) + strokeWidthVar;\n } else if (scaleMode == 2) { // stroke\n radiusVar += strokeWidthVar * (exp2(zoom) - 1.0);\n strokeWidthVar *= exp2(zoom);\n } else if (scaleMode == 3) { // all\n radiusVar *= exp2(zoom);\n strokeWidthVar *= exp2(zoom);\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n symbolVar = symbol;\n symbolValueVar = symbolValue;\n rotationVar = rotation;\n if (bool(mod(floor(symbolVar / 4.0), 2.0))) {\n rotationVar += rotationUniform;\n }\n return radiusVar;\n}\n\n\nvoid main(void)\n{\n radiusVar = markerFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for sprite\n gl_Position = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n gl_PointSize = 2.0 * radiusVar;\n}\n"},428:function(t){t.exports="/* contourFeature fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nuniform vec4 minColor;\nuniform vec4 maxColor;\nuniform float steps;\nuniform bool stepped;\nuniform sampler2D sampler2d;\nvarying float valueVar;\nvarying float opacityVar;\n\nvoid main () {\n vec4 clr;\n if (valueVar < 0.0) {\n clr = minColor;\n } else if (valueVar > steps) {\n clr = maxColor;\n } else {\n float step;\n if (stepped) {\n step = floor(valueVar) + 0.5;\n if (step > steps) {\n step = steps - 0.5;\n }\n } else {\n step = valueVar + 0.5;\n }\n // our texture is padded on either end by a repeated value to ensure\n // we interpolate smoothly at the ends.\n clr = texture2D(sampler2d, vec2((step + 1.0) / (steps + 2.0), 0.0));\n }\n gl_FragColor = vec4(clr.rgb, clr.a * opacityVar);\n}\n"},4993:function(t){t.exports="/* contourFeature vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float value;\nattribute float opacity;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying float valueVar;\nvarying float opacityVar;\n\nvoid main(void)\n{\n /* Don't use z values */\n vec4 scrPos = projectionMatrix * modelViewMatrix * vec4(pos.xy, 0, 1);\n if (scrPos.w != 0.0) {\n scrPos = scrPos / scrPos.w;\n }\n valueVar = value;\n opacityVar = opacity;\n gl_Position = scrPos;\n}\n"},3925:function(t){t.exports="/* pixelmapFeature fragment shader */\n\nvarying highp vec2 iTextureCoord;\nuniform sampler2D sampler2d;\nuniform sampler2D lutSampler;\nuniform int lutWidth;\nuniform int lutHeight;\nuniform mediump float opacity;\nuniform highp vec2 crop;\n\nvoid main(void) {\n if ((crop.s < 1.0 && iTextureCoord.s > crop.s) || (crop.t < 1.0 && 1.0 - iTextureCoord.t > crop.t)) {\n discard;\n }\n // to add anti-aliasing, we would need to know the current pixel size\n // (probably computed in the vertex shader) and then sample the base image at\n // multiple points, then average the output color.\n highp vec4 lutValue = texture2D(sampler2d, iTextureCoord);\n highp vec2 lutCoord;\n lutCoord.s = (\n mod(\n // add 0.5 to handle float imprecision\n floor(lutValue.r * 255.0 + 0.5) +\n floor(lutValue.g * 255.0 + 0.5) * 256.0,\n float(lutWidth)\n // center in pixel\n ) + 0.5) / float(lutWidth);\n // Our image is top-down, so invert the coordinate\n lutCoord.t = 1.0 - (\n floor(\n (\n // add 0.5 to handle float imprecision\n floor(lutValue.r * 255.0 + 0.5) +\n floor(lutValue.g * 255.0 + 0.5) * 256.0 +\n floor(lutValue.b * 255.0 + 0.5) * 256.0 * 256.0\n // We may want an option to use the alpha channel to allow more indices\n ) / float(lutWidth)\n // center in pixel\n ) + 0.5) / float(lutHeight);\n if (lutCoord.t < 0.0) {\n discard;\n }\n mediump vec4 color = texture2D(lutSampler, lutCoord);\n\n color.a *= opacity;\n gl_FragColor = color;\n}\n"},4317:function(t){t.exports="/* pointFeature square/triangle fragment shader */\n\n/* pointFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nvoid pointFeatureFragment(float rad) {\n vec4 strokeColor, fillColor;\n float endStep;\n // No stroke or fill implies nothing to draw\n if (rad > 1.0)\n discard;\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 1.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = radiusVar / (radiusVar + strokeWidthVar);\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0)\n fillColor = vec4(strokeColor.rgb, 0.0);\n else\n fillColor = fillColorVar;\n // Distance to antialias over. First number is in pixels\n float antialiasDist = 1.5 / (radiusVar + strokeWidthVar);\n if (rad < endStep) {\n float step = smoothstep(max(0.0, endStep - antialiasDist), endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\nvarying vec3 unitVar; // distinct for square/triangle\n\nvoid main () {\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n float rad = length(unitVar.xy); // distinct for square/triangle\n pointFeatureFragment(rad);\n}\n"},8208:function(t){t.exports="/* pointFeature square/triangle vertex shader */\n\n/* pointFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute vec3 strokeColor;\nattribute float fillOpacity;\nattribute float strokeWidth;\nattribute float strokeOpacity;\nattribute float fill;\nattribute float stroke;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nfloat pointFeaturePrep() {\n strokeWidthVar = strokeWidth;\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // No stroke or fill implies nothing to draw\n if (stroke < 1.0 || strokeWidth <= 0.0 || strokeOpacity <= 0.0) {\n strokeColorVar.a = 0.0;\n strokeWidthVar = 0.0;\n }\n if (fill < 1.0 || radius <= 0.0 || fillOpacity <= 0.0)\n fillColorVar.a = 0.0;\n /* If the point has no visible pixels, skip doing computations on it. */\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0) {\n gl_Position = vec4(2, 2, 0, 1);\n return 0.0;\n }\n return radius;\n}\n\n\nuniform float pixelWidth; // for non-sprite\nuniform float aspect; // for non-sprite\nattribute vec2 unit; // for non-sprite\nvarying vec3 unitVar; // for non-sprite\n\nvoid main(void)\n{\n radiusVar = pointFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for non-sprite\n unitVar = vec3(unit, 1.0);\n vec4 p = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n if (p.w != 0.0) {\n p = p / p.w;\n }\n p += (radius + strokeWidthVar) *\n vec4(unit.x * pixelWidth, unit.y * pixelWidth * aspect, 0.0, 1.0);\n gl_Position = vec4(p.xyz, 1.0);\n}\n"},2682:function(t){t.exports="/* pointFeature sprite fragment shader */\n\n/* pointFeature common fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nvoid pointFeatureFragment(float rad) {\n vec4 strokeColor, fillColor;\n float endStep;\n // No stroke or fill implies nothing to draw\n if (rad > 1.0)\n discard;\n // If there is no stroke, the fill region should transition to nothing\n if (strokeColorVar.a == 0.0) {\n strokeColor = vec4(fillColorVar.rgb, 0.0);\n endStep = 1.0;\n } else {\n strokeColor = strokeColorVar;\n endStep = radiusVar / (radiusVar + strokeWidthVar);\n }\n // Likewise, if there is no fill, the stroke should transition to nothing\n if (fillColorVar.a == 0.0)\n fillColor = vec4(strokeColor.rgb, 0.0);\n else\n fillColor = fillColorVar;\n // Distance to antialias over. First number is in pixels\n float antialiasDist = 1.5 / (radiusVar + strokeWidthVar);\n if (rad < endStep) {\n float step = smoothstep(max(0.0, endStep - antialiasDist), endStep, rad);\n vec4 color = mix(fillColor, strokeColor, step);\n float step2 = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(color, vec4(color.rgb, 0.0), step2);\n } else {\n float step = smoothstep(max(0.0, 1.0 - antialiasDist), 1.0, rad);\n gl_FragColor = mix(strokeColor, vec4(strokeColor.rgb, 0.0), step);\n }\n}\n\n\n// the square/triangle shader defines unitVar\n\nvoid main () {\n // No stroke or fill implies nothing to draw\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0)\n discard;\n float rad = 2.0 * length(gl_PointCoord - vec2(0.5)); // distinct for sprite\n pointFeatureFragment(rad);\n}\n"},6979:function(t){t.exports="/* pointFeature sprite vertex shader */\n\n/* pointFeature common vertex shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nattribute vec3 pos;\nattribute float radius;\nattribute vec3 fillColor;\nattribute vec3 strokeColor;\nattribute float fillOpacity;\nattribute float strokeWidth;\nattribute float strokeOpacity;\nattribute float fill;\nattribute float stroke;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\nvarying vec4 strokeColorVar;\nvarying float radiusVar;\nvarying float strokeWidthVar;\n\nfloat pointFeaturePrep() {\n strokeWidthVar = strokeWidth;\n fillColorVar = vec4(fillColor, fillOpacity);\n strokeColorVar = vec4(strokeColor, strokeOpacity);\n // No stroke or fill implies nothing to draw\n if (stroke < 1.0 || strokeWidth <= 0.0 || strokeOpacity <= 0.0) {\n strokeColorVar.a = 0.0;\n strokeWidthVar = 0.0;\n }\n if (fill < 1.0 || radius <= 0.0 || fillOpacity <= 0.0)\n fillColorVar.a = 0.0;\n /* If the point has no visible pixels, skip doing computations on it. */\n if (fillColorVar.a == 0.0 && strokeColorVar.a == 0.0) {\n gl_Position = vec4(2, 2, 0, 1);\n return 0.0;\n }\n return radius;\n}\n\n\nvoid main(void)\n{\n radiusVar = pointFeaturePrep();\n if (radiusVar == 0.0) {\n return;\n }\n // for sprite\n gl_Position = (projectionMatrix * modelViewMatrix * vec4(pos, 1.0)).xyzw;\n gl_PointSize = 2.0 * (radius + strokeWidthVar);\n}\n"},4547:function(t){t.exports="/* polygonFeature fragment shader */\n\n#ifdef GL_ES\n precision highp float;\n#endif\nvarying vec4 fillColorVar;\n\nvoid main () {\n gl_FragColor = fillColorVar;\n}\n"},9506:function(t){t.exports="/* polygonFeature vertex shader */\n\nattribute vec3 pos;\nattribute vec3 fillColor;\nattribute float fillOpacity;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying vec4 fillColorVar;\n\nvoid main(void)\n{\n vec4 clipPos = projectionMatrix * modelViewMatrix * vec4(pos.xyz, 1.0);\n if (clipPos.w != 0.0) {\n clipPos = clipPos/clipPos.w;\n }\n fillColorVar = vec4(fillColor, fillOpacity);\n gl_Position = clipPos;\n}\n"},8961:function(t){t.exports="/* quadFeature Color fragment shader */\n\nvarying mediump vec3 iVertexColor;\nuniform mediump float opacity;\n\nvoid main(void) {\n gl_FragColor = vec4(iVertexColor, opacity);\n}\n"},3260:function(t){t.exports="/* quadFeature Color vertex shader */\n\nattribute vec3 vertexPosition;\nuniform float zOffset;\nuniform vec3 vertexColor;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying mediump vec3 iVertexColor;\n\nvoid main(void) {\n gl_Position = projectionMatrix * modelViewMatrix * vec4(vertexPosition, 1.0);\n gl_Position.z += zOffset;\n iVertexColor = vertexColor;\n}\n"},8711:function(t){t.exports="/* quadFeature Image fragment shader */\n\nvarying highp vec2 iTextureCoord;\nuniform sampler2D sampler2d;\nuniform mediump float opacity;\nuniform highp vec2 crop;\n\nvoid main(void) {\n mediump vec4 color = texture2D(sampler2d, iTextureCoord);\n if ((crop.s < 1.0 && iTextureCoord.s > crop.s) || (crop.t < 1.0 && 1.0 - iTextureCoord.t > crop.t)) {\n discard;\n }\n color.w *= opacity;\n gl_FragColor = color;\n}\n"},6238:function(t){t.exports="/* quadFeature Image vertex shader */\n\nattribute vec3 vertexPosition;\nattribute vec2 textureCoord;\nuniform float zOffset;\nuniform mat4 modelViewMatrix;\nuniform mat4 projectionMatrix;\nvarying highp vec2 iTextureCoord;\nuniform highp vec4 cropsource;\n\nvoid main(void) {\n gl_Position = projectionMatrix * modelViewMatrix * vec4(vertexPosition, 1.0);\n gl_Position.z += zOffset;\n if (cropsource.p > cropsource.s && cropsource.q > cropsource.t && (cropsource.p < 1.0 || cropsource.s > 0.0 || cropsource.q < 1.0 || cropsource.t > 0.0)) {\n iTextureCoord.s = textureCoord.s * (cropsource.p - cropsource.s) + cropsource.s;\n iTextureCoord.t = textureCoord.t * (cropsource.q - cropsource.t) + cropsource.t;\n } else {\n iTextureCoord = textureCoord;\n }\n}\n"},7605:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(632),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},1159:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(7046),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},615:function(t,e,n){"use strict";n.r(e);var r=n(5292),i=n.n(r),o=n(9893),a=n.n(o),s=n(9383),u=n.n(s),l=n(6884),c=n.n(l),f=n(9088),h=n.n(f),d=n(7997),p=n.n(d),m=n(5290),g={};g.styleTagTransform=p(),g.setAttributes=c(),g.insert=u().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=h();i()(m.A,g);e.default=m.A&&m.A.locals?m.A.locals:void 0},5292:function(t){"use strict";var e=[];function n(t){for(var n=-1,r=0;r<e.length;r++)if(e[r].identifier===t){n=r;break}return n}function r(t,r){for(var o={},a=[],s=0;s<t.length;s++){var u=t[s],l=r.base?u[0]+r.base:u[0],c=o[l]||0,f="".concat(l," ").concat(c);o[l]=c+1;var h=n(f),d={css:u[1],media:u[2],sourceMap:u[3],supports:u[4],layer:u[5]};if(-1!==h)e[h].references++,e[h].updater(d);else{var p=i(d,r);r.byIndex=s,e.splice(s,0,{identifier:f,updater:p,references:1})}a.push(f)}return a}function i(t,e){var n=e.domAPI(e);n.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;n.update(t=e)}else n.remove()}}t.exports=function(t,i){var o=r(t=t||[],i=i||{});return function(t){t=t||[];for(var a=0;a<o.length;a++){var s=n(o[a]);e[s].references--}for(var u=r(t,i),l=0;l<o.length;l++){var c=n(o[l]);0===e[c].references&&(e[c].updater(),e.splice(c,1))}o=u}}},9383:function(t){"use strict";var e={};t.exports=function(t,n){var r=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9088:function(t){"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},6884:function(t,e,n){"use strict";t.exports=function(t){var e=n.nc;e&&t.setAttribute("nonce",e)}},9893:function(t){"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(n){!function(t,e,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,i&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),e.styleTagTransform(r,t,e.options)}(e,t,n)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},7997:function(t){"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},5245:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwyN2w4LDBsMCwybC04LDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},8546:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwyN2wzLDBsMCwtM2wyLDBsMCwzbDMsMGwwLDJsLTMsMGwwLDNsLTIsMGwwLC0zbC0zLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},3158:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0yNCwzMmwwLC00YTQsNCwwLDAsMSw4LDBsMCw0bC0yLDBsMCwtNGEyLDIsMCwwLDAsLTQsMGwwLDR6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+Cjwvc3ZnPgo="},9803:function(t){"use strict";t.exports="data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjMyIiBoZWlnaHQ9IjMyIj4KPHBhdGggZD0iTTAsMTFsMTEsMGwwLC0xMWwyLDBsMCwxMWwxMSwwbDAsMmwtMTEsMGwwLDExbC0yLDBsMCwtMTFsLTExLDB6IiBmaWxsPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIwIi8+CjxwYXRoIGQ9Ik0zMiwzMC41OWwtMS40MSwxLjQxbC0yLjEyLC0yLjEybC0yLjEyLDIuMTJsLTEuNDEsLTEuNDFsMi4xMiwtMi4xMmwtMi4xMiwtMi4xMmwxLjQxLC0xLjQxbDIuMTIsMi4xMmwyLjEyLC0yLjEybDEuNDEsMS40MWwtMi4xMiwyLjEyeiIgZmlsbD0iYmxhY2siIHN0cm9rZS13aWR0aD0iMCIvPgo8L3N2Zz4K"},4436:function(e){"use strict";if(void 0===t){var n=new Error("Cannot find module 'vtk.js'");throw n.code="MODULE_NOT_FOUND",n}e.exports=t},9747:function(t,e,n){"use strict";function r(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return i(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){u=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(u)throw a}}}}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function o(t,e){var n,r,i,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:2,s=e&&e.length,l=s?e[0]*o:t.length,c=a(t,0,l,o,!0),f=[];if(!c||c.next===c.prev)return f;if(s&&(c=function(t,e,n,r){for(var i=[],o=0,s=e.length;o<s;o++){var u=a(t,e[o]*r,o<s-1?e[o+1]*r:t.length,r,!1);u===u.next&&(u.steiner=!0),i.push(y(u))}i.sort(d);for(var l=0;l<i.length;l++)n=p(i[l],n);return n}(t,e,c,o)),t.length>80*o){n=1/0,r=1/0;for(var h=-1/0,m=-1/0,g=o;g<l;g+=o){var v=t[g],x=t[g+1];v<n&&(n=v),x<r&&(r=x),v>h&&(h=v),x>m&&(m=x)}i=0!==(i=Math.max(h-n,m-r))?32767/i:0}return u(c,f,o,n,r,i,0),f}function a(t,e,n,r,i){var o;if(i===L(t,e,n,r)>0)for(var a=e;a<n;a+=r)o=k(a/r|0,t[a],t[a+1],o);else for(var s=n-r;s>=e;s-=r)o=k(s/r|0,t[s],t[s+1],o);return o&&w(o,o.next)&&(S(o),o=o.next),o}function s(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!w(r,r.next)&&0!==b(r.prev,r,r.next))r=r.next;else{if(S(r),(r=e=r.prev)===r.next)break;n=!0}}while(n||r!==e);return e}function u(t,e,n,r,i,o,a){if(t){!a&&o&&function(t,e,n,r){var i=t;do{0===i.z&&(i.z=g(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,n=1;do{var r=t,i=void 0;t=null;var o=null;for(e=0;r;){e++;for(var a=r,s=0,u=0;u<n&&(s++,a=a.nextZ);u++);for(var l=n;s>0||l>0&&a;)0!==s&&(0===l||!a||r.z<=a.z)?(i=r,r=r.nextZ,s--):(i=a,a=a.nextZ,l--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;r=a}o.nextZ=null,n*=2}while(e>1)}(i)}(t,r,i,o);for(var d=t;t.prev!==t.next;){var p=t.prev,m=t.next;if(o?c(t,r,i,o):l(t))e.push(p.i,t.i,m.i),S(t),t=m.next,d=m.next;else if((t=m)===d){a?1===a?u(t=f(s(t),e),e,n,r,i,o,2):2===a&&h(t,e,n,r,i,o):u(s(t),e,n,r,i,o,1);break}}}}function l(t){var e=t.prev,n=t,r=t.next;if(b(e,n,r)>=0)return!1;for(var i=e.x,o=n.x,a=r.x,s=e.y,u=n.y,l=r.y,c=Math.min(i,o,a),f=Math.min(s,u,l),h=Math.max(i,o,a),d=Math.max(s,u,l),p=r.next;p!==e;){if(p.x>=c&&p.x<=h&&p.y>=f&&p.y<=d&&x(i,s,o,u,a,l,p.x,p.y)&&b(p.prev,p,p.next)>=0)return!1;p=p.next}return!0}function c(t,e,n,r){var i=t.prev,o=t,a=t.next;if(b(i,o,a)>=0)return!1;for(var s=i.x,u=o.x,l=a.x,c=i.y,f=o.y,h=a.y,d=Math.min(s,u,l),p=Math.min(c,f,h),m=Math.max(s,u,l),y=Math.max(c,f,h),v=g(d,p,e,n,r),_=g(m,y,e,n,r),w=t.prevZ,M=t.nextZ;w&&w.z>=v&&M&&M.z<=_;){if(w.x>=d&&w.x<=m&&w.y>=p&&w.y<=y&&w!==i&&w!==a&&x(s,c,u,f,l,h,w.x,w.y)&&b(w.prev,w,w.next)>=0)return!1;if(w=w.prevZ,M.x>=d&&M.x<=m&&M.y>=p&&M.y<=y&&M!==i&&M!==a&&x(s,c,u,f,l,h,M.x,M.y)&&b(M.prev,M,M.next)>=0)return!1;M=M.nextZ}for(;w&&w.z>=v;){if(w.x>=d&&w.x<=m&&w.y>=p&&w.y<=y&&w!==i&&w!==a&&x(s,c,u,f,l,h,w.x,w.y)&&b(w.prev,w,w.next)>=0)return!1;w=w.prevZ}for(;M&&M.z<=_;){if(M.x>=d&&M.x<=m&&M.y>=p&&M.y<=y&&M!==i&&M!==a&&x(s,c,u,f,l,h,M.x,M.y)&&b(M.prev,M,M.next)>=0)return!1;M=M.nextZ}return!0}function f(t,e){var n=t;do{var r=n.prev,i=n.next.next;!w(r,i)&&M(r,n,n.next,i)&&E(r,i)&&E(i,r)&&(e.push(r.i,n.i,i.i),S(n),S(n.next),n=t=i),n=n.next}while(n!==t);return s(n)}function h(t,e,n,r,i,o){var a=t;do{for(var l=a.next.next;l!==a.prev;){if(a.i!==l.i&&_(a,l)){var c=C(a,l);return a=s(a,a.next),c=s(c,c.next),u(a,e,n,r,i,o,0),void u(c,e,n,r,i,o,0)}l=l.next}a=a.next}while(a!==t)}function d(t,e){var n=t.x-e.x;0===n&&(0===(n=t.y-e.y)&&(n=(t.next.y-t.y)/(t.next.x-t.x)-(e.next.y-e.y)/(e.next.x-e.x)));return n}function p(t,e){var n=function(t,e){var n,r=e,i=t.x,o=t.y,a=-1/0;if(w(t,r))return r;do{if(w(t,r.next))return r.next;if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var s=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(s<=i&&s>a&&(a=s,n=r.x<r.next.x?r:r.next,s===i))return n}r=r.next}while(r!==e);if(!n)return null;var u=n,l=n.x,c=n.y,f=1/0;r=n;do{if(i>=r.x&&r.x>=l&&i!==r.x&&v(o<c?i:a,o,l,c,o<c?a:i,o,r.x,r.y)){var h=Math.abs(o-r.y)/(i-r.x);E(r,t)&&(h<f||h===f&&(r.x>n.x||r.x===n.x&&m(n,r)))&&(n=r,f=h)}r=r.next}while(r!==u);return n}(t,e);if(!n)return e;var r=C(n,t);return s(r,r.next),s(n,n.next)}function m(t,e){return b(t.prev,t,e.prev)<0&&b(e.next,t,t.next)<0}function g(t,e,n,r,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=(t-n)*i|0)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=(e-r)*i|0)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function y(t){var e=t,n=t;do{(e.x<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function v(t,e,n,r,i,o,a,s){return(i-a)*(e-s)>=(t-a)*(o-s)&&(t-a)*(r-s)>=(n-a)*(e-s)&&(n-a)*(o-s)>=(i-a)*(r-s)}function x(t,e,n,r,i,o,a,s){return!(t===a&&e===s)&&v(t,e,n,r,i,o,a,s)}function _(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&M(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(E(t,e)&&E(e,t)&&function(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(b(t.prev,t,e.prev)||b(t,e.prev,e))||w(t,e)&&b(t.prev,t,t.next)>0&&b(e.prev,e,e.next)>0)}function b(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function w(t,e){return t.x===e.x&&t.y===e.y}function M(t,e,n,r){var i=T(b(t,e,n)),o=T(b(t,e,r)),a=T(b(n,r,t)),s=T(b(n,r,e));return i!==o&&a!==s||(!(0!==i||!A(t,n,e))||(!(0!==o||!A(t,r,e))||(!(0!==a||!A(n,t,r))||!(0!==s||!A(n,e,r)))))}function A(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function T(t){return t>0?1:t<0?-1:0}function E(t,e){return b(t.prev,t,t.next)<0?b(t,e,t.next)>=0&&b(t,t.prev,e)>=0:b(t,e,t.prev)<0||b(t,t.next,e)<0}function C(t,e){var n=O(t.i,t.x,t.y),r=O(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function k(t,e,n,r){var i=O(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function S(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function O(t,e,n){return{i:t,x:e,y:n,prev:null,next:null,z:0,prevZ:null,nextZ:null,steiner:!1}}function P(t,e,n,r){var i=e&&e.length,o=i?e[0]*n:t.length,a=Math.abs(L(t,0,o,n));if(i)for(var s=0,u=e.length;s<u;s++){var l=e[s]*n,c=s<u-1?e[s+1]*n:t.length;a-=Math.abs(L(t,l,c,n))}for(var f=0,h=0;h<r.length;h+=3){var d=r[h]*n,p=r[h+1]*n,m=r[h+2]*n;f+=Math.abs((t[d]-t[m])*(t[p+1]-t[d+1])-(t[d]-t[p])*(t[m+1]-t[d+1]))}return 0===a&&0===f?0:Math.abs((f-a)/a)}function L(t,e,n,r){for(var i=0,o=e,a=n-r;o<n;o+=r)i+=(t[a]-t[o])*(t[o+1]+t[a+1]),a=o;return i}function R(t){var e,n=[],i=[],o=t[0][0].length,a=0,s=0,u=r(t);try{for(u.s();!(e=u.n()).done;){var l,c=e.value,f=r(c);try{for(f.s();!(l=f.n()).done;)for(var h=l.value,d=0;d<o;d++)n.push(h[d])}catch(t){f.e(t)}finally{f.f()}s&&(a+=s,i.push(a)),s=c.length}}catch(t){u.e(t)}finally{u.f()}return{vertices:n,holes:i,dimensions:o}}n.r(e),n.d(e,{default:function(){return o},deviation:function(){return P},flatten:function(){return R}})},4279:function(t,e,n){"use strict";function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,s=[],u=!0,l=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=o.call(n)).done)&&(s.push(r.value),s.length!==e);u=!0);}catch(t){l=!0,i=t}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw i}}return s}}(t,e)||function(t,e){if(t){if("string"==typeof t)return o(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function a(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,s(r.key),r)}}function s(t){var e=function(t,e){if("object"!=r(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,e||"default");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==r(e)?e:e+""}n.r(e),n.d(e,{default:function(){return l}});var u=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],l=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:64,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Float64Array,i=arguments.length>3?arguments[3]:void 0;if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),isNaN(e)||e<0)throw new Error("Unpexpected numItems value: ".concat(e,"."));this.numItems=+e,this.nodeSize=Math.min(Math.max(+n,2),65535),this.ArrayType=r,this.IndexArrayType=e<65536?Uint16Array:Uint32Array;var o=u.indexOf(this.ArrayType),a=2*e*this.ArrayType.BYTES_PER_ELEMENT,s=e*this.IndexArrayType.BYTES_PER_ELEMENT,l=(8-s%8)%8;if(o<0)throw new Error("Unexpected typed array class: ".concat(r,"."));i&&i instanceof ArrayBuffer?(this.data=i,this.ids=new this.IndexArrayType(this.data,8,e),this.coords=new this.ArrayType(this.data,8+s+l,2*e),this._pos=2*e,this._finished=!0):(this.data=new ArrayBuffer(8+a+s+l),this.ids=new this.IndexArrayType(this.data,8,e),this.coords=new this.ArrayType(this.data,8+s+l,2*e),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,16+o]),new Uint16Array(this.data,2,1)[0]=n,new Uint32Array(this.data,4,1)[0]=e)}return e=t,r=[{key:"from",value:function(e){if(!(e instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");var n=i(new Uint8Array(e,0,2),2),r=n[0],o=n[1];if(219!==r)throw new Error("Data does not appear to be in a KDBush format.");var a=o>>4;if(1!==a)throw new Error("Got v".concat(a," data when expected v").concat(1,"."));var s=u[15&o];if(!s)throw new Error("Unrecognized array type.");var l=i(new Uint16Array(e,2,1),1)[0];return new t(i(new Uint32Array(e,4,1),1)[0],l,s,e)}}],(n=[{key:"add",value:function(t,e){var n=this._pos>>1;return this.ids[n]=n,this.coords[this._pos++]=t,this.coords[this._pos++]=e,n}},{key:"finish",value:function(){var t=this._pos>>1;if(t!==this.numItems)throw new Error("Added ".concat(t," items when expected ").concat(this.numItems,"."));return c(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}},{key:"range",value:function(t,e,n,r){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var i=this.ids,o=this.coords,a=this.nodeSize,s=[0,i.length-1,0],u=[];s.length;){var l=s.pop()||0,c=s.pop()||0,f=s.pop()||0;if(c-f<=a)for(var h=f;h<=c;h++){var d=o[2*h],p=o[2*h+1];d>=t&&d<=n&&p>=e&&p<=r&&u.push(i[h])}else{var m=f+c>>1,g=o[2*m],y=o[2*m+1];g>=t&&g<=n&&y>=e&&y<=r&&u.push(i[m]),(0===l?t<=g:e<=y)&&(s.push(f),s.push(m-1),s.push(1-l)),(0===l?n>=g:r>=y)&&(s.push(m+1),s.push(c),s.push(1-l))}}return u}},{key:"within",value:function(t,e,n){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var r=this.ids,i=this.coords,o=this.nodeSize,a=[0,r.length-1,0],s=[],u=n*n;a.length;){var l=a.pop()||0,c=a.pop()||0,f=a.pop()||0;if(c-f<=o)for(var h=f;h<=c;h++)p(i[2*h],i[2*h+1],t,e)<=u&&s.push(r[h]);else{var d=f+c>>1,m=i[2*d],g=i[2*d+1];p(m,g,t,e)<=u&&s.push(r[d]),(0===l?t-n<=m:e-n<=g)&&(a.push(f),a.push(d-1),a.push(1-l)),(0===l?t+n>=m:e+n>=g)&&(a.push(d+1),a.push(c),a.push(1-l))}}return s}}])&&a(e.prototype,n),r&&a(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,n,r}();function c(t,e,n,r,i,o){if(!(i-r<=n)){var a=r+i>>1;f(t,e,a,r,i,o),c(t,e,n,r,a-1,1-o),c(t,e,n,a+1,i,1-o)}}function f(t,e,n,r,i,o){for(;i>r;){if(i-r>600){var a=i-r+1,s=n-r+1,u=Math.log(a),l=.5*Math.exp(2*u/3),c=.5*Math.sqrt(u*l*(a-l)/a)*(s-a/2<0?-1:1);f(t,e,n,Math.max(r,Math.floor(n-s*l/a+c)),Math.min(i,Math.floor(n+(a-s)*l/a+c)),o)}var d=e[2*n+o],p=r,m=i;for(h(t,e,r,n),e[2*i+o]>d&&h(t,e,r,i);p<m;){for(h(t,e,p,m),p++,m--;e[2*p+o]<d;)p++;for(;e[2*m+o]>d;)m--}e[2*r+o]===d?h(t,e,r,m):h(t,e,++m,i),m<=n&&(r=m+1),n<=m&&(i=m-1)}}function h(t,e,n,r){d(t,n,r),d(e,2*n,2*r),d(e,2*n+1,2*r+1)}function d(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function p(t,e,n,r){var i=t-n,o=e-r;return i*i+o*o}},7715:function(t,e,n){"use strict";n.r(e),e.default={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},5127:function(t,e,n){"use strict";function r(t,e){return null==t||null==e?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function i(t,e){return null==t||null==e?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function o(t){let e,n,o;function s(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<0?i=e+1:o=e}while(i<o)}return i}return 2!==t.length?(e=r,n=(e,n)=>r(t(e),n),o=(e,n)=>t(e)-n):(e=t===r||t===i?t:a,n=t,o=t),{left:s,center:function(t,e,n=0,r=t.length){const i=s(t,e,n,r-1);return i>n&&o(t[i-1],e)>-o(t[i],e)?i-1:i},right:function(t,r,i=0,o=t.length){if(i<o){if(0!==e(r,r))return o;do{const e=i+o>>>1;n(t[e],r)<=0?i=e+1:o=e}while(i<o)}return i}}}function a(){return 0}function s(t){return null===t?NaN:+t}n.r(e),n.d(e,{Adder:function(){return S},Delaunay:function(){return Xs},FormatSpecifier:function(){return hc},InternMap:function(){return L},InternSet:function(){return R},Node:function(){return Fm},Path:function(){return la},Voronoi:function(){return Vs},ZoomTransform:function(){return XT},active:function(){return po},arc:function(){return PM},area:function(){return zM},areaRadial:function(){return KM},ascending:function(){return r},autoType:function(){return Cu},axisBottom:function(){return xe},axisLeft:function(){return _e},axisRight:function(){return ve},axisTop:function(){return ye},bin:function(){return dt},bisect:function(){return h},bisectCenter:function(){return f},bisectLeft:function(){return c},bisectRight:function(){return l},bisector:function(){return o},blob:function(){return gl},blur:function(){return d},blur2:function(){return p},blurImage:function(){return m},brush:function(){return Go},brushSelection:function(){return Bo},brushX:function(){return Vo},brushY:function(){return qo},buffer:function(){return vl},chord:function(){return ta},chordDirected:function(){return na},chordTranspose:function(){return ea},cluster:function(){return Om},color:function(){return hr},contourDensity:function(){return vs},contours:function(){return cs},count:function(){return _},create:function(){return oM},creator:function(){return Cn},cross:function(){return A},csv:function(){return Ml},csvFormat:function(){return pu},csvFormatBody:function(){return mu},csvFormatRow:function(){return yu},csvFormatRows:function(){return gu},csvFormatValue:function(){return vu},csvParse:function(){return hu},csvParseRows:function(){return du},cubehelix:function(){return ts},cumsum:function(){return T},curveBasis:function(){return jA},curveBasisClosed:function(){return BA},curveBasisOpen:function(){return qA},curveBumpX:function(){return ZM},curveBumpY:function(){return JM},curveBundle:function(){return UA},curveCardinal:function(){return XA},curveCardinalClosed:function(){return QA},curveCardinalOpen:function(){return $A},curveCatmullRom:function(){return tT},curveCatmullRomClosed:function(){return nT},curveCatmullRomOpen:function(){return iT},curveLinear:function(){return DM},curveLinearClosed:function(){return aT},curveMonotoneX:function(){return pT},curveMonotoneY:function(){return mT},curveNatural:function(){return vT},curveStep:function(){return _T},curveStepAfter:function(){return wT},curveStepBefore:function(){return bT},descending:function(){return i},deviation:function(){return C},difference:function(){return $t},disjoint:function(){return Zt},dispatch:function(){return Ee},drag:function(){return tu},dragDisable:function(){return Wn},dragEnable:function(){return Xn},dsv:function(){return wl},dsvFormat:function(){return cu},easeBack:function(){return cl},easeBackIn:function(){return ul},easeBackInOut:function(){return cl},easeBackOut:function(){return ll},easeBounce:function(){return ol},easeBounceIn:function(){return il},easeBounceInOut:function(){return al},easeBounceOut:function(){return ol},easeCircle:function(){return Xu},easeCircleIn:function(){return Hu},easeCircleInOut:function(){return Xu},easeCircleOut:function(){return Wu},easeCubic:function(){return lo},easeCubicIn:function(){return so},easeCubicInOut:function(){return lo},easeCubicOut:function(){return uo},easeElastic:function(){return dl},easeElasticIn:function(){return hl},easeElasticInOut:function(){return pl},easeElasticOut:function(){return dl},easeExp:function(){return Uu},easeExpIn:function(){return qu},easeExpInOut:function(){return Uu},easeExpOut:function(){return Gu},easeLinear:function(){return Su},easePoly:function(){return Du},easePolyIn:function(){return Ru},easePolyInOut:function(){return Du},easePolyOut:function(){return Iu},easeQuad:function(){return Lu},easeQuadIn:function(){return Ou},easeQuadInOut:function(){return Lu},easeQuadOut:function(){return Pu},easeSin:function(){return Bu},easeSinIn:function(){return ju},easeSinInOut:function(){return Bu},easeSinOut:function(){return zu},every:function(){return Ht},extent:function(){return k},fcumsum:function(){return P},filter:function(){return Xt},flatGroup:function(){return q},flatRollup:function(){return G},forceCenter:function(){return Ll},forceCollide:function(){return Hl},forceLink:function(){return Kl},forceManyBody:function(){return rc},forceRadial:function(){return ic},forceSimulation:function(){return nc},forceX:function(){return oc},forceY:function(){return ac},format:function(){return yc},formatDefaultLocale:function(){return wc},formatLocale:function(){return bc},formatPrefix:function(){return vc},formatSpecifier:function(){return fc},fsum:function(){return O},geoAlbers:function(){return Hp},geoAlbersUsa:function(){return Wp},geoArea:function(){return Cf},geoAzimuthalEqualArea:function(){return Yp},geoAzimuthalEqualAreaRaw:function(){return Qp},geoAzimuthalEquidistant:function(){return Zp},geoAzimuthalEquidistantRaw:function(){return $p},geoBounds:function(){return uh},geoCentroid:function(){return _h},geoCircle:function(){return Ph},geoClipAntimeridian:function(){return qh},geoClipCircle:function(){return Gh},geoClipExtent:function(){return $h},geoClipRectangle:function(){return Yh},geoConicConformal:function(){return im},geoConicConformalRaw:function(){return rm},geoConicEqualArea:function(){return Up},geoConicEqualAreaRaw:function(){return Gp},geoConicEquidistant:function(){return um},geoConicEquidistantRaw:function(){return sm},geoContains:function(){return pd},geoDistance:function(){return od},geoEqualEarth:function(){return mm},geoEqualEarthRaw:function(){return pm},geoEquirectangular:function(){return am},geoEquirectangularRaw:function(){return om},geoGnomonic:function(){return ym},geoGnomonicRaw:function(){return gm},geoGraticule:function(){return yd},geoGraticule10:function(){return vd},geoIdentity:function(){return vm},geoInterpolate:function(){return xd},geoLength:function(){return nd},geoMercator:function(){return tm},geoMercatorRaw:function(){return Jp},geoNaturalEarth1:function(){return _m},geoNaturalEarth1Raw:function(){return xm},geoOrthographic:function(){return wm},geoOrthographicRaw:function(){return bm},geoPath:function(){return Ep},geoProjection:function(){return Bp},geoProjectionMutator:function(){return Vp},geoRotation:function(){return kh},geoStereographic:function(){return Am},geoStereographicRaw:function(){return Mm},geoStream:function(){return nf},geoTransform:function(){return Cp},geoTransverseMercator:function(){return Em},geoTransverseMercatorRaw:function(){return Tm},gray:function(){return Ia},greatest:function(){return _t},greatestIndex:function(){return Ft},group:function(){return z},groupSort:function(){return tt},groups:function(){return B},hcl:function(){return Ga},hierarchy:function(){return Lm},histogram:function(){return dt},hsl:function(){return Tr},html:function(){return Ol},image:function(){return Tl},index:function(){return W},indexes:function(){return X},interpolate:function(){return Zr},interpolateArray:function(){return Ur},interpolateBasis:function(){return Pr},interpolateBasisClosed:function(){return Lr},interpolateBlues:function(){return Lw},interpolateBrBG:function(){return Ub},interpolateBuGn:function(){return uw},interpolateBuPu:function(){return cw},interpolateCividis:function(){return Gw},interpolateCool:function(){return Ww},interpolateCubehelix:function(){return $g},interpolateCubehelixDefault:function(){return Uw},interpolateCubehelixLong:function(){return Zg},interpolateDate:function(){return Wr},interpolateDiscrete:function(){return jg},interpolateGnBu:function(){return hw},interpolateGreens:function(){return Iw},interpolateGreys:function(){return Nw},interpolateHcl:function(){return Kg},interpolateHclLong:function(){return Qg},interpolateHsl:function(){return Ug},interpolateHslLong:function(){return Hg},interpolateHue:function(){return zg},interpolateInferno:function(){return rM},interpolateLab:function(){return Wg},interpolateMagma:function(){return nM},interpolateNumber:function(){return Xr},interpolateNumberArray:function(){return qr},interpolateObject:function(){return Kr},interpolateOrRd:function(){return pw},interpolateOranges:function(){return qw},interpolatePRGn:function(){return Wb},interpolatePiYG:function(){return Kb},interpolatePlasma:function(){return iM},interpolatePuBu:function(){return vw},interpolatePuBuGn:function(){return gw},interpolatePuOr:function(){return Yb},interpolatePuRd:function(){return _w},interpolatePurples:function(){return jw},interpolateRainbow:function(){return Kw},interpolateRdBu:function(){return Zb},interpolateRdGy:function(){return tw},interpolateRdPu:function(){return ww},interpolateRdYlBu:function(){return nw},interpolateRdYlGn:function(){return iw},interpolateReds:function(){return Bw},interpolateRgb:function(){return jr},interpolateRgbBasis:function(){return Br},interpolateRgbBasisClosed:function(){return Vr},interpolateRound:function(){return Bg},interpolateSinebow:function(){return Zw},interpolateSpectral:function(){return aw},interpolateString:function(){return $r},interpolateTransformCss:function(){return Ni},interpolateTransformSvg:function(){return Fi},interpolateTurbo:function(){return Jw},interpolateViridis:function(){return eM},interpolateWarm:function(){return Hw},interpolateYlGn:function(){return Ew},interpolateYlGnBu:function(){return Aw},interpolateYlOrBr:function(){return kw},interpolateYlOrRd:function(){return Ow},interpolateZoom:function(){return qg},interrupt:function(){return Oi},intersection:function(){return Jt},interval:function(){return UT},isoFormat:function(){return VT},isoParse:function(){return GT},json:function(){return Cl},lab:function(){return Da},lch:function(){return qa},least:function(){return Dt},leastIndex:function(){return Nt},line:function(){return jM},lineRadial:function(){return XM},link:function(){return rA},linkHorizontal:function(){return iA},linkRadial:function(){return aA},linkVertical:function(){return oA},local:function(){return sM},map:function(){return Kt},matcher:function(){return Le},max:function(){return pt},maxIndex:function(){return mt},mean:function(){return Et},median:function(){return Ct},medianIndex:function(){return kt},merge:function(){return St},min:function(){return gt},minIndex:function(){return yt},mode:function(){return Ot},namespace:function(){return Xe},namespaces:function(){return We},nice:function(){return ft},now:function(){return fi},pack:function(){return ug},packEnclose:function(){return Wm},packSiblings:function(){return ag},pairs:function(){return Pt},partition:function(){return pg},path:function(){return ca},pathRound:function(){return fa},permute:function(){return Y},pie:function(){return qM},piecewise:function(){return Jg},pointRadial:function(){return QM},pointer:function(){return ti},pointers:function(){return lM},polygonArea:function(){return ey},polygonCentroid:function(){return ny},polygonContains:function(){return sy},polygonHull:function(){return ay},polygonLength:function(){return uy},precisionFixed:function(){return Mc},precisionPrefix:function(){return Ac},precisionRound:function(){return Tc},quadtree:function(){return Fl},quantile:function(){return bt},quantileIndex:function(){return Mt},quantileSorted:function(){return wt},quantize:function(){return ty},quickselect:function(){return vt},radialArea:function(){return KM},radialLine:function(){return XM},randomBates:function(){return my},randomBernoulli:function(){return vy},randomBeta:function(){return by},randomBinomial:function(){return wy},randomCauchy:function(){return Ay},randomExponential:function(){return gy},randomGamma:function(){return _y},randomGeometric:function(){return xy},randomInt:function(){return fy},randomIrwinHall:function(){return py},randomLcg:function(){return Oy},randomLogNormal:function(){return dy},randomLogistic:function(){return Ty},randomNormal:function(){return hy},randomPareto:function(){return yy},randomPoisson:function(){return Ey},randomUniform:function(){return cy},randomWeibull:function(){return My},range:function(){return Rt},rank:function(){return It},reduce:function(){return Qt},reverse:function(){return Yt},rgb:function(){return gr},ribbon:function(){return wa},ribbonArrow:function(){return Ma},rollup:function(){return U},rollups:function(){return H},scaleBand:function(){return Dy},scaleDiverging:function(){return Tb},scaleDivergingLog:function(){return Eb},scaleDivergingPow:function(){return kb},scaleDivergingSqrt:function(){return Sb},scaleDivergingSymlog:function(){return Cb},scaleIdentity:function(){return Yy},scaleImplicit:function(){return Ry},scaleLinear:function(){return Qy},scaleLog:function(){return ov},scaleOrdinal:function(){return Iy},scalePoint:function(){return Fy},scalePow:function(){return pv},scaleQuantile:function(){return vv},scaleQuantize:function(){return xv},scaleRadial:function(){return yv},scaleSequential:function(){return vb},scaleSequentialLog:function(){return xb},scaleSequentialPow:function(){return bb},scaleSequentialQuantile:function(){return Mb},scaleSequentialSqrt:function(){return wb},scaleSequentialSymlog:function(){return _b},scaleSqrt:function(){return mv},scaleSymlog:function(){return lv},scaleThreshold:function(){return _v},scaleTime:function(){return pb},scaleUtc:function(){return mb},scan:function(){return jt},schemeAccent:function(){return Lb},schemeBlues:function(){return Pw},schemeBrBG:function(){return Gb},schemeBuGn:function(){return sw},schemeBuPu:function(){return lw},schemeCategory10:function(){return Pb},schemeDark2:function(){return Rb},schemeGnBu:function(){return fw},schemeGreens:function(){return Rw},schemeGreys:function(){return Dw},schemeObservable10:function(){return Ib},schemeOrRd:function(){return dw},schemeOranges:function(){return Vw},schemePRGn:function(){return Hb},schemePaired:function(){return Db},schemePastel1:function(){return Nb},schemePastel2:function(){return Fb},schemePiYG:function(){return Xb},schemePuBu:function(){return yw},schemePuBuGn:function(){return mw},schemePuOr:function(){return Qb},schemePuRd:function(){return xw},schemePurples:function(){return Fw},schemeRdBu:function(){return $b},schemeRdGy:function(){return Jb},schemeRdPu:function(){return bw},schemeRdYlBu:function(){return ew},schemeRdYlGn:function(){return rw},schemeReds:function(){return zw},schemeSet1:function(){return jb},schemeSet2:function(){return zb},schemeSet3:function(){return Bb},schemeSpectral:function(){return ow},schemeTableau10:function(){return Vb},schemeYlGn:function(){return Tw},schemeYlGnBu:function(){return Mw},schemeYlOrBr:function(){return Cw},schemeYlOrRd:function(){return Sw},select:function(){return Vn},selectAll:function(){return cM},selection:function(){return Bn},selector:function(){return ke},selectorAll:function(){return Pe},shuffle:function(){return zt},shuffler:function(){return Bt},some:function(){return Wt},sort:function(){return $},stack:function(){return CT},stackOffsetDiverging:function(){return ST},stackOffsetExpand:function(){return kT},stackOffsetNone:function(){return MT},stackOffsetSilhouette:function(){return OT},stackOffsetWiggle:function(){return PT},stackOrderAppearance:function(){return LT},stackOrderAscending:function(){return IT},stackOrderDescending:function(){return NT},stackOrderInsideOut:function(){return FT},stackOrderNone:function(){return AT},stackOrderReverse:function(){return jT},stratify:function(){return _g},style:function(){return on},subset:function(){return re},sum:function(){return Vt},superset:function(){return ee},svg:function(){return Pl},symbol:function(){return IA},symbolAsterisk:function(){return uA},symbolCircle:function(){return lA},symbolCross:function(){return cA},symbolDiamond:function(){return dA},symbolDiamond2:function(){return pA},symbolPlus:function(){return mA},symbolSquare:function(){return gA},symbolSquare2:function(){return yA},symbolStar:function(){return bA},symbolTimes:function(){return PA},symbolTriangle:function(){return MA},symbolTriangle2:function(){return TA},symbolWye:function(){return OA},symbolX:function(){return PA},symbols:function(){return LA},symbolsFill:function(){return LA},symbolsStroke:function(){return RA},text:function(){return _l},thresholdFreedmanDiaconis:function(){return At},thresholdScott:function(){return Tt},thresholdSturges:function(){return ht},tickFormat:function(){return Xy},tickIncrement:function(){return lt},tickStep:function(){return ct},ticks:function(){return ut},timeDay:function(){return Gv},timeDays:function(){return Uv},timeFormat:function(){return Gx},timeFormatDefaultLocale:function(){return cb},timeFormatLocale:function(){return Vx},timeFriday:function(){return ex},timeFridays:function(){return ux},timeHour:function(){return zv},timeHours:function(){return Bv},timeInterval:function(){return Ov},timeMillisecond:function(){return Pv},timeMilliseconds:function(){return Lv},timeMinute:function(){return Dv},timeMinutes:function(){return Nv},timeMonday:function(){return $v},timeMondays:function(){return ix},timeMonth:function(){return Tx},timeMonths:function(){return Ex},timeParse:function(){return Ux},timeSaturday:function(){return nx},timeSaturdays:function(){return lx},timeSecond:function(){return Rv},timeSeconds:function(){return Iv},timeSunday:function(){return Yv},timeSundays:function(){return rx},timeThursday:function(){return tx},timeThursdays:function(){return sx},timeTickInterval:function(){return Fx},timeTicks:function(){return Nx},timeTuesday:function(){return Zv},timeTuesdays:function(){return ox},timeWednesday:function(){return Jv},timeWednesdays:function(){return ax},timeWeek:function(){return Yv},timeWeeks:function(){return rx},timeYear:function(){return Sx},timeYears:function(){return Ox},timeout:function(){return xi},timer:function(){return pi},timerFlush:function(){return mi},transition:function(){return io},transpose:function(){return qt},tree:function(){return Sg},treemap:function(){return Ig},treemapBinary:function(){return Dg},treemapDice:function(){return dg},treemapResquarify:function(){return Fg},treemapSlice:function(){return Og},treemapSliceDice:function(){return Ng},treemapSquarify:function(){return Rg},tsv:function(){return Al},tsvFormat:function(){return wu},tsvFormatBody:function(){return Mu},tsvFormatRow:function(){return Tu},tsvFormatRows:function(){return Au},tsvFormatValue:function(){return Eu},tsvParse:function(){return _u},tsvParseRows:function(){return bu},union:function(){return ie},unixDay:function(){return Xv},unixDays:function(){return Kv},utcDay:function(){return Hv},utcDays:function(){return Wv},utcFormat:function(){return Hx},utcFriday:function(){return gx},utcFridays:function(){return Mx},utcHour:function(){return Vv},utcHours:function(){return qv},utcMillisecond:function(){return Pv},utcMilliseconds:function(){return Lv},utcMinute:function(){return Fv},utcMinutes:function(){return jv},utcMonday:function(){return hx},utcMondays:function(){return xx},utcMonth:function(){return Cx},utcMonths:function(){return kx},utcParse:function(){return Wx},utcSaturday:function(){return yx},utcSaturdays:function(){return Ax},utcSecond:function(){return Rv},utcSeconds:function(){return Iv},utcSunday:function(){return fx},utcSundays:function(){return vx},utcThursday:function(){return mx},utcThursdays:function(){return wx},utcTickInterval:function(){return Dx},utcTicks:function(){return Ix},utcTuesday:function(){return dx},utcTuesdays:function(){return _x},utcWednesday:function(){return px},utcWednesdays:function(){return bx},utcWeek:function(){return fx},utcWeeks:function(){return vx},utcYear:function(){return Px},utcYears:function(){return Lx},variance:function(){return E},window:function(){return tn},xml:function(){return Sl},zip:function(){return Ut},zoom:function(){return iE},zoomIdentity:function(){return KT},zoomTransform:function(){return QT}});const u=o(r),l=u.right,c=u.left,f=o(s).center;var h=l;function d(t,e){if(!((e=+e)>=0))throw new RangeError("invalid r");let n=t.length;if(!((n=Math.floor(n))>=0))throw new RangeError("invalid length");if(!n||!e)return t;const r=x(e),i=t.slice();return r(t,i,0,n,1),r(i,t,0,n,1),r(t,i,0,n,1),t}const p=g(x),m=g((function(t){const e=x(t);return(t,n,r,i,o)=>{e(t,n,(r<<=2)+0,(i<<=2)+0,o<<=2),e(t,n,r+1,i+1,o),e(t,n,r+2,i+2,o),e(t,n,r+3,i+3,o)}}));function g(t){return function(e,n,r=n){if(!((n=+n)>=0))throw new RangeError("invalid rx");if(!((r=+r)>=0))throw new RangeError("invalid ry");let{data:i,width:o,height:a}=e;if(!((o=Math.floor(o))>=0))throw new RangeError("invalid width");if(!((a=Math.floor(void 0!==a?a:i.length/o))>=0))throw new RangeError("invalid height");if(!o||!a||!n&&!r)return e;const s=n&&t(n),u=r&&t(r),l=i.slice();return s&&u?(y(s,l,i,o,a),y(s,i,l,o,a),y(s,l,i,o,a),v(u,i,l,o,a),v(u,l,i,o,a),v(u,i,l,o,a)):s?(y(s,i,l,o,a),y(s,l,i,o,a),y(s,i,l,o,a)):u&&(v(u,i,l,o,a),v(u,l,i,o,a),v(u,i,l,o,a)),e}}function y(t,e,n,r,i){for(let o=0,a=r*i;o<a;)t(e,n,o,o+=r,1)}function v(t,e,n,r,i){for(let o=0,a=r*i;o<r;++o)t(e,n,o,o+a,r)}function x(t){const e=Math.floor(t);if(e===t)return function(t){const e=2*t+1;return(n,r,i,o,a)=>{if(!((o-=a)>=i))return;let s=t*r[i];const u=a*t;for(let t=i,e=i+u;t<e;t+=a)s+=r[Math.min(o,t)];for(let t=i,l=o;t<=l;t+=a)s+=r[Math.min(o,t+u)],n[t]=s/e,s-=r[Math.max(i,t-u)]}}(t);const n=t-e,r=2*t+1;return(t,i,o,a,s)=>{if(!((a-=s)>=o))return;let u=e*i[o];const l=s*e,c=l+s;for(let t=o,e=o+l;t<e;t+=s)u+=i[Math.min(a,t)];for(let e=o,f=a;e<=f;e+=s)u+=i[Math.min(a,e+l)],t[e]=(u+n*(i[Math.max(o,e-c)]+i[Math.min(a,e+c)]))/r,u-=i[Math.max(o,e-l)]}}function _(t,e){let n=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&++n;else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(i=+i)>=i&&++n}return n}function b(t){return 0|t.length}function w(t){return!(t>0)}function M(t){return"object"!=typeof t||"length"in t?t:Array.from(t)}function A(...t){const e="function"==typeof t[t.length-1]&&function(t){return e=>t(...e)}(t.pop()),n=(t=t.map(M)).map(b),r=t.length-1,i=new Array(r+1).fill(0),o=[];if(r<0||n.some(w))return o;for(;;){o.push(i.map(((e,n)=>t[n][e])));let a=r;for(;++i[a]===n[a];){if(0===a)return e?o.map(e):o;i[a--]=0}}}function T(t,e){var n=0,r=0;return Float64Array.from(t,void 0===e?t=>n+=+t||0:i=>n+=+e(i,r++,t)||0)}function E(t,e){let n,r=0,i=0,o=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(n=e-i,i+=n/++r,o+=n*(e-i));else{let a=-1;for(let s of t)null!=(s=e(s,++a,t))&&(s=+s)>=s&&(n=s-i,i+=n/++r,o+=n*(s-i))}if(r>1)return o/(r-1)}function C(t,e){const n=E(t,e);return n?Math.sqrt(n):n}function k(t,e){let n,r;if(void 0===e)for(const e of t)null!=e&&(void 0===n?e>=e&&(n=r=e):(n>e&&(n=e),r<e&&(r=e)));else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(void 0===n?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}class S{constructor(){this._partials=new Float64Array(32),this._n=0}add(t){const e=this._partials;let n=0;for(let r=0;r<this._n&&r<32;r++){const i=e[r],o=t+i,a=Math.abs(t)<Math.abs(i)?t-(o-i):i-(o-t);a&&(e[n++]=a),t=o}return e[n]=t,this._n=n+1,this}valueOf(){const t=this._partials;let e,n,r,i=this._n,o=0;if(i>0){for(o=t[--i];i>0&&(e=o,n=t[--i],o=e+n,r=n-(o-e),!r););i>0&&(r<0&&t[i-1]<0||r>0&&t[i-1]>0)&&(n=2*r,e=o+n,n==e-o&&(o=e))}return o}}function O(t,e){const n=new S;if(void 0===e)for(let e of t)(e=+e)&&n.add(e);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&n.add(i)}return+n}function P(t,e){const n=new S;let r=-1;return Float64Array.from(t,void 0===e?t=>n.add(+t||0):i=>n.add(+e(i,++r,t)||0))}class L extends Map{constructor(t,e=F){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[e,n]of t)this.set(e,n)}get(t){return super.get(I(this,t))}has(t){return super.has(I(this,t))}set(t,e){return super.set(D(this,t),e)}delete(t){return super.delete(N(this,t))}}class R extends Set{constructor(t,e=F){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const e of t)this.add(e)}has(t){return super.has(I(this,t))}add(t){return super.add(D(this,t))}delete(t){return super.delete(N(this,t))}}function I({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):n}function D({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):(t.set(r,n),n)}function N({_intern:t,_key:e},n){const r=e(n);return t.has(r)&&(n=t.get(r),t.delete(r)),n}function F(t){return null!==t&&"object"==typeof t?t.valueOf():t}function j(t){return t}function z(t,...e){return Q(t,j,j,e)}function B(t,...e){return Q(t,Array.from,j,e)}function V(t,e){for(let n=1,r=e.length;n<r;++n)t=t.flatMap((t=>t.pop().map((([e,n])=>[...t,e,n]))));return t}function q(t,...e){return V(B(t,...e),e)}function G(t,e,...n){return V(H(t,e,...n),n)}function U(t,e,...n){return Q(t,j,e,n)}function H(t,e,...n){return Q(t,Array.from,e,n)}function W(t,...e){return Q(t,j,K,e)}function X(t,...e){return Q(t,Array.from,K,e)}function K(t){if(1!==t.length)throw new Error("duplicate key");return t[0]}function Q(t,e,n,r){return function t(i,o){if(o>=r.length)return n(i);const a=new L,s=r[o++];let u=-1;for(const t of i){const e=s(t,++u,i),n=a.get(e);n?n.push(t):a.set(e,[t])}for(const[e,n]of a)a.set(e,t(n,o));return e(a)}(t,0)}function Y(t,e){return Array.from(e,(e=>t[e]))}function $(t,...e){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");t=Array.from(t);let[n]=e;if(n&&2!==n.length||e.length>1){const r=Uint32Array.from(t,((t,e)=>e));return e.length>1?(e=e.map((e=>t.map(e))),r.sort(((t,n)=>{for(const r of e){const e=J(r[t],r[n]);if(e)return e}}))):(n=t.map(n),r.sort(((t,e)=>J(n[t],n[e])))),Y(t,r)}return t.sort(Z(n))}function Z(t=r){if(t===r)return J;if("function"!=typeof t)throw new TypeError("compare is not a function");return(e,n)=>{const r=t(e,n);return r||0===r?r:(0===t(n,n))-(0===t(e,e))}}function J(t,e){return(null==t||!(t>=t))-(null==e||!(e>=e))||(t<e?-1:t>e?1:0)}function tt(t,e,n){return(2!==e.length?$(U(t,e,n),(([t,e],[n,i])=>r(e,i)||r(t,n))):$(z(t,n),(([t,n],[i,o])=>e(n,o)||r(t,i)))).map((([t])=>t))}var et=Array.prototype,nt=et.slice;et.map;function rt(t){return()=>t}const it=Math.sqrt(50),ot=Math.sqrt(10),at=Math.sqrt(2);function st(t,e,n){const r=(e-t)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=it?10:o>=ot?5:o>=at?2:1;let s,u,l;return i<0?(l=Math.pow(10,-i)/a,s=Math.round(t*l),u=Math.round(e*l),s/l<t&&++s,u/l>e&&--u,l=-l):(l=Math.pow(10,i)*a,s=Math.round(t/l),u=Math.round(e/l),s*l<t&&++s,u*l>e&&--u),u<s&&.5<=n&&n<2?st(t,e,2*n):[s,u,l]}function ut(t,e,n){if(!((n=+n)>0))return[];if((t=+t)===(e=+e))return[t];const r=e<t,[i,o,a]=r?st(e,t,n):st(t,e,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let t=0;t<s;++t)u[t]=(o-t)/-a;else for(let t=0;t<s;++t)u[t]=(o-t)*a;else if(a<0)for(let t=0;t<s;++t)u[t]=(i+t)/-a;else for(let t=0;t<s;++t)u[t]=(i+t)*a;return u}function lt(t,e,n){return st(t=+t,e=+e,n=+n)[2]}function ct(t,e,n){n=+n;const r=(e=+e)<(t=+t),i=r?lt(e,t,n):lt(t,e,n);return(r?-1:1)*(i<0?1/-i:i)}function ft(t,e,n){let r;for(;;){const i=lt(t,e,n);if(i===r||0===i||!isFinite(i))return[t,e];i>0?(t=Math.floor(t/i)*i,e=Math.ceil(e/i)*i):i<0&&(t=Math.ceil(t*i)/i,e=Math.floor(e*i)/i),r=i}}function ht(t){return Math.max(1,Math.ceil(Math.log(_(t))/Math.LN2)+1)}function dt(){var t=j,e=k,n=ht;function r(r){Array.isArray(r)||(r=Array.from(r));var i,o,a,s=r.length,u=new Array(s);for(i=0;i<s;++i)u[i]=t(r[i],i,r);var l=e(u),c=l[0],f=l[1],d=n(u,c,f);if(!Array.isArray(d)){const t=f,n=+d;if(e===k&&([c,f]=ft(c,f,n)),(d=ut(c,f,n))[0]<=c&&(a=lt(c,f,n)),d[d.length-1]>=f)if(t>=f&&e===k){const t=lt(c,f,n);isFinite(t)&&(t>0?f=(Math.floor(f/t)+1)*t:t<0&&(f=(Math.ceil(f*-t)+1)/-t))}else d.pop()}for(var p=d.length,m=0,g=p;d[m]<=c;)++m;for(;d[g-1]>f;)--g;(m||g<p)&&(d=d.slice(m,g),p=g-m);var y,v=new Array(p+1);for(i=0;i<=p;++i)(y=v[i]=[]).x0=i>0?d[i-1]:c,y.x1=i<p?d[i]:f;if(isFinite(a)){if(a>0)for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=f&&v[Math.min(p,Math.floor((o-c)/a))].push(r[i]);else if(a<0)for(i=0;i<s;++i)if(null!=(o=u[i])&&c<=o&&o<=f){const t=Math.floor((c-o)*a);v[Math.min(p,t+(d[t]<=o))].push(r[i])}}else for(i=0;i<s;++i)null!=(o=u[i])&&c<=o&&o<=f&&v[h(d,o,0,p)].push(r[i]);return v}return r.value=function(e){return arguments.length?(t="function"==typeof e?e:rt(e),r):t},r.domain=function(t){return arguments.length?(e="function"==typeof t?t:rt([t[0],t[1]]),r):e},r.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:rt(Array.isArray(t)?nt.call(t):t),r):n},r}function pt(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n<e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n<i||void 0===n&&i>=i)&&(n=i)}return n}function mt(t,e){let n,r=-1,i=-1;if(void 0===e)for(const e of t)++i,null!=e&&(n<e||void 0===n&&e>=e)&&(n=e,r=i);else for(let o of t)null!=(o=e(o,++i,t))&&(n<o||void 0===n&&o>=o)&&(n=o,r=i);return r}function gt(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n>e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function yt(t,e){let n,r=-1,i=-1;if(void 0===e)for(const e of t)++i,null!=e&&(n>e||void 0===n&&e>=e)&&(n=e,r=i);else for(let o of t)null!=(o=e(o,++i,t))&&(n>o||void 0===n&&o>=o)&&(n=o,r=i);return r}function vt(t,e,n=0,r=1/0,i){if(e=Math.floor(e),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(t.length-1,r)),!(n<=e&&e<=r))return t;for(i=void 0===i?J:Z(i);r>n;){if(r-n>600){const o=r-n+1,a=e-n+1,s=Math.log(o),u=.5*Math.exp(2*s/3),l=.5*Math.sqrt(s*u*(o-u)/o)*(a-o/2<0?-1:1);vt(t,e,Math.max(n,Math.floor(e-a*u/o+l)),Math.min(r,Math.floor(e+(o-a)*u/o+l)),i)}const o=t[e];let a=n,s=r;for(xt(t,n,e),i(t[r],o)>0&&xt(t,n,r);a<s;){for(xt(t,a,s),++a,--s;i(t[a],o)<0;)++a;for(;i(t[s],o)>0;)--s}0===i(t[n],o)?xt(t,n,s):(++s,xt(t,s,r)),s<=e&&(n=s+1),e<=s&&(r=s-1)}return t}function xt(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function _t(t,e=r){let n,i=!1;if(1===e.length){let o;for(const a of t){const t=e(a);(i?r(t,o)>0:0===r(t,t))&&(n=a,o=t,i=!0)}}else for(const r of t)(i?e(r,n)>0:0===e(r,r))&&(n=r,i=!0);return n}function bt(t,e,n){if(t=Float64Array.from(function*(t,e){if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(yield e);else{let n=-1;for(let r of t)null!=(r=e(r,++n,t))&&(r=+r)>=r&&(yield r)}}(t,n)),(r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return gt(t);if(e>=1)return pt(t);var r,i=(r-1)*e,o=Math.floor(i),a=pt(vt(t,o).subarray(0,o+1));return a+(gt(t.subarray(o+1))-a)*(i-o)}}function wt(t,e,n=s){if((r=t.length)&&!isNaN(e=+e)){if(e<=0||r<2)return+n(t[0],0,t);if(e>=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,o=Math.floor(i),a=+n(t[o],o,t);return a+(+n(t[o+1],o+1,t)-a)*(i-o)}}function Mt(t,e,n=s){if(!isNaN(e=+e)){if(r=Float64Array.from(t,((e,r)=>s(n(t[r],r,t)))),e<=0)return yt(r);if(e>=1)return mt(r);var r,i=Uint32Array.from(t,((t,e)=>e)),o=r.length-1,a=Math.floor(o*e);return vt(i,a,0,o,((t,e)=>J(r[t],r[e]))),(a=_t(i.subarray(0,a+1),(t=>r[t])))>=0?a:-1}}function At(t,e,n){const r=_(t),i=bt(t,.75)-bt(t,.25);return r&&i?Math.ceil((n-e)/(2*i*Math.pow(r,-1/3))):1}function Tt(t,e,n){const r=_(t),i=C(t);return r&&i?Math.ceil((n-e)*Math.cbrt(r)/(3.49*i)):1}function Et(t,e){let n=0,r=0;if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(++n,r+=e);else{let i=-1;for(let o of t)null!=(o=e(o,++i,t))&&(o=+o)>=o&&(++n,r+=o)}if(n)return r/n}function Ct(t,e){return bt(t,.5,e)}function kt(t,e){return Mt(t,.5,e)}function St(t){return Array.from(function*(t){for(const e of t)yield*e}(t))}function Ot(t,e){const n=new L;if(void 0===e)for(let e of t)null!=e&&e>=e&&n.set(e,(n.get(e)||0)+1);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&i>=i&&n.set(i,(n.get(i)||0)+1)}let r,i=0;for(const[t,e]of n)e>i&&(i=e,r=t);return r}function Pt(t,e=Lt){const n=[];let r,i=!1;for(const o of t)i&&n.push(e(r,o)),r=o,i=!0;return n}function Lt(t,e){return[t,e]}function Rt(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}function It(t,e=r){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");let n=Array.from(t);const i=new Float64Array(n.length);2!==e.length&&(n=n.map(e),e=r);const o=(t,r)=>e(n[t],n[r]);let a,s;return(t=Uint32Array.from(n,((t,e)=>e))).sort(e===r?(t,e)=>J(n[t],n[e]):Z(o)),t.forEach(((t,e)=>{const n=o(t,void 0===a?t:a);n>=0?((void 0===a||n>0)&&(a=t,s=e),i[t]=s):i[t]=NaN})),i}function Dt(t,e=r){let n,i=!1;if(1===e.length){let o;for(const a of t){const t=e(a);(i?r(t,o)<0:0===r(t,t))&&(n=a,o=t,i=!0)}}else for(const r of t)(i?e(r,n)<0:0===e(r,r))&&(n=r,i=!0);return n}function Nt(t,e=r){if(1===e.length)return yt(t,e);let n,i=-1,o=-1;for(const r of t)++o,(i<0?0===e(r,r):e(r,n)<0)&&(n=r,i=o);return i}function Ft(t,e=r){if(1===e.length)return mt(t,e);let n,i=-1,o=-1;for(const r of t)++o,(i<0?0===e(r,r):e(r,n)>0)&&(n=r,i=o);return i}function jt(t,e){const n=Nt(t,e);return n<0?void 0:n}var zt=Bt(Math.random);function Bt(t){return function(e,n=0,r=e.length){let i=r-(n=+n);for(;i;){const r=t()*i--|0,o=e[i+n];e[i+n]=e[r+n],e[r+n]=o}return e}}function Vt(t,e){let n=0;if(void 0===e)for(let e of t)(e=+e)&&(n+=e);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&(n+=i)}return n}function qt(t){if(!(i=t.length))return[];for(var e=-1,n=gt(t,Gt),r=new Array(n);++e<n;)for(var i,o=-1,a=r[e]=new Array(i);++o<i;)a[o]=t[o][e];return r}function Gt(t){return t.length}function Ut(){return qt(arguments)}function Ht(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");let n=-1;for(const r of t)if(!e(r,++n,t))return!1;return!0}function Wt(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");let n=-1;for(const r of t)if(e(r,++n,t))return!0;return!1}function Xt(t,e){if("function"!=typeof e)throw new TypeError("test is not a function");const n=[];let r=-1;for(const i of t)e(i,++r,t)&&n.push(i);return n}function Kt(t,e){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");if("function"!=typeof e)throw new TypeError("mapper is not a function");return Array.from(t,((n,r)=>e(n,r,t)))}function Qt(t,e,n){if("function"!=typeof e)throw new TypeError("reducer is not a function");const r=t[Symbol.iterator]();let i,o,a=-1;if(arguments.length<3){if(({done:i,value:n}=r.next()),i)return;++a}for(;({done:i,value:o}=r.next()),!i;)n=e(n,o,++a,t);return n}function Yt(t){if("function"!=typeof t[Symbol.iterator])throw new TypeError("values is not iterable");return Array.from(t).reverse()}function $t(t,...e){t=new R(t);for(const n of e)for(const e of n)t.delete(e);return t}function Zt(t,e){const n=e[Symbol.iterator](),r=new R;for(const e of t){if(r.has(e))return!1;let t,i;for(;({value:t,done:i}=n.next())&&!i;){if(Object.is(e,t))return!1;r.add(t)}}return!0}function Jt(t,...e){t=new R(t),e=e.map(te);t:for(const n of t)for(const r of e)if(!r.has(n)){t.delete(n);continue t}return t}function te(t){return t instanceof R?t:new R(t)}function ee(t,e){const n=t[Symbol.iterator](),r=new Set;for(const t of e){const e=ne(t);if(r.has(e))continue;let i,o;for(;({value:i,done:o}=n.next());){if(o)return!1;const t=ne(i);if(r.add(t),Object.is(e,t))break}}return!0}function ne(t){return null!==t&&"object"==typeof t?t.valueOf():t}function re(t,e){return ee(e,t)}function ie(...t){const e=new R;for(const n of t)for(const t of n)e.add(t);return e}function oe(t){return t}var ae=1,se=2,ue=3,le=4,ce=1e-6;function fe(t){return"translate("+t+",0)"}function he(t){return"translate(0,"+t+")"}function de(t){return e=>+t(e)}function pe(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function me(){return!this.__axis}function ge(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u="undefined"!=typeof window&&window.devicePixelRatio>1?0:.5,l=t===ae||t===le?-1:1,c=t===le||t===se?"x":"y",f=t===ae||t===ue?fe:he;function h(h){var d=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,p=null==i?e.tickFormat?e.tickFormat.apply(e,n):oe:i,m=Math.max(o,0)+s,g=e.range(),y=+g[0]+u,v=+g[g.length-1]+u,x=(e.bandwidth?pe:de)(e.copy(),u),_=h.selection?h.selection():h,b=_.selectAll(".domain").data([null]),w=_.selectAll(".tick").data(d,e).order(),M=w.exit(),A=w.enter().append("g").attr("class","tick"),T=w.select("line"),E=w.select("text");b=b.merge(b.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),w=w.merge(A),T=T.merge(A.append("line").attr("stroke","currentColor").attr(c+"2",l*o)),E=E.merge(A.append("text").attr("fill","currentColor").attr(c,l*m).attr("dy",t===ae?"0em":t===ue?"0.71em":"0.32em")),h!==_&&(b=b.transition(h),w=w.transition(h),T=T.transition(h),E=E.transition(h),M=M.transition(h).attr("opacity",ce).attr("transform",(function(t){return isFinite(t=x(t))?f(t+u):this.getAttribute("transform")})),A.attr("opacity",ce).attr("transform",(function(t){var e=this.parentNode.__axis;return f((e&&isFinite(e=e(t))?e:x(t))+u)}))),M.remove(),b.attr("d",t===le||t===se?a?"M"+l*a+","+y+"H"+u+"V"+v+"H"+l*a:"M"+u+","+y+"V"+v:a?"M"+y+","+l*a+"V"+u+"H"+v+"V"+l*a:"M"+y+","+u+"H"+v),w.attr("opacity",1).attr("transform",(function(t){return f(x(t)+u)})),T.attr(c+"2",l*o),E.attr(c,l*m).text(p),_.filter(me).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===se?"start":t===le?"end":"middle"),_.each((function(){this.__axis=x}))}return h.scale=function(t){return arguments.length?(e=t,h):e},h.ticks=function(){return n=Array.from(arguments),h},h.tickArguments=function(t){return arguments.length?(n=null==t?[]:Array.from(t),h):n.slice()},h.tickValues=function(t){return arguments.length?(r=null==t?null:Array.from(t),h):r&&r.slice()},h.tickFormat=function(t){return arguments.length?(i=t,h):i},h.tickSize=function(t){return arguments.length?(o=a=+t,h):o},h.tickSizeInner=function(t){return arguments.length?(o=+t,h):o},h.tickSizeOuter=function(t){return arguments.length?(a=+t,h):a},h.tickPadding=function(t){return arguments.length?(s=+t,h):s},h.offset=function(t){return arguments.length?(u=+t,h):u},h}function ye(t){return ge(ae,t)}function ve(t){return ge(se,t)}function xe(t){return ge(ue,t)}function _e(t){return ge(le,t)}var be={value:()=>{}};function we(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new Me(r)}function Me(t){this._=t}function Ae(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function Te(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=be,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}Me.prototype=we.prototype={constructor:Me,on:function(t,e){var n,r,i=this._,o=(r=i,(t+"").trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");if(n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}}))),a=-1,s=o.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++a<s;)if(n=(t=o[a]).type)i[n]=Te(i[n],t.name,e);else if(null==e)for(n in i)i[n]=Te(i[n],t.name,null);return this}for(;++a<s;)if((n=(t=o[a]).type)&&(n=Ae(i[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new Me(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(r=this._[t]).length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var Ee=we;function Ce(){}function ke(t){return null==t?Ce:function(){return this.querySelector(t)}}function Se(t){return null==t?[]:Array.isArray(t)?t:Array.from(t)}function Oe(){return[]}function Pe(t){return null==t?Oe:function(){return this.querySelectorAll(t)}}function Le(t){return function(){return this.matches(t)}}function Re(t){return function(e){return e.matches(t)}}var Ie=Array.prototype.find;function De(){return this.firstElementChild}var Ne=Array.prototype.filter;function Fe(){return Array.from(this.children)}function je(t){return new Array(t.length)}function ze(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function Be(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new ze(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function Ve(t,e,n,r,i,o,a){var s,u,l,c=new Map,f=e.length,h=o.length,d=new Array(f);for(s=0;s<f;++s)(u=e[s])&&(d[s]=l=a.call(u,u.__data__,s,e)+"",c.has(l)?i[s]=u:c.set(l,u));for(s=0;s<h;++s)l=a.call(t,o[s],s,o)+"",(u=c.get(l))?(r[s]=u,u.__data__=o[s],c.delete(l)):n[s]=new ze(t,o[s]);for(s=0;s<f;++s)(u=e[s])&&c.get(d[s])===u&&(i[s]=u)}function qe(t){return t.__data__}function Ge(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function Ue(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}ze.prototype={constructor:ze,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var He="http://www.w3.org/1999/xhtml",We={svg:"http://www.w3.org/2000/svg",xhtml:He,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Xe(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),We.hasOwnProperty(e)?{space:We[e],local:t}:t}function Ke(t){return function(){this.removeAttribute(t)}}function Qe(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ye(t,e){return function(){this.setAttribute(t,e)}}function $e(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Ze(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Je(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function tn(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function en(t){return function(){this.style.removeProperty(t)}}function nn(t,e,n){return function(){this.style.setProperty(t,e,n)}}function rn(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function on(t,e){return t.style.getPropertyValue(e)||tn(t).getComputedStyle(t,null).getPropertyValue(e)}function an(t){return function(){delete this[t]}}function sn(t,e){return function(){this[t]=e}}function un(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function ln(t){return t.trim().split(/^|\s+/)}function cn(t){return t.classList||new fn(t)}function fn(t){this._node=t,this._names=ln(t.getAttribute("class")||"")}function hn(t,e){for(var n=cn(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function dn(t,e){for(var n=cn(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function pn(t){return function(){hn(this,t)}}function mn(t){return function(){dn(this,t)}}function gn(t,e){return function(){(e.apply(this,arguments)?hn:dn)(this,t)}}function yn(){this.textContent=""}function vn(t){return function(){this.textContent=t}}function xn(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function _n(){this.innerHTML=""}function bn(t){return function(){this.innerHTML=t}}function wn(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function Mn(){this.nextSibling&&this.parentNode.appendChild(this)}function An(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Tn(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===He&&e.documentElement.namespaceURI===He?e.createElement(t):e.createElementNS(n,t)}}function En(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Cn(t){var e=Xe(t);return(e.local?En:Tn)(e)}function kn(){return null}function Sn(){var t=this.parentNode;t&&t.removeChild(this)}function On(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Pn(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Ln(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.options);++i?e.length=i:delete this.__on}}}function Rn(t,e,n){return function(){var r,i=this.__on,o=function(t){return function(e){t.call(this,e,this.__data__)}}(e);if(i)for(var a=0,s=i.length;a<s;++a)if((r=i[a]).type===t.type&&r.name===t.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),void(r.value=e);this.addEventListener(t.type,o,n),r={type:t.type,name:t.name,value:e,listener:o,options:n},i?i.push(r):this.__on=[r]}}function In(t,e,n){var r=tn(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function Dn(t,e){return function(){return In(this,t,e)}}function Nn(t,e){return function(){return In(this,t,e.apply(this,arguments))}}fn.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Fn=[null];function jn(t,e){this._groups=t,this._parents=e}function zn(){return new jn([[document.documentElement]],Fn)}jn.prototype=zn.prototype={constructor:jn,select:function(t){"function"!=typeof t&&(t=ke(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,l=r[i]=new Array(u),c=0;c<u;++c)(o=s[c])&&(a=t.call(o,o.__data__,c,s))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new jn(r,this._parents)},selectAll:function(t){t="function"==typeof t?function(t){return function(){return Se(t.apply(this,arguments))}}(t):Pe(t);for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new jn(r,i)},selectChild:function(t){return this.select(null==t?De:function(t){return function(){return Ie.call(this.children,t)}}("function"==typeof t?t:Re(t)))},selectChildren:function(t){return this.selectAll(null==t?Fe:function(t){return function(){return Ne.call(this.children,t)}}("function"==typeof t?t:Re(t)))},filter:function(t){"function"!=typeof t&&(t=Le(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new jn(r,this._parents)},data:function(t,e){if(!arguments.length)return Array.from(this,qe);var n=e?Ve:Be,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),l=0;l<o;++l){var c=r[l],f=i[l],h=f.length,d=Ge(t.call(c,c&&c.__data__,l,r)),p=d.length,m=s[l]=new Array(p),g=a[l]=new Array(p);n(c,f,m,g,u[l]=new Array(h),d,e);for(var y,v,x=0,_=0;x<p;++x)if(y=m[x]){for(x>=_&&(_=x+1);!(v=g[_])&&++_<p;);y._next=v||null}}return(a=new jn(a,r))._enter=s,a._exit=u,a},enter:function(){return new jn(this._enter||this._groups.map(je),this._parents)},exit:function(){return new jn(this._exit||this._groups.map(je),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return"function"==typeof t?(r=t(r))&&(r=r.selection()):r=r.append(t+""),null!=e&&(i=e(i))&&(i=i.selection()),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){for(var e=t.selection?t.selection():t,n=this._groups,r=e._groups,i=n.length,o=r.length,a=Math.min(i,o),s=new Array(i),u=0;u<a;++u)for(var l,c=n[u],f=r[u],h=c.length,d=s[u]=new Array(h),p=0;p<h;++p)(l=c[p]||f[p])&&(d[p]=l);for(;u<i;++u)s[u]=n[u];return new jn(s,this._parents)},selection:function(){return this},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Ue);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new jn(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){let t=0;for(const e of this)++t;return t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,e){var n=Xe(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?Qe:Ke:"function"==typeof e?n.local?Je:Ze:n.local?$e:Ye)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?en:"function"==typeof e?rn:nn)(t,e,null==n?"":n)):on(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?an:"function"==typeof e?un:sn)(t,e)):this.node()[t]},classed:function(t,e){var n=ln(t+"");if(arguments.length<2){for(var r=cn(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?gn:e?pn:mn)(n,e))},text:function(t){return arguments.length?this.each(null==t?yn:("function"==typeof t?xn:vn)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?_n:("function"==typeof t?wn:bn)(t)):this.node().innerHTML},raise:function(){return this.each(Mn)},lower:function(){return this.each(An)},append:function(t){var e="function"==typeof t?t:Cn(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:Cn(t),r=null==e?kn:"function"==typeof e?e:ke(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(Sn)},clone:function(t){return this.select(t?Pn:On)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=function(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?Rn:Ln,r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value},dispatch:function(t,e){return this.each(("function"==typeof e?Nn:Dn)(t,e))},[Symbol.iterator]:function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r,i=t[e],o=0,a=i.length;o<a;++o)(r=i[o])&&(yield r)}};var Bn=zn;function Vn(t){return"string"==typeof t?new jn([[document.querySelector(t)]],[document.documentElement]):new jn([[t]],Fn)}const qn={passive:!1},Gn={capture:!0,passive:!1};function Un(t){t.stopImmediatePropagation()}function Hn(t){t.preventDefault(),t.stopImmediatePropagation()}function Wn(t){var e=t.document.documentElement,n=Vn(t).on("dragstart.drag",Hn,Gn);"onselectstart"in e?n.on("selectstart.drag",Hn,Gn):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function Xn(t,e){var n=t.document.documentElement,r=Vn(t).on("dragstart.drag",null);e&&(r.on("click.drag",Hn,Gn),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Kn(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Qn(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Yn(){}var $n=.7,Zn=1/$n,Jn="\\s*([+-]?\\d+)\\s*",tr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",er="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",nr=/^#([0-9a-f]{3,8})$/,rr=new RegExp(`^rgb\\(${Jn},${Jn},${Jn}\\)$`),ir=new RegExp(`^rgb\\(${er},${er},${er}\\)$`),or=new RegExp(`^rgba\\(${Jn},${Jn},${Jn},${tr}\\)$`),ar=new RegExp(`^rgba\\(${er},${er},${er},${tr}\\)$`),sr=new RegExp(`^hsl\\(${tr},${er},${er}\\)$`),ur=new RegExp(`^hsla\\(${tr},${er},${er},${tr}\\)$`),lr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function cr(){return this.rgb().formatHex()}function fr(){return this.rgb().formatRgb()}function hr(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=nr.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?dr(e):3===n?new yr(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?pr(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?pr(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=rr.exec(t))?new yr(e[1],e[2],e[3],1):(e=ir.exec(t))?new yr(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=or.exec(t))?pr(e[1],e[2],e[3],e[4]):(e=ar.exec(t))?pr(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=sr.exec(t))?Mr(e[1],e[2]/100,e[3]/100,1):(e=ur.exec(t))?Mr(e[1],e[2]/100,e[3]/100,e[4]):lr.hasOwnProperty(t)?dr(lr[t]):"transparent"===t?new yr(NaN,NaN,NaN,0):null}function dr(t){return new yr(t>>16&255,t>>8&255,255&t,1)}function pr(t,e,n,r){return r<=0&&(t=e=n=NaN),new yr(t,e,n,r)}function mr(t){return t instanceof Yn||(t=hr(t)),t?new yr((t=t.rgb()).r,t.g,t.b,t.opacity):new yr}function gr(t,e,n,r){return 1===arguments.length?mr(t):new yr(t,e,n,null==r?1:r)}function yr(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function vr(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}`}function xr(){const t=_r(this.opacity);return`${1===t?"rgb(":"rgba("}${br(this.r)}, ${br(this.g)}, ${br(this.b)}${1===t?")":`, ${t})`}`}function _r(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function br(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function wr(t){return((t=br(t))<16?"0":"")+t.toString(16)}function Mr(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Er(t,e,n,r)}function Ar(t){if(t instanceof Er)return new Er(t.h,t.s,t.l,t.opacity);if(t instanceof Yn||(t=hr(t)),!t)return new Er;if(t instanceof Er)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new Er(a,s,u,t.opacity)}function Tr(t,e,n,r){return 1===arguments.length?Ar(t):new Er(t,e,n,null==r?1:r)}function Er(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function Cr(t){return(t=(t||0)%360)<0?t+360:t}function kr(t){return Math.max(0,Math.min(1,t||0))}function Sr(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function Or(t,e,n,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*r+a*i)/6}function Pr(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,s=r<e-1?t[r+2]:2*o-i;return Or((n-r/e)*e,a,i,o,s)}}function Lr(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),i=t[(r+e-1)%e],o=t[r%e],a=t[(r+1)%e],s=t[(r+2)%e];return Or((n-r/e)*e,i,o,a,s)}}Kn(Yn,hr,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:cr,formatHex:cr,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ar(this).formatHsl()},formatRgb:fr,toString:fr}),Kn(yr,gr,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new yr(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new yr(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new yr(br(this.r),br(this.g),br(this.b),_r(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:vr,formatHex:vr,formatHex8:function(){return`#${wr(this.r)}${wr(this.g)}${wr(this.b)}${wr(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:xr,toString:xr})),Kn(Er,Tr,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new Er(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new Er(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new yr(Sr(t>=240?t-240:t+120,i,r),Sr(t,i,r),Sr(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new Er(Cr(this.h),kr(this.s),kr(this.l),_r(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=_r(this.opacity);return`${1===t?"hsl(":"hsla("}${Cr(this.h)}, ${100*kr(this.s)}%, ${100*kr(this.l)}%${1===t?")":`, ${t})`}`}}));var Rr=t=>()=>t;function Ir(t,e){return function(n){return t+n*e}}function Dr(t,e){var n=e-t;return n?Ir(t,n>180||n<-180?n-360*Math.round(n/360):n):Rr(isNaN(t)?e:t)}function Nr(t){return 1==(t=+t)?Fr:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):Rr(isNaN(e)?n:e)}}function Fr(t,e){var n=e-t;return n?Ir(t,n):Rr(isNaN(t)?e:t)}var jr=function t(e){var n=Nr(e);function r(t,e){var r=n((t=gr(t)).r,(e=gr(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=Fr(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function zr(t){return function(e){var n,r,i=e.length,o=new Array(i),a=new Array(i),s=new Array(i);for(n=0;n<i;++n)r=gr(e[n]),o[n]=r.r||0,a[n]=r.g||0,s[n]=r.b||0;return o=t(o),a=t(a),s=t(s),r.opacity=1,function(t){return r.r=o(t),r.g=a(t),r.b=s(t),r+""}}}var Br=zr(Pr),Vr=zr(Lr);function qr(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}}function Gr(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function Ur(t,e){return(Gr(e)?qr:Hr)(t,e)}function Hr(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=Zr(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}function Wr(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function Xr(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function Kr(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=Zr(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var Qr=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Yr=new RegExp(Qr.source,"g");function $r(t,e){var n,r,i,o=Qr.lastIndex=Yr.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=Qr.exec(t))&&(r=Yr.exec(e));)(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:Xr(n,r)})),o=Yr.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})}function Zr(t,e){var n,r=typeof e;return null==e||"boolean"===r?Rr(e):("number"===r?Xr:"string"===r?(n=hr(e))?(e=n,jr):$r:e instanceof hr?jr:e instanceof Date?Wr:Gr(e)?qr:Array.isArray(e)?Hr:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?Kr:Xr)(t,e)}function Jr(t){let e;for(;e=t.sourceEvent;)t=e;return t}function ti(t,e){if(t=Jr(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,[(r=r.matrixTransform(e.getScreenCTM().inverse())).x,r.y]}if(e.getBoundingClientRect){var i=e.getBoundingClientRect();return[t.clientX-i.left-e.clientLeft,t.clientY-i.top-e.clientTop]}}return[t.pageX,t.pageY]}var ei,ni,ri=0,ii=0,oi=0,ai=0,si=0,ui=0,li="object"==typeof performance&&performance.now?performance:Date,ci="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function fi(){return si||(ci(hi),si=li.now()+ui)}function hi(){si=0}function di(){this._call=this._time=this._next=null}function pi(t,e,n){var r=new di;return r.restart(t,e,n),r}function mi(){fi(),++ri;for(var t,e=ei;e;)(t=si-e._time)>=0&&e._call.call(void 0,t),e=e._next;--ri}function gi(){si=(ai=li.now())+ui,ri=ii=0;try{mi()}finally{ri=0,function(){var t,e,n=ei,r=1/0;for(;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:ei=e);ni=t,vi(r)}(),si=0}}function yi(){var t=li.now(),e=t-ai;e>1e3&&(ui-=e,ai=t)}function vi(t){ri||(ii&&(ii=clearTimeout(ii)),t-si>24?(t<1/0&&(ii=setTimeout(gi,t-li.now()-ui)),oi&&(oi=clearInterval(oi))):(oi||(ai=li.now(),oi=setInterval(yi,1e3)),ri=1,ci(gi)))}function xi(t,e,n){var r=new di;return e=null==e?0:+e,r.restart((n=>{r.stop(),t(n+e)}),e,n),r}di.prototype=pi.prototype={constructor:di,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?fi():+n)+(null==e?0:+e),this._next||ni===this||(ni?ni._next=this:ei=this,ni=this),this._call=t,this._time=n,vi()},stop:function(){this._call&&(this._call=null,this._time=1/0,vi())}};var _i=Ee("start","end","cancel","interrupt"),bi=[],wi=1,Mi=2,Ai=5,Ti=6;function Ei(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(t){n.state=wi,n.timer.restart(a,n.delay,n.time),n.delay<=t&&a(t-n.delay)}function a(o){var l,c,f,h;if(n.state!==wi)return u();for(l in i)if((h=i[l]).name===n.name){if(3===h.state)return xi(a);4===h.state?(h.state=Ti,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[l]):+l<e&&(h.state=Ti,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[l])}if(xi((function(){3===n.state&&(n.state=4,n.timer.restart(s,n.delay,n.time),s(o))})),n.state=Mi,n.on.call("start",t,t.__data__,n.index,n.group),n.state===Mi){for(n.state=3,r=new Array(f=n.tween.length),l=0,c=-1;l<f;++l)(h=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=h);r.length=c+1}}function s(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(u),n.state=Ai,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);n.state===Ai&&(n.on.call("end",t,t.__data__,n.index,n.group),u())}function u(){for(var r in n.state=Ti,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=pi(o,0,n.time)}(t,n,{name:e,index:r,group:i,on:_i,tween:bi,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Ci(t,e){var n=Si(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function ki(t,e){var n=Si(t,e);if(n.state>3)throw new Error("too late; already running");return n}function Si(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function Oi(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>Mi&&n.state<Ai,n.state=Ti,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}}var Pi,Li=180/Math.PI,Ri={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Ii(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*Li,skewX:Math.atan(u)*Li,scaleX:a,scaleY:s}}function Di(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:Xr(t,i)},{i:u-2,x:Xr(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:Xr(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:Xr(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:Xr(t,n)},{i:s-2,x:Xr(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var Ni=Di((function(t){const e=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Ri:Ii(e.a,e.b,e.c,e.d,e.e,e.f)}),"px, ","px)","deg)"),Fi=Di((function(t){return null==t?Ri:(Pi||(Pi=document.createElementNS("http://www.w3.org/2000/svg","g")),Pi.setAttribute("transform",t),(t=Pi.transform.baseVal.consolidate())?Ii((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Ri)}),", ",")",")");function ji(t,e){var n,r;return function(){var i=ki(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function zi(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=ki(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}}function Bi(t,e,n){var r=t._id;return t.each((function(){var t=ki(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return Si(t,r).value[e]}}function Vi(t,e){var n;return("number"==typeof e?Xr:e instanceof hr?jr:(n=hr(e))?(e=n,jr):$r)(t,e)}function qi(t){return function(){this.removeAttribute(t)}}function Gi(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ui(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function Hi(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function Wi(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttribute(t))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function Xi(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttributeNS(t.space,t.local))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Ki(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&function(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}(t,i)),n}return i._value=e,i}function Qi(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&function(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}(t,i)),n}return i._value=e,i}function Yi(t,e){return function(){Ci(this,t).delay=+e.apply(this,arguments)}}function $i(t,e){return e=+e,function(){Ci(this,t).delay=e}}function Zi(t,e){return function(){ki(this,t).duration=+e.apply(this,arguments)}}function Ji(t,e){return e=+e,function(){ki(this,t).duration=e}}var to=Bn.prototype.constructor;function eo(t){return function(){this.style.removeProperty(t)}}var no=0;function ro(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function io(t){return Bn().transition(t)}function oo(){return++no}var ao=Bn.prototype;function so(t){return t*t*t}function uo(t){return--t*t*t+1}function lo(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}ro.prototype=io.prototype={constructor:ro,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=ke(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,l=r[a],c=l.length,f=o[a]=new Array(c),h=0;h<c;++h)(s=l[h])&&(u=t.call(s,s.__data__,h,l))&&("__data__"in s&&(u.__data__=s.__data__),f[h]=u,Ei(f[h],e,n,h,f,Si(s,n)));return new ro(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Pe(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,l=r[s],c=l.length,f=0;f<c;++f)if(u=l[f]){for(var h,d=t.call(u,u.__data__,f,l),p=Si(u,n),m=0,g=d.length;m<g;++m)(h=d[m])&&Ei(h,e,n,m,d,p);o.push(d),a.push(u)}return new ro(o,a,e,n)},selectChild:ao.selectChild,selectChildren:ao.selectChildren,filter:function(t){"function"!=typeof t&&(t=Le(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new ro(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],f=l.length,h=a[s]=new Array(f),d=0;d<f;++d)(u=l[d]||c[d])&&(h[d]=u);for(;s<r;++s)a[s]=e[s];return new ro(a,this._parents,this._name,this._id)},selection:function(){return new to(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=oo(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=Si(a,e);Ei(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new ro(r,this._parents,t,n)},call:ao.call,nodes:ao.nodes,node:ao.node,size:ao.size,empty:ao.empty,each:ao.each,on:function(t,e){var n=this._id;return arguments.length<2?Si(this.node(),n).on.on(t):this.each(function(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?Ci:ki;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}(n,t,e))},attr:function(t,e){var n=Xe(t),r="transform"===n?Fi:Vi;return this.attrTween(t,"function"==typeof e?(n.local?Xi:Wi)(n,r,Bi(this,"attr."+t,e)):null==e?(n.local?Gi:qi)(n):(n.local?Hi:Ui)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=Xe(t);return this.tween(n,(r.local?Ki:Qi)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?Ni:Vi;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=on(this,t),a=(this.style.removeProperty(t),on(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,eo(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=on(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=on(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,Bi(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=ki(this,t),l=u.on,c=null==u.value[a]?o||(o=eo(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=on(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,function(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&function(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}(t,o,n)),r}return o._value=e,o}(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(Bi(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,function(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&function(t){return function(e){this.textContent=t.call(this,e)}}(r)),e}return r._value=t,r}(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=Si(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?ji:zi)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Yi:$i)(e,t)):Si(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Zi:Ji)(e,t)):Si(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(function(t,e){if("function"!=typeof e)throw new Error;return function(){ki(this,t).ease=e}}(e,t)):Si(this.node(),e).ease},easeVarying:function(t){if("function"!=typeof t)throw new Error;return this.each(function(t,e){return function(){var n=e.apply(this,arguments);if("function"!=typeof n)throw new Error;ki(this,t).ease=n}}(this._id,t))},end:function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0==--i&&o()}};n.each((function(){var n=ki(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e})),0===i&&o()}))},[Symbol.iterator]:ao[Symbol.iterator]};var co={time:null,delay:0,duration:250,ease:lo};function fo(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return n}Bn.prototype.interrupt=function(t){return this.each((function(){Oi(this,t)}))},Bn.prototype.transition=function(t){var e,n;t instanceof ro?(e=t._id,t=t._name):(e=oo(),(n=co).time=fi(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&Ei(a,t,e,l,s,n||fo(a,e));return new ro(r,this._parents,t,e)};var ho=[null];function po(t,e){var n,r,i=t.__transition;if(i)for(r in e=null==e?null:e+"",i)if((n=i[r]).state>wi&&n.name===e)return new ro([[t]],ho,e,+r);return null}var mo=t=>()=>t;function go(t,{sourceEvent:e,target:n,selection:r,mode:i,dispatch:o}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function yo(t){t.preventDefault(),t.stopImmediatePropagation()}var vo={name:"drag"},xo={name:"space"},_o={name:"handle"},bo={name:"center"};const{abs:wo,max:Mo,min:Ao}=Math;function To(t){return[+t[0],+t[1]]}function Eo(t){return[To(t[0]),To(t[1])]}var Co={name:"x",handles:["w","e"].map(Do),input:function(t,e){return null==t?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},ko={name:"y",handles:["n","s"].map(Do),input:function(t,e){return null==t?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},So={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(Do),input:function(t){return null==t?null:Eo(t)},output:function(t){return t}},Oo={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},Po={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},Lo={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},Ro={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Io={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Do(t){return{type:t}}function No(t){return!t.ctrlKey&&!t.button}function Fo(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function jo(){return navigator.maxTouchPoints||"ontouchstart"in this}function zo(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function Bo(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Vo(){return Uo(Co)}function qo(){return Uo(ko)}function Go(){return Uo(So)}function Uo(t){var e,n=Fo,r=No,i=jo,o=!0,a=Ee("start","brush","end"),s=6;function u(e){var n=e.property("__brush",m).selectAll(".overlay").data([Do("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",Oo.overlay).merge(n).each((function(){var t=zo(this).extent;Vn(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([Do("selection")]).enter().append("rect").attr("class","selection").attr("cursor",Oo.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var r=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));r.exit().remove(),r.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return Oo[t.type]})),e.each(l).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(i).on("touchstart.brush",h).on("touchmove.brush",d).on("touchend.brush touchcancel.brush",p).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function l(){var t=Vn(this),e=zo(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-s/2:e[0][0]-s/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-s/2:e[0][1]-s/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+s:s})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+s:s}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function c(t,e,n){var r=t.__brush.emitter;return!r||n&&r.clean?new f(t,e,n):r}function f(t,e,n){this.that=t,this.args=e,this.state=t.__brush,this.active=0,this.clean=n}function h(n){if((!e||n.touches)&&r.apply(this,arguments)){var i,a,s,u,f,h,d,p,m,g,y,v=this,x=n.target.__data__.type,_="selection"===(o&&n.metaKey?x="overlay":x)?vo:o&&n.altKey?bo:_o,b=t===ko?null:Ro[x],w=t===Co?null:Io[x],M=zo(v),A=M.extent,T=M.selection,E=A[0][0],C=A[0][1],k=A[1][0],S=A[1][1],O=0,P=0,L=b&&w&&o&&n.shiftKey,R=Array.from(n.touches||[n],(t=>{const e=t.identifier;return(t=ti(t,v)).point0=t.slice(),t.identifier=e,t}));Oi(v);var I=c(v,arguments,!0).beforestart();if("overlay"===x){T&&(m=!0);const e=[R[0],R[1]||R[0]];M.selection=T=[[i=t===ko?E:Ao(e[0][0],e[1][0]),s=t===Co?C:Ao(e[0][1],e[1][1])],[f=t===ko?k:Mo(e[0][0],e[1][0]),d=t===Co?S:Mo(e[0][1],e[1][1])]],R.length>1&&z(n)}else i=T[0][0],s=T[0][1],f=T[1][0],d=T[1][1];a=i,u=s,h=f,p=d;var D=Vn(v).attr("pointer-events","none"),N=D.selectAll(".overlay").attr("cursor",Oo[x]);if(n.touches)I.moved=j,I.ended=B;else{var F=Vn(n.view).on("mousemove.brush",j,!0).on("mouseup.brush",B,!0);o&&F.on("keydown.brush",(function(t){switch(t.keyCode){case 16:L=b&&w;break;case 18:_===_o&&(b&&(f=h-O*b,i=a+O*b),w&&(d=p-P*w,s=u+P*w),_=bo,z(t));break;case 32:_!==_o&&_!==bo||(b<0?f=h-O:b>0&&(i=a-O),w<0?d=p-P:w>0&&(s=u-P),_=xo,N.attr("cursor",Oo.selection),z(t));break;default:return}yo(t)}),!0).on("keyup.brush",(function(t){switch(t.keyCode){case 16:L&&(g=y=L=!1,z(t));break;case 18:_===bo&&(b<0?f=h:b>0&&(i=a),w<0?d=p:w>0&&(s=u),_=_o,z(t));break;case 32:_===xo&&(t.altKey?(b&&(f=h-O*b,i=a+O*b),w&&(d=p-P*w,s=u+P*w),_=bo):(b<0?f=h:b>0&&(i=a),w<0?d=p:w>0&&(s=u),_=_o),N.attr("cursor",Oo[x]),z(t));break;default:return}yo(t)}),!0),Wn(n.view)}l.call(v),I.start(n,_.name)}function j(t){for(const e of t.changedTouches||[t])for(const t of R)t.identifier===e.identifier&&(t.cur=ti(e,v));if(L&&!g&&!y&&1===R.length){const t=R[0];wo(t.cur[0]-t[0])>wo(t.cur[1]-t[1])?y=!0:g=!0}for(const t of R)t.cur&&(t[0]=t.cur[0],t[1]=t.cur[1]);m=!0,yo(t),z(t)}function z(t){const e=R[0],n=e.point0;var r;switch(O=e[0]-n[0],P=e[1]-n[1],_){case xo:case vo:b&&(O=Mo(E-i,Ao(k-f,O)),a=i+O,h=f+O),w&&(P=Mo(C-s,Ao(S-d,P)),u=s+P,p=d+P);break;case _o:R[1]?(b&&(a=Mo(E,Ao(k,R[0][0])),h=Mo(E,Ao(k,R[1][0])),b=1),w&&(u=Mo(C,Ao(S,R[0][1])),p=Mo(C,Ao(S,R[1][1])),w=1)):(b<0?(O=Mo(E-i,Ao(k-i,O)),a=i+O,h=f):b>0&&(O=Mo(E-f,Ao(k-f,O)),a=i,h=f+O),w<0?(P=Mo(C-s,Ao(S-s,P)),u=s+P,p=d):w>0&&(P=Mo(C-d,Ao(S-d,P)),u=s,p=d+P));break;case bo:b&&(a=Mo(E,Ao(k,i-O*b)),h=Mo(E,Ao(k,f+O*b))),w&&(u=Mo(C,Ao(S,s-P*w)),p=Mo(C,Ao(S,d+P*w)))}h<a&&(b*=-1,r=i,i=f,f=r,r=a,a=h,h=r,x in Po&&N.attr("cursor",Oo[x=Po[x]])),p<u&&(w*=-1,r=s,s=d,d=r,r=u,u=p,p=r,x in Lo&&N.attr("cursor",Oo[x=Lo[x]])),M.selection&&(T=M.selection),g&&(a=T[0][0],h=T[1][0]),y&&(u=T[0][1],p=T[1][1]),T[0][0]===a&&T[0][1]===u&&T[1][0]===h&&T[1][1]===p||(M.selection=[[a,u],[h,p]],l.call(v),I.brush(t,_.name))}function B(t){if(function(t){t.stopImmediatePropagation()}(t),t.touches){if(t.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500)}else Xn(t.view,m),F.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);D.attr("pointer-events","all"),N.attr("cursor",Oo.overlay),M.selection&&(T=M.selection),function(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}(T)&&(M.selection=null,l.call(v)),I.end(t,_.name)}}function d(t){c(this,arguments).moved(t)}function p(t){c(this,arguments).ended(t)}function m(){var e=this.__brush||{selection:null};return e.extent=Eo(n.apply(this,arguments)),e.dim=t,e}return u.move=function(e,n,r){e.tween?e.on("start.brush",(function(t){c(this,arguments).beforestart().start(t)})).on("interrupt.brush end.brush",(function(t){c(this,arguments).end(t)})).tween("brush",(function(){var e=this,r=e.__brush,i=c(e,arguments),o=r.selection,a=t.input("function"==typeof n?n.apply(this,arguments):n,r.extent),s=Zr(o,a);function u(t){r.selection=1===t&&null===a?null:s(t),l.call(e),i.brush()}return null!==o&&null!==a?u:u(1)})):e.each((function(){var e=this,i=arguments,o=e.__brush,a=t.input("function"==typeof n?n.apply(e,i):n,o.extent),s=c(e,i).beforestart();Oi(e),o.selection=null===a?null:a,l.call(e),s.start(r).brush(r).end(r)}))},u.clear=function(t,e){u.move(t,null,e)},f.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(t,e){return this.starting?(this.starting=!1,this.emit("start",t,e)):this.emit("brush",t),this},brush:function(t,e){return this.emit("brush",t,e),this},end:function(t,e){return 0==--this.active&&(delete this.state.emitter,this.emit("end",t,e)),this},emit:function(e,n,r){var i=Vn(this.that).datum();a.call(e,this.that,new go(e,{sourceEvent:n,target:u,selection:t.output(this.state.selection),mode:r,dispatch:a}),i)}},u.extent=function(t){return arguments.length?(n="function"==typeof t?t:mo(Eo(t)),u):n},u.filter=function(t){return arguments.length?(r="function"==typeof t?t:mo(!!t),u):r},u.touchable=function(t){return arguments.length?(i="function"==typeof t?t:mo(!!t),u):i},u.handleSize=function(t){return arguments.length?(s=+t,u):s},u.keyModifiers=function(t){return arguments.length?(o=!!t,u):o},u.on=function(){var t=a.on.apply(a,arguments);return t===a?u:t},u}var Ho=Math.abs,Wo=Math.cos,Xo=Math.sin,Ko=Math.PI,Qo=Ko/2,Yo=2*Ko,$o=Math.max,Zo=1e-12;function Jo(t,e){return Array.from({length:e-t},((e,n)=>t+n))}function ta(){return ra(!1,!1)}function ea(){return ra(!1,!0)}function na(){return ra(!0,!1)}function ra(t,e){var n=0,r=null,i=null,o=null;function a(a){var s,u=a.length,l=new Array(u),c=Jo(0,u),f=new Array(u*u),h=new Array(u),d=0;a=Float64Array.from({length:u*u},e?(t,e)=>a[e%u][e/u|0]:(t,e)=>a[e/u|0][e%u]);for(let e=0;e<u;++e){let n=0;for(let r=0;r<u;++r)n+=a[e*u+r]+t*a[r*u+e];d+=l[e]=n}s=(d=$o(0,Yo-n*u)/d)?n:Yo/u;{let e=0;r&&c.sort(((t,e)=>r(l[t],l[e])));for(const n of c){const r=e;if(t){const t=Jo(1+~u,u).filter((t=>t<0?a[~t*u+n]:a[n*u+t]));i&&t.sort(((t,e)=>i(t<0?-a[~t*u+n]:a[n*u+t],e<0?-a[~e*u+n]:a[n*u+e])));for(const r of t)if(r<0){(f[~r*u+n]||(f[~r*u+n]={source:null,target:null})).target={index:n,startAngle:e,endAngle:e+=a[~r*u+n]*d,value:a[~r*u+n]}}else{(f[n*u+r]||(f[n*u+r]={source:null,target:null})).source={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]}}h[n]={index:n,startAngle:r,endAngle:e,value:l[n]}}else{const t=Jo(0,u).filter((t=>a[n*u+t]||a[t*u+n]));i&&t.sort(((t,e)=>i(a[n*u+t],a[n*u+e])));for(const r of t){let t;if(n<r?(t=f[n*u+r]||(f[n*u+r]={source:null,target:null}),t.source={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]}):(t=f[r*u+n]||(f[r*u+n]={source:null,target:null}),t.target={index:n,startAngle:e,endAngle:e+=a[n*u+r]*d,value:a[n*u+r]},n===r&&(t.source=t.target)),t.source&&t.target&&t.source.value<t.target.value){const e=t.source;t.source=t.target,t.target=e}}h[n]={index:n,startAngle:r,endAngle:e,value:l[n]}}e+=s}}return(f=Object.values(f)).groups=h,o?f.sort(o):f}return a.padAngle=function(t){return arguments.length?(n=$o(0,t),a):n},a.sortGroups=function(t){return arguments.length?(r=t,a):r},a.sortSubgroups=function(t){return arguments.length?(i=t,a):i},a.sortChords=function(t){return arguments.length?(null==t?o=null:(e=t,o=function(t,n){return e(t.source.value+t.target.value,n.source.value+n.target.value)})._=t,a):o&&o._;var e},a}const ia=Math.PI,oa=2*ia,aa=1e-6,sa=oa-aa;function ua(t){this._+=t[0];for(let e=1,n=t.length;e<n;++e)this._+=arguments[e]+t[e]}class la{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==t?ua:function(t){let e=Math.floor(t);if(!(e>=0))throw new Error(`invalid digits: ${t}`);if(e>15)return ua;const n=10**e;return function(t){this._+=t[0];for(let e=1,r=t.length;e<r;++e)this._+=Math.round(arguments[e]*n)/n+t[e]}}(t)}moveTo(t,e){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,e){this._append`L${this._x1=+t},${this._y1=+e}`}quadraticCurveTo(t,e,n,r){this._append`Q${+t},${+e},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(t,e,n,r,i,o){this._append`C${+t},${+e},${+n},${+r},${this._x1=+i},${this._y1=+o}`}arcTo(t,e,n,r,i){if(t=+t,e=+e,n=+n,r=+r,(i=+i)<0)throw new Error(`negative radius: ${i}`);let o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,f=l*l+c*c;if(null===this._x1)this._append`M${this._x1=t},${this._y1=e}`;else if(f>aa)if(Math.abs(c*s-u*l)>aa&&i){let h=n-o,d=r-a,p=s*s+u*u,m=h*h+d*d,g=Math.sqrt(p),y=Math.sqrt(f),v=i*Math.tan((ia-Math.acos((p+f-m)/(2*g*y)))/2),x=v/y,_=v/g;Math.abs(x-1)>aa&&this._append`L${t+x*l},${e+x*c}`,this._append`A${i},${i},0,0,${+(c*h>l*d)},${this._x1=t+_*s},${this._y1=e+_*u}`}else this._append`L${this._x1=t},${this._y1=e}`;else;}arc(t,e,n,r,i,o){if(t=+t,e=+e,o=!!o,(n=+n)<0)throw new Error(`negative radius: ${n}`);let a=n*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,f=o?r-i:i-r;null===this._x1?this._append`M${u},${l}`:(Math.abs(this._x1-u)>aa||Math.abs(this._y1-l)>aa)&&this._append`L${u},${l}`,n&&(f<0&&(f=f%oa+oa),f>sa?this._append`A${n},${n},0,1,${c},${t-a},${e-s}A${n},${n},0,1,${c},${this._x1=u},${this._y1=l}`:f>aa&&this._append`A${n},${n},0,${+(f>=ia)},${c},${this._x1=t+n*Math.cos(i)},${this._y1=e+n*Math.sin(i)}`)}rect(t,e,n,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}}function ca(){return new la}function fa(t=3){return new la(+t)}ca.prototype=la.prototype;var ha=Array.prototype.slice;function da(t){return function(){return t}}function pa(t){return t.source}function ma(t){return t.target}function ga(t){return t.radius}function ya(t){return t.startAngle}function va(t){return t.endAngle}function xa(){return 0}function _a(){return 10}function ba(t){var e=pa,n=ma,r=ga,i=ga,o=ya,a=va,s=xa,u=null;function l(){var l,c=e.apply(this,arguments),f=n.apply(this,arguments),h=s.apply(this,arguments)/2,d=ha.call(arguments),p=+r.apply(this,(d[0]=c,d)),m=o.apply(this,d)-Qo,g=a.apply(this,d)-Qo,y=+i.apply(this,(d[0]=f,d)),v=o.apply(this,d)-Qo,x=a.apply(this,d)-Qo;if(u||(u=l=ca()),h>Zo&&(Ho(g-m)>2*h+Zo?g>m?(m+=h,g-=h):(m-=h,g+=h):m=g=(m+g)/2,Ho(x-v)>2*h+Zo?x>v?(v+=h,x-=h):(v-=h,x+=h):v=x=(v+x)/2),u.moveTo(p*Wo(m),p*Xo(m)),u.arc(0,0,p,m,g),m!==v||g!==x)if(t){var _=y-+t.apply(this,arguments),b=(v+x)/2;u.quadraticCurveTo(0,0,_*Wo(v),_*Xo(v)),u.lineTo(y*Wo(b),y*Xo(b)),u.lineTo(_*Wo(x),_*Xo(x))}else u.quadraticCurveTo(0,0,y*Wo(v),y*Xo(v)),u.arc(0,0,y,v,x);if(u.quadraticCurveTo(0,0,p*Wo(m),p*Xo(m)),u.closePath(),l)return u=null,l+""||null}return t&&(l.headRadius=function(e){return arguments.length?(t="function"==typeof e?e:da(+e),l):t}),l.radius=function(t){return arguments.length?(r=i="function"==typeof t?t:da(+t),l):r},l.sourceRadius=function(t){return arguments.length?(r="function"==typeof t?t:da(+t),l):r},l.targetRadius=function(t){return arguments.length?(i="function"==typeof t?t:da(+t),l):i},l.startAngle=function(t){return arguments.length?(o="function"==typeof t?t:da(+t),l):o},l.endAngle=function(t){return arguments.length?(a="function"==typeof t?t:da(+t),l):a},l.padAngle=function(t){return arguments.length?(s="function"==typeof t?t:da(+t),l):s},l.source=function(t){return arguments.length?(e=t,l):e},l.target=function(t){return arguments.length?(n=t,l):n},l.context=function(t){return arguments.length?(u=null==t?null:t,l):u},l}function wa(){return ba()}function Ma(){return ba(_a)}const Aa=Math.PI/180,Ta=180/Math.PI,Ea=.96422,Ca=1,ka=.82521,Sa=4/29,Oa=6/29,Pa=3*Oa*Oa,La=Oa*Oa*Oa;function Ra(t){if(t instanceof Na)return new Na(t.l,t.a,t.b,t.opacity);if(t instanceof Ua)return Ha(t);t instanceof yr||(t=mr(t));var e,n,r=Ba(t.r),i=Ba(t.g),o=Ba(t.b),a=Fa((.2225045*r+.7168786*i+.0606169*o)/Ca);return r===i&&i===o?e=n=a:(e=Fa((.4360747*r+.3850649*i+.1430804*o)/Ea),n=Fa((.0139322*r+.0971045*i+.7141733*o)/ka)),new Na(116*a-16,500*(e-a),200*(a-n),t.opacity)}function Ia(t,e){return new Na(t,0,0,null==e?1:e)}function Da(t,e,n,r){return 1===arguments.length?Ra(t):new Na(t,e,n,null==r?1:r)}function Na(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}function Fa(t){return t>La?Math.pow(t,1/3):t/Pa+Sa}function ja(t){return t>Oa?t*t*t:Pa*(t-Sa)}function za(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Ba(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Va(t){if(t instanceof Ua)return new Ua(t.h,t.c,t.l,t.opacity);if(t instanceof Na||(t=Ra(t)),0===t.a&&0===t.b)return new Ua(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*Ta;return new Ua(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function qa(t,e,n,r){return 1===arguments.length?Va(t):new Ua(n,e,t,null==r?1:r)}function Ga(t,e,n,r){return 1===arguments.length?Va(t):new Ua(t,e,n,null==r?1:r)}function Ua(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}function Ha(t){if(isNaN(t.h))return new Na(t.l,0,0,t.opacity);var e=t.h*Aa;return new Na(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}Kn(Na,Da,Qn(Yn,{brighter(t){return new Na(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker(t){return new Na(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new yr(za(3.1338561*(e=Ea*ja(e))-1.6168667*(t=Ca*ja(t))-.4906146*(n=ka*ja(n))),za(-.9787684*e+1.9161415*t+.033454*n),za(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),Kn(Ua,Ga,Qn(Yn,{brighter(t){return new Ua(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker(t){return new Ua(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb(){return Ha(this).rgb()}}));var Wa=-.14861,Xa=1.78277,Ka=-.29227,Qa=-.90649,Ya=1.97294,$a=Ya*Qa,Za=Ya*Xa,Ja=Xa*Ka-Qa*Wa;function ts(t,e,n,r){return 1===arguments.length?function(t){if(t instanceof es)return new es(t.h,t.s,t.l,t.opacity);t instanceof yr||(t=mr(t));var e=t.r/255,n=t.g/255,r=t.b/255,i=(Ja*r+$a*e-Za*n)/(Ja+$a-Za),o=r-i,a=(Ya*(n-i)-Ka*o)/Qa,s=Math.sqrt(a*a+o*o)/(Ya*i*(1-i)),u=s?Math.atan2(a,o)*Ta-120:NaN;return new es(u<0?u+360:u,s,i,t.opacity)}(t):new es(t,e,n,null==r?1:r)}function es(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}Kn(es,ts,Qn(Yn,{brighter(t){return t=null==t?Zn:Math.pow(Zn,t),new es(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?$n:Math.pow($n,t),new es(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=isNaN(this.h)?0:(this.h+120)*Aa,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),r=Math.cos(t),i=Math.sin(t);return new yr(255*(e+n*(Wa*r+Xa*i)),255*(e+n*(Ka*r+Qa*i)),255*(e+n*(Ya*r)),this.opacity)}}));var ns=Array.prototype.slice;function rs(t,e){return t-e}var is=t=>()=>t;function os(t,e){for(var n,r=-1,i=e.length;++r<i;)if(n=as(t,e[r]))return n;return 0}function as(t,e){for(var n=e[0],r=e[1],i=-1,o=0,a=t.length,s=a-1;o<a;s=o++){var u=t[o],l=u[0],c=u[1],f=t[s],h=f[0],d=f[1];if(ss(u,f,e))return 0;c>r!=d>r&&n<(h-l)*(r-c)/(d-c)+l&&(i=-i)}return i}function ss(t,e,n){var r,i,o,a;return function(t,e,n){return(e[0]-t[0])*(n[1]-t[1])==(n[0]-t[0])*(e[1]-t[1])}(t,e,n)&&(i=t[r=+(t[0]===e[0])],o=n[r],a=e[r],i<=o&&o<=a||a<=o&&o<=i)}function us(){}var ls=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]];function cs(){var t=1,e=1,n=ht,r=s;function i(t){var e=n(t);if(Array.isArray(e))e=e.slice().sort(rs);else{const n=k(t,fs);for(e=ut(...ft(n[0],n[1],e),e);e[e.length-1]>=n[1];)e.pop();for(;e[1]<n[0];)e.shift()}return e.map((e=>o(t,e)))}function o(n,i){const o=null==i?NaN:+i;if(isNaN(o))throw new Error(`invalid value: ${i}`);var s=[],u=[];return function(n,r,i){var o,s,u,l,c,f,h=new Array,d=new Array;o=s=-1,l=hs(n[0],r),ls[l<<1].forEach(p);for(;++o<t-1;)u=l,l=hs(n[o+1],r),ls[u|l<<1].forEach(p);ls[l|0].forEach(p);for(;++s<e-1;){for(o=-1,l=hs(n[s*t+t],r),c=hs(n[s*t],r),ls[l<<1|c<<2].forEach(p);++o<t-1;)u=l,l=hs(n[s*t+t+o+1],r),f=c,c=hs(n[s*t+o+1],r),ls[u|l<<1|c<<2|f<<3].forEach(p);ls[l|c<<3].forEach(p)}o=-1,c=n[s*t]>=r,ls[c<<2].forEach(p);for(;++o<t-1;)f=c,c=hs(n[s*t+o+1],r),ls[c<<2|f<<3].forEach(p);function p(t){var e,n,r=[t[0][0]+o,t[0][1]+s],u=[t[1][0]+o,t[1][1]+s],l=a(r),c=a(u);(e=d[l])?(n=h[c])?(delete d[e.end],delete h[n.start],e===n?(e.ring.push(u),i(e.ring)):h[e.start]=d[n.end]={start:e.start,end:n.end,ring:e.ring.concat(n.ring)}):(delete d[e.end],e.ring.push(u),d[e.end=c]=e):(e=h[c])?(n=d[l])?(delete h[e.start],delete d[n.end],e===n?(e.ring.push(u),i(e.ring)):h[n.start]=d[e.end]={start:n.start,end:e.end,ring:n.ring.concat(e.ring)}):(delete h[e.start],e.ring.unshift(r),h[e.start=l]=e):h[l]=d[c]={start:l,end:c,ring:[r,u]}}ls[c<<3].forEach(p)}(n,o,(function(t){r(t,n,o),function(t){for(var e=0,n=t.length,r=t[n-1][1]*t[0][0]-t[n-1][0]*t[0][1];++e<n;)r+=t[e-1][1]*t[e][0]-t[e-1][0]*t[e][1];return r}(t)>0?s.push([t]):u.push(t)})),u.forEach((function(t){for(var e,n=0,r=s.length;n<r;++n)if(-1!==os((e=s[n])[0],t))return void e.push(t)})),{type:"MultiPolygon",value:i,coordinates:s}}function a(e){return 2*e[0]+e[1]*(t+1)*4}function s(n,r,i){n.forEach((function(n){var o=n[0],a=n[1],s=0|o,u=0|a,l=ds(r[u*t+s]);o>0&&o<t&&s===o&&(n[0]=ps(o,ds(r[u*t+s-1]),l,i)),a>0&&a<e&&u===a&&(n[1]=ps(a,ds(r[(u-1)*t+s]),l,i))}))}return i.contour=o,i.size=function(n){if(!arguments.length)return[t,e];var r=Math.floor(n[0]),o=Math.floor(n[1]);if(!(r>=0&&o>=0))throw new Error("invalid size");return t=r,e=o,i},i.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?is(ns.call(t)):is(t),i):n},i.smooth=function(t){return arguments.length?(r=t?s:us,i):r===s},i}function fs(t){return isFinite(t)?t:NaN}function hs(t,e){return null!=t&&+t>=e}function ds(t){return null==t||isNaN(t=+t)?-1/0:t}function ps(t,e,n,r){const i=r-e,o=n-e,a=isFinite(i)||isFinite(o)?i/o:Math.sign(i)/Math.sign(o);return isNaN(a)?t:t+a-.5}function ms(t){return t[0]}function gs(t){return t[1]}function ys(){return 1}function vs(){var t=ms,e=gs,n=ys,r=960,i=500,o=20,a=2,s=3*o,u=r+2*s>>a,l=i+2*s>>a,c=is(20);function f(r){var i=new Float32Array(u*l),c=Math.pow(2,-a),f=-1;for(const o of r){var h=(t(o,++f,r)+s)*c,d=(e(o,f,r)+s)*c,m=+n(o,f,r);if(m&&h>=0&&h<u&&d>=0&&d<l){var g=Math.floor(h),y=Math.floor(d),v=h-g-.5,x=d-y-.5;i[g+y*u]+=(1-v)*(1-x)*m,i[g+1+y*u]+=v*(1-x)*m,i[g+1+(y+1)*u]+=v*x*m,i[g+(y+1)*u]+=(1-v)*x*m}}return p({data:i,width:u,height:l},o*c),i}function h(t){var e=f(t),n=c(e),r=Math.pow(2,2*a);return Array.isArray(n)||(n=ut(Number.MIN_VALUE,pt(e)/r,n)),cs().size([u,l]).thresholds(n.map((t=>t*r)))(e).map(((t,e)=>(t.value=+n[e],d(t))))}function d(t){return t.coordinates.forEach(m),t}function m(t){t.forEach(g)}function g(t){t.forEach(y)}function y(t){t[0]=t[0]*Math.pow(2,a)-s,t[1]=t[1]*Math.pow(2,a)-s}function v(){return u=r+2*(s=3*o)>>a,l=i+2*s>>a,h}return h.contours=function(t){var e=f(t),n=cs().size([u,l]),r=Math.pow(2,2*a),i=t=>{t=+t;var i=d(n.contour(e,t*r));return i.value=t,i};return Object.defineProperty(i,"max",{get:()=>pt(e)/r}),i},h.x=function(e){return arguments.length?(t="function"==typeof e?e:is(+e),h):t},h.y=function(t){return arguments.length?(e="function"==typeof t?t:is(+t),h):e},h.weight=function(t){return arguments.length?(n="function"==typeof t?t:is(+t),h):n},h.size=function(t){if(!arguments.length)return[r,i];var e=+t[0],n=+t[1];if(!(e>=0&&n>=0))throw new Error("invalid size");return r=e,i=n,v()},h.cellSize=function(t){if(!arguments.length)return 1<<a;if(!((t=+t)>=1))throw new Error("invalid cell size");return a=Math.floor(Math.log(t)/Math.LN2),v()},h.thresholds=function(t){return arguments.length?(c="function"==typeof t?t:Array.isArray(t)?is(ns.call(t)):is(t),h):c},h.bandwidth=function(t){if(!arguments.length)return Math.sqrt(o*(o+1));if(!((t=+t)>=0))throw new Error("invalid bandwidth");return o=(Math.sqrt(4*t*t+1)-1)/2,v()},h}const xs=134217729;function _s(t,e,n,r,i){let o,a,s,u,l=e[0],c=r[0],f=0,h=0;c>l==c>-l?(o=l,l=e[++f]):(o=c,c=r[++h]);let d=0;if(f<t&&h<n)for(c>l==c>-l?(a=l+o,s=o-(a-l),l=e[++f]):(a=c+o,s=o-(a-c),c=r[++h]),o=a,0!==s&&(i[d++]=s);f<t&&h<n;)c>l==c>-l?(a=o+l,u=a-o,s=o-(a-u)+(l-u),l=e[++f]):(a=o+c,u=a-o,s=o-(a-u)+(c-u),c=r[++h]),o=a,0!==s&&(i[d++]=s);for(;f<t;)a=o+l,u=a-o,s=o-(a-u)+(l-u),l=e[++f],o=a,0!==s&&(i[d++]=s);for(;h<n;)a=o+c,u=a-o,s=o-(a-u)+(c-u),c=r[++h],o=a,0!==s&&(i[d++]=s);return 0===o&&0!==d||(i[d++]=o),d}function bs(t){return new Float64Array(t)}const ws=bs(4),Ms=bs(8),As=bs(12),Ts=bs(16),Es=bs(4);function Cs(t,e,n,r,i,o){const a=(e-o)*(n-i),s=(t-i)*(r-o),u=a-s,l=Math.abs(a+s);return Math.abs(u)>=33306690738754716e-32*l?u:-function(t,e,n,r,i,o,a){let s,u,l,c,f,h,d,p,m,g,y,v,x,_,b,w,M,A;const T=t-i,E=n-i,C=e-o,k=r-o;_=T*k,h=xs*T,d=h-(h-T),p=T-d,h=xs*k,m=h-(h-k),g=k-m,b=p*g-(_-d*m-p*m-d*g),w=C*E,h=xs*C,d=h-(h-C),p=C-d,h=xs*E,m=h-(h-E),g=E-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,ws[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,ws[1]=x-(y+f)+(f-w),A=v+y,f=A-v,ws[2]=v-(A-f)+(y-f),ws[3]=A;let S=function(t,e){let n=e[0];for(let r=1;r<t;r++)n+=e[r];return n}(4,ws),O=22204460492503146e-32*a;if(S>=O||-S>=O)return S;if(f=t-T,s=t-(T+f)+(f-i),f=n-E,l=n-(E+f)+(f-i),f=e-C,u=e-(C+f)+(f-o),f=r-k,c=r-(k+f)+(f-o),0===s&&0===u&&0===l&&0===c)return S;if(O=11093356479670487e-47*a+33306690738754706e-32*Math.abs(S),S+=T*c+k*s-(C*l+E*u),S>=O||-S>=O)return S;_=s*k,h=xs*s,d=h-(h-s),p=s-d,h=xs*k,m=h-(h-k),g=k-m,b=p*g-(_-d*m-p*m-d*g),w=u*E,h=xs*u,d=h-(h-u),p=u-d,h=xs*E,m=h-(h-E),g=E-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const P=_s(4,ws,4,Es,Ms);_=T*c,h=xs*T,d=h-(h-T),p=T-d,h=xs*c,m=h-(h-c),g=c-m,b=p*g-(_-d*m-p*m-d*g),w=C*l,h=xs*C,d=h-(h-C),p=C-d,h=xs*l,m=h-(h-l),g=l-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const L=_s(P,Ms,4,Es,As);_=s*c,h=xs*s,d=h-(h-s),p=s-d,h=xs*c,m=h-(h-c),g=c-m,b=p*g-(_-d*m-p*m-d*g),w=u*l,h=xs*u,d=h-(h-u),p=u-d,h=xs*l,m=h-(h-l),g=l-m,M=p*g-(w-d*m-p*m-d*g),y=b-M,f=b-y,Es[0]=b-(y+f)+(f-M),v=_+y,f=v-_,x=_-(v-f)+(y-f),y=x-w,f=x-y,Es[1]=x-(y+f)+(f-w),A=v+y,f=A-v,Es[2]=v-(A-f)+(y-f),Es[3]=A;const R=_s(L,As,4,Es,Ts);return Ts[R-1]}(t,e,n,r,i,o,l)}bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(8),bs(8),bs(8),bs(4),bs(8),bs(8),bs(8),bs(12);bs(192),bs(192);bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(8),bs(4),bs(4),bs(4),bs(8),bs(16),bs(16),bs(16),bs(32),bs(32),bs(48),bs(64);bs(1152),bs(1152);bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(4),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(24),bs(1152),bs(1152),bs(1152),bs(1152),bs(1152),bs(2304),bs(2304),bs(3456),bs(5760),bs(8),bs(8),bs(8),bs(16),bs(24),bs(48),bs(48),bs(96),bs(192),bs(384),bs(384),bs(384),bs(768);bs(96),bs(96),bs(96),bs(1152);const ks=Math.pow(2,-52),Ss=new Uint32Array(512);class Os{static from(t,e=Ns,n=Fs){const r=t.length,i=new Float64Array(2*r);for(let o=0;o<r;o++){const r=t[o];i[2*o]=e(r),i[2*o+1]=n(r)}return new Os(i)}constructor(t){const e=t.length>>1;if(e>0&&"number"!=typeof t[0])throw new Error("Expected coords to contain numbers.");this.coords=t;const n=Math.max(2*e-5,0);this._triangles=new Uint32Array(3*n),this._halfedges=new Int32Array(3*n),this._hashSize=Math.ceil(Math.sqrt(e)),this._hullPrev=new Uint32Array(e),this._hullNext=new Uint32Array(e),this._hullTri=new Uint32Array(e),this._hullHash=new Int32Array(this._hashSize),this._ids=new Uint32Array(e),this._dists=new Float64Array(e),this.update()}update(){const{coords:t,_hullPrev:e,_hullNext:n,_hullTri:r,_hullHash:i}=this,o=t.length>>1;let a=1/0,s=1/0,u=-1/0,l=-1/0;for(let e=0;e<o;e++){const n=t[2*e],r=t[2*e+1];n<a&&(a=n),r<s&&(s=r),n>u&&(u=n),r>l&&(l=r),this._ids[e]=e}const c=(a+u)/2,f=(s+l)/2;let h,d,p;for(let e=0,n=1/0;e<o;e++){const r=Ps(c,f,t[2*e],t[2*e+1]);r<n&&(h=e,n=r)}const m=t[2*h],g=t[2*h+1];for(let e=0,n=1/0;e<o;e++){if(e===h)continue;const r=Ps(m,g,t[2*e],t[2*e+1]);r<n&&r>0&&(d=e,n=r)}let y=t[2*d],v=t[2*d+1],x=1/0;for(let e=0;e<o;e++){if(e===h||e===d)continue;const n=Rs(m,g,y,v,t[2*e],t[2*e+1]);n<x&&(p=e,x=n)}let _=t[2*p],b=t[2*p+1];if(x===1/0){for(let e=0;e<o;e++)this._dists[e]=t[2*e]-t[0]||t[2*e+1]-t[1];Is(this._ids,this._dists,0,o-1);const e=new Uint32Array(o);let n=0;for(let t=0,r=-1/0;t<o;t++){const i=this._ids[t],o=this._dists[i];o>r&&(e[n++]=i,r=o)}return this.hull=e.subarray(0,n),this.triangles=new Uint32Array(0),void(this.halfedges=new Uint32Array(0))}if(Cs(m,g,y,v,_,b)<0){const t=d,e=y,n=v;d=p,y=_,v=b,p=t,_=e,b=n}const w=function(t,e,n,r,i,o){const a=n-t,s=r-e,u=i-t,l=o-e,c=a*a+s*s,f=u*u+l*l,h=.5/(a*l-s*u),d=t+(l*c-s*f)*h,p=e+(a*f-u*c)*h;return{x:d,y:p}}(m,g,y,v,_,b);this._cx=w.x,this._cy=w.y;for(let e=0;e<o;e++)this._dists[e]=Ps(t[2*e],t[2*e+1],w.x,w.y);Is(this._ids,this._dists,0,o-1),this._hullStart=h;let M=3;n[h]=e[p]=d,n[d]=e[h]=p,n[p]=e[d]=h,r[h]=0,r[d]=1,r[p]=2,i.fill(-1),i[this._hashKey(m,g)]=h,i[this._hashKey(y,v)]=d,i[this._hashKey(_,b)]=p,this.trianglesLen=0,this._addTriangle(h,d,p,-1,-1,-1);for(let o,a,s=0;s<this._ids.length;s++){const u=this._ids[s],l=t[2*u],c=t[2*u+1];if(s>0&&Math.abs(l-o)<=ks&&Math.abs(c-a)<=ks)continue;if(o=l,a=c,u===h||u===d||u===p)continue;let f=0;for(let t=0,e=this._hashKey(l,c);t<this._hashSize&&(f=i[(e+t)%this._hashSize],-1===f||f===n[f]);t++);f=e[f];let m,g=f;for(;m=n[g],Cs(l,c,t[2*g],t[2*g+1],t[2*m],t[2*m+1])>=0;)if(g=m,g===f){g=-1;break}if(-1===g)continue;let y=this._addTriangle(g,u,n[g],-1,-1,r[g]);r[u]=this._legalize(y+2),r[g]=y,M++;let v=n[g];for(;m=n[v],Cs(l,c,t[2*v],t[2*v+1],t[2*m],t[2*m+1])<0;)y=this._addTriangle(v,u,m,r[u],-1,r[v]),r[u]=this._legalize(y+2),n[v]=v,M--,v=m;if(g===f)for(;m=e[g],Cs(l,c,t[2*m],t[2*m+1],t[2*g],t[2*g+1])<0;)y=this._addTriangle(m,u,g,-1,r[g],r[m]),this._legalize(y+2),r[m]=y,n[g]=g,M--,g=m;this._hullStart=e[u]=g,n[g]=e[v]=u,n[u]=v,i[this._hashKey(l,c)]=u,i[this._hashKey(t[2*g],t[2*g+1])]=g}this.hull=new Uint32Array(M);for(let t=0,e=this._hullStart;t<M;t++)this.hull[t]=e,e=n[e];this.triangles=this._triangles.subarray(0,this.trianglesLen),this.halfedges=this._halfedges.subarray(0,this.trianglesLen)}_hashKey(t,e){return Math.floor(function(t,e){const n=t/(Math.abs(t)+Math.abs(e));return(e>0?3-n:1+n)/4}(t-this._cx,e-this._cy)*this._hashSize)%this._hashSize}_legalize(t){const{_triangles:e,_halfedges:n,coords:r}=this;let i=0,o=0;for(;;){const a=n[t],s=t-t%3;if(o=s+(t+2)%3,-1===a){if(0===i)break;t=Ss[--i];continue}const u=a-a%3,l=s+(t+1)%3,c=u+(a+2)%3,f=e[o],h=e[t],d=e[l],p=e[c];if(Ls(r[2*f],r[2*f+1],r[2*h],r[2*h+1],r[2*d],r[2*d+1],r[2*p],r[2*p+1])){e[t]=p,e[a]=f;const r=n[c];if(-1===r){let e=this._hullStart;do{if(this._hullTri[e]===c){this._hullTri[e]=t;break}e=this._hullPrev[e]}while(e!==this._hullStart)}this._link(t,r),this._link(a,n[o]),this._link(o,c);const s=u+(a+1)%3;i<Ss.length&&(Ss[i++]=s)}else{if(0===i)break;t=Ss[--i]}}return o}_link(t,e){this._halfedges[t]=e,-1!==e&&(this._halfedges[e]=t)}_addTriangle(t,e,n,r,i,o){const a=this.trianglesLen;return this._triangles[a]=t,this._triangles[a+1]=e,this._triangles[a+2]=n,this._link(a,r),this._link(a+1,i),this._link(a+2,o),this.trianglesLen+=3,a}}function Ps(t,e,n,r){const i=t-n,o=e-r;return i*i+o*o}function Ls(t,e,n,r,i,o,a,s){const u=t-a,l=e-s,c=n-a,f=r-s,h=i-a,d=o-s,p=c*c+f*f,m=h*h+d*d;return u*(f*m-p*d)-l*(c*m-p*h)+(u*u+l*l)*(c*d-f*h)<0}function Rs(t,e,n,r,i,o){const a=n-t,s=r-e,u=i-t,l=o-e,c=a*a+s*s,f=u*u+l*l,h=.5/(a*l-s*u),d=(l*c-s*f)*h,p=(a*f-u*c)*h;return d*d+p*p}function Is(t,e,n,r){if(r-n<=20)for(let i=n+1;i<=r;i++){const r=t[i],o=e[r];let a=i-1;for(;a>=n&&e[t[a]]>o;)t[a+1]=t[a--];t[a+1]=r}else{let i=n+1,o=r;Ds(t,n+r>>1,i),e[t[n]]>e[t[r]]&&Ds(t,n,r),e[t[i]]>e[t[r]]&&Ds(t,i,r),e[t[n]]>e[t[i]]&&Ds(t,n,i);const a=t[i],s=e[a];for(;;){do{i++}while(e[t[i]]<s);do{o--}while(e[t[o]]>s);if(o<i)break;Ds(t,i,o)}t[n+1]=t[o],t[o]=a,r-i+1>=o-n?(Is(t,e,i,r),Is(t,e,n,o-1)):(Is(t,e,n,o-1),Is(t,e,i,r))}}function Ds(t,e,n){const r=t[e];t[e]=t[n],t[n]=r}function Ns(t){return t[0]}function Fs(t){return t[1]}const js=1e-6;class zs{constructor(){this._x0=this._y0=this._x1=this._y1=null,this._=""}moveTo(t,e){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")}lineTo(t,e){this._+=`L${this._x1=+t},${this._y1=+e}`}arc(t,e,n){const r=(t=+t)+(n=+n),i=e=+e;if(n<0)throw new Error("negative radius");null===this._x1?this._+=`M${r},${i}`:(Math.abs(this._x1-r)>js||Math.abs(this._y1-i)>js)&&(this._+="L"+r+","+i),n&&(this._+=`A${n},${n},0,1,1,${t-n},${e}A${n},${n},0,1,1,${this._x1=r},${this._y1=i}`)}rect(t,e,n,r){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${+n}v${+r}h${-n}Z`}value(){return this._||null}}class Bs{constructor(){this._=[]}moveTo(t,e){this._.push([t,e])}closePath(){this._.push(this._[0].slice())}lineTo(t,e){this._.push([t,e])}value(){return this._.length?this._:null}}class Vs{constructor(t,[e,n,r,i]=[0,0,960,500]){if(!((r=+r)>=(e=+e)&&(i=+i)>=(n=+n)))throw new Error("invalid bounds");this.delaunay=t,this._circumcenters=new Float64Array(2*t.points.length),this.vectors=new Float64Array(2*t.points.length),this.xmax=r,this.xmin=e,this.ymax=i,this.ymin=n,this._init()}update(){return this.delaunay.update(),this._init(),this}_init(){const{delaunay:{points:t,hull:e,triangles:n},vectors:r}=this;let i,o;const a=this.circumcenters=this._circumcenters.subarray(0,n.length/3*2);for(let r,s,u=0,l=0,c=n.length;u<c;u+=3,l+=2){const c=2*n[u],f=2*n[u+1],h=2*n[u+2],d=t[c],p=t[c+1],m=t[f],g=t[f+1],y=t[h],v=t[h+1],x=m-d,_=g-p,b=y-d,w=v-p,M=2*(x*w-_*b);if(Math.abs(M)<1e-9){if(void 0===i){i=o=0;for(const n of e)i+=t[2*n],o+=t[2*n+1];i/=e.length,o/=e.length}const n=1e9*Math.sign((i-d)*w-(o-p)*b);r=(d+y)/2-n*w,s=(p+v)/2+n*b}else{const t=1/M,e=x*x+_*_,n=b*b+w*w;r=d+(w*e-_*n)*t,s=p+(x*n-b*e)*t}a[l]=r,a[l+1]=s}let s,u,l,c=e[e.length-1],f=4*c,h=t[2*c],d=t[2*c+1];r.fill(0);for(let n=0;n<e.length;++n)c=e[n],s=f,u=h,l=d,f=4*c,h=t[2*c],d=t[2*c+1],r[s+2]=r[f]=l-d,r[s+3]=r[f+1]=h-u}render(t){const e=null==t?t=new zs:void 0,{delaunay:{halfedges:n,inedges:r,hull:i},circumcenters:o,vectors:a}=this;if(i.length<=1)return null;for(let e=0,r=n.length;e<r;++e){const r=n[e];if(r<e)continue;const i=2*Math.floor(e/3),a=2*Math.floor(r/3),s=o[i],u=o[i+1],l=o[a],c=o[a+1];this._renderSegment(s,u,l,c,t)}let s,u=i[i.length-1];for(let e=0;e<i.length;++e){s=u,u=i[e];const n=2*Math.floor(r[u]/3),l=o[n],c=o[n+1],f=4*s,h=this._project(l,c,a[f+2],a[f+3]);h&&this._renderSegment(l,c,h[0],h[1],t)}return e&&e.value()}renderBounds(t){const e=null==t?t=new zs:void 0;return t.rect(this.xmin,this.ymin,this.xmax-this.xmin,this.ymax-this.ymin),e&&e.value()}renderCell(t,e){const n=null==e?e=new zs:void 0,r=this._clip(t);if(null===r||!r.length)return;e.moveTo(r[0],r[1]);let i=r.length;for(;r[0]===r[i-2]&&r[1]===r[i-1]&&i>1;)i-=2;for(let t=2;t<i;t+=2)r[t]===r[t-2]&&r[t+1]===r[t-1]||e.lineTo(r[t],r[t+1]);return e.closePath(),n&&n.value()}*cellPolygons(){const{delaunay:{points:t}}=this;for(let e=0,n=t.length/2;e<n;++e){const t=this.cellPolygon(e);t&&(t.index=e,yield t)}}cellPolygon(t){const e=new Bs;return this.renderCell(t,e),e.value()}_renderSegment(t,e,n,r,i){let o;const a=this._regioncode(t,e),s=this._regioncode(n,r);0===a&&0===s?(i.moveTo(t,e),i.lineTo(n,r)):(o=this._clipSegment(t,e,n,r,a,s))&&(i.moveTo(o[0],o[1]),i.lineTo(o[2],o[3]))}contains(t,e,n){return(e=+e)==e&&(n=+n)==n&&this.delaunay._step(t,e,n)===t}*neighbors(t){const e=this._clip(t);if(e)for(const n of this.delaunay.neighbors(t)){const t=this._clip(n);if(t)t:for(let r=0,i=e.length;r<i;r+=2)for(let o=0,a=t.length;o<a;o+=2)if(e[r]===t[o]&&e[r+1]===t[o+1]&&e[(r+2)%i]===t[(o+a-2)%a]&&e[(r+3)%i]===t[(o+a-1)%a]){yield n;break t}}}_cell(t){const{circumcenters:e,delaunay:{inedges:n,halfedges:r,triangles:i}}=this,o=n[t];if(-1===o)return null;const a=[];let s=o;do{const n=Math.floor(s/3);if(a.push(e[2*n],e[2*n+1]),s=s%3==2?s-2:s+1,i[s]!==t)break;s=r[s]}while(s!==o&&-1!==s);return a}_clip(t){if(0===t&&1===this.delaunay.hull.length)return[this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax,this.xmin,this.ymin];const e=this._cell(t);if(null===e)return null;const{vectors:n}=this,r=4*t;return this._simplify(n[r]||n[r+1]?this._clipInfinite(t,e,n[r],n[r+1],n[r+2],n[r+3]):this._clipFinite(t,e))}_clipFinite(t,e){const n=e.length;let r,i,o,a,s=null,u=e[n-2],l=e[n-1],c=this._regioncode(u,l),f=0;for(let h=0;h<n;h+=2)if(r=u,i=l,u=e[h],l=e[h+1],o=c,c=this._regioncode(u,l),0===o&&0===c)a=f,f=0,s?s.push(u,l):s=[u,l];else{let e,n,h,d,p;if(0===o){if(null===(e=this._clipSegment(r,i,u,l,o,c)))continue;[n,h,d,p]=e}else{if(null===(e=this._clipSegment(u,l,r,i,c,o)))continue;[d,p,n,h]=e,a=f,f=this._edgecode(n,h),a&&f&&this._edge(t,a,f,s,s.length),s?s.push(n,h):s=[n,h]}a=f,f=this._edgecode(d,p),a&&f&&this._edge(t,a,f,s,s.length),s?s.push(d,p):s=[d,p]}if(s)a=f,f=this._edgecode(s[0],s[1]),a&&f&&this._edge(t,a,f,s,s.length);else if(this.contains(t,(this.xmin+this.xmax)/2,(this.ymin+this.ymax)/2))return[this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax,this.xmin,this.ymin];return s}_clipSegment(t,e,n,r,i,o){const a=i<o;for(a&&([t,e,n,r,i,o]=[n,r,t,e,o,i]);;){if(0===i&&0===o)return a?[n,r,t,e]:[t,e,n,r];if(i&o)return null;let s,u,l=i||o;8&l?(s=t+(n-t)*(this.ymax-e)/(r-e),u=this.ymax):4&l?(s=t+(n-t)*(this.ymin-e)/(r-e),u=this.ymin):2&l?(u=e+(r-e)*(this.xmax-t)/(n-t),s=this.xmax):(u=e+(r-e)*(this.xmin-t)/(n-t),s=this.xmin),i?(t=s,e=u,i=this._regioncode(t,e)):(n=s,r=u,o=this._regioncode(n,r))}}_clipInfinite(t,e,n,r,i,o){let a,s=Array.from(e);if((a=this._project(s[0],s[1],n,r))&&s.unshift(a[0],a[1]),(a=this._project(s[s.length-2],s[s.length-1],i,o))&&s.push(a[0],a[1]),s=this._clipFinite(t,s))for(let e,n=0,r=s.length,i=this._edgecode(s[r-2],s[r-1]);n<r;n+=2)e=i,i=this._edgecode(s[n],s[n+1]),e&&i&&(n=this._edge(t,e,i,s,n),r=s.length);else this.contains(t,(this.xmin+this.xmax)/2,(this.ymin+this.ymax)/2)&&(s=[this.xmin,this.ymin,this.xmax,this.ymin,this.xmax,this.ymax,this.xmin,this.ymax]);return s}_edge(t,e,n,r,i){for(;e!==n;){let n,o;switch(e){case 5:e=4;continue;case 4:e=6,n=this.xmax,o=this.ymin;break;case 6:e=2;continue;case 2:e=10,n=this.xmax,o=this.ymax;break;case 10:e=8;continue;case 8:e=9,n=this.xmin,o=this.ymax;break;case 9:e=1;continue;case 1:e=5,n=this.xmin,o=this.ymin}r[i]===n&&r[i+1]===o||!this.contains(t,n,o)||(r.splice(i,0,n,o),i+=2)}return i}_project(t,e,n,r){let i,o,a,s=1/0;if(r<0){if(e<=this.ymin)return null;(i=(this.ymin-e)/r)<s&&(a=this.ymin,o=t+(s=i)*n)}else if(r>0){if(e>=this.ymax)return null;(i=(this.ymax-e)/r)<s&&(a=this.ymax,o=t+(s=i)*n)}if(n>0){if(t>=this.xmax)return null;(i=(this.xmax-t)/n)<s&&(o=this.xmax,a=e+(s=i)*r)}else if(n<0){if(t<=this.xmin)return null;(i=(this.xmin-t)/n)<s&&(o=this.xmin,a=e+(s=i)*r)}return[o,a]}_edgecode(t,e){return(t===this.xmin?1:t===this.xmax?2:0)|(e===this.ymin?4:e===this.ymax?8:0)}_regioncode(t,e){return(t<this.xmin?1:t>this.xmax?2:0)|(e<this.ymin?4:e>this.ymax?8:0)}_simplify(t){if(t&&t.length>4){for(let e=0;e<t.length;e+=2){const n=(e+2)%t.length,r=(e+4)%t.length;(t[e]===t[n]&&t[n]===t[r]||t[e+1]===t[n+1]&&t[n+1]===t[r+1])&&(t.splice(n,2),e-=2)}t.length||(t=null)}return t}}const qs=2*Math.PI,Gs=Math.pow;function Us(t){return t[0]}function Hs(t){return t[1]}function Ws(t,e,n){return[t+Math.sin(t+e)*n,e+Math.cos(t-e)*n]}class Xs{static from(t,e=Us,n=Hs,r){return new Xs("length"in t?function(t,e,n,r){const i=t.length,o=new Float64Array(2*i);for(let a=0;a<i;++a){const i=t[a];o[2*a]=e.call(r,i,a,t),o[2*a+1]=n.call(r,i,a,t)}return o}(t,e,n,r):Float64Array.from(function*(t,e,n,r){let i=0;for(const o of t)yield e.call(r,o,i,t),yield n.call(r,o,i,t),++i}(t,e,n,r)))}constructor(t){this._delaunator=new Os(t),this.inedges=new Int32Array(t.length/2),this._hullIndex=new Int32Array(t.length/2),this.points=this._delaunator.coords,this._init()}update(){return this._delaunator.update(),this._init(),this}_init(){const t=this._delaunator,e=this.points;if(t.hull&&t.hull.length>2&&function(t){const{triangles:e,coords:n}=t;for(let t=0;t<e.length;t+=3){const r=2*e[t],i=2*e[t+1],o=2*e[t+2];if((n[o]-n[r])*(n[i+1]-n[r+1])-(n[i]-n[r])*(n[o+1]-n[r+1])>1e-10)return!1}return!0}(t)){this.collinear=Int32Array.from({length:e.length/2},((t,e)=>e)).sort(((t,n)=>e[2*t]-e[2*n]||e[2*t+1]-e[2*n+1]));const t=this.collinear[0],n=this.collinear[this.collinear.length-1],r=[e[2*t],e[2*t+1],e[2*n],e[2*n+1]],i=1e-8*Math.hypot(r[3]-r[1],r[2]-r[0]);for(let t=0,n=e.length/2;t<n;++t){const n=Ws(e[2*t],e[2*t+1],i);e[2*t]=n[0],e[2*t+1]=n[1]}this._delaunator=new Os(e)}else delete this.collinear;const n=this.halfedges=this._delaunator.halfedges,r=this.hull=this._delaunator.hull,i=this.triangles=this._delaunator.triangles,o=this.inedges.fill(-1),a=this._hullIndex.fill(-1);for(let t=0,e=n.length;t<e;++t){const e=i[t%3==2?t-2:t+1];-1!==n[t]&&-1!==o[e]||(o[e]=t)}for(let t=0,e=r.length;t<e;++t)a[r[t]]=t;r.length<=2&&r.length>0&&(this.triangles=new Int32Array(3).fill(-1),this.halfedges=new Int32Array(3).fill(-1),this.triangles[0]=r[0],o[r[0]]=1,2===r.length&&(o[r[1]]=0,this.triangles[1]=r[1],this.triangles[2]=r[1]))}voronoi(t){return new Vs(this,t)}*neighbors(t){const{inedges:e,hull:n,_hullIndex:r,halfedges:i,triangles:o,collinear:a}=this;if(a){const e=a.indexOf(t);return e>0&&(yield a[e-1]),void(e<a.length-1&&(yield a[e+1]))}const s=e[t];if(-1===s)return;let u=s,l=-1;do{if(yield l=o[u],u=u%3==2?u-2:u+1,o[u]!==t)return;if(u=i[u],-1===u){const e=n[(r[t]+1)%n.length];return void(e!==l&&(yield e))}}while(u!==s)}find(t,e,n=0){if((t=+t)!=t||(e=+e)!=e)return-1;const r=n;let i;for(;(i=this._step(n,t,e))>=0&&i!==n&&i!==r;)n=i;return i}_step(t,e,n){const{inedges:r,hull:i,_hullIndex:o,halfedges:a,triangles:s,points:u}=this;if(-1===r[t]||!u.length)return(t+1)%(u.length>>1);let l=t,c=Gs(e-u[2*t],2)+Gs(n-u[2*t+1],2);const f=r[t];let h=f;do{let r=s[h];const f=Gs(e-u[2*r],2)+Gs(n-u[2*r+1],2);if(f<c&&(c=f,l=r),h=h%3==2?h-2:h+1,s[h]!==t)break;if(h=a[h],-1===h){if(h=i[(o[t]+1)%i.length],h!==r&&Gs(e-u[2*h],2)+Gs(n-u[2*h+1],2)<c)return h;break}}while(h!==f);return l}render(t){const e=null==t?t=new zs:void 0,{points:n,halfedges:r,triangles:i}=this;for(let e=0,o=r.length;e<o;++e){const o=r[e];if(o<e)continue;const a=2*i[e],s=2*i[o];t.moveTo(n[a],n[a+1]),t.lineTo(n[s],n[s+1])}return this.renderHull(t),e&&e.value()}renderPoints(t,e){void 0!==e||t&&"function"==typeof t.moveTo||(e=t,t=null),e=null==e?2:+e;const n=null==t?t=new zs:void 0,{points:r}=this;for(let n=0,i=r.length;n<i;n+=2){const i=r[n],o=r[n+1];t.moveTo(i+e,o),t.arc(i,o,e,0,qs)}return n&&n.value()}renderHull(t){const e=null==t?t=new zs:void 0,{hull:n,points:r}=this,i=2*n[0],o=n.length;t.moveTo(r[i],r[i+1]);for(let e=1;e<o;++e){const i=2*n[e];t.lineTo(r[i],r[i+1])}return t.closePath(),e&&e.value()}hullPolygon(){const t=new Bs;return this.renderHull(t),t.value()}renderTriangle(t,e){const n=null==e?e=new zs:void 0,{points:r,triangles:i}=this,o=2*i[t*=3],a=2*i[t+1],s=2*i[t+2];return e.moveTo(r[o],r[o+1]),e.lineTo(r[a],r[a+1]),e.lineTo(r[s],r[s+1]),e.closePath(),n&&n.value()}*trianglePolygons(){const{triangles:t}=this;for(let e=0,n=t.length/3;e<n;++e)yield this.trianglePolygon(e)}trianglePolygon(t){const e=new Bs;return this.renderTriangle(t,e),e.value()}}var Ks=t=>()=>t;function Qs(t,{sourceEvent:e,subject:n,target:r,identifier:i,active:o,x:a,y:s,dx:u,dy:l,dispatch:c}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:o,enumerable:!0,configurable:!0},x:{value:a,enumerable:!0,configurable:!0},y:{value:s,enumerable:!0,configurable:!0},dx:{value:u,enumerable:!0,configurable:!0},dy:{value:l,enumerable:!0,configurable:!0},_:{value:c}})}function Ys(t){return!t.ctrlKey&&!t.button}function $s(){return this.parentNode}function Zs(t,e){return null==e?{x:t.x,y:t.y}:e}function Js(){return navigator.maxTouchPoints||"ontouchstart"in this}function tu(){var t,e,n,r,i=Ys,o=$s,a=Zs,s=Js,u={},l=Ee("start","drag","end"),c=0,f=0;function h(t){t.on("mousedown.drag",d).filter(s).on("touchstart.drag",g).on("touchmove.drag",y,qn).on("touchend.drag touchcancel.drag",v).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function d(a,s){if(!r&&i.call(this,a,s)){var u=x(this,o.call(this,a,s),a,s,"mouse");u&&(Vn(a.view).on("mousemove.drag",p,Gn).on("mouseup.drag",m,Gn),Wn(a.view),Un(a),n=!1,t=a.clientX,e=a.clientY,u("start",a))}}function p(r){if(Hn(r),!n){var i=r.clientX-t,o=r.clientY-e;n=i*i+o*o>f}u.mouse("drag",r)}function m(t){Vn(t.view).on("mousemove.drag mouseup.drag",null),Xn(t.view,n),Hn(t),u.mouse("end",t)}function g(t,e){if(i.call(this,t,e)){var n,r,a=t.changedTouches,s=o.call(this,t,e),u=a.length;for(n=0;n<u;++n)(r=x(this,s,t,e,a[n].identifier,a[n]))&&(Un(t),r("start",t,a[n]))}}function y(t){var e,n,r=t.changedTouches,i=r.length;for(e=0;e<i;++e)(n=u[r[e].identifier])&&(Hn(t),n("drag",t,r[e]))}function v(t){var e,n,i=t.changedTouches,o=i.length;for(r&&clearTimeout(r),r=setTimeout((function(){r=null}),500),e=0;e<o;++e)(n=u[i[e].identifier])&&(Un(t),n("end",t,i[e]))}function x(t,e,n,r,i,o){var s,f,d,p=l.copy(),m=ti(o||n,e);if(null!=(d=a.call(t,new Qs("beforestart",{sourceEvent:n,target:h,identifier:i,active:c,x:m[0],y:m[1],dx:0,dy:0,dispatch:p}),r)))return s=d.x-m[0]||0,f=d.y-m[1]||0,function n(o,a,l){var g,y=m;switch(o){case"start":u[i]=n,g=c++;break;case"end":delete u[i],--c;case"drag":m=ti(l||a,e),g=c}p.call(o,t,new Qs(o,{sourceEvent:a,subject:d,target:h,identifier:i,active:g,x:m[0]+s,y:m[1]+f,dx:m[0]-y[0],dy:m[1]-y[1],dispatch:p}),r)}}return h.filter=function(t){return arguments.length?(i="function"==typeof t?t:Ks(!!t),h):i},h.container=function(t){return arguments.length?(o="function"==typeof t?t:Ks(t),h):o},h.subject=function(t){return arguments.length?(a="function"==typeof t?t:Ks(t),h):a},h.touchable=function(t){return arguments.length?(s="function"==typeof t?t:Ks(!!t),h):s},h.on=function(){var t=l.on.apply(l,arguments);return t===l?h:t},h.clickDistance=function(t){return arguments.length?(f=(t=+t)*t,h):Math.sqrt(f)},h}Qs.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};var eu={},nu={},ru=34,iu=10,ou=13;function au(t){return new Function("d","return {"+t.map((function(t,e){return JSON.stringify(t)+": d["+e+'] || ""'})).join(",")+"}")}function su(t){var e=Object.create(null),n=[];return t.forEach((function(t){for(var r in t)r in e||n.push(e[r]=r)})),n}function uu(t,e){var n=t+"",r=n.length;return r<e?new Array(e-r+1).join(0)+n:n}function lu(t){var e,n=t.getUTCHours(),r=t.getUTCMinutes(),i=t.getUTCSeconds(),o=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":((e=t.getUTCFullYear())<0?"-"+uu(-e,6):e>9999?"+"+uu(e,6):uu(e,4))+"-"+uu(t.getUTCMonth()+1,2)+"-"+uu(t.getUTCDate(),2)+(o?"T"+uu(n,2)+":"+uu(r,2)+":"+uu(i,2)+"."+uu(o,3)+"Z":i?"T"+uu(n,2)+":"+uu(r,2)+":"+uu(i,2)+"Z":r||n?"T"+uu(n,2)+":"+uu(r,2)+"Z":"")}function cu(t){var e=new RegExp('["'+t+"\n\r]"),n=t.charCodeAt(0);function r(t,e){var r,i=[],o=t.length,a=0,s=0,u=o<=0,l=!1;function c(){if(u)return nu;if(l)return l=!1,eu;var e,r,i=a;if(t.charCodeAt(i)===ru){for(;a++<o&&t.charCodeAt(a)!==ru||t.charCodeAt(++a)===ru;);return(e=a)>=o?u=!0:(r=t.charCodeAt(a++))===iu?l=!0:r===ou&&(l=!0,t.charCodeAt(a)===iu&&++a),t.slice(i+1,e-1).replace(/""/g,'"')}for(;a<o;){if((r=t.charCodeAt(e=a++))===iu)l=!0;else if(r===ou)l=!0,t.charCodeAt(a)===iu&&++a;else if(r!==n)continue;return t.slice(i,e)}return u=!0,t.slice(i,o)}for(t.charCodeAt(o-1)===iu&&--o,t.charCodeAt(o-1)===ou&&--o;(r=c())!==nu;){for(var f=[];r!==eu&&r!==nu;)f.push(r),r=c();e&&null==(f=e(f,s++))||i.push(f)}return i}function i(e,n){return e.map((function(e){return n.map((function(t){return a(e[t])})).join(t)}))}function o(e){return e.map(a).join(t)}function a(t){return null==t?"":t instanceof Date?lu(t):e.test(t+="")?'"'+t.replace(/"/g,'""')+'"':t}return{parse:function(t,e){var n,i,o=r(t,(function(t,r){if(n)return n(t,r-1);i=t,n=e?function(t,e){var n=au(t);return function(r,i){return e(n(r),i,t)}}(t,e):au(t)}));return o.columns=i||[],o},parseRows:r,format:function(e,n){return null==n&&(n=su(e)),[n.map(a).join(t)].concat(i(e,n)).join("\n")},formatBody:function(t,e){return null==e&&(e=su(t)),i(t,e).join("\n")},formatRows:function(t){return t.map(o).join("\n")},formatRow:o,formatValue:a}}var fu=cu(","),hu=fu.parse,du=fu.parseRows,pu=fu.format,mu=fu.formatBody,gu=fu.formatRows,yu=fu.formatRow,vu=fu.formatValue,xu=cu("\t"),_u=xu.parse,bu=xu.parseRows,wu=xu.format,Mu=xu.formatBody,Au=xu.formatRows,Tu=xu.formatRow,Eu=xu.formatValue;function Cu(t){for(var e in t){var n,r,i=t[e].trim();if(i)if("true"===i)i=!0;else if("false"===i)i=!1;else if("NaN"===i)i=NaN;else if(isNaN(n=+i)){if(!(r=i.match(/^([-+]\d{2})?\d{4}(-\d{2}(-\d{2})?)?(T\d{2}:\d{2}(:\d{2}(\.\d{3})?)?(Z|[-+]\d{2}:\d{2})?)?$/)))continue;ku&&r[4]&&!r[7]&&(i=i.replace(/-/g,"/").replace(/T/," ")),i=new Date(i)}else i=n;else i=null;t[e]=i}return t}const ku=new Date("2019-01-01T00:00").getHours()||new Date("2019-07-01T00:00").getHours(),Su=t=>+t;function Ou(t){return t*t}function Pu(t){return t*(2-t)}function Lu(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}var Ru=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),Iu=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),Du=function t(e){function n(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,n.exponent=t,n}(3),Nu=Math.PI,Fu=Nu/2;function ju(t){return 1==+t?1:1-Math.cos(t*Fu)}function zu(t){return Math.sin(t*Fu)}function Bu(t){return(1-Math.cos(Nu*t))/2}function Vu(t){return 1.0009775171065494*(Math.pow(2,-10*t)-.0009765625)}function qu(t){return Vu(1-+t)}function Gu(t){return 1-Vu(t)}function Uu(t){return((t*=2)<=1?Vu(1-t):2-Vu(t-1))/2}function Hu(t){return 1-Math.sqrt(1-t*t)}function Wu(t){return Math.sqrt(1- --t*t)}function Xu(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var Ku=4/11,Qu=6/11,Yu=8/11,$u=3/4,Zu=9/11,Ju=10/11,tl=15/16,el=21/22,nl=63/64,rl=1/Ku/Ku;function il(t){return 1-ol(1-t)}function ol(t){return(t=+t)<Ku?rl*t*t:t<Yu?rl*(t-=Qu)*t+$u:t<Ju?rl*(t-=Zu)*t+tl:rl*(t-=el)*t+nl}function al(t){return((t*=2)<=1?1-ol(1-t):ol(t-1)+1)/2}var sl=1.70158,ul=function t(e){function n(t){return(t=+t)*t*(e*(t-1)+t)}return e=+e,n.overshoot=t,n}(sl),ll=function t(e){function n(t){return--t*t*((t+1)*e+t)+1}return e=+e,n.overshoot=t,n}(sl),cl=function t(e){function n(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,n.overshoot=t,n}(sl),fl=2*Math.PI,hl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return e*Vu(- --t)*Math.sin((r-t)/n)}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3),dl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return 1-e*Vu(t=+t)*Math.sin((t+r)/n)}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3),pl=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=fl);function i(t){return((t=2*t-1)<0?e*Vu(-t)*Math.sin((r-t)/n):2-e*Vu(t)*Math.sin((r+t)/n))/2}return i.amplitude=function(e){return t(e,n*fl)},i.period=function(n){return t(e,n)},i}(1,.3);function ml(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.blob()}function gl(t,e){return fetch(t,e).then(ml)}function yl(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.arrayBuffer()}function vl(t,e){return fetch(t,e).then(yl)}function xl(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.text()}function _l(t,e){return fetch(t,e).then(xl)}function bl(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=void 0),_l(e,n).then((function(e){return t(e,r)}))}}function wl(t,e,n,r){3===arguments.length&&"function"==typeof n&&(r=n,n=void 0);var i=cu(t);return _l(e,n).then((function(t){return i.parse(t,r)}))}var Ml=bl(hu),Al=bl(_u);function Tl(t,e){return new Promise((function(n,r){var i=new Image;for(var o in e)i[o]=e[o];i.onerror=r,i.onload=function(){n(i)},i.src=t}))}function El(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);if(204!==t.status&&205!==t.status)return t.json()}function Cl(t,e){return fetch(t,e).then(El)}function kl(t){return(e,n)=>_l(e,n).then((e=>(new DOMParser).parseFromString(e,t)))}var Sl=kl("application/xml"),Ol=kl("text/html"),Pl=kl("image/svg+xml");function Ll(t,e){var n,r=1;function i(){var i,o,a=n.length,s=0,u=0;for(i=0;i<a;++i)s+=(o=n[i]).x,u+=o.y;for(s=(s/a-t)*r,u=(u/a-e)*r,i=0;i<a;++i)(o=n[i]).x-=s,o.y-=u}return null==t&&(t=0),null==e&&(e=0),i.initialize=function(t){n=t},i.x=function(e){return arguments.length?(t=+e,i):t},i.y=function(t){return arguments.length?(e=+t,i):e},i.strength=function(t){return arguments.length?(r=+t,i):r},i}function Rl(t,e,n,r){if(isNaN(e)||isNaN(n))return t;var i,o,a,s,u,l,c,f,h,d=t._root,p={data:r},m=t._x0,g=t._y0,y=t._x1,v=t._y1;if(!d)return t._root=p,t;for(;d.length;)if((l=e>=(o=(m+y)/2))?m=o:y=o,(c=n>=(a=(g+v)/2))?g=a:v=a,i=d,!(d=d[f=c<<1|l]))return i[f]=p,t;if(s=+t._x.call(null,d.data),u=+t._y.call(null,d.data),e===s&&n===u)return p.next=d,i?i[f]=p:t._root=p,t;do{i=i?i[f]=new Array(4):t._root=new Array(4),(l=e>=(o=(m+y)/2))?m=o:y=o,(c=n>=(a=(g+v)/2))?g=a:v=a}while((f=c<<1|l)==(h=(u>=a)<<1|s>=o));return i[h]=d,i[f]=p,t}function Il(t,e,n,r,i){this.node=t,this.x0=e,this.y0=n,this.x1=r,this.y1=i}function Dl(t){return t[0]}function Nl(t){return t[1]}function Fl(t,e,n){var r=new jl(null==e?Dl:e,null==n?Nl:n,NaN,NaN,NaN,NaN);return null==t?r:r.addAll(t)}function jl(t,e,n,r,i,o){this._x=t,this._y=e,this._x0=n,this._y0=r,this._x1=i,this._y1=o,this._root=void 0}function zl(t){for(var e={data:t.data},n=e;t=t.next;)n=n.next={data:t.data};return e}var Bl=Fl.prototype=jl.prototype;function Vl(t){return function(){return t}}function ql(t){return 1e-6*(t()-.5)}function Gl(t){return t.x+t.vx}function Ul(t){return t.y+t.vy}function Hl(t){var e,n,r,i=1,o=1;function a(){for(var t,a,u,l,c,f,h,d=e.length,p=0;p<o;++p)for(a=Fl(e,Gl,Ul).visitAfter(s),t=0;t<d;++t)u=e[t],f=n[u.index],h=f*f,l=u.x+u.vx,c=u.y+u.vy,a.visit(m);function m(t,e,n,o,a){var s=t.data,d=t.r,p=f+d;if(!s)return e>l+p||o<l-p||n>c+p||a<c-p;if(s.index>u.index){var m=l-s.x-s.vx,g=c-s.y-s.vy,y=m*m+g*g;y<p*p&&(0===m&&(y+=(m=ql(r))*m),0===g&&(y+=(g=ql(r))*g),y=(p-(y=Math.sqrt(y)))/y*i,u.vx+=(m*=y)*(p=(d*=d)/(h+d)),u.vy+=(g*=y)*p,s.vx-=m*(p=1-p),s.vy-=g*p)}}}function s(t){if(t.data)return t.r=n[t.data.index];for(var e=t.r=0;e<4;++e)t[e]&&t[e].r>t.r&&(t.r=t[e].r)}function u(){if(e){var r,i,o=e.length;for(n=new Array(o),r=0;r<o;++r)i=e[r],n[i.index]=+t(i,r,e)}}return"function"!=typeof t&&(t=Vl(null==t?1:+t)),a.initialize=function(t,n){e=t,r=n,u()},a.iterations=function(t){return arguments.length?(o=+t,a):o},a.strength=function(t){return arguments.length?(i=+t,a):i},a.radius=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),u(),a):t},a}function Wl(t){return t.index}function Xl(t,e){var n=t.get(e);if(!n)throw new Error("node not found: "+e);return n}function Kl(t){var e,n,r,i,o,a,s=Wl,u=function(t){return 1/Math.min(i[t.source.index],i[t.target.index])},l=Vl(30),c=1;function f(r){for(var i=0,s=t.length;i<c;++i)for(var u,l,f,h,d,p,m,g=0;g<s;++g)l=(u=t[g]).source,h=(f=u.target).x+f.vx-l.x-l.vx||ql(a),d=f.y+f.vy-l.y-l.vy||ql(a),h*=p=((p=Math.sqrt(h*h+d*d))-n[g])/p*r*e[g],d*=p,f.vx-=h*(m=o[g]),f.vy-=d*m,l.vx+=h*(m=1-m),l.vy+=d*m}function h(){if(r){var a,u,l=r.length,c=t.length,f=new Map(r.map(((t,e)=>[s(t,e,r),t])));for(a=0,i=new Array(l);a<c;++a)(u=t[a]).index=a,"object"!=typeof u.source&&(u.source=Xl(f,u.source)),"object"!=typeof u.target&&(u.target=Xl(f,u.target)),i[u.source.index]=(i[u.source.index]||0)+1,i[u.target.index]=(i[u.target.index]||0)+1;for(a=0,o=new Array(c);a<c;++a)u=t[a],o[a]=i[u.source.index]/(i[u.source.index]+i[u.target.index]);e=new Array(c),d(),n=new Array(c),p()}}function d(){if(r)for(var n=0,i=t.length;n<i;++n)e[n]=+u(t[n],n,t)}function p(){if(r)for(var e=0,i=t.length;e<i;++e)n[e]=+l(t[e],e,t)}return null==t&&(t=[]),f.initialize=function(t,e){r=t,a=e,h()},f.links=function(e){return arguments.length?(t=e,h(),f):t},f.id=function(t){return arguments.length?(s=t,f):s},f.iterations=function(t){return arguments.length?(c=+t,f):c},f.strength=function(t){return arguments.length?(u="function"==typeof t?t:Vl(+t),d(),f):u},f.distance=function(t){return arguments.length?(l="function"==typeof t?t:Vl(+t),p(),f):l},f}Bl.copy=function(){var t,e,n=new jl(this._x,this._y,this._x0,this._y0,this._x1,this._y1),r=this._root;if(!r)return n;if(!r.length)return n._root=zl(r),n;for(t=[{source:r,target:n._root=new Array(4)}];r=t.pop();)for(var i=0;i<4;++i)(e=r.source[i])&&(e.length?t.push({source:e,target:r.target[i]=new Array(4)}):r.target[i]=zl(e));return n},Bl.add=function(t){const e=+this._x.call(null,t),n=+this._y.call(null,t);return Rl(this.cover(e,n),e,n,t)},Bl.addAll=function(t){var e,n,r,i,o=t.length,a=new Array(o),s=new Array(o),u=1/0,l=1/0,c=-1/0,f=-1/0;for(n=0;n<o;++n)isNaN(r=+this._x.call(null,e=t[n]))||isNaN(i=+this._y.call(null,e))||(a[n]=r,s[n]=i,r<u&&(u=r),r>c&&(c=r),i<l&&(l=i),i>f&&(f=i));if(u>c||l>f)return this;for(this.cover(u,l).cover(c,f),n=0;n<o;++n)Rl(this,a[n],s[n],t[n]);return this},Bl.cover=function(t,e){if(isNaN(t=+t)||isNaN(e=+e))return this;var n=this._x0,r=this._y0,i=this._x1,o=this._y1;if(isNaN(n))i=(n=Math.floor(t))+1,o=(r=Math.floor(e))+1;else{for(var a,s,u=i-n||1,l=this._root;n>t||t>=i||r>e||e>=o;)switch(s=(e<r)<<1|t<n,(a=new Array(4))[s]=l,l=a,u*=2,s){case 0:i=n+u,o=r+u;break;case 1:n=i-u,o=r+u;break;case 2:i=n+u,r=o-u;break;case 3:n=i-u,r=o-u}this._root&&this._root.length&&(this._root=l)}return this._x0=n,this._y0=r,this._x1=i,this._y1=o,this},Bl.data=function(){var t=[];return this.visit((function(e){if(!e.length)do{t.push(e.data)}while(e=e.next)})),t},Bl.extent=function(t){return arguments.length?this.cover(+t[0][0],+t[0][1]).cover(+t[1][0],+t[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]},Bl.find=function(t,e,n){var r,i,o,a,s,u,l,c=this._x0,f=this._y0,h=this._x1,d=this._y1,p=[],m=this._root;for(m&&p.push(new Il(m,c,f,h,d)),null==n?n=1/0:(c=t-n,f=e-n,h=t+n,d=e+n,n*=n);u=p.pop();)if(!(!(m=u.node)||(i=u.x0)>h||(o=u.y0)>d||(a=u.x1)<c||(s=u.y1)<f))if(m.length){var g=(i+a)/2,y=(o+s)/2;p.push(new Il(m[3],g,y,a,s),new Il(m[2],i,y,g,s),new Il(m[1],g,o,a,y),new Il(m[0],i,o,g,y)),(l=(e>=y)<<1|t>=g)&&(u=p[p.length-1],p[p.length-1]=p[p.length-1-l],p[p.length-1-l]=u)}else{var v=t-+this._x.call(null,m.data),x=e-+this._y.call(null,m.data),_=v*v+x*x;if(_<n){var b=Math.sqrt(n=_);c=t-b,f=e-b,h=t+b,d=e+b,r=m.data}}return r},Bl.remove=function(t){if(isNaN(o=+this._x.call(null,t))||isNaN(a=+this._y.call(null,t)))return this;var e,n,r,i,o,a,s,u,l,c,f,h,d=this._root,p=this._x0,m=this._y0,g=this._x1,y=this._y1;if(!d)return this;if(d.length)for(;;){if((l=o>=(s=(p+g)/2))?p=s:g=s,(c=a>=(u=(m+y)/2))?m=u:y=u,e=d,!(d=d[f=c<<1|l]))return this;if(!d.length)break;(e[f+1&3]||e[f+2&3]||e[f+3&3])&&(n=e,h=f)}for(;d.data!==t;)if(r=d,!(d=d.next))return this;return(i=d.next)&&delete d.next,r?(i?r.next=i:delete r.next,this):e?(i?e[f]=i:delete e[f],(d=e[0]||e[1]||e[2]||e[3])&&d===(e[3]||e[2]||e[1]||e[0])&&!d.length&&(n?n[h]=d:this._root=d),this):(this._root=i,this)},Bl.removeAll=function(t){for(var e=0,n=t.length;e<n;++e)this.remove(t[e]);return this},Bl.root=function(){return this._root},Bl.size=function(){var t=0;return this.visit((function(e){if(!e.length)do{++t}while(e=e.next)})),t},Bl.visit=function(t){var e,n,r,i,o,a,s=[],u=this._root;for(u&&s.push(new Il(u,this._x0,this._y0,this._x1,this._y1));e=s.pop();)if(!t(u=e.node,r=e.x0,i=e.y0,o=e.x1,a=e.y1)&&u.length){var l=(r+o)/2,c=(i+a)/2;(n=u[3])&&s.push(new Il(n,l,c,o,a)),(n=u[2])&&s.push(new Il(n,r,c,l,a)),(n=u[1])&&s.push(new Il(n,l,i,o,c)),(n=u[0])&&s.push(new Il(n,r,i,l,c))}return this},Bl.visitAfter=function(t){var e,n=[],r=[];for(this._root&&n.push(new Il(this._root,this._x0,this._y0,this._x1,this._y1));e=n.pop();){var i=e.node;if(i.length){var o,a=e.x0,s=e.y0,u=e.x1,l=e.y1,c=(a+u)/2,f=(s+l)/2;(o=i[0])&&n.push(new Il(o,a,s,c,f)),(o=i[1])&&n.push(new Il(o,c,s,u,f)),(o=i[2])&&n.push(new Il(o,a,f,c,l)),(o=i[3])&&n.push(new Il(o,c,f,u,l))}r.push(e)}for(;e=r.pop();)t(e.node,e.x0,e.y0,e.x1,e.y1);return this},Bl.x=function(t){return arguments.length?(this._x=t,this):this._x},Bl.y=function(t){return arguments.length?(this._y=t,this):this._y};const Ql=1664525,Yl=1013904223,$l=4294967296;function Zl(t){return t.x}function Jl(t){return t.y}var tc=10,ec=Math.PI*(3-Math.sqrt(5));function nc(t){var e,n=1,r=.001,i=1-Math.pow(r,1/300),o=0,a=.6,s=new Map,u=pi(f),l=Ee("tick","end"),c=function(){let t=1;return()=>(t=(Ql*t+Yl)%$l)/$l}();function f(){h(),l.call("tick",e),n<r&&(u.stop(),l.call("end",e))}function h(r){var u,l,c=t.length;void 0===r&&(r=1);for(var f=0;f<r;++f)for(n+=(o-n)*i,s.forEach((function(t){t(n)})),u=0;u<c;++u)null==(l=t[u]).fx?l.x+=l.vx*=a:(l.x=l.fx,l.vx=0),null==l.fy?l.y+=l.vy*=a:(l.y=l.fy,l.vy=0);return e}function d(){for(var e,n=0,r=t.length;n<r;++n){if((e=t[n]).index=n,null!=e.fx&&(e.x=e.fx),null!=e.fy&&(e.y=e.fy),isNaN(e.x)||isNaN(e.y)){var i=tc*Math.sqrt(.5+n),o=n*ec;e.x=i*Math.cos(o),e.y=i*Math.sin(o)}(isNaN(e.vx)||isNaN(e.vy))&&(e.vx=e.vy=0)}}function p(e){return e.initialize&&e.initialize(t,c),e}return null==t&&(t=[]),d(),e={tick:h,restart:function(){return u.restart(f),e},stop:function(){return u.stop(),e},nodes:function(n){return arguments.length?(t=n,d(),s.forEach(p),e):t},alpha:function(t){return arguments.length?(n=+t,e):n},alphaMin:function(t){return arguments.length?(r=+t,e):r},alphaDecay:function(t){return arguments.length?(i=+t,e):+i},alphaTarget:function(t){return arguments.length?(o=+t,e):o},velocityDecay:function(t){return arguments.length?(a=1-t,e):1-a},randomSource:function(t){return arguments.length?(c=t,s.forEach(p),e):c},force:function(t,n){return arguments.length>1?(null==n?s.delete(t):s.set(t,p(n)),e):s.get(t)},find:function(e,n,r){var i,o,a,s,u,l=0,c=t.length;for(null==r?r=1/0:r*=r,l=0;l<c;++l)(a=(i=e-(s=t[l]).x)*i+(o=n-s.y)*o)<r&&(u=s,r=a);return u},on:function(t,n){return arguments.length>1?(l.on(t,n),e):l.on(t)}}}function rc(){var t,e,n,r,i,o=Vl(-30),a=1,s=1/0,u=.81;function l(n){var i,o=t.length,a=Fl(t,Zl,Jl).visitAfter(f);for(r=n,i=0;i<o;++i)e=t[i],a.visit(h)}function c(){if(t){var e,n,r=t.length;for(i=new Array(r),e=0;e<r;++e)n=t[e],i[n.index]=+o(n,e,t)}}function f(t){var e,n,r,o,a,s=0,u=0;if(t.length){for(r=o=a=0;a<4;++a)(e=t[a])&&(n=Math.abs(e.value))&&(s+=e.value,u+=n,r+=n*e.x,o+=n*e.y);t.x=r/u,t.y=o/u}else{(e=t).x=e.data.x,e.y=e.data.y;do{s+=i[e.data.index]}while(e=e.next)}t.value=s}function h(t,o,l,c){if(!t.value)return!0;var f=t.x-e.x,h=t.y-e.y,d=c-o,p=f*f+h*h;if(d*d/u<p)return p<s&&(0===f&&(p+=(f=ql(n))*f),0===h&&(p+=(h=ql(n))*h),p<a&&(p=Math.sqrt(a*p)),e.vx+=f*t.value*r/p,e.vy+=h*t.value*r/p),!0;if(!(t.length||p>=s)){(t.data!==e||t.next)&&(0===f&&(p+=(f=ql(n))*f),0===h&&(p+=(h=ql(n))*h),p<a&&(p=Math.sqrt(a*p)));do{t.data!==e&&(d=i[t.data.index]*r/p,e.vx+=f*d,e.vy+=h*d)}while(t=t.next)}}return l.initialize=function(e,r){t=e,n=r,c()},l.strength=function(t){return arguments.length?(o="function"==typeof t?t:Vl(+t),c(),l):o},l.distanceMin=function(t){return arguments.length?(a=t*t,l):Math.sqrt(a)},l.distanceMax=function(t){return arguments.length?(s=t*t,l):Math.sqrt(s)},l.theta=function(t){return arguments.length?(u=t*t,l):Math.sqrt(u)},l}function ic(t,e,n){var r,i,o,a=Vl(.1);function s(t){for(var a=0,s=r.length;a<s;++a){var u=r[a],l=u.x-e||1e-6,c=u.y-n||1e-6,f=Math.sqrt(l*l+c*c),h=(o[a]-f)*i[a]*t/f;u.vx+=l*h,u.vy+=c*h}}function u(){if(r){var e,n=r.length;for(i=new Array(n),o=new Array(n),e=0;e<n;++e)o[e]=+t(r[e],e,r),i[e]=isNaN(o[e])?0:+a(r[e],e,r)}}return"function"!=typeof t&&(t=Vl(+t)),null==e&&(e=0),null==n&&(n=0),s.initialize=function(t){r=t,u()},s.strength=function(t){return arguments.length?(a="function"==typeof t?t:Vl(+t),u(),s):a},s.radius=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),u(),s):t},s.x=function(t){return arguments.length?(e=+t,s):e},s.y=function(t){return arguments.length?(n=+t,s):n},s}function oc(t){var e,n,r,i=Vl(.1);function o(t){for(var i,o=0,a=e.length;o<a;++o)(i=e[o]).vx+=(r[o]-i.x)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),r=new Array(a),o=0;o<a;++o)n[o]=isNaN(r[o]=+t(e[o],o,e))?0:+i(e[o],o,e)}}return"function"!=typeof t&&(t=Vl(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(i="function"==typeof t?t:Vl(+t),a(),o):i},o.x=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),a(),o):t},o}function ac(t){var e,n,r,i=Vl(.1);function o(t){for(var i,o=0,a=e.length;o<a;++o)(i=e[o]).vy+=(r[o]-i.y)*n[o]*t}function a(){if(e){var o,a=e.length;for(n=new Array(a),r=new Array(a),o=0;o<a;++o)n[o]=isNaN(r[o]=+t(e[o],o,e))?0:+i(e[o],o,e)}}return"function"!=typeof t&&(t=Vl(null==t?0:+t)),o.initialize=function(t){e=t,a()},o.strength=function(t){return arguments.length?(i="function"==typeof t?t:Vl(+t),a(),o):i},o.y=function(e){return arguments.length?(t="function"==typeof e?e:Vl(+e),a(),o):t},o}function sc(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function uc(t){return(t=sc(Math.abs(t)))?t[1]:NaN}var lc,cc=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function fc(t){if(!(e=cc.exec(t)))throw new Error("invalid format: "+t);var e;return new hc({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function hc(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function dc(t,e){var n=sc(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}fc.prototype=hc.prototype,hc.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var pc={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>dc(100*t,e),r:dc,s:function(t,e){var n=sc(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(lc=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+sc(t,Math.max(0,e+o-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function mc(t){return t}var gc,yc,vc,xc=Array.prototype.map,_c=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function bc(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?mc:(e=xc.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?mc:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(xc.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"−":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=fc(t)).fill,n=t.align,f=t.sign,h=t.symbol,d=t.zero,p=t.width,m=t.comma,g=t.precision,y=t.trim,v=t.type;"n"===v?(m=!0,v="g"):pc[v]||(void 0===g&&(g=12),y=!0,v="g"),(d||"0"===e&&"="===n)&&(d=!0,e="0",n="=");var x="$"===h?i:"#"===h&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",_="$"===h?o:/[%p]/.test(v)?u:"",b=pc[v],w=/[defgprs%]/.test(v);function M(t){var i,o,u,h=x,M=_;if("c"===v)M=b(t)+M,t="";else{var A=(t=+t)<0||1/t<0;if(t=isNaN(t)?c:b(Math.abs(t),g),y&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),A&&0==+t&&"+"!==f&&(A=!1),h=(A?"("===f?f:l:"-"===f||"("===f?"":f)+h,M=("s"===v?_c[8+lc/3]:"")+M+(A&&"("===f?")":""),w)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){M=(46===u?a+t.slice(i+1):t.slice(i))+M,t=t.slice(0,i);break}}m&&!d&&(t=r(t,1/0));var T=h.length+t.length+M.length,E=T<p?new Array(p-T+1).join(e):"";switch(m&&d&&(t=r(E+t,E.length?p-M.length:1/0),E=""),n){case"<":t=h+t+M+E;break;case"=":t=h+E+t+M;break;case"^":t=E.slice(0,T=E.length>>1)+h+t+M+E.slice(T);break;default:t=E+h+t+M}return s(t)}return g=void 0===g?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),M.toString=function(){return t+""},M}return{format:f,formatPrefix:function(t,e){var n=f(((t=fc(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(uc(e)/3))),i=Math.pow(10,-r),o=_c[8+r/3];return function(t){return n(i*t)+o}}}}function wc(t){return gc=bc(t),yc=gc.format,vc=gc.formatPrefix,gc}function Mc(t){return Math.max(0,-uc(Math.abs(t)))}function Ac(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(uc(e)/3)))-uc(Math.abs(t)))}function Tc(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,uc(e)-uc(t))+1}wc({thousands:",",grouping:[3],currency:["$",""]});var Ec=1e-6,Cc=1e-12,kc=Math.PI,Sc=kc/2,Oc=kc/4,Pc=2*kc,Lc=180/kc,Rc=kc/180,Ic=Math.abs,Dc=Math.atan,Nc=Math.atan2,Fc=Math.cos,jc=Math.ceil,zc=Math.exp,Bc=(Math.floor,Math.hypot),Vc=Math.log,qc=Math.pow,Gc=Math.sin,Uc=Math.sign||function(t){return t>0?1:t<0?-1:0},Hc=Math.sqrt,Wc=Math.tan;function Xc(t){return t>1?0:t<-1?kc:Math.acos(t)}function Kc(t){return t>1?Sc:t<-1?-Sc:Math.asin(t)}function Qc(t){return(t=Gc(t/2))*t}function Yc(){}function $c(t,e){t&&Jc.hasOwnProperty(t.type)&&Jc[t.type](t,e)}var Zc={Feature:function(t,e){$c(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)$c(n[r].geometry,e)}},Jc={Sphere:function(t,e){e.sphere()},Point:function(t,e){t=t.coordinates,e.point(t[0],t[1],t[2])},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)t=n[r],e.point(t[0],t[1],t[2])},LineString:function(t,e){tf(t.coordinates,e,0)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)tf(n[r],e,0)},Polygon:function(t,e){ef(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)ef(n[r],e)},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)$c(n[r],e)}};function tf(t,e,n){var r,i=-1,o=t.length-n;for(e.lineStart();++i<o;)r=t[i],e.point(r[0],r[1],r[2]);e.lineEnd()}function ef(t,e){var n=-1,r=t.length;for(e.polygonStart();++n<r;)tf(t[n],e,1);e.polygonEnd()}function nf(t,e){t&&Zc.hasOwnProperty(t.type)?Zc[t.type](t,e):$c(t,e)}var rf,of,af,sf,uf,lf,cf,ff,hf,df,pf,mf,gf,yf,vf,xf,_f=new S,bf=new S,wf={point:Yc,lineStart:Yc,lineEnd:Yc,polygonStart:function(){_f=new S,wf.lineStart=Mf,wf.lineEnd=Af},polygonEnd:function(){var t=+_f;bf.add(t<0?Pc+t:t),this.lineStart=this.lineEnd=this.point=Yc},sphere:function(){bf.add(Pc)}};function Mf(){wf.point=Tf}function Af(){Ef(rf,of)}function Tf(t,e){wf.point=Ef,rf=t,of=e,af=t*=Rc,sf=Fc(e=(e*=Rc)/2+Oc),uf=Gc(e)}function Ef(t,e){var n=(t*=Rc)-af,r=n>=0?1:-1,i=r*n,o=Fc(e=(e*=Rc)/2+Oc),a=Gc(e),s=uf*a,u=sf*o+s*Fc(i),l=s*r*Gc(i);_f.add(Nc(l,u)),af=t,sf=o,uf=a}function Cf(t){return bf=new S,nf(t,wf),2*bf}function kf(t){return[Nc(t[1],t[0]),Kc(t[2])]}function Sf(t){var e=t[0],n=t[1],r=Fc(n);return[r*Fc(e),r*Gc(e),Gc(n)]}function Of(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function Pf(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function Lf(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function Rf(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function If(t){var e=Hc(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}var Df,Nf,Ff,jf,zf,Bf,Vf,qf,Gf,Uf,Hf,Wf,Xf,Kf,Qf,Yf,$f={point:Zf,lineStart:th,lineEnd:eh,polygonStart:function(){$f.point=nh,$f.lineStart=rh,$f.lineEnd=ih,yf=new S,wf.polygonStart()},polygonEnd:function(){wf.polygonEnd(),$f.point=Zf,$f.lineStart=th,$f.lineEnd=eh,_f<0?(lf=-(ff=180),cf=-(hf=90)):yf>Ec?hf=90:yf<-Ec&&(cf=-90),xf[0]=lf,xf[1]=ff},sphere:function(){lf=-(ff=180),cf=-(hf=90)}};function Zf(t,e){vf.push(xf=[lf=t,ff=t]),e<cf&&(cf=e),e>hf&&(hf=e)}function Jf(t,e){var n=Sf([t*Rc,e*Rc]);if(gf){var r=Pf(gf,n),i=Pf([r[1],-r[0],0],r);If(i),i=kf(i);var o,a=t-df,s=a>0?1:-1,u=i[0]*Lc*s,l=Ic(a)>180;l^(s*df<u&&u<s*t)?(o=i[1]*Lc)>hf&&(hf=o):l^(s*df<(u=(u+360)%360-180)&&u<s*t)?(o=-i[1]*Lc)<cf&&(cf=o):(e<cf&&(cf=e),e>hf&&(hf=e)),l?t<df?oh(lf,t)>oh(lf,ff)&&(ff=t):oh(t,ff)>oh(lf,ff)&&(lf=t):ff>=lf?(t<lf&&(lf=t),t>ff&&(ff=t)):t>df?oh(lf,t)>oh(lf,ff)&&(ff=t):oh(t,ff)>oh(lf,ff)&&(lf=t)}else vf.push(xf=[lf=t,ff=t]);e<cf&&(cf=e),e>hf&&(hf=e),gf=n,df=t}function th(){$f.point=Jf}function eh(){xf[0]=lf,xf[1]=ff,$f.point=Zf,gf=null}function nh(t,e){if(gf){var n=t-df;yf.add(Ic(n)>180?n+(n>0?360:-360):n)}else pf=t,mf=e;wf.point(t,e),Jf(t,e)}function rh(){wf.lineStart()}function ih(){nh(pf,mf),wf.lineEnd(),Ic(yf)>Ec&&(lf=-(ff=180)),xf[0]=lf,xf[1]=ff,gf=null}function oh(t,e){return(e-=t)<0?e+360:e}function ah(t,e){return t[0]-e[0]}function sh(t,e){return t[0]<=t[1]?t[0]<=e&&e<=t[1]:e<t[0]||t[1]<e}function uh(t){var e,n,r,i,o,a,s;if(hf=ff=-(lf=cf=1/0),vf=[],nf(t,$f),n=vf.length){for(vf.sort(ah),e=1,o=[r=vf[0]];e<n;++e)sh(r,(i=vf[e])[0])||sh(r,i[1])?(oh(r[0],i[1])>oh(r[0],r[1])&&(r[1]=i[1]),oh(i[0],r[1])>oh(r[0],r[1])&&(r[0]=i[0])):o.push(r=i);for(a=-1/0,e=0,r=o[n=o.length-1];e<=n;r=i,++e)i=o[e],(s=oh(r[1],i[0]))>a&&(a=s,lf=i[0],ff=r[1])}return vf=xf=null,lf===1/0||cf===1/0?[[NaN,NaN],[NaN,NaN]]:[[lf,cf],[ff,hf]]}var lh={sphere:Yc,point:ch,lineStart:hh,lineEnd:mh,polygonStart:function(){lh.lineStart=gh,lh.lineEnd=yh},polygonEnd:function(){lh.lineStart=hh,lh.lineEnd=mh}};function ch(t,e){t*=Rc;var n=Fc(e*=Rc);fh(n*Fc(t),n*Gc(t),Gc(e))}function fh(t,e,n){++Df,Ff+=(t-Ff)/Df,jf+=(e-jf)/Df,zf+=(n-zf)/Df}function hh(){lh.point=dh}function dh(t,e){t*=Rc;var n=Fc(e*=Rc);Kf=n*Fc(t),Qf=n*Gc(t),Yf=Gc(e),lh.point=ph,fh(Kf,Qf,Yf)}function ph(t,e){t*=Rc;var n=Fc(e*=Rc),r=n*Fc(t),i=n*Gc(t),o=Gc(e),a=Nc(Hc((a=Qf*o-Yf*i)*a+(a=Yf*r-Kf*o)*a+(a=Kf*i-Qf*r)*a),Kf*r+Qf*i+Yf*o);Nf+=a,Bf+=a*(Kf+(Kf=r)),Vf+=a*(Qf+(Qf=i)),qf+=a*(Yf+(Yf=o)),fh(Kf,Qf,Yf)}function mh(){lh.point=ch}function gh(){lh.point=vh}function yh(){xh(Wf,Xf),lh.point=ch}function vh(t,e){Wf=t,Xf=e,t*=Rc,e*=Rc,lh.point=xh;var n=Fc(e);Kf=n*Fc(t),Qf=n*Gc(t),Yf=Gc(e),fh(Kf,Qf,Yf)}function xh(t,e){t*=Rc;var n=Fc(e*=Rc),r=n*Fc(t),i=n*Gc(t),o=Gc(e),a=Qf*o-Yf*i,s=Yf*r-Kf*o,u=Kf*i-Qf*r,l=Bc(a,s,u),c=Kc(l),f=l&&-c/l;Gf.add(f*a),Uf.add(f*s),Hf.add(f*u),Nf+=c,Bf+=c*(Kf+(Kf=r)),Vf+=c*(Qf+(Qf=i)),qf+=c*(Yf+(Yf=o)),fh(Kf,Qf,Yf)}function _h(t){Df=Nf=Ff=jf=zf=Bf=Vf=qf=0,Gf=new S,Uf=new S,Hf=new S,nf(t,lh);var e=+Gf,n=+Uf,r=+Hf,i=Bc(e,n,r);return i<Cc&&(e=Bf,n=Vf,r=qf,Nf<Ec&&(e=Ff,n=jf,r=zf),(i=Bc(e,n,r))<Cc)?[NaN,NaN]:[Nc(n,e)*Lc,Kc(r/i)*Lc]}function bh(t){return function(){return t}}function wh(t,e){function n(n,r){return n=t(n,r),e(n[0],n[1])}return t.invert&&e.invert&&(n.invert=function(n,r){return(n=e.invert(n,r))&&t.invert(n[0],n[1])}),n}function Mh(t,e){return Ic(t)>kc&&(t-=Math.round(t/Pc)*Pc),[t,e]}function Ah(t,e,n){return(t%=Pc)?e||n?wh(Eh(t),Ch(e,n)):Eh(t):e||n?Ch(e,n):Mh}function Th(t){return function(e,n){return Ic(e+=t)>kc&&(e-=Math.round(e/Pc)*Pc),[e,n]}}function Eh(t){var e=Th(t);return e.invert=Th(-t),e}function Ch(t,e){var n=Fc(t),r=Gc(t),i=Fc(e),o=Gc(e);function a(t,e){var a=Fc(e),s=Fc(t)*a,u=Gc(t)*a,l=Gc(e),c=l*n+s*r;return[Nc(u*i-c*o,s*n-l*r),Kc(c*i+u*o)]}return a.invert=function(t,e){var a=Fc(e),s=Fc(t)*a,u=Gc(t)*a,l=Gc(e),c=l*i-u*o;return[Nc(u*i+l*o,s*n+c*r),Kc(c*n-s*r)]},a}function kh(t){function e(e){return(e=t(e[0]*Rc,e[1]*Rc))[0]*=Lc,e[1]*=Lc,e}return t=Ah(t[0]*Rc,t[1]*Rc,t.length>2?t[2]*Rc:0),e.invert=function(e){return(e=t.invert(e[0]*Rc,e[1]*Rc))[0]*=Lc,e[1]*=Lc,e},e}function Sh(t,e,n,r,i,o){if(n){var a=Fc(e),s=Gc(e),u=r*n;null==i?(i=e+r*Pc,o=e-u/2):(i=Oh(a,i),o=Oh(a,o),(r>0?i<o:i>o)&&(i+=r*Pc));for(var l,c=i;r>0?c>o:c<o;c-=u)l=kf([a,-s*Fc(c),-s*Gc(c)]),t.point(l[0],l[1])}}function Oh(t,e){(e=Sf(e))[0]-=t,If(e);var n=Xc(-e[1]);return((-e[2]<0?-n:n)+Pc-Ec)%Pc}function Ph(){var t,e,n=bh([0,0]),r=bh(90),i=bh(2),o={point:function(n,r){t.push(n=e(n,r)),n[0]*=Lc,n[1]*=Lc}};function a(){var a=n.apply(this,arguments),s=r.apply(this,arguments)*Rc,u=i.apply(this,arguments)*Rc;return t=[],e=Ah(-a[0]*Rc,-a[1]*Rc,0).invert,Sh(o,s,u,1),a={type:"Polygon",coordinates:[t]},t=e=null,a}return a.center=function(t){return arguments.length?(n="function"==typeof t?t:bh([+t[0],+t[1]]),a):n},a.radius=function(t){return arguments.length?(r="function"==typeof t?t:bh(+t),a):r},a.precision=function(t){return arguments.length?(i="function"==typeof t?t:bh(+t),a):i},a}function Lh(){var t,e=[];return{point:function(e,n,r){t.push([e,n,r])},lineStart:function(){e.push(t=[])},lineEnd:Yc,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function Rh(t,e){return Ic(t[0]-e[0])<Ec&&Ic(t[1]-e[1])<Ec}function Ih(t,e,n,r){this.x=t,this.z=e,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Dh(t,e,n,r,i){var o,a,s=[],u=[];if(t.forEach((function(t){if(!((e=t.length-1)<=0)){var e,n,r=t[0],a=t[e];if(Rh(r,a)){if(!r[2]&&!a[2]){for(i.lineStart(),o=0;o<e;++o)i.point((r=t[o])[0],r[1]);return void i.lineEnd()}a[0]+=2*Ec}s.push(n=new Ih(r,t,null,!0)),u.push(n.o=new Ih(r,null,n,!1)),s.push(n=new Ih(a,t,null,!1)),u.push(n.o=new Ih(a,null,n,!0))}})),s.length){for(u.sort(e),Nh(s),Nh(u),o=0,a=u.length;o<a;++o)u[o].e=n=!n;for(var l,c,f=s[0];;){for(var h=f,d=!0;h.v;)if((h=h.n)===f)return;l=h.z,i.lineStart();do{if(h.v=h.o.v=!0,h.e){if(d)for(o=0,a=l.length;o<a;++o)i.point((c=l[o])[0],c[1]);else r(h.x,h.n.x,1,i);h=h.n}else{if(d)for(l=h.p.z,o=l.length-1;o>=0;--o)i.point((c=l[o])[0],c[1]);else r(h.x,h.p.x,-1,i);h=h.p}l=(h=h.o).z,d=!d}while(!h.v);i.lineEnd()}}}function Nh(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r<e;)i.n=n=t[r],n.p=i,i=n;i.n=n=t[0],n.p=i}}function Fh(t){return Ic(t[0])<=kc?t[0]:Uc(t[0])*((Ic(t[0])+kc)%Pc-kc)}function jh(t,e){var n=Fh(e),r=e[1],i=Gc(r),o=[Gc(n),-Fc(n),0],a=0,s=0,u=new S;1===i?r=Sc+Ec:-1===i&&(r=-Sc-Ec);for(var l=0,c=t.length;l<c;++l)if(h=(f=t[l]).length)for(var f,h,d=f[h-1],p=Fh(d),m=d[1]/2+Oc,g=Gc(m),y=Fc(m),v=0;v<h;++v,p=_,g=w,y=M,d=x){var x=f[v],_=Fh(x),b=x[1]/2+Oc,w=Gc(b),M=Fc(b),A=_-p,T=A>=0?1:-1,E=T*A,C=E>kc,k=g*w;if(u.add(Nc(k*T*Gc(E),y*M+k*Fc(E))),a+=C?A+T*Pc:A,C^p>=n^_>=n){var O=Pf(Sf(d),Sf(x));If(O);var P=Pf(o,O);If(P);var L=(C^A>=0?-1:1)*Kc(P[2]);(r>L||r===L&&(O[0]||O[1]))&&(s+=C^A>=0?1:-1)}}return(a<-Ec||a<Ec&&u<-Cc)^1&s}function zh(t,e,n,r){return function(i){var o,a,s,u=e(i),l=Lh(),c=e(l),f=!1,h={point:d,lineStart:m,lineEnd:g,polygonStart:function(){h.point=y,h.lineStart=v,h.lineEnd=x,a=[],o=[]},polygonEnd:function(){h.point=d,h.lineStart=m,h.lineEnd=g,a=St(a);var t=jh(o,r);a.length?(f||(i.polygonStart(),f=!0),Dh(a,Vh,t,n,i)):t&&(f||(i.polygonStart(),f=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),f&&(i.polygonEnd(),f=!1),a=o=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function d(e,n){t(e,n)&&i.point(e,n)}function p(t,e){u.point(t,e)}function m(){h.point=p,u.lineStart()}function g(){h.point=d,u.lineEnd()}function y(t,e){s.push([t,e]),c.point(t,e)}function v(){c.lineStart(),s=[]}function x(){y(s[0][0],s[0][1]),c.lineEnd();var t,e,n,r,u=c.clean(),h=l.result(),d=h.length;if(s.pop(),o.push(s),s=null,d)if(1&u){if((e=(n=h[0]).length-1)>0){for(f||(i.polygonStart(),f=!0),i.lineStart(),t=0;t<e;++t)i.point((r=n[t])[0],r[1]);i.lineEnd()}}else d>1&&2&u&&h.push(h.pop().concat(h.shift())),a.push(h.filter(Bh))}return h}}function Bh(t){return t.length>1}function Vh(t,e){return((t=t.x)[0]<0?t[1]-Sc-Ec:Sc-t[1])-((e=e.x)[0]<0?e[1]-Sc-Ec:Sc-e[1])}Mh.invert=Mh;var qh=zh((function(){return!0}),(function(t){var e,n=NaN,r=NaN,i=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(o,a){var s=o>0?kc:-kc,u=Ic(o-n);Ic(u-kc)<Ec?(t.point(n,r=(r+a)/2>0?Sc:-Sc),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),t.point(o,r),e=0):i!==s&&u>=kc&&(Ic(n-i)<Ec&&(n-=i*Ec),Ic(o-s)<Ec&&(o-=s*Ec),r=function(t,e,n,r){var i,o,a=Gc(t-n);return Ic(a)>Ec?Dc((Gc(e)*(o=Fc(r))*Gc(n)-Gc(r)*(i=Fc(e))*Gc(t))/(i*o*a)):(e+r)/2}(n,r,o,a),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),e=0),t.point(n=o,r=a),i=s},lineEnd:function(){t.lineEnd(),n=r=NaN},clean:function(){return 2-e}}}),(function(t,e,n,r){var i;if(null==t)i=n*Sc,r.point(-kc,i),r.point(0,i),r.point(kc,i),r.point(kc,0),r.point(kc,-i),r.point(0,-i),r.point(-kc,-i),r.point(-kc,0),r.point(-kc,i);else if(Ic(t[0]-e[0])>Ec){var o=t[0]<e[0]?kc:-kc;i=n*o/2,r.point(-o,i),r.point(0,i),r.point(o,i)}else r.point(e[0],e[1])}),[-kc,-Sc]);function Gh(t){var e=Fc(t),n=2*Rc,r=e>0,i=Ic(e)>Ec;function o(t,n){return Fc(t)*Fc(n)>e}function a(t,n,r){var i=[1,0,0],o=Pf(Sf(t),Sf(n)),a=Of(o,o),s=o[0],u=a-s*s;if(!u)return!r&&t;var l=e*a/u,c=-e*s/u,f=Pf(i,o),h=Rf(i,l);Lf(h,Rf(o,c));var d=f,p=Of(h,d),m=Of(d,d),g=p*p-m*(Of(h,h)-1);if(!(g<0)){var y=Hc(g),v=Rf(d,(-p-y)/m);if(Lf(v,h),v=kf(v),!r)return v;var x,_=t[0],b=n[0],w=t[1],M=n[1];b<_&&(x=_,_=b,b=x);var A=b-_,T=Ic(A-kc)<Ec;if(!T&&M<w&&(x=w,w=M,M=x),T||A<Ec?T?w+M>0^v[1]<(Ic(v[0]-_)<Ec?w:M):w<=v[1]&&v[1]<=M:A>kc^(_<=v[0]&&v[0]<=b)){var E=Rf(d,(-p+y)/m);return Lf(E,h),[v,kf(E)]}}}function s(e,n){var i=r?t:kc-t,o=0;return e<-i?o|=1:e>i&&(o|=2),n<-i?o|=4:n>i&&(o|=8),o}return zh(o,(function(t){var e,n,u,l,c;return{lineStart:function(){l=u=!1,c=1},point:function(f,h){var d,p=[f,h],m=o(f,h),g=r?m?0:s(f,h):m?s(f+(f<0?kc:-kc),h):0;if(!e&&(l=u=m)&&t.lineStart(),m!==u&&(!(d=a(e,p))||Rh(e,d)||Rh(p,d))&&(p[2]=1),m!==u)c=0,m?(t.lineStart(),d=a(p,e),t.point(d[0],d[1])):(d=a(e,p),t.point(d[0],d[1],2),t.lineEnd()),e=d;else if(i&&e&&r^m){var y;g&n||!(y=a(p,e,!0))||(c=0,r?(t.lineStart(),t.point(y[0][0],y[0][1]),t.point(y[1][0],y[1][1]),t.lineEnd()):(t.point(y[1][0],y[1][1]),t.lineEnd(),t.lineStart(),t.point(y[0][0],y[0][1],3)))}!m||e&&Rh(e,p)||t.point(p[0],p[1]),e=p,u=m,n=g},lineEnd:function(){u&&t.lineEnd(),e=null},clean:function(){return c|(l&&u)<<1}}}),(function(e,r,i,o){Sh(o,t,n,i,e,r)}),r?[0,-t]:[-kc,t-kc])}var Uh,Hh,Wh,Xh,Kh=1e9,Qh=-Kh;function Yh(t,e,n,r){function i(i,o){return t<=i&&i<=n&&e<=o&&o<=r}function o(i,o,s,l){var c=0,f=0;if(null==i||(c=a(i,s))!==(f=a(o,s))||u(i,o)<0^s>0)do{l.point(0===c||3===c?t:n,c>1?r:e)}while((c=(c+s+4)%4)!==f);else l.point(o[0],o[1])}function a(r,i){return Ic(r[0]-t)<Ec?i>0?0:3:Ic(r[0]-n)<Ec?i>0?2:1:Ic(r[1]-e)<Ec?i>0?1:0:i>0?3:2}function s(t,e){return u(t.x,e.x)}function u(t,e){var n=a(t,1),r=a(e,1);return n!==r?n-r:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(a){var u,l,c,f,h,d,p,m,g,y,v,x=a,_=Lh(),b={point:w,lineStart:function(){b.point=M,l&&l.push(c=[]);y=!0,g=!1,p=m=NaN},lineEnd:function(){u&&(M(f,h),d&&g&&_.rejoin(),u.push(_.result()));b.point=w,g&&x.lineEnd()},polygonStart:function(){x=_,u=[],l=[],v=!0},polygonEnd:function(){var e=function(){for(var e=0,n=0,i=l.length;n<i;++n)for(var o,a,s=l[n],u=1,c=s.length,f=s[0],h=f[0],d=f[1];u<c;++u)o=h,a=d,h=(f=s[u])[0],d=f[1],a<=r?d>r&&(h-o)*(r-a)>(d-a)*(t-o)&&++e:d<=r&&(h-o)*(r-a)<(d-a)*(t-o)&&--e;return e}(),n=v&&e,i=(u=St(u)).length;(n||i)&&(a.polygonStart(),n&&(a.lineStart(),o(null,null,1,a),a.lineEnd()),i&&Dh(u,s,e,o,a),a.polygonEnd());x=a,u=l=c=null}};function w(t,e){i(t,e)&&x.point(t,e)}function M(o,a){var s=i(o,a);if(l&&c.push([o,a]),y)f=o,h=a,d=s,y=!1,s&&(x.lineStart(),x.point(o,a));else if(s&&g)x.point(o,a);else{var u=[p=Math.max(Qh,Math.min(Kh,p)),m=Math.max(Qh,Math.min(Kh,m))],_=[o=Math.max(Qh,Math.min(Kh,o)),a=Math.max(Qh,Math.min(Kh,a))];!function(t,e,n,r,i,o){var a,s=t[0],u=t[1],l=0,c=1,f=e[0]-s,h=e[1]-u;if(a=n-s,f||!(a>0)){if(a/=f,f<0){if(a<l)return;a<c&&(c=a)}else if(f>0){if(a>c)return;a>l&&(l=a)}if(a=i-s,f||!(a<0)){if(a/=f,f<0){if(a>c)return;a>l&&(l=a)}else if(f>0){if(a<l)return;a<c&&(c=a)}if(a=r-u,h||!(a>0)){if(a/=h,h<0){if(a<l)return;a<c&&(c=a)}else if(h>0){if(a>c)return;a>l&&(l=a)}if(a=o-u,h||!(a<0)){if(a/=h,h<0){if(a>c)return;a>l&&(l=a)}else if(h>0){if(a<l)return;a<c&&(c=a)}return l>0&&(t[0]=s+l*f,t[1]=u+l*h),c<1&&(e[0]=s+c*f,e[1]=u+c*h),!0}}}}}(u,_,t,e,n,r)?s&&(x.lineStart(),x.point(o,a),v=!1):(g||(x.lineStart(),x.point(u[0],u[1])),x.point(_[0],_[1]),s||x.lineEnd(),v=!1)}p=o,m=a,g=s}return b}}function $h(){var t,e,n,r=0,i=0,o=960,a=500;return n={stream:function(n){return t&&e===n?t:t=Yh(r,i,o,a)(e=n)},extent:function(s){return arguments.length?(r=+s[0][0],i=+s[0][1],o=+s[1][0],a=+s[1][1],t=e=null,n):[[r,i],[o,a]]}}}var Zh={sphere:Yc,point:Yc,lineStart:function(){Zh.point=td,Zh.lineEnd=Jh},lineEnd:Yc,polygonStart:Yc,polygonEnd:Yc};function Jh(){Zh.point=Zh.lineEnd=Yc}function td(t,e){Hh=t*=Rc,Wh=Gc(e*=Rc),Xh=Fc(e),Zh.point=ed}function ed(t,e){t*=Rc;var n=Gc(e*=Rc),r=Fc(e),i=Ic(t-Hh),o=Fc(i),a=r*Gc(i),s=Xh*n-Wh*r*o,u=Wh*n+Xh*r*o;Uh.add(Nc(Hc(a*a+s*s),u)),Hh=t,Wh=n,Xh=r}function nd(t){return Uh=new S,nf(t,Zh),+Uh}var rd=[null,null],id={type:"LineString",coordinates:rd};function od(t,e){return rd[0]=t,rd[1]=e,nd(id)}var ad={Feature:function(t,e){return ud(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)if(ud(n[r].geometry,e))return!0;return!1}},sd={Sphere:function(){return!0},Point:function(t,e){return ld(t.coordinates,e)},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(ld(n[r],e))return!0;return!1},LineString:function(t,e){return cd(t.coordinates,e)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(cd(n[r],e))return!0;return!1},Polygon:function(t,e){return fd(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(fd(n[r],e))return!0;return!1},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)if(ud(n[r],e))return!0;return!1}};function ud(t,e){return!(!t||!sd.hasOwnProperty(t.type))&&sd[t.type](t,e)}function ld(t,e){return 0===od(t,e)}function cd(t,e){for(var n,r,i,o=0,a=t.length;o<a;o++){if(0===(r=od(t[o],e)))return!0;if(o>0&&(i=od(t[o],t[o-1]))>0&&n<=i&&r<=i&&(n+r-i)*(1-Math.pow((n-r)/i,2))<Cc*i)return!0;n=r}return!1}function fd(t,e){return!!jh(t.map(hd),dd(e))}function hd(t){return(t=t.map(dd)).pop(),t}function dd(t){return[t[0]*Rc,t[1]*Rc]}function pd(t,e){return(t&&ad.hasOwnProperty(t.type)?ad[t.type]:ud)(t,e)}function md(t,e,n){var r=Rt(t,e-Ec,n).concat(e);return function(t){return r.map((function(e){return[t,e]}))}}function gd(t,e,n){var r=Rt(t,e-Ec,n).concat(e);return function(t){return r.map((function(e){return[e,t]}))}}function yd(){var t,e,n,r,i,o,a,s,u,l,c,f,h=10,d=h,p=90,m=360,g=2.5;function y(){return{type:"MultiLineString",coordinates:v()}}function v(){return Rt(jc(r/p)*p,n,p).map(c).concat(Rt(jc(s/m)*m,a,m).map(f)).concat(Rt(jc(e/h)*h,t,h).filter((function(t){return Ic(t%p)>Ec})).map(u)).concat(Rt(jc(o/d)*d,i,d).filter((function(t){return Ic(t%m)>Ec})).map(l))}return y.lines=function(){return v().map((function(t){return{type:"LineString",coordinates:t}}))},y.outline=function(){return{type:"Polygon",coordinates:[c(r).concat(f(a).slice(1),c(n).reverse().slice(1),f(s).reverse().slice(1))]}},y.extent=function(t){return arguments.length?y.extentMajor(t).extentMinor(t):y.extentMinor()},y.extentMajor=function(t){return arguments.length?(r=+t[0][0],n=+t[1][0],s=+t[0][1],a=+t[1][1],r>n&&(t=r,r=n,n=t),s>a&&(t=s,s=a,a=t),y.precision(g)):[[r,s],[n,a]]},y.extentMinor=function(n){return arguments.length?(e=+n[0][0],t=+n[1][0],o=+n[0][1],i=+n[1][1],e>t&&(n=e,e=t,t=n),o>i&&(n=o,o=i,i=n),y.precision(g)):[[e,o],[t,i]]},y.step=function(t){return arguments.length?y.stepMajor(t).stepMinor(t):y.stepMinor()},y.stepMajor=function(t){return arguments.length?(p=+t[0],m=+t[1],y):[p,m]},y.stepMinor=function(t){return arguments.length?(h=+t[0],d=+t[1],y):[h,d]},y.precision=function(h){return arguments.length?(g=+h,u=md(o,i,90),l=gd(e,t,g),c=md(s,a,90),f=gd(r,n,g),y):g},y.extentMajor([[-180,-90+Ec],[180,90-Ec]]).extentMinor([[-180,-80-Ec],[180,80+Ec]])}function vd(){return yd()()}function xd(t,e){var n=t[0]*Rc,r=t[1]*Rc,i=e[0]*Rc,o=e[1]*Rc,a=Fc(r),s=Gc(r),u=Fc(o),l=Gc(o),c=a*Fc(n),f=a*Gc(n),h=u*Fc(i),d=u*Gc(i),p=2*Kc(Hc(Qc(o-r)+a*u*Qc(i-n))),m=Gc(p),g=p?function(t){var e=Gc(t*=p)/m,n=Gc(p-t)/m,r=n*c+e*h,i=n*f+e*d,o=n*s+e*l;return[Nc(i,r)*Lc,Nc(o,Hc(r*r+i*i))*Lc]}:function(){return[n*Lc,r*Lc]};return g.distance=p,g}var _d,bd,wd,Md,Ad=t=>t,Td=new S,Ed=new S,Cd={point:Yc,lineStart:Yc,lineEnd:Yc,polygonStart:function(){Cd.lineStart=kd,Cd.lineEnd=Pd},polygonEnd:function(){Cd.lineStart=Cd.lineEnd=Cd.point=Yc,Td.add(Ic(Ed)),Ed=new S},result:function(){var t=Td/2;return Td=new S,t}};function kd(){Cd.point=Sd}function Sd(t,e){Cd.point=Od,_d=wd=t,bd=Md=e}function Od(t,e){Ed.add(Md*t-wd*e),wd=t,Md=e}function Pd(){Od(_d,bd)}var Ld=Cd,Rd=1/0,Id=Rd,Dd=-Rd,Nd=Dd,Fd={point:function(t,e){t<Rd&&(Rd=t);t>Dd&&(Dd=t);e<Id&&(Id=e);e>Nd&&(Nd=e)},lineStart:Yc,lineEnd:Yc,polygonStart:Yc,polygonEnd:Yc,result:function(){var t=[[Rd,Id],[Dd,Nd]];return Dd=Nd=-(Id=Rd=1/0),t}};var jd,zd,Bd,Vd,qd=Fd,Gd=0,Ud=0,Hd=0,Wd=0,Xd=0,Kd=0,Qd=0,Yd=0,$d=0,Zd={point:Jd,lineStart:tp,lineEnd:rp,polygonStart:function(){Zd.lineStart=ip,Zd.lineEnd=op},polygonEnd:function(){Zd.point=Jd,Zd.lineStart=tp,Zd.lineEnd=rp},result:function(){var t=$d?[Qd/$d,Yd/$d]:Kd?[Wd/Kd,Xd/Kd]:Hd?[Gd/Hd,Ud/Hd]:[NaN,NaN];return Gd=Ud=Hd=Wd=Xd=Kd=Qd=Yd=$d=0,t}};function Jd(t,e){Gd+=t,Ud+=e,++Hd}function tp(){Zd.point=ep}function ep(t,e){Zd.point=np,Jd(Bd=t,Vd=e)}function np(t,e){var n=t-Bd,r=e-Vd,i=Hc(n*n+r*r);Wd+=i*(Bd+t)/2,Xd+=i*(Vd+e)/2,Kd+=i,Jd(Bd=t,Vd=e)}function rp(){Zd.point=Jd}function ip(){Zd.point=ap}function op(){sp(jd,zd)}function ap(t,e){Zd.point=sp,Jd(jd=Bd=t,zd=Vd=e)}function sp(t,e){var n=t-Bd,r=e-Vd,i=Hc(n*n+r*r);Wd+=i*(Bd+t)/2,Xd+=i*(Vd+e)/2,Kd+=i,Qd+=(i=Vd*t-Bd*e)*(Bd+t),Yd+=i*(Vd+e),$d+=3*i,Jd(Bd=t,Vd=e)}var up=Zd;function lp(t){this._context=t}lp.prototype={_radius:4.5,pointRadius:function(t){return this._radius=t,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._context.closePath(),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._context.moveTo(t,e),this._point=1;break;case 1:this._context.lineTo(t,e);break;default:this._context.moveTo(t+this._radius,e),this._context.arc(t,e,this._radius,0,Pc)}},result:Yc};var cp,fp,hp,dp,pp,mp=new S,gp={point:Yc,lineStart:function(){gp.point=yp},lineEnd:function(){cp&&vp(fp,hp),gp.point=Yc},polygonStart:function(){cp=!0},polygonEnd:function(){cp=null},result:function(){var t=+mp;return mp=new S,t}};function yp(t,e){gp.point=vp,fp=dp=t,hp=pp=e}function vp(t,e){dp-=t,pp-=e,mp.add(Hc(dp*dp+pp*pp)),dp=t,pp=e}var xp=gp;let _p,bp,wp,Mp;class Ap{constructor(t){this._append=null==t?Tp:function(t){const e=Math.floor(t);if(!(e>=0))throw new RangeError(`invalid digits: ${t}`);if(e>15)return Tp;if(e!==_p){const t=10**e;_p=e,bp=function(e){let n=1;this._+=e[0];for(const r=e.length;n<r;++n)this._+=Math.round(arguments[n]*t)/t+e[n]}}return bp}(t),this._radius=4.5,this._=""}pointRadius(t){return this._radius=+t,this}polygonStart(){this._line=0}polygonEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){0===this._line&&(this._+="Z"),this._point=NaN}point(t,e){switch(this._point){case 0:this._append`M${t},${e}`,this._point=1;break;case 1:this._append`L${t},${e}`;break;default:if(this._append`M${t},${e}`,this._radius!==wp||this._append!==bp){const t=this._radius,e=this._;this._="",this._append`m0,${t}a${t},${t} 0 1,1 0,${-2*t}a${t},${t} 0 1,1 0,${2*t}z`,wp=t,bp=this._append,Mp=this._,this._=e}this._+=Mp}}result(){const t=this._;return this._="",t.length?t:null}}function Tp(t){let e=1;this._+=t[0];for(const n=t.length;e<n;++e)this._+=arguments[e]+t[e]}function Ep(t,e){let n,r,i=3,o=4.5;function a(t){return t&&("function"==typeof o&&r.pointRadius(+o.apply(this,arguments)),nf(t,n(r))),r.result()}return a.area=function(t){return nf(t,n(Ld)),Ld.result()},a.measure=function(t){return nf(t,n(xp)),xp.result()},a.bounds=function(t){return nf(t,n(qd)),qd.result()},a.centroid=function(t){return nf(t,n(up)),up.result()},a.projection=function(e){return arguments.length?(n=null==e?(t=null,Ad):(t=e).stream,a):t},a.context=function(t){return arguments.length?(r=null==t?(e=null,new Ap(i)):new lp(e=t),"function"!=typeof o&&r.pointRadius(o),a):e},a.pointRadius=function(t){return arguments.length?(o="function"==typeof t?t:(r.pointRadius(+t),+t),a):o},a.digits=function(t){if(!arguments.length)return i;if(null==t)i=null;else{const e=Math.floor(t);if(!(e>=0))throw new RangeError(`invalid digits: ${t}`);i=e}return null===e&&(r=new Ap(i)),a},a.projection(t).digits(i).context(e)}function Cp(t){return{stream:kp(t)}}function kp(t){return function(e){var n=new Sp;for(var r in t)n[r]=t[r];return n.stream=e,n}}function Sp(){}function Op(t,e,n){var r=t.clipExtent&&t.clipExtent();return t.scale(150).translate([0,0]),null!=r&&t.clipExtent(null),nf(n,t.stream(qd)),e(qd.result()),null!=r&&t.clipExtent(r),t}function Pp(t,e,n){return Op(t,(function(n){var r=e[1][0]-e[0][0],i=e[1][1]-e[0][1],o=Math.min(r/(n[1][0]-n[0][0]),i/(n[1][1]-n[0][1])),a=+e[0][0]+(r-o*(n[1][0]+n[0][0]))/2,s=+e[0][1]+(i-o*(n[1][1]+n[0][1]))/2;t.scale(150*o).translate([a,s])}),n)}function Lp(t,e,n){return Pp(t,[[0,0],e],n)}function Rp(t,e,n){return Op(t,(function(n){var r=+e,i=r/(n[1][0]-n[0][0]),o=(r-i*(n[1][0]+n[0][0]))/2,a=-i*n[0][1];t.scale(150*i).translate([o,a])}),n)}function Ip(t,e,n){return Op(t,(function(n){var r=+e,i=r/(n[1][1]-n[0][1]),o=-i*n[0][0],a=(r-i*(n[1][1]+n[0][1]))/2;t.scale(150*i).translate([o,a])}),n)}Sp.prototype={constructor:Sp,point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};var Dp=16,Np=Fc(30*Rc);function Fp(t,e){return+e?function(t,e){function n(r,i,o,a,s,u,l,c,f,h,d,p,m,g){var y=l-r,v=c-i,x=y*y+v*v;if(x>4*e&&m--){var _=a+h,b=s+d,w=u+p,M=Hc(_*_+b*b+w*w),A=Kc(w/=M),T=Ic(Ic(w)-1)<Ec||Ic(o-f)<Ec?(o+f)/2:Nc(b,_),E=t(T,A),C=E[0],k=E[1],S=C-r,O=k-i,P=v*S-y*O;(P*P/x>e||Ic((y*S+v*O)/x-.5)>.3||a*h+s*d+u*p<Np)&&(n(r,i,o,a,s,u,C,k,T,_/=M,b/=M,w,m,g),g.point(C,k),n(C,k,T,_,b,w,l,c,f,h,d,p,m,g))}}return function(e){var r,i,o,a,s,u,l,c,f,h,d,p,m={point:g,lineStart:y,lineEnd:x,polygonStart:function(){e.polygonStart(),m.lineStart=_},polygonEnd:function(){e.polygonEnd(),m.lineStart=y}};function g(n,r){n=t(n,r),e.point(n[0],n[1])}function y(){c=NaN,m.point=v,e.lineStart()}function v(r,i){var o=Sf([r,i]),a=t(r,i);n(c,f,l,h,d,p,c=a[0],f=a[1],l=r,h=o[0],d=o[1],p=o[2],Dp,e),e.point(c,f)}function x(){m.point=g,e.lineEnd()}function _(){y(),m.point=b,m.lineEnd=w}function b(t,e){v(r=t,e),i=c,o=f,a=h,s=d,u=p,m.point=v}function w(){n(c,f,l,h,d,p,i,o,r,a,s,u,Dp,e),m.lineEnd=x,x()}return m}}(t,e):function(t){return kp({point:function(e,n){e=t(e,n),this.stream.point(e[0],e[1])}})}(t)}var jp=kp({point:function(t,e){this.stream.point(t*Rc,e*Rc)}});function zp(t,e,n,r,i,o){if(!o)return function(t,e,n,r,i){function o(o,a){return[e+t*(o*=r),n-t*(a*=i)]}return o.invert=function(o,a){return[(o-e)/t*r,(n-a)/t*i]},o}(t,e,n,r,i);var a=Fc(o),s=Gc(o),u=a*t,l=s*t,c=a/t,f=s/t,h=(s*n-a*e)/t,d=(s*e+a*n)/t;function p(t,o){return[u*(t*=r)-l*(o*=i)+e,n-l*t-u*o]}return p.invert=function(t,e){return[r*(c*t-f*e+h),i*(d-f*t-c*e)]},p}function Bp(t){return Vp((function(){return t}))()}function Vp(t){var e,n,r,i,o,a,s,u,l,c,f=150,h=480,d=250,p=0,m=0,g=0,y=0,v=0,x=0,_=1,b=1,w=null,M=qh,A=null,T=Ad,E=.5;function C(t){return u(t[0]*Rc,t[1]*Rc)}function k(t){return(t=u.invert(t[0],t[1]))&&[t[0]*Lc,t[1]*Lc]}function S(){var t=zp(f,0,0,_,b,x).apply(null,e(p,m)),r=zp(f,h-t[0],d-t[1],_,b,x);return n=Ah(g,y,v),s=wh(e,r),u=wh(n,s),a=Fp(s,E),O()}function O(){return l=c=null,C}return C.stream=function(t){return l&&c===t?l:l=jp(function(t){return kp({point:function(e,n){var r=t(e,n);return this.stream.point(r[0],r[1])}})}(n)(M(a(T(c=t)))))},C.preclip=function(t){return arguments.length?(M=t,w=void 0,O()):M},C.postclip=function(t){return arguments.length?(T=t,A=r=i=o=null,O()):T},C.clipAngle=function(t){return arguments.length?(M=+t?Gh(w=t*Rc):(w=null,qh),O()):w*Lc},C.clipExtent=function(t){return arguments.length?(T=null==t?(A=r=i=o=null,Ad):Yh(A=+t[0][0],r=+t[0][1],i=+t[1][0],o=+t[1][1]),O()):null==A?null:[[A,r],[i,o]]},C.scale=function(t){return arguments.length?(f=+t,S()):f},C.translate=function(t){return arguments.length?(h=+t[0],d=+t[1],S()):[h,d]},C.center=function(t){return arguments.length?(p=t[0]%360*Rc,m=t[1]%360*Rc,S()):[p*Lc,m*Lc]},C.rotate=function(t){return arguments.length?(g=t[0]%360*Rc,y=t[1]%360*Rc,v=t.length>2?t[2]%360*Rc:0,S()):[g*Lc,y*Lc,v*Lc]},C.angle=function(t){return arguments.length?(x=t%360*Rc,S()):x*Lc},C.reflectX=function(t){return arguments.length?(_=t?-1:1,S()):_<0},C.reflectY=function(t){return arguments.length?(b=t?-1:1,S()):b<0},C.precision=function(t){return arguments.length?(a=Fp(s,E=t*t),O()):Hc(E)},C.fitExtent=function(t,e){return Pp(C,t,e)},C.fitSize=function(t,e){return Lp(C,t,e)},C.fitWidth=function(t,e){return Rp(C,t,e)},C.fitHeight=function(t,e){return Ip(C,t,e)},function(){return e=t.apply(this,arguments),C.invert=e.invert&&k,S()}}function qp(t){var e=0,n=kc/3,r=Vp(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Rc,n=t[1]*Rc):[e*Lc,n*Lc]},i}function Gp(t,e){var n=Gc(t),r=(n+Gc(e))/2;if(Ic(r)<Ec)return function(t){var e=Fc(t);function n(t,n){return[t*e,Gc(n)/e]}return n.invert=function(t,n){return[t/e,Kc(n*e)]},n}(t);var i=1+n*(2*r-n),o=Hc(i)/r;function a(t,e){var n=Hc(i-2*r*Gc(e))/r;return[n*Gc(t*=r),o-n*Fc(t)]}return a.invert=function(t,e){var n=o-e,a=Nc(t,Ic(n))*Uc(n);return n*r<0&&(a-=kc*Uc(t)*Uc(n)),[a/r,Kc((i-(t*t+n*n)*r*r)/(2*r))]},a}function Up(){return qp(Gp).scale(155.424).center([0,33.6442])}function Hp(){return Up().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Wp(){var t,e,n,r,i,o,a=Hp(),s=Up().rotate([154,0]).center([-2,58.5]).parallels([55,65]),u=Up().rotate([157,0]).center([-3,19.9]).parallels([8,18]),l={point:function(t,e){o=[t,e]}};function c(t){var e=t[0],a=t[1];return o=null,n.point(e,a),o||(r.point(e,a),o)||(i.point(e,a),o)}function f(){return t=e=null,c}return c.invert=function(t){var e=a.scale(),n=a.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&i<.234&&r>=-.425&&r<-.214?s:i>=.166&&i<.234&&r>=-.214&&r<-.115?u:a).invert(t)},c.stream=function(n){return t&&e===n?t:(r=[a.stream(e=n),s.stream(n),u.stream(n)],i=r.length,t={point:function(t,e){for(var n=-1;++n<i;)r[n].point(t,e)},sphere:function(){for(var t=-1;++t<i;)r[t].sphere()},lineStart:function(){for(var t=-1;++t<i;)r[t].lineStart()},lineEnd:function(){for(var t=-1;++t<i;)r[t].lineEnd()},polygonStart:function(){for(var t=-1;++t<i;)r[t].polygonStart()},polygonEnd:function(){for(var t=-1;++t<i;)r[t].polygonEnd()}});var r,i},c.precision=function(t){return arguments.length?(a.precision(t),s.precision(t),u.precision(t),f()):a.precision()},c.scale=function(t){return arguments.length?(a.scale(t),s.scale(.35*t),u.scale(t),c.translate(a.translate())):a.scale()},c.translate=function(t){if(!arguments.length)return a.translate();var e=a.scale(),o=+t[0],c=+t[1];return n=a.translate(t).clipExtent([[o-.455*e,c-.238*e],[o+.455*e,c+.238*e]]).stream(l),r=s.translate([o-.307*e,c+.201*e]).clipExtent([[o-.425*e+Ec,c+.12*e+Ec],[o-.214*e-Ec,c+.234*e-Ec]]).stream(l),i=u.translate([o-.205*e,c+.212*e]).clipExtent([[o-.214*e+Ec,c+.166*e+Ec],[o-.115*e-Ec,c+.234*e-Ec]]).stream(l),f()},c.fitExtent=function(t,e){return Pp(c,t,e)},c.fitSize=function(t,e){return Lp(c,t,e)},c.fitWidth=function(t,e){return Rp(c,t,e)},c.fitHeight=function(t,e){return Ip(c,t,e)},c.scale(1070)}function Xp(t){return function(e,n){var r=Fc(e),i=Fc(n),o=t(r*i);return o===1/0?[2,0]:[o*i*Gc(e),o*Gc(n)]}}function Kp(t){return function(e,n){var r=Hc(e*e+n*n),i=t(r),o=Gc(i),a=Fc(i);return[Nc(e*o,r*a),Kc(r&&n*o/r)]}}var Qp=Xp((function(t){return Hc(2/(1+t))}));function Yp(){return Bp(Qp).scale(124.75).clipAngle(179.999)}Qp.invert=Kp((function(t){return 2*Kc(t/2)}));var $p=Xp((function(t){return(t=Xc(t))&&t/Gc(t)}));function Zp(){return Bp($p).scale(79.4188).clipAngle(179.999)}function Jp(t,e){return[t,Vc(Wc((Sc+e)/2))]}function tm(){return em(Jp).scale(961/Pc)}function em(t){var e,n,r,i=Bp(t),o=i.center,a=i.scale,s=i.translate,u=i.clipExtent,l=null;function c(){var o=kc*a(),s=i(kh(i.rotate()).invert([0,0]));return u(null==l?[[s[0]-o,s[1]-o],[s[0]+o,s[1]+o]]:t===Jp?[[Math.max(s[0]-o,l),e],[Math.min(s[0]+o,n),r]]:[[l,Math.max(s[1]-o,e)],[n,Math.min(s[1]+o,r)]])}return i.scale=function(t){return arguments.length?(a(t),c()):a()},i.translate=function(t){return arguments.length?(s(t),c()):s()},i.center=function(t){return arguments.length?(o(t),c()):o()},i.clipExtent=function(t){return arguments.length?(null==t?l=e=n=r=null:(l=+t[0][0],e=+t[0][1],n=+t[1][0],r=+t[1][1]),c()):null==l?null:[[l,e],[n,r]]},c()}function nm(t){return Wc((Sc+t)/2)}function rm(t,e){var n=Fc(t),r=t===e?Gc(t):Vc(n/Fc(e))/Vc(nm(e)/nm(t)),i=n*qc(nm(t),r)/r;if(!r)return Jp;function o(t,e){i>0?e<-Sc+Ec&&(e=-Sc+Ec):e>Sc-Ec&&(e=Sc-Ec);var n=i/qc(nm(e),r);return[n*Gc(r*t),i-n*Fc(r*t)]}return o.invert=function(t,e){var n=i-e,o=Uc(r)*Hc(t*t+n*n),a=Nc(t,Ic(n))*Uc(n);return n*r<0&&(a-=kc*Uc(t)*Uc(n)),[a/r,2*Dc(qc(i/o,1/r))-Sc]},o}function im(){return qp(rm).scale(109.5).parallels([30,30])}function om(t,e){return[t,e]}function am(){return Bp(om).scale(152.63)}function sm(t,e){var n=Fc(t),r=t===e?Gc(t):(n-Fc(e))/(e-t),i=n/r+t;if(Ic(r)<Ec)return om;function o(t,e){var n=i-e,o=r*t;return[n*Gc(o),i-n*Fc(o)]}return o.invert=function(t,e){var n=i-e,o=Nc(t,Ic(n))*Uc(n);return n*r<0&&(o-=kc*Uc(t)*Uc(n)),[o/r,i-Uc(r)*Hc(t*t+n*n)]},o}function um(){return qp(sm).scale(131.154).center([0,13.9389])}$p.invert=Kp((function(t){return t})),Jp.invert=function(t,e){return[t,2*Dc(zc(e))-Sc]},om.invert=om;var lm=1.340264,cm=-.081106,fm=893e-6,hm=.003796,dm=Hc(3)/2;function pm(t,e){var n=Kc(dm*Gc(e)),r=n*n,i=r*r*r;return[t*Fc(n)/(dm*(lm+3*cm*r+i*(7*fm+9*hm*r))),n*(lm+cm*r+i*(fm+hm*r))]}function mm(){return Bp(pm).scale(177.158)}function gm(t,e){var n=Fc(e),r=Fc(t)*n;return[n*Gc(t)/r,Gc(e)/r]}function ym(){return Bp(gm).scale(144.049).clipAngle(60)}function vm(){var t,e,n,r,i,o,a,s=1,u=0,l=0,c=1,f=1,h=0,d=null,p=1,m=1,g=kp({point:function(t,e){var n=x([t,e]);this.stream.point(n[0],n[1])}}),y=Ad;function v(){return p=s*c,m=s*f,o=a=null,x}function x(n){var r=n[0]*p,i=n[1]*m;if(h){var o=i*t-r*e;r=r*t+i*e,i=o}return[r+u,i+l]}return x.invert=function(n){var r=n[0]-u,i=n[1]-l;if(h){var o=i*t+r*e;r=r*t-i*e,i=o}return[r/p,i/m]},x.stream=function(t){return o&&a===t?o:o=g(y(a=t))},x.postclip=function(t){return arguments.length?(y=t,d=n=r=i=null,v()):y},x.clipExtent=function(t){return arguments.length?(y=null==t?(d=n=r=i=null,Ad):Yh(d=+t[0][0],n=+t[0][1],r=+t[1][0],i=+t[1][1]),v()):null==d?null:[[d,n],[r,i]]},x.scale=function(t){return arguments.length?(s=+t,v()):s},x.translate=function(t){return arguments.length?(u=+t[0],l=+t[1],v()):[u,l]},x.angle=function(n){return arguments.length?(e=Gc(h=n%360*Rc),t=Fc(h),v()):h*Lc},x.reflectX=function(t){return arguments.length?(c=t?-1:1,v()):c<0},x.reflectY=function(t){return arguments.length?(f=t?-1:1,v()):f<0},x.fitExtent=function(t,e){return Pp(x,t,e)},x.fitSize=function(t,e){return Lp(x,t,e)},x.fitWidth=function(t,e){return Rp(x,t,e)},x.fitHeight=function(t,e){return Ip(x,t,e)},x}function xm(t,e){var n=e*e,r=n*n;return[t*(.8707-.131979*n+r*(r*(.003971*n-.001529*r)-.013791)),e*(1.007226+n*(.015085+r*(.028874*n-.044475-.005916*r)))]}function _m(){return Bp(xm).scale(175.295)}function bm(t,e){return[Fc(e)*Gc(t),Gc(e)]}function wm(){return Bp(bm).scale(249.5).clipAngle(90+Ec)}function Mm(t,e){var n=Fc(e),r=1+Fc(t)*n;return[n*Gc(t)/r,Gc(e)/r]}function Am(){return Bp(Mm).scale(250).clipAngle(142)}function Tm(t,e){return[Vc(Wc((Sc+e)/2)),-t]}function Em(){var t=em(Tm),e=t.center,n=t.rotate;return t.center=function(t){return arguments.length?e([-t[1],t[0]]):[(t=e())[1],-t[0]]},t.rotate=function(t){return arguments.length?n([t[0],t[1],t.length>2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90]).scale(159.155)}function Cm(t,e){return t.parent===e.parent?1:2}function km(t,e){return t+e.x}function Sm(t,e){return Math.max(t,e.y)}function Om(){var t=Cm,e=1,n=1,r=!1;function i(i){var o,a=0;i.eachAfter((function(e){var n=e.children;n?(e.x=function(t){return t.reduce(km,0)/t.length}(n),e.y=function(t){return 1+t.reduce(Sm,0)}(n)):(e.x=o?a+=t(e,o):0,e.y=0,o=e)}));var s=function(t){for(var e;e=t.children;)t=e[0];return t}(i),u=function(t){for(var e;e=t.children;)t=e[e.length-1];return t}(i),l=s.x-t(s,u)/2,c=u.x+t(u,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-l)/(c-l)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function Pm(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function Lm(t,e){t instanceof Map?(t=[void 0,t],void 0===e&&(e=Im)):void 0===e&&(e=Rm);for(var n,r,i,o,a,s=new Fm(t),u=[s];n=u.pop();)if((i=e(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)u.push(r=i[o]=new Fm(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(Nm)}function Rm(t){return t.children}function Im(t){return Array.isArray(t)?t[1]:null}function Dm(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function Nm(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function Fm(t){this.data=t,this.depth=this.height=0,this.parent=null}function jm(t){return null==t?null:zm(t)}function zm(t){if("function"!=typeof t)throw new Error;return t}function Bm(){return 0}function Vm(t){return function(){return t}}pm.invert=function(t,e){for(var n,r=e,i=r*r,o=i*i*i,a=0;a<12&&(o=(i=(r-=n=(r*(lm+cm*i+o*(fm+hm*i))-e)/(lm+3*cm*i+o*(7*fm+9*hm*i)))*r)*i*i,!(Ic(n)<Cc));++a);return[dm*t*(lm+3*cm*i+o*(7*fm+9*hm*i))/Fc(r),Kc(Gc(r)/dm)]},gm.invert=Kp(Dc),xm.invert=function(t,e){var n,r=e,i=25;do{var o=r*r,a=o*o;r-=n=(r*(1.007226+o*(.015085+a*(.028874*o-.044475-.005916*a)))-e)/(1.007226+o*(.045255+a*(.259866*o-.311325-.005916*11*a)))}while(Ic(n)>Ec&&--i>0);return[t/(.8707+(o=r*r)*(o*(o*o*o*(.003971-.001529*o)-.013791)-.131979)),r]},bm.invert=Kp(Kc),Mm.invert=Kp((function(t){return 2*Dc(t)})),Tm.invert=function(t,e){return[-e,2*Dc(zc(t))-Sc]},Fm.prototype=Lm.prototype={constructor:Fm,count:function(){return this.eachAfter(Pm)},each:function(t,e){let n=-1;for(const r of this)t.call(e,r,++n,this);return this},eachAfter:function(t,e){for(var n,r,i,o=this,a=[o],s=[],u=-1;o=a.pop();)if(s.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);for(;o=s.pop();)t.call(e,o,++u,this);return this},eachBefore:function(t,e){for(var n,r,i=this,o=[i],a=-1;i=o.pop();)if(t.call(e,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},find:function(t,e){let n=-1;for(const r of this)if(t.call(e,r,++n,this))return r},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();for(;t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){return Array.from(this)},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return Lm(this).eachBefore(Dm)},[Symbol.iterator]:function*(){var t,e,n,r,i=this,o=[i];do{for(t=o.reverse(),o=[];i=t.pop();)if(yield i,e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n])}while(o.length)}};const qm=1664525,Gm=1013904223,Um=4294967296;function Hm(){let t=1;return()=>(t=(qm*t+Gm)%Um)/Um}function Wm(t){return Xm(t,Hm())}function Xm(t,e){for(var n,r,i=0,o=(t=function(t,e){let n,r,i=t.length;for(;i;)r=e()*i--|0,n=t[i],t[i]=t[r],t[r]=n;return t}(Array.from(t),e)).length,a=[];i<o;)n=t[i],r&&Ym(r,n)?++i:(r=Zm(a=Km(a,n)),i=0);return r}function Km(t,e){var n,r;if($m(e,t))return[e];for(n=0;n<t.length;++n)if(Qm(e,t[n])&&$m(Jm(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(r=n+1;r<t.length;++r)if(Qm(Jm(t[n],t[r]),e)&&Qm(Jm(t[n],e),t[r])&&Qm(Jm(t[r],e),t[n])&&$m(tg(t[n],t[r],e),t))return[t[n],t[r],e];throw new Error}function Qm(t,e){var n=t.r-e.r,r=e.x-t.x,i=e.y-t.y;return n<0||n*n<r*r+i*i}function Ym(t,e){var n=t.r-e.r+1e-9*Math.max(t.r,e.r,1),r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function $m(t,e){for(var n=0;n<e.length;++n)if(!Ym(t,e[n]))return!1;return!0}function Zm(t){switch(t.length){case 1:return function(t){return{x:t.x,y:t.y,r:t.r}}(t[0]);case 2:return Jm(t[0],t[1]);case 3:return tg(t[0],t[1],t[2])}}function Jm(t,e){var n=t.x,r=t.y,i=t.r,o=e.x,a=e.y,s=e.r,u=o-n,l=a-r,c=s-i,f=Math.sqrt(u*u+l*l);return{x:(n+o+u/f*c)/2,y:(r+a+l/f*c)/2,r:(f+i+s)/2}}function tg(t,e,n){var r=t.x,i=t.y,o=t.r,a=e.x,s=e.y,u=e.r,l=n.x,c=n.y,f=n.r,h=r-a,d=r-l,p=i-s,m=i-c,g=u-o,y=f-o,v=r*r+i*i-o*o,x=v-a*a-s*s+u*u,_=v-l*l-c*c+f*f,b=d*p-h*m,w=(p*_-m*x)/(2*b)-r,M=(m*g-p*y)/b,A=(d*x-h*_)/(2*b)-i,T=(h*y-d*g)/b,E=M*M+T*T-1,C=2*(o+w*M+A*T),k=w*w+A*A-o*o,S=-(Math.abs(E)>1e-6?(C+Math.sqrt(C*C-4*E*k))/(2*E):k/C);return{x:r+w+M*S,y:i+A+T*S,r:S}}function eg(t,e,n){var r,i,o,a,s=t.x-e.x,u=t.y-e.y,l=s*s+u*u;l?(i=e.r+n.r,i*=i,a=t.r+n.r,i>(a*=a)?(r=(l+a-i)/(2*l),o=Math.sqrt(Math.max(0,a/l-r*r)),n.x=t.x-r*s-o*u,n.y=t.y-r*u+o*s):(r=(l+i-a)/(2*l),o=Math.sqrt(Math.max(0,i/l-r*r)),n.x=e.x+r*s-o*u,n.y=e.y+r*u+o*s)):(n.x=e.x+n.r,n.y=e.y)}function ng(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function rg(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,o=(e.y*n.r+n.y*e.r)/r;return i*i+o*o}function ig(t){this._=t,this.next=null,this.previous=null}function og(t,e){if(!(o=(t=function(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}(t)).length))return 0;var n,r,i,o,a,s,u,l,c,f,h;if((n=t[0]).x=0,n.y=0,!(o>1))return n.r;if(r=t[1],n.x=-r.r,r.x=n.r,r.y=0,!(o>2))return n.r+r.r;eg(r,n,i=t[2]),n=new ig(n),r=new ig(r),i=new ig(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(u=3;u<o;++u){eg(n._,r._,i=t[u]),i=new ig(i),l=r.next,c=n.previous,f=r._.r,h=n._.r;do{if(f<=h){if(ng(l._,i._)){r=l,n.next=r,r.previous=n,--u;continue t}f+=l._.r,l=l.next}else{if(ng(c._,i._)){(n=c).next=r,r.previous=n,--u;continue t}h+=c._.r,c=c.previous}}while(l!==c.next);for(i.previous=n,i.next=r,n.next=r.previous=r=i,a=rg(n);(i=i.next)!==r;)(s=rg(i))<a&&(n=i,a=s);r=n.next}for(n=[r._],i=r;(i=i.next)!==r;)n.push(i._);for(i=Xm(n,e),u=0;u<o;++u)(n=t[u]).x-=i.x,n.y-=i.y;return i.r}function ag(t){return og(t,Hm()),t}function sg(t){return Math.sqrt(t.value)}function ug(){var t=null,e=1,n=1,r=Bm;function i(i){const o=Hm();return i.x=e/2,i.y=n/2,t?i.eachBefore(lg(t)).eachAfter(cg(r,.5,o)).eachBefore(fg(1)):i.eachBefore(lg(sg)).eachAfter(cg(Bm,1,o)).eachAfter(cg(r,i.r/Math.min(e,n),o)).eachBefore(fg(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=jm(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"==typeof t?t:Vm(+t),i):r},i}function lg(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function cg(t,e,n){return function(r){if(i=r.children){var i,o,a,s=i.length,u=t(r)*e||0;if(u)for(o=0;o<s;++o)i[o].r+=u;if(a=og(i,n),u)for(o=0;o<s;++o)i[o].r-=u;r.r=a+u}}}function fg(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}function hg(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function dg(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(r-e)/t.value;++s<u;)(o=a[s]).y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*l}function pg(){var t=1,e=1,n=0,r=!1;function i(i){var o=i.height+1;return i.x0=i.y0=n,i.x1=t,i.y1=e/o,i.eachBefore(function(t,e){return function(r){r.children&&dg(r,r.x0,t*(r.depth+1)/e,r.x1,t*(r.depth+2)/e);var i=r.x0,o=r.y0,a=r.x1-n,s=r.y1-n;a<i&&(i=a=(i+a)/2),s<o&&(o=s=(o+s)/2),r.x0=i,r.y0=o,r.x1=a,r.y1=s}}(e,o)),r&&i.eachBefore(hg),i}return i.round=function(t){return arguments.length?(r=!!t,i):r},i.size=function(n){return arguments.length?(t=+n[0],e=+n[1],i):[t,e]},i.padding=function(t){return arguments.length?(n=+t,i):n},i}var mg={depth:-1},gg={},yg={};function vg(t){return t.id}function xg(t){return t.parentId}function _g(){var t,e=vg,n=xg;function r(r){var i,o,a,s,u,l,c,f,h=Array.from(r),d=e,p=n,m=new Map;if(null!=t){const e=h.map(((e,n)=>function(t){t=`${t}`;let e=t.length;wg(t,e-1)&&!wg(t,e-2)&&(t=t.slice(0,-1));return"/"===t[0]?t:`/${t}`}(t(e,n,r)))),n=e.map(bg),i=new Set(e).add("");for(const t of n)i.has(t)||(i.add(t),e.push(t),n.push(bg(t)),h.push(yg));d=(t,n)=>e[n],p=(t,e)=>n[e]}for(a=0,i=h.length;a<i;++a)o=h[a],l=h[a]=new Fm(o),null!=(c=d(o,a,r))&&(c+="")&&(f=l.id=c,m.set(f,m.has(f)?gg:l)),null!=(c=p(o,a,r))&&(c+="")&&(l.parent=c);for(a=0;a<i;++a)if(c=(l=h[a]).parent){if(!(u=m.get(c)))throw new Error("missing: "+c);if(u===gg)throw new Error("ambiguous: "+c);u.children?u.children.push(l):u.children=[l],l.parent=u}else{if(s)throw new Error("multiple roots");s=l}if(!s)throw new Error("no root");if(null!=t){for(;s.data===yg&&1===s.children.length;)s=s.children[0],--i;for(let t=h.length-1;t>=0&&(l=h[t]).data===yg;--t)l.data=null}if(s.parent=mg,s.eachBefore((function(t){t.depth=t.parent.depth+1,--i})).eachBefore(Nm),s.parent=null,i>0)throw new Error("cycle");return s}return r.id=function(t){return arguments.length?(e=jm(t),r):e},r.parentId=function(t){return arguments.length?(n=jm(t),r):n},r.path=function(e){return arguments.length?(t=jm(e),r):t},r}function bg(t){let e=t.length;if(e<2)return"";for(;--e>1&&!wg(t,e););return t.slice(0,e)}function wg(t,e){if("/"===t[e]){let n=0;for(;e>0&&"\\"===t[--e];)++n;if(!(1&n))return!0}return!1}function Mg(t,e){return t.parent===e.parent?1:2}function Ag(t){var e=t.children;return e?e[0]:t.t}function Tg(t){var e=t.children;return e?e[e.length-1]:t.t}function Eg(t,e,n){var r=n/(e.i-t.i);e.c-=r,e.s+=n,t.c+=r,e.z+=n,e.m+=n}function Cg(t,e,n){return t.a.parent===e.parent?t.a:n}function kg(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}function Sg(){var t=Mg,e=1,n=1,r=null;function i(i){var u=function(t){for(var e,n,r,i,o,a=new kg(t,0),s=[a];e=s.pop();)if(r=e._.children)for(e.children=new Array(o=r.length),i=o-1;i>=0;--i)s.push(n=e.children[i]=new kg(r[i],i)),n.parent=e;return(a.parent=new kg(null,0)).children=[a],a}(i);if(u.eachAfter(o),u.parent.m=-u.z,u.eachBefore(a),r)i.eachBefore(s);else{var l=i,c=i,f=i;i.eachBefore((function(t){t.x<l.x&&(l=t),t.x>c.x&&(c=t),t.depth>f.depth&&(f=t)}));var h=l===c?1:t(l,c)/2,d=h-l.x,p=e/(c.x+h+d),m=n/(f.depth||1);i.eachBefore((function(t){t.x=(t.x+d)*p,t.y=t.depth*m}))}return i}function o(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){!function(t){for(var e,n=0,r=0,i=t.children,o=i.length;--o>=0;)(e=i[o]).z+=n,e.m+=n,n+=e.s+(r+=e.c)}(e);var o=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-o):e.z=o}else i&&(e.z=i.z+t(e._,i._));e.parent.A=function(e,n,r){if(n){for(var i,o=e,a=e,s=n,u=o.parent.children[0],l=o.m,c=a.m,f=s.m,h=u.m;s=Tg(s),o=Ag(o),s&&o;)u=Ag(u),(a=Tg(a)).a=e,(i=s.z+f-o.z-l+t(s._,o._))>0&&(Eg(Cg(s,e,r),e,i),l+=i,c+=i),f+=s.m,l+=o.m,h+=u.m,c+=a.m;s&&!Tg(a)&&(a.t=s,a.m+=f-c),o&&!Ag(u)&&(u.t=o,u.m+=l-h,r=e)}return r}(e,i,e.parent.A||r[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function Og(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(i-n)/t.value;++s<u;)(o=a[s]).x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*l}kg.prototype=Object.create(Fm.prototype);var Pg=(1+Math.sqrt(5))/2;function Lg(t,e,n,r,i,o){for(var a,s,u,l,c,f,h,d,p,m,g,y=[],v=e.children,x=0,_=0,b=v.length,w=e.value;x<b;){u=i-n,l=o-r;do{c=v[_++].value}while(!c&&_<b);for(f=h=c,g=c*c*(m=Math.max(l/u,u/l)/(w*t)),p=Math.max(h/g,g/f);_<b;++_){if(c+=s=v[_].value,s<f&&(f=s),s>h&&(h=s),g=c*c*m,(d=Math.max(h/g,g/f))>p){c-=s;break}p=d}y.push(a={value:c,dice:u<l,children:v.slice(x,_)}),a.dice?dg(a,n,r,i,w?r+=l*c/w:o):Og(a,n,r,w?n+=u*c/w:i,o),w-=c,x=_}return y}var Rg=function t(e){function n(t,n,r,i,o){Lg(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(Pg);function Ig(){var t=Rg,e=!1,n=1,r=1,i=[0],o=Bm,a=Bm,s=Bm,u=Bm,l=Bm;function c(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(f),i=[0],e&&t.eachBefore(hg),t}function f(e){var n=i[e.depth],r=e.x0+n,c=e.y0+n,f=e.x1-n,h=e.y1-n;f<r&&(r=f=(r+f)/2),h<c&&(c=h=(c+h)/2),e.x0=r,e.y0=c,e.x1=f,e.y1=h,e.children&&(n=i[e.depth+1]=o(e)/2,r+=l(e)-n,c+=a(e)-n,(f-=s(e)-n)<r&&(r=f=(r+f)/2),(h-=u(e)-n)<c&&(c=h=(c+h)/2),t(e,r,c,f,h))}return c.round=function(t){return arguments.length?(e=!!t,c):e},c.size=function(t){return arguments.length?(n=+t[0],r=+t[1],c):[n,r]},c.tile=function(e){return arguments.length?(t=zm(e),c):t},c.padding=function(t){return arguments.length?c.paddingInner(t).paddingOuter(t):c.paddingInner()},c.paddingInner=function(t){return arguments.length?(o="function"==typeof t?t:Vm(+t),c):o},c.paddingOuter=function(t){return arguments.length?c.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):c.paddingTop()},c.paddingTop=function(t){return arguments.length?(a="function"==typeof t?t:Vm(+t),c):a},c.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:Vm(+t),c):s},c.paddingBottom=function(t){return arguments.length?(u="function"==typeof t?t:Vm(+t),c):u},c.paddingLeft=function(t){return arguments.length?(l="function"==typeof t?t:Vm(+t),c):l},c}function Dg(t,e,n,r,i){var o,a,s=t.children,u=s.length,l=new Array(u+1);for(l[0]=a=o=0;o<u;++o)l[o+1]=a+=s[o].value;!function t(e,n,r,i,o,a,u){if(e>=n-1){var c=s[e];return c.x0=i,c.y0=o,c.x1=a,void(c.y1=u)}var f=l[e],h=r/2+f,d=e+1,p=n-1;for(;d<p;){var m=d+p>>>1;l[m]<h?d=m+1:p=m}h-l[d-1]<l[d]-h&&e+1<d&&--d;var g=l[d]-f,y=r-g;if(a-i>u-o){var v=r?(i*y+a*g)/r:a;t(e,d,g,i,o,v,u),t(d,n,y,v,o,a,u)}else{var x=r?(o*y+u*g)/r:u;t(e,d,g,i,o,a,x),t(d,n,y,i,x,a,u)}}(0,u,t.value,e,n,r,i)}function Ng(t,e,n,r,i){(1&t.depth?Og:dg)(t,e,n,r,i)}var Fg=function t(e){function n(t,n,r,i,o){if((a=t._squarify)&&a.ratio===e)for(var a,s,u,l,c,f=-1,h=a.length,d=t.value;++f<h;){for(u=(s=a[f]).children,l=s.value=0,c=u.length;l<c;++l)s.value+=u[l].value;s.dice?dg(s,n,r,i,d?r+=(o-r)*s.value/d:o):Og(s,n,r,d?n+=(i-n)*s.value/d:i,o),d-=s.value}else t._squarify=a=Lg(e,t,n,r,i,o),a.ratio=e}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(Pg);function jg(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}function zg(t,e){var n=Dr(+t,+e);return function(t){var e=n(t);return e-360*Math.floor(e/360)}}function Bg(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}function Vg(t){return((t=Math.exp(t))+1/t)/2}var qg=function t(e,n,r){function i(t,i){var o,a,s=t[0],u=t[1],l=t[2],c=i[0],f=i[1],h=i[2],d=c-s,p=f-u,m=d*d+p*p;if(m<1e-12)a=Math.log(h/l)/e,o=function(t){return[s+t*d,u+t*p,l*Math.exp(e*t*a)]};else{var g=Math.sqrt(m),y=(h*h-l*l+r*m)/(2*l*n*g),v=(h*h-l*l-r*m)/(2*h*n*g),x=Math.log(Math.sqrt(y*y+1)-y),_=Math.log(Math.sqrt(v*v+1)-v);a=(_-x)/e,o=function(t){var r=t*a,i=Vg(x),o=l/(n*g)*(i*function(t){return((t=Math.exp(2*t))-1)/(t+1)}(e*r+x)-function(t){return((t=Math.exp(t))-1/t)/2}(x));return[s+o*d,u+o*p,l*i/Vg(e*r+x)]}}return o.duration=1e3*a*e/Math.SQRT2,o}return i.rho=function(e){var n=Math.max(.001,+e),r=n*n;return t(n,r,r*r)},i}(Math.SQRT2,2,4);function Gg(t){return function(e,n){var r=t((e=Tr(e)).h,(n=Tr(n)).h),i=Fr(e.s,n.s),o=Fr(e.l,n.l),a=Fr(e.opacity,n.opacity);return function(t){return e.h=r(t),e.s=i(t),e.l=o(t),e.opacity=a(t),e+""}}}var Ug=Gg(Dr),Hg=Gg(Fr);function Wg(t,e){var n=Fr((t=Da(t)).l,(e=Da(e)).l),r=Fr(t.a,e.a),i=Fr(t.b,e.b),o=Fr(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=r(e),t.b=i(e),t.opacity=o(e),t+""}}function Xg(t){return function(e,n){var r=t((e=Ga(e)).h,(n=Ga(n)).h),i=Fr(e.c,n.c),o=Fr(e.l,n.l),a=Fr(e.opacity,n.opacity);return function(t){return e.h=r(t),e.c=i(t),e.l=o(t),e.opacity=a(t),e+""}}}var Kg=Xg(Dr),Qg=Xg(Fr);function Yg(t){return function e(n){function r(e,r){var i=t((e=ts(e)).h,(r=ts(r)).h),o=Fr(e.s,r.s),a=Fr(e.l,r.l),s=Fr(e.opacity,r.opacity);return function(t){return e.h=i(t),e.s=o(t),e.l=a(Math.pow(t,n)),e.opacity=s(t),e+""}}return n=+n,r.gamma=e,r}(1)}var $g=Yg(Dr),Zg=Yg(Fr);function Jg(t,e){void 0===e&&(e=t,t=Zr);for(var n=0,r=e.length-1,i=e[0],o=new Array(r<0?0:r);n<r;)o[n]=t(i,i=e[++n]);return function(t){var e=Math.max(0,Math.min(r-1,Math.floor(t*=r)));return o[e](t-e)}}function ty(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n}function ey(t){for(var e,n=-1,r=t.length,i=t[r-1],o=0;++n<r;)e=i,i=t[n],o+=e[1]*i[0]-e[0]*i[1];return o/2}function ny(t){for(var e,n,r=-1,i=t.length,o=0,a=0,s=t[i-1],u=0;++r<i;)e=s,s=t[r],u+=n=e[0]*s[1]-s[0]*e[1],o+=(e[0]+s[0])*n,a+=(e[1]+s[1])*n;return[o/(u*=3),a/u]}function ry(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function iy(t,e){return t[0]-e[0]||t[1]-e[1]}function oy(t){const e=t.length,n=[0,1];let r,i=2;for(r=2;r<e;++r){for(;i>1&&ry(t[n[i-2]],t[n[i-1]],t[r])<=0;)--i;n[i++]=r}return n.slice(0,i)}function ay(t){if((n=t.length)<3)return null;var e,n,r=new Array(n),i=new Array(n);for(e=0;e<n;++e)r[e]=[+t[e][0],+t[e][1],e];for(r.sort(iy),e=0;e<n;++e)i[e]=[r[e][0],-r[e][1]];var o=oy(r),a=oy(i),s=a[0]===o[0],u=a[a.length-1]===o[o.length-1],l=[];for(e=o.length-1;e>=0;--e)l.push(t[r[o[e]][2]]);for(e=+s;e<a.length-u;++e)l.push(t[r[a[e]][2]]);return l}function sy(t,e){for(var n,r,i=t.length,o=t[i-1],a=e[0],s=e[1],u=o[0],l=o[1],c=!1,f=0;f<i;++f)n=(o=t[f])[0],(r=o[1])>s!=l>s&&a<(u-n)*(s-r)/(l-r)+n&&(c=!c),u=n,l=r;return c}function uy(t){for(var e,n,r=-1,i=t.length,o=t[i-1],a=o[0],s=o[1],u=0;++r<i;)e=a,n=s,e-=a=(o=t[r])[0],n-=s=o[1],u+=Math.hypot(e,n);return u}var ly=Math.random,cy=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,1===arguments.length?(n=t,t=0):n-=t,function(){return e()*n+t}}return n.source=t,n}(ly),fy=function t(e){function n(t,n){return arguments.length<2&&(n=t,t=0),t=Math.floor(t),n=Math.floor(n)-t,function(){return Math.floor(e()*n+t)}}return n.source=t,n}(ly),hy=function t(e){function n(t,n){var r,i;return t=null==t?0:+t,n=null==n?1:+n,function(){var o;if(null!=r)o=r,r=null;else do{r=2*e()-1,o=2*e()-1,i=r*r+o*o}while(!i||i>1);return t+n*o*Math.sqrt(-2*Math.log(i)/i)}}return n.source=t,n}(ly),dy=function t(e){var n=hy.source(e);function r(){var t=n.apply(this,arguments);return function(){return Math.exp(t())}}return r.source=t,r}(ly),py=function t(e){function n(t){return(t=+t)<=0?()=>0:function(){for(var n=0,r=t;r>1;--r)n+=e();return n+r*e()}}return n.source=t,n}(ly),my=function t(e){var n=py.source(e);function r(t){if(0==(t=+t))return e;var r=n(t);return function(){return r()/t}}return r.source=t,r}(ly),gy=function t(e){function n(t){return function(){return-Math.log1p(-e())/t}}return n.source=t,n}(ly),yy=function t(e){function n(t){if((t=+t)<0)throw new RangeError("invalid alpha");return t=1/-t,function(){return Math.pow(1-e(),t)}}return n.source=t,n}(ly),vy=function t(e){function n(t){if((t=+t)<0||t>1)throw new RangeError("invalid p");return function(){return Math.floor(e()+t)}}return n.source=t,n}(ly),xy=function t(e){function n(t){if((t=+t)<0||t>1)throw new RangeError("invalid p");return 0===t?()=>1/0:1===t?()=>1:(t=Math.log1p(-t),function(){return 1+Math.floor(Math.log1p(-e())/t)})}return n.source=t,n}(ly),_y=function t(e){var n=hy.source(e)();function r(t,r){if((t=+t)<0)throw new RangeError("invalid k");if(0===t)return()=>0;if(r=null==r?1:+r,1===t)return()=>-Math.log1p(-e())*r;var i=(t<1?t+1:t)-1/3,o=1/(3*Math.sqrt(i)),a=t<1?()=>Math.pow(e(),1/t):()=>1;return function(){do{do{var t=n(),s=1+o*t}while(s<=0);s*=s*s;var u=1-e()}while(u>=1-.0331*t*t*t*t&&Math.log(u)>=.5*t*t+i*(1-s+Math.log(s)));return i*s*a()*r}}return r.source=t,r}(ly),by=function t(e){var n=_y.source(e);function r(t,e){var r=n(t),i=n(e);return function(){var t=r();return 0===t?0:t/(t+i())}}return r.source=t,r}(ly),wy=function t(e){var n=xy.source(e),r=by.source(e);function i(t,e){return t=+t,(e=+e)>=1?()=>t:e<=0?()=>0:function(){for(var i=0,o=t,a=e;o*a>16&&o*(1-a)>16;){var s=Math.floor((o+1)*a),u=r(s,o-s+1)();u<=a?(i+=s,o-=s,a=(a-u)/(1-u)):(o=s-1,a/=u)}for(var l=a<.5,c=n(l?a:1-a),f=c(),h=0;f<=o;++h)f+=c();return i+(l?h:o-h)}}return i.source=t,i}(ly),My=function t(e){function n(t,n,r){var i;return 0==(t=+t)?i=t=>-Math.log(t):(t=1/t,i=e=>Math.pow(e,t)),n=null==n?0:+n,r=null==r?1:+r,function(){return n+r*i(-Math.log1p(-e()))}}return n.source=t,n}(ly),Ay=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,function(){return t+n*Math.tan(Math.PI*e())}}return n.source=t,n}(ly),Ty=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,function(){var r=e();return t+n*Math.log(r/(1-r))}}return n.source=t,n}(ly),Ey=function t(e){var n=_y.source(e),r=wy.source(e);function i(t){return function(){for(var i=0,o=t;o>16;){var a=Math.floor(.875*o),s=n(a)();if(s>o)return i+r(a-1,o/s)();i+=a,o-=s}for(var u=-Math.log1p(-e()),l=0;u<=o;++l)u-=Math.log1p(-e());return i+l}}return i.source=t,i}(ly);const Cy=1664525,ky=1013904223,Sy=1/4294967296;function Oy(t=Math.random()){let e=0|(0<=t&&t<1?t/Sy:Math.abs(t));return()=>(e=Cy*e+ky|0,Sy*(e>>>0))}function Py(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function Ly(t,e){switch(arguments.length){case 0:break;case 1:"function"==typeof t?this.interpolator(t):this.range(t);break;default:this.domain(t),"function"==typeof e?this.interpolator(e):this.range(e)}return this}const Ry=Symbol("implicit");function Iy(){var t=new L,e=[],n=[],r=Ry;function i(i){let o=t.get(i);if(void 0===o){if(r!==Ry)return r;t.set(i,o=e.push(i)-1)}return n[o%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new L;for(const r of n)t.has(r)||t.set(r,e.push(r)-1);return i},i.range=function(t){return arguments.length?(n=Array.from(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Iy(e,n).unknown(r)},Py.apply(i,arguments),i}function Dy(){var t,e,n=Iy().unknown(void 0),r=n.domain,i=n.range,o=0,a=1,s=!1,u=0,l=0,c=.5;function f(){var n=r().length,f=a<o,h=f?a:o,d=f?o:a;t=(d-h)/Math.max(1,n-u+2*l),s&&(t=Math.floor(t)),h+=(d-h-t*(n-u))*c,e=t*(1-u),s&&(h=Math.round(h),e=Math.round(e));var p=Rt(n).map((function(e){return h+t*e}));return i(f?p.reverse():p)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),f()):r()},n.range=function(t){return arguments.length?([o,a]=t,o=+o,a=+a,f()):[o,a]},n.rangeRound=function(t){return[o,a]=t,o=+o,a=+a,s=!0,f()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(s=!!t,f()):s},n.padding=function(t){return arguments.length?(u=Math.min(1,l=+t),f()):u},n.paddingInner=function(t){return arguments.length?(u=Math.min(1,t),f()):u},n.paddingOuter=function(t){return arguments.length?(l=+t,f()):l},n.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),f()):c},n.copy=function(){return Dy(r(),[o,a]).round(s).paddingInner(u).paddingOuter(l).align(c)},Py.apply(f(),arguments)}function Ny(t){var e=t.copy;return t.padding=t.paddingOuter,delete t.paddingInner,delete t.paddingOuter,t.copy=function(){return Ny(e())},t}function Fy(){return Ny(Dy.apply(null,arguments).paddingInner(1))}function jy(t){return+t}var zy=[0,1];function By(t){return t}function Vy(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function qy(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=Vy(i,r),o=n(a,o)):(r=Vy(r,i),o=n(o,a)),function(t){return o(r(t))}}function Gy(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=Vy(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=h(t,e,1,r)-1;return o[n](i[n](e))}}function Uy(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Hy(){var t,e,n,r,i,o,a=zy,s=zy,u=Zr,l=By;function c(){var t=Math.min(a.length,s.length);return l!==By&&(l=function(t,e){var n;return t>e&&(n=t,t=e,e=n),function(n){return Math.max(t,Math.min(e,n))}}(a[0],a[t-1])),r=t>2?Gy:qy,i=o=null,f}function f(e){return null==e||isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return f.invert=function(n){return l(e((o||(o=r(s,a.map(t),Xr)))(n)))},f.domain=function(t){return arguments.length?(a=Array.from(t,jy),c()):a.slice()},f.range=function(t){return arguments.length?(s=Array.from(t),c()):s.slice()},f.rangeRound=function(t){return s=Array.from(t),u=Bg,c()},f.clamp=function(t){return arguments.length?(l=!!t||By,c()):l!==By},f.interpolate=function(t){return arguments.length?(u=t,c()):u},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,c()}}function Wy(){return Hy()(By,By)}function Xy(t,e,n,r){var i,o=ct(t,e,n);switch((r=fc(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=Ac(o,a))||(r.precision=i),vc(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=Tc(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=Mc(o))||(r.precision=i-2*("%"===r.type))}return yc(r)}function Ky(t){var e=t.domain;return t.ticks=function(t){var n=e();return ut(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return Xy(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i,o=e(),a=0,s=o.length-1,u=o[a],l=o[s],c=10;for(l<u&&(i=u,u=l,l=i,i=a,a=s,s=i);c-- >0;){if((i=lt(u,l,n))===r)return o[a]=u,o[s]=l,e(o);if(i>0)u=Math.floor(u/i)*i,l=Math.ceil(l/i)*i;else{if(!(i<0))break;u=Math.ceil(u*i)/i,l=Math.floor(l*i)/i}r=i}return t},t}function Qy(){var t=Wy();return t.copy=function(){return Uy(t,Qy())},Py.apply(t,arguments),Ky(t)}function Yy(t){var e;function n(t){return null==t||isNaN(t=+t)?e:t}return n.invert=n,n.domain=n.range=function(e){return arguments.length?(t=Array.from(e,jy),n):t.slice()},n.unknown=function(t){return arguments.length?(e=t,n):e},n.copy=function(){return Yy(t).unknown(e)},t=arguments.length?Array.from(t,jy):[0,1],Ky(n)}function $y(t,e){var n,r=0,i=(t=t.slice()).length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function Zy(t){return Math.log(t)}function Jy(t){return Math.exp(t)}function tv(t){return-Math.log(-t)}function ev(t){return-Math.exp(-t)}function nv(t){return isFinite(t)?+("1e"+t):t<0?0:t}function rv(t){return(e,n)=>-t(-e,n)}function iv(t){const e=t(Zy,Jy),n=e.domain;let r,i,o=10;function a(){return r=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}(o),i=function(t){return 10===t?nv:t===Math.E?Math.exp:e=>Math.pow(t,e)}(o),n()[0]<0?(r=rv(r),i=rv(i),t(tv,ev)):t(Zy,Jy),e}return e.base=function(t){return arguments.length?(o=+t,a()):o},e.domain=function(t){return arguments.length?(n(t),a()):n()},e.ticks=t=>{const e=n();let a=e[0],s=e[e.length-1];const u=s<a;u&&([a,s]=[s,a]);let l,c,f=r(a),h=r(s);const d=null==t?10:+t;let p=[];if(!(o%1)&&h-f<d){if(f=Math.floor(f),h=Math.ceil(h),a>0){for(;f<=h;++f)for(l=1;l<o;++l)if(c=f<0?l/i(-f):l*i(f),!(c<a)){if(c>s)break;p.push(c)}}else for(;f<=h;++f)for(l=o-1;l>=1;--l)if(c=f>0?l/i(-f):l*i(f),!(c<a)){if(c>s)break;p.push(c)}2*p.length<d&&(p=ut(a,s,d))}else p=ut(f,h,Math.min(h-f,d)).map(i);return u?p.reverse():p},e.tickFormat=(t,n)=>{if(null==t&&(t=10),null==n&&(n=10===o?"s":","),"function"!=typeof n&&(o%1||null!=(n=fc(n)).precision||(n.trim=!0),n=yc(n)),t===1/0)return n;const a=Math.max(1,o*t/e.ticks().length);return t=>{let e=t/i(Math.round(r(t)));return e*o<o-.5&&(e*=o),e<=a?n(t):""}},e.nice=()=>n($y(n(),{floor:t=>i(Math.floor(r(t))),ceil:t=>i(Math.ceil(r(t)))})),e}function ov(){const t=iv(Hy()).domain([1,10]);return t.copy=()=>Uy(t,ov()).base(t.base()),Py.apply(t,arguments),t}function av(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function sv(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function uv(t){var e=1,n=t(av(e),sv(e));return n.constant=function(n){return arguments.length?t(av(e=+n),sv(e)):e},Ky(n)}function lv(){var t=uv(Hy());return t.copy=function(){return Uy(t,lv()).constant(t.constant())},Py.apply(t,arguments)}function cv(t){return function(e){return e<0?-Math.pow(-e,t):Math.pow(e,t)}}function fv(t){return t<0?-Math.sqrt(-t):Math.sqrt(t)}function hv(t){return t<0?-t*t:t*t}function dv(t){var e=t(By,By),n=1;return e.exponent=function(e){return arguments.length?1===(n=+e)?t(By,By):.5===n?t(fv,hv):t(cv(n),cv(1/n)):n},Ky(e)}function pv(){var t=dv(Hy());return t.copy=function(){return Uy(t,pv()).exponent(t.exponent())},Py.apply(t,arguments),t}function mv(){return pv.apply(null,arguments).exponent(.5)}function gv(t){return Math.sign(t)*t*t}function yv(){var t,e=Wy(),n=[0,1],r=!1;function i(n){var i=function(t){return Math.sign(t)*Math.sqrt(Math.abs(t))}(e(n));return isNaN(i)?t:r?Math.round(i):i}return i.invert=function(t){return e.invert(gv(t))},i.domain=function(t){return arguments.length?(e.domain(t),i):e.domain()},i.range=function(t){return arguments.length?(e.range((n=Array.from(t,jy)).map(gv)),i):n.slice()},i.rangeRound=function(t){return i.range(t).round(!0)},i.round=function(t){return arguments.length?(r=!!t,i):r},i.clamp=function(t){return arguments.length?(e.clamp(t),i):e.clamp()},i.unknown=function(e){return arguments.length?(t=e,i):t},i.copy=function(){return yv(e.domain(),n).round(r).clamp(e.clamp()).unknown(t)},Py.apply(i,arguments),Ky(i)}function vv(){var t,e=[],n=[],i=[];function o(){var t=0,r=Math.max(1,n.length);for(i=new Array(r-1);++t<r;)i[t-1]=wt(e,t/r);return a}function a(e){return null==e||isNaN(e=+e)?t:n[h(i,e)]}return a.invertExtent=function(t){var r=n.indexOf(t);return r<0?[NaN,NaN]:[r>0?i[r-1]:e[0],r<i.length?i[r]:e[e.length-1]]},a.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let n of t)null==n||isNaN(n=+n)||e.push(n);return e.sort(r),o()},a.range=function(t){return arguments.length?(n=Array.from(t),o()):n.slice()},a.unknown=function(e){return arguments.length?(t=e,a):t},a.quantiles=function(){return i.slice()},a.copy=function(){return vv().domain(e).range(n).unknown(t)},Py.apply(a,arguments)}function xv(){var t,e=0,n=1,r=1,i=[.5],o=[0,1];function a(e){return null!=e&&e<=e?o[h(i,e,0,r)]:t}function s(){var t=-1;for(i=new Array(r);++t<r;)i[t]=((t+1)*n-(t-r)*e)/(r+1);return a}return a.domain=function(t){return arguments.length?([e,n]=t,e=+e,n=+n,s()):[e,n]},a.range=function(t){return arguments.length?(r=(o=Array.from(t)).length-1,s()):o.slice()},a.invertExtent=function(t){var a=o.indexOf(t);return a<0?[NaN,NaN]:a<1?[e,i[0]]:a>=r?[i[r-1],n]:[i[a-1],i[a]]},a.unknown=function(e){return arguments.length?(t=e,a):a},a.thresholds=function(){return i.slice()},a.copy=function(){return xv().domain([e,n]).range(o).unknown(t)},Py.apply(Ky(a),arguments)}function _v(){var t,e=[.5],n=[0,1],r=1;function i(i){return null!=i&&i<=i?n[h(e,i,0,r)]:t}return i.domain=function(t){return arguments.length?(e=Array.from(t),r=Math.min(e.length,n.length-1),i):e.slice()},i.range=function(t){return arguments.length?(n=Array.from(t),r=Math.min(e.length,n.length-1),i):n.slice()},i.invertExtent=function(t){var r=n.indexOf(t);return[e[r-1],e[r]]},i.unknown=function(e){return arguments.length?(t=e,i):t},i.copy=function(){return _v().domain(e).range(n).unknown(t)},Py.apply(i,arguments)}const bv=1e3,wv=6e4,Mv=36e5,Av=864e5,Tv=6048e5,Ev=2592e6,Cv=31536e6,kv=new Date,Sv=new Date;function Ov(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=e=>(t(e=new Date(+e)),e),i.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),i.round=t=>{const e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=(t,n)=>(e(t=new Date(+t),null==n?1:Math.floor(n)),t),i.range=(n,r,o)=>{const a=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return a;let s;do{a.push(s=new Date(+n)),e(n,o),t(n)}while(s<n&&n<r);return a},i.filter=n=>Ov((e=>{if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),((t,r)=>{if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););})),n&&(i.count=(e,r)=>(kv.setTime(+e),Sv.setTime(+r),t(kv),t(Sv),Math.floor(n(kv,Sv))),i.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?e=>r(e)%t==0:e=>i.count(0,e)%t==0):i:null)),i}const Pv=Ov((()=>{}),((t,e)=>{t.setTime(+t+e)}),((t,e)=>e-t));Pv.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?Ov((e=>{e.setTime(Math.floor(e/t)*t)}),((e,n)=>{e.setTime(+e+n*t)}),((e,n)=>(n-e)/t)):Pv:null);const Lv=Pv.range,Rv=Ov((t=>{t.setTime(t-t.getMilliseconds())}),((t,e)=>{t.setTime(+t+e*bv)}),((t,e)=>(e-t)/bv),(t=>t.getUTCSeconds())),Iv=Rv.range,Dv=Ov((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*bv)}),((t,e)=>{t.setTime(+t+e*wv)}),((t,e)=>(e-t)/wv),(t=>t.getMinutes())),Nv=Dv.range,Fv=Ov((t=>{t.setUTCSeconds(0,0)}),((t,e)=>{t.setTime(+t+e*wv)}),((t,e)=>(e-t)/wv),(t=>t.getUTCMinutes())),jv=Fv.range,zv=Ov((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*bv-t.getMinutes()*wv)}),((t,e)=>{t.setTime(+t+e*Mv)}),((t,e)=>(e-t)/Mv),(t=>t.getHours())),Bv=zv.range,Vv=Ov((t=>{t.setUTCMinutes(0,0,0)}),((t,e)=>{t.setTime(+t+e*Mv)}),((t,e)=>(e-t)/Mv),(t=>t.getUTCHours())),qv=Vv.range,Gv=Ov((t=>t.setHours(0,0,0,0)),((t,e)=>t.setDate(t.getDate()+e)),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wv)/Av),(t=>t.getDate()-1)),Uv=Gv.range,Hv=Ov((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/Av),(t=>t.getUTCDate()-1)),Wv=Hv.range,Xv=Ov((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/Av),(t=>Math.floor(t/Av))),Kv=Xv.range;function Qv(t){return Ov((e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),((t,e)=>{t.setDate(t.getDate()+7*e)}),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*wv)/Tv))}const Yv=Qv(0),$v=Qv(1),Zv=Qv(2),Jv=Qv(3),tx=Qv(4),ex=Qv(5),nx=Qv(6),rx=Yv.range,ix=$v.range,ox=Zv.range,ax=Jv.range,sx=tx.range,ux=ex.range,lx=nx.range;function cx(t){return Ov((e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)}),((t,e)=>(e-t)/Tv))}const fx=cx(0),hx=cx(1),dx=cx(2),px=cx(3),mx=cx(4),gx=cx(5),yx=cx(6),vx=fx.range,xx=hx.range,_x=dx.range,bx=px.range,wx=mx.range,Mx=gx.range,Ax=yx.range,Tx=Ov((t=>{t.setDate(1),t.setHours(0,0,0,0)}),((t,e)=>{t.setMonth(t.getMonth()+e)}),((t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())),(t=>t.getMonth())),Ex=Tx.range,Cx=Ov((t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)}),((t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())),(t=>t.getUTCMonth())),kx=Cx.range,Sx=Ov((t=>{t.setMonth(0,1),t.setHours(0,0,0,0)}),((t,e)=>{t.setFullYear(t.getFullYear()+e)}),((t,e)=>e.getFullYear()-t.getFullYear()),(t=>t.getFullYear()));Sx.every=t=>isFinite(t=Math.floor(t))&&t>0?Ov((e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),((e,n)=>{e.setFullYear(e.getFullYear()+n*t)})):null;const Ox=Sx.range,Px=Ov((t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)}),((t,e)=>e.getUTCFullYear()-t.getUTCFullYear()),(t=>t.getUTCFullYear()));Px.every=t=>isFinite(t=Math.floor(t))&&t>0?Ov((e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),((e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null;const Lx=Px.range;function Rx(t,e,n,r,i,a){const s=[[Rv,1,bv],[Rv,5,5e3],[Rv,15,15e3],[Rv,30,3e4],[a,1,wv],[a,5,3e5],[a,15,9e5],[a,30,18e5],[i,1,Mv],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,Av],[r,2,1728e5],[n,1,Tv],[e,1,Ev],[e,3,7776e6],[t,1,Cv]];function u(e,n,r){const i=Math.abs(n-e)/r,a=o((([,,t])=>t)).right(s,i);if(a===s.length)return t.every(ct(e/Cv,n/Cv,r));if(0===a)return Pv.every(Math.max(ct(e,n,r),1));const[u,l]=s[i/s[a-1][2]<s[a][2]/i?a-1:a];return u.every(l)}return[function(t,e,n){const r=e<t;r&&([t,e]=[e,t]);const i=n&&"function"==typeof n.range?n:u(t,e,n),o=i?i.range(t,+e+1):[];return r?o.reverse():o},u]}const[Ix,Dx]=Rx(Px,Cx,fx,Xv,Vv,Fv),[Nx,Fx]=Rx(Sx,Tx,Yv,Gv,zv,Dv);function jx(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function zx(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Bx(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function Vx(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,l=Jx(i),c=t_(i),f=Jx(o),h=t_(o),d=Jx(a),p=t_(a),m=Jx(s),g=t_(s),y=Jx(u),v=t_(u),x={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:b_,e:b_,f:E_,g:F_,G:z_,H:w_,I:M_,j:A_,L:T_,m:C_,M:k_,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:ub,s:lb,S:S_,u:O_,U:P_,V:R_,w:I_,W:D_,x:null,X:null,y:N_,Y:j_,Z:B_,"%":sb},_={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:V_,e:V_,f:W_,g:rb,G:ob,H:q_,I:G_,j:U_,L:H_,m:X_,M:K_,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:ub,s:lb,S:Q_,u:Y_,U:$_,V:J_,w:tb,W:eb,x:null,X:null,y:nb,Y:ib,Z:ab,"%":sb},b={a:function(t,e,n){var r=d.exec(e.slice(n));return r?(t.w=p.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(t,e,n){var r=y.exec(e.slice(n));return r?(t.m=v.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=g.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(t,n,r){return A(t,e,n,r)},d:f_,e:f_,f:y_,g:s_,G:a_,H:d_,I:d_,j:h_,L:g_,m:c_,M:p_,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c.get(r[0].toLowerCase()),n+r[0].length):-1},q:l_,Q:x_,s:__,S:m_,u:n_,U:r_,V:i_,w:e_,W:o_,x:function(t,e,r){return A(t,n,e,r)},X:function(t,e,n){return A(t,r,e,n)},y:s_,Y:a_,Z:u_,"%":v_};function w(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Xx[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function M(t,e){return function(n){var r,i,o=Bx(1900,void 0,1);if(A(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=zx(Bx(o.y,0,1))).getUTCDay(),r=i>4||0===i?hx.ceil(r):hx(r),r=Hv.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=jx(Bx(o.y,0,1))).getDay(),r=i>4||0===i?$v.ceil(r):$v(r),r=Gv.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?zx(Bx(o.y,0,1)).getUTCDay():jx(Bx(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,zx(o)):jx(o)}}function A(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=b[i in Xx?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return x.x=w(n,x),x.X=w(r,x),x.c=w(e,x),_.x=w(n,_),_.X=w(r,_),_.c=w(e,_),{format:function(t){var e=w(t+="",x);return e.toString=function(){return t},e},parse:function(t){var e=M(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=M(t+="",!0);return e.toString=function(){return t},e}}}var qx,Gx,Ux,Hx,Wx,Xx={"-":"",_:" ",0:"0"},Kx=/^\s*\d+/,Qx=/^%/,Yx=/[\\^$*+?|[\]().{}]/g;function $x(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function Zx(t){return t.replace(Yx,"\\$&")}function Jx(t){return new RegExp("^(?:"+t.map(Zx).join("|")+")","i")}function t_(t){return new Map(t.map(((t,e)=>[t.toLowerCase(),e])))}function e_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function n_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function r_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function i_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function o_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function a_(t,e,n){var r=Kx.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function s_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function u_(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function l_(t,e,n){var r=Kx.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function c_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function f_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function h_(t,e,n){var r=Kx.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function d_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function p_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function m_(t,e,n){var r=Kx.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function g_(t,e,n){var r=Kx.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function y_(t,e,n){var r=Kx.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function v_(t,e,n){var r=Qx.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function x_(t,e,n){var r=Kx.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function __(t,e,n){var r=Kx.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function b_(t,e){return $x(t.getDate(),e,2)}function w_(t,e){return $x(t.getHours(),e,2)}function M_(t,e){return $x(t.getHours()%12||12,e,2)}function A_(t,e){return $x(1+Gv.count(Sx(t),t),e,3)}function T_(t,e){return $x(t.getMilliseconds(),e,3)}function E_(t,e){return T_(t,e)+"000"}function C_(t,e){return $x(t.getMonth()+1,e,2)}function k_(t,e){return $x(t.getMinutes(),e,2)}function S_(t,e){return $x(t.getSeconds(),e,2)}function O_(t){var e=t.getDay();return 0===e?7:e}function P_(t,e){return $x(Yv.count(Sx(t)-1,t),e,2)}function L_(t){var e=t.getDay();return e>=4||0===e?tx(t):tx.ceil(t)}function R_(t,e){return t=L_(t),$x(tx.count(Sx(t),t)+(4===Sx(t).getDay()),e,2)}function I_(t){return t.getDay()}function D_(t,e){return $x($v.count(Sx(t)-1,t),e,2)}function N_(t,e){return $x(t.getFullYear()%100,e,2)}function F_(t,e){return $x((t=L_(t)).getFullYear()%100,e,2)}function j_(t,e){return $x(t.getFullYear()%1e4,e,4)}function z_(t,e){var n=t.getDay();return $x((t=n>=4||0===n?tx(t):tx.ceil(t)).getFullYear()%1e4,e,4)}function B_(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+$x(e/60|0,"0",2)+$x(e%60,"0",2)}function V_(t,e){return $x(t.getUTCDate(),e,2)}function q_(t,e){return $x(t.getUTCHours(),e,2)}function G_(t,e){return $x(t.getUTCHours()%12||12,e,2)}function U_(t,e){return $x(1+Hv.count(Px(t),t),e,3)}function H_(t,e){return $x(t.getUTCMilliseconds(),e,3)}function W_(t,e){return H_(t,e)+"000"}function X_(t,e){return $x(t.getUTCMonth()+1,e,2)}function K_(t,e){return $x(t.getUTCMinutes(),e,2)}function Q_(t,e){return $x(t.getUTCSeconds(),e,2)}function Y_(t){var e=t.getUTCDay();return 0===e?7:e}function $_(t,e){return $x(fx.count(Px(t)-1,t),e,2)}function Z_(t){var e=t.getUTCDay();return e>=4||0===e?mx(t):mx.ceil(t)}function J_(t,e){return t=Z_(t),$x(mx.count(Px(t),t)+(4===Px(t).getUTCDay()),e,2)}function tb(t){return t.getUTCDay()}function eb(t,e){return $x(hx.count(Px(t)-1,t),e,2)}function nb(t,e){return $x(t.getUTCFullYear()%100,e,2)}function rb(t,e){return $x((t=Z_(t)).getUTCFullYear()%100,e,2)}function ib(t,e){return $x(t.getUTCFullYear()%1e4,e,4)}function ob(t,e){var n=t.getUTCDay();return $x((t=n>=4||0===n?mx(t):mx.ceil(t)).getUTCFullYear()%1e4,e,4)}function ab(){return"+0000"}function sb(){return"%"}function ub(t){return+t}function lb(t){return Math.floor(+t/1e3)}function cb(t){return qx=Vx(t),Gx=qx.format,Ux=qx.parse,Hx=qx.utcFormat,Wx=qx.utcParse,qx}function fb(t){return new Date(t)}function hb(t){return t instanceof Date?+t:+new Date(+t)}function db(t,e,n,r,i,o,a,s,u,l){var c=Wy(),f=c.invert,h=c.domain,d=l(".%L"),p=l(":%S"),m=l("%I:%M"),g=l("%I %p"),y=l("%a %d"),v=l("%b %d"),x=l("%B"),_=l("%Y");function b(t){return(u(t)<t?d:s(t)<t?p:a(t)<t?m:o(t)<t?g:r(t)<t?i(t)<t?y:v:n(t)<t?x:_)(t)}return c.invert=function(t){return new Date(f(t))},c.domain=function(t){return arguments.length?h(Array.from(t,hb)):h().map(fb)},c.ticks=function(e){var n=h();return t(n[0],n[n.length-1],null==e?10:e)},c.tickFormat=function(t,e){return null==e?b:l(e)},c.nice=function(t){var n=h();return t&&"function"==typeof t.range||(t=e(n[0],n[n.length-1],null==t?10:t)),t?h($y(n,t)):c},c.copy=function(){return Uy(c,db(t,e,n,r,i,o,a,s,u,l))},c}function pb(){return Py.apply(db(Nx,Fx,Sx,Tx,Yv,Gv,zv,Dv,Rv,Gx).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function mb(){return Py.apply(db(Ix,Dx,Px,Cx,fx,Hv,Vv,Fv,Rv,Hx).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function gb(){var t,e,n,r,i,o=0,a=1,s=By,u=!1;function l(e){return null==e||isNaN(e=+e)?i:s(0===n?.5:(e=(r(e)-t)*n,u?Math.max(0,Math.min(1,e)):e))}function c(t){return function(e){var n,r;return arguments.length?([n,r]=e,s=t(n,r),l):[s(0),s(1)]}}return l.domain=function(i){return arguments.length?([o,a]=i,t=r(o=+o),e=r(a=+a),n=t===e?0:1/(e-t),l):[o,a]},l.clamp=function(t){return arguments.length?(u=!!t,l):u},l.interpolator=function(t){return arguments.length?(s=t,l):s},l.range=c(Zr),l.rangeRound=c(Bg),l.unknown=function(t){return arguments.length?(i=t,l):i},function(i){return r=i,t=i(o),e=i(a),n=t===e?0:1/(e-t),l}}function yb(t,e){return e.domain(t.domain()).interpolator(t.interpolator()).clamp(t.clamp()).unknown(t.unknown())}function vb(){var t=Ky(gb()(By));return t.copy=function(){return yb(t,vb())},Ly.apply(t,arguments)}function xb(){var t=iv(gb()).domain([1,10]);return t.copy=function(){return yb(t,xb()).base(t.base())},Ly.apply(t,arguments)}function _b(){var t=uv(gb());return t.copy=function(){return yb(t,_b()).constant(t.constant())},Ly.apply(t,arguments)}function bb(){var t=dv(gb());return t.copy=function(){return yb(t,bb()).exponent(t.exponent())},Ly.apply(t,arguments)}function wb(){return bb.apply(null,arguments).exponent(.5)}function Mb(){var t=[],e=By;function n(n){if(null!=n&&!isNaN(n=+n))return e((h(t,n,1)-1)/(t.length-1))}return n.domain=function(e){if(!arguments.length)return t.slice();t=[];for(let n of e)null==n||isNaN(n=+n)||t.push(n);return t.sort(r),n},n.interpolator=function(t){return arguments.length?(e=t,n):e},n.range=function(){return t.map(((n,r)=>e(r/(t.length-1))))},n.quantiles=function(e){return Array.from({length:e+1},((n,r)=>bt(t,r/e)))},n.copy=function(){return Mb(e).domain(t)},Ly.apply(n,arguments)}function Ab(){var t,e,n,r,i,o,a,s=0,u=.5,l=1,c=1,f=By,h=!1;function d(t){return isNaN(t=+t)?a:(t=.5+((t=+o(t))-e)*(c*t<c*e?r:i),f(h?Math.max(0,Math.min(1,t)):t))}function p(t){return function(e){var n,r,i;return arguments.length?([n,r,i]=e,f=Jg(t,[n,r,i]),d):[f(0),f(.5),f(1)]}}return d.domain=function(a){return arguments.length?([s,u,l]=a,t=o(s=+s),e=o(u=+u),n=o(l=+l),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),c=e<t?-1:1,d):[s,u,l]},d.clamp=function(t){return arguments.length?(h=!!t,d):h},d.interpolator=function(t){return arguments.length?(f=t,d):f},d.range=p(Zr),d.rangeRound=p(Bg),d.unknown=function(t){return arguments.length?(a=t,d):a},function(a){return o=a,t=a(s),e=a(u),n=a(l),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),c=e<t?-1:1,d}}function Tb(){var t=Ky(Ab()(By));return t.copy=function(){return yb(t,Tb())},Ly.apply(t,arguments)}function Eb(){var t=iv(Ab()).domain([.1,1,10]);return t.copy=function(){return yb(t,Eb()).base(t.base())},Ly.apply(t,arguments)}function Cb(){var t=uv(Ab());return t.copy=function(){return yb(t,Cb()).constant(t.constant())},Ly.apply(t,arguments)}function kb(){var t=dv(Ab());return t.copy=function(){return yb(t,kb()).exponent(t.exponent())},Ly.apply(t,arguments)}function Sb(){return kb.apply(null,arguments).exponent(.5)}function Ob(t){for(var e=t.length/6|0,n=new Array(e),r=0;r<e;)n[r]="#"+t.slice(6*r,6*++r);return n}cb({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var Pb=Ob("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),Lb=Ob("7fc97fbeaed4fdc086ffff99386cb0f0027fbf5b17666666"),Rb=Ob("1b9e77d95f027570b3e7298a66a61ee6ab02a6761d666666"),Ib=Ob("4269d0efb118ff725c6cc5b03ca951ff8ab7a463f297bbf59c6b4e9498a0"),Db=Ob("a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928"),Nb=Ob("fbb4aeb3cde3ccebc5decbe4fed9a6ffffcce5d8bdfddaecf2f2f2"),Fb=Ob("b3e2cdfdcdaccbd5e8f4cae4e6f5c9fff2aef1e2cccccccc"),jb=Ob("e41a1c377eb84daf4a984ea3ff7f00ffff33a65628f781bf999999"),zb=Ob("66c2a5fc8d628da0cbe78ac3a6d854ffd92fe5c494b3b3b3"),Bb=Ob("8dd3c7ffffb3bebadafb807280b1d3fdb462b3de69fccde5d9d9d9bc80bdccebc5ffed6f"),Vb=Ob("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab"),qb=t=>Br(t[t.length-1]),Gb=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(Ob),Ub=qb(Gb),Hb=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(Ob),Wb=qb(Hb),Xb=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(Ob),Kb=qb(Xb),Qb=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(Ob),Yb=qb(Qb),$b=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(Ob),Zb=qb($b),Jb=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(Ob),tw=qb(Jb),ew=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(Ob),nw=qb(ew),rw=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(Ob),iw=qb(rw),ow=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(Ob),aw=qb(ow),sw=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(Ob),uw=qb(sw),lw=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(Ob),cw=qb(lw),fw=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(Ob),hw=qb(fw),dw=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(Ob),pw=qb(dw),mw=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(Ob),gw=qb(mw),yw=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(Ob),vw=qb(yw),xw=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(Ob),_w=qb(xw),bw=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(Ob),ww=qb(bw),Mw=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(Ob),Aw=qb(Mw),Tw=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(Ob),Ew=qb(Tw),Cw=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(Ob),kw=qb(Cw),Sw=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(Ob),Ow=qb(Sw),Pw=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(Ob),Lw=qb(Pw),Rw=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(Ob),Iw=qb(Rw),Dw=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(Ob),Nw=qb(Dw),Fw=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(Ob),jw=qb(Fw),zw=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(Ob),Bw=qb(zw),Vw=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(Ob),qw=qb(Vw);function Gw(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(-4.54-t*(35.34-t*(2381.73-t*(6402.7-t*(7024.72-2710.57*t)))))))+", "+Math.max(0,Math.min(255,Math.round(32.49+t*(170.73+t*(52.82-t*(131.46-t*(176.58-67.37*t)))))))+", "+Math.max(0,Math.min(255,Math.round(81.24+t*(442.36-t*(2482.43-t*(6167.24-t*(6614.94-2475.67*t)))))))+")"}var Uw=Zg(ts(300,.5,0),ts(-240,.5,1)),Hw=Zg(ts(-100,.75,.35),ts(80,1.5,.8)),Ww=Zg(ts(260,.75,.35),ts(80,1.5,.8)),Xw=ts();function Kw(t){(t<0||t>1)&&(t-=Math.floor(t));var e=Math.abs(t-.5);return Xw.h=360*t-100,Xw.s=1.5-1.5*e,Xw.l=.8-.9*e,Xw+""}var Qw=gr(),Yw=Math.PI/3,$w=2*Math.PI/3;function Zw(t){var e;return t=(.5-t)*Math.PI,Qw.r=255*(e=Math.sin(t))*e,Qw.g=255*(e=Math.sin(t+Yw))*e,Qw.b=255*(e=Math.sin(t+$w))*e,Qw+""}function Jw(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+t*(1172.33-t*(10793.56-t*(33300.12-t*(38394.49-14825.05*t)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+t*(557.33+t*(1225.33-t*(3574.96-t*(1073.77+707.56*t)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+t*(3211.1-t*(15327.97-t*(27814-t*(22569.18-6838.66*t)))))))+")"}function tM(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}var eM=tM(Ob("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725")),nM=tM(Ob("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),rM=tM(Ob("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),iM=tM(Ob("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921"));function oM(t){return Vn(Cn(t).call(document.documentElement))}var aM=0;function sM(){return new uM}function uM(){this._="@"+(++aM).toString(36)}function lM(t,e){return t.target&&(t=Jr(t),void 0===e&&(e=t.currentTarget),t=t.touches||[t]),Array.from(t,(t=>ti(t,e)))}function cM(t){return"string"==typeof t?new jn([document.querySelectorAll(t)],[document.documentElement]):new jn([Se(t)],Fn)}function fM(t){return function(){return t}}uM.prototype=sM.prototype={constructor:uM,get:function(t){for(var e=this._;!(e in t);)if(!(t=t.parentNode))return;return t[e]},set:function(t,e){return t[this._]=e},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};const hM=Math.abs,dM=Math.atan2,pM=Math.cos,mM=Math.max,gM=Math.min,yM=Math.sin,vM=Math.sqrt,xM=1e-12,_M=Math.PI,bM=_M/2,wM=2*_M;function MM(t){return t>=1?bM:t<=-1?-bM:Math.asin(t)}function AM(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(null==n)e=null;else{const t=Math.floor(n);if(!(t>=0))throw new RangeError(`invalid digits: ${n}`);e=t}return t},()=>new la(e)}function TM(t){return t.innerRadius}function EM(t){return t.outerRadius}function CM(t){return t.startAngle}function kM(t){return t.endAngle}function SM(t){return t&&t.padAngle}function OM(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/vM(s*s+u*u),c=l*u,f=-l*s,h=t+c,d=e+f,p=n+c,m=r+f,g=(h+p)/2,y=(d+m)/2,v=p-h,x=m-d,_=v*v+x*x,b=i-o,w=h*m-p*d,M=(x<0?-1:1)*vM(mM(0,b*b*_-w*w)),A=(w*x-v*M)/_,T=(-w*v-x*M)/_,E=(w*x+v*M)/_,C=(-w*v+x*M)/_,k=A-g,S=T-y,O=E-g,P=C-y;return k*k+S*S>O*O+P*P&&(A=E,T=C),{cx:A,cy:T,x01:-c,y01:-f,x11:A*(i/b-1),y11:T*(i/b-1)}}function PM(){var t=TM,e=EM,n=fM(0),r=null,i=CM,o=kM,a=SM,s=null,u=AM(l);function l(){var l,c,f=+t.apply(this,arguments),h=+e.apply(this,arguments),d=i.apply(this,arguments)-bM,p=o.apply(this,arguments)-bM,m=hM(p-d),g=p>d;if(s||(s=l=u()),h<f&&(c=h,h=f,f=c),h>xM)if(m>wM-xM)s.moveTo(h*pM(d),h*yM(d)),s.arc(0,0,h,d,p,!g),f>xM&&(s.moveTo(f*pM(p),f*yM(p)),s.arc(0,0,f,p,d,g));else{var y,v,x=d,_=p,b=d,w=p,M=m,A=m,T=a.apply(this,arguments)/2,E=T>xM&&(r?+r.apply(this,arguments):vM(f*f+h*h)),C=gM(hM(h-f)/2,+n.apply(this,arguments)),k=C,S=C;if(E>xM){var O=MM(E/f*yM(T)),P=MM(E/h*yM(T));(M-=2*O)>xM?(b+=O*=g?1:-1,w-=O):(M=0,b=w=(d+p)/2),(A-=2*P)>xM?(x+=P*=g?1:-1,_-=P):(A=0,x=_=(d+p)/2)}var L=h*pM(x),R=h*yM(x),I=f*pM(w),D=f*yM(w);if(C>xM){var N,F=h*pM(_),j=h*yM(_),z=f*pM(b),B=f*yM(b);if(m<_M)if(N=function(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,f=s-o,h=f*u-c*l;if(!(h*h<xM))return[t+(h=(c*(e-o)-f*(t-i))/h)*u,e+h*l]}(L,R,z,B,F,j,I,D)){var V=L-N[0],q=R-N[1],G=F-N[0],U=j-N[1],H=1/yM(function(t){return t>1?0:t<-1?_M:Math.acos(t)}((V*G+q*U)/(vM(V*V+q*q)*vM(G*G+U*U)))/2),W=vM(N[0]*N[0]+N[1]*N[1]);k=gM(C,(f-W)/(H-1)),S=gM(C,(h-W)/(H+1))}else k=S=0}A>xM?S>xM?(y=OM(z,B,L,R,h,S,g),v=OM(F,j,I,D,h,S,g),s.moveTo(y.cx+y.x01,y.cy+y.y01),S<C?s.arc(y.cx,y.cy,S,dM(y.y01,y.x01),dM(v.y01,v.x01),!g):(s.arc(y.cx,y.cy,S,dM(y.y01,y.x01),dM(y.y11,y.x11),!g),s.arc(0,0,h,dM(y.cy+y.y11,y.cx+y.x11),dM(v.cy+v.y11,v.cx+v.x11),!g),s.arc(v.cx,v.cy,S,dM(v.y11,v.x11),dM(v.y01,v.x01),!g))):(s.moveTo(L,R),s.arc(0,0,h,x,_,!g)):s.moveTo(L,R),f>xM&&M>xM?k>xM?(y=OM(I,D,F,j,f,-k,g),v=OM(L,R,z,B,f,-k,g),s.lineTo(y.cx+y.x01,y.cy+y.y01),k<C?s.arc(y.cx,y.cy,k,dM(y.y01,y.x01),dM(v.y01,v.x01),!g):(s.arc(y.cx,y.cy,k,dM(y.y01,y.x01),dM(y.y11,y.x11),!g),s.arc(0,0,f,dM(y.cy+y.y11,y.cx+y.x11),dM(v.cy+v.y11,v.cx+v.x11),g),s.arc(v.cx,v.cy,k,dM(v.y11,v.x11),dM(v.y01,v.x01),!g))):s.arc(0,0,f,w,b,g):s.lineTo(I,D)}else s.moveTo(0,0);if(s.closePath(),l)return s=null,l+""||null}return l.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-_M/2;return[pM(r)*n,yM(r)*n]},l.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),l):t},l.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),l):e},l.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:fM(+t),l):n},l.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:fM(+t),l):r},l.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),l):i},l.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:fM(+t),l):o},l.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:fM(+t),l):a},l.context=function(t){return arguments.length?(s=null==t?null:t,l):s},l}var LM=Array.prototype.slice;function RM(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function IM(t){this._context=t}function DM(t){return new IM(t)}function NM(t){return t[0]}function FM(t){return t[1]}function jM(t,e){var n=fM(!0),r=null,i=DM,o=null,a=AM(s);function s(s){var u,l,c,f=(s=RM(s)).length,h=!1;for(null==r&&(o=i(c=a())),u=0;u<=f;++u)!(u<f&&n(l=s[u],u,s))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+t(l,u,s),+e(l,u,s));if(c)return o=null,c+""||null}return t="function"==typeof t?t:void 0===t?NM:fM(t),e="function"==typeof e?e:void 0===e?FM:fM(e),s.x=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),s):t},s.y=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),s):e},s.defined=function(t){return arguments.length?(n="function"==typeof t?t:fM(!!t),s):n},s.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),s):i},s.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),s):r},s}function zM(t,e,n){var r=null,i=fM(!0),o=null,a=DM,s=null,u=AM(l);function l(l){var c,f,h,d,p,m=(l=RM(l)).length,g=!1,y=new Array(m),v=new Array(m);for(null==o&&(s=a(p=u())),c=0;c<=m;++c){if(!(c<m&&i(d=l[c],c,l))===g)if(g=!g)f=c,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),h=c-1;h>=f;--h)s.point(y[h],v[h]);s.lineEnd(),s.areaEnd()}g&&(y[c]=+t(d,c,l),v[c]=+e(d,c,l),s.point(r?+r(d,c,l):y[c],n?+n(d,c,l):v[c]))}if(p)return s=null,p+""||null}function c(){return jM().defined(i).curve(a).context(o)}return t="function"==typeof t?t:void 0===t?NM:fM(+t),e="function"==typeof e?e:fM(void 0===e?0:+e),n="function"==typeof n?n:void 0===n?FM:fM(+n),l.x=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),r=null,l):t},l.x0=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),l):t},l.x1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:fM(+t),l):r},l.y=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),n=null,l):e},l.y0=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),l):e},l.y1=function(t){return arguments.length?(n=null==t?null:"function"==typeof t?t:fM(+t),l):n},l.lineX0=l.lineY0=function(){return c().x(t).y(e)},l.lineY1=function(){return c().x(t).y(n)},l.lineX1=function(){return c().x(r).y(e)},l.defined=function(t){return arguments.length?(i="function"==typeof t?t:fM(!!t),l):i},l.curve=function(t){return arguments.length?(a=t,null!=o&&(s=a(o)),l):a},l.context=function(t){return arguments.length?(null==t?o=s=null:s=a(o=t),l):o},l}function BM(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function VM(t){return t}function qM(){var t=VM,e=BM,n=null,r=fM(0),i=fM(wM),o=fM(0);function a(a){var s,u,l,c,f,h=(a=RM(a)).length,d=0,p=new Array(h),m=new Array(h),g=+r.apply(this,arguments),y=Math.min(wM,Math.max(-wM,i.apply(this,arguments)-g)),v=Math.min(Math.abs(y)/h,o.apply(this,arguments)),x=v*(y<0?-1:1);for(s=0;s<h;++s)(f=m[p[s]=s]=+t(a[s],s,a))>0&&(d+=f);for(null!=e?p.sort((function(t,n){return e(m[t],m[n])})):null!=n&&p.sort((function(t,e){return n(a[t],a[e])})),s=0,l=d?(y-h*x)/d:0;s<h;++s,g=c)u=p[s],c=g+((f=m[u])>0?f*l:0)+x,m[u]={data:a[u],index:s,value:f,startAngle:g,endAngle:c,padAngle:v};return m}return a.value=function(e){return arguments.length?(t="function"==typeof e?e:fM(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:fM(+t),a):o},a}IM.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var GM=HM(DM);function UM(t){this._curve=t}function HM(t){function e(e){return new UM(t(e))}return e._curve=t,e}function WM(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(HM(t)):e()._curve},t}function XM(){return WM(jM().curve(GM))}function KM(){var t=zM().curve(GM),e=t.curve,n=t.lineX0,r=t.lineX1,i=t.lineY0,o=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return WM(n())},delete t.lineX0,t.lineEndAngle=function(){return WM(r())},delete t.lineX1,t.lineInnerRadius=function(){return WM(i())},delete t.lineY0,t.lineOuterRadius=function(){return WM(o())},delete t.lineY1,t.curve=function(t){return arguments.length?e(HM(t)):e()._curve},t}function QM(t,e){return[(e=+e)*Math.cos(t-=Math.PI/2),e*Math.sin(t)]}UM.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};class YM{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e)}this._x0=t,this._y0=e}}class $M{constructor(t){this._context=t}lineStart(){this._point=0}lineEnd(){}point(t,e){if(t=+t,e=+e,0===this._point)this._point=1;else{const n=QM(this._x0,this._y0),r=QM(this._x0,this._y0=(this._y0+e)/2),i=QM(t,this._y0),o=QM(t,e);this._context.moveTo(...n),this._context.bezierCurveTo(...r,...i,...o)}this._x0=t,this._y0=e}}function ZM(t){return new YM(t,!0)}function JM(t){return new YM(t,!1)}function tA(t){return new $M(t)}function eA(t){return t.source}function nA(t){return t.target}function rA(t){let e=eA,n=nA,r=NM,i=FM,o=null,a=null,s=AM(u);function u(){let u;const l=LM.call(arguments),c=e.apply(this,l),f=n.apply(this,l);if(null==o&&(a=t(u=s())),a.lineStart(),l[0]=c,a.point(+r.apply(this,l),+i.apply(this,l)),l[0]=f,a.point(+r.apply(this,l),+i.apply(this,l)),a.lineEnd(),u)return a=null,u+""||null}return u.source=function(t){return arguments.length?(e=t,u):e},u.target=function(t){return arguments.length?(n=t,u):n},u.x=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),u):r},u.y=function(t){return arguments.length?(i="function"==typeof t?t:fM(+t),u):i},u.context=function(e){return arguments.length?(null==e?o=a=null:a=t(o=e),u):o},u}function iA(){return rA(ZM)}function oA(){return rA(JM)}function aA(){const t=rA(tA);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t}const sA=vM(3);var uA={draw(t,e){const n=.59436*vM(e+gM(e/28,.75)),r=n/2,i=r*sA;t.moveTo(0,n),t.lineTo(0,-n),t.moveTo(-i,-r),t.lineTo(i,r),t.moveTo(-i,r),t.lineTo(i,-r)}},lA={draw(t,e){const n=vM(e/_M);t.moveTo(n,0),t.arc(0,0,n,0,wM)}},cA={draw(t,e){const n=vM(e/5)/2;t.moveTo(-3*n,-n),t.lineTo(-n,-n),t.lineTo(-n,-3*n),t.lineTo(n,-3*n),t.lineTo(n,-n),t.lineTo(3*n,-n),t.lineTo(3*n,n),t.lineTo(n,n),t.lineTo(n,3*n),t.lineTo(-n,3*n),t.lineTo(-n,n),t.lineTo(-3*n,n),t.closePath()}};const fA=vM(1/3),hA=2*fA;var dA={draw(t,e){const n=vM(e/hA),r=n*fA;t.moveTo(0,-n),t.lineTo(r,0),t.lineTo(0,n),t.lineTo(-r,0),t.closePath()}},pA={draw(t,e){const n=.62625*vM(e);t.moveTo(0,-n),t.lineTo(n,0),t.lineTo(0,n),t.lineTo(-n,0),t.closePath()}},mA={draw(t,e){const n=.87559*vM(e-gM(e/7,2));t.moveTo(-n,0),t.lineTo(n,0),t.moveTo(0,n),t.lineTo(0,-n)}},gA={draw(t,e){const n=vM(e),r=-n/2;t.rect(r,r,n,n)}},yA={draw(t,e){const n=.4431*vM(e);t.moveTo(n,n),t.lineTo(n,-n),t.lineTo(-n,-n),t.lineTo(-n,n),t.closePath()}};const vA=yM(_M/10)/yM(7*_M/10),xA=yM(wM/10)*vA,_A=-pM(wM/10)*vA;var bA={draw(t,e){const n=vM(.8908130915292852*e),r=xA*n,i=_A*n;t.moveTo(0,-n),t.lineTo(r,i);for(let e=1;e<5;++e){const o=wM*e/5,a=pM(o),s=yM(o);t.lineTo(s*n,-a*n),t.lineTo(a*r-s*i,s*r+a*i)}t.closePath()}};const wA=vM(3);var MA={draw(t,e){const n=-vM(e/(3*wA));t.moveTo(0,2*n),t.lineTo(-wA*n,-n),t.lineTo(wA*n,-n),t.closePath()}};const AA=vM(3);var TA={draw(t,e){const n=.6824*vM(e),r=n/2,i=n*AA/2;t.moveTo(0,-n),t.lineTo(i,r),t.lineTo(-i,r),t.closePath()}};const EA=-.5,CA=vM(3)/2,kA=1/vM(12),SA=3*(kA/2+1);var OA={draw(t,e){const n=vM(e/SA),r=n/2,i=n*kA,o=r,a=n*kA+n,s=-o,u=a;t.moveTo(r,i),t.lineTo(o,a),t.lineTo(s,u),t.lineTo(EA*r-CA*i,CA*r+EA*i),t.lineTo(EA*o-CA*a,CA*o+EA*a),t.lineTo(EA*s-CA*u,CA*s+EA*u),t.lineTo(EA*r+CA*i,EA*i-CA*r),t.lineTo(EA*o+CA*a,EA*a-CA*o),t.lineTo(EA*s+CA*u,EA*u-CA*s),t.closePath()}},PA={draw(t,e){const n=.6189*vM(e-gM(e/6,1.7));t.moveTo(-n,-n),t.lineTo(n,n),t.moveTo(-n,n),t.lineTo(n,-n)}};const LA=[lA,cA,dA,gA,bA,MA,OA],RA=[lA,mA,PA,TA,uA,yA,pA];function IA(t,e){let n=null,r=AM(i);function i(){let i;if(n||(n=i=r()),t.apply(this,arguments).draw(n,+e.apply(this,arguments)),i)return n=null,i+""||null}return t="function"==typeof t?t:fM(t||lA),e="function"==typeof e?e:fM(void 0===e?64:+e),i.type=function(e){return arguments.length?(t="function"==typeof e?e:fM(e),i):t},i.size=function(t){return arguments.length?(e="function"==typeof t?t:fM(+t),i):e},i.context=function(t){return arguments.length?(n=null==t?null:t,i):n},i}function DA(){}function NA(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function FA(t){this._context=t}function jA(t){return new FA(t)}function zA(t){this._context=t}function BA(t){return new zA(t)}function VA(t){this._context=t}function qA(t){return new VA(t)}function GA(t,e){this._basis=new FA(t),this._beta=e}FA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:NA(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},zA.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},VA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:NA(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},GA.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var UA=function t(e){function n(t){return 1===e?new FA(t):new GA(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function HA(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function WA(t,e){this._context=t,this._k=(1-e)/6}WA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:HA(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var XA=function t(e){function n(t){return new WA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function KA(t,e){this._context=t,this._k=(1-e)/6}KA.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var QA=function t(e){function n(t){return new KA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function YA(t,e){this._context=t,this._k=(1-e)/6}YA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:HA(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var $A=function t(e){function n(t){return new YA(t,e)}return n.tension=function(e){return t(+e)},n}(0);function ZA(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>xM){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>xM){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/c,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/c}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function JA(t,e){this._context=t,this._alpha=e}JA.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var tT=function t(e){function n(t){return e?new JA(t,e):new WA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function eT(t,e){this._context=t,this._alpha=e}eT.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var nT=function t(e){function n(t){return e?new eT(t,e):new KA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function rT(t,e){this._context=t,this._alpha=e}rT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ZA(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var iT=function t(e){function n(t){return e?new rT(t,e):new YA(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function oT(t){this._context=t}function aT(t){return new oT(t)}function sT(t){return t<0?-1:1}function uT(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(sT(o)+sT(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function lT(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function cT(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function fT(t){this._context=t}function hT(t){this._context=new dT(t)}function dT(t){this._context=t}function pT(t){return new fT(t)}function mT(t){return new hT(t)}function gT(t){this._context=t}function yT(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}function vT(t){return new gT(t)}function xT(t,e){this._context=t,this._t=e}function _T(t){return new xT(t,.5)}function bT(t){return new xT(t,0)}function wT(t){return new xT(t,1)}function MT(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]}function AT(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function TT(t,e){return t[e]}function ET(t){const e=[];return e.key=t,e}function CT(){var t=fM([]),e=AT,n=MT,r=TT;function i(i){var o,a,s=Array.from(t.apply(this,arguments),ET),u=s.length,l=-1;for(const t of i)for(o=0,++l;o<u;++o)(s[o][l]=[0,+r(t,s[o].key,l,i)]).data=t;for(o=0,a=RM(e(s));o<u;++o)s[a[o]].index=o;return n(s,a),s}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:fM(Array.from(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:fM(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?AT:"function"==typeof t?t:fM(Array.from(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?MT:t,i):n},i}function kT(t,e){if((r=t.length)>0){for(var n,r,i,o=0,a=t[0].length;o<a;++o){for(i=n=0;n<r;++n)i+=t[n][o][1]||0;if(i)for(n=0;n<r;++n)t[n][o][1]/=i}MT(t,e)}}function ST(t,e){if((s=t.length)>0)for(var n,r,i,o,a,s,u=0,l=t[e[0]].length;u<l;++u)for(o=a=0,n=0;n<s;++n)(i=(r=t[e[n]][u])[1]-r[0])>0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=a,r[0]=a+=i):(r[0]=0,r[1]=i)}function OT(t,e){if((n=t.length)>0){for(var n,r=0,i=t[e[0]],o=i.length;r<o;++r){for(var a=0,s=0;a<n;++a)s+=t[a][r][1]||0;i[r][1]+=i[r][0]=-s/2}MT(t,e)}}function PT(t,e){if((i=t.length)>0&&(r=(n=t[e[0]]).length)>0){for(var n,r,i,o=0,a=1;a<r;++a){for(var s=0,u=0,l=0;s<i;++s){for(var c=t[e[s]],f=c[a][1]||0,h=(f-(c[a-1][1]||0))/2,d=0;d<s;++d){var p=t[e[d]];h+=(p[a][1]||0)-(p[a-1][1]||0)}u+=f,l+=h*f}n[a-1][1]+=n[a-1][0]=o,u&&(o-=l/u)}n[a-1][1]+=n[a-1][0]=o,MT(t,e)}}function LT(t){var e=t.map(RT);return AT(t).sort((function(t,n){return e[t]-e[n]}))}function RT(t){for(var e,n=-1,r=0,i=t.length,o=-1/0;++n<i;)(e=+t[n][1])>o&&(o=e,r=n);return r}function IT(t){var e=t.map(DT);return AT(t).sort((function(t,n){return e[t]-e[n]}))}function DT(t){for(var e,n=0,r=-1,i=t.length;++r<i;)(e=+t[r][1])&&(n+=e);return n}function NT(t){return IT(t).reverse()}function FT(t){var e,n,r=t.length,i=t.map(DT),o=LT(t),a=0,s=0,u=[],l=[];for(e=0;e<r;++e)n=o[e],a<s?(a+=i[n],u.push(n)):(s+=i[n],l.push(n));return l.reverse().concat(u)}function jT(t){return AT(t).reverse()}oT.prototype={areaStart:DA,areaEnd:DA,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}},fT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:cT(this,this._t0,lT(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,cT(this,lT(this,n=uT(this,t,e)),n);break;default:cT(this,this._t0,n=uT(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(hT.prototype=Object.create(fT.prototype)).point=function(t,e){fT.prototype.point.call(this,e,t)},dT.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},gT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=yT(t),i=yT(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}},xT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var zT="%Y-%m-%dT%H:%M:%S.%LZ";var BT=Date.prototype.toISOString?function(t){return t.toISOString()}:Hx(zT),VT=BT;var qT=+new Date("2000-01-01T00:00:00.000Z")?function(t){var e=new Date(t);return isNaN(e)?null:e}:Wx(zT),GT=qT;function UT(t,e,n){var r=new di,i=e;return null==e?(r.restart(t,e,n),r):(r._restart=r.restart,r.restart=function(t,e,n){e=+e,n=null==n?fi():+n,r._restart((function o(a){a+=i,r._restart(o,i+=e,n),t(a)}),e,n)},r.restart(t,e,n),r)}var HT=t=>()=>t;function WT(t,{sourceEvent:e,target:n,transform:r,dispatch:i}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:e,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:i}})}function XT(t,e,n){this.k=t,this.x=e,this.y=n}XT.prototype={constructor:XT,scale:function(t){return 1===t?this:new XT(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new XT(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var KT=new XT(1,0,0);function QT(t){for(;!t.__zoom;)if(!(t=t.parentNode))return KT;return t.__zoom}function YT(t){t.stopImmediatePropagation()}function $T(t){t.preventDefault(),t.stopImmediatePropagation()}function ZT(t){return!(t.ctrlKey&&"wheel"!==t.type||t.button)}function JT(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t).hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]:[[0,0],[t.clientWidth,t.clientHeight]]}function tE(){return this.__zoom||KT}function eE(t){return-t.deltaY*(1===t.deltaMode?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function nE(){return navigator.maxTouchPoints||"ontouchstart"in this}function rE(t,e,n){var r=t.invertX(e[0][0])-n[0][0],i=t.invertX(e[1][0])-n[1][0],o=t.invertY(e[0][1])-n[0][1],a=t.invertY(e[1][1])-n[1][1];return t.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),a>o?(o+a)/2:Math.min(0,o)||Math.max(0,a))}function iE(){var t,e,n,r=ZT,i=JT,o=rE,a=eE,s=nE,u=[0,1/0],l=[[-1/0,-1/0],[1/0,1/0]],c=250,f=qg,h=Ee("start","zoom","end"),d=0,p=10;function m(t){t.property("__zoom",tE).on("wheel.zoom",w,{passive:!1}).on("mousedown.zoom",M).on("dblclick.zoom",A).filter(s).on("touchstart.zoom",T).on("touchmove.zoom",E).on("touchend.zoom touchcancel.zoom",C).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(t,e){return(e=Math.max(u[0],Math.min(u[1],e)))===t.k?t:new XT(e,t.x,t.y)}function y(t,e,n){var r=e[0]-n[0]*t.k,i=e[1]-n[1]*t.k;return r===t.x&&i===t.y?t:new XT(t.k,r,i)}function v(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function x(t,e,n,r){t.on("start.zoom",(function(){_(this,arguments).event(r).start()})).on("interrupt.zoom end.zoom",(function(){_(this,arguments).event(r).end()})).tween("zoom",(function(){var t=this,o=arguments,a=_(t,o).event(r),s=i.apply(t,o),u=null==n?v(s):"function"==typeof n?n.apply(t,o):n,l=Math.max(s[1][0]-s[0][0],s[1][1]-s[0][1]),c=t.__zoom,h="function"==typeof e?e.apply(t,o):e,d=f(c.invert(u).concat(l/c.k),h.invert(u).concat(l/h.k));return function(t){if(1===t)t=h;else{var e=d(t),n=l/e[2];t=new XT(n,u[0]-e[0]*n,u[1]-e[1]*n)}a.zoom(null,t)}}))}function _(t,e,n){return!n&&t.__zooming||new b(t,e)}function b(t,e){this.that=t,this.args=e,this.active=0,this.sourceEvent=null,this.extent=i.apply(t,e),this.taps=0}function w(t,...e){if(r.apply(this,arguments)){var n=_(this,e).event(t),i=this.__zoom,s=Math.max(u[0],Math.min(u[1],i.k*Math.pow(2,a.apply(this,arguments)))),c=ti(t);if(n.wheel)n.mouse[0][0]===c[0]&&n.mouse[0][1]===c[1]||(n.mouse[1]=i.invert(n.mouse[0]=c)),clearTimeout(n.wheel);else{if(i.k===s)return;n.mouse=[c,i.invert(c)],Oi(this),n.start()}$T(t),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),150),n.zoom("mouse",o(y(g(i,s),n.mouse[0],n.mouse[1]),n.extent,l))}}function M(t,...e){if(!n&&r.apply(this,arguments)){var i=t.currentTarget,a=_(this,e,!0).event(t),s=Vn(t.view).on("mousemove.zoom",(function(t){if($T(t),!a.moved){var e=t.clientX-c,n=t.clientY-f;a.moved=e*e+n*n>d}a.event(t).zoom("mouse",o(y(a.that.__zoom,a.mouse[0]=ti(t,i),a.mouse[1]),a.extent,l))}),!0).on("mouseup.zoom",(function(t){s.on("mousemove.zoom mouseup.zoom",null),Xn(t.view,a.moved),$T(t),a.event(t).end()}),!0),u=ti(t,i),c=t.clientX,f=t.clientY;Wn(t.view),YT(t),a.mouse=[u,this.__zoom.invert(u)],Oi(this),a.start()}}function A(t,...e){if(r.apply(this,arguments)){var n=this.__zoom,a=ti(t.changedTouches?t.changedTouches[0]:t,this),s=n.invert(a),u=n.k*(t.shiftKey?.5:2),f=o(y(g(n,u),a,s),i.apply(this,e),l);$T(t),c>0?Vn(this).transition().duration(c).call(x,f,a,t):Vn(this).call(m.transform,f,a,t)}}function T(n,...i){if(r.apply(this,arguments)){var o,a,s,u,l=n.touches,c=l.length,f=_(this,i,n.changedTouches.length===c).event(n);for(YT(n),a=0;a<c;++a)u=[u=ti(s=l[a],this),this.__zoom.invert(u),s.identifier],f.touch0?f.touch1||f.touch0[2]===u[2]||(f.touch1=u,f.taps=0):(f.touch0=u,o=!0,f.taps=1+!!t);t&&(t=clearTimeout(t)),o&&(f.taps<2&&(e=u[0],t=setTimeout((function(){t=null}),500)),Oi(this),f.start())}}function E(t,...e){if(this.__zooming){var n,r,i,a,s=_(this,e).event(t),u=t.changedTouches,c=u.length;for($T(t),n=0;n<c;++n)i=ti(r=u[n],this),s.touch0&&s.touch0[2]===r.identifier?s.touch0[0]=i:s.touch1&&s.touch1[2]===r.identifier&&(s.touch1[0]=i);if(r=s.that.__zoom,s.touch1){var f=s.touch0[0],h=s.touch0[1],d=s.touch1[0],p=s.touch1[1],m=(m=d[0]-f[0])*m+(m=d[1]-f[1])*m,v=(v=p[0]-h[0])*v+(v=p[1]-h[1])*v;r=g(r,Math.sqrt(m/v)),i=[(f[0]+d[0])/2,(f[1]+d[1])/2],a=[(h[0]+p[0])/2,(h[1]+p[1])/2]}else{if(!s.touch0)return;i=s.touch0[0],a=s.touch0[1]}s.zoom("touch",o(y(r,i,a),s.extent,l))}}function C(t,...r){if(this.__zooming){var i,o,a=_(this,r).event(t),s=t.changedTouches,u=s.length;for(YT(t),n&&clearTimeout(n),n=setTimeout((function(){n=null}),500),i=0;i<u;++i)o=s[i],a.touch0&&a.touch0[2]===o.identifier?delete a.touch0:a.touch1&&a.touch1[2]===o.identifier&&delete a.touch1;if(a.touch1&&!a.touch0&&(a.touch0=a.touch1,delete a.touch1),a.touch0)a.touch0[1]=this.__zoom.invert(a.touch0[0]);else if(a.end(),2===a.taps&&(o=ti(o,this),Math.hypot(e[0]-o[0],e[1]-o[1])<p)){var l=Vn(this).on("dblclick.zoom");l&&l.apply(this,arguments)}}}return m.transform=function(t,e,n,r){var i=t.selection?t.selection():t;i.property("__zoom",tE),t!==i?x(t,e,n,r):i.interrupt().each((function(){_(this,arguments).event(r).start().zoom(null,"function"==typeof e?e.apply(this,arguments):e).end()}))},m.scaleBy=function(t,e,n,r){m.scaleTo(t,(function(){return this.__zoom.k*("function"==typeof e?e.apply(this,arguments):e)}),n,r)},m.scaleTo=function(t,e,n,r){m.transform(t,(function(){var t=i.apply(this,arguments),r=this.__zoom,a=null==n?v(t):"function"==typeof n?n.apply(this,arguments):n,s=r.invert(a),u="function"==typeof e?e.apply(this,arguments):e;return o(y(g(r,u),a,s),t,l)}),n,r)},m.translateBy=function(t,e,n,r){m.transform(t,(function(){return o(this.__zoom.translate("function"==typeof e?e.apply(this,arguments):e,"function"==typeof n?n.apply(this,arguments):n),i.apply(this,arguments),l)}),null,r)},m.translateTo=function(t,e,n,r,a){m.transform(t,(function(){var t=i.apply(this,arguments),a=this.__zoom,s=null==r?v(t):"function"==typeof r?r.apply(this,arguments):r;return o(KT.translate(s[0],s[1]).scale(a.k).translate("function"==typeof e?-e.apply(this,arguments):-e,"function"==typeof n?-n.apply(this,arguments):-n),t,l)}),r,a)},b.prototype={event:function(t){return t&&(this.sourceEvent=t),this},start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(t,e){return this.mouse&&"mouse"!==t&&(this.mouse[1]=e.invert(this.mouse[0])),this.touch0&&"touch"!==t&&(this.touch0[1]=e.invert(this.touch0[0])),this.touch1&&"touch"!==t&&(this.touch1[1]=e.invert(this.touch1[0])),this.that.__zoom=e,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(t){var e=Vn(this.that).datum();h.call(t,this.that,new WT(t,{sourceEvent:this.sourceEvent,target:m,type:t,transform:this.that.__zoom,dispatch:h}),e)}},m.wheelDelta=function(t){return arguments.length?(a="function"==typeof t?t:HT(+t),m):a},m.filter=function(t){return arguments.length?(r="function"==typeof t?t:HT(!!t),m):r},m.touchable=function(t){return arguments.length?(s="function"==typeof t?t:HT(!!t),m):s},m.extent=function(t){return arguments.length?(i="function"==typeof t?t:HT([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),m):i},m.scaleExtent=function(t){return arguments.length?(u[0]=+t[0],u[1]=+t[1],m):[u[0],u[1]]},m.translateExtent=function(t){return arguments.length?(l[0][0]=+t[0][0],l[1][0]=+t[1][0],l[0][1]=+t[0][1],l[1][1]=+t[1][1],m):[[l[0][0],l[0][1]],[l[1][0],l[1][1]]]},m.constrain=function(t){return arguments.length?(o=t,m):o},m.duration=function(t){return arguments.length?(c=+t,m):c},m.interpolate=function(t){return arguments.length?(f=t,m):f},m.on=function(){var t=h.on.apply(h,arguments);return t===h?m:t},m.clickDistance=function(t){return arguments.length?(d=(t=+t)*t,m):Math.sqrt(d)},m.tapDistance=function(t){return arguments.length?(p=+t,m):p},m}QT.prototype=XT.prototype}},n={};function r(t){var i=n[t];if(void 0!==i)return i.exports;var o=n[t]={id:t,exports:{}};return e[t].call(o.exports,o,o.exports,r),o.exports}return r.m=e,r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.b=document.baseURI||self.location.href,r.nc=void 0,r(2257)}()}));
|
|
55
55
|
//# sourceMappingURL=geo.min.js.map
|