","http://www.w3.org/2000/svg"===(d.firstChild&&d.firstChild.namespaceURI)),tj=!tR&&function(){try{var t=document.createElement("div");t.innerHTML='';var e=t.firstChild;return e.style.behavior="url(#default#VML)",e&&"object"==typeof e.adj}catch(t){return!1}}();function tB(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}var tN={ie:th,ielt9:tl,edge:tu,webkit:tc,android:tp,android23:td,androidStock:tf,opera:tm,chrome:tg,gecko:ty,safari:tv,phantom:tb,opera12:tw,win:tx,ie3d:tP,webkit3d:tL,gecko3d:tT,any3d:tE,mobile:tS,mobileWebkit:tS&&tc,mobileWebkit3d:tS&&tL,msPointer:tk,pointer:tM,touch:tO,touchNative:tA,mobileOpera:tS&&tm,mobileGecko:tS&&ty,retina:tC,passiveEvents:tz,canvas:tI,svg:tR,vml:tj,inlineSvg:tZ,mac:0===navigator.platform.indexOf("Mac"),linux:0===navigator.platform.indexOf("Linux")},tD=tN.msPointer?"MSPointerDown":"pointerdown",tF=tN.msPointer?"MSPointerMove":"pointermove",tW=tN.msPointer?"MSPointerUp":"pointerup",tU=tN.msPointer?"MSPointerCancel":"pointercancel",tH={touchstart:tD,touchmove:tF,touchend:tW,touchcancel:tU},tG={touchstart:function(t,e){e.MSPOINTER_TYPE_TOUCH&&e.pointerType===e.MSPOINTER_TYPE_TOUCH&&eT(e),tX(t,e)},touchmove:tX,touchend:tX,touchcancel:tX},tq={},tV=!1;function t$(t){tq[t.pointerId]=t}function tY(t){tq[t.pointerId]&&(tq[t.pointerId]=t)}function tK(t){delete tq[t.pointerId]}function tX(t,e){if(e.pointerType!==(e.MSPOINTER_TYPE_MOUSE||"mouse")){for(var i in e.touches=[],tq)e.touches.push(tq[i]);e.changedTouches=[e],t(e)}}var tJ=eo(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),tQ=eo(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),t0="webkitTransition"===tQ||"OTransition"===tQ?tQ+"End":"transitionend";function t1(t){return"string"==typeof t?document.getElementById(t):t}function t2(t,e){var i=t.style[e]||t.currentStyle&&t.currentStyle[e];if((!i||"auto"===i)&&document.defaultView){var n=document.defaultView.getComputedStyle(t,null);i=n?n[e]:null}return"auto"===i?null:i}function t3(t,e,i){var n=document.createElement(t);return n.className=e||"",i&&i.appendChild(n),n}function t8(t){var e=t.parentNode;e&&e.removeChild(t)}function t5(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function t6(t){var e=t.parentNode;e&&e.lastChild!==t&&e.appendChild(t)}function t4(t){var e=t.parentNode;e&&e.firstChild!==t&&e.insertBefore(t,e.firstChild)}function t9(t,e){if(void 0!==t.classList)return t.classList.contains(e);var i=ei(t);return i.length>0&&RegExp("(^|\\s)"+e+"(\\s|$)").test(i)}function t7(t,e){if(void 0!==t.classList)for(var i=T(e),n=0,o=i.length;n0?2*window.devicePixelRatio:1;function eA(t){return tN.edge?t.wheelDeltaY/2:t.deltaY&&0===t.deltaMode?-t.deltaY/eM:t.deltaY&&1===t.deltaMode?-(20*t.deltaY):t.deltaY&&2===t.deltaMode?-(60*t.deltaY):t.deltaX||t.deltaZ?0:t.wheelDelta?(t.wheelDeltaY||t.wheelDelta)/2:t.detail&&32765>Math.abs(t.detail)?-(20*t.detail):t.detail?-(60*(t.detail/32765)):0}function eO(t,e){var i=e.relatedTarget;if(!i)return!0;try{for(;i&&i!==t;)i=i.parentNode}catch(t){return!1}return i!==t}var eC=W.extend({run:function(t,e,i,n){this.stop(),this._el=t,this._inProgress=!0,this._duration=i||.25,this._easeOutPower=1/Math.max(n||.5,.2),this._startPos=ea(t),this._offset=e.subtract(this._startPos),this._startTime=+new Date,this.fire("start"),this._animate()},stop:function(){this._inProgress&&(this._step(!0),this._complete())},_animate:function(){this._animId=B(this._animate,this),this._step()},_step:function(t){var e=+new Date-this._startTime,i=1e3*this._duration;ethis.options.maxZoom))?this.setZoom(t):this},panInsideBounds:function(t,e){this._enforcingBounds=!0;var i=this.getCenter(),n=this._limitCenter(i,this._zoom,Y(t));return i.equals(n)||this.panTo(n,e),this._enforcingBounds=!1,this},panInside:function(t,e){var i=G((e=e||{}).paddingTopLeft||e.padding||[0,0]),n=G(e.paddingBottomRight||e.padding||[0,0]),o=this.project(this.getCenter()),r=this.project(t),s=this.getPixelBounds(),a=V([s.min.add(i),s.max.subtract(n)]),h=a.getSize();if(!a.contains(r)){this._enforcingBounds=!0;var l=r.subtract(a.getCenter()),u=a.extend(r).getSize().subtract(h);o.x+=l.x<0?-u.x:u.x,o.y+=l.y<0?-u.y:u.y,this.panTo(this.unproject(o),e),this._enforcingBounds=!1}return this},invalidateSize:function(t){if(!this._loaded)return this;t=i({animate:!1,pan:!0},!0===t?{animate:!0}:t);var e=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var n=this.getSize(),o=e.divideBy(2).round(),r=n.divideBy(2).round(),s=o.subtract(r);return s.x||s.y?(t.animate&&t.pan?this.panBy(s):(t.pan&&this._rawPanBy(s),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(m(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:e,newSize:n})):this},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(t){if(t=this._locateOptions=i({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var e=m(this._handleGeolocationResponse,this),n=m(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(e,n,t):navigator.geolocation.getCurrentPosition(e,n,t),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(t){if(this._container._leaflet_id){var e=t.code,i=t.message||(1===e?"permission denied":2===e?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:e,message:"Geolocation error: "+i+"."})}},_handleGeolocationResponse:function(t){if(this._container._leaflet_id){var e=t.coords.latitude,i=t.coords.longitude,n=new K(e,i),o=n.toBounds(2*t.coords.accuracy),r=this._locateOptions;if(r.setView){var s=this.getBoundsZoom(o);this.setView(n,r.maxZoom?Math.min(s,r.maxZoom):s)}var a={latlng:n,bounds:o,timestamp:t.timestamp};for(var h in t.coords)"number"==typeof t.coords[h]&&(a[h]=t.coords[h]);this.fire("locationfound",a)}},addHandler:function(t,e){if(!e)return this;var i=this[t]=new e(this);return this._handlers.push(i),this.options[t]&&i.enable(),this},remove:function(){var t;if(this._initEvents(!0),this.options.maxBounds&&this.off("moveend",this._panInsideMaxBounds),this._containerId!==this._container._leaflet_id)throw Error("Map container is being reused by another instance");try{delete this._container._leaflet_id,delete this._containerId}catch(t){this._container._leaflet_id=void 0,this._containerId=void 0}for(t in void 0!==this._locationWatchId&&this.stopLocate(),this._stop(),t8(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(N(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload"),this._layers)this._layers[t].remove();for(t in this._panes)t8(this._panes[t]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,e){var i=t3("div","leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),e||this._mapPane);return t&&(this._panes[t]=i),i},getCenter:function(){return(this._checkIfLoaded(),this._lastCenter&&!this._moved())?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var t=this.getPixelBounds(),e=this.unproject(t.getBottomLeft()),i=this.unproject(t.getTopRight());return new $(e,i)},getMinZoom:function(){return void 0===this.options.minZoom?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return void 0===this.options.maxZoom?void 0===this._layersMaxZoom?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(t,e,i){t=Y(t),i=G(i||[0,0]);var n=this.getZoom()||0,o=this.getMinZoom(),r=this.getMaxZoom(),s=t.getNorthWest(),a=t.getSouthEast(),h=this.getSize().subtract(i),l=V(this.project(a,n),this.project(s,n)).getSize(),u=tN.any3d?this.options.zoomSnap:1,c=h.x/l.x,p=h.y/l.y,d=e?Math.max(c,p):Math.min(c,p);return n=this.getScaleZoom(d,n),u&&(n=Math.round(n/(u/100))*(u/100),n=e?Math.ceil(n/u)*u:Math.floor(n/u)*u),Math.max(o,Math.min(r,n))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new U(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,e){var i=this._getTopLeftPoint(t,e);return new q(i,i.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(t){return this.options.crs.getProjectedBounds(void 0===t?this.getZoom():t)},getPane:function(t){return"string"==typeof t?this._panes[t]:t},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(t,e){var i=this.options.crs;return e=void 0===e?this._zoom:e,i.scale(t)/i.scale(e)},getScaleZoom:function(t,e){var i=this.options.crs;e=void 0===e?this._zoom:e;var n=i.zoom(t*i.scale(e));return isNaN(n)?1/0:n},project:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.latLngToPoint(X(t),e)},unproject:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.pointToLatLng(G(t),e)},layerPointToLatLng:function(t){var e=G(t).add(this.getPixelOrigin());return this.unproject(e)},latLngToLayerPoint:function(t){return this.project(X(t))._round()._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(X(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds(Y(t))},distance:function(t,e){return this.options.crs.distance(X(t),X(e))},containerPointToLayerPoint:function(t){return G(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return G(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(G(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(X(t)))},mouseEventToContainerPoint:function(t){return ek(t,this._container)},mouseEventToLayerPoint:function(t){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(t))},mouseEventToLatLng:function(t){return this.layerPointToLatLng(this.mouseEventToLayerPoint(t))},_initContainer:function(t){var e=this._container=t1(t);if(e){if(e._leaflet_id)throw Error("Map container is already initialized.")}else throw Error("Map container not found.");ef(e,"scroll",this._onScroll,this),this._containerId=y(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&tN.any3d,t7(t,"leaflet-container"+(tN.touch?" leaflet-touch":"")+(tN.retina?" leaflet-retina":"")+(tN.ielt9?" leaflet-oldie":"")+(tN.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var e=t2(t,"position");"absolute"!==e&&"relative"!==e&&"fixed"!==e&&(t.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var t=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),es(this._mapPane,new U(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(t7(t.markerPane,"leaflet-zoom-hide"),t7(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e,i){es(this._mapPane,new U(0,0));var n=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var o=this._zoom!==e;this._moveStart(o,i)._move(t,e)._moveEnd(o),this.fire("viewreset"),n&&this.fire("load")},_moveStart:function(t,e){return t&&this.fire("zoomstart"),e||this.fire("movestart"),this},_move:function(t,e,i,n){void 0===e&&(e=this._zoom);var o=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),n?i&&i.pinch&&this.fire("zoom",i):((o||i&&i.pinch)&&this.fire("zoom",i),this.fire("move",i)),this},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return N(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){es(this._mapPane,this._getMapPanePos().subtract(t))},_getZoomSpan:function(){return this.getMaxZoom()-this.getMinZoom()},_panInsideMaxBounds:function(){this._enforcingBounds||this.panInsideBounds(this.options.maxBounds)},_checkIfLoaded:function(){if(!this._loaded)throw Error("Set map center and zoom first.")},_initEvents:function(t){this._targets={},this._targets[y(this._container)]=this;var e=t?eg:ef;e(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&e(window,"resize",this._onResize,this),tN.any3d&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){N(this._resizeRequest),this._resizeRequest=B(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var t=this._getMapPanePos();Math.max(Math.abs(t.x),Math.abs(t.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(t,e){for(var i,n=[],o="mouseout"===e||"mouseover"===e,r=t.target||t.srcElement,s=!1;r;){if((i=this._targets[y(r)])&&("click"===e||"preclick"===e)&&this._draggableMoved(i)){s=!0;break}if(i&&i.listens(e,!0)&&(o&&!eO(r,t)||(n.push(i),o))||r===this._container)break;r=r.parentNode}return!n.length&&!s&&!o&&this.listens(e,!0)&&(n=[this]),n},_isClickDisabled:function(t){for(;t&&t!==this._container;){if(t._leaflet_disable_click)return!0;t=t.parentNode}},_handleDOMEvent:function(t){var e=t.target||t.srcElement;if(!(!this._loaded||e._leaflet_disable_events||"click"===t.type&&this._isClickDisabled(e))){var i=t.type;"mousedown"===i&&ec(e),this._fireDOMEvent(t,i)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,e,n){if("click"===t.type){var o=i({},t);o.type="preclick",this._fireDOMEvent(o,o.type,n)}var r=this._findEventTargets(t,e);if(n){for(var s=[],a=0;a0?Math.round(t-e)/2:Math.max(0,Math.ceil(t))-Math.max(0,Math.floor(e))},_limitZoom:function(t){var e=this.getMinZoom(),i=this.getMaxZoom(),n=tN.any3d?this.options.zoomSnap:1;return n&&(t=Math.round(t/n)*n),Math.max(e,Math.min(i,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){et(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,e){var i=this._getCenterOffset(t)._trunc();return!!(!0===(e&&e.animate)||this.getSize().contains(i))&&(this.panBy(i,e),!0)},_createAnimProxy:function(){var t=this._proxy=t3("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(t){var e=this._proxy.style[tJ];er(this._proxy,this.project(t.center,t.zoom),this.getZoomScale(t.zoom,1)),e===this._proxy.style[tJ]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){t8(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var t=this.getCenter(),e=this.getZoom();er(this._proxy,this.project(t,e),this.getZoomScale(e,1))},_catchTransitionEnd:function(t){this._animatingZoom&&t.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(t,e,i){if(this._animatingZoom)return!0;if(i=i||{},!this._zoomAnimated||!1===i.animate||this._nothingToAnimate()||Math.abs(e-this._zoom)>this.options.zoomAnimationThreshold)return!1;var n=this.getZoomScale(e),o=this._getCenterOffset(t)._divideBy(1-1/n);return!!(!0===i.animate||this.getSize().contains(o))&&(B(function(){this._moveStart(!0,!1)._animateZoom(t,e,!0)},this),!0)},_animateZoom:function(t,e,i,n){this._mapPane&&(i&&(this._animatingZoom=!0,this._animateToCenter=t,this._animateToZoom=e,t7(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:t,zoom:e,noUpdate:n}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(m(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&et(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom,void 0,!0),this._tempFireZoomEvent&&this.fire("zoom"),delete this._tempFireZoomEvent,this.fire("move"),this._moveEnd(!0))}});function eI(t,e){return new ez(t,e)}var eR=D.extend({options:{position:"topright"},initialize:function(t){E(this,t)},getPosition:function(){return this.options.position},setPosition:function(t){var e=this._map;return e&&e.removeControl(this),this.options.position=t,e&&e.addControl(this),this},getContainer:function(){return this._container},addTo:function(t){this.remove(),this._map=t;var e=this._container=this.onAdd(t),i=this.getPosition(),n=t._controlCorners[i];return t7(e,"leaflet-control"),-1!==i.indexOf("bottom")?n.insertBefore(e,n.firstChild):n.appendChild(e),this._map.on("unload",this.remove,this),this},remove:function(){return this._map&&(t8(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null),this},_refocusOnMap:function(t){this._map&&t&&t.screenX>0&&t.screenY>0&&this._map.getContainer().focus()}}),eZ=function(t){return new eR(t)};ez.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){var t=this._controlCorners={},e="leaflet-",i=this._controlContainer=t3("div",e+"control-container",this._container);function n(n,o){var r=e+n+" "+e+o;t[n+o]=t3("div",r,i)}n("top","left"),n("top","right"),n("bottom","left"),n("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)t8(this._controlCorners[t]);t8(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var ej=eR.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,e,i,n){return i1,this._baseLayersList.style.display=t?"":"none"),this._separator.style.display=e&&t?"":"none",this},_onLayerChange:function(t){this._handlingClick||this._update();var e=this._getLayer(y(t.target)),i=e.overlay?"add"===t.type?"overlayadd":"overlayremove":"add"===t.type?"baselayerchange":null;i&&this._map.fire(i,e)},_createRadioElement:function(t,e){var i=document.createElement("div");return i.innerHTML='",i.firstChild},_addItem:function(t){var e,i=document.createElement("label"),n=this._map.hasLayer(t.layer);t.overlay?((e=document.createElement("input")).type="checkbox",e.className="leaflet-control-layers-selector",e.defaultChecked=n):e=this._createRadioElement("leaflet-base-layers_"+y(this),n),this._layerControlInputs.push(e),e.layerId=y(t.layer),ef(e,"click",this._onInputClick,this);var o=document.createElement("span");o.innerHTML=" "+t.name;var r=document.createElement("span");return i.appendChild(r),r.appendChild(e),r.appendChild(o),(t.overlay?this._overlaysList:this._baseLayersList).appendChild(i),this._checkDisabledLayers(),i},_onInputClick:function(){var t,e,i=this._layerControlInputs,n=[],o=[];this._handlingClick=!0;for(var r=i.length-1;r>=0;r--)t=i[r],e=this._getLayer(t.layerId).layer,t.checked?n.push(e):t.checked||o.push(e);for(r=0;r=0;o--)t=i[o],e=this._getLayer(t.layerId).layer,t.disabled=void 0!==e.options.minZoom&&ne.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this}}),eB=eR.extend({options:{position:"topleft",zoomInText:'+',zoomInTitle:"Zoom in",zoomOutText:'−',zoomOutTitle:"Zoom out"},onAdd:function(t){var e="leaflet-control-zoom",i=t3("div",e+" leaflet-bar"),n=this.options;return this._zoomInButton=this._createButton(n.zoomInText,n.zoomInTitle,e+"-in",i,this._zoomIn),this._zoomOutButton=this._createButton(n.zoomOutText,n.zoomOutTitle,e+"-out",i,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),i},onRemove:function(t){t.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(t){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(t.shiftKey?3:1))},_createButton:function(t,e,i,n,o){var r=t3("a",i,n);return r.innerHTML=t,r.href="#",r.title=e,r.setAttribute("role","button"),r.setAttribute("aria-label",e),eL(r),ef(r,"click",eE),ef(r,"click",o,this),ef(r,"click",this._refocusOnMap,this),r},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";et(this._zoomInButton,e),et(this._zoomOutButton,e),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||t._zoom===t.getMinZoom())&&(t7(this._zoomOutButton,e),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||t._zoom===t.getMaxZoom())&&(t7(this._zoomInButton,e),this._zoomInButton.setAttribute("aria-disabled","true"))}});ez.mergeOptions({zoomControl:!0}),ez.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new eB,this.addControl(this.zoomControl))});var eN=eR.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",i=t3("div",e),n=this.options;return this._addScales(n,e+"-line",i),t.on(n.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),i},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,e,i){t.metric&&(this._mScale=t3("div",e,i)),t.imperial&&(this._iScale=t3("div",e,i))},_update:function(){var t=this._map,e=t.getSize().y/2,i=t.distance(t.containerPointToLatLng([0,e]),t.containerPointToLatLng([this.options.maxWidth,e]));this._updateScales(i)},_updateScales:function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},_updateMetric:function(t){var e=this._getRoundNum(t),i=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,i,e/t)},_updateImperial:function(t){var e,i,n,o=3.2808399*t;o>5280?(e=o/5280,i=this._getRoundNum(e),this._updateScale(this._iScale,i+" mi",i/e)):(n=this._getRoundNum(o),this._updateScale(this._iScale,n+" ft",n/o))},_updateScale:function(t,e,i){t.style.width=Math.round(this.options.maxWidth*i)+"px",t.innerHTML=e},_getRoundNum:function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),i=t/e;return e*(i=i>=10?10:i>=5?5:i>=3?3:i>=2?2:1)}}),eD=eR.extend({options:{position:"bottomright",prefix:''+(tN.inlineSvg?' ':"")+"Leaflet"},initialize:function(t){E(this,t),this._attributions={}},onAdd:function(t){for(var e in t.attributionControl=this,this._container=t3("div","leaflet-control-attribution"),eL(this._container),t._layers)t._layers[e].getAttribution&&this.addAttribution(t._layers[e].getAttribution());return this._update(),t.on("layeradd",this._addAttribution,this),this._container},onRemove:function(t){t.off("layeradd",this._addAttribution,this)},_addAttribution:function(t){t.layer.getAttribution&&(this.addAttribution(t.layer.getAttribution()),t.layer.once("remove",function(){this.removeAttribution(t.layer.getAttribution())},this))},setPrefix:function(t){return this.options.prefix=t,this._update(),this},addAttribution:function(t){return t&&(this._attributions[t]||(this._attributions[t]=0),this._attributions[t]++,this._update()),this},removeAttribution:function(t){return t&&this._attributions[t]&&(this._attributions[t]--,this._update()),this},_update:function(){if(this._map){var t=[];for(var e in this._attributions)this._attributions[e]&&t.push(e);var i=[];this.options.prefix&&i.push(this.options.prefix),t.length&&i.push(t.join(", ")),this._container.innerHTML=i.join(' | ')}}});ez.mergeOptions({attributionControl:!0}),ez.addInitHook(function(){this.options.attributionControl&&new eD().addTo(this)}),eR.Layers=ej,eR.Zoom=eB,eR.Scale=eN,eR.Attribution=eD,eZ.layers=function(t,e,i){return new ej(t,e,i)},eZ.zoom=function(t){return new eB(t)},eZ.scale=function(t){return new eN(t)},eZ.attribution=function(t){return new eD(t)};var eF=D.extend({initialize:function(t){this._map=t},enable:function(){return this._enabled||(this._enabled=!0,this.addHooks()),this},disable:function(){return this._enabled&&(this._enabled=!1,this.removeHooks()),this},enabled:function(){return!!this._enabled}});eF.addTo=function(t,e){return t.addHandler(e,this),this};var eW=tN.touch?"touchstart mousedown":"mousedown",eU=W.extend({options:{clickTolerance:3},initialize:function(t,e,i,n){E(this,n),this._element=t,this._dragStartTarget=e||t,this._preventOutline=i},enable:function(){this._enabled||(ef(this._dragStartTarget,eW,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(eU._dragging===this&&this.finishDrag(!0),eg(this._dragStartTarget,eW,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(!(!this._enabled||(this._moved=!1,t9(this._element,"leaflet-zoom-anim")))){if(t.touches&&1!==t.touches.length){eU._dragging===this&&this.finishDrag();return}if(!eU._dragging&&!t.shiftKey&&(1===t.which||1===t.button||t.touches)&&(eU._dragging=this,this._preventOutline&&ec(this._element),el(),n(),!this._moving)){this.fire("down");var e=t.touches?t.touches[0]:t,i=ed(this._element);this._startPoint=new U(e.clientX,e.clientY),this._startPos=ea(this._element),this._parentScale=e_(i);var o="mousedown"===t.type;ef(document,o?"mousemove":"touchmove",this._onMove,this),ef(document,o?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(t){if(this._enabled){if(t.touches&&t.touches.length>1){this._moved=!0;return}var e=t.touches&&1===t.touches.length?t.touches[0]:t,i=new U(e.clientX,e.clientY)._subtract(this._startPoint);(i.x||i.y)&&(Math.abs(i.x)+Math.abs(i.y)l&&(s=a,l=h);l>n&&(i[s]=1,t(e,i,n,o,s),t(e,i,n,s,r))}(t,n,e,0,i-1);var o,r=[];for(o=0;oe&&(i.push(t[n]),o=n);return oe.max.x&&(i|=2),t.ye.max.y&&(i|=8),i}function eY(t,e,i,n){var o,r=e.x,s=e.y,a=i.x-r,h=i.y-s,l=a*a+h*h;return l>0&&((o=((t.x-r)*a+(t.y-s)*h)/l)>1?(r=i.x,s=i.y):o>0&&(r+=a*o,s+=h*o)),a=t.x-r,h=t.y-s,n?a*a+h*h:new U(r,s)}function eK(t){return!A(t[0])||"object"!=typeof t[0][0]&&void 0!==t[0][0]}function eX(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),eK(t)}function eJ(t,e){if(!t||0===t.length)throw Error("latlngs not passed");eK(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var i,n,o,r,s,a,h,l,u=[];for(var c in t)u.push(e.project(X(t[c])));var p=u.length;for(i=0,n=0;in){h=(r-n)/o,l=[a.x-h*(a.x-s.x),a.y-h*(a.y-s.y)];break}return e.unproject(G(l))}function eQ(t,e,i){var n,o,r,s,a,h,l,u,c,p=[1,4,2,8];for(o=0,l=t.length;o1e-7;h++)e=Math.pow((1-(e=r*Math.sin(a)))/(1+e),r/2),l=Math.PI/2-2*Math.atan(s*e)-a,a+=l;return new K(a*i,t.x*i/n)}},e3=i({},Q,{code:"EPSG:3395",projection:e2,transformation:ti(_=.5/(Math.PI*e2.R),.5,-_,.5)}),e8=i({},Q,{code:"EPSG:4326",projection:e1,transformation:ti(1/180,1,-1/180,.5)}),e5=i({},J,{projection:e1,transformation:ti(1,0,-1,0),scale:function(t){return Math.pow(2,t)},zoom:function(t){return Math.log(t)/Math.LN2},distance:function(t,e){var i=e.lng-t.lng,n=e.lat-t.lat;return Math.sqrt(i*i+n*n)},infinite:!0});J.Earth=Q,J.EPSG3395=e3,J.EPSG3857=tn,J.EPSG900913=to,J.EPSG4326=e8,J.Simple=e5;var e6=W.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(t){return t.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(t){return t&&t.removeLayer(this),this},getPane:function(t){return this._map.getPane(t?this.options[t]||t:this.options.pane)},addInteractiveTarget:function(t){return this._map._targets[y(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[y(t)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(t){var e=t.target;if(e.hasLayer(this)){if(this._map=e,this._zoomAnimated=e._zoomAnimated,this.getEvents){var i=this.getEvents();e.on(i,this),this.once("remove",function(){e.off(i,this)},this)}this.onAdd(e),this.fire("add"),e.fire("layeradd",{layer:this})}}});ez.include({addLayer:function(t){if(!t._layerAdd)throw Error("The provided object is not a Layer.");var e=y(t);return this._layers[e]||(this._layers[e]=t,t._mapToAdd=this,t.beforeAdd&&t.beforeAdd(this),this.whenReady(t._layerAdd,t)),this},removeLayer:function(t){var e=y(t);return this._layers[e]&&(this._loaded&&t.onRemove(this),delete this._layers[e],this._loaded&&(this.fire("layerremove",{layer:t}),t.fire("remove")),t._map=t._mapToAdd=null),this},hasLayer:function(t){return y(t) in this._layers},eachLayer:function(t,e){for(var i in this._layers)t.call(e,this._layers[i]);return this},_addLayers:function(t){t=t?A(t)?t:[t]:[];for(var e=0,i=t.length;ethis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),void 0===this.options.minZoom&&this._layersMinZoom&&this.getZoom()=2&&e[0]instanceof K&&e[0].equals(e[i-1])&&e.pop(),e},_setLatLngs:function(t){il.prototype._setLatLngs.call(this,t),eK(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return eK(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,e=this.options.weight,i=new U(e,e);if(t=new q(t.min.subtract(i),t.max.add(i)),this._parts=[],this._pxBounds&&this._pxBounds.intersects(t)){if(this.options.noClip){this._parts=this._rings;return}for(var n,o=0,r=this._rings.length;ot.y!=n.y>t.y&&t.x<(n.x-i.x)*(t.y-i.y)/(n.y-i.y)+i.x&&(l=!l);return l||il.prototype._containsPoint.call(this,t,!0)}}),ic=e9.extend({initialize:function(t,e){E(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e,i,n,o=A(t)?t:t.features;if(o){for(e=0,i=o.length;e0?n:[e.src];return}A(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(e.style,"objectFit")&&(e.style.objectFit="fill"),e.autoplay=!!this.options.autoplay,e.loop=!!this.options.loop,e.muted=!!this.options.muted,e.playsInline=!!this.options.playsInline;for(var r=0;r×',ef(n,"click",function(t){eT(t),this.close()},this)}},_updateLayout:function(){var t=this._contentNode,e=t.style;e.width="",e.whiteSpace="nowrap";var i=t.offsetWidth;i=Math.max(i=Math.min(i,this.options.maxWidth),this.options.minWidth),e.width=i+1+"px",e.whiteSpace="",e.height="";var n=t.offsetHeight,o=this.options.maxHeight,r="leaflet-popup-scrolled";o&&n>o?(e.height=o+"px",t7(t,r)):et(t,r),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),i=this._getAnchor();es(this._container,e.add(i))},_adjustPan:function(t){if(this.options.autoPan){this._map._panAnim&&this._map._panAnim.stop();var e=this._map,i=parseInt(t2(this._container,"marginBottom"),10)||0,n=this._container.offsetHeight+i,o=this._containerWidth,r=new U(this._containerLeft,-n-this._containerBottom);r._add(ea(this._container));var s=e.layerPointToContainerPoint(r),a=G(this.options.autoPanPadding),h=G(this.options.autoPanPaddingTopLeft||a),l=G(this.options.autoPanPaddingBottomRight||a),u=e.getSize(),c=0,p=0;s.x+o+l.x>u.x&&(c=s.x+o-u.x+l.x),s.x-c-h.x<0&&(c=s.x-h.x),s.y+n+l.y>u.y&&(p=s.y+n-u.y+l.y),s.y-p-h.y<0&&(p=s.y-h.y),(c||p)&&e.fire("autopanstart").panBy([c,p],{animate:t&&"moveend"===t.type})}},_getAnchor:function(){return G(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}});ez.mergeOptions({closePopupOnClick:!0}),ez.include({openPopup:function(t,e,i){return this._initOverlay(iS,t,e,i).openOn(this),this},closePopup:function(t){return t=arguments.length?t:this._popup,t&&t.close(),this}}),e6.include({bindPopup:function(t,e){return this._popup=this._initOverlay(iS,this._popup,t,e),this._popupHandlersAdded||(this.on({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!0),this},unbindPopup:function(){return this._popup&&(this.off({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!1,this._popup=null),this},openPopup:function(t){return this._popup&&this._popup._prepareOpen(t)&&this._popup.openOn(this._map),this},closePopup:function(){return this._popup&&this._popup.close(),this},togglePopup:function(){return this._popup&&this._popup.toggle(this),this},isPopupOpen:function(){return!!this._popup&&this._popup.isOpen()},setPopupContent:function(t){return this._popup&&this._popup.setContent(t),this},getPopup:function(){return this._popup},_openPopup:function(t){if(this._popup&&this._map){eE(t);var e=t.layer||t.target;if(this._popup._source===e&&!(e instanceof is)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(t.latlng);return}this._popup._source=e,this.openPopup(t.latlng)}},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){13===t.originalEvent.keyCode&&this._openPopup(t)}});var ik=iE.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(t){iE.prototype.onAdd.call(this,t),this.setOpacity(this.options.opacity),t.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(t){iE.prototype.onRemove.call(this,t),t.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var t=iE.prototype.getEvents.call(this);return this.options.permanent||(t.preclick=this.close),t},_initLayout:function(){var t="leaflet-tooltip "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=t3("div",t),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+y(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e,i,n=this._map,o=this._container,r=n.latLngToContainerPoint(n.getCenter()),s=n.layerPointToContainerPoint(t),a=this.options.direction,h=o.offsetWidth,l=o.offsetHeight,u=G(this.options.offset),c=this._getAnchor();"top"===a?(e=h/2,i=l):"bottom"===a?(e=h/2,i=0):("center"===a?e=h/2:"right"===a?e=0:"left"===a?e=h:s.xthis.options.maxZoom||in&&this._retainParent(o,r,s,n))},_retainChildren:function(t,e,i,n){for(var o=2*t;o<2*t+2;o++)for(var r=2*e;r<2*e+2;r++){var s=new U(o,r);s.z=i+1;var a=this._tileCoordsToKey(s),h=this._tiles[a];if(h&&h.active){h.retain=!0;continue}h&&h.loaded&&(h.retain=!0),i+1this.options.maxZoom||void 0!==this.options.minZoom&&o1){this._setView(t,i);return}for(var c=o.min.y;c<=o.max.y;c++)for(var p=o.min.x;p<=o.max.x;p++){var d=new U(p,c);if(d.z=this._tileZoom,this._isValidTile(d)){var _=this._tiles[this._tileCoordsToKey(d)];_?_.current=!0:s.push(d)}}if(s.sort(function(t,e){return t.distanceTo(r)-e.distanceTo(r)}),0!==s.length){this._loading||(this._loading=!0,this.fire("loading"));var f=document.createDocumentFragment();for(p=0;pi.max.x)||!e.wrapLat&&(t.yi.max.y))return!1}if(!this.options.bounds)return!0;var n=this._tileCoordsToBounds(t);return Y(this.options.bounds).overlaps(n)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var e=this._map,i=this.getTileSize(),n=t.scaleBy(i),o=n.add(i);return[e.unproject(n,t.z),e.unproject(o,t.z)]},_tileCoordsToBounds:function(t){var e=this._tileCoordsToNwSe(t),i=new $(e[0],e[1]);return this.options.noWrap||(i=this._map.wrapLatLngBounds(i)),i},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var e=t.split(":"),i=new U(+e[0],+e[1]);return i.z=+e[2],i},_removeTile:function(t){var e=this._tiles[t];e&&(t8(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){t7(t,"leaflet-tile");var e=this.getTileSize();t.style.width=e.x+"px",t.style.height=e.y+"px",t.onselectstart=w,t.onmousemove=w,tN.ielt9&&this.options.opacity<1&&en(t,this.options.opacity)},_addTile:function(t,e){var i=this._getTilePos(t),n=this._tileCoordsToKey(t),o=this.createTile(this._wrapCoords(t),m(this._tileReady,this,t));this._initTile(o),this.createTile.length<2&&B(m(this._tileReady,this,t,null,o)),es(o,i),this._tiles[n]={el:o,coords:t,current:!0},e.appendChild(o),this.fire("tileloadstart",{tile:o,coords:t})},_tileReady:function(t,e,i){e&&this.fire("tileerror",{error:e,tile:i,coords:t});var n=this._tileCoordsToKey(t);(i=this._tiles[n])&&(i.loaded=+new Date,this._map._fadeAnimated?(en(i.el,0),N(this._fadeFrame),this._fadeFrame=B(this._updateOpacity,this)):(i.active=!0,this._pruneTiles()),e||(t7(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),tN.ielt9||!this._map._fadeAnimated?B(this._pruneTiles,this):setTimeout(m(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new U(this._wrapX?b(t.x,this._wrapX):t.x,this._wrapY?b(t.y,this._wrapY):t.y);return e.z=t.z,e},_pxBoundsToTileRange:function(t){var e=this.getTileSize();return new q(t.min.unscaleBy(e).floor(),t.max.unscaleBy(e).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var t in this._tiles)if(!this._tiles[t].loaded)return!1;return!0}}),iC=iO.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(t,e){this._url=t,(e=E(this,e)).detectRetina&&tN.retina&&e.maxZoom>0?(e.tileSize=Math.floor(e.tileSize/2),e.zoomReverse?(e.zoomOffset--,e.minZoom=Math.min(e.maxZoom,e.minZoom+1)):(e.zoomOffset++,e.maxZoom=Math.max(e.minZoom,e.maxZoom-1)),e.minZoom=Math.max(0,e.minZoom)):e.zoomReverse?e.minZoom=Math.min(e.maxZoom,e.minZoom):e.maxZoom=Math.max(e.minZoom,e.maxZoom),"string"==typeof e.subdomains&&(e.subdomains=e.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(t,e){return this._url===t&&void 0===e&&(e=!0),this._url=t,e||this.redraw(),this},createTile:function(t,e){var i=document.createElement("img");return ef(i,"load",m(this._tileOnLoad,this,e,i)),ef(i,"error",m(this._tileOnError,this,e,i)),(this.options.crossOrigin||""===this.options.crossOrigin)&&(i.crossOrigin=!0===this.options.crossOrigin?"":this.options.crossOrigin),"string"==typeof this.options.referrerPolicy&&(i.referrerPolicy=this.options.referrerPolicy),i.alt="",i.src=this.getTileUrl(t),i},getTileUrl:function(t){var e={r:tN.retina?"@2x":"",s:this._getSubdomain(t),x:t.x,y:t.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var n=this._globalTileRange.max.y-t.y;this.options.tms&&(e.y=n),e["-y"]=n}return M(this._url,i(e,this.options))},_tileOnLoad:function(t,e){tN.ielt9?setTimeout(m(t,this,null,e),0):t(null,e)},_tileOnError:function(t,e,i){var n=this.options.errorTileUrl;n&&e.getAttribute("src")!==n&&(e.src=n),t(i,e)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,e=this.options.maxZoom,i=this.options.zoomReverse,n=this.options.zoomOffset;return i&&(t=e-t),t+n},_getSubdomain:function(t){var e=Math.abs(t.x+t.y)%this.options.subdomains.length;return this.options.subdomains[e]},_abortLoading:function(){var t,e;for(t in this._tiles)if(this._tiles[t].coords.z!==this._tileZoom&&((e=this._tiles[t].el).onload=w,e.onerror=w,!e.complete)){e.src=C;var i=this._tiles[t].coords;t8(e),delete this._tiles[t],this.fire("tileabort",{tile:e,coords:i})}},_removeTile:function(t){var e=this._tiles[t];if(e)return e.el.setAttribute("src",C),iO.prototype._removeTile.call(this,t)},_tileReady:function(t,e,i){if(this._map&&(!i||i.getAttribute("src")!==C))return iO.prototype._tileReady.call(this,t,e,i)}});function iz(t,e){return new iC(t,e)}var iI=iC.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(t,e){this._url=t;var n=i({},this.defaultWmsParams);for(var o in e)o in this.options||(n[o]=e[o]);var r=(e=E(this,e)).detectRetina&&tN.retina?2:1,s=this.getTileSize();n.width=s.x*r,n.height=s.y*r,this.wmsParams=n},onAdd:function(t){this._crs=this.options.crs||t.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var e=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[e]=this._crs.code,iC.prototype.onAdd.call(this,t)},getTileUrl:function(t){var e=this._tileCoordsToNwSe(t),i=this._crs,n=V(i.project(e[0]),i.project(e[1])),o=n.min,r=n.max,s=(this._wmsVersion>=1.3&&this._crs===e8?[o.y,o.x,r.y,r.x]:[o.x,o.y,r.x,r.y]).join(","),a=iC.prototype.getTileUrl.call(this,t);return a+S(this.wmsParams,a,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+s},setParams:function(t,e){return i(this.wmsParams,t),e||this.redraw(),this}});iC.WMS=iI,iz.wms=function(t,e){return new iI(t,e)};var iR=e6.extend({options:{padding:.1},initialize:function(t){E(this,t),y(this),this._layers=this._layers||{}},onAdd:function(){!this._container&&(this._initContainer(),this._zoomAnimated&&t7(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var t={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(t.zoomanim=this._onAnimZoom),t},_onAnimZoom:function(t){this._updateTransform(t.center,t.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(t,e){var i=this._map.getZoomScale(e,this._zoom),n=this._map.getSize().multiplyBy(.5+this.options.padding),o=this._map.project(this._center,e),r=n.multiplyBy(-i).add(o).subtract(this._map._getNewPixelOrigin(t,e));tN.any3d?er(this._container,r,i):es(this._container,r)},_reset:function(){for(var t in this._update(),this._updateTransform(this._center,this._zoom),this._layers)this._layers[t]._reset()},_onZoomEnd:function(){for(var t in this._layers)this._layers[t]._project()},_updatePaths:function(){for(var t in this._layers)this._layers[t]._update()},_update:function(){var t=this.options.padding,e=this._map.getSize(),i=this._map.containerPointToLayerPoint(e.multiplyBy(-t)).round();this._bounds=new q(i,i.add(e.multiplyBy(1+2*t)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),iZ=iR.extend({options:{tolerance:0},getEvents:function(){var t=iR.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){iR.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");ef(t,"mousemove",this._onMouseMove,this),ef(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),ef(t,"mouseout",this._handleMouseOut,this),t._leaflet_disable_events=!0,this._ctx=t.getContext("2d")},_destroyContainer:function(){N(this._redrawRequest),delete this._ctx,t8(this._container),eg(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){for(var t in this._redrawBounds=null,this._layers)this._layers[t]._update();this._redraw()}},_update:function(){if(!this._map._animatingZoom||!this._bounds){iR.prototype._update.call(this);var t=this._bounds,e=this._container,i=t.getSize(),n=tN.retina?2:1;es(e,t.min),e.width=n*i.x,e.height=n*i.y,e.style.width=i.x+"px",e.style.height=i.y+"px",tN.retina&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){iR.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[y(t)]=t;var e=t._order={layer:t,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=e),this._drawLast=e,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(t){this._requestRedraw(t)},_removePath:function(t){var e=t._order,i=e.next,n=e.prev;i?i.prev=n:this._drawLast=n,n?n.next=i:this._drawFirst=i,delete t._order,delete this._layers[y(t)],this._requestRedraw(t)},_updatePath:function(t){this._extendRedrawBounds(t),t._project(),t._update(),this._requestRedraw(t)},_updateStyle:function(t){this._updateDashArray(t),this._requestRedraw(t)},_updateDashArray:function(t){if("string"==typeof t.options.dashArray){var e,i,n=t.options.dashArray.split(/[, ]+/),o=[];for(i=0;i')}}catch(t){}return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),iN=tN.vml?iB:tr,iD=iR.extend({_initContainer:function(){this._container=iN("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=iN("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){t8(this._container),eg(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!this._map._animatingZoom||!this._bounds){iR.prototype._update.call(this);var t=this._bounds,e=t.getSize(),i=this._container;this._svgSize&&this._svgSize.equals(e)||(this._svgSize=e,i.setAttribute("width",e.x),i.setAttribute("height",e.y)),es(i,t.min),i.setAttribute("viewBox",[t.min.x,t.min.y,e.x,e.y].join(" ")),this.fire("update")}},_initPath:function(t){var e=t._path=iN("path");t.options.className&&t7(e,t.options.className),t.options.interactive&&t7(e,"leaflet-interactive"),this._updateStyle(t),this._layers[y(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){t8(t._path),t.removeInteractiveTarget(t._path),delete this._layers[y(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var e=t._path,i=t.options;e&&(i.stroke?(e.setAttribute("stroke",i.color),e.setAttribute("stroke-opacity",i.opacity),e.setAttribute("stroke-width",i.weight),e.setAttribute("stroke-linecap",i.lineCap),e.setAttribute("stroke-linejoin",i.lineJoin),i.dashArray?e.setAttribute("stroke-dasharray",i.dashArray):e.removeAttribute("stroke-dasharray"),i.dashOffset?e.setAttribute("stroke-dashoffset",i.dashOffset):e.removeAttribute("stroke-dashoffset")):e.setAttribute("stroke","none"),i.fill?(e.setAttribute("fill",i.fillColor||i.color),e.setAttribute("fill-opacity",i.fillOpacity),e.setAttribute("fill-rule",i.fillRule||"evenodd")):e.setAttribute("fill","none"))},_updatePoly:function(t,e){this._setPath(t,ts(t._parts,e))},_updateCircle:function(t){var e=t._point,i=Math.max(Math.round(t._radius),1),n=Math.max(Math.round(t._radiusY),1)||i,o="a"+i+","+n+" 0 1,0 ",r=t._empty()?"M0 0":"M"+(e.x-i)+","+e.y+o+2*i+",0 "+o+-(2*i)+",0 ";this._setPath(t,r)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){t6(t._path)},_bringToBack:function(t){t4(t._path)}});function iF(t){return tN.svg||tN.vml?new iD(t):null}tN.vml&&iD.include({_initContainer:function(){this._container=t3("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(iR.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var e=t._container=iB("shape");t7(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=iB("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[y(t)]=t},_addPath:function(t){var e=t._container;this._container.appendChild(e),t.options.interactive&&t.addInteractiveTarget(e)},_removePath:function(t){var e=t._container;t8(e),t.removeInteractiveTarget(e),delete this._layers[y(t)]},_updateStyle:function(t){var e=t._stroke,i=t._fill,n=t.options,o=t._container;o.stroked=!!n.stroke,o.filled=!!n.fill,n.stroke?(e||(e=t._stroke=iB("stroke")),o.appendChild(e),e.weight=n.weight+"px",e.color=n.color,e.opacity=n.opacity,n.dashArray?e.dashStyle=A(n.dashArray)?n.dashArray.join(" "):n.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=n.lineCap.replace("butt","flat"),e.joinstyle=n.lineJoin):e&&(o.removeChild(e),t._stroke=null),n.fill?(i||(i=t._fill=iB("fill")),o.appendChild(i),i.color=n.fillColor||n.color,i.opacity=n.fillOpacity):i&&(o.removeChild(i),t._fill=null)},_updateCircle:function(t){var e=t._point.round(),i=Math.round(t._radius),n=Math.round(t._radiusY||i);this._setPath(t,t._empty()?"M0 0":"AL "+e.x+","+e.y+" "+i+","+n+" 0,23592600")},_setPath:function(t,e){t._path.v=e},_bringToFront:function(t){t6(t._container)},_bringToBack:function(t){t4(t._container)}}),ez.include({getRenderer:function(t){var e=t.options.renderer||this._getPaneRenderer(t.options.pane)||this.options.renderer||this._renderer;return e||(e=this._renderer=this._createRenderer()),this.hasLayer(e)||this.addLayer(e),e},_getPaneRenderer:function(t){if("overlayPane"===t||void 0===t)return!1;var e=this._paneRenderers[t];return void 0===e&&(e=this._createRenderer({pane:t}),this._paneRenderers[t]=e),e},_createRenderer:function(t){return this.options.preferCanvas&&ij(t)||iF(t)}});var iW=iu.extend({initialize:function(t,e){iu.prototype.initialize.call(this,this._boundsToLatLngs(t),e)},setBounds:function(t){return this.setLatLngs(this._boundsToLatLngs(t))},_boundsToLatLngs:function(t){return[(t=Y(t)).getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});iD.create=iN,iD.pointsToPath=ts,ic.geometryToLayer=ip,ic.coordsToLatLng=i_,ic.coordsToLatLngs=im,ic.latLngToCoords=ig,ic.latLngsToCoords=iy,ic.getFeature=iv,ic.asFeature=ib,ez.mergeOptions({boxZoom:!0});var iU=eF.extend({initialize:function(t){this._map=t,this._container=t._container,this._pane=t._panes.overlayPane,this._resetStateTimeout=0,t.on("unload",this._destroy,this)},addHooks:function(){ef(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){eg(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){t8(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){0!==this._resetStateTimeout&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(t){if(!t.shiftKey||1!==t.which&&1!==t.button)return!1;this._clearDeferredResetState(),this._resetState(),n(),el(),this._startPoint=this._map.mouseEventToContainerPoint(t),ef(document,{contextmenu:eE,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=t3("div","leaflet-zoom-box",this._container),t7(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var e=new q(this._point,this._startPoint),i=e.getSize();es(this._box,e.min),this._box.style.width=i.x+"px",this._box.style.height=i.y+"px"},_finish:function(){this._moved&&(t8(this._box),et(this._container,"leaflet-crosshair")),o(),eu(),eg(document,{contextmenu:eE,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(t){if((1===t.which||1===t.button)&&(this._finish(),this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(m(this._resetState,this),0);var e=new $(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(e).fire("boxzoomend",{boxZoomBounds:e})}},_onKeyDown:function(t){27===t.keyCode&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});ez.addInitHook("addHandler","boxZoom",iU),ez.mergeOptions({doubleClickZoom:!0});var iH=eF.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(t){var e=this._map,i=e.getZoom(),n=e.options.zoomDelta,o=t.originalEvent.shiftKey?i-n:i+n;"center"===e.options.doubleClickZoom?e.setZoom(o):e.setZoomAround(t.containerPoint,o)}});ez.addInitHook("addHandler","doubleClickZoom",iH),ez.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var iG=eF.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new eU(t._mapPane,t._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),t.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),t.on("zoomend",this._onZoomEnd,this),t.whenReady(this._onZoomEnd,this))}t7(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){et(this._map._container,"leaflet-grab"),et(this._map._container,"leaflet-touch-drag"),this._draggable.disable()},moved:function(){return this._draggable&&this._draggable._moved},moving:function(){return this._draggable&&this._draggable._moving},_onDragStart:function(){var t=this._map;if(t._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var e=Y(this._map.options.maxBounds);this._offsetLimit=V(this._map.latLngToContainerPoint(e.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(e.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;t.fire("movestart").fire("dragstart"),t.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(t){if(this._map.options.inertia){var e=this._lastTime=+new Date,i=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(i),this._times.push(e),this._prunePositions(e)}this._map.fire("move",t).fire("drag",t)},_prunePositions:function(t){for(;this._positions.length>1&&t-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var t=this._map.getSize().divideBy(2),e=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=e.subtract(t).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(t,e){return t-(t-e)*this._viscosity},_onPreDragLimit:function(){if(this._viscosity&&this._offsetLimit){var t=this._draggable._newPos.subtract(this._draggable._startPos),e=this._offsetLimit;t.xe.max.x&&(t.x=this._viscousLimit(t.x,e.max.x)),t.y>e.max.y&&(t.y=this._viscousLimit(t.y,e.max.y)),this._draggable._newPos=this._draggable._startPos.add(t)}},_onPreDragWrap:function(){var t=this._worldWidth,e=Math.round(t/2),i=this._initialWorldOffset,n=this._draggable._newPos.x,o=(n-e+i)%t+e-i,r=(n+e+i)%t-e-i;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=Math.abs(o+i)0?o:-o))-e;this._delta=0,this._startTime=null,r&&("center"===t.options.scrollWheelZoom?t.setZoom(e+r):t.setZoomAround(this._lastMousePos,e+r))}});ez.addInitHook("addHandler","scrollWheelZoom",iV),ez.mergeOptions({tapHold:tN.touchNative&&tN.safari&&tN.mobile,tapTolerance:15});var i$=eF.extend({addHooks:function(){ef(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){eg(this._map._container,"touchstart",this._onDown,this)},_onDown:function(t){if(clearTimeout(this._holdTimeout),1===t.touches.length){var e=t.touches[0];this._startPos=this._newPos=new U(e.clientX,e.clientY),this._holdTimeout=setTimeout(m(function(){this._cancel(),this._isTapValid()&&(ef(document,"touchend",eT),ef(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",e))},this),600),ef(document,"touchend touchcancel contextmenu",this._cancel,this),ef(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function t(){eg(document,"touchend",eT),eg(document,"touchend touchcancel",t)},_cancel:function(){clearTimeout(this._holdTimeout),eg(document,"touchend touchcancel contextmenu",this._cancel,this),eg(document,"touchmove",this._onMove,this)},_onMove:function(t){var e=t.touches[0];this._newPos=new U(e.clientX,e.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(t,e){var i=new MouseEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:e.screenX,screenY:e.screenY,clientX:e.clientX,clientY:e.clientY});i._simulated=!0,e.target.dispatchEvent(i)}});ez.addInitHook("addHandler","tapHold",i$),ez.mergeOptions({touchZoom:tN.touch,bounceAtZoomLimits:!0});var iY=eF.extend({addHooks:function(){t7(this._map._container,"leaflet-touch-zoom"),ef(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){et(this._map._container,"leaflet-touch-zoom"),eg(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(t){var e=this._map;if(t.touches&&2===t.touches.length&&!e._animatingZoom&&!this._zooming){var i=e.mouseEventToContainerPoint(t.touches[0]),n=e.mouseEventToContainerPoint(t.touches[1]);this._centerPoint=e.getSize()._divideBy(2),this._startLatLng=e.containerPointToLatLng(this._centerPoint),"center"!==e.options.touchZoom&&(this._pinchStartLatLng=e.containerPointToLatLng(i.add(n)._divideBy(2))),this._startDist=i.distanceTo(n),this._startZoom=e.getZoom(),this._moved=!1,this._zooming=!0,e._stop(),ef(document,"touchmove",this._onTouchMove,this),ef(document,"touchend touchcancel",this._onTouchEnd,this),eT(t)}},_onTouchMove:function(t){if(t.touches&&2===t.touches.length&&this._zooming){var e=this._map,i=e.mouseEventToContainerPoint(t.touches[0]),n=e.mouseEventToContainerPoint(t.touches[1]),o=i.distanceTo(n)/this._startDist;if(this._zoom=e.getScaleZoom(o,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoome.getMaxZoom()&&o>1)&&(this._zoom=e._limitZoom(this._zoom)),"center"===e.options.touchZoom){if(this._center=this._startLatLng,1===o)return}else{var r=i._add(n)._divideBy(2)._subtract(this._centerPoint);if(1===o&&0===r.x&&0===r.y)return;this._center=e.unproject(e.project(this._pinchStartLatLng,this._zoom).subtract(r),this._zoom)}this._moved||(e._moveStart(!0,!1),this._moved=!0),N(this._animRequest);var s=m(e._move,e,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=B(s,this,!0),eT(t)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,N(this._animRequest),eg(document,"touchmove",this._onTouchMove,this),eg(document,"touchend touchcancel",this._onTouchEnd,this),this._map.options.zoomAnimation?this._map._animateZoom(this._center,this._map._limitZoom(this._zoom),!0,this._map.options.zoomSnap):this._map._resetView(this._center,this._map._limitZoom(this._zoom))}});ez.addInitHook("addHandler","touchZoom",iY),ez.BoxZoom=iU,ez.DoubleClickZoom=iH,ez.Drag=iG,ez.Keyboard=iq,ez.ScrollWheelZoom=iV,ez.TapHold=i$,ez.TouchZoom=iY;var iK=i({__proto__:null,version:"1.9.0+main.a7e1bbcb",Control:eR,control:eZ,Class:D,Handler:eF,extend:i,bind:m,stamp:y,setOptions:E,Browser:tN,Evented:W,Mixin:{Events:F},Util:{__proto__:null,extend:i,create:f,bind:m,get lastId(){return g},stamp:y,throttle:v,wrapNum:b,falseFn:w,formatNum:x,trim:P,splitWords:T,setOptions:E,getParamString:S,template:M,isArray:A,indexOf:O,emptyImageUrl:C,requestFn:Z,cancelFn:j,requestAnimFrame:B,cancelAnimFrame:N},PosAnimation:eC,Draggable:eU,DomEvent:{__proto__:null,on:ef,off:eg,stopPropagation:ex,disableScrollPropagation:eP,disableClickPropagation:eL,preventDefault:eT,stop:eE,getPropagationPath:eS,getMousePosition:ek,getWheelDelta:eA,isExternalTarget:eO,addListener:ef,removeListener:eg},DomUtil:{__proto__:null,TRANSFORM:tJ,TRANSITION:tQ,TRANSITION_END:t0,get:t1,getStyle:t2,create:t3,remove:t8,empty:t5,toFront:t6,toBack:t4,hasClass:t9,addClass:t7,removeClass:et,setClass:ee,getClass:ei,setOpacity:en,testProp:eo,setTransform:er,setPosition:es,getPosition:ea,get disableTextSelection(){return n},get enableTextSelection(){return o},disableImageDrag:el,enableImageDrag:eu,preventOutline:ec,restoreOutline:ep,getSizedParentNode:ed,getScale:e_},Point:U,point:G,Bounds:q,bounds:V,Transformation:te,transformation:ti,LineUtil:{__proto__:null,simplify:eH,pointToSegmentDistance:eG,closestPointOnSegment:function(t,e,i){return eY(t,e,i)},clipSegment:eq,_getEdgeIntersection:eV,_getBitCode:e$,_sqClosestPointOnSegment:eY,isFlat:eK,_flat:eX,polylineCenter:eJ},PolyUtil:{__proto__:null,clipPolygon:eQ,polygonCenter:e0},LatLng:K,latLng:X,LatLngBounds:$,latLngBounds:Y,CRS:J,Projection:{__proto__:null,LonLat:e1,Mercator:e2,SphericalMercator:tt},Layer:e6,LayerGroup:e4,layerGroup:function(t,e){return new e4(t,e)},FeatureGroup:e9,featureGroup:function(t,e){return new e9(t,e)},ImageOverlay:iP,imageOverlay:function(t,e,i){return new iP(t,e,i)},VideoOverlay:iL,videoOverlay:function(t,e,i){return new iL(t,e,i)},SVGOverlay:iT,svgOverlay:function(t,e,i){return new iT(t,e,i)},DivOverlay:iE,Popup:iS,popup:function(t,e){return new iS(t,e)},Tooltip:ik,tooltip:function(t,e){return new ik(t,e)},icon:it,DivIcon:iM,divIcon:iA,Marker:io,marker:ir,Icon:e7,GridLayer:iO,gridLayer:function(t){return new iO(t)},TileLayer:iC,tileLayer:iz,Renderer:iR,Canvas:iZ,canvas:ij,Path:is,CircleMarker:ia,circleMarker:function(t,e){return new ia(t,e)},Circle:ih,circle:function(t,e,i){return new ih(t,e,i)},Polyline:il,polyline:function(t,e){return new il(t,e)},Polygon:iu,polygon:function(t,e){return new iu(t,e)},Rectangle:iW,rectangle:function(t,e){return new iW(t,e)},SVG:iD,svg:iF,GeoJSON:ic,geoJSON:ix,geoJson:ix,Map:ez,map:eI},{noConflict:function(){return iX.L=iJ,iK}}),iX=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r)return r;throw Error("Unable to locate global object.")}(),iJ=iX.L;iX.L=iK}),c("1zENl",function(t,e){var i=u("5A49f"),n=u("hDtVy"),o=u("9RC8m"),r=u("2BaZq"),s=u("5Ox6r"),a=u("eEkyn"),h=u("hFSMY"),l=Function,c=function(t){try{return l('"use strict"; return ('+t+").constructor;")()}catch(t){}},p=Object.getOwnPropertyDescriptor;if(p)try{p({},"")}catch(t){p=null}var d=function(){throw new a},_=p?function(){try{return arguments.callee,d}catch(t){try{return p(arguments,"callee").get}catch(t){return d}}}():d,f=u("24qIq")(),m=u("dSRh6")(),g=Object.getPrototypeOf||(m?function(t){return t.__proto__}:null),y={},v="undefined"!=typeof Uint8Array&&g?g(Uint8Array):void 0,b={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?void 0:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"%ArrayIteratorPrototype%":f&&g?g([][Symbol.iterator]()):void 0,"%AsyncFromSyncIteratorPrototype%":void 0,"%AsyncFunction%":y,"%AsyncGenerator%":y,"%AsyncGeneratorFunction%":y,"%AsyncIteratorPrototype%":y,"%Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"%BigInt%":"undefined"==typeof BigInt?void 0:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?void 0:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?void 0:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?void 0:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":i,"%eval%":eval,"%EvalError%":n,"%Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?void 0:FinalizationRegistry,"%Function%":l,"%GeneratorFunction%":y,"%Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":f&&g?g(g([][Symbol.iterator]())):void 0,"%JSON%":"object"==typeof JSON?JSON:void 0,"%Map%":"undefined"==typeof Map?void 0:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f&&g?g(new Map()[Symbol.iterator]()):void 0,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?void 0:Promise,"%Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"%RangeError%":o,"%ReferenceError%":r,"%Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?void 0:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f&&g?g(new Set()[Symbol.iterator]()):void 0,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f&&g?g(""[Symbol.iterator]()):void 0,"%Symbol%":f?Symbol:void 0,"%SyntaxError%":s,"%ThrowTypeError%":_,"%TypedArray%":v,"%TypeError%":a,"%Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"%URIError%":h,"%WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?void 0:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet};if(g)try{null.error}catch(t){var w=g(g(t));b["%Error.prototype%"]=w}var x=function t(e){var i;if("%AsyncFunction%"===e)i=c("async function () {}");else if("%GeneratorFunction%"===e)i=c("function* () {}");else if("%AsyncGeneratorFunction%"===e)i=c("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(i=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var o=t("%AsyncGenerator%");o&&g&&(i=g(o.prototype))}return b[e]=i,i},P={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},T=u("gvair"),E=u("4c4Ky"),S=T.call(Function.call,Array.prototype.concat),k=T.call(Function.apply,Array.prototype.splice),M=T.call(Function.call,String.prototype.replace),A=T.call(Function.call,String.prototype.slice),O=T.call(Function.call,RegExp.prototype.exec),C=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,z=/\\(\\)?/g,I=function(t){var e=A(t,0,1),i=A(t,-1);if("%"===e&&"%"!==i)throw new s("invalid intrinsic syntax, expected closing `%`");if("%"===i&&"%"!==e)throw new s("invalid intrinsic syntax, expected opening `%`");var n=[];return M(t,C,function(t,e,i,o){n[n.length]=i?M(o,z,"$1"):e||t}),n},R=function(t,e){var i,n=t;if(E(P,n)&&(n="%"+(i=P[n])[0]+"%"),E(b,n)){var o=b[n];if(o===y&&(o=x(n)),void 0===o&&!e)throw new a("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:i,name:n,value:o}}throw new s("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new a("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new a('"allowMissing" argument must be a boolean');if(null===O(/^%?[^%]*%?$/,t))throw new s("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var i=I(t),n=i.length>0?i[0]:"",o=R("%"+n+"%",e),r=o.name,h=o.value,l=!1,u=o.alias;u&&(n=u[0],k(i,S([0,1],u)));for(var c=1,d=!0;c=i.length){var g=p(h,_);h=(d=!!g)&&"get"in g&&!("originalValue"in g.get)?g.get:h[_]}else d=E(h,_),h=h[_];d&&!l&&(b[r]=h)}}return h}}),c("5A49f",function(t,e){t.exports=Error}),c("hDtVy",function(t,e){t.exports=EvalError}),c("9RC8m",function(t,e){t.exports=RangeError}),c("2BaZq",function(t,e){t.exports=ReferenceError}),c("5Ox6r",function(t,e){t.exports=SyntaxError}),c("eEkyn",function(t,e){t.exports=TypeError}),c("hFSMY",function(t,e){t.exports=URIError}),c("24qIq",function(t,e){var i="undefined"!=typeof Symbol&&Symbol,n=u("7YWkK");t.exports=function(){return"function"==typeof i&&"function"==typeof Symbol&&"symbol"==typeof i("foo")&&"symbol"==typeof Symbol("bar")&&n()}}),c("7YWkK",function(t,e){t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),i=Object(e);if("string"==typeof e||"[object Symbol]"!==Object.prototype.toString.call(e)||"[object Symbol]"!==Object.prototype.toString.call(i))return!1;for(e in t[e]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var n=Object.getOwnPropertySymbols(t);if(1!==n.length||n[0]!==e||!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(t,e);if(42!==o.value||!0!==o.enumerable)return!1}return!0}}),c("dSRh6",function(t,e){var i={foo:{}},n=Object;t.exports=function(){return({__proto__:i}).foo===i.foo&&!(({__proto__:null})instanceof n)}}),c("gvair",function(t,e){var i=u("kAGnA");t.exports=Function.prototype.bind||i}),c("kAGnA",function(t,e){var i=Object.prototype.toString,n=Math.max,o=function(t,e){for(var i=[],n=0;n=0&&"[object Function]"===i.call(t.callee)),n}}),c("4nFCC",function(t,e){var i;if(!Object.keys){var n=Object.prototype.hasOwnProperty,o=Object.prototype.toString,r=u("z1gio"),s=Object.prototype.propertyIsEnumerable,a=!s.call({toString:null},"toString"),h=s.call(function(){},"prototype"),l=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],c=function(t){var e=t.constructor;return e&&e.prototype===t},p={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},d=function(){if("undefined"==typeof window)return!1;for(var t in window)try{if(!p["$"+t]&&n.call(window,t)&&null!==window[t]&&"object"==typeof window[t])try{c(window[t])}catch(t){return!0}}catch(t){return!0}return!1}(),_=function(t){if("undefined"==typeof window||!d)return c(t);try{return c(t)}catch(t){return!1}};i=function(t){var e=null!==t&&"object"==typeof t,i="[object Function]"===o.call(t),s=r(t),u=e&&"[object String]"===o.call(t),c=[];if(!e&&!i&&!s)throw TypeError("Object.keys called on a non-object");var p=h&&i;if(u&&t.length>0&&!n.call(t,0))for(var d=0;d0)for(var f=0;f-1?n(r):r}}),c("cOB0F",function(t,e){var i=u("gvair"),n=u("1zENl"),o=u("BPe9e"),r=u("eEkyn"),s=n("%Function.prototype.apply%"),a=n("%Function.prototype.call%"),h=n("%Reflect.apply%",!0)||i.call(a,s),l=u("jAy3M"),c=n("%Math.max%");t.exports=function(t){if("function"!=typeof t)throw new r("a function is required");var e=h(i,a,arguments);return o(e,1+c(0,t.length-(arguments.length-1)),!0)};var p=function(){return h(i,s,arguments)};l?l(t.exports,"apply",{value:p}):t.exports.apply=p}),c("BPe9e",function(t,e){var i=u("1zENl"),n=u("5FEEt"),o=u("i16wS")(),r=u("dYOee"),s=u("eEkyn"),a=i("%Math.floor%");t.exports=function(t,e){if("function"!=typeof t)throw new s("`fn` is not a function");if("number"!=typeof e||e<0||e>4294967295||a(e)!==e)throw new s("`length` must be a positive 32-bit integer");var i=arguments.length>2&&!!arguments[2],h=!0,l=!0;if("length"in t&&r){var u=r(t,"length");u&&!u.configurable&&(h=!1),u&&!u.writable&&(l=!1)}return(h||l||!i)&&(o?n(t,"length",e,!0,!0):n(t,"length",e)),t}}),c("5FEEt",function(t,e){var i=u("jAy3M"),n=u("5Ox6r"),o=u("eEkyn"),r=u("dYOee");t.exports=function(t,e,s){if(!t||"object"!=typeof t&&"function"!=typeof t)throw new o("`obj` must be an object or a function`");if("string"!=typeof e&&"symbol"!=typeof e)throw new o("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new o("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new o("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new o("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new o("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,h=arguments.length>4?arguments[4]:null,l=arguments.length>5?arguments[5]:null,u=arguments.length>6&&arguments[6],c=!!r&&r(t,e);if(i)i(t,e,{configurable:null===l&&c?c.configurable:!l,enumerable:null===a&&c?c.enumerable:!a,value:s,writable:null===h&&c?c.writable:!h});else if(!u&&(a||h||l))throw new n("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");else t[e]=s}}),c("dYOee",function(t,e){var i=u("1zENl")("%Object.getOwnPropertyDescriptor%",!0);if(i)try{i([],"length")}catch(t){i=null}t.exports=i});var p=u("lzbil");(t=i||(i={}))[t.PING=0]="PING",t[t.PONG=1]="PONG",t[t.SUBSCRIBE=2]="SUBSCRIBE",t[t.POINT=3]="POINT",t[t.LOG=4]="LOG",t[t.DISTANCE=5]="DISTANCE";var d={},_={};function f(t){return(f="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})(t)}function m(t,e){if(!(t instanceof e))throw TypeError("Cannot call a class as a function")}function g(t,e){for(var i=0;it.length)&&(e=t.length);for(var i=0,n=Array(e);i{this._isPending=!0,this._resolve=t,this._reject=e})}_handleTimeout(){let t=z(this._options.timeoutReason),e="string"==typeof t?t.replace("{timeout}",this._options.timeout):"",i=new I.TimeoutError(e);this.reject(i)}_createTimer(){this._options.timeout&&(this._timer=setTimeout(()=>this._handleTimeout(),this._options.timeout))}_clearTimer(){this._timer&&(clearTimeout(this._timer),this._timer=null)}_settle(t){this._isPending=!1,this._value=t,this._clearTimer()}_callFn(t){if("function"==typeof t)try{let e=t();this._tryAttachToPromise(e)}catch(t){this.reject(t)}}_tryAttachToPromise(t){O(t)&&t.then(t=>this.resolve(t),t=>this.reject(t))}}I.TimeoutError=C("TimeoutError"),I.ResetError=C("ResetError"),M=I;var R={};Object.defineProperty(R,"__esModule",{value:!0}),R.PromisedMap=void 0;var Z=function(){function t(){this.map=new Map}return Object.defineProperty(t.prototype,"size",{get:function(){return this.map.size},enumerable:!1,configurable:!0}),t.prototype.set=function(t,e){var i=this.createMapItem(e);return this.map.set(t,i),i.promise},t.prototype.get=function(t){var e=this.map.get(t);return e&&e.data},t.prototype.has=function(t){return this.map.has(t)},t.prototype.delete=function(t){return this.map.delete(t)},t.prototype.resolve=function(t,e){var i=this.map.get(t);i&&(this.delete(t),i.resolve(e))},t.prototype.reject=function(t,e){var i=this.map.get(t);i&&(this.delete(t),i.reject(e))},t.prototype.resolveAll=function(t){this.map.forEach(function(e){return e.resolve(t)}),this.map.clear()},t.prototype.rejectAll=function(t){this.map.forEach(function(e){return e.reject(t)}),this.map.clear()},t.prototype.forEach=function(t){this.map.forEach(function(e,i,n){return t(e.data,i,n)})},t.prototype.clear=function(){return this.map.clear()},t.prototype.createMapItem=function(t){var e={data:t};return e.promise=new Promise(function(t,i){e.resolve=t,e.reject=i}),e},t}();R.PromisedMap=Z;var j=R.PromisedMap,B={},N={},D=u("cOB0F"),F={},W={},U=Array.prototype.slice,H=u("z1gio"),G=Object.keys,q=G?function(t){return G(t)}:u("4nFCC"),V=Object.keys;q.shim=function(){return Object.keys?!function(){var t=Object.keys(arguments);return t&&t.length===arguments.length}(1,2)&&(Object.keys=function(t){return H(t)?V(U.call(t)):V(t)}):Object.keys=q,Object.keys||q},W=q;var $="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),Y=Object.prototype.toString,K=Array.prototype.concat,X=Object.defineProperty,J=u("i16wS")(),Q=X&&J,tt=function(t,e,i,n){if(e in t){if(!0===n){if(t[e]===i)return}else if(!("function"==typeof n&&"[object Function]"===Y.call(n))||!n())return}Q?X(t,e,{configurable:!0,enumerable:!1,value:i,writable:!0}):t[e]=i},te=function(t,e){var i=arguments.length>2?arguments[2]:{},n=W(e);$&&(n=K.call(n,Object.getOwnPropertySymbols(e)));for(var o=0;o=0&&t["[[EndIndex]]"]>=t["[[StartIndex]]"]&&String(parseInt(t["[[StartIndex]]"],10))===String(t["[[StartIndex]]"])&&String(parseInt(t["[[EndIndex]]"],10))===String(t["[[EndIndex]]"])},"Iterator Record":function(t){return td(t,"[[Iterator]]")&&td(t,"[[NextMethod]]")&&td(t,"[[Done]]")},"PromiseCapability Record":function(t){return!!t&&td(t,"[[Resolve]]")&&"function"==typeof t["[[Resolve]]"]&&td(t,"[[Reject]]")&&"function"==typeof t["[[Reject]]"]&&td(t,"[[Promise]]")&&t["[[Promise]]"]&&"function"==typeof t["[[Promise]]"].then},"AsyncGeneratorRequest Record":function(t){return!!t&&td(t,"[[Completion]]")&&td(t,"[[Capability]]")&&tA["PromiseCapability Record"](t["[[Capability]]"])},"RegExp Record":function(t){return t&&td(t,"[[IgnoreCase]]")&&"boolean"==typeof t["[[IgnoreCase]]"]&&td(t,"[[Multiline]]")&&"boolean"==typeof t["[[Multiline]]"]&&td(t,"[[DotAll]]")&&"boolean"==typeof t["[[DotAll]]"]&&td(t,"[[Unicode]]")&&"boolean"==typeof t["[[Unicode]]"]&&td(t,"[[CapturingGroupsCount]]")&&"number"==typeof t["[[CapturingGroupsCount]]"]&&tT(t["[[CapturingGroupsCount]]"])&&t["[[CapturingGroupsCount]]"]>=0}};tx=function(t,e,i,n){var o=tA[e];if("function"!=typeof o)throw new tL("unknown record type: "+e);if("Object"!==t(n)||!o(n))throw new tP(i+" must be a "+e)};var tO={};tO=function(t){if(void 0===t)return t;var e={};return"[[Value]]"in t&&(e.value=t["[[Value]]"]),"[[Writable]]"in t&&(e.writable=!!t["[[Writable]]"]),"[[Get]]"in t&&(e.get=t["[[Get]]"]),"[[Set]]"in t&&(e.set=t["[[Set]]"]),"[[Enumerable]]"in t&&(e.enumerable=!!t["[[Enumerable]]"]),"[[Configurable]]"in t&&(e.configurable=!!t["[[Configurable]]"]),e};var tC={},tz={};tz=function(t){return null===t?"Null":void 0===t?"Undefined":"function"==typeof t||"object"==typeof t?"Object":"number"==typeof t?"Number":"boolean"==typeof t?"Boolean":"string"==typeof t?"String":void 0},tC=function(t){return"symbol"==typeof t?"Symbol":"bigint"==typeof t?"BigInt":tz(t)},tw=function(t){return void 0!==t&&tx(tC,"Property Descriptor","Desc",t),tO(t)};var tI={};tI=function(t){return void 0!==t&&(tx(tC,"Property Descriptor","Desc",t),!!(td(t,"[[Get]]")||td(t,"[[Set]]")))};var tR={};tR=function(t){return void 0!==t&&(tx(tC,"Property Descriptor","Desc",t),!!(td(t,"[[Value]]")||td(t,"[[Writable]]")))};var tZ={};tZ=function(t){return"string"==typeof t||"symbol"==typeof t};var tj={};tj=function(t,e){return t===e?0!==t||1/t==1/e:tk(t)&&tk(e)};var tB={},ts=u("1zENl"),tN=ts("%TypeError%"),tD={};tD=function(t){return!!t},tB=function(t){if("Object"!==tC(t))throw new tN("ToPropertyDescriptor requires an object");var e={};if(td(t,"enumerable")&&(e["[[Enumerable]]"]=tD(t.enumerable)),td(t,"configurable")&&(e["[[Configurable]]"]=tD(t.configurable)),td(t,"value")&&(e["[[Value]]"]=t.value),td(t,"writable")&&(e["[[Writable]]"]=tD(t.writable)),td(t,"get")){var i=t.get;if(void 0!==i&&!to(i))throw new tN("getter must be a function");e["[[Get]]"]=i}if(td(t,"set")){var n=t.set;if(void 0!==n&&!to(n))throw new tN("setter must be a function");e["[[Set]]"]=n}if((td(e,"[[Get]]")||td(e,"[[Set]]"))&&(td(e,"[[Value]]")||td(e,"[[Writable]]")))throw new tN("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return e};var tF=function(t,e,i){if("Object"!==tC(t))throw new tc("Assertion failed: Type(O) is not Object");if(!tZ(e))throw new tc("Assertion failed: IsPropertyKey(P) is not true");var n=tp({Type:tC,IsDataDescriptor:tR,IsAccessorDescriptor:tI},i)?i:tB(i);if(!tp({Type:tC,IsDataDescriptor:tR,IsAccessorDescriptor:tI},n))throw new tc("Assertion failed: Desc is not a valid Property Descriptor");return tf(tR,tj,tw,t,e,n)};try{tF({},"",{"[[Get]]":function(){}})}catch(t){tF=null}if(tF&&tu){var tW={},tU={};tF(tU,"length",{"[[Get]]":function(){throw tW},"[[Enumerable]]":!0}),tl=function(t){try{tu(t,tU)}catch(t){return t===tW}}}else tl=function(t){return"function"==typeof t&&!!t.prototype};tr=function(t,e){if("Object"!==tC(t))throw new th("Assertion failed: Type(O) is not Object");var i=t.constructor;if(void 0===i)return e;if("Object"!==tC(i))throw new th("O.constructor is not an Object");var n=ta?i[ta]:void 0;if(null==n)return e;if(tl(n))return n;throw new th("no constructor found")};var tH=function(t,e){return new t(function(t){t(e)})},tG=Promise,tq=function(t){if("Object"!==tC(this))throw TypeError("receiver is not an Object");var e=tr(this,tG),i=t,n=t;return to(t)&&(i=function(i){return tH(e,t()).then(function(){return i})},n=function(i){return tH(e,t()).then(function(){throw i})}),this.then(i,n)};if(Object.getOwnPropertyDescriptor){var tV=Object.getOwnPropertyDescriptor(tq,"name");tV&&tV.configurable&&Object.defineProperty(tq,"name",{configurable:!0,value:"finally"})}ti=tq;var t$={};t$=function(){return tn(),"function"==typeof Promise.prototype.finally?Promise.prototype.finally:ti};var tY={};tY=function(){tn();var t=t$();return F(Promise.prototype,{finally:t},{finally:function(){return Promise.prototype.finally!==t}}),t};var tK=D(t$());F(tK,{getPolyfill:t$,implementation:ti,shim:tY}),N=tK,B=class{constructor(){this._items=new Map}create(t,e,i){return this._rejectExistingRequest(t),this._createNewRequest(t,e,i)}resolve(t,e){t&&this._items.has(t)&&this._items.get(t).resolve(e)}rejectAll(t){this._items.forEach(e=>e.isPending?e.reject(t):null)}_rejectExistingRequest(t){let e=this._items.get(t);e&&e.isPending&&e.reject(Error(`WebSocket request is replaced, id: ${t}`))}_createNewRequest(t,e,i){let n=new M({timeout:i,timeoutReason:`WebSocket request was rejected by timeout (${i} ms). RequestId: ${t}`});return this._items.set(t,n),N(n.call(e),()=>this._deleteRequest(t,n))}_deleteRequest(t,e){this._items.get(t)===e&&this._items.delete(t)}};var tX={};tX={createWebSocket:t=>new WebSocket(t),packMessage:null,unpackMessage:null,attachRequestId:null,extractRequestId:null,extractMessageData:t=>t.data,timeout:0,connectionTimeout:0};var tJ=(t,e)=>{if(t)throw Error(e)},tQ=t=>t&&"function"==typeof t.then;const t0={CONNECTING:0,OPEN:1,CLOSING:2,CLOSED:3};d=class{constructor(t,e){this._assertOptions(e),this._url=t,this._options=Object.assign({},tX,e),this._requests=new B,this._promisedMap=new j,this._ws=null,this._wsSubscription=null,this._createOpeningController(),this._createClosingController(),this._createChannels()}get ws(){return this._ws}get url(){return this._url}get isOpening(){return!!(this._ws&&this._ws.readyState===t0.CONNECTING)}get isOpened(){return!!(this._ws&&this._ws.readyState===t0.OPEN)}get isClosing(){return!!(this._ws&&this._ws.readyState===t0.CLOSING)}get isClosed(){return!!(!this._ws||this._ws.readyState===t0.CLOSED)}get onOpen(){return this._onOpen}get onSend(){return this._onSend}get onMessage(){return this._onMessage}get onUnpackedMessage(){return this._onUnpackedMessage}get onResponse(){return this._onResponse}get onClose(){return this._onClose}get onError(){return this._onError}open(){return this.isClosing?Promise.reject(Error("Can't open WebSocket while closing.")):this.isOpened?this._opening.promise:this._opening.call(()=>{this._opening.promise.catch(t=>this._cleanup(t)),this._createWS()})}sendRequest(t,e={}){let i=e.requestId||`${Math.random()}`,n=void 0!==e.timeout?e.timeout:this._options.timeout;return this._requests.create(i,()=>{this._assertRequestIdHandlers();let e=this._options.attachRequestId(t,i);this.sendPacked(e)},n)}sendPacked(t){this._assertPackingHandlers();let e=this._options.packMessage(t);this.send(e)}send(t){tJ(!this.isOpened,"Can't send data because WebSocket is not opened."),this._ws.send(t),this._onSend.dispatchAsync(t)}waitUnpackedMessage(t,e={}){return tJ("function"!=typeof t,`Predicate must be a function, got ${typeof t}`),e.timeout&&setTimeout(()=>{if(this._promisedMap.has(t)){let i=e.timeoutError||Error("Timeout");this._promisedMap.reject(t,i)}},e.timeout),this._promisedMap.set(t)}close(t,e){return this.isClosed?Promise.resolve(this._closing.value):this._closing.call(()=>this._ws.close(t,e))}removeAllListeners(){this._onOpen.removeAllListeners(),this._onMessage.removeAllListeners(),this._onUnpackedMessage.removeAllListeners(),this._onResponse.removeAllListeners(),this._onSend.removeAllListeners(),this._onClose.removeAllListeners(),this._onError.removeAllListeners()}_createOpeningController(){let t=this._options.connectionTimeout||this._options.timeout;this._opening=new M({timeout:t,timeoutReason:`Can't open WebSocket within allowed timeout: ${t} ms.`})}_createClosingController(){let t=this._options.timeout;this._closing=new M({timeout:t,timeoutReason:`Can't close WebSocket within allowed timeout: ${t} ms.`})}_createChannels(){this._onOpen=new _,this._onMessage=new _,this._onUnpackedMessage=new _,this._onResponse=new _,this._onSend=new _,this._onClose=new _,this._onError=new _}_createWS(){this._ws=this._options.createWebSocket(this._url),this._wsSubscription=new _.Subscription([{channel:this._ws,event:"open",listener:t=>this._handleOpen(t)},{channel:this._ws,event:"message",listener:t=>this._handleMessage(t)},{channel:this._ws,event:"error",listener:t=>this._handleError(t)},{channel:this._ws,event:"close",listener:t=>this._handleClose(t)}]).on()}_handleOpen(t){this._onOpen.dispatchAsync(t),this._opening.resolve(t)}_handleMessage(t){let e=this._options.extractMessageData(t);this._onMessage.dispatchAsync(e),this._tryUnpack(e)}_tryUnpack(t){this._options.unpackMessage&&(tQ(t=this._options.unpackMessage(t))?t.then(t=>this._handleUnpackedData(t)):this._handleUnpackedData(t))}_handleUnpackedData(t){void 0!==t&&(this._onUnpackedMessage.dispatchAsync(t),this._tryHandleResponse(t)),this._tryHandleWaitingMessage(t)}_tryHandleResponse(t){if(this._options.extractRequestId){let e=this._options.extractRequestId(t);e&&(this._onResponse.dispatchAsync(t,e),this._requests.resolve(e,t))}}_tryHandleWaitingMessage(t){this._promisedMap.forEach((e,i)=>{let n=!1;try{n=i(t)}catch(t){this._promisedMap.reject(i,t);return}n&&this._promisedMap.resolve(i,t)})}_handleError(t){this._onError.dispatchAsync(t)}_handleClose(t){this._onClose.dispatchAsync(t),this._closing.resolve(t);let e=Error(`WebSocket closed with reason: ${t.reason} (${t.code}).`);this._opening.isPending&&this._opening.reject(e),this._cleanup(e)}_cleanupWS(){this._wsSubscription&&(this._wsSubscription.off(),this._wsSubscription=null),this._ws=null}_cleanup(t){this._cleanupWS(),this._requests.rejectAll(t)}_assertOptions(t){Object.keys(t||{}).forEach(t=>{if(!tX.hasOwnProperty(t))throw Error(`Unknown option: ${t}`)})}_assertPackingHandlers(){let{packMessage:t,unpackMessage:e}=this._options;tJ(!t||!e,"Please define 'options.packMessage / options.unpackMessage' for sending packed messages.")}_assertRequestIdHandlers(){let{attachRequestId:t,extractRequestId:e}=this._options;tJ(!t||!e,"Please define 'options.attachRequestId / options.extractRequestId' for sending requests.")}};class t1{constructor(t){if(this.config=t,this.log=0,this.timestamp=0,this.pingInterval=null,this.pingTimeout=null,t.transport)this.ws=t.transport;else{let t={packMessage:t=>JSON.stringify(t),unpackMessage:t=>JSON.parse(t.toString())};console.log("ws config",t),this.ws=new(a(d))(this.config.endpoint+"?key="+this.config.accessKey,t)}this.initListeners()}initListeners(){this.ws.onUnpackedMessage.addListener(t=>{t.type===i.POINT&&(this.timestamp=t.point.timestamp,console.log("point message",t)),t.type===i.LOG&&(this.log=t.log,console.log("log message",t),this.timestamp=0),t.type===i.PONG&&(console.log("pong message",t),this.pingTimeout&&(clearTimeout(this.pingTimeout),this.pingTimeout=null)),this.config.listener(t)}),this.ws.onError.addListener(t=>{console.log("error",t),this.ws.close()}),this.ws.onClose.addListener(()=>{console.log("websocket closed"),null!==this.pingInterval&&(clearInterval(this.pingInterval),this.pingInterval=null),null!==this.pingTimeout&&(clearTimeout(this.pingTimeout),this.pingTimeout=null),setTimeout(()=>{this.open(this.log,this.timestamp)},2e3)})}async open(t,e){console.log("open websocket",t,e),this.log=t,this.timestamp=e,await this.ws.open(),this.pingInterval=setInterval(()=>{this.ws.sendPacked({type:i.PING}),null!==this.pingTimeout&&clearTimeout(this.pingTimeout),this.pingTimeout=setTimeout(()=>{console.log("pong timewout"),this.ws.close()},1e3)},3e3),this.ws.sendPacked({type:i.SUBSCRIBE,name:this.config.name,log:t,timestamp:e})}}var t2={},t3="object"==typeof Reflect?Reflect:null,t8=t3&&"function"==typeof t3.apply?t3.apply:function(t,e,i){return Function.prototype.apply.call(t,e,i)};n=t3&&"function"==typeof t3.ownKeys?t3.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var t5=Number.isNaN||function(t){return t!=t};function t6(){t6.init.call(this)}t2=t6,t2.once=function(t,e){return new Promise(function(i,n){function o(i){t.removeListener(e,r),n(i)}function r(){"function"==typeof t.removeListener&&t.removeListener("error",o),i([].slice.call(arguments))}es(t,e,r,{once:!0}),"error"!==e&&"function"==typeof t.on&&es(t,"error",o,{once:!0})})},t6.EventEmitter=t6,t6.prototype._events=void 0,t6.prototype._eventsCount=0,t6.prototype._maxListeners=void 0;var t4=10;function t9(t){if("function"!=typeof t)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof t)}function t7(t){return void 0===t._maxListeners?t6.defaultMaxListeners:t._maxListeners}function et(t,e,i,n){if(t9(i),void 0===(r=t._events)?(r=t._events=Object.create(null),t._eventsCount=0):(void 0!==r.newListener&&(t.emit("newListener",e,i.listener?i.listener:i),r=t._events),s=r[e]),void 0===s)s=r[e]=i,++t._eventsCount;else if("function"==typeof s?s=r[e]=n?[i,s]:[s,i]:n?s.unshift(i):s.push(i),(o=t7(t))>0&&s.length>o&&!s.warned){s.warned=!0;var o,r,s,a=Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");a.name="MaxListenersExceededWarning",a.emitter=t,a.type=e,a.count=s.length,console&&console.warn&&console.warn(a)}return t}function ee(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function ei(t,e,i){var n={fired:!1,wrapFn:void 0,target:t,type:e,listener:i},o=ee.bind(n);return o.listener=i,n.wrapFn=o,o}function en(t,e,i){var n=t._events;if(void 0===n)return[];var o=n[e];return void 0===o?[]:"function"==typeof o?i?[o.listener||o]:[o]:i?function(t){for(var e=Array(t.length),i=0;i0&&(r=e[0]),r instanceof Error)throw r;var r,s=Error("Unhandled error."+(r?" ("+r.message+")":""));throw s.context=r,s}var a=o[t];if(void 0===a)return!1;if("function"==typeof a)t8(a,this,e);else for(var h=a.length,l=er(a,h),i=0;i=0;r--)if(i[r]===e||i[r].listener===e){s=i[r].listener,o=r;break}if(o<0)return this;0===o?i.shift():function(t,e){for(;e+1=0;n--)this.removeListener(t,e[n]);return this},t6.prototype.listeners=function(t){return en(this,t,!0)},t6.prototype.rawListeners=function(t){return en(this,t,!1)},t6.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):eo.call(t,e)},t6.prototype.listenerCount=eo,t6.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]},(e=o||(o={}))[e.NOT_READY=0]="NOT_READY",e[e.READY=1]="READY";class ea extends a(t2){constructor(t){super(),this.config=t,this.status=o.NOT_READY,this.tracking=null,this.points=new Map,console.log("gps client config",t),this.ws=new t1({endpoint:t.wsEndpoint,accessKey:t.accessKey,name:t.name,listener:t=>{this.onMessage(t)},transport:t.transport})}async init(){let t=await fetch(this.config.apiEndpoint+"/"+this.config.name,{headers:{authorization:this.config.accessKey}});this.tracking=await t.json();let e=[];for(let t=0;t0){console.log("llog",t=this.tracking.logs[this.tracking.logs.length-1].started);let i=this.points.get(t);console.log("p",i),i&&i.length>0&&(e=i[i.length-1].timestamp)}await this.ws.open(t,e),this.status=o.READY}async updateLogs(t){console.log("update logs",t);let e=new URLSearchParams;t.forEach(t=>e.append("started",t.started.toString())),console.log("searchparams",e.toString());let i=await fetch(this.config.apiEndpoint+"/"+this.config.name+"/log?"+e.toString(),{headers:{authorization:this.config.accessKey},mode:"cors"});console.log("response",i);let n=await i.text(),o=-1,r=null;for(;;){let t=n.indexOf("\n",o+1);if(-1===t)break;let e=n.substring(o+1,t);if(o=t,e.startsWith("#log")){let t=Number(e.substring(5).trim());r=[],console.log("set points logs",t),this.points.set(t,r)}else{let t=e.split(","),i={timestamp:Number(t[0]),lat:Number(t[1]),lng:Number(t[2])};r&&r.push(i)}}}onMessage(t){if(t.type===i.LOG&&(this.points.set(t.log,[]),this.tracking)){let e={started:t.log,last:0,distance:0};this.tracking.logs.push(e),this.emit("log",e)}if(t.type===i.POINT){let e=this.points.get(t.log);e&&(e.push(t.point),this.emit("point",t.point,t.log))}if(t.type===i.DISTANCE&&this.tracking){let e=this.tracking.logs.filter(e=>e.started===t.log);e.length>0&&(e[0].distance=t.distance,this.emit("distance",e[0]))}this.emit("message",t)}}var p=u("lzbil");function eh(t,e){let i={zIndexOffset:900};if(e.icon){let t=p.icon({iconUrl:e.icon.url,iconSize:[e.icon.width,e.icon.height],iconAnchor:[e.icon.anchorX,e.icon.anchorY]});i.icon=t;let n=e.innerIcon,o="";n&&(o=``),console.log("innerSource",o);let r=e.bounce?'class="bounce"':"",s=p.divIcon({html:`
${o}
`,iconSize:[e.icon.width,e.icon.height],iconAnchor:[e.icon.anchorX,e.icon.anchorY]});i.icon=s}let n=p.marker([e.lat,e.lng],i).addTo(t);console.log("marker",n)}const el=[{name:"openstreetmap",url:"https://{s}.tile.openstreetmap.de/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'},{name:"photo",url:"https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}",attribution:"Tiles © Esri — Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community"}];async function eu(t){console.log("starting app",t);let e="https://gps.jinnytty.live/api/",i=await fetch(`${e}/config/test-map`),n=await i.json();console.log("config",n);let o=p.map("map",{}).setView([n.lat,n.lng],n.zoom),r=function(t){for(let e=0;e{let e=h.points.get(t.started);e&&(l=l.concat(e.map(t=>new p.LatLng(t.lat,t.lng))))});let u=n.lat,c=n.lng;if(l.length>0){s.push(!0);let t=l[l.length-1];u=t.lat,c=t.lng}else s.push(!1);let d=new p.Polyline(l,{color:e.color,smoothFactor:0});d.addTo(o);let _=p.icon({iconUrl:e.icon.url,iconSize:[e.icon.width,e.icon.height],iconAnchor:[e.icon.anchorX,e.icon.anchorY]}),f=p.marker([u,c],{icon:_,zIndexOffset:1001});l.length>0&&f.addTo(o),a.push(f),h.on("point",t=>{let e=new p.LatLng(t.lat,t.lng);d.addLatLng(e),f&&f.setLatLng(e)})}for(let t=0;t{let e=h.points.get(t.started);e&&(l=l.concat(e.map(t=>new p.LatLng(t.lat,t.lng))))}),l.length>0&&(r=l[l.length-1].lng,i=l[l.length-1].lat);let u=new p.Polyline(l,{color:e.color,smoothFactor:0});u.addTo(o)}if(s.length>=t&&!s[t]&&a.length>=t){let e=new p.LatLng(i,r);a[t].setLatLng(e)}}if(a.forEach(t=>t.addTo(o)),(()=>{let t=a.map(t=>t.getLatLng());o.fitBounds(p.latLngBounds(t),{maxZoom:n.zoom})})(),n.marker&&n.marker.forEach(t=>{eh(o,t)}),Array.isArray(n.markerId)){for(let t=0;t{eh(o,t)})}catch(e){console.log("unabel to display marker ",n.markerId[t])}}}const ec=new URLSearchParams(window.location.search);let ep="openstreetmap";ec.get("tile")&&(ep=ec.get("tile")),eu(ep);