forked from cal/tdf-2023-webseite
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
194 KiB
36 lines
194 KiB
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).leaflet={})}(this,(function(t){"use strict";function e(t){var e,n,i,o;for(n=1,i=arguments.length;n<i;n++)for(e in o=arguments[n])t[e]=o[e];return t}function n(t,e){var n=Array.prototype.slice;if(t.bind)return t.bind.apply(t,n.call(arguments,1));var i=n.call(arguments,2);return function(){return t.apply(e,i.length?i.concat(n.call(arguments)):arguments)}}function i(t){return"_leaflet_id"in t||(t._leaflet_id=++be),t._leaflet_id}function o(t,e,n){var i,o,s,r;return r=function(){i=!1,o&&(s.apply(n,o),o=!1)},s=function(){i?o=arguments:(t.apply(n,arguments),setTimeout(r,e),i=!0)},s}function s(t,e,n){var i=e[1],o=e[0],s=i-o;return t===i&&n?t:((t-o)%s+s)%s+o}function r(){return!1}function a(t,e){if(!1===e)return t;var n=Math.pow(10,void 0===e?6:e);return Math.round(t*n)/n}function l(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function h(t){return l(t).split(/\s+/)}function p(t,e){for(var n in Object.prototype.hasOwnProperty.call(t,"options")||(t.options=t.options?ve(t.options):{}),e)t.options[n]=e[n];return t.options}function u(t,e,n){var i=[];for(var o in t)i.push(encodeURIComponent(n?o.toUpperCase():o)+"="+encodeURIComponent(t[o]));return(e&&-1!==e.indexOf("?")?"&":"?")+i.join("&")}function c(t,e){return t.replace(ye,(function(t,n){var i=e[n];if(void 0===i)throw new Error("No value provided for variable "+t);return"function"==typeof i&&(i=i(e)),i}))}function d(t,e){for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1}function m(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}function _(t){var e=+new Date,n=Math.max(0,16-(e-we));return we=e+n,window.setTimeout(t,n)}function f(t,e,i){if(!i||Le!==_)return Le.call(window,n(t,e));t.call(e)}function g(t){t&&Pe.call(window,t)}function v(){}function b(t){if("undefined"!=typeof L&&L&&L.Mixin){t=xe(t)?t:[t];for(var e=0;e<t.length;e++)t[e]===L.Mixin.Events&&console.warn("Deprecated include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.",(new Error).stack)}}function y(t,e,n){this.x=n?Math.round(t):t,this.y=n?Math.round(e):e}function x(t,e,n){return t instanceof y?t:xe(t)?new y(t[0],t[1]):null==t?t:"object"==typeof t&&"x"in t&&"y"in t?new y(t.x,t.y):new y(t,e,n)}function I(t,e){if(t)for(var n=e?[t,e]:t,i=0,o=n.length;i<o;i++)this.extend(n[i])}function w(t,e){return!t||t instanceof I?t:new I(t,e)}function P(t,e){if(t)for(var n=e?[t,e]:t,i=0,o=n.length;i<o;i++)this.extend(n[i])}function T(t,e){return t instanceof P?t:new P(t,e)}function M(t,e,n){if(isNaN(t)||isNaN(e))throw new Error("Invalid LatLng object: ("+t+", "+e+")");this.lat=+t,this.lng=+e,void 0!==n&&(this.alt=+n)}function z(t,e,n){return t instanceof M?t:xe(t)&&"object"!=typeof t[0]?3===t.length?new M(t[0],t[1],t[2]):2===t.length?new M(t[0],t[1]):null:null==t?t:"object"==typeof t&&"lat"in t?new M(t.lat,"lng"in t?t.lng:t.lon,t.alt):void 0===e?null:new M(t,e,n)}function k(t,e,n,i){if(xe(t))return this._a=t[0],this._b=t[1],this._c=t[2],void(this._d=t[3]);this._a=t,this._b=e,this._c=n,this._d=i}function S(t,e,n,i){return new k(t,e,n,i)}function j(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function C(t,e){var n,i,o,s,r,a,l="";for(n=0,o=t.length;n<o;n++){for(i=0,s=(r=t[n]).length;i<s;i++)l+=(i?"L":"M")+(a=r[i]).x+" "+a.y;l+=e?Pn.svg?"z":"x":""}return l||"M0 0"}function R(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}function O(t,e,n){return"touchstart"===e&&N(),jn[e]?(n=jn[e].bind(this,n),t.addEventListener(Sn[e],n,!1),n):(console.warn("wrong event specified:",e),r)}function E(t,e,n){Sn[e]?t.removeEventListener(Sn[e],n,!1):console.warn("wrong event specified:",e)}function Z(t){Cn[t.pointerId]=t}function A(t){Cn[t.pointerId]&&(Cn[t.pointerId]=t)}function B(t){delete Cn[t.pointerId]}function N(){Rn||(document.addEventListener(Tn,Z,!0),document.addEventListener(Mn,A,!0),document.addEventListener(zn,B,!0),document.addEventListener(kn,B,!0),Rn=!0)}function D(t,e){if(e.pointerType!==(e.MSPOINTER_TYPE_MOUSE||"mouse")){for(var n in e.touches=[],Cn)e.touches.push(Cn[n]);e.changedTouches=[e],t(e)}}function F(t,e){e.MSPOINTER_TYPE_TOUCH&&e.pointerType===e.MSPOINTER_TYPE_TOUCH&&wt(e),D(t,e)}function H(t){var e,n,i={};for(n in t)e=t[n],i[n]=e&&e.bind?e.bind(t):e;return t=i,i.type="dblclick",i.detail=2,i.isTrusted=!1,i._simulated=!0,i}function W(t,e){function n(t){if(1===t.detail){if("mouse"!==t.pointerType&&(!t.sourceCapabilities||t.sourceCapabilities.firesTouchEvents)){var n=Pt(t);if(!n.some((function(t){return t instanceof HTMLLabelElement&&t.attributes.for}))||n.some((function(t){return t instanceof HTMLInputElement||t instanceof HTMLSelectElement}))){var s=Date.now();s-o<=On?2===++i&&e(H(t)):i=1,o=s}}}else i=t.detail}t.addEventListener("dblclick",e);var i,o=0;return t.addEventListener("click",n),{dblclick:e,simDblclick:n}}function U(t,e){t.removeEventListener("dblclick",e.dblclick),t.removeEventListener("click",e.simDblclick)}function V(t){return"string"==typeof t?document.getElementById(t):t}function q(t,e){var n=t.style[e]||t.currentStyle&&t.currentStyle[e];if((!n||"auto"===n)&&document.defaultView){var i=document.defaultView.getComputedStyle(t,null);n=i?i[e]:null}return"auto"===n?null:n}function G(t,e,n){var i=document.createElement(t);return i.className=e||"",n&&n.appendChild(i),i}function K(t){var e=t.parentNode;e&&e.removeChild(t)}function Y(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function J(t){var e=t.parentNode;e&&e.lastChild!==t&&e.appendChild(t)}function X(t){var e=t.parentNode;e&&e.firstChild!==t&&e.insertBefore(t,e.firstChild)}function $(t,e){if(void 0!==t.classList)return t.classList.contains(e);var n=nt(t);return n.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(n)}function Q(t,e){if(void 0!==t.classList)for(var n=h(e),i=0,o=n.length;i<o;i++)t.classList.add(n[i]);else if(!$(t,e)){var s=nt(t);et(t,(s?s+" ":"")+e)}}function tt(t,e){void 0!==t.classList?t.classList.remove(e):et(t,l((" "+nt(t)+" ").replace(" "+e+" "," ")))}function et(t,e){void 0===t.className.baseVal?t.className=e:t.className.baseVal=e}function nt(t){return t.correspondingElement&&(t=t.correspondingElement),void 0===t.className.baseVal?t.className:t.className.baseVal}function it(t,e){"opacity"in t.style?t.style.opacity=e:"filter"in t.style&&ot(t,e)}function ot(t,e){var n=!1,i="DXImageTransform.Microsoft.Alpha";try{n=t.filters.item(i)}catch(t){if(1===e)return}e=Math.round(100*e),n?(n.Enabled=100!==e,n.Opacity=e):t.style.filter+=" progid:"+i+"(opacity="+e+")"}function st(t){for(var e=document.documentElement.style,n=0;n<t.length;n++)if(t[n]in e)return t[n];return!1}function rt(t,e,n){var i=e||new y(0,0);t.style[En]=(Pn.ie3d?"translate("+i.x+"px,"+i.y+"px)":"translate3d("+i.x+"px,"+i.y+"px,0)")+(n?" scale("+n+")":"")}function at(t,e){t._leaflet_pos=e,Pn.any3d?rt(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px")}function lt(t){return t._leaflet_pos||new y(0,0)}function ht(){_t(window,"dragstart",wt)}function pt(){ft(window,"dragstart",wt)}function ut(t){for(;-1===t.tabIndex;)t=t.parentNode;t.style&&(ct(),Ne=t,De=t.style.outlineStyle,t.style.outlineStyle="none",_t(window,"keydown",ct))}function ct(){Ne&&(Ne.style.outlineStyle=De,Ne=void 0,De=void 0,ft(window,"keydown",ct))}function dt(t){do{t=t.parentNode}while(!(t.offsetWidth&&t.offsetHeight||t===document.body));return t}function mt(t){var e=t.getBoundingClientRect();return{x:e.width/t.offsetWidth||1,y:e.height/t.offsetHeight||1,boundingClientRect:e}}function _t(t,e,n,i){if(e&&"object"==typeof e)for(var o in e)vt(t,o,e[o],n);else for(var s=0,r=(e=h(e)).length;s<r;s++)vt(t,e[s],n,i);return this}function ft(t,e,n,i){if(1===arguments.length)gt(t),delete t[Dn];else if(e&&"object"==typeof e)for(var o in e)bt(t,o,e[o],n);else if(e=h(e),2===arguments.length)gt(t,(function(t){return-1!==d(e,t)}));else for(var s=0,r=e.length;s<r;s++)bt(t,e[s],n,i);return this}function gt(t,e){for(var n in t[Dn]){var i=n.split(/\d/)[0];e&&!e(i)||bt(t,i,null,null,n)}}function vt(t,e,n,o){var s=e+i(n)+(o?"_"+i(o):"");if(t[Dn]&&t[Dn][s])return this;var r=function(e){return n.call(o||t,e||window.event)},a=r;!Pn.touchNative&&Pn.pointer&&0===e.indexOf("touch")?r=O(t,e,r):Pn.touch&&"dblclick"===e?r=W(t,r):"addEventListener"in t?"touchstart"===e||"touchmove"===e||"wheel"===e||"mousewheel"===e?t.addEventListener(Fn[e]||e,r,!!Pn.passiveEvents&&{passive:!1}):"mouseenter"===e||"mouseleave"===e?(r=function(e){e=e||window.event,zt(t,e)&&a(e)},t.addEventListener(Fn[e],r,!1)):t.addEventListener(e,a,!1):t.attachEvent("on"+e,r),t[Dn]=t[Dn]||{},t[Dn][s]=r}function bt(t,e,n,o,s){s=s||e+i(n)+(o?"_"+i(o):"");var r=t[Dn]&&t[Dn][s];if(!r)return this;!Pn.touchNative&&Pn.pointer&&0===e.indexOf("touch")?E(t,e,r):Pn.touch&&"dblclick"===e?U(t,r):"removeEventListener"in t?t.removeEventListener(Fn[e]||e,r,!1):t.detachEvent("on"+e,r),t[Dn][s]=null}function yt(t){return t.stopPropagation?t.stopPropagation():t.originalEvent?t.originalEvent._stopped=!0:t.cancelBubble=!0,this}function xt(t){return vt(t,"wheel",yt),this}function It(t){return _t(t,"mousedown touchstart dblclick contextmenu",yt),t._leaflet_disable_click=!0,this}function wt(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Lt(t){return wt(t),yt(t),this}function Pt(t){if(t.composedPath)return t.composedPath();for(var e=[],n=t.target;n;)e.push(n),n=n.parentNode;return e}function Tt(t,e){if(!e)return new y(t.clientX,t.clientY);var n=mt(e),i=n.boundingClientRect;return new y((t.clientX-i.left)/n.x-e.clientLeft,(t.clientY-i.top)/n.y-e.clientTop)}function Mt(t){return Pn.edge?t.wheelDeltaY/2:t.deltaY&&0===t.deltaMode?-t.deltaY/Hn: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&&Math.abs(t.detail)<32765?20*-t.detail:t.detail?t.detail/-32765*60:0}function zt(t,e){var n=e.relatedTarget;if(!n)return!0;try{for(;n&&n!==t;)n=n.parentNode}catch(t){return!1}return n!==t}function kt(t,e){return new Vn(t,e)}function St(t,e,n){var i,o,s,r,a,l,h,p,u,c=[1,4,2,8];for(o=0,h=t.length;o<h;o++)t[o]._code=Ft(t[o],e);for(r=0;r<4;r++){for(p=c[r],i=[],o=0,s=(h=t.length)-1;o<h;s=o++)a=t[o],l=t[s],a._code&p?l._code&p||((u=Dt(l,a,p,e,n))._code=Ft(u,e),i.push(u)):(l._code&p&&((u=Dt(l,a,p,e,n))._code=Ft(u,e),i.push(u)),i.push(a));t=i}return t}function jt(t,e){var n,i,o,s,r,a,l,h,p;if(!t||0===t.length)throw new Error("latlngs not passed");Ut(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var u=z([0,0]),c=T(t);c.getNorthWest().distanceTo(c.getSouthWest())*c.getNorthEast().distanceTo(c.getNorthWest())<1700&&(u=Ct(t));var d=t.length,m=[];for(n=0;n<d;n++){var _=z(t[n]);m.push(e.project(z([_.lat-u.lat,_.lng-u.lng])))}for(a=l=h=0,n=0,i=d-1;n<d;i=n++)o=m[n],s=m[i],r=o.y*s.x-s.y*o.x,l+=(o.x+s.x)*r,h+=(o.y+s.y)*r,a+=3*r;p=0===a?m[0]:[l/a,h/a];var f=e.unproject(x(p));return z([f.lat+u.lat,f.lng+u.lng])}function Ct(t){for(var e=0,n=0,i=0,o=0;o<t.length;o++){var s=z(t[o]);e+=s.lat,n+=s.lng,i++}return z([e/i,n/i])}function Rt(t,e){if(!e||!t.length)return t.slice();var n=e*e;return t=Zt(t=Bt(t,n),n)}function Ot(t,e,n){return Math.sqrt(Wt(t,e,n,!0))}function Et(t,e,n){return Wt(t,e,n)}function Zt(t,e){var n=t.length,i=new(typeof Uint8Array!=void 0+""?Uint8Array:Array)(n);i[0]=i[n-1]=1,At(t,i,e,0,n-1);var o,s=[];for(o=0;o<n;o++)i[o]&&s.push(t[o]);return s}function At(t,e,n,i,o){var s,r,a,l=0;for(r=i+1;r<=o-1;r++)(a=Wt(t[r],t[i],t[o],!0))>l&&(s=r,l=a);l>n&&(e[s]=1,At(t,e,n,i,s),At(t,e,n,s,o))}function Bt(t,e){for(var n=[t[0]],i=1,o=0,s=t.length;i<s;i++)Ht(t[i],t[o])>e&&(n.push(t[i]),o=i);return o<s-1&&n.push(t[s-1]),n}function Nt(t,e,n,i,o){var s,r,a,l=i?oi:Ft(t,n),h=Ft(e,n);for(oi=h;;){if(!(l|h))return[t,e];if(l&h)return!1;a=Ft(r=Dt(t,e,s=l||h,n,o),n),s===l?(t=r,l=a):(e=r,h=a)}}function Dt(t,e,n,i,o){var s,r,a=e.x-t.x,l=e.y-t.y,h=i.min,p=i.max;return 8&n?(s=t.x+a*(p.y-t.y)/l,r=p.y):4&n?(s=t.x+a*(h.y-t.y)/l,r=h.y):2&n?(s=p.x,r=t.y+l*(p.x-t.x)/a):1&n&&(s=h.x,r=t.y+l*(h.x-t.x)/a),new y(s,r,o)}function Ft(t,e){var n=0;return t.x<e.min.x?n|=1:t.x>e.max.x&&(n|=2),t.y<e.min.y?n|=4:t.y>e.max.y&&(n|=8),n}function Ht(t,e){var n=e.x-t.x,i=e.y-t.y;return n*n+i*i}function Wt(t,e,n,i){var o,s=e.x,r=e.y,a=n.x-s,l=n.y-r,h=a*a+l*l;return h>0&&((o=((t.x-s)*a+(t.y-r)*l)/h)>1?(s=n.x,r=n.y):o>0&&(s+=a*o,r+=l*o)),a=t.x-s,l=t.y-r,i?a*a+l*l:new y(s,r)}function Ut(t){return!xe(t[0])||"object"!=typeof t[0][0]&&void 0!==t[0][0]}function Vt(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),Ut(t)}function qt(t,e){var n,i,o,s,r,a,l,h;if(!t||0===t.length)throw new Error("latlngs not passed");Ut(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var p=z([0,0]),u=T(t);u.getNorthWest().distanceTo(u.getSouthWest())*u.getNorthEast().distanceTo(u.getNorthWest())<1700&&(p=Ct(t));var c=t.length,d=[];for(n=0;n<c;n++){var m=z(t[n]);d.push(e.project(z([m.lat-p.lat,m.lng-p.lng])))}for(n=0,i=0;n<c-1;n++)i+=d[n].distanceTo(d[n+1])/2;if(0===i)h=d[0];else for(n=0,s=0;n<c-1;n++)if(r=d[n],a=d[n+1],(s+=o=r.distanceTo(a))>i){l=(s-i)/o,h=[a.x-l*(a.x-r.x),a.y-l*(a.y-r.y)];break}var _=e.unproject(x(h));return z([_.lat+p.lat,_.lng+p.lng])}function Gt(t){return new xi(t)}function Kt(t,e){return new Li(t,e)}function Yt(t,e){return new Ti(t,e)}function Jt(t,e,n){return new Mi(t,e,n)}function Xt(t,e){return new zi(t,e)}function $t(t,e){return new ki(t,e)}function Qt(t,e){var n,i,o,s,r="Feature"===t.type?t.geometry:t,a=r?r.coordinates:null,l=[],h=e&&e.pointToLayer,p=e&&e.coordsToLatLng||ee;if(!a&&!r)return null;switch(r.type){case"Point":return te(h,t,n=p(a),e);case"MultiPoint":for(o=0,s=a.length;o<s;o++)n=p(a[o]),l.push(te(h,t,n,e));return new bi(l);case"LineString":case"MultiLineString":return i=ne(a,"LineString"===r.type?0:1,p),new zi(i,e);case"Polygon":case"MultiPolygon":return i=ne(a,"Polygon"===r.type?1:2,p),new ki(i,e);case"GeometryCollection":for(o=0,s=r.geometries.length;o<s;o++){var u=Qt({geometry:r.geometries[o],type:"Feature",properties:t.properties},e);u&&l.push(u)}return new bi(l);case"FeatureCollection":for(o=0,s=r.features.length;o<s;o++){var c=Qt(r.features[o],e);c&&l.push(c)}return new bi(l);default:throw new Error("Invalid GeoJSON object.")}}function te(t,e,n,i){return t?t(e,n):new Li(n,i&&i.markersInheritOptions&&i)}function ee(t){return new M(t[1],t[0],t[2])}function ne(t,e,n){for(var i,o=[],s=0,r=t.length;s<r;s++)i=e?ne(t[s],e-1,n):(n||ee)(t[s]),o.push(i);return o}function ie(t,e){return void 0!==(t=z(t)).alt?[a(t.lng,e),a(t.lat,e),a(t.alt,e)]:[a(t.lng,e),a(t.lat,e)]}function oe(t,e,n,i){for(var o=[],s=0,r=t.length;s<r;s++)o.push(e?oe(t[s],Ut(t[s])?0:e-1,n,i):ie(t[s],i));return!e&&n&&o.length>0&&o.push(o[0].slice()),o}function se(t,n){return t.feature?e({},t.feature,{geometry:n}):re(n)}function re(t){return"Feature"===t.type||"FeatureCollection"===t.type?t:{type:"Feature",properties:{},geometry:t}}function ae(t,e){return new Si(t,e)}function le(t,e,n){return new Ei(t,e,n)}function he(t,e,n){return new Zi(t,e,n)}function pe(t){return new Hi(t)}function ue(t){return new Wi(t)}
|
|
/*
|
|
* @class TileLayer
|
|
* @inherits GridLayer
|
|
* @aka L.TileLayer
|
|
* Used to load and display tile layers on the map. Note that most tile servers require attribution, which you can set under `Layer`. Extends `GridLayer`.
|
|
*
|
|
* @example
|
|
*
|
|
* ```js
|
|
* L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png?{foo}', {foo: 'bar', attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'}).addTo(map);
|
|
* ```
|
|
*
|
|
* @section URL template
|
|
* @example
|
|
*
|
|
* A string of the following form:
|
|
*
|
|
* ```
|
|
* 'https://{s}.somedomain.com/blabla/{z}/{x}/{y}{r}.png'
|
|
* ```
|
|
*
|
|
* `{s}` means one of the available subdomains (used sequentially to help with browser parallel requests per domain limitation; subdomain values are specified in options; `a`, `b` or `c` by default, can be omitted), `{z}` — zoom level, `{x}` and `{y}` — tile coordinates. `{r}` can be used to add "@2x" to the URL to load retina tiles.
|
|
*
|
|
* You can use custom keys in the template, which will be [evaluated](#util-template) from TileLayer options, like this:
|
|
*
|
|
* ```
|
|
* L.tileLayer('https://{s}.somedomain.com/{foo}/{z}/{x}/{y}.png', {foo: 'bar'});
|
|
* ```
|
|
*/function ce(t,e){return new Ui(t,e)}function de(t,e){return new Vi(t,e)}function me(t){return Pn.canvas?new Gi(t):null}function _e(t){return Pn.svg||Pn.vml?new Xi(t):null}function fe(t,e){return new $i(t,e)}var ge="1.9.4",ve=Object.create||function(){function t(){}return function(e){return t.prototype=e,new t}}(),be=0,ye=/\{ *([\w_ -]+) *\}/g,xe=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)},Ie="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=",we=0,Le=window.requestAnimationFrame||m("RequestAnimationFrame")||_,Pe=window.cancelAnimationFrame||m("CancelAnimationFrame")||m("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)},Te={__proto__:null,extend:e,create:ve,bind:n,get lastId(){return be},stamp:i,throttle:o,wrapNum:s,falseFn:r,formatNum:a,trim:l,splitWords:h,setOptions:p,getParamString:u,template:c,isArray:xe,indexOf:d,emptyImageUrl:Ie,requestFn:Le,cancelFn:Pe,requestAnimFrame:f,cancelAnimFrame:g};v.extend=function(t){var n=function(){p(this),this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},i=n.__super__=this.prototype,o=ve(i);for(var s in o.constructor=n,n.prototype=o,this)Object.prototype.hasOwnProperty.call(this,s)&&"prototype"!==s&&"__super__"!==s&&(n[s]=this[s]);return t.statics&&e(n,t.statics),t.includes&&(b(t.includes),e.apply(null,[o].concat(t.includes))),e(o,t),delete o.statics,delete o.includes,o.options&&(o.options=i.options?ve(i.options):{},e(o.options,t.options)),o._initHooks=[],o.callInitHooks=function(){if(!this._initHooksCalled){i.callInitHooks&&i.callInitHooks.call(this),this._initHooksCalled=!0;for(var t=0,e=o._initHooks.length;t<e;t++)o._initHooks[t].call(this)}},n},v.include=function(t){var n=this.prototype.options;return e(this.prototype,t),t.options&&(this.prototype.options=n,this.mergeOptions(t.options)),this},v.mergeOptions=function(t){return e(this.prototype.options,t),this},v.addInitHook=function(t){var e=Array.prototype.slice.call(arguments,1),n="function"==typeof t?t:function(){this[t].apply(this,e)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(n),this};var Me={on:function(t,e,n){if("object"==typeof t)for(var i in t)this._on(i,t[i],e);else for(var o=0,s=(t=h(t)).length;o<s;o++)this._on(t[o],e,n);return this},off:function(t,e,n){if(arguments.length)if("object"==typeof t)for(var i in t)this._off(i,t[i],e);else{t=h(t);for(var o=1===arguments.length,s=0,r=t.length;s<r;s++)o?this._off(t[s]):this._off(t[s],e,n)}else delete this._events;return this},_on:function(t,e,n,i){if("function"==typeof e){if(!1===this._listens(t,e,n)){n===this&&(n=void 0);var o={fn:e,ctx:n};i&&(o.once=!0),this._events=this._events||{},this._events[t]=this._events[t]||[],this._events[t].push(o)}}else console.warn("wrong listener type: "+typeof e)},_off:function(t,e,n){var i,o,s;if(this._events&&(i=this._events[t]))if(1!==arguments.length)if("function"==typeof e){var a=this._listens(t,e,n);if(!1!==a){var l=i[a];this._firingCount&&(l.fn=r,this._events[t]=i=i.slice()),i.splice(a,1)}}else console.warn("wrong listener type: "+typeof e);else{if(this._firingCount)for(o=0,s=i.length;o<s;o++)i[o].fn=r;delete this._events[t]}},fire:function(t,n,i){if(!this.listens(t,i))return this;var o=e({},n,{type:t,target:this,sourceTarget:n&&n.sourceTarget||this});if(this._events){var s=this._events[t];if(s){this._firingCount=this._firingCount+1||1;for(var r=0,a=s.length;r<a;r++){var l=s[r],h=l.fn;l.once&&this.off(t,h,l.ctx),h.call(l.ctx||this,o)}this._firingCount--}}return i&&this._propagateEvent(o),this},listens:function(t,e,n,i){"string"!=typeof t&&console.warn('"string" type argument expected');var o=e;"function"!=typeof e&&(i=!!e,o=void 0,n=void 0);var s=this._events&&this._events[t];if(s&&s.length&&!1!==this._listens(t,o,n))return!0;if(i)for(var r in this._eventParents)if(this._eventParents[r].listens(t,e,n,i))return!0;return!1},_listens:function(t,e,n){if(!this._events)return!1;var i=this._events[t]||[];if(!e)return!!i.length;n===this&&(n=void 0);for(var o=0,s=i.length;o<s;o++)if(i[o].fn===e&&i[o].ctx===n)return o;return!1},once:function(t,e,n){if("object"==typeof t)for(var i in t)this._on(i,t[i],e,!0);else for(var o=0,s=(t=h(t)).length;o<s;o++)this._on(t[o],e,n,!0);return this},addEventParent:function(t){return this._eventParents=this._eventParents||{},this._eventParents[i(t)]=t,this},removeEventParent:function(t){return this._eventParents&&delete this._eventParents[i(t)],this},_propagateEvent:function(t){for(var n in this._eventParents)this._eventParents[n].fire(t.type,e({layer:t.target,propagatedFrom:t.target},t),!0)}};Me.addEventListener=Me.on,Me.removeEventListener=Me.clearAllEventListeners=Me.off,Me.addOneTimeEventListener=Me.once,Me.fireEvent=Me.fire,Me.hasEventListeners=Me.listens;var ze=v.extend(Me),ke=Math.trunc||function(t){return t>0?Math.floor(t):Math.ceil(t)};y.prototype={clone:function(){return new y(this.x,this.y)},add:function(t){return this.clone()._add(x(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(x(t))},_subtract:function(t){return this.x-=t.x,this.y-=t.y,this},divideBy:function(t){return this.clone()._divideBy(t)},_divideBy:function(t){return this.x/=t,this.y/=t,this},multiplyBy:function(t){return this.clone()._multiplyBy(t)},_multiplyBy:function(t){return this.x*=t,this.y*=t,this},scaleBy:function(t){return new y(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new y(this.x/t.x,this.y/t.y)},round:function(){return this.clone()._round()},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},floor:function(){return this.clone()._floor()},_floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.clone()._ceil()},_ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},trunc:function(){return this.clone()._trunc()},_trunc:function(){return this.x=ke(this.x),this.y=ke(this.y),this},distanceTo:function(t){var e=(t=x(t)).x-this.x,n=t.y-this.y;return Math.sqrt(e*e+n*n)},equals:function(t){return(t=x(t)).x===this.x&&t.y===this.y},contains:function(t){return t=x(t),Math.abs(t.x)<=Math.abs(this.x)&&Math.abs(t.y)<=Math.abs(this.y)},toString:function(){return"Point("+a(this.x)+", "+a(this.y)+")"}},I.prototype={extend:function(t){var e,n;if(!t)return this;if(t instanceof y||"number"==typeof t[0]||"x"in t)e=n=x(t);else if(e=(t=w(t)).min,n=t.max,!e||!n)return this;return this.min||this.max?(this.min.x=Math.min(e.x,this.min.x),this.max.x=Math.max(n.x,this.max.x),this.min.y=Math.min(e.y,this.min.y),this.max.y=Math.max(n.y,this.max.y)):(this.min=e.clone(),this.max=n.clone()),this},getCenter:function(t){return x((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return x(this.min.x,this.max.y)},getTopRight:function(){return x(this.max.x,this.min.y)},getTopLeft:function(){return this.min},getBottomRight:function(){return this.max},getSize:function(){return this.max.subtract(this.min)},contains:function(t){var e,n;return(t="number"==typeof t[0]||t instanceof y?x(t):w(t))instanceof I?(e=t.min,n=t.max):e=n=t,e.x>=this.min.x&&n.x<=this.max.x&&e.y>=this.min.y&&n.y<=this.max.y},intersects:function(t){t=w(t);var e=this.min,n=this.max,i=t.min,o=t.max,s=o.x>=e.x&&i.x<=n.x,r=o.y>=e.y&&i.y<=n.y;return s&&r},overlaps:function(t){t=w(t);var e=this.min,n=this.max,i=t.min,o=t.max,s=o.x>e.x&&i.x<n.x,r=o.y>e.y&&i.y<n.y;return s&&r},isValid:function(){return!(!this.min||!this.max)},pad:function(t){var e=this.min,n=this.max,i=Math.abs(e.x-n.x)*t,o=Math.abs(e.y-n.y)*t;return w(x(e.x-i,e.y-o),x(n.x+i,n.y+o))},equals:function(t){return!!t&&(t=w(t),this.min.equals(t.getTopLeft())&&this.max.equals(t.getBottomRight()))}},P.prototype={extend:function(t){var e,n,i=this._southWest,o=this._northEast;if(t instanceof M)e=t,n=t;else{if(!(t instanceof P))return t?this.extend(z(t)||T(t)):this;if(e=t._southWest,n=t._northEast,!e||!n)return this}return i||o?(i.lat=Math.min(e.lat,i.lat),i.lng=Math.min(e.lng,i.lng),o.lat=Math.max(n.lat,o.lat),o.lng=Math.max(n.lng,o.lng)):(this._southWest=new M(e.lat,e.lng),this._northEast=new M(n.lat,n.lng)),this},pad:function(t){var e=this._southWest,n=this._northEast,i=Math.abs(e.lat-n.lat)*t,o=Math.abs(e.lng-n.lng)*t;return new P(new M(e.lat-i,e.lng-o),new M(n.lat+i,n.lng+o))},getCenter:function(){return new M((this._southWest.lat+this._northEast.lat)/2,(this._southWest.lng+this._northEast.lng)/2)},getSouthWest:function(){return this._southWest},getNorthEast:function(){return this._northEast},getNorthWest:function(){return new M(this.getNorth(),this.getWest())},getSouthEast:function(){return new M(this.getSouth(),this.getEast())},getWest:function(){return this._southWest.lng},getSouth:function(){return this._southWest.lat},getEast:function(){return this._northEast.lng},getNorth:function(){return this._northEast.lat},contains:function(t){t="number"==typeof t[0]||t instanceof M||"lat"in t?z(t):T(t);var e,n,i=this._southWest,o=this._northEast;return t instanceof P?(e=t.getSouthWest(),n=t.getNorthEast()):e=n=t,e.lat>=i.lat&&n.lat<=o.lat&&e.lng>=i.lng&&n.lng<=o.lng},intersects:function(t){t=T(t);var e=this._southWest,n=this._northEast,i=t.getSouthWest(),o=t.getNorthEast(),s=o.lat>=e.lat&&i.lat<=n.lat,r=o.lng>=e.lng&&i.lng<=n.lng;return s&&r},overlaps:function(t){t=T(t);var e=this._southWest,n=this._northEast,i=t.getSouthWest(),o=t.getNorthEast(),s=o.lat>e.lat&&i.lat<n.lat,r=o.lng>e.lng&&i.lng<n.lng;return s&&r},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(t,e){return!!t&&(t=T(t),this._southWest.equals(t.getSouthWest(),e)&&this._northEast.equals(t.getNorthEast(),e))},isValid:function(){return!(!this._southWest||!this._northEast)}},M.prototype={equals:function(t,e){return!!t&&(t=z(t),Math.max(Math.abs(this.lat-t.lat),Math.abs(this.lng-t.lng))<=(void 0===e?1e-9:e))},toString:function(t){return"LatLng("+a(this.lat,t)+", "+a(this.lng,t)+")"},distanceTo:function(t){return Ce.distance(this,z(t))},wrap:function(){return Ce.wrapLatLng(this)},toBounds:function(t){var e=180*t/40075017,n=e/Math.cos(Math.PI/180*this.lat);return T([this.lat-e,this.lng-n],[this.lat+e,this.lng+n])},clone:function(){return new M(this.lat,this.lng,this.alt)}};var Se,je={latLngToPoint:function(t,e){var n=this.projection.project(t),i=this.scale(e);return this.transformation._transform(n,i)},pointToLatLng:function(t,e){var n=this.scale(e),i=this.transformation.untransform(t,n);return this.projection.unproject(i)},project:function(t){return this.projection.project(t)},unproject:function(t){return this.projection.unproject(t)},scale:function(t){return 256*Math.pow(2,t)},zoom:function(t){return Math.log(t/256)/Math.LN2},getProjectedBounds:function(t){if(this.infinite)return null;var e=this.projection.bounds,n=this.scale(t);return new I(this.transformation.transform(e.min,n),this.transformation.transform(e.max,n))},infinite:!1,wrapLatLng:function(t){var e=this.wrapLng?s(t.lng,this.wrapLng,!0):t.lng;return new M(this.wrapLat?s(t.lat,this.wrapLat,!0):t.lat,e,t.alt)},wrapLatLngBounds:function(t){var e=t.getCenter(),n=this.wrapLatLng(e),i=e.lat-n.lat,o=e.lng-n.lng;if(0===i&&0===o)return t;var s=t.getSouthWest(),r=t.getNorthEast();return new P(new M(s.lat-i,s.lng-o),new M(r.lat-i,r.lng-o))}},Ce=e({},je,{wrapLng:[-180,180],R:6371e3,distance:function(t,e){var n=Math.PI/180,i=t.lat*n,o=e.lat*n,s=Math.sin((e.lat-t.lat)*n/2),r=Math.sin((e.lng-t.lng)*n/2),a=s*s+Math.cos(i)*Math.cos(o)*r*r,l=2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a));return this.R*l}}),Re=6378137,Oe={R:Re,MAX_LATITUDE:85.0511287798,project:function(t){var e=Math.PI/180,n=this.MAX_LATITUDE,i=Math.max(Math.min(n,t.lat),-n),o=Math.sin(i*e);return new y(this.R*t.lng*e,this.R*Math.log((1+o)/(1-o))/2)},unproject:function(t){var e=180/Math.PI;return new M((2*Math.atan(Math.exp(t.y/this.R))-Math.PI/2)*e,t.x*e/this.R)},bounds:(Se=Re*Math.PI,new I([-Se,-Se],[Se,Se]))};k.prototype={transform:function(t,e){return this._transform(t.clone(),e)},_transform:function(t,e){return e=e||1,t.x=e*(this._a*t.x+this._b),t.y=e*(this._c*t.y+this._d),t},untransform:function(t,e){return e=e||1,new y((t.x/e-this._b)/this._a,(t.y/e-this._d)/this._c)}};var Ee,Ze,Ae,Be,Ne,De,Fe=e({},Ce,{code:"EPSG:3857",projection:Oe,transformation:function(){var t=.5/(Math.PI*Oe.R);return S(t,.5,-t,.5)}()}),He=e({},Fe,{code:"EPSG:900913"}),We=document.documentElement.style,Ue="ActiveXObject"in window,Ve=Ue&&!document.addEventListener,qe="msLaunchUri"in navigator&&!("documentMode"in document),Ge=R("webkit"),Ke=R("android"),Ye=R("android 2")||R("android 3"),Je=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),Xe=Ke&&R("Google")&&Je<537&&!("AudioNode"in window),$e=!!window.opera,Qe=!qe&&R("chrome"),tn=R("gecko")&&!Ge&&!$e&&!Ue,en=!Qe&&R("safari"),nn=R("phantom"),on="OTransition"in We,sn=0===navigator.platform.indexOf("Win"),rn=Ue&&"transition"in We,an="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Ye,ln="MozPerspective"in We,hn=!window.L_DISABLE_3D&&(rn||an||ln)&&!on&&!nn,pn="undefined"!=typeof orientation||R("mobile"),un=pn&&Ge,cn=pn&&an,dn=!window.PointerEvent&&window.MSPointerEvent,mn=!(!window.PointerEvent&&!dn),_n="ontouchstart"in window||!!window.TouchEvent,fn=!window.L_NO_TOUCH&&(_n||mn),gn=pn&&$e,vn=pn&&tn,bn=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,yn=function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("testPassiveEventSupport",r,e),window.removeEventListener("testPassiveEventSupport",r,e)}catch(t){}return t}(),xn=!!document.createElement("canvas").getContext,In=!(!document.createElementNS||!j("svg").createSVGRect),wn=!!In&&((Ee=document.createElement("div")).innerHTML="<svg/>","http://www.w3.org/2000/svg"===(Ee.firstChild&&Ee.firstChild.namespaceURI)),Ln=!In&&function(){try{var t=document.createElement("div");t.innerHTML='<v:shape adj="1"/>';var e=t.firstChild;return e.style.behavior="url(#default#VML)",e&&"object"==typeof e.adj}catch(t){return!1}}(),Pn={ie:Ue,ielt9:Ve,edge:qe,webkit:Ge,android:Ke,android23:Ye,androidStock:Xe,opera:$e,chrome:Qe,gecko:tn,safari:en,phantom:nn,opera12:on,win:sn,ie3d:rn,webkit3d:an,gecko3d:ln,any3d:hn,mobile:pn,mobileWebkit:un,mobileWebkit3d:cn,msPointer:dn,pointer:mn,touch:fn,touchNative:_n,mobileOpera:gn,mobileGecko:vn,retina:bn,passiveEvents:yn,canvas:xn,svg:In,vml:Ln,inlineSvg:wn,mac:0===navigator.platform.indexOf("Mac"),linux:0===navigator.platform.indexOf("Linux")},Tn=Pn.msPointer?"MSPointerDown":"pointerdown",Mn=Pn.msPointer?"MSPointerMove":"pointermove",zn=Pn.msPointer?"MSPointerUp":"pointerup",kn=Pn.msPointer?"MSPointerCancel":"pointercancel",Sn={touchstart:Tn,touchmove:Mn,touchend:zn,touchcancel:kn},jn={touchstart:F,touchmove:D,touchend:D,touchcancel:D},Cn={},Rn=!1,On=200,En=st(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),Zn=st(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),An="webkitTransition"===Zn||"OTransition"===Zn?Zn+"End":"transitionend";if("onselectstart"in document)Ze=function(){_t(window,"selectstart",wt)},Ae=function(){ft(window,"selectstart",wt)};else{var Bn=st(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);Ze=function(){if(Bn){var t=document.documentElement.style;Be=t[Bn],t[Bn]="none"}},Ae=function(){Bn&&(document.documentElement.style[Bn]=Be,Be=void 0)}}var Nn={__proto__:null,TRANSFORM:En,TRANSITION:Zn,TRANSITION_END:An,get:V,getStyle:q,create:G,remove:K,empty:Y,toFront:J,toBack:X,hasClass:$,addClass:Q,removeClass:tt,setClass:et,getClass:nt,setOpacity:it,testProp:st,setTransform:rt,setPosition:at,getPosition:lt,get disableTextSelection(){return Ze},get enableTextSelection(){return Ae},disableImageDrag:ht,enableImageDrag:pt,preventOutline:ut,restoreOutline:ct,getSizedParentNode:dt,getScale:mt},Dn="_leaflet_events",Fn={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"},Hn=Pn.linux&&Pn.chrome?window.devicePixelRatio:Pn.mac?3*window.devicePixelRatio:window.devicePixelRatio>0?2*window.devicePixelRatio:1,Wn={__proto__:null,on:_t,off:ft,stopPropagation:yt,disableScrollPropagation:xt,disableClickPropagation:It,preventDefault:wt,stop:Lt,getPropagationPath:Pt,getMousePosition:Tt,getWheelDelta:Mt,isExternalTarget:zt,addListener:_t,removeListener:ft},Un=ze.extend({run:function(t,e,n,i){this.stop(),this._el=t,this._inProgress=!0,this._duration=n||.25,this._easeOutPower=1/Math.max(i||.5,.2),this._startPos=lt(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=f(this._animate,this),this._step()},_step:function(t){var e=+new Date-this._startTime,n=1e3*this._duration;e<n?this._runFrame(this._easeOut(e/n),t):(this._runFrame(1),this._complete())},_runFrame:function(t,e){var n=this._startPos.add(this._offset.multiplyBy(t));e&&n._round(),at(this._el,n),this.fire("step")},_complete:function(){g(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(t){return 1-Math.pow(1-t,this._easeOutPower)}}),Vn=ze.extend({options:{crs:Fe,center:void 0,zoom:void 0,minZoom:void 0,maxZoom:void 0,layers:[],maxBounds:void 0,renderer:void 0,zoomAnimation:!0,zoomAnimationThreshold:4,fadeAnimation:!0,markerZoomAnimation:!0,transform3DLimit:8388608,zoomSnap:1,zoomDelta:1,trackResize:!0},initialize:function(t,e){e=p(this,e),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this._initContainer(t),this._initLayout(),this._onResize=n(this._onResize,this),this._initEvents(),e.maxBounds&&this.setMaxBounds(e.maxBounds),void 0!==e.zoom&&(this._zoom=this._limitZoom(e.zoom)),e.center&&void 0!==e.zoom&&this.setView(z(e.center),e.zoom,{reset:!0}),this.callInitHooks(),this._zoomAnimated=Zn&&Pn.any3d&&!Pn.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),_t(this._proxy,An,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(t,n,i){if((n=void 0===n?this._zoom:this._limitZoom(n),t=this._limitCenter(z(t),n,this.options.maxBounds),i=i||{},this._stop(),this._loaded&&!i.reset&&!0!==i)&&(void 0!==i.animate&&(i.zoom=e({animate:i.animate},i.zoom),i.pan=e({animate:i.animate,duration:i.duration},i.pan)),this._zoom!==n?this._tryAnimatedZoom&&this._tryAnimatedZoom(t,n,i.zoom):this._tryAnimatedPan(t,i.pan)))return clearTimeout(this._sizeTimer),this;return this._resetView(t,n,i.pan&&i.pan.noMoveStart),this},setZoom:function(t,e){return this._loaded?this.setView(this.getCenter(),t,{zoom:e}):(this._zoom=t,this)},zoomIn:function(t,e){return t=t||(Pn.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+t,e)},zoomOut:function(t,e){return t=t||(Pn.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-t,e)},setZoomAround:function(t,e,n){var i=this.getZoomScale(e),o=this.getSize().divideBy(2),s=(t instanceof y?t:this.latLngToContainerPoint(t)).subtract(o).multiplyBy(1-1/i),r=this.containerPointToLatLng(o.add(s));return this.setView(r,e,{zoom:n})},_getBoundsCenterZoom:function(t,e){e=e||{},t=t.getBounds?t.getBounds():T(t);var n=x(e.paddingTopLeft||e.padding||[0,0]),i=x(e.paddingBottomRight||e.padding||[0,0]),o=this.getBoundsZoom(t,!1,n.add(i));if((o="number"==typeof e.maxZoom?Math.min(e.maxZoom,o):o)===1/0)return{center:t.getCenter(),zoom:o};var s=i.subtract(n).divideBy(2),r=this.project(t.getSouthWest(),o),a=this.project(t.getNorthEast(),o);return{center:this.unproject(r.add(a).divideBy(2).add(s),o),zoom:o}},fitBounds:function(t,e){if(!(t=T(t)).isValid())throw new Error("Bounds are not valid.");var n=this._getBoundsCenterZoom(t,e);return this.setView(n.center,n.zoom,e)},fitWorld:function(t){return this.fitBounds([[-90,-180],[90,180]],t)},panTo:function(t,e){return this.setView(t,this._zoom,{pan:e})},panBy:function(t,e){if(e=e||{},!(t=x(t).round()).x&&!t.y)return this.fire("moveend");if(!0!==e.animate&&!this.getSize().contains(t))return this._resetView(this.unproject(this.project(this.getCenter()).add(t)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new Un,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),e.noMoveStart||this.fire("movestart"),!1!==e.animate){Q(this._mapPane,"leaflet-pan-anim");var n=this._getMapPanePos().subtract(t).round();this._panAnim.run(this._mapPane,n,e.duration||.25,e.easeLinearity)}else this._rawPanBy(t),this.fire("move").fire("moveend");return this},flyTo:function(t,e,n){function i(t){var e=(g*g-_*_+(t?-1:1)*y*y*v*v)/(2*(t?g:_)*y*v),n=Math.sqrt(e*e+1)-e;return n<1e-9?-18:Math.log(n)}function o(t){return(Math.exp(t)-Math.exp(-t))/2}function s(t){return(Math.exp(t)+Math.exp(-t))/2}function r(t){return o(t)/s(t)}function a(t){return _*(s(x)/s(x+b*t))}function l(t){return _*(s(x)*r(x+b*t)-o(x))/y}function h(t){return 1-Math.pow(1-t,1.5)}function p(){var n=(Date.now()-I)/L,i=h(n)*w;n<=1?(this._flyToFrame=f(p,this),this._move(this.unproject(u.add(c.subtract(u).multiplyBy(l(i)/v)),m),this.getScaleZoom(_/a(i),m),{flyTo:!0})):this._move(t,e)._moveEnd(!0)}if(!1===(n=n||{}).animate||!Pn.any3d)return this.setView(t,e,n);this._stop();var u=this.project(this.getCenter()),c=this.project(t),d=this.getSize(),m=this._zoom;t=z(t),e=void 0===e?m:e;var _=Math.max(d.x,d.y),g=_*this.getZoomScale(m,e),v=c.distanceTo(u)||1,b=1.42,y=b*b,x=i(0),I=Date.now(),w=(i(1)-x)/b,L=n.duration?1e3*n.duration:1e3*w*.8;return this._moveStart(!0,n.noMoveStart),p.call(this),this},flyToBounds:function(t,e){var n=this._getBoundsCenterZoom(t,e);return this.flyTo(n.center,n.zoom,e)},setMaxBounds:function(t){return t=T(t),this.listens("moveend",this._panInsideMaxBounds)&&this.off("moveend",this._panInsideMaxBounds),t.isValid()?(this.options.maxBounds=t,this._loaded&&this._panInsideMaxBounds(),this.on("moveend",this._panInsideMaxBounds)):(this.options.maxBounds=null,this)},setMinZoom:function(t){var e=this.options.minZoom;return this.options.minZoom=t,this._loaded&&e!==t&&(this.fire("zoomlevelschange"),this.getZoom()<this.options.minZoom)?this.setZoom(t):this},setMaxZoom:function(t){var e=this.options.maxZoom;return this.options.maxZoom=t,this._loaded&&e!==t&&(this.fire("zoomlevelschange"),this.getZoom()>this.options.maxZoom)?this.setZoom(t):this},panInsideBounds:function(t,e){this._enforcingBounds=!0;var n=this.getCenter(),i=this._limitCenter(n,this._zoom,T(t));return n.equals(i)||this.panTo(i,e),this._enforcingBounds=!1,this},panInside:function(t,e){var n=x((e=e||{}).paddingTopLeft||e.padding||[0,0]),i=x(e.paddingBottomRight||e.padding||[0,0]),o=this.project(this.getCenter()),s=this.project(t),r=this.getPixelBounds(),a=w([r.min.add(n),r.max.subtract(i)]),l=a.getSize();if(!a.contains(s)){this._enforcingBounds=!0;var h=s.subtract(a.getCenter()),p=a.extend(s).getSize().subtract(l);o.x+=h.x<0?-p.x:p.x,o.y+=h.y<0?-p.y:p.y,this.panTo(this.unproject(o),e),this._enforcingBounds=!1}return this},invalidateSize:function(t){if(!this._loaded)return this;t=e({animate:!1,pan:!0},!0===t?{animate:!0}:t);var i=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var o=this.getSize(),s=i.divideBy(2).round(),r=o.divideBy(2).round(),a=s.subtract(r);return a.x||a.y?(t.animate&&t.pan?this.panBy(a):(t.pan&&this._rawPanBy(a),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(n(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:i,newSize:o})):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=e({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var i=n(this._handleGeolocationResponse,this),o=n(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(i,o,t):navigator.geolocation.getCurrentPosition(i,o,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,n=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: "+n+"."})}},_handleGeolocationResponse:function(t){if(this._container._leaflet_id){var e=new M(t.coords.latitude,t.coords.longitude),n=e.toBounds(2*t.coords.accuracy),i=this._locateOptions;if(i.setView){var o=this.getBoundsZoom(n);this.setView(e,i.maxZoom?Math.min(o,i.maxZoom):o)}var s={latlng:e,bounds:n,timestamp:t.timestamp};for(var r in t.coords)"number"==typeof t.coords[r]&&(s[r]=t.coords[r]);this.fire("locationfound",s)}},addHandler:function(t,e){if(!e)return this;var n=this[t]=new e(this);return this._handlers.push(n),this.options[t]&&n.enable(),this},remove:function(){if(this._initEvents(!0),this.options.maxBounds&&this.off("moveend",this._panInsideMaxBounds),this._containerId!==this._container._leaflet_id)throw new 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}var t;for(t in void 0!==this._locationWatchId&&this.stopLocate(),this._stop(),K(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(g(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload"),this._layers)this._layers[t].remove();for(t in this._panes)K(this._panes[t]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,e){var n=G("div","leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),e||this._mapPane);return t&&(this._panes[t]=n),n},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();return new P(this.unproject(t.getBottomLeft()),this.unproject(t.getTopRight()))},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,n){t=T(t),n=x(n||[0,0]);var i=this.getZoom()||0,o=this.getMinZoom(),s=this.getMaxZoom(),r=t.getNorthWest(),a=t.getSouthEast(),l=this.getSize().subtract(n),h=w(this.project(a,i),this.project(r,i)).getSize(),p=Pn.any3d?this.options.zoomSnap:1,u=l.x/h.x,c=l.y/h.y,d=e?Math.max(u,c):Math.min(u,c);return i=this.getScaleZoom(d,i),p&&(i=Math.round(i/(p/100))*(p/100),i=e?Math.ceil(i/p)*p:Math.floor(i/p)*p),Math.max(o,Math.min(s,i))},getSize:function(){return this._size&&!this._sizeChanged||(this._size=new y(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,e){var n=this._getTopLeftPoint(t,e);return new I(n,n.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 n=this.options.crs;return e=void 0===e?this._zoom:e,n.scale(t)/n.scale(e)},getScaleZoom:function(t,e){var n=this.options.crs;e=void 0===e?this._zoom:e;var i=n.zoom(t*n.scale(e));return isNaN(i)?1/0:i},project:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.latLngToPoint(z(t),e)},unproject:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.pointToLatLng(x(t),e)},layerPointToLatLng:function(t){var e=x(t).add(this.getPixelOrigin());return this.unproject(e)},latLngToLayerPoint:function(t){return this.project(z(t))._round()._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(z(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds(T(t))},distance:function(t,e){return this.options.crs.distance(z(t),z(e))},containerPointToLayerPoint:function(t){return x(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return x(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(x(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(z(t)))},mouseEventToContainerPoint:function(t){return Tt(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=V(t);if(!e)throw new Error("Map container not found.");if(e._leaflet_id)throw new Error("Map container is already initialized.");_t(e,"scroll",this._onScroll,this),this._containerId=i(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&Pn.any3d,Q(t,"leaflet-container"+(Pn.touch?" leaflet-touch":"")+(Pn.retina?" leaflet-retina":"")+(Pn.ielt9?" leaflet-oldie":"")+(Pn.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var e=q(t,"position");"absolute"!==e&&"relative"!==e&&"fixed"!==e&&"sticky"!==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),at(this._mapPane,new y(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(Q(t.markerPane,"leaflet-zoom-hide"),Q(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e,n){at(this._mapPane,new y(0,0));var i=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var o=this._zoom!==e;this._moveStart(o,n)._move(t,e)._moveEnd(o),this.fire("viewreset"),i&&this.fire("load")},_moveStart:function(t,e){return t&&this.fire("zoomstart"),e||this.fire("movestart"),this},_move:function(t,e,n,i){void 0===e&&(e=this._zoom);var o=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),i?n&&n.pinch&&this.fire("zoom",n):((o||n&&n.pinch)&&this.fire("zoom",n),this.fire("move",n)),this},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return g(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){at(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 new Error("Set map center and zoom first.")},_initEvents:function(t){this._targets={},this._targets[i(this._container)]=this;var e=t?ft:_t;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),Pn.any3d&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){g(this._resizeRequest),this._resizeRequest=f((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 n,o=[],s="mouseout"===e||"mouseover"===e,r=t.target||t.srcElement,a=!1;r;){if((n=this._targets[i(r)])&&("click"===e||"preclick"===e)&&this._draggableMoved(n)){a=!0;break}if(n&&n.listens(e,!0)){if(s&&!zt(r,t))break;if(o.push(n),s)break}if(r===this._container)break;r=r.parentNode}return o.length||a||s||!this.listens(e,!0)||(o=[this]),o},_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 n=t.type;"mousedown"===n&&ut(e),this._fireDOMEvent(t,n)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,n,i){if("click"===t.type){var o=e({},t);o.type="preclick",this._fireDOMEvent(o,o.type,i)}var s=this._findEventTargets(t,n);if(i){for(var r=[],a=0;a<i.length;a++)i[a].listens(n,!0)&&r.push(i[a]);s=r.concat(s)}if(s.length){"contextmenu"===n&&wt(t);var l=s[0],h={originalEvent:t};if("keypress"!==t.type&&"keydown"!==t.type&&"keyup"!==t.type){var p=l.getLatLng&&(!l._radius||l._radius<=10);h.containerPoint=p?this.latLngToContainerPoint(l.getLatLng()):this.mouseEventToContainerPoint(t),h.layerPoint=this.containerPointToLayerPoint(h.containerPoint),h.latlng=p?l.getLatLng():this.layerPointToLatLng(h.layerPoint)}for(a=0;a<s.length;a++)if(s[a].fire(n,h,!0),h.originalEvent._stopped||!1===s[a].options.bubblingMouseEvents&&-1!==d(this._mouseEvents,n))return}},_draggableMoved:function(t){return(t=t.dragging&&t.dragging.enabled()?t:this).dragging&&t.dragging.moved()||this.boxZoom&&this.boxZoom.moved()},_clearHandlers:function(){for(var t=0,e=this._handlers.length;t<e;t++)this._handlers[t].disable()},whenReady:function(t,e){return this._loaded?t.call(e||this,{target:this}):this.on("load",t,e),this},_getMapPanePos:function(){return lt(this._mapPane)||new y(0,0)},_moved:function(){var t=this._getMapPanePos();return t&&!t.equals([0,0])},_getTopLeftPoint:function(t,e){return(t&&void 0!==e?this._getNewPixelOrigin(t,e):this.getPixelOrigin()).subtract(this._getMapPanePos())},_getNewPixelOrigin:function(t,e){var n=this.getSize()._divideBy(2);return this.project(t,e)._subtract(n)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(t,e,n){var i=this._getNewPixelOrigin(n,e);return this.project(t,e)._subtract(i)},_latLngBoundsToNewLayerBounds:function(t,e,n){var i=this._getNewPixelOrigin(n,e);return w([this.project(t.getSouthWest(),e)._subtract(i),this.project(t.getNorthWest(),e)._subtract(i),this.project(t.getSouthEast(),e)._subtract(i),this.project(t.getNorthEast(),e)._subtract(i)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(t){return this.latLngToLayerPoint(t).subtract(this._getCenterLayerPoint())},_limitCenter:function(t,e,n){if(!n)return t;var i=this.project(t,e),o=this.getSize().divideBy(2),s=new I(i.subtract(o),i.add(o)),r=this._getBoundsOffset(s,n,e);return Math.abs(r.x)<=1&&Math.abs(r.y)<=1?t:this.unproject(i.add(r),e)},_limitOffset:function(t,e){if(!e)return t;var n=this.getPixelBounds(),i=new I(n.min.add(t),n.max.add(t));return t.add(this._getBoundsOffset(i,e))},_getBoundsOffset:function(t,e,n){var i=w(this.project(e.getNorthEast(),n),this.project(e.getSouthWest(),n)),o=i.min.subtract(t.min),s=i.max.subtract(t.max);return new y(this._rebound(o.x,-s.x),this._rebound(o.y,-s.y))},_rebound:function(t,e){return t+e>0?Math.round(t-e)/2:Math.max(0,Math.ceil(t))-Math.max(0,Math.floor(e))},_limitZoom:function(t){var e=this.getMinZoom(),n=this.getMaxZoom(),i=Pn.any3d?this.options.zoomSnap:1;return i&&(t=Math.round(t/i)*i),Math.max(e,Math.min(n,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){tt(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,e){var n=this._getCenterOffset(t)._trunc();return!(!0!==(e&&e.animate)&&!this.getSize().contains(n))&&(this.panBy(n,e),!0)},_createAnimProxy:function(){var t=this._proxy=G("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",(function(t){var e=En,n=this._proxy.style[e];rt(this._proxy,this.project(t.center,t.zoom),this.getZoomScale(t.zoom,1)),n===this._proxy.style[e]&&this._animatingZoom&&this._onZoomTransitionEnd()}),this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){K(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var t=this.getCenter(),e=this.getZoom();rt(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,n){if(this._animatingZoom)return!0;if(n=n||{},!this._zoomAnimated||!1===n.animate||this._nothingToAnimate()||Math.abs(e-this._zoom)>this.options.zoomAnimationThreshold)return!1;var i=this.getZoomScale(e),o=this._getCenterOffset(t)._divideBy(1-1/i);return!(!0!==n.animate&&!this.getSize().contains(o))&&(f((function(){this._moveStart(!0,n.noMoveStart||!1)._animateZoom(t,e,!0)}),this),!0)},_animateZoom:function(t,e,i,o){this._mapPane&&(i&&(this._animatingZoom=!0,this._animateToCenter=t,this._animateToZoom=e,Q(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:t,zoom:e,noUpdate:o}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(n(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&tt(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))}}),qn=v.extend({options:{position:"topright"},initialize:function(t){p(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),n=this.getPosition(),i=t._controlCorners[n];return Q(e,"leaflet-control"),-1!==n.indexOf("bottom")?i.insertBefore(e,i.firstChild):i.appendChild(e),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(K(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(t){this._map&&t&&t.screenX>0&&t.screenY>0&&this._map.getContainer().focus()}}),Gn=function(t){return new qn(t)};Vn.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){function t(t,o){var s=n+t+" "+n+o;e[t+o]=G("div",s,i)}var e=this._controlCorners={},n="leaflet-",i=this._controlContainer=G("div",n+"control-container",this._container);t("top","left"),t("top","right"),t("bottom","left"),t("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)K(this._controlCorners[t]);K(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var Kn=qn.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,e,n,i){return n<i?-1:i<n?1:0}},initialize:function(t,e,n){for(var i in p(this,n),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1,this._preventClick=!1,t)this._addLayer(t[i],i);for(i in e)this._addLayer(e[i],i,!0)},onAdd:function(t){this._initLayout(),this._update(),this._map=t,t.on("zoomend",this._checkDisabledLayers,this);for(var e=0;e<this._layers.length;e++)this._layers[e].layer.on("add remove",this._onLayerChange,this);return this._container},addTo:function(t){return qn.prototype.addTo.call(this,t),this._expandIfNotCollapsed()},onRemove:function(){this._map.off("zoomend",this._checkDisabledLayers,this);for(var t=0;t<this._layers.length;t++)this._layers[t].layer.off("add remove",this._onLayerChange,this)},addBaseLayer:function(t,e){return this._addLayer(t,e),this._map?this._update():this},addOverlay:function(t,e){return this._addLayer(t,e,!0),this._map?this._update():this},removeLayer:function(t){t.off("add remove",this._onLayerChange,this);var e=this._getLayer(i(t));return e&&this._layers.splice(this._layers.indexOf(e),1),this._map?this._update():this},expand:function(){Q(this._container,"leaflet-control-layers-expanded"),this._section.style.height=null;var t=this._map.getSize().y-(this._container.offsetTop+50);return t<this._section.clientHeight?(Q(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=t+"px"):tt(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return tt(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var t="leaflet-control-layers",e=this._container=G("div",t),n=this.options.collapsed;e.setAttribute("aria-haspopup",!0),It(e),xt(e);var i=this._section=G("section",t+"-list");n&&(this._map.on("click",this.collapse,this),_t(e,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var o=this._layersLink=G("a",t+"-toggle",e);o.href="#",o.title="Layers",o.setAttribute("role","button"),_t(o,{keydown:function(t){13===t.keyCode&&this._expandSafely()},click:function(t){wt(t),this._expandSafely()}},this),n||this.expand(),this._baseLayersList=G("div",t+"-base",i),this._separator=G("div",t+"-separator",i),this._overlaysList=G("div",t+"-overlays",i),e.appendChild(i)},_getLayer:function(t){for(var e=0;e<this._layers.length;e++)if(this._layers[e]&&i(this._layers[e].layer)===t)return this._layers[e]},_addLayer:function(t,e,i){this._map&&t.on("add remove",this._onLayerChange,this),this._layers.push({layer:t,name:e,overlay:i}),this.options.sortLayers&&this._layers.sort(n((function(t,e){return this.options.sortFunction(t.layer,e.layer,t.name,e.name)}),this)),this.options.autoZIndex&&t.setZIndex&&(this._lastZIndex++,t.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Y(this._baseLayersList),Y(this._overlaysList),this._layerControlInputs=[];var t,e,n,i,o=0;for(n=0;n<this._layers.length;n++)i=this._layers[n],this._addItem(i),e=e||i.overlay,t=t||!i.overlay,o+=i.overlay?0:1;return this.options.hideSingleBase&&(t=t&&o>1,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(i(t.target)),n=e.overlay?"add"===t.type?"overlayadd":"overlayremove":"add"===t.type?"baselayerchange":null;n&&this._map.fire(n,e)},_createRadioElement:function(t,e){var n='<input type="radio" class="leaflet-control-layers-selector" name="'+t+'"'+(e?' checked="checked"':"")+"/>",i=document.createElement("div");return i.innerHTML=n,i.firstChild},_addItem:function(t){var e,n=document.createElement("label"),o=this._map.hasLayer(t.layer);t.overlay?((e=document.createElement("input")).type="checkbox",e.className="leaflet-control-layers-selector",e.defaultChecked=o):e=this._createRadioElement("leaflet-base-layers_"+i(this),o),this._layerControlInputs.push(e),e.layerId=i(t.layer),_t(e,"click",this._onInputClick,this);var s=document.createElement("span");s.innerHTML=" "+t.name;var r=document.createElement("span");return n.appendChild(r),r.appendChild(e),r.appendChild(s),(t.overlay?this._overlaysList:this._baseLayersList).appendChild(n),this._checkDisabledLayers(),n},_onInputClick:function(){if(!this._preventClick){var t,e,n=this._layerControlInputs,i=[],o=[];this._handlingClick=!0;for(var s=n.length-1;s>=0;s--)t=n[s],e=this._getLayer(t.layerId).layer,t.checked?i.push(e):t.checked||o.push(e);for(s=0;s<o.length;s++)this._map.hasLayer(o[s])&&this._map.removeLayer(o[s]);for(s=0;s<i.length;s++)this._map.hasLayer(i[s])||this._map.addLayer(i[s]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var t,e,n=this._layerControlInputs,i=this._map.getZoom(),o=n.length-1;o>=0;o--)t=n[o],e=this._getLayer(t.layerId).layer,t.disabled=void 0!==e.options.minZoom&&i<e.options.minZoom||void 0!==e.options.maxZoom&&i>e.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var t=this._section;this._preventClick=!0,_t(t,"click",wt),this.expand();var e=this;setTimeout((function(){ft(t,"click",wt),e._preventClick=!1}))}}),Yn=function(t,e,n){return new Kn(t,e,n)},Jn=qn.extend({options:{position:"topleft",zoomInText:'<span aria-hidden="true">+</span>',zoomInTitle:"Zoom in",zoomOutText:'<span aria-hidden="true">−</span>',zoomOutTitle:"Zoom out"},onAdd:function(t){var e="leaflet-control-zoom",n=G("div",e+" leaflet-bar"),i=this.options;return this._zoomInButton=this._createButton(i.zoomInText,i.zoomInTitle,e+"-in",n,this._zoomIn),this._zoomOutButton=this._createButton(i.zoomOutText,i.zoomOutTitle,e+"-out",n,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),n},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._zoom<this._map.getMaxZoom()&&this._map.zoomIn(this._map.options.zoomDelta*(t.shiftKey?3:1))},_zoomOut:function(t){!this._disabled&&this._map._zoom>this._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(t.shiftKey?3:1))},_createButton:function(t,e,n,i,o){var s=G("a",n,i);return s.innerHTML=t,s.href="#",s.title=e,s.setAttribute("role","button"),s.setAttribute("aria-label",e),It(s),_t(s,"click",Lt),_t(s,"click",o,this),_t(s,"click",this._refocusOnMap,this),s},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";tt(this._zoomInButton,e),tt(this._zoomOutButton,e),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||t._zoom===t.getMinZoom())&&(Q(this._zoomOutButton,e),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||t._zoom===t.getMaxZoom())&&(Q(this._zoomInButton,e),this._zoomInButton.setAttribute("aria-disabled","true"))}});Vn.mergeOptions({zoomControl:!0}),Vn.addInitHook((function(){this.options.zoomControl&&(this.zoomControl=new Jn,this.addControl(this.zoomControl))}));var Xn=function(t){return new Jn(t)},$n=qn.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",n=G("div",e),i=this.options;return this._addScales(i,e+"-line",n),t.on(i.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),n},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,e,n){t.metric&&(this._mScale=G("div",e,n)),t.imperial&&(this._iScale=G("div",e,n))},_update:function(){var t=this._map,e=t.getSize().y/2,n=t.distance(t.containerPointToLatLng([0,e]),t.containerPointToLatLng([this.options.maxWidth,e]));this._updateScales(n)},_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),n=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,n,e/t)},_updateImperial:function(t){var e,n,i,o=3.2808399*t;o>5280?(e=o/5280,n=this._getRoundNum(e),this._updateScale(this._iScale,n+" mi",n/e)):(i=this._getRoundNum(o),this._updateScale(this._iScale,i+" ft",i/o))},_updateScale:function(t,e,n){t.style.width=Math.round(this.options.maxWidth*n)+"px",t.innerHTML=e},_getRoundNum:function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),n=t/e;return e*(n=n>=10?10:n>=5?5:n>=3?3:n>=2?2:1)}}),Qn=function(t){return new $n(t)},ti='<svg aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="12" height="8" viewBox="0 0 12 8" class="leaflet-attribution-flag"><path fill="#4C7BE1" d="M0 0h12v4H0z"/><path fill="#FFD500" d="M0 4h12v3H0z"/><path fill="#E0BC00" d="M0 7h12v1H0z"/></svg>',ei=qn.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(Pn.inlineSvg?ti+" ":"")+"Leaflet</a>"},initialize:function(t){p(this,t),this._attributions={}},onAdd:function(t){for(var e in t.attributionControl=this,this._container=G("div","leaflet-control-attribution"),It(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):this},removeAttribution:function(t){return t?(this._attributions[t]&&(this._attributions[t]--,this._update()),this):this},_update:function(){if(this._map){var t=[];for(var e in this._attributions)this._attributions[e]&&t.push(e);var n=[];this.options.prefix&&n.push(this.options.prefix),t.length&&n.push(t.join(", ")),this._container.innerHTML=n.join(' <span aria-hidden="true">|</span> ')}}});Vn.mergeOptions({attributionControl:!0}),Vn.addInitHook((function(){this.options.attributionControl&&(new ei).addTo(this)}));var ni=function(t){return new ei(t)};qn.Layers=Kn,qn.Zoom=Jn,qn.Scale=$n,qn.Attribution=ei,Gn.layers=Yn,Gn.zoom=Xn,Gn.scale=Qn,Gn.attribution=ni;var ii=v.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):this},enabled:function(){return!!this._enabled}});ii.addTo=function(t,e){return t.addHandler(e,this),this};var oi,si={Events:Me},ri=Pn.touch?"touchstart mousedown":"mousedown",ai=ze.extend({options:{clickTolerance:3},initialize:function(t,e,n,i){p(this,i),this._element=t,this._dragStartTarget=e||t,this._preventOutline=n},enable:function(){this._enabled||(_t(this._dragStartTarget,ri,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(ai._dragging===this&&this.finishDrag(!0),ft(this._dragStartTarget,ri,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(this._enabled&&(this._moved=!1,!$(this._element,"leaflet-zoom-anim")))if(t.touches&&1!==t.touches.length)ai._dragging===this&&this.finishDrag();else if(!(ai._dragging||t.shiftKey||1!==t.which&&1!==t.button&&!t.touches||(ai._dragging=this,this._preventOutline&&ut(this._element),ht(),Ze(),this._moving))){this.fire("down");var e=t.touches?t.touches[0]:t,n=dt(this._element);this._startPoint=new y(e.clientX,e.clientY),this._startPos=lt(this._element),this._parentScale=mt(n);var i="mousedown"===t.type;_t(document,i?"mousemove":"touchmove",this._onMove,this),_t(document,i?"mouseup":"touchend touchcancel",this._onUp,this)}},_onMove:function(t){if(this._enabled)if(t.touches&&t.touches.length>1)this._moved=!0;else{var e=t.touches&&1===t.touches.length?t.touches[0]:t,n=new y(e.clientX,e.clientY)._subtract(this._startPoint);(n.x||n.y)&&(Math.abs(n.x)+Math.abs(n.y)<this.options.clickTolerance||(n.x/=this._parentScale.x,n.y/=this._parentScale.y,wt(t),this._moved||(this.fire("dragstart"),this._moved=!0,Q(document.body,"leaflet-dragging"),this._lastTarget=t.target||t.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),Q(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(n),this._moving=!0,this._lastEvent=t,this._updatePosition()))}},_updatePosition:function(){var t={originalEvent:this._lastEvent};this.fire("predrag",t),at(this._element,this._newPos),this.fire("drag",t)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(t){tt(document.body,"leaflet-dragging"),this._lastTarget&&(tt(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),ft(document,"mousemove touchmove",this._onMove,this),ft(document,"mouseup touchend touchcancel",this._onUp,this),pt(),Ae();var e=this._moved&&this._moving;this._moving=!1,ai._dragging=!1,e&&this.fire("dragend",{noInertia:t,distance:this._newPos.distanceTo(this._startPos)})}}),li={__proto__:null,clipPolygon:St,polygonCenter:jt,centroid:Ct},hi={__proto__:null,simplify:Rt,pointToSegmentDistance:Ot,closestPointOnSegment:Et,clipSegment:Nt,_getEdgeIntersection:Dt,_getBitCode:Ft,_sqClosestPointOnSegment:Wt,isFlat:Ut,_flat:Vt,polylineCenter:qt},pi={project:function(t){return new y(t.lng,t.lat)},unproject:function(t){return new M(t.y,t.x)},bounds:new I([-180,-90],[180,90])},ui={R:6378137,R_MINOR:6356752.314245179,bounds:new I([-20037508.34279,-15496570.73972],[20037508.34279,18764656.23138]),project:function(t){var e=Math.PI/180,n=this.R,i=t.lat*e,o=this.R_MINOR/n,s=Math.sqrt(1-o*o),r=s*Math.sin(i),a=Math.tan(Math.PI/4-i/2)/Math.pow((1-r)/(1+r),s/2);return i=-n*Math.log(Math.max(a,1e-10)),new y(t.lng*e*n,i)},unproject:function(t){for(var e,n=180/Math.PI,i=this.R,o=this.R_MINOR/i,s=Math.sqrt(1-o*o),r=Math.exp(-t.y/i),a=Math.PI/2-2*Math.atan(r),l=0,h=.1;l<15&&Math.abs(h)>1e-7;l++)e=s*Math.sin(a),e=Math.pow((1-e)/(1+e),s/2),a+=h=Math.PI/2-2*Math.atan(r*e)-a;return new M(a*n,t.x*n/i)}},ci={__proto__:null,LonLat:pi,Mercator:ui,SphericalMercator:Oe},di=e({},Ce,{code:"EPSG:3395",projection:ui,transformation:function(){var t=.5/(Math.PI*ui.R);return S(t,.5,-t,.5)}()}),mi=e({},Ce,{code:"EPSG:4326",projection:pi,transformation:S(1/180,1,-1/180,.5)}),_i=e({},je,{projection:pi,transformation:S(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 n=e.lng-t.lng,i=e.lat-t.lat;return Math.sqrt(n*n+i*i)},infinite:!0});je.Earth=Ce,je.EPSG3395=di,je.EPSG3857=Fe,je.EPSG900913=He,je.EPSG4326=mi,je.Simple=_i;var fi=ze.extend({options:{pane:"overlayPane",
|
|
// String to be shown in the attribution control, e.g. "© OpenStreetMap contributors". It describes the layer data and is often a legal obligation towards copyright holders and tile providers.
|
|
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[i(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[i(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 n=this.getEvents();e.on(n,this),this.once("remove",(function(){e.off(n,this)}),this)}this.onAdd(e),this.fire("add"),e.fire("layeradd",{layer:this})}}});Vn.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var e=i(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=i(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):this},hasLayer:function(t){return i(t)in this._layers},eachLayer:function(t,e){for(var n in this._layers)t.call(e,this._layers[n]);return this},_addLayers:function(t){for(var e=0,n=(t=t?xe(t)?t:[t]:[]).length;e<n;e++)this.addLayer(t[e])},_addZoomLimit:function(t){isNaN(t.options.maxZoom)&&isNaN(t.options.minZoom)||(this._zoomBoundLayers[i(t)]=t,this._updateZoomLevels())},_removeZoomLimit:function(t){var e=i(t);this._zoomBoundLayers[e]&&(delete this._zoomBoundLayers[e],this._updateZoomLevels())},_updateZoomLevels:function(){var t=1/0,e=-1/0,n=this._getZoomSpan();for(var i in this._zoomBoundLayers){var o=this._zoomBoundLayers[i].options;t=void 0===o.minZoom?t:Math.min(t,o.minZoom),e=void 0===o.maxZoom?e:Math.max(e,o.maxZoom)}this._layersMaxZoom=e===-1/0?void 0:e,this._layersMinZoom=t===1/0?void 0:t,n!==this._getZoomSpan()&&this.fire("zoomlevelschange"),void 0===this.options.maxZoom&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),void 0===this.options.minZoom&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var gi=fi.extend({initialize:function(t,e){var n,i;if(p(this,e),this._layers={},t)for(n=0,i=t.length;n<i;n++)this.addLayer(t[n])},addLayer:function(t){var e=this.getLayerId(t);return this._layers[e]=t,this._map&&this._map.addLayer(t),this},removeLayer:function(t){var e=t in this._layers?t:this.getLayerId(t);return this._map&&this._layers[e]&&this._map.removeLayer(this._layers[e]),delete this._layers[e],this},hasLayer:function(t){return("number"==typeof t?t:this.getLayerId(t))in this._layers},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(t){var e,n,i=Array.prototype.slice.call(arguments,1);for(e in this._layers)(n=this._layers[e])[t]&&n[t].apply(n,i);return this},onAdd:function(t){this.eachLayer(t.addLayer,t)},onRemove:function(t){this.eachLayer(t.removeLayer,t)},eachLayer:function(t,e){for(var n in this._layers)t.call(e,this._layers[n]);return this},getLayer:function(t){return this._layers[t]},getLayers:function(){var t=[];return this.eachLayer(t.push,t),t},setZIndex:function(t){return this.invoke("setZIndex",t)},getLayerId:function(t){return i(t)}}),vi=function(t,e){return new gi(t,e)},bi=gi.extend({addLayer:function(t){return this.hasLayer(t)?this:(t.addEventParent(this),gi.prototype.addLayer.call(this,t),this.fire("layeradd",{layer:t}))},removeLayer:function(t){return this.hasLayer(t)?(t in this._layers&&(t=this._layers[t]),t.removeEventParent(this),gi.prototype.removeLayer.call(this,t),this.fire("layerremove",{layer:t})):this},setStyle:function(t){return this.invoke("setStyle",t)},bringToFront:function(){return this.invoke("bringToFront")},bringToBack:function(){return this.invoke("bringToBack")},getBounds:function(){var t=new P;for(var e in this._layers){var n=this._layers[e];t.extend(n.getBounds?n.getBounds():n.getLatLng())}return t}}),yi=function(t,e){return new bi(t,e)},xi=v.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0],crossOrigin:!1},initialize:function(t){p(this,t)},createIcon:function(t){return this._createIcon("icon",t)},createShadow:function(t){return this._createIcon("shadow",t)},_createIcon:function(t,e){var n=this._getIconUrl(t);if(!n){if("icon"===t)throw new Error("iconUrl not set in Icon options (see the docs).");return null}var i=this._createImg(n,e&&"IMG"===e.tagName?e:null);return this._setIconStyles(i,t),(this.options.crossOrigin||""===this.options.crossOrigin)&&(i.crossOrigin=!0===this.options.crossOrigin?"":this.options.crossOrigin),i},_setIconStyles:function(t,e){var n=this.options,i=n[e+"Size"];"number"==typeof i&&(i=[i,i]);var o=x(i),s=x("shadow"===e&&n.shadowAnchor||n.iconAnchor||o&&o.divideBy(2,!0));t.className="leaflet-marker-"+e+" "+(n.className||""),s&&(t.style.marginLeft=-s.x+"px",t.style.marginTop=-s.y+"px"),o&&(t.style.width=o.x+"px",t.style.height=o.y+"px")},_createImg:function(t,e){return(e=e||document.createElement("img")).src=t,e},_getIconUrl:function(t){return Pn.retina&&this.options[t+"RetinaUrl"]||this.options[t+"Url"]}}),Ii=xi.extend({options:{iconUrl:"marker-icon.png",iconRetinaUrl:"marker-icon-2x.png",shadowUrl:"marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[16,-28],shadowSize:[41,41]},_getIconUrl:function(t){return"string"!=typeof Ii.imagePath&&(Ii.imagePath=this._detectIconPath()),(this.options.imagePath||Ii.imagePath)+xi.prototype._getIconUrl.call(this,t)},_stripUrl:function(t){var e=function(t,e,n){var i=e.exec(t);return i&&i[n]};return(t=e(t,/^url\((['"])?(.+)\1\)$/,2))&&e(t,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var t=G("div","leaflet-default-icon-path",document.body),e=q(t,"background-image")||q(t,"backgroundImage");if(document.body.removeChild(t),e=this._stripUrl(e))return e;var n=document.querySelector('link[href$="leaflet.css"]');return n?n.href.substring(0,n.href.length-11-1):""}}),wi=ii.extend({initialize:function(t){this._marker=t},addHooks:function(){var t=this._marker._icon;this._draggable||(this._draggable=new ai(t,t,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),Q(t,"leaflet-marker-draggable")},removeHooks:function(){this._draggable.off({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).disable(),this._marker._icon&&tt(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(t){var e=this._marker,n=e._map,i=this._marker.options.autoPanSpeed,o=this._marker.options.autoPanPadding,s=lt(e._icon),r=n.getPixelBounds(),a=n.getPixelOrigin(),l=w(r.min._subtract(a).add(o),r.max._subtract(a).subtract(o));if(!l.contains(s)){var h=x((Math.max(l.max.x,s.x)-l.max.x)/(r.max.x-l.max.x)-(Math.min(l.min.x,s.x)-l.min.x)/(r.min.x-l.min.x),(Math.max(l.max.y,s.y)-l.max.y)/(r.max.y-l.max.y)-(Math.min(l.min.y,s.y)-l.min.y)/(r.min.y-l.min.y)).multiplyBy(i);n.panBy(h,{animate:!1}),this._draggable._newPos._add(h),this._draggable._startPos._add(h),at(e._icon,this._draggable._newPos),this._onDrag(t),this._panRequest=f(this._adjustPan.bind(this,t))}},_onDragStart:function(){this._oldLatLng=this._marker.getLatLng(),this._marker.closePopup&&this._marker.closePopup(),this._marker.fire("movestart").fire("dragstart")},_onPreDrag:function(t){this._marker.options.autoPan&&(g(this._panRequest),this._panRequest=f(this._adjustPan.bind(this,t)))},_onDrag:function(t){var e=this._marker,n=e._shadow,i=lt(e._icon),o=e._map.layerPointToLatLng(i);n&&at(n,i),e._latlng=o,t.latlng=o,t.oldLatLng=this._oldLatLng,e.fire("move",t).fire("drag",t)},_onDragEnd:function(t){g(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",t)}}),Li=fi.extend({options:{icon:new Ii,interactive:!0,keyboard:!0,title:"",alt:"Marker",zIndexOffset:0,opacity:1,riseOnHover:!1,riseOffset:250,pane:"markerPane",shadowPane:"shadowPane",bubblingMouseEvents:!1,autoPanOnFocus:!0,draggable:!1,autoPan:!1,autoPanPadding:[50,50],autoPanSpeed:10},initialize:function(t,e){p(this,e),this._latlng=z(t)},onAdd:function(t){this._zoomAnimated=this._zoomAnimated&&t.options.markerZoomAnimation,this._zoomAnimated&&t.on("zoomanim",this._animateZoom,this),this._initIcon(),this.update()},onRemove:function(t){this.dragging&&this.dragging.enabled()&&(this.options.draggable=!0,this.dragging.removeHooks()),delete this.dragging,this._zoomAnimated&&t.off("zoomanim",this._animateZoom,this),this._removeIcon(),this._removeShadow()},getEvents:function(){return{zoom:this.update,viewreset:this.update}},getLatLng:function(){return this._latlng},setLatLng:function(t){var e=this._latlng;return this._latlng=z(t),this.update(),this.fire("move",{oldLatLng:e,latlng:this._latlng})},setZIndexOffset:function(t){return this.options.zIndexOffset=t,this.update()},getIcon:function(){return this.options.icon},setIcon:function(t){return this.options.icon=t,this._map&&(this._initIcon(),this.update()),this._popup&&this.bindPopup(this._popup,this._popup.options),this},getElement:function(){return this._icon},update:function(){if(this._icon&&this._map){var t=this._map.latLngToLayerPoint(this._latlng).round();this._setPos(t)}return this},_initIcon:function(){var t=this.options,e="leaflet-zoom-"+(this._zoomAnimated?"animated":"hide"),n=t.icon.createIcon(this._icon),i=!1;n!==this._icon&&(this._icon&&this._removeIcon(),i=!0,t.title&&(n.title=t.title),"IMG"===n.tagName&&(n.alt=t.alt||"")),Q(n,e),t.keyboard&&(n.tabIndex="0",n.setAttribute("role","button")),this._icon=n,t.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&_t(n,"focus",this._panOnFocus,this);var o=t.icon.createShadow(this._shadow),s=!1;o!==this._shadow&&(this._removeShadow(),s=!0),o&&(Q(o,e),o.alt=""),this._shadow=o,t.opacity<1&&this._updateOpacity(),i&&this.getPane().appendChild(this._icon),this._initInteraction(),o&&s&&this.getPane(t.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&ft(this._icon,"focus",this._panOnFocus,this),K(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&K(this._shadow),this._shadow=null},_setPos:function(t){this._icon&&at(this._icon,t),this._shadow&&at(this._shadow,t),this._zIndex=t.y+this.options.zIndexOffset,this._resetZIndex()},_updateZIndex:function(t){this._icon&&(this._icon.style.zIndex=this._zIndex+t)},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center).round();this._setPos(e)},_initInteraction:function(){if(this.options.interactive&&(Q(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),wi)){var t=this.options.draggable;this.dragging&&(t=this.dragging.enabled(),this.dragging.disable()),this.dragging=new wi(this),t&&this.dragging.enable()}},setOpacity:function(t){return this.options.opacity=t,this._map&&this._updateOpacity(),this},_updateOpacity:function(){var t=this.options.opacity;this._icon&&it(this._icon,t),this._shadow&&it(this._shadow,t)},_bringToFront:function(){this._updateZIndex(this.options.riseOffset)},_resetZIndex:function(){this._updateZIndex(0)},_panOnFocus:function(){var t=this._map;if(t){var e=this.options.icon.options,n=e.iconSize?x(e.iconSize):x(0,0),i=e.iconAnchor?x(e.iconAnchor):x(0,0);t.panInside(this._latlng,{paddingTopLeft:i,paddingBottomRight:n.subtract(i)})}},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}}),Pi=fi.extend({options:{stroke:!0,color:"#3388ff",weight:3,opacity:1,lineCap:"round",lineJoin:"round",dashArray:null,dashOffset:null,fill:!1,fillColor:null,fillOpacity:.2,fillRule:"evenodd",interactive:!0,bubblingMouseEvents:!0},beforeAdd:function(t){this._renderer=t.getRenderer(this)},onAdd:function(){this._renderer._initPath(this),this._reset(),this._renderer._addPath(this)},onRemove:function(){this._renderer._removePath(this)},redraw:function(){return this._map&&this._renderer._updatePath(this),this},setStyle:function(t){return p(this,t),this._renderer&&(this._renderer._updateStyle(this),this.options.stroke&&t&&Object.prototype.hasOwnProperty.call(t,"weight")&&this._updateBounds()),this},bringToFront:function(){return this._renderer&&this._renderer._bringToFront(this),this},bringToBack:function(){return this._renderer&&this._renderer._bringToBack(this),this},getElement:function(){return this._path},_reset:function(){this._project(),this._update()},_clickTolerance:function(){return(this.options.stroke?this.options.weight/2:0)+(this._renderer.options.tolerance||0)}}),Ti=Pi.extend({options:{fill:!0,radius:10},initialize:function(t,e){p(this,e),this._latlng=z(t),this._radius=this.options.radius},setLatLng:function(t){var e=this._latlng;return this._latlng=z(t),this.redraw(),this.fire("move",{oldLatLng:e,latlng:this._latlng})},getLatLng:function(){return this._latlng},setRadius:function(t){return this.options.radius=this._radius=t,this.redraw()},getRadius:function(){return this._radius},setStyle:function(t){var e=t&&t.radius||this._radius;return Pi.prototype.setStyle.call(this,t),this.setRadius(e),this},_project:function(){this._point=this._map.latLngToLayerPoint(this._latlng),this._updateBounds()},_updateBounds:function(){var t=this._radius,e=this._radiusY||t,n=this._clickTolerance(),i=[t+n,e+n];this._pxBounds=new I(this._point.subtract(i),this._point.add(i))},_update:function(){this._map&&this._updatePath()},_updatePath:function(){this._renderer._updateCircle(this)},_empty:function(){return this._radius&&!this._renderer._bounds.intersects(this._pxBounds)},_containsPoint:function(t){return t.distanceTo(this._point)<=this._radius+this._clickTolerance()}}),Mi=Ti.extend({initialize:function(t,n,i){if("number"==typeof n&&(n=e({},i,{radius:n})),p(this,n),this._latlng=z(t),isNaN(this.options.radius))throw new Error("Circle radius cannot be NaN");this._mRadius=this.options.radius},setRadius:function(t){return this._mRadius=t,this.redraw()},getRadius:function(){return this._mRadius},getBounds:function(){var t=[this._radius,this._radiusY||this._radius];return new P(this._map.layerPointToLatLng(this._point.subtract(t)),this._map.layerPointToLatLng(this._point.add(t)))},setStyle:Pi.prototype.setStyle,_project:function(){var t=this._latlng.lng,e=this._latlng.lat,n=this._map,i=n.options.crs;if(i.distance===Ce.distance){var o=Math.PI/180,s=this._mRadius/Ce.R/o,r=n.project([e+s,t]),a=n.project([e-s,t]),l=r.add(a).divideBy(2),h=n.unproject(l).lat,p=Math.acos((Math.cos(s*o)-Math.sin(e*o)*Math.sin(h*o))/(Math.cos(e*o)*Math.cos(h*o)))/o;(isNaN(p)||0===p)&&(p=s/Math.cos(Math.PI/180*e)),this._point=l.subtract(n.getPixelOrigin()),this._radius=isNaN(p)?0:l.x-n.project([h,t-p]).x,this._radiusY=l.y-r.y}else{var u=i.unproject(i.project(this._latlng).subtract([this._mRadius,0]));this._point=n.latLngToLayerPoint(this._latlng),this._radius=this._point.x-n.latLngToLayerPoint(u).x}this._updateBounds()}}),zi=Pi.extend({options:{smoothFactor:1,noClip:!1},initialize:function(t,e){p(this,e),this._setLatLngs(t)},getLatLngs:function(){return this._latlngs},setLatLngs:function(t){return this._setLatLngs(t),this.redraw()},isEmpty:function(){return!this._latlngs.length},closestLayerPoint:function(t){for(var e,n,i=1/0,o=null,s=Wt,r=0,a=this._parts.length;r<a;r++)for(var l=this._parts[r],h=1,p=l.length;h<p;h++){var u=s(t,e=l[h-1],n=l[h],!0);u<i&&(i=u,o=s(t,e,n))}return o&&(o.distance=Math.sqrt(i)),o},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return qt(this._defaultShape(),this._map.options.crs)},getBounds:function(){return this._bounds},addLatLng:function(t,e){return e=e||this._defaultShape(),t=z(t),e.push(t),this._bounds.extend(t),this.redraw()},_setLatLngs:function(t){this._bounds=new P,this._latlngs=this._convertLatLngs(t)},_defaultShape:function(){return Ut(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(t){for(var e=[],n=Ut(t),i=0,o=t.length;i<o;i++)n?(e[i]=z(t[i]),this._bounds.extend(e[i])):e[i]=this._convertLatLngs(t[i]);return e},_project:function(){var t=new I;this._rings=[],this._projectLatlngs(this._latlngs,this._rings,t),this._bounds.isValid()&&t.isValid()&&(this._rawPxBounds=t,this._updateBounds())},_updateBounds:function(){var t=this._clickTolerance(),e=new y(t,t);this._rawPxBounds&&(this._pxBounds=new I([this._rawPxBounds.min.subtract(e),this._rawPxBounds.max.add(e)]))},_projectLatlngs:function(t,e,n){var i,o,s=t[0]instanceof M,r=t.length;if(s){for(o=[],i=0;i<r;i++)o[i]=this._map.latLngToLayerPoint(t[i]),n.extend(o[i]);e.push(o)}else for(i=0;i<r;i++)this._projectLatlngs(t[i],e,n)},_clipPoints:function(){var t=this._renderer._bounds;if(this._parts=[],this._pxBounds&&this._pxBounds.intersects(t))if(this.options.noClip)this._parts=this._rings;else{var e,n,i,o,s,r,a,l=this._parts;for(e=0,i=0,o=this._rings.length;e<o;e++)for(n=0,s=(a=this._rings[e]).length;n<s-1;n++)(r=Nt(a[n],a[n+1],t,n,!0))&&(l[i]=l[i]||[],l[i].push(r[0]),r[1]===a[n+1]&&n!==s-2||(l[i].push(r[1]),i++))}},_simplifyPoints:function(){for(var t=this._parts,e=this.options.smoothFactor,n=0,i=t.length;n<i;n++)t[n]=Rt(t[n],e)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(t,e){var n,i,o,s,r,a,l=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(n=0,s=this._parts.length;n<s;n++)for(i=0,o=(r=(a=this._parts[n]).length)-1;i<r;o=i++)if((e||0!==i)&&Ot(t,a[o],a[i])<=l)return!0;return!1}});zi._flat=Vt;var ki=zi.extend({options:{fill:!0},isEmpty:function(){return!this._latlngs.length||!this._latlngs[0].length},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return jt(this._defaultShape(),this._map.options.crs)},_convertLatLngs:function(t){var e=zi.prototype._convertLatLngs.call(this,t),n=e.length;return n>=2&&e[0]instanceof M&&e[0].equals(e[n-1])&&e.pop(),e},_setLatLngs:function(t){zi.prototype._setLatLngs.call(this,t),Ut(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return Ut(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,e=this.options.weight,n=new y(e,e);if(t=new I(t.min.subtract(n),t.max.add(n)),this._parts=[],this._pxBounds&&this._pxBounds.intersects(t))if(this.options.noClip)this._parts=this._rings;else for(var i,o=0,s=this._rings.length;o<s;o++)(i=St(this._rings[o],t,!0)).length&&this._parts.push(i)},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(t){var e,n,i,o,s,r,a,l,h=!1;if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(o=0,a=this._parts.length;o<a;o++)for(s=0,r=(l=(e=this._parts[o]).length)-1;s<l;r=s++)n=e[s],i=e[r],n.y>t.y!=i.y>t.y&&t.x<(i.x-n.x)*(t.y-n.y)/(i.y-n.y)+n.x&&(h=!h);return h||zi.prototype._containsPoint.call(this,t,!0)}}),Si=bi.extend({initialize:function(t,e){p(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e,n,i,o=xe(t)?t:t.features;if(o){for(e=0,n=o.length;e<n;e++)((i=o[e]).geometries||i.geometry||i.features||i.coordinates)&&this.addData(i);return this}var s=this.options;if(s.filter&&!s.filter(t))return this;var r=Qt(t,s);return r?(r.feature=re(t),r.defaultOptions=r.options,this.resetStyle(r),s.onEachFeature&&s.onEachFeature(t,r),this.addLayer(r)):this},resetStyle:function(t){return void 0===t?this.eachLayer(this.resetStyle,this):(t.options=e({},t.defaultOptions),this._setLayerStyle(t,this.options.style),this)},setStyle:function(t){return this.eachLayer((function(e){this._setLayerStyle(e,t)}),this)},_setLayerStyle:function(t,e){t.setStyle&&("function"==typeof e&&(e=e(t.feature)),t.setStyle(e))}}),ji={toGeoJSON:function(t){return se(this,{type:"Point",coordinates:ie(this.getLatLng(),t)})}};Li.include(ji),Mi.include(ji),Ti.include(ji),zi.include({toGeoJSON:function(t){var e=!Ut(this._latlngs);return se(this,{type:(e?"Multi":"")+"LineString",coordinates:oe(this._latlngs,e?1:0,!1,t)})}}),ki.include({toGeoJSON:function(t){var e=!Ut(this._latlngs),n=e&&!Ut(this._latlngs[0]),i=oe(this._latlngs,n?2:e?1:0,!0,t);return e||(i=[i]),se(this,{type:(n?"Multi":"")+"Polygon",coordinates:i})}}),gi.include({toMultiPoint:function(t){var e=[];return this.eachLayer((function(n){e.push(n.toGeoJSON(t).geometry.coordinates)})),se(this,{type:"MultiPoint",coordinates:e})},toGeoJSON:function(t){var e=this.feature&&this.feature.geometry&&this.feature.geometry.type;if("MultiPoint"===e)return this.toMultiPoint(t);var n="GeometryCollection"===e,i=[];return this.eachLayer((function(e){if(e.toGeoJSON){var o=e.toGeoJSON(t);if(n)i.push(o.geometry);else{var s=re(o);"FeatureCollection"===s.type?i.push.apply(i,s.features):i.push(s)}}})),n?se(this,{geometries:i,type:"GeometryCollection"}):{type:"FeatureCollection",features:i}}});var Ci=ae,Ri=fi.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(t,e,n){this._url=t,this._bounds=T(e),p(this,n)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(Q(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){K(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(t){return this.options.opacity=t,this._image&&this._updateOpacity(),this},setStyle:function(t){return t.opacity&&this.setOpacity(t.opacity),this},bringToFront:function(){return this._map&&J(this._image),this},bringToBack:function(){return this._map&&X(this._image),this},setUrl:function(t){return this._url=t,this._image&&(this._image.src=t),this},setBounds:function(t){return this._bounds=T(t),this._map&&this._reset(),this},getEvents:function(){var t={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},setZIndex:function(t){return this.options.zIndex=t,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var t="IMG"===this._url.tagName,e=this._image=t?this._url:G("img");Q(e,"leaflet-image-layer"),this._zoomAnimated&&Q(e,"leaflet-zoom-animated"),this.options.className&&Q(e,this.options.className),e.onselectstart=r,e.onmousemove=r,e.onload=n(this.fire,this,"load"),e.onerror=n(this._overlayOnError,this,"error"),(this.options.crossOrigin||""===this.options.crossOrigin)&&(e.crossOrigin=!0===this.options.crossOrigin?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),t?this._url=e.src:(e.src=this._url,e.alt=this.options.alt)},_animateZoom:function(t){var e=this._map.getZoomScale(t.zoom),n=this._map._latLngBoundsToNewLayerBounds(this._bounds,t.zoom,t.center).min;rt(this._image,n,e)},_reset:function(){var t=this._image,e=new I(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),n=e.getSize();at(t,e.min),t.style.width=n.x+"px",t.style.height=n.y+"px"},_updateOpacity:function(){it(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&void 0!==this.options.zIndex&&null!==this.options.zIndex&&(this._image.style.zIndex=this.options.zIndex)},_overlayOnError:function(){this.fire("error");var t=this.options.errorOverlayUrl;t&&this._url!==t&&(this._url=t,this._image.src=t)},getCenter:function(){return this._bounds.getCenter()}}),Oi=function(t,e,n){return new Ri(t,e,n)},Ei=Ri.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var t="VIDEO"===this._url.tagName,e=this._image=t?this._url:G("video");if(Q(e,"leaflet-image-layer"),this._zoomAnimated&&Q(e,"leaflet-zoom-animated"),this.options.className&&Q(e,this.options.className),e.onselectstart=r,e.onmousemove=r,e.onloadeddata=n(this.fire,this,"load"),t){for(var i=e.getElementsByTagName("source"),o=[],s=0;s<i.length;s++)o.push(i[s].src);this._url=i.length>0?o:[e.src]}else{xe(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 a=0;a<this._url.length;a++){var l=G("source");l.src=this._url[a],e.appendChild(l)}}}}),Zi=Ri.extend({_initImage:function(){var t=this._image=this._url;Q(t,"leaflet-image-layer"),this._zoomAnimated&&Q(t,"leaflet-zoom-animated"),this.options.className&&Q(t,this.options.className),t.onselectstart=r,t.onmousemove=r}}),Ai=fi.extend({options:{interactive:!1,offset:[0,0],className:"",pane:void 0,content:""},initialize:function(t,e){t&&(t instanceof M||xe(t))?(this._latlng=z(t),p(this,e)):(p(this,t),this._source=e),this.options.content&&(this._content=this.options.content)},openOn:function(t){return(t=arguments.length?t:this._source._map).hasLayer(this)||t.addLayer(this),this},close:function(){return this._map&&this._map.removeLayer(this),this},toggle:function(t){return this._map?this.close():(arguments.length?this._source=t:t=this._source,this._prepareOpen(),this.openOn(t._map)),this},onAdd:function(t){this._zoomAnimated=t._zoomAnimated,this._container||this._initLayout(),t._fadeAnimated&&it(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),t._fadeAnimated&&it(this._container,1),this.bringToFront(),this.options.interactive&&(Q(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(t){t._fadeAnimated?(it(this._container,0),this._removeTimeout=setTimeout(n(K,void 0,this._container),200)):K(this._container),this.options.interactive&&(tt(this._container,"leaflet-interactive"),this.removeInteractiveTarget(this._container))},getLatLng:function(){return this._latlng},setLatLng:function(t){return this._latlng=z(t),this._map&&(this._updatePosition(),this._adjustPan()),this},getContent:function(){return this._content},setContent:function(t){return this._content=t,this.update(),this},getElement:function(){return this._container},update:function(){this._map&&(this._container.style.visibility="hidden",this._updateContent(),this._updateLayout(),this._updatePosition(),this._container.style.visibility="",this._adjustPan())},getEvents:function(){var t={zoom:this._updatePosition,viewreset:this._updatePosition};return this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},isOpen:function(){return!!this._map&&this._map.hasLayer(this)},bringToFront:function(){return this._map&&J(this._container),this},bringToBack:function(){return this._map&&X(this._container),this},_prepareOpen:function(t){var e=this._source;if(!e._map)return!1;if(e instanceof bi){e=null;var n=this._source._layers;for(var i in n)if(n[i]._map){e=n[i];break}if(!e)return!1;this._source=e}if(!t)if(e.getCenter)t=e.getCenter();else if(e.getLatLng)t=e.getLatLng();else{if(!e.getBounds)throw new Error("Unable to get source layer LatLng.");t=e.getBounds().getCenter()}return this.setLatLng(t),this._map&&this.update(),!0},_updateContent:function(){if(this._content){var t=this._contentNode,e="function"==typeof this._content?this._content(this._source||this):this._content;if("string"==typeof e)t.innerHTML=e;else{for(;t.hasChildNodes();)t.removeChild(t.firstChild);t.appendChild(e)}this.fire("contentupdate")}},_updatePosition:function(){if(this._map){var t=this._map.latLngToLayerPoint(this._latlng),e=x(this.options.offset),n=this._getAnchor();this._zoomAnimated?at(this._container,t.add(n)):e=e.add(t).add(n);var i=this._containerBottom=-e.y,o=this._containerLeft=-Math.round(this._containerWidth/2)+e.x;this._container.style.bottom=i+"px",this._container.style.left=o+"px"}},_getAnchor:function(){return[0,0]}});Vn.include({_initOverlay:function(t,e,n,i){var o=e;return o instanceof t||(o=new t(i).setContent(e)),n&&o.setLatLng(n),o}}),fi.include({_initOverlay:function(t,e,n,i){var o=n;return o instanceof t?(p(o,i),o._source=this):(o=e&&!i?e:new t(i,this)).setContent(n),o}});var Bi=Ai.extend({options:{pane:"popupPane",offset:[0,7],maxWidth:300,minWidth:50,maxHeight:null,autoPan:!0,autoPanPaddingTopLeft:null,autoPanPaddingBottomRight:null,autoPanPadding:[5,5],keepInView:!1,closeButton:!0,autoClose:!0,closeOnEscapeKey:!0,className:""},openOn:function(t){return!(t=arguments.length?t:this._source._map).hasLayer(this)&&t._popup&&t._popup.options.autoClose&&t.removeLayer(t._popup),t._popup=this,Ai.prototype.openOn.call(this,t)},onAdd:function(t){Ai.prototype.onAdd.call(this,t),t.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof Pi||this._source.on("preclick",yt))},onRemove:function(t){Ai.prototype.onRemove.call(this,t),t.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof Pi||this._source.off("preclick",yt))},getEvents:function(){var t=Ai.prototype.getEvents.call(this);return(void 0!==this.options.closeOnClick?this.options.closeOnClick:this._map.options.closePopupOnClick)&&(t.preclick=this.close),this.options.keepInView&&(t.moveend=this._adjustPan),t},_initLayout:function(){var t="leaflet-popup",e=this._container=G("div",t+" "+(this.options.className||"")+" leaflet-zoom-animated"),n=this._wrapper=G("div",t+"-content-wrapper",e);if(this._contentNode=G("div",t+"-content",n),It(e),xt(this._contentNode),_t(e,"contextmenu",yt),this._tipContainer=G("div",t+"-tip-container",e),this._tip=G("div",t+"-tip",this._tipContainer),this.options.closeButton){var i=this._closeButton=G("a",t+"-close-button",e);i.setAttribute("role","button"),i.setAttribute("aria-label","Close popup"),i.href="#close",i.innerHTML='<span aria-hidden="true">×</span>',_t(i,"click",(function(t){wt(t),this.close()}),this)}},_updateLayout:function(){var t=this._contentNode,e=t.style;e.width="",e.whiteSpace="nowrap";var n=t.offsetWidth;n=Math.min(n,this.options.maxWidth),n=Math.max(n,this.options.minWidth),e.width=n+1+"px",e.whiteSpace="",e.height="";var i=t.offsetHeight,o=this.options.maxHeight,s="leaflet-popup-scrolled";o&&i>o?(e.height=o+"px",Q(t,s)):tt(t,s),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),n=this._getAnchor();at(this._container,e.add(n))},_adjustPan:function(){if(this.options.autoPan)if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning)this._autopanning=!1;else{var t=this._map,e=parseInt(q(this._container,"marginBottom"),10)||0,n=this._container.offsetHeight+e,i=this._containerWidth,o=new y(this._containerLeft,-n-this._containerBottom);o._add(lt(this._container));var s=t.layerPointToContainerPoint(o),r=x(this.options.autoPanPadding),a=x(this.options.autoPanPaddingTopLeft||r),l=x(this.options.autoPanPaddingBottomRight||r),h=t.getSize(),p=0,u=0;s.x+i+l.x>h.x&&(p=s.x+i-h.x+l.x),s.x-p-a.x<0&&(p=s.x-a.x),s.y+n+l.y>h.y&&(u=s.y+n-h.y+l.y),s.y-u-a.y<0&&(u=s.y-a.y),(p||u)&&(this.options.keepInView&&(this._autopanning=!0),t.fire("autopanstart").panBy([p,u]))}},_getAnchor:function(){return x(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),Ni=function(t,e){return new Bi(t,e)};Vn.mergeOptions({closePopupOnClick:!0}),Vn.include({openPopup:function(t,e,n){return this._initOverlay(Bi,t,e,n).openOn(this),this},closePopup:function(t){return(t=arguments.length?t:this._popup)&&t.close(),this}}),fi.include({bindPopup:function(t,e){return this._popup=this._initOverlay(Bi,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 instanceof bi||(this._popup._source=this),this._popup._prepareOpen(t||this._latlng)&&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){Lt(t);var e=t.layer||t.target;this._popup._source!==e||e instanceof Pi?(this._popup._source=e,this.openPopup(t.latlng)):this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(t.latlng)}},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){13===t.originalEvent.keyCode&&this._openPopup(t)}});var Di=Ai.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(t){Ai.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){Ai.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=Ai.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=G("div",t),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+i(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e,n,i=this._map,o=this._container,s=i.latLngToContainerPoint(i.getCenter()),r=i.layerPointToContainerPoint(t),a=this.options.direction,l=o.offsetWidth,h=o.offsetHeight,p=x(this.options.offset),u=this._getAnchor();"top"===a?(e=l/2,n=h):"bottom"===a?(e=l/2,n=0):"center"===a?(e=l/2,n=h/2):"right"===a?(e=0,n=h/2):"left"===a?(e=l,n=h/2):r.x<s.x?(a="right",e=0,n=h/2):(a="left",e=l+2*(p.x+u.x),n=h/2),t=t.subtract(x(e,n,!0)).add(p).add(u),tt(o,"leaflet-tooltip-right"),tt(o,"leaflet-tooltip-left"),tt(o,"leaflet-tooltip-top"),tt(o,"leaflet-tooltip-bottom"),Q(o,"leaflet-tooltip-"+a),at(o,t)},_updatePosition:function(){var t=this._map.latLngToLayerPoint(this._latlng);this._setPosition(t)},setOpacity:function(t){this.options.opacity=t,this._container&&it(this._container,t)},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center);this._setPosition(e)},_getAnchor:function(){return x(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),Fi=function(t,e){return new Di(t,e)};Vn.include({openTooltip:function(t,e,n){return this._initOverlay(Di,t,e,n).openOn(this),this},closeTooltip:function(t){return t.close(),this}}),fi.include({bindTooltip:function(t,e){return this._tooltip&&this.isTooltipOpen()&&this.unbindTooltip(),this._tooltip=this._initOverlay(Di,this._tooltip,t,e),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(t){if(t||!this._tooltipHandlersAdded){var e=t?"off":"on",n={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?n.add=this._openTooltip:(n.mouseover=this._openTooltip,n.mouseout=this.closeTooltip,n.click=this._openTooltip,this._map?this._addFocusListeners():n.add=this._addFocusListeners),this._tooltip.options.sticky&&(n.mousemove=this._moveTooltip),this[e](n),this._tooltipHandlersAdded=!t}},openTooltip:function(t){return this._tooltip&&(this instanceof bi||(this._tooltip._source=this),this._tooltip._prepareOpen(t)&&(this._tooltip.openOn(this._map),this.getElement?this._setAriaDescribedByOnLayer(this):this.eachLayer&&this.eachLayer(this._setAriaDescribedByOnLayer,this))),this},closeTooltip:function(){if(this._tooltip)return this._tooltip.close()},toggleTooltip:function(){return this._tooltip&&this._tooltip.toggle(this),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(t){return this._tooltip&&this._tooltip.setContent(t),this},getTooltip:function(){return this._tooltip},_addFocusListeners:function(){this.getElement?this._addFocusListenersOnLayer(this):this.eachLayer&&this.eachLayer(this._addFocusListenersOnLayer,this)},_addFocusListenersOnLayer:function(t){var e="function"==typeof t.getElement&&t.getElement();e&&(_t(e,"focus",(function(){this._tooltip._source=t,this.openTooltip()}),this),_t(e,"blur",this.closeTooltip,this))},_setAriaDescribedByOnLayer:function(t){var e="function"==typeof t.getElement&&t.getElement();e&&e.setAttribute("aria-describedby",this._tooltip._container.id)},_openTooltip:function(t){if(this._tooltip&&this._map)if(this._map.dragging&&this._map.dragging.moving()&&!this._openOnceFlag){this._openOnceFlag=!0;var e=this;this._map.once("moveend",(function(){e._openOnceFlag=!1,e._openTooltip(t)}))}else this._tooltip._source=t.layer||t.target,this.openTooltip(this._tooltip.options.sticky?t.latlng:void 0)},_moveTooltip:function(t){var e,n,i=t.latlng;this._tooltip.options.sticky&&t.originalEvent&&(e=this._map.mouseEventToContainerPoint(t.originalEvent),n=this._map.containerPointToLayerPoint(e),i=this._map.layerPointToLatLng(n)),this._tooltip.setLatLng(i)}});var Hi=xi.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(t){var e=t&&"DIV"===t.tagName?t:document.createElement("div"),n=this.options;if(n.html instanceof Element?(Y(e),e.appendChild(n.html)):e.innerHTML=!1!==n.html?n.html:"",n.bgPos){var i=x(n.bgPos);e.style.backgroundPosition=-i.x+"px "+-i.y+"px"}return this._setIconStyles(e,"icon"),e},createShadow:function(){return null}});xi.Default=Ii;var Wi=fi.extend({options:{tileSize:256,opacity:1,updateWhenIdle:Pn.mobile,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(t){p(this,t)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView()},beforeAdd:function(t){t._addZoomLimit(this)},onRemove:function(t){this._removeAllTiles(),K(this._container),t._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(J(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(X(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(t){return this.options.opacity=t,this._updateOpacity(),this},setZIndex:function(t){return this.options.zIndex=t,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){if(this._map){this._removeAllTiles();var t=this._clampZoom(this._map.getZoom());t!==this._tileZoom&&(this._tileZoom=t,this._updateLevels()),this._update()}return this},getEvents:function(){var t={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=o(this._onMoveEnd,this.options.updateInterval,this)),t.move=this._onMove),this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},createTile:function(){return document.createElement("div")},getTileSize:function(){var t=this.options.tileSize;return t instanceof y?t:new y(t,t)},_updateZIndex:function(){this._container&&void 0!==this.options.zIndex&&null!==this.options.zIndex&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(t){for(var e,n=this.getPane().children,i=-t(-1/0,1/0),o=0,s=n.length;o<s;o++)e=n[o].style.zIndex,n[o]!==this._container&&e&&(i=t(i,+e));isFinite(i)&&(this.options.zIndex=i+t(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!Pn.ielt9){it(this._container,this.options.opacity);var t=+new Date,e=!1,n=!1;for(var i in this._tiles){var o=this._tiles[i];if(o.current&&o.loaded){var s=Math.min(1,(t-o.loaded)/200);it(o.el,s),s<1?e=!0:(o.active?n=!0:this._onOpaqueTile(o),o.active=!0)}}n&&!this._noPrune&&this._pruneTiles(),e&&(g(this._fadeFrame),this._fadeFrame=f(this._updateOpacity,this))}},_onOpaqueTile:r,_initContainer:function(){this._container||(this._container=G("div","leaflet-layer "+(this.options.className||"")),this._updateZIndex(),this.options.opacity<1&&this._updateOpacity(),this.getPane().appendChild(this._container))},_updateLevels:function(){var t=this._tileZoom,e=this.options.maxZoom;if(void 0!==t){for(var n in this._levels)n=Number(n),this._levels[n].el.children.length||n===t?(this._levels[n].el.style.zIndex=e-Math.abs(t-n),this._onUpdateLevel(n)):(K(this._levels[n].el),this._removeTilesAtZoom(n),this._onRemoveLevel(n),delete this._levels[n]);var i=this._levels[t],o=this._map;return i||((i=this._levels[t]={}).el=G("div","leaflet-tile-container leaflet-zoom-animated",this._container),i.el.style.zIndex=e,i.origin=o.project(o.unproject(o.getPixelOrigin()),t).round(),i.zoom=t,this._setZoomTransform(i,o.getCenter(),o.getZoom()),r(i.el.offsetWidth),this._onCreateLevel(i)),this._level=i,i}},_onUpdateLevel:r,_onRemoveLevel:r,_onCreateLevel:r,_pruneTiles:function(){if(this._map){var t,e,n=this._map.getZoom();if(n>this.options.maxZoom||n<this.options.minZoom)this._removeAllTiles();else{for(t in this._tiles)(e=this._tiles[t]).retain=e.current;for(t in this._tiles)if((e=this._tiles[t]).current&&!e.active){var i=e.coords;this._retainParent(i.x,i.y,i.z,i.z-5)||this._retainChildren(i.x,i.y,i.z,i.z+2)}for(t in this._tiles)this._tiles[t].retain||this._removeTile(t)}}},_removeTilesAtZoom:function(t){for(var e in this._tiles)this._tiles[e].coords.z===t&&this._removeTile(e)},_removeAllTiles:function(){for(var t in this._tiles)this._removeTile(t)},_invalidateAll:function(){for(var t in this._levels)K(this._levels[t].el),this._onRemoveLevel(Number(t)),delete this._levels[t];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(t,e,n,i){var o=Math.floor(t/2),s=Math.floor(e/2),r=n-1,a=new y(+o,+s);a.z=+r;var l=this._tileCoordsToKey(a),h=this._tiles[l];return h&&h.active?(h.retain=!0,!0):(h&&h.loaded&&(h.retain=!0),r>i&&this._retainParent(o,s,r,i))},_retainChildren:function(t,e,n,i){for(var o=2*t;o<2*t+2;o++)for(var s=2*e;s<2*e+2;s++){var r=new y(o,s);r.z=n+1;var a=this._tileCoordsToKey(r),l=this._tiles[a];l&&l.active?l.retain=!0:(l&&l.loaded&&(l.retain=!0),n+1<i&&this._retainChildren(o,s,n+1,i))}},_resetView:function(t){var e=t&&(t.pinch||t.flyTo);this._setView(this._map.getCenter(),this._map.getZoom(),e,e)},_animateZoom:function(t){this._setView(t.center,t.zoom,!0,t.noUpdate)},_clampZoom:function(t){var e=this.options;return void 0!==e.minNativeZoom&&t<e.minNativeZoom?e.minNativeZoom:void 0!==e.maxNativeZoom&&e.maxNativeZoom<t?e.maxNativeZoom:t},_setView:function(t,e,n,i){var o=Math.round(e);o=void 0!==this.options.maxZoom&&o>this.options.maxZoom||void 0!==this.options.minZoom&&o<this.options.minZoom?void 0:this._clampZoom(o);var s=this.options.updateWhenZooming&&o!==this._tileZoom;i&&!s||(this._tileZoom=o,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),void 0!==o&&this._update(t),n||this._pruneTiles(),this._noPrune=!!n),this._setZoomTransforms(t,e)},_setZoomTransforms:function(t,e){for(var n in this._levels)this._setZoomTransform(this._levels[n],t,e)},_setZoomTransform:function(t,e,n){var i=this._map.getZoomScale(n,t.zoom),o=t.origin.multiplyBy(i).subtract(this._map._getNewPixelOrigin(e,n)).round();Pn.any3d?rt(t.el,o,i):at(t.el,o)},_resetGrid:function(){var t=this._map,e=t.options.crs,n=this._tileSize=this.getTileSize(),i=this._tileZoom,o=this._map.getPixelWorldBounds(this._tileZoom);o&&(this._globalTileRange=this._pxBoundsToTileRange(o)),this._wrapX=e.wrapLng&&!this.options.noWrap&&[Math.floor(t.project([0,e.wrapLng[0]],i).x/n.x),Math.ceil(t.project([0,e.wrapLng[1]],i).x/n.y)],this._wrapY=e.wrapLat&&!this.options.noWrap&&[Math.floor(t.project([e.wrapLat[0],0],i).y/n.x),Math.ceil(t.project([e.wrapLat[1],0],i).y/n.y)]},_onMoveEnd:function(){this._map&&!this._map._animatingZoom&&this._update()},_getTiledPixelBounds:function(t){var e=this._map,n=e._animatingZoom?Math.max(e._animateToZoom,e.getZoom()):e.getZoom(),i=e.getZoomScale(n,this._tileZoom),o=e.project(t,this._tileZoom).floor(),s=e.getSize().divideBy(2*i);return new I(o.subtract(s),o.add(s))},_update:function(t){var e=this._map;if(e){var n=this._clampZoom(e.getZoom());if(void 0===t&&(t=e.getCenter()),void 0!==this._tileZoom){var i=this._getTiledPixelBounds(t),o=this._pxBoundsToTileRange(i),s=o.getCenter(),r=[],a=this.options.keepBuffer,l=new I(o.getBottomLeft().subtract([a,-a]),o.getTopRight().add([a,-a]));if(!(isFinite(o.min.x)&&isFinite(o.min.y)&&isFinite(o.max.x)&&isFinite(o.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var h in this._tiles){var p=this._tiles[h].coords;p.z===this._tileZoom&&l.contains(new y(p.x,p.y))||(this._tiles[h].current=!1)}if(Math.abs(n-this._tileZoom)>1)this._setView(t,n);else{for(var u=o.min.y;u<=o.max.y;u++)for(var c=o.min.x;c<=o.max.x;c++){var d=new y(c,u);if(d.z=this._tileZoom,this._isValidTile(d)){var m=this._tiles[this._tileCoordsToKey(d)];m?m.current=!0:r.push(d)}}if(r.sort((function(t,e){return t.distanceTo(s)-e.distanceTo(s)})),0!==r.length){this._loading||(this._loading=!0,this.fire("loading"));var _=document.createDocumentFragment();for(c=0;c<r.length;c++)this._addTile(r[c],_);this._level.el.appendChild(_)}}}}},_isValidTile:function(t){var e=this._map.options.crs;if(!e.infinite){var n=this._globalTileRange;if(!e.wrapLng&&(t.x<n.min.x||t.x>n.max.x)||!e.wrapLat&&(t.y<n.min.y||t.y>n.max.y))return!1}if(!this.options.bounds)return!0;var i=this._tileCoordsToBounds(t);return T(this.options.bounds).overlaps(i)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var e=this._map,n=this.getTileSize(),i=t.scaleBy(n),o=i.add(n);return[e.unproject(i,t.z),e.unproject(o,t.z)]},_tileCoordsToBounds:function(t){var e=this._tileCoordsToNwSe(t),n=new P(e[0],e[1]);return this.options.noWrap||(n=this._map.wrapLatLngBounds(n)),n},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var e=t.split(":"),n=new y(+e[0],+e[1]);return n.z=+e[2],n},_removeTile:function(t){var e=this._tiles[t];e&&(K(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){Q(t,"leaflet-tile");var e=this.getTileSize();t.style.width=e.x+"px",t.style.height=e.y+"px",t.onselectstart=r,t.onmousemove=r,Pn.ielt9&&this.options.opacity<1&&it(t,this.options.opacity)},_addTile:function(t,e){var i=this._getTilePos(t),o=this._tileCoordsToKey(t),s=this.createTile(this._wrapCoords(t),n(this._tileReady,this,t));this._initTile(s),this.createTile.length<2&&f(n(this._tileReady,this,t,null,s)),at(s,i),this._tiles[o]={el:s,coords:t,current:!0},e.appendChild(s),this.fire("tileloadstart",{tile:s,coords:t})},_tileReady:function(t,e,i){e&&this.fire("tileerror",{error:e,tile:i,coords:t});var o=this._tileCoordsToKey(t);(i=this._tiles[o])&&(i.loaded=+new Date,this._map._fadeAnimated?(it(i.el,0),g(this._fadeFrame),this._fadeFrame=f(this._updateOpacity,this)):(i.active=!0,this._pruneTiles()),e||(Q(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),Pn.ielt9||!this._map._fadeAnimated?f(this._pruneTiles,this):setTimeout(n(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new y(this._wrapX?s(t.x,this._wrapX):t.x,this._wrapY?s(t.y,this._wrapY):t.y);return e.z=t.z,e},_pxBoundsToTileRange:function(t){var e=this.getTileSize();return new I(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}}),Ui=Wi.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=p(this,e)).detectRetina&&Pn.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 _t(i,"load",n(this._tileOnLoad,this,e,i)),_t(i,"error",n(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 n={r:Pn.retina?"@2x":"",s:this._getSubdomain(t),x:t.x,y:t.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var i=this._globalTileRange.max.y-t.y;this.options.tms&&(n.y=i),n["-y"]=i}return c(this._url,e(n,this.options))},_tileOnLoad:function(t,e){Pn.ielt9?setTimeout(n(t,this,null,e),0):t(null,e)},_tileOnError:function(t,e,n){var i=this.options.errorTileUrl;i&&e.getAttribute("src")!==i&&(e.src=i),t(n,e)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,e=this.options.maxZoom;return this.options.zoomReverse&&(t=e-t),t+this.options.zoomOffset},_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=r,e.onerror=r,!e.complete)){e.src=Ie;var n=this._tiles[t].coords;K(e),delete this._tiles[t],this.fire("tileabort",{tile:e,coords:n})}},_removeTile:function(t){var e=this._tiles[t];if(e)return e.el.setAttribute("src",Ie),Wi.prototype._removeTile.call(this,t)},_tileReady:function(t,e,n){if(this._map&&(!n||n.getAttribute("src")!==Ie))return Wi.prototype._tileReady.call(this,t,e,n)}}),Vi=Ui.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,n){this._url=t;var i=e({},this.defaultWmsParams);for(var o in n)o in this.options||(i[o]=n[o]);var s=(n=p(this,n)).detectRetina&&Pn.retina?2:1,r=this.getTileSize();i.width=r.x*s,i.height=r.y*s,this.wmsParams=i},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,Ui.prototype.onAdd.call(this,t)},getTileUrl:function(t){var e=this._tileCoordsToNwSe(t),n=this._crs,i=w(n.project(e[0]),n.project(e[1])),o=i.min,s=i.max,r=(this._wmsVersion>=1.3&&this._crs===mi?[o.y,o.x,s.y,s.x]:[o.x,o.y,s.x,s.y]).join(","),a=Ui.prototype.getTileUrl.call(this,t);return a+u(this.wmsParams,a,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+r},setParams:function(t,n){return e(this.wmsParams,t),n||this.redraw(),this}});Ui.WMS=Vi,ce.wms=de;var qi=fi.extend({options:{padding:.1},initialize:function(t){p(this,t),i(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),Q(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 n=this._map.getZoomScale(e,this._zoom),i=this._map.getSize().multiplyBy(.5+this.options.padding),o=this._map.project(this._center,e),s=i.multiplyBy(-n).add(o).subtract(this._map._getNewPixelOrigin(t,e));Pn.any3d?rt(this._container,s,n):at(this._container,s)},_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(),n=this._map.containerPointToLayerPoint(e.multiplyBy(-t)).round();this._bounds=new I(n,n.add(e.multiplyBy(1+2*t)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),Gi=qi.extend({options:{tolerance:0},getEvents:function(){var t=qi.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){qi.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");_t(t,"mousemove",this._onMouseMove,this),_t(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),_t(t,"mouseout",this._handleMouseOut,this),t._leaflet_disable_events=!0,this._ctx=t.getContext("2d")},_destroyContainer:function(){g(this._redrawRequest),delete this._ctx,K(this._container),ft(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){qi.prototype._update.call(this);var t=this._bounds,e=this._container,n=t.getSize(),i=Pn.retina?2:1;at(e,t.min),e.width=i*n.x,e.height=i*n.y,e.style.width=n.x+"px",e.style.height=n.y+"px",Pn.retina&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){qi.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[i(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,n=e.next,o=e.prev;n?n.prev=o:this._drawLast=o,o?o.next=n:this._drawFirst=n,delete t._order,delete this._layers[i(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,n,i=t.options.dashArray.split(/[, ]+/),o=[];for(n=0;n<i.length;n++){if(e=Number(i[n]),isNaN(e))return;o.push(e)}t.options._dashArray=o}else t.options._dashArray=t.options.dashArray},_requestRedraw:function(t){this._map&&(this._extendRedrawBounds(t),this._redrawRequest=this._redrawRequest||f(this._redraw,this))},_extendRedrawBounds:function(t){if(t._pxBounds){var e=(t.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new I,this._redrawBounds.extend(t._pxBounds.min.subtract([e,e])),this._redrawBounds.extend(t._pxBounds.max.add([e,e]))}},_redraw:function(){this._redrawRequest=null,this._redrawBounds&&(this._redrawBounds.min._floor(),this._redrawBounds.max._ceil()),this._clear(),this._draw(),this._redrawBounds=null},_clear:function(){var t=this._redrawBounds;if(t){var e=t.getSize();this._ctx.clearRect(t.min.x,t.min.y,e.x,e.y)}else this._ctx.save(),this._ctx.setTransform(1,0,0,1,0,0),this._ctx.clearRect(0,0,this._container.width,this._container.height),this._ctx.restore()},_draw:function(){var t,e=this._redrawBounds;if(this._ctx.save(),e){var n=e.getSize();this._ctx.beginPath(),this._ctx.rect(e.min.x,e.min.y,n.x,n.y),this._ctx.clip()}this._drawing=!0;for(var i=this._drawFirst;i;i=i.next)t=i.layer,(!e||t._pxBounds&&t._pxBounds.intersects(e))&&t._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(t,e){if(this._drawing){var n,i,o,s,r=t._parts,a=r.length,l=this._ctx;if(a){for(l.beginPath(),n=0;n<a;n++){for(i=0,o=r[n].length;i<o;i++)s=r[n][i],l[i?"lineTo":"moveTo"](s.x,s.y);e&&l.closePath()}this._fillStroke(l,t)}}},_updateCircle:function(t){if(this._drawing&&!t._empty()){var e=t._point,n=this._ctx,i=Math.max(Math.round(t._radius),1),o=(Math.max(Math.round(t._radiusY),1)||i)/i;1!==o&&(n.save(),n.scale(1,o)),n.beginPath(),n.arc(e.x,e.y/o,i,0,2*Math.PI,!1),1!==o&&n.restore(),this._fillStroke(n,t)}},_fillStroke:function(t,e){var n=e.options;n.fill&&(t.globalAlpha=n.fillOpacity,t.fillStyle=n.fillColor||n.color,t.fill(n.fillRule||"evenodd")),n.stroke&&0!==n.weight&&(t.setLineDash&&t.setLineDash(e.options&&e.options._dashArray||[]),t.globalAlpha=n.opacity,t.lineWidth=n.weight,t.strokeStyle=n.color,t.lineCap=n.lineCap,t.lineJoin=n.lineJoin,t.stroke())},_onClick:function(t){for(var e,n,i=this._map.mouseEventToLayerPoint(t),o=this._drawFirst;o;o=o.next)(e=o.layer).options.interactive&&e._containsPoint(i)&&("click"!==t.type&&"preclick"!==t.type||!this._map._draggableMoved(e))&&(n=e);this._fireEvent(!!n&&[n],t)},_onMouseMove:function(t){if(this._map&&!this._map.dragging.moving()&&!this._map._animatingZoom){var e=this._map.mouseEventToLayerPoint(t);this._handleMouseHover(t,e)}},_handleMouseOut:function(t){var e=this._hoveredLayer;e&&(tt(this._container,"leaflet-interactive"),this._fireEvent([e],t,"mouseout"),this._hoveredLayer=null,this._mouseHoverThrottled=!1)},_handleMouseHover:function(t,e){if(!this._mouseHoverThrottled){for(var i,o,s=this._drawFirst;s;s=s.next)(i=s.layer).options.interactive&&i._containsPoint(e)&&(o=i);o!==this._hoveredLayer&&(this._handleMouseOut(t),o&&(Q(this._container,"leaflet-interactive"),this._fireEvent([o],t,"mouseover"),this._hoveredLayer=o)),this._fireEvent(!!this._hoveredLayer&&[this._hoveredLayer],t),this._mouseHoverThrottled=!0,setTimeout(n((function(){this._mouseHoverThrottled=!1}),this),32)}},_fireEvent:function(t,e,n){this._map._fireDOMEvent(e,n||e.type,t)},_bringToFront:function(t){var e=t._order;if(e){var n=e.next,i=e.prev;n&&(n.prev=i,i?i.next=n:n&&(this._drawFirst=n),e.prev=this._drawLast,this._drawLast.next=e,e.next=null,this._drawLast=e,this._requestRedraw(t))}},_bringToBack:function(t){var e=t._order;if(e){var n=e.next,i=e.prev;i&&(i.next=n,n?n.prev=i:i&&(this._drawLast=i),e.prev=null,e.next=this._drawFirst,this._drawFirst.prev=e,this._drawFirst=e,this._requestRedraw(t))}}}),Ki=function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("<lvml:"+t+' class="lvml">')}}catch(t){}return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),Yi={_initContainer:function(){this._container=G("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(qi.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var e=t._container=Ki("shape");Q(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=Ki("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[i(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;K(e),t.removeInteractiveTarget(e),delete this._layers[i(t)]},_updateStyle:function(t){var e=t._stroke,n=t._fill,i=t.options,o=t._container;o.stroked=!!i.stroke,o.filled=!!i.fill,i.stroke?(e||(e=t._stroke=Ki("stroke")),o.appendChild(e),e.weight=i.weight+"px",e.color=i.color,e.opacity=i.opacity,i.dashArray?e.dashStyle=xe(i.dashArray)?i.dashArray.join(" "):i.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=i.lineCap.replace("butt","flat"),e.joinstyle=i.lineJoin):e&&(o.removeChild(e),t._stroke=null),i.fill?(n||(n=t._fill=Ki("fill")),o.appendChild(n),n.color=i.fillColor||i.color,n.opacity=i.fillOpacity):n&&(o.removeChild(n),t._fill=null)},_updateCircle:function(t){var e=t._point.round(),n=Math.round(t._radius),i=Math.round(t._radiusY||n);this._setPath(t,t._empty()?"M0 0":"AL "+e.x+","+e.y+" "+n+","+i+" 0,23592600")},_setPath:function(t,e){t._path.v=e},_bringToFront:function(t){J(t._container)},_bringToBack:function(t){X(t._container)}},Ji=Pn.vml?Ki:j,Xi=qi.extend({_initContainer:function(){this._container=Ji("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Ji("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){K(this._container),ft(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!this._map._animatingZoom||!this._bounds){qi.prototype._update.call(this);var t=this._bounds,e=t.getSize(),n=this._container;this._svgSize&&this._svgSize.equals(e)||(this._svgSize=e,n.setAttribute("width",e.x),n.setAttribute("height",e.y)),at(n,t.min),n.setAttribute("viewBox",[t.min.x,t.min.y,e.x,e.y].join(" ")),this.fire("update")}},_initPath:function(t){var e=t._path=Ji("path");t.options.className&&Q(e,t.options.className),t.options.interactive&&Q(e,"leaflet-interactive"),this._updateStyle(t),this._layers[i(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){K(t._path),t.removeInteractiveTarget(t._path),delete this._layers[i(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var e=t._path,n=t.options;e&&(n.stroke?(e.setAttribute("stroke",n.color),e.setAttribute("stroke-opacity",n.opacity),e.setAttribute("stroke-width",n.weight),e.setAttribute("stroke-linecap",n.lineCap),e.setAttribute("stroke-linejoin",n.lineJoin),n.dashArray?e.setAttribute("stroke-dasharray",n.dashArray):e.removeAttribute("stroke-dasharray"),n.dashOffset?e.setAttribute("stroke-dashoffset",n.dashOffset):e.removeAttribute("stroke-dashoffset")):e.setAttribute("stroke","none"),n.fill?(e.setAttribute("fill",n.fillColor||n.color),e.setAttribute("fill-opacity",n.fillOpacity),e.setAttribute("fill-rule",n.fillRule||"evenodd")):e.setAttribute("fill","none"))},_updatePoly:function(t,e){this._setPath(t,C(t._parts,e))},_updateCircle:function(t){var e=t._point,n=Math.max(Math.round(t._radius),1),i="a"+n+","+(Math.max(Math.round(t._radiusY),1)||n)+" 0 1,0 ",o=t._empty()?"M0 0":"M"+(e.x-n)+","+e.y+i+2*n+",0 "+i+2*-n+",0 ";this._setPath(t,o)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){J(t._path)},_bringToBack:function(t){X(t._path)}});Pn.vml&&Xi.include(Yi),Vn.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&&me(t)||_e(t)}});var $i=ki.extend({initialize:function(t,e){ki.prototype.initialize.call(this,this._boundsToLatLngs(t),e)},setBounds:function(t){return this.setLatLngs(this._boundsToLatLngs(t))},_boundsToLatLngs:function(t){return[(t=T(t)).getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});Xi.create=Ji,Xi.pointsToPath=C,Si.geometryToLayer=Qt,Si.coordsToLatLng=ee,Si.coordsToLatLngs=ne,Si.latLngToCoords=ie,Si.latLngsToCoords=oe,Si.getFeature=se,Si.asFeature=re,Vn.mergeOptions({boxZoom:!0});var Qi=ii.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(){_t(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){ft(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){K(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(),Ze(),
|
|
ht(),this._startPoint=this._map.mouseEventToContainerPoint(t),_t(document,{contextmenu:Lt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=G("div","leaflet-zoom-box",this._container),Q(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var e=new I(this._point,this._startPoint),n=e.getSize();at(this._box,e.min),this._box.style.width=n.x+"px",this._box.style.height=n.y+"px"},_finish:function(){this._moved&&(K(this._box),tt(this._container,"leaflet-crosshair")),Ae(),pt(),ft(document,{contextmenu:Lt,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(n(this._resetState,this),0);var e=new P(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())}});Vn.addInitHook("addHandler","boxZoom",Qi),Vn.mergeOptions({doubleClickZoom:!0});var to=ii.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,n=e.getZoom(),i=e.options.zoomDelta,o=t.originalEvent.shiftKey?n-i:n+i;"center"===e.options.doubleClickZoom?e.setZoom(o):e.setZoomAround(t.containerPoint,o)}});Vn.addInitHook("addHandler","doubleClickZoom",to),Vn.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var eo=ii.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new ai(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))}Q(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){tt(this._map._container,"leaflet-grab"),tt(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=T(this._map.options.maxBounds);this._offsetLimit=w(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,n=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(n),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.x<e.min.x&&(t.x=this._viscousLimit(t.x,e.min.x)),t.y<e.min.y&&(t.y=this._viscousLimit(t.y,e.min.y)),t.x>e.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),n=this._initialWorldOffset,i=this._draggable._newPos.x,o=(i-e+n)%t+e-n,s=(i+e+n)%t-e-n,r=Math.abs(o+n)<Math.abs(s+n)?o:s;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=r},_onDragEnd:function(t){var e=this._map,n=e.options,i=!n.inertia||t.noInertia||this._times.length<2;if(e.fire("dragend",t),i)e.fire("moveend");else{this._prunePositions(+new Date);var o=this._lastPos.subtract(this._positions[0]),s=(this._lastTime-this._times[0])/1e3,r=n.easeLinearity,a=o.multiplyBy(r/s),l=a.distanceTo([0,0]),h=Math.min(n.inertiaMaxSpeed,l),p=a.multiplyBy(h/l),u=h/(n.inertiaDeceleration*r),c=p.multiplyBy(-u/2).round();c.x||c.y?(c=e._limitOffset(c,e.options.maxBounds),f((function(){e.panBy(c,{duration:u,easeLinearity:r,noMoveStart:!0,animate:!0})}))):e.fire("moveend")}}});Vn.addInitHook("addHandler","dragging",eo),Vn.mergeOptions({keyboard:!0,keyboardPanDelta:80});var no=ii.extend({keyCodes:{left:[37],right:[39],down:[40],up:[38],zoomIn:[187,107,61,171],zoomOut:[189,109,54,173]},initialize:function(t){this._map=t,this._setPanDelta(t.options.keyboardPanDelta),this._setZoomDelta(t.options.zoomDelta)},addHooks:function(){var t=this._map._container;t.tabIndex<=0&&(t.tabIndex="0"),_t(t,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.on({focus:this._addHooks,blur:this._removeHooks},this)},removeHooks:function(){this._removeHooks(),ft(this._map._container,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.off({focus:this._addHooks,blur:this._removeHooks},this)},_onMouseDown:function(){if(!this._focused){var t=document.body,e=document.documentElement,n=t.scrollTop||e.scrollTop,i=t.scrollLeft||e.scrollLeft;this._map._container.focus(),window.scrollTo(i,n)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(t){var e,n,i=this._panKeys={},o=this.keyCodes;for(e=0,n=o.left.length;e<n;e++)i[o.left[e]]=[-1*t,0];for(e=0,n=o.right.length;e<n;e++)i[o.right[e]]=[t,0];for(e=0,n=o.down.length;e<n;e++)i[o.down[e]]=[0,t];for(e=0,n=o.up.length;e<n;e++)i[o.up[e]]=[0,-1*t]},_setZoomDelta:function(t){var e,n,i=this._zoomKeys={},o=this.keyCodes;for(e=0,n=o.zoomIn.length;e<n;e++)i[o.zoomIn[e]]=t;for(e=0,n=o.zoomOut.length;e<n;e++)i[o.zoomOut[e]]=-t},_addHooks:function(){_t(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){ft(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(t){if(!(t.altKey||t.ctrlKey||t.metaKey)){var e,n=t.keyCode,i=this._map;if(n in this._panKeys){if(!i._panAnim||!i._panAnim._inProgress)if(e=this._panKeys[n],t.shiftKey&&(e=x(e).multiplyBy(3)),i.options.maxBounds&&(e=i._limitOffset(x(e),i.options.maxBounds)),i.options.worldCopyJump){var o=i.wrapLatLng(i.unproject(i.project(i.getCenter()).add(e)));i.panTo(o)}else i.panBy(e)}else if(n in this._zoomKeys)i.setZoom(i.getZoom()+(t.shiftKey?3:1)*this._zoomKeys[n]);else{if(27!==n||!i._popup||!i._popup.options.closeOnEscapeKey)return;i.closePopup()}Lt(t)}}});Vn.addInitHook("addHandler","keyboard",no),Vn.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var io=ii.extend({addHooks:function(){_t(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){ft(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(t){var e=Mt(t),i=this._map.options.wheelDebounceTime;this._delta+=e,this._lastMousePos=this._map.mouseEventToContainerPoint(t),this._startTime||(this._startTime=+new Date);var o=Math.max(i-(+new Date-this._startTime),0);clearTimeout(this._timer),this._timer=setTimeout(n(this._performZoom,this),o),Lt(t)},_performZoom:function(){var t=this._map,e=t.getZoom(),n=this._map.options.zoomSnap||0;t._stop();var i=this._delta/(4*this._map.options.wheelPxPerZoomLevel),o=4*Math.log(2/(1+Math.exp(-Math.abs(i))))/Math.LN2,s=n?Math.ceil(o/n)*n:o,r=t._limitZoom(e+(this._delta>0?s:-s))-e;this._delta=0,this._startTime=null,r&&("center"===t.options.scrollWheelZoom?t.setZoom(e+r):t.setZoomAround(this._lastMousePos,e+r))}});Vn.addInitHook("addHandler","scrollWheelZoom",io);var oo=600;Vn.mergeOptions({tapHold:Pn.touchNative&&Pn.safari&&Pn.mobile,tapTolerance:15});var so=ii.extend({addHooks:function(){_t(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){ft(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 y(e.clientX,e.clientY),this._holdTimeout=setTimeout(n((function(){this._cancel(),this._isTapValid()&&(_t(document,"touchend",wt),_t(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",e))}),this),oo),_t(document,"touchend touchcancel contextmenu",this._cancel,this),_t(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function t(){ft(document,"touchend",wt),ft(document,"touchend touchcancel",t)},_cancel:function(){clearTimeout(this._holdTimeout),ft(document,"touchend touchcancel contextmenu",this._cancel,this),ft(document,"touchmove",this._onMove,this)},_onMove:function(t){var e=t.touches[0];this._newPos=new y(e.clientX,e.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(t,e){var n=new MouseEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:e.screenX,screenY:e.screenY,clientX:e.clientX,clientY:e.clientY});n._simulated=!0,e.target.dispatchEvent(n)}});Vn.addInitHook("addHandler","tapHold",so),Vn.mergeOptions({touchZoom:Pn.touch,bounceAtZoomLimits:!0});var ro=ii.extend({addHooks:function(){Q(this._map._container,"leaflet-touch-zoom"),_t(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){tt(this._map._container,"leaflet-touch-zoom"),ft(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 n=e.mouseEventToContainerPoint(t.touches[0]),i=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(n.add(i)._divideBy(2))),this._startDist=n.distanceTo(i),this._startZoom=e.getZoom(),this._moved=!1,this._zooming=!0,e._stop(),_t(document,"touchmove",this._onTouchMove,this),_t(document,"touchend touchcancel",this._onTouchEnd,this),wt(t)}},_onTouchMove:function(t){if(t.touches&&2===t.touches.length&&this._zooming){var e=this._map,i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]),s=i.distanceTo(o)/this._startDist;if(this._zoom=e.getScaleZoom(s,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoom<e.getMinZoom()&&s<1||this._zoom>e.getMaxZoom()&&s>1)&&(this._zoom=e._limitZoom(this._zoom)),"center"===e.options.touchZoom){if(this._center=this._startLatLng,1===s)return}else{var r=i._add(o)._divideBy(2)._subtract(this._centerPoint);if(1===s&&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),g(this._animRequest);var a=n(e._move,e,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=f(a,this,!0),wt(t)}},_onTouchEnd:function(){this._moved&&this._zooming?(this._zooming=!1,g(this._animRequest),ft(document,"touchmove",this._onTouchMove,this),ft(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))):this._zooming=!1}});Vn.addInitHook("addHandler","touchZoom",ro),Vn.BoxZoom=Qi,Vn.DoubleClickZoom=to,Vn.Drag=eo,Vn.Keyboard=no,Vn.ScrollWheelZoom=io,Vn.TapHold=so,Vn.TouchZoom=ro,t.Bounds=I,t.Browser=Pn,t.CRS=je,t.Canvas=Gi,t.Circle=Mi,t.CircleMarker=Ti,t.Class=v,t.Control=qn,t.DivIcon=Hi,t.DivOverlay=Ai,t.DomEvent=Wn,t.DomUtil=Nn,t.Draggable=ai,t.Evented=ze,t.FeatureGroup=bi,t.GeoJSON=Si,t.GridLayer=Wi,t.Handler=ii,t.Icon=xi,t.ImageOverlay=Ri,t.LatLng=M,t.LatLngBounds=P,t.Layer=fi,t.LayerGroup=gi,t.LineUtil=hi,t.Map=Vn,t.Marker=Li,t.Mixin=si,t.Path=Pi,t.Point=y,t.PolyUtil=li,t.Polygon=ki,t.Polyline=zi,t.Popup=Bi,t.PosAnimation=Un,t.Projection=ci,t.Rectangle=$i,t.Renderer=qi,t.SVG=Xi,t.SVGOverlay=Zi,t.TileLayer=Ui,t.Tooltip=Di,t.Transformation=k,t.Util=Te,t.VideoOverlay=Ei,t.bind=n,t.bounds=w,t.canvas=me,t.circle=Jt,t.circleMarker=Yt,t.control=Gn,t.divIcon=pe,t.extend=e,t.featureGroup=yi,t.geoJSON=ae,t.geoJson=Ci,t.gridLayer=ue,t.icon=Gt,t.imageOverlay=Oi,t.latLng=z,t.latLngBounds=T,t.layerGroup=vi,t.map=kt,t.marker=Kt,t.point=x,t.polygon=$t,t.polyline=Xt,t.popup=Ni,t.rectangle=fe,t.setOptions=p,t.stamp=i,t.svg=_e,t.svgOverlay=he,t.tileLayer=ce,t.tooltip=Fi,t.transformation=S,t.version=ge,t.videoOverlay=le;var ao=window.L;t.noConflict=function(){return window.L=ao,this},window.L=t})),L.OSM={},L.OSM.TileLayer=L.TileLayer.extend({options:{url:"https://tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors'},initialize:function(t){t=L.Util.setOptions(this,t),L.TileLayer.prototype.initialize.call(this,t.url)}}),L.OSM.Mapnik=L.OSM.TileLayer.extend({options:{url:"https://tile.openstreetmap.org/{z}/{x}/{y}.png",maxZoom:19}}),L.OSM.CyclOSM=L.OSM.TileLayer.extend({options:{url:"https://{s}.tile-cyclosm.openstreetmap.fr/cyclosm/{z}/{x}/{y}.png",maxZoom:20,subdomains:"abc",attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="https://www.openstreetmap.fr" target="_blank">OpenStreetMap France</a>'}}),L.OSM.CycleMap=L.OSM.TileLayer.extend({options:{url:"https://{s}.tile.thunderforest.com/cycle/{z}/{x}/{y}{r}.png?apikey={apikey}",maxZoom:21,attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="http://www.thunderforest.com/" target="_blank">Andy Allan</a>'}}),L.OSM.TransportMap=L.OSM.TileLayer.extend({options:{url:"https://{s}.tile.thunderforest.com/transport/{z}/{x}/{y}{r}.png?apikey={apikey}",maxZoom:21,attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="http://www.thunderforest.com/" target="_blank">Andy Allan</a>'}}),L.OSM.OPNVKarte=L.OSM.TileLayer.extend({options:{url:"https://tileserver.memomaps.de/tilegen/{z}/{x}/{y}.png",maxZoom:18,attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="http://memomaps.de/" target="_blank">MeMoMaps</a>'}}),L.OSM.HOT=L.OSM.TileLayer.extend({options:{url:"https://tile-{s}.openstreetmap.fr/hot/{z}/{x}/{y}.png",maxZoom:20,subdomains:"abc",attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="http://hot.openstreetmap.org/" target="_blank">Humanitarian OpenStreetMap Team</a>'}}),L.OSM.TracestrackTopo=L.OSM.TileLayer.extend({options:{url:"https://tile.tracestrack.com/topo__/{z}/{x}/{y}.png?key={apikey}",maxZoom:19,attribution:'\xa9 <a href="https://www.openstreetmap.org/copyright" target="_blank">OpenStreetMap</a> contributors. Tiles courtesy of <a href="https://www.tracestrack.com/" target="_blank">Tracestrack Maps</a>'}}),L.OSM.GPS=L.OSM.TileLayer.extend({options:{url:"https://gps.tile.openstreetmap.org/lines/{z}/{x}/{y}.png",maxZoom:21,maxNativeZoom:20,subdomains:"abc"}}),L.OSM.DataLayer=L.FeatureGroup.extend({options:{areaTags:["area","building","leisure","tourism","ruins","historic","landuse","military","natural","sport"],uninterestingTags:["source","source_ref","source:ref","history","attribution","created_by","tiger:county","tiger:tlid","tiger:upload_uuid"],styles:{}},initialize:function(t,e){L.Util.setOptions(this,e),L.FeatureGroup.prototype.initialize.call(this),t&&this.addData(t)},addData:function(t){t instanceof Array||(t=this.buildFeatures(t));for(var e=0;e<t.length;e++){var n,i=t[e];if("changeset"===i.type)n=L.rectangle(i.latLngBounds,this.options.styles.changeset);else if("node"===i.type)n=L.circleMarker(i.latLng,this.options.styles.node);else{for(var o=new Array(i.nodes.length),s=0;s<i.nodes.length;s++)o[s]=i.nodes[s].latLng;this.isWayArea(i)?(o.pop(),n=L.polygon(o,this.options.styles.area)):n=L.polyline(o,this.options.styles.way)}n.addTo(this),n.feature=i}},buildFeatures:function(t){var e=L.OSM.getChangesets(t),n=L.OSM.getNodes(t),i=L.OSM.getWays(t,n),o=L.OSM.getRelations(t,n,i);for(var s in n){var r=n[s];this.interestingNode(r,i,o)&&e.push(r)}for(var a=0;a<i.length;a++){var l=i[a];e.push(l)}return e},isWayArea:function(t){if(t.nodes[0]!=t.nodes[t.nodes.length-1])return!1;for(var e in t.tags)if(~this.options.areaTags.indexOf(e))return!0;return!1},interestingNode:function(t,e,n){for(var i=!1,o=0;o<e.length;o++)if(e[o].nodes.indexOf(t)>=0){i=!0;break}if(!i)return!0;for(o=0;o<n.length;o++)if(n[o].members.indexOf(t)>=0)return!0;for(var s in t.tags)if(this.options.uninterestingTags.indexOf(s)<0)return!0;return!1}}),L.Util.extend(L.OSM,{getChangesets:function(t){for(var e=[],n=t.getElementsByTagName("changeset"),i=0;i<n.length;i++){var o=n[i],s=o.getAttribute("id");e.push({id:s,type:"changeset",latLngBounds:L.latLngBounds([o.getAttribute("min_lat"),o.getAttribute("min_lon")],[o.getAttribute("max_lat"),o.getAttribute("max_lon")]),tags:this.getTags(o)})}return e},getNodes:function(t){for(var e={},n=t.getElementsByTagName("node"),i=0;i<n.length;i++){var o=n[i],s=o.getAttribute("id");e[s]={id:s,type:"node",latLng:L.latLng(o.getAttribute("lat"),o.getAttribute("lon"),!0),tags:this.getTags(o)}}return e},getWays:function(t,e){for(var n=[],i=t.getElementsByTagName("way"),o=0;o<i.length;o++){for(var s=i[o],r=s.getElementsByTagName("nd"),a={id:s.getAttribute("id"),type:"way",nodes:new Array(r.length),tags:this.getTags(s)},l=0;l<r.length;l++)a.nodes[l]=e[r[l].getAttribute("ref")];n.push(a)}return n},getRelations:function(t,e){for(var n=[],i=t.getElementsByTagName("relation"),o=0;o<i.length;o++){for(var s=i[o],r=s.getElementsByTagName("member"),a={id:s.getAttribute("id"),type:"relation",members:new Array(r.length),tags:this.getTags(s)},l=0;l<r.length;l++)"node"===r[l].getAttribute("type")?a.members[l]=e[r[l].getAttribute("ref")]:a.members[l]=null;n.push(a)}return n},getTags:function(t){for(var e={},n=t.getElementsByTagName("tag"),i=0;i<n.length;i++)e[n[i].getAttribute("k")]=n[i].getAttribute("v");return e}}),function(t,e){"function"==typeof define&&define.amd?define("i18n",(function(){return e(t)})):"object"==typeof module&&module.exports?module.exports=e(t):t.I18n=e(t)}(this,(function(t){"use strict";var e=t&&t.I18n||{},n=Array.prototype.slice,i=function(t){return("0"+t.toString()).substr(-2)},o=function(t,e){return d("round",t,-e).toFixed(e)},s=function(t){var e=typeof t;return"function"===e||"object"===e},r=function(t){return"function"===typeof t},a=function(t){return null!=t},l=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===Object.prototype.toString.call(t)},h=function(t){return"string"==typeof t||"[object String]"===Object.prototype.toString.call(t)},p=function(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)},u=function(t){return!0===t||!1===t},c=function(t){return null===t},d=function(t,e,n){return void 0===n||0==+n?Math[t](e):(e=+e,n=+n,isNaN(e)||"number"!=typeof n||n%1!=0?NaN:(e=e.toString().split("e"),+((e=(e=Math[t](+(e[0]+"e"+(e[1]?+e[1]-n:-n)))).toString().split("e"))[0]+"e"+(e[1]?+e[1]+n:n))))},m=function(t,e){return r(t)?t(e):t},_=function(t,e){var n,i;for(n in e)e.hasOwnProperty(n)&&(i=e[n],h(i)||p(i)||u(i)||l(i)||c(i)?t[n]=i:(null==t[n]&&(t[n]={}),_(t[n],i)));return t},f={day_names:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],abbr_day_names:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],month_names:[null,"January","February","March","April","May","June","July","August","September","October","November","December"],abbr_month_names:[null,"Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],meridian:["AM","PM"]},g={precision:3,separator:".",delimiter:",",strip_insignificant_zeros:!1},v={unit:"$",precision:2,format:"%u%n",sign_first:!0,delimiter:",",separator:"."},b={unit:"%",precision:3,format:"%n%u",separator:".",delimiter:""},y=[null,"kb","mb","gb","tb"],x={defaultLocale:"en",locale:"en",defaultSeparator:".",placeholder:/(?:\{\{|%\{)(.*?)(?:\}\}?)/gm,fallbacks:!1,translations:{},missingBehaviour:"message",missingTranslationPrefix:""};return e.reset=function(){var t;for(t in x)this[t]=x[t]},e.initializeOptions=function(){var t;for(t in x)a(this[t])||(this[t]=x[t])},e.initializeOptions(),e.locales={},e.locales.get=function(t){var n=this[t]||this[e.locale]||this.default;return r(n)&&(n=n(t)),!1===l(n)&&(n=[n]),n},e.locales.default=function(t){var n=[],i=[];return t&&n.push(t),!t&&e.locale&&n.push(e.locale),e.fallbacks&&e.defaultLocale&&n.push(e.defaultLocale),n.forEach((function(t){var n=t.split("-"),o=null,s=null;3===n.length?(o=[n[0],n[1]].join("-"),s=n[0]):2===n.length&&(o=n[0]),-1===i.indexOf(t)&&i.push(t),e.fallbacks&&[o,s].forEach((function(e){null!=e&&e!==t&&-1===i.indexOf(e)&&i.push(e)}))})),n.length||n.push("en"),i},e.pluralization={},e.pluralization.get=function(t){return this[t]||this[e.locale]||this.default},e.pluralization.default=function(t){switch(t){case 0:return["zero","other"];case 1:return["one"];default:return["other"]}},e.currentLocale=function(){return this.locale||this.defaultLocale},e.isSet=a,e.lookup=function(t,e){e=e||{};var n,i,o,s,r=this.locales.get(e.locale).slice();for(o=this.getFullScope(t,e);r.length;)if(n=r.shift(),i=o.split(e.separator||this.defaultSeparator),s=this.translations[n]){for(;i.length&&null!=(s=s[i.shift()]););if(null!=s)return s}if(a(e.defaultValue))return m(e.defaultValue,t)},e.pluralizationLookupWithoutFallback=function(t,e,n){var i,o,r=this.pluralization.get(e)(t);if(n&&s(n))for(;r.length;)if(i=r.shift(),a(n[i])){o=n[i];break}return o},e.pluralizationLookup=function(t,e,n){n=n||{};var i,o,r,l,h=this.locales.get(n.locale).slice();for(e=this.getFullScope(e,n);h.length;)if(i=h.shift(),o=e.split(n.separator||this.defaultSeparator),r=this.translations[i]){for(;o.length&&(r=r[o.shift()],s(r));)0===o.length&&(l=this.pluralizationLookupWithoutFallback(t,i,r));if(null!=l)break}return null==l&&a(n.defaultValue)&&(l=s(n.defaultValue)?this.pluralizationLookupWithoutFallback(t,n.locale,n.defaultValue):n.defaultValue,r=n.defaultValue),{message:l,translations:r}},e.meridian=function(){var t=this.lookup("time"),e=this.lookup("date");return t&&t.am&&t.pm?[t.am,t.pm]:e&&e.meridian?e.meridian:f.meridian},e.prepareOptions=function(){for(var t,e=n.call(arguments),i={};e.length;)if("object"==typeof(t=e.shift()))for(var o in t)t.hasOwnProperty(o)&&(a(i[o])||(i[o]=t[o]));return i},e.createTranslationOptions=function(t,e){var n=[{scope:t}];return a(e.defaults)&&(n=n.concat(e.defaults)),a(e.defaultValue)&&n.push({message:e.defaultValue}),n},e.translate=function(t,e){e=e||{};var n,i=this.createTranslationOptions(t,e),o=t,r=this.prepareOptions(e);return delete r.defaultValue,i.some((function(e){if(a(e.scope)?(o=e.scope,n=this.lookup(o,r)):a(e.message)&&(n=m(e.message,t)),null!=n)return!0}),this)?("string"==typeof n?n=this.interpolate(n,e):l(n)?n=n.map((function(t){return"string"==typeof t?this.interpolate(t,e):t}),this):s(n)&&a(e.count)&&(n=this.pluralize(e.count,o,e)),n):this.missingTranslation(t,e)},e.interpolate=function(t,e){if(null==t)return t;e=e||{};var n,i,o,s,r=t.match(this.placeholder);if(!r)return t;for(;r.length;)o=(n=r.shift()).replace(this.placeholder,"$1"),i=a(e[o])?e[o].toString().replace(/\$/gm,"_#$#_"):o in e?this.nullPlaceholder(n,t,e):this.missingPlaceholder(n,t,e),s=new RegExp(n.replace(/{/gm,"\\{").replace(/}/gm,"\\}")),t=t.replace(s,i);return t.replace(/_#\$#_/g,"$")},e.pluralize=function(t,e,n){var i,o;return n=this.prepareOptions({count:String(t)},n),void 0===(o=this.pluralizationLookup(t,e,n)).translations||null==o.translations?this.missingTranslation(e,n):void 0!==o.message&&null!=o.message?this.interpolate(o.message,n):(i=this.pluralization.get(n.locale),this.missingTranslation(e+"."+i(t)[0],n))},e.missingTranslation=function(t,e){if("guess"===this.missingBehaviour){var n=t.split(".").slice(-1)[0];return(this.missingTranslationPrefix.length>0?this.missingTranslationPrefix:"")+n.replace(/_/g," ").replace(/([a-z])([A-Z])/g,(function(t,e,n){return e+" "+n.toLowerCase()}))}return'[missing "'+[null!=e&&null!=e.locale?e.locale:this.currentLocale(),this.getFullScope(t,e)].join(e.separator||this.defaultSeparator)+'" translation]'},e.missingPlaceholder=function(t){return"[missing "+t+" value]"},e.nullPlaceholder=function(){return e.missingPlaceholder.apply(e,arguments)},e.toNumber=function(t,e){e=this.prepareOptions(e,this.lookup("number.format"),g);var n,i,s=t<0,r=o(Math.abs(t),e.precision).toString().split("."),a=[],l=e.format||"%n",h=s?"-":"";for(t=r[0],n=r[1];t.length>0;)a.unshift(t.substr(Math.max(0,t.length-3),3)),t=t.substr(0,t.length-3);return i=a.join(e.delimiter),e.strip_insignificant_zeros&&n&&(n=n.replace(/0+$/,"")),e.precision>0&&n&&(i+=e.separator+n),i=(l=e.sign_first?"%s"+l:l.replace("%n","%s%n")).replace("%u",e.unit).replace("%n",i).replace("%s",h)},e.toCurrency=function(t,e){return e=this.prepareOptions(e,this.lookup("number.currency.format",e),this.lookup("number.format",e),v),this.toNumber(t,e)},e.localize=function(t,e,n){switch(n||(n={}),t){case"currency":return this.toCurrency(e,n);case"number":return t=this.lookup("number.format",n),this.toNumber(e,t);case"percentage":return this.toPercentage(e,n);default:var i;return i=t.match(/^(date|time)/)?this.toTime(t,e,n):e.toString(),this.interpolate(i,n)}},e.parseDate=function(t){var e,n,i;if(null==t)return t;if("object"==typeof t)return t;if(e=t.toString().match(/(\d{4})-(\d{2})-(\d{2})(?:[ T](\d{2}):(\d{2}):(\d{2})([\.,]\d{1,3})?)?(Z|\+00:?00)?/)){for(var o=1;o<=6;o++)e[o]=parseInt(e[o],10)||0;e[2]-=1,i=e[7]?1e3*("0"+e[7]):null,n=e[8]?new Date(Date.UTC(e[1],e[2],e[3],e[4],e[5],e[6],i)):new Date(e[1],e[2],e[3],e[4],e[5],e[6],i)}else"number"==typeof t?(n=new Date).setTime(t):t.match(/([A-Z][a-z]{2}) ([A-Z][a-z]{2}) (\d+) (\d+:\d+:\d+) ([+-]\d+) (\d+)/)?(n=new Date).setTime(Date.parse([RegExp.$1,RegExp.$2,RegExp.$3,RegExp.$6,RegExp.$4,RegExp.$5].join(" "))):(t.match(/\d+ \d+:\d+:\d+ [+-]\d+ \d+/),(n=new Date).setTime(Date.parse(t)));return n},e.strftime=function(t,n,o){o=this.lookup("date",o);var s=e.meridian();if(o||(o={}),o=this.prepareOptions(o,f),isNaN(t.getTime()))throw new Error("I18n.strftime() requires a valid date object, but received an invalid date.");var r=t.getDay(),a=t.getDate(),l=t.getFullYear(),h=t.getMonth()+1,p=t.getHours(),u=p,c=p>11?1:0,d=t.getSeconds(),m=t.getMinutes(),_=t.getTimezoneOffset(),g=Math.floor(Math.abs(_/60)),v=Math.abs(_)-60*g,b=(_>0?"-":"+")+(g.toString().length<2?"0"+g:g)+(v.toString().length<2?"0"+v:v);return u>12?u-=12:0===u&&(u=12),n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=(n=n.replace("%a",o.abbr_day_names[r])).replace("%A",o.day_names[r])).replace("%b",o.abbr_month_names[h])).replace("%B",o.month_names[h])).replace("%d",i(a))).replace("%e",a)).replace("%-d",a)).replace("%H",i(p))).replace("%-H",p)).replace("%k",p)).replace("%I",i(u))).replace("%-I",u)).replace("%l",u)).replace("%m",i(h))).replace("%-m",h)).replace("%M",i(m))).replace("%-M",m)).replace("%p",s[c])).replace("%P",s[c].toLowerCase())).replace("%S",i(d))).replace("%-S",d)).replace("%w",r)).replace("%y",i(l))).replace("%-y",i(l).replace(/^0+/,""))).replace("%Y",l)).replace("%z",b)).replace("%Z",b)},e.toTime=function(t,e,n){var i=this.parseDate(e),o=this.lookup(t,n);if(null==i)return i;var s=i.toString();return s.match(/invalid/i)?s:o?this.strftime(i,o,n):s},e.toPercentage=function(t,e){return e=this.prepareOptions(e,this.lookup("number.percentage.format",e),this.lookup("number.format",e),b),this.toNumber(t,e)},e.toHumanSize=function(t,e){for(var n,i,o,s=1024,r=t,a=0;r>=s&&a<4;)r/=s,a+=1;return 0===a?(o=this.getFullScope("number.human.storage_units.units.byte",e),n=this.t(o,{count:r}),i=0):(o=this.getFullScope("number.human.storage_units.units."+y[a],e),n=this.t(o),i=r-Math.floor(r)==0?0:1),e=this.prepareOptions(e,{unit:n,precision:i,format:"%n%u",delimiter:""}),this.toNumber(r,e)},e.getFullScope=function(t,e){return e=e||{},l(t)&&(t=t.join(e.separator||this.defaultSeparator)),e.scope&&(t=[e.scope,t].join(e.separator||this.defaultSeparator)),t},e.extend=function(t,e){return void 0===t&&void 0===e?{}:_(t,e)},e.t=e.translate.bind(e),e.l=e.localize.bind(e),e.p=e.pluralize.bind(e),e})),I18n.translations||(I18n.translations={}),I18n.translations[""]=I18n.extend(I18n.translations[""]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.af=I18n.extend(I18n.translations.af||{},{javascripts:{embed:{report_problem:"Rapporteer 'n probleem"}}}),I18n.translations.ak=I18n.extend(I18n.translations.ak||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.aln=I18n.extend(I18n.translations.aln||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.am=I18n.extend(I18n.translations.am||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ar=I18n.extend(I18n.translations.ar||{},{javascripts:{embed:{report_problem:"\u0623\u0628\u0644\u063a \u0639\u0646 \u0645\u0634\u0643\u0644\u0629"}}}),I18n.translations["ar-AA"]=I18n.extend(I18n.translations["ar-AA"]||{},{javascripts:{embed:{report_problem:"\u0623\u0628\u0644\u063a \u0639\u0646 \u0645\u0634\u0643\u0644\u0629"}}}),I18n.translations.arz=I18n.extend(I18n.translations.arz||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.as=I18n.extend(I18n.translations.as||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ast=I18n.extend(I18n.translations.ast||{},{javascripts:{embed:{report_problem:"Informar d'un problema"}}}),I18n.translations.ay=I18n.extend(I18n.translations.ay||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.az=I18n.extend(I18n.translations.az||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ba=I18n.extend(I18n.translations.ba||{},{javascripts:{embed:{report_problem:"\u041f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0445\u0430\u04a1\u044b\u043d\u0434\u0430 \u0445\u04d9\u0431\u04d9\u0440 \u0438\u0442\u0435\u0440\u0433\u04d9"}}}),I18n.translations.be=I18n.extend(I18n.translations.be||{},{javascripts:{embed:{report_problem:"\u041f\u0430\u0432\u0435\u0434\u0430\u043c\u0456\u0446\u044c \u0430\u0431 \u043f\u0440\u0430\u0431\u043b\u0435\u043c\u0435"}}}),I18n.translations["be-tarask"]=I18n.extend(I18n.translations["be-tarask"]||{},{javascripts:{embed:{report_problem:"\u041f\u0430\u0432\u0435\u0434\u0430\u043c\u0456\u0446\u044c \u0430\u0431 \u043f\u0440\u0430\u0431\u043b\u0435\u043c\u0435"}}}),I18n.translations.bg=I18n.extend(I18n.translations.bg||{},{javascripts:{embed:{report_problem:"\u0414\u043e\u043a\u043b\u0430\u0434\u0432\u0430\u043d\u0435 \u0437\u0430 \u043f\u0440\u043e\u0431\u043b\u0435\u043c"}}}),I18n.translations["bg-BG"]=I18n.extend(I18n.translations["bg-BG"]||{},{javascripts:{embed:{report_problem:"\u0414\u043e\u043a\u043b\u0430\u0434\u0432\u0430\u043d\u0435 \u0437\u0430 \u043f\u0440\u043e\u0431\u043b\u0435\u043c"}}}),I18n.translations.bn=I18n.extend(I18n.translations.bn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.bo=I18n.extend(I18n.translations.bo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.bqi=I18n.extend(I18n.translations.bqi||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.br=I18n.extend(I18n.translations.br||{},{javascripts:{embed:{report_problem:"Menegi\xf1 ur gudenn"}}}),I18n.translations.bs=I18n.extend(I18n.translations.bs||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ca=I18n.extend(I18n.translations.ca||{},{javascripts:{
|
|
embed:{report_problem:"Informeu sobre un problema"}}}),I18n.translations.ce=I18n.extend(I18n.translations.ce||{},{javascripts:{embed:{report_problem:"\u041f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u0445 \u043b\u0430\u044c\u0446\u043d\u0430 \u0445\u0430\u0438\u0439\u0442\u0430"}}}),I18n.translations.ckb=I18n.extend(I18n.translations.ckb||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.co=I18n.extend(I18n.translations.co||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.cs=I18n.extend(I18n.translations.cs||{},{javascripts:{embed:{report_problem:"Nahl\xe1sit probl\xe9m"}}}),I18n.translations.cv=I18n.extend(I18n.translations.cv||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.cy=I18n.extend(I18n.translations.cy||{},{javascripts:{embed:{report_problem:"Rhoi gwybod am broblem"}}}),I18n.translations.da=I18n.extend(I18n.translations.da||{},{javascripts:{embed:{report_problem:"Rapporter et problem"}}}),I18n.translations.de=I18n.extend(I18n.translations.de||{},{javascripts:{embed:{report_problem:"Ein Problem melden"}}}),I18n.translations["de-AT"]=I18n.extend(I18n.translations["de-AT"]||{},{javascripts:{embed:{report_problem:"Ein Problem melden"}}}),I18n.translations["de-CH"]=I18n.extend(I18n.translations["de-CH"]||{},{javascripts:{embed:{report_problem:"Ein Problem melden"}}}),I18n.translations["de-DE"]=I18n.extend(I18n.translations["de-DE"]||{},{javascripts:{embed:{report_problem:"Ein Problem melden"}}}),I18n.translations.diq=I18n.extend(I18n.translations.diq||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.dsb=I18n.extend(I18n.translations.dsb||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.dv=I18n.extend(I18n.translations.dv||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.dz=I18n.extend(I18n.translations.dz||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ee=I18n.extend(I18n.translations.ee||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.el=I18n.extend(I18n.translations.el||{},{javascripts:{embed:{report_problem:"\u0391\u03bd\u03b1\u03c6\u03bf\u03c1\u03ac \u03c0\u03c1\u03bf\u03b2\u03bb\u03ae\u03bc\u03b1\u03c4\u03bf\u03c2"}}}),I18n.translations["el-CY"]=I18n.extend(I18n.translations["el-CY"]||{},{javascripts:{embed:{report_problem:"\u0391\u03bd\u03b1\u03c6\u03bf\u03c1\u03ac \u03c0\u03c1\u03bf\u03b2\u03bb\u03ae\u03bc\u03b1\u03c4\u03bf\u03c2"}}}),I18n.translations.en=I18n.extend(I18n.translations.en||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-AU"]=I18n.extend(I18n.translations["en-AU"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-CA"]=I18n.extend(I18n.translations["en-CA"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-CY"]=I18n.extend(I18n.translations["en-CY"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-GB"]=I18n.extend(I18n.translations["en-GB"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-IE"]=I18n.extend(I18n.translations["en-IE"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-IN"]=I18n.extend(I18n.translations["en-IN"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-NZ"]=I18n.extend(I18n.translations["en-NZ"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-PH"]=I18n.extend(I18n.translations["en-PH"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-TT"]=I18n.extend(I18n.translations["en-TT"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-US"]=I18n.extend(I18n.translations["en-US"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["en-ZA"]=I18n.extend(I18n.translations["en-ZA"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.eo=I18n.extend(I18n.translations.eo||{},{javascripts:{embed:{report_problem:"Raporti problemon"}}}),I18n.translations.es=I18n.extend(I18n.translations.es||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-419"]=I18n.extend(I18n.translations["es-419"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-AR"]=I18n.extend(I18n.translations["es-AR"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-CL"]=I18n.extend(I18n.translations["es-CL"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-CO"]=I18n.extend(I18n.translations["es-CO"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-CR"]=I18n.extend(I18n.translations["es-CR"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-EC"]=I18n.extend(I18n.translations["es-EC"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-ES"]=I18n.extend(I18n.translations["es-ES"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-MX"]=I18n.extend(I18n.translations["es-MX"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-NI"]=I18n.extend(I18n.translations["es-NI"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-PA"]=I18n.extend(I18n.translations["es-PA"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-PE"]=I18n.extend(I18n.translations["es-PE"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-US"]=I18n.extend(I18n.translations["es-US"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations["es-VE"]=I18n.extend(I18n.translations["es-VE"]||{},{javascripts:{embed:{report_problem:"Reportar un problema"}}}),I18n.translations.et=I18n.extend(I18n.translations.et||{},{javascripts:{embed:{report_problem:"Teata probleemist"}}}),I18n.translations.eu=I18n.extend(I18n.translations.eu||{},{javascripts:{embed:{report_problem:"Arazo baten berri eman"}}}),I18n.translations.fa=I18n.extend(I18n.translations.fa||{},{javascripts:{embed:{report_problem:"\u06af\u0632\u0627\u0631\u0634 \u0645\u0634\u06a9\u0644"}}}),I18n.translations["fa-IR"]=I18n.extend(I18n.translations["fa-IR"]||{},{javascripts:{embed:{report_problem:"\u06af\u0632\u0627\u0631\u0634 \u0645\u0634\u06a9\u0644"}}}),I18n.translations.ff=I18n.extend(I18n.translations.ff||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.fi=I18n.extend(I18n.translations.fi||{},{javascripts:{embed:{report_problem:"Ilmoita ongelmasta"}}}),I18n.translations.fil=I18n.extend(I18n.translations.fil||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.fit=I18n.extend(I18n.translations.fit||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.fr=I18n.extend(I18n.translations.fr||{},{javascripts:{embed:{report_problem:"Signaler un probl\xe8me"}}}),I18n.translations["fr-CA"]=I18n.extend(I18n.translations["fr-CA"]||{},{javascripts:{embed:{report_problem:"Signaler un probl\xe8me"}}}),I18n.translations["fr-CH"]=I18n.extend(I18n.translations["fr-CH"]||{},{javascripts:{embed:{report_problem:"Signaler un probl\xe8me"}}}),I18n.translations["fr-FR"]=I18n.extend(I18n.translations["fr-FR"]||{},{javascripts:{embed:{report_problem:"Signaler un probl\xe8me"}}}),I18n.translations.fur=I18n.extend(I18n.translations.fur||{},{javascripts:{embed:{report_problem:"Segnale un probleme"}}}),I18n.translations.fy=I18n.extend(I18n.translations.fy||{},{javascripts:{embed:{report_problem:"Probleem melde"}}}),I18n.translations.ga=I18n.extend(I18n.translations.ga||{},{javascripts:{embed:{report_problem:"Tuairiscigh fadhb"}}}),I18n.translations.gan=I18n.extend(I18n.translations.gan||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.gcf=I18n.extend(I18n.translations.gcf||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.gd=I18n.extend(I18n.translations.gd||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.gl=I18n.extend(I18n.translations.gl||{},{javascripts:{embed:{report_problem:"Denunciar un problema"}}}),I18n.translations.grt=I18n.extend(I18n.translations.grt||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.gsw=I18n.extend(I18n.translations.gsw||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.gu=I18n.extend(I18n.translations.gu||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ha=I18n.extend(I18n.translations.ha||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.he=I18n.extend(I18n.translations.he||{},{javascripts:{embed:{report_problem:"\u05d3\u05d9\u05d5\u05d5\u05d7 \u05e2\u05dc \u05d1\u05e2\u05d9\u05d4"}}}),I18n.translations["he-IL"]=I18n.extend(I18n.translations["he-IL"]||{},{javascripts:{embed:{report_problem:"\u05d3\u05d9\u05d5\u05d5\u05d7 \u05e2\u05dc \u05d1\u05e2\u05d9\u05d4"}}}),I18n.translations.hi=I18n.extend(I18n.translations.hi||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["hi-IN"]=I18n.extend(I18n.translations["hi-IN"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.hr=I18n.extend(I18n.translations.hr||{},{javascripts:{embed:{report_problem:"Prijavi problem"}}}),I18n.translations.hsb=I18n.extend(I18n.translations.hsb||{},{javascripts:{embed:{report_problem:"Problem zd\u017a\u011bli\u0107"}}}),I18n.translations.hu=I18n.extend(I18n.translations.hu||{},{javascripts:{embed:{report_problem:"Probl\xe9ma bejelent\xe9se"}}}),I18n.translations.hy=I18n.extend(I18n.translations.hy||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ia=I18n.extend(I18n.translations.ia||{},{javascripts:{embed:{report_problem:"Reportar problema"}}}),I18n.translations.id=I18n.extend(I18n.translations.id||{},{javascripts:{embed:{report_problem:"Laporkan masalah"}}}),I18n.translations.ig=I18n.extend(I18n.translations.ig||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.is=I18n.extend(I18n.translations.is||{},{javascripts:{embed:{report_problem:"Tilkynna vandam\xe1l"}}}),I18n.translations.it=I18n.extend(I18n.translations.it||{},{javascripts:{embed:{report_problem:"Segnala un problema"}}}),I18n.translations["it-CH"]=I18n.extend(I18n.translations["it-CH"]||{},{javascripts:{embed:{report_problem:"Segnala un problema"}}}),I18n.translations.ja=I18n.extend(I18n.translations.ja||{},{javascripts:{embed:{report_problem:"\u554f\u984c\u3092\u5831\u544a"}}}),I18n.translations.jam=I18n.extend(I18n.translations.jam||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.jv=I18n.extend(I18n.translations.jv||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ka=I18n.extend(I18n.translations.ka||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.kab=I18n.extend(I18n.translations.kab||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.kbd=I18n.extend(I18n.translations.kbd||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.kha=I18n.extend(I18n.translations.kha||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ki=I18n.extend(I18n.translations.ki||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.kk=I18n.extend(I18n.translations.kk||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["kk-Cyrl"]=I18n.extend(I18n.translations["kk-Cyrl"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.km=I18n.extend(I18n.translations.km||{},{javascripts:{embed:{report_problem:"\u179a\u17b6\u1799\u1780\u17b6\u179a\u178e\u17cd\u200b\u1794\u1789\u17d2\u17a0\u17b6"}}}),I18n.translations.kn=I18n.extend(I18n.translations.kn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ko=I18n.extend(I18n.translations.ko||{},{javascripts:{embed:{report_problem:"\ubb38\uc81c\uc810 \ubcf4\uace0"}}}),I18n.translations.ks=I18n.extend(I18n.translations.ks||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ksh=I18n.extend(I18n.translations.ksh||{},{javascripts:{embed:{report_problem:"Donn e Problehm m\xe4lde"}}}),I18n.translations.ku=I18n.extend(I18n.translations.ku||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["ku-Latn"]=I18n.extend(I18n.translations["ku-Latn"]||{},{javascripts:{embed:{report_problem:"Pirsgir\xeakek rapor bike"}}}),I18n.translations.ky=I18n.extend(I18n.translations.ky||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.lb=I18n.extend(I18n.translations.lb||{},{javascripts:{embed:{report_problem:"E Probleem mellen"}}}),I18n.translations.lg=I18n.extend(I18n.translations.lg||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.lij=I18n.extend(I18n.translations.lij||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ln=I18n.extend(I18n.translations.ln||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.lo=I18n.extend(I18n.translations.lo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.lt=I18n.extend(I18n.translations.lt||{},{javascripts:{embed:{report_problem:"Prane\u0161ti apie problem\u0105"}}}),I18n.translations.lus=I18n.extend(I18n.translations.lus||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.lv=I18n.extend(I18n.translations.lv||{},{javascripts:{embed:{report_problem:"Zi\u0146ot par probl\u0113mu"}}}),I18n.translations.mg=I18n.extend(I18n.translations.mg||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.mi=I18n.extend(I18n.translations.mi||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.mk=I18n.extend(I18n.translations.mk||{},{javascripts:{embed:{report_problem:"\u041f\u0440\u0438\u0458\u0430\u0432\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c"}}}),I18n.translations.ml=I18n.extend(I18n.translations.ml||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.mn=I18n.extend(I18n.translations.mn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.mo=I18n.extend(I18n.translations.mo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.mr=I18n.extend(I18n.translations.mr||{},{javascripts:{embed:{report_problem:"\u0938\u092e\u0938\u094d\u092f\u093e \u0915\u0933\u0935\u093e"}}}),I18n.translations["mr-IN"]=I18n.extend(I18n.translations["mr-IN"]||{},{javascripts:{embed:{report_problem:"\u0938\u092e\u0938\u094d\u092f\u093e \u0915\u0933\u0935\u093e"}}}),I18n.translations.ms=I18n.extend(I18n.translations.ms||{},{javascripts:{embed:{report_problem:"Laporkan masalah"}}}),I18n.translations.my=I18n.extend(I18n.translations.my||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nb=I18n.extend(I18n.translations.nb||{},{javascripts:{embed:{report_problem:"Rapporter et problem"}}}),I18n.translations.nd=I18n.extend(I18n.translations.nd||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nds=I18n.extend(I18n.translations.nds||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ne=I18n.extend(I18n.translations.ne||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nl=I18n.extend(I18n.translations.nl||{},{javascripts:{embed:{report_problem:"Een probleem melden"}}}),I18n.translations["nl-BE"]=I18n.extend(I18n.translations["nl-BE"]||{},{javascripts:{embed:{report_problem:"Een probleem melden"}}}),I18n.translations["nl-NL"]=I18n.extend(I18n.translations["nl-NL"]||{},{javascripts:{embed:{report_problem:"Een probleem melden"}}}),I18n.translations.nn=I18n.extend(I18n.translations.nn||{},{javascripts:{embed:{report_problem:"Rapporter eit problem"}}}),I18n.translations.no=I18n.extend(I18n.translations.no||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nqo=I18n.extend(I18n.translations.nqo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nr=I18n.extend(I18n.translations.nr||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nso=I18n.extend(I18n.translations.nso||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.nv=I18n.extend(I18n.translations.nv||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ny=I18n.extend(I18n.translations.ny||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.oc=I18n.extend(I18n.translations.oc||{},{javascripts:{embed:{report_problem:"Senhalar un probl\xe8ma"}}}),I18n.translations.om=I18n.extend(I18n.translations.om||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.or=I18n.extend(I18n.translations.or||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.pa=I18n.extend(I18n.translations.pa||{},{javascripts:{embed:{report_problem:"\u0a38\u0a2e\u0a71\u0a38\u0a3f\u0a06 \u0a26\u0a40 \u0a07\u0a24\u0a32\u0a3e\u0a39 \u0a26\u0a3f\u0a13"}}}),I18n.translations["pa-PK"]=I18n.extend(I18n.translations["pa-PK"]||{},{javascripts:{embed:{report_problem:"\u0a38\u0a2e\u0a71\u0a38\u0a3f\u0a06 \u0a26\u0a40 \u0a07\u0a24\u0a32\u0a3e\u0a39 \u0a26\u0a3f\u0a13"}}}),I18n.translations.pap=I18n.extend(I18n.translations.pap||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["pap-AW"]=I18n.extend(I18n.translations["pap-AW"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["pap-CW"]=I18n.extend(I18n.translations["pap-CW"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.pl=I18n.extend(I18n.translations.pl||{},{javascripts:{embed:{report_problem:"Zg\u0142o\u015b b\u0142\u0105d"}}}),I18n.translations.pnb=I18n.extend(I18n.translations.pnb||{},{javascripts:{embed:{report_problem:"\u06a9\u0648\u0626\u06cc \u0645\u0633\u0626\u0644\u06c1 \u0631\u067e\u0648\u0631\u0679 \u06a9\u0631\u06cc\u0648"}}}),I18n.translations.ps=I18n.extend(I18n.translations.ps||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.pt=I18n.extend(I18n.translations.pt||{},{javascripts:{embed:{report_problem:"Reportar um problema"}}}),I18n.translations["pt-BR"]=I18n.extend(I18n.translations["pt-BR"]||{},{javascripts:{embed:{report_problem:"Reportar um problema"}}}),I18n.translations["pt-PT"]=I18n.extend(I18n.translations["pt-PT"]||{},{javascripts:{embed:{report_problem:"Reportar um problema"}}}),I18n.translations.qu=I18n.extend(I18n.translations.qu||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.rm=I18n.extend(I18n.translations.rm||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ro=I18n.extend(I18n.translations.ro||{},{javascripts:{embed:{report_problem:"Semnalare problem\u0103"}}}),I18n.translations.ru=I18n.extend(I18n.translations.ru||{},{javascripts:{embed:{report_problem:"\u0421\u043e\u043e\u0431\u0449\u0438\u0442\u044c \u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0435"}}}),I18n.translations.rw=I18n.extend(I18n.translations.rw||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sat=I18n.extend(I18n.translations.sat||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sc=I18n.extend(I18n.translations.sc||{},{javascripts:{embed:{report_problem:"Sinnala unu problema"}}}),I18n.translations.scn=I18n.extend(I18n.translations.scn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sco=I18n.extend(I18n.translations.sco||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sd=I18n.extend(I18n.translations.sd||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sg=I18n.extend(I18n.translations.sg||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sh=I18n.extend(I18n.translations.sh||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.si=I18n.extend(I18n.translations.si||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sk=I18n.extend(I18n.translations.sk||{},{javascripts:{embed:{report_problem:"Nahl\xe1si\u0165 probl\xe9m"}}}),I18n.translations.skr=I18n.extend(I18n.translations.skr||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["skr-Arab"]=I18n.extend(I18n.translations["skr-Arab"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sl=I18n.extend(I18n.translations.sl||{},{javascripts:{embed:{report_problem:"Prijavi te\u017eavo"}}}),I18n.translations.sm=I18n.extend(I18n.translations.sm||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sn=I18n.extend(I18n.translations.sn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.so=I18n.extend(I18n.translations.so||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sq=I18n.extend(I18n.translations.sq||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sr=I18n.extend(I18n.translations.sr||{},{javascripts:{embed:{report_problem:"\u041f\u0440\u0438\u0458\u0430\u0432\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c"}}}),I18n.translations["sr-Latn"]=I18n.extend(I18n.translations["sr-Latn"]||{},{javascripts:{embed:{report_problem:"\u041f\u0440\u0438\u0458\u0430\u0432\u0438 \u043f\u0440\u043e\u0431\u043b\u0435\u043c"}}}),I18n.translations.ss=I18n.extend(I18n.translations.ss||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.st=I18n.extend(I18n.translations.st||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.su=I18n.extend(I18n.translations.su||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.sv=I18n.extend(I18n.translations.sv||{},{javascripts:{embed:{report_problem:"Rapportera ett problem"}}}),I18n.translations["sv-FI"]=I18n.extend(I18n.translations["sv-FI"]||{},{javascripts:{embed:{report_problem:"Rapportera ett problem"}}}),I18n.translations["sv-SE"]=I18n.extend(I18n.translations["sv-SE"]||{},{javascripts:{embed:{report_problem:"Rapportera ett problem"}}}),I18n.translations.sw=I18n.extend(I18n.translations.sw||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ta=I18n.extend(I18n.translations.ta||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.te=I18n.extend(I18n.translations.te||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tg=I18n.extend(I18n.translations.tg||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.th=I18n.extend(I18n.translations.th||{},{javascripts:{embed:{report_problem:"\u0e41\u0e08\u0e49\u0e07\u0e1b\u0e31\u0e0d\u0e2b\u0e32"}}}),I18n.translations.ti=I18n.extend(I18n.translations.ti||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tk=I18n.extend(I18n.translations.tk||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tl=I18n.extend(I18n.translations.tl||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tn=I18n.extend(I18n.translations.tn||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tr=I18n.extend(I18n.translations.tr||{},{javascripts:{embed:{report_problem:"Bir sorunu \u015fikayet et"}}}),I18n.translations.ts=I18n.extend(I18n.translations.ts||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tt=I18n.extend(I18n.translations.tt||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.tum=I18n.extend(I18n.translations.tum||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ug=I18n.extend(I18n.translations.ug||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.uk=I18n.extend(I18n.translations.uk||{},{javascripts:{embed:{report_problem:"\u041f\u043e\u0432\u0456\u0434\u043e\u043c\u0438\u0442\u0438 \u043f\u0440\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443"}}}),I18n.translations.ur=I18n.extend(I18n.translations.ur||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.uz=I18n.extend(I18n.translations.uz||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.ve=I18n.extend(I18n.translations.ve||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.vi=I18n.extend(I18n.translations.vi||{},{javascripts:{embed:{report_problem:"B\xe1o v\u1ea5n \u0111\u1ec1"}}}),I18n.translations.wa=I18n.extend(I18n.translations.wa||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.wo=I18n.extend(I18n.translations.wo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.xh=I18n.extend(I18n.translations.xh||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.xmf=I18n.extend(I18n.translations.xmf||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.yi=I18n.extend(I18n.translations.yi||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.yo=I18n.extend(I18n.translations.yo||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.yue=I18n.extend(I18n.translations.yue||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.zh=I18n.extend(I18n.translations.zh||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["zh-CN"]=I18n.extend(I18n.translations["zh-CN"]||{},{javascripts:{embed:{report_problem:"\u62a5\u544a\u95ee\u9898"}}}),I18n.translations["zh-HK"]=I18n.extend(I18n.translations["zh-HK"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations["zh-TW"]=I18n.extend(I18n.translations["zh-TW"]||{},{javascripts:{embed:{report_problem:"\u56de\u5831\u554f\u984c"}}}),I18n.translations["zh-yue"]=I18n.extend(I18n.translations["zh-yue"]||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),I18n.translations.zu=I18n.extend(I18n.translations.zu||{},{javascripts:{embed:{report_problem:"Report a problem"}}}),navigator.languages?I18n.locale=navigator.languages[0]:navigator.language&&(I18n.locale=navigator.language),window.onload=function(){for(var t={},e=(window.location.search||"?").slice(1).split("&"),n=0;n<e.length;n++){var i=e[n].split("=");t[i[0]]=decodeURIComponent(i[1]||"")}var o={},s={apikey:"6e5478c8a4f54c779f85573c0e399391"},r=L.map("map");if(r.attributionControl.setPrefix(""),r.removeControl(r.attributionControl),"cyclosm"===t.layer?(new L.OSM.CyclOSM).addTo(r):"cyclemap"===t.layer||"cycle map"===t.layer?new L.OSM.CycleMap(s).addTo(r):"transportmap"===t.layer?new L.OSM.TransportMap(s).addTo(r):"hot"===t.layer?(new L.OSM.HOT).addTo(r):new L.OSM.Mapnik(o).addTo(r),t.marker&&L.marker(t.marker.split(","),{icon:L.icon({iconUrl:"/assets/leaflet/dist/images/marker-icon-3d253116ec4ba0e1f22a01cdf1ff7f120fa4d89a6cd0933d68f12951d19809b4.png",iconSize:new L.Point(25,41),iconAnchor:new L.Point(12,41),shadowUrl:"/assets/leaflet/dist/images/marker-shadow-a2d94406ba198f61f68a71ed8f9f9c701122c0c33b775d990edceae4aece567f.png",shadowSize:new L.Point(41,41)})}).addTo(r),t.bbox){var a=t.bbox.split(",");r.fitBounds([L.latLng(a[1],a[0]),L.latLng(a[3],a[2])])}else r.fitWorld();r.addControl(new L.Control.OSMReportAProblem)},L.Control.OSMReportAProblem=L.Control.Attribution.extend({options:{position:"bottomright",prefix:'<a href="https://www.openstreetmap.org/fixthemap?lat={x}&lon={y}&zoom={z}" target="_blank">'+I18n.t("javascripts.embed.report_problem")+"</a>"},onAdd:function(t){var e=L.Control.Attribution.prototype.onAdd.call(this,t);return t.on("moveend",this._update,this),e},_update:function(){L.Control.Attribution.prototype._update.call(this),this._container.innerHTML=this._container.innerHTML.replace("{x}",this._map.getCenter().lat).replace("{y}",this._map.getCenter().lng).replace("{z}",this._map.getZoom())}}); |