@florasync/leaflet-geokit 0.5.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +47 -0
- package/dist/django/index.js +1800 -1553
- package/dist/django/index.js.map +1 -1
- package/dist/leaflet-geokit.es.js +1475 -1228
- package/dist/leaflet-geokit.es.js.map +1 -1
- package/dist/leaflet-geokit.external.es.js +912 -665
- package/dist/leaflet-geokit.external.es.js.map +1 -1
- package/dist/leaflet-geokit.umd.js +16 -16
- package/dist/leaflet-geokit.umd.js.map +1 -1
- package/dist/preact/{index-D8EjMf-1.js → index-DagV_wwR.js} +938 -691
- package/dist/preact/index-DagV_wwR.js.map +1 -0
- package/dist/preact/index.js +1 -1
- package/dist/preact-bundled/index.js +1762 -1515
- package/dist/preact-bundled/index.js.map +1 -1
- package/dist/react/{index-D8EjMf-1.js → index-DagV_wwR.js} +938 -691
- package/dist/react/index-DagV_wwR.js.map +1 -0
- package/dist/react/index.js +1 -1
- package/dist/react-bundled/index.js +1761 -1514
- package/dist/react-bundled/index.js.map +1 -1
- package/dist/types/src/components/LeafletDrawMapElement.d.ts +18 -0
- package/dist/types/src/lib/MapController.d.ts +7 -0
- package/dist/types/src/lib/TileProviderFactory.d.ts +45 -0
- package/dist/types/src/types/public.d.ts +58 -0
- package/dist/types/tests/component-branch-coverage.spec.d.ts +1 -0
- package/dist/types/tests/component-tile-provider.spec.d.ts +1 -0
- package/dist/types/tests/tile-provider-factory.spec.d.ts +1 -0
- package/package.json +12 -7
- package/dist/preact/index-D8EjMf-1.js.map +0 -1
- package/dist/react/index-D8EjMf-1.js.map +0 -1
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
(function(dt,ut){typeof exports=="object"&&typeof module!="undefined"?ut(exports):typeof define=="function"&&define.amd?define(["exports"],ut):(dt=typeof globalThis!="undefined"?globalThis:dt||self,ut(dt.LeafletGeoKit={}))})(this,(function(dt){"use strict";var
|
|
1
|
+
(function(dt,ut){typeof exports=="object"&&typeof module!="undefined"?ut(exports):typeof define=="function"&&define.amd?define(["exports"],ut):(dt=typeof globalThis!="undefined"?globalThis:dt||self,ut(dt.LeafletGeoKit={}))})(this,(function(dt){"use strict";var Zs=Object.defineProperty;var Hs=(dt,ut,zt)=>ut in dt?Zs(dt,ut,{enumerable:!0,configurable:!0,writable:!0,value:zt}):dt[ut]=zt;var k=(dt,ut,zt)=>Hs(dt,typeof ut!="symbol"?ut+"":ut,zt);function ut(m,c){for(var s=0;s<c.length;s++){const h=c[s];if(typeof h!="string"&&!Array.isArray(h)){for(const n in h)if(n!=="default"&&!(n in m)){const r=Object.getOwnPropertyDescriptor(h,n);r&&Object.defineProperty(m,n,r.get?r:{enumerable:!0,get:()=>h[n]})}}}return Object.freeze(Object.defineProperty(m,Symbol.toStringTag,{value:"Module"}))}const zt={trace:10,debug:20,info:30,warn:40,error:50};function uo(m,c){return m==="silent"?!1:zt[c]>=zt[m]}function fo(){try{return new Date().toISOString()}catch{return""}}function ve(m,c="debug",s=console){let h=c;const n=a=>(...u)=>{try{if(!uo(h,a))return;const f=`[${fo()}][${m}][${a.toUpperCase()}]`,_=s[a];typeof _=="function"?_(f,...u):s.log(f,...u)}catch{}};return{get level(){return h},setLevel(a){h=a},trace:n("trace"),debug:n("debug"),info:n("info"),warn:n("warn"),error:n("error"),child(a){return ve(`${m}:${a}`,h,s)}}}function po(m){return m&&m.__esModule&&Object.prototype.hasOwnProperty.call(m,"default")?m.default:m}var $t={exports:{}};/* @preserve
|
|
2
2
|
* Leaflet 1.9.4, a JS library for interactive maps. https://leafletjs.com
|
|
3
3
|
* (c) 2010-2023 Vladimir Agafonkin, (c) 2010-2011 CloudMade
|
|
4
|
-
*/var uo=Qt.exports,Oi;function Bi(){return Oi||(Oi=1,(function(g,h){(function(s,c){c(h)})(uo,(function(s){var c="1.9.4";function n(t){var e,i,o,l;for(i=1,o=arguments.length;i<o;i++){l=arguments[i];for(e in l)t[e]=l[e]}return t}var r=Object.create||(function(){function t(){}return function(e){return t.prototype=e,new t}})();function a(t,e){var i=Array.prototype.slice;if(t.bind)return t.bind.apply(t,i.call(arguments,1));var o=i.call(arguments,2);return function(){return t.apply(e,o.length?o.concat(i.call(arguments)):arguments)}}var u=0;function f(t){return"_leaflet_id"in t||(t._leaflet_id=++u),t._leaflet_id}function _(t,e,i){var o,l,d,p;return p=function(){o=!1,l&&(d.apply(i,l),l=!1)},d=function(){o?l=arguments:(t.apply(i,arguments),setTimeout(p,e),o=!0)},d}function m(t,e,i){var o=e[1],l=e[0],d=o-l;return t===o&&i?t:((t-l)%d+d)%d+l}function w(){return!1}function x(t,e){if(e===!1)return t;var i=Math.pow(10,e===void 0?6:e);return Math.round(t*i)/i}function E(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function P(t){return E(t).split(/\s+/)}function M(t,e){Object.prototype.hasOwnProperty.call(t,"options")||(t.options=t.options?r(t.options):{});for(var i in e)t.options[i]=e[i];return t.options}function U(t,e,i){var o=[];for(var l in t)o.push(encodeURIComponent(i?l.toUpperCase():l)+"="+encodeURIComponent(t[l]));return(!e||e.indexOf("?")===-1?"?":"&")+o.join("&")}var H=/\{ *([\w_ -]+) *\}/g;function T(t,e){return t.replace(H,function(i,o){var l=e[o];if(l===void 0)throw new Error("No value provided for variable "+i);return typeof l=="function"&&(l=l(e)),l})}var D=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"};function V(t,e){for(var i=0;i<t.length;i++)if(t[i]===e)return i;return-1}var j="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";function J(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}var K=0;function kt(t){var e=+new Date,i=Math.max(0,16-(e-K));return K=e+i,window.setTimeout(t,i)}var Tt=window.requestAnimationFrame||J("RequestAnimationFrame")||kt,ke=window.cancelAnimationFrame||J("CancelAnimationFrame")||J("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)};function rt(t,e,i){if(i&&Tt===kt)t.call(e);else return Tt.call(window,a(t,e))}function at(t){t&&ke.call(window,t)}var Ae={__proto__:null,extend:n,create:r,bind:a,get lastId(){return u},stamp:f,throttle:_,wrapNum:m,falseFn:w,formatNum:x,trim:E,splitWords:P,setOptions:M,getParamString:U,template:T,isArray:D,indexOf:V,emptyImageUrl:j,requestFn:Tt,cancelFn:ke,requestAnimFrame:rt,cancelAnimFrame:at};function pt(){}pt.extend=function(t){var e=function(){M(this),this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},i=e.__super__=this.prototype,o=r(i);o.constructor=e,e.prototype=o;for(var l in this)Object.prototype.hasOwnProperty.call(this,l)&&l!=="prototype"&&l!=="__super__"&&(e[l]=this[l]);return t.statics&&n(e,t.statics),t.includes&&(ee(t.includes),n.apply(null,[o].concat(t.includes))),n(o,t),delete o.statics,delete o.includes,o.options&&(o.options=i.options?r(i.options):{},n(o.options,t.options)),o._initHooks=[],o.callInitHooks=function(){if(!this._initHooksCalled){i.callInitHooks&&i.callInitHooks.call(this),this._initHooksCalled=!0;for(var d=0,p=o._initHooks.length;d<p;d++)o._initHooks[d].call(this)}},e},pt.include=function(t){var e=this.prototype.options;return n(this.prototype,t),t.options&&(this.prototype.options=e,this.mergeOptions(t.options)),this},pt.mergeOptions=function(t){return n(this.prototype.options,t),this},pt.addInitHook=function(t){var e=Array.prototype.slice.call(arguments,1),i=typeof t=="function"?t:function(){this[t].apply(this,e)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(i),this};function ee(t){if(!(typeof L=="undefined"||!L||!L.Mixin)){t=D(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)}}var ft={on:function(t,e,i){if(typeof t=="object")for(var o in t)this._on(o,t[o],e);else{t=P(t);for(var l=0,d=t.length;l<d;l++)this._on(t[l],e,i)}return this},off:function(t,e,i){if(!arguments.length)delete this._events;else if(typeof t=="object")for(var o in t)this._off(o,t[o],e);else{t=P(t);for(var l=arguments.length===1,d=0,p=t.length;d<p;d++)l?this._off(t[d]):this._off(t[d],e,i)}return this},_on:function(t,e,i,o){if(typeof e!="function"){console.warn("wrong listener type: "+typeof e);return}if(this._listens(t,e,i)===!1){i===this&&(i=void 0);var l={fn:e,ctx:i};o&&(l.once=!0),this._events=this._events||{},this._events[t]=this._events[t]||[],this._events[t].push(l)}},_off:function(t,e,i){var o,l,d;if(this._events&&(o=this._events[t],!!o)){if(arguments.length===1){if(this._firingCount)for(l=0,d=o.length;l<d;l++)o[l].fn=w;delete this._events[t];return}if(typeof e!="function"){console.warn("wrong listener type: "+typeof e);return}var p=this._listens(t,e,i);if(p!==!1){var v=o[p];this._firingCount&&(v.fn=w,this._events[t]=o=o.slice()),o.splice(p,1)}}},fire:function(t,e,i){if(!this.listens(t,i))return this;var o=n({},e,{type:t,target:this,sourceTarget:e&&e.sourceTarget||this});if(this._events){var l=this._events[t];if(l){this._firingCount=this._firingCount+1||1;for(var d=0,p=l.length;d<p;d++){var v=l[d],y=v.fn;v.once&&this.off(t,y,v.ctx),y.call(v.ctx||this,o)}this._firingCount--}}return i&&this._propagateEvent(o),this},listens:function(t,e,i,o){typeof t!="string"&&console.warn('"string" type argument expected');var l=e;typeof e!="function"&&(o=!!e,l=void 0,i=void 0);var d=this._events&&this._events[t];if(d&&d.length&&this._listens(t,l,i)!==!1)return!0;if(o){for(var p in this._eventParents)if(this._eventParents[p].listens(t,e,i,o))return!0}return!1},_listens:function(t,e,i){if(!this._events)return!1;var o=this._events[t]||[];if(!e)return!!o.length;i===this&&(i=void 0);for(var l=0,d=o.length;l<d;l++)if(o[l].fn===e&&o[l].ctx===i)return l;return!1},once:function(t,e,i){if(typeof t=="object")for(var o in t)this._on(o,t[o],e,!0);else{t=P(t);for(var l=0,d=t.length;l<d;l++)this._on(t[l],e,i,!0)}return this},addEventParent:function(t){return this._eventParents=this._eventParents||{},this._eventParents[f(t)]=t,this},removeEventParent:function(t){return this._eventParents&&delete this._eventParents[f(t)],this},_propagateEvent:function(t){for(var e in this._eventParents)this._eventParents[e].fire(t.type,n({layer:t.target,propagatedFrom:t.target},t),!0)}};ft.addEventListener=ft.on,ft.removeEventListener=ft.clearAllEventListeners=ft.off,ft.addOneTimeEventListener=ft.once,ft.fireEvent=ft.fire,ft.hasEventListeners=ft.listens;var ie=pt.extend(ft);function z(t,e,i){this.x=i?Math.round(t):t,this.y=i?Math.round(e):e}var Ki=Math.trunc||function(t){return t>0?Math.floor(t):Math.ceil(t)};z.prototype={clone:function(){return new z(this.x,this.y)},add:function(t){return this.clone()._add(I(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(I(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 z(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new z(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=Ki(this.x),this.y=Ki(this.y),this},distanceTo:function(t){t=I(t);var e=t.x-this.x,i=t.y-this.y;return Math.sqrt(e*e+i*i)},equals:function(t){return t=I(t),t.x===this.x&&t.y===this.y},contains:function(t){return t=I(t),Math.abs(t.x)<=Math.abs(this.x)&&Math.abs(t.y)<=Math.abs(this.y)},toString:function(){return"Point("+x(this.x)+", "+x(this.y)+")"}};function I(t,e,i){return t instanceof z?t:D(t)?new z(t[0],t[1]):t==null?t:typeof t=="object"&&"x"in t&&"y"in t?new z(t.x,t.y):new z(t,e,i)}function Y(t,e){if(t)for(var i=e?[t,e]:t,o=0,l=i.length;o<l;o++)this.extend(i[o])}Y.prototype={extend:function(t){var e,i;if(!t)return this;if(t instanceof z||typeof t[0]=="number"||"x"in t)e=i=I(t);else if(t=lt(t),e=t.min,i=t.max,!e||!i)return this;return!this.min&&!this.max?(this.min=e.clone(),this.max=i.clone()):(this.min.x=Math.min(e.x,this.min.x),this.max.x=Math.max(i.x,this.max.x),this.min.y=Math.min(e.y,this.min.y),this.max.y=Math.max(i.y,this.max.y)),this},getCenter:function(t){return I((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return I(this.min.x,this.max.y)},getTopRight:function(){return I(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,i;return typeof t[0]=="number"||t instanceof z?t=I(t):t=lt(t),t instanceof Y?(e=t.min,i=t.max):e=i=t,e.x>=this.min.x&&i.x<=this.max.x&&e.y>=this.min.y&&i.y<=this.max.y},intersects:function(t){t=lt(t);var e=this.min,i=this.max,o=t.min,l=t.max,d=l.x>=e.x&&o.x<=i.x,p=l.y>=e.y&&o.y<=i.y;return d&&p},overlaps:function(t){t=lt(t);var e=this.min,i=this.max,o=t.min,l=t.max,d=l.x>e.x&&o.x<i.x,p=l.y>e.y&&o.y<i.y;return d&&p},isValid:function(){return!!(this.min&&this.max)},pad:function(t){var e=this.min,i=this.max,o=Math.abs(e.x-i.x)*t,l=Math.abs(e.y-i.y)*t;return lt(I(e.x-o,e.y-l),I(i.x+o,i.y+l))},equals:function(t){return t?(t=lt(t),this.min.equals(t.getTopLeft())&&this.max.equals(t.getBottomRight())):!1}};function lt(t,e){return!t||t instanceof Y?t:new Y(t,e)}function ht(t,e){if(t)for(var i=e?[t,e]:t,o=0,l=i.length;o<l;o++)this.extend(i[o])}ht.prototype={extend:function(t){var e=this._southWest,i=this._northEast,o,l;if(t instanceof G)o=t,l=t;else if(t instanceof ht){if(o=t._southWest,l=t._northEast,!o||!l)return this}else return t?this.extend(N(t)||$(t)):this;return!e&&!i?(this._southWest=new G(o.lat,o.lng),this._northEast=new G(l.lat,l.lng)):(e.lat=Math.min(o.lat,e.lat),e.lng=Math.min(o.lng,e.lng),i.lat=Math.max(l.lat,i.lat),i.lng=Math.max(l.lng,i.lng)),this},pad:function(t){var e=this._southWest,i=this._northEast,o=Math.abs(e.lat-i.lat)*t,l=Math.abs(e.lng-i.lng)*t;return new ht(new G(e.lat-o,e.lng-l),new G(i.lat+o,i.lng+l))},getCenter:function(){return new G((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 G(this.getNorth(),this.getWest())},getSouthEast:function(){return new G(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){typeof t[0]=="number"||t instanceof G||"lat"in t?t=N(t):t=$(t);var e=this._southWest,i=this._northEast,o,l;return t instanceof ht?(o=t.getSouthWest(),l=t.getNorthEast()):o=l=t,o.lat>=e.lat&&l.lat<=i.lat&&o.lng>=e.lng&&l.lng<=i.lng},intersects:function(t){t=$(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),l=t.getNorthEast(),d=l.lat>=e.lat&&o.lat<=i.lat,p=l.lng>=e.lng&&o.lng<=i.lng;return d&&p},overlaps:function(t){t=$(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),l=t.getNorthEast(),d=l.lat>e.lat&&o.lat<i.lat,p=l.lng>e.lng&&o.lng<i.lng;return d&&p},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(t,e){return t?(t=$(t),this._southWest.equals(t.getSouthWest(),e)&&this._northEast.equals(t.getNorthEast(),e)):!1},isValid:function(){return!!(this._southWest&&this._northEast)}};function $(t,e){return t instanceof ht?t:new ht(t,e)}function G(t,e,i){if(isNaN(t)||isNaN(e))throw new Error("Invalid LatLng object: ("+t+", "+e+")");this.lat=+t,this.lng=+e,i!==void 0&&(this.alt=+i)}G.prototype={equals:function(t,e){if(!t)return!1;t=N(t);var i=Math.max(Math.abs(this.lat-t.lat),Math.abs(this.lng-t.lng));return i<=(e===void 0?1e-9:e)},toString:function(t){return"LatLng("+x(this.lat,t)+", "+x(this.lng,t)+")"},distanceTo:function(t){return St.distance(this,N(t))},wrap:function(){return St.wrapLatLng(this)},toBounds:function(t){var e=180*t/40075017,i=e/Math.cos(Math.PI/180*this.lat);return $([this.lat-e,this.lng-i],[this.lat+e,this.lng+i])},clone:function(){return new G(this.lat,this.lng,this.alt)}};function N(t,e,i){return t instanceof G?t:D(t)&&typeof t[0]!="object"?t.length===3?new G(t[0],t[1],t[2]):t.length===2?new G(t[0],t[1]):null:t==null?t:typeof t=="object"&&"lat"in t?new G(t.lat,"lng"in t?t.lng:t.lon,t.alt):e===void 0?null:new G(t,e,i)}var At={latLngToPoint:function(t,e){var i=this.projection.project(t),o=this.scale(e);return this.transformation._transform(i,o)},pointToLatLng:function(t,e){var i=this.scale(e),o=this.transformation.untransform(t,i);return this.projection.unproject(o)},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,i=this.scale(t),o=this.transformation.transform(e.min,i),l=this.transformation.transform(e.max,i);return new Y(o,l)},infinite:!1,wrapLatLng:function(t){var e=this.wrapLng?m(t.lng,this.wrapLng,!0):t.lng,i=this.wrapLat?m(t.lat,this.wrapLat,!0):t.lat,o=t.alt;return new G(i,e,o)},wrapLatLngBounds:function(t){var e=t.getCenter(),i=this.wrapLatLng(e),o=e.lat-i.lat,l=e.lng-i.lng;if(o===0&&l===0)return t;var d=t.getSouthWest(),p=t.getNorthEast(),v=new G(d.lat-o,d.lng-l),y=new G(p.lat-o,p.lng-l);return new ht(v,y)}},St=n({},At,{wrapLng:[-180,180],R:6371e3,distance:function(t,e){var i=Math.PI/180,o=t.lat*i,l=e.lat*i,d=Math.sin((e.lat-t.lat)*i/2),p=Math.sin((e.lng-t.lng)*i/2),v=d*d+Math.cos(o)*Math.cos(l)*p*p,y=2*Math.atan2(Math.sqrt(v),Math.sqrt(1-v));return this.R*y}}),Xi=6378137,ei={R:Xi,MAX_LATITUDE:85.0511287798,project:function(t){var e=Math.PI/180,i=this.MAX_LATITUDE,o=Math.max(Math.min(i,t.lat),-i),l=Math.sin(o*e);return new z(this.R*t.lng*e,this.R*Math.log((1+l)/(1-l))/2)},unproject:function(t){var e=180/Math.PI;return new G((2*Math.atan(Math.exp(t.y/this.R))-Math.PI/2)*e,t.x*e/this.R)},bounds:(function(){var t=Xi*Math.PI;return new Y([-t,-t],[t,t])})()};function ii(t,e,i,o){if(D(t)){this._a=t[0],this._b=t[1],this._c=t[2],this._d=t[3];return}this._a=t,this._b=e,this._c=i,this._d=o}ii.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 z((t.x/e-this._b)/this._a,(t.y/e-this._d)/this._c)}};function ne(t,e,i,o){return new ii(t,e,i,o)}var ni=n({},St,{code:"EPSG:3857",projection:ei,transformation:(function(){var t=.5/(Math.PI*ei.R);return ne(t,.5,-t,.5)})()}),dr=n({},ni,{code:"EPSG:900913"});function Qi(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function $i(t,e){var i="",o,l,d,p,v,y;for(o=0,d=t.length;o<d;o++){for(v=t[o],l=0,p=v.length;l<p;l++)y=v[l],i+=(l?"L":"M")+y.x+" "+y.y;i+=e?C.svg?"z":"x":""}return i||"M0 0"}var oi=document.documentElement.style,Me="ActiveXObject"in window,ur=Me&&!document.addEventListener,tn="msLaunchUri"in navigator&&!("documentMode"in document),ri=Lt("webkit"),en=Lt("android"),nn=Lt("android 2")||Lt("android 3"),fr=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),pr=en&&Lt("Google")&&fr<537&&!("AudioNode"in window),si=!!window.opera,on=!tn&&Lt("chrome"),rn=Lt("gecko")&&!ri&&!si&&!Me,mr=!on&&Lt("safari"),sn=Lt("phantom"),an="OTransition"in oi,_r=navigator.platform.indexOf("Win")===0,ln=Me&&"transition"in oi,ai="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!nn,hn="MozPerspective"in oi,gr=!window.L_DISABLE_3D&&(ln||ai||hn)&&!an&&!sn,oe=typeof orientation!="undefined"||Lt("mobile"),vr=oe&&ri,yr=oe&&ai,cn=!window.PointerEvent&&window.MSPointerEvent,dn=!!(window.PointerEvent||cn),un="ontouchstart"in window||!!window.TouchEvent,Lr=!window.L_NO_TOUCH&&(un||dn),wr=oe&&si,br=oe&&rn,xr=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,kr=(function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("testPassiveEventSupport",w,e),window.removeEventListener("testPassiveEventSupport",w,e)}catch{}return t})(),Ar=(function(){return!!document.createElement("canvas").getContext})(),li=!!(document.createElementNS&&Qi("svg").createSVGRect),Mr=!!li&&(function(){var t=document.createElement("div");return t.innerHTML="<svg/>",(t.firstChild&&t.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"})(),Er=!li&&(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&&typeof e.adj=="object"}catch{return!1}})(),Pr=navigator.platform.indexOf("Mac")===0,Cr=navigator.platform.indexOf("Linux")===0;function Lt(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}var C={ie:Me,ielt9:ur,edge:tn,webkit:ri,android:en,android23:nn,androidStock:pr,opera:si,chrome:on,gecko:rn,safari:mr,phantom:sn,opera12:an,win:_r,ie3d:ln,webkit3d:ai,gecko3d:hn,any3d:gr,mobile:oe,mobileWebkit:vr,mobileWebkit3d:yr,msPointer:cn,pointer:dn,touch:Lr,touchNative:un,mobileOpera:wr,mobileGecko:br,retina:xr,passiveEvents:kr,canvas:Ar,svg:li,vml:Er,inlineSvg:Mr,mac:Pr,linux:Cr},fn=C.msPointer?"MSPointerDown":"pointerdown",pn=C.msPointer?"MSPointerMove":"pointermove",mn=C.msPointer?"MSPointerUp":"pointerup",_n=C.msPointer?"MSPointerCancel":"pointercancel",hi={touchstart:fn,touchmove:pn,touchend:mn,touchcancel:_n},gn={touchstart:Or,touchmove:Ee,touchend:Ee,touchcancel:Ee},Gt={},vn=!1;function Tr(t,e,i){return e==="touchstart"&&zr(),gn[e]?(i=gn[e].bind(this,i),t.addEventListener(hi[e],i,!1),i):(console.warn("wrong event specified:",e),w)}function Sr(t,e,i){if(!hi[e]){console.warn("wrong event specified:",e);return}t.removeEventListener(hi[e],i,!1)}function Dr(t){Gt[t.pointerId]=t}function Ir(t){Gt[t.pointerId]&&(Gt[t.pointerId]=t)}function yn(t){delete Gt[t.pointerId]}function zr(){vn||(document.addEventListener(fn,Dr,!0),document.addEventListener(pn,Ir,!0),document.addEventListener(mn,yn,!0),document.addEventListener(_n,yn,!0),vn=!0)}function Ee(t,e){if(e.pointerType!==(e.MSPOINTER_TYPE_MOUSE||"mouse")){e.touches=[];for(var i in Gt)e.touches.push(Gt[i]);e.changedTouches=[e],t(e)}}function Or(t,e){e.MSPOINTER_TYPE_TOUCH&&e.pointerType===e.MSPOINTER_TYPE_TOUCH&&ot(e),Ee(t,e)}function Br(t){var e={},i,o;for(o in t)i=t[o],e[o]=i&&i.bind?i.bind(t):i;return t=e,e.type="dblclick",e.detail=2,e.isTrusted=!1,e._simulated=!0,e}var Rr=200;function Ur(t,e){t.addEventListener("dblclick",e);var i=0,o;function l(d){if(d.detail!==1){o=d.detail;return}if(!(d.pointerType==="mouse"||d.sourceCapabilities&&!d.sourceCapabilities.firesTouchEvents)){var p=kn(d);if(!(p.some(function(y){return y instanceof HTMLLabelElement&&y.attributes.for})&&!p.some(function(y){return y instanceof HTMLInputElement||y instanceof HTMLSelectElement}))){var v=Date.now();v-i<=Rr?(o++,o===2&&e(Br(d))):o=1,i=v}}}return t.addEventListener("click",l),{dblclick:e,simDblclick:l}}function Nr(t,e){t.removeEventListener("dblclick",e.dblclick),t.removeEventListener("click",e.simDblclick)}var ci=Te(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),re=Te(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),Ln=re==="webkitTransition"||re==="OTransition"?re+"End":"transitionend";function wn(t){return typeof t=="string"?document.getElementById(t):t}function se(t,e){var i=t.style[e]||t.currentStyle&&t.currentStyle[e];if((!i||i==="auto")&&document.defaultView){var o=document.defaultView.getComputedStyle(t,null);i=o?o[e]:null}return i==="auto"?null:i}function F(t,e,i){var o=document.createElement(t);return o.className=e||"",i&&i.appendChild(o),o}function q(t){var e=t.parentNode;e&&e.removeChild(t)}function Pe(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function Vt(t){var e=t.parentNode;e&&e.lastChild!==t&&e.appendChild(t)}function Wt(t){var e=t.parentNode;e&&e.firstChild!==t&&e.insertBefore(t,e.firstChild)}function di(t,e){if(t.classList!==void 0)return t.classList.contains(e);var i=Ce(t);return i.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(i)}function B(t,e){if(t.classList!==void 0)for(var i=P(e),o=0,l=i.length;o<l;o++)t.classList.add(i[o]);else if(!di(t,e)){var d=Ce(t);ui(t,(d?d+" ":"")+e)}}function X(t,e){t.classList!==void 0?t.classList.remove(e):ui(t,E((" "+Ce(t)+" ").replace(" "+e+" "," ")))}function ui(t,e){t.className.baseVal===void 0?t.className=e:t.className.baseVal=e}function Ce(t){return t.correspondingElement&&(t=t.correspondingElement),t.className.baseVal===void 0?t.className:t.className.baseVal}function mt(t,e){"opacity"in t.style?t.style.opacity=e:"filter"in t.style&&Zr(t,e)}function Zr(t,e){var i=!1,o="DXImageTransform.Microsoft.Alpha";try{i=t.filters.item(o)}catch{if(e===1)return}e=Math.round(e*100),i?(i.Enabled=e!==100,i.Opacity=e):t.style.filter+=" progid:"+o+"(opacity="+e+")"}function Te(t){for(var e=document.documentElement.style,i=0;i<t.length;i++)if(t[i]in e)return t[i];return!1}function Bt(t,e,i){var o=e||new z(0,0);t.style[ci]=(C.ie3d?"translate("+o.x+"px,"+o.y+"px)":"translate3d("+o.x+"px,"+o.y+"px,0)")+(i?" scale("+i+")":"")}function tt(t,e){t._leaflet_pos=e,C.any3d?Bt(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px")}function Rt(t){return t._leaflet_pos||new z(0,0)}var ae,le,fi;if("onselectstart"in document)ae=function(){O(window,"selectstart",ot)},le=function(){W(window,"selectstart",ot)};else{var he=Te(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);ae=function(){if(he){var t=document.documentElement.style;fi=t[he],t[he]="none"}},le=function(){he&&(document.documentElement.style[he]=fi,fi=void 0)}}function pi(){O(window,"dragstart",ot)}function mi(){W(window,"dragstart",ot)}var Se,_i;function gi(t){for(;t.tabIndex===-1;)t=t.parentNode;t.style&&(De(),Se=t,_i=t.style.outlineStyle,t.style.outlineStyle="none",O(window,"keydown",De))}function De(){Se&&(Se.style.outlineStyle=_i,Se=void 0,_i=void 0,W(window,"keydown",De))}function bn(t){do t=t.parentNode;while((!t.offsetWidth||!t.offsetHeight)&&t!==document.body);return t}function vi(t){var e=t.getBoundingClientRect();return{x:e.width/t.offsetWidth||1,y:e.height/t.offsetHeight||1,boundingClientRect:e}}var Hr={__proto__:null,TRANSFORM:ci,TRANSITION:re,TRANSITION_END:Ln,get:wn,getStyle:se,create:F,remove:q,empty:Pe,toFront:Vt,toBack:Wt,hasClass:di,addClass:B,removeClass:X,setClass:ui,getClass:Ce,setOpacity:mt,testProp:Te,setTransform:Bt,setPosition:tt,getPosition:Rt,get disableTextSelection(){return ae},get enableTextSelection(){return le},disableImageDrag:pi,enableImageDrag:mi,preventOutline:gi,restoreOutline:De,getSizedParentNode:bn,getScale:vi};function O(t,e,i,o){if(e&&typeof e=="object")for(var l in e)Li(t,l,e[l],i);else{e=P(e);for(var d=0,p=e.length;d<p;d++)Li(t,e[d],i,o)}return this}var wt="_leaflet_events";function W(t,e,i,o){if(arguments.length===1)xn(t),delete t[wt];else if(e&&typeof e=="object")for(var l in e)wi(t,l,e[l],i);else if(e=P(e),arguments.length===2)xn(t,function(v){return V(e,v)!==-1});else for(var d=0,p=e.length;d<p;d++)wi(t,e[d],i,o);return this}function xn(t,e){for(var i in t[wt]){var o=i.split(/\d/)[0];(!e||e(o))&&wi(t,o,null,null,i)}}var yi={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"};function Li(t,e,i,o){var l=e+f(i)+(o?"_"+f(o):"");if(t[wt]&&t[wt][l])return this;var d=function(v){return i.call(o||t,v||window.event)},p=d;!C.touchNative&&C.pointer&&e.indexOf("touch")===0?d=Tr(t,e,d):C.touch&&e==="dblclick"?d=Ur(t,d):"addEventListener"in t?e==="touchstart"||e==="touchmove"||e==="wheel"||e==="mousewheel"?t.addEventListener(yi[e]||e,d,C.passiveEvents?{passive:!1}:!1):e==="mouseenter"||e==="mouseleave"?(d=function(v){v=v||window.event,xi(t,v)&&p(v)},t.addEventListener(yi[e],d,!1)):t.addEventListener(e,p,!1):t.attachEvent("on"+e,d),t[wt]=t[wt]||{},t[wt][l]=d}function wi(t,e,i,o,l){l=l||e+f(i)+(o?"_"+f(o):"");var d=t[wt]&&t[wt][l];if(!d)return this;!C.touchNative&&C.pointer&&e.indexOf("touch")===0?Sr(t,e,d):C.touch&&e==="dblclick"?Nr(t,d):"removeEventListener"in t?t.removeEventListener(yi[e]||e,d,!1):t.detachEvent("on"+e,d),t[wt][l]=null}function Ut(t){return t.stopPropagation?t.stopPropagation():t.originalEvent?t.originalEvent._stopped=!0:t.cancelBubble=!0,this}function bi(t){return Li(t,"wheel",Ut),this}function ce(t){return O(t,"mousedown touchstart dblclick contextmenu",Ut),t._leaflet_disable_click=!0,this}function ot(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Nt(t){return ot(t),Ut(t),this}function kn(t){if(t.composedPath)return t.composedPath();for(var e=[],i=t.target;i;)e.push(i),i=i.parentNode;return e}function An(t,e){if(!e)return new z(t.clientX,t.clientY);var i=vi(e),o=i.boundingClientRect;return new z((t.clientX-o.left)/i.x-e.clientLeft,(t.clientY-o.top)/i.y-e.clientTop)}var Fr=C.linux&&C.chrome?window.devicePixelRatio:C.mac?window.devicePixelRatio*3:window.devicePixelRatio>0?2*window.devicePixelRatio:1;function Mn(t){return C.edge?t.wheelDeltaY/2:t.deltaY&&t.deltaMode===0?-t.deltaY/Fr:t.deltaY&&t.deltaMode===1?-t.deltaY*20:t.deltaY&&t.deltaMode===2?-t.deltaY*60:t.deltaX||t.deltaZ?0:t.wheelDelta?(t.wheelDeltaY||t.wheelDelta)/2:t.detail&&Math.abs(t.detail)<32765?-t.detail*20:t.detail?t.detail/-32765*60:0}function xi(t,e){var i=e.relatedTarget;if(!i)return!0;try{for(;i&&i!==t;)i=i.parentNode}catch{return!1}return i!==t}var Gr={__proto__:null,on:O,off:W,stopPropagation:Ut,disableScrollPropagation:bi,disableClickPropagation:ce,preventDefault:ot,stop:Nt,getPropagationPath:kn,getMousePosition:An,getWheelDelta:Mn,isExternalTarget:xi,addListener:O,removeListener:W},En=ie.extend({run:function(t,e,i,o){this.stop(),this._el=t,this._inProgress=!0,this._duration=i||.25,this._easeOutPower=1/Math.max(o||.5,.2),this._startPos=Rt(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=rt(this._animate,this),this._step()},_step:function(t){var e=+new Date-this._startTime,i=this._duration*1e3;e<i?this._runFrame(this._easeOut(e/i),t):(this._runFrame(1),this._complete())},_runFrame:function(t,e){var i=this._startPos.add(this._offset.multiplyBy(t));e&&i._round(),tt(this._el,i),this.fire("step")},_complete:function(){at(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(t){return 1-Math.pow(1-t,this._easeOutPower)}}),Z=ie.extend({options:{crs:ni,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=M(this,e),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this._initContainer(t),this._initLayout(),this._onResize=a(this._onResize,this),this._initEvents(),e.maxBounds&&this.setMaxBounds(e.maxBounds),e.zoom!==void 0&&(this._zoom=this._limitZoom(e.zoom)),e.center&&e.zoom!==void 0&&this.setView(N(e.center),e.zoom,{reset:!0}),this.callInitHooks(),this._zoomAnimated=re&&C.any3d&&!C.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),O(this._proxy,Ln,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(t,e,i){if(e=e===void 0?this._zoom:this._limitZoom(e),t=this._limitCenter(N(t),e,this.options.maxBounds),i=i||{},this._stop(),this._loaded&&!i.reset&&i!==!0){i.animate!==void 0&&(i.zoom=n({animate:i.animate},i.zoom),i.pan=n({animate:i.animate,duration:i.duration},i.pan));var o=this._zoom!==e?this._tryAnimatedZoom&&this._tryAnimatedZoom(t,e,i.zoom):this._tryAnimatedPan(t,i.pan);if(o)return clearTimeout(this._sizeTimer),this}return this._resetView(t,e,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||(C.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+t,e)},zoomOut:function(t,e){return t=t||(C.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-t,e)},setZoomAround:function(t,e,i){var o=this.getZoomScale(e),l=this.getSize().divideBy(2),d=t instanceof z?t:this.latLngToContainerPoint(t),p=d.subtract(l).multiplyBy(1-1/o),v=this.containerPointToLatLng(l.add(p));return this.setView(v,e,{zoom:i})},_getBoundsCenterZoom:function(t,e){e=e||{},t=t.getBounds?t.getBounds():$(t);var i=I(e.paddingTopLeft||e.padding||[0,0]),o=I(e.paddingBottomRight||e.padding||[0,0]),l=this.getBoundsZoom(t,!1,i.add(o));if(l=typeof e.maxZoom=="number"?Math.min(e.maxZoom,l):l,l===1/0)return{center:t.getCenter(),zoom:l};var d=o.subtract(i).divideBy(2),p=this.project(t.getSouthWest(),l),v=this.project(t.getNorthEast(),l),y=this.unproject(p.add(v).divideBy(2).add(d),l);return{center:y,zoom:l}},fitBounds:function(t,e){if(t=$(t),!t.isValid())throw new Error("Bounds are not valid.");var i=this._getBoundsCenterZoom(t,e);return this.setView(i.center,i.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(t=I(t).round(),e=e||{},!t.x&&!t.y)return this.fire("moveend");if(e.animate!==!0&&!this.getSize().contains(t))return this._resetView(this.unproject(this.project(this.getCenter()).add(t)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new En,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),e.noMoveStart||this.fire("movestart"),e.animate!==!1){B(this._mapPane,"leaflet-pan-anim");var i=this._getMapPanePos().subtract(t).round();this._panAnim.run(this._mapPane,i,e.duration||.25,e.easeLinearity)}else this._rawPanBy(t),this.fire("move").fire("moveend");return this},flyTo:function(t,e,i){if(i=i||{},i.animate===!1||!C.any3d)return this.setView(t,e,i);this._stop();var o=this.project(this.getCenter()),l=this.project(t),d=this.getSize(),p=this._zoom;t=N(t),e=e===void 0?p:e;var v=Math.max(d.x,d.y),y=v*this.getZoomScale(p,e),b=l.distanceTo(o)||1,A=1.42,S=A*A;function R(et){var Ve=et?-1:1,Ss=et?y:v,Ds=y*y-v*v+Ve*S*S*b*b,Is=2*Ss*S*b,zi=Ds/Is,ao=Math.sqrt(zi*zi+1)-zi,zs=ao<1e-9?-18:Math.log(ao);return zs}function st(et){return(Math.exp(et)-Math.exp(-et))/2}function it(et){return(Math.exp(et)+Math.exp(-et))/2}function gt(et){return st(et)/it(et)}var ct=R(0);function Xt(et){return v*(it(ct)/it(ct+A*et))}function Es(et){return v*(it(ct)*gt(ct+A*et)-st(ct))/S}function Ps(et){return 1-Math.pow(1-et,1.5)}var Cs=Date.now(),ro=(R(1)-ct)/A,Ts=i.duration?1e3*i.duration:1e3*ro*.8;function so(){var et=(Date.now()-Cs)/Ts,Ve=Ps(et)*ro;et<=1?(this._flyToFrame=rt(so,this),this._move(this.unproject(o.add(l.subtract(o).multiplyBy(Es(Ve)/b)),p),this.getScaleZoom(v/Xt(Ve),p),{flyTo:!0})):this._move(t,e)._moveEnd(!0)}return this._moveStart(!0,i.noMoveStart),so.call(this),this},flyToBounds:function(t,e){var i=this._getBoundsCenterZoom(t,e);return this.flyTo(i.center,i.zoom,e)},setMaxBounds:function(t){return 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 i=this.getCenter(),o=this._limitCenter(i,this._zoom,$(t));return i.equals(o)||this.panTo(o,e),this._enforcingBounds=!1,this},panInside:function(t,e){e=e||{};var i=I(e.paddingTopLeft||e.padding||[0,0]),o=I(e.paddingBottomRight||e.padding||[0,0]),l=this.project(this.getCenter()),d=this.project(t),p=this.getPixelBounds(),v=lt([p.min.add(i),p.max.subtract(o)]),y=v.getSize();if(!v.contains(d)){this._enforcingBounds=!0;var b=d.subtract(v.getCenter()),A=v.extend(d).getSize().subtract(y);l.x+=b.x<0?-A.x:A.x,l.y+=b.y<0?-A.y:A.y,this.panTo(this.unproject(l),e),this._enforcingBounds=!1}return this},invalidateSize:function(t){if(!this._loaded)return this;t=n({animate:!1,pan:!0},t===!0?{animate:!0}:t);var e=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var i=this.getSize(),o=e.divideBy(2).round(),l=i.divideBy(2).round(),d=o.subtract(l);return!d.x&&!d.y?this:(t.animate&&t.pan?this.panBy(d):(t.pan&&this._rawPanBy(d),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(a(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:e,newSize:i}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(t){if(t=this._locateOptions=n({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var e=a(this._handleGeolocationResponse,this),i=a(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(e,i,t):navigator.geolocation.getCurrentPosition(e,i,t),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(t){if(this._container._leaflet_id){var e=t.code,i=t.message||(e===1?"permission denied":e===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:e,message:"Geolocation error: "+i+"."})}},_handleGeolocationResponse:function(t){if(this._container._leaflet_id){var e=t.coords.latitude,i=t.coords.longitude,o=new G(e,i),l=o.toBounds(t.coords.accuracy*2),d=this._locateOptions;if(d.setView){var p=this.getBoundsZoom(l);this.setView(o,d.maxZoom?Math.min(p,d.maxZoom):p)}var v={latlng:o,bounds:l,timestamp:t.timestamp};for(var y in t.coords)typeof t.coords[y]=="number"&&(v[y]=t.coords[y]);this.fire("locationfound",v)}},addHandler:function(t,e){if(!e)return this;var i=this[t]=new e(this);return this._handlers.push(i),this.options[t]&&i.enable(),this},remove:function(){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{this._container._leaflet_id=void 0,this._containerId=void 0}this._locationWatchId!==void 0&&this.stopLocate(),this._stop(),q(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(at(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var t;for(t in this._layers)this._layers[t].remove();for(t in this._panes)q(this._panes[t]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,e){var i="leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),o=F("div",i,e||this._mapPane);return t&&(this._panes[t]=o),o},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var t=this.getPixelBounds(),e=this.unproject(t.getBottomLeft()),i=this.unproject(t.getTopRight());return new ht(e,i)},getMinZoom:function(){return this.options.minZoom===void 0?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return this.options.maxZoom===void 0?this._layersMaxZoom===void 0?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(t,e,i){t=$(t),i=I(i||[0,0]);var o=this.getZoom()||0,l=this.getMinZoom(),d=this.getMaxZoom(),p=t.getNorthWest(),v=t.getSouthEast(),y=this.getSize().subtract(i),b=lt(this.project(v,o),this.project(p,o)).getSize(),A=C.any3d?this.options.zoomSnap:1,S=y.x/b.x,R=y.y/b.y,st=e?Math.max(S,R):Math.min(S,R);return o=this.getScaleZoom(st,o),A&&(o=Math.round(o/(A/100))*(A/100),o=e?Math.ceil(o/A)*A:Math.floor(o/A)*A),Math.max(l,Math.min(d,o))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new z(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,e){var i=this._getTopLeftPoint(t,e);return new Y(i,i.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(t){return this.options.crs.getProjectedBounds(t===void 0?this.getZoom():t)},getPane:function(t){return typeof t=="string"?this._panes[t]:t},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(t,e){var i=this.options.crs;return e=e===void 0?this._zoom:e,i.scale(t)/i.scale(e)},getScaleZoom:function(t,e){var i=this.options.crs;e=e===void 0?this._zoom:e;var o=i.zoom(t*i.scale(e));return isNaN(o)?1/0:o},project:function(t,e){return e=e===void 0?this._zoom:e,this.options.crs.latLngToPoint(N(t),e)},unproject:function(t,e){return e=e===void 0?this._zoom:e,this.options.crs.pointToLatLng(I(t),e)},layerPointToLatLng:function(t){var e=I(t).add(this.getPixelOrigin());return this.unproject(e)},latLngToLayerPoint:function(t){var e=this.project(N(t))._round();return e._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(N(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds($(t))},distance:function(t,e){return this.options.crs.distance(N(t),N(e))},containerPointToLayerPoint:function(t){return I(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return I(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(I(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(N(t)))},mouseEventToContainerPoint:function(t){return An(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=wn(t);if(e){if(e._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");O(e,"scroll",this._onScroll,this),this._containerId=f(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&C.any3d,B(t,"leaflet-container"+(C.touch?" leaflet-touch":"")+(C.retina?" leaflet-retina":"")+(C.ielt9?" leaflet-oldie":"")+(C.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var e=se(t,"position");e!=="absolute"&&e!=="relative"&&e!=="fixed"&&e!=="sticky"&&(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),tt(this._mapPane,new z(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(B(t.markerPane,"leaflet-zoom-hide"),B(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e,i){tt(this._mapPane,new z(0,0));var o=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var l=this._zoom!==e;this._moveStart(l,i)._move(t,e)._moveEnd(l),this.fire("viewreset"),o&&this.fire("load")},_moveStart:function(t,e){return t&&this.fire("zoomstart"),e||this.fire("movestart"),this},_move:function(t,e,i,o){e===void 0&&(e=this._zoom);var l=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),o?i&&i.pinch&&this.fire("zoom",i):((l||i&&i.pinch)&&this.fire("zoom",i),this.fire("move",i)),this},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return at(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){tt(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[f(this._container)]=this;var e=t?W:O;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),C.any3d&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){at(this._resizeRequest),this._resizeRequest=rt(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var t=this._getMapPanePos();Math.max(Math.abs(t.x),Math.abs(t.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(t,e){for(var i=[],o,l=e==="mouseout"||e==="mouseover",d=t.target||t.srcElement,p=!1;d;){if(o=this._targets[f(d)],o&&(e==="click"||e==="preclick")&&this._draggableMoved(o)){p=!0;break}if(o&&o.listens(e,!0)&&(l&&!xi(d,t)||(i.push(o),l))||d===this._container)break;d=d.parentNode}return!i.length&&!p&&!l&&this.listens(e,!0)&&(i=[this]),i},_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||t.type==="click"&&this._isClickDisabled(e))){var i=t.type;i==="mousedown"&&gi(e),this._fireDOMEvent(t,i)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,e,i){if(t.type==="click"){var o=n({},t);o.type="preclick",this._fireDOMEvent(o,o.type,i)}var l=this._findEventTargets(t,e);if(i){for(var d=[],p=0;p<i.length;p++)i[p].listens(e,!0)&&d.push(i[p]);l=d.concat(l)}if(l.length){e==="contextmenu"&&ot(t);var v=l[0],y={originalEvent:t};if(t.type!=="keypress"&&t.type!=="keydown"&&t.type!=="keyup"){var b=v.getLatLng&&(!v._radius||v._radius<=10);y.containerPoint=b?this.latLngToContainerPoint(v.getLatLng()):this.mouseEventToContainerPoint(t),y.layerPoint=this.containerPointToLayerPoint(y.containerPoint),y.latlng=b?v.getLatLng():this.layerPointToLatLng(y.layerPoint)}for(p=0;p<l.length;p++)if(l[p].fire(e,y,!0),y.originalEvent._stopped||l[p].options.bubblingMouseEvents===!1&&V(this._mouseEvents,e)!==-1)return}},_draggableMoved:function(t){return t=t.dragging&&t.dragging.enabled()?t:this,t.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 Rt(this._mapPane)||new z(0,0)},_moved:function(){var t=this._getMapPanePos();return t&&!t.equals([0,0])},_getTopLeftPoint:function(t,e){var i=t&&e!==void 0?this._getNewPixelOrigin(t,e):this.getPixelOrigin();return i.subtract(this._getMapPanePos())},_getNewPixelOrigin:function(t,e){var i=this.getSize()._divideBy(2);return this.project(t,e)._subtract(i)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(t,e,i){var o=this._getNewPixelOrigin(i,e);return this.project(t,e)._subtract(o)},_latLngBoundsToNewLayerBounds:function(t,e,i){var o=this._getNewPixelOrigin(i,e);return lt([this.project(t.getSouthWest(),e)._subtract(o),this.project(t.getNorthWest(),e)._subtract(o),this.project(t.getSouthEast(),e)._subtract(o),this.project(t.getNorthEast(),e)._subtract(o)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(t){return this.latLngToLayerPoint(t).subtract(this._getCenterLayerPoint())},_limitCenter:function(t,e,i){if(!i)return t;var o=this.project(t,e),l=this.getSize().divideBy(2),d=new Y(o.subtract(l),o.add(l)),p=this._getBoundsOffset(d,i,e);return Math.abs(p.x)<=1&&Math.abs(p.y)<=1?t:this.unproject(o.add(p),e)},_limitOffset:function(t,e){if(!e)return t;var i=this.getPixelBounds(),o=new Y(i.min.add(t),i.max.add(t));return t.add(this._getBoundsOffset(o,e))},_getBoundsOffset:function(t,e,i){var o=lt(this.project(e.getNorthEast(),i),this.project(e.getSouthWest(),i)),l=o.min.subtract(t.min),d=o.max.subtract(t.max),p=this._rebound(l.x,-d.x),v=this._rebound(l.y,-d.y);return new z(p,v)},_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(),i=this.getMaxZoom(),o=C.any3d?this.options.zoomSnap:1;return o&&(t=Math.round(t/o)*o),Math.max(e,Math.min(i,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){X(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,e){var i=this._getCenterOffset(t)._trunc();return(e&&e.animate)!==!0&&!this.getSize().contains(i)?!1:(this.panBy(i,e),!0)},_createAnimProxy:function(){var t=this._proxy=F("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(e){var i=ci,o=this._proxy.style[i];Bt(this._proxy,this.project(e.center,e.zoom),this.getZoomScale(e.zoom,1)),o===this._proxy.style[i]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){q(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var t=this.getCenter(),e=this.getZoom();Bt(this._proxy,this.project(t,e),this.getZoomScale(e,1))},_catchTransitionEnd:function(t){this._animatingZoom&&t.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(t,e,i){if(this._animatingZoom)return!0;if(i=i||{},!this._zoomAnimated||i.animate===!1||this._nothingToAnimate()||Math.abs(e-this._zoom)>this.options.zoomAnimationThreshold)return!1;var o=this.getZoomScale(e),l=this._getCenterOffset(t)._divideBy(1-1/o);return i.animate!==!0&&!this.getSize().contains(l)?!1:(rt(function(){this._moveStart(!0,i.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,B(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(a(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&X(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom,void 0,!0),this._tempFireZoomEvent&&this.fire("zoom"),delete this._tempFireZoomEvent,this.fire("move"),this._moveEnd(!0))}});function Vr(t,e){return new Z(t,e)}var vt=pt.extend({options:{position:"topright"},initialize:function(t){M(this,t)},getPosition:function(){return this.options.position},setPosition:function(t){var e=this._map;return e&&e.removeControl(this),this.options.position=t,e&&e.addControl(this),this},getContainer:function(){return this._container},addTo:function(t){this.remove(),this._map=t;var e=this._container=this.onAdd(t),i=this.getPosition(),o=t._controlCorners[i];return B(e,"leaflet-control"),i.indexOf("bottom")!==-1?o.insertBefore(e,o.firstChild):o.appendChild(e),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(q(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()}}),de=function(t){return new vt(t)};Z.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){var t=this._controlCorners={},e="leaflet-",i=this._controlContainer=F("div",e+"control-container",this._container);function o(l,d){var p=e+l+" "+e+d;t[l+d]=F("div",p,i)}o("top","left"),o("top","right"),o("bottom","left"),o("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)q(this._controlCorners[t]);q(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var Pn=vt.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,e,i,o){return i<o?-1:o<i?1:0}},initialize:function(t,e,i){M(this,i),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1,this._preventClick=!1;for(var o in t)this._addLayer(t[o],o);for(o in e)this._addLayer(e[o],o,!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 vt.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(f(t));return e&&this._layers.splice(this._layers.indexOf(e),1),this._map?this._update():this},expand:function(){B(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?(B(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=t+"px"):X(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return X(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var t="leaflet-control-layers",e=this._container=F("div",t),i=this.options.collapsed;e.setAttribute("aria-haspopup",!0),ce(e),bi(e);var o=this._section=F("section",t+"-list");i&&(this._map.on("click",this.collapse,this),O(e,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var l=this._layersLink=F("a",t+"-toggle",e);l.href="#",l.title="Layers",l.setAttribute("role","button"),O(l,{keydown:function(d){d.keyCode===13&&this._expandSafely()},click:function(d){ot(d),this._expandSafely()}},this),i||this.expand(),this._baseLayersList=F("div",t+"-base",o),this._separator=F("div",t+"-separator",o),this._overlaysList=F("div",t+"-overlays",o),e.appendChild(o)},_getLayer:function(t){for(var e=0;e<this._layers.length;e++)if(this._layers[e]&&f(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(a(function(o,l){return this.options.sortFunction(o.layer,l.layer,o.name,l.name)},this)),this.options.autoZIndex&&t.setZIndex&&(this._lastZIndex++,t.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Pe(this._baseLayersList),Pe(this._overlaysList),this._layerControlInputs=[];var t,e,i,o,l=0;for(i=0;i<this._layers.length;i++)o=this._layers[i],this._addItem(o),e=e||o.overlay,t=t||!o.overlay,l+=o.overlay?0:1;return this.options.hideSingleBase&&(t=t&&l>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(f(t.target)),i=e.overlay?t.type==="add"?"overlayadd":"overlayremove":t.type==="add"?"baselayerchange":null;i&&this._map.fire(i,e)},_createRadioElement:function(t,e){var i='<input type="radio" class="leaflet-control-layers-selector" name="'+t+'"'+(e?' checked="checked"':"")+"/>",o=document.createElement("div");return o.innerHTML=i,o.firstChild},_addItem:function(t){var e=document.createElement("label"),i=this._map.hasLayer(t.layer),o;t.overlay?(o=document.createElement("input"),o.type="checkbox",o.className="leaflet-control-layers-selector",o.defaultChecked=i):o=this._createRadioElement("leaflet-base-layers_"+f(this),i),this._layerControlInputs.push(o),o.layerId=f(t.layer),O(o,"click",this._onInputClick,this);var l=document.createElement("span");l.innerHTML=" "+t.name;var d=document.createElement("span");e.appendChild(d),d.appendChild(o),d.appendChild(l);var p=t.overlay?this._overlaysList:this._baseLayersList;return p.appendChild(e),this._checkDisabledLayers(),e},_onInputClick:function(){if(!this._preventClick){var t=this._layerControlInputs,e,i,o=[],l=[];this._handlingClick=!0;for(var d=t.length-1;d>=0;d--)e=t[d],i=this._getLayer(e.layerId).layer,e.checked?o.push(i):e.checked||l.push(i);for(d=0;d<l.length;d++)this._map.hasLayer(l[d])&&this._map.removeLayer(l[d]);for(d=0;d<o.length;d++)this._map.hasLayer(o[d])||this._map.addLayer(o[d]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var t=this._layerControlInputs,e,i,o=this._map.getZoom(),l=t.length-1;l>=0;l--)e=t[l],i=this._getLayer(e.layerId).layer,e.disabled=i.options.minZoom!==void 0&&o<i.options.minZoom||i.options.maxZoom!==void 0&&o>i.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var t=this._section;this._preventClick=!0,O(t,"click",ot),this.expand();var e=this;setTimeout(function(){W(t,"click",ot),e._preventClick=!1})}}),Wr=function(t,e,i){return new Pn(t,e,i)},ki=vt.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",i=F("div",e+" leaflet-bar"),o=this.options;return this._zoomInButton=this._createButton(o.zoomInText,o.zoomInTitle,e+"-in",i,this._zoomIn),this._zoomOutButton=this._createButton(o.zoomOutText,o.zoomOutTitle,e+"-out",i,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),i},onRemove:function(t){t.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(t){!this._disabled&&this._map._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,i,o,l){var d=F("a",i,o);return d.innerHTML=t,d.href="#",d.title=e,d.setAttribute("role","button"),d.setAttribute("aria-label",e),ce(d),O(d,"click",Nt),O(d,"click",l,this),O(d,"click",this._refocusOnMap,this),d},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";X(this._zoomInButton,e),X(this._zoomOutButton,e),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||t._zoom===t.getMinZoom())&&(B(this._zoomOutButton,e),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||t._zoom===t.getMaxZoom())&&(B(this._zoomInButton,e),this._zoomInButton.setAttribute("aria-disabled","true"))}});Z.mergeOptions({zoomControl:!0}),Z.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new ki,this.addControl(this.zoomControl))});var Yr=function(t){return new ki(t)},Cn=vt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",i=F("div",e),o=this.options;return this._addScales(o,e+"-line",i),t.on(o.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),i},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,e,i){t.metric&&(this._mScale=F("div",e,i)),t.imperial&&(this._iScale=F("div",e,i))},_update:function(){var t=this._map,e=t.getSize().y/2,i=t.distance(t.containerPointToLatLng([0,e]),t.containerPointToLatLng([this.options.maxWidth,e]));this._updateScales(i)},_updateScales:function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},_updateMetric:function(t){var e=this._getRoundNum(t),i=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,i,e/t)},_updateImperial:function(t){var e=t*3.2808399,i,o,l;e>5280?(i=e/5280,o=this._getRoundNum(i),this._updateScale(this._iScale,o+" mi",o/i)):(l=this._getRoundNum(e),this._updateScale(this._iScale,l+" ft",l/e))},_updateScale:function(t,e,i){t.style.width=Math.round(this.options.maxWidth*i)+"px",t.innerHTML=e},_getRoundNum:function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),i=t/e;return i=i>=10?10:i>=5?5:i>=3?3:i>=2?2:1,e*i}}),qr=function(t){return new Cn(t)},jr='<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>',Ai=vt.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(C.inlineSvg?jr+" ":"")+"Leaflet</a>"},initialize:function(t){M(this,t),this._attributions={}},onAdd:function(t){t.attributionControl=this,this._container=F("div","leaflet-control-attribution"),ce(this._container);for(var e in 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 i=[];this.options.prefix&&i.push(this.options.prefix),t.length&&i.push(t.join(", ")),this._container.innerHTML=i.join(' <span aria-hidden="true">|</span> ')}}});Z.mergeOptions({attributionControl:!0}),Z.addInitHook(function(){this.options.attributionControl&&new Ai().addTo(this)});var Jr=function(t){return new Ai(t)};vt.Layers=Pn,vt.Zoom=ki,vt.Scale=Cn,vt.Attribution=Ai,de.layers=Wr,de.zoom=Yr,de.scale=qr,de.attribution=Jr;var bt=pt.extend({initialize:function(t){this._map=t},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});bt.addTo=function(t,e){return t.addHandler(e,this),this};var Kr={Events:ft},Tn=C.touch?"touchstart mousedown":"mousedown",Dt=ie.extend({options:{clickTolerance:3},initialize:function(t,e,i,o){M(this,o),this._element=t,this._dragStartTarget=e||t,this._preventOutline=i},enable:function(){this._enabled||(O(this._dragStartTarget,Tn,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(Dt._dragging===this&&this.finishDrag(!0),W(this._dragStartTarget,Tn,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(this._enabled&&(this._moved=!1,!di(this._element,"leaflet-zoom-anim"))){if(t.touches&&t.touches.length!==1){Dt._dragging===this&&this.finishDrag();return}if(!(Dt._dragging||t.shiftKey||t.which!==1&&t.button!==1&&!t.touches)&&(Dt._dragging=this,this._preventOutline&&gi(this._element),pi(),ae(),!this._moving)){this.fire("down");var e=t.touches?t.touches[0]:t,i=bn(this._element);this._startPoint=new z(e.clientX,e.clientY),this._startPos=Rt(this._element),this._parentScale=vi(i);var o=t.type==="mousedown";O(document,o?"mousemove":"touchmove",this._onMove,this),O(document,o?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(t){if(this._enabled){if(t.touches&&t.touches.length>1){this._moved=!0;return}var e=t.touches&&t.touches.length===1?t.touches[0]:t,i=new z(e.clientX,e.clientY)._subtract(this._startPoint);!i.x&&!i.y||Math.abs(i.x)+Math.abs(i.y)<this.options.clickTolerance||(i.x/=this._parentScale.x,i.y/=this._parentScale.y,ot(t),this._moved||(this.fire("dragstart"),this._moved=!0,B(document.body,"leaflet-dragging"),this._lastTarget=t.target||t.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),B(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(i),this._moving=!0,this._lastEvent=t,this._updatePosition())}},_updatePosition:function(){var t={originalEvent:this._lastEvent};this.fire("predrag",t),tt(this._element,this._newPos),this.fire("drag",t)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(t){X(document.body,"leaflet-dragging"),this._lastTarget&&(X(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),W(document,"mousemove touchmove",this._onMove,this),W(document,"mouseup touchend touchcancel",this._onUp,this),mi(),le();var e=this._moved&&this._moving;this._moving=!1,Dt._dragging=!1,e&&this.fire("dragend",{noInertia:t,distance:this._newPos.distanceTo(this._startPos)})}});function Sn(t,e,i){var o,l=[1,4,2,8],d,p,v,y,b,A,S,R;for(d=0,A=t.length;d<A;d++)t[d]._code=Zt(t[d],e);for(v=0;v<4;v++){for(S=l[v],o=[],d=0,A=t.length,p=A-1;d<A;p=d++)y=t[d],b=t[p],y._code&S?b._code&S||(R=Ie(b,y,S,e,i),R._code=Zt(R,e),o.push(R)):(b._code&S&&(R=Ie(b,y,S,e,i),R._code=Zt(R,e),o.push(R)),o.push(y));t=o}return t}function Dn(t,e){var i,o,l,d,p,v,y,b,A;if(!t||t.length===0)throw new Error("latlngs not passed");_t(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var S=N([0,0]),R=$(t),st=R.getNorthWest().distanceTo(R.getSouthWest())*R.getNorthEast().distanceTo(R.getNorthWest());st<1700&&(S=Mi(t));var it=t.length,gt=[];for(i=0;i<it;i++){var ct=N(t[i]);gt.push(e.project(N([ct.lat-S.lat,ct.lng-S.lng])))}for(v=y=b=0,i=0,o=it-1;i<it;o=i++)l=gt[i],d=gt[o],p=l.y*d.x-d.y*l.x,y+=(l.x+d.x)*p,b+=(l.y+d.y)*p,v+=p*3;v===0?A=gt[0]:A=[y/v,b/v];var Xt=e.unproject(I(A));return N([Xt.lat+S.lat,Xt.lng+S.lng])}function Mi(t){for(var e=0,i=0,o=0,l=0;l<t.length;l++){var d=N(t[l]);e+=d.lat,i+=d.lng,o++}return N([e/o,i/o])}var Xr={__proto__:null,clipPolygon:Sn,polygonCenter:Dn,centroid:Mi};function In(t,e){if(!e||!t.length)return t.slice();var i=e*e;return t=ts(t,i),t=$r(t,i),t}function zn(t,e,i){return Math.sqrt(ue(t,e,i,!0))}function Qr(t,e,i){return ue(t,e,i)}function $r(t,e){var i=t.length,o=typeof Uint8Array!="undefined"?Uint8Array:Array,l=new o(i);l[0]=l[i-1]=1,Ei(t,l,e,0,i-1);var d,p=[];for(d=0;d<i;d++)l[d]&&p.push(t[d]);return p}function Ei(t,e,i,o,l){var d=0,p,v,y;for(v=o+1;v<=l-1;v++)y=ue(t[v],t[o],t[l],!0),y>d&&(p=v,d=y);d>i&&(e[p]=1,Ei(t,e,i,o,p),Ei(t,e,i,p,l))}function ts(t,e){for(var i=[t[0]],o=1,l=0,d=t.length;o<d;o++)es(t[o],t[l])>e&&(i.push(t[o]),l=o);return l<d-1&&i.push(t[d-1]),i}var On;function Bn(t,e,i,o,l){var d=o?On:Zt(t,i),p=Zt(e,i),v,y,b;for(On=p;;){if(!(d|p))return[t,e];if(d&p)return!1;v=d||p,y=Ie(t,e,v,i,l),b=Zt(y,i),v===d?(t=y,d=b):(e=y,p=b)}}function Ie(t,e,i,o,l){var d=e.x-t.x,p=e.y-t.y,v=o.min,y=o.max,b,A;return i&8?(b=t.x+d*(y.y-t.y)/p,A=y.y):i&4?(b=t.x+d*(v.y-t.y)/p,A=v.y):i&2?(b=y.x,A=t.y+p*(y.x-t.x)/d):i&1&&(b=v.x,A=t.y+p*(v.x-t.x)/d),new z(b,A,l)}function Zt(t,e){var i=0;return t.x<e.min.x?i|=1:t.x>e.max.x&&(i|=2),t.y<e.min.y?i|=4:t.y>e.max.y&&(i|=8),i}function es(t,e){var i=e.x-t.x,o=e.y-t.y;return i*i+o*o}function ue(t,e,i,o){var l=e.x,d=e.y,p=i.x-l,v=i.y-d,y=p*p+v*v,b;return y>0&&(b=((t.x-l)*p+(t.y-d)*v)/y,b>1?(l=i.x,d=i.y):b>0&&(l+=p*b,d+=v*b)),p=t.x-l,v=t.y-d,o?p*p+v*v:new z(l,d)}function _t(t){return!D(t[0])||typeof t[0][0]!="object"&&typeof t[0][0]!="undefined"}function Rn(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),_t(t)}function Un(t,e){var i,o,l,d,p,v,y,b;if(!t||t.length===0)throw new Error("latlngs not passed");_t(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var A=N([0,0]),S=$(t),R=S.getNorthWest().distanceTo(S.getSouthWest())*S.getNorthEast().distanceTo(S.getNorthWest());R<1700&&(A=Mi(t));var st=t.length,it=[];for(i=0;i<st;i++){var gt=N(t[i]);it.push(e.project(N([gt.lat-A.lat,gt.lng-A.lng])))}for(i=0,o=0;i<st-1;i++)o+=it[i].distanceTo(it[i+1])/2;if(o===0)b=it[0];else for(i=0,d=0;i<st-1;i++)if(p=it[i],v=it[i+1],l=p.distanceTo(v),d+=l,d>o){y=(d-o)/l,b=[v.x-y*(v.x-p.x),v.y-y*(v.y-p.y)];break}var ct=e.unproject(I(b));return N([ct.lat+A.lat,ct.lng+A.lng])}var is={__proto__:null,simplify:In,pointToSegmentDistance:zn,closestPointOnSegment:Qr,clipSegment:Bn,_getEdgeIntersection:Ie,_getBitCode:Zt,_sqClosestPointOnSegment:ue,isFlat:_t,_flat:Rn,polylineCenter:Un},Pi={project:function(t){return new z(t.lng,t.lat)},unproject:function(t){return new G(t.y,t.x)},bounds:new Y([-180,-90],[180,90])},Ci={R:6378137,R_MINOR:6356752314245179e-9,bounds:new Y([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(t){var e=Math.PI/180,i=this.R,o=t.lat*e,l=this.R_MINOR/i,d=Math.sqrt(1-l*l),p=d*Math.sin(o),v=Math.tan(Math.PI/4-o/2)/Math.pow((1-p)/(1+p),d/2);return o=-i*Math.log(Math.max(v,1e-10)),new z(t.lng*e*i,o)},unproject:function(t){for(var e=180/Math.PI,i=this.R,o=this.R_MINOR/i,l=Math.sqrt(1-o*o),d=Math.exp(-t.y/i),p=Math.PI/2-2*Math.atan(d),v=0,y=.1,b;v<15&&Math.abs(y)>1e-7;v++)b=l*Math.sin(p),b=Math.pow((1-b)/(1+b),l/2),y=Math.PI/2-2*Math.atan(d*b)-p,p+=y;return new G(p*e,t.x*e/i)}},ns={__proto__:null,LonLat:Pi,Mercator:Ci,SphericalMercator:ei},os=n({},St,{code:"EPSG:3395",projection:Ci,transformation:(function(){var t=.5/(Math.PI*Ci.R);return ne(t,.5,-t,.5)})()}),Nn=n({},St,{code:"EPSG:4326",projection:Pi,transformation:ne(1/180,1,-1/180,.5)}),rs=n({},At,{projection:Pi,transformation:ne(1,0,-1,0),scale:function(t){return Math.pow(2,t)},zoom:function(t){return Math.log(t)/Math.LN2},distance:function(t,e){var i=e.lng-t.lng,o=e.lat-t.lat;return Math.sqrt(i*i+o*o)},infinite:!0});At.Earth=St,At.EPSG3395=os,At.EPSG3857=ni,At.EPSG900913=dr,At.EPSG4326=Nn,At.Simple=rs;var yt=ie.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(t){return t.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(t){return t&&t.removeLayer(this),this},getPane:function(t){return this._map.getPane(t?this.options[t]||t:this.options.pane)},addInteractiveTarget:function(t){return this._map._targets[f(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[f(t)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(t){var e=t.target;if(e.hasLayer(this)){if(this._map=e,this._zoomAnimated=e._zoomAnimated,this.getEvents){var i=this.getEvents();e.on(i,this),this.once("remove",function(){e.off(i,this)},this)}this.onAdd(e),this.fire("add"),e.fire("layeradd",{layer:this})}}});Z.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var e=f(t);return this._layers[e]?this:(this._layers[e]=t,t._mapToAdd=this,t.beforeAdd&&t.beforeAdd(this),this.whenReady(t._layerAdd,t),this)},removeLayer:function(t){var e=f(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 f(t)in this._layers},eachLayer:function(t,e){for(var i in this._layers)t.call(e,this._layers[i]);return this},_addLayers:function(t){t=t?D(t)?t:[t]:[];for(var e=0,i=t.length;e<i;e++)this.addLayer(t[e])},_addZoomLimit:function(t){(!isNaN(t.options.maxZoom)||!isNaN(t.options.minZoom))&&(this._zoomBoundLayers[f(t)]=t,this._updateZoomLevels())},_removeZoomLimit:function(t){var e=f(t);this._zoomBoundLayers[e]&&(delete this._zoomBoundLayers[e],this._updateZoomLevels())},_updateZoomLevels:function(){var t=1/0,e=-1/0,i=this._getZoomSpan();for(var o in this._zoomBoundLayers){var l=this._zoomBoundLayers[o].options;t=l.minZoom===void 0?t:Math.min(t,l.minZoom),e=l.maxZoom===void 0?e:Math.max(e,l.maxZoom)}this._layersMaxZoom=e===-1/0?void 0:e,this._layersMinZoom=t===1/0?void 0:t,i!==this._getZoomSpan()&&this.fire("zoomlevelschange"),this.options.maxZoom===void 0&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var Yt=yt.extend({initialize:function(t,e){M(this,e),this._layers={};var i,o;if(t)for(i=0,o=t.length;i<o;i++)this.addLayer(t[i])},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){var e=typeof t=="number"?t:this.getLayerId(t);return e in this._layers},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(t){var e=Array.prototype.slice.call(arguments,1),i,o;for(i in this._layers)o=this._layers[i],o[t]&&o[t].apply(o,e);return this},onAdd:function(t){this.eachLayer(t.addLayer,t)},onRemove:function(t){this.eachLayer(t.removeLayer,t)},eachLayer:function(t,e){for(var i in this._layers)t.call(e,this._layers[i]);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 f(t)}}),ss=function(t,e){return new Yt(t,e)},Mt=Yt.extend({addLayer:function(t){return this.hasLayer(t)?this:(t.addEventParent(this),Yt.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),Yt.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 ht;for(var e in this._layers){var i=this._layers[e];t.extend(i.getBounds?i.getBounds():i.getLatLng())}return t}}),as=function(t,e){return new Mt(t,e)},qt=pt.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0],crossOrigin:!1},initialize:function(t){M(this,t)},createIcon:function(t){return this._createIcon("icon",t)},createShadow:function(t){return this._createIcon("shadow",t)},_createIcon:function(t,e){var i=this._getIconUrl(t);if(!i){if(t==="icon")throw new Error("iconUrl not set in Icon options (see the docs).");return null}var o=this._createImg(i,e&&e.tagName==="IMG"?e:null);return this._setIconStyles(o,t),(this.options.crossOrigin||this.options.crossOrigin==="")&&(o.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),o},_setIconStyles:function(t,e){var i=this.options,o=i[e+"Size"];typeof o=="number"&&(o=[o,o]);var l=I(o),d=I(e==="shadow"&&i.shadowAnchor||i.iconAnchor||l&&l.divideBy(2,!0));t.className="leaflet-marker-"+e+" "+(i.className||""),d&&(t.style.marginLeft=-d.x+"px",t.style.marginTop=-d.y+"px"),l&&(t.style.width=l.x+"px",t.style.height=l.y+"px")},_createImg:function(t,e){return e=e||document.createElement("img"),e.src=t,e},_getIconUrl:function(t){return C.retina&&this.options[t+"RetinaUrl"]||this.options[t+"Url"]}});function ls(t){return new qt(t)}var fe=qt.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 typeof fe.imagePath!="string"&&(fe.imagePath=this._detectIconPath()),(this.options.imagePath||fe.imagePath)+qt.prototype._getIconUrl.call(this,t)},_stripUrl:function(t){var e=function(i,o,l){var d=o.exec(i);return d&&d[l]};return t=e(t,/^url\((['"])?(.+)\1\)$/,2),t&&e(t,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var t=F("div","leaflet-default-icon-path",document.body),e=se(t,"background-image")||se(t,"backgroundImage");if(document.body.removeChild(t),e=this._stripUrl(e),e)return e;var i=document.querySelector('link[href$="leaflet.css"]');return i?i.href.substring(0,i.href.length-11-1):""}}),Zn=bt.extend({initialize:function(t){this._marker=t},addHooks:function(){var t=this._marker._icon;this._draggable||(this._draggable=new Dt(t,t,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),B(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&&X(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(t){var e=this._marker,i=e._map,o=this._marker.options.autoPanSpeed,l=this._marker.options.autoPanPadding,d=Rt(e._icon),p=i.getPixelBounds(),v=i.getPixelOrigin(),y=lt(p.min._subtract(v).add(l),p.max._subtract(v).subtract(l));if(!y.contains(d)){var b=I((Math.max(y.max.x,d.x)-y.max.x)/(p.max.x-y.max.x)-(Math.min(y.min.x,d.x)-y.min.x)/(p.min.x-y.min.x),(Math.max(y.max.y,d.y)-y.max.y)/(p.max.y-y.max.y)-(Math.min(y.min.y,d.y)-y.min.y)/(p.min.y-y.min.y)).multiplyBy(o);i.panBy(b,{animate:!1}),this._draggable._newPos._add(b),this._draggable._startPos._add(b),tt(e._icon,this._draggable._newPos),this._onDrag(t),this._panRequest=rt(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&&(at(this._panRequest),this._panRequest=rt(this._adjustPan.bind(this,t)))},_onDrag:function(t){var e=this._marker,i=e._shadow,o=Rt(e._icon),l=e._map.layerPointToLatLng(o);i&&tt(i,o),e._latlng=l,t.latlng=l,t.oldLatLng=this._oldLatLng,e.fire("move",t).fire("drag",t)},_onDragEnd:function(t){at(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",t)}}),ze=yt.extend({options:{icon:new fe,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){M(this,e),this._latlng=N(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=N(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"),i=t.icon.createIcon(this._icon),o=!1;i!==this._icon&&(this._icon&&this._removeIcon(),o=!0,t.title&&(i.title=t.title),i.tagName==="IMG"&&(i.alt=t.alt||"")),B(i,e),t.keyboard&&(i.tabIndex="0",i.setAttribute("role","button")),this._icon=i,t.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&O(i,"focus",this._panOnFocus,this);var l=t.icon.createShadow(this._shadow),d=!1;l!==this._shadow&&(this._removeShadow(),d=!0),l&&(B(l,e),l.alt=""),this._shadow=l,t.opacity<1&&this._updateOpacity(),o&&this.getPane().appendChild(this._icon),this._initInteraction(),l&&d&&this.getPane(t.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&W(this._icon,"focus",this._panOnFocus,this),q(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&q(this._shadow),this._shadow=null},_setPos:function(t){this._icon&&tt(this._icon,t),this._shadow&&tt(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&&(B(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),Zn)){var t=this.options.draggable;this.dragging&&(t=this.dragging.enabled(),this.dragging.disable()),this.dragging=new Zn(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&&mt(this._icon,t),this._shadow&&mt(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,i=e.iconSize?I(e.iconSize):I(0,0),o=e.iconAnchor?I(e.iconAnchor):I(0,0);t.panInside(this._latlng,{paddingTopLeft:o,paddingBottomRight:i.subtract(o)})}},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}});function hs(t,e){return new ze(t,e)}var It=yt.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 M(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)}}),Oe=It.extend({options:{fill:!0,radius:10},initialize:function(t,e){M(this,e),this._latlng=N(t),this._radius=this.options.radius},setLatLng:function(t){var e=this._latlng;return this._latlng=N(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 It.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,i=this._clickTolerance(),o=[t+i,e+i];this._pxBounds=new Y(this._point.subtract(o),this._point.add(o))},_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()}});function cs(t,e){return new Oe(t,e)}var Ti=Oe.extend({initialize:function(t,e,i){if(typeof e=="number"&&(e=n({},i,{radius:e})),M(this,e),this._latlng=N(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 ht(this._map.layerPointToLatLng(this._point.subtract(t)),this._map.layerPointToLatLng(this._point.add(t)))},setStyle:It.prototype.setStyle,_project:function(){var t=this._latlng.lng,e=this._latlng.lat,i=this._map,o=i.options.crs;if(o.distance===St.distance){var l=Math.PI/180,d=this._mRadius/St.R/l,p=i.project([e+d,t]),v=i.project([e-d,t]),y=p.add(v).divideBy(2),b=i.unproject(y).lat,A=Math.acos((Math.cos(d*l)-Math.sin(e*l)*Math.sin(b*l))/(Math.cos(e*l)*Math.cos(b*l)))/l;(isNaN(A)||A===0)&&(A=d/Math.cos(Math.PI/180*e)),this._point=y.subtract(i.getPixelOrigin()),this._radius=isNaN(A)?0:y.x-i.project([b,t-A]).x,this._radiusY=y.y-p.y}else{var S=o.unproject(o.project(this._latlng).subtract([this._mRadius,0]));this._point=i.latLngToLayerPoint(this._latlng),this._radius=this._point.x-i.latLngToLayerPoint(S).x}this._updateBounds()}});function ds(t,e,i){return new Ti(t,e,i)}var Et=It.extend({options:{smoothFactor:1,noClip:!1},initialize:function(t,e){M(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=1/0,i=null,o=ue,l,d,p=0,v=this._parts.length;p<v;p++)for(var y=this._parts[p],b=1,A=y.length;b<A;b++){l=y[b-1],d=y[b];var S=o(t,l,d,!0);S<e&&(e=S,i=o(t,l,d))}return i&&(i.distance=Math.sqrt(e)),i},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return Un(this._defaultShape(),this._map.options.crs)},getBounds:function(){return this._bounds},addLatLng:function(t,e){return e=e||this._defaultShape(),t=N(t),e.push(t),this._bounds.extend(t),this.redraw()},_setLatLngs:function(t){this._bounds=new ht,this._latlngs=this._convertLatLngs(t)},_defaultShape:function(){return _t(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(t){for(var e=[],i=_t(t),o=0,l=t.length;o<l;o++)i?(e[o]=N(t[o]),this._bounds.extend(e[o])):e[o]=this._convertLatLngs(t[o]);return e},_project:function(){var t=new Y;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 z(t,t);this._rawPxBounds&&(this._pxBounds=new Y([this._rawPxBounds.min.subtract(e),this._rawPxBounds.max.add(e)]))},_projectLatlngs:function(t,e,i){var o=t[0]instanceof G,l=t.length,d,p;if(o){for(p=[],d=0;d<l;d++)p[d]=this._map.latLngToLayerPoint(t[d]),i.extend(p[d]);e.push(p)}else for(d=0;d<l;d++)this._projectLatlngs(t[d],e,i)},_clipPoints:function(){var t=this._renderer._bounds;if(this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(t))){if(this.options.noClip){this._parts=this._rings;return}var e=this._parts,i,o,l,d,p,v,y;for(i=0,l=0,d=this._rings.length;i<d;i++)for(y=this._rings[i],o=0,p=y.length;o<p-1;o++)v=Bn(y[o],y[o+1],t,o,!0),v&&(e[l]=e[l]||[],e[l].push(v[0]),(v[1]!==y[o+1]||o===p-2)&&(e[l].push(v[1]),l++))}},_simplifyPoints:function(){for(var t=this._parts,e=this.options.smoothFactor,i=0,o=t.length;i<o;i++)t[i]=In(t[i],e)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(t,e){var i,o,l,d,p,v,y=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(i=0,d=this._parts.length;i<d;i++)for(v=this._parts[i],o=0,p=v.length,l=p-1;o<p;l=o++)if(!(!e&&o===0)&&zn(t,v[l],v[o])<=y)return!0;return!1}});function us(t,e){return new Et(t,e)}Et._flat=Rn;var jt=Et.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 Dn(this._defaultShape(),this._map.options.crs)},_convertLatLngs:function(t){var e=Et.prototype._convertLatLngs.call(this,t),i=e.length;return i>=2&&e[0]instanceof G&&e[0].equals(e[i-1])&&e.pop(),e},_setLatLngs:function(t){Et.prototype._setLatLngs.call(this,t),_t(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return _t(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,e=this.options.weight,i=new z(e,e);if(t=new Y(t.min.subtract(i),t.max.add(i)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(t))){if(this.options.noClip){this._parts=this._rings;return}for(var o=0,l=this._rings.length,d;o<l;o++)d=Sn(this._rings[o],t,!0),d.length&&this._parts.push(d)}},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(t){var e=!1,i,o,l,d,p,v,y,b;if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(d=0,y=this._parts.length;d<y;d++)for(i=this._parts[d],p=0,b=i.length,v=b-1;p<b;v=p++)o=i[p],l=i[v],o.y>t.y!=l.y>t.y&&t.x<(l.x-o.x)*(t.y-o.y)/(l.y-o.y)+o.x&&(e=!e);return e||Et.prototype._containsPoint.call(this,t,!0)}});function fs(t,e){return new jt(t,e)}var Pt=Mt.extend({initialize:function(t,e){M(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e=D(t)?t:t.features,i,o,l;if(e){for(i=0,o=e.length;i<o;i++)l=e[i],(l.geometries||l.geometry||l.features||l.coordinates)&&this.addData(l);return this}var d=this.options;if(d.filter&&!d.filter(t))return this;var p=Be(t,d);return p?(p.feature=Ne(t),p.defaultOptions=p.options,this.resetStyle(p),d.onEachFeature&&d.onEachFeature(t,p),this.addLayer(p)):this},resetStyle:function(t){return t===void 0?this.eachLayer(this.resetStyle,this):(t.options=n({},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&&(typeof e=="function"&&(e=e(t.feature)),t.setStyle(e))}});function Be(t,e){var i=t.type==="Feature"?t.geometry:t,o=i?i.coordinates:null,l=[],d=e&&e.pointToLayer,p=e&&e.coordsToLatLng||Si,v,y,b,A;if(!o&&!i)return null;switch(i.type){case"Point":return v=p(o),Hn(d,t,v,e);case"MultiPoint":for(b=0,A=o.length;b<A;b++)v=p(o[b]),l.push(Hn(d,t,v,e));return new Mt(l);case"LineString":case"MultiLineString":return y=Re(o,i.type==="LineString"?0:1,p),new Et(y,e);case"Polygon":case"MultiPolygon":return y=Re(o,i.type==="Polygon"?1:2,p),new jt(y,e);case"GeometryCollection":for(b=0,A=i.geometries.length;b<A;b++){var S=Be({geometry:i.geometries[b],type:"Feature",properties:t.properties},e);S&&l.push(S)}return new Mt(l);case"FeatureCollection":for(b=0,A=i.features.length;b<A;b++){var R=Be(i.features[b],e);R&&l.push(R)}return new Mt(l);default:throw new Error("Invalid GeoJSON object.")}}function Hn(t,e,i,o){return t?t(e,i):new ze(i,o&&o.markersInheritOptions&&o)}function Si(t){return new G(t[1],t[0],t[2])}function Re(t,e,i){for(var o=[],l=0,d=t.length,p;l<d;l++)p=e?Re(t[l],e-1,i):(i||Si)(t[l]),o.push(p);return o}function Di(t,e){return t=N(t),t.alt!==void 0?[x(t.lng,e),x(t.lat,e),x(t.alt,e)]:[x(t.lng,e),x(t.lat,e)]}function Ue(t,e,i,o){for(var l=[],d=0,p=t.length;d<p;d++)l.push(e?Ue(t[d],_t(t[d])?0:e-1,i,o):Di(t[d],o));return!e&&i&&l.length>0&&l.push(l[0].slice()),l}function Jt(t,e){return t.feature?n({},t.feature,{geometry:e}):Ne(e)}function Ne(t){return t.type==="Feature"||t.type==="FeatureCollection"?t:{type:"Feature",properties:{},geometry:t}}var Ii={toGeoJSON:function(t){return Jt(this,{type:"Point",coordinates:Di(this.getLatLng(),t)})}};ze.include(Ii),Ti.include(Ii),Oe.include(Ii),Et.include({toGeoJSON:function(t){var e=!_t(this._latlngs),i=Ue(this._latlngs,e?1:0,!1,t);return Jt(this,{type:(e?"Multi":"")+"LineString",coordinates:i})}}),jt.include({toGeoJSON:function(t){var e=!_t(this._latlngs),i=e&&!_t(this._latlngs[0]),o=Ue(this._latlngs,i?2:e?1:0,!0,t);return e||(o=[o]),Jt(this,{type:(i?"Multi":"")+"Polygon",coordinates:o})}}),Yt.include({toMultiPoint:function(t){var e=[];return this.eachLayer(function(i){e.push(i.toGeoJSON(t).geometry.coordinates)}),Jt(this,{type:"MultiPoint",coordinates:e})},toGeoJSON:function(t){var e=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(e==="MultiPoint")return this.toMultiPoint(t);var i=e==="GeometryCollection",o=[];return this.eachLayer(function(l){if(l.toGeoJSON){var d=l.toGeoJSON(t);if(i)o.push(d.geometry);else{var p=Ne(d);p.type==="FeatureCollection"?o.push.apply(o,p.features):o.push(p)}}}),i?Jt(this,{geometries:o,type:"GeometryCollection"}):{type:"FeatureCollection",features:o}}});function Fn(t,e){return new Pt(t,e)}var ps=Fn,Ze=yt.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(t,e,i){this._url=t,this._bounds=$(e),M(this,i)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(B(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){q(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&&Vt(this._image),this},bringToBack:function(){return this._map&&Wt(this._image),this},setUrl:function(t){return this._url=t,this._image&&(this._image.src=t),this},setBounds:function(t){return this._bounds=$(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=this._url.tagName==="IMG",e=this._image=t?this._url:F("img");if(B(e,"leaflet-image-layer"),this._zoomAnimated&&B(e,"leaflet-zoom-animated"),this.options.className&&B(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onload=a(this.fire,this,"load"),e.onerror=a(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(e.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),t){this._url=e.src;return}e.src=this._url,e.alt=this.options.alt},_animateZoom:function(t){var e=this._map.getZoomScale(t.zoom),i=this._map._latLngBoundsToNewLayerBounds(this._bounds,t.zoom,t.center).min;Bt(this._image,i,e)},_reset:function(){var t=this._image,e=new Y(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),i=e.getSize();tt(t,e.min),t.style.width=i.x+"px",t.style.height=i.y+"px"},_updateOpacity:function(){mt(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(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()}}),ms=function(t,e,i){return new Ze(t,e,i)},Gn=Ze.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var t=this._url.tagName==="VIDEO",e=this._image=t?this._url:F("video");if(B(e,"leaflet-image-layer"),this._zoomAnimated&&B(e,"leaflet-zoom-animated"),this.options.className&&B(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onloadeddata=a(this.fire,this,"load"),t){for(var i=e.getElementsByTagName("source"),o=[],l=0;l<i.length;l++)o.push(i[l].src);this._url=i.length>0?o:[e.src];return}D(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 d=0;d<this._url.length;d++){var p=F("source");p.src=this._url[d],e.appendChild(p)}}});function _s(t,e,i){return new Gn(t,e,i)}var Vn=Ze.extend({_initImage:function(){var t=this._image=this._url;B(t,"leaflet-image-layer"),this._zoomAnimated&&B(t,"leaflet-zoom-animated"),this.options.className&&B(t,this.options.className),t.onselectstart=w,t.onmousemove=w}});function gs(t,e,i){return new Vn(t,e,i)}var xt=yt.extend({options:{interactive:!1,offset:[0,0],className:"",pane:void 0,content:""},initialize:function(t,e){t&&(t instanceof G||D(t))?(this._latlng=N(t),M(this,e)):(M(this,t),this._source=e),this.options.content&&(this._content=this.options.content)},openOn:function(t){return t=arguments.length?t:this._source._map,t.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&&mt(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),t._fadeAnimated&&mt(this._container,1),this.bringToFront(),this.options.interactive&&(B(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(t){t._fadeAnimated?(mt(this._container,0),this._removeTimeout=setTimeout(a(q,void 0,this._container),200)):q(this._container),this.options.interactive&&(X(this._container,"leaflet-interactive"),this.removeInteractiveTarget(this._container))},getLatLng:function(){return this._latlng},setLatLng:function(t){return this._latlng=N(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&&Vt(this._container),this},bringToBack:function(){return this._map&&Wt(this._container),this},_prepareOpen:function(t){var e=this._source;if(!e._map)return!1;if(e instanceof Mt){e=null;var i=this._source._layers;for(var o in i)if(i[o]._map){e=i[o];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)t=e.getBounds().getCenter();else throw new Error("Unable to get source layer LatLng.");return this.setLatLng(t),this._map&&this.update(),!0},_updateContent:function(){if(this._content){var t=this._contentNode,e=typeof this._content=="function"?this._content(this._source||this):this._content;if(typeof e=="string")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=I(this.options.offset),i=this._getAnchor();this._zoomAnimated?tt(this._container,t.add(i)):e=e.add(t).add(i);var o=this._containerBottom=-e.y,l=this._containerLeft=-Math.round(this._containerWidth/2)+e.x;this._container.style.bottom=o+"px",this._container.style.left=l+"px"}},_getAnchor:function(){return[0,0]}});Z.include({_initOverlay:function(t,e,i,o){var l=e;return l instanceof t||(l=new t(o).setContent(e)),i&&l.setLatLng(i),l}}),yt.include({_initOverlay:function(t,e,i,o){var l=i;return l instanceof t?(M(l,o),l._source=this):(l=e&&!o?e:new t(o,this),l.setContent(i)),l}});var He=xt.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,!t.hasLayer(this)&&t._popup&&t._popup.options.autoClose&&t.removeLayer(t._popup),t._popup=this,xt.prototype.openOn.call(this,t)},onAdd:function(t){xt.prototype.onAdd.call(this,t),t.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof It||this._source.on("preclick",Ut))},onRemove:function(t){xt.prototype.onRemove.call(this,t),t.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof It||this._source.off("preclick",Ut))},getEvents:function(){var t=xt.prototype.getEvents.call(this);return(this.options.closeOnClick!==void 0?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=F("div",t+" "+(this.options.className||"")+" leaflet-zoom-animated"),i=this._wrapper=F("div",t+"-content-wrapper",e);if(this._contentNode=F("div",t+"-content",i),ce(e),bi(this._contentNode),O(e,"contextmenu",Ut),this._tipContainer=F("div",t+"-tip-container",e),this._tip=F("div",t+"-tip",this._tipContainer),this.options.closeButton){var o=this._closeButton=F("a",t+"-close-button",e);o.setAttribute("role","button"),o.setAttribute("aria-label","Close popup"),o.href="#close",o.innerHTML='<span aria-hidden="true">×</span>',O(o,"click",function(l){ot(l),this.close()},this)}},_updateLayout:function(){var t=this._contentNode,e=t.style;e.width="",e.whiteSpace="nowrap";var i=t.offsetWidth;i=Math.min(i,this.options.maxWidth),i=Math.max(i,this.options.minWidth),e.width=i+1+"px",e.whiteSpace="",e.height="";var o=t.offsetHeight,l=this.options.maxHeight,d="leaflet-popup-scrolled";l&&o>l?(e.height=l+"px",B(t,d)):X(t,d),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),i=this._getAnchor();tt(this._container,e.add(i))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var t=this._map,e=parseInt(se(this._container,"marginBottom"),10)||0,i=this._container.offsetHeight+e,o=this._containerWidth,l=new z(this._containerLeft,-i-this._containerBottom);l._add(Rt(this._container));var d=t.layerPointToContainerPoint(l),p=I(this.options.autoPanPadding),v=I(this.options.autoPanPaddingTopLeft||p),y=I(this.options.autoPanPaddingBottomRight||p),b=t.getSize(),A=0,S=0;d.x+o+y.x>b.x&&(A=d.x+o-b.x+y.x),d.x-A-v.x<0&&(A=d.x-v.x),d.y+i+y.y>b.y&&(S=d.y+i-b.y+y.y),d.y-S-v.y<0&&(S=d.y-v.y),(A||S)&&(this.options.keepInView&&(this._autopanning=!0),t.fire("autopanstart").panBy([A,S]))}},_getAnchor:function(){return I(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),vs=function(t,e){return new He(t,e)};Z.mergeOptions({closePopupOnClick:!0}),Z.include({openPopup:function(t,e,i){return this._initOverlay(He,t,e,i).openOn(this),this},closePopup:function(t){return t=arguments.length?t:this._popup,t&&t.close(),this}}),yt.include({bindPopup:function(t,e){return this._popup=this._initOverlay(He,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 Mt||(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():!1},setPopupContent:function(t){return this._popup&&this._popup.setContent(t),this},getPopup:function(){return this._popup},_openPopup:function(t){if(!(!this._popup||!this._map)){Nt(t);var e=t.layer||t.target;if(this._popup._source===e&&!(e instanceof It)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(t.latlng);return}this._popup._source=e,this.openPopup(t.latlng)}},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){t.originalEvent.keyCode===13&&this._openPopup(t)}});var Fe=xt.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(t){xt.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){xt.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=xt.prototype.getEvents.call(this);return this.options.permanent||(t.preclick=this.close),t},_initLayout:function(){var t="leaflet-tooltip",e=t+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=F("div",e),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+f(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e,i,o=this._map,l=this._container,d=o.latLngToContainerPoint(o.getCenter()),p=o.layerPointToContainerPoint(t),v=this.options.direction,y=l.offsetWidth,b=l.offsetHeight,A=I(this.options.offset),S=this._getAnchor();v==="top"?(e=y/2,i=b):v==="bottom"?(e=y/2,i=0):v==="center"?(e=y/2,i=b/2):v==="right"?(e=0,i=b/2):v==="left"?(e=y,i=b/2):p.x<d.x?(v="right",e=0,i=b/2):(v="left",e=y+(A.x+S.x)*2,i=b/2),t=t.subtract(I(e,i,!0)).add(A).add(S),X(l,"leaflet-tooltip-right"),X(l,"leaflet-tooltip-left"),X(l,"leaflet-tooltip-top"),X(l,"leaflet-tooltip-bottom"),B(l,"leaflet-tooltip-"+v),tt(l,t)},_updatePosition:function(){var t=this._map.latLngToLayerPoint(this._latlng);this._setPosition(t)},setOpacity:function(t){this.options.opacity=t,this._container&&mt(this._container,t)},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center);this._setPosition(e)},_getAnchor:function(){return I(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),ys=function(t,e){return new Fe(t,e)};Z.include({openTooltip:function(t,e,i){return this._initOverlay(Fe,t,e,i).openOn(this),this},closeTooltip:function(t){return t.close(),this}}),yt.include({bindTooltip:function(t,e){return this._tooltip&&this.isTooltipOpen()&&this.unbindTooltip(),this._tooltip=this._initOverlay(Fe,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",i={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?i.add=this._openTooltip:(i.mouseover=this._openTooltip,i.mouseout=this.closeTooltip,i.click=this._openTooltip,this._map?this._addFocusListeners():i.add=this._addFocusListeners),this._tooltip.options.sticky&&(i.mousemove=this._moveTooltip),this[e](i),this._tooltipHandlersAdded=!t}},openTooltip:function(t){return this._tooltip&&(this instanceof Mt||(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=typeof t.getElement=="function"&&t.getElement();e&&(O(e,"focus",function(){this._tooltip._source=t,this.openTooltip()},this),O(e,"blur",this.closeTooltip,this))},_setAriaDescribedByOnLayer:function(t){var e=typeof t.getElement=="function"&&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)});return}this._tooltip._source=t.layer||t.target,this.openTooltip(this._tooltip.options.sticky?t.latlng:void 0)}},_moveTooltip:function(t){var e=t.latlng,i,o;this._tooltip.options.sticky&&t.originalEvent&&(i=this._map.mouseEventToContainerPoint(t.originalEvent),o=this._map.containerPointToLayerPoint(i),e=this._map.layerPointToLatLng(o)),this._tooltip.setLatLng(e)}});var Wn=qt.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(t){var e=t&&t.tagName==="DIV"?t:document.createElement("div"),i=this.options;if(i.html instanceof Element?(Pe(e),e.appendChild(i.html)):e.innerHTML=i.html!==!1?i.html:"",i.bgPos){var o=I(i.bgPos);e.style.backgroundPosition=-o.x+"px "+-o.y+"px"}return this._setIconStyles(e,"icon"),e},createShadow:function(){return null}});function Ls(t){return new Wn(t)}qt.Default=fe;var pe=yt.extend({options:{tileSize:256,opacity:1,updateWhenIdle:C.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){M(this,t)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView()},beforeAdd:function(t){t._addZoomLimit(this)},onRemove:function(t){this._removeAllTiles(),q(this._container),t._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Vt(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(Wt(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=_(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 z?t:new z(t,t)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(t){for(var e=this.getPane().children,i=-t(-1/0,1/0),o=0,l=e.length,d;o<l;o++)d=e[o].style.zIndex,e[o]!==this._container&&d&&(i=t(i,+d));isFinite(i)&&(this.options.zIndex=i+t(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!C.ielt9){mt(this._container,this.options.opacity);var t=+new Date,e=!1,i=!1;for(var o in this._tiles){var l=this._tiles[o];if(!(!l.current||!l.loaded)){var d=Math.min(1,(t-l.loaded)/200);mt(l.el,d),d<1?e=!0:(l.active?i=!0:this._onOpaqueTile(l),l.active=!0)}}i&&!this._noPrune&&this._pruneTiles(),e&&(at(this._fadeFrame),this._fadeFrame=rt(this._updateOpacity,this))}},_onOpaqueTile:w,_initContainer:function(){this._container||(this._container=F("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(t!==void 0){for(var i in this._levels)i=Number(i),this._levels[i].el.children.length||i===t?(this._levels[i].el.style.zIndex=e-Math.abs(t-i),this._onUpdateLevel(i)):(q(this._levels[i].el),this._removeTilesAtZoom(i),this._onRemoveLevel(i),delete this._levels[i]);var o=this._levels[t],l=this._map;return o||(o=this._levels[t]={},o.el=F("div","leaflet-tile-container leaflet-zoom-animated",this._container),o.el.style.zIndex=e,o.origin=l.project(l.unproject(l.getPixelOrigin()),t).round(),o.zoom=t,this._setZoomTransform(o,l.getCenter(),l.getZoom()),w(o.el.offsetWidth),this._onCreateLevel(o)),this._level=o,o}},_onUpdateLevel:w,_onRemoveLevel:w,_onCreateLevel:w,_pruneTiles:function(){if(this._map){var t,e,i=this._map.getZoom();if(i>this.options.maxZoom||i<this.options.minZoom){this._removeAllTiles();return}for(t in this._tiles)e=this._tiles[t],e.retain=e.current;for(t in this._tiles)if(e=this._tiles[t],e.current&&!e.active){var o=e.coords;this._retainParent(o.x,o.y,o.z,o.z-5)||this._retainChildren(o.x,o.y,o.z,o.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)q(this._levels[t].el),this._onRemoveLevel(Number(t)),delete this._levels[t];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(t,e,i,o){var l=Math.floor(t/2),d=Math.floor(e/2),p=i-1,v=new z(+l,+d);v.z=+p;var y=this._tileCoordsToKey(v),b=this._tiles[y];return b&&b.active?(b.retain=!0,!0):(b&&b.loaded&&(b.retain=!0),p>o?this._retainParent(l,d,p,o):!1)},_retainChildren:function(t,e,i,o){for(var l=2*t;l<2*t+2;l++)for(var d=2*e;d<2*e+2;d++){var p=new z(l,d);p.z=i+1;var v=this._tileCoordsToKey(p),y=this._tiles[v];if(y&&y.active){y.retain=!0;continue}else y&&y.loaded&&(y.retain=!0);i+1<o&&this._retainChildren(l,d,i+1,o)}},_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 e.minNativeZoom!==void 0&&t<e.minNativeZoom?e.minNativeZoom:e.maxNativeZoom!==void 0&&e.maxNativeZoom<t?e.maxNativeZoom:t},_setView:function(t,e,i,o){var l=Math.round(e);this.options.maxZoom!==void 0&&l>this.options.maxZoom||this.options.minZoom!==void 0&&l<this.options.minZoom?l=void 0:l=this._clampZoom(l);var d=this.options.updateWhenZooming&&l!==this._tileZoom;(!o||d)&&(this._tileZoom=l,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),l!==void 0&&this._update(t),i||this._pruneTiles(),this._noPrune=!!i),this._setZoomTransforms(t,e)},_setZoomTransforms:function(t,e){for(var i in this._levels)this._setZoomTransform(this._levels[i],t,e)},_setZoomTransform:function(t,e,i){var o=this._map.getZoomScale(i,t.zoom),l=t.origin.multiplyBy(o).subtract(this._map._getNewPixelOrigin(e,i)).round();C.any3d?Bt(t.el,l,o):tt(t.el,l)},_resetGrid:function(){var t=this._map,e=t.options.crs,i=this._tileSize=this.getTileSize(),o=this._tileZoom,l=this._map.getPixelWorldBounds(this._tileZoom);l&&(this._globalTileRange=this._pxBoundsToTileRange(l)),this._wrapX=e.wrapLng&&!this.options.noWrap&&[Math.floor(t.project([0,e.wrapLng[0]],o).x/i.x),Math.ceil(t.project([0,e.wrapLng[1]],o).x/i.y)],this._wrapY=e.wrapLat&&!this.options.noWrap&&[Math.floor(t.project([e.wrapLat[0],0],o).y/i.x),Math.ceil(t.project([e.wrapLat[1],0],o).y/i.y)]},_onMoveEnd:function(){!this._map||this._map._animatingZoom||this._update()},_getTiledPixelBounds:function(t){var e=this._map,i=e._animatingZoom?Math.max(e._animateToZoom,e.getZoom()):e.getZoom(),o=e.getZoomScale(i,this._tileZoom),l=e.project(t,this._tileZoom).floor(),d=e.getSize().divideBy(o*2);return new Y(l.subtract(d),l.add(d))},_update:function(t){var e=this._map;if(e){var i=this._clampZoom(e.getZoom());if(t===void 0&&(t=e.getCenter()),this._tileZoom!==void 0){var o=this._getTiledPixelBounds(t),l=this._pxBoundsToTileRange(o),d=l.getCenter(),p=[],v=this.options.keepBuffer,y=new Y(l.getBottomLeft().subtract([v,-v]),l.getTopRight().add([v,-v]));if(!(isFinite(l.min.x)&&isFinite(l.min.y)&&isFinite(l.max.x)&&isFinite(l.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var b in this._tiles){var A=this._tiles[b].coords;(A.z!==this._tileZoom||!y.contains(new z(A.x,A.y)))&&(this._tiles[b].current=!1)}if(Math.abs(i-this._tileZoom)>1){this._setView(t,i);return}for(var S=l.min.y;S<=l.max.y;S++)for(var R=l.min.x;R<=l.max.x;R++){var st=new z(R,S);if(st.z=this._tileZoom,!!this._isValidTile(st)){var it=this._tiles[this._tileCoordsToKey(st)];it?it.current=!0:p.push(st)}}if(p.sort(function(ct,Xt){return ct.distanceTo(d)-Xt.distanceTo(d)}),p.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var gt=document.createDocumentFragment();for(R=0;R<p.length;R++)this._addTile(p[R],gt);this._level.el.appendChild(gt)}}}},_isValidTile:function(t){var e=this._map.options.crs;if(!e.infinite){var i=this._globalTileRange;if(!e.wrapLng&&(t.x<i.min.x||t.x>i.max.x)||!e.wrapLat&&(t.y<i.min.y||t.y>i.max.y))return!1}if(!this.options.bounds)return!0;var o=this._tileCoordsToBounds(t);return $(this.options.bounds).overlaps(o)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var e=this._map,i=this.getTileSize(),o=t.scaleBy(i),l=o.add(i),d=e.unproject(o,t.z),p=e.unproject(l,t.z);return[d,p]},_tileCoordsToBounds:function(t){var e=this._tileCoordsToNwSe(t),i=new ht(e[0],e[1]);return this.options.noWrap||(i=this._map.wrapLatLngBounds(i)),i},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var e=t.split(":"),i=new z(+e[0],+e[1]);return i.z=+e[2],i},_removeTile:function(t){var e=this._tiles[t];e&&(q(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){B(t,"leaflet-tile");var e=this.getTileSize();t.style.width=e.x+"px",t.style.height=e.y+"px",t.onselectstart=w,t.onmousemove=w,C.ielt9&&this.options.opacity<1&&mt(t,this.options.opacity)},_addTile:function(t,e){var i=this._getTilePos(t),o=this._tileCoordsToKey(t),l=this.createTile(this._wrapCoords(t),a(this._tileReady,this,t));this._initTile(l),this.createTile.length<2&&rt(a(this._tileReady,this,t,null,l)),tt(l,i),this._tiles[o]={el:l,coords:t,current:!0},e.appendChild(l),this.fire("tileloadstart",{tile:l,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&&(i.loaded=+new Date,this._map._fadeAnimated?(mt(i.el,0),at(this._fadeFrame),this._fadeFrame=rt(this._updateOpacity,this)):(i.active=!0,this._pruneTiles()),e||(B(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),C.ielt9||!this._map._fadeAnimated?rt(this._pruneTiles,this):setTimeout(a(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new z(this._wrapX?m(t.x,this._wrapX):t.x,this._wrapY?m(t.y,this._wrapY):t.y);return e.z=t.z,e},_pxBoundsToTileRange:function(t){var e=this.getTileSize();return new Y(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}});function ws(t){return new pe(t)}var Kt=pe.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=M(this,e),e.detectRetina&&C.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),typeof e.subdomains=="string"&&(e.subdomains=e.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(t,e){return this._url===t&&e===void 0&&(e=!0),this._url=t,e||this.redraw(),this},createTile:function(t,e){var i=document.createElement("img");return O(i,"load",a(this._tileOnLoad,this,e,i)),O(i,"error",a(this._tileOnError,this,e,i)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(i.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(i.referrerPolicy=this.options.referrerPolicy),i.alt="",i.src=this.getTileUrl(t),i},getTileUrl:function(t){var e={r:C.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&&(e.y=i),e["-y"]=i}return T(this._url,n(e,this.options))},_tileOnLoad:function(t,e){C.ielt9?setTimeout(a(t,this,null,e),0):t(null,e)},_tileOnError:function(t,e,i){var o=this.options.errorTileUrl;o&&e.getAttribute("src")!==o&&(e.src=o),t(i,e)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,e=this.options.maxZoom,i=this.options.zoomReverse,o=this.options.zoomOffset;return i&&(t=e-t),t+o},_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,e.onload=w,e.onerror=w,!e.complete)){e.src=j;var i=this._tiles[t].coords;q(e),delete this._tiles[t],this.fire("tileabort",{tile:e,coords:i})}},_removeTile:function(t){var e=this._tiles[t];if(e)return e.el.setAttribute("src",j),pe.prototype._removeTile.call(this,t)},_tileReady:function(t,e,i){if(!(!this._map||i&&i.getAttribute("src")===j))return pe.prototype._tileReady.call(this,t,e,i)}});function Yn(t,e){return new Kt(t,e)}var qn=Kt.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(t,e){this._url=t;var i=n({},this.defaultWmsParams);for(var o in e)o in this.options||(i[o]=e[o]);e=M(this,e);var l=e.detectRetina&&C.retina?2:1,d=this.getTileSize();i.width=d.x*l,i.height=d.y*l,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,Kt.prototype.onAdd.call(this,t)},getTileUrl:function(t){var e=this._tileCoordsToNwSe(t),i=this._crs,o=lt(i.project(e[0]),i.project(e[1])),l=o.min,d=o.max,p=(this._wmsVersion>=1.3&&this._crs===Nn?[l.y,l.x,d.y,d.x]:[l.x,l.y,d.x,d.y]).join(","),v=Kt.prototype.getTileUrl.call(this,t);return v+U(this.wmsParams,v,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+p},setParams:function(t,e){return n(this.wmsParams,t),e||this.redraw(),this}});function bs(t,e){return new qn(t,e)}Kt.WMS=qn,Yn.wms=bs;var Ct=yt.extend({options:{padding:.1},initialize:function(t){M(this,t),f(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),B(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var t={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(t.zoomanim=this._onAnimZoom),t},_onAnimZoom:function(t){this._updateTransform(t.center,t.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(t,e){var i=this._map.getZoomScale(e,this._zoom),o=this._map.getSize().multiplyBy(.5+this.options.padding),l=this._map.project(this._center,e),d=o.multiplyBy(-i).add(l).subtract(this._map._getNewPixelOrigin(t,e));C.any3d?Bt(this._container,d,i):tt(this._container,d)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var t in this._layers)this._layers[t]._reset()},_onZoomEnd:function(){for(var t in this._layers)this._layers[t]._project()},_updatePaths:function(){for(var t in this._layers)this._layers[t]._update()},_update:function(){var t=this.options.padding,e=this._map.getSize(),i=this._map.containerPointToLayerPoint(e.multiplyBy(-t)).round();this._bounds=new Y(i,i.add(e.multiplyBy(1+t*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),jn=Ct.extend({options:{tolerance:0},getEvents:function(){var t=Ct.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Ct.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");O(t,"mousemove",this._onMouseMove,this),O(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),O(t,"mouseout",this._handleMouseOut,this),t._leaflet_disable_events=!0,this._ctx=t.getContext("2d")},_destroyContainer:function(){at(this._redrawRequest),delete this._ctx,q(this._container),W(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var t;this._redrawBounds=null;for(var e in this._layers)t=this._layers[e],t._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Ct.prototype._update.call(this);var t=this._bounds,e=this._container,i=t.getSize(),o=C.retina?2:1;tt(e,t.min),e.width=o*i.x,e.height=o*i.y,e.style.width=i.x+"px",e.style.height=i.y+"px",C.retina&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){Ct.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[f(t)]=t;var e=t._order={layer:t,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=e),this._drawLast=e,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(t){this._requestRedraw(t)},_removePath:function(t){var e=t._order,i=e.next,o=e.prev;i?i.prev=o:this._drawLast=o,o?o.next=i:this._drawFirst=i,delete t._order,delete this._layers[f(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(typeof t.options.dashArray=="string"){var e=t.options.dashArray.split(/[, ]+/),i=[],o,l;for(l=0;l<e.length;l++){if(o=Number(e[l]),isNaN(o))return;i.push(o)}t.options._dashArray=i}else t.options._dashArray=t.options.dashArray},_requestRedraw:function(t){this._map&&(this._extendRedrawBounds(t),this._redrawRequest=this._redrawRequest||rt(this._redraw,this))},_extendRedrawBounds:function(t){if(t._pxBounds){var e=(t.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new Y,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 i=e.getSize();this._ctx.beginPath(),this._ctx.rect(e.min.x,e.min.y,i.x,i.y),this._ctx.clip()}this._drawing=!0;for(var o=this._drawFirst;o;o=o.next)t=o.layer,(!e||t._pxBounds&&t._pxBounds.intersects(e))&&t._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(t,e){if(this._drawing){var i,o,l,d,p=t._parts,v=p.length,y=this._ctx;if(v){for(y.beginPath(),i=0;i<v;i++){for(o=0,l=p[i].length;o<l;o++)d=p[i][o],y[o?"lineTo":"moveTo"](d.x,d.y);e&&y.closePath()}this._fillStroke(y,t)}}},_updateCircle:function(t){if(!(!this._drawing||t._empty())){var e=t._point,i=this._ctx,o=Math.max(Math.round(t._radius),1),l=(Math.max(Math.round(t._radiusY),1)||o)/o;l!==1&&(i.save(),i.scale(1,l)),i.beginPath(),i.arc(e.x,e.y/l,o,0,Math.PI*2,!1),l!==1&&i.restore(),this._fillStroke(i,t)}},_fillStroke:function(t,e){var i=e.options;i.fill&&(t.globalAlpha=i.fillOpacity,t.fillStyle=i.fillColor||i.color,t.fill(i.fillRule||"evenodd")),i.stroke&&i.weight!==0&&(t.setLineDash&&t.setLineDash(e.options&&e.options._dashArray||[]),t.globalAlpha=i.opacity,t.lineWidth=i.weight,t.strokeStyle=i.color,t.lineCap=i.lineCap,t.lineJoin=i.lineJoin,t.stroke())},_onClick:function(t){for(var e=this._map.mouseEventToLayerPoint(t),i,o,l=this._drawFirst;l;l=l.next)i=l.layer,i.options.interactive&&i._containsPoint(e)&&(!(t.type==="click"||t.type==="preclick")||!this._map._draggableMoved(i))&&(o=i);this._fireEvent(o?[o]:!1,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&&(X(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,l=this._drawFirst;l;l=l.next)i=l.layer,i.options.interactive&&i._containsPoint(e)&&(o=i);o!==this._hoveredLayer&&(this._handleMouseOut(t),o&&(B(this._container,"leaflet-interactive"),this._fireEvent([o],t,"mouseover"),this._hoveredLayer=o)),this._fireEvent(this._hoveredLayer?[this._hoveredLayer]:!1,t),this._mouseHoverThrottled=!0,setTimeout(a(function(){this._mouseHoverThrottled=!1},this),32)}},_fireEvent:function(t,e,i){this._map._fireDOMEvent(e,i||e.type,t)},_bringToFront:function(t){var e=t._order;if(e){var i=e.next,o=e.prev;if(i)i.prev=o;else return;o?o.next=i:i&&(this._drawFirst=i),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 i=e.next,o=e.prev;if(o)o.next=i;else return;i?i.prev=o:o&&(this._drawLast=o),e.prev=null,e.next=this._drawFirst,this._drawFirst.prev=e,this._drawFirst=e,this._requestRedraw(t)}}});function Jn(t){return C.canvas?new jn(t):null}var me=(function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("<lvml:"+t+' class="lvml">')}}catch{}return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}})(),xs={_initContainer:function(){this._container=F("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Ct.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var e=t._container=me("shape");B(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=me("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[f(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;q(e),t.removeInteractiveTarget(e),delete this._layers[f(t)]},_updateStyle:function(t){var e=t._stroke,i=t._fill,o=t.options,l=t._container;l.stroked=!!o.stroke,l.filled=!!o.fill,o.stroke?(e||(e=t._stroke=me("stroke")),l.appendChild(e),e.weight=o.weight+"px",e.color=o.color,e.opacity=o.opacity,o.dashArray?e.dashStyle=D(o.dashArray)?o.dashArray.join(" "):o.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=o.lineCap.replace("butt","flat"),e.joinstyle=o.lineJoin):e&&(l.removeChild(e),t._stroke=null),o.fill?(i||(i=t._fill=me("fill")),l.appendChild(i),i.color=o.fillColor||o.color,i.opacity=o.fillOpacity):i&&(l.removeChild(i),t._fill=null)},_updateCircle:function(t){var e=t._point.round(),i=Math.round(t._radius),o=Math.round(t._radiusY||i);this._setPath(t,t._empty()?"M0 0":"AL "+e.x+","+e.y+" "+i+","+o+" 0,"+65535*360)},_setPath:function(t,e){t._path.v=e},_bringToFront:function(t){Vt(t._container)},_bringToBack:function(t){Wt(t._container)}},Ge=C.vml?me:Qi,_e=Ct.extend({_initContainer:function(){this._container=Ge("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Ge("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){q(this._container),W(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Ct.prototype._update.call(this);var t=this._bounds,e=t.getSize(),i=this._container;(!this._svgSize||!this._svgSize.equals(e))&&(this._svgSize=e,i.setAttribute("width",e.x),i.setAttribute("height",e.y)),tt(i,t.min),i.setAttribute("viewBox",[t.min.x,t.min.y,e.x,e.y].join(" ")),this.fire("update")}},_initPath:function(t){var e=t._path=Ge("path");t.options.className&&B(e,t.options.className),t.options.interactive&&B(e,"leaflet-interactive"),this._updateStyle(t),this._layers[f(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){q(t._path),t.removeInteractiveTarget(t._path),delete this._layers[f(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var e=t._path,i=t.options;e&&(i.stroke?(e.setAttribute("stroke",i.color),e.setAttribute("stroke-opacity",i.opacity),e.setAttribute("stroke-width",i.weight),e.setAttribute("stroke-linecap",i.lineCap),e.setAttribute("stroke-linejoin",i.lineJoin),i.dashArray?e.setAttribute("stroke-dasharray",i.dashArray):e.removeAttribute("stroke-dasharray"),i.dashOffset?e.setAttribute("stroke-dashoffset",i.dashOffset):e.removeAttribute("stroke-dashoffset")):e.setAttribute("stroke","none"),i.fill?(e.setAttribute("fill",i.fillColor||i.color),e.setAttribute("fill-opacity",i.fillOpacity),e.setAttribute("fill-rule",i.fillRule||"evenodd")):e.setAttribute("fill","none"))},_updatePoly:function(t,e){this._setPath(t,$i(t._parts,e))},_updateCircle:function(t){var e=t._point,i=Math.max(Math.round(t._radius),1),o=Math.max(Math.round(t._radiusY),1)||i,l="a"+i+","+o+" 0 1,0 ",d=t._empty()?"M0 0":"M"+(e.x-i)+","+e.y+l+i*2+",0 "+l+-i*2+",0 ";this._setPath(t,d)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){Vt(t._path)},_bringToBack:function(t){Wt(t._path)}});C.vml&&_e.include(xs);function Kn(t){return C.svg||C.vml?new _e(t):null}Z.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(t==="overlayPane"||t===void 0)return!1;var e=this._paneRenderers[t];return e===void 0&&(e=this._createRenderer({pane:t}),this._paneRenderers[t]=e),e},_createRenderer:function(t){return this.options.preferCanvas&&Jn(t)||Kn(t)}});var Xn=jt.extend({initialize:function(t,e){jt.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()]}});function ks(t,e){return new Xn(t,e)}_e.create=Ge,_e.pointsToPath=$i,Pt.geometryToLayer=Be,Pt.coordsToLatLng=Si,Pt.coordsToLatLngs=Re,Pt.latLngToCoords=Di,Pt.latLngsToCoords=Ue,Pt.getFeature=Jt,Pt.asFeature=Ne,Z.mergeOptions({boxZoom:!0});var Qn=bt.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(){O(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){W(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){q(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){this._resetStateTimeout!==0&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(t){if(!t.shiftKey||t.which!==1&&t.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),ae(),pi(),this._startPoint=this._map.mouseEventToContainerPoint(t),O(document,{contextmenu:Nt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=F("div","leaflet-zoom-box",this._container),B(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var e=new Y(this._point,this._startPoint),i=e.getSize();tt(this._box,e.min),this._box.style.width=i.x+"px",this._box.style.height=i.y+"px"},_finish:function(){this._moved&&(q(this._box),X(this._container,"leaflet-crosshair")),le(),mi(),W(document,{contextmenu:Nt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(t){if(!(t.which!==1&&t.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(a(this._resetState,this),0);var e=new ht(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(e).fire("boxzoomend",{boxZoomBounds:e})}},_onKeyDown:function(t){t.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});Z.addInitHook("addHandler","boxZoom",Qn),Z.mergeOptions({doubleClickZoom:!0});var $n=bt.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(t){var e=this._map,i=e.getZoom(),o=e.options.zoomDelta,l=t.originalEvent.shiftKey?i-o:i+o;e.options.doubleClickZoom==="center"?e.setZoom(l):e.setZoomAround(t.containerPoint,l)}});Z.addInitHook("addHandler","doubleClickZoom",$n),Z.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var to=bt.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new Dt(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))}B(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){X(this._map._container,"leaflet-grab"),X(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=$(this._map.options.maxBounds);this._offsetLimit=lt(this._map.latLngToContainerPoint(e.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(e.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;t.fire("movestart").fire("dragstart"),t.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(t){if(this._map.options.inertia){var e=this._lastTime=+new Date,i=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(i),this._times.push(e),this._prunePositions(e)}this._map.fire("move",t).fire("drag",t)},_prunePositions:function(t){for(;this._positions.length>1&&t-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var t=this._map.getSize().divideBy(2),e=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=e.subtract(t).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(t,e){return t-(t-e)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var t=this._draggable._newPos.subtract(this._draggable._startPos),e=this._offsetLimit;t.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),i=this._initialWorldOffset,o=this._draggable._newPos.x,l=(o-e+i)%t+e-i,d=(o+e+i)%t-e-i,p=Math.abs(l+i)<Math.abs(d+i)?l:d;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=p},_onDragEnd:function(t){var e=this._map,i=e.options,o=!i.inertia||t.noInertia||this._times.length<2;if(e.fire("dragend",t),o)e.fire("moveend");else{this._prunePositions(+new Date);var l=this._lastPos.subtract(this._positions[0]),d=(this._lastTime-this._times[0])/1e3,p=i.easeLinearity,v=l.multiplyBy(p/d),y=v.distanceTo([0,0]),b=Math.min(i.inertiaMaxSpeed,y),A=v.multiplyBy(b/y),S=b/(i.inertiaDeceleration*p),R=A.multiplyBy(-S/2).round();!R.x&&!R.y?e.fire("moveend"):(R=e._limitOffset(R,e.options.maxBounds),rt(function(){e.panBy(R,{duration:S,easeLinearity:p,noMoveStart:!0,animate:!0})}))}}});Z.addInitHook("addHandler","dragging",to),Z.mergeOptions({keyboard:!0,keyboardPanDelta:80});var eo=bt.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"),O(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(),W(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,i=t.scrollTop||e.scrollTop,o=t.scrollLeft||e.scrollLeft;this._map._container.focus(),window.scrollTo(o,i)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(t){var e=this._panKeys={},i=this.keyCodes,o,l;for(o=0,l=i.left.length;o<l;o++)e[i.left[o]]=[-1*t,0];for(o=0,l=i.right.length;o<l;o++)e[i.right[o]]=[t,0];for(o=0,l=i.down.length;o<l;o++)e[i.down[o]]=[0,t];for(o=0,l=i.up.length;o<l;o++)e[i.up[o]]=[0,-1*t]},_setZoomDelta:function(t){var e=this._zoomKeys={},i=this.keyCodes,o,l;for(o=0,l=i.zoomIn.length;o<l;o++)e[i.zoomIn[o]]=t;for(o=0,l=i.zoomOut.length;o<l;o++)e[i.zoomOut[o]]=-t},_addHooks:function(){O(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){W(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(t){if(!(t.altKey||t.ctrlKey||t.metaKey)){var e=t.keyCode,i=this._map,o;if(e in this._panKeys){if(!i._panAnim||!i._panAnim._inProgress)if(o=this._panKeys[e],t.shiftKey&&(o=I(o).multiplyBy(3)),i.options.maxBounds&&(o=i._limitOffset(I(o),i.options.maxBounds)),i.options.worldCopyJump){var l=i.wrapLatLng(i.unproject(i.project(i.getCenter()).add(o)));i.panTo(l)}else i.panBy(o)}else if(e in this._zoomKeys)i.setZoom(i.getZoom()+(t.shiftKey?3:1)*this._zoomKeys[e]);else if(e===27&&i._popup&&i._popup.options.closeOnEscapeKey)i.closePopup();else return;Nt(t)}}});Z.addInitHook("addHandler","keyboard",eo),Z.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var io=bt.extend({addHooks:function(){O(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){W(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(t){var e=Mn(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(a(this._performZoom,this),o),Nt(t)},_performZoom:function(){var t=this._map,e=t.getZoom(),i=this._map.options.zoomSnap||0;t._stop();var o=this._delta/(this._map.options.wheelPxPerZoomLevel*4),l=4*Math.log(2/(1+Math.exp(-Math.abs(o))))/Math.LN2,d=i?Math.ceil(l/i)*i:l,p=t._limitZoom(e+(this._delta>0?d:-d))-e;this._delta=0,this._startTime=null,p&&(t.options.scrollWheelZoom==="center"?t.setZoom(e+p):t.setZoomAround(this._lastMousePos,e+p))}});Z.addInitHook("addHandler","scrollWheelZoom",io);var As=600;Z.mergeOptions({tapHold:C.touchNative&&C.safari&&C.mobile,tapTolerance:15});var no=bt.extend({addHooks:function(){O(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){W(this._map._container,"touchstart",this._onDown,this)},_onDown:function(t){if(clearTimeout(this._holdTimeout),t.touches.length===1){var e=t.touches[0];this._startPos=this._newPos=new z(e.clientX,e.clientY),this._holdTimeout=setTimeout(a(function(){this._cancel(),this._isTapValid()&&(O(document,"touchend",ot),O(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",e))},this),As),O(document,"touchend touchcancel contextmenu",this._cancel,this),O(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function t(){W(document,"touchend",ot),W(document,"touchend touchcancel",t)},_cancel:function(){clearTimeout(this._holdTimeout),W(document,"touchend touchcancel contextmenu",this._cancel,this),W(document,"touchmove",this._onMove,this)},_onMove:function(t){var e=t.touches[0];this._newPos=new z(e.clientX,e.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(t,e){var i=new MouseEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:e.screenX,screenY:e.screenY,clientX:e.clientX,clientY:e.clientY});i._simulated=!0,e.target.dispatchEvent(i)}});Z.addInitHook("addHandler","tapHold",no),Z.mergeOptions({touchZoom:C.touch,bounceAtZoomLimits:!0});var oo=bt.extend({addHooks:function(){B(this._map._container,"leaflet-touch-zoom"),O(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){X(this._map._container,"leaflet-touch-zoom"),W(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(t){var e=this._map;if(!(!t.touches||t.touches.length!==2||e._animatingZoom||this._zooming)){var i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]);this._centerPoint=e.getSize()._divideBy(2),this._startLatLng=e.containerPointToLatLng(this._centerPoint),e.options.touchZoom!=="center"&&(this._pinchStartLatLng=e.containerPointToLatLng(i.add(o)._divideBy(2))),this._startDist=i.distanceTo(o),this._startZoom=e.getZoom(),this._moved=!1,this._zooming=!0,e._stop(),O(document,"touchmove",this._onTouchMove,this),O(document,"touchend touchcancel",this._onTouchEnd,this),ot(t)}},_onTouchMove:function(t){if(!(!t.touches||t.touches.length!==2||!this._zooming)){var e=this._map,i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]),l=i.distanceTo(o)/this._startDist;if(this._zoom=e.getScaleZoom(l,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoom<e.getMinZoom()&&l<1||this._zoom>e.getMaxZoom()&&l>1)&&(this._zoom=e._limitZoom(this._zoom)),e.options.touchZoom==="center"){if(this._center=this._startLatLng,l===1)return}else{var d=i._add(o)._divideBy(2)._subtract(this._centerPoint);if(l===1&&d.x===0&&d.y===0)return;this._center=e.unproject(e.project(this._pinchStartLatLng,this._zoom).subtract(d),this._zoom)}this._moved||(e._moveStart(!0,!1),this._moved=!0),at(this._animRequest);var p=a(e._move,e,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=rt(p,this,!0),ot(t)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,at(this._animRequest),W(document,"touchmove",this._onTouchMove,this),W(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))}});Z.addInitHook("addHandler","touchZoom",oo),Z.BoxZoom=Qn,Z.DoubleClickZoom=$n,Z.Drag=to,Z.Keyboard=eo,Z.ScrollWheelZoom=io,Z.TapHold=no,Z.TouchZoom=oo,s.Bounds=Y,s.Browser=C,s.CRS=At,s.Canvas=jn,s.Circle=Ti,s.CircleMarker=Oe,s.Class=pt,s.Control=vt,s.DivIcon=Wn,s.DivOverlay=xt,s.DomEvent=Gr,s.DomUtil=Hr,s.Draggable=Dt,s.Evented=ie,s.FeatureGroup=Mt,s.GeoJSON=Pt,s.GridLayer=pe,s.Handler=bt,s.Icon=qt,s.ImageOverlay=Ze,s.LatLng=G,s.LatLngBounds=ht,s.Layer=yt,s.LayerGroup=Yt,s.LineUtil=is,s.Map=Z,s.Marker=ze,s.Mixin=Kr,s.Path=It,s.Point=z,s.PolyUtil=Xr,s.Polygon=jt,s.Polyline=Et,s.Popup=He,s.PosAnimation=En,s.Projection=ns,s.Rectangle=Xn,s.Renderer=Ct,s.SVG=_e,s.SVGOverlay=Vn,s.TileLayer=Kt,s.Tooltip=Fe,s.Transformation=ii,s.Util=Ae,s.VideoOverlay=Gn,s.bind=a,s.bounds=lt,s.canvas=Jn,s.circle=ds,s.circleMarker=cs,s.control=de,s.divIcon=Ls,s.extend=n,s.featureGroup=as,s.geoJSON=Fn,s.geoJson=ps,s.gridLayer=ws,s.icon=ls,s.imageOverlay=ms,s.latLng=N,s.latLngBounds=$,s.layerGroup=ss,s.map=Vr,s.marker=hs,s.point=I,s.polygon=fs,s.polyline=us,s.popup=vs,s.rectangle=ks,s.setOptions=M,s.stamp=f,s.svg=Kn,s.svgOverlay=gs,s.tileLayer=Yn,s.tooltip=ys,s.transformation=ne,s.version=c,s.videoOverlay=_s;var Ms=window.L;s.noConflict=function(){return window.L=Ms,this},window.L=s}))})(Qt,Qt.exports)),Qt.exports}var Q=Bi();const ve=ut({__proto__:null,default:co(Q)},[Q]),fo='.leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:transparent}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{max-width:none!important;max-height:none!important;width:auto;padding:0}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;-moz-box-sizing:border-box;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-top,.leaflet-bottom{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;-webkit-transition:opacity .2s linear;-moz-transition:opacity .2s linear;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{-webkit-transition:none;-moz-transition:none;transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline-offset:1px}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{border:2px dotted #38f;background:#ffffff80}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:12px;font-size:.75rem;line-height:1.5}.leaflet-bar{box-shadow:0 1px 5px #000000a6;border-radius:4px}.leaflet-bar a{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px #0006;background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block;font-size:13px;font-size:1.08333em}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=)}.leaflet-container .leaflet-control-attribution{background:#fff;background:#fffc;margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{display:inline!important;vertical-align:baseline!important;width:1em;height:.6669em}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;white-space:nowrap;-moz-box-sizing:border-box;box-sizing:border-box;background:#fffc;text-shadow:1px 1px #fff}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 24px 13px 20px;line-height:1.3;font-size:13px;font-size:1.08333em;min-height:1px}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-top:-1px;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;pointer-events:auto;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:#fff;color:#333;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;border:none;text-align:center;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;color:#757575;text-decoration:none;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=.70710678,M12=.70710678,M21=-.70710678,M22=.70710678)}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}',po=`.leaflet-draw-section{position:relative}.leaflet-draw-toolbar{margin-top:12px}.leaflet-draw-toolbar-top{margin-top:0}.leaflet-draw-toolbar-notop a:first-child{border-top-right-radius:0}.leaflet-draw-toolbar-nobottom a:last-child{border-bottom-right-radius:0}.leaflet-draw-toolbar a{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAAeCAYAAACWuCNnAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAG7AAABuwBHnU4NQAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAbvSURBVHic7dtdbBxXFQfw/9nZ3SRKwAP7UFFUQOoHqGnUoEAoNghX9tyxVcpD1X0J+WgiUQmpfUB5ACSgG1qJIKASqBIUIauqAbWseIlqb+bOWHVR6y0FKZBEqdIUQROIREGRx3FFvR/38ODZst3a3nE8Ywfv+T2t7hzdM3fle/bOnWtACCGEEEIIIYQQQgghhBBCCCGEEEIIIcRa0EbfgBDdFItFKwzDAa3175LuWylVAvBIR/MxrXUp6Vxx9dp4VyObVEdKKW591lonXgiVUg6AHzPzk9ls9meVSmUh6RzXkz179uQKhcIgM+8CACI6U6vVnp+enm6knXt4ePiuTCbzWQAwxlSDIHg57ZwroDAMnwKwz3XdBzzPG08hxzsTNprQG2lTjtd13WFmfghAP4A+AJcATFiW9YNKpfL3uP0kUliiX4SG1pqUUpx0wXJd9/PMXAGwPWq6yMyPz8/P/7xarf4nyVwt7QV4JWkU52i8YwBu6bh0wRhzJAiCF5POCQCDg4N2Pp//NYDRjkuTxph9QRCESeYrFov5ubm5R5n5AIAPtV1aYOb7BgYGTpZKJeO67lFmPsbM9/i+/8Ja8y6zylhOYquPXhsvAJRKpczMzMwTAIaJ6LFGo+HNzs5eKRQKNxPRAWb+CoAjWuvn4vS35skWFasxAAdbbUlOYqVUPwAPwI4lLr8J4KeWZT1eqVTmksoZ5d2QghUVKx/AlmVCFph5yPf9l5LMCwBKqUksFqszRHQcAJj5GwB2MfOE7/tfTDKf4zjHiejrAE4CuNhqZ+bf2rY9FYbhGBH92/O8o47j3Oj7/uUk86+3XhsvACilHmPmgW3btn3pxIkTVzuvj4yMfNoY85wxZiQIglPd+lvTZIuq5xiAQwCe6evr218ul5tr6bNd9GiiAbyvS+hFrfVHk8oLbEzBih4Dz+G9K6t3IaLXFhYWdib5eBh911UA8wBu1lq/CQBDQ0M3WJb1OoAdRPQZz/NeSSqnUuofAKpa6/vb26MfwacA7AdwFcCdWuu/JpU3yl1C91VHoquNXhvvyMjIx4wxr1iWtbNSqfxruTjHcR4AcMj3/bu79XnNe1hpFyvHcXYT0QS6FysASHR1tVEKhcIguhQrAGDm23K53BcATCWV27KsAWYGgPOtYgUAU1NT/1RKnQewxxjzOQCJFSwANwI4297QtmLfD+AtZr43m83OJ5iz3bGU+l1OT43XGFNk5mdXKlYAYNv2eBiG31dK3aS1vrRSbOZabqRYLFppFisAIKJxAB+MGf56krk30O64gZlMJnZsHMxsoo8fHxoauqHVHn3+BAAQUaxV57Xq2F54i5nvIaJXm81mYoX5etID491JRH/sFlQul5tEdMoYc3u32FUXrLYvObViBQDM/MQqwi8knX8jEJHpHrXIGJNo8WDm1spph2VZgeu6+5RSX7YsK8D/Xnb8Psmcnebm5h7G4uS9ysxutOH8VQC70sy7UTb7eImImTnWlgkzUyaT6fr3v6qC1fGL8EytVjuQRrECANu2fwHg1TixzPyXNO5hvTHz6VWE/znJ3L7vzxBRa9PzDmb+FYBfArgjajvd39+f9vGGKwACZh5te6mwmc8KburxMvO5TCbzqW5xxWLRArDbsqyu8z32HtZSxSrNM0Hlcrnpum6JmZ+NEb4pHglrtdrz+Xz+AoBbu4Ser9fra37d3YEBfBvAkq+XmfmbpVIp9grwWnie9zSAp9PMcT3Z7OPNZrO/aTQaf1BKfbd9X7RTGIaHmPlcnPNYsVZYSikOw7AB4CAzj/f19e1fjwOMnueVEeMxJJfLbYqCNT093TDGHAGw0qHYBQBH0vj+Pc+bYOb3HFRk5nHf9yeTzgfgMhF9uEvMTQD+71/vR3pqvJOTk28AeBJAeXR09P1LxbiuuxfA9wB8LU6fsVdYrUOhtm0fTusxcAlMRN+KziUt5SqAM3v37r00OZnGfFp/QRC86DjOUCaTGWPm2zoun8fiIbuZtPLX6/UH8/n8rQDuippertfrD6aRKyqOR5VS81ji8Z+IbmfmgwB+mEb+9dZr4wWA/v7+R6rV6k+azeYpx3EezeVyJ7dv335lfn7+lkajcZCZDzPzYd/3/xSnv9gFq3UuaR2LFQDA87xAKVUB8BEAZ6N9nrNEdEZr/TcArLVOPG8aJ9jj8n3/pcHBwZ1btmx5519zmPl0vV5/Ie2V7fT09Nujo6Nus9kcA4CtW7ce1lq/nUYu27a/Mzs7CyI6gMVX/u/CzJeZ+Ue2bcc9pb1aXc8lJZms18YLANE2wkOu694N4OFGo3E8DMMPAHiDiCaY+ZOb4YCsEEIIIYQQQgghhBBCCCGEEEIIIYQQQgghhEjYfwGO+b5dFNs4OgAAAABJRU5ErkJggg==);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3csvg%20xmlns:dc='http://purl.org/dc/elements/1.1/'%20xmlns:cc='http://creativecommons.org/ns%23'%20xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23'%20xmlns:svg='http://www.w3.org/2000/svg'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd'%20xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape'%20viewBox='0%200%20600%2060'%20height='60'%20width='600'%20id='svg4225'%20version='1.1'%20inkscape:version='0.91%20r13725'%20sodipodi:docname='spritesheet.svg'%20inkscape:export-filename='/home/fpuga/development/upstream/icarto.Leaflet.draw/src/images/spritesheet-2x.png'%20inkscape:export-xdpi='90'%20inkscape:export-ydpi='90'%3e%3cmetadata%20id='metadata4258'%3e%3crdf:RDF%3e%3ccc:Work%20rdf:about=''%3e%3cdc:format%3eimage/svg+xml%3c/dc:format%3e%3cdc:type%20rdf:resource='http://purl.org/dc/dcmitype/StillImage'%20/%3e%3cdc:title%20/%3e%3c/cc:Work%3e%3c/rdf:RDF%3e%3c/metadata%3e%3cdefs%20id='defs4256'%20/%3e%3csodipodi:namedview%20pagecolor='%23ffffff'%20bordercolor='%23666666'%20borderopacity='1'%20objecttolerance='10'%20gridtolerance='10'%20guidetolerance='10'%20inkscape:pageopacity='0'%20inkscape:pageshadow='2'%20inkscape:window-width='1920'%20inkscape:window-height='1056'%20id='namedview4254'%20showgrid='false'%20inkscape:zoom='1.3101852'%20inkscape:cx='237.56928'%20inkscape:cy='7.2419621'%20inkscape:window-x='1920'%20inkscape:window-y='24'%20inkscape:window-maximized='1'%20inkscape:current-layer='svg4225'%20/%3e%3cg%20id='enabled'%20style='fill:%23464646;fill-opacity:1'%3e%3cg%20id='polyline'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%2018,36%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4229'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2036,18%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4231'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2023.142,39.145%20-2.285,-2.29%2016,-15.998%202.285,2.285%20z'%20id='path4233'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cpath%20id='polygon'%20d='M%20100,24.565%2097.904,39.395%2083.07,42%2076,28.773%2086.463,18%20Z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='rectangle'%20d='m%20140,20%2020,0%200,20%20-20,0%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='circle'%20d='m%20221,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='marker'%20d='m%20270,19%20c%20-4.971,0%20-9,4.029%20-9,9%200,4.971%205.001,12%209,14%204.001,-2%209,-9.029%209,-14%200,-4.971%20-4.029,-9%20-9,-9%20z%20m%200,12.5%20c%20-2.484,0%20-4.5,-2.014%20-4.5,-4.5%200,-2.484%202.016,-4.5%204.5,-4.5%202.485,0%204.5,2.016%204.5,4.5%200,2.486%20-2.015,4.5%20-4.5,4.5%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cg%20id='edit'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20337,30.156%200,0.407%200,5.604%20c%200,1.658%20-1.344,3%20-3,3%20l%20-10,0%20c%20-1.655,0%20-3,-1.342%20-3,-3%20l%200,-10%20c%200,-1.657%201.345,-3%203,-3%20l%206.345,0%203.19,-3.17%20-9.535,0%20c%20-3.313,0%20-6,2.687%20-6,6%20l%200,10%20c%200,3.313%202.687,6%206,6%20l%2010,0%20c%203.314,0%206,-2.687%206,-6%20l%200,-8.809%20-3,2.968'%20id='path4240'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.72,24.637%20-8.892,8.892%20-2.828,0%200,-2.829%208.89,-8.89%20z'%20id='path4242'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.697,17.826%204,0%200,4%20-4,0%20z'%20transform='matrix(-0.70698336,-0.70723018,0.70723018,-0.70698336,567.55917,274.78273)'%20id='path4244'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cg%20id='remove'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20381,42%2018,0%200,-18%20-18,0%200,18%20z%20m%2014,-16%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z'%20id='path4247'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20395,20%200,-4%20-10,0%200,4%20-6,0%200,2%2022,0%200,-2%20-6,0%20z%20m%20-2,0%20-6,0%200,-2%206,0%200,2%20z'%20id='path4249'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3c/g%3e%3cg%20id='disabled'%20transform='translate(120,0)'%20style='fill:%23bbbbbb'%3e%3cuse%20xlink:href='%23edit'%20id='edit-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3cuse%20xlink:href='%23remove'%20id='remove-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3c/g%3e%3cpath%20style='fill:none;stroke:%23464646;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1'%20id='circle-3'%20d='m%20581.65725,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:300px 30px;background-clip:padding-box}.leaflet-retina .leaflet-draw-toolbar a{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAlgAAAA8CAYAAAC6nMS5AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAA16SURBVHic7d1/jBxneQfw7zNzvotdn+9sVQkxoRKoammBqqpbk6uT5mLfvHPn42yn1VFRVCEhoFH5IYpoSaUCKi1NcGkcfrbCVRFKEwG2aHLn83pmLvY2CTqT1AmCOBE0EOT4B0nBPw/snb2dp3/sLr6s77i923dud/a+H8ny7tzMo8f3eud99p133gGIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiFYGaXYCRETUPMYYrWe/MAzZX2QQ27d5OpqdABFROxgZGVlz5cqVrzuOc18QBJPNzofsYvvSYrVcgTVftZ2l6npgYODXHMc5oKoHHcfZHQTB2WbnRETpGRkZWVMoFA6IyO2qutX3/R1Z64TnO8fWOwLSzti+mSKDg4M3l0qlnSJyG4CbAFwP4ByAlwE8paoPX3fddcH4+PjP00yk5QqsrDPGvAZAHsBrReRNqvpeY8x/iMg9QRCcaXJ6ZIHv+xtUdReAHQBej/IHGABOAnhORMY6OjoempiYONe0JC3zPM84jjOqqrfi6r/3RQCPAdgXhmHUvOyaa3R01L1w4cJBALdVNq1W1THP87woir7ZzNyocWzf7PA8b4uI7E6S5A9Frqknb6j8eZOIvKNQKPzU9/1/dhznvlwuV0gjn5YbFapW09Vqu/Z9K9u2bdsNruvmUe50axUAfMV13X/I5XInlzcze2x/28lCu1b19fWt7u7u/hCAvwGwboHdL6jq7unp6T1TU1OXlyG9VAwODv5mkiR7Ady6wK6Plkqldz/yyCPfX468bBkaGuqamZm5E8DbReQNANYscMiLIrI1CILnZ280xrwHwL+hck4VkacBDLTS6HVaIxWt/Blm+zauldu3atOmTas2bNjwWRG5s7LplKp+VUQOuq77/bVr17589uzZ9SKy0XGcAVUdFZE/qOx7zHXdXWn0yy31i6sMw/4MyF6BZYy5XlWPiMhvL7BrrKpfcxznE7Uf4ixYqQWW53kbATw060NZr28nSbJzcnLyRBp5pcnzvNtE5CEAvXUecg7ArjAMH00xLWuGhoZuKpVKEwB+p85DXnRd9/ZcLvcDAOjv778un88XAChwtRMWkW+jxTpfYOV1wGxfO1q1fav6+vpWr1u3blxVtwH4uar+/fT09OcW+mJrjBkBcC+AXwdwBoAJw/AZm7m1zC+uUlyNA9g6189buZH7+/t/tbOz8wiANy7isKKqftV13U8eOnToe2nlZttKLLAqJ+qjAF69xBAnZ2Zmbj58+PApm3mlqTJydRTXFldHAUxVXvcBuLnm5+dU9c1RFP1v2jk2YmhoqKtUKj2B+jvfE0mS3D45OflD4OqcHADPh2H4F6h0wp7nva1YLOby+fz5dDKnerB9Vwzxff8BVX0bgFMAdoZheKzeg4eHh9cXi8WvAfAAvOC67ptzudz/WUvOVqBGVO7OmBCR/vn2adWOuL+/v7ezs3MSwKYlhkgAHBSRjwdB8JTF1FKx0gqsymXBxwH8XoOh/ieO41vz+fwVG3mlzRjzKF55WfA8gD8LwzA3ez/P87aLyIMAeqrbVDUfRdHty5Pp0hhjPgDgM9X3qnq/iNwPYM5RCdd1T1RPvLM63+q/ce/sTpiaj+27Mvi+f6eq/iuAi67r9uVyuWcXG6NSjB8B0KeqE1EUvcVWfk3v3OYZuXosjuPt+Xx+ull51WNgYKBHRKIlXDaaS6Kq+6Mo+lMLsVKz0gosz/M+KiKfsBTub8MwvMdSrNQYYzwAYc3m7bXFVZXv+8OqemD2NlUdiKLokbRybJQx5lsANlfefi4Mww/UedyvADgI4I9mbxeRDwdB8C92s0yHrc9wK3922b6Na+X2BYD+/v61nZ2dz6M8cX00DMP9S421ffv2V83MzDwHoNfmucuxEWSpslxcjYyMrHEcZ8xScQUAjoj8vqVYZIHv+xtE5MMWQ941PDy83mK8VIjIW2s2HZ2vuAKAIAgmADyxQIxWM3uu5J56DhgZGVkDYBw1nS+ApwB82VJeZAfbt82tWrXqPSgXV481UlwBwMGDB3+sqncDgIh81EZ+QBMLrKwXV5Uh5NoPYqMyN+m9nanqHVj4bsHF6InjeKfFeKmoLMUw+/2Ct6KLyOM1m2x/NmxbW30RhuGPFtp5jstGVU+JiNdqE57rEYahzB6lWOz7Fsf2be/2hYj8SeXlvTbiFYvFLwK4DOAWY8z1NmI2pcDKcnE1OjraWSgU9uPaD2LDRKSlJwavQCO2A4rIDtsxU7BxsQeoau2Jeak3BDTDL72kUm/n63neaFoJUkPYvm3G9/0NKN9gc7mrq6t2OsOSVGqPSQCuiAzaiLnsBVaWiysAuHDhwn4AQ2nEVtUfpBGXluwNKcRcaBmPVpDMfiMiW+o4pnafZM69MmYxnW9lsj9lCNs3m1T1tSjXL89aXo39WCX+62wEW9YCK+vFVcXLKcbmJcLW8qoUYmZhZOfFmvc3e563fb6djTFvwdUJxfPFyJx6O1/f999a6Xz5ZIwMYftm2o2Vv60+HUVETldeLnoUfy7LVmC1SXEFVf0YgFSeX5QkCQus9tfyIzsicnSObQ/6vj9cu71SXP1nPTGyplAo5FDT+arqk3Ecb5s9J0dV2flmENs3u0REgTmnJjRkVjwrd2Iuy3+adimuACCKotPGmC8A+GvLoZOZmZkXLMekBojIaVX9DcthTy+8S3MlSTIuIu+q2dyjqgeMMU8A+CYAUdUtAOa8izZJkvG081wG19xN5jjO4ByLTLrLlRBZxfbNrjMAICI3LrTjIlVHrqyMjKU+gtVOxVVVHMf/hHkWrGvAiawsQrlSqOqiF61rRkzbOjo6AsxfCG4G8FcAPvhLlih5qVgsWpl42kIyezcZ1YXtmy0/QvlqwG9V1i6zZRMAiIiV+dCpFljtWFwBQOUbzqcth+XlwdZjfRRGRMZsx7St8mT5zzcQ4r52+LKgqp9S1U8B+GTtZSPKPrZvdlXaagrAalU1NmJWCrVtAEqO4xyyETO1S4TtWlxVXbp06b7u7u6/BHCTjXiqygKrxYjIQ6p6L2Y9BqZB51etWtXyBRYAuK77hVKp9H5cnUxarzOu634xjZyWWxRFdzU7B0oP2zfbVPUbIrLFcZwPAfivRuOJyPtUdbWq5m09jzCVEax2L64AYGpq6rKq/qOteI7jsMBqMUEQnFXV3bbiqerdExMT52zFS1Mul7soIovugETkI7lc7mIaORERVRWLxS8BeElVb/F9v6EnR/i+f6Oq3gUAjuPYejSavQLLGKPVP4VC4Wd4ZXF1pKura7Bdiquq3t7efwfwnKVwLLBa0PT09B5U1kZp0BPFYvGzFuIsmyAI7kf5uWz1OhgEwTV3FLaoX5yLKosWLknNsZcayohsYvu2uUo98TEAUNW9vu8vad3CoaGhLlX9BoBeAONBEByxleNyLNPwWBzHOywvBtYS9u3bV1LVj1sKxwKrBU1NTV12XXcXgFMNhDmpqndkcF6SisifAzhRx76n4jh+Byzd3rwMjldfqOqSV+xPkmT2yvzH592RlhvbdwUIw3AvgAcArFPVcHBwcFHPBvZ9f0OpVDqA8qrwL8Rx/E6b+VkvsGqfZ9ROlwXnEkXRfgDfajCMXrx48Yc28iH7crncSVXdrKpPLvZYEXk6SZItURS1/PIMcwmC4KzjOCMAam9dn+0SgJ35fP4ny5SWDQ/Mer3HGLPoTtgYMyIiv3gOmqpmZfRuJWD7rgwax/G7UH7EzcYkSf7bGHNXX1/f6oUO9H1/Z+WcPoDysgw7bJ/DUl8Hq52LqwoVkb9T1WiRx8UoX158RlWfnJqaupxCbmRJFEWn+/r6buvu7v4ggI9g4Ynv50XknkKh8JkMjly9wqFDh77j+/6oqo4BqD1xXRaRPw6CwMZl1GXjuu6XSqXSOwH8LoD1AMaMMecA1PtF53WV4wCUC+menp699jOlpWD7rhz5fP5Kf3//UFdX132q+l4Ad3d3d7/fGPN1EZlQ1e/19PS8dPbs2fWu694kIgOqOqqqm4Dy4rKlUumOw4cPN3KVYk7WVkE1xsx5aSBLT+duhDEmQrkSnssZlIeXnxWRY6p6PI7j41nveFeq4eHh9XEc7xSRnQBej6t3kp5EuWh+OI7jh+dYsDDTfN/frKrjAKpPmv9pkiS7JicnH29mXku1devWV3d0dBxAuRNeMhF5ulgsjqRxgk7DfOfqxWr1czvbtzGt3r5zGRwc7FPV3ap6y0L7ishPAHx63bp1e/bt2xenkQ8LLEuMMZtE5JCqfhfAMwCeSZLkO2vWrDk+NjbGyZHUFjzP2yginwcAVX1fVi99Vo2OjnaeP3/+3SLydgBvBNBd56GXAHxXVR/s7e3dm9YJOg0rqQNm+y5dFtp3HmKM2QxgF8qr9b8GwA0AzgH4MYBjIjJ28eLFkFeOiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIhWgv8Hnffz4dmwY9cAAAAASUVORK5CYII=);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3csvg%20xmlns:dc='http://purl.org/dc/elements/1.1/'%20xmlns:cc='http://creativecommons.org/ns%23'%20xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23'%20xmlns:svg='http://www.w3.org/2000/svg'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd'%20xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape'%20viewBox='0%200%20600%2060'%20height='60'%20width='600'%20id='svg4225'%20version='1.1'%20inkscape:version='0.91%20r13725'%20sodipodi:docname='spritesheet.svg'%20inkscape:export-filename='/home/fpuga/development/upstream/icarto.Leaflet.draw/src/images/spritesheet-2x.png'%20inkscape:export-xdpi='90'%20inkscape:export-ydpi='90'%3e%3cmetadata%20id='metadata4258'%3e%3crdf:RDF%3e%3ccc:Work%20rdf:about=''%3e%3cdc:format%3eimage/svg+xml%3c/dc:format%3e%3cdc:type%20rdf:resource='http://purl.org/dc/dcmitype/StillImage'%20/%3e%3cdc:title%20/%3e%3c/cc:Work%3e%3c/rdf:RDF%3e%3c/metadata%3e%3cdefs%20id='defs4256'%20/%3e%3csodipodi:namedview%20pagecolor='%23ffffff'%20bordercolor='%23666666'%20borderopacity='1'%20objecttolerance='10'%20gridtolerance='10'%20guidetolerance='10'%20inkscape:pageopacity='0'%20inkscape:pageshadow='2'%20inkscape:window-width='1920'%20inkscape:window-height='1056'%20id='namedview4254'%20showgrid='false'%20inkscape:zoom='1.3101852'%20inkscape:cx='237.56928'%20inkscape:cy='7.2419621'%20inkscape:window-x='1920'%20inkscape:window-y='24'%20inkscape:window-maximized='1'%20inkscape:current-layer='svg4225'%20/%3e%3cg%20id='enabled'%20style='fill:%23464646;fill-opacity:1'%3e%3cg%20id='polyline'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%2018,36%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4229'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2036,18%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4231'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2023.142,39.145%20-2.285,-2.29%2016,-15.998%202.285,2.285%20z'%20id='path4233'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cpath%20id='polygon'%20d='M%20100,24.565%2097.904,39.395%2083.07,42%2076,28.773%2086.463,18%20Z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='rectangle'%20d='m%20140,20%2020,0%200,20%20-20,0%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='circle'%20d='m%20221,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='marker'%20d='m%20270,19%20c%20-4.971,0%20-9,4.029%20-9,9%200,4.971%205.001,12%209,14%204.001,-2%209,-9.029%209,-14%200,-4.971%20-4.029,-9%20-9,-9%20z%20m%200,12.5%20c%20-2.484,0%20-4.5,-2.014%20-4.5,-4.5%200,-2.484%202.016,-4.5%204.5,-4.5%202.485,0%204.5,2.016%204.5,4.5%200,2.486%20-2.015,4.5%20-4.5,4.5%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cg%20id='edit'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20337,30.156%200,0.407%200,5.604%20c%200,1.658%20-1.344,3%20-3,3%20l%20-10,0%20c%20-1.655,0%20-3,-1.342%20-3,-3%20l%200,-10%20c%200,-1.657%201.345,-3%203,-3%20l%206.345,0%203.19,-3.17%20-9.535,0%20c%20-3.313,0%20-6,2.687%20-6,6%20l%200,10%20c%200,3.313%202.687,6%206,6%20l%2010,0%20c%203.314,0%206,-2.687%206,-6%20l%200,-8.809%20-3,2.968'%20id='path4240'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.72,24.637%20-8.892,8.892%20-2.828,0%200,-2.829%208.89,-8.89%20z'%20id='path4242'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.697,17.826%204,0%200,4%20-4,0%20z'%20transform='matrix(-0.70698336,-0.70723018,0.70723018,-0.70698336,567.55917,274.78273)'%20id='path4244'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cg%20id='remove'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20381,42%2018,0%200,-18%20-18,0%200,18%20z%20m%2014,-16%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z'%20id='path4247'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20395,20%200,-4%20-10,0%200,4%20-6,0%200,2%2022,0%200,-2%20-6,0%20z%20m%20-2,0%20-6,0%200,-2%206,0%200,2%20z'%20id='path4249'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3c/g%3e%3cg%20id='disabled'%20transform='translate(120,0)'%20style='fill:%23bbbbbb'%3e%3cuse%20xlink:href='%23edit'%20id='edit-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3cuse%20xlink:href='%23remove'%20id='remove-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3c/g%3e%3cpath%20style='fill:none;stroke:%23464646;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1'%20id='circle-3'%20d='m%20581.65725,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20/%3e%3c/svg%3e")}.leaflet-draw a{display:block;text-align:center;text-decoration:none}.leaflet-draw a .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.leaflet-draw-actions{display:none;list-style:none;margin:0;padding:0;position:absolute;left:26px;top:0;white-space:nowrap}.leaflet-touch .leaflet-draw-actions{left:32px}.leaflet-right .leaflet-draw-actions{right:26px;left:auto}.leaflet-touch .leaflet-right .leaflet-draw-actions{right:32px;left:auto}.leaflet-draw-actions li{display:inline-block}.leaflet-draw-actions li:first-child a{border-left:0}.leaflet-draw-actions li:last-child a{-webkit-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.leaflet-right .leaflet-draw-actions li:last-child a{-webkit-border-radius:0;border-radius:0}.leaflet-right .leaflet-draw-actions li:first-child a{-webkit-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.leaflet-draw-actions a{background-color:#919187;border-left:1px solid #AAA;color:#fff;font:11px/19px Helvetica Neue,Arial,Helvetica,sans-serif;line-height:28px;text-decoration:none;padding-left:10px;padding-right:10px;height:28px}.leaflet-touch .leaflet-draw-actions a{font-size:12px;line-height:30px;height:30px}.leaflet-draw-actions-bottom{margin-top:0}.leaflet-draw-actions-top{margin-top:1px}.leaflet-draw-actions-top a,.leaflet-draw-actions-bottom a{height:27px;line-height:27px}.leaflet-draw-actions a:hover{background-color:#a0a098}.leaflet-draw-actions-top.leaflet-draw-actions-bottom a{height:26px;line-height:26px}.leaflet-draw-toolbar .leaflet-draw-draw-polyline{background-position:-2px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-polyline{background-position:0 -1px}.leaflet-draw-toolbar .leaflet-draw-draw-polygon{background-position:-31px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-polygon{background-position:-29px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-rectangle{background-position:-62px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-rectangle{background-position:-60px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-circle{background-position:-92px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-circle{background-position:-90px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-marker{background-position:-122px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-marker{background-position:-120px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-circlemarker{background-position:-273px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-circlemarker{background-position:-271px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-edit{background-position:-152px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-edit{background-position:-150px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-remove{background-position:-182px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-remove{background-position:-180px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-edit.leaflet-disabled{background-position:-212px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-edit.leaflet-disabled{background-position:-210px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-remove.leaflet-disabled{background-position:-242px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-remove.leaflet-disabled{background-position:-240px -2px}.leaflet-mouse-marker{background-color:#fff;cursor:crosshair}.leaflet-draw-tooltip{background:#363636;background:#00000080;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px;color:#fff;font:12px/18px Helvetica Neue,Arial,Helvetica,sans-serif;margin-left:20px;margin-top:-21px;padding:4px 8px;position:absolute;visibility:hidden;white-space:nowrap;z-index:6}.leaflet-draw-tooltip:before{border-right:6px solid black;border-right-color:#00000080;border-top:6px solid transparent;border-bottom:6px solid transparent;content:"";position:absolute;top:7px;left:-7px}.leaflet-error-draw-tooltip{background-color:#f2dede;border:1px solid #e6b6bd;color:#b94a48}.leaflet-error-draw-tooltip:before{border-right-color:#e6b6bd}.leaflet-draw-tooltip-single{margin-top:-12px}.leaflet-draw-tooltip-subtext{color:#f8d5e4}.leaflet-draw-guide-dash{font-size:1%;opacity:.6;position:absolute;width:5px;height:5px}.leaflet-edit-marker-selected{background-color:#fe57a11a;border:4px dashed rgba(254,87,161,.6);-webkit-border-radius:4px;border-radius:4px;box-sizing:content-box}.leaflet-edit-move{cursor:move}.leaflet-edit-resize{cursor:pointer}.leaflet-oldie .leaflet-draw-toolbar{border:1px solid #999}`,mo=".leaflet-ruler{height:35px;width:35px;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAQAAABKfvVzAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QAAKqNIzIAAAAJcEhZcwAADdcAAA3XAUIom3gAAAAHdElNRQfhBQoMHg6McuYvAAABwklEQVQ4y43TP0jUYRgH8M/daQpqdujhnwShGiwyipCIoIgWxyIwrqEhnCQoGqKhpoYMg1qCQjg8TC2JCtSkjCgaKisIhyQUwpJssD9KZWRZg6d450/yGV54n/fzfd53eUOCaoNa5QpNGNPr9cKjUAatdsB++co0G1XiiHd+uqnTq8VzI874o9s2Ic1iiEpii9tmnJOdfkOldt/dU+HYolHnjdmpRNzbuVaNL86m4sXqNOrz3kMXHFKYMqd8VREGBToMifqLgwY1yNZirya5knaBqH16fJjNJiWEFSlxy4g980+pMuZkir/UJjLbrvNRPnINaLUygK/yQpuImHp47LOjuKJPOJA/1y4iZsAlyozLs8IO42L/4QlhGrSCy5oCeKH+dM59vVbL9sn6AP5MRzpnVKtN1viRxit1WRvEmVKFrQbTpoddNR3E+aYKuw1lPOapa0GcEf22KzOtejmcG1rkYdjEAn59KU5cDzjt+HI4BSZtVJTazfIsMQOmFAusLr/E53lniickJYIDNcaUL+JhMZPWBUdOeCCaweGOw5k0lFrv2uyRuBxPlLpoBtTK0p3mh+f+dKl6jX6LapRj6XrzD+1bmkFA/dTVAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE3LTA1LTEwVDEyOjMwOjE0KzAyOjAwUNH5TAAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNy0wNS0xMFQxMjozMDoxNCswMjowMCGMQfAAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC);background-repeat:no-repeat;background-position:center}.leaflet-ruler:hover{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=)}.leaflet-ruler-clicked{height:35px;width:35px;background-repeat:no-repeat;background-position:center;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=);border-color:#7fff00!important}.leaflet-bar{background-color:#fff}.leaflet-control{cursor:pointer}.result-tooltip{background-color:#fff;border-width:medium;border-color:#de0000;font-size:smaller}.moving-tooltip{background-color:#ffffffb3;background-clip:padding-box;opacity:.5;border:dotted;border-color:red;font-size:smaller}.plus-length{padding-left:45px}",_o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAMAAAAhFXfZAAAC91BMVEVMaXEzeak2f7I4g7g3g7cua5gzeKg8hJo3grY4g7c3grU0gLI2frE0daAubJc2gbQwd6QzeKk2gLMtd5sxdKIua5g1frA2f7IydaM0e6w2fq41fK01eqo3grgubJgta5cxdKI1f7AydaQydaMxc6EubJgvbJkwcZ4ubZkwcJwubZgubJcydqUydKIxapgubJctbJcubZcubJcvbJYubJcvbZkubJctbJctbZcubJg2f7AubJcrbZcubJcubJcua5g3grY0fq8ubJcubJdEkdEwhsw6i88vhswuhcsuhMtBjMgthMsrg8srgss6is8qgcs8i9A9iMYtg8spgcoogMo7hcMngMonf8olfso4gr8kfck5iM8jfMk4iM8he8k1fro7itAgesk2hs8eecgzfLcofssdeMg0hc4cd8g2hcsxeLQbdsgZdcgxeLImfcszhM0vda4xgckzhM4xg84wf8Yxgs4udKsvfcQucqhUndROmdM1fK0wcZ8vb5w0eqpQm9MzeKhXoNVcpdYydKNWn9VZotVKltJFjsIwcJ1Rms9OlslLmtH///8+kc9epdYzd6dbo9VHkMM2f7FHmNBClM8ydqVcpNY9hro3gLM9hLczealQmcw3fa46f7A8gLMxc6I3eagyc6FIldJMl9JSnNRSntNNl9JPnNJFi75UnM9ZodVKksg8kM45jc09e6ZHltFBk883gbRBh7pDk9EwcaBzn784g7dKkcY2i81Om9M7j85Llc81is09g7Q4grY/j9A0eqxKmdFFltBEjcXf6fFImdBCiLxJl9FGlNFBi78yiMxVndEvbpo6js74+vx+psPP3+o/ks5HkcpGmNCjwdZCkNDM3ehYoNJEls+lxNkxh8xHks0+jdC1zd5Lg6r+/v/H2ufz9/o3jM3t8/edvdM/k89Th61OiLBSjbZklbaTt9BfptdjmL1AicBHj8hGk9FAgK1dkLNTjLRekrdClc/k7fM0icy0y9tgp9c4jc2NtM9Dlc8zicxeXZn3AAAAQ3RSTlMAHDdTb4yPA+LtnEQmC4L2EmHqB7XA0d0sr478x4/Yd5i1zOfyPkf1sLVq4Nh3FvjxopQ2/STNuFzUwFIwxKaejILpIBEV9wAABhVJREFUeF6s1NdyFEcYBeBeoQIhRAkLlRDGrhIgY3BJL8CVeKzuyXFzzjkn5ZxzzuScg3PO8cKzu70JkO0LfxdTU//pM9vTu7Xgf6KqOVTb9X7toRrVEfBf1HTVjZccrT/2by1VV928Yty9ZbVuucdz90frG8DBjl9pVApbOstvmMuvVgaNXSfAAd6pGxpy6yxf5ph43pS/4f3uoaGm2rdu72S9xzOvMymkZFq/ptDrk90mhW7e4zl7HLzhxGWPR20xmSxJ/VqldG5m9XhaVOA1DadsNh3Pu5L2N6QtPO/32JpqQBVVk20oy/Pi2s23WEvyfHbe1thadVQttvm7Llf65gGmXK67XtupyoM7HQhmXdLS8oGWJNeOJ3C5fG5XCEJnkez3/oFdsvgJ4l2ANZwhrJKk/7OSXa+3Vw2WJMlKnGkobouYk6T0TyX30klOUnTD9HJ5qpckL3EW/w4XF3Xd0FGywXUrstrclVsqz5Pd/sXFYyDnPdrLcQODmGOK47IZb4CmibmMn+MYRzFZ5jg33ZL/EJrWcszHmANy3ARBK/IXtciJy8VsitPSdE3uuHxzougojcUdr8/32atnz/ev3f/K5wtpxUTpcaI45zusVDpYtZi+jg0oU9b3x74h7+n9ABvYEZeKaVq0sh0AtLKsFtqNBdeT0MrSzwwlq9+x6xAO4tgOtSzbCjrNQQiNvQUbUEubvzBUeGw26yDCsRHCoLkTHDa7IdOLIThs/gHvChszh2CimE8peRs47cxANI0lYNB5y1DljpOF0IhzBDPOZnDOqYYbeGKECbPzWnXludPphw5c2YBq5zlwXphIbO4VDCZ0gnPfUO1TwZoYwAs2ExPCedAu9DAjfQUjzITQb3jNj0KG2Sgt6BHaQUdYzWz+XmBktOHwanXjaSTcwwziBcuMOtwBmqPrTOxFQR/DRKKPqyur0aiW6cULYsx6tBm0jXpR/AUWR6HRq9WVW6MRhIq5jLyjbaCTDCijyYJNpCajdyobP/eTw0iexBAKkJ3gA5KcQb2zBXsIBckn+xVv8jkZSaEFHE+jFEleAEfayRU0MouNoBmB/L50Ai/HSLIHxcrpCvnhSQAuakKp2C/YbCylJjXRVy/z3+Kv/RrNcCo+WUzlVEhzKffnTQnxeN9fWF88fiNCUdSTsaufaChKWInHeysygfpIqagoakW+vV20J8uyl6TyNKEZWV4oRSPyCkWpgOLSbkCObT8o2r6tlG58HQquf6O0v50tB7JM7F4EORd2dx/K0w/KHsVkLPaoYrwgP/y7krr3SSMA4zj+OBgmjYkxcdIJQyQRKgg2viX9Hddi9UBb29LrKR7CVVEEEXWojUkXNyfTNDE14W9gbHJNuhjDettN3ZvbOvdOqCD3Jp/9l+/wJE+9PkYGjx/fqkys3S2rMozM/o2106rfMUINo6hVqz+eu/hd1c4xTg0TAfy5kV+4UG6+IthHTU9woWmxuKNbTfuCSfovBCxq7EtHqvYL4Sm6F8GVxsSXHMQ07TOi1DKtZxjWaaIyi4CXWjxPccUw8WVbMYY5wxC1mzEyXMJWkllpRloi+Kkoq69sxBTlElF6aAxYUbjXNlhlDZilDnM4U5SlN5biRsRHnbx3mbeWjEh4mEyiuJDl5XcWVmX5GvNkFgLWZM5qwsop4/AWfLhU1cR7k1VVvcYCWRkOI6Xy5gmnphCYIkvzuNYzHzosq2oNk2RtSs8khfUOfHIDgR6ysYBaMpl4uEgk2U/oJTs9AaTSwma7dT69geAE2ZpEjUsn2ieJNHeKfrI3EcAGJ2ZaNgVuC8EBctCLc57P5u5led6IOBkIYkuQMrmmjChs4VkfOerHqSBkPzZlhe06RslZ3zMjk2sscqKwY0RcjKK+LWbzd7KiHhkncs/siFJ+V5eXxD34B8nVuJEpGJNmxN2gH3vSvp7J70tF+D1Ej8qUJD1TkErAND2GZwTFg/LubvmgiBG3SOvdlsqFQrkEzJCL1rstlnVFROixZoDDSuXQFHESwVGlcuQcMb/b42NgjLowh5MTDFE3vNB5qStRIErdCQEh6pLPR92anSUb/wAIhldAaDMpGgAAAABJRU5ErkJggg==",go="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=",vo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC",yo="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='430'%20height='430'%20style='width:100%25;height:100%25;transform:translate3d(0,0,0);content-visibility:visible'%20viewBox='0%200%20430%20430'%3e%3cdefs%3e%3cclipPath%20id='i'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='s'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='e'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='p'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='f'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='m'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='g'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='j'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='h'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cfilter%20id='t'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cfilter%20id='r'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'%20stdDeviation='52.5%2052.5'/%3e%3c/filter%3e%3cfilter%20id='n'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cfilter%20id='k'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cmask%20id='u'%20mask-type='alpha'%3e%3cuse%20xmlns:ns1='http://www.w3.org/1999/xlink'%20ns1:href='%23a'/%3e%3c/mask%3e%3cmask%20id='q'%20mask-type='alpha'%3e%3cuse%20xmlns:ns2='http://www.w3.org/1999/xlink'%20ns2:href='%23b'/%3e%3c/mask%3e%3cmask%20id='o'%20mask-type='alpha'%3e%3cuse%20xmlns:ns3='http://www.w3.org/1999/xlink'%20ns3:href='%23c'/%3e%3c/mask%3e%3cmask%20id='l'%20mask-type='alpha'%3e%3cuse%20xmlns:ns4='http://www.w3.org/1999/xlink'%20ns4:href='%23d'/%3e%3c/mask%3e%3cg%20id='a'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23e)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3cg%20id='b'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='12'%20clip-path='url(%23f)'%20style='display:block'%3e%3cpath%20stroke='%2308A88A'%20d='M44.446-66.518a79.998%2079.998%200%200%200-101.012%209.952A79.998%2079.998%200%201%200%2056.569%2056.569%2080.005%2080.005%200%200%200%2073.91-30.615a80.001%2080.001%200%200%200-29.464-35.903z'%20class='secondary'%20style='display:block'%20transform='translate(215%20214)'/%3e%3cpath%20stroke='%23121331'%20d='m141.409%2025.241%208.727%205.041s0%200%200%200a22.3%2022.3%200%200%201%2010.411%2013.542%2022.32%2022.32%200%200%201-2.221%2016.937l-26.515%2045.924a22.325%2022.325%200%200%201-30.497%208.172l-8.754-5.059a143.414%20143.414%200%200%201-43.718%2025.286v10.108a22.302%2022.302%200%200%201-13.778%2020.612%2022.303%2022.303%200%200%201-8.539%201.696h-53.029a22.303%2022.303%200%200%201-15.779-6.531%2022.302%2022.302%200%200%201-6.537-15.777v-10.073a143.416%20143.416%200%200%201-43.719-25.285l-8.754%205.059a22.325%2022.325%200%200%201-30.497-8.172l-26.523-45.924a22.315%2022.315%200%200%201-2.238-16.943A22.31%2022.31%200%200%201-150.142%2030.3l8.727-5.041a145.097%20145.097%200%200%201%200-50.518l-8.727-5.041a22.294%2022.294%200%200%201-10.409-13.554%2022.306%2022.306%200%200%201%202.238-16.943l26.514-45.924a22.325%2022.325%200%200%201%2030.497-8.172l8.754%205.059a143.416%20143.416%200%200%201%2043.719-25.285v-10.073a22.302%2022.302%200%200%201%206.537-15.777%2022.3%2022.3%200%200%201%2015.779-6.531h53.02a22.307%2022.307%200%200%201%2022.317%2022.308v10.037a143.41%20143.41%200%200%201%2043.718%2025.285l8.754-5.059a22.325%2022.325%200%200%201%2030.497%208.172l26.515%2045.942a22.313%2022.313%200%200%201-1.618%2024.757%2022.294%2022.294%200%200%201-6.554%205.74l-8.727%205.041a145.097%20145.097%200%200%201%200%2050.518z'%20class='primary'%20style='display:block'%20transform='rotate(-120%20169.576%2045.095)'/%3e%3c/g%3e%3cg%20id='c'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23g)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3cg%20id='d'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23h)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3c/defs%3e%3cg%20clip-path='url(%23i)'%3e%3cg%20clip-path='url(%23j)'%20filter='url(%23k)'%20mask='url(%23l)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23m)'%20filter='url(%23n)'%20mask='url(%23o)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23p)'%20mask='url(%23q)'%20style='display:block'%3e%3cg%20filter='url(%23r)'%20transform='rotate(-94%20238.762%20-16.565)%20scale(2.4)'%3e%3cg%20class='design'%3e%3cpath%20fill='%234BE1EC'%20d='M0-250c137.975%200%20250%20112.025%20250%20250S137.975%20250%200%20250-250%20137.975-250%200-137.975-250%200-250z'%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20fill='%23CB5EEE'%20d='M113.242-295.384c97.478%200%20176.5%2079.022%20176.5%20176.5s-79.022%20176.5-176.5%20176.5c-43.948%200-74.396-34.057-105.29-60.631-37.631-32.369-71.21-62.338-71.21-115.869%200-97.478%2079.022-176.5%20176.5-176.5z'%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23s)'%20filter='url(%23t)'%20mask='url(%23u)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Ri="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Generator:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%20-1.67%2047.336%2047.336'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Group_42'%20data-name='Group%2042'%20transform='translate(-172.455%20-364.36)'%3e%3cpath%20id='Rectangle_17'%20data-name='Rectangle%2017'%20d='M4.351,0H40.984a4.351,4.351,0,0,1,4.351,4.351V22.117a1,1,0,0,1-1,1H1a1,1,0,0,1-1-1V4.351A4.351,4.351,0,0,1,4.351,0Z'%20transform='translate(173.455%20384.243)'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cpath%20id='Path_90'%20data-name='Path%2090'%20d='M218.79,390.249a3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.778,3.778,0,0,1-3.777-3.778'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cg%20id='Group_41'%20data-name='Group%2041'%3e%3cpath%20id='Rectangle_18'%20data-name='Rectangle%2018'%20d='M4.351,0H26.473a4.351,4.351,0,0,1,4.351,4.351V17.883a1,1,0,0,1-1,1H1a1,1,0,0,1-1-1V4.351A4.351,4.351,0,0,1,4.351,0Z'%20transform='translate(180.71%20365.36)'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cpath%20id='Path_91'%20data-name='Path%2091'%20d='M211.234,370.794a3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Lo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAQAAABKfvVzAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QAAKqNIzIAAAAJcEhZcwAADdcAAA3XAUIom3gAAAAHdElNRQfhBQoMHg6McuYvAAABwklEQVQ4y43TP0jUYRgH8M/daQpqdujhnwShGiwyipCIoIgWxyIwrqEhnCQoGqKhpoYMg1qCQjg8TC2JCtSkjCgaKisIhyQUwpJssD9KZWRZg6d450/yGV54n/fzfd53eUOCaoNa5QpNGNPr9cKjUAatdsB++co0G1XiiHd+uqnTq8VzI874o9s2Ic1iiEpii9tmnJOdfkOldt/dU+HYolHnjdmpRNzbuVaNL86m4sXqNOrz3kMXHFKYMqd8VREGBToMifqLgwY1yNZirya5knaBqH16fJjNJiWEFSlxy4g980+pMuZkir/UJjLbrvNRPnINaLUygK/yQpuImHp47LOjuKJPOJA/1y4iZsAlyozLs8IO42L/4QlhGrSCy5oCeKH+dM59vVbL9sn6AP5MRzpnVKtN1viRxit1WRvEmVKFrQbTpoddNR3E+aYKuw1lPOapa0GcEf22KzOtejmcG1rkYdjEAn59KU5cDzjt+HI4BSZtVJTazfIsMQOmFAusLr/E53lniickJYIDNcaUL+JhMZPWBUdOeCCaweGOw5k0lFrv2uyRuBxPlLpoBtTK0p3mh+f+dKl6jX6LapRj6XrzD+1bmkFA/dTVAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE3LTA1LTEwVDEyOjMwOjE0KzAyOjAwUNH5TAAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNy0wNS0xMFQxMjozMDoxNCswMjowMCGMQfAAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC",wo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=";function bo(g){const h="data-leaflet-styles";if(g.querySelector(`style[${h}]`))return;const s=document.createElement("style");s.setAttribute(h,"true"),s.textContent=`
|
|
4
|
+
*/var mo=$t.exports,Bi;function Ri(){return Bi||(Bi=1,(function(m,c){(function(s,h){h(c)})(mo,(function(s){var h="1.9.4";function n(t){var e,i,o,l;for(i=1,o=arguments.length;i<o;i++){l=arguments[i];for(e in l)t[e]=l[e]}return t}var r=Object.create||(function(){function t(){}return function(e){return t.prototype=e,new t}})();function a(t,e){var i=Array.prototype.slice;if(t.bind)return t.bind.apply(t,i.call(arguments,1));var o=i.call(arguments,2);return function(){return t.apply(e,o.length?o.concat(i.call(arguments)):arguments)}}var u=0;function f(t){return"_leaflet_id"in t||(t._leaflet_id=++u),t._leaflet_id}function _(t,e,i){var o,l,d,p;return p=function(){o=!1,l&&(d.apply(i,l),l=!1)},d=function(){o?l=arguments:(t.apply(i,arguments),setTimeout(p,e),o=!0)},d}function g(t,e,i){var o=e[1],l=e[0],d=o-l;return t===o&&i?t:((t-l)%d+d)%d+l}function w(){return!1}function x(t,e){if(e===!1)return t;var i=Math.pow(10,e===void 0?6:e);return Math.round(t*i)/i}function M(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function E(t){return M(t).split(/\s+/)}function P(t,e){Object.prototype.hasOwnProperty.call(t,"options")||(t.options=t.options?r(t.options):{});for(var i in e)t.options[i]=e[i];return t.options}function U(t,e,i){var o=[];for(var l in t)o.push(encodeURIComponent(i?l.toUpperCase():l)+"="+encodeURIComponent(t[l]));return(!e||e.indexOf("?")===-1?"?":"&")+o.join("&")}var H=/\{ *([\w_ -]+) *\}/g;function S(t,e){return t.replace(H,function(i,o){var l=e[o];if(l===void 0)throw new Error("No value provided for variable "+i);return typeof l=="function"&&(l=l(e)),l})}var D=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"};function G(t,e){for(var i=0;i<t.length;i++)if(t[i]===e)return i;return-1}var Y="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";function q(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}var at=0;function vt(t){var e=+new Date,i=Math.max(0,16-(e-at));return at=e+i,window.setTimeout(t,i)}var Gt=window.requestAnimationFrame||q("RequestAnimationFrame")||vt,Ae=window.cancelAnimationFrame||q("CancelAnimationFrame")||q("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)};function ot(t,e,i){if(i&&Gt===vt)t.call(e);else return Gt.call(window,a(t,e))}function rt(t){t&&Ae.call(window,t)}var Me={__proto__:null,extend:n,create:r,bind:a,get lastId(){return u},stamp:f,throttle:_,wrapNum:g,falseFn:w,formatNum:x,trim:M,splitWords:E,setOptions:P,getParamString:U,template:S,isArray:D,indexOf:G,emptyImageUrl:Y,requestFn:Gt,cancelFn:Ae,requestAnimFrame:ot,cancelAnimFrame:rt};function pt(){}pt.extend=function(t){var e=function(){P(this),this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},i=e.__super__=this.prototype,o=r(i);o.constructor=e,e.prototype=o;for(var l in this)Object.prototype.hasOwnProperty.call(this,l)&&l!=="prototype"&&l!=="__super__"&&(e[l]=this[l]);return t.statics&&n(e,t.statics),t.includes&&(ie(t.includes),n.apply(null,[o].concat(t.includes))),n(o,t),delete o.statics,delete o.includes,o.options&&(o.options=i.options?r(i.options):{},n(o.options,t.options)),o._initHooks=[],o.callInitHooks=function(){if(!this._initHooksCalled){i.callInitHooks&&i.callInitHooks.call(this),this._initHooksCalled=!0;for(var d=0,p=o._initHooks.length;d<p;d++)o._initHooks[d].call(this)}},e},pt.include=function(t){var e=this.prototype.options;return n(this.prototype,t),t.options&&(this.prototype.options=e,this.mergeOptions(t.options)),this},pt.mergeOptions=function(t){return n(this.prototype.options,t),this},pt.addInitHook=function(t){var e=Array.prototype.slice.call(arguments,1),i=typeof t=="function"?t:function(){this[t].apply(this,e)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(i),this};function ie(t){if(!(typeof L=="undefined"||!L||!L.Mixin)){t=D(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)}}var ft={on:function(t,e,i){if(typeof t=="object")for(var o in t)this._on(o,t[o],e);else{t=E(t);for(var l=0,d=t.length;l<d;l++)this._on(t[l],e,i)}return this},off:function(t,e,i){if(!arguments.length)delete this._events;else if(typeof t=="object")for(var o in t)this._off(o,t[o],e);else{t=E(t);for(var l=arguments.length===1,d=0,p=t.length;d<p;d++)l?this._off(t[d]):this._off(t[d],e,i)}return this},_on:function(t,e,i,o){if(typeof e!="function"){console.warn("wrong listener type: "+typeof e);return}if(this._listens(t,e,i)===!1){i===this&&(i=void 0);var l={fn:e,ctx:i};o&&(l.once=!0),this._events=this._events||{},this._events[t]=this._events[t]||[],this._events[t].push(l)}},_off:function(t,e,i){var o,l,d;if(this._events&&(o=this._events[t],!!o)){if(arguments.length===1){if(this._firingCount)for(l=0,d=o.length;l<d;l++)o[l].fn=w;delete this._events[t];return}if(typeof e!="function"){console.warn("wrong listener type: "+typeof e);return}var p=this._listens(t,e,i);if(p!==!1){var v=o[p];this._firingCount&&(v.fn=w,this._events[t]=o=o.slice()),o.splice(p,1)}}},fire:function(t,e,i){if(!this.listens(t,i))return this;var o=n({},e,{type:t,target:this,sourceTarget:e&&e.sourceTarget||this});if(this._events){var l=this._events[t];if(l){this._firingCount=this._firingCount+1||1;for(var d=0,p=l.length;d<p;d++){var v=l[d],y=v.fn;v.once&&this.off(t,y,v.ctx),y.call(v.ctx||this,o)}this._firingCount--}}return i&&this._propagateEvent(o),this},listens:function(t,e,i,o){typeof t!="string"&&console.warn('"string" type argument expected');var l=e;typeof e!="function"&&(o=!!e,l=void 0,i=void 0);var d=this._events&&this._events[t];if(d&&d.length&&this._listens(t,l,i)!==!1)return!0;if(o){for(var p in this._eventParents)if(this._eventParents[p].listens(t,e,i,o))return!0}return!1},_listens:function(t,e,i){if(!this._events)return!1;var o=this._events[t]||[];if(!e)return!!o.length;i===this&&(i=void 0);for(var l=0,d=o.length;l<d;l++)if(o[l].fn===e&&o[l].ctx===i)return l;return!1},once:function(t,e,i){if(typeof t=="object")for(var o in t)this._on(o,t[o],e,!0);else{t=E(t);for(var l=0,d=t.length;l<d;l++)this._on(t[l],e,i,!0)}return this},addEventParent:function(t){return this._eventParents=this._eventParents||{},this._eventParents[f(t)]=t,this},removeEventParent:function(t){return this._eventParents&&delete this._eventParents[f(t)],this},_propagateEvent:function(t){for(var e in this._eventParents)this._eventParents[e].fire(t.type,n({layer:t.target,propagatedFrom:t.target},t),!0)}};ft.addEventListener=ft.on,ft.removeEventListener=ft.clearAllEventListeners=ft.off,ft.addOneTimeEventListener=ft.once,ft.fireEvent=ft.fire,ft.hasEventListeners=ft.listens;var ne=pt.extend(ft);function z(t,e,i){this.x=i?Math.round(t):t,this.y=i?Math.round(e):e}var $i=Math.trunc||function(t){return t>0?Math.floor(t):Math.ceil(t)};z.prototype={clone:function(){return new z(this.x,this.y)},add:function(t){return this.clone()._add(I(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(I(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 z(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new z(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=$i(this.x),this.y=$i(this.y),this},distanceTo:function(t){t=I(t);var e=t.x-this.x,i=t.y-this.y;return Math.sqrt(e*e+i*i)},equals:function(t){return t=I(t),t.x===this.x&&t.y===this.y},contains:function(t){return t=I(t),Math.abs(t.x)<=Math.abs(this.x)&&Math.abs(t.y)<=Math.abs(this.y)},toString:function(){return"Point("+x(this.x)+", "+x(this.y)+")"}};function I(t,e,i){return t instanceof z?t:D(t)?new z(t[0],t[1]):t==null?t:typeof t=="object"&&"x"in t&&"y"in t?new z(t.x,t.y):new z(t,e,i)}function j(t,e){if(t)for(var i=e?[t,e]:t,o=0,l=i.length;o<l;o++)this.extend(i[o])}j.prototype={extend:function(t){var e,i;if(!t)return this;if(t instanceof z||typeof t[0]=="number"||"x"in t)e=i=I(t);else if(t=lt(t),e=t.min,i=t.max,!e||!i)return this;return!this.min&&!this.max?(this.min=e.clone(),this.max=i.clone()):(this.min.x=Math.min(e.x,this.min.x),this.max.x=Math.max(i.x,this.max.x),this.min.y=Math.min(e.y,this.min.y),this.max.y=Math.max(i.y,this.max.y)),this},getCenter:function(t){return I((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return I(this.min.x,this.max.y)},getTopRight:function(){return I(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,i;return typeof t[0]=="number"||t instanceof z?t=I(t):t=lt(t),t instanceof j?(e=t.min,i=t.max):e=i=t,e.x>=this.min.x&&i.x<=this.max.x&&e.y>=this.min.y&&i.y<=this.max.y},intersects:function(t){t=lt(t);var e=this.min,i=this.max,o=t.min,l=t.max,d=l.x>=e.x&&o.x<=i.x,p=l.y>=e.y&&o.y<=i.y;return d&&p},overlaps:function(t){t=lt(t);var e=this.min,i=this.max,o=t.min,l=t.max,d=l.x>e.x&&o.x<i.x,p=l.y>e.y&&o.y<i.y;return d&&p},isValid:function(){return!!(this.min&&this.max)},pad:function(t){var e=this.min,i=this.max,o=Math.abs(e.x-i.x)*t,l=Math.abs(e.y-i.y)*t;return lt(I(e.x-o,e.y-l),I(i.x+o,i.y+l))},equals:function(t){return t?(t=lt(t),this.min.equals(t.getTopLeft())&&this.max.equals(t.getBottomRight())):!1}};function lt(t,e){return!t||t instanceof j?t:new j(t,e)}function ht(t,e){if(t)for(var i=e?[t,e]:t,o=0,l=i.length;o<l;o++)this.extend(i[o])}ht.prototype={extend:function(t){var e=this._southWest,i=this._northEast,o,l;if(t instanceof V)o=t,l=t;else if(t instanceof ht){if(o=t._southWest,l=t._northEast,!o||!l)return this}else return t?this.extend(N(t)||Q(t)):this;return!e&&!i?(this._southWest=new V(o.lat,o.lng),this._northEast=new V(l.lat,l.lng)):(e.lat=Math.min(o.lat,e.lat),e.lng=Math.min(o.lng,e.lng),i.lat=Math.max(l.lat,i.lat),i.lng=Math.max(l.lng,i.lng)),this},pad:function(t){var e=this._southWest,i=this._northEast,o=Math.abs(e.lat-i.lat)*t,l=Math.abs(e.lng-i.lng)*t;return new ht(new V(e.lat-o,e.lng-l),new V(i.lat+o,i.lng+l))},getCenter:function(){return new V((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 V(this.getNorth(),this.getWest())},getSouthEast:function(){return new V(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){typeof t[0]=="number"||t instanceof V||"lat"in t?t=N(t):t=Q(t);var e=this._southWest,i=this._northEast,o,l;return t instanceof ht?(o=t.getSouthWest(),l=t.getNorthEast()):o=l=t,o.lat>=e.lat&&l.lat<=i.lat&&o.lng>=e.lng&&l.lng<=i.lng},intersects:function(t){t=Q(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),l=t.getNorthEast(),d=l.lat>=e.lat&&o.lat<=i.lat,p=l.lng>=e.lng&&o.lng<=i.lng;return d&&p},overlaps:function(t){t=Q(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),l=t.getNorthEast(),d=l.lat>e.lat&&o.lat<i.lat,p=l.lng>e.lng&&o.lng<i.lng;return d&&p},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(t,e){return t?(t=Q(t),this._southWest.equals(t.getSouthWest(),e)&&this._northEast.equals(t.getNorthEast(),e)):!1},isValid:function(){return!!(this._southWest&&this._northEast)}};function Q(t,e){return t instanceof ht?t:new ht(t,e)}function V(t,e,i){if(isNaN(t)||isNaN(e))throw new Error("Invalid LatLng object: ("+t+", "+e+")");this.lat=+t,this.lng=+e,i!==void 0&&(this.alt=+i)}V.prototype={equals:function(t,e){if(!t)return!1;t=N(t);var i=Math.max(Math.abs(this.lat-t.lat),Math.abs(this.lng-t.lng));return i<=(e===void 0?1e-9:e)},toString:function(t){return"LatLng("+x(this.lat,t)+", "+x(this.lng,t)+")"},distanceTo:function(t){return St.distance(this,N(t))},wrap:function(){return St.wrapLatLng(this)},toBounds:function(t){var e=180*t/40075017,i=e/Math.cos(Math.PI/180*this.lat);return Q([this.lat-e,this.lng-i],[this.lat+e,this.lng+i])},clone:function(){return new V(this.lat,this.lng,this.alt)}};function N(t,e,i){return t instanceof V?t:D(t)&&typeof t[0]!="object"?t.length===3?new V(t[0],t[1],t[2]):t.length===2?new V(t[0],t[1]):null:t==null?t:typeof t=="object"&&"lat"in t?new V(t.lat,"lng"in t?t.lng:t.lon,t.alt):e===void 0?null:new V(t,e,i)}var At={latLngToPoint:function(t,e){var i=this.projection.project(t),o=this.scale(e);return this.transformation._transform(i,o)},pointToLatLng:function(t,e){var i=this.scale(e),o=this.transformation.untransform(t,i);return this.projection.unproject(o)},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,i=this.scale(t),o=this.transformation.transform(e.min,i),l=this.transformation.transform(e.max,i);return new j(o,l)},infinite:!1,wrapLatLng:function(t){var e=this.wrapLng?g(t.lng,this.wrapLng,!0):t.lng,i=this.wrapLat?g(t.lat,this.wrapLat,!0):t.lat,o=t.alt;return new V(i,e,o)},wrapLatLngBounds:function(t){var e=t.getCenter(),i=this.wrapLatLng(e),o=e.lat-i.lat,l=e.lng-i.lng;if(o===0&&l===0)return t;var d=t.getSouthWest(),p=t.getNorthEast(),v=new V(d.lat-o,d.lng-l),y=new V(p.lat-o,p.lng-l);return new ht(v,y)}},St=n({},At,{wrapLng:[-180,180],R:6371e3,distance:function(t,e){var i=Math.PI/180,o=t.lat*i,l=e.lat*i,d=Math.sin((e.lat-t.lat)*i/2),p=Math.sin((e.lng-t.lng)*i/2),v=d*d+Math.cos(o)*Math.cos(l)*p*p,y=2*Math.atan2(Math.sqrt(v),Math.sqrt(1-v));return this.R*y}}),tn=6378137,ii={R:tn,MAX_LATITUDE:85.0511287798,project:function(t){var e=Math.PI/180,i=this.MAX_LATITUDE,o=Math.max(Math.min(i,t.lat),-i),l=Math.sin(o*e);return new z(this.R*t.lng*e,this.R*Math.log((1+l)/(1-l))/2)},unproject:function(t){var e=180/Math.PI;return new V((2*Math.atan(Math.exp(t.y/this.R))-Math.PI/2)*e,t.x*e/this.R)},bounds:(function(){var t=tn*Math.PI;return new j([-t,-t],[t,t])})()};function ni(t,e,i,o){if(D(t)){this._a=t[0],this._b=t[1],this._c=t[2],this._d=t[3];return}this._a=t,this._b=e,this._c=i,this._d=o}ni.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 z((t.x/e-this._b)/this._a,(t.y/e-this._d)/this._c)}};function oe(t,e,i,o){return new ni(t,e,i,o)}var oi=n({},St,{code:"EPSG:3857",projection:ii,transformation:(function(){var t=.5/(Math.PI*ii.R);return oe(t,.5,-t,.5)})()}),_r=n({},oi,{code:"EPSG:900913"});function en(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function nn(t,e){var i="",o,l,d,p,v,y;for(o=0,d=t.length;o<d;o++){for(v=t[o],l=0,p=v.length;l<p;l++)y=v[l],i+=(l?"L":"M")+y.x+" "+y.y;i+=e?T.svg?"z":"x":""}return i||"M0 0"}var ri=document.documentElement.style,Ee="ActiveXObject"in window,gr=Ee&&!document.addEventListener,on="msLaunchUri"in navigator&&!("documentMode"in document),si=wt("webkit"),rn=wt("android"),sn=wt("android 2")||wt("android 3"),vr=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),yr=rn&&wt("Google")&&vr<537&&!("AudioNode"in window),ai=!!window.opera,an=!on&&wt("chrome"),ln=wt("gecko")&&!si&&!ai&&!Ee,Lr=!an&&wt("safari"),hn=wt("phantom"),cn="OTransition"in ri,wr=navigator.platform.indexOf("Win")===0,dn=Ee&&"transition"in ri,li="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!sn,un="MozPerspective"in ri,br=!window.L_DISABLE_3D&&(dn||li||un)&&!cn&&!hn,re=typeof orientation!="undefined"||wt("mobile"),xr=re&&si,kr=re&&li,fn=!window.PointerEvent&&window.MSPointerEvent,pn=!!(window.PointerEvent||fn),mn="ontouchstart"in window||!!window.TouchEvent,Ar=!window.L_NO_TOUCH&&(mn||pn),Mr=re&&ai,Er=re&&ln,Pr=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,Tr=(function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("testPassiveEventSupport",w,e),window.removeEventListener("testPassiveEventSupport",w,e)}catch{}return t})(),Cr=(function(){return!!document.createElement("canvas").getContext})(),hi=!!(document.createElementNS&&en("svg").createSVGRect),Sr=!!hi&&(function(){var t=document.createElement("div");return t.innerHTML="<svg/>",(t.firstChild&&t.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"})(),Dr=!hi&&(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&&typeof e.adj=="object"}catch{return!1}})(),Ir=navigator.platform.indexOf("Mac")===0,zr=navigator.platform.indexOf("Linux")===0;function wt(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}var T={ie:Ee,ielt9:gr,edge:on,webkit:si,android:rn,android23:sn,androidStock:yr,opera:ai,chrome:an,gecko:ln,safari:Lr,phantom:hn,opera12:cn,win:wr,ie3d:dn,webkit3d:li,gecko3d:un,any3d:br,mobile:re,mobileWebkit:xr,mobileWebkit3d:kr,msPointer:fn,pointer:pn,touch:Ar,touchNative:mn,mobileOpera:Mr,mobileGecko:Er,retina:Pr,passiveEvents:Tr,canvas:Cr,svg:hi,vml:Dr,inlineSvg:Sr,mac:Ir,linux:zr},_n=T.msPointer?"MSPointerDown":"pointerdown",gn=T.msPointer?"MSPointerMove":"pointermove",vn=T.msPointer?"MSPointerUp":"pointerup",yn=T.msPointer?"MSPointerCancel":"pointercancel",ci={touchstart:_n,touchmove:gn,touchend:vn,touchcancel:yn},Ln={touchstart:Zr,touchmove:Pe,touchend:Pe,touchcancel:Pe},Vt={},wn=!1;function Or(t,e,i){return e==="touchstart"&&Nr(),Ln[e]?(i=Ln[e].bind(this,i),t.addEventListener(ci[e],i,!1),i):(console.warn("wrong event specified:",e),w)}function Br(t,e,i){if(!ci[e]){console.warn("wrong event specified:",e);return}t.removeEventListener(ci[e],i,!1)}function Rr(t){Vt[t.pointerId]=t}function Ur(t){Vt[t.pointerId]&&(Vt[t.pointerId]=t)}function bn(t){delete Vt[t.pointerId]}function Nr(){wn||(document.addEventListener(_n,Rr,!0),document.addEventListener(gn,Ur,!0),document.addEventListener(vn,bn,!0),document.addEventListener(yn,bn,!0),wn=!0)}function Pe(t,e){if(e.pointerType!==(e.MSPOINTER_TYPE_MOUSE||"mouse")){e.touches=[];for(var i in Vt)e.touches.push(Vt[i]);e.changedTouches=[e],t(e)}}function Zr(t,e){e.MSPOINTER_TYPE_TOUCH&&e.pointerType===e.MSPOINTER_TYPE_TOUCH&&nt(e),Pe(t,e)}function Hr(t){var e={},i,o;for(o in t)i=t[o],e[o]=i&&i.bind?i.bind(t):i;return t=e,e.type="dblclick",e.detail=2,e.isTrusted=!1,e._simulated=!0,e}var Fr=200;function Gr(t,e){t.addEventListener("dblclick",e);var i=0,o;function l(d){if(d.detail!==1){o=d.detail;return}if(!(d.pointerType==="mouse"||d.sourceCapabilities&&!d.sourceCapabilities.firesTouchEvents)){var p=En(d);if(!(p.some(function(y){return y instanceof HTMLLabelElement&&y.attributes.for})&&!p.some(function(y){return y instanceof HTMLInputElement||y instanceof HTMLSelectElement}))){var v=Date.now();v-i<=Fr?(o++,o===2&&e(Hr(d))):o=1,i=v}}}return t.addEventListener("click",l),{dblclick:e,simDblclick:l}}function Vr(t,e){t.removeEventListener("dblclick",e.dblclick),t.removeEventListener("click",e.simDblclick)}var di=Se(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),se=Se(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),xn=se==="webkitTransition"||se==="OTransition"?se+"End":"transitionend";function kn(t){return typeof t=="string"?document.getElementById(t):t}function ae(t,e){var i=t.style[e]||t.currentStyle&&t.currentStyle[e];if((!i||i==="auto")&&document.defaultView){var o=document.defaultView.getComputedStyle(t,null);i=o?o[e]:null}return i==="auto"?null:i}function F(t,e,i){var o=document.createElement(t);return o.className=e||"",i&&i.appendChild(o),o}function J(t){var e=t.parentNode;e&&e.removeChild(t)}function Te(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function Wt(t){var e=t.parentNode;e&&e.lastChild!==t&&e.appendChild(t)}function Yt(t){var e=t.parentNode;e&&e.firstChild!==t&&e.insertBefore(t,e.firstChild)}function ui(t,e){if(t.classList!==void 0)return t.classList.contains(e);var i=Ce(t);return i.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(i)}function B(t,e){if(t.classList!==void 0)for(var i=E(e),o=0,l=i.length;o<l;o++)t.classList.add(i[o]);else if(!ui(t,e)){var d=Ce(t);fi(t,(d?d+" ":"")+e)}}function K(t,e){t.classList!==void 0?t.classList.remove(e):fi(t,M((" "+Ce(t)+" ").replace(" "+e+" "," ")))}function fi(t,e){t.className.baseVal===void 0?t.className=e:t.className.baseVal=e}function Ce(t){return t.correspondingElement&&(t=t.correspondingElement),t.className.baseVal===void 0?t.className:t.className.baseVal}function mt(t,e){"opacity"in t.style?t.style.opacity=e:"filter"in t.style&&Wr(t,e)}function Wr(t,e){var i=!1,o="DXImageTransform.Microsoft.Alpha";try{i=t.filters.item(o)}catch{if(e===1)return}e=Math.round(e*100),i?(i.Enabled=e!==100,i.Opacity=e):t.style.filter+=" progid:"+o+"(opacity="+e+")"}function Se(t){for(var e=document.documentElement.style,i=0;i<t.length;i++)if(t[i]in e)return t[i];return!1}function Bt(t,e,i){var o=e||new z(0,0);t.style[di]=(T.ie3d?"translate("+o.x+"px,"+o.y+"px)":"translate3d("+o.x+"px,"+o.y+"px,0)")+(i?" scale("+i+")":"")}function $(t,e){t._leaflet_pos=e,T.any3d?Bt(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px")}function Rt(t){return t._leaflet_pos||new z(0,0)}var le,he,pi;if("onselectstart"in document)le=function(){O(window,"selectstart",nt)},he=function(){W(window,"selectstart",nt)};else{var ce=Se(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);le=function(){if(ce){var t=document.documentElement.style;pi=t[ce],t[ce]="none"}},he=function(){ce&&(document.documentElement.style[ce]=pi,pi=void 0)}}function mi(){O(window,"dragstart",nt)}function _i(){W(window,"dragstart",nt)}var De,gi;function vi(t){for(;t.tabIndex===-1;)t=t.parentNode;t.style&&(Ie(),De=t,gi=t.style.outlineStyle,t.style.outlineStyle="none",O(window,"keydown",Ie))}function Ie(){De&&(De.style.outlineStyle=gi,De=void 0,gi=void 0,W(window,"keydown",Ie))}function An(t){do t=t.parentNode;while((!t.offsetWidth||!t.offsetHeight)&&t!==document.body);return t}function yi(t){var e=t.getBoundingClientRect();return{x:e.width/t.offsetWidth||1,y:e.height/t.offsetHeight||1,boundingClientRect:e}}var Yr={__proto__:null,TRANSFORM:di,TRANSITION:se,TRANSITION_END:xn,get:kn,getStyle:ae,create:F,remove:J,empty:Te,toFront:Wt,toBack:Yt,hasClass:ui,addClass:B,removeClass:K,setClass:fi,getClass:Ce,setOpacity:mt,testProp:Se,setTransform:Bt,setPosition:$,getPosition:Rt,get disableTextSelection(){return le},get enableTextSelection(){return he},disableImageDrag:mi,enableImageDrag:_i,preventOutline:vi,restoreOutline:Ie,getSizedParentNode:An,getScale:yi};function O(t,e,i,o){if(e&&typeof e=="object")for(var l in e)wi(t,l,e[l],i);else{e=E(e);for(var d=0,p=e.length;d<p;d++)wi(t,e[d],i,o)}return this}var bt="_leaflet_events";function W(t,e,i,o){if(arguments.length===1)Mn(t),delete t[bt];else if(e&&typeof e=="object")for(var l in e)bi(t,l,e[l],i);else if(e=E(e),arguments.length===2)Mn(t,function(v){return G(e,v)!==-1});else for(var d=0,p=e.length;d<p;d++)bi(t,e[d],i,o);return this}function Mn(t,e){for(var i in t[bt]){var o=i.split(/\d/)[0];(!e||e(o))&&bi(t,o,null,null,i)}}var Li={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"};function wi(t,e,i,o){var l=e+f(i)+(o?"_"+f(o):"");if(t[bt]&&t[bt][l])return this;var d=function(v){return i.call(o||t,v||window.event)},p=d;!T.touchNative&&T.pointer&&e.indexOf("touch")===0?d=Or(t,e,d):T.touch&&e==="dblclick"?d=Gr(t,d):"addEventListener"in t?e==="touchstart"||e==="touchmove"||e==="wheel"||e==="mousewheel"?t.addEventListener(Li[e]||e,d,T.passiveEvents?{passive:!1}:!1):e==="mouseenter"||e==="mouseleave"?(d=function(v){v=v||window.event,ki(t,v)&&p(v)},t.addEventListener(Li[e],d,!1)):t.addEventListener(e,p,!1):t.attachEvent("on"+e,d),t[bt]=t[bt]||{},t[bt][l]=d}function bi(t,e,i,o,l){l=l||e+f(i)+(o?"_"+f(o):"");var d=t[bt]&&t[bt][l];if(!d)return this;!T.touchNative&&T.pointer&&e.indexOf("touch")===0?Br(t,e,d):T.touch&&e==="dblclick"?Vr(t,d):"removeEventListener"in t?t.removeEventListener(Li[e]||e,d,!1):t.detachEvent("on"+e,d),t[bt][l]=null}function Ut(t){return t.stopPropagation?t.stopPropagation():t.originalEvent?t.originalEvent._stopped=!0:t.cancelBubble=!0,this}function xi(t){return wi(t,"wheel",Ut),this}function de(t){return O(t,"mousedown touchstart dblclick contextmenu",Ut),t._leaflet_disable_click=!0,this}function nt(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Nt(t){return nt(t),Ut(t),this}function En(t){if(t.composedPath)return t.composedPath();for(var e=[],i=t.target;i;)e.push(i),i=i.parentNode;return e}function Pn(t,e){if(!e)return new z(t.clientX,t.clientY);var i=yi(e),o=i.boundingClientRect;return new z((t.clientX-o.left)/i.x-e.clientLeft,(t.clientY-o.top)/i.y-e.clientTop)}var qr=T.linux&&T.chrome?window.devicePixelRatio:T.mac?window.devicePixelRatio*3:window.devicePixelRatio>0?2*window.devicePixelRatio:1;function Tn(t){return T.edge?t.wheelDeltaY/2:t.deltaY&&t.deltaMode===0?-t.deltaY/qr:t.deltaY&&t.deltaMode===1?-t.deltaY*20:t.deltaY&&t.deltaMode===2?-t.deltaY*60:t.deltaX||t.deltaZ?0:t.wheelDelta?(t.wheelDeltaY||t.wheelDelta)/2:t.detail&&Math.abs(t.detail)<32765?-t.detail*20:t.detail?t.detail/-32765*60:0}function ki(t,e){var i=e.relatedTarget;if(!i)return!0;try{for(;i&&i!==t;)i=i.parentNode}catch{return!1}return i!==t}var jr={__proto__:null,on:O,off:W,stopPropagation:Ut,disableScrollPropagation:xi,disableClickPropagation:de,preventDefault:nt,stop:Nt,getPropagationPath:En,getMousePosition:Pn,getWheelDelta:Tn,isExternalTarget:ki,addListener:O,removeListener:W},Cn=ne.extend({run:function(t,e,i,o){this.stop(),this._el=t,this._inProgress=!0,this._duration=i||.25,this._easeOutPower=1/Math.max(o||.5,.2),this._startPos=Rt(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=ot(this._animate,this),this._step()},_step:function(t){var e=+new Date-this._startTime,i=this._duration*1e3;e<i?this._runFrame(this._easeOut(e/i),t):(this._runFrame(1),this._complete())},_runFrame:function(t,e){var i=this._startPos.add(this._offset.multiplyBy(t));e&&i._round(),$(this._el,i),this.fire("step")},_complete:function(){rt(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(t){return 1-Math.pow(1-t,this._easeOutPower)}}),Z=ne.extend({options:{crs:oi,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=a(this._onResize,this),this._initEvents(),e.maxBounds&&this.setMaxBounds(e.maxBounds),e.zoom!==void 0&&(this._zoom=this._limitZoom(e.zoom)),e.center&&e.zoom!==void 0&&this.setView(N(e.center),e.zoom,{reset:!0}),this.callInitHooks(),this._zoomAnimated=se&&T.any3d&&!T.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),O(this._proxy,xn,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(t,e,i){if(e=e===void 0?this._zoom:this._limitZoom(e),t=this._limitCenter(N(t),e,this.options.maxBounds),i=i||{},this._stop(),this._loaded&&!i.reset&&i!==!0){i.animate!==void 0&&(i.zoom=n({animate:i.animate},i.zoom),i.pan=n({animate:i.animate,duration:i.duration},i.pan));var o=this._zoom!==e?this._tryAnimatedZoom&&this._tryAnimatedZoom(t,e,i.zoom):this._tryAnimatedPan(t,i.pan);if(o)return clearTimeout(this._sizeTimer),this}return this._resetView(t,e,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||(T.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+t,e)},zoomOut:function(t,e){return t=t||(T.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-t,e)},setZoomAround:function(t,e,i){var o=this.getZoomScale(e),l=this.getSize().divideBy(2),d=t instanceof z?t:this.latLngToContainerPoint(t),p=d.subtract(l).multiplyBy(1-1/o),v=this.containerPointToLatLng(l.add(p));return this.setView(v,e,{zoom:i})},_getBoundsCenterZoom:function(t,e){e=e||{},t=t.getBounds?t.getBounds():Q(t);var i=I(e.paddingTopLeft||e.padding||[0,0]),o=I(e.paddingBottomRight||e.padding||[0,0]),l=this.getBoundsZoom(t,!1,i.add(o));if(l=typeof e.maxZoom=="number"?Math.min(e.maxZoom,l):l,l===1/0)return{center:t.getCenter(),zoom:l};var d=o.subtract(i).divideBy(2),p=this.project(t.getSouthWest(),l),v=this.project(t.getNorthEast(),l),y=this.unproject(p.add(v).divideBy(2).add(d),l);return{center:y,zoom:l}},fitBounds:function(t,e){if(t=Q(t),!t.isValid())throw new Error("Bounds are not valid.");var i=this._getBoundsCenterZoom(t,e);return this.setView(i.center,i.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(t=I(t).round(),e=e||{},!t.x&&!t.y)return this.fire("moveend");if(e.animate!==!0&&!this.getSize().contains(t))return this._resetView(this.unproject(this.project(this.getCenter()).add(t)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new Cn,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),e.noMoveStart||this.fire("movestart"),e.animate!==!1){B(this._mapPane,"leaflet-pan-anim");var i=this._getMapPanePos().subtract(t).round();this._panAnim.run(this._mapPane,i,e.duration||.25,e.easeLinearity)}else this._rawPanBy(t),this.fire("move").fire("moveend");return this},flyTo:function(t,e,i){if(i=i||{},i.animate===!1||!T.any3d)return this.setView(t,e,i);this._stop();var o=this.project(this.getCenter()),l=this.project(t),d=this.getSize(),p=this._zoom;t=N(t),e=e===void 0?p:e;var v=Math.max(d.x,d.y),y=v*this.getZoomScale(p,e),b=l.distanceTo(o)||1,A=1.42,C=A*A;function R(tt){var We=tt?-1:1,Bs=tt?y:v,Rs=y*y-v*v+We*C*C*b*b,Us=2*Bs*C*b,Oi=Rs/Us,co=Math.sqrt(Oi*Oi+1)-Oi,Ns=co<1e-9?-18:Math.log(co);return Ns}function st(tt){return(Math.exp(tt)-Math.exp(-tt))/2}function et(tt){return(Math.exp(tt)+Math.exp(-tt))/2}function gt(tt){return st(tt)/et(tt)}var ct=R(0);function Qt(tt){return v*(et(ct)/et(ct+A*tt))}function Ds(tt){return v*(et(ct)*gt(ct+A*tt)-st(ct))/C}function Is(tt){return 1-Math.pow(1-tt,1.5)}var zs=Date.now(),lo=(R(1)-ct)/A,Os=i.duration?1e3*i.duration:1e3*lo*.8;function ho(){var tt=(Date.now()-zs)/Os,We=Is(tt)*lo;tt<=1?(this._flyToFrame=ot(ho,this),this._move(this.unproject(o.add(l.subtract(o).multiplyBy(Ds(We)/b)),p),this.getScaleZoom(v/Qt(We),p),{flyTo:!0})):this._move(t,e)._moveEnd(!0)}return this._moveStart(!0,i.noMoveStart),ho.call(this),this},flyToBounds:function(t,e){var i=this._getBoundsCenterZoom(t,e);return this.flyTo(i.center,i.zoom,e)},setMaxBounds:function(t){return t=Q(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 i=this.getCenter(),o=this._limitCenter(i,this._zoom,Q(t));return i.equals(o)||this.panTo(o,e),this._enforcingBounds=!1,this},panInside:function(t,e){e=e||{};var i=I(e.paddingTopLeft||e.padding||[0,0]),o=I(e.paddingBottomRight||e.padding||[0,0]),l=this.project(this.getCenter()),d=this.project(t),p=this.getPixelBounds(),v=lt([p.min.add(i),p.max.subtract(o)]),y=v.getSize();if(!v.contains(d)){this._enforcingBounds=!0;var b=d.subtract(v.getCenter()),A=v.extend(d).getSize().subtract(y);l.x+=b.x<0?-A.x:A.x,l.y+=b.y<0?-A.y:A.y,this.panTo(this.unproject(l),e),this._enforcingBounds=!1}return this},invalidateSize:function(t){if(!this._loaded)return this;t=n({animate:!1,pan:!0},t===!0?{animate:!0}:t);var e=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var i=this.getSize(),o=e.divideBy(2).round(),l=i.divideBy(2).round(),d=o.subtract(l);return!d.x&&!d.y?this:(t.animate&&t.pan?this.panBy(d):(t.pan&&this._rawPanBy(d),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(a(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:e,newSize:i}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(t){if(t=this._locateOptions=n({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var e=a(this._handleGeolocationResponse,this),i=a(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(e,i,t):navigator.geolocation.getCurrentPosition(e,i,t),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(t){if(this._container._leaflet_id){var e=t.code,i=t.message||(e===1?"permission denied":e===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:e,message:"Geolocation error: "+i+"."})}},_handleGeolocationResponse:function(t){if(this._container._leaflet_id){var e=t.coords.latitude,i=t.coords.longitude,o=new V(e,i),l=o.toBounds(t.coords.accuracy*2),d=this._locateOptions;if(d.setView){var p=this.getBoundsZoom(l);this.setView(o,d.maxZoom?Math.min(p,d.maxZoom):p)}var v={latlng:o,bounds:l,timestamp:t.timestamp};for(var y in t.coords)typeof t.coords[y]=="number"&&(v[y]=t.coords[y]);this.fire("locationfound",v)}},addHandler:function(t,e){if(!e)return this;var i=this[t]=new e(this);return this._handlers.push(i),this.options[t]&&i.enable(),this},remove:function(){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{this._container._leaflet_id=void 0,this._containerId=void 0}this._locationWatchId!==void 0&&this.stopLocate(),this._stop(),J(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(rt(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var t;for(t in this._layers)this._layers[t].remove();for(t in this._panes)J(this._panes[t]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,e){var i="leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),o=F("div",i,e||this._mapPane);return t&&(this._panes[t]=o),o},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var t=this.getPixelBounds(),e=this.unproject(t.getBottomLeft()),i=this.unproject(t.getTopRight());return new ht(e,i)},getMinZoom:function(){return this.options.minZoom===void 0?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return this.options.maxZoom===void 0?this._layersMaxZoom===void 0?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(t,e,i){t=Q(t),i=I(i||[0,0]);var o=this.getZoom()||0,l=this.getMinZoom(),d=this.getMaxZoom(),p=t.getNorthWest(),v=t.getSouthEast(),y=this.getSize().subtract(i),b=lt(this.project(v,o),this.project(p,o)).getSize(),A=T.any3d?this.options.zoomSnap:1,C=y.x/b.x,R=y.y/b.y,st=e?Math.max(C,R):Math.min(C,R);return o=this.getScaleZoom(st,o),A&&(o=Math.round(o/(A/100))*(A/100),o=e?Math.ceil(o/A)*A:Math.floor(o/A)*A),Math.max(l,Math.min(d,o))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new z(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,e){var i=this._getTopLeftPoint(t,e);return new j(i,i.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(t){return this.options.crs.getProjectedBounds(t===void 0?this.getZoom():t)},getPane:function(t){return typeof t=="string"?this._panes[t]:t},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(t,e){var i=this.options.crs;return e=e===void 0?this._zoom:e,i.scale(t)/i.scale(e)},getScaleZoom:function(t,e){var i=this.options.crs;e=e===void 0?this._zoom:e;var o=i.zoom(t*i.scale(e));return isNaN(o)?1/0:o},project:function(t,e){return e=e===void 0?this._zoom:e,this.options.crs.latLngToPoint(N(t),e)},unproject:function(t,e){return e=e===void 0?this._zoom:e,this.options.crs.pointToLatLng(I(t),e)},layerPointToLatLng:function(t){var e=I(t).add(this.getPixelOrigin());return this.unproject(e)},latLngToLayerPoint:function(t){var e=this.project(N(t))._round();return e._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(N(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds(Q(t))},distance:function(t,e){return this.options.crs.distance(N(t),N(e))},containerPointToLayerPoint:function(t){return I(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return I(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(I(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(N(t)))},mouseEventToContainerPoint:function(t){return Pn(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=kn(t);if(e){if(e._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");O(e,"scroll",this._onScroll,this),this._containerId=f(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&T.any3d,B(t,"leaflet-container"+(T.touch?" leaflet-touch":"")+(T.retina?" leaflet-retina":"")+(T.ielt9?" leaflet-oldie":"")+(T.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var e=ae(t,"position");e!=="absolute"&&e!=="relative"&&e!=="fixed"&&e!=="sticky"&&(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),$(this._mapPane,new z(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(B(t.markerPane,"leaflet-zoom-hide"),B(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e,i){$(this._mapPane,new z(0,0));var o=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var l=this._zoom!==e;this._moveStart(l,i)._move(t,e)._moveEnd(l),this.fire("viewreset"),o&&this.fire("load")},_moveStart:function(t,e){return t&&this.fire("zoomstart"),e||this.fire("movestart"),this},_move:function(t,e,i,o){e===void 0&&(e=this._zoom);var l=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),o?i&&i.pinch&&this.fire("zoom",i):((l||i&&i.pinch)&&this.fire("zoom",i),this.fire("move",i)),this},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return rt(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){$(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[f(this._container)]=this;var e=t?W:O;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),T.any3d&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){rt(this._resizeRequest),this._resizeRequest=ot(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var t=this._getMapPanePos();Math.max(Math.abs(t.x),Math.abs(t.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(t,e){for(var i=[],o,l=e==="mouseout"||e==="mouseover",d=t.target||t.srcElement,p=!1;d;){if(o=this._targets[f(d)],o&&(e==="click"||e==="preclick")&&this._draggableMoved(o)){p=!0;break}if(o&&o.listens(e,!0)&&(l&&!ki(d,t)||(i.push(o),l))||d===this._container)break;d=d.parentNode}return!i.length&&!p&&!l&&this.listens(e,!0)&&(i=[this]),i},_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||t.type==="click"&&this._isClickDisabled(e))){var i=t.type;i==="mousedown"&&vi(e),this._fireDOMEvent(t,i)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,e,i){if(t.type==="click"){var o=n({},t);o.type="preclick",this._fireDOMEvent(o,o.type,i)}var l=this._findEventTargets(t,e);if(i){for(var d=[],p=0;p<i.length;p++)i[p].listens(e,!0)&&d.push(i[p]);l=d.concat(l)}if(l.length){e==="contextmenu"&&nt(t);var v=l[0],y={originalEvent:t};if(t.type!=="keypress"&&t.type!=="keydown"&&t.type!=="keyup"){var b=v.getLatLng&&(!v._radius||v._radius<=10);y.containerPoint=b?this.latLngToContainerPoint(v.getLatLng()):this.mouseEventToContainerPoint(t),y.layerPoint=this.containerPointToLayerPoint(y.containerPoint),y.latlng=b?v.getLatLng():this.layerPointToLatLng(y.layerPoint)}for(p=0;p<l.length;p++)if(l[p].fire(e,y,!0),y.originalEvent._stopped||l[p].options.bubblingMouseEvents===!1&&G(this._mouseEvents,e)!==-1)return}},_draggableMoved:function(t){return t=t.dragging&&t.dragging.enabled()?t:this,t.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 Rt(this._mapPane)||new z(0,0)},_moved:function(){var t=this._getMapPanePos();return t&&!t.equals([0,0])},_getTopLeftPoint:function(t,e){var i=t&&e!==void 0?this._getNewPixelOrigin(t,e):this.getPixelOrigin();return i.subtract(this._getMapPanePos())},_getNewPixelOrigin:function(t,e){var i=this.getSize()._divideBy(2);return this.project(t,e)._subtract(i)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(t,e,i){var o=this._getNewPixelOrigin(i,e);return this.project(t,e)._subtract(o)},_latLngBoundsToNewLayerBounds:function(t,e,i){var o=this._getNewPixelOrigin(i,e);return lt([this.project(t.getSouthWest(),e)._subtract(o),this.project(t.getNorthWest(),e)._subtract(o),this.project(t.getSouthEast(),e)._subtract(o),this.project(t.getNorthEast(),e)._subtract(o)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(t){return this.latLngToLayerPoint(t).subtract(this._getCenterLayerPoint())},_limitCenter:function(t,e,i){if(!i)return t;var o=this.project(t,e),l=this.getSize().divideBy(2),d=new j(o.subtract(l),o.add(l)),p=this._getBoundsOffset(d,i,e);return Math.abs(p.x)<=1&&Math.abs(p.y)<=1?t:this.unproject(o.add(p),e)},_limitOffset:function(t,e){if(!e)return t;var i=this.getPixelBounds(),o=new j(i.min.add(t),i.max.add(t));return t.add(this._getBoundsOffset(o,e))},_getBoundsOffset:function(t,e,i){var o=lt(this.project(e.getNorthEast(),i),this.project(e.getSouthWest(),i)),l=o.min.subtract(t.min),d=o.max.subtract(t.max),p=this._rebound(l.x,-d.x),v=this._rebound(l.y,-d.y);return new z(p,v)},_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(),i=this.getMaxZoom(),o=T.any3d?this.options.zoomSnap:1;return o&&(t=Math.round(t/o)*o),Math.max(e,Math.min(i,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){K(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,e){var i=this._getCenterOffset(t)._trunc();return(e&&e.animate)!==!0&&!this.getSize().contains(i)?!1:(this.panBy(i,e),!0)},_createAnimProxy:function(){var t=this._proxy=F("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(e){var i=di,o=this._proxy.style[i];Bt(this._proxy,this.project(e.center,e.zoom),this.getZoomScale(e.zoom,1)),o===this._proxy.style[i]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){J(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var t=this.getCenter(),e=this.getZoom();Bt(this._proxy,this.project(t,e),this.getZoomScale(e,1))},_catchTransitionEnd:function(t){this._animatingZoom&&t.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(t,e,i){if(this._animatingZoom)return!0;if(i=i||{},!this._zoomAnimated||i.animate===!1||this._nothingToAnimate()||Math.abs(e-this._zoom)>this.options.zoomAnimationThreshold)return!1;var o=this.getZoomScale(e),l=this._getCenterOffset(t)._divideBy(1-1/o);return i.animate!==!0&&!this.getSize().contains(l)?!1:(ot(function(){this._moveStart(!0,i.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,B(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(a(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&K(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom,void 0,!0),this._tempFireZoomEvent&&this.fire("zoom"),delete this._tempFireZoomEvent,this.fire("move"),this._moveEnd(!0))}});function Jr(t,e){return new Z(t,e)}var yt=pt.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),i=this.getPosition(),o=t._controlCorners[i];return B(e,"leaflet-control"),i.indexOf("bottom")!==-1?o.insertBefore(e,o.firstChild):o.appendChild(e),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(J(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()}}),ue=function(t){return new yt(t)};Z.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){var t=this._controlCorners={},e="leaflet-",i=this._controlContainer=F("div",e+"control-container",this._container);function o(l,d){var p=e+l+" "+e+d;t[l+d]=F("div",p,i)}o("top","left"),o("top","right"),o("bottom","left"),o("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)J(this._controlCorners[t]);J(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var Sn=yt.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,e,i,o){return i<o?-1:o<i?1:0}},initialize:function(t,e,i){P(this,i),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1,this._preventClick=!1;for(var o in t)this._addLayer(t[o],o);for(o in e)this._addLayer(e[o],o,!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 yt.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(f(t));return e&&this._layers.splice(this._layers.indexOf(e),1),this._map?this._update():this},expand:function(){B(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?(B(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=t+"px"):K(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return K(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var t="leaflet-control-layers",e=this._container=F("div",t),i=this.options.collapsed;e.setAttribute("aria-haspopup",!0),de(e),xi(e);var o=this._section=F("section",t+"-list");i&&(this._map.on("click",this.collapse,this),O(e,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var l=this._layersLink=F("a",t+"-toggle",e);l.href="#",l.title="Layers",l.setAttribute("role","button"),O(l,{keydown:function(d){d.keyCode===13&&this._expandSafely()},click:function(d){nt(d),this._expandSafely()}},this),i||this.expand(),this._baseLayersList=F("div",t+"-base",o),this._separator=F("div",t+"-separator",o),this._overlaysList=F("div",t+"-overlays",o),e.appendChild(o)},_getLayer:function(t){for(var e=0;e<this._layers.length;e++)if(this._layers[e]&&f(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(a(function(o,l){return this.options.sortFunction(o.layer,l.layer,o.name,l.name)},this)),this.options.autoZIndex&&t.setZIndex&&(this._lastZIndex++,t.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Te(this._baseLayersList),Te(this._overlaysList),this._layerControlInputs=[];var t,e,i,o,l=0;for(i=0;i<this._layers.length;i++)o=this._layers[i],this._addItem(o),e=e||o.overlay,t=t||!o.overlay,l+=o.overlay?0:1;return this.options.hideSingleBase&&(t=t&&l>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(f(t.target)),i=e.overlay?t.type==="add"?"overlayadd":"overlayremove":t.type==="add"?"baselayerchange":null;i&&this._map.fire(i,e)},_createRadioElement:function(t,e){var i='<input type="radio" class="leaflet-control-layers-selector" name="'+t+'"'+(e?' checked="checked"':"")+"/>",o=document.createElement("div");return o.innerHTML=i,o.firstChild},_addItem:function(t){var e=document.createElement("label"),i=this._map.hasLayer(t.layer),o;t.overlay?(o=document.createElement("input"),o.type="checkbox",o.className="leaflet-control-layers-selector",o.defaultChecked=i):o=this._createRadioElement("leaflet-base-layers_"+f(this),i),this._layerControlInputs.push(o),o.layerId=f(t.layer),O(o,"click",this._onInputClick,this);var l=document.createElement("span");l.innerHTML=" "+t.name;var d=document.createElement("span");e.appendChild(d),d.appendChild(o),d.appendChild(l);var p=t.overlay?this._overlaysList:this._baseLayersList;return p.appendChild(e),this._checkDisabledLayers(),e},_onInputClick:function(){if(!this._preventClick){var t=this._layerControlInputs,e,i,o=[],l=[];this._handlingClick=!0;for(var d=t.length-1;d>=0;d--)e=t[d],i=this._getLayer(e.layerId).layer,e.checked?o.push(i):e.checked||l.push(i);for(d=0;d<l.length;d++)this._map.hasLayer(l[d])&&this._map.removeLayer(l[d]);for(d=0;d<o.length;d++)this._map.hasLayer(o[d])||this._map.addLayer(o[d]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var t=this._layerControlInputs,e,i,o=this._map.getZoom(),l=t.length-1;l>=0;l--)e=t[l],i=this._getLayer(e.layerId).layer,e.disabled=i.options.minZoom!==void 0&&o<i.options.minZoom||i.options.maxZoom!==void 0&&o>i.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var t=this._section;this._preventClick=!0,O(t,"click",nt),this.expand();var e=this;setTimeout(function(){W(t,"click",nt),e._preventClick=!1})}}),Kr=function(t,e,i){return new Sn(t,e,i)},Ai=yt.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",i=F("div",e+" leaflet-bar"),o=this.options;return this._zoomInButton=this._createButton(o.zoomInText,o.zoomInTitle,e+"-in",i,this._zoomIn),this._zoomOutButton=this._createButton(o.zoomOutText,o.zoomOutTitle,e+"-out",i,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),i},onRemove:function(t){t.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(t){!this._disabled&&this._map._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,i,o,l){var d=F("a",i,o);return d.innerHTML=t,d.href="#",d.title=e,d.setAttribute("role","button"),d.setAttribute("aria-label",e),de(d),O(d,"click",Nt),O(d,"click",l,this),O(d,"click",this._refocusOnMap,this),d},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";K(this._zoomInButton,e),K(this._zoomOutButton,e),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||t._zoom===t.getMinZoom())&&(B(this._zoomOutButton,e),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||t._zoom===t.getMaxZoom())&&(B(this._zoomInButton,e),this._zoomInButton.setAttribute("aria-disabled","true"))}});Z.mergeOptions({zoomControl:!0}),Z.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new Ai,this.addControl(this.zoomControl))});var Xr=function(t){return new Ai(t)},Dn=yt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",i=F("div",e),o=this.options;return this._addScales(o,e+"-line",i),t.on(o.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),i},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,e,i){t.metric&&(this._mScale=F("div",e,i)),t.imperial&&(this._iScale=F("div",e,i))},_update:function(){var t=this._map,e=t.getSize().y/2,i=t.distance(t.containerPointToLatLng([0,e]),t.containerPointToLatLng([this.options.maxWidth,e]));this._updateScales(i)},_updateScales:function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},_updateMetric:function(t){var e=this._getRoundNum(t),i=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,i,e/t)},_updateImperial:function(t){var e=t*3.2808399,i,o,l;e>5280?(i=e/5280,o=this._getRoundNum(i),this._updateScale(this._iScale,o+" mi",o/i)):(l=this._getRoundNum(e),this._updateScale(this._iScale,l+" ft",l/e))},_updateScale:function(t,e,i){t.style.width=Math.round(this.options.maxWidth*i)+"px",t.innerHTML=e},_getRoundNum:function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),i=t/e;return i=i>=10?10:i>=5?5:i>=3?3:i>=2?2:1,e*i}}),Qr=function(t){return new Dn(t)},$r='<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>',Mi=yt.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(T.inlineSvg?$r+" ":"")+"Leaflet</a>"},initialize:function(t){P(this,t),this._attributions={}},onAdd:function(t){t.attributionControl=this,this._container=F("div","leaflet-control-attribution"),de(this._container);for(var e in 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 i=[];this.options.prefix&&i.push(this.options.prefix),t.length&&i.push(t.join(", ")),this._container.innerHTML=i.join(' <span aria-hidden="true">|</span> ')}}});Z.mergeOptions({attributionControl:!0}),Z.addInitHook(function(){this.options.attributionControl&&new Mi().addTo(this)});var ts=function(t){return new Mi(t)};yt.Layers=Sn,yt.Zoom=Ai,yt.Scale=Dn,yt.Attribution=Mi,ue.layers=Kr,ue.zoom=Xr,ue.scale=Qr,ue.attribution=ts;var xt=pt.extend({initialize:function(t){this._map=t},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});xt.addTo=function(t,e){return t.addHandler(e,this),this};var es={Events:ft},In=T.touch?"touchstart mousedown":"mousedown",Dt=ne.extend({options:{clickTolerance:3},initialize:function(t,e,i,o){P(this,o),this._element=t,this._dragStartTarget=e||t,this._preventOutline=i},enable:function(){this._enabled||(O(this._dragStartTarget,In,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(Dt._dragging===this&&this.finishDrag(!0),W(this._dragStartTarget,In,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(this._enabled&&(this._moved=!1,!ui(this._element,"leaflet-zoom-anim"))){if(t.touches&&t.touches.length!==1){Dt._dragging===this&&this.finishDrag();return}if(!(Dt._dragging||t.shiftKey||t.which!==1&&t.button!==1&&!t.touches)&&(Dt._dragging=this,this._preventOutline&&vi(this._element),mi(),le(),!this._moving)){this.fire("down");var e=t.touches?t.touches[0]:t,i=An(this._element);this._startPoint=new z(e.clientX,e.clientY),this._startPos=Rt(this._element),this._parentScale=yi(i);var o=t.type==="mousedown";O(document,o?"mousemove":"touchmove",this._onMove,this),O(document,o?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(t){if(this._enabled){if(t.touches&&t.touches.length>1){this._moved=!0;return}var e=t.touches&&t.touches.length===1?t.touches[0]:t,i=new z(e.clientX,e.clientY)._subtract(this._startPoint);!i.x&&!i.y||Math.abs(i.x)+Math.abs(i.y)<this.options.clickTolerance||(i.x/=this._parentScale.x,i.y/=this._parentScale.y,nt(t),this._moved||(this.fire("dragstart"),this._moved=!0,B(document.body,"leaflet-dragging"),this._lastTarget=t.target||t.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),B(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(i),this._moving=!0,this._lastEvent=t,this._updatePosition())}},_updatePosition:function(){var t={originalEvent:this._lastEvent};this.fire("predrag",t),$(this._element,this._newPos),this.fire("drag",t)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(t){K(document.body,"leaflet-dragging"),this._lastTarget&&(K(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),W(document,"mousemove touchmove",this._onMove,this),W(document,"mouseup touchend touchcancel",this._onUp,this),_i(),he();var e=this._moved&&this._moving;this._moving=!1,Dt._dragging=!1,e&&this.fire("dragend",{noInertia:t,distance:this._newPos.distanceTo(this._startPos)})}});function zn(t,e,i){var o,l=[1,4,2,8],d,p,v,y,b,A,C,R;for(d=0,A=t.length;d<A;d++)t[d]._code=Zt(t[d],e);for(v=0;v<4;v++){for(C=l[v],o=[],d=0,A=t.length,p=A-1;d<A;p=d++)y=t[d],b=t[p],y._code&C?b._code&C||(R=ze(b,y,C,e,i),R._code=Zt(R,e),o.push(R)):(b._code&C&&(R=ze(b,y,C,e,i),R._code=Zt(R,e),o.push(R)),o.push(y));t=o}return t}function On(t,e){var i,o,l,d,p,v,y,b,A;if(!t||t.length===0)throw new Error("latlngs not passed");_t(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var C=N([0,0]),R=Q(t),st=R.getNorthWest().distanceTo(R.getSouthWest())*R.getNorthEast().distanceTo(R.getNorthWest());st<1700&&(C=Ei(t));var et=t.length,gt=[];for(i=0;i<et;i++){var ct=N(t[i]);gt.push(e.project(N([ct.lat-C.lat,ct.lng-C.lng])))}for(v=y=b=0,i=0,o=et-1;i<et;o=i++)l=gt[i],d=gt[o],p=l.y*d.x-d.y*l.x,y+=(l.x+d.x)*p,b+=(l.y+d.y)*p,v+=p*3;v===0?A=gt[0]:A=[y/v,b/v];var Qt=e.unproject(I(A));return N([Qt.lat+C.lat,Qt.lng+C.lng])}function Ei(t){for(var e=0,i=0,o=0,l=0;l<t.length;l++){var d=N(t[l]);e+=d.lat,i+=d.lng,o++}return N([e/o,i/o])}var is={__proto__:null,clipPolygon:zn,polygonCenter:On,centroid:Ei};function Bn(t,e){if(!e||!t.length)return t.slice();var i=e*e;return t=rs(t,i),t=os(t,i),t}function Rn(t,e,i){return Math.sqrt(fe(t,e,i,!0))}function ns(t,e,i){return fe(t,e,i)}function os(t,e){var i=t.length,o=typeof Uint8Array!="undefined"?Uint8Array:Array,l=new o(i);l[0]=l[i-1]=1,Pi(t,l,e,0,i-1);var d,p=[];for(d=0;d<i;d++)l[d]&&p.push(t[d]);return p}function Pi(t,e,i,o,l){var d=0,p,v,y;for(v=o+1;v<=l-1;v++)y=fe(t[v],t[o],t[l],!0),y>d&&(p=v,d=y);d>i&&(e[p]=1,Pi(t,e,i,o,p),Pi(t,e,i,p,l))}function rs(t,e){for(var i=[t[0]],o=1,l=0,d=t.length;o<d;o++)ss(t[o],t[l])>e&&(i.push(t[o]),l=o);return l<d-1&&i.push(t[d-1]),i}var Un;function Nn(t,e,i,o,l){var d=o?Un:Zt(t,i),p=Zt(e,i),v,y,b;for(Un=p;;){if(!(d|p))return[t,e];if(d&p)return!1;v=d||p,y=ze(t,e,v,i,l),b=Zt(y,i),v===d?(t=y,d=b):(e=y,p=b)}}function ze(t,e,i,o,l){var d=e.x-t.x,p=e.y-t.y,v=o.min,y=o.max,b,A;return i&8?(b=t.x+d*(y.y-t.y)/p,A=y.y):i&4?(b=t.x+d*(v.y-t.y)/p,A=v.y):i&2?(b=y.x,A=t.y+p*(y.x-t.x)/d):i&1&&(b=v.x,A=t.y+p*(v.x-t.x)/d),new z(b,A,l)}function Zt(t,e){var i=0;return t.x<e.min.x?i|=1:t.x>e.max.x&&(i|=2),t.y<e.min.y?i|=4:t.y>e.max.y&&(i|=8),i}function ss(t,e){var i=e.x-t.x,o=e.y-t.y;return i*i+o*o}function fe(t,e,i,o){var l=e.x,d=e.y,p=i.x-l,v=i.y-d,y=p*p+v*v,b;return y>0&&(b=((t.x-l)*p+(t.y-d)*v)/y,b>1?(l=i.x,d=i.y):b>0&&(l+=p*b,d+=v*b)),p=t.x-l,v=t.y-d,o?p*p+v*v:new z(l,d)}function _t(t){return!D(t[0])||typeof t[0][0]!="object"&&typeof t[0][0]!="undefined"}function Zn(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),_t(t)}function Hn(t,e){var i,o,l,d,p,v,y,b;if(!t||t.length===0)throw new Error("latlngs not passed");_t(t)||(console.warn("latlngs are not flat! Only the first ring will be used"),t=t[0]);var A=N([0,0]),C=Q(t),R=C.getNorthWest().distanceTo(C.getSouthWest())*C.getNorthEast().distanceTo(C.getNorthWest());R<1700&&(A=Ei(t));var st=t.length,et=[];for(i=0;i<st;i++){var gt=N(t[i]);et.push(e.project(N([gt.lat-A.lat,gt.lng-A.lng])))}for(i=0,o=0;i<st-1;i++)o+=et[i].distanceTo(et[i+1])/2;if(o===0)b=et[0];else for(i=0,d=0;i<st-1;i++)if(p=et[i],v=et[i+1],l=p.distanceTo(v),d+=l,d>o){y=(d-o)/l,b=[v.x-y*(v.x-p.x),v.y-y*(v.y-p.y)];break}var ct=e.unproject(I(b));return N([ct.lat+A.lat,ct.lng+A.lng])}var as={__proto__:null,simplify:Bn,pointToSegmentDistance:Rn,closestPointOnSegment:ns,clipSegment:Nn,_getEdgeIntersection:ze,_getBitCode:Zt,_sqClosestPointOnSegment:fe,isFlat:_t,_flat:Zn,polylineCenter:Hn},Ti={project:function(t){return new z(t.lng,t.lat)},unproject:function(t){return new V(t.y,t.x)},bounds:new j([-180,-90],[180,90])},Ci={R:6378137,R_MINOR:6356752314245179e-9,bounds:new j([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(t){var e=Math.PI/180,i=this.R,o=t.lat*e,l=this.R_MINOR/i,d=Math.sqrt(1-l*l),p=d*Math.sin(o),v=Math.tan(Math.PI/4-o/2)/Math.pow((1-p)/(1+p),d/2);return o=-i*Math.log(Math.max(v,1e-10)),new z(t.lng*e*i,o)},unproject:function(t){for(var e=180/Math.PI,i=this.R,o=this.R_MINOR/i,l=Math.sqrt(1-o*o),d=Math.exp(-t.y/i),p=Math.PI/2-2*Math.atan(d),v=0,y=.1,b;v<15&&Math.abs(y)>1e-7;v++)b=l*Math.sin(p),b=Math.pow((1-b)/(1+b),l/2),y=Math.PI/2-2*Math.atan(d*b)-p,p+=y;return new V(p*e,t.x*e/i)}},ls={__proto__:null,LonLat:Ti,Mercator:Ci,SphericalMercator:ii},hs=n({},St,{code:"EPSG:3395",projection:Ci,transformation:(function(){var t=.5/(Math.PI*Ci.R);return oe(t,.5,-t,.5)})()}),Fn=n({},St,{code:"EPSG:4326",projection:Ti,transformation:oe(1/180,1,-1/180,.5)}),cs=n({},At,{projection:Ti,transformation:oe(1,0,-1,0),scale:function(t){return Math.pow(2,t)},zoom:function(t){return Math.log(t)/Math.LN2},distance:function(t,e){var i=e.lng-t.lng,o=e.lat-t.lat;return Math.sqrt(i*i+o*o)},infinite:!0});At.Earth=St,At.EPSG3395=hs,At.EPSG3857=oi,At.EPSG900913=_r,At.EPSG4326=Fn,At.Simple=cs;var Lt=ne.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(t){return t.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(t){return t&&t.removeLayer(this),this},getPane:function(t){return this._map.getPane(t?this.options[t]||t:this.options.pane)},addInteractiveTarget:function(t){return this._map._targets[f(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[f(t)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(t){var e=t.target;if(e.hasLayer(this)){if(this._map=e,this._zoomAnimated=e._zoomAnimated,this.getEvents){var i=this.getEvents();e.on(i,this),this.once("remove",function(){e.off(i,this)},this)}this.onAdd(e),this.fire("add"),e.fire("layeradd",{layer:this})}}});Z.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var e=f(t);return this._layers[e]?this:(this._layers[e]=t,t._mapToAdd=this,t.beforeAdd&&t.beforeAdd(this),this.whenReady(t._layerAdd,t),this)},removeLayer:function(t){var e=f(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 f(t)in this._layers},eachLayer:function(t,e){for(var i in this._layers)t.call(e,this._layers[i]);return this},_addLayers:function(t){t=t?D(t)?t:[t]:[];for(var e=0,i=t.length;e<i;e++)this.addLayer(t[e])},_addZoomLimit:function(t){(!isNaN(t.options.maxZoom)||!isNaN(t.options.minZoom))&&(this._zoomBoundLayers[f(t)]=t,this._updateZoomLevels())},_removeZoomLimit:function(t){var e=f(t);this._zoomBoundLayers[e]&&(delete this._zoomBoundLayers[e],this._updateZoomLevels())},_updateZoomLevels:function(){var t=1/0,e=-1/0,i=this._getZoomSpan();for(var o in this._zoomBoundLayers){var l=this._zoomBoundLayers[o].options;t=l.minZoom===void 0?t:Math.min(t,l.minZoom),e=l.maxZoom===void 0?e:Math.max(e,l.maxZoom)}this._layersMaxZoom=e===-1/0?void 0:e,this._layersMinZoom=t===1/0?void 0:t,i!==this._getZoomSpan()&&this.fire("zoomlevelschange"),this.options.maxZoom===void 0&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var qt=Lt.extend({initialize:function(t,e){P(this,e),this._layers={};var i,o;if(t)for(i=0,o=t.length;i<o;i++)this.addLayer(t[i])},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){var e=typeof t=="number"?t:this.getLayerId(t);return e in this._layers},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(t){var e=Array.prototype.slice.call(arguments,1),i,o;for(i in this._layers)o=this._layers[i],o[t]&&o[t].apply(o,e);return this},onAdd:function(t){this.eachLayer(t.addLayer,t)},onRemove:function(t){this.eachLayer(t.removeLayer,t)},eachLayer:function(t,e){for(var i in this._layers)t.call(e,this._layers[i]);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 f(t)}}),ds=function(t,e){return new qt(t,e)},Mt=qt.extend({addLayer:function(t){return this.hasLayer(t)?this:(t.addEventParent(this),qt.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),qt.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 ht;for(var e in this._layers){var i=this._layers[e];t.extend(i.getBounds?i.getBounds():i.getLatLng())}return t}}),us=function(t,e){return new Mt(t,e)},jt=pt.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 i=this._getIconUrl(t);if(!i){if(t==="icon")throw new Error("iconUrl not set in Icon options (see the docs).");return null}var o=this._createImg(i,e&&e.tagName==="IMG"?e:null);return this._setIconStyles(o,t),(this.options.crossOrigin||this.options.crossOrigin==="")&&(o.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),o},_setIconStyles:function(t,e){var i=this.options,o=i[e+"Size"];typeof o=="number"&&(o=[o,o]);var l=I(o),d=I(e==="shadow"&&i.shadowAnchor||i.iconAnchor||l&&l.divideBy(2,!0));t.className="leaflet-marker-"+e+" "+(i.className||""),d&&(t.style.marginLeft=-d.x+"px",t.style.marginTop=-d.y+"px"),l&&(t.style.width=l.x+"px",t.style.height=l.y+"px")},_createImg:function(t,e){return e=e||document.createElement("img"),e.src=t,e},_getIconUrl:function(t){return T.retina&&this.options[t+"RetinaUrl"]||this.options[t+"Url"]}});function fs(t){return new jt(t)}var pe=jt.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 typeof pe.imagePath!="string"&&(pe.imagePath=this._detectIconPath()),(this.options.imagePath||pe.imagePath)+jt.prototype._getIconUrl.call(this,t)},_stripUrl:function(t){var e=function(i,o,l){var d=o.exec(i);return d&&d[l]};return t=e(t,/^url\((['"])?(.+)\1\)$/,2),t&&e(t,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var t=F("div","leaflet-default-icon-path",document.body),e=ae(t,"background-image")||ae(t,"backgroundImage");if(document.body.removeChild(t),e=this._stripUrl(e),e)return e;var i=document.querySelector('link[href$="leaflet.css"]');return i?i.href.substring(0,i.href.length-11-1):""}}),Gn=xt.extend({initialize:function(t){this._marker=t},addHooks:function(){var t=this._marker._icon;this._draggable||(this._draggable=new Dt(t,t,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),B(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&&K(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(t){var e=this._marker,i=e._map,o=this._marker.options.autoPanSpeed,l=this._marker.options.autoPanPadding,d=Rt(e._icon),p=i.getPixelBounds(),v=i.getPixelOrigin(),y=lt(p.min._subtract(v).add(l),p.max._subtract(v).subtract(l));if(!y.contains(d)){var b=I((Math.max(y.max.x,d.x)-y.max.x)/(p.max.x-y.max.x)-(Math.min(y.min.x,d.x)-y.min.x)/(p.min.x-y.min.x),(Math.max(y.max.y,d.y)-y.max.y)/(p.max.y-y.max.y)-(Math.min(y.min.y,d.y)-y.min.y)/(p.min.y-y.min.y)).multiplyBy(o);i.panBy(b,{animate:!1}),this._draggable._newPos._add(b),this._draggable._startPos._add(b),$(e._icon,this._draggable._newPos),this._onDrag(t),this._panRequest=ot(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&&(rt(this._panRequest),this._panRequest=ot(this._adjustPan.bind(this,t)))},_onDrag:function(t){var e=this._marker,i=e._shadow,o=Rt(e._icon),l=e._map.layerPointToLatLng(o);i&&$(i,o),e._latlng=l,t.latlng=l,t.oldLatLng=this._oldLatLng,e.fire("move",t).fire("drag",t)},_onDragEnd:function(t){rt(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",t)}}),Oe=Lt.extend({options:{icon:new pe,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=N(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=N(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"),i=t.icon.createIcon(this._icon),o=!1;i!==this._icon&&(this._icon&&this._removeIcon(),o=!0,t.title&&(i.title=t.title),i.tagName==="IMG"&&(i.alt=t.alt||"")),B(i,e),t.keyboard&&(i.tabIndex="0",i.setAttribute("role","button")),this._icon=i,t.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&O(i,"focus",this._panOnFocus,this);var l=t.icon.createShadow(this._shadow),d=!1;l!==this._shadow&&(this._removeShadow(),d=!0),l&&(B(l,e),l.alt=""),this._shadow=l,t.opacity<1&&this._updateOpacity(),o&&this.getPane().appendChild(this._icon),this._initInteraction(),l&&d&&this.getPane(t.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&W(this._icon,"focus",this._panOnFocus,this),J(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&J(this._shadow),this._shadow=null},_setPos:function(t){this._icon&&$(this._icon,t),this._shadow&&$(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&&(B(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),Gn)){var t=this.options.draggable;this.dragging&&(t=this.dragging.enabled(),this.dragging.disable()),this.dragging=new Gn(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&&mt(this._icon,t),this._shadow&&mt(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,i=e.iconSize?I(e.iconSize):I(0,0),o=e.iconAnchor?I(e.iconAnchor):I(0,0);t.panInside(this._latlng,{paddingTopLeft:o,paddingBottomRight:i.subtract(o)})}},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}});function ps(t,e){return new Oe(t,e)}var It=Lt.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)}}),Be=It.extend({options:{fill:!0,radius:10},initialize:function(t,e){P(this,e),this._latlng=N(t),this._radius=this.options.radius},setLatLng:function(t){var e=this._latlng;return this._latlng=N(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 It.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,i=this._clickTolerance(),o=[t+i,e+i];this._pxBounds=new j(this._point.subtract(o),this._point.add(o))},_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()}});function ms(t,e){return new Be(t,e)}var Si=Be.extend({initialize:function(t,e,i){if(typeof e=="number"&&(e=n({},i,{radius:e})),P(this,e),this._latlng=N(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 ht(this._map.layerPointToLatLng(this._point.subtract(t)),this._map.layerPointToLatLng(this._point.add(t)))},setStyle:It.prototype.setStyle,_project:function(){var t=this._latlng.lng,e=this._latlng.lat,i=this._map,o=i.options.crs;if(o.distance===St.distance){var l=Math.PI/180,d=this._mRadius/St.R/l,p=i.project([e+d,t]),v=i.project([e-d,t]),y=p.add(v).divideBy(2),b=i.unproject(y).lat,A=Math.acos((Math.cos(d*l)-Math.sin(e*l)*Math.sin(b*l))/(Math.cos(e*l)*Math.cos(b*l)))/l;(isNaN(A)||A===0)&&(A=d/Math.cos(Math.PI/180*e)),this._point=y.subtract(i.getPixelOrigin()),this._radius=isNaN(A)?0:y.x-i.project([b,t-A]).x,this._radiusY=y.y-p.y}else{var C=o.unproject(o.project(this._latlng).subtract([this._mRadius,0]));this._point=i.latLngToLayerPoint(this._latlng),this._radius=this._point.x-i.latLngToLayerPoint(C).x}this._updateBounds()}});function _s(t,e,i){return new Si(t,e,i)}var Et=It.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=1/0,i=null,o=fe,l,d,p=0,v=this._parts.length;p<v;p++)for(var y=this._parts[p],b=1,A=y.length;b<A;b++){l=y[b-1],d=y[b];var C=o(t,l,d,!0);C<e&&(e=C,i=o(t,l,d))}return i&&(i.distance=Math.sqrt(e)),i},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return Hn(this._defaultShape(),this._map.options.crs)},getBounds:function(){return this._bounds},addLatLng:function(t,e){return e=e||this._defaultShape(),t=N(t),e.push(t),this._bounds.extend(t),this.redraw()},_setLatLngs:function(t){this._bounds=new ht,this._latlngs=this._convertLatLngs(t)},_defaultShape:function(){return _t(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(t){for(var e=[],i=_t(t),o=0,l=t.length;o<l;o++)i?(e[o]=N(t[o]),this._bounds.extend(e[o])):e[o]=this._convertLatLngs(t[o]);return e},_project:function(){var t=new j;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 z(t,t);this._rawPxBounds&&(this._pxBounds=new j([this._rawPxBounds.min.subtract(e),this._rawPxBounds.max.add(e)]))},_projectLatlngs:function(t,e,i){var o=t[0]instanceof V,l=t.length,d,p;if(o){for(p=[],d=0;d<l;d++)p[d]=this._map.latLngToLayerPoint(t[d]),i.extend(p[d]);e.push(p)}else for(d=0;d<l;d++)this._projectLatlngs(t[d],e,i)},_clipPoints:function(){var t=this._renderer._bounds;if(this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(t))){if(this.options.noClip){this._parts=this._rings;return}var e=this._parts,i,o,l,d,p,v,y;for(i=0,l=0,d=this._rings.length;i<d;i++)for(y=this._rings[i],o=0,p=y.length;o<p-1;o++)v=Nn(y[o],y[o+1],t,o,!0),v&&(e[l]=e[l]||[],e[l].push(v[0]),(v[1]!==y[o+1]||o===p-2)&&(e[l].push(v[1]),l++))}},_simplifyPoints:function(){for(var t=this._parts,e=this.options.smoothFactor,i=0,o=t.length;i<o;i++)t[i]=Bn(t[i],e)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(t,e){var i,o,l,d,p,v,y=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(i=0,d=this._parts.length;i<d;i++)for(v=this._parts[i],o=0,p=v.length,l=p-1;o<p;l=o++)if(!(!e&&o===0)&&Rn(t,v[l],v[o])<=y)return!0;return!1}});function gs(t,e){return new Et(t,e)}Et._flat=Zn;var Jt=Et.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 On(this._defaultShape(),this._map.options.crs)},_convertLatLngs:function(t){var e=Et.prototype._convertLatLngs.call(this,t),i=e.length;return i>=2&&e[0]instanceof V&&e[0].equals(e[i-1])&&e.pop(),e},_setLatLngs:function(t){Et.prototype._setLatLngs.call(this,t),_t(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return _t(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,e=this.options.weight,i=new z(e,e);if(t=new j(t.min.subtract(i),t.max.add(i)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(t))){if(this.options.noClip){this._parts=this._rings;return}for(var o=0,l=this._rings.length,d;o<l;o++)d=zn(this._rings[o],t,!0),d.length&&this._parts.push(d)}},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(t){var e=!1,i,o,l,d,p,v,y,b;if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(d=0,y=this._parts.length;d<y;d++)for(i=this._parts[d],p=0,b=i.length,v=b-1;p<b;v=p++)o=i[p],l=i[v],o.y>t.y!=l.y>t.y&&t.x<(l.x-o.x)*(t.y-o.y)/(l.y-o.y)+o.x&&(e=!e);return e||Et.prototype._containsPoint.call(this,t,!0)}});function vs(t,e){return new Jt(t,e)}var Pt=Mt.extend({initialize:function(t,e){P(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e=D(t)?t:t.features,i,o,l;if(e){for(i=0,o=e.length;i<o;i++)l=e[i],(l.geometries||l.geometry||l.features||l.coordinates)&&this.addData(l);return this}var d=this.options;if(d.filter&&!d.filter(t))return this;var p=Re(t,d);return p?(p.feature=Ze(t),p.defaultOptions=p.options,this.resetStyle(p),d.onEachFeature&&d.onEachFeature(t,p),this.addLayer(p)):this},resetStyle:function(t){return t===void 0?this.eachLayer(this.resetStyle,this):(t.options=n({},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&&(typeof e=="function"&&(e=e(t.feature)),t.setStyle(e))}});function Re(t,e){var i=t.type==="Feature"?t.geometry:t,o=i?i.coordinates:null,l=[],d=e&&e.pointToLayer,p=e&&e.coordsToLatLng||Di,v,y,b,A;if(!o&&!i)return null;switch(i.type){case"Point":return v=p(o),Vn(d,t,v,e);case"MultiPoint":for(b=0,A=o.length;b<A;b++)v=p(o[b]),l.push(Vn(d,t,v,e));return new Mt(l);case"LineString":case"MultiLineString":return y=Ue(o,i.type==="LineString"?0:1,p),new Et(y,e);case"Polygon":case"MultiPolygon":return y=Ue(o,i.type==="Polygon"?1:2,p),new Jt(y,e);case"GeometryCollection":for(b=0,A=i.geometries.length;b<A;b++){var C=Re({geometry:i.geometries[b],type:"Feature",properties:t.properties},e);C&&l.push(C)}return new Mt(l);case"FeatureCollection":for(b=0,A=i.features.length;b<A;b++){var R=Re(i.features[b],e);R&&l.push(R)}return new Mt(l);default:throw new Error("Invalid GeoJSON object.")}}function Vn(t,e,i,o){return t?t(e,i):new Oe(i,o&&o.markersInheritOptions&&o)}function Di(t){return new V(t[1],t[0],t[2])}function Ue(t,e,i){for(var o=[],l=0,d=t.length,p;l<d;l++)p=e?Ue(t[l],e-1,i):(i||Di)(t[l]),o.push(p);return o}function Ii(t,e){return t=N(t),t.alt!==void 0?[x(t.lng,e),x(t.lat,e),x(t.alt,e)]:[x(t.lng,e),x(t.lat,e)]}function Ne(t,e,i,o){for(var l=[],d=0,p=t.length;d<p;d++)l.push(e?Ne(t[d],_t(t[d])?0:e-1,i,o):Ii(t[d],o));return!e&&i&&l.length>0&&l.push(l[0].slice()),l}function Kt(t,e){return t.feature?n({},t.feature,{geometry:e}):Ze(e)}function Ze(t){return t.type==="Feature"||t.type==="FeatureCollection"?t:{type:"Feature",properties:{},geometry:t}}var zi={toGeoJSON:function(t){return Kt(this,{type:"Point",coordinates:Ii(this.getLatLng(),t)})}};Oe.include(zi),Si.include(zi),Be.include(zi),Et.include({toGeoJSON:function(t){var e=!_t(this._latlngs),i=Ne(this._latlngs,e?1:0,!1,t);return Kt(this,{type:(e?"Multi":"")+"LineString",coordinates:i})}}),Jt.include({toGeoJSON:function(t){var e=!_t(this._latlngs),i=e&&!_t(this._latlngs[0]),o=Ne(this._latlngs,i?2:e?1:0,!0,t);return e||(o=[o]),Kt(this,{type:(i?"Multi":"")+"Polygon",coordinates:o})}}),qt.include({toMultiPoint:function(t){var e=[];return this.eachLayer(function(i){e.push(i.toGeoJSON(t).geometry.coordinates)}),Kt(this,{type:"MultiPoint",coordinates:e})},toGeoJSON:function(t){var e=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(e==="MultiPoint")return this.toMultiPoint(t);var i=e==="GeometryCollection",o=[];return this.eachLayer(function(l){if(l.toGeoJSON){var d=l.toGeoJSON(t);if(i)o.push(d.geometry);else{var p=Ze(d);p.type==="FeatureCollection"?o.push.apply(o,p.features):o.push(p)}}}),i?Kt(this,{geometries:o,type:"GeometryCollection"}):{type:"FeatureCollection",features:o}}});function Wn(t,e){return new Pt(t,e)}var ys=Wn,He=Lt.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(t,e,i){this._url=t,this._bounds=Q(e),P(this,i)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(B(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){J(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&&Wt(this._image),this},bringToBack:function(){return this._map&&Yt(this._image),this},setUrl:function(t){return this._url=t,this._image&&(this._image.src=t),this},setBounds:function(t){return this._bounds=Q(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=this._url.tagName==="IMG",e=this._image=t?this._url:F("img");if(B(e,"leaflet-image-layer"),this._zoomAnimated&&B(e,"leaflet-zoom-animated"),this.options.className&&B(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onload=a(this.fire,this,"load"),e.onerror=a(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(e.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),t){this._url=e.src;return}e.src=this._url,e.alt=this.options.alt},_animateZoom:function(t){var e=this._map.getZoomScale(t.zoom),i=this._map._latLngBoundsToNewLayerBounds(this._bounds,t.zoom,t.center).min;Bt(this._image,i,e)},_reset:function(){var t=this._image,e=new j(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),i=e.getSize();$(t,e.min),t.style.width=i.x+"px",t.style.height=i.y+"px"},_updateOpacity:function(){mt(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(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()}}),Ls=function(t,e,i){return new He(t,e,i)},Yn=He.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var t=this._url.tagName==="VIDEO",e=this._image=t?this._url:F("video");if(B(e,"leaflet-image-layer"),this._zoomAnimated&&B(e,"leaflet-zoom-animated"),this.options.className&&B(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onloadeddata=a(this.fire,this,"load"),t){for(var i=e.getElementsByTagName("source"),o=[],l=0;l<i.length;l++)o.push(i[l].src);this._url=i.length>0?o:[e.src];return}D(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 d=0;d<this._url.length;d++){var p=F("source");p.src=this._url[d],e.appendChild(p)}}});function ws(t,e,i){return new Yn(t,e,i)}var qn=He.extend({_initImage:function(){var t=this._image=this._url;B(t,"leaflet-image-layer"),this._zoomAnimated&&B(t,"leaflet-zoom-animated"),this.options.className&&B(t,this.options.className),t.onselectstart=w,t.onmousemove=w}});function bs(t,e,i){return new qn(t,e,i)}var kt=Lt.extend({options:{interactive:!1,offset:[0,0],className:"",pane:void 0,content:""},initialize:function(t,e){t&&(t instanceof V||D(t))?(this._latlng=N(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,t.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&&mt(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),t._fadeAnimated&&mt(this._container,1),this.bringToFront(),this.options.interactive&&(B(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(t){t._fadeAnimated?(mt(this._container,0),this._removeTimeout=setTimeout(a(J,void 0,this._container),200)):J(this._container),this.options.interactive&&(K(this._container,"leaflet-interactive"),this.removeInteractiveTarget(this._container))},getLatLng:function(){return this._latlng},setLatLng:function(t){return this._latlng=N(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&&Wt(this._container),this},bringToBack:function(){return this._map&&Yt(this._container),this},_prepareOpen:function(t){var e=this._source;if(!e._map)return!1;if(e instanceof Mt){e=null;var i=this._source._layers;for(var o in i)if(i[o]._map){e=i[o];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)t=e.getBounds().getCenter();else throw new Error("Unable to get source layer LatLng.");return this.setLatLng(t),this._map&&this.update(),!0},_updateContent:function(){if(this._content){var t=this._contentNode,e=typeof this._content=="function"?this._content(this._source||this):this._content;if(typeof e=="string")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=I(this.options.offset),i=this._getAnchor();this._zoomAnimated?$(this._container,t.add(i)):e=e.add(t).add(i);var o=this._containerBottom=-e.y,l=this._containerLeft=-Math.round(this._containerWidth/2)+e.x;this._container.style.bottom=o+"px",this._container.style.left=l+"px"}},_getAnchor:function(){return[0,0]}});Z.include({_initOverlay:function(t,e,i,o){var l=e;return l instanceof t||(l=new t(o).setContent(e)),i&&l.setLatLng(i),l}}),Lt.include({_initOverlay:function(t,e,i,o){var l=i;return l instanceof t?(P(l,o),l._source=this):(l=e&&!o?e:new t(o,this),l.setContent(i)),l}});var Fe=kt.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,!t.hasLayer(this)&&t._popup&&t._popup.options.autoClose&&t.removeLayer(t._popup),t._popup=this,kt.prototype.openOn.call(this,t)},onAdd:function(t){kt.prototype.onAdd.call(this,t),t.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof It||this._source.on("preclick",Ut))},onRemove:function(t){kt.prototype.onRemove.call(this,t),t.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof It||this._source.off("preclick",Ut))},getEvents:function(){var t=kt.prototype.getEvents.call(this);return(this.options.closeOnClick!==void 0?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=F("div",t+" "+(this.options.className||"")+" leaflet-zoom-animated"),i=this._wrapper=F("div",t+"-content-wrapper",e);if(this._contentNode=F("div",t+"-content",i),de(e),xi(this._contentNode),O(e,"contextmenu",Ut),this._tipContainer=F("div",t+"-tip-container",e),this._tip=F("div",t+"-tip",this._tipContainer),this.options.closeButton){var o=this._closeButton=F("a",t+"-close-button",e);o.setAttribute("role","button"),o.setAttribute("aria-label","Close popup"),o.href="#close",o.innerHTML='<span aria-hidden="true">×</span>',O(o,"click",function(l){nt(l),this.close()},this)}},_updateLayout:function(){var t=this._contentNode,e=t.style;e.width="",e.whiteSpace="nowrap";var i=t.offsetWidth;i=Math.min(i,this.options.maxWidth),i=Math.max(i,this.options.minWidth),e.width=i+1+"px",e.whiteSpace="",e.height="";var o=t.offsetHeight,l=this.options.maxHeight,d="leaflet-popup-scrolled";l&&o>l?(e.height=l+"px",B(t,d)):K(t,d),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),i=this._getAnchor();$(this._container,e.add(i))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var t=this._map,e=parseInt(ae(this._container,"marginBottom"),10)||0,i=this._container.offsetHeight+e,o=this._containerWidth,l=new z(this._containerLeft,-i-this._containerBottom);l._add(Rt(this._container));var d=t.layerPointToContainerPoint(l),p=I(this.options.autoPanPadding),v=I(this.options.autoPanPaddingTopLeft||p),y=I(this.options.autoPanPaddingBottomRight||p),b=t.getSize(),A=0,C=0;d.x+o+y.x>b.x&&(A=d.x+o-b.x+y.x),d.x-A-v.x<0&&(A=d.x-v.x),d.y+i+y.y>b.y&&(C=d.y+i-b.y+y.y),d.y-C-v.y<0&&(C=d.y-v.y),(A||C)&&(this.options.keepInView&&(this._autopanning=!0),t.fire("autopanstart").panBy([A,C]))}},_getAnchor:function(){return I(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),xs=function(t,e){return new Fe(t,e)};Z.mergeOptions({closePopupOnClick:!0}),Z.include({openPopup:function(t,e,i){return this._initOverlay(Fe,t,e,i).openOn(this),this},closePopup:function(t){return t=arguments.length?t:this._popup,t&&t.close(),this}}),Lt.include({bindPopup:function(t,e){return this._popup=this._initOverlay(Fe,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 Mt||(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():!1},setPopupContent:function(t){return this._popup&&this._popup.setContent(t),this},getPopup:function(){return this._popup},_openPopup:function(t){if(!(!this._popup||!this._map)){Nt(t);var e=t.layer||t.target;if(this._popup._source===e&&!(e instanceof It)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(t.latlng);return}this._popup._source=e,this.openPopup(t.latlng)}},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){t.originalEvent.keyCode===13&&this._openPopup(t)}});var Ge=kt.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(t){kt.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){kt.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=kt.prototype.getEvents.call(this);return this.options.permanent||(t.preclick=this.close),t},_initLayout:function(){var t="leaflet-tooltip",e=t+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=F("div",e),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+f(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e,i,o=this._map,l=this._container,d=o.latLngToContainerPoint(o.getCenter()),p=o.layerPointToContainerPoint(t),v=this.options.direction,y=l.offsetWidth,b=l.offsetHeight,A=I(this.options.offset),C=this._getAnchor();v==="top"?(e=y/2,i=b):v==="bottom"?(e=y/2,i=0):v==="center"?(e=y/2,i=b/2):v==="right"?(e=0,i=b/2):v==="left"?(e=y,i=b/2):p.x<d.x?(v="right",e=0,i=b/2):(v="left",e=y+(A.x+C.x)*2,i=b/2),t=t.subtract(I(e,i,!0)).add(A).add(C),K(l,"leaflet-tooltip-right"),K(l,"leaflet-tooltip-left"),K(l,"leaflet-tooltip-top"),K(l,"leaflet-tooltip-bottom"),B(l,"leaflet-tooltip-"+v),$(l,t)},_updatePosition:function(){var t=this._map.latLngToLayerPoint(this._latlng);this._setPosition(t)},setOpacity:function(t){this.options.opacity=t,this._container&&mt(this._container,t)},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center);this._setPosition(e)},_getAnchor:function(){return I(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),ks=function(t,e){return new Ge(t,e)};Z.include({openTooltip:function(t,e,i){return this._initOverlay(Ge,t,e,i).openOn(this),this},closeTooltip:function(t){return t.close(),this}}),Lt.include({bindTooltip:function(t,e){return this._tooltip&&this.isTooltipOpen()&&this.unbindTooltip(),this._tooltip=this._initOverlay(Ge,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",i={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?i.add=this._openTooltip:(i.mouseover=this._openTooltip,i.mouseout=this.closeTooltip,i.click=this._openTooltip,this._map?this._addFocusListeners():i.add=this._addFocusListeners),this._tooltip.options.sticky&&(i.mousemove=this._moveTooltip),this[e](i),this._tooltipHandlersAdded=!t}},openTooltip:function(t){return this._tooltip&&(this instanceof Mt||(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=typeof t.getElement=="function"&&t.getElement();e&&(O(e,"focus",function(){this._tooltip._source=t,this.openTooltip()},this),O(e,"blur",this.closeTooltip,this))},_setAriaDescribedByOnLayer:function(t){var e=typeof t.getElement=="function"&&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)});return}this._tooltip._source=t.layer||t.target,this.openTooltip(this._tooltip.options.sticky?t.latlng:void 0)}},_moveTooltip:function(t){var e=t.latlng,i,o;this._tooltip.options.sticky&&t.originalEvent&&(i=this._map.mouseEventToContainerPoint(t.originalEvent),o=this._map.containerPointToLayerPoint(i),e=this._map.layerPointToLatLng(o)),this._tooltip.setLatLng(e)}});var jn=jt.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(t){var e=t&&t.tagName==="DIV"?t:document.createElement("div"),i=this.options;if(i.html instanceof Element?(Te(e),e.appendChild(i.html)):e.innerHTML=i.html!==!1?i.html:"",i.bgPos){var o=I(i.bgPos);e.style.backgroundPosition=-o.x+"px "+-o.y+"px"}return this._setIconStyles(e,"icon"),e},createShadow:function(){return null}});function As(t){return new jn(t)}jt.Default=pe;var me=Lt.extend({options:{tileSize:256,opacity:1,updateWhenIdle:T.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(),J(this._container),t._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Wt(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(Yt(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=_(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 z?t:new z(t,t)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(t){for(var e=this.getPane().children,i=-t(-1/0,1/0),o=0,l=e.length,d;o<l;o++)d=e[o].style.zIndex,e[o]!==this._container&&d&&(i=t(i,+d));isFinite(i)&&(this.options.zIndex=i+t(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!T.ielt9){mt(this._container,this.options.opacity);var t=+new Date,e=!1,i=!1;for(var o in this._tiles){var l=this._tiles[o];if(!(!l.current||!l.loaded)){var d=Math.min(1,(t-l.loaded)/200);mt(l.el,d),d<1?e=!0:(l.active?i=!0:this._onOpaqueTile(l),l.active=!0)}}i&&!this._noPrune&&this._pruneTiles(),e&&(rt(this._fadeFrame),this._fadeFrame=ot(this._updateOpacity,this))}},_onOpaqueTile:w,_initContainer:function(){this._container||(this._container=F("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(t!==void 0){for(var i in this._levels)i=Number(i),this._levels[i].el.children.length||i===t?(this._levels[i].el.style.zIndex=e-Math.abs(t-i),this._onUpdateLevel(i)):(J(this._levels[i].el),this._removeTilesAtZoom(i),this._onRemoveLevel(i),delete this._levels[i]);var o=this._levels[t],l=this._map;return o||(o=this._levels[t]={},o.el=F("div","leaflet-tile-container leaflet-zoom-animated",this._container),o.el.style.zIndex=e,o.origin=l.project(l.unproject(l.getPixelOrigin()),t).round(),o.zoom=t,this._setZoomTransform(o,l.getCenter(),l.getZoom()),w(o.el.offsetWidth),this._onCreateLevel(o)),this._level=o,o}},_onUpdateLevel:w,_onRemoveLevel:w,_onCreateLevel:w,_pruneTiles:function(){if(this._map){var t,e,i=this._map.getZoom();if(i>this.options.maxZoom||i<this.options.minZoom){this._removeAllTiles();return}for(t in this._tiles)e=this._tiles[t],e.retain=e.current;for(t in this._tiles)if(e=this._tiles[t],e.current&&!e.active){var o=e.coords;this._retainParent(o.x,o.y,o.z,o.z-5)||this._retainChildren(o.x,o.y,o.z,o.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)J(this._levels[t].el),this._onRemoveLevel(Number(t)),delete this._levels[t];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(t,e,i,o){var l=Math.floor(t/2),d=Math.floor(e/2),p=i-1,v=new z(+l,+d);v.z=+p;var y=this._tileCoordsToKey(v),b=this._tiles[y];return b&&b.active?(b.retain=!0,!0):(b&&b.loaded&&(b.retain=!0),p>o?this._retainParent(l,d,p,o):!1)},_retainChildren:function(t,e,i,o){for(var l=2*t;l<2*t+2;l++)for(var d=2*e;d<2*e+2;d++){var p=new z(l,d);p.z=i+1;var v=this._tileCoordsToKey(p),y=this._tiles[v];if(y&&y.active){y.retain=!0;continue}else y&&y.loaded&&(y.retain=!0);i+1<o&&this._retainChildren(l,d,i+1,o)}},_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 e.minNativeZoom!==void 0&&t<e.minNativeZoom?e.minNativeZoom:e.maxNativeZoom!==void 0&&e.maxNativeZoom<t?e.maxNativeZoom:t},_setView:function(t,e,i,o){var l=Math.round(e);this.options.maxZoom!==void 0&&l>this.options.maxZoom||this.options.minZoom!==void 0&&l<this.options.minZoom?l=void 0:l=this._clampZoom(l);var d=this.options.updateWhenZooming&&l!==this._tileZoom;(!o||d)&&(this._tileZoom=l,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),l!==void 0&&this._update(t),i||this._pruneTiles(),this._noPrune=!!i),this._setZoomTransforms(t,e)},_setZoomTransforms:function(t,e){for(var i in this._levels)this._setZoomTransform(this._levels[i],t,e)},_setZoomTransform:function(t,e,i){var o=this._map.getZoomScale(i,t.zoom),l=t.origin.multiplyBy(o).subtract(this._map._getNewPixelOrigin(e,i)).round();T.any3d?Bt(t.el,l,o):$(t.el,l)},_resetGrid:function(){var t=this._map,e=t.options.crs,i=this._tileSize=this.getTileSize(),o=this._tileZoom,l=this._map.getPixelWorldBounds(this._tileZoom);l&&(this._globalTileRange=this._pxBoundsToTileRange(l)),this._wrapX=e.wrapLng&&!this.options.noWrap&&[Math.floor(t.project([0,e.wrapLng[0]],o).x/i.x),Math.ceil(t.project([0,e.wrapLng[1]],o).x/i.y)],this._wrapY=e.wrapLat&&!this.options.noWrap&&[Math.floor(t.project([e.wrapLat[0],0],o).y/i.x),Math.ceil(t.project([e.wrapLat[1],0],o).y/i.y)]},_onMoveEnd:function(){!this._map||this._map._animatingZoom||this._update()},_getTiledPixelBounds:function(t){var e=this._map,i=e._animatingZoom?Math.max(e._animateToZoom,e.getZoom()):e.getZoom(),o=e.getZoomScale(i,this._tileZoom),l=e.project(t,this._tileZoom).floor(),d=e.getSize().divideBy(o*2);return new j(l.subtract(d),l.add(d))},_update:function(t){var e=this._map;if(e){var i=this._clampZoom(e.getZoom());if(t===void 0&&(t=e.getCenter()),this._tileZoom!==void 0){var o=this._getTiledPixelBounds(t),l=this._pxBoundsToTileRange(o),d=l.getCenter(),p=[],v=this.options.keepBuffer,y=new j(l.getBottomLeft().subtract([v,-v]),l.getTopRight().add([v,-v]));if(!(isFinite(l.min.x)&&isFinite(l.min.y)&&isFinite(l.max.x)&&isFinite(l.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var b in this._tiles){var A=this._tiles[b].coords;(A.z!==this._tileZoom||!y.contains(new z(A.x,A.y)))&&(this._tiles[b].current=!1)}if(Math.abs(i-this._tileZoom)>1){this._setView(t,i);return}for(var C=l.min.y;C<=l.max.y;C++)for(var R=l.min.x;R<=l.max.x;R++){var st=new z(R,C);if(st.z=this._tileZoom,!!this._isValidTile(st)){var et=this._tiles[this._tileCoordsToKey(st)];et?et.current=!0:p.push(st)}}if(p.sort(function(ct,Qt){return ct.distanceTo(d)-Qt.distanceTo(d)}),p.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var gt=document.createDocumentFragment();for(R=0;R<p.length;R++)this._addTile(p[R],gt);this._level.el.appendChild(gt)}}}},_isValidTile:function(t){var e=this._map.options.crs;if(!e.infinite){var i=this._globalTileRange;if(!e.wrapLng&&(t.x<i.min.x||t.x>i.max.x)||!e.wrapLat&&(t.y<i.min.y||t.y>i.max.y))return!1}if(!this.options.bounds)return!0;var o=this._tileCoordsToBounds(t);return Q(this.options.bounds).overlaps(o)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var e=this._map,i=this.getTileSize(),o=t.scaleBy(i),l=o.add(i),d=e.unproject(o,t.z),p=e.unproject(l,t.z);return[d,p]},_tileCoordsToBounds:function(t){var e=this._tileCoordsToNwSe(t),i=new ht(e[0],e[1]);return this.options.noWrap||(i=this._map.wrapLatLngBounds(i)),i},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var e=t.split(":"),i=new z(+e[0],+e[1]);return i.z=+e[2],i},_removeTile:function(t){var e=this._tiles[t];e&&(J(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){B(t,"leaflet-tile");var e=this.getTileSize();t.style.width=e.x+"px",t.style.height=e.y+"px",t.onselectstart=w,t.onmousemove=w,T.ielt9&&this.options.opacity<1&&mt(t,this.options.opacity)},_addTile:function(t,e){var i=this._getTilePos(t),o=this._tileCoordsToKey(t),l=this.createTile(this._wrapCoords(t),a(this._tileReady,this,t));this._initTile(l),this.createTile.length<2&&ot(a(this._tileReady,this,t,null,l)),$(l,i),this._tiles[o]={el:l,coords:t,current:!0},e.appendChild(l),this.fire("tileloadstart",{tile:l,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&&(i.loaded=+new Date,this._map._fadeAnimated?(mt(i.el,0),rt(this._fadeFrame),this._fadeFrame=ot(this._updateOpacity,this)):(i.active=!0,this._pruneTiles()),e||(B(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),T.ielt9||!this._map._fadeAnimated?ot(this._pruneTiles,this):setTimeout(a(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new z(this._wrapX?g(t.x,this._wrapX):t.x,this._wrapY?g(t.y,this._wrapY):t.y);return e.z=t.z,e},_pxBoundsToTileRange:function(t){var e=this.getTileSize();return new j(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}});function Ms(t){return new me(t)}var Xt=me.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),e.detectRetina&&T.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),typeof e.subdomains=="string"&&(e.subdomains=e.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(t,e){return this._url===t&&e===void 0&&(e=!0),this._url=t,e||this.redraw(),this},createTile:function(t,e){var i=document.createElement("img");return O(i,"load",a(this._tileOnLoad,this,e,i)),O(i,"error",a(this._tileOnError,this,e,i)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(i.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(i.referrerPolicy=this.options.referrerPolicy),i.alt="",i.src=this.getTileUrl(t),i},getTileUrl:function(t){var e={r:T.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&&(e.y=i),e["-y"]=i}return S(this._url,n(e,this.options))},_tileOnLoad:function(t,e){T.ielt9?setTimeout(a(t,this,null,e),0):t(null,e)},_tileOnError:function(t,e,i){var o=this.options.errorTileUrl;o&&e.getAttribute("src")!==o&&(e.src=o),t(i,e)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,e=this.options.maxZoom,i=this.options.zoomReverse,o=this.options.zoomOffset;return i&&(t=e-t),t+o},_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,e.onload=w,e.onerror=w,!e.complete)){e.src=Y;var i=this._tiles[t].coords;J(e),delete this._tiles[t],this.fire("tileabort",{tile:e,coords:i})}},_removeTile:function(t){var e=this._tiles[t];if(e)return e.el.setAttribute("src",Y),me.prototype._removeTile.call(this,t)},_tileReady:function(t,e,i){if(!(!this._map||i&&i.getAttribute("src")===Y))return me.prototype._tileReady.call(this,t,e,i)}});function Jn(t,e){return new Xt(t,e)}var Kn=Xt.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(t,e){this._url=t;var i=n({},this.defaultWmsParams);for(var o in e)o in this.options||(i[o]=e[o]);e=P(this,e);var l=e.detectRetina&&T.retina?2:1,d=this.getTileSize();i.width=d.x*l,i.height=d.y*l,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,Xt.prototype.onAdd.call(this,t)},getTileUrl:function(t){var e=this._tileCoordsToNwSe(t),i=this._crs,o=lt(i.project(e[0]),i.project(e[1])),l=o.min,d=o.max,p=(this._wmsVersion>=1.3&&this._crs===Fn?[l.y,l.x,d.y,d.x]:[l.x,l.y,d.x,d.y]).join(","),v=Xt.prototype.getTileUrl.call(this,t);return v+U(this.wmsParams,v,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+p},setParams:function(t,e){return n(this.wmsParams,t),e||this.redraw(),this}});function Es(t,e){return new Kn(t,e)}Xt.WMS=Kn,Jn.wms=Es;var Tt=Lt.extend({options:{padding:.1},initialize:function(t){P(this,t),f(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),B(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var t={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(t.zoomanim=this._onAnimZoom),t},_onAnimZoom:function(t){this._updateTransform(t.center,t.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(t,e){var i=this._map.getZoomScale(e,this._zoom),o=this._map.getSize().multiplyBy(.5+this.options.padding),l=this._map.project(this._center,e),d=o.multiplyBy(-i).add(l).subtract(this._map._getNewPixelOrigin(t,e));T.any3d?Bt(this._container,d,i):$(this._container,d)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var t in this._layers)this._layers[t]._reset()},_onZoomEnd:function(){for(var t in this._layers)this._layers[t]._project()},_updatePaths:function(){for(var t in this._layers)this._layers[t]._update()},_update:function(){var t=this.options.padding,e=this._map.getSize(),i=this._map.containerPointToLayerPoint(e.multiplyBy(-t)).round();this._bounds=new j(i,i.add(e.multiplyBy(1+t*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),Xn=Tt.extend({options:{tolerance:0},getEvents:function(){var t=Tt.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Tt.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");O(t,"mousemove",this._onMouseMove,this),O(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),O(t,"mouseout",this._handleMouseOut,this),t._leaflet_disable_events=!0,this._ctx=t.getContext("2d")},_destroyContainer:function(){rt(this._redrawRequest),delete this._ctx,J(this._container),W(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var t;this._redrawBounds=null;for(var e in this._layers)t=this._layers[e],t._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Tt.prototype._update.call(this);var t=this._bounds,e=this._container,i=t.getSize(),o=T.retina?2:1;$(e,t.min),e.width=o*i.x,e.height=o*i.y,e.style.width=i.x+"px",e.style.height=i.y+"px",T.retina&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){Tt.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[f(t)]=t;var e=t._order={layer:t,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=e),this._drawLast=e,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(t){this._requestRedraw(t)},_removePath:function(t){var e=t._order,i=e.next,o=e.prev;i?i.prev=o:this._drawLast=o,o?o.next=i:this._drawFirst=i,delete t._order,delete this._layers[f(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(typeof t.options.dashArray=="string"){var e=t.options.dashArray.split(/[, ]+/),i=[],o,l;for(l=0;l<e.length;l++){if(o=Number(e[l]),isNaN(o))return;i.push(o)}t.options._dashArray=i}else t.options._dashArray=t.options.dashArray},_requestRedraw:function(t){this._map&&(this._extendRedrawBounds(t),this._redrawRequest=this._redrawRequest||ot(this._redraw,this))},_extendRedrawBounds:function(t){if(t._pxBounds){var e=(t.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new j,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 i=e.getSize();this._ctx.beginPath(),this._ctx.rect(e.min.x,e.min.y,i.x,i.y),this._ctx.clip()}this._drawing=!0;for(var o=this._drawFirst;o;o=o.next)t=o.layer,(!e||t._pxBounds&&t._pxBounds.intersects(e))&&t._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(t,e){if(this._drawing){var i,o,l,d,p=t._parts,v=p.length,y=this._ctx;if(v){for(y.beginPath(),i=0;i<v;i++){for(o=0,l=p[i].length;o<l;o++)d=p[i][o],y[o?"lineTo":"moveTo"](d.x,d.y);e&&y.closePath()}this._fillStroke(y,t)}}},_updateCircle:function(t){if(!(!this._drawing||t._empty())){var e=t._point,i=this._ctx,o=Math.max(Math.round(t._radius),1),l=(Math.max(Math.round(t._radiusY),1)||o)/o;l!==1&&(i.save(),i.scale(1,l)),i.beginPath(),i.arc(e.x,e.y/l,o,0,Math.PI*2,!1),l!==1&&i.restore(),this._fillStroke(i,t)}},_fillStroke:function(t,e){var i=e.options;i.fill&&(t.globalAlpha=i.fillOpacity,t.fillStyle=i.fillColor||i.color,t.fill(i.fillRule||"evenodd")),i.stroke&&i.weight!==0&&(t.setLineDash&&t.setLineDash(e.options&&e.options._dashArray||[]),t.globalAlpha=i.opacity,t.lineWidth=i.weight,t.strokeStyle=i.color,t.lineCap=i.lineCap,t.lineJoin=i.lineJoin,t.stroke())},_onClick:function(t){for(var e=this._map.mouseEventToLayerPoint(t),i,o,l=this._drawFirst;l;l=l.next)i=l.layer,i.options.interactive&&i._containsPoint(e)&&(!(t.type==="click"||t.type==="preclick")||!this._map._draggableMoved(i))&&(o=i);this._fireEvent(o?[o]:!1,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&&(K(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,l=this._drawFirst;l;l=l.next)i=l.layer,i.options.interactive&&i._containsPoint(e)&&(o=i);o!==this._hoveredLayer&&(this._handleMouseOut(t),o&&(B(this._container,"leaflet-interactive"),this._fireEvent([o],t,"mouseover"),this._hoveredLayer=o)),this._fireEvent(this._hoveredLayer?[this._hoveredLayer]:!1,t),this._mouseHoverThrottled=!0,setTimeout(a(function(){this._mouseHoverThrottled=!1},this),32)}},_fireEvent:function(t,e,i){this._map._fireDOMEvent(e,i||e.type,t)},_bringToFront:function(t){var e=t._order;if(e){var i=e.next,o=e.prev;if(i)i.prev=o;else return;o?o.next=i:i&&(this._drawFirst=i),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 i=e.next,o=e.prev;if(o)o.next=i;else return;i?i.prev=o:o&&(this._drawLast=o),e.prev=null,e.next=this._drawFirst,this._drawFirst.prev=e,this._drawFirst=e,this._requestRedraw(t)}}});function Qn(t){return T.canvas?new Xn(t):null}var _e=(function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("<lvml:"+t+' class="lvml">')}}catch{}return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}})(),Ps={_initContainer:function(){this._container=F("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Tt.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var e=t._container=_e("shape");B(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=_e("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[f(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;J(e),t.removeInteractiveTarget(e),delete this._layers[f(t)]},_updateStyle:function(t){var e=t._stroke,i=t._fill,o=t.options,l=t._container;l.stroked=!!o.stroke,l.filled=!!o.fill,o.stroke?(e||(e=t._stroke=_e("stroke")),l.appendChild(e),e.weight=o.weight+"px",e.color=o.color,e.opacity=o.opacity,o.dashArray?e.dashStyle=D(o.dashArray)?o.dashArray.join(" "):o.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=o.lineCap.replace("butt","flat"),e.joinstyle=o.lineJoin):e&&(l.removeChild(e),t._stroke=null),o.fill?(i||(i=t._fill=_e("fill")),l.appendChild(i),i.color=o.fillColor||o.color,i.opacity=o.fillOpacity):i&&(l.removeChild(i),t._fill=null)},_updateCircle:function(t){var e=t._point.round(),i=Math.round(t._radius),o=Math.round(t._radiusY||i);this._setPath(t,t._empty()?"M0 0":"AL "+e.x+","+e.y+" "+i+","+o+" 0,"+65535*360)},_setPath:function(t,e){t._path.v=e},_bringToFront:function(t){Wt(t._container)},_bringToBack:function(t){Yt(t._container)}},Ve=T.vml?_e:en,ge=Tt.extend({_initContainer:function(){this._container=Ve("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Ve("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){J(this._container),W(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Tt.prototype._update.call(this);var t=this._bounds,e=t.getSize(),i=this._container;(!this._svgSize||!this._svgSize.equals(e))&&(this._svgSize=e,i.setAttribute("width",e.x),i.setAttribute("height",e.y)),$(i,t.min),i.setAttribute("viewBox",[t.min.x,t.min.y,e.x,e.y].join(" ")),this.fire("update")}},_initPath:function(t){var e=t._path=Ve("path");t.options.className&&B(e,t.options.className),t.options.interactive&&B(e,"leaflet-interactive"),this._updateStyle(t),this._layers[f(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){J(t._path),t.removeInteractiveTarget(t._path),delete this._layers[f(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var e=t._path,i=t.options;e&&(i.stroke?(e.setAttribute("stroke",i.color),e.setAttribute("stroke-opacity",i.opacity),e.setAttribute("stroke-width",i.weight),e.setAttribute("stroke-linecap",i.lineCap),e.setAttribute("stroke-linejoin",i.lineJoin),i.dashArray?e.setAttribute("stroke-dasharray",i.dashArray):e.removeAttribute("stroke-dasharray"),i.dashOffset?e.setAttribute("stroke-dashoffset",i.dashOffset):e.removeAttribute("stroke-dashoffset")):e.setAttribute("stroke","none"),i.fill?(e.setAttribute("fill",i.fillColor||i.color),e.setAttribute("fill-opacity",i.fillOpacity),e.setAttribute("fill-rule",i.fillRule||"evenodd")):e.setAttribute("fill","none"))},_updatePoly:function(t,e){this._setPath(t,nn(t._parts,e))},_updateCircle:function(t){var e=t._point,i=Math.max(Math.round(t._radius),1),o=Math.max(Math.round(t._radiusY),1)||i,l="a"+i+","+o+" 0 1,0 ",d=t._empty()?"M0 0":"M"+(e.x-i)+","+e.y+l+i*2+",0 "+l+-i*2+",0 ";this._setPath(t,d)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){Wt(t._path)},_bringToBack:function(t){Yt(t._path)}});T.vml&&ge.include(Ps);function $n(t){return T.svg||T.vml?new ge(t):null}Z.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(t==="overlayPane"||t===void 0)return!1;var e=this._paneRenderers[t];return e===void 0&&(e=this._createRenderer({pane:t}),this._paneRenderers[t]=e),e},_createRenderer:function(t){return this.options.preferCanvas&&Qn(t)||$n(t)}});var to=Jt.extend({initialize:function(t,e){Jt.prototype.initialize.call(this,this._boundsToLatLngs(t),e)},setBounds:function(t){return this.setLatLngs(this._boundsToLatLngs(t))},_boundsToLatLngs:function(t){return t=Q(t),[t.getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});function Ts(t,e){return new to(t,e)}ge.create=Ve,ge.pointsToPath=nn,Pt.geometryToLayer=Re,Pt.coordsToLatLng=Di,Pt.coordsToLatLngs=Ue,Pt.latLngToCoords=Ii,Pt.latLngsToCoords=Ne,Pt.getFeature=Kt,Pt.asFeature=Ze,Z.mergeOptions({boxZoom:!0});var eo=xt.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(){O(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){W(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){J(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){this._resetStateTimeout!==0&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(t){if(!t.shiftKey||t.which!==1&&t.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),le(),mi(),this._startPoint=this._map.mouseEventToContainerPoint(t),O(document,{contextmenu:Nt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=F("div","leaflet-zoom-box",this._container),B(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var e=new j(this._point,this._startPoint),i=e.getSize();$(this._box,e.min),this._box.style.width=i.x+"px",this._box.style.height=i.y+"px"},_finish:function(){this._moved&&(J(this._box),K(this._container,"leaflet-crosshair")),he(),_i(),W(document,{contextmenu:Nt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(t){if(!(t.which!==1&&t.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(a(this._resetState,this),0);var e=new ht(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(e).fire("boxzoomend",{boxZoomBounds:e})}},_onKeyDown:function(t){t.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});Z.addInitHook("addHandler","boxZoom",eo),Z.mergeOptions({doubleClickZoom:!0});var io=xt.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(t){var e=this._map,i=e.getZoom(),o=e.options.zoomDelta,l=t.originalEvent.shiftKey?i-o:i+o;e.options.doubleClickZoom==="center"?e.setZoom(l):e.setZoomAround(t.containerPoint,l)}});Z.addInitHook("addHandler","doubleClickZoom",io),Z.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var no=xt.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new Dt(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))}B(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){K(this._map._container,"leaflet-grab"),K(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=Q(this._map.options.maxBounds);this._offsetLimit=lt(this._map.latLngToContainerPoint(e.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(e.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;t.fire("movestart").fire("dragstart"),t.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(t){if(this._map.options.inertia){var e=this._lastTime=+new Date,i=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(i),this._times.push(e),this._prunePositions(e)}this._map.fire("move",t).fire("drag",t)},_prunePositions:function(t){for(;this._positions.length>1&&t-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var t=this._map.getSize().divideBy(2),e=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=e.subtract(t).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(t,e){return t-(t-e)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var t=this._draggable._newPos.subtract(this._draggable._startPos),e=this._offsetLimit;t.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),i=this._initialWorldOffset,o=this._draggable._newPos.x,l=(o-e+i)%t+e-i,d=(o+e+i)%t-e-i,p=Math.abs(l+i)<Math.abs(d+i)?l:d;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=p},_onDragEnd:function(t){var e=this._map,i=e.options,o=!i.inertia||t.noInertia||this._times.length<2;if(e.fire("dragend",t),o)e.fire("moveend");else{this._prunePositions(+new Date);var l=this._lastPos.subtract(this._positions[0]),d=(this._lastTime-this._times[0])/1e3,p=i.easeLinearity,v=l.multiplyBy(p/d),y=v.distanceTo([0,0]),b=Math.min(i.inertiaMaxSpeed,y),A=v.multiplyBy(b/y),C=b/(i.inertiaDeceleration*p),R=A.multiplyBy(-C/2).round();!R.x&&!R.y?e.fire("moveend"):(R=e._limitOffset(R,e.options.maxBounds),ot(function(){e.panBy(R,{duration:C,easeLinearity:p,noMoveStart:!0,animate:!0})}))}}});Z.addInitHook("addHandler","dragging",no),Z.mergeOptions({keyboard:!0,keyboardPanDelta:80});var oo=xt.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"),O(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(),W(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,i=t.scrollTop||e.scrollTop,o=t.scrollLeft||e.scrollLeft;this._map._container.focus(),window.scrollTo(o,i)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(t){var e=this._panKeys={},i=this.keyCodes,o,l;for(o=0,l=i.left.length;o<l;o++)e[i.left[o]]=[-1*t,0];for(o=0,l=i.right.length;o<l;o++)e[i.right[o]]=[t,0];for(o=0,l=i.down.length;o<l;o++)e[i.down[o]]=[0,t];for(o=0,l=i.up.length;o<l;o++)e[i.up[o]]=[0,-1*t]},_setZoomDelta:function(t){var e=this._zoomKeys={},i=this.keyCodes,o,l;for(o=0,l=i.zoomIn.length;o<l;o++)e[i.zoomIn[o]]=t;for(o=0,l=i.zoomOut.length;o<l;o++)e[i.zoomOut[o]]=-t},_addHooks:function(){O(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){W(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(t){if(!(t.altKey||t.ctrlKey||t.metaKey)){var e=t.keyCode,i=this._map,o;if(e in this._panKeys){if(!i._panAnim||!i._panAnim._inProgress)if(o=this._panKeys[e],t.shiftKey&&(o=I(o).multiplyBy(3)),i.options.maxBounds&&(o=i._limitOffset(I(o),i.options.maxBounds)),i.options.worldCopyJump){var l=i.wrapLatLng(i.unproject(i.project(i.getCenter()).add(o)));i.panTo(l)}else i.panBy(o)}else if(e in this._zoomKeys)i.setZoom(i.getZoom()+(t.shiftKey?3:1)*this._zoomKeys[e]);else if(e===27&&i._popup&&i._popup.options.closeOnEscapeKey)i.closePopup();else return;Nt(t)}}});Z.addInitHook("addHandler","keyboard",oo),Z.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var ro=xt.extend({addHooks:function(){O(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){W(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(t){var e=Tn(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(a(this._performZoom,this),o),Nt(t)},_performZoom:function(){var t=this._map,e=t.getZoom(),i=this._map.options.zoomSnap||0;t._stop();var o=this._delta/(this._map.options.wheelPxPerZoomLevel*4),l=4*Math.log(2/(1+Math.exp(-Math.abs(o))))/Math.LN2,d=i?Math.ceil(l/i)*i:l,p=t._limitZoom(e+(this._delta>0?d:-d))-e;this._delta=0,this._startTime=null,p&&(t.options.scrollWheelZoom==="center"?t.setZoom(e+p):t.setZoomAround(this._lastMousePos,e+p))}});Z.addInitHook("addHandler","scrollWheelZoom",ro);var Cs=600;Z.mergeOptions({tapHold:T.touchNative&&T.safari&&T.mobile,tapTolerance:15});var so=xt.extend({addHooks:function(){O(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){W(this._map._container,"touchstart",this._onDown,this)},_onDown:function(t){if(clearTimeout(this._holdTimeout),t.touches.length===1){var e=t.touches[0];this._startPos=this._newPos=new z(e.clientX,e.clientY),this._holdTimeout=setTimeout(a(function(){this._cancel(),this._isTapValid()&&(O(document,"touchend",nt),O(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",e))},this),Cs),O(document,"touchend touchcancel contextmenu",this._cancel,this),O(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function t(){W(document,"touchend",nt),W(document,"touchend touchcancel",t)},_cancel:function(){clearTimeout(this._holdTimeout),W(document,"touchend touchcancel contextmenu",this._cancel,this),W(document,"touchmove",this._onMove,this)},_onMove:function(t){var e=t.touches[0];this._newPos=new z(e.clientX,e.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(t,e){var i=new MouseEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:e.screenX,screenY:e.screenY,clientX:e.clientX,clientY:e.clientY});i._simulated=!0,e.target.dispatchEvent(i)}});Z.addInitHook("addHandler","tapHold",so),Z.mergeOptions({touchZoom:T.touch,bounceAtZoomLimits:!0});var ao=xt.extend({addHooks:function(){B(this._map._container,"leaflet-touch-zoom"),O(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){K(this._map._container,"leaflet-touch-zoom"),W(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(t){var e=this._map;if(!(!t.touches||t.touches.length!==2||e._animatingZoom||this._zooming)){var i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]);this._centerPoint=e.getSize()._divideBy(2),this._startLatLng=e.containerPointToLatLng(this._centerPoint),e.options.touchZoom!=="center"&&(this._pinchStartLatLng=e.containerPointToLatLng(i.add(o)._divideBy(2))),this._startDist=i.distanceTo(o),this._startZoom=e.getZoom(),this._moved=!1,this._zooming=!0,e._stop(),O(document,"touchmove",this._onTouchMove,this),O(document,"touchend touchcancel",this._onTouchEnd,this),nt(t)}},_onTouchMove:function(t){if(!(!t.touches||t.touches.length!==2||!this._zooming)){var e=this._map,i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]),l=i.distanceTo(o)/this._startDist;if(this._zoom=e.getScaleZoom(l,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoom<e.getMinZoom()&&l<1||this._zoom>e.getMaxZoom()&&l>1)&&(this._zoom=e._limitZoom(this._zoom)),e.options.touchZoom==="center"){if(this._center=this._startLatLng,l===1)return}else{var d=i._add(o)._divideBy(2)._subtract(this._centerPoint);if(l===1&&d.x===0&&d.y===0)return;this._center=e.unproject(e.project(this._pinchStartLatLng,this._zoom).subtract(d),this._zoom)}this._moved||(e._moveStart(!0,!1),this._moved=!0),rt(this._animRequest);var p=a(e._move,e,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=ot(p,this,!0),nt(t)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,rt(this._animRequest),W(document,"touchmove",this._onTouchMove,this),W(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))}});Z.addInitHook("addHandler","touchZoom",ao),Z.BoxZoom=eo,Z.DoubleClickZoom=io,Z.Drag=no,Z.Keyboard=oo,Z.ScrollWheelZoom=ro,Z.TapHold=so,Z.TouchZoom=ao,s.Bounds=j,s.Browser=T,s.CRS=At,s.Canvas=Xn,s.Circle=Si,s.CircleMarker=Be,s.Class=pt,s.Control=yt,s.DivIcon=jn,s.DivOverlay=kt,s.DomEvent=jr,s.DomUtil=Yr,s.Draggable=Dt,s.Evented=ne,s.FeatureGroup=Mt,s.GeoJSON=Pt,s.GridLayer=me,s.Handler=xt,s.Icon=jt,s.ImageOverlay=He,s.LatLng=V,s.LatLngBounds=ht,s.Layer=Lt,s.LayerGroup=qt,s.LineUtil=as,s.Map=Z,s.Marker=Oe,s.Mixin=es,s.Path=It,s.Point=z,s.PolyUtil=is,s.Polygon=Jt,s.Polyline=Et,s.Popup=Fe,s.PosAnimation=Cn,s.Projection=ls,s.Rectangle=to,s.Renderer=Tt,s.SVG=ge,s.SVGOverlay=qn,s.TileLayer=Xt,s.Tooltip=Ge,s.Transformation=ni,s.Util=Me,s.VideoOverlay=Yn,s.bind=a,s.bounds=lt,s.canvas=Qn,s.circle=_s,s.circleMarker=ms,s.control=ue,s.divIcon=As,s.extend=n,s.featureGroup=us,s.geoJSON=Wn,s.geoJson=ys,s.gridLayer=Ms,s.icon=fs,s.imageOverlay=Ls,s.latLng=N,s.latLngBounds=Q,s.layerGroup=ds,s.map=Jr,s.marker=ps,s.point=I,s.polygon=vs,s.polyline=gs,s.popup=xs,s.rectangle=Ts,s.setOptions=P,s.stamp=f,s.svg=$n,s.svgOverlay=bs,s.tileLayer=Jn,s.tooltip=ks,s.transformation=oe,s.version=h,s.videoOverlay=ws;var Ss=window.L;s.noConflict=function(){return window.L=Ss,this},window.L=s}))})($t,$t.exports)),$t.exports}var X=Ri();const ye=ut({__proto__:null,default:po(X)},[X]),_o='.leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:transparent}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{max-width:none!important;max-height:none!important;width:auto;padding:0}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;-moz-box-sizing:border-box;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-top,.leaflet-bottom{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;-webkit-transition:opacity .2s linear;-moz-transition:opacity .2s linear;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{-webkit-transition:none;-moz-transition:none;transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline-offset:1px}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{border:2px dotted #38f;background:#ffffff80}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:12px;font-size:.75rem;line-height:1.5}.leaflet-bar{box-shadow:0 1px 5px #000000a6;border-radius:4px}.leaflet-bar a{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px #0006;background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block;font-size:13px;font-size:1.08333em}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=)}.leaflet-container .leaflet-control-attribution{background:#fff;background:#fffc;margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{display:inline!important;vertical-align:baseline!important;width:1em;height:.6669em}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;white-space:nowrap;-moz-box-sizing:border-box;box-sizing:border-box;background:#fffc;text-shadow:1px 1px #fff}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 24px 13px 20px;line-height:1.3;font-size:13px;font-size:1.08333em;min-height:1px}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-top:-1px;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;pointer-events:auto;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:#fff;color:#333;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;border:none;text-align:center;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;color:#757575;text-decoration:none;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=.70710678,M12=.70710678,M21=-.70710678,M22=.70710678)}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}',go=`.leaflet-draw-section{position:relative}.leaflet-draw-toolbar{margin-top:12px}.leaflet-draw-toolbar-top{margin-top:0}.leaflet-draw-toolbar-notop a:first-child{border-top-right-radius:0}.leaflet-draw-toolbar-nobottom a:last-child{border-bottom-right-radius:0}.leaflet-draw-toolbar a{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAAeCAYAAACWuCNnAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAG7AAABuwBHnU4NQAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAbvSURBVHic7dtdbBxXFQfw/9nZ3SRKwAP7UFFUQOoHqGnUoEAoNghX9tyxVcpD1X0J+WgiUQmpfUB5ACSgG1qJIKASqBIUIauqAbWseIlqb+bOWHVR6y0FKZBEqdIUQROIREGRx3FFvR/38ODZst3a3nE8Ywfv+T2t7hzdM3fle/bOnWtACCGEEEIIIYQQQgghhBBCCCGEEEIIIcRa0EbfgBDdFItFKwzDAa3175LuWylVAvBIR/MxrXUp6Vxx9dp4VyObVEdKKW591lonXgiVUg6AHzPzk9ls9meVSmUh6RzXkz179uQKhcIgM+8CACI6U6vVnp+enm6knXt4ePiuTCbzWQAwxlSDIHg57ZwroDAMnwKwz3XdBzzPG08hxzsTNprQG2lTjtd13WFmfghAP4A+AJcATFiW9YNKpfL3uP0kUliiX4SG1pqUUpx0wXJd9/PMXAGwPWq6yMyPz8/P/7xarf4nyVwt7QV4JWkU52i8YwBu6bh0wRhzJAiCF5POCQCDg4N2Pp//NYDRjkuTxph9QRCESeYrFov5ubm5R5n5AIAPtV1aYOb7BgYGTpZKJeO67lFmPsbM9/i+/8Ja8y6zylhOYquPXhsvAJRKpczMzMwTAIaJ6LFGo+HNzs5eKRQKNxPRAWb+CoAjWuvn4vS35skWFasxAAdbbUlOYqVUPwAPwI4lLr8J4KeWZT1eqVTmksoZ5d2QghUVKx/AlmVCFph5yPf9l5LMCwBKqUksFqszRHQcAJj5GwB2MfOE7/tfTDKf4zjHiejrAE4CuNhqZ+bf2rY9FYbhGBH92/O8o47j3Oj7/uUk86+3XhsvACilHmPmgW3btn3pxIkTVzuvj4yMfNoY85wxZiQIglPd+lvTZIuq5xiAQwCe6evr218ul5tr6bNd9GiiAbyvS+hFrfVHk8oLbEzBih4Dz+G9K6t3IaLXFhYWdib5eBh911UA8wBu1lq/CQBDQ0M3WJb1OoAdRPQZz/NeSSqnUuofAKpa6/vb26MfwacA7AdwFcCdWuu/JpU3yl1C91VHoquNXhvvyMjIx4wxr1iWtbNSqfxruTjHcR4AcMj3/bu79XnNe1hpFyvHcXYT0QS6FysASHR1tVEKhcIguhQrAGDm23K53BcATCWV27KsAWYGgPOtYgUAU1NT/1RKnQewxxjzOQCJFSwANwI4297QtmLfD+AtZr43m83OJ5iz3bGU+l1OT43XGFNk5mdXKlYAYNv2eBiG31dK3aS1vrRSbOZabqRYLFppFisAIKJxAB+MGf56krk30O64gZlMJnZsHMxsoo8fHxoauqHVHn3+BAAQUaxV57Xq2F54i5nvIaJXm81mYoX5etID491JRH/sFlQul5tEdMoYc3u32FUXrLYvObViBQDM/MQqwi8knX8jEJHpHrXIGJNo8WDm1spph2VZgeu6+5RSX7YsK8D/Xnb8Psmcnebm5h7G4uS9ysxutOH8VQC70sy7UTb7eImImTnWlgkzUyaT6fr3v6qC1fGL8EytVjuQRrECANu2fwHg1TixzPyXNO5hvTHz6VWE/znJ3L7vzxBRa9PzDmb+FYBfArgjajvd39+f9vGGKwACZh5te6mwmc8KburxMvO5TCbzqW5xxWLRArDbsqyu8z32HtZSxSrNM0Hlcrnpum6JmZ+NEb4pHglrtdrz+Xz+AoBbu4Ser9fra37d3YEBfBvAkq+XmfmbpVIp9grwWnie9zSAp9PMcT3Z7OPNZrO/aTQaf1BKfbd9X7RTGIaHmPlcnPNYsVZYSikOw7AB4CAzj/f19e1fjwOMnueVEeMxJJfLbYqCNT093TDGHAGw0qHYBQBH0vj+Pc+bYOb3HFRk5nHf9yeTzgfgMhF9uEvMTQD+71/vR3pqvJOTk28AeBJAeXR09P1LxbiuuxfA9wB8LU6fsVdYrUOhtm0fTusxcAlMRN+KziUt5SqAM3v37r00OZnGfFp/QRC86DjOUCaTGWPm2zoun8fiIbuZtPLX6/UH8/n8rQDuippertfrD6aRKyqOR5VS81ji8Z+IbmfmgwB+mEb+9dZr4wWA/v7+R6rV6k+azeYpx3EezeVyJ7dv335lfn7+lkajcZCZDzPzYd/3/xSnv9gFq3UuaR2LFQDA87xAKVUB8BEAZ6N9nrNEdEZr/TcArLVOPG8aJ9jj8n3/pcHBwZ1btmx5519zmPl0vV5/Ie2V7fT09Nujo6Nus9kcA4CtW7ce1lq/nUYu27a/Mzs7CyI6gMVX/u/CzJeZ+Ue2bcc9pb1aXc8lJZms18YLANE2wkOu694N4OFGo3E8DMMPAHiDiCaY+ZOb4YCsEEIIIYQQQgghhBBCCCGEEEIIIYQQQgghhEjYfwGO+b5dFNs4OgAAAABJRU5ErkJggg==);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3csvg%20xmlns:dc='http://purl.org/dc/elements/1.1/'%20xmlns:cc='http://creativecommons.org/ns%23'%20xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23'%20xmlns:svg='http://www.w3.org/2000/svg'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd'%20xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape'%20viewBox='0%200%20600%2060'%20height='60'%20width='600'%20id='svg4225'%20version='1.1'%20inkscape:version='0.91%20r13725'%20sodipodi:docname='spritesheet.svg'%20inkscape:export-filename='/home/fpuga/development/upstream/icarto.Leaflet.draw/src/images/spritesheet-2x.png'%20inkscape:export-xdpi='90'%20inkscape:export-ydpi='90'%3e%3cmetadata%20id='metadata4258'%3e%3crdf:RDF%3e%3ccc:Work%20rdf:about=''%3e%3cdc:format%3eimage/svg+xml%3c/dc:format%3e%3cdc:type%20rdf:resource='http://purl.org/dc/dcmitype/StillImage'%20/%3e%3cdc:title%20/%3e%3c/cc:Work%3e%3c/rdf:RDF%3e%3c/metadata%3e%3cdefs%20id='defs4256'%20/%3e%3csodipodi:namedview%20pagecolor='%23ffffff'%20bordercolor='%23666666'%20borderopacity='1'%20objecttolerance='10'%20gridtolerance='10'%20guidetolerance='10'%20inkscape:pageopacity='0'%20inkscape:pageshadow='2'%20inkscape:window-width='1920'%20inkscape:window-height='1056'%20id='namedview4254'%20showgrid='false'%20inkscape:zoom='1.3101852'%20inkscape:cx='237.56928'%20inkscape:cy='7.2419621'%20inkscape:window-x='1920'%20inkscape:window-y='24'%20inkscape:window-maximized='1'%20inkscape:current-layer='svg4225'%20/%3e%3cg%20id='enabled'%20style='fill:%23464646;fill-opacity:1'%3e%3cg%20id='polyline'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%2018,36%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4229'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2036,18%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4231'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2023.142,39.145%20-2.285,-2.29%2016,-15.998%202.285,2.285%20z'%20id='path4233'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cpath%20id='polygon'%20d='M%20100,24.565%2097.904,39.395%2083.07,42%2076,28.773%2086.463,18%20Z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='rectangle'%20d='m%20140,20%2020,0%200,20%20-20,0%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='circle'%20d='m%20221,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='marker'%20d='m%20270,19%20c%20-4.971,0%20-9,4.029%20-9,9%200,4.971%205.001,12%209,14%204.001,-2%209,-9.029%209,-14%200,-4.971%20-4.029,-9%20-9,-9%20z%20m%200,12.5%20c%20-2.484,0%20-4.5,-2.014%20-4.5,-4.5%200,-2.484%202.016,-4.5%204.5,-4.5%202.485,0%204.5,2.016%204.5,4.5%200,2.486%20-2.015,4.5%20-4.5,4.5%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cg%20id='edit'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20337,30.156%200,0.407%200,5.604%20c%200,1.658%20-1.344,3%20-3,3%20l%20-10,0%20c%20-1.655,0%20-3,-1.342%20-3,-3%20l%200,-10%20c%200,-1.657%201.345,-3%203,-3%20l%206.345,0%203.19,-3.17%20-9.535,0%20c%20-3.313,0%20-6,2.687%20-6,6%20l%200,10%20c%200,3.313%202.687,6%206,6%20l%2010,0%20c%203.314,0%206,-2.687%206,-6%20l%200,-8.809%20-3,2.968'%20id='path4240'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.72,24.637%20-8.892,8.892%20-2.828,0%200,-2.829%208.89,-8.89%20z'%20id='path4242'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.697,17.826%204,0%200,4%20-4,0%20z'%20transform='matrix(-0.70698336,-0.70723018,0.70723018,-0.70698336,567.55917,274.78273)'%20id='path4244'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cg%20id='remove'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20381,42%2018,0%200,-18%20-18,0%200,18%20z%20m%2014,-16%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z'%20id='path4247'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20395,20%200,-4%20-10,0%200,4%20-6,0%200,2%2022,0%200,-2%20-6,0%20z%20m%20-2,0%20-6,0%200,-2%206,0%200,2%20z'%20id='path4249'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3c/g%3e%3cg%20id='disabled'%20transform='translate(120,0)'%20style='fill:%23bbbbbb'%3e%3cuse%20xlink:href='%23edit'%20id='edit-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3cuse%20xlink:href='%23remove'%20id='remove-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3c/g%3e%3cpath%20style='fill:none;stroke:%23464646;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1'%20id='circle-3'%20d='m%20581.65725,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:300px 30px;background-clip:padding-box}.leaflet-retina .leaflet-draw-toolbar a{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAlgAAAA8CAYAAAC6nMS5AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAN1wAADdcBQiibeAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAA16SURBVHic7d1/jBxneQfw7zNzvotdn+9sVQkxoRKoammBqqpbk6uT5mLfvHPn42yn1VFRVCEhoFH5IYpoSaUCKi1NcGkcfrbCVRFKEwG2aHLn83pmLvY2CTqT1AmCOBE0EOT4B0nBPw/snb2dp3/sLr6s77i923dud/a+H8ny7tzMo8f3eud99p133gGIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiFYGaXYCRETUPMYYrWe/MAzZX2QQ27d5OpqdABFROxgZGVlz5cqVrzuOc18QBJPNzofsYvvSYrVcgTVftZ2l6npgYODXHMc5oKoHHcfZHQTB2WbnRETpGRkZWVMoFA6IyO2qutX3/R1Z64TnO8fWOwLSzti+mSKDg4M3l0qlnSJyG4CbAFwP4ByAlwE8paoPX3fddcH4+PjP00yk5QqsrDPGvAZAHsBrReRNqvpeY8x/iMg9QRCcaXJ6ZIHv+xtUdReAHQBej/IHGABOAnhORMY6OjoempiYONe0JC3zPM84jjOqqrfi6r/3RQCPAdgXhmHUvOyaa3R01L1w4cJBALdVNq1W1THP87woir7ZzNyocWzf7PA8b4uI7E6S5A9Frqknb6j8eZOIvKNQKPzU9/1/dhznvlwuV0gjn5YbFapW09Vqu/Z9K9u2bdsNruvmUe50axUAfMV13X/I5XInlzcze2x/28lCu1b19fWt7u7u/hCAvwGwboHdL6jq7unp6T1TU1OXlyG9VAwODv5mkiR7Ady6wK6Plkqldz/yyCPfX468bBkaGuqamZm5E8DbReQNANYscMiLIrI1CILnZ280xrwHwL+hck4VkacBDLTS6HVaIxWt/Blm+zauldu3atOmTas2bNjwWRG5s7LplKp+VUQOuq77/bVr17589uzZ9SKy0XGcAVUdFZE/qOx7zHXdXWn0yy31i6sMw/4MyF6BZYy5XlWPiMhvL7BrrKpfcxznE7Uf4ixYqQWW53kbATw060NZr28nSbJzcnLyRBp5pcnzvNtE5CEAvXUecg7ArjAMH00xLWuGhoZuKpVKEwB+p85DXnRd9/ZcLvcDAOjv778un88XAChwtRMWkW+jxTpfYOV1wGxfO1q1fav6+vpWr1u3blxVtwH4uar+/fT09OcW+mJrjBkBcC+AXwdwBoAJw/AZm7m1zC+uUlyNA9g6189buZH7+/t/tbOz8wiANy7isKKqftV13U8eOnToe2nlZttKLLAqJ+qjAF69xBAnZ2Zmbj58+PApm3mlqTJydRTXFldHAUxVXvcBuLnm5+dU9c1RFP1v2jk2YmhoqKtUKj2B+jvfE0mS3D45OflD4OqcHADPh2H4F6h0wp7nva1YLOby+fz5dDKnerB9Vwzxff8BVX0bgFMAdoZheKzeg4eHh9cXi8WvAfAAvOC67ptzudz/WUvOVqBGVO7OmBCR/vn2adWOuL+/v7ezs3MSwKYlhkgAHBSRjwdB8JTF1FKx0gqsymXBxwH8XoOh/ieO41vz+fwVG3mlzRjzKF55WfA8gD8LwzA3ez/P87aLyIMAeqrbVDUfRdHty5Pp0hhjPgDgM9X3qnq/iNwPYM5RCdd1T1RPvLM63+q/ce/sTpiaj+27Mvi+f6eq/iuAi67r9uVyuWcXG6NSjB8B0KeqE1EUvcVWfk3v3OYZuXosjuPt+Xx+ull51WNgYKBHRKIlXDaaS6Kq+6Mo+lMLsVKz0gosz/M+KiKfsBTub8MwvMdSrNQYYzwAYc3m7bXFVZXv+8OqemD2NlUdiKLokbRybJQx5lsANlfefi4Mww/UedyvADgI4I9mbxeRDwdB8C92s0yHrc9wK3922b6Na+X2BYD+/v61nZ2dz6M8cX00DMP9S421ffv2V83MzDwHoNfmucuxEWSpslxcjYyMrHEcZ8xScQUAjoj8vqVYZIHv+xtE5MMWQ941PDy83mK8VIjIW2s2HZ2vuAKAIAgmADyxQIxWM3uu5J56DhgZGVkDYBw1nS+ApwB82VJeZAfbt82tWrXqPSgXV481UlwBwMGDB3+sqncDgIh81EZ+QBMLrKwXV5Uh5NoPYqMyN+m9nanqHVj4bsHF6InjeKfFeKmoLMUw+/2Ct6KLyOM1m2x/NmxbW30RhuGPFtp5jstGVU+JiNdqE57rEYahzB6lWOz7Fsf2be/2hYj8SeXlvTbiFYvFLwK4DOAWY8z1NmI2pcDKcnE1OjraWSgU9uPaD2LDRKSlJwavQCO2A4rIDtsxU7BxsQeoau2Jeak3BDTDL72kUm/n63neaFoJUkPYvm3G9/0NKN9gc7mrq6t2OsOSVGqPSQCuiAzaiLnsBVaWiysAuHDhwn4AQ2nEVtUfpBGXluwNKcRcaBmPVpDMfiMiW+o4pnafZM69MmYxnW9lsj9lCNs3m1T1tSjXL89aXo39WCX+62wEW9YCK+vFVcXLKcbmJcLW8qoUYmZhZOfFmvc3e563fb6djTFvwdUJxfPFyJx6O1/f999a6Xz5ZIwMYftm2o2Vv60+HUVETldeLnoUfy7LVmC1SXEFVf0YgFSeX5QkCQus9tfyIzsicnSObQ/6vj9cu71SXP1nPTGyplAo5FDT+arqk3Ecb5s9J0dV2flmENs3u0REgTmnJjRkVjwrd2Iuy3+adimuACCKotPGmC8A+GvLoZOZmZkXLMekBojIaVX9DcthTy+8S3MlSTIuIu+q2dyjqgeMMU8A+CYAUdUtAOa8izZJkvG081wG19xN5jjO4ByLTLrLlRBZxfbNrjMAICI3LrTjIlVHrqyMjKU+gtVOxVVVHMf/hHkWrGvAiawsQrlSqOqiF61rRkzbOjo6AsxfCG4G8FcAPvhLlih5qVgsWpl42kIyezcZ1YXtmy0/QvlqwG9V1i6zZRMAiIiV+dCpFljtWFwBQOUbzqcth+XlwdZjfRRGRMZsx7St8mT5zzcQ4r52+LKgqp9S1U8B+GTtZSPKPrZvdlXaagrAalU1NmJWCrVtAEqO4xyyETO1S4TtWlxVXbp06b7u7u6/BHCTjXiqygKrxYjIQ6p6L2Y9BqZB51etWtXyBRYAuK77hVKp9H5cnUxarzOu634xjZyWWxRFdzU7B0oP2zfbVPUbIrLFcZwPAfivRuOJyPtUdbWq5m09jzCVEax2L64AYGpq6rKq/qOteI7jsMBqMUEQnFXV3bbiqerdExMT52zFS1Mul7soIovugETkI7lc7mIaORERVRWLxS8BeElVb/F9v6EnR/i+f6Oq3gUAjuPYejSavQLLGKPVP4VC4Wd4ZXF1pKura7Bdiquq3t7efwfwnKVwLLBa0PT09B5U1kZp0BPFYvGzFuIsmyAI7kf5uWz1OhgEwTV3FLaoX5yLKosWLknNsZcayohsYvu2uUo98TEAUNW9vu8vad3CoaGhLlX9BoBeAONBEByxleNyLNPwWBzHOywvBtYS9u3bV1LVj1sKxwKrBU1NTV12XXcXgFMNhDmpqndkcF6SisifAzhRx76n4jh+Byzd3rwMjldfqOqSV+xPkmT2yvzH592RlhvbdwUIw3AvgAcArFPVcHBwcFHPBvZ9f0OpVDqA8qrwL8Rx/E6b+VkvsGqfZ9ROlwXnEkXRfgDfajCMXrx48Yc28iH7crncSVXdrKpPLvZYEXk6SZItURS1/PIMcwmC4KzjOCMAam9dn+0SgJ35fP4ny5SWDQ/Mer3HGLPoTtgYMyIiv3gOmqpmZfRuJWD7rgwax/G7UH7EzcYkSf7bGHNXX1/f6oUO9H1/Z+WcPoDysgw7bJ/DUl8Hq52LqwoVkb9T1WiRx8UoX158RlWfnJqaupxCbmRJFEWn+/r6buvu7v4ggI9g4Ynv50XknkKh8JkMjly9wqFDh77j+/6oqo4BqD1xXRaRPw6CwMZl1GXjuu6XSqXSOwH8LoD1AMaMMecA1PtF53WV4wCUC+menp699jOlpWD7rhz5fP5Kf3//UFdX132q+l4Ad3d3d7/fGPN1EZlQ1e/19PS8dPbs2fWu694kIgOqOqqqm4Dy4rKlUumOw4cPN3KVYk7WVkE1xsx5aSBLT+duhDEmQrkSnssZlIeXnxWRY6p6PI7j41nveFeq4eHh9XEc7xSRnQBej6t3kp5EuWh+OI7jh+dYsDDTfN/frKrjAKpPmv9pkiS7JicnH29mXku1devWV3d0dBxAuRNeMhF5ulgsjqRxgk7DfOfqxWr1czvbtzGt3r5zGRwc7FPV3ap6y0L7ishPAHx63bp1e/bt2xenkQ8LLEuMMZtE5JCqfhfAMwCeSZLkO2vWrDk+NjbGyZHUFjzP2yginwcAVX1fVi99Vo2OjnaeP3/+3SLydgBvBNBd56GXAHxXVR/s7e3dm9YJOg0rqQNm+y5dFtp3HmKM2QxgF8qr9b8GwA0AzgH4MYBjIjJ28eLFkFeOiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIiIhWgv8Hnffz4dmwY9cAAAAASUVORK5CYII=);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3csvg%20xmlns:dc='http://purl.org/dc/elements/1.1/'%20xmlns:cc='http://creativecommons.org/ns%23'%20xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23'%20xmlns:svg='http://www.w3.org/2000/svg'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd'%20xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape'%20viewBox='0%200%20600%2060'%20height='60'%20width='600'%20id='svg4225'%20version='1.1'%20inkscape:version='0.91%20r13725'%20sodipodi:docname='spritesheet.svg'%20inkscape:export-filename='/home/fpuga/development/upstream/icarto.Leaflet.draw/src/images/spritesheet-2x.png'%20inkscape:export-xdpi='90'%20inkscape:export-ydpi='90'%3e%3cmetadata%20id='metadata4258'%3e%3crdf:RDF%3e%3ccc:Work%20rdf:about=''%3e%3cdc:format%3eimage/svg+xml%3c/dc:format%3e%3cdc:type%20rdf:resource='http://purl.org/dc/dcmitype/StillImage'%20/%3e%3cdc:title%20/%3e%3c/cc:Work%3e%3c/rdf:RDF%3e%3c/metadata%3e%3cdefs%20id='defs4256'%20/%3e%3csodipodi:namedview%20pagecolor='%23ffffff'%20bordercolor='%23666666'%20borderopacity='1'%20objecttolerance='10'%20gridtolerance='10'%20guidetolerance='10'%20inkscape:pageopacity='0'%20inkscape:pageshadow='2'%20inkscape:window-width='1920'%20inkscape:window-height='1056'%20id='namedview4254'%20showgrid='false'%20inkscape:zoom='1.3101852'%20inkscape:cx='237.56928'%20inkscape:cy='7.2419621'%20inkscape:window-x='1920'%20inkscape:window-y='24'%20inkscape:window-maximized='1'%20inkscape:current-layer='svg4225'%20/%3e%3cg%20id='enabled'%20style='fill:%23464646;fill-opacity:1'%3e%3cg%20id='polyline'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%2018,36%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4229'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2036,18%200,6%206,0%200,-6%20-6,0%20z%20m%204,4%20-2,0%200,-2%202,0%200,2%20z'%20id='path4231'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%2023.142,39.145%20-2.285,-2.29%2016,-15.998%202.285,2.285%20z'%20id='path4233'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cpath%20id='polygon'%20d='M%20100,24.565%2097.904,39.395%2083.07,42%2076,28.773%2086.463,18%20Z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='rectangle'%20d='m%20140,20%2020,0%200,20%20-20,0%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='circle'%20d='m%20221,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20id='marker'%20d='m%20270,19%20c%20-4.971,0%20-9,4.029%20-9,9%200,4.971%205.001,12%209,14%204.001,-2%209,-9.029%209,-14%200,-4.971%20-4.029,-9%20-9,-9%20z%20m%200,12.5%20c%20-2.484,0%20-4.5,-2.014%20-4.5,-4.5%200,-2.484%202.016,-4.5%204.5,-4.5%202.485,0%204.5,2.016%204.5,4.5%200,2.486%20-2.015,4.5%20-4.5,4.5%20z'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cg%20id='edit'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20337,30.156%200,0.407%200,5.604%20c%200,1.658%20-1.344,3%20-3,3%20l%20-10,0%20c%20-1.655,0%20-3,-1.342%20-3,-3%20l%200,-10%20c%200,-1.657%201.345,-3%203,-3%20l%206.345,0%203.19,-3.17%20-9.535,0%20c%20-3.313,0%20-6,2.687%20-6,6%20l%200,10%20c%200,3.313%202.687,6%206,6%20l%2010,0%20c%203.314,0%206,-2.687%206,-6%20l%200,-8.809%20-3,2.968'%20id='path4240'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.72,24.637%20-8.892,8.892%20-2.828,0%200,-2.829%208.89,-8.89%20z'%20id='path4242'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20338.697,17.826%204,0%200,4%20-4,0%20z'%20transform='matrix(-0.70698336,-0.70723018,0.70723018,-0.70698336,567.55917,274.78273)'%20id='path4244'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3cg%20id='remove'%20style='fill:%23464646;fill-opacity:1'%3e%3cpath%20d='m%20381,42%2018,0%200,-18%20-18,0%200,18%20z%20m%2014,-16%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z%20m%20-4,0%202,0%200,14%20-2,0%200,-14%20z'%20id='path4247'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3cpath%20d='m%20395,20%200,-4%20-10,0%200,4%20-6,0%200,2%2022,0%200,-2%20-6,0%20z%20m%20-2,0%20-6,0%200,-2%206,0%200,2%20z'%20id='path4249'%20inkscape:connector-curvature='0'%20style='fill:%23464646;fill-opacity:1'%20/%3e%3c/g%3e%3c/g%3e%3cg%20id='disabled'%20transform='translate(120,0)'%20style='fill:%23bbbbbb'%3e%3cuse%20xlink:href='%23edit'%20id='edit-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3cuse%20xlink:href='%23remove'%20id='remove-disabled'%20x='0'%20y='0'%20width='100%25'%20height='100%25'%20/%3e%3c/g%3e%3cpath%20style='fill:none;stroke:%23464646;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1'%20id='circle-3'%20d='m%20581.65725,30%20c%200,6.078%20-4.926,11%20-11,11%20-6.074,0%20-11,-4.922%20-11,-11%200,-6.074%204.926,-11%2011,-11%206.074,0%2011,4.926%2011,11%20z'%20inkscape:connector-curvature='0'%20/%3e%3c/svg%3e")}.leaflet-draw a{display:block;text-align:center;text-decoration:none}.leaflet-draw a .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.leaflet-draw-actions{display:none;list-style:none;margin:0;padding:0;position:absolute;left:26px;top:0;white-space:nowrap}.leaflet-touch .leaflet-draw-actions{left:32px}.leaflet-right .leaflet-draw-actions{right:26px;left:auto}.leaflet-touch .leaflet-right .leaflet-draw-actions{right:32px;left:auto}.leaflet-draw-actions li{display:inline-block}.leaflet-draw-actions li:first-child a{border-left:0}.leaflet-draw-actions li:last-child a{-webkit-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0}.leaflet-right .leaflet-draw-actions li:last-child a{-webkit-border-radius:0;border-radius:0}.leaflet-right .leaflet-draw-actions li:first-child a{-webkit-border-radius:4px 0 0 4px;border-radius:4px 0 0 4px}.leaflet-draw-actions a{background-color:#919187;border-left:1px solid #AAA;color:#fff;font:11px/19px Helvetica Neue,Arial,Helvetica,sans-serif;line-height:28px;text-decoration:none;padding-left:10px;padding-right:10px;height:28px}.leaflet-touch .leaflet-draw-actions a{font-size:12px;line-height:30px;height:30px}.leaflet-draw-actions-bottom{margin-top:0}.leaflet-draw-actions-top{margin-top:1px}.leaflet-draw-actions-top a,.leaflet-draw-actions-bottom a{height:27px;line-height:27px}.leaflet-draw-actions a:hover{background-color:#a0a098}.leaflet-draw-actions-top.leaflet-draw-actions-bottom a{height:26px;line-height:26px}.leaflet-draw-toolbar .leaflet-draw-draw-polyline{background-position:-2px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-polyline{background-position:0 -1px}.leaflet-draw-toolbar .leaflet-draw-draw-polygon{background-position:-31px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-polygon{background-position:-29px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-rectangle{background-position:-62px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-rectangle{background-position:-60px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-circle{background-position:-92px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-circle{background-position:-90px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-marker{background-position:-122px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-marker{background-position:-120px -1px}.leaflet-draw-toolbar .leaflet-draw-draw-circlemarker{background-position:-273px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-draw-circlemarker{background-position:-271px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-edit{background-position:-152px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-edit{background-position:-150px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-remove{background-position:-182px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-remove{background-position:-180px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-edit.leaflet-disabled{background-position:-212px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-edit.leaflet-disabled{background-position:-210px -1px}.leaflet-draw-toolbar .leaflet-draw-edit-remove.leaflet-disabled{background-position:-242px -2px}.leaflet-touch .leaflet-draw-toolbar .leaflet-draw-edit-remove.leaflet-disabled{background-position:-240px -2px}.leaflet-mouse-marker{background-color:#fff;cursor:crosshair}.leaflet-draw-tooltip{background:#363636;background:#00000080;border:1px solid transparent;-webkit-border-radius:4px;border-radius:4px;color:#fff;font:12px/18px Helvetica Neue,Arial,Helvetica,sans-serif;margin-left:20px;margin-top:-21px;padding:4px 8px;position:absolute;visibility:hidden;white-space:nowrap;z-index:6}.leaflet-draw-tooltip:before{border-right:6px solid black;border-right-color:#00000080;border-top:6px solid transparent;border-bottom:6px solid transparent;content:"";position:absolute;top:7px;left:-7px}.leaflet-error-draw-tooltip{background-color:#f2dede;border:1px solid #e6b6bd;color:#b94a48}.leaflet-error-draw-tooltip:before{border-right-color:#e6b6bd}.leaflet-draw-tooltip-single{margin-top:-12px}.leaflet-draw-tooltip-subtext{color:#f8d5e4}.leaflet-draw-guide-dash{font-size:1%;opacity:.6;position:absolute;width:5px;height:5px}.leaflet-edit-marker-selected{background-color:#fe57a11a;border:4px dashed rgba(254,87,161,.6);-webkit-border-radius:4px;border-radius:4px;box-sizing:content-box}.leaflet-edit-move{cursor:move}.leaflet-edit-resize{cursor:pointer}.leaflet-oldie .leaflet-draw-toolbar{border:1px solid #999}`,vo=".leaflet-ruler{height:35px;width:35px;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAQAAABKfvVzAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QAAKqNIzIAAAAJcEhZcwAADdcAAA3XAUIom3gAAAAHdElNRQfhBQoMHg6McuYvAAABwklEQVQ4y43TP0jUYRgH8M/daQpqdujhnwShGiwyipCIoIgWxyIwrqEhnCQoGqKhpoYMg1qCQjg8TC2JCtSkjCgaKisIhyQUwpJssD9KZWRZg6d450/yGV54n/fzfd53eUOCaoNa5QpNGNPr9cKjUAatdsB++co0G1XiiHd+uqnTq8VzI874o9s2Ic1iiEpii9tmnJOdfkOldt/dU+HYolHnjdmpRNzbuVaNL86m4sXqNOrz3kMXHFKYMqd8VREGBToMifqLgwY1yNZirya5knaBqH16fJjNJiWEFSlxy4g980+pMuZkir/UJjLbrvNRPnINaLUygK/yQpuImHp47LOjuKJPOJA/1y4iZsAlyozLs8IO42L/4QlhGrSCy5oCeKH+dM59vVbL9sn6AP5MRzpnVKtN1viRxit1WRvEmVKFrQbTpoddNR3E+aYKuw1lPOapa0GcEf22KzOtejmcG1rkYdjEAn59KU5cDzjt+HI4BSZtVJTazfIsMQOmFAusLr/E53lniickJYIDNcaUL+JhMZPWBUdOeCCaweGOw5k0lFrv2uyRuBxPlLpoBtTK0p3mh+f+dKl6jX6LapRj6XrzD+1bmkFA/dTVAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE3LTA1LTEwVDEyOjMwOjE0KzAyOjAwUNH5TAAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNy0wNS0xMFQxMjozMDoxNCswMjowMCGMQfAAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC);background-repeat:no-repeat;background-position:center}.leaflet-ruler:hover{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=)}.leaflet-ruler-clicked{height:35px;width:35px;background-repeat:no-repeat;background-position:center;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=);border-color:#7fff00!important}.leaflet-bar{background-color:#fff}.leaflet-control{cursor:pointer}.result-tooltip{background-color:#fff;border-width:medium;border-color:#de0000;font-size:smaller}.moving-tooltip{background-color:#ffffffb3;background-clip:padding-box;opacity:.5;border:dotted;border-color:red;font-size:smaller}.plus-length{padding-left:45px}",yo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAABSCAMAAAAhFXfZAAAC91BMVEVMaXEzeak2f7I4g7g3g7cua5gzeKg8hJo3grY4g7c3grU0gLI2frE0daAubJc2gbQwd6QzeKk2gLMtd5sxdKIua5g1frA2f7IydaM0e6w2fq41fK01eqo3grgubJgta5cxdKI1f7AydaQydaMxc6EubJgvbJkwcZ4ubZkwcJwubZgubJcydqUydKIxapgubJctbJcubZcubJcvbJYubJcvbZkubJctbJctbZcubJg2f7AubJcrbZcubJcubJcua5g3grY0fq8ubJcubJdEkdEwhsw6i88vhswuhcsuhMtBjMgthMsrg8srgss6is8qgcs8i9A9iMYtg8spgcoogMo7hcMngMonf8olfso4gr8kfck5iM8jfMk4iM8he8k1fro7itAgesk2hs8eecgzfLcofssdeMg0hc4cd8g2hcsxeLQbdsgZdcgxeLImfcszhM0vda4xgckzhM4xg84wf8Yxgs4udKsvfcQucqhUndROmdM1fK0wcZ8vb5w0eqpQm9MzeKhXoNVcpdYydKNWn9VZotVKltJFjsIwcJ1Rms9OlslLmtH///8+kc9epdYzd6dbo9VHkMM2f7FHmNBClM8ydqVcpNY9hro3gLM9hLczealQmcw3fa46f7A8gLMxc6I3eagyc6FIldJMl9JSnNRSntNNl9JPnNJFi75UnM9ZodVKksg8kM45jc09e6ZHltFBk883gbRBh7pDk9EwcaBzn784g7dKkcY2i81Om9M7j85Llc81is09g7Q4grY/j9A0eqxKmdFFltBEjcXf6fFImdBCiLxJl9FGlNFBi78yiMxVndEvbpo6js74+vx+psPP3+o/ks5HkcpGmNCjwdZCkNDM3ehYoNJEls+lxNkxh8xHks0+jdC1zd5Lg6r+/v/H2ufz9/o3jM3t8/edvdM/k89Th61OiLBSjbZklbaTt9BfptdjmL1AicBHj8hGk9FAgK1dkLNTjLRekrdClc/k7fM0icy0y9tgp9c4jc2NtM9Dlc8zicxeXZn3AAAAQ3RSTlMAHDdTb4yPA+LtnEQmC4L2EmHqB7XA0d0sr478x4/Yd5i1zOfyPkf1sLVq4Nh3FvjxopQ2/STNuFzUwFIwxKaejILpIBEV9wAABhVJREFUeF6s1NdyFEcYBeBeoQIhRAkLlRDGrhIgY3BJL8CVeKzuyXFzzjkn5ZxzzuScg3PO8cKzu70JkO0LfxdTU//pM9vTu7Xgf6KqOVTb9X7toRrVEfBf1HTVjZccrT/2by1VV928Yty9ZbVuucdz90frG8DBjl9pVApbOstvmMuvVgaNXSfAAd6pGxpy6yxf5ph43pS/4f3uoaGm2rdu72S9xzOvMymkZFq/ptDrk90mhW7e4zl7HLzhxGWPR20xmSxJ/VqldG5m9XhaVOA1DadsNh3Pu5L2N6QtPO/32JpqQBVVk20oy/Pi2s23WEvyfHbe1thadVQttvm7Llf65gGmXK67XtupyoM7HQhmXdLS8oGWJNeOJ3C5fG5XCEJnkez3/oFdsvgJ4l2ANZwhrJKk/7OSXa+3Vw2WJMlKnGkobouYk6T0TyX30klOUnTD9HJ5qpckL3EW/w4XF3Xd0FGywXUrstrclVsqz5Pd/sXFYyDnPdrLcQODmGOK47IZb4CmibmMn+MYRzFZ5jg33ZL/EJrWcszHmANy3ARBK/IXtciJy8VsitPSdE3uuHxzougojcUdr8/32atnz/ev3f/K5wtpxUTpcaI45zusVDpYtZi+jg0oU9b3x74h7+n9ABvYEZeKaVq0sh0AtLKsFtqNBdeT0MrSzwwlq9+x6xAO4tgOtSzbCjrNQQiNvQUbUEubvzBUeGw26yDCsRHCoLkTHDa7IdOLIThs/gHvChszh2CimE8peRs47cxANI0lYNB5y1DljpOF0IhzBDPOZnDOqYYbeGKECbPzWnXludPphw5c2YBq5zlwXphIbO4VDCZ0gnPfUO1TwZoYwAs2ExPCedAu9DAjfQUjzITQb3jNj0KG2Sgt6BHaQUdYzWz+XmBktOHwanXjaSTcwwziBcuMOtwBmqPrTOxFQR/DRKKPqyur0aiW6cULYsx6tBm0jXpR/AUWR6HRq9WVW6MRhIq5jLyjbaCTDCijyYJNpCajdyobP/eTw0iexBAKkJ3gA5KcQb2zBXsIBckn+xVv8jkZSaEFHE+jFEleAEfayRU0MouNoBmB/L50Ai/HSLIHxcrpCvnhSQAuakKp2C/YbCylJjXRVy/z3+Kv/RrNcCo+WUzlVEhzKffnTQnxeN9fWF88fiNCUdSTsaufaChKWInHeysygfpIqagoakW+vV20J8uyl6TyNKEZWV4oRSPyCkWpgOLSbkCObT8o2r6tlG58HQquf6O0v50tB7JM7F4EORd2dx/K0w/KHsVkLPaoYrwgP/y7krr3SSMA4zj+OBgmjYkxcdIJQyQRKgg2viX9Hddi9UBb29LrKR7CVVEEEXWojUkXNyfTNDE14W9gbHJNuhjDettN3ZvbOvdOqCD3Jp/9l+/wJE+9PkYGjx/fqkys3S2rMozM/o2106rfMUINo6hVqz+eu/hd1c4xTg0TAfy5kV+4UG6+IthHTU9woWmxuKNbTfuCSfovBCxq7EtHqvYL4Sm6F8GVxsSXHMQ07TOi1DKtZxjWaaIyi4CXWjxPccUw8WVbMYY5wxC1mzEyXMJWkllpRloi+Kkoq69sxBTlElF6aAxYUbjXNlhlDZilDnM4U5SlN5biRsRHnbx3mbeWjEh4mEyiuJDl5XcWVmX5GvNkFgLWZM5qwsop4/AWfLhU1cR7k1VVvcYCWRkOI6Xy5gmnphCYIkvzuNYzHzosq2oNk2RtSs8khfUOfHIDgR6ysYBaMpl4uEgk2U/oJTs9AaTSwma7dT69geAE2ZpEjUsn2ieJNHeKfrI3EcAGJ2ZaNgVuC8EBctCLc57P5u5led6IOBkIYkuQMrmmjChs4VkfOerHqSBkPzZlhe06RslZ3zMjk2sscqKwY0RcjKK+LWbzd7KiHhkncs/siFJ+V5eXxD34B8nVuJEpGJNmxN2gH3vSvp7J70tF+D1Ej8qUJD1TkErAND2GZwTFg/LubvmgiBG3SOvdlsqFQrkEzJCL1rstlnVFROixZoDDSuXQFHESwVGlcuQcMb/b42NgjLowh5MTDFE3vNB5qStRIErdCQEh6pLPR92anSUb/wAIhldAaDMpGgAAAABJRU5ErkJggg==",Lo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=",wo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC",bo="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='430'%20height='430'%20style='width:100%25;height:100%25;transform:translate3d(0,0,0);content-visibility:visible'%20viewBox='0%200%20430%20430'%3e%3cdefs%3e%3cclipPath%20id='i'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='s'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='e'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='p'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='f'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='m'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='g'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='j'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='h'%3e%3cpath%20d='M0%200h430v430H0z'/%3e%3c/clipPath%3e%3cfilter%20id='t'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cfilter%20id='r'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'%20stdDeviation='52.5%2052.5'/%3e%3c/filter%3e%3cfilter%20id='n'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cfilter%20id='k'%20width='300%25'%20height='300%25'%20x='-100%25'%20y='-100%25'%3e%3cfeGaussianBlur%20result='filter_result_0'/%3e%3c/filter%3e%3cmask%20id='u'%20mask-type='alpha'%3e%3cuse%20xmlns:ns1='http://www.w3.org/1999/xlink'%20ns1:href='%23a'/%3e%3c/mask%3e%3cmask%20id='q'%20mask-type='alpha'%3e%3cuse%20xmlns:ns2='http://www.w3.org/1999/xlink'%20ns2:href='%23b'/%3e%3c/mask%3e%3cmask%20id='o'%20mask-type='alpha'%3e%3cuse%20xmlns:ns3='http://www.w3.org/1999/xlink'%20ns3:href='%23c'/%3e%3c/mask%3e%3cmask%20id='l'%20mask-type='alpha'%3e%3cuse%20xmlns:ns4='http://www.w3.org/1999/xlink'%20ns4:href='%23d'/%3e%3c/mask%3e%3cg%20id='a'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23e)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3cg%20id='b'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='12'%20clip-path='url(%23f)'%20style='display:block'%3e%3cpath%20stroke='%2308A88A'%20d='M44.446-66.518a79.998%2079.998%200%200%200-101.012%209.952A79.998%2079.998%200%201%200%2056.569%2056.569%2080.005%2080.005%200%200%200%2073.91-30.615a80.001%2080.001%200%200%200-29.464-35.903z'%20class='secondary'%20style='display:block'%20transform='translate(215%20214)'/%3e%3cpath%20stroke='%23121331'%20d='m141.409%2025.241%208.727%205.041s0%200%200%200a22.3%2022.3%200%200%201%2010.411%2013.542%2022.32%2022.32%200%200%201-2.221%2016.937l-26.515%2045.924a22.325%2022.325%200%200%201-30.497%208.172l-8.754-5.059a143.414%20143.414%200%200%201-43.718%2025.286v10.108a22.302%2022.302%200%200%201-13.778%2020.612%2022.303%2022.303%200%200%201-8.539%201.696h-53.029a22.303%2022.303%200%200%201-15.779-6.531%2022.302%2022.302%200%200%201-6.537-15.777v-10.073a143.416%20143.416%200%200%201-43.719-25.285l-8.754%205.059a22.325%2022.325%200%200%201-30.497-8.172l-26.523-45.924a22.315%2022.315%200%200%201-2.238-16.943A22.31%2022.31%200%200%201-150.142%2030.3l8.727-5.041a145.097%20145.097%200%200%201%200-50.518l-8.727-5.041a22.294%2022.294%200%200%201-10.409-13.554%2022.306%2022.306%200%200%201%202.238-16.943l26.514-45.924a22.325%2022.325%200%200%201%2030.497-8.172l8.754%205.059a143.416%20143.416%200%200%201%2043.719-25.285v-10.073a22.302%2022.302%200%200%201%206.537-15.777%2022.3%2022.3%200%200%201%2015.779-6.531h53.02a22.307%2022.307%200%200%201%2022.317%2022.308v10.037a143.41%20143.41%200%200%201%2043.718%2025.285l8.754-5.059a22.325%2022.325%200%200%201%2030.497%208.172l26.515%2045.942a22.313%2022.313%200%200%201-1.618%2024.757%2022.294%2022.294%200%200%201-6.554%205.74l-8.727%205.041a145.097%20145.097%200%200%201%200%2050.518z'%20class='primary'%20style='display:block'%20transform='rotate(-120%20169.576%2045.095)'/%3e%3c/g%3e%3cg%20id='c'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23g)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3cg%20id='d'%20fill-opacity='0'%20stroke-linecap='round'%20stroke-linejoin='round'%20clip-path='url(%23h)'%20style='display:none'%3e%3cpath%20class='secondary'%20style='display:none'/%3e%3cpath%20class='primary'%20style='display:none'/%3e%3c/g%3e%3c/defs%3e%3cg%20clip-path='url(%23i)'%3e%3cg%20clip-path='url(%23j)'%20filter='url(%23k)'%20mask='url(%23l)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23m)'%20filter='url(%23n)'%20mask='url(%23o)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23p)'%20mask='url(%23q)'%20style='display:block'%3e%3cg%20filter='url(%23r)'%20transform='rotate(-94%20238.762%20-16.565)%20scale(2.4)'%3e%3cg%20class='design'%3e%3cpath%20fill='%234BE1EC'%20d='M0-250c137.975%200%20250%20112.025%20250%20250S137.975%20250%200%20250-250%20137.975-250%200-137.975-250%200-250z'%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20fill='%23CB5EEE'%20d='M113.242-295.384c97.478%200%20176.5%2079.022%20176.5%20176.5s-79.022%20176.5-176.5%20176.5c-43.948%200-74.396-34.057-105.29-60.631-37.631-32.369-71.21-62.338-71.21-115.869%200-97.478%2079.022-176.5%20176.5-176.5z'%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20clip-path='url(%23s)'%20filter='url(%23t)'%20mask='url(%23u)'%20style='display:none'%3e%3cg%20class='design'%3e%3cpath%20class='primary'/%3e%3c/g%3e%3cg%20class='design'%3e%3cpath%20class='secondary'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Ui="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Generator:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%20-1.67%2047.336%2047.336'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Group_42'%20data-name='Group%2042'%20transform='translate(-172.455%20-364.36)'%3e%3cpath%20id='Rectangle_17'%20data-name='Rectangle%2017'%20d='M4.351,0H40.984a4.351,4.351,0,0,1,4.351,4.351V22.117a1,1,0,0,1-1,1H1a1,1,0,0,1-1-1V4.351A4.351,4.351,0,0,1,4.351,0Z'%20transform='translate(173.455%20384.243)'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cpath%20id='Path_90'%20data-name='Path%2090'%20d='M218.79,390.249a3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.778,3.778,0,0,1-3.777-3.778'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cg%20id='Group_41'%20data-name='Group%2041'%3e%3cpath%20id='Rectangle_18'%20data-name='Rectangle%2018'%20d='M4.351,0H26.473a4.351,4.351,0,0,1,4.351,4.351V17.883a1,1,0,0,1-1,1H1a1,1,0,0,1-1-1V4.351A4.351,4.351,0,0,1,4.351,0Z'%20transform='translate(180.71%20365.36)'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3cpath%20id='Path_91'%20data-name='Path%2091'%20d='M211.234,370.794a3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778'%20fill='none'%20stroke='%23000000'%20stroke-linecap='round'%20stroke-linejoin='round'%20stroke-width='2'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e",xo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAQAAABKfvVzAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAAmJLR0QAAKqNIzIAAAAJcEhZcwAADdcAAA3XAUIom3gAAAAHdElNRQfhBQoMHg6McuYvAAABwklEQVQ4y43TP0jUYRgH8M/daQpqdujhnwShGiwyipCIoIgWxyIwrqEhnCQoGqKhpoYMg1qCQjg8TC2JCtSkjCgaKisIhyQUwpJssD9KZWRZg6d450/yGV54n/fzfd53eUOCaoNa5QpNGNPr9cKjUAatdsB++co0G1XiiHd+uqnTq8VzI874o9s2Ic1iiEpii9tmnJOdfkOldt/dU+HYolHnjdmpRNzbuVaNL86m4sXqNOrz3kMXHFKYMqd8VREGBToMifqLgwY1yNZirya5knaBqH16fJjNJiWEFSlxy4g980+pMuZkir/UJjLbrvNRPnINaLUygK/yQpuImHp47LOjuKJPOJA/1y4iZsAlyozLs8IO42L/4QlhGrSCy5oCeKH+dM59vVbL9sn6AP5MRzpnVKtN1viRxit1WRvEmVKFrQbTpoddNR3E+aYKuw1lPOapa0GcEf22KzOtejmcG1rkYdjEAn59KU5cDzjt+HI4BSZtVJTazfIsMQOmFAusLr/E53lniickJYIDNcaUL+JhMZPWBUdOeCCaweGOw5k0lFrv2uyRuBxPlLpoBtTK0p3mh+f+dKl6jX6LapRj6XrzD+1bmkFA/dTVAAAAJXRFWHRkYXRlOmNyZWF0ZQAyMDE3LTA1LTEwVDEyOjMwOjE0KzAyOjAwUNH5TAAAACV0RVh0ZGF0ZTptb2RpZnkAMjAxNy0wNS0xMFQxMjozMDoxNCswMjowMCGMQfAAAAAZdEVYdFNvZnR3YXJlAHd3dy5pbmtzY2FwZS5vcmeb7jwaAAAAAElFTkSuQmCC",ko="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAMAAADXqc3KAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAAACmAAAApgHdff84AAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAn9QTFRF////AAAAAAAAAAAAAAAAAAAzABcXABQUABIkDhwrAA0aAAwYABUgABQfABIbABAZAA8fABUcABMaABMfABIeABEcABAbABQeABMdABIdABEbABIbABIbABEdABEcABIcBxsoABEdABIdABIdABEcABMbABMdFBwgERofAhIbEhsfAhIdBxUeEhsgEBofAhMbAhMdBRMdAhIbAhIdAhMdCRceARIcDBgfDBgfDBcfDBcfFhwgDBceDBceCxceFCs5HTdGAxMcDxofGTFAHDRDHDVDHDVEHTZFDRkfEBofERogCh0oERsgARIcEhsfEhsgCh4pDCEsDRkfDRkfEBofBhQdDSMvDRgfDBgfCBUeBxUeDyUyECYzUDktPTAqCRceCRYeChYeDxkfEBkgLCgmWj4wCBYdW0AwGh4hHCAiHSAiTDctBhUdBxYdEBkfLyonMConBhUdJiUkLCclLSgmLigmOzApPTEpDBgfBRQdDBgfERsgWT8wBBMdCBYeChceQjMrSzctZEUyBBMdERsgXUAxXkExY0QzglQ5AxUfBxolSjcthlU6hlY7h1Y7AxMcSDUsSjYsd042g1Q5hlY6jVo8AhIcAxMcBBQdLEpcOVpvARIcAhIcBhQdDSIuEhsgJ0NUNS0oNi0oO11yTTgtUXmSUnqUXEAxXUExYEIyZUUzaEYzb0o1cEo1dEw2i1g8jFk8jcfskFs9mdX9mmA/mtf/pmZCqGdCsWxEvnJHxHVJxnZJyHdJzHlK0XxM031M139N3IFO3YJO4INP5IVQ5YZQ5oZQ6ohR7IlS7opS74tS8ItT841T9I1T9o5U949U+ZBV+pBV/ZJW/pJW/5NWIYcOagAAAJt0Uk5TAAECAwQFCw0OEhQVGBkcHyEkKCkqLTAzNUZLVFZZW2RnanJzeHl8f4uMjY6Pj5KVl52eoKGprKytrq+vsLGytLu9vb/BwsLDxcXP0NDS09bf4uPk5OXl5ufo6enq7O3u7+/x8fHy8/P09PT09fX19fX29vb29vb29/j4+Pj5+fn5+fn6+vr6+vr7/Pz8/Pz9/f39/f39/v7+/v7Td3FlAAABgklEQVQoU2NggAMRJU1DTWURBlQgqhWUND11Tfr05GBdMYQws8a07j2XVx2/cnLl5T0T5+ixQsX5/RrWr70CA+s2NPoLgMUlciddvnLl3PbslMysmi2ngXKTc/iA4uwRC1dfudRT76UtJy5lMHvHlSsni82ZgBLWbZdOHCuPlARpForvBYszA9ky1WeunC8y5YCI9125cqrEnJlbnoHBZ/6mK+0eTAjxUgtmbl99Bt6Ksxd2pXGDxRPg4kZMDIqxV6406cDFT8PEGRwnHLlYJQwSTwSJ51tCxRmiVuw7VAsRP7zkIEKcofnAlb0hEPWXls9AiDNUHriyMxwoPgVoToEVQpwhdNHuY/2imOIMZq1nr2QUgsVtkMUZZOOuXOmYiinOwF63/8QVsDgLd0wnFwMCOM3dBhK3ZeGOXjzLHklCIu8oRDxs8eaNXYJIMuplJ0HigYs3b906UwFJgtGzxY6FLWDe0mXLli3wVoEAaZAMjxoLA6eDu5urq4uziTEEqAIAvamx163e5EoAAAAASUVORK5CYII=";function Ao(m){const c="data-leaflet-styles";if(m.querySelector(`style[${c}]`))return;const s=document.createElement("style");s.setAttribute(c,"true"),s.textContent=`
|
|
5
5
|
/* --- Leaflet core CSS --- */
|
|
6
|
-
${
|
|
6
|
+
${_o}
|
|
7
7
|
|
|
8
8
|
/* --- Leaflet.draw CSS --- */
|
|
9
|
-
${
|
|
9
|
+
${go}
|
|
10
10
|
|
|
11
11
|
/* --- Leaflet.ruler CSS --- */
|
|
12
|
-
${
|
|
12
|
+
${vo}
|
|
13
13
|
|
|
14
14
|
/* --- Fix Leaflet.ruler icons (broken relative paths in inlined CSS) --- */
|
|
15
15
|
.leaflet-ruler {
|
|
16
16
|
width: 30px !important; /* Match Leaflet Draw default size approx */
|
|
17
17
|
height: 30px !important;
|
|
18
18
|
background-color: #fff; /* Ensure visibility */
|
|
19
|
-
background-image: url(${
|
|
19
|
+
background-image: url(${xo}) !important;
|
|
20
20
|
background-size: 16px 16px; /* Scale icon to fit */
|
|
21
21
|
}
|
|
22
22
|
.leaflet-ruler:hover,
|
|
23
23
|
.leaflet-ruler-clicked {
|
|
24
|
-
background-image: url(${
|
|
24
|
+
background-image: url(${ko}) !important;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
/* --- Custom overrides for marker/handle sizes --- */
|
|
@@ -51,7 +51,7 @@ ${mo}
|
|
|
51
51
|
padding: 0;
|
|
52
52
|
border-radius: 4px;
|
|
53
53
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
|
|
54
|
-
background-image: url(${
|
|
54
|
+
background-image: url(${bo});
|
|
55
55
|
transition: background-color 0.15s ease, box-shadow 0.15s ease;
|
|
56
56
|
}
|
|
57
57
|
.leaflet-ruler-settings-button:hover {
|
|
@@ -135,7 +135,7 @@ ${mo}
|
|
|
135
135
|
|
|
136
136
|
/* --- Layer Cake draw tool icon + manager UI --- */
|
|
137
137
|
.leaflet-draw-toolbar a.leaflet-draw-draw-cake {
|
|
138
|
-
background-image: url(${
|
|
138
|
+
background-image: url(${Ui}) !important;
|
|
139
139
|
background-size: 18px 18px !important;
|
|
140
140
|
background-position: 50% 50% !important;
|
|
141
141
|
background-repeat: no-repeat !important;
|
|
@@ -193,21 +193,21 @@ ${mo}
|
|
|
193
193
|
.leaflet-draw-move-mode .leaflet-interactive:active {
|
|
194
194
|
cursor: grabbing !important;
|
|
195
195
|
}
|
|
196
|
-
`,
|
|
196
|
+
`,m.appendChild(s)}function Mo(m){const c="data-leaflet-custom-styles";if(m.querySelector(`style[${c}]`))return;const s=document.createElement("style");s.setAttribute(c,"true"),s.textContent=`
|
|
197
197
|
/* Ensure Layer Cake toolbar icon uses project asset instead of draw sprite sheet */
|
|
198
198
|
.leaflet-draw-toolbar a.leaflet-draw-draw-cake {
|
|
199
|
-
background-image: url(${
|
|
199
|
+
background-image: url(${Ui}) !important;
|
|
200
200
|
background-size: 18px 18px !important;
|
|
201
201
|
background-position: 50% 50% !important;
|
|
202
202
|
background-repeat: no-repeat !important;
|
|
203
203
|
background-color: #fff;
|
|
204
204
|
}
|
|
205
|
-
`,g.appendChild(s)}function ko(){var g,h;(h=(g=Q.Icon.Default).mergeOptions)==null||h.call(g,{iconRetinaUrl:_o,iconUrl:go,shadowUrl:vo})}function Ao(g){const{root:h,skipStyles:s}=g;try{s||(bo(h),ko()),xo(h)}catch{}}(function(g,h,s){function c(n,r){for(;(n=n.parentElement)&&!n.classList.contains(r););return n}L.drawVersion="1.0.4",L.Draw={},L.drawLocal={draw:{toolbar:{actions:{title:"Cancel drawing",text:"Cancel"},finish:{title:"Finish drawing",text:"Finish"},undo:{title:"Delete last point drawn",text:"Delete last point"},buttons:{polyline:"Draw a polyline",polygon:"Draw a polygon",rectangle:"Draw a rectangle",circle:"Draw a circle",marker:"Draw a marker",circlemarker:"Draw a circlemarker"}},handlers:{circle:{tooltip:{start:"Click and drag to draw circle."},radius:"Radius"},circlemarker:{tooltip:{start:"Click map to place circle marker."}},marker:{tooltip:{start:"Click map to place marker."}},polygon:{tooltip:{start:"Click to start drawing shape.",cont:"Click to continue drawing shape.",end:"Click first point to close this shape."}},polyline:{error:"<strong>Error:</strong> shape edges cannot cross!",tooltip:{start:"Click to start drawing line.",cont:"Click to continue drawing line.",end:"Click last point to finish line."}},rectangle:{tooltip:{start:"Click and drag to draw rectangle."}},simpleshape:{tooltip:{end:"Release mouse to finish drawing."}}}},edit:{toolbar:{actions:{save:{title:"Save changes",text:"Save"},cancel:{title:"Cancel editing, discards all changes",text:"Cancel"},clearAll:{title:"Clear all layers",text:"Clear All"}},buttons:{edit:"Edit layers",editDisabled:"No layers to edit",remove:"Delete layers",removeDisabled:"No layers to delete"}},handlers:{edit:{tooltip:{text:"Drag handles or markers to edit features.",subtext:"Click cancel to undo changes."}},remove:{tooltip:{text:"Click on a feature to remove."}}}}},L.Draw.Event={},L.Draw.Event.CREATED="draw:created",L.Draw.Event.EDITED="draw:edited",L.Draw.Event.DELETED="draw:deleted",L.Draw.Event.DRAWSTART="draw:drawstart",L.Draw.Event.DRAWSTOP="draw:drawstop",L.Draw.Event.DRAWVERTEX="draw:drawvertex",L.Draw.Event.EDITSTART="draw:editstart",L.Draw.Event.EDITMOVE="draw:editmove",L.Draw.Event.EDITRESIZE="draw:editresize",L.Draw.Event.EDITVERTEX="draw:editvertex",L.Draw.Event.EDITSTOP="draw:editstop",L.Draw.Event.DELETESTART="draw:deletestart",L.Draw.Event.DELETESTOP="draw:deletestop",L.Draw.Event.TOOLBAROPENED="draw:toolbaropened",L.Draw.Event.TOOLBARCLOSED="draw:toolbarclosed",L.Draw.Event.MARKERCONTEXT="draw:markercontext",L.Draw=L.Draw||{},L.Draw.Feature=L.Handler.extend({initialize:function(n,r){this._map=n,this._container=n._container,this._overlayPane=n._panes.overlayPane,this._popupPane=n._panes.popupPane,r&&r.shapeOptions&&(r.shapeOptions=L.Util.extend({},this.options.shapeOptions,r.shapeOptions)),L.setOptions(this,r);var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.Draw.Feature.include(L.Evented.prototype):L.Draw.Feature.include(L.Mixin.Events)},enable:function(){this._enabled||(L.Handler.prototype.enable.call(this),this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.DRAWSTART,{layerType:this.type}))},disable:function(){this._enabled&&(L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.DRAWSTOP,{layerType:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(L.DomUtil.disableTextSelection(),n.getContainer().focus(),this._tooltip=new L.Draw.Tooltip(this._map),L.DomEvent.on(this._container,"keyup",this._cancelDrawing,this))},removeHooks:function(){this._map&&(L.DomUtil.enableTextSelection(),this._tooltip.dispose(),this._tooltip=null,L.DomEvent.off(this._container,"keyup",this._cancelDrawing,this))},setOptions:function(n){L.setOptions(this,n)},_fireCreatedEvent:function(n){this._map.fire(L.Draw.Event.CREATED,{layer:n,layerType:this.type})},_cancelDrawing:function(n){n.keyCode===27&&(this._map.fire("draw:canceled",{layerType:this.type}),this.disable())}}),L.Draw.Polyline=L.Draw.Feature.extend({statics:{TYPE:"polyline"},Poly:L.Polyline,options:{allowIntersection:!0,repeatMode:!1,drawError:{color:"#b00b00",timeout:2500},icon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon"}),touchIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-touch-icon"}),guidelineDistance:20,maxGuideLineLength:4e3,shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!1,clickable:!0},metric:!0,feet:!0,nautic:!1,showLength:!0,zIndexOffset:2e3,factor:1,maxPoints:0},initialize:function(n,r){L.Browser.touch&&(this.options.icon=this.options.touchIcon),this.options.drawError.message=L.drawLocal.draw.handlers.polyline.error,r&&r.drawError&&(r.drawError=L.Util.extend({},this.options.drawError,r.drawError)),this.type=L.Draw.Polyline.TYPE,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._markers=[],this._markerGroup=new L.LayerGroup,this._map.addLayer(this._markerGroup),this._poly=new L.Polyline([],this.options.shapeOptions),this._tooltip.updateContent(this._getTooltipText()),this._mouseMarker||(this._mouseMarker=L.marker(this._map.getCenter(),{icon:L.divIcon({className:"leaflet-mouse-marker",iconAnchor:[20,20],iconSize:[40,40]}),opacity:0,zIndexOffset:this.options.zIndexOffset})),this._mouseMarker.on("mouseout",this._onMouseOut,this).on("mousemove",this._onMouseMove,this).on("mousedown",this._onMouseDown,this).on("mouseup",this._onMouseUp,this).addTo(this._map),this._map.on("mouseup",this._onMouseUp,this).on("mousemove",this._onMouseMove,this).on("zoomlevelschange",this._onZoomEnd,this).on("touchstart",this._onTouch,this).on("zoomend",this._onZoomEnd,this))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._clearHideErrorTimeout(),this._cleanUpShape(),this._map.removeLayer(this._markerGroup),delete this._markerGroup,delete this._markers,this._map.removeLayer(this._poly),delete this._poly,this._mouseMarker.off("mousedown",this._onMouseDown,this).off("mouseout",this._onMouseOut,this).off("mouseup",this._onMouseUp,this).off("mousemove",this._onMouseMove,this),this._map.removeLayer(this._mouseMarker),delete this._mouseMarker,this._clearGuides(),this._map.off("mouseup",this._onMouseUp,this).off("mousemove",this._onMouseMove,this).off("zoomlevelschange",this._onZoomEnd,this).off("zoomend",this._onZoomEnd,this).off("touchstart",this._onTouch,this).off("click",this._onTouch,this)},deleteLastVertex:function(){if(!(this._markers.length<=1)){var n=this._markers.pop(),r=this._poly,a=r.getLatLngs(),u=a.splice(-1,1)[0];this._poly.setLatLngs(a),this._markerGroup.removeLayer(n),r.getLatLngs().length<2&&this._map.removeLayer(r),this._vertexChanged(u,!1)}},addVertex:function(n){if(this._markers.length>=2&&!this.options.allowIntersection&&this._poly.newLatLngIntersects(n))return void this._showErrorTooltip();this._errorShown&&this._hideErrorTooltip(),this._markers.push(this._createMarker(n)),this._poly.addLatLng(n),this._poly.getLatLngs().length===2&&this._map.addLayer(this._poly),this._vertexChanged(n,!0)},completeShape:function(){this._markers.length<=1||!this._shapeIsValid()||(this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable())},_finishShape:function(){var n=this._poly._defaultShape?this._poly._defaultShape():this._poly.getLatLngs(),r=this._poly.newLatLngIntersects(n[n.length-1]);if(!this.options.allowIntersection&&r||!this._shapeIsValid())return void this._showErrorTooltip();this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()},_shapeIsValid:function(){return!0},_onZoomEnd:function(){this._markers!==null&&this._updateGuide()},_onMouseMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent),a=this._map.layerPointToLatLng(r);this._currentLatLng=a,this._updateTooltip(a),this._updateGuide(r),this._mouseMarker.setLatLng(a),L.DomEvent.preventDefault(n.originalEvent)},_vertexChanged:function(n,r){this._map.fire(L.Draw.Event.DRAWVERTEX,{layers:this._markerGroup}),this._updateFinishHandler(),this._updateRunningMeasure(n,r),this._clearGuides(),this._updateTooltip()},_onMouseDown:function(n){if(!this._clickHandled&&!this._touchHandled&&!this._disableMarkers){this._onMouseMove(n),this._clickHandled=!0,this._disableNewMarkers();var r=n.originalEvent,a=r.clientX,u=r.clientY;this._startPoint.call(this,a,u)}},_startPoint:function(n,r){this._mouseDownOrigin=L.point(n,r)},_onMouseUp:function(n){var r=n.originalEvent,a=r.clientX,u=r.clientY;this._endPoint.call(this,a,u,n),this._clickHandled=null},_endPoint:function(n,r,a){if(this._mouseDownOrigin){var u=L.point(n,r).distanceTo(this._mouseDownOrigin),f=this._calculateFinishDistance(a.latlng);this.options.maxPoints>1&&this.options.maxPoints==this._markers.length+1?(this.addVertex(a.latlng),this._finishShape()):f<10&&L.Browser.touch?this._finishShape():Math.abs(u)<9*(g.devicePixelRatio||1)&&this.addVertex(a.latlng),this._enableNewMarkers()}this._mouseDownOrigin=null},_onTouch:function(n){var r,a,u=n.originalEvent;!u.touches||!u.touches[0]||this._clickHandled||this._touchHandled||this._disableMarkers||(r=u.touches[0].clientX,a=u.touches[0].clientY,this._disableNewMarkers(),this._touchHandled=!0,this._startPoint.call(this,r,a),this._endPoint.call(this,r,a,n),this._touchHandled=null),this._clickHandled=null},_onMouseOut:function(){this._tooltip&&this._tooltip._onMouseOut.call(this._tooltip)},_calculateFinishDistance:function(n){var r;if(this._markers.length>0){var a;if(this.type===L.Draw.Polyline.TYPE)a=this._markers[this._markers.length-1];else{if(this.type!==L.Draw.Polygon.TYPE)return 1/0;a=this._markers[0]}var u=this._map.latLngToContainerPoint(a.getLatLng()),f=new L.Marker(n,{icon:this.options.icon,zIndexOffset:2*this.options.zIndexOffset}),_=this._map.latLngToContainerPoint(f.getLatLng());r=u.distanceTo(_)}else r=1/0;return r},_updateFinishHandler:function(){var n=this._markers.length;n>1&&this._markers[n-1].on("click",this._finishShape,this),n>2&&this._markers[n-2].off("click",this._finishShape,this)},_createMarker:function(n){var r=new L.Marker(n,{icon:this.options.icon,zIndexOffset:2*this.options.zIndexOffset});return this._markerGroup.addLayer(r),r},_updateGuide:function(n){var r=this._markers?this._markers.length:0;r>0&&(n=n||this._map.latLngToLayerPoint(this._currentLatLng),this._clearGuides(),this._drawGuide(this._map.latLngToLayerPoint(this._markers[r-1].getLatLng()),n))},_updateTooltip:function(n){var r=this._getTooltipText();n&&this._tooltip.updatePosition(n),this._errorShown||this._tooltip.updateContent(r)},_drawGuide:function(n,r){var a,u,f,_=Math.floor(Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2))),m=this.options.guidelineDistance,w=this.options.maxGuideLineLength,x=_>w?_-w:m;for(this._guidesContainer||(this._guidesContainer=L.DomUtil.create("div","leaflet-draw-guides",this._overlayPane));x<_;x+=this.options.guidelineDistance)a=x/_,u={x:Math.floor(n.x*(1-a)+a*r.x),y:Math.floor(n.y*(1-a)+a*r.y)},f=L.DomUtil.create("div","leaflet-draw-guide-dash",this._guidesContainer),f.style.backgroundColor=this._errorShown?this.options.drawError.color:this.options.shapeOptions.color,L.DomUtil.setPosition(f,u)},_updateGuideColor:function(n){if(this._guidesContainer)for(var r=0,a=this._guidesContainer.childNodes.length;r<a;r++)this._guidesContainer.childNodes[r].style.backgroundColor=n},_clearGuides:function(){if(this._guidesContainer)for(;this._guidesContainer.firstChild;)this._guidesContainer.removeChild(this._guidesContainer.firstChild)},_getTooltipText:function(){var n,r,a=this.options.showLength;return this._markers.length===0?n={text:L.drawLocal.draw.handlers.polyline.tooltip.start}:(r=a?this._getMeasurementString():"",n=this._markers.length===1?{text:L.drawLocal.draw.handlers.polyline.tooltip.cont,subtext:r}:{text:L.drawLocal.draw.handlers.polyline.tooltip.end,subtext:r}),n},_updateRunningMeasure:function(n,r){var a,u,f=this._markers.length;this._markers.length===1?this._measurementRunningTotal=0:(a=f-(r?2:1),u=L.GeometryUtil.isVersion07x()?n.distanceTo(this._markers[a].getLatLng())*(this.options.factor||1):this._map.distance(n,this._markers[a].getLatLng())*(this.options.factor||1),this._measurementRunningTotal+=u*(r?1:-1))},_getMeasurementString:function(){var n,r=this._currentLatLng,a=this._markers[this._markers.length-1].getLatLng();return n=L.GeometryUtil.isVersion07x()?a&&r&&r.distanceTo?this._measurementRunningTotal+r.distanceTo(a)*(this.options.factor||1):this._measurementRunningTotal||0:a&&r?this._measurementRunningTotal+this._map.distance(r,a)*(this.options.factor||1):this._measurementRunningTotal||0,L.GeometryUtil.readableDistance(n,this.options.metric,this.options.feet,this.options.nautic,this.options.precision)},_showErrorTooltip:function(){this._errorShown=!0,this._tooltip.showAsError().updateContent({text:this.options.drawError.message}),this._updateGuideColor(this.options.drawError.color),this._poly.setStyle({color:this.options.drawError.color}),this._clearHideErrorTimeout(),this._hideErrorTimeout=setTimeout(L.Util.bind(this._hideErrorTooltip,this),this.options.drawError.timeout)},_hideErrorTooltip:function(){this._errorShown=!1,this._clearHideErrorTimeout(),this._tooltip.removeError().updateContent(this._getTooltipText()),this._updateGuideColor(this.options.shapeOptions.color),this._poly.setStyle({color:this.options.shapeOptions.color})},_clearHideErrorTimeout:function(){this._hideErrorTimeout&&(clearTimeout(this._hideErrorTimeout),this._hideErrorTimeout=null)},_disableNewMarkers:function(){this._disableMarkers=!0},_enableNewMarkers:function(){setTimeout(function(){this._disableMarkers=!1}.bind(this),50)},_cleanUpShape:function(){this._markers.length>1&&this._markers[this._markers.length-1].off("click",this._finishShape,this)},_fireCreatedEvent:function(){var n=new this.Poly(this._poly.getLatLngs(),this.options.shapeOptions);L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)}}),L.Draw.Polygon=L.Draw.Polyline.extend({statics:{TYPE:"polygon"},Poly:L.Polygon,options:{showArea:!1,showLength:!1,shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},metric:!0,feet:!0,nautic:!1,precision:{}},initialize:function(n,r){L.Draw.Polyline.prototype.initialize.call(this,n,r),this.type=L.Draw.Polygon.TYPE},_updateFinishHandler:function(){var n=this._markers.length;n===1&&this._markers[0].on("click",this._finishShape,this),n>2&&(this._markers[n-1].on("dblclick",this._finishShape,this),n>3&&this._markers[n-2].off("dblclick",this._finishShape,this))},_getTooltipText:function(){var n,r;return this._markers.length===0?n=L.drawLocal.draw.handlers.polygon.tooltip.start:this._markers.length<3?(n=L.drawLocal.draw.handlers.polygon.tooltip.cont,r=this._getMeasurementString()):(n=L.drawLocal.draw.handlers.polygon.tooltip.end,r=this._getMeasurementString()),{text:n,subtext:r}},_getMeasurementString:function(){var n=this._area,r="";return n||this.options.showLength?(this.options.showLength&&(r=L.Draw.Polyline.prototype._getMeasurementString.call(this)),n&&(r+="<br>"+L.GeometryUtil.readableArea(n,this.options.metric,this.options.precision)),r):null},_shapeIsValid:function(){return this._markers.length>=3},_vertexChanged:function(n,r){var a;!this.options.allowIntersection&&this.options.showArea&&(a=this._poly.getLatLngs(),this._area=L.GeometryUtil.geodesicArea(a)),L.Draw.Polyline.prototype._vertexChanged.call(this,n,r)},_cleanUpShape:function(){var n=this._markers.length;n>0&&(this._markers[0].off("click",this._finishShape,this),n>2&&this._markers[n-1].off("dblclick",this._finishShape,this))}}),L.SimpleShape={},L.Draw.SimpleShape=L.Draw.Feature.extend({options:{repeatMode:!1},initialize:function(n,r){this._endLabelText=L.drawLocal.draw.handlers.simpleshape.tooltip.end,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._mapDraggable=this._map.dragging.enabled(),this._mapDraggable&&this._map.dragging.disable(),this._container.style.cursor="crosshair",this._tooltip.updateContent({text:this._initialLabelText}),this._map.on("mousedown",this._onMouseDown,this).on("mousemove",this._onMouseMove,this).on("touchstart",this._onMouseDown,this).on("touchmove",this._onMouseMove,this),h.addEventListener("touchstart",L.DomEvent.preventDefault,{passive:!1}))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._map&&(this._mapDraggable&&this._map.dragging.enable(),this._container.style.cursor="",this._map.off("mousedown",this._onMouseDown,this).off("mousemove",this._onMouseMove,this).off("touchstart",this._onMouseDown,this).off("touchmove",this._onMouseMove,this),L.DomEvent.off(h,"mouseup",this._onMouseUp,this),L.DomEvent.off(h,"touchend",this._onMouseUp,this),h.removeEventListener("touchstart",L.DomEvent.preventDefault),this._shape&&(this._map.removeLayer(this._shape),delete this._shape)),this._isDrawing=!1},_getTooltipText:function(){return{text:this._endLabelText}},_onMouseDown:function(n){this._isDrawing=!0,this._startLatLng=n.latlng,L.DomEvent.on(h,"mouseup",this._onMouseUp,this).on(h,"touchend",this._onMouseUp,this).preventDefault(n.originalEvent)},_onMouseMove:function(n){var r=n.latlng;this._tooltip.updatePosition(r),this._isDrawing&&(this._tooltip.updateContent(this._getTooltipText()),this._drawShape(r))},_onMouseUp:function(){this._shape&&this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()}}),L.Draw.Rectangle=L.Draw.SimpleShape.extend({statics:{TYPE:"rectangle"},options:{shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},showArea:!0,metric:!0},initialize:function(n,r){this.type=L.Draw.Rectangle.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.rectangle.tooltip.start,L.Draw.SimpleShape.prototype.initialize.call(this,n,r)},disable:function(){this._enabled&&(this._isCurrentlyTwoClickDrawing=!1,L.Draw.SimpleShape.prototype.disable.call(this))},_onMouseUp:function(n){if(!this._shape&&!this._isCurrentlyTwoClickDrawing)return void(this._isCurrentlyTwoClickDrawing=!0);this._isCurrentlyTwoClickDrawing&&!c(n.target,"leaflet-pane")||L.Draw.SimpleShape.prototype._onMouseUp.call(this)},_drawShape:function(n){this._shape?this._shape.setBounds(new L.LatLngBounds(this._startLatLng,n)):(this._shape=new L.Rectangle(new L.LatLngBounds(this._startLatLng,n),this.options.shapeOptions),this._map.addLayer(this._shape))},_fireCreatedEvent:function(){var n=new L.Rectangle(this._shape.getBounds(),this.options.shapeOptions);L.Draw.SimpleShape.prototype._fireCreatedEvent.call(this,n)},_getTooltipText:function(){var n,r,a,u=L.Draw.SimpleShape.prototype._getTooltipText.call(this),f=this._shape,_=this.options.showArea;return f&&(n=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),r=L.GeometryUtil.geodesicArea(n),a=_?L.GeometryUtil.readableArea(r,this.options.metric):""),{text:u.text,subtext:a}}}),L.Draw.Marker=L.Draw.Feature.extend({statics:{TYPE:"marker"},options:{icon:new L.Icon.Default,repeatMode:!1,zIndexOffset:2e3},initialize:function(n,r){this.type=L.Draw.Marker.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.marker.tooltip.start,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._tooltip.updateContent({text:this._initialLabelText}),this._mouseMarker||(this._mouseMarker=L.marker(this._map.getCenter(),{icon:L.divIcon({className:"leaflet-mouse-marker",iconAnchor:[20,20],iconSize:[40,40]}),opacity:0,zIndexOffset:this.options.zIndexOffset})),this._mouseMarker.on("click",this._onClick,this).addTo(this._map),this._map.on("mousemove",this._onMouseMove,this),this._map.on("click",this._onTouch,this))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._map&&(this._map.off("click",this._onClick,this).off("click",this._onTouch,this),this._marker&&(this._marker.off("click",this._onClick,this),this._map.removeLayer(this._marker),delete this._marker),this._mouseMarker.off("click",this._onClick,this),this._map.removeLayer(this._mouseMarker),delete this._mouseMarker,this._map.off("mousemove",this._onMouseMove,this))},_onMouseMove:function(n){var r=n.latlng;this._tooltip.updatePosition(r),this._mouseMarker.setLatLng(r),this._marker?(r=this._mouseMarker.getLatLng(),this._marker.setLatLng(r)):(this._marker=this._createMarker(r),this._marker.on("click",this._onClick,this),this._map.on("click",this._onClick,this).addLayer(this._marker))},_createMarker:function(n){return new L.Marker(n,{icon:this.options.icon,zIndexOffset:this.options.zIndexOffset})},_onClick:function(){this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()},_onTouch:function(n){this._onMouseMove(n),this._onClick()},_fireCreatedEvent:function(){var n=new L.Marker.Touch(this._marker.getLatLng(),{icon:this.options.icon});L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)}}),L.Draw.CircleMarker=L.Draw.Marker.extend({statics:{TYPE:"circlemarker"},options:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0,zIndexOffset:2e3},initialize:function(n,r){this.type=L.Draw.CircleMarker.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.circlemarker.tooltip.start,L.Draw.Feature.prototype.initialize.call(this,n,r)},_fireCreatedEvent:function(){var n=new L.CircleMarker(this._marker.getLatLng(),this.options);L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)},_createMarker:function(n){return new L.CircleMarker(n,this.options)}}),L.Draw.Circle=L.Draw.SimpleShape.extend({statics:{TYPE:"circle"},options:{shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},showRadius:!0,metric:!0,feet:!0,nautic:!1},initialize:function(n,r){this.type=L.Draw.Circle.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.circle.tooltip.start,L.Draw.SimpleShape.prototype.initialize.call(this,n,r)},_drawShape:function(n){if(L.GeometryUtil.isVersion07x())var r=this._startLatLng.distanceTo(n);else var r=this._map.distance(this._startLatLng,n);this._shape?this._shape.setRadius(r):(this._shape=new L.Circle(this._startLatLng,r,this.options.shapeOptions),this._map.addLayer(this._shape))},_fireCreatedEvent:function(){var n=new L.Circle(this._startLatLng,this._shape.getRadius(),this.options.shapeOptions);L.Draw.SimpleShape.prototype._fireCreatedEvent.call(this,n)},_onMouseMove:function(n){var r,a=n.latlng,u=this.options.showRadius,f=this.options.metric;if(this._tooltip.updatePosition(a),this._isDrawing){this._drawShape(a),r=this._shape.getRadius().toFixed(1);var _="";u&&(_=L.drawLocal.draw.handlers.circle.radius+": "+L.GeometryUtil.readableDistance(r,f,this.options.feet,this.options.nautic)),this._tooltip.updateContent({text:this._endLabelText,subtext:_})}}}),L.Edit=L.Edit||{},L.Edit.Marker=L.Handler.extend({initialize:function(n,r){this._marker=n,L.setOptions(this,r)},addHooks:function(){var n=this._marker;n.dragging.enable(),n.on("dragend",this._onDragEnd,n),this._toggleMarkerHighlight()},removeHooks:function(){var n=this._marker;n.dragging.disable(),n.off("dragend",this._onDragEnd,n),this._toggleMarkerHighlight()},_onDragEnd:function(n){var r=n.target;r.edited=!0,this._map.fire(L.Draw.Event.EDITMOVE,{layer:r})},_toggleMarkerHighlight:function(){var n=this._marker._icon;n&&(n.style.display="none",L.DomUtil.hasClass(n,"leaflet-edit-marker-selected")?(L.DomUtil.removeClass(n,"leaflet-edit-marker-selected"),this._offsetMarker(n,-4)):(L.DomUtil.addClass(n,"leaflet-edit-marker-selected"),this._offsetMarker(n,4)),n.style.display="")},_offsetMarker:function(n,r){var a=parseInt(n.style.marginTop,10)-r,u=parseInt(n.style.marginLeft,10)-r;n.style.marginTop=a+"px",n.style.marginLeft=u+"px"}}),L.Marker.addInitHook(function(){L.Edit.Marker&&(this.editing=new L.Edit.Marker(this),this.options.editable&&this.editing.enable())}),L.Edit=L.Edit||{},L.Edit.Poly=L.Handler.extend({initialize:function(n){this.latlngs=[n._latlngs],n._holes&&(this.latlngs=this.latlngs.concat(n._holes)),this._poly=n,this._poly.on("revert-edited",this._updateLatLngs,this)},_defaultShape:function(){return L.Polyline._flat?L.Polyline._flat(this._poly._latlngs)?this._poly._latlngs:this._poly._latlngs[0]:this._poly._latlngs},_eachVertexHandler:function(n){for(var r=0;r<this._verticesHandlers.length;r++)n(this._verticesHandlers[r])},addHooks:function(){this._initHandlers(),this._eachVertexHandler(function(n){n.addHooks()})},removeHooks:function(){this._eachVertexHandler(function(n){n.removeHooks()})},updateMarkers:function(){this._eachVertexHandler(function(n){n.updateMarkers()})},_initHandlers:function(){this._verticesHandlers=[];for(var n=0;n<this.latlngs.length;n++)this._verticesHandlers.push(new L.Edit.PolyVerticesEdit(this._poly,this.latlngs[n],this._poly.options.poly))},_updateLatLngs:function(n){this.latlngs=[n.layer._latlngs],n.layer._holes&&(this.latlngs=this.latlngs.concat(n.layer._holes))}}),L.Edit.PolyVerticesEdit=L.Handler.extend({options:{icon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon"}),touchIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-touch-icon"}),drawError:{color:"#b00b00",timeout:1e3}},initialize:function(n,r,a){L.Browser.touch&&(this.options.icon=this.options.touchIcon),this._poly=n,a&&a.drawError&&(a.drawError=L.Util.extend({},this.options.drawError,a.drawError)),this._latlngs=r,L.setOptions(this,a)},_defaultShape:function(){return L.Polyline._flat?L.Polyline._flat(this._latlngs)?this._latlngs:this._latlngs[0]:this._latlngs},addHooks:function(){var n=this._poly,r=n._path;n instanceof L.Polygon||(n.options.fill=!1,n.options.editing&&(n.options.editing.fill=!1)),r&&n.options.editing&&n.options.editing.className&&(n.options.original.className&&n.options.original.className.split(" ").forEach(function(a){L.DomUtil.removeClass(r,a)}),n.options.editing.className.split(" ").forEach(function(a){L.DomUtil.addClass(r,a)})),n.setStyle(n.options.editing),this._poly._map&&(this._map=this._poly._map,this._markerGroup||this._initMarkers(),this._poly._map.addLayer(this._markerGroup))},removeHooks:function(){var n=this._poly,r=n._path;r&&n.options.editing&&n.options.editing.className&&(n.options.editing.className.split(" ").forEach(function(a){L.DomUtil.removeClass(r,a)}),n.options.original.className&&n.options.original.className.split(" ").forEach(function(a){L.DomUtil.addClass(r,a)})),n.setStyle(n.options.original),n._map&&(n._map.removeLayer(this._markerGroup),delete this._markerGroup,delete this._markers)},updateMarkers:function(){this._markerGroup.clearLayers(),this._initMarkers()},_initMarkers:function(){this._markerGroup||(this._markerGroup=new L.LayerGroup),this._markers=[];var n,r,a,u,f=this._defaultShape();for(n=0,a=f.length;n<a;n++)u=this._createMarker(f[n],n),u.on("click",this._onMarkerClick,this),u.on("contextmenu",this._onContextMenu,this),this._markers.push(u);var _,m;for(n=0,r=a-1;n<a;r=n++)(n!==0||L.Polygon&&this._poly instanceof L.Polygon)&&(_=this._markers[r],m=this._markers[n],this._createMiddleMarker(_,m),this._updatePrevNext(_,m))},_createMarker:function(n,r){var a=new L.Marker.Touch(n,{draggable:!0,icon:this.options.icon});return a._origLatLng=n,a._index=r,a.on("dragstart",this._onMarkerDragStart,this).on("drag",this._onMarkerDrag,this).on("dragend",this._fireEdit,this).on("touchmove",this._onTouchMove,this).on("touchend",this._fireEdit,this).on("MSPointerMove",this._onTouchMove,this).on("MSPointerUp",this._fireEdit,this),this._markerGroup.addLayer(a),a},_onMarkerDragStart:function(){this._poly.fire("editstart")},_spliceLatLngs:function(){var n=this._defaultShape(),r=[].splice.apply(n,arguments);return this._poly._convertLatLngs(n,!0),this._poly.redraw(),r},_removeMarker:function(n){var r=n._index;this._markerGroup.removeLayer(n),this._markers.splice(r,1),this._spliceLatLngs(r,1),this._updateIndexes(r,-1),n.off("dragstart",this._onMarkerDragStart,this).off("drag",this._onMarkerDrag,this).off("dragend",this._fireEdit,this).off("touchmove",this._onMarkerDrag,this).off("touchend",this._fireEdit,this).off("click",this._onMarkerClick,this).off("MSPointerMove",this._onTouchMove,this).off("MSPointerUp",this._fireEdit,this)},_fireEdit:function(){this._poly.edited=!0,this._poly.fire("edit"),this._poly._map.fire(L.Draw.Event.EDITVERTEX,{layers:this._markerGroup,poly:this._poly})},_onMarkerDrag:function(n){var r=n.target,a=this._poly,u=L.LatLngUtil.cloneLatLng(r._origLatLng);if(L.extend(r._origLatLng,r._latlng),a.options.poly){var f=a._map._editTooltip;if(!a.options.poly.allowIntersection&&a.intersects()){L.extend(r._origLatLng,u),r.setLatLng(u);var _=a.options.color;a.setStyle({color:this.options.drawError.color}),f&&f.updateContent({text:L.drawLocal.draw.handlers.polyline.error}),setTimeout(function(){a.setStyle({color:_}),f&&f.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext})},1e3)}}r._middleLeft&&r._middleLeft.setLatLng(this._getMiddleLatLng(r._prev,r)),r._middleRight&&r._middleRight.setLatLng(this._getMiddleLatLng(r,r._next)),this._poly._bounds._southWest=L.latLng(1/0,1/0),this._poly._bounds._northEast=L.latLng(-1/0,-1/0);var m=this._poly.getLatLngs();this._poly._convertLatLngs(m,!0),this._poly.redraw(),this._poly.fire("editdrag")},_onMarkerClick:function(n){var r=L.Polygon&&this._poly instanceof L.Polygon?4:3,a=n.target;this._defaultShape().length<r||(this._removeMarker(a),this._updatePrevNext(a._prev,a._next),a._middleLeft&&this._markerGroup.removeLayer(a._middleLeft),a._middleRight&&this._markerGroup.removeLayer(a._middleRight),a._prev&&a._next?this._createMiddleMarker(a._prev,a._next):a._prev?a._next||(a._prev._middleRight=null):a._next._middleLeft=null,this._fireEdit())},_onContextMenu:function(n){var r=n.target;this._poly,this._poly._map.fire(L.Draw.Event.MARKERCONTEXT,{marker:r,layers:this._markerGroup,poly:this._poly}),L.DomEvent.stopPropagation},_onTouchMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent.touches[0]),a=this._map.layerPointToLatLng(r),u=n.target;L.extend(u._origLatLng,a),u._middleLeft&&u._middleLeft.setLatLng(this._getMiddleLatLng(u._prev,u)),u._middleRight&&u._middleRight.setLatLng(this._getMiddleLatLng(u,u._next)),this._poly.redraw(),this.updateMarkers()},_updateIndexes:function(n,r){this._markerGroup.eachLayer(function(a){a._index>n&&(a._index+=r)})},_createMiddleMarker:function(n,r){var a,u,f,_=this._getMiddleLatLng(n,r),m=this._createMarker(_);m.setOpacity(.6),n._middleRight=r._middleLeft=m,u=function(){m.off("touchmove",u,this);var w=r._index;m._index=w,m.off("click",a,this).on("click",this._onMarkerClick,this),_.lat=m.getLatLng().lat,_.lng=m.getLatLng().lng,this._spliceLatLngs(w,0,_),this._markers.splice(w,0,m),m.setOpacity(1),this._updateIndexes(w,1),r._index++,this._updatePrevNext(n,m),this._updatePrevNext(m,r),this._poly.fire("editstart")},f=function(){m.off("dragstart",u,this),m.off("dragend",f,this),m.off("touchmove",u,this),this._createMiddleMarker(n,m),this._createMiddleMarker(m,r)},a=function(){u.call(this),f.call(this),this._fireEdit()},m.on("click",a,this).on("dragstart",u,this).on("dragend",f,this).on("touchmove",u,this),this._markerGroup.addLayer(m)},_updatePrevNext:function(n,r){n&&(n._next=r),r&&(r._prev=n)},_getMiddleLatLng:function(n,r){var a=this._poly._map,u=a.project(n.getLatLng()),f=a.project(r.getLatLng());return a.unproject(u._add(f)._divideBy(2))}}),L.Polyline.addInitHook(function(){this.editing||(L.Edit.Poly&&(this.editing=new L.Edit.Poly(this),this.options.editable&&this.editing.enable()),this.on("add",function(){this.editing&&this.editing.enabled()&&this.editing.addHooks()}),this.on("remove",function(){this.editing&&this.editing.enabled()&&this.editing.removeHooks()}))}),L.Edit=L.Edit||{},L.Edit.SimpleShape=L.Handler.extend({options:{moveIcon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-move"}),resizeIcon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-resize"}),touchMoveIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-move leaflet-touch-icon"}),touchResizeIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-resize leaflet-touch-icon"})},initialize:function(n,r){L.Browser.touch&&(this.options.moveIcon=this.options.touchMoveIcon,this.options.resizeIcon=this.options.touchResizeIcon),this._shape=n,L.Util.setOptions(this,r)},addHooks:function(){var n=this._shape;this._shape._map&&(this._map=this._shape._map,n.setStyle(n.options.editing),n._map&&(this._map=n._map,this._markerGroup||this._initMarkers(),this._map.addLayer(this._markerGroup)))},removeHooks:function(){var n=this._shape;if(n.setStyle(n.options.original),n._map){this._unbindMarker(this._moveMarker);for(var r=0,a=this._resizeMarkers.length;r<a;r++)this._unbindMarker(this._resizeMarkers[r]);this._resizeMarkers=null,this._map.removeLayer(this._markerGroup),delete this._markerGroup}this._map=null},updateMarkers:function(){this._markerGroup.clearLayers(),this._initMarkers()},_initMarkers:function(){this._markerGroup||(this._markerGroup=new L.LayerGroup),this._createMoveMarker(),this._createResizeMarker()},_createMoveMarker:function(){},_createResizeMarker:function(){},_createMarker:function(n,r){var a=new L.Marker.Touch(n,{draggable:!0,icon:r,zIndexOffset:10});return this._bindMarker(a),this._markerGroup.addLayer(a),a},_bindMarker:function(n){n.on("dragstart",this._onMarkerDragStart,this).on("drag",this._onMarkerDrag,this).on("dragend",this._onMarkerDragEnd,this).on("touchstart",this._onTouchStart,this).on("touchmove",this._onTouchMove,this).on("MSPointerMove",this._onTouchMove,this).on("touchend",this._onTouchEnd,this).on("MSPointerUp",this._onTouchEnd,this)},_unbindMarker:function(n){n.off("dragstart",this._onMarkerDragStart,this).off("drag",this._onMarkerDrag,this).off("dragend",this._onMarkerDragEnd,this).off("touchstart",this._onTouchStart,this).off("touchmove",this._onTouchMove,this).off("MSPointerMove",this._onTouchMove,this).off("touchend",this._onTouchEnd,this).off("MSPointerUp",this._onTouchEnd,this)},_onMarkerDragStart:function(n){n.target.setOpacity(0),this._shape.fire("editstart")},_fireEdit:function(){this._shape.edited=!0,this._shape.fire("edit")},_onMarkerDrag:function(n){var r=n.target,a=r.getLatLng();r===this._moveMarker?this._move(a):this._resize(a),this._shape.redraw(),this._shape.fire("editdrag")},_onMarkerDragEnd:function(n){n.target.setOpacity(1),this._fireEdit()},_onTouchStart:function(n){if(L.Edit.SimpleShape.prototype._onMarkerDragStart.call(this,n),typeof this._getCorners=="function"){var r=this._getCorners(),a=n.target,u=a._cornerIndex;a.setOpacity(0),this._oppositeCorner=r[(u+2)%4],this._toggleCornerMarkers(0,u)}this._shape.fire("editstart")},_onTouchMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent.touches[0]),a=this._map.layerPointToLatLng(r);return n.target===this._moveMarker?this._move(a):this._resize(a),this._shape.redraw(),!1},_onTouchEnd:function(n){n.target.setOpacity(1),this.updateMarkers(),this._fireEdit()},_move:function(){},_resize:function(){}}),L.Edit=L.Edit||{},L.Edit.Rectangle=L.Edit.SimpleShape.extend({_createMoveMarker:function(){var n=this._shape.getBounds(),r=n.getCenter();this._moveMarker=this._createMarker(r,this.options.moveIcon)},_createResizeMarker:function(){var n=this._getCorners();this._resizeMarkers=[];for(var r=0,a=n.length;r<a;r++)this._resizeMarkers.push(this._createMarker(n[r],this.options.resizeIcon)),this._resizeMarkers[r]._cornerIndex=r},_onMarkerDragStart:function(n){L.Edit.SimpleShape.prototype._onMarkerDragStart.call(this,n);var r=this._getCorners(),a=n.target,u=a._cornerIndex;this._oppositeCorner=r[(u+2)%4],this._toggleCornerMarkers(0,u)},_onMarkerDragEnd:function(n){var r,a,u=n.target;u===this._moveMarker&&(r=this._shape.getBounds(),a=r.getCenter(),u.setLatLng(a)),this._toggleCornerMarkers(1),this._repositionCornerMarkers(),L.Edit.SimpleShape.prototype._onMarkerDragEnd.call(this,n)},_move:function(n){for(var r,a=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),u=this._shape.getBounds(),f=u.getCenter(),_=[],m=0,w=a.length;m<w;m++)r=[a[m].lat-f.lat,a[m].lng-f.lng],_.push([n.lat+r[0],n.lng+r[1]]);this._shape.setLatLngs(_),this._repositionCornerMarkers(),this._map.fire(L.Draw.Event.EDITMOVE,{layer:this._shape})},_resize:function(n){var r;this._shape.setBounds(L.latLngBounds(n,this._oppositeCorner)),r=this._shape.getBounds(),this._moveMarker.setLatLng(r.getCenter()),this._map.fire(L.Draw.Event.EDITRESIZE,{layer:this._shape})},_getCorners:function(){var n=this._shape.getBounds();return[n.getNorthWest(),n.getNorthEast(),n.getSouthEast(),n.getSouthWest()]},_toggleCornerMarkers:function(n){for(var r=0,a=this._resizeMarkers.length;r<a;r++)this._resizeMarkers[r].setOpacity(n)},_repositionCornerMarkers:function(){for(var n=this._getCorners(),r=0,a=this._resizeMarkers.length;r<a;r++)this._resizeMarkers[r].setLatLng(n[r])}}),L.Rectangle.addInitHook(function(){L.Edit.Rectangle&&(this.editing=new L.Edit.Rectangle(this),this.options.editable&&this.editing.enable())}),L.Edit=L.Edit||{},L.Edit.CircleMarker=L.Edit.SimpleShape.extend({_createMoveMarker:function(){var n=this._shape.getLatLng();this._moveMarker=this._createMarker(n,this.options.moveIcon)},_createResizeMarker:function(){this._resizeMarkers=[]},_move:function(n){if(this._resizeMarkers.length){var r=this._getResizeMarkerPoint(n);this._resizeMarkers[0].setLatLng(r)}this._shape.setLatLng(n),this._map.fire(L.Draw.Event.EDITMOVE,{layer:this._shape})}}),L.CircleMarker.addInitHook(function(){L.Edit.CircleMarker&&(this.editing=new L.Edit.CircleMarker(this),this.options.editable&&this.editing.enable()),this.on("add",function(){this.editing&&this.editing.enabled()&&this.editing.addHooks()}),this.on("remove",function(){this.editing&&this.editing.enabled()&&this.editing.removeHooks()})}),L.Edit=L.Edit||{},L.Edit.Circle=L.Edit.CircleMarker.extend({_createResizeMarker:function(){var n=this._shape.getLatLng(),r=this._getResizeMarkerPoint(n);this._resizeMarkers=[],this._resizeMarkers.push(this._createMarker(r,this.options.resizeIcon))},_getResizeMarkerPoint:function(n){var r=this._shape._radius*Math.cos(Math.PI/4),a=this._map.project(n);return this._map.unproject([a.x+r,a.y-r])},_resize:function(n){var r=this._moveMarker.getLatLng();L.GeometryUtil.isVersion07x()?radius=r.distanceTo(n):radius=this._map.distance(r,n),this._shape.setRadius(radius),this._map.editTooltip&&this._map._editTooltip.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.subtext+"<br />"+L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.draw.handlers.circle.radius+": "+L.GeometryUtil.readableDistance(radius,!0,this.options.feet,this.options.nautic)}),this._shape.setRadius(radius),this._map.fire(L.Draw.Event.EDITRESIZE,{layer:this._shape})}}),L.Circle.addInitHook(function(){L.Edit.Circle&&(this.editing=new L.Edit.Circle(this),this.options.editable&&this.editing.enable())}),L.Map.mergeOptions({touchExtend:!0}),L.Map.TouchExtend=L.Handler.extend({initialize:function(n){this._map=n,this._container=n._container,this._pane=n._panes.overlayPane},addHooks:function(){L.DomEvent.on(this._container,"touchstart",this._onTouchStart,this),L.DomEvent.on(this._container,"touchend",this._onTouchEnd,this),L.DomEvent.on(this._container,"touchmove",this._onTouchMove,this),this._detectIE()?(L.DomEvent.on(this._container,"MSPointerDown",this._onTouchStart,this),L.DomEvent.on(this._container,"MSPointerUp",this._onTouchEnd,this),L.DomEvent.on(this._container,"MSPointerMove",this._onTouchMove,this),L.DomEvent.on(this._container,"MSPointerCancel",this._onTouchCancel,this)):(L.DomEvent.on(this._container,"touchcancel",this._onTouchCancel,this),L.DomEvent.on(this._container,"touchleave",this._onTouchLeave,this))},removeHooks:function(){L.DomEvent.off(this._container,"touchstart",this._onTouchStart,this),L.DomEvent.off(this._container,"touchend",this._onTouchEnd,this),L.DomEvent.off(this._container,"touchmove",this._onTouchMove,this),this._detectIE()?(L.DomEvent.off(this._container,"MSPointerDown",this._onTouchStart,this),L.DomEvent.off(this._container,"MSPointerUp",this._onTouchEnd,this),L.DomEvent.off(this._container,"MSPointerMove",this._onTouchMove,this),L.DomEvent.off(this._container,"MSPointerCancel",this._onTouchCancel,this)):(L.DomEvent.off(this._container,"touchcancel",this._onTouchCancel,this),L.DomEvent.off(this._container,"touchleave",this._onTouchLeave,this))},_touchEvent:function(n,r){var a={};if(n.touches!==void 0){if(!n.touches.length)return;a=n.touches[0]}else if(n.pointerType!=="touch"||(a=n,!this._filterClick(n)))return;var u=this._map.mouseEventToContainerPoint(a),f=this._map.mouseEventToLayerPoint(a),_=this._map.layerPointToLatLng(f);this._map.fire(r,{latlng:_,layerPoint:f,containerPoint:u,pageX:a.pageX,pageY:a.pageY,originalEvent:n})},_filterClick:function(n){var r=n.timeStamp||n.originalEvent.timeStamp,a=L.DomEvent._lastClick&&r-L.DomEvent._lastClick;return a&&a>100&&a<500||n.target._simulatedClick&&!n._simulated?(L.DomEvent.stop(n),!1):(L.DomEvent._lastClick=r,!0)},_onTouchStart:function(n){this._map._loaded&&this._touchEvent(n,"touchstart")},_onTouchEnd:function(n){this._map._loaded&&this._touchEvent(n,"touchend")},_onTouchCancel:function(n){if(this._map._loaded){var r="touchcancel";this._detectIE()&&(r="pointercancel"),this._touchEvent(n,r)}},_onTouchLeave:function(n){this._map._loaded&&this._touchEvent(n,"touchleave")},_onTouchMove:function(n){this._map._loaded&&this._touchEvent(n,"touchmove")},_detectIE:function(){var n=g.navigator.userAgent,r=n.indexOf("MSIE ");if(r>0)return parseInt(n.substring(r+5,n.indexOf(".",r)),10);if(n.indexOf("Trident/")>0){var a=n.indexOf("rv:");return parseInt(n.substring(a+3,n.indexOf(".",a)),10)}var u=n.indexOf("Edge/");return u>0&&parseInt(n.substring(u+5,n.indexOf(".",u)),10)}}),L.Map.addInitHook("addHandler","touchExtend",L.Map.TouchExtend),L.Marker.Touch=L.Marker.extend({_initInteraction:function(){return this.addInteractiveTarget?L.Marker.prototype._initInteraction.apply(this):this._initInteractionLegacy()},_initInteractionLegacy:function(){if(this.options.clickable){var n=this._icon,r=["dblclick","mousedown","mouseover","mouseout","contextmenu","touchstart","touchend","touchmove"];this._detectIE?r.concat(["MSPointerDown","MSPointerUp","MSPointerMove","MSPointerCancel"]):r.concat(["touchcancel"]),L.DomUtil.addClass(n,"leaflet-clickable"),L.DomEvent.on(n,"click",this._onMouseClick,this),L.DomEvent.on(n,"keypress",this._onKeyPress,this);for(var a=0;a<r.length;a++)L.DomEvent.on(n,r[a],this._fireMouseEvent,this);L.Handler.MarkerDrag&&(this.dragging=new L.Handler.MarkerDrag(this),this.options.draggable&&this.dragging.enable())}},_detectIE:function(){var n=g.navigator.userAgent,r=n.indexOf("MSIE ");if(r>0)return parseInt(n.substring(r+5,n.indexOf(".",r)),10);if(n.indexOf("Trident/")>0){var a=n.indexOf("rv:");return parseInt(n.substring(a+3,n.indexOf(".",a)),10)}var u=n.indexOf("Edge/");return u>0&&parseInt(n.substring(u+5,n.indexOf(".",u)),10)}}),L.LatLngUtil={cloneLatLngs:function(n){for(var r=[],a=0,u=n.length;a<u;a++)Array.isArray(n[a])?r.push(L.LatLngUtil.cloneLatLngs(n[a])):r.push(this.cloneLatLng(n[a]));return r},cloneLatLng:function(n){return L.latLng(n.lat,n.lng)}},(function(){var n={km:2,ha:2,m:0,mi:2,ac:2,yd:0,ft:0,nm:2};L.GeometryUtil=L.extend(L.GeometryUtil||{},{geodesicArea:function(r){var a,u,f=r.length,_=0,m=Math.PI/180;if(f>2){for(var w=0;w<f;w++)a=r[w],u=r[(w+1)%f],_+=(u.lng-a.lng)*m*(2+Math.sin(a.lat*m)+Math.sin(u.lat*m));_=6378137*_*6378137/2}return Math.abs(_)},formattedNumber:function(r,a){var u=parseFloat(r).toFixed(a),f=L.drawLocal.format&&L.drawLocal.format.numeric,_=f&&f.delimiters,m=_&&_.thousands,w=_&&_.decimal;if(m||w){var x=u.split(".");u=m?x[0].replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+m):x[0],w=w||".",x.length>1&&(u=u+w+x[1])}return u},readableArea:function(r,a,m){var f,_,m=L.Util.extend({},n,m);return a?(_=["ha","m"],type=typeof a,type==="string"?_=[a]:type!=="boolean"&&(_=a),f=r>=1e6&&_.indexOf("km")!==-1?L.GeometryUtil.formattedNumber(1e-6*r,m.km)+" km²":r>=1e4&&_.indexOf("ha")!==-1?L.GeometryUtil.formattedNumber(1e-4*r,m.ha)+" ha":L.GeometryUtil.formattedNumber(r,m.m)+" m²"):(r/=.836127,f=r>=3097600?L.GeometryUtil.formattedNumber(r/3097600,m.mi)+" mi²":r>=4840?L.GeometryUtil.formattedNumber(r/4840,m.ac)+" acres":L.GeometryUtil.formattedNumber(r,m.yd)+" yd²"),f},readableDistance:function(r,a,u,f,w){var m,w=L.Util.extend({},n,w);switch(a?typeof a=="string"?a:"metric":u?"feet":f?"nauticalMile":"yards"){case"metric":m=r>1e3?L.GeometryUtil.formattedNumber(r/1e3,w.km)+" km":L.GeometryUtil.formattedNumber(r,w.m)+" m";break;case"feet":r*=3.28083,m=L.GeometryUtil.formattedNumber(r,w.ft)+" ft";break;case"nauticalMile":r*=.53996,m=L.GeometryUtil.formattedNumber(r/1e3,w.nm)+" nm";break;case"yards":default:r*=1.09361,m=r>1760?L.GeometryUtil.formattedNumber(r/1760,w.mi)+" miles":L.GeometryUtil.formattedNumber(r,w.yd)+" yd"}return m},isVersion07x:function(){var r=L.version.split(".");return parseInt(r[0],10)===0&&parseInt(r[1],10)===7}})})(),L.Util.extend(L.LineUtil,{segmentsIntersect:function(n,r,a,u){return this._checkCounterclockwise(n,a,u)!==this._checkCounterclockwise(r,a,u)&&this._checkCounterclockwise(n,r,a)!==this._checkCounterclockwise(n,r,u)},_checkCounterclockwise:function(n,r,a){return(a.y-n.y)*(r.x-n.x)>(r.y-n.y)*(a.x-n.x)}}),L.Polyline.include({intersects:function(){var n,r,a,u=this._getProjectedPoints(),f=u?u.length:0;if(this._tooFewPointsForIntersection())return!1;for(n=f-1;n>=3;n--)if(r=u[n-1],a=u[n],this._lineSegmentsIntersectsRange(r,a,n-2))return!0;return!1},newLatLngIntersects:function(n,r){return!!this._map&&this.newPointIntersects(this._map.latLngToLayerPoint(n),r)},newPointIntersects:function(n,r){var a=this._getProjectedPoints(),u=a?a.length:0,f=a?a[u-1]:null,_=u-2;return!this._tooFewPointsForIntersection(1)&&this._lineSegmentsIntersectsRange(f,n,_,r?1:0)},_tooFewPointsForIntersection:function(n){var r=this._getProjectedPoints(),a=r?r.length:0;return a+=n||0,!r||a<=3},_lineSegmentsIntersectsRange:function(n,r,a,u){var f,_,m=this._getProjectedPoints();u=u||0;for(var w=a;w>u;w--)if(f=m[w-1],_=m[w],L.LineUtil.segmentsIntersect(n,r,f,_))return!0;return!1},_getProjectedPoints:function(){if(!this._defaultShape)return this._originalPoints;for(var n=[],r=this._defaultShape(),a=0;a<r.length;a++)n.push(this._map.latLngToLayerPoint(r[a]));return n}}),L.Polygon.include({intersects:function(){var n,r,a,u,f=this._getProjectedPoints();return!this._tooFewPointsForIntersection()&&(!!L.Polyline.prototype.intersects.call(this)||(n=f.length,r=f[0],a=f[n-1],u=n-2,this._lineSegmentsIntersectsRange(a,r,u,1)))}}),L.Control.Draw=L.Control.extend({options:{position:"topleft",draw:{},edit:!1},initialize:function(n){if(L.version<"0.7")throw new Error("Leaflet.draw 0.2.3+ requires Leaflet 0.7.0+. Download latest from https://github.com/Leaflet/Leaflet/");L.Control.prototype.initialize.call(this,n);var r;this._toolbars={},L.DrawToolbar&&this.options.draw&&(r=new L.DrawToolbar(this.options.draw),this._toolbars[L.DrawToolbar.TYPE]=r,this._toolbars[L.DrawToolbar.TYPE].on("enable",this._toolbarEnabled,this)),L.EditToolbar&&this.options.edit&&(r=new L.EditToolbar(this.options.edit),this._toolbars[L.EditToolbar.TYPE]=r,this._toolbars[L.EditToolbar.TYPE].on("enable",this._toolbarEnabled,this)),L.toolbar=this},onAdd:function(n){var r,a=L.DomUtil.create("div","leaflet-draw"),u=!1;for(var f in this._toolbars)this._toolbars.hasOwnProperty(f)&&(r=this._toolbars[f].addToolbar(n))&&(u||(L.DomUtil.hasClass(r,"leaflet-draw-toolbar-top")||L.DomUtil.addClass(r.childNodes[0],"leaflet-draw-toolbar-top"),u=!0),a.appendChild(r));return a},onRemove:function(){for(var n in this._toolbars)this._toolbars.hasOwnProperty(n)&&this._toolbars[n].removeToolbar()},setDrawingOptions:function(n){for(var r in this._toolbars)this._toolbars[r]instanceof L.DrawToolbar&&this._toolbars[r].setOptions(n)},_toolbarEnabled:function(n){var r=n.target;for(var a in this._toolbars)this._toolbars[a]!==r&&this._toolbars[a].disable()}}),L.Map.mergeOptions({drawControlTooltips:!0,drawControl:!1}),L.Map.addInitHook(function(){this.options.drawControl&&(this.drawControl=new L.Control.Draw,this.addControl(this.drawControl))}),L.Toolbar=L.Class.extend({initialize:function(n){L.setOptions(this,n),this._modes={},this._actionButtons=[],this._activeMode=null;var r=L.version.split(".");parseInt(r[0],10)===1&&parseInt(r[1],10)>=2?L.Toolbar.include(L.Evented.prototype):L.Toolbar.include(L.Mixin.Events)},enabled:function(){return this._activeMode!==null},disable:function(){this.enabled()&&this._activeMode.handler.disable()},addToolbar:function(n){var r,a=L.DomUtil.create("div","leaflet-draw-section"),u=0,f=this._toolbarClass||"",_=this.getModeHandlers(n);for(this._toolbarContainer=L.DomUtil.create("div","leaflet-draw-toolbar leaflet-bar"),this._map=n,r=0;r<_.length;r++)_[r].enabled&&this._initModeHandler(_[r].handler,this._toolbarContainer,u++,f,_[r].title);if(u)return this._lastButtonIndex=--u,this._actionsContainer=L.DomUtil.create("ul","leaflet-draw-actions"),a.appendChild(this._toolbarContainer),a.appendChild(this._actionsContainer),a},removeToolbar:function(){for(var n in this._modes)this._modes.hasOwnProperty(n)&&(this._disposeButton(this._modes[n].button,this._modes[n].handler.enable,this._modes[n].handler),this._modes[n].handler.disable(),this._modes[n].handler.off("enabled",this._handlerActivated,this).off("disabled",this._handlerDeactivated,this));this._modes={};for(var r=0,a=this._actionButtons.length;r<a;r++)this._disposeButton(this._actionButtons[r].button,this._actionButtons[r].callback,this);this._actionButtons=[],this._actionsContainer=null},_initModeHandler:function(n,r,a,u,f){var _=n.type;this._modes[_]={},this._modes[_].handler=n,this._modes[_].button=this._createButton({type:_,title:f,className:u+"-"+_,container:r,callback:this._modes[_].handler.enable,context:this._modes[_].handler}),this._modes[_].buttonIndex=a,this._modes[_].handler.on("enabled",this._handlerActivated,this).on("disabled",this._handlerDeactivated,this)},_detectIOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!g.MSStream},_createButton:function(n){var r=L.DomUtil.create("a",n.className||"",n.container),a=L.DomUtil.create("span","sr-only",n.container);r.href="#",r.appendChild(a),n.title&&(r.title=n.title,a.innerHTML=n.title),n.text&&(r.innerHTML=n.text,a.innerHTML=n.text);var u=this._detectIOS()?"touchstart":"click";return L.DomEvent.on(r,"click",L.DomEvent.stopPropagation).on(r,"mousedown",L.DomEvent.stopPropagation).on(r,"dblclick",L.DomEvent.stopPropagation).on(r,"touchstart",L.DomEvent.stopPropagation).on(r,"click",L.DomEvent.preventDefault).on(r,u,n.callback,n.context),r},_disposeButton:function(n,r){var a=this._detectIOS()?"touchstart":"click";L.DomEvent.off(n,"click",L.DomEvent.stopPropagation).off(n,"mousedown",L.DomEvent.stopPropagation).off(n,"dblclick",L.DomEvent.stopPropagation).off(n,"touchstart",L.DomEvent.stopPropagation).off(n,"click",L.DomEvent.preventDefault).off(n,a,r)},_handlerActivated:function(n){this.disable(),this._activeMode=this._modes[n.handler],L.DomUtil.addClass(this._activeMode.button,"leaflet-draw-toolbar-button-enabled"),this._showActionsToolbar(),this.fire("enable")},_handlerDeactivated:function(){this._hideActionsToolbar(),L.DomUtil.removeClass(this._activeMode.button,"leaflet-draw-toolbar-button-enabled"),this._activeMode=null,this.fire("disable")},_createActions:function(n){var r,a,u,f,_=this._actionsContainer,m=this.getActions(n),w=m.length;for(a=0,u=this._actionButtons.length;a<u;a++)this._disposeButton(this._actionButtons[a].button,this._actionButtons[a].callback);for(this._actionButtons=[];_.firstChild;)_.removeChild(_.firstChild);for(var x=0;x<w;x++)"enabled"in m[x]&&!m[x].enabled||(r=L.DomUtil.create("li","",_),f=this._createButton({title:m[x].title,text:m[x].text,container:r,callback:m[x].callback,context:m[x].context}),this._actionButtons.push({button:f,callback:m[x].callback}))},_showActionsToolbar:function(){var n=this._activeMode.buttonIndex,r=this._lastButtonIndex,a=this._activeMode.button.offsetTop-1;this._createActions(this._activeMode.handler),this._actionsContainer.style.top=a+"px",n===0&&(L.DomUtil.addClass(this._toolbarContainer,"leaflet-draw-toolbar-notop"),L.DomUtil.addClass(this._actionsContainer,"leaflet-draw-actions-top")),n===r&&(L.DomUtil.addClass(this._toolbarContainer,"leaflet-draw-toolbar-nobottom"),L.DomUtil.addClass(this._actionsContainer,"leaflet-draw-actions-bottom")),this._actionsContainer.style.display="block",this._map.fire(L.Draw.Event.TOOLBAROPENED)},_hideActionsToolbar:function(){this._actionsContainer.style.display="none",L.DomUtil.removeClass(this._toolbarContainer,"leaflet-draw-toolbar-notop"),L.DomUtil.removeClass(this._toolbarContainer,"leaflet-draw-toolbar-nobottom"),L.DomUtil.removeClass(this._actionsContainer,"leaflet-draw-actions-top"),L.DomUtil.removeClass(this._actionsContainer,"leaflet-draw-actions-bottom"),this._map.fire(L.Draw.Event.TOOLBARCLOSED)}}),L.Draw=L.Draw||{},L.Draw.Tooltip=L.Class.extend({initialize:function(n){this._map=n,this._popupPane=n._panes.popupPane,this._visible=!1,this._container=n.options.drawControlTooltips?L.DomUtil.create("div","leaflet-draw-tooltip",this._popupPane):null,this._singleLineLabel=!1,this._map.on("mouseout",this._onMouseOut,this)},dispose:function(){this._map.off("mouseout",this._onMouseOut,this),this._container&&(this._popupPane.removeChild(this._container),this._container=null)},updateContent:function(n){return this._container?(n.subtext=n.subtext||"",n.subtext.length!==0||this._singleLineLabel?n.subtext.length>0&&this._singleLineLabel&&(L.DomUtil.removeClass(this._container,"leaflet-draw-tooltip-single"),this._singleLineLabel=!1):(L.DomUtil.addClass(this._container,"leaflet-draw-tooltip-single"),this._singleLineLabel=!0),this._container.innerHTML=(n.subtext.length>0?'<span class="leaflet-draw-tooltip-subtext">'+n.subtext+"</span><br />":"")+"<span>"+n.text+"</span>",n.text||n.subtext?(this._visible=!0,this._container.style.visibility="inherit"):(this._visible=!1,this._container.style.visibility="hidden"),this):this},updatePosition:function(n){var r=this._map.latLngToLayerPoint(n),a=this._container;return this._container&&(this._visible&&(a.style.visibility="inherit"),L.DomUtil.setPosition(a,r)),this},showAsError:function(){return this._container&&L.DomUtil.addClass(this._container,"leaflet-error-draw-tooltip"),this},removeError:function(){return this._container&&L.DomUtil.removeClass(this._container,"leaflet-error-draw-tooltip"),this},_onMouseOut:function(){this._container&&(this._container.style.visibility="hidden")}}),L.DrawToolbar=L.Toolbar.extend({statics:{TYPE:"draw"},options:{polyline:{},polygon:{},rectangle:{},circle:{},marker:{},circlemarker:{}},initialize:function(n){for(var r in this.options)this.options.hasOwnProperty(r)&&n[r]&&(n[r]=L.extend({},this.options[r],n[r]));this._toolbarClass="leaflet-draw-draw",L.Toolbar.prototype.initialize.call(this,n)},getModeHandlers:function(n){return[{enabled:this.options.polyline,handler:new L.Draw.Polyline(n,this.options.polyline),title:L.drawLocal.draw.toolbar.buttons.polyline},{enabled:this.options.polygon,handler:new L.Draw.Polygon(n,this.options.polygon),title:L.drawLocal.draw.toolbar.buttons.polygon},{enabled:this.options.rectangle,handler:new L.Draw.Rectangle(n,this.options.rectangle),title:L.drawLocal.draw.toolbar.buttons.rectangle},{enabled:this.options.circle,handler:new L.Draw.Circle(n,this.options.circle),title:L.drawLocal.draw.toolbar.buttons.circle},{enabled:this.options.marker,handler:new L.Draw.Marker(n,this.options.marker),title:L.drawLocal.draw.toolbar.buttons.marker},{enabled:this.options.circlemarker,handler:new L.Draw.CircleMarker(n,this.options.circlemarker),title:L.drawLocal.draw.toolbar.buttons.circlemarker}]},getActions:function(n){return[{enabled:n.completeShape,title:L.drawLocal.draw.toolbar.finish.title,text:L.drawLocal.draw.toolbar.finish.text,callback:n.completeShape,context:n},{enabled:n.deleteLastVertex,title:L.drawLocal.draw.toolbar.undo.title,text:L.drawLocal.draw.toolbar.undo.text,callback:n.deleteLastVertex,context:n},{title:L.drawLocal.draw.toolbar.actions.title,text:L.drawLocal.draw.toolbar.actions.text,callback:this.disable,context:this}]},setOptions:function(n){L.setOptions(this,n);for(var r in this._modes)this._modes.hasOwnProperty(r)&&n.hasOwnProperty(r)&&this._modes[r].handler.setOptions(n[r])}}),L.EditToolbar=L.Toolbar.extend({statics:{TYPE:"edit"},options:{edit:{selectedPathOptions:{dashArray:"10, 10",fill:!0,fillColor:"#fe57a1",fillOpacity:.1,maintainColor:!1}},remove:{},poly:null,featureGroup:null},initialize:function(n){n.edit&&(n.edit.selectedPathOptions===void 0&&(n.edit.selectedPathOptions=this.options.edit.selectedPathOptions),n.edit.selectedPathOptions=L.extend({},this.options.edit.selectedPathOptions,n.edit.selectedPathOptions)),n.remove&&(n.remove=L.extend({},this.options.remove,n.remove)),n.poly&&(n.poly=L.extend({},this.options.poly,n.poly)),this._toolbarClass="leaflet-draw-edit",L.Toolbar.prototype.initialize.call(this,n),this._selectedFeatureCount=0},getModeHandlers:function(n){var r=this.options.featureGroup;return[{enabled:this.options.edit,handler:new L.EditToolbar.Edit(n,{featureGroup:r,selectedPathOptions:this.options.edit.selectedPathOptions,poly:this.options.poly}),title:L.drawLocal.edit.toolbar.buttons.edit},{enabled:this.options.remove,handler:new L.EditToolbar.Delete(n,{featureGroup:r}),title:L.drawLocal.edit.toolbar.buttons.remove}]},getActions:function(n){var r=[{title:L.drawLocal.edit.toolbar.actions.save.title,text:L.drawLocal.edit.toolbar.actions.save.text,callback:this._save,context:this},{title:L.drawLocal.edit.toolbar.actions.cancel.title,text:L.drawLocal.edit.toolbar.actions.cancel.text,callback:this.disable,context:this}];return n.removeAllLayers&&r.push({title:L.drawLocal.edit.toolbar.actions.clearAll.title,text:L.drawLocal.edit.toolbar.actions.clearAll.text,callback:this._clearAllLayers,context:this}),r},addToolbar:function(n){var r=L.Toolbar.prototype.addToolbar.call(this,n);return this._checkDisabled(),this.options.featureGroup.on("layeradd layerremove",this._checkDisabled,this),r},removeToolbar:function(){this.options.featureGroup.off("layeradd layerremove",this._checkDisabled,this),L.Toolbar.prototype.removeToolbar.call(this)},disable:function(){this.enabled()&&(this._activeMode.handler.revertLayers(),L.Toolbar.prototype.disable.call(this))},_save:function(){this._activeMode.handler.save(),this._activeMode&&this._activeMode.handler.disable()},_clearAllLayers:function(){this._activeMode.handler.removeAllLayers(),this._activeMode&&this._activeMode.handler.disable()},_checkDisabled:function(){var n,r=this.options.featureGroup,a=r.getLayers().length!==0;this.options.edit&&(n=this._modes[L.EditToolbar.Edit.TYPE].button,a?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",a?L.drawLocal.edit.toolbar.buttons.edit:L.drawLocal.edit.toolbar.buttons.editDisabled)),this.options.remove&&(n=this._modes[L.EditToolbar.Delete.TYPE].button,a?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",a?L.drawLocal.edit.toolbar.buttons.remove:L.drawLocal.edit.toolbar.buttons.removeDisabled))}}),L.EditToolbar.Edit=L.Handler.extend({statics:{TYPE:"edit"},initialize:function(n,r){if(L.Handler.prototype.initialize.call(this,n),L.setOptions(this,r),this._featureGroup=r.featureGroup,!(this._featureGroup instanceof L.FeatureGroup))throw new Error("options.featureGroup must be a L.FeatureGroup");this._uneditedLayerProps={},this.type=L.EditToolbar.Edit.TYPE;var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.EditToolbar.Edit.include(L.Evented.prototype):L.EditToolbar.Edit.include(L.Mixin.Events)},enable:function(){!this._enabled&&this._hasAvailableLayers()&&(this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.EDITSTART,{handler:this.type}),L.Handler.prototype.enable.call(this),this._featureGroup.on("layeradd",this._enableLayerEdit,this).on("layerremove",this._disableLayerEdit,this))},disable:function(){this._enabled&&(this._featureGroup.off("layeradd",this._enableLayerEdit,this).off("layerremove",this._disableLayerEdit,this),L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.EDITSTOP,{handler:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(n.getContainer().focus(),this._featureGroup.eachLayer(this._enableLayerEdit,this),this._tooltip=new L.Draw.Tooltip(this._map),this._tooltip.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext}),n._editTooltip=this._tooltip,this._updateTooltip(),this._map.on("mousemove",this._onMouseMove,this).on("touchmove",this._onMouseMove,this).on("MSPointerMove",this._onMouseMove,this).on(L.Draw.Event.EDITVERTEX,this._updateTooltip,this))},removeHooks:function(){this._map&&(this._featureGroup.eachLayer(this._disableLayerEdit,this),this._uneditedLayerProps={},this._tooltip.dispose(),this._tooltip=null,this._map.off("mousemove",this._onMouseMove,this).off("touchmove",this._onMouseMove,this).off("MSPointerMove",this._onMouseMove,this).off(L.Draw.Event.EDITVERTEX,this._updateTooltip,this))},revertLayers:function(){this._featureGroup.eachLayer(function(n){this._revertLayer(n)},this)},save:function(){var n=new L.LayerGroup;this._featureGroup.eachLayer(function(r){r.edited&&(n.addLayer(r),r.edited=!1)}),this._map.fire(L.Draw.Event.EDITED,{layers:n})},_backupLayer:function(n){var r=L.Util.stamp(n);this._uneditedLayerProps[r]||(n instanceof L.Polyline||n instanceof L.Polygon||n instanceof L.Rectangle?this._uneditedLayerProps[r]={latlngs:L.LatLngUtil.cloneLatLngs(n.getLatLngs())}:n instanceof L.Circle?this._uneditedLayerProps[r]={latlng:L.LatLngUtil.cloneLatLng(n.getLatLng()),radius:n.getRadius()}:(n instanceof L.Marker||n instanceof L.CircleMarker)&&(this._uneditedLayerProps[r]={latlng:L.LatLngUtil.cloneLatLng(n.getLatLng())}))},_getTooltipText:function(){return{text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext}},_updateTooltip:function(){this._tooltip.updateContent(this._getTooltipText())},_revertLayer:function(n){var r=L.Util.stamp(n);n.edited=!1,this._uneditedLayerProps.hasOwnProperty(r)&&(n instanceof L.Polyline||n instanceof L.Polygon||n instanceof L.Rectangle?n.setLatLngs(this._uneditedLayerProps[r].latlngs):n instanceof L.Circle?(n.setLatLng(this._uneditedLayerProps[r].latlng),n.setRadius(this._uneditedLayerProps[r].radius)):(n instanceof L.Marker||n instanceof L.CircleMarker)&&n.setLatLng(this._uneditedLayerProps[r].latlng),n.fire("revert-edited",{layer:n}))},_enableLayerEdit:function(n){var r,a,u=n.layer||n.target||n;this._backupLayer(u),this.options.poly&&(a=L.Util.extend({},this.options.poly),u.options.poly=a),this.options.selectedPathOptions&&(r=L.Util.extend({},this.options.selectedPathOptions),r.maintainColor&&(r.color=u.options.color,r.fillColor=u.options.fillColor),u.options.original=L.extend({},u.options),u.options.editing=r),u instanceof L.Marker?(u.editing&&u.editing.enable(),u.dragging.enable(),u.on("dragend",this._onMarkerDragEnd).on("touchmove",this._onTouchMove,this).on("MSPointerMove",this._onTouchMove,this).on("touchend",this._onMarkerDragEnd,this).on("MSPointerUp",this._onMarkerDragEnd,this)):u.editing.enable()},_disableLayerEdit:function(n){var r=n.layer||n.target||n;r.edited=!1,r.editing&&r.editing.disable(),delete r.options.editing,delete r.options.original,this._selectedPathOptions&&(r instanceof L.Marker?this._toggleMarkerHighlight(r):(r.setStyle(r.options.previousOptions),delete r.options.previousOptions)),r instanceof L.Marker?(r.dragging.disable(),r.off("dragend",this._onMarkerDragEnd,this).off("touchmove",this._onTouchMove,this).off("MSPointerMove",this._onTouchMove,this).off("touchend",this._onMarkerDragEnd,this).off("MSPointerUp",this._onMarkerDragEnd,this)):r.editing.disable()},_onMouseMove:function(n){this._tooltip.updatePosition(n.latlng)},_onMarkerDragEnd:function(n){var r=n.target;r.edited=!0,this._map.fire(L.Draw.Event.EDITMOVE,{layer:r})},_onTouchMove:function(n){var r=n.originalEvent.changedTouches[0],a=this._map.mouseEventToLayerPoint(r),u=this._map.layerPointToLatLng(a);n.target.setLatLng(u)},_hasAvailableLayers:function(){return this._featureGroup.getLayers().length!==0}}),L.EditToolbar.Delete=L.Handler.extend({statics:{TYPE:"remove"},initialize:function(n,r){if(L.Handler.prototype.initialize.call(this,n),L.Util.setOptions(this,r),this._deletableLayers=this.options.featureGroup,!(this._deletableLayers instanceof L.FeatureGroup))throw new Error("options.featureGroup must be a L.FeatureGroup");this.type=L.EditToolbar.Delete.TYPE;var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.EditToolbar.Delete.include(L.Evented.prototype):L.EditToolbar.Delete.include(L.Mixin.Events)},enable:function(){!this._enabled&&this._hasAvailableLayers()&&(this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.DELETESTART,{handler:this.type}),L.Handler.prototype.enable.call(this),this._deletableLayers.on("layeradd",this._enableLayerDelete,this).on("layerremove",this._disableLayerDelete,this))},disable:function(){this._enabled&&(this._deletableLayers.off("layeradd",this._enableLayerDelete,this).off("layerremove",this._disableLayerDelete,this),L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.DELETESTOP,{handler:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(n.getContainer().focus(),this._deletableLayers.eachLayer(this._enableLayerDelete,this),this._deletedLayers=new L.LayerGroup,this._tooltip=new L.Draw.Tooltip(this._map),this._tooltip.updateContent({text:L.drawLocal.edit.handlers.remove.tooltip.text}),this._map.on("mousemove",this._onMouseMove,this))},removeHooks:function(){this._map&&(this._deletableLayers.eachLayer(this._disableLayerDelete,this),this._deletedLayers=null,this._tooltip.dispose(),this._tooltip=null,this._map.off("mousemove",this._onMouseMove,this))},revertLayers:function(){this._deletedLayers.eachLayer(function(n){this._deletableLayers.addLayer(n),n.fire("revert-deleted",{layer:n})},this)},save:function(){this._map.fire(L.Draw.Event.DELETED,{layers:this._deletedLayers})},removeAllLayers:function(){this._deletableLayers.eachLayer(function(n){this._removeLayer({layer:n})},this),this.save()},_enableLayerDelete:function(n){(n.layer||n.target||n).on("click",this._removeLayer,this)},_disableLayerDelete:function(n){var r=n.layer||n.target||n;r.off("click",this._removeLayer,this),this._deletedLayers.removeLayer(r)},_removeLayer:function(n){var r=n.layer||n.target||n;this._deletableLayers.removeLayer(r),this._deletedLayers.addLayer(r),r.fire("deleted")},_onMouseMove:function(n){this._tooltip.updatePosition(n.latlng)},_hasAvailableLayers:function(){return this._deletableLayers.getLayers().length!==0}})})(window,document);var We={exports:{}},Ui;function Mo(){return Ui||(Ui=1,(function(g,h){(function(s,c){g.exports=s(Bi()),typeof c!="undefined"&&c.L&&(c.L.Ruler=s(L))})(function(s){s.Control.Ruler=s.Control.extend({options:{position:"topright",circleMarker:{color:"red",radius:2},lineStyle:{color:"red",dashArray:"1,6"},lengthUnit:{display:"km",decimal:2,factor:null,label:"Distance:"},angleUnit:{display:"°",decimal:2,factor:null,label:"Bearing:"}},onAdd:function(c){return this._map=c,this._container=s.DomUtil.create("div","leaflet-bar"),this._container.classList.add("leaflet-ruler"),s.DomEvent.disableClickPropagation(this._container),s.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._choice=!1,this._defaultCursor=this._map._container.style.cursor,this._allLayers=s.layerGroup(),this._container},onRemove:function(){s.DomEvent.off(this._container,"click",this._toggleMeasure,this)},_toggleMeasure:function(){this._choice=!this._choice,this._clickedLatLong=null,this._clickedPoints=[],this._totalLength=0,this._choice?(this._map.doubleClickZoom.disable(),s.DomEvent.on(this._map._container,"keydown",this._escape,this),s.DomEvent.on(this._map._container,"dblclick",this._closePath,this),this._container.classList.add("leaflet-ruler-clicked"),this._clickCount=0,this._tempLine=s.featureGroup().addTo(this._allLayers),this._tempPoint=s.featureGroup().addTo(this._allLayers),this._pointLayer=s.featureGroup().addTo(this._allLayers),this._polylineLayer=s.featureGroup().addTo(this._allLayers),this._allLayers.addTo(this._map),this._map._container.style.cursor="crosshair",this._map.on("click",this._clicked,this),this._map.on("mousemove",this._moving,this)):(this._map.doubleClickZoom.enable(),s.DomEvent.off(this._map._container,"keydown",this._escape,this),s.DomEvent.off(this._map._container,"dblclick",this._closePath,this),this._container.classList.remove("leaflet-ruler-clicked"),this._map.removeLayer(this._allLayers),this._allLayers=s.layerGroup(),this._map._container.style.cursor=this._defaultCursor,this._map.off("click",this._clicked,this),this._map.off("mousemove",this._moving,this))},_clicked:function(c){if(this._clickedLatLong=c.latlng,this._clickedPoints.push(this._clickedLatLong),s.circleMarker(this._clickedLatLong,this.options.circleMarker).addTo(this._pointLayer),this._clickCount>0&&!c.latlng.equals(this._clickedPoints[this._clickedPoints.length-2])){this._movingLatLong&&s.polyline([this._clickedPoints[this._clickCount-1],this._movingLatLong],this.options.lineStyle).addTo(this._polylineLayer);var n;this._totalLength+=this._result.Distance,this._clickCount>1?n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._totalLength.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display:n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display,s.circleMarker(this._clickedLatLong,this.options.circleMarker).bindTooltip(n,{permanent:!0,className:"result-tooltip"}).addTo(this._pointLayer).openTooltip()}this._clickCount++},_moving:function(c){if(this._clickedLatLong){s.DomEvent.off(this._container,"click",this._toggleMeasure,this),this._movingLatLong=c.latlng,this._tempLine&&(this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint));var n;this._addedLength=0,this._tempLine=s.featureGroup(),this._tempPoint=s.featureGroup(),this._tempLine.addTo(this._map),this._tempPoint.addTo(this._map),this._calculateBearingAndDistance(),this._addedLength=this._result.Distance+this._totalLength,s.polyline([this._clickedLatLong,this._movingLatLong],this.options.lineStyle).addTo(this._tempLine),this._clickCount>1?n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._addedLength.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display+'<br><div class="plus-length">(+'+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+")</div>":n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display,s.circleMarker(this._movingLatLong,this.options.circleMarker).bindTooltip(n,{sticky:!0,offset:s.point(0,-40),className:"moving-tooltip"}).addTo(this._tempPoint).openTooltip()}},_escape:function(c){c.keyCode===27&&(this._clickCount>0?this._closePath():(this._choice=!0,this._toggleMeasure()))},_calculateBearingAndDistance:function(){var c=this._clickedLatLong.lat,n=this._clickedLatLong.lng,r=this._movingLatLong.lat,a=this._movingLatLong.lng,u=Math.PI/180,f=Math.sin((a-n)*u)*Math.cos(r*u),_=Math.cos(c*u)*Math.sin(r*u)-Math.sin(c*u)*Math.cos(r*u)*Math.cos((a-n)*u),m=Math.atan2(f,_)*((this.options.angleUnit.factor?this.options.angleUnit.factor/2:180)/Math.PI);m+=m<0?this.options.angleUnit.factor?this.options.angleUnit.factor:360:0;var w=this.options.lengthUnit.factor?6371*this.options.lengthUnit.factor:6371,x=(r-c)*u,E=(a-n)*u,P=Math.sin(x/2)*Math.sin(x/2)+Math.cos(c*u)*Math.cos(r*u)*Math.sin(E/2)*Math.sin(E/2),M=2*Math.atan2(Math.sqrt(P),Math.sqrt(1-P)),U=w*M;this._result={Bearing:m,Distance:U}},_closePath:function(){this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint),this._clickCount<=1&&this._map.removeLayer(this._pointLayer),this._choice=!1,s.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._toggleMeasure()}}),s.control.ruler=function(c){return new s.Control.Ruler(c)}},window)})(We)),We.exports}Mo();let ye;const Eo=new Uint8Array(16);function Po(){if(!ye&&(ye=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!ye))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ye(Eo)}const nt=[];for(let g=0;g<256;++g)nt.push((g+256).toString(16).slice(1));function Co(g,h=0){return nt[g[h+0]]+nt[g[h+1]]+nt[g[h+2]]+nt[g[h+3]]+"-"+nt[g[h+4]]+nt[g[h+5]]+"-"+nt[g[h+6]]+nt[g[h+7]]+"-"+nt[g[h+8]]+nt[g[h+9]]+"-"+nt[g[h+10]]+nt[g[h+11]]+nt[g[h+12]]+nt[g[h+13]]+nt[g[h+14]]+nt[g[h+15]]}const Ni={randomUUID:typeof crypto!="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Ye(g,h,s){if(Ni.randomUUID&&!g)return Ni.randomUUID();g=g||{};const c=g.random||(g.rng||Po)();return c[6]=c[6]&15|64,c[8]=c[8]&63|128,Co(c)}function To(g){var s,c;const h=(c=g.id)!=null?c:(s=g.properties)==null?void 0:s.id;if(h!=null)return String(h)}function So(g,h){const s=c=>{switch(c.type){case"Point":h(c.coordinates);break;case"MultiPoint":case"LineString":for(const n of c.coordinates)h(n);break;case"MultiLineString":case"Polygon":for(const n of c.coordinates)for(const r of n)h(r);break;case"MultiPolygon":for(const n of c.coordinates)for(const r of n)for(const a of r)h(a);break;case"GeometryCollection":for(const n of c.geometries)s(n);break}};s(g)}function Do(g){const h=g.geometry;if(!h)return null;let s=1/0,c=1/0,n=-1/0,r=-1/0,a=!1;return So(h,u=>{const[f,_]=u;typeof f!="number"||typeof _!="number"||(a=!0,f<s&&(s=f),_<c&&(c=_),f>n&&(n=f),_>r&&(r=_))}),a?[s,c,n,r]:null}function Io(g){let h=1/0,s=1/0,c=-1/0,n=-1/0,r=!1;for(const a of g.features){const u=Do(a);u&&(r=!0,h=Math.min(h,u[0]),s=Math.min(s,u[1]),c=Math.max(c,u[2]),n=Math.max(n,u[3]))}return r?[h,s,c,n]:null}function zo(g){const[h,s,c,n]=g;return[[s,h],[n,c]]}function Zi(g){var s;const h=[];for(const c of g.features){if(!c||c.type!=="Feature")continue;const n=(s=c.properties)!=null?s:{},r=c.geometry;if(r)switch(r.type){case"MultiPolygon":for(const a of r.coordinates)h.push({type:"Feature",properties:{...n},geometry:{type:"Polygon",coordinates:a}});break;case"MultiLineString":for(const a of r.coordinates)h.push({type:"Feature",properties:{...n},geometry:{type:"LineString",coordinates:a}});break;case"MultiPoint":for(const a of r.coordinates)h.push({type:"Feature",properties:{...n},geometry:{type:"Point",coordinates:a}});break;case"GeometryCollection":for(const a of r.geometries)h.push({type:"Feature",properties:{...n},geometry:a});break;default:h.push(c);break}}return{type:"FeatureCollection",features:h}}function Hi(g){return(g==null?void 0:g.type)==="Polygon"}function Fi(g){return(g==null?void 0:g.type)==="MultiPolygon"}function Oo(g){const h=g.geometry;return h?Hi(h)?[h.coordinates]:Fi(h)?h.coordinates:[]:[]}function Bo(g,h){var n,r;const s=[];for(const a of g){const u=Oo(a);u.length>0&&s.push(...u)}if(s.length===0)return null;const c=(r=h!=null?h:(n=g[0])==null?void 0:n.properties)!=null?r:{};return s.length===1?{type:"Feature",properties:{...c},geometry:{type:"Polygon",coordinates:s[0]}}:{type:"Feature",properties:{...c},geometry:{type:"MultiPolygon",coordinates:s}}}class Ro{constructor(h=ge("feature-store","debug")){k(this,"log");k(this,"features");this.log=h,this.features=new Map}size(){return this.features.size}has(h){return this.features.has(h)}get(h){return this.features.get(h)}add(h){var r,a,u,f;const s=[],c=(a=(r=performance.now)==null?void 0:r.call(performance))!=null?a:Date.now();for(const _ of h.features){const m=this.ensureId(_),w={..._,id:m};this.features.set(m,w),s.push(m)}const n=((f=(u=performance.now)==null?void 0:u.call(performance))!=null?f:Date.now())-c;return this.log.debug("add",{count:h.features.length,ids:s,elapsedMs:Math.round(n)}),s}update(h,s){if(!this.features.has(h)){this.log.warn("update:missing",{id:h});return}const c={...s,id:h};this.features.set(h,c),this.log.debug("update",{id:h})}remove(h){this.features.delete(h)?this.log.debug("remove",{id:h}):this.log.warn("remove:missing",{id:h})}clear(){const h=this.features.size;this.features.clear(),this.log.debug("clear",{count:h})}toFeatureCollection(){return{type:"FeatureCollection",features:Array.from(this.features.values())}}bounds(){const h=this.toFeatureCollection();if(h.features.length===0)return null;const s=Io(h);return s?zo(s):null}ensureId(h){const s=To(h);if(s)return String(s);const c=Ye();return h.id=c,h.properties&&typeof h.properties=="object"&&(h.properties.id=c),c}}const Gi=new WeakSet;function Uo(g=ve){var c;if(Gi.has(g))return;const h=g.DrawToolbar;if(!((c=h==null?void 0:h.prototype)!=null&&c.getModeHandlers))return;const s=h.prototype.getModeHandlers;h.prototype.getModeHandlers=function(n){var a,u,f,_;const r=s.call(this,n);if((a=this.options)!=null&&a.cake){const m=(u=g.Draw)==null?void 0:u.Cake;if(!m)return r;r.push({enabled:!0,handler:new m(n,this.options.cake),title:"Draw Layer Cake (Subtractive Zones)"})}if((f=this.options)!=null&&f.move){const m=(_=g.Draw)==null?void 0:_.Move;if(!m)return r;r.push({enabled:!0,handler:new m(n,this.options.move),title:"Move/Translate Features"})}return r},Gi.add(g)}const be=class be extends Q.Draw.Circle{constructor(h,s){super(h,s),this.type=be.TYPE}addHooks(){super.addHooks();const h=this._tooltip;h!=null&&h.updateContent&&h.updateContent({text:"Click and drag to draw the Layer Cake base",subtext:"Release mouse to finish base layer"})}};k(be,"TYPE","cake");let Le=be;Q.Draw.Cake=Le;function No(g){const h=g.Draw;if(!h||h.Cake)return;const c=class c extends h.Circle{constructor(r,a){super(r,a),this.type=c.TYPE}addHooks(){super.addHooks();const r=this._tooltip;r!=null&&r.updateContent&&r.updateContent({text:"Click and drag to draw the Layer Cake base",subtext:"Release mouse to finish base layer"})}};k(c,"TYPE","cake");let s=c;h.Cake=s}const xe=class xe extends Q.Draw.Feature{constructor(s,c){super(s,c);k(this,"_featureGroup");k(this,"_selectedLayer",null);k(this,"_originalLatLngs",null);k(this,"_dragStartLatLng",null);k(this,"_isDragging",!1);k(this,"_pendingMove",null);this.type=xe.TYPE,this._featureGroup=(c==null?void 0:c.featureGroup)||new Q.FeatureGroup}enable(){this._enabled||super.enable()}disable(){this._enabled&&(this._cleanupDragging(),super.disable())}addHooks(){const s=this._map;if(!s)return;Q.DomUtil.addClass(s.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(n=>{this._enableLayerHover(n)});const c=this._tooltip;c!=null&&c.updateContent&&c.updateContent({text:"Click and drag a feature to move it",subtext:""})}removeHooks(){const s=this._map;s&&(Q.DomUtil.removeClass(s.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(c=>{this._disableLayerHover(c)}),this._cleanupDragging())}_enableLayerHover(s){s.on&&(s.on("mouseover",this._onLayerMouseOver,this),s.on("mouseout",this._onLayerMouseOut,this),s.on("mousedown",this._onLayerMouseDown,this))}_disableLayerHover(s){s.off&&(s.off("mouseover",this._onLayerMouseOver,this),s.off("mouseout",this._onLayerMouseOut,this),s.off("mousedown",this._onLayerMouseDown,this))}_onLayerMouseOver(s){if(this._isDragging)return;const c=s.target;if(c.getElement){const n=c.getElement();n&&(n.style.cursor="grab")}else c._path&&(c._path.style.cursor="grab")}_onLayerMouseOut(s){if(this._isDragging)return;const c=s.target;if(c.getElement){const n=c.getElement();n&&(n.style.cursor="")}else c._path&&(c._path.style.cursor="")}_onLayerMouseDown(s){if(this._isDragging)return;Q.DomEvent.stopPropagation(s.originalEvent),Q.DomEvent.preventDefault(s.originalEvent);const c=s.target;if(this._selectedLayer=c,this._isDragging=!0,this._dragStartLatLng=s.latlng,this._storeOriginalLatLngs(c),c.getElement){const r=c.getElement();r&&(r.style.cursor="grabbing")}else c._path&&(c._path.style.cursor="grabbing");this._map.on("mousemove",this._onMouseMove,this),this._map.on("mouseup",this._onMouseUp,this);const n=c.toGeoJSON();this._pendingMove={layer:c,originalGeoJSON:n,newGeoJSON:n}}_storeOriginalLatLngs(s){s.getLatLng?this._originalLatLngs=s.getLatLng():s.getLatLngs&&(this._originalLatLngs=JSON.parse(JSON.stringify(s.getLatLngs())))}_onMouseMove(s){if(!this._isDragging||!this._selectedLayer||!this._dragStartLatLng)return;const c=this._selectedLayer,n={lat:s.latlng.lat-this._dragStartLatLng.lat,lng:s.latlng.lng-this._dragStartLatLng.lng};if(c.setLatLng){const r=Q.latLng(this._originalLatLngs.lat+n.lat,this._originalLatLngs.lng+n.lng);c.setLatLng(r)}else if(c.setLatLngs){const r=this._offsetLatLngs(this._originalLatLngs,n);c.setLatLngs(r)}}_offsetLatLngs(s,c){return s instanceof Q.LatLng||s.lat!==void 0&&s.lng!==void 0?Q.latLng(s.lat+c.lat,s.lng+c.lng):Array.isArray(s)?s.map(n=>this._offsetLatLngs(n,c)):s}_onMouseUp(s){var n,r;if(!this._isDragging||!this._selectedLayer)return;this._pendingMove&&(this._pendingMove.newGeoJSON=this._selectedLayer.toGeoJSON());const c=this._selectedLayer;if(c.getElement){const a=c.getElement();a&&(a.style.cursor="grab")}else c._path&&(c._path.style.cursor="grab");this._map.fire("draw:moveend",{layer:this._selectedLayer,originalGeoJSON:(n=this._pendingMove)==null?void 0:n.originalGeoJSON,newGeoJSON:(r=this._pendingMove)==null?void 0:r.newGeoJSON}),this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._isDragging=!1}_cleanupDragging(){if(this._selectedLayer){const s=this._selectedLayer;if(s.getElement){const c=s.getElement();c&&(c.style.cursor="")}else s._path&&(s._path.style.cursor="")}this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._selectedLayer=null,this._originalLatLngs=null,this._dragStartLatLng=null,this._isDragging=!1,this._pendingMove=null}confirmMove(){this._pendingMove&&(this._map.fire("draw:moveconfirmed",{layer:this._pendingMove.layer,originalGeoJSON:this._pendingMove.originalGeoJSON,newGeoJSON:this._pendingMove.newGeoJSON}),this._cleanupDragging())}cancelMove(){if(!this._pendingMove)return;const s=this._pendingMove.layer;s.setLatLng&&this._originalLatLngs?s.setLatLng(this._originalLatLngs):s.setLatLngs&&this._originalLatLngs&&s.setLatLngs(this._originalLatLngs),this._cleanupDragging()}hasPendingMove(){return this._pendingMove!==null}};k(xe,"TYPE","move");let qe=xe;Q.Draw.Move=qe;function Zo(g){const h=g.Draw;if(!h||h.Move)return;const c=class c extends h.Feature{constructor(a,u){super(a,u);k(this,"_featureGroup");k(this,"_selectedLayer",null);k(this,"_originalLatLngs",null);k(this,"_dragStartLatLng",null);k(this,"_isDragging",!1);k(this,"_pendingMove",null);this.type=c.TYPE,this._featureGroup=(u==null?void 0:u.featureGroup)||new Q.FeatureGroup}enable(){this._enabled||super.enable()}disable(){this._enabled&&(this._cleanupDragging(),super.disable())}addHooks(){const a=this._map;if(!a)return;g.DomUtil.addClass(a.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(f=>{this._enableLayerHover(f)});const u=this._tooltip;u!=null&&u.updateContent&&u.updateContent({text:"Click and drag a feature to move it",subtext:""})}removeHooks(){const a=this._map;a&&(g.DomUtil.removeClass(a.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(u=>{this._disableLayerHover(u)}),this._cleanupDragging())}_enableLayerHover(a){a.on&&(a.on("mouseover",this._onLayerMouseOver,this),a.on("mouseout",this._onLayerMouseOut,this),a.on("mousedown",this._onLayerMouseDown,this))}_disableLayerHover(a){a.off&&(a.off("mouseover",this._onLayerMouseOver,this),a.off("mouseout",this._onLayerMouseOut,this),a.off("mousedown",this._onLayerMouseDown,this))}_onLayerMouseOver(a){if(this._isDragging)return;const u=a.target;if(u.getElement){const f=u.getElement();f&&(f.style.cursor="grab")}else u._path&&(u._path.style.cursor="grab")}_onLayerMouseOut(a){if(this._isDragging)return;const u=a.target;if(u.getElement){const f=u.getElement();f&&(f.style.cursor="")}else u._path&&(u._path.style.cursor="")}_onLayerMouseDown(a){if(this._isDragging)return;g.DomEvent.stopPropagation(a.originalEvent),g.DomEvent.preventDefault(a.originalEvent);const u=a.target;if(this._selectedLayer=u,this._isDragging=!0,this._dragStartLatLng=a.latlng,this._storeOriginalLatLngs(u),u.getElement){const _=u.getElement();_&&(_.style.cursor="grabbing")}else u._path&&(u._path.style.cursor="grabbing");this._map.on("mousemove",this._onMouseMove,this),this._map.on("mouseup",this._onMouseUp,this);const f=u.toGeoJSON();this._pendingMove={layer:u,originalGeoJSON:f,newGeoJSON:f}}_storeOriginalLatLngs(a){a.getLatLng?this._originalLatLngs=a.getLatLng():a.getLatLngs&&(this._originalLatLngs=JSON.parse(JSON.stringify(a.getLatLngs())))}_onMouseMove(a){if(!this._isDragging||!this._selectedLayer||!this._dragStartLatLng)return;const u=this._selectedLayer,f={lat:a.latlng.lat-this._dragStartLatLng.lat,lng:a.latlng.lng-this._dragStartLatLng.lng};if(u.setLatLng){const _=g.latLng(this._originalLatLngs.lat+f.lat,this._originalLatLngs.lng+f.lng);u.setLatLng(_)}else if(u.setLatLngs){const _=this._offsetLatLngs(this._originalLatLngs,f);u.setLatLngs(_)}}_offsetLatLngs(a,u){return a instanceof g.LatLng||a.lat!==void 0&&a.lng!==void 0?g.latLng(a.lat+u.lat,a.lng+u.lng):Array.isArray(a)?a.map(f=>this._offsetLatLngs(f,u)):a}_onMouseUp(a){var f,_;if(!this._isDragging||!this._selectedLayer)return;this._pendingMove&&(this._pendingMove.newGeoJSON=this._selectedLayer.toGeoJSON());const u=this._selectedLayer;if(u.getElement){const m=u.getElement();m&&(m.style.cursor="grab")}else u._path&&(u._path.style.cursor="grab");this._map.fire("draw:moveend",{layer:this._selectedLayer,originalGeoJSON:(f=this._pendingMove)==null?void 0:f.originalGeoJSON,newGeoJSON:(_=this._pendingMove)==null?void 0:_.newGeoJSON}),this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._isDragging=!1}_cleanupDragging(){if(this._selectedLayer){const a=this._selectedLayer;if(a.getElement){const u=a.getElement();u&&(u.style.cursor="")}else a._path&&(a._path.style.cursor="")}this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._selectedLayer=null,this._originalLatLngs=null,this._dragStartLatLng=null,this._isDragging=!1,this._pendingMove=null}confirmMove(){this._pendingMove&&(this._map.fire("draw:moveconfirmed",{layer:this._pendingMove.layer,originalGeoJSON:this._pendingMove.originalGeoJSON,newGeoJSON:this._pendingMove.newGeoJSON}),this._cleanupDragging())}cancelMove(){if(!this._pendingMove)return;const a=this._pendingMove.layer;a.setLatLng&&this._originalLatLngs?a.setLatLng(this._originalLatLngs):a.setLatLngs&&this._originalLatLngs&&a.setLatLngs(this._originalLatLngs),this._cleanupDragging()}hasPendingMove(){return this._pendingMove!==null}};k(c,"TYPE","move");let s=c;h.Move=s}const Ho=63710088e-1;function je(g){return g*Math.PI/180}function Vi(g){return g*180/Math.PI}function Fo(g,h,s){const c=h/Ho,n=je(s),r=je(g.lat),a=je(g.lng),u=Math.sin(r),f=Math.cos(r),_=Math.sin(c),m=Math.cos(c),w=u*m+f*_*Math.cos(n),x=Math.asin(w),E=Math.sin(n)*_*f,P=m-u*w,M=a+Math.atan2(E,P);return{lat:Vi(x),lng:Vi(M)}}function Go(g){let h=0;for(let s=0;s<g.length-1;s++){const[c,n]=g[s],[r,a]=g[s+1];h+=c*a-r*n}return h/2}function Je(g){const h=g[0],s=g.at(-1);return!h||!s||h[0]===s[0]&&h[1]===s[1]?g:[...g,h]}function Ke(g,h){const s=Je(g);if(Go(s)<0===h)return s;const r=[...s].reverse();return Je(r)}function Xe(g,h,s){if(s<4)throw new Error("steps must be >= 4");const c=[];for(let n=0;n<s;n++){const r=n/s*360,a=Fo(g,h,r);c.push([a.lng,a.lat])}return Je(c)}function Vo(g){const{id:h,center:s,radiusMeters:c,layerIndex:n,steps:r}=g,a=Ke(Xe(s,c,r),!1);return{type:"Feature",properties:{id:h,layer_index:n,radius_outer:c,type:"core",_meta:{lat:s.lat,lng:s.lng,radius:c}},geometry:{type:"Polygon",coordinates:[a]}}}function Wo(g){const{id:h,center:s,radiusOuterMeters:c,radiusInnerMeters:n,layerIndex:r,steps:a}=g,u=Ke(Xe(s,c,a),!1),f=Ke(Xe(s,n,a),!0);return{type:"Feature",properties:{id:h,layer_index:r,radius_outer:c,type:"ring",_meta:{lat:s.lat,lng:s.lng,radius:c}},geometry:{type:"Polygon",coordinates:[u,f]}}}function Yo(g){const{circles:h,steps:s=64}=g,c=[...h].sort((r,a)=>r.getRadius()-a.getRadius()),n=[];return c.forEach((r,a)=>{const u=r.getLatLng(),f=r.getRadius(),_=Ye();if(a===0){n.push(Vo({id:_,center:u,radiusMeters:f,layerIndex:a,steps:s}));return}const w=c[a-1].getRadius();n.push(Wo({id:_,center:u,radiusOuterMeters:f,radiusInnerMeters:w,layerIndex:a,steps:s}))}),{type:"FeatureCollection",features:n}}function $t(g){g.preventDefault(),g.stopPropagation()}function qo(g){var _,m;const{root:h,addButtonId:s,saveButtonId:c,onAddRing:n,onSave:r}=g,a=(_=h.querySelector)==null?void 0:_.call(h,`#${s}`),u=(m=h.querySelector)==null?void 0:m.call(h,`#${c}`);if(!a||!u)return;const f="data-cake-controls-bound";if(!(a.hasAttribute(f)||u.hasAttribute(f))){a.setAttribute(f,"true"),u.setAttribute(f,"true");for(const w of[a,u])w.addEventListener("pointerdown",$t),w.addEventListener("mousedown",$t),w.addEventListener("touchstart",$t);a.addEventListener("click",w=>{$t(w),n()}),u.addEventListener("click",w=>{$t(w),r()})}}function jo(g){var s;const h=(s=g.options)!=null?s:{};h.original||(h.original={...h}),h.editing||(h.editing={...h})}function te(g,h){if(h==="imperial"){const s=g*3.28084;return s>=5280?`${(s/5280).toFixed(2)} mi`:`${Math.round(s)} ft`}return g>=1e3?`${(g/1e3).toFixed(2)} km`:`${Math.round(g)} m`}class Jo{constructor(h,s,c,n="metric"){k(this,"map");k(this,"layers",[]);k(this,"controlsGroup");k(this,"onSave");k(this,"sessionId",Ye().slice(0,8));k(this,"baseCircleOptions");k(this,"detachMapListeners",[]);k(this,"renderScheduled",!1);k(this,"measurementSystem");this.map=h,this.onSave=c,this.measurementSystem=n,this.controlsGroup=Q.layerGroup().addTo(h),this.baseCircleOptions={...s.options},delete this.baseCircleOptions.editing,delete this.baseCircleOptions.original,this.addLayer(s),this.installEditEventBridges(),this.renderControls()}installEditEventBridges(){var m,w,x,E,P,M,U,H;const h=ve,s=(w=(m=h==null?void 0:h.Draw)==null?void 0:m.Event)==null?void 0:w.EDITMOVE,c=(E=(x=h==null?void 0:h.Draw)==null?void 0:x.Event)==null?void 0:E.EDITRESIZE,n=(M=(P=h==null?void 0:h.Draw)==null?void 0:P.Event)==null?void 0:M.EDITSTART,r=(H=(U=h==null?void 0:h.Draw)==null?void 0:U.Event)==null?void 0:H.EDITSTOP;if(!s||!c)return;const a=T=>{const D=T==null?void 0:T.layer;D&&this.layers.includes(D)&&this.syncCenters(D)},u=T=>{const D=T==null?void 0:T.layer;D&&this.layers.includes(D)&&(this.updateLabels(D),this.requestRenderControls())},f=T=>{var J;const D=T==null?void 0:T.layer;if(!D||!this.layers.includes(D))return;const V=D;((J=V.getTooltip)==null?void 0:J.call(V))&&this.updateLabels(V)},_=()=>{this.layers.forEach(T=>{var V;const D=(V=T.getTooltip)==null?void 0:V.call(T);D&&(T.setTooltipContent(te(T.getRadius(),this.measurementSystem)),D.options.offset=[10,0],D.options.direction="right",T.closeTooltip(),T.openTooltip())})};this.map.on(s,a),this.map.on(c,u),n&&(this.map.on(n,f),this.detachMapListeners.push(()=>this.map.off(n,f))),r&&(this.map.on(r,_),this.detachMapListeners.push(()=>this.map.off(r,_))),this.detachMapListeners.push(()=>this.map.off(s,a)),this.detachMapListeners.push(()=>this.map.off(c,u))}requestRenderControls(){if(this.renderScheduled)return;this.renderScheduled=!0,(typeof requestAnimationFrame=="function"?requestAnimationFrame:s=>setTimeout(()=>s(0),0))(()=>{this.renderScheduled=!1,this.renderControls()})}addLayer(h){this.layers.push(h),h.addTo(this.map),h.bindTooltip(te(h.getRadius(),this.measurementSystem),{permanent:!0,direction:"right",className:"cake-label",offset:[10,0]});const s=h.editing;setTimeout(()=>{var c,n,r,a,u;try{if((c=h.redraw)==null||c.call(h),jo(h),(n=s==null?void 0:s.enabled)!=null&&n.call(s)){(r=s.updateMarkers)==null||r.call(s),this.requestRenderControls();return}(a=s==null?void 0:s.enable)==null||a.call(s),(u=s==null?void 0:s.updateMarkers)==null||u.call(s),this.requestRenderControls()}catch{}},0)}addRing(){if(this.layers.length>=10)return;const h=this.getLargestCircle();if(!h)return;const s=h.getRadius()*1.5,c=Q.circle(h.getLatLng(),{...this.baseCircleOptions,radius:s});this.addLayer(c),this.renderControls()}save(){const h=Yo({circles:this.layers});this.onSave(h),this.destroy()}getLargestCircle(){return this.layers.length===0?null:this.layers.reduce((h,s)=>h.getRadius()>s.getRadius()?h:s)}syncCenters(h){const s=h.getLatLng();this.layers.forEach(c=>{var n,r,a;c!==h&&(c.setLatLng(s),(n=c.redraw)==null||n.call(c),(a=(r=c.editing)==null?void 0:r.updateMarkers)==null||a.call(r))}),this.requestRenderControls()}updateLabels(h){var a;const s=h.getRadius();let c=te(s,this.measurementSystem);const n=this.layers.filter(u=>u!==h&&u.getRadius()<s);if(n.length>0){const u=n.reduce((m,w)=>m.getRadius()>w.getRadius()?m:w),f=s-u.getRadius(),_=te(f,this.measurementSystem);c=`${te(s,this.measurementSystem)} (+${_})`}const r=(a=h.getTooltip)==null?void 0:a.call(h);if(r){h.setTooltipContent(c);const f=h.getBounds().getSouthWest();f.lat=h.getLatLng().lat,r.options.direction="left",r.options.offset=[-10,0],r.setLatLng(f),h.closeTooltip(),h.openTooltip()}}renderControls(){this.controlsGroup.clearLayers();const h=this.getLargestCircle();if(!h)return;const c=h.getBounds().getNorthEast(),n=`cake-add-${this.sessionId}`,r=`cake-save-${this.sessionId}`,a=Q.divIcon({className:"layer-cake-controls",html:`
|
|
205
|
+
`,m.appendChild(s)}function Eo(){var m,c;(c=(m=X.Icon.Default).mergeOptions)==null||c.call(m,{iconRetinaUrl:yo,iconUrl:Lo,shadowUrl:wo})}function Po(m){const{root:c,skipStyles:s}=m;try{s||(Ao(c),Eo()),Mo(c)}catch{}}(function(m,c,s){function h(n,r){for(;(n=n.parentElement)&&!n.classList.contains(r););return n}L.drawVersion="1.0.4",L.Draw={},L.drawLocal={draw:{toolbar:{actions:{title:"Cancel drawing",text:"Cancel"},finish:{title:"Finish drawing",text:"Finish"},undo:{title:"Delete last point drawn",text:"Delete last point"},buttons:{polyline:"Draw a polyline",polygon:"Draw a polygon",rectangle:"Draw a rectangle",circle:"Draw a circle",marker:"Draw a marker",circlemarker:"Draw a circlemarker"}},handlers:{circle:{tooltip:{start:"Click and drag to draw circle."},radius:"Radius"},circlemarker:{tooltip:{start:"Click map to place circle marker."}},marker:{tooltip:{start:"Click map to place marker."}},polygon:{tooltip:{start:"Click to start drawing shape.",cont:"Click to continue drawing shape.",end:"Click first point to close this shape."}},polyline:{error:"<strong>Error:</strong> shape edges cannot cross!",tooltip:{start:"Click to start drawing line.",cont:"Click to continue drawing line.",end:"Click last point to finish line."}},rectangle:{tooltip:{start:"Click and drag to draw rectangle."}},simpleshape:{tooltip:{end:"Release mouse to finish drawing."}}}},edit:{toolbar:{actions:{save:{title:"Save changes",text:"Save"},cancel:{title:"Cancel editing, discards all changes",text:"Cancel"},clearAll:{title:"Clear all layers",text:"Clear All"}},buttons:{edit:"Edit layers",editDisabled:"No layers to edit",remove:"Delete layers",removeDisabled:"No layers to delete"}},handlers:{edit:{tooltip:{text:"Drag handles or markers to edit features.",subtext:"Click cancel to undo changes."}},remove:{tooltip:{text:"Click on a feature to remove."}}}}},L.Draw.Event={},L.Draw.Event.CREATED="draw:created",L.Draw.Event.EDITED="draw:edited",L.Draw.Event.DELETED="draw:deleted",L.Draw.Event.DRAWSTART="draw:drawstart",L.Draw.Event.DRAWSTOP="draw:drawstop",L.Draw.Event.DRAWVERTEX="draw:drawvertex",L.Draw.Event.EDITSTART="draw:editstart",L.Draw.Event.EDITMOVE="draw:editmove",L.Draw.Event.EDITRESIZE="draw:editresize",L.Draw.Event.EDITVERTEX="draw:editvertex",L.Draw.Event.EDITSTOP="draw:editstop",L.Draw.Event.DELETESTART="draw:deletestart",L.Draw.Event.DELETESTOP="draw:deletestop",L.Draw.Event.TOOLBAROPENED="draw:toolbaropened",L.Draw.Event.TOOLBARCLOSED="draw:toolbarclosed",L.Draw.Event.MARKERCONTEXT="draw:markercontext",L.Draw=L.Draw||{},L.Draw.Feature=L.Handler.extend({initialize:function(n,r){this._map=n,this._container=n._container,this._overlayPane=n._panes.overlayPane,this._popupPane=n._panes.popupPane,r&&r.shapeOptions&&(r.shapeOptions=L.Util.extend({},this.options.shapeOptions,r.shapeOptions)),L.setOptions(this,r);var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.Draw.Feature.include(L.Evented.prototype):L.Draw.Feature.include(L.Mixin.Events)},enable:function(){this._enabled||(L.Handler.prototype.enable.call(this),this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.DRAWSTART,{layerType:this.type}))},disable:function(){this._enabled&&(L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.DRAWSTOP,{layerType:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(L.DomUtil.disableTextSelection(),n.getContainer().focus(),this._tooltip=new L.Draw.Tooltip(this._map),L.DomEvent.on(this._container,"keyup",this._cancelDrawing,this))},removeHooks:function(){this._map&&(L.DomUtil.enableTextSelection(),this._tooltip.dispose(),this._tooltip=null,L.DomEvent.off(this._container,"keyup",this._cancelDrawing,this))},setOptions:function(n){L.setOptions(this,n)},_fireCreatedEvent:function(n){this._map.fire(L.Draw.Event.CREATED,{layer:n,layerType:this.type})},_cancelDrawing:function(n){n.keyCode===27&&(this._map.fire("draw:canceled",{layerType:this.type}),this.disable())}}),L.Draw.Polyline=L.Draw.Feature.extend({statics:{TYPE:"polyline"},Poly:L.Polyline,options:{allowIntersection:!0,repeatMode:!1,drawError:{color:"#b00b00",timeout:2500},icon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon"}),touchIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-touch-icon"}),guidelineDistance:20,maxGuideLineLength:4e3,shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!1,clickable:!0},metric:!0,feet:!0,nautic:!1,showLength:!0,zIndexOffset:2e3,factor:1,maxPoints:0},initialize:function(n,r){L.Browser.touch&&(this.options.icon=this.options.touchIcon),this.options.drawError.message=L.drawLocal.draw.handlers.polyline.error,r&&r.drawError&&(r.drawError=L.Util.extend({},this.options.drawError,r.drawError)),this.type=L.Draw.Polyline.TYPE,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._markers=[],this._markerGroup=new L.LayerGroup,this._map.addLayer(this._markerGroup),this._poly=new L.Polyline([],this.options.shapeOptions),this._tooltip.updateContent(this._getTooltipText()),this._mouseMarker||(this._mouseMarker=L.marker(this._map.getCenter(),{icon:L.divIcon({className:"leaflet-mouse-marker",iconAnchor:[20,20],iconSize:[40,40]}),opacity:0,zIndexOffset:this.options.zIndexOffset})),this._mouseMarker.on("mouseout",this._onMouseOut,this).on("mousemove",this._onMouseMove,this).on("mousedown",this._onMouseDown,this).on("mouseup",this._onMouseUp,this).addTo(this._map),this._map.on("mouseup",this._onMouseUp,this).on("mousemove",this._onMouseMove,this).on("zoomlevelschange",this._onZoomEnd,this).on("touchstart",this._onTouch,this).on("zoomend",this._onZoomEnd,this))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._clearHideErrorTimeout(),this._cleanUpShape(),this._map.removeLayer(this._markerGroup),delete this._markerGroup,delete this._markers,this._map.removeLayer(this._poly),delete this._poly,this._mouseMarker.off("mousedown",this._onMouseDown,this).off("mouseout",this._onMouseOut,this).off("mouseup",this._onMouseUp,this).off("mousemove",this._onMouseMove,this),this._map.removeLayer(this._mouseMarker),delete this._mouseMarker,this._clearGuides(),this._map.off("mouseup",this._onMouseUp,this).off("mousemove",this._onMouseMove,this).off("zoomlevelschange",this._onZoomEnd,this).off("zoomend",this._onZoomEnd,this).off("touchstart",this._onTouch,this).off("click",this._onTouch,this)},deleteLastVertex:function(){if(!(this._markers.length<=1)){var n=this._markers.pop(),r=this._poly,a=r.getLatLngs(),u=a.splice(-1,1)[0];this._poly.setLatLngs(a),this._markerGroup.removeLayer(n),r.getLatLngs().length<2&&this._map.removeLayer(r),this._vertexChanged(u,!1)}},addVertex:function(n){if(this._markers.length>=2&&!this.options.allowIntersection&&this._poly.newLatLngIntersects(n))return void this._showErrorTooltip();this._errorShown&&this._hideErrorTooltip(),this._markers.push(this._createMarker(n)),this._poly.addLatLng(n),this._poly.getLatLngs().length===2&&this._map.addLayer(this._poly),this._vertexChanged(n,!0)},completeShape:function(){this._markers.length<=1||!this._shapeIsValid()||(this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable())},_finishShape:function(){var n=this._poly._defaultShape?this._poly._defaultShape():this._poly.getLatLngs(),r=this._poly.newLatLngIntersects(n[n.length-1]);if(!this.options.allowIntersection&&r||!this._shapeIsValid())return void this._showErrorTooltip();this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()},_shapeIsValid:function(){return!0},_onZoomEnd:function(){this._markers!==null&&this._updateGuide()},_onMouseMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent),a=this._map.layerPointToLatLng(r);this._currentLatLng=a,this._updateTooltip(a),this._updateGuide(r),this._mouseMarker.setLatLng(a),L.DomEvent.preventDefault(n.originalEvent)},_vertexChanged:function(n,r){this._map.fire(L.Draw.Event.DRAWVERTEX,{layers:this._markerGroup}),this._updateFinishHandler(),this._updateRunningMeasure(n,r),this._clearGuides(),this._updateTooltip()},_onMouseDown:function(n){if(!this._clickHandled&&!this._touchHandled&&!this._disableMarkers){this._onMouseMove(n),this._clickHandled=!0,this._disableNewMarkers();var r=n.originalEvent,a=r.clientX,u=r.clientY;this._startPoint.call(this,a,u)}},_startPoint:function(n,r){this._mouseDownOrigin=L.point(n,r)},_onMouseUp:function(n){var r=n.originalEvent,a=r.clientX,u=r.clientY;this._endPoint.call(this,a,u,n),this._clickHandled=null},_endPoint:function(n,r,a){if(this._mouseDownOrigin){var u=L.point(n,r).distanceTo(this._mouseDownOrigin),f=this._calculateFinishDistance(a.latlng);this.options.maxPoints>1&&this.options.maxPoints==this._markers.length+1?(this.addVertex(a.latlng),this._finishShape()):f<10&&L.Browser.touch?this._finishShape():Math.abs(u)<9*(m.devicePixelRatio||1)&&this.addVertex(a.latlng),this._enableNewMarkers()}this._mouseDownOrigin=null},_onTouch:function(n){var r,a,u=n.originalEvent;!u.touches||!u.touches[0]||this._clickHandled||this._touchHandled||this._disableMarkers||(r=u.touches[0].clientX,a=u.touches[0].clientY,this._disableNewMarkers(),this._touchHandled=!0,this._startPoint.call(this,r,a),this._endPoint.call(this,r,a,n),this._touchHandled=null),this._clickHandled=null},_onMouseOut:function(){this._tooltip&&this._tooltip._onMouseOut.call(this._tooltip)},_calculateFinishDistance:function(n){var r;if(this._markers.length>0){var a;if(this.type===L.Draw.Polyline.TYPE)a=this._markers[this._markers.length-1];else{if(this.type!==L.Draw.Polygon.TYPE)return 1/0;a=this._markers[0]}var u=this._map.latLngToContainerPoint(a.getLatLng()),f=new L.Marker(n,{icon:this.options.icon,zIndexOffset:2*this.options.zIndexOffset}),_=this._map.latLngToContainerPoint(f.getLatLng());r=u.distanceTo(_)}else r=1/0;return r},_updateFinishHandler:function(){var n=this._markers.length;n>1&&this._markers[n-1].on("click",this._finishShape,this),n>2&&this._markers[n-2].off("click",this._finishShape,this)},_createMarker:function(n){var r=new L.Marker(n,{icon:this.options.icon,zIndexOffset:2*this.options.zIndexOffset});return this._markerGroup.addLayer(r),r},_updateGuide:function(n){var r=this._markers?this._markers.length:0;r>0&&(n=n||this._map.latLngToLayerPoint(this._currentLatLng),this._clearGuides(),this._drawGuide(this._map.latLngToLayerPoint(this._markers[r-1].getLatLng()),n))},_updateTooltip:function(n){var r=this._getTooltipText();n&&this._tooltip.updatePosition(n),this._errorShown||this._tooltip.updateContent(r)},_drawGuide:function(n,r){var a,u,f,_=Math.floor(Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2))),g=this.options.guidelineDistance,w=this.options.maxGuideLineLength,x=_>w?_-w:g;for(this._guidesContainer||(this._guidesContainer=L.DomUtil.create("div","leaflet-draw-guides",this._overlayPane));x<_;x+=this.options.guidelineDistance)a=x/_,u={x:Math.floor(n.x*(1-a)+a*r.x),y:Math.floor(n.y*(1-a)+a*r.y)},f=L.DomUtil.create("div","leaflet-draw-guide-dash",this._guidesContainer),f.style.backgroundColor=this._errorShown?this.options.drawError.color:this.options.shapeOptions.color,L.DomUtil.setPosition(f,u)},_updateGuideColor:function(n){if(this._guidesContainer)for(var r=0,a=this._guidesContainer.childNodes.length;r<a;r++)this._guidesContainer.childNodes[r].style.backgroundColor=n},_clearGuides:function(){if(this._guidesContainer)for(;this._guidesContainer.firstChild;)this._guidesContainer.removeChild(this._guidesContainer.firstChild)},_getTooltipText:function(){var n,r,a=this.options.showLength;return this._markers.length===0?n={text:L.drawLocal.draw.handlers.polyline.tooltip.start}:(r=a?this._getMeasurementString():"",n=this._markers.length===1?{text:L.drawLocal.draw.handlers.polyline.tooltip.cont,subtext:r}:{text:L.drawLocal.draw.handlers.polyline.tooltip.end,subtext:r}),n},_updateRunningMeasure:function(n,r){var a,u,f=this._markers.length;this._markers.length===1?this._measurementRunningTotal=0:(a=f-(r?2:1),u=L.GeometryUtil.isVersion07x()?n.distanceTo(this._markers[a].getLatLng())*(this.options.factor||1):this._map.distance(n,this._markers[a].getLatLng())*(this.options.factor||1),this._measurementRunningTotal+=u*(r?1:-1))},_getMeasurementString:function(){var n,r=this._currentLatLng,a=this._markers[this._markers.length-1].getLatLng();return n=L.GeometryUtil.isVersion07x()?a&&r&&r.distanceTo?this._measurementRunningTotal+r.distanceTo(a)*(this.options.factor||1):this._measurementRunningTotal||0:a&&r?this._measurementRunningTotal+this._map.distance(r,a)*(this.options.factor||1):this._measurementRunningTotal||0,L.GeometryUtil.readableDistance(n,this.options.metric,this.options.feet,this.options.nautic,this.options.precision)},_showErrorTooltip:function(){this._errorShown=!0,this._tooltip.showAsError().updateContent({text:this.options.drawError.message}),this._updateGuideColor(this.options.drawError.color),this._poly.setStyle({color:this.options.drawError.color}),this._clearHideErrorTimeout(),this._hideErrorTimeout=setTimeout(L.Util.bind(this._hideErrorTooltip,this),this.options.drawError.timeout)},_hideErrorTooltip:function(){this._errorShown=!1,this._clearHideErrorTimeout(),this._tooltip.removeError().updateContent(this._getTooltipText()),this._updateGuideColor(this.options.shapeOptions.color),this._poly.setStyle({color:this.options.shapeOptions.color})},_clearHideErrorTimeout:function(){this._hideErrorTimeout&&(clearTimeout(this._hideErrorTimeout),this._hideErrorTimeout=null)},_disableNewMarkers:function(){this._disableMarkers=!0},_enableNewMarkers:function(){setTimeout(function(){this._disableMarkers=!1}.bind(this),50)},_cleanUpShape:function(){this._markers.length>1&&this._markers[this._markers.length-1].off("click",this._finishShape,this)},_fireCreatedEvent:function(){var n=new this.Poly(this._poly.getLatLngs(),this.options.shapeOptions);L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)}}),L.Draw.Polygon=L.Draw.Polyline.extend({statics:{TYPE:"polygon"},Poly:L.Polygon,options:{showArea:!1,showLength:!1,shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},metric:!0,feet:!0,nautic:!1,precision:{}},initialize:function(n,r){L.Draw.Polyline.prototype.initialize.call(this,n,r),this.type=L.Draw.Polygon.TYPE},_updateFinishHandler:function(){var n=this._markers.length;n===1&&this._markers[0].on("click",this._finishShape,this),n>2&&(this._markers[n-1].on("dblclick",this._finishShape,this),n>3&&this._markers[n-2].off("dblclick",this._finishShape,this))},_getTooltipText:function(){var n,r;return this._markers.length===0?n=L.drawLocal.draw.handlers.polygon.tooltip.start:this._markers.length<3?(n=L.drawLocal.draw.handlers.polygon.tooltip.cont,r=this._getMeasurementString()):(n=L.drawLocal.draw.handlers.polygon.tooltip.end,r=this._getMeasurementString()),{text:n,subtext:r}},_getMeasurementString:function(){var n=this._area,r="";return n||this.options.showLength?(this.options.showLength&&(r=L.Draw.Polyline.prototype._getMeasurementString.call(this)),n&&(r+="<br>"+L.GeometryUtil.readableArea(n,this.options.metric,this.options.precision)),r):null},_shapeIsValid:function(){return this._markers.length>=3},_vertexChanged:function(n,r){var a;!this.options.allowIntersection&&this.options.showArea&&(a=this._poly.getLatLngs(),this._area=L.GeometryUtil.geodesicArea(a)),L.Draw.Polyline.prototype._vertexChanged.call(this,n,r)},_cleanUpShape:function(){var n=this._markers.length;n>0&&(this._markers[0].off("click",this._finishShape,this),n>2&&this._markers[n-1].off("dblclick",this._finishShape,this))}}),L.SimpleShape={},L.Draw.SimpleShape=L.Draw.Feature.extend({options:{repeatMode:!1},initialize:function(n,r){this._endLabelText=L.drawLocal.draw.handlers.simpleshape.tooltip.end,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._mapDraggable=this._map.dragging.enabled(),this._mapDraggable&&this._map.dragging.disable(),this._container.style.cursor="crosshair",this._tooltip.updateContent({text:this._initialLabelText}),this._map.on("mousedown",this._onMouseDown,this).on("mousemove",this._onMouseMove,this).on("touchstart",this._onMouseDown,this).on("touchmove",this._onMouseMove,this),c.addEventListener("touchstart",L.DomEvent.preventDefault,{passive:!1}))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._map&&(this._mapDraggable&&this._map.dragging.enable(),this._container.style.cursor="",this._map.off("mousedown",this._onMouseDown,this).off("mousemove",this._onMouseMove,this).off("touchstart",this._onMouseDown,this).off("touchmove",this._onMouseMove,this),L.DomEvent.off(c,"mouseup",this._onMouseUp,this),L.DomEvent.off(c,"touchend",this._onMouseUp,this),c.removeEventListener("touchstart",L.DomEvent.preventDefault),this._shape&&(this._map.removeLayer(this._shape),delete this._shape)),this._isDrawing=!1},_getTooltipText:function(){return{text:this._endLabelText}},_onMouseDown:function(n){this._isDrawing=!0,this._startLatLng=n.latlng,L.DomEvent.on(c,"mouseup",this._onMouseUp,this).on(c,"touchend",this._onMouseUp,this).preventDefault(n.originalEvent)},_onMouseMove:function(n){var r=n.latlng;this._tooltip.updatePosition(r),this._isDrawing&&(this._tooltip.updateContent(this._getTooltipText()),this._drawShape(r))},_onMouseUp:function(){this._shape&&this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()}}),L.Draw.Rectangle=L.Draw.SimpleShape.extend({statics:{TYPE:"rectangle"},options:{shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},showArea:!0,metric:!0},initialize:function(n,r){this.type=L.Draw.Rectangle.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.rectangle.tooltip.start,L.Draw.SimpleShape.prototype.initialize.call(this,n,r)},disable:function(){this._enabled&&(this._isCurrentlyTwoClickDrawing=!1,L.Draw.SimpleShape.prototype.disable.call(this))},_onMouseUp:function(n){if(!this._shape&&!this._isCurrentlyTwoClickDrawing)return void(this._isCurrentlyTwoClickDrawing=!0);this._isCurrentlyTwoClickDrawing&&!h(n.target,"leaflet-pane")||L.Draw.SimpleShape.prototype._onMouseUp.call(this)},_drawShape:function(n){this._shape?this._shape.setBounds(new L.LatLngBounds(this._startLatLng,n)):(this._shape=new L.Rectangle(new L.LatLngBounds(this._startLatLng,n),this.options.shapeOptions),this._map.addLayer(this._shape))},_fireCreatedEvent:function(){var n=new L.Rectangle(this._shape.getBounds(),this.options.shapeOptions);L.Draw.SimpleShape.prototype._fireCreatedEvent.call(this,n)},_getTooltipText:function(){var n,r,a,u=L.Draw.SimpleShape.prototype._getTooltipText.call(this),f=this._shape,_=this.options.showArea;return f&&(n=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),r=L.GeometryUtil.geodesicArea(n),a=_?L.GeometryUtil.readableArea(r,this.options.metric):""),{text:u.text,subtext:a}}}),L.Draw.Marker=L.Draw.Feature.extend({statics:{TYPE:"marker"},options:{icon:new L.Icon.Default,repeatMode:!1,zIndexOffset:2e3},initialize:function(n,r){this.type=L.Draw.Marker.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.marker.tooltip.start,L.Draw.Feature.prototype.initialize.call(this,n,r)},addHooks:function(){L.Draw.Feature.prototype.addHooks.call(this),this._map&&(this._tooltip.updateContent({text:this._initialLabelText}),this._mouseMarker||(this._mouseMarker=L.marker(this._map.getCenter(),{icon:L.divIcon({className:"leaflet-mouse-marker",iconAnchor:[20,20],iconSize:[40,40]}),opacity:0,zIndexOffset:this.options.zIndexOffset})),this._mouseMarker.on("click",this._onClick,this).addTo(this._map),this._map.on("mousemove",this._onMouseMove,this),this._map.on("click",this._onTouch,this))},removeHooks:function(){L.Draw.Feature.prototype.removeHooks.call(this),this._map&&(this._map.off("click",this._onClick,this).off("click",this._onTouch,this),this._marker&&(this._marker.off("click",this._onClick,this),this._map.removeLayer(this._marker),delete this._marker),this._mouseMarker.off("click",this._onClick,this),this._map.removeLayer(this._mouseMarker),delete this._mouseMarker,this._map.off("mousemove",this._onMouseMove,this))},_onMouseMove:function(n){var r=n.latlng;this._tooltip.updatePosition(r),this._mouseMarker.setLatLng(r),this._marker?(r=this._mouseMarker.getLatLng(),this._marker.setLatLng(r)):(this._marker=this._createMarker(r),this._marker.on("click",this._onClick,this),this._map.on("click",this._onClick,this).addLayer(this._marker))},_createMarker:function(n){return new L.Marker(n,{icon:this.options.icon,zIndexOffset:this.options.zIndexOffset})},_onClick:function(){this._fireCreatedEvent(),this.disable(),this.options.repeatMode&&this.enable()},_onTouch:function(n){this._onMouseMove(n),this._onClick()},_fireCreatedEvent:function(){var n=new L.Marker.Touch(this._marker.getLatLng(),{icon:this.options.icon});L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)}}),L.Draw.CircleMarker=L.Draw.Marker.extend({statics:{TYPE:"circlemarker"},options:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0,zIndexOffset:2e3},initialize:function(n,r){this.type=L.Draw.CircleMarker.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.circlemarker.tooltip.start,L.Draw.Feature.prototype.initialize.call(this,n,r)},_fireCreatedEvent:function(){var n=new L.CircleMarker(this._marker.getLatLng(),this.options);L.Draw.Feature.prototype._fireCreatedEvent.call(this,n)},_createMarker:function(n){return new L.CircleMarker(n,this.options)}}),L.Draw.Circle=L.Draw.SimpleShape.extend({statics:{TYPE:"circle"},options:{shapeOptions:{stroke:!0,color:"#3388ff",weight:4,opacity:.5,fill:!0,fillColor:null,fillOpacity:.2,clickable:!0},showRadius:!0,metric:!0,feet:!0,nautic:!1},initialize:function(n,r){this.type=L.Draw.Circle.TYPE,this._initialLabelText=L.drawLocal.draw.handlers.circle.tooltip.start,L.Draw.SimpleShape.prototype.initialize.call(this,n,r)},_drawShape:function(n){if(L.GeometryUtil.isVersion07x())var r=this._startLatLng.distanceTo(n);else var r=this._map.distance(this._startLatLng,n);this._shape?this._shape.setRadius(r):(this._shape=new L.Circle(this._startLatLng,r,this.options.shapeOptions),this._map.addLayer(this._shape))},_fireCreatedEvent:function(){var n=new L.Circle(this._startLatLng,this._shape.getRadius(),this.options.shapeOptions);L.Draw.SimpleShape.prototype._fireCreatedEvent.call(this,n)},_onMouseMove:function(n){var r,a=n.latlng,u=this.options.showRadius,f=this.options.metric;if(this._tooltip.updatePosition(a),this._isDrawing){this._drawShape(a),r=this._shape.getRadius().toFixed(1);var _="";u&&(_=L.drawLocal.draw.handlers.circle.radius+": "+L.GeometryUtil.readableDistance(r,f,this.options.feet,this.options.nautic)),this._tooltip.updateContent({text:this._endLabelText,subtext:_})}}}),L.Edit=L.Edit||{},L.Edit.Marker=L.Handler.extend({initialize:function(n,r){this._marker=n,L.setOptions(this,r)},addHooks:function(){var n=this._marker;n.dragging.enable(),n.on("dragend",this._onDragEnd,n),this._toggleMarkerHighlight()},removeHooks:function(){var n=this._marker;n.dragging.disable(),n.off("dragend",this._onDragEnd,n),this._toggleMarkerHighlight()},_onDragEnd:function(n){var r=n.target;r.edited=!0,this._map.fire(L.Draw.Event.EDITMOVE,{layer:r})},_toggleMarkerHighlight:function(){var n=this._marker._icon;n&&(n.style.display="none",L.DomUtil.hasClass(n,"leaflet-edit-marker-selected")?(L.DomUtil.removeClass(n,"leaflet-edit-marker-selected"),this._offsetMarker(n,-4)):(L.DomUtil.addClass(n,"leaflet-edit-marker-selected"),this._offsetMarker(n,4)),n.style.display="")},_offsetMarker:function(n,r){var a=parseInt(n.style.marginTop,10)-r,u=parseInt(n.style.marginLeft,10)-r;n.style.marginTop=a+"px",n.style.marginLeft=u+"px"}}),L.Marker.addInitHook(function(){L.Edit.Marker&&(this.editing=new L.Edit.Marker(this),this.options.editable&&this.editing.enable())}),L.Edit=L.Edit||{},L.Edit.Poly=L.Handler.extend({initialize:function(n){this.latlngs=[n._latlngs],n._holes&&(this.latlngs=this.latlngs.concat(n._holes)),this._poly=n,this._poly.on("revert-edited",this._updateLatLngs,this)},_defaultShape:function(){return L.Polyline._flat?L.Polyline._flat(this._poly._latlngs)?this._poly._latlngs:this._poly._latlngs[0]:this._poly._latlngs},_eachVertexHandler:function(n){for(var r=0;r<this._verticesHandlers.length;r++)n(this._verticesHandlers[r])},addHooks:function(){this._initHandlers(),this._eachVertexHandler(function(n){n.addHooks()})},removeHooks:function(){this._eachVertexHandler(function(n){n.removeHooks()})},updateMarkers:function(){this._eachVertexHandler(function(n){n.updateMarkers()})},_initHandlers:function(){this._verticesHandlers=[];for(var n=0;n<this.latlngs.length;n++)this._verticesHandlers.push(new L.Edit.PolyVerticesEdit(this._poly,this.latlngs[n],this._poly.options.poly))},_updateLatLngs:function(n){this.latlngs=[n.layer._latlngs],n.layer._holes&&(this.latlngs=this.latlngs.concat(n.layer._holes))}}),L.Edit.PolyVerticesEdit=L.Handler.extend({options:{icon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon"}),touchIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-touch-icon"}),drawError:{color:"#b00b00",timeout:1e3}},initialize:function(n,r,a){L.Browser.touch&&(this.options.icon=this.options.touchIcon),this._poly=n,a&&a.drawError&&(a.drawError=L.Util.extend({},this.options.drawError,a.drawError)),this._latlngs=r,L.setOptions(this,a)},_defaultShape:function(){return L.Polyline._flat?L.Polyline._flat(this._latlngs)?this._latlngs:this._latlngs[0]:this._latlngs},addHooks:function(){var n=this._poly,r=n._path;n instanceof L.Polygon||(n.options.fill=!1,n.options.editing&&(n.options.editing.fill=!1)),r&&n.options.editing&&n.options.editing.className&&(n.options.original.className&&n.options.original.className.split(" ").forEach(function(a){L.DomUtil.removeClass(r,a)}),n.options.editing.className.split(" ").forEach(function(a){L.DomUtil.addClass(r,a)})),n.setStyle(n.options.editing),this._poly._map&&(this._map=this._poly._map,this._markerGroup||this._initMarkers(),this._poly._map.addLayer(this._markerGroup))},removeHooks:function(){var n=this._poly,r=n._path;r&&n.options.editing&&n.options.editing.className&&(n.options.editing.className.split(" ").forEach(function(a){L.DomUtil.removeClass(r,a)}),n.options.original.className&&n.options.original.className.split(" ").forEach(function(a){L.DomUtil.addClass(r,a)})),n.setStyle(n.options.original),n._map&&(n._map.removeLayer(this._markerGroup),delete this._markerGroup,delete this._markers)},updateMarkers:function(){this._markerGroup.clearLayers(),this._initMarkers()},_initMarkers:function(){this._markerGroup||(this._markerGroup=new L.LayerGroup),this._markers=[];var n,r,a,u,f=this._defaultShape();for(n=0,a=f.length;n<a;n++)u=this._createMarker(f[n],n),u.on("click",this._onMarkerClick,this),u.on("contextmenu",this._onContextMenu,this),this._markers.push(u);var _,g;for(n=0,r=a-1;n<a;r=n++)(n!==0||L.Polygon&&this._poly instanceof L.Polygon)&&(_=this._markers[r],g=this._markers[n],this._createMiddleMarker(_,g),this._updatePrevNext(_,g))},_createMarker:function(n,r){var a=new L.Marker.Touch(n,{draggable:!0,icon:this.options.icon});return a._origLatLng=n,a._index=r,a.on("dragstart",this._onMarkerDragStart,this).on("drag",this._onMarkerDrag,this).on("dragend",this._fireEdit,this).on("touchmove",this._onTouchMove,this).on("touchend",this._fireEdit,this).on("MSPointerMove",this._onTouchMove,this).on("MSPointerUp",this._fireEdit,this),this._markerGroup.addLayer(a),a},_onMarkerDragStart:function(){this._poly.fire("editstart")},_spliceLatLngs:function(){var n=this._defaultShape(),r=[].splice.apply(n,arguments);return this._poly._convertLatLngs(n,!0),this._poly.redraw(),r},_removeMarker:function(n){var r=n._index;this._markerGroup.removeLayer(n),this._markers.splice(r,1),this._spliceLatLngs(r,1),this._updateIndexes(r,-1),n.off("dragstart",this._onMarkerDragStart,this).off("drag",this._onMarkerDrag,this).off("dragend",this._fireEdit,this).off("touchmove",this._onMarkerDrag,this).off("touchend",this._fireEdit,this).off("click",this._onMarkerClick,this).off("MSPointerMove",this._onTouchMove,this).off("MSPointerUp",this._fireEdit,this)},_fireEdit:function(){this._poly.edited=!0,this._poly.fire("edit"),this._poly._map.fire(L.Draw.Event.EDITVERTEX,{layers:this._markerGroup,poly:this._poly})},_onMarkerDrag:function(n){var r=n.target,a=this._poly,u=L.LatLngUtil.cloneLatLng(r._origLatLng);if(L.extend(r._origLatLng,r._latlng),a.options.poly){var f=a._map._editTooltip;if(!a.options.poly.allowIntersection&&a.intersects()){L.extend(r._origLatLng,u),r.setLatLng(u);var _=a.options.color;a.setStyle({color:this.options.drawError.color}),f&&f.updateContent({text:L.drawLocal.draw.handlers.polyline.error}),setTimeout(function(){a.setStyle({color:_}),f&&f.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext})},1e3)}}r._middleLeft&&r._middleLeft.setLatLng(this._getMiddleLatLng(r._prev,r)),r._middleRight&&r._middleRight.setLatLng(this._getMiddleLatLng(r,r._next)),this._poly._bounds._southWest=L.latLng(1/0,1/0),this._poly._bounds._northEast=L.latLng(-1/0,-1/0);var g=this._poly.getLatLngs();this._poly._convertLatLngs(g,!0),this._poly.redraw(),this._poly.fire("editdrag")},_onMarkerClick:function(n){var r=L.Polygon&&this._poly instanceof L.Polygon?4:3,a=n.target;this._defaultShape().length<r||(this._removeMarker(a),this._updatePrevNext(a._prev,a._next),a._middleLeft&&this._markerGroup.removeLayer(a._middleLeft),a._middleRight&&this._markerGroup.removeLayer(a._middleRight),a._prev&&a._next?this._createMiddleMarker(a._prev,a._next):a._prev?a._next||(a._prev._middleRight=null):a._next._middleLeft=null,this._fireEdit())},_onContextMenu:function(n){var r=n.target;this._poly,this._poly._map.fire(L.Draw.Event.MARKERCONTEXT,{marker:r,layers:this._markerGroup,poly:this._poly}),L.DomEvent.stopPropagation},_onTouchMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent.touches[0]),a=this._map.layerPointToLatLng(r),u=n.target;L.extend(u._origLatLng,a),u._middleLeft&&u._middleLeft.setLatLng(this._getMiddleLatLng(u._prev,u)),u._middleRight&&u._middleRight.setLatLng(this._getMiddleLatLng(u,u._next)),this._poly.redraw(),this.updateMarkers()},_updateIndexes:function(n,r){this._markerGroup.eachLayer(function(a){a._index>n&&(a._index+=r)})},_createMiddleMarker:function(n,r){var a,u,f,_=this._getMiddleLatLng(n,r),g=this._createMarker(_);g.setOpacity(.6),n._middleRight=r._middleLeft=g,u=function(){g.off("touchmove",u,this);var w=r._index;g._index=w,g.off("click",a,this).on("click",this._onMarkerClick,this),_.lat=g.getLatLng().lat,_.lng=g.getLatLng().lng,this._spliceLatLngs(w,0,_),this._markers.splice(w,0,g),g.setOpacity(1),this._updateIndexes(w,1),r._index++,this._updatePrevNext(n,g),this._updatePrevNext(g,r),this._poly.fire("editstart")},f=function(){g.off("dragstart",u,this),g.off("dragend",f,this),g.off("touchmove",u,this),this._createMiddleMarker(n,g),this._createMiddleMarker(g,r)},a=function(){u.call(this),f.call(this),this._fireEdit()},g.on("click",a,this).on("dragstart",u,this).on("dragend",f,this).on("touchmove",u,this),this._markerGroup.addLayer(g)},_updatePrevNext:function(n,r){n&&(n._next=r),r&&(r._prev=n)},_getMiddleLatLng:function(n,r){var a=this._poly._map,u=a.project(n.getLatLng()),f=a.project(r.getLatLng());return a.unproject(u._add(f)._divideBy(2))}}),L.Polyline.addInitHook(function(){this.editing||(L.Edit.Poly&&(this.editing=new L.Edit.Poly(this),this.options.editable&&this.editing.enable()),this.on("add",function(){this.editing&&this.editing.enabled()&&this.editing.addHooks()}),this.on("remove",function(){this.editing&&this.editing.enabled()&&this.editing.removeHooks()}))}),L.Edit=L.Edit||{},L.Edit.SimpleShape=L.Handler.extend({options:{moveIcon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-move"}),resizeIcon:new L.DivIcon({iconSize:new L.Point(8,8),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-resize"}),touchMoveIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-move leaflet-touch-icon"}),touchResizeIcon:new L.DivIcon({iconSize:new L.Point(20,20),className:"leaflet-div-icon leaflet-editing-icon leaflet-edit-resize leaflet-touch-icon"})},initialize:function(n,r){L.Browser.touch&&(this.options.moveIcon=this.options.touchMoveIcon,this.options.resizeIcon=this.options.touchResizeIcon),this._shape=n,L.Util.setOptions(this,r)},addHooks:function(){var n=this._shape;this._shape._map&&(this._map=this._shape._map,n.setStyle(n.options.editing),n._map&&(this._map=n._map,this._markerGroup||this._initMarkers(),this._map.addLayer(this._markerGroup)))},removeHooks:function(){var n=this._shape;if(n.setStyle(n.options.original),n._map){this._unbindMarker(this._moveMarker);for(var r=0,a=this._resizeMarkers.length;r<a;r++)this._unbindMarker(this._resizeMarkers[r]);this._resizeMarkers=null,this._map.removeLayer(this._markerGroup),delete this._markerGroup}this._map=null},updateMarkers:function(){this._markerGroup.clearLayers(),this._initMarkers()},_initMarkers:function(){this._markerGroup||(this._markerGroup=new L.LayerGroup),this._createMoveMarker(),this._createResizeMarker()},_createMoveMarker:function(){},_createResizeMarker:function(){},_createMarker:function(n,r){var a=new L.Marker.Touch(n,{draggable:!0,icon:r,zIndexOffset:10});return this._bindMarker(a),this._markerGroup.addLayer(a),a},_bindMarker:function(n){n.on("dragstart",this._onMarkerDragStart,this).on("drag",this._onMarkerDrag,this).on("dragend",this._onMarkerDragEnd,this).on("touchstart",this._onTouchStart,this).on("touchmove",this._onTouchMove,this).on("MSPointerMove",this._onTouchMove,this).on("touchend",this._onTouchEnd,this).on("MSPointerUp",this._onTouchEnd,this)},_unbindMarker:function(n){n.off("dragstart",this._onMarkerDragStart,this).off("drag",this._onMarkerDrag,this).off("dragend",this._onMarkerDragEnd,this).off("touchstart",this._onTouchStart,this).off("touchmove",this._onTouchMove,this).off("MSPointerMove",this._onTouchMove,this).off("touchend",this._onTouchEnd,this).off("MSPointerUp",this._onTouchEnd,this)},_onMarkerDragStart:function(n){n.target.setOpacity(0),this._shape.fire("editstart")},_fireEdit:function(){this._shape.edited=!0,this._shape.fire("edit")},_onMarkerDrag:function(n){var r=n.target,a=r.getLatLng();r===this._moveMarker?this._move(a):this._resize(a),this._shape.redraw(),this._shape.fire("editdrag")},_onMarkerDragEnd:function(n){n.target.setOpacity(1),this._fireEdit()},_onTouchStart:function(n){if(L.Edit.SimpleShape.prototype._onMarkerDragStart.call(this,n),typeof this._getCorners=="function"){var r=this._getCorners(),a=n.target,u=a._cornerIndex;a.setOpacity(0),this._oppositeCorner=r[(u+2)%4],this._toggleCornerMarkers(0,u)}this._shape.fire("editstart")},_onTouchMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent.touches[0]),a=this._map.layerPointToLatLng(r);return n.target===this._moveMarker?this._move(a):this._resize(a),this._shape.redraw(),!1},_onTouchEnd:function(n){n.target.setOpacity(1),this.updateMarkers(),this._fireEdit()},_move:function(){},_resize:function(){}}),L.Edit=L.Edit||{},L.Edit.Rectangle=L.Edit.SimpleShape.extend({_createMoveMarker:function(){var n=this._shape.getBounds(),r=n.getCenter();this._moveMarker=this._createMarker(r,this.options.moveIcon)},_createResizeMarker:function(){var n=this._getCorners();this._resizeMarkers=[];for(var r=0,a=n.length;r<a;r++)this._resizeMarkers.push(this._createMarker(n[r],this.options.resizeIcon)),this._resizeMarkers[r]._cornerIndex=r},_onMarkerDragStart:function(n){L.Edit.SimpleShape.prototype._onMarkerDragStart.call(this,n);var r=this._getCorners(),a=n.target,u=a._cornerIndex;this._oppositeCorner=r[(u+2)%4],this._toggleCornerMarkers(0,u)},_onMarkerDragEnd:function(n){var r,a,u=n.target;u===this._moveMarker&&(r=this._shape.getBounds(),a=r.getCenter(),u.setLatLng(a)),this._toggleCornerMarkers(1),this._repositionCornerMarkers(),L.Edit.SimpleShape.prototype._onMarkerDragEnd.call(this,n)},_move:function(n){for(var r,a=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),u=this._shape.getBounds(),f=u.getCenter(),_=[],g=0,w=a.length;g<w;g++)r=[a[g].lat-f.lat,a[g].lng-f.lng],_.push([n.lat+r[0],n.lng+r[1]]);this._shape.setLatLngs(_),this._repositionCornerMarkers(),this._map.fire(L.Draw.Event.EDITMOVE,{layer:this._shape})},_resize:function(n){var r;this._shape.setBounds(L.latLngBounds(n,this._oppositeCorner)),r=this._shape.getBounds(),this._moveMarker.setLatLng(r.getCenter()),this._map.fire(L.Draw.Event.EDITRESIZE,{layer:this._shape})},_getCorners:function(){var n=this._shape.getBounds();return[n.getNorthWest(),n.getNorthEast(),n.getSouthEast(),n.getSouthWest()]},_toggleCornerMarkers:function(n){for(var r=0,a=this._resizeMarkers.length;r<a;r++)this._resizeMarkers[r].setOpacity(n)},_repositionCornerMarkers:function(){for(var n=this._getCorners(),r=0,a=this._resizeMarkers.length;r<a;r++)this._resizeMarkers[r].setLatLng(n[r])}}),L.Rectangle.addInitHook(function(){L.Edit.Rectangle&&(this.editing=new L.Edit.Rectangle(this),this.options.editable&&this.editing.enable())}),L.Edit=L.Edit||{},L.Edit.CircleMarker=L.Edit.SimpleShape.extend({_createMoveMarker:function(){var n=this._shape.getLatLng();this._moveMarker=this._createMarker(n,this.options.moveIcon)},_createResizeMarker:function(){this._resizeMarkers=[]},_move:function(n){if(this._resizeMarkers.length){var r=this._getResizeMarkerPoint(n);this._resizeMarkers[0].setLatLng(r)}this._shape.setLatLng(n),this._map.fire(L.Draw.Event.EDITMOVE,{layer:this._shape})}}),L.CircleMarker.addInitHook(function(){L.Edit.CircleMarker&&(this.editing=new L.Edit.CircleMarker(this),this.options.editable&&this.editing.enable()),this.on("add",function(){this.editing&&this.editing.enabled()&&this.editing.addHooks()}),this.on("remove",function(){this.editing&&this.editing.enabled()&&this.editing.removeHooks()})}),L.Edit=L.Edit||{},L.Edit.Circle=L.Edit.CircleMarker.extend({_createResizeMarker:function(){var n=this._shape.getLatLng(),r=this._getResizeMarkerPoint(n);this._resizeMarkers=[],this._resizeMarkers.push(this._createMarker(r,this.options.resizeIcon))},_getResizeMarkerPoint:function(n){var r=this._shape._radius*Math.cos(Math.PI/4),a=this._map.project(n);return this._map.unproject([a.x+r,a.y-r])},_resize:function(n){var r=this._moveMarker.getLatLng();L.GeometryUtil.isVersion07x()?radius=r.distanceTo(n):radius=this._map.distance(r,n),this._shape.setRadius(radius),this._map.editTooltip&&this._map._editTooltip.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.subtext+"<br />"+L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.draw.handlers.circle.radius+": "+L.GeometryUtil.readableDistance(radius,!0,this.options.feet,this.options.nautic)}),this._shape.setRadius(radius),this._map.fire(L.Draw.Event.EDITRESIZE,{layer:this._shape})}}),L.Circle.addInitHook(function(){L.Edit.Circle&&(this.editing=new L.Edit.Circle(this),this.options.editable&&this.editing.enable())}),L.Map.mergeOptions({touchExtend:!0}),L.Map.TouchExtend=L.Handler.extend({initialize:function(n){this._map=n,this._container=n._container,this._pane=n._panes.overlayPane},addHooks:function(){L.DomEvent.on(this._container,"touchstart",this._onTouchStart,this),L.DomEvent.on(this._container,"touchend",this._onTouchEnd,this),L.DomEvent.on(this._container,"touchmove",this._onTouchMove,this),this._detectIE()?(L.DomEvent.on(this._container,"MSPointerDown",this._onTouchStart,this),L.DomEvent.on(this._container,"MSPointerUp",this._onTouchEnd,this),L.DomEvent.on(this._container,"MSPointerMove",this._onTouchMove,this),L.DomEvent.on(this._container,"MSPointerCancel",this._onTouchCancel,this)):(L.DomEvent.on(this._container,"touchcancel",this._onTouchCancel,this),L.DomEvent.on(this._container,"touchleave",this._onTouchLeave,this))},removeHooks:function(){L.DomEvent.off(this._container,"touchstart",this._onTouchStart,this),L.DomEvent.off(this._container,"touchend",this._onTouchEnd,this),L.DomEvent.off(this._container,"touchmove",this._onTouchMove,this),this._detectIE()?(L.DomEvent.off(this._container,"MSPointerDown",this._onTouchStart,this),L.DomEvent.off(this._container,"MSPointerUp",this._onTouchEnd,this),L.DomEvent.off(this._container,"MSPointerMove",this._onTouchMove,this),L.DomEvent.off(this._container,"MSPointerCancel",this._onTouchCancel,this)):(L.DomEvent.off(this._container,"touchcancel",this._onTouchCancel,this),L.DomEvent.off(this._container,"touchleave",this._onTouchLeave,this))},_touchEvent:function(n,r){var a={};if(n.touches!==void 0){if(!n.touches.length)return;a=n.touches[0]}else if(n.pointerType!=="touch"||(a=n,!this._filterClick(n)))return;var u=this._map.mouseEventToContainerPoint(a),f=this._map.mouseEventToLayerPoint(a),_=this._map.layerPointToLatLng(f);this._map.fire(r,{latlng:_,layerPoint:f,containerPoint:u,pageX:a.pageX,pageY:a.pageY,originalEvent:n})},_filterClick:function(n){var r=n.timeStamp||n.originalEvent.timeStamp,a=L.DomEvent._lastClick&&r-L.DomEvent._lastClick;return a&&a>100&&a<500||n.target._simulatedClick&&!n._simulated?(L.DomEvent.stop(n),!1):(L.DomEvent._lastClick=r,!0)},_onTouchStart:function(n){this._map._loaded&&this._touchEvent(n,"touchstart")},_onTouchEnd:function(n){this._map._loaded&&this._touchEvent(n,"touchend")},_onTouchCancel:function(n){if(this._map._loaded){var r="touchcancel";this._detectIE()&&(r="pointercancel"),this._touchEvent(n,r)}},_onTouchLeave:function(n){this._map._loaded&&this._touchEvent(n,"touchleave")},_onTouchMove:function(n){this._map._loaded&&this._touchEvent(n,"touchmove")},_detectIE:function(){var n=m.navigator.userAgent,r=n.indexOf("MSIE ");if(r>0)return parseInt(n.substring(r+5,n.indexOf(".",r)),10);if(n.indexOf("Trident/")>0){var a=n.indexOf("rv:");return parseInt(n.substring(a+3,n.indexOf(".",a)),10)}var u=n.indexOf("Edge/");return u>0&&parseInt(n.substring(u+5,n.indexOf(".",u)),10)}}),L.Map.addInitHook("addHandler","touchExtend",L.Map.TouchExtend),L.Marker.Touch=L.Marker.extend({_initInteraction:function(){return this.addInteractiveTarget?L.Marker.prototype._initInteraction.apply(this):this._initInteractionLegacy()},_initInteractionLegacy:function(){if(this.options.clickable){var n=this._icon,r=["dblclick","mousedown","mouseover","mouseout","contextmenu","touchstart","touchend","touchmove"];this._detectIE?r.concat(["MSPointerDown","MSPointerUp","MSPointerMove","MSPointerCancel"]):r.concat(["touchcancel"]),L.DomUtil.addClass(n,"leaflet-clickable"),L.DomEvent.on(n,"click",this._onMouseClick,this),L.DomEvent.on(n,"keypress",this._onKeyPress,this);for(var a=0;a<r.length;a++)L.DomEvent.on(n,r[a],this._fireMouseEvent,this);L.Handler.MarkerDrag&&(this.dragging=new L.Handler.MarkerDrag(this),this.options.draggable&&this.dragging.enable())}},_detectIE:function(){var n=m.navigator.userAgent,r=n.indexOf("MSIE ");if(r>0)return parseInt(n.substring(r+5,n.indexOf(".",r)),10);if(n.indexOf("Trident/")>0){var a=n.indexOf("rv:");return parseInt(n.substring(a+3,n.indexOf(".",a)),10)}var u=n.indexOf("Edge/");return u>0&&parseInt(n.substring(u+5,n.indexOf(".",u)),10)}}),L.LatLngUtil={cloneLatLngs:function(n){for(var r=[],a=0,u=n.length;a<u;a++)Array.isArray(n[a])?r.push(L.LatLngUtil.cloneLatLngs(n[a])):r.push(this.cloneLatLng(n[a]));return r},cloneLatLng:function(n){return L.latLng(n.lat,n.lng)}},(function(){var n={km:2,ha:2,m:0,mi:2,ac:2,yd:0,ft:0,nm:2};L.GeometryUtil=L.extend(L.GeometryUtil||{},{geodesicArea:function(r){var a,u,f=r.length,_=0,g=Math.PI/180;if(f>2){for(var w=0;w<f;w++)a=r[w],u=r[(w+1)%f],_+=(u.lng-a.lng)*g*(2+Math.sin(a.lat*g)+Math.sin(u.lat*g));_=6378137*_*6378137/2}return Math.abs(_)},formattedNumber:function(r,a){var u=parseFloat(r).toFixed(a),f=L.drawLocal.format&&L.drawLocal.format.numeric,_=f&&f.delimiters,g=_&&_.thousands,w=_&&_.decimal;if(g||w){var x=u.split(".");u=g?x[0].replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+g):x[0],w=w||".",x.length>1&&(u=u+w+x[1])}return u},readableArea:function(r,a,g){var f,_,g=L.Util.extend({},n,g);return a?(_=["ha","m"],type=typeof a,type==="string"?_=[a]:type!=="boolean"&&(_=a),f=r>=1e6&&_.indexOf("km")!==-1?L.GeometryUtil.formattedNumber(1e-6*r,g.km)+" km²":r>=1e4&&_.indexOf("ha")!==-1?L.GeometryUtil.formattedNumber(1e-4*r,g.ha)+" ha":L.GeometryUtil.formattedNumber(r,g.m)+" m²"):(r/=.836127,f=r>=3097600?L.GeometryUtil.formattedNumber(r/3097600,g.mi)+" mi²":r>=4840?L.GeometryUtil.formattedNumber(r/4840,g.ac)+" acres":L.GeometryUtil.formattedNumber(r,g.yd)+" yd²"),f},readableDistance:function(r,a,u,f,w){var g,w=L.Util.extend({},n,w);switch(a?typeof a=="string"?a:"metric":u?"feet":f?"nauticalMile":"yards"){case"metric":g=r>1e3?L.GeometryUtil.formattedNumber(r/1e3,w.km)+" km":L.GeometryUtil.formattedNumber(r,w.m)+" m";break;case"feet":r*=3.28083,g=L.GeometryUtil.formattedNumber(r,w.ft)+" ft";break;case"nauticalMile":r*=.53996,g=L.GeometryUtil.formattedNumber(r/1e3,w.nm)+" nm";break;case"yards":default:r*=1.09361,g=r>1760?L.GeometryUtil.formattedNumber(r/1760,w.mi)+" miles":L.GeometryUtil.formattedNumber(r,w.yd)+" yd"}return g},isVersion07x:function(){var r=L.version.split(".");return parseInt(r[0],10)===0&&parseInt(r[1],10)===7}})})(),L.Util.extend(L.LineUtil,{segmentsIntersect:function(n,r,a,u){return this._checkCounterclockwise(n,a,u)!==this._checkCounterclockwise(r,a,u)&&this._checkCounterclockwise(n,r,a)!==this._checkCounterclockwise(n,r,u)},_checkCounterclockwise:function(n,r,a){return(a.y-n.y)*(r.x-n.x)>(r.y-n.y)*(a.x-n.x)}}),L.Polyline.include({intersects:function(){var n,r,a,u=this._getProjectedPoints(),f=u?u.length:0;if(this._tooFewPointsForIntersection())return!1;for(n=f-1;n>=3;n--)if(r=u[n-1],a=u[n],this._lineSegmentsIntersectsRange(r,a,n-2))return!0;return!1},newLatLngIntersects:function(n,r){return!!this._map&&this.newPointIntersects(this._map.latLngToLayerPoint(n),r)},newPointIntersects:function(n,r){var a=this._getProjectedPoints(),u=a?a.length:0,f=a?a[u-1]:null,_=u-2;return!this._tooFewPointsForIntersection(1)&&this._lineSegmentsIntersectsRange(f,n,_,r?1:0)},_tooFewPointsForIntersection:function(n){var r=this._getProjectedPoints(),a=r?r.length:0;return a+=n||0,!r||a<=3},_lineSegmentsIntersectsRange:function(n,r,a,u){var f,_,g=this._getProjectedPoints();u=u||0;for(var w=a;w>u;w--)if(f=g[w-1],_=g[w],L.LineUtil.segmentsIntersect(n,r,f,_))return!0;return!1},_getProjectedPoints:function(){if(!this._defaultShape)return this._originalPoints;for(var n=[],r=this._defaultShape(),a=0;a<r.length;a++)n.push(this._map.latLngToLayerPoint(r[a]));return n}}),L.Polygon.include({intersects:function(){var n,r,a,u,f=this._getProjectedPoints();return!this._tooFewPointsForIntersection()&&(!!L.Polyline.prototype.intersects.call(this)||(n=f.length,r=f[0],a=f[n-1],u=n-2,this._lineSegmentsIntersectsRange(a,r,u,1)))}}),L.Control.Draw=L.Control.extend({options:{position:"topleft",draw:{},edit:!1},initialize:function(n){if(L.version<"0.7")throw new Error("Leaflet.draw 0.2.3+ requires Leaflet 0.7.0+. Download latest from https://github.com/Leaflet/Leaflet/");L.Control.prototype.initialize.call(this,n);var r;this._toolbars={},L.DrawToolbar&&this.options.draw&&(r=new L.DrawToolbar(this.options.draw),this._toolbars[L.DrawToolbar.TYPE]=r,this._toolbars[L.DrawToolbar.TYPE].on("enable",this._toolbarEnabled,this)),L.EditToolbar&&this.options.edit&&(r=new L.EditToolbar(this.options.edit),this._toolbars[L.EditToolbar.TYPE]=r,this._toolbars[L.EditToolbar.TYPE].on("enable",this._toolbarEnabled,this)),L.toolbar=this},onAdd:function(n){var r,a=L.DomUtil.create("div","leaflet-draw"),u=!1;for(var f in this._toolbars)this._toolbars.hasOwnProperty(f)&&(r=this._toolbars[f].addToolbar(n))&&(u||(L.DomUtil.hasClass(r,"leaflet-draw-toolbar-top")||L.DomUtil.addClass(r.childNodes[0],"leaflet-draw-toolbar-top"),u=!0),a.appendChild(r));return a},onRemove:function(){for(var n in this._toolbars)this._toolbars.hasOwnProperty(n)&&this._toolbars[n].removeToolbar()},setDrawingOptions:function(n){for(var r in this._toolbars)this._toolbars[r]instanceof L.DrawToolbar&&this._toolbars[r].setOptions(n)},_toolbarEnabled:function(n){var r=n.target;for(var a in this._toolbars)this._toolbars[a]!==r&&this._toolbars[a].disable()}}),L.Map.mergeOptions({drawControlTooltips:!0,drawControl:!1}),L.Map.addInitHook(function(){this.options.drawControl&&(this.drawControl=new L.Control.Draw,this.addControl(this.drawControl))}),L.Toolbar=L.Class.extend({initialize:function(n){L.setOptions(this,n),this._modes={},this._actionButtons=[],this._activeMode=null;var r=L.version.split(".");parseInt(r[0],10)===1&&parseInt(r[1],10)>=2?L.Toolbar.include(L.Evented.prototype):L.Toolbar.include(L.Mixin.Events)},enabled:function(){return this._activeMode!==null},disable:function(){this.enabled()&&this._activeMode.handler.disable()},addToolbar:function(n){var r,a=L.DomUtil.create("div","leaflet-draw-section"),u=0,f=this._toolbarClass||"",_=this.getModeHandlers(n);for(this._toolbarContainer=L.DomUtil.create("div","leaflet-draw-toolbar leaflet-bar"),this._map=n,r=0;r<_.length;r++)_[r].enabled&&this._initModeHandler(_[r].handler,this._toolbarContainer,u++,f,_[r].title);if(u)return this._lastButtonIndex=--u,this._actionsContainer=L.DomUtil.create("ul","leaflet-draw-actions"),a.appendChild(this._toolbarContainer),a.appendChild(this._actionsContainer),a},removeToolbar:function(){for(var n in this._modes)this._modes.hasOwnProperty(n)&&(this._disposeButton(this._modes[n].button,this._modes[n].handler.enable,this._modes[n].handler),this._modes[n].handler.disable(),this._modes[n].handler.off("enabled",this._handlerActivated,this).off("disabled",this._handlerDeactivated,this));this._modes={};for(var r=0,a=this._actionButtons.length;r<a;r++)this._disposeButton(this._actionButtons[r].button,this._actionButtons[r].callback,this);this._actionButtons=[],this._actionsContainer=null},_initModeHandler:function(n,r,a,u,f){var _=n.type;this._modes[_]={},this._modes[_].handler=n,this._modes[_].button=this._createButton({type:_,title:f,className:u+"-"+_,container:r,callback:this._modes[_].handler.enable,context:this._modes[_].handler}),this._modes[_].buttonIndex=a,this._modes[_].handler.on("enabled",this._handlerActivated,this).on("disabled",this._handlerDeactivated,this)},_detectIOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!m.MSStream},_createButton:function(n){var r=L.DomUtil.create("a",n.className||"",n.container),a=L.DomUtil.create("span","sr-only",n.container);r.href="#",r.appendChild(a),n.title&&(r.title=n.title,a.innerHTML=n.title),n.text&&(r.innerHTML=n.text,a.innerHTML=n.text);var u=this._detectIOS()?"touchstart":"click";return L.DomEvent.on(r,"click",L.DomEvent.stopPropagation).on(r,"mousedown",L.DomEvent.stopPropagation).on(r,"dblclick",L.DomEvent.stopPropagation).on(r,"touchstart",L.DomEvent.stopPropagation).on(r,"click",L.DomEvent.preventDefault).on(r,u,n.callback,n.context),r},_disposeButton:function(n,r){var a=this._detectIOS()?"touchstart":"click";L.DomEvent.off(n,"click",L.DomEvent.stopPropagation).off(n,"mousedown",L.DomEvent.stopPropagation).off(n,"dblclick",L.DomEvent.stopPropagation).off(n,"touchstart",L.DomEvent.stopPropagation).off(n,"click",L.DomEvent.preventDefault).off(n,a,r)},_handlerActivated:function(n){this.disable(),this._activeMode=this._modes[n.handler],L.DomUtil.addClass(this._activeMode.button,"leaflet-draw-toolbar-button-enabled"),this._showActionsToolbar(),this.fire("enable")},_handlerDeactivated:function(){this._hideActionsToolbar(),L.DomUtil.removeClass(this._activeMode.button,"leaflet-draw-toolbar-button-enabled"),this._activeMode=null,this.fire("disable")},_createActions:function(n){var r,a,u,f,_=this._actionsContainer,g=this.getActions(n),w=g.length;for(a=0,u=this._actionButtons.length;a<u;a++)this._disposeButton(this._actionButtons[a].button,this._actionButtons[a].callback);for(this._actionButtons=[];_.firstChild;)_.removeChild(_.firstChild);for(var x=0;x<w;x++)"enabled"in g[x]&&!g[x].enabled||(r=L.DomUtil.create("li","",_),f=this._createButton({title:g[x].title,text:g[x].text,container:r,callback:g[x].callback,context:g[x].context}),this._actionButtons.push({button:f,callback:g[x].callback}))},_showActionsToolbar:function(){var n=this._activeMode.buttonIndex,r=this._lastButtonIndex,a=this._activeMode.button.offsetTop-1;this._createActions(this._activeMode.handler),this._actionsContainer.style.top=a+"px",n===0&&(L.DomUtil.addClass(this._toolbarContainer,"leaflet-draw-toolbar-notop"),L.DomUtil.addClass(this._actionsContainer,"leaflet-draw-actions-top")),n===r&&(L.DomUtil.addClass(this._toolbarContainer,"leaflet-draw-toolbar-nobottom"),L.DomUtil.addClass(this._actionsContainer,"leaflet-draw-actions-bottom")),this._actionsContainer.style.display="block",this._map.fire(L.Draw.Event.TOOLBAROPENED)},_hideActionsToolbar:function(){this._actionsContainer.style.display="none",L.DomUtil.removeClass(this._toolbarContainer,"leaflet-draw-toolbar-notop"),L.DomUtil.removeClass(this._toolbarContainer,"leaflet-draw-toolbar-nobottom"),L.DomUtil.removeClass(this._actionsContainer,"leaflet-draw-actions-top"),L.DomUtil.removeClass(this._actionsContainer,"leaflet-draw-actions-bottom"),this._map.fire(L.Draw.Event.TOOLBARCLOSED)}}),L.Draw=L.Draw||{},L.Draw.Tooltip=L.Class.extend({initialize:function(n){this._map=n,this._popupPane=n._panes.popupPane,this._visible=!1,this._container=n.options.drawControlTooltips?L.DomUtil.create("div","leaflet-draw-tooltip",this._popupPane):null,this._singleLineLabel=!1,this._map.on("mouseout",this._onMouseOut,this)},dispose:function(){this._map.off("mouseout",this._onMouseOut,this),this._container&&(this._popupPane.removeChild(this._container),this._container=null)},updateContent:function(n){return this._container?(n.subtext=n.subtext||"",n.subtext.length!==0||this._singleLineLabel?n.subtext.length>0&&this._singleLineLabel&&(L.DomUtil.removeClass(this._container,"leaflet-draw-tooltip-single"),this._singleLineLabel=!1):(L.DomUtil.addClass(this._container,"leaflet-draw-tooltip-single"),this._singleLineLabel=!0),this._container.innerHTML=(n.subtext.length>0?'<span class="leaflet-draw-tooltip-subtext">'+n.subtext+"</span><br />":"")+"<span>"+n.text+"</span>",n.text||n.subtext?(this._visible=!0,this._container.style.visibility="inherit"):(this._visible=!1,this._container.style.visibility="hidden"),this):this},updatePosition:function(n){var r=this._map.latLngToLayerPoint(n),a=this._container;return this._container&&(this._visible&&(a.style.visibility="inherit"),L.DomUtil.setPosition(a,r)),this},showAsError:function(){return this._container&&L.DomUtil.addClass(this._container,"leaflet-error-draw-tooltip"),this},removeError:function(){return this._container&&L.DomUtil.removeClass(this._container,"leaflet-error-draw-tooltip"),this},_onMouseOut:function(){this._container&&(this._container.style.visibility="hidden")}}),L.DrawToolbar=L.Toolbar.extend({statics:{TYPE:"draw"},options:{polyline:{},polygon:{},rectangle:{},circle:{},marker:{},circlemarker:{}},initialize:function(n){for(var r in this.options)this.options.hasOwnProperty(r)&&n[r]&&(n[r]=L.extend({},this.options[r],n[r]));this._toolbarClass="leaflet-draw-draw",L.Toolbar.prototype.initialize.call(this,n)},getModeHandlers:function(n){return[{enabled:this.options.polyline,handler:new L.Draw.Polyline(n,this.options.polyline),title:L.drawLocal.draw.toolbar.buttons.polyline},{enabled:this.options.polygon,handler:new L.Draw.Polygon(n,this.options.polygon),title:L.drawLocal.draw.toolbar.buttons.polygon},{enabled:this.options.rectangle,handler:new L.Draw.Rectangle(n,this.options.rectangle),title:L.drawLocal.draw.toolbar.buttons.rectangle},{enabled:this.options.circle,handler:new L.Draw.Circle(n,this.options.circle),title:L.drawLocal.draw.toolbar.buttons.circle},{enabled:this.options.marker,handler:new L.Draw.Marker(n,this.options.marker),title:L.drawLocal.draw.toolbar.buttons.marker},{enabled:this.options.circlemarker,handler:new L.Draw.CircleMarker(n,this.options.circlemarker),title:L.drawLocal.draw.toolbar.buttons.circlemarker}]},getActions:function(n){return[{enabled:n.completeShape,title:L.drawLocal.draw.toolbar.finish.title,text:L.drawLocal.draw.toolbar.finish.text,callback:n.completeShape,context:n},{enabled:n.deleteLastVertex,title:L.drawLocal.draw.toolbar.undo.title,text:L.drawLocal.draw.toolbar.undo.text,callback:n.deleteLastVertex,context:n},{title:L.drawLocal.draw.toolbar.actions.title,text:L.drawLocal.draw.toolbar.actions.text,callback:this.disable,context:this}]},setOptions:function(n){L.setOptions(this,n);for(var r in this._modes)this._modes.hasOwnProperty(r)&&n.hasOwnProperty(r)&&this._modes[r].handler.setOptions(n[r])}}),L.EditToolbar=L.Toolbar.extend({statics:{TYPE:"edit"},options:{edit:{selectedPathOptions:{dashArray:"10, 10",fill:!0,fillColor:"#fe57a1",fillOpacity:.1,maintainColor:!1}},remove:{},poly:null,featureGroup:null},initialize:function(n){n.edit&&(n.edit.selectedPathOptions===void 0&&(n.edit.selectedPathOptions=this.options.edit.selectedPathOptions),n.edit.selectedPathOptions=L.extend({},this.options.edit.selectedPathOptions,n.edit.selectedPathOptions)),n.remove&&(n.remove=L.extend({},this.options.remove,n.remove)),n.poly&&(n.poly=L.extend({},this.options.poly,n.poly)),this._toolbarClass="leaflet-draw-edit",L.Toolbar.prototype.initialize.call(this,n),this._selectedFeatureCount=0},getModeHandlers:function(n){var r=this.options.featureGroup;return[{enabled:this.options.edit,handler:new L.EditToolbar.Edit(n,{featureGroup:r,selectedPathOptions:this.options.edit.selectedPathOptions,poly:this.options.poly}),title:L.drawLocal.edit.toolbar.buttons.edit},{enabled:this.options.remove,handler:new L.EditToolbar.Delete(n,{featureGroup:r}),title:L.drawLocal.edit.toolbar.buttons.remove}]},getActions:function(n){var r=[{title:L.drawLocal.edit.toolbar.actions.save.title,text:L.drawLocal.edit.toolbar.actions.save.text,callback:this._save,context:this},{title:L.drawLocal.edit.toolbar.actions.cancel.title,text:L.drawLocal.edit.toolbar.actions.cancel.text,callback:this.disable,context:this}];return n.removeAllLayers&&r.push({title:L.drawLocal.edit.toolbar.actions.clearAll.title,text:L.drawLocal.edit.toolbar.actions.clearAll.text,callback:this._clearAllLayers,context:this}),r},addToolbar:function(n){var r=L.Toolbar.prototype.addToolbar.call(this,n);return this._checkDisabled(),this.options.featureGroup.on("layeradd layerremove",this._checkDisabled,this),r},removeToolbar:function(){this.options.featureGroup.off("layeradd layerremove",this._checkDisabled,this),L.Toolbar.prototype.removeToolbar.call(this)},disable:function(){this.enabled()&&(this._activeMode.handler.revertLayers(),L.Toolbar.prototype.disable.call(this))},_save:function(){this._activeMode.handler.save(),this._activeMode&&this._activeMode.handler.disable()},_clearAllLayers:function(){this._activeMode.handler.removeAllLayers(),this._activeMode&&this._activeMode.handler.disable()},_checkDisabled:function(){var n,r=this.options.featureGroup,a=r.getLayers().length!==0;this.options.edit&&(n=this._modes[L.EditToolbar.Edit.TYPE].button,a?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",a?L.drawLocal.edit.toolbar.buttons.edit:L.drawLocal.edit.toolbar.buttons.editDisabled)),this.options.remove&&(n=this._modes[L.EditToolbar.Delete.TYPE].button,a?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",a?L.drawLocal.edit.toolbar.buttons.remove:L.drawLocal.edit.toolbar.buttons.removeDisabled))}}),L.EditToolbar.Edit=L.Handler.extend({statics:{TYPE:"edit"},initialize:function(n,r){if(L.Handler.prototype.initialize.call(this,n),L.setOptions(this,r),this._featureGroup=r.featureGroup,!(this._featureGroup instanceof L.FeatureGroup))throw new Error("options.featureGroup must be a L.FeatureGroup");this._uneditedLayerProps={},this.type=L.EditToolbar.Edit.TYPE;var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.EditToolbar.Edit.include(L.Evented.prototype):L.EditToolbar.Edit.include(L.Mixin.Events)},enable:function(){!this._enabled&&this._hasAvailableLayers()&&(this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.EDITSTART,{handler:this.type}),L.Handler.prototype.enable.call(this),this._featureGroup.on("layeradd",this._enableLayerEdit,this).on("layerremove",this._disableLayerEdit,this))},disable:function(){this._enabled&&(this._featureGroup.off("layeradd",this._enableLayerEdit,this).off("layerremove",this._disableLayerEdit,this),L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.EDITSTOP,{handler:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(n.getContainer().focus(),this._featureGroup.eachLayer(this._enableLayerEdit,this),this._tooltip=new L.Draw.Tooltip(this._map),this._tooltip.updateContent({text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext}),n._editTooltip=this._tooltip,this._updateTooltip(),this._map.on("mousemove",this._onMouseMove,this).on("touchmove",this._onMouseMove,this).on("MSPointerMove",this._onMouseMove,this).on(L.Draw.Event.EDITVERTEX,this._updateTooltip,this))},removeHooks:function(){this._map&&(this._featureGroup.eachLayer(this._disableLayerEdit,this),this._uneditedLayerProps={},this._tooltip.dispose(),this._tooltip=null,this._map.off("mousemove",this._onMouseMove,this).off("touchmove",this._onMouseMove,this).off("MSPointerMove",this._onMouseMove,this).off(L.Draw.Event.EDITVERTEX,this._updateTooltip,this))},revertLayers:function(){this._featureGroup.eachLayer(function(n){this._revertLayer(n)},this)},save:function(){var n=new L.LayerGroup;this._featureGroup.eachLayer(function(r){r.edited&&(n.addLayer(r),r.edited=!1)}),this._map.fire(L.Draw.Event.EDITED,{layers:n})},_backupLayer:function(n){var r=L.Util.stamp(n);this._uneditedLayerProps[r]||(n instanceof L.Polyline||n instanceof L.Polygon||n instanceof L.Rectangle?this._uneditedLayerProps[r]={latlngs:L.LatLngUtil.cloneLatLngs(n.getLatLngs())}:n instanceof L.Circle?this._uneditedLayerProps[r]={latlng:L.LatLngUtil.cloneLatLng(n.getLatLng()),radius:n.getRadius()}:(n instanceof L.Marker||n instanceof L.CircleMarker)&&(this._uneditedLayerProps[r]={latlng:L.LatLngUtil.cloneLatLng(n.getLatLng())}))},_getTooltipText:function(){return{text:L.drawLocal.edit.handlers.edit.tooltip.text,subtext:L.drawLocal.edit.handlers.edit.tooltip.subtext}},_updateTooltip:function(){this._tooltip.updateContent(this._getTooltipText())},_revertLayer:function(n){var r=L.Util.stamp(n);n.edited=!1,this._uneditedLayerProps.hasOwnProperty(r)&&(n instanceof L.Polyline||n instanceof L.Polygon||n instanceof L.Rectangle?n.setLatLngs(this._uneditedLayerProps[r].latlngs):n instanceof L.Circle?(n.setLatLng(this._uneditedLayerProps[r].latlng),n.setRadius(this._uneditedLayerProps[r].radius)):(n instanceof L.Marker||n instanceof L.CircleMarker)&&n.setLatLng(this._uneditedLayerProps[r].latlng),n.fire("revert-edited",{layer:n}))},_enableLayerEdit:function(n){var r,a,u=n.layer||n.target||n;this._backupLayer(u),this.options.poly&&(a=L.Util.extend({},this.options.poly),u.options.poly=a),this.options.selectedPathOptions&&(r=L.Util.extend({},this.options.selectedPathOptions),r.maintainColor&&(r.color=u.options.color,r.fillColor=u.options.fillColor),u.options.original=L.extend({},u.options),u.options.editing=r),u instanceof L.Marker?(u.editing&&u.editing.enable(),u.dragging.enable(),u.on("dragend",this._onMarkerDragEnd).on("touchmove",this._onTouchMove,this).on("MSPointerMove",this._onTouchMove,this).on("touchend",this._onMarkerDragEnd,this).on("MSPointerUp",this._onMarkerDragEnd,this)):u.editing.enable()},_disableLayerEdit:function(n){var r=n.layer||n.target||n;r.edited=!1,r.editing&&r.editing.disable(),delete r.options.editing,delete r.options.original,this._selectedPathOptions&&(r instanceof L.Marker?this._toggleMarkerHighlight(r):(r.setStyle(r.options.previousOptions),delete r.options.previousOptions)),r instanceof L.Marker?(r.dragging.disable(),r.off("dragend",this._onMarkerDragEnd,this).off("touchmove",this._onTouchMove,this).off("MSPointerMove",this._onTouchMove,this).off("touchend",this._onMarkerDragEnd,this).off("MSPointerUp",this._onMarkerDragEnd,this)):r.editing.disable()},_onMouseMove:function(n){this._tooltip.updatePosition(n.latlng)},_onMarkerDragEnd:function(n){var r=n.target;r.edited=!0,this._map.fire(L.Draw.Event.EDITMOVE,{layer:r})},_onTouchMove:function(n){var r=n.originalEvent.changedTouches[0],a=this._map.mouseEventToLayerPoint(r),u=this._map.layerPointToLatLng(a);n.target.setLatLng(u)},_hasAvailableLayers:function(){return this._featureGroup.getLayers().length!==0}}),L.EditToolbar.Delete=L.Handler.extend({statics:{TYPE:"remove"},initialize:function(n,r){if(L.Handler.prototype.initialize.call(this,n),L.Util.setOptions(this,r),this._deletableLayers=this.options.featureGroup,!(this._deletableLayers instanceof L.FeatureGroup))throw new Error("options.featureGroup must be a L.FeatureGroup");this.type=L.EditToolbar.Delete.TYPE;var a=L.version.split(".");parseInt(a[0],10)===1&&parseInt(a[1],10)>=2?L.EditToolbar.Delete.include(L.Evented.prototype):L.EditToolbar.Delete.include(L.Mixin.Events)},enable:function(){!this._enabled&&this._hasAvailableLayers()&&(this.fire("enabled",{handler:this.type}),this._map.fire(L.Draw.Event.DELETESTART,{handler:this.type}),L.Handler.prototype.enable.call(this),this._deletableLayers.on("layeradd",this._enableLayerDelete,this).on("layerremove",this._disableLayerDelete,this))},disable:function(){this._enabled&&(this._deletableLayers.off("layeradd",this._enableLayerDelete,this).off("layerremove",this._disableLayerDelete,this),L.Handler.prototype.disable.call(this),this._map.fire(L.Draw.Event.DELETESTOP,{handler:this.type}),this.fire("disabled",{handler:this.type}))},addHooks:function(){var n=this._map;n&&(n.getContainer().focus(),this._deletableLayers.eachLayer(this._enableLayerDelete,this),this._deletedLayers=new L.LayerGroup,this._tooltip=new L.Draw.Tooltip(this._map),this._tooltip.updateContent({text:L.drawLocal.edit.handlers.remove.tooltip.text}),this._map.on("mousemove",this._onMouseMove,this))},removeHooks:function(){this._map&&(this._deletableLayers.eachLayer(this._disableLayerDelete,this),this._deletedLayers=null,this._tooltip.dispose(),this._tooltip=null,this._map.off("mousemove",this._onMouseMove,this))},revertLayers:function(){this._deletedLayers.eachLayer(function(n){this._deletableLayers.addLayer(n),n.fire("revert-deleted",{layer:n})},this)},save:function(){this._map.fire(L.Draw.Event.DELETED,{layers:this._deletedLayers})},removeAllLayers:function(){this._deletableLayers.eachLayer(function(n){this._removeLayer({layer:n})},this),this.save()},_enableLayerDelete:function(n){(n.layer||n.target||n).on("click",this._removeLayer,this)},_disableLayerDelete:function(n){var r=n.layer||n.target||n;r.off("click",this._removeLayer,this),this._deletedLayers.removeLayer(r)},_removeLayer:function(n){var r=n.layer||n.target||n;this._deletableLayers.removeLayer(r),this._deletedLayers.addLayer(r),r.fire("deleted")},_onMouseMove:function(n){this._tooltip.updatePosition(n.latlng)},_hasAvailableLayers:function(){return this._deletableLayers.getLayers().length!==0}})})(window,document);var Ye={exports:{}},Ni;function To(){return Ni||(Ni=1,(function(m,c){(function(s,h){m.exports=s(Ri()),typeof h!="undefined"&&h.L&&(h.L.Ruler=s(L))})(function(s){s.Control.Ruler=s.Control.extend({options:{position:"topright",circleMarker:{color:"red",radius:2},lineStyle:{color:"red",dashArray:"1,6"},lengthUnit:{display:"km",decimal:2,factor:null,label:"Distance:"},angleUnit:{display:"°",decimal:2,factor:null,label:"Bearing:"}},onAdd:function(h){return this._map=h,this._container=s.DomUtil.create("div","leaflet-bar"),this._container.classList.add("leaflet-ruler"),s.DomEvent.disableClickPropagation(this._container),s.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._choice=!1,this._defaultCursor=this._map._container.style.cursor,this._allLayers=s.layerGroup(),this._container},onRemove:function(){s.DomEvent.off(this._container,"click",this._toggleMeasure,this)},_toggleMeasure:function(){this._choice=!this._choice,this._clickedLatLong=null,this._clickedPoints=[],this._totalLength=0,this._choice?(this._map.doubleClickZoom.disable(),s.DomEvent.on(this._map._container,"keydown",this._escape,this),s.DomEvent.on(this._map._container,"dblclick",this._closePath,this),this._container.classList.add("leaflet-ruler-clicked"),this._clickCount=0,this._tempLine=s.featureGroup().addTo(this._allLayers),this._tempPoint=s.featureGroup().addTo(this._allLayers),this._pointLayer=s.featureGroup().addTo(this._allLayers),this._polylineLayer=s.featureGroup().addTo(this._allLayers),this._allLayers.addTo(this._map),this._map._container.style.cursor="crosshair",this._map.on("click",this._clicked,this),this._map.on("mousemove",this._moving,this)):(this._map.doubleClickZoom.enable(),s.DomEvent.off(this._map._container,"keydown",this._escape,this),s.DomEvent.off(this._map._container,"dblclick",this._closePath,this),this._container.classList.remove("leaflet-ruler-clicked"),this._map.removeLayer(this._allLayers),this._allLayers=s.layerGroup(),this._map._container.style.cursor=this._defaultCursor,this._map.off("click",this._clicked,this),this._map.off("mousemove",this._moving,this))},_clicked:function(h){if(this._clickedLatLong=h.latlng,this._clickedPoints.push(this._clickedLatLong),s.circleMarker(this._clickedLatLong,this.options.circleMarker).addTo(this._pointLayer),this._clickCount>0&&!h.latlng.equals(this._clickedPoints[this._clickedPoints.length-2])){this._movingLatLong&&s.polyline([this._clickedPoints[this._clickCount-1],this._movingLatLong],this.options.lineStyle).addTo(this._polylineLayer);var n;this._totalLength+=this._result.Distance,this._clickCount>1?n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._totalLength.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display:n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display,s.circleMarker(this._clickedLatLong,this.options.circleMarker).bindTooltip(n,{permanent:!0,className:"result-tooltip"}).addTo(this._pointLayer).openTooltip()}this._clickCount++},_moving:function(h){if(this._clickedLatLong){s.DomEvent.off(this._container,"click",this._toggleMeasure,this),this._movingLatLong=h.latlng,this._tempLine&&(this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint));var n;this._addedLength=0,this._tempLine=s.featureGroup(),this._tempPoint=s.featureGroup(),this._tempLine.addTo(this._map),this._tempPoint.addTo(this._map),this._calculateBearingAndDistance(),this._addedLength=this._result.Distance+this._totalLength,s.polyline([this._clickedLatLong,this._movingLatLong],this.options.lineStyle).addTo(this._tempLine),this._clickCount>1?n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._addedLength.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display+'<br><div class="plus-length">(+'+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+")</div>":n="<b>"+this.options.angleUnit.label+"</b> "+this._result.Bearing.toFixed(this.options.angleUnit.decimal)+" "+this.options.angleUnit.display+"<br><b>"+this.options.lengthUnit.label+"</b> "+this._result.Distance.toFixed(this.options.lengthUnit.decimal)+" "+this.options.lengthUnit.display,s.circleMarker(this._movingLatLong,this.options.circleMarker).bindTooltip(n,{sticky:!0,offset:s.point(0,-40),className:"moving-tooltip"}).addTo(this._tempPoint).openTooltip()}},_escape:function(h){h.keyCode===27&&(this._clickCount>0?this._closePath():(this._choice=!0,this._toggleMeasure()))},_calculateBearingAndDistance:function(){var h=this._clickedLatLong.lat,n=this._clickedLatLong.lng,r=this._movingLatLong.lat,a=this._movingLatLong.lng,u=Math.PI/180,f=Math.sin((a-n)*u)*Math.cos(r*u),_=Math.cos(h*u)*Math.sin(r*u)-Math.sin(h*u)*Math.cos(r*u)*Math.cos((a-n)*u),g=Math.atan2(f,_)*((this.options.angleUnit.factor?this.options.angleUnit.factor/2:180)/Math.PI);g+=g<0?this.options.angleUnit.factor?this.options.angleUnit.factor:360:0;var w=this.options.lengthUnit.factor?6371*this.options.lengthUnit.factor:6371,x=(r-h)*u,M=(a-n)*u,E=Math.sin(x/2)*Math.sin(x/2)+Math.cos(h*u)*Math.cos(r*u)*Math.sin(M/2)*Math.sin(M/2),P=2*Math.atan2(Math.sqrt(E),Math.sqrt(1-E)),U=w*P;this._result={Bearing:g,Distance:U}},_closePath:function(){this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint),this._clickCount<=1&&this._map.removeLayer(this._pointLayer),this._choice=!1,s.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._toggleMeasure()}}),s.control.ruler=function(h){return new s.Control.Ruler(h)}},window)})(Ye)),Ye.exports}To();let Le;const Co=new Uint8Array(16);function So(){if(!Le&&(Le=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Le))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Le(Co)}const it=[];for(let m=0;m<256;++m)it.push((m+256).toString(16).slice(1));function Do(m,c=0){return it[m[c+0]]+it[m[c+1]]+it[m[c+2]]+it[m[c+3]]+"-"+it[m[c+4]]+it[m[c+5]]+"-"+it[m[c+6]]+it[m[c+7]]+"-"+it[m[c+8]]+it[m[c+9]]+"-"+it[m[c+10]]+it[m[c+11]]+it[m[c+12]]+it[m[c+13]]+it[m[c+14]]+it[m[c+15]]}const Zi={randomUUID:typeof crypto!="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function qe(m,c,s){if(Zi.randomUUID&&!m)return Zi.randomUUID();m=m||{};const h=m.random||(m.rng||So)();return h[6]=h[6]&15|64,h[8]=h[8]&63|128,Do(h)}function Io(m){var s,h;const c=(h=m.id)!=null?h:(s=m.properties)==null?void 0:s.id;if(c!=null)return String(c)}function zo(m,c){const s=h=>{switch(h.type){case"Point":c(h.coordinates);break;case"MultiPoint":case"LineString":for(const n of h.coordinates)c(n);break;case"MultiLineString":case"Polygon":for(const n of h.coordinates)for(const r of n)c(r);break;case"MultiPolygon":for(const n of h.coordinates)for(const r of n)for(const a of r)c(a);break;case"GeometryCollection":for(const n of h.geometries)s(n);break}};s(m)}function Oo(m){const c=m.geometry;if(!c)return null;let s=1/0,h=1/0,n=-1/0,r=-1/0,a=!1;return zo(c,u=>{const[f,_]=u;typeof f!="number"||typeof _!="number"||(a=!0,f<s&&(s=f),_<h&&(h=_),f>n&&(n=f),_>r&&(r=_))}),a?[s,h,n,r]:null}function Bo(m){let c=1/0,s=1/0,h=-1/0,n=-1/0,r=!1;for(const a of m.features){const u=Oo(a);u&&(r=!0,c=Math.min(c,u[0]),s=Math.min(s,u[1]),h=Math.max(h,u[2]),n=Math.max(n,u[3]))}return r?[c,s,h,n]:null}function Ro(m){const[c,s,h,n]=m;return[[s,c],[n,h]]}function Hi(m){var s;const c=[];for(const h of m.features){if(!h||h.type!=="Feature")continue;const n=(s=h.properties)!=null?s:{},r=h.geometry;if(r)switch(r.type){case"MultiPolygon":for(const a of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"Polygon",coordinates:a}});break;case"MultiLineString":for(const a of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"LineString",coordinates:a}});break;case"MultiPoint":for(const a of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"Point",coordinates:a}});break;case"GeometryCollection":for(const a of r.geometries)c.push({type:"Feature",properties:{...n},geometry:a});break;default:c.push(h);break}}return{type:"FeatureCollection",features:c}}function Fi(m){return(m==null?void 0:m.type)==="Polygon"}function Gi(m){return(m==null?void 0:m.type)==="MultiPolygon"}function Uo(m){const c=m.geometry;return c?Fi(c)?[c.coordinates]:Gi(c)?c.coordinates:[]:[]}function No(m,c){var n,r;const s=[];for(const a of m){const u=Uo(a);u.length>0&&s.push(...u)}if(s.length===0)return null;const h=(r=c!=null?c:(n=m[0])==null?void 0:n.properties)!=null?r:{};return s.length===1?{type:"Feature",properties:{...h},geometry:{type:"Polygon",coordinates:s[0]}}:{type:"Feature",properties:{...h},geometry:{type:"MultiPolygon",coordinates:s}}}class Zo{constructor(c=ve("feature-store","debug")){k(this,"log");k(this,"features");this.log=c,this.features=new Map}size(){return this.features.size}has(c){return this.features.has(c)}get(c){return this.features.get(c)}add(c){var r,a,u,f;const s=[],h=(a=(r=performance.now)==null?void 0:r.call(performance))!=null?a:Date.now();for(const _ of c.features){const g=this.ensureId(_),w={..._,id:g};this.features.set(g,w),s.push(g)}const n=((f=(u=performance.now)==null?void 0:u.call(performance))!=null?f:Date.now())-h;return this.log.debug("add",{count:c.features.length,ids:s,elapsedMs:Math.round(n)}),s}update(c,s){if(!this.features.has(c)){this.log.warn("update:missing",{id:c});return}const h={...s,id:c};this.features.set(c,h),this.log.debug("update",{id:c})}remove(c){this.features.delete(c)?this.log.debug("remove",{id:c}):this.log.warn("remove:missing",{id:c})}clear(){const c=this.features.size;this.features.clear(),this.log.debug("clear",{count:c})}toFeatureCollection(){return{type:"FeatureCollection",features:Array.from(this.features.values())}}bounds(){const c=this.toFeatureCollection();if(c.features.length===0)return null;const s=Bo(c);return s?Ro(s):null}ensureId(c){const s=Io(c);if(s)return String(s);const h=qe();return c.id=h,c.properties&&typeof c.properties=="object"&&(c.properties.id=h),h}}const Vi=new WeakSet;function Ho(m=ye){var h;if(Vi.has(m))return;const c=m.DrawToolbar;if(!((h=c==null?void 0:c.prototype)!=null&&h.getModeHandlers))return;const s=c.prototype.getModeHandlers;c.prototype.getModeHandlers=function(n){var a,u,f,_;const r=s.call(this,n);if((a=this.options)!=null&&a.cake){const g=(u=m.Draw)==null?void 0:u.Cake;if(!g)return r;r.push({enabled:!0,handler:new g(n,this.options.cake),title:"Draw Layer Cake (Subtractive Zones)"})}if((f=this.options)!=null&&f.move){const g=(_=m.Draw)==null?void 0:_.Move;if(!g)return r;r.push({enabled:!0,handler:new g(n,this.options.move),title:"Move/Translate Features"})}return r},Vi.add(m)}const xe=class xe extends X.Draw.Circle{constructor(c,s){super(c,s),this.type=xe.TYPE}addHooks(){super.addHooks();const c=this._tooltip;c!=null&&c.updateContent&&c.updateContent({text:"Click and drag to draw the Layer Cake base",subtext:"Release mouse to finish base layer"})}};k(xe,"TYPE","cake");let we=xe;X.Draw.Cake=we;function Fo(m){const c=m.Draw;if(!c||c.Cake)return;const h=class h extends c.Circle{constructor(r,a){super(r,a),this.type=h.TYPE}addHooks(){super.addHooks();const r=this._tooltip;r!=null&&r.updateContent&&r.updateContent({text:"Click and drag to draw the Layer Cake base",subtext:"Release mouse to finish base layer"})}};k(h,"TYPE","cake");let s=h;c.Cake=s}const ke=class ke extends X.Draw.Feature{constructor(s,h){super(s,h);k(this,"_featureGroup");k(this,"_selectedLayer",null);k(this,"_originalLatLngs",null);k(this,"_dragStartLatLng",null);k(this,"_isDragging",!1);k(this,"_pendingMove",null);this.type=ke.TYPE,this._featureGroup=(h==null?void 0:h.featureGroup)||new X.FeatureGroup}enable(){this._enabled||super.enable()}disable(){this._enabled&&(this._cleanupDragging(),super.disable())}addHooks(){const s=this._map;if(!s)return;X.DomUtil.addClass(s.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(n=>{this._enableLayerHover(n)});const h=this._tooltip;h!=null&&h.updateContent&&h.updateContent({text:"Click and drag a feature to move it",subtext:""})}removeHooks(){const s=this._map;s&&(X.DomUtil.removeClass(s.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(h=>{this._disableLayerHover(h)}),this._cleanupDragging())}_enableLayerHover(s){s.on&&(s.on("mouseover",this._onLayerMouseOver,this),s.on("mouseout",this._onLayerMouseOut,this),s.on("mousedown",this._onLayerMouseDown,this))}_disableLayerHover(s){s.off&&(s.off("mouseover",this._onLayerMouseOver,this),s.off("mouseout",this._onLayerMouseOut,this),s.off("mousedown",this._onLayerMouseDown,this))}_onLayerMouseOver(s){if(this._isDragging)return;const h=s.target;if(h.getElement){const n=h.getElement();n&&(n.style.cursor="grab")}else h._path&&(h._path.style.cursor="grab")}_onLayerMouseOut(s){if(this._isDragging)return;const h=s.target;if(h.getElement){const n=h.getElement();n&&(n.style.cursor="")}else h._path&&(h._path.style.cursor="")}_onLayerMouseDown(s){if(this._isDragging)return;X.DomEvent.stopPropagation(s.originalEvent),X.DomEvent.preventDefault(s.originalEvent);const h=s.target;if(this._selectedLayer=h,this._isDragging=!0,this._dragStartLatLng=s.latlng,this._storeOriginalLatLngs(h),h.getElement){const r=h.getElement();r&&(r.style.cursor="grabbing")}else h._path&&(h._path.style.cursor="grabbing");this._map.on("mousemove",this._onMouseMove,this),this._map.on("mouseup",this._onMouseUp,this);const n=h.toGeoJSON();this._pendingMove={layer:h,originalGeoJSON:n,newGeoJSON:n}}_storeOriginalLatLngs(s){s.getLatLng?this._originalLatLngs=s.getLatLng():s.getLatLngs&&(this._originalLatLngs=JSON.parse(JSON.stringify(s.getLatLngs())))}_onMouseMove(s){if(!this._isDragging||!this._selectedLayer||!this._dragStartLatLng)return;const h=this._selectedLayer,n={lat:s.latlng.lat-this._dragStartLatLng.lat,lng:s.latlng.lng-this._dragStartLatLng.lng};if(h.setLatLng){const r=X.latLng(this._originalLatLngs.lat+n.lat,this._originalLatLngs.lng+n.lng);h.setLatLng(r)}else if(h.setLatLngs){const r=this._offsetLatLngs(this._originalLatLngs,n);h.setLatLngs(r)}}_offsetLatLngs(s,h){return s instanceof X.LatLng||s.lat!==void 0&&s.lng!==void 0?X.latLng(s.lat+h.lat,s.lng+h.lng):Array.isArray(s)?s.map(n=>this._offsetLatLngs(n,h)):s}_onMouseUp(s){var n,r;if(!this._isDragging||!this._selectedLayer)return;this._pendingMove&&(this._pendingMove.newGeoJSON=this._selectedLayer.toGeoJSON());const h=this._selectedLayer;if(h.getElement){const a=h.getElement();a&&(a.style.cursor="grab")}else h._path&&(h._path.style.cursor="grab");this._map.fire("draw:moveend",{layer:this._selectedLayer,originalGeoJSON:(n=this._pendingMove)==null?void 0:n.originalGeoJSON,newGeoJSON:(r=this._pendingMove)==null?void 0:r.newGeoJSON}),this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._isDragging=!1}_cleanupDragging(){if(this._selectedLayer){const s=this._selectedLayer;if(s.getElement){const h=s.getElement();h&&(h.style.cursor="")}else s._path&&(s._path.style.cursor="")}this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._selectedLayer=null,this._originalLatLngs=null,this._dragStartLatLng=null,this._isDragging=!1,this._pendingMove=null}confirmMove(){this._pendingMove&&(this._map.fire("draw:moveconfirmed",{layer:this._pendingMove.layer,originalGeoJSON:this._pendingMove.originalGeoJSON,newGeoJSON:this._pendingMove.newGeoJSON}),this._cleanupDragging())}cancelMove(){if(!this._pendingMove)return;const s=this._pendingMove.layer;s.setLatLng&&this._originalLatLngs?s.setLatLng(this._originalLatLngs):s.setLatLngs&&this._originalLatLngs&&s.setLatLngs(this._originalLatLngs),this._cleanupDragging()}hasPendingMove(){return this._pendingMove!==null}};k(ke,"TYPE","move");let je=ke;X.Draw.Move=je;function Go(m){const c=m.Draw;if(!c||c.Move)return;const h=class h extends c.Feature{constructor(a,u){super(a,u);k(this,"_featureGroup");k(this,"_selectedLayer",null);k(this,"_originalLatLngs",null);k(this,"_dragStartLatLng",null);k(this,"_isDragging",!1);k(this,"_pendingMove",null);this.type=h.TYPE,this._featureGroup=(u==null?void 0:u.featureGroup)||new X.FeatureGroup}enable(){this._enabled||super.enable()}disable(){this._enabled&&(this._cleanupDragging(),super.disable())}addHooks(){const a=this._map;if(!a)return;m.DomUtil.addClass(a.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(f=>{this._enableLayerHover(f)});const u=this._tooltip;u!=null&&u.updateContent&&u.updateContent({text:"Click and drag a feature to move it",subtext:""})}removeHooks(){const a=this._map;a&&(m.DomUtil.removeClass(a.getContainer(),"leaflet-draw-move-mode"),this._featureGroup.eachLayer(u=>{this._disableLayerHover(u)}),this._cleanupDragging())}_enableLayerHover(a){a.on&&(a.on("mouseover",this._onLayerMouseOver,this),a.on("mouseout",this._onLayerMouseOut,this),a.on("mousedown",this._onLayerMouseDown,this))}_disableLayerHover(a){a.off&&(a.off("mouseover",this._onLayerMouseOver,this),a.off("mouseout",this._onLayerMouseOut,this),a.off("mousedown",this._onLayerMouseDown,this))}_onLayerMouseOver(a){if(this._isDragging)return;const u=a.target;if(u.getElement){const f=u.getElement();f&&(f.style.cursor="grab")}else u._path&&(u._path.style.cursor="grab")}_onLayerMouseOut(a){if(this._isDragging)return;const u=a.target;if(u.getElement){const f=u.getElement();f&&(f.style.cursor="")}else u._path&&(u._path.style.cursor="")}_onLayerMouseDown(a){if(this._isDragging)return;m.DomEvent.stopPropagation(a.originalEvent),m.DomEvent.preventDefault(a.originalEvent);const u=a.target;if(this._selectedLayer=u,this._isDragging=!0,this._dragStartLatLng=a.latlng,this._storeOriginalLatLngs(u),u.getElement){const _=u.getElement();_&&(_.style.cursor="grabbing")}else u._path&&(u._path.style.cursor="grabbing");this._map.on("mousemove",this._onMouseMove,this),this._map.on("mouseup",this._onMouseUp,this);const f=u.toGeoJSON();this._pendingMove={layer:u,originalGeoJSON:f,newGeoJSON:f}}_storeOriginalLatLngs(a){a.getLatLng?this._originalLatLngs=a.getLatLng():a.getLatLngs&&(this._originalLatLngs=JSON.parse(JSON.stringify(a.getLatLngs())))}_onMouseMove(a){if(!this._isDragging||!this._selectedLayer||!this._dragStartLatLng)return;const u=this._selectedLayer,f={lat:a.latlng.lat-this._dragStartLatLng.lat,lng:a.latlng.lng-this._dragStartLatLng.lng};if(u.setLatLng){const _=m.latLng(this._originalLatLngs.lat+f.lat,this._originalLatLngs.lng+f.lng);u.setLatLng(_)}else if(u.setLatLngs){const _=this._offsetLatLngs(this._originalLatLngs,f);u.setLatLngs(_)}}_offsetLatLngs(a,u){return a instanceof m.LatLng||a.lat!==void 0&&a.lng!==void 0?m.latLng(a.lat+u.lat,a.lng+u.lng):Array.isArray(a)?a.map(f=>this._offsetLatLngs(f,u)):a}_onMouseUp(a){var f,_;if(!this._isDragging||!this._selectedLayer)return;this._pendingMove&&(this._pendingMove.newGeoJSON=this._selectedLayer.toGeoJSON());const u=this._selectedLayer;if(u.getElement){const g=u.getElement();g&&(g.style.cursor="grab")}else u._path&&(u._path.style.cursor="grab");this._map.fire("draw:moveend",{layer:this._selectedLayer,originalGeoJSON:(f=this._pendingMove)==null?void 0:f.originalGeoJSON,newGeoJSON:(_=this._pendingMove)==null?void 0:_.newGeoJSON}),this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._isDragging=!1}_cleanupDragging(){if(this._selectedLayer){const a=this._selectedLayer;if(a.getElement){const u=a.getElement();u&&(u.style.cursor="")}else a._path&&(a._path.style.cursor="")}this._map.off("mousemove",this._onMouseMove,this),this._map.off("mouseup",this._onMouseUp,this),this._selectedLayer=null,this._originalLatLngs=null,this._dragStartLatLng=null,this._isDragging=!1,this._pendingMove=null}confirmMove(){this._pendingMove&&(this._map.fire("draw:moveconfirmed",{layer:this._pendingMove.layer,originalGeoJSON:this._pendingMove.originalGeoJSON,newGeoJSON:this._pendingMove.newGeoJSON}),this._cleanupDragging())}cancelMove(){if(!this._pendingMove)return;const a=this._pendingMove.layer;a.setLatLng&&this._originalLatLngs?a.setLatLng(this._originalLatLngs):a.setLatLngs&&this._originalLatLngs&&a.setLatLngs(this._originalLatLngs),this._cleanupDragging()}hasPendingMove(){return this._pendingMove!==null}};k(h,"TYPE","move");let s=h;c.Move=s}const Vo=63710088e-1;function Je(m){return m*Math.PI/180}function Wi(m){return m*180/Math.PI}function Wo(m,c,s){const h=c/Vo,n=Je(s),r=Je(m.lat),a=Je(m.lng),u=Math.sin(r),f=Math.cos(r),_=Math.sin(h),g=Math.cos(h),w=u*g+f*_*Math.cos(n),x=Math.asin(w),M=Math.sin(n)*_*f,E=g-u*w,P=a+Math.atan2(M,E);return{lat:Wi(x),lng:Wi(P)}}function Yo(m){let c=0;for(let s=0;s<m.length-1;s++){const[h,n]=m[s],[r,a]=m[s+1];c+=h*a-r*n}return c/2}function Ke(m){const c=m[0],s=m.at(-1);return!c||!s||c[0]===s[0]&&c[1]===s[1]?m:[...m,c]}function Xe(m,c){const s=Ke(m);if(Yo(s)<0===c)return s;const r=[...s].reverse();return Ke(r)}function Qe(m,c,s){if(s<4)throw new Error("steps must be >= 4");const h=[];for(let n=0;n<s;n++){const r=n/s*360,a=Wo(m,c,r);h.push([a.lng,a.lat])}return Ke(h)}function qo(m){const{id:c,center:s,radiusMeters:h,layerIndex:n,steps:r}=m,a=Xe(Qe(s,h,r),!1);return{type:"Feature",properties:{id:c,layer_index:n,radius_outer:h,type:"core",_meta:{lat:s.lat,lng:s.lng,radius:h}},geometry:{type:"Polygon",coordinates:[a]}}}function jo(m){const{id:c,center:s,radiusOuterMeters:h,radiusInnerMeters:n,layerIndex:r,steps:a}=m,u=Xe(Qe(s,h,a),!1),f=Xe(Qe(s,n,a),!0);return{type:"Feature",properties:{id:c,layer_index:r,radius_outer:h,type:"ring",_meta:{lat:s.lat,lng:s.lng,radius:h}},geometry:{type:"Polygon",coordinates:[u,f]}}}function Jo(m){const{circles:c,steps:s=64}=m,h=[...c].sort((r,a)=>r.getRadius()-a.getRadius()),n=[];return h.forEach((r,a)=>{const u=r.getLatLng(),f=r.getRadius(),_=qe();if(a===0){n.push(qo({id:_,center:u,radiusMeters:f,layerIndex:a,steps:s}));return}const w=h[a-1].getRadius();n.push(jo({id:_,center:u,radiusOuterMeters:f,radiusInnerMeters:w,layerIndex:a,steps:s}))}),{type:"FeatureCollection",features:n}}function te(m){m.preventDefault(),m.stopPropagation()}function Ko(m){var _,g;const{root:c,addButtonId:s,saveButtonId:h,onAddRing:n,onSave:r}=m,a=(_=c.querySelector)==null?void 0:_.call(c,`#${s}`),u=(g=c.querySelector)==null?void 0:g.call(c,`#${h}`);if(!a||!u)return;const f="data-cake-controls-bound";if(!(a.hasAttribute(f)||u.hasAttribute(f))){a.setAttribute(f,"true"),u.setAttribute(f,"true");for(const w of[a,u])w.addEventListener("pointerdown",te),w.addEventListener("mousedown",te),w.addEventListener("touchstart",te);a.addEventListener("click",w=>{te(w),n()}),u.addEventListener("click",w=>{te(w),r()})}}function Xo(m){var s;const c=(s=m.options)!=null?s:{};c.original||(c.original={...c}),c.editing||(c.editing={...c})}function ee(m,c){if(c==="imperial"){const s=m*3.28084;return s>=5280?`${(s/5280).toFixed(2)} mi`:`${Math.round(s)} ft`}return m>=1e3?`${(m/1e3).toFixed(2)} km`:`${Math.round(m)} m`}class Qo{constructor(c,s,h,n="metric"){k(this,"map");k(this,"layers",[]);k(this,"controlsGroup");k(this,"onSave");k(this,"sessionId",qe().slice(0,8));k(this,"baseCircleOptions");k(this,"detachMapListeners",[]);k(this,"renderScheduled",!1);k(this,"measurementSystem");this.map=c,this.onSave=h,this.measurementSystem=n,this.controlsGroup=X.layerGroup().addTo(c),this.baseCircleOptions={...s.options},delete this.baseCircleOptions.editing,delete this.baseCircleOptions.original,this.addLayer(s),this.installEditEventBridges(),this.renderControls()}installEditEventBridges(){var g,w,x,M,E,P,U,H;const c=ye,s=(w=(g=c==null?void 0:c.Draw)==null?void 0:g.Event)==null?void 0:w.EDITMOVE,h=(M=(x=c==null?void 0:c.Draw)==null?void 0:x.Event)==null?void 0:M.EDITRESIZE,n=(P=(E=c==null?void 0:c.Draw)==null?void 0:E.Event)==null?void 0:P.EDITSTART,r=(H=(U=c==null?void 0:c.Draw)==null?void 0:U.Event)==null?void 0:H.EDITSTOP;if(!s||!h)return;const a=S=>{const D=S==null?void 0:S.layer;D&&this.layers.includes(D)&&this.syncCenters(D)},u=S=>{const D=S==null?void 0:S.layer;D&&this.layers.includes(D)&&(this.updateLabels(D),this.requestRenderControls())},f=S=>{var q;const D=S==null?void 0:S.layer;if(!D||!this.layers.includes(D))return;const G=D;((q=G.getTooltip)==null?void 0:q.call(G))&&this.updateLabels(G)},_=()=>{this.layers.forEach(S=>{var G;const D=(G=S.getTooltip)==null?void 0:G.call(S);D&&(S.setTooltipContent(ee(S.getRadius(),this.measurementSystem)),D.options.offset=[10,0],D.options.direction="right",S.closeTooltip(),S.openTooltip())})};this.map.on(s,a),this.map.on(h,u),n&&(this.map.on(n,f),this.detachMapListeners.push(()=>this.map.off(n,f))),r&&(this.map.on(r,_),this.detachMapListeners.push(()=>this.map.off(r,_))),this.detachMapListeners.push(()=>this.map.off(s,a)),this.detachMapListeners.push(()=>this.map.off(h,u))}requestRenderControls(){if(this.renderScheduled)return;this.renderScheduled=!0,(typeof requestAnimationFrame=="function"?requestAnimationFrame:s=>setTimeout(()=>s(0),0))(()=>{this.renderScheduled=!1,this.renderControls()})}addLayer(c){this.layers.push(c),c.addTo(this.map),c.bindTooltip(ee(c.getRadius(),this.measurementSystem),{permanent:!0,direction:"right",className:"cake-label",offset:[10,0]});const s=c.editing;setTimeout(()=>{var h,n,r,a,u;try{if((h=c.redraw)==null||h.call(c),Xo(c),(n=s==null?void 0:s.enabled)!=null&&n.call(s)){(r=s.updateMarkers)==null||r.call(s),this.requestRenderControls();return}(a=s==null?void 0:s.enable)==null||a.call(s),(u=s==null?void 0:s.updateMarkers)==null||u.call(s),this.requestRenderControls()}catch{}},0)}addRing(){if(this.layers.length>=10)return;const c=this.getLargestCircle();if(!c)return;const s=c.getRadius()*1.5,h=X.circle(c.getLatLng(),{...this.baseCircleOptions,radius:s});this.addLayer(h),this.renderControls()}save(){const c=Jo({circles:this.layers});this.onSave(c),this.destroy()}getLargestCircle(){return this.layers.length===0?null:this.layers.reduce((c,s)=>c.getRadius()>s.getRadius()?c:s)}syncCenters(c){const s=c.getLatLng();this.layers.forEach(h=>{var n,r,a;h!==c&&(h.setLatLng(s),(n=h.redraw)==null||n.call(h),(a=(r=h.editing)==null?void 0:r.updateMarkers)==null||a.call(r))}),this.requestRenderControls()}updateLabels(c){var a;const s=c.getRadius();let h=ee(s,this.measurementSystem);const n=this.layers.filter(u=>u!==c&&u.getRadius()<s);if(n.length>0){const u=n.reduce((g,w)=>g.getRadius()>w.getRadius()?g:w),f=s-u.getRadius(),_=ee(f,this.measurementSystem);h=`${ee(s,this.measurementSystem)} (+${_})`}const r=(a=c.getTooltip)==null?void 0:a.call(c);if(r){c.setTooltipContent(h);const f=c.getBounds().getSouthWest();f.lat=c.getLatLng().lat,r.options.direction="left",r.options.offset=[-10,0],r.setLatLng(f),c.closeTooltip(),c.openTooltip()}}renderControls(){this.controlsGroup.clearLayers();const c=this.getLargestCircle();if(!c)return;const h=c.getBounds().getNorthEast(),n=`cake-add-${this.sessionId}`,r=`cake-save-${this.sessionId}`,a=X.divIcon({className:"layer-cake-controls",html:`
|
|
206
206
|
<div class="layer-cake-controls__container">
|
|
207
207
|
<button id="${n}" type="button">➕ Ring</button>
|
|
208
208
|
<button id="${r}" type="button" class="layer-cake-controls__save">💾 Save</button>
|
|
209
209
|
</div>
|
|
210
|
-
`,iconSize:[140,40],iconAnchor:[-10,20]});
|
|
210
|
+
`,iconSize:[140,40],iconAnchor:[-10,20]});X.marker(h,{icon:a,interactive:!0,keyboard:!1,bubblingMouseEvents:!1}).addTo(this.controlsGroup),setTimeout(()=>{const u=this.map.getContainer();Ko({root:u,addButtonId:n,saveButtonId:r,onAddRing:()=>this.addRing(),onSave:()=>this.save()})},0)}destroy(){this.detachMapListeners.forEach(c=>{try{c()}catch{}}),this.detachMapListeners=[],this.layers.forEach(c=>this.map.removeLayer(c)),this.layers=[],this.controlsGroup.clearLayers(),this.map.removeLayer(this.controlsGroup)}}const $o=`<?xml version="1.0" encoding="utf-8"?>
|
|
211
211
|
\r<!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
|
|
212
212
|
<svg width="800px" height="800px" viewBox="0 -1.67 47.336 47.336" xmlns="http://www.w3.org/2000/svg">\r
|
|
213
213
|
<g id="Group_42" data-name="Group 42" transform="translate(-172.455 -364.36)">\r
|
|
@@ -218,7 +218,7 @@ ${mo}
|
|
|
218
218
|
<path id="Path_91" data-name="Path 91" d="M211.234,370.794a3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778,3.778,3.778,0,0,1-3.778,3.778h0a3.779,3.779,0,0,1-3.778-3.778" fill="none" stroke="#000000" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"/>\r
|
|
219
219
|
</g>\r
|
|
220
220
|
</g>\r
|
|
221
|
-
</svg>`,
|
|
221
|
+
</svg>`,tr=`<?xml version="1.0" encoding="utf-8"?>
|
|
222
222
|
<!-- Four-way directional arrow icon for move tool -->
|
|
223
223
|
<svg width="800px" height="800px" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
|
|
224
224
|
<g fill="none" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
@@ -238,7 +238,7 @@ ${mo}
|
|
|
238
238
|
<path d="M22 12 L19 15"/>
|
|
239
239
|
</g>
|
|
240
240
|
</svg>
|
|
241
|
-
`,Wi=6378137,Ht=6356752314245e-6,Ot=1/298.257223563,Qo=Math.PI/180,$o=180/Math.PI,we=1e9;function tr(g){const h=BigInt(Math.round(g*we));return Number(h)/we}function Ft(g){return tr(g)*Qo}function Yi(g){const h=g*$o%360;return h<0?h+360:h}function Qe(g){const h=BigInt(Math.round(g*we));return Number(h)/we}function er(g,h,s,c){const n=ir(g,h,s,c);if(n.converged)return{meters:Qe(n.distanceMeters),bearingDegrees:Yi(n.bearingRad),algorithm:"vincenty",iterations:n.iterations};const r=nr(g,h,s,c);return{meters:Qe(r.distanceMeters),bearingDegrees:Yi(r.bearingRad),algorithm:"karney",iterations:n.iterations}}function ir(g,h,s,c){const n=Ft(g),r=Ft(s),a=Ft(c-h),u=Math.atan((1-Ot)*Math.tan(n)),f=Math.atan((1-Ot)*Math.tan(r)),_=Math.sin(u),m=Math.cos(u),w=Math.sin(f),x=Math.cos(f);let E=a,P=0,M=0;const U=200;let H=0,T=0,D=0,V=0,j=0,J=0;for(;Math.abs(E-P)>1e-12&&M<U;){const Ae=Math.sin(E),pt=Math.cos(E);if(H=Math.sqrt((x*Ae)**2+(m*w-_*x*pt)**2),H===0)return{distanceMeters:0,bearingRad:0,iterations:M,converged:!0};T=_*w+m*x*pt,D=Math.atan2(H,T),V=m*x*Ae/H,j=1-V**2,J=j===0?0:T-2*_*w/j;const ee=Ot/16*j*(4+Ot*(4-3*j));P=E,E=a+(1-ee)*Ot*V*(D+ee*H*(J+ee*T*(-1+2*J**2))),M+=1}if(M>=U)return{distanceMeters:Number.NaN,bearingRad:0,iterations:M,converged:!1};const K=(Wi**2-Ht**2)/Ht**2*j,kt=1+K/16384*(4096+K*(-768+K*(320-175*K))),Tt=K/1024*(256+K*(-128+K*(74-47*K))),ke=Tt*H*(J+Tt/4*(T*(-1+2*J**2)-Tt/6*J*(-3+4*H**2)*(-3+4*J**2))),rt=Ht*kt*(D-ke),at=Math.atan2(x*Math.sin(E),m*w-_*x*Math.cos(E));return{distanceMeters:rt,bearingRad:at,iterations:M,converged:!0}}function nr(g,h,s,c){const n=Ft(g),r=Ft(s),a=Ft(c-h),u=Math.atan((1-Ot)*Math.tan(n)),f=Math.atan((1-Ot)*Math.tan(r)),_=Math.sin(u),m=Math.cos(u),w=Math.sin(f),x=Math.cos(f),E=Math.sqrt((x*Math.sin(a))**2+(m*w-_*x*Math.cos(a))**2),P=_*w+m*x*Math.cos(a),M=Math.atan2(E,P);if(M===0)return{distanceMeters:0,bearingRad:0};const H=1-(m*x*Math.sin(a)/Math.sin(M))**2,T=H===0?0:P-2*_*w/H,D=(Wi**2-Ht**2)/Ht**2*H,V=1+D/16384*(4096+D*(-768+D*(320-175*D))),j=D/1024*(256+D*(-128+D*(74-47*D))),J=j*E*(T+j/4*(P*(-1+2*T**2)-j/6*T*(-3+4*E**2)*(-3+4*T**2))),K=Ht*V*(M-J),kt=Math.atan2(x*Math.sin(a),m*w-_*x*Math.cos(a));return{distanceMeters:K,bearingRad:kt}}const or={position:"topleft",circleMarker:{color:"red",radius:2},lineStyle:{color:"red",dashArray:"1,6"},angleUnit:{display:"°",decimal:2,factor:null,label:"Bearing:"}},rr={display:"km",decimal:2,factor:null,label:"Distance (km):"},sr={display:"mi",decimal:2,factor:.621371,label:"Distance (mi):"};function ar(g){const h=g==="imperial"?{...sr}:{...rr};return{...or,lengthUnit:h}}const lr={metric:"Meters / Kilometers",imperial:"Feet / Miles"};function $e(g,h={}){var r,a;const s=!!((r=g==null?void 0:g.Control)!=null&&r.Draw),c=!!g.draw,n=s&&c;return n||(a=h.onError)==null||a.call(h,"Leaflet.draw is not available on the provided Leaflet instance"),n}let qi=!1;class hr{constructor(h){k(this,"container");k(this,"logger");k(this,"options");k(this,"L");k(this,"store");k(this,"map",null);k(this,"drawnItems",null);k(this,"drawControl",null);k(this,"rulerControl",null);k(this,"measurementControl",null);k(this,"measurementSystem","metric");k(this,"measurementModalOverlay",null);k(this,"measurementModalDialog",null);k(this,"measurementModalRadios",{});k(this,"measurementModalKeydownHandler",null);k(this,"detachPolygonFinishPatch",null);k(this,"vertexMenuEl",null);k(this,"vertexMenuCleanup",null);k(this,"activeCakeSession",null);k(this,"moveConfirmationUI",null);k(this,"activeMoveHandler",null);var s;this.options=h,this.container=h.container,this.logger=((s=h.logger)!=null?s:ge("controller","debug")).child("map"),this.L=this.resolveLeaflet(h),this.store=new Ro(this.logger.child("store")),this.logger.debug("ctor",{config:h.map,controls:h.controls,readOnly:h.readOnly,useExternalLeaflet:h.useExternalLeaflet}),No(this.L),Zo(this.L),Uo(this.L)}resolveLeaflet(h){if(!h.useExternalLeaflet)return ve;if(h.leaflet&&$e(h.leaflet))return this.logger.debug("leaflet-runtime:external-injected"),h.leaflet;const c=globalThis.L;return c&&$e(c)?(this.logger.debug("leaflet-runtime:external-global"),c):(this.logger.warn("leaflet-runtime:external-fallback-bundled",{message:"External Leaflet requested but Draw APIs were missing; falling back to bundled Leaflet/Draw"}),ve)}async init(){var s,c,n,r,a,u;const h=(c=(s=performance.now)==null?void 0:s.call(performance))!=null?c:Date.now();try{await this.destroy();const{latitude:f,longitude:_,zoom:m,minZoom:w,maxZoom:x,tileUrl:E,tileAttribution:P,preferCanvas:M=!0,useExternalLeaflet:U}=this.options.map,H=[f,_],T=this.L;U&&$e(T,{onError:K=>this.logger.warn("external-leaflet-missing-draw",{message:K})}),this.map=T.map(this.container,{zoomControl:!0,preferCanvas:M}).setView(H,m),T.tileLayer(E,{attribution:P,minZoom:w,maxZoom:x}).addTo(this.map),this.drawnItems=T.featureGroup().addTo(this.map);const D=this.buildDrawOptions(this.options.controls,!!this.options.readOnly),V=T.Control.Draw;this.drawControl=new V(D),this.map.addControl(this.drawControl),this.applyLayerCakeToolbarIcon(),this.applyMoveToolbarIcon(),this.options.controls.ruler&&(this.logger.debug("init:ruler",{available:typeof T.control.ruler=="function"}),typeof T.control.ruler=="function"?(this.addRulerControl(),this.installMeasurementSettingsControl()):this.logger.warn("init:ruler:missing",{msg:"L.control.ruler is not defined"})),this.patchLeafletDrawBugs(),this.installPolygonFinishPatch(),this.map.invalidateSize(),setTimeout(()=>{var K;try{(K=this.map)==null||K.invalidateSize()}catch{}},0),this.bindDrawEvents();const j=((r=(n=performance.now)==null?void 0:n.call(performance))!=null?r:Date.now())-h;this.logger.debug("init:ready",{elapsedMs:Math.round(j)});const J=this.store.bounds();(u=(a=this.options.callbacks)==null?void 0:a.onReady)==null||u.call(a,J?{bounds:J}:{})}catch(f){this._error("Failed to initialize Leaflet map",f)}}async destroy(){var h,s,c;try{this.map&&(this.map.off(),this.map.remove())}catch(n){this._error("Failed to remove Leaflet map",n)}try{(h=this.detachPolygonFinishPatch)==null||h.call(this)}catch{}this.detachPolygonFinishPatch=null;try{(s=this.vertexMenuCleanup)==null||s.call(this)}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null;try{this.hideMoveConfirmationUI()}catch{}this.drawControl=null,this.rulerControl=null,this.measurementControl=null,this.removeMeasurementModal(),this.drawnItems=null;try{(c=this.activeCakeSession)==null||c.destroy()}catch{}this.activeCakeSession=null,this.map=null}async getGeoJSON(){return this.store.toFeatureCollection()}async loadGeoJSON(h,s=!1){if(!this.map||!this.drawnItems)return;await this.clearLayers();const c=Zi(h),n=this.store.add(c),r=this.L.geoJSON(c);let a=0;r.eachLayer(u=>{var f;u._fid=(f=n[a])!=null?f:n[n.length-1],this.drawnItems.addLayer(u),this.installVertexContextMenu(u),a++}),this.logger.debug("loadGeoJSON",{count:c.features.length,ids:n}),s&&await this.fitBoundsToData()}async clearLayers(){this.drawnItems&&this.drawnItems.clearLayers(),this.store.clear()}async addFeatures(h){if(!this.map||!this.drawnItems)return[];const s=Zi(h),c=this.store.add(s),n=this.L.geoJSON(s);let r=0;return n.eachLayer(a=>{var u;a._fid=(u=c[r])!=null?u:c[c.length-1],this.drawnItems.addLayer(a),this.installVertexContextMenu(a),r++}),c}async updateFeature(h,s){this.store.update(h,s)}async removeFeature(h){this.drawnItems&&this.drawnItems.eachLayer(s=>{s._fid===h&&this.drawnItems.removeLayer(s)}),this.store.remove(h)}async fitBoundsToData(h=.05){if(!this.map)return;const s=this.store.bounds();if(!s)return;const c=s,n=this.L.latLngBounds(c);if(h>0){const r=n.getSouthWest(),a=n.getNorthEast(),u=(a.lat-r.lat)*h,f=(a.lng-r.lng)*h,_=this.L.latLngBounds(this.L.latLng(r.lat-u,r.lng-f),this.L.latLng(a.lat+u,a.lng+f));this.map.fitBounds(_)}else this.map.fitBounds(n)}async fitBounds(h,s=.05){if(!this.map)return;const c=this.L.latLngBounds(h);if(s>0){const n=c.getSouthWest(),r=c.getNorthEast(),a=(r.lat-n.lat)*s,u=(r.lng-n.lng)*s,f=this.L.latLngBounds(this.L.latLng(n.lat-a,n.lng-u),this.L.latLng(r.lat+a,r.lng+u));this.map.fitBounds(f)}else this.map.fitBounds(c)}async setView(h,s,c){this.map&&this.map.setView([h,s],c!=null?c:this.map.getZoom())}async mergeVisiblePolygons(h){if(!this.map||!this.drawnItems)return null;const c=(await this.getGeoJSON()).features.filter(u=>{const f=u.geometry;return f&&(Hi(f)||Fi(f))});if(c.length<=1){if(c.length===1){const u=c[0].id;return u?String(u):null}return null}const n=Bo(c,h==null?void 0:h.properties);if(!n)return null;const r=[];for(const u of c){const f=u.id;f&&r.push(String(f))}for(const u of r)await this.removeFeature(u);const[a]=await this.addFeatures({type:"FeatureCollection",features:[n]});return a||null}setRulerUnits(h){this.measurementSystem!==h&&(this.measurementSystem=h,this.logger.debug("ruler:units",{system:h}),this.syncMeasurementModalState(),this.rebuildRulerControl())}buildDrawOptions(h,s){var r;const c={polygon:h.polygon?{allowIntersection:(r=this.options.map.polygonAllowIntersection)!=null?r:!1,showArea:!0,shapeOptions:{color:"#3388ff"}}:!1,polyline:h.polyline?{shapeOptions:{color:"#3388ff"}}:!1,rectangle:h.rectangle?{shapeOptions:{color:"#3388ff"}}:!1,circle:h.circle?{shapeOptions:{color:"#3388ff"}}:!1,cake:h.cake?{shapeOptions:{color:"#8A2BE2",fillOpacity:.2}}:!1,marker:h.marker?{}:!1,move:h.move?{featureGroup:this.drawnItems}:!1};let n={featureGroup:this.drawnItems};return h.edit?h.delete===!1&&(n.remove=!1):n=!1,s?{draw:!1,edit:!1}:{draw:c,edit:n}}applyLayerCakeToolbarIcon(){if(!this.container)return;const h=()=>{const s=this.container.querySelector("a.leaflet-draw-draw-cake");if(!s)return;s.style.setProperty("background-image","none","important"),s.style.setProperty("background-color","#fff","important"),s.style.setProperty("position","relative","important");let c=s.querySelector(".leaflet-geokit-cake-icon");c||(c=document.createElement("span"),c.className="leaflet-geokit-cake-icon",c.setAttribute("aria-hidden","true"),s.appendChild(c)),c.style.setProperty("position","absolute","important"),c.style.setProperty("display","block","important"),c.style.setProperty("left","50%","important"),c.style.setProperty("top","50%","important"),c.style.setProperty("width","18px","important"),c.style.setProperty("height","18px","important"),c.style.setProperty("transform","translate(-50%, -50%)","important"),c.style.setProperty("pointer-events","none","important"),c.firstElementChild||(c.innerHTML=Ko);const n=c.firstElementChild;n&&(n.style.setProperty("width","100%","important"),n.style.setProperty("height","100%","important"),n.style.setProperty("display","block","important"))};h(),setTimeout(h,0)}applyMoveToolbarIcon(){if(!this.container)return;const h=()=>{const s=this.container.querySelector("a.leaflet-draw-draw-move");if(!s)return;s.style.setProperty("background-image","none","important"),s.style.setProperty("background-color","#fff","important"),s.style.setProperty("position","relative","important");let c=s.querySelector(".leaflet-geokit-move-icon");c||(c=document.createElement("span"),c.className="leaflet-geokit-move-icon",c.setAttribute("aria-hidden","true"),s.appendChild(c)),c.style.setProperty("position","absolute","important"),c.style.setProperty("display","block","important"),c.style.setProperty("left","50%","important"),c.style.setProperty("top","50%","important"),c.style.setProperty("width","18px","important"),c.style.setProperty("height","18px","important"),c.style.setProperty("transform","translate(-50%, -50%)","important"),c.style.setProperty("pointer-events","none","important"),c.firstElementChild||(c.innerHTML=Xo);const n=c.firstElementChild;n&&(n.style.setProperty("width","100%","important"),n.style.setProperty("height","100%","important"),n.style.setProperty("display","block","important"))};h(),setTimeout(h,0)}addRulerControl(){if(!this.map)return;this.installRulerPrecisionPatch();const h=ar(this.measurementSystem);this.rulerControl=this.L.control.ruler(h),this.map.addControl(this.rulerControl)}installRulerPrecisionPatch(){if(qi)return;const h=this.L.Control.Ruler;if(!h||typeof h!="function")return;const s=h.prototype,c=s._calculateBearingAndDistance;if(typeof c!="function")return;const n=this.logger;s._calculateBearingAndDistance=function(){var a,u,f;c.call(this);try{const _=this._clickedLatLong,m=(a=this._movingLatLong)!=null?a:this._clickedLatLong;if(!_||!m)return;const{meters:w,bearingDegrees:x}=er(_.lat,_.lng,m.lat,m.lng),E=w/1e3,P=typeof((f=(u=this.options)==null?void 0:u.lengthUnit)==null?void 0:f.factor)=="number"?this.options.lengthUnit.factor:1,M=Qe(E*P);this._result=this._result||{},this._result.Distance=M,this._result.Bearing=x,this._result.meters=w}catch(_){n==null||n.warn("ruler:precision-patch",_)}},qi=!0}rebuildRulerControl(){if(!(!this.map||!this.options.controls.ruler)){if(this.rulerControl){try{this.map.removeControl(this.rulerControl)}catch(h){this.logger.warn("ruler:remove-failed",h)}this.rulerControl=null}this.addRulerControl()}}installMeasurementSettingsControl(){if(!this.map||this.measurementControl)return;const h=this,s=this.L.Control.extend({options:{position:"topleft"},onAdd(){const c=h.L.DomUtil.create("div","leaflet-bar leaflet-ruler-settings-control"),n=h.L.DomUtil.create("button","leaflet-ruler-settings-button",c);return n.type="button",n.title="Measurement settings",n.setAttribute("aria-label","Measurement settings"),n.addEventListener("click",r=>{r.preventDefault(),r.stopPropagation(),h.toggleMeasurementModal(!0)}),h.L.DomEvent.disableClickPropagation(c),h.L.DomEvent.disableScrollPropagation(c),c}});this.measurementControl=new s,this.map.addControl(this.measurementControl)}ensureMeasurementModal(){if(this.measurementModalOverlay)return this.measurementModalOverlay;if(typeof document=="undefined")throw new Error("Measurement modal requires a browser environment");const h=document.createElement("div");h.className="leaflet-ruler-modal-overlay",h.setAttribute("aria-hidden","true");const s=document.createElement("div");s.className="leaflet-ruler-modal",s.setAttribute("role","dialog"),s.setAttribute("aria-modal","true"),s.tabIndex=-1,h.addEventListener("click",f=>{f.target===h&&this.toggleMeasurementModal(!1)});const c=document.createElement("h2");c.className="leaflet-ruler-modal-title",c.textContent="Measurement Units",s.appendChild(c);const n=document.createElement("p");n.className="leaflet-ruler-modal-description",n.textContent="Choose how the measurement tool reports distances.",s.appendChild(n);const r=document.createElement("div");r.className="leaflet-ruler-modal-options",s.appendChild(r),["metric","imperial"].forEach(f=>{const _=document.createElement("label");_.className="leaflet-ruler-modal-option";const m=document.createElement("input");m.type="radio",m.name="leaflet-ruler-units",m.value=f,m.addEventListener("change",()=>{m.checked&&this.setRulerUnits(f)});const w=document.createElement("span");w.textContent=lr[f],_.appendChild(m),_.appendChild(w),r.appendChild(_),this.measurementModalRadios[f]=m});const a=document.createElement("div");a.className="leaflet-ruler-modal-actions";const u=document.createElement("button");return u.type="button",u.className="leaflet-ruler-modal-close",u.textContent="Close",u.addEventListener("click",()=>this.toggleMeasurementModal(!1)),a.appendChild(u),s.appendChild(a),h.appendChild(s),this.container.appendChild(h),this.measurementModalOverlay=h,this.measurementModalDialog=s,this.syncMeasurementModalState(),h}toggleMeasurementModal(h){var c;if(!h){this.measurementModalOverlay&&(this.measurementModalOverlay.classList.remove("is-open"),this.measurementModalOverlay.setAttribute("aria-hidden","true")),this.detachMeasurementModalKeydown();return}const s=this.ensureMeasurementModal();s.classList.add("is-open"),s.setAttribute("aria-hidden","false"),this.syncMeasurementModalState(),this.attachMeasurementModalKeydown(),(c=this.measurementModalDialog)==null||c.focus()}syncMeasurementModalState(){for(const[h,s]of Object.entries(this.measurementModalRadios))s&&(s.checked=h===this.measurementSystem)}removeMeasurementModal(){this.measurementModalOverlay&&this.measurementModalOverlay.remove(),this.measurementModalOverlay=null,this.measurementModalDialog=null,this.measurementModalRadios={},this.detachMeasurementModalKeydown()}attachMeasurementModalKeydown(){this.measurementModalKeydownHandler||typeof document=="undefined"||(this.measurementModalKeydownHandler=h=>{h.key==="Escape"&&this.toggleMeasurementModal(!1)},document.addEventListener("keydown",this.measurementModalKeydownHandler))}detachMeasurementModalKeydown(){!this.measurementModalKeydownHandler||typeof document=="undefined"||(document.removeEventListener("keydown",this.measurementModalKeydownHandler),this.measurementModalKeydownHandler=null)}installPolygonFinishPatch(){var a,u,f,_,m;if(!this.map||!this.drawControl)return;try{(a=this.detachPolygonFinishPatch)==null||a.call(this)}catch{}this.detachPolygonFinishPatch=null;const h=this.map,s=(f=(u=this.drawControl)==null?void 0:u._toolbars)==null?void 0:f.draw;if(!s||!!!((m=(_=s._modes)==null?void 0:_.polygon)!=null&&m.handler))return;const n=10,r=w=>{var x,E,P,M,U,H,T,D;try{const V=(E=(x=s._modes)==null?void 0:x.polygon)==null?void 0:E.handler;if(!V||!V._enabled)return;const j=V._markers;if(!Array.isArray(j)||j.length<4)return;const J=(M=(P=j[0])==null?void 0:P.getLatLng)==null?void 0:M.call(P);if(!J)return;const K=h.latLngToContainerPoint(J),kt=h.latLngToContainerPoint(w.latlng);Math.hypot(K.x-kt.x,K.y-kt.y)<=n&&typeof V._finishShape=="function"&&((H=(U=w.originalEvent)==null?void 0:U.preventDefault)==null||H.call(U),(D=(T=w.originalEvent)==null?void 0:T.stopPropagation)==null||D.call(T),V._finishShape())}catch(V){this._error("polygon-finish-patch",V)}};h.on("click",r),this.detachPolygonFinishPatch=()=>{try{h.off("click",r)}catch{}}}patchLeafletDrawBugs(){var h,s,c,n,r;try{const a=this.L,u=a.GeometryUtil;if(!u)return;const f={km:2,ha:2,m:0,mi:2,ac:2,yd:0,ft:0,nm:2},_=(s=(h=u.formattedNumber)==null?void 0:h.bind(u))!=null?s:((m,w)=>Number(m).toFixed(w));u.readableArea=(m,w,x)=>{var M;const E=(M=a.Util)!=null&&M.extend?a.Util.extend({},f,x||{}):{...f,...x||{}};let P;if(w){let U=["ha","m"];const H=typeof w;H==="string"?U=[w]:H!=="boolean"&&(U=Array.isArray(w)?w:U),m>=1e6&&U.indexOf("km")!==-1?P=`${_(1e-6*m,E.km)} km²`:m>=1e4&&U.indexOf("ha")!==-1?P=`${_(1e-4*m,E.ha)} ha`:P=`${_(m,E.m)} m²`}else m=m/.836127,m>=3097600?P=`${_(m/3097600,E.mi)} mi²`:m>=4840?P=`${_(m/4840,E.ac)} acres`:P=`${_(m,E.yd)} yd²`;return P}}catch(a){this.logger.warn("leaflet-draw-patch:readableArea",a)}try{const a=this.L,u=(c=a.Edit)==null?void 0:c.Circle,f=(n=a.Draw)==null?void 0:n.Event,_=a.GeometryUtil;if(!((r=u==null?void 0:u.prototype)!=null&&r._resize)||!f||!_)return;u.prototype._resize=function(w){var P,M,U;const x=this._moveMarker.getLatLng(),E=_.isVersion07x()?x.distanceTo(w):this._map.distance(x,w);this._shape.setRadius(E);try{(P=this._map)!=null&&P.editTooltip&&((U=(M=this._map)==null?void 0:M._editTooltip)!=null&&U.updateContent)&&this._map._editTooltip.updateContent({text:a.drawLocal.edit.handlers.edit.tooltip.subtext+"<br />"+a.drawLocal.edit.handlers.edit.tooltip.text,subtext:a.drawLocal.draw.handlers.circle.radius+": "+_.readableDistance(E,!0,this.options.feet,this.options.nautic)})}catch{}this._map.fire(f.EDITRESIZE,{layer:this._shape})}}catch(a){this.logger.warn("leaflet-draw-patch:circle-resize",a)}}bindDrawEvents(){!this.map||!this.drawnItems||(this.map.on(this.L.Draw.Event.CREATED,h=>{var s,c,n;try{const{layer:r,layerType:a}=h;if(a===Le.TYPE){try{(s=this.activeCakeSession)==null||s.destroy()}catch{}this.activeCakeSession=new Jo(this.map,r,m=>{if(!this.drawnItems)return;const w=this.store.add(m),x=this.L.geoJSON(m);let E=0;x.eachLayer(P=>{var U,H,T;const M=(U=w[E])!=null?U:w[w.length-1];P._fid=M,this.drawnItems.addLayer(P),this.installVertexContextMenu(P),(T=(H=this.options.callbacks)==null?void 0:H.onCreated)==null||T.call(H,{id:M,layerType:"polygon",geoJSON:P.toGeoJSON()}),E++}),this.activeCakeSession=null},this.measurementSystem);return}this.drawnItems.addLayer(r);const u=r.toGeoJSON(),_=this.store.add({type:"FeatureCollection",features:[u]})[0];r._fid=_,this.installVertexContextMenu(r),(n=(c=this.options.callbacks)==null?void 0:c.onCreated)==null||n.call(c,{id:_,layerType:a,geoJSON:u})}catch(r){this._error("onCreated handler failed",r)}}),this.map.on(this.L.Draw.Event.EDITED,h=>{var s,c;try{const n=[];h.layers.eachLayer(a=>{const u=a.toGeoJSON(),f=a._fid;if(f)this.store.update(f,u),n.push(f);else{const _=this.store.add({type:"FeatureCollection",features:[u]})[0];a._fid=_,n.push(_)}}),(c=(s=this.options.callbacks)==null?void 0:s.onEdited)==null||c.call(s,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onEdited handler failed",n)}}),this.map.on(this.L.Draw.Event.DELETED,h=>{var s,c;try{const n=[];h.layers.eachLayer(a=>{const u=a._fid;u&&(n.push(u),this.store.remove(u))}),(c=(s=this.options.callbacks)==null?void 0:s.onDeleted)==null||c.call(s,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onDeleted handler failed",n)}}),this.map.on("draw:moveend",h=>{try{this.showMoveConfirmationUI(h.layer,h.originalGeoJSON,h.newGeoJSON)}catch(s){this._error("draw:moveend handler failed",s)}}),this.map.on("draw:moveconfirmed",h=>{var s,c;try{const n=h.layer,r=n._fid;if(r){const a=n.toGeoJSON();this.store.update(r,a),(c=(s=this.options.callbacks)==null?void 0:s.onEdited)==null||c.call(s,{ids:[r],geoJSON:this.store.toFeatureCollection()})}this.hideMoveConfirmationUI()}catch(n){this._error("draw:moveconfirmed handler failed",n)}}))}_error(h,s){var c,n;this.logger.error("error",{message:h,cause:s}),(n=(c=this.options.callbacks)==null?void 0:c.onError)==null||n.call(c,{message:h,cause:s})}installVertexContextMenu(h){if(!h||typeof h.on!="function")return;const s=n=>{var r,a,u,f;try{(a=(r=n==null?void 0:n.originalEvent)==null?void 0:r.preventDefault)==null||a.call(r),(f=(u=n==null?void 0:n.originalEvent)==null?void 0:u.stopPropagation)==null||f.call(u)}catch{}this.openVertexMenu(h,n)},c=n=>{const r=n==null?void 0:n.originalEvent;r&&(r.ctrlKey||r.metaKey)&&this.openVertexMenu(h,n)};try{h.on("contextmenu",s),h.on("click",c)}catch{}}openVertexMenu(h,s){try{if(!this.map||!(typeof h.getLatLngs=="function"&&(h instanceof this.L.Polygon||h instanceof this.L.Polyline)))return;const n=h.editing;if(!n||typeof n.enabled!="function"||!n.enabled())return;const r=s==null?void 0:s.latlng,a=this.map.latLngToContainerPoint(r),u=this.findNearestVertex(h,r,12);if(!u)return;this.showVertexMenu(a,async()=>{await this.deleteVertex(h,u.pathIndex,u.vertexIndex)})}catch(c){this._error("openVertexMenu",c)}}showVertexMenu(h,s){var c;try{try{(c=this.vertexMenuCleanup)==null||c.call(this)}catch{}if(this.vertexMenuCleanup=null,!this.container)return;const n=document.createElement("div");n.style.position="absolute",n.style.top=`${h.y}px`,n.style.left=`${h.x}px`,n.style.transform="translate(-50%, -100%)",n.style.background="#fff",n.style.border="1px solid rgba(0,0,0,0.15)",n.style.borderRadius="6px",n.style.boxShadow="0 4px 12px rgba(0,0,0,0.15)",n.style.padding="6px",n.style.zIndex="10000",n.style.fontSize="12px",n.style.userSelect="none";const r=document.createElement("button");r.textContent="Delete vertex",r.style.padding="6px 10px",r.style.border="none",r.style.background="#da1e28",r.style.color="#fff",r.style.borderRadius="4px",r.style.cursor="pointer",r.addEventListener("click",f=>{f.stopPropagation(),f.preventDefault();try{s()}finally{a()}}),n.appendChild(r);const a=()=>{try{window.removeEventListener("pointerdown",u),this.container.removeEventListener("scroll",a,!0),n.remove()}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null},u=f=>{n.contains(f.target)||a()};window.addEventListener("pointerdown",u,{capture:!0}),this.container.addEventListener("scroll",a,!0),this.container.appendChild(n),this.vertexMenuEl=n,this.vertexMenuCleanup=a}catch(n){this._error("showVertexMenu",n)}}findNearestVertex(h,s,c){if(!this.map)return null;const n=x=>this.map.latLngToContainerPoint(x),r=(x,E)=>Math.hypot(x.x-E.x,x.y-E.y),a=n(s);let u=1/0,f=-1,_=-1;const m=h.getLatLngs();return(Array.isArray(m[0])?m:[m]).forEach((x,E)=>{x.forEach((P,M)=>{const U=n(P),H=r(U,a);H<u&&(u=H,f=E,_=M)})}),f===-1||u>c?null:{pathIndex:f,vertexIndex:_}}async deleteVertex(h,s,c){var n,r,a;try{if(!(typeof h.getLatLngs=="function"&&(h instanceof this.L.Polygon||h instanceof this.L.Polyline)))return;const f=h.getLatLngs(),_=Array.isArray(f[0])?f:[f],m=_[s];if(!m)return;const x=h instanceof this.L.Polygon?3:2;if(m.length<=x)return;if(m.splice(c,1),_.length===1)h.setLatLngs(m);else{const P=_.map((M,U)=>U===s?m:M);h.setLatLngs(P)}(n=h.redraw)==null||n.call(h);const E=h._fid;if(E){const P=h.toGeoJSON();this.store.update(E,P),(a=(r=this.options.callbacks)==null?void 0:r.onEdited)==null||a.call(r,{ids:[E],geoJSON:this.store.toFeatureCollection()})}}catch(u){this._error("deleteVertex",u)}}showMoveConfirmationUI(h,s,c){var n,r;try{if(this.hideMoveConfirmationUI(),!this.container||!this.map)return;const a=this.drawControl;if(!a)return;const u=(n=a==null?void 0:a._toolbars)==null?void 0:n.draw;if(!u)return;const f=u._modes||{};let _=null;for(const E in f){const P=f[E];if(((r=P==null?void 0:P.handler)==null?void 0:r.type)==="move"){_=P.handler;break}}this.activeMoveHandler=_;const m=document.createElement("div");m.style.position="absolute",m.style.bottom="60px",m.style.left="50%",m.style.transform="translateX(-50%)",m.style.display="flex",m.style.gap="8px",m.style.background="#fff",m.style.border="2px solid #3388ff",m.style.borderRadius="8px",m.style.padding="12px 16px",m.style.boxShadow="0 4px 12px rgba(0,0,0,0.2)",m.style.zIndex="10000",m.style.fontSize="14px",m.style.fontFamily="system-ui, sans-serif";const w=document.createElement("button");w.textContent="✓ Save",w.style.padding="8px 16px",w.style.border="none",w.style.background="#28a745",w.style.color="#fff",w.style.borderRadius="4px",w.style.cursor="pointer",w.style.fontWeight="600",w.style.fontSize="14px",w.addEventListener("click",E=>{E.stopPropagation(),E.preventDefault(),_!=null&&_.confirmMove&&_.confirmMove()});const x=document.createElement("button");x.textContent="✕ Cancel",x.style.padding="8px 16px",x.style.border="1px solid #ccc",x.style.background="#fff",x.style.color="#333",x.style.borderRadius="4px",x.style.cursor="pointer",x.style.fontWeight="600",x.style.fontSize="14px",x.addEventListener("click",E=>{E.stopPropagation(),E.preventDefault(),_!=null&&_.cancelMove&&_.cancelMove(),this.hideMoveConfirmationUI()}),m.appendChild(w),m.appendChild(x),this.container.appendChild(m),this.moveConfirmationUI=m,this.logger.debug("showMoveConfirmationUI",{layerId:h._fid})}catch(a){this._error("showMoveConfirmationUI",a)}}hideMoveConfirmationUI(){try{this.moveConfirmationUI&&(this.moveConfirmationUI.remove(),this.moveConfirmationUI=null),this.activeMoveHandler=null}catch(h){this._error("hideMoveConfirmationUI",h)}}}class ti extends HTMLElement{constructor(){super();k(this,"_root");k(this,"_container");k(this,"_logger",ge("component:leaflet-geokit","debug"));k(this,"_latitude",0);k(this,"_longitude",0);k(this,"_zoom",2);k(this,"_minZoom");k(this,"_maxZoom");k(this,"_tileUrl","https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png");k(this,"_tileAttribution");k(this,"_readOnly",!1);k(this,"_logLevel","debug");k(this,"_devOverlay",!1);k(this,"_polygonAllowIntersection",!1);k(this,"_preferCanvas",!0);k(this,"_themeUrl");k(this,"_themeCss","");k(this,"_themeLinkEl",null);k(this,"_themeStyleEl",null);k(this,"_controller",null);k(this,"_useExternalLeaflet",!1);k(this,"_skipLeafletStyles",!1);k(this,"_leafletInstance");this._root=this.attachShadow({mode:"open"}),this._root.innerHTML=`
|
|
241
|
+
`,Yi=6378137,Ht=6356752314245e-6,Ot=1/298.257223563,er=Math.PI/180,ir=180/Math.PI,be=1e9;function nr(m){const c=BigInt(Math.round(m*be));return Number(c)/be}function Ft(m){return nr(m)*er}function qi(m){const c=m*ir%360;return c<0?c+360:c}function $e(m){const c=BigInt(Math.round(m*be));return Number(c)/be}function or(m,c,s,h){const n=rr(m,c,s,h);if(n.converged)return{meters:$e(n.distanceMeters),bearingDegrees:qi(n.bearingRad),algorithm:"vincenty",iterations:n.iterations};const r=sr(m,c,s,h);return{meters:$e(r.distanceMeters),bearingDegrees:qi(r.bearingRad),algorithm:"karney",iterations:n.iterations}}function rr(m,c,s,h){const n=Ft(m),r=Ft(s),a=Ft(h-c),u=Math.atan((1-Ot)*Math.tan(n)),f=Math.atan((1-Ot)*Math.tan(r)),_=Math.sin(u),g=Math.cos(u),w=Math.sin(f),x=Math.cos(f);let M=a,E=0,P=0;const U=200;let H=0,S=0,D=0,G=0,Y=0;for(;Math.abs(M-E)>1e-12&&P<U;){const rt=Math.sin(M),Me=Math.cos(M);if(H=Math.sqrt((x*rt)**2+(g*w-_*x*Me)**2),H===0)return{distanceMeters:0,bearingRad:0,iterations:P,converged:!0};S=_*w+g*x*Me,D=Math.atan2(H,S);const pt=g*x*rt/H;G=1-pt**2,Y=G===0?0:S-2*_*w/G;const ie=Ot/16*G*(4+Ot*(4-3*G));E=M,M=a+(1-ie)*Ot*pt*(D+ie*H*(Y+ie*S*(-1+2*Y**2))),P+=1}if(P>=U)return{distanceMeters:Number.NaN,bearingRad:0,iterations:P,converged:!1};const q=(Yi**2-Ht**2)/Ht**2*G,at=1+q/16384*(4096+q*(-768+q*(320-175*q))),vt=q/1024*(256+q*(-128+q*(74-47*q))),Gt=vt*H*(Y+vt/4*(S*(-1+2*Y**2)-vt/6*Y*(-3+4*H**2)*(-3+4*Y**2))),Ae=Ht*at*(D-Gt),ot=Math.atan2(x*Math.sin(M),g*w-_*x*Math.cos(M));return{distanceMeters:Ae,bearingRad:ot,iterations:P,converged:!0}}function sr(m,c,s,h){const n=Ft(m),r=Ft(s),a=Ft(h-c),u=Math.atan((1-Ot)*Math.tan(n)),f=Math.atan((1-Ot)*Math.tan(r)),_=Math.sin(u),g=Math.cos(u),w=Math.sin(f),x=Math.cos(f),M=Math.sqrt((x*Math.sin(a))**2+(g*w-_*x*Math.cos(a))**2),E=_*w+g*x*Math.cos(a),P=Math.atan2(M,E);if(P===0)return{distanceMeters:0,bearingRad:0};const H=1-(g*x*Math.sin(a)/Math.sin(P))**2,S=H===0?0:E-2*_*w/H,D=(Yi**2-Ht**2)/Ht**2*H,G=1+D/16384*(4096+D*(-768+D*(320-175*D))),Y=D/1024*(256+D*(-128+D*(74-47*D))),q=Y*M*(S+Y/4*(E*(-1+2*S**2)-Y/6*S*(-3+4*M**2)*(-3+4*S**2))),at=Ht*G*(P-q),vt=Math.atan2(x*Math.sin(a),g*w-_*x*Math.cos(a));return{distanceMeters:at,bearingRad:vt}}const ar={position:"topleft",circleMarker:{color:"red",radius:2},lineStyle:{color:"red",dashArray:"1,6"},angleUnit:{display:"°",decimal:2,factor:null,label:"Bearing:"}},lr={display:"km",decimal:2,factor:null,label:"Distance (km):"},hr={display:"mi",decimal:2,factor:.621371,label:"Distance (mi):"};function cr(m){const c=m==="imperial"?{...hr}:{...lr};return{...ar,lengthUnit:c}}const dr={metric:"Meters / Kilometers",imperial:"Feet / Miles"};function ti(m,c={}){var r,a;const s=!!((r=m==null?void 0:m.Control)!=null&&r.Draw),h=!!m.draw,n=s&&h;return n||(a=c.onError)==null||a.call(c,"Leaflet.draw is not available on the provided Leaflet instance"),n}let ji=!1;class ur{constructor(c){k(this,"container");k(this,"logger");k(this,"options");k(this,"L");k(this,"store");k(this,"map",null);k(this,"tileLayer",null);k(this,"drawnItems",null);k(this,"drawControl",null);k(this,"rulerControl",null);k(this,"measurementControl",null);k(this,"measurementSystem","metric");k(this,"measurementModalOverlay",null);k(this,"measurementModalDialog",null);k(this,"measurementModalRadios",{});k(this,"measurementModalKeydownHandler",null);k(this,"detachPolygonFinishPatch",null);k(this,"vertexMenuEl",null);k(this,"vertexMenuCleanup",null);k(this,"activeCakeSession",null);k(this,"moveConfirmationUI",null);k(this,"activeMoveHandler",null);var s;this.options=c,this.container=c.container,this.logger=((s=c.logger)!=null?s:ve("controller","debug")).child("map"),this.L=this.resolveLeaflet(c),this.store=new Zo(this.logger.child("store")),this.logger.debug("ctor",{config:c.map,controls:c.controls,readOnly:c.readOnly,useExternalLeaflet:c.useExternalLeaflet}),Fo(this.L),Go(this.L),Ho(this.L)}resolveLeaflet(c){if(!c.useExternalLeaflet)return ye;if(c.leaflet&&ti(c.leaflet))return this.logger.debug("leaflet-runtime:external-injected"),c.leaflet;const h=globalThis.L;return h&&ti(h)?(this.logger.debug("leaflet-runtime:external-global"),h):(this.logger.warn("leaflet-runtime:external-fallback-bundled",{message:"External Leaflet requested but Draw APIs were missing; falling back to bundled Leaflet/Draw"}),ye)}async init(){var s,h,n,r,a,u;const c=(h=(s=performance.now)==null?void 0:s.call(performance))!=null?h:Date.now();try{await this.destroy();const{latitude:f,longitude:_,zoom:g,minZoom:w,maxZoom:x,tileUrl:M,tileAttribution:E,preferCanvas:P=!0,useExternalLeaflet:U}=this.options.map,H=[f,_],S=this.L;U&&ti(S,{onError:at=>this.logger.warn("external-leaflet-missing-draw",{message:at})}),this.map=S.map(this.container,{zoomControl:!0,preferCanvas:P}).setView(H,g),this.setTileLayer({urlTemplate:M,attribution:E!=null?E:"",maxZoom:x}),this.drawnItems=S.featureGroup().addTo(this.map);const D=this.buildDrawOptions(this.options.controls,!!this.options.readOnly),G=S.Control.Draw;this.drawControl=new G(D),this.map.addControl(this.drawControl),this.applyLayerCakeToolbarIcon(),this.applyMoveToolbarIcon(),this.options.controls.ruler&&(this.logger.debug("init:ruler",{available:typeof S.control.ruler=="function"}),typeof S.control.ruler=="function"?(this.addRulerControl(),this.installMeasurementSettingsControl()):this.logger.warn("init:ruler:missing",{msg:"L.control.ruler is not defined"})),this.patchLeafletDrawBugs(),this.installPolygonFinishPatch(),this.map.invalidateSize(),setTimeout(()=>{var at;try{(at=this.map)==null||at.invalidateSize()}catch{}},0),this.bindDrawEvents();const Y=((r=(n=performance.now)==null?void 0:n.call(performance))!=null?r:Date.now())-c;this.logger.debug("init:ready",{elapsedMs:Math.round(Y)});const q=this.store.bounds();(u=(a=this.options.callbacks)==null?void 0:a.onReady)==null||u.call(a,q?{bounds:q}:{})}catch(f){this._error("Failed to initialize Leaflet map",f)}}async destroy(){var c,s,h;try{this.map&&(this.map.off(),this.map.remove())}catch(n){this._error("Failed to remove Leaflet map",n)}try{(c=this.detachPolygonFinishPatch)==null||c.call(this)}catch{}this.detachPolygonFinishPatch=null;try{(s=this.vertexMenuCleanup)==null||s.call(this)}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null;try{this.hideMoveConfirmationUI()}catch{}this.drawControl=null,this.rulerControl=null,this.measurementControl=null,this.removeMeasurementModal(),this.drawnItems=null,this.tileLayer=null;try{(h=this.activeCakeSession)==null||h.destroy()}catch{}this.activeCakeSession=null,this.map=null}async getGeoJSON(){return this.store.toFeatureCollection()}async loadGeoJSON(c,s=!1){if(!this.map||!this.drawnItems)return;await this.clearLayers();const h=Hi(c),n=this.store.add(h),r=this.L.geoJSON(h);let a=0;r.eachLayer(u=>{var f;u._fid=(f=n[a])!=null?f:n[n.length-1],this.drawnItems.addLayer(u),this.installVertexContextMenu(u),a++}),this.logger.debug("loadGeoJSON",{count:h.features.length,ids:n}),s&&await this.fitBoundsToData()}async clearLayers(){this.drawnItems&&this.drawnItems.clearLayers(),this.store.clear()}async addFeatures(c){if(!this.map||!this.drawnItems)return[];const s=Hi(c),h=this.store.add(s),n=this.L.geoJSON(s);let r=0;return n.eachLayer(a=>{var u;a._fid=(u=h[r])!=null?u:h[h.length-1],this.drawnItems.addLayer(a),this.installVertexContextMenu(a),r++}),h}async updateFeature(c,s){this.store.update(c,s)}async removeFeature(c){this.drawnItems&&this.drawnItems.eachLayer(s=>{s._fid===c&&this.drawnItems.removeLayer(s)}),this.store.remove(c)}async fitBoundsToData(c=.05){if(!this.map)return;const s=this.store.bounds();if(!s)return;const h=s,n=this.L.latLngBounds(h);if(c>0){const r=n.getSouthWest(),a=n.getNorthEast(),u=(a.lat-r.lat)*c,f=(a.lng-r.lng)*c,_=this.L.latLngBounds(this.L.latLng(r.lat-u,r.lng-f),this.L.latLng(a.lat+u,a.lng+f));this.map.fitBounds(_)}else this.map.fitBounds(n)}async fitBounds(c,s=.05){if(!this.map)return;const h=this.L.latLngBounds(c);if(s>0){const n=h.getSouthWest(),r=h.getNorthEast(),a=(r.lat-n.lat)*s,u=(r.lng-n.lng)*s,f=this.L.latLngBounds(this.L.latLng(n.lat-a,n.lng-u),this.L.latLng(r.lat+a,r.lng+u));this.map.fitBounds(f)}else this.map.fitBounds(h)}async setView(c,s,h){this.map&&this.map.setView([c,s],h!=null?h:this.map.getZoom())}setTileLayer(c,s){if(!this.map){this.logger.warn("setTileLayer called before map initialization",{urlTemplate:c.urlTemplate});return}this.logger.debug("tile-layer:switch",{urlTemplate:c.urlTemplate,attribution:c.attribution,maxZoom:c.maxZoom,subdomains:c.subdomains}),this.tileLayer&&(this.map.removeLayer(this.tileLayer),this.tileLayer=null);const h={attribution:c.attribution,minZoom:this.options.map.minZoom,maxZoom:c.maxZoom};c.subdomains!==void 0?h.subdomains=c.subdomains:c.urlTemplate.includes("{s}")&&(h.subdomains=["a","b","c"]);const n=this.L.tileLayer(c.urlTemplate,h);let r=!1;n.on("tileerror",a=>{var u;this.logger.error("tile-layer:error",{error:a}),r||(r=!0,(u=s==null?void 0:s.onTileError)==null||u.call(s,a))}),n.addTo(this.map),this.tileLayer=n}async mergeVisiblePolygons(c){if(!this.map||!this.drawnItems)return null;const h=(await this.getGeoJSON()).features.filter(u=>{const f=u.geometry;return f&&(Fi(f)||Gi(f))});if(h.length<=1){if(h.length===1){const u=h[0].id;return u?String(u):null}return null}const n=No(h,c==null?void 0:c.properties);if(!n)return null;const r=[];for(const u of h){const f=u.id;f&&r.push(String(f))}for(const u of r)await this.removeFeature(u);const[a]=await this.addFeatures({type:"FeatureCollection",features:[n]});return a||null}setRulerUnits(c){this.measurementSystem!==c&&(this.measurementSystem=c,this.logger.debug("ruler:units",{system:c}),this.syncMeasurementModalState(),this.rebuildRulerControl())}buildDrawOptions(c,s){var r;const h={polygon:c.polygon?{allowIntersection:(r=this.options.map.polygonAllowIntersection)!=null?r:!1,showArea:!0,shapeOptions:{color:"#3388ff"}}:!1,polyline:c.polyline?{shapeOptions:{color:"#3388ff"}}:!1,rectangle:c.rectangle?{shapeOptions:{color:"#3388ff"}}:!1,circle:c.circle?{shapeOptions:{color:"#3388ff"}}:!1,cake:c.cake?{shapeOptions:{color:"#8A2BE2",fillOpacity:.2}}:!1,marker:c.marker?{}:!1,move:c.move?{featureGroup:this.drawnItems}:!1};let n={featureGroup:this.drawnItems};return c.edit?c.delete===!1&&(n.remove=!1):n=!1,s?{draw:!1,edit:!1}:{draw:h,edit:n}}applyLayerCakeToolbarIcon(){if(!this.container)return;const c=()=>{const s=this.container.querySelector("a.leaflet-draw-draw-cake");if(!s)return;s.style.setProperty("background-image","none","important"),s.style.setProperty("background-color","#fff","important"),s.style.setProperty("position","relative","important");let h=s.querySelector(".leaflet-geokit-cake-icon");h||(h=document.createElement("span"),h.className="leaflet-geokit-cake-icon",h.setAttribute("aria-hidden","true"),s.appendChild(h)),h.style.setProperty("position","absolute","important"),h.style.setProperty("display","block","important"),h.style.setProperty("left","50%","important"),h.style.setProperty("top","50%","important"),h.style.setProperty("width","18px","important"),h.style.setProperty("height","18px","important"),h.style.setProperty("transform","translate(-50%, -50%)","important"),h.style.setProperty("pointer-events","none","important"),h.firstElementChild||(h.innerHTML=$o);const n=h.firstElementChild;n&&(n.style.setProperty("width","100%","important"),n.style.setProperty("height","100%","important"),n.style.setProperty("display","block","important"))};c(),setTimeout(c,0)}applyMoveToolbarIcon(){if(!this.container)return;const c=()=>{const s=this.container.querySelector("a.leaflet-draw-draw-move");if(!s)return;s.style.setProperty("background-image","none","important"),s.style.setProperty("background-color","#fff","important"),s.style.setProperty("position","relative","important");let h=s.querySelector(".leaflet-geokit-move-icon");h||(h=document.createElement("span"),h.className="leaflet-geokit-move-icon",h.setAttribute("aria-hidden","true"),s.appendChild(h)),h.style.setProperty("position","absolute","important"),h.style.setProperty("display","block","important"),h.style.setProperty("left","50%","important"),h.style.setProperty("top","50%","important"),h.style.setProperty("width","18px","important"),h.style.setProperty("height","18px","important"),h.style.setProperty("transform","translate(-50%, -50%)","important"),h.style.setProperty("pointer-events","none","important"),h.firstElementChild||(h.innerHTML=tr);const n=h.firstElementChild;n&&(n.style.setProperty("width","100%","important"),n.style.setProperty("height","100%","important"),n.style.setProperty("display","block","important"))};c(),setTimeout(c,0)}addRulerControl(){if(!this.map)return;this.installRulerPrecisionPatch();const c=cr(this.measurementSystem);this.rulerControl=this.L.control.ruler(c),this.map.addControl(this.rulerControl)}installRulerPrecisionPatch(){if(ji)return;const c=this.L.Control.Ruler;if(!c||typeof c!="function")return;const s=c.prototype,h=s._calculateBearingAndDistance;if(typeof h!="function")return;const n=this.logger;s._calculateBearingAndDistance=function(){var a,u,f;h.call(this);try{const _=this._clickedLatLong,g=(a=this._movingLatLong)!=null?a:this._clickedLatLong;if(!_||!g)return;const{meters:w,bearingDegrees:x}=or(_.lat,_.lng,g.lat,g.lng),M=w/1e3,E=typeof((f=(u=this.options)==null?void 0:u.lengthUnit)==null?void 0:f.factor)=="number"?this.options.lengthUnit.factor:1,P=$e(M*E);this._result=this._result||{},this._result.Distance=P,this._result.Bearing=x,this._result.meters=w}catch(_){n==null||n.warn("ruler:precision-patch",_)}},ji=!0}rebuildRulerControl(){if(!(!this.map||!this.options.controls.ruler)){if(this.rulerControl){try{this.map.removeControl(this.rulerControl)}catch(c){this.logger.warn("ruler:remove-failed",c)}this.rulerControl=null}this.addRulerControl()}}installMeasurementSettingsControl(){if(!this.map||this.measurementControl)return;const c=this,s=this.L.Control.extend({options:{position:"topleft"},onAdd(){const h=c.L.DomUtil.create("div","leaflet-bar leaflet-ruler-settings-control"),n=c.L.DomUtil.create("button","leaflet-ruler-settings-button",h);return n.type="button",n.title="Measurement settings",n.setAttribute("aria-label","Measurement settings"),n.addEventListener("click",r=>{r.preventDefault(),r.stopPropagation(),c.toggleMeasurementModal(!0)}),c.L.DomEvent.disableClickPropagation(h),c.L.DomEvent.disableScrollPropagation(h),h}});this.measurementControl=new s,this.map.addControl(this.measurementControl)}ensureMeasurementModal(){if(this.measurementModalOverlay)return this.measurementModalOverlay;if(typeof document=="undefined")throw new Error("Measurement modal requires a browser environment");const c=document.createElement("div");c.className="leaflet-ruler-modal-overlay",c.setAttribute("aria-hidden","true");const s=document.createElement("div");s.className="leaflet-ruler-modal",s.setAttribute("role","dialog"),s.setAttribute("aria-modal","true"),s.tabIndex=-1,c.addEventListener("click",f=>{f.target===c&&this.toggleMeasurementModal(!1)});const h=document.createElement("h2");h.className="leaflet-ruler-modal-title",h.textContent="Measurement Units",s.appendChild(h);const n=document.createElement("p");n.className="leaflet-ruler-modal-description",n.textContent="Choose how the measurement tool reports distances.",s.appendChild(n);const r=document.createElement("div");r.className="leaflet-ruler-modal-options",s.appendChild(r),["metric","imperial"].forEach(f=>{const _=document.createElement("label");_.className="leaflet-ruler-modal-option";const g=document.createElement("input");g.type="radio",g.name="leaflet-ruler-units",g.value=f,g.addEventListener("change",()=>{g.checked&&this.setRulerUnits(f)});const w=document.createElement("span");w.textContent=dr[f],_.appendChild(g),_.appendChild(w),r.appendChild(_),this.measurementModalRadios[f]=g});const a=document.createElement("div");a.className="leaflet-ruler-modal-actions";const u=document.createElement("button");return u.type="button",u.className="leaflet-ruler-modal-close",u.textContent="Close",u.addEventListener("click",()=>this.toggleMeasurementModal(!1)),a.appendChild(u),s.appendChild(a),c.appendChild(s),this.container.appendChild(c),this.measurementModalOverlay=c,this.measurementModalDialog=s,this.syncMeasurementModalState(),c}toggleMeasurementModal(c){var h;if(!c){this.measurementModalOverlay&&(this.measurementModalOverlay.classList.remove("is-open"),this.measurementModalOverlay.setAttribute("aria-hidden","true")),this.detachMeasurementModalKeydown();return}const s=this.ensureMeasurementModal();s.classList.add("is-open"),s.setAttribute("aria-hidden","false"),this.syncMeasurementModalState(),this.attachMeasurementModalKeydown(),(h=this.measurementModalDialog)==null||h.focus()}syncMeasurementModalState(){for(const[c,s]of Object.entries(this.measurementModalRadios))s&&(s.checked=c===this.measurementSystem)}removeMeasurementModal(){this.measurementModalOverlay&&this.measurementModalOverlay.remove(),this.measurementModalOverlay=null,this.measurementModalDialog=null,this.measurementModalRadios={},this.detachMeasurementModalKeydown()}attachMeasurementModalKeydown(){this.measurementModalKeydownHandler||typeof document=="undefined"||(this.measurementModalKeydownHandler=c=>{c.key==="Escape"&&this.toggleMeasurementModal(!1)},document.addEventListener("keydown",this.measurementModalKeydownHandler))}detachMeasurementModalKeydown(){!this.measurementModalKeydownHandler||typeof document=="undefined"||(document.removeEventListener("keydown",this.measurementModalKeydownHandler),this.measurementModalKeydownHandler=null)}installPolygonFinishPatch(){var a,u,f,_,g;if(!this.map||!this.drawControl)return;try{(a=this.detachPolygonFinishPatch)==null||a.call(this)}catch{}this.detachPolygonFinishPatch=null;const c=this.map,s=(f=(u=this.drawControl)==null?void 0:u._toolbars)==null?void 0:f.draw;if(!s||!!!((g=(_=s._modes)==null?void 0:_.polygon)!=null&&g.handler))return;const n=10,r=w=>{var x,M,E,P,U,H,S,D;try{const G=(M=(x=s._modes)==null?void 0:x.polygon)==null?void 0:M.handler;if(!G||!G._enabled)return;const Y=G._markers;if(!Array.isArray(Y)||Y.length<4)return;const q=(P=(E=Y[0])==null?void 0:E.getLatLng)==null?void 0:P.call(E);if(!q)return;const at=c.latLngToContainerPoint(q),vt=c.latLngToContainerPoint(w.latlng);Math.hypot(at.x-vt.x,at.y-vt.y)<=n&&typeof G._finishShape=="function"&&((H=(U=w.originalEvent)==null?void 0:U.preventDefault)==null||H.call(U),(D=(S=w.originalEvent)==null?void 0:S.stopPropagation)==null||D.call(S),G._finishShape())}catch(G){this._error("polygon-finish-patch",G)}};c.on("click",r),this.detachPolygonFinishPatch=()=>{try{c.off("click",r)}catch{}}}patchLeafletDrawBugs(){var c,s,h,n,r;try{const a=this.L,u=a.GeometryUtil;if(!u)return;const f={km:2,ha:2,m:0,mi:2,ac:2,yd:0,ft:0,nm:2},_=(s=(c=u.formattedNumber)==null?void 0:c.bind(u))!=null?s:((g,w)=>Number(g).toFixed(w));u.readableArea=(g,w,x)=>{var P;const M=(P=a.Util)!=null&&P.extend?a.Util.extend({},f,x||{}):{...f,...x||{}};let E;if(w){let U=["ha","m"];const H=typeof w;H==="string"?U=[w]:H!=="boolean"&&(U=Array.isArray(w)?w:U),g>=1e6&&U.indexOf("km")!==-1?E=`${_(1e-6*g,M.km)} km²`:g>=1e4&&U.indexOf("ha")!==-1?E=`${_(1e-4*g,M.ha)} ha`:E=`${_(g,M.m)} m²`}else g=g/.836127,g>=3097600?E=`${_(g/3097600,M.mi)} mi²`:g>=4840?E=`${_(g/4840,M.ac)} acres`:E=`${_(g,M.yd)} yd²`;return E}}catch(a){this.logger.warn("leaflet-draw-patch:readableArea",a)}try{const a=this.L,u=(h=a.Edit)==null?void 0:h.Circle,f=(n=a.Draw)==null?void 0:n.Event,_=a.GeometryUtil;if(!((r=u==null?void 0:u.prototype)!=null&&r._resize)||!f||!_)return;u.prototype._resize=function(w){var E,P,U;const x=this._moveMarker.getLatLng(),M=_.isVersion07x()?x.distanceTo(w):this._map.distance(x,w);this._shape.setRadius(M);try{(E=this._map)!=null&&E.editTooltip&&((U=(P=this._map)==null?void 0:P._editTooltip)!=null&&U.updateContent)&&this._map._editTooltip.updateContent({text:a.drawLocal.edit.handlers.edit.tooltip.subtext+"<br />"+a.drawLocal.edit.handlers.edit.tooltip.text,subtext:a.drawLocal.draw.handlers.circle.radius+": "+_.readableDistance(M,!0,this.options.feet,this.options.nautic)})}catch{}this._map.fire(f.EDITRESIZE,{layer:this._shape})}}catch(a){this.logger.warn("leaflet-draw-patch:circle-resize",a)}}bindDrawEvents(){!this.map||!this.drawnItems||(this.map.on(this.L.Draw.Event.CREATED,c=>{var s,h,n;try{const{layer:r,layerType:a}=c;if(a===we.TYPE){try{(s=this.activeCakeSession)==null||s.destroy()}catch{}this.activeCakeSession=new Qo(this.map,r,g=>{if(!this.drawnItems)return;const w=this.store.add(g),x=this.L.geoJSON(g);let M=0;x.eachLayer(E=>{var U,H,S;const P=(U=w[M])!=null?U:w[w.length-1];E._fid=P,this.drawnItems.addLayer(E),this.installVertexContextMenu(E),(S=(H=this.options.callbacks)==null?void 0:H.onCreated)==null||S.call(H,{id:P,layerType:"polygon",geoJSON:E.toGeoJSON()}),M++}),this.activeCakeSession=null},this.measurementSystem);return}this.drawnItems.addLayer(r);const u=r.toGeoJSON(),_=this.store.add({type:"FeatureCollection",features:[u]})[0];r._fid=_,this.installVertexContextMenu(r),(n=(h=this.options.callbacks)==null?void 0:h.onCreated)==null||n.call(h,{id:_,layerType:a,geoJSON:u})}catch(r){this._error("onCreated handler failed",r)}}),this.map.on(this.L.Draw.Event.EDITED,c=>{var s,h;try{const n=[];c.layers.eachLayer(a=>{const u=a.toGeoJSON(),f=a._fid;if(f)this.store.update(f,u),n.push(f);else{const _=this.store.add({type:"FeatureCollection",features:[u]})[0];a._fid=_,n.push(_)}}),(h=(s=this.options.callbacks)==null?void 0:s.onEdited)==null||h.call(s,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onEdited handler failed",n)}}),this.map.on(this.L.Draw.Event.DELETED,c=>{var s,h;try{const n=[];c.layers.eachLayer(a=>{const u=a._fid;u&&(n.push(u),this.store.remove(u))}),(h=(s=this.options.callbacks)==null?void 0:s.onDeleted)==null||h.call(s,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onDeleted handler failed",n)}}),this.map.on("draw:moveend",c=>{try{this.showMoveConfirmationUI(c.layer,c.originalGeoJSON,c.newGeoJSON)}catch(s){this._error("draw:moveend handler failed",s)}}),this.map.on("draw:moveconfirmed",c=>{var s,h;try{const n=c.layer,r=n._fid;if(r){const a=n.toGeoJSON();this.store.update(r,a),(h=(s=this.options.callbacks)==null?void 0:s.onEdited)==null||h.call(s,{ids:[r],geoJSON:this.store.toFeatureCollection()})}this.hideMoveConfirmationUI()}catch(n){this._error("draw:moveconfirmed handler failed",n)}}))}_error(c,s){var h,n;this.logger.error("error",{message:c,cause:s}),(n=(h=this.options.callbacks)==null?void 0:h.onError)==null||n.call(h,{message:c,cause:s})}installVertexContextMenu(c){if(!c||typeof c.on!="function")return;const s=n=>{var r,a,u,f;try{(a=(r=n==null?void 0:n.originalEvent)==null?void 0:r.preventDefault)==null||a.call(r),(f=(u=n==null?void 0:n.originalEvent)==null?void 0:u.stopPropagation)==null||f.call(u)}catch{}this.openVertexMenu(c,n)},h=n=>{const r=n==null?void 0:n.originalEvent;r&&(r.ctrlKey||r.metaKey)&&this.openVertexMenu(c,n)};try{c.on("contextmenu",s),c.on("click",h)}catch{}}openVertexMenu(c,s){try{if(!this.map||!(typeof c.getLatLngs=="function"&&(c instanceof this.L.Polygon||c instanceof this.L.Polyline)))return;const n=c.editing;if(!n||typeof n.enabled!="function"||!n.enabled())return;const r=s==null?void 0:s.latlng,a=this.map.latLngToContainerPoint(r),u=this.findNearestVertex(c,r,12);if(!u)return;this.showVertexMenu(a,async()=>{await this.deleteVertex(c,u.pathIndex,u.vertexIndex)})}catch(h){this._error("openVertexMenu",h)}}showVertexMenu(c,s){var h;try{try{(h=this.vertexMenuCleanup)==null||h.call(this)}catch{}if(this.vertexMenuCleanup=null,!this.container)return;const n=document.createElement("div");n.style.position="absolute",n.style.top=`${c.y}px`,n.style.left=`${c.x}px`,n.style.transform="translate(-50%, -100%)",n.style.background="#fff",n.style.border="1px solid rgba(0,0,0,0.15)",n.style.borderRadius="6px",n.style.boxShadow="0 4px 12px rgba(0,0,0,0.15)",n.style.padding="6px",n.style.zIndex="10000",n.style.fontSize="12px",n.style.userSelect="none";const r=document.createElement("button");r.textContent="Delete vertex",r.style.padding="6px 10px",r.style.border="none",r.style.background="#da1e28",r.style.color="#fff",r.style.borderRadius="4px",r.style.cursor="pointer",r.addEventListener("click",f=>{f.stopPropagation(),f.preventDefault();try{s()}finally{a()}}),n.appendChild(r);const a=()=>{try{window.removeEventListener("pointerdown",u),this.container.removeEventListener("scroll",a,!0),n.remove()}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null},u=f=>{n.contains(f.target)||a()};window.addEventListener("pointerdown",u,{capture:!0}),this.container.addEventListener("scroll",a,!0),this.container.appendChild(n),this.vertexMenuEl=n,this.vertexMenuCleanup=a}catch(n){this._error("showVertexMenu",n)}}findNearestVertex(c,s,h){if(!this.map)return null;const n=x=>this.map.latLngToContainerPoint(x),r=(x,M)=>Math.hypot(x.x-M.x,x.y-M.y),a=n(s);let u=1/0,f=-1,_=-1;const g=c.getLatLngs();return(Array.isArray(g[0])?g:[g]).forEach((x,M)=>{x.forEach((E,P)=>{const U=n(E),H=r(U,a);H<u&&(u=H,f=M,_=P)})}),f===-1||u>h?null:{pathIndex:f,vertexIndex:_}}async deleteVertex(c,s,h){var n,r,a;try{if(!(typeof c.getLatLngs=="function"&&(c instanceof this.L.Polygon||c instanceof this.L.Polyline)))return;const f=c.getLatLngs(),_=Array.isArray(f[0])?f:[f],g=_[s];if(!g)return;const x=c instanceof this.L.Polygon?3:2;if(g.length<=x)return;if(g.splice(h,1),_.length===1)c.setLatLngs(g);else{const E=_.map((P,U)=>U===s?g:P);c.setLatLngs(E)}(n=c.redraw)==null||n.call(c);const M=c._fid;if(M){const E=c.toGeoJSON();this.store.update(M,E),(a=(r=this.options.callbacks)==null?void 0:r.onEdited)==null||a.call(r,{ids:[M],geoJSON:this.store.toFeatureCollection()})}}catch(u){this._error("deleteVertex",u)}}showMoveConfirmationUI(c,s,h){var n,r;try{if(this.hideMoveConfirmationUI(),!this.container||!this.map)return;const a=this.drawControl;if(!a)return;const u=(n=a==null?void 0:a._toolbars)==null?void 0:n.draw;if(!u)return;const f=u._modes||{};let _=null;for(const M in f){const E=f[M];if(((r=E==null?void 0:E.handler)==null?void 0:r.type)==="move"){_=E.handler;break}}this.activeMoveHandler=_;const g=document.createElement("div");g.style.position="absolute",g.style.bottom="60px",g.style.left="50%",g.style.transform="translateX(-50%)",g.style.display="flex",g.style.gap="8px",g.style.background="#fff",g.style.border="2px solid #3388ff",g.style.borderRadius="8px",g.style.padding="12px 16px",g.style.boxShadow="0 4px 12px rgba(0,0,0,0.2)",g.style.zIndex="10000",g.style.fontSize="14px",g.style.fontFamily="system-ui, sans-serif";const w=document.createElement("button");w.textContent="✓ Save",w.style.padding="8px 16px",w.style.border="none",w.style.background="#28a745",w.style.color="#fff",w.style.borderRadius="4px",w.style.cursor="pointer",w.style.fontWeight="600",w.style.fontSize="14px",w.addEventListener("click",M=>{M.stopPropagation(),M.preventDefault(),_!=null&&_.confirmMove&&_.confirmMove()});const x=document.createElement("button");x.textContent="✕ Cancel",x.style.padding="8px 16px",x.style.border="1px solid #ccc",x.style.background="#fff",x.style.color="#333",x.style.borderRadius="4px",x.style.cursor="pointer",x.style.fontWeight="600",x.style.fontSize="14px",x.addEventListener("click",M=>{M.stopPropagation(),M.preventDefault(),_!=null&&_.cancelMove&&_.cancelMove(),this.hideMoveConfirmationUI()}),g.appendChild(w),g.appendChild(x),this.container.appendChild(g),this.moveConfirmationUI=g,this.logger.debug("showMoveConfirmationUI",{layerId:c._fid})}catch(a){this._error("showMoveConfirmationUI",a)}}hideMoveConfirmationUI(){try{this.moveConfirmationUI&&(this.moveConfirmationUI.remove(),this.moveConfirmationUI=null),this.activeMoveHandler=null}catch(c){this._error("hideMoveConfirmationUI",c)}}}const Ct={osm:{urlTemplate:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors',maxZoom:19,subdomains:["a","b","c"]},here:{styles:{"lite.day":"lite.day","normal.day":"normal.day","satellite.day":"satellite.day"},defaultStyle:"lite.day",attribution:'Map Tiles © <a href="https://www.here.com">HERE</a>',maxZoom:20}};function Ji(m){return typeof m=="string"?m.trim().toLowerCase():""}function Ki(m){if(typeof m!="string")return;const c=m.trim();return c.length>0?c:void 0}function fr(m){const{style:c,attribution:s}=m,h=Ji(m.provider),n=Ki(m.apiKey);switch(h){case"osm":return{urlTemplate:Ct.osm.urlTemplate,attribution:s||Ct.osm.attribution,maxZoom:Ct.osm.maxZoom,subdomains:[...Ct.osm.subdomains]};case"here":{if(!n)throw new Error("HERE Maps requires an API key");const r=typeof c=="string"?c.trim():"",a=r&&r in Ct.here.styles?r:Ct.here.defaultStyle;return{urlTemplate:`https://maps.hereapi.com/v3/base/mc/{z}/{x}/{y}/png8?style=${encodeURIComponent(a)}&apiKey=${encodeURIComponent(n)}`,attribution:s||Ct.here.attribution,maxZoom:Ct.here.maxZoom,subdomains:void 0}}default:throw new Error(`Unknown tile provider: ${m.provider}`)}}function pr(m){const c=Ji(m.provider),s=Ki(m.apiKey);return c?c==="here"&&!s?{valid:!1,error:"HERE Maps requires an API key"}:{valid:!0}:{valid:!1,error:"Provider is required"}}class ei extends HTMLElement{constructor(){super();k(this,"_root");k(this,"_container");k(this,"_logger",ve("component:leaflet-geokit","debug"));k(this,"_latitude",0);k(this,"_longitude",0);k(this,"_zoom",2);k(this,"_minZoom");k(this,"_maxZoom");k(this,"_tileUrl","https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png");k(this,"_tileAttribution");k(this,"_tileProvider");k(this,"_tileStyle");k(this,"_apiKey");k(this,"_activeTileProvider","tile-url");k(this,"_readOnly",!1);k(this,"_logLevel","debug");k(this,"_devOverlay",!1);k(this,"_polygonAllowIntersection",!1);k(this,"_preferCanvas",!0);k(this,"_themeUrl");k(this,"_themeCss","");k(this,"_themeLinkEl",null);k(this,"_themeStyleEl",null);k(this,"_controller",null);k(this,"_useExternalLeaflet",!1);k(this,"_skipLeafletStyles",!1);k(this,"_leafletInstance");this._root=this.attachShadow({mode:"open"}),this._root.innerHTML=`
|
|
242
242
|
<style>
|
|
243
243
|
:host {
|
|
244
244
|
display: block;
|
|
@@ -251,5 +251,5 @@ ${mo}
|
|
|
251
251
|
}
|
|
252
252
|
</style>
|
|
253
253
|
<div class="map-container" part="map"></div>
|
|
254
|
-
`;const s=this._root.querySelector(".map-container");if(!(s instanceof HTMLDivElement))throw new Error("Failed to initialize map container");this._container=s;const c=this.getAttribute("log-level");c&&(this._logLevel=c,this._logger.setLevel(c))}_controlsFromAttributes(){return{polygon:this.hasAttribute("draw-polygon"),polyline:this.hasAttribute("draw-polyline"),rectangle:this.hasAttribute("draw-rectangle"),circle:this.hasAttribute("draw-circle"),cake:this.hasAttribute("draw-layer-cake"),marker:this.hasAttribute("draw-marker"),move:this.hasAttribute("draw-move"),edit:this.hasAttribute("edit-features"),delete:this.hasAttribute("delete-features"),ruler:this.hasAttribute("draw-ruler")}}_mapConfig(){return{latitude:this._latitude,longitude:this._longitude,zoom:this._zoom,minZoom:this._minZoom,maxZoom:this._maxZoom,tileUrl:this._tileUrl,tileAttribution:this._tileAttribution,readOnly:this._readOnly,fitToDataOnLoad:!1,logLevel:this._logLevel,devOverlay:this._devOverlay,polygonAllowIntersection:this._polygonAllowIntersection,preferCanvas:this._preferCanvas,useExternalLeaflet:this._useExternalLeaflet,skipLeafletStyles:this._skipLeafletStyles}}async connectedCallback(){var s;this._logger.debug("connectedCallback",this._currentConfig()),Ao({root:this._root,skipStyles:this._skipLeafletStyles}),this._applyThemeStyles(),this._controller=new hr({container:this._container,map:this._mapConfig(),controls:this._controlsFromAttributes(),readOnly:this._readOnly,logger:this._logger.child("controller"),callbacks:{onReady:c=>{this.dispatchEvent(new CustomEvent("leaflet-draw:ready",{detail:c}))},onCreated:c=>{this.dispatchEvent(new CustomEvent("leaflet-draw:created",{detail:c}))},onEdited:c=>{this.dispatchEvent(new CustomEvent("leaflet-draw:edited",{detail:c}))},onDeleted:c=>{this.dispatchEvent(new CustomEvent("leaflet-draw:deleted",{detail:c}))},onError:c=>{this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:c}))}},leaflet:(s=this._leafletInstance)!=null?s:void 0,useExternalLeaflet:this._useExternalLeaflet}),await this._controller.init()}async disconnectedCallback(){this._logger.debug("disconnectedCallback"),this._controller&&(await this._controller.destroy(),this._controller=null)}static get observedAttributes(){return["latitude","longitude","zoom","min-zoom","max-zoom","tile-url","tile-attribution","read-only","log-level","dev-overlay","prefer-canvas","use-external-leaflet","skip-leaflet-styles","theme-url","draw-polygon","draw-polyline","draw-rectangle","draw-circle","draw-layer-cake","draw-marker","draw-move","draw-ruler","edit-features","delete-features","polygon-allow-intersection"]}attributeChangedCallback(s,c,n){switch(this._logger.debug("attributeChanged",{name:s,value:n}),s){case"latitude":this._latitude=this._coerceNumber(n,0);break;case"longitude":this._longitude=this._coerceNumber(n,0);break;case"zoom":this._zoom=this._coerceNumber(n,2);break;case"min-zoom":this._minZoom=n!=null?this._coerceNumber(n):void 0;break;case"max-zoom":this._maxZoom=n!=null?this._coerceNumber(n):void 0;break;case"tile-url":this._tileUrl=n!=null?n:this._tileUrl;break;case"tile-attribution":this._tileAttribution=n!=null?n:void 0;break;case"theme-url":this._themeUrl=n!=null?n:void 0,this.isConnected&&this._applyThemeStyles();break;case"read-only":this._readOnly=n!==null;break;case"log-level":this._logLevel=n!=null?n:this._logLevel,this._logger.setLevel(this._logLevel);break;case"dev-overlay":this._devOverlay=n!==null;break;case"polygon-allow-intersection":this._polygonAllowIntersection=n!==null;break;case"prefer-canvas":this._preferCanvas=n!==null;break;case"use-external-leaflet":this._useExternalLeaflet=n!==null;break;case"skip-leaflet-styles":this._skipLeafletStyles=n!==null;break}this._controller&&(s==="latitude"||s==="longitude"||s==="zoom"?this._controller.setView(this._latitude,this._longitude,this._zoom):(s==="tile-url"||s==="tile-attribution"||s==="min-zoom"||s==="max-zoom"||s==="read-only"||s==="dev-overlay"||s==="log-level"||s==="prefer-canvas"||s==="use-external-leaflet"||s==="skip-leaflet-styles"||s.startsWith("draw-")||s==="edit-features"||s==="delete-features")&&this._controller.destroy().then(()=>this._controller.init()))}get latitude(){return this._latitude}set latitude(s){this._latitude=Number(s),this._reflect("latitude",String(this._latitude))}get longitude(){return this._longitude}set longitude(s){this._longitude=Number(s),this._reflect("longitude",String(this._longitude))}get zoom(){return this._zoom}set zoom(s){this._zoom=Number(s),this._reflect("zoom",String(this._zoom))}get minZoom(){return this._minZoom}set minZoom(s){this._minZoom=s,this._reflect("min-zoom",s!=null?String(s):null)}get maxZoom(){return this._maxZoom}set maxZoom(s){this._maxZoom=s,this._reflect("max-zoom",s!=null?String(s):null)}get tileUrl(){return this._tileUrl}set tileUrl(s){this._tileUrl=s,this._reflect("tile-url",s)}get tileAttribution(){return this._tileAttribution}set tileAttribution(s){this._tileAttribution=s,this._reflect("tile-attribution",s!=null?s:null)}get readOnly(){return this._readOnly}set readOnly(s){this._readOnly=!!s,this._booleanReflect("read-only",this._readOnly)}get logLevel(){return this._logLevel}set logLevel(s){this._logLevel=s,this._logger.setLevel(s),this._reflect("log-level",s)}get devOverlay(){return this._devOverlay}set devOverlay(s){this._devOverlay=!!s,this._booleanReflect("dev-overlay",this._devOverlay)}get preferCanvas(){return this._preferCanvas}set preferCanvas(s){this._preferCanvas=!!s,this._booleanReflect("prefer-canvas",this._preferCanvas)}get useExternalLeaflet(){return this._useExternalLeaflet}set useExternalLeaflet(s){this._useExternalLeaflet=!!s,this._booleanReflect("use-external-leaflet",this._useExternalLeaflet)}get skipLeafletStyles(){return this._skipLeafletStyles}set skipLeafletStyles(s){this._skipLeafletStyles=!!s,this._booleanReflect("skip-leaflet-styles",this._skipLeafletStyles)}get leafletInstance(){return this._leafletInstance}set leafletInstance(s){this._leafletInstance=s}get themeCss(){return this._themeCss}set themeCss(s){this._themeCss=typeof s=="string"?s:"",this.isConnected&&this._applyThemeStyles()}async getGeoJSON(){return this._logger.debug("getGeoJSON"),this._controller?this._controller.getGeoJSON():{type:"FeatureCollection",features:[]}}async loadGeoJSON(s){var r,a;if(this._logger.debug("loadGeoJSON",{features:(a=(r=s==null?void 0:s.features)==null?void 0:r.length)!=null?a:0}),!this._controller)return;const c={fc:s,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:c}));const n=c.fc&&c.fc.type==="FeatureCollection"?c.fc:s;await this._controller.loadGeoJSON(n,!1)}async clearLayers(){this._logger.debug("clearLayers"),this._controller&&await this._controller.clearLayers()}async addFeatures(s){var r,a;if(this._logger.debug("addFeatures",{count:(a=(r=s==null?void 0:s.features)==null?void 0:r.length)!=null?a:0}),!this._controller)return[];const c={fc:s,mode:"add"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:c}));const n=c.fc&&c.fc.type==="FeatureCollection"?c.fc:s;return this._controller.addFeatures(n)}async updateFeature(s,c){this._logger.debug("updateFeature",{id:s}),this._controller&&await this._controller.updateFeature(s,c)}async removeFeature(s){this._logger.debug("removeFeature",{id:s}),this._controller&&await this._controller.removeFeature(s)}async fitBoundsToData(s){this._logger.debug("fitBoundsToData",{padding:s}),this._controller&&await this._controller.fitBoundsToData(typeof s=="number"?s:.05)}async fitBounds(s,c){this._logger.debug("fitBounds",{bounds:s,padding:c}),this._controller&&await this._controller.fitBounds(s,typeof c=="number"?c:.05)}async setView(s,c,n){this._logger.debug("setView",{lat:s,lng:c,zoom:n}),this.latitude=s,this.longitude=c,typeof n=="number"&&(this.zoom=n),this._controller&&await this._controller.setView(s,c,n)}async exportGeoJSON(){if(this._logger.debug("exportGeoJSON"),!this._controller)return{type:"FeatureCollection",features:[]};const s=await this._controller.getGeoJSON(),c={geoJSON:s,featureCount:s.features.length};return this.dispatchEvent(new CustomEvent("leaflet-draw:export",{detail:c})),s}async mergePolygons(s){if(this._logger.debug("mergePolygons"),!this._controller)return null;const n=(await this._controller.getGeoJSON()).features.length,r=await this._controller.mergeVisiblePolygons(s);if(r){const a=await this._controller.getGeoJSON(),u={id:r,mergedFeatureCount:n-a.features.length+1,geoJSON:a};this.dispatchEvent(new CustomEvent("leaflet-draw:merged",{detail:u}))}return r}async setMeasurementUnits(s){this._logger.debug("setMeasurementUnits",{system:s}),this._controller&&this._controller.setRulerUnits(s)}async loadGeoJSONFromUrl(s){if(this._logger.debug("loadGeoJSONFromUrl",{url:s}),!this._controller)return;const c=await fetch(s,{headers:{Accept:"application/json"}});if(!c.ok){const u=new Error(`Failed to fetch GeoJSON from ${s}: ${c.status} ${c.statusText}`);throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:u.message,cause:u}})),u}const n=await c.json(),r={fc:n,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:r}));const a=r.fc&&r.fc.type==="FeatureCollection"?r.fc:n;await this._controller.loadGeoJSON(a,!0)}async loadGeoJSONFromText(s){var a;if(this._logger.debug("loadGeoJSONFromText",{length:(a=s==null?void 0:s.length)!=null?a:0}),!this._controller)return;let c;try{c=JSON.parse(s)}catch(u){const f=new Error("Failed to parse GeoJSON text");throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:f.message,cause:u}})),f}const n={fc:c,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:n}));const r=n.fc&&n.fc.type==="FeatureCollection"?n.fc:c;await this._controller.loadGeoJSON(r,!0)}_currentConfig(){return{latitude:this._latitude,longitude:this._longitude,zoom:this._zoom,minZoom:this._minZoom,maxZoom:this._maxZoom,tileUrl:this._tileUrl,tileAttribution:this._tileAttribution,readOnly:this._readOnly,fitToDataOnLoad:!1,logLevel:this._logLevel,devOverlay:this._devOverlay,polygonAllowIntersection:this._polygonAllowIntersection,preferCanvas:this._preferCanvas,useExternalLeaflet:this._useExternalLeaflet,skipLeafletStyles:this._skipLeafletStyles}}_applyThemeStyles(){var n;const s=(n=this._themeUrl)==null?void 0:n.trim();if(s){if(!this._themeLinkEl){const r=document.createElement("link");r.setAttribute("rel","stylesheet"),r.setAttribute("data-geokit-theme-url","true"),this._root.appendChild(r),this._themeLinkEl=r}this._themeLinkEl.getAttribute("href")!==s&&this._themeLinkEl.setAttribute("href",s)}else this._themeLinkEl&&(this._themeLinkEl.remove(),this._themeLinkEl=null);const c=this._themeCss;if(c.trim().length>0){if(!this._themeStyleEl){const r=document.createElement("style");r.setAttribute("data-geokit-theme-css","true"),this._root.appendChild(r),this._themeStyleEl=r}this._themeStyleEl.textContent!==c&&(this._themeStyleEl.textContent=c)}else this._themeStyleEl&&(this._themeStyleEl.remove(),this._themeStyleEl=null)}_reflect(s,c){c===null?this.removeAttribute(s):this.getAttribute(s)!==c&&this.setAttribute(s,c)}_booleanReflect(s,c){c?this.hasAttribute(s)||this.setAttribute(s,""):this.hasAttribute(s)&&this.removeAttribute(s)}_coerceNumber(s,c){if(s==null)return c!=null?c:NaN;const n=Number(s);return Number.isFinite(n)?n:c!=null?c:NaN}}const cr={Ready:"leaflet-draw:ready",Created:"leaflet-draw:created",Edited:"leaflet-draw:edited",Deleted:"leaflet-draw:deleted",Error:"leaflet-draw:error",Ingest:"leaflet-draw:ingest",Export:"leaflet-draw:export",DrawStart:"leaflet-draw:drawstart",DrawStop:"leaflet-draw:drawstop",EditStart:"leaflet-draw:editstart",EditStop:"leaflet-draw:editstop"},ji="leaflet-geokit";customElements.get(ji)||customElements.define(ji,ti);const Ji="leaflet-draw-map";if(!customElements.get(Ji)){class g extends ti{}customElements.define(Ji,g)}dt.DrawEvent=cr,dt.LeafletDrawMapElement=ti,Object.defineProperty(dt,Symbol.toStringTag,{value:"Module"})}));
|
|
254
|
+
`;const s=this._root.querySelector(".map-container");if(!(s instanceof HTMLDivElement))throw new Error("Failed to initialize map container");this._container=s;const h=this.getAttribute("log-level");h&&(this._logLevel=h,this._logger.setLevel(h))}_controlsFromAttributes(){return{polygon:this.hasAttribute("draw-polygon"),polyline:this.hasAttribute("draw-polyline"),rectangle:this.hasAttribute("draw-rectangle"),circle:this.hasAttribute("draw-circle"),cake:this.hasAttribute("draw-layer-cake"),marker:this.hasAttribute("draw-marker"),move:this.hasAttribute("draw-move"),edit:this.hasAttribute("edit-features"),delete:this.hasAttribute("delete-features"),ruler:this.hasAttribute("draw-ruler")}}_mapConfig(){return{latitude:this._latitude,longitude:this._longitude,zoom:this._zoom,minZoom:this._minZoom,maxZoom:this._maxZoom,tileUrl:this._tileUrl,tileAttribution:this._tileAttribution,readOnly:this._readOnly,fitToDataOnLoad:!1,logLevel:this._logLevel,devOverlay:this._devOverlay,polygonAllowIntersection:this._polygonAllowIntersection,preferCanvas:this._preferCanvas,useExternalLeaflet:this._useExternalLeaflet,skipLeafletStyles:this._skipLeafletStyles}}async connectedCallback(){var s;this._logger.debug("connectedCallback",this._currentConfig()),Po({root:this._root,skipStyles:this._skipLeafletStyles}),this._applyThemeStyles(),this._controller=new ur({container:this._container,map:this._mapConfig(),controls:this._controlsFromAttributes(),readOnly:this._readOnly,logger:this._logger.child("controller"),callbacks:{onReady:h=>{this.dispatchEvent(new CustomEvent("leaflet-draw:ready",{detail:h}))},onCreated:h=>{this.dispatchEvent(new CustomEvent("leaflet-draw:created",{detail:h}))},onEdited:h=>{this.dispatchEvent(new CustomEvent("leaflet-draw:edited",{detail:h}))},onDeleted:h=>{this.dispatchEvent(new CustomEvent("leaflet-draw:deleted",{detail:h}))},onError:h=>{this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:h}))}},leaflet:(s=this._leafletInstance)!=null?s:void 0,useExternalLeaflet:this._useExternalLeaflet}),await this._controller.init(),this._tileProvider&&this._updateTileLayer()}async disconnectedCallback(){this._logger.debug("disconnectedCallback"),this._controller&&(await this._controller.destroy(),this._controller=null)}static get observedAttributes(){return["latitude","longitude","zoom","min-zoom","max-zoom","tile-url","tile-attribution","tile-provider","tile-style","api-key","here-api-key","read-only","log-level","dev-overlay","prefer-canvas","use-external-leaflet","skip-leaflet-styles","theme-url","draw-polygon","draw-polyline","draw-rectangle","draw-circle","draw-layer-cake","draw-marker","draw-move","draw-ruler","edit-features","delete-features","polygon-allow-intersection"]}attributeChangedCallback(s,h,n){switch(this._logger.debug("attributeChanged",{name:s,value:n}),s){case"latitude":this._latitude=this._coerceNumber(n,0);break;case"longitude":this._longitude=this._coerceNumber(n,0);break;case"zoom":this._zoom=this._coerceNumber(n,2);break;case"min-zoom":this._minZoom=n!=null?this._coerceNumber(n):void 0;break;case"max-zoom":this._maxZoom=n!=null?this._coerceNumber(n):void 0;break;case"tile-url":this._tileUrl=n!=null?n:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",this._controller&&this._updateTileLayer();break;case"tile-attribution":this._tileAttribution=n!=null?n:void 0,this._controller&&this._updateTileLayer();break;case"tile-provider":this._tileProvider=this._normalizeText(n,{lowercase:!0}),this._controller&&this._updateTileLayer();break;case"tile-style":this._tileStyle=this._normalizeText(n),this._controller&&this._updateTileLayer();break;case"api-key":case"here-api-key":this._syncApiKeyFromAttributes(),this._controller&&this._updateTileLayer();break;case"theme-url":this._themeUrl=n!=null?n:void 0,this.isConnected&&this._applyThemeStyles();break;case"read-only":this._readOnly=n!==null;break;case"log-level":this._logLevel=n!=null?n:this._logLevel,this._logger.setLevel(this._logLevel);break;case"dev-overlay":this._devOverlay=n!==null;break;case"polygon-allow-intersection":this._polygonAllowIntersection=n!==null;break;case"prefer-canvas":this._preferCanvas=n!==null;break;case"use-external-leaflet":this._useExternalLeaflet=n!==null;break;case"skip-leaflet-styles":this._skipLeafletStyles=n!==null;break}this._controller&&(s==="latitude"||s==="longitude"||s==="zoom"?this._controller.setView(this._latitude,this._longitude,this._zoom):(s==="min-zoom"||s==="max-zoom"||s==="read-only"||s==="dev-overlay"||s==="log-level"||s==="prefer-canvas"||s==="use-external-leaflet"||s==="skip-leaflet-styles"||s.startsWith("draw-")||s==="edit-features"||s==="delete-features")&&this._controller.destroy().then(()=>this._controller.init()))}_updateTileLayer(){var h,n,r,a;if(!this._controller)return;const s=this._controller;if(typeof s.setTileLayer!="function"){this._logger.warn("setTileLayer is not available on MapController yet");return}try{if(this._tileProvider){const u=this._tileProvider,f={provider:u,style:this._tileStyle,apiKey:this._apiKey,attribution:this._tileAttribution},_=pr(f);if(!_.valid){const x=(h=_.error)!=null&&h.toLowerCase().includes("api key")?"missing_api_key":"tile_load_failed";this._handleTileProviderError(x,(n=_.error)!=null?n:"Invalid tile provider configuration",u);return}const g=fr(f),w=this._activeTileProvider;s.setTileLayer(g,{onTileError:x=>{if(this._tileProvider!==u)return;const M=this._describeTileLayerError(x,u),E=u==="here"?this._resolveHereTileLayerErrorCode(M):"tile_load_failed";this._handleTileProviderError(E,M,u)}}),this._activeTileProvider=u,this._emitTileProviderChanged(u,this._tileStyle,w);return}s.setTileLayer({urlTemplate:this._tileUrl,attribution:(r=this._tileAttribution)!=null?r:"",maxZoom:this._maxZoom,subdomains:["a","b","c"]}),this._activeTileProvider="tile-url"}catch(u){const f=this._resolveTileProviderErrorCode(u);this._logger.error("Failed to update tile layer",{error:u,code:f}),this._handleTileProviderError(f,u instanceof Error?u.message:"Unknown tile layer error",(a=this._tileProvider)!=null?a:"unknown")}}_handleTileProviderError(s,h,n){this._logger.error(`Tile provider error (${s}): ${h}`),this.dispatchEvent(new CustomEvent("tile-provider-error",{bubbles:!0,detail:{code:s,message:h,provider:n,timestamp:Date.now()}}));const r=this._controller;typeof r.setTileLayer=="function"&&(r.setTileLayer({urlTemplate:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors',maxZoom:19,subdomains:["a","b","c"]}),this._activeTileProvider="osm")}_emitTileProviderChanged(s,h,n){this.dispatchEvent(new CustomEvent("tile-provider-changed",{bubbles:!0,detail:{provider:s,style:h,previousProvider:n,timestamp:Date.now()}}))}get latitude(){return this._latitude}set latitude(s){this._latitude=Number(s),this._reflect("latitude",String(this._latitude))}get longitude(){return this._longitude}set longitude(s){this._longitude=Number(s),this._reflect("longitude",String(this._longitude))}get zoom(){return this._zoom}set zoom(s){this._zoom=Number(s),this._reflect("zoom",String(this._zoom))}get minZoom(){return this._minZoom}set minZoom(s){this._minZoom=s,this._reflect("min-zoom",s!=null?String(s):null)}get maxZoom(){return this._maxZoom}set maxZoom(s){this._maxZoom=s,this._reflect("max-zoom",s!=null?String(s):null)}get tileUrl(){return this._tileUrl}set tileUrl(s){this._tileUrl=s,this._reflect("tile-url",s),this._controller&&this._updateTileLayer()}get tileProvider(){return this._tileProvider}set tileProvider(s){var h;this._tileProvider=this._normalizeText(s!=null?s:null,{lowercase:!0}),this._reflect("tile-provider",(h=this._tileProvider)!=null?h:null),this._controller&&this._updateTileLayer()}get tileStyle(){return this._tileStyle}set tileStyle(s){var h;this._tileStyle=this._normalizeText(s!=null?s:null),this._reflect("tile-style",(h=this._tileStyle)!=null?h:null),this._controller&&this._updateTileLayer()}get apiKey(){return this._apiKey}set apiKey(s){var h;this._apiKey=this._normalizeText(s!=null?s:null),this._reflect("api-key",(h=this._apiKey)!=null?h:null),this.hasAttribute("here-api-key")&&this.removeAttribute("here-api-key"),this._controller&&this._updateTileLayer()}get tileAttribution(){return this._tileAttribution}set tileAttribution(s){this._tileAttribution=s,this._reflect("tile-attribution",s!=null?s:null),this._controller&&this._updateTileLayer()}get readOnly(){return this._readOnly}set readOnly(s){this._readOnly=!!s,this._booleanReflect("read-only",this._readOnly)}get logLevel(){return this._logLevel}set logLevel(s){this._logLevel=s,this._logger.setLevel(s),this._reflect("log-level",s)}get devOverlay(){return this._devOverlay}set devOverlay(s){this._devOverlay=!!s,this._booleanReflect("dev-overlay",this._devOverlay)}get preferCanvas(){return this._preferCanvas}set preferCanvas(s){this._preferCanvas=!!s,this._booleanReflect("prefer-canvas",this._preferCanvas)}get useExternalLeaflet(){return this._useExternalLeaflet}set useExternalLeaflet(s){this._useExternalLeaflet=!!s,this._booleanReflect("use-external-leaflet",this._useExternalLeaflet)}get skipLeafletStyles(){return this._skipLeafletStyles}set skipLeafletStyles(s){this._skipLeafletStyles=!!s,this._booleanReflect("skip-leaflet-styles",this._skipLeafletStyles)}get leafletInstance(){return this._leafletInstance}set leafletInstance(s){this._leafletInstance=s}get themeCss(){return this._themeCss}set themeCss(s){this._themeCss=typeof s=="string"?s:"",this.isConnected&&this._applyThemeStyles()}async getGeoJSON(){return this._logger.debug("getGeoJSON"),this._controller?this._controller.getGeoJSON():{type:"FeatureCollection",features:[]}}async loadGeoJSON(s){var r,a;if(this._logger.debug("loadGeoJSON",{features:(a=(r=s==null?void 0:s.features)==null?void 0:r.length)!=null?a:0}),!this._controller)return;const h={fc:s,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:h}));const n=h.fc&&h.fc.type==="FeatureCollection"?h.fc:s;await this._controller.loadGeoJSON(n,!1)}async clearLayers(){this._logger.debug("clearLayers"),this._controller&&await this._controller.clearLayers()}async addFeatures(s){var r,a;if(this._logger.debug("addFeatures",{count:(a=(r=s==null?void 0:s.features)==null?void 0:r.length)!=null?a:0}),!this._controller)return[];const h={fc:s,mode:"add"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:h}));const n=h.fc&&h.fc.type==="FeatureCollection"?h.fc:s;return this._controller.addFeatures(n)}async updateFeature(s,h){this._logger.debug("updateFeature",{id:s}),this._controller&&await this._controller.updateFeature(s,h)}async removeFeature(s){this._logger.debug("removeFeature",{id:s}),this._controller&&await this._controller.removeFeature(s)}async fitBoundsToData(s){this._logger.debug("fitBoundsToData",{padding:s}),this._controller&&await this._controller.fitBoundsToData(typeof s=="number"?s:.05)}async fitBounds(s,h){this._logger.debug("fitBounds",{bounds:s,padding:h}),this._controller&&await this._controller.fitBounds(s,typeof h=="number"?h:.05)}async setView(s,h,n){this._logger.debug("setView",{lat:s,lng:h,zoom:n}),this.latitude=s,this.longitude=h,typeof n=="number"&&(this.zoom=n),this._controller&&await this._controller.setView(s,h,n)}async exportGeoJSON(){if(this._logger.debug("exportGeoJSON"),!this._controller)return{type:"FeatureCollection",features:[]};const s=await this._controller.getGeoJSON(),h={geoJSON:s,featureCount:s.features.length};return this.dispatchEvent(new CustomEvent("leaflet-draw:export",{detail:h})),s}async mergePolygons(s){if(this._logger.debug("mergePolygons"),!this._controller)return null;const n=(await this._controller.getGeoJSON()).features.length,r=await this._controller.mergeVisiblePolygons(s);if(r){const a=await this._controller.getGeoJSON(),u={id:r,mergedFeatureCount:n-a.features.length+1,geoJSON:a};this.dispatchEvent(new CustomEvent("leaflet-draw:merged",{detail:u}))}return r}async setMeasurementUnits(s){this._logger.debug("setMeasurementUnits",{system:s}),this._controller&&this._controller.setRulerUnits(s)}async loadGeoJSONFromUrl(s){if(this._logger.debug("loadGeoJSONFromUrl",{url:s}),!this._controller)return;const h=await fetch(s,{headers:{Accept:"application/json"}});if(!h.ok){const u=new Error(`Failed to fetch GeoJSON from ${s}: ${h.status} ${h.statusText}`);throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:u.message,cause:u}})),u}const n=await h.json(),r={fc:n,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:r}));const a=r.fc&&r.fc.type==="FeatureCollection"?r.fc:n;await this._controller.loadGeoJSON(a,!0)}async loadGeoJSONFromText(s){var a;if(this._logger.debug("loadGeoJSONFromText",{length:(a=s==null?void 0:s.length)!=null?a:0}),!this._controller)return;let h;try{h=JSON.parse(s)}catch(u){const f=new Error("Failed to parse GeoJSON text");throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:f.message,cause:u}})),f}const n={fc:h,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:n}));const r=n.fc&&n.fc.type==="FeatureCollection"?n.fc:h;await this._controller.loadGeoJSON(r,!0)}_currentConfig(){return{latitude:this._latitude,longitude:this._longitude,zoom:this._zoom,minZoom:this._minZoom,maxZoom:this._maxZoom,tileUrl:this._tileUrl,tileAttribution:this._tileAttribution,readOnly:this._readOnly,fitToDataOnLoad:!1,logLevel:this._logLevel,devOverlay:this._devOverlay,polygonAllowIntersection:this._polygonAllowIntersection,preferCanvas:this._preferCanvas,useExternalLeaflet:this._useExternalLeaflet,skipLeafletStyles:this._skipLeafletStyles}}_applyThemeStyles(){var n;const s=(n=this._themeUrl)==null?void 0:n.trim();if(s){if(!this._themeLinkEl){const r=document.createElement("link");r.setAttribute("rel","stylesheet"),r.setAttribute("data-geokit-theme-url","true"),this._root.appendChild(r),this._themeLinkEl=r}this._themeLinkEl.getAttribute("href")!==s&&this._themeLinkEl.setAttribute("href",s)}else this._themeLinkEl&&(this._themeLinkEl.remove(),this._themeLinkEl=null);const h=this._themeCss;if(h.trim().length>0){if(!this._themeStyleEl){const r=document.createElement("style");r.setAttribute("data-geokit-theme-css","true"),this._root.appendChild(r),this._themeStyleEl=r}this._themeStyleEl.textContent!==h&&(this._themeStyleEl.textContent=h)}else this._themeStyleEl&&(this._themeStyleEl.remove(),this._themeStyleEl=null)}_syncApiKeyFromAttributes(){const s=this._normalizeText(this.getAttribute("api-key")),h=this._normalizeText(this.getAttribute("here-api-key"));this._apiKey=s!=null?s:h}_normalizeText(s,h){if(typeof s!="string")return;const n=s.trim();if(n)return h!=null&&h.lowercase?n.toLowerCase():n}_resolveTileProviderErrorCode(s){return s instanceof Error&&s.message.toLowerCase().includes("unknown tile provider")?"unknown_provider":"tile_load_failed"}_resolveHereTileLayerErrorCode(s){const h=s.toLowerCase();return h.includes("permission")||h.includes("forbidden")||h.includes("403")||h.includes("unauthorized")||h.includes("not authorized")||h.includes("not authorised")||h.includes("access denied")?"permission_denied":"invalid_api_key"}_describeTileLayerError(s,h){if(s&&typeof s=="object"&&"error"in s&&s.error instanceof Error)return s.error.message;if(s instanceof Error&&s.message)return s.message;if(s&&typeof s=="object"&&"message"in s&&typeof s.message=="string"){const n=s.message.trim();if(n.length>0)return n}return h==="here"?`Failed to load HERE tiles; verify API key, project permissions, and allowed localhost origin/referrer.${this._tileStyle==="satellite.day"?" If satellite.day fails, try lite.day.":""}`:"Failed to load tile layer"}_reflect(s,h){h===null?this.removeAttribute(s):this.getAttribute(s)!==h&&this.setAttribute(s,h)}_booleanReflect(s,h){h?this.hasAttribute(s)||this.setAttribute(s,""):this.hasAttribute(s)&&this.removeAttribute(s)}_coerceNumber(s,h){if(s==null)return h!=null?h:NaN;const n=Number(s);return Number.isFinite(n)?n:h!=null?h:NaN}}const mr={Ready:"leaflet-draw:ready",Created:"leaflet-draw:created",Edited:"leaflet-draw:edited",Deleted:"leaflet-draw:deleted",Error:"leaflet-draw:error",Ingest:"leaflet-draw:ingest",Export:"leaflet-draw:export",DrawStart:"leaflet-draw:drawstart",DrawStop:"leaflet-draw:drawstop",EditStart:"leaflet-draw:editstart",EditStop:"leaflet-draw:editstop"},Xi="leaflet-geokit";customElements.get(Xi)||customElements.define(Xi,ei);const Qi="leaflet-draw-map";if(!customElements.get(Qi)){class m extends ei{}customElements.define(Qi,m)}dt.DrawEvent=mr,dt.LeafletDrawMapElement=ei,Object.defineProperty(dt,Symbol.toStringTag,{value:"Module"})}));
|
|
255
255
|
//# sourceMappingURL=leaflet-geokit.umd.js.map
|